@volverjs/ui-vue 0.0.3-beta.4 → 0.0.4

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 (853) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +56 -16
  3. package/auto-imports.d.ts +10 -6
  4. package/bin/icons.cjs +8 -8
  5. package/bin/icons.js +8 -8
  6. package/dist/Volver.d.ts +43 -13
  7. package/dist/components/VvAccordion/VvAccordion.es.js +133 -59
  8. package/dist/components/VvAccordion/VvAccordion.umd.js +1 -1
  9. package/dist/components/VvAccordion/index.d.ts +2 -2
  10. package/dist/components/VvAccordionGroup/VvAccordionGroup.es.js +207 -100
  11. package/dist/components/VvAccordionGroup/VvAccordionGroup.umd.js +1 -1
  12. package/dist/components/VvAccordionGroup/VvAccordionGroup.vue.d.ts +1 -1
  13. package/dist/components/VvAction/VvAction.es.js +170 -0
  14. package/dist/components/VvAction/VvAction.umd.js +1 -0
  15. package/dist/components/VvAction/VvAction.vue.d.ts +63 -0
  16. package/dist/components/VvAction/index.d.ts +24 -0
  17. package/dist/components/VvBadge/VvBadge.es.js +92 -17
  18. package/dist/components/VvBadge/VvBadge.umd.js +1 -1
  19. package/dist/components/VvBreadcrumb/VvBreadcrumb.es.js +104 -57
  20. package/dist/components/VvBreadcrumb/VvBreadcrumb.umd.js +1 -1
  21. package/dist/components/VvButton/VvButton.es.js +526 -202
  22. package/dist/components/VvButton/VvButton.umd.js +1 -1
  23. package/dist/components/VvButton/VvButton.vue.d.ts +59 -62
  24. package/dist/components/VvButton/index.d.ts +32 -83
  25. package/dist/components/VvButtonGroup/VvButtonGroup.es.js +133 -43
  26. package/dist/components/VvButtonGroup/VvButtonGroup.umd.js +1 -1
  27. package/dist/components/VvButtonGroup/VvButtonGroup.vue.d.ts +1 -1
  28. package/dist/components/VvCard/VvCard.es.js +38 -27
  29. package/dist/components/VvCard/VvCard.umd.js +1 -1
  30. package/dist/components/VvCheckbox/VvCheckbox.es.js +386 -147
  31. package/dist/components/VvCheckbox/VvCheckbox.umd.js +1 -1
  32. package/dist/components/VvCheckbox/VvCheckbox.vue.d.ts +7 -5
  33. package/dist/components/VvCheckbox/index.d.ts +6 -10
  34. package/dist/components/VvCheckboxGroup/VvCheckboxGroup.es.js +475 -189
  35. package/dist/components/VvCheckboxGroup/VvCheckboxGroup.umd.js +1 -1
  36. package/dist/components/VvCheckboxGroup/VvCheckboxGroup.vue.d.ts +14 -3
  37. package/dist/components/VvCheckboxGroup/index.d.ts +6 -1
  38. package/dist/components/VvCombobox/VvCombobox.es.js +1488 -457
  39. package/dist/components/VvCombobox/VvCombobox.umd.js +1 -1
  40. package/dist/components/VvCombobox/VvCombobox.vue.d.ts +282 -25
  41. package/dist/components/VvCombobox/index.d.ts +141 -15
  42. package/dist/components/VvDialog/VvDialog.es.js +248 -82
  43. package/dist/components/VvDialog/VvDialog.umd.js +1 -1
  44. package/dist/components/VvDialog/VvDialog.vue.d.ts +3 -9
  45. package/dist/components/VvDialog/index.d.ts +16 -4
  46. package/dist/components/VvDropdown/VvDropdown.es.js +448 -89
  47. package/dist/components/VvDropdown/VvDropdown.umd.js +1 -1
  48. package/dist/components/VvDropdown/VvDropdown.vue.d.ts +184 -51
  49. package/dist/components/VvDropdown/VvDropdownAction.vue.d.ts +61 -0
  50. package/dist/components/VvDropdown/VvDropdownItem.vue.d.ts +9 -0
  51. package/dist/components/VvDropdown/VvDropdownOption.vue.d.ts +52 -0
  52. package/dist/components/VvDropdown/index.d.ts +70 -31
  53. package/dist/components/VvDropdownAction/VvDropdownAction.es.js +251 -0
  54. package/dist/components/VvDropdownAction/VvDropdownAction.umd.js +1 -0
  55. package/dist/components/VvDropdownItem/VvDropdownItem.es.js +38 -0
  56. package/dist/components/VvDropdownItem/VvDropdownItem.umd.js +1 -0
  57. package/dist/components/VvDropdownOption/VvDropdownOption.es.js +176 -0
  58. package/dist/components/VvDropdownOption/VvDropdownOption.umd.js +1 -0
  59. package/dist/components/VvIcon/VvIcon.es.js +113 -34
  60. package/dist/components/VvIcon/VvIcon.umd.js +1 -1
  61. package/dist/components/VvInputText/VvInputText.es.js +721 -342
  62. package/dist/components/VvInputText/VvInputText.umd.js +1 -1
  63. package/dist/components/VvInputText/VvInputText.vue.d.ts +21 -14
  64. package/dist/components/VvInputText/index.d.ts +17 -6
  65. package/dist/components/VvProgress/VvProgress.es.js +113 -19
  66. package/dist/components/VvProgress/VvProgress.umd.js +1 -1
  67. package/dist/components/VvRadio/VvRadio.es.js +345 -120
  68. package/dist/components/VvRadio/VvRadio.umd.js +1 -1
  69. package/dist/components/VvRadio/VvRadio.vue.d.ts +6 -4
  70. package/dist/components/VvRadio/index.d.ts +6 -4
  71. package/dist/components/VvRadioGroup/VvRadioGroup.es.js +434 -162
  72. package/dist/components/VvRadioGroup/VvRadioGroup.umd.js +1 -1
  73. package/dist/components/VvRadioGroup/VvRadioGroup.vue.d.ts +14 -3
  74. package/dist/components/VvRadioGroup/index.d.ts +6 -1
  75. package/dist/components/VvSelect/VvSelect.es.js +542 -222
  76. package/dist/components/VvSelect/VvSelect.umd.js +1 -1
  77. package/dist/components/VvSelect/VvSelect.vue.d.ts +44 -21
  78. package/dist/components/VvSelect/index.d.ts +13 -9
  79. package/dist/components/VvTextarea/VvTextarea.es.js +579 -236
  80. package/dist/components/VvTextarea/VvTextarea.umd.js +1 -1
  81. package/dist/components/VvTextarea/VvTextarea.vue.d.ts +20 -13
  82. package/dist/components/VvTextarea/index.d.ts +9 -6
  83. package/dist/components/VvTooltip/VvTooltip.es.js +104 -14
  84. package/dist/components/VvTooltip/VvTooltip.umd.js +1 -1
  85. package/dist/components/VvTooltip/VvTooltip.vue.d.ts +11 -5
  86. package/dist/components/VvTooltip/index.d.ts +7 -9
  87. package/dist/components/index.es.js +2800 -1423
  88. package/dist/components/index.umd.js +1 -1
  89. package/dist/composables/dropdown/useInjectDropdown.d.ts +31 -0
  90. package/dist/composables/dropdown/useProvideDropdown.d.ts +36 -0
  91. package/dist/composables/group/useInjectedGroupState.d.ts +4 -4
  92. package/dist/composables/group/useProvideGroupState.d.ts +2 -2
  93. package/dist/composables/useComponentIcon.d.ts +10 -0
  94. package/dist/composables/useModifiers.d.ts +1 -9
  95. package/dist/composables/useOptions.d.ts +2 -1
  96. package/dist/composables/useUniqueId.d.ts +2 -0
  97. package/dist/composables/useVolver.d.ts +2 -0
  98. package/dist/constants.d.ts +59 -4
  99. package/dist/directives/index.d.ts +4 -0
  100. package/dist/directives/index.es.js +128 -0
  101. package/dist/directives/index.umd.js +1 -0
  102. package/dist/directives/v-tooltip.d.ts +3 -0
  103. package/dist/directives/v-tooltip.es.js +126 -0
  104. package/dist/directives/v-tooltip.umd.js +1 -0
  105. package/dist/icons.d.ts +9 -0
  106. package/dist/icons.es.js +30 -21
  107. package/dist/icons.umd.js +1 -1
  108. package/dist/index.d.ts +1 -1
  109. package/dist/index.es.js +2866 -1455
  110. package/dist/index.umd.js +1 -1
  111. package/dist/props/index.d.ts +327 -33
  112. package/dist/resolvers/unplugin.d.ts +8 -8
  113. package/dist/resolvers/unplugin.es.js +54 -33
  114. package/dist/resolvers/unplugin.umd.js +1 -1
  115. package/dist/stories/CheckboxGroup/CheckboxGroup.settings.d.ts +14 -0
  116. package/dist/stories/Combobox/Combobox.settings.d.ts +270 -3
  117. package/dist/stories/Dropdown/Dropdown.settings.d.ts +139 -28
  118. package/dist/stories/Dropdown/Dropdown.test.d.ts +1 -1
  119. package/dist/stories/InputText/InputText.settings.d.ts +24 -24
  120. package/dist/stories/RadioGroup/RadioGroup.settings.d.ts +14 -0
  121. package/dist/stories/Select/Select.settings.d.ts +15 -1
  122. package/dist/stories/Textarea/Textarea.settings.d.ts +24 -24
  123. package/dist/stories/Tooltip/Tooltip.settings.d.ts +1 -1
  124. package/dist/stories/argTypes.d.ts +164 -3
  125. package/package.json +83 -48
  126. package/src/Volver.ts +152 -33
  127. package/src/assets/icons/detailed/add-circle.svg +12 -1
  128. package/src/assets/icons/detailed/add.svg +8 -1
  129. package/src/assets/icons/detailed/align-center.svg +12 -1
  130. package/src/assets/icons/detailed/align-justify.svg +12 -1
  131. package/src/assets/icons/detailed/align-left.svg +12 -1
  132. package/src/assets/icons/detailed/align-right.svg +12 -1
  133. package/src/assets/icons/detailed/analysis-2.svg +20 -1
  134. package/src/assets/icons/detailed/analysis-3.svg +8 -1
  135. package/src/assets/icons/detailed/analysis.svg +16 -1
  136. package/src/assets/icons/detailed/apple.svg +16 -1
  137. package/src/assets/icons/detailed/arrow-down.svg +8 -1
  138. package/src/assets/icons/detailed/arrow-left.svg +8 -1
  139. package/src/assets/icons/detailed/arrow-right.svg +8 -1
  140. package/src/assets/icons/detailed/arrow-up.svg +8 -1
  141. package/src/assets/icons/detailed/attachment.svg +8 -1
  142. package/src/assets/icons/detailed/back-to-front.svg +17 -1
  143. package/src/assets/icons/detailed/bell-active.svg +14 -1
  144. package/src/assets/icons/detailed/bell.svg +14 -1
  145. package/src/assets/icons/detailed/bold.svg +8 -1
  146. package/src/assets/icons/detailed/bookmark-active.svg +12 -1
  147. package/src/assets/icons/detailed/bookmark.svg +12 -1
  148. package/src/assets/icons/detailed/building.svg +26 -1
  149. package/src/assets/icons/detailed/bullet-list.svg +22 -1
  150. package/src/assets/icons/detailed/calendar.svg +26 -1
  151. package/src/assets/icons/detailed/camera-off.svg +12 -1
  152. package/src/assets/icons/detailed/camera-on.svg +17 -1
  153. package/src/assets/icons/detailed/catalog.svg +15 -1
  154. package/src/assets/icons/detailed/certificate.svg +10 -1
  155. package/src/assets/icons/detailed/chat.svg +6 -1
  156. package/src/assets/icons/detailed/check-badge.svg +9 -1
  157. package/src/assets/icons/detailed/check-circle.svg +10 -1
  158. package/src/assets/icons/detailed/check.svg +6 -1
  159. package/src/assets/icons/detailed/checkbox.svg +8 -1
  160. package/src/assets/icons/detailed/chevron-down-circle.svg +10 -1
  161. package/src/assets/icons/detailed/chevron-down.svg +6 -1
  162. package/src/assets/icons/detailed/chevron-left-circle.svg +10 -1
  163. package/src/assets/icons/detailed/chevron-left.svg +6 -1
  164. package/src/assets/icons/detailed/chevron-right-circle.svg +7 -1
  165. package/src/assets/icons/detailed/chevron-up-circle.svg +10 -1
  166. package/src/assets/icons/detailed/chevron-up.svg +6 -1
  167. package/src/assets/icons/detailed/circle.svg +8 -0
  168. package/src/assets/icons/detailed/classroom.svg +38 -1
  169. package/src/assets/icons/detailed/clear-field.svg +14 -1
  170. package/src/assets/icons/detailed/clear-style.svg +9 -1
  171. package/src/assets/icons/detailed/close-circle.svg +14 -1
  172. package/src/assets/icons/detailed/close-loader.svg +6 -1
  173. package/src/assets/icons/detailed/close.svg +8 -1
  174. package/src/assets/icons/detailed/coffee.svg +21 -1
  175. package/src/assets/icons/detailed/color.svg +20 -1
  176. package/src/assets/icons/detailed/contact-us.svg +27 -1
  177. package/src/assets/icons/detailed/copy.svg +10 -1
  178. package/src/assets/icons/detailed/courses.svg +22 -1
  179. package/src/assets/icons/detailed/dashboard.svg +20 -1
  180. package/src/assets/icons/detailed/download.svg +10 -1
  181. package/src/assets/icons/detailed/drag.svg +10 -1
  182. package/src/assets/icons/detailed/duplicate.svg +23 -1
  183. package/src/assets/icons/detailed/edit.svg +16 -1
  184. package/src/assets/icons/detailed/elearning.svg +13 -1
  185. package/src/assets/icons/detailed/email.svg +11 -1
  186. package/src/assets/icons/detailed/error-2.svg +8 -1
  187. package/src/assets/icons/detailed/error.svg +12 -1
  188. package/src/assets/icons/detailed/exercise.svg +26 -1
  189. package/src/assets/icons/detailed/external-link.svg +11 -1
  190. package/src/assets/icons/detailed/extract.svg +20 -1
  191. package/src/assets/icons/detailed/eye-off.svg +15 -1
  192. package/src/assets/icons/detailed/eye-on.svg +8 -1
  193. package/src/assets/icons/detailed/fail.svg +11 -1
  194. package/src/assets/icons/detailed/fast-back.svg +20 -1
  195. package/src/assets/icons/detailed/fast-forward.svg +20 -1
  196. package/src/assets/icons/detailed/file-add.svg +19 -1
  197. package/src/assets/icons/detailed/file-duplicate.svg +16 -1
  198. package/src/assets/icons/detailed/file-remove.svg +17 -1
  199. package/src/assets/icons/detailed/file-required.svg +23 -1
  200. package/src/assets/icons/detailed/file.svg +13 -1
  201. package/src/assets/icons/detailed/filter-2.svg +22 -1
  202. package/src/assets/icons/detailed/filter-active.svg +12 -1
  203. package/src/assets/icons/detailed/filter.svg +12 -1
  204. package/src/assets/icons/detailed/flag.svg +11 -1
  205. package/src/assets/icons/detailed/folder.svg +14 -1
  206. package/src/assets/icons/detailed/full-width.svg +11 -1
  207. package/src/assets/icons/detailed/go-to-back.svg +19 -1
  208. package/src/assets/icons/detailed/grid.svg +20 -1
  209. package/src/assets/icons/detailed/group-add.svg +24 -1
  210. package/src/assets/icons/detailed/group.svg +16 -1
  211. package/src/assets/icons/detailed/heart-active.svg +12 -1
  212. package/src/assets/icons/detailed/heart.svg +12 -1
  213. package/src/assets/icons/detailed/highlighter.svg +10 -1
  214. package/src/assets/icons/detailed/home.svg +12 -1
  215. package/src/assets/icons/detailed/hourglass.svg +12 -1
  216. package/src/assets/icons/detailed/image.svg +15 -1
  217. package/src/assets/icons/detailed/info-badge.svg +9 -1
  218. package/src/assets/icons/detailed/information.svg +12 -1
  219. package/src/assets/icons/detailed/italic.svg +10 -1
  220. package/src/assets/icons/detailed/key.svg +5 -1
  221. package/src/assets/icons/detailed/language.svg +14 -1
  222. package/src/assets/icons/detailed/learning-path.svg +7 -1
  223. package/src/assets/icons/detailed/light-off.svg +10 -1
  224. package/src/assets/icons/detailed/light-on.svg +18 -1
  225. package/src/assets/icons/detailed/link.svg +12 -1
  226. package/src/assets/icons/detailed/lock.svg +13 -1
  227. package/src/assets/icons/detailed/login.svg +11 -1
  228. package/src/assets/icons/detailed/logout.svg +11 -1
  229. package/src/assets/icons/detailed/maximaze.svg +12 -1
  230. package/src/assets/icons/detailed/menu.svg +9 -1
  231. package/src/assets/icons/detailed/merge.svg +20 -1
  232. package/src/assets/icons/detailed/minimize.svg +14 -1
  233. package/src/assets/icons/detailed/mixed-class.svg +40 -1
  234. package/src/assets/icons/detailed/more-horizontal.svg +7 -1
  235. package/src/assets/icons/detailed/more-vertical.svg +7 -1
  236. package/src/assets/icons/detailed/news.svg +12 -1
  237. package/src/assets/icons/detailed/no-prerequisites.svg +13 -1
  238. package/src/assets/icons/detailed/notes.svg +14 -1
  239. package/src/assets/icons/detailed/number-code.svg +34 -1
  240. package/src/assets/icons/detailed/numbered-list.svg +18 -1
  241. package/src/assets/icons/detailed/on-site.svg +22 -1
  242. package/src/assets/icons/detailed/order-down.svg +12 -1
  243. package/src/assets/icons/detailed/order-up.svg +12 -1
  244. package/src/assets/icons/detailed/paste.svg +14 -1
  245. package/src/assets/icons/detailed/pausa.svg +8 -1
  246. package/src/assets/icons/detailed/pdf.svg +12 -1
  247. package/src/assets/icons/detailed/phone.svg +10 -1
  248. package/src/assets/icons/detailed/pin-map.svg +12 -1
  249. package/src/assets/icons/detailed/pin.svg +15 -1
  250. package/src/assets/icons/detailed/pizza.svg +17 -1
  251. package/src/assets/icons/detailed/play.svg +11 -1
  252. package/src/assets/icons/detailed/plug-in.svg +10 -1
  253. package/src/assets/icons/detailed/pointer.svg +12 -1
  254. package/src/assets/icons/detailed/printer.svg +26 -1
  255. package/src/assets/icons/detailed/profile-add.svg +20 -1
  256. package/src/assets/icons/detailed/profile.svg +10 -1
  257. package/src/assets/icons/detailed/push-pin-off.svg +11 -1
  258. package/src/assets/icons/detailed/push-pin-on.svg +9 -1
  259. package/src/assets/icons/detailed/qrcode.svg +28 -1
  260. package/src/assets/icons/detailed/question-badge.svg +10 -1
  261. package/src/assets/icons/detailed/radio.svg +8 -1
  262. package/src/assets/icons/detailed/redo.svg +9 -1
  263. package/src/assets/icons/detailed/relations.svg +32 -1
  264. package/src/assets/icons/detailed/reload.svg +13 -1
  265. package/src/assets/icons/detailed/remove-circle.svg +10 -1
  266. package/src/assets/icons/detailed/remove.svg +5 -1
  267. package/src/assets/icons/detailed/reorder.svg +12 -1
  268. package/src/assets/icons/detailed/repeat.svg +12 -1
  269. package/src/assets/icons/detailed/repository.svg +18 -1
  270. package/src/assets/icons/detailed/request-form.svg +18 -1
  271. package/src/assets/icons/detailed/resize-100%.svg +15 -1
  272. package/src/assets/icons/detailed/resize-height.svg +12 -1
  273. package/src/assets/icons/detailed/resize-width.svg +12 -1
  274. package/src/assets/icons/detailed/search.svg +12 -1
  275. package/src/assets/icons/detailed/sequential-prerequisites.svg +20 -1
  276. package/src/assets/icons/detailed/settings.svg +14 -1
  277. package/src/assets/icons/detailed/share.svg +20 -1
  278. package/src/assets/icons/detailed/sketch.svg +12 -1
  279. package/src/assets/icons/detailed/skills.svg +20 -1
  280. package/src/assets/icons/detailed/skip-back.svg +12 -1
  281. package/src/assets/icons/detailed/skip-forward.svg +13 -1
  282. package/src/assets/icons/detailed/sms.svg +18 -1
  283. package/src/assets/icons/detailed/sso-access.svg +18 -1
  284. package/src/assets/icons/detailed/star-active.svg +6 -1
  285. package/src/assets/icons/detailed/star.svg +6 -1
  286. package/src/assets/icons/detailed/success.svg +10 -1
  287. package/src/assets/icons/detailed/sun.svg +24 -1
  288. package/src/assets/icons/detailed/sunrise.svg +18 -1
  289. package/src/assets/icons/detailed/support.svg +18 -1
  290. package/src/assets/icons/detailed/survey.svg +24 -1
  291. package/src/assets/icons/detailed/table.svg +11 -1
  292. package/src/assets/icons/detailed/tematic-channels.svg +12 -1
  293. package/src/assets/icons/detailed/test.svg +14 -1
  294. package/src/assets/icons/detailed/text-body.svg +8 -1
  295. package/src/assets/icons/detailed/text-edit.svg +11 -1
  296. package/src/assets/icons/detailed/text-style.svg +10 -1
  297. package/src/assets/icons/detailed/time.svg +10 -1
  298. package/src/assets/icons/detailed/toilet-piper.svg +15 -1
  299. package/src/assets/icons/detailed/training-points.svg +16 -1
  300. package/src/assets/icons/detailed/trash.svg +19 -1
  301. package/src/assets/icons/detailed/underline.svg +8 -1
  302. package/src/assets/icons/detailed/undo.svg +9 -1
  303. package/src/assets/icons/detailed/unlock.svg +13 -1
  304. package/src/assets/icons/detailed/upload.svg +10 -1
  305. package/src/assets/icons/detailed/user-add.svg +16 -1
  306. package/src/assets/icons/detailed/user-badge.svg +11 -1
  307. package/src/assets/icons/detailed/user.svg +8 -1
  308. package/src/assets/icons/detailed/video-off.svg +17 -1
  309. package/src/assets/icons/detailed/video-on.svg +16 -1
  310. package/src/assets/icons/detailed/video-rec.svg +19 -1
  311. package/src/assets/icons/detailed/view-card.svg +12 -1
  312. package/src/assets/icons/detailed/view-list.svg +20 -1
  313. package/src/assets/icons/detailed/view.svg +7 -1
  314. package/src/assets/icons/detailed/voice-off.svg +14 -1
  315. package/src/assets/icons/detailed/voice-on.svg +16 -1
  316. package/src/assets/icons/detailed/volume-down.svg +14 -1
  317. package/src/assets/icons/detailed/volume-off.svg +19 -1
  318. package/src/assets/icons/detailed/volume-up.svg +16 -1
  319. package/src/assets/icons/detailed/warning.svg +16 -1
  320. package/src/assets/icons/detailed/webinar.svg +57 -1
  321. package/src/assets/icons/detailed/whiteboard.svg +16 -1
  322. package/src/assets/icons/detailed/wine.svg +22 -1
  323. package/src/assets/icons/detailed/zip.svg +17 -1
  324. package/src/assets/icons/detailed/zoom-in.svg +18 -1
  325. package/src/assets/icons/detailed/zoom-out.svg +16 -1
  326. package/src/assets/icons/detailed.json +1 -1
  327. package/src/assets/icons/normal/add-circle.svg +12 -1
  328. package/src/assets/icons/normal/add.svg +4 -1
  329. package/src/assets/icons/normal/align-center.svg +11 -1
  330. package/src/assets/icons/normal/align-justify.svg +11 -1
  331. package/src/assets/icons/normal/align-left.svg +11 -1
  332. package/src/assets/icons/normal/align-right.svg +11 -1
  333. package/src/assets/icons/normal/analysis-2.svg +18 -1
  334. package/src/assets/icons/normal/analysis-3.svg +8 -1
  335. package/src/assets/icons/normal/analysis.svg +14 -1
  336. package/src/assets/icons/normal/apple.svg +16 -1
  337. package/src/assets/icons/normal/arrow-down.svg +8 -1
  338. package/src/assets/icons/normal/arrow-left.svg +8 -1
  339. package/src/assets/icons/normal/arrow-right.svg +8 -1
  340. package/src/assets/icons/normal/arrow-up.svg +8 -1
  341. package/src/assets/icons/normal/attachment.svg +6 -1
  342. package/src/assets/icons/normal/back-to-front.svg +15 -1
  343. package/src/assets/icons/normal/bell-active.svg +14 -1
  344. package/src/assets/icons/normal/bell.svg +14 -1
  345. package/src/assets/icons/normal/bold.svg +8 -1
  346. package/src/assets/icons/normal/bookmark active.svg +12 -1
  347. package/src/assets/icons/normal/bookmark.svg +10 -1
  348. package/src/assets/icons/normal/building.svg +21 -1
  349. package/src/assets/icons/normal/bulleted-list.svg +23 -1
  350. package/src/assets/icons/normal/calendar.svg +20 -1
  351. package/src/assets/icons/normal/camera-off.svg +17 -1
  352. package/src/assets/icons/normal/camera-on.svg +16 -1
  353. package/src/assets/icons/normal/catalog.svg +13 -1
  354. package/src/assets/icons/normal/certificate.svg +12 -1
  355. package/src/assets/icons/normal/chat.svg +6 -1
  356. package/src/assets/icons/normal/check-badge.svg +9 -1
  357. package/src/assets/icons/normal/check-circle.svg +10 -1
  358. package/src/assets/icons/normal/check.svg +4 -1
  359. package/src/assets/icons/normal/checkbox.svg +8 -1
  360. package/src/assets/icons/normal/chevron-down-circle.svg +10 -1
  361. package/src/assets/icons/normal/chevron-down.svg +6 -1
  362. package/src/assets/icons/normal/chevron-left-circle.svg +10 -1
  363. package/src/assets/icons/normal/chevron-left.svg +6 -1
  364. package/src/assets/icons/normal/chevron-right-circle.svg +10 -1
  365. package/src/assets/icons/normal/chevron-right.svg +7 -1
  366. package/src/assets/icons/normal/chevron-up-circle.svg +10 -1
  367. package/src/assets/icons/normal/chevron-up.svg +6 -1
  368. package/src/assets/icons/normal/circle.svg +8 -0
  369. package/src/assets/icons/normal/classroom.svg +36 -1
  370. package/src/assets/icons/normal/clear-field.svg +14 -1
  371. package/src/assets/icons/normal/clear-style.svg +18 -1
  372. package/src/assets/icons/normal/close-circle.svg +14 -1
  373. package/src/assets/icons/normal/close-loader.svg +6 -1
  374. package/src/assets/icons/normal/close.svg +8 -1
  375. package/src/assets/icons/normal/coffee.svg +26 -1
  376. package/src/assets/icons/normal/color.svg +18 -1
  377. package/src/assets/icons/normal/contact-us.svg +29 -1
  378. package/src/assets/icons/normal/copy.svg +10 -1
  379. package/src/assets/icons/normal/courses.svg +22 -1
  380. package/src/assets/icons/normal/dashboard.svg +18 -1
  381. package/src/assets/icons/normal/download.svg +10 -1
  382. package/src/assets/icons/normal/drag.svg +5 -1
  383. package/src/assets/icons/normal/dulicate.svg +22 -1
  384. package/src/assets/icons/normal/edit.svg +16 -1
  385. package/src/assets/icons/normal/elearning.svg +16 -1
  386. package/src/assets/icons/normal/email.svg +11 -1
  387. package/src/assets/icons/normal/error-2.svg +8 -1
  388. package/src/assets/icons/normal/error.svg +12 -1
  389. package/src/assets/icons/normal/exercise.svg +26 -1
  390. package/src/assets/icons/normal/external-link.svg +11 -1
  391. package/src/assets/icons/normal/extract.svg +14 -1
  392. package/src/assets/icons/normal/eye-off.svg +14 -1
  393. package/src/assets/icons/normal/eye-on.svg +16 -1
  394. package/src/assets/icons/normal/fail.svg +11 -1
  395. package/src/assets/icons/normal/fast-back.svg +19 -1
  396. package/src/assets/icons/normal/fast-forward.svg +17 -1
  397. package/src/assets/icons/normal/file-add.svg +16 -1
  398. package/src/assets/icons/normal/file-duplicate.svg +22 -1
  399. package/src/assets/icons/normal/file-remove.svg +14 -1
  400. package/src/assets/icons/normal/file-required.svg +24 -1
  401. package/src/assets/icons/normal/file.svg +13 -1
  402. package/src/assets/icons/normal/filter-2.svg +20 -1
  403. package/src/assets/icons/normal/filter-active.svg +12 -1
  404. package/src/assets/icons/normal/filter.svg +12 -1
  405. package/src/assets/icons/normal/flag.svg +10 -1
  406. package/src/assets/icons/normal/folder.svg +12 -1
  407. package/src/assets/icons/normal/full-width.svg +9 -1
  408. package/src/assets/icons/normal/go-to-back.svg +19 -1
  409. package/src/assets/icons/normal/grid.svg +20 -1
  410. package/src/assets/icons/normal/group-add.svg +18 -1
  411. package/src/assets/icons/normal/group.svg +14 -1
  412. package/src/assets/icons/normal/heart-active.svg +10 -1
  413. package/src/assets/icons/normal/heart.svg +10 -1
  414. package/src/assets/icons/normal/highlighter.svg +11 -1
  415. package/src/assets/icons/normal/home.svg +12 -1
  416. package/src/assets/icons/normal/hourglass.svg +8 -1
  417. package/src/assets/icons/normal/image.svg +15 -1
  418. package/src/assets/icons/normal/info-badge.svg +9 -1
  419. package/src/assets/icons/normal/information.svg +12 -1
  420. package/src/assets/icons/normal/italic.svg +10 -1
  421. package/src/assets/icons/normal/key.svg +8 -1
  422. package/src/assets/icons/normal/language.svg +14 -1
  423. package/src/assets/icons/normal/learning-path.svg +7 -1
  424. package/src/assets/icons/normal/light-off.svg +10 -1
  425. package/src/assets/icons/normal/light-on.svg +17 -1
  426. package/src/assets/icons/normal/link.svg +12 -1
  427. package/src/assets/icons/normal/lock.svg +12 -1
  428. package/src/assets/icons/normal/login.svg +10 -1
  429. package/src/assets/icons/normal/logout.svg +10 -1
  430. package/src/assets/icons/normal/maximize.svg +10 -1
  431. package/src/assets/icons/normal/menu.svg +8 -1
  432. package/src/assets/icons/normal/merge.svg +20 -1
  433. package/src/assets/icons/normal/minimize.svg +12 -1
  434. package/src/assets/icons/normal/mixed-class.svg +36 -1
  435. package/src/assets/icons/normal/more-horizontal.svg +7 -1
  436. package/src/assets/icons/normal/more-vertical.svg +7 -1
  437. package/src/assets/icons/normal/news.svg +9 -1
  438. package/src/assets/icons/normal/no-prerequisites.svg +12 -1
  439. package/src/assets/icons/normal/notes.svg +15 -1
  440. package/src/assets/icons/normal/number-code.svg +34 -1
  441. package/src/assets/icons/normal/numbered-list.svg +19 -1
  442. package/src/assets/icons/normal/on-site.svg +18 -1
  443. package/src/assets/icons/normal/order-down.svg +12 -1
  444. package/src/assets/icons/normal/order-up.svg +11 -1
  445. package/src/assets/icons/normal/paste.svg +14 -1
  446. package/src/assets/icons/normal/pausa.svg +7 -1
  447. package/src/assets/icons/normal/pdf.svg +12 -1
  448. package/src/assets/icons/normal/phone.svg +10 -1
  449. package/src/assets/icons/normal/pin-map.svg +10 -1
  450. package/src/assets/icons/normal/pin.svg +12 -1
  451. package/src/assets/icons/normal/pizza.svg +17 -1
  452. package/src/assets/icons/normal/play.svg +9 -1
  453. package/src/assets/icons/normal/plug-in.svg +10 -1
  454. package/src/assets/icons/normal/pointer.svg +12 -1
  455. package/src/assets/icons/normal/printer.svg +28 -1
  456. package/src/assets/icons/normal/profile-add.svg +28 -1
  457. package/src/assets/icons/normal/profile.svg +15 -1
  458. package/src/assets/icons/normal/push pin on.svg +9 -1
  459. package/src/assets/icons/normal/push-pin-off.svg +23 -1
  460. package/src/assets/icons/normal/qrcode.svg +26 -1
  461. package/src/assets/icons/normal/question-badge.svg +10 -1
  462. package/src/assets/icons/normal/radio.svg +8 -1
  463. package/src/assets/icons/normal/redo.svg +9 -1
  464. package/src/assets/icons/normal/relations.svg +28 -1
  465. package/src/assets/icons/normal/reload.svg +12 -1
  466. package/src/assets/icons/normal/remove-circle.svg +10 -1
  467. package/src/assets/icons/normal/remove.svg +4 -1
  468. package/src/assets/icons/normal/reorder.svg +12 -1
  469. package/src/assets/icons/normal/repeat.svg +12 -1
  470. package/src/assets/icons/normal/repository.svg +18 -1
  471. package/src/assets/icons/normal/request-form.svg +18 -1
  472. package/src/assets/icons/normal/resize-100%.svg +17 -1
  473. package/src/assets/icons/normal/resize-height.svg +12 -1
  474. package/src/assets/icons/normal/resize-width.svg +12 -1
  475. package/src/assets/icons/normal/search.svg +10 -1
  476. package/src/assets/icons/normal/sequential-prerequisites.svg +20 -1
  477. package/src/assets/icons/normal/settings.svg +14 -1
  478. package/src/assets/icons/normal/share.svg +20 -1
  479. package/src/assets/icons/normal/sketch.svg +11 -1
  480. package/src/assets/icons/normal/skills.svg +16 -1
  481. package/src/assets/icons/normal/skip-back.svg +12 -1
  482. package/src/assets/icons/normal/skip-forward.svg +13 -1
  483. package/src/assets/icons/normal/sms.svg +20 -1
  484. package/src/assets/icons/normal/sso-access.svg +20 -1
  485. package/src/assets/icons/normal/star-active.svg +4 -1
  486. package/src/assets/icons/normal/star.svg +4 -1
  487. package/src/assets/icons/normal/success.svg +10 -1
  488. package/src/assets/icons/normal/sun.svg +24 -1
  489. package/src/assets/icons/normal/sunrise.svg +18 -1
  490. package/src/assets/icons/normal/support.svg +18 -1
  491. package/src/assets/icons/normal/survey.svg +24 -1
  492. package/src/assets/icons/normal/table.svg +11 -1
  493. package/src/assets/icons/normal/tematic-channels.svg +10 -1
  494. package/src/assets/icons/normal/test.svg +15 -1
  495. package/src/assets/icons/normal/text-body.svg +8 -1
  496. package/src/assets/icons/normal/text-edit.svg +11 -1
  497. package/src/assets/icons/normal/text-style.svg +10 -1
  498. package/src/assets/icons/normal/time.svg +10 -1
  499. package/src/assets/icons/normal/toilet-paper.svg +15 -1
  500. package/src/assets/icons/normal/training-points.svg +16 -1
  501. package/src/assets/icons/normal/trash.svg +19 -1
  502. package/src/assets/icons/normal/underline.svg +8 -1
  503. package/src/assets/icons/normal/undo.svg +9 -1
  504. package/src/assets/icons/normal/unlock.svg +13 -1
  505. package/src/assets/icons/normal/upload.svg +10 -1
  506. package/src/assets/icons/normal/user-add.svg +14 -1
  507. package/src/assets/icons/normal/user-badge.svg +11 -1
  508. package/src/assets/icons/normal/user.svg +5 -1
  509. package/src/assets/icons/normal/video-off.svg +11 -1
  510. package/src/assets/icons/normal/video-on.svg +20 -1
  511. package/src/assets/icons/normal/video-rec.svg +23 -1
  512. package/src/assets/icons/normal/view-card.svg +10 -1
  513. package/src/assets/icons/normal/view-list.svg +18 -1
  514. package/src/assets/icons/normal/view.svg +8 -1
  515. package/src/assets/icons/normal/voice-off.svg +18 -1
  516. package/src/assets/icons/normal/voice-on.svg +15 -1
  517. package/src/assets/icons/normal/volume-down.svg +14 -1
  518. package/src/assets/icons/normal/volume-off.svg +18 -1
  519. package/src/assets/icons/normal/volume-up.svg +16 -1
  520. package/src/assets/icons/normal/warning.svg +16 -1
  521. package/src/assets/icons/normal/webinar.svg +36 -1
  522. package/src/assets/icons/normal/whiteboard.svg +17 -1
  523. package/src/assets/icons/normal/wine.svg +22 -1
  524. package/src/assets/icons/normal/zip.svg +19 -1
  525. package/src/assets/icons/normal/zoom-in.svg +16 -1
  526. package/src/assets/icons/normal/zoom-out.svg +14 -1
  527. package/src/assets/icons/normal.json +1 -1
  528. package/src/assets/icons/simple/add-circle.svg +12 -1
  529. package/src/assets/icons/simple/add.svg +8 -1
  530. package/src/assets/icons/simple/align-center.svg +12 -1
  531. package/src/assets/icons/simple/align-justify.svg +12 -1
  532. package/src/assets/icons/simple/align-left.svg +12 -1
  533. package/src/assets/icons/simple/align-right.svg +12 -1
  534. package/src/assets/icons/simple/analysis-2.svg +21 -1
  535. package/src/assets/icons/simple/analysis-3.svg +8 -1
  536. package/src/assets/icons/simple/analysis.svg +16 -1
  537. package/src/assets/icons/simple/apple.svg +18 -1
  538. package/src/assets/icons/simple/arrow-down.svg +8 -1
  539. package/src/assets/icons/simple/arrow-left.svg +8 -1
  540. package/src/assets/icons/simple/arrow-right.svg +8 -1
  541. package/src/assets/icons/simple/arrow-up.svg +8 -1
  542. package/src/assets/icons/simple/attachment.svg +10 -1
  543. package/src/assets/icons/simple/bck-to-front.svg +19 -1
  544. package/src/assets/icons/simple/bell-active.svg +14 -1
  545. package/src/assets/icons/simple/bell.svg +14 -1
  546. package/src/assets/icons/simple/bold.svg +8 -1
  547. package/src/assets/icons/simple/bookmark-active.svg +12 -1
  548. package/src/assets/icons/simple/bookmark.svg +12 -1
  549. package/src/assets/icons/simple/building.svg +25 -1
  550. package/src/assets/icons/simple/bulleted-list.svg +22 -1
  551. package/src/assets/icons/simple/calendar.svg +22 -1
  552. package/src/assets/icons/simple/camera-off.svg +12 -1
  553. package/src/assets/icons/simple/camera-on.svg +16 -1
  554. package/src/assets/icons/simple/catalog.svg +14 -1
  555. package/src/assets/icons/simple/certificate.svg +15 -1
  556. package/src/assets/icons/simple/chat.svg +9 -1
  557. package/src/assets/icons/simple/check-badge.svg +9 -1
  558. package/src/assets/icons/simple/check-circle.svg +10 -1
  559. package/src/assets/icons/simple/check.svg +6 -1
  560. package/src/assets/icons/simple/checkbox.svg +6 -1
  561. package/src/assets/icons/simple/chevron-down-circle.svg +10 -1
  562. package/src/assets/icons/simple/chevron-down.svg +6 -1
  563. package/src/assets/icons/simple/chevron-left-circle.svg +10 -1
  564. package/src/assets/icons/simple/chevron-left.svg +6 -1
  565. package/src/assets/icons/simple/chevron-right-circle.svg +10 -1
  566. package/src/assets/icons/simple/chevron-right.svg +7 -1
  567. package/src/assets/icons/simple/chevron-up-circle.svg +10 -1
  568. package/src/assets/icons/simple/chevron-up.svg +6 -1
  569. package/src/assets/icons/simple/circle.svg +8 -0
  570. package/src/assets/icons/simple/classroom.svg +38 -1
  571. package/src/assets/icons/simple/clear-field.svg +11 -1
  572. package/src/assets/icons/simple/clear-style.svg +15 -1
  573. package/src/assets/icons/simple/close-circle.svg +14 -1
  574. package/src/assets/icons/simple/close-loader.svg +6 -1
  575. package/src/assets/icons/simple/close.svg +10 -1
  576. package/src/assets/icons/simple/coffee.svg +28 -1
  577. package/src/assets/icons/simple/color.svg +20 -1
  578. package/src/assets/icons/simple/contact-us.svg +26 -1
  579. package/src/assets/icons/simple/copy.svg +10 -1
  580. package/src/assets/icons/simple/courses.svg +21 -1
  581. package/src/assets/icons/simple/dashboard.svg +20 -1
  582. package/src/assets/icons/simple/download.svg +10 -1
  583. package/src/assets/icons/simple/drag.svg +10 -1
  584. package/src/assets/icons/simple/duplicate.svg +24 -1
  585. package/src/assets/icons/simple/edit.svg +17 -1
  586. package/src/assets/icons/simple/elearning.svg +17 -1
  587. package/src/assets/icons/simple/email.svg +11 -1
  588. package/src/assets/icons/simple/error-2.svg +8 -1
  589. package/src/assets/icons/simple/error.svg +12 -1
  590. package/src/assets/icons/simple/exercise.svg +30 -1
  591. package/src/assets/icons/simple/external-link.svg +13 -1
  592. package/src/assets/icons/simple/extract.svg +17 -1
  593. package/src/assets/icons/simple/eye-off.svg +13 -1
  594. package/src/assets/icons/simple/eye-on.svg +11 -1
  595. package/src/assets/icons/simple/fail.svg +11 -1
  596. package/src/assets/icons/simple/fast-back.svg +20 -1
  597. package/src/assets/icons/simple/fast-forward.svg +19 -1
  598. package/src/assets/icons/simple/file-add.svg +20 -1
  599. package/src/assets/icons/simple/file-duplicate.svg +22 -1
  600. package/src/assets/icons/simple/file-remove.svg +18 -1
  601. package/src/assets/icons/simple/file-required.svg +24 -1
  602. package/src/assets/icons/simple/file.svg +14 -1
  603. package/src/assets/icons/simple/filter-2.svg +24 -1
  604. package/src/assets/icons/simple/filter-active.svg +13 -1
  605. package/src/assets/icons/simple/filter.svg +12 -1
  606. package/src/assets/icons/simple/flag.svg +12 -1
  607. package/src/assets/icons/simple/folder.svg +14 -1
  608. package/src/assets/icons/simple/full-width.svg +11 -1
  609. package/src/assets/icons/simple/go-to-back.svg +18 -1
  610. package/src/assets/icons/simple/grid.svg +20 -1
  611. package/src/assets/icons/simple/group-add.svg +24 -1
  612. package/src/assets/icons/simple/group.svg +18 -1
  613. package/src/assets/icons/simple/heart-active.svg +12 -1
  614. package/src/assets/icons/simple/heart.svg +12 -1
  615. package/src/assets/icons/simple/highlighter.svg +12 -1
  616. package/src/assets/icons/simple/home.svg +13 -1
  617. package/src/assets/icons/simple/hourglass.svg +11 -1
  618. package/src/assets/icons/simple/image.svg +15 -1
  619. package/src/assets/icons/simple/info-badge.svg +9 -1
  620. package/src/assets/icons/simple/information.svg +12 -1
  621. package/src/assets/icons/simple/italic.svg +12 -1
  622. package/src/assets/icons/simple/key.svg +11 -1
  623. package/src/assets/icons/simple/language.svg +12 -1
  624. package/src/assets/icons/simple/learning-path.svg +9 -1
  625. package/src/assets/icons/simple/light-off.svg +7 -1
  626. package/src/assets/icons/simple/light-on.svg +18 -1
  627. package/src/assets/icons/simple/link.svg +14 -1
  628. package/src/assets/icons/simple/lock.svg +13 -1
  629. package/src/assets/icons/simple/login.svg +11 -1
  630. package/src/assets/icons/simple/logout.svg +11 -1
  631. package/src/assets/icons/simple/maximaze.svg +12 -1
  632. package/src/assets/icons/simple/menu.svg +10 -1
  633. package/src/assets/icons/simple/merge.svg +20 -1
  634. package/src/assets/icons/simple/minimaze.svg +12 -1
  635. package/src/assets/icons/simple/mixed-class.svg +40 -1
  636. package/src/assets/icons/simple/more-horizontal.svg +8 -1
  637. package/src/assets/icons/simple/more-vertical.svg +8 -1
  638. package/src/assets/icons/simple/news.svg +12 -1
  639. package/src/assets/icons/simple/no-prerequisites.svg +17 -1
  640. package/src/assets/icons/simple/notes.svg +14 -1
  641. package/src/assets/icons/simple/number-code.svg +29 -1
  642. package/src/assets/icons/simple/numbered-list.svg +18 -1
  643. package/src/assets/icons/simple/on-site.svg +18 -1
  644. package/src/assets/icons/simple/order-down.svg +12 -1
  645. package/src/assets/icons/simple/order-up.svg +12 -1
  646. package/src/assets/icons/simple/paste.svg +14 -1
  647. package/src/assets/icons/simple/pausa.svg +8 -1
  648. package/src/assets/icons/simple/pdf.svg +12 -1
  649. package/src/assets/icons/simple/phone.svg +10 -1
  650. package/src/assets/icons/simple/pin-map.svg +13 -1
  651. package/src/assets/icons/simple/pin.svg +14 -1
  652. package/src/assets/icons/simple/pizza.svg +17 -1
  653. package/src/assets/icons/simple/play.svg +10 -1
  654. package/src/assets/icons/simple/plug-in.svg +10 -1
  655. package/src/assets/icons/simple/pointer.svg +6 -1
  656. package/src/assets/icons/simple/printer.svg +28 -1
  657. package/src/assets/icons/simple/profile-add.svg +28 -1
  658. package/src/assets/icons/simple/profile.svg +13 -1
  659. package/src/assets/icons/simple/push-pin-off.svg +11 -1
  660. package/src/assets/icons/simple/push-pin-on.svg +12 -1
  661. package/src/assets/icons/simple/qrcode.svg +26 -1
  662. package/src/assets/icons/simple/question-badge.svg +10 -1
  663. package/src/assets/icons/simple/radio.svg +8 -1
  664. package/src/assets/icons/simple/redo.svg +9 -1
  665. package/src/assets/icons/simple/relations.svg +28 -1
  666. package/src/assets/icons/simple/reload.svg +12 -1
  667. package/src/assets/icons/simple/remove-circle.svg +10 -1
  668. package/src/assets/icons/simple/remove.svg +6 -1
  669. package/src/assets/icons/simple/repeart.svg +14 -1
  670. package/src/assets/icons/simple/repository.svg +18 -1
  671. package/src/assets/icons/simple/request-form.svg +20 -1
  672. package/src/assets/icons/simple/resize-100%.svg +15 -1
  673. package/src/assets/icons/simple/resize-height.svg +12 -1
  674. package/src/assets/icons/simple/resize-width.svg +14 -1
  675. package/src/assets/icons/simple/search.svg +10 -1
  676. package/src/assets/icons/simple/sequential-prerequisites.svg +22 -1
  677. package/src/assets/icons/simple/settings.svg +17 -1
  678. package/src/assets/icons/simple/share.svg +21 -1
  679. package/src/assets/icons/simple/sketch.svg +13 -1
  680. package/src/assets/icons/simple/skills.svg +17 -1
  681. package/src/assets/icons/simple/skip-back.svg +14 -1
  682. package/src/assets/icons/simple/skip-forward.svg +14 -1
  683. package/src/assets/icons/simple/sms.svg +22 -1
  684. package/src/assets/icons/simple/sso-access.svg +20 -1
  685. package/src/assets/icons/simple/star-active.svg +6 -1
  686. package/src/assets/icons/simple/star.svg +6 -1
  687. package/src/assets/icons/simple/success.svg +12 -1
  688. package/src/assets/icons/simple/sun.svg +22 -1
  689. package/src/assets/icons/simple/sunrise.svg +18 -1
  690. package/src/assets/icons/simple/support.svg +18 -1
  691. package/src/assets/icons/simple/survey.svg +32 -1
  692. package/src/assets/icons/simple/table.svg +11 -1
  693. package/src/assets/icons/simple/tematic-channels.svg +15 -1
  694. package/src/assets/icons/simple/test.svg +23 -1
  695. package/src/assets/icons/simple/text-body.svg +7 -1
  696. package/src/assets/icons/simple/text-edit.svg +11 -1
  697. package/src/assets/icons/simple/text-style.svg +10 -1
  698. package/src/assets/icons/simple/time.svg +10 -1
  699. package/src/assets/icons/simple/toilet-paper.svg +17 -1
  700. package/src/assets/icons/simple/training-points.svg +18 -1
  701. package/src/assets/icons/simple/trash.svg +20 -1
  702. package/src/assets/icons/simple/underline.svg +9 -1
  703. package/src/assets/icons/simple/undo.svg +9 -1
  704. package/src/assets/icons/simple/unlock.svg +15 -1
  705. package/src/assets/icons/simple/upload.svg +10 -1
  706. package/src/assets/icons/simple/user-add.svg +18 -1
  707. package/src/assets/icons/simple/user-badge.svg +12 -1
  708. package/src/assets/icons/simple/user.svg +8 -1
  709. package/src/assets/icons/simple/video-off.svg +17 -1
  710. package/src/assets/icons/simple/video-on.svg +17 -1
  711. package/src/assets/icons/simple/video-rec.svg +20 -1
  712. package/src/assets/icons/simple/view-card.svg +12 -1
  713. package/src/assets/icons/simple/view-list.svg +20 -1
  714. package/src/assets/icons/simple/view.svg +17 -1
  715. package/src/assets/icons/simple/voice-off.svg +16 -1
  716. package/src/assets/icons/simple/voice-on.svg +16 -1
  717. package/src/assets/icons/simple/volume-down.svg +15 -1
  718. package/src/assets/icons/simple/volume-off.svg +16 -1
  719. package/src/assets/icons/simple/volume-up.svg +16 -1
  720. package/src/assets/icons/simple/warning.svg +14 -1
  721. package/src/assets/icons/simple/webinar.svg +19 -1
  722. package/src/assets/icons/simple/whiteboard.svg +16 -1
  723. package/src/assets/icons/simple/wine.svg +24 -1
  724. package/src/assets/icons/simple/zip.svg +22 -1
  725. package/src/assets/icons/simple/zoom-in.svg +18 -1
  726. package/src/assets/icons/simple/zoom-out.svg +17 -1
  727. package/src/assets/icons/simple.json +1 -1
  728. package/src/components/VvAccordion/VvAccordion.vue +16 -9
  729. package/src/components/VvAccordion/index.ts +5 -3
  730. package/src/components/VvAccordionGroup/VvAccordionGroup.vue +16 -11
  731. package/src/components/VvAction/VvAction.vue +144 -0
  732. package/src/components/VvAction/index.ts +5 -0
  733. package/src/components/VvBadge/VvBadge.vue +3 -3
  734. package/src/components/VvBreadcrumb/VvBreadcrumb.vue +5 -5
  735. package/src/components/VvButton/VvButton.vue +53 -100
  736. package/src/components/VvButton/index.ts +21 -94
  737. package/src/components/VvButtonGroup/VvButtonGroup.vue +7 -10
  738. package/src/components/VvCard/VvCard.vue +6 -3
  739. package/src/components/VvCheckbox/VvCheckbox.vue +17 -12
  740. package/src/components/VvCheckbox/index.ts +7 -5
  741. package/src/components/VvCheckboxGroup/VvCheckboxGroup.vue +21 -19
  742. package/src/components/VvCombobox/VvCombobox.vue +330 -101
  743. package/src/components/VvCombobox/index.ts +63 -7
  744. package/src/components/VvDialog/VvDialog.vue +14 -6
  745. package/src/components/VvDialog/index.ts +18 -1
  746. package/src/components/VvDropdown/VvDropdown.vue +344 -95
  747. package/src/components/VvDropdown/VvDropdownAction.vue +44 -0
  748. package/src/components/VvDropdown/VvDropdownItem.vue +32 -0
  749. package/src/components/VvDropdown/VvDropdownOption.vue +65 -0
  750. package/src/components/VvDropdown/index.ts +20 -23
  751. package/src/components/VvIcon/VvIcon.vue +16 -16
  752. package/src/components/VvInputText/VvInputText.vue +45 -34
  753. package/src/components/VvProgress/VvProgress.vue +7 -5
  754. package/src/components/VvRadio/VvRadio.vue +16 -14
  755. package/src/components/VvRadio/index.ts +6 -3
  756. package/src/components/VvRadioGroup/VvRadioGroup.vue +20 -16
  757. package/src/components/VvSelect/VvSelect.vue +69 -56
  758. package/src/components/VvSelect/index.ts +4 -6
  759. package/src/components/VvTextarea/VvTextarea.vue +46 -33
  760. package/src/components/VvTooltip/VvTooltip.vue +16 -10
  761. package/src/components/VvTooltip/index.ts +8 -11
  762. package/src/components/common/HintSlot.ts +5 -4
  763. package/src/composables/dropdown/useInjectDropdown.ts +51 -0
  764. package/src/composables/dropdown/useProvideDropdown.ts +95 -0
  765. package/src/composables/group/useInjectedGroupState.ts +7 -7
  766. package/src/composables/group/useProvideGroupState.ts +3 -3
  767. package/src/composables/useComponentIcon.ts +41 -0
  768. package/src/composables/useModifiers.ts +28 -91
  769. package/src/composables/useOptions.ts +11 -3
  770. package/src/composables/useUniqueId.ts +5 -0
  771. package/src/composables/useVolver.ts +6 -0
  772. package/src/constants.ts +74 -5
  773. package/src/directives/index.ts +5 -0
  774. package/src/directives/v-tooltip.ts +15 -0
  775. package/src/index.ts +1 -1
  776. package/src/props/index.ts +222 -26
  777. package/src/resolvers/unplugin.ts +83 -47
  778. package/src/shims.d.ts +1 -1
  779. package/src/stories/Accordion/Accordion.stories.mdx +9 -7
  780. package/src/stories/Accordion/Accordion.test.ts +1 -1
  781. package/src/stories/Accordion/AccordionSlots.stories.mdx +2 -2
  782. package/src/stories/AccordionGroup/AccordionGroup.stories.mdx +6 -4
  783. package/src/stories/AccordionGroup/AccordionGroupSlots.stories.mdx +12 -9
  784. package/src/stories/Badge/Badge.stories.mdx +4 -3
  785. package/src/stories/Breadcrumb/Breadcrumb.stories.mdx +6 -4
  786. package/src/stories/Breadcrumb/Breadcrumb.test.ts +14 -12
  787. package/src/stories/Breadcrumb/BreadcrumbSlots.stories.mdx +8 -8
  788. package/src/stories/Button/Button.stories.mdx +10 -8
  789. package/src/stories/Button/Button.test.ts +9 -7
  790. package/src/stories/Button/ButtonModifiers.stories.mdx +4 -4
  791. package/src/stories/Button/ButtonSlots.stories.mdx +20 -15
  792. package/src/stories/Button/ButtonState.stories.mdx +2 -11
  793. package/src/stories/ButtonGroup/ButtonGroup.stories.mdx +2 -2
  794. package/src/stories/ButtonGroup/ButtonGroupSlots.stories.mdx +2 -2
  795. package/src/stories/Card/Card.stories.mdx +4 -3
  796. package/src/stories/Card/Card.test.ts +1 -1
  797. package/src/stories/Card/CardSlots.stories.mdx +2 -2
  798. package/src/stories/Checkbox/Checkbox.stories.mdx +9 -8
  799. package/src/stories/CheckboxGroup/CheckboxGroup.stories.mdx +9 -8
  800. package/src/stories/CheckboxGroup/CheckboxGroupSlots.stories.mdx +11 -10
  801. package/src/stories/Combobox/Combobox.settings.ts +155 -4
  802. package/src/stories/Combobox/Combobox.stories.mdx +125 -5
  803. package/src/stories/Combobox/Combobox.test.ts +2 -2
  804. package/src/stories/Combobox/ComboboxIconPosition.stories.mdx +78 -0
  805. package/src/stories/Combobox/ComboboxMultiple.stories.mdx +1 -2
  806. package/src/stories/Combobox/ComboboxSlots.stories.mdx +107 -2
  807. package/src/stories/Dialog/Dialog.stories.mdx +4 -3
  808. package/src/stories/Dialog/Dialog.test.ts +4 -4
  809. package/src/stories/Dropdown/Dropdown.settings.ts +55 -36
  810. package/src/stories/Dropdown/Dropdown.stories.mdx +60 -59
  811. package/src/stories/Dropdown/Dropdown.test.ts +10 -32
  812. package/src/stories/Dropdown/DropdownMultilevel.stories.mdx +56 -0
  813. package/src/stories/Dropdown/DropdownSlots.stories.mdx +114 -0
  814. package/src/stories/Icon/Icon.stories.mdx +3 -2
  815. package/src/stories/Icon/IconsCollection.stories.mdx +4 -3
  816. package/src/stories/InputText/InputText.settings.ts +2 -1
  817. package/src/stories/InputText/InputText.stories.mdx +9 -5
  818. package/src/stories/InputText/InputTextIconPosition.stories.mdx +2 -2
  819. package/src/stories/InputText/InputTextSlots.stories.mdx +2 -2
  820. package/src/stories/Progress/Progress.stories.mdx +5 -2
  821. package/src/stories/Progress/Progress.test.ts +1 -1
  822. package/src/stories/Radio/Radio.stories.mdx +3 -2
  823. package/src/stories/RadioGroup/RadioGroup.stories.mdx +9 -8
  824. package/src/stories/RadioGroup/RadioGroupSlots.stories.mdx +11 -10
  825. package/src/stories/Select/Select.settings.ts +2 -2
  826. package/src/stories/Select/Select.stories.mdx +5 -4
  827. package/src/stories/Select/SelectIconPosition.stories.mdx +78 -0
  828. package/src/stories/Select/SelectSlots.stories.mdx +2 -2
  829. package/src/stories/Textarea/Textarea.settings.ts +2 -1
  830. package/src/stories/Textarea/Textarea.stories.mdx +6 -5
  831. package/src/stories/Textarea/TextareaSlots.stories.mdx +2 -2
  832. package/src/stories/Textarea/TextareatIconPosition.stories.mdx +2 -2
  833. package/src/stories/Tooltip/Tooltip.settings.ts +13 -13
  834. package/src/stories/Tooltip/Tooltip.stories.mdx +26 -22
  835. package/src/stories/Tooltip/Tooltip.test.ts +22 -13
  836. package/src/stories/Tooltip/TooltipDirective.stories.mdx +99 -0
  837. package/src/stories/argTypes.ts +153 -4
  838. package/src/types/floating-ui.d.ts +7 -0
  839. package/src/types/generic.d.ts +0 -1
  840. package/src/types/group.d.ts +37 -0
  841. package/src/utils/ObjectUtilities.ts +4 -1
  842. package/dist/composables/group/types/IAccordionGroupState.d.ts +0 -9
  843. package/dist/composables/group/types/IButtonGroupState.d.ts +0 -13
  844. package/dist/composables/group/types/IGroupState.d.ts +0 -8
  845. package/dist/composables/group/types/IInputGroup.d.ts +0 -8
  846. package/dist/composables/useComponentIcons.d.ts +0 -27
  847. package/src/composables/group/types/IAccordionGroupState.ts +0 -10
  848. package/src/composables/group/types/IButtonGroupState.ts +0 -14
  849. package/src/composables/group/types/IGroupState.ts +0 -10
  850. package/src/composables/group/types/IInputGroup.ts +0 -9
  851. package/src/composables/useComponentIcons.ts +0 -96
  852. package/src/directives/.gitkeep +0 -0
  853. package/src/stories/Dropdown/DropdownOptions.stories.mdx +0 -96
