@youcan/celeste 0.21.2 → 0.22.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 (538) hide show
  1. package/ai/README.md +1 -1
  2. package/ai/component-registry.json +2 -2
  3. package/ai/icons.json +2 -2
  4. package/ai/tokens.json +2 -2
  5. package/dist/celeste.css +3057 -3057
  6. package/dist/cjs/chunks/alert.cjs +4 -2
  7. package/dist/cjs/chunks/badge.cjs +4 -2
  8. package/dist/cjs/chunks/bar-chart.cjs +17 -10016
  9. package/dist/cjs/chunks/button.cjs +6 -4
  10. package/dist/cjs/chunks/calendar.cjs +20 -796
  11. package/dist/cjs/chunks/chart-card.cjs +4 -2
  12. package/dist/cjs/chunks/chart-legend.cjs +4 -2
  13. package/dist/cjs/chunks/chart-plot.cjs +4 -2
  14. package/dist/cjs/chunks/checkbox-card.cjs +11 -10
  15. package/dist/cjs/chunks/checkbox-label.cjs +12 -11
  16. package/dist/cjs/chunks/checkbox.cjs +7 -227
  17. package/dist/cjs/chunks/collapsible-content.cjs +5 -105
  18. package/dist/cjs/chunks/collapsible-trigger.cjs +2 -50
  19. package/dist/cjs/chunks/collapsible.cjs +3 -4
  20. package/dist/cjs/chunks/color-picker.cjs +21 -19
  21. package/dist/cjs/chunks/color-swatch.cjs +5 -3
  22. package/dist/cjs/chunks/combobox-anchor.cjs +6 -44
  23. package/dist/cjs/chunks/combobox-empty.cjs +5 -30
  24. package/dist/cjs/chunks/combobox-group.cjs +6 -5
  25. package/dist/cjs/chunks/combobox-input.cjs +6 -4
  26. package/dist/cjs/chunks/combobox-item.cjs +10 -66
  27. package/dist/cjs/chunks/combobox-list.cjs +8 -95
  28. package/dist/cjs/chunks/combobox-root.cjs +4 -6
  29. package/dist/cjs/chunks/combobox-separator.cjs +5 -3
  30. package/dist/cjs/chunks/combobox-trigger.cjs +7 -64
  31. package/dist/cjs/chunks/combobox.cjs +5 -5
  32. package/dist/cjs/chunks/compact-button.cjs +6 -4
  33. package/dist/cjs/chunks/components.cjs +55 -54
  34. package/dist/cjs/chunks/content-divider.cjs +6 -88
  35. package/dist/cjs/chunks/counter-input.cjs +10 -939
  36. package/dist/cjs/chunks/date-picker.cjs +5 -3
  37. package/dist/cjs/chunks/dialog-body.cjs +4 -2
  38. package/dist/cjs/chunks/dialog-content.cjs +1 -1
  39. package/dist/cjs/chunks/dialog-description.cjs +5 -4
  40. package/dist/cjs/chunks/dialog-footer.cjs +4 -2
  41. package/dist/cjs/chunks/dialog-title.cjs +5 -4
  42. package/dist/cjs/chunks/dialog-trigger.cjs +1 -1
  43. package/dist/cjs/chunks/dialog.cjs +3 -3
  44. package/dist/cjs/chunks/digit-input-group.cjs +8 -7
  45. package/dist/cjs/chunks/digit-input-slot.cjs +8 -265
  46. package/dist/cjs/chunks/digit-input.cjs +9 -8
  47. package/dist/cjs/chunks/drawer-body.cjs +7 -38
  48. package/dist/cjs/chunks/drawer-close.cjs +2 -2
  49. package/dist/cjs/chunks/drawer-content.cjs +9 -1148
  50. package/dist/cjs/chunks/drawer-description.cjs +7 -5
  51. package/dist/cjs/chunks/drawer-footer.cjs +4 -2
  52. package/dist/cjs/chunks/drawer-header.cjs +6 -4
  53. package/dist/cjs/chunks/drawer-title.cjs +7 -5
  54. package/dist/cjs/chunks/drawer-trigger.cjs +2 -50
  55. package/dist/cjs/chunks/drawer.cjs +4 -5
  56. package/dist/cjs/chunks/dropdown-menu-content.cjs +8 -535
  57. package/dist/cjs/chunks/dropdown-menu-group.cjs +2 -28
  58. package/dist/cjs/chunks/dropdown-menu-item.cjs +6 -124
  59. package/dist/cjs/chunks/dropdown-menu-label.cjs +6 -58
  60. package/dist/cjs/chunks/dropdown-menu-separator.cjs +5 -56
  61. package/dist/cjs/chunks/dropdown-menu-sub-content.cjs +7 -287
  62. package/dist/cjs/chunks/dropdown-menu-sub-trigger.cjs +6 -191
  63. package/dist/cjs/chunks/dropdown-menu-sub.cjs +3 -39
  64. package/dist/cjs/chunks/dropdown-menu-trigger.cjs +3 -89
  65. package/dist/cjs/chunks/dropdown-menu.cjs +8 -8
  66. package/dist/cjs/chunks/extra-settings.cjs +3 -3
  67. package/dist/cjs/chunks/fancy-button.cjs +6 -4
  68. package/dist/cjs/chunks/file-upload-area.cjs +6 -4
  69. package/dist/cjs/chunks/gradient-picker.cjs +8 -6
  70. package/dist/cjs/chunks/hint-text.cjs +4 -2
  71. package/dist/cjs/chunks/{label2.cjs → label.cjs} +7 -6
  72. package/dist/cjs/chunks/link-bubble.cjs +3 -3
  73. package/dist/cjs/chunks/link-button.cjs +6 -4
  74. package/dist/cjs/chunks/mochi.cjs +4 -2
  75. package/dist/cjs/chunks/modal-body.cjs +4 -2
  76. package/dist/cjs/chunks/modal-close.cjs +2 -2
  77. package/dist/cjs/chunks/modal-content.cjs +9 -9
  78. package/dist/cjs/chunks/modal-footer.cjs +4 -2
  79. package/dist/cjs/chunks/modal-header.cjs +8 -8
  80. package/dist/cjs/chunks/modal-trigger.cjs +2 -2
  81. package/dist/cjs/chunks/modal.cjs +3 -4
  82. package/dist/cjs/chunks/pagination-content.cjs +5 -87
  83. package/dist/cjs/chunks/pagination-ellipsis.cjs +6 -32
  84. package/dist/cjs/chunks/pagination-first.cjs +7 -42
  85. package/dist/cjs/chunks/pagination-item.cjs +6 -54
  86. package/dist/cjs/chunks/pagination-last.cjs +7 -42
  87. package/dist/cjs/chunks/pagination-next.cjs +7 -42
  88. package/dist/cjs/chunks/pagination-previous.cjs +7 -42
  89. package/dist/cjs/chunks/pagination.cjs +7 -8
  90. package/dist/cjs/chunks/popover-content.cjs +10 -705
  91. package/dist/cjs/chunks/popover-trigger.cjs +2 -61
  92. package/dist/cjs/chunks/popover.cjs +3 -4
  93. package/dist/cjs/chunks/progress-bar.cjs +6 -4
  94. package/dist/cjs/chunks/progress-circle.cjs +7 -5
  95. package/dist/cjs/chunks/radio-group-card.cjs +11 -10
  96. package/dist/cjs/chunks/radio-group-item.cjs +7 -302
  97. package/dist/cjs/chunks/radio-group-label.cjs +12 -11
  98. package/dist/cjs/chunks/radio-group.cjs +6 -5
  99. package/dist/cjs/chunks/range-calendar.cjs +21 -1031
  100. package/dist/cjs/chunks/range-picker.cjs +9 -7
  101. package/dist/cjs/chunks/rich-editor.cjs +21 -5863
  102. package/dist/cjs/chunks/rolldown-runtime.cjs +0 -14
  103. package/dist/cjs/chunks/scroll-area.cjs +9 -142
  104. package/dist/cjs/chunks/scroll-bar.cjs +6 -901
  105. package/dist/cjs/chunks/segmented-control-item.cjs +6 -163
  106. package/dist/cjs/chunks/segmented-control.cjs +7 -6
  107. package/dist/cjs/chunks/select-content.cjs +9 -311
  108. package/dist/cjs/chunks/select-group.cjs +2 -2
  109. package/dist/cjs/chunks/select-icon.cjs +4 -2
  110. package/dist/cjs/chunks/select-item.cjs +7 -227
  111. package/dist/cjs/chunks/select-label.cjs +5 -34
  112. package/dist/cjs/chunks/select-separator.cjs +5 -27
  113. package/dist/cjs/chunks/select-trigger.cjs +6 -163
  114. package/dist/cjs/chunks/select-value.cjs +5 -64
  115. package/dist/cjs/chunks/select.cjs +8 -8
  116. package/dist/cjs/chunks/sheet-close.cjs +5 -3
  117. package/dist/cjs/chunks/sheet-content.cjs +10 -10
  118. package/dist/cjs/chunks/sheet-description.cjs +7 -5
  119. package/dist/cjs/chunks/sheet-footer.cjs +4 -2
  120. package/dist/cjs/chunks/sheet-header.cjs +4 -2
  121. package/dist/cjs/chunks/sheet-title.cjs +7 -5
  122. package/dist/cjs/chunks/sheet-trigger.cjs +2 -2
  123. package/dist/cjs/chunks/sheet.cjs +3 -4
  124. package/dist/cjs/chunks/sidebar-content.cjs +4 -2
  125. package/dist/cjs/chunks/sidebar-element.cjs +6 -4
  126. package/dist/cjs/chunks/sidebar-footer.cjs +4 -2
  127. package/dist/cjs/chunks/sidebar-group-content.cjs +4 -2
  128. package/dist/cjs/chunks/sidebar-group-label.cjs +6 -4
  129. package/dist/cjs/chunks/sidebar-group.cjs +4 -2
  130. package/dist/cjs/chunks/sidebar-header.cjs +4 -2
  131. package/dist/cjs/chunks/sidebar-menu-action.cjs +6 -4
  132. package/dist/cjs/chunks/sidebar-menu-badge.cjs +4 -2
  133. package/dist/cjs/chunks/sidebar-menu-button.cjs +8 -6
  134. package/dist/cjs/chunks/sidebar-menu-item.cjs +4 -2
  135. package/dist/cjs/chunks/sidebar-menu-sub-button.cjs +6 -4
  136. package/dist/cjs/chunks/sidebar-menu-sub-item.cjs +4 -2
  137. package/dist/cjs/chunks/sidebar-menu-sub.cjs +4 -2
  138. package/dist/cjs/chunks/sidebar-menu.cjs +4 -2
  139. package/dist/cjs/chunks/sidebar-provider.cjs +9 -7
  140. package/dist/cjs/chunks/sidebar-trigger.cjs +4 -2
  141. package/dist/cjs/chunks/sidebar.cjs +4 -2
  142. package/dist/cjs/chunks/slider.cjs +10 -757
  143. package/dist/cjs/chunks/social-button.cjs +6 -4
  144. package/dist/cjs/chunks/status-badge.cjs +4 -2
  145. package/dist/cjs/chunks/switch.cjs +7 -185
  146. package/dist/cjs/chunks/tab-menu-content.cjs +5 -81
  147. package/dist/cjs/chunks/tab-menu-item.cjs +6 -88
  148. package/dist/cjs/chunks/tab-menu-list.cjs +6 -61
  149. package/dist/cjs/chunks/tab-menu.cjs +3 -4
  150. package/dist/cjs/chunks/table-body.cjs +4 -2
  151. package/dist/cjs/chunks/table-caption.cjs +4 -2
  152. package/dist/cjs/chunks/table-cell.cjs +4 -2
  153. package/dist/cjs/chunks/table-footer.cjs +4 -2
  154. package/dist/cjs/chunks/table-head.cjs +4 -2
  155. package/dist/cjs/chunks/table-header.cjs +4 -2
  156. package/dist/cjs/chunks/table-row.cjs +4 -2
  157. package/dist/cjs/chunks/table.cjs +4 -2
  158. package/dist/cjs/chunks/table2.cjs +4 -2
  159. package/dist/cjs/chunks/tag.cjs +6 -4
  160. package/dist/cjs/chunks/text-input-affix.cjs +4 -2
  161. package/dist/cjs/chunks/text-input-button.cjs +4 -2
  162. package/dist/cjs/chunks/text-input.cjs +11 -9
  163. package/dist/cjs/chunks/textarea.cjs +4 -2
  164. package/dist/cjs/chunks/tooltip-content.cjs +9 -599
  165. package/dist/cjs/chunks/tooltip-provider.cjs +2 -2
  166. package/dist/cjs/chunks/tooltip-root.cjs +3 -4
  167. package/dist/cjs/chunks/tooltip-trigger.cjs +3 -107
  168. package/dist/cjs/chunks/tooltip.cjs +4 -4
  169. package/dist/cjs/command-group.cjs +3 -4
  170. package/dist/cjs/command-input.cjs +7 -6
  171. package/dist/cjs/command-item.cjs +3 -4
  172. package/dist/cjs/command-list.cjs +3 -4
  173. package/dist/cjs/command-root.cjs +4 -6
  174. package/dist/cjs/command-separator.cjs +5 -3
  175. package/dist/cjs/context.cjs +1 -1
  176. package/dist/cjs/index.cjs +53 -53
  177. package/dist/cjs/label.cjs +1 -1
  178. package/dist/cjs/use-chart-motion.cjs +2 -2
  179. package/dist/cjs/use-color-model.cjs +6 -4
  180. package/dist/cjs/use-sidebar.cjs +2 -2
  181. package/dist/cjs/use-tab-observer.cjs +4 -4
  182. package/dist/es/chunks/alert.js +2 -2
  183. package/dist/es/chunks/badge.js +2 -2
  184. package/dist/es/chunks/bar-chart.js +11 -10007
  185. package/dist/es/chunks/button.js +3 -3
  186. package/dist/es/chunks/calendar.js +20 -798
  187. package/dist/es/chunks/chart-card.js +2 -2
  188. package/dist/es/chunks/chart-legend.js +2 -2
  189. package/dist/es/chunks/chart-plot.js +2 -2
  190. package/dist/es/chunks/checkbox-card.js +4 -5
  191. package/dist/es/chunks/checkbox-label.js +4 -5
  192. package/dist/es/chunks/checkbox.js +5 -227
  193. package/dist/es/chunks/collapsible-content.js +4 -106
  194. package/dist/es/chunks/collapsible-trigger.js +2 -50
  195. package/dist/es/chunks/collapsible.js +2 -3
  196. package/dist/es/chunks/color-picker.js +10 -10
  197. package/dist/es/chunks/color-swatch.js +1 -1
  198. package/dist/es/chunks/combobox-anchor.js +4 -44
  199. package/dist/es/chunks/combobox-empty.js +4 -30
  200. package/dist/es/chunks/combobox-group.js +4 -5
  201. package/dist/es/chunks/combobox-input.js +4 -4
  202. package/dist/es/chunks/combobox-item.js +8 -66
  203. package/dist/es/chunks/combobox-list.js +6 -94
  204. package/dist/es/chunks/combobox-root.js +3 -5
  205. package/dist/es/chunks/combobox-separator.js +3 -3
  206. package/dist/es/chunks/combobox-trigger.js +5 -63
  207. package/dist/es/chunks/combobox.js +4 -4
  208. package/dist/es/chunks/compact-button.js +3 -3
  209. package/dist/es/chunks/components.js +65 -55
  210. package/dist/es/chunks/content-divider.js +5 -89
  211. package/dist/es/chunks/counter-input.js +8 -939
  212. package/dist/es/chunks/date-picker.js +3 -3
  213. package/dist/es/chunks/dialog-body.js +2 -2
  214. package/dist/es/chunks/dialog-content.js +1 -1
  215. package/dist/es/chunks/dialog-description.js +3 -4
  216. package/dist/es/chunks/dialog-footer.js +2 -2
  217. package/dist/es/chunks/dialog-title.js +3 -4
  218. package/dist/es/chunks/dialog-trigger.js +1 -1
  219. package/dist/es/chunks/dialog.js +1 -1
  220. package/dist/es/chunks/digit-input-group.js +4 -5
  221. package/dist/es/chunks/digit-input-slot.js +5 -263
  222. package/dist/es/chunks/digit-input.js +5 -6
  223. package/dist/es/chunks/drawer-body.js +4 -36
  224. package/dist/es/chunks/drawer-close.js +2 -2
  225. package/dist/es/chunks/drawer-content.js +7 -1147
  226. package/dist/es/chunks/drawer-description.js +4 -4
  227. package/dist/es/chunks/drawer-footer.js +2 -2
  228. package/dist/es/chunks/drawer-header.js +4 -4
  229. package/dist/es/chunks/drawer-title.js +4 -4
  230. package/dist/es/chunks/drawer-trigger.js +3 -51
  231. package/dist/es/chunks/drawer.js +3 -4
  232. package/dist/es/chunks/dropdown-menu-content.js +6 -534
  233. package/dist/es/chunks/dropdown-menu-group.js +3 -28
  234. package/dist/es/chunks/dropdown-menu-item.js +4 -124
  235. package/dist/es/chunks/dropdown-menu-label.js +4 -57
  236. package/dist/es/chunks/dropdown-menu-separator.js +4 -56
  237. package/dist/es/chunks/dropdown-menu-sub-content.js +5 -286
  238. package/dist/es/chunks/dropdown-menu-sub-trigger.js +4 -191
  239. package/dist/es/chunks/dropdown-menu-sub.js +3 -39
  240. package/dist/es/chunks/dropdown-menu-trigger.js +3 -88
  241. package/dist/es/chunks/dropdown-menu.js +5 -7
  242. package/dist/es/chunks/extra-settings.js +3 -3
  243. package/dist/es/chunks/fancy-button.js +3 -3
  244. package/dist/es/chunks/file-upload-area.js +3 -3
  245. package/dist/es/chunks/gradient-picker.js +3 -3
  246. package/dist/es/chunks/hint-text.js +2 -2
  247. package/dist/es/chunks/{label2.js → label.js} +4 -5
  248. package/dist/es/chunks/link-bubble.js +3 -3
  249. package/dist/es/chunks/link-button.js +3 -3
  250. package/dist/es/chunks/mochi.js +2 -2
  251. package/dist/es/chunks/modal-body.js +2 -2
  252. package/dist/es/chunks/modal-close.js +2 -2
  253. package/dist/es/chunks/modal-content.js +5 -7
  254. package/dist/es/chunks/modal-footer.js +2 -2
  255. package/dist/es/chunks/modal-header.js +6 -8
  256. package/dist/es/chunks/modal-trigger.js +2 -2
  257. package/dist/es/chunks/modal.js +2 -3
  258. package/dist/es/chunks/pagination-content.js +5 -86
  259. package/dist/es/chunks/pagination-ellipsis.js +5 -30
  260. package/dist/es/chunks/pagination-first.js +5 -40
  261. package/dist/es/chunks/pagination-item.js +5 -53
  262. package/dist/es/chunks/pagination-last.js +5 -40
  263. package/dist/es/chunks/pagination-next.js +5 -40
  264. package/dist/es/chunks/pagination-previous.js +5 -40
  265. package/dist/es/chunks/pagination.js +4 -5
  266. package/dist/es/chunks/popover-content.js +8 -705
  267. package/dist/es/chunks/popover-trigger.js +3 -61
  268. package/dist/es/chunks/popover.js +2 -3
  269. package/dist/es/chunks/progress-bar.js +4 -4
  270. package/dist/es/chunks/progress-circle.js +5 -5
  271. package/dist/es/chunks/radio-group-card.js +4 -5
  272. package/dist/es/chunks/radio-group-item.js +5 -302
  273. package/dist/es/chunks/radio-group-label.js +4 -5
  274. package/dist/es/chunks/radio-group.js +3 -4
  275. package/dist/es/chunks/range-calendar.js +21 -1033
  276. package/dist/es/chunks/range-picker.js +7 -7
  277. package/dist/es/chunks/rich-editor.js +13 -5859
  278. package/dist/es/chunks/scroll-area.js +8 -142
  279. package/dist/es/chunks/scroll-bar.js +6 -890
  280. package/dist/es/chunks/segmented-control-item.js +5 -163
  281. package/dist/es/chunks/segmented-control.js +4 -5
  282. package/dist/es/chunks/select-content.js +7 -310
  283. package/dist/es/chunks/select-group.js +2 -2
  284. package/dist/es/chunks/select-icon.js +2 -2
  285. package/dist/es/chunks/select-item.js +6 -227
  286. package/dist/es/chunks/select-label.js +3 -33
  287. package/dist/es/chunks/select-separator.js +4 -27
  288. package/dist/es/chunks/select-trigger.js +5 -163
  289. package/dist/es/chunks/select-value.js +4 -64
  290. package/dist/es/chunks/select.js +5 -7
  291. package/dist/es/chunks/sheet-close.js +3 -3
  292. package/dist/es/chunks/sheet-content.js +6 -8
  293. package/dist/es/chunks/sheet-description.js +4 -4
  294. package/dist/es/chunks/sheet-footer.js +2 -2
  295. package/dist/es/chunks/sheet-header.js +2 -2
  296. package/dist/es/chunks/sheet-title.js +4 -4
  297. package/dist/es/chunks/sheet-trigger.js +2 -2
  298. package/dist/es/chunks/sheet.js +2 -3
  299. package/dist/es/chunks/sidebar-content.js +2 -2
  300. package/dist/es/chunks/sidebar-element.js +3 -3
  301. package/dist/es/chunks/sidebar-footer.js +2 -2
  302. package/dist/es/chunks/sidebar-group-content.js +2 -2
  303. package/dist/es/chunks/sidebar-group-label.js +3 -3
  304. package/dist/es/chunks/sidebar-group.js +2 -2
  305. package/dist/es/chunks/sidebar-header.js +2 -2
  306. package/dist/es/chunks/sidebar-menu-action.js +3 -3
  307. package/dist/es/chunks/sidebar-menu-badge.js +2 -2
  308. package/dist/es/chunks/sidebar-menu-button.js +4 -4
  309. package/dist/es/chunks/sidebar-menu-item.js +2 -2
  310. package/dist/es/chunks/sidebar-menu-sub-button.js +3 -3
  311. package/dist/es/chunks/sidebar-menu-sub-item.js +2 -2
  312. package/dist/es/chunks/sidebar-menu-sub.js +2 -2
  313. package/dist/es/chunks/sidebar-menu.js +2 -2
  314. package/dist/es/chunks/sidebar-provider.js +3 -3
  315. package/dist/es/chunks/sidebar-trigger.js +2 -2
  316. package/dist/es/chunks/sidebar.js +2 -2
  317. package/dist/es/chunks/slider.js +10 -759
  318. package/dist/es/chunks/social-button.js +3 -3
  319. package/dist/es/chunks/status-badge.js +2 -2
  320. package/dist/es/chunks/switch.js +5 -185
  321. package/dist/es/chunks/tab-menu-content.js +4 -81
  322. package/dist/es/chunks/tab-menu-item.js +4 -88
  323. package/dist/es/chunks/tab-menu-list.js +5 -62
  324. package/dist/es/chunks/tab-menu.js +2 -3
  325. package/dist/es/chunks/table-body.js +2 -2
  326. package/dist/es/chunks/table-caption.js +2 -2
  327. package/dist/es/chunks/table-cell.js +2 -2
  328. package/dist/es/chunks/table-footer.js +2 -2
  329. package/dist/es/chunks/table-head.js +2 -2
  330. package/dist/es/chunks/table-header.js +2 -2
  331. package/dist/es/chunks/table-row.js +2 -2
  332. package/dist/es/chunks/table.js +2 -2
  333. package/dist/es/chunks/table2.js +2 -2
  334. package/dist/es/chunks/tag.js +3 -3
  335. package/dist/es/chunks/text-input-affix.js +2 -2
  336. package/dist/es/chunks/text-input-button.js +2 -2
  337. package/dist/es/chunks/text-input.js +3 -3
  338. package/dist/es/chunks/textarea.js +2 -2
  339. package/dist/es/chunks/tooltip-content.js +7 -599
  340. package/dist/es/chunks/tooltip-provider.js +2 -2
  341. package/dist/es/chunks/tooltip-root.js +2 -3
  342. package/dist/es/chunks/tooltip-trigger.js +3 -107
  343. package/dist/es/chunks/tooltip.js +3 -3
  344. package/dist/es/command-group.js +3 -4
  345. package/dist/es/command-input.js +4 -5
  346. package/dist/es/command-item.js +2 -3
  347. package/dist/es/command-list.js +2 -3
  348. package/dist/es/command-root.js +3 -5
  349. package/dist/es/command-separator.js +3 -3
  350. package/dist/es/context.js +1 -1
  351. package/dist/es/index.js +54 -54
  352. package/dist/es/label.js +1 -1
  353. package/dist/es/use-chart-motion.js +1 -1
  354. package/dist/es/use-color-model.js +1 -1
  355. package/dist/es/use-sidebar.js +1 -1
  356. package/dist/es/use-tab-observer.js +1 -1
  357. package/package.json +3 -3
  358. package/dist/cjs/chunks/BubbleSelect.cjs +0 -331
  359. package/dist/cjs/chunks/CollapsibleRoot.cjs +0 -89
  360. package/dist/cjs/chunks/Collection.cjs +0 -84
  361. package/dist/cjs/chunks/ComboboxContent.cjs +0 -446
  362. package/dist/cjs/chunks/ComboboxGroup.cjs +0 -89
  363. package/dist/cjs/chunks/ComboboxInput.cjs +0 -269
  364. package/dist/cjs/chunks/ComboboxItem.cjs +0 -202
  365. package/dist/cjs/chunks/ComboboxLabel.cjs +0 -46
  366. package/dist/cjs/chunks/ComboboxRoot.cjs +0 -753
  367. package/dist/cjs/chunks/ComboboxSeparator.cjs +0 -34
  368. package/dist/cjs/chunks/ConfigProvider.cjs +0 -68
  369. package/dist/cjs/chunks/DialogClose.cjs +0 -40
  370. package/dist/cjs/chunks/DialogDescription.cjs +0 -37
  371. package/dist/cjs/chunks/DialogPortal.cjs +0 -524
  372. package/dist/cjs/chunks/DialogRoot.cjs +0 -80
  373. package/dist/cjs/chunks/DialogTitle.cjs +0 -37
  374. package/dist/cjs/chunks/DialogTrigger.cjs +0 -56
  375. package/dist/cjs/chunks/DismissableLayer.cjs +0 -268
  376. package/dist/cjs/chunks/DrawerClose.cjs +0 -40
  377. package/dist/cjs/chunks/DrawerDescription.cjs +0 -37
  378. package/dist/cjs/chunks/DrawerRoot.cjs +0 -366
  379. package/dist/cjs/chunks/DrawerTitle.cjs +0 -37
  380. package/dist/cjs/chunks/DropdownMenuPortal.cjs +0 -72
  381. package/dist/cjs/chunks/DropdownMenuRoot.cjs +0 -86
  382. package/dist/cjs/chunks/FocusScope.cjs +0 -377
  383. package/dist/cjs/chunks/Label.cjs +0 -41
  384. package/dist/cjs/chunks/MenuAnchor.cjs +0 -36
  385. package/dist/cjs/chunks/MenuContentImpl.cjs +0 -371
  386. package/dist/cjs/chunks/MenuGroup.cjs +0 -43
  387. package/dist/cjs/chunks/MenuItemImpl.cjs +0 -100
  388. package/dist/cjs/chunks/MenuRoot.cjs +0 -108
  389. package/dist/cjs/chunks/MenuSub.cjs +0 -67
  390. package/dist/cjs/chunks/PaginationRoot.cjs +0 -100
  391. package/dist/cjs/chunks/PinInputRoot.cjs +0 -152
  392. package/dist/cjs/chunks/PopoverRoot.cjs +0 -72
  393. package/dist/cjs/chunks/PopperAnchor.cjs +0 -47
  394. package/dist/cjs/chunks/PopperArrow.cjs +0 -151
  395. package/dist/cjs/chunks/PopperContent.cjs +0 -2099
  396. package/dist/cjs/chunks/PopperRoot.cjs +0 -31
  397. package/dist/cjs/chunks/Presence.cjs +0 -195
  398. package/dist/cjs/chunks/Primitive.cjs +0 -79
  399. package/dist/cjs/chunks/ProgressIndicator.cjs +0 -160
  400. package/dist/cjs/chunks/RadioGroupRoot.cjs +0 -142
  401. package/dist/cjs/chunks/RovingFocusGroup.cjs +0 -146
  402. package/dist/cjs/chunks/RovingFocusItem.cjs +0 -113
  403. package/dist/cjs/chunks/SelectGroup.cjs +0 -43
  404. package/dist/cjs/chunks/SelectItemAlignedPosition.cjs +0 -597
  405. package/dist/cjs/chunks/TabsRoot.cjs +0 -113
  406. package/dist/cjs/chunks/Teleport.cjs +0 -50
  407. package/dist/cjs/chunks/ToggleGroupRoot.cjs +0 -187
  408. package/dist/cjs/chunks/TooltipProvider.cjs +0 -86
  409. package/dist/cjs/chunks/TooltipRoot.cjs +0 -145
  410. package/dist/cjs/chunks/VisuallyHidden.cjs +0 -64
  411. package/dist/cjs/chunks/VisuallyHiddenInput.cjs +0 -146
  412. package/dist/cjs/chunks/clamp.cjs +0 -75
  413. package/dist/cjs/chunks/clsx.cjs +0 -21
  414. package/dist/cjs/chunks/createContext.cjs +0 -37
  415. package/dist/cjs/chunks/defu.cjs +0 -34
  416. package/dist/cjs/chunks/dist.cjs +0 -543
  417. package/dist/cjs/chunks/dist2.cjs +0 -538
  418. package/dist/cjs/chunks/dist3.cjs +0 -16177
  419. package/dist/cjs/chunks/getActiveElement.cjs +0 -14
  420. package/dist/cjs/chunks/handleAndDispatchCustomEvent.cjs +0 -18
  421. package/dist/cjs/chunks/isValueEqualOrExist.cjs +0 -24
  422. package/dist/cjs/chunks/menus.cjs +0 -1368
  423. package/dist/cjs/chunks/nullish.cjs +0 -11
  424. package/dist/cjs/chunks/ohash.D__AXeF1.cjs +0 -114
  425. package/dist/cjs/chunks/tinycolor.cjs +0 -904
  426. package/dist/cjs/chunks/useArrowNavigation.cjs +0 -65
  427. package/dist/cjs/chunks/useCalendar.cjs +0 -2533
  428. package/dist/cjs/chunks/useComposing.cjs +0 -45
  429. package/dist/cjs/chunks/useDirection.cjs +0 -19
  430. package/dist/cjs/chunks/useEmitAsProps.cjs +0 -33
  431. package/dist/cjs/chunks/useFocusGuards.cjs +0 -39
  432. package/dist/cjs/chunks/useFormControl.cjs +0 -13
  433. package/dist/cjs/chunks/useForwardExpose.cjs +0 -63
  434. package/dist/cjs/chunks/useForwardProps.cjs +0 -39
  435. package/dist/cjs/chunks/useForwardPropsEmits.cjs +0 -19
  436. package/dist/cjs/chunks/useForwardScopeId.cjs +0 -30
  437. package/dist/cjs/chunks/useHideOthers.cjs +0 -137
  438. package/dist/cjs/chunks/useId.cjs +0 -30
  439. package/dist/cjs/chunks/useKbd.cjs +0 -46
  440. package/dist/cjs/chunks/useLocale.cjs +0 -19
  441. package/dist/cjs/chunks/useNonce.cjs +0 -14
  442. package/dist/cjs/chunks/usePrimitiveElement.cjs +0 -17
  443. package/dist/cjs/chunks/useSize.cjs +0 -54
  444. package/dist/cjs/chunks/useTypeahead.cjs +0 -69
  445. package/dist/cjs/chunks/utils.cjs +0 -117
  446. package/dist/cjs/chunks/utils2.cjs +0 -73
  447. package/dist/cjs/chunks/utils3.cjs +0 -20
  448. package/dist/es/chunks/BubbleSelect.js +0 -290
  449. package/dist/es/chunks/CollapsibleRoot.js +0 -78
  450. package/dist/es/chunks/Collection.js +0 -79
  451. package/dist/es/chunks/ComboboxContent.js +0 -441
  452. package/dist/es/chunks/ComboboxGroup.js +0 -78
  453. package/dist/es/chunks/ComboboxInput.js +0 -264
  454. package/dist/es/chunks/ComboboxItem.js +0 -191
  455. package/dist/es/chunks/ComboboxLabel.js +0 -41
  456. package/dist/es/chunks/ComboboxRoot.js +0 -730
  457. package/dist/es/chunks/ComboboxSeparator.js +0 -29
  458. package/dist/es/chunks/ConfigProvider.js +0 -57
  459. package/dist/es/chunks/DialogClose.js +0 -35
  460. package/dist/es/chunks/DialogDescription.js +0 -32
  461. package/dist/es/chunks/DialogPortal.js +0 -507
  462. package/dist/es/chunks/DialogRoot.js +0 -69
  463. package/dist/es/chunks/DialogTitle.js +0 -32
  464. package/dist/es/chunks/DialogTrigger.js +0 -51
  465. package/dist/es/chunks/DismissableLayer.js +0 -257
  466. package/dist/es/chunks/DrawerClose.js +0 -35
  467. package/dist/es/chunks/DrawerDescription.js +0 -32
  468. package/dist/es/chunks/DrawerRoot.js +0 -325
  469. package/dist/es/chunks/DrawerTitle.js +0 -32
  470. package/dist/es/chunks/DropdownMenuPortal.js +0 -67
  471. package/dist/es/chunks/DropdownMenuRoot.js +0 -75
  472. package/dist/es/chunks/FocusScope.js +0 -360
  473. package/dist/es/chunks/Label.js +0 -36
  474. package/dist/es/chunks/MenuAnchor.js +0 -31
  475. package/dist/es/chunks/MenuContentImpl.js +0 -360
  476. package/dist/es/chunks/MenuGroup.js +0 -32
  477. package/dist/es/chunks/MenuItemImpl.js +0 -95
  478. package/dist/es/chunks/MenuRoot.js +0 -85
  479. package/dist/es/chunks/MenuSub.js +0 -56
  480. package/dist/es/chunks/PaginationRoot.js +0 -89
  481. package/dist/es/chunks/PinInputRoot.js +0 -141
  482. package/dist/es/chunks/PopoverRoot.js +0 -61
  483. package/dist/es/chunks/PopperAnchor.js +0 -42
  484. package/dist/es/chunks/PopperArrow.js +0 -146
  485. package/dist/es/chunks/PopperContent.js +0 -2029
  486. package/dist/es/chunks/PopperRoot.js +0 -20
  487. package/dist/es/chunks/Presence.js +0 -184
  488. package/dist/es/chunks/Primitive.js +0 -62
  489. package/dist/es/chunks/ProgressIndicator.js +0 -149
  490. package/dist/es/chunks/RadioGroupRoot.js +0 -131
  491. package/dist/es/chunks/RovingFocusGroup.js +0 -135
  492. package/dist/es/chunks/RovingFocusItem.js +0 -108
  493. package/dist/es/chunks/SelectGroup.js +0 -32
  494. package/dist/es/chunks/SelectItemAlignedPosition.js +0 -568
  495. package/dist/es/chunks/TabsRoot.js +0 -102
  496. package/dist/es/chunks/Teleport.js +0 -45
  497. package/dist/es/chunks/ToggleGroupRoot.js +0 -176
  498. package/dist/es/chunks/TooltipProvider.js +0 -75
  499. package/dist/es/chunks/TooltipRoot.js +0 -128
  500. package/dist/es/chunks/VisuallyHidden.js +0 -59
  501. package/dist/es/chunks/VisuallyHiddenInput.js +0 -141
  502. package/dist/es/chunks/clamp.js +0 -64
  503. package/dist/es/chunks/clsx.js +0 -16
  504. package/dist/es/chunks/createContext.js +0 -32
  505. package/dist/es/chunks/defu.js +0 -29
  506. package/dist/es/chunks/dist.js +0 -418
  507. package/dist/es/chunks/dist2.js +0 -461
  508. package/dist/es/chunks/dist3.js +0 -15890
  509. package/dist/es/chunks/getActiveElement.js +0 -9
  510. package/dist/es/chunks/handleAndDispatchCustomEvent.js +0 -13
  511. package/dist/es/chunks/isValueEqualOrExist.js +0 -19
  512. package/dist/es/chunks/menus.js +0 -1368
  513. package/dist/es/chunks/nullish.js +0 -6
  514. package/dist/es/chunks/ohash.D__AXeF1.js +0 -109
  515. package/dist/es/chunks/rolldown-runtime.js +0 -34
  516. package/dist/es/chunks/tinycolor.js +0 -899
  517. package/dist/es/chunks/useArrowNavigation.js +0 -60
  518. package/dist/es/chunks/useCalendar.js +0 -2426
  519. package/dist/es/chunks/useComposing.js +0 -40
  520. package/dist/es/chunks/useDirection.js +0 -14
  521. package/dist/es/chunks/useEmitAsProps.js +0 -28
  522. package/dist/es/chunks/useFocusGuards.js +0 -34
  523. package/dist/es/chunks/useFormControl.js +0 -8
  524. package/dist/es/chunks/useForwardExpose.js +0 -58
  525. package/dist/es/chunks/useForwardProps.js +0 -34
  526. package/dist/es/chunks/useForwardPropsEmits.js +0 -14
  527. package/dist/es/chunks/useForwardScopeId.js +0 -25
  528. package/dist/es/chunks/useHideOthers.js +0 -132
  529. package/dist/es/chunks/useId.js +0 -23
  530. package/dist/es/chunks/useKbd.js +0 -41
  531. package/dist/es/chunks/useLocale.js +0 -14
  532. package/dist/es/chunks/useNonce.js +0 -9
  533. package/dist/es/chunks/usePrimitiveElement.js +0 -12
  534. package/dist/es/chunks/useSize.js +0 -49
  535. package/dist/es/chunks/useTypeahead.js +0 -64
  536. package/dist/es/chunks/utils.js +0 -58
  537. package/dist/es/chunks/utils2.js +0 -44
  538. package/dist/es/chunks/utils3.js +0 -9
