@volverjs/ui-vue 0.0.14 → 0.0.15

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 (97) hide show
  1. package/dist/Volver.d.ts +5 -5
  2. package/dist/components/VvAction/VvAction.es.js +26 -26
  3. package/dist/components/VvAction/VvAction.umd.js +1 -1
  4. package/dist/components/VvAction/index.d.ts +1 -44
  5. package/dist/components/VvAlert/VvAlert.es.js +43 -44
  6. package/dist/components/VvAlert/VvAlert.umd.js +1 -1
  7. package/dist/components/VvAlert/VvAlert.vue.d.ts +1 -1
  8. package/dist/components/VvAlertGroup/VvAlertGroup.es.js +54 -55
  9. package/dist/components/VvAlertGroup/VvAlertGroup.umd.js +1 -1
  10. package/dist/components/VvBreadcrumb/VvBreadcrumb.es.js +34 -34
  11. package/dist/components/VvBreadcrumb/VvBreadcrumb.umd.js +1 -1
  12. package/dist/components/VvBreadcrumb/VvBreadcrumb.vue.d.ts +1 -1
  13. package/dist/components/VvButton/VvButton.es.js +186 -187
  14. package/dist/components/VvButton/VvButton.umd.js +1 -1
  15. package/dist/components/VvCheckbox/VvCheckbox.es.js +215 -217
  16. package/dist/components/VvCheckbox/VvCheckbox.umd.js +1 -1
  17. package/dist/components/VvCheckboxGroup/VvCheckboxGroup.es.js +235 -237
  18. package/dist/components/VvCheckboxGroup/VvCheckboxGroup.umd.js +1 -1
  19. package/dist/components/VvCheckboxGroup/VvCheckboxGroup.vue.d.ts +2 -2
  20. package/dist/components/VvCheckboxGroup/index.d.ts +1 -78
  21. package/dist/components/VvCombobox/VvCombobox.es.js +810 -813
  22. package/dist/components/VvCombobox/VvCombobox.umd.js +1 -1
  23. package/dist/components/VvCombobox/VvCombobox.vue.d.ts +1 -1
  24. package/dist/components/VvCombobox/index.d.ts +2 -2
  25. package/dist/components/VvDropdown/VvDropdown.es.js +4 -4
  26. package/dist/components/VvDropdown/VvDropdown.umd.js +1 -1
  27. package/dist/components/VvDropdownAction/VvDropdownAction.es.js +50 -50
  28. package/dist/components/VvDropdownAction/VvDropdownAction.umd.js +1 -1
  29. package/dist/components/VvIcon/VvIcon.es.js +30 -31
  30. package/dist/components/VvIcon/VvIcon.umd.js +1 -1
  31. package/dist/components/VvInputFile/VvInputFile.es.js +415 -418
  32. package/dist/components/VvInputFile/VvInputFile.umd.js +1 -1
  33. package/dist/components/VvInputText/VvInputText.es.js +595 -588
  34. package/dist/components/VvInputText/VvInputText.umd.js +1 -1
  35. package/dist/components/VvInputText/VvInputText.vue.d.ts +6 -6
  36. package/dist/components/VvInputText/index.d.ts +3 -3
  37. package/dist/components/VvNav/VvNav.es.js +63 -63
  38. package/dist/components/VvNav/VvNav.umd.js +1 -1
  39. package/dist/components/VvNavItem/VvNavItem.es.js +41 -41
  40. package/dist/components/VvNavItem/VvNavItem.umd.js +1 -1
  41. package/dist/components/VvRadio/VvRadio.es.js +222 -224
  42. package/dist/components/VvRadio/VvRadio.umd.js +1 -1
  43. package/dist/components/VvRadioGroup/VvRadioGroup.es.js +234 -236
  44. package/dist/components/VvRadioGroup/VvRadioGroup.umd.js +1 -1
  45. package/dist/components/VvRadioGroup/VvRadioGroup.vue.d.ts +2 -2
  46. package/dist/components/VvRadioGroup/index.d.ts +1 -78
  47. package/dist/components/VvSelect/VvSelect.es.js +200 -203
  48. package/dist/components/VvSelect/VvSelect.umd.js +1 -1
  49. package/dist/components/VvSelect/VvSelect.vue.d.ts +1 -1
  50. package/dist/components/VvSelect/index.d.ts +2 -2
  51. package/dist/components/VvTab/VvTab.es.js +35 -35
  52. package/dist/components/VvTab/VvTab.umd.js +1 -1
  53. package/dist/components/VvTextarea/VvTextarea.es.js +341 -344
  54. package/dist/components/VvTextarea/VvTextarea.umd.js +1 -1
  55. package/dist/components/index.es.js +1965 -1958
  56. package/dist/components/index.umd.js +1 -1
  57. package/dist/composables/index.es.js +34 -34
  58. package/dist/composables/index.umd.js +2 -2
  59. package/dist/composables/useModifiers.d.ts +1 -1
  60. package/dist/constants.d.ts +2 -2
  61. package/dist/directives/index.es.js +22 -22
  62. package/dist/directives/index.umd.js +1 -1
  63. package/dist/directives/v-contextmenu.es.js +13 -13
  64. package/dist/directives/v-contextmenu.umd.js +1 -1
  65. package/dist/index.d.ts +2 -2
  66. package/dist/index.es.js +19 -19
  67. package/dist/index.umd.js +1 -1
  68. package/dist/json-render/index.es.js +1877 -1870
  69. package/dist/json-render/index.umd.js +1 -1
  70. package/dist/props/index.d.ts +1 -1
  71. package/dist/resolvers/unplugin.es.js +28 -28
  72. package/dist/resolvers/unplugin.umd.js +1 -1
  73. package/dist/types/alert.d.ts +1 -1
  74. package/dist/types/nav.d.ts +1 -1
  75. package/dist/utils/ObjectUtilities.d.ts +0 -6
  76. package/package.json +1 -1
  77. package/src/Volver.ts +8 -6
  78. package/src/components/VvAction/index.ts +1 -3
  79. package/src/components/VvButton/VvButton.vue +1 -1
  80. package/src/components/VvCheckboxGroup/index.ts +1 -3
  81. package/src/components/VvCombobox/VvCombobox.vue +3 -3
  82. package/src/components/VvDropdown/VvDropdown.vue +8 -8
  83. package/src/components/VvIcon/VvIcon.vue +3 -6
  84. package/src/components/VvInputFile/VvInputFile.vue +6 -6
  85. package/src/components/VvInputText/VvInputText.vue +95 -78
  86. package/src/components/VvRadioGroup/index.ts +1 -3
  87. package/src/composables/useBlurhash.ts +1 -1
  88. package/src/composables/useDebouncedInput.ts +1 -1
  89. package/src/composables/useDefaults.ts +55 -44
  90. package/src/composables/useModifiers.ts +1 -1
  91. package/src/index.ts +2 -2
  92. package/src/resolvers/unplugin.ts +6 -6
  93. package/src/types/alert.ts +1 -1
  94. package/src/types/nav.ts +1 -1
  95. package/src/utils/DateUtilities.ts +3 -3
  96. package/src/utils/DomUtilities.ts +7 -1
  97. package/src/utils/ObjectUtilities.ts +60 -59
