@robert-stackflow/oneui 0.6.7 → 0.6.16
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 +63 -0
- package/README.md +255 -188
- package/components/AccountItem.module.css +103 -103
- package/components/Alert.d.ts +2 -9
- package/components/Alert.js +2 -40
- package/components/AppShell.d.ts +7 -7
- package/components/AppShell.js +37 -33
- package/components/AppShell.module.css +223 -271
- package/components/AppearanceSettings.js +25 -32
- package/components/Badge.module.css +30 -30
- package/components/Banner.d.ts +17 -0
- package/components/Banner.js +99 -0
- package/components/Banner.module.css +143 -0
- package/components/BarChart.module.css +35 -34
- package/components/Breadcrumb.module.css +97 -97
- package/components/Button.module.css +120 -120
- package/components/Cascader.js +1 -0
- package/components/CharacterPicker.js +2 -0
- package/components/Checkbox.module.css +95 -95
- package/components/Combobox.js +1 -0
- package/components/Combobox.module.css +6 -1
- package/components/CommandPalette.js +2 -2
- package/components/ContributionCalendar.module.css +121 -121
- package/components/Control.module.css +86 -86
- package/components/DataTable.d.ts +3 -2
- package/components/DataTable.js +92 -66
- package/components/DataTable.module.css +3 -31
- package/components/DatePicker.js +1 -0
- package/components/DateRangePicker.js +1 -0
- package/components/Dialog.d.ts +3 -1
- package/components/Dialog.js +11 -4
- package/components/Dialog.module.css +139 -97
- package/components/DialogVariants.d.ts +2 -1
- package/components/DialogVariants.js +35 -7
- package/components/HierarchyPicker.module.css +185 -181
- package/components/IconPicker.js +2 -0
- package/components/Indicator.module.css +83 -83
- package/components/Layout.module.css +82 -82
- package/components/Markdown.d.ts +13 -0
- package/components/Markdown.js +164 -0
- package/components/Markdown.module.css +227 -0
- package/components/MenuItem.module.css +172 -172
- package/components/MultiSelect.js +1 -0
- package/components/MultiSelect.module.css +2 -0
- package/components/NavBar.d.ts +20 -0
- package/components/NavBar.js +197 -0
- package/components/NavBar.module.css +130 -0
- package/components/NavigationSurface.module.css +27 -0
- package/components/Picker.module.css +7 -0
- package/components/Popover.d.ts +6 -1
- package/components/Popover.js +39 -13
- package/components/Popover.module.css +8 -0
- package/components/Progress.module.css +33 -33
- package/components/RadioGroup.module.css +87 -87
- package/components/RangeSlider.module.css +141 -141
- package/components/ResizablePanel.module.css +101 -101
- package/components/ResourceCard.module.css +98 -98
- package/components/SelectSettingRow.d.ts +7 -0
- package/components/SelectSettingRow.js +58 -0
- package/components/SettingRow.d.ts +9 -3
- package/components/SettingRow.js +32 -8
- package/components/SettingRow.module.css +17 -0
- package/components/SettingsLayout.d.ts +15 -3
- package/components/SettingsLayout.js +46 -29
- package/components/SideBar.d.ts +9 -0
- package/components/SideBar.js +30 -0
- package/components/SidebarNavigation.d.ts +24 -3
- package/components/SidebarNavigation.js +274 -47
- package/components/SidebarNavigation.module.css +352 -130
- package/components/Slider.module.css +19 -19
- package/components/Steps.module.css +176 -176
- package/components/Switch.d.ts +3 -1
- package/components/Switch.js +5 -1
- package/components/Switch.module.css +59 -59
- package/components/SwitchSettingRow.d.ts +7 -0
- package/components/SwitchSettingRow.js +45 -0
- package/components/Tab.module.css +148 -148
- package/components/Table.d.ts +8 -1
- package/components/Table.js +34 -17
- package/components/Table.module.css +87 -48
- package/components/TableMarkup.d.ts +2 -1
- package/components/TableMarkup.js +18 -1
- package/components/TableOfContents.d.ts +22 -0
- package/components/TableOfContents.js +462 -0
- package/components/TableOfContents.module.css +252 -0
- package/components/TextAreaSettingRow.d.ts +9 -0
- package/components/TextAreaSettingRow.js +47 -0
- package/components/TextSettingRow.d.ts +9 -0
- package/components/TextSettingRow.js +45 -0
- package/components/ThemePicker.module.css +178 -178
- package/components/ThemeProvider.js +2 -0
- package/components/TimeColumns.module.css +47 -47
- package/components/Timeline.module.css +202 -202
- package/components/Toast.d.ts +8 -1
- package/components/Toast.js +49 -17
- package/components/Toast.module.css +25 -0
- package/components/ToastProvider.d.ts +4 -1
- package/components/ToastProvider.js +67 -12
- package/components/TreeSelect.js +1 -0
- package/components/TreeTable.d.ts +3 -3
- package/components/TreeTable.js +12 -2
- package/components/TreeTable.module.css +57 -53
- package/components/createToaster.d.ts +2 -1
- package/components/createToaster.js +28 -14
- package/components/index.d.ts +18 -1
- package/components/index.js +24 -0
- package/components/motion.d.ts +1 -0
- package/components/motion.js +18 -6
- package/components/settingRowControl.d.ts +7 -0
- package/components/settingRowControl.js +15 -0
- package/package.json +57 -3
- package/styles/base.css +206 -206
- package/styles/blue.css +270 -268
- package/styles/minimal.css +4 -25
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
.bar {
|
|
2
|
+
display: flex;
|
|
3
|
+
align-items: center;
|
|
4
|
+
gap: 24px;
|
|
5
|
+
min-width: 0;
|
|
6
|
+
min-height: 68px;
|
|
7
|
+
padding: 12px 24px;
|
|
8
|
+
color: var(--fg);
|
|
9
|
+
background: var(--surface);
|
|
10
|
+
border-bottom: 1px solid var(--line);
|
|
11
|
+
}
|
|
12
|
+
.brand {
|
|
13
|
+
display: inline-flex;
|
|
14
|
+
align-items: center;
|
|
15
|
+
gap: 10px;
|
|
16
|
+
flex-shrink: 0;
|
|
17
|
+
color: var(--fg);
|
|
18
|
+
text-decoration: none;
|
|
19
|
+
font-weight: 600;
|
|
20
|
+
}
|
|
21
|
+
.brand > svg {
|
|
22
|
+
width: 24px;
|
|
23
|
+
height: 24px;
|
|
24
|
+
color: var(--accent-ink, var(--accent));
|
|
25
|
+
}
|
|
26
|
+
.links {
|
|
27
|
+
display: flex;
|
|
28
|
+
align-items: center;
|
|
29
|
+
justify-content: flex-end;
|
|
30
|
+
gap: 6px;
|
|
31
|
+
min-width: 0;
|
|
32
|
+
margin-left: auto;
|
|
33
|
+
}
|
|
34
|
+
.link,
|
|
35
|
+
.menuItem {
|
|
36
|
+
display: flex;
|
|
37
|
+
align-items: center;
|
|
38
|
+
justify-content: flex-start;
|
|
39
|
+
gap: 9px;
|
|
40
|
+
min-height: 38px;
|
|
41
|
+
padding: 8px 13px;
|
|
42
|
+
border: 0;
|
|
43
|
+
border-radius: 9px;
|
|
44
|
+
background: transparent;
|
|
45
|
+
color: var(--muted);
|
|
46
|
+
font: inherit;
|
|
47
|
+
font-size: 13px;
|
|
48
|
+
line-height: 1.5;
|
|
49
|
+
text-decoration: none;
|
|
50
|
+
white-space: nowrap;
|
|
51
|
+
cursor: pointer;
|
|
52
|
+
transition:
|
|
53
|
+
color var(--motion-hover),
|
|
54
|
+
background var(--motion-hover);
|
|
55
|
+
}
|
|
56
|
+
.link > svg,
|
|
57
|
+
.menuItem > svg {
|
|
58
|
+
flex-shrink: 0;
|
|
59
|
+
width: 17px;
|
|
60
|
+
height: 17px;
|
|
61
|
+
}
|
|
62
|
+
.link:hover:not(:disabled):not([aria-disabled]),
|
|
63
|
+
.menuItem:hover:not([aria-disabled]) {
|
|
64
|
+
color: var(--fg);
|
|
65
|
+
background: var(--hover);
|
|
66
|
+
}
|
|
67
|
+
.link[aria-current],
|
|
68
|
+
.link[data-selected],
|
|
69
|
+
.menuItem[aria-current] {
|
|
70
|
+
color: var(--navigation-active-color, var(--fg));
|
|
71
|
+
background: var(--selected);
|
|
72
|
+
}
|
|
73
|
+
.link:disabled,
|
|
74
|
+
.link[aria-disabled],
|
|
75
|
+
.menuItem[aria-disabled] {
|
|
76
|
+
opacity: 0.45;
|
|
77
|
+
cursor: not-allowed;
|
|
78
|
+
}
|
|
79
|
+
.link:focus-visible,
|
|
80
|
+
.menuItem:focus-visible,
|
|
81
|
+
.brand:focus-visible {
|
|
82
|
+
outline: 2px solid var(--accent-ink, var(--accent));
|
|
83
|
+
outline-offset: -2px;
|
|
84
|
+
}
|
|
85
|
+
.chevron {
|
|
86
|
+
transition: transform var(--motion-chevron) var(--ease);
|
|
87
|
+
}
|
|
88
|
+
.link[aria-expanded="true"] .chevron {
|
|
89
|
+
transform: rotate(180deg);
|
|
90
|
+
}
|
|
91
|
+
.menuItem {
|
|
92
|
+
min-width: 0;
|
|
93
|
+
width: 100%;
|
|
94
|
+
}
|
|
95
|
+
.menuItem > span {
|
|
96
|
+
overflow: hidden;
|
|
97
|
+
text-overflow: ellipsis;
|
|
98
|
+
}
|
|
99
|
+
.actions {
|
|
100
|
+
display: flex;
|
|
101
|
+
align-items: center;
|
|
102
|
+
gap: 8px;
|
|
103
|
+
flex-shrink: 0;
|
|
104
|
+
}
|
|
105
|
+
.mobileToggle {
|
|
106
|
+
display: none;
|
|
107
|
+
}
|
|
108
|
+
@media (max-width: 720px) {
|
|
109
|
+
.bar {
|
|
110
|
+
min-height: 60px;
|
|
111
|
+
padding: 10px 16px;
|
|
112
|
+
gap: 12px;
|
|
113
|
+
}
|
|
114
|
+
.links {
|
|
115
|
+
display: none;
|
|
116
|
+
}
|
|
117
|
+
.actions {
|
|
118
|
+
margin-left: auto;
|
|
119
|
+
}
|
|
120
|
+
.mobileToggle {
|
|
121
|
+
display: inline-flex;
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
@media (prefers-reduced-motion: reduce) {
|
|
125
|
+
.link,
|
|
126
|
+
.menuItem,
|
|
127
|
+
.chevron {
|
|
128
|
+
transition: none;
|
|
129
|
+
}
|
|
130
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
.surface {
|
|
2
|
+
min-width: 0;
|
|
3
|
+
width: 100%;
|
|
4
|
+
--nav-radius: 8px;
|
|
5
|
+
--nav-item-height: 42px;
|
|
6
|
+
}
|
|
7
|
+
.surface[data-navigation="sidebar"] {
|
|
8
|
+
--nav-group-divider: 1px solid var(--line);
|
|
9
|
+
--nav-group-gap: 16px;
|
|
10
|
+
--nav-group-inset: 16px;
|
|
11
|
+
}
|
|
12
|
+
.surface[data-navigation="indicator"] {
|
|
13
|
+
--nav-indicator-opacity: 1;
|
|
14
|
+
--nav-radius: 8px;
|
|
15
|
+
--nav-item-height: 42px;
|
|
16
|
+
--nav-group-gap: 22px;
|
|
17
|
+
--nav-group-inset: 0;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.card {
|
|
21
|
+
composes: card from "./Card.module.css";
|
|
22
|
+
padding: 14px;
|
|
23
|
+
--nav-radius: 10px;
|
|
24
|
+
--nav-group-divider: 1px solid var(--line);
|
|
25
|
+
--nav-group-gap: 16px;
|
|
26
|
+
--nav-group-inset: 16px;
|
|
27
|
+
}
|
|
@@ -4,6 +4,11 @@
|
|
|
4
4
|
gap: 12px;
|
|
5
5
|
padding: 12px;
|
|
6
6
|
max-height: min(540px, 80vh);
|
|
7
|
+
min-height: 0;
|
|
8
|
+
flex-shrink: 1;
|
|
9
|
+
}
|
|
10
|
+
.panel > :where(:not(.variantPanel):not(.loading):not([data-virtual-picker])) {
|
|
11
|
+
flex-shrink: 0;
|
|
7
12
|
}
|
|
8
13
|
.footer {
|
|
9
14
|
display: flex;
|
|
@@ -22,11 +27,13 @@
|
|
|
22
27
|
font-family: "Segoe UI Emoji", "Segoe UI Symbol", var(--ui-font);
|
|
23
28
|
}
|
|
24
29
|
.loading {
|
|
30
|
+
min-height: 0;
|
|
25
31
|
display: grid;
|
|
26
32
|
place-items: center;
|
|
27
33
|
height: 320px;
|
|
28
34
|
}
|
|
29
35
|
.variantPanel {
|
|
36
|
+
min-height: 0;
|
|
30
37
|
height: 320px;
|
|
31
38
|
overflow: auto;
|
|
32
39
|
}
|
package/components/Popover.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { type ReactNode, type RefObject } from "react";
|
|
2
|
-
|
|
2
|
+
import { type MenuSide } from "./motion";
|
|
3
|
+
export declare function Popover({ open: requestedOpen, onClose, anchor, children, width, maxHeight, scrollable, side, align, label, role, id, onKeyDown, descriptionId, autoFocus, matchAnchorWidth, className, }: {
|
|
3
4
|
open: boolean;
|
|
4
5
|
onClose(): void;
|
|
5
6
|
anchor: RefObject<HTMLElement | null>;
|
|
@@ -7,6 +8,10 @@ export declare function Popover({ open: requestedOpen, onClose, anchor, children
|
|
|
7
8
|
width?: number;
|
|
8
9
|
/** Maximum menu height; the viewport can reduce it further. */
|
|
9
10
|
maxHeight?: number;
|
|
11
|
+
/** Set false when a child owns scrolling, keeping search and actions fixed. */
|
|
12
|
+
scrollable?: boolean;
|
|
13
|
+
side?: "auto" | MenuSide;
|
|
14
|
+
align?: "start" | "center" | "end";
|
|
10
15
|
label: string;
|
|
11
16
|
role?: string;
|
|
12
17
|
id?: string;
|
package/components/Popover.js
CHANGED
|
@@ -16,6 +16,9 @@ function Popover({
|
|
|
16
16
|
children,
|
|
17
17
|
width = 230,
|
|
18
18
|
maxHeight = 360,
|
|
19
|
+
scrollable = true,
|
|
20
|
+
side = "auto",
|
|
21
|
+
align = "start",
|
|
19
22
|
label,
|
|
20
23
|
role = "dialog",
|
|
21
24
|
id,
|
|
@@ -46,7 +49,7 @@ function Popover({
|
|
|
46
49
|
void menuSurfaceMotion(
|
|
47
50
|
surface,
|
|
48
51
|
"exit",
|
|
49
|
-
surface.dataset.side
|
|
52
|
+
surface.dataset.side
|
|
50
53
|
).then((done) => {
|
|
51
54
|
if (done && !opened.current && surface.matches(":popover-open"))
|
|
52
55
|
surface.hidePopover();
|
|
@@ -66,7 +69,10 @@ function Popover({
|
|
|
66
69
|
const viewportLeft = viewport?.offsetLeft ?? 0;
|
|
67
70
|
const viewportWidth = viewport?.width ?? innerWidth;
|
|
68
71
|
const viewportBottom = viewportTop + (viewport?.height ?? innerHeight);
|
|
69
|
-
const rect = trigger.getBoundingClientRect(), available = Math.max(
|
|
72
|
+
const rect = trigger.getBoundingClientRect(), available = Math.max(
|
|
73
|
+
0,
|
|
74
|
+
Math.min(maxHeight, viewportBottom - viewportTop - 24)
|
|
75
|
+
);
|
|
70
76
|
surface.style.maxHeight = available + "px";
|
|
71
77
|
const actualWidth = Math.min(
|
|
72
78
|
matchAnchorWidth ? rect.width : width,
|
|
@@ -74,25 +80,34 @@ function Popover({
|
|
|
74
80
|
);
|
|
75
81
|
surface.style.width = actualWidth + "px";
|
|
76
82
|
const height = Math.min(surface.scrollHeight + 2, available);
|
|
83
|
+
const below = viewportBottom - rect.bottom - 10;
|
|
84
|
+
let resolved = side === "auto" ? below >= height || rect.top - viewportTop < height ? "bottom" : "top" : side;
|
|
85
|
+
if (resolved === "left" && rect.left - viewportLeft - 20 < actualWidth && viewportLeft + viewportWidth - rect.right - 20 >= actualWidth)
|
|
86
|
+
resolved = "right";
|
|
87
|
+
if (resolved === "right" && viewportLeft + viewportWidth - rect.right - 20 < actualWidth && rect.left - viewportLeft - 20 >= actualWidth)
|
|
88
|
+
resolved = "left";
|
|
89
|
+
const horizontal = resolved === "left" || resolved === "right";
|
|
90
|
+
const left = horizontal ? resolved === "left" ? rect.left - actualWidth - 8 : rect.right + 8 : align === "end" ? rect.right - actualWidth : align === "center" ? rect.left + (rect.width - actualWidth) / 2 : rect.left;
|
|
91
|
+
const top = horizontal ? align === "end" ? rect.bottom - height : align === "center" ? rect.top + (rect.height - height) / 2 : rect.top : resolved === "bottom" ? rect.bottom + 6 : rect.top - height - 6;
|
|
92
|
+
surface.dataset.side = resolved;
|
|
77
93
|
surface.style.left = Math.max(
|
|
78
94
|
viewportLeft + 12,
|
|
79
|
-
Math.min(
|
|
95
|
+
Math.min(left, viewportLeft + viewportWidth - actualWidth - 12)
|
|
80
96
|
) + "px";
|
|
81
|
-
const below = viewportBottom - rect.bottom - 10;
|
|
82
|
-
surface.dataset.side = below >= height || rect.top - viewportTop < height ? "bottom" : "top";
|
|
83
|
-
const top = surface.dataset.side === "bottom" ? rect.bottom + 6 : rect.top - height - 6;
|
|
84
97
|
surface.style.top = Math.max(
|
|
85
98
|
viewportTop + 12,
|
|
86
99
|
Math.min(top, viewportBottom - height - 12)
|
|
87
100
|
) + "px";
|
|
88
101
|
};
|
|
102
|
+
const entering = !surface.matches(":popover-open") || surface.dataset.motionPhase === "exit" || surface.dataset.motionPhase === "hidden";
|
|
89
103
|
if (!surface.matches(":popover-open")) surface.showPopover();
|
|
90
104
|
position();
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
105
|
+
if (entering)
|
|
106
|
+
void menuSurfaceMotion(
|
|
107
|
+
surface,
|
|
108
|
+
"enter",
|
|
109
|
+
surface.dataset.side
|
|
110
|
+
);
|
|
96
111
|
if (autoFocus && role !== "listbox")
|
|
97
112
|
(surface.querySelector("[data-autofocus]") || surface.querySelector(
|
|
98
113
|
'input:not([disabled]),button:not([disabled]),[tabindex="0"]'
|
|
@@ -133,7 +148,18 @@ function Popover({
|
|
|
133
148
|
window.visualViewport?.removeEventListener("resize", position);
|
|
134
149
|
window.visualViewport?.removeEventListener("scroll", position);
|
|
135
150
|
};
|
|
136
|
-
}, [
|
|
151
|
+
}, [
|
|
152
|
+
open,
|
|
153
|
+
anchor,
|
|
154
|
+
width,
|
|
155
|
+
maxHeight,
|
|
156
|
+
role,
|
|
157
|
+
portalHost,
|
|
158
|
+
autoFocus,
|
|
159
|
+
matchAnchorWidth,
|
|
160
|
+
side,
|
|
161
|
+
align
|
|
162
|
+
]);
|
|
137
163
|
return createPortal(
|
|
138
164
|
/* @__PURE__ */ jsx(
|
|
139
165
|
"div",
|
|
@@ -145,7 +171,7 @@ function Popover({
|
|
|
145
171
|
"aria-label": label,
|
|
146
172
|
"aria-describedby": descriptionId,
|
|
147
173
|
onKeyDown,
|
|
148
|
-
className: s.popover
|
|
174
|
+
className: `${s.popover} ${scrollable ? "" : s.contained} ${className}`,
|
|
149
175
|
children: /* @__PURE__ */ jsx(FieldContext, { value: null, children })
|
|
150
176
|
}
|
|
151
177
|
),
|
|
@@ -14,6 +14,14 @@
|
|
|
14
14
|
.popover[inert] {
|
|
15
15
|
pointer-events: none;
|
|
16
16
|
}
|
|
17
|
+
.popover.contained {
|
|
18
|
+
display: flex;
|
|
19
|
+
flex-direction: column;
|
|
20
|
+
overflow: hidden;
|
|
21
|
+
}
|
|
22
|
+
:where(.contained) > * {
|
|
23
|
+
flex-shrink: 0;
|
|
24
|
+
}
|
|
17
25
|
.popover:not(:popover-open) {
|
|
18
26
|
display: none;
|
|
19
27
|
}
|
|
@@ -1,33 +1,33 @@
|
|
|
1
|
-
.progress {
|
|
2
|
-
height: 5px;
|
|
3
|
-
width: 100%;
|
|
4
|
-
background: var(--line);
|
|
5
|
-
border-radius: 10px;
|
|
6
|
-
overflow: hidden;
|
|
7
|
-
}
|
|
8
|
-
.progress span {
|
|
9
|
-
display: block;
|
|
10
|
-
height: 100%;
|
|
11
|
-
background: var(--accent);
|
|
12
|
-
border-radius: inherit;
|
|
13
|
-
transition: width var(--motion-panel) var(--ease);
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.progress[data-indeterminate="true"] > span {
|
|
17
|
-
width: 35%;
|
|
18
|
-
animation: progress-travel 1.25s ease-in-out infinite;
|
|
19
|
-
}
|
|
20
|
-
.progress[data-tone="success"] > span {
|
|
21
|
-
background: var(--success);
|
|
22
|
-
}
|
|
23
|
-
.progress[data-tone="error"] > span {
|
|
24
|
-
background: var(--danger);
|
|
25
|
-
}
|
|
26
|
-
@keyframes progress-travel {
|
|
27
|
-
from {
|
|
28
|
-
transform: translateX(-100%);
|
|
29
|
-
}
|
|
30
|
-
to {
|
|
31
|
-
transform: translateX(290%);
|
|
32
|
-
}
|
|
33
|
-
}
|
|
1
|
+
.progress {
|
|
2
|
+
height: 5px;
|
|
3
|
+
width: 100%;
|
|
4
|
+
background: var(--line);
|
|
5
|
+
border-radius: 10px;
|
|
6
|
+
overflow: hidden;
|
|
7
|
+
}
|
|
8
|
+
.progress span {
|
|
9
|
+
display: block;
|
|
10
|
+
height: 100%;
|
|
11
|
+
background: var(--accent-ink, var(--accent));
|
|
12
|
+
border-radius: inherit;
|
|
13
|
+
transition: width var(--motion-panel) var(--ease);
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.progress[data-indeterminate="true"] > span {
|
|
17
|
+
width: 35%;
|
|
18
|
+
animation: progress-travel 1.25s ease-in-out infinite;
|
|
19
|
+
}
|
|
20
|
+
.progress[data-tone="success"] > span {
|
|
21
|
+
background: var(--success);
|
|
22
|
+
}
|
|
23
|
+
.progress[data-tone="error"] > span {
|
|
24
|
+
background: var(--danger);
|
|
25
|
+
}
|
|
26
|
+
@keyframes progress-travel {
|
|
27
|
+
from {
|
|
28
|
+
transform: translateX(-100%);
|
|
29
|
+
}
|
|
30
|
+
to {
|
|
31
|
+
transform: translateX(290%);
|
|
32
|
+
}
|
|
33
|
+
}
|
|
@@ -1,87 +1,87 @@
|
|
|
1
|
-
.group {
|
|
2
|
-
border: 0;
|
|
3
|
-
margin: 0;
|
|
4
|
-
padding: 0;
|
|
5
|
-
display: flex;
|
|
6
|
-
gap: 20px;
|
|
7
|
-
}
|
|
8
|
-
.group legend {
|
|
9
|
-
padding: 0;
|
|
10
|
-
margin-bottom: 10px;
|
|
11
|
-
font-size: 12px;
|
|
12
|
-
}
|
|
13
|
-
.group label {
|
|
14
|
-
position: relative;
|
|
15
|
-
display: inline-flex;
|
|
16
|
-
align-items: center;
|
|
17
|
-
gap: 8px;
|
|
18
|
-
cursor: pointer;
|
|
19
|
-
user-select: none;
|
|
20
|
-
}
|
|
21
|
-
.group input[type="radio"] {
|
|
22
|
-
position: absolute;
|
|
23
|
-
left: 0;
|
|
24
|
-
margin: 0;
|
|
25
|
-
width: 18px;
|
|
26
|
-
height: 18px;
|
|
27
|
-
opacity: 0;
|
|
28
|
-
}
|
|
29
|
-
.mark {
|
|
30
|
-
display: grid;
|
|
31
|
-
place-items: center;
|
|
32
|
-
flex-shrink: 0;
|
|
33
|
-
width: 18px;
|
|
34
|
-
height: 18px;
|
|
35
|
-
border: 1px solid color-mix(in srgb, var(--fg) 25%, var(--surface));
|
|
36
|
-
border-radius: 50%;
|
|
37
|
-
background: var(--field);
|
|
38
|
-
pointer-events: none;
|
|
39
|
-
transition:
|
|
40
|
-
border-color var(--motion-hover),
|
|
41
|
-
box-shadow var(--motion-hover),
|
|
42
|
-
transform var(--motion-press);
|
|
43
|
-
}
|
|
44
|
-
.mark::after {
|
|
45
|
-
content: "";
|
|
46
|
-
width: 8px;
|
|
47
|
-
height: 8px;
|
|
48
|
-
border-radius: 50%;
|
|
49
|
-
background: var(--accent-
|
|
50
|
-
transform: scale(0.25);
|
|
51
|
-
opacity: 0;
|
|
52
|
-
transition:
|
|
53
|
-
transform var(--motion-panel) var(--ease),
|
|
54
|
-
opacity var(--motion-hover);
|
|
55
|
-
}
|
|
56
|
-
.group input:checked + .mark {
|
|
57
|
-
border-color: var(--accent-
|
|
58
|
-
}
|
|
59
|
-
.group input:checked + .mark::after {
|
|
60
|
-
transform: scale(1);
|
|
61
|
-
opacity: 1;
|
|
62
|
-
}
|
|
63
|
-
.group label:hover input:not(:disabled) + .mark {
|
|
64
|
-
border-color: var(--muted);
|
|
65
|
-
}
|
|
66
|
-
.group label:active input:not(:disabled) + .mark {
|
|
67
|
-
transform: scale(0.92);
|
|
68
|
-
}
|
|
69
|
-
.group input:focus-visible + .mark {
|
|
70
|
-
box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 14%, transparent);
|
|
71
|
-
border-color: var(--accent);
|
|
72
|
-
}
|
|
73
|
-
.group label[data-disabled="true"] {
|
|
74
|
-
cursor: not-allowed;
|
|
75
|
-
}
|
|
76
|
-
.group input:disabled ~ span {
|
|
77
|
-
opacity: 0.4;
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
.group[data-orientation="vertical"] {
|
|
81
|
-
flex-direction: column;
|
|
82
|
-
align-items: flex-start;
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
.group[aria-invalid="true"] .mark {
|
|
86
|
-
border-color: var(--danger);
|
|
87
|
-
}
|
|
1
|
+
.group {
|
|
2
|
+
border: 0;
|
|
3
|
+
margin: 0;
|
|
4
|
+
padding: 0;
|
|
5
|
+
display: flex;
|
|
6
|
+
gap: 20px;
|
|
7
|
+
}
|
|
8
|
+
.group legend {
|
|
9
|
+
padding: 0;
|
|
10
|
+
margin-bottom: 10px;
|
|
11
|
+
font-size: 12px;
|
|
12
|
+
}
|
|
13
|
+
.group label {
|
|
14
|
+
position: relative;
|
|
15
|
+
display: inline-flex;
|
|
16
|
+
align-items: center;
|
|
17
|
+
gap: 8px;
|
|
18
|
+
cursor: pointer;
|
|
19
|
+
user-select: none;
|
|
20
|
+
}
|
|
21
|
+
.group input[type="radio"] {
|
|
22
|
+
position: absolute;
|
|
23
|
+
left: 0;
|
|
24
|
+
margin: 0;
|
|
25
|
+
width: 18px;
|
|
26
|
+
height: 18px;
|
|
27
|
+
opacity: 0;
|
|
28
|
+
}
|
|
29
|
+
.mark {
|
|
30
|
+
display: grid;
|
|
31
|
+
place-items: center;
|
|
32
|
+
flex-shrink: 0;
|
|
33
|
+
width: 18px;
|
|
34
|
+
height: 18px;
|
|
35
|
+
border: 1px solid color-mix(in srgb, var(--fg) 25%, var(--surface));
|
|
36
|
+
border-radius: 50%;
|
|
37
|
+
background: var(--field);
|
|
38
|
+
pointer-events: none;
|
|
39
|
+
transition:
|
|
40
|
+
border-color var(--motion-hover),
|
|
41
|
+
box-shadow var(--motion-hover),
|
|
42
|
+
transform var(--motion-press);
|
|
43
|
+
}
|
|
44
|
+
.mark::after {
|
|
45
|
+
content: "";
|
|
46
|
+
width: 8px;
|
|
47
|
+
height: 8px;
|
|
48
|
+
border-radius: 50%;
|
|
49
|
+
background: var(--accent-ink, var(--accent));
|
|
50
|
+
transform: scale(0.25);
|
|
51
|
+
opacity: 0;
|
|
52
|
+
transition:
|
|
53
|
+
transform var(--motion-panel) var(--ease),
|
|
54
|
+
opacity var(--motion-hover);
|
|
55
|
+
}
|
|
56
|
+
.group input:checked + .mark {
|
|
57
|
+
border-color: var(--accent-ink, var(--accent));
|
|
58
|
+
}
|
|
59
|
+
.group input:checked + .mark::after {
|
|
60
|
+
transform: scale(1);
|
|
61
|
+
opacity: 1;
|
|
62
|
+
}
|
|
63
|
+
.group label:hover input:not(:disabled) + .mark {
|
|
64
|
+
border-color: var(--muted);
|
|
65
|
+
}
|
|
66
|
+
.group label:active input:not(:disabled) + .mark {
|
|
67
|
+
transform: scale(0.92);
|
|
68
|
+
}
|
|
69
|
+
.group input:focus-visible + .mark {
|
|
70
|
+
box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent-ink, var(--accent)) 14%, transparent);
|
|
71
|
+
border-color: var(--accent-ink, var(--accent));
|
|
72
|
+
}
|
|
73
|
+
.group label[data-disabled="true"] {
|
|
74
|
+
cursor: not-allowed;
|
|
75
|
+
}
|
|
76
|
+
.group input:disabled ~ span {
|
|
77
|
+
opacity: 0.4;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
.group[data-orientation="vertical"] {
|
|
81
|
+
flex-direction: column;
|
|
82
|
+
align-items: flex-start;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.group[aria-invalid="true"] .mark {
|
|
86
|
+
border-color: var(--danger);
|
|
87
|
+
}
|