@crisp-ui-kit/crisp 0.5.0 → 0.7.1

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 (472) hide show
  1. package/README.md +14 -0
  2. package/dist/accordion.css +9 -1
  3. package/dist/appshell.css +12 -4
  4. package/dist/authshell.css +57 -0
  5. package/dist/authshell.d.ts +7 -0
  6. package/dist/avatargroup.css +2 -2
  7. package/dist/badge.css +4 -4
  8. package/dist/barchart.css +13 -5
  9. package/dist/board.css +9 -1
  10. package/dist/bulkbar.css +11 -3
  11. package/dist/button.css +15 -1
  12. package/dist/button.d.ts +2 -1
  13. package/dist/card.css +8 -0
  14. package/dist/checkbox.css +17 -1
  15. package/dist/cjs/components/accordion/accordion.js +69 -0
  16. package/dist/cjs/components/accordion/accordion.recipe.js +26 -0
  17. package/dist/cjs/components/accordion/index.js +7 -0
  18. package/dist/cjs/components/avatar/avatar.js +44 -0
  19. package/dist/cjs/components/avatar/avatar.recipe.js +42 -0
  20. package/dist/cjs/components/avatar/index.js +7 -0
  21. package/dist/cjs/components/avatargroup/avatargroup.js +52 -0
  22. package/dist/cjs/components/avatargroup/avatargroup.recipe.js +18 -0
  23. package/dist/cjs/components/avatargroup/index.js +7 -0
  24. package/dist/cjs/components/badge/badge.js +44 -0
  25. package/dist/cjs/components/badge/badge.recipe.js +68 -0
  26. package/dist/cjs/components/badge/index.js +7 -0
  27. package/dist/cjs/components/barchart/barchart.js +45 -0
  28. package/dist/cjs/components/barchart/barchart.recipe.js +34 -0
  29. package/dist/cjs/components/barchart/index.js +7 -0
  30. package/dist/cjs/components/breadcrumb/breadcrumb.js +53 -0
  31. package/dist/cjs/components/breadcrumb/breadcrumb.recipe.js +21 -0
  32. package/dist/cjs/components/breadcrumb/index.js +7 -0
  33. package/dist/cjs/components/bulkbar/bulkbar.js +53 -0
  34. package/dist/cjs/components/bulkbar/bulkbar.recipe.js +31 -0
  35. package/dist/cjs/components/bulkbar/index.js +8 -0
  36. package/dist/cjs/components/button/button.js +62 -0
  37. package/dist/cjs/components/button/button.recipe.js +58 -0
  38. package/dist/cjs/components/button/index.js +7 -0
  39. package/dist/cjs/components/callout/callout.js +25 -0
  40. package/dist/cjs/components/callout/callout.recipe.js +29 -0
  41. package/dist/cjs/components/callout/index.js +7 -0
  42. package/dist/cjs/components/card/card.js +54 -0
  43. package/dist/cjs/components/card/card.recipe.js +31 -0
  44. package/dist/cjs/components/card/index.js +10 -0
  45. package/dist/cjs/components/checkbox/checkbox.js +56 -0
  46. package/dist/cjs/components/checkbox/checkbox.recipe.js +34 -0
  47. package/dist/cjs/components/checkbox/index.js +7 -0
  48. package/dist/cjs/components/columncalc/columncalc.js +139 -0
  49. package/dist/cjs/components/columncalc/columncalc.recipe.js +33 -0
  50. package/dist/cjs/components/columncalc/index.js +10 -0
  51. package/dist/cjs/components/contextmenu/contextmenu.js +78 -0
  52. package/dist/cjs/components/contextmenu/contextmenu.recipe.js +24 -0
  53. package/dist/cjs/components/contextmenu/index.js +7 -0
  54. package/dist/cjs/components/datatable/datatable.js +508 -0
  55. package/dist/cjs/components/datatable/datatable.recipe.js +113 -0
  56. package/dist/cjs/components/datatable/index.js +7 -0
  57. package/dist/cjs/components/datepicker/datepicker.js +153 -0
  58. package/dist/cjs/components/datepicker/datepicker.recipe.js +190 -0
  59. package/dist/cjs/components/datepicker/index.js +19 -0
  60. package/dist/cjs/components/datepickerfield/datepickerfield.js +85 -0
  61. package/dist/cjs/components/datepickerfield/datepickerfield.recipe.js +44 -0
  62. package/dist/cjs/components/datepickerfield/index.js +7 -0
  63. package/dist/cjs/components/dialog/dialog.js +86 -0
  64. package/dist/cjs/components/dialog/dialog.recipe.js +35 -0
  65. package/dist/cjs/components/dialog/index.js +9 -0
  66. package/dist/cjs/components/divider/divider.js +10 -0
  67. package/dist/cjs/components/divider/divider.recipe.js +17 -0
  68. package/dist/cjs/components/divider/index.js +7 -0
  69. package/dist/cjs/components/donutchart/donutchart.js +41 -0
  70. package/dist/cjs/components/donutchart/donutchart.recipe.js +30 -0
  71. package/dist/cjs/components/donutchart/index.js +7 -0
  72. package/dist/cjs/components/drawer/drawer.js +80 -0
  73. package/dist/cjs/components/drawer/drawer.recipe.js +30 -0
  74. package/dist/cjs/components/drawer/index.js +9 -0
  75. package/dist/cjs/components/emptystate/emptystate.js +10 -0
  76. package/dist/cjs/components/emptystate/emptystate.recipe.js +34 -0
  77. package/dist/cjs/components/emptystate/index.js +7 -0
  78. package/dist/cjs/components/formfield/formfield.js +50 -0
  79. package/dist/cjs/components/formfield/formfield.recipe.js +22 -0
  80. package/dist/cjs/components/formfield/index.js +7 -0
  81. package/dist/cjs/components/input/index.js +7 -0
  82. package/dist/cjs/components/input/input.js +47 -0
  83. package/dist/cjs/components/input/input.recipe.js +59 -0
  84. package/dist/cjs/components/kbd/index.js +7 -0
  85. package/dist/cjs/components/kbd/kbd.js +44 -0
  86. package/dist/cjs/components/kbd/kbd.recipe.js +23 -0
  87. package/dist/cjs/components/linechart/index.js +7 -0
  88. package/dist/cjs/components/linechart/linechart.js +57 -0
  89. package/dist/cjs/components/linechart/linechart.recipe.js +35 -0
  90. package/dist/cjs/components/menu/index.js +14 -0
  91. package/dist/cjs/components/menu/menu-keyboard.js +117 -0
  92. package/dist/cjs/components/menu/menu.js +144 -0
  93. package/dist/cjs/components/menu/menu.recipe.js +54 -0
  94. package/dist/cjs/components/multiselect/index.js +7 -0
  95. package/dist/cjs/components/multiselect/multiselect.js +161 -0
  96. package/dist/cjs/components/multiselect/multiselect.recipe.js +71 -0
  97. package/dist/cjs/components/popover/index.js +7 -0
  98. package/dist/cjs/components/popover/popover.js +106 -0
  99. package/dist/cjs/components/popover/popover.recipe.js +21 -0
  100. package/dist/cjs/components/progress/index.js +7 -0
  101. package/dist/cjs/components/progress/progress.js +26 -0
  102. package/dist/cjs/components/progress/progress.recipe.js +20 -0
  103. package/dist/cjs/components/radiogroup/index.js +8 -0
  104. package/dist/cjs/components/radiogroup/radiogroup.js +83 -0
  105. package/dist/cjs/components/radiogroup/radiogroup.recipe.js +40 -0
  106. package/dist/cjs/components/resizablepanel/index.js +12 -0
  107. package/dist/cjs/components/resizablepanel/resizablepanel.js +176 -0
  108. package/dist/cjs/components/resizablepanel/resizablepanel.recipe.js +69 -0
  109. package/dist/cjs/components/segmented/index.js +7 -0
  110. package/dist/cjs/components/segmented/segmented.js +95 -0
  111. package/dist/cjs/components/segmented/segmented.recipe.js +23 -0
  112. package/dist/cjs/components/select/index.js +7 -0
  113. package/dist/cjs/components/select/select.js +180 -0
  114. package/dist/cjs/components/select/select.recipe.js +79 -0
  115. package/dist/cjs/components/skeleton/index.js +7 -0
  116. package/dist/cjs/components/skeleton/skeleton.js +13 -0
  117. package/dist/cjs/components/skeleton/skeleton.recipe.js +17 -0
  118. package/dist/cjs/components/spinner/index.js +7 -0
  119. package/dist/cjs/components/spinner/spinner.js +15 -0
  120. package/dist/cjs/components/spinner/spinner.recipe.js +16 -0
  121. package/dist/cjs/components/stagebar/index.js +7 -0
  122. package/dist/cjs/components/stagebar/stagebar.js +26 -0
  123. package/dist/cjs/components/stagebar/stagebar.recipe.js +17 -0
  124. package/dist/cjs/components/statcard/index.js +7 -0
  125. package/dist/cjs/components/statcard/statcard.js +15 -0
  126. package/dist/cjs/components/statcard/statcard.recipe.js +37 -0
  127. package/dist/cjs/components/switch/index.js +7 -0
  128. package/dist/cjs/components/switch/switch.js +58 -0
  129. package/dist/cjs/components/switch/switch.recipe.js +29 -0
  130. package/dist/cjs/components/table/index.js +14 -0
  131. package/dist/cjs/components/table/table.js +66 -0
  132. package/dist/cjs/components/table/table.recipe.js +43 -0
  133. package/dist/cjs/components/tabletoolbar/index.js +20 -0
  134. package/dist/cjs/components/tabletoolbar/tabletoolbar.chrome.js +84 -0
  135. package/dist/cjs/components/tabletoolbar/tabletoolbar.js +237 -0
  136. package/dist/cjs/components/tabletoolbar/tabletoolbar.recipe.js +26 -0
  137. package/dist/cjs/components/tabs/index.js +7 -0
  138. package/dist/cjs/components/tabs/tabs.js +106 -0
  139. package/dist/cjs/components/tabs/tabs.recipe.js +36 -0
  140. package/dist/cjs/components/textarea/index.js +7 -0
  141. package/dist/cjs/components/textarea/textarea.js +56 -0
  142. package/dist/cjs/components/textarea/textarea.recipe.js +46 -0
  143. package/dist/cjs/components/toast/index.js +8 -0
  144. package/dist/cjs/components/toast/toast.js +95 -0
  145. package/dist/cjs/components/toast/toast.recipe.js +31 -0
  146. package/dist/cjs/components/tooltip/index.js +7 -0
  147. package/dist/cjs/components/tooltip/tooltip.js +95 -0
  148. package/dist/cjs/components/tooltip/tooltip.recipe.js +16 -0
  149. package/dist/cjs/components/wheelpicker/index.js +7 -0
  150. package/dist/cjs/components/wheelpicker/wheelpicker.js +134 -0
  151. package/dist/cjs/components/wheelpicker/wheelpicker.recipe.js +95 -0
  152. package/dist/cjs/core/cx.js +8 -0
  153. package/dist/cjs/core/define.js +6 -0
  154. package/dist/cjs/core/index.js +11 -0
  155. package/dist/cjs/core/primitive.js +49 -0
  156. package/dist/cjs/core/resolve.js +44 -0
  157. package/dist/cjs/core/types.js +2 -0
  158. package/dist/cjs/index.js +92 -0
  159. package/dist/cjs/package.json +3 -0
  160. package/dist/cjs/product/appshell/appshell.js +104 -0
  161. package/dist/cjs/product/appshell/appshell.recipe.js +30 -0
  162. package/dist/cjs/product/appshell/index.js +7 -0
  163. package/dist/cjs/product/authshell/authshell.js +21 -0
  164. package/dist/cjs/product/authshell/authshell.recipe.js +67 -0
  165. package/dist/cjs/product/authshell/index.js +7 -0
  166. package/dist/cjs/product/board/board.js +78 -0
  167. package/dist/cjs/product/board/board.recipe.js +31 -0
  168. package/dist/cjs/product/board/index.js +7 -0
  169. package/dist/cjs/product/command/command.js +238 -0
  170. package/dist/cjs/product/command/command.recipe.js +47 -0
  171. package/dist/cjs/product/command/index.js +8 -0
  172. package/dist/cjs/product/entitycard/entitycard.js +14 -0
  173. package/dist/cjs/product/entitycard/entitycard.recipe.js +32 -0
  174. package/dist/cjs/product/entitycard/index.js +7 -0
  175. package/dist/cjs/product/flowcanvas/flowcanvas.js +121 -0
  176. package/dist/cjs/product/flowcanvas/flowcanvas.recipe.js +28 -0
  177. package/dist/cjs/product/flowcanvas/index.js +7 -0
  178. package/dist/cjs/product/inbox/inbox.js +16 -0
  179. package/dist/cjs/product/inbox/inbox.recipe.js +46 -0
  180. package/dist/cjs/product/inbox/index.js +7 -0
  181. package/dist/cjs/product/listpage/index.js +8 -0
  182. package/dist/cjs/product/listpage/listpage.js +25 -0
  183. package/dist/cjs/product/listpage/listpage.recipe.js +46 -0
  184. package/dist/cjs/product/navitem/index.js +5 -0
  185. package/dist/cjs/product/navitem/navitem.js +44 -0
  186. package/dist/cjs/product/navitem/navitem.recipe.js +36 -0
  187. package/dist/cjs/product/onboarding/index.js +7 -0
  188. package/dist/cjs/product/onboarding/onboarding.js +17 -0
  189. package/dist/cjs/product/onboarding/onboarding.recipe.js +44 -0
  190. package/dist/cjs/product/recordpage/index.js +7 -0
  191. package/dist/cjs/product/recordpage/recordpage.js +409 -0
  192. package/dist/cjs/product/recordpage/recordpage.recipe.js +162 -0
  193. package/dist/cjs/product/recordpanel/index.js +7 -0
  194. package/dist/cjs/product/recordpanel/recordpanel.js +83 -0
  195. package/dist/cjs/product/recordpanel/recordpanel.recipe.js +51 -0
  196. package/dist/cjs/product/recordstable/company-logos.js +29 -0
  197. package/dist/cjs/product/recordstable/index.js +10 -0
  198. package/dist/cjs/product/recordstable/recordstable.js +1092 -0
  199. package/dist/cjs/product/recordstable/recordstable.recipe.js +152 -0
  200. package/dist/cjs/product/recordstable/recordstable.tag.js +21 -0
  201. package/dist/cjs/product/richtext/index.js +7 -0
  202. package/dist/cjs/product/richtext/richtext.js +147 -0
  203. package/dist/cjs/product/richtext/richtext.recipe.js +43 -0
  204. package/dist/cjs/product/settingssection/index.js +7 -0
  205. package/dist/cjs/product/settingssection/settingssection.js +14 -0
  206. package/dist/cjs/product/settingssection/settingssection.recipe.js +23 -0
  207. package/dist/cjs/product/settingsshell/index.js +7 -0
  208. package/dist/cjs/product/settingsshell/settingsshell.js +59 -0
  209. package/dist/cjs/product/settingsshell/settingsshell.recipe.js +46 -0
  210. package/dist/cjs/product/sidebar/index.js +13 -0
  211. package/dist/cjs/product/sidebar/sidebar.js +148 -0
  212. package/dist/cjs/product/sidebar/sidebar.recipe.js +46 -0
  213. package/dist/cjs/product/tasklist/index.js +7 -0
  214. package/dist/cjs/product/tasklist/tasklist.js +19 -0
  215. package/dist/cjs/product/tasklist/tasklist.recipe.js +38 -0
  216. package/dist/cjs/product/trialbanner/index.js +7 -0
  217. package/dist/cjs/product/trialbanner/trialbanner.js +13 -0
  218. package/dist/cjs/product/trialbanner/trialbanner.recipe.js +32 -0
  219. package/dist/cjs/product/viewtoggle/index.js +7 -0
  220. package/dist/cjs/product/viewtoggle/viewtoggle.js +55 -0
  221. package/dist/cjs/product/viewtoggle/viewtoggle.recipe.js +27 -0
  222. package/dist/cjs/tokens/contract.js +21 -0
  223. package/dist/cjs/tokens/elevation.js +47 -0
  224. package/dist/cjs/tokens/index.js +18 -0
  225. package/dist/cjs/tokens/palette.js +63 -0
  226. package/dist/cjs/tokens/scale.js +70 -0
  227. package/dist/cjs/tokens/semantic.js +57 -0
  228. package/dist/columncalc.css +26 -0
  229. package/dist/columncalc.d.ts +7 -0
  230. package/dist/command.css +34 -1
  231. package/dist/contextmenu.css +10 -2
  232. package/dist/datatable.css +60 -14
  233. package/dist/datepicker.css +175 -19
  234. package/dist/datepicker.d.ts +2 -2
  235. package/dist/datepickerfield.css +27 -0
  236. package/dist/datepickerfield.d.ts +7 -0
  237. package/dist/dialog.css +10 -2
  238. package/dist/donutchart.css +8 -0
  239. package/dist/drawer.css +13 -5
  240. package/dist/entitycard.css +10 -2
  241. package/dist/esm/components/accordion/accordion.js +17 -16
  242. package/dist/esm/components/accordion/accordion.recipe.js +1 -1
  243. package/dist/esm/components/avatargroup/avatargroup.js +2 -2
  244. package/dist/esm/components/avatargroup/avatargroup.recipe.js +2 -2
  245. package/dist/esm/components/badge/badge.recipe.js +4 -4
  246. package/dist/esm/components/barchart/barchart.js +15 -2
  247. package/dist/esm/components/barchart/barchart.recipe.js +10 -5
  248. package/dist/esm/components/breadcrumb/breadcrumb.js +2 -2
  249. package/dist/esm/components/bulkbar/bulkbar.js +2 -2
  250. package/dist/esm/components/bulkbar/bulkbar.recipe.js +4 -4
  251. package/dist/esm/components/button/button.js +13 -2
  252. package/dist/esm/components/button/button.recipe.js +20 -4
  253. package/dist/esm/components/callout/callout.js +2 -2
  254. package/dist/esm/components/checkbox/checkbox.recipe.js +9 -1
  255. package/dist/esm/components/columncalc/columncalc.js +100 -0
  256. package/dist/esm/components/columncalc/columncalc.recipe.js +30 -0
  257. package/dist/esm/components/columncalc/index.js +1 -0
  258. package/dist/esm/components/contextmenu/contextmenu.recipe.js +4 -4
  259. package/dist/esm/components/datatable/datatable.js +276 -49
  260. package/dist/esm/components/datatable/datatable.recipe.js +54 -16
  261. package/dist/esm/components/datepicker/datepicker.js +104 -53
  262. package/dist/esm/components/datepicker/datepicker.recipe.js +180 -25
  263. package/dist/esm/components/datepicker/index.js +1 -1
  264. package/dist/esm/components/datepickerfield/datepickerfield.js +49 -0
  265. package/dist/esm/components/datepickerfield/datepickerfield.recipe.js +41 -0
  266. package/dist/esm/components/datepickerfield/index.js +2 -0
  267. package/dist/esm/components/dialog/dialog.js +2 -2
  268. package/dist/esm/components/dialog/dialog.recipe.js +4 -4
  269. package/dist/esm/components/divider/divider.js +2 -2
  270. package/dist/esm/components/donutchart/donutchart.js +2 -2
  271. package/dist/esm/components/drawer/drawer.js +2 -2
  272. package/dist/esm/components/drawer/drawer.recipe.js +6 -6
  273. package/dist/esm/components/emptystate/emptystate.js +2 -2
  274. package/dist/esm/components/formfield/formfield.js +2 -2
  275. package/dist/esm/components/input/input.js +6 -3
  276. package/dist/esm/components/input/input.recipe.js +38 -5
  277. package/dist/esm/components/linechart/linechart.js +15 -2
  278. package/dist/esm/components/linechart/linechart.recipe.js +10 -5
  279. package/dist/esm/components/menu/index.js +1 -0
  280. package/dist/esm/components/menu/menu-keyboard.js +80 -0
  281. package/dist/esm/components/menu/menu.js +27 -60
  282. package/dist/esm/components/menu/menu.recipe.js +5 -5
  283. package/dist/esm/components/multiselect/multiselect.js +10 -3
  284. package/dist/esm/components/multiselect/multiselect.recipe.js +8 -8
  285. package/dist/esm/components/popover/popover.js +2 -2
  286. package/dist/esm/components/popover/popover.recipe.js +2 -2
  287. package/dist/esm/components/progress/progress.js +3 -3
  288. package/dist/esm/components/radiogroup/radiogroup.js +2 -2
  289. package/dist/esm/components/radiogroup/radiogroup.recipe.js +1 -1
  290. package/dist/esm/components/resizablepanel/index.js +2 -0
  291. package/dist/esm/components/resizablepanel/resizablepanel.js +135 -0
  292. package/dist/esm/components/resizablepanel/resizablepanel.recipe.js +66 -0
  293. package/dist/esm/components/segmented/segmented.js +2 -2
  294. package/dist/esm/components/select/select.js +2 -2
  295. package/dist/esm/components/select/select.recipe.js +6 -6
  296. package/dist/esm/components/skeleton/skeleton.js +5 -2
  297. package/dist/esm/components/spinner/spinner.js +3 -2
  298. package/dist/esm/components/stagebar/stagebar.js +2 -2
  299. package/dist/esm/components/statcard/statcard.js +2 -2
  300. package/dist/esm/components/table/table.recipe.js +6 -6
  301. package/dist/esm/components/tabletoolbar/tabletoolbar.chrome.js +3 -3
  302. package/dist/esm/components/tabletoolbar/tabletoolbar.js +21 -13
  303. package/dist/esm/components/tabs/tabs.js +2 -2
  304. package/dist/esm/components/tabs/tabs.recipe.js +4 -4
  305. package/dist/esm/components/textarea/textarea.js +5 -5
  306. package/dist/esm/components/textarea/textarea.recipe.js +16 -4
  307. package/dist/esm/components/toast/toast.js +4 -4
  308. package/dist/esm/components/toast/toast.recipe.js +2 -2
  309. package/dist/esm/components/tooltip/tooltip.js +21 -7
  310. package/dist/esm/components/wheelpicker/index.js +2 -0
  311. package/dist/esm/components/wheelpicker/wheelpicker.js +98 -0
  312. package/dist/esm/components/wheelpicker/wheelpicker.recipe.js +92 -0
  313. package/dist/esm/index.js +5 -0
  314. package/dist/esm/product/appshell/appshell.js +33 -9
  315. package/dist/esm/product/appshell/appshell.recipe.js +4 -4
  316. package/dist/esm/product/authshell/authshell.js +18 -0
  317. package/dist/esm/product/authshell/authshell.recipe.js +64 -0
  318. package/dist/esm/product/authshell/index.js +2 -0
  319. package/dist/esm/product/board/board.js +2 -2
  320. package/dist/esm/product/board/board.recipe.js +1 -1
  321. package/dist/esm/product/command/command.js +19 -6
  322. package/dist/esm/product/command/command.recipe.js +27 -2
  323. package/dist/esm/product/entitycard/entitycard.js +2 -2
  324. package/dist/esm/product/entitycard/entitycard.recipe.js +2 -2
  325. package/dist/esm/product/flowcanvas/flowcanvas.js +4 -4
  326. package/dist/esm/product/inbox/inbox.recipe.js +1 -1
  327. package/dist/esm/product/listpage/listpage.recipe.js +3 -3
  328. package/dist/esm/product/navitem/navitem.recipe.js +13 -1
  329. package/dist/esm/product/onboarding/onboarding.js +2 -2
  330. package/dist/esm/product/onboarding/onboarding.recipe.js +2 -2
  331. package/dist/esm/product/recordpage/recordpage.js +133 -47
  332. package/dist/esm/product/recordpage/recordpage.recipe.js +19 -17
  333. package/dist/esm/product/recordpanel/recordpanel.js +4 -4
  334. package/dist/esm/product/recordpanel/recordpanel.recipe.js +12 -16
  335. package/dist/esm/product/recordstable/recordstable.js +157 -66
  336. package/dist/esm/product/recordstable/recordstable.recipe.js +23 -23
  337. package/dist/esm/product/recordstable/recordstable.tag.js +18 -0
  338. package/dist/esm/product/richtext/richtext.js +3 -3
  339. package/dist/esm/product/richtext/richtext.recipe.js +3 -3
  340. package/dist/esm/product/settingssection/settingssection.js +2 -2
  341. package/dist/esm/product/settingsshell/settingsshell.js +2 -2
  342. package/dist/esm/product/settingsshell/settingsshell.recipe.js +7 -2
  343. package/dist/esm/product/sidebar/sidebar.js +2 -2
  344. package/dist/esm/product/sidebar/sidebar.recipe.js +27 -2
  345. package/dist/esm/product/tasklist/tasklist.js +4 -4
  346. package/dist/esm/product/trialbanner/trialbanner.js +2 -2
  347. package/dist/esm/product/trialbanner/trialbanner.recipe.js +2 -2
  348. package/dist/esm/product/viewtoggle/viewtoggle.js +10 -2
  349. package/dist/esm/product/viewtoggle/viewtoggle.recipe.js +1 -1
  350. package/dist/esm/tokens/elevation.js +44 -0
  351. package/dist/esm/tokens/index.js +1 -0
  352. package/dist/esm/tokens/palette.js +30 -0
  353. package/dist/esm/tokens/scale.js +7 -0
  354. package/dist/esm/tokens/semantic.js +24 -0
  355. package/dist/inbox.css +9 -1
  356. package/dist/input.css +32 -4
  357. package/dist/linechart.css +5 -5
  358. package/dist/listpage.css +11 -3
  359. package/dist/menu.css +11 -3
  360. package/dist/multiselect.css +14 -6
  361. package/dist/native/tokens.d.ts +16 -0
  362. package/dist/native/tokens.js +221 -0
  363. package/dist/navitem.css +21 -1
  364. package/dist/onboarding.css +10 -2
  365. package/dist/popover.css +8 -0
  366. package/dist/progress.css +8 -0
  367. package/dist/radiogroup.css +9 -1
  368. package/dist/recordpage.css +22 -12
  369. package/dist/recordpanel.css +25 -15
  370. package/dist/recordstable.css +37 -23
  371. package/dist/resizablepanel.css +53 -0
  372. package/dist/resizablepanel.d.ts +7 -0
  373. package/dist/richtext.css +11 -3
  374. package/dist/segmented.css +8 -0
  375. package/dist/select.css +12 -4
  376. package/dist/settingsshell.css +15 -2
  377. package/dist/sidebar.css +34 -1
  378. package/dist/skeleton.css +8 -0
  379. package/dist/spinner.css +8 -0
  380. package/dist/stagebar.css +8 -0
  381. package/dist/styles.css +2061 -1111
  382. package/dist/switch.css +8 -0
  383. package/dist/table.css +14 -6
  384. package/dist/tabletoolbar.css +8 -0
  385. package/dist/tabs.css +12 -4
  386. package/dist/tasklist.css +8 -0
  387. package/dist/textarea.css +23 -3
  388. package/dist/toast.css +10 -2
  389. package/dist/tokens.css +29 -0
  390. package/dist/tokens.json +217 -0
  391. package/dist/tooltip.css +8 -0
  392. package/dist/trialbanner.css +8 -0
  393. package/dist/types/components/accordion/accordion.d.ts +10 -8
  394. package/dist/types/components/avatargroup/avatargroup.d.ts +2 -2
  395. package/dist/types/components/barchart/barchart.d.ts +4 -2
  396. package/dist/types/components/breadcrumb/breadcrumb.d.ts +2 -2
  397. package/dist/types/components/bulkbar/bulkbar.d.ts +4 -2
  398. package/dist/types/components/button/button.d.ts +8 -0
  399. package/dist/types/components/button/button.recipe.d.ts +12 -0
  400. package/dist/types/components/callout/callout.d.ts +2 -2
  401. package/dist/types/components/columncalc/columncalc.d.ts +49 -0
  402. package/dist/types/components/columncalc/columncalc.recipe.d.ts +3 -0
  403. package/dist/types/components/columncalc/index.d.ts +1 -0
  404. package/dist/types/components/datatable/datatable.d.ts +58 -3
  405. package/dist/types/components/datepicker/datepicker.d.ts +41 -18
  406. package/dist/types/components/datepicker/datepicker.recipe.d.ts +25 -2
  407. package/dist/types/components/datepicker/index.d.ts +1 -1
  408. package/dist/types/components/datepickerfield/datepickerfield.d.ts +35 -0
  409. package/dist/types/components/datepickerfield/datepickerfield.recipe.d.ts +5 -0
  410. package/dist/types/components/datepickerfield/index.d.ts +2 -0
  411. package/dist/types/components/dialog/dialog.d.ts +3 -1
  412. package/dist/types/components/divider/divider.d.ts +2 -2
  413. package/dist/types/components/donutchart/donutchart.d.ts +2 -2
  414. package/dist/types/components/drawer/drawer.d.ts +3 -1
  415. package/dist/types/components/emptystate/emptystate.d.ts +2 -2
  416. package/dist/types/components/formfield/formfield.d.ts +7 -4
  417. package/dist/types/components/input/input.d.ts +8 -2
  418. package/dist/types/components/linechart/linechart.d.ts +4 -2
  419. package/dist/types/components/menu/index.d.ts +1 -0
  420. package/dist/types/components/menu/menu-keyboard.d.ts +33 -0
  421. package/dist/types/components/menu/menu.d.ts +7 -1
  422. package/dist/types/components/multiselect/multiselect.d.ts +8 -4
  423. package/dist/types/components/popover/popover.d.ts +4 -1
  424. package/dist/types/components/progress/progress.d.ts +2 -2
  425. package/dist/types/components/radiogroup/radiogroup.d.ts +2 -2
  426. package/dist/types/components/resizablepanel/index.d.ts +2 -0
  427. package/dist/types/components/resizablepanel/resizablepanel.d.ts +75 -0
  428. package/dist/types/components/resizablepanel/resizablepanel.recipe.d.ts +3 -0
  429. package/dist/types/components/segmented/segmented.d.ts +2 -2
  430. package/dist/types/components/select/select.d.ts +2 -2
  431. package/dist/types/components/skeleton/skeleton.d.ts +2 -2
  432. package/dist/types/components/spinner/spinner.d.ts +2 -2
  433. package/dist/types/components/stagebar/stagebar.d.ts +2 -2
  434. package/dist/types/components/statcard/statcard.d.ts +2 -2
  435. package/dist/types/components/tabletoolbar/tabletoolbar.d.ts +28 -2
  436. package/dist/types/components/tabs/tabs.d.ts +2 -2
  437. package/dist/types/components/toast/toast.d.ts +7 -1
  438. package/dist/types/components/tooltip/tooltip.d.ts +8 -1
  439. package/dist/types/components/wheelpicker/index.d.ts +2 -0
  440. package/dist/types/components/wheelpicker/wheelpicker.d.ts +37 -0
  441. package/dist/types/components/wheelpicker/wheelpicker.recipe.d.ts +26 -0
  442. package/dist/types/index.d.ts +5 -0
  443. package/dist/types/product/appshell/appshell.d.ts +16 -2
  444. package/dist/types/product/authshell/authshell.d.ts +28 -0
  445. package/dist/types/product/authshell/authshell.recipe.d.ts +3 -0
  446. package/dist/types/product/authshell/index.d.ts +2 -0
  447. package/dist/types/product/board/board.d.ts +2 -2
  448. package/dist/types/product/command/command.d.ts +25 -1
  449. package/dist/types/product/entitycard/entitycard.d.ts +2 -2
  450. package/dist/types/product/flowcanvas/flowcanvas.d.ts +9 -1
  451. package/dist/types/product/onboarding/onboarding.d.ts +7 -1
  452. package/dist/types/product/recordpage/recordpage.d.ts +65 -1
  453. package/dist/types/product/recordpanel/recordpanel.d.ts +8 -2
  454. package/dist/types/product/recordstable/recordstable.d.ts +90 -1
  455. package/dist/types/product/recordstable/recordstable.tag.d.ts +10 -0
  456. package/dist/types/product/richtext/richtext.d.ts +5 -1
  457. package/dist/types/product/settingssection/settingssection.d.ts +2 -2
  458. package/dist/types/product/settingsshell/settingsshell.d.ts +6 -2
  459. package/dist/types/product/sidebar/sidebar.d.ts +8 -0
  460. package/dist/types/product/tasklist/tasklist.d.ts +5 -1
  461. package/dist/types/product/trialbanner/trialbanner.d.ts +2 -2
  462. package/dist/types/product/viewtoggle/viewtoggle.d.ts +11 -5
  463. package/dist/types/tokens/contract.d.ts +14 -3
  464. package/dist/types/tokens/elevation.d.ts +44 -0
  465. package/dist/types/tokens/index.d.ts +1 -0
  466. package/dist/types/tokens/palette.d.ts +40 -0
  467. package/dist/types/tokens/scale.d.ts +7 -0
  468. package/dist/types/tokens/semantic.d.ts +19 -0
  469. package/dist/viewtoggle.css +9 -1
  470. package/dist/wheelpicker.css +68 -0
  471. package/dist/wheelpicker.d.ts +7 -0
  472. package/package.json +160 -68
