@charcoal-ui/react 5.6.0 → 5.8.0-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (46) hide show
  1. package/dist/index.cjs +3 -2
  2. package/dist/index.cjs.map +1 -1
  3. package/dist/index.css +566 -586
  4. package/dist/index.css.map +1 -1
  5. package/dist/index.js +3 -2
  6. package/dist/index.js.map +1 -1
  7. package/dist/layered.css +566 -586
  8. package/dist/layered.css.map +1 -1
  9. package/package.json +6 -5
  10. package/src/__tests__/css-output.test.ts +77 -0
  11. package/src/components/Button/__snapshots__/index.css.snap +123 -0
  12. package/src/components/Button/index.css +105 -120
  13. package/src/components/Checkbox/__snapshots__/index.css.snap +22 -0
  14. package/src/components/Checkbox/index.css +7 -7
  15. package/src/components/Clickable/__snapshots__/index.css.snap +41 -0
  16. package/src/components/Clickable/index.css +11 -11
  17. package/src/components/DropdownSelector/__snapshots__/index.css.snap +79 -0
  18. package/src/components/DropdownSelector/index.css +33 -33
  19. package/src/components/FieldLabel/__snapshots__/index.css.snap +37 -0
  20. package/src/components/FieldLabel/index.css +6 -6
  21. package/src/components/HintText/__snapshots__/index.css.snap +37 -0
  22. package/src/components/HintText/index.css +5 -7
  23. package/src/components/IconButton/__snapshots__/index.css.snap +107 -0
  24. package/src/components/IconButton/index.css +87 -89
  25. package/src/components/LoadingSpinner/__snapshots__/index.css.snap +47 -0
  26. package/src/components/LoadingSpinner/index.css +11 -9
  27. package/src/components/Modal/__snapshots__/index.css.snap +35 -0
  28. package/src/components/Modal/index.css +5 -5
  29. package/src/components/MultiSelect/__snapshots__/index.css.snap +124 -0
  30. package/src/components/MultiSelect/index.css +74 -82
  31. package/src/components/Pagination/__snapshots__/index.css.snap +114 -0
  32. package/src/components/Pagination/index.css +79 -80
  33. package/src/components/Radio/__snapshots__/index.css.snap +18 -0
  34. package/src/components/Radio/index.css +4 -4
  35. package/src/components/SegmentedControl/__snapshots__/index.css.snap +61 -0
  36. package/src/components/SegmentedControl/index.css +23 -25
  37. package/src/components/Switch/__snapshots__/index.css.snap +23 -0
  38. package/src/components/Switch/index.css +7 -7
  39. package/src/components/TagItem/__snapshots__/index.css.snap +139 -0
  40. package/src/components/TagItem/index.css +80 -71
  41. package/src/components/TextArea/__snapshots__/index.css.snap +78 -0
  42. package/src/components/TextArea/index.css +24 -23
  43. package/src/components/TextEllipsis/__snapshots__/index.css.snap +20 -0
  44. package/src/components/TextEllipsis/index.css +10 -10
  45. package/src/components/TextField/__snapshots__/index.css.snap +86 -0
  46. package/src/components/TextField/index.css +19 -21