@@ -1,40 +0,0 @@
1
- import { computed, nextTick, ref } from "vue";
2
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useComposing.js
3
- var imeScriptRE = /[\p{Script=Han}\p{Script=Hiragana}\p{Script=Katakana}\p{Script=Hangul}\p{Script=Bopomofo}]/u;
4
- var androidRE = /android/i;
5
- function isAndroid() {
6
- return typeof navigator !== "undefined" && androidRE.test(navigator.userAgent);
7
- }
8
- function useComposing(onEnd) {
9
- const isComposing = ref(false);
10
- const isImeComposition = ref(true);
11
- const sawImeScript = ref(false);
12
- const shouldDeferInput = computed(() => isComposing.value && isImeComposition.value);
13
- function handleCompositionStart() {
14
- isComposing.value = true;
15
- isImeComposition.value = true;
16
- sawImeScript.value = false;
17
- }
18
- function handleCompositionUpdate(event) {
19
- if (!event.data) return;
20
- if (imeScriptRE.test(event.data)) {
21
- isImeComposition.value = true;
22
- sawImeScript.value = true;
23
- } else if (isAndroid() && !sawImeScript.value) isImeComposition.value = false;
24
- }
25
- function handleCompositionEnd(event) {
26
- nextTick(() => {
27
- isComposing.value = false;
28
- onEnd?.(event);
29
- });
30
- }
31
- return {
32
- isComposing,
33
- shouldDeferInput,
34
- handleCompositionStart,
35
- handleCompositionUpdate,
36
- handleCompositionEnd
37
- };
38
- }
39
- //#endregion
40
- export { useComposing as t };
@@ -1,14 +0,0 @@
1
- import { n as injectConfigProviderContext } from "./ConfigProvider.js";
2
- import { computed, ref } from "vue";
3
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useDirection.js
4
- /**
5
- * The `useDirection` function provides a way to access the current direction in your application.
6
- * @param {Ref<Direction | undefined>} [dir] - An optional ref containing the direction (ltr or rtl).
7
- * @returns computed value that combines with the resolved direction.
8
- */
9
- function useDirection(dir) {
10
- const context = injectConfigProviderContext({ dir: ref("ltr") });
11
- return computed(() => dir?.value || context.dir?.value || "ltr");
12
- }
13
- //#endregion
14
- export { useDirection as t };
@@ -1,28 +0,0 @@
1
- import { camelize, getCurrentInstance, toHandlerKey } from "vue";
2
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useEmitAsProps.js
3
- /**
4
- * The `useEmitAsProps` function is a TypeScript utility that converts emitted events into props for a
5
- * Vue component.
6
- *
7
- * @template Name - The event name string union type.
8
- * @template Fn - The emit function type.
9
- *
10
- * @param emit - The `emit` parameter is a function that is used to emit events from a component. It
11
- *
12
- * takes two parameters: `name` which is the name of the event to be emitted, and `...args` which are
13
- * the arguments to be passed along with the event.
14
- * @returns The function `useEmitAsProps` returns an object that maps event names to functions that
15
- * call the `emit` function with the corresponding event name and arguments.
16
- */
17
- function useEmitAsProps(emit) {
18
- const vm = getCurrentInstance();
19
- const events = vm?.type.emits;
20
- const result = {};
21
- if (!events?.length) console.warn(`No emitted event found. Please check component: ${vm?.type.__name}`);
22
- events?.forEach((ev) => {
23
- result[toHandlerKey(camelize(ev))] = (...arg) => emit(ev, ...arg);
24
- });
25
- return result;
26
- }
27
- //#endregion
28
- export { useEmitAsProps as t };
@@ -1,34 +0,0 @@
1
- import { a as isClient } from "./dist.js";
2
- import { watchEffect } from "vue";
3
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useFocusGuards.js
4
- /** Number of components which have requested interest to have focus guards */
5
- var count = 0;
6
- /**
7
- * Injects a pair of focus guards at the edges of the whole DOM tree
8
- * to ensure `focusin` & `focusout` events can be caught consistently.
9
- */
10
- function useFocusGuards() {
11
- watchEffect((cleanupFn) => {
12
- if (!isClient) return;
13
- const edgeGuards = document.querySelectorAll("[data-reka-focus-guard]");
14
- document.body.insertAdjacentElement("afterbegin", edgeGuards[0] ?? createFocusGuard());
15
- document.body.insertAdjacentElement("beforeend", edgeGuards[1] ?? createFocusGuard());
16
- count++;
17
- cleanupFn(() => {
18
- if (count === 1) document.querySelectorAll("[data-reka-focus-guard]").forEach((node) => node.remove());
19
- count--;
20
- });
21
- });
22
- }
23
- function createFocusGuard() {
24
- const element = document.createElement("span");
25
- element.setAttribute("data-reka-focus-guard", "");
26
- element.tabIndex = 0;
27
- element.style.outline = "none";
28
- element.style.opacity = "0";
29
- element.style.position = "fixed";
30
- element.style.pointerEvents = "none";
31
- return element;
32
- }
33
- //#endregion
34
- export { useFocusGuards as t };
@@ -1,8 +0,0 @@
1
- import { i as unrefElement } from "./dist2.js";
2
- import { computed, toValue } from "vue";
3
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useFormControl.js
4
- function useFormControl(el) {
5
- return computed(() => toValue(el) ? Boolean(unrefElement(el)?.closest("form")) : true);
6
- }
7
- //#endregion
8
- export { useFormControl as t };
@@ -1,58 +0,0 @@
1
- import { i as unrefElement } from "./dist2.js";
2
- import { computed, getCurrentInstance, onUpdated, ref, triggerRef } from "vue";
3
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useForwardExpose.js
4
- function useForwardExpose() {
5
- const instance = getCurrentInstance();
6
- const currentRef = ref();
7
- const currentElement = computed(() => resolveCurrentElement());
8
- onUpdated(() => {
9
- if (currentElement.value !== resolveCurrentElement()) triggerRef(currentRef);
10
- });
11
- function resolveCurrentElement() {
12
- return currentRef.value && "$el" in currentRef.value && ["#text", "#comment"].includes(currentRef.value.$el.nodeName) ? currentRef.value.$el.nextElementSibling : unrefElement(currentRef);
13
- }
14
- const localExpose = Object.assign({}, instance.exposed);
15
- const ret = {};
16
- for (const key in instance.props) Object.defineProperty(ret, key, {
17
- enumerable: true,
18
- configurable: true,
19
- get: () => instance.props[key]
20
- });
21
- if (Object.keys(localExpose).length > 0) for (const key in localExpose) Object.defineProperty(ret, key, {
22
- enumerable: true,
23
- configurable: true,
24
- get: () => localExpose[key]
25
- });
26
- Object.defineProperty(ret, "$el", {
27
- enumerable: true,
28
- configurable: true,
29
- get: () => instance.vnode.el
30
- });
31
- instance.exposed = ret;
32
- function forwardRef(ref$1) {
33
- currentRef.value = ref$1;
34
- if (!ref$1) return;
35
- Object.defineProperty(ret, "$el", {
36
- enumerable: true,
37
- configurable: true,
38
- get: () => ref$1 instanceof Element ? ref$1 : ref$1.$el
39
- });
40
- if (!(ref$1 instanceof Element) && !Object.hasOwn(ref$1, "$el")) {
41
- const childExposed = ref$1.$.exposed;
42
- const merged = Object.assign({}, ret);
43
- for (const key in childExposed) Object.defineProperty(merged, key, {
44
- enumerable: true,
45
- configurable: true,
46
- get: () => childExposed[key]
47
- });
48
- instance.exposed = merged;
49
- }
50
- }
51
- return {
52
- forwardRef,
53
- currentRef,
54
- currentElement
55
- };
56
- }
57
- //#endregion
58
- export { useForwardExpose as t };
@@ -1,34 +0,0 @@
1
- import { camelize, computed, getCurrentInstance, toRef } from "vue";
2
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useForwardProps.js
3
- /**
4
- * The `useForwardProps` function in TypeScript takes in a set of props and returns a computed value
5
- * that combines default props with assigned props from the current instance.
6
- * @param {T} props - The `props` parameter is an object that represents the props passed to a
7
- * component.
8
- * @returns computed value that combines the default props, preserved props, and assigned props.
9
- */
10
- function useForwardProps(props) {
11
- const vm = getCurrentInstance();
12
- const defaultProps = Object.keys(vm?.type.props ?? {}).reduce((prev, curr) => {
13
- const defaultValue = (vm?.type.props[curr]).default;
14
- if (defaultValue !== void 0) prev[curr] = defaultValue;
15
- return prev;
16
- }, {});
17
- const refProps = toRef(props);
18
- return computed(() => {
19
- const preservedProps = {};
20
- const assignedProps = vm?.vnode.props ?? {};
21
- Object.keys(assignedProps).forEach((key) => {
22
- preservedProps[camelize(key)] = assignedProps[key];
23
- });
24
- return Object.keys({
25
- ...defaultProps,
26
- ...preservedProps
27
- }).reduce((prev, curr) => {
28
- if (refProps.value[curr] !== void 0) prev[curr] = refProps.value[curr];
29
- return prev;
30
- }, {});
31
- });
32
- }
33
- //#endregion
34
- export { useForwardProps as t };
@@ -1,14 +0,0 @@
1
- import { t as useEmitAsProps } from "./useEmitAsProps.js";
2
- import { t as useForwardProps } from "./useForwardProps.js";
3
- import { computed } from "vue";
4
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useForwardPropsEmits.js
5
- function useForwardPropsEmits(props, emit) {
6
- const parsedProps = useForwardProps(props);
7
- const emitsAsProps = emit ? useEmitAsProps(emit) : {};
8
- return computed(() => ({
9
- ...parsedProps.value,
10
- ...emitsAsProps
11
- }));
12
- }
13
- //#endregion
14
- export { useForwardPropsEmits as t };
@@ -1,25 +0,0 @@
1
- import { getCurrentInstance } from "vue";
2
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useForwardScopeId.js
3
- /**
4
- * Returns the parent component's `<style scoped>` id (e.g. `data-v-xxxxxxx`) as a
5
- * bindable attribute object, so it can be manually forwarded onto the chosen root
6
- * element of a multi-root component.
7
- *
8
- * Vue only auto-applies the parent's scope id to a **single-root** component's root.
9
- * When a component renders multiple root nodes (e.g. an interactive control plus a
10
- * sibling hidden form input), that fallthrough is dropped and the parent's scoped
11
- * styles can no longer reach the component. Spread the returned object onto the
12
- * element that should stay styleable by the parent.
13
- *
14
- * @example
15
- * ```ts
16
- * const scopeIdAttrs = useForwardScopeId()
17
- * // <Primitive v-bind="{ ...$attrs, ...scopeIdAttrs }" />
18
- * ```
19
- */
20
- function useForwardScopeId() {
21
- const scopeId = (getCurrentInstance()?.vnode)?.scopeId;
22
- return scopeId ? { [scopeId]: "" } : {};
23
- }
24
- //#endregion
25
- export { useForwardScopeId as t };
@@ -1,132 +0,0 @@
1
- import { i as unrefElement } from "./dist2.js";
2
- import { onUnmounted, watch } from "vue";
3
- //#region ../../node_modules/.pnpm/aria-hidden@1.2.6/node_modules/aria-hidden/dist/es2015/index.js
4
- var getDefaultParent = function(originalTarget) {
5
- if (typeof document === "undefined") return null;
6
- return (Array.isArray(originalTarget) ? originalTarget[0] : originalTarget).ownerDocument.body;
7
- };
8
- var counterMap = /* @__PURE__ */ new WeakMap();
9
- var uncontrolledNodes = /* @__PURE__ */ new WeakMap();
10
- var markerMap = {};
11
- var lockCount = 0;
12
- var unwrapHost = function(node) {
13
- return node && (node.host || unwrapHost(node.parentNode));
14
- };
15
- var correctTargets = function(parent, targets) {
16
- return targets.map(function(target) {
17
- if (parent.contains(target)) return target;
18
- var correctedTarget = unwrapHost(target);
19
- if (correctedTarget && parent.contains(correctedTarget)) return correctedTarget;
20
- console.error("aria-hidden", target, "in not contained inside", parent, ". Doing nothing");
21
- return null;
22
- }).filter(function(x) {
23
- return Boolean(x);
24
- });
25
- };
26
- /**
27
- * Marks everything except given node(or nodes) as aria-hidden
28
- * @param {Element | Element[]} originalTarget - elements to keep on the page
29
- * @param [parentNode] - top element, defaults to document.body
30
- * @param {String} [markerName] - a special attribute to mark every node
31
- * @param {String} [controlAttribute] - html Attribute to control
32
- * @return {Undo} undo command
33
- */
34
- var applyAttributeToOthers = function(originalTarget, parentNode, markerName, controlAttribute) {
35
- var targets = correctTargets(parentNode, Array.isArray(originalTarget) ? originalTarget : [originalTarget]);
36
- if (!markerMap[markerName]) markerMap[markerName] = /* @__PURE__ */ new WeakMap();
37
- var markerCounter = markerMap[markerName];
38
- var hiddenNodes = [];
39
- var elementsToKeep = /* @__PURE__ */ new Set();
40
- var elementsToStop = new Set(targets);
41
- var keep = function(el) {
42
- if (!el || elementsToKeep.has(el)) return;
43
- elementsToKeep.add(el);
44
- keep(el.parentNode);
45
- };
46
- targets.forEach(keep);
47
- var deep = function(parent) {
48
- if (!parent || elementsToStop.has(parent)) return;
49
- Array.prototype.forEach.call(parent.children, function(node) {
50
- if (elementsToKeep.has(node)) deep(node);
51
- else try {
52
- var attr = node.getAttribute(controlAttribute);
53
- var alreadyHidden = attr !== null && attr !== "false";
54
- var counterValue = (counterMap.get(node) || 0) + 1;
55
- var markerValue = (markerCounter.get(node) || 0) + 1;
56
- counterMap.set(node, counterValue);
57
- markerCounter.set(node, markerValue);
58
- hiddenNodes.push(node);
59
- if (counterValue === 1 && alreadyHidden) uncontrolledNodes.set(node, true);
60
- if (markerValue === 1) node.setAttribute(markerName, "true");
61
- if (!alreadyHidden) node.setAttribute(controlAttribute, "true");
62
- } catch (e) {
63
- console.error("aria-hidden: cannot operate on ", node, e);
64
- }
65
- });
66
- };
67
- deep(parentNode);
68
- elementsToKeep.clear();
69
- lockCount++;
70
- return function() {
71
- hiddenNodes.forEach(function(node) {
72
- var counterValue = counterMap.get(node) - 1;
73
- var markerValue = markerCounter.get(node) - 1;
74
- counterMap.set(node, counterValue);
75
- markerCounter.set(node, markerValue);
76
- if (!counterValue) {
77
- if (!uncontrolledNodes.has(node)) node.removeAttribute(controlAttribute);
78
- uncontrolledNodes.delete(node);
79
- }
80
- if (!markerValue) node.removeAttribute(markerName);
81
- });
82
- lockCount--;
83
- if (!lockCount) {
84
- counterMap = /* @__PURE__ */ new WeakMap();
85
- counterMap = /* @__PURE__ */ new WeakMap();
86
- uncontrolledNodes = /* @__PURE__ */ new WeakMap();
87
- markerMap = {};
88
- }
89
- };
90
- };
91
- /**
92
- * Marks everything except given node(or nodes) as aria-hidden
93
- * @param {Element | Element[]} originalTarget - elements to keep on the page
94
- * @param [parentNode] - top element, defaults to document.body
95
- * @param {String} [markerName] - a special attribute to mark every node
96
- * @return {Undo} undo command
97
- */
98
- var hideOthers = function(originalTarget, parentNode, markerName) {
99
- if (markerName === void 0) markerName = "data-aria-hidden";
100
- var targets = Array.from(Array.isArray(originalTarget) ? originalTarget : [originalTarget]);
101
- var activeParentNode = parentNode || getDefaultParent(originalTarget);
102
- if (!activeParentNode) return function() {
103
- return null;
104
- };
105
- targets.push.apply(targets, Array.from(activeParentNode.querySelectorAll("[aria-live], script")));
106
- return applyAttributeToOthers(targets, activeParentNode, markerName, "aria-hidden");
107
- };
108
- //#endregion
109
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useHideOthers.js
110
- /**
111
- * The `useHideOthers` function is a TypeScript function that takes a target element reference and
112
- * hides all other elements in ARIA when the target element is present, and restores the visibility of the
113
- * hidden elements when the target element is removed.
114
- * @param {MaybeElementRef} target - The `target` parameter is a reference to the element that you want
115
- * to hide other elements when it is clicked or focused.
116
- */
117
- function useHideOthers(target) {
118
- let undo;
119
- watch(() => unrefElement(target), (el) => {
120
- let isInsideClosedPopover = false;
121
- try {
122
- isInsideClosedPopover = !!el?.closest("[popover]:not(:popover-open)");
123
- } catch {}
124
- if (el && !isInsideClosedPopover) undo = hideOthers(el);
125
- else if (undo) undo();
126
- });
127
- onUnmounted(() => {
128
- if (undo) undo();
129
- });
130
- }
131
- //#endregion
132
- export { useHideOthers as t };
@@ -1,23 +0,0 @@
1
- import { n as injectConfigProviderContext } from "./ConfigProvider.js";
2
- import * as vue from "vue";
3
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useId.js
4
- var count = 0;
5
- /**
6
- * The `useId` function generates a unique identifier using a provided deterministic ID,
7
- * a configured `<ConfigProvider>` ID source, Vue's native `useId`, or a fallback counter.
8
- * @param {string | null | undefined} [deterministicId] - The `useId` function you provided takes an
9
- * optional parameter `deterministicId`, which can be a string, null, or undefined. If
10
- * `deterministicId` is provided, the function will return it. Otherwise, it will generate an id using
11
- * the configured ID source.
12
- */
13
- function useId(deterministicId, prefix = "reka") {
14
- if (deterministicId) return deterministicId;
15
- let id;
16
- const configProviderContext = injectConfigProviderContext({ useId: void 0 });
17
- if (configProviderContext.useId) id = configProviderContext.useId();
18
- else if ("useId" in vue) id = vue.useId?.();
19
- else id = `${++count}`;
20
- return prefix ? `${prefix}-${id}` : id;
21
- }
22
- //#endregion
23
- export { useId as t };
@@ -1,41 +0,0 @@
1
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useKbd.js
2
- function useKbd() {
3
- return {
4
- ALT: "Alt",
5
- ARROW_DOWN: "ArrowDown",
6
- ARROW_LEFT: "ArrowLeft",
7
- ARROW_RIGHT: "ArrowRight",
8
- ARROW_UP: "ArrowUp",
9
- BACKSPACE: "Backspace",
10
- CAPS_LOCK: "CapsLock",
11
- CONTROL: "Control",
12
- DELETE: "Delete",
13
- END: "End",
14
- ENTER: "Enter",
15
- ESCAPE: "Escape",
16
- F1: "F1",
17
- F10: "F10",
18
- F11: "F11",
19
- F12: "F12",
20
- F2: "F2",
21
- F3: "F3",
22
- F4: "F4",
23
- F5: "F5",
24
- F6: "F6",
25
- F7: "F7",
26
- F8: "F8",
27
- F9: "F9",
28
- HOME: "Home",
29
- META: "Meta",
30
- PAGE_DOWN: "PageDown",
31
- PAGE_UP: "PageUp",
32
- SHIFT: "Shift",
33
- SPACE: " ",
34
- TAB: "Tab",
35
- CTRL: "Control",
36
- ASTERISK: "*",
37
- SPACE_CODE: "Space"
38
- };
39
- }
40
- //#endregion
41
- export { useKbd as t };
@@ -1,14 +0,0 @@
1
- import { n as injectConfigProviderContext } from "./ConfigProvider.js";
2
- import { computed, ref } from "vue";
3
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useLocale.js
4
- /**
5
- * The `useLocale` function provides a way to access the current locale in your application.
6
- * @param {Ref<string | undefined>} [locale] - An optional ref containing the locale.
7
- * @returns A computed ref holding the resolved locale.
8
- */
9
- function useLocale(locale) {
10
- const context = injectConfigProviderContext({ locale: ref("en") });
11
- return computed(() => locale?.value || context.locale?.value || "en");
12
- }
13
- //#endregion
14
- export { useLocale as t };
@@ -1,9 +0,0 @@
1
- import { n as injectConfigProviderContext } from "./ConfigProvider.js";
2
- import { computed, ref } from "vue";
3
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useNonce.js
4
- function useNonce(nonce) {
5
- const context = injectConfigProviderContext({ nonce: ref() });
6
- return computed(() => nonce?.value || context.nonce?.value);
7
- }
8
- //#endregion
9
- export { useNonce as t };
@@ -1,12 +0,0 @@
1
- import { i as unrefElement } from "./dist2.js";
2
- import { computed, ref } from "vue";
3
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/Primitive/usePrimitiveElement.js
4
- function usePrimitiveElement() {
5
- const primitiveElement = ref();
6
- return {
7
- primitiveElement,
8
- currentElement: computed(() => ["#text", "#comment"].includes(primitiveElement.value?.$el.nodeName) ? primitiveElement.value?.$el.nextElementSibling : unrefElement(primitiveElement))
9
- };
10
- }
11
- //#endregion
12
- export { usePrimitiveElement as t };
@@ -1,49 +0,0 @@
1
- import { i as unrefElement } from "./dist2.js";
2
- import { computed, onMounted, onUnmounted, ref } from "vue";
3
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useSize.js
4
- function useSize(element) {
5
- const size = ref();
6
- const width = computed(() => size.value?.width ?? 0);
7
- const height = computed(() => size.value?.height ?? 0);
8
- let resizeObserver;
9
- onMounted(() => {
10
- const el = unrefElement(element);
11
- if (el) {
12
- size.value = {
13
- width: el.offsetWidth,
14
- height: el.offsetHeight
15
- };
16
- resizeObserver = new ResizeObserver((entries) => {
17
- if (!Array.isArray(entries)) return;
18
- if (!entries.length) return;
19
- const entry = entries[0];
20
- let width$1;
21
- let height$1;
22
- if ("borderBoxSize" in entry) {
23
- const borderSizeEntry = entry.borderBoxSize;
24
- const borderSize = Array.isArray(borderSizeEntry) ? borderSizeEntry[0] : borderSizeEntry;
25
- width$1 = borderSize.inlineSize;
26
- height$1 = borderSize.blockSize;
27
- } else {
28
- width$1 = el.offsetWidth;
29
- height$1 = el.offsetHeight;
30
- }
31
- size.value = {
32
- width: width$1,
33
- height: height$1
34
- };
35
- });
36
- resizeObserver.observe(el, { box: "border-box" });
37
- } else size.value = void 0;
38
- });
39
- onUnmounted(() => {
40
- resizeObserver?.disconnect();
41
- resizeObserver = void 0;
42
- });
43
- return {
44
- width,
45
- height
46
- };
47
- }
48
- //#endregion
49
- export { useSize as t };
@@ -1,64 +0,0 @@
1
- import { t as getActiveElement } from "./getActiveElement.js";
2
- import { p as refAutoReset } from "./dist.js";
3
- //#region ../../node_modules/.pnpm/reka-ui@2.10.5_vue@3.5.41_typescript@6.0.3_/node_modules/reka-ui/dist/shared/useTypeahead.js
4
- function useTypeahead(callback) {
5
- const search = refAutoReset("", 1e3);
6
- const handleTypeaheadSearch = (key, items) => {
7
- search.value = search.value + key;
8
- if (callback) callback(key);
9
- else {
10
- const currentItem = getActiveElement();
11
- const itemsWithTextValue = items.map((item) => ({
12
- ...item,
13
- textValue: item.value?.textValue ?? item.ref.textContent?.trim() ?? ""
14
- }));
15
- const currentMatch = itemsWithTextValue.find((item) => item.ref === currentItem);
16
- const nextMatch = getNextMatch(itemsWithTextValue.map((item) => item.textValue), search.value, currentMatch?.textValue);
17
- const newItem = itemsWithTextValue.find((item) => item.textValue === nextMatch);
18
- if (newItem) newItem.ref.focus();
19
- return newItem?.ref;
20
- }
21
- };
22
- const resetTypeahead = () => {
23
- search.value = "";
24
- };
25
- return {
26
- search,
27
- handleTypeaheadSearch,
28
- resetTypeahead
29
- };
30
- }
31
- /**
32
- * Wraps an array around itself at a given start index
33
- * Example: `wrapArray(['a', 'b', 'c', 'd'], 2) === ['c', 'd', 'a', 'b']`
34
- */
35
- function wrapArray(array, startIndex) {
36
- return array.map((_, index) => array[(startIndex + index) % array.length]);
37
- }
38
- /**
39
- * This is the "meat" of the typeahead matching logic. It takes in all the values,
40
- * the search and the current match, and returns the next match (or `undefined`).
41
- *
42
- * We normalize the search because if a user has repeatedly pressed a character,
43
- * we want the exact same behavior as if we only had that one character
44
- * (ie. cycle through options starting with that character)
45
- *
46
- * We also reorder the values by wrapping the array around the current match.
47
- * This is so we always look forward from the current match, and picking the first
48
- * match will always be the correct one.
49
- *
50
- * Finally, if the normalized search is exactly one character, we exclude the
51
- * current match from the values because otherwise it would be the first to match always
52
- * and focus would never move. This is as opposed to the regular case, where we
53
- * don't want focus to move if the current match still matches.
54
- */
55
- function getNextMatch(values, search, currentMatch) {
56
- const normalizedSearch = search.length > 1 && Array.from(search).every((char) => char === search[0]) ? search[0] : search;
57
- const currentMatchIndex = currentMatch ? values.indexOf(currentMatch) : -1;
58
- let wrappedValues = wrapArray(values, Math.max(currentMatchIndex, 0));
59
- if (normalizedSearch.length === 1) wrappedValues = wrappedValues.filter((v) => v !== currentMatch);
60
- const nextMatch = wrappedValues.find((value) => value.toLowerCase().startsWith(normalizedSearch.toLowerCase()));
61
- return nextMatch !== currentMatch ? nextMatch : void 0;
62
- }
63
- //#endregion
64
- export { useTypeahead as t };