@volverjs/ui-vue 0.0.10-beta.47 → 0.0.10-beta.49

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 (357) hide show
  1. package/README.md +2 -2
  2. package/auto-imports.d.ts +19 -11
  3. package/bin/icons.js +1 -0
  4. package/dist/components/VvAccordion/VvAccordion.es.js +4 -5
  5. package/dist/components/VvAccordion/VvAccordion.umd.js +1 -1
  6. package/dist/components/VvAccordion/VvAccordion.vue.d.ts +8 -11
  7. package/dist/components/VvAccordion/index.d.ts +2 -2
  8. package/dist/components/VvAccordionGroup/VvAccordionGroup.es.js +45 -46
  9. package/dist/components/VvAccordionGroup/VvAccordionGroup.umd.js +1 -1
  10. package/dist/components/VvAccordionGroup/VvAccordionGroup.vue.d.ts +11 -13
  11. package/dist/components/VvAccordionGroup/index.d.ts +2 -2
  12. package/dist/components/VvAction/VvAction.vue.d.ts +8 -10
  13. package/dist/components/VvAction/index.d.ts +1 -1
  14. package/dist/components/VvAlert/VvAlert.es.js +158 -161
  15. package/dist/components/VvAlert/VvAlert.umd.js +1 -1
  16. package/dist/components/VvAlert/VvAlert.vue.d.ts +20 -22
  17. package/dist/components/VvAlert/index.d.ts +1 -1
  18. package/dist/components/VvAlertGroup/VvAlertGroup.es.js +271 -274
  19. package/dist/components/VvAlertGroup/VvAlertGroup.umd.js +1 -1
  20. package/dist/components/VvAlertGroup/VvAlertGroup.vue.d.ts +9 -11
  21. package/dist/components/VvAlertGroup/index.d.ts +2 -2
  22. package/dist/components/VvAvatar/VvAvatar.vue.d.ts +6 -6
  23. package/dist/components/VvAvatar/index.d.ts +1 -1
  24. package/dist/components/VvAvatarGroup/VvAvatarGroup.es.js +21 -22
  25. package/dist/components/VvAvatarGroup/VvAvatarGroup.umd.js +1 -1
  26. package/dist/components/VvAvatarGroup/VvAvatarGroup.vue.d.ts +6 -6
  27. package/dist/components/VvAvatarGroup/index.d.ts +1 -1
  28. package/dist/components/VvBadge/VvBadge.vue.d.ts +6 -6
  29. package/dist/components/VvBadge/index.d.ts +1 -1
  30. package/dist/components/VvBreadcrumb/VvBreadcrumb.es.js +23 -23
  31. package/dist/components/VvBreadcrumb/VvBreadcrumb.umd.js +1 -1
  32. package/dist/components/VvBreadcrumb/VvBreadcrumb.vue.d.ts +19 -19
  33. package/dist/components/VvBreadcrumb/index.d.ts +1 -1
  34. package/dist/components/VvButton/VvButton.es.js +313 -314
  35. package/dist/components/VvButton/VvButton.umd.js +1 -1
  36. package/dist/components/VvButton/VvButton.vue.d.ts +14 -16
  37. package/dist/components/VvButton/index.d.ts +9 -9
  38. package/dist/components/VvButtonGroup/VvButtonGroup.es.js +2 -2
  39. package/dist/components/VvButtonGroup/VvButtonGroup.vue.d.ts +6 -8
  40. package/dist/components/VvButtonGroup/index.d.ts +1 -1
  41. package/dist/components/VvCard/VvCard.vue.d.ts +6 -6
  42. package/dist/components/VvCard/index.d.ts +1 -1
  43. package/dist/components/VvCheckbox/VvCheckbox.es.js +186 -187
  44. package/dist/components/VvCheckbox/VvCheckbox.umd.js +1 -1
  45. package/dist/components/VvCheckbox/VvCheckbox.vue.d.ts +11 -13
  46. package/dist/components/VvCheckbox/index.d.ts +7 -7
  47. package/dist/components/VvCheckboxGroup/VvCheckboxGroup.es.js +190 -191
  48. package/dist/components/VvCheckboxGroup/VvCheckboxGroup.umd.js +1 -1
  49. package/dist/components/VvCheckboxGroup/VvCheckboxGroup.vue.d.ts +11 -13
  50. package/dist/components/VvCheckboxGroup/index.d.ts +2 -2
  51. package/dist/components/VvCombobox/VvCombobox.es.js +1864 -1865
  52. package/dist/components/VvCombobox/VvCombobox.umd.js +1 -1
  53. package/dist/components/VvCombobox/VvCombobox.vue.d.ts +72 -291
  54. package/dist/components/VvCombobox/index.d.ts +1 -1
  55. package/dist/components/VvDialog/VvDialog.vue.d.ts +7 -9
  56. package/dist/components/VvDialog/index.d.ts +1 -1
  57. package/dist/components/VvDropdown/VvDropdown.es.js +9 -10
  58. package/dist/components/VvDropdown/VvDropdown.umd.js +1 -1
  59. package/dist/components/VvDropdown/VvDropdown.vue.d.ts +51 -51
  60. package/dist/components/VvDropdown/VvDropdownAction.vue.d.ts +22 -16
  61. package/dist/components/VvDropdown/VvDropdownItem.vue.d.ts +4 -4
  62. package/dist/components/VvDropdown/VvDropdownOptgroup.vue.d.ts +4 -4
  63. package/dist/components/VvDropdown/VvDropdownOption.vue.d.ts +6 -6
  64. package/dist/components/VvDropdownAction/VvDropdownAction.es.js +2 -2
  65. package/dist/components/VvDropdownItem/VvDropdownItem.es.js +2 -2
  66. package/dist/components/VvDropdownOption/VvDropdownOption.es.js +2 -2
  67. package/dist/components/VvIcon/VvIcon.vue.d.ts +2 -23
  68. package/dist/components/VvInputFile/VvInputFile.es.js +651 -652
  69. package/dist/components/VvInputFile/VvInputFile.umd.js +1 -1
  70. package/dist/components/VvInputFile/VvInputFile.vue.d.ts +19 -19
  71. package/dist/components/VvInputFile/index.d.ts +4 -4
  72. package/dist/components/VvInputText/VvInputClearAction.d.ts +10 -6
  73. package/dist/components/VvInputText/VvInputPasswordAction.d.ts +11 -7
  74. package/dist/components/VvInputText/VvInputStepAction.d.ts +10 -6
  75. package/dist/components/VvInputText/VvInputText.es.js +715 -716
  76. package/dist/components/VvInputText/VvInputText.umd.js +1 -1
  77. package/dist/components/VvInputText/VvInputText.vue.d.ts +30 -32
  78. package/dist/components/VvInputText/index.d.ts +1 -1
  79. package/dist/components/VvNav/VvNav.es.js +5 -5
  80. package/dist/components/VvNav/VvNav.umd.js +1 -1
  81. package/dist/components/VvNav/VvNav.vue.d.ts +8 -10
  82. package/dist/components/VvNav/VvNavItem.vue.d.ts +1 -1
  83. package/dist/components/VvNav/VvNavSeparator.vue.d.ts +1 -1
  84. package/dist/components/VvNav/index.d.ts +2 -2
  85. package/dist/components/VvProgress/VvProgress.vue.d.ts +6 -6
  86. package/dist/components/VvProgress/index.d.ts +1 -1
  87. package/dist/components/VvRadio/VvRadio.es.js +186 -187
  88. package/dist/components/VvRadio/VvRadio.umd.js +1 -1
  89. package/dist/components/VvRadio/VvRadio.vue.d.ts +10 -12
  90. package/dist/components/VvRadio/index.d.ts +5 -5
  91. package/dist/components/VvRadioGroup/VvRadioGroup.es.js +190 -191
  92. package/dist/components/VvRadioGroup/VvRadioGroup.umd.js +1 -1
  93. package/dist/components/VvRadioGroup/VvRadioGroup.vue.d.ts +11 -13
  94. package/dist/components/VvRadioGroup/index.d.ts +2 -2
  95. package/dist/components/VvSelect/VvSelect.es.js +337 -338
  96. package/dist/components/VvSelect/VvSelect.umd.js +1 -1
  97. package/dist/components/VvSelect/VvSelect.vue.d.ts +20 -131
  98. package/dist/components/VvSelect/index.d.ts +7 -7
  99. package/dist/components/VvTab/VvTab.es.js +18 -18
  100. package/dist/components/VvTab/VvTab.umd.js +1 -1
  101. package/dist/components/VvTab/VvTab.vue.d.ts +6 -8
  102. package/dist/components/VvTab/index.d.ts +1 -1
  103. package/dist/components/VvTextarea/VvTextarea.es.js +292 -293
  104. package/dist/components/VvTextarea/VvTextarea.umd.js +1 -1
  105. package/dist/components/VvTextarea/VvTextarea.vue.d.ts +14 -16
  106. package/dist/components/VvTextarea/index.d.ts +3 -3
  107. package/dist/components/VvTooltip/VvTooltip.vue.d.ts +8 -8
  108. package/dist/components/common/HintSlot.d.ts +6 -6
  109. package/dist/components/index.d.ts +1 -1
  110. package/dist/components/index.es.js +2760 -2763
  111. package/dist/components/index.umd.js +1 -1
  112. package/dist/composables/alert/useAlert.d.ts +4 -4
  113. package/dist/composables/alert/{useProvideAlert.d.ts → useAlertProvide.d.ts} +1 -1
  114. package/dist/composables/dropdown/useDropdownContextmenu.d.ts +18 -0
  115. package/dist/composables/dropdown/{useProvideDropdown.d.ts → useDropdownProvide.d.ts} +6 -6
  116. package/dist/composables/dropdown/useDropdownVirtualElement.d.ts +17 -0
  117. package/dist/composables/group/{useInjectedGroupState.d.ts → useGroupStateInject.d.ts} +1 -1
  118. package/dist/composables/group/{useProvideGroupState.d.ts → useGroupStateProvide.d.ts} +2 -2
  119. package/dist/composables/index.d.ts +2 -0
  120. package/dist/composables/index.es.js +87 -3
  121. package/dist/composables/index.umd.js +1 -1
  122. package/dist/composables/useComponentFocus.d.ts +1 -1
  123. package/dist/composables/useOptions.d.ts +1 -1
  124. package/dist/composables/usePersistence.d.ts +1 -1
  125. package/dist/composables/useUniqueId.d.ts +1 -1
  126. package/dist/constants.d.ts +3 -3
  127. package/dist/directives/index.d.ts +2 -2
  128. package/dist/directives/index.es.js +145 -39
  129. package/dist/directives/index.umd.js +1 -1
  130. package/dist/directives/v-contextmenu.es.js +137 -31
  131. package/dist/directives/v-contextmenu.umd.js +1 -1
  132. package/dist/icons.d.ts +17 -17
  133. package/dist/icons.es.js +424 -424
  134. package/dist/icons.umd.js +1 -1
  135. package/dist/index.d.ts +1 -1
  136. package/dist/index.umd.js +1 -1
  137. package/dist/props/index.d.ts +4 -4
  138. package/dist/resolvers/unplugin.umd.js +1 -1
  139. package/dist/stories/AccordionGroup/AccordionGroupSlots.stories.d.ts +178 -474
  140. package/dist/stories/Alert/Alert.settings.d.ts +1 -1
  141. package/dist/stories/Alert/AlertModifiers.stories.d.ts +1 -1
  142. package/dist/stories/Alert/AlertSlots.stories.d.ts +1 -1
  143. package/dist/stories/AlertGroup/AlertGroupPosition.stories.d.ts +1 -1
  144. package/dist/stories/AlertGroup/AlertGroupSlots.stories.d.ts +1 -1
  145. package/dist/stories/AlertGroup/AlertGroupWithComposable.stories.d.ts +1 -1
  146. package/dist/stories/Button/Button.settings.d.ts +1 -1
  147. package/dist/stories/Combobox/Combobox.settings.d.ts +1 -1
  148. package/dist/stories/Nav/Nav.settings.d.ts +1 -1
  149. package/dist/stories/Tab/Tab.settings.d.ts +1 -1
  150. package/dist/types/floating-ui.d.ts +1 -1
  151. package/dist/types/group.d.ts +1 -1
  152. package/dist/types/index.d.ts +2 -2
  153. package/dist/utils/DomUtilities.d.ts +1 -0
  154. package/package.json +43 -43
  155. package/src/Volver.ts +3 -3
  156. package/src/assets/icons/detailed.json +1 -1
  157. package/src/assets/icons/normal.json +1 -1
  158. package/src/assets/icons/simple.json +1 -1
  159. package/src/components/VvAccordion/VvAccordion.vue +5 -5
  160. package/src/components/VvAccordion/index.ts +2 -2
  161. package/src/components/VvAccordionGroup/VvAccordionGroup.vue +5 -5
  162. package/src/components/VvAction/VvAction.vue +1 -1
  163. package/src/components/VvAlert/VvAlert.vue +1 -1
  164. package/src/components/VvAlert/index.ts +1 -1
  165. package/src/components/VvAlertGroup/VvAlertGroup.vue +1 -1
  166. package/src/components/VvAlertGroup/index.ts +3 -3
  167. package/src/components/VvAvatarGroup/VvAvatarGroup.vue +1 -1
  168. package/src/components/VvBreadcrumb/VvBreadcrumb.vue +2 -2
  169. package/src/components/VvBreadcrumb/index.ts +1 -1
  170. package/src/components/VvButton/VvButton.vue +3 -3
  171. package/src/components/VvButton/index.ts +4 -4
  172. package/src/components/VvButtonGroup/VvButtonGroup.vue +3 -3
  173. package/src/components/VvCheckbox/VvCheckbox.vue +2 -2
  174. package/src/components/VvCheckbox/index.ts +2 -2
  175. package/src/components/VvCheckboxGroup/VvCheckboxGroup.vue +2 -2
  176. package/src/components/VvCombobox/VvCombobox.vue +9 -9
  177. package/src/components/VvCombobox/index.ts +15 -15
  178. package/src/components/VvDropdown/VvDropdown.vue +19 -19
  179. package/src/components/VvDropdown/VvDropdownAction.vue +1 -1
  180. package/src/components/VvDropdown/VvDropdownItem.vue +1 -1
  181. package/src/components/VvDropdown/VvDropdownOption.vue +1 -1
  182. package/src/components/VvDropdown/index.ts +2 -2
  183. package/src/components/VvIcon/VvIcon.vue +2 -2
  184. package/src/components/VvInputFile/VvInputFile.vue +7 -7
  185. package/src/components/VvInputFile/index.ts +7 -7
  186. package/src/components/VvInputText/VvInputPasswordAction.ts +1 -1
  187. package/src/components/VvInputText/VvInputText.vue +19 -19
  188. package/src/components/VvInputText/VvInputTextActions.ts +4 -4
  189. package/src/components/VvInputText/index.ts +2 -2
  190. package/src/components/VvNav/VvNav.vue +1 -1
  191. package/src/components/VvRadio/VvRadio.vue +1 -1
  192. package/src/components/VvRadio/index.ts +2 -2
  193. package/src/components/VvRadioGroup/VvRadioGroup.vue +2 -2
  194. package/src/components/VvSelect/VvSelect.vue +6 -6
  195. package/src/components/VvSelect/index.ts +12 -12
  196. package/src/components/VvTab/VvTab.vue +2 -2
  197. package/src/components/VvTab/index.ts +1 -1
  198. package/src/components/VvTextarea/VvTextarea.vue +1 -1
  199. package/src/components/common/HintSlot.ts +14 -14
  200. package/src/components/index.ts +1 -1
  201. package/src/composables/alert/useAlert.ts +2 -2
  202. package/src/composables/alert/{useProvideAlert.ts → useAlertProvide.ts} +2 -2
  203. package/src/composables/dropdown/useDropdownContextmenu.ts +22 -0
  204. package/src/composables/dropdown/{useProvideDropdown.ts → useDropdownProvide.ts} +9 -9
  205. package/src/composables/dropdown/useDropdownVirtualElement.ts +53 -0
  206. package/src/composables/group/{useInjectedGroupState.ts → useGroupStateInject.ts} +2 -2
  207. package/src/composables/group/{useProvideGroupState.ts → useGroupStateProvide.ts} +2 -2
  208. package/src/composables/index.ts +2 -0
  209. package/src/composables/useBlurhash.ts +2 -2
  210. package/src/composables/useOptions.ts +1 -1
  211. package/src/composables/usePersistence.ts +1 -1
  212. package/src/composables/useTextCount.ts +2 -2
  213. package/src/composables/useUniqueId.ts +2 -3
  214. package/src/constants.ts +5 -5
  215. package/src/directives/index.ts +2 -2
  216. package/src/directives/v-contextmenu.ts +21 -29
  217. package/src/directives/v-tooltip.ts +2 -2
  218. package/src/icons.ts +2 -2
  219. package/src/index.ts +1 -1
  220. package/src/props/index.ts +7 -7
  221. package/src/resolvers/unplugin.ts +5 -5
  222. package/src/stories/Accordion/Accordion.stories.ts +2 -2
  223. package/src/stories/Accordion/Accordion.test.ts +1 -1
  224. package/src/stories/Accordion/AccordionSlots.stories.ts +2 -2
  225. package/src/stories/AccordionGroup/AccordionGroup.stories.ts +2 -2
  226. package/src/stories/AccordionGroup/AccordionGroup.test.ts +1 -1
  227. package/src/stories/AccordionGroup/AccordionGroupSlots.stories.ts +3 -3
  228. package/src/stories/Alert/Alert.settings.ts +1 -1
  229. package/src/stories/Alert/Alert.stories.ts +2 -2
  230. package/src/stories/Alert/Alert.test.ts +1 -1
  231. package/src/stories/Alert/AlertModifiers.stories.ts +2 -2
  232. package/src/stories/Alert/AlertSlots.stories.ts +2 -2
  233. package/src/stories/AlertGroup/AlertGroup.stories.ts +2 -2
  234. package/src/stories/AlertGroup/AlertGroup.test.ts +3 -3
  235. package/src/stories/AlertGroup/AlertGroupPosition.stories.ts +2 -2
  236. package/src/stories/AlertGroup/AlertGroupSlots.stories.ts +2 -2
  237. package/src/stories/AlertGroup/AlertGroupWithComposable.stories.ts +2 -2
  238. package/src/stories/Avatar/Avatar.stories.ts +2 -2
  239. package/src/stories/Avatar/Avatar.test.ts +1 -1
  240. package/src/stories/Avatar/AvatarBadge.stories.ts +1 -1
  241. package/src/stories/Avatar/AvatarModifiers.stories.ts +2 -2
  242. package/src/stories/Avatar/AvatarSlots.stories.ts +2 -2
  243. package/src/stories/AvatarGroup/AvatarGroup.stories.ts +2 -2
  244. package/src/stories/AvatarGroup/AvatarGroup.test.ts +1 -1
  245. package/src/stories/AvatarGroup/AvatarGroupModifiers.stories.ts +2 -2
  246. package/src/stories/AvatarGroup/AvatarGroupSlotDefault.stories.ts +3 -3
  247. package/src/stories/Badge/Badge.stories.ts +2 -2
  248. package/src/stories/Badge/Badge.test.ts +1 -1
  249. package/src/stories/Badge/BadgeSlots.stories.ts +2 -2
  250. package/src/stories/Blurhash/BlurhashComposable.stories.ts +37 -117
  251. package/src/stories/Breadcrumb/Breadcrumb.stories.ts +2 -2
  252. package/src/stories/Breadcrumb/BreadcrumbSlots.stories.ts +5 -5
  253. package/src/stories/Button/Button.settings.ts +3 -3
  254. package/src/stories/Button/Button.stories.ts +2 -2
  255. package/src/stories/Button/Button.test.ts +1 -1
  256. package/src/stories/Button/ButtonIcon.stories.ts +2 -2
  257. package/src/stories/Button/ButtonLink.stories.ts +2 -2
  258. package/src/stories/Button/ButtonLoading.stories.ts +2 -2
  259. package/src/stories/Button/ButtonModifiers.stories.ts +2 -2
  260. package/src/stories/Button/ButtonSlots.stories.ts +3 -3
  261. package/src/stories/Button/ButtonState.stories.ts +2 -2
  262. package/src/stories/Button/ButtonToggle.stories.ts +2 -2
  263. package/src/stories/ButtonGroup/ButtonGroup.settings.ts +2 -2
  264. package/src/stories/ButtonGroup/ButtonGroup.stories.ts +2 -2
  265. package/src/stories/ButtonGroup/ButtonGroup.test.ts +1 -1
  266. package/src/stories/ButtonGroup/ButtonGroupModifiers.stories.ts +2 -2
  267. package/src/stories/ButtonGroup/ButtonGroupSlots.stories.ts +2 -2
  268. package/src/stories/ButtonGroup/ButtonGroupToggle.stories.ts +2 -2
  269. package/src/stories/Card/Card.stories.ts +2 -2
  270. package/src/stories/Card/Card.test.ts +1 -1
  271. package/src/stories/Card/CardSlots.stories.ts +2 -2
  272. package/src/stories/Checkbox/Checkbox.stories.ts +2 -2
  273. package/src/stories/Checkbox/Checkbox.test.ts +1 -1
  274. package/src/stories/Checkbox/CheckboxBinary.stories.ts +2 -2
  275. package/src/stories/Checkbox/CheckboxSlots.stories.ts +2 -2
  276. package/src/stories/CheckboxGroup/CheckboxGroup.stories.ts +2 -2
  277. package/src/stories/CheckboxGroup/CheckboxGroup.test.ts +2 -2
  278. package/src/stories/CheckboxGroup/CheckboxGroupOptions.stories.ts +2 -2
  279. package/src/stories/CheckboxGroup/CheckboxGroupSlots.stories.ts +3 -3
  280. package/src/stories/Combobox/Combobox.settings.ts +9 -9
  281. package/src/stories/Combobox/Combobox.stories.ts +2 -2
  282. package/src/stories/Combobox/Combobox.test.ts +2 -2
  283. package/src/stories/Combobox/ComboboxIconPosition.stories.ts +2 -2
  284. package/src/stories/Combobox/ComboboxMultiple.stories.ts +2 -2
  285. package/src/stories/Combobox/ComboboxOptions.stories.ts +2 -2
  286. package/src/stories/Combobox/ComboboxSlots.stories.ts +3 -3
  287. package/src/stories/Dialog/Dialog.stories.ts +2 -2
  288. package/src/stories/Dialog/Dialog.test.ts +1 -1
  289. package/src/stories/Dialog/DialogModifiers.stories.ts +2 -2
  290. package/src/stories/Dialog/DialogSlots.stories.ts +2 -2
  291. package/src/stories/Dropdown/Dropdown.settings.ts +1 -1
  292. package/src/stories/Dropdown/Dropdown.stories.ts +4 -4
  293. package/src/stories/Dropdown/Dropdown.test.ts +1 -1
  294. package/src/stories/Dropdown/DropdownContextmenuDirective.stories.ts +3 -4
  295. package/src/stories/Dropdown/DropdownMultilevel.stories.ts +4 -4
  296. package/src/stories/Dropdown/DropdownSlots.stories.ts +4 -4
  297. package/src/stories/Icon/Icon.settings.ts +1 -1
  298. package/src/stories/Icon/Icon.stories.ts +2 -2
  299. package/src/stories/Icon/IconsCollection.stories.ts +3 -3
  300. package/src/stories/InputFile/InputFile.settings.ts +1 -1
  301. package/src/stories/InputFile/InputFile.stories.ts +1 -1
  302. package/src/stories/InputFile/InputFileDropArea.stories.ts +2 -2
  303. package/src/stories/InputFile/InputFileIconPosition.stories.ts +2 -2
  304. package/src/stories/InputFile/InputFileSlots.stories.ts +2 -2
  305. package/src/stories/InputText/InputText.settings.ts +2 -2
  306. package/src/stories/InputText/InputText.stories.ts +2 -2
  307. package/src/stories/InputText/InputText.test.ts +2 -2
  308. package/src/stories/InputText/InputTextIconPosition.stories.ts +2 -2
  309. package/src/stories/InputText/InputTextLength.stories.ts +2 -2
  310. package/src/stories/InputText/InputTextMask.stories.ts +2 -2
  311. package/src/stories/InputText/InputTextMinMax.stories.ts +2 -2
  312. package/src/stories/InputText/InputTextSlots.stories.ts +2 -2
  313. package/src/stories/InputText/InputTextType.stories.ts +2 -2
  314. package/src/stories/Nav/Nav.settings.ts +1 -1
  315. package/src/stories/Nav/Nav.stories.ts +2 -2
  316. package/src/stories/Nav/Nav.test.ts +1 -1
  317. package/src/stories/Nav/NavModifiers.stories.ts +2 -2
  318. package/src/stories/Progress/Progress.stories.ts +2 -2
  319. package/src/stories/Progress/Progress.test.ts +2 -2
  320. package/src/stories/Radio/Radio.stories.ts +2 -2
  321. package/src/stories/Radio/Radio.test.ts +1 -1
  322. package/src/stories/Radio/RadioSlots.stories.ts +2 -2
  323. package/src/stories/RadioGroup/RadioGroup.stories.ts +2 -2
  324. package/src/stories/RadioGroup/RadioGroup.test.ts +2 -2
  325. package/src/stories/RadioGroup/RadioGroupOptions.stories.ts +2 -2
  326. package/src/stories/RadioGroup/RadioGroupSlots.stories.ts +3 -3
  327. package/src/stories/Select/Select.settings.ts +10 -10
  328. package/src/stories/Select/Select.stories.ts +2 -2
  329. package/src/stories/Select/Select.test.ts +1 -1
  330. package/src/stories/Select/SelectIconPosition.stories.ts +2 -2
  331. package/src/stories/Select/SelectOptions.stories.ts +2 -2
  332. package/src/stories/Select/SelectSlots.stories.ts +2 -2
  333. package/src/stories/Tab/Tab.settings.ts +1 -1
  334. package/src/stories/Tab/Tab.stories.ts +1 -1
  335. package/src/stories/Tab/Tab.test.ts +1 -1
  336. package/src/stories/Textarea/Textarea.settings.ts +1 -1
  337. package/src/stories/Textarea/Textarea.stories.ts +2 -2
  338. package/src/stories/Textarea/Textarea.test.ts +1 -1
  339. package/src/stories/Textarea/TextareaLength.stories.ts +2 -2
  340. package/src/stories/Textarea/TextareaSlots.stories.ts +2 -2
  341. package/src/stories/Textarea/TextareatIconPosition.stories.ts +2 -2
  342. package/src/stories/Tooltip/Tooltip.stories.ts +3 -3
  343. package/src/stories/Tooltip/Tooltip.test.ts +1 -1
  344. package/src/stories/Tooltip/TooltipDirective.stories.ts +3 -3
  345. package/src/test/expect.ts +3 -3
  346. package/src/test/types.d.ts +2 -2
  347. package/src/types/floating-ui.ts +1 -1
  348. package/src/types/group.ts +1 -1
  349. package/src/types/index.ts +2 -2
  350. package/src/utils/DomUtilities.ts +15 -0
  351. package/src/utils/ObjectUtilities.ts +4 -4
  352. package/src/workers/blurhash.ts +1 -1
  353. package/dist/composables/alert/{useInjectAlert.d.ts → useAlerInject.d.ts} +0 -0
  354. package/dist/composables/dropdown/{useInjectDropdown.d.ts → useDropdownInject.d.ts} +0 -0
  355. package/src/assets/icons/normal/{dulicate.svg → duplicate.svg} +0 -0
  356. package/src/composables/alert/{useInjectAlert.ts → useAlerInject.ts} +0 -0
  357. package/src/composables/dropdown/{useInjectDropdown.ts → useDropdownInject.ts} +1 -1