@@ -0,0 +1,123 @@
1
+ .charcoal-button {
2
+ appearance: none;
3
+ background: transparent;
4
+ box-sizing: border-box;
5
+ padding: 0 24px;
6
+ border-style: none;
7
+ outline: none;
8
+ text-rendering: inherit;
9
+ letter-spacing: inherit;
10
+ word-spacing: inherit;
11
+ text-decoration: none;
12
+ font: inherit;
13
+ margin: 0;
14
+ overflow: visible;
15
+ text-transform: none;
16
+ width: min-content;
17
+ display: inline-grid;
18
+ align-items: center;
19
+ justify-content: center;
20
+ cursor: pointer;
21
+ user-select: none;
22
+ white-space: nowrap;
23
+ border-radius: 999999px;
24
+ font-size: 14px;
25
+ line-height: 22px;
26
+ font-weight: bold;
27
+ color: var(--charcoal-text2);
28
+ background-color: var(--charcoal-surface3);
29
+ transition: 0.2s color,
30
+ 0.2s background-color,
31
+ 0.2s box-shadow;
32
+ height: 40px;
33
+ }
34
+
35
+ .charcoal-button:disabled, .charcoal-button[aria-disabled]:not([aria-disabled='false']) {
36
+ cursor: default;
37
+ opacity: 0.32;
38
+ }
39
+
40
+ .charcoal-button:not(:disabled):not([aria-disabled]):focus-visible, .charcoal-button[aria-disabled='false']:focus-visible {
41
+ outline: none;
42
+ box-shadow: 0 0 0 4px rgba(0, 150, 250, 0.32);
43
+ }
44
+
45
+ .charcoal-button:not(:disabled):not([aria-disabled]):hover, .charcoal-button[aria-disabled='false']:hover {
46
+ color: var(--charcoal-text2-hover);
47
+ background-color: var(--charcoal-surface3-hover);
48
+ }
49
+
50
+ .charcoal-button:not(:disabled):not([aria-disabled]):active, .charcoal-button[aria-disabled='false']:active, .charcoal-button[data-active='true'] {
51
+ color: var(--charcoal-text2-press);
52
+ background-color: var(--charcoal-surface3-press);
53
+ }
54
+
55
+ .charcoal-button[data-variant='Primary'] {
56
+ color: var(--charcoal-text5);
57
+ background-color: var(--charcoal-brand);
58
+ }
59
+
60
+ .charcoal-button[data-variant='Primary']:hover:not(:disabled):not([aria-disabled]), .charcoal-button[data-variant='Primary']:hover[aria-disabled='false'] {
61
+ color: var(--charcoal-text5-hover);
62
+ background-color: var(--charcoal-brand-hover);
63
+ }
64
+
65
+ .charcoal-button[data-variant='Primary']:active:not(:disabled):not([aria-disabled]), .charcoal-button[data-variant='Primary']:active[aria-disabled='false'], .charcoal-button[data-variant='Primary'][data-active='true'] {
66
+ color: var(--charcoal-text5-press);
67
+ background-color: var(--charcoal-brand-press);
68
+ }
69
+
70
+ .charcoal-button[data-variant='Overlay'] {
71
+ color: var(--charcoal-text5);
72
+ background-color: var(--charcoal-surface4);
73
+ }
74
+
75
+ .charcoal-button[data-variant='Overlay']:hover:not(:disabled):not([aria-disabled]), .charcoal-button[data-variant='Overlay']:hover[aria-disabled='false'] {
76
+ color: var(--charcoal-text5-hover);
77
+ background-color: var(--charcoal-surface4-hover);
78
+ }
79
+
80
+ .charcoal-button[data-variant='Overlay']:active:not(:disabled):not([aria-disabled]), .charcoal-button[data-variant='Overlay']:active[aria-disabled='false'], .charcoal-button[data-variant='Overlay'][data-active='true'] {
81
+ color: var(--charcoal-text5-press);
82
+ background-color: var(--charcoal-surface4-press);
83
+ }
84
+
85
+ .charcoal-button[data-variant='Navigation'] {
86
+ color: var(--charcoal-text5);
87
+ background-color: var(--charcoal-surface6);
88
+ }
89
+
90
+ .charcoal-button[data-variant='Navigation']:hover:not(:disabled):not([aria-disabled]), .charcoal-button[data-variant='Navigation']:hover[aria-disabled='false'] {
91
+ color: var(--charcoal-text5-hover);
92
+ background-color: var(--charcoal-surface6-hover);
93
+ }
94
+
95
+ .charcoal-button[data-variant='Navigation']:active:not(:disabled):not([aria-disabled]), .charcoal-button[data-variant='Navigation']:active[aria-disabled='false'], .charcoal-button[data-variant='Navigation'][data-active='true'] {
96
+ color: var(--charcoal-text5-press);
97
+ background-color: var(--charcoal-surface6-press);
98
+ }
99
+
100
+ .charcoal-button[data-variant='Danger'] {
101
+ color: var(--charcoal-text5);
102
+ background-color: var(--charcoal-assertive);
103
+ }
104
+
105
+ .charcoal-button[data-variant='Danger']:hover:not(:disabled):not([aria-disabled]), .charcoal-button[data-variant='Danger']:hover[aria-disabled='false'] {
106
+ color: var(--charcoal-text5-hover);
107
+ background-color: var(--charcoal-assertive-hover);
108
+ }
109
+
110
+ .charcoal-button[data-variant='Danger']:active:not(:disabled):not([aria-disabled]), .charcoal-button[data-variant='Danger']:active[aria-disabled='false'], .charcoal-button[data-variant='Danger'][data-active='true'] {
111
+ color: var(--charcoal-text5-press);
112
+ background-color: var(--charcoal-assertive-press);
113
+ }
114
+
115
+ .charcoal-button[data-size='S'] {
116
+ padding: 0 16px;
117
+ height: 32px;
118
+ }
119
+
120
+ .charcoal-button[data-full-width='true'] {
121
+ width: 100%;
122
+ }
123
+
@@ -31,125 +31,110 @@
31
31
  0.2s background-color,