@@ -1,4 +1,4 @@
1
- import { computed as b, createBlock as T, createElementBlock as Z, createTextVNode as R, createVNode as ee, defineComponent as S, getCurrentInstance as te, inject as y, mergeProps as P, openBlock as _, provide as re, ref as h, renderSlot as O, resolveComponent as oe, resolveDynamicComponent as ae, toDisplayString as M, toRefs as ne, unref as s, watch as $, withCtx as m } from "vue";
1
+ import { computed as b, createBlock as T, createElementBlock as Z, createTextVNode as R, createVNode as ee, defineComponent as S, getCurrentInstance as te, inject as y, mergeProps as _, openBlock as P, provide as re, ref as h, renderSlot as O, resolveComponent as oe, resolveDynamicComponent as ae, toDisplayString as M, toRefs as ne, unref as s, watch as $, withCtx as m } from "vue";
2
2
  import "mitt";
3
3
  import { useElementHover as le, useFocus as ue, useFocusWithin as se } from "@vueuse/core";
4
4
  var ie = {
@@ -16,19 +16,19 @@ var ie = {
16
16
  return e.local = "local", e.session = "session", e;
17
17
  })({}), de = /* @__PURE__ */ (function(e) {
18
18
  return e.absolute = "absolute", e.fixed = "fixed", e;
19
- })({}), V = /* @__PURE__ */ (function(e) {
19
+ })({}), j = /* @__PURE__ */ (function(e) {
20
20
  return e.left = "left", e.right = "right", e.top = "top", e.bottom = "bottom", e;
21
21
  })({}), pe = /* @__PURE__ */ (function(e) {
22
22
  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;
23
- })({}), j = /* @__PURE__ */ (function(e) {
23
+ })({}), L = /* @__PURE__ */ (function(e) {
24
24
  return e.before = "before", e.after = "after", e;
25
- })({}), A = /* @__PURE__ */ (function(e) {
25
+ })({}), V = /* @__PURE__ */ (function(e) {
26
26
  return e.button = "button", e.submit = "submit", e.reset = "reset", e;
27
27
  })({}), u = /* @__PURE__ */ (function(e) {
28
28
  return e.nuxtLink = "nuxt-link", e.routerLink = "router-link", e.a = "a", e.button = "button", e;
29
29
  })({}), fe = /* @__PURE__ */ (function(e) {
30
30
  return e.button = "button", e.link = "link", e.menuitem = "menuitem", e;
31
- })({}), L = /* @__PURE__ */ (function(e) {
31
+ })({}), A = /* @__PURE__ */ (function(e) {
32
32
  return e.listbox = "listbox", e.menu = "menu", e;
33
33
  })({}), ve = /* @__PURE__ */ Symbol.for("volver"), ce = /* @__PURE__ */ Symbol.for("dropdownTrigger"), be = /* @__PURE__ */ Symbol.for("dropdownItem"), H = /* @__PURE__ */ Symbol.for("dropdownAction"), ye = {
34
34
  to: { type: [String, Object] },
@@ -80,7 +80,7 @@ var ie = {
80
80
  } }, Se = { current: {
81
81
  type: Boolean,
82
82
  default: !1
83
- } }, Ue = {
83
+ } }, ze = {
84
84
  showClearAction: {
85
85
  type: Boolean,
86
86
  default: !1
@@ -93,7 +93,7 @@ var ie = {
93
93
  type: String,
94
94
  default: "Clear"
95
95
  }
96
- }, Pe = { pressed: {
96
+ }, _e = { pressed: {
97
97
  type: Boolean,
98
98
  default: !1
99
99
  } }, g = { label: {
@@ -108,7 +108,7 @@ var ie = {
108
108
  } }, N = { hintLabel: {
109
109
  type: String,
110
110
  default: ""
111
- } }, _e = {
111
+ } }, Pe = {
112
112
  options: {
113
113
  type: Array,
114
114
  default: () => []
@@ -144,8 +144,8 @@ var ie = {
144
144
  },
145
145
  iconPosition: {
146
146
  type: String,
147
- default: j.before,
148
- validation: (e) => Object.values(j).includes(e)
147
+ default: L.before,
148
+ validation: (e) => Object.values(L).includes(e)
149
149
  }
150
150
  }, x = { tabindex: {
151
151
  type: [String, Number],
@@ -159,8 +159,8 @@ var ie = {
159
159
  } }, F = { id: [String, Number] }, Ie = {
160
160
  placement: {
161
161
  type: String,
162
- default: V.bottom,
163
- validator: (e) => Object.values(V).includes(e) || Object.values(pe).includes(e)
162
+ default: j.bottom,
163
+ validator: (e) => Object.values(j).includes(e) || Object.values(pe).includes(e)
164
164
  },
165
165
  strategy: {
166
166
  type: String,
@@ -223,7 +223,7 @@ var ie = {
223
223
  } }, Ce = { autocomplete: {
224
224
  type: String,
225
225
  default: "off"
226
- } }, Qe = {
226
+ } }, Ue = {
227
227
  ...W,
228
228
  ...Ne,
229
229
  ...Ce,
@@ -253,7 +253,7 @@ var ie = {
253
253
  default: void 0
254
254
  },
255
255
  ...K
256
- }, Xe = {
256
+ }, Qe = {
257
257
  ...W,
258
258
  ...x,
259
259
  ...w,
@@ -281,10 +281,10 @@ var ie = {
281
281
  ],
282
282
  default: void 0
283
283
  }
284
- }, Ze = {
284
+ }, Xe = {
285
285
  ...w,
286
286
  ...B,
287
- ..._e,
287
+ ...Pe,
288
288
  ...N,
289
289
  ...f,
290
290
  ...I,
@@ -313,14 +313,14 @@ var ie = {
313
313
  }, q = {
314
314
  ...f,
315
315
  ...g,
316
- ...Pe,
316
+ ..._e,
317
317
  ...me,
318
318
  ...Se,
319
319
  ...ye,
320
320
  type: {
321
321
  type: String,
322
- default: A.button,
323
- validator: (e) => Object.values(A).includes(e)
322
+ default: V.button,
323
+ validator: (e) => Object.values(V).includes(e)
324
324
  },
325
325
  ariaLabel: {
326
326
  type: String,
@@ -330,7 +330,7 @@ var ie = {
330
330
  type: String,
331
331
  default: u.button
332
332
  }
333
- }, et = {
333
+ }, Ze = {
334
334
  storageType: {
335
335
  type: String,
336
336
  default: E.local,
@@ -341,31 +341,31 @@ var ie = {
341
341
  "click",
342
342
  "mouseover",
343
343
  "mouseleave"
344
- ], Ee = q;
345
- function Ve() {
344
+ ];
345
+ function Ee() {
346
346
  return y(ve, void 0);
347
347
  }
348
348
  function je() {
349
349
  return y(ce, {});
350
350
  }
351
- function Ae() {
351
+ function Le() {
352
352
  return y(be, {});
353
353
  }
354
- function Le() {
354
+ function Ve() {
355
355
  return y(H, {});
356
356
  }
357
- var Te = { name: "VvAction" }, Re = /* @__PURE__ */ S({
358
- ...Te,
359
- props: Ee,
357
+ var Ae = { name: "VvAction" }, Te = /* @__PURE__ */ S({
358
+ ...Ae,
359
+ props: q,
360
360
  emits: De,
361
361
  setup(e, { expose: n, emit: l }) {
362
- const t = e, o = l, a = te(), v = Ve(), p = h(null);
362
+ const t = e, o = l, a = te(), v = Ee(), p = h(null);
363
363
  n({ $el: p });
364
364
  const { reference: i, bus: c, aria: J, expanded: Y } = je();
365
365
  $(() => p.value, (r) => {
366
366
  i && (i.value = r);
367
367
  });
368
- const C = b(() => t.pressed || Y?.value), { role: G } = Le(), D = b(() => {
368
+ const C = b(() => t.pressed || Y?.value), { role: G } = Ve(), D = b(() => {
369
369
  switch (!0) {
370
370
  case t.disabled:
371
371
  return u.button;
@@ -433,7 +433,7 @@ var Te = { name: "VvAction" }, Re = /* @__PURE__ */ S({
433
433
  }
434
434
  c?.emit("mouseleave", r);
435
435
  }
436
- return (r, Je) => (_(), T(ae(s(D)), P(s(z), {
436
+ return (r, qe) => (P(), T(ae(s(D)), _(s(z), {
437
437
  ref_key: "rootEl",
438
438
  ref: p,
439
439
  class: {
@@ -450,7 +450,7 @@ var Te = { name: "VvAction" }, Re = /* @__PURE__ */ S({
450
450
  _: 3
451
451
  }, 16, ["class"]));
452
452
  }
453
- }), Me = Re, tt = {
453
+ }), Re = Te, et = {
454
454
  ...F,
455
455
  ...Ie,
456
456
  ...d,
@@ -464,13 +464,13 @@ var Te = { name: "VvAction" }, Re = /* @__PURE__ */ S({
464
464
  },
465
465
  role: {
466
466
  type: String,
467
- default: L.menu,
468
- validator: (e) => Object.values(L).includes(e)
467
+ default: A.menu,
468
+ validator: (e) => Object.values(A).includes(e)
469
469
  }
470
- }, $e = { focusOnHover: {
470
+ }, Me = { focusOnHover: {
471
471
  type: Boolean,
472
472
  default: !1
473
- } }, rt = {
473
+ } }, tt = {
474
474
  ...f,
475
475
  ...ge,
476
476
  ...ke,
@@ -483,29 +483,29 @@ var Te = { name: "VvAction" }, Re = /* @__PURE__ */ S({
483
483
  default: !1
484
484
  }
485
485
  };
486
- function He({ expanded: e }) {
486
+ function $e({ expanded: e }) {
487
487
  re(H, {
488
488
  role: h(fe.menuitem),
489
489
  expanded: e
490
490
  });
491
491
  }
492
- var Ke = { name: "VvDropdownItem" }, xe = /* @__PURE__ */ S({
493
- ...Ke,
494
- props: $e,
492
+ var He = { name: "VvDropdownItem" }, Ke = /* @__PURE__ */ S({
493
+ ...He,
494
+ props: Me,
495
495
  setup(e) {
496
- const n = e, { role: l, expanded: t } = Ae(), o = h(null);
497
- He({ expanded: t });
496
+ const n = e, { role: l, expanded: t } = Le(), o = h(null);
497
+ $e({ expanded: t });
498
498
  const a = le(o), { focused: v } = ue(o), { focused: p } = se(o);
499
499
  return $(a, (i) => {
500
500
  i && n.focusOnHover && (v.value = !0);
501
- }), (i, c) => (_(), Z("div", P({ role: s(l) }, {
501
+ }), (i, c) => (P(), Z("div", _({ role: s(l) }, {
502
502
  ref_key: "element",
503
503
  ref: o,
504
504
  class: ["vv-dropdown__item", { "focus-visible": s(v) || s(p) }]
505
505
  }), [O(i.$slots, "default")], 16));
506
506
  }
507
- }), Fe = xe;
508
- function We(e, n, l) {
507
+ }), xe = Ke;
508
+ function Fe(e, n, l) {
509
509
  return b(() => {
510
510
  const t = { [e]: !0 }, o = typeof n?.value == "string" ? n.value.split(" ") : n?.value;
511
511
  return o && Array.isArray(o) && o.forEach((a) => {
@@ -515,16 +515,16 @@ function We(e, n, l) {
515
515
  }), t;
516
516
  });
517
517
  }
518
- var qe = /* @__PURE__ */ S({
518
+ var We = /* @__PURE__ */ S({
519
519
  __name: "VvDropdownAction",
520
520
  props: {
521
521
  ...q,
522
522
  ...d
523
523
  },
524
524
  setup(e) {
525
- const { modifiers: n } = ne(e), l = We("vv-dropdown-action", n);
526
- return (t, o) => (_(), T(Fe, null, {
527
- default: m(() => [ee(Me, P({
525
+ const { modifiers: n } = ne(e), l = Fe("vv-dropdown-action", n);
526
+ return (t, o) => (P(), T(xe, null, {
527
+ default: m(() => [ee(Re, _({
528
528
  disabled: t.disabled,
529
529
  pressed: t.pressed,
530
530
  active: t.active,
@@ -540,7 +540,7 @@ var qe = /* @__PURE__ */ S({
540
540
  _: 3
541
541
  }));
542
542
  }
543
- }), ot = qe;
543
+ }), rt = We;
544
544
  export {
545
- ot as default
545
+ rt as default
546
546
  };
@@ -1 +1 @@
1
- (function(t,v){typeof exports=="object"&&typeof module<"u"?module.exports=v(require("vue"),require("mitt"),require("@vueuse/core")):typeof define=="function"&&define.amd?define(["vue","mitt","@vueuse/core"],v):(t=typeof globalThis<"u"?globalThis:t||self,t.VvDropdownAction=v(t.Vue,t.mitt,t.VueuseCore))})(this,function(t,v,g){var x=Object.create,h=Object.defineProperty,M=Object.getOwnPropertyDescriptor,R=Object.getOwnPropertyNames,$=Object.getPrototypeOf,H=Object.prototype.hasOwnProperty,K=(e,a,l,r)=>{if(a&&typeof a=="object"||typeof a=="function")for(var n=R(a),i=0,f=n.length,s;i<f;i++)s=n[i],!H.call(e,s)&&s!==l&&h(e,s,{get:(d=>a[d]).bind(null,s),enumerable:!(r=M(a,s))||r.enumerable});return e},Ae=(e,a,l)=>(l=e!=null?x($(e)):{},K(a||!e||!e.__esModule?h(l,"default",{value:e,enumerable:!0}):l,e)),q={showPassword:"eye-on",hidePassword:"eye-off",showDatePicker:"calendar",showTimePicker:"time",showColorPicker:"color",clear:"close",add:"add",remove:"trash",edit:"edit",download:"download"},w=(function(e){return e.local="local",e.session="session",e})({}),F=(function(e){return e.absolute="absolute",e.fixed="fixed",e})({}),B=(function(e){return e.left="left",e.right="right",e.top="top",e.bottom="bottom",e})({}),W=(function(e){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})({}),j=(function(e){return e.before="before",e.after="after",e})({}),C=(function(e){return e.button="button",e.submit="submit",e.reset="reset",e})({}),u=(function(e){return e.nuxtLink="nuxt-link",e.routerLink="router-link",e.a="a",e.button="button",e})({}),J=(function(e){return e.button="button",e.link="link",e.menuitem="menuitem",e})({}),N=(function(e){return e.listbox="listbox",e.menu="menu",e})({}),Y=Symbol.for("volver"),G=Symbol.for("dropdownTrigger"),z=Symbol.for("dropdownItem"),D=Symbol.for("dropdownAction"),U={to:{type:[String,Object]},href:String,target:String,rel:{type:String,default:"noopener noreferrer"}},m={valid:{type:Boolean,default:!1},validLabel:{type:[String,Array],default:void 0}},_={invalid:{type:Boolean,default:!1},invalidLabel:{type:[String,Array],default:void 0}},P={loading:{type:Boolean,default:!1},loadingLabel:{type:String,default:"Loading..."}},c={disabled:{type:Boolean,default:!1}},I={required:{type:Boolean,default:!1}},Q={selected:{type:Boolean,default:!1}},X={active:{type:Boolean,default:!1}},Z={current:{type:Boolean,default:!1}},Le={showClearAction:{type:Boolean,default:!1},iconClear:{type:[String,Object],default:q.clear},labelClear:{type:String,default:"Clear"}},ee={pressed:{type:Boolean,default:!1}},b={label:{type:[String,Number],default:void 0}},S={readonly:{type:Boolean,default:!1}},p={modifiers:{type:[String,Array],default:void 0}},O={hintLabel:{type:String,default:""}},te={options:{type:Array,default:()=>[]},labelKey:{type:[String,Function],default:"label"},valueKey:{type:[String,Function],default:"value"},disabledKey:{type:[String,Function],default:"disabled"}},re={count:{type:[Boolean,String],default:!1,validator:e=>[!0,!1,"limit","countdown"].includes(e)}},oe={debounce:{type:[Number,String],default:void 0}},ae={icon:{type:[String,Object],default:void 0},iconPosition:{type:String,default:j.before,validation:e=>Object.values(j).includes(e)}},V={tabindex:{type:[String,Number],default:0}},ne={floating:{type:Boolean,default:!1}},le={unselectable:{type:Boolean,default:!0}},k={id:[String,Number]},ie={placement:{type:String,default:B.bottom,validator:e=>Object.values(B).includes(e)||Object.values(W).includes(e)},strategy:{type:String,default:void 0,validator:e=>Object.values(F).includes(e)},transitionName:{type:String,default:void 0},offset:{type:[Number,String,Object],default:0},shift:{type:[Boolean,Object],default:!1},flip:{type:[Boolean,Object],default:!0},size:{type:[Boolean,Object],default:()=>({padding:10})},autoPlacement:{type:[Boolean,Object],default:!1},arrow:{type:Boolean,default:!1},keepOpen:{type:Boolean,default:!1},autofocusFirst:{type:Boolean,default:!0},triggerWidth:{type:Boolean,default:!1}},E={...k,name:{type:String,required:!0}},se={autofocus:{type:Boolean,default:!1}},ue={autocomplete:{type:String,default:"off"}},Te={...E,...se,...ue,...V,...c,...S,...m,..._,...O,...P,...p,...re,...oe,...ae,...ne,...b,minlength:{type:[String,Number],default:void 0},maxlength:{type:[String,Number],default:void 0},placeholder:{type:String,default:void 0},...I},xe={...E,...V,...m,..._,...O,...c,...S,...p,...b,...P,value:{type:[String,Number,Boolean],default:void 0},modelValue:{type:[Object,Number,Boolean,String],default:void 0}},Me={...m,..._,...te,...O,...c,...S,...p,...b,...P,...I,modelValue:{type:[String,Array,Boolean,Number,Symbol],default:void 0},name:{type:String,required:!0},vertical:{type:Boolean,default:!1}},A={...c,...b,...ee,...X,...Z,...U,type:{type:String,default:C.button,validator:e=>Object.values(C).includes(e)},ariaLabel:{type:String,default:void 0},defaultTag:{type:String,default:u.button}},Re={storageType:{type:String,default:w.local,validator:e=>Object.values(w).includes(e)},storageKey:String},de=["click","mouseover","mouseleave"],pe=A;function fe(){return(0,t.inject)(Y,void 0)}function ce(){return(0,t.inject)(G,{})}function ve(){return(0,t.inject)(z,{})}function be(){return(0,t.inject)(D,{})}var ye={name:"VvAction"},ge=(0,t.defineComponent)({...ye,props:pe,emits:de,setup(e,{expose:a,emit:l}){const r=e,n=l,i=(0,t.getCurrentInstance)(),f=fe(),s=(0,t.ref)(null);a({$el:s});const{reference:d,bus:y,aria:Ce,expanded:Ne}=ce();(0,t.watch)(()=>s.value,o=>{d&&(d.value=o)});const L=(0,t.computed)(()=>r.pressed||Ne?.value),{role:De}=be(),T=(0,t.computed)(()=>{switch(!0){case r.disabled:return u.button;case r.to!==void 0:return f?.nuxt?(0,t.resolveComponent)(u.nuxtLink):u.routerLink;case r.href!==void 0:return u.a;default:return r.defaultTag}}),Ie=(0,t.computed)(()=>{const o={...Ce?.value,ariaPressed:L.value?!0:void 0,ariaLabel:r.ariaLabel,role:De?.value};switch(T.value){case u.a:return{...o,href:r.href,target:r.target,rel:r.rel};case u.routerLink:case u.nuxtLink:return{...o,to:r.to,target:r.target};case u.button:return{...o,type:r.type,disabled:r.disabled};default:return o}});function Ve(o){if(r.disabled){o.preventDefault();return}if(i?.vnode.props?.onClick){n("click",o);return}y?.emit("click",o)}function ke(o){if(i?.vnode.props?.onMouseover){n("mouseover",o);return}y?.emit("mouseover",o)}function Ee(o){if(i?.vnode.props?.onMouseleave){n("mouseleave",o);return}y?.emit("mouseleave",o)}return(o,Ke)=>((0,t.openBlock)(),(0,t.createBlock)((0,t.resolveDynamicComponent)((0,t.unref)(T)),(0,t.mergeProps)((0,t.unref)(Ie),{ref_key:"rootEl",ref:s,class:{active:o.active,pressed:(0,t.unref)(L),disabled:o.disabled,current:o.current},onClickPassive:Ve,onMouseoverPassive:ke,onMouseleavePassive:Ee}),{default:(0,t.withCtx)(()=>[(0,t.renderSlot)(o.$slots,"default",{},()=>[(0,t.createTextVNode)((0,t.toDisplayString)(o.label),1)])]),_:3},16,["class"]))}}),me=ge,$e={...k,...ie,...p,modelValue:{type:Boolean,default:void 0},reference:{type:Object,default:null},role:{type:String,default:N.menu,validator:e=>Object.values(N).includes(e)}},_e={focusOnHover:{type:Boolean,default:!1}},He={...c,...Q,...le,...p,deselectHintLabel:{type:String},selectHintLabel:{type:String},selectedHintLabel:{type:String},focusOnHover:{type:Boolean,default:!1}};function Pe({expanded:e}){(0,t.provide)(D,{role:(0,t.ref)(J.menuitem),expanded:e})}var Se={name:"VvDropdownItem"},Oe=(0,t.defineComponent)({...Se,props:_e,setup(e){const a=e,{role:l,expanded:r}=ve(),n=(0,t.ref)(null);Pe({expanded:r});const i=(0,g.useElementHover)(n),{focused:f}=(0,g.useFocus)(n),{focused:s}=(0,g.useFocusWithin)(n);return(0,t.watch)(i,d=>{d&&a.focusOnHover&&(f.value=!0)}),(d,y)=>((0,t.openBlock)(),(0,t.createElementBlock)("div",(0,t.mergeProps)({role:(0,t.unref)(l)},{ref_key:"element",ref:n,class:["vv-dropdown__item",{"focus-visible":(0,t.unref)(f)||(0,t.unref)(s)}]}),[(0,t.renderSlot)(d.$slots,"default")],16))}}),he=Oe;function we(e,a,l){return(0,t.computed)(()=>{const r={[e]:!0},n=typeof a?.value=="string"?a.value.split(" "):a?.value;return n&&Array.isArray(n)&&n.forEach(i=>{i&&(r[`${e}--${i}`]=!0)}),l&&Object.keys(l.value).forEach(i=>{r[`${e}--${i}`]=(0,t.unref)(l.value[i])}),r})}var Be=(0,t.defineComponent)({__name:"VvDropdownAction",props:{...A,...p},setup(e){const{modifiers:a}=(0,t.toRefs)(e),l=we("vv-dropdown-action",a);return(r,n)=>((0,t.openBlock)(),(0,t.createBlock)(he,null,{default:(0,t.withCtx)(()=>[(0,t.createVNode)(me,(0,t.mergeProps)({disabled:r.disabled,pressed:r.pressed,active:r.active,type:r.type,to:r.to,href:r.href,target:r.target,rel:r.rel},{class:(0,t.unref)(l)}),{default:(0,t.withCtx)(()=>[(0,t.renderSlot)(r.$slots,"default",{},()=>[(0,t.createTextVNode)((0,t.toDisplayString)(r.label),1)])]),_:3},16,["class"])]),_:3}))}}),je=Be;return je});
1
+ (function(t,v){typeof exports=="object"&&typeof module<"u"?module.exports=v(require("vue"),require("mitt"),require("@vueuse/core")):typeof define=="function"&&define.amd?define(["vue","mitt","@vueuse/core"],v):(t=typeof globalThis<"u"?globalThis:t||self,t.VvDropdownAction=v(t.Vue,t.mitt,t.VueuseCore))})(this,function(t,v,g){var x=Object.create,h=Object.defineProperty,M=Object.getOwnPropertyDescriptor,R=Object.getOwnPropertyNames,$=Object.getPrototypeOf,H=Object.prototype.hasOwnProperty,K=(e,a,l,r)=>{if(a&&typeof a=="object"||typeof a=="function")for(var n=R(a),i=0,f=n.length,s;i<f;i++)s=n[i],!H.call(e,s)&&s!==l&&h(e,s,{get:(d=>a[d]).bind(null,s),enumerable:!(r=M(a,s))||r.enumerable});return e},Ee=(e,a,l)=>(l=e!=null?x($(e)):{},K(a||!e||!e.__esModule?h(l,"default",{value:e,enumerable:!0}):l,e)),q={showPassword:"eye-on",hidePassword:"eye-off",showDatePicker:"calendar",showTimePicker:"time",showColorPicker:"color",clear:"close",add:"add",remove:"trash",edit:"edit",download:"download"},w=(function(e){return e.local="local",e.session="session",e})({}),F=(function(e){return e.absolute="absolute",e.fixed="fixed",e})({}),B=(function(e){return e.left="left",e.right="right",e.top="top",e.bottom="bottom",e})({}),W=(function(e){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})({}),j=(function(e){return e.before="before",e.after="after",e})({}),C=(function(e){return e.button="button",e.submit="submit",e.reset="reset",e})({}),u=(function(e){return e.nuxtLink="nuxt-link",e.routerLink="router-link",e.a="a",e.button="button",e})({}),J=(function(e){return e.button="button",e.link="link",e.menuitem="menuitem",e})({}),N=(function(e){return e.listbox="listbox",e.menu="menu",e})({}),Y=Symbol.for("volver"),G=Symbol.for("dropdownTrigger"),z=Symbol.for("dropdownItem"),D=Symbol.for("dropdownAction"),U={to:{type:[String,Object]},href:String,target:String,rel:{type:String,default:"noopener noreferrer"}},m={valid:{type:Boolean,default:!1},validLabel:{type:[String,Array],default:void 0}},_={invalid:{type:Boolean,default:!1},invalidLabel:{type:[String,Array],default:void 0}},P={loading:{type:Boolean,default:!1},loadingLabel:{type:String,default:"Loading..."}},c={disabled:{type:Boolean,default:!1}},I={required:{type:Boolean,default:!1}},Q={selected:{type:Boolean,default:!1}},X={active:{type:Boolean,default:!1}},Z={current:{type:Boolean,default:!1}},Ae={showClearAction:{type:Boolean,default:!1},iconClear:{type:[String,Object],default:q.clear},labelClear:{type:String,default:"Clear"}},ee={pressed:{type:Boolean,default:!1}},b={label:{type:[String,Number],default:void 0}},S={readonly:{type:Boolean,default:!1}},p={modifiers:{type:[String,Array],default:void 0}},O={hintLabel:{type:String,default:""}},te={options:{type:Array,default:()=>[]},labelKey:{type:[String,Function],default:"label"},valueKey:{type:[String,Function],default:"value"},disabledKey:{type:[String,Function],default:"disabled"}},re={count:{type:[Boolean,String],default:!1,validator:e=>[!0,!1,"limit","countdown"].includes(e)}},oe={debounce:{type:[Number,String],default:void 0}},ae={icon:{type:[String,Object],default:void 0},iconPosition:{type:String,default:j.before,validation:e=>Object.values(j).includes(e)}},V={tabindex:{type:[String,Number],default:0}},ne={floating:{type:Boolean,default:!1}},le={unselectable:{type:Boolean,default:!0}},k={id:[String,Number]},ie={placement:{type:String,default:B.bottom,validator:e=>Object.values(B).includes(e)||Object.values(W).includes(e)},strategy:{type:String,default:void 0,validator:e=>Object.values(F).includes(e)},transitionName:{type:String,default:void 0},offset:{type:[Number,String,Object],default:0},shift:{type:[Boolean,Object],default:!1},flip:{type:[Boolean,Object],default:!0},size:{type:[Boolean,Object],default:()=>({padding:10})},autoPlacement:{type:[Boolean,Object],default:!1},arrow:{type:Boolean,default:!1},keepOpen:{type:Boolean,default:!1},autofocusFirst:{type:Boolean,default:!0},triggerWidth:{type:Boolean,default:!1}},E={...k,name:{type:String,required:!0}},se={autofocus:{type:Boolean,default:!1}},ue={autocomplete:{type:String,default:"off"}},Le={...E,...se,...ue,...V,...c,...S,...m,..._,...O,...P,...p,...re,...oe,...ae,...ne,...b,minlength:{type:[String,Number],default:void 0},maxlength:{type:[String,Number],default:void 0},placeholder:{type:String,default:void 0},...I},Te={...E,...V,...m,..._,...O,...c,...S,...p,...b,...P,value:{type:[String,Number,Boolean],default:void 0},modelValue:{type:[Object,Number,Boolean,String],default:void 0}},xe={...m,..._,...te,...O,...c,...S,...p,...b,...P,...I,modelValue:{type:[String,Array,Boolean,Number,Symbol],default:void 0},name:{type:String,required:!0},vertical:{type:Boolean,default:!1}},A={...c,...b,...ee,...X,...Z,...U,type:{type:String,default:C.button,validator:e=>Object.values(C).includes(e)},ariaLabel:{type:String,default:void 0},defaultTag:{type:String,default:u.button}},Me={storageType:{type:String,default:w.local,validator:e=>Object.values(w).includes(e)},storageKey:String},de=["click","mouseover","mouseleave"];function pe(){return(0,t.inject)(Y,void 0)}function fe(){return(0,t.inject)(G,{})}function ce(){return(0,t.inject)(z,{})}function ve(){return(0,t.inject)(D,{})}var be={name:"VvAction"},ye=(0,t.defineComponent)({...be,props:A,emits:de,setup(e,{expose:a,emit:l}){const r=e,n=l,i=(0,t.getCurrentInstance)(),f=pe(),s=(0,t.ref)(null);a({$el:s});const{reference:d,bus:y,aria:je,expanded:Ce}=fe();(0,t.watch)(()=>s.value,o=>{d&&(d.value=o)});const L=(0,t.computed)(()=>r.pressed||Ce?.value),{role:Ne}=ve(),T=(0,t.computed)(()=>{switch(!0){case r.disabled:return u.button;case r.to!==void 0:return f?.nuxt?(0,t.resolveComponent)(u.nuxtLink):u.routerLink;case r.href!==void 0:return u.a;default:return r.defaultTag}}),De=(0,t.computed)(()=>{const o={...je?.value,ariaPressed:L.value?!0:void 0,ariaLabel:r.ariaLabel,role:Ne?.value};switch(T.value){case u.a:return{...o,href:r.href,target:r.target,rel:r.rel};case u.routerLink:case u.nuxtLink:return{...o,to:r.to,target:r.target};case u.button:return{...o,type:r.type,disabled:r.disabled};default:return o}});function Ie(o){if(r.disabled){o.preventDefault();return}if(i?.vnode.props?.onClick){n("click",o);return}y?.emit("click",o)}function Ve(o){if(i?.vnode.props?.onMouseover){n("mouseover",o);return}y?.emit("mouseover",o)}function ke(o){if(i?.vnode.props?.onMouseleave){n("mouseleave",o);return}y?.emit("mouseleave",o)}return(o,He)=>((0,t.openBlock)(),(0,t.createBlock)((0,t.resolveDynamicComponent)((0,t.unref)(T)),(0,t.mergeProps)((0,t.unref)(De),{ref_key:"rootEl",ref:s,class:{active:o.active,pressed:(0,t.unref)(L),disabled:o.disabled,current:o.current},onClickPassive:Ie,onMouseoverPassive:Ve,onMouseleavePassive:ke}),{default:(0,t.withCtx)(()=>[(0,t.renderSlot)(o.$slots,"default",{},()=>[(0,t.createTextVNode)((0,t.toDisplayString)(o.label),1)])]),_:3},16,["class"]))}}),ge=ye,Re={...k,...ie,...p,modelValue:{type:Boolean,default:void 0},reference:{type:Object,default:null},role:{type:String,default:N.menu,validator:e=>Object.values(N).includes(e)}},me={focusOnHover:{type:Boolean,default:!1}},$e={...c,...Q,...le,...p,deselectHintLabel:{type:String},selectHintLabel:{type:String},selectedHintLabel:{type:String},focusOnHover:{type:Boolean,default:!1}};function _e({expanded:e}){(0,t.provide)(D,{role:(0,t.ref)(J.menuitem),expanded:e})}var Pe={name:"VvDropdownItem"},Se=(0,t.defineComponent)({...Pe,props:me,setup(e){const a=e,{role:l,expanded:r}=ce(),n=(0,t.ref)(null);_e({expanded:r});const i=(0,g.useElementHover)(n),{focused:f}=(0,g.useFocus)(n),{focused:s}=(0,g.useFocusWithin)(n);return(0,t.watch)(i,d=>{d&&a.focusOnHover&&(f.value=!0)}),(d,y)=>((0,t.openBlock)(),(0,t.createElementBlock)("div",(0,t.mergeProps)({role:(0,t.unref)(l)},{ref_key:"element",ref:n,class:["vv-dropdown__item",{"focus-visible":(0,t.unref)(f)||(0,t.unref)(s)}]}),[(0,t.renderSlot)(d.$slots,"default")],16))}}),Oe=Se;function he(e,a,l){return(0,t.computed)(()=>{const r={[e]:!0},n=typeof a?.value=="string"?a.value.split(" "):a?.value;return n&&Array.isArray(n)&&n.forEach(i=>{i&&(r[`${e}--${i}`]=!0)}),l&&Object.keys(l.value).forEach(i=>{r[`${e}--${i}`]=(0,t.unref)(l.value[i])}),r})}var we=(0,t.defineComponent)({__name:"VvDropdownAction",props:{...A,...p},setup(e){const{modifiers:a}=(0,t.toRefs)(e),l=he("vv-dropdown-action",a);return(r,n)=>((0,t.openBlock)(),(0,t.createBlock)(Oe,null,{default:(0,t.withCtx)(()=>[(0,t.createVNode)(ge,(0,t.mergeProps)({disabled:r.disabled,pressed:r.pressed,active:r.active,type:r.type,to:r.to,href:r.href,target:r.target,rel:r.rel},{class:(0,t.unref)(l)}),{default:(0,t.withCtx)(()=>[(0,t.renderSlot)(r.$slots,"default",{},()=>[(0,t.createTextVNode)((0,t.toDisplayString)(r.label),1)])]),_:3},16,["class"])]),_:3}))}}),Be=we;return Be});
@@ -1,21 +1,21 @@
1
- import { computed as f, createBlock as $, createCommentVNode as w, defineComponent as y, inject as x, mergeDefaults as C, mergeProps as F, openBlock as I, ref as V, toRefs as E, unref as l } from "vue";
2
- import { Icon as b, addIcon as B, iconLoaded as v } from "@iconify/vue";
1
+ import { computed as v, createBlock as $, createCommentVNode as y, defineComponent as w, inject as x, mergeDefaults as C, mergeProps as F, openBlock as I, ref as V, toRefs as b, unref as l } from "vue";
2
+ import { Icon as E, addIcon as B, iconLoaded as f } from "@iconify/vue";
3
3
  var L = { prefix: "normal" }, N = /* @__PURE__ */ Symbol.for("volver");
4
- function P() {
4
+ function S() {
5
5
  return x(N, void 0);
6
6
  }
7
- function S(o, e, c) {
8
- return f(() => {
9
- const n = { [o]: !0 }, i = typeof e?.value == "string" ? e.value.split(" ") : e?.value;
10
- return i && Array.isArray(i) && i.forEach((a) => {
11
- a && (n[`${o}--${a}`] = !0);
7
+ function O(o, e, c) {
8
+ return v(() => {
9
+ const r = { [o]: !0 }, n = typeof e?.value == "string" ? e.value.split(" ") : e?.value;
10
+ return n && Array.isArray(n) && n.forEach((a) => {
11
+ a && (r[`${o}--${a}`] = !0);
12
12
  }), c && Object.keys(c.value).forEach((a) => {
13
- n[`${o}--${a}`] = l(c.value[a]);
14
- }), n;
13
+ r[`${o}--${a}`] = l(c.value[a]);
14
+ }), r;
15
15
  });
16
16
  }
17
- var O = { name: "VvIcon" }, R = /* @__PURE__ */ y({
18
- ...O,
17
+ var P = { name: "VvIcon" }, R = /* @__PURE__ */ w({
18
+ ...P,
19
19
  props: /* @__PURE__ */ C({
20
20
  name: {},
21
21
  color: {},
@@ -35,31 +35,30 @@ var O = { name: "VvIcon" }, R = /* @__PURE__ */ y({
35
35
  modifiers: {}
36
36
  }, L),
37
37
  setup(o) {
38
- const e = o, c = f(() => typeof e.rotate == "string" ? Number.parseFloat(e.rotate) : e.rotate), n = V(!0), i = P(), { modifiers: a } = E(e), m = S("vv-icon", a), u = f(() => e.provider || i?.iconsProvider), h = f(() => {
39
- const t = e.name ?? "", r = `@${u.value}:${e.prefix}:${t}`;
40
- if (v(r)) return r;
41
- const s = i?.iconsCollections.find((g) => v(`@${u.value}:${g.prefix}:${t}`));
38
+ const e = o, c = v(() => typeof e.rotate == "string" ? Number.parseFloat(e.rotate) : e.rotate), r = V(!0), n = S(), { modifiers: a } = b(e), h = O("vv-icon", a), u = v(() => e.provider || n?.iconsProvider), m = v(() => {
39
+ const t = e.name ?? "", i = `@${u.value}:${e.prefix}:${t}`;
40
+ if (f(i)) return i;
41
+ const s = n?.iconsCollections.find((g) => f(`@${u.value}:${g.prefix}:${t}`));
42
42
  return s ? `@${u.value}:${s.prefix}:${t}` : t;
43
43
  });
44
44
  function p(t) {
45
- const r = typeof window < "u" ? new window.DOMParser() : null;
46
- return r ? r.parseFromString(t, "text/html").querySelector("svg") : null;
45
+ return globalThis.window === void 0 ? null : new globalThis.DOMParser().parseFromString(t, "text/html").querySelector("svg");
47
46
  }
48
47
  function d(t) {
49
- const r = p(t), s = r?.innerHTML.trim() || "";
50
- r && s && B(`@${u.value}:${e.prefix}:${e.name}`, {
48
+ const i = p(t), s = i?.innerHTML.trim() || "";
49
+ i && s && B(`@${u.value}:${e.prefix}:${e.name}`, {
51
50
  body: s,
52
- height: r.viewBox.baseVal.height,
53
- width: r.viewBox.baseVal.width
51
+ height: i.viewBox.baseVal.height,
52
+ width: i.viewBox.baseVal.width
54
53
  });
55
54
  }
56
- return i && e.src && !v(`@${u.value}:${e.prefix}:${e.name}`) && (n.value = !1, i.fetchIcon(e.src).then((t) => {
57
- t && d(t), n.value = !0;
55
+ return n && e.src && !f(`@${u.value}:${e.prefix}:${e.name}`) && (r.value = !1, n.fetchIcon(e.src).then((t) => {
56
+ t && d(t), r.value = !0;
58
57
  }).catch((t) => {
59
- throw n.value = !0, new Error(`Error during fetch icon: ${t?.message}`);
60
- })), e.svg && d(e.svg), (t, r) => l(n) ? (I(), $(l(b), F({
58
+ throw r.value = !0, new Error(`Error during fetch icon: ${t?.message}`);
59
+ })), e.svg && d(e.svg), (t, i) => l(r) ? (I(), $(l(E), F({
61
60
  key: 0,
62
- class: l(m)
61
+ class: l(h)
63
62
  }, {
64
63
  inline: o.inline,
65
64
  width: o.width,
@@ -69,10 +68,10 @@ var O = { name: "VvIcon" }, R = /* @__PURE__ */ y({
69
68
  flip: o.flip,
70
69
  rotate: l(c),
71
70
  color: o.color,
72
- icon: l(h)
73
- }, { onLoad: o.onLoad }), null, 16, ["class", "onLoad"])) : w("v-if", !0);
71
+ icon: l(m)
72
+ }, { onLoad: o.onLoad }), null, 16, ["class", "onLoad"])) : y("v-if", !0);
74
73
  }
75
- }), A = R;
74
+ }), z = R;
76
75
  export {
77
- A as default
76
+ z as default
78
77
  };
@@ -1 +1 @@
1
- (function(e,i){typeof exports=="object"&&typeof module<"u"?module.exports=i(require("vue"),require("@iconify/vue")):typeof define=="function"&&define.amd?define(["vue","@iconify/vue"],i):(e=typeof globalThis<"u"?globalThis:e||self,e.VvIcon=i(e.Vue,e.IconifyVue))})(this,function(e,i){var p={prefix:"normal"},v=Symbol.for("volver");function h(){return(0,e.inject)(v,void 0)}function m(o,n,s){return(0,e.computed)(()=>{const a={[o]:!0},c=typeof n?.value=="string"?n.value.split(" "):n?.value;return c&&Array.isArray(c)&&c.forEach(l=>{l&&(a[`${o}--${l}`]=!0)}),s&&Object.keys(s.value).forEach(l=>{a[`${o}--${l}`]=(0,e.unref)(s.value[l])}),a})}var $={name:"VvIcon"},g=(0,e.defineComponent)({...$,props:(0,e.mergeDefaults)({name:{},color:{},width:{},height:{},provider:{},prefix:{},src:{},horizontalFlip:{type:Boolean},verticalFlip:{type:Boolean},flip:{},mode:{},inline:{type:Boolean},rotate:{},onLoad:{type:Function},svg:{},modifiers:{}},p),setup(o){const n=o,s=(0,e.computed)(()=>typeof n.rotate=="string"?Number.parseFloat(n.rotate):n.rotate),a=(0,e.ref)(!0),c=h(),{modifiers:l}=(0,e.toRefs)(n),w=m("vv-icon",l),f=(0,e.computed)(()=>n.provider||c?.iconsProvider),V=(0,e.computed)(()=>{const t=n.name??"",r=`@${f.value}:${n.prefix}:${t}`;if((0,i.iconLoaded)(r))return r;const u=c?.iconsCollections.find(x=>(0,i.iconLoaded)(`@${f.value}:${x.prefix}:${t}`));return u?`@${f.value}:${u.prefix}:${t}`:t});function I(t){const r=typeof window<"u"?new window.DOMParser:null;return r?r.parseFromString(t,"text/html").querySelector("svg"):null}function d(t){const r=I(t),u=r?.innerHTML.trim()||"";r&&u&&(0,i.addIcon)(`@${f.value}:${n.prefix}:${n.name}`,{body:u,height:r.viewBox.baseVal.height,width:r.viewBox.baseVal.width})}return c&&n.src&&!(0,i.iconLoaded)(`@${f.value}:${n.prefix}:${n.name}`)&&(a.value=!1,c.fetchIcon(n.src).then(t=>{t&&d(t),a.value=!0}).catch(t=>{throw a.value=!0,new Error(`Error during fetch icon: ${t?.message}`)})),n.svg&&d(n.svg),(t,r)=>(0,e.unref)(a)?((0,e.openBlock)(),(0,e.createBlock)((0,e.unref)(i.Icon),(0,e.mergeProps)({key:0,class:(0,e.unref)(w)},{inline:o.inline,width:o.width,height:o.height,horizontalFlip:o.horizontalFlip,verticalFlip:o.verticalFlip,flip:o.flip,rotate:(0,e.unref)(s),color:o.color,icon:(0,e.unref)(V)},{onLoad:o.onLoad}),null,16,["class","onLoad"])):(0,e.createCommentVNode)("v-if",!0)}}),y=g;return y});
1
+ (function(e,r){typeof exports=="object"&&typeof module<"u"?module.exports=r(require("vue"),require("@iconify/vue")):typeof define=="function"&&define.amd?define(["vue","@iconify/vue"],r):(e=typeof globalThis<"u"?globalThis:e||self,e.VvIcon=r(e.Vue,e.IconifyVue))})(this,function(e,r){var v={prefix:"normal"},h=Symbol.for("volver");function p(){return(0,e.inject)(h,void 0)}function m(o,n,s){return(0,e.computed)(()=>{const i={[o]:!0},a=typeof n?.value=="string"?n.value.split(" "):n?.value;return a&&Array.isArray(a)&&a.forEach(l=>{l&&(i[`${o}--${l}`]=!0)}),s&&Object.keys(s.value).forEach(l=>{i[`${o}--${l}`]=(0,e.unref)(s.value[l])}),i})}var g={name:"VvIcon"},$=(0,e.defineComponent)({...g,props:(0,e.mergeDefaults)({name:{},color:{},width:{},height:{},provider:{},prefix:{},src:{},horizontalFlip:{type:Boolean},verticalFlip:{type:Boolean},flip:{},mode:{},inline:{type:Boolean},rotate:{},onLoad:{type:Function},svg:{},modifiers:{}},v),setup(o){const n=o,s=(0,e.computed)(()=>typeof n.rotate=="string"?Number.parseFloat(n.rotate):n.rotate),i=(0,e.ref)(!0),a=p(),{modifiers:l}=(0,e.toRefs)(n),w=m("vv-icon",l),f=(0,e.computed)(()=>n.provider||a?.iconsProvider),V=(0,e.computed)(()=>{const t=n.name??"",c=`@${f.value}:${n.prefix}:${t}`;if((0,r.iconLoaded)(c))return c;const u=a?.iconsCollections.find(x=>(0,r.iconLoaded)(`@${f.value}:${x.prefix}:${t}`));return u?`@${f.value}:${u.prefix}:${t}`:t});function I(t){return globalThis.window===void 0?null:new globalThis.DOMParser().parseFromString(t,"text/html").querySelector("svg")}function d(t){const c=I(t),u=c?.innerHTML.trim()||"";c&&u&&(0,r.addIcon)(`@${f.value}:${n.prefix}:${n.name}`,{body:u,height:c.viewBox.baseVal.height,width:c.viewBox.baseVal.width})}return a&&n.src&&!(0,r.iconLoaded)(`@${f.value}:${n.prefix}:${n.name}`)&&(i.value=!1,a.fetchIcon(n.src).then(t=>{t&&d(t),i.value=!0}).catch(t=>{throw i.value=!0,new Error(`Error during fetch icon: ${t?.message}`)})),n.svg&&d(n.svg),(t,c)=>(0,e.unref)(i)?((0,e.openBlock)(),(0,e.createBlock)((0,e.unref)(r.Icon),(0,e.mergeProps)({key:0,class:(0,e.unref)(w)},{inline:o.inline,width:o.width,height:o.height,horizontalFlip:o.horizontalFlip,verticalFlip:o.verticalFlip,flip:o.flip,rotate:(0,e.unref)(s),color:o.color,icon:(0,e.unref)(V)},{onLoad:o.onLoad}),null,16,["class","onLoad"])):(0,e.createCommentVNode)("v-if",!0)}}),y=$;return y});