@radui/ui 1.0.0 → 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.
Files changed (265) hide show
  1. package/dist/components/Accordion.cjs +1 -0
  2. package/dist/components/Accordion.js +1 -1
  3. package/dist/components/AlertDialog.cjs +1 -0
  4. package/dist/components/AlertDialog.d.ts +61 -24
  5. package/dist/components/AlertDialog.js +1 -1
  6. package/dist/components/AspectRatio.cjs +1 -0
  7. package/dist/components/Avatar.cjs +1 -0
  8. package/dist/components/Avatar.d.ts +36 -6
  9. package/dist/components/Avatar.js +1 -1
  10. package/dist/components/AvatarGroup.cjs +1 -0
  11. package/dist/components/AvatarGroup.d.ts +39 -18
  12. package/dist/components/AvatarGroup.js +1 -1
  13. package/dist/components/AvatarPrimitiveFallback-BpUU1vNV.cjs +1 -0
  14. package/dist/components/{AvatarPrimitiveFallback-C1siRii4.js → AvatarPrimitiveFallback-DIXB9Tnm.js} +1 -1
  15. package/dist/components/Badge.cjs +1 -0
  16. package/dist/components/Badge.js +1 -1
  17. package/dist/components/BlockQuote.cjs +1 -0
  18. package/dist/components/Breadcrumb.cjs +1 -0
  19. package/dist/components/Breadcrumb.js +1 -1
  20. package/dist/components/Button.cjs +1 -0
  21. package/dist/components/Button.js +1 -1
  22. package/dist/components/Callout.cjs +1 -0
  23. package/dist/components/Callout.d.ts +32 -18
  24. package/dist/components/Callout.js +1 -1
  25. package/dist/components/Card.cjs +1 -0
  26. package/dist/components/Card.d.ts +31 -16
  27. package/dist/components/Card.js +1 -1
  28. package/dist/components/Checkbox.cjs +8 -0
  29. package/dist/components/Checkbox.js +1 -1
  30. package/dist/components/CheckboxCards.cjs +1 -0
  31. package/dist/components/CheckboxCards.js +1 -1
  32. package/dist/components/CheckboxGroup.cjs +1 -0
  33. package/dist/components/CheckboxGroup.d.ts +6 -2
  34. package/dist/components/CheckboxGroup.js +1 -1
  35. package/dist/components/{CheckboxGroupPrimitive-DfHQYkep.js → CheckboxGroupPrimitive-BRCGIztp.js} +1 -1
  36. package/dist/components/CheckboxGroupPrimitive-C21WO4L3.cjs +1 -0
  37. package/dist/components/Code.cjs +1 -0
  38. package/dist/components/Collapsible.cjs +1 -0
  39. package/dist/components/Collapsible.d.ts +34 -4
  40. package/dist/components/Collapsible.js +1 -1
  41. package/dist/components/Combobox.cjs +1 -0
  42. package/dist/components/Combobox.d.ts +57 -45
  43. package/dist/components/Combobox.js +1 -1
  44. package/dist/components/ComboboxPrimitive-BdX2jgpQ.js +1 -0
  45. package/dist/components/ComboboxPrimitive-CyO6ZH5T.cjs +1 -0
  46. package/dist/components/Command.cjs +1 -0
  47. package/dist/components/Command.d.ts +36 -8
  48. package/dist/components/Command.js +1 -1
  49. package/dist/components/ContextMenu.cjs +1 -0
  50. package/dist/components/ContextMenu.d.ts +25 -11
  51. package/dist/components/ContextMenu.js +1 -1
  52. package/dist/components/DataList.cjs +1 -0
  53. package/dist/components/Dialog.cjs +1 -0
  54. package/dist/components/Dialog.d.ts +29 -4
  55. package/dist/components/Dialog.js +1 -1
  56. package/dist/components/Disclosure.cjs +1 -0
  57. package/dist/components/Disclosure.js +1 -1
  58. package/dist/components/Drawer.cjs +1 -0
  59. package/dist/components/Drawer.d.ts +31 -3
  60. package/dist/components/Drawer.js +1 -1
  61. package/dist/components/DropdownMenu.cjs +1 -0
  62. package/dist/components/DropdownMenu.d.ts +25 -11
  63. package/dist/components/DropdownMenu.js +1 -1
  64. package/dist/components/Em.cjs +1 -0
  65. package/dist/components/Fieldset.cjs +1 -0
  66. package/dist/components/Heading.cjs +1 -0
  67. package/dist/components/HoverCard.cjs +1 -0
  68. package/dist/components/HoverCard.d.ts +15 -1
  69. package/dist/components/HoverCard.js +1 -1
  70. package/dist/components/Kbd.cjs +1 -0
  71. package/dist/components/Label.cjs +1 -0
  72. package/dist/components/Label.d.ts +18 -0
  73. package/dist/components/Label.js +1 -0
  74. package/dist/components/Link.cjs +1 -0
  75. package/dist/components/Link.js +1 -1
  76. package/dist/components/LiveRegion.cjs +1 -0
  77. package/dist/components/LiveRegion.d.ts +2 -5
  78. package/dist/components/LiveRegion.js +1 -1
  79. package/dist/components/MenuPrimitive-Ctqo21Vd.cjs +1 -0
  80. package/dist/components/MenuPrimitive-Cy_MJfjG.js +1 -0
  81. package/dist/components/Menubar.cjs +1 -0
  82. package/dist/components/Menubar.d.ts +45 -16
  83. package/dist/components/Menubar.js +1 -1
  84. package/dist/components/Meter.cjs +1 -0
  85. package/dist/components/Meter.d.ts +44 -0
  86. package/dist/components/Meter.js +1 -0
  87. package/dist/components/Minimap.cjs +1 -0
  88. package/dist/components/Minimap.js +1 -1
  89. package/dist/components/NavigationMenu.cjs +1 -0
  90. package/dist/components/NavigationMenu.d.ts +2 -0
  91. package/dist/components/NavigationMenu.js +1 -1
  92. package/dist/components/NumberField.cjs +1 -0
  93. package/dist/components/Popover.cjs +1 -0
  94. package/dist/components/Popover.d.ts +64 -5
  95. package/dist/components/Popover.js +1 -1
  96. package/dist/components/Progress.cjs +1 -0
  97. package/dist/components/Progress.d.ts +14 -2
  98. package/dist/components/Progress.js +1 -1
  99. package/dist/components/Quote.cjs +1 -0
  100. package/dist/components/Radio.cjs +1 -0
  101. package/dist/components/Radio.js +1 -1
  102. package/dist/components/RadioCards.cjs +1 -0
  103. package/dist/components/RadioCards.d.ts +22 -1
  104. package/dist/components/RadioCards.js +1 -1
  105. package/dist/components/RadioGroup.cjs +1 -0
  106. package/dist/components/RadioGroup.d.ts +27 -7
  107. package/dist/components/RadioGroup.js +1 -1
  108. package/dist/components/RadioGroupPrimitive-B0CrM2bi.cjs +1 -0
  109. package/dist/components/RadioGroupPrimitive-CnPy0zgW.js +1 -0
  110. package/dist/components/ScrollArea.cjs +1 -0
  111. package/dist/components/ScrollArea.d.ts +24 -13
  112. package/dist/components/ScrollArea.js +1 -1
  113. package/dist/components/Select.cjs +1 -0
  114. package/dist/components/Select.d.ts +52 -44
  115. package/dist/components/Select.js +1 -1
  116. package/dist/components/Separator.cjs +1 -0
  117. package/dist/components/Separator.d.ts +8 -1
  118. package/dist/components/Separator.js +1 -1
  119. package/dist/components/Skeleton.cjs +1 -0
  120. package/dist/components/Slider.cjs +1 -0
  121. package/dist/components/Slider.js +1 -1
  122. package/dist/components/Spinner.cjs +1 -0
  123. package/dist/components/Splitter.cjs +1 -0
  124. package/dist/components/Steps.cjs +1 -0
  125. package/dist/components/Steps.d.ts +33 -16
  126. package/dist/components/Steps.js +1 -1
  127. package/dist/components/Strong.cjs +1 -0
  128. package/dist/components/Switch.cjs +1 -0
  129. package/dist/components/Switch.d.ts +14 -2
  130. package/dist/components/Switch.js +1 -1
  131. package/dist/components/TabNav.cjs +1 -0
  132. package/dist/components/TabNav.d.ts +5 -0
  133. package/dist/components/TabNav.js +1 -1
  134. package/dist/components/Table.cjs +1 -0
  135. package/dist/components/Table.d.ts +23 -12
  136. package/dist/components/Table.js +1 -1
  137. package/dist/components/Tabs.cjs +1 -0
  138. package/dist/components/Tabs.js +1 -1
  139. package/dist/components/Text.cjs +1 -0
  140. package/dist/components/TextArea.cjs +1 -0
  141. package/dist/components/TextField.cjs +1 -0
  142. package/dist/components/Theme.cjs +1 -0
  143. package/dist/components/Theme.d.ts +2 -0
  144. package/dist/components/Theme.js +1 -1
  145. package/dist/components/ThemeContext-t7IX-w6i.cjs +1 -0
  146. package/dist/components/Toast.cjs +1 -0
  147. package/dist/components/Toast.js +1 -1
  148. package/dist/components/Toggle.cjs +1 -0
  149. package/dist/components/Toggle.js +1 -1
  150. package/dist/components/ToggleGroup.cjs +1 -0
  151. package/dist/components/ToggleGroup.js +1 -1
  152. package/dist/components/Toolbar.cjs +1 -0
  153. package/dist/components/Toolbar.d.ts +8 -1
  154. package/dist/components/Toolbar.js +1 -1
  155. package/dist/components/Tooltip.cjs +1 -0
  156. package/dist/components/Tooltip.d.ts +7 -1
  157. package/dist/components/Tooltip.js +1 -1
  158. package/dist/components/Tree.cjs +1 -0
  159. package/dist/components/Tree.d.ts +8 -1
  160. package/dist/components/Tree.js +1 -1
  161. package/dist/components/VisuallyHidden.cjs +1 -0
  162. package/dist/components/VisuallyHidden.d.ts +6 -1
  163. package/dist/components/VisuallyHidden.js +1 -1
  164. package/dist/components/check-BazcmpuG.cjs +44 -0
  165. package/dist/components/documentOverlayOpen-BbC6uByx.cjs +1 -0
  166. package/dist/components/{floating-ui.react-2kiGB4sW.js → floating-ui.react-CZf-mCiA.js} +1 -1
  167. package/dist/components/floating-ui.react-Kw0_L48Q.cjs +5 -0
  168. package/dist/components/index-7Bjw6jmo.cjs +1 -0
  169. package/dist/components/index-BZO29jsF.cjs +1 -0
  170. package/dist/components/index-B_OPdW20.js +1 -0
  171. package/dist/components/index-BbvJO-A-.cjs +1 -0
  172. package/dist/components/index-Bg-UeWCo.cjs +1 -0
  173. package/dist/components/index-BidxkqdT.js +1 -0
  174. package/dist/components/index-BudP4FIn.cjs +1 -0
  175. package/dist/components/index-BwNOI8cB.cjs +1 -0
  176. package/dist/components/{index-DMX7gpdp.js → index-CAD0hWja.js} +1 -1
  177. package/dist/components/{index-xlB--dex.js → index-CXv1Y-O3.js} +1 -1
  178. package/dist/components/index-C_Yiql9j.cjs +1 -0
  179. package/dist/components/index-CbdoW3TC.cjs +1 -0
  180. package/dist/components/{index-nYRBURkR.js → index-Cp5L_alO.js} +1 -1
  181. package/dist/components/{index-C7dBo_Ry.js → index-D8QLtYJh.js} +1 -1
  182. package/dist/components/{index-FITGoHty.js → index-DH-14XDv.js} +1 -1
  183. package/dist/components/index-DrMwbB8q.cjs +1 -0
  184. package/dist/components/index-K0sE1H4u.cjs +1 -0
  185. package/dist/components/index-c6NFMS_0.cjs +1 -0
  186. package/dist/components/index-rUSzFrhJ.cjs +1 -0
  187. package/dist/components/keyboard-BBlFllyi.cjs +1 -0
  188. package/dist/components/mergeProps-DW5qFqqJ.cjs +1 -0
  189. package/dist/components/mergeRefs-BUn-enYe.cjs +1 -0
  190. package/dist/components/useComponentClass-B0DF90tm.cjs +1 -0
  191. package/dist/index.cjs +70 -0
  192. package/dist/index.d.ts +67 -0
  193. package/dist/index.js +69 -0
  194. package/dist/styles/clarity/Accordion/accordion.clarity.scss +147 -0
  195. package/dist/styles/clarity/AlertDialog/alert-dialog.clarity.scss +199 -0
  196. package/dist/styles/clarity/Avatar/_avatar-base.clarity.scss +87 -0
  197. package/dist/styles/clarity/Avatar/avatar.clarity.scss +1 -0
  198. package/dist/styles/clarity/AvatarGroup/avatar-group.clarity.scss +122 -0
  199. package/dist/styles/clarity/Badge/badge.clarity.scss +118 -0
  200. package/dist/styles/clarity/BlockQuote/blockquote.clarity.scss +123 -0
  201. package/dist/styles/clarity/Breadcrumb/breadcrumb.clarity.scss +50 -0
  202. package/dist/styles/clarity/Button/button.clarity.scss +132 -0
  203. package/dist/styles/clarity/Callout/callout.clarity.scss +183 -0
  204. package/dist/styles/clarity/Card/card.clarity.scss +121 -0
  205. package/dist/styles/clarity/Checkbox/checkbox.clarity.scss +75 -0
  206. package/dist/styles/clarity/CheckboxCards/checkbox-cards.clarity.scss +143 -0
  207. package/dist/styles/clarity/CheckboxGroup/checkbox-group.clarity.scss +92 -0
  208. package/dist/styles/clarity/Code/code.clarity.scss +42 -0
  209. package/dist/styles/clarity/Collapsible/collapsible.clarity.scss +84 -0
  210. package/dist/styles/clarity/Combobox/combobox.clarity.scss +157 -0
  211. package/dist/styles/clarity/Command/command.clarity.scss +231 -0
  212. package/dist/styles/clarity/ContextMenu/context-menu.clarity.scss +272 -0
  213. package/dist/styles/clarity/DataList/data-list.clarity.scss +60 -0
  214. package/dist/styles/clarity/Dialog/dialog.clarity.scss +205 -0
  215. package/dist/styles/clarity/Disclosure/disclosure.clarity.scss +56 -0
  216. package/dist/styles/clarity/Drawer/drawer.clarity.scss +331 -0
  217. package/dist/styles/clarity/DropdownMenu/dropdown-menu.clarity.scss +187 -0
  218. package/dist/styles/clarity/Em/em.clarity.scss +3 -0
  219. package/dist/styles/clarity/Fieldset/fieldset.clarity.scss +49 -0
  220. package/dist/styles/clarity/Heading/heading.clarity.scss +46 -0
  221. package/dist/styles/clarity/HoverCard/hover-card.clarity.scss +43 -0
  222. package/dist/styles/clarity/Kbd/kbd.clarity.scss +55 -0
  223. package/dist/styles/clarity/Label/label.clarity.scss +11 -0
  224. package/dist/styles/clarity/Link/link.clarity.scss +41 -0
  225. package/dist/styles/clarity/Menubar/menubar.clarity.scss +149 -0
  226. package/dist/styles/clarity/Meter/meter.clarity.scss +39 -0
  227. package/dist/styles/clarity/Minimap/minimap.clarity.scss +92 -0
  228. package/dist/styles/clarity/NavigationMenu/navigation-menu.clarity.scss +128 -0
  229. package/dist/styles/clarity/NumberField/number-field.clarity.scss +135 -0
  230. package/dist/styles/clarity/Popover/popover.clarity.scss +106 -0
  231. package/dist/styles/clarity/Progress/progress.clarity.scss +38 -0
  232. package/dist/styles/clarity/Quote/quote.clarity.scss +26 -0
  233. package/dist/styles/clarity/Radio/radio.clarity.scss +76 -0
  234. package/dist/styles/clarity/RadioCards/radiocards.clarity.scss +134 -0
  235. package/dist/styles/clarity/RadioGroup/radio-group.clarity.scss +99 -0
  236. package/dist/styles/clarity/ScrollArea/scroll-area.clarity.scss +112 -0
  237. package/dist/styles/clarity/Select/select.clarity.scss +228 -0
  238. package/dist/styles/clarity/Separator/separator.clarity.scss +23 -0
  239. package/dist/styles/clarity/Skeleton/skeleton.clarity.scss +33 -0
  240. package/dist/styles/clarity/Slider/slider.clarity.scss +203 -0
  241. package/dist/styles/clarity/Spinner/spinner.clarity.scss +52 -0
  242. package/dist/styles/clarity/Splitter/splitter.clarity.scss +151 -0
  243. package/dist/styles/clarity/Steps/steps.clarity.scss +143 -0
  244. package/dist/styles/clarity/Strong/strong.clarity.scss +6 -0
  245. package/dist/styles/clarity/Switch/switch.clarity.scss +89 -0
  246. package/dist/styles/clarity/TabNav/tab-nav.clarity.scss +69 -0
  247. package/dist/styles/clarity/Table/table.clarity.scss +128 -0
  248. package/dist/styles/clarity/Tabs/tabs.clarity.scss +91 -0
  249. package/dist/styles/clarity/Text/text.clarity.scss +5 -0
  250. package/dist/styles/clarity/TextArea/textarea.clarity.scss +146 -0
  251. package/dist/styles/clarity/TextField/text-field.clarity.scss +120 -0
  252. package/dist/styles/clarity/Toast/toast.clarity.scss +203 -0
  253. package/dist/styles/clarity/Toggle/toggle.clarity.scss +51 -0
  254. package/dist/styles/clarity/ToggleGroup/toggle-group.clarity.scss +103 -0
  255. package/dist/styles/clarity/Toolbar/toolbar.clarity.scss +140 -0
  256. package/dist/styles/clarity/Tooltip/tooltip.clarity.scss +37 -0
  257. package/dist/styles/clarity/Tree/tree.clarity.scss +103 -0
  258. package/dist/themes/baremetal.css +1 -1
  259. package/dist/themes/default.css +1 -1
  260. package/package.json +21 -2
  261. package/dist/components/ComboboxPrimitive-DQcJ8pzQ.js +0 -1
  262. package/dist/components/MenuPrimitive-D9VMz2TZ.js +0 -1
  263. package/dist/components/RadioGroupPrimitive-D1PP4y2M.js +0 -1
  264. package/dist/components/index-D8I-rMwz.js +0 -1
  265. package/dist/components/index-XF8itt-H.js +0 -1