32
32
  0.2s box-shadow;
33
33
  height: 40px;
34
- }
35
-
36
- .charcoal-button:disabled,
37
- .charcoal-button[aria-disabled]:not([aria-disabled='false']) {
38
- cursor: default;
39
- opacity: 0.32;
40
- }
41
-
42
- .charcoal-button:not(:disabled):not([aria-disabled]):focus-visible,
43
- .charcoal-button[aria-disabled='false']:focus-visible {
44
- outline: none;
45
- box-shadow: 0 0 0 4px rgba(0, 150, 250, 0.32);
46
- }
47
-
48
- .charcoal-button:not(:disabled):not([aria-disabled]):hover,
49
- .charcoal-button[aria-disabled='false']:hover {
50
- color: var(--charcoal-text2-hover);
51
- background-color: var(--charcoal-surface3-hover);
52
- }
53
-
54
- .charcoal-button:not(:disabled):not([aria-disabled]):active,
55
- .charcoal-button[aria-disabled='false']:active,
56
- .charcoal-button[data-active='true'] {
57
- color: var(--charcoal-text2-press);
58
- background-color: var(--charcoal-surface3-press);
59
- }
60
-
61
- .charcoal-button[data-variant='Primary'] {
62
- color: var(--charcoal-text5);
63
- background-color: var(--charcoal-brand);
64
- }
65
-
66
- .charcoal-button[data-variant='Primary']:hover:not(:disabled):not(
67
- [aria-disabled]
68
- ),
69
- .charcoal-button[data-variant='Primary']:hover[aria-disabled='false'] {
70
- color: var(--charcoal-text5-hover);
71
- background-color: var(--charcoal-brand-hover);
72
- }
73
-
74
- .charcoal-button[data-variant='Primary']:active:not(:disabled):not(
75
- [aria-disabled]
76
- ),
77
- .charcoal-button[data-variant='Primary']:active[aria-disabled='false'],
78
- .charcoal-button[data-variant='Primary'][data-active='true'] {
79
- color: var(--charcoal-text5-press);
80
- background-color: var(--charcoal-brand-press);
81
- }
82
-
83
- .charcoal-button[data-variant='Overlay'] {
84
- color: var(--charcoal-text5);
85
- background-color: var(--charcoal-surface4);
86
- }
87
-
88
- .charcoal-button[data-variant='Overlay']:hover:not(:disabled):not(
89
- [aria-disabled]
90
- ),
91
- .charcoal-button[data-variant='Overlay']:hover[aria-disabled='false'] {
92
- color: var(--charcoal-text5-hover);
93
- background-color: var(--charcoal-surface4-hover);
94
- }
95
-
96
- .charcoal-button[data-variant='Overlay']:active:not(:disabled):not(
97
- [aria-disabled]
98
- ),
99
- .charcoal-button[data-variant='Overlay']:active[aria-disabled='false'],
100
- .charcoal-button[data-variant='Overlay'][data-active='true'] {
101
- color: var(--charcoal-text5-press);
102
- background-color: var(--charcoal-surface4-press);
103
- }
104
-
105
- .charcoal-button[data-variant='Navigation'] {
106
- color: var(--charcoal-text5);
107
- background-color: var(--charcoal-surface6);
108
- }
109
-
110
- .charcoal-button[data-variant='Navigation']:hover:not(:disabled):not(
111
- [aria-disabled]
112
- ),
113
- .charcoal-button[data-variant='Navigation']:hover[aria-disabled='false'] {
114
- color: var(--charcoal-text5-hover);
115
- background-color: var(--charcoal-surface6-hover);
116
- }
117
-
118
- .charcoal-button[data-variant='Navigation']:active:not(:disabled):not(
119
- [aria-disabled]
120
- ),
121
- .charcoal-button[data-variant='Navigation']:active[aria-disabled='false'],
122
- .charcoal-button[data-variant='Navigation'][data-active='true'] {
123
- color: var(--charcoal-text5-press);
124
- background-color: var(--charcoal-surface6-press);
125
- }
126
-
127
- .charcoal-button[data-variant='Danger'] {
128
- color: var(--charcoal-text5);
129
- background-color: var(--charcoal-assertive);
130
- }
131
- .charcoal-button[data-variant='Danger']:hover:not(:disabled):not(
132
- [aria-disabled]
133
- ),
134
- .charcoal-button[data-variant='Danger']:hover[aria-disabled='false'] {
135
- color: var(--charcoal-text5-hover);
136
- background-color: var(--charcoal-assertive-hover);
137
- }
138
-
139
- .charcoal-button[data-variant='Danger']:active:not(:disabled):not(
140
- [aria-disabled]
141
- ),
142
- .charcoal-button[data-variant='Danger']:active[aria-disabled='false'],
143
- .charcoal-button[data-variant='Danger'][data-active='true'] {
144
- color: var(--charcoal-text5-press);
145
- background-color: var(--charcoal-assertive-press);
146
- }
147
-
148
- .charcoal-button[data-size='S'] {
149
- padding: 0 16px;
150
- height: 32px;
151
- }
152
34
 
