@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
package/dist/index.js ADDED
@@ -0,0 +1,69 @@
1
+ 'use client';
2
+
3
+ export { default as Accordion } from './components/Accordion.js';
4
+ export { default as Avatar } from './components/Avatar.js';
5
+ export { default as AvatarGroup } from './components/AvatarGroup.js';
6
+ export { default as AlertDialog } from './components/AlertDialog.js';
7
+ export { default as AspectRatio } from './components/AspectRatio.js';
8
+ export { default as Badge } from './components/Badge.js';
9
+ export { default as Button } from './components/Button.js';
10
+ export { default as BlockQuote } from './components/BlockQuote.js';
11
+ export { default as Breadcrumb } from './components/Breadcrumb.js';
12
+ export { default as Callout } from './components/Callout.js';
13
+ export { default as Card } from './components/Card.js';
14
+ export { default as Code } from './components/Code.js';
15
+ export { default as Dialog } from './components/Dialog.js';
16
+ export { default as Em } from './components/Em.js';
17
+ export { default as Heading } from './components/Heading.js';
18
+ export { default as Text } from './components/Text.js';
19
+ export { default as Kbd } from './components/Kbd.js';
20
+ export { default as Label } from './components/Label.js';
21
+ export { default as LiveRegion } from './components/LiveRegion.js';
22
+ export { default as Progress } from './components/Progress.js';
23
+ export { default as Separator } from './components/Separator.js';
24
+ export { default as Strong } from './components/Strong.js';
25
+ export { default as Switch } from './components/Switch.js';
26
+ export { default as Table } from './components/Table.js';
27
+ export { default as Tabs } from './components/Tabs.js';
28
+ export { default as Toggle } from './components/Toggle.js';
29
+ export { default as ToggleGroup } from './components/ToggleGroup.js';
30
+ export { default as Toolbar } from './components/Toolbar.js';
31
+ export { default as Tooltip } from './components/Tooltip.js';
32
+ export { default as VisuallyHidden } from './components/VisuallyHidden.js';
33
+ export { default as ScrollArea } from './components/ScrollArea.js';
34
+ export { default as Popover } from './components/Popover.js';
35
+ export { default as Theme } from './components/Theme.js';
36
+ export { default as Link } from './components/Link.js';
37
+ export { default as Checkbox } from './components/Checkbox.js';
38
+ export { default as CheckboxCards } from './components/CheckboxCards.js';
39
+ export { default as CheckboxGroup } from './components/CheckboxGroup.js';
40
+ export { default as Collapsible } from './components/Collapsible.js';
41
+ export { default as Combobox } from './components/Combobox.js';
42
+ export { default as Command } from './components/Command.js';
43
+ export { default as ContextMenu } from './components/ContextMenu.js';
44
+ export { default as DataList } from './components/DataList.js';
45
+ export { default as Drawer } from './components/Drawer.js';
46
+ export { default as Disclosure } from './components/Disclosure.js';
47
+ export { default as DropdownMenu } from './components/DropdownMenu.js';
48
+ export { default as Fieldset } from './components/Fieldset.js';
49
+ export { default as HoverCard } from './components/HoverCard.js';
50
+ export { default as Menubar } from './components/Menubar.js';
51
+ export { default as Meter } from './components/Meter.js';
52
+ export { default as Minimap } from './components/Minimap.js';
53
+ export { default as NavigationMenu } from './components/NavigationMenu.js';
54
+ export { default as NumberField } from './components/NumberField.js';
55
+ export { default as Quote } from './components/Quote.js';
56
+ export { default as Radio } from './components/Radio.js';
57
+ export { default as RadioCards } from './components/RadioCards.js';
58
+ export { default as RadioGroup } from './components/RadioGroup.js';
59
+ export { default as Select } from './components/Select.js';
60
+ export { default as Skeleton } from './components/Skeleton.js';
61
+ export { default as Slider } from './components/Slider.js';
62
+ export { default as Spinner } from './components/Spinner.js';
63
+ export { default as Splitter } from './components/Splitter.js';
64
+ export { default as Steps } from './components/Steps.js';
65
+ export { default as TabNav } from './components/TabNav.js';
66
+ export { default as TextArea } from './components/TextArea.js';
67
+ export { default as TextField } from './components/TextField.js';
68
+ export { default as Toast } from './components/Toast.js';
69
+ export { default as Tree } from './components/Tree.js';
@@ -0,0 +1,147 @@
1
+ .rad-ui-accordion-root {
2
+ width: 100%;
3
+
4
+ .rad-ui-accordion-item {
5
+ border-bottom: 1px solid var(--rad-ui-border-soft);
6
+
7
+ &[data-disabled] {
8
+ opacity: 0.5;
9
+ pointer-events: none;
10
+ }
11
+
12
+ .rad-ui-accordion-header {
13
+ display: flex;
14
+ margin: 0;
15
+ }
16
+
17
+ .rad-ui-accordion-trigger {
18
+ flex: 1;
19
+ display: flex;
20
+ align-items: center;
21
+ justify-content: space-between;
22
+ gap: var(--rad-ui-spacing-4);
23
+ padding: 1rem 4px;
24
+ font-size: var(--rad-ui-component-font-size-comfortable);
25
+ font-weight: 600;
26
+ line-height: 1.4;
27
+ background-color: transparent;
28
+ color: var(--rad-ui-text-primary);
29
+ border: none;
30
+ cursor: pointer;
31
+ text-align: left;
32
+ width: 100%;
33
+
34
+ &:focus-visible {
35
+ outline: none;
36
+ box-shadow: var(--rad-ui-focus-ring-shadow-offset);
37
+ border-radius: var(--rad-ui-radius-sm);
38
+ }
39
+
40
+ &[aria-disabled="true"] {
41
+ pointer-events: none;
42
+ opacity: 0.5;
43
+ }
44
+
45
+ // Chevron icon
46
+ svg,
47
+ .rad-ui-accordion-chevron {
48
+ height: 1.125rem;
49
+ width: 1.125rem;
50
+ flex-shrink: 0;
51
+ color: var(--rad-ui-text-secondary);
52
+ transition: transform var(--rad-ui-motion-duration-normal) ease;
53
+ }
54
+ }
55
+
56
+ &[data-state="open"] {
57
+ .rad-ui-accordion-trigger {
58
+ svg,
59
+ .rad-ui-accordion-chevron {
60
+ transform: rotate(180deg);
61
+ }
62
+ }
63
+ }
64
+
65
+ .rad-ui-accordion-content {
66
+ overflow: hidden;
67
+ font-size: var(--rad-ui-component-font-size-comfortable);
68
+ line-height: 1.6;
69
+ color: var(--rad-ui-text-secondary);
70
+
71
+ .rad-ui-accordion-content-inner {
72
+ padding-bottom: 1rem;
73
+
74
+ > :first-child {
75
+ margin-top: 0;
76
+ }
77
+
78
+ > :last-child {
79
+ margin-bottom: 0;
80
+ }
81
+ }
82
+ }
83
+
84
+ /* Opt-in expand/collapse animation.
85
+ *
86
+ * The default panel animates via the inline `height` the Collapsible
87
+ * primitive sets, which works but is limited to a height tween. This
88
+ * variant uses the `grid-template-rows: 0fr -> 1fr` technique instead,
89
+ * which also fades and slides the panel in.
90
+ *
91
+ * `height: auto !important` is required, not stylistic: it overrides the
92
+ * inline height the primitive writes during its own tween. Without it the
93
+ * two animations fight and the panel snaps. Because the inline height is
94
+ * discarded, callers using this variant should pass `forceMount` so the
95
+ * panel stays mounted and the collapse can finish.
96
+ *
97
+ * The bottom spacing moves from the panel's `padding-bottom` onto its
98
+ * last child as a `margin-bottom`. Padding on the grid item does not
99
+ * collapse with a `0fr` track: the padding box still occupies 1rem, so
100
+ * the closed panel reserved a 1rem gap under the trigger. A margin on
101
+ * the child is outside the collapsed track and collapses with it. The
102
+ * base rule zeroes the last child's margin, so this has to override it;
103
+ * both selectors compile to (0,5,0) and this one is later in the file.
104
+ *
105
+ * Removed in 798f9c8f along with the `WithAnimation` story and left
106
+ * unreplaced; restored here so the story and the docs example share one
107
+ * definition. */
108
+ .rad-ui-accordion-content-animated {
109
+ height: auto !important;
110
+ display: grid;
111
+ grid-template-rows: 0fr;
112
+ transition: grid-template-rows var(--rad-ui-motion-duration-normal) ease;
113
+
114
+ .rad-ui-accordion-content-inner {
115
+ min-height: 0;
116
+ padding-bottom: 0;
117
+ transform-origin: top;
118
+ opacity: 0;
119
+ transform: translateY(-8px) scaleY(0.96);
120
+ transition: opacity var(--rad-ui-motion-duration-normal) ease, transform var(--rad-ui-motion-duration-normal) ease;
121
+
122
+ > *:last-child {
123
+ margin-bottom: 1rem;
124
+ }
125
+ }
126
+
127
+ &[data-state="open"] {
128
+ grid-template-rows: 1fr;
129
+
130
+ .rad-ui-accordion-content-inner {
131
+ opacity: 1;
132
+ transform: translateY(0) scaleY(1);
133
+ }
134
+ }
135
+
136
+ @media (prefers-reduced-motion: reduce) {
137
+ transition: none;
138
+
139
+ .rad-ui-accordion-content-inner {
140
+ opacity: 1;
141
+ transform: none;
142
+ transition: none;
143
+ }
144
+ }
145
+ }
146
+ }
147
+ }
@@ -0,0 +1,199 @@
1
+ @use '../Button/button.clarity';
2
+
3
+ %rad-ui-alert-dialog-action-skin {
4
+ @extend .rad-ui-button-root;
5
+
6
+ min-height: var(--rad-ui-control-height-md);
7
+ padding-inline: calc(var(--rad-ui-control-padding-x-md) + var(--rad-ui-density-gap-xs));
8
+ border-radius: var(--rad-ui-control-radius-lg);
9
+ font-size: calc(var(--rad-ui-font-size-2) - (var(--rad-ui-spacing-1) / 4));
10
+ font-weight: var(--rad-ui-component-font-weight-medium);
11
+ letter-spacing: -0.03em;
12
+ background-color: var(--rad-ui-surface-inverse);
13
+ color: var(--rad-ui-text-inverse);
14
+ border: var(--rad-ui-border-width-default) solid var(--rad-ui-surface-inverse);
15
+ box-shadow: var(--rad-ui-control-shadow);
16
+
17
+ &:hover {
18
+ background-color: var(--rad-ui-text-primary);
19
+ border-color: var(--rad-ui-text-primary);
20
+ }
21
+ }
22
+
23
+ %rad-ui-alert-dialog-cancel-skin {
24
+ @extend .rad-ui-button-root;
25
+
26
+ min-height: var(--rad-ui-control-height-md);
27
+ padding-inline: calc(var(--rad-ui-control-padding-x-md) + var(--rad-ui-density-gap-xs));
28
+ border-radius: var(--rad-ui-control-radius-lg);
29
+ font-size: calc(var(--rad-ui-font-size-2) - (var(--rad-ui-spacing-1) / 4));
30
+ font-weight: var(--rad-ui-component-font-weight-medium);
31
+ letter-spacing: -0.03em;
32
+ background-color: var(--rad-ui-surface-panel);
33
+ color: var(--rad-ui-text-primary);
34
+ border: var(--rad-ui-border-width-default) solid var(--rad-ui-border-soft);
35
+ box-shadow: var(--rad-ui-control-shadow);
36
+
37
+ &:hover {
38
+ background-color: var(--rad-ui-surface-subtle);
39
+ border-color: var(--rad-ui-border-default);
40
+ color: var(--rad-ui-text-primary);
41
+ }
42
+ }
43
+
44
+ .rad-ui-alert-dialog-overlay {
45
+ position: fixed;
46
+ inset: 0;
47
+ z-index: var(--rad-ui-z-index-overlay);
48
+ background-color: var(--rad-ui-overlay-scrim);
49
+ backdrop-filter: blur(var(--rad-ui-blur-lg));
50
+ overflow: hidden;
51
+ transition:
52
+ opacity var(--rad-ui-motion-duration-normal) var(--rad-ui-motion-easing-standard),
53
+ visibility var(--rad-ui-motion-duration-normal) var(--rad-ui-motion-easing-standard);
54
+
55
+ &[data-state="open"] {
56
+ opacity: 1;
57
+ visibility: visible;
58
+ }
59
+
60
+ &[data-state="closed"] {
61
+ opacity: 0;
62
+ visibility: hidden;
63
+ }
64
+ }
65
+
66
+ .rad-ui-alert-dialog-trigger {
67
+ @extend .rad-ui-button-root;
68
+
69
+ cursor: pointer;
70
+ }
71
+
72
+ .rad-ui-alert-dialog-content {
73
+ --rad-ui-alert-dialog-body-font-size: calc(var(--rad-ui-font-size-2) - (var(--rad-ui-spacing-1) / 4));
74
+ --rad-ui-alert-dialog-title-font-size-mobile: calc(var(--rad-ui-font-size-3) - (var(--rad-ui-spacing-1) / 4));
75
+ --rad-ui-alert-dialog-inline-padding: var(--rad-ui-spacing-4);
76
+ --rad-ui-alert-dialog-inline-padding-mobile: calc(var(--rad-ui-spacing-3) + var(--rad-ui-density-gap-xs));
77
+
78
+ position: fixed;
79
+ left: 50%;
80
+ top: 50%;
81
+ z-index: var(--rad-ui-z-index-portal);
82
+ width: 100%;
83
+ max-width: var(--rad-ui-overlay-width-lg);
84
+ transform: translate(-50%, -50%);
85
+ padding: var(--rad-ui-spacing-4) var(--rad-ui-alert-dialog-inline-padding) 0;
86
+ border-radius: var(--rad-ui-panel-radius-lg);
87
+ background-color: var(--rad-ui-surface-panel);
88
+ color: var(--rad-ui-text-primary);
89
+ border: var(--rad-ui-border-width-default) solid var(--rad-ui-border-default);
90
+ box-shadow: var(--rad-ui-elevation-lg-shadow);
91
+ display: flex;
92
+ flex-direction: column;
93
+ gap: 0;
94
+ overflow: hidden;
95
+ transition:
96
+ opacity var(--rad-ui-motion-duration-normal) var(--rad-ui-motion-easing-standard),
97
+ visibility var(--rad-ui-motion-duration-normal) var(--rad-ui-motion-easing-standard),
98
+ transform var(--rad-ui-motion-duration-normal) var(--rad-ui-motion-easing-standard);
99
+
100
+ &[data-state="open"] {
101
+ opacity: 1;
102
+ visibility: visible;
103
+ transform: translate(-50%, -50%) scale(1);
104
+ }
105
+
106
+ &[data-state="closed"] {
107
+ opacity: 0;
108
+ visibility: hidden;
109
+ transform: translate(-50%, -50%) scale(0.95);
110
+ }
111
+
112
+ &:focus {
113
+ outline: none;
114
+ }
115
+
116
+ // Nested child components
117
+ .rad-ui-alert-dialog-title {
118
+ font-size: var(--rad-ui-font-size-3);
119
+ font-weight: var(--rad-ui-component-font-weight-medium);
120
+ line-height: calc(var(--rad-ui-component-line-height-tight) + 0.15);
121
+ margin: 0;
122
+ margin-bottom: var(--rad-ui-spacing-2);
123
+ color: var(--rad-ui-text-primary);
124
+ letter-spacing: -0.05em;
125
+ }
126
+
127
+ .rad-ui-alert-dialog-description {
128
+ max-width: calc(var(--rad-ui-overlay-width-lg) - var(--rad-ui-spacing-12) - var(--rad-ui-size-4));
129
+ font-size: var(--rad-ui-alert-dialog-body-font-size);
130
+ font-weight: var(--rad-ui-component-font-weight-regular);
131
+ line-height: calc(var(--rad-ui-component-line-height-normal) + 0.2);
132
+ margin: 0;
133
+ margin-bottom: calc(var(--rad-ui-spacing-3) + var(--rad-ui-density-gap-xs));
134
+ color: var(--rad-ui-text-muted);
135
+ letter-spacing: -0.025em;
136
+ }
137
+
138
+ .rad-ui-alert-dialog-footer {
139
+ display: flex;
140
+ flex-direction: column-reverse;
141
+ gap: var(--rad-ui-spacing-2);
142
+ margin: 0 calc(var(--rad-ui-alert-dialog-inline-padding) * -1);
143
+ padding: calc(var(--rad-ui-spacing-3) + var(--rad-ui-density-gap-xs)) var(--rad-ui-alert-dialog-inline-padding) var(--rad-ui-spacing-4);
144
+ border-top: var(--rad-ui-border-width-default) solid var(--rad-ui-border-soft);
145
+ background-color: var(--rad-ui-surface-subtle);
146
+ border-bottom-left-radius: inherit;
147
+ border-bottom-right-radius: inherit;
148
+
149
+ @media (width > 640px) {
150
+ flex-direction: row;
151
+ justify-content: flex-end;
152
+ align-items: center;
153
+ }
154
+
155
+ .rad-ui-alert-dialog-action {
156
+ @extend %rad-ui-alert-dialog-action-skin;
157
+ }
158
+
159
+ .rad-ui-alert-dialog-cancel {
160
+ @extend %rad-ui-alert-dialog-cancel-skin;
161
+ }
162
+ }
163
+
164
+ @media (width <= 640px) {
165
+ max-width: calc(100% - 2rem);
166
+ margin: var(--rad-ui-spacing-4);
167
+ padding: calc(var(--rad-ui-spacing-3) + var(--rad-ui-density-gap-xs)) var(--rad-ui-alert-dialog-inline-padding-mobile) 0;
168
+ border-radius: calc(var(--rad-ui-panel-radius-md) + var(--rad-ui-density-gap-xs));
169
+
170
+ .rad-ui-alert-dialog-title {
171
+ font-size: var(--rad-ui-alert-dialog-title-font-size-mobile);
172
+ margin-bottom: var(--rad-ui-spacing-2);
173
+ }
174
+
175
+ .rad-ui-alert-dialog-description {
176
+ font-size: var(--rad-ui-alert-dialog-body-font-size);
177
+ margin-bottom: calc(var(--rad-ui-spacing-3) + var(--rad-ui-density-gap-xs));
178
+ }
179
+
180
+ .rad-ui-alert-dialog-footer {
181
+ margin: 0 calc(var(--rad-ui-alert-dialog-inline-padding-mobile) * -1);
182
+ padding: var(--rad-ui-spacing-3) var(--rad-ui-alert-dialog-inline-padding-mobile) var(--rad-ui-alert-dialog-inline-padding-mobile);
183
+ }
184
+
185
+ .rad-ui-alert-dialog-action,
186
+ .rad-ui-alert-dialog-cancel {
187
+ width: 100%;
188
+ }
189
+ }
190
+ }
191
+
192
+ // Standalone button styles (for when used outside of content context)
193
+ .rad-ui-alert-dialog-action {
194
+ @extend %rad-ui-alert-dialog-action-skin;
195
+ }
196
+
197
+ .rad-ui-alert-dialog-cancel {
198
+ @extend %rad-ui-alert-dialog-cancel-skin;
199
+ }
@@ -0,0 +1,87 @@
1
+ // Base avatar styles - shared between avatar and avatar-group components
2
+ .rad-ui-avatar {
3
+ position: relative;
4
+ display: flex;
5
+ height: var(--rad-ui-size-10); // h-10
6
+ width: var(--rad-ui-size-10); // w-10
7
+ flex-shrink: 0;
8
+ overflow: hidden;
9
+ border-radius: var(--rad-ui-radius-full); // rounded-full
10
+
11
+ .rad-ui-avatar-image {
12
+ aspect-ratio: 1 / 1;
13
+ height: 100%;
14
+ width: 100%;
15
+ object-fit: cover;
16
+ border-radius: inherit;
17
+
18
+ // Keep a loading/undecoded image out of the layout so the fallback is the only
19
+ // visible content until the image is ready (it still loads while hidden).
20
+ &[data-state="loading"] {
21
+ position: absolute;
22
+ inset: 0;
23
+ opacity: 0;
24
+ }
25
+ }
26
+
27
+ // Default styles (no color prop) — semantic tokens so dark theme keeps contrast vs canvas
28
+ .rad-ui-avatar-fallback {
29
+ display: flex;
30
+ align-items: center;
31
+ justify-content: center;
32
+ height: 100%;
33
+ width: 100%;
34
+ border-radius: inherit;
35
+ font-size: var(--rad-ui-font-size-2); // text-sm
36
+ line-height: var(--rad-ui-line-height-1);
37
+ font-weight: 500; // font-medium
38
+ color: var(--rad-ui-text-primary);
39
+ background-color: var(--rad-ui-surface-muted);
40
+ box-shadow: inset 0 0 0 1px var(--rad-ui-border-soft);
41
+ }
42
+
43
+ // Size variants - must come before more specific selectors
44
+ &[data-size="sm"],
45
+ &[data-size="small"] {
46
+ height: var(--rad-ui-size-8); // h-8
47
+ width: var(--rad-ui-size-8); // w-8
48
+
49
+ .rad-ui-avatar-fallback {
50
+ font-size: var(--rad-ui-font-size-1); // text-xs
51
+ }
52
+ }
53
+
54
+ &[data-size="lg"],
55
+ &[data-size="large"] {
56
+ height: var(--rad-ui-size-12); // h-12
57
+ width: var(--rad-ui-size-12); // w-12
58
+
59
+ .rad-ui-avatar-fallback {
60
+ font-size: var(--rad-ui-font-size-3); // text-base
61
+ }
62
+ }
63
+
64
+ &[data-rad-ui-has-image] {
65
+ .rad-ui-avatar-fallback {
66
+ color: var(--rad-ui-text-primary);
67
+ background-color: var(--rad-ui-surface-muted);
68
+ box-shadow: inset 0 0 0 1px var(--rad-ui-border-soft);
69
+ }
70
+ }
71
+
72
+ // Solid accent fallback: light initials on the 950 step (as Button/Badge solid).
73
+ // The 800 step cannot carry light or dark text at WCAG AA for most scales
74
+ // (gray 3.2:1 light / 3.6:1 dark, sky 1.5:1), so it is not used for text surfaces.
75
+ &[data-color]:not([data-rad-ui-has-image]) {
76
+ .rad-ui-avatar-fallback {
77
+ color: var(--rad-ui-color-accent-50);
78
+ background-color: var(--rad-ui-color-accent-950);
79
+ box-shadow: var(--rad-ui-shadow-none);
80
+ }
81
+ }
82
+
83
+ // Square variant
84
+ &[data-variant="square"] {
85
+ border-radius: var(--rad-ui-radius-sm); // rounded-md
86
+ }
87
+ }
@@ -0,0 +1 @@
1
+ @use "avatar-base.clarity";
@@ -0,0 +1,122 @@
1
+ /* stylelint-disable no-descending-specificity */
2
+ // Base avatar styles (least specific) - must come first
3
+ @use "../Avatar/avatar-base.clarity";
4
+
5
+ // Avatar group styles (more specific due to nesting)
6
+ // Note: This file has nested selectors that create specificity conflicts
7
+ // The structure is functionally correct, but stylelint can't handle the nesting properly
8
+ .rad-ui-avatar-group {
9
+ --rad-ui-avatar-group-overlap: calc(var(--rad-ui-spacing-1) + var(--rad-ui-density-gap-xs));
10
+
11
+ display: flex;
12
+ flex-direction: row;
13
+ align-items: center;
14
+
15
+ .rad-ui-avatar-group-item {
16
+ position: relative;
17
+ display: flex;
18
+ height: var(--rad-ui-size-10); // h-10
19
+ width: var(--rad-ui-size-10); // w-10
20
+ flex-shrink: 0;
21
+ overflow: hidden;
22
+ border-radius: var(--rad-ui-radius-full); // rounded-full
23
+ background-color: var(--rad-ui-surface-panel);
24
+ box-shadow: 0 0 0 var(--rad-ui-border-width-2) var(--rad-ui-surface-panel);
25
+
26
+ // Overlapping avatars with negative margin
27
+ &:not(:first-child) {
28
+ margin-left: calc(var(--rad-ui-avatar-group-overlap) * -1);
29
+ z-index: 1;
30
+ }
31
+
32
+ &:first-child {
33
+ margin-left: 0;
34
+ }
35
+
36
+ // Nested avatar components - more specific than standalone .rad-ui-avatar
37
+ .rad-ui-avatar {
38
+ height: 100%;
39
+ width: 100%;
40
+ border-radius: inherit;
41
+ }
42
+
43
+ .rad-ui-avatar-image,
44
+ .rad-ui-avatar-group-avatar {
45
+ width: 100%;
46
+ height: 100%;
47
+ object-fit: cover;
48
+ border-radius: inherit;
49
+
50
+ // Hidden (but still loading) until decoded, so the fallback is the only
51
+ // visible content while the image is pending.
52
+ &[data-state="loading"] {
53
+ position: absolute;
54
+ inset: 0;
55
+ opacity: 0;
56
+ }
57
+ }
58
+
59
+ // Default styles (no color prop) - muted appearance
60
+ .rad-ui-avatar-fallback,
61
+ .rad-ui-avatar-group-fallback {
62
+ display: flex;
63
+ align-items: center;
64
+ justify-content: center;
65
+ height: 100%;
66
+ width: 100%;
67
+ border-radius: inherit;
68
+ font-size: var(--rad-ui-font-size-2); // text-sm
69
+ line-height: var(--rad-ui-line-height-1);
70
+ font-weight: 600; // font-semibold
71
+ color: var(--rad-ui-text-primary);
72
+ background-color: var(--rad-ui-surface-muted);
73
+ }
74
+
75
+ // Item `color` prop: solid accent fallback (same recipe as Avatar).
76
+ &[data-color]:not([data-rad-ui-has-image]) {
77
+ .rad-ui-avatar-fallback,
78
+ .rad-ui-avatar-group-fallback {
79
+ color: var(--rad-ui-color-accent-50);
80
+ background-color: var(--rad-ui-color-accent-950);
81
+ }
82
+ }
83
+ }
84
+
85
+ // Size variants — mirror Avatar sizes (accepts both short and library-standard names)
86
+ &[data-size="sm"] .rad-ui-avatar-group-item,
87
+ &[data-size="small"] .rad-ui-avatar-group-item {
88
+ height: var(--rad-ui-size-8);
89
+ width: var(--rad-ui-size-8);
90
+
91
+ .rad-ui-avatar-fallback,
92
+ .rad-ui-avatar-group-fallback {
93
+ font-size: var(--rad-ui-font-size-1);
94
+ }
95
+ }
96
+
97
+ &[data-size="lg"] .rad-ui-avatar-group-item,
98
+ &[data-size="large"] .rad-ui-avatar-group-item {
99
+ height: var(--rad-ui-size-12);
100
+ width: var(--rad-ui-size-12);
101
+
102
+ .rad-ui-avatar-fallback,
103
+ .rad-ui-avatar-group-fallback {
104
+ font-size: var(--rad-ui-font-size-3);
105
+ }
106
+ }
107
+
108
+ &[data-variant="square"] .rad-ui-avatar-group-item {
109
+ border-radius: var(--rad-ui-radius-sm);
110
+ }
111
+
112
+ // Spacing variant (no overlap) - more specific
113
+ &[data-variant="spacing"] {
114
+ gap: var(--rad-ui-spacing-2);
115
+
116
+ .rad-ui-avatar-group-item {
117
+ margin-left: 0;
118
+ }
119
+ }
120
+
121
+ }
122
+ /* stylelint-enable no-descending-specificity */