@@ -0,0 +1,205 @@
1
+ @use '../Button/button.clarity';
2
+
3
+ .rad-ui-dialog-overlay {
4
+ position: fixed;
5
+ inset: 0;
6
+ z-index: var(--rad-ui-z-index-overlay);
7
+ background-color: var(--rad-ui-overlay-scrim);
8
+ backdrop-filter: blur(var(--rad-ui-blur-lg));
9
+ overflow: hidden;
10
+ transition:
11
+ opacity var(--rad-ui-motion-duration-normal) var(--rad-ui-motion-easing-standard),
12
+ visibility var(--rad-ui-motion-duration-normal) var(--rad-ui-motion-easing-standard);
13
+
14
+ &[data-state="open"] {
15
+ opacity: 1;
16
+ visibility: visible;
17
+ }
18
+
19
+ &[data-state="closed"] {
20
+ opacity: 0;
21
+ visibility: hidden;
22
+ }
23
+ }
24
+
25
+ .rad-ui-dialog-trigger {
26
+ @extend .rad-ui-button-root;
27
+ }
28
+
29
+ .rad-ui-dialog-content {
30
+ --rad-ui-dialog-body-font-size: calc(var(--rad-ui-font-size-2) - (var(--rad-ui-spacing-1) / 4));
31
+ --rad-ui-dialog-title-font-size-mobile: calc(var(--rad-ui-font-size-3) - (var(--rad-ui-spacing-1) / 4));
32
+ --rad-ui-dialog-inline-padding: var(--rad-ui-spacing-4);
33
+ --rad-ui-dialog-inline-padding-mobile: calc(var(--rad-ui-spacing-3) + var(--rad-ui-density-gap-xs));
34
+
35
+ position: fixed;
36
+ left: 50%;
37
+ top: 50%;
38
+ z-index: var(--rad-ui-z-index-portal);
39
+ width: 100%;
40
+ max-width: var(--rad-ui-overlay-width-lg);
41
+ transform: translate(-50%, -50%);
42
+ padding: var(--rad-ui-spacing-4) var(--rad-ui-dialog-inline-padding) 0;
43
+ border-radius: var(--rad-ui-panel-radius-lg);
44
+ background-color: var(--rad-ui-surface-panel);
45
+ color: var(--rad-ui-text-primary);
46
+ border: var(--rad-ui-border-width-default) solid var(--rad-ui-border-soft);
47
+ box-shadow: var(--rad-ui-elevation-lg-shadow);
48
+ display: flex;
49
+ flex-direction: column;
50
+ gap: 0;
51
+ overflow: hidden;
52
+ transition:
53
+ opacity var(--rad-ui-motion-duration-normal) var(--rad-ui-motion-easing-standard),
54
+ visibility var(--rad-ui-motion-duration-normal) var(--rad-ui-motion-easing-standard),
55
+ transform var(--rad-ui-motion-duration-normal) var(--rad-ui-motion-easing-standard);
56
+
57
+ &[data-state="open"] {
58
+ opacity: 1;
59
+ visibility: visible;
60
+ transform: translate(-50%, -50%) scale(1);
61
+ }
62
+
63
+ &[data-state="closed"] {
64
+ opacity: 0;
65
+ visibility: hidden;
66
+ transform: translate(-50%, -50%) scale(0.95);
67
+ }
68
+
69
+ &:focus {
70
+ outline: none;
71
+ }
72
+
73
+ // Nested child components
74
+ .rad-ui-dialog-title {
75
+ font-size: var(--rad-ui-font-size-3);
76
+ font-weight: var(--rad-ui-component-font-weight-medium);
77
+ line-height: calc(var(--rad-ui-component-line-height-tight) + 0.15);
78
+ margin: 0;
79
+ margin-bottom: var(--rad-ui-spacing-2);
80
+ color: var(--rad-ui-text-primary);
81
+ letter-spacing: -0.05em;
82
+ }
83
+
84
+ .rad-ui-dialog-description {
85
+ max-width: calc(var(--rad-ui-overlay-width-lg) - var(--rad-ui-spacing-12) - var(--rad-ui-size-4));
86
+ font-size: var(--rad-ui-dialog-body-font-size);
87
+ font-weight: var(--rad-ui-component-font-weight-regular);
88
+ line-height: calc(var(--rad-ui-component-line-height-normal) + 0.2);
89
+ margin: 0;
90
+ margin-bottom: calc(var(--rad-ui-spacing-3) + var(--rad-ui-density-gap-xs));
91
+ color: var(--rad-ui-text-secondary);
92
+ letter-spacing: -0.025em;
93
+ }
94
+
95
+ .rad-ui-dialog-footer {
96
+ display: flex;
97
+ flex-direction: column-reverse;
98
+ gap: var(--rad-ui-spacing-2);
99
+ margin: 0 calc(var(--rad-ui-dialog-inline-padding) * -1);
100
+ padding: calc(var(--rad-ui-spacing-3) + var(--rad-ui-density-gap-xs)) var(--rad-ui-dialog-inline-padding) var(--rad-ui-spacing-4);
101
+ border-top: var(--rad-ui-border-width-default) solid var(--rad-ui-border-soft);
102
+ background-color: var(--rad-ui-surface-subtle);
103
+ border-bottom-left-radius: inherit;
104
+ border-bottom-right-radius: inherit;
105
+
106
+ @media (width >= 640px) {
107
+ flex-direction: row;
108
+ justify-content: flex-end;
109
+ align-items: center;
110
+ }
111
+ }
112
+
113
+ // Close renders as a ghost control so text children ("Close") get real
114
+ // padding and icon-only children stay square. By default it sits in the
115
+ // header corner, with its label edge aligned to the content inline padding.
116
+ .rad-ui-dialog-close {
117
+ position: absolute;
118
+ right: calc(var(--rad-ui-dialog-inline-padding) - var(--rad-ui-control-padding-x-sm));
119
+ top: calc(var(--rad-ui-spacing-2) + var(--rad-ui-density-gap-xs));
120
+ box-sizing: border-box;
121
+ display: inline-flex;
122
+ align-items: center;
123
+ justify-content: center;
124
+ gap: var(--rad-ui-density-gap-sm);
125
+ min-width: var(--rad-ui-control-height-sm);
126
+ min-height: var(--rad-ui-control-height-sm);
127
+ padding: 0 var(--rad-ui-control-padding-x-sm);
128
+ border: var(--rad-ui-border-width-default) solid transparent;
129
+ border-radius: var(--rad-ui-control-radius-md);
130
+ background-color: transparent;
131
+ color: var(--rad-ui-text-secondary);
132
+ font-family: inherit;
133
+ font-size: var(--rad-ui-component-font-size-sm);
134
+ font-weight: var(--rad-ui-component-font-weight-medium);
135
+ line-height: var(--rad-ui-component-line-height-tight);
136
+ white-space: nowrap;
137
+ opacity: 1;
138
+ cursor: pointer;
139
+ transition:
140
+ background-color var(--rad-ui-motion-duration-fast) ease,
141
+ border-color var(--rad-ui-motion-duration-fast) ease,
142
+ color var(--rad-ui-motion-duration-fast) ease;
143
+
144
+ svg {
145
+ width: var(--rad-ui-icon-size-sm);
146
+ height: var(--rad-ui-icon-size-sm);
147
+ flex-shrink: 0;
148
+ }
149
+
150
+ &:hover {
151
+ color: var(--rad-ui-text-primary);
152
+ background-color: var(--rad-ui-surface-hover);
153
+ }
154
+
155
+ &:focus-visible {
156
+ outline: none;
157
+ box-shadow: var(--rad-ui-focus-ring-shadow);
158
+ }
159
+
160
+ &:disabled {
161
+ pointer-events: none;
162
+ opacity: 0.5;
163
+ }
164
+ }
165
+
166
+ // Inside the footer the close is an in-flow secondary action, not a corner
167
+ // control, so the footer keeps its content instead of rendering empty.
168
+ .rad-ui-dialog-footer .rad-ui-dialog-close {
169
+ position: static;
170
+ min-height: var(--rad-ui-control-height-md);
171
+ padding: 0 var(--rad-ui-control-padding-x-md);
172
+ border-color: var(--rad-ui-border-default);
173
+ background-color: var(--rad-ui-surface-panel);
174
+ color: var(--rad-ui-text-primary);
175
+ box-shadow: var(--rad-ui-control-shadow);
176
+
177
+ &:hover {
178
+ background-color: var(--rad-ui-surface-hover);
179
+ border-color: var(--rad-ui-border-strong);
180
+ }
181
+ }
182
+
183
+ // Responsive adjustments
184
+ @media (width <= 640px) {
185
+ max-width: calc(100% - 2rem);
186
+ margin: var(--rad-ui-spacing-4);
187
+ padding: calc(var(--rad-ui-spacing-3) + var(--rad-ui-density-gap-xs)) var(--rad-ui-dialog-inline-padding-mobile) 0;
188
+ border-radius: calc(var(--rad-ui-panel-radius-md) + var(--rad-ui-density-gap-xs));
189
+
190
+ .rad-ui-dialog-title {
191
+ font-size: var(--rad-ui-dialog-title-font-size-mobile);
192
+ margin-bottom: var(--rad-ui-spacing-2);
193
+ }
194
+
195
+ .rad-ui-dialog-description {
196
+ font-size: var(--rad-ui-dialog-body-font-size);
197
+ margin-bottom: calc(var(--rad-ui-spacing-3) + var(--rad-ui-density-gap-xs));
198
+ }
199
+
200
+ .rad-ui-dialog-footer {
201
+ margin: 0 calc(var(--rad-ui-dialog-inline-padding-mobile) * -1);
202
+ padding: var(--rad-ui-spacing-3) var(--rad-ui-dialog-inline-padding-mobile) var(--rad-ui-dialog-inline-padding-mobile);
203
+ }
204
+ }
205
+ }
@@ -0,0 +1,56 @@
1
+ .rad-ui-disclosure-root{
2
+ border: 1px solid var(--rad-ui-border-soft);
3
+ border-radius: var(--rad-ui-radius-lg);
4
+ background-color: var(--rad-ui-surface-panel);
5
+
6
+ .rad-ui-disclosure-item{
7
+ margin: 0;
8
+ border-bottom: 1px solid var(--rad-ui-border-soft);
9
+
10
+ &:focus-within{
11
+ color: var(--rad-ui-text-primary);
12
+ }
13
+
14
+
15
+ .rad-ui-disclosure-trigger{
16
+ display: flex;
17
+ width: 100%;
18
+ padding: var(--rad-ui-spacing-4);
19
+ font-weight: 600;
20
+ color: var(--rad-ui-text-primary);
21
+ background-color: transparent;
22
+ border: none;
23
+ text-align: left;
24
+ cursor: pointer;
25
+
26
+ &:focus-visible{
27
+ outline: none;
28
+ box-shadow: var(--rad-ui-focus-ring-shadow-inset);
29
+ }
30
+
31
+ &:hover {
32
+ background-color: var(--rad-ui-surface-subtle);
33
+ }
34
+
35
+ }
36
+
37
+ .rad-ui-disclosure-content{
38
+ // No vertical padding on the animated element: the height animation cannot go below
39
+ // padding, so the last 1rem would snap away when the close finishes. The bottom
40
+ // spacing lives in a pseudo-element inside the box, which collapses with the height.
41
+ padding: 0 var(--rad-ui-spacing-4);
42
+ background-color: var(--rad-ui-surface-panel);
43
+ color: var(--rad-ui-text-muted);
44
+
45
+ &::after {
46
+ content: "";
47
+ display: block;
48
+ height: var(--rad-ui-spacing-4);
49
+ }
50
+ }
51
+
52
+ &:last-child {
53
+ border-bottom: none;
54
+ }
55
+ }
56
+ }
@@ -0,0 +1,331 @@
1
+ @use '../Button/button.clarity';
2
+
3
+ $open-duration: var(--rad-ui-drawer-open-duration, var(--rad-ui-motion-duration-slower));
4
+ $close-duration: var(--rad-ui-drawer-close-duration, var(--rad-ui-motion-duration-slow));
5
+ $open-easing: var(--rad-ui-motion-easing-entrance);
6
+ $close-easing: var(--rad-ui-motion-easing-standard);
7
+
8
+ .rad-ui-drawer-overlay {
9
+ position: fixed;
10
+ inset: 0;
11
+ z-index: var(--rad-ui-z-index-overlay);
12
+ background-color: var(--rad-ui-overlay-scrim);
13
+ backdrop-filter: blur(var(--rad-ui-blur-lg));
14
+ overflow: hidden;
15
+ transition:
16
+ opacity $close-duration $close-easing,
17
+ visibility $close-duration $close-easing;
18
+
19
+ &[data-state="open"] {
20
+ opacity: 1;
21
+ visibility: visible;
22
+ transition:
23
+ opacity $open-duration $open-easing,
24
+ visibility $open-duration $open-easing;
25
+ }
26
+
27
+ &[data-state="closed"] {
28
+ opacity: 0;
29
+ visibility: hidden;
30
+ }
31
+ }
32
+
33
+ .rad-ui-drawer-trigger {
34
+ @extend .rad-ui-button-root;
35
+
36
+ position: relative;
37
+ isolation: isolate;
38
+
39
+ &:focus-visible {
40
+ outline: none;
41
+ box-shadow:
42
+ var(--rad-ui-focus-ring-shadow-offset-panel),
43
+ var(--rad-ui-shadow-md);
44
+ }
45
+ }
46
+
47
+ .rad-ui-drawer-content {
48
+ position: fixed;
49
+ z-index: var(--rad-ui-z-index-portal);
50
+ background-color: var(--rad-ui-surface-panel);
51
+ color: var(--rad-ui-text-primary);
52
+ border: 1px solid var(--rad-ui-border-soft);
53
+ box-shadow: var(--rad-ui-elevation-lg-shadow);
54
+ display: flex;
55
+ flex-direction: column;
56
+ gap: 0;
57
+ overflow: visible;
58
+
59
+ // Prevent the browser from intercepting a vertical swipe as page scroll while the
60
+ // drawer is being dragged.
61
+ overscroll-behavior: contain;
62
+ transition:
63
+ opacity $close-duration $close-easing,
64
+ visibility $close-duration $close-easing,
65
+ transform $close-duration $close-easing;
66
+
67
+ // While a swipe is in progress, we disable transitions so the transform tracks
68
+ // the finger without lag, then restore the authored easing for the release.
69
+ &[data-swiping="true"] {
70
+ transition-duration: 0ms !important;
71
+ }
72
+
73
+ @media (prefers-reduced-motion: reduce) {
74
+ transition-duration: 0ms !important;
75
+ &[data-swiping="true"] { transition-duration: 0ms !important; }
76
+ }
77
+
78
+ // ── Side drawers ──────────────────────────────────────────────────────────
79
+
80
+ &[data-swipe-direction="left"] {
81
+ top: 0; left: 0; bottom: 0;
82
+ width: min(24rem, 85vw);
83
+ border-radius: 0 var(--rad-ui-radius-xl) var(--rad-ui-radius-xl) 0;
84
+ border-left: none;
85
+
86
+ // Handle is first child → sits on the right (open) edge
87
+ &:has(.rad-ui-drawer-handle) { flex-direction: row-reverse; }
88
+
89
+ &[data-child-open="true"] {
90
+ width: calc(min(24rem, 85vw) + var(--drawer-peek-offset, 0px));
91
+ }
92
+
93
+ &[data-state="open"] {
94
+ opacity: 1; visibility: visible;
95
+ transform: translateX(calc(-1 * var(--rad-ui-drawer-snap-point-offset, 0px) + var(--rad-ui-drawer-swipe-movement-x, 0px)));
96
+ transition:
97
+ opacity $open-duration $open-easing,
98
+ visibility $open-duration $open-easing,
99
+ transform $open-duration $open-easing,
100
+ width $open-duration $open-easing;
101
+ }
102
+ &[data-state="closed"] { opacity: 0; visibility: hidden; transform: translateX(-100%); }
103
+ }
104
+
105
+ &[data-swipe-direction="right"] {
106
+ top: 0; right: 0; bottom: 0;
107
+ width: min(24rem, 85vw);
108
+ border-radius: var(--rad-ui-radius-xl) 0 0 var(--rad-ui-radius-xl);
109
+ border-right: none;
110
+
111
+ // Handle is first child → sits on the left (open) edge
112
+ &:has(.rad-ui-drawer-handle) { flex-direction: row; }
113
+
114
+ &[data-child-open="true"] {
115
+ width: calc(min(24rem, 85vw) + var(--drawer-peek-offset, 0px));
116
+ }
117
+
118
+ &[data-state="open"] {
119
+ opacity: 1; visibility: visible;
120
+ transform: translateX(calc(var(--rad-ui-drawer-snap-point-offset, 0px) + var(--rad-ui-drawer-swipe-movement-x, 0px)));
121
+ transition:
122
+ opacity $open-duration $open-easing,
123
+ visibility $open-duration $open-easing,
124
+ transform $open-duration $open-easing,
125
+ width $open-duration $open-easing;
126
+ }
127
+ &[data-state="closed"] { opacity: 0; visibility: hidden; transform: translateX(100%); }
128
+ }
129
+
130
+ // ── Top / bottom drawers ──────────────────────────────────────────────────
131
+
132
+ &[data-swipe-direction="top"] {
133
+ left: 0; right: 0; top: 0;
134
+ height: min(24rem, 85vh);
135
+ border-radius: 0 0 var(--rad-ui-radius-xl) var(--rad-ui-radius-xl);
136
+ border-top: none;
137
+
138
+ // Handle is first child → column-reverse puts it at the bottom (open edge)
139
+ &:has(.rad-ui-drawer-handle) { flex-direction: column-reverse; }
140
+
141
+ &[data-child-open="true"] {
142
+ height: calc(min(24rem, 85vh) + var(--drawer-peek-offset, 0px));
143
+ }
144
+
145
+ &[data-state="open"] {
146
+ opacity: 1; visibility: visible;
147
+ transform: translateY(calc(-1 * var(--rad-ui-drawer-snap-point-offset, 0px) + var(--rad-ui-drawer-swipe-movement-y, 0px)));
148
+ transition:
149
+ opacity $open-duration $open-easing,
150
+ visibility $open-duration $open-easing,
151
+ transform $open-duration $open-easing,
152
+ height $open-duration $open-easing;
153
+ }
154
+ &[data-state="closed"] { opacity: 0; visibility: hidden; transform: translateY(-100%); }
155
+ }
156
+
157
+ &[data-swipe-direction="bottom"] {
158
+ left: 0; right: 0; bottom: 0;
159
+ height: min(24rem, 85vh);
160
+ border-radius: var(--rad-ui-radius-xl) var(--rad-ui-radius-xl) 0 0;
161
+ border-bottom: none;
162
+
163
+ &[data-child-open="true"] {
164
+ height: calc(min(24rem, 85vh) + var(--drawer-peek-offset, 0px));
165
+ }
166
+
167
+ &[data-state="open"] {
168
+ opacity: 1; visibility: visible;
169
+ transform: translateY(calc(var(--rad-ui-drawer-snap-point-offset, 0px) + var(--rad-ui-drawer-swipe-movement-y, 0px)));
170
+ transition:
171
+ opacity $open-duration $open-easing,
172
+ visibility $open-duration $open-easing,
173
+ transform $open-duration $open-easing,
174
+ height $open-duration $open-easing;
175
+ }
176
+ &[data-state="closed"] { opacity: 0; visibility: hidden; transform: translateY(100%); }
177
+ }
178
+
179
+ // ── Handle ───────────────────────────────────────────────────────────────
180
+ // In-flow element — the outer content switches flex-direction per direction
181
+ // so the handle always lands on the open (dismissal) edge.
182
+
183
+ .rad-ui-drawer-handle {
184
+ display: flex;
185
+ align-items: center;
186
+ justify-content: center;
187
+ flex-shrink: 0;
188
+ cursor: grab;
189
+ user-select: none;
190
+ touch-action: none;
191
+ border: none;
192
+ background: transparent;
193
+ padding: 0;
194
+
195
+ &[data-dragging] { cursor: grabbing; }
196
+
197
+ // Bottom / top → full-width horizontal bar
198
+ &[data-direction="bottom"],
199
+ &[data-direction="top"] {
200
+ width: 100%;
201
+ height: 2.25rem;
202
+
203
+ .rad-ui-drawer-handle-grip {
204
+ width: 2.75rem;
205
+ height: 0.3rem;
206
+ margin: auto;
207
+ }
208
+ }
209
+
210
+ // Right / left → full-height vertical bar on the open edge
211
+ &[data-direction="right"],
212
+ &[data-direction="left"] {
213
+ width: 2.25rem;
214
+ height: 100%;
215
+
216
+ .rad-ui-drawer-handle-grip {
217
+ width: 0.3rem;
218
+ height: 2.75rem;
219
+ margin: auto;
220
+ }
221
+ }
222
+
223
+ &:focus-visible {
224
+ outline: none;
225
+
226
+ .rad-ui-drawer-handle-grip {
227
+ box-shadow: 0 0 0 2px var(--rad-ui-surface-panel), 0 0 0 4px var(--rad-ui-ring-strong);
228
+ }
229
+ }
230
+
231
+ &:hover .rad-ui-drawer-handle-grip {
232
+ background-color: var(--rad-ui-text-muted);
233
+ }
234
+
235
+ &[data-dragging] .rad-ui-drawer-handle-grip {
236
+ background-color: var(--rad-ui-text-secondary);
237
+ transform: scale(1.1);
238
+ }
239
+ }
240
+
241
+ .rad-ui-drawer-handle-grip {
242
+ display: block;
243
+ border-radius: 9999px;
244
+ background-color: var(--rad-ui-border-strong);
245
+ flex-shrink: 0;
246
+ transition:
247
+ background-color var(--rad-ui-motion-duration-fast) ease,
248
+ transform var(--rad-ui-motion-duration-normal) ease;
249
+ }
250
+
251
+ // Inner content wrapper — fills remaining space in a column
252
+ .rad-ui-drawer-content-inner {
253
+ display: flex;
254
+ flex-direction: column;
255
+ flex: 1;
256
+ min-height: 0;
257
+ overflow: auto;
258
+ position: relative; // for absolute-positioned close button
259
+ }
260
+
261
+ // ── Inner elements ────────────────────────────────────────────────────────
262
+
263
+ .rad-ui-drawer-title {
264
+ font-size: var(--rad-ui-font-size-3);
265
+ font-weight: 500;
266
+ line-height: 1.15;
267
+ margin: 0 0 0.5rem;
268
+ color: var(--rad-ui-text-primary);
269
+ letter-spacing: -0.05em;
270
+ padding: 1.25rem 1.25rem 0;
271
+ }
272
+
273
+ .rad-ui-drawer-description {
274
+ font-size: 0.8125rem;
275
+ font-weight: 400;
276
+ line-height: 1.45;
277
+ margin: 0 0 0.875rem;
278
+ color: var(--rad-ui-text-secondary);
279
+ letter-spacing: -0.025em;
280
+ padding: 0 1.25rem;
281
+ }
282
+
283
+ // Close renders as a ghost control so text children ("Close") get real
284
+ // padding and icon-only children stay square. Its label edge aligns with the
285
+ // title's inline padding instead of hugging the viewport edge.
286
+ .rad-ui-drawer-close {
287
+ position: absolute;
288
+ right: calc(var(--rad-ui-spacing-5) - var(--rad-ui-control-padding-x-sm));
289
+ top: var(--rad-ui-spacing-3);
290
+ box-sizing: border-box;
291
+ display: inline-flex;
292
+ align-items: center;
293
+ justify-content: center;
294
+ gap: var(--rad-ui-density-gap-sm);
295
+ min-width: var(--rad-ui-control-height-sm);
296
+ min-height: var(--rad-ui-control-height-sm);
297
+ padding: 0 var(--rad-ui-control-padding-x-sm);
298
+ border: var(--rad-ui-border-width-default) solid transparent;
299
+ border-radius: var(--rad-ui-control-radius-md);
300
+ background-color: transparent;
301
+ color: var(--rad-ui-text-secondary);
302
+ font-family: inherit;
303
+ font-size: var(--rad-ui-component-font-size-sm);
304
+ font-weight: var(--rad-ui-component-font-weight-medium);
305
+ line-height: var(--rad-ui-component-line-height-tight);
306
+ white-space: nowrap;
307
+ cursor: pointer;
308
+ transition:
309
+ background-color var(--rad-ui-motion-duration-fast) ease,
310
+ border-color var(--rad-ui-motion-duration-fast) ease,
311
+ color var(--rad-ui-motion-duration-fast) ease;
312
+
313
+ svg {
314
+ width: var(--rad-ui-icon-size-sm);
315
+ height: var(--rad-ui-icon-size-sm);
316
+ flex-shrink: 0;
317
+ }
318
+
319
+ &:hover {
320
+ color: var(--rad-ui-text-primary);
321
+ background-color: var(--rad-ui-surface-hover);
322
+ }
323
+
324
+ &:focus-visible {
325
+ outline: none;
326
+ box-shadow: var(--rad-ui-focus-ring-shadow);
327
+ }
328
+
329
+ &:disabled { pointer-events: none; opacity: 0.5; }
330
+ }
331
+ }