153
- .charcoal-button[data-full-width='true'] {
154
- width: 100%;
35
+ &:disabled,
36
+ &[aria-disabled]:not([aria-disabled='false']) {
37
+ cursor: default;
38
+ opacity: 0.32;
39
+ }
40
+
41
+ &:not(:disabled):not([aria-disabled]):focus-visible,
42
+ &[aria-disabled='false']:focus-visible {
43
+ outline: none;
44
+ box-shadow: 0 0 0 4px rgba(0, 150, 250, 0.32);
45
+ }
46
+
47
+ &:not(:disabled):not([aria-disabled]):hover,
48
+ &[aria-disabled='false']:hover {
49
+ color: var(--charcoal-text2-hover);
50
+ background-color: var(--charcoal-surface3-hover);
51
+ }
52
+
53
+ &:not(:disabled):not([aria-disabled]):active,
54
+ &[aria-disabled='false']:active,
55
+ &[data-active='true'] {
56
+ color: var(--charcoal-text2-press);
57
+ background-color: var(--charcoal-surface3-press);
58
+ }
59
+
60
+ &[data-variant='Primary'] {
61
+ color: var(--charcoal-text5);
62
+ background-color: var(--charcoal-brand);
63
+
64
+ &:hover:not(:disabled):not([aria-disabled]),
65
+ &:hover[aria-disabled='false'] {
66
+ color: var(--charcoal-text5-hover);
67
+ background-color: var(--charcoal-brand-hover);
68
+ }
69
+
70
+ &:active:not(:disabled):not([aria-disabled]),
71
+ &:active[aria-disabled='false'],
72
+ &[data-active='true'] {
73
+ color: var(--charcoal-text5-press);
74
+ background-color: var(--charcoal-brand-press);
75
+ }
76
+ }
77
+
78
+ &[data-variant='Overlay'] {
79
+ color: var(--charcoal-text5);
80
+ background-color: var(--charcoal-surface4);
81
+
82
+ &:hover:not(:disabled):not([aria-disabled]),
83
+ &:hover[aria-disabled='false'] {
84
+ color: var(--charcoal-text5-hover);
85
+ background-color: var(--charcoal-surface4-hover);
86
+ }
87
+
88
+ &:active:not(:disabled):not([aria-disabled]),
89
+ &:active[aria-disabled='false'],
90
+ &[data-active='true'] {
91
+ color: var(--charcoal-text5-press);
92
+ background-color: var(--charcoal-surface4-press);
93
+ }
94
+ }
95
+
96
+ &[data-variant='Navigation'] {
97
+ color: var(--charcoal-text5);
98
+ background-color: var(--charcoal-surface6);
99
+
100
+ &:hover:not(:disabled):not([aria-disabled]),
101
+ &:hover[aria-disabled='false'] {
102
+ color: var(--charcoal-text5-hover);
103
+ background-color: var(--charcoal-surface6-hover);
104
+ }
105
+
106
+ &:active:not(:disabled):not([aria-disabled]),
107
+ &:active[aria-disabled='false'],
108
+ &[data-active='true'] {
109
+ color: var(--charcoal-text5-press);
110
+ background-color: var(--charcoal-surface6-press);
111
+ }
112
+ }
113
+
114
+ &[data-variant='Danger'] {
115
+ color: var(--charcoal-text5);
116
+ background-color: var(--charcoal-assertive);
117
+
118
+ &:hover:not(:disabled):not([aria-disabled]),
119
+ &:hover[aria-disabled='false'] {
120
+ color: var(--charcoal-text5-hover);
121
+ background-color: var(--charcoal-assertive-hover);
122
+ }
123
+
124
+ &:active:not(:disabled):not([aria-disabled]),
125
+ &:active[aria-disabled='false'],
126
+ &[data-active='true'] {
127
+ color: var(--charcoal-text5-press);
128
+ background-color: var(--charcoal-assertive-press);
129
+ }
130
+ }
131
+
132
+ &[data-size='S'] {
133
+ padding: 0 16px;
134
+ height: 32px;
135
+ }
136
+
137
+ &[data-full-width='true'] {
138
+ width: 100%;
139
+ }
155
140
  }
