@nuxt/ui 4.1.0 → 4.2.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 (391) hide show
  1. package/cli/templates.mjs +2 -2
  2. package/dist/module.d.mts +10 -0
  3. package/dist/module.json +1 -1
  4. package/dist/module.mjs +7 -7
  5. package/dist/runtime/components/Accordion.vue +9 -8
  6. package/dist/runtime/components/Alert.vue +9 -8
  7. package/dist/runtime/components/App.d.vue.ts +1 -1
  8. package/dist/runtime/components/App.vue +2 -1
  9. package/dist/runtime/components/App.vue.d.ts +1 -1
  10. package/dist/runtime/components/AuthForm.d.vue.ts +9 -8
  11. package/dist/runtime/components/AuthForm.vue +28 -20
  12. package/dist/runtime/components/AuthForm.vue.d.ts +9 -8
  13. package/dist/runtime/components/Avatar.d.vue.ts +2 -1
  14. package/dist/runtime/components/Avatar.vue +4 -2
  15. package/dist/runtime/components/Avatar.vue.d.ts +2 -1
  16. package/dist/runtime/components/AvatarGroup.vue +3 -3
  17. package/dist/runtime/components/Badge.vue +5 -5
  18. package/dist/runtime/components/Banner.vue +9 -8
  19. package/dist/runtime/components/BlogPost.vue +19 -10
  20. package/dist/runtime/components/Breadcrumb.vue +9 -9
  21. package/dist/runtime/components/Button.vue +6 -4
  22. package/dist/runtime/components/Calendar.vue +12 -8
  23. package/dist/runtime/components/Card.vue +4 -4
  24. package/dist/runtime/components/Carousel.vue +10 -5
  25. package/dist/runtime/components/ChangelogVersion.vue +22 -14
  26. package/dist/runtime/components/ChangelogVersions.vue +4 -4
  27. package/dist/runtime/components/ChatMessage.vue +7 -7
  28. package/dist/runtime/components/ChatMessages.vue +4 -2
  29. package/dist/runtime/components/ChatPalette.vue +3 -3
  30. package/dist/runtime/components/ChatPrompt.d.vue.ts +3 -6
  31. package/dist/runtime/components/ChatPrompt.vue +23 -14
  32. package/dist/runtime/components/ChatPrompt.vue.d.ts +3 -6
  33. package/dist/runtime/components/ChatPromptSubmit.d.vue.ts +4 -4
  34. package/dist/runtime/components/ChatPromptSubmit.vue +51 -4
  35. package/dist/runtime/components/ChatPromptSubmit.vue.d.ts +4 -4
  36. package/dist/runtime/components/Checkbox.d.vue.ts +2 -1
  37. package/dist/runtime/components/Checkbox.vue +9 -8
  38. package/dist/runtime/components/Checkbox.vue.d.ts +2 -1
  39. package/dist/runtime/components/CheckboxGroup.vue +7 -4
  40. package/dist/runtime/components/Chip.vue +2 -2
  41. package/dist/runtime/components/Collapsible.vue +2 -2
  42. package/dist/runtime/components/ColorPicker.vue +7 -3
  43. package/dist/runtime/components/CommandPalette.vue +62 -37
  44. package/dist/runtime/components/ContextMenuContent.vue +19 -17
  45. package/dist/runtime/components/DashboardNavbar.vue +7 -6
  46. package/dist/runtime/components/DashboardPanel.vue +3 -1
  47. package/dist/runtime/components/DashboardSearch.vue +2 -1
  48. package/dist/runtime/components/DashboardSearchButton.d.vue.ts +2 -3
  49. package/dist/runtime/components/DashboardSearchButton.vue +47 -9
  50. package/dist/runtime/components/DashboardSearchButton.vue.d.ts +2 -3
  51. package/dist/runtime/components/DashboardSidebar.vue +9 -6
  52. package/dist/runtime/components/DashboardSidebarCollapse.d.vue.ts +7 -4
  53. package/dist/runtime/components/DashboardSidebarCollapse.vue +51 -7
  54. package/dist/runtime/components/DashboardSidebarCollapse.vue.d.ts +7 -4
  55. package/dist/runtime/components/DashboardSidebarToggle.d.vue.ts +7 -4
  56. package/dist/runtime/components/DashboardSidebarToggle.vue +52 -7
  57. package/dist/runtime/components/DashboardSidebarToggle.vue.d.ts +7 -4
  58. package/dist/runtime/components/DashboardToolbar.vue +3 -3
  59. package/dist/runtime/components/Drawer.d.vue.ts +1 -1
  60. package/dist/runtime/components/Drawer.vue +9 -9
  61. package/dist/runtime/components/Drawer.vue.d.ts +1 -1
  62. package/dist/runtime/components/DropdownMenu.vue +1 -1
  63. package/dist/runtime/components/DropdownMenuContent.vue +19 -17
  64. package/dist/runtime/components/Empty.vue +8 -8
  65. package/dist/runtime/components/Error.d.vue.ts +1 -1
  66. package/dist/runtime/components/Error.vue +5 -5
  67. package/dist/runtime/components/Error.vue.d.ts +1 -1
  68. package/dist/runtime/components/FileUpload.d.vue.ts +8 -2
  69. package/dist/runtime/components/FileUpload.vue +34 -24
  70. package/dist/runtime/components/FileUpload.vue.d.ts +8 -2
  71. package/dist/runtime/components/Footer.vue +7 -7
  72. package/dist/runtime/components/FooterColumns.vue +11 -11
  73. package/dist/runtime/components/Form.d.vue.ts +3 -2
  74. package/dist/runtime/components/Form.vue +3 -4
  75. package/dist/runtime/components/Form.vue.d.ts +3 -2
  76. package/dist/runtime/components/FormField.vue +8 -8
  77. package/dist/runtime/components/Header.vue +9 -8
  78. package/dist/runtime/components/Input.d.vue.ts +6 -6
  79. package/dist/runtime/components/Input.vue +9 -8
  80. package/dist/runtime/components/Input.vue.d.ts +6 -6
  81. package/dist/runtime/components/InputDate.d.vue.ts +89 -0
  82. package/dist/runtime/components/InputDate.vue +161 -0
  83. package/dist/runtime/components/InputDate.vue.d.ts +89 -0
  84. package/dist/runtime/components/InputMenu.d.vue.ts +6 -127
  85. package/dist/runtime/components/InputMenu.vue +50 -42
  86. package/dist/runtime/components/InputMenu.vue.d.ts +6 -127
  87. package/dist/runtime/components/InputNumber.d.vue.ts +24 -127
  88. package/dist/runtime/components/InputNumber.vue +8 -9
  89. package/dist/runtime/components/InputNumber.vue.d.ts +24 -127
  90. package/dist/runtime/components/InputTags.d.vue.ts +5 -108
  91. package/dist/runtime/components/InputTags.vue +19 -15
  92. package/dist/runtime/components/InputTags.vue.d.ts +5 -108
  93. package/dist/runtime/components/InputTime.d.vue.ts +72 -0
  94. package/dist/runtime/components/InputTime.vue +137 -0
  95. package/dist/runtime/components/InputTime.vue.d.ts +72 -0
  96. package/dist/runtime/components/Link.d.vue.ts +4 -49
  97. package/dist/runtime/components/Link.vue +1 -0
  98. package/dist/runtime/components/Link.vue.d.ts +4 -49
  99. package/dist/runtime/components/Marquee.d.vue.ts +1 -1
  100. package/dist/runtime/components/Marquee.vue +2 -6
  101. package/dist/runtime/components/Marquee.vue.d.ts +1 -1
  102. package/dist/runtime/components/Modal.d.vue.ts +7 -2
  103. package/dist/runtime/components/Modal.vue +52 -16
  104. package/dist/runtime/components/Modal.vue.d.ts +7 -2
  105. package/dist/runtime/components/NavigationMenu.d.vue.ts +44 -9
  106. package/dist/runtime/components/NavigationMenu.vue +73 -43
  107. package/dist/runtime/components/NavigationMenu.vue.d.ts +44 -9
  108. package/dist/runtime/components/Page.vue +4 -4
  109. package/dist/runtime/components/PageAnchors.vue +8 -8
  110. package/dist/runtime/components/PageAside.vue +6 -6
  111. package/dist/runtime/components/PageCTA.vue +9 -9
  112. package/dist/runtime/components/PageCard.vue +11 -10
  113. package/dist/runtime/components/PageFeature.vue +6 -6
  114. package/dist/runtime/components/PageHeader.vue +7 -7
  115. package/dist/runtime/components/PageHero.vue +10 -10
  116. package/dist/runtime/components/PageLinks.vue +8 -8
  117. package/dist/runtime/components/PageLogos.vue +6 -3
  118. package/dist/runtime/components/PageSection.vue +13 -13
  119. package/dist/runtime/components/Pagination.d.vue.ts +2 -2
  120. package/dist/runtime/components/Pagination.vue +8 -8
  121. package/dist/runtime/components/Pagination.vue.d.ts +2 -2
  122. package/dist/runtime/components/PinInput.d.vue.ts +2 -2
  123. package/dist/runtime/components/PinInput.vue +2 -0
  124. package/dist/runtime/components/PinInput.vue.d.ts +2 -2
  125. package/dist/runtime/components/Popover.vue +2 -2
  126. package/dist/runtime/components/PricingPlan.vue +28 -21
  127. package/dist/runtime/components/PricingTable.vue +35 -31
  128. package/dist/runtime/components/Progress.d.vue.ts +1 -1
  129. package/dist/runtime/components/Progress.vue +6 -6
  130. package/dist/runtime/components/Progress.vue.d.ts +1 -1
  131. package/dist/runtime/components/RadioGroup.d.vue.ts +5 -5
  132. package/dist/runtime/components/RadioGroup.vue +13 -11
  133. package/dist/runtime/components/RadioGroup.vue.d.ts +5 -5
  134. package/dist/runtime/components/Select.d.vue.ts +5 -106
  135. package/dist/runtime/components/Select.vue +26 -23
  136. package/dist/runtime/components/Select.vue.d.ts +5 -106
  137. package/dist/runtime/components/SelectMenu.d.vue.ts +6 -105
  138. package/dist/runtime/components/SelectMenu.vue +54 -40
  139. package/dist/runtime/components/SelectMenu.vue.d.ts +6 -105
  140. package/dist/runtime/components/Separator.vue +7 -7
  141. package/dist/runtime/components/Slideover.d.vue.ts +2 -2
  142. package/dist/runtime/components/Slideover.vue +9 -7
  143. package/dist/runtime/components/Slideover.vue.d.ts +2 -2
  144. package/dist/runtime/components/Slider.vue +5 -4
  145. package/dist/runtime/components/Stepper.vue +12 -10
  146. package/dist/runtime/components/Switch.d.vue.ts +2 -1
  147. package/dist/runtime/components/Switch.vue +10 -9
  148. package/dist/runtime/components/Switch.vue.d.ts +2 -1
  149. package/dist/runtime/components/Table.d.vue.ts +7 -6
  150. package/dist/runtime/components/Table.vue +37 -18
  151. package/dist/runtime/components/Table.vue.d.ts +7 -6
  152. package/dist/runtime/components/Tabs.vue +10 -7
  153. package/dist/runtime/components/Textarea.d.vue.ts +6 -5
  154. package/dist/runtime/components/Textarea.vue +9 -8
  155. package/dist/runtime/components/Textarea.vue.d.ts +6 -5
  156. package/dist/runtime/components/Timeline.vue +16 -7
  157. package/dist/runtime/components/Toast.vue +15 -12
  158. package/dist/runtime/components/Toaster.d.vue.ts +1 -1
  159. package/dist/runtime/components/Toaster.vue +2 -0
  160. package/dist/runtime/components/Toaster.vue.d.ts +1 -1
  161. package/dist/runtime/components/Tooltip.vue +4 -4
  162. package/dist/runtime/components/Tree.d.vue.ts +1 -1
  163. package/dist/runtime/components/Tree.vue +18 -11
  164. package/dist/runtime/components/Tree.vue.d.ts +1 -1
  165. package/dist/runtime/components/User.vue +13 -6
  166. package/dist/runtime/components/color-mode/ColorModeAvatar.d.vue.ts +3 -3
  167. package/dist/runtime/components/color-mode/ColorModeAvatar.vue +16 -4
  168. package/dist/runtime/components/color-mode/ColorModeAvatar.vue.d.ts +3 -3
  169. package/dist/runtime/components/color-mode/ColorModeButton.d.vue.ts +6 -13
  170. package/dist/runtime/components/color-mode/ColorModeButton.vue +59 -18
  171. package/dist/runtime/components/color-mode/ColorModeButton.vue.d.ts +6 -13
  172. package/dist/runtime/components/color-mode/ColorModeImage.d.vue.ts +4 -3
  173. package/dist/runtime/components/color-mode/ColorModeImage.vue +4 -0
  174. package/dist/runtime/components/color-mode/ColorModeImage.vue.d.ts +4 -3
  175. package/dist/runtime/components/color-mode/ColorModeSelect.d.vue.ts +5 -3
  176. package/dist/runtime/components/color-mode/ColorModeSelect.vue +45 -5
  177. package/dist/runtime/components/color-mode/ColorModeSelect.vue.d.ts +5 -3
  178. package/dist/runtime/components/color-mode/ColorModeSwitch.d.vue.ts +2 -2
  179. package/dist/runtime/components/color-mode/ColorModeSwitch.vue +29 -5
  180. package/dist/runtime/components/color-mode/ColorModeSwitch.vue.d.ts +2 -2
  181. package/dist/runtime/components/content/ContentNavigation.vue +13 -12
  182. package/dist/runtime/components/content/ContentSearch.vue +60 -65
  183. package/dist/runtime/components/content/ContentSearchButton.d.vue.ts +2 -3
  184. package/dist/runtime/components/content/ContentSearchButton.vue +47 -9
  185. package/dist/runtime/components/content/ContentSearchButton.vue.d.ts +2 -3
  186. package/dist/runtime/components/content/ContentSurround.vue +6 -6
  187. package/dist/runtime/components/content/ContentToc.vue +15 -15
  188. package/dist/runtime/components/locale/LocaleSelect.d.vue.ts +10 -6
  189. package/dist/runtime/components/locale/LocaleSelect.vue +54 -6
  190. package/dist/runtime/components/locale/LocaleSelect.vue.d.ts +10 -6
  191. package/dist/runtime/composables/index.d.ts +8 -0
  192. package/dist/runtime/composables/index.js +8 -0
  193. package/dist/runtime/composables/useAvatarGroup.d.ts +1 -1
  194. package/dist/runtime/composables/useContentSearch.d.ts +5 -0
  195. package/dist/runtime/composables/useContentSearch.js +31 -1
  196. package/dist/runtime/composables/useFieldGroup.d.ts +1 -1
  197. package/dist/runtime/composables/useFileUpload.d.ts +2 -1
  198. package/dist/runtime/composables/useFileUpload.js +13 -4
  199. package/dist/runtime/composables/useFormField.d.ts +1 -1
  200. package/dist/runtime/index.css +1 -1
  201. package/dist/runtime/inertia/components/Link.d.vue.ts +17 -10
  202. package/dist/runtime/inertia/components/Link.vue +7 -6
  203. package/dist/runtime/inertia/components/Link.vue.d.ts +17 -10
  204. package/dist/runtime/inertia/stubs.js +1 -1
  205. package/dist/runtime/keyframes.css +1 -1
  206. package/dist/runtime/locale/gl.d.ts +3 -0
  207. package/dist/runtime/locale/gl.js +129 -0
  208. package/dist/runtime/locale/index.d.ts +2 -0
  209. package/dist/runtime/locale/index.js +2 -0
  210. package/dist/runtime/locale/sq.d.ts +3 -0
  211. package/dist/runtime/locale/sq.js +129 -0
  212. package/dist/runtime/plugins/colors.js +8 -6
  213. package/dist/runtime/types/html.d.ts +8 -0
  214. package/dist/runtime/types/html.js +0 -0
  215. package/dist/runtime/types/index.d.ts +5 -0
  216. package/dist/runtime/types/index.js +5 -0
  217. package/dist/runtime/types/input.d.ts +5 -5
  218. package/dist/runtime/types/utils.d.ts +2 -0
  219. package/dist/runtime/utils/content.d.ts +2 -2
  220. package/dist/runtime/utils/link.d.ts +1 -0
  221. package/dist/runtime/utils/link.js +40 -24
  222. package/dist/runtime/utils/virtualizer.d.ts +6 -0
  223. package/dist/runtime/utils/virtualizer.js +30 -0
  224. package/dist/runtime/vue/components/Link.d.vue.ts +8 -37
  225. package/dist/runtime/vue/components/Link.vue +5 -10
  226. package/dist/runtime/vue/components/Link.vue.d.ts +8 -37
  227. package/dist/runtime/vue/components/color-mode/ColorModeSelect.d.vue.ts +5 -3
  228. package/dist/runtime/vue/components/color-mode/ColorModeSelect.vue +44 -3
  229. package/dist/runtime/vue/components/color-mode/ColorModeSelect.vue.d.ts +5 -3
  230. package/dist/runtime/vue/components/color-mode/ColorModeSwitch.d.vue.ts +1 -1
  231. package/dist/runtime/vue/components/color-mode/ColorModeSwitch.vue +24 -3
  232. package/dist/runtime/vue/components/color-mode/ColorModeSwitch.vue.d.ts +1 -1
  233. package/dist/runtime/vue/stubs.d.ts +1 -1
  234. package/dist/runtime/vue/stubs.js +1 -1
  235. package/dist/shared/{ui.Cmctwxv6.mjs → ui.B77q-Dvh.mjs} +397 -153
  236. package/dist/unplugin.d.mts +1 -0
  237. package/dist/unplugin.mjs +31 -3
  238. package/dist/vite.mjs +5 -3
  239. package/package.json +39 -34
  240. package/.nuxt/ui/accordion.ts +0 -20
  241. package/.nuxt/ui/alert.ts +0 -264
  242. package/.nuxt/ui/auth-form.ts +0 -20
  243. package/.nuxt/ui/avatar-group.ts +0 -52
  244. package/.nuxt/ui/avatar.ts +0 -54
  245. package/.nuxt/ui/badge.ts +0 -263
  246. package/.nuxt/ui/banner.ts +0 -108
  247. package/.nuxt/ui/blog-post.ts +0 -142
  248. package/.nuxt/ui/blog-posts.ts +0 -9
  249. package/.nuxt/ui/breadcrumb.ts +0 -45
  250. package/.nuxt/ui/button.ts +0 -378
  251. package/.nuxt/ui/calendar.ts +0 -315
  252. package/.nuxt/ui/card.ts +0 -34
  253. package/.nuxt/ui/carousel.ts +0 -38
  254. package/.nuxt/ui/changelog-version.ts +0 -41
  255. package/.nuxt/ui/changelog-versions.ts +0 -8
  256. package/.nuxt/ui/chat-message.ts +0 -136
  257. package/.nuxt/ui/chat-messages.ts +0 -14
  258. package/.nuxt/ui/chat-palette.ts +0 -8
  259. package/.nuxt/ui/chat-prompt-submit.ts +0 -5
  260. package/.nuxt/ui/chat-prompt.ts +0 -35
  261. package/.nuxt/ui/checkbox-group.ts +0 -204
  262. package/.nuxt/ui/checkbox.ts +0 -236
  263. package/.nuxt/ui/chip.ts +0 -96
  264. package/.nuxt/ui/collapsible.ts +0 -6
  265. package/.nuxt/ui/color-picker.ts +0 -47
  266. package/.nuxt/ui/command-palette.ts +0 -62
  267. package/.nuxt/ui/container.ts +0 -3
  268. package/.nuxt/ui/content/content-navigation.ts +0 -368
  269. package/.nuxt/ui/content/content-search-button.ts +0 -6
  270. package/.nuxt/ui/content/content-search.ts +0 -13
  271. package/.nuxt/ui/content/content-surround.ts +0 -34
  272. package/.nuxt/ui/content/content-toc.ts +0 -155
  273. package/.nuxt/ui/context-menu.ts +0 -219
  274. package/.nuxt/ui/dashboard-group.ts +0 -3
  275. package/.nuxt/ui/dashboard-navbar.ts +0 -21
  276. package/.nuxt/ui/dashboard-panel.ts +0 -17
  277. package/.nuxt/ui/dashboard-resize-handle.ts +0 -3
  278. package/.nuxt/ui/dashboard-search-button.ts +0 -6
  279. package/.nuxt/ui/dashboard-search.ts +0 -13
  280. package/.nuxt/ui/dashboard-sidebar-collapse.ts +0 -9
  281. package/.nuxt/ui/dashboard-sidebar-toggle.ts +0 -9
  282. package/.nuxt/ui/dashboard-sidebar.ts +0 -37
  283. package/.nuxt/ui/dashboard-toolbar.ts +0 -7
  284. package/.nuxt/ui/drawer.ts +0 -149
  285. package/.nuxt/ui/dropdown-menu.ts +0 -220
  286. package/.nuxt/ui/empty.ts +0 -83
  287. package/.nuxt/ui/error.ts +0 -9
  288. package/.nuxt/ui/field-group.ts +0 -16
  289. package/.nuxt/ui/file-upload.ts +0 -290
  290. package/.nuxt/ui/footer-columns.ts +0 -28
  291. package/.nuxt/ui/footer.ts +0 -11
  292. package/.nuxt/ui/form-field.ts +0 -48
  293. package/.nuxt/ui/form.ts +0 -3
  294. package/.nuxt/ui/header.ts +0 -25
  295. package/.nuxt/ui/index.ts +0 -106
  296. package/.nuxt/ui/input-menu.ts +0 -460
  297. package/.nuxt/ui/input-number.ts +0 -256
  298. package/.nuxt/ui/input-tags.ts +0 -310
  299. package/.nuxt/ui/input.ts +0 -289
  300. package/.nuxt/ui/kbd.ts +0 -195
  301. package/.nuxt/ui/link.ts +0 -22
  302. package/.nuxt/ui/main.ts +0 -3
  303. package/.nuxt/ui/marquee.ts +0 -66
  304. package/.nuxt/ui/modal.ts +0 -29
  305. package/.nuxt/ui/navigation-menu.ts +0 -510
  306. package/.nuxt/ui/page-anchors.ts +0 -30
  307. package/.nuxt/ui/page-aside.ts +0 -10
  308. package/.nuxt/ui/page-body.ts +0 -3
  309. package/.nuxt/ui/page-card.ts +0 -279
  310. package/.nuxt/ui/page-columns.ts +0 -3
  311. package/.nuxt/ui/page-cta.ts +0 -70
  312. package/.nuxt/ui/page-feature.ts +0 -26
  313. package/.nuxt/ui/page-grid.ts +0 -3
  314. package/.nuxt/ui/page-header.ts +0 -18
  315. package/.nuxt/ui/page-hero.ts +0 -44
  316. package/.nuxt/ui/page-links.ts +0 -25
  317. package/.nuxt/ui/page-list.ts +0 -8
  318. package/.nuxt/ui/page-logos.ts +0 -15
  319. package/.nuxt/ui/page-section.ts +0 -84
  320. package/.nuxt/ui/page.ts +0 -32
  321. package/.nuxt/ui/pagination.ts +0 -13
  322. package/.nuxt/ui/pin-input.ts +0 -171
  323. package/.nuxt/ui/popover.ts +0 -6
  324. package/.nuxt/ui/pricing-plan.ts +0 -101
  325. package/.nuxt/ui/pricing-plans.ts +0 -22
  326. package/.nuxt/ui/pricing-table.ts +0 -51
  327. package/.nuxt/ui/progress.ts +0 -297
  328. package/.nuxt/ui/prose/a.ts +0 -6
  329. package/.nuxt/ui/prose/accordion-item.ts +0 -3
  330. package/.nuxt/ui/prose/accordion.ts +0 -6
  331. package/.nuxt/ui/prose/badge.ts +0 -3
  332. package/.nuxt/ui/prose/blockquote.ts +0 -3
  333. package/.nuxt/ui/prose/callout.ts +0 -129
  334. package/.nuxt/ui/prose/card-group.ts +0 -3
  335. package/.nuxt/ui/prose/card.ts +0 -119
  336. package/.nuxt/ui/prose/code-collapse.ts +0 -19
  337. package/.nuxt/ui/prose/code-group.ts +0 -13
  338. package/.nuxt/ui/prose/code-icon.ts +0 -66
  339. package/.nuxt/ui/prose/code-preview.ts +0 -14
  340. package/.nuxt/ui/prose/code-tree.ts +0 -28
  341. package/.nuxt/ui/prose/code.ts +0 -27
  342. package/.nuxt/ui/prose/collapsible.ts +0 -12
  343. package/.nuxt/ui/prose/em.ts +0 -3
  344. package/.nuxt/ui/prose/field-group.ts +0 -3
  345. package/.nuxt/ui/prose/field.ts +0 -11
  346. package/.nuxt/ui/prose/h1.ts +0 -6
  347. package/.nuxt/ui/prose/h2.ts +0 -14
  348. package/.nuxt/ui/prose/h3.ts +0 -14
  349. package/.nuxt/ui/prose/h4.ts +0 -6
  350. package/.nuxt/ui/prose/hr.ts +0 -3
  351. package/.nuxt/ui/prose/icon.ts +0 -3
  352. package/.nuxt/ui/prose/img.ts +0 -23
  353. package/.nuxt/ui/prose/index.ts +0 -41
  354. package/.nuxt/ui/prose/kbd.ts +0 -3
  355. package/.nuxt/ui/prose/li.ts +0 -3
  356. package/.nuxt/ui/prose/ol.ts +0 -3
  357. package/.nuxt/ui/prose/p.ts +0 -3
  358. package/.nuxt/ui/prose/pre.ts +0 -17
  359. package/.nuxt/ui/prose/steps.ts +0 -19
  360. package/.nuxt/ui/prose/strong.ts +0 -3
  361. package/.nuxt/ui/prose/table.ts +0 -6
  362. package/.nuxt/ui/prose/tabs-item.ts +0 -3
  363. package/.nuxt/ui/prose/tabs.ts +0 -5
  364. package/.nuxt/ui/prose/tbody.ts +0 -3
  365. package/.nuxt/ui/prose/td.ts +0 -3
  366. package/.nuxt/ui/prose/th.ts +0 -3
  367. package/.nuxt/ui/prose/thead.ts +0 -3
  368. package/.nuxt/ui/prose/tr.ts +0 -3
  369. package/.nuxt/ui/prose/ul.ts +0 -3
  370. package/.nuxt/ui/radio-group.ts +0 -350
  371. package/.nuxt/ui/select-menu.ts +0 -361
  372. package/.nuxt/ui/select.ts +0 -348
  373. package/.nuxt/ui/separator.ts +0 -172
  374. package/.nuxt/ui/skeleton.ts +0 -3
  375. package/.nuxt/ui/slideover.ts +0 -71
  376. package/.nuxt/ui/slider.ts +0 -171
  377. package/.nuxt/ui/stepper.ts +0 -202
  378. package/.nuxt/ui/switch.ts +0 -131
  379. package/.nuxt/ui/table.ts +0 -162
  380. package/.nuxt/ui/tabs.ts +0 -258
  381. package/.nuxt/ui/textarea.ts +0 -294
  382. package/.nuxt/ui/timeline.ts +0 -321
  383. package/.nuxt/ui/toast.ts +0 -74
  384. package/.nuxt/ui/toaster.ts +0 -91
  385. package/.nuxt/ui/tooltip.ts +0 -9
  386. package/.nuxt/ui/tree.ts +0 -168
  387. package/.nuxt/ui/user.ts +0 -101
  388. package/.nuxt/ui.css +0 -146
  389. package/dist/runtime/vue/components/color-mode/ColorModeButton.d.vue.ts +0 -17
  390. package/dist/runtime/vue/components/color-mode/ColorModeButton.vue +0 -35
  391. package/dist/runtime/vue/components/color-mode/ColorModeButton.vue.d.ts +0 -17
