KNACSS/sass/components/_tabs.scss

54 lines
1.2 KiB
SCSS
Raw Normal View History

2017-08-01 21:13:27 +02:00
/* ----------------------------- */
/* ==Tabs */
/* ----------------------------- */
/* see example on https://knacss.com/styleguide.html#tabs */
/* NOTE : tabs need JavaScript to be activated */
2017-09-07 15:54:20 +02:00
2017-08-01 21:13:27 +02:00
.tabs-menu {
2017-09-07 15:54:20 +02:00
border-bottom: 2px solid $border-tabs;
2017-08-01 21:13:27 +02:00
2017-09-07 15:54:20 +02:00
&-link {
display: block;
margin-bottom: -2px;
padding: $tiny-value $medium-plus-value;
border-bottom: 4px solid transparent;
color: $color-tabs;
background: $background-tabs;
text-decoration: none;
border-radius: $border-radius-tabs $border-radius-tabs 0 0;
transition: .25s;
transition-property: color, border, background-color;
2017-08-01 21:13:27 +02:00
2017-09-07 15:54:20 +02:00
&.is-active {
border-bottom-color: $border-tabs-active;
color: $color-tabs-active;
background: $background-tabs-active;
outline: 0;
}
2017-08-01 21:13:27 +02:00
2017-09-07 15:54:20 +02:00
&:focus {
border-bottom-color: $border-tabs-active;
color: $color-tabs-active;
outline: 0;
}
@media (min-width: $small) {
display: inline-block;
}
2017-08-01 21:13:27 +02:00
}
}
.tabs-content-item {
2017-09-07 15:54:20 +02:00
padding-top: $small-value;
2017-08-01 21:13:27 +02:00
2017-09-07 15:54:20 +02:00
&[aria-hidden="true"] {
visibility: hidden;
@extend .visually-hidden;
}
2017-08-01 21:13:27 +02:00
2017-09-07 15:54:20 +02:00
&[aria-hidden="false"] {
visibility: visible;
}
2017-08-01 21:13:27 +02:00
}