@@ -0,0 +1,22 @@
1
+ .charcoal-checkbox__label {
2
+ position: relative;
3
+ cursor: pointer;
4
+ display: flex;
5
+ gap: 4px;
6
+ }
7
+
8
+ .charcoal-checkbox__label[aria-disabled='true'] {
9
+ cursor: default;
10
+ opacity: 0.32;
11
+ }
12
+
13
+ .charcoal-checkbox__label[aria-disabled='true'] > input {
14
+ opacity: 1;
15
+ }
16
+
17
+ .charcoal-checkbox__label_div {
18
+ flex: 1;
19
+ color: var(--charcoal-text2);
20
+ font-size: 14px;
21
+ line-height: 20px;
22
+ }
@@ -3,15 +3,15 @@
3
3
  cursor: pointer;
4
4
  display: flex;
5
5
  gap: 4px;
6
- }
7
6
 
8
- .charcoal-checkbox__label[aria-disabled='true'] {
9
- cursor: default;
10
- opacity: 0.32;
11
- }
7
+ &[aria-disabled='true'] {
8
+ cursor: default;
9
+ opacity: 0.32;
12
10
 
13
- .charcoal-checkbox__label[aria-disabled='true'] > input {
14
- opacity: 1;
11
+ & > input {
12
+ opacity: 1;
13
+ }
14
+ }
15
15
  }
16
16
 
17
17
  .charcoal-checkbox__label_div {
@@ -0,0 +1,41 @@
1
+ .charcoal-clickable {
2
+ cursor: pointer;
3
+
4
+ /* Reset button appearance */
5
+ appearance: none;
6
+ background: transparent;
7
+ padding: 0;
8
+ border-style: none;
9
+ outline: none;
10
+ color: inherit;
11
+ text-rendering: inherit;
12
+ letter-spacing: inherit;
13
+ word-spacing: inherit;
14
+ text-decoration: none;
15
+
16
+ /* Change the font styles in all browsers. */
17
+ font: inherit;
18
+
19
+ /* Remove the margin in Firefox and Safari. */
20
+ margin: 0;
21
+
22
+ /* Show the overflow in Edge. */
23
+ overflow: visible;
24
+
25
+ /* Remove the inheritance of text transform in Firefox. */
26
+ text-transform: none;
27
+ }
28
+
29
+ .charcoal-clickable:disabled, .charcoal-clickable[aria-disabled]:not([aria-disabled='false']) {
30
+ cursor: default;
31
+ }
32
+
33
+ .charcoal-clickable:focus {
34
+ outline: none;
35
+ }
36
+
37
+ .charcoal-clickable::-moz-focus-inner {
38
+ border-style: none;
39
+ padding: 0;
40
+ }
41
+
@@ -24,18 +24,18 @@
24
24
 
25
25
  /* Remove the inheritance of text transform in Firefox. */
26
26
  text-transform: none;
27
- }
28
27
 
