summaryrefslogtreecommitdiffstats
path: root/src/objects/_tabbar.scss
diff options
context:
space:
mode:
Diffstat (limited to 'src/objects/_tabbar.scss')
-rw-r--r--src/objects/_tabbar.scss42
1 files changed, 8 insertions, 34 deletions
diff --git a/src/objects/_tabbar.scss b/src/objects/_tabbar.scss
index bd937d0..ce6a890 100644
--- a/src/objects/_tabbar.scss
+++ b/src/objects/_tabbar.scss
@@ -14,23 +14,13 @@
14 @include bem.object('tabbar') { 14 @include bem.object('tabbar') {
15 position: relative; 15 position: relative;
16 display: flex; 16 display: flex;
17 gap: props.get(vars.$spacing);
17 min-inline-size: 0; 18 min-inline-size: 0;
18 block-size: props.get(vars.$block-size); 19 block-size: props.get(vars.$block-size);
19 overflow-inline: auto; 20 box-shadow: 0 calc(-1 * props.get(vars.$indicator--width)) 0 0 props.get(vars.$railing--bg-color) inset;
20
21 &::after {
22 display: block;
23 flex: 1 1 auto;
24 block-size: props.get(vars.$indicator--width);
25 margin-block-start: 0;
26 content: '';
27 background-color: props.get(vars.$railing--bg-color);
28 }
29 21
30 @include bem.modifier('quiet') { 22 @include bem.modifier('quiet') {
31 &::after { 23 box-shadow: none;
32 display: none;
33 }
34 } 24 }
35 25
36 @include bem.modifier('adapt') { 26 @include bem.modifier('adapt') {
@@ -44,6 +34,7 @@
44 padding-inline: calc(.5 * props.get(vars.$spacing)); 34 padding-inline: calc(.5 * props.get(vars.$spacing));
45 color: props.get(vars.$tab--text-color); 35 color: props.get(vars.$tab--text-color);
46 white-space: nowrap; 36 white-space: nowrap;
37 border-block: props.get(vars.$indicator--width) solid transparent;
47 38
48 &::before { 39 &::before {
49 position: absolute; 40 position: absolute;
@@ -56,17 +47,6 @@
56 transform: translateY(-50%); 47 transform: translateY(-50%);
57 } 48 }
58 49
59 &::after {
60 position: absolute;
61 inset-block-end: 0;
62 inset-inline: calc(.5 * props.get(vars.$spacing));
63 z-index: -10;
64 display: none;
65 block-size: props.get(vars.$indicator--width);
66 content: '';
67 background-color: props.get(vars.$tab--selected--text-color);
68 }
69
70 &:link, 50 &:link,
71 &:visited { 51 &:visited {
72 &:hover, 52 &:hover,
@@ -88,11 +68,8 @@
88 } 68 }
89 69
90 @include bem.is('selected') { 70 @include bem.is('selected') {
91 color: props.get(vars.$tab--selected--text-color); 71 color: props.get(vars.$tab--selected--text-color);
92 72 border-block-end-color: props.get(vars.$tab--selected--text-color);
93 &::after {
94 display: block;
95 }
96 } 73 }
97 } 74 }
98 75
@@ -102,12 +79,9 @@
102 79
103 @include bem.modifier('accent') { 80 @include bem.modifier('accent') {
104 @include bem.elem('tab') { 81 @include bem.elem('tab') {
105 &::after {
106 background-color: props.get(vars.$tab--accent--text-color);
107 }
108
109 @include bem.is('selected') { 82 @include bem.is('selected') {
110 color: props.get(vars.$tab--accent--text-color); 83 color: props.get(vars.$tab--accent--text-color);
84 border-block-end-color: props.get(vars.$tab--accent--text-color);
111 } 85 }
112 } 86 }
113 } 87 }