@@ -9,6 +9,12 @@ $variants: (
9
9
' primary' : colors .primary (700 ),
10
10
);
11
11
12
+ %column {
13
+ flex : 0 0 auto ;
14
+
15
+ margin-inline : lengths .margin (2 );
16
+ }
17
+
12
18
.rcx-option {
13
19
@include clickable ;
14
20
@include typography .use-font-scale (p2);
@@ -35,24 +41,33 @@ $variants: (
35
41
margin-inline : lengths .margin (-2 );
36
42
}
37
43
38
- & :hover ,
39
- & --focus {
40
- background : colors .neutral (100 );
44
+ & __icon {
45
+ color : inherit ;
41
46
}
42
47
43
- & --selected {
44
- background : colors . neutral ( 500 ) ;
48
+ & __avatar {
49
+ @extend %column ;
45
50
}
46
51
47
- & :hover & __menu-wrapper ,
48
- & .focus-within & __menu-wrapper ,
49
- & :focus-within & __menu-wrapper {
50
- display : flex ;
51
- align-items : center ;
52
+ & __content {
53
+ @include typography .use-text-ellipsis ;
54
+ @extend %column ;
55
+ flex : 1 1 100% ;
52
56
53
- width : lengths . size ( 28 ) ;
57
+ text-align : start ;
54
58
55
- opacity : 1 ;
59
+ white-space : nowrap ;
60
+ }
61
+
62
+ & __header {
63
+ @include typography .use-font-scale (micro);
64
+
65
+ padding-block : lengths .padding (8 );
66
+ padding-inline : lengths .padding (16 );
67
+
68
+ text-transform : uppercase ;
69
+
70
+ font-weight : 400 ;
56
71
}
57
72
58
73
& __menu-wrapper {
@@ -65,58 +80,56 @@ $variants: (
65
80
opacity : 0 ;
66
81
}
67
82
68
- @each $name , $color in $variants {
69
- & --#{$name} {
70
- color : theme (' option-color-variant-#{$name } ' , $color );
71
- }
72
- }
73
- }
74
-
75
- %column {
76
- flex : 0 0 auto ;
77
-
78
- margin-inline : lengths .margin (2 );
79
- }
83
+ & .rcx-option__column {
84
+ @extend %column ;
85
+ display : flex ;
80
86
81
- .rcx-option__icon {
82
- color : inherit ;
83
- }
87
+ justify-content : center ;
88
+ align-items : center ;
84
89
85
- .rcx-option__avatar {
86
- @extend %column ;
87
- }
90
+ min-width : lengths . size ( 20 );
91
+ min-height : lengths . size ( 20 ) ;
92
+ }
88
93
89
- .rcx-option__content {
90
- @include typography .use-text-ellipsis ;
91
- @extend %column ;
92
- flex : 1 1 100 % ;
94
+ & .rcx-option__description {
95
+ @include typography .use-font-scale (p2) ;
96
+ @extend %column ;
97
+ display : inline ;
93
98
94
- text-align : start ;
99
+ color : colors .foreground (hint );
100
+ }
95
101
96
- white-space : nowrap ;
97
- }
102
+ & :hover ,
103
+ & --focus {
104
+ background : colors .neutral (100 );
105
+ }
98
106
99
- .rcx-option__column {
100
- @extend %column ;
101
- display : flex ;
107
+ & --selected {
108
+ background : colors . neutral ( 500 ) ;
109
+ }
102
110
103
- justify-content : center ;
104
- align-items : center ;
111
+ & :hover & __menu-wrapper ,
112
+ & .focus-within & __menu-wrapper ,
113
+ & :focus-within & __menu-wrapper {
114
+ display : flex ;
115
+ align-items : center ;
105
116
106
- min-width : lengths .size (20 );
107
- min-height : lengths .size (20 );
108
- }
117
+ width : lengths .size (28 );
109
118
110
- .rcx-option__description {
111
- @include typography .use-font-scale (p2);
112
- @extend %column ;
113
- display : inline ;
119
+ opacity : 1 ;
120
+ }
114
121
115
- color : colors .foreground (hint );
122
+ @each $name , $color in $variants {
123
+ & --#{$name} {
124
+ color : theme (' option-color-variant-#{$name } ' , $color );
125
+ }
126
+ }
116
127
}
117
128
118
- .rcx-options :hover {
119
- .rcx-option--focus :not (.rcx-option--selected ):not (:hover ) {
120
- background : initial ;
129
+ .rcx-options {
130
+ & :hover {
131
+ .rcx-option--focus :not (.rcx-option--selected ):not (:hover ) {
132
+ background : initial ;
133
+ }
121
134
}
122
135
}
0 commit comments