@8wave/ai-elements 0.126.0-beta.36 → 0.126.0-beta.37

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 (131) hide show
  1. package/dist/_chunks/{PkChatbotFilePreview-Cw3va5vW.js → PkChatbotFilePreview-CLUH7cTq.js} +2 -2
  2. package/dist/_chunks/{PkChatbotFilePreview-Cw3va5vW.js.map → PkChatbotFilePreview-CLUH7cTq.js.map} +1 -1
  3. package/dist/_chunks/{PkEditorRadioButtons-CY0D_EkU.js → PkEditorRadioButtons-YSngp-Wn.js} +2 -2
  4. package/dist/_chunks/{PkEditorRadioButtons-CY0D_EkU.js.map → PkEditorRadioButtons-YSngp-Wn.js.map} +1 -1
  5. package/dist/_chunks/{PkFilePreview-D4TgY0T9.js → PkFilePreview-BHqmp1EW.js} +5 -5
  6. package/dist/_chunks/{PkFilePreview-D4TgY0T9.js.map → PkFilePreview-BHqmp1EW.js.map} +1 -1
  7. package/dist/_chunks/{PkFilePreviewDialog-8H1GeV91.js → PkFilePreviewDialog-BHAgVlKs.js} +3 -3
  8. package/dist/_chunks/{PkFilePreviewDialog-8H1GeV91.js.map → PkFilePreviewDialog-BHAgVlKs.js.map} +1 -1
  9. package/dist/_chunks/{PkHeldImage-B6UYQ8Ox.js → PkHeldImage-WGwFM77v.js} +2 -2
  10. package/dist/_chunks/{PkHeldImage-B6UYQ8Ox.js.map → PkHeldImage-WGwFM77v.js.map} +1 -1
  11. package/dist/_chunks/{PkImageEditorDialog-BqHjVX97.js → PkImageEditorDialog-BDwL39Du.js} +18 -18
  12. package/dist/_chunks/{PkImageEditorDialog-BqHjVX97.js.map → PkImageEditorDialog-BDwL39Du.js.map} +1 -1
  13. package/dist/_chunks/{PkLazyImg-D3XOz-dS.js → PkLazyImg-DL7hxjyy.js} +2 -2
  14. package/dist/_chunks/{PkLazyImg-D3XOz-dS.js.map → PkLazyImg-DL7hxjyy.js.map} +1 -1
  15. package/dist/_chunks/{PkSelectionActions-BxUXWFNK.js → PkSelectionActions-DLsZ8-gW.js} +2 -2
  16. package/dist/_chunks/{PkSelectionActions-BxUXWFNK.js.map → PkSelectionActions-DLsZ8-gW.js.map} +1 -1
  17. package/dist/_chunks/{PkToolChatFile-CSBzfuyE.js → PkToolChatFile-62j1S0Pq.js} +3 -3
  18. package/dist/_chunks/{PkToolChatFile-CSBzfuyE.js.map → PkToolChatFile-62j1S0Pq.js.map} +1 -1
  19. package/dist/_chunks/{PkToolRequestGeolocation-DNzNRszE.js → PkToolRequestGeolocation-B9EM_K6O.js} +2 -2
  20. package/dist/_chunks/{PkToolRequestGeolocation-DNzNRszE.js.map → PkToolRequestGeolocation-B9EM_K6O.js.map} +1 -1
  21. package/dist/_chunks/{PkToolRequestOAuthConnection-BDxYXz4s.js → PkToolRequestOAuthConnection-CfjfqCHX.js} +3 -3
  22. package/dist/_chunks/{PkToolRequestOAuthConnection-BDxYXz4s.js.map → PkToolRequestOAuthConnection-CfjfqCHX.js.map} +1 -1
  23. package/dist/_chunks/{PkToolShareDocument-Kq7SFbw5.js → PkToolShareDocument-CYBU4LPO.js} +3 -3
  24. package/dist/_chunks/{PkToolShareDocument-Kq7SFbw5.js.map → PkToolShareDocument-CYBU4LPO.js.map} +1 -1
  25. package/dist/_chunks/{PkToolShowArtifact-d5tKvM01.js → PkToolShowArtifact-I_QZS7Pf.js} +2 -2
  26. package/dist/_chunks/{PkToolShowArtifact-d5tKvM01.js.map → PkToolShowArtifact-I_QZS7Pf.js.map} +1 -1
  27. package/dist/_chunks/{PkToolShowCalendarEvent-fMI-paCP.js → PkToolShowCalendarEvent-js9lh-cX.js} +3 -3
  28. package/dist/_chunks/{PkToolShowCalendarEvent-fMI-paCP.js.map → PkToolShowCalendarEvent-js9lh-cX.js.map} +1 -1
  29. package/dist/_chunks/{PkToolShowChart-lLXuHRJu.js → PkToolShowChart-BalU3bxm.js} +3 -3
  30. package/dist/_chunks/{PkToolShowChart-lLXuHRJu.js.map → PkToolShowChart-BalU3bxm.js.map} +1 -1
  31. package/dist/_chunks/{PkToolShowComparison-CKSqPgJo.js → PkToolShowComparison-DeO7cMeF.js} +3 -3
  32. package/dist/_chunks/{PkToolShowComparison-CKSqPgJo.js.map → PkToolShowComparison-DeO7cMeF.js.map} +1 -1
  33. package/dist/_chunks/{PkToolShowContactForm-Bni1QzXV.js → PkToolShowContactForm-BeJ5GR6t.js} +5 -5
  34. package/dist/_chunks/{PkToolShowContactForm-Bni1QzXV.js.map → PkToolShowContactForm-BeJ5GR6t.js.map} +1 -1
  35. package/dist/_chunks/{PkToolShowDiagram-DWVSCu33.js → PkToolShowDiagram-j3TTzZ5I.js} +3 -3
  36. package/dist/_chunks/{PkToolShowDiagram-DWVSCu33.js.map → PkToolShowDiagram-j3TTzZ5I.js.map} +1 -1
  37. package/dist/_chunks/{PkToolShowEmail-D6Mw24jB.js → PkToolShowEmail-CQ4uyty9.js} +3 -3
  38. package/dist/_chunks/{PkToolShowEmail-D6Mw24jB.js.map → PkToolShowEmail-CQ4uyty9.js.map} +1 -1
  39. package/dist/_chunks/{PkToolShowForm-CFXtO0j4.js → PkToolShowForm-B9VDoS_W.js} +15 -15
  40. package/dist/_chunks/{PkToolShowForm-CFXtO0j4.js.map → PkToolShowForm-B9VDoS_W.js.map} +1 -1
  41. package/dist/_chunks/{PkToolShowImageGallery-Ci_Kg44s.js → PkToolShowImageGallery-DFuc5IJ1.js} +3 -3
  42. package/dist/_chunks/{PkToolShowImageGallery-Ci_Kg44s.js.map → PkToolShowImageGallery-DFuc5IJ1.js.map} +1 -1
  43. package/dist/_chunks/{PkToolShowLocation-DV0puCbD.js → PkToolShowLocation-PThC5tCV.js} +3 -3
  44. package/dist/_chunks/{PkToolShowLocation-DV0puCbD.js.map → PkToolShowLocation-PThC5tCV.js.map} +1 -1
  45. package/dist/_chunks/{PkToolShowMessage-Bq2dbSy1.js → PkToolShowMessage-9mlI4IQ6.js} +3 -3
  46. package/dist/_chunks/{PkToolShowMessage-Bq2dbSy1.js.map → PkToolShowMessage-9mlI4IQ6.js.map} +1 -1
  47. package/dist/_chunks/{PkToolShowProductList-BWWzkWWA.js → PkToolShowProductList-C2EJKYOV.js} +4 -4
  48. package/dist/_chunks/{PkToolShowProductList-BWWzkWWA.js.map → PkToolShowProductList-C2EJKYOV.js.map} +1 -1
  49. package/dist/_chunks/{PkToolShowQrCode-DZkJIyMF.js → PkToolShowQrCode-DQiVo4Vh.js} +3 -3
  50. package/dist/_chunks/{PkToolShowQrCode-DZkJIyMF.js.map → PkToolShowQrCode-DQiVo4Vh.js.map} +1 -1
  51. package/dist/_chunks/{PkToolShowSources-Dv7hbDyy.js → PkToolShowSources-BL3DnfcN.js} +3 -3
  52. package/dist/_chunks/{PkToolShowSources-Dv7hbDyy.js.map → PkToolShowSources-BL3DnfcN.js.map} +1 -1
  53. package/dist/_chunks/{PkToolShowSuggestedReply-B_dRrZfj.js → PkToolShowSuggestedReply-DLgtjBJ1.js} +2 -2
  54. package/dist/_chunks/{PkToolShowSuggestedReply-B_dRrZfj.js.map → PkToolShowSuggestedReply-DLgtjBJ1.js.map} +1 -1
  55. package/dist/_chunks/{PkToolShowVideo-DLgQjTq_.js → PkToolShowVideo-DcWXDcOZ.js} +3 -3
  56. package/dist/_chunks/{PkToolShowVideo-DLgQjTq_.js.map → PkToolShowVideo-DcWXDcOZ.js.map} +1 -1
  57. package/dist/_chunks/{PkToolShowWeather-HElfkyLV.js → PkToolShowWeather-DLT47oC6.js} +2 -2
  58. package/dist/_chunks/{PkToolShowWeather-HElfkyLV.js.map → PkToolShowWeather-DLT47oC6.js.map} +1 -1
  59. package/dist/_chunks/{PkToolShowWebPages-XxcYBQpr.js → PkToolShowWebPages-CPqMC6qt.js} +4 -4
  60. package/dist/_chunks/{PkToolShowWebPages-XxcYBQpr.js.map → PkToolShowWebPages-CPqMC6qt.js.map} +1 -1
  61. package/dist/_chunks/{VvButtonLocalized-BgY-V26j.js → VvButtonLocalized-D_gumqSJ.js} +2 -2
  62. package/dist/_chunks/{VvButtonLocalized-BgY-V26j.js.map → VvButtonLocalized-D_gumqSJ.js.map} +1 -1
  63. package/dist/_chunks/{VvCheckbox.es-KisDJtH_.js → VvCheckbox.es-D44kGZc-.js} +2 -2
  64. package/dist/_chunks/{VvCheckbox.es-KisDJtH_.js.map → VvCheckbox.es-D44kGZc-.js.map} +1 -1
  65. package/dist/_chunks/{VvCheckboxGroup.es-CIVHYElp.js → VvCheckboxGroup.es-Da5Vuel0.js} +2 -2
  66. package/dist/_chunks/{VvCheckboxGroup.es-CIVHYElp.js.map → VvCheckboxGroup.es-Da5Vuel0.js.map} +1 -1
  67. package/dist/_chunks/{VvCombobox.es-DybZ6U_6.js → VvCombobox.es-BJzmLeTh.js} +467 -403
  68. package/dist/_chunks/VvCombobox.es-BJzmLeTh.js.map +1 -0
  69. package/dist/_chunks/{VvInputText.es-DFSPWDcH.js → VvInputText.es-CHcdm2K-.js} +280 -218
  70. package/dist/_chunks/VvInputText.es-CHcdm2K-.js.map +1 -0
  71. package/dist/_chunks/{VvRadio.es-vrNSXb3X.js → VvRadio.es-B3IskaN4.js} +2 -2
  72. package/dist/_chunks/{VvRadio.es-vrNSXb3X.js.map → VvRadio.es-B3IskaN4.js.map} +1 -1
  73. package/dist/_chunks/{VvRadioGroup.es-DalxMbrj.js → VvRadioGroup.es-CBivcD0v.js} +2 -2
  74. package/dist/_chunks/{VvRadioGroup.es-DalxMbrj.js.map → VvRadioGroup.es-CBivcD0v.js.map} +1 -1
  75. package/dist/_chunks/{VvSelect.es-D55xq4Lw.js → VvSelect.es-CAVvkyxB.js} +2 -2
  76. package/dist/_chunks/{VvSelect.es-D55xq4Lw.js.map → VvSelect.es-CAVvkyxB.js.map} +1 -1
  77. package/dist/_chunks/{VvTextarea.es-BOhkaXfY.js → VvTextarea.es-CgvZOWO4.js} +446 -384
  78. package/dist/_chunks/VvTextarea.es-CgvZOWO4.js.map +1 -0
  79. package/dist/_chunks/{index.es-BYhSukum.js → index.es-CEYwDeKz.js} +126 -66
  80. package/dist/_chunks/index.es-CEYwDeKz.js.map +1 -0
  81. package/dist/_chunks/{index.es-CPvSmI-B.js → index.es-DDdkqLT6.js} +10 -10
  82. package/dist/_chunks/{index.es-CPvSmI-B.js.map → index.es-DDdkqLT6.js.map} +1 -1
  83. package/dist/ai-elements.es.js +377 -376
  84. package/dist/ai-elements.es.js.map +1 -1
  85. package/dist-vue/PkChatbot.js +1 -1
  86. package/dist-vue/PkChatbotAuth.js +1 -1
  87. package/dist-vue/PkChatbotFeedbackForm.js +1 -1
  88. package/dist-vue/PkChatbotMessages.js +1 -1
  89. package/dist-vue/PkChatbotViewChat.js +1 -1
  90. package/dist-vue/PkChatbotViewConversations.js +1 -1
  91. package/dist-vue/PkChatbotViewProfile.js +1 -1
  92. package/dist-vue/_chunks/PkChatbot-aCgj2DMu.js +326 -0
  93. package/dist-vue/_chunks/PkChatbot-aCgj2DMu.js.map +1 -0
  94. package/dist-vue/_chunks/{PkChatbotAuth-449QUBoC.js → PkChatbotAuth-C5agN8ht.js} +2 -2
  95. package/dist-vue/_chunks/{PkChatbotAuth-449QUBoC.js.map → PkChatbotAuth-C5agN8ht.js.map} +1 -1
  96. package/dist-vue/_chunks/{PkChatbotFeedbackForm-DdQQlAr1.js → PkChatbotFeedbackForm-DjsLxYjT.js} +2 -2
  97. package/dist-vue/_chunks/{PkChatbotFeedbackForm-DdQQlAr1.js.map → PkChatbotFeedbackForm-DjsLxYjT.js.map} +1 -1
  98. package/dist-vue/_chunks/{PkChatbotMessages-_-h-egX7.js → PkChatbotMessages-CG3UZYcP.js} +3 -3
  99. package/dist-vue/_chunks/{PkChatbotMessages-_-h-egX7.js.map → PkChatbotMessages-CG3UZYcP.js.map} +1 -1
  100. package/dist-vue/_chunks/{PkChatbotViewChat-Bg-Op2Oe.js → PkChatbotViewChat-IU3HJpxG.js} +3 -3
  101. package/dist-vue/_chunks/{PkChatbotViewChat-Bg-Op2Oe.js.map → PkChatbotViewChat-IU3HJpxG.js.map} +1 -1
  102. package/dist-vue/_chunks/PkChatbotViewConversations-4zGrp7Fo.js +197 -0
  103. package/dist-vue/_chunks/PkChatbotViewConversations-4zGrp7Fo.js.map +1 -0
  104. package/dist-vue/_chunks/PkChatbotViewProfile-BrZ7oiUY.js +85 -0
  105. package/dist-vue/_chunks/PkChatbotViewProfile-BrZ7oiUY.js.map +1 -0
  106. package/dist-vue/_chunks/{PkFilePreview-DydUI1G2.js → PkFilePreview-WqS-s3vk.js} +2 -2
  107. package/dist-vue/_chunks/{PkFilePreview-DydUI1G2.js.map → PkFilePreview-WqS-s3vk.js.map} +1 -1
  108. package/dist-vue/_chunks/{PkFilePreviewDialog-BuG1whsJ.js → PkFilePreviewDialog-BIaTAK05.js} +2 -2
  109. package/dist-vue/_chunks/{PkFilePreviewDialog-BuG1whsJ.js.map → PkFilePreviewDialog-BIaTAK05.js.map} +1 -1
  110. package/dist-vue/_chunks/{PkToolShowContactForm-D0lDC69x.js → PkToolShowContactForm-DFufPNnQ.js} +2 -2
  111. package/dist-vue/_chunks/{PkToolShowContactForm-D0lDC69x.js.map → PkToolShowContactForm-DFufPNnQ.js.map} +1 -1
  112. package/dist-vue/_chunks/{index.es-CwEgvvQD.js → index.es-BmedAjkp.js} +2 -2
  113. package/dist-vue/_chunks/{index.es-CwEgvvQD.js.map → index.es-BmedAjkp.js.map} +1 -1
  114. package/dist-vue/composables.js +8 -6
  115. package/dist-vue/composables.js.map +1 -1
  116. package/dist-vue/index.js +10 -10
  117. package/dist-vue/locales.js +20 -16
  118. package/dist-vue/packages/components/src/chat/PkChatbot.d.ts +7 -7
  119. package/package.json +2 -2
  120. package/dist/_chunks/VvCombobox.es-DybZ6U_6.js.map +0 -1
  121. package/dist/_chunks/VvInputText.es-DFSPWDcH.js.map +0 -1
  122. package/dist/_chunks/VvTextarea.es-BOhkaXfY.js.map +0 -1
  123. package/dist/_chunks/index.es-BYhSukum.js.map +0 -1
  124. package/dist-vue/_chunks/PkChatbot-CFJmT4nN.js +0 -299
  125. package/dist-vue/_chunks/PkChatbot-CFJmT4nN.js.map +0 -1
  126. package/dist-vue/_chunks/PkChatbotViewConversations--smzyxqN.js +0 -226
  127. package/dist-vue/_chunks/PkChatbotViewConversations--smzyxqN.js.map +0 -1
  128. package/dist-vue/_chunks/PkChatbotViewProfile-Cn7IQfnQ.js +0 -86
  129. package/dist-vue/_chunks/PkChatbotViewProfile-Cn7IQfnQ.js.map +0 -1
  130. package/dist-vue/_chunks/chatbotProfileContext-b-nve-mR.js +0 -5
  131. package/dist-vue/_chunks/chatbotProfileContext-b-nve-mR.js.map +0 -1
