opui-css 3.3.5 → 4.0.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/CHANGELOG.md +235 -0
- package/LICENSE +21 -21
- package/MIGRATING.md +105 -0
- package/README.md +66 -29
- package/astro/index.ts +46 -0
- package/components/AGENTS.md +247 -0
- package/components/Accordion/Accordion.astro +42 -0
- package/components/Anchor/Anchor.astro +51 -0
- package/components/Avatar/Avatar.astro +44 -0
- package/components/Badge/Badge.astro +54 -0
- package/components/Button/Button.astro +45 -0
- package/components/ButtonGroup/ButtonGroup.astro +29 -0
- package/components/Callout/Callout.astro +75 -0
- package/components/Card/Card.astro +38 -0
- package/components/Checkbox/Checkbox.astro +76 -0
- package/components/Checkbox/CheckboxInput.astro +32 -0
- package/components/Chip/Chip.astro +37 -0
- package/components/ClassicSelect/ClassicSelect.astro +83 -0
- package/components/DescriptionList/Description.astro +12 -0
- package/components/DescriptionList/DescriptionList.astro +22 -0
- package/components/DescriptionList/Item.astro +12 -0
- package/components/DescriptionList/Term.astro +12 -0
- package/components/DescriptionList/index.ts +12 -0
- package/components/Dialog/Dialog.astro +43 -0
- package/components/Divider/Divider.astro +14 -0
- package/components/Drawer/Drawer.astro +49 -0
- package/components/Drawer/DrawerFooter.astro +14 -0
- package/components/Drawer/DrawerHeader.astro +31 -0
- package/components/FieldDescription/FieldDescription.astro +13 -0
- package/components/FieldGroup/FieldGroup.astro +31 -0
- package/components/FieldLegend/FieldLegend.astro +15 -0
- package/components/FieldSet/FieldSet.astro +15 -0
- package/components/Form/Form.astro +15 -0
- package/components/IconButton/IconButton.astro +26 -0
- package/components/List/List.astro +36 -0
- package/components/ListItem/ListItem.astro +118 -0
- package/components/Progress/Progress.astro +40 -0
- package/components/Radio/Radio.astro +70 -0
- package/components/Radio/RadioInput.astro +24 -0
- package/components/Range/Range.astro +136 -0
- package/components/Select/Select.astro +106 -0
- package/components/Switch/Switch.astro +101 -0
- package/components/Switch/SwitchInput.astro +25 -0
- package/components/Table/Body.astro +13 -0
- package/components/Table/Cell.astro +13 -0
- package/components/Table/Column.astro +15 -0
- package/components/Table/ColumnGroup.astro +13 -0
- package/components/Table/Head.astro +13 -0
- package/components/Table/HeaderCell.astro +13 -0
- package/components/Table/Row.astro +13 -0
- package/components/Table/Table.astro +15 -0
- package/components/Table/index.ts +20 -0
- package/components/Tabs/Tabs.astro +28 -0
- package/components/Tabs/TabsItem.astro +47 -0
- package/components/Tabs/TabsPanel.astro +21 -0
- package/components/Tabs/TabsTab.astro +19 -0
- package/components/Tabs/index.ts +14 -0
- package/components/TextField/TextField.astro +128 -0
- package/components/Textarea/Textarea.astro +106 -0
- package/components/Toast/Toast.astro +42 -0
- package/components/ToggleButton/ToggleButton.astro +53 -0
- package/components/ToggleGroup/ToggleGroup.astro +49 -0
- package/components/Tooltip/Tooltip.astro +30 -0
- package/{src/core → core}/normalize.css +194 -196
- package/core/palette.css +59 -0
- package/{src/core → core}/utils.css +71 -60
- package/css/components/accordion.css +174 -0
- package/css/components/anchor.css +27 -0
- package/{src/themes/theme-two → css}/components/avatar.css +65 -68
- package/css/components/badge.css +107 -0
- package/css/components/button-group.css +179 -0
- package/css/components/button.css +215 -0
- package/css/components/callout.css +109 -0
- package/css/components/card.css +117 -0
- package/css/components/checkbox.css +205 -0
- package/{src/themes/theme-one → css}/components/chip.css +87 -135
- package/{src/themes/theme-two/components/definition-list.css → css/components/description-list.css} +77 -68
- package/{src/themes/theme-two → css}/components/dialog.css +68 -59
- package/css/components/divider.css +20 -0
- package/css/components/drawer.css +171 -0
- package/css/components/form.css +146 -0
- package/css/components/icon-button.css +139 -0
- package/{src/themes/theme-two → css}/components/link.css +21 -21
- package/{src/themes/theme-two → css}/components/list.css +345 -318
- package/{src/themes/theme-one → css}/components/progress.css +97 -83
- package/css/components/radio.css +172 -0
- package/css/components/range.css +337 -0
- package/{src/themes/theme-two → css}/components/select.css +169 -162
- package/{src/themes/theme-two → css}/components/spinner.css +37 -38
- package/{src/themes/theme-two → css}/components/switch.css +268 -225
- package/css/components/table.css +179 -0
- package/css/components/tabs.css +77 -0
- package/css/components/text-field.css +450 -0
- package/css/components/text-input.css +53 -0
- package/{src/themes/theme-two → css}/components/textarea.css +24 -25
- package/css/components/toast.css +161 -0
- package/css/components/toggle-button.css +87 -0
- package/css/components/toggle-group.css +56 -0
- package/css/components/tooltip.css +67 -0
- package/css/components/typography.css +585 -0
- package/{src/themes/theme-two → css}/components.css +41 -37
- package/{src/themes/theme-two → css}/imports.css +16 -16
- package/css/js/checkbox.js +21 -0
- package/css/js/toast.js +94 -0
- package/css/theme.css +132 -0
- package/dist/op.css +1001 -32
- package/dist/op.css.map +1 -0
- package/dist/opui.components.css +5135 -0
- package/dist/opui.components.css.map +1 -0
- package/dist/opui.css +6604 -0
- package/dist/opui.css.map +1 -0
- package/env.d.ts +14 -0
- package/open-props.css +9 -0
- package/package.json +64 -56
- package/dist/theme-one/components.css +0 -3869
- package/dist/theme-one/theme-one.css +0 -4424
- package/dist/theme-two/components.css +0 -3591
- package/dist/theme-two/theme-two.css +0 -4141
- package/src/open-props.css +0 -10
- package/src/themes/theme-one/components/accordion.css +0 -172
- package/src/themes/theme-one/components/alert.css +0 -85
- package/src/themes/theme-one/components/avatar.css +0 -68
- package/src/themes/theme-one/components/badge.css +0 -101
- package/src/themes/theme-one/components/button-group.css +0 -69
- package/src/themes/theme-one/components/button.css +0 -281
- package/src/themes/theme-one/components/card.css +0 -82
- package/src/themes/theme-one/components/checkbox-radio.css +0 -123
- package/src/themes/theme-one/components/definition-list.css +0 -68
- package/src/themes/theme-one/components/dialog.css +0 -59
- package/src/themes/theme-one/components/divider.css +0 -7
- package/src/themes/theme-one/components/field-group.css +0 -83
- package/src/themes/theme-one/components/field.css +0 -494
- package/src/themes/theme-one/components/icon-button.css +0 -40
- package/src/themes/theme-one/components/link.css +0 -21
- package/src/themes/theme-one/components/list.css +0 -318
- package/src/themes/theme-one/components/range.css +0 -121
- package/src/themes/theme-one/components/rich-text.css +0 -210
- package/src/themes/theme-one/components/select.css +0 -163
- package/src/themes/theme-one/components/snackbar.css +0 -148
- package/src/themes/theme-one/components/spinner.css +0 -38
- package/src/themes/theme-one/components/switch.css +0 -225
- package/src/themes/theme-one/components/tab-buttons.css +0 -120
- package/src/themes/theme-one/components/table.css +0 -92
- package/src/themes/theme-one/components/text-field.css +0 -57
- package/src/themes/theme-one/components/textarea.css +0 -25
- package/src/themes/theme-one/components/toggle-button-group.css +0 -135
- package/src/themes/theme-one/components/tooltip.css +0 -94
- package/src/themes/theme-one/components/typography.css +0 -209
- package/src/themes/theme-one/components.css +0 -37
- package/src/themes/theme-one/imports.css +0 -16
- package/src/themes/theme-one/theme.css +0 -163
- package/src/themes/theme-two/components/accordion.css +0 -172
- package/src/themes/theme-two/components/alert.css +0 -85
- package/src/themes/theme-two/components/badge.css +0 -101
- package/src/themes/theme-two/components/button-group.css +0 -50
- package/src/themes/theme-two/components/button.css +0 -229
- package/src/themes/theme-two/components/card.css +0 -82
- package/src/themes/theme-two/components/checkbox-radio.css +0 -123
- package/src/themes/theme-two/components/chip.css +0 -135
- package/src/themes/theme-two/components/divider.css +0 -7
- package/src/themes/theme-two/components/field-group.css +0 -83
- package/src/themes/theme-two/components/field.css +0 -281
- package/src/themes/theme-two/components/icon-button.css +0 -40
- package/src/themes/theme-two/components/progress.css +0 -83
- package/src/themes/theme-two/components/range.css +0 -121
- package/src/themes/theme-two/components/rich-text.css +0 -210
- package/src/themes/theme-two/components/snackbar.css +0 -148
- package/src/themes/theme-two/components/tab-buttons.css +0 -120
- package/src/themes/theme-two/components/table.css +0 -99
- package/src/themes/theme-two/components/text-field.css +0 -57
- package/src/themes/theme-two/components/toggle-button-group.css +0 -135
- package/src/themes/theme-two/components/tooltip.css +0 -94
- package/src/themes/theme-two/components/typography.css +0 -209
- package/src/themes/theme-two/theme.css +0 -158
|
@@ -1,281 +0,0 @@
|
|
|
1
|
-
@layer components.extended {
|
|
2
|
-
/*
|
|
3
|
-
- Common styling for input, textarea and select
|
|
4
|
-
- Form related styles such as: label, supporting text, error handling
|
|
5
|
-
*/
|
|
6
|
-
:where(.field) {
|
|
7
|
-
--_accent-color: var(--primary);
|
|
8
|
-
--_bg-color: var(--surface-default);
|
|
9
|
-
--_border-color: var(--field-border-color);
|
|
10
|
-
--_field-padding-block: 0.75rem;
|
|
11
|
-
--_field-padding-inline: var(--size-2);
|
|
12
|
-
--_filled-border-color: var(--text-color-1);
|
|
13
|
-
--_height: var(--field-size);
|
|
14
|
-
--_label-color: var(--text-color-2);
|
|
15
|
-
--_supporting-text-color: var(--text-color-2);
|
|
16
|
-
|
|
17
|
-
display: grid;
|
|
18
|
-
position: relative;
|
|
19
|
-
|
|
20
|
-
/* Input/Select base */
|
|
21
|
-
:where(& input, & textarea, & select) {
|
|
22
|
-
background-color: var(--_bg-color);
|
|
23
|
-
block-size: var(--_height);
|
|
24
|
-
border-radius: var(--field-border-radius);
|
|
25
|
-
border: var(--field-border-width) solid var(--_border-color);
|
|
26
|
-
color: var(--text-color-1);
|
|
27
|
-
font-family: var(--font-sans);
|
|
28
|
-
font-size: var(--font-size-1);
|
|
29
|
-
grid-column: 1/-1;
|
|
30
|
-
grid-row: 2;
|
|
31
|
-
inline-size: 100%;
|
|
32
|
-
line-height: var(--font-lineheight-1);
|
|
33
|
-
min-inline-size: 0;
|
|
34
|
-
padding: var(--_field-padding-block) var(--_field-padding-inline);
|
|
35
|
-
|
|
36
|
-
@media (prefers-reduced-motion: no-preference) {
|
|
37
|
-
transition: border-color 0.2s cubic-bezier(0.4, 0, 0.2, 1),
|
|
38
|
-
padding-block 0.2s var(--ease-3);
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
/* Required/Invalid */
|
|
43
|
-
&:has(
|
|
44
|
-
:not(:placeholder-shown):invalid,
|
|
45
|
-
:where(
|
|
46
|
-
:placeholder-shown,
|
|
47
|
-
option[value=""]:not(:checked),
|
|
48
|
-
option:checked:not([value=""])
|
|
49
|
-
):required
|
|
50
|
-
) {
|
|
51
|
-
.label:after {
|
|
52
|
-
color: var(--red);
|
|
53
|
-
content: "*";
|
|
54
|
-
margin: -0.25em auto auto 0.25em;
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
/* File */
|
|
59
|
-
&:has(input[type="file"]) {
|
|
60
|
-
cursor: pointer;
|
|
61
|
-
|
|
62
|
-
input {
|
|
63
|
-
align-self: flex-start;
|
|
64
|
-
block-size: var(--_height);
|
|
65
|
-
box-shadow: none;
|
|
66
|
-
color: var(--text-color-1);
|
|
67
|
-
cursor: inherit;
|
|
68
|
-
max-inline-size: 100%;
|
|
69
|
-
padding: 0;
|
|
70
|
-
transition: font-size 0.2s var(--ease-3);
|
|
71
|
-
|
|
72
|
-
&::-webkit-file-upload-button,
|
|
73
|
-
&::file-selector-button {
|
|
74
|
-
background-color: var(--surface-tonal);
|
|
75
|
-
border: none;
|
|
76
|
-
block-size: calc(100% - var(--size-2) * 2);
|
|
77
|
-
border-radius: var(--field-border-radius);
|
|
78
|
-
cursor: pointer;
|
|
79
|
-
margin-inline-end: 1ex;
|
|
80
|
-
margin-block-start: var(--size-2);
|
|
81
|
-
margin-inline-start: var(--size-2);
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
/* Variants */
|
|
86
|
-
&.filled {
|
|
87
|
-
input {
|
|
88
|
-
&::-webkit-file-upload-button,
|
|
89
|
-
&::file-selector-button {
|
|
90
|
-
background-color: var(--surface-default);
|
|
91
|
-
block-size: calc(100% - var(--size-2) * 2);
|
|
92
|
-
border-radius: var(--field-border-radius);
|
|
93
|
-
cursor: pointer;
|
|
94
|
-
margin-block-start: var(--size-2);
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
}
|
|
98
|
-
|
|
99
|
-
/* Sizes */
|
|
100
|
-
&.small {
|
|
101
|
-
input {
|
|
102
|
-
font-size: var(--font-size-sm);
|
|
103
|
-
&::-webkit-file-upload-button,
|
|
104
|
-
&::file-selector-button {
|
|
105
|
-
block-size: calc(100% - var(--size-2));
|
|
106
|
-
margin-block-start: var(--size-1);
|
|
107
|
-
}
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
/* Autosuggest */
|
|
113
|
-
&:has(input[list]) {
|
|
114
|
-
.label {
|
|
115
|
-
/* Make sure chevron is visible */
|
|
116
|
-
inline-size: calc(100% - var(--size-6));
|
|
117
|
-
}
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
/* Select */
|
|
121
|
-
&:has(select) {
|
|
122
|
-
.label {
|
|
123
|
-
/* Make sure chevron is visible */
|
|
124
|
-
inline-size: calc(100% - var(--size-6));
|
|
125
|
-
}
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
/* Experimental Select */
|
|
129
|
-
&:has(select button) {
|
|
130
|
-
select {
|
|
131
|
-
padding: 0;
|
|
132
|
-
|
|
133
|
-
button {
|
|
134
|
-
outline: 0;
|
|
135
|
-
padding: var(--_field-padding-block) var(--size-8)
|
|
136
|
-
var(--_field-padding-block) var(--_field-padding-inline);
|
|
137
|
-
}
|
|
138
|
-
}
|
|
139
|
-
}
|
|
140
|
-
|
|
141
|
-
/* Non-experimental Select */
|
|
142
|
-
&:has(select):not(:has(button)) {
|
|
143
|
-
select {
|
|
144
|
-
padding: var(--_field-padding-block) var(--size-8)
|
|
145
|
-
var(--_field-padding-block) var(--_field-padding-inline);
|
|
146
|
-
}
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
/* Input - color */
|
|
150
|
-
&:has(input[type="color"]) {
|
|
151
|
-
input {
|
|
152
|
-
appearance: none;
|
|
153
|
-
background: none;
|
|
154
|
-
block-size: var(--_height);
|
|
155
|
-
inline-size: var(--_height);
|
|
156
|
-
overflow: hidden;
|
|
157
|
-
padding: 0;
|
|
158
|
-
|
|
159
|
-
&::-webkit-color-swatch {
|
|
160
|
-
border: none;
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
&::-webkit-color-swatch-wrapper {
|
|
164
|
-
padding: 0;
|
|
165
|
-
}
|
|
166
|
-
}
|
|
167
|
-
}
|
|
168
|
-
|
|
169
|
-
/* Element states */
|
|
170
|
-
&:hover {
|
|
171
|
-
&:not(.error) {
|
|
172
|
-
:where(input, textarea, select) {
|
|
173
|
-
--_border-color: var(--text-color-1);
|
|
174
|
-
}
|
|
175
|
-
}
|
|
176
|
-
}
|
|
177
|
-
|
|
178
|
-
&:focus-within {
|
|
179
|
-
& input,
|
|
180
|
-
& textarea,
|
|
181
|
-
& select {
|
|
182
|
-
border-color: var(--_accent-color);
|
|
183
|
-
outline-offset: -2px;
|
|
184
|
-
outline: 2px solid var(--_accent-color);
|
|
185
|
-
}
|
|
186
|
-
}
|
|
187
|
-
|
|
188
|
-
/* Label */
|
|
189
|
-
.label {
|
|
190
|
-
font-size: var(--font-size-sm);
|
|
191
|
-
grid-column: 1/-1;
|
|
192
|
-
grid-row: 1;
|
|
193
|
-
}
|
|
194
|
-
|
|
195
|
-
/* Supporting text */
|
|
196
|
-
.supporting-text {
|
|
197
|
-
color: var(--_supporting-text-color);
|
|
198
|
-
font-size: var(--font-size-xs);
|
|
199
|
-
grid-column: 1/-1;
|
|
200
|
-
grid-row: 3;
|
|
201
|
-
line-height: 1.5;
|
|
202
|
-
}
|
|
203
|
-
|
|
204
|
-
/* Auto-fit */
|
|
205
|
-
&.auto-fit {
|
|
206
|
-
inline-size: auto;
|
|
207
|
-
|
|
208
|
-
:where(& input, & textarea) {
|
|
209
|
-
field-sizing: content;
|
|
210
|
-
inline-size: auto;
|
|
211
|
-
}
|
|
212
|
-
}
|
|
213
|
-
|
|
214
|
-
/* Validation */
|
|
215
|
-
&.error {
|
|
216
|
-
--_accent-color: var(--color-9);
|
|
217
|
-
--_border-color: var(--color-9);
|
|
218
|
-
--_filled-border-color: var(--color-9);
|
|
219
|
-
--_label-color: var(--color-9);
|
|
220
|
-
--_supporting-text-color: var(--color-9);
|
|
221
|
-
}
|
|
222
|
-
|
|
223
|
-
/*
|
|
224
|
-
* Variant: Filled
|
|
225
|
-
*/
|
|
226
|
-
&.filled {
|
|
227
|
-
--_bg-color: var(--surface-tonal);
|
|
228
|
-
|
|
229
|
-
&:not(:has([disabled], :has(input[type="color"]))) {
|
|
230
|
-
/* Hover */
|
|
231
|
-
&:hover {
|
|
232
|
-
--_bg-color: light-dark(
|
|
233
|
-
oklch(from var(--surface-tonal) calc(l * 0.93) c h),
|
|
234
|
-
oklch(from var(--surface-tonal) calc(l * 1.1) c h)
|
|
235
|
-
);
|
|
236
|
-
}
|
|
237
|
-
}
|
|
238
|
-
}
|
|
239
|
-
|
|
240
|
-
/* Disabled */
|
|
241
|
-
&:where(:has([disabled])) {
|
|
242
|
-
&::before {
|
|
243
|
-
display: none;
|
|
244
|
-
}
|
|
245
|
-
:where(input, textarea, select) {
|
|
246
|
-
cursor: not-allowed;
|
|
247
|
-
opacity: 0.7;
|
|
248
|
-
|
|
249
|
-
* {
|
|
250
|
-
pointer-events: none;
|
|
251
|
-
}
|
|
252
|
-
}
|
|
253
|
-
}
|
|
254
|
-
|
|
255
|
-
/* Read-only */
|
|
256
|
-
&:where(:has([readonly])) {
|
|
257
|
-
&::before {
|
|
258
|
-
display: none;
|
|
259
|
-
}
|
|
260
|
-
:where(input, textarea, select) {
|
|
261
|
-
cursor: not-allowed;
|
|
262
|
-
|
|
263
|
-
* {
|
|
264
|
-
pointer-events: none;
|
|
265
|
-
}
|
|
266
|
-
}
|
|
267
|
-
}
|
|
268
|
-
|
|
269
|
-
/* Sizes */
|
|
270
|
-
&.small {
|
|
271
|
-
--_field-padding-block: var(--size-2);
|
|
272
|
-
--_height: var(--field-size-small);
|
|
273
|
-
|
|
274
|
-
&:has(input[type="color"]) {
|
|
275
|
-
.label {
|
|
276
|
-
line-height: 1.5;
|
|
277
|
-
}
|
|
278
|
-
}
|
|
279
|
-
}
|
|
280
|
-
}
|
|
281
|
-
}
|
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
@layer components.root {
|
|
2
|
-
:where(.icon-button) {
|
|
3
|
-
--_text-color: inherit;
|
|
4
|
-
|
|
5
|
-
align-items: center;
|
|
6
|
-
aspect-ratio: 1;
|
|
7
|
-
background-color: transparent;
|
|
8
|
-
border: 0;
|
|
9
|
-
border-radius: var(--radius-round);
|
|
10
|
-
display: inline-flex;
|
|
11
|
-
inline-size: var(--size-6);
|
|
12
|
-
justify-content: center;
|
|
13
|
-
padding: 0;
|
|
14
|
-
transform-style: preserve-3d;
|
|
15
|
-
|
|
16
|
-
&:where([disabled]) {
|
|
17
|
-
color: light-dark(rgb(0, 0, 0/0.3), rgb(255, 255, 255/0.26));
|
|
18
|
-
cursor: not-allowed;
|
|
19
|
-
opacity: 0.64;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
svg {
|
|
23
|
-
max-inline-size: var(--size-5);
|
|
24
|
-
pointer-events: none;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
/* Ripple effect, utils.css */
|
|
28
|
-
&::before {
|
|
29
|
-
--highlight-size: 130%;
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
/* Size */
|
|
33
|
-
&.small {
|
|
34
|
-
inline-size: var(--size-4);
|
|
35
|
-
svg {
|
|
36
|
-
max-inline-size: var(--size-4);
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
}
|
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
@layer components.root {
|
|
2
|
-
:where(progress) {
|
|
3
|
-
--_accent-color: var(--primary);
|
|
4
|
-
--_bg-color: var(--surface-tonal);
|
|
5
|
-
|
|
6
|
-
appearance: none;
|
|
7
|
-
background-color: var(--_bg-color);
|
|
8
|
-
border-radius: var(--border-radius, 0.25rem);
|
|
9
|
-
border: 0;
|
|
10
|
-
display: inline-block;
|
|
11
|
-
block-size: var(--size-1);
|
|
12
|
-
overflow: hidden;
|
|
13
|
-
position: relative;
|
|
14
|
-
vertical-align: baseline;
|
|
15
|
-
inline-size: 100%;
|
|
16
|
-
|
|
17
|
-
&::-webkit-progress-bar {
|
|
18
|
-
border-radius: var(--border-radius, 0.25rem);
|
|
19
|
-
background: none;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
&[value]::-webkit-progress-value {
|
|
23
|
-
background-color: var(--_accent-color);
|
|
24
|
-
|
|
25
|
-
@media (prefers-reduced-motion: no-preference) {
|
|
26
|
-
transition: inline-size 0.2s
|
|
27
|
-
var(--ease-out-4, cubic-bezier(0, 0, 0.1, 1));
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
&::-moz-progress-bar {
|
|
32
|
-
background-color: var(--_accent-color);
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
@media (prefers-reduced-motion: no-preference) {
|
|
37
|
-
progress:indeterminate {
|
|
38
|
-
background-color: var(--_bg-color);
|
|
39
|
-
|
|
40
|
-
&::after {
|
|
41
|
-
animation: indeterminate 2s linear infinite;
|
|
42
|
-
background-color: var(--_accent-color);
|
|
43
|
-
content: "";
|
|
44
|
-
inset: 0 auto 0 0;
|
|
45
|
-
position: absolute;
|
|
46
|
-
will-change: inset-inline-start, inset-inline-end;
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
&[value]::-webkit-progress-value {
|
|
50
|
-
background-color: transparent;
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
&::-moz-progress-bar {
|
|
54
|
-
background-color: transparent;
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
[dir="rtl"] {
|
|
59
|
-
:where(progress):indeterminate {
|
|
60
|
-
animation-direction: reverse;
|
|
61
|
-
|
|
62
|
-
&::after {
|
|
63
|
-
animation-direction: reverse;
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
@keyframes indeterminate {
|
|
70
|
-
0% {
|
|
71
|
-
left: -200%;
|
|
72
|
-
right: 100%;
|
|
73
|
-
}
|
|
74
|
-
60% {
|
|
75
|
-
left: 107%;
|
|
76
|
-
right: -8%;
|
|
77
|
-
}
|
|
78
|
-
100% {
|
|
79
|
-
left: 107%;
|
|
80
|
-
right: -8%;
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
}
|
|
@@ -1,121 +0,0 @@
|
|
|
1
|
-
@layer components.root {
|
|
2
|
-
:where(.range > input[type="range"]) {
|
|
3
|
-
--thumb-bg: var(--primary);
|
|
4
|
-
--thumb-highlight-color: oklch(from var(--primary) 70% 100% h / 20%);
|
|
5
|
-
--thumb-highlight-size: 0px;
|
|
6
|
-
--thumb-offset: -1ex;
|
|
7
|
-
--thumb-size: 3ex;
|
|
8
|
-
--track-color: var(--field-border-color);
|
|
9
|
-
--track-fill: 0%;
|
|
10
|
-
--track-height: 1ex;
|
|
11
|
-
|
|
12
|
-
appearance: none;
|
|
13
|
-
background: transparent;
|
|
14
|
-
display: block;
|
|
15
|
-
inline-size: 100%;
|
|
16
|
-
margin: 1ex 0 3ex;
|
|
17
|
-
outline-offset: 1ex;
|
|
18
|
-
|
|
19
|
-
@media (hover: none) {
|
|
20
|
-
--thumb-offset: -14px;
|
|
21
|
-
--thumb-size: 30px;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
/* Track */
|
|
25
|
-
&::-webkit-slider-runnable-track {
|
|
26
|
-
appearance: none;
|
|
27
|
-
background: linear-gradient(
|
|
28
|
-
to right,
|
|
29
|
-
transparent var(--track-fill),
|
|
30
|
-
var(--track-color) 0%
|
|
31
|
-
),
|
|
32
|
-
var(--primary);
|
|
33
|
-
block-size: var(--track-height);
|
|
34
|
-
border-radius: 5ex;
|
|
35
|
-
box-shadow: var(--inner-shadow-1);
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
&::-moz-range-track {
|
|
39
|
-
appearance: none;
|
|
40
|
-
background: linear-gradient(
|
|
41
|
-
to right,
|
|
42
|
-
transparent var(--track-fill),
|
|
43
|
-
var(--track-color) 0%
|
|
44
|
-
),
|
|
45
|
-
var(--primary);
|
|
46
|
-
block-size: var(--track-height);
|
|
47
|
-
border-radius: 5ex;
|
|
48
|
-
box-shadow: var(--inner-shadow-2);
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
/* Ring */
|
|
52
|
-
&::-webkit-slider-thumb {
|
|
53
|
-
appearance: none;
|
|
54
|
-
background: var(--thumb-bg);
|
|
55
|
-
block-size: var(--thumb-size);
|
|
56
|
-
border-radius: 50%;
|
|
57
|
-
border: 3px solid var(--surface-default);
|
|
58
|
-
box-shadow: 0 0 0 var(--thumb-highlight-size) var(--thumb-highlight-color);
|
|
59
|
-
cursor: ew-resize;
|
|
60
|
-
inline-size: var(--thumb-size);
|
|
61
|
-
margin-block-start: var(--thumb-offset);
|
|
62
|
-
|
|
63
|
-
@media (prefers-reduced-motion: no-preference) {
|
|
64
|
-
transition: box-shadow 0.1s ease;
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
.fieldset-item:focus-within & {
|
|
68
|
-
border-color: var(--gray-14);
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
&::-moz-range-thumb {
|
|
73
|
-
appearance: none;
|
|
74
|
-
background: var(--thumb-bg);
|
|
75
|
-
block-size: var(--thumb-size);
|
|
76
|
-
border-radius: 50%;
|
|
77
|
-
border: 3px solid var(--primary);
|
|
78
|
-
box-shadow: 0 0 0 var(--thumb-highlight-size) var(--thumb-highlight-color);
|
|
79
|
-
cursor: ew-resize;
|
|
80
|
-
inline-size: var(--thumb-size);
|
|
81
|
-
margin-block-start: var(--thumb-offset);
|
|
82
|
-
|
|
83
|
-
@media (prefers-reduced-motion: no-preference) {
|
|
84
|
-
transition: box-shadow 0.1s ease;
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
.fieldset-item:focus-within & {
|
|
88
|
-
border-color: var(--gray-14);
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
/* Element state */
|
|
93
|
-
&:not([disabled]) {
|
|
94
|
-
&:hover {
|
|
95
|
-
--thumb-highlight-size: var(--size-1);
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
&:active {
|
|
99
|
-
--thumb-highlight-size: var(--size-2);
|
|
100
|
-
--track-color: light-dark(
|
|
101
|
-
oklch(from var(--field-border-color) calc(l * 0.9) c h),
|
|
102
|
-
oklch(from var(--field-border-color) calc(l * 1.1) c h)
|
|
103
|
-
);
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
&[disabled] {
|
|
108
|
-
--thumb-bg: oklch(from var(--text-color-1) l c h / 50%);
|
|
109
|
-
--track-color: var(--field-border-color);
|
|
110
|
-
|
|
111
|
-
cursor: not-allowed;
|
|
112
|
-
|
|
113
|
-
&::-webkit-slider-thumb {
|
|
114
|
-
cursor: not-allowed;
|
|
115
|
-
}
|
|
116
|
-
&::-moz-range-thumb {
|
|
117
|
-
cursor: not-allowed;
|
|
118
|
-
}
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
}
|