@hina-ui/vue 1.7.6 → 1.7.8

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 (789) hide show
  1. package/dist/index.js +7952 -663
  2. package/dist/index.js.map +1 -1
  3. package/dist/shared/behavior/anchor-follow.ts +20 -11
  4. package/dist/shared/lib/command-palette/match.ts +9 -0
  5. package/dist/shared/lib/float-button.ts +14 -0
  6. package/dist/shared/lib/line-clamp.ts +76 -0
  7. package/dist/shared/lib/scroll-restore.ts +145 -0
  8. package/dist/shared/locale/en-US.ts +4 -0
  9. package/dist/shared/locale/index.ts +2 -0
  10. package/dist/shared/locale/ja-JP.ts +229 -0
  11. package/dist/shared/locale/types.ts +4 -0
  12. package/dist/shared/locale/zh-CN.ts +4 -0
  13. package/dist/shared/primitives/accordion/LICENSE +21 -0
  14. package/dist/shared/primitives/accordion/index.ts +34 -0
  15. package/dist/shared/primitives/arrow-navigation/LICENSE +21 -0
  16. package/dist/shared/primitives/arrow-navigation/index.ts +90 -0
  17. package/dist/shared/primitives/body-scroll-lock/LICENSE +21 -0
  18. package/dist/shared/primitives/body-scroll-lock/index.ts +115 -0
  19. package/dist/shared/primitives/checkbox/LICENSE +21 -0
  20. package/dist/shared/primitives/checkbox/index.ts +23 -0
  21. package/dist/shared/primitives/collapsible/LICENSE +21 -0
  22. package/dist/shared/primitives/collapsible/index.ts +31 -0
  23. package/dist/shared/primitives/collection/LICENSE +21 -0
  24. package/dist/shared/primitives/collection/index.ts +19 -0
  25. package/dist/shared/primitives/dismissable-layer/LICENSE +21 -0
  26. package/dist/shared/primitives/dismissable-layer/index.ts +203 -0
  27. package/dist/shared/primitives/focus-guards/LICENSE +21 -0
  28. package/dist/shared/primitives/focus-guards/index.ts +24 -0
  29. package/dist/shared/primitives/focus-scope/LICENSE +21 -0
  30. package/dist/shared/primitives/focus-scope/index.ts +216 -0
  31. package/dist/shared/primitives/label/LICENSE +21 -0
  32. package/dist/shared/primitives/label/index.ts +4 -0
  33. package/dist/shared/primitives/pagination/LICENSE +21 -0
  34. package/dist/shared/primitives/pagination/index.ts +99 -0
  35. package/dist/shared/primitives/pin-input/LICENSE +21 -0
  36. package/dist/shared/primitives/pin-input/index.ts +126 -0
  37. package/dist/shared/primitives/presence/LICENSE +21 -0
  38. package/dist/shared/primitives/presence/index.ts +135 -0
  39. package/dist/shared/primitives/progress/LICENSE +21 -0
  40. package/dist/shared/primitives/progress/index.ts +41 -0
  41. package/dist/shared/primitives/radio-group/LICENSE +21 -0
  42. package/dist/shared/primitives/radio-group/index.ts +46 -0
  43. package/dist/shared/primitives/rating/LICENSE +21 -0
  44. package/dist/shared/primitives/rating/index.ts +37 -0
  45. package/dist/shared/primitives/roving-focus/LICENSE +21 -0
  46. package/dist/shared/primitives/roving-focus/index.ts +44 -0
  47. package/dist/shared/primitives/separator/LICENSE +21 -0
  48. package/dist/shared/primitives/separator/index.ts +14 -0
  49. package/dist/shared/primitives/size/LICENSE +21 -0
  50. package/dist/shared/primitives/size/index.ts +19 -0
  51. package/dist/shared/primitives/slider/LICENSE +21 -0
  52. package/dist/shared/primitives/slider/index.ts +183 -0
  53. package/dist/shared/primitives/splitter/LICENSE +21 -0
  54. package/dist/shared/primitives/splitter/arrays.ts +6 -0
  55. package/dist/shared/primitives/splitter/assert.ts +9 -0
  56. package/dist/shared/primitives/splitter/calculate.ts +139 -0
  57. package/dist/shared/primitives/splitter/callPanelCallbacks.ts +40 -0
  58. package/dist/shared/primitives/splitter/compare.ts +13 -0
  59. package/dist/shared/primitives/splitter/constants.ts +1 -0
  60. package/dist/shared/primitives/splitter/debounce.ts +10 -0
  61. package/dist/shared/primitives/splitter/dom.ts +64 -0
  62. package/dist/shared/primitives/splitter/events.ts +29 -0
  63. package/dist/shared/primitives/splitter/flags.ts +4 -0
  64. package/dist/shared/primitives/splitter/layout.ts +153 -0
  65. package/dist/shared/primitives/splitter/pivot.ts +10 -0
  66. package/dist/shared/primitives/splitter/rects.ts +24 -0
  67. package/dist/shared/primitives/splitter/registry.ts +231 -0
  68. package/dist/shared/primitives/splitter/resizePanel.ts +30 -0
  69. package/dist/shared/primitives/splitter/stackingOrder.ts +88 -0
  70. package/dist/shared/primitives/splitter/storage.ts +95 -0
  71. package/dist/shared/primitives/splitter/style.ts +95 -0
  72. package/dist/shared/primitives/splitter/types.ts +48 -0
  73. package/dist/shared/primitives/splitter/units.ts +123 -0
  74. package/dist/shared/primitives/splitter/validation.ts +55 -0
  75. package/dist/shared/primitives/stepper/LICENSE +21 -0
  76. package/dist/shared/primitives/stepper/index.ts +58 -0
  77. package/dist/shared/primitives/tabs/LICENSE +21 -0
  78. package/dist/shared/primitives/tabs/index.ts +18 -0
  79. package/dist/shared/primitives/toggle/LICENSE +21 -0
  80. package/dist/shared/primitives/toggle/index.ts +5 -0
  81. package/dist/shared/primitives/value/LICENSE +21 -0
  82. package/dist/shared/primitives/value/index.ts +80 -0
  83. package/dist/shared/primitives/visually-hidden/LICENSE +21 -0
  84. package/dist/shared/primitives/visually-hidden/index.ts +25 -0
  85. package/dist/shared/styles/density.css +4 -0
  86. package/dist/shared/styles/float-button.css +20 -6
  87. package/dist/shared/styles/line-clamp.css +98 -0
  88. package/dist/shared/styles/tokens.css +1 -0
  89. package/dist/shared/styles/typography.css +18 -0
  90. package/dist/shared/variants/button.ts +2 -0
  91. package/dist/shared/variants/command-palette.ts +4 -0
  92. package/dist/shared/variants/line-clamp.ts +13 -0
  93. package/dist/shared/variants/panel.ts +5 -0
  94. package/dist/shared/variants/tag.ts +1 -0
  95. package/dist/types/shared/src/behavior/anchor-follow.d.ts.map +1 -1
  96. package/dist/types/shared/src/lib/command-palette/match.d.ts +5 -0
  97. package/dist/types/shared/src/lib/command-palette/match.d.ts.map +1 -1
  98. package/dist/types/shared/src/lib/float-button.d.ts +15 -0
  99. package/dist/types/shared/src/lib/float-button.d.ts.map +1 -0
  100. package/dist/types/shared/src/lib/line-clamp.d.ts +6 -0
  101. package/dist/types/shared/src/lib/line-clamp.d.ts.map +1 -0
  102. package/dist/types/shared/src/lib/scroll-restore.d.ts +14 -0
  103. package/dist/types/shared/src/lib/scroll-restore.d.ts.map +1 -1
  104. package/dist/types/shared/src/locale/en-US.d.ts.map +1 -1
  105. package/dist/types/shared/src/locale/index.d.ts +1 -0
  106. package/dist/types/shared/src/locale/index.d.ts.map +1 -1
  107. package/dist/types/shared/src/locale/ja-JP.d.ts +3 -0
  108. package/dist/types/shared/src/locale/ja-JP.d.ts.map +1 -0
  109. package/dist/types/shared/src/locale/types.d.ts +4 -0
  110. package/dist/types/shared/src/locale/types.d.ts.map +1 -1
  111. package/dist/types/shared/src/locale/zh-CN.d.ts.map +1 -1
  112. package/dist/types/shared/src/primitives/accordion/index.d.ts +9 -0
  113. package/dist/types/shared/src/primitives/accordion/index.d.ts.map +1 -0
  114. package/dist/types/shared/src/primitives/arrow-navigation/index.d.ts +12 -0
  115. package/dist/types/shared/src/primitives/arrow-navigation/index.d.ts.map +1 -0
  116. package/dist/types/shared/src/primitives/checkbox/index.d.ts +6 -0
  117. package/dist/types/shared/src/primitives/checkbox/index.d.ts.map +1 -0
  118. package/dist/types/shared/src/primitives/collapsible/index.d.ts +12 -0
  119. package/dist/types/shared/src/primitives/collapsible/index.d.ts.map +1 -0
  120. package/dist/types/shared/src/primitives/collection/index.d.ts +6 -0
  121. package/dist/types/shared/src/primitives/collection/index.d.ts.map +1 -0
  122. package/dist/types/shared/src/primitives/dismissable-layer/index.d.ts +41 -0
  123. package/dist/types/shared/src/primitives/dismissable-layer/index.d.ts.map +1 -0
  124. package/dist/types/shared/src/primitives/focus-scope/index.d.ts +51 -0
  125. package/dist/types/shared/src/primitives/focus-scope/index.d.ts.map +1 -0
  126. package/dist/types/shared/src/primitives/label/index.d.ts +2 -0
  127. package/dist/types/shared/src/primitives/label/index.d.ts.map +1 -0
  128. package/dist/types/shared/src/primitives/pagination/index.d.ts +17 -0
  129. package/dist/types/shared/src/primitives/pagination/index.d.ts.map +1 -0
  130. package/dist/types/shared/src/primitives/pin-input/index.d.ts +31 -0
  131. package/dist/types/shared/src/primitives/pin-input/index.d.ts.map +1 -0
  132. package/dist/types/shared/src/primitives/presence/index.d.ts +14 -0
  133. package/dist/types/shared/src/primitives/presence/index.d.ts.map +1 -0
  134. package/dist/types/shared/src/primitives/progress/index.d.ts +10 -0
  135. package/dist/types/shared/src/primitives/progress/index.d.ts.map +1 -0
  136. package/dist/types/shared/src/primitives/radio-group/index.d.ts +12 -0
  137. package/dist/types/shared/src/primitives/radio-group/index.d.ts.map +1 -0
  138. package/dist/types/shared/src/primitives/rating/index.d.ts +8 -0
  139. package/dist/types/shared/src/primitives/rating/index.d.ts.map +1 -0
  140. package/dist/types/shared/src/primitives/roving-focus/index.d.ts +13 -0
  141. package/dist/types/shared/src/primitives/roving-focus/index.d.ts.map +1 -0
  142. package/dist/types/shared/src/primitives/separator/index.d.ts +10 -0
  143. package/dist/types/shared/src/primitives/separator/index.d.ts.map +1 -0
  144. package/dist/types/shared/src/primitives/size/index.d.ts +7 -0
  145. package/dist/types/shared/src/primitives/size/index.d.ts.map +1 -0
  146. package/dist/types/shared/src/primitives/slider/index.d.ts +60 -0
  147. package/dist/types/shared/src/primitives/slider/index.d.ts.map +1 -0
  148. package/dist/types/shared/src/primitives/splitter/arrays.d.ts +2 -0
  149. package/dist/types/shared/src/primitives/splitter/arrays.d.ts.map +1 -0
  150. package/dist/types/shared/src/primitives/splitter/assert.d.ts +2 -0
  151. package/dist/types/shared/src/primitives/splitter/assert.d.ts.map +1 -0
  152. package/dist/types/shared/src/primitives/splitter/calculate.d.ts +15 -0
  153. package/dist/types/shared/src/primitives/splitter/calculate.d.ts.map +1 -0
  154. package/dist/types/shared/src/primitives/splitter/callPanelCallbacks.d.ts +3 -0
  155. package/dist/types/shared/src/primitives/splitter/callPanelCallbacks.d.ts.map +1 -0
  156. package/dist/types/shared/src/primitives/splitter/compare.d.ts +3 -0
  157. package/dist/types/shared/src/primitives/splitter/compare.d.ts.map +1 -0
  158. package/dist/types/shared/src/primitives/splitter/constants.d.ts +2 -0
  159. package/dist/types/shared/src/primitives/splitter/constants.d.ts.map +1 -0
  160. package/dist/types/shared/src/primitives/splitter/debounce.d.ts +2 -0
  161. package/dist/types/shared/src/primitives/splitter/debounce.d.ts.map +1 -0
  162. package/dist/types/shared/src/primitives/splitter/dom.d.ts +8 -0
  163. package/dist/types/shared/src/primitives/splitter/dom.d.ts.map +1 -0
  164. package/dist/types/shared/src/primitives/splitter/events.d.ts +10 -0
  165. package/dist/types/shared/src/primitives/splitter/events.d.ts.map +1 -0
  166. package/dist/types/shared/src/primitives/splitter/flags.d.ts +5 -0
  167. package/dist/types/shared/src/primitives/splitter/flags.d.ts.map +1 -0
  168. package/dist/types/shared/src/primitives/splitter/layout.d.ts +10 -0
  169. package/dist/types/shared/src/primitives/splitter/layout.d.ts.map +1 -0
  170. package/dist/types/shared/src/primitives/splitter/pivot.d.ts +2 -0
  171. package/dist/types/shared/src/primitives/splitter/pivot.d.ts.map +1 -0
  172. package/dist/types/shared/src/primitives/splitter/rects.d.ts +8 -0
  173. package/dist/types/shared/src/primitives/splitter/rects.d.ts.map +1 -0
  174. package/dist/types/shared/src/primitives/splitter/registry.d.ts +5 -0
  175. package/dist/types/shared/src/primitives/splitter/registry.d.ts.map +1 -0
  176. package/dist/types/shared/src/primitives/splitter/resizePanel.d.ts +7 -0
  177. package/dist/types/shared/src/primitives/splitter/resizePanel.d.ts.map +1 -0
  178. package/dist/types/shared/src/primitives/splitter/stackingOrder.d.ts +2 -0
  179. package/dist/types/shared/src/primitives/splitter/stackingOrder.d.ts.map +1 -0
  180. package/dist/types/shared/src/primitives/splitter/storage.d.ts +9 -0
  181. package/dist/types/shared/src/primitives/splitter/storage.d.ts.map +1 -0
  182. package/dist/types/shared/src/primitives/splitter/style.d.ts +21 -0
  183. package/dist/types/shared/src/primitives/splitter/style.d.ts.map +1 -0
  184. package/dist/types/shared/src/primitives/splitter/types.d.ts +42 -0
  185. package/dist/types/shared/src/primitives/splitter/types.d.ts.map +1 -0
  186. package/dist/types/shared/src/primitives/splitter/units.d.ts +13 -0
  187. package/dist/types/shared/src/primitives/splitter/units.d.ts.map +1 -0
  188. package/dist/types/shared/src/primitives/splitter/validation.d.ts +6 -0
  189. package/dist/types/shared/src/primitives/splitter/validation.d.ts.map +1 -0
  190. package/dist/types/shared/src/primitives/stepper/index.d.ts +21 -0
  191. package/dist/types/shared/src/primitives/stepper/index.d.ts.map +1 -0
  192. package/dist/types/shared/src/primitives/tabs/index.d.ts +7 -0
  193. package/dist/types/shared/src/primitives/tabs/index.d.ts.map +1 -0
  194. package/dist/types/shared/src/primitives/toggle/index.d.ts +3 -0
  195. package/dist/types/shared/src/primitives/toggle/index.d.ts.map +1 -0
  196. package/dist/types/shared/src/primitives/value/index.d.ts +15 -0
  197. package/dist/types/shared/src/primitives/value/index.d.ts.map +1 -0
  198. package/dist/types/shared/src/primitives/visually-hidden/index.d.ts +19 -0
  199. package/dist/types/shared/src/primitives/visually-hidden/index.d.ts.map +1 -0
  200. package/dist/types/shared/src/variants/button.d.ts +6 -0
  201. package/dist/types/shared/src/variants/button.d.ts.map +1 -1
  202. package/dist/types/shared/src/variants/command-palette.d.ts +1 -0
  203. package/dist/types/shared/src/variants/command-palette.d.ts.map +1 -1
  204. package/dist/types/shared/src/variants/line-clamp.d.ts +4 -0
  205. package/dist/types/shared/src/variants/line-clamp.d.ts.map +1 -0
  206. package/dist/types/shared/src/variants/panel.d.ts +13 -1
  207. package/dist/types/shared/src/variants/panel.d.ts.map +1 -1
  208. package/dist/types/shared/src/variants/tag.d.ts +3 -0
  209. package/dist/types/shared/src/variants/tag.d.ts.map +1 -1
  210. package/dist/types/shared/src/variants/toggle.d.ts +7 -0
  211. package/dist/types/shared/src/variants/toggle.d.ts.map +1 -1
  212. package/dist/types/vue/src/components/accordion/Accordion.vue.d.ts.map +1 -1
  213. package/dist/types/vue/src/components/app-shell/AppShell.vue.d.ts +2 -2
  214. package/dist/types/vue/src/components/app-shell/AppShell.vue.d.ts.map +1 -1
  215. package/dist/types/vue/src/components/breadcrumb/BreadcrumbItem.vue.d.ts +2 -2
  216. package/dist/types/vue/src/components/breadcrumb/BreadcrumbItem.vue.d.ts.map +1 -1
  217. package/dist/types/vue/src/components/button/Button.vue.d.ts +2 -2
  218. package/dist/types/vue/src/components/button/Button.vue.d.ts.map +1 -1
  219. package/dist/types/vue/src/components/card/Card.vue.d.ts +2 -2
  220. package/dist/types/vue/src/components/card/Card.vue.d.ts.map +1 -1
  221. package/dist/types/vue/src/components/carousel/composables/useCarousel.d.ts +1 -1
  222. package/dist/types/vue/src/components/chip/Chip.vue.d.ts +1 -1
  223. package/dist/types/vue/src/components/chip/Chip.vue.d.ts.map +1 -1
  224. package/dist/types/vue/src/components/chip/composables/useChipRoot.d.ts +2 -2
  225. package/dist/types/vue/src/components/chip/composables/useChipRoot.d.ts.map +1 -1
  226. package/dist/types/vue/src/components/close-button/CloseButton.vue.d.ts +1 -1
  227. package/dist/types/vue/src/components/collapsible/Collapsible.vue.d.ts.map +1 -1
  228. package/dist/types/vue/src/components/command-palette/CommandPalette.vue.d.ts +40 -34
  229. package/dist/types/vue/src/components/command-palette/CommandPalette.vue.d.ts.map +1 -1
  230. package/dist/types/vue/src/components/command-palette/CommandPaletteInput.vue.d.ts +8 -0
  231. package/dist/types/vue/src/components/command-palette/CommandPaletteInput.vue.d.ts.map +1 -0
  232. package/dist/types/vue/src/components/command-palette/CommandPaletteItem.vue.d.ts +21 -7
  233. package/dist/types/vue/src/components/command-palette/CommandPaletteItem.vue.d.ts.map +1 -1
  234. package/dist/types/vue/src/components/command-palette/CommandPalettePanel.vue.d.ts +37 -31
  235. package/dist/types/vue/src/components/command-palette/CommandPalettePanel.vue.d.ts.map +1 -1
  236. package/dist/types/vue/src/components/command-palette/composables/useCommandItems.d.ts +6 -6
  237. package/dist/types/vue/src/components/command-palette/composables/useCommandItems.d.ts.map +1 -1
  238. package/dist/types/vue/src/components/command-palette/context.d.ts +11 -0
  239. package/dist/types/vue/src/components/command-palette/context.d.ts.map +1 -0
  240. package/dist/types/vue/src/components/command-palette/types.d.ts +16 -5
  241. package/dist/types/vue/src/components/command-palette/types.d.ts.map +1 -1
  242. package/dist/types/vue/src/components/command-palette/utils/match.d.ts +3 -3
  243. package/dist/types/vue/src/components/command-palette/utils/match.d.ts.map +1 -1
  244. package/dist/types/vue/src/components/copy-button/CopyButton.vue.d.ts +1 -1
  245. package/dist/types/vue/src/components/data-list/DataList.vue.d.ts +2 -2
  246. package/dist/types/vue/src/components/data-table/DataTable.vue.d.ts +2 -2
  247. package/dist/types/vue/src/components/description-list/DescriptionList.vue.d.ts +1 -0
  248. package/dist/types/vue/src/components/description-list/DescriptionList.vue.d.ts.map +1 -1
  249. package/dist/types/vue/src/components/dialog/Dialog.vue.d.ts +3 -0
  250. package/dist/types/vue/src/components/dialog/Dialog.vue.d.ts.map +1 -1
  251. package/dist/types/vue/src/components/drawer/Drawer.vue.d.ts +3 -0
  252. package/dist/types/vue/src/components/drawer/Drawer.vue.d.ts.map +1 -1
  253. package/dist/types/vue/src/components/float-button/FloatButton.vue.d.ts +1 -1
  254. package/dist/types/vue/src/components/float-button/FloatButton.vue.d.ts.map +1 -1
  255. package/dist/types/vue/src/components/float-button/types.d.ts +3 -2
  256. package/dist/types/vue/src/components/float-button/types.d.ts.map +1 -1
  257. package/dist/types/vue/src/components/form/Form.vue.d.ts +5 -0
  258. package/dist/types/vue/src/components/form/Form.vue.d.ts.map +1 -1
  259. package/dist/types/vue/src/components/form/scope.d.ts +4 -0
  260. package/dist/types/vue/src/components/form/scope.d.ts.map +1 -0
  261. package/dist/types/vue/src/components/heading/Heading.vue.d.ts.map +1 -1
  262. package/dist/types/vue/src/components/icon-button/IconButton.vue.d.ts +2 -2
  263. package/dist/types/vue/src/components/icon-button/IconButton.vue.d.ts.map +1 -1
  264. package/dist/types/vue/src/components/image/Image.vue.d.ts.map +1 -1
  265. package/dist/types/vue/src/components/indicator/Indicator.vue.d.ts +2 -2
  266. package/dist/types/vue/src/components/indicator/Indicator.vue.d.ts.map +1 -1
  267. package/dist/types/vue/src/components/line-clamp/LineClamp.vue.d.ts +28 -0
  268. package/dist/types/vue/src/components/line-clamp/LineClamp.vue.d.ts.map +1 -0
  269. package/dist/types/vue/src/components/line-clamp/line-clamp.variants.d.ts +2 -0
  270. package/dist/types/vue/src/components/line-clamp/line-clamp.variants.d.ts.map +1 -0
  271. package/dist/types/vue/src/components/link/Link.vue.d.ts +2 -2
  272. package/dist/types/vue/src/components/link/Link.vue.d.ts.map +1 -1
  273. package/dist/types/vue/src/components/multi-select/MultiSelect.vue.d.ts.map +1 -1
  274. package/dist/types/vue/src/components/nav-link/NavLink.vue.d.ts +9 -5
  275. package/dist/types/vue/src/components/nav-link/NavLink.vue.d.ts.map +1 -1
  276. package/dist/types/vue/src/components/nav-link/NavLinkChild.d.ts +27 -0
  277. package/dist/types/vue/src/components/nav-link/NavLinkChild.d.ts.map +1 -0
  278. package/dist/types/vue/src/components/navigation-menu/NavigationMenuLink.vue.d.ts +2 -2
  279. package/dist/types/vue/src/components/navigation-menu/NavigationMenuLink.vue.d.ts.map +1 -1
  280. package/dist/types/vue/src/components/pagination/PaginationControl.vue.d.ts.map +1 -1
  281. package/dist/types/vue/src/components/prev-next/PrevNextLink.vue.d.ts +2 -2
  282. package/dist/types/vue/src/components/prev-next/PrevNextLink.vue.d.ts.map +1 -1
  283. package/dist/types/vue/src/components/prose/Prose.vue.d.ts +2 -2
  284. package/dist/types/vue/src/components/prose/Prose.vue.d.ts.map +1 -1
  285. package/dist/types/vue/src/components/section/Section.vue.d.ts.map +1 -1
  286. package/dist/types/vue/src/components/segmented-control/SegmentedControl.vue.d.ts.map +1 -1
  287. package/dist/types/vue/src/components/sheet/Sheet.vue.d.ts +3 -0
  288. package/dist/types/vue/src/components/sheet/Sheet.vue.d.ts.map +1 -1
  289. package/dist/types/vue/src/components/sidebar/Sidebar.vue.d.ts.map +1 -1
  290. package/dist/types/vue/src/components/sidebar/context.d.ts +2 -0
  291. package/dist/types/vue/src/components/sidebar/context.d.ts.map +1 -1
  292. package/dist/types/vue/src/components/slider/SliderHandle.vue.d.ts.map +1 -1
  293. package/dist/types/vue/src/components/split-button/SplitButton.vue.d.ts +1 -1
  294. package/dist/types/vue/src/components/split-button/types.d.ts +1 -1
  295. package/dist/types/vue/src/components/split-button/types.d.ts.map +1 -1
  296. package/dist/types/vue/src/components/tag/Tag.vue.d.ts +2 -2
  297. package/dist/types/vue/src/components/tag/Tag.vue.d.ts.map +1 -1
  298. package/dist/types/vue/src/components/text/Text.vue.d.ts +2 -2
  299. package/dist/types/vue/src/components/text/Text.vue.d.ts.map +1 -1
  300. package/dist/types/vue/src/components/time/Time.vue.d.ts +2 -0
  301. package/dist/types/vue/src/components/time/Time.vue.d.ts.map +1 -1
  302. package/dist/types/vue/src/components/toast/Toaster.vue.d.ts.map +1 -1
  303. package/dist/types/vue/src/components/toggle/Toggle.vue.d.ts.map +1 -1
  304. package/dist/types/vue/src/components/toolbar/ToolbarControl.vue.d.ts +1 -1
  305. package/dist/types/vue/src/components/toolbar/ToolbarLink.vue.d.ts +1 -1
  306. package/dist/types/vue/src/components/toolbar/ToolbarToggleGroup.vue.d.ts.map +1 -1
  307. package/dist/types/vue/src/components/toolbar/types.d.ts +1 -1
  308. package/dist/types/vue/src/components/toolbar/types.d.ts.map +1 -1
  309. package/dist/types/vue/src/components/virtual-list/composables/useVirtualList.d.ts +1 -1
  310. package/dist/types/vue/src/components/visually-hidden/VisuallyHidden.vue.d.ts +2 -2
  311. package/dist/types/vue/src/components/visually-hidden/VisuallyHidden.vue.d.ts.map +1 -1
  312. package/dist/types/vue/src/index.d.ts +6 -4
  313. package/dist/types/vue/src/index.d.ts.map +1 -1
  314. package/dist/types/vue/src/lib/useDirection.d.ts +2 -2
  315. package/dist/types/vue/src/lib/useDirection.d.ts.map +1 -1
  316. package/dist/types/vue/src/locale/index.d.ts +1 -1
  317. package/dist/types/vue/src/locale/index.d.ts.map +1 -1
  318. package/dist/types/vue/src/primitives/accordion/AccordionContent.d.ts +40 -0
  319. package/dist/types/vue/src/primitives/accordion/AccordionContent.d.ts.map +1 -0
  320. package/dist/types/vue/src/primitives/accordion/AccordionHeader.d.ts +33 -0
  321. package/dist/types/vue/src/primitives/accordion/AccordionHeader.d.ts.map +1 -0
  322. package/dist/types/vue/src/primitives/accordion/AccordionItem.d.ts +61 -0
  323. package/dist/types/vue/src/primitives/accordion/AccordionItem.d.ts.map +1 -0
  324. package/dist/types/vue/src/primitives/accordion/AccordionRoot.d.ts +122 -0
  325. package/dist/types/vue/src/primitives/accordion/AccordionRoot.d.ts.map +1 -0
  326. package/dist/types/vue/src/primitives/accordion/AccordionTrigger.d.ts +30 -0
  327. package/dist/types/vue/src/primitives/accordion/AccordionTrigger.d.ts.map +1 -0
  328. package/dist/types/vue/src/primitives/accordion/context.d.ts +27 -0
  329. package/dist/types/vue/src/primitives/accordion/context.d.ts.map +1 -0
  330. package/dist/types/vue/src/primitives/accordion/index.d.ts +7 -0
  331. package/dist/types/vue/src/primitives/accordion/index.d.ts.map +1 -0
  332. package/dist/types/vue/src/primitives/aspect-ratio/AspectRatio.d.ts +42 -0
  333. package/dist/types/vue/src/primitives/aspect-ratio/AspectRatio.d.ts.map +1 -0
  334. package/dist/types/vue/src/primitives/aspect-ratio/index.d.ts +2 -0
  335. package/dist/types/vue/src/primitives/aspect-ratio/index.d.ts.map +1 -0
  336. package/dist/types/vue/src/primitives/checkbox/CheckboxGroupRoot.d.ts +121 -0
  337. package/dist/types/vue/src/primitives/checkbox/CheckboxGroupRoot.d.ts.map +1 -0
  338. package/dist/types/vue/src/primitives/checkbox/CheckboxRoot.d.ts +127 -0
  339. package/dist/types/vue/src/primitives/checkbox/CheckboxRoot.d.ts.map +1 -0
  340. package/dist/types/vue/src/primitives/checkbox/context.d.ts +14 -0
  341. package/dist/types/vue/src/primitives/checkbox/context.d.ts.map +1 -0
  342. package/dist/types/vue/src/primitives/checkbox/index.d.ts +4 -0
  343. package/dist/types/vue/src/primitives/checkbox/index.d.ts.map +1 -0
  344. package/dist/types/vue/src/primitives/collapsible/CollapsibleContent.d.ts +45 -0
  345. package/dist/types/vue/src/primitives/collapsible/CollapsibleContent.d.ts.map +1 -0
  346. package/dist/types/vue/src/primitives/collapsible/CollapsibleRoot.d.ts +81 -0
  347. package/dist/types/vue/src/primitives/collapsible/CollapsibleRoot.d.ts.map +1 -0
  348. package/dist/types/vue/src/primitives/collapsible/CollapsibleTrigger.d.ts +33 -0
  349. package/dist/types/vue/src/primitives/collapsible/CollapsibleTrigger.d.ts.map +1 -0
  350. package/dist/types/vue/src/primitives/collapsible/context.d.ts +10 -0
  351. package/dist/types/vue/src/primitives/collapsible/context.d.ts.map +1 -0
  352. package/dist/types/vue/src/primitives/collapsible/index.d.ts +5 -0
  353. package/dist/types/vue/src/primitives/collapsible/index.d.ts.map +1 -0
  354. package/dist/types/vue/src/primitives/collection/index.d.ts +28 -0
  355. package/dist/types/vue/src/primitives/collection/index.d.ts.map +1 -0
  356. package/dist/types/vue/src/primitives/number-field/NumberFieldDecrement.vue.d.ts +2 -2
  357. package/dist/types/vue/src/primitives/number-field/NumberFieldDecrement.vue.d.ts.map +1 -1
  358. package/dist/types/vue/src/primitives/number-field/NumberFieldIncrement.vue.d.ts +2 -2
  359. package/dist/types/vue/src/primitives/number-field/NumberFieldIncrement.vue.d.ts.map +1 -1
  360. package/dist/types/vue/src/primitives/number-field/NumberFieldInput.vue.d.ts +2 -2
  361. package/dist/types/vue/src/primitives/number-field/NumberFieldInput.vue.d.ts.map +1 -1
  362. package/dist/types/vue/src/primitives/number-field/NumberFieldRoot.vue.d.ts +2 -2
  363. package/dist/types/vue/src/primitives/number-field/NumberFieldRoot.vue.d.ts.map +1 -1
  364. package/dist/types/vue/src/primitives/pagination/PaginationEdge.d.ts +111 -0
  365. package/dist/types/vue/src/primitives/pagination/PaginationEdge.d.ts.map +1 -0
  366. package/dist/types/vue/src/primitives/pagination/PaginationList.d.ts +30 -0
  367. package/dist/types/vue/src/primitives/pagination/PaginationList.d.ts.map +1 -0
  368. package/dist/types/vue/src/primitives/pagination/PaginationListItem.d.ts +42 -0
  369. package/dist/types/vue/src/primitives/pagination/PaginationListItem.d.ts.map +1 -0
  370. package/dist/types/vue/src/primitives/pagination/PaginationRoot.d.ts +114 -0
  371. package/dist/types/vue/src/primitives/pagination/PaginationRoot.d.ts.map +1 -0
  372. package/dist/types/vue/src/primitives/pagination/context.d.ts +11 -0
  373. package/dist/types/vue/src/primitives/pagination/context.d.ts.map +1 -0
  374. package/dist/types/vue/src/primitives/pagination/index.d.ts +6 -0
  375. package/dist/types/vue/src/primitives/pagination/index.d.ts.map +1 -0
  376. package/dist/types/vue/src/primitives/pin-input/PinInputInput.d.ts +52 -0
  377. package/dist/types/vue/src/primitives/pin-input/PinInputInput.d.ts.map +1 -0
  378. package/dist/types/vue/src/primitives/pin-input/PinInputRoot.d.ts +149 -0
  379. package/dist/types/vue/src/primitives/pin-input/PinInputRoot.d.ts.map +1 -0
  380. package/dist/types/vue/src/primitives/pin-input/context.d.ts +20 -0
  381. package/dist/types/vue/src/primitives/pin-input/context.d.ts.map +1 -0
  382. package/dist/types/vue/src/primitives/pin-input/index.d.ts +4 -0
  383. package/dist/types/vue/src/primitives/pin-input/index.d.ts.map +1 -0
  384. package/dist/types/vue/src/primitives/presence/Presence.d.ts +31 -0
  385. package/dist/types/vue/src/primitives/presence/Presence.d.ts.map +1 -0
  386. package/dist/types/vue/src/primitives/presence/index.d.ts +3 -0
  387. package/dist/types/vue/src/primitives/presence/index.d.ts.map +1 -0
  388. package/dist/types/vue/src/primitives/presence/usePresence.d.ts +5 -0
  389. package/dist/types/vue/src/primitives/presence/usePresence.d.ts.map +1 -0
  390. package/dist/types/vue/src/primitives/primitive/Primitive.d.ts +31 -0
  391. package/dist/types/vue/src/primitives/primitive/Primitive.d.ts.map +1 -0
  392. package/dist/types/vue/src/primitives/primitive/Slot.d.ts +6 -0
  393. package/dist/types/vue/src/primitives/primitive/Slot.d.ts.map +1 -0
  394. package/dist/types/vue/src/primitives/primitive/index.d.ts +3 -0
  395. package/dist/types/vue/src/primitives/primitive/index.d.ts.map +1 -0
  396. package/dist/types/vue/src/primitives/progress/ProgressIndicator.vue.d.ts +14 -0
  397. package/dist/types/vue/src/primitives/progress/ProgressIndicator.vue.d.ts.map +1 -0
  398. package/dist/types/vue/src/primitives/progress/ProgressRoot.vue.d.ts +33 -0
  399. package/dist/types/vue/src/primitives/progress/ProgressRoot.vue.d.ts.map +1 -0
  400. package/dist/types/vue/src/primitives/progress/context.d.ts +9 -0
  401. package/dist/types/vue/src/primitives/progress/context.d.ts.map +1 -0
  402. package/dist/types/vue/src/primitives/progress/index.d.ts +4 -0
  403. package/dist/types/vue/src/primitives/progress/index.d.ts.map +1 -0
  404. package/dist/types/vue/src/primitives/radio-group/Radio.d.ts +88 -0
  405. package/dist/types/vue/src/primitives/radio-group/Radio.d.ts.map +1 -0
  406. package/dist/types/vue/src/primitives/radio-group/RadioGroupIndicator.d.ts +43 -0
  407. package/dist/types/vue/src/primitives/radio-group/RadioGroupIndicator.d.ts.map +1 -0
  408. package/dist/types/vue/src/primitives/radio-group/RadioGroupItem.d.ts +85 -0
  409. package/dist/types/vue/src/primitives/radio-group/RadioGroupItem.d.ts.map +1 -0
  410. package/dist/types/vue/src/primitives/radio-group/RadioGroupRoot.d.ts +119 -0
  411. package/dist/types/vue/src/primitives/radio-group/RadioGroupRoot.d.ts.map +1 -0
  412. package/dist/types/vue/src/primitives/radio-group/context.d.ts +19 -0
  413. package/dist/types/vue/src/primitives/radio-group/context.d.ts.map +1 -0
  414. package/dist/types/vue/src/primitives/radio-group/index.d.ts +5 -0
  415. package/dist/types/vue/src/primitives/radio-group/index.d.ts.map +1 -0
  416. package/dist/types/vue/src/primitives/rating/RatingItem.d.ts +42 -0
  417. package/dist/types/vue/src/primitives/rating/RatingItem.d.ts.map +1 -0
  418. package/dist/types/vue/src/primitives/rating/RatingItemIndicator.d.ts +39 -0
  419. package/dist/types/vue/src/primitives/rating/RatingItemIndicator.d.ts.map +1 -0
  420. package/dist/types/vue/src/primitives/rating/RatingRoot.d.ts +159 -0
  421. package/dist/types/vue/src/primitives/rating/RatingRoot.d.ts.map +1 -0
  422. package/dist/types/vue/src/primitives/rating/context.d.ts +16 -0
  423. package/dist/types/vue/src/primitives/rating/context.d.ts.map +1 -0
  424. package/dist/types/vue/src/primitives/rating/index.d.ts +5 -0
  425. package/dist/types/vue/src/primitives/rating/index.d.ts.map +1 -0
  426. package/dist/types/vue/src/primitives/roving-focus/RovingFocusGroup.vue.d.ts +38 -0
  427. package/dist/types/vue/src/primitives/roving-focus/RovingFocusGroup.vue.d.ts.map +1 -0
  428. package/dist/types/vue/src/primitives/roving-focus/RovingFocusItem.vue.d.ts +21 -0
  429. package/dist/types/vue/src/primitives/roving-focus/RovingFocusItem.vue.d.ts.map +1 -0
  430. package/dist/types/vue/src/primitives/roving-focus/context.d.ts +15 -0
  431. package/dist/types/vue/src/primitives/roving-focus/context.d.ts.map +1 -0
  432. package/dist/types/vue/src/primitives/roving-focus/index.d.ts +4 -0
  433. package/dist/types/vue/src/primitives/roving-focus/index.d.ts.map +1 -0
  434. package/dist/types/vue/src/primitives/separator/Separator.vue.d.ts +19 -0
  435. package/dist/types/vue/src/primitives/separator/Separator.vue.d.ts.map +1 -0
  436. package/dist/types/vue/src/primitives/separator/index.d.ts +2 -0
  437. package/dist/types/vue/src/primitives/separator/index.d.ts.map +1 -0
  438. package/dist/types/vue/src/primitives/slider/SliderImpl.d.ts +36 -0
  439. package/dist/types/vue/src/primitives/slider/SliderImpl.d.ts.map +1 -0
  440. package/dist/types/vue/src/primitives/slider/SliderOrientation.d.ts +91 -0
  441. package/dist/types/vue/src/primitives/slider/SliderOrientation.d.ts.map +1 -0
  442. package/dist/types/vue/src/primitives/slider/SliderRoot.d.ts +187 -0
  443. package/dist/types/vue/src/primitives/slider/SliderRoot.d.ts.map +1 -0
  444. package/dist/types/vue/src/primitives/slider/SliderThumb.d.ts +33 -0
  445. package/dist/types/vue/src/primitives/slider/SliderThumb.d.ts.map +1 -0
  446. package/dist/types/vue/src/primitives/slider/SliderTrack.d.ts +33 -0
  447. package/dist/types/vue/src/primitives/slider/SliderTrack.d.ts.map +1 -0
  448. package/dist/types/vue/src/primitives/slider/context.d.ts +22 -0
  449. package/dist/types/vue/src/primitives/slider/context.d.ts.map +1 -0
  450. package/dist/types/vue/src/primitives/slider/index.d.ts +5 -0
  451. package/dist/types/vue/src/primitives/slider/index.d.ts.map +1 -0
  452. package/dist/types/vue/src/primitives/splitter/SplitterGroup.d.ts +90 -0
  453. package/dist/types/vue/src/primitives/splitter/SplitterGroup.d.ts.map +1 -0
  454. package/dist/types/vue/src/primitives/splitter/SplitterPanel.d.ts +113 -0
  455. package/dist/types/vue/src/primitives/splitter/SplitterPanel.d.ts.map +1 -0
  456. package/dist/types/vue/src/primitives/splitter/SplitterResizeHandle.d.ts +85 -0
  457. package/dist/types/vue/src/primitives/splitter/SplitterResizeHandle.d.ts.map +1 -0
  458. package/dist/types/vue/src/primitives/splitter/behaviors.d.ts +22 -0
  459. package/dist/types/vue/src/primitives/splitter/behaviors.d.ts.map +1 -0
  460. package/dist/types/vue/src/primitives/splitter/context.d.ts +23 -0
  461. package/dist/types/vue/src/primitives/splitter/context.d.ts.map +1 -0
  462. package/dist/types/vue/src/primitives/splitter/index.d.ts +6 -0
  463. package/dist/types/vue/src/primitives/splitter/index.d.ts.map +1 -0
  464. package/dist/types/vue/src/primitives/stepper/StepperItem.d.ts +63 -0
  465. package/dist/types/vue/src/primitives/stepper/StepperItem.d.ts.map +1 -0
  466. package/dist/types/vue/src/primitives/stepper/StepperParts.d.ts +130 -0
  467. package/dist/types/vue/src/primitives/stepper/StepperParts.d.ts.map +1 -0
  468. package/dist/types/vue/src/primitives/stepper/StepperRoot.d.ts +91 -0
  469. package/dist/types/vue/src/primitives/stepper/StepperRoot.d.ts.map +1 -0
  470. package/dist/types/vue/src/primitives/stepper/StepperTrigger.d.ts +33 -0
  471. package/dist/types/vue/src/primitives/stepper/StepperTrigger.d.ts.map +1 -0
  472. package/dist/types/vue/src/primitives/stepper/context.d.ts +23 -0
  473. package/dist/types/vue/src/primitives/stepper/context.d.ts.map +1 -0
  474. package/dist/types/vue/src/primitives/stepper/index.d.ts +6 -0
  475. package/dist/types/vue/src/primitives/stepper/index.d.ts.map +1 -0
  476. package/dist/types/vue/src/primitives/switch/SwitchRoot.d.ts +133 -0
  477. package/dist/types/vue/src/primitives/switch/SwitchRoot.d.ts.map +1 -0
  478. package/dist/types/vue/src/primitives/switch/index.d.ts +2 -0
  479. package/dist/types/vue/src/primitives/switch/index.d.ts.map +1 -0
  480. package/dist/types/vue/src/primitives/tabs/TabsContent.d.ts +50 -0
  481. package/dist/types/vue/src/primitives/tabs/TabsContent.d.ts.map +1 -0
  482. package/dist/types/vue/src/primitives/tabs/TabsList.d.ts +42 -0
  483. package/dist/types/vue/src/primitives/tabs/TabsList.d.ts.map +1 -0
  484. package/dist/types/vue/src/primitives/tabs/TabsRoot.d.ts +101 -0
  485. package/dist/types/vue/src/primitives/tabs/TabsRoot.d.ts.map +1 -0
  486. package/dist/types/vue/src/primitives/tabs/TabsTrigger.d.ts +55 -0
  487. package/dist/types/vue/src/primitives/tabs/TabsTrigger.d.ts.map +1 -0
  488. package/dist/types/vue/src/primitives/tabs/context.d.ts +19 -0
  489. package/dist/types/vue/src/primitives/tabs/context.d.ts.map +1 -0
  490. package/dist/types/vue/src/primitives/tabs/index.d.ts +6 -0
  491. package/dist/types/vue/src/primitives/tabs/index.d.ts.map +1 -0
  492. package/dist/types/vue/src/primitives/toggle/Toggle.d.ts +91 -0
  493. package/dist/types/vue/src/primitives/toggle/Toggle.d.ts.map +1 -0
  494. package/dist/types/vue/src/primitives/toggle/index.d.ts +2 -0
  495. package/dist/types/vue/src/primitives/toggle/index.d.ts.map +1 -0
  496. package/dist/types/vue/src/primitives/toggle-group/ToggleGroupItem.d.ts +53 -0
  497. package/dist/types/vue/src/primitives/toggle-group/ToggleGroupItem.d.ts.map +1 -0
  498. package/dist/types/vue/src/primitives/toggle-group/ToggleGroupRoot.d.ts +141 -0
  499. package/dist/types/vue/src/primitives/toggle-group/ToggleGroupRoot.d.ts.map +1 -0
  500. package/dist/types/vue/src/primitives/toggle-group/context.d.ts +16 -0
  501. package/dist/types/vue/src/primitives/toggle-group/context.d.ts.map +1 -0
  502. package/dist/types/vue/src/primitives/toggle-group/index.d.ts +4 -0
  503. package/dist/types/vue/src/primitives/toggle-group/index.d.ts.map +1 -0
  504. package/dist/types/vue/src/primitives/toolbar/ToolbarButton.d.ts +43 -0
  505. package/dist/types/vue/src/primitives/toolbar/ToolbarButton.d.ts.map +1 -0
  506. package/dist/types/vue/src/primitives/toolbar/ToolbarRoot.d.ts +63 -0
  507. package/dist/types/vue/src/primitives/toolbar/ToolbarRoot.d.ts.map +1 -0
  508. package/dist/types/vue/src/primitives/toolbar/ToolbarToggleGroup.d.ts +135 -0
  509. package/dist/types/vue/src/primitives/toolbar/ToolbarToggleGroup.d.ts.map +1 -0
  510. package/dist/types/vue/src/primitives/toolbar/ToolbarToggleItem.d.ts +50 -0
  511. package/dist/types/vue/src/primitives/toolbar/ToolbarToggleItem.d.ts.map +1 -0
  512. package/dist/types/vue/src/primitives/toolbar/context.d.ts +9 -0
  513. package/dist/types/vue/src/primitives/toolbar/context.d.ts.map +1 -0
  514. package/dist/types/vue/src/primitives/toolbar/index.d.ts +6 -0
  515. package/dist/types/vue/src/primitives/toolbar/index.d.ts.map +1 -0
  516. package/dist/types/vue/src/primitives/utils/config.d.ts +2 -0
  517. package/dist/types/vue/src/primitives/utils/config.d.ts.map +1 -0
  518. package/dist/types/vue/src/primitives/utils/createContext.d.ts +2 -0
  519. package/dist/types/vue/src/primitives/utils/createContext.d.ts.map +1 -0
  520. package/dist/types/vue/src/primitives/utils/renderSlotFragments.d.ts +3 -0
  521. package/dist/types/vue/src/primitives/utils/renderSlotFragments.d.ts.map +1 -0
  522. package/dist/types/vue/src/primitives/utils/types.d.ts +2 -0
  523. package/dist/types/vue/src/primitives/utils/types.d.ts.map +1 -0
  524. package/dist/types/vue/src/primitives/utils/useComposing.d.ts +8 -0
  525. package/dist/types/vue/src/primitives/utils/useComposing.d.ts.map +1 -0
  526. package/dist/types/vue/src/primitives/utils/useDirection.d.ts +4 -0
  527. package/dist/types/vue/src/primitives/utils/useDirection.d.ts.map +1 -0
  528. package/dist/types/vue/src/primitives/utils/useEmitAsProps.d.ts +2 -0
  529. package/dist/types/vue/src/primitives/utils/useEmitAsProps.d.ts.map +1 -0
  530. package/dist/types/vue/src/primitives/utils/useFormControl.d.ts +4 -0
  531. package/dist/types/vue/src/primitives/utils/useFormControl.d.ts.map +1 -0
  532. package/dist/types/vue/src/primitives/utils/useForwardExpose.d.ts +7 -0
  533. package/dist/types/vue/src/primitives/utils/useForwardExpose.d.ts.map +1 -0
  534. package/dist/types/vue/src/primitives/utils/useForwardProps.d.ts +3 -0
  535. package/dist/types/vue/src/primitives/utils/useForwardProps.d.ts.map +1 -0
  536. package/dist/types/vue/src/primitives/utils/useForwardPropsEmits.d.ts +3 -0
  537. package/dist/types/vue/src/primitives/utils/useForwardPropsEmits.d.ts.map +1 -0
  538. package/dist/types/vue/src/primitives/utils/useForwardScopeId.d.ts +2 -0
  539. package/dist/types/vue/src/primitives/utils/useForwardScopeId.d.ts.map +1 -0
  540. package/dist/types/vue/src/primitives/utils/useId.d.ts +2 -0
  541. package/dist/types/vue/src/primitives/utils/useId.d.ts.map +1 -0
  542. package/dist/types/vue/src/primitives/utils/useNonce.d.ts +3 -0
  543. package/dist/types/vue/src/primitives/utils/useNonce.d.ts.map +1 -0
  544. package/dist/types/vue/src/primitives/utils/useSingleOrMultipleValue.d.ts +12 -0
  545. package/dist/types/vue/src/primitives/utils/useSingleOrMultipleValue.d.ts.map +1 -0
  546. package/dist/types/vue/src/primitives/utils/useSize.d.ts +7 -0
  547. package/dist/types/vue/src/primitives/utils/useSize.d.ts.map +1 -0
  548. package/dist/types/vue/src/primitives/visually-hidden/VisuallyHidden.vue.d.ts +19 -0
  549. package/dist/types/vue/src/primitives/visually-hidden/VisuallyHidden.vue.d.ts.map +1 -0
  550. package/dist/types/vue/src/primitives/visually-hidden/VisuallyHiddenInput.d.ts +2 -2
  551. package/dist/types/vue/src/primitives/visually-hidden/VisuallyHiddenInput.d.ts.map +1 -1
  552. package/dist/types/vue/src/primitives/visually-hidden/VisuallyHiddenInputBubble.vue.d.ts +1 -1
  553. package/dist/types/vue/src/primitives/visually-hidden/VisuallyHiddenInputBubble.vue.d.ts.map +1 -1
  554. package/dist/types/vue/src/primitives/visually-hidden/index.d.ts +3 -0
  555. package/dist/types/vue/src/primitives/visually-hidden/index.d.ts.map +1 -0
  556. package/package.json +1 -1
  557. package/src/components/accordion/Accordion.vue +2 -1
  558. package/src/components/accordion/AccordionContent.vue +1 -1
  559. package/src/components/accordion/AccordionItem.vue +1 -1
  560. package/src/components/accordion/AccordionTrigger.vue +3 -3
  561. package/src/components/app-shell/AppShell.vue +54 -4
  562. package/src/components/aspect-ratio/AspectRatio.vue +1 -1
  563. package/src/components/breadcrumb/BreadcrumbItem.vue +2 -1
  564. package/src/components/button/Button.vue +2 -1
  565. package/src/components/card/Card.vue +2 -1
  566. package/src/components/checkbox/Checkbox.vue +1 -1
  567. package/src/components/checkbox-group/CheckboxGroup.vue +1 -1
  568. package/src/components/chip/Chip.vue +2 -1
  569. package/src/components/chip/composables/useChipRoot.ts +1 -1
  570. package/src/components/collapsible/Collapsible.vue +2 -1
  571. package/src/components/collapsible/CollapsibleContent.vue +1 -1
  572. package/src/components/collapsible/CollapsibleTrigger.vue +2 -2
  573. package/src/components/command-palette/CommandPalette.vue +53 -16
  574. package/src/components/command-palette/CommandPaletteInput.vue +32 -0
  575. package/src/components/command-palette/CommandPaletteItem.vue +7 -5
  576. package/src/components/command-palette/CommandPalettePanel.vue +95 -34
  577. package/src/components/command-palette/composables/useCommandItems.ts +16 -14
  578. package/src/components/command-palette/context.ts +28 -0
  579. package/src/components/command-palette/types.ts +21 -5
  580. package/src/components/command-palette/utils/match.ts +6 -3
  581. package/src/components/description-list/DescriptionList.vue +8 -2
  582. package/src/components/dialog/Dialog.vue +13 -8
  583. package/src/components/divider/Divider.vue +1 -1
  584. package/src/components/drawer/Drawer.vue +13 -8
  585. package/src/components/float-button/FloatButton.vue +4 -11
  586. package/src/components/float-button/types.ts +3 -2
  587. package/src/components/form/Form.vue +14 -1
  588. package/src/components/form/scope.ts +39 -0
  589. package/src/components/heading/Heading.vue +1 -1
  590. package/src/components/icon-button/IconButton.vue +2 -1
  591. package/src/components/image/Image.vue +1 -1
  592. package/src/components/indicator/Indicator.vue +2 -1
  593. package/src/components/input/InputAction.vue +1 -1
  594. package/src/components/line-clamp/LineClamp.vue +105 -0
  595. package/src/components/line-clamp/line-clamp.variants.ts +1 -0
  596. package/src/components/link/Link.vue +2 -1
  597. package/src/components/multi-select/MultiSelect.vue +4 -1
  598. package/src/components/nav-link/NavLink.vue +33 -4
  599. package/src/components/nav-link/NavLinkChild.ts +57 -0
  600. package/src/components/navigation-menu/NavigationMenuLink.vue +1 -1
  601. package/src/components/pagination/Pagination.vue +1 -1
  602. package/src/components/pagination/PaginationContent.vue +1 -1
  603. package/src/components/pagination/PaginationControl.vue +6 -1
  604. package/src/components/pagination/PaginationPage.vue +1 -1
  605. package/src/components/panel/Panel.vue +1 -1
  606. package/src/components/pin-input/PinInput.vue +1 -1
  607. package/src/components/prev-next/PrevNextLink.vue +2 -1
  608. package/src/components/progress/Progress.vue +1 -1
  609. package/src/components/prose/Prose.vue +2 -1
  610. package/src/components/radio-group/RadioGroup.vue +1 -1
  611. package/src/components/range-slider/RangeSlider.vue +1 -1
  612. package/src/components/rating/Rating.vue +1 -1
  613. package/src/components/ring-progress/RingProgress.vue +1 -1
  614. package/src/components/section/Section.vue +13 -2
  615. package/src/components/segmented-control/SegmentedControl.vue +2 -1
  616. package/src/components/sheet/Sheet.vue +14 -10
  617. package/src/components/sidebar/Sidebar.vue +2 -1
  618. package/src/components/sidebar/context.ts +9 -0
  619. package/src/components/slider/Slider.vue +1 -1
  620. package/src/components/slider/SliderHandle.vue +2 -1
  621. package/src/components/split-button/types.ts +1 -1
  622. package/src/components/splitter/Splitter.vue +1 -1
  623. package/src/components/splitter/SplitterHandle.vue +1 -1
  624. package/src/components/splitter/SplitterPanel.vue +1 -1
  625. package/src/components/statistic/Statistic.vue +2 -2
  626. package/src/components/stepper/Stepper.vue +1 -1
  627. package/src/components/stepper/StepperStep.vue +1 -1
  628. package/src/components/switch/Switch.vue +1 -1
  629. package/src/components/tabs/Tabs.vue +1 -1
  630. package/src/components/tabs/TabsContent.vue +1 -1
  631. package/src/components/tabs/TabsList.vue +1 -1
  632. package/src/components/tabs/TabsTrigger.vue +1 -1
  633. package/src/components/tag/Tag.vue +2 -1
  634. package/src/components/text/Text.vue +2 -1
  635. package/src/components/time/Time.vue +22 -5
  636. package/src/components/toast/Toaster.vue +1 -0
  637. package/src/components/toggle/Toggle.vue +2 -1
  638. package/src/components/toolbar/Toolbar.vue +1 -1
  639. package/src/components/toolbar/ToolbarButton.vue +1 -1
  640. package/src/components/toolbar/ToolbarLink.vue +1 -1
  641. package/src/components/toolbar/ToolbarSeparator.vue +1 -1
  642. package/src/components/toolbar/ToolbarToggleGroup.vue +2 -1
  643. package/src/components/toolbar/ToolbarToggleItem.vue +1 -1
  644. package/src/components/toolbar/types.ts +1 -1
  645. package/src/components/visually-hidden/VisuallyHidden.vue +4 -18
  646. package/src/index.ts +15 -2
  647. package/src/lib/useDirection.ts +2 -1
  648. package/src/locale/index.ts +1 -1
  649. package/src/primitives/accordion/AccordionContent.ts +47 -0
  650. package/src/primitives/accordion/AccordionHeader.ts +35 -0
  651. package/src/primitives/accordion/AccordionItem.ts +83 -0
  652. package/src/primitives/accordion/AccordionRoot.ts +75 -0
  653. package/src/primitives/accordion/AccordionTrigger.ts +55 -0
  654. package/src/primitives/accordion/LICENSE +44 -0
  655. package/src/primitives/accordion/context.ts +34 -0
  656. package/src/primitives/accordion/index.ts +11 -0
  657. package/src/primitives/aspect-ratio/AspectRatio.ts +47 -0
  658. package/src/primitives/aspect-ratio/LICENSE +44 -0
  659. package/src/primitives/aspect-ratio/index.ts +1 -0
  660. package/src/primitives/checkbox/CheckboxGroupRoot.ts +93 -0
  661. package/src/primitives/checkbox/CheckboxRoot.ts +170 -0
  662. package/src/primitives/checkbox/LICENSE +44 -0
  663. package/src/primitives/checkbox/context.ts +20 -0
  664. package/src/primitives/checkbox/index.ts +8 -0
  665. package/src/primitives/collapsible/CollapsibleContent.ts +124 -0
  666. package/src/primitives/collapsible/CollapsibleRoot.ts +63 -0
  667. package/src/primitives/collapsible/CollapsibleTrigger.ts +43 -0
  668. package/src/primitives/collapsible/LICENSE +44 -0
  669. package/src/primitives/collapsible/context.ts +13 -0
  670. package/src/primitives/collapsible/index.ts +12 -0
  671. package/src/primitives/collection/LICENSE +44 -0
  672. package/src/primitives/collection/index.ts +82 -0
  673. package/src/primitives/number-field/NumberFieldDecrement.vue +2 -3
  674. package/src/primitives/number-field/NumberFieldIncrement.vue +2 -3
  675. package/src/primitives/number-field/NumberFieldInput.vue +2 -3
  676. package/src/primitives/number-field/NumberFieldRoot.vue +3 -3
  677. package/src/primitives/pagination/LICENSE +44 -0
  678. package/src/primitives/pagination/PaginationEdge.ts +77 -0
  679. package/src/primitives/pagination/PaginationList.ts +46 -0
  680. package/src/primitives/pagination/PaginationListItem.ts +61 -0
  681. package/src/primitives/pagination/PaginationRoot.ts +73 -0
  682. package/src/primitives/pagination/context.ts +14 -0
  683. package/src/primitives/pagination/index.ts +15 -0
  684. package/src/primitives/pin-input/LICENSE +44 -0
  685. package/src/primitives/pin-input/PinInputInput.ts +218 -0
  686. package/src/primitives/pin-input/PinInputRoot.ts +136 -0
  687. package/src/primitives/pin-input/context.ts +24 -0
  688. package/src/primitives/pin-input/index.ts +3 -0
  689. package/src/primitives/presence/LICENSE +44 -0
  690. package/src/primitives/presence/Presence.ts +70 -0
  691. package/src/primitives/presence/index.ts +2 -0
  692. package/src/primitives/presence/usePresence.ts +28 -0
  693. package/src/primitives/primitive/LICENSE +44 -0
  694. package/src/primitives/primitive/Primitive.ts +45 -0
  695. package/src/primitives/primitive/Slot.ts +22 -0
  696. package/src/primitives/primitive/index.ts +2 -0
  697. package/src/primitives/progress/LICENSE +44 -0
  698. package/src/primitives/progress/ProgressIndicator.vue +24 -0
  699. package/src/primitives/progress/ProgressRoot.vue +95 -0
  700. package/src/primitives/progress/context.ts +12 -0
  701. package/src/primitives/progress/index.ts +7 -0
  702. package/src/primitives/radio-group/LICENSE +44 -0
  703. package/src/primitives/radio-group/Radio.ts +110 -0
  704. package/src/primitives/radio-group/RadioGroupIndicator.ts +54 -0
  705. package/src/primitives/radio-group/RadioGroupItem.ts +116 -0
  706. package/src/primitives/radio-group/RadioGroupRoot.ts +108 -0
  707. package/src/primitives/radio-group/context.ts +25 -0
  708. package/src/primitives/radio-group/index.ts +9 -0
  709. package/src/primitives/rating/LICENSE +44 -0
  710. package/src/primitives/rating/RatingItem.ts +35 -0
  711. package/src/primitives/rating/RatingItemIndicator.ts +87 -0
  712. package/src/primitives/rating/RatingRoot.ts +111 -0
  713. package/src/primitives/rating/context.ts +22 -0
  714. package/src/primitives/rating/index.ts +9 -0
  715. package/src/primitives/roving-focus/LICENSE +44 -0
  716. package/src/primitives/roving-focus/RovingFocusGroup.vue +125 -0
  717. package/src/primitives/roving-focus/RovingFocusItem.vue +99 -0
  718. package/src/primitives/roving-focus/context.ts +18 -0
  719. package/src/primitives/roving-focus/index.ts +7 -0
  720. package/src/primitives/separator/LICENSE +44 -0
  721. package/src/primitives/separator/Separator.vue +26 -0
  722. package/src/primitives/separator/index.ts +1 -0
  723. package/src/primitives/slider/LICENSE +44 -0
  724. package/src/primitives/slider/SliderImpl.ts +66 -0
  725. package/src/primitives/slider/SliderOrientation.ts +100 -0
  726. package/src/primitives/slider/SliderRoot.ts +214 -0
  727. package/src/primitives/slider/SliderThumb.ts +139 -0
  728. package/src/primitives/slider/SliderTrack.ts +37 -0
  729. package/src/primitives/slider/context.ts +31 -0
  730. package/src/primitives/slider/index.ts +8 -0
  731. package/src/primitives/splitter/LICENSE +44 -0
  732. package/src/primitives/splitter/SplitterGroup.ts +642 -0
  733. package/src/primitives/splitter/SplitterPanel.ts +170 -0
  734. package/src/primitives/splitter/SplitterResizeHandle.ts +170 -0
  735. package/src/primitives/splitter/behaviors.ts +173 -0
  736. package/src/primitives/splitter/context.ts +33 -0
  737. package/src/primitives/splitter/index.ts +13 -0
  738. package/src/primitives/stepper/LICENSE +44 -0
  739. package/src/primitives/stepper/StepperItem.ts +68 -0
  740. package/src/primitives/stepper/StepperParts.ts +103 -0
  741. package/src/primitives/stepper/StepperRoot.ts +171 -0
  742. package/src/primitives/stepper/StepperTrigger.ts +119 -0
  743. package/src/primitives/stepper/context.ts +29 -0
  744. package/src/primitives/stepper/index.ts +17 -0
  745. package/src/primitives/switch/LICENSE +44 -0
  746. package/src/primitives/switch/SwitchRoot.ts +151 -0
  747. package/src/primitives/switch/index.ts +6 -0
  748. package/src/primitives/tabs/LICENSE +44 -0
  749. package/src/primitives/tabs/TabsContent.ts +94 -0
  750. package/src/primitives/tabs/TabsList.ts +52 -0
  751. package/src/primitives/tabs/TabsRoot.ts +99 -0
  752. package/src/primitives/tabs/TabsTrigger.ts +97 -0
  753. package/src/primitives/tabs/context.ts +22 -0
  754. package/src/primitives/tabs/index.ts +5 -0
  755. package/src/primitives/toggle/LICENSE +44 -0
  756. package/src/primitives/toggle/Toggle.ts +116 -0
  757. package/src/primitives/toggle/index.ts +1 -0
  758. package/src/primitives/toggle-group/LICENSE +44 -0
  759. package/src/primitives/toggle-group/ToggleGroupItem.ts +80 -0
  760. package/src/primitives/toggle-group/ToggleGroupRoot.ts +113 -0
  761. package/src/primitives/toggle-group/context.ts +19 -0
  762. package/src/primitives/toggle-group/index.ts +7 -0
  763. package/src/primitives/toolbar/LICENSE +44 -0
  764. package/src/primitives/toolbar/ToolbarButton.ts +44 -0
  765. package/src/primitives/toolbar/ToolbarRoot.ts +53 -0
  766. package/src/primitives/toolbar/ToolbarToggleGroup.ts +69 -0
  767. package/src/primitives/toolbar/ToolbarToggleItem.ts +43 -0
  768. package/src/primitives/toolbar/context.ts +12 -0
  769. package/src/primitives/toolbar/index.ts +9 -0
  770. package/src/primitives/utils/config.ts +1 -0
  771. package/src/primitives/utils/createContext.ts +34 -0
  772. package/src/primitives/utils/renderSlotFragments.ts +8 -0
  773. package/src/primitives/utils/types.ts +1 -0
  774. package/src/primitives/utils/useComposing.ts +44 -0
  775. package/src/primitives/utils/useDirection.ts +9 -0
  776. package/src/primitives/utils/useEmitAsProps.ts +13 -0
  777. package/src/primitives/utils/useFormControl.ts +6 -0
  778. package/src/primitives/utils/useForwardExpose.ts +78 -0
  779. package/src/primitives/utils/useForwardProps.ts +29 -0
  780. package/src/primitives/utils/useForwardPropsEmits.ts +12 -0
  781. package/src/primitives/utils/useForwardScopeId.ts +6 -0
  782. package/src/primitives/utils/useId.ts +9 -0
  783. package/src/primitives/utils/useNonce.ts +7 -0
  784. package/src/primitives/utils/useSingleOrMultipleValue.ts +36 -0
  785. package/src/primitives/utils/useSize.ts +25 -0
  786. package/src/primitives/visually-hidden/VisuallyHidden.vue +30 -0
  787. package/src/primitives/visually-hidden/VisuallyHiddenInput.ts +1 -1
  788. package/src/primitives/visually-hidden/VisuallyHiddenInputBubble.vue +2 -2
  789. package/src/primitives/visually-hidden/index.ts +2 -0
