11@import " ../../pfe-sass/pfe-sass" ;
22
3- $LOCAL : tab;
4-
5- // Active tab styles
6-
7- :host (:focus ),
8- :host (:focus-visible ) {
9- outline : #{pfe-var (ui--focus-outline-width )} #{pfe-var (ui--focus-outline-style )} var (--pfe-tabs--focus );
10- }
3+ $LOCAL : tabs;
114
125/// ===========================================================================
136/// HORIZONTAL TAB ORIENTATION
147/// ===========================================================================
158
169:host {
17- @include pfe-tab ;
10+ --pfe-tabs--main : transparent ;
11+ --pfe-tabs--aux : #{pfe-color (ui-disabled--text )} ;
12+ --pfe-tabs--link : #{pfe-color (surface--lightest--link )} ;
13+ --pfe-tabs--focus : #{pfe-color (surface--lightest--link--focus )} ;
14+ --pfe-tabs--highlight : #{pfe-color (ui-accent )} ;
15+
16+ position : relative ;
17+ display : block ;
18+ margin : 0 0 -1px ;
19+
20+ // Padding
21+ padding : calc (#{pfe-var (container-padding )} * .666 ) calc (#{pfe-var (container-padding )} * 1.5 );
22+ // Border
23+ border : #{pfe-var (ui--border-width )} #{pfe-var (ui--border-style )} transparent ;
24+ border-bottom : 0 ;
25+ // Inner style
26+ background-color : var (--pfe-tabs--main );
27+ color : var (--pfe-tabs--aux );
28+ text-transform : var (--pfe-tabs__tab--TextTransform , none ); // exposing this for RH
29+ font-weight : #{pfe-var (font-weight--normal )} ;
30+
31+ cursor : pointer ;
32+ text-align : center ;
33+ }
34+
35+ // Active tab styles
36+
37+ :host (:focus ),
38+ :host (:focus-visible ) {
39+ outline : 1px solid #{$pfe-color--ui-link--focus } ;
40+ outline : #{pfe-var (ui--focus-outline-width )} #{pfe-var (ui--focus-outline-style )} #{pfe-local (focus )} ;
1841}
1942
2043:host ([aria-selected = " true" ]) {
21- @include pfe-tab-selected ;
44+ --pfe-tabs--aux : #{$pfe-color--black } ;
45+ // Border
46+ border : transparent ;
47+ border-bottom : #{pfe-var (surface--border-width--heavy )} #{pfe-var (surface--border-style )} #{pfe-local (highlight )} ;
2248}
2349
2450:host (:hover ) {
25- @include pfe-tab-hover ;
51+ -- pfe-tabs--aux : #{ pfe-color ( text )} ;
2652}
2753
2854/// ===========================================================================
2955/// VERTICAL TAB ORIENTATION
3056/// ===========================================================================
3157
3258:host ([vertical ]) {
33- @include pfe-tab-vertical ;
59+ text-align : left ;
60+ margin : 0 -1px 0 0 ;
61+ padding-left : calc (#{pfe-var (container-padding )} * .75 );
62+ border : #{pfe-var (ui--border-width )} #{pfe-var (ui--border-style )} transparent ;
63+ border-right : 0 ;
64+ position : relative ;
3465}
3566
3667:host ([vertical ][aria-selected = " true" ]) {
37- @include pfe-tab-vertical-selected ;
68+ border-color-top : transparent ;
69+ border-right : #{pfe-var (surface--border-width--heavy )} #{pfe-var (surface--border-style )} #{pfe-local (highlight )} ;
3870}
3971
4072/// ===========================================================================
4173/// WIND TAB VARIANTS
4274/// ===========================================================================
4375
44- :host ([pfe-variant = " wind" ][aria-selected = " true" ][on = " dark" ]) {
45- @include pfe-tab-wind-dark-selected ;
46- }
47-
76+ :host ([pfe-variant = " wind" ][aria-selected = " true" ][on = " dark" ]),
4877:host ([pfe-variant = " wind" ][on = " dark" ]:hover ) {
49- @include pfe-tab-wind -dark-selected ;
78+ --pfe-tabs--aux : #{ pfe-color ( ui- tab--dark-hover-color )} ;
5079}
5180
5281/// ===========================================================================
5382/// EARTH TAB VARIANTS
5483/// ===========================================================================
5584
5685:host ([pfe-variant = " earth" ][aria-selected = " false" ]) {
57- @include pfe-tab-earth-selected-false ;
86+ border-left : #{pfe-var (ui--border-width )} #{pfe-var (ui--border-style )} #{pfe-color (surface--border )} ;
87+ border-bottom : #{pfe-var (ui--border-width )} #{pfe-var (ui--border-style )} #{pfe-color (surface--border )} ;
88+ border-top : #{pfe-var (surface--border-width--heavy )} #{pfe-var (ui--border-style )} #{pfe-color (surface--lighter )} ;
89+ --pfe-tabs--main : #{pfe-color (surface--lighter )} ;
5890}
5991
6092:host ([pfe-variant = " earth" ][aria-selected = " true" ]) {
61- @include pfe-tab-earth-selected ;
93+ --pfe-tabs--main : #{pfe-color (surface--lightest )} ;
94+ border-top : #{pfe-var (surface--border-width--heavy )} #{pfe-var (surface--border-style )} #{pfe-local (highlight )} ;
95+ border-bottom : 0 ;
96+ border-left : #{pfe-var (ui--border-width )} #{pfe-var (ui--border-style )} #{pfe-color (surface--border )} ;
6297}
6398
6499:host ([pfe-variant = " earth" ][aria-selected = " true" ]:last-of-type ) {
65- @include pfe-tab-earth-selected-last ;
100+ border-right : #{ pfe-var ( ui--border-width )} #{ pfe-var ( ui--border-style )} #{ pfe-color ( surface--border )} ;
66101}
67102
68103/// ===========================================================================
69104/// EARTH TAB VERTICAL ORIENTATION
70105/// ===========================================================================
71106
72107:host ([vertical ][pfe-variant = " earth" ]) {
73- @include pfe-tab-earth-vertical ;
108+ border-top : #{ pfe-var ( ui--border-width )} #{ pfe-var ( ui--border-style )} #{ pfe-color ( surface--border )} ;
74109}
75110
76111:host ([vertical ][pfe-variant = " earth" ]:first-of-type ) {
77- @include pfe-tab-earth-vertical-first ;
112+ border-top : 0 ;
78113}
79114
80115:host ([vertical ][pfe-variant = " earth" ][aria-selected = " true" ]) {
81- @include pfe-tab-earth-vertical-selected ;
116+ border-top : #{pfe-var (ui--border-width )} #{pfe-var (ui--border-style )} #{pfe-color (surface--border )} ;
117+ border-right : 0 ;
118+ border-left : #{pfe-var (surface--border-width--heavy )} #{pfe-var (surface--border-style )} #{pfe-local (highlight )} ;
82119}
83120
84121:host ([vertical ][pfe-variant = " earth" ][aria-selected = " false" ]) {
85- @include pfe-tab-earth-vertical-selected-false ;
122+ border-right : #{pfe-var (ui--border-width )} #{pfe-var (ui--border-style )} #{pfe-color (surface--border )} ;
123+ border-bottom : 0 ;
124+ border-left : #{pfe-var (surface--border-width--heavy )} #{pfe-var (ui--border-style )} #{pfe-color (surface--lighter )} ;
86125}
87126
88127:host ([vertical ][pfe-variant = " earth" ][aria-selected = " true" ]:last-of-type ) {
89- @include pfe-tab-earth-vertical-selected-last ;
128+ border-bottom : #{ pfe-var ( ui--border-width )} #{ pfe-var ( ui--border-style )} #{ pfe-color ( surface--border )} ;
90129}
0 commit comments