@@ -3,7 +3,7 @@ import theme from "#build/ui/input-menu";
3
3
  </script>
4
4
 
5
5
  <script setup>
6
- import { computed, ref, toRef, onMounted, toRaw, nextTick } from "vue";
6
+ import { computed, useTemplateRef, toRef, onMounted, toRaw, nextTick } from "vue";
7
7
  import { ComboboxRoot, ComboboxArrow, ComboboxAnchor, ComboboxInput, ComboboxTrigger, ComboboxPortal, ComboboxContent, ComboboxEmpty, ComboboxGroup, ComboboxVirtualizer, ComboboxLabel, ComboboxSeparator, ComboboxItem, ComboboxItemIndicator, TagsInputRoot, TagsInputItem, TagsInputItemText, TagsInputItemDelete, TagsInputInput, useForwardPropsEmits, useFilter } from "reka-ui";
8
8
  import { defu } from "defu";
9
9
  import { isEqual } from "ohash/utils";
@@ -15,6 +15,7 @@ import { useFormField } from "../composables/useFormField";
15
15
  import { useLocale } from "../composables/useLocale";
16
16
  import { usePortal } from "../composables/usePortal";
17
17
  import { compare, get, getDisplayValue, isArrayOfArray } from "../utils";
18
+ import { getEstimateSize } from "../utils/virtualizer";
18
19
  import { tv } from "../utils/tv";