29
- .charcoal-clickable:disabled,
30
- .charcoal-clickable[aria-disabled]:not([aria-disabled='false']) {
31
- cursor: default;
32
- }
28
+ &:disabled,
29
+ &[aria-disabled]:not([aria-disabled='false']) {
30
+ cursor: default;
31
+ }
33
32
 
34
- .charcoal-clickable:focus {
35
- outline: none;
36
- }
33
+ &:focus {
34
+ outline: none;
35
+ }
37
36
 
38
- .charcoal-clickable::-moz-focus-inner {
39
- border-style: none;
40
- padding: 0;
37
+ &::-moz-focus-inner {
38
+ border-style: none;
39
+ padding: 0;
40
+ }
41
41
  }
@@ -0,0 +1,79 @@
1
+ .charcoal-dropdown-selector-root {
2
+ display: grid;
3
+ grid-template-columns: 1fr;
4
+ grid-gap: 4px;
5
+ width: 100%;
6
+ }
7
+
8
+ .charcoal-dropdown-selector-root[aria-disabled='true'] {
9
+ cursor: default;
10
+ opacity: 0.32;
11
+ }
12
+
13
+ .charcoal-dropdown-selector-button {
14
+ display: grid;
15
+ grid-template-columns: 1fr auto;
16
+ justify-content: space-between;
17
+ align-items: center;
18
+ height: 40px;
19
+ width: 100%;
20
+ box-sizing: border-box;
21
+ border: none;
22
+ cursor: pointer;
23
+ gap: 4px;
24
+ padding-right: 8px;
25
+ padding-left: 8px;
26
+ background-color: var(--charcoal-surface3);
27
+ border-radius: 4px;
28
+ transition: 0.2s box-shadow,
29
+ 0.2s background-color;
30
+ }
31
+
32
+ .charcoal-dropdown-selector-button:disabled {
33
+ cursor: default;
34
+ }
35
+
36
+ .charcoal-dropdown-selector-button:not(:disabled):focus {
37
+ outline: none;
38
+ box-shadow: 0 0 0 4px rgba(0, 150, 250, 0.32);
39
+ }
40
+
41
+ .charcoal-dropdown-selector-button:not(:disabled):focus-visible {
42
+ box-shadow: 0 0 0 4px rgba(0, 150, 250, 0.32);
43
+ }
44
+
45
+ .charcoal-dropdown-selector-button:not(:disabled)[data-active='true'], .charcoal-dropdown-selector-button:not(:disabled):active {
46
+ background-color: var(--charcoal-surface3-press);
47
+ }
48
+
49
+ .charcoal-dropdown-selector-button:not(:disabled):hover {
50
+ background-color: var(--charcoal-surface3-hover);
51
+ }
52
+
53
+ .charcoal-dropdown-selector-button:not(:disabled):focus:not(:focus-visible) {
54
+ box-shadow: none;
55
+ }
56
+
57
+ .charcoal-dropdown-selector-button[aria-invalid='true'], .charcoal-dropdown-selector-button:not(:disabled)[aria-invalid='true']:focus:not(:focus-visible) {
58
+ box-shadow: 0 0 0 4px rgba(255, 43, 0, 0.32);
59
+ }
60
+
61
+ .charcoal-ui-dropdown-selector-text {
62
+ text-align: left;
63
+ font-size: 14px;
64
+ line-height: 22px;
65
+ display: flow-root;
66
+ color: var(--charcoal-text2);
67
+ overflow: hidden;
68
+ text-overflow: ellipsis;
69
+ white-space: nowrap;
70
+ }
71
+
72
+ .charcoal-ui-dropdown-selector-text[data-placeholder='true'] {
73
+ color: var(--charcoal-text3);
74
+ }
75
+
76
+ .charcoal-ui-dropdown-selector-icon {
77
+ color: var(--charcoal-text2);
78
+ }
79
+
@@ -3,11 +3,11 @@
3
3
  grid-template-columns: 1fr;
4
4
  grid-gap: 4px;
5
5
  width: 100%;
6
- }
7
6
 
8
- .charcoal-dropdown-selector-root[aria-disabled='true'] {
9
- cursor: default;
10
- opacity: 0.32;
7
+ &[aria-disabled='true'] {
8
+ cursor: default;
9
+ opacity: 0.32;
10
+ }
11
11
  }
12
12
 
13
13
  .charcoal-dropdown-selector-button {
@@ -31,39 +31,39 @@
31
31
  transition:
32
32
  0.2s box-shadow,
33
33
  0.2s background-color;
34
- }
35
34
 