@@ -1,21 +1,21 @@
1
1
  import { defineRecipe, resolveRecipe } from "../../core/index.js";
2
- import { contract as c } from "../../tokens/index.js";
2
+ import { contract as c, elevation as e } from "../../tokens/index.js";
3
3
  // A side sheet — a focus-trapped panel that slides in from the right or left,
4
4
  // over a scrim. Shares the Dialog header/body/footer language.
5
5
  const config = defineRecipe({
6
6
  name: "drawer",
7
7
  base: `display: contents; font-family: ${c.font.sans};
8
8
  & .drawer-backdrop { position: fixed; inset: 0; z-index: 60; background: color-mix(in srgb, ${c.fgPrimary} 18%, transparent); opacity: 1; transition: opacity 0.2s ease; @starting-style { opacity: 0; } }
9
- & .drawer-positioner { position: fixed; inset: 0; z-index: 61; display: flex; }
9
+ & .drawer-positioner { position: fixed; inset: 0; z-index: 61; display: flex; box-sizing: border-box; padding: ${c.space["2"]}; }
10
10
  & .drawer-positioner[data-side="right"] { justify-content: flex-end; }
11
11
  & .drawer-positioner[data-side="left"] { justify-content: flex-start; }
12
- & .drawer-content { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; position: relative; display: flex; flex-direction: column; box-sizing: border-box; width: 420px; max-width: 92vw; height: 100%; background: ${c.bgSurface}; transform: none; transition: transform 0.24s cubic-bezier(.32,.72,0,1); }
13
- & .drawer-positioner[data-side="right"] .drawer-content { box-shadow: -12px 0 32px -8px rgba(28,40,64,0.18); @starting-style { transform: translateX(100%); } }
14
- & .drawer-positioner[data-side="left"] .drawer-content { box-shadow: 12px 0 32px -8px rgba(28,40,64,0.18); @starting-style { transform: translateX(-100%); } }
12
+ & .drawer-content { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; position: relative; display: flex; flex-direction: column; box-sizing: border-box; overflow: hidden; width: 420px; max-width: 100%; height: 100%; background: ${c.bgSurface}; border-radius: ${c.radius.xl}; box-shadow: ${e.floating}; transform: none; transition: transform 0.24s cubic-bezier(.32,.72,0,1); }
13
+ & .drawer-positioner[data-side="right"] .drawer-content { @starting-style { transform: translateX(calc(100% + ${c.space["2"]})); } }
14
+ & .drawer-positioner[data-side="left"] .drawer-content { @starting-style { transform: translateX(calc(-100% - ${c.space["2"]})); } }
15
15
  & .drawer-header { display: flex; align-items: center; gap: ${c.space["2"]}; flex-shrink: 0; height: 52px; padding: 0 ${c.space["2"]} 0 ${c.space["4"]}; border-bottom: 1px solid ${c.borderSubtle}; }
16
16
  & .drawer-header svg { flex-shrink: 0; color: ${c.fgMuted}; }
17
17
  & .drawer-title { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: ${c.text.lg}; font-weight: ${c.weight.semibold}; color: ${c.fgPrimary}; }
18
- & .drawer-close { display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; width: 28px; height: 28px; margin: 0; padding: 0; border: none; border-radius: ${c.radius.md}; background: none; color: ${c.fgMuted}; cursor: pointer; }
18
+ & .drawer-close { display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; width: 28px; height: 28px; margin: 0; padding: 0; border: none; border-radius: ${c.radius.md}; background: none; color: ${c.fgMuted}; font-family: inherit; cursor: pointer; }
19
19
  & .drawer-close:hover { background: color-mix(in srgb, ${c.fgPrimary} 6%, transparent); color: ${c.fgPrimary}; }
20
20
  & .drawer-body { flex: 1; min-height: 0; overflow-y: auto; padding: ${c.space["4"]}; }
21
21
  & .drawer-footer { display: flex; align-items: center; justify-content: flex-end; gap: ${c.space["3"]}; flex-shrink: 0; min-height: 56px; padding: 0 ${c.space["4"]}; border-top: 1px solid ${c.borderSubtle}; }`,
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { emptystateRecipe } from "./emptystate.recipe.js";
3
3
  /** A centred empty-state panel — icon, title, description, optional action. */
4
- export function EmptyState({ icon, title, description, action, variant, className, }) {
5
- return (_jsxs("div", { className: emptystateRecipe({ variant, className }), children: [icon && _jsx("span", { className: "emptystate-icon", children: icon }), _jsx("div", { className: "emptystate-title", children: title }), description != null && (_jsx("div", { className: "emptystate-desc", children: description })), action && _jsx("div", { className: "emptystate-action", children: action })] }));
4
+ export function EmptyState({ icon, title, description, action, variant, className, ...rest }) {
5
+ return (_jsxs("div", { className: emptystateRecipe({ variant, className }), ...rest, children: [icon && _jsx("span", { className: "emptystate-icon", children: icon }), _jsx("div", { className: "emptystate-title", children: title }), description != null && (_jsx("div", { className: "emptystate-desc", children: description })), action && _jsx("div", { className: "emptystate-action", children: action })] }));
6
6
  }
7
7
  EmptyState.displayName = "EmptyState";
@@ -6,9 +6,9 @@ import { formfieldRecipe } from "./formfield.recipe.js";
6
6
  * above any control, with an optional description or error line below. When
7
7
  * `error` is set, it replaces the description and gets `aria-describedby` wiring.
8
8
  */
9
- export function FormField({ label, htmlFor, required, optional, description, error, children, className, }) {
9
+ export function FormField({ label, htmlFor, required, optional, description, error, children, className, ...rest }) {
10
10
  const descId = React.useId();
11
11
  const hasMsg = error != null || description != null;
12
- return (_jsxs("div", { className: formfieldRecipe({ className }), children: [_jsxs("label", { className: "formfield-label", htmlFor: htmlFor, children: [label, required && (_jsx("span", { className: "formfield-required", "aria-hidden": "true", children: "*" })), optional && !required && (_jsx("span", { className: "formfield-optional", children: "(optional)" }))] }), children, error != null ? (_jsx("span", { className: "formfield-error", id: hasMsg ? descId : undefined, children: error })) : description != null ? (_jsx("span", { className: "formfield-desc", id: hasMsg ? descId : undefined, children: description })) : null] }));
12
+ return (_jsxs("div", { className: formfieldRecipe({ className }), ...rest, children: [_jsxs("label", { className: "formfield-label", htmlFor: htmlFor, children: [label, required && (_jsx("span", { className: "formfield-required", "aria-hidden": "true", children: "*" })), optional && !required && (_jsx("span", { className: "formfield-optional", children: optional === true ? "(optional)" : optional }))] }), children, error != null ? (_jsx("span", { className: "formfield-error", id: hasMsg ? descId : undefined, children: error })) : description != null ? (_jsx("span", { className: "formfield-desc", id: hasMsg ? descId : undefined, children: description })) : null] }));
13
13
  }
14
14
  FormField.displayName = "FormField";
@@ -1,8 +1,11 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import * as React from "react";
3
- import { Primitive } from "../../core/index.js";
4
3
  import { inputRecipe } from "./input.recipe.js";
5
- export const Input = React.forwardRef(({ size, invalid, className, ...props }, ref) => {
6
- return (_jsx(Primitive.input, { ref: ref, className: inputRecipe({ size, invalid, className }), "aria-invalid": invalid === true || undefined, ...props }));
4
+ export const Input = React.forwardRef(({ size, invalid, className, style, ...props }, ref) => {
5
+ // The wrapper exists only to host the ::after focus ring — an <input> is a
6
+ // replaced element and cannot have one. Everything the consumer passes
7
+ // still lands on the <input> itself, so `id`, `name`, `onChange`, form
8
+ // association and every native attribute behave exactly as before.
9
+ return (_jsx("span", { className: inputRecipe({ size, invalid, className }), style: style, children: _jsx("input", { ref: ref, className: "input-value", "aria-invalid": invalid === true || undefined, ...props }) }));
7
10
  });
8
11
  Input.displayName = "Input";
@@ -1,15 +1,48 @@
1
1
  import { defineRecipe, resolveRecipe } from "../../core/index.js";
2
- import { contract as c } from "../../tokens/index.js";
2
+ import { contract as c, elevation as e } from "../../tokens/index.js";
3
+ // Geometry is Attio's, measured: 32/36px tall, r8/r10, 10/12px side padding.
4
+ // The FOCUS TREATMENT is seed-design's, measured from @seed-design/css: a 2px
5
+ // ring on an ::after overlay that is present-but-transparent at rest, so
6
+ // focusing cannot shift layout the way a width change would, and animates
7
+ // `border-color` over 100ms. The ring colour is a high-contrast neutral rather
8
+ // than the brand hue — it reads as "this field has focus", not as a state.
9
+ //
10
+ // The ring needs the ::after, and ::after needs a non-replaced element, so
11
+ // Input renders a wrapper around the <input>. The wrapper is presentational:
12
+ // every consumer prop still goes to the <input>, which is what `id`, `name`,
13
+ // `onChange` and form semantics require.
3
14
  const config = defineRecipe({
4
15
  name: "input",
5
- base: `box-sizing: border-box; display: inline-flex; width: 100%; font-family: ${c.font.sans}; font-size: ${c.text.lg}; line-height: 20px; color: ${c.fgPrimary}; background: ${c.bgSurface}; border: none; outline: none; box-shadow: 0 0 2px rgba(28,40,64,0.18), 0 1px 3px rgba(0,0,0,0.04); transition: box-shadow .15s; &::placeholder { color: ${c.fgMuted}; } &:focus { box-shadow: inset 0 0 0 1px ${c.bgBrandSolid}; } &:disabled { opacity: 0.5; cursor: not-allowed; }`,
16
+ base: `
17
+ position: relative; box-sizing: border-box; display: inline-flex; align-items: center;
18
+ width: 100%; background: ${c.bgSurface}; box-shadow: ${e.field};
19
+ font-family: ${c.font.sans}; font-size: ${c.text.lg}; line-height: 20px;
20
+
21
+ &::after {
22
+ content: ""; position: absolute; inset: 0; border-radius: inherit;
23
+ border: 2px solid transparent; transition: border-color .1s ease;
24
+ pointer-events: none;
25
+ }
26
+ &:focus-within::after { border-color: ${c.strokeFieldFocus}; }
27
+
28
+ & .input-value {
29
+ box-sizing: border-box; flex: 1 1 auto; min-width: 0; width: 100%;
30
+ align-self: stretch; margin: 0; border: none; background: none; outline: none;
31
+ font: inherit; color: ${c.fgPrimary};
32
+ }
33
+ & .input-value::placeholder { color: ${c.fgMuted}; }
34
+ & .input-value:disabled { opacity: 0.5; cursor: not-allowed; }
35
+ &:has(.input-value:disabled) { opacity: 1; }
36
+ `,
6
37
  variants: {
7
38
  size: {
8
- medium: `height: 32px; padding-inline: ${c.space["2.5"]}; border-radius: ${c.radius.md};`,
9
- large: `height: 36px; padding-inline: ${c.space["3"]}; border-radius: 10px;`,
39
+ medium: `height: 32px; border-radius: ${c.radius.md}; & .input-value { padding-inline: ${c.space["2.5"]}; }`,
40
+ large: `height: 36px; border-radius: 10px; & .input-value { padding-inline: ${c.space["3"]}; }`,
10
41
  },
11
42
  invalid: {
12
- true: `box-shadow: inset 0 0 0 1px ${c.bgDanger}; &:focus { box-shadow: inset 0 0 0 1px ${c.bgDanger}; }`,
43
+ // critical outranks focus: a field that is wrong stays visibly wrong
44
+ // while you are correcting it, which is seed's behaviour too
45
+ true: `&::after { border-color: ${c.bgDanger}; } &:focus-within::after { border-color: ${c.bgDanger}; }`,
13
46
  false: ``,
14
47
  },
15
48
  },
@@ -1,4 +1,5 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { contract as c } from "../../tokens/index.js";
2
3
  import { linechartRecipe } from "./linechart.recipe.js";
3
4
  function niceNum(raw) {
4
5
  if (raw <= 0)
@@ -13,11 +14,20 @@ function niceNum(raw) {
13
14
  * A stretched SVG line/area (non-scaling stroke keeps it crisp) over dashed
14
15
  * gridlines; dots are HTML so they stay round. `role="img"` with a summary.
15
16
  */
16
- export function LineChart({ data, height = 240, max, ticks = 5, color, area = true, dots = true, format = (n) => n.toLocaleString(), xAxisTitle, "aria-label": ariaLabel, className, }) {
17
+ export function LineChart({ data, height = 240, max, ticks = 5, color, area = true, dots = true, format = (n) => n.toLocaleString(), yAxisWidth, xAxisTitle, "aria-label": ariaLabel, className, ...rest }) {
17
18
  const rawMax = Math.max(1, ...data.map((d) => d.value));
18
19
  const step = max ? max / (ticks - 1) : niceNum(rawMax / (ticks - 1));
19
20
  const top = step * (ticks - 1);
20
21
  const tickValues = Array.from({ length: ticks }, (_, i) => step * i);
22
+ // The value-axis gutter must fit whatever `format` actually returns — a
23
+ // hardcoded width fits "4.0k" but not "4,000,000₮". `ch` is the width of
24
+ // "0" in the current font, so sizing off the longest formatted tick tracks
25
+ // the real label width without measuring the DOM (works during SSR, no
26
+ // ResizeObserver). `yAxisWidth` lets a caller pin the gutter instead.
27
+ const longestTickChars = Math.max(0, ...tickValues.map((t) => format(t).length));
28
+ const yAxisWidthValue = yAxisWidth != null
29
+ ? `${yAxisWidth}px`
30
+ : `max(34px, ${longestTickChars}ch + ${c.space["4"]})`;
21
31
  // points in a 0..100 viewBox (y inverted: 0 at top)
22
32
  const n = data.length;
23
33
  const pts = data.map((d, i) => {
@@ -31,7 +41,10 @@ export function LineChart({ data, height = 240, max, ticks = 5, color, area = tr
31
41
  : "";
32
42
  const summary = ariaLabel ??
33
43
  `Line chart: ${data.map((d) => `${d.label} ${format(d.value)}`).join(", ")}`;
34
- return (_jsxs("div", { className: linechartRecipe({ className }), style: { height }, role: "img", "aria-label": summary, children: [_jsxs("div", { className: "linechart-body", children: [_jsx("div", { className: "linechart-yaxis", children: tickValues.map((t) => (_jsx("span", { className: "linechart-ytick", style: { bottom: `${(t / top) * 100}%` }, children: format(t) }, t))) }), _jsxs("div", { className: "linechart-plot", children: [tickValues.map((t) => (_jsx("div", { className: "linechart-grid", style: { bottom: `${(t / top) * 100}%` } }, t))), pts.length > 1 && (_jsxs("svg", { className: "linechart-svg", viewBox: "0 0 100 100", preserveAspectRatio: "none", "aria-hidden": "true", children: [area && _jsx("path", { className: "linechart-area", d: areaPath }), _jsx("polyline", { className: "linechart-line", points: line, style: { stroke: color } })] })), dots &&
44
+ return (_jsxs("div", { className: linechartRecipe({ className }), ...rest, style: {
45
+ height,
46
+ "--linechart-yaxis-width": yAxisWidthValue,
47
+ }, role: "img", "aria-label": summary, children: [_jsxs("div", { className: "linechart-body", children: [_jsx("div", { className: "linechart-yaxis", children: tickValues.map((t) => (_jsx("span", { className: "linechart-ytick", style: { bottom: `${(t / top) * 100}%` }, children: format(t) }, t))) }), _jsxs("div", { className: "linechart-plot", children: [tickValues.map((t) => (_jsx("div", { className: "linechart-grid", style: { bottom: `${(t / top) * 100}%` } }, t))), pts.length > 1 && (_jsxs("svg", { className: "linechart-svg", viewBox: "0 0 100 100", preserveAspectRatio: "none", "aria-hidden": "true", children: [area && _jsx("path", { className: "linechart-area", d: areaPath }), _jsx("polyline", { className: "linechart-line", points: line, style: { stroke: color } })] })), dots &&
35
48
  pts.map((p, i) => (_jsx("span", { className: "linechart-dot-html", style: {
36
49
  left: `${p.x}%`,
37
50
  bottom: `${p.frac * 100}%`,
@@ -6,19 +6,24 @@ import { contract as c } from "../../tokens/index.js";
6
6
  // its box (non-scaling stroke keeps the line crisp); axes are HTML.
7
7
  const config = defineRecipe({
8
8
  name: "linechart",
9
- base: `display: flex; flex-direction: column; box-sizing: border-box; font-family: ${c.font.sans};
9
+ // --linechart-yaxis-width is the one source of truth for the value-axis
10
+ // gutter: the component sets it (auto-sized to the longest tick label, or
11
+ // pinned via `yAxisWidth`) on the root element, and it inherits down to the
12
+ // x-axis padding and axis title so they never drift out of alignment. 34px
13
+ // is only the pre-JS fallback (e.g. if `linechartRecipe` is used bare).
14
+ base: `display: flex; flex-direction: column; box-sizing: border-box; font-family: ${c.font.sans}; --linechart-yaxis-width: 34px;
10
15
  & .linechart-body { display: flex; flex: 1; min-height: 0; }
11
- & .linechart-yaxis { position: relative; flex-shrink: 0; width: 34px; }
12
- & .linechart-ytick { position: absolute; right: ${c.space["2"]}; transform: translateY(50%); font-size: ${c.text.xs}; color: ${c.fgMuted}; white-space: nowrap; }
16
+ & .linechart-yaxis { position: relative; flex-shrink: 0; width: var(--linechart-yaxis-width); }
17
+ & .linechart-ytick { position: absolute; inset-inline-end: ${c.space["2"]}; transform: translateY(50%); font-size: ${c.text.xs}; color: ${c.fgMuted}; white-space: nowrap; }
13
18
  & .linechart-plot { position: relative; flex: 1; min-width: 0; border-bottom: 1px solid ${c.borderDefault}; }
14
19
  & .linechart-grid { position: absolute; left: 0; right: 0; border-top: 1px dashed ${c.borderSubtle}; pointer-events: none; }
15
20
  & .linechart-svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
16
21
  & .linechart-area { fill: color-mix(in srgb, ${c.bgBrandSolid} 12%, transparent); stroke: none; }
17
22
  & .linechart-line { fill: none; stroke: ${c.bgBrandSolid}; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
18
23
  & .linechart-dot-html { position: absolute; width: 8px; height: 8px; box-sizing: border-box; border-radius: ${c.radius.full}; background: ${c.bgSurface}; border: 2px solid ${c.bgBrandSolid}; transform: translate(-50%, 50%); pointer-events: auto; }
19
- & .linechart-xaxis { display: flex; margin-top: ${c.space["1.5"]}; padding-left: 34px; }
24
+ & .linechart-xaxis { display: flex; margin-top: ${c.space["1.5"]}; padding-inline-start: var(--linechart-yaxis-width); }
20
25
  & .linechart-xlabel { flex: 1; min-width: 0; text-align: center; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: ${c.text.sm}; color: ${c.fgMuted}; }
21
- & .linechart-axis-title { margin-top: ${c.space["1"]}; padding-left: 34px; text-align: center; font-size: ${c.text.sm}; color: ${c.fgMuted}; }`,
26
+ & .linechart-axis-title { margin-top: ${c.space["1"]}; padding-inline-start: var(--linechart-yaxis-width); text-align: center; font-size: ${c.text.sm}; color: ${c.fgMuted}; }`,
22
27
  variants: {},
23
28
  defaultVariants: {},
24
29
  compoundVariants: [],
@@ -1,2 +1,3 @@
1
1
  export { Menu, MenuCheckboxItem, MenuItem, MenuLabel, MenuSeparator, } from "./menu.js";
2
2
  export { menuRecipe } from "./menu.recipe.js";
3
+ export { MENU_ITEM_SELECTOR, useMenuKeyboard, } from "./menu-keyboard.js";
@@ -0,0 +1,80 @@
1
+ import * as React from "react";
2
+ /**
3
+ * The elements a `role="menu"` may own, minus the disabled ones. Kept here so
4
+ * every menu surface in crisp agrees on what counts as an item.
5
+ */
6
+ export const MENU_ITEM_SELECTOR = [
7
+ '[role="menuitem"]',
8
+ '[role="menuitemcheckbox"]',
9
+ '[role="menuitemradio"]',
10
+ ]
11
+ // a disabled item is not focusable, so leaving it in the list would strand
12
+ // the roving focus on it — both spellings have to go
13
+ .map((role) => `${role}:not([data-disabled]):not(:disabled)`)
14
+ .join(",");
15
+ /**
16
+ * The WAI-ARIA menu keyboard model: focus the first item on open, ↑/↓ to move
17
+ * (wrapping), Home/End to jump, printable characters for typeahead, Esc to
18
+ * close, Tab to dismiss. Returns the `onKeyDown` to put on the menu element.
19
+ *
20
+ * Extracted from `Menu` so the table surfaces, which build their own popovers
21
+ * against measured positions, get the identical model instead of a second
22
+ * partial one.
23
+ */
24
+ export function useMenuKeyboard({ open, close, dismiss = close, contentRef, }) {
25
+ const typeahead = React.useRef("");
26
+ const typeaheadTimer = React.useRef(undefined);
27
+ const items = React.useCallback(() => Array.from(contentRef.current?.querySelectorAll(MENU_ITEM_SELECTOR) ??
28
+ []), [contentRef]);
29
+ // focus the first item when the menu opens
30
+ React.useEffect(() => {
31
+ if (!open)
32
+ return;
33
+ const id = requestAnimationFrame(() => contentRef.current
34
+ ?.querySelector(MENU_ITEM_SELECTOR)
35
+ ?.focus());
36
+ return () => cancelAnimationFrame(id);
37
+ }, [open, contentRef]);
38
+ React.useEffect(() => () => clearTimeout(typeaheadTimer.current), []);
39
+ const onKeyDown = (e) => {
40
+ const list = items();
41
+ const idx = list.indexOf(document.activeElement);
42
+ if (e.key === "ArrowDown") {
43
+ e.preventDefault();
44
+ list[(idx + 1) % list.length]?.focus();
45
+ }
46
+ else if (e.key === "ArrowUp") {
47
+ e.preventDefault();
48
+ list[(idx - 1 + list.length) % list.length]?.focus();
49
+ }
50
+ else if (e.key === "Home") {
51
+ e.preventDefault();
52
+ list[0]?.focus();
53
+ }
54
+ else if (e.key === "End") {
55
+ e.preventDefault();
56
+ list[list.length - 1]?.focus();
57
+ }
58
+ else if (e.key === "Escape") {
59
+ e.preventDefault();
60
+ close();
61
+ }
62
+ else if (e.key === "Tab") {
63
+ dismiss();
64
+ }
65
+ else if (e.key.length === 1 && /\S/.test(e.key)) {
66
+ // typeahead: jump to the next item starting with the typed run
67
+ typeahead.current += e.key.toLowerCase();
68
+ clearTimeout(typeaheadTimer.current);
69
+ typeaheadTimer.current = setTimeout(() => {
70
+ typeahead.current = "";
71
+ }, 500);
72
+ const match = list.find((el) => (el.textContent ?? "")
73
+ .trim()
74
+ .toLowerCase()
75
+ .startsWith(typeahead.current));
76
+ match?.focus();
77
+ }
78
+ };
79
+ return { onKeyDown, items };
80
+ }
@@ -2,8 +2,8 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { Check } from "lucide-react";
3
3
  import * as React from "react";
4
4
  import { menuRecipe } from "./menu.recipe.js";
5
+ import { useMenuKeyboard } from "./menu-keyboard.js";
5
6
  const MenuContext = React.createContext(null);
6
- const ITEM_SELECTOR = '[role="menuitem"]:not([data-disabled]),[role="menuitemcheckbox"]:not([data-disabled]),[role="menuitemradio"]:not([data-disabled])';
7
7
  /**
8
8
  * A dropdown menu — the ⋯ / sort / filter menu surface, on Attio's measured
9
9
  * popover. Give it a `trigger` element and Menu items as children. Opens on
@@ -11,23 +11,26 @@ const ITEM_SELECTOR = '[role="menuitem"]:not([data-disabled]),[role="menuitemche
11
11
  * typeahead, Enter/Space select, Esc closes and returns focus to the trigger);
12
12
  * closes on outside click. Flips up / right-aligns when space is tight.
13
13
  */
14
- export function Menu({ trigger, children, align = "start", className, "aria-label": ariaLabel, }) {
15
- const [open, setOpen] = React.useState(false);
14
+ export function Menu({ trigger, children, align = "start", open: openProp, defaultOpen, onOpenChange, className, "aria-label": ariaLabel, }) {
15
+ const [internalOpen, setInternalOpen] = React.useState(defaultOpen ?? false);
16
+ const open = openProp ?? internalOpen;
17
+ const setOpen = React.useCallback((next) => {
18
+ if (openProp === undefined)
19
+ setInternalOpen(next);
20
+ onOpenChange?.(next);
21
+ }, [openProp, onOpenChange]);
16
22
  const [up, setUp] = React.useState(false);
17
23
  const [pos, setPos] = React.useState({});
18
24
  const rootRef = React.useRef(null);
19
25
  const triggerRef = React.useRef(null);
20
26
  const contentRef = React.useRef(null);
21
- const typeahead = React.useRef("");
22
- const typeaheadTimer = React.useRef(undefined);
23
27
  // Position the (fixed) menu against the trigger so it escapes any overflow
24
- // clip; flip up / right-align when there isn't room.
25
- const openMenu = () => {
28
+ // clip; flip up / right-align when there isn't room. Runs on every open,
29
+ // not just a click, so a controlled consumer gets the same placement.
30
+ const place = () => {
26
31
  const rect = triggerRef.current?.getBoundingClientRect();
27
- if (!rect) {
28
- setOpen(true);
32
+ if (!rect)
29
33
  return;
30
- }
31
34
  const gap = 4;
32
35
  const flipUp = window.innerHeight - rect.bottom < 280;
33
36
  const style = flipUp
@@ -39,18 +42,16 @@ export function Menu({ trigger, children, align = "start", className, "aria-labe
39
42
  style.left = rect.left;
40
43
  setUp(flipUp);
41
44
  setPos(style);
42
- setOpen(true);
43
45
  };
46
+ // biome-ignore lint/correctness/useExhaustiveDependencies: reposition each time it opens
47
+ React.useLayoutEffect(() => {
48
+ if (open)
49
+ place();
50
+ }, [open]);
44
51
  const close = React.useCallback(() => {
45
52
  setOpen(false);
46
53
  triggerRef.current?.focus?.();
47
- }, []);
48
- const items = () => Array.from(contentRef.current?.querySelectorAll(ITEM_SELECTOR) ?? []);
49
- // focus the first item when the menu opens
50
- React.useEffect(() => {
51
- if (open)
52
- requestAnimationFrame(() => contentRef.current?.querySelector(ITEM_SELECTOR)?.focus());
53
- }, [open]);
54
+ }, [setOpen]);
54
55
  // close on outside pointer-down
55
56
  React.useEffect(() => {
56
57
  if (!open)
@@ -61,54 +62,20 @@ export function Menu({ trigger, children, align = "start", className, "aria-labe
61
62
  };
62
63
  document.addEventListener("pointerdown", onDown);
63
64
  return () => document.removeEventListener("pointerdown", onDown);
64
- }, [open]);
65
- const onContentKeyDown = (e) => {
66
- const list = items();
67
- const idx = list.indexOf(document.activeElement);
68
- if (e.key === "ArrowDown") {
69
- e.preventDefault();
70
- list[(idx + 1) % list.length]?.focus();
71
- }
72
- else if (e.key === "ArrowUp") {
73
- e.preventDefault();
74
- list[(idx - 1 + list.length) % list.length]?.focus();
75
- }
76
- else if (e.key === "Home") {
77
- e.preventDefault();
78
- list[0]?.focus();
79
- }
80
- else if (e.key === "End") {
81
- e.preventDefault();
82
- list[list.length - 1]?.focus();
83
- }
84
- else if (e.key === "Escape") {
85
- e.preventDefault();
86
- close();
87
- }
88
- else if (e.key === "Tab") {
89
- setOpen(false);
90
- }
91
- else if (e.key.length === 1 && /\S/.test(e.key)) {
92
- // typeahead: jump to the next item starting with the typed run
93
- typeahead.current += e.key.toLowerCase();
94
- clearTimeout(typeaheadTimer.current);
95
- typeaheadTimer.current = setTimeout(() => {
96
- typeahead.current = "";
97
- }, 500);
98
- const match = list.find((el) => (el.textContent ?? "")
99
- .trim()
100
- .toLowerCase()
101
- .startsWith(typeahead.current));
102
- match?.focus();
103
- }
104
- };
65
+ }, [open, setOpen]);
66
+ const { onKeyDown: onContentKeyDown } = useMenuKeyboard({
67
+ open,
68
+ close,
69
+ dismiss: () => setOpen(false),
70
+ contentRef,
71
+ });
105
72
  const triggerEl = React.cloneElement(trigger, {
106
73
  ref: triggerRef,
107
74
  "aria-haspopup": "menu",
108
75
  "aria-expanded": open,
109
76
  onClick: (e) => {
110
77
  trigger.props.onClick?.(e);
111
- open ? setOpen(false) : openMenu();
78
+ setOpen(!open);
112
79
  },
113
80
  });
114
81
  return (_jsxs("div", { ref: rootRef, className: menuRecipe({ className }), children: [triggerEl, open && (_jsx(MenuContext.Provider, { value: { close }, children: _jsx("div", { ref: contentRef, className: "menu-content", role: "menu", "aria-label": ariaLabel, "data-align": align, "data-up": up ? "" : undefined, style: pos, onKeyDown: onContentKeyDown, children: children }) }))] }));
@@ -1,5 +1,5 @@
1
1
  import { defineRecipe, resolveRecipe } from "../../core/index.js";
2
- import { contract as c } from "../../tokens/index.js";
2
+ import { contract as c, elevation as e } from "../../tokens/index.js";
3
3
  // A dropdown menu — same popover surface Attio uses for its ⋯ / sort / filter
4
4
  // menus (measured from the app's listboxes): radius 12, 4px padding, a layered
5
5
  // soft shadow, over 32px items (radius 8, icon + label + optional shortcut /
@@ -15,7 +15,7 @@ const config = defineRecipe({
15
15
  position: fixed; z-index: 60; box-sizing: border-box; display: flex; flex-direction: column; gap: ${c.space.px};
16
16
  min-width: 200px; max-height: 360px; overflow-y: auto; padding: ${c.space["1"]};
17
17
  border-radius: ${c.radius.xl}; background: ${c.bgPopover};
18
- box-shadow: inset 0 0 0 1px ${c.ringPopover}, 0 0 0 1px ${c.shadowPopover1}, 0 4px 8px -4px ${c.shadowPopover2}, 0 4px 12px -2px ${c.shadowPopover3};
18
+ box-shadow: ${e.floating};
19
19
  transform-origin: top left; opacity: 1; transform: none; transition: opacity .08s ease, transform .08s ease;
20
20
  }
21
21
  & .menu-content[data-align="end"] { transform-origin: top right; }
@@ -24,9 +24,9 @@ const config = defineRecipe({
24
24
  & .menu-content { @starting-style { opacity: 0; transform: scale(0.97) translateY(-1px); } }
25
25
 
26
26
  & .menu-item {
27
- box-sizing: border-box; display: flex; align-items: center; gap: ${c.space["1.5"]}; width: 100%; height: 32px; flex-shrink: 0;
27
+ box-sizing: border-box; display: flex; align-items: center; gap: ${c.space["1.5"]}; width: 100%; height: ${c.size.menuRow}; flex-shrink: 0;
28
28
  margin: 0; padding: 0 ${c.space["2"]}; border: none; background: none; border-radius: ${c.radius.md};
29
- font-family: inherit; font-size: ${c.text.lg}; color: ${c.fgPrimary}; text-align: left; cursor: pointer; white-space: nowrap;
29
+ font-family: inherit; font-size: ${c.text.lg}; color: ${c.fgPrimary}; text-align: start; cursor: pointer; white-space: nowrap;
30
30
  }
31
31
  & .menu-item svg { flex-shrink: 0; color: ${c.fgMuted}; }
32
32
  & .menu-item:focus { outline: none; }
@@ -36,7 +36,7 @@ const config = defineRecipe({
36
36
  & .menu-item--danger svg { color: ${c.bgDanger}; }
37
37
  & .menu-item--danger:hover, & .menu-item--danger:focus-visible, & .menu-item--danger[data-highlighted] { background: color-mix(in srgb, ${c.bgDanger} 10%, transparent); }
38
38
  & .menu-item-label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
39
- & .menu-item-shortcut { flex-shrink: 0; margin-left: ${c.space["3"]}; font-size: ${c.text.sm}; color: ${c.fgMuted}; letter-spacing: 0.02em; }
39
+ & .menu-item-shortcut { flex-shrink: 0; margin-inline-start: ${c.space["3"]}; font-size: ${c.text.sm}; color: ${c.fgMuted}; letter-spacing: 0.02em; }
40
40
  & .menu-item-check { flex-shrink: 0; color: ${c.bgBrandSolid}; }
41
41
  & .menu-item-check--placeholder { width: 15px; }
42
42
 
@@ -27,7 +27,7 @@ function Chip({ opt }) {
27
27
  * popover with a search field over rows of "[chip] … [checkbox]" that toggle on
28
28
  * click (the menu stays open). Keyboard: ↑/↓ move, Enter toggles, Esc closes.
29
29
  */
30
- export function MultiSelect({ options, value, onValueChange, placeholder = "Select…", searchable = true, searchPlaceholder = "Search…", disabled, className, "aria-label": ariaLabel, }) {
30
+ export function MultiSelect({ options, value: valueProp, defaultValue, onValueChange, placeholder = "Select…", searchable = true, searchPlaceholder = "Search…", disabled, className, "aria-label": ariaLabel, ...rest }) {
31
31
  const [open, setOpen] = React.useState(false);
32
32
  const [up, setUp] = React.useState(false);
33
33
  const [pos, setPos] = React.useState({});
@@ -36,6 +36,8 @@ export function MultiSelect({ options, value, onValueChange, placeholder = "Sele
36
36
  const rootRef = React.useRef(null);
37
37
  const triggerRef = React.useRef(null);
38
38
  const searchRef = React.useRef(null);
39
+ const [internalValue, setInternalValue] = React.useState(defaultValue ?? []);
40
+ const value = valueProp ?? internalValue;
39
41
  const selectedSet = React.useMemo(() => new Set(value), [value]);
40
42
  const selectedOptions = options.filter((o) => selectedSet.has(o.value));
41
43
  const q = query.trim().toLowerCase();
@@ -68,7 +70,12 @@ export function MultiSelect({ options, value, onValueChange, placeholder = "Sele
68
70
  triggerRef.current?.focus({ preventScroll: true });
69
71
  };
70
72
  const toggle = (v) => {
71
- onValueChange(selectedSet.has(v) ? value.filter((x) => x !== v) : [...value, v]);
73
+ const next = selectedSet.has(v)
74
+ ? value.filter((x) => x !== v)
75
+ : [...value, v];
76
+ if (valueProp === undefined)
77
+ setInternalValue(next);
78
+ onValueChange?.(next);
72
79
  };
73
80
  const onNavKeys = (e) => {
74
81
  if (e.key === "ArrowDown") {
@@ -100,7 +107,7 @@ export function MultiSelect({ options, value, onValueChange, placeholder = "Sele
100
107
  document.addEventListener("pointerdown", onDown);
101
108
  return () => document.removeEventListener("pointerdown", onDown);
102
109
  }, [open]);
103
- return (_jsxs("div", { ref: rootRef, className: multiselectRecipe({ className }), children: [_jsxs("button", { ref: triggerRef, type: "button", "aria-haspopup": "listbox", "aria-expanded": open, "aria-label": ariaLabel, disabled: disabled, "data-open": open ? "" : undefined, className: "multiselect-trigger", onClick: () => (open ? setOpen(false) : openMenu()), onKeyDown: (e) => {
110
+ return (_jsxs("div", { ref: rootRef, className: multiselectRecipe({ className }), ...rest, children: [_jsxs("button", { ref: triggerRef, type: "button", "aria-haspopup": "listbox", "aria-expanded": open, "aria-label": ariaLabel, disabled: disabled, "data-open": open ? "" : undefined, className: "multiselect-trigger", onClick: () => (open ? setOpen(false) : openMenu()), onKeyDown: (e) => {
104
111
  if (open && !searchable)
105
112
  onNavKeys(e);
106
113
  else if (!open && (e.key === "ArrowDown" || e.key === "Enter")) {
@@ -1,5 +1,5 @@
1
1
  import { defineRecipe, resolveRecipe } from "../../core/index.js";
2
- import { contract as c } from "../../tokens/index.js";
2
+ import { contract as c, elevation as e } from "../../tokens/index.js";
3
3
  // A multi-select / tag editor — measured from Attio's cell tag picker: an
4
4
  // outlined trigger showing the selected values as coloured chips, opening a
5
5
  // popover with a search field over rows of "[coloured chip] … [checkbox]" that
@@ -12,10 +12,10 @@ const config = defineRecipe({
12
12
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
13
13
 
14
14
  & .multiselect-trigger {
15
- box-sizing: border-box; display: flex; align-items: center; gap: ${c.space["1"]}; width: 100%; min-width: 0; min-height: 32px;
15
+ box-sizing: border-box; display: flex; align-items: center; gap: ${c.space["1"]}; width: 100%; min-width: 0; min-height: ${c.size.menuRow};
16
16
  margin: 0; padding: ${c.space["0.5"]} ${c.space["1.5"]} ${c.space["0.5"]} ${c.space["2"]};
17
17
  border: none; border-radius: ${c.radius.md}; background: transparent; box-shadow: inset 0 0 0 1px color-mix(in srgb, ${c.fgPrimary} 7%, transparent);
18
- font-family: inherit; font-size: ${c.text.lg}; color: ${c.fgPrimary}; cursor: pointer; text-align: left;
18
+ font-family: inherit; font-size: ${c.text.lg}; color: ${c.fgPrimary}; cursor: pointer; text-align: start;
19
19
  transition: background-color .12s ease, box-shadow .12s ease;
20
20
  }
21
21
  & .multiselect-trigger:hover { background: ${c.bgRaised}; }
@@ -30,7 +30,7 @@ const config = defineRecipe({
30
30
  position: fixed; z-index: 60; box-sizing: border-box; display: flex; flex-direction: column; gap: ${c.space.px};
31
31
  max-height: 300px; overflow-y: auto; padding: ${c.space["1"]};
32
32
  border-radius: ${c.radius.xl}; background: ${c.bgPopover};
33
- box-shadow: inset 0 0 0 1px ${c.ringPopover}, 0 0 0 1px ${c.shadowPopover1}, 0 4px 8px -4px ${c.shadowPopover2}, 0 4px 12px -2px ${c.shadowPopover3};
33
+ box-shadow: ${e.floating};
34
34
  transform-origin: top left; opacity: 1; transform: none; transition: opacity .08s ease, transform .08s ease;
35
35
  }
36
36
  & .multiselect-listbox[data-up] { transform-origin: bottom left; }
@@ -40,16 +40,16 @@ const config = defineRecipe({
40
40
  & .multiselect-search input { flex: 1; min-width: 0; border: none; outline: none; background: none; font-family: inherit; font-size: ${c.text.lg}; color: ${c.fgPrimary}; }
41
41
  & .multiselect-search input::placeholder { color: ${c.fgMuted}; }
42
42
  & .multiselect-option {
43
- box-sizing: border-box; display: flex; align-items: center; gap: ${c.space["2"]}; height: 32px; flex-shrink: 0;
44
- padding: 0 ${c.space["2"]}; margin: 0; border: none; background: none; border-radius: ${c.radius.md}; cursor: pointer; text-align: left;
43
+ box-sizing: border-box; display: flex; align-items: center; gap: ${c.space["2"]}; height: ${c.size.menuRow}; flex-shrink: 0;
44
+ padding: 0 ${c.space["2"]}; margin: 0; border: none; background: none; border-radius: ${c.radius.md}; font-family: inherit; cursor: pointer; text-align: start;
45
45
  }
46
46
  & .multiselect-option[data-highlighted] { background: ${c.bgRaised}; }
47
47
  & .multiselect-option-chip { flex: 0 1 auto; min-width: 0; overflow: hidden; }
48
- & .multiselect-check { flex-shrink: 0; margin-left: auto; display: inline-flex; align-items: center; justify-content: center; width: 16px; height: 16px; border-radius: ${c.radius.sm}; box-shadow: inset 0 0 0 1.5px ${c.borderDefault}; color: transparent; }
48
+ & .multiselect-check { flex-shrink: 0; margin-inline-start: auto; display: inline-flex; align-items: center; justify-content: center; width: 16px; height: 16px; border-radius: ${c.radius.sm}; box-shadow: inset 0 0 0 1.5px ${c.borderDefault}; color: transparent; }
49
49
  & .multiselect-option[aria-selected="true"] .multiselect-check { background: ${c.bgBrandSolid}; box-shadow: none; color: #fff; }
50
50
  & .multiselect-empty { padding: ${c.space["3"]} ${c.space["2"]}; text-align: center; font-size: ${c.text.md}; color: ${c.fgMuted}; }
51
51
 
52
- & .recordstable-tag { display: inline-flex; align-items: center; height: 22px; padding: 0 ${c.space["1"]}; border-radius: 7px; font-size: ${c.text.lg}; line-height: 20px; font-weight: ${c.weight.medium}; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; background: color-mix(in srgb, ${c.fgPrimary} 6%, transparent); color: color-mix(in srgb, ${c.fgPrimary} 82%, transparent); }
52
+ & .recordstable-tag { display: inline-flex; align-items: center; height: ${c.size.chip}; padding: 0 ${c.space["1"]}; border-radius: ${c.radius.chip}; font-size: ${c.text.lg}; line-height: 20px; font-weight: ${c.weight.medium}; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; background: color-mix(in srgb, ${c.fgPrimary} 6%, transparent); color: color-mix(in srgb, ${c.fgPrimary} 82%, transparent); }
53
53
  & .recordstable-tag[data-tone="brand"] { background: color-mix(in srgb, ${c.bgBrandSolid} 14%, transparent); color: color-mix(in srgb, ${c.bgBrandSolid} 82%, ${c.fgPrimary}); }
54
54
  & .recordstable-tag[data-tone="success"] { background: color-mix(in srgb, ${c.bgSuccess} 16%, transparent); color: color-mix(in srgb, ${c.bgSuccess} 78%, ${c.fgPrimary}); }
55
55
  & .recordstable-tag[data-tone="warning"] { background: color-mix(in srgb, ${c.bgWarning} 18%, transparent); color: color-mix(in srgb, ${c.bgWarning} 82%, ${c.fgPrimary}); }
@@ -6,8 +6,8 @@ import { popoverRecipe } from "./popover.recipe.js";
6
6
  * content. Opens below the trigger (flipping up when there's no room),
7
7
  * closes on outside pointer-down and Escape. Controlled or self-managed.
8
8
  */
9
- export function Popover({ trigger, children, align = "start", open: openProp, onOpenChange, "aria-label": ariaLabel, className, }) {
10
- const [internalOpen, setInternalOpen] = React.useState(false);
9
+ export function Popover({ trigger, children, align = "start", open: openProp, defaultOpen, onOpenChange, "aria-label": ariaLabel, className, }) {
10
+ const [internalOpen, setInternalOpen] = React.useState(defaultOpen ?? false);
11
11
  const open = openProp ?? internalOpen;
12
12
  const rootRef = React.useRef(null);
13
13
  const triggerRef = React.useRef(null);
@@ -1,5 +1,5 @@
1
1
  import { defineRecipe, resolveRecipe } from "../../core/index.js";
2
- import { contract as c } from "../../tokens/index.js";
2
+ import { contract as c, elevation as e } from "../../tokens/index.js";
3
3
  // A generic anchored popover — the same measured surface as Menu / Select
4
4
  // (radius 12, 4px padding, layered soft shadow, inset border), but holding
5
5
  // arbitrary content. Rendered inside a display:contents root and lifted out of
@@ -7,7 +7,7 @@ import { contract as c } from "../../tokens/index.js";
7
7
  const config = defineRecipe({
8
8
  name: "popover",
9
9
  base: `display: contents; font-family: ${c.font.sans};
10
- & .popover-content { position: fixed; z-index: 60; box-sizing: border-box; min-width: 200px; max-width: min(360px, 92vw); padding: ${c.space["1"]}; border-radius: ${c.radius.xl}; background: ${c.bgPopover}; color: ${c.fgPrimary}; box-shadow: inset 0 0 0 1px ${c.ringPopover}, 0 0 0 1px ${c.shadowPopover1}, 0 4px 8px -4px ${c.shadowPopover2}, 0 4px 12px -2px ${c.shadowPopover3}; opacity: 1; transform: none; transition: opacity 0.08s ease, transform 0.08s ease; transform-origin: top left; @starting-style { opacity: 0; transform: scale(0.97) translateY(-1px); } }
10
+ & .popover-content { position: fixed; z-index: 60; box-sizing: border-box; min-width: 200px; max-width: min(360px, 92vw); padding: ${c.space["1"]}; border-radius: ${c.radius.xl}; background: ${c.bgPopover}; color: ${c.fgPrimary}; box-shadow: ${e.floating}; opacity: 1; transform: none; transition: opacity 0.08s ease, transform 0.08s ease; transform-origin: top left; @starting-style { opacity: 0; transform: scale(0.97) translateY(-1px); } }
11
11
  & .popover-content[data-align="end"] { transform-origin: top right; }
12
12
  & .popover-content[data-up] { transform-origin: bottom left; }`,
13
13
  variants: {},
@@ -5,7 +5,7 @@ import { progressRecipe } from "./progress.recipe.js";
5
5
  * `segments` is set (the "Getting started 3/6" pattern). Reports its state via
6
6
  * `role="progressbar"` and the ARIA value attributes.
7
7
  */
8
- export function Progress({ value, max = 100, segments, "aria-label": ariaLabel, className, }) {
8
+ export function Progress({ value, max = 100, segments, "aria-label": ariaLabel, className, ...rest }) {
9
9
  const pct = Math.max(0, Math.min(100, (value / max) * 100));
10
10
  const aria = {
11
11
  role: "progressbar",
@@ -16,8 +16,8 @@ export function Progress({ value, max = 100, segments, "aria-label": ariaLabel,
16
16
  };
17
17
  if (segments && segments > 0) {
18
18
  const filled = Math.round((pct / 100) * segments);
19
- return (_jsx("div", { ...aria, className: progressRecipe({ className }), "data-segmented": "", children: Array.from({ length: segments }, (_, i) => (_jsx("span", { className: "progress-seg", "data-filled": i < filled ? "" : undefined }, i))) }));
19
+ return (_jsx("div", { ...aria, className: progressRecipe({ className }), ...rest, "data-segmented": "", children: Array.from({ length: segments }, (_, i) => (_jsx("span", { className: "progress-seg", "data-filled": i < filled ? "" : undefined }, i))) }));
20
20
  }
21
- return (_jsx("div", { ...aria, className: progressRecipe({ className }), children: _jsx("span", { className: "progress-fill", style: { width: `${pct}%` } }) }));
21
+ return (_jsx("div", { ...aria, className: progressRecipe({ className }), ...rest, children: _jsx("span", { className: "progress-fill", style: { width: `${pct}%` } }) }));
22
22
  }
23
23
  Progress.displayName = "Progress";