19
20
  import UIcon from "./Icon.vue";
20
21
  import UAvatar from "./Avatar.vue";
@@ -78,15 +79,12 @@ const rootProps = useForwardPropsEmits(reactivePick(props, "as", "modelValue", "
78
79
  const portalProps = usePortal(toRef(() => props.portal));
79
80
  const contentProps = toRef(() => defu(props.content, { side: "bottom", sideOffset: 8, collisionPadding: 8, position: "popper" }));
80
81
  const arrowProps = toRef(() => props.arrow);
81
- const virtualizerProps = toRef(() => !!props.virtualize && defu(typeof props.virtualize === "boolean" ? {} : props.virtualize, {
82
- estimateSize: {
83
- xs: 24,
84
- sm: 28,
85
- md: 32,
86
- lg: 36,
87
- xl: 40
88
- }[props.size || "md"]
89
- }));
82
+ const virtualizerProps = toRef(() => {
83
+ if (!props.virtualize) return false;
84
+ return defu(typeof props.virtualize === "boolean" ? {} : props.virtualize, {
85
+ estimateSize: getEstimateSize(items.value, inputSize.value || "md", props.descriptionKey)
86
+ });
87
+ });
90
88
  const { emitFormBlur, emitFormFocus, emitFormChange, emitFormInput, size: formGroupSize, color, id, name, highlight, disabled, ariaAttrs } = useFormField(props);
91
89
  const { orientation, size: fieldGroupSize } = useFieldGroup(props);
92
90
  const { isLeading, isTrailing, leadingIconName, trailingIconName } = useComponentIcons(toRef(() => defu(props, { trailingIcon: appConfig.ui.icons.chevronDown })));
@@ -161,7 +159,7 @@ const createItem = computed(() => {
161
159
  return !filteredItems.value.length;
162
160
  });
163
161
  const createItemPosition = computed(() => typeof props.createItem === "object" ? props.createItem.position : "bottom");
164
- const inputRef = ref(null);
162
+ const inputRef = useTemplateRef("inputRef");
165
163
  function autoFocus() {
166
164
  if (props.autofocus) {
167
165
  inputRef.value?.$el?.focus();
@@ -222,6 +220,11 @@ function onRemoveTag(event, modelValue) {
222
220
  onUpdate(filteredValue);
223
221
  }
224
222
  }
223
+ function onCreate(e) {
224
+ e.preventDefault();
225
+ e.stopPropagation();
226
+ emits("create", searchTerm.value);
227
+ }
225
228
  function onSelect(e, item) {
226
229
  if (!isInputItem(item)) {
227
230
  return;
@@ -236,18 +239,19 @@ function isInputItem(item) {
236
239
  return typeof item === "object" && item !== null;
237
240
  }
238
241
  defineExpose({
239
- inputRef
242
+ inputRef: toRef(() => inputRef.value?.$el)
240
243
  });
241
244
  </script>
242
245
 
243
246
  <template>
244
247
  <DefineCreateItemTemplate>
245
248
  <ComboboxItem
249
+ data-slot="item"
246
250
  :class="ui.item({ class: props.ui?.item })"
247
251
  :value="searchTerm"
248
- @select.prevent="emits('create', searchTerm)"
252
+ @select="onCreate"
249
253
  >
250
- <span :class="ui.itemLabel({ class: props.ui?.itemLabel })">
254
+ <span data-slot="itemLabel" :class="ui.itemLabel({ class: props.ui?.itemLabel })">
251
255
  <slot name="create-item-label" :item="searchTerm">
252
256
  {{ t("inputMenu.create", { label: searchTerm }) }}
253
257
  </slot>
@@ -256,14 +260,15 @@ defineExpose({
256
260
  </DefineCreateItemTemplate>
257
261
 
258
262
  <DefineItemTemplate v-slot="{ item, index }">
259
- <ComboboxLabel v-if="isInputItem(item) && item.type === 'label'" :class="ui.label({ class: [props.ui?.label, item.ui?.label, item.class] })">
263
+ <ComboboxLabel v-if="isInputItem(item) && item.type === 'label'" data-slot="label" :class="ui.label({ class: [props.ui?.label, item.ui?.label, item.class] })">
260
264
  {{ get(item, props.labelKey) }}
261
265
  </ComboboxLabel>
262
266
 
263
- <ComboboxSeparator v-else-if="isInputItem(item) && item.type === 'separator'" :class="ui.separator({ class: [props.ui?.separator, item.ui?.separator, item.class] })" />
267
+ <ComboboxSeparator v-else-if="isInputItem(item) && item.type === 'separator'" data-slot="separator" :class="ui.separator({ class: [props.ui?.separator, item.ui?.separator, item.class] })" />
264
268
 
265
269
  <ComboboxItem
266
270
  v-else
271
+ data-slot="item"
267
272
  :class="ui.item({ class: [props.ui?.item, isInputItem(item) && item.ui?.item, isInputItem(item) && item.class] })"
268
273
  :disabled="isInputItem(item) && item.disabled"
269
274
  :value="props.valueKey && isInputItem(item) ? get(item, props.valueKey) : item"
@@ -271,37 +276,38 @@ defineExpose({
271
276
  >
272
277
  <slot name="item" :item="item" :index="index" :ui="ui">
273
278
  <slot name="item-leading" :item="item" :index="index" :ui="ui">
274
- <UIcon v-if="isInputItem(item) && item.icon" :name="item.icon" :class="ui.itemLeadingIcon({ class: [props.ui?.itemLeadingIcon, item.ui?.itemLeadingIcon] })" />
275
- <UAvatar v-else-if="isInputItem(item) && item.avatar" :size="item.ui?.itemLeadingAvatarSize || props.ui?.itemLeadingAvatarSize || ui.itemLeadingAvatarSize()" v-bind="item.avatar" :class="ui.itemLeadingAvatar({ class: [props.ui?.itemLeadingAvatar, item.ui?.itemLeadingAvatar] })" />
279
+ <UIcon v-if="isInputItem(item) && item.icon" :name="item.icon" data-slot="itemLeadingIcon" :class="ui.itemLeadingIcon({ class: [props.ui?.itemLeadingIcon, item.ui?.itemLeadingIcon] })" />
280
+ <UAvatar v-else-if="isInputItem(item) && item.avatar" :size="item.ui?.itemLeadingAvatarSize || props.ui?.itemLeadingAvatarSize || ui.itemLeadingAvatarSize()" v-bind="item.avatar" data-slot="itemLeadingAvatar" :class="ui.itemLeadingAvatar({ class: [props.ui?.itemLeadingAvatar, item.ui?.itemLeadingAvatar] })" />
276
281
  <UChip
277
282
  v-else-if="isInputItem(item) && item.chip"
278
283
  :size="item.ui?.itemLeadingChipSize || props.ui?.itemLeadingChipSize || ui.itemLeadingChipSize()"
279
284
  inset
280
285
  standalone
281
286
  v-bind="item.chip"
287
+ data-slot="itemLeadingChip"
282
288
  :class="ui.itemLeadingChip({ class: [props.ui?.itemLeadingChip, item.ui?.itemLeadingChip] })"
283
289
  />
284
290
  </slot>
285
291
 
286
- <span :class="ui.itemWrapper({ class: [props.ui?.itemWrapper, isInputItem(item) && item.ui?.itemWrapper] })">
287
- <span :class="ui.itemLabel({ class: [props.ui?.itemLabel, isInputItem(item) && item.ui?.itemLabel] })">
292
+ <span data-slot="itemWrapper" :class="ui.itemWrapper({ class: [props.ui?.itemWrapper, isInputItem(item) && item.ui?.itemWrapper] })">
293
+ <span data-slot="itemLabel" :class="ui.itemLabel({ class: [props.ui?.itemLabel, isInputItem(item) && item.ui?.itemLabel] })">
288
294
  <slot name="item-label" :item="item" :index="index">
289
295
  {{ isInputItem(item) ? get(item, props.labelKey) : item }}
290
296
  </slot>
291
297
  </span>
292
298
 
293
- <span v-if="isInputItem(item) && (get(item, props.descriptionKey) || !!slots['item-description'])" :class="ui.itemDescription({ class: [props.ui?.itemDescription, isInputItem(item) && item.ui?.itemDescription] })">
299
+ <span v-if="isInputItem(item) && (get(item, props.descriptionKey) || !!slots['item-description'])" data-slot="itemDescription" :class="ui.itemDescription({ class: [props.ui?.itemDescription, isInputItem(item) && item.ui?.itemDescription] })">
294
300
  <slot name="item-description" :item="item" :index="index">
295
301
  {{ get(item, props.descriptionKey) }}
296
302
  </slot>
297
303
  </span>
298
304
  </span>
299
305
 
300
- <span :class="ui.itemTrailing({ class: [props.ui?.itemTrailing, isInputItem(item) && item.ui?.itemTrailing] })">
306
+ <span data-slot="itemTrailing" :class="ui.itemTrailing({ class: [props.ui?.itemTrailing, isInputItem(item) && item.ui?.itemTrailing] })">
301
307
  <slot name="item-trailing" :item="item" :index="index" :ui="ui" />
302
308
 
303
309
  <ComboboxItemIndicator as-child>
304
- <UIcon :name="selectedIcon || appConfig.ui.icons.check" :class="ui.itemTrailingIcon({ class: [props.ui?.itemTrailingIcon, isInputItem(item) && item.ui?.itemTrailingIcon] })" />
310
+ <UIcon :name="selectedIcon || appConfig.ui.icons.check" data-slot="itemTrailingIcon" :class="ui.itemTrailingIcon({ class: [props.ui?.itemTrailingIcon, isInputItem(item) && item.ui?.itemTrailingIcon] })" />
305
311
  </ComboboxItemIndicator>
306
312
  </span>
307
313
  </slot>
@@ -313,14 +319,14 @@ defineExpose({
313
319
  v-bind="rootProps"
314
320
  :name="name"
315
321
  :disabled="disabled"
322
+ data-slot="root"
316
323
  :class="ui.root({ class: [props.ui?.root, props.class] })"
317
324
  :as-child="!!multiple"
318
325
  ignore-filter
319
326
  @update:model-value="onUpdate"
320
327
  @update:open="onUpdateOpen"
321
- @keydown.enter="$event.preventDefault()"
322
328
  >
323
- <ComboboxAnchor :as-child="!multiple" :class="ui.base({ class: props.ui?.base })">
329
+ <ComboboxAnchor :as-child="!multiple" data-slot="base" :class="ui.base({ class: props.ui?.base })">
324
330
  <TagsInputRoot
325
331
  v-if="multiple"
326
332
  v-slot="{ modelValue: tags }"
@@ -333,16 +339,16 @@ defineExpose({
333
339
  @focus="onFocus"
334
340
  @remove-tag="onRemoveTag($event, modelValue)"
335
341
  >
336
- <TagsInputItem v-for="(item, index) in tags" :key="index" :value="item" :class="ui.tagsItem({ class: [props.ui?.tagsItem, isInputItem(item) && item.ui?.tagsItem] })">
337
- <TagsInputItemText :class="ui.tagsItemText({ class: [props.ui?.tagsItemText, isInputItem(item) && item.ui?.tagsItemText] })">
342
+ <TagsInputItem v-for="(item, index) in tags" :key="index" :value="item" data-slot="tagsItem" :class="ui.tagsItem({ class: [props.ui?.tagsItem, isInputItem(item) && item.ui?.tagsItem] })">
343
+ <TagsInputItemText data-slot="tagsItemText" :class="ui.tagsItemText({ class: [props.ui?.tagsItemText, isInputItem(item) && item.ui?.tagsItemText] })">
338
344
  <slot name="tags-item-text" :item="item" :index="index">
339
345
  {{ displayValue(item) }}
340
346
  </slot>
341
347
  </TagsInputItemText>
342
348
 
343
- <TagsInputItemDelete :class="ui.tagsItemDelete({ class: [props.ui?.tagsItemDelete, isInputItem(item) && item.ui?.tagsItemDelete] })" :disabled="disabled">
349
+ <TagsInputItemDelete data-slot="tagsItemDelete" :class="ui.tagsItemDelete({ class: [props.ui?.tagsItemDelete, isInputItem(item) && item.ui?.tagsItemDelete] })" :disabled="disabled">
344
350
  <slot name="tags-item-delete" :item="item" :index="index" :ui="ui">
345
- <UIcon :name="deleteIcon || appConfig.ui.icons.close" :class="ui.tagsItemDeleteIcon({ class: [props.ui?.tagsItemDeleteIcon, isInputItem(item) && item.ui?.tagsItemDeleteIcon] })" />
351
+ <UIcon :name="deleteIcon || appConfig.ui.icons.close" data-slot="tagsItemDeleteIcon" :class="ui.tagsItemDeleteIcon({ class: [props.ui?.tagsItemDeleteIcon, isInputItem(item) && item.ui?.tagsItemDeleteIcon] })" />
346
352
  </slot>
347
353
  </TagsInputItemDelete>
348
354
  </TagsInputItem>
@@ -353,8 +359,9 @@ defineExpose({
353
359
  ref="inputRef"
354
360
  v-bind="{ ...$attrs, ...ariaAttrs }"
355
361
  :placeholder="placeholder"
362
+ data-slot="tagsInput"
356
363
  :class="ui.tagsInput({ class: props.ui?.tagsInput })"
357
- @keydown.enter.prevent
364
+ @change.stop
358
365
  />
359
366
  </ComboboxInput>
360
367
  </TagsInputRoot>
@@ -370,34 +377,35 @@ defineExpose({
370
377
  :required="required"
371
378
  @blur="onBlur"
372
379
  @focus="onFocus"
380
+ @change.stop
373
381
  @update:model-value="searchTerm = $event"
374
382
  />
375
383
 
376
- <span v-if="isLeading || !!avatar || !!slots.leading" :class="ui.leading({ class: props.ui?.leading })">
384
+ <span v-if="isLeading || !!avatar || !!slots.leading" data-slot="leading" :class="ui.leading({ class: props.ui?.leading })">
377
385
  <slot name="leading" :model-value="modelValue" :open="open" :ui="ui">
378
- <UIcon v-if="isLeading && leadingIconName" :name="leadingIconName" :class="ui.leadingIcon({ class: props.ui?.leadingIcon })" />
379
- <UAvatar v-else-if="!!avatar" :size="props.ui?.itemLeadingAvatarSize || ui.itemLeadingAvatarSize()" v-bind="avatar" :class="ui.itemLeadingAvatar({ class: props.ui?.itemLeadingAvatar })" />
386
+ <UIcon v-if="isLeading && leadingIconName" :name="leadingIconName" data-slot="leadingIcon" :class="ui.leadingIcon({ class: props.ui?.leadingIcon })" />
387
+ <UAvatar v-else-if="!!avatar" :size="props.ui?.itemLeadingAvatarSize || ui.itemLeadingAvatarSize()" v-bind="avatar" data-slot="itemLeadingAvatar" :class="ui.itemLeadingAvatar({ class: props.ui?.itemLeadingAvatar })" />
380
388
  </slot>
381
389
  </span>
382
390
 
383
- <ComboboxTrigger v-if="isTrailing || !!slots.trailing" :class="ui.trailing({ class: props.ui?.trailing })">
391
+ <ComboboxTrigger v-if="isTrailing || !!slots.trailing" data-slot="trailing" :class="ui.trailing({ class: props.ui?.trailing })">
384
392
  <slot name="trailing" :model-value="modelValue" :open="open" :ui="ui">
385
- <UIcon v-if="trailingIconName" :name="trailingIconName" :class="ui.trailingIcon({ class: props.ui?.trailingIcon })" />
393
+ <UIcon v-if="trailingIconName" :name="trailingIconName" data-slot="trailingIcon" :class="ui.trailingIcon({ class: props.ui?.trailingIcon })" />
386
394
  </slot>
387
395
  </ComboboxTrigger>
388
396
  </ComboboxAnchor>
389
397
 
390
398
  <ComboboxPortal v-bind="portalProps">
391
- <ComboboxContent :class="ui.content({ class: props.ui?.content })" v-bind="contentProps" @focus-outside.prevent>
399
+ <ComboboxContent data-slot="content" :class="ui.content({ class: props.ui?.content })" v-bind="contentProps" @focus-outside.prevent>
392
400
  <slot name="content-top" />
393
401
 
394
- <ComboboxEmpty :class="ui.empty({ class: props.ui?.empty })">
402
+ <ComboboxEmpty data-slot="empty" :class="ui.empty({ class: props.ui?.empty })">
395
403
  <slot name="empty" :search-term="searchTerm">
396
404
  {{ searchTerm ? t("inputMenu.noMatch", { searchTerm }) : t("inputMenu.noData") }}
397
405
  </slot>
398
406
  </ComboboxEmpty>
399
407
 
400
- <div role="presentation" :class="ui.viewport({ class: props.ui?.viewport })">
408
+ <div role="presentation" data-slot="viewport" :class="ui.viewport({ class: props.ui?.viewport })">
401
409
  <template v-if="!!virtualize">
402
410
  <ReuseCreateItemTemplate v-if="createItem && createItemPosition === 'top'" />
403
411
 
@@ -414,15 +422,15 @@ defineExpose({
414
422
  </template>
415
423
 
416
424
  <template v-else>
417
- <ComboboxGroup v-if="createItem && createItemPosition === 'top'" :class="ui.group({ class: props.ui?.group })">
425
+ <ComboboxGroup v-if="createItem && createItemPosition === 'top'" data-slot="group" :class="ui.group({ class: props.ui?.group })">
418
426
  <ReuseCreateItemTemplate />
419
427
  </ComboboxGroup>
420
428
 
421
- <ComboboxGroup v-for="(group, groupIndex) in filteredGroups" :key="`group-${groupIndex}`" :class="ui.group({ class: props.ui?.group })">
429
+ <ComboboxGroup v-for="(group, groupIndex) in filteredGroups" :key="`group-${groupIndex}`" data-slot="group" :class="ui.group({ class: props.ui?.group })">
422
430
  <ReuseItemTemplate v-for="(item, index) in group" :key="`group-${groupIndex}-${index}`" :item="item" :index="index" />
423
431
  </ComboboxGroup>
424
432
 
425
- <ComboboxGroup v-if="createItem && createItemPosition === 'bottom'" :class="ui.group({ class: props.ui?.group })">
433
+ <ComboboxGroup v-if="createItem && createItemPosition === 'bottom'" data-slot="group" :class="ui.group({ class: props.ui?.group })">
426
434
  <ReuseCreateItemTemplate />
427
435
  </ComboboxGroup>
428
436
  </template>
@@ -430,7 +438,7 @@ defineExpose({
430
438
 
431
439
  <slot name="content-bottom" />
432
440
 
433
- <ComboboxArrow v-if="!!arrow" v-bind="arrowProps" :class="ui.arrow({ class: props.ui?.arrow })" />
441
+ <ComboboxArrow v-if="!!arrow" v-bind="arrowProps" data-slot="arrow" :class="ui.arrow({ class: props.ui?.arrow })" />
434
442
  </ComboboxContent>
435
443
  </ComboboxPortal>
436
444
  </ComboboxRoot>
@@ -1,10 +1,9 @@
1
- import { nextTick } from 'vue';
2
- import type { InputHTMLAttributes } from 'vue';
3
1
  import type { ComboboxRootProps, ComboboxRootEmits, ComboboxContentProps, ComboboxContentEmits, ComboboxArrowProps } from 'reka-ui';
4
2
  import type { AppConfig } from '@nuxt/schema';
5
3
  import theme from '#build/ui/input-menu';
6
4
  import type { UseComponentIconsProps } from '../composables/useComponentIcons';
7
5
  import type { AvatarProps, ChipProps, IconProps } from '../types';
6
+ import type { InputHTMLAttributes } from '../types/html';
8
7
  import type { AcceptableValue, ArrayOrNested, GetItemKeys, GetModelValue, GetModelValueEmits, NestedItem, EmitsToProps } from '../types/utils';
9
8
  import type { ComponentConfig } from '../types/tv';
10
9
  type InputMenu = ComponentConfig<typeof theme, AppConfig, 'inputMenu'>;
@@ -29,7 +28,7 @@ export type InputMenuItem = InputMenuValue | {
29
28
  ui?: Pick<InputMenu['slots'], 'tagsItem' | 'tagsItemText' | 'tagsItemDelete' | 'tagsItemDeleteIcon' | 'label' | 'separator' | 'item' | 'itemLeadingIcon' | 'itemLeadingAvatarSize' | 'itemLeadingAvatar' | 'itemLeadingChip' | 'itemLeadingChipSize' | 'itemWrapper' | 'itemLabel' | 'itemDescription' | 'itemTrailing' | 'itemTrailingIcon'>;
30
29
  [key: string]: any;
31
30
  };
32
- export interface InputMenuProps<T extends ArrayOrNested<InputMenuItem> = ArrayOrNested<InputMenuItem>, VK extends GetItemKeys<T> | undefined = undefined, M extends boolean = false> extends Pick<ComboboxRootProps<T>, 'open' | 'defaultOpen' | 'disabled' | 'name' | 'resetSearchTermOnBlur' | 'resetSearchTermOnSelect' | 'highlightOnHover' | 'openOnClick' | 'openOnFocus'>, UseComponentIconsProps {
31
+ export interface InputMenuProps<T extends ArrayOrNested<InputMenuItem> = ArrayOrNested<InputMenuItem>, VK extends GetItemKeys<T> | undefined = undefined, M extends boolean = false> extends Pick<ComboboxRootProps<T>, 'open' | 'defaultOpen' | 'disabled' | 'name' | 'resetSearchTermOnBlur' | 'resetSearchTermOnSelect' | 'highlightOnHover' | 'openOnClick' | 'openOnFocus'>, UseComponentIconsProps, /** @vue-ignore */ Omit<InputHTMLAttributes, 'disabled' | 'name' | 'type' | 'placeholder' | 'autofocus' | 'maxlength' | 'minlength' | 'pattern' | 'size' | 'min' | 'max' | 'step'> {
33
32
  /**
34
33
  * The element or component this component should render as.
35
34
  * @defaultValue 'div'
@@ -209,11 +208,11 @@ declare const __VLS_export: <T extends ArrayOrNested<InputMenuItem>, VK extends
209
208
  props: __VLS_PrettifyLocal<(InputMenuProps<T, VK, M> & {
210
209
  searchTerm?: string;
211
210
  }) & {
212
- onBlur?: ((event: FocusEvent) => any) | undefined;
213
211
  onChange?: ((event: Event) => any) | undefined;
212
+ onBlur?: ((event: FocusEvent) => any) | undefined;
214
213
  onFocus?: ((event: FocusEvent) => any) | undefined;
215
- onCreate?: ((item: string) => any) | undefined;
216
214
  "onUpdate:open"?: ((value: boolean) => any) | undefined;
215
+ onCreate?: ((item: string) => any) | undefined;
217
216
  "onUpdate:modelValue"?: ((value: GetModelValue<T, VK, M>) => any) | undefined;
218
217
  onHighlight?: ((payload: {
219
218
  ref: HTMLElement;
@@ -223,131 +222,11 @@ declare const __VLS_export: <T extends ArrayOrNested<InputMenuItem>, VK extends
223
222
  "onRemove-tag"?: ((item: GetModelValue<T, VK, M>) => any) | undefined;
224
223
  }> & import("vue").PublicProps;
225
224
  expose: (exposed: import("vue").ShallowUnwrapRef<{
226
- inputRef: import("vue").Ref<({
227
- $: import("vue").ComponentInternalInstance;
228
- $data: {};
229
- $props: {
230
- readonly displayValue?: ((val: any) => string) | undefined;
231
- readonly modelValue?: string | undefined;
232
- readonly autoFocus?: boolean | undefined;
233
- readonly disabled?: boolean | undefined;
234
- readonly asChild?: boolean | undefined;
235
- readonly as?: (import("reka-ui").AsTag | import("vue").Component) | undefined;
236
- readonly "onUpdate:modelValue"?: ((args_0: string) => any) | undefined | undefined;
237
- } & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps;
238
- $attrs: {
239
- [x: string]: unknown;
240
- };
241
- $refs: {
242
- [x: string]: unknown;
243
- };
244
- $slots: Readonly<{
245
- [name: string]: import("vue").Slot<any> | undefined;
246
- }>;
247
- $root: import("vue").ComponentPublicInstance | null;
248
- $parent: import("vue").ComponentPublicInstance | null;
249
- $host: Element | null;
250
- $emit: (event: "update:modelValue", args_0: string) => void;
251
- $el: any;
252
- $options: import("vue").ComponentOptionsBase<Readonly<import("reka-ui").ComboboxInputProps> & Readonly<{
253
- "onUpdate:modelValue"?: ((args_0: string) => any) | undefined;
254
- }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
255
- "update:modelValue": (args_0: string) => any;
256
- }, string, {
257
- as: import("reka-ui").AsTag | import("vue").Component;
258
- }, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & {
259
- beforeCreate?: (() => void) | (() => void)[];
260
- created?: (() => void) | (() => void)[];
261
- beforeMount?: (() => void) | (() => void)[];
262
- mounted?: (() => void) | (() => void)[];
263
- beforeUpdate?: (() => void) | (() => void)[];
264
- updated?: (() => void) | (() => void)[];
265
- activated?: (() => void) | (() => void)[];
266
- deactivated?: (() => void) | (() => void)[];
267
- beforeDestroy?: (() => void) | (() => void)[];
268
- beforeUnmount?: (() => void) | (() => void)[];
269
- destroyed?: (() => void) | (() => void)[];
270
- unmounted?: (() => void) | (() => void)[];
271
- renderTracked?: ((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[];
272
- renderTriggered?: ((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[];
273
- errorCaptured?: ((err: unknown, instance: import("vue").ComponentPublicInstance | null, info: string) => boolean | void) | ((err: unknown, instance: import("vue").ComponentPublicInstance | null, info: string) => boolean | void)[];
274
- };
275
- $forceUpdate: () => void;
276
- $nextTick: typeof nextTick;
277
- $watch<T_1 extends string | ((...args: any) => any)>(source: T_1, cb: T_1 extends (...args: any) => infer R ? (...args: [R, R, import("@vue/reactivity").OnCleanup]) => any : (...args: [any, any, import("@vue/reactivity").OnCleanup]) => any, options?: import("vue").WatchOptions): import("vue").WatchStopHandle;
278
- } & Readonly<{
279
- as: import("reka-ui").AsTag | import("vue").Component;
280
- }> & Omit<Readonly<import("reka-ui").ComboboxInputProps> & Readonly<{
281
- "onUpdate:modelValue"?: ((args_0: string) => any) | undefined;
282
- }>, "as"> & import("vue").ShallowUnwrapRef<{}> & {} & import("vue").ComponentCustomProperties & {} & {
283
- $slots: {
284
- default?: (props: {}) => any;
285
- };
286
- }) | null, ({
287
- $: import("vue").ComponentInternalInstance;
288
- $data: {};
289
- $props: {
290
- readonly displayValue?: ((val: any) => string) | undefined;
291
- readonly modelValue?: string | undefined;
292
- readonly autoFocus?: boolean | undefined;
293
- readonly disabled?: boolean | undefined;
294
- readonly asChild?: boolean | undefined;
295
- readonly as?: (import("reka-ui").AsTag | import("vue").Component) | undefined;
296
- readonly "onUpdate:modelValue"?: ((args_0: string) => any) | undefined | undefined;
297
- } & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps;
298
- $attrs: {
299
- [x: string]: unknown;
300
- };
301
- $refs: {
302
- [x: string]: unknown;
303
- };
304
- $slots: Readonly<{
305
- [name: string]: import("vue").Slot<any> | undefined;
306
- }>;
307
- $root: import("vue").ComponentPublicInstance | null;
308
- $parent: import("vue").ComponentPublicInstance | null;
309
- $host: Element | null;
310
- $emit: (event: "update:modelValue", args_0: string) => void;
311
- $el: any;
312
- $options: import("vue").ComponentOptionsBase<Readonly<import("reka-ui").ComboboxInputProps> & Readonly<{
313
- "onUpdate:modelValue"?: ((args_0: string) => any) | undefined;
314
- }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
315
- "update:modelValue": (args_0: string) => any;
316
- }, string, {
317
- as: import("reka-ui").AsTag | import("vue").Component;
318
- }, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & {
319
- beforeCreate?: (() => void) | (() => void)[];
320
- created?: (() => void) | (() => void)[];
321
- beforeMount?: (() => void) | (() => void)[];
322
- mounted?: (() => void) | (() => void)[];
323
- beforeUpdate?: (() => void) | (() => void)[];
324
- updated?: (() => void) | (() => void)[];
325
- activated?: (() => void) | (() => void)[];
326
- deactivated?: (() => void) | (() => void)[];
327
- beforeDestroy?: (() => void) | (() => void)[];
328
- beforeUnmount?: (() => void) | (() => void)[];
329
- destroyed?: (() => void) | (() => void)[];
330
- unmounted?: (() => void) | (() => void)[];
331
- renderTracked?: ((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[];
332
- renderTriggered?: ((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[];
333
- errorCaptured?: ((err: unknown, instance: import("vue").ComponentPublicInstance | null, info: string) => boolean | void) | ((err: unknown, instance: import("vue").ComponentPublicInstance | null, info: string) => boolean | void)[];
334
- };
335
- $forceUpdate: () => void;
336
- $nextTick: typeof nextTick;
337
- $watch<T_1 extends string | ((...args: any) => any)>(source: T_1, cb: T_1 extends (...args: any) => infer R ? (...args: [R, R, import("@vue/reactivity").OnCleanup]) => any : (...args: [any, any, import("@vue/reactivity").OnCleanup]) => any, options?: import("vue").WatchOptions): import("vue").WatchStopHandle;
338
- } & Readonly<{
339
- as: import("reka-ui").AsTag | import("vue").Component;
340
- }> & Omit<Readonly<import("reka-ui").ComboboxInputProps> & Readonly<{
341
- "onUpdate:modelValue"?: ((args_0: string) => any) | undefined;
342
- }>, "as"> & import("vue").ShallowUnwrapRef<{}> & {} & import("vue").ComponentCustomProperties & {} & {
343
- $slots: {
344
- default?: (props: {}) => any;
345
- };
346
- }) | null>;
225
+ inputRef: Readonly<import("vue").Ref<HTMLInputElement, HTMLInputElement>>;
347
226
  }>) => void;
348
227
  attrs: any;
349
228
  slots: InputMenuSlots<T, VK, M, NestedItem<T>>;
350
- emit: (((evt: "blur", event: FocusEvent) => void) & ((evt: "change", event: Event) => void) & ((evt: "focus", event: FocusEvent) => void) & ((evt: "create", item: string) => void) & ((evt: "update:open", value: boolean) => void) & ((evt: "update:modelValue", value: GetModelValue<T, VK, M>) => void) & ((evt: "highlight", payload: {
229
+ emit: (((evt: "change", event: Event) => void) & ((evt: "blur", event: FocusEvent) => void) & ((evt: "focus", event: FocusEvent) => void) & ((evt: "update:open", value: boolean) => void) & ((evt: "create", item: string) => void) & ((evt: "update:modelValue", value: GetModelValue<T, VK, M>) => void) & ((evt: "highlight", payload: {
351
230
  ref: HTMLElement;
352
231
  value: GetModelValue<T, VK, M>;
353
232
  } | undefined) => void) & ((evt: "remove-tag", item: GetModelValue<T, VK, M>) => void)) & ((evt: "update:searchTerm", value: string) => void);
@@ -2,10 +2,12 @@ import type { NumberFieldRootProps } from 'reka-ui';
2
2
  import type { AppConfig } from '@nuxt/schema';
3
3
  import theme from '#build/ui/input-number';
4
4
  import type { ButtonProps, IconProps } from '../types';
5
+ import type { InputHTMLAttributes } from '../types/html';
5
6
  import type { ModelModifiers } from '../types/input';
6
7
  import type { ComponentConfig } from '../types/tv';
7
8
  type InputNumber = ComponentConfig<typeof theme, AppConfig, 'inputNumber'>;
8
- export interface InputNumberProps extends Pick<NumberFieldRootProps, 'modelValue' | 'defaultValue' | 'min' | 'max' | 'step' | 'stepSnapping' | 'disabled' | 'required' | 'id' | 'name' | 'formatOptions' | 'disableWheelChange' | 'invertWheelChange' | 'readonly'> {
9
+ type InputNumberValue = number | null;
10
+ export interface InputNumberProps<T extends InputNumberValue = InputNumberValue> extends Pick<NumberFieldRootProps, 'modelValue' | 'defaultValue' | 'min' | 'max' | 'step' | 'stepSnapping' | 'disabled' | 'required' | 'id' | 'name' | 'formatOptions' | 'disableWheelChange' | 'invertWheelChange' | 'readonly'>, /** @vue-ignore */ Omit<InputHTMLAttributes, 'disabled' | 'min' | 'max' | 'readonly' | 'required' | 'step' | 'name' | 'placeholder' | 'type' | 'autofocus' | 'maxlength' | 'minlength' | 'pattern' | 'size'> {
9
11
  /**
10
12
  * The element or component this component should render as.
11
13
  * @defaultValue 'div'
@@ -51,17 +53,12 @@ export interface InputNumberProps extends Pick<NumberFieldRootProps, 'modelValue
51
53
  decrementDisabled?: boolean;
52
54
  autofocus?: boolean;
53
55
  autofocusDelay?: number;
54
- modelModifiers?: Pick<ModelModifiers, 'optional'>;
55
- /**
56
- * The locale to use for formatting and parsing numbers.
57
- * @defaultValue UApp.locale.code
58
- */
59
- locale?: string;
56
+ modelModifiers?: Pick<ModelModifiers<T>, 'optional'>;
60
57
  class?: any;
61
58
  ui?: InputNumber['slots'];
62
59
  }
63
- export interface InputNumberEmits {
64
- 'update:modelValue': [value: number];
60
+ export interface InputNumberEmits<T extends InputNumberValue = InputNumberValue> {
61
+ 'update:modelValue': [value: T];
65
62
  'blur': [event: FocusEvent];
66
63
  'change': [event: Event];
67
64
  }
@@ -69,123 +66,23 @@ export interface InputNumberSlots {
69
66
  increment(props?: {}): any;
70
67
  decrement(props?: {}): any;
71
68
  }
72
- declare const __VLS_export: __VLS_WithSlots<import("vue").DefineComponent<InputNumberProps, {
73
- inputRef: import("vue").Ref<({
74
- $: import("vue").ComponentInternalInstance;
75
- $data: {};
76
- $props: {
77
- readonly asChild?: boolean | undefined;
78
- readonly as?: (import("reka-ui").AsTag | import("vue").Component) | undefined;
79
- } & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps;
80
- $attrs: {
81
- [x: string]: unknown;
82
- };
83
- $refs: {
84
- [x: string]: unknown;
85
- };
86
- $slots: Readonly<{
87
- [name: string]: import("vue").Slot<any> | undefined;
88
- }>;
89
- $root: import("vue").ComponentPublicInstance | null;
90
- $parent: import("vue").ComponentPublicInstance | null;
91
- $host: Element | null;
92
- $emit: (event: string, ...args: any[]) => void;
93
- $el: any;
94
- $options: import("vue").ComponentOptionsBase<Readonly<import("reka-ui").NumberFieldInputProps> & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {
95
- as: import("reka-ui").AsTag | import("vue").Component;
96
- }, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & {
97
- beforeCreate?: (() => void) | (() => void)[];
98
- created?: (() => void) | (() => void)[];
99
- beforeMount?: (() => void) | (() => void)[];
100
- mounted?: (() => void) | (() => void)[];
101
- beforeUpdate?: (() => void) | (() => void)[];
102
- updated?: (() => void) | (() => void)[];
103
- activated?: (() => void) | (() => void)[];
104
- deactivated?: (() => void) | (() => void)[];
105
- beforeDestroy?: (() => void) | (() => void)[];
106
- beforeUnmount?: (() => void) | (() => void)[];
107
- destroyed?: (() => void) | (() => void)[];
108
- unmounted?: (() => void) | (() => void)[];
109
- renderTracked?: ((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[];
110
- renderTriggered?: ((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[];
111
- errorCaptured?: ((err: unknown, instance: import("vue").ComponentPublicInstance | null, info: string) => boolean | void) | ((err: unknown, instance: import("vue").ComponentPublicInstance | null, info: string) => boolean | void)[];
112
- };
113
- $forceUpdate: () => void;
114
- $nextTick: typeof import("vue").nextTick;
115
- $watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (...args: [R, R, import("@vue/reactivity").OnCleanup]) => any : (...args: [any, any, import("@vue/reactivity").OnCleanup]) => any, options?: import("vue").WatchOptions): import("vue").WatchStopHandle;
116
- } & Readonly<{
117
- as: import("reka-ui").AsTag | import("vue").Component;
118
- }> & Omit<Readonly<import("reka-ui").NumberFieldInputProps> & Readonly<{}>, "as"> & import("vue").ShallowUnwrapRef<{}> & {} & import("vue").ComponentCustomProperties & {} & {
119
- $slots: {
120
- default?: (props: {}) => any;
121
- };
122
- }) | null, ({
123
- $: import("vue").ComponentInternalInstance;
124
- $data: {};
125
- $props: {
126
- readonly asChild?: boolean | undefined;
127
- readonly as?: (import("reka-ui").AsTag | import("vue").Component) | undefined;
128
- } & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps;
129
- $attrs: {
130
- [x: string]: unknown;
131
- };
132
- $refs: {
133
- [x: string]: unknown;
134
- };
135
- $slots: Readonly<{
136
- [name: string]: import("vue").Slot<any> | undefined;
137
- }>;
138
- $root: import("vue").ComponentPublicInstance | null;
139
- $parent: import("vue").ComponentPublicInstance | null;
140
- $host: Element | null;
141
- $emit: (event: string, ...args: any[]) => void;
142
- $el: any;
143
- $options: import("vue").ComponentOptionsBase<Readonly<import("reka-ui").NumberFieldInputProps> & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {
144
- as: import("reka-ui").AsTag | import("vue").Component;
145
- }, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & {
146
- beforeCreate?: (() => void) | (() => void)[];
147
- created?: (() => void) | (() => void)[];
148
- beforeMount?: (() => void) | (() => void)[];
149
- mounted?: (() => void) | (() => void)[];
150
- beforeUpdate?: (() => void) | (() => void)[];
151
- updated?: (() => void) | (() => void)[];
152
- activated?: (() => void) | (() => void)[];
153
- deactivated?: (() => void) | (() => void)[];
154
- beforeDestroy?: (() => void) | (() => void)[];
155
- beforeUnmount?: (() => void) | (() => void)[];
156
- destroyed?: (() => void) | (() => void)[];
157
- unmounted?: (() => void) | (() => void)[];
158
- renderTracked?: ((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[];
159
- renderTriggered?: ((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[];
160
- errorCaptured?: ((err: unknown, instance: import("vue").ComponentPublicInstance | null, info: string) => boolean | void) | ((err: unknown, instance: import("vue").ComponentPublicInstance | null, info: string) => boolean | void)[];
161
- };
162
- $forceUpdate: () => void;
163
- $nextTick: typeof import("vue").nextTick;
164
- $watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (...args: [R, R, import("@vue/reactivity").OnCleanup]) => any : (...args: [any, any, import("@vue/reactivity").OnCleanup]) => any, options?: import("vue").WatchOptions): import("vue").WatchStopHandle;
165
- } & Readonly<{
166
- as: import("reka-ui").AsTag | import("vue").Component;
167
- }> & Omit<Readonly<import("reka-ui").NumberFieldInputProps> & Readonly<{}>, "as"> & import("vue").ShallowUnwrapRef<{}> & {} & import("vue").ComponentCustomProperties & {} & {
168
- $slots: {
169
- default?: (props: {}) => any;
170
- };
171
- }) | null>;
172
- }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
173
- blur: (event: FocusEvent) => any;
174
- change: (event: Event) => any;
175
- "update:modelValue": (value: number) => any;
176
- }, string, import("vue").PublicProps, Readonly<InputNumberProps> & Readonly<{
177
- onBlur?: ((event: FocusEvent) => any) | undefined;
178
- onChange?: ((event: Event) => any) | undefined;
179
- "onUpdate:modelValue"?: ((value: number) => any) | undefined;
180
- }>, {
181
- decrement: boolean | ButtonProps;
182
- increment: boolean | ButtonProps;
183
- orientation: "vertical" | "horizontal";
184
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, InputNumberSlots>;
69
+ declare const __VLS_export: <T extends InputNumberValue = InputNumberValue>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
70
+ props: __VLS_PrettifyLocal<InputNumberProps<T> & {
71
+ onChange?: ((event: Event) => any) | undefined;
72
+ onBlur?: ((event: FocusEvent) => any) | undefined;
73
+ "onUpdate:modelValue"?: ((value: T) => any) | undefined;
74
+ }> & import("vue").PublicProps;
75
+ expose: (exposed: import("vue").ShallowUnwrapRef<{
76
+ inputRef: Readonly<import("vue").Ref<HTMLInputElement, HTMLInputElement>>;
77
+ }>) => void;
78
+ attrs: any;
79
+ slots: InputNumberSlots;
80
+ emit: ((evt: "change", event: Event) => void) & ((evt: "blur", event: FocusEvent) => void) & ((evt: "update:modelValue", value: T) => void);
81
+ }>) => import("vue").VNode & {
82
+ __ctx?: Awaited<typeof __VLS_setup>;
83
+ };
185
84
  declare const _default: typeof __VLS_export;
186
85
  export default _default;
187
- type __VLS_WithSlots<T, S> = T & {
188
- new (): {
189
- $slots: S;
190
- };
191
- };
86
+ type __VLS_PrettifyLocal<T> = {
87
+ [K in keyof T as K]: T[K];
88
+ } & {};