@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.
- package/dist/_chunks/{PkChatbotFilePreview-Cw3va5vW.js → PkChatbotFilePreview-CLUH7cTq.js} +2 -2
- package/dist/_chunks/{PkChatbotFilePreview-Cw3va5vW.js.map → PkChatbotFilePreview-CLUH7cTq.js.map} +1 -1
- package/dist/_chunks/{PkEditorRadioButtons-CY0D_EkU.js → PkEditorRadioButtons-YSngp-Wn.js} +2 -2
- package/dist/_chunks/{PkEditorRadioButtons-CY0D_EkU.js.map → PkEditorRadioButtons-YSngp-Wn.js.map} +1 -1
- package/dist/_chunks/{PkFilePreview-D4TgY0T9.js → PkFilePreview-BHqmp1EW.js} +5 -5
- package/dist/_chunks/{PkFilePreview-D4TgY0T9.js.map → PkFilePreview-BHqmp1EW.js.map} +1 -1
- package/dist/_chunks/{PkFilePreviewDialog-8H1GeV91.js → PkFilePreviewDialog-BHAgVlKs.js} +3 -3
- package/dist/_chunks/{PkFilePreviewDialog-8H1GeV91.js.map → PkFilePreviewDialog-BHAgVlKs.js.map} +1 -1
- package/dist/_chunks/{PkHeldImage-B6UYQ8Ox.js → PkHeldImage-WGwFM77v.js} +2 -2
- package/dist/_chunks/{PkHeldImage-B6UYQ8Ox.js.map → PkHeldImage-WGwFM77v.js.map} +1 -1
- package/dist/_chunks/{PkImageEditorDialog-BqHjVX97.js → PkImageEditorDialog-BDwL39Du.js} +18 -18
- package/dist/_chunks/{PkImageEditorDialog-BqHjVX97.js.map → PkImageEditorDialog-BDwL39Du.js.map} +1 -1
- package/dist/_chunks/{PkLazyImg-D3XOz-dS.js → PkLazyImg-DL7hxjyy.js} +2 -2
- package/dist/_chunks/{PkLazyImg-D3XOz-dS.js.map → PkLazyImg-DL7hxjyy.js.map} +1 -1
- package/dist/_chunks/{PkSelectionActions-BxUXWFNK.js → PkSelectionActions-DLsZ8-gW.js} +2 -2
- package/dist/_chunks/{PkSelectionActions-BxUXWFNK.js.map → PkSelectionActions-DLsZ8-gW.js.map} +1 -1
- package/dist/_chunks/{PkToolChatFile-CSBzfuyE.js → PkToolChatFile-62j1S0Pq.js} +3 -3
- package/dist/_chunks/{PkToolChatFile-CSBzfuyE.js.map → PkToolChatFile-62j1S0Pq.js.map} +1 -1
- package/dist/_chunks/{PkToolRequestGeolocation-DNzNRszE.js → PkToolRequestGeolocation-B9EM_K6O.js} +2 -2
- package/dist/_chunks/{PkToolRequestGeolocation-DNzNRszE.js.map → PkToolRequestGeolocation-B9EM_K6O.js.map} +1 -1
- package/dist/_chunks/{PkToolRequestOAuthConnection-BDxYXz4s.js → PkToolRequestOAuthConnection-CfjfqCHX.js} +3 -3
- package/dist/_chunks/{PkToolRequestOAuthConnection-BDxYXz4s.js.map → PkToolRequestOAuthConnection-CfjfqCHX.js.map} +1 -1
- package/dist/_chunks/{PkToolShareDocument-Kq7SFbw5.js → PkToolShareDocument-CYBU4LPO.js} +3 -3
- package/dist/_chunks/{PkToolShareDocument-Kq7SFbw5.js.map → PkToolShareDocument-CYBU4LPO.js.map} +1 -1
- package/dist/_chunks/{PkToolShowArtifact-d5tKvM01.js → PkToolShowArtifact-I_QZS7Pf.js} +2 -2
- package/dist/_chunks/{PkToolShowArtifact-d5tKvM01.js.map → PkToolShowArtifact-I_QZS7Pf.js.map} +1 -1
- package/dist/_chunks/{PkToolShowCalendarEvent-fMI-paCP.js → PkToolShowCalendarEvent-js9lh-cX.js} +3 -3
- package/dist/_chunks/{PkToolShowCalendarEvent-fMI-paCP.js.map → PkToolShowCalendarEvent-js9lh-cX.js.map} +1 -1
- package/dist/_chunks/{PkToolShowChart-lLXuHRJu.js → PkToolShowChart-BalU3bxm.js} +3 -3
- package/dist/_chunks/{PkToolShowChart-lLXuHRJu.js.map → PkToolShowChart-BalU3bxm.js.map} +1 -1
- package/dist/_chunks/{PkToolShowComparison-CKSqPgJo.js → PkToolShowComparison-DeO7cMeF.js} +3 -3
- package/dist/_chunks/{PkToolShowComparison-CKSqPgJo.js.map → PkToolShowComparison-DeO7cMeF.js.map} +1 -1
- package/dist/_chunks/{PkToolShowContactForm-Bni1QzXV.js → PkToolShowContactForm-BeJ5GR6t.js} +5 -5
- package/dist/_chunks/{PkToolShowContactForm-Bni1QzXV.js.map → PkToolShowContactForm-BeJ5GR6t.js.map} +1 -1
- package/dist/_chunks/{PkToolShowDiagram-DWVSCu33.js → PkToolShowDiagram-j3TTzZ5I.js} +3 -3
- package/dist/_chunks/{PkToolShowDiagram-DWVSCu33.js.map → PkToolShowDiagram-j3TTzZ5I.js.map} +1 -1
- package/dist/_chunks/{PkToolShowEmail-D6Mw24jB.js → PkToolShowEmail-CQ4uyty9.js} +3 -3
- package/dist/_chunks/{PkToolShowEmail-D6Mw24jB.js.map → PkToolShowEmail-CQ4uyty9.js.map} +1 -1
- package/dist/_chunks/{PkToolShowForm-CFXtO0j4.js → PkToolShowForm-B9VDoS_W.js} +15 -15
- package/dist/_chunks/{PkToolShowForm-CFXtO0j4.js.map → PkToolShowForm-B9VDoS_W.js.map} +1 -1
- package/dist/_chunks/{PkToolShowImageGallery-Ci_Kg44s.js → PkToolShowImageGallery-DFuc5IJ1.js} +3 -3
- package/dist/_chunks/{PkToolShowImageGallery-Ci_Kg44s.js.map → PkToolShowImageGallery-DFuc5IJ1.js.map} +1 -1
- package/dist/_chunks/{PkToolShowLocation-DV0puCbD.js → PkToolShowLocation-PThC5tCV.js} +3 -3
- package/dist/_chunks/{PkToolShowLocation-DV0puCbD.js.map → PkToolShowLocation-PThC5tCV.js.map} +1 -1
- package/dist/_chunks/{PkToolShowMessage-Bq2dbSy1.js → PkToolShowMessage-9mlI4IQ6.js} +3 -3
- package/dist/_chunks/{PkToolShowMessage-Bq2dbSy1.js.map → PkToolShowMessage-9mlI4IQ6.js.map} +1 -1
- package/dist/_chunks/{PkToolShowProductList-BWWzkWWA.js → PkToolShowProductList-C2EJKYOV.js} +4 -4
- package/dist/_chunks/{PkToolShowProductList-BWWzkWWA.js.map → PkToolShowProductList-C2EJKYOV.js.map} +1 -1
- package/dist/_chunks/{PkToolShowQrCode-DZkJIyMF.js → PkToolShowQrCode-DQiVo4Vh.js} +3 -3
- package/dist/_chunks/{PkToolShowQrCode-DZkJIyMF.js.map → PkToolShowQrCode-DQiVo4Vh.js.map} +1 -1
- package/dist/_chunks/{PkToolShowSources-Dv7hbDyy.js → PkToolShowSources-BL3DnfcN.js} +3 -3
- package/dist/_chunks/{PkToolShowSources-Dv7hbDyy.js.map → PkToolShowSources-BL3DnfcN.js.map} +1 -1
- package/dist/_chunks/{PkToolShowSuggestedReply-B_dRrZfj.js → PkToolShowSuggestedReply-DLgtjBJ1.js} +2 -2
- package/dist/_chunks/{PkToolShowSuggestedReply-B_dRrZfj.js.map → PkToolShowSuggestedReply-DLgtjBJ1.js.map} +1 -1
- package/dist/_chunks/{PkToolShowVideo-DLgQjTq_.js → PkToolShowVideo-DcWXDcOZ.js} +3 -3
- package/dist/_chunks/{PkToolShowVideo-DLgQjTq_.js.map → PkToolShowVideo-DcWXDcOZ.js.map} +1 -1
- package/dist/_chunks/{PkToolShowWeather-HElfkyLV.js → PkToolShowWeather-DLT47oC6.js} +2 -2
- package/dist/_chunks/{PkToolShowWeather-HElfkyLV.js.map → PkToolShowWeather-DLT47oC6.js.map} +1 -1
- package/dist/_chunks/{PkToolShowWebPages-XxcYBQpr.js → PkToolShowWebPages-CPqMC6qt.js} +4 -4
- package/dist/_chunks/{PkToolShowWebPages-XxcYBQpr.js.map → PkToolShowWebPages-CPqMC6qt.js.map} +1 -1
- package/dist/_chunks/{VvButtonLocalized-BgY-V26j.js → VvButtonLocalized-D_gumqSJ.js} +2 -2
- package/dist/_chunks/{VvButtonLocalized-BgY-V26j.js.map → VvButtonLocalized-D_gumqSJ.js.map} +1 -1
- package/dist/_chunks/{VvCheckbox.es-KisDJtH_.js → VvCheckbox.es-D44kGZc-.js} +2 -2
- package/dist/_chunks/{VvCheckbox.es-KisDJtH_.js.map → VvCheckbox.es-D44kGZc-.js.map} +1 -1
- package/dist/_chunks/{VvCheckboxGroup.es-CIVHYElp.js → VvCheckboxGroup.es-Da5Vuel0.js} +2 -2
- package/dist/_chunks/{VvCheckboxGroup.es-CIVHYElp.js.map → VvCheckboxGroup.es-Da5Vuel0.js.map} +1 -1
- package/dist/_chunks/{VvCombobox.es-DybZ6U_6.js → VvCombobox.es-BJzmLeTh.js} +467 -403
- package/dist/_chunks/VvCombobox.es-BJzmLeTh.js.map +1 -0
- package/dist/_chunks/{VvInputText.es-DFSPWDcH.js → VvInputText.es-CHcdm2K-.js} +280 -218
- package/dist/_chunks/VvInputText.es-CHcdm2K-.js.map +1 -0
- package/dist/_chunks/{VvRadio.es-vrNSXb3X.js → VvRadio.es-B3IskaN4.js} +2 -2
- package/dist/_chunks/{VvRadio.es-vrNSXb3X.js.map → VvRadio.es-B3IskaN4.js.map} +1 -1
- package/dist/_chunks/{VvRadioGroup.es-DalxMbrj.js → VvRadioGroup.es-CBivcD0v.js} +2 -2
- package/dist/_chunks/{VvRadioGroup.es-DalxMbrj.js.map → VvRadioGroup.es-CBivcD0v.js.map} +1 -1
- package/dist/_chunks/{VvSelect.es-D55xq4Lw.js → VvSelect.es-CAVvkyxB.js} +2 -2
- package/dist/_chunks/{VvSelect.es-D55xq4Lw.js.map → VvSelect.es-CAVvkyxB.js.map} +1 -1
- package/dist/_chunks/{VvTextarea.es-BOhkaXfY.js → VvTextarea.es-CgvZOWO4.js} +446 -384
- package/dist/_chunks/VvTextarea.es-CgvZOWO4.js.map +1 -0
- package/dist/_chunks/{index.es-BYhSukum.js → index.es-CEYwDeKz.js} +126 -66
- package/dist/_chunks/index.es-CEYwDeKz.js.map +1 -0
- package/dist/_chunks/{index.es-CPvSmI-B.js → index.es-DDdkqLT6.js} +10 -10
- package/dist/_chunks/{index.es-CPvSmI-B.js.map → index.es-DDdkqLT6.js.map} +1 -1
- package/dist/ai-elements.es.js +377 -376
- package/dist/ai-elements.es.js.map +1 -1
- package/dist-vue/PkChatbot.js +1 -1
- package/dist-vue/PkChatbotAuth.js +1 -1
- package/dist-vue/PkChatbotFeedbackForm.js +1 -1
- package/dist-vue/PkChatbotMessages.js +1 -1
- package/dist-vue/PkChatbotViewChat.js +1 -1
- package/dist-vue/PkChatbotViewConversations.js +1 -1
- package/dist-vue/PkChatbotViewProfile.js +1 -1
- package/dist-vue/_chunks/PkChatbot-aCgj2DMu.js +326 -0
- package/dist-vue/_chunks/PkChatbot-aCgj2DMu.js.map +1 -0
- package/dist-vue/_chunks/{PkChatbotAuth-449QUBoC.js → PkChatbotAuth-C5agN8ht.js} +2 -2
- package/dist-vue/_chunks/{PkChatbotAuth-449QUBoC.js.map → PkChatbotAuth-C5agN8ht.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotFeedbackForm-DdQQlAr1.js → PkChatbotFeedbackForm-DjsLxYjT.js} +2 -2
- package/dist-vue/_chunks/{PkChatbotFeedbackForm-DdQQlAr1.js.map → PkChatbotFeedbackForm-DjsLxYjT.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotMessages-_-h-egX7.js → PkChatbotMessages-CG3UZYcP.js} +3 -3
- package/dist-vue/_chunks/{PkChatbotMessages-_-h-egX7.js.map → PkChatbotMessages-CG3UZYcP.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotViewChat-Bg-Op2Oe.js → PkChatbotViewChat-IU3HJpxG.js} +3 -3
- package/dist-vue/_chunks/{PkChatbotViewChat-Bg-Op2Oe.js.map → PkChatbotViewChat-IU3HJpxG.js.map} +1 -1
- package/dist-vue/_chunks/PkChatbotViewConversations-4zGrp7Fo.js +197 -0
- package/dist-vue/_chunks/PkChatbotViewConversations-4zGrp7Fo.js.map +1 -0
- package/dist-vue/_chunks/PkChatbotViewProfile-BrZ7oiUY.js +85 -0
- package/dist-vue/_chunks/PkChatbotViewProfile-BrZ7oiUY.js.map +1 -0
- package/dist-vue/_chunks/{PkFilePreview-DydUI1G2.js → PkFilePreview-WqS-s3vk.js} +2 -2
- package/dist-vue/_chunks/{PkFilePreview-DydUI1G2.js.map → PkFilePreview-WqS-s3vk.js.map} +1 -1
- package/dist-vue/_chunks/{PkFilePreviewDialog-BuG1whsJ.js → PkFilePreviewDialog-BIaTAK05.js} +2 -2
- package/dist-vue/_chunks/{PkFilePreviewDialog-BuG1whsJ.js.map → PkFilePreviewDialog-BIaTAK05.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolShowContactForm-D0lDC69x.js → PkToolShowContactForm-DFufPNnQ.js} +2 -2
- package/dist-vue/_chunks/{PkToolShowContactForm-D0lDC69x.js.map → PkToolShowContactForm-DFufPNnQ.js.map} +1 -1
- package/dist-vue/_chunks/{index.es-CwEgvvQD.js → index.es-BmedAjkp.js} +2 -2
- package/dist-vue/_chunks/{index.es-CwEgvvQD.js.map → index.es-BmedAjkp.js.map} +1 -1
- package/dist-vue/composables.js +8 -6
- package/dist-vue/composables.js.map +1 -1
- package/dist-vue/index.js +10 -10
- package/dist-vue/locales.js +20 -16
- package/dist-vue/packages/components/src/chat/PkChatbot.d.ts +7 -7
- package/package.json +2 -2
- package/dist/_chunks/VvCombobox.es-DybZ6U_6.js.map +0 -1
- package/dist/_chunks/VvInputText.es-DFSPWDcH.js.map +0 -1
- package/dist/_chunks/VvTextarea.es-BOhkaXfY.js.map +0 -1
- package/dist/_chunks/index.es-BYhSukum.js.map +0 -1
- package/dist-vue/_chunks/PkChatbot-CFJmT4nN.js +0 -299
- package/dist-vue/_chunks/PkChatbot-CFJmT4nN.js.map +0 -1
- package/dist-vue/_chunks/PkChatbotViewConversations--smzyxqN.js +0 -226
- package/dist-vue/_chunks/PkChatbotViewConversations--smzyxqN.js.map +0 -1
- package/dist-vue/_chunks/PkChatbotViewProfile-Cn7IQfnQ.js +0 -86
- package/dist-vue/_chunks/PkChatbotViewProfile-Cn7IQfnQ.js.map +0 -1
- package/dist-vue/_chunks/chatbotProfileContext-b-nve-mR.js +0 -5
- 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
|
|
2
|
-
import { a as
|
|
3
|
-
import { S as
|
|
4
|
-
import { a as
|
|
5
|
-
// ../../node_modules/.pnpm/@volverjs+ui-vue@0.0.
|
|
6
|
-
|
|
7
|
-
var
|
|
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
|
-
},
|
|
18
|
+
}, Me = { prefix: "normal" }, L = /* @__PURE__ */ (function(e) {
|
|
19
19
|
return e.local = "local", e.session = "session", e;
|
|
20
|
-
})({}),
|
|
20
|
+
})({}), R = /* @__PURE__ */ (function(e) {
|
|
21
21
|
return e.absolute = "absolute", e.fixed = "fixed", e;
|
|
22
|
-
})({}),
|
|
22
|
+
})({}), z = /* @__PURE__ */ (function(e) {
|
|
23
23
|
return e.left = "left", e.right = "right", e.top = "top", e.bottom = "bottom", e;
|
|
24
|
-
})({}),
|
|
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
|
-
})({}),
|
|
26
|
+
})({}), B = /* @__PURE__ */ (function(e) {
|
|
27
27
|
return e.before = "before", e.after = "after", e;
|
|
28
|
-
})({}),
|
|
28
|
+
})({}), Pe = /* @__PURE__ */ (function(e) {
|
|
29
29
|
return e.button = "button", e.submit = "submit", e.reset = "reset", e;
|
|
30
|
-
})({}),
|
|
30
|
+
})({}), V = /* @__PURE__ */ (function(e) {
|
|
31
31
|
return e.nuxtLink = "nuxt-link", e.routerLink = "router-link", e.a = "a", e.button = "button", e;
|
|
32
|
-
})({}),
|
|
32
|
+
})({}), Fe = /* @__PURE__ */ (function(e) {
|
|
33
33
|
return e.button = "button", e.link = "link", e.menuitem = "menuitem", e;
|
|
34
|
-
})({}),
|
|
34
|
+
})({}), H = /* @__PURE__ */ (function(e) {
|
|
35
35
|
return e.listbox = "listbox", e.menu = "menu", e;
|
|
36
|
-
})({}),
|
|
36
|
+
})({}), U = /* @__PURE__ */ (function(e) {
|
|
37
37
|
return e.option = "option", e.presentation = "presentation", e;
|
|
38
|
-
})({}),
|
|
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
|
-
},
|
|
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
|
-
},
|
|
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
|
-
},
|
|
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
|
-
},
|
|
73
|
+
}, J = { disabled: {
|
|
74
74
|
type: Boolean,
|
|
75
75
|
default: !1
|
|
76
|
-
} },
|
|
76
|
+
} }, Be = { required: {
|
|
77
77
|
type: Boolean,
|
|
78
78
|
default: !1
|
|
79
|
-
} },
|
|
79
|
+
} }, Ve = { selected: {
|
|
80
80
|
type: Boolean,
|
|
81
81
|
default: !1
|
|
82
|
-
} },
|
|
82
|
+
} }, He = { active: {
|
|
83
83
|
type: Boolean,
|
|
84
84
|
default: !1
|
|
85
|
-
} },
|
|
85
|
+
} }, Y = { current: {
|
|
86
86
|
type: Boolean,
|
|
87
87
|
default: !1
|
|
88
88
|
} };
|
|
89
|
-
|
|
90
|
-
var
|
|
89
|
+
je.clear;
|
|
90
|
+
var Ue = { pressed: {
|
|
91
91
|
type: Boolean,
|
|
92
92
|
default: !1
|
|
93
|
-
} },
|
|
93
|
+
} }, X = { label: {
|
|
94
94
|
type: [String, Number],
|
|
95
95
|
default: void 0
|
|
96
|
-
} },
|
|
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
|
-
},
|
|
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:
|
|
155
|
-
validator: (e) => Object.values(
|
|
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:
|
|
170
|
-
validator: (e) => Object.values(
|
|
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(
|
|
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
|
-
...
|
|
243
|
-
...
|
|
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
|
-
...
|
|
254
|
-
...
|
|
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
|
-
...
|
|
267
|
+
...Be
|
|
268
268
|
};
|
|
269
269
|
({
|
|
270
270
|
...et,
|
|
271
271
|
...Ye,
|
|
272
|
-
...
|
|
273
|
-
...
|
|
272
|
+
...Le,
|
|
273
|
+
...Re,
|
|
274
274
|
...We,
|
|
275
|
-
...
|
|
276
|
-
...Ue,
|
|
277
|
-
...$,
|
|
275
|
+
...J,
|
|
278
276
|
...Q,
|
|
279
|
-
|
|
280
|
-
...
|
|
277
|
+
...$,
|
|
278
|
+
...X,
|
|
279
|
+
...Z,
|
|
280
|
+
...ze
|
|
281
281
|
}), {
|
|
282
|
-
...
|
|
283
|
-
...
|
|
282
|
+
...Le,
|
|
283
|
+
...Re,
|
|
284
284
|
...Ge,
|
|
285
285
|
...We,
|
|
286
|
-
...
|
|
287
|
-
...Ue,
|
|
288
|
-
...$,
|
|
286
|
+
...J,
|
|
289
287
|
...Q,
|
|
290
|
-
|
|
291
|
-
...Re
|
|
292
|
-
}, {
|
|
288
|
+
...$,
|
|
293
289
|
...X,
|
|
294
|
-
...Q,
|
|
295
|
-
...Ve,
|
|
296
290
|
...ze,
|
|
297
|
-
...Be
|
|
298
|
-
|
|
299
|
-
|
|
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:
|
|
304
|
-
validator: (e) => Object.values(
|
|
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:
|
|
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)(
|
|
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 =
|
|
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:
|
|
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:
|
|
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:
|
|
426
|
-
validator: (e) => Object.values(
|
|
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
|
-
...
|
|
433
|
-
...
|
|
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 =
|
|
446
|
-
return
|
|
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 =
|
|
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 =
|
|
471
|
+
let o = ve();
|
|
472
472
|
return {
|
|
473
473
|
bus: o,
|
|
474
|
-
component:
|
|
474
|
+
component: O({
|
|
475
475
|
name: "VvDropdownTriggerProvider",
|
|
476
476
|
setup() {
|
|
477
|
-
t(
|
|
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(
|
|
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 =
|
|
493
|
-
return t(
|
|
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(
|
|
500
|
-
role:
|
|
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
|
|
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}`] =
|
|
511
|
+
r[`${e}--${t}`] = k(n.value[t]);
|
|
511
512
|
}), r;
|
|
512
513
|
});
|
|
513
514
|
}
|
|
514
|
-
|
|
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
|
-
],
|
|
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 } =
|
|
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:
|
|
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
|
-
|
|
549
|
-
|
|
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
|
|
562
|
+
function O(e, t, n) {
|
|
556
563
|
return typeof e == "boolean" ? t() : n(e);
|
|
557
564
|
}
|
|
558
|
-
function
|
|
565
|
+
function pe(e) {
|
|
559
566
|
return !e.width && !e.height;
|
|
560
567
|
}
|
|
561
|
-
let
|
|
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 ||
|
|
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
|
|
572
|
-
return d.triggerWidth && !
|
|
578
|
+
function P(e) {
|
|
579
|
+
return d.triggerWidth && !E.value ? e.reference.width : 0;
|
|
573
580
|
}
|
|
574
|
-
let
|
|
581
|
+
let De = {
|
|
575
582
|
name: "triggerWidth",
|
|
576
583
|
fn({ elements: e, rects: t, middlewareData: n }) {
|
|
577
|
-
let { style: r } = e.floating, i =
|
|
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
|
-
},
|
|
587
|
+
}, Oe = x(() => {
|
|
581
588
|
let e = [];
|
|
582
|
-
d.triggerWidth && e.push(
|
|
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(
|
|
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) =>
|
|
594
|
+
}), (e) => he({
|
|
588
595
|
padding: t,
|
|
589
596
|
...e
|
|
590
|
-
}))), d.shift && e.push(
|
|
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 (
|
|
599
|
+
if (pe(r.floating) || E.value) return;
|
|
593
600
|
let { style: i } = n.floating;
|
|
594
|
-
i.maxWidth =
|
|
601
|
+
i.maxWidth = P(r) ? "" : `${Math.max(0, e)}px`, i.maxHeight = `${Math.max(0, t)}px`;
|
|
595
602
|
};
|
|
596
|
-
e.push(
|
|
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(
|
|
602
|
-
}), { x:
|
|
603
|
-
placement:
|
|
604
|
-
strategy:
|
|
605
|
-
middleware:
|
|
606
|
-
}),
|
|
607
|
-
if (!
|
|
608
|
-
position:
|
|
609
|
-
top: `${
|
|
610
|
-
left: `${
|
|
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
|
|
617
|
-
if (
|
|
623
|
+
let B = x(() => je.value.split("-")[0]), Pe = x(() => {
|
|
624
|
+
if (E.value) return;
|
|
618
625
|
let e = {
|
|
619
|
-
[
|
|
620
|
-
[
|
|
621
|
-
[
|
|
622
|
-
[
|
|
623
|
-
}[
|
|
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:
|
|
626
|
-
top:
|
|
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
|
-
}),
|
|
630
|
-
get: () =>
|
|
636
|
+
}), V = Ce(d, "modelValue", h), Fe = b(!1), U = x({
|
|
637
|
+
get: () => V.value ?? Fe.value,
|
|
631
638
|
set: (e) => {
|
|
632
|
-
|
|
639
|
+
V.value === void 0 ? Fe.value = e : V.value = e;
|
|
633
640
|
}
|
|
634
641
|
});
|
|
635
642
|
m([
|
|
636
|
-
|
|
637
|
-
|
|
643
|
+
U,
|
|
644
|
+
S,
|
|
638
645
|
v,
|
|
639
|
-
|
|
646
|
+
w
|
|
640
647
|
], ([e, t, n, r], i, a) => {
|
|
641
|
-
e && t && n && a(
|
|
648
|
+
e && t && n && a(_e(t, n, L, { animationFrame: r === R.fixed }));
|
|
642
649
|
}, {
|
|
643
650
|
flush: "post",
|
|
644
651
|
immediate: !0
|
|
645
|
-
}),
|
|
646
|
-
|
|
652
|
+
}), we(ie, () => {
|
|
653
|
+
U.value && L();
|
|
647
654
|
}, {
|
|
648
655
|
childList: !0,
|
|
649
656
|
subtree: !0,
|
|
650
657
|
characterData: !0
|
|
651
|
-
}),
|
|
652
|
-
|
|
658
|
+
}), ae(() => {
|
|
659
|
+
U.value && ue();
|
|
653
660
|
});
|
|
654
|
-
function
|
|
655
|
-
|
|
661
|
+
function W() {
|
|
662
|
+
U.value = !0;
|
|
656
663
|
}
|
|
657
|
-
function
|
|
658
|
-
|
|
664
|
+
function G() {
|
|
665
|
+
U.value = !1;
|
|
659
666
|
}
|
|
660
|
-
function
|
|
661
|
-
|
|
667
|
+
function K() {
|
|
668
|
+
U.value = !U.value;
|
|
662
669
|
}
|
|
663
|
-
function
|
|
664
|
-
|
|
670
|
+
function q(e) {
|
|
671
|
+
S.value = e;
|
|
665
672
|
}
|
|
666
|
-
|
|
667
|
-
!d.keepOpen &&
|
|
668
|
-
}, { ignore: [
|
|
669
|
-
let
|
|
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":
|
|
673
|
-
})), { component:
|
|
674
|
-
reference:
|
|
679
|
+
"aria-expanded": U.value
|
|
680
|
+
})), { component: Re, bus: ze } = vt({
|
|
681
|
+
reference: S,
|
|
675
682
|
id: te,
|
|
676
|
-
expanded:
|
|
677
|
-
aria:
|
|
683
|
+
expanded: U,
|
|
684
|
+
aria: Le
|
|
678
685
|
});
|
|
679
|
-
|
|
680
|
-
let { role:
|
|
681
|
-
function
|
|
682
|
-
return e
|
|
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
|
|
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 =
|
|
719
|
+
let e = Z(v.value);
|
|
687
720
|
e.length > 0 && e[0].focus({ preventScroll: !0 });
|
|
688
721
|
});
|
|
689
722
|
}
|
|
690
|
-
function
|
|
723
|
+
function Je() {
|
|
691
724
|
o(() => {
|
|
692
|
-
let e =
|
|
725
|
+
let e = Z(ie.value);
|
|
693
726
|
e.length > 0 && e[0].focus({ preventScroll: !0 });
|
|
694
727
|
});
|
|
695
728
|
}
|
|
696
|
-
function
|
|
729
|
+
function Ye() {
|
|
697
730
|
o(() => {
|
|
698
|
-
if (
|
|
699
|
-
let e =
|
|
700
|
-
if (e.length === 0 || !
|
|
701
|
-
let
|
|
702
|
-
|
|
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
|
|
739
|
+
function Xe() {
|
|
707
740
|
o(() => {
|
|
708
|
-
if (
|
|
709
|
-
let e =
|
|
710
|
-
if (e.length === 0 || !
|
|
711
|
-
let
|
|
712
|
-
if (
|
|
713
|
-
e[
|
|
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(
|
|
721
|
-
|
|
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:
|
|
724
|
-
show:
|
|
725
|
-
hide:
|
|
726
|
-
init:
|
|
727
|
-
focusFirst:
|
|
728
|
-
focusFirstListElement:
|
|
729
|
-
focusNext:
|
|
730
|
-
focusPrev:
|
|
731
|
-
customPosition:
|
|
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 {
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
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
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
}),
|
|
744
|
-
|
|
745
|
-
}),
|
|
746
|
-
|
|
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
|
-
|
|
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
|
-
|
|
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) => (
|
|
776
|
-
default:
|
|
777
|
-
init:
|
|
778
|
-
show:
|
|
779
|
-
hide:
|
|
780
|
-
toggle:
|
|
781
|
-
expanded:
|
|
782
|
-
aria:
|
|
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(
|
|
786
|
-
default:
|
|
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:
|
|
790
|
-
style: f(
|
|
791
|
-
class: a(
|
|
852
|
+
popover: k(le),
|
|
853
|
+
style: f(k(Ne)),
|
|
854
|
+
class: a(k(Ve))
|
|
792
855
|
}, [
|
|
793
|
-
d.arrow ? (
|
|
856
|
+
d.arrow ? (j(), A("div", {
|
|
794
857
|
key: 0,
|
|
795
858
|
ref_key: "arrowEl",
|
|
796
859
|
ref: re,
|
|
797
|
-
style: f(
|
|
860
|
+
style: f(k(Pe)),
|
|
798
861
|
class: "vv-dropdown__arrow"
|
|
799
|
-
}, null, 4)) :
|
|
862
|
+
}, null, 4)) : D("v-if", !0),
|
|
800
863
|
c(e.$slots, "before", r(i({
|
|
801
|
-
show:
|
|
802
|
-
hide:
|
|
803
|
-
toggle:
|
|
804
|
-
expanded:
|
|
864
|
+
show: W,
|
|
865
|
+
hide: G,
|
|
866
|
+
toggle: K,
|
|
867
|
+
expanded: k(U)
|
|
805
868
|
}))),
|
|
806
|
-
|
|
807
|
-
id:
|
|
869
|
+
y("div", p(k(ne), {
|
|
870
|
+
id: k(te),
|
|
808
871
|
ref_key: "listEl",
|
|
809
|
-
ref:
|
|
810
|
-
tabindex:
|
|
811
|
-
role:
|
|
812
|
-
"aria-labelledby":
|
|
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:
|
|
816
|
-
hide:
|
|
817
|
-
toggle:
|
|
818
|
-
expanded:
|
|
819
|
-
role:
|
|
820
|
-
})))], 16,
|
|
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:
|
|
823
|
-
hide:
|
|
824
|
-
toggle:
|
|
825
|
-
expanded:
|
|
885
|
+
show: W,
|
|
886
|
+
hide: G,
|
|
887
|
+
toggle: K,
|
|
888
|
+
expanded: k(U)
|
|
826
889
|
})))
|
|
827
|
-
], 14,
|
|
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 } =
|
|
840
|
-
bt({
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
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:
|
|
847
|
-
class: ["vv-dropdown__item", { "focus-visible":
|
|
908
|
+
ref: a,
|
|
909
|
+
class: ["vv-dropdown__item", { "focus-visible": k(s) || k(l) }]
|
|
848
910
|
}), [c(e.$slots, "default")], 16));
|
|
849
911
|
}
|
|
850
|
-
}),
|
|
912
|
+
}), Ot = ["title"], kt = /* @__PURE__ */ O({
|
|
851
913
|
name: "VvDropdownOption",
|
|
852
914
|
props: ht,
|
|
853
915
|
setup(e) {
|
|
854
|
-
let t = e, { modifiers: n } =
|
|
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 =
|
|
859
|
-
return (e, t) => (
|
|
860
|
-
class: a(
|
|
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:
|
|
928
|
+
default: T(() => [c(e.$slots, "default"), y("span", {
|
|
867
929
|
class: "vv-dropdown-option__hint",
|
|
868
|
-
title:
|
|
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
|
-
})), () => [
|
|
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
|
|
885
|
-
return e(
|
|
946
|
+
function At() {
|
|
947
|
+
return e(W, void 0);
|
|
886
948
|
}
|
|
887
|
-
var
|
|
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
|
-
},
|
|
968
|
+
}, Me),
|
|
907
969
|
setup(e) {
|
|
908
|
-
let t = e, n =
|
|
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 (
|
|
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
|
|
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 &&
|
|
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 && !
|
|
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) =>
|
|
994
|
+
})), t.svg && u(t.svg), (t, i) => k(r) ? (j(), _(k(I), p({
|
|
933
995
|
key: 0,
|
|
934
|
-
class:
|
|
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:
|
|
1004
|
+
rotate: k(n),
|
|
943
1005
|
color: e.color,
|
|
944
|
-
icon:
|
|
945
|
-
}, { onLoad: e.onLoad }), null, 16, ["class", "onLoad"])) :
|
|
1006
|
+
icon: k(c)
|
|
1007
|
+
}, { onLoad: e.onLoad }), null, 16, ["class", "onLoad"])) : D("v-if", !0);
|
|
946
1008
|
}
|
|
947
1009
|
});
|
|
948
|
-
function
|
|
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
|
|
961
|
-
let r =
|
|
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
|
|
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 ?
|
|
1031
|
+
return t[n] = n in e ? Mt(r[n], i, e[n]) : i, t;
|
|
970
1032
|
}, {});
|
|
971
1033
|
});
|
|
972
1034
|
}
|
|
973
|
-
function
|
|
974
|
-
let a, o, 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
|
|
987
|
-
model:
|
|
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
|
|
998
|
-
let n =
|
|
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:
|
|
1002
|
-
hasIconRight:
|
|
1003
|
-
hasIconTop:
|
|
1004
|
-
hasIconBottom:
|
|
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
|
|
1010
|
-
let { focused: n } =
|
|
1071
|
+
function It(e, t) {
|
|
1072
|
+
let { focused: n } = P(e);
|
|
1011
1073
|
return m(n, (n) => {
|
|
1012
|
-
t(n ? "focus" : "blur",
|
|
1074
|
+
t(n ? "focus" : "blur", k(e));
|
|
1013
1075
|
}), { focused: n };
|
|
1014
1076
|
}
|
|
1015
|
-
function
|
|
1016
|
-
let n =
|
|
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:
|
|
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
|
|
1024
|
-
let r =
|
|
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 =
|
|
1030
|
-
n && n !== e && a.removeItem(n), e ? (i =
|
|
1031
|
-
}, { immediate: !0 }),
|
|
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 ===
|
|
1035
|
-
i =
|
|
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 ===
|
|
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
|
|
1109
|
+
var zt = ["for"], Bt = {
|
|
1048
1110
|
key: 0,
|
|
1049
1111
|
class: "vv-textarea__input-before"
|
|
1050
|
-
},
|
|
1112
|
+
}, Vt = { class: "vv-textarea__inner" }, Ht = ["id"], Ut = {
|
|
1051
1113
|
key: 1,
|
|
1052
1114
|
class: "vv-textarea__input-after"
|
|
1053
|
-
},
|
|
1115
|
+
}, Wt = {
|
|
1054
1116
|
key: 2,
|
|
1055
1117
|
class: "vv-textarea__limit"
|
|
1056
|
-
},
|
|
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 =
|
|
1062
|
-
t({ flush:
|
|
1063
|
-
let { hasIconBefore:
|
|
1064
|
-
m(
|
|
1065
|
-
let t =
|
|
1066
|
-
if (e || (t =
|
|
1067
|
-
else if (
|
|
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
|
-
|
|
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
|
|
1073
|
-
m(
|
|
1074
|
-
e && o.autofocus && (
|
|
1134
|
+
let ke = De(f);
|
|
1135
|
+
m(ke, (e) => {
|
|
1136
|
+
e && o.autofocus && (F.value = !0);
|
|
1075
1137
|
});
|
|
1076
|
-
let { formatted:
|
|
1077
|
-
mode:
|
|
1078
|
-
upperLimit: Number(
|
|
1079
|
-
lowerLimit: Number(
|
|
1080
|
-
}),
|
|
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
|
-
}),
|
|
1084
|
-
function
|
|
1085
|
-
|
|
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
|
|
1088
|
-
|
|
1149
|
+
function V(e) {
|
|
1150
|
+
z.value?.delete(e), s("suggestion:removed", e);
|
|
1089
1151
|
}
|
|
1090
|
-
let { HintSlot:
|
|
1091
|
-
valid:
|
|
1092
|
-
invalid:
|
|
1093
|
-
loading:
|
|
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":
|
|
1098
|
-
"icon-after":
|
|
1159
|
+
"icon-before": we.value !== void 0,
|
|
1160
|
+
"icon-after": Te.value !== void 0,
|
|
1099
1161
|
floating: o.floating && !lt(o.label),
|
|
1100
|
-
dirty:
|
|
1101
|
-
focus:
|
|
1162
|
+
dirty: Me.value,
|
|
1163
|
+
focus: F.value,
|
|
1102
1164
|
resizable: o.resizable
|
|
1103
|
-
}))),
|
|
1165
|
+
}))), K = x(() => ({
|
|
1104
1166
|
name: o.name,
|
|
1105
|
-
placeholder:
|
|
1106
|
-
tabindex:
|
|
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":
|
|
1120
|
-
"aria-describedby": [o.ariaDescribedby,
|
|
1121
|
-
"aria-errormessage":
|
|
1122
|
-
})),
|
|
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:
|
|
1191
|
+
clear: Ie
|
|
1130
1192
|
}));
|
|
1131
|
-
function
|
|
1132
|
-
|
|
1193
|
+
function Ie() {
|
|
1194
|
+
N.value = void 0;
|
|
1133
1195
|
}
|
|
1134
|
-
return (e, t) => (
|
|
1135
|
-
|
|
1196
|
+
return (e, t) => (j(), A("div", { class: a(k(G)) }, [
|
|
1197
|
+
k(de) ? (j(), A("label", {
|
|
1136
1198
|
key: 0,
|
|
1137
|
-
for:
|
|
1199
|
+
for: k(M),
|
|
1138
1200
|
class: "vv-textarea__label"
|
|
1139
|
-
},
|
|
1140
|
-
|
|
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 ? (
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
id:
|
|
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) =>
|
|
1153
|
-
},
|
|
1154
|
-
|
|
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 ? (
|
|
1157
|
-
|
|
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(
|
|
1160
|
-
id:
|
|
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:
|
|
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:
|
|
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:
|
|
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:
|
|
1242
|
+
fn: T(() => [c(e.$slots, "invalid", r(i(k(W))))]),
|
|
1181
1243
|
key: "3"
|
|
1182
1244
|
} : void 0
|
|
1183
1245
|
]), 1032, ["id"]),
|
|
1184
|
-
|
|
1246
|
+
k(B) ? (j(), _(Et, {
|
|
1185
1247
|
key: 1,
|
|
1186
1248
|
ref_key: "suggestionsDropdownEl",
|
|
1187
1249
|
ref: g,
|
|
1188
|
-
reference:
|
|
1250
|
+
reference: k(h),
|
|
1189
1251
|
"autofocus-first": !1,
|
|
1190
1252
|
"trigger-width": !0,
|
|
1191
|
-
"top-layer":
|
|
1253
|
+
"top-layer": k(d).topLayer
|
|
1192
1254
|
}, {
|
|
1193
|
-
items:
|
|
1255
|
+
items: T(() => [(j(!0), A(oe, null, te(k(Ne), (t) => (j(), _(kt, {
|
|
1194
1256
|
key: t,
|
|
1195
|
-
onClick:
|
|
1257
|
+
onClick: ie((e) => Pe(t), ["stop"])
|
|
1196
1258
|
}, {
|
|
1197
|
-
default:
|
|
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:
|
|
1203
|
-
onClick:
|
|
1204
|
-
}, [ee(
|
|
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"])) :
|
|
1270
|
+
}, 8, ["reference", "top-layer"])) : D("v-if", !0)
|
|
1209
1271
|
], 2));
|
|
1210
1272
|
}
|
|
1211
1273
|
});
|
|
1212
|
-
export {
|
|
1274
|
+
export { qt as default };
|
|
1213
1275
|
|
|
1214
|
-
//# sourceMappingURL=VvTextarea.es-
|
|
1276
|
+
//# sourceMappingURL=VvTextarea.es-CgvZOWO4.js.map
|