@@ -1,10 +1,10 @@
1
- import { A as e, B as t, D as n, Dt as r, E as i, Et as a, F as o, G as s, H as c, K as l, L as u, M as d, Ot as f, P as p, Q as m, S as ee, St as h, Tt as g, V as te, Y as ne, _, b as v, c as re, d as y, et as ie, f as ae, g as b, gt as x, h as S, k as C, kt as w, l as oe, nt as se, ot as ce, pt as le, q as ue, r as T, t as de, tt as E, ut as D, v as O, w as k, wt as A, x as fe, xt as pe, y as j, z as M } from "./vue.runtime.esm-bundler-DZgpK-ja.js";
2
- import { a as me, c as he, i as ge, l as _e, n as ve, o as ye, r as be, s as N, t as xe } from "./floating-ui.vue-SbFDfAS7.js";
3
- import { S as Se, c as P, f as F, g as I, n as Ce, p as we, r as L, u as Te, x as Ee } from "./dist-CR8l0inH.js";
4
- import { a as R, i as De, t as z } from "./iconify-BsIVfdEw.js";
5
- // ../../node_modules/.pnpm/@volverjs+ui-vue@0.0.26_@json-render+core@0.19.0_zod@4.6.7__@volverjs+style@0.1.32_@vue_3ab70fef148227ce501622bd10a5d9b4/node_modules/@volverjs/ui-vue/dist/components/VvTextarea/VvTextarea.es.js
6
- C(), T(), ce(), g();
7
- var Oe = {
1
+ import { A as e, B as t, D as n, Dt as r, E as i, Et as a, F as o, G as s, H as c, K as l, L as u, M as d, Ot as f, P as p, Q as m, S as ee, St as h, Tt as g, V as te, Y as ne, _, b as v, c as re, d as ie, et as ae, f as oe, g as y, gt as b, h as x, k as S, kt as C, l as se, nt as ce, ot as le, pt as ue, q as de, r as w, t as fe, tt as T, ut as E, v as D, w as O, wt as k, x as pe, xt as me, y as A, z as j } from "./vue.runtime.esm-bundler-DZgpK-ja.js";
2
+ import { a as he, c as ge, i as _e, l as ve, n as ye, o as be, r as xe, s as M, t as Se } from "./floating-ui.vue-SbFDfAS7.js";
3
+ import { S as Ce, c as N, f as P, g as we, n as Te, p as Ee, r as F, u as De, x as Oe } from "./dist-CR8l0inH.js";
4
+ import { a as ke, i as Ae, t as I } from "./iconify-BsIVfdEw.js";
5
+ // ../../node_modules/.pnpm/@volverjs+ui-vue@0.0.28_@json-render+core@0.19.0_zod@4.6.7__@volverjs+style@0.1.32_@vue_113cf0a066eeca009eded43485818201/node_modules/@volverjs/ui-vue/dist/components/VvTextarea/VvTextarea.es.js
6
+ S(), w(), le(), g();
7
+ var je = {
8
8
  showPassword: "eye-on",
9
9
  hidePassword: "eye-off",
10
10
  showDatePicker: "calendar",
@@ -15,27 +15,27 @@ var Oe = {
15
15
  remove: "trash",
16
16
  edit: "edit",
17
17
  download: "download"
18
- }, ke = { prefix: "normal" }, B = /* @__PURE__ */ (function(e) {
18
+ }, Me = { prefix: "normal" }, L = /* @__PURE__ */ (function(e) {
19
19
  return e.local = "local", e.session = "session", e;
20
- })({}), V = /* @__PURE__ */ (function(e) {
20
+ })({}), R = /* @__PURE__ */ (function(e) {
21
21
  return e.absolute = "absolute", e.fixed = "fixed", e;
22
- })({}), H = /* @__PURE__ */ (function(e) {
22
+ })({}), z = /* @__PURE__ */ (function(e) {
23
23
  return e.left = "left", e.right = "right", e.top = "top", e.bottom = "bottom", e;
24
- })({}), Ae = /* @__PURE__ */ (function(e) {
24
+ })({}), Ne = /* @__PURE__ */ (function(e) {
25
25
  return e.topStart = "top-start", e.topEnd = "top-end", e.bottomStart = "bottom-start", e.bottomEnd = "bottom-end", e.leftStart = "left-start", e.leftEnd = "left-end", e.rightStart = "right-start", e.rightEnd = "right-end", e;
26
- })({}), U = /* @__PURE__ */ (function(e) {
26
+ })({}), B = /* @__PURE__ */ (function(e) {
27
27
  return e.before = "before", e.after = "after", e;
28
- })({}), je = /* @__PURE__ */ (function(e) {
28
+ })({}), Pe = /* @__PURE__ */ (function(e) {
29
29
  return e.button = "button", e.submit = "submit", e.reset = "reset", e;
30
- })({}), W = /* @__PURE__ */ (function(e) {
30
+ })({}), V = /* @__PURE__ */ (function(e) {
31
31
  return e.nuxtLink = "nuxt-link", e.routerLink = "router-link", e.a = "a", e.button = "button", e;
32
- })({}), Me = /* @__PURE__ */ (function(e) {
32
+ })({}), Fe = /* @__PURE__ */ (function(e) {
33
33
  return e.button = "button", e.link = "link", e.menuitem = "menuitem", e;
34
- })({}), G = /* @__PURE__ */ (function(e) {
34
+ })({}), H = /* @__PURE__ */ (function(e) {
35
35
  return e.listbox = "listbox", e.menu = "menu", e;
36
- })({}), K = /* @__PURE__ */ (function(e) {
36
+ })({}), U = /* @__PURE__ */ (function(e) {
37
37
  return e.option = "option", e.presentation = "presentation", e;
38
- })({}), q = /* @__PURE__ */ Symbol.for("volver"), J = /* @__PURE__ */ Symbol.for("dropdownTrigger"), Y = /* @__PURE__ */ Symbol.for("dropdownItem"), Ne = /* @__PURE__ */ Symbol.for("dropdownAction"), Pe = {
38
+ })({}), W = /* @__PURE__ */ Symbol.for("volver"), G = /* @__PURE__ */ Symbol.for("dropdownTrigger"), K = /* @__PURE__ */ Symbol.for("dropdownItem"), q = /* @__PURE__ */ Symbol.for("dropdownAction"), Ie = {
39
39
  to: { type: [String, Object] },
40
40
  href: String,
41
41
  target: String,
@@ -43,7 +43,7 @@ var Oe = {
43
43
  type: String,
44
44
  default: "noopener noreferrer"
45
45
  }
46
- }, Fe = {
46
+ }, Le = {
47
47
  valid: {
48
48
  type: Boolean,
49
49
  default: !1
@@ -52,7 +52,7 @@ var Oe = {
52
52
  type: [String, Array],
53
53
  default: void 0
54
54
  }
55
- }, Ie = {
55
+ }, Re = {
56
56
  invalid: {
57
57
  type: Boolean,
58
58
  default: !1
@@ -61,7 +61,7 @@ var Oe = {
61
61
  type: [String, Array],
62
62
  default: void 0
63
63
  }
64
- }, Le = {
64
+ }, ze = {
65
65
  loading: {
66
66
  type: Boolean,
67
67
  default: !1
@@ -70,30 +70,30 @@ var Oe = {
70
70
  type: String,
71
71
  default: "Loading..."
72
72
  }
73
- }, X = { disabled: {
73
+ }, J = { disabled: {
74
74
  type: Boolean,
75
75
  default: !1
76
- } }, Re = { required: {
76
+ } }, Be = { required: {
77
77
  type: Boolean,
78
78
  default: !1
79
- } }, Z = { selected: {
79
+ } }, Ve = { selected: {
80
80
  type: Boolean,
81
81
  default: !1
82
- } }, ze = { active: {
82
+ } }, He = { active: {
83
83
  type: Boolean,
84
84
  default: !1
85
- } }, Be = { current: {
85
+ } }, Y = { current: {
86
86
  type: Boolean,
87
87
  default: !1
88
88
  } };
89
- Oe.clear;
90
- var Ve = { pressed: {
89
+ je.clear;
90
+ var Ue = { pressed: {
91
91
  type: Boolean,
92
92
  default: !1
93
- } }, Q = { label: {
93
+ } }, X = { label: {
94
94
  type: [String, Number],
95
95
  default: void 0
96
- } }, He = {
96
+ } }, Z = {
97
97
  ariaLabel: {
98
98
  type: String,
99
99
  default: void 0
@@ -106,7 +106,7 @@ var Ve = { pressed: {
106
106
  type: String,
107
107
  default: void 0
108
108
  }
109
- }, Ue = { readonly: {
109
+ }, Q = { readonly: {
110
110
  type: Boolean,
111
111
  default: !1
112
112
  } }, $ = { modifiers: {
@@ -151,8 +151,8 @@ var Ve = { pressed: {
151
151
  },
152
152
  iconPosition: {
153
153
  type: String,
154
- default: U.before,
155
- validator: (e) => Object.values(U).includes(e)
154
+ default: B.before,
155
+ validator: (e) => Object.values(B).includes(e)
156
156
  }
157
157
  }, Ye = { tabindex: {
158
158
  type: [String, Number],
@@ -166,13 +166,13 @@ var Ve = { pressed: {
166
166
  } }, Qe = { id: [String, Number] }, $e = {
167
167
  placement: {
168
168
  type: String,
169
- default: H.bottom,
170
- validator: (e) => Object.values(H).includes(e) || Object.values(Ae).includes(e)
169
+ default: z.bottom,
170
+ validator: (e) => Object.values(z).includes(e) || Object.values(Ne).includes(e)
171
171
  },
172
172
  strategy: {
173
173
  type: String,
174
174
  default: void 0,
175
- validator: (e) => Object.values(V).includes(e)
175
+ validator: (e) => Object.values(R).includes(e)
176
176
  },
177
177
  transitionName: {
178
178
  type: String,
@@ -239,19 +239,19 @@ var Ve = { pressed: {
239
239
  ...tt,
240
240
  ...nt,
241
241
  ...Ye,
242
- ...X,
243
- ...Ue,
244
- ...Fe,
245
- ...Ie,
246
- ...We,
242
+ ...J,
243
+ ...Q,
247
244
  ...Le,
245
+ ...Re,
246
+ ...We,
247
+ ...ze,
248
248
  ...$,
249
249
  ...Ke,
250
250
  ...qe,
251
251
  ...Je,
252
252
  ...Xe,
253
- ...Q,
254
- ...He,
253
+ ...X,
254
+ ...Z,
255
255
  minlength: {
256
256
  type: [String, Number],
257
257
  default: void 0
@@ -264,44 +264,44 @@ var Ve = { pressed: {
264
264
  type: String,
265
265
  default: void 0
266
266
  },
267
- ...Re
267
+ ...Be
268
268
  };
269
269
  ({
270
270
  ...et,
271
271
  ...Ye,
272
- ...Fe,
273
- ...Ie,
272
+ ...Le,
273
+ ...Re,
274
274
  ...We,
275
- ...X,
276
- ...Ue,
277
- ...$,
275
+ ...J,
278
276
  ...Q,
279
- ...He,
280
- ...Le
277
+ ...$,
278
+ ...X,
279
+ ...Z,
280
+ ...ze
281
281
  }), {
282
- ...Fe,
283
- ...Ie,
282
+ ...Le,
283
+ ...Re,
284
284
  ...Ge,
285
285
  ...We,
286
- ...X,
287
- ...Ue,
288
- ...$,
286
+ ...J,
289
287
  ...Q,
290
- ...Le,
291
- ...Re
292
- }, {
288
+ ...$,
293
289
  ...X,
294
- ...Q,
295
- ...Ve,
296
290
  ...ze,
297
- ...Be,
298
- ...Pe
299
- }, je.button, W.button;
291
+ ...Be
292
+ }, {
293
+ ...J,
294
+ ...X,
295
+ ...Ue,
296
+ ...He,
297
+ ...Y,
298
+ ...Ie
299
+ }, Pe.button, V.button;
300
300
  var it = {
301
301
  storageType: {
302
302
  type: String,
303
- default: B.local,
304
- validator: (e) => Object.values(B).includes(e)
303
+ default: L.local,
304
+ validator: (e) => Object.values(L).includes(e)
305
305
  },
306
306
  storageKey: String
307
307
  }, at = {
@@ -340,7 +340,7 @@ var it = {
340
340
  },
341
341
  iconRemoveSuggestion: {
342
342
  type: [String, Object],
343
- default: Oe.remove
343
+ default: je.remove
344
344
  },
345
345
  labelRemoveSuggestion: {
346
346
  type: String,
@@ -358,7 +358,7 @@ var it = {
358
358
  topLayer: $e.topLayer
359
359
  };
360
360
  function lt(e) {
361
- return ((e) => e == null || e === "" || Array.isArray(e) && e.length === 0 || !(e instanceof Date) && typeof e == "object" && Object.keys(e).length === 0)(A(e));
361
+ return ((e) => e == null || e === "" || Array.isArray(e) && e.length === 0 || !(e instanceof Date) && typeof e == "object" && Object.keys(e).length === 0)(k(e));
362
362
  }
363
363
  function ut(e) {
364
364
  return typeof e == "string";
@@ -367,19 +367,19 @@ function dt(e) {
367
367
  return Array.isArray(e) ? e.filter((e) => ut(e)).join(" ") : e;
368
368
  }
369
369
  function ft(e, t) {
370
- let r = S(() => D(e) ? e.value : e), i = S(() => dt(r.value.invalidLabel)), a = S(() => dt(r.value.validLabel)), o = S(() => r.value.loadingLabel), s = S(() => r.value.hintLabel), c = S(() => !!(r.value.loading && (t.loading || o.value))), l = S(() => !c.value && !!(r.value.invalid && (t.invalid || i.value))), u = S(() => !c.value && !l.value && !!(r.value.valid && (t.valid || a.value))), d = S(() => !c.value && !l.value && !u.value && !!(t.hint || s.value)), f = S(() => l.value || u.value || c.value || d.value);
370
+ let r = x(() => E(e) ? e.value : e), i = x(() => dt(r.value.invalidLabel)), a = x(() => dt(r.value.validLabel)), o = x(() => r.value.loadingLabel), s = x(() => r.value.hintLabel), c = x(() => !!(r.value.loading && (t.loading || o.value))), l = x(() => !c.value && !!(r.value.invalid && (t.invalid || i.value))), u = x(() => !c.value && !l.value && !!(r.value.valid && (t.valid || a.value))), d = x(() => !c.value && !l.value && !u.value && !!(t.hint || s.value)), f = x(() => l.value || u.value || c.value || d.value);
371
371
  return {
372
372
  hasInvalidLabelOrSlot: l,
373
373
  hasHintLabelOrSlot: d,
374
374
  hasValidLabelOrSlot: u,
375
375
  hasLoadingLabelOrSlot: c,
376
- hintSlotScope: S(() => ({
376
+ hintSlotScope: x(() => ({
377
377
  modelValue: r.value.modelValue,
378
378
  valid: r.value.valid,
379
379
  invalid: r.value.invalid,
380
380
  loading: r.value.loading
381
381
  })),
382
- HintSlot: k({
382
+ HintSlot: O({
383
383
  name: "HintSlot",
384
384
  props: { tag: {
385
385
  type: String,
@@ -422,15 +422,15 @@ var pt = {
422
422
  },
423
423
  role: {
424
424
  type: String,
425
- default: G.menu,
426
- validator: (e) => Object.values(G).includes(e)
425
+ default: H.menu,
426
+ validator: (e) => Object.values(H).includes(e)
427
427
  }
428
428
  }, mt = { focusOnHover: {
429
429
  type: Boolean,
430
430
  default: !1
431
431
  } }, ht = {
432
- ...X,
433
- ...Z,
432
+ ...J,
433
+ ...Ve,
434
434
  ...Ze,
435
435
  ...$,
436
436
  deselectHintLabel: { type: String },
@@ -442,11 +442,11 @@ var pt = {
442
442
  }
443
443
  };
444
444
  function gt(e) {
445
- let t = ue();
446
- return S(() => String(e?.value || t));
445
+ let t = de();
446
+ return x(() => String(e?.value || t));
447
447
  }
448
448
  function _t(e, t) {
449
- let n = globalThis.HTMLElement !== void 0 && "popover" in globalThis.HTMLElement.prototype, r = S(() => n && h(t)), i = S(() => r.value ? "manual" : void 0);
449
+ let n = globalThis.HTMLElement !== void 0 && "popover" in globalThis.HTMLElement.prototype, r = x(() => n && h(t)), i = x(() => r.value ? "manual" : void 0);
450
450
  function a() {
451
451
  return (n && e.value?.matches(":popover-open")) ?? !1;
452
452
  }
@@ -468,13 +468,13 @@ function _t(e, t) {
468
468
  };
469
469
  }
470
470
  function vt({ reference: e, id: r, expanded: i, aria: a }) {
471
- let o = _e();
471
+ let o = ve();
472
472
  return {
473
473
  bus: o,
474
- component: k({
474
+ component: O({
475
475
  name: "VvDropdownTriggerProvider",
476
476
  setup() {
477
- t(J, {
477
+ t(G, {
478
478
  reference: e,
479
479
  id: r,
480
480
  expanded: i,
@@ -483,40 +483,47 @@ function vt({ reference: e, id: r, expanded: i, aria: a }) {
483
483
  });
484
484
  },
485
485
  render() {
486
- return n(ae, {}, this.$slots.default?.());
486
+ return n(oe, {}, this.$slots.default?.());
487
487
  }
488
488
  })
489
489
  };
490
490
  }
491
491
  function yt({ role: e, ...n }) {
492
- let r = S(() => e.value === G.listbox ? K.option : K.presentation);
493
- return t(Y, {
492
+ let r = x(() => e.value === H.listbox ? U.option : U.presentation);
493
+ return t(K, {
494
494
  role: r,
495
495
  ...n
496
496
  }), { itemRole: r };
497
497
  }
498
- function bt({ expanded: e }) {
499
- t(Ne, {
500
- role: x(Me.menuitem),
501
- expanded: e
498
+ function bt({ expanded: e, onAction: n }) {
499
+ t(q, {
500
+ role: b(Fe.menuitem),
501
+ expanded: e,
502
+ onAction: n
502
503
  });
503
504
  }
504
505
  function xt(e, t, n) {
505
- return S(() => {
506
+ return x(() => {
506
507
  let r = { [e]: !0 }, i = typeof t?.value == "string" ? t.value.split(" ") : t?.value;
507
508
  return i && Array.isArray(i) && i.forEach((t) => {
508
509
  t && (r[`${e}--${t}`] = !0);
509
510
  }), n && Object.keys(n.value).forEach((t) => {
510
- r[`${e}--${t}`] = A(n.value[t]);
511
+ r[`${e}--${t}`] = k(n.value[t]);
511
512
  }), r;
512
513
  });
513
514
  }
514
- var St = ["popover"], Ct = [
515
+ function St() {
516
+ return e(K, {});
517
+ }
518
+ function Ct() {
519
+ return e(q, {});
520
+ }
521
+ var wt = ["popover"], Tt = [
515
522
  "id",
516
523
  "tabindex",
517
524
  "role",
518
525
  "aria-labelledby"
519
- ], wt = /* @__PURE__ */ k({
526
+ ], Et = /* @__PURE__ */ O({
520
527
  name: "VvDropdown",
521
528
  inheritAttrs: !1,
522
529
  props: pt,
@@ -538,220 +545,276 @@ var St = ["popover"], Ct = [
538
545
  "leaveCancelled"
539
546
  ],
540
547
  setup(e, { expose: t, emit: n }) {
541
- let d = e, h = n, { id: g } = pe(d), te = gt(g), ne = l(), _ = x(), v = x(), re = x(), y = x(), C = S({
548
+ let d = e, h = n, { id: g } = me(d), te = gt(g), ne = l(), _ = b(), v = b(), re = b(), ie = b(), S = x({
542
549
  get: () => d.reference ?? _.value,
543
550
  set: (e) => {
544
551
  _.value = e;
545
552
  }
546
- }), { isTopLayer: w, popover: ce, show: le, hide: ue } = _t(v, () => d.topLayer), T = S(() => w.value ? V.fixed : d.strategy), D = x(!1);
553
+ }), { isTopLayer: C, popover: le, show: ue, hide: de } = _t(v, () => d.topLayer), w = x(() => C.value ? R.fixed : d.strategy), E = b(!1);
547
554
  u(() => {
548
- I(v.value, () => {
549
- D.value = globalThis.getComputedStyle(v.value).getPropertyValue("--dropdown-custom-position")?.trim() === "true";
555
+ we(v.value, () => {
556
+ E.value = globalThis.getComputedStyle(v.value).getPropertyValue("--dropdown-custom-position")?.trim() === "true";
550
557
  }, {
551
558
  attributeFilter: ["style"],
552
559
  window: globalThis.window
553
560
  });
554
561
  });
555
- function k(e, t, n) {
562
+ function O(e, t, n) {
556
563
  return typeof e == "boolean" ? t() : n(e);
557
564
  }
558
- function fe(e) {
565
+ function pe(e) {
559
566
  return !e.width && !e.height;
560
567
  }
561
- let _e = {
568
+ let ve = {
562
569
  name: "uncap",
563
570
  fn({ elements: e, rects: t, middlewareData: n }) {
564
571
  let { style: r } = e.floating, i = t.floating.height >= Number.parseFloat(r.maxHeight) - 1 || t.floating.width >= Number.parseFloat(r.maxWidth) - 1;
565
- return n.uncap || !i || fe(t.floating) ? {} : (r.maxHeight = "", r.maxWidth = "", {
572
+ return n.uncap || !i || pe(t.floating) ? {} : (r.maxHeight = "", r.maxWidth = "", {
566
573
  data: { uncapped: !0 },
567
574
  reset: { rects: !0 }
568
575
  });
569
576
  }
570
577
  };
571
- function F(e) {
572
- return d.triggerWidth && !D.value ? e.reference.width : 0;
578
+ function P(e) {
579
+ return d.triggerWidth && !E.value ? e.reference.width : 0;
573
580
  }
574
- let Te = {
581
+ let De = {
575
582
  name: "triggerWidth",
576
583
  fn({ elements: e, rects: t, middlewareData: n }) {
577
- let { style: r } = e.floating, i = F(t), a = Number.parseFloat(r.width) || 0;
584
+ let { style: r } = e.floating, i = P(t), a = Number.parseFloat(r.width) || 0;
578
585
  return n.triggerWidth || Math.abs(i - a) < .01 ? {} : (r.width = i ? `${i}px` : "", { reset: { rects: !0 } });
579
586
  }
580
- }, Ee = S(() => {
587
+ }, Oe = x(() => {
581
588
  let e = [];
582
- d.triggerWidth && e.push(Te), d.size && e.push(_e), d.offset && e.push(["string", "number"].includes(typeof d.offset) ? ye(Number(d.offset)) : ye(d.offset));
589
+ d.triggerWidth && e.push(De), d.size && e.push(ve), d.offset && e.push(["string", "number"].includes(typeof d.offset) ? be(Number(d.offset)) : be(d.offset));
583
590
  let t = typeof d.size == "object" ? d.size.padding : void 0;
584
- if (d.autoPlacement ? e.push(k(d.autoPlacement, () => be(), (e) => be(e))) : d.flip && e.push(k(d.flip, () => me({
591
+ if (d.autoPlacement ? e.push(O(d.autoPlacement, () => xe(), (e) => xe(e))) : d.flip && e.push(O(d.flip, () => he({
585
592
  fallbackStrategy: "initialPlacement",
586
593
  padding: t
587
- }), (e) => me({
594
+ }), (e) => he({
588
595
  padding: t,
589
596
  ...e
590
- }))), d.shift && e.push(k(d.shift, () => N(), (e) => N(e))), d.size) {
597
+ }))), d.shift && e.push(O(d.shift, () => M(), (e) => M(e))), d.size) {
591
598
  let t = ({ availableWidth: e, availableHeight: t, elements: n, rects: r }) => {
592
- if (fe(r.floating) || D.value) return;
599
+ if (pe(r.floating) || E.value) return;
593
600
  let { style: i } = n.floating;
594
- i.maxWidth = F(r) ? "" : `${Math.max(0, e)}px`, i.maxHeight = `${Math.max(0, t)}px`;
601
+ i.maxWidth = P(r) ? "" : `${Math.max(0, e)}px`, i.maxHeight = `${Math.max(0, t)}px`;
595
602
  };
596
- e.push(k(d.size, () => he({ apply: t }), (e) => he({
603
+ e.push(O(d.size, () => ge({ apply: t }), (e) => ge({
597
604
  ...e,
598
605
  apply: (n) => (t(n), e?.apply?.(n))
599
606
  })));
600
607
  }
601
- return d.arrow && e.push(xe({ element: re })), e;
602
- }), { x: R, y: De, middlewareData: z, placement: Oe, strategy: ke, update: B } = ve(C, v, {
603
- placement: S(() => d.placement),
604
- strategy: T,
605
- middleware: Ee
606
- }), Ae = S(() => {
607
- if (!D.value) return {
608
- position: ke.value,
609
- top: `${De.value ?? 0}px`,
610
- left: `${R.value ?? 0}px`
608
+ return d.arrow && e.push(Se({ element: re })), e;
609
+ }), { x: ke, y: Ae, middlewareData: I, placement: je, strategy: Me, update: L } = ye(S, v, {
610
+ placement: x(() => d.placement),
611
+ strategy: w,
612
+ middleware: Oe
613
+ }), Ne = x(() => {
614
+ if (!E.value) return {
615
+ position: Me.value,
616
+ top: `${Ae.value ?? 0}px`,
617
+ left: `${ke.value ?? 0}px`
611
618
  };
612
619
  });
613
620
  m(() => d.triggerWidth, (e) => {
614
621
  !e && v.value && (v.value.style.width = "");
615
622
  });
616
- let U = S(() => Oe.value.split("-")[0]), je = S(() => {
617
- if (D.value) return;
623
+ let B = x(() => je.value.split("-")[0]), Pe = x(() => {
624
+ if (E.value) return;
618
625
  let e = {
619
- [H.top]: H.bottom,
620
- [H.right]: H.left,
621
- [H.bottom]: H.top,
622
- [H.left]: H.right
623
- }[U.value];
626
+ [z.top]: z.bottom,
627
+ [z.right]: z.left,
628
+ [z.bottom]: z.top,
629
+ [z.left]: z.right
630
+ }[B.value];
624
631
  return {
625
- left: z.value.arrow?.x === void 0 ? void 0 : `${z.value.arrow?.x}px`,
626
- top: z.value.arrow?.y === void 0 ? void 0 : `${z.value.arrow?.y}px`,
632
+ left: I.value.arrow?.x === void 0 ? void 0 : `${I.value.arrow?.x}px`,
633
+ top: I.value.arrow?.y === void 0 ? void 0 : `${I.value.arrow?.y}px`,
627
634
  [e]: `${-(re.value?.offsetWidth ?? 0) / 2}px`
628
635
  };
629
- }), W = Se(d, "modelValue", h), Me = x(!1), G = S({
630
- get: () => W.value ?? Me.value,
636
+ }), V = Ce(d, "modelValue", h), Fe = b(!1), U = x({
637
+ get: () => V.value ?? Fe.value,
631
638
  set: (e) => {
632
- W.value === void 0 ? Me.value = e : W.value = e;
639
+ V.value === void 0 ? Fe.value = e : V.value = e;
633
640
  }
634
641
  });
635
642
  m([
636
- G,
637
- C,
643
+ U,
644
+ S,
638
645
  v,
639
- T
646
+ w
640
647
  ], ([e, t, n, r], i, a) => {
641
- e && t && n && a(ge(t, n, B, { animationFrame: r === V.fixed }));
648
+ e && t && n && a(_e(t, n, L, { animationFrame: r === R.fixed }));
642
649
  }, {
643
650
  flush: "post",
644
651
  immediate: !0
645
- }), I(y, () => {
646
- G.value && B();
652
+ }), we(ie, () => {
653
+ U.value && L();
647
654
  }, {
648
655
  childList: !0,
649
656
  subtree: !0,
650
657
  characterData: !0
651
- }), ie(() => {
652
- G.value && le();
658
+ }), ae(() => {
659
+ U.value && ue();
653
660
  });
654
- function K() {
655
- G.value = !0;
661
+ function W() {
662
+ U.value = !0;
656
663
  }
657
- function q() {
658
- G.value = !1;
664
+ function G() {
665
+ U.value = !1;
659
666
  }
660
- function J() {
661
- G.value = !G.value;
667
+ function K() {
668
+ U.value = !U.value;
662
669
  }
663
- function Y(e) {
664
- C.value = e;
670
+ function q(e) {
671
+ S.value = e;
665
672
  }
666
- Ce(v, () => {
667
- !d.keepOpen && G.value && (G.value = !1);
668
- }, { ignore: [C] });
669
- let Ne = S(() => C.value?.getAttribute?.("id") ?? void 0), Pe = S(() => ({
673
+ Te(v, () => {
674
+ !d.keepOpen && U.value && (U.value = !1);
675
+ }, { ignore: [S] });
676
+ let Ie = x(() => S.value?.getAttribute?.("id") ?? void 0), Le = x(() => ({
670
677
  "aria-controls": te.value,
671
678
  "aria-haspopup": !0,
672
- "aria-expanded": G.value
673
- })), { component: Fe, bus: Ie } = vt({
674
- reference: C,
679
+ "aria-expanded": U.value
680
+ })), { component: Re, bus: ze } = vt({
681
+ reference: S,
675
682
  id: te,
676
- expanded: G,
677
- aria: Pe
683
+ expanded: U,
684
+ aria: Le
678
685
  });
679
- Ie.on("click", J);
680
- let { role: Le, modifiers: X } = pe(d), Re = xt("vv-dropdown", X, S(() => ({ arrow: d.arrow }))), { focused: Z } = we(v);
681
- function ze(e) {
682
- return e ? [...e.querySelectorAll("a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"])")].filter((e) => !e.hasAttribute("disabled") && !e.getAttribute("aria-hidden")) : [];
686
+ ze.on("click", K);
687
+ let { role: J, modifiers: Be } = me(d), Ve = xt("vv-dropdown", Be, x(() => ({ arrow: d.arrow }))), { focused: He } = Ee(v);
688
+ function Y(e) {
689
+ return e?.getRootNode()?.activeElement ?? null;
690
+ }
691
+ let Ue = "a[href], button, input:not([type=\"hidden\"]), textarea, select, details, [tabindex]:not([tabindex=\"-1\"])";
692
+ function X(e) {
693
+ return !e.hasAttribute("disabled") && e.getAttribute("aria-hidden") !== "true";
683
694
  }
684
- function Be() {
695
+ function Z(e) {
696
+ return e ? [...e.querySelectorAll(Ue)].filter(X) : [];
697
+ }
698
+ let Q = b(!1), $;
699
+ function We() {
700
+ let e = S.value?.$el ?? S.value;
701
+ if (e instanceof HTMLElement) {
702
+ if (e.matches(Ue) && X(e)) return e;
703
+ let t = e.querySelector(`[aria-controls="${CSS.escape(String(te.value))}"]`), n = t && X(t) ? t : Z(e).find((e) => !v.value?.contains(e));
704
+ if (n) return n;
705
+ }
706
+ return $?.isConnected ? $ : void 0;
707
+ }
708
+ function Ge() {
709
+ let e = We();
710
+ e && (Q.value = !0, e.focus({ preventScroll: !0 }), setTimeout(() => {
711
+ Q.value = !1;
712
+ }));
713
+ }
714
+ function Ke(e) {
715
+ return e.composedPath().find((e) => e instanceof Element && e.classList.contains("vv-dropdown")) ?? Y(v.value)?.closest(".vv-dropdown") ?? void 0;
716
+ }
717
+ function qe() {
685
718
  o(() => {
686
- let e = ze(v.value);
719
+ let e = Z(v.value);
687
720
  e.length > 0 && e[0].focus({ preventScroll: !0 });
688
721
  });
689
722
  }
690
- function Ve() {
723
+ function Je() {
691
724
  o(() => {
692
- let e = ze(y.value);
725
+ let e = Z(ie.value);
693
726
  e.length > 0 && e[0].focus({ preventScroll: !0 });
694
727
  });
695
728
  }
696
- function Q() {
729
+ function Ye() {
697
730
  o(() => {
698
- if (Z.value) {
699
- let e = ze(v.value);
700
- if (e.length === 0 || !document.activeElement) return;
701
- let t = e.indexOf(document.activeElement);
702
- t < e.length - 1 ? e[t + 1].focus({ preventScroll: !0 }) : e[0].focus({ preventScroll: !0 });
731
+ if (He.value) {
732
+ let e = Z(v.value), t = Y(v.value);
733
+ if (e.length === 0 || !t) return;
734
+ let n = e.indexOf(t);
735
+ n < e.length - 1 ? e[n + 1].focus({ preventScroll: !0 }) : e[0].focus({ preventScroll: !0 });
703
736
  }
704
737
  });
705
738
  }
706
- function He() {
739
+ function Xe() {
707
740
  o(() => {
708
- if (Z.value) {
709
- let e = ze(v.value);
710
- if (e.length === 0 || !document.activeElement) return;
711
- let t = e.indexOf(document.activeElement);
712
- if (t > 0) {
713
- e[t - 1].focus({ preventScroll: !0 });
741
+ if (He.value) {
742
+ let e = Z(v.value), t = Y(v.value);
743
+ if (e.length === 0 || !t) return;
744
+ let n = e.indexOf(t);
745
+ if (n > 0) {
746
+ e[n - 1].focus({ preventScroll: !0 });
714
747
  return;
715
748
  }
716
749
  e.at(-1)?.focus({ preventScroll: !0 });
717
750
  }
718
751
  });
719
752
  }
720
- m(G, (e) => {
721
- e && d.autofocusFirst && Be();
753
+ m(U, (e) => {
754
+ if (e) {
755
+ let e = Y(v.value) ?? document.activeElement;
756
+ $ = e instanceof HTMLElement && !v.value?.contains(e) ? e : void 0;
757
+ }
758
+ e && d.autofocusFirst && qe();
722
759
  }), t({
723
- toggle: J,
724
- show: K,
725
- hide: q,
726
- init: Y,
727
- focusFirst: Be,
728
- focusFirstListElement: Ve,
729
- focusNext: Q,
730
- focusPrev: He,
731
- customPosition: D
760
+ toggle: K,
761
+ show: W,
762
+ hide: G,
763
+ init: q,
764
+ focusFirst: qe,
765
+ focusFirstListElement: Je,
766
+ focusNext: Ye,
767
+ focusPrev: Xe,
768
+ customPosition: E,
769
+ restoringFocus: Q
732
770
  });
733
- let { itemRole: Ue } = yt({
734
- role: Le,
735
- expanded: G,
736
- focused: Z,
737
- hovered: P(v)
771
+ let Ze = N(v), { onAction: Qe } = St(), { expanded: $e, onAction: et } = Ct();
772
+ et && bt({ expanded: $e });
773
+ function tt() {
774
+ if (!U.value || d.keepOpen || J.value === H.listbox) return;
775
+ let e = Y(v.value), t = !!e && !!v.value?.contains(e);
776
+ G(), t && Ge(), Qe?.();
777
+ }
778
+ let { itemRole: nt } = yt({
779
+ role: J,
780
+ expanded: U,
781
+ focused: He,
782
+ hovered: Ze,
783
+ onAction: tt
738
784
  });
739
- L("Escape", (e) => {
740
- G.value && (e.preventDefault(), q());
741
- }), L("ArrowDown", (e) => {
742
- G.value && Z.value && (e.preventDefault(), Q());
743
- }), L("ArrowUp", (e) => {
744
- G.value && Z.value && (e.preventDefault(), He());
745
- }), L([" ", "Enter"], (e) => {
746
- let t = e.target;
747
- G.value && Z.value && t && t?.click();
785
+ F("Escape", (e) => {
786
+ if (!U.value) return;
787
+ let t = Ke(e);
788
+ t && t !== v.value && v.value?.contains(t) || (e.preventDefault(), G(), t === v.value && Ge());
789
+ }), F("ArrowDown", (e) => {
790
+ U.value && Ke(e) === v.value && (e.preventDefault(), Ye());
791
+ }), F("ArrowUp", (e) => {
792
+ U.value && Ke(e) === v.value && (e.preventDefault(), Xe());
748
793
  });
749
- let $ = {
794
+ function rt(e, t) {
795
+ if (e instanceof HTMLElement && e.isContentEditable) return !0;
796
+ switch (e.tagName) {
797
+ case "BUTTON":
798
+ case "SUMMARY":
799
+ case "INPUT":
800
+ case "TEXTAREA":
801
+ case "SELECT": return !0;
802
+ case "A":
803
+ case "AREA": return t === "Enter" && e.hasAttribute("href");
804
+ default: return !1;
805
+ }
806
+ }
807
+ F([" ", "Enter"], (e) => {
808
+ if (!U.value || Ke(e) !== v.value) return;
809
+ let t = Y(v.value);
810
+ t instanceof HTMLElement && !rt(t, e.key) && t.click();
811
+ });
812
+ let it = {
750
813
  "before-enter": () => {
751
814
  h("beforeExpand"), h("beforeEnter");
752
815
  },
753
816
  "after-leave": () => {
754
- G.value || ue(), h("afterCollapse"), h("afterLeave");
817
+ U.value || de(), h("afterCollapse"), h("afterLeave");
755
818
  },
756
819
  enter: () => {
757
820
  h("enter");
@@ -772,105 +835,104 @@ var St = ["popover"], Ct = [
772
835
  h("leaveCancelled");
773
836
  }
774
837
  };
775
- return (e, t) => (M(), j(ae, null, [ee(A(Fe), null, {
776
- default: E(() => [c(e.$slots, "default", r(i({
777
- init: Y,
778
- show: K,
779
- hide: q,
780
- toggle: J,
781
- expanded: A(G),
782
- aria: A(Pe)
838
+ return (e, t) => (j(), A(oe, null, [ee(k(Re), null, {
839
+ default: T(() => [c(e.$slots, "default", r(i({
840
+ init: q,
841
+ show: W,
842
+ hide: G,
843
+ toggle: K,
844
+ expanded: k(U),
845
+ aria: k(Le)
783
846
  })))]),
784
847
  _: 3
785
- }), ee(de, p({ name: e.transitionName }, s($), { persisted: "" }), {
786
- default: E(() => [se(b("div", {
848
+ }), ee(fe, p({ name: e.transitionName }, s(it), { persisted: "" }), {
849
+ default: T(() => [ce(y("div", {
787
850
  ref_key: "floatingEl",
788
851
  ref: v,
789
- popover: A(ce),
790
- style: f(A(Ae)),
791
- class: a(A(Re))
852
+ popover: k(le),
853
+ style: f(k(Ne)),
854
+ class: a(k(Ve))
792
855
  }, [
793
- d.arrow ? (M(), j("div", {
856
+ d.arrow ? (j(), A("div", {
794
857
  key: 0,
795
858
  ref_key: "arrowEl",
796
859
  ref: re,
797
- style: f(A(je)),
860
+ style: f(k(Pe)),
798
861
  class: "vv-dropdown__arrow"
799
- }, null, 4)) : O("v-if", !0),
862
+ }, null, 4)) : D("v-if", !0),
800
863
  c(e.$slots, "before", r(i({
801
- show: K,
802
- hide: q,
803
- toggle: J,
804
- expanded: A(G)
864
+ show: W,
865
+ hide: G,
866
+ toggle: K,
867
+ expanded: k(U)
805
868
  }))),
806
- b("div", p(A(ne), {
807
- id: A(te),
869
+ y("div", p(k(ne), {
870
+ id: k(te),
808
871
  ref_key: "listEl",
809
- ref: y,
810
- tabindex: A(G) ? void 0 : -1,
811
- role: A(Le),
812
- "aria-labelledby": A(Ne),
872
+ ref: ie,
873
+ tabindex: k(U) ? void 0 : -1,
874
+ role: k(J),
875
+ "aria-labelledby": k(Ie),
813
876
  class: "vv-dropdown__list"
814
877
  }), [c(e.$slots, "items", r(i({
815
- show: K,
816
- hide: q,
817
- toggle: J,
818
- expanded: A(G),
819
- role: A(Ue)
820
- })))], 16, Ct),
878
+ show: W,
879
+ hide: G,
880
+ toggle: K,
881
+ expanded: k(U),
882
+ role: k(nt)
883
+ })))], 16, Tt),
821
884
  c(e.$slots, "after", r(i({
822
- show: K,
823
- hide: q,
824
- toggle: J,
825
- expanded: A(G)
885
+ show: W,
886
+ hide: G,
887
+ toggle: K,
888
+ expanded: k(U)
826
889
  })))
827
- ], 14, St), [[oe, A(G)]])]),
890
+ ], 14, wt), [[se, k(U)]])]),
828
891
  _: 3
829
892
  }, 16, ["name"])], 64));
830
893
  }
831
- });
832
- function Tt() {
833
- return e(Y, {});
834
- }
835
- var Et = /* @__PURE__ */ k({
894
+ }), Dt = /* @__PURE__ */ O({
836
895
  name: "VvDropdownItem",
837
896
  props: mt,
838
897
  setup(e) {
839
- let t = e, { role: n, expanded: r } = Tt(), i = x(null);
840
- bt({ expanded: r });
841
- let a = P(i), { focused: o } = F(i), { focused: s } = we(i);
842
- return m(a, (e) => {
843
- e && t.focusOnHover && (o.value = !0);
844
- }), (e, t) => (M(), j("div", p({ role: A(n) }, {
898
+ let t = e, { role: n, expanded: r, onAction: i } = St(), a = b(null);
899
+ bt({
900
+ expanded: r,
901
+ onAction: i
902
+ });
903
+ let o = N(a), { focused: s } = P(a), { focused: l } = Ee(a);
904
+ return m(o, (e) => {
905
+ e && t.focusOnHover && (s.value = !0);
906
+ }), (e, t) => (j(), A("div", p({ role: k(n) }, {
845
907
  ref_key: "element",
846
- ref: i,
847
- class: ["vv-dropdown__item", { "focus-visible": A(o) || A(s) }]
908
+ ref: a,
909
+ class: ["vv-dropdown__item", { "focus-visible": k(s) || k(l) }]
848
910
  }), [c(e.$slots, "default")], 16));
849
911
  }
850
- }), Dt = ["title"], Ot = /* @__PURE__ */ k({
912
+ }), Ot = ["title"], kt = /* @__PURE__ */ O({
851
913
  name: "VvDropdownOption",
852
914
  props: ht,
853
915
  setup(e) {
854
- let t = e, { modifiers: n } = pe(t), o = xt("vv-dropdown-option", n, S(() => ({
916
+ let t = e, { modifiers: n } = me(t), o = xt("vv-dropdown-option", n, x(() => ({
855
917
  disabled: t.disabled,
856
918
  selected: t.selected,
857
919
  unselectable: t.unselectable && t.selected
858
- }))), s = S(() => t.selected ? t.unselectable ? t.deselectHintLabel : t.selectedHintLabel : t.disabled ? "" : t.selectHintLabel);
859
- return (e, t) => (M(), _(Et, {
860
- class: a(A(o)),
920
+ }))), s = x(() => t.selected ? t.unselectable ? t.deselectHintLabel : t.selectedHintLabel : t.disabled ? "" : t.selectHintLabel);
921
+ return (e, t) => (j(), _(Dt, {
922
+ class: a(k(o)),
861
923
  tabindex: e.disabled ? -1 : 0,
862
924
  "aria-selected": e.selected,
863
925
  "aria-disabled": e.disabled,
864
926
  "focus-on-hover": e.focusOnHover
865
927
  }, {
866
- default: E(() => [c(e.$slots, "default"), b("span", {
928
+ default: T(() => [c(e.$slots, "default"), y("span", {
867
929
  class: "vv-dropdown-option__hint",
868
- title: A(s)
930
+ title: k(s)
869
931
  }, [c(e.$slots, "hint", r(i({
870
932
  disabled: e.disabled,
871
933
  selected: e.selected,
872
934
  unselectable: e.unselectable
873
- })), () => [fe(w(A(s)), 1)])], 8, Dt)]),
935
+ })), () => [pe(C(k(s)), 1)])], 8, Ot)]),
874
936
  _: 3
875
937
  }, 8, [
876
938
  "class",
@@ -881,10 +943,10 @@ var Et = /* @__PURE__ */ k({
881
943
  ]));
882
944
  }
883
945
  });
884
- function kt() {
885
- return e(q, void 0);
946
+ function At() {
947
+ return e(W, void 0);
886
948
  }
887
- var At = /* @__PURE__ */ k({
949
+ var jt = /* @__PURE__ */ O({
888
950
  name: "VvIcon",
889
951
  props: /* @__PURE__ */ d({
890
952
  name: {},
@@ -903,14 +965,14 @@ var At = /* @__PURE__ */ k({
903
965
  onLoad: { type: Function },
904
966
  svg: {},
905
967
  modifiers: {}
906
- }, ke),
968
+ }, Me),
907
969
  setup(e) {
908
- let t = e, n = S(() => typeof t.rotate == "string" ? Number.parseFloat(t.rotate) : t.rotate), r = x(!0), i = kt(), { modifiers: a } = pe(t), o = xt("vv-icon", a), s = S(() => t.provider || i?.iconsProvider), c = S(() => {
970
+ let t = e, n = x(() => typeof t.rotate == "string" ? Number.parseFloat(t.rotate) : t.rotate), r = b(!0), i = At(), { modifiers: a } = me(t), o = xt("vv-icon", a), s = x(() => t.provider || i?.iconsProvider), c = x(() => {
909
971
  let e = t.name ?? "", n = `@${s.value}:${t.prefix}:${e}`;
910
- if (R(n)) return n;
972
+ if (ke(n)) return n;
911
973
  let r = i?.iconsCollections.find((t) => {
912
974
  let n = `@${s.value}:${t.prefix}:${e}`;
913
- return R(n);
975
+ return ke(n);
914
976
  });
915
977
  return r ? `@${s.value}:${r.prefix}:${e}` : e;
916
978
  });
@@ -919,19 +981,19 @@ var At = /* @__PURE__ */ k({
919
981
  }
920
982
  function u(e) {
921
983
  let n = l(e), r = n?.innerHTML.trim() || "";
922
- n && r && De(`@${s.value}:${t.prefix}:${t.name}`, {
984
+ n && r && Ae(`@${s.value}:${t.prefix}:${t.name}`, {
923
985
  body: r,
924
986
  height: n.viewBox.baseVal.height,
925
987
  width: n.viewBox.baseVal.width
926
988
  });
927
989
  }
928
- return i && t.src && !R(`@${s.value}:${t.prefix}:${t.name}`) && (r.value = !1, i.fetchIcon(t.src).then((e) => {
990
+ return i && t.src && !ke(`@${s.value}:${t.prefix}:${t.name}`) && (r.value = !1, i.fetchIcon(t.src).then((e) => {
929
991
  e && u(e), r.value = !0;
930
992
  }).catch((e) => {
931
993
  throw r.value = !0, /* @__PURE__ */ Error(`Error during fetch icon: ${e?.message}`);
932
- })), t.svg && u(t.svg), (t, i) => A(r) ? (M(), _(A(z), p({
994
+ })), t.svg && u(t.svg), (t, i) => k(r) ? (j(), _(k(I), p({
933
995
  key: 0,
934
- class: A(o)
996
+ class: k(o)
935
997
  }, {
936
998
  inline: e.inline,
937
999
  width: e.width,
@@ -939,13 +1001,13 @@ var At = /* @__PURE__ */ k({
939
1001
  horizontalFlip: e.horizontalFlip,
940
1002
  verticalFlip: e.verticalFlip,
941
1003
  flip: e.flip,
942
- rotate: A(n),
1004
+ rotate: k(n),
943
1005
  color: e.color,
944
- icon: A(c)
945
- }, { onLoad: e.onLoad }), null, 16, ["class", "onLoad"])) : O("v-if", !0);
1006
+ icon: k(c)
1007
+ }, { onLoad: e.onLoad }), null, 16, ["class", "onLoad"])) : D("v-if", !0);
946
1008
  }
947
1009
  });
948
- function jt(e, t, n) {
1010
+ function Mt(e, t, n) {
949
1011
  let r = t;
950
1012
  if (Array.isArray(e) && e.length) {
951
1013
  let i = e[0];
@@ -957,21 +1019,21 @@ function jt(e, t, n) {
957
1019
  }
958
1020
  return r;
959
1021
  }
960
- function Mt(e, t, n) {
961
- let r = kt(), i = S(() => {
1022
+ function Nt(e, t, n) {
1023
+ let r = At(), i = x(() => {
962
1024
  if (r?.defaults.value?.[e]) return r.defaults.value[e];
963
1025
  });
964
- return S(() => {
1026
+ return x(() => {
965
1027
  if (i.value === void 0) return n;
966
1028
  let e = i.value, r = t, a = n;
967
1029
  return Object.keys(r).reduce((t, n) => {
968
1030
  let i = a[n];
969
- return t[n] = n in e ? jt(r[n], i, e[n]) : i, t;
1031
+ return t[n] = n in e ? Mt(r[n], i, e[n]) : i, t;
970
1032
  }, {});
971
1033
  });
972
1034
  }
973
- function Nt(e, t, n = 0, { getter: r = (e) => e, setter: i = (e) => e } = {}) {
974
- let a, o, s = S(() => {
1035
+ function Pt(e, t, n = 0, { getter: r = (e) => e, setter: i = (e) => e } = {}) {
1036
+ let a, o, s = x(() => {
975
1037
  let e = h(n) ?? 0, t = typeof e == "string" ? Number.parseInt(e) : e;
976
1038
  return Number.isNaN(t) ? 0 : t;
977
1039
  });
@@ -983,8 +1045,8 @@ function Nt(e, t, n = 0, { getter: r = (e) => e, setter: i = (e) => e } = {}) {
983
1045
  let e = i(o.value);
984
1046
  return c(), t("update:modelValue", e), e;
985
1047
  }
986
- return le(c), {
987
- model: S({
1048
+ return ue(c), {
1049
+ model: x({
988
1050
  get: () => r(e?.value),
989
1051
  set: (e) => {
990
1052
  s.value <= 0 ? (c(), t("update:modelValue", i(e))) : (o = { value: e }, a && clearTimeout(a), a = setTimeout(l, s.value));
@@ -994,47 +1056,47 @@ function Nt(e, t, n = 0, { getter: r = (e) => e, setter: i = (e) => e } = {}) {
994
1056
  cancel: c
995
1057
  };
996
1058
  }
997
- function Pt(e, t) {
998
- let n = S(() => typeof e?.value == "string" ? { name: e?.value } : e?.value), r = S(() => t?.value === U.before ? n.value : void 0), i = S(() => t?.value === U.after ? n.value : void 0);
1059
+ function Ft(e, t) {
1060
+ let n = x(() => typeof e?.value == "string" ? { name: e?.value } : e?.value), r = x(() => t?.value === B.before ? n.value : void 0), i = x(() => t?.value === B.after ? n.value : void 0);
999
1061
  return {
1000
1062
  hasIcon: n,
1001
- hasIconLeft: S(() => t?.value === H.left ? n.value : void 0),
1002
- hasIconRight: S(() => t?.value === H.right ? n.value : void 0),
1003
- hasIconTop: S(() => t?.value === H.top ? n.value : void 0),
1004
- hasIconBottom: S(() => t?.value === H.bottom ? n.value : void 0),
1063
+ hasIconLeft: x(() => t?.value === z.left ? n.value : void 0),
1064
+ hasIconRight: x(() => t?.value === z.right ? n.value : void 0),
1065
+ hasIconTop: x(() => t?.value === z.top ? n.value : void 0),
1066
+ hasIconBottom: x(() => t?.value === z.bottom ? n.value : void 0),
1005
1067
  hasIconBefore: r,
1006
1068
  hasIconAfter: i
1007
1069
  };
1008
1070
  }
1009
- function Ft(e, t) {
1010
- let { focused: n } = F(e);
1071
+ function It(e, t) {
1072
+ let { focused: n } = P(e);
1011
1073
  return m(n, (n) => {
1012
- t(n ? "focus" : "blur", A(e));
1074
+ t(n ? "focus" : "blur", k(e));
1013
1075
  }), { focused: n };
1014
1076
  }
1015
- function It(e, t) {
1016
- let n = S(() => (A(e) ?? "").length), r = S(() => t?.lowerLimit !== void 0 && n.value < t?.lowerLimit ? n.value - t.lowerLimit : t?.upperLimit === void 0 ? 0 : t.upperLimit - n.value);
1077
+ function Lt(e, t) {
1078
+ let n = x(() => (k(e) ?? "").length), r = x(() => t?.lowerLimit !== void 0 && n.value < t?.lowerLimit ? n.value - t.lowerLimit : t?.upperLimit === void 0 ? 0 : t.upperLimit - n.value);
1017
1079
  return {
1018
1080
  length: n,
1019
1081
  gap: r,
1020
- formatted: S(() => t?.mode === !1 ? "" : t?.mode === "limit" && t?.upperLimit ? `${n.value} / ${t.lowerLimit ? `${t.lowerLimit}-` : ""}${t.upperLimit}` : t?.mode === "countdown" ? r.value === 0 ? void 0 : r.value : n.value)
1082
+ formatted: x(() => t?.mode === !1 ? "" : t?.mode === "limit" && t?.upperLimit ? `${n.value} / ${t.lowerLimit ? `${t.lowerLimit}-` : ""}${t.upperLimit}` : t?.mode === "countdown" ? r.value === 0 ? void 0 : r.value : n.value)
1021
1083
  };
1022
1084
  }
1023
- function Lt(e, t = B.local, n) {
1024
- let r = x();
1085
+ function Rt(e, t = L.local, n) {
1086
+ let r = b();
1025
1087
  n && (r.value = n);
1026
1088
  let i;
1027
1089
  return u(() => {
1028
1090
  e && m(e, (e, n) => {
1029
- let a = A(t) === B.session ? sessionStorage : localStorage;
1030
- n && n !== e && a.removeItem(n), e ? (i = Ee(e, i?.value ?? r.value, a), i.value && (r.value = i.value)) : i = void 0;
1031
- }, { immediate: !0 }), D(t) && m(t, (t, n) => {
1091
+ let a = k(t) === L.session ? sessionStorage : localStorage;
1092
+ n && n !== e && a.removeItem(n), e ? (i = Oe(e, i?.value ?? r.value, a), i.value && (r.value = i.value)) : i = void 0;
1093
+ }, { immediate: !0 }), E(t) && m(t, (t, n) => {
1032
1094
  if (e?.value) {
1033
1095
  if (t) {
1034
- let n = t === B.session ? sessionStorage : localStorage;
1035
- i = Ee(e.value, i?.value ?? r.value, n);
1096
+ let n = t === L.session ? sessionStorage : localStorage;
1097
+ i = Oe(e.value, i?.value ?? r.value, n);
1036
1098
  }
1037
- n && n !== t && (n === B.session ? sessionStorage : localStorage).removeItem(e.value);
1099
+ n && n !== t && (n === L.session ? sessionStorage : localStorage).removeItem(e.value);
1038
1100
  }
1039
1101
  });
1040
1102
  }), m(r, (e) => {
@@ -1044,66 +1106,66 @@ function Lt(e, t = B.local, n) {
1044
1106
  immediate: !0
1045
1107
  }), r;
1046
1108
  }
1047
- var Rt = ["for"], zt = {
1109
+ var zt = ["for"], Bt = {
1048
1110
  key: 0,
1049
1111
  class: "vv-textarea__input-before"
1050
- }, Bt = { class: "vv-textarea__inner" }, Vt = ["id"], Ht = {
1112
+ }, Vt = { class: "vv-textarea__inner" }, Ht = ["id"], Ut = {
1051
1113
  key: 1,
1052
1114
  class: "vv-textarea__input-after"
1053
- }, Ut = {
1115
+ }, Wt = {
1054
1116
  key: 2,
1055
1117
  class: "vv-textarea__limit"
1056
- }, Wt = { class: "flex-1" }, Gt = ["title", "onClick"], Kt = /* @__PURE__ */ k({
1118
+ }, Gt = { class: "flex-1" }, Kt = ["title", "onClick"], qt = /* @__PURE__ */ O({
1057
1119
  name: "VvTextarea",
1058
1120
  props: ct,
1059
1121
  emits: st,
1060
1122
  setup(e, { expose: t, emit: n }) {
1061
- let o = e, s = n, l = ne(), u = kt(), d = Mt("VvTextarea", ct, o), f = x(), h = x(), g = x(), { id: ie, icon: C, iconPosition: oe, iconRemoveSuggestion: ce, labelRemoveSuggestion: le, label: ue, modelValue: T, count: de, valid: k, invalid: me, loading: he, modifiers: ge, debounce: _e, minlength: ve, maxlength: ye, storageType: be } = pe(o), N = gt(ie), xe = S(() => `${N.value}-hint`), Se = S(() => o.floating && lt(o.placeholder) ? " " : o.placeholder), { model: P, flush: F } = Nt(T, s, _e);
1062
- t({ flush: F });
1063
- let { hasIconBefore: I, hasIconAfter: Ce } = Pt(C, oe), { hasIcon: we } = Pt(ce), { focused: L } = Ft(f, s), Ee = S(() => L.value && !o.disabled && !o.readonly);
1064
- m(Ee, (e) => {
1065
- let t = P.value;
1066
- if (e || (t = F() ?? t), e && d.value.selectOnFocus && f.value && f.value.select(), e && H.value?.size) g.value?.show();
1067
- else if (H.value && !lt(t)) {
1123
+ let o = e, s = n, l = ne(), u = At(), d = Nt("VvTextarea", ct, o), f = b(), h = b(), g = b(), { id: ae, icon: S, iconPosition: se, iconRemoveSuggestion: le, labelRemoveSuggestion: ue, label: de, modelValue: w, count: fe, valid: O, invalid: he, loading: ge, modifiers: _e, debounce: ve, minlength: ye, maxlength: be, storageType: xe } = me(o), M = gt(ae), Se = x(() => `${M.value}-hint`), Ce = x(() => o.floating && lt(o.placeholder) ? " " : o.placeholder), { model: N, flush: P } = Pt(w, s, ve);
1124
+ t({ flush: P });
1125
+ let { hasIconBefore: we, hasIconAfter: Te } = Ft(S, se), { hasIcon: Ee } = Ft(le), { focused: F } = It(f, s), Oe = x(() => F.value && !o.disabled && !o.readonly);
1126
+ m(Oe, (e) => {
1127
+ let t = N.value;
1128
+ if (e || (t = P() ?? t), e && d.value.selectOnFocus && f.value && f.value.select(), e && z.value?.size) g.value?.restoringFocus || g.value?.show();
1129
+ else if (z.value && !lt(t)) {
1068
1130
  let e = o.maxSuggestions;
1069
- H.value.size >= e && !H.value.has(t) && (H.value = new Set([...H.value].slice(H.value.size - e + 1))), H.value.add(t);
1131
+ z.value.size >= e && !z.value.has(t) && (z.value = new Set([...z.value].slice(z.value.size - e + 1))), z.value.add(t);
1070
1132
  }
1071
1133
  });
1072
- let R = Te(f);
1073
- m(R, (e) => {
1074
- e && o.autofocus && (L.value = !0);
1134
+ let ke = De(f);
1135
+ m(ke, (e) => {
1136
+ e && o.autofocus && (F.value = !0);
1075
1137
  });
1076
- let { formatted: De } = It(P, {
1077
- mode: de?.value,
1078
- upperLimit: Number(ye?.value),
1079
- lowerLimit: Number(ve?.value)
1080
- }), z = S(() => !o.disabled && !o.readonly), Oe = S(() => z.value ? o.tabindex : -1), ke = S(() => !lt(T)), B = S(() => {
1138
+ let { formatted: Ae } = Lt(N, {
1139
+ mode: fe?.value,
1140
+ upperLimit: Number(be?.value),
1141
+ lowerLimit: Number(ye?.value)
1142
+ }), I = x(() => !o.disabled && !o.readonly), je = x(() => I.value ? o.tabindex : -1), Me = x(() => !lt(w)), L = x(() => {
1081
1143
  if (o.invalid === !0) return !0;
1082
1144
  if (o.valid === !0) return !1;
1083
- }), V = S(() => o.storageKey ?? (u?.experimentalFeatures.forceInputSuggestions ? o.name : void 0)), H = Lt(V, be, /* @__PURE__ */ new Set()), Ae = S(() => H.value ? [...H.value].filter((e) => lt(P.value) || `${e}`.toLowerCase().includes(`${P.value}`.toLowerCase()) && e !== P.value).reverse() : []), U = S(() => V?.value && H.value && H.value.size > 0);
1084
- function je(e) {
1085
- P.value = e, g.value?.hide(), s("suggestion:selected", e);
1145
+ }), R = x(() => o.storageKey ?? (u?.experimentalFeatures.forceInputSuggestions ? o.name : void 0)), z = Rt(R, xe, /* @__PURE__ */ new Set()), Ne = x(() => z.value ? [...z.value].filter((e) => lt(N.value) || `${e}`.toLowerCase().includes(`${N.value}`.toLowerCase()) && e !== N.value).reverse() : []), B = x(() => R?.value && z.value && z.value.size > 0);
1146
+ function Pe(e) {
1147
+ N.value = e, g.value?.hide(), s("suggestion:selected", e);
1086
1148
  }
1087
- function W(e) {
1088
- H.value?.delete(e), s("suggestion:removed", e);
1149
+ function V(e) {
1150
+ z.value?.delete(e), s("suggestion:removed", e);
1089
1151
  }
1090
- let { HintSlot: Me, hasHintLabelOrSlot: G, hasInvalidLabelOrSlot: K, hintSlotScope: q } = ft(d, l), J = xt("vv-textarea", ge, S(() => ({
1091
- valid: k.value,
1092
- invalid: me.value,
1093
- loading: he.value,
1152
+ let { HintSlot: Fe, hasHintLabelOrSlot: H, hasInvalidLabelOrSlot: U, hintSlotScope: W } = ft(d, l), G = xt("vv-textarea", _e, x(() => ({
1153
+ valid: O.value,
1154
+ invalid: he.value,
1155
+ loading: ge.value,
1094
1156
  disabled: o.disabled,
1095
1157
  readonly: o.readonly,
1096
1158
  required: o.required,
1097
- "icon-before": I.value !== void 0,
1098
- "icon-after": Ce.value !== void 0,
1159
+ "icon-before": we.value !== void 0,
1160
+ "icon-after": Te.value !== void 0,
1099
1161
  floating: o.floating && !lt(o.label),
1100
- dirty: ke.value,
1101
- focus: L.value,
1162
+ dirty: Me.value,
1163
+ focus: F.value,
1102
1164
  resizable: o.resizable
1103
- }))), Y = S(() => ({
1165
+ }))), K = x(() => ({
1104
1166
  name: o.name,
1105
- placeholder: Se.value,
1106
- tabindex: Oe.value,
1167
+ placeholder: Ce.value,
1168
+ tabindex: je.value,
1107
1169
  disabled: o.disabled,
1108
1170
  readonly: o.readonly,
1109
1171
  required: o.required,
@@ -1116,99 +1178,99 @@ var Rt = ["for"], zt = {
1116
1178
  spellcheck: o.spellcheck,
1117
1179
  "aria-label": o.ariaLabel || void 0,
1118
1180
  "aria-labelledby": o.ariaLabelledby || void 0,
1119
- "aria-invalid": B.value,
1120
- "aria-describedby": [o.ariaDescribedby, G.value ? xe.value : void 0].filter(Boolean).join(" ") || void 0,
1121
- "aria-errormessage": K.value ? xe.value : void 0
1122
- })), Ne = S(() => ({
1181
+ "aria-invalid": L.value,
1182
+ "aria-describedby": [o.ariaDescribedby, H.value ? Se.value : void 0].filter(Boolean).join(" ") || void 0,
1183
+ "aria-errormessage": U.value ? Se.value : void 0
1184
+ })), q = x(() => ({
1123
1185
  valid: o.valid,
1124
1186
  invalid: o.invalid,
1125
1187
  modelValue: o.modelValue,
1126
1188
  hintLabel: o.hintLabel,
1127
1189
  maxlength: o.maxlength,
1128
1190
  minlength: o.minlength,
1129
- clear: Pe
1191
+ clear: Ie
1130
1192
  }));
1131
- function Pe() {
1132
- P.value = void 0;
1193
+ function Ie() {
1194
+ N.value = void 0;
1133
1195
  }
1134
- return (e, t) => (M(), j("div", { class: a(A(J)) }, [
1135
- A(ue) ? (M(), j("label", {
1196
+ return (e, t) => (j(), A("div", { class: a(k(G)) }, [
1197
+ k(de) ? (j(), A("label", {
1136
1198
  key: 0,
1137
- for: A(N),
1199
+ for: k(M),
1138
1200
  class: "vv-textarea__label"
1139
- }, w(A(ue)), 9, Rt)) : O("v-if", !0),
1140
- b("div", {
1201
+ }, C(k(de)), 9, zt)) : D("v-if", !0),
1202
+ y("div", {
1141
1203
  ref_key: "wrapperEl",
1142
1204
  ref: h,
1143
1205
  class: "vv-textarea__wrapper"
1144
1206
  }, [
1145
- e.$slots.before ? (M(), j("div", zt, [c(e.$slots, "before", r(i(A(Ne))))])) : O("v-if", !0),
1146
- b("div", Bt, [
1147
- A(I) ? (M(), _(At, p({ key: 0 }, A(I), { class: "vv-textarea__icon" }), null, 16)) : O("v-if", !0),
1148
- se(b("textarea", p({
1149
- id: A(N),
1207
+ e.$slots.before ? (j(), A("div", Bt, [c(e.$slots, "before", r(i(k(q))))])) : D("v-if", !0),
1208
+ y("div", Vt, [
1209
+ k(we) ? (j(), _(jt, p({ key: 0 }, k(we), { class: "vv-textarea__icon" }), null, 16)) : D("v-if", !0),
1210
+ ce(y("textarea", p({
1211
+ id: k(M),
1150
1212
  ref_key: "textareaEl",
1151
1213
  ref: f,
1152
- "onUpdate:modelValue": t[0] ||= (e) => D(P) ? P.value = e : null
1153
- }, A(Y), { onKeyup: t[1] ||= (e) => s("keyup", e) }), null, 16, Vt), [[re, A(P)]]),
1154
- A(Ce) ? (M(), _(At, p({ key: 1 }, A(Ce), { class: "vv-textarea__icon vv-textarea__icon-after" }), null, 16)) : O("v-if", !0)
1214
+ "onUpdate:modelValue": t[0] ||= (e) => E(N) ? N.value = e : null
1215
+ }, k(K), { onKeyup: t[1] ||= (e) => s("keyup", e) }), null, 16, Ht), [[re, k(N)]]),
1216
+ k(Te) ? (j(), _(jt, p({ key: 1 }, k(Te), { class: "vv-textarea__icon vv-textarea__icon-after" }), null, 16)) : D("v-if", !0)
1155
1217
  ]),
1156
- e.$slots.after ? (M(), j("div", Ht, [c(e.$slots, "after", r(i(A(Ne))))])) : O("v-if", !0),
1157
- A(de) ? (M(), j("span", Ut, [c(e.$slots, "count", r(i(A(Ne))), () => [fe(w(A(De)), 1)])])) : O("v-if", !0)
1218
+ e.$slots.after ? (j(), A("div", Ut, [c(e.$slots, "after", r(i(k(q))))])) : D("v-if", !0),
1219
+ k(fe) ? (j(), A("span", Wt, [c(e.$slots, "count", r(i(k(q))), () => [pe(C(k(Ae)), 1)])])) : D("v-if", !0)
1158
1220
  ], 512),
1159
- ee(A(Me), {
1160
- id: A(xe),
1221
+ ee(k(Fe), {
1222
+ id: k(Se),
1161
1223
  class: "vv-textarea__hint"
1162
1224
  }, v({ _: 2 }, [
1163
1225
  e.$slots.hint ? {
1164
1226
  name: "hint",
1165
- fn: E(() => [c(e.$slots, "hint", r(i(A(q))))]),
1227
+ fn: T(() => [c(e.$slots, "hint", r(i(k(W))))]),
1166
1228
  key: "0"
1167
1229
  } : void 0,
1168
1230
  e.$slots.loading ? {
1169
1231
  name: "loading",
1170
- fn: E(() => [c(e.$slots, "loading", r(i(A(q))))]),
1232
+ fn: T(() => [c(e.$slots, "loading", r(i(k(W))))]),
1171
1233
  key: "1"
1172
1234
  } : void 0,
1173
1235
  e.$slots.valid ? {
1174
1236
  name: "valid",
1175
- fn: E(() => [c(e.$slots, "valid", r(i(A(q))))]),
1237
+ fn: T(() => [c(e.$slots, "valid", r(i(k(W))))]),
1176
1238
  key: "2"
1177
1239
  } : void 0,
1178
1240
  e.$slots.invalid ? {
1179
1241
  name: "invalid",
1180
- fn: E(() => [c(e.$slots, "invalid", r(i(A(q))))]),
1242
+ fn: T(() => [c(e.$slots, "invalid", r(i(k(W))))]),
1181
1243
  key: "3"
1182
1244
  } : void 0
1183
1245
  ]), 1032, ["id"]),
1184
- A(U) ? (M(), _(wt, {
1246
+ k(B) ? (j(), _(Et, {
1185
1247
  key: 1,
1186
1248
  ref_key: "suggestionsDropdownEl",
1187
1249
  ref: g,
1188
- reference: A(h),
1250
+ reference: k(h),
1189
1251
  "autofocus-first": !1,
1190
1252
  "trigger-width": !0,
1191
- "top-layer": A(d).topLayer
1253
+ "top-layer": k(d).topLayer
1192
1254
  }, {
1193
- items: E(() => [(M(!0), j(ae, null, te(A(Ae), (t) => (M(), _(Ot, {
1255
+ items: T(() => [(j(!0), A(oe, null, te(k(Ne), (t) => (j(), _(kt, {
1194
1256
  key: t,
1195
- onClick: y((e) => je(t), ["stop"])
1257
+ onClick: ie((e) => Pe(t), ["stop"])
1196
1258
  }, {
1197
- default: E(() => [b("div", Wt, [c(e.$slots, "suggestion", p({ ref_for: !0 }, { value: t }), () => [fe(w(t), 1)])]), A(H) && A(we) ? (M(), j("button", {
1259
+ default: T(() => [y("div", Gt, [c(e.$slots, "suggestion", p({ ref_for: !0 }, { value: t }), () => [pe(C(t), 1)])]), k(z) && k(Ee) ? (j(), A("button", {
1198
1260
  key: 0,
1199
1261
  type: "button",
1200
1262
  tabindex: "-1",
1201
1263
  class: "cursor-pointer",
1202
- title: A(le),
1203
- onClick: y((e) => W(t), ["stop"])
1204
- }, [ee(At, p({ ref_for: !0 }, A(we)), null, 16)], 8, Gt)) : O("v-if", !0)]),
1264
+ title: k(ue),
1265
+ onClick: ie((e) => V(t), ["stop"])
1266
+ }, [ee(jt, p({ ref_for: !0 }, k(Ee)), null, 16)], 8, Kt)) : D("v-if", !0)]),
1205
1267
  _: 2
1206
1268
  }, 1032, ["onClick"]))), 128))]),
1207
1269
  _: 3
1208
- }, 8, ["reference", "top-layer"])) : O("v-if", !0)
1270
+ }, 8, ["reference", "top-layer"])) : D("v-if", !0)
1209
1271
  ], 2));
1210
1272
  }
1211
1273
  });
1212
- export { Kt as default };
1274
+ export { qt as default };
1213
1275
 
1214
- //# sourceMappingURL=VvTextarea.es-BOhkaXfY.js.map
1276
+ //# sourceMappingURL=VvTextarea.es-CgvZOWO4.js.map