@@ -1,793 +1,1361 @@
1
- import { defineComponent as N, openBlock as m, createElementBlock as _, unref as t, normalizeClass as U, withModifiers as Re, createElementVNode as R, renderSlot as k, normalizeProps as F, guardReactiveProps as Y, createTextVNode as q, toDisplayString as B, Fragment as de, renderList as fe, createBlock as D, mergeProps as O, withCtx as he, resolveDynamicComponent as Ge, createCommentVNode as I, withDirectives as ve, isRef as be, vModelCheckbox as lt, createVNode as Z, vModelSelect as nt, withKeys as Le, vModelText as xe, Transition as rt, toHandlers as it, vShow as ut, vModelDynamic as dt, vModelRadio as ct } from "vue";
2
- import { nanoid as ne } from "nanoid";
3
- import { iconExists as $e, Icon as pt, addIcon as vt } from "@iconify/vue";
4
- const Ue = "VV_BUTTON_GROUP", Fe = "VV_RADIO_GROUP", Ke = "VV_CHECK_GROUP", We = "VV_ACCORDION_GROUP", mt = {
1
+ import { unref as a, inject as We, computed as n, toRef as il, toRefs as G, defineComponent as j, useAttrs as yt, ref as N, openBlock as f, createElementBlock as g, normalizeClass as le, withModifiers as Tt, createElementVNode as M, renderSlot as V, normalizeProps as K, guardReactiveProps as z, createTextVNode as Y, toDisplayString as T, isRef as Ee, provide as gt, watchEffect as _t, Fragment as ie, renderList as Ne, createBlock as H, mergeProps as R, withCtx as te, resolveDynamicComponent as Nt, createCommentVNode as C, watch as ve, useSlots as Ae, h as be, onMounted as ul, withDirectives as Oe, vModelCheckbox as dl, createVNode as pe, nextTick as Xe, Transition as Rt, normalizeStyle as It, vShow as St, vModelSelect as cl, createSlots as vl, vModelText as Ht, toHandlers as fl, vModelDynamic as pl, vModelRadio as ml } from "vue";
2
+ import { nanoid as Mt } from "nanoid";
3
+ import { useToggle as bl, toReactive as hl, useVModel as et, onClickOutside as xt, useFocusWithin as Vt, onKeyStroke as He, useElementHover as yl, useFocus as Gt, useElementVisibility as $t, refDebounced as gl } from "@vueuse/core";
4
+ import { iconExists as Ye, Icon as _l, addIcon as Sl } from "@iconify/vue";
5
+ import { autoPlacement as Et, flip as Pt, shift as Ot, size as Dt, offset as ct, arrow as Vl, useFloating as $l, autoUpdate as kl } from "@floating-ui/vue";
6
+ import Al from "mitt";
7
+ var fe = /* @__PURE__ */ ((t) => (t.left = "left", t.right = "right", t.top = "top", t.bottom = "bottom", t))(fe || {}), jt = /* @__PURE__ */ ((t) => (t.topStart = "top-start", t.topEnd = "top-end", t.bottomStart = "bottom-start", t.bottomEnd = "bottom-end", t.leftStart = "left-start", t.leftEnd = "left-end", t.rightStart = "right-start", t.rightEnd = "right-end", t))(jt || {}), Ge = /* @__PURE__ */ ((t) => (t.before = "before", t.after = "after", t))(Ge || {}), pt = /* @__PURE__ */ ((t) => (t.button = "button", t.submit = "submit", t.reset = "reset", t))(pt || {}), ke = /* @__PURE__ */ ((t) => (t.nuxtLink = "nuxt-link", t.routerLink = "router-link", t.a = "a", t.button = "button", t))(ke || {}), Wt = /* @__PURE__ */ ((t) => (t.button = "button", t.link = "link", t.menuitem = "menuitem", t))(Wt || {}), je = /* @__PURE__ */ ((t) => (t.listbox = "listbox", t.menu = "menu", t))(je || {}), mt = /* @__PURE__ */ ((t) => (t.option = "option", t.presentation = "presentation", t))(mt || {}), Ut = /* @__PURE__ */ ((t) => (t._blank = "_blank", t._self = "_self", t._parent = "_parent", t._top = "_top", t))(Ut || {});
8
+ const wl = Symbol.for("volver"), Ft = Symbol.for("buttonGroup"), Kt = Symbol.for("radioGroup"), zt = Symbol.for("checkGroup"), qt = Symbol.for("accordionGroup"), Yt = Symbol.for("dropdownTrigger"), Jt = Symbol.for("dropdownItem"), Xt = Symbol.for("dropdownAction");
9
+ function Pe(t, l, e) {
10
+ return e ? Ze(t, e) === Ze(l, e) : bt(t, l);
11
+ }
12
+ function bt(t, l) {
13
+ if (t === l)
14
+ return !0;
15
+ if (t && l && typeof t == "object" && typeof l == "object") {
16
+ const e = Array.isArray(t), s = Array.isArray(l);
17
+ let o, c, u;
18
+ if (e && s) {
19
+ if (c = t.length, c != l.length)
20
+ return !1;
21
+ for (o = c; o-- !== 0; )
22
+ if (!bt(t[o], l[o]))
23
+ return !1;
24
+ return !0;
25
+ }
26
+ if (e != s)
27
+ return !1;
28
+ const v = t instanceof Date, d = l instanceof Date;
29
+ if (v != d)
30
+ return !1;
31
+ if (v && d)
32
+ return t.getTime() == l.getTime();
33
+ const p = t instanceof RegExp, r = l instanceof RegExp;
34
+ if (p != r)
35
+ return !1;
36
+ if (p && r)
37
+ return t.toString() == l.toString();
38
+ const i = Object.keys(t);
39
+ if (c = i.length, c !== Object.keys(l).length)
40
+ return !1;
41
+ for (o = c; o-- !== 0; )
42
+ if (!Object.prototype.hasOwnProperty.call(l, i[o]))
43
+ return !1;
44
+ for (o = c; o-- !== 0; )
45
+ if (u = i[o], !bt(t[u], l[u]))
46
+ return !1;
47
+ return !0;
48
+ }
49
+ return t !== t && l !== l;
50
+ }
51
+ function Ze(t, l) {
52
+ if (t && Object.keys(t).length && l) {
53
+ if (l.indexOf(".") === -1)
54
+ return t[l];
55
+ {
56
+ const e = l.split(".");
57
+ let s = t;
58
+ for (let o = 0, c = e.length; o < c; ++o) {
59
+ if (t == null)
60
+ return null;
61
+ s = s[e[o]];
62
+ }
63
+ return s;
64
+ }
65
+ } else
66
+ return null;
67
+ }
68
+ function Cl(t, l) {
69
+ let e = -1;
70
+ if (l) {
71
+ for (let s = 0; s < l.length; s++)
72
+ if (Pe(l[s], t)) {
73
+ e = s;
74
+ break;
75
+ }
76
+ }
77
+ return e;
78
+ }
79
+ function Ce(t, l) {
80
+ if (t != null && l && l.length) {
81
+ for (const e of l)
82
+ if (Pe(t, e))
83
+ return !0;
84
+ }
85
+ return !1;
86
+ }
87
+ function ge(t) {
88
+ return ((l) => l == null || l === "" || Array.isArray(l) && l.length === 0 || !(l instanceof Date) && typeof l == "object" && Object.keys(l).length === 0)(a(t));
89
+ }
90
+ function Il(t, l) {
91
+ const e = Cl(t, l);
92
+ return e > -1 ? l.filter((s, o) => o !== e) : l;
93
+ }
94
+ function El(t) {
95
+ return typeof t == "string" || t instanceof String;
96
+ }
97
+ function tt(t) {
98
+ const l = We(t, void 0), e = n(() => !ge(l));
99
+ function s(o, c, u) {
100
+ if (l != null && l.value) {
101
+ const d = a(l.value)[o];
102
+ return n({
103
+ get() {
104
+ return d == null ? void 0 : d.value;
105
+ },
106
+ set(p) {
107
+ d.value = p;
108
+ }
109
+ });
110
+ }
111
+ const v = il(c, o);
112
+ return n({
113
+ get() {
114
+ return v.value;
115
+ },
116
+ set(d) {
117
+ u && u(`update:${o}`, d);
118
+ }
119
+ });
120
+ }
121
+ return {
122
+ group: l,
123
+ isInGroup: e,
124
+ getGroupOrLocalRef: s
125
+ };
126
+ }
127
+ const Pl = {
128
+ /**
129
+ * Accordion name
130
+ */
5
131
  name: String,
132
+ /**
133
+ * Header title
134
+ */
6
135
  title: String,
136
+ /**
137
+ * Content text
138
+ */
7
139
  content: String,
140
+ /**
141
+ * (Optional) Defines if item is open. Event "update:modelValue" is emitted on accordion header click
142
+ */
8
143
  modelValue: {
9
144
  type: Boolean,
10
145
  default: void 0
11
146
  },
147
+ /**
148
+ * String or String[] of css classes (modifiers) that will be concatenated to prefix 'vv-accordion--'
149
+ */
12
150
  modifiers: [String, Array],
151
+ /**
152
+ * If true, the accordion will be disabled
153
+ */
13
154
  disabled: Boolean
14
- }, ft = ["update:modelValue"];
15
- function bt(o, a) {
16
- const { group: e, isInGroup: n, getGroupOrLocalRef: s } = useInjectedGroupState(We), { title: d, content: r } = toRefs(o), f = s("modelValue", o, a), p = s("disabled", o), i = s("collapse", o), l = s("modifiers", o);
155
+ }, Ol = ["update:modelValue"];
156
+ function Dl(t, l) {
157
+ const { group: e, isInGroup: s, getGroupOrLocalRef: o } = tt(
158
+ qt
159
+ ), { title: c, content: u } = G(t), v = o("modelValue", t, l), d = o("disabled", t), p = o("collapse", t), r = o("modifiers", t);
17
160
  return {
18
- modelValue: f,
19
- disabled: p,
20
- isInGroup: n,
161
+ // group props
162
+ modelValue: v,
163
+ disabled: d,
164
+ isInGroup: s,
21
165
  group: e,
22
- collapse: i,
23
- modifiers: l,
24
- title: d,
25
- content: r
166
+ collapse: p,
167
+ modifiers: r,
168
+ // local props
169
+ title: c,
170
+ content: u
26
171
  };
27
172
  }
28
- const ht = ["id", "open"], gt = ["aria-controls", "aria-expanded"], yt = ["aria-hidden"], _t = {
173
+ function X(t, l, e) {
174
+ return n(() => {
175
+ const s = {
176
+ [t]: !0
177
+ }, o = typeof (l == null ? void 0 : l.value) == "string" ? l.value.split(" ") : l == null ? void 0 : l.value;
178
+ return o && Array.isArray(o) && o.forEach((c) => {
179
+ s[`${t}--${c}`] = !0;
180
+ }), e && Object.keys(e.value).forEach((c) => {
181
+ s[`${t}--${c}`] = a(e.value[c]);
182
+ }), s;
183
+ });
184
+ }
185
+ const Ll = ["id", "open"], Bl = ["aria-controls", "aria-expanded"], Tl = ["aria-hidden"], Nl = {
29
186
  name: "VvAccordion"
30
- }, St = /* @__PURE__ */ N({
31
- ..._t,
32
- props: mt,
33
- emits: ft,
34
- setup(o, { emit: a }) {
35
- const e = o, n = useAttrs(), s = e.name || (n == null ? void 0 : n.id) || ne(), {
36
- modifiers: d,
37
- title: r,
38
- content: f,
39
- disabled: p,
40
- collapse: i,
41
- modelValue: l,
42
- isInGroup: c
43
- } = bt(e, a), u = ref(!1), b = computed({
44
- get: () => c.value ? i.value && Array.isArray(l.value) ? l.value.includes(s) : l.value === s : l.value === void 0 ? u.value : l.value,
45
- set: (v) => {
46
- if (c.value) {
47
- if (i.value && Array.isArray(l.value)) {
48
- if (v) {
49
- l.value.push(s);
187
+ }, Rl = /* @__PURE__ */ j({
188
+ ...Nl,
189
+ props: Pl,
190
+ emits: Ol,
191
+ setup(t, { emit: l }) {
192
+ const e = t, s = yt(), o = n(
193
+ () => e.name || (s == null ? void 0 : s.id) || Mt()
194
+ ), {
195
+ modifiers: c,
196
+ title: u,
197
+ content: v,
198
+ disabled: d,
199
+ collapse: p,
200
+ modelValue: r,
201
+ isInGroup: i
202
+ } = Dl(e, l), b = N(!1), _ = n({
203
+ get: () => i.value ? p.value && Array.isArray(r.value) ? r.value.includes(o.value) : r.value === o.value : r.value === void 0 ? b.value : r.value,
204
+ set: (y) => {
205
+ if (i.value) {
206
+ if (p.value && Array.isArray(r.value)) {
207
+ if (y) {
208
+ r.value.push(o.value);
50
209
  return;
51
210
  }
52
- l.value = l.value.filter(
53
- (V) => V !== s
211
+ r.value = r.value.filter(
212
+ (m) => m !== o.value
54
213
  );
55
214
  return;
56
215
  }
57
- l.value = v ? s : null;
216
+ r.value = y ? o.value : null;
58
217
  return;
59
218
  }
60
- if (l.value === void 0 && typeof v == "boolean") {
61
- u.value = v;
219
+ if (r.value === void 0 && typeof y == "boolean") {
220
+ b.value = y;
62
221
  return;
63
222
  }
64
- l.value = v;
223
+ r.value = y;
65
224
  }
66
- }), { bemCssClasses: g } = useBemModifiers("vv-accordion", {
67
- modifiers: d,
68
- disabled: p
69
- }), y = useToggle(b);
70
- return (v, V) => (m(), _("details", {
71
- id: t(s),
72
- class: U(t(g)),
73
- open: t(b),
74
- onClick: V[0] || (V[0] = Re((w) => t(y)(), ["prevent"]))
225
+ }), k = X(
226
+ "vv-accordion",
227
+ c,
228
+ n(() => ({
229
+ disabled: d.value
230
+ }))
231
+ ), A = bl(_);
232
+ return (y, m) => (f(), g("details", {
233
+ id: a(o),
234
+ class: le(a(k)),
235
+ open: a(_),
236
+ onClick: m[0] || (m[0] = Tt((I) => a(A)(), ["prevent"]))
75
237
  }, [
76
- R("summary", {
77
- "aria-controls": t(s),
78
- "aria-expanded": t(b),
238
+ M("summary", {
239
+ "aria-controls": a(o),
240
+ "aria-expanded": a(_),
79
241
  class: "vv-collapse__summary"
80
242
  }, [
81
- k(v.$slots, "summary", F(Y({ open: t(b) })), () => [
82
- q(B(t(r)), 1)
243
+ V(y.$slots, "summary", K(z({ open: a(_) })), () => [
244
+ Y(T(a(u)), 1)
83
245
  ])
84
- ], 8, gt),
85
- R("div", {
86
- "aria-hidden": !t(b),
246
+ ], 8, Bl),
247
+ M("div", {
248
+ "aria-hidden": !a(_),
87
249
  class: "vv-collapse__content"
88
250
  }, [
89
- k(v.$slots, "details", F(Y({ open: t(b) })), () => [
90
- q(B(t(f)), 1)
251
+ V(y.$slots, "details", K(z({ open: a(_) })), () => [
252
+ Y(T(a(v)), 1)
91
253
  ])
92
- ], 8, yt)
93
- ], 10, ht));
254
+ ], 8, Tl)
255
+ ], 10, Ll));
94
256
  }
95
- }), Vt = {
257
+ }), Hl = {
258
+ /**
259
+ * VModel
260
+ */
96
261
  modelValue: [String, Array],
262
+ /**
263
+ * Accordion items
264
+ * @type VvAccordionGroupItem
265
+ */
97
266
  items: { type: Array, default: () => [] },
267
+ /**
268
+ * If true, accordion items stay open when another item is opened
269
+ */
98
270
  collapse: Boolean,
271
+ /**
272
+ * String or String[] of css classes (modifiers) that will be concatenated to prefix 'vv-accordion-group--'
273
+ */
99
274
  modifiers: [String, Array],
275
+ /**
276
+ * String or String[] of css classes (modifiers) that will be concatenated to prefix 'vv-accordion--'
277
+ */
100
278
  itemModifiers: {
101
279
  type: [String, Array],
102
280
  default: ""
103
281
  },
282
+ /**
283
+ * If true, the accordion items will be disabled
284
+ */
104
285
  disabled: Boolean
105
- }, $t = ["update:modelValue"], Ct = {
286
+ }, Ml = ["update:modelValue"];
287
+ function lt(t) {
288
+ if (Object.keys(t).some(
289
+ (l) => l !== "key" && !Ee(t[l])
290
+ ))
291
+ throw Error("One or more groupState props aren't ref.");
292
+ gt(
293
+ t.key,
294
+ n(() => t)
295
+ );
296
+ }
297
+ const xl = {
106
298
  name: "VvAccordionGroup"
107
- }, ys = /* @__PURE__ */ N({
108
- ...Ct,
109
- props: Vt,
110
- emits: $t,
111
- setup(o, { emit: a }) {
112
- const e = o, { disabled: n, collapse: s, modifiers: d, itemModifiers: r, items: f } = toRefs(e);
113
- watchEffect(() => {
114
- typeof e.modelValue == "string" && s.value && console.warn(
299
+ }, ds = /* @__PURE__ */ j({
300
+ ...xl,
301
+ props: Hl,
302
+ emits: Ml,
303
+ setup(t, { emit: l }) {
304
+ const e = t, { disabled: s, collapse: o, modifiers: c, itemModifiers: u, items: v } = G(e);
305
+ _t(() => {
306
+ typeof e.modelValue == "string" && o.value && console.warn(
115
307
  "[VvAccordionGroup]: modelValue is a string but collapse is true."
116
308
  );
117
309
  });
118
- const p = ref([]), i = computed({
310
+ const d = N([]), p = n({
119
311
  get: () => {
120
- var u;
121
- return e.modelValue !== void 0 ? s.value ? e.modelValue : Array.isArray(e.modelValue) ? e.modelValue[0] : e.modelValue : s.value ? p.value : (u = p.value) == null ? void 0 : u[0];
312
+ var i;
313
+ return e.modelValue !== void 0 ? o.value ? e.modelValue : Array.isArray(e.modelValue) ? e.modelValue[0] : e.modelValue : o.value ? d.value : (i = d.value) == null ? void 0 : i[0];
122
314
  },
123
- set: (u) => {
315
+ set: (i) => {
124
316
  if (e.modelValue !== void 0)
125
- return (Array.isArray(e.modelValue) || s.value) && !Array.isArray(u) && (u = [u]), a("update:modelValue", u);
126
- p.value = Array.isArray(u) ? u : [u];
317
+ return (Array.isArray(e.modelValue) || o.value) && !Array.isArray(i) && (i = [i]), l("update:modelValue", i);
318
+ d.value = Array.isArray(i) ? i : [i];
127
319
  }
128
- }), l = {
129
- key: We,
130
- modelValue: i,
131
- disabled: n,
132
- collapse: s,
133
- modifiers: r
134
- };
135
- useProvideGroupState(l);
136
- const { bemCssClasses: c } = useBemModifiers("vv-accordion-group", {
137
- modifiers: d,
138
- disabled: n
139
320
  });
140
- return (u, b) => (m(), _("div", {
141
- class: U(t(c))
321
+ lt({
322
+ key: qt,
323
+ modelValue: p,
324
+ disabled: s,
325
+ collapse: o,
326
+ modifiers: u
327
+ });
328
+ const r = X(
329
+ "vv-accordion-group",
330
+ c,
331
+ n(() => ({
332
+ disabled: s.value
333
+ }))
334
+ );
335
+ return (i, b) => (f(), g("div", {
336
+ class: le(a(r))
142
337
  }, [
143
- k(u.$slots, "default", {}, () => [
144
- (m(!0), _(de, null, fe(t(f), (g) => (m(), D(St, O({
145
- key: g.title
338
+ V(i.$slots, "default", {}, () => [
339
+ (f(!0), g(ie, null, Ne(a(v), (_) => (f(), H(Rl, R({
340
+ key: _.title
146
341
  }, {
147
- name: g.name,
148
- title: g.title,
149
- content: g.content
342
+ name: _.name,
343
+ title: _.title,
344
+ content: _.content
150
345
  }), {
151
- header: he((y) => [
152
- k(u.$slots, `header::${g.name}`, F(Y(y)))
346
+ header: te((k) => [
347
+ V(i.$slots, `header::${_.name}`, K(z(k)))
153
348
  ]),
154
- details: he((y) => [
155
- k(u.$slots, `details::${g.name}`, F(Y(y)))
349
+ details: te((k) => [
350
+ V(i.$slots, `details::${_.name}`, K(z(k)))
156
351
  ]),
157
352
  _: 2
158
353
  }, 1040))), 128))
159
354
  ])
160
355
  ], 2));
161
356
  }
162
- }), ge = {
357
+ }), Gl = {
358
+ /**
359
+ * The router-link/nuxt-link property, if it is defined the button is rendered as a ruouter-link or nuxt-link.
360
+ * @see Documentation of [router-link](https://router.vuejs.org/api/#router-link) and [nuxt-link](https://nuxtjs.org/api/components-nuxt-link/)
361
+ */
362
+ to: {
363
+ type: [String, Object]
364
+ },
365
+ /**
366
+ * Anchor href
367
+ */
368
+ href: String,
369
+ /**
370
+ * Anchor target
371
+ */
372
+ target: {
373
+ type: String,
374
+ validator: (t) => Object.values(Ut).includes(t)
375
+ },
376
+ /**
377
+ * Anchor rel
378
+ */
379
+ rel: {
380
+ type: String,
381
+ default: "noopener noreferrer"
382
+ }
383
+ }, Ue = {
384
+ /**
385
+ * Valid status
386
+ */
163
387
  valid: Boolean,
388
+ /**
389
+ * Valid label
390
+ */
164
391
  validLabel: [String, Array]
165
- }, ye = {
392
+ }, Fe = {
393
+ /**
394
+ * Invalid status
395
+ */
166
396
  invalid: Boolean,
397
+ /**
398
+ * Invalid label
399
+ */
167
400
  invalidLabel: [String, Array]
168
- }, Oe = {
401
+ }, at = {
402
+ /**
403
+ * Loading status
404
+ */
169
405
  loading: Boolean,
170
- loadingLabel: String
171
- }, ce = {
406
+ /**
407
+ * Loading label
408
+ */
409
+ loadingLabel: {
410
+ type: String,
411
+ default: "Loading..."
412
+ }
413
+ }, De = {
414
+ /**
415
+ * Whether the form control is disabled
416
+ */
172
417
  disabled: Boolean
173
- }, _e = {
418
+ }, jl = {
419
+ /**
420
+ * Whether the item is selected
421
+ */
422
+ selected: Boolean
423
+ }, Wl = {
424
+ /**
425
+ * Whether the item is active
426
+ */
427
+ active: Boolean
428
+ }, Ul = {
429
+ /**
430
+ * Whether the item is pressed
431
+ */
432
+ pressed: Boolean
433
+ }, Me = {
434
+ /**
435
+ * The item label
436
+ */
437
+ label: [String, Number]
438
+ }, Ke = {
439
+ /**
440
+ * The value is not editable
441
+ */
174
442
  readonly: Boolean
175
- }, re = {
443
+ }, me = {
444
+ /**
445
+ * Component BEM modifiers
446
+ */
176
447
  modifiers: [String, Array]
177
- }, Se = {
448
+ }, ze = {
178
449
  hintLabel: { type: String, default: "" }
179
- }, ke = {
450
+ }, kt = {
451
+ /**
452
+ * List of options, can be string[] or object[]
453
+ */
180
454
  options: {
181
455
  type: Array,
182
456
  default: () => []
183
457
  },
458
+ /**
459
+ * Used when options are objects: key to use for option label
460
+ */
184
461
  labelKey: { type: [String, Function], default: "label" },
185
- valueKey: { type: [String, Function], default: "value" }
186
- }, kt = {
462
+ /**
463
+ * Used when options are objects: key to use for option label
464
+ */
465
+ valueKey: { type: [String, Function], default: "value" },
466
+ /**
467
+ * Used when options are objects: key to use for option disabled
468
+ */
469
+ disabledKey: { type: [String, Function], default: "disabled" }
470
+ }, Fl = {
471
+ /**
472
+ * Show character limit
473
+ */
187
474
  count: {
188
475
  type: [Boolean, String],
189
476
  default: !1,
190
- validator: (o) => [!0, !1, "limit", "countdown"].includes(o)
477
+ validator: (t) => [!0, !1, "limit", "countdown"].includes(t)
191
478
  }
192
- }, At = {
479
+ }, Kl = {
480
+ /**
481
+ * Milliseconds to wait before emitting the input event
482
+ */
193
483
  debounce: [Number, String]
194
- }, Me = {
195
- LEFT: "left",
196
- RIGHT: "right"
197
- }, Be = {
484
+ }, At = {
485
+ /**
486
+ * VvIcon name or props
487
+ * @see VVIcon
488
+ */
198
489
  icon: { type: [String, Object] },
490
+ /**
491
+ * VvIcon position
492
+ */
199
493
  iconPosition: {
200
494
  type: String,
201
- validation: (o) => Object.values(Me).includes(o),
202
- default: Me.RIGHT
495
+ default: Ge.before,
496
+ validation: (t) => Object.values(Ge).includes(t)
203
497
  }
204
- }, Ae = {
498
+ }, ot = {
499
+ /**
500
+ * Global attribute tabindex
501
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/tabindex
502
+ */
205
503
  tabindex: { type: [String, Number], default: 0 }
206
- }, De = {
504
+ }, wt = {
505
+ /**
506
+ * If true the label will be floating
507
+ */
207
508
  floating: Boolean
208
- }, Pe = {
509
+ }, qe = {
510
+ /**
511
+ * If true the input will be unselectable
512
+ */
209
513
  unselectable: { type: Boolean, default: !0 }
210
- }, Ve = {
211
- id: [String, Number],
514
+ }, st = {
515
+ /**
516
+ * Global attribute id
517
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/id
518
+ */
519
+ id: [String, Number]
520
+ }, ht = {
521
+ /**
522
+ * Dropdown placement
523
+ */
524
+ placement: {
525
+ type: String,
526
+ default: fe.bottom,
527
+ validator: (t) => Object.values(fe).includes(t) || Object.values(jt).includes(t)
528
+ },
529
+ /**
530
+ * Dropdown show / hide transition name
531
+ */
532
+ transitionName: {
533
+ type: String
534
+ },
535
+ /**
536
+ * Offset of the dropdown from the trigger
537
+ * @see https://floating-ui.com/docs/offset
538
+ */
539
+ offset: {
540
+ type: [Number, String, Object],
541
+ default: 0
542
+ },
543
+ /**
544
+ * Move dropdown to the side if there is no space in the default position
545
+ * @see https://floating-ui.com/docs/shift
546
+ */
547
+ shift: {
548
+ type: [Boolean, Object],
549
+ default: !1
550
+ },
551
+ /**
552
+ * Flip dropdown position if there is no space in the default position
553
+ * @see https://floating-ui.com/docs/flip
554
+ */
555
+ flip: {
556
+ type: [Boolean, Object],
557
+ default: !0
558
+ },
559
+ /**
560
+ * Size of the dropdown
561
+ * @see https://floating-ui.com/docs/size
562
+ */
563
+ size: {
564
+ type: [Boolean, Object],
565
+ default: () => ({ padding: 10 })
566
+ },
567
+ /**
568
+ * Automatically change the position of the dropdown
569
+ * @see https://floating-ui.com/docs/autoPlacement
570
+ */
571
+ autoPlacement: {
572
+ type: [Boolean, Object],
573
+ default: !1
574
+ },
575
+ /**
576
+ * Add arrow to the dropdown
577
+ * @see https://floating-ui.com/docs/arrow
578
+ */
579
+ arrow: {
580
+ type: Boolean,
581
+ default: !1
582
+ },
583
+ /**
584
+ * Close dropdown on click outside
585
+ */
586
+ autoClose: {
587
+ type: Boolean,
588
+ default: !0
589
+ },
590
+ /**
591
+ * Autofocus first item on dropdown open
592
+ */
593
+ autofocusFirst: {
594
+ type: Boolean,
595
+ default: !0
596
+ },
597
+ /**
598
+ * Set dropdown width to the same as the trigger
599
+ */
600
+ triggerWidth: {
601
+ type: Boolean
602
+ }
603
+ }, nt = {
604
+ ...st,
605
+ /**
606
+ * Input / Textarea name
607
+ * Name of the form control. Submitted with the form as part of a name/value pair
608
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#name
609
+ */
212
610
  name: { type: String, required: !0 }
213
- }, qe = {
611
+ }, Qt = {
612
+ /**
613
+ * Global attribute autofocus
614
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/autofocus
615
+ */
214
616
  autofocus: Boolean
215
- }, je = {
617
+ }, Zt = {
618
+ /**
619
+ * Global attribute autocomplete
620
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete
621
+ */
216
622
  autocomplete: { type: String, default: "off" }
217
- }, ze = {
218
- ...Ve,
219
- ...qe,
220
- ...je,
221
- ...Ae,
222
- ...ce,
223
- ..._e,
224
- ...ge,
225
- ...ye,
226
- ...Se,
227
- ...Oe,
228
- ...re,
229
- ...kt,
230
- ...At,
231
- ...Be,
623
+ }, el = {
624
+ ...nt,
625
+ ...Qt,
626
+ ...Zt,
627
+ ...ot,
232
628
  ...De,
629
+ ...Ke,
630
+ ...Ue,
631
+ ...Fe,
632
+ ...ze,
633
+ ...at,
634
+ ...me,
635
+ ...Fl,
636
+ ...Kl,
637
+ ...At,
638
+ ...wt,
639
+ ...Me,
640
+ /**
641
+ * Input / Textarea minlength
642
+ * Minimum length (number of characters) of value
643
+ * Available for input types: text, search, url, tel, email, password
644
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#minlength
645
+ */
233
646
  minlength: Number,
647
+ /**
648
+ * Input / Textarea maxlength
649
+ * Maximum length (number of characters) of value
650
+ * Available for input types: text, search, url, tel, email, password
651
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#maxlength
652
+ */
234
653
  maxlength: Number,
654
+ /**
655
+ * Input / Textarea placeholder
656
+ * Text that appears in the form control when it has no value set
657
+ * Available for input types: text, search, url, tel, email, password, number
658
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#placeholder
659
+ */
235
660
  placeholder: String,
236
- required: Boolean,
237
- label: String
238
- }, Xe = {
239
- ...Ve,
240
- ...Ae,
241
- ...ge,
242
- ...ye,
243
- ...Se,
244
- ...ce,
245
- ..._e,
661
+ /**
662
+ * Input / Textarea required
663
+ * A value is required or must be check for the form to be submittable
664
+ * Available for all input types except color
665
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#required
666
+ */
667
+ required: Boolean
668
+ }, tl = {
669
+ ...nt,
670
+ ...ot,
671
+ ...Ue,
672
+ ...Fe,
673
+ ...ze,
674
+ ...De,
675
+ ...Ke,
676
+ ...me,
677
+ ...Me,
678
+ /**
679
+ * Input value
680
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#value
681
+ */
246
682
  value: [String, Number, Boolean],
247
- modelValue: [Object, Number, Boolean, String],
248
- label: String
249
- }, Ye = {
250
- ...ge,
251
- ...ye,
252
- ...ke,
253
- ...Se,
254
- ...ce,
255
- ..._e,
683
+ /**
684
+ * Input value
685
+ */
686
+ modelValue: [Object, Number, Boolean, String]
687
+ }, ll = {
688
+ ...Ue,
689
+ ...Fe,
690
+ ...kt,
691
+ ...ze,
692
+ ...De,
693
+ ...Ke,
694
+ ...me,
695
+ ...Me,
696
+ /**
697
+ * Input value
698
+ */
256
699
  modelValue: [String, Array],
257
- label: String,
700
+ /**
701
+ * Input name
702
+ */
258
703
  name: { type: String, required: !0 },
704
+ /**
705
+ * If true, the group will be displayed in a vertical column
706
+ */
259
707
  vertical: Boolean
260
- }, Pt = {
261
- ...re,
708
+ }, al = {
709
+ ...De,
710
+ ...Me,
711
+ ...Ul,
712
+ ...Wl,
713
+ ...Gl,
714
+ /**
715
+ * Button type
716
+ */
717
+ type: {
718
+ type: String,
719
+ default: pt.button,
720
+ validator: (t) => Object.values(pt).includes(t)
721
+ }
722
+ }, zl = {
723
+ ...me,
262
724
  value: [String, Number]
263
- }, wt = {
725
+ }, ql = {
264
726
  name: "VvBadge"
265
- }, _s = /* @__PURE__ */ N({
266
- ...wt,
267
- props: Pt,
268
- setup(o) {
269
- const a = o, { bemCssClasses: e } = useBemModifiers("vv-badge", {
270
- modifiers: a.modifiers
271
- });
272
- return (n, s) => (m(), _("span", {
273
- class: U(t(e)),
727
+ }, Yl = /* @__PURE__ */ j({
728
+ ...ql,
729
+ props: zl,
730
+ setup(t) {
731
+ const l = t, { modifiers: e } = G(l), s = X("vv-badge", e);
732
+ return (o, c) => (f(), g("span", {
733
+ class: le(a(s)),
274
734
  role: "status"
275
735
  }, [
276
- k(n.$slots, "default", {}, () => [
277
- q(B(n.value), 1)
736
+ V(o.$slots, "default", {}, () => [
737
+ Y(T(o.value), 1)
278
738
  ])
279
739
  ], 2));
280
740
  }
281
- });
282
- function It(o, a) {
283
- const e = { [`${o}`]: !0 };
284
- return {
285
- bemCssClasses: computed(() => Object.keys(a).reduce((s, d) => {
286
- const r = unref(a[d]) || !1;
287
- if (!r)
288
- return s;
289
- if (d === "modifiers") {
290
- const f = Array.isArray(r) ? r : r.split(" ");
291
- return {
292
- ...s,
293
- ...f.reduce(
294
- (p, i) => ({
295
- ...p,
296
- [`${o}--${kebabCase(i)}`]: !0
297
- }),
298
- {}
299
- )
300
- };
301
- } else
302
- return {
303
- ...s,
304
- [`${o}--${kebabCase(d)}`]: r
305
- };
306
- }, e) || {})
307
- };
308
- }
309
- const Et = {
310
- ...re,
741
+ }), Jl = {
742
+ ...me,
311
743
  routes: Array
312
- }, Rt = { class: "vv-breadcrumb__list" }, Ot = ["content"], Bt = {
744
+ }, Xl = { class: "vv-breadcrumb__list" }, Ql = ["content"], Zl = {
313
745
  name: "VvBreadcrumb"
314
- }, Ss = /* @__PURE__ */ N({
315
- ...Bt,
316
- props: Et,
317
- setup(o) {
318
- const a = o, { bemCssClasses: e } = It("vv-breadcrumb", {
319
- modifiers: a.modifiers
320
- });
321
- return (n, s) => (m(), _("nav", {
322
- class: U(t(e)),
746
+ }, cs = /* @__PURE__ */ j({
747
+ ...Zl,
748
+ props: Jl,
749
+ setup(t) {
750
+ const l = t, { modifiers: e } = G(l), s = X("vv-breadcrumb", e);
751
+ return (o, c) => (f(), g("nav", {
752
+ class: le(a(s)),
323
753
  "aria-label": "breadcrumbs"
324
754
  }, [
325
- R("ol", Rt, [
326
- (m(!0), _(de, null, fe(n.routes, (d, r) => {
327
- var f, p, i, l;
328
- return m(), _("li", {
329
- key: `${d.label}-${r}`,
330
- class: U({
331
- "vv-breadcrumb__item": r < Number((f = n.routes) == null ? void 0 : f.length) - 1,
332
- "vv-breadcrumb__item-active": r === Number((p = n.routes) == null ? void 0 : p.length) - 1
755
+ M("ol", Xl, [
756
+ (f(!0), g(ie, null, Ne(o.routes, (u, v) => {
757
+ var d, p, r, i;
758
+ return f(), g("li", {
759
+ key: `${u.label}-${v}`,
760
+ class: le({
761
+ "vv-breadcrumb__item": v < Number((d = o.routes) == null ? void 0 : d.length) - 1,
762
+ "vv-breadcrumb__item-active": v === Number((p = o.routes) == null ? void 0 : p.length) - 1
333
763
  }),
334
764
  itemprop: "itemListElement",
335
765
  itemtype: "https://schema.org/ListItem",
336
766
  itemscope: ""
337
767
  }, [
338
- (m(), D(Ge(d.to ? "router-link" : d.href ? "a" : "span"), O(d, {
768
+ (f(), H(Nt(u.to ? "router-link" : u.href ? "a" : "span"), R(u, {
339
769
  class: {
340
- "vv-breadcrumb__link": r < Number((i = n.routes) == null ? void 0 : i.length) - 1
770
+ "vv-breadcrumb__link": v < Number((r = o.routes) == null ? void 0 : r.length) - 1
341
771
  },
342
- "aria-current": r === Number((l = n.routes) == null ? void 0 : l.length) - 1 ? "page" : void 0,
772
+ "aria-current": v === Number((i = o.routes) == null ? void 0 : i.length) - 1 ? "page" : void 0,
343
773
  itemprop: "item"
344
774
  }), {
345
- default: he(() => [
346
- k(n.$slots, "label", F(Y({ route: d, index: r })), () => [
347
- q(B(d.label), 1)
775
+ default: te(() => [
776
+ V(o.$slots, "label", K(z({ route: u, index: v })), () => [
777
+ Y(T(u.label), 1)
348
778
  ])
349
779
  ]),
350
780
  _: 2
351
781
  }, 1040, ["class", "aria-current"])),
352
- R("meta", {
782
+ M("meta", {
353
783
  itemprop: "position",
354
- content: `${r + 1}`
355
- }, null, 8, Ot)
784
+ content: `${v + 1}`
785
+ }, null, 8, Ql)
356
786
  ], 2);
357
787
  }), 128))
358
788
  ])
359
789
  ], 2));
360
790
  }
361
- }), Je = "ds", Dt = {
791
+ }), ea = {
792
+ /**
793
+ * Color
794
+ */
362
795
  color: String,
796
+ /**
797
+ * Width
798
+ */
363
799
  width: {
364
800
  type: [String, Number]
365
801
  },
802
+ /**
803
+ * Height
804
+ */
366
805
  height: {
367
806
  type: [String, Number]
368
807
  },
808
+ /**
809
+ * Icon name
810
+ * Can be the full composition of iconify name "@{provider}:{prefix}:{name}" or "{prefix}:{name}" or "{name}"
811
+ * https://docs.iconify.design/api/providers.html#provider-in-icon-name
812
+ */
369
813
  name: {
370
814
  type: String,
371
815
  required: !0
372
816
  },
817
+ /**
818
+ * By default 'vv'
819
+ * If custom collection is not added with "addCollection" DS class method, this prop could not be used
820
+ * Icon provider: https://docs.iconify.design/api/providers.html#provider-in-icon-name
821
+ */
373
822
  provider: {
374
823
  type: String
375
824
  },
825
+ /**
826
+ * The name of icon set.
827
+ * Icon default options prefix: simple | normal | detailed
828
+ */
376
829
  prefix: {
377
830
  type: String,
378
831
  default: "normal"
379
832
  },
833
+ /**
834
+ * Url remote SVG icon
835
+ */
380
836
  src: String,
837
+ /**
838
+ * Horizontal flip
839
+ */
381
840
  horizontalFlip: Boolean,
841
+ /**
842
+ * Vertical flip
843
+ */
382
844
  verticalFlip: Boolean,
845
+ /**
846
+ * String alternative to "horizontalFlip" and "verticalFlip".
847
+ * Example: https://docs.iconify.design/icon-components/vue/transform.html
848
+ */
383
849
  flip: String,
850
+ /**
851
+ * Icon render mode
852
+ * 'style' = 'bg' or 'mask', depending on icon content
853
+ * 'bg' = span with style using `background`
854
+ * 'mask' = span with style using `mask`
855
+ * 'svg' = svg
856
+ * Iconify doc: https://docs.iconify.design/iconify-icon/modes.html
857
+ */
384
858
  mode: String,
859
+ /**
860
+ * Toggles inline or block mode
861
+ * Example https://docs.iconify.design/icon-components/vue/inline.html
862
+ */
385
863
  inline: Boolean,
864
+ /**
865
+ * rotates icon
866
+ * Example https://docs.iconify.design/icon-components/vue/transform.html
867
+ */
386
868
  rotate: [Number, String],
869
+ /**
870
+ * A callback that is called when icon data has been loaded
871
+ */
387
872
  onLoad: Function,
873
+ /**
874
+ * SVG icon string
875
+ */
388
876
  svg: String,
877
+ /**
878
+ * Icon modifiers: vv-icon css helper classes, value/s are concatened with prefix 'vv-icon--'
879
+ * @values string | Array<string>
880
+ */
389
881
  modifiers: {
390
882
  type: [String, Array]
391
883
  }
392
- }, Tt = {
884
+ };
885
+ function ol() {
886
+ return We(wl);
887
+ }
888
+ const ta = {
393
889
  name: "VvIcon"
394
- }, G = /* @__PURE__ */ N({
395
- ...Tt,
396
- props: Dt,
397
- setup(o) {
398
- const a = o, e = ref(!0), { modifiers: n } = toRefs(a), s = inject(Je), { bemCssClasses: d } = useBemModifiers("vv-icon", {
399
- modifiers: n
400
- }), r = computed(() => a.provider || (s == null ? void 0 : s.provider)), f = computed(() => {
401
- const l = a.name ?? "", c = `@${r.value}:${a.prefix}:${a.name}`;
402
- return $e(l) ? l : $e(c) ? c : (s == null ? void 0 : s.iconsCollections.find((u) => {
403
- const b = `@${r.value}:${u.prefix}:${l}`;
404
- if ($e(b))
405
- return b;
406
- })) || l;
890
+ }, ee = /* @__PURE__ */ j({
891
+ ...ta,
892
+ props: ea,
893
+ setup(t) {
894
+ const l = t, e = N(!0), s = ol(), { modifiers: o } = G(l), c = X("vv-icon", o), u = n(() => l.provider || (s == null ? void 0 : s.provider)), v = n(() => {
895
+ const r = l.name ?? "", i = `@${u.value}:${l.prefix}:${l.name}`;
896
+ return Ye(r) ? r : Ye(i) ? i : (s == null ? void 0 : s.iconsCollections.find(
897
+ (b) => {
898
+ const _ = `@${u.value}:${b.prefix}:${r}`;
899
+ if (Ye(_))
900
+ return _;
901
+ }
902
+ )) || r;
407
903
  });
408
- function p(l) {
409
- let c = null;
904
+ function d(r) {
905
+ let i = null;
410
906
  if (typeof window > "u") {
411
- const { JSDOM: y } = require("jsdom");
412
- c = new y().window;
907
+ const { JSDOM: A } = require("jsdom");
908
+ i = new A().window;
413
909
  }
414
- return (c ? new c.DOMParser() : new window.DOMParser()).parseFromString(l, "text/html").querySelector("svg");
910
+ return (i ? new i.DOMParser() : new window.DOMParser()).parseFromString(r, "text/html").querySelector("svg");
415
911
  }
416
- function i(l) {
417
- const c = p(l), u = (c == null ? void 0 : c.innerHTML.trim()) || "";
418
- c && u && vt(`@${r.value}:${a.prefix}:${a.name}`, {
419
- body: u,
420
- height: c.viewBox.baseVal.height,
421
- width: c.viewBox.baseVal.width
912
+ function p(r) {
913
+ const i = d(r), b = (i == null ? void 0 : i.innerHTML.trim()) || "";
914
+ i && b && Sl(`@${u.value}:${l.prefix}:${l.name}`, {
915
+ body: b,
916
+ // Set height and width from svg content
917
+ height: i.viewBox.baseVal.height,
918
+ width: i.viewBox.baseVal.width
422
919
  });
423
920
  }
424
- return s && (a.src && !$e(`@${r.value}:${a.prefix}:${a.name}`) ? (e.value = !1, s.fetchIcon(a.src).then((l) => {
425
- l && (i(l), e.value = !0);
426
- }).catch((l) => {
427
- throw new Error(`During fetch icon: ${l == null ? void 0 : l.message}`);
428
- })) : a.svg && i(a.svg)), (l, c) => t(e) ? (m(), D(t(pt), O({
921
+ return s && (l.src && !Ye(`@${u.value}:${l.prefix}:${l.name}`) ? (e.value = !1, s.fetchIcon(l.src).then((r) => {
922
+ r && (p(r), e.value = !0);
923
+ }).catch((r) => {
924
+ throw new Error(`During fetch icon: ${r == null ? void 0 : r.message}`);
925
+ })) : l.svg && p(l.svg)), (r, i) => a(e) ? (f(), H(a(_l), R({
429
926
  key: 0,
430
- class: t(d)
927
+ class: a(c)
431
928
  }, {
432
- inline: l.inline,
433
- width: l.width,
434
- height: l.height,
435
- horizontalFlip: l.horizontalFlip,
436
- verticalFlip: l.verticalFlip,
437
- flip: l.flip,
438
- rotate: l.rotate,
439
- color: l.color,
440
- onLoad: l.onLoad,
441
- icon: t(f)
442
- }), null, 16, ["class"])) : I("", !0);
929
+ inline: r.inline,
930
+ width: r.width,
931
+ height: r.height,
932
+ horizontalFlip: r.horizontalFlip,
933
+ verticalFlip: r.verticalFlip,
934
+ flip: r.flip,
935
+ rotate: r.rotate,
936
+ color: r.color,
937
+ onLoad: r.onLoad,
938
+ icon: a(v)
939
+ }), null, 16, ["class"])) : C("", !0);
443
940
  }
444
- });
445
- var me = /* @__PURE__ */ ((o) => (o.left = "left", o.right = "right", o.top = "top", o.bottom = "bottom", o))(me || {}), Qe = /* @__PURE__ */ ((o) => (o.button = "button", o.submit = "submit", o.reset = "reset", o))(Qe || {}), le = /* @__PURE__ */ ((o) => (o.nuxtLink = "nuxt-link", o.routerLink = "router-link", o.a = "a", o.button = "button", o))(le || {}), Ze = /* @__PURE__ */ ((o) => (o._blank = "_blank", o._self = "_self", o._parent = "_parent", o._top = "_top", o))(Ze || {});
446
- const Lt = ["update:modelValue"], Mt = {
447
- ...re,
448
- ...ce,
449
- ...Pe,
450
- icon: {
451
- type: [String, Object],
452
- default: ""
453
- },
941
+ }), la = ["click", "mouseover", "mouseleave"], aa = al;
942
+ function oa() {
943
+ return We(Yt, {});
944
+ }
945
+ function sa() {
946
+ return We(Jt, {});
947
+ }
948
+ function na() {
949
+ return We(Xt, {});
950
+ }
951
+ const ra = {
952
+ name: "VvAction"
953
+ }, ia = /* @__PURE__ */ j({
954
+ ...ra,
955
+ props: aa,
956
+ emits: la,
957
+ setup(t, { expose: l, emit: e }) {
958
+ const s = t, o = ol(), c = N(null);
959
+ l({ $el: c });
960
+ const {
961
+ reference: u,
962
+ bus: v,
963
+ aria: d,
964
+ expanded: p
965
+ } = oa();
966
+ ve(
967
+ () => c.value,
968
+ (m) => {
969
+ u && (u.value = m);
970
+ }
971
+ );
972
+ const r = n(() => s.pressed || (p == null ? void 0 : p.value)), { role: i } = na(), b = n(() => {
973
+ switch (!0) {
974
+ case s.disabled:
975
+ return ke.button;
976
+ case s.to !== void 0:
977
+ return o != null && o.nuxt ? ke.nuxtLink : ke.routerLink;
978
+ case s.href !== void 0:
979
+ return ke.a;
980
+ default:
981
+ return ke.button;
982
+ }
983
+ }), _ = n(() => {
984
+ const m = {
985
+ ...d == null ? void 0 : d.value,
986
+ "aria-pressed": r.value ? !0 : void 0,
987
+ role: i
988
+ };
989
+ switch (b.value) {
990
+ case ke.a:
991
+ return {
992
+ ...m,
993
+ href: s.href,
994
+ target: s.target,
995
+ rel: s.rel
996
+ };
997
+ case ke.routerLink:
998
+ case ke.nuxtLink:
999
+ return {
1000
+ ...m,
1001
+ to: s.to,
1002
+ target: s.target
1003
+ };
1004
+ default:
1005
+ return {
1006
+ ...m,
1007
+ type: s.type,
1008
+ disabled: s.disabled
1009
+ };
1010
+ }
1011
+ }), k = (m) => {
1012
+ if (s.disabled) {
1013
+ m.preventDefault();
1014
+ return;
1015
+ }
1016
+ v == null || v.emit("click", m), e("click", m);
1017
+ }, A = (m) => {
1018
+ v == null || v.emit("mouseover", m), e("mouseover", m);
1019
+ }, y = (m) => {
1020
+ v == null || v.emit("mouseleave", m), e("mouseleave", m);
1021
+ };
1022
+ return (m, I) => (f(), H(Nt(a(b)), R(a(_), {
1023
+ ref_key: "element",
1024
+ ref: c,
1025
+ class: {
1026
+ active: m.active,
1027
+ pressed: a(r),
1028
+ disabled: m.disabled
1029
+ },
1030
+ onClickPassive: k,
1031
+ onMouseoverPassive: A,
1032
+ onMouseleavePassive: y
1033
+ }), {
1034
+ default: te(() => [
1035
+ V(m.$slots, "default", {}, () => [
1036
+ Y(T(m.label), 1)
1037
+ ])
1038
+ ]),
1039
+ _: 3
1040
+ }, 16, ["class"]));
1041
+ }
1042
+ }), ua = ["update:modelValue"], da = {
1043
+ ...al,
1044
+ ...st,
1045
+ ...me,
1046
+ ...qe,
1047
+ ...at,
1048
+ /**
1049
+ * Button icon
1050
+ */
1051
+ icon: [String, Object],
1052
+ /**
1053
+ * Button icon position
1054
+ */
454
1055
  iconPosition: {
455
1056
  type: String,
456
- default: "left",
457
- validator: (o) => o in me
1057
+ default: fe.left,
1058
+ validator: (t) => Object.values(fe).includes(t)
458
1059
  },
459
- label: [String, Number],
460
- loading: Boolean,
1060
+ /**
1061
+ * Loading icon
1062
+ */
461
1063
  loadingIcon: { type: String, default: "eos-icons:bubble-loading" },
462
- loadingLabel: {
463
- type: String,
464
- default: "Loading..."
465
- },
466
- to: {
467
- type: [String, Object]
468
- },
469
- href: String,
470
- target: {
471
- type: String,
472
- validator: (o) => o in Ze
473
- },
474
- active: Boolean,
475
- pressed: Boolean,
476
- rel: {
477
- type: String,
478
- default: "noopener noreferrer"
479
- },
480
- type: {
481
- type: String,
482
- default: "button",
483
- validator: (o) => o in Qe
484
- },
485
1064
  toggle: {
486
1065
  type: Boolean,
487
1066
  default: !1
488
1067
  },
489
1068
  modelValue: String
490
1069
  };
491
- function Nt(o, a) {
492
- var v;
493
- const { group: e, isInGroup: n, getGroupOrLocalRef: s } = useInjectedGroupState(Ue), {
494
- iconPosition: d,
495
- icon: r,
496
- label: f,
1070
+ function ca(t, l) {
1071
+ var m;
1072
+ const { group: e, isInGroup: s, getGroupOrLocalRef: o } = tt(Ft), {
1073
+ id: c,
1074
+ iconPosition: u,
1075
+ icon: v,
1076
+ label: d,
497
1077
  pressed: p,
498
- modifiers: i
499
- } = toRefs(o), l = s("modelValue", o, a), c = s("disabled", o), u = s("toggle", o), b = s(
1078
+ modifiers: r
1079
+ } = G(t), i = o("modelValue", t, l), b = o("disabled", t), _ = o("toggle", t), k = o(
500
1080
  "unselectable",
501
- o
502
- ), g = ((v = e == null ? void 0 : e.value) == null ? void 0 : v.multiple) ?? ref(!1), y = computed(() => {
503
- var $;
504
- const V = i != null && i.value ? Array.isArray(i.value) ? i.value : [i.value] : [], w = ($ = e == null ? void 0 : e.value.itemModifiers) != null && $.value ? Array.isArray(e.value.itemModifiers.value) ? e.value.itemModifiers.value : [e.value.itemModifiers.value] : [];
505
- return [...V, ...w];
1081
+ t
1082
+ ), A = ((m = e == null ? void 0 : e.value) == null ? void 0 : m.multiple) ?? N(!1), y = n(() => {
1083
+ var D;
1084
+ const I = r != null && r.value ? Array.isArray(r.value) ? r.value : r.value.split(" ") : [], O = (D = e == null ? void 0 : e.value.itemModifiers) != null && D.value ? Array.isArray(e.value.itemModifiers.value) ? e.value.itemModifiers.value : e.value.itemModifiers.value.split(" ") : [];
1085
+ return [...I, ...O];
506
1086
  });
507
1087
  return {
1088
+ // group props
508
1089
  group: e,
509
- isInGroup: n,
510
- modelValue: l,
511
- disabled: c,
512
- toggle: u,
513
- unselectable: b,
514
- multiple: g,
1090
+ isInGroup: s,
1091
+ modelValue: i,
1092
+ disabled: b,
1093
+ toggle: _,
1094
+ unselectable: k,
1095
+ multiple: A,
1096
+ // local props
1097
+ id: c,
515
1098
  modifiers: y,
516
1099
  pressed: p,
517
- iconPosition: d,
518
- icon: r,
519
- label: f
1100
+ iconPosition: u,
1101
+ icon: v,
1102
+ label: d
520
1103
  };
521
1104
  }
522
- const Ht = {
1105
+ const Le = (t) => n(() => String((t == null ? void 0 : t.value) || Mt())), va = {
523
1106
  key: 1,
524
1107
  class: "vv-button__label"
525
- }, Gt = {
1108
+ }, fa = {
526
1109
  key: 1,
527
1110
  class: "vv-button__label"
528
- }, xt = {
1111
+ }, pa = {
529
1112
  name: "VvButton"
530
- }, Vs = /* @__PURE__ */ N({
531
- ...xt,
532
- props: Mt,
533
- emits: Lt,
534
- setup(o, { emit: a }) {
535
- const e = o, n = useAttrs(), s = useSlots(), d = (n == null ? void 0 : n.name) || ne(), {
536
- modifiers: r,
537
- iconPosition: f,
1113
+ }, vs = /* @__PURE__ */ j({
1114
+ ...pa,
1115
+ props: da,
1116
+ emits: ua,
1117
+ setup(t, { expose: l, emit: e }) {
1118
+ const s = t, o = yt(), c = Ae(), {
1119
+ id: u,
1120
+ modifiers: v,
1121
+ iconPosition: d,
538
1122
  icon: p,
539
- label: i,
540
- modelValue: l,
541
- disabled: c,
542
- toggle: u,
543
- unselectable: b
544
- } = Nt(e, a), g = inject(Je), y = computed(() => {
545
- switch (!0) {
546
- case c.value:
547
- return le.button;
548
- case e.to !== void 0:
549
- return g != null && g.nuxt ? le.nuxtLink : le.routerLink;
550
- case e.href !== void 0:
551
- return le.a;
552
- default:
553
- return le.button;
554
- }
555
- }), v = computed(() => u.value ? Array.isArray(l.value) ? contains(d, l.value) : equals(d, l.value) : e.pressed), { bemCssClasses: V } = useBemModifiers("vv-button", {
556
- modifiers: r,
557
- active: e.active,
558
- pressed: v,
559
- disabled: c,
560
- reverse: computed(
561
- () => [me.right, me.bottom].includes(
562
- f.value
563
- )
564
- ),
565
- column: computed(
566
- () => [me.top, me.bottom].includes(
567
- f.value
1123
+ label: r,
1124
+ modelValue: i,
1125
+ disabled: b,
1126
+ toggle: _,
1127
+ unselectable: k
1128
+ } = ca(s, e), A = Le(u), y = n(() => (o == null ? void 0 : o.name) || A.value), m = N(null), I = n(() => {
1129
+ var w;
1130
+ return (w = m.value) == null ? void 0 : w.$el;
1131
+ });
1132
+ l({ $el: I });
1133
+ const O = n(() => _.value ? Array.isArray(i.value) ? Ce(y.value, i.value) : Pe(y.value, i.value) : s.pressed), D = X(
1134
+ "vv-button",
1135
+ v,
1136
+ n(() => ({
1137
+ reverse: [fe.right, fe.bottom].includes(d.value),
1138
+ column: [fe.top, fe.bottom].includes(d.value),
1139
+ "icon-only": Boolean(
1140
+ (p == null ? void 0 : p.value) && !(r != null && r.value) && !c.default
568
1141
  )
569
- ),
570
- iconOnly: computed(
571
- () => (p == null ? void 0 : p.value) && !(i != null && i.value) && !s.default
572
- )
573
- }), w = computed(
1142
+ }))
1143
+ ), L = n(
574
1144
  () => typeof (p == null ? void 0 : p.value) == "string" ? { name: p == null ? void 0 : p.value } : p == null ? void 0 : p.value
575
- ), $ = computed(() => {
576
- const C = {
577
- class: V.value,
578
- "aria-pressed": v.value ? !0 : void 0
579
- };
580
- switch (y.value) {
581
- case le.a:
582
- return {
583
- ...C,
584
- role: "button",
585
- href: e.href,
586
- target: e.target,
587
- rel: e.rel
588
- };
589
- case le.routerLink:
590
- case le.nuxtLink:
591
- return {
592
- ...C,
593
- role: "button",
594
- to: e.to,
595
- target: e.target
596
- };
597
- default:
598
- return {
599
- ...C,
600
- type: e.type,
601
- disabled: c.value
602
- };
603
- }
604
- }), M = () => {
605
- if (u.value) {
606
- if (Array.isArray(l.value)) {
607
- if (contains(d, l.value)) {
608
- b.value && (l.value = l.value.filter(
609
- (C) => C !== d
1145
+ ), x = () => {
1146
+ if (_.value) {
1147
+ if (Array.isArray(i.value)) {
1148
+ if (Ce(y.value, i.value)) {
1149
+ k.value && (i.value = i.value.filter(
1150
+ (w) => w !== y.value
610
1151
  ));
611
1152
  return;
612
1153
  }
613
- l.value.push(d);
1154
+ i.value.push(y.value);
614
1155
  return;
615
1156
  }
616
- if (equals(d, l.value) && b.value) {
617
- l.value = void 0;
1157
+ if (Pe(y.value, i.value) && k.value) {
1158
+ i.value = void 0;
618
1159
  return;
619
1160
  }
620
- l.value = d;
1161
+ i.value = y.value;
621
1162
  }
622
1163
  };
623
- return (C, H) => (m(), D(Ge(t(y)), O(t($), { onClickPassive: M }), {
624
- default: he(() => [
625
- k(C.$slots, "default", {}, () => [
626
- C.loading ? k(C.$slots, "loading", { key: 0 }, () => [
627
- C.loadingIcon ? (m(), D(G, {
1164
+ return (w, se) => (f(), H(ia, R({
1165
+ disabled: a(b),
1166
+ pressed: a(O),
1167
+ active: w.active,
1168
+ type: w.type,
1169
+ to: w.to,
1170
+ href: w.href,
1171
+ target: w.target,
1172
+ rel: w.rel
1173
+ }, {
1174
+ id: a(A),
1175
+ ref_key: "element",
1176
+ ref: m,
1177
+ class: a(D),
1178
+ onClick: x
1179
+ }), {
1180
+ default: te(() => [
1181
+ V(w.$slots, "default", {}, () => [
1182
+ w.loading ? V(w.$slots, "loading", { key: 0 }, () => [
1183
+ w.loadingIcon ? (f(), H(ee, {
628
1184
  key: 0,
629
1185
  class: "vv-button__loading-icon",
630
- name: C.loadingIcon
631
- }, null, 8, ["name"])) : I("", !0),
632
- C.loadingLabel ? (m(), _("span", Ht, B(C.loadingLabel), 1)) : I("", !0)
633
- ]) : (m(), _(de, { key: 1 }, [
634
- k(C.$slots, "before"),
635
- t(p) ? (m(), D(G, O({
1186
+ name: w.loadingIcon
1187
+ }, null, 8, ["name"])) : C("", !0),
1188
+ w.loadingLabel ? (f(), g("span", va, T(w.loadingLabel), 1)) : C("", !0)
1189
+ ]) : (f(), g(ie, { key: 1 }, [
1190
+ V(w.$slots, "before"),
1191
+ a(p) ? (f(), H(ee, R({
636
1192
  key: 0,
637
1193
  class: "vv-button__icon"
638
- }, t(w)), null, 16)) : I("", !0),
639
- t(i) ? (m(), _("span", Gt, [
640
- k(C.$slots, "label", {}, () => [
641
- q(B(t(i)), 1)
1194
+ }, a(L)), null, 16)) : C("", !0),
1195
+ a(r) ? (f(), g("span", fa, [
1196
+ V(w.$slots, "label", {}, () => [
1197
+ Y(T(a(r)), 1)
642
1198
  ])
643
- ])) : I("", !0),
644
- k(C.$slots, "after")
1199
+ ])) : C("", !0),
1200
+ V(w.$slots, "after")
645
1201
  ], 64))
646
1202
  ])
647
1203
  ]),
648
1204
  _: 3
649
- }, 16));
1205
+ }, 16, ["id", "class"]));
650
1206
  }
651
- }), Ut = {
652
- ...re,
653
- ...ce,
654
- ...Pe,
1207
+ }), ma = {
1208
+ ...me,
1209
+ ...De,
1210
+ ...qe,
1211
+ /**
1212
+ * String or String[] of css classes (modifiers) that will be provided to each button'
1213
+ */
655
1214
  itemModifiers: { type: [String, Array], default: void 0 },
656
1215
  toggle: { type: Boolean, default: !1 },
657
1216
  multiple: { type: Boolean, default: !1 },
658
1217
  modelValue: { type: [String, Array], default: void 0 }
659
- }, Ft = ["update:modelValue"], Kt = {
1218
+ }, ba = ["update:modelValue"], ha = {
660
1219
  name: "VvButtonGroup"
661
- }, $s = /* @__PURE__ */ N({
662
- ...Kt,
663
- props: Ut,
664
- emits: Ft,
665
- setup(o, { emit: a }) {
666
- const e = o, {
667
- disabled: n,
668
- toggle: s,
669
- modifiers: d,
670
- multiple: r,
671
- unselectable: f,
672
- itemModifiers: p
673
- } = toRefs(e);
674
- watchEffect(() => {
675
- typeof e.modelValue == "string" && r.value && console.warn(
1220
+ }, fs = /* @__PURE__ */ j({
1221
+ ...ha,
1222
+ props: ma,
1223
+ emits: ba,
1224
+ setup(t, { emit: l }) {
1225
+ const e = t, {
1226
+ disabled: s,
1227
+ toggle: o,
1228
+ modifiers: c,
1229
+ multiple: u,
1230
+ unselectable: v,
1231
+ itemModifiers: d
1232
+ } = G(e);
1233
+ _t(() => {
1234
+ typeof e.modelValue == "string" && u.value && console.warn(
676
1235
  "[VvButtonGroup]: modelValue is a string but multiple is true."
677
1236
  );
678
1237
  });
679
- const i = computed({
680
- get: () => r.value ? e.modelValue : Array.isArray(e.modelValue) ? e.modelValue[0] : e.modelValue,
681
- set: (u) => (u !== void 0 && (Array.isArray(e.modelValue) || r.value) && !Array.isArray(u) && (u = [u]), a("update:modelValue", u))
682
- }), l = {
683
- key: Ue,
684
- modelValue: i,
685
- disabled: n,
686
- toggle: s,
687
- multiple: r,
688
- unselectable: f,
689
- itemModifiers: p
690
- };
691
- useProvideGroupState(l);
692
- const { bemCssClasses: c } = useBemModifiers("vv-button-group", {
693
- modifiers: d
1238
+ const p = n({
1239
+ get: () => u.value ? e.modelValue : Array.isArray(e.modelValue) ? e.modelValue[0] : e.modelValue,
1240
+ set: (i) => (i !== void 0 && (Array.isArray(e.modelValue) || u.value) && !Array.isArray(i) && (i = [i]), l("update:modelValue", i))
1241
+ });
1242
+ lt({
1243
+ key: Ft,
1244
+ modelValue: p,
1245
+ disabled: s,
1246
+ toggle: o,
1247
+ multiple: u,
1248
+ unselectable: v,
1249
+ itemModifiers: d
694
1250
  });
695
- return (u, b) => (m(), _("div", {
696
- class: U(t(c)),
1251
+ const r = X("vv-button-group", c);
1252
+ return (i, b) => (f(), g("div", {
1253
+ class: le(a(r)),
697
1254
  role: "group"
698
1255
  }, [
699
- k(u.$slots, "default")
1256
+ V(i.$slots, "default")
700
1257
  ], 2));
701
1258
  }
702
- }), Wt = {
1259
+ }), ya = {
703
1260
  title: String,
704
1261
  modifiers: [String, Array]
705
- }, qt = {
1262
+ }, ga = {
706
1263
  key: 0,
707
1264
  class: "vv-card__header"
708
- }, jt = {
1265
+ }, _a = {
709
1266
  key: 1,
710
1267
  class: "vv-card__content"
711
- }, zt = {
1268
+ }, Sa = {
712
1269
  key: 2,
713
1270
  class: "vv-card__footer"
714
- }, Xt = {
1271
+ }, Va = {
715
1272
  name: "VvCard"
716
- }, Cs = /* @__PURE__ */ N({
717
- ...Xt,
718
- props: Wt,
719
- setup(o) {
720
- const a = o, { bemCssClasses: e } = useBemModifiers("vv-card", {
721
- modifiers: a.modifiers
722
- });
723
- return (n, s) => (m(), _("article", {
724
- class: U(t(e))
1273
+ }, ps = /* @__PURE__ */ j({
1274
+ ...Va,
1275
+ props: ya,
1276
+ setup(t) {
1277
+ const l = t, { modifiers: e } = G(l), s = X("vv-card", e);
1278
+ return (o, c) => (f(), g("article", {
1279
+ class: le(a(s))
725
1280
  }, [
726
- n.$slots.header || n.title ? (m(), _("header", qt, [
727
- k(n.$slots, "header", {}, () => [
728
- q(B(n.title), 1)
1281
+ o.$slots.header || o.title ? (f(), g("header", ga, [
1282
+ V(o.$slots, "header", {}, () => [
1283
+ Y(T(o.title), 1)
729
1284
  ])
730
- ])) : I("", !0),
731
- k(n.$slots, "default"),
732
- n.$slots.content ? (m(), _("div", jt, [
733
- k(n.$slots, "content")
734
- ])) : I("", !0),
735
- n.$slots.footer ? (m(), _("footer", zt, [
736
- k(n.$slots, "footer")
737
- ])) : I("", !0)
1285
+ ])) : C("", !0),
1286
+ V(o.$slots, "default"),
1287
+ o.$slots.content ? (f(), g("div", _a, [
1288
+ V(o.$slots, "content")
1289
+ ])) : C("", !0),
1290
+ o.$slots.footer ? (f(), g("footer", Sa, [
1291
+ V(o.$slots, "footer")
1292
+ ])) : C("", !0)
738
1293
  ], 2));
739
1294
  }
740
- }), Yt = {
741
- ...Xe,
1295
+ }), $a = {
1296
+ ...tl,
1297
+ ...me,
1298
+ /**
1299
+ * If true, the input will be indeterminated
1300
+ */
742
1301
  indeterminate: Boolean,
1302
+ /**
1303
+ * Value associated with the unchecked state
1304
+ */
743
1305
  uncheckedValue: [String, Number, Boolean],
1306
+ /**
1307
+ * If true, the input will be displayed as a switch
1308
+ */
744
1309
  switch: Boolean
745
- }, Jt = ["click", "update:modelValue", "change", "blur"];
746
- function Qt(o, a) {
747
- const { group: e, isInGroup: n, getGroupOrLocalRef: s } = useInjectedGroupState(Ke), { switch: d, indeterminate: r } = toRefs(o), f = s("modelValue", o, a), p = s("readonly", o), i = s("disabled", o), l = s("valid", o), c = s("invalid", o);
1310
+ }, ka = ["click", "update:modelValue", "change", "blur"];
1311
+ function Aa(t, l) {
1312
+ const { group: e, isInGroup: s, getGroupOrLocalRef: o } = tt(zt), { id: c, switch: u, indeterminate: v } = G(t), d = o("modelValue", t, l), p = o("readonly", t), r = o("disabled", t), i = o("valid", t), b = o("invalid", t);
748
1313
  return {
749
- propsSwitch: d,
750
- indeterminate: r,
1314
+ // local props
1315
+ id: c,
1316
+ propsSwitch: u,
1317
+ indeterminate: v,
1318
+ // global props
751
1319
  group: e,
752
- isInGroup: n,
753
- modelValue: f,
1320
+ isInGroup: s,
1321
+ modelValue: d,
754
1322
  readonly: p,
755
- disabled: i,
756
- valid: l,
757
- invalid: c
1323
+ disabled: r,
1324
+ valid: i,
1325
+ invalid: b
758
1326
  };
759
1327
  }
760
- function Ce(o) {
761
- return Array.isArray(o) ? o.filter((a) => isString(a)).join(" ") : o;
1328
+ function Je(t) {
1329
+ return Array.isArray(t) ? t.filter((l) => El(l)).join(" ") : t;
762
1330
  }
763
- function pe(o, a) {
1331
+ function Be(t, l) {
764
1332
  const {
765
1333
  invalid: e,
766
- valid: n,
767
- hint: s,
768
- loading: d
769
- } = a, {
770
- hintLabel: r,
771
- modelValue: f,
772
- valid: p,
773
- validLabel: i,
774
- invalid: l,
775
- invalidLabel: c,
776
- ...u
777
- } = toRefs(o), b = resolveFieldData(u, "loading"), g = resolveFieldData(u, "loadingLabel"), y = computed(() => l.value ? !!(l.value && e || c != null && c.value && Array.isArray(c.value) && c.value.length > 0 || c != null && c.value && !isEmpty(c)) : !1), v = computed(
778
- () => !!(r && r.value || s)
779
- ), V = computed(
780
- () => !!(i && i.value || n)
781
- ), w = computed(
782
- () => !!(b != null && b.value && d || b != null && b.value && (g != null && g.value))
783
- ), $ = computed(
784
- () => v.value || V.value || y.value || w.value
1334
+ valid: s,
1335
+ hint: o,
1336
+ loading: c
1337
+ } = l, {
1338
+ hintLabel: u,
1339
+ modelValue: v,
1340
+ valid: d,
1341
+ validLabel: p,
1342
+ invalid: r,
1343
+ invalidLabel: i,
1344
+ ...b
1345
+ } = G(t), _ = Ze(b, "loading"), k = Ze(b, "loadingLabel"), A = n(() => r.value ? !!(r.value && e || i != null && i.value && Array.isArray(i.value) && i.value.length > 0 || i != null && i.value && !ge(i)) : !1), y = n(
1346
+ () => !!(u && u.value || o)
1347
+ ), m = n(
1348
+ () => !!(p && p.value || s)
1349
+ ), I = n(
1350
+ () => !!(_ != null && _.value && c || _ != null && _.value && (k != null && k.value))
1351
+ ), O = n(
1352
+ () => y.value || m.value || A.value || I.value
785
1353
  );
786
1354
  return {
787
- hasInvalid: y,
788
- hasHint: v,
789
- hasValid: V,
790
- hasLoading: w,
1355
+ hasInvalid: A,
1356
+ hasHint: y,
1357
+ hasValid: m,
1358
+ hasLoading: I,
791
1359
  HintSlot: {
792
1360
  name: "HintSlot",
793
1361
  props: {
@@ -796,34 +1364,34 @@ function pe(o, a) {
796
1364
  default: () => ({})
797
1365
  }
798
1366
  },
799
- setup(M) {
800
- const C = computed(() => {
801
- const H = toReactive({
802
- hintLabel: r,
803
- modelValue: f,
804
- valid: p,
805
- validLabel: i,
806
- invalid: l,
807
- invalidLabel: c,
808
- loading: b,
809
- loadingLabel: g,
810
- ...M.params
1367
+ setup(D) {
1368
+ const L = n(() => {
1369
+ const x = hl({
1370
+ hintLabel: u,
1371
+ modelValue: v,
1372
+ valid: d,
1373
+ validLabel: p,
1374
+ invalid: r,
1375
+ invalidLabel: i,
1376
+ loading: _,
1377
+ loadingLabel: k,
1378
+ ...D.params
811
1379
  });
812
- return l != null && l.value ? (e == null ? void 0 : e(H)) || Ce(c == null ? void 0 : c.value) || (r == null ? void 0 : r.value) : p != null && p.value ? (n == null ? void 0 : n(H)) || Ce(i == null ? void 0 : i.value) || (r == null ? void 0 : r.value) : b != null && b.value ? (d == null ? void 0 : d(H)) || Ce(g == null ? void 0 : g.value) || (r == null ? void 0 : r.value) : (s == null ? void 0 : s(H)) || Ce(r == null ? void 0 : r.value) || (r == null ? void 0 : r.value);
1380
+ return r != null && r.value ? (e == null ? void 0 : e(x)) || Je(i == null ? void 0 : i.value) || (u == null ? void 0 : u.value) : d != null && d.value ? (s == null ? void 0 : s(x)) || Je(p == null ? void 0 : p.value) || (u == null ? void 0 : u.value) : _ != null && _.value ? (c == null ? void 0 : c(x)) || Je(k == null ? void 0 : k.value) || (u == null ? void 0 : u.value) : (o == null ? void 0 : o(x)) || Je(u == null ? void 0 : u.value) || (u == null ? void 0 : u.value);
813
1381
  });
814
1382
  return {
815
- isVisible: $,
816
- hasInvalid: y,
817
- hasValid: V,
818
- hintContent: C
1383
+ isVisible: O,
1384
+ hasInvalid: A,
1385
+ hasValid: m,
1386
+ hintContent: L
819
1387
  };
820
1388
  },
821
1389
  render() {
822
1390
  if (this.isVisible)
823
- return h(
1391
+ return be(
824
1392
  "small",
825
1393
  {
826
- role: this.hasInvalid || this.hasValid ? "alert" : void 0
1394
+ role: this.hasInvalid ? "alert" : this.hasValid ? "status" : void 0
827
1395
  },
828
1396
  this.hintContent
829
1397
  );
@@ -831,474 +1399,977 @@ function pe(o, a) {
831
1399
  }
832
1400
  };
833
1401
  }
834
- const Zt = ["for"], eo = ["id", "name", "disabled", "value", "tabindex", "aria-invalid"], to = {
1402
+ const wa = ["for"], Ca = ["id", "name", "disabled", "value", "tabindex", "aria-invalid"], Ia = {
835
1403
  name: "VvCheckbox"
836
- }, oo = /* @__PURE__ */ N({
837
- ...to,
838
- props: Yt,
839
- emits: Jt,
840
- setup(o, { emit: a }) {
841
- const e = o, n = useSlots(), {
842
- disabled: s,
843
- readonly: d,
844
- valid: r,
845
- invalid: f,
1404
+ }, Ea = /* @__PURE__ */ j({
1405
+ ...Ia,
1406
+ props: $a,
1407
+ emits: ka,
1408
+ setup(t, { emit: l }) {
1409
+ const e = t, s = Ae(), {
1410
+ id: o,
1411
+ disabled: c,
1412
+ readonly: u,
1413
+ valid: v,
1414
+ invalid: d,
846
1415
  propsSwitch: p,
847
- modelValue: i,
848
- indeterminate: l,
849
- isInGroup: c
850
- } = Qt(e, a), u = computed(() => String(e.id || ne())), b = computed(() => v.value ? -1 : e.tabindex), g = ref(), y = computed(
851
- () => e.uncheckedValue !== void 0 && !c.value
852
- ), v = computed(() => s.value || d.value), V = computed(() => {
853
- if (f.value === !0)
1416
+ modelValue: r,
1417
+ indeterminate: i,
1418
+ isInGroup: b
1419
+ } = Aa(e, l), _ = Le(o), k = n(() => m.value ? -1 : e.tabindex), A = N(), y = n(
1420
+ () => e.uncheckedValue !== void 0 && !b.value
1421
+ ), m = n(() => c.value || u.value), I = n(() => {
1422
+ if (d.value === !0)
854
1423
  return !0;
855
- if (r.value === !0)
1424
+ if (v.value === !0)
856
1425
  return !1;
857
- }), w = computed(() => y.value ? i.value === e.value : Array.isArray(i.value) ? contains(e.value, i.value) : equals(e.value, i.value)), $ = computed(() => !!(l.value || !w.value && y.value && e.uncheckedValue !== i.value)), M = computed(() => {
1426
+ }), O = n(() => y.value ? r.value === e.value : Array.isArray(r.value) ? Ce(e.value, r.value) : Pe(e.value, r.value)), D = n(() => !!(i.value || !O.value && y.value && e.uncheckedValue !== r.value)), L = n(() => {
858
1427
  if (!y.value)
859
1428
  return ["string", "number", "boolean"].includes(typeof e.value) ? e.value : !0;
860
- }), C = computed({
1429
+ }), x = n({
861
1430
  get() {
862
- return w.value;
1431
+ return O.value;
863
1432
  },
864
- set(T) {
1433
+ set(W) {
865
1434
  if (y.value)
866
- i.value = T ? e.value : e.uncheckedValue;
867
- else if (Array.isArray(i.value) || c.value) {
868
- const x = new Set(
869
- Array.isArray(i.value) ? i.value : i.value !== void 0 ? [i.value] : []
1435
+ r.value = W ? e.value : e.uncheckedValue;
1436
+ else if (Array.isArray(r.value) || b.value) {
1437
+ const F = new Set(
1438
+ Array.isArray(r.value) ? r.value : r.value !== void 0 ? [r.value] : []
870
1439
  );
871
- T ? x.add(e.value) : x.delete(e.value), i.value = [...x];
1440
+ W ? F.add(e.value) : F.delete(e.value), r.value = [...F];
872
1441
  } else
873
- i.value = T ? e.value : void 0;
874
- a("change", T);
1442
+ r.value = W ? e.value : void 0;
1443
+ l("change", W);
875
1444
  }
876
- }), { bemCssClasses: H } = useBemModifiers("vv-checkbox", {
877
- switch: p,
878
- valid: r,
879
- invalid: f,
880
- disabled: s,
881
- readonly: d,
882
- indeterminate: l
883
- });
884
- watchEffect(() => {
885
- y.value && Array.isArray(i.value) && console.warn(
1445
+ }), { modifiers: w } = G(e), se = X(
1446
+ "vv-checkbox",
1447
+ w,
1448
+ n(() => ({
1449
+ switch: p.value,
1450
+ valid: v.value,
1451
+ invalid: d.value,
1452
+ disabled: c.value,
1453
+ readonly: u.value,
1454
+ indeterminate: i.value
1455
+ }))
1456
+ );
1457
+ _t(() => {
1458
+ y.value && Array.isArray(r.value) && console.warn(
886
1459
  "[VvCheckbox] The model value is an array but the component is in binary mode."
887
1460
  );
888
- }), watch(
889
- () => $.value,
890
- (T) => {
891
- T ? g.value.indeterminate = !0 : g.value.indeterminate = !1;
1461
+ }), ve(
1462
+ () => D.value,
1463
+ (W) => {
1464
+ W ? A.value.indeterminate = !0 : A.value.indeterminate = !1;
892
1465
  }
893
- ), onMounted(() => {
894
- $.value && (g.value.indeterminate = !0);
1466
+ ), ul(() => {
1467
+ D.value && (A.value.indeterminate = !0);
895
1468
  });
896
- const { HintSlot: X } = pe(e, n);
897
- return (T, x) => (m(), _("label", {
898
- class: U(t(H)),
899
- for: t(u)
1469
+ const { HintSlot: P } = Be(e, s);
1470
+ return (W, F) => (f(), g("label", {
1471
+ class: le(a(se)),
1472
+ for: a(_)
900
1473
  }, [
901
- ve(R("input", {
902
- id: t(u),
1474
+ Oe(M("input", {
1475
+ id: a(_),
903
1476
  ref_key: "input",
904
- ref: g,
905
- "onUpdate:modelValue": x[0] || (x[0] = (J) => be(C) ? C.value = J : null),
1477
+ ref: A,
1478
+ "onUpdate:modelValue": F[0] || (F[0] = (ue) => Ee(x) ? x.value = ue : null),
906
1479
  type: "checkbox",
907
1480
  class: "vv-checkbox__input",
908
- name: T.name,
909
- disabled: t(v),
910
- value: t(M),
911
- tabindex: t(b),
912
- "aria-invalid": t(V)
913
- }, null, 8, eo), [
914
- [lt, t(C)]
1481
+ name: W.name,
1482
+ disabled: a(m),
1483
+ value: a(L),
1484
+ tabindex: a(k),
1485
+ "aria-invalid": a(I)
1486
+ }, null, 8, Ca), [
1487
+ [dl, a(x)]
915
1488
  ]),
916
- k(T.$slots, "default", { value: t(i) }, () => [
917
- q(B(T.label), 1)
1489
+ V(W.$slots, "default", { value: a(r) }, () => [
1490
+ Y(T(W.label), 1)
918
1491
  ]),
919
- Z(t(X), {
1492
+ pe(a(P), {
920
1493
  class: "vv-checkbox__hint",
921
- params: { value: t(i) }
1494
+ params: { value: a(r) }
922
1495
  }, null, 8, ["params"])
923
- ], 10, Zt));
1496
+ ], 10, wa));
924
1497
  }
925
- }), so = Ye, ao = ["update:modelValue", "change"], lo = ["textContent"], no = { class: "vv-checkbox-group__wrapper" }, ro = {
1498
+ }), Pa = ll, Oa = ["update:modelValue", "change"];
1499
+ function rt(t) {
1500
+ const { options: l, labelKey: e, valueKey: s, disabledKey: o } = G(t);
1501
+ return {
1502
+ options: l,
1503
+ getOptionLabel: (d) => typeof d != "object" && d !== null ? d : typeof e.value == "function" ? e.value(d) : d[e.value],
1504
+ getOptionValue: (d) => typeof d != "object" && d !== null ? d : typeof s.value == "function" ? s.value(d) : d[s.value],
1505
+ getOptionDisabled: (d) => typeof d != "object" && d !== null ? !1 : typeof o.value == "function" ? o.value(d) : d[o.value]
1506
+ };
1507
+ }
1508
+ const Da = ["textContent"], La = { class: "vv-checkbox-group__wrapper" }, Ba = {
926
1509
  name: "VvCheckboxGroup"
927
- }, ks = /* @__PURE__ */ N({
928
- ...ro,
929
- props: so,
930
- emits: ao,
931
- setup(o, { emit: a }) {
932
- const e = o, n = useSlots(), s = useVModel(e, "modelValue", a), { disabled: d, readonly: r, vertical: f, valid: p, invalid: i } = toRefs(e), l = {
933
- key: Ke,
934
- modelValue: s,
935
- disabled: d,
936
- readonly: r,
937
- valid: p,
938
- invalid: i
939
- };
940
- useProvideGroupState(l);
941
- const { getOptionLabel: c, getOptionValue: u } = useOptions(e), { bemCssClasses: b } = useBemModifiers("vv-checkbox-group", {
942
- disabled: d,
943
- readonly: r,
944
- horizontal: computed(() => !f.value),
945
- valid: p,
946
- invalid: i
947
- }), g = (v, V) => ({
948
- id: `${e.name}_opt${V}`,
1510
+ }, ms = /* @__PURE__ */ j({
1511
+ ...Ba,
1512
+ props: Pa,
1513
+ emits: Oa,
1514
+ setup(t, { emit: l }) {
1515
+ const e = t, s = Ae(), o = et(e, "modelValue", l), { disabled: c, readonly: u, vertical: v, valid: d, invalid: p, modifiers: r } = G(e);
1516
+ lt({
1517
+ key: zt,
1518
+ modelValue: o,
1519
+ disabled: c,
1520
+ readonly: u,
1521
+ valid: d,
1522
+ invalid: p
1523
+ });
1524
+ const { getOptionLabel: i, getOptionValue: b } = rt(e), _ = X(
1525
+ "vv-checkbox-group",
1526
+ r,
1527
+ n(() => ({
1528
+ disabled: c.value,
1529
+ readonly: u.value,
1530
+ horizontal: !v.value,
1531
+ valid: d.value,
1532
+ invalid: p.value
1533
+ }))
1534
+ ), k = (y, m) => ({
1535
+ id: `${e.name}_opt${m}`,
949
1536
  name: e.name,
950
- label: c(v),
951
- value: u(v)
952
- }), { HintSlot: y } = pe(e, n);
953
- return (v, V) => (m(), _("fieldset", {
954
- class: U(t(b))
1537
+ label: i(y),
1538
+ value: b(y)
1539
+ }), { HintSlot: A } = Be(e, s);
1540
+ return (y, m) => (f(), g("fieldset", {
1541
+ class: le(a(_))
955
1542
  }, [
956
- v.label ? (m(), _("legend", {
1543
+ y.label ? (f(), g("legend", {
957
1544
  key: 0,
958
- textContent: B(v.label)
959
- }, null, 8, lo)) : I("", !0),
960
- R("div", no, [
961
- v.options.length > 0 ? (m(!0), _(de, { key: 0 }, fe(v.options, (w, $) => (m(), D(oo, O({ key: $ }, g(w, $)), null, 16))), 128)) : k(v.$slots, "default", { key: 1 })
1545
+ textContent: T(y.label)
1546
+ }, null, 8, Da)) : C("", !0),
1547
+ M("div", La, [
1548
+ y.options.length > 0 ? (f(!0), g(ie, { key: 0 }, Ne(y.options, (I, O) => (f(), H(Ea, R({ key: O }, k(I, O)), null, 16))), 128)) : V(y.$slots, "default", { key: 1 })
962
1549
  ]),
963
- Z(t(y), { class: "vv-checkbox-group__hint" })
1550
+ pe(a(A), { class: "vv-checkbox-group__hint" })
964
1551
  ], 2));
965
1552
  }
966
- }), io = {
967
- ...Ve,
968
- ...ke,
969
- ...ce,
970
- ...re,
1553
+ }), Ta = [
1554
+ "update:modelValue",
1555
+ "change:search",
1556
+ "focus",
1557
+ "blur"
1558
+ ], Na = {
1559
+ ...nt,
1560
+ ...ot,
1561
+ ...Ue,
1562
+ ...Fe,
1563
+ ...ze,
1564
+ ...at,
1565
+ ...De,
1566
+ ...Ke,
1567
+ ...me,
1568
+ ...kt,
1569
+ ...At,
1570
+ ...wt,
1571
+ ...qe,
1572
+ ...ht,
1573
+ ...Me,
1574
+ /**
1575
+ * modelValue can be a string, number, boolean, object or array of string, number, boolean, object
1576
+ */
971
1577
  modelValue: {
972
- type: [String, Number, Boolean, Object, Array]
1578
+ type: [String, Number, Boolean, Object, Array],
1579
+ default: void 0
1580
+ },
1581
+ /**
1582
+ * Label for no search results
1583
+ */
1584
+ noResultsLabel: { type: String, default: "No results" },
1585
+ /**
1586
+ * Label for no options available
1587
+ */
1588
+ noOptionsLabel: { type: String, default: "No options available" },
1589
+ /**
1590
+ * Label for selected option hint
1591
+ */
1592
+ selectedHintLabel: { type: String, default: "Selected" },
1593
+ /**
1594
+ * Label for deselect action button
1595
+ */
1596
+ deselectActionLabel: { type: String, default: "Deselect" },
1597
+ /**
1598
+ * Label for select option hint
1599
+ */
1600
+ selectHintLabel: { type: String, default: "Press enter to select" },
1601
+ /**
1602
+ * Label for deselected option hint
1603
+ */
1604
+ deselectHintLabel: { type: String, default: "Press enter to remove" },
1605
+ /**
1606
+ * Select input placeholder
1607
+ */
1608
+ placeholder: String,
1609
+ /**
1610
+ * Use input text to search on options
1611
+ */
1612
+ searchable: Boolean,
1613
+ /**
1614
+ * On searchable select is the input search placeholder
1615
+ */
1616
+ searchPlaceholder: {
1617
+ type: String,
1618
+ default: "Search..."
1619
+ },
1620
+ /**
1621
+ * The input search debounce time in ms
1622
+ */
1623
+ debounceSearch: {
1624
+ type: [Number, String],
1625
+ default: 0
973
1626
  },
974
- labelNoResults: { type: String, default: "No results" },
1627
+ /**
1628
+ * Manage modelValue as string[] or object[]
1629
+ */
975
1630
  multiple: Boolean,
1631
+ /**
1632
+ * The max number of selected values
1633
+ */
976
1634
  maxValues: [Number, String],
977
- unselectable: { type: Boolean, default: !0 }
978
- }, uo = ["id"], co = {
979
- key: 0,
980
- role: "option"
981
- }, po = ["aria-selected"], vo = ["for", "onClick"], mo = ["id", "type", "value", "checked", "disabled", "name"], fo = {
982
- name: "VvDropdown"
983
- }, bo = /* @__PURE__ */ N({
984
- ...fo,
985
- props: io,
1635
+ /**
1636
+ * The select label separator visible to the user
1637
+ */
1638
+ separator: { type: String, default: ", " },
1639
+ /**
1640
+ * Show native select
1641
+ */
1642
+ native: Boolean,
1643
+ /**
1644
+ * Show badges
1645
+ */
1646
+ badges: Boolean,
1647
+ /**
1648
+ * Badge modifiers
1649
+ */
1650
+ badgeModifiers: {
1651
+ type: [String, Array],
1652
+ default: "action sm"
1653
+ },
1654
+ /**
1655
+ * Set dropdown width to the same as the trigger
1656
+ */
1657
+ triggerWidth: {
1658
+ ...ht.triggerWidth,
1659
+ default: !0
1660
+ },
1661
+ /**
1662
+ * Dropdown modifiers
1663
+ */
1664
+ dropdownModifiers: {
1665
+ type: [String, Array]
1666
+ },
1667
+ /**
1668
+ * Open dropdown on focus
1669
+ */
1670
+ autoOpen: Boolean,
1671
+ /**
1672
+ * Close dropdown on select (not multiple)
1673
+ */
1674
+ autoClose: Boolean
1675
+ }, Ra = {
1676
+ ...st,
1677
+ ...me,
1678
+ ...ht,
1679
+ /**
1680
+ * Show / hide dropdown programmatically
1681
+ */
1682
+ modelValue: {
1683
+ type: Boolean,
1684
+ default: void 0
1685
+ },
1686
+ /**
1687
+ * Dropdown trigger element
1688
+ */
1689
+ reference: {
1690
+ type: Object,
1691
+ default: null
1692
+ },
1693
+ /**
1694
+ * Dropdown role
1695
+ */
1696
+ role: {
1697
+ type: String,
1698
+ default: je.menu,
1699
+ validator: (t) => Object.values(je).includes(t)
1700
+ }
1701
+ };
1702
+ function Ha({
1703
+ reference: t,
1704
+ id: l,
1705
+ expanded: e,
1706
+ aria: s
1707
+ }) {
1708
+ const o = Al(), c = j({
1709
+ name: "VvDropdownTriggerProvider",
1710
+ provide() {
1711
+ return {
1712
+ [Yt]: {
1713
+ reference: t,
1714
+ id: l,
1715
+ expanded: e,
1716
+ aria: s,
1717
+ bus: o
1718
+ }
1719
+ };
1720
+ },
1721
+ setup() {
1722
+ return {};
1723
+ },
1724
+ render() {
1725
+ var u, v;
1726
+ return be(ie, {}, (v = (u = this.$slots).default) == null ? void 0 : v.call(u));
1727
+ }
1728
+ });
1729
+ return {
1730
+ bus: o,
1731
+ component: c
1732
+ };
1733
+ }
1734
+ function Ma({
1735
+ role: t,
1736
+ expanded: l
1737
+ }) {
1738
+ const e = n(
1739
+ () => t.value === je.listbox ? mt.option : mt.presentation
1740
+ );
1741
+ return gt(Jt, {
1742
+ role: e,
1743
+ expanded: l
1744
+ }), { itemRole: e };
1745
+ }
1746
+ function xa({
1747
+ expanded: t
1748
+ }) {
1749
+ gt(Xt, {
1750
+ role: Wt.menuitem,
1751
+ expanded: t
1752
+ });
1753
+ }
1754
+ const Ga = ["id", "tabindex", "role", "aria-labelledby"], ja = {
1755
+ name: "VvDropdown",
1756
+ inheritAttrs: !1
1757
+ }, sl = /* @__PURE__ */ j({
1758
+ ...ja,
1759
+ props: Ra,
986
1760
  emits: ["update:modelValue"],
987
- setup(o, { emit: a }) {
988
- const e = o, n = computed(() => String(e.id || ne())), { modifiers: s, disabled: d } = toRefs(e), { getOptionLabel: r, getOptionValue: f } = useOptions(e), { bemCssClasses: p } = useBemModifiers("vv-dropdown", {
989
- modifiers: s,
990
- disabled: d
1761
+ setup(t, { emit: l }) {
1762
+ const e = t, { id: s } = G(e), o = Le(s), c = yt(), u = N("auto"), v = N("auto"), d = N(null), p = N(null), r = N(null), i = N(null), b = n({
1763
+ get: () => e.reference ?? d.value,
1764
+ set: (h) => {
1765
+ d.value = h;
1766
+ }
1767
+ }), _ = n(() => {
1768
+ const h = [];
1769
+ if (e.autoPlacement ? typeof e.autoPlacement == "boolean" ? h.push(Et()) : h.push(
1770
+ Et(e.autoPlacement)
1771
+ ) : e.flip && (typeof e.flip == "boolean" ? h.push(Pt()) : h.push(Pt(e.flip))), e.shift && (typeof e.shift == "boolean" ? h.push(Ot()) : h.push(Ot(e.shift))), e.size) {
1772
+ const U = ({
1773
+ availableWidth: ce,
1774
+ availableHeight: $e
1775
+ }) => {
1776
+ u.value = `${ce}px`, v.value = `${$e}px`;
1777
+ };
1778
+ typeof e.size == "boolean" ? h.push(
1779
+ Dt({
1780
+ apply: U
1781
+ })
1782
+ ) : h.push(
1783
+ Dt({
1784
+ ...e.size,
1785
+ apply: U
1786
+ })
1787
+ );
1788
+ }
1789
+ return e.offset && (h.push(ct(Number(e.offset))), ["string", "number"].includes(typeof e.offset) ? h.push(ct(Number(e.offset))) : h.push(ct(e.offset))), e.arrow && h.push(
1790
+ Vl({
1791
+ element: r
1792
+ })
1793
+ ), h;
1794
+ }), { x: k, y: A, strategy: y, middlewareData: m, placement: I } = $l(
1795
+ b,
1796
+ p,
1797
+ {
1798
+ whileElementsMounted: kl,
1799
+ placement: e.placement,
1800
+ middleware: _
1801
+ }
1802
+ ), O = n(() => ({
1803
+ position: y.value,
1804
+ top: `${A.value ?? 0}px`,
1805
+ left: `${k.value ?? 0}px`,
1806
+ maxWidth: u.value,
1807
+ maxHeight: v.value,
1808
+ width: e.triggerWidth && b.value ? `${b.value.offsetWidth}px` : void 0
1809
+ })), D = n(() => I.value.split("-")[0]), L = n(
1810
+ () => ({
1811
+ top: "bottom",
1812
+ right: "left",
1813
+ bottom: "top",
1814
+ left: "right"
1815
+ })[D.value] ?? "bottom"
1816
+ ), x = n(() => {
1817
+ var h, U, ce, $e;
1818
+ return ["bottom", "top"].includes(L.value) ? {
1819
+ right: `${((h = m.value.arrow) == null ? void 0 : h.x) ?? 0}px`,
1820
+ [L.value]: `${-(((U = r.value) == null ? void 0 : U.offsetWidth) ?? 0) / 2}px`
1821
+ } : {
1822
+ top: `${((ce = m.value.arrow) == null ? void 0 : ce.y) ?? 0}px`,
1823
+ [L.value]: `${-((($e = r.value) == null ? void 0 : $e.offsetWidth) ?? 0) / 2}px`
1824
+ };
1825
+ }), w = et(e, "modelValue", l), se = N(!1), P = n({
1826
+ get: () => w.value ?? se.value,
1827
+ set: (h) => {
1828
+ if (w.value === void 0) {
1829
+ se.value = h;
1830
+ return;
1831
+ }
1832
+ w.value = h;
1833
+ }
1834
+ }), W = () => {
1835
+ P.value = !0;
1836
+ }, F = () => {
1837
+ P.value = !1;
1838
+ }, ue = () => {
1839
+ P.value = !P.value;
1840
+ }, he = (h) => {
1841
+ b.value = h;
1842
+ };
1843
+ ve(P, (h) => {
1844
+ h && e.autofocusFirst && Xe(() => {
1845
+ const U = ae(
1846
+ p.value
1847
+ );
1848
+ U.length > 0 && U[0].focus();
1849
+ });
1850
+ }), xt(
1851
+ p,
1852
+ () => {
1853
+ e.autoClose && (P.value = !1);
1854
+ },
1855
+ { ignore: [b] }
1856
+ );
1857
+ const ye = n(() => {
1858
+ var h;
1859
+ return ((h = b.value) == null ? void 0 : h.getAttribute("id")) ?? void 0;
1860
+ }), ne = n(() => ({
1861
+ "aria-controls": o.value,
1862
+ "aria-haspopup": !0,
1863
+ "aria-expanded": P.value
1864
+ })), { component: de, bus: _e } = Ha({
1865
+ reference: b,
1866
+ id: o,
1867
+ expanded: P,
1868
+ aria: ne
991
1869
  });
992
- function i(u) {
993
- return Array.isArray(e.modelValue) ? contains(u, e.modelValue) || contains(f(u), e.modelValue) : equals(u, e.modelValue) || equals(f(u), e.modelValue);
994
- }
995
- function l(u) {
996
- return typeof u == "string" || u.disabled === void 0 ? d.value : u.disabled;
1870
+ _e.on("click", ue);
1871
+ const { role: re, modifiers: Ve } = G(e), { itemRole: J } = Ma({ role: re, expanded: P }), B = X(
1872
+ "vv-dropdown",
1873
+ Ve,
1874
+ n(() => ({
1875
+ arrow: e.arrow
1876
+ }))
1877
+ ), { focused: Q } = Vt(p);
1878
+ function ae(h) {
1879
+ return h ? [
1880
+ ...h.querySelectorAll(
1881
+ 'a[href], button, input, textarea, select, details,[tabindex]:not([tabindex="-1"])'
1882
+ )
1883
+ ].filter(
1884
+ (U) => !U.hasAttribute("disabled") && !U.getAttribute("aria-hidden")
1885
+ ) : [];
997
1886
  }
998
- function c(u) {
999
- var g;
1000
- if (e.disabled)
1001
- return;
1002
- let b = u;
1003
- if (e.multiple)
1004
- if (Array.isArray(e.modelValue)) {
1005
- if (e.maxValues !== void 0 && e.maxValues >= 0 && ((g = e.modelValue) == null ? void 0 : g.length) >= e.maxValues && !contains(u, e.modelValue))
1887
+ const Se = () => {
1888
+ Xe(() => {
1889
+ if (Q.value) {
1890
+ const h = ae(
1891
+ p.value
1892
+ );
1893
+ if (h.length === 0 || !document.activeElement)
1006
1894
  return;
1007
- b = contains(u, e.modelValue) ? removeFromList(u, e.modelValue) : [...e.modelValue, u];
1008
- } else
1009
- b = [u];
1010
- else
1011
- e.unselectable && u === e.modelValue && (b = void 0);
1012
- a("update:modelValue", b);
1013
- }
1014
- return (u, b) => {
1015
- var g;
1016
- return m(), _("ul", {
1017
- id: t(n),
1018
- class: U(t(p)),
1019
- role: "listbox"
1020
- }, [
1021
- (g = u.options) != null && g.length ? I("", !0) : (m(), _("li", co, [
1022
- R("label", null, B(u.labelNoResults), 1)
1023
- ])),
1024
- (m(!0), _(de, null, fe(u.options, (y, v) => (m(), _("li", {
1025
- key: v,
1026
- role: "option",
1027
- "aria-selected": i(y)
1028
- }, [
1029
- R("label", {
1030
- for: `dropdown-${v}-${t(n)}`,
1031
- onClick: Re((V) => c(t(f)(y)), ["prevent"])
1032
- }, [
1033
- R("input", {
1034
- id: `dropdown-${v}-${t(n)}`,
1035
- type: u.multiple ? "checkbox" : "radio",
1036
- value: t(f)(y),
1037
- checked: i(y),
1038
- disabled: l(y),
1039
- name: u.name,
1040
- tabindex: "-1",
1041
- "aria-hidden": "true"
1042
- }, null, 8, mo),
1043
- q(" " + B(t(r)(y)), 1)
1044
- ], 8, vo)
1045
- ], 8, po))), 128))
1046
- ], 10, uo);
1895
+ const U = h.indexOf(
1896
+ document.activeElement
1897
+ );
1898
+ U < h.length - 1 ? h[U + 1].focus() : h[0].focus();
1899
+ }
1900
+ });
1901
+ }, we = () => {
1902
+ Xe(() => {
1903
+ if (Q.value) {
1904
+ const h = ae(
1905
+ p.value
1906
+ );
1907
+ if (h.length === 0 || !document.activeElement)
1908
+ return;
1909
+ const U = h.indexOf(
1910
+ document.activeElement
1911
+ );
1912
+ U > 0 ? h[U - 1].focus() : h[h.length - 1].focus();
1913
+ }
1914
+ });
1047
1915
  };
1916
+ return He("Escape", (h) => {
1917
+ P.value && (h.preventDefault(), F());
1918
+ }), He("ArrowDown", (h) => {
1919
+ P.value && Q.value && (h.preventDefault(), Se());
1920
+ }), He("ArrowUp", (h) => {
1921
+ P.value && Q.value && (h.preventDefault(), we());
1922
+ }), He([" ", "Enter"], (h) => {
1923
+ P.value && Q.value && (h.preventDefault(), document.activeElement.click());
1924
+ }), (h, U) => (f(), g(ie, null, [
1925
+ pe(a(de), null, {
1926
+ default: te(() => [
1927
+ V(h.$slots, "default", K(z({ init: he, show: W, hide: F, toggle: ue, expanded: a(P), aria: a(ne) })))
1928
+ ]),
1929
+ _: 3
1930
+ }),
1931
+ pe(Rt, { name: h.transitionName }, {
1932
+ default: te(() => [
1933
+ Oe(M("div", {
1934
+ ref_key: "floatingEl",
1935
+ ref: p,
1936
+ style: It(a(O)),
1937
+ class: le(a(B))
1938
+ }, [
1939
+ e.arrow ? (f(), g("div", {
1940
+ key: 0,
1941
+ ref_key: "arrowEl",
1942
+ ref: r,
1943
+ style: It(a(x)),
1944
+ class: "vv-dropdown__arrow"
1945
+ }, null, 4)) : C("", !0),
1946
+ V(h.$slots, "before", K(z({ expanded: a(P) }))),
1947
+ M("ul", R(a(c), {
1948
+ id: a(o),
1949
+ ref_key: "listEl",
1950
+ ref: i,
1951
+ tabindex: a(P) ? void 0 : -1,
1952
+ role: a(re),
1953
+ "aria-labelledby": a(ye),
1954
+ class: "vv-dropdown__list"
1955
+ }), [
1956
+ V(h.$slots, "items", K(z({
1957
+ role: a(J)
1958
+ })))
1959
+ ], 16, Ga),
1960
+ V(h.$slots, "after", K(z({ expanded: a(P) })))
1961
+ ], 6), [
1962
+ [St, a(P)]
1963
+ ])
1964
+ ]),
1965
+ _: 3
1966
+ }, 8, ["name"])
1967
+ ], 64));
1048
1968
  }
1049
- }), ho = {
1050
- ...Ve,
1051
- ...qe,
1052
- ...je,
1053
- ...Ae,
1054
- ...ge,
1055
- ...ye,
1056
- ...Se,
1057
- ...Oe,
1058
- ...ce,
1059
- ..._e,
1060
- ...re,
1061
- ...ke,
1062
- ...Be,
1969
+ }), Wa = {
1970
+ name: "VvDropdownItem"
1971
+ }, Ua = /* @__PURE__ */ j({
1972
+ ...Wa,
1973
+ setup(t) {
1974
+ const { role: l, expanded: e } = sa(), s = N(null);
1975
+ xa({ expanded: e });
1976
+ const o = yl(s), { focused: c } = Gt(s), { focused: u } = Vt(s);
1977
+ return ve(o, (v) => {
1978
+ v && (c.value = !0);
1979
+ }), (v, d) => (f(), g("li", R({ role: a(l) }, {
1980
+ ref_key: "element",
1981
+ ref: s,
1982
+ class: ["vv-dropdown__item", { "focus-visible": a(c) || a(u) }]
1983
+ }), [
1984
+ V(v.$slots, "default")
1985
+ ], 16));
1986
+ }
1987
+ }), Fa = { class: "vv-dropdown-option__hint" }, Ka = {
1988
+ name: "VvDropdownOption"
1989
+ }, Qe = /* @__PURE__ */ j({
1990
+ ...Ka,
1991
+ props: {
1992
+ ...De,
1993
+ ...jl,
1994
+ ...qe,
1995
+ ...me,
1996
+ deselectHintLabel: {
1997
+ type: String
1998
+ },
1999
+ selectHintLabel: {
2000
+ type: String
2001
+ },
2002
+ selectedHintLabel: {
2003
+ type: String
2004
+ }
2005
+ },
2006
+ setup(t) {
2007
+ const l = t, { modifiers: e } = G(l), s = X(
2008
+ "vv-dropdown-option",
2009
+ e,
2010
+ n(() => ({
2011
+ disabled: l.disabled,
2012
+ selected: l.selected,
2013
+ unselectable: l.unselectable && l.selected
2014
+ }))
2015
+ );
2016
+ return (o, c) => (f(), H(Ua, {
2017
+ class: le(a(s)),
2018
+ tabindex: o.disabled ? -1 : 0,
2019
+ "aria-selected": o.selected,
2020
+ "aria-disabled": o.disabled
2021
+ }, {
2022
+ default: te(() => [
2023
+ V(o.$slots, "default"),
2024
+ M("span", Fa, [
2025
+ V(o.$slots, "hint", K(z({ disabled: o.disabled, selected: o.selected, unselectable: o.unselectable })), () => [
2026
+ o.selected ? (f(), g(ie, { key: 0 }, [
2027
+ Y(T(o.unselectable ? t.deselectHintLabel : t.selectedHintLabel), 1)
2028
+ ], 64)) : o.disabled ? C("", !0) : (f(), g(ie, { key: 1 }, [
2029
+ Y(T(t.selectHintLabel), 1)
2030
+ ], 64))
2031
+ ])
2032
+ ])
2033
+ ]),
2034
+ _: 3
2035
+ }, 8, ["class", "tabindex", "aria-selected", "aria-disabled"]));
2036
+ }
2037
+ }), za = {
2038
+ ...nt,
2039
+ ...Qt,
2040
+ ...Zt,
2041
+ ...ot,
2042
+ ...Ue,
2043
+ ...Fe,
2044
+ ...ze,
2045
+ ...at,
1063
2046
  ...De,
1064
- ...Pe,
2047
+ ...Ke,
2048
+ ...me,
2049
+ ...kt,
2050
+ ...At,
2051
+ ...wt,
2052
+ ...qe,
2053
+ ...Me,
2054
+ /**
2055
+ * This Boolean attribute indicates that multiple options can be selected in the list.
2056
+ * If it is not specified, then only one option can be selected at a time.
2057
+ * When multiple is specified, most browsers will show a scrolling list box instead of a single line dropdown.
2058
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/select#attr-multiple
2059
+ */
1065
2060
  multiple: Boolean,
2061
+ /**
2062
+ * A Boolean attribute indicating that an option with a non-empty string value must be selected.
2063
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/select#attr-required
2064
+ */
1066
2065
  required: Boolean,
2066
+ /**
2067
+ * If the control is presented as a scrolling list box (e.g. when multiple is specified),
2068
+ * this attribute represents the number of rows in the list that should be visible at one time.
2069
+ * Browsers are not required to present a select element as a scrolled list box. The default value is 0.
2070
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/select#attr-size
2071
+ */
1067
2072
  size: [String, Number],
2073
+ /**
2074
+ * modelValue can be a string, number, boolean, object or array of string, number, boolean, object
2075
+ */
1068
2076
  modelValue: {
1069
2077
  type: [String, Number, Boolean, Object, Array],
1070
2078
  default: void 0
1071
2079
  },
1072
- label: String,
2080
+ /**
2081
+ * Select placeholder
2082
+ */
1073
2083
  placeholder: String
1074
- }, go = ["update:modelValue", "focus", "blur"], yo = ["for"], _o = { class: "vv-select__wrapper" }, So = ["id"], Vo = ["disabled", "hidden"], $o = ["disabled", "value"], Co = {
2084
+ }, qa = ["update:modelValue", "focus", "blur"];
2085
+ function it(t, l) {
2086
+ const { focused: e } = Gt(t);
2087
+ return ve(e, (s) => {
2088
+ l(s ? "focus" : "blur", a(t));
2089
+ }), {
2090
+ focused: e
2091
+ };
2092
+ }
2093
+ function ut(t, l) {
2094
+ const e = n(
2095
+ () => Boolean((t == null ? void 0 : t.value) && l.value === Ge.before)
2096
+ ), s = n(
2097
+ () => Boolean((t == null ? void 0 : t.value) && l.value === Ge.after)
2098
+ ), o = n(
2099
+ () => Boolean((t == null ? void 0 : t.value) && l.value === fe.left)
2100
+ ), c = n(
2101
+ () => Boolean((t == null ? void 0 : t.value) && l.value === fe.right)
2102
+ ), u = n(
2103
+ () => Boolean((t == null ? void 0 : t.value) && l.value === fe.top)
2104
+ ), v = n(
2105
+ () => Boolean((t == null ? void 0 : t.value) && l.value === fe.bottom)
2106
+ );
2107
+ return {
2108
+ hasIcon: n(() => typeof (t == null ? void 0 : t.value) == "string" ? { name: t == null ? void 0 : t.value } : t == null ? void 0 : t.value),
2109
+ hasIconLeft: o,
2110
+ hasIconRight: c,
2111
+ hasIconTop: u,
2112
+ hasIconBottom: v,
2113
+ hasIconBefore: e,
2114
+ hasIconAfter: s
2115
+ };
2116
+ }
2117
+ const Ya = ["for"], Ja = { class: "vv-select__wrapper" }, Xa = {
2118
+ key: 0,
2119
+ class: "vv-select__input-before"
2120
+ }, Qa = { class: "vv-select__inner" }, Za = ["id"], eo = ["disabled", "hidden"], to = ["disabled", "value"], lo = {
2121
+ key: 1,
2122
+ class: "vv-select__input-after"
2123
+ }, ao = {
1075
2124
  name: "VvSelect"
1076
- }, ko = /* @__PURE__ */ N({
1077
- ...Co,
1078
- props: ho,
1079
- emits: go,
1080
- setup(o, { emit: a }) {
1081
- const e = o, n = useSlots(), s = ref(), { HintSlot: d, hasHint: r, hasInvalid: f } = pe(e, n), {
2125
+ }, oo = /* @__PURE__ */ j({
2126
+ ...ao,
2127
+ props: za,
2128
+ emits: qa,
2129
+ setup(t, { emit: l }) {
2130
+ const e = t, s = Ae(), o = N(), { HintSlot: c, hasHint: u, hasInvalid: v } = Be(e, s), {
2131
+ id: d,
1082
2132
  modifiers: p,
1083
- disabled: i,
1084
- readonly: l,
1085
- loading: c,
1086
- icon: u,
1087
- iconPosition: b,
1088
- invalid: g,
2133
+ disabled: r,
2134
+ readonly: i,
2135
+ loading: b,
2136
+ icon: _,
2137
+ iconPosition: k,
2138
+ invalid: A,
1089
2139
  valid: y,
1090
- floating: v,
1091
- multiple: V
1092
- } = toRefs(e), w = computed(() => String(e.id || ne())), $ = computed(() => `${w.value}-hint`), { focused: M } = useComponentFocus(s, a), C = useElementVisibility(s);
1093
- watch(C, (P) => {
1094
- P && e.autofocus && (M.value = !0);
2140
+ floating: m,
2141
+ multiple: I
2142
+ } = G(e), O = Le(d), D = n(() => `${O.value}-hint`), { focused: L } = it(o, l), x = $t(o);
2143
+ ve(x, (B) => {
2144
+ B && e.autofocus && (L.value = !0);
1095
2145
  });
1096
- const { hasIcon: H, hasIconLeft: X, hasIconRight: T } = useComponentIcon(
1097
- u,
1098
- b
1099
- ), x = computed(() => !isEmpty(e.modelValue)), J = computed(() => e.disabled || e.readonly), ee = computed(() => J.value ? -1 : e.tabindex), te = computed(() => {
2146
+ const { hasIcon: w, hasIconBefore: se, hasIconAfter: P } = ut(
2147
+ _,
2148
+ k
2149
+ ), W = n(() => !ge(e.modelValue)), F = n(() => e.disabled || e.readonly), ue = n(() => F.value ? -1 : e.tabindex), he = n(() => {
1100
2150
  if (e.invalid === !0)
1101
2151
  return !0;
1102
2152
  if (e.valid === !0)
1103
2153
  return !1;
1104
- }), { bemCssClasses: Q } = useBemModifiers("vv-select", {
1105
- modifiers: p,
1106
- valid: y,
1107
- invalid: g,
1108
- loading: c,
1109
- disabled: i,
1110
- readonly: l,
1111
- iconLeft: X,
1112
- iconRight: T,
1113
- dirty: x,
1114
- focus: M,
1115
- floating: v,
1116
- multiple: V
1117
- }), ie = computed(() => ({
2154
+ }), ye = X(
2155
+ "vv-select",
2156
+ p,
2157
+ n(() => ({
2158
+ valid: y.value,
2159
+ invalid: A.value,
2160
+ loading: b.value,
2161
+ disabled: r.value,
2162
+ readonly: i.value,
2163
+ "icon-before": se.value,
2164
+ "icon-after": P.value,
2165
+ dirty: W.value,
2166
+ focus: L.value,
2167
+ floating: m.value,
2168
+ multiple: I.value
2169
+ }))
2170
+ ), ne = n(() => ({
1118
2171
  name: e.name,
1119
- tabindex: ee.value,
1120
- disabled: J.value,
2172
+ tabindex: ue.value,
2173
+ disabled: F.value,
1121
2174
  required: e.required,
1122
2175
  size: e.size,
1123
2176
  autocomplete: e.autocomplete,
1124
2177
  multiple: e.multiple,
1125
- "aria-invalid": te.value,
1126
- "aria-describedby": !f.value && r.value ? $.value : void 0,
1127
- "aria-errormessage": f.value ? $.value : void 0
1128
- })), { getOptionLabel: oe, getOptionValue: se } = useOptions(e);
1129
- function ae(P) {
1130
- return typeof P == "string" || P.disabled === void 0 ? i.value : P.disabled;
1131
- }
1132
- const W = computed({
2178
+ "aria-invalid": he.value,
2179
+ "aria-describedby": !v.value && u.value ? D.value : void 0,
2180
+ "aria-errormessage": v.value ? D.value : void 0
2181
+ })), de = n(() => ({
2182
+ valid: e.valid,
2183
+ invalid: e.invalid,
2184
+ modelValue: e.modelValue
2185
+ })), { getOptionLabel: _e, getOptionValue: re, getOptionDisabled: Ve } = rt(e), J = n({
1133
2186
  get: () => e.modelValue,
1134
- set: (P) => {
1135
- Array.isArray(P) && (P = P.filter((j) => j !== void 0)), a("update:modelValue", P);
2187
+ set: (B) => {
2188
+ Array.isArray(B) && (B = B.filter((Q) => Q !== void 0)), l("update:modelValue", B);
1136
2189
  }
1137
2190
  });
1138
- return (P, j) => (m(), _("div", {
1139
- class: U(t(Q))
2191
+ return (B, Q) => (f(), g("div", {
2192
+ class: le(a(ye))
1140
2193
  }, [
1141
- P.label ? (m(), _("label", {
2194
+ B.label ? (f(), g("label", {
1142
2195
  key: 0,
1143
- for: t(w)
1144
- }, B(P.label), 9, yo)) : I("", !0),
1145
- R("div", _o, [
1146
- k(P.$slots, "before", {}, () => [
1147
- t(X) ? (m(), D(G, F(O({ key: 0 }, t(H))), null, 16)) : I("", !0)
1148
- ]),
1149
- ve(R("select", O({
1150
- id: t(w),
1151
- ref_key: "select",
1152
- ref: s,
1153
- "onUpdate:modelValue": j[0] || (j[0] = (A) => be(W) ? W.value = A : null)
1154
- }, t(ie)), [
1155
- P.placeholder ? (m(), _("option", {
2196
+ for: a(O)
2197
+ }, T(B.label), 9, Ya)) : C("", !0),
2198
+ M("div", Ja, [
2199
+ B.$slots.before ? (f(), g("div", Xa, [
2200
+ V(B.$slots, "before", K(z(a(de))))
2201
+ ])) : C("", !0),
2202
+ M("div", Qa, [
2203
+ a(se) ? (f(), H(ee, R({
1156
2204
  key: 0,
1157
- value: void 0,
1158
- disabled: !P.unselectable,
1159
- hidden: !P.unselectable
1160
- }, B(P.placeholder), 9, Vo)) : I("", !0),
1161
- (m(!0), _(de, null, fe(P.options, (A, L) => (m(), _("option", {
1162
- key: L,
1163
- disabled: ae(A),
1164
- value: t(se)(A)
1165
- }, B(t(oe)(A)), 9, $o))), 128))
1166
- ], 16, So), [
1167
- [nt, t(W)]
2205
+ class: "vv-select__icon"
2206
+ }, a(w)), null, 16)) : C("", !0),
2207
+ Oe(M("select", R({
2208
+ id: a(O),
2209
+ ref_key: "select",
2210
+ ref: o,
2211
+ "onUpdate:modelValue": Q[0] || (Q[0] = (ae) => Ee(J) ? J.value = ae : null)
2212
+ }, a(ne)), [
2213
+ B.placeholder ? (f(), g("option", {
2214
+ key: 0,
2215
+ value: void 0,
2216
+ disabled: !B.unselectable,
2217
+ hidden: !B.unselectable
2218
+ }, T(B.placeholder), 9, eo)) : C("", !0),
2219
+ (f(!0), g(ie, null, Ne(B.options, (ae, Se) => (f(), g("option", {
2220
+ key: Se,
2221
+ disabled: a(Ve)(ae),
2222
+ value: a(re)(ae)
2223
+ }, T(a(_e)(ae)), 9, to))), 128))
2224
+ ], 16, Za), [
2225
+ [cl, a(J)]
2226
+ ]),
2227
+ a(P) ? (f(), H(ee, R({
2228
+ key: 1,
2229
+ class: "vv-select__icon vv-select__icon-after"
2230
+ }, a(w)), null, 16)) : C("", !0)
1168
2231
  ]),
1169
- k(P.$slots, "after", {}, () => [
1170
- t(T) ? (m(), D(G, F(O({ key: 0 }, t(H))), null, 16)) : I("", !0)
1171
- ])
2232
+ B.$slots.after ? (f(), g("div", lo, [
2233
+ V(B.$slots, "after", K(z(a(de))))
2234
+ ])) : C("", !0)
1172
2235
  ]),
1173
- Z(t(d), {
1174
- id: t($),
2236
+ pe(a(c), {
2237
+ id: a(D),
1175
2238
  class: "vv-select__hint"
1176
2239
  }, null, 8, ["id"])
1177
2240
  ], 2));
1178
2241
  }
1179
- }), Ao = [
1180
- "update:modelValue",
1181
- "change:search",
1182
- "focus",
1183
- "blur"
1184
- ], Po = {
1185
- ...Ve,
1186
- ...Ae,
1187
- ...ge,
1188
- ...ye,
1189
- ...Se,
1190
- ...Oe,
1191
- ...ce,
1192
- ..._e,
1193
- ...re,
1194
- ...ke,
1195
- ...Be,
1196
- ...De,
1197
- ...Pe,
1198
- modelValue: {
1199
- type: [String, Number, Boolean, Object, Array],
1200
- default: void 0
1201
- },
1202
- label: String,
1203
- labelNoResults: { type: String, default: "No results" },
1204
- placeholder: String,
1205
- searchable: Boolean,
1206
- searchPlaceholder: String,
1207
- debounceSearch: {
1208
- type: [Number, String],
1209
- default: 0
1210
- },
1211
- multiple: Boolean,
1212
- maxValues: [Number, String],
1213
- separator: { type: String, default: ", " },
1214
- native: Boolean
1215
- }, wo = ["id"], Io = ["id", "for"], Eo = ["tabindex"], Ro = ["id", "placeholder"], Oo = {
1216
- name: "VvCombobox"
1217
- }, As = /* @__PURE__ */ N({
1218
- ...Oo,
1219
- props: Po,
1220
- emits: Ao,
1221
- setup(o, { emit: a }) {
1222
- const e = o, n = useSlots(), { HintSlot: s } = pe(e, n), d = ref(), r = ref(), { focused: f } = useComponentFocus(d, a), p = computed(() => String(e.id || ne())), i = ref(""), l = refDebounced(
1223
- i,
2242
+ }), so = ["id"], no = ["id", "for"], ro = ["id", "aria-controls", "aria-labelledby", "aria-describedby", "placeholder"], io = {
2243
+ key: 0,
2244
+ class: "vv-select__input-before"
2245
+ }, uo = { class: "vv-select__inner" }, co = ["aria-labelledby", "tabindex"], vo = ["aria-label", "onClick"], fo = {
2246
+ key: 1,
2247
+ class: "vv-select__input-after"
2248
+ }, po = {
2249
+ name: "VvCombobox",
2250
+ components: { VvDropdown: sl, VvDropdownOption: Qe }
2251
+ }, bs = /* @__PURE__ */ j({
2252
+ ...po,
2253
+ props: Na,
2254
+ emits: Ta,
2255
+ setup(t, { emit: l }) {
2256
+ const e = t, s = Ae(), { HintSlot: o } = Be(e, s), c = N(null), u = N(null), v = N(null), { focused: d } = it(c, l), { focused: p } = Vt(v);
2257
+ ve(d, (S) => {
2258
+ if (e.autoOpen) {
2259
+ if (S && !b.value) {
2260
+ k();
2261
+ return;
2262
+ }
2263
+ !S && b.value && !p.value && A();
2264
+ }
2265
+ }), ve(p, (S) => {
2266
+ !d.value && !S && b.value && A();
2267
+ });
2268
+ const r = N(""), i = gl(
2269
+ r,
1224
2270
  Number(e.debounceSearch)
1225
- ), c = ref(!1), {
1226
- icon: u,
1227
- iconPosition: b,
1228
- modifiers: g,
1229
- disabled: y,
1230
- readonly: v,
1231
- loading: V,
1232
- valid: w,
1233
- invalid: $,
1234
- floating: M
1235
- } = toRefs(e);
1236
- watch(
1237
- l,
1238
- () => a("change:search", l.value)
1239
2271
  );
1240
- const { hasIcon: C, hasIconLeft: H, hasIconRight: X } = useComponentIcon(
1241
- u,
1242
- b
1243
- ), T = computed(() => !isEmpty(e.modelValue)), x = computed(() => y.value || v.value ? -1 : e.tabindex), { bemCssClasses: J } = useBemModifiers("vv-select", {
1244
- modifiers: g,
1245
- disabled: y,
1246
- loading: V,
1247
- readonly: v,
1248
- iconLeft: H,
1249
- iconRight: X,
2272
+ ve(
2273
+ i,
2274
+ () => l("change:search", i.value)
2275
+ );
2276
+ const b = N(!1), _ = () => {
2277
+ e.disabled || e.readonly || (b.value = !b.value);
2278
+ }, k = () => {
2279
+ e.disabled || e.readonly || b.value || (b.value = !0);
2280
+ }, A = () => {
2281
+ e.disabled || e.readonly || !b.value || (b.value = !1);
2282
+ };
2283
+ ve(b, (S) => {
2284
+ W.value && Xe(() => {
2285
+ if (S) {
2286
+ u.value && u.value.focus();
2287
+ return;
2288
+ }
2289
+ r.value = "";
2290
+ });
2291
+ });
2292
+ const {
2293
+ id: y,
2294
+ icon: m,
2295
+ iconPosition: I,
2296
+ modifiers: O,
2297
+ disabled: D,
2298
+ readonly: L,
2299
+ loading: x,
1250
2300
  valid: w,
1251
- invalid: $,
1252
- dirty: T,
1253
- focus: f,
1254
- floating: M
1255
- }), ee = computed(
1256
- () => e.searchable ? ie.value : e.options
1257
- ), { getOptionLabel: te, getOptionValue: Q } = useOptions(e), ie = computed(() => {
1258
- var A;
1259
- return (A = e.options) == null ? void 0 : A.filter((L) => te(L).toLowerCase().includes(l.value.toLowerCase().trim()));
1260
- }), oe = computed(() => {
1261
- let A = [];
1262
- return Array.isArray(e.modelValue) ? A = e.modelValue : e.modelValue && (A = [e.modelValue]), e.options.filter(
1263
- (L) => A.includes(Q(L))
1264
- );
1265
- }), se = computed(() => oe.value.map((A) => te(A)).join(e.separator));
1266
- onClickOutside(d, () => {
1267
- d.value.open = !1;
2301
+ invalid: se,
2302
+ floating: P,
2303
+ searchable: W
2304
+ } = G(e), F = Le(y), ue = n(() => `${F.value}-hint`), he = n(() => `${F.value}-dropdown`), ye = n(() => `${F.value}-search`), ne = n(() => `${F.value}-label`), { hasIcon: de, hasIconBefore: _e, hasIconAfter: re } = ut(
2305
+ m,
2306
+ I
2307
+ ), Ve = n(() => !ge(e.modelValue)), J = n(() => D.value || L.value ? -1 : e.tabindex), B = X(
2308
+ "vv-select",
2309
+ O,
2310
+ n(() => ({
2311
+ disabled: D.value,
2312
+ loading: x.value,
2313
+ readonly: L.value,
2314
+ "icon-before": Boolean(_e.value),
2315
+ "icon-after": Boolean(re.value),
2316
+ valid: w.value,
2317
+ invalid: se.value,
2318
+ dirty: Ve.value,
2319
+ focus: d.value,
2320
+ floating: P.value
2321
+ }))
2322
+ ), Q = n(
2323
+ () => e.searchable ? h.value : e.options
2324
+ ), { getOptionLabel: ae, getOptionValue: Se, getOptionDisabled: we } = rt(e), h = n(() => {
2325
+ var S;
2326
+ return (S = e.options) == null ? void 0 : S.filter((Z) => ae(Z).toLowerCase().includes(i.value.toLowerCase().trim()));
1268
2327
  });
1269
- function ae(A) {
1270
- const L = A.target;
1271
- c.value = L.open;
1272
- }
1273
- function W(A) {
1274
- d.value && !e.multiple && (d.value.open = !1), a("update:modelValue", A);
2328
+ function U(S) {
2329
+ return Array.isArray(e.modelValue) ? Ce(S, e.modelValue) || Ce(Se(S), e.modelValue) : Pe(S, e.modelValue) || Pe(Se(S), e.modelValue);
1275
2330
  }
1276
- const P = computed(() => ({
1277
- name: e.name,
1278
- options: ee.value,
1279
- labelKey: e.labelKey,
1280
- valueKey: e.valueKey,
1281
- disabled: e.disabled,
1282
- labelNoResults: e.labelNoResults,
1283
- multiple: e.multiple,
1284
- maxValues: e.maxValues,
1285
- modelValue: e.modelValue,
1286
- unselectable: e.unselectable
1287
- })), j = computed(() => ({
1288
- id: p.value,
2331
+ const ce = n(() => {
2332
+ let S = [];
2333
+ return Array.isArray(e.modelValue) ? S = e.modelValue : e.modelValue && (S = [e.modelValue]), e.options.filter(
2334
+ (Z) => S.includes(Se(Z))
2335
+ );
2336
+ }), $e = n(() => ce.value.map((S) => ae(S)).join(e.separator));
2337
+ ve(ce, () => {
2338
+ !e.multiple && e.autoClose && A();
2339
+ });
2340
+ const dt = () => {
2341
+ e.autoOpen ? k() : _();
2342
+ }, xe = (S) => {
2343
+ var Te;
2344
+ if (e.disabled || e.readonly)
2345
+ return;
2346
+ const Z = Se(S);
2347
+ let q = Z;
2348
+ if (e.multiple)
2349
+ if (Array.isArray(e.modelValue)) {
2350
+ if (e.maxValues !== void 0 && e.maxValues >= 0 && ((Te = e.modelValue) == null ? void 0 : Te.length) >= e.maxValues && !Ce(Z, e.modelValue))
2351
+ return;
2352
+ q = Ce(Z, e.modelValue) ? Il(Z, e.modelValue) : [...e.modelValue, Z];
2353
+ } else
2354
+ q = [Z];
2355
+ else
2356
+ e.unselectable && Z === e.modelValue && (q = void 0);
2357
+ l("update:modelValue", q);
2358
+ }, E = n(() => ({
2359
+ id: F.value,
1289
2360
  name: e.name,
1290
- tabindex: x.value,
2361
+ tabindex: J.value,
1291
2362
  valid: w.value,
1292
2363
  validLabel: e.validLabel,
1293
- invalid: $.value,
2364
+ invalid: se.value,
1294
2365
  invalidLabel: e.invalidLabel,
1295
2366
  hintLabel: e.hintLabel,
1296
- loading: V.value,
2367
+ loading: x.value,
1297
2368
  loadingLabel: e.loadingLabel,
1298
- disabled: y.value,
1299
- readonly: v.value,
2369
+ disabled: D.value,
2370
+ readonly: L.value,
1300
2371
  modifiers: e.modifiers,
1301
- options: ee.value,
2372
+ options: Q.value,
1302
2373
  labelKey: e.labelKey,
1303
2374
  valueKey: e.valueKey,
1304
2375
  icon: e.icon,
@@ -1309,142 +2380,286 @@ const Zt = ["for"], eo = ["id", "name", "disabled", "value", "tabindex", "aria-i
1309
2380
  label: e.label,
1310
2381
  placeholder: e.placeholder,
1311
2382
  modelValue: e.modelValue
2383
+ })), oe = n(() => ({
2384
+ id: he.value,
2385
+ reference: v.value,
2386
+ placement: e.placement,
2387
+ transitionName: e.transitionName,
2388
+ offset: e.offset,
2389
+ shift: e.shift,
2390
+ flip: e.flip,
2391
+ autoPlacement: e.autoPlacement,
2392
+ arrow: e.arrow,
2393
+ autoClose: e.autoClose,
2394
+ autofocusFirst: W.value ? !1 : e.autofocusFirst,
2395
+ triggerWidth: e.triggerWidth,
2396
+ modifiers: e.dropdownModifiers
2397
+ })), Re = n(() => ({
2398
+ valid: e.valid,
2399
+ invalid: e.invalid,
2400
+ modelValue: e.modelValue
1312
2401
  }));
1313
- return (A, L) => A.native ? (m(), D(ko, O({ key: 1 }, t(j), {
1314
- "onUpdate:modelValue": L[4] || (L[4] = (z) => a("update:modelValue", z))
1315
- }), null, 16)) : (m(), _("div", {
2402
+ return He([" ", "Enter"], (S) => {
2403
+ e.autoOpen || !b.value && d.value && (S.preventDefault(), S.stopImmediatePropagation(), _());
2404
+ }), (S, Z) => S.native ? (f(), H(oo, R({ key: 1 }, a(E), {
2405
+ "onUpdate:modelValue": Z[2] || (Z[2] = (q) => l("update:modelValue", q))
2406
+ }), null, 16)) : (f(), g("div", {
1316
2407
  key: 0,
1317
- id: t(p),
1318
- class: U(t(J))
2408
+ id: a(F),
2409
+ class: le(a(B))
1319
2410
  }, [
1320
- A.label ? (m(), _("label", {
2411
+ S.label ? (f(), g("label", {
1321
2412
  key: 0,
1322
- id: `${t(p)}-label`,
1323
- for: A.searchable && t(c) ? `${t(p)}-input` : void 0
1324
- }, B(A.label), 9, Io)) : I("", !0),
1325
- R("details", {
1326
- ref_key: "dropdown",
1327
- ref: d,
1328
- class: "vv-select__wrapper",
1329
- onClick: L[2] || (L[2] = (z) => t(y) || t(v) ? z.preventDefault() : null),
1330
- onKeyup: L[3] || (L[3] = Le((z) => t(d).open = !1, ["esc"])),
1331
- onToggle: ae
2413
+ id: a(ne),
2414
+ for: a(W) ? a(ye) : void 0
2415
+ }, T(S.label), 9, no)) : C("", !0),
2416
+ M("div", {
2417
+ ref_key: "wrapperEl",
2418
+ ref: v,
2419
+ class: "vv-select__wrapper"
1332
2420
  }, [
1333
- R("summary", {
1334
- class: "vv-select__input",
1335
- tabindex: t(x),
1336
- onKeyup: L[1] || (L[1] = Le((z) => A.searchable ? z.preventDefault() : null, ["space"]))
1337
- }, [
1338
- k(A.$slots, "before", {}, () => [
1339
- t(H) ? (m(), D(G, O({
1340
- key: 0,
1341
- class: "vv-select__icon-left"
1342
- }, t(C)), null, 16)) : I("", !0)
2421
+ pe(sl, R({
2422
+ modelValue: a(b),
2423
+ "onUpdate:modelValue": Z[1] || (Z[1] = (q) => Ee(b) ? b.value = q : null)
2424
+ }, a(oe), {
2425
+ role: a(je).listbox
2426
+ }), vl({
2427
+ default: te(({ aria: q }) => [
2428
+ S.$slots.before ? (f(), g("div", io, [
2429
+ V(S.$slots, "before", K(z(a(Re))))
2430
+ ])) : C("", !0),
2431
+ M("div", uo, [
2432
+ a(_e) ? (f(), H(ee, R({
2433
+ key: 0,
2434
+ class: "vv-select__icon"
2435
+ }, a(de)), null, 16)) : C("", !0),
2436
+ M("div", R({
2437
+ ref_key: "inputEl",
2438
+ ref: c
2439
+ }, q, {
2440
+ "aria-labelledby": a(ne),
2441
+ class: "vv-select__input",
2442
+ role: "combobox",
2443
+ tabindex: a(J),
2444
+ onClickPassive: dt
2445
+ }), [
2446
+ V(S.$slots, "value", K(z({ selectedOptions: a(ce), onInput: xe })), () => [
2447
+ a($e) ? (f(), g(ie, { key: 0 }, [
2448
+ S.badges ? (f(!0), g(ie, { key: 1 }, Ne(a(ce), (Te, Ct) => (f(), H(Yl, {
2449
+ key: Ct,
2450
+ modifiers: S.badgeModifiers,
2451
+ class: "vv-select__badge"
2452
+ }, {
2453
+ default: te(() => [
2454
+ Y(T(a(ae)(Te)) + " ", 1),
2455
+ S.unselectable && !a(L) && !a(D) ? (f(), g("button", {
2456
+ key: 0,
2457
+ "aria-label": S.deselectActionLabel,
2458
+ onClick: Tt((as) => xe(Te), ["stop"])
2459
+ }, [
2460
+ pe(ee, { name: "close" })
2461
+ ], 8, vo)) : C("", !0)
2462
+ ]),
2463
+ _: 2
2464
+ }, 1032, ["modifiers"]))), 128)) : (f(), g(ie, { key: 0 }, [
2465
+ Y(T(a($e)), 1)
2466
+ ], 64))
2467
+ ], 64)) : (f(), g(ie, { key: 1 }, [
2468
+ Y(T(S.placeholder), 1)
2469
+ ], 64))
2470
+ ])
2471
+ ], 16, co),
2472
+ a(re) ? (f(), H(ee, R({
2473
+ key: 1,
2474
+ class: "vv-select__icon vv-select__icon-after"
2475
+ }, a(de)), null, 16)) : C("", !0)
2476
+ ]),
2477
+ S.$slots.after ? (f(), g("div", fo, [
2478
+ V(S.$slots, "after", K(z(a(Re))))
2479
+ ])) : C("", !0)
1343
2480
  ]),
1344
- A.searchable && t(c) ? ve((m(), _("input", {
1345
- key: 0,
1346
- id: `${t(p)}-input`,
1347
- ref_key: "inputSearch",
1348
- ref: r,
1349
- "onUpdate:modelValue": L[0] || (L[0] = (z) => be(i) ? i.value = z : null),
1350
- role: "combobox",
1351
- type: "search",
1352
- placeholder: A.searchPlaceholder
1353
- }, null, 8, Ro)), [
1354
- [xe, t(i)]
1355
- ]) : (m(), _(de, { key: 1 }, [
1356
- q(B(t(se) || A.placeholder), 1)
1357
- ], 64)),
1358
- k(A.$slots, "after", {}, () => [
1359
- t(X) ? (m(), D(G, O({
1360
- key: 0,
1361
- class: "vv-select__icon-right"
1362
- }, t(C)), null, 16)) : I("", !0)
1363
- ])
1364
- ], 40, Eo),
1365
- Z(bo, O({
1366
- id: `${t(p)}-dropdown`
1367
- }, t(P), { "onUpdate:modelValue": W }), null, 16, ["id"])
1368
- ], 544),
1369
- Z(t(s), { class: "vv-select__hint" })
1370
- ], 10, wo));
2481
+ items: te(() => [
2482
+ a(h).length ? (f(!0), g(ie, { key: 0 }, Ne(a(h), (q, Te) => (f(), H(Qe, R({
2483
+ disabled: a(we)(q),
2484
+ selected: U(q),
2485
+ unselectable: S.unselectable,
2486
+ deselectHintLabel: S.deselectHintLabel,
2487
+ selectHintLabel: S.selectHintLabel,
2488
+ selectedHintLabel: S.selectedHintLabel
2489
+ }, {
2490
+ key: Te,
2491
+ class: "vv-dropdown-option",
2492
+ onClickPassive: (Ct) => xe(q)
2493
+ }), {
2494
+ default: te(() => [
2495
+ V(S.$slots, "option", K(z({
2496
+ option: q,
2497
+ selectedOptions: a(ce),
2498
+ selected: U(q),
2499
+ disabled: a(we)(q)
2500
+ })), () => [
2501
+ Y(T(a(ae)(q)), 1)
2502
+ ])
2503
+ ]),
2504
+ _: 2
2505
+ }, 1040, ["onClickPassive"]))), 128)) : S.options.length ? (f(), H(Qe, {
2506
+ key: 2,
2507
+ modifiers: "inert"
2508
+ }, {
2509
+ default: te(() => [
2510
+ V(S.$slots, "no-results", {}, () => [
2511
+ Y(T(S.noResultsLabel), 1)
2512
+ ])
2513
+ ]),
2514
+ _: 3
2515
+ })) : (f(), H(Qe, {
2516
+ key: 1,
2517
+ modifiers: "inert"
2518
+ }, {
2519
+ default: te(() => [
2520
+ V(S.$slots, "no-options", {}, () => [
2521
+ Y(T(S.noOptionsLabel), 1)
2522
+ ])
2523
+ ]),
2524
+ _: 3
2525
+ }))
2526
+ ]),
2527
+ _: 2
2528
+ }, [
2529
+ a(W) || S.$slots["dropdown::before"] ? {
2530
+ name: "before",
2531
+ fn: te(() => [
2532
+ V(S.$slots, "dropdown::before"),
2533
+ a(W) ? Oe((f(), g("input", {
2534
+ key: 0,
2535
+ id: a(ye),
2536
+ ref_key: "inputSearchEl",
2537
+ ref: u,
2538
+ "onUpdate:modelValue": Z[0] || (Z[0] = (q) => Ee(r) ? r.value = q : null),
2539
+ "aria-autocomplete": "list",
2540
+ "aria-controls": a(he),
2541
+ "aria-labelledby": a(ne),
2542
+ "aria-describedby": a(ue),
2543
+ autocomplete: "off",
2544
+ spellcheck: "false",
2545
+ type: "search",
2546
+ class: "vv-dropdown__search",
2547
+ placeholder: S.searchPlaceholder
2548
+ }, null, 8, ro)), [
2549
+ [St, a(b)],
2550
+ [Ht, a(r)]
2551
+ ]) : C("", !0)
2552
+ ]),
2553
+ key: "0"
2554
+ } : void 0,
2555
+ S.$slots["dropdown::after"] ? {
2556
+ name: "after",
2557
+ fn: te(() => [
2558
+ V(S.$slots, "dropdown::after")
2559
+ ]),
2560
+ key: "1"
2561
+ } : void 0
2562
+ ]), 1040, ["modelValue", "role"])
2563
+ ], 512),
2564
+ pe(a(o), {
2565
+ id: a(ue),
2566
+ class: "vv-select__hint"
2567
+ }, null, 8, ["id"])
2568
+ ], 10, so));
1371
2569
  }
1372
- }), Bo = ["open", "close", "update:modelValue"], Do = {
1373
- id: { type: String, required: !0 },
2570
+ }), mo = ["open", "close", "update:modelValue"], bo = {
2571
+ ...st,
2572
+ /**
2573
+ * Dialog title
2574
+ */
1374
2575
  title: String,
2576
+ /**
2577
+ * Show / hide dialog programmatically
2578
+ */
1375
2579
  modelValue: Boolean,
2580
+ /**
2581
+ * Dialog transition
2582
+ */
1376
2583
  transition: { type: String, default: "fade-block" },
2584
+ /**
2585
+ * Dialog size
2586
+ */
1377
2587
  size: String,
2588
+ /**
2589
+ * Close dialog on click outside
2590
+ */
1378
2591
  autoClose: { type: Boolean, default: !0 }
1379
- }, To = {
2592
+ }, ho = {
1380
2593
  key: 0,
1381
2594
  class: "vv-dialog__header"
1382
- }, Lo = ["onClick"], Mo = { class: "vv-dialog__content" }, No = {
2595
+ }, yo = { class: "vv-dialog__content" }, go = {
1383
2596
  key: 1,
1384
2597
  class: "vv-dialog__footer"
1385
- }, Ho = {
2598
+ }, _o = {
1386
2599
  name: "VvDialog"
1387
- }, Ps = /* @__PURE__ */ N({
1388
- ...Ho,
1389
- props: Do,
1390
- emits: Bo,
1391
- setup(o, { emit: a }) {
1392
- const e = o, n = useVModel(e, "modelValue", a), s = ref(!0), d = ref(null), r = computed(() => {
1393
- const { id: c } = e;
2600
+ }, hs = /* @__PURE__ */ j({
2601
+ ..._o,
2602
+ props: bo,
2603
+ emits: mo,
2604
+ setup(t, { emit: l }) {
2605
+ const e = t, s = et(e, "modelValue", l), o = N(!0), c = N(null), u = n(() => {
2606
+ const { id: i } = e;
1394
2607
  return {
1395
- id: c,
1396
- open: s.value
2608
+ id: i,
2609
+ open: o.value
1397
2610
  };
1398
- }), f = computed(() => e.size ? ["vv-dialog", `vv-dialog--${e.size}`] : "vv-dialog"), p = computed(() => `vv-dialog--${e.transition}`), i = {
2611
+ }), v = n(() => e.size ? ["vv-dialog", `vv-dialog--${e.size}`] : "vv-dialog"), d = n(() => `vv-dialog--${e.transition}`), p = {
1399
2612
  "before-enter": () => {
1400
- s.value = !0, a("open");
2613
+ o.value = !0, l("open");
1401
2614
  },
1402
2615
  "after-leave": () => {
1403
- s.value = !1, a("close");
2616
+ o.value = !1, l("close");
1404
2617
  }
1405
2618
  };
1406
- onClickOutside(d, () => {
1407
- e.autoClose && (n.value = !1);
2619
+ xt(c, () => {
2620
+ e.autoClose && (s.value = !1);
1408
2621
  });
1409
- function l() {
1410
- n.value = !1;
2622
+ function r() {
2623
+ s.value = !1;
1411
2624
  }
1412
- return (c, u) => (m(), D(rt, O({ name: t(p) }, it(i)), {
1413
- default: he(() => [
1414
- ve(R("dialog", O(t(r), { class: t(f) }), [
1415
- R("article", {
2625
+ return He("Escape", (i) => {
2626
+ s.value && (i.preventDefault(), r());
2627
+ }), (i, b) => (f(), H(Rt, R({ name: a(d) }, fl(p)), {
2628
+ default: te(() => [
2629
+ Oe(M("dialog", R(a(u), { class: a(v) }), [
2630
+ M("article", {
1416
2631
  ref_key: "modalWrapper",
1417
- ref: d,
2632
+ ref: c,
1418
2633
  class: "vv-dialog__wrapper"
1419
2634
  }, [
1420
- c.$slots.header || c.title ? (m(), _("header", To, [
1421
- k(c.$slots, "header", {}, () => [
1422
- q(B(c.title) + " ", 1),
1423
- R("button", {
2635
+ i.$slots.header || i.title ? (f(), g("header", ho, [
2636
+ V(i.$slots, "header", {}, () => [
2637
+ Y(T(i.title) + " ", 1),
2638
+ M("button", {
1424
2639
  type: "button",
1425
2640
  "aria-label": "Close",
1426
2641
  class: "vv-dialog__close",
1427
- onClick: Re(l, ["prevent"])
2642
+ onClickPassive: r
1428
2643
  }, [
1429
- Z(G, { name: "close" })
1430
- ], 8, Lo)
2644
+ pe(ee, { name: "close" })
2645
+ ], 32)
1431
2646
  ])
1432
- ])) : I("", !0),
1433
- R("div", Mo, [
1434
- k(c.$slots, "default")
2647
+ ])) : C("", !0),
2648
+ M("div", yo, [
2649
+ V(i.$slots, "default")
1435
2650
  ]),
1436
- c.$slots.footer ? (m(), _("footer", No, [
1437
- k(c.$slots, "footer")
1438
- ])) : I("", !0)
2651
+ i.$slots.footer ? (f(), g("footer", go, [
2652
+ V(i.$slots, "footer")
2653
+ ])) : C("", !0)
1439
2654
  ], 512)
1440
2655
  ], 16), [
1441
- [ut, t(n)]
2656
+ [St, a(s)]
1442
2657
  ])
1443
2658
  ]),
1444
2659
  _: 3
1445
2660
  }, 16, ["name"]));
1446
2661
  }
1447
- }), S = {
2662
+ }), $ = {
1448
2663
  TEXT: "text",
1449
2664
  PASSWORD: "password",
1450
2665
  NUMBER: "number",
@@ -1458,61 +2673,121 @@ const Zt = ["for"], eo = ["id", "name", "disabled", "value", "tabindex", "aria-i
1458
2673
  DATETIME_LOCAL: "datetime-local",
1459
2674
  MONTH: "month",
1460
2675
  WEEK: "week"
1461
- }, ue = {
2676
+ }, Ie = {
1462
2677
  PASSWORD_SHOW: "eye-on",
1463
2678
  PASSWORD_HIDE: "eye-off",
1464
2679
  DATE: "calendar",
1465
2680
  TIME: "time",
1466
2681
  COLOR: "color",
1467
2682
  SEARCH: "close"
1468
- }, Go = ["update:modelValue", "focus", "blur", "keyup"], xo = {
1469
- ...ze,
2683
+ }, So = ["update:modelValue", "focus", "blur", "keyup"], Vo = {
2684
+ ...el,
2685
+ /**
2686
+ * Input value
2687
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#value
2688
+ */
1470
2689
  modelValue: [String, Number],
2690
+ /**
2691
+ * Type of form control
2692
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#type
2693
+ */
1471
2694
  type: {
1472
2695
  type: String,
1473
- default: S.TEXT,
1474
- validator: (o) => Object.values(S).includes(o)
2696
+ default: $.TEXT,
2697
+ validator: (t) => Object.values($).includes(t)
1475
2698
  },
2699
+ /**
2700
+ * Minimum value
2701
+ * Available for input types: date, month, week, time, datetime-local, number, range.
2702
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#min
2703
+ */
1476
2704
  min: [Number, Date, String],
2705
+ /**
2706
+ * Maximum value
2707
+ * Available for input types: date, month, week, time, datetime-local, number, range.
2708
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#max
2709
+ */
1477
2710
  max: [Number, Date, String],
2711
+ /**
2712
+ * Incremental values that are valid
2713
+ * Available for input types: date, month, week, time, datetime-local and number
2714
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#step
2715
+ */
1478
2716
  step: { type: [String, Number], default: 1 },
2717
+ /**
2718
+ * Pattern the value must match to be valid
2719
+ * Available for input types: text, search, url, tel, email and password
2720
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#pattern
2721
+ */
1479
2722
  pattern: String,
2723
+ /**
2724
+ * Whether to allow multiple values
2725
+ * Available for input type email
2726
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#multiple
2727
+ */
1480
2728
  multiple: Boolean,
2729
+ /**
2730
+ * VvIcon name for show password button
2731
+ * @see VVIcon
2732
+ */
1481
2733
  iconShowPassword: {
1482
2734
  type: String,
1483
- default: ue.PASSWORD_SHOW
2735
+ default: Ie.PASSWORD_SHOW
1484
2736
  },
2737
+ /**
2738
+ * VvIcon name for hide password button
2739
+ * @see VVIcon
2740
+ */
1485
2741
  iconHidePassword: {
1486
2742
  type: String,
1487
- default: ue.PASSWORD_HIDE
2743
+ default: Ie.PASSWORD_HIDE
1488
2744
  },
2745
+ /**
2746
+ * VvIcon name for clear button
2747
+ * @see VVIcon
2748
+ */
1489
2749
  iconClear: {
1490
2750
  type: String,
1491
- default: ue.SEARCH
2751
+ default: Ie.SEARCH
1492
2752
  },
2753
+ /**
2754
+ * Label for step up button
2755
+ */
1493
2756
  labelStepUp: {
1494
2757
  type: String,
1495
2758
  default: "Increase value"
1496
2759
  },
2760
+ /**
2761
+ * Label for step down button
2762
+ */
1497
2763
  labelStepDown: {
1498
2764
  type: String,
1499
2765
  default: "Decrease value"
1500
2766
  },
2767
+ /**
2768
+ * Label for show password button
2769
+ */
1501
2770
  labelShowPassword: {
1502
2771
  type: String,
1503
2772
  default: "Show password"
1504
2773
  },
2774
+ /**
2775
+ * Label for hide password button
2776
+ */
1505
2777
  labelHidePassword: {
1506
2778
  type: String,
1507
2779
  default: "Hide password"
1508
2780
  },
2781
+ /**
2782
+ * Label for clear button
2783
+ */
1509
2784
  labelClear: {
1510
2785
  type: String,
1511
2786
  default: "Clear"
1512
2787
  }
1513
- }, Ne = defineComponent({
2788
+ }, Lt = j({
1514
2789
  components: {
1515
- VvIcon: G
2790
+ VvIcon: ee
1516
2791
  },
1517
2792
  props: {
1518
2793
  disabled: {
@@ -1529,33 +2804,33 @@ const Zt = ["for"], eo = ["id", "name", "disabled", "value", "tabindex", "aria-i
1529
2804
  },
1530
2805
  iconShow: {
1531
2806
  type: String,
1532
- default: ue.PASSWORD_SHOW
2807
+ default: Ie.PASSWORD_SHOW
1533
2808
  },
1534
2809
  iconHide: {
1535
2810
  type: String,
1536
- default: ue.PASSWORD_HIDE
2811
+ default: Ie.PASSWORD_HIDE
1537
2812
  }
1538
2813
  },
1539
2814
  emits: ["toggle-password"],
1540
- setup(o, { emit: a }) {
1541
- const e = ref(!1), n = computed(
1542
- () => e.value ? o.iconHide : o.iconShow
2815
+ setup(t, { emit: l }) {
2816
+ const e = N(!1), s = n(
2817
+ () => e.value ? t.iconHide : t.iconShow
1543
2818
  );
1544
- function s(d) {
1545
- d == null || d.stopPropagation(), o.disabled || (e.value = !e.value, a("toggle-password", e.value));
2819
+ function o(c) {
2820
+ c == null || c.stopPropagation(), t.disabled || (e.value = !e.value, l("toggle-password", e.value));
1546
2821
  }
1547
2822
  return {
1548
2823
  active: e,
1549
- activeIcon: n,
1550
- onClick: s
2824
+ activeIcon: s,
2825
+ onClick: o
1551
2826
  };
1552
2827
  },
1553
2828
  render() {
1554
- const o = h(G, {
2829
+ const t = be(ee, {
1555
2830
  name: this.activeIcon,
1556
2831
  class: "vv-input-text__action-icon"
1557
2832
  });
1558
- return h(
2833
+ return be(
1559
2834
  "button",
1560
2835
  {
1561
2836
  disabled: this.disabled,
@@ -1564,12 +2839,12 @@ const Zt = ["for"], eo = ["id", "name", "disabled", "value", "tabindex", "aria-i
1564
2839
  type: "button",
1565
2840
  onClick: this.onClick
1566
2841
  },
1567
- o
2842
+ t
1568
2843
  );
1569
2844
  }
1570
- }), Ie = defineComponent({
2845
+ }), vt = j({
1571
2846
  components: {
1572
- VvIcon: G
2847
+ VvIcon: ee
1573
2848
  },
1574
2849
  props: {
1575
2850
  disabled: {
@@ -1581,22 +2856,22 @@ const Zt = ["for"], eo = ["id", "name", "disabled", "value", "tabindex", "aria-i
1581
2856
  },
1582
2857
  mode: {
1583
2858
  type: String,
1584
- validator: (o) => ["up", "down"].includes(o),
2859
+ validator: (t) => ["up", "down"].includes(t),
1585
2860
  default: "up"
1586
2861
  }
1587
2862
  },
1588
2863
  emits: ["step-up", "step-down"],
1589
- setup(o, { emit: a }) {
1590
- const e = computed(() => o.mode === "up");
2864
+ setup(t, { emit: l }) {
2865
+ const e = n(() => t.mode === "up");
1591
2866
  return {
1592
2867
  isUp: e,
1593
- onClick: (s) => {
1594
- s == null || s.stopPropagation(), o.disabled || a(e.value ? "step-up" : "step-down");
2868
+ onClick: (o) => {
2869
+ o == null || o.stopPropagation(), t.disabled || l(e.value ? "step-up" : "step-down");
1595
2870
  }
1596
2871
  };
1597
2872
  },
1598
2873
  render() {
1599
- return h("button", {
2874
+ return be("button", {
1600
2875
  class: [
1601
2876
  "vv-input-text__action-chevron",
1602
2877
  this.isUp && "vv-input-text__action-chevron-up"
@@ -1606,9 +2881,9 @@ const Zt = ["for"], eo = ["id", "name", "disabled", "value", "tabindex", "aria-i
1606
2881
  onClick: this.onClick
1607
2882
  });
1608
2883
  }
1609
- }), He = defineComponent({
2884
+ }), Bt = j({
1610
2885
  components: {
1611
- VvIcon: G
2886
+ VvIcon: ee
1612
2887
  },
1613
2888
  props: {
1614
2889
  disabled: {
@@ -1625,20 +2900,20 @@ const Zt = ["for"], eo = ["id", "name", "disabled", "value", "tabindex", "aria-i
1625
2900
  }
1626
2901
  },
1627
2902
  emits: ["clear"],
1628
- setup(o, { emit: a }) {
1629
- function e(n) {
1630
- n == null || n.stopPropagation(), o.disabled || a("clear");
2903
+ setup(t, { emit: l }) {
2904
+ function e(s) {
2905
+ s == null || s.stopPropagation(), t.disabled || l("clear");
1631
2906
  }
1632
2907
  return {
1633
2908
  onClick: e
1634
2909
  };
1635
2910
  },
1636
2911
  render() {
1637
- const o = h(G, {
2912
+ const t = be(ee, {
1638
2913
  name: this.icon,
1639
2914
  class: "vv-input-text__action-icon"
1640
2915
  });
1641
- return h(
2916
+ return be(
1642
2917
  "button",
1643
2918
  {
1644
2919
  disabled: this.disabled,
@@ -1647,51 +2922,51 @@ const Zt = ["for"], eo = ["id", "name", "disabled", "value", "tabindex", "aria-i
1647
2922
  type: "button",
1648
2923
  onClick: this.onClick
1649
2924
  },
1650
- o
2925
+ t
1651
2926
  );
1652
2927
  }
1653
2928
  });
1654
- function Ee(o, a) {
2929
+ function ft(t, l) {
1655
2930
  return {
1656
2931
  name: "VvInputTextActions",
1657
2932
  components: {
1658
- VvIcon: G,
1659
- VvInputPasswordAction: Ne,
1660
- VvInputStepAction: Ie,
1661
- VvInputClearAction: He
2933
+ VvIcon: ee,
2934
+ VvInputPasswordAction: Lt,
2935
+ VvInputStepAction: vt,
2936
+ VvInputClearAction: Bt
1662
2937
  },
1663
2938
  setup() {
1664
2939
  return {
1665
- isDisabled: computed(() => a.disabled || a.readonly),
1666
- labelStepUp: a.labelStepUp,
1667
- labelStepDown: a.labelStepDown,
1668
- labelShowPassword: a.labelShowPassword,
1669
- labelHidePassword: a.labelHidePassword,
1670
- labelClear: a.labelClear,
1671
- iconShowPassword: a.iconShowPassword,
1672
- iconHidePassword: a.iconHidePassword
2940
+ isDisabled: n(() => l.disabled || l.readonly),
2941
+ labelStepUp: l.labelStepUp,
2942
+ labelStepDown: l.labelStepDown,
2943
+ labelShowPassword: l.labelShowPassword,
2944
+ labelHidePassword: l.labelHidePassword,
2945
+ labelClear: l.labelClear,
2946
+ iconShowPassword: l.iconShowPassword,
2947
+ iconHidePassword: l.iconHidePassword
1673
2948
  };
1674
2949
  },
1675
2950
  render() {
1676
2951
  let e = null;
1677
- switch (o) {
1678
- case S.SEARCH: {
1679
- const { onClear: n } = this.$attrs;
2952
+ switch (t) {
2953
+ case $.SEARCH: {
2954
+ const { onClear: s } = this.$attrs;
1680
2955
  e = [
1681
- h(He, {
2956
+ be(Bt, {
1682
2957
  disabled: this.isDisabled,
1683
2958
  label: this.labelShowPassword,
1684
- onClear: n
2959
+ onClear: s
1685
2960
  })
1686
2961
  ];
1687
2962
  break;
1688
2963
  }
1689
- case S.PASSWORD: {
1690
- const { onTogglePassword: n } = this.$attrs;
2964
+ case $.PASSWORD: {
2965
+ const { onTogglePassword: s } = this.$attrs;
1691
2966
  e = [
1692
- h(Ne, {
2967
+ be(Lt, {
1693
2968
  disabled: this.isDisabled,
1694
- onTogglePassword: n,
2969
+ onTogglePassword: s,
1695
2970
  labelShow: this.labelShowPassword,
1696
2971
  labelHide: this.labelHidePassword,
1697
2972
  iconShow: this.iconShowPassword,
@@ -1700,404 +2975,499 @@ function Ee(o, a) {
1700
2975
  ];
1701
2976
  break;
1702
2977
  }
1703
- case S.NUMBER: {
1704
- const { onStepUp: n, onStepDown: s } = this.$attrs;
2978
+ case $.NUMBER: {
2979
+ const { onStepUp: s, onStepDown: o } = this.$attrs;
1705
2980
  e = [
1706
- h(Ie, {
2981
+ be(vt, {
1707
2982
  mode: "up",
1708
- disabled: this.isDisabled || a.max !== void 0 && a.modelValue === a.max,
2983
+ disabled: this.isDisabled || l.max !== void 0 && l.modelValue === l.max,
1709
2984
  label: this.labelStepUp,
1710
- onStepUp: n,
1711
- onStepDown: s
2985
+ onStepUp: s,
2986
+ onStepDown: o
1712
2987
  }),
1713
- h(Ie, {
2988
+ be(vt, {
1714
2989
  mode: "down",
1715
- disabled: this.isDisabled || a.min !== void 0 && a.modelValue === a.min,
2990
+ disabled: this.isDisabled || l.min !== void 0 && l.modelValue === l.min,
1716
2991
  label: this.labelStepDown,
1717
- onStepUp: n,
1718
- onStepDown: s
2992
+ onStepUp: s,
2993
+ onStepDown: o
1719
2994
  })
1720
2995
  ];
1721
2996
  break;
1722
2997
  }
1723
2998
  }
1724
- return Array.isArray(e) ? h("div", { class: "vv-input-text__actions-group" }, e) : e;
2999
+ return Array.isArray(e) ? be("div", { class: "vv-input-text__actions-group" }, e) : e;
1725
3000
  }
1726
3001
  };
1727
3002
  }
1728
- const Uo = ["for"], Fo = { class: "vv-input-text__wrapper" }, Ko = ["id"], Wo = {
3003
+ function nl(t, l, e = 0) {
3004
+ let s;
3005
+ return typeof e == "string" && (e = parseInt(e)), n({
3006
+ get: () => t == null ? void 0 : t.value,
3007
+ set: (o) => {
3008
+ s && clearTimeout(s), s = setTimeout(() => {
3009
+ l("update:modelValue", o);
3010
+ }, e);
3011
+ }
3012
+ });
3013
+ }
3014
+ function rl(t, l) {
3015
+ const e = n(() => (a(t) ?? "").length), s = n(() => (l == null ? void 0 : l.lowerLimit) !== void 0 && e.value < (l == null ? void 0 : l.lowerLimit) ? e.value - l.lowerLimit : (l == null ? void 0 : l.upperLimit) !== void 0 && e.value < (l == null ? void 0 : l.upperLimit) ? l.upperLimit - e.value : 0), o = n(() => (l == null ? void 0 : l.mode) === !1 ? "" : (l == null ? void 0 : l.mode) === "limit" && (l != null && l.upperLimit) ? `${e.value} / ${l.lowerLimit ? `${l.lowerLimit}-` : ""}${l.upperLimit}` : (l == null ? void 0 : l.mode) === "countdown" ? s.value === 0 ? void 0 : s : e.value);
3016
+ return {
3017
+ length: e,
3018
+ gap: s,
3019
+ formatted: o
3020
+ };
3021
+ }
3022
+ const $o = ["for"], ko = { class: "vv-input-text__wrapper" }, Ao = {
1729
3023
  key: 0,
3024
+ class: "vv-input-text__input-before"
3025
+ }, wo = { class: "vv-input-text__inner" }, Co = ["id"], Io = {
3026
+ key: 1,
3027
+ class: "vv-input-text__input-after"
3028
+ }, Eo = {
3029
+ key: 2,
1730
3030
  class: "vv-input-text__limit"
1731
- }, qo = {
3031
+ }, Po = {
1732
3032
  name: "VvInputText"
1733
- }, ws = /* @__PURE__ */ N({
1734
- ...qo,
1735
- props: xo,
1736
- emits: Go,
1737
- setup(o, { emit: a }) {
1738
- const e = o, n = useSlots(), s = ref(), {
1739
- icon: d,
1740
- iconPosition: r,
1741
- label: f,
3033
+ }, ys = /* @__PURE__ */ j({
3034
+ ...Po,
3035
+ props: Vo,
3036
+ emits: So,
3037
+ setup(t, { emit: l }) {
3038
+ const e = t, s = Ae(), o = N(), {
3039
+ id: c,
3040
+ icon: u,
3041
+ iconPosition: v,
3042
+ label: d,
1742
3043
  modelValue: p,
1743
- count: i,
1744
- valid: l,
1745
- invalid: c,
1746
- loading: u
1747
- } = toRefs(e), b = computed(() => String(e.id || ne())), g = computed(() => `${b.value}-hint`), y = computed(
1748
- () => e.floating && isEmpty(e.placeholder) ? " " : e.placeholder
1749
- ), v = useDebouncedInput(p, a, e.debounce), { focused: V } = useComponentFocus(s, a), w = useElementVisibility(s);
1750
- watch(w, (E) => {
1751
- E && e.autofocus && (V.value = !0);
3044
+ count: r,
3045
+ valid: i,
3046
+ invalid: b,
3047
+ loading: _
3048
+ } = G(e), k = Le(c), A = n(() => `${k.value}-hint`), y = n(
3049
+ () => e.floating && ge(e.placeholder) ? " " : e.placeholder
3050
+ ), m = nl(p, l, e.debounce), { focused: I } = it(o, l), O = $t(o);
3051
+ ve(O, (E) => {
3052
+ E && e.autofocus && (I.value = !0);
1752
3053
  });
1753
- const $ = ref(!1), M = computed(() => e.type === S.PASSWORD), C = () => {
1754
- $.value = !$.value;
1755
- }, H = computed(
1756
- () => e.type === S.TIME || e.type === S.DATETIME_LOCAL || e.type === S.DATE || e.type === S.WEEK || e.type === S.MONTH
1757
- ), X = computed(() => e.type === S.NUMBER), T = () => {
1758
- ae.value && (s.value.stepUp(), v.value = unref(s).value);
1759
- }, x = () => {
1760
- ae.value && (s.value.stepDown(), v.value = unref(s).value);
1761
- }, J = computed(() => e.type === S.SEARCH), ee = () => {
1762
- v.value = void 0;
1763
- }, { hasIconLeft: te, hasIconRight: Q, hasIcon: ie } = useComponentIcon(
1764
- d,
1765
- r
1766
- ), oe = computed(() => {
3054
+ const D = N(!1), L = n(() => e.type === $.PASSWORD), x = () => {
3055
+ D.value = !D.value;
3056
+ }, w = n(
3057
+ () => e.type === $.TIME || e.type === $.DATETIME_LOCAL || e.type === $.DATE || e.type === $.WEEK || e.type === $.MONTH
3058
+ ), se = n(() => e.type === $.NUMBER), P = () => {
3059
+ re.value && (o.value.stepUp(), m.value = a(o).value);
3060
+ }, W = () => {
3061
+ re.value && (o.value.stepDown(), m.value = a(o).value);
3062
+ }, F = n(() => e.type === $.SEARCH), ue = () => {
3063
+ m.value = void 0;
3064
+ }, { hasIcon: he, hasIconBefore: ye, hasIconAfter: ne } = ut(
3065
+ u,
3066
+ v
3067
+ ), de = n(() => {
1767
3068
  switch (e.type) {
1768
- case S.COLOR:
1769
- return { name: ue.COLOR };
1770
- case S.DATE:
1771
- case S.DATETIME_LOCAL:
1772
- case S.WEEK:
1773
- case S.MONTH:
1774
- return { name: ue.DATE };
1775
- case S.TIME:
1776
- return { name: ue.TIME };
3069
+ case $.COLOR:
3070
+ return { name: Ie.COLOR };
3071
+ case $.DATE:
3072
+ case $.DATETIME_LOCAL:
3073
+ case $.WEEK:
3074
+ case $.MONTH:
3075
+ return { name: Ie.DATE };
3076
+ case $.TIME:
3077
+ return { name: Ie.TIME };
1777
3078
  default:
1778
3079
  return "";
1779
3080
  }
1780
- }), { formatted: se } = useTextCount(v, {
3081
+ }), { formatted: _e } = rl(m, {
1781
3082
  mode: e.count,
1782
3083
  upperLimit: e.maxlength,
1783
3084
  lowerLimit: e.minlength
1784
- }), ae = computed(() => !e.disabled && !e.readonly), W = computed(
1785
- () => ae.value ? e.tabindex : -1
1786
- ), P = computed(() => !isEmpty(p)), j = computed(() => {
1787
- if (c.value === !0)
3085
+ }), re = n(() => !e.disabled && !e.readonly), Ve = n(
3086
+ () => re.value ? e.tabindex : -1
3087
+ ), J = n(() => !ge(p)), B = n(() => {
3088
+ if (b.value === !0)
1788
3089
  return !0;
1789
- if (l.value === !0)
3090
+ if (i.value === !0)
1790
3091
  return !1;
1791
- }), { bemCssClasses: A } = useBemModifiers("vv-input-text", {
1792
- modifiers: e.modifiers,
1793
- valid: l,
1794
- invalid: c,
1795
- loading: u,
1796
- disabled: e.disabled,
1797
- readonly: e.readonly,
1798
- iconLeft: te,
1799
- iconRight: Q.value || !isEmpty(oe),
1800
- floating: e.floating && !isEmpty(e.label),
1801
- dirty: P,
1802
- focus: V
1803
- }), L = computed(() => {
1804
- const E = (() => M.value && $.value || H.value && !P.value && !V.value ? S.TEXT : e.type)(), K = {
3092
+ }), { modifiers: Q } = G(e), ae = X(
3093
+ "vv-input-text",
3094
+ Q,
3095
+ n(() => ({
3096
+ valid: i.value,
3097
+ invalid: b.value,
3098
+ loading: _.value,
3099
+ disabled: e.disabled,
3100
+ readonly: e.readonly,
3101
+ "icon-before": ye.value,
3102
+ "icon-after": ne.value || !ge(de),
3103
+ floating: e.floating && !ge(e.label),
3104
+ dirty: J.value,
3105
+ focus: I.value
3106
+ }))
3107
+ ), Se = n(() => {
3108
+ const E = (() => L.value && D.value || w.value && !J.value && !I.value ? $.TEXT : e.type)(), oe = {
1805
3109
  type: E,
1806
3110
  name: e.name,
1807
- tabindex: W.value,
3111
+ tabindex: Ve.value,
1808
3112
  disabled: e.disabled,
1809
3113
  readonly: e.readonly,
1810
3114
  required: e.required,
1811
3115
  autocomplete: e.autocomplete,
1812
- "aria-invalid": j.value,
1813
- "aria-describedby": !Te.value && tt.value ? g.value : void 0,
1814
- "aria-errormessage": Te.value ? g.value : void 0
3116
+ "aria-invalid": B.value,
3117
+ "aria-describedby": !ce.value && U.value ? A.value : void 0,
3118
+ "aria-errormessage": ce.value ? A.value : void 0
1815
3119
  };
1816
- return (E === S.DATE || E === S.MONTH || E === S.WEEK || E === S.TIME || E === S.DATETIME_LOCAL || E === S.NUMBER) && (K.step = e.step, K.max = String(e.max), K.min = String(e.min)), (E === S.TEXT || E === S.SEARCH || E === S.URL || E === S.TEL || E === S.EMAIL || E === S.PASSWORD || E === S.NUMBER) && (K.placeholder = y.value), (E === S.TEXT || E === S.SEARCH || E === S.URL || E === S.TEL || E === S.EMAIL || E === S.PASSWORD) && (K.minlength = e.minlength, K.maxlength = e.maxlength, K.pattern = e.pattern), E === S.EMAIL && (K.multiple = e.multiple), K;
1817
- }), z = computed(() => ({
3120
+ return (E === $.DATE || E === $.MONTH || E === $.WEEK || E === $.TIME || E === $.DATETIME_LOCAL || E === $.NUMBER) && (oe.step = e.step, oe.max = String(e.max), oe.min = String(e.min)), (E === $.TEXT || E === $.SEARCH || E === $.URL || E === $.TEL || E === $.EMAIL || E === $.PASSWORD || E === $.NUMBER) && (oe.placeholder = y.value), (E === $.TEXT || E === $.SEARCH || E === $.URL || E === $.TEL || E === $.EMAIL || E === $.PASSWORD) && (oe.minlength = e.minlength, oe.maxlength = e.maxlength, oe.pattern = e.pattern), E === $.EMAIL && (oe.multiple = e.multiple), oe;
3121
+ }), we = n(() => ({
1818
3122
  valid: e.valid,
1819
3123
  invalid: e.invalid,
1820
3124
  modelValue: e.modelValue,
1821
- togglePassword: C,
1822
- stepUp: T,
1823
- stepDown: x,
1824
- clear: ee
1825
- })), { HintSlot: et, hasHint: tt, hasInvalid: Te } = pe(e, n), ot = Ee(
1826
- S.PASSWORD,
3125
+ togglePassword: x,
3126
+ stepUp: P,
3127
+ stepDown: W,
3128
+ clear: ue
3129
+ })), { HintSlot: h, hasHint: U, hasInvalid: ce } = Be(e, s), $e = ft(
3130
+ $.PASSWORD,
1827
3131
  e
1828
- ), st = Ee(
1829
- S.NUMBER,
3132
+ ), dt = ft(
3133
+ $.NUMBER,
1830
3134
  e
1831
- ), at = Ee(
1832
- S.SEARCH,
3135
+ ), xe = ft(
3136
+ $.SEARCH,
1833
3137
  e
1834
3138
  );
1835
- return (E, K) => (m(), _("div", {
1836
- class: U(t(A))
3139
+ return (E, oe) => (f(), g("div", {
3140
+ class: le(a(ae))
1837
3141
  }, [
1838
- t(f) ? (m(), _("label", {
3142
+ a(d) ? (f(), g("label", {
1839
3143
  key: 0,
1840
- for: t(b),
3144
+ for: a(k),
1841
3145
  class: "vv-input-text__label"
1842
- }, B(t(f)), 9, Uo)) : I("", !0),
1843
- R("div", Fo, [
1844
- k(E.$slots, "before", F(Y(t(z))), () => [
1845
- t(te) ? (m(), D(G, O({
3146
+ }, T(a(d)), 9, $o)) : C("", !0),
3147
+ M("div", ko, [
3148
+ E.$slots.before ? (f(), g("div", Ao, [
3149
+ V(E.$slots, "before", K(z(a(we))))
3150
+ ])) : C("", !0),
3151
+ M("div", wo, [
3152
+ a(ye) ? (f(), H(ee, R({
1846
3153
  key: 0,
1847
- class: "vv-input-text__icon-left"
1848
- }, t(ie)), null, 16)) : I("", !0)
1849
- ]),
1850
- ve(R("input", O({
1851
- id: t(b),
1852
- ref_key: "input",
1853
- ref: s,
1854
- "onUpdate:modelValue": K[0] || (K[0] = (we) => be(v) ? v.value = we : null)
1855
- }, t(L), {
1856
- onKeyup: K[1] || (K[1] = (we) => a("keyup", we))
1857
- }), null, 16, Ko), [
1858
- [dt, t(v)]
1859
- ]),
1860
- k(E.$slots, "after", F(Y(t(z))), () => [
1861
- t(Q) || t(oe) ? (m(), D(G, F(O({ key: 0 }, t(Q) ? t(ie) : t(oe))), null, 16)) : t(M) ? (m(), D(t(ot), {
3154
+ class: "vv-input-text__icon"
3155
+ }, a(he)), null, 16)) : C("", !0),
3156
+ Oe(M("input", R({
3157
+ id: a(k),
3158
+ ref_key: "input",
3159
+ ref: o,
3160
+ "onUpdate:modelValue": oe[0] || (oe[0] = (Re) => Ee(m) ? m.value = Re : null)
3161
+ }, a(Se), {
3162
+ onKeyup: oe[1] || (oe[1] = (Re) => l("keyup", Re))
3163
+ }), null, 16, Co), [
3164
+ [pl, a(m)]
3165
+ ]),
3166
+ a(ne) || a(de) ? (f(), H(ee, R({
1862
3167
  key: 1,
1863
- onTogglePassword: C
1864
- })) : t(X) ? (m(), D(t(st), {
3168
+ class: "vv-input-text__icon vv-input-text__icon-after"
3169
+ }, a(ne) ? a(he) : a(de)), null, 16)) : a(L) ? (f(), H(a($e), {
1865
3170
  key: 2,
1866
- onStepUp: T,
1867
- onStepDown: x
1868
- })) : t(J) ? (m(), D(t(at), {
3171
+ onTogglePassword: x
3172
+ })) : a(se) ? (f(), H(a(dt), {
1869
3173
  key: 3,
1870
- onClear: ee
1871
- })) : I("", !0)
3174
+ onStepUp: P,
3175
+ onStepDown: W
3176
+ })) : a(F) ? (f(), H(a(xe), {
3177
+ key: 4,
3178
+ onClear: ue
3179
+ })) : C("", !0)
1872
3180
  ]),
1873
- t(i) ? (m(), _("span", Wo, [
1874
- k(E.$slots, "count", F(Y(t(z))), () => [
1875
- q(B(t(se)), 1)
3181
+ E.$slots.after ? (f(), g("div", Io, [
3182
+ V(E.$slots, "after", K(z(a(we))))
3183
+ ])) : C("", !0),
3184
+ a(r) ? (f(), g("span", Eo, [
3185
+ V(E.$slots, "count", K(z(a(we))), () => [
3186
+ Y(T(a(_e)), 1)
1876
3187
  ])
1877
- ])) : I("", !0)
3188
+ ])) : C("", !0)
1878
3189
  ]),
1879
- Z(t(et), {
1880
- id: t(g),
3190
+ pe(a(h), {
3191
+ id: a(A),
1881
3192
  class: "vv-input-text__hint"
1882
3193
  }, null, 8, ["id"])
1883
3194
  ], 2));
1884
3195
  }
1885
- }), jo = {
1886
- ...re,
3196
+ }), Oo = {
3197
+ ...me,
3198
+ /**
3199
+ * Progress value
3200
+ * This attribute specifies how much of the task that has been completed.
3201
+ * It must be a valid floating point number between 0 and max, or between 0 and 1 if max is omitted.
3202
+ * If there is no value attribute, the progress bar is indeterminate.
3203
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/progress#attr-max
3204
+ */
1887
3205
  value: {
1888
3206
  type: [Number, String],
1889
3207
  default: void 0
1890
3208
  },
3209
+ /**
3210
+ * Progress max
3211
+ * This attribute describes how much work the task indicated by the progress element requires.
3212
+ * The max attribute, if present, must have a value greater than 0 and be a valid floating point number. The default value is 1.
3213
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/progress#attr-max
3214
+ */
1891
3215
  max: {
1892
3216
  type: [Number, String]
1893
3217
  },
3218
+ /**
3219
+ * Progress aria-label
3220
+ */
1894
3221
  label: {
1895
3222
  type: String,
1896
3223
  required: !0
1897
3224
  }
1898
- }, zo = {
3225
+ }, Do = {
1899
3226
  name: "VvProgress"
1900
- }, Is = /* @__PURE__ */ N({
1901
- ...zo,
1902
- props: jo,
1903
- setup(o) {
1904
- const a = o, { value: e, max: n, label: s } = toRefs(a), d = computed(() => a.value === void 0), { bemCssClasses: r } = useBemModifiers("vv-progress", {
1905
- modifiers: a.modifiers,
1906
- indeterminate: d
1907
- });
1908
- return (f, p) => (m(), _("progress", O({ role: "progressbar" }, {
1909
- class: t(r),
1910
- ariaLabel: t(s),
1911
- max: t(n),
1912
- value: t(e)
3227
+ }, gs = /* @__PURE__ */ j({
3228
+ ...Do,
3229
+ props: Oo,
3230
+ setup(t) {
3231
+ const l = t, { value: e, max: s, label: o } = G(l), c = n(() => l.value === void 0), { modifiers: u } = G(l), v = X(
3232
+ "vv-progress",
3233
+ u,
3234
+ n(() => ({ indeterminate: c.value }))
3235
+ );
3236
+ return (d, p) => (f(), g("progress", R({ role: "progressbar" }, {
3237
+ class: a(v),
3238
+ ariaLabel: a(o),
3239
+ max: a(s),
3240
+ value: a(e)
1913
3241
  }), null, 16));
1914
3242
  }
1915
- }), Xo = Xe, Yo = ["click", "update:modelValue", "change", "blur"];
1916
- function Jo(o, a) {
1917
- const { group: e, isInGroup: n, getGroupOrLocalRef: s } = useInjectedGroupState(Fe), d = s("modelValue", o, a), r = s("readonly", o), f = s("disabled", o), p = s("valid", o), i = s("invalid", o);
3243
+ }), Lo = tl, Bo = ["click", "update:modelValue", "change", "blur"];
3244
+ function To(t, l) {
3245
+ const { id: e } = G(t), { group: s, isInGroup: o, getGroupOrLocalRef: c } = tt(Kt), u = c("modelValue", t, l), v = c("readonly", t), d = c("disabled", t), p = c("valid", t), r = c("invalid", t);
1918
3246
  return {
1919
- group: e,
1920
- isInGroup: n,
1921
- modelValue: d,
1922
- readonly: r,
1923
- disabled: f,
3247
+ // local props
3248
+ id: e,
3249
+ // global props
3250
+ group: s,
3251
+ isInGroup: o,
3252
+ modelValue: u,
3253
+ readonly: v,
3254
+ disabled: d,
1924
3255
  valid: p,
1925
- invalid: i
3256
+ invalid: r
1926
3257
  };
1927
3258
  }
1928
- const Qo = ["for"], Zo = ["id", "name", "disabled", "value", "tabindex", "aria-invalid"], es = {
3259
+ const No = ["for"], Ro = ["id", "name", "disabled", "value", "tabindex", "aria-invalid"], Ho = {
1929
3260
  name: "VvRadio"
1930
- }, ts = /* @__PURE__ */ N({
1931
- ...es,
1932
- props: Xo,
1933
- emits: Yo,
1934
- setup(o, { emit: a }) {
1935
- const e = o, n = useSlots(), { disabled: s, readonly: d, modelValue: r, valid: f, invalid: p } = Jo(
1936
- e,
1937
- a
1938
- ), i = computed(() => String(e.id || ne())), l = computed(() => u.value ? -1 : e.tabindex), c = ref(), u = computed(() => s.value || d.value), b = computed(() => {
3261
+ }, Mo = /* @__PURE__ */ j({
3262
+ ...Ho,
3263
+ props: Lo,
3264
+ emits: Bo,
3265
+ setup(t, { emit: l }) {
3266
+ const e = t, s = Ae(), { id: o, disabled: c, readonly: u, modelValue: v, valid: d, invalid: p } = To(e, l), r = Le(o), i = n(() => _.value ? -1 : e.tabindex), b = N(), _ = n(() => c.value || u.value), k = n(() => {
1939
3267
  if (p.value === !0)
1940
3268
  return !0;
1941
- if (f.value === !0)
3269
+ if (d.value === !0)
1942
3270
  return !1;
1943
- }), g = computed(
1944
- () => Array.isArray(r.value) ? contains(e.value, r.value) : equals(e.value, r.value)
1945
- ), y = computed(
3271
+ }), A = n(
3272
+ () => Array.isArray(v.value) ? Ce(e.value, v.value) : Pe(e.value, v.value)
3273
+ ), y = n(
1946
3274
  () => ["string", "number", "boolean"].includes(typeof e.value) ? e.value : !0
1947
- ), v = computed({
3275
+ ), m = n({
1948
3276
  get() {
1949
- return g.value ? y.value : null;
3277
+ return A.value ? y.value : null;
1950
3278
  },
1951
- set($) {
1952
- Array.isArray(r.value) ? r.value = [e.value] : r.value = e.value, a("change", $);
3279
+ set(L) {
3280
+ Array.isArray(v.value) ? v.value = [e.value] : v.value = e.value, l("change", L);
1953
3281
  }
1954
- }), { bemCssClasses: V } = useBemModifiers("vv-radio", {
1955
- valid: f,
1956
- invalid: p,
1957
- disabled: s,
1958
- readonly: d
1959
- }), { HintSlot: w } = pe(e, n);
1960
- return ($, M) => (m(), _("label", {
1961
- class: U(t(V)),
1962
- for: t(i)
3282
+ }), { modifiers: I } = G(e), O = X(
3283
+ "vv-radio",
3284
+ I,
3285
+ n(() => ({
3286
+ valid: d.value,
3287
+ invalid: p.value,
3288
+ disabled: c.value,
3289
+ readonly: u.value
3290
+ }))
3291
+ ), { HintSlot: D } = Be(e, s);
3292
+ return (L, x) => (f(), g("label", {
3293
+ class: le(a(O)),
3294
+ for: a(r)
1963
3295
  }, [
1964
- ve(R("input", {
1965
- id: t(i),
3296
+ Oe(M("input", {
3297
+ id: a(r),
1966
3298
  ref_key: "input",
1967
- ref: c,
1968
- "onUpdate:modelValue": M[0] || (M[0] = (C) => be(v) ? v.value = C : null),
3299
+ ref: b,
3300
+ "onUpdate:modelValue": x[0] || (x[0] = (w) => Ee(m) ? m.value = w : null),
1969
3301
  type: "radio",
1970
3302
  class: "vv-radio__input",
1971
- name: $.name,
1972
- disabled: t(u),
1973
- value: t(y),
1974
- tabindex: t(l),
1975
- "aria-invalid": t(b)
1976
- }, null, 8, Zo), [
1977
- [ct, t(v)]
3303
+ name: L.name,
3304
+ disabled: a(_),
3305
+ value: a(y),
3306
+ tabindex: a(i),
3307
+ "aria-invalid": a(k)
3308
+ }, null, 8, Ro), [
3309
+ [ml, a(m)]
1978
3310
  ]),
1979
- k($.$slots, "default", { value: t(r) }, () => [
1980
- q(B($.label), 1)
3311
+ V(L.$slots, "default", { value: a(v) }, () => [
3312
+ Y(T(L.label), 1)
1981
3313
  ]),
1982
- Z(t(w), {
3314
+ pe(a(D), {
1983
3315
  class: "vv-radio__hint",
1984
- params: { value: t(r) }
3316
+ params: { value: a(v) }
1985
3317
  }, null, 8, ["params"])
1986
- ], 10, Qo));
3318
+ ], 10, No));
1987
3319
  }
1988
- }), os = Ye, ss = ["update:modelValue", "change"], as = ["textContent"], ls = { class: "vv-radio-group__wrapper" }, ns = {
3320
+ }), xo = ll, Go = ["update:modelValue", "change"], jo = ["textContent"], Wo = { class: "vv-radio-group__wrapper" }, Uo = {
1989
3321
  name: "VvRadioGroup"
1990
- }, Es = /* @__PURE__ */ N({
1991
- ...ns,
1992
- props: os,
1993
- emits: ss,
1994
- setup(o, { emit: a }) {
1995
- const e = o, n = useSlots(), s = useVModel(e, "modelValue", a), { disabled: d, readonly: r, vertical: f, valid: p, invalid: i } = toRefs(e), l = {
1996
- key: Fe,
1997
- modelValue: s,
1998
- disabled: d,
1999
- readonly: r,
2000
- valid: p,
2001
- invalid: i
2002
- };
2003
- useProvideGroupState(l);
2004
- const { getOptionLabel: c, getOptionValue: u } = useOptions(e), { bemCssClasses: b } = useBemModifiers("vv-radio-group", {
2005
- disabled: d,
2006
- readonly: r,
2007
- horizontal: computed(() => !f.value),
2008
- valid: p,
2009
- invalid: i
2010
- }), g = (v, V) => ({
2011
- id: `${e.name}_opt${V}`,
3322
+ }, _s = /* @__PURE__ */ j({
3323
+ ...Uo,
3324
+ props: xo,
3325
+ emits: Go,
3326
+ setup(t, { emit: l }) {
3327
+ const e = t, s = Ae(), o = et(e, "modelValue", l), { disabled: c, readonly: u, vertical: v, valid: d, invalid: p, modifiers: r } = G(e);
3328
+ lt({
3329
+ key: Kt,
3330
+ modelValue: o,
3331
+ disabled: c,
3332
+ readonly: u,
3333
+ valid: d,
3334
+ invalid: p
3335
+ });
3336
+ const { getOptionLabel: i, getOptionValue: b } = rt(e), _ = X(
3337
+ "vv-radio-group",
3338
+ r,
3339
+ n(() => ({
3340
+ disabled: c.value,
3341
+ readonly: u.value,
3342
+ horizontal: !v.value,
3343
+ valid: d.value,
3344
+ invalid: p.value
3345
+ }))
3346
+ ), k = (y, m) => ({
3347
+ id: `${e.name}_opt${m}`,
2012
3348
  name: e.name,
2013
- label: c(v),
2014
- value: u(v)
2015
- }), { HintSlot: y } = pe(e, n);
2016
- return (v, V) => (m(), _("fieldset", {
2017
- class: U(t(b))
3349
+ label: i(y),
3350
+ value: b(y)
3351
+ }), { HintSlot: A } = Be(e, s);
3352
+ return (y, m) => (f(), g("fieldset", {
3353
+ class: le(a(_))
2018
3354
  }, [
2019
- v.label ? (m(), _("legend", {
3355
+ y.label ? (f(), g("legend", {
2020
3356
  key: 0,
2021
- textContent: B(v.label)
2022
- }, null, 8, as)) : I("", !0),
2023
- R("div", ls, [
2024
- v.options.length > 0 ? (m(!0), _(de, { key: 0 }, fe(v.options, (w, $) => (m(), D(ts, O({ key: $ }, g(w, $)), null, 16))), 128)) : k(v.$slots, "default", { key: 1 })
3357
+ textContent: T(y.label)
3358
+ }, null, 8, jo)) : C("", !0),
3359
+ M("div", Wo, [
3360
+ y.options.length > 0 ? (f(!0), g(ie, { key: 0 }, Ne(y.options, (I, O) => (f(), H(Mo, R({ key: O }, k(I, O)), null, 16))), 128)) : V(y.$slots, "default", { key: 1 })
2025
3361
  ]),
2026
- Z(t(y), { class: "vv-radio-group__hint" })
3362
+ pe(a(A), { class: "vv-radio-group__hint" })
2027
3363
  ], 2));
2028
3364
  }
2029
- }), rs = {
3365
+ }), Fo = {
2030
3366
  hard: "hard",
2031
3367
  soft: "soft"
2032
- }, is = {
3368
+ }, Ko = {
2033
3369
  true: !0,
2034
3370
  false: !1,
2035
3371
  default: "default"
2036
- }, us = ["update:modelValue", "focus", "blur", "keyup"], ds = {
2037
- ...ze,
3372
+ }, zo = ["update:modelValue", "focus", "blur", "keyup"], qo = {
3373
+ ...el,
3374
+ /**
3375
+ * Textarea value
3376
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/textarea#value
3377
+ */
2038
3378
  modelValue: String,
3379
+ /**
3380
+ * The visible width of the text control, in average character widths. If it is specified, it must be a positive integer. If it is not specified, the default value is 20.
3381
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/textarea#cols
3382
+ */
2039
3383
  cols: { type: [String, Number], default: 20 },
3384
+ /**
3385
+ * The number of visible text lines for the control. If it is specified, it must be a positive integer. If it is not specified, the default value is 2.
3386
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/textarea#rows
3387
+ */
2040
3388
  rows: { type: [String, Number], default: 2 },
2041
- wrap: { type: String, default: rs.soft },
2042
- spellcheck: { type: [Boolean, String], default: is.default },
3389
+ /**
3390
+ * Indicates how the control should wrap the value for form submission.
3391
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/textarea#wrap
3392
+ */
3393
+ wrap: { type: String, default: Fo.soft },
3394
+ /**
3395
+ * Specifies whether the <textarea> is subject to spell checking by the underlying browser/OS.
3396
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/textarea#wrap
3397
+ */
3398
+ spellcheck: { type: [Boolean, String], default: Ko.default },
3399
+ /**
3400
+ * If true, the textarea will be resizable
3401
+ */
2043
3402
  resizable: Boolean
2044
- }, cs = ["for"], ps = { class: "vv-textarea__wrapper" }, vs = ["id"], ms = {
3403
+ }, Yo = ["for"], Jo = { class: "vv-textarea__wrapper" }, Xo = {
2045
3404
  key: 0,
3405
+ class: "vv-textarea__input-before"
3406
+ }, Qo = { class: "vv-textarea__inner" }, Zo = ["id"], es = {
3407
+ key: 1,
3408
+ class: "vv-textarea__input-after"
3409
+ }, ts = {
3410
+ key: 2,
2046
3411
  class: "vv-textarea__limit"
2047
- }, fs = {
3412
+ }, ls = {
2048
3413
  name: "VvTextarea"
2049
- }, Rs = /* @__PURE__ */ N({
2050
- ...fs,
2051
- props: ds,
2052
- emits: us,
2053
- setup(o, { emit: a }) {
2054
- const e = o, n = useSlots(), s = ref(), {
2055
- icon: d,
2056
- iconPosition: r,
2057
- label: f,
3414
+ }, Ss = /* @__PURE__ */ j({
3415
+ ...ls,
3416
+ props: qo,
3417
+ emits: zo,
3418
+ setup(t, { emit: l }) {
3419
+ const e = t, s = Ae(), o = N(), {
3420
+ id: c,
3421
+ icon: u,
3422
+ iconPosition: v,
3423
+ label: d,
2058
3424
  modelValue: p,
2059
- count: i,
2060
- valid: l,
2061
- invalid: c,
2062
- loading: u
2063
- } = toRefs(e), b = computed(() => String(e.id || ne())), g = computed(() => `${b.value}-hint`), y = computed(
2064
- () => e.floating && isEmpty(e.placeholder) ? " " : e.placeholder
2065
- ), v = useDebouncedInput(p, a, e.debounce), { hasIcon: V, hasIconLeft: w, hasIconRight: $ } = useComponentIcon(
2066
- d,
2067
- r
2068
- ), { focused: M } = useComponentFocus(s, a), C = useElementVisibility(s);
2069
- watch(C, (W) => {
2070
- W && e.autofocus && (M.value = !0);
3425
+ count: r,
3426
+ valid: i,
3427
+ invalid: b,
3428
+ loading: _,
3429
+ modifiers: k
3430
+ } = G(e), A = Le(c), y = n(() => `${A.value}-hint`), m = n(
3431
+ () => e.floating && ge(e.placeholder) ? " " : e.placeholder
3432
+ ), I = nl(p, l, e.debounce), { hasIcon: O, hasIconBefore: D, hasIconAfter: L } = ut(
3433
+ u,
3434
+ v
3435
+ ), { focused: x } = it(o, l), w = $t(o);
3436
+ ve(w, (J) => {
3437
+ J && e.autofocus && (x.value = !0);
2071
3438
  });
2072
- const { formatted: H } = useTextCount(v, {
3439
+ const { formatted: se } = rl(I, {
2073
3440
  mode: e.count,
2074
3441
  upperLimit: e.maxlength,
2075
3442
  lowerLimit: e.minlength
2076
- }), X = computed(() => !e.disabled && !e.readonly), T = computed(
2077
- () => X.value ? e.tabindex : -1
2078
- ), x = computed(() => !isEmpty(p)), J = computed(() => {
3443
+ }), P = n(() => !e.disabled && !e.readonly), W = n(
3444
+ () => P.value ? e.tabindex : -1
3445
+ ), F = n(() => !ge(p)), ue = n(() => {
2079
3446
  if (e.invalid === !0)
2080
3447
  return !0;
2081
3448
  if (e.valid === !0)
2082
3449
  return !1;
2083
- }), { HintSlot: ee, hasHint: te, hasInvalid: Q } = pe(e, n), { bemCssClasses: ie } = useBemModifiers("vv-textarea", {
2084
- modifiers: e.modifiers,
2085
- valid: l,
2086
- invalid: c,
2087
- loading: u,
2088
- disabled: e.disabled,
2089
- readonly: e.readonly,
2090
- iconLeft: w,
2091
- iconRight: $,
2092
- floating: e.floating && !isEmpty(e.label),
2093
- dirty: x,
2094
- focused: M,
2095
- resizable: e.resizable
2096
- }), oe = computed(
3450
+ }), { HintSlot: he, hasHint: ye, hasInvalid: ne } = Be(e, s), de = X(
3451
+ "vv-textarea",
3452
+ k,
3453
+ n(() => ({
3454
+ valid: i.value,
3455
+ invalid: b.value,
3456
+ loading: _.value,
3457
+ disabled: e.disabled,
3458
+ readonly: e.readonly,
3459
+ "icon-before": D.value,
3460
+ "icon-after": L.value,
3461
+ floating: e.floating && !ge(e.label),
3462
+ dirty: F.value,
3463
+ focused: x.value,
3464
+ resizable: e.resizable
3465
+ }))
3466
+ ), _e = n(
2097
3467
  () => ({
2098
3468
  name: e.name,
2099
- placeholder: y.value,
2100
- tabindex: T.value,
3469
+ placeholder: m.value,
3470
+ tabindex: W.value,
2101
3471
  disabled: e.disabled,
2102
3472
  readonly: e.readonly,
2103
3473
  required: e.required,
@@ -2108,80 +3478,87 @@ const Qo = ["for"], Zo = ["id", "name", "disabled", "value", "tabindex", "aria-i
2108
3478
  rows: e.rows,
2109
3479
  wrap: e.wrap,
2110
3480
  spellcheck: e.spellcheck,
2111
- "aria-invalid": J.value,
2112
- "aria-describedby": !Q.value && te.value ? g.value : void 0,
2113
- "aria-errormessage": Q.value ? g.value : void 0
3481
+ "aria-invalid": ue.value,
3482
+ "aria-describedby": !ne.value && ye.value ? y.value : void 0,
3483
+ "aria-errormessage": ne.value ? y.value : void 0
2114
3484
  })
2115
- ), se = computed(() => ({
3485
+ ), re = n(() => ({
2116
3486
  valid: e.valid,
2117
3487
  invalid: e.invalid,
2118
3488
  modelValue: e.modelValue,
2119
3489
  hintLabel: e.hintLabel,
2120
3490
  maxlength: e.maxlength,
2121
3491
  minlength: e.minlength,
2122
- clear: ae
2123
- })), ae = () => {
2124
- v.value = void 0;
3492
+ clear: Ve
3493
+ })), Ve = () => {
3494
+ I.value = void 0;
2125
3495
  };
2126
- return (W, P) => (m(), _("div", {
2127
- class: U(t(ie))
3496
+ return (J, B) => (f(), g("div", {
3497
+ class: le(a(de))
2128
3498
  }, [
2129
- t(f) ? (m(), _("label", {
3499
+ a(d) ? (f(), g("label", {
2130
3500
  key: 0,
2131
- for: t(b),
3501
+ for: a(A),
2132
3502
  class: "vv-textarea__label"
2133
- }, B(t(f)), 9, cs)) : I("", !0),
2134
- R("div", ps, [
2135
- k(W.$slots, "before", F(Y(t(se))), () => [
2136
- t(w) ? (m(), D(G, O({
3503
+ }, T(a(d)), 9, Yo)) : C("", !0),
3504
+ M("div", Jo, [
3505
+ J.$slots.before ? (f(), g("div", Xo, [
3506
+ V(J.$slots, "before", K(z(a(re))))
3507
+ ])) : C("", !0),
3508
+ M("div", Qo, [
3509
+ a(D) ? (f(), H(ee, R({
2137
3510
  key: 0,
2138
- class: "vv-textarea__icon-left"
2139
- }, t(V)), null, 16)) : I("", !0)
2140
- ]),
2141
- ve(R("textarea", O({
2142
- id: t(b),
2143
- ref_key: "textarea",
2144
- ref: s,
2145
- "onUpdate:modelValue": P[0] || (P[0] = (j) => be(v) ? v.value = j : null)
2146
- }, t(oe), {
2147
- onKeyup: P[1] || (P[1] = (j) => a("keyup", j))
2148
- }), null, 16, vs), [
2149
- [xe, t(v)]
2150
- ]),
2151
- k(W.$slots, "after", F(Y(t(se))), () => [
2152
- t($) ? (m(), D(G, F(O({ key: 0 }, t(V))), null, 16)) : I("", !0)
3511
+ class: "vv-textarea__icon"
3512
+ }, a(O)), null, 16)) : C("", !0),
3513
+ Oe(M("textarea", R({
3514
+ id: a(A),
3515
+ ref_key: "textarea",
3516
+ ref: o,
3517
+ "onUpdate:modelValue": B[0] || (B[0] = (Q) => Ee(I) ? I.value = Q : null)
3518
+ }, a(_e), {
3519
+ onKeyup: B[1] || (B[1] = (Q) => l("keyup", Q))
3520
+ }), null, 16, Zo), [
3521
+ [Ht, a(I)]
3522
+ ]),
3523
+ a(L) ? (f(), H(ee, R({
3524
+ key: 1,
3525
+ class: "vv-textarea__icon vv-textarea__icon-after"
3526
+ }, a(O)), null, 16)) : C("", !0)
2153
3527
  ]),
2154
- t(i) ? (m(), _("span", ms, [
2155
- k(W.$slots, "count", F(Y(t(se))), () => [
2156
- q(B(t(H)), 1)
3528
+ J.$slots.after ? (f(), g("div", es, [
3529
+ V(J.$slots, "after", K(z(a(re))))
3530
+ ])) : C("", !0),
3531
+ a(r) ? (f(), g("span", ts, [
3532
+ V(J.$slots, "count", K(z(a(re))), () => [
3533
+ Y(T(a(se)), 1)
2157
3534
  ])
2158
- ])) : I("", !0)
3535
+ ])) : C("", !0)
2159
3536
  ]),
2160
- Z(t(ee), {
2161
- id: t(g),
3537
+ pe(a(he), {
3538
+ id: a(y),
2162
3539
  class: "vv-textarea__hint"
2163
3540
  }, null, 8, ["id"])
2164
3541
  ], 2));
2165
3542
  }
2166
3543
  });
2167
3544
  export {
2168
- St as VvAccordion,
2169
- ys as VvAccordionGroup,
2170
- _s as VvBadge,
2171
- Ss as VvBreadcrumb,
2172
- Vs as VvButton,
2173
- $s as VvButtonGroup,
2174
- Cs as VvCard,
2175
- oo as VvCheckbox,
2176
- ks as VvCheckboxGroup,
2177
- As as VvCombobox,
2178
- Ps as VvDialog,
2179
- bo as VvDropdown,
2180
- G as VvIcon,
2181
- ws as VvInputText,
2182
- Is as VvProgress,
2183
- ts as VvRadio,
2184
- Es as VvRadioGroup,
2185
- ko as VvSelect,
2186
- Rs as VvTextarea
3545
+ Rl as VvAccordion,
3546
+ ds as VvAccordionGroup,
3547
+ Yl as VvBadge,
3548
+ cs as VvBreadcrumb,
3549
+ vs as VvButton,
3550
+ fs as VvButtonGroup,
3551
+ ps as VvCard,
3552
+ Ea as VvCheckbox,
3553
+ ms as VvCheckboxGroup,
3554
+ bs as VvCombobox,
3555
+ hs as VvDialog,
3556
+ sl as VvDropdown,
3557
+ ee as VvIcon,
3558
+ ys as VvInputText,
3559
+ gs as VvProgress,
3560
+ Mo as VvRadio,
3561
+ _s as VvRadioGroup,
3562
+ oo as VvSelect,
3563
+ Ss as VvTextarea
2187
3564
  };