@radui/ui 1.0.1 → 1.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/dist/components/Accordion.cjs +1 -1
- package/dist/components/Accordion.js +1 -1
- package/dist/components/AlertDialog.cjs +1 -1
- package/dist/components/AlertDialog.d.ts +61 -24
- package/dist/components/AlertDialog.js +1 -1
- package/dist/components/Avatar.cjs +1 -1
- package/dist/components/Avatar.d.ts +36 -6
- package/dist/components/Avatar.js +1 -1
- package/dist/components/AvatarGroup.cjs +1 -1
- package/dist/components/AvatarGroup.d.ts +39 -18
- package/dist/components/AvatarGroup.js +1 -1
- package/dist/components/{AvatarPrimitiveFallback-CBb0nHGD.cjs → AvatarPrimitiveFallback-BpUU1vNV.cjs} +1 -1
- package/dist/components/{AvatarPrimitiveFallback-C1siRii4.js → AvatarPrimitiveFallback-DIXB9Tnm.js} +1 -1
- package/dist/components/Badge.cjs +1 -1
- package/dist/components/Badge.js +1 -1
- package/dist/components/Breadcrumb.cjs +1 -1
- package/dist/components/Breadcrumb.js +1 -1
- package/dist/components/Button.cjs +1 -1
- package/dist/components/Button.js +1 -1
- package/dist/components/Callout.cjs +1 -1
- package/dist/components/Callout.d.ts +32 -18
- package/dist/components/Callout.js +1 -1
- package/dist/components/Card.cjs +1 -1
- package/dist/components/Card.d.ts +31 -16
- package/dist/components/Card.js +1 -1
- package/dist/components/Checkbox.cjs +1 -1
- package/dist/components/Checkbox.js +1 -1
- package/dist/components/CheckboxCards.cjs +1 -1
- package/dist/components/CheckboxCards.js +1 -1
- package/dist/components/CheckboxGroup.cjs +1 -1
- package/dist/components/CheckboxGroup.d.ts +6 -2
- package/dist/components/CheckboxGroup.js +1 -1
- package/dist/components/{CheckboxGroupPrimitive-DfHQYkep.js → CheckboxGroupPrimitive-BRCGIztp.js} +1 -1
- package/dist/components/{CheckboxGroupPrimitive-d9yBl6m5.cjs → CheckboxGroupPrimitive-C21WO4L3.cjs} +1 -1
- package/dist/components/Collapsible.cjs +1 -1
- package/dist/components/Collapsible.d.ts +34 -4
- package/dist/components/Collapsible.js +1 -1
- package/dist/components/Combobox.cjs +1 -1
- package/dist/components/Combobox.d.ts +57 -45
- package/dist/components/Combobox.js +1 -1
- package/dist/components/ComboboxPrimitive-BdX2jgpQ.js +1 -0
- package/dist/components/ComboboxPrimitive-CyO6ZH5T.cjs +1 -0
- package/dist/components/Command.cjs +1 -1
- package/dist/components/Command.d.ts +36 -8
- package/dist/components/Command.js +1 -1
- package/dist/components/ContextMenu.cjs +1 -1
- package/dist/components/ContextMenu.d.ts +25 -11
- package/dist/components/ContextMenu.js +1 -1
- package/dist/components/Dialog.cjs +1 -1
- package/dist/components/Dialog.d.ts +29 -4
- package/dist/components/Dialog.js +1 -1
- package/dist/components/Disclosure.cjs +1 -1
- package/dist/components/Disclosure.js +1 -1
- package/dist/components/Drawer.cjs +1 -1
- package/dist/components/Drawer.d.ts +31 -3
- package/dist/components/Drawer.js +1 -1
- package/dist/components/DropdownMenu.cjs +1 -1
- package/dist/components/DropdownMenu.d.ts +25 -11
- package/dist/components/DropdownMenu.js +1 -1
- package/dist/components/HoverCard.cjs +1 -1
- package/dist/components/HoverCard.d.ts +15 -1
- package/dist/components/HoverCard.js +1 -1
- package/dist/components/Label.cjs +1 -0
- package/dist/components/Label.d.ts +18 -0
- package/dist/components/Label.js +1 -0
- package/dist/components/Link.cjs +1 -1
- package/dist/components/Link.js +1 -1
- package/dist/components/LiveRegion.cjs +1 -1
- package/dist/components/LiveRegion.d.ts +2 -5
- package/dist/components/LiveRegion.js +1 -1
- package/dist/components/MenuPrimitive-Ctqo21Vd.cjs +1 -0
- package/dist/components/MenuPrimitive-Cy_MJfjG.js +1 -0
- package/dist/components/Menubar.cjs +1 -1
- package/dist/components/Menubar.d.ts +45 -16
- package/dist/components/Menubar.js +1 -1
- package/dist/components/Meter.cjs +1 -0
- package/dist/components/Meter.d.ts +44 -0
- package/dist/components/Meter.js +1 -0
- package/dist/components/Minimap.cjs +1 -1
- package/dist/components/Minimap.js +1 -1
- package/dist/components/NavigationMenu.cjs +1 -1
- package/dist/components/NavigationMenu.d.ts +2 -0
- package/dist/components/NavigationMenu.js +1 -1
- package/dist/components/Popover.cjs +1 -1
- package/dist/components/Popover.d.ts +64 -5
- package/dist/components/Popover.js +1 -1
- package/dist/components/Progress.cjs +1 -1
- package/dist/components/Progress.d.ts +14 -2
- package/dist/components/Progress.js +1 -1
- package/dist/components/Radio.cjs +1 -1
- package/dist/components/Radio.js +1 -1
- package/dist/components/RadioCards.cjs +1 -1
- package/dist/components/RadioCards.d.ts +22 -1
- package/dist/components/RadioCards.js +1 -1
- package/dist/components/RadioGroup.cjs +1 -1
- package/dist/components/RadioGroup.d.ts +27 -7
- package/dist/components/RadioGroup.js +1 -1
- package/dist/components/RadioGroupPrimitive-B0CrM2bi.cjs +1 -0
- package/dist/components/RadioGroupPrimitive-CnPy0zgW.js +1 -0
- package/dist/components/ScrollArea.cjs +1 -1
- package/dist/components/ScrollArea.d.ts +24 -13
- package/dist/components/ScrollArea.js +1 -1
- package/dist/components/Select.cjs +1 -1
- package/dist/components/Select.d.ts +52 -44
- package/dist/components/Select.js +1 -1
- package/dist/components/Separator.cjs +1 -1
- package/dist/components/Separator.d.ts +8 -1
- package/dist/components/Separator.js +1 -1
- package/dist/components/Slider.cjs +1 -1
- package/dist/components/Slider.js +1 -1
- package/dist/components/Steps.cjs +1 -1
- package/dist/components/Steps.d.ts +33 -16
- package/dist/components/Steps.js +1 -1
- package/dist/components/Switch.cjs +1 -1
- package/dist/components/Switch.d.ts +14 -2
- package/dist/components/Switch.js +1 -1
- package/dist/components/TabNav.cjs +1 -1
- package/dist/components/TabNav.d.ts +5 -0
- package/dist/components/TabNav.js +1 -1
- package/dist/components/Table.cjs +1 -1
- package/dist/components/Table.d.ts +23 -12
- package/dist/components/Table.js +1 -1
- package/dist/components/Tabs.cjs +1 -1
- package/dist/components/Tabs.js +1 -1
- package/dist/components/Theme.cjs +1 -1
- package/dist/components/Theme.d.ts +2 -0
- package/dist/components/Theme.js +1 -1
- package/dist/components/Toast.cjs +1 -1
- package/dist/components/Toast.js +1 -1
- package/dist/components/Toggle.cjs +1 -1
- package/dist/components/Toggle.js +1 -1
- package/dist/components/ToggleGroup.cjs +1 -1
- package/dist/components/ToggleGroup.js +1 -1
- package/dist/components/Toolbar.cjs +1 -1
- package/dist/components/Toolbar.d.ts +8 -1
- package/dist/components/Toolbar.js +1 -1
- package/dist/components/Tooltip.cjs +1 -1
- package/dist/components/Tooltip.d.ts +7 -1
- package/dist/components/Tooltip.js +1 -1
- package/dist/components/Tree.cjs +1 -1
- package/dist/components/Tree.d.ts +8 -1
- package/dist/components/Tree.js +1 -1
- package/dist/components/VisuallyHidden.cjs +1 -1
- package/dist/components/VisuallyHidden.d.ts +6 -1
- package/dist/components/VisuallyHidden.js +1 -1
- package/dist/components/{floating-ui.react-2kiGB4sW.js → floating-ui.react-CZf-mCiA.js} +1 -1
- package/dist/components/{index-WGIYLuwZ.cjs → index-BZO29jsF.cjs} +1 -1
- package/dist/components/index-B_OPdW20.js +1 -0
- package/dist/components/{index-436yWBk4.cjs → index-BbvJO-A-.cjs} +1 -1
- package/dist/components/index-Bg-UeWCo.cjs +1 -0
- package/dist/components/index-BidxkqdT.js +1 -0
- package/dist/components/{index-DMX7gpdp.js → index-CAD0hWja.js} +1 -1
- package/dist/components/{index-xlB--dex.js → index-CXv1Y-O3.js} +1 -1
- package/dist/components/{index-CukraWfT.cjs → index-C_Yiql9j.cjs} +1 -1
- package/dist/components/{index-nYRBURkR.js → index-Cp5L_alO.js} +1 -1
- package/dist/components/{index-C7dBo_Ry.js → index-D8QLtYJh.js} +1 -1
- package/dist/components/{index-FITGoHty.js → index-DH-14XDv.js} +1 -1
- package/dist/components/{index-CoPhBYnZ.cjs → index-K0sE1H4u.cjs} +1 -1
- package/dist/components/{index-BeakeOqt.cjs → index-rUSzFrhJ.cjs} +1 -1
- package/dist/index.cjs +2 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +2 -0
- package/dist/styles/clarity/Accordion/accordion.clarity.scss +147 -0
- package/dist/styles/clarity/AlertDialog/alert-dialog.clarity.scss +199 -0
- package/dist/styles/clarity/Avatar/_avatar-base.clarity.scss +87 -0
- package/dist/styles/clarity/Avatar/avatar.clarity.scss +1 -0
- package/dist/styles/clarity/AvatarGroup/avatar-group.clarity.scss +122 -0
- package/dist/styles/clarity/Badge/badge.clarity.scss +118 -0
- package/dist/styles/clarity/BlockQuote/blockquote.clarity.scss +123 -0
- package/dist/styles/clarity/Breadcrumb/breadcrumb.clarity.scss +50 -0
- package/dist/styles/clarity/Button/button.clarity.scss +132 -0
- package/dist/styles/clarity/Callout/callout.clarity.scss +183 -0
- package/dist/styles/clarity/Card/card.clarity.scss +121 -0
- package/dist/styles/clarity/Checkbox/checkbox.clarity.scss +75 -0
- package/dist/styles/clarity/CheckboxCards/checkbox-cards.clarity.scss +143 -0
- package/dist/styles/clarity/CheckboxGroup/checkbox-group.clarity.scss +92 -0
- package/dist/styles/clarity/Code/code.clarity.scss +42 -0
- package/dist/styles/clarity/Collapsible/collapsible.clarity.scss +84 -0
- package/dist/styles/clarity/Combobox/combobox.clarity.scss +157 -0
- package/dist/styles/clarity/Command/command.clarity.scss +231 -0
- package/dist/styles/clarity/ContextMenu/context-menu.clarity.scss +272 -0
- package/dist/styles/clarity/DataList/data-list.clarity.scss +60 -0
- package/dist/styles/clarity/Dialog/dialog.clarity.scss +205 -0
- package/dist/styles/clarity/Disclosure/disclosure.clarity.scss +56 -0
- package/dist/styles/clarity/Drawer/drawer.clarity.scss +331 -0
- package/dist/styles/clarity/DropdownMenu/dropdown-menu.clarity.scss +187 -0
- package/dist/styles/clarity/Em/em.clarity.scss +3 -0
- package/dist/styles/clarity/Fieldset/fieldset.clarity.scss +49 -0
- package/dist/styles/clarity/Heading/heading.clarity.scss +46 -0
- package/dist/styles/clarity/HoverCard/hover-card.clarity.scss +43 -0
- package/dist/styles/clarity/Kbd/kbd.clarity.scss +55 -0
- package/dist/styles/clarity/Label/label.clarity.scss +11 -0
- package/dist/styles/clarity/Link/link.clarity.scss +41 -0
- package/dist/styles/clarity/Menubar/menubar.clarity.scss +149 -0
- package/dist/styles/clarity/Meter/meter.clarity.scss +39 -0
- package/dist/styles/clarity/Minimap/minimap.clarity.scss +92 -0
- package/dist/styles/clarity/NavigationMenu/navigation-menu.clarity.scss +128 -0
- package/dist/styles/clarity/NumberField/number-field.clarity.scss +135 -0
- package/dist/styles/clarity/Popover/popover.clarity.scss +106 -0
- package/dist/styles/clarity/Progress/progress.clarity.scss +38 -0
- package/dist/styles/clarity/Quote/quote.clarity.scss +26 -0
- package/dist/styles/clarity/Radio/radio.clarity.scss +76 -0
- package/dist/styles/clarity/RadioCards/radiocards.clarity.scss +134 -0
- package/dist/styles/clarity/RadioGroup/radio-group.clarity.scss +99 -0
- package/dist/styles/clarity/ScrollArea/scroll-area.clarity.scss +112 -0
- package/dist/styles/clarity/Select/select.clarity.scss +228 -0
- package/dist/styles/clarity/Separator/separator.clarity.scss +23 -0
- package/dist/styles/clarity/Skeleton/skeleton.clarity.scss +33 -0
- package/dist/styles/clarity/Slider/slider.clarity.scss +203 -0
- package/dist/styles/clarity/Spinner/spinner.clarity.scss +52 -0
- package/dist/styles/clarity/Splitter/splitter.clarity.scss +151 -0
- package/dist/styles/clarity/Steps/steps.clarity.scss +143 -0
- package/dist/styles/clarity/Strong/strong.clarity.scss +6 -0
- package/dist/styles/clarity/Switch/switch.clarity.scss +89 -0
- package/dist/styles/clarity/TabNav/tab-nav.clarity.scss +69 -0
- package/dist/styles/clarity/Table/table.clarity.scss +128 -0
- package/dist/styles/clarity/Tabs/tabs.clarity.scss +91 -0
- package/dist/styles/clarity/Text/text.clarity.scss +5 -0
- package/dist/styles/clarity/TextArea/textarea.clarity.scss +146 -0
- package/dist/styles/clarity/TextField/text-field.clarity.scss +120 -0
- package/dist/styles/clarity/Toast/toast.clarity.scss +203 -0
- package/dist/styles/clarity/Toggle/toggle.clarity.scss +51 -0
- package/dist/styles/clarity/ToggleGroup/toggle-group.clarity.scss +103 -0
- package/dist/styles/clarity/Toolbar/toolbar.clarity.scss +140 -0
- package/dist/styles/clarity/Tooltip/tooltip.clarity.scss +37 -0
- package/dist/styles/clarity/Tree/tree.clarity.scss +103 -0
- package/dist/themes/baremetal.css +1 -1
- package/dist/themes/default.css +1 -1
- package/package.json +21 -2
- package/dist/components/ComboboxPrimitive-DQcJ8pzQ.js +0 -1
- package/dist/components/ComboboxPrimitive-kFYDdMUS.cjs +0 -1
- package/dist/components/MenuPrimitive-B1-7Sfhj.cjs +0 -1
- package/dist/components/MenuPrimitive-D9VMz2TZ.js +0 -1
- package/dist/components/RadioGroupPrimitive-CpA06FS_.cjs +0 -1
- package/dist/components/RadioGroupPrimitive-D1PP4y2M.js +0 -1
- package/dist/components/index-CbKtybdA.cjs +0 -1
- package/dist/components/index-D8I-rMwz.js +0 -1
- package/dist/components/index-XF8itt-H.js +0 -1
|
@@ -0,0 +1,203 @@
|
|
|
1
|
+
// Slider — Clarity design system aligned
|
|
2
|
+
// Track bg: step 5 (400) — contrasted interactive rail
|
|
3
|
+
// Track border: step 8 (700) — defined rail edge
|
|
4
|
+
// Track end caps: step 5 (400) bg, step 8 (700) border
|
|
5
|
+
// Range fill: accent-700 — brand/solid color
|
|
6
|
+
// Thumb bg: step 1 (50) — canvas bg (clean, no hue)
|
|
7
|
+
// Thumb border: step 7 (600) — default border
|
|
8
|
+
// Thumb hover/active/dragging border: accent-600/700 — interactive signal
|
|
9
|
+
// Mark line: step 7 (600) — default border
|
|
10
|
+
// Mark label: step 11 (950) — supporting content
|
|
11
|
+
.rad-ui-slider {
|
|
12
|
+
position: relative;
|
|
13
|
+
width: 100%;
|
|
14
|
+
max-width: var(--rad-ui-slider-inline-size, calc(var(--rad-ui-overlay-width-md) + var(--rad-ui-spacing-6)));
|
|
15
|
+
min-height: var(--rad-ui-control-height-sm);
|
|
16
|
+
display: flex;
|
|
17
|
+
align-items: center;
|
|
18
|
+
touch-action: none;
|
|
19
|
+
user-select: none;
|
|
20
|
+
|
|
21
|
+
.rad-ui-slider-track {
|
|
22
|
+
position: relative;
|
|
23
|
+
width: 100%;
|
|
24
|
+
height: var(--rad-ui-slider-track-size, calc(var(--rad-ui-density-gap-sm) + var(--rad-ui-density-gap-xs)));
|
|
25
|
+
border-radius: var(--rad-ui-control-radius-pill);
|
|
26
|
+
background-color: var(--rad-ui-color-gray-400); // step 5 — contrasted interactive rail
|
|
27
|
+
box-shadow:
|
|
28
|
+
inset 0 0 0 var(--rad-ui-border-width-default) var(--rad-ui-color-gray-700),
|
|
29
|
+
var(--rad-ui-control-shadow);
|
|
30
|
+
|
|
31
|
+
&::before,
|
|
32
|
+
&::after {
|
|
33
|
+
content: "";
|
|
34
|
+
position: absolute;
|
|
35
|
+
top: 50%;
|
|
36
|
+
width: var(--rad-ui-density-gap-md);
|
|
37
|
+
height: var(--rad-ui-density-gap-md);
|
|
38
|
+
border-radius: var(--rad-ui-control-radius-pill);
|
|
39
|
+
background-color: var(--rad-ui-color-gray-400); // step 5
|
|
40
|
+
border: var(--rad-ui-border-width-default) solid var(--rad-ui-color-gray-700); // step 8 — defined edge
|
|
41
|
+
transform: translateY(-50%);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
&::before { left: calc(var(--rad-ui-density-gap-xs) * -1); }
|
|
45
|
+
&::after { right: calc(var(--rad-ui-density-gap-xs) * -1); }
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.rad-ui-slider-range {
|
|
49
|
+
height: 100%;
|
|
50
|
+
border-radius: inherit;
|
|
51
|
+
background-color: var(--rad-ui-color-accent-700); // accent — brand fill
|
|
52
|
+
box-shadow: inset 0 0 0 var(--rad-ui-border-width-default) var(--rad-ui-color-accent-600);
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.rad-ui-slider-thumb,
|
|
56
|
+
.rad-ui-slider-thumb-lower,
|
|
57
|
+
.rad-ui-slider-thumb-upper {
|
|
58
|
+
width: var(--rad-ui-icon-size-md);
|
|
59
|
+
height: var(--rad-ui-icon-size-md);
|
|
60
|
+
background-color: var(--rad-ui-color-gray-50); // step 1 — canvas bg
|
|
61
|
+
border-radius: var(--rad-ui-control-radius-pill);
|
|
62
|
+
border: var(--rad-ui-border-width-default) solid var(--rad-ui-color-gray-600); // step 7 — default border
|
|
63
|
+
box-shadow: var(--rad-ui-control-shadow);
|
|
64
|
+
position: absolute;
|
|
65
|
+
top: 50%;
|
|
66
|
+
transform: translateY(-50%);
|
|
67
|
+
cursor: pointer;
|
|
68
|
+
z-index: 2;
|
|
69
|
+
transition: border-color var(--rad-ui-motion-duration-fast) ease, box-shadow var(--rad-ui-motion-duration-fast) ease;
|
|
70
|
+
|
|
71
|
+
&:hover {
|
|
72
|
+
border-color: var(--rad-ui-color-accent-600); // accent — hover signal
|
|
73
|
+
box-shadow: var(--rad-ui-control-shadow-hover);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
&[data-state="active"] {
|
|
77
|
+
border-color: var(--rad-ui-color-accent-700);
|
|
78
|
+
transform: translateY(-50%) scale(1.04);
|
|
79
|
+
box-shadow: var(--rad-ui-control-shadow-active);
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
&[data-state="dragging"] {
|
|
83
|
+
border-color: var(--rad-ui-color-accent-700);
|
|
84
|
+
transform: translateY(-50%) scale(1.08);
|
|
85
|
+
box-shadow: var(--rad-ui-control-shadow-active);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
&[data-disabled="true"] {
|
|
89
|
+
opacity: 0.45;
|
|
90
|
+
cursor: not-allowed;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
&:focus-visible {
|
|
94
|
+
outline: none;
|
|
95
|
+
box-shadow: var(--rad-ui-focus-ring-shadow);
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.rad-ui-slider-marks {
|
|
100
|
+
position: absolute;
|
|
101
|
+
inset: calc(var(--rad-ui-density-gap-lg) * -1) 0 0 0;
|
|
102
|
+
pointer-events: none;
|
|
103
|
+
z-index: 1;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
.rad-ui-slider-mark {
|
|
107
|
+
position: absolute;
|
|
108
|
+
display: flex;
|
|
109
|
+
flex-direction: column;
|
|
110
|
+
align-items: center;
|
|
111
|
+
|
|
112
|
+
.rad-ui-slider-mark-line {
|
|
113
|
+
background-color: var(--rad-ui-color-gray-600); // step 7 — default border
|
|
114
|
+
border-radius: var(--rad-ui-density-gap-xs);
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
.rad-ui-slider-mark-label {
|
|
118
|
+
position: absolute;
|
|
119
|
+
font-size: var(--rad-ui-component-font-size-xs);
|
|
120
|
+
font-weight: var(--rad-ui-component-font-weight-regular);
|
|
121
|
+
color: var(--rad-ui-text-secondary);
|
|
122
|
+
background-color: transparent;
|
|
123
|
+
padding: var(--rad-ui-border-width-default) var(--rad-ui-density-gap-sm);
|
|
124
|
+
border-radius: var(--rad-ui-density-gap-xs);
|
|
125
|
+
border: none;
|
|
126
|
+
box-shadow: var(--rad-ui-shadow-none);
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
&:not(.rad-ui-slider-mark-custom) .rad-ui-slider-mark-line {
|
|
130
|
+
width: var(--rad-ui-density-gap-md);
|
|
131
|
+
height: var(--rad-ui-density-gap-xs);
|
|
132
|
+
opacity: 0.8;
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
&.rad-ui-slider-mark-custom {
|
|
136
|
+
.rad-ui-slider-mark-line { background-color: var(--rad-ui-border-strong); }
|
|
137
|
+
.rad-ui-slider-mark-label { font-weight: var(--rad-ui-component-font-weight-medium); color: var(--rad-ui-text-primary); }
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
&[data-orientation="vertical"] {
|
|
142
|
+
height: var(--rad-ui-slider-block-size, calc(var(--rad-ui-overlay-width-sm) - var(--rad-ui-size-10)));
|
|
143
|
+
width: calc(var(--rad-ui-control-height-md) + var(--rad-ui-density-gap-md));
|
|
144
|
+
flex-direction: column;
|
|
145
|
+
|
|
146
|
+
.rad-ui-slider-track {
|
|
147
|
+
height: 100%;
|
|
148
|
+
width: var(--rad-ui-slider-track-size, calc(var(--rad-ui-density-gap-sm) + var(--rad-ui-density-gap-xs)));
|
|
149
|
+
|
|
150
|
+
&::before,
|
|
151
|
+
&::after {
|
|
152
|
+
left: 50%;
|
|
153
|
+
top: auto;
|
|
154
|
+
transform: translateX(-50%);
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
&::before { top: calc(var(--rad-ui-density-gap-xs) * -1); }
|
|
158
|
+
&::after { bottom: calc(var(--rad-ui-density-gap-xs) * -1); }
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
.rad-ui-slider-thumb,
|
|
162
|
+
.rad-ui-slider-thumb-lower,
|
|
163
|
+
.rad-ui-slider-thumb-upper {
|
|
164
|
+
left: 50%;
|
|
165
|
+
top: auto;
|
|
166
|
+
transform: translateX(-50%);
|
|
167
|
+
|
|
168
|
+
&[data-state="active"] {
|
|
169
|
+
border-color: var(--rad-ui-color-accent-700);
|
|
170
|
+
transform: translateX(-50%) scale(1.04);
|
|
171
|
+
box-shadow: var(--rad-ui-control-shadow-active);
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
&[data-state="dragging"] {
|
|
175
|
+
border-color: var(--rad-ui-color-accent-700);
|
|
176
|
+
transform: translateX(-50%) scale(1.08);
|
|
177
|
+
box-shadow: var(--rad-ui-control-shadow-active);
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
&:focus-visible {
|
|
181
|
+
outline: none;
|
|
182
|
+
box-shadow: var(--rad-ui-focus-ring-shadow);
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
.rad-ui-slider-range { width: 100%; }
|
|
187
|
+
|
|
188
|
+
.rad-ui-slider-mark {
|
|
189
|
+
flex-direction: row;
|
|
190
|
+
align-items: center;
|
|
191
|
+
|
|
192
|
+
.rad-ui-slider-mark-label {
|
|
193
|
+
top: 50%;
|
|
194
|
+
right: var(--rad-ui-density-gap-xl);
|
|
195
|
+
transform: translateY(-50%);
|
|
196
|
+
margin: 0;
|
|
197
|
+
white-space: nowrap;
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
.rad-ui-slider-mark-line { width: var(--rad-ui-density-gap-xs); height: var(--rad-ui-density-gap-md); }
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
// Spinner — Clarity design system aligned
|
|
2
|
+
// Track ring: accent-300 — light, low-weight accent surface (step 4 equivalent)
|
|
3
|
+
// Active arc: accent-800 — solid, high contrast accent (step 9 equivalent)
|
|
4
|
+
@keyframes rad-ui-spinner-spin {
|
|
5
|
+
0% { transform: rotate(0deg); opacity: 0.3; }
|
|
6
|
+
25% { opacity: 0.6; }
|
|
7
|
+
50% { opacity: 0.8; }
|
|
8
|
+
75% { opacity: 0.6; }
|
|
9
|
+
100% { transform: rotate(360deg); opacity: 0.3; }
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.rad-ui-spinner-container {
|
|
13
|
+
// Inline so a spinner can sit next to text, e.g. inside a button.
|
|
14
|
+
display: inline-flex;
|
|
15
|
+
vertical-align: middle;
|
|
16
|
+
align-items: center;
|
|
17
|
+
justify-content: center;
|
|
18
|
+
|
|
19
|
+
// The rotating square's bounding box grows past the circle mid-rotation, which creates
|
|
20
|
+
// transient scrollable overflow in the parent; the circle itself never leaves this box.
|
|
21
|
+
overflow: hidden;
|
|
22
|
+
border-radius: 100%;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.rad-ui-spinner {
|
|
26
|
+
animation: rad-ui-spinner-spin 1.3s linear infinite;
|
|
27
|
+
border-style: solid;
|
|
28
|
+
border-color: var(--rad-ui-color-accent-300); // accent step 4 — light track ring
|
|
29
|
+
border-top-color: var(--rad-ui-color-accent-800); // accent step 9 — solid active arc
|
|
30
|
+
border-radius: 100%;
|
|
31
|
+
width: 30px;
|
|
32
|
+
height: 30px;
|
|
33
|
+
border-width: 3px;
|
|
34
|
+
|
|
35
|
+
&[data-size="small"] {
|
|
36
|
+
border-width: 2px;
|
|
37
|
+
width: 20px;
|
|
38
|
+
height: 20px;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
&[data-size="medium"] {
|
|
42
|
+
border-width: 3px;
|
|
43
|
+
width: 30px;
|
|
44
|
+
height: 30px;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
&[data-size="large"] {
|
|
48
|
+
border-width: 4px;
|
|
49
|
+
width: 40px;
|
|
50
|
+
height: 40px;
|
|
51
|
+
}
|
|
52
|
+
}
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
// Splitter — Clarity design system aligned
|
|
2
|
+
// Outer border: step 6 (500) — light border
|
|
3
|
+
// Panel bg: step 2 (100) — subtle surface
|
|
4
|
+
// Handle divider line: step 6 (500) — light border/separator
|
|
5
|
+
// Handle divider line active: accent focus color — interaction signal
|
|
6
|
+
// Handle grip pill default: step 9 (800) — solid UI element
|
|
7
|
+
|
|
8
|
+
.rad-ui-splitter {
|
|
9
|
+
position: relative;
|
|
10
|
+
width: 100%;
|
|
11
|
+
height: 100%;
|
|
12
|
+
display: flex;
|
|
13
|
+
user-select: none;
|
|
14
|
+
touch-action: none;
|
|
15
|
+
overflow: hidden;
|
|
16
|
+
border-radius: var(--rad-ui-radius-lg);
|
|
17
|
+
border: 1px solid var(--rad-ui-color-gray-500); // step 6 — light border
|
|
18
|
+
background-color: var(--rad-ui-color-gray-100); // step 2 — subtle surface
|
|
19
|
+
|
|
20
|
+
.rad-ui-splitter-panel {
|
|
21
|
+
position: relative;
|
|
22
|
+
background-color: var(--rad-ui-color-gray-100); // step 2 — subtle surface
|
|
23
|
+
flex-shrink: 1;
|
|
24
|
+
flex-grow: 0;
|
|
25
|
+
min-width: 0;
|
|
26
|
+
min-height: 0;
|
|
27
|
+
|
|
28
|
+
> * {
|
|
29
|
+
box-sizing: border-box;
|
|
30
|
+
min-width: 0;
|
|
31
|
+
min-height: 0;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.rad-ui-splitter-handle {
|
|
36
|
+
position: relative;
|
|
37
|
+
background: transparent;
|
|
38
|
+
border: 0;
|
|
39
|
+
border-radius: var(--rad-ui-radius-full);
|
|
40
|
+
outline: none;
|
|
41
|
+
flex-shrink: 0;
|
|
42
|
+
flex-grow: 0;
|
|
43
|
+
user-select: none;
|
|
44
|
+
touch-action: none;
|
|
45
|
+
z-index: 10;
|
|
46
|
+
|
|
47
|
+
&:focus-visible {
|
|
48
|
+
outline: none;
|
|
49
|
+
box-shadow: var(--rad-ui-shadow-none);
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
&[aria-orientation="horizontal"] {
|
|
53
|
+
height: 100%;
|
|
54
|
+
cursor: col-resize;
|
|
55
|
+
width: 11px;
|
|
56
|
+
|
|
57
|
+
&::before {
|
|
58
|
+
content: '';
|
|
59
|
+
position: absolute;
|
|
60
|
+
top: 0;
|
|
61
|
+
bottom: 0;
|
|
62
|
+
left: 50%;
|
|
63
|
+
width: 1px;
|
|
64
|
+
transform: translateX(-50%);
|
|
65
|
+
background: var(--rad-ui-color-gray-500); // step 6 — separator line
|
|
66
|
+
transition: background-color var(--rad-ui-motion-duration-fast) ease, width var(--rad-ui-motion-duration-fast) ease;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
&::after {
|
|
70
|
+
content: '';
|
|
71
|
+
position: absolute;
|
|
72
|
+
top: 50%;
|
|
73
|
+
left: 50%;
|
|
74
|
+
width: 0.3125rem;
|
|
75
|
+
height: 1.75rem;
|
|
76
|
+
transform: translate(-50%, -50%);
|
|
77
|
+
border-radius: var(--rad-ui-radius-full);
|
|
78
|
+
background: var(--rad-ui-solid-background);
|
|
79
|
+
opacity: 1;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
&:hover::before,
|
|
83
|
+
&:focus-visible::before,
|
|
84
|
+
&.active::before,
|
|
85
|
+
&:active::before {
|
|
86
|
+
width: 2px;
|
|
87
|
+
background: var(--rad-ui-focus-ring-color); // accent — interaction signal
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
&[data-disabled]::before {
|
|
91
|
+
width: 1px;
|
|
92
|
+
background: var(--rad-ui-color-gray-500);
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
&[aria-orientation="vertical"] {
|
|
97
|
+
width: 100%;
|
|
98
|
+
cursor: row-resize;
|
|
99
|
+
height: 11px;
|
|
100
|
+
|
|
101
|
+
&::before {
|
|
102
|
+
content: '';
|
|
103
|
+
position: absolute;
|
|
104
|
+
left: 0;
|
|
105
|
+
right: 0;
|
|
106
|
+
top: 50%;
|
|
107
|
+
height: 1px;
|
|
108
|
+
transform: translateY(-50%);
|
|
109
|
+
background: var(--rad-ui-color-gray-500); // step 6 — separator line
|
|
110
|
+
transition: background-color var(--rad-ui-motion-duration-fast) ease, height var(--rad-ui-motion-duration-fast) ease;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
&::after {
|
|
114
|
+
content: '';
|
|
115
|
+
position: absolute;
|
|
116
|
+
top: 50%;
|
|
117
|
+
left: 50%;
|
|
118
|
+
width: 1.75rem;
|
|
119
|
+
height: 0.3125rem;
|
|
120
|
+
transform: translate(-50%, -50%);
|
|
121
|
+
border-radius: var(--rad-ui-radius-full);
|
|
122
|
+
background: var(--rad-ui-solid-background);
|
|
123
|
+
opacity: 1;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
&:hover::before,
|
|
127
|
+
&:focus-visible::before,
|
|
128
|
+
&.active::before,
|
|
129
|
+
&:active::before {
|
|
130
|
+
height: 2px;
|
|
131
|
+
background: var(--rad-ui-focus-ring-color); // accent — interaction signal
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
&[data-disabled]::before {
|
|
135
|
+
height: 1px;
|
|
136
|
+
background: var(--rad-ui-color-gray-500);
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
// Declared after the orientation blocks so it overrides their resize cursors.
|
|
142
|
+
.rad-ui-splitter-handle[data-disabled] {
|
|
143
|
+
cursor: not-allowed;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
@media (prefers-reduced-motion: reduce) {
|
|
147
|
+
.rad-ui-splitter-handle::before {
|
|
148
|
+
transition: none;
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
}
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
// Steps — Clarity design system aligned
|
|
2
|
+
// Bubble border (default): step 6 (500) — light border
|
|
3
|
+
// Bubble bg (default): step 2 (100) — subtle surface
|
|
4
|
+
// Bubble text (default): step 8 (700) — muted/disabled text
|
|
5
|
+
// Connector line (default): step 6 (500) — light separator
|
|
6
|
+
// Active bubble border: accent-500 — interactive selected state
|
|
7
|
+
// Active bubble bg: accent-50 — subtle accent surface
|
|
8
|
+
// Active bubble text: accent-900 — accessible accent text
|
|
9
|
+
// Active bubble ring: accent-100 — soft glow
|
|
10
|
+
// Completed bubble bg: accent-800 — solid accent fill
|
|
11
|
+
// Completed bubble border: accent-600 — solid border
|
|
12
|
+
// Completed line: accent-800 — solid accent connector
|
|
13
|
+
// Title: step 11 (1000) — primary text
|
|
14
|
+
// Description: step 8 (700) — supporting content
|
|
15
|
+
|
|
16
|
+
.rad-ui-steps {
|
|
17
|
+
.rad-ui-steps-item {
|
|
18
|
+
display: flex;
|
|
19
|
+
flex-direction: row;
|
|
20
|
+
gap: 16px;
|
|
21
|
+
position: relative;
|
|
22
|
+
|
|
23
|
+
.rad-ui-steps-track {
|
|
24
|
+
display: flex;
|
|
25
|
+
flex-direction: column;
|
|
26
|
+
align-items: center;
|
|
27
|
+
gap: 4px;
|
|
28
|
+
|
|
29
|
+
.rad-ui-steps-bubble {
|
|
30
|
+
width: 32px;
|
|
31
|
+
height: 32px;
|
|
32
|
+
border: 1px solid var(--rad-ui-color-gray-500); // step 6 — light border
|
|
33
|
+
background-color: var(--rad-ui-color-gray-100); // step 2 — subtle surface
|
|
34
|
+
border-radius: 50%;
|
|
35
|
+
display: flex;
|
|
36
|
+
align-items: center;
|
|
37
|
+
justify-content: center;
|
|
38
|
+
font-size: 14px;
|
|
39
|
+
font-weight: 600;
|
|
40
|
+
color: var(--rad-ui-text-secondary);
|
|
41
|
+
z-index: 2;
|
|
42
|
+
transition: border-color var(--rad-ui-motion-duration-fast) ease, background-color var(--rad-ui-motion-duration-fast) ease;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.rad-ui-steps-line {
|
|
46
|
+
width: 2px;
|
|
47
|
+
flex: 1;
|
|
48
|
+
min-height: 20px;
|
|
49
|
+
background-color: var(--rad-ui-color-gray-500); // step 6 — light separator
|
|
50
|
+
margin: 4px 0;
|
|
51
|
+
border-radius: 1px;
|
|
52
|
+
transition: background-color var(--rad-ui-motion-duration-fast) ease;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
&[data-state="active"] {
|
|
57
|
+
.rad-ui-steps-bubble {
|
|
58
|
+
border-color: var(--rad-ui-color-accent-500); // accent — active border
|
|
59
|
+
background-color: var(--rad-ui-color-accent-50); // accent — subtle surface
|
|
60
|
+
color: var(--rad-ui-color-accent-900); // accent — accessible text
|
|
61
|
+
box-shadow: 0 0 0 4px var(--rad-ui-color-accent-100); // accent — soft ring
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
&[data-state="completed"] {
|
|
66
|
+
.rad-ui-steps-bubble {
|
|
67
|
+
border-color: var(--rad-ui-color-accent-600); // accent — solid border
|
|
68
|
+
background-color: var(--rad-ui-color-accent-800); // accent — solid fill
|
|
69
|
+
color: var(--rad-ui-color-gray-50); // step 1 — inverse text
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
// stylelint-disable-next-line no-descending-specificity
|
|
73
|
+
.rad-ui-steps-track .rad-ui-steps-line {
|
|
74
|
+
background-color: var(--rad-ui-color-accent-800); // accent — completed connector
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
.rad-ui-steps-content {
|
|
79
|
+
padding-bottom: 24px;
|
|
80
|
+
padding-top: 4px;
|
|
81
|
+
display: flex;
|
|
82
|
+
flex-direction: column;
|
|
83
|
+
gap: 4px;
|
|
84
|
+
|
|
85
|
+
.rad-ui-steps-title {
|
|
86
|
+
font-size: 15px;
|
|
87
|
+
font-weight: 600;
|
|
88
|
+
color: var(--rad-ui-color-gray-1000); // step 11 — primary text
|
|
89
|
+
line-height: 1.2;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.rad-ui-steps-description {
|
|
93
|
+
font-size: 13px;
|
|
94
|
+
color: var(--rad-ui-text-secondary);
|
|
95
|
+
line-height: 1.4;
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
&:last-child {
|
|
100
|
+
.rad-ui-steps-line {
|
|
101
|
+
display: none;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
.rad-ui-steps-content {
|
|
105
|
+
padding-bottom: 0;
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
// Horizontal orientation: steps sit in a row; the track runs left-to-right with the
|
|
111
|
+
// connector line filling the gap to the next step.
|
|
112
|
+
&[data-orientation="horizontal"] {
|
|
113
|
+
display: flex;
|
|
114
|
+
flex-direction: row;
|
|
115
|
+
align-items: flex-start;
|
|
116
|
+
|
|
117
|
+
.rad-ui-steps-item {
|
|
118
|
+
flex: 1 1 0;
|
|
119
|
+
flex-direction: column;
|
|
120
|
+
gap: var(--rad-ui-spacing-2);
|
|
121
|
+
min-width: 0;
|
|
122
|
+
|
|
123
|
+
.rad-ui-steps-track {
|
|
124
|
+
flex-direction: row;
|
|
125
|
+
width: 100%;
|
|
126
|
+
|
|
127
|
+
.rad-ui-steps-line {
|
|
128
|
+
width: auto;
|
|
129
|
+
height: var(--rad-ui-border-width-2);
|
|
130
|
+
min-height: var(--rad-ui-spacing-0);
|
|
131
|
+
min-width: 20px;
|
|
132
|
+
margin: 0 var(--rad-ui-spacing-1);
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
.rad-ui-steps-content {
|
|
137
|
+
padding-bottom: var(--rad-ui-spacing-0);
|
|
138
|
+
padding-inline-end: var(--rad-ui-spacing-4);
|
|
139
|
+
overflow-wrap: anywhere;
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
}
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
// Switch — Clarity design system aligned
|
|
2
|
+
// Off track bg: step 4 (300) — muted filled track
|
|
3
|
+
// Off track border: step 7 (600) — defined border
|
|
4
|
+
// Off hover bg/border: step 5/8 (400/700) — stronger muted state
|
|
5
|
+
// On track bg: accent-800 — solid accent fill
|
|
6
|
+
// On track border: accent-600 — solid accent border
|
|
7
|
+
// Thumb bg: step 3 (200) — filled muted knob
|
|
8
|
+
// Thumb border: step 8 (700) — defined knob edge
|
|
9
|
+
// Thumb checked bg: accent-50 — subtle accent tint on knob
|
|
10
|
+
|
|
11
|
+
.rad-ui-switch {
|
|
12
|
+
--rad-ui-switch-width: calc(var(--rad-ui-size-10) + var(--rad-ui-spacing-1));
|
|
13
|
+
--rad-ui-switch-height: calc(var(--rad-ui-size-6) + (var(--rad-ui-spacing-1) / 2));
|
|
14
|
+
--rad-ui-switch-thumb-shift: calc(var(--rad-ui-size-5) - (var(--rad-ui-spacing-1) / 2));
|
|
15
|
+
|
|
16
|
+
all: unset;
|
|
17
|
+
box-sizing: border-box;
|
|
18
|
+
position: relative;
|
|
19
|
+
display: inline-flex;
|
|
20
|
+
align-items: center;
|
|
21
|
+
flex-shrink: 0;
|
|
22
|
+
line-height: 0;
|
|
23
|
+
width: var(--rad-ui-switch-width);
|
|
24
|
+
height: var(--rad-ui-switch-height);
|
|
25
|
+
border-radius: var(--rad-ui-control-radius-pill);
|
|
26
|
+
background-color: var(--rad-ui-color-gray-300); // step 4 — muted filled track
|
|
27
|
+
border: var(--rad-ui-border-width-default) solid var(--rad-ui-color-gray-600); // step 7 — defined border
|
|
28
|
+
cursor: pointer;
|
|
29
|
+
transition:
|
|
30
|
+
background-color var(--rad-ui-motion-duration-normal) var(--rad-ui-motion-easing-standard),
|
|
31
|
+
border-color var(--rad-ui-motion-duration-normal) var(--rad-ui-motion-easing-standard),
|
|
32
|
+
box-shadow var(--rad-ui-motion-duration-normal) var(--rad-ui-motion-easing-standard),
|
|
33
|
+
opacity var(--rad-ui-motion-duration-normal) var(--rad-ui-motion-easing-standard);
|
|
34
|
+
|
|
35
|
+
&:hover {
|
|
36
|
+
background-color: var(--rad-ui-color-gray-400); // step 5 — stronger muted fill
|
|
37
|
+
border-color: var(--rad-ui-color-gray-700); // step 8 — stronger border
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
&[data-state="checked"] {
|
|
41
|
+
background-color: var(--rad-ui-color-accent-800); // accent — solid fill
|
|
42
|
+
border-color: var(--rad-ui-color-accent-600); // accent — solid border
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
&[data-disabled],
|
|
46
|
+
&:disabled {
|
|
47
|
+
opacity: 0.5;
|
|
48
|
+
cursor: not-allowed;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
&:focus-visible {
|
|
52
|
+
outline: none;
|
|
53
|
+
box-shadow: var(--rad-ui-focus-ring-shadow);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.rad-ui-switch-indicator {
|
|
57
|
+
position: absolute;
|
|
58
|
+
top: 50%;
|
|
59
|
+
left: var(--rad-ui-border-width-default);
|
|
60
|
+
display: inline-flex;
|
|
61
|
+
align-items: center;
|
|
62
|
+
justify-content: center;
|
|
63
|
+
width: var(--rad-ui-size-5);
|
|
64
|
+
height: var(--rad-ui-size-5);
|
|
65
|
+
border-radius: var(--rad-ui-control-radius-pill);
|
|
66
|
+
background-color: var(--rad-ui-color-gray-200); // step 3 — filled muted knob
|
|
67
|
+
box-shadow:
|
|
68
|
+
var(--rad-ui-shadow-xs),
|
|
69
|
+
inset 0 0 0 1px var(--rad-ui-color-gray-700); // step 8 — defined knob edge
|
|
70
|
+
|
|
71
|
+
transform: translateY(-50%) translateX(0);
|
|
72
|
+
transition:
|
|
73
|
+
transform var(--rad-ui-motion-duration-slow) var(--rad-ui-motion-easing-spring),
|
|
74
|
+
background-color var(--rad-ui-motion-duration-normal) var(--rad-ui-motion-easing-standard),
|
|
75
|
+
box-shadow var(--rad-ui-motion-duration-normal) var(--rad-ui-motion-easing-standard);
|
|
76
|
+
|
|
77
|
+
&[data-state="checked"] {
|
|
78
|
+
transform: translateY(-50%) translateX(var(--rad-ui-switch-thumb-shift));
|
|
79
|
+
background-color: var(--rad-ui-color-accent-50); // accent — subtle tint on knob
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
@media (prefers-reduced-motion: reduce) {
|
|
85
|
+
.rad-ui-switch,
|
|
86
|
+
.rad-ui-switch .rad-ui-switch-indicator {
|
|
87
|
+
transition-duration: var(--rad-ui-motion-duration-reduced);
|
|
88
|
+
}
|
|
89
|
+
}
|