@@ -1,24 +1,7 @@
1
- import { inject, computed, unref, defineComponent, mergeDefaults, ref, toRefs, openBlock, createBlock, mergeProps, createCommentVNode, getCurrentInstance, watch, resolveDynamicComponent, withCtx, renderSlot, createTextVNode, toDisplayString, toRef, useAttrs, useSlots, createElementBlock, Fragment, isRef, h, onBeforeUnmount, normalizeClass, withModifiers, createElementVNode, normalizeProps, createVNode, guardReactiveProps, createSlots } from "vue";
1
+ import { computed, isRef, defineComponent, h, inject, toRef, toRefs, getCurrentInstance, ref, watch, openBlock, createBlock, resolveDynamicComponent, unref, mergeProps, withCtx, renderSlot, createTextVNode, toDisplayString, mergeDefaults, createCommentVNode, useId, useAttrs, useSlots, createElementBlock, Fragment, useTemplateRef, onBeforeUnmount, normalizeClass, withModifiers, createElementVNode, normalizeProps, createVNode, guardReactiveProps, createSlots } from "vue";
2
2
  import { useVModel } from "@vueuse/core";
3
3
  import Sortable from "vuedraggable";
4
4
  import { iconExists, Icon, addIcon } from "@iconify/vue";
5
- import { uid } from "uid";
6
- const ACTION_ICONS = {
7
- showPassword: "eye-on",
8
- hidePassword: "eye-off",
9
- showDatePicker: "calendar",
10
- showTimePicker: "time",
11
- showColorPicker: "color",
12
- clear: "close",
13
- add: "add",
14
- remove: "trash",
15
- edit: "edit",
16
- download: "download"
17
- };
18
- const VvIconPropsDefaults = {
19
- prefix: "normal"
20
- /* normal */
21
- };
22
5
  var StorageType = /* @__PURE__ */ ((StorageType2) => {
23
6
  StorageType2["local"] = "local";
24
7
  StorageType2["session"] = "session";
@@ -75,145 +58,6 @@ const INJECTION_KEY_DROPDOWN_TRIGGER = Symbol.for(
75
58
  const INJECTION_KEY_DROPDOWN_ACTION = Symbol.for(
76
59
  "dropdownAction"
77
60
  );
78
- function useVolver() {
79
- return inject(INJECTION_KEY_VOLVER);
80
- }
81
- function useModifiers(prefix, modifiers, others) {
82
- return computed(() => {
83
- const toReturn = {
84
- [prefix]: true
85
- };
86
- const modifiersArray = typeof (modifiers == null ? void 0 : modifiers.value) === "string" ? modifiers.value.split(" ") : modifiers == null ? void 0 : modifiers.value;
87
- if (modifiersArray) {
88
- if (Array.isArray(modifiersArray)) {
89
- modifiersArray.forEach((modifier) => {
90
- if (modifier) {
91
- toReturn[`${prefix}--${modifier}`] = true;
92
- }
93
- });
94
- }
95
- }
96
- if (others) {
97
- Object.keys(others.value).forEach((key) => {
98
- toReturn[`${prefix}--${key}`] = unref(others.value[key]);
99
- });
100
- }
101
- return toReturn;
102
- });
103
- }
104
- const __default__$3 = {
105
- name: "VvIcon"
106
- };
107
- const _sfc_main$3 = /* @__PURE__ */ defineComponent({
108
- ...__default__$3,
109
- props: /* @__PURE__ */ mergeDefaults({
110
- name: {},
111
- color: {},
112
- width: {},
113
- height: {},
114
- provider: {},
115
- prefix: {},
116
- src: {},
117
- horizontalFlip: { type: Boolean },
118
- verticalFlip: { type: Boolean },
119
- flip: {},
120
- mode: {},
121
- inline: { type: Boolean },
122
- rotate: {},
123
- onLoad: { type: Function },
124
- svg: {},
125
- modifiers: {}
126
- }, VvIconPropsDefaults),
127
- setup(__props) {
128
- const props = __props;
129
- const hasRotate = computed(() => {
130
- if (typeof props.rotate === "string") {
131
- return Number.parseFloat(props.rotate);
132
- }
133
- return props.rotate;
134
- });
135
- const show = ref(true);
136
- const volver = useVolver();
137
- const { modifiers } = toRefs(props);
138
- const bemCssClasses = useModifiers("vv-icon", modifiers);
139
- const provider = computed(() => {
140
- return props.provider || (volver == null ? void 0 : volver.iconsProvider);
141
- });
142
- const icon = computed(() => {
143
- const name = props.name ?? "";
144
- const iconName = `@${provider.value}:${props.prefix}:${name}`;
145
- if (iconExists(iconName)) {
146
- return iconName;
147
- }
148
- const iconsCollection = volver == null ? void 0 : volver.iconsCollections.find(
149
- (iconsCollection2) => {
150
- const icon2 = `@${provider.value}:${iconsCollection2.prefix}:${name}`;
151
- return iconExists(icon2);
152
- }
153
- );
154
- if (iconsCollection) {
155
- return `@${provider.value}:${iconsCollection.prefix}:${name}`;
156
- }
157
- return name;
158
- });
159
- function getSvgContent(svg) {
160
- let dom;
161
- if (typeof window === "undefined") {
162
- const { JSDOM } = require("jsdom");
163
- dom = new JSDOM().window;
164
- }
165
- const domParser = dom ? new dom.DOMParser() : new window.DOMParser();
166
- const svgDomString = domParser.parseFromString(svg, "text/html");
167
- const svgEl = svgDomString.querySelector("svg");
168
- return svgEl;
169
- }
170
- function addIconFromSvg(svg) {
171
- const svgContentEl = getSvgContent(svg);
172
- const svgContent = (svgContentEl == null ? void 0 : svgContentEl.innerHTML.trim()) || "";
173
- if (svgContentEl && svgContent) {
174
- addIcon(`@${provider.value}:${props.prefix}:${props.name}`, {
175
- body: svgContent,
176
- // Set height and width from svg content
177
- height: svgContentEl.viewBox.baseVal.height,
178
- width: svgContentEl.viewBox.baseVal.width
179
- });
180
- }
181
- }
182
- if (volver) {
183
- if (props.src && !iconExists(`@${provider.value}:${props.prefix}:${props.name}`)) {
184
- show.value = false;
185
- volver.fetchIcon(props.src).then((svg) => {
186
- if (svg) {
187
- addIconFromSvg(svg);
188
- show.value = true;
189
- }
190
- }).catch((e) => {
191
- throw new Error(`Error during fetch icon: ${e == null ? void 0 : e.message}`);
192
- });
193
- }
194
- }
195
- if (props.svg) {
196
- addIconFromSvg(props.svg);
197
- }
198
- return (_ctx, _cache) => {
199
- return unref(show) ? (openBlock(), createBlock(unref(Icon), mergeProps({
200
- key: 0,
201
- class: unref(bemCssClasses)
202
- }, {
203
- inline: _ctx.inline,
204
- width: _ctx.width,
205
- height: _ctx.height,
206
- horizontalFlip: _ctx.horizontalFlip,
207
- verticalFlip: _ctx.verticalFlip,
208
- flip: _ctx.flip,
209
- rotate: unref(hasRotate),
210
- color: _ctx.color,
211
- onLoad: _ctx.onLoad,
212
- icon: unref(icon)
213
- }), null, 16, ["class"])) : createCommentVNode("v-if", true);
214
- };
215
- }
216
- });
217
61
  const LinkProps = {
218
62
  /**
219
63
  * The router-link/nuxt-link property, if it is defined the button is rendered as a ruouter-link or nuxt-link.
@@ -515,278 +359,138 @@ const ActionProps = {
515
359
  },
516
360
  storageKey: String
517
361
  });
518
- const VvActionEvents = ["click", "mouseover", "mouseleave"];
519
- const VvActionProps = ActionProps;
520
- function useInjectedDropdownTrigger() {
521
- return inject(INJECTION_KEY_DROPDOWN_TRIGGER, {});
522
- }
523
- function useInjectedDropdownAction() {
524
- return inject(INJECTION_KEY_DROPDOWN_ACTION, {});
525
- }
526
- const __default__$2 = {
527
- name: "VvAction"
362
+ const ACTION_ICONS = {
363
+ showPassword: "eye-on",
364
+ hidePassword: "eye-off",
365
+ showDatePicker: "calendar",
366
+ showTimePicker: "time",
367
+ showColorPicker: "color",
368
+ clear: "close",
369
+ add: "add",
370
+ remove: "trash",
371
+ edit: "edit",
372
+ download: "download"
528
373
  };
529
- const _sfc_main$2 = /* @__PURE__ */ defineComponent({
530
- ...__default__$2,
531
- props: VvActionProps,
532
- emits: VvActionEvents,
533
- setup(__props, { expose: __expose, emit: __emit }) {
534
- const props = __props;
535
- const emit = __emit;
536
- const instance = getCurrentInstance();
537
- const volver = useVolver();
538
- const element = ref(null);
539
- __expose({ $el: element });
540
- const {
541
- reference: dropdownTriggerReference,
542
- bus: dropdownEventBus,
543
- aria: dropdownAria,
544
- expanded: dropdownExpanded
545
- } = useInjectedDropdownTrigger();
546
- watch(
547
- () => element.value,
548
- (newValue) => {
549
- if (dropdownTriggerReference) {
550
- dropdownTriggerReference.value = newValue;
551
- }
374
+ const VvIconPropsDefaults = {
375
+ prefix: "normal"
376
+ /* normal */
377
+ };
378
+ const VvInputFileProps = {
379
+ ...IdNameProps,
380
+ ...ModifiersProps,
381
+ ...ValidProps,
382
+ ...InvalidProps,
383
+ ...HintProps,
384
+ ...LabelProps,
385
+ ...LoadingProps,
386
+ ...ReadonlyProps,
387
+ ...DisabledProps,
388
+ ...IconProps,
389
+ /**
390
+ * Input value
391
+ */
392
+ modelValue: {
393
+ type: Object
394
+ },
395
+ /**
396
+ * Whether to show progress bar
397
+ */
398
+ progress: { type: [Number, String], default: void 0 },
399
+ /**
400
+ * Input
401
+ * Text that appears in the form control when it has no value set
402
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#placeholder
403
+ */
404
+ placeholder: { type: String, default: void 0 },
405
+ /**
406
+ * File types to accept
407
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/accept
408
+ */
409
+ accept: { type: String, default: "*" },
410
+ /**
411
+ * Whether to allow multiple values
412
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#multiple
413
+ */
414
+ multiple: { type: Boolean, default: false },
415
+ /**
416
+ * Front or rear camera
417
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/capture
418
+ */
419
+ capture: {
420
+ type: String,
421
+ default: void 0,
422
+ validation: (value) => {
423
+ if (value === void 0) {
424
+ return true;
552
425
  }
553
- );
554
- const pressed = computed(() => {
555
- return props.pressed || (dropdownExpanded == null ? void 0 : dropdownExpanded.value);
556
- });
557
- const { role } = useInjectedDropdownAction();
558
- const hasTag = computed(() => {
559
- switch (true) {
560
- case props.disabled:
561
- return ActionTag.button;
562
- case props.to !== void 0:
563
- return (volver == null ? void 0 : volver.nuxt) ? ActionTag.nuxtLink : ActionTag.routerLink;
564
- case props.href !== void 0:
565
- return ActionTag.a;
566
- default:
567
- return props.defaultTag;
568
- }
569
- });
570
- const hasProps = computed(() => {
571
- const toReturn = {
572
- ...dropdownAria == null ? void 0 : dropdownAria.value,
573
- ariaPressed: pressed.value ? true : void 0,
574
- ariaLabel: props.ariaLabel,
575
- role: role == null ? void 0 : role.value
576
- };
577
- switch (hasTag.value) {
578
- case ActionTag.a:
579
- return {
580
- ...toReturn,
581
- href: props.href,
582
- target: props.target,
583
- rel: props.rel
584
- };
585
- case ActionTag.routerLink:
586
- case ActionTag.nuxtLink:
587
- return {
588
- ...toReturn,
589
- to: props.to,
590
- target: props.target
591
- };
592
- case ActionTag.button:
593
- return {
594
- ...toReturn,
595
- type: props.type,
596
- disabled: props.disabled
597
- };
598
- default:
599
- return toReturn;
600
- }
601
- });
602
- function onClick(e) {
603
- var _a;
604
- if (props.disabled) {
605
- e.preventDefault();
606
- return;
607
- }
608
- if ((_a = instance == null ? void 0 : instance.vnode.props) == null ? void 0 : _a.onClick) {
609
- emit("click", e);
610
- return;
611
- }
612
- dropdownEventBus == null ? void 0 : dropdownEventBus.emit("click", e);
613
- }
614
- function onMouseover(e) {
615
- var _a;
616
- if ((_a = instance == null ? void 0 : instance.vnode.props) == null ? void 0 : _a.onMouseover) {
617
- emit("mouseover", e);
618
- return;
619
- }
620
- dropdownEventBus == null ? void 0 : dropdownEventBus.emit("mouseover", e);
621
- }
622
- function onMouseleave(e) {
623
- var _a;
624
- if ((_a = instance == null ? void 0 : instance.vnode.props) == null ? void 0 : _a.onMouseleave) {
625
- emit("mouseleave", e);
626
- return;
627
- }
628
- dropdownEventBus == null ? void 0 : dropdownEventBus.emit("mouseleave", e);
629
- }
630
- return (_ctx, _cache) => {
631
- return openBlock(), createBlock(resolveDynamicComponent(unref(hasTag)), mergeProps(unref(hasProps), {
632
- ref_key: "element",
633
- ref: element,
634
- class: {
635
- active: _ctx.active,
636
- pressed: unref(pressed),
637
- disabled: _ctx.disabled,
638
- current: _ctx.current
639
- },
640
- onClickPassive: onClick,
641
- onMouseoverPassive: onMouseover,
642
- onMouseleavePassive: onMouseleave
643
- }), {
644
- default: withCtx(() => [
645
- renderSlot(_ctx.$slots, "default", {}, () => [
646
- createTextVNode(
647
- toDisplayString(_ctx.label),
648
- 1
649
- /* TEXT */
650
- )
651
- ])
652
- ]),
653
- _: 3
654
- /* FORWARDED */
655
- }, 16, ["class"]);
656
- };
657
- }
658
- });
659
- function useInjectedGroupState(groupKey) {
660
- const group = inject(groupKey, void 0);
661
- const isInGroup = computed(() => group !== void 0);
662
- function getGroupOrLocalRef(propName, props, emit) {
663
- const groupPropValue = group == null ? void 0 : group[propName];
664
- if (groupPropValue) {
665
- return computed({
666
- get() {
667
- return groupPropValue.value;
668
- },
669
- set(value) {
670
- groupPropValue.value = value;
671
- }
672
- });
426
+ return ["user", "environment"].includes(value);
673
427
  }
674
- const propRef = toRef(props, propName);
675
- return computed({
676
- get() {
677
- return propRef.value;
678
- },
679
- set(value) {
680
- if (emit) {
681
- emit(`update:${propName}`, value);
682
- }
683
- }
684
- });
685
- }
686
- return {
687
- group,
688
- isInGroup,
689
- getGroupOrLocalRef
690
- };
691
- }
692
- const VvButtonEvents = ["update:modelValue"];
693
- const VvButtonProps = {
694
- ...ActionProps,
695
- ...IdProps,
696
- ...ModifiersProps,
697
- ...UnselectableProps,
698
- ...LoadingProps,
699
- ...IconProps,
428
+ },
700
429
  /**
701
- * Button icon position
430
+ * Max number of files
702
431
  */
703
- iconPosition: {
432
+ max: { type: [Number, String], default: void 0 },
433
+ /**
434
+ * Show drop area
435
+ */
436
+ dropArea: { type: Boolean, default: false },
437
+ /**
438
+ * Enable sorting
439
+ */
440
+ sortable: { type: Boolean, default: false },
441
+ /**
442
+ * Label for add button
443
+ */
444
+ labelAdd: {
704
445
  type: String,
705
- default: Side.left,
706
- validator: (value) => Object.values(Side).includes(value)
446
+ default: "Add file"
707
447
  },
708
448
  /**
709
- * Loading icon
449
+ * VvIcon name for add button
450
+ * @see VVIcon
710
451
  */
711
- loadingIcon: { type: String, default: "eos-icons:bubble-loading" },
452
+ iconAdd: {
453
+ type: [String, Object],
454
+ default: ACTION_ICONS.add
455
+ },
712
456
  /**
713
- * Enable button toggle
457
+ * Label for replace button
714
458
  */
715
- toggle: {
716
- type: Boolean,
717
- default: false
459
+ labelReplace: {
460
+ type: String,
461
+ default: "Replace file"
718
462
  },
719
463
  /**
720
- * Button toggle value
464
+ * VvIcon name for replace button
465
+ * @see VVIcon
721
466
  */
722
- value: {
723
- type: [String, Number, Boolean],
724
- default: void 0
467
+ iconReplace: {
468
+ type: [String, Object],
469
+ default: ACTION_ICONS.edit
725
470
  },
726
471
  /**
727
- * Value associated with the unchecked state
472
+ * Label for download button
728
473
  */
729
- uncheckedValue: {
730
- type: [String, Number, Boolean],
731
- default: void 0
474
+ labelDownload: {
475
+ type: String,
476
+ default: "Downlaod file"
732
477
  },
733
478
  /**
734
- * Button toggle model value
479
+ * VvIcon name for download button
480
+ * @see VVIcon
735
481
  */
736
- modelValue: {
737
- type: [String, Number, Boolean],
738
- default: void 0
482
+ iconDownload: {
483
+ type: [String, Object],
484
+ default: ACTION_ICONS.download
485
+ },
486
+ /**
487
+ * Label for remove button
488
+ */
489
+ labelRemove: {
490
+ type: String,
491
+ default: "Remove file"
739
492
  }
740
493
  };
741
- function useGroupProps(props, emit) {
742
- const { group, isInGroup, getGroupOrLocalRef } = useInjectedGroupState(INJECTION_KEY_BUTTON_GROUP);
743
- const { id, iconPosition, icon, label, pressed } = toRefs(props);
744
- const modelValue = getGroupOrLocalRef("modelValue", props, emit);
745
- const toggle = getGroupOrLocalRef("toggle", props);
746
- const unselectable = getGroupOrLocalRef("unselectable", props);
747
- const multiple = computed(() => (group == null ? void 0 : group.multiple.value) ?? false);
748
- const modifiers = computed(() => {
749
- let localModifiers = props.modifiers;
750
- let groupModifiers = group == null ? void 0 : group.modifiers.value;
751
- const toReturn = /* @__PURE__ */ new Set();
752
- if (localModifiers) {
753
- if (!Array.isArray(localModifiers)) {
754
- localModifiers = localModifiers.split(" ");
755
- }
756
- localModifiers.forEach((modifier) => toReturn.add(modifier));
757
- }
758
- if (groupModifiers) {
759
- if (!Array.isArray(groupModifiers)) {
760
- groupModifiers = groupModifiers.split(" ");
761
- }
762
- groupModifiers.forEach((modifier) => toReturn.add(modifier));
763
- }
764
- return Array.from(toReturn);
765
- });
766
- const disabled = computed(
767
- () => Boolean(props.disabled || (group == null ? void 0 : group.disabled.value))
768
- );
769
- return {
770
- // group props
771
- group,
772
- isInGroup,
773
- modelValue,
774
- toggle,
775
- unselectable,
776
- multiple,
777
- modifiers,
778
- disabled,
779
- // local props
780
- id,
781
- pressed,
782
- iconPosition,
783
- icon,
784
- label
785
- };
786
- }
787
- function useUniqueId(id) {
788
- return computed(() => String((id == null ? void 0 : id.value) || uid()));
789
- }
790
494
  function equals(obj1, obj2, field) {
791
495
  return deepEquals(obj1, obj2);
792
496
  }
@@ -846,10 +550,539 @@ function contains(value, list) {
846
550
  }
847
551
  }
848
552
  }
849
- return false;
850
- }
851
- function isString(value) {
852
- return typeof value === "string" || value instanceof String;
553
+ return false;
554
+ }
555
+ function isString(value) {
556
+ return typeof value === "string" || value instanceof String;
557
+ }
558
+ function joinLines(items) {
559
+ if (Array.isArray(items)) {
560
+ return items.filter((item) => isString(item)).join(" ");
561
+ }
562
+ return items;
563
+ }
564
+ function HintSlotFactory(propsOrRef, slots) {
565
+ const props = computed(() => {
566
+ if (isRef(propsOrRef)) {
567
+ return propsOrRef.value;
568
+ }
569
+ return propsOrRef;
570
+ });
571
+ const invalidLabel = computed(() => joinLines(props.value.invalidLabel));
572
+ const validLabel = computed(() => joinLines(props.value.validLabel));
573
+ const loadingLabel = computed(() => props.value.loadingLabel);
574
+ const hintLabel = computed(() => props.value.hintLabel);
575
+ const hasLoadingLabelOrSlot = computed(
576
+ () => Boolean(props.value.loading && (slots.loading || loadingLabel.value))
577
+ );
578
+ const hasInvalidLabelOrSlot = computed(
579
+ () => !hasLoadingLabelOrSlot.value && Boolean(
580
+ props.value.invalid && (slots.invalid || invalidLabel.value)
581
+ )
582
+ );
583
+ const hasValidLabelOrSlot = computed(
584
+ () => !hasLoadingLabelOrSlot.value && !hasInvalidLabelOrSlot.value && Boolean(props.value.valid && (slots.valid || validLabel.value))
585
+ );
586
+ const hasHintLabelOrSlot = computed(
587
+ () => !hasLoadingLabelOrSlot.value && !hasInvalidLabelOrSlot.value && !hasValidLabelOrSlot.value && Boolean(slots.hint || hintLabel.value)
588
+ );
589
+ const isVisible = computed(
590
+ () => hasInvalidLabelOrSlot.value || hasValidLabelOrSlot.value || hasLoadingLabelOrSlot.value || hasHintLabelOrSlot.value
591
+ );
592
+ const hintSlotScope = computed(() => ({
593
+ modelValue: props.value.modelValue,
594
+ valid: props.value.valid,
595
+ invalid: props.value.invalid,
596
+ loading: props.value.loading
597
+ }));
598
+ const HintSlot = defineComponent({
599
+ name: "HintSlot",
600
+ props: {
601
+ tag: {
602
+ type: String,
603
+ default: "small"
604
+ }
605
+ },
606
+ setup() {
607
+ return {
608
+ isVisible,
609
+ invalidLabel,
610
+ validLabel,
611
+ loadingLabel,
612
+ hintLabel,
613
+ hasInvalidLabelOrSlot,
614
+ hasValidLabelOrSlot,
615
+ hasLoadingLabelOrSlot,
616
+ hasHintLabelOrSlot
617
+ };
618
+ },
619
+ render() {
620
+ var _a, _b, _c, _d, _e, _f, _g, _h;
621
+ if (this.isVisible) {
622
+ let role;
623
+ if (this.hasInvalidLabelOrSlot) {
624
+ role = "alert";
625
+ }
626
+ if (this.hasValidLabelOrSlot) {
627
+ role = "status";
628
+ }
629
+ if (this.hasLoadingLabelOrSlot) {
630
+ return h(
631
+ this.tag,
632
+ {
633
+ role
634
+ },
635
+ ((_b = (_a = this.$slots).loading) == null ? void 0 : _b.call(_a)) ?? this.loadingLabel
636
+ );
637
+ }
638
+ if (this.hasInvalidLabelOrSlot) {
639
+ return h(
640
+ this.tag,
641
+ {
642
+ role
643
+ },
644
+ ((_d = (_c = this.$slots).invalid) == null ? void 0 : _d.call(_c)) ?? this.$slots.invalid ?? this.invalidLabel
645
+ );
646
+ }
647
+ if (this.hasValidLabelOrSlot) {
648
+ return h(
649
+ this.tag,
650
+ {
651
+ role
652
+ },
653
+ ((_f = (_e = this.$slots).valid) == null ? void 0 : _f.call(_e)) ?? this.validLabel
654
+ );
655
+ }
656
+ return h(
657
+ this.tag,
658
+ {
659
+ role
660
+ },
661
+ ((_h = (_g = this.$slots).hint) == null ? void 0 : _h.call(_g)) ?? this.$slots.hint ?? this.hintLabel
662
+ );
663
+ }
664
+ return null;
665
+ }
666
+ });
667
+ return {
668
+ hasInvalidLabelOrSlot,
669
+ hasHintLabelOrSlot,
670
+ hasValidLabelOrSlot,
671
+ hasLoadingLabelOrSlot,
672
+ hintSlotScope,
673
+ HintSlot
674
+ };
675
+ }
676
+ function useGroupStateInject(groupKey) {
677
+ const group = inject(groupKey, void 0);
678
+ const isInGroup = computed(() => group !== void 0);
679
+ function getGroupOrLocalRef(propName, props, emit) {
680
+ const groupPropValue = group == null ? void 0 : group[propName];
681
+ if (groupPropValue) {
682
+ return computed({
683
+ get() {
684
+ return groupPropValue.value;
685
+ },
686
+ set(value) {
687
+ groupPropValue.value = value;
688
+ }
689
+ });
690
+ }
691
+ const propRef = toRef(props, propName);
692
+ return computed({
693
+ get() {
694
+ return propRef.value;
695
+ },
696
+ set(value) {
697
+ if (emit) {
698
+ emit(`update:${propName}`, value);
699
+ }
700
+ }
701
+ });
702
+ }
703
+ return {
704
+ group,
705
+ isInGroup,
706
+ getGroupOrLocalRef
707
+ };
708
+ }
709
+ const VvButtonEvents = ["update:modelValue"];
710
+ const VvButtonProps = {
711
+ ...ActionProps,
712
+ ...IdProps,
713
+ ...ModifiersProps,
714
+ ...UnselectableProps,
715
+ ...LoadingProps,
716
+ ...IconProps,
717
+ /**
718
+ * Button icon position
719
+ */
720
+ iconPosition: {
721
+ type: String,
722
+ default: Side.left,
723
+ validator: (value) => Object.values(Side).includes(value)
724
+ },
725
+ /**
726
+ * Loading icon
727
+ */
728
+ loadingIcon: { type: String, default: "eos-icons:bubble-loading" },
729
+ /**
730
+ * Enable button toggle
731
+ */
732
+ toggle: {
733
+ type: Boolean,
734
+ default: false
735
+ },
736
+ /**
737
+ * Button toggle value
738
+ */
739
+ value: {
740
+ type: [String, Number, Boolean],
741
+ default: void 0
742
+ },
743
+ /**
744
+ * Value associated with the unchecked state
745
+ */
746
+ uncheckedValue: {
747
+ type: [String, Number, Boolean],
748
+ default: void 0
749
+ },
750
+ /**
751
+ * Button toggle model value
752
+ */
753
+ modelValue: {
754
+ type: [String, Number, Boolean],
755
+ default: void 0
756
+ }
757
+ };
758
+ function useGroupProps(props, emit) {
759
+ const { group, isInGroup, getGroupOrLocalRef } = useGroupStateInject(INJECTION_KEY_BUTTON_GROUP);
760
+ const { id, iconPosition, icon, label, pressed } = toRefs(props);
761
+ const modelValue = getGroupOrLocalRef("modelValue", props, emit);
762
+ const toggle = getGroupOrLocalRef("toggle", props);
763
+ const unselectable = getGroupOrLocalRef("unselectable", props);
764
+ const multiple = computed(() => (group == null ? void 0 : group.multiple.value) ?? false);
765
+ const modifiers = computed(() => {
766
+ let localModifiers = props.modifiers;
767
+ let groupModifiers = group == null ? void 0 : group.modifiers.value;
768
+ const toReturn = /* @__PURE__ */ new Set();
769
+ if (localModifiers) {
770
+ if (!Array.isArray(localModifiers)) {
771
+ localModifiers = localModifiers.split(" ");
772
+ }
773
+ localModifiers.forEach((modifier) => toReturn.add(modifier));
774
+ }
775
+ if (groupModifiers) {
776
+ if (!Array.isArray(groupModifiers)) {
777
+ groupModifiers = groupModifiers.split(" ");
778
+ }
779
+ groupModifiers.forEach((modifier) => toReturn.add(modifier));
780
+ }
781
+ return Array.from(toReturn);
782
+ });
783
+ const disabled = computed(
784
+ () => Boolean(props.disabled || (group == null ? void 0 : group.disabled.value))
785
+ );
786
+ return {
787
+ // group props
788
+ group,
789
+ isInGroup,
790
+ modelValue,
791
+ toggle,
792
+ unselectable,
793
+ multiple,
794
+ modifiers,
795
+ disabled,
796
+ // local props
797
+ id,
798
+ pressed,
799
+ iconPosition,
800
+ icon,
801
+ label
802
+ };
803
+ }
804
+ const VvActionEvents = ["click", "mouseover", "mouseleave"];
805
+ const VvActionProps = ActionProps;
806
+ function useVolver() {
807
+ return inject(INJECTION_KEY_VOLVER);
808
+ }
809
+ function useInjectedDropdownTrigger() {
810
+ return inject(INJECTION_KEY_DROPDOWN_TRIGGER, {});
811
+ }
812
+ function useInjectedDropdownAction() {
813
+ return inject(INJECTION_KEY_DROPDOWN_ACTION, {});
814
+ }
815
+ const __default__$3 = {
816
+ name: "VvAction"
817
+ };
818
+ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
819
+ ...__default__$3,
820
+ props: VvActionProps,
821
+ emits: VvActionEvents,
822
+ setup(__props, { expose: __expose, emit: __emit }) {
823
+ const props = __props;
824
+ const emit = __emit;
825
+ const instance = getCurrentInstance();
826
+ const volver = useVolver();
827
+ const element = ref(null);
828
+ __expose({ $el: element });
829
+ const {
830
+ reference: dropdownTriggerReference,
831
+ bus: dropdownEventBus,
832
+ aria: dropdownAria,
833
+ expanded: dropdownExpanded
834
+ } = useInjectedDropdownTrigger();
835
+ watch(
836
+ () => element.value,
837
+ (newValue) => {
838
+ if (dropdownTriggerReference) {
839
+ dropdownTriggerReference.value = newValue;
840
+ }
841
+ }
842
+ );
843
+ const pressed = computed(() => {
844
+ return props.pressed || (dropdownExpanded == null ? void 0 : dropdownExpanded.value);
845
+ });
846
+ const { role } = useInjectedDropdownAction();
847
+ const hasTag = computed(() => {
848
+ switch (true) {
849
+ case props.disabled:
850
+ return ActionTag.button;
851
+ case props.to !== void 0:
852
+ return (volver == null ? void 0 : volver.nuxt) ? ActionTag.nuxtLink : ActionTag.routerLink;
853
+ case props.href !== void 0:
854
+ return ActionTag.a;
855
+ default:
856
+ return props.defaultTag;
857
+ }
858
+ });
859
+ const hasProps = computed(() => {
860
+ const toReturn = {
861
+ ...dropdownAria == null ? void 0 : dropdownAria.value,
862
+ ariaPressed: pressed.value ? true : void 0,
863
+ ariaLabel: props.ariaLabel,
864
+ role: role == null ? void 0 : role.value
865
+ };
866
+ switch (hasTag.value) {
867
+ case ActionTag.a:
868
+ return {
869
+ ...toReturn,
870
+ href: props.href,
871
+ target: props.target,
872
+ rel: props.rel
873
+ };
874
+ case ActionTag.routerLink:
875
+ case ActionTag.nuxtLink:
876
+ return {
877
+ ...toReturn,
878
+ to: props.to,
879
+ target: props.target
880
+ };
881
+ case ActionTag.button:
882
+ return {
883
+ ...toReturn,
884
+ type: props.type,
885
+ disabled: props.disabled
886
+ };
887
+ default:
888
+ return toReturn;
889
+ }
890
+ });
891
+ function onClick(e) {
892
+ var _a;
893
+ if (props.disabled) {
894
+ e.preventDefault();
895
+ return;
896
+ }
897
+ if ((_a = instance == null ? void 0 : instance.vnode.props) == null ? void 0 : _a.onClick) {
898
+ emit("click", e);
899
+ return;
900
+ }
901
+ dropdownEventBus == null ? void 0 : dropdownEventBus.emit("click", e);
902
+ }
903
+ function onMouseover(e) {
904
+ var _a;
905
+ if ((_a = instance == null ? void 0 : instance.vnode.props) == null ? void 0 : _a.onMouseover) {
906
+ emit("mouseover", e);
907
+ return;
908
+ }
909
+ dropdownEventBus == null ? void 0 : dropdownEventBus.emit("mouseover", e);
910
+ }
911
+ function onMouseleave(e) {
912
+ var _a;
913
+ if ((_a = instance == null ? void 0 : instance.vnode.props) == null ? void 0 : _a.onMouseleave) {
914
+ emit("mouseleave", e);
915
+ return;
916
+ }
917
+ dropdownEventBus == null ? void 0 : dropdownEventBus.emit("mouseleave", e);
918
+ }
919
+ return (_ctx, _cache) => {
920
+ return openBlock(), createBlock(resolveDynamicComponent(unref(hasTag)), mergeProps(unref(hasProps), {
921
+ ref_key: "element",
922
+ ref: element,
923
+ class: {
924
+ active: _ctx.active,
925
+ pressed: unref(pressed),
926
+ disabled: _ctx.disabled,
927
+ current: _ctx.current
928
+ },
929
+ onClickPassive: onClick,
930
+ onMouseoverPassive: onMouseover,
931
+ onMouseleavePassive: onMouseleave
932
+ }), {
933
+ default: withCtx(() => [
934
+ renderSlot(_ctx.$slots, "default", {}, () => [
935
+ createTextVNode(
936
+ toDisplayString(_ctx.label),
937
+ 1
938
+ /* TEXT */
939
+ )
940
+ ])
941
+ ]),
942
+ _: 3
943
+ /* FORWARDED */
944
+ }, 16, ["class"]);
945
+ };
946
+ }
947
+ });
948
+ function useModifiers(prefix, modifiers, others) {
949
+ return computed(() => {
950
+ const toReturn = {
951
+ [prefix]: true
952
+ };
953
+ const modifiersArray = typeof (modifiers == null ? void 0 : modifiers.value) === "string" ? modifiers.value.split(" ") : modifiers == null ? void 0 : modifiers.value;
954
+ if (modifiersArray) {
955
+ if (Array.isArray(modifiersArray)) {
956
+ modifiersArray.forEach((modifier) => {
957
+ if (modifier) {
958
+ toReturn[`${prefix}--${modifier}`] = true;
959
+ }
960
+ });
961
+ }
962
+ }
963
+ if (others) {
964
+ Object.keys(others.value).forEach((key) => {
965
+ toReturn[`${prefix}--${key}`] = unref(others.value[key]);
966
+ });
967
+ }
968
+ return toReturn;
969
+ });
970
+ }
971
+ const __default__$2 = {
972
+ name: "VvIcon"
973
+ };
974
+ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
975
+ ...__default__$2,
976
+ props: /* @__PURE__ */ mergeDefaults({
977
+ name: {},
978
+ color: {},
979
+ width: {},
980
+ height: {},
981
+ provider: {},
982
+ prefix: {},
983
+ src: {},
984
+ horizontalFlip: { type: Boolean },
985
+ verticalFlip: { type: Boolean },
986
+ flip: {},
987
+ mode: {},
988
+ inline: { type: Boolean },
989
+ rotate: {},
990
+ onLoad: { type: Function },
991
+ svg: {},
992
+ modifiers: {}
993
+ }, VvIconPropsDefaults),
994
+ setup(__props) {
995
+ const props = __props;
996
+ const hasRotate = computed(() => {
997
+ if (typeof props.rotate === "string") {
998
+ return Number.parseFloat(props.rotate);
999
+ }
1000
+ return props.rotate;
1001
+ });
1002
+ const show = ref(true);
1003
+ const volver = useVolver();
1004
+ const { modifiers } = toRefs(props);
1005
+ const bemCssClasses = useModifiers("vv-icon", modifiers);
1006
+ const provider = computed(() => {
1007
+ return props.provider || (volver == null ? void 0 : volver.iconsProvider);
1008
+ });
1009
+ const icon = computed(() => {
1010
+ const name = props.name ?? "";
1011
+ const iconName = `@${provider.value}:${props.prefix}:${name}`;
1012
+ if (iconExists(iconName)) {
1013
+ return iconName;
1014
+ }
1015
+ const iconsCollection = volver == null ? void 0 : volver.iconsCollections.find(
1016
+ (iconsCollection2) => {
1017
+ const icon2 = `@${provider.value}:${iconsCollection2.prefix}:${name}`;
1018
+ return iconExists(icon2);
1019
+ }
1020
+ );
1021
+ if (iconsCollection) {
1022
+ return `@${provider.value}:${iconsCollection.prefix}:${name}`;
1023
+ }
1024
+ return name;
1025
+ });
1026
+ function getSvgContent(svg) {
1027
+ let dom;
1028
+ if (typeof window === "undefined") {
1029
+ const { JSDOM } = require("jsdom");
1030
+ dom = new JSDOM().window;
1031
+ }
1032
+ const domParser = dom ? new dom.DOMParser() : new window.DOMParser();
1033
+ const svgDomString = domParser.parseFromString(svg, "text/html");
1034
+ const svgEl = svgDomString.querySelector("svg");
1035
+ return svgEl;
1036
+ }
1037
+ function addIconFromSvg(svg) {
1038
+ const svgContentEl = getSvgContent(svg);
1039
+ const svgContent = (svgContentEl == null ? void 0 : svgContentEl.innerHTML.trim()) || "";
1040
+ if (svgContentEl && svgContent) {
1041
+ addIcon(`@${provider.value}:${props.prefix}:${props.name}`, {
1042
+ body: svgContent,
1043
+ // Set height and width from svg content
1044
+ height: svgContentEl.viewBox.baseVal.height,
1045
+ width: svgContentEl.viewBox.baseVal.width
1046
+ });
1047
+ }
1048
+ }
1049
+ if (volver) {
1050
+ if (props.src && !iconExists(`@${provider.value}:${props.prefix}:${props.name}`)) {
1051
+ show.value = false;
1052
+ volver.fetchIcon(props.src).then((svg) => {
1053
+ if (svg) {
1054
+ addIconFromSvg(svg);
1055
+ show.value = true;
1056
+ }
1057
+ }).catch((e) => {
1058
+ throw new Error(`Error during fetch icon: ${e == null ? void 0 : e.message}`);
1059
+ });
1060
+ }
1061
+ }
1062
+ if (props.svg) {
1063
+ addIconFromSvg(props.svg);
1064
+ }
1065
+ return (_ctx, _cache) => {
1066
+ return unref(show) ? (openBlock(), createBlock(unref(Icon), mergeProps({
1067
+ key: 0,
1068
+ class: unref(bemCssClasses)
1069
+ }, {
1070
+ inline: _ctx.inline,
1071
+ width: _ctx.width,
1072
+ height: _ctx.height,
1073
+ horizontalFlip: _ctx.horizontalFlip,
1074
+ verticalFlip: _ctx.verticalFlip,
1075
+ flip: _ctx.flip,
1076
+ rotate: unref(hasRotate),
1077
+ color: _ctx.color,
1078
+ onLoad: _ctx.onLoad,
1079
+ icon: unref(icon)
1080
+ }), null, 16, ["class"])) : createCommentVNode("v-if", true);
1081
+ };
1082
+ }
1083
+ });
1084
+ function useUniqueId(id) {
1085
+ return computed(() => String((id == null ? void 0 : id.value) || useId()));
853
1086
  }
854
1087
  function useComponentIcon(icon, iconPosition) {
855
1088
  const hasIcon = computed(() => {
@@ -984,7 +1217,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
984
1217
  }
985
1218
  }
986
1219
  return (_ctx, _cache) => {
987
- return openBlock(), createBlock(_sfc_main$2, mergeProps({
1220
+ return openBlock(), createBlock(_sfc_main$3, mergeProps({
988
1221
  ...unref(attrs),
989
1222
  ...unref(hasListeners),
990
1223
  disabled: unref(disabled),
@@ -1005,7 +1238,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
1005
1238
  default: withCtx(() => [
1006
1239
  renderSlot(_ctx.$slots, "default", {}, () => [
1007
1240
  _ctx.loading ? renderSlot(_ctx.$slots, "loading", { key: 0 }, () => [
1008
- _ctx.loadingIcon ? (openBlock(), createBlock(_sfc_main$3, {
1241
+ _ctx.loadingIcon ? (openBlock(), createBlock(_sfc_main$2, {
1009
1242
  key: 0,
1010
1243
  class: "vv-button__loading-icon",
1011
1244
  name: _ctx.loadingIcon
@@ -1023,7 +1256,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
1023
1256
  [
1024
1257
  renderSlot(_ctx.$slots, "before"),
1025
1258
  unref(hasIcon) ? (openBlock(), createBlock(
1026
- _sfc_main$3,
1259
+ _sfc_main$2,
1027
1260
  mergeProps({ key: 0 }, unref(hasIcon), { class: "vv-button__icon" }),
1028
1261
  null,
1029
1262
  16
@@ -1051,240 +1284,6 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
1051
1284
  };
1052
1285
  }
1053
1286
  });
1054
- function joinLines(items) {
1055
- if (Array.isArray(items)) {
1056
- return items.filter((item) => isString(item)).join(" ");
1057
- }
1058
- return items;
1059
- }
1060
- function HintSlotFactory(propsOrRef, slots) {
1061
- const props = computed(() => {
1062
- if (isRef(propsOrRef)) {
1063
- return propsOrRef.value;
1064
- }
1065
- return propsOrRef;
1066
- });
1067
- const invalidLabel = computed(() => joinLines(props.value.invalidLabel));
1068
- const validLabel = computed(() => joinLines(props.value.validLabel));
1069
- const loadingLabel = computed(() => props.value.loadingLabel);
1070
- const hintLabel = computed(() => props.value.hintLabel);
1071
- const hasLoadingLabelOrSlot = computed(
1072
- () => Boolean(props.value.loading && (slots.loading || loadingLabel.value))
1073
- );
1074
- const hasInvalidLabelOrSlot = computed(
1075
- () => !hasLoadingLabelOrSlot.value && Boolean(
1076
- props.value.invalid && (slots.invalid || invalidLabel.value)
1077
- )
1078
- );
1079
- const hasValidLabelOrSlot = computed(
1080
- () => !hasLoadingLabelOrSlot.value && !hasInvalidLabelOrSlot.value && Boolean(props.value.valid && (slots.valid || validLabel.value))
1081
- );
1082
- const hasHintLabelOrSlot = computed(
1083
- () => !hasLoadingLabelOrSlot.value && !hasInvalidLabelOrSlot.value && !hasValidLabelOrSlot.value && Boolean(slots.hint || hintLabel.value)
1084
- );
1085
- const isVisible = computed(
1086
- () => hasInvalidLabelOrSlot.value || hasValidLabelOrSlot.value || hasLoadingLabelOrSlot.value || hasHintLabelOrSlot.value
1087
- );
1088
- const hintSlotScope = computed(() => ({
1089
- modelValue: props.value.modelValue,
1090
- valid: props.value.valid,
1091
- invalid: props.value.invalid,
1092
- loading: props.value.loading
1093
- }));
1094
- const HintSlot = defineComponent({
1095
- name: "HintSlot",
1096
- props: {
1097
- tag: {
1098
- type: String,
1099
- default: "small"
1100
- }
1101
- },
1102
- setup() {
1103
- return {
1104
- isVisible,
1105
- invalidLabel,
1106
- validLabel,
1107
- loadingLabel,
1108
- hintLabel,
1109
- hasInvalidLabelOrSlot,
1110
- hasValidLabelOrSlot,
1111
- hasLoadingLabelOrSlot,
1112
- hasHintLabelOrSlot
1113
- };
1114
- },
1115
- render() {
1116
- var _a, _b, _c, _d, _e, _f, _g, _h;
1117
- if (this.isVisible) {
1118
- let role;
1119
- if (this.hasInvalidLabelOrSlot) {
1120
- role = "alert";
1121
- }
1122
- if (this.hasValidLabelOrSlot) {
1123
- role = "status";
1124
- }
1125
- if (this.hasLoadingLabelOrSlot) {
1126
- return h(
1127
- this.tag,
1128
- {
1129
- role
1130
- },
1131
- ((_b = (_a = this.$slots).loading) == null ? void 0 : _b.call(_a)) ?? this.loadingLabel
1132
- );
1133
- }
1134
- if (this.hasInvalidLabelOrSlot) {
1135
- return h(
1136
- this.tag,
1137
- {
1138
- role
1139
- },
1140
- ((_d = (_c = this.$slots).invalid) == null ? void 0 : _d.call(_c)) ?? this.$slots.invalid ?? this.invalidLabel
1141
- );
1142
- }
1143
- if (this.hasValidLabelOrSlot) {
1144
- return h(
1145
- this.tag,
1146
- {
1147
- role
1148
- },
1149
- ((_f = (_e = this.$slots).valid) == null ? void 0 : _f.call(_e)) ?? this.validLabel
1150
- );
1151
- }
1152
- return h(
1153
- this.tag,
1154
- {
1155
- role
1156
- },
1157
- ((_h = (_g = this.$slots).hint) == null ? void 0 : _h.call(_g)) ?? this.$slots.hint ?? this.hintLabel
1158
- );
1159
- }
1160
- return null;
1161
- }
1162
- });
1163
- return {
1164
- hasInvalidLabelOrSlot,
1165
- hasHintLabelOrSlot,
1166
- hasValidLabelOrSlot,
1167
- hasLoadingLabelOrSlot,
1168
- hintSlotScope,
1169
- HintSlot
1170
- };
1171
- }
1172
- const VvInputFileProps = {
1173
- ...IdNameProps,
1174
- ...ModifiersProps,
1175
- ...ValidProps,
1176
- ...InvalidProps,
1177
- ...HintProps,
1178
- ...LabelProps,
1179
- ...LoadingProps,
1180
- ...ReadonlyProps,
1181
- ...DisabledProps,
1182
- ...IconProps,
1183
- /**
1184
- * Input value
1185
- */
1186
- modelValue: {
1187
- type: Object
1188
- },
1189
- /**
1190
- * Whether to show progress bar
1191
- */
1192
- progress: { type: [Number, String], default: void 0 },
1193
- /**
1194
- * Input
1195
- * Text that appears in the form control when it has no value set
1196
- * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#placeholder
1197
- */
1198
- placeholder: { type: String, default: void 0 },
1199
- /**
1200
- * File types to accept
1201
- * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/accept
1202
- */
1203
- accept: { type: String, default: "*" },
1204
- /**
1205
- * Whether to allow multiple values
1206
- * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#multiple
1207
- */
1208
- multiple: { type: Boolean, default: false },
1209
- /**
1210
- * Front or rear camera
1211
- * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/capture
1212
- */
1213
- capture: {
1214
- type: String,
1215
- default: void 0,
1216
- validation: (value) => {
1217
- if (value === void 0) {
1218
- return true;
1219
- }
1220
- return ["user", "environment"].includes(value);
1221
- }
1222
- },
1223
- /**
1224
- * Max number of files
1225
- */
1226
- max: { type: [Number, String], default: void 0 },
1227
- /**
1228
- * Show drop area
1229
- */
1230
- dropArea: { type: Boolean, default: false },
1231
- /**
1232
- * Enable sorting
1233
- */
1234
- sortable: { type: Boolean, default: false },
1235
- /**
1236
- * Label for add button
1237
- */
1238
- labelAdd: {
1239
- type: String,
1240
- default: "Add file"
1241
- },
1242
- /**
1243
- * VvIcon name for add button
1244
- * @see VVIcon
1245
- */
1246
- iconAdd: {
1247
- type: [String, Object],
1248
- default: ACTION_ICONS.add
1249
- },
1250
- /**
1251
- * Label for replace button
1252
- */
1253
- labelReplace: {
1254
- type: String,
1255
- default: "Replace file"
1256
- },
1257
- /**
1258
- * VvIcon name for replace button
1259
- * @see VVIcon
1260
- */
1261
- iconReplace: {
1262
- type: [String, Object],
1263
- default: ACTION_ICONS.edit
1264
- },
1265
- /**
1266
- * Label for download button
1267
- */
1268
- labelDownload: {
1269
- type: String,
1270
- default: "Downlaod file"
1271
- },
1272
- /**
1273
- * VvIcon name for download button
1274
- * @see VVIcon
1275
- */
1276
- iconDownload: {
1277
- type: [String, Object],
1278
- default: ACTION_ICONS.download
1279
- },
1280
- /**
1281
- * Label for remove button
1282
- */
1283
- labelRemove: {
1284
- type: String,
1285
- default: "Remove file"
1286
- }
1287
- };
1288
1287
  function useDefaults(componentName, propsDefinition, props) {
1289
1288
  const volver = useVolver();
1290
1289
  const volverComponentDefaults = computed(() => {
@@ -1430,7 +1429,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
1430
1429
  return hasMax.value - files.value.length > 1;
1431
1430
  });
1432
1431
  const isDragging = ref(false);
1433
- const inputEl = ref();
1432
+ const inputEl = useTemplateRef("inputEl");
1434
1433
  function onDragenter() {
1435
1434
  isDragging.value = true;
1436
1435
  }
@@ -1634,7 +1633,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
1634
1633
  )) : createCommentVNode("v-if", true),
1635
1634
  createElementVNode("div", _hoisted_4, [
1636
1635
  unref(hasIconBefore) ? (openBlock(), createBlock(
1637
- _sfc_main$3,
1636
+ _sfc_main$2,
1638
1637
  normalizeProps(mergeProps({ key: 0 }, unref(hasIconBefore))),
1639
1638
  null,
1640
1639
  16
@@ -1664,7 +1663,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
1664
1663
  max: "100"
1665
1664
  }, toDisplayString(_ctx.progress) + "% ", 9, _hoisted_6)) : createCommentVNode("v-if", true),
1666
1665
  unref(hasIconAfter) ? (openBlock(), createBlock(
1667
- _sfc_main$3,
1666
+ _sfc_main$2,
1668
1667
  normalizeProps(mergeProps({ key: 2 }, unref(hasIconAfter))),
1669
1668
  null,
1670
1669
  16
@@ -1696,7 +1695,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
1696
1695
  onClick: withModifiers(($event) => onClickDownloadFile(file), ["stop"])
1697
1696
  }, [
1698
1697
  createVNode(
1699
- _sfc_main$3,
1698
+ _sfc_main$2,
1700
1699
  normalizeProps(guardReactiveProps(unref(hasIconDownload))),
1701
1700
  null,
1702
1701
  16