36
- .charcoal-dropdown-selector-button:disabled {
37
- cursor: default;
38
- }
35
+ &:disabled {
36
+ cursor: default;
37
+ }
39
38
 
40
- .charcoal-dropdown-selector-button:not(:disabled):focus {
41
- outline: none;
42
- box-shadow: 0 0 0 4px rgba(0, 150, 250, 0.32);
43
- }
39
+ &:not(:disabled) {
40
+ &:focus {
41
+ outline: none;
42
+ box-shadow: 0 0 0 4px rgba(0, 150, 250, 0.32);
43
+ }
44
44
 
45
- .charcoal-dropdown-selector-button:not(:disabled):focus-visible {
46
- box-shadow: 0 0 0 4px rgba(0, 150, 250, 0.32);
47
- }
45
+ &:focus-visible {
46
+ box-shadow: 0 0 0 4px rgba(0, 150, 250, 0.32);
47
+ }
48
48
 
49
- .charcoal-dropdown-selector-button:not(:disabled)[data-active='true'],
50
- .charcoal-dropdown-selector-button:not(:disabled):active {
51
- background-color: var(--charcoal-surface3-press);
52
- }
49
+ &[data-active='true'],
50
+ &:active {
51
+ background-color: var(--charcoal-surface3-press);
52
+ }
53
53
 
54
- .charcoal-dropdown-selector-button:not(:disabled):hover {
55
- background-color: var(--charcoal-surface3-hover);
56
- }
54
+ &:hover {
55
+ background-color: var(--charcoal-surface3-hover);
56
+ }
57
57
 
58
- .charcoal-dropdown-selector-button:not(:disabled):focus:not(:focus-visible) {
59
- box-shadow: none;
60
- }
58
+ &:focus:not(:focus-visible) {
59
+ box-shadow: none;
60
+ }
61
+ }
61
62
 
62
- .charcoal-dropdown-selector-button[aria-invalid='true'],
63
- .charcoal-dropdown-selector-button:not(
64
- :disabled
65
- )[aria-invalid='true']:focus:not(:focus-visible) {
66
- box-shadow: 0 0 0 4px rgba(255, 43, 0, 0.32);
63
+ &[aria-invalid='true'],
64
+ &:not(:disabled)[aria-invalid='true']:focus:not(:focus-visible) {
65
+ box-shadow: 0 0 0 4px rgba(255, 43, 0, 0.32);
66
+ }
67
67
  }
68
68
 
69
69
  .charcoal-ui-dropdown-selector-text {
@@ -75,10 +75,10 @@
75
75
  overflow: hidden;
76
76
  text-overflow: ellipsis;
77
77
  white-space: nowrap;
78
- }
79
78
 
80
- .charcoal-ui-dropdown-selector-text[data-placeholder='true'] {
81
- color: var(--charcoal-text3);
79
+ &[data-placeholder='true'] {
80
+ color: var(--charcoal-text3);
81
+ }
82
82
  }
83
83
 
84
84
  .charcoal-ui-dropdown-selector-icon {
@@ -0,0 +1,37 @@
1
+ .charcoal-field-label {
2
+ font-size: 14px;
3
+ line-height: 22px;
4
+ font-weight: bold;
5
+ display: flow-root;
6
+ color: var(--charcoal-text1);
7
+ }
8
+
9
+ .charcoal-field-label-required-text {
10
+ font-size: 14px;
11
+ line-height: 22px;
12
+ display: flow-root;
13
+ color: var(--charcoal-text2);
14
+ }
15
+
16
+ .charcoal-field-label-sub-label {
17
+ font-size: 14px;
18
+ line-height: 22px;
19
+ display: flow-root;
20
+ color: var(--charcoal-text3);
21
+ transition: 0.2s color,
22
+ 0.2s box-shadow;
23
+ }
24
+
25
+ .charcoal-field-label-root {
26
+ display: inline-flex;
27
+ align-items: center;
28
+ }
29
+
30
+ .charcoal-field-label-root > .charcoal-field-label-required-text {
31
+ margin-left: 4px;
32
+ }
33
+
34
+ .charcoal-field-label-root > .charcoal-field-label-sub-label {
35
+ margin-left: auto;
36
+ }
37
+