@carbon/styles 0.7.0 → 0.9.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.
- package/package.json +9 -9
- package/scss/_feature-flags.scss +8 -1
- package/scss/_spacing.scss +1 -0
- package/scss/_type.scss +1 -0
- package/scss/components/_index.scss +1 -0
- package/scss/components/button/_button.scss +9 -0
- package/scss/components/checkbox/_checkbox.scss +1 -0
- package/scss/components/code-snippet/_code-snippet.scss +3 -3
- package/scss/components/data-table/_data-table.scss +1 -0
- package/scss/components/data-table/expandable/_data-table-expandable.scss +2 -2
- package/scss/components/date-picker/_date-picker.scss +1 -1
- package/scss/components/date-picker/_flatpickr.scss +39 -38
- package/scss/components/dropdown/_dropdown.scss +4 -4
- package/scss/components/file-uploader/_file-uploader.scss +4 -1
- package/scss/components/form/_form.scss +15 -6
- package/scss/components/list-box/_list-box.scss +34 -4
- package/scss/components/notification/_actionable-notification.scss +5 -2
- package/scss/components/notification/_inline-notification.scss +7 -4
- package/scss/components/notification/_toast-notification.scss +13 -8
- package/scss/components/number-input/_number-input.scss +3 -3
- package/scss/components/overflow-menu/_overflow-menu.scss +4 -4
- package/scss/components/popover/_popover.scss +232 -199
- package/scss/components/progress-indicator/_progress-indicator.scss +6 -0
- package/scss/components/radio-button/_radio-button.scss +11 -9
- package/scss/components/search/_search.scss +7 -7
- package/scss/components/stack/_index.scss +11 -0
- package/scss/components/stack/_stack.scss +34 -0
- package/scss/components/structured-list/_structured-list.scss +7 -4
- package/scss/components/tabs/_tabs.scss +4 -1
- package/scss/components/tile/_tile.scss +4 -3
- package/scss/components/toggle/_toggle.scss +80 -18
- package/scss/components/tooltip/_tooltip.scss +14 -727
- package/scss/components/treeview/_treeview.scss +17 -17
- package/scss/components/ui-shell/header/_header.scss +19 -0
- package/scss/utilities/_convert.scss +13 -4
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
@use '../../config' as *;
|
|
9
9
|
@use '../../motion' as *;
|
|
10
10
|
@use '../../spacing' as *;
|
|
11
|
-
@use '../../
|
|
11
|
+
@use '../../theme' as *;
|
|
12
12
|
@use '../../type' as *;
|
|
13
13
|
@use '../../utilities/convert' as *;
|
|
14
14
|
@use '../../utilities/focus-outline' as *;
|
|
@@ -23,8 +23,8 @@
|
|
|
23
23
|
|
|
24
24
|
.#{$prefix}--tree-node {
|
|
25
25
|
padding-left: $spacing-05;
|
|
26
|
-
background-color: $
|
|
27
|
-
color: $text-
|
|
26
|
+
background-color: $layer-01;
|
|
27
|
+
color: $text-secondary;
|
|
28
28
|
|
|
29
29
|
&:focus {
|
|
30
30
|
outline: none;
|
|
@@ -44,8 +44,8 @@
|
|
|
44
44
|
.#{$prefix}--tree-node--disabled
|
|
45
45
|
.#{$prefix}--tree-node__label:hover
|
|
46
46
|
.#{$prefix}--tree-node__label__details {
|
|
47
|
-
background-color: $
|
|
48
|
-
color: $disabled
|
|
47
|
+
background-color: $field-01;
|
|
48
|
+
color: $text-disabled;
|
|
49
49
|
}
|
|
50
50
|
|
|
51
51
|
.#{$prefix}--tree-node--disabled .#{$prefix}--tree-parent-node__toggle-icon,
|
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
.#{$prefix}--tree-node--disabled
|
|
57
57
|
.#{$prefix}--tree-node__label:hover
|
|
58
58
|
.#{$prefix}--tree-node__icon {
|
|
59
|
-
fill: $disabled
|
|
59
|
+
fill: $icon-disabled;
|
|
60
60
|
}
|
|
61
61
|
|
|
62
62
|
.#{$prefix}--tree-node--disabled,
|
|
@@ -74,19 +74,19 @@
|
|
|
74
74
|
align-items: center;
|
|
75
75
|
|
|
76
76
|
&:hover {
|
|
77
|
-
background-color: $hover-
|
|
78
|
-
color: $text-
|
|
77
|
+
background-color: $layer-hover-01;
|
|
78
|
+
color: $text-primary;
|
|
79
79
|
}
|
|
80
80
|
}
|
|
81
81
|
|
|
82
82
|
.#{$prefix}--tree-node__label:hover .#{$prefix}--tree-node__label__details {
|
|
83
|
-
color: $text-
|
|
83
|
+
color: $text-primary;
|
|
84
84
|
}
|
|
85
85
|
|
|
86
86
|
.#{$prefix}--tree-node__label:hover
|
|
87
87
|
.#{$prefix}--tree-parent-node__toggle-icon,
|
|
88
88
|
.#{$prefix}--tree-node__label:hover .#{$prefix}--tree-node__icon {
|
|
89
|
-
fill: $icon-
|
|
89
|
+
fill: $icon-primary;
|
|
90
90
|
}
|
|
91
91
|
|
|
92
92
|
.#{$prefix}--tree-leaf-node {
|
|
@@ -122,7 +122,7 @@
|
|
|
122
122
|
}
|
|
123
123
|
|
|
124
124
|
.#{$prefix}--tree-parent-node__toggle-icon {
|
|
125
|
-
fill: $icon-
|
|
125
|
+
fill: $icon-secondary;
|
|
126
126
|
transform: rotate(-90deg);
|
|
127
127
|
transition: all $duration-fast-02 motion(standard, productive);
|
|
128
128
|
}
|
|
@@ -135,15 +135,15 @@
|
|
|
135
135
|
min-width: 1rem;
|
|
136
136
|
min-height: 1rem;
|
|
137
137
|
margin-right: $spacing-03;
|
|
138
|
-
fill: $icon-
|
|
138
|
+
fill: $icon-secondary;
|
|
139
139
|
}
|
|
140
140
|
|
|
141
141
|
.#{$prefix}--tree-node--selected > .#{$prefix}--tree-node__label {
|
|
142
|
-
background-color: $selected-
|
|
143
|
-
color: $text-
|
|
142
|
+
background-color: $layer-selected-01;
|
|
143
|
+
color: $text-primary;
|
|
144
144
|
|
|
145
145
|
&:hover {
|
|
146
|
-
background-color: $
|
|
146
|
+
background-color: $layer-selected-hover-01;
|
|
147
147
|
}
|
|
148
148
|
}
|
|
149
149
|
|
|
@@ -153,7 +153,7 @@
|
|
|
153
153
|
.#{$prefix}--tree-node--selected
|
|
154
154
|
> .#{$prefix}--tree-node__label
|
|
155
155
|
.#{$prefix}--tree-node__icon {
|
|
156
|
-
fill: $icon-
|
|
156
|
+
fill: $icon-primary;
|
|
157
157
|
}
|
|
158
158
|
|
|
159
159
|
.#{$prefix}--tree-node--active > .#{$prefix}--tree-node__label {
|
|
@@ -165,7 +165,7 @@
|
|
|
165
165
|
left: 0;
|
|
166
166
|
width: rem(4px);
|
|
167
167
|
height: 100%;
|
|
168
|
-
background-color: $interactive
|
|
168
|
+
background-color: $interactive;
|
|
169
169
|
content: '';
|
|
170
170
|
}
|
|
171
171
|
}
|
|
@@ -269,6 +269,25 @@
|
|
|
269
269
|
position: relative;
|
|
270
270
|
}
|
|
271
271
|
|
|
272
|
+
.#{$prefix}--header__submenu--current::after {
|
|
273
|
+
position: absolute;
|
|
274
|
+
top: 0;
|
|
275
|
+
right: 0;
|
|
276
|
+
bottom: 0;
|
|
277
|
+
left: 0;
|
|
278
|
+
width: 100%;
|
|
279
|
+
border-bottom: 3px solid $border-interactive;
|
|
280
|
+
content: '';
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
.#{$prefix}--header__submenu--current:focus {
|
|
284
|
+
border: 2px solid $focus;
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
.#{$prefix}--header__submenu--current:focus::after {
|
|
288
|
+
border: 0;
|
|
289
|
+
}
|
|
290
|
+
|
|
272
291
|
.#{$prefix}--header__menu-title[aria-haspopup='true'] {
|
|
273
292
|
position: relative;
|
|
274
293
|
}
|
|
@@ -5,11 +5,12 @@
|
|
|
5
5
|
// LICENSE file in the root directory of this source tree.
|
|
6
6
|
//
|
|
7
7
|
|
|
8
|
+
@use 'sass:meta';
|
|
9
|
+
@use "sass:math";
|
|
10
|
+
|
|
8
11
|
/// Default font size
|
|
9
12
|
/// @type Number
|
|
10
13
|
/// @access public
|
|
11
|
-
@use "sass:math";
|
|
12
|
-
|
|
13
14
|
$base-font-size: 16px !default;
|
|
14
15
|
|
|
15
16
|
/// Convert a given px unit to a rem unit
|
|
@@ -23,7 +24,11 @@ $base-font-size: 16px !default;
|
|
|
23
24
|
@warn "Expected argument $px to be of type `px`, instead received: `#{unit($px)}`";
|
|
24
25
|
}
|
|
25
26
|
|
|
26
|
-
@
|
|
27
|
+
@if meta.function-exists('div', 'math') {
|
|
28
|
+
@return math.div($px, $base-font-size) * 1rem;
|
|
29
|
+
} @else {
|
|
30
|
+
@return ($px / $base-font-size) * 1rem;
|
|
31
|
+
}
|
|
27
32
|
}
|
|
28
33
|
|
|
29
34
|
/// Convert a given px unit to a em unit
|
|
@@ -37,5 +42,9 @@ $base-font-size: 16px !default;
|
|
|
37
42
|
@warn "Expected argument $px to be of type `px`, instead received: `#{unit($px)}`";
|
|
38
43
|
}
|
|
39
44
|
|
|
40
|
-
@
|
|
45
|
+
@if meta.function-exists('div', 'math') {
|
|
46
|
+
@return math.div($px, $base-font-size) * 1em;
|
|
47
|
+
} @else {
|
|
48
|
+
@return ($px / $base-font-size) * 1em;
|
|
49
|
+
}
|
|
41
50
|
}
|