@@ -0,0 +1,111 @@
1
+ import {
2
+ computed,
3
+ defineComponent,
4
+ h,
5
+ mergeProps,
6
+ ref,
7
+ renderSlot,
8
+ toRefs,
9
+ withCtx,
10
+ type PropType,
11
+ } from 'vue'
12
+ import { nextRating, ratingItems } from '../../../../shared/src/primitives/rating'
13
+ import type { Orientation } from '../../../../shared/src/primitives/roving-focus'
14
+ import type { PrimitiveProps } from '../primitive'
15
+ import { RadioGroupRoot } from '../radio-group'
16
+ import type { Direction } from '../utils/useDirection'
17
+ import { useForwardExpose } from '../utils/useForwardExpose'
18
+ import { useVModel } from '../utils/useVModel'
19
+ import { provideRatingRootContext } from './context'
20
+
21
+ export interface RatingRootProps {
22
+ defaultValue?: number
23
+ modelValue?: number
24
+ length?: number
25
+ clearable?: boolean
26
+ hoverable?: boolean
27
+ step?: number
28
+ disabled?: boolean
29
+ orientation?: Orientation
30
+ dir?: Direction
31
+ loop?: boolean
32
+ asChild?: boolean
33
+ as?: PrimitiveProps['as']
34
+ name?: string
35
+ required?: boolean
36
+ }
37
+
38
+ export type RatingRootEmits = {
39
+ 'update:modelValue': [value: number]
40
+ }
41
+
42
+ const OMITTED = ['length', 'clearable', 'hoverable', 'step']
43
+
44
+ export const RatingRoot = defineComponent({
45
+ name: 'RatingRoot',
46
+ props: {
47
+ defaultValue: { type: Number, required: false },
48
+ modelValue: { type: Number, required: false },
49
+ length: { type: Number, required: false, default: 5 },
50
+ clearable: { type: Boolean, required: false },
51
+ hoverable: { type: Boolean, required: false },
52
+ step: { type: Number, required: false, default: 1 },
53
+ disabled: { type: Boolean, required: false },
54
+ orientation: { type: String as PropType<Orientation>, required: false, default: 'horizontal' },
55
+ dir: { type: String as PropType<Direction>, required: false },
56
+ loop: { type: Boolean, required: false },
57
+ asChild: { type: Boolean, required: false },
58
+ as: { type: null as unknown as PropType<PrimitiveProps['as']>, required: false },
59
+ name: { type: String, required: false },
60
+ required: { type: Boolean, required: false },
61
+ },
62
+ emits: ['update:modelValue'],
63
+ setup(props, { emit, slots }) {
64
+ const { length, disabled, clearable, hoverable, step } = toRefs(props)
65
+ useForwardExpose()
66
+ const modelValue = useVModel(props, 'modelValue', emit, {
67
+ defaultValue: props.defaultValue,
68
+ passive: props.modelValue === undefined,
69
+ })
70
+ const items = computed(() => ratingItems(length.value))
71
+ const hoveredRating = ref(0)
72
+
73
+ function changeModelValue(rating: number) {
74
+ if (disabled.value) return
75
+ const next = nextRating(clearable.value, modelValue.value, rating)
76
+ if (next === 0) hoveredRating.value = 0
77
+ modelValue.value = next
78
+ }
79
+ function changeHoveredRating(rating: number) {
80
+ if (disabled.value || !hoverable.value) return
81
+ hoveredRating.value = rating
82
+ }
83
+ function resetHoveredRating() {
84
+ hoveredRating.value = 0
85
+ }
86
+
87
+ provideRatingRootContext({
88
+ modelValue,
89
+ items,
90
+ hoveredRating,
91
+ disabled,
92
+ step,
93
+ changeModelValue,
94
+ changeHoveredRating,
95
+ })
96
+
97
+ return () =>
98
+ h(
99
+ RadioGroupRoot,
100
+ mergeProps(
101
+ Object.fromEntries(Object.entries(props).filter(([key]) => !OMITTED.includes(key))),
102
+ { disabled: disabled.value, onMouseleave: resetHoveredRating },
103
+ ),
104
+ {
105
+ default: withCtx(() => [
106
+ renderSlot(slots, 'default', { items: items.value, modelValue: modelValue.value }),
107
+ ]),
108
+ },
109
+ )
110
+ },
111
+ })
@@ -0,0 +1,22 @@
1
+ import type { ComputedRef, Ref } from 'vue'
2
+ import { createContext } from '../utils/createContext'
3
+
4
+ export interface RatingRootContext {
5
+ modelValue: Ref<number | undefined>
6
+ items: ComputedRef<number[]>
7
+ hoveredRating: Ref<number>
8
+ disabled: Ref<boolean>
9
+ step: Ref<number>
10
+ changeModelValue: (value: number) => void
11
+ changeHoveredRating: (value: number) => void
12
+ }
13
+
14
+ export const [injectRatingRootContext, provideRatingRootContext] =
15
+ createContext<RatingRootContext>('RatingRoot')
16
+
17
+ export interface RatingItemContext {
18
+ steps: ComputedRef<number[]>
19
+ }
20
+
21
+ export const [injectRatingItemContext, provideRatingItemContext] =
22
+ createContext<RatingItemContext>('RatingItem')
@@ -0,0 +1,9 @@
1
+ export {
2
+ injectRatingItemContext,
3
+ injectRatingRootContext,
4
+ type RatingItemContext,
5
+ type RatingRootContext,
6
+ } from './context'
7
+ export { RatingItem, type RatingItemProps } from './RatingItem'
8
+ export { RatingItemIndicator, type RatingItemIndicatorProps } from './RatingItemIndicator'
9
+ export { RatingRoot, type RatingRootEmits, type RatingRootProps } from './RatingRoot'
@@ -0,0 +1,44 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2023 UnoVue <https://github.com/unovue>
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
22
+
23
+ Portions adapted from VueUse:
24
+ MIT License
25
+
26
+ Copyright (c) 2019-PRESENT Anthony Fu<https://github.com/antfu>
27
+
28
+ Permission is hereby granted, free of charge, to any person obtaining a copy
29
+ of this software and associated documentation files (the "Software"), to deal
30
+ in the Software without restriction, including without limitation the rights
31
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
32
+ copies of the Software, and to permit persons to whom the Software is
33
+ furnished to do so, subject to the following conditions:
34
+
35
+ The above copyright notice and this permission notice shall be included in all
36
+ copies or substantial portions of the Software.
37
+
38
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
39
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
40
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
41
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
42
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
43
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
44
+ SOFTWARE.
@@ -0,0 +1,125 @@
1
+ <script lang="ts">
2
+ export interface RovingFocusGroupProps extends PrimitiveProps {
3
+ orientation?: Orientation
4
+ dir?: Direction
5
+ loop?: boolean
6
+ currentTabStopId?: string | null
7
+ defaultCurrentTabStopId?: string
8
+ preventScrollOnEntryFocus?: boolean
9
+ }
10
+
11
+ export type RovingFocusGroupEmits = {
12
+ entryFocus: [event: Event]
13
+ 'update:currentTabStopId': [value: string | null | undefined]
14
+ }
15
+ </script>
16
+
17
+ <script setup lang="ts">
18
+ import { ref, toRefs } from 'vue'
19
+ import {
20
+ ENTRY_FOCUS,
21
+ ENTRY_FOCUS_OPTIONS,
22
+ focusFirstCandidate,
23
+ type Orientation,
24
+ } from '../../../../shared/src/primitives/roving-focus'
25
+ import { useCollection } from '../collection'
26
+ import { Primitive, type PrimitiveProps } from '../primitive'
27
+ import { useDirection, type Direction } from '../utils/useDirection'
28
+ import { useVModel } from '../utils/useVModel'
29
+ import { provideRovingFocusGroupContext } from './context'
30
+
31
+ const props = withDefaults(defineProps<RovingFocusGroupProps>(), {
32
+ orientation: undefined,
33
+ loop: false,
34
+ preventScrollOnEntryFocus: false,
35
+ })
36
+ const emits = defineEmits<RovingFocusGroupEmits>()
37
+ const { loop, orientation, dir: propDir } = toRefs(props)
38
+ const dir = useDirection(propDir)
39
+ const currentTabStopId = useVModel(
40
+ props,
41
+ 'currentTabStopId',
42
+ (_, value) => emits('update:currentTabStopId', value),
43
+ {
44
+ defaultValue: props.defaultCurrentTabStopId,
45
+ passive: props.currentTabStopId === undefined,
46
+ },
47
+ )
48
+ const isTabbingBackOut = ref(false)
49
+ const isClickFocus = ref(false)
50
+ const focusableItemsCount = ref(0)
51
+ const { getItems, CollectionSlot } = useCollection({ isProvider: true })
52
+
53
+ function handleFocus(event: FocusEvent) {
54
+ const isKeyboardFocus = !isClickFocus.value
55
+ if (
56
+ event.currentTarget &&
57
+ event.target === event.currentTarget &&
58
+ isKeyboardFocus &&
59
+ !isTabbingBackOut.value
60
+ ) {
61
+ const entryFocusEvent = new CustomEvent(ENTRY_FOCUS, ENTRY_FOCUS_OPTIONS)
62
+ event.currentTarget.dispatchEvent(entryFocusEvent)
63
+ emits('entryFocus', entryFocusEvent)
64
+ if (!entryFocusEvent.defaultPrevented) {
65
+ const items = getItems()
66
+ .map(item => item.ref)
67
+ .filter(item => item.dataset.disabled !== '')
68
+ const activeItem = items.find(item => item.getAttribute('data-active') === '')
69
+ const highlightedItem = items.find(item => item.getAttribute('data-highlighted') === '')
70
+ const currentItem = items.find(item => item.id === currentTabStopId.value)
71
+ const candidates = [activeItem, highlightedItem, currentItem, ...items].filter(
72
+ (item): item is HTMLElement => !!item,
73
+ )
74
+ focusFirstCandidate(candidates, props.preventScrollOnEntryFocus)
75
+ }
76
+ }
77
+ isClickFocus.value = false
78
+ }
79
+
80
+ function handleMouseUp() {
81
+ setTimeout(() => {
82
+ isClickFocus.value = false
83
+ }, 1)
84
+ }
85
+
86
+ defineExpose({ getItems })
87
+
88
+ provideRovingFocusGroupContext({
89
+ loop,
90
+ dir,
91
+ orientation,
92
+ currentTabStopId,
93
+ onItemFocus: tabStopId => {
94
+ currentTabStopId.value = tabStopId
95
+ },
96
+ onItemShiftTab: () => {
97
+ isTabbingBackOut.value = true
98
+ },
99
+ onFocusableItemAdd: () => {
100
+ focusableItemsCount.value++
101
+ },
102
+ onFocusableItemRemove: () => {
103
+ focusableItemsCount.value--
104
+ },
105
+ })
106
+ </script>
107
+
108
+ <template>
109
+ <CollectionSlot>
110
+ <Primitive
111
+ :tabindex="isTabbingBackOut || focusableItemsCount === 0 ? -1 : 0"
112
+ :data-orientation="orientation"
113
+ :as="as"
114
+ :as-child="asChild"
115
+ :dir="dir"
116
+ style="outline: none"
117
+ @mousedown="isClickFocus = true"
118
+ @mouseup="handleMouseUp"
119
+ @focus="handleFocus"
120
+ @blur="isTabbingBackOut = false"
121
+ >
122
+ <slot />
123
+ </Primitive>
124
+ </CollectionSlot>
125
+ </template>
@@ -0,0 +1,99 @@
1
+ <script lang="ts">
2
+ export interface RovingFocusItemProps extends PrimitiveProps {
3
+ tabStopId?: string
4
+ focusable?: boolean
5
+ active?: boolean
6
+ allowShiftKey?: boolean
7
+ }
8
+ </script>
9
+
10
+ <script setup lang="ts">
11
+ import { computed, nextTick, onMounted, onUnmounted, watch } from 'vue'
12
+ import {
13
+ focusFirstCandidate,
14
+ getFocusIntent,
15
+ wrapArray,
16
+ } from '../../../../shared/src/primitives/roving-focus'
17
+ import { useCollection } from '../collection'
18
+ import { Primitive, type PrimitiveProps } from '../primitive'
19
+ import { useId } from '../utils/useId'
20
+ import { injectRovingFocusGroupContext } from './context'
21
+
22
+ const props = withDefaults(defineProps<RovingFocusItemProps>(), {
23
+ focusable: true,
24
+ as: 'span',
25
+ })
26
+ const context = injectRovingFocusGroupContext()
27
+ const randomId = useId()
28
+ const id = computed(() => props.tabStopId || randomId)
29
+ const isCurrentTabStop = computed(() => context.currentTabStopId.value === id.value)
30
+ const { getItems, CollectionItem } = useCollection()
31
+
32
+ onMounted(() => {
33
+ if (props.focusable) context.onFocusableItemAdd()
34
+ })
35
+ onUnmounted(() => {
36
+ if (props.focusable) context.onFocusableItemRemove()
37
+ })
38
+ watch(
39
+ () => props.focusable,
40
+ (value, previous) => {
41
+ if (value === previous) return
42
+ if (value) context.onFocusableItemAdd()
43
+ else context.onFocusableItemRemove()
44
+ },
45
+ )
46
+
47
+ function handleKeydown(event: KeyboardEvent) {
48
+ if (event.key === 'Tab' && event.shiftKey) {
49
+ context.onItemShiftTab()
50
+ return
51
+ }
52
+ if (event.target !== event.currentTarget) return
53
+ const focusIntent = getFocusIntent(event, context.orientation.value, context.dir.value)
54
+ if (focusIntent === undefined) return
55
+ if (
56
+ event.metaKey ||
57
+ event.ctrlKey ||
58
+ event.altKey ||
59
+ (props.allowShiftKey ? false : event.shiftKey)
60
+ )
61
+ return
62
+ event.preventDefault()
63
+ let candidates = getItems()
64
+ .map(item => item.ref)
65
+ .filter(item => item.dataset.disabled !== '')
66
+ if (focusIntent === 'last') candidates.reverse()
67
+ else if (focusIntent === 'prev' || focusIntent === 'next') {
68
+ if (focusIntent === 'prev') candidates.reverse()
69
+ const currentIndex = candidates.indexOf(event.currentTarget as HTMLElement)
70
+ candidates = context.loop.value
71
+ ? wrapArray(candidates, currentIndex + 1)
72
+ : candidates.slice(currentIndex + 1)
73
+ }
74
+ void nextTick(() => focusFirstCandidate(candidates))
75
+ }
76
+ </script>
77
+
78
+ <template>
79
+ <CollectionItem>
80
+ <Primitive
81
+ :tabindex="isCurrentTabStop ? 0 : -1"
82
+ :data-orientation="context.orientation.value"
83
+ :data-active="active ? '' : undefined"
84
+ :data-disabled="!focusable ? '' : undefined"
85
+ :as="as"
86
+ :as-child="asChild"
87
+ @mousedown="
88
+ (event: MouseEvent) => {
89
+ if (!focusable) event.preventDefault()
90
+ else context.onItemFocus(id)
91
+ }
92
+ "
93
+ @focus="context.onItemFocus(id)"
94
+ @keydown="handleKeydown"
95
+ >
96
+ <slot />
97
+ </Primitive>
98
+ </CollectionItem>
99
+ </template>
@@ -0,0 +1,18 @@
1
+ import type { Ref } from 'vue'
2
+ import type { Orientation } from '../../../../shared/src/primitives/roving-focus'
3
+ import { createContext } from '../utils/createContext'
4
+ import type { Direction } from '../utils/useDirection'
5
+
6
+ export interface RovingFocusGroupContext {
7
+ loop: Ref<boolean>
8
+ dir: Ref<Direction>
9
+ orientation: Ref<Orientation | undefined>
10
+ currentTabStopId: Ref<string | null | undefined>
11
+ onItemFocus: (tabStopId: string) => void
12
+ onItemShiftTab: () => void
13
+ onFocusableItemAdd: () => void
14
+ onFocusableItemRemove: () => void
15
+ }
16
+
17
+ export const [injectRovingFocusGroupContext, provideRovingFocusGroupContext] =
18
+ createContext<RovingFocusGroupContext>('RovingFocusGroup')
@@ -0,0 +1,7 @@
1
+ export { injectRovingFocusGroupContext, type RovingFocusGroupContext } from './context'
2
+ export {
3
+ default as RovingFocusGroup,
4
+ type RovingFocusGroupEmits,
5
+ type RovingFocusGroupProps,
6
+ } from './RovingFocusGroup.vue'
7
+ export { default as RovingFocusItem, type RovingFocusItemProps } from './RovingFocusItem.vue'
@@ -0,0 +1,44 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2023 UnoVue <https://github.com/unovue>
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
22
+
23
+ Portions adapted from VueUse:
24
+ MIT License
25
+
26
+ Copyright (c) 2019-PRESENT Anthony Fu<https://github.com/antfu>
27
+
28
+ Permission is hereby granted, free of charge, to any person obtaining a copy
29
+ of this software and associated documentation files (the "Software"), to deal
30
+ in the Software without restriction, including without limitation the rights
31
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
32
+ copies of the Software, and to permit persons to whom the Software is
33
+ furnished to do so, subject to the following conditions:
34
+
35
+ The above copyright notice and this permission notice shall be included in all
36
+ copies or substantial portions of the Software.
37
+
38
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
39
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
40
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
41
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
42
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
43
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
44
+ SOFTWARE.
@@ -0,0 +1,26 @@
1
+ <script lang="ts">
2
+ export interface SeparatorProps extends PrimitiveProps {
3
+ orientation?: SeparatorOrientation
4
+ decorative?: boolean
5
+ }
6
+ </script>
7
+
8
+ <script setup lang="ts">
9
+ import { computed } from 'vue'
10
+ import {
11
+ separatorOrientation,
12
+ separatorSemantics,
13
+ type SeparatorOrientation,
14
+ } from '../../../../shared/src/primitives/separator'
15
+ import { Primitive, type PrimitiveProps } from '../primitive'
16
+
17
+ const props = withDefaults(defineProps<SeparatorProps>(), { orientation: 'horizontal' })
18
+ const orientation = computed(() => separatorOrientation(props.orientation))
19
+ const semantics = computed(() => separatorSemantics(orientation.value, props.decorative))
20
+ </script>
21
+
22
+ <template>
23
+ <Primitive :as="as" :as-child="asChild" :data-orientation="orientation" v-bind="semantics">
24
+ <slot />
25
+ </Primitive>
26
+ </template>
@@ -0,0 +1 @@
1
+ export { default as Separator, type SeparatorProps } from './Separator.vue'
@@ -0,0 +1,44 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2023 UnoVue <https://github.com/unovue>
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
22
+
23
+ Portions adapted from VueUse:
24
+ MIT License
25
+
26
+ Copyright (c) 2019-PRESENT Anthony Fu<https://github.com/antfu>
27
+
28
+ Permission is hereby granted, free of charge, to any person obtaining a copy
29
+ of this software and associated documentation files (the "Software"), to deal
30
+ in the Software without restriction, including without limitation the rights
31
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
32
+ copies of the Software, and to permit persons to whom the Software is
33
+ furnished to do so, subject to the following conditions:
34
+
35
+ The above copyright notice and this permission notice shall be included in all
36
+ copies or substantial portions of the Software.
37
+
38
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
39
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
40
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
41
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
42
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
43
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
44
+ SOFTWARE.
@@ -0,0 +1,66 @@
1
+ import { defineComponent, h, mergeProps, renderSlot, withCtx, type PropType } from 'vue'
2
+ import { ARROW_KEYS, PAGE_KEYS } from '../../../../shared/src/primitives/slider'
3
+ import { Primitive, type PrimitiveProps } from '../primitive'
4
+ import { injectSliderRootContext } from './context'
5
+
6
+ export const SliderImpl = defineComponent({
7
+ name: 'SliderImpl',
8
+ props: {
9
+ asChild: { type: Boolean, required: false },
10
+ as: {
11
+ type: null as unknown as PropType<PrimitiveProps['as']>,
12
+ required: false,
13
+ default: 'span',
14
+ },
15
+ },
16
+ emits: ['slideStart', 'slideMove', 'slideEnd', 'homeKeyDown', 'endKeyDown', 'stepKeyDown'],
17
+ setup(props, { emit, slots }) {
18
+ const rootContext = injectSliderRootContext()
19
+
20
+ function onKeydown(event: KeyboardEvent) {
21
+ if (event.key === 'Home') {
22
+ emit('homeKeyDown', event)
23
+ event.preventDefault()
24
+ } else if (event.key === 'End') {
25
+ emit('endKeyDown', event)
26
+ event.preventDefault()
27
+ } else if (PAGE_KEYS.concat(ARROW_KEYS).includes(event.key)) {
28
+ emit('stepKeyDown', event)
29
+ event.preventDefault()
30
+ }
31
+ }
32
+
33
+ function onPointerdown(event: PointerEvent) {
34
+ const target = event.target as HTMLElement
35
+ target.setPointerCapture(event.pointerId)
36
+ event.preventDefault()
37
+ if (rootContext.thumbElements.value.includes(target)) target.focus()
38
+ else emit('slideStart', event)
39
+ }
40
+
41
+ function onPointermove(event: PointerEvent) {
42
+ const target = event.target as HTMLElement
43
+ if (target.hasPointerCapture(event.pointerId)) emit('slideMove', event)
44
+ }
45
+
46
+ function onPointerup(event: PointerEvent) {
47
+ const target = event.target as HTMLElement
48
+ if (target.hasPointerCapture(event.pointerId)) {
49
+ target.releasePointerCapture(event.pointerId)
50
+ emit('slideEnd', event)
51
+ }
52
+ }
53
+
54
+ return () =>
55
+ h(
56
+ Primitive,
57
+ mergeProps({ 'data-slider-impl': '' }, props, {
58
+ onKeydown,
59
+ onPointerdown,
60
+ onPointermove,
61
+ onPointerup,
62
+ }),
63
+ { default: withCtx(() => [renderSlot(slots, 'default')]) },
64
+ )
65
+ },
66
+ })