opui-css 5.0.0 → 5.1.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 +317 -276
- package/LICENSE +21 -21
- package/MIGRATING.md +138 -127
- package/README.md +87 -87
- package/astro/index.ts +46 -46
- package/components/AGENTS.md +248 -248
- package/components/Accordion/Accordion.astro +52 -42
- package/components/Anchor/Anchor.astro +55 -51
- package/components/Avatar/Avatar.astro +38 -38
- package/components/Badge/Badge.astro +59 -59
- package/components/Button/Button.astro +45 -45
- package/components/ButtonGroup/ButtonGroup.astro +36 -29
- package/components/Callout/Callout.astro +75 -75
- package/components/Card/Card.astro +38 -36
- package/components/Checkbox/Checkbox.astro +76 -76
- package/components/Checkbox/CheckboxInput.astro +32 -32
- package/components/Chip/Chip.astro +37 -37
- package/components/ClassicSelect/ClassicSelect.astro +83 -83
- package/components/DescriptionList/Description.astro +12 -12
- package/components/DescriptionList/DescriptionList.astro +22 -22
- package/components/DescriptionList/Item.astro +12 -12
- package/components/DescriptionList/Term.astro +12 -12
- package/components/DescriptionList/index.ts +12 -12
- package/components/Dialog/Dialog.astro +43 -41
- package/components/Divider/Divider.astro +17 -17
- package/components/Drawer/Drawer.astro +49 -49
- package/components/Drawer/DrawerFooter.astro +14 -14
- package/components/Drawer/DrawerHeader.astro +31 -31
- package/components/FieldDescription/FieldDescription.astro +13 -13
- package/components/FieldGroup/FieldGroup.astro +31 -31
- package/components/FieldLegend/FieldLegend.astro +15 -15
- package/components/FieldSet/FieldSet.astro +15 -15
- package/components/Form/Form.astro +15 -15
- package/components/IconButton/IconButton.astro +26 -26
- package/components/List/List.astro +36 -36
- package/components/ListItem/ListItem.astro +118 -118
- package/components/Progress/Progress.astro +41 -40
- package/components/Radio/Radio.astro +70 -70
- package/components/Radio/RadioInput.astro +24 -24
- package/components/Range/Range.astro +136 -136
- package/components/Select/Select.astro +106 -106
- package/components/Switch/Switch.astro +101 -101
- package/components/Switch/SwitchInput.astro +25 -25
- package/components/Table/Body.astro +13 -13
- package/components/Table/Cell.astro +13 -13
- package/components/Table/Column.astro +15 -15
- package/components/Table/ColumnGroup.astro +13 -13
- package/components/Table/Head.astro +13 -13
- package/components/Table/HeaderCell.astro +13 -13
- package/components/Table/Row.astro +13 -13
- package/components/Table/Table.astro +18 -18
- package/components/Table/index.ts +20 -20
- package/components/Tabs/Tabs.astro +28 -28
- package/components/Tabs/TabsItem.astro +47 -47
- package/components/Tabs/TabsPanel.astro +21 -21
- package/components/Tabs/TabsTab.astro +19 -19
- package/components/Tabs/index.ts +14 -14
- package/components/TextField/TextField.astro +128 -128
- package/components/Textarea/Textarea.astro +106 -106
- package/components/Toast/Toast.astro +42 -42
- package/components/ToggleButton/ToggleButton.astro +53 -53
- package/components/ToggleGroup/ToggleGroup.astro +49 -49
- package/components/Tooltip/Tooltip.astro +30 -30
- package/core/normalize.css +200 -194
- package/core/palette.css +110 -59
- package/core/utils.css +71 -71
- package/css/components/accordion.css +174 -174
- package/css/components/anchor.css +27 -27
- package/css/components/avatar.css +65 -65
- package/css/components/badge.css +107 -107
- package/css/components/button-group.css +193 -179
- package/css/components/button.css +227 -215
- package/css/components/callout.css +112 -109
- package/css/components/card.css +115 -117
- package/css/components/checkbox.css +211 -205
- package/css/components/chip.css +92 -87
- package/css/components/description-list.css +81 -80
- package/css/components/dialog.css +69 -68
- package/css/components/divider.css +20 -20
- package/css/components/drawer.css +171 -171
- package/css/components/form.css +147 -146
- package/css/components/icon-button.css +158 -139
- package/css/components/link.css +21 -21
- package/css/components/list.css +343 -345
- package/css/components/progress.css +103 -97
- package/css/components/radio.css +170 -172
- package/css/components/range.css +342 -337
- package/css/components/select.css +172 -169
- package/css/components/spinner.css +38 -37
- package/css/components/switch.css +271 -268
- package/css/components/table.css +173 -179
- package/css/components/tabs.css +84 -83
- package/css/components/text-field.css +449 -450
- package/css/components/text-input.css +68 -64
- package/css/components/textarea.css +26 -24
- package/css/components/toast.css +160 -161
- package/css/components/toggle-button.css +91 -87
- package/css/components/toggle-group.css +56 -56
- package/css/components/tooltip.css +70 -67
- package/css/components/typography.css +585 -585
- package/css/components.css +41 -41
- package/css/imports.css +17 -16
- package/css/js/checkbox.js +21 -21
- package/css/js/toast.js +94 -94
- package/css/theme.css +133 -132
- package/dist/op.css +4 -66
- package/dist/op.css.map +1 -1
- package/dist/opui.components.css +5234 -5154
- package/dist/opui.components.css.map +1 -1
- package/dist/opui.css +5798 -5663
- package/dist/opui.css.map +1 -1
- package/env.d.ts +14 -14
- package/open-props.css +8 -9
- package/package.json +81 -81
|
@@ -1,80 +1,81 @@
|
|
|
1
|
-
@layer components.root {
|
|
2
|
-
:where(.ui-description-list) {
|
|
3
|
-
--_border-style: solid;
|
|
4
|
-
--_border-width: 1px;
|
|
5
|
-
|
|
6
|
-
display: grid;
|
|
7
|
-
gap: var(--size-3);
|
|
8
|
-
margin: 0;
|
|
9
|
-
padding: 0;
|
|
10
|
-
|
|
11
|
-
&.ui-dotted {
|
|
12
|
-
--_border-style: dotted;
|
|
13
|
-
--_border-width: 2px;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.ui-item {
|
|
17
|
-
display: grid;
|
|
18
|
-
margin: 0;
|
|
19
|
-
padding: 0;
|
|
20
|
-
|
|
21
|
-
dt,
|
|
22
|
-
.ui-term {
|
|
23
|
-
display: block;
|
|
24
|
-
font-weight: 700;
|
|
25
|
-
overflow: hidden;
|
|
26
|
-
position: relative;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
dd {
|
|
30
|
-
margin: 0;
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
@container (width > 45ch) {
|
|
35
|
-
gap: var(--size-1);
|
|
36
|
-
|
|
37
|
-
.ui-item {
|
|
38
|
-
align-items: baseline;
|
|
39
|
-
display: grid;
|
|
40
|
-
gap: var(--size-1);
|
|
41
|
-
grid-template-columns: 1fr auto;
|
|
42
|
-
|
|
43
|
-
dt,
|
|
44
|
-
.ui-term {
|
|
45
|
-
inline-size: max-content;
|
|
46
|
-
|
|
47
|
-
&::after {
|
|
48
|
-
display: inline-block;
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
dd {
|
|
53
|
-
color: var(--text-muted);
|
|
54
|
-
text-align: end;
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
&.ui-bordered .ui-item {
|
|
59
|
-
grid-template-columns: auto 1fr auto;
|
|
60
|
-
|
|
61
|
-
dt,
|
|
62
|
-
.ui-term {
|
|
63
|
-
order: 0;
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
dd {
|
|
67
|
-
order: 2;
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
&::after {
|
|
71
|
-
background-color: transparent;
|
|
72
|
-
block-size: 2px;
|
|
73
|
-
border-block-end: var(--_border-width) var(--_border-style)
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
}
|
|
1
|
+
@layer components.root {
|
|
2
|
+
:where(.ui-description-list) {
|
|
3
|
+
--_border-style: solid;
|
|
4
|
+
--_border-width: 1px;
|
|
5
|
+
|
|
6
|
+
display: grid;
|
|
7
|
+
gap: var(--size-3);
|
|
8
|
+
margin: 0;
|
|
9
|
+
padding: 0;
|
|
10
|
+
|
|
11
|
+
&.ui-dotted {
|
|
12
|
+
--_border-style: dotted;
|
|
13
|
+
--_border-width: 2px;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.ui-item {
|
|
17
|
+
display: grid;
|
|
18
|
+
margin: 0;
|
|
19
|
+
padding: 0;
|
|
20
|
+
|
|
21
|
+
dt,
|
|
22
|
+
.ui-term {
|
|
23
|
+
display: block;
|
|
24
|
+
font-weight: 700;
|
|
25
|
+
overflow: hidden;
|
|
26
|
+
position: relative;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
dd {
|
|
30
|
+
margin: 0;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
@container (width > 45ch) {
|
|
35
|
+
gap: var(--size-1);
|
|
36
|
+
|
|
37
|
+
.ui-item {
|
|
38
|
+
align-items: baseline;
|
|
39
|
+
display: grid;
|
|
40
|
+
gap: var(--size-1);
|
|
41
|
+
grid-template-columns: 1fr auto;
|
|
42
|
+
|
|
43
|
+
dt,
|
|
44
|
+
.ui-term {
|
|
45
|
+
inline-size: max-content;
|
|
46
|
+
|
|
47
|
+
&::after {
|
|
48
|
+
display: inline-block;
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
dd {
|
|
53
|
+
color: var(--text-muted);
|
|
54
|
+
text-align: end;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
&.ui-bordered .ui-item {
|
|
59
|
+
grid-template-columns: auto 1fr auto;
|
|
60
|
+
|
|
61
|
+
dt,
|
|
62
|
+
.ui-term {
|
|
63
|
+
order: 0;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
dd {
|
|
67
|
+
order: 2;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
&::after {
|
|
71
|
+
background-color: transparent;
|
|
72
|
+
block-size: 2px;
|
|
73
|
+
border-block-end: var(--_border-width) var(--_border-style)
|
|
74
|
+
var(--border-color);
|
|
75
|
+
content: "";
|
|
76
|
+
order: 1;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
}
|
|
@@ -1,68 +1,69 @@
|
|
|
1
|
-
@layer components.extended {
|
|
2
|
-
:where(.ui-dialog) {
|
|
3
|
-
inline-size: 100%;
|
|
4
|
-
inset: 0;
|
|
5
|
-
margin: auto;
|
|
6
|
-
margin-block-start: 15%;
|
|
7
|
-
max-inline-size: calc(100% - var(--size-4));
|
|
8
|
-
padding-block: 0;
|
|
9
|
-
pointer-events: none;
|
|
10
|
-
position: fixed;
|
|
11
|
-
|
|
12
|
-
@media (width > 600px) {
|
|
13
|
-
max-inline-size: 60ch;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
/* Animation */
|
|
17
|
-
/* There's no close animation, intentionally */
|
|
18
|
-
opacity: 0;
|
|
19
|
-
|
|
20
|
-
&::backdrop {
|
|
21
|
-
backdrop-filter: blur(1px);
|
|
22
|
-
background-color: rgba(0, 0, 0, 0.5);
|
|
23
|
-
|
|
24
|
-
@media (prefers-reduced-motion: reduce) {
|
|
25
|
-
backdrop-filter: none;
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
&:not([open]) {
|
|
30
|
-
display: none;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
&[open] {
|
|
34
|
-
pointer-events: all;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
.ui-actions {
|
|
38
|
-
justify-content: end;
|
|
39
|
-
padding-inline: var(--size-3) var(--size-1);
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
&[open] {
|
|
43
|
-
opacity: 1;
|
|
44
|
-
transition:
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
}
|
|
1
|
+
@layer components.extended {
|
|
2
|
+
:where(.ui-dialog) {
|
|
3
|
+
inline-size: 100%;
|
|
4
|
+
inset: 0;
|
|
5
|
+
margin: auto;
|
|
6
|
+
margin-block-start: 15%;
|
|
7
|
+
max-inline-size: calc(100% - var(--size-4));
|
|
8
|
+
padding-block: 0;
|
|
9
|
+
pointer-events: none;
|
|
10
|
+
position: fixed;
|
|
11
|
+
|
|
12
|
+
@media (width > 600px) {
|
|
13
|
+
max-inline-size: 60ch;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
/* Animation */
|
|
17
|
+
/* There's no close animation, intentionally */
|
|
18
|
+
opacity: 0;
|
|
19
|
+
|
|
20
|
+
&::backdrop {
|
|
21
|
+
backdrop-filter: blur(1px);
|
|
22
|
+
background-color: rgba(0, 0, 0, 0.5);
|
|
23
|
+
|
|
24
|
+
@media (prefers-reduced-motion: reduce) {
|
|
25
|
+
backdrop-filter: none;
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
&:not([open]) {
|
|
30
|
+
display: none;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
&[open] {
|
|
34
|
+
pointer-events: all;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.ui-actions {
|
|
38
|
+
justify-content: end;
|
|
39
|
+
padding-inline: var(--size-3) var(--size-1);
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
&[open] {
|
|
43
|
+
opacity: 1;
|
|
44
|
+
transition:
|
|
45
|
+
display 0.2s allow-discrete,
|
|
46
|
+
overlay 0.2s allow-discrete,
|
|
47
|
+
opacity 0.2s var(--ease-out-1);
|
|
48
|
+
|
|
49
|
+
@starting-style {
|
|
50
|
+
opacity: 0;
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
@media (prefers-reduced-motion: no-preference) {
|
|
55
|
+
&[open] {
|
|
56
|
+
margin-block-start: 15%;
|
|
57
|
+
|
|
58
|
+
@starting-style {
|
|
59
|
+
opacity: 0;
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
:where(html:has(.ui-dialog[open])) {
|
|
66
|
+
block-size: 100%;
|
|
67
|
+
overflow: hidden;
|
|
68
|
+
}
|
|
69
|
+
}
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
@layer components.root {
|
|
2
|
-
:where(.ui-divider) {
|
|
3
|
-
background-color: var(--border-color);
|
|
4
|
-
block-size: var(--border-size-1);
|
|
5
|
-
margin-block: var(--size-fluid-3);
|
|
6
|
-
|
|
7
|
-
/* Border color */
|
|
8
|
-
&.ui-border-filled {
|
|
9
|
-
background-color: var(--surface-filled);
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
&.ui-border-primary {
|
|
13
|
-
background-color: var(--primary);
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
&.ui-border-tonal {
|
|
17
|
-
background-color: var(--surface-tonal);
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
}
|
|
1
|
+
@layer components.root {
|
|
2
|
+
:where(.ui-divider) {
|
|
3
|
+
background-color: var(--border-color);
|
|
4
|
+
block-size: var(--border-size-1);
|
|
5
|
+
margin-block: var(--size-fluid-3);
|
|
6
|
+
|
|
7
|
+
/* Border color */
|
|
8
|
+
&.ui-border-filled {
|
|
9
|
+
background-color: var(--surface-filled);
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
&.ui-border-primary {
|
|
13
|
+
background-color: var(--primary);
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
&.ui-border-tonal {
|
|
17
|
+
background-color: var(--surface-tonal);
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
}
|
|
@@ -1,171 +1,171 @@
|
|
|
1
|
-
@layer components.root {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
This carve-out re-enables page scrolling when a transparent-backdrop drawer is
|
|
161
|
-
open on wide viewports (where the drawer doesn't visually cover the page). */
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
}
|
|
1
|
+
@layer components.root {
|
|
2
|
+
:where(dialog.ui-drawer) {
|
|
3
|
+
--_backdrop-bg-color: transparent;
|
|
4
|
+
--_backdrop-blur: blur(2px);
|
|
5
|
+
--_bg-color: var(--surface-default);
|
|
6
|
+
--_block-size: min(80vb, 650px);
|
|
7
|
+
--_border-color: var(--border-color);
|
|
8
|
+
--_border-width: var(--border-width);
|
|
9
|
+
--_color: var(--text-primary);
|
|
10
|
+
--_content-padding: var(--size-4);
|
|
11
|
+
--_footer-gap: var(--size-3);
|
|
12
|
+
--_footer-padding: var(--size-3);
|
|
13
|
+
--_header-font-size: var(--font-size-3);
|
|
14
|
+
--_header-padding: var(--size-3);
|
|
15
|
+
--_inline-size: min(375px, 100vi);
|
|
16
|
+
--_shadow: var(--shadow-2);
|
|
17
|
+
--_transition-duration: 0.2s;
|
|
18
|
+
--_transition-timing: var(--ease-out-3);
|
|
19
|
+
|
|
20
|
+
background-color: var(--_bg-color);
|
|
21
|
+
border: none;
|
|
22
|
+
box-shadow: var(--_shadow);
|
|
23
|
+
color: var(--_color);
|
|
24
|
+
display: flex;
|
|
25
|
+
flex-direction: column;
|
|
26
|
+
margin: 0;
|
|
27
|
+
max-inline-size: 100%;
|
|
28
|
+
padding: 0;
|
|
29
|
+
position: fixed;
|
|
30
|
+
transition:
|
|
31
|
+
display var(--_transition-duration) allow-discrete,
|
|
32
|
+
overlay var(--_transition-duration) allow-discrete,
|
|
33
|
+
translate var(--_transition-duration) var(--_transition-timing);
|
|
34
|
+
z-index: 1000;
|
|
35
|
+
|
|
36
|
+
&::backdrop {
|
|
37
|
+
backdrop-filter: var(--_backdrop-blur);
|
|
38
|
+
background-color: var(--_backdrop-bg-color);
|
|
39
|
+
opacity: 0;
|
|
40
|
+
transition:
|
|
41
|
+
display var(--_transition-duration) allow-discrete,
|
|
42
|
+
overlay var(--_transition-duration) allow-discrete,
|
|
43
|
+
opacity var(--_transition-duration) var(--_transition-timing);
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
&.ui-backdrop-transparent {
|
|
47
|
+
--_backdrop-blur: none;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.ui-header {
|
|
51
|
+
align-items: center;
|
|
52
|
+
border-block-end: var(--_border-width) solid var(--_border-color);
|
|
53
|
+
display: flex;
|
|
54
|
+
padding: var(--_header-padding);
|
|
55
|
+
|
|
56
|
+
:where(h1, h2, h3, h4, h5, h6) {
|
|
57
|
+
font-size: var(--_header-font-size);
|
|
58
|
+
margin: 0;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
:where(.ui-icon-button) {
|
|
62
|
+
margin-inline-start: auto;
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
.ui-content {
|
|
67
|
+
flex: 1;
|
|
68
|
+
overflow-y: auto;
|
|
69
|
+
padding: var(--_content-padding);
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
.ui-footer {
|
|
73
|
+
border-block-start: var(--_border-width) solid var(--_border-color);
|
|
74
|
+
display: flex;
|
|
75
|
+
gap: var(--_footer-gap);
|
|
76
|
+
justify-content: end;
|
|
77
|
+
padding: var(--_footer-padding);
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
&.ui-inline-start,
|
|
81
|
+
&.ui-inline-end {
|
|
82
|
+
block-size: 100dvb;
|
|
83
|
+
inline-size: var(--_inline-size);
|
|
84
|
+
inset-block: 0;
|
|
85
|
+
max-block-size: 100%;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
&.ui-inline-start {
|
|
89
|
+
border-inline-end: var(--_border-width) solid var(--_border-color);
|
|
90
|
+
inset-inline-end: auto;
|
|
91
|
+
inset-inline-start: 0;
|
|
92
|
+
translate: -100% 0;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
&.ui-inline-end {
|
|
96
|
+
border-inline-start: var(--_border-width) solid var(--_border-color);
|
|
97
|
+
inset-inline-end: 0;
|
|
98
|
+
inset-inline-start: auto;
|
|
99
|
+
translate: 100% 0;
|
|
100
|
+
|
|
101
|
+
.ui-footer {
|
|
102
|
+
justify-content: start;
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
&.ui-block-start,
|
|
107
|
+
&.ui-block-end {
|
|
108
|
+
block-size: var(--_block-size);
|
|
109
|
+
inline-size: 100dvi;
|
|
110
|
+
inset-inline: 0;
|
|
111
|
+
max-block-size: 80dvb;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
&.ui-block-start {
|
|
115
|
+
border-block-end: var(--_border-width) solid var(--_border-color);
|
|
116
|
+
inset-block-end: auto;
|
|
117
|
+
inset-block-start: 0;
|
|
118
|
+
translate: 0 -100%;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
&.ui-block-end {
|
|
122
|
+
border-block-start: var(--_border-width) solid var(--_border-color);
|
|
123
|
+
inset-block-end: 0;
|
|
124
|
+
inset-block-start: auto;
|
|
125
|
+
translate: 0 100%;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
&[open] {
|
|
129
|
+
translate: 0 0;
|
|
130
|
+
|
|
131
|
+
&::backdrop {
|
|
132
|
+
opacity: 1;
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
@starting-style {
|
|
136
|
+
&::backdrop {
|
|
137
|
+
opacity: 0;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
&.ui-inline-start {
|
|
141
|
+
translate: -100% 0;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
&.ui-inline-end {
|
|
145
|
+
translate: 100% 0;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
&.ui-block-start {
|
|
149
|
+
translate: 0 -100%;
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
&.ui-block-end {
|
|
153
|
+
translate: 0 100%;
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
/* Scroll-lock is provided by the shared `.ui-scroll-lock` utility in core/utils.css.
|
|
160
|
+
This carve-out re-enables page scrolling when a transparent-backdrop drawer is
|
|
161
|
+
open on wide viewports (where the drawer doesn't visually cover the page). */
|
|
162
|
+
html:has(dialog.ui-drawer.ui-scroll-lock[open].ui-backdrop-transparent) {
|
|
163
|
+
overflow: unset;
|
|
164
|
+
overscroll-behavior: auto;
|
|
165
|
+
|
|
166
|
+
@media (width < 500px) {
|
|
167
|
+
overflow: clip;
|
|
168
|
+
overscroll-behavior: contain;
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
}
|