maz-ui 3.47.1 → 3.47.2-beta.0

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 (96) hide show
  1. package/components/MazCard.mjs +1 -1
  2. package/components/MazChart.d.ts +1 -1
  3. package/components/MazChecklist.mjs +1 -1
  4. package/components/MazGallery.mjs +1 -1
  5. package/components/MazInput.mjs +1 -1
  6. package/components/MazInputNumber.mjs +1 -1
  7. package/components/MazInputPrice.mjs +1 -1
  8. package/components/MazInputTags.mjs +1 -1
  9. package/components/MazPhoneNumberInput.mjs +1 -1
  10. package/components/MazPicker.mjs +1 -1
  11. package/components/MazSelect.mjs +1 -1
  12. package/components/MazTable.d.ts +29 -52
  13. package/components/MazTable.mjs +1 -1
  14. package/components/MazTabsBar.mjs +1 -1
  15. package/components/assets/MazDropdown.css +1 -1
  16. package/components/assets/MazGallery.css +1 -1
  17. package/components/assets/MazInput.css +1 -1
  18. package/components/assets/MazInputNumber.css +1 -1
  19. package/components/assets/MazInputPrice.css +1 -1
  20. package/components/assets/MazInputTags.css +1 -1
  21. package/components/assets/MazPhoneNumberInput.css +1 -1
  22. package/components/assets/MazPicker.css +1 -1
  23. package/components/assets/MazSelect.css +1 -1
  24. package/components/assets/MazTable.css +1 -1
  25. package/components/assets/MazTabsBar.css +1 -1
  26. package/components/chunks/{MazBadge-CNSfzYq-.mjs → MazBadge-CvIiiTdM.mjs} +1 -1
  27. package/components/chunks/{MazBtn-D6Jxw9Nr.mjs → MazBtn-BO3G90L3.mjs} +2 -2
  28. package/components/chunks/{MazBtn-BRnLMzhy.mjs → MazBtn-C87UEsVs.mjs} +2 -2
  29. package/components/chunks/{MazBtn-DlD5m7T4.mjs → MazBtn-C_l3xuAh.mjs} +2 -2
  30. package/components/chunks/{MazBtn-CnqRnXh_.mjs → MazBtn-DJOUeES7.mjs} +2 -2
  31. package/components/chunks/{MazBtn-TkePGm5o.mjs → MazBtn-DVkwISlp.mjs} +2 -2
  32. package/components/chunks/MazBtn-DadFupkY.mjs +118 -0
  33. package/components/chunks/{MazBtn-Dt8lr0GH.mjs → MazBtn-GGcGrIH4.mjs} +2 -2
  34. package/components/chunks/{MazCard-CfkvpcGL.mjs → MazCard-FSXmHyhj.mjs} +1 -1
  35. package/components/chunks/{MazCheckbox-BKCo6EzO.mjs → MazCheckbox-2G4VkxDz.mjs} +1 -1
  36. package/components/chunks/{MazCheckbox-Byqz8JJB.mjs → MazCheckbox-BmnqBHaY.mjs} +1 -1
  37. package/components/chunks/{MazCheckbox-CI8ml-P8.mjs → MazCheckbox-Cq9gpTEw.mjs} +1 -1
  38. package/components/chunks/{MazChecklist-BLxsNHMP.mjs → MazChecklist-CY1Cv70T.mjs} +1 -1
  39. package/components/chunks/{MazGallery-BMFwld84.mjs → MazGallery-BknvUeo1.mjs} +272 -229
  40. package/components/chunks/{MazGallery-BKL7gfrz.mjs → MazGallery-CZOokGAt.mjs} +248 -205
  41. package/components/chunks/{MazIcon-D8V8ixhf.mjs → MazIcon-z-jTiuyI.mjs} +1 -1
  42. package/components/chunks/{MazInput-CBiCdd0F.mjs → MazInput-BQoQSRyL.mjs} +2 -2
  43. package/components/chunks/{MazInput-Dx2cCzFS.mjs → MazInput-CJQB68c-.mjs} +22 -22
  44. package/components/chunks/{MazInput-O6Q41Fm0.mjs → MazInput-oOA7gdLO.mjs} +23 -23
  45. package/components/chunks/{MazInputNumber-DYPVUz4k.mjs → MazInputNumber-B4mQJcVB.mjs} +2 -2
  46. package/components/chunks/{MazInputPrice-DZD7ZZpm.mjs → MazInputPrice-BrxE5WVf.mjs} +2 -2
  47. package/components/chunks/{MazInputTags-CxXBsTdM.mjs → MazInputTags-BVCej_gW.mjs} +233 -232
  48. package/components/chunks/{MazLoadingBar-Di2OIrPD.mjs → MazLoadingBar-Dwf55oHy.mjs} +1 -1
  49. package/components/chunks/{MazPhoneNumberInput-C4TX1tGw.mjs → MazPhoneNumberInput-Cd25AzXc.mjs} +10 -10
  50. package/components/chunks/{MazPicker-BcQ_-AJH.mjs → MazPicker-C78yxilJ.mjs} +3 -3
  51. package/components/chunks/{MazPickerMonthSwitcher-hCAkEd5r.mjs → MazPickerMonthSwitcher-CyHYx8TT.mjs} +1 -1
  52. package/components/chunks/{MazPickerShortcuts-vpLyw1de.mjs → MazPickerShortcuts-Bsi8cnox.mjs} +1 -1
  53. package/components/chunks/{MazPickerYearSwitcher-DvC79vrt.mjs → MazPickerYearSwitcher-DLUSMAtz.mjs} +1 -1
  54. package/components/chunks/{MazSelect-BXzgSKmL.mjs → MazSelect-CQDoUpgp.mjs} +15 -14
  55. package/components/chunks/{MazSelect-Baj2BQH7.mjs → MazSelect-uCJPMXF-.mjs} +3 -3
  56. package/components/chunks/{MazSpinner-DwSGm0-X.mjs → MazSpinner-2D0ZmAQz.mjs} +1 -1
  57. package/components/chunks/MazSpinner-B9OwpEP_.mjs +34 -0
  58. package/components/chunks/{MazSpinner-C1SiKhfK.mjs → MazSpinner-BT_717pD.mjs} +1 -1
  59. package/components/chunks/{MazSpinner-Cg26sBU2.mjs → MazSpinner-C1Ip-Dwh.mjs} +1 -1
  60. package/components/chunks/MazSpinner-C23CZ_Za.mjs +34 -0
  61. package/components/chunks/{MazSpinner-B5lezvu4.mjs → MazSpinner-CViChjTw.mjs} +1 -1
  62. package/components/chunks/MazSpinner-CZMBhCOJ.mjs +34 -0
  63. package/components/chunks/{MazSpinner-DlMKBtyt.mjs → MazSpinner-D4C84xZe.mjs} +1 -1
  64. package/components/chunks/{MazSpinner-B8akphXs.mjs → MazSpinner-EFo8dM46.mjs} +1 -1
  65. package/components/chunks/MazSpinner-u8WQTgUR.mjs +34 -0
  66. package/components/chunks/{MazSpinner-M4r0cykl.mjs → MazSpinner-w-S5uCxg.mjs} +1 -1
  67. package/components/chunks/{MazTable-CulBGLaj.mjs → MazTable-Cuz5QI08.mjs} +4 -4
  68. package/components/chunks/{MazTableCell-BXDbkEJq.mjs → MazTableCell-D_OTOJiy.mjs} +1 -1
  69. package/components/chunks/{MazTableRow-Ds3CDEit.mjs → MazTableRow-BTcVAyOy.mjs} +1 -1
  70. package/components/chunks/{MazTableTitle-uirsgvk_.mjs → MazTableTitle-BDA9G6Zw.mjs} +1 -1
  71. package/components/chunks/{MazTabsBar-MZYefBb8.mjs → MazTabsBar-JkRzMDM6.mjs} +9 -10
  72. package/components/chunks/{MazTransitionExpand-4Ll_5LDO.mjs → MazTransitionExpand-C-FHhOGB.mjs} +1 -1
  73. package/css/main.css +1 -1
  74. package/modules/assets/index.css +1 -1
  75. package/modules/chunks/{MazBtn-CTqI4qhg.mjs → MazBtn-BSnVxud6.mjs} +2 -2
  76. package/modules/chunks/{MazBtn-D_CpNgpD.cjs → MazBtn-Bf9Cq5M7.cjs} +1 -1
  77. package/modules/chunks/{MazIcon-BB0DMfOc.mjs → MazIcon-DllGg8tw.mjs} +1 -1
  78. package/modules/chunks/{MazIcon-BtomZnkQ.cjs → MazIcon-dhyR9Q8a.cjs} +1 -1
  79. package/modules/chunks/{MazSpinner-BASKjaLe.cjs → MazSpinner-CiIyZ8gs.cjs} +1 -1
  80. package/modules/chunks/{MazSpinner-CDJhmIRl.mjs → MazSpinner-bdGjxsu6.mjs} +1 -1
  81. package/modules/chunks/index-BPqjUr5e.cjs +149 -0
  82. package/modules/chunks/{index-C2yAjM0P.mjs → index-x2F1l5sr.mjs} +944 -915
  83. package/modules/index.cjs +1 -1
  84. package/modules/index.mjs +1 -1
  85. package/nuxt/index.json +1 -1
  86. package/package.json +1 -1
  87. package/types/components/MazChart.vue.d.ts +1 -1
  88. package/types/components/MazTable.vue.d.ts +29 -52
  89. package/types/modules/directives/v-fullscreen-img/MazFullscreenImg.vue.d.ts +5 -5
  90. package/types/modules/helpers/check-availability.d.ts +1 -0
  91. package/components/chunks/MazBtn-igor8wRn.mjs +0 -118
  92. package/components/chunks/MazSpinner-CvT-9sC7.mjs +0 -34
  93. package/components/chunks/MazSpinner-DH6C15pU.mjs +0 -34
  94. package/components/chunks/MazSpinner-cqcpf_FX.mjs +0 -34
  95. package/components/chunks/MazSpinner-yPkPj7Q8.mjs +0 -34
  96. package/modules/chunks/index-BIX1NMzX.cjs +0 -149
@@ -1,28 +1,28 @@
1
- import '../assets/index.css';var xt = Object.defineProperty;
2
- var Ot = (s, e, t) => e in s ? xt(s, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : s[e] = t;
3
- var d = (s, e, t) => Ot(s, typeof e != "symbol" ? e + "" : e, t);
4
- import { inject as st, ref as y, onMounted as ce, onUnmounted as nt, computed as f, toValue as le, nextTick as Ne, getCurrentInstance as Dt, watch as Z, provide as Mt, useId as Pt, onBeforeUnmount as ot, createVNode as J, render as Te, defineComponent as ve, defineAsyncComponent as $, openBlock as L, createElementBlock as U, withModifiers as K, withKeys as $t, withDirectives as it, unref as A, vShow as rt, createCommentVNode as C, createElementVNode as H, normalizeClass as ue, createBlock as V, Teleport as Ht, Transition as at, withCtx as j, mergeProps as ee, renderSlot as q, useAttrs as Vt, createTextVNode as Q, toDisplayString as Y, Fragment as Re, renderList as Bt, resolveDynamicComponent as Ft, normalizeStyle as Nt } from "vue";
5
- function Se(s, e) {
6
- const t = st(s, e);
1
+ import '../assets/index.css';var Pt = Object.defineProperty;
2
+ var Mt = (s, e, t) => e in s ? Pt(s, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : s[e] = t;
3
+ var d = (s, e, t) => Mt(s, typeof e != "symbol" ? e + "" : e, t);
4
+ import { inject as ot, ref as y, onMounted as ue, onUnmounted as it, computed as f, toValue as ae, nextTick as Ue, getCurrentInstance as $t, watch as X, provide as Ht, useId as Vt, onBeforeUnmount as rt, createVNode as J, render as Ce, defineComponent as ge, defineAsyncComponent as V, reactive as Ft, openBlock as C, createElementBlock as _, withModifiers as Y, withKeys as Bt, unref as S, createCommentVNode as I, createElementVNode as F, normalizeClass as le, withDirectives as at, vShow as lt, createBlock as B, Teleport as Nt, Transition as ut, withCtx as U, mergeProps as ee, renderSlot as q, useAttrs as jt, createTextVNode as Q, toDisplayString as Z, Fragment as Ye, renderList as Ut, resolveDynamicComponent as _t, normalizeStyle as qt } from "vue";
5
+ function Oe(s, e) {
6
+ const t = ot(s, e);
7
7
  if (!t)
8
8
  throw new TypeError(`[maz-ui](injectStrict) Could not resolve ${s}`);
9
9
  return t;
10
10
  }
11
- function Vn() {
12
- return Se("aos");
11
+ function Nn() {
12
+ return Oe("aos");
13
13
  }
14
- function jt(s) {
14
+ function Wt(s) {
15
15
  const e = {};
16
16
  for (const [t, n] of Object.entries(s))
17
17
  e[t] = Number.parseInt(n, 10);
18
18
  return e;
19
19
  }
20
- function F() {
20
+ function N() {
21
21
  return typeof document < "u";
22
22
  }
23
- function Ut(s = {}) {
23
+ function Rt(s = {}) {
24
24
  const {
25
- internalWindow: e = F() ? window : void 0,
25
+ internalWindow: e = N() ? window : void 0,
26
26
  initialWidth: t = Number.POSITIVE_INFINITY,
27
27
  initialHeight: n = Number.POSITIVE_INFINITY,
28
28
  includeScrollbar: o = !0
@@ -30,13 +30,13 @@ function Ut(s = {}) {
30
30
  function a() {
31
31
  e && (o ? (i.value = e.innerWidth, r.value = e.innerHeight) : (i.value = e.document.documentElement.clientWidth, r.value = e.document.documentElement.clientHeight));
32
32
  }
33
- return a(), ce(() => {
33
+ return a(), ue(() => {
34
34
  e && window.addEventListener("resize", a, { passive: !0 });
35
- }), nt(() => {
35
+ }), it(() => {
36
36
  e && window.removeEventListener("resize", a);
37
37
  }), { width: i, height: r };
38
38
  }
39
- function Bn({
39
+ function jn({
40
40
  initialWidth: s = 0,
41
41
  initialHeight: e,
42
42
  includeScrollbar: t,
@@ -46,14 +46,14 @@ function Bn({
46
46
  mediumBreakPoint: r = "md",
47
47
  largeBreakPoint: a = "lg"
48
48
  }) {
49
- const { width: u } = Ut({
49
+ const { width: u } = Rt({
50
50
  initialWidth: s,
51
51
  // (SSR) mobile first
52
52
  initialHeight: e,
53
53
  includeScrollbar: t,
54
54
  internalWindow: n,
55
55
  listenOrientation: o
56
- }), l = jt(i), h = f(() => u.value >= l[a]), p = f(
56
+ }), l = Wt(i), h = f(() => u.value >= l[a]), g = f(
57
57
  () => u.value >= l[r] && u.value < l[a]
58
58
  ), E = f(() => u.value >= 0 && u.value < l[r]);
59
59
  return {
@@ -61,14 +61,14 @@ function Bn({
61
61
  numericBreakpoints: l,
62
62
  isSmallScreen: E,
63
63
  isLargeScreen: h,
64
- isMediumScreen: p,
64
+ isMediumScreen: g,
65
65
  breakpoints: i
66
66
  };
67
67
  }
68
- function Fn() {
69
- return Se("dialog");
68
+ function Un() {
69
+ return Oe("dialog");
70
70
  }
71
- function _t(s, e, t) {
71
+ function ct(s, e, t) {
72
72
  const n = {
73
73
  maxAttempts: 20,
74
74
  interval: 100,
@@ -77,38 +77,38 @@ function _t(s, e, t) {
77
77
  let o = 0;
78
78
  function i() {
79
79
  const r = s();
80
- r != null ? e(r) : o < n.maxAttempts ? (o++, setTimeout(i, n.interval)) : console.warn(n.errorMessage || `[maz-ui](checkAvailability) Nothing found after ${n.maxAttempts} attempts for ref ${r}`);
80
+ r != null ? n.expectedValue !== void 0 && r !== n.expectedValue ? o < n.maxAttempts ? (o++, setTimeout(i, n.interval)) : console.warn(n.errorMessage || `[maz-ui](checkAvailability) Nothing found after ${n.maxAttempts} attempts for ref ${r}`) : e(r) : o < n.maxAttempts ? (o++, setTimeout(i, n.interval)) : console.warn(n.errorMessage || `[maz-ui](checkAvailability) Nothing found or expected value after ${n.maxAttempts} attempts for ref ${r}`);
81
81
  }
82
82
  i();
83
83
  }
84
- function lt(s) {
85
- const e = le(s);
84
+ function dt(s) {
85
+ const e = ae(s);
86
86
  return Array.isArray(e) ? Object.freeze([...e]) : typeof e == "object" && e !== null ? Object.freeze({ ...e }) : e;
87
87
  }
88
- function Ke(s) {
88
+ function Ze(s) {
89
89
  return s == null || typeof s == "string" || typeof s == "number" || typeof s == "boolean" || typeof s == "symbol" || typeof s == "bigint";
90
90
  }
91
- function qt(s, e) {
91
+ function Kt(s, e) {
92
92
  if (s.length !== e.length)
93
93
  return !1;
94
94
  for (const [t, n] of s.entries())
95
- if (!pe(n, e[t]))
95
+ if (!ye(n, e[t]))
96
96
  return !1;
97
97
  return !0;
98
98
  }
99
- function Wt(s, e) {
99
+ function Yt(s, e) {
100
100
  const t = Object.keys(s), n = Object.keys(e);
101
101
  if (t.length !== n.length)
102
102
  return !1;
103
103
  for (const o of t)
104
- if (!n.includes(o) || !pe(s[o], e[o]))
104
+ if (!n.includes(o) || !ye(s[o], e[o]))
105
105
  return !1;
106
106
  return !0;
107
107
  }
108
- function pe(s, e) {
109
- return Ke(s) || Ke(e) ? s === e : s instanceof Date && e instanceof Date ? s.getTime() === e.getTime() : typeof s != typeof e || Array.isArray(s) !== Array.isArray(e) ? !1 : Array.isArray(s) && Array.isArray(e) ? qt(s, e) : typeof s == "object" && typeof e == "object" ? Wt(s, e) : !1;
108
+ function ye(s, e) {
109
+ return Ze(s) || Ze(e) ? s === e : s instanceof Date && e instanceof Date ? s.getTime() === e.getTime() : typeof s != typeof e || Array.isArray(s) !== Array.isArray(e) ? !1 : Array.isArray(s) && Array.isArray(e) ? Kt(s, e) : typeof s == "object" && typeof e == "object" ? Yt(s, e) : !1;
110
110
  }
111
- function Rt(s, e, t) {
111
+ function Zt(s, e, t) {
112
112
  const n = {};
113
113
  return async function(...o) {
114
114
  n[s] || (n[s] = { timer: null, promise: null });
@@ -126,7 +126,7 @@ function Rt(s, e, t) {
126
126
  }), i.promise;
127
127
  };
128
128
  }
129
- function Kt(s, e, t) {
129
+ function Xt(s, e, t) {
130
130
  const n = {};
131
131
  return async (...o) => {
132
132
  const i = Date.now();
@@ -148,14 +148,14 @@ const te = {
148
148
  debounceTime: 300,
149
149
  throttleTime: 1e3
150
150
  };
151
- function ut(s, e) {
151
+ function mt(s, e) {
152
152
  return Object.keys(e).includes(s);
153
153
  }
154
- function Ye(s = te.scrollToErrorSelector) {
154
+ function Xe(s = te.scrollToErrorSelector) {
155
155
  const e = document.querySelector(s);
156
156
  e && e.scrollIntoView({ behavior: "smooth", block: "center" });
157
157
  }
158
- function Yt(s, e) {
158
+ function Gt(s, e) {
159
159
  const t = {};
160
160
  for (const [n, o] of Object.entries(s)) {
161
161
  const i = o;
@@ -163,10 +163,10 @@ function Yt(s, e) {
163
163
  }
164
164
  return t;
165
165
  }
166
- function je(s) {
166
+ function _e(s) {
167
167
  return s == null || s === "";
168
168
  }
169
- function Zt({
169
+ function Qt({
170
170
  name: s,
171
171
  hasValidation: e,
172
172
  debouncedFields: t,
@@ -175,25 +175,25 @@ function Zt({
175
175
  if (e) {
176
176
  if (t != null && t[s] && (n != null && n[s]))
177
177
  throw new Error(`The field "${s}" cannot be both debounced and throttled`);
178
- return t != null && t[s] ? Rt(
178
+ return t != null && t[s] ? Zt(
179
179
  s,
180
- he,
180
+ pe,
181
181
  typeof t[s] == "number" ? t[s] : te.debounceTime
182
- ) : n != null && n[s] ? Kt(
182
+ ) : n != null && n[s] ? Xt(
183
183
  s,
184
- he,
184
+ pe,
185
185
  typeof n[s] == "number" ? n[s] : te.throttleTime
186
- ) : he;
186
+ ) : pe;
187
187
  }
188
188
  }
189
- function ct({
189
+ function ft({
190
190
  name: s,
191
191
  schema: e,
192
192
  initialValue: t,
193
193
  fieldState: n,
194
194
  options: o
195
195
  }) {
196
- const i = e ? ut(s, e) : !1, r = Zt({
196
+ const i = e ? mt(s, e) : !1, r = Qt({
197
197
  name: s,
198
198
  hasValidation: i,
199
199
  debouncedFields: o == null ? void 0 : o.debouncedFields,
@@ -207,12 +207,12 @@ function ct({
207
207
  valid: !i,
208
208
  validating: !1,
209
209
  validated: !1,
210
- initialValue: lt(t),
210
+ initialValue: dt(t),
211
211
  validateFunction: r,
212
212
  mode: i ? (o == null ? void 0 : o.mode) ?? (n == null ? void 0 : n.mode) ?? te.mode : void 0
213
213
  };
214
214
  }
215
- function Xt({
215
+ function Jt({
216
216
  schema: s,
217
217
  payload: e,
218
218
  options: t
@@ -220,7 +220,7 @@ function Xt({
220
220
  const n = {};
221
221
  for (const o in s) {
222
222
  const i = o;
223
- n[i] = ct({
223
+ n[i] = ft({
224
224
  name: i,
225
225
  schema: s,
226
226
  options: t,
@@ -230,7 +230,7 @@ function Xt({
230
230
  }
231
231
  return n;
232
232
  }
233
- function Gt({
233
+ function es({
234
234
  fieldsStates: s,
235
235
  payload: e,
236
236
  schema: t,
@@ -239,7 +239,7 @@ function Gt({
239
239
  }) {
240
240
  for (const i in t) {
241
241
  const r = i;
242
- s[r] = dt({
242
+ s[r] = ht({
243
243
  name: r,
244
244
  fieldState: s[r],
245
245
  payload: e,
@@ -249,7 +249,7 @@ function Gt({
249
249
  });
250
250
  }
251
251
  }
252
- function dt({
252
+ function ht({
253
253
  name: s,
254
254
  fieldState: e,
255
255
  payload: t,
@@ -257,7 +257,7 @@ function dt({
257
257
  options: o,
258
258
  updateMode: i = !0
259
259
  }) {
260
- const { initialValue: r, mode: a, ...u } = ct({
260
+ const { initialValue: r, mode: a, ...u } = ft({
261
261
  name: s,
262
262
  schema: n,
263
263
  initialValue: o.defaultValue ?? t[s],
@@ -271,27 +271,27 @@ function dt({
271
271
  ...e != null && e.mode && l !== e.mode ? u : {}
272
272
  };
273
273
  }
274
- function Qt(s) {
274
+ function ts(s) {
275
275
  const e = {};
276
276
  for (const [t, { errors: n }] of Object.entries(s))
277
277
  e[t] = n;
278
278
  return e;
279
279
  }
280
- function Jt(s) {
280
+ function ss(s) {
281
281
  return s instanceof HTMLInputElement || s instanceof HTMLSelectElement || s instanceof HTMLTextAreaElement ? [s] : s.querySelectorAll(
282
282
  "input, select, textarea"
283
283
  );
284
284
  }
285
- function es({
285
+ function ns({
286
286
  interactiveElements: s,
287
287
  onBlurHandler: e,
288
288
  mode: t
289
289
  }) {
290
290
  s.forEach((n) => {
291
- ge(["eager", "blur", "progressive"], t) && n.addEventListener("blur", e);
291
+ be(["eager", "blur", "progressive"], t) && n.addEventListener("blur", e);
292
292
  });
293
293
  }
294
- function ts({
294
+ function os({
295
295
  interactiveElements: s,
296
296
  onBlurHandler: e
297
297
  }) {
@@ -299,14 +299,14 @@ function ts({
299
299
  t.removeEventListener("blur", e);
300
300
  });
301
301
  }
302
- async function ss(s, e, t) {
303
- const n = await ls(e), i = await (await ht("safeParseAsync"))(n.entries[s], t ?? "");
302
+ async function is(s, e, t) {
303
+ const n = await ds(e), i = await (await gt("safeParseAsync"))(n.entries[s], t ?? "");
304
304
  return {
305
305
  result: i,
306
306
  isValid: i.success
307
307
  };
308
308
  }
309
- async function he({
309
+ async function pe({
310
310
  name: s,
311
311
  fieldState: e,
312
312
  schema: t,
@@ -314,14 +314,14 @@ async function he({
314
314
  setError: o = !0,
315
315
  setErrorIfInvalidAndNotEmpty: i = !1
316
316
  }) {
317
- if (await Ne(), e.validating = !0, !t[s]) {
317
+ if (await Ue(), e.validating = !0, !t[s]) {
318
318
  e.valid = !0, e.validating = !1, e.validated = !0, e.errors = [], e.error = !1;
319
319
  return;
320
320
  }
321
- const { result: r, isValid: a } = await ss(s, t, n[s]);
322
- e.valid = a, (o || i && !a && !je(n[s])) && (e.error = !a), e.errors = r.issues ?? [], e.validating = !1, e.validated = !0;
321
+ const { result: r, isValid: a } = await is(s, t, n[s]);
322
+ e.valid = a, (o || i && !a && !_e(n[s])) && (e.error = !a), e.errors = r.issues ?? [], e.validating = !1, e.validated = !0;
323
323
  }
324
- function mt({
324
+ function vt({
325
325
  name: s,
326
326
  fieldState: e,
327
327
  payload: t,
@@ -337,7 +337,7 @@ function mt({
337
337
  };
338
338
  return (i = e.validateFunction) == null ? void 0 : i.call(e, o);
339
339
  }
340
- function ns({
340
+ function rs({
341
341
  fieldsStates: s,
342
342
  payload: e,
343
343
  showErrors: t = !0,
@@ -345,7 +345,7 @@ function ns({
345
345
  }) {
346
346
  return Promise.all(
347
347
  Object.keys(s).map(
348
- (o) => he({
348
+ (o) => pe({
349
349
  name: o,
350
350
  setError: t,
351
351
  fieldState: s[o],
@@ -356,15 +356,15 @@ function ns({
356
356
  )
357
357
  );
358
358
  }
359
- function ft({
359
+ function pt({
360
360
  eventName: s,
361
361
  fieldState: e,
362
362
  isSubmitted: t
363
363
  }) {
364
364
  const { dirty: n, blurred: o, mode: i, valid: r } = e;
365
- return s === "blur" && (ge(["lazy", "aggressive"], i) || r) || s === "input" && i === "blur" || !i ? !1 : t || i === "eager" && o || i === "blur" && o || i === "aggressive" && n || i === "lazy" && n || i === "progressive";
365
+ return s === "blur" && (be(["lazy", "aggressive"], i) || r) || s === "input" && i === "blur" || !i ? !1 : t || i === "eager" && o || i === "blur" && o || i === "aggressive" && n || i === "lazy" && n || i === "progressive";
366
366
  }
367
- function os({
367
+ function as({
368
368
  name: s,
369
369
  force: e = !1,
370
370
  payload: t,
@@ -372,16 +372,16 @@ function os({
372
372
  schema: o,
373
373
  isSubmitted: i
374
374
  }) {
375
- const r = t[s], a = !je(r) && !pe(r, n.initialValue);
376
- if (n.dirty = a, n.blurred = n.blurred || (n.mode === "eager" ? a : !0), !!(e || ft({ eventName: "blur", fieldState: n, isSubmitted: i })))
377
- return mt({
375
+ const r = t[s], a = !_e(r) && !ye(r, n.initialValue);
376
+ if (n.dirty = a, n.blurred = n.blurred || (n.mode === "eager" ? a : !0), !!(e || pt({ eventName: "blur", fieldState: n, isSubmitted: i })))
377
+ return vt({
378
378
  name: s,
379
379
  fieldState: n,
380
380
  schema: o,
381
381
  payload: t
382
382
  });
383
383
  }
384
- function is({
384
+ function ls({
385
385
  name: s,
386
386
  payload: e,
387
387
  fieldState: t,
@@ -391,52 +391,52 @@ function is({
391
391
  }) {
392
392
  const r = e[s];
393
393
  t.validated = !1;
394
- const a = !je(r) && !pe(r, t.initialValue);
395
- if (t.dirty = a, !!(i || ft({ eventName: "input", fieldState: t, isSubmitted: o })))
396
- return mt({
394
+ const a = !_e(r) && !ye(r, t.initialValue);
395
+ if (t.dirty = a, !!(i || pt({ eventName: "input", fieldState: t, isSubmitted: o })))
396
+ return vt({
397
397
  name: s,
398
398
  fieldState: t,
399
399
  schema: n,
400
400
  payload: e
401
401
  });
402
402
  }
403
- function Ue(s) {
404
- const e = Dt();
403
+ function qe(s) {
404
+ const e = $t();
405
405
  if (!e)
406
406
  throw new Error(`${s} must be called within setup()`);
407
407
  return e;
408
408
  }
409
- function rs(s, e) {
409
+ function us(s, e) {
410
410
  var o;
411
- const n = ((o = Ue(e).formContexts) == null ? void 0 : o.get(s)) ?? st(s);
411
+ const n = ((o = qe(e).formContexts) == null ? void 0 : o.get(s)) ?? ot(s);
412
412
  if (!n)
413
413
  throw new Error("useFormField must be used within a form (useFormValidator)");
414
414
  return n;
415
415
  }
416
- function as({
416
+ function cs({
417
417
  ref: s,
418
418
  fieldState: e,
419
419
  onBlurHandler: t
420
420
  }) {
421
- if (!(s || ge(["aggressive", "lazy"], e.mode)))
421
+ if (!(s || be(["aggressive", "lazy"], e.mode)))
422
422
  return {
423
423
  onBlur: t
424
424
  };
425
425
  }
426
- const Pe = {};
427
- async function ht(s) {
428
- if (Pe[s])
429
- return Pe[s];
426
+ const He = {};
427
+ async function gt(s) {
428
+ if (He[s])
429
+ return He[s];
430
430
  const e = await import("./index-BgyjI1q8.mjs");
431
- return Pe[s] = e[s], e[s];
431
+ return He[s] = e[s], e[s];
432
432
  }
433
- async function ls(s) {
434
- return (await ht("objectAsync"))(s);
433
+ async function ds(s) {
434
+ return (await gt("objectAsync"))(s);
435
435
  }
436
- function ge(s, e) {
436
+ function be(s, e) {
437
437
  return e ? s.includes(e) : !1;
438
438
  }
439
- function Nn(s, e) {
439
+ function _n(s, e) {
440
440
  const t = {
441
441
  formIdentifier: "main-form-validator",
442
442
  ...e
@@ -447,20 +447,20 @@ function Nn(s, e) {
447
447
  internalSchema: r,
448
448
  errorMessages: a,
449
449
  isSubmitted: u
450
- } = rs(t.formIdentifier, "useFormField"), l = ut(s, r.value) ? (e == null ? void 0 : e.mode) ?? i.mode : void 0;
450
+ } = us(t.formIdentifier, "useFormField"), l = mt(s, r.value) ? (e == null ? void 0 : e.mode) ?? i.mode : void 0;
451
451
  t.mode = l;
452
452
  const h = f(() => n.value[s]);
453
- if (n.value[s] = dt({
453
+ if (n.value[s] = ht({
454
454
  name: s,
455
455
  fieldState: h.value,
456
456
  payload: o.value,
457
457
  schema: r.value,
458
458
  options: { ...i, ...t }
459
- }), t.defaultValue !== void 0 && !pe(o.value[s], t.defaultValue)) {
459
+ }), t.defaultValue !== void 0 && !ye(o.value[s], t.defaultValue)) {
460
460
  const T = t.defaultValue;
461
- o.value[s] = T, n.value[s].initialValue = lt(T);
461
+ o.value[s] = T, n.value[s].initialValue = dt(T);
462
462
  }
463
- l && he({
463
+ l && pe({
464
464
  name: s,
465
465
  fieldState: h.value,
466
466
  payload: o.value,
@@ -468,8 +468,8 @@ function Nn(s, e) {
468
468
  setError: l === "aggressive",
469
469
  setErrorIfInvalidAndNotEmpty: l === "lazy"
470
470
  });
471
- function p() {
472
- os({
471
+ function g() {
472
+ as({
473
473
  name: s,
474
474
  fieldState: h.value,
475
475
  payload: o.value,
@@ -478,33 +478,33 @@ function Nn(s, e) {
478
478
  });
479
479
  }
480
480
  const E = f(
481
- () => as({
481
+ () => cs({
482
482
  ref: t.ref,
483
- onBlurHandler: p,
483
+ onBlurHandler: g,
484
484
  fieldState: h.value
485
485
  })
486
486
  );
487
- if (t.ref && ge(["eager", "blur", "progressive"], l)) {
487
+ if (t.ref && be(["eager", "blur", "progressive"], l)) {
488
488
  let T = [];
489
- const P = (x) => {
490
- T = Jt(x), es({
489
+ const $ = (k) => {
490
+ T = ss(k), ns({
491
491
  interactiveElements: T,
492
- onBlurHandler: p,
492
+ onBlurHandler: g,
493
493
  mode: l
494
494
  });
495
495
  };
496
- ce(() => {
497
- const x = Ue(`useFormField of ${s}`);
498
- _t(() => x.refs[t.ref], (c) => {
499
- const g = c instanceof HTMLElement ? c : c == null ? void 0 : c.$el;
500
- g && P(g);
496
+ ue(() => {
497
+ const k = qe(`useFormField of ${s}`);
498
+ ct(() => k.refs[t.ref], (c) => {
499
+ const b = c instanceof HTMLElement ? c : c == null ? void 0 : c.$el;
500
+ b && $(b);
501
501
  }, {
502
502
  errorMessage: `[maz-ui](useFormField) No element found for ref ${t.ref} for field ${s}`
503
503
  });
504
- }), nt(() => {
505
- ts({
504
+ }), it(() => {
505
+ os({
506
506
  interactiveElements: T,
507
- onBlurHandler: p
507
+ onBlurHandler: g
508
508
  });
509
509
  });
510
510
  }
@@ -525,8 +525,8 @@ function Nn(s, e) {
525
525
  validationEvents: E
526
526
  };
527
527
  }
528
- function jn({ schema: s, defaultValues: e, model: t, options: n }) {
529
- const o = Ue("useFormValidator"), i = {
528
+ function qn({ schema: s, defaultValues: e, model: t, options: n }) {
529
+ const o = qe("useFormValidator"), i = {
530
530
  mode: te.mode,
531
531
  scrollToError: te.scrollToErrorSelector,
532
532
  debouncedFields: null,
@@ -534,29 +534,29 @@ function jn({ schema: s, defaultValues: e, model: t, options: n }) {
534
534
  identifier: "main-form-validator",
535
535
  ...n
536
536
  }, r = y(e), a = y({ ...r.value, ...t == null ? void 0 : t.value }), u = y(s), l = y(
537
- Xt({
537
+ Jt({
538
538
  schema: u.value,
539
539
  payload: a.value,
540
540
  options: i
541
541
  })
542
- ), h = y(!1), p = y(!1), E = f(() => Object.values(l.value).every(({ valid: z }) => z)), T = f(() => Object.values(l.value).some(({ dirty: z }) => z)), P = f(() => Qt(l.value)), x = f(() => Yt(P.value, l.value));
543
- t && Z(
542
+ ), h = y(!1), g = y(!1), E = f(() => Object.values(l.value).every(({ valid: L }) => L)), T = f(() => Object.values(l.value).some(({ dirty: L }) => L)), $ = f(() => ts(l.value)), k = f(() => Gt($.value, l.value));
543
+ t && X(
544
544
  a,
545
- (z) => {
546
- t.value = { ...r.value, ...z };
545
+ (L) => {
546
+ t.value = { ...r.value, ...L };
547
547
  },
548
548
  { deep: !0 }
549
- ), Z(
549
+ ), X(
550
550
  r,
551
- (z) => {
552
- a.value = { ...z, ...a.value };
551
+ (L) => {
552
+ a.value = { ...L, ...a.value };
553
553
  },
554
554
  { deep: !0 }
555
- ), Z(
555
+ ), X(
556
556
  u,
557
- (z) => {
558
- Gt({
559
- schema: z,
557
+ (L) => {
558
+ es({
559
+ schema: L,
560
560
  fieldsStates: l.value,
561
561
  payload: a.value,
562
562
  options: i
@@ -564,74 +564,74 @@ function jn({ schema: s, defaultValues: e, model: t, options: n }) {
564
564
  },
565
565
  { deep: !0 }
566
566
  ), c();
567
- function c(z = i.mode === "aggressive") {
568
- return ns({
567
+ function c(L = i.mode === "aggressive") {
568
+ return rs({
569
569
  fieldsStates: l.value,
570
570
  payload: a.value,
571
571
  schema: u.value,
572
- showErrors: z
572
+ showErrors: L
573
573
  });
574
574
  }
575
- const g = [];
576
- async function k(z) {
577
- await Ne();
578
- const B = Z(
579
- () => a.value[z],
575
+ const b = [];
576
+ async function D(L) {
577
+ await Ue();
578
+ const P = X(
579
+ () => a.value[L],
580
580
  () => {
581
- const _ = l.value[z];
582
- is({
583
- name: z,
584
- fieldState: _,
581
+ const j = l.value[L];
582
+ ls({
583
+ name: L,
584
+ fieldState: j,
585
585
  payload: a.value,
586
586
  schema: u.value,
587
- isSubmitted: p.value,
588
- forceValidation: ge(["aggressive", "lazy", "progressive"], _.mode)
587
+ isSubmitted: g.value,
588
+ forceValidation: be(["aggressive", "lazy", "progressive"], j.mode)
589
589
  });
590
590
  },
591
- { deep: typeof u.value[z] == "object" }
591
+ { deep: typeof u.value[L] == "object" }
592
592
  );
593
- g.push(B);
593
+ b.push(P);
594
594
  }
595
- function b() {
596
- for (const z of g)
597
- z();
598
- for (const z of Object.keys(u.value))
599
- k(z);
595
+ function v() {
596
+ for (const L of b)
597
+ L();
598
+ for (const L of Object.keys(u.value))
599
+ D(L);
600
600
  }
601
- function D(z, B) {
602
- return async (_) => {
603
- if (_ == null || _.preventDefault(), h.value)
601
+ function x(L, P) {
602
+ return async (j) => {
603
+ if (j == null || j.preventDefault(), h.value)
604
604
  return;
605
- p.value = !0, h.value = !0, await c(!0);
606
- const X = typeof B == "string" ? B : i.scrollToError;
605
+ g.value = !0, h.value = !0, await c(!0);
606
+ const se = typeof P == "string" ? P : i.scrollToError;
607
607
  let G;
608
- return E.value ? G = await z(a.value) : typeof X != "boolean" && Ye(X), h.value = !1, G;
608
+ return E.value ? G = await L(a.value) : typeof se != "boolean" && Xe(se), h.value = !1, G;
609
609
  };
610
610
  }
611
- const O = {
611
+ const H = {
612
612
  fieldsStates: l,
613
613
  payload: a,
614
614
  options: i,
615
615
  internalSchema: u,
616
- errorMessages: x,
617
- isSubmitted: p
616
+ errorMessages: k,
617
+ isSubmitted: g
618
618
  };
619
- return o.formContexts ?? (o.formContexts = /* @__PURE__ */ new Map()), o.formContexts.set(i.identifier, O), Mt(i.identifier, O), b(), {
619
+ return o.formContexts ?? (o.formContexts = /* @__PURE__ */ new Map()), o.formContexts.set(i.identifier, H), Ht(i.identifier, H), v(), {
620
620
  identifier: i.identifier,
621
621
  isDirty: T,
622
622
  isSubmitting: h,
623
- isSubmitted: p,
623
+ isSubmitted: g,
624
624
  isValid: E,
625
- errors: P,
625
+ errors: $,
626
626
  model: a,
627
627
  fieldsStates: l,
628
628
  validateForm: c,
629
- scrollToError: Ye,
630
- handleSubmit: D,
631
- errorMessages: x
629
+ scrollToError: Xe,
630
+ handleSubmit: x,
631
+ errorMessages: k
632
632
  };
633
633
  }
634
- class us {
634
+ class ms {
635
635
  constructor(e, t) {
636
636
  d(this, "defaultOptions", {
637
637
  element: void 0,
@@ -679,13 +679,13 @@ class us {
679
679
  this.callback = e, this.options = {
680
680
  ...this.defaultOptions,
681
681
  ...t
682
- }, F() && this.start();
682
+ }, N() && this.start();
683
683
  }
684
684
  get element() {
685
685
  return this.options.element ?? document.body;
686
686
  }
687
687
  start() {
688
- if (!F()) {
688
+ if (!N()) {
689
689
  console.warn("[IdleTimeout](start) you should run this method on client side");
690
690
  return;
691
691
  }
@@ -704,7 +704,7 @@ class us {
704
704
  this.isDestroy = !1, this.isIdle = !1, this.remainingTime = 0, this.resetTimeout(), this.callback({ isIdle: this.isIdle, instance: this });
705
705
  }
706
706
  destroy() {
707
- if (!F()) {
707
+ if (!N()) {
708
708
  console.warn("[IdleTimeout](destroy) you should run this method on client side");
709
709
  return;
710
710
  }
@@ -738,20 +738,20 @@ class us {
738
738
  e ? this.handleTimeout() : this.reset(), this.callback({ isIdle: this.isIdle, instance: this });
739
739
  }
740
740
  }
741
- function Un({
741
+ function Wn({
742
742
  callback: s,
743
743
  options: e
744
744
  }) {
745
- return new us(s, e);
745
+ return new ms(s, e);
746
746
  }
747
- function _n({
747
+ function Rn({
748
748
  componentName: s,
749
749
  providedId: e
750
750
  }) {
751
- const t = Pt();
751
+ const t = Vt();
752
752
  return f(() => e ?? `${s}-${t}`);
753
753
  }
754
- const cs = [
754
+ const fs = [
755
755
  "af-ZA",
756
756
  "sq-AL",
757
757
  "ar-DZ",
@@ -889,9 +889,9 @@ const cs = [
889
889
  "Lt-uz-UZ",
890
890
  "vi-VN"
891
891
  ];
892
- function ds(s, e) {
892
+ function hs(s, e) {
893
893
  return f(() => {
894
- const t = le(e), n = le(s);
894
+ const t = ae(e), n = ae(s);
895
895
  try {
896
896
  return !t || !n ? n : new Intl.DisplayNames([t], { type: "language" }).of(n) || n;
897
897
  } catch {
@@ -899,9 +899,9 @@ function ds(s, e) {
899
899
  }
900
900
  });
901
901
  }
902
- function ms(s) {
902
+ function vs(s) {
903
903
  return f(() => {
904
- const e = le(s);
904
+ const e = ae(s);
905
905
  if (!e)
906
906
  return [];
907
907
  const t = 65, n = 90, o = new Intl.DisplayNames([e], { type: "language" }), i = [];
@@ -916,15 +916,15 @@ function ms(s) {
916
916
  return i;
917
917
  });
918
918
  }
919
- function fs(s) {
919
+ function ps(s) {
920
920
  return f(() => {
921
- const e = le(s);
921
+ const e = ae(s);
922
922
  if (!e)
923
923
  return [];
924
924
  const t = new Intl.DisplayNames([e], {
925
925
  type: "language"
926
926
  });
927
- return cs.map((n) => {
927
+ return fs.map((n) => {
928
928
  try {
929
929
  const o = t.of(n);
930
930
  return !o || n.toLocaleLowerCase() === o.toLocaleLowerCase() ? void 0 : {
@@ -937,22 +937,22 @@ function fs(s) {
937
937
  }).filter(Boolean);
938
938
  });
939
939
  }
940
- function qn(s) {
940
+ function Kn(s) {
941
941
  return {
942
- getLanguageDisplayName: ({ isoCode: e, locale: t }) => ds(e, t || s),
943
- getAllPossibleLanguages: (e) => ms(e || s),
944
- getLanguageDisplayNamesForIsoCodes: (e) => fs(e || s)
942
+ getLanguageDisplayName: ({ isoCode: e, locale: t }) => hs(e, t || s),
943
+ getAllPossibleLanguages: (e) => vs(e || s),
944
+ getLanguageDisplayNamesForIsoCodes: (e) => ps(e || s)
945
945
  };
946
946
  }
947
- function vt(s) {
947
+ function yt(s) {
948
948
  const e = s.join(", ").match(/\b\w+\b/g);
949
949
  return e ? e.length : 0;
950
950
  }
951
- function hs(s, e = 150) {
952
- const t = vt([s]);
951
+ function gs(s, e = 150) {
952
+ const t = yt([s]);
953
953
  return Math.ceil(t / e);
954
954
  }
955
- function Wn(s) {
955
+ function Yn(s) {
956
956
  const e = f(
957
957
  () => {
958
958
  var r;
@@ -971,7 +971,7 @@ function Wn(s) {
971
971
  return l.textContent;
972
972
  }
973
973
  return typeof s.content == "string" ? s.content : (u = s.content) == null ? void 0 : u.value;
974
- }), o = f(() => hs(n.value, e.value)), i = f(() => vt([n.value]));
974
+ }), o = f(() => gs(n.value, e.value)), i = f(() => yt([n.value]));
975
975
  return {
976
976
  content: n,
977
977
  wordCount: i,
@@ -979,7 +979,7 @@ function Wn(s) {
979
979
  duration: o
980
980
  };
981
981
  }
982
- const vs = {
982
+ const ys = {
983
983
  removeAccents: !0,
984
984
  caseSensitive: !1,
985
985
  replaceSpaces: !0,
@@ -989,8 +989,8 @@ const vs = {
989
989
  removeNumbers: !1,
990
990
  customNormalizationForms: ["NFC", "NFKD"]
991
991
  };
992
- function Ze(s, e) {
993
- const t = { ...vs, ...e }, n = {
992
+ function Ge(s, e) {
993
+ const t = { ...ys, ...e }, n = {
994
994
  À: "A",
995
995
  Á: "A",
996
996
  Â: "A",
@@ -1045,7 +1045,7 @@ function Ze(s, e) {
1045
1045
  o = o.normalize(i);
1046
1046
  return o;
1047
1047
  }
1048
- function ps(s, e) {
1048
+ function bs(s, e) {
1049
1049
  const t = s.length, n = e.length, o = [];
1050
1050
  for (let i = 0; i <= t; i++)
1051
1051
  o[i] = [i];
@@ -1062,34 +1062,34 @@ function ps(s, e) {
1062
1062
  }
1063
1063
  return o[t][n];
1064
1064
  }
1065
- function pt(s, e) {
1066
- const t = ps(s, e), n = Math.max(s.length, e.length);
1065
+ function bt(s, e) {
1066
+ const t = bs(s, e), n = Math.max(s.length, e.length);
1067
1067
  return 1 - t / n;
1068
1068
  }
1069
- function gs(s, e, t = 0.75) {
1070
- return pt(s, e) >= t;
1069
+ function ws(s, e, t = 0.75) {
1070
+ return bt(s, e) >= t;
1071
1071
  }
1072
- function Rn(s, e, t = 0.75) {
1072
+ function Zn(s, e, t = 0.75) {
1073
1073
  const n = f(
1074
- () => Ze(typeof s == "string" ? s : s.value)
1074
+ () => Ge(typeof s == "string" ? s : s.value)
1075
1075
  ), o = f(
1076
- () => Ze(typeof e == "string" ? e : e.value)
1077
- ), i = f(() => typeof t == "number" ? t : t.value), r = f(() => pt(n.value, o.value));
1076
+ () => Ge(typeof e == "string" ? e : e.value)
1077
+ ), i = f(() => typeof t == "number" ? t : t.value), r = f(() => bt(n.value, o.value));
1078
1078
  return {
1079
1079
  isMatching: f(
1080
- () => gs(n.value, o.value, i.value)
1080
+ () => ws(n.value, o.value, i.value)
1081
1081
  ),
1082
1082
  score: r
1083
1083
  };
1084
1084
  }
1085
- const ys = {
1085
+ const Es = {
1086
1086
  preventDefaultOnTouchMove: !1,
1087
1087
  preventDefaultOnMouseWheel: !1,
1088
1088
  threshold: 50,
1089
1089
  immediate: !1,
1090
1090
  triggerOnEnd: !1
1091
1091
  };
1092
- class bs {
1092
+ class Ts {
1093
1093
  constructor(e) {
1094
1094
  d(this, "element");
1095
1095
  d(this, "xStart");
@@ -1105,7 +1105,7 @@ class bs {
1105
1105
  d(this, "start");
1106
1106
  d(this, "stop");
1107
1107
  d(this, "options");
1108
- this.inputOption = e, this.options = { ...ys, ...e }, this.onToucheStartCallback = this.toucheStartHandler.bind(this), this.onToucheMoveCallback = this.handleTouchMove.bind(this), this.onToucheEndCallback = this.handleTouchEnd.bind(this), this.onMouseWheelCallback = this.handleMouseWheel.bind(this), this.start = this.startListening.bind(this), this.stop = this.stopListening.bind(this), this.options.element && this.setElement(this.options.element), this.options.immediate && this.start();
1108
+ this.inputOption = e, this.options = { ...Es, ...e }, this.onToucheStartCallback = this.toucheStartHandler.bind(this), this.onToucheMoveCallback = this.handleTouchMove.bind(this), this.onToucheEndCallback = this.handleTouchEnd.bind(this), this.onMouseWheelCallback = this.handleMouseWheel.bind(this), this.start = this.startListening.bind(this), this.stop = this.stopListening.bind(this), this.options.element && this.setElement(this.options.element), this.options.immediate && this.start();
1109
1109
  }
1110
1110
  startListening() {
1111
1111
  this.setElement(this.options.element), this.element.addEventListener("touchstart", this.onToucheStartCallback, { passive: !0 }), this.element.addEventListener("touchmove", this.onToucheMoveCallback, { passive: !0 }), this.options.triggerOnEnd && this.element.addEventListener("touchend", this.onToucheEndCallback, { passive: !0 }), this.options.preventDefaultOnMouseWheel && this.element.addEventListener("mousewheel", this.onMouseWheelCallback, { passive: !1 });
@@ -1161,8 +1161,8 @@ class bs {
1161
1161
  this.xStart = void 0, this.yStart = void 0, this.xEnd = void 0, this.yEnd = void 0, this.xDiff = void 0, this.yDiff = void 0, this.emitValuesChanged();
1162
1162
  }
1163
1163
  }
1164
- function Kn(s) {
1165
- const e = y(), t = y(), n = y(), o = y(), i = y(), r = y(), a = f(() => le(s.element)), u = new bs({
1164
+ function Xn(s) {
1165
+ const e = y(), t = y(), n = y(), o = y(), i = y(), r = y(), a = f(() => ae(s.element)), u = new Ts({
1166
1166
  ...s,
1167
1167
  element: a.value,
1168
1168
  onValuesChanged(l) {
@@ -1182,7 +1182,7 @@ function Kn(s) {
1182
1182
  stop: u.stop
1183
1183
  };
1184
1184
  }
1185
- const ws = {
1185
+ const Ls = {
1186
1186
  darkClass: "dark",
1187
1187
  lightClass: "light",
1188
1188
  storageThemeKey: "theme",
@@ -1190,11 +1190,11 @@ const ws = {
1190
1190
  storageThemeValueLight: "light",
1191
1191
  storageThemeValueSystem: "system",
1192
1192
  watchChanges: !0
1193
- }, ye = y("system"), R = y("system");
1194
- function Xe() {
1193
+ }, we = y("system"), K = y("system");
1194
+ function Qe() {
1195
1195
  return window.matchMedia("(prefers-color-scheme: dark)").matches;
1196
1196
  }
1197
- function be({
1197
+ function Ee({
1198
1198
  darkClass: s,
1199
1199
  lightClass: e,
1200
1200
  storageThemeKey: t,
@@ -1202,9 +1202,9 @@ function be({
1202
1202
  setLocalStorageValue: o = !0,
1203
1203
  setSelectedTheme: i = !0
1204
1204
  }) {
1205
- F() && (document.documentElement.classList.remove(e), document.documentElement.classList.add(s), ye.value = n, i && (R.value = n), o && (localStorage[t] = n));
1205
+ N() && (document.documentElement.classList.remove(e), document.documentElement.classList.add(s), we.value = n, i && (K.value = n), o && (localStorage[t] = n));
1206
1206
  }
1207
- function we({
1207
+ function Te({
1208
1208
  darkClass: s,
1209
1209
  lightClass: e,
1210
1210
  storageThemeKey: t,
@@ -1212,97 +1212,97 @@ function we({
1212
1212
  setLocalStorageValue: o = !0,
1213
1213
  setSelectedTheme: i = !0
1214
1214
  }) {
1215
- F() && (document.documentElement.classList.remove(s), document.documentElement.classList.add(e), ye.value = n, i && (R.value = n), o && (localStorage[t] = n));
1215
+ N() && (document.documentElement.classList.remove(s), document.documentElement.classList.add(e), we.value = n, i && (K.value = n), o && (localStorage[t] = n));
1216
1216
  }
1217
- function gt({
1217
+ function wt({
1218
1218
  setLocalStorageValue: s = !0,
1219
1219
  ...e
1220
1220
  }) {
1221
- if (F())
1222
- return document.documentElement.classList.remove(e.darkClass), document.documentElement.classList.remove(e.lightClass), ye.value = e.storageThemeValueSystem, R.value = e.storageThemeValueSystem, s && (localStorage[e.storageThemeKey] = e.storageThemeValueSystem), Ve(e);
1221
+ if (N())
1222
+ return document.documentElement.classList.remove(e.darkClass), document.documentElement.classList.remove(e.lightClass), we.value = e.storageThemeValueSystem, K.value = e.storageThemeValueSystem, s && (localStorage[e.storageThemeKey] = e.storageThemeValueSystem), Be(e);
1223
1223
  }
1224
- function yt(s) {
1224
+ function Et(s) {
1225
1225
  if (!s.defaultTheme)
1226
1226
  return console.error("[maz-ui](useThemeHandler) No default theme set");
1227
1227
  if (!["light", "dark"].includes(s.defaultTheme))
1228
1228
  return console.error('[maz-ui](useThemeHandler) Default theme must be "light" or "dark"');
1229
1229
  switch (s.defaultTheme) {
1230
1230
  case "dark":
1231
- return be({
1231
+ return Ee({
1232
1232
  ...s,
1233
1233
  setLocalStorageValue: !1,
1234
1234
  setSelectedTheme: !0
1235
1235
  });
1236
1236
  case "light":
1237
- return we({
1237
+ return Te({
1238
1238
  ...s,
1239
1239
  setLocalStorageValue: !1,
1240
1240
  setSelectedTheme: !0
1241
1241
  });
1242
1242
  }
1243
1243
  }
1244
- function Ve(s) {
1245
- return F() ? !localStorage[s.storageThemeKey] && s.defaultTheme ? yt(s) : localStorage[s.storageThemeKey] === s.storageThemeValueDark || !localStorage[s.storageThemeKey] && Xe() || localStorage[s.storageThemeKey] === s.storageThemeValueSystem && Xe() ? be({
1244
+ function Be(s) {
1245
+ return N() ? !localStorage[s.storageThemeKey] && s.defaultTheme ? Et(s) : localStorage[s.storageThemeKey] === s.storageThemeValueDark || !localStorage[s.storageThemeKey] && Qe() || localStorage[s.storageThemeKey] === s.storageThemeValueSystem && Qe() ? Ee({
1246
1246
  ...s,
1247
1247
  setLocalStorageValue: !1,
1248
1248
  setSelectedTheme: !1
1249
- }) : we({
1249
+ }) : Te({
1250
1250
  ...s,
1251
1251
  setLocalStorageValue: !1,
1252
1252
  setSelectedTheme: !1
1253
1253
  }) : void 0;
1254
1254
  }
1255
- function $e({
1255
+ function Ve({
1256
1256
  theme: s,
1257
1257
  ...e
1258
1258
  }) {
1259
- return s === "system" ? gt(e) : s === "dark" ? be(e) : we(e);
1259
+ return s === "system" ? wt(e) : s === "dark" ? Ee(e) : Te(e);
1260
1260
  }
1261
- function Es(s) {
1262
- return ye.value === s.storageThemeValueDark ? we(s) : be(s);
1261
+ function zs(s) {
1262
+ return we.value === s.storageThemeValueDark ? Te(s) : Ee(s);
1263
1263
  }
1264
- function Yn(s) {
1264
+ function Gn(s) {
1265
1265
  const e = {
1266
- ...ws,
1266
+ ...Ls,
1267
1267
  ...s
1268
1268
  };
1269
1269
  function t() {
1270
- Ve(e);
1270
+ Be(e);
1271
1271
  }
1272
- return ce(() => {
1273
- localStorage[e.storageThemeKey] && (R.value = localStorage[e.storageThemeKey]), e.watchChanges && window.matchMedia("(prefers-color-scheme: dark)").addEventListener("change", t);
1274
- }), ot(() => {
1272
+ return ue(() => {
1273
+ localStorage[e.storageThemeKey] && (K.value = localStorage[e.storageThemeKey]), e.watchChanges && window.matchMedia("(prefers-color-scheme: dark)").addEventListener("change", t);
1274
+ }), rt(() => {
1275
1275
  e.watchChanges && window.matchMedia("(prefers-color-scheme: dark)").removeEventListener("change", t);
1276
- }), Z(R, (n) => {
1276
+ }), X(K, (n) => {
1277
1277
  switch (localStorage[e.storageThemeKey] = n, n) {
1278
1278
  case e.storageThemeValueDark: {
1279
- be(e);
1279
+ Ee(e);
1280
1280
  break;
1281
1281
  }
1282
1282
  case e.storageThemeValueLight: {
1283
- we(e);
1283
+ Te(e);
1284
1284
  break;
1285
1285
  }
1286
1286
  case e.storageThemeValueSystem: {
1287
- gt(e);
1287
+ wt(e);
1288
1288
  break;
1289
1289
  }
1290
1290
  }
1291
1291
  }), {
1292
- autoSetTheme: () => Ve(e),
1293
- toggleTheme: () => Es(e),
1294
- setSystemTheme: () => $e({ ...e, theme: "system" }),
1295
- setDarkTheme: () => $e({ ...e, theme: "dark" }),
1296
- setLightTheme: () => $e({ ...e, theme: "light" }),
1297
- setDefaultTheme: () => yt(e),
1298
- hasDarkTheme: f(() => R.value === e.storageThemeValueDark),
1299
- hasLightTheme: f(() => R.value === e.storageThemeValueLight),
1300
- hasSystemTheme: f(() => R.value === e.storageThemeValueSystem),
1301
- theme: ye,
1302
- selectedTheme: R
1292
+ autoSetTheme: () => Be(e),
1293
+ toggleTheme: () => zs(e),
1294
+ setSystemTheme: () => Ve({ ...e, theme: "system" }),
1295
+ setDarkTheme: () => Ve({ ...e, theme: "dark" }),
1296
+ setLightTheme: () => Ve({ ...e, theme: "light" }),
1297
+ setDefaultTheme: () => Et(e),
1298
+ hasDarkTheme: f(() => K.value === e.storageThemeValueDark),
1299
+ hasLightTheme: f(() => K.value === e.storageThemeValueLight),
1300
+ hasSystemTheme: f(() => K.value === e.storageThemeValueSystem),
1301
+ theme: we,
1302
+ selectedTheme: K
1303
1303
  };
1304
1304
  }
1305
- function zs({ timeout: s = 1e3, callback: e, remainingTimeUpdate: t = 200, callbackOffsetTime: n = 0 }) {
1305
+ function Cs({ timeout: s = 1e3, callback: e, remainingTimeUpdate: t = 200, callbackOffsetTime: n = 0 }) {
1306
1306
  const o = y(s), i = y(s);
1307
1307
  let r;
1308
1308
  function a(E) {
@@ -1310,7 +1310,7 @@ function zs({ timeout: s = 1e3, callback: e, remainingTimeUpdate: t = 200, callb
1310
1310
  }
1311
1311
  function u() {
1312
1312
  r || (r = setInterval(() => {
1313
- i.value -= t, i.value <= 0 && (p(), setTimeout(() => e == null ? void 0 : e(), n));
1313
+ i.value -= t, i.value <= 0 && (g(), setTimeout(() => e == null ? void 0 : e(), n));
1314
1314
  }, t));
1315
1315
  }
1316
1316
  function l() {
@@ -1319,7 +1319,7 @@ function zs({ timeout: s = 1e3, callback: e, remainingTimeUpdate: t = 200, callb
1319
1319
  function h() {
1320
1320
  !r && i.value > 0 && u();
1321
1321
  }
1322
- function p() {
1322
+ function g() {
1323
1323
  setTimeout(() => i.value = o.value, n * 2), l();
1324
1324
  }
1325
1325
  return {
@@ -1327,13 +1327,13 @@ function zs({ timeout: s = 1e3, callback: e, remainingTimeUpdate: t = 200, callb
1327
1327
  start: a,
1328
1328
  pause: l,
1329
1329
  resume: h,
1330
- stop: p
1330
+ stop: g
1331
1331
  };
1332
1332
  }
1333
- function Zn() {
1334
- return Se("toast");
1333
+ function Qn() {
1334
+ return Oe("toast");
1335
1335
  }
1336
- class Ts {
1336
+ class Is {
1337
1337
  constructor(e, t) {
1338
1338
  d(this, "eventHandlerFunction");
1339
1339
  d(this, "event", "visibilitychange");
@@ -1348,10 +1348,10 @@ class Ts {
1348
1348
  this.callback = e, this.options = {
1349
1349
  ...this.defaultOptions,
1350
1350
  ...t
1351
- }, this.eventHandlerFunction = this.eventHandler.bind(this), F() && this.start();
1351
+ }, this.eventHandlerFunction = this.eventHandler.bind(this), N() && this.start();
1352
1352
  }
1353
1353
  start() {
1354
- if (!F()) {
1354
+ if (!N()) {
1355
1355
  console.warn("[UserVisibility](start) you should run this method on client side");
1356
1356
  return;
1357
1357
  }
@@ -1379,62 +1379,62 @@ class Ts {
1379
1379
  this.removeEventListener(), this.timeoutHandler && clearTimeout(this.timeoutHandler);
1380
1380
  }
1381
1381
  }
1382
- function Xn({
1382
+ function Jn({
1383
1383
  callback: s,
1384
1384
  options: e
1385
1385
  }) {
1386
- return new Ts(s, e);
1386
+ return new Is(s, e);
1387
1387
  }
1388
- function Gn() {
1389
- return Se("wait");
1388
+ function eo() {
1389
+ return Oe("wait");
1390
1390
  }
1391
- const Ae = "__maz-click-outside__";
1392
- function bt() {
1391
+ const xe = "__maz-click-outside__";
1392
+ function Tt() {
1393
1393
  return document.ontouchstart === null ? "touchstart" : "click";
1394
1394
  }
1395
- async function wt(s, e) {
1395
+ async function Lt(s, e) {
1396
1396
  try {
1397
- Et(s);
1397
+ zt(s);
1398
1398
  const t = e.instance, n = e.value, o = typeof n == "function";
1399
1399
  if (!o)
1400
1400
  throw new Error("[maz-ui](vClickOutside) the callback should be a function");
1401
- await Ne(), s[Ae] = (r) => {
1401
+ await Ue(), s[xe] = (r) => {
1402
1402
  if ((!s || r.target && !s.contains(r.target)) && n && o)
1403
1403
  return n.call(t, r);
1404
1404
  };
1405
- const i = bt();
1406
- document.addEventListener(i, s[Ae], { passive: !0 });
1405
+ const i = Tt();
1406
+ document.addEventListener(i, s[xe], { passive: !0 });
1407
1407
  } catch (t) {
1408
1408
  console.error("[maz-ui](vClickOutside)", t);
1409
1409
  }
1410
1410
  }
1411
- function Et(s) {
1411
+ function zt(s) {
1412
1412
  try {
1413
- const e = bt();
1414
- document.removeEventListener(e, s[Ae], !1), delete s[Ae];
1413
+ const e = Tt();
1414
+ document.removeEventListener(e, s[xe], !1), delete s[xe];
1415
1415
  } catch (e) {
1416
1416
  console.error("[maz-ui](vClickOutside)", e);
1417
1417
  }
1418
1418
  }
1419
- function Ls(s, e) {
1419
+ function ks(s, e) {
1420
1420
  try {
1421
1421
  if (e.value === e.oldValue)
1422
1422
  return;
1423
- wt(s, e);
1423
+ Lt(s, e);
1424
1424
  } catch (t) {
1425
1425
  console.error("[maz-ui](vClickOutside)", t);
1426
1426
  }
1427
1427
  }
1428
- const Cs = {
1429
- mounted: wt,
1430
- updated: Ls,
1431
- unmounted: Et
1432
- }, Is = {
1428
+ const As = {
1429
+ mounted: Lt,
1430
+ updated: ks,
1431
+ unmounted: zt
1432
+ }, Ss = {
1433
1433
  install: (s) => {
1434
- s.directive("click-outside", Cs);
1434
+ s.directive("click-outside", As);
1435
1435
  }
1436
1436
  };
1437
- function zt(s, e, t) {
1437
+ function Ct(s, e, t) {
1438
1438
  var r;
1439
1439
  s.stopPropagation();
1440
1440
  const n = typeof t.value == "function" ? t.value : t.value.handler, o = typeof t.value == "object" ? t.value.exclude : void 0;
@@ -1448,36 +1448,36 @@ function zt(s, e, t) {
1448
1448
  }
1449
1449
  !e.contains(s.target) && !i && (n == null || n());
1450
1450
  }
1451
- function Tt() {
1451
+ function It() {
1452
1452
  return document.ontouchstart === null ? "touchstart" : "click";
1453
1453
  }
1454
- function ks(s, e) {
1455
- const t = Tt();
1456
- document.removeEventListener(t, (n) => zt(n, s, e));
1454
+ function xs(s, e) {
1455
+ const t = It();
1456
+ document.removeEventListener(t, (n) => Ct(n, s, e));
1457
1457
  }
1458
- function As(s, e) {
1458
+ function Os(s, e) {
1459
1459
  if (typeof e.value != "function" && typeof e.value == "object" && typeof e.value.handler != "function") {
1460
1460
  console.error("[maz-ui](vClosable) v-closable directive requires a handler function");
1461
1461
  return;
1462
1462
  }
1463
- const t = Tt();
1464
- document.addEventListener(t, (n) => zt(n, s, e));
1463
+ const t = It();
1464
+ document.addEventListener(t, (n) => Ct(n, s, e));
1465
1465
  }
1466
- const Ss = {
1467
- mounted: As,
1468
- unmounted: ks
1469
- }, xs = {
1466
+ const Ds = {
1467
+ mounted: Os,
1468
+ unmounted: xs
1469
+ }, Ps = {
1470
1470
  install: (s) => {
1471
- s.directive("closable", Ss);
1471
+ s.directive("closable", Ds);
1472
1472
  }
1473
- }, Be = {
1473
+ }, Ne = {
1474
1474
  position: "top"
1475
1475
  };
1476
- class Lt {
1476
+ class kt {
1477
1477
  constructor(e = {}) {
1478
1478
  d(this, "options");
1479
1479
  this.options = {
1480
- ...Be,
1480
+ ...Ne,
1481
1481
  ...e
1482
1482
  };
1483
1483
  }
@@ -1505,24 +1505,24 @@ class Lt {
1505
1505
  e.removeAttribute("data-tooltip"), e.classList.remove("m-tooltip"), e.classList.remove("m-tooltip--top"), e.classList.remove("m-tooltip--bottom"), e.classList.remove("m-tooltip--left"), e.classList.remove("m-tooltip--right"), e.classList.remove("m-tooltip--open"), e.classList.remove(`m-tooltip--${this.getColor(t)}`);
1506
1506
  }
1507
1507
  }
1508
- let Le;
1509
- const Qn = {
1508
+ let Ie;
1509
+ const to = {
1510
1510
  beforeMount(s, e) {
1511
1511
  const t = typeof e.value == "object" ? e.value : {};
1512
- return Le = new Lt(t), Le.create(s, e);
1512
+ return Ie = new kt(t), Ie.create(s, e);
1513
1513
  },
1514
1514
  updated(s, e) {
1515
- return Le.update(s, e);
1515
+ return Ie.update(s, e);
1516
1516
  },
1517
1517
  unmounted(s, e) {
1518
- return Le.remove(s, e);
1518
+ return Ie.remove(s, e);
1519
1519
  }
1520
- }, Os = {
1521
- install: (s, e = Be) => {
1520
+ }, Ms = {
1521
+ install: (s, e = Ne) => {
1522
1522
  const t = {
1523
- ...Be,
1523
+ ...Ne,
1524
1524
  ...e
1525
- }, n = new Lt(t);
1525
+ }, n = new kt(t);
1526
1526
  s.directive("tooltip", {
1527
1527
  beforeMount: n.create.bind(n),
1528
1528
  updated: n.update.bind(n),
@@ -1530,19 +1530,88 @@ const Qn = {
1530
1530
  });
1531
1531
  }
1532
1532
  };
1533
- function _e(s, e) {
1533
+ function We(s, e) {
1534
1534
  let t = e == null ? void 0 : e.element;
1535
1535
  function n() {
1536
- t && Te(null, t);
1536
+ t && Ce(null, t);
1537
1537
  }
1538
1538
  const o = { ...e == null ? void 0 : e.props, ...e != null && e.addDestroyInProps ? { destroy: n } : {} }, i = J(
1539
1539
  s,
1540
1540
  o,
1541
1541
  e == null ? void 0 : e.children
1542
1542
  );
1543
- return e != null && e.app ? (i.appContext = e.app._context, t ? Te(i, t) : typeof document < "u" && (t = document.createElement("div"), Te(i, t))) : (t = t ?? document.body, Te(i, t)), { vNode: i, destroy: n, el: t };
1543
+ return e != null && e.app ? (i.appContext = e.app._context, t ? Ce(i, t) : typeof document < "u" && (t = document.createElement("div"), Ce(i, t))) : (t = t ?? document.body, Ce(i, t)), { vNode: i, destroy: n, el: t };
1544
+ }
1545
+ function $s(s) {
1546
+ return !!s;
1547
+ }
1548
+ function so(s) {
1549
+ return [...s].map((e) => {
1550
+ const t = e.codePointAt(0);
1551
+ return t ? t % 32 + 127461 : void 0;
1552
+ }).filter($s).map((e) => String.fromCodePoint(e)).join("");
1553
+ }
1554
+ function no(s, e) {
1555
+ let t;
1556
+ return function(...n) {
1557
+ clearTimeout(t), t = setTimeout(() => {
1558
+ s.apply(this, n);
1559
+ }, e);
1560
+ };
1544
1561
  }
1545
- const Ds = ["onKeypress"], Ms = { class: "m-fullscreen-img-scroller" }, Ps = ["src", "alt"], $s = /* @__PURE__ */ ve({
1562
+ class oo {
1563
+ constructor({ src: e, identifier: t, once: n = !0, async: o = !0, defer: i = !0 }) {
1564
+ d(this, "src");
1565
+ d(this, "script");
1566
+ d(this, "once");
1567
+ d(this, "async");
1568
+ d(this, "defer");
1569
+ d(this, "identifier");
1570
+ if (typeof window > "u")
1571
+ throw new TypeError("[ScriptLoader]: Is supported only on browser side");
1572
+ if (!e)
1573
+ throw new Error('[ScriptLoader]: You should provide the attribut "src"');
1574
+ if (!t)
1575
+ throw new Error('[ScriptLoader]: You should provide the attribut "identifier"');
1576
+ this.src = e, this.identifier = t, this.once = n, this.async = o, this.defer = i;
1577
+ }
1578
+ removeTag(e) {
1579
+ var t;
1580
+ typeof e == "string" ? (t = document.head.querySelector(`[data-identifier="${e}"]`)) == null || t.remove() : e.remove();
1581
+ }
1582
+ load() {
1583
+ const e = window, t = document.head.querySelectorAll(`[data-identifier="${this.identifier}"]`);
1584
+ if (this.once && e[this.identifier] && t.length > 0)
1585
+ return this.script = e[this.identifier], Promise.resolve(this.script);
1586
+ if (!this.once && t.length > 0)
1587
+ for (const n of t)
1588
+ this.removeTag(n);
1589
+ return this.injectScript();
1590
+ }
1591
+ injectScript() {
1592
+ const e = window;
1593
+ return new Promise((t, n) => {
1594
+ try {
1595
+ const o = document.createElement("script");
1596
+ o.src = this.src, o.async = this.async, o.defer = this.defer, o.dataset.identifier = this.identifier, o.addEventListener("error", (i) => n(new Error(`[ScriptLoader](injectScript) ${i.message}`))), o.addEventListener("load", (i) => (this.script = i, e[this.identifier] = i, t(i))), document.head.append(o);
1597
+ } catch (o) {
1598
+ throw new Error(`[ScriptLoader](init) ${o}`);
1599
+ }
1600
+ });
1601
+ }
1602
+ }
1603
+ function Hs(s) {
1604
+ return new Promise((e) => setTimeout(e, s));
1605
+ }
1606
+ function io(s, e) {
1607
+ let t = !1, n, o;
1608
+ return function(...i) {
1609
+ t ? (clearTimeout(n), n = setTimeout(() => {
1610
+ Date.now() - o >= e && (s.apply(this, i), o = Date.now());
1611
+ }, Math.max(e - (Date.now() - o), 0))) : (s.apply(this, i), o = Date.now(), t = !0);
1612
+ };
1613
+ }
1614
+ const Vs = ["onKeypress"], Fs = { class: "m-fullscreen-img-scroller" }, Bs = ["src", "alt"], Ns = /* @__PURE__ */ ge({
1546
1615
  __name: "MazFullscreenImg",
1547
1616
  props: {
1548
1617
  src: {},
@@ -1560,202 +1629,232 @@ const Ds = ["onKeypress"], Ms = { class: "m-fullscreen-img-scroller" }, Ps = ["s
1560
1629
  },
1561
1630
  emits: ["close", "previous", "next", "before-close"],
1562
1631
  setup(s, { emit: e }) {
1563
- const t = s, n = e, o = $(() => import("./MazSpinner-CDJhmIRl.mjs")), i = $(() => import("./x-mark-CnZwVvA7.mjs")), r = $(() => import("./chevron-left-BqVOLRdC.mjs")), a = y(!1), u = y(!1), l = y(!1), h = y(!1), p = y(!1), E = y(t.clickedElement), T = f(() => t.clickedElement.getBoundingClientRect()), P = f(
1564
- () => T.value.height < T.value.width
1565
- ), x = y(t.src), c = y(t.alt), g = y(), k = y(), b = f(() => p.value ? "--is-zoomed maz-cursor-zoom-out" : "maz-cursor-zoom-in");
1566
- function D() {
1567
- a.value = !0, u.value = !1, l.value = !0;
1632
+ const t = s, n = e, o = V(() => import("./MazSpinner-bdGjxsu6.mjs")), i = V(() => import("./x-mark-CnZwVvA7.mjs")), r = V(() => import("./chevron-left-BqVOLRdC.mjs")), a = y(!1), u = y(!1), l = y(!1), h = y(!1), g = y(!1), E = Ft({
1633
+ running: !1,
1634
+ ended: !1
1635
+ }), T = y(t.clickedElement), $ = f(() => t.clickedElement.getBoundingClientRect()), k = y(), c = y(t.src), b = y(t.alt), D = y(), v = y(), x = y(!0), H = f(() => ({
1636
+ "--is-zoomed": g.value,
1637
+ "--invisible": x.value,
1638
+ "--absolute": !g.value
1639
+ }));
1640
+ function L() {
1641
+ var p, w;
1642
+ v.value && (k.value = ((p = v.value) == null ? void 0 : p.naturalWidth) > ((w = v.value) == null ? void 0 : w.naturalHeight)), a.value = !0, u.value = !1, l.value = !0;
1568
1643
  }
1569
- Z(
1570
- () => l.value,
1571
- (m) => {
1572
- m && Oe();
1573
- }
1644
+ X(
1645
+ l,
1646
+ async (p) => {
1647
+ p && A();
1648
+ },
1649
+ { immediate: !0 }
1574
1650
  );
1575
- function O() {
1576
- n("before-close"), v();
1651
+ function P() {
1652
+ n("before-close"), O();
1577
1653
  }
1578
- function z(m) {
1579
- m.key === "Escape" && (m.preventDefault(), O()), (m.key === "ArrowLeft" || m.key === "ArrowRight") && (m.preventDefault(), de(m.key === "ArrowRight" ? "next" : "previous"));
1654
+ function j(p) {
1655
+ p.key === "Escape" && (p.preventDefault(), P()), (p.key === "ArrowLeft" || p.key === "ArrowRight") && (p.preventDefault(), me(p.key === "ArrowRight" ? "next" : "previous"));
1580
1656
  }
1581
- function B() {
1657
+ function se() {
1582
1658
  document.documentElement.classList.add("--m-fullscreen-open");
1583
1659
  }
1584
- function _() {
1660
+ function G() {
1585
1661
  document.documentElement.classList.remove("--m-fullscreen-open");
1586
1662
  }
1587
- function X() {
1663
+ function ce() {
1588
1664
  return [...document.querySelectorAll(".m-fullscreen-img-instance")];
1589
1665
  }
1590
- function G(m, w) {
1591
- return w < 0 ? m.length - 1 : w >= m.length ? 0 : w;
1666
+ function De(p, w) {
1667
+ return w < 0 ? p.length - 1 : w >= p.length ? 0 : w;
1592
1668
  }
1593
- async function Ee(m, w) {
1594
- m.classList.remove(t.openInstanceClass), w.classList.add(t.openInstanceClass);
1595
- const S = w.getAttribute("data-src"), M = w.getAttribute("data-alt");
1596
- c.value = M, S && (x.value = S), a.value = !1, a.value || (u.value = !0);
1669
+ async function de(p, w) {
1670
+ p.classList.remove(t.openInstanceClass), w.classList.add(t.openInstanceClass);
1671
+ const z = w.getAttribute("data-src"), M = w.getAttribute("data-alt");
1672
+ b.value = M, c.value = z ?? c.value;
1597
1673
  }
1598
- function de(m) {
1674
+ function me(p) {
1675
+ x.value = !0;
1599
1676
  const w = document.querySelector(
1600
1677
  `.m-fullscreen-img-instance.${t.openInstanceClass}`
1601
1678
  );
1602
1679
  if (w) {
1603
- const S = X(), M = S.indexOf(w), W = m === "next" ? M + 1 : M - 1, N = S[G(S, W)];
1604
- E.value = N, N && Ee(w, N), n(m), p.value ? se(k.value) : oe();
1680
+ const z = ce(), M = z.indexOf(w), W = p === "next" ? M + 1 : M - 1, R = z[De(z, W)];
1681
+ T.value = R, R && de(w, R), n(p), a.value = !1, u.value = !0, ct(() => a.value === !0, () => {
1682
+ x.value = !1, g.value ? fe() : m();
1683
+ }, {
1684
+ expectedValue: !0,
1685
+ interval: 100,
1686
+ maxAttempts: 50
1687
+ });
1605
1688
  }
1606
1689
  }
1607
- function se(m) {
1608
- P.value ? (m.style.width = `${window.innerWidth}px`, m.style.removeProperty("height")) : (m.style.height = `${window.innerHeight}px`, m.style.removeProperty("width")), m.style.removeProperty("top"), m.style.removeProperty("left");
1690
+ function fe() {
1691
+ const p = v.value;
1692
+ if (!p) {
1693
+ console.error("[maz-ui](vFullscreenImg) ImgElement is not defined");
1694
+ return;
1695
+ }
1696
+ p.style.removeProperty("max-width"), p.style.removeProperty("max-height"), p == null || p.style.removeProperty("top"), p == null || p.style.removeProperty("left"), k.value ? (p.style.height = "100vh", p.style.removeProperty("width")) : (p.style.width = "100vw", p.style.removeProperty("height"));
1609
1697
  }
1610
- async function xe() {
1611
- const m = k.value;
1612
- p.value ? (p.value = !p.value, oe()) : (p.value = !p.value, se(m));
1698
+ async function Pe() {
1699
+ g.value ? (g.value = !g.value, m()) : (g.value = !g.value, fe());
1613
1700
  }
1614
- function me(m) {
1615
- var w;
1616
- return (w = k.value) == null ? void 0 : w.animate(m, {
1701
+ function ne(p) {
1702
+ var z;
1703
+ E.running = !0, x.value = !1;
1704
+ const w = (z = v.value) == null ? void 0 : z.animate(p, {
1617
1705
  duration: t.animation.duration,
1618
- // Durée de l'animation en millisecondes
1619
1706
  easing: t.animation.easing
1620
- // Fonction d'interpolation pour l'animation inverse
1621
1707
  });
1708
+ if (!w) {
1709
+ console.error("[maz-ui](vFullscreenImg) animation is not defined"), E.running = !1, E.ended = !0;
1710
+ return;
1711
+ }
1712
+ return w;
1622
1713
  }
1623
- function ze(m = t.offset ?? 0) {
1624
- const w = (E.value instanceof HTMLImageElement ? E.value.naturalWidth : E.value.clientWidth) || 1, S = (E.value instanceof HTMLImageElement ? E.value.naturalHeight : E.value.clientHeight) || 1, M = window.innerWidth, W = window.innerHeight, N = Math.min(
1625
- (M - 2 * m) / w,
1626
- (W - 2 * m) / S
1627
- ), De = (M - w * N) / 2, Me = (W - S * N) / 2;
1714
+ function Le(p = t.offset ?? 0) {
1715
+ const w = T.value.clientWidth || 1, z = T.value.clientHeight || 1, M = window.innerWidth, W = window.innerHeight, R = Math.min(
1716
+ (M - 2 * p) / w,
1717
+ (W - 2 * p) / z
1718
+ ), Me = (M - w * R) / 2, $e = (W - z * R) / 2;
1628
1719
  return {
1629
- centerX: De,
1630
- centerY: Me,
1631
- originalWidth: w,
1632
- originalHeight: S,
1633
- scale: N
1720
+ centerX: Me,
1721
+ centerY: $e,
1722
+ width: w,
1723
+ height: z,
1724
+ scale: R
1634
1725
  };
1635
1726
  }
1636
- function ne({ trigger: m }) {
1637
- const { originalWidth: w, originalHeight: S, scale: M, centerX: W, centerY: N } = ze(), { top: De, left: Me, width: At, height: St } = T.value, We = [
1727
+ function ze({ trigger: p }) {
1728
+ const { width: w, height: z, scale: M, centerX: W, centerY: R } = Le(), { top: Me, left: $e, width: Ot, height: Dt } = $.value, Ke = [
1638
1729
  {
1639
- top: `${De}px`,
1640
- left: `${Me}px`,
1641
- width: `${At}px`,
1642
- height: `${St}px`,
1730
+ top: `${Me}px`,
1731
+ left: `${$e}px`,
1732
+ width: `${Ot}px`,
1733
+ height: `${Dt}px`,
1643
1734
  opacity: 0
1644
1735
  },
1645
1736
  {
1646
- top: `${N}px`,
1737
+ top: `${R}px`,
1647
1738
  left: `${W}px`,
1648
1739
  width: `${w * M}px`,
1649
- height: `${S * M}px`,
1740
+ height: `${z * M}px`,
1650
1741
  opacity: 1
1651
1742
  }
1652
1743
  ];
1653
1744
  return {
1654
- frames: m === "open" ? We : We.reverse()
1745
+ frames: p === "open" ? Ke : Ke.reverse()
1655
1746
  };
1656
1747
  }
1657
- function oe() {
1658
- const { centerX: m, centerY: w, originalHeight: S, originalWidth: M, scale: W } = ze(), N = {
1659
- top: `${w}px`,
1660
- left: `${m}px`,
1661
- width: `${M * W}px`,
1662
- height: `${S * W}px`
1748
+ function m() {
1749
+ const { height: p, width: w, scale: z } = Le(), M = k.value ? {
1750
+ width: `${w * z}px`,
1751
+ maxHeight: `${p * z}px`
1752
+ } : {
1753
+ height: `${p * z}px`,
1754
+ maxWidth: `${w * z}px`
1663
1755
  };
1664
- if (!k.value)
1665
- throw console.error("[maz-ui](vFullscreenImg) ImgElement is not defined");
1666
- Object.assign(k.value.style, N);
1756
+ if (!v.value) {
1757
+ console.error("[maz-ui](vFullscreenImg) ImgElement is not defined");
1758
+ return;
1759
+ }
1760
+ k.value ? (v.value.style.removeProperty("height"), v.value.style.removeProperty("maxHeight")) : (v.value.style.removeProperty("width"), v.value.style.removeProperty("maxWidth")), Object.assign(v.value.style, M);
1667
1761
  }
1668
- function Oe() {
1669
- const { frames: m } = ne({
1762
+ function A() {
1763
+ const { frames: p } = ze({
1670
1764
  trigger: "open"
1671
- }), w = me(m);
1672
- if (!w)
1673
- throw console.error("[maz-ui](vFullscreenImg) open animation is not defined");
1765
+ }), w = ne(p);
1766
+ if (!w) {
1767
+ console.error("[maz-ui](vFullscreenImg) open animation is not defined"), m();
1768
+ return;
1769
+ }
1674
1770
  w.onfinish = () => {
1675
- oe();
1771
+ m(), E.running = !1, E.ended = !0;
1676
1772
  };
1677
1773
  }
1678
- function v() {
1679
- const { frames: m } = ne({
1774
+ function O() {
1775
+ const { frames: p } = ze({
1680
1776
  trigger: "close"
1681
- }), w = me(m);
1682
- if (!w)
1683
- throw console.error("[maz-ui](vFullscreenImg) close animation is not defined");
1684
- w.onfinish = () => {
1685
- var S, M;
1686
- n("close"), (S = g.value) == null || S.remove(), (M = t.destroy) == null || M.call(t);
1687
- };
1777
+ }), w = ne(p);
1778
+ function z() {
1779
+ var M, W;
1780
+ n("close"), (M = D.value) == null || M.remove(), (W = t.destroy) == null || W.call(t), E.running = !1, E.ended = !0;
1781
+ }
1782
+ if (!w) {
1783
+ console.error("[maz-ui](vFullscreenImg) close animation is not defined"), z();
1784
+ return;
1785
+ }
1786
+ w.onfinish = z;
1688
1787
  }
1689
- function I() {
1690
- p.value || oe();
1788
+ function he() {
1789
+ g.value || m();
1691
1790
  }
1692
- return ce(() => {
1693
- u.value = !0, document.addEventListener("keydown", z), window.addEventListener("resize", I), B(), h.value = X().length > 1;
1694
- }), ot(() => {
1695
- document.removeEventListener("keydown", z), window.removeEventListener("resize", I), _();
1696
- }), (m, w) => (L(), U("div", {
1791
+ return ue(() => {
1792
+ u.value = !0, document.addEventListener("keydown", j), window.addEventListener("resize", he), se(), h.value = ce().length > 1;
1793
+ }), rt(() => {
1794
+ document.removeEventListener("keydown", j), window.removeEventListener("resize", he), G();
1795
+ }), (p, w) => (C(), _("div", {
1697
1796
  ref_key: "FullscreenImgElement",
1698
- ref: g,
1797
+ ref: D,
1699
1798
  role: "button",
1700
1799
  class: "m-fullscreen-img",
1701
1800
  tabindex: "0",
1702
- onClick: K(O, ["stop"]),
1703
- onKeypress: $t(K(O, ["prevent"]), ["esc"])
1801
+ onClick: Y(P, ["stop"]),
1802
+ onKeypress: Bt(Y(P, ["prevent"]), ["esc"])
1704
1803
  }, [
1705
- it(J(
1706
- A(o),
1707
- { class: "m-fullscreen-img-loader maz-h-16" },
1708
- null,
1709
- 512
1710
- /* NEED_PATCH */
1711
- ), [
1712
- [rt, u.value]
1713
- ]),
1714
- l.value && h.value ? (L(), U("button", {
1804
+ l.value && h.value ? (C(), _("button", {
1715
1805
  key: 0,
1716
1806
  type: "button",
1717
1807
  class: "m-fullscreen-btn --next",
1718
- onClick: w[0] || (w[0] = K((S) => de("next"), ["stop"]))
1808
+ onClick: w[0] || (w[0] = Y((z) => me("next"), ["stop"]))
1719
1809
  }, [
1720
- J(A(r), { class: "maz-rotate-180 maz-text-3xl" })
1721
- ])) : C("v-if", !0),
1722
- l.value && h.value ? (L(), U("button", {
1810
+ J(S(r), { class: "maz-rotate-180" })
1811
+ ])) : I("v-if", !0),
1812
+ l.value && h.value ? (C(), _("button", {
1723
1813
  key: 1,
1724
1814
  type: "button",
1725
1815
  class: "m-fullscreen-btn --previous",
1726
- onClick: w[1] || (w[1] = K((S) => de("previous"), ["stop"]))
1816
+ onClick: w[1] || (w[1] = Y((z) => me("previous"), ["stop"]))
1727
1817
  }, [
1728
- J(A(r), { class: "maz-text-3xl" })
1729
- ])) : C("v-if", !0),
1730
- H("button", {
1818
+ J(S(r))
1819
+ ])) : I("v-if", !0),
1820
+ F("button", {
1731
1821
  type: "button",
1732
1822
  class: "m-fullscreen-btn --close",
1733
- onClick: O
1823
+ onClick: P
1734
1824
  }, [
1735
- J(A(i), { class: "maz-text-3xl" })
1825
+ J(S(i))
1736
1826
  ]),
1737
- H("div", Ms, [
1738
- C(" eslint-disable-next-line vuejs-accessibility/no-static-element-interactions, vuejs-accessibility/click-events-have-key-events "),
1739
- H("img", {
1827
+ F("div", Fs, [
1828
+ I(" eslint-disable-next-line vuejs-accessibility/no-static-element-interactions, vuejs-accessibility/click-events-have-key-events "),
1829
+ F("img", {
1740
1830
  ref_key: "ImgElement",
1741
- ref: k,
1742
- src: x.value,
1743
- alt: c.value ?? void 0,
1831
+ ref: v,
1832
+ src: c.value,
1833
+ alt: b.value ?? void 0,
1744
1834
  tabindex: "0",
1745
- class: ue([b.value]),
1746
- onLoad: D,
1747
- onClick: w[2] || (w[2] = K((S) => m.zoom ? xe() : void 0, ["stop"]))
1748
- }, null, 42, Ps)
1835
+ class: le([H.value]),
1836
+ onLoad: L,
1837
+ onClick: w[2] || (w[2] = Y((z) => p.zoom && Pe(), ["stop"]))
1838
+ }, null, 42, Bs),
1839
+ at(J(
1840
+ S(o),
1841
+ { class: "m-fullscreen-img-loader" },
1842
+ null,
1843
+ 512
1844
+ /* NEED_PATCH */
1845
+ ), [
1846
+ [lt, u.value]
1847
+ ])
1749
1848
  ])
1750
- ], 40, Ds));
1849
+ ], 40, Vs));
1751
1850
  }
1752
- }), qe = (s, e) => {
1851
+ }), Re = (s, e) => {
1753
1852
  const t = s.__vccOpts || s;
1754
1853
  for (const [n, o] of e)
1755
1854
  t[n] = o;
1756
1855
  return t;
1757
- }, Hs = /* @__PURE__ */ qe($s, [["__scopeId", "data-v-42226ee7"]]), Ge = "m-fullscreen-is-open";
1758
- class Vs {
1856
+ }, js = /* @__PURE__ */ Re(Ns, [["__scopeId", "data-v-b6e5fc28"]]), Je = "m-fullscreen-is-open";
1857
+ class Us {
1759
1858
  constructor() {
1760
1859
  d(this, "options");
1761
1860
  d(this, "defaultOptions", {
@@ -1812,10 +1911,10 @@ class Vs {
1812
1911
  e.removeEventListener("mouseenter", this.mouseEnterListener), e.removeEventListener("mouseleave", this.mouseLeaveListener), e.removeEventListener("click", this.renderPreviewListener), e.classList.remove("m-fullscreen-img-instance"), e.style.cursor = "";
1813
1912
  }
1814
1913
  renderPreview(e) {
1815
- return e.classList.add(Ge), _e(Hs, {
1914
+ return e.classList.add(Je), We(js, {
1816
1915
  props: {
1817
1916
  ...this.options,
1818
- openInstanceClass: Ge,
1917
+ openInstanceClass: Je,
1819
1918
  clickedElement: e,
1820
1919
  clickedElementBounds: e.getBoundingClientRect()
1821
1920
  },
@@ -1829,22 +1928,22 @@ class Vs {
1829
1928
  e.style.zIndex = "1", this.options.scaleOnHover && (e.style.transform = "scale(1.04)"), this.options.blurOnHover && (e.style.filter = "blur(3px)");
1830
1929
  }
1831
1930
  }
1832
- let Ce;
1833
- const Bs = {
1931
+ let ke;
1932
+ const _s = {
1834
1933
  mounted(s, e) {
1835
- return Ce = new Vs(), Ce.create(s, e);
1934
+ return ke = new Us(), ke.create(s, e);
1836
1935
  },
1837
1936
  updated(s, e) {
1838
- return Ce.update(s, e);
1937
+ return ke.update(s, e);
1839
1938
  },
1840
1939
  unmounted(s) {
1841
- return Ce.remove(s);
1940
+ return ke.remove(s);
1842
1941
  }
1843
- }, Fs = {
1942
+ }, qs = {
1844
1943
  install(s) {
1845
- s.directive("fullscreen-img", Bs);
1944
+ s.directive("fullscreen-img", _s);
1846
1945
  }
1847
- }, Ns = "data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7", Fe = {
1946
+ }, Ws = "data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7", je = {
1848
1947
  baseClass: "m-lazy-img",
1849
1948
  loadedClass: "m-lazy-loaded",
1850
1949
  loadingClass: "m-lazy-loading",
@@ -1858,10 +1957,10 @@ const Bs = {
1858
1957
  threshold: 0.1
1859
1958
  }
1860
1959
  };
1861
- class Ct {
1960
+ class At {
1862
1961
  constructor(e = {}) {
1863
1962
  d(this, "observers", []);
1864
- d(this, "defaultOptions", Fe);
1963
+ d(this, "defaultOptions", je);
1865
1964
  d(this, "options");
1866
1965
  d(this, "onImgLoadedCallback");
1867
1966
  d(this, "onImgErrorCallback");
@@ -1999,7 +2098,7 @@ class Ct {
1999
2098
  async add(e, t) {
2000
2099
  if (this.hasBgImgMode(t) && this.isPictureElement(e))
2001
2100
  throw new Error(`[MazLazyImg] You can't use the "bg-image" mode with "<picture />" element`);
2002
- setTimeout(() => this.setBaseClass(e), 0), e.getAttribute("src") || this.setImgSrc(e, Ns), await this.bindUpdateHandler(e, t, "bind");
2101
+ setTimeout(() => this.setBaseClass(e), 0), e.getAttribute("src") || this.setImgSrc(e, Ws), await this.bindUpdateHandler(e, t, "bind");
2003
2102
  }
2004
2103
  async update(e, t) {
2005
2104
  t.value !== t.oldValue && (this.hasImgLoaded = !1, this.removeAllStateClasses(e), await this.bindUpdateHandler(e, t, "update"));
@@ -2011,35 +2110,35 @@ class Ct {
2011
2110
  this.observers = [];
2012
2111
  }
2013
2112
  }
2014
- let Ie;
2015
- const Jn = {
2113
+ let Ae;
2114
+ const ro = {
2016
2115
  created(s, e) {
2017
2116
  const t = typeof e.value == "object" ? e.value : {};
2018
- Ie = new Ct(t), Ie.add(s, e);
2117
+ Ae = new At(t), Ae.add(s, e);
2019
2118
  },
2020
2119
  updated(s, e) {
2021
- Ie.update(s, e);
2120
+ Ae.update(s, e);
2022
2121
  },
2023
2122
  unmounted(s, e) {
2024
- Ie.remove(s, e);
2123
+ Ae.remove(s, e);
2025
2124
  }
2026
- }, js = {
2125
+ }, Rs = {
2027
2126
  install(s, e = {}) {
2028
2127
  const t = {
2029
- ...Fe,
2128
+ ...je,
2030
2129
  ...e,
2031
2130
  observerOptions: {
2032
- ...Fe.observerOptions,
2131
+ ...je.observerOptions,
2033
2132
  ...e.observerOptions
2034
2133
  }
2035
- }, n = new Ct(t);
2134
+ }, n = new At(t);
2036
2135
  s.directive("lazy-img", {
2037
2136
  created: n.add.bind(n),
2038
2137
  updated: n.update.bind(n),
2039
2138
  unmounted: n.remove.bind(n)
2040
2139
  });
2041
2140
  }
2042
- }, Us = `
2141
+ }, Ks = `
2043
2142
  .maz-zoom-img {
2044
2143
  position: fixed;
2045
2144
  top: 0;
@@ -2162,13 +2261,13 @@ const Jn = {
2162
2261
 
2163
2262
  .maz-zoom-img .maz-zoom-btn:hover {
2164
2263
  background-color: hsl(0, 0%, 0%);
2165
- }`, Qe = {
2264
+ }`, et = {
2166
2265
  close: '<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24"><path d="M0 0h24v24H0z" fill="none"/><path d="M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"/></svg>',
2167
2266
  next: '<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24"><path d="M0 0h24v24H0z" fill="none"/><path d="M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg>',
2168
2267
  previous: '<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24"><path d="M0 0h24v24H0z" fill="none"/><path d="M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z"/></svg>',
2169
2268
  spinner: '<svg width="40px" height="40px" version="1.1" xmlns="http://www.w3.org/2000/svg" fill="currentColor" x="0px" y="0px" viewBox="0 0 50 50" xml:space="preserve" class="maz-zoom-img__loader__svg" data-v-6d1cb50c=""><path d="M43.935,25.145c0-10.318-8.364-18.683-18.683-18.683c-10.318,0-18.683,8.365-18.683,18.683h4.068c0-8.071,6.543-14.615,14.615-14.615c8.072,0,14.615,6.543,14.615,14.615H43.935z"></path></svg>'
2170
2269
  };
2171
- class _s {
2270
+ class Ys {
2172
2271
  constructor(e) {
2173
2272
  d(this, "options");
2174
2273
  d(this, "loader");
@@ -2215,7 +2314,7 @@ class _s {
2215
2314
  e.classList.add(
2216
2315
  "maz-is-open"
2217
2316
  /* OPEN */
2218
- ), this.addStyle(Us);
2317
+ ), this.addStyle(Ks);
2219
2318
  const n = document.createElement("div");
2220
2319
  n.classList.add("maz-zoom-img"), n.setAttribute("id", "MazImgPreviewFullsize"), n.addEventListener("click", (o) => {
2221
2320
  n.isEqualNode(o.target) && this.closePreview();
@@ -2236,7 +2335,7 @@ class _s {
2236
2335
  }
2237
2336
  getLoader() {
2238
2337
  const e = document.createElement("div");
2239
- return e.classList.add("maz-zoom-img__loader"), e.innerHTML = Qe.spinner, e;
2338
+ return e.classList.add("maz-zoom-img__loader"), e.innerHTML = et.spinner, e;
2240
2339
  }
2241
2340
  mouseLeave(e) {
2242
2341
  this.options.scale && (e.style.transform = ""), this.options.blur && (e.style.filter = ""), e.style.zIndex = "";
@@ -2249,7 +2348,7 @@ class _s {
2249
2348
  }
2250
2349
  getButton(e = "close") {
2251
2350
  const t = document.createElement("button");
2252
- t.innerHTML = Qe[e];
2351
+ t.innerHTML = et[e];
2253
2352
  const n = e === "close" ? this.closePreview() : this.allInstances ? this.nextPreviousImage(e === "next") : null;
2254
2353
  return t.addEventListener("click", () => n), t.classList.add("maz-zoom-btn"), t.classList.add(`maz-zoom-btn--${e}`), t;
2255
2354
  }
@@ -2302,47 +2401,47 @@ class _s {
2302
2401
  this.img.removeEventListener("load", this.onImgLoadedCallback);
2303
2402
  }
2304
2403
  }
2305
- let ke;
2306
- const qs = {
2404
+ let Se;
2405
+ const Zs = {
2307
2406
  created(s, e) {
2308
- ke = new _s(e), ke.create(s);
2407
+ Se = new Ys(e), Se.create(s);
2309
2408
  },
2310
2409
  updated(s, e) {
2311
- ke.update(e);
2410
+ Se.update(e);
2312
2411
  },
2313
2412
  unmounted(s) {
2314
- ke.remove(s);
2413
+ Se.remove(s);
2315
2414
  }
2316
- }, Ws = {
2415
+ }, Xs = {
2317
2416
  install(s) {
2318
- s.directive("zoom-img", qs);
2319
- }
2320
- }, Rs = [
2321
- xs,
2322
- Ws,
2323
- js,
2324
- Is,
2325
- Fs,
2326
- Os
2327
- ], eo = {
2417
+ s.directive("zoom-img", Zs);
2418
+ }
2419
+ }, Gs = [
2420
+ Ps,
2421
+ Xs,
2422
+ Rs,
2423
+ Ss,
2424
+ qs,
2425
+ Ms
2426
+ ], ao = {
2328
2427
  install(s) {
2329
- for (const e of Rs)
2428
+ for (const e of Gs)
2330
2429
  e.install(s, {});
2331
2430
  }
2332
2431
  };
2333
- function Ks(s) {
2432
+ function Qs(s) {
2334
2433
  return s ? (s = s.toString(), s.charAt(0).toUpperCase() + s.slice(1)) : "";
2335
2434
  }
2336
- const Ys = {
2435
+ const Js = {
2337
2436
  style: "currency",
2338
2437
  minimumFractionDigits: 2,
2339
2438
  round: !1
2340
2439
  };
2341
- function Zs(s, e, t) {
2440
+ function en(s, e, t) {
2342
2441
  let n = Number(s);
2343
2442
  return t.round && (n = Math.floor(n), t.minimumFractionDigits = 0), new Intl.NumberFormat(e, t).format(n);
2344
2443
  }
2345
- function Xs(s, e, t) {
2444
+ function tn(s, e, t) {
2346
2445
  if (s === void 0)
2347
2446
  throw new TypeError("[maz-ui](FilterCurrency) The `number` attribute is required.");
2348
2447
  if (e === void 0)
@@ -2352,29 +2451,29 @@ function Xs(s, e, t) {
2352
2451
  if (t.currency === void 0)
2353
2452
  throw new TypeError("[maz-ui](FilterCurrency) The `options.currency` attribute is required.");
2354
2453
  }
2355
- function Gs(s, e, t) {
2454
+ function sn(s, e, t) {
2356
2455
  const n = {
2357
- ...Ys,
2456
+ ...Js,
2358
2457
  ...t
2359
2458
  };
2360
- Xs(s, e, n);
2459
+ tn(s, e, n);
2361
2460
  try {
2362
- return Zs(s, e, n);
2461
+ return en(s, e, n);
2363
2462
  } catch (o) {
2364
2463
  throw new Error(`[maz-ui](FilterCurrency) ${o}`);
2365
2464
  }
2366
2465
  }
2367
- const Qs = {
2466
+ const nn = {
2368
2467
  month: "short",
2369
2468
  day: "numeric",
2370
2469
  year: "numeric"
2371
2470
  };
2372
- function Js(s, e, t) {
2471
+ function on(s, e, t) {
2373
2472
  if (e === void 0)
2374
2473
  throw new TypeError("[maz-ui](FilterDate) The `locale` attribute is required.");
2375
2474
  if (typeof e != "string")
2376
2475
  throw new TypeError("[maz-ui](FilterDate) The `locale` attribute must be a string.");
2377
- const n = t ?? Qs;
2476
+ const n = t ?? nn;
2378
2477
  try {
2379
2478
  const o = s instanceof Date ? s : new Date(s);
2380
2479
  return new Intl.DateTimeFormat(e, n).format(o);
@@ -2382,12 +2481,12 @@ function Js(s, e, t) {
2382
2481
  throw new Error(`[maz-ui](FilterDate) ${o}`);
2383
2482
  }
2384
2483
  }
2385
- const en = {
2484
+ const rn = {
2386
2485
  minimumFractionDigits: 2
2387
2486
  };
2388
- function tn(s, e, t) {
2487
+ function an(s, e, t) {
2389
2488
  const n = {
2390
- ...en,
2489
+ ...rn,
2391
2490
  ...t
2392
2491
  };
2393
2492
  if (s === void 0)
@@ -2402,86 +2501,16 @@ function tn(s, e, t) {
2402
2501
  throw new Error(`[maz-ui](FilterNumber) ${o}`);
2403
2502
  }
2404
2503
  }
2405
- const sn = {
2406
- capitalize: Ks,
2407
- currency: Gs,
2408
- date: Js,
2409
- number: tn
2410
- }, to = {
2504
+ const ln = {
2505
+ capitalize: Qs,
2506
+ currency: sn,
2507
+ date: on,
2508
+ number: an
2509
+ }, lo = {
2411
2510
  install(s) {
2412
- s.provide("filters", sn);
2511
+ s.provide("filters", ln);
2413
2512
  }
2414
- };
2415
- function nn(s) {
2416
- return !!s;
2417
- }
2418
- function so(s) {
2419
- return [...s].map((e) => {
2420
- const t = e.codePointAt(0);
2421
- return t ? t % 32 + 127461 : void 0;
2422
- }).filter(nn).map((e) => String.fromCodePoint(e)).join("");
2423
- }
2424
- function no(s, e) {
2425
- let t;
2426
- return function(...n) {
2427
- clearTimeout(t), t = setTimeout(() => {
2428
- s.apply(this, n);
2429
- }, e);
2430
- };
2431
- }
2432
- class oo {
2433
- constructor({ src: e, identifier: t, once: n = !0, async: o = !0, defer: i = !0 }) {
2434
- d(this, "src");
2435
- d(this, "script");
2436
- d(this, "once");
2437
- d(this, "async");
2438
- d(this, "defer");
2439
- d(this, "identifier");
2440
- if (typeof window > "u")
2441
- throw new TypeError("[ScriptLoader]: Is supported only on browser side");
2442
- if (!e)
2443
- throw new Error('[ScriptLoader]: You should provide the attribut "src"');
2444
- if (!t)
2445
- throw new Error('[ScriptLoader]: You should provide the attribut "identifier"');
2446
- this.src = e, this.identifier = t, this.once = n, this.async = o, this.defer = i;
2447
- }
2448
- removeTag(e) {
2449
- var t;
2450
- typeof e == "string" ? (t = document.head.querySelector(`[data-identifier="${e}"]`)) == null || t.remove() : e.remove();
2451
- }
2452
- load() {
2453
- const e = window, t = document.head.querySelectorAll(`[data-identifier="${this.identifier}"]`);
2454
- if (this.once && e[this.identifier] && t.length > 0)
2455
- return this.script = e[this.identifier], Promise.resolve(this.script);
2456
- if (!this.once && t.length > 0)
2457
- for (const n of t)
2458
- this.removeTag(n);
2459
- return this.injectScript();
2460
- }
2461
- injectScript() {
2462
- const e = window;
2463
- return new Promise((t, n) => {
2464
- try {
2465
- const o = document.createElement("script");
2466
- o.src = this.src, o.async = this.async, o.defer = this.defer, o.dataset.identifier = this.identifier, o.addEventListener("error", (i) => n(new Error(`[ScriptLoader](injectScript) ${i.message}`))), o.addEventListener("load", (i) => (this.script = i, e[this.identifier] = i, t(i))), document.head.append(o);
2467
- } catch (o) {
2468
- throw new Error(`[ScriptLoader](init) ${o}`);
2469
- }
2470
- });
2471
- }
2472
- }
2473
- function on(s) {
2474
- return new Promise((e) => setTimeout(e, s));
2475
- }
2476
- function io(s, e) {
2477
- let t = !1, n, o;
2478
- return function(...i) {
2479
- t ? (clearTimeout(n), n = setTimeout(() => {
2480
- Date.now() - o >= e && (s.apply(this, i), o = Date.now());
2481
- }, Math.max(e - (Date.now() - o), 0))) : (s.apply(this, i), o = Date.now(), t = !0);
2482
- };
2483
- }
2484
- const He = {
2513
+ }, Fe = {
2485
2514
  delay: 100,
2486
2515
  observer: {
2487
2516
  root: void 0,
@@ -2494,17 +2523,17 @@ const He = {
2494
2523
  delay: 0
2495
2524
  }
2496
2525
  };
2497
- class rn {
2526
+ class un {
2498
2527
  constructor(e) {
2499
2528
  d(this, "options");
2500
2529
  this.options = {
2501
- delay: (e == null ? void 0 : e.delay) ?? He.delay,
2530
+ delay: (e == null ? void 0 : e.delay) ?? Fe.delay,
2502
2531
  observer: {
2503
- ...He.observer,
2532
+ ...Fe.observer,
2504
2533
  ...e == null ? void 0 : e.observer
2505
2534
  },
2506
2535
  animation: {
2507
- ...He.animation,
2536
+ ...Fe.animation,
2508
2537
  ...e == null ? void 0 : e.animation
2509
2538
  }
2510
2539
  };
@@ -2522,10 +2551,10 @@ class rn {
2522
2551
  for (const a of r) {
2523
2552
  const u = a.getAttribute("data-maz-aos-once"), l = typeof u == "string" ? u === "true" : this.options.animation.once;
2524
2553
  if (typeof this.options.observer.threshold == "number" && n.intersectionRatio > this.options.observer.threshold) {
2525
- const h = a.getAttribute("data-maz-aos-duration"), p = a.getAttribute("data-maz-aos-delay");
2554
+ const h = a.getAttribute("data-maz-aos-duration"), g = a.getAttribute("data-maz-aos-delay");
2526
2555
  if (h || (a.style.transitionDuration = `${this.options.animation.duration}ms`, setTimeout(() => {
2527
2556
  a.style.transitionDuration = "0";
2528
- }, 1e3)), p || (a.style.transitionDelay = `${this.options.animation.delay}ms`, setTimeout(() => {
2557
+ }, 1e3)), g || (a.style.transitionDelay = `${this.options.animation.delay}ms`, setTimeout(() => {
2529
2558
  a.style.transitionDelay = "0";
2530
2559
  }, 1e3)), a.classList.add("maz-aos-animate"), l) {
2531
2560
  const E = a.getAttribute("data-maz-aos-anchor");
@@ -2541,7 +2570,7 @@ class rn {
2541
2570
  }
2542
2571
  }
2543
2572
  async handleObserver() {
2544
- await on(this.options.delay);
2573
+ await Hs(this.options.delay);
2545
2574
  const e = new IntersectionObserver(this.handleIntersect.bind(this), this.options.observer);
2546
2575
  for (const t of document.querySelectorAll("[data-maz-aos]")) {
2547
2576
  const n = t.getAttribute("data-maz-aos-anchor");
@@ -2553,23 +2582,23 @@ class rn {
2553
2582
  }
2554
2583
  }
2555
2584
  runAnimations() {
2556
- if (F())
2585
+ if (N())
2557
2586
  return this.handleObserver();
2558
2587
  console.warn("[MazAos](runAnimations) should be executed on client side");
2559
2588
  }
2560
2589
  }
2561
- let fe;
2562
- const ro = {
2590
+ let ve;
2591
+ const uo = {
2563
2592
  install: (s, e) => {
2564
- fe = new rn(e), s.provide("aos", fe), F() && (e != null && e.router ? e.router.afterEach(async () => {
2565
- fe.runAnimations();
2566
- }) : fe.runAnimations());
2593
+ ve = new un(e), s.provide("aos", ve), N() && (e != null && e.router ? e.router.afterEach(async () => {
2594
+ ve.runAnimations();
2595
+ }) : ve.runAnimations());
2567
2596
  }
2568
2597
  };
2569
- function ao() {
2570
- return fe;
2598
+ function co() {
2599
+ return ve;
2571
2600
  }
2572
- const Je = "--backdrop-present", an = /* @__PURE__ */ ve({
2601
+ const tt = "--backdrop-present", cn = /* @__PURE__ */ ge({
2573
2602
  inheritAttrs: !1,
2574
2603
  __name: "MazBackdrop",
2575
2604
  props: {
@@ -2586,24 +2615,24 @@ const Je = "--backdrop-present", an = /* @__PURE__ */ ve({
2586
2615
  setup(s, { expose: e, emit: t }) {
2587
2616
  const n = s, o = t;
2588
2617
  function i() {
2589
- document.documentElement.classList.add(Je);
2618
+ document.documentElement.classList.add(tt);
2590
2619
  }
2591
2620
  async function r() {
2592
- document.querySelector(".m-backdrop.--present") || document.documentElement.classList.remove(Je);
2621
+ document.querySelector(".m-backdrop.--present") || document.documentElement.classList.remove(tt);
2593
2622
  }
2594
2623
  const a = y(n.modelValue);
2595
2624
  function u() {
2596
2625
  l(!1);
2597
2626
  }
2598
2627
  async function l(c) {
2599
- var g;
2600
- c || (o("before-close"), await ((g = n.beforeClose) == null ? void 0 : g.call(n))), a.value = c;
2628
+ var b;
2629
+ c || (o("before-close"), await ((b = n.beforeClose) == null ? void 0 : b.call(n))), a.value = c;
2601
2630
  }
2602
2631
  function h() {
2603
2632
  o("open");
2604
2633
  }
2605
- function p() {
2606
- o("update:model-value", !1), o("close"), x();
2634
+ function g() {
2635
+ o("update:model-value", !1), o("close"), k();
2607
2636
  }
2608
2637
  function E() {
2609
2638
  n.persistent || u();
@@ -2611,56 +2640,56 @@ const Je = "--backdrop-present", an = /* @__PURE__ */ ve({
2611
2640
  function T(c) {
2612
2641
  !n.noCloseOnEscKey && c.key === "Escape" && !n.persistent && u();
2613
2642
  }
2614
- function P() {
2643
+ function $() {
2615
2644
  i(), document.addEventListener("keyup", T, !1);
2616
2645
  }
2617
- function x() {
2646
+ function k() {
2618
2647
  document.removeEventListener("keyup", T), r();
2619
2648
  }
2620
- return ce(() => {
2621
- n.modelValue ? P() : x();
2622
- }), Z(
2649
+ return ue(() => {
2650
+ n.modelValue ? $() : k();
2651
+ }), X(
2623
2652
  () => n.modelValue,
2624
2653
  (c) => {
2625
- a.value = c, c ? P() : x();
2654
+ a.value = c, c ? $() : k();
2626
2655
  }
2627
2656
  ), e({
2628
2657
  onBackdropAnimationEnter: h,
2629
- onBackdropAnimationLeave: p,
2658
+ onBackdropAnimationLeave: g,
2630
2659
  onBackdropClicked: E,
2631
2660
  close: u,
2632
2661
  present: a,
2633
2662
  toggleModal: l,
2634
2663
  onKeyPress: T
2635
- }), (c, g) => (L(), V(Ht, { to: c.teleportSelector }, [
2636
- J(at, {
2664
+ }), (c, b) => (C(), B(Nt, { to: c.teleportSelector }, [
2665
+ J(ut, {
2637
2666
  appear: "",
2638
2667
  name: c.transitionName,
2639
2668
  onAfterEnter: h,
2640
- onAfterLeave: p
2669
+ onAfterLeave: g
2641
2670
  }, {
2642
- default: j(() => [
2643
- a.value ? (L(), U(
2671
+ default: U(() => [
2672
+ a.value ? (C(), _(
2644
2673
  "div",
2645
2674
  {
2646
2675
  key: 0,
2647
- class: ue(["m-backdrop --present", [c.backdropClass]]),
2676
+ class: le(["m-backdrop --present", [c.backdropClass]]),
2648
2677
  tabindex: "-1",
2649
2678
  role: "dialog"
2650
2679
  },
2651
2680
  [
2652
- H(
2681
+ F(
2653
2682
  "button",
2654
2683
  {
2655
- class: ue(["m-backdrop-overlay", { "--disabled": c.persistent }]),
2684
+ class: le(["m-backdrop-overlay", { "--disabled": c.persistent }]),
2656
2685
  tabindex: "-1",
2657
- onClick: K(E, ["self"])
2686
+ onClick: Y(E, ["self"])
2658
2687
  },
2659
2688
  null,
2660
2689
  2
2661
2690
  /* CLASS */
2662
2691
  ),
2663
- H(
2692
+ F(
2664
2693
  "div",
2665
2694
  ee({
2666
2695
  class: ["m-backdrop-content", c.backdropContentClass]
@@ -2677,24 +2706,24 @@ const Je = "--backdrop-present", an = /* @__PURE__ */ ve({
2677
2706
  ],
2678
2707
  2
2679
2708
  /* CLASS */
2680
- )) : C("v-if", !0)
2709
+ )) : I("v-if", !0)
2681
2710
  ]),
2682
2711
  _: 3
2683
2712
  /* FORWARDED */
2684
2713
  }, 8, ["name"])
2685
2714
  ], 8, ["to"]));
2686
2715
  }
2687
- }), ln = {
2716
+ }), dn = {
2688
2717
  key: 0,
2689
2718
  id: "dialogTitle",
2690
2719
  class: "maz-my-0 maz-text-xl maz-font-semibold"
2691
- }, un = {
2720
+ }, mn = {
2692
2721
  id: "dialogDesc",
2693
2722
  class: "m-dialog-content"
2694
- }, cn = {
2723
+ }, fn = {
2695
2724
  key: 0,
2696
2725
  class: "m-dialog-footer"
2697
- }, dn = /* @__PURE__ */ ve({
2726
+ }, hn = /* @__PURE__ */ ge({
2698
2727
  __name: "MazDialog",
2699
2728
  props: {
2700
2729
  modelValue: { type: Boolean },
@@ -2714,7 +2743,7 @@ const Je = "--backdrop-present", an = /* @__PURE__ */ ve({
2714
2743
  },
2715
2744
  emits: ["open", "close", "update:model-value"],
2716
2745
  setup(s, { expose: e }) {
2717
- const t = s, n = $(() => import("./MazBtn-CTqI4qhg.mjs")), o = $(() => import("./x-mark-CnZwVvA7.mjs")), i = Vt(), r = y();
2746
+ const t = s, n = V(() => import("./MazBtn-BSnVxud6.mjs")), o = V(() => import("./x-mark-CnZwVvA7.mjs")), i = jt(), r = y();
2718
2747
  e({
2719
2748
  close: () => {
2720
2749
  var l, h;
@@ -2729,7 +2758,7 @@ const Je = "--backdrop-present", an = /* @__PURE__ */ ve({
2729
2758
  class: i.class,
2730
2759
  style: i.style
2731
2760
  }));
2732
- return (l, h) => (L(), V(an, ee({ ...a.value, ...t }, {
2761
+ return (l, h) => (C(), B(cn, ee({ ...a.value, ...t }, {
2733
2762
  ref_key: "backdrop",
2734
2763
  ref: r,
2735
2764
  persistent: l.persistent,
@@ -2737,12 +2766,12 @@ const Je = "--backdrop-present", an = /* @__PURE__ */ ve({
2737
2766
  "transition-name": "modal-anim",
2738
2767
  "aria-labelledby": "dialogTitle",
2739
2768
  "aria-describedby": "dialogDesc",
2740
- onClose: h[0] || (h[0] = (p) => l.$emit("close", p)),
2741
- onOpen: h[1] || (h[1] = (p) => l.$emit("open", p)),
2742
- "onUpdate:modelValue": h[2] || (h[2] = (p) => l.$emit("update:model-value", p))
2769
+ onClose: h[0] || (h[0] = (g) => l.$emit("close", g)),
2770
+ onOpen: h[1] || (h[1] = (g) => l.$emit("open", g)),
2771
+ "onUpdate:modelValue": h[2] || (h[2] = (g) => l.$emit("update:model-value", g))
2743
2772
  }), {
2744
- default: j(({ close: p }) => [
2745
- H(
2773
+ default: U(({ close: g }) => [
2774
+ F(
2746
2775
  "div",
2747
2776
  ee({
2748
2777
  class: ["m-dialog", { "--scrollable": l.scrollable }],
@@ -2751,56 +2780,56 @@ const Je = "--backdrop-present", an = /* @__PURE__ */ ve({
2751
2780
  style: [{ width: l.width, maxWidth: l.maxWidth, maxHeight: l.maxHeight }]
2752
2781
  }, u.value),
2753
2782
  [
2754
- C(`
2783
+ I(`
2755
2784
  @slot Header slot
2756
2785
  @binding {Function} close close function
2757
2786
  `),
2758
- q(l.$slots, "header", { close: p }, () => [
2759
- H(
2787
+ q(l.$slots, "header", { close: g }, () => [
2788
+ F(
2760
2789
  "div",
2761
2790
  {
2762
- class: ue(["m-dialog-header", { "--has-title": l.$slots.title || l.title }])
2791
+ class: le(["m-dialog-header", { "--has-title": l.$slots.title || l.title }])
2763
2792
  },
2764
2793
  [
2765
- l.$slots.title || l.title ? (L(), U("h2", ln, [
2766
- C(`
2794
+ l.$slots.title || l.title ? (C(), _("h2", dn, [
2795
+ I(`
2767
2796
  @slot Title slot in the header
2768
2797
  `),
2769
2798
  q(l.$slots, "title", {}, () => [
2770
2799
  Q(
2771
- Y(l.title),
2800
+ Z(l.title),
2772
2801
  1
2773
2802
  /* TEXT */
2774
2803
  )
2775
2804
  ], !0)
2776
- ])) : C("v-if", !0),
2777
- !l.noClose && !l.persistent ? (L(), V(A(n), {
2805
+ ])) : I("v-if", !0),
2806
+ !l.noClose && !l.persistent ? (C(), B(S(n), {
2778
2807
  key: 1,
2779
2808
  class: "m-dialog-closebtn",
2780
2809
  color: "transparent",
2781
2810
  size: "sm",
2782
- icon: A(o),
2783
- onClick: p
2784
- }, null, 8, ["icon", "onClick"])) : C("v-if", !0)
2811
+ icon: S(o),
2812
+ onClick: g
2813
+ }, null, 8, ["icon", "onClick"])) : I("v-if", !0)
2785
2814
  ],
2786
2815
  2
2787
2816
  /* CLASS */
2788
2817
  )
2789
2818
  ], !0),
2790
- H("div", un, [
2791
- C(`
2819
+ F("div", mn, [
2820
+ I(`
2792
2821
  @slot Default content
2793
2822
  @binding {Function} close close function
2794
2823
  `),
2795
- q(l.$slots, "default", { close: p }, void 0, !0)
2824
+ q(l.$slots, "default", { close: g }, void 0, !0)
2796
2825
  ]),
2797
- l.$slots.footer ? (L(), U("div", cn, [
2798
- C(`
2826
+ l.$slots.footer ? (C(), _("div", fn, [
2827
+ I(`
2799
2828
  @slot Footer slot
2800
2829
  @binding {Function} close close function
2801
2830
  `),
2802
- q(l.$slots, "footer", { close: p }, void 0, !0)
2803
- ])) : C("v-if", !0)
2831
+ q(l.$slots, "footer", { close: g }, void 0, !0)
2832
+ ])) : I("v-if", !0)
2804
2833
  ],
2805
2834
  16
2806
2835
  /* FULL_PROPS */
@@ -2810,7 +2839,7 @@ const Je = "--backdrop-present", an = /* @__PURE__ */ ve({
2810
2839
  /* FORWARDED */
2811
2840
  }, 16, ["persistent", "model-value"]));
2812
2841
  }
2813
- }), mn = /* @__PURE__ */ qe(dn, [["__scopeId", "data-v-50775b17"]]), ie = {
2842
+ }), vn = /* @__PURE__ */ Re(hn, [["__scopeId", "data-v-50775b17"]]), oe = {
2814
2843
  cancelText: "Cancel",
2815
2844
  confirmText: "Confirm",
2816
2845
  cancelButton: {
@@ -2821,11 +2850,11 @@ const Je = "--backdrop-present", an = /* @__PURE__ */ ve({
2821
2850
  text: "Confirm",
2822
2851
  color: "success"
2823
2852
  }
2824
- }, fn = y(ie), re = y([]);
2825
- function hn(s, e) {
2853
+ }, pn = y(oe), ie = y([]);
2854
+ function gn(s, e) {
2826
2855
  return new Promise((t, n) => {
2827
- re.value = [
2828
- ...re.value,
2856
+ ie.value = [
2857
+ ...ie.value,
2829
2858
  {
2830
2859
  id: s,
2831
2860
  isActive: !0,
@@ -2839,26 +2868,26 @@ function hn(s, e) {
2839
2868
  ];
2840
2869
  });
2841
2870
  }
2842
- function It(s) {
2843
- return re.value = re.value.filter(({ id: e }) => e !== s), re.value;
2871
+ function St(s) {
2872
+ return ie.value = ie.value.filter(({ id: e }) => e !== s), ie.value;
2844
2873
  }
2845
- function et(s, e, t) {
2874
+ function st(s, e, t) {
2846
2875
  var n;
2847
2876
  e && ((n = e[s]) == null || n.call(e, t), e.isActive = !1, setTimeout(() => {
2848
- It(e.id);
2877
+ St(e.id);
2849
2878
  }, 500));
2850
2879
  }
2851
- function kt() {
2880
+ function xt() {
2852
2881
  return {
2853
- data: fn,
2854
- dialogState: re,
2855
- showDialogAndWaitChoice: hn,
2856
- removeDialogFromState: It,
2857
- rejectDialog: async (s, e = new Error("cancel"), t) => (await (t == null ? void 0 : t()), et("reject", s, e)),
2858
- resolveDialog: async (s, e = "accept", t) => (await (t == null ? void 0 : t()), et("resolve", s, e))
2882
+ data: pn,
2883
+ dialogState: ie,
2884
+ showDialogAndWaitChoice: gn,
2885
+ removeDialogFromState: St,
2886
+ rejectDialog: async (s, e = new Error("cancel"), t) => (await (t == null ? void 0 : t()), st("reject", s, e)),
2887
+ resolveDialog: async (s, e = "accept", t) => (await (t == null ? void 0 : t()), st("resolve", s, e))
2859
2888
  };
2860
2889
  }
2861
- const vn = { class: "maz-flex maz-items-center maz-gap-2" }, pn = /* @__PURE__ */ ve({
2890
+ const yn = { class: "maz-flex maz-items-center maz-gap-2" }, bn = /* @__PURE__ */ ge({
2862
2891
  __name: "MazDialogPromise",
2863
2892
  props: {
2864
2893
  data: { default: void 0 },
@@ -2886,126 +2915,126 @@ const vn = { class: "maz-flex maz-items-center maz-gap-2" }, pn = /* @__PURE__ *
2886
2915
  },
2887
2916
  emits: ["open", "close"],
2888
2917
  setup(s, { expose: e }) {
2889
- const t = s, n = $(() => import("./MazBtn-CTqI4qhg.mjs")), { dialogState: o, rejectDialog: i, resolveDialog: r, data: a } = kt(), u = f(() => {
2918
+ const t = s, n = V(() => import("./MazBtn-BSnVxud6.mjs")), { dialogState: o, rejectDialog: i, resolveDialog: r, data: a } = xt(), u = f(() => {
2890
2919
  var c;
2891
2920
  return t.buttons ?? ((c = t.data) == null ? void 0 : c.buttons) ?? a.value.buttons;
2892
2921
  }), l = f(() => ({
2893
- ...ie,
2922
+ ...oe,
2894
2923
  ...a.value,
2895
2924
  ...t.data
2896
2925
  })), h = f(() => {
2897
- var k, b, D, O;
2898
- if (!(((k = a.value) == null ? void 0 : k.cancelButton) ?? ((b = t.data) == null ? void 0 : b.cancelButton) ?? ie.cancelButton))
2926
+ var D, v, x, H;
2927
+ if (!(((D = a.value) == null ? void 0 : D.cancelButton) ?? ((v = t.data) == null ? void 0 : v.cancelButton) ?? oe.cancelButton))
2899
2928
  return;
2900
- const g = {
2901
- ...ie.cancelButton,
2902
- ...(D = a.value) == null ? void 0 : D.cancelButton,
2903
- ...(O = t.data) == null ? void 0 : O.cancelButton
2929
+ const b = {
2930
+ ...oe.cancelButton,
2931
+ ...(x = a.value) == null ? void 0 : x.cancelButton,
2932
+ ...(H = t.data) == null ? void 0 : H.cancelButton
2904
2933
  };
2905
2934
  return {
2906
- ...g,
2907
- text: l.value.cancelText || g.text
2935
+ ...b,
2936
+ text: l.value.cancelText || b.text
2908
2937
  };
2909
- }), p = f(() => {
2910
- var k, b, D, O;
2911
- if (!(((k = a.value) == null ? void 0 : k.confirmButton) ?? ((b = t.data) == null ? void 0 : b.confirmButton) ?? ie.confirmButton))
2938
+ }), g = f(() => {
2939
+ var D, v, x, H;
2940
+ if (!(((D = a.value) == null ? void 0 : D.confirmButton) ?? ((v = t.data) == null ? void 0 : v.confirmButton) ?? oe.confirmButton))
2912
2941
  return;
2913
- const g = {
2914
- ...ie.confirmButton,
2915
- ...(D = a.value) == null ? void 0 : D.confirmButton,
2916
- ...(O = t.data) == null ? void 0 : O.confirmButton
2942
+ const b = {
2943
+ ...oe.confirmButton,
2944
+ ...(x = a.value) == null ? void 0 : x.confirmButton,
2945
+ ...(H = t.data) == null ? void 0 : H.confirmButton
2917
2946
  };
2918
2947
  return {
2919
- ...g,
2920
- text: l.value.confirmText || g.text
2948
+ ...b,
2949
+ text: l.value.confirmText || b.text
2921
2950
  };
2922
2951
  }), E = f(
2923
2952
  () => o.value.find(({ id: c }) => c === t.identifier)
2924
2953
  ), T = y();
2925
2954
  e({
2926
2955
  close: () => {
2927
- var c, g;
2928
- return (g = (c = T.value) == null ? void 0 : c.close) == null ? void 0 : g.call(c);
2956
+ var c, b;
2957
+ return (b = (c = T.value) == null ? void 0 : c.close) == null ? void 0 : b.call(c);
2929
2958
  }
2930
2959
  });
2931
- function P(c) {
2960
+ function $(c) {
2932
2961
  return "type" in c && (c.type === "resolve" || c.type === "reject");
2933
2962
  }
2934
- function x(c, g) {
2935
- return P(g) ? g.type === "resolve" ? r(c, g.response) : i(c, g.response) : r(c, void 0, g.action);
2963
+ function k(c, b) {
2964
+ return $(b) ? b.type === "resolve" ? r(c, b.response) : i(c, b.response) : r(c, void 0, b.action);
2936
2965
  }
2937
- return (c, g) => {
2938
- var k;
2939
- return L(), V(mn, ee({
2966
+ return (c, b) => {
2967
+ var D;
2968
+ return C(), B(vn, ee({
2940
2969
  ref_key: "dialog",
2941
2970
  ref: T
2942
2971
  }, { ...c.$attrs, ...t }, {
2943
- "model-value": ((k = E.value) == null ? void 0 : k.isActive) ?? c.modelValue ?? !1,
2944
- onClose: g[2] || (g[2] = (b) => c.$emit("close", b)),
2945
- onOpen: g[3] || (g[3] = (b) => c.$emit("open", b)),
2946
- "onUpdate:modelValue": g[4] || (g[4] = (b) => A(i)(E.value))
2972
+ "model-value": ((D = E.value) == null ? void 0 : D.isActive) ?? c.modelValue ?? !1,
2973
+ onClose: b[2] || (b[2] = (v) => c.$emit("close", v)),
2974
+ onOpen: b[3] || (b[3] = (v) => c.$emit("open", v)),
2975
+ "onUpdate:modelValue": b[4] || (b[4] = (v) => S(i)(E.value))
2947
2976
  }), {
2948
- title: j(() => [
2949
- C(`
2977
+ title: U(() => [
2978
+ I(`
2950
2979
  @slot title slot - Place your title
2951
2980
  `),
2952
2981
  q(c.$slots, "title", {}, () => {
2953
- var b;
2982
+ var v;
2954
2983
  return [
2955
2984
  Q(
2956
- Y(c.title || ((b = l.value) == null ? void 0 : b.title)),
2985
+ Z(c.title || ((v = l.value) == null ? void 0 : v.title)),
2957
2986
  1
2958
2987
  /* TEXT */
2959
2988
  )
2960
2989
  ];
2961
2990
  })
2962
2991
  ]),
2963
- default: j(() => [
2964
- C(`
2992
+ default: U(() => [
2993
+ I(`
2965
2994
  @slot Default slot - Place your content
2966
2995
  @binding {Function} resolve resolve function
2967
2996
  @binding {Function} reject reject function
2968
2997
  `),
2969
2998
  q(c.$slots, "default", {
2970
- resolve: (b) => A(r)(E.value, b),
2971
- reject: (b) => A(i)(E.value, b)
2999
+ resolve: (v) => S(r)(E.value, v),
3000
+ reject: (v) => S(i)(E.value, v)
2972
3001
  }, () => {
2973
- var b;
3002
+ var v;
2974
3003
  return [
2975
3004
  Q(
2976
- Y(c.message || ((b = l.value) == null ? void 0 : b.message)),
3005
+ Z(c.message || ((v = l.value) == null ? void 0 : v.message)),
2977
3006
  1
2978
3007
  /* TEXT */
2979
3008
  )
2980
3009
  ];
2981
3010
  })
2982
3011
  ]),
2983
- footer: j(() => [
2984
- C(`
3012
+ footer: U(() => [
3013
+ I(`
2985
3014
  @slot Footer slot
2986
3015
  @binding {Function} resolve resolve function
2987
3016
  @binding {Function} reject reject function
2988
3017
  `),
2989
3018
  q(c.$slots, "footer-button", {
2990
- resolve: (b) => A(r)(E.value, b),
2991
- reject: (b) => A(i)(E.value, b)
3019
+ resolve: (v) => S(r)(E.value, v),
3020
+ reject: (v) => S(i)(E.value, v)
2992
3021
  }, () => [
2993
- H("div", vn, [
2994
- u.value ? (L(!0), U(
2995
- Re,
3022
+ F("div", yn, [
3023
+ u.value ? (C(!0), _(
3024
+ Ye,
2996
3025
  { key: 0 },
2997
- Bt(u.value, (b, D) => (L(), V(A(n), ee({
2998
- key: D,
3026
+ Ut(u.value, (v, x) => (C(), B(S(n), ee({
3027
+ key: x,
2999
3028
  ref_for: !0
3000
3029
  }, {
3001
- ...b,
3030
+ ...v,
3002
3031
  type: "button"
3003
3032
  }, {
3004
- onClick: (O) => x(E.value, b)
3033
+ onClick: (H) => k(E.value, v)
3005
3034
  }), {
3006
- default: j(() => [
3035
+ default: U(() => [
3007
3036
  Q(
3008
- Y(b.text),
3037
+ Z(v.text),
3009
3038
  1
3010
3039
  /* TEXT */
3011
3040
  )
@@ -3015,23 +3044,23 @@ const vn = { class: "maz-flex maz-items-center maz-gap-2" }, pn = /* @__PURE__ *
3015
3044
  }, 1040, ["onClick"]))),
3016
3045
  128
3017
3046
  /* KEYED_FRAGMENT */
3018
- )) : (L(), U(
3019
- Re,
3047
+ )) : (C(), _(
3048
+ Ye,
3020
3049
  { key: 1 },
3021
3050
  [
3022
- h.value ? (L(), V(
3023
- A(n),
3051
+ h.value ? (C(), B(
3052
+ S(n),
3024
3053
  ee({ key: 0 }, h.value, {
3025
- onClick: g[0] || (g[0] = (b) => A(i)(E.value))
3054
+ onClick: b[0] || (b[0] = (v) => S(i)(E.value))
3026
3055
  }),
3027
3056
  {
3028
- default: j(() => [
3029
- C(`
3057
+ default: U(() => [
3058
+ I(`
3030
3059
  @slot cancel-text slot - Place your cancel text
3031
3060
  `),
3032
3061
  q(c.$slots, "cancel-text", {}, () => [
3033
3062
  Q(
3034
- Y(h.value.text),
3063
+ Z(h.value.text),
3035
3064
  1
3036
3065
  /* TEXT */
3037
3066
  )
@@ -3042,20 +3071,20 @@ const vn = { class: "maz-flex maz-items-center maz-gap-2" }, pn = /* @__PURE__ *
3042
3071
  },
3043
3072
  16
3044
3073
  /* FULL_PROPS */
3045
- )) : C("v-if", !0),
3046
- p.value ? (L(), V(
3047
- A(n),
3048
- ee({ key: 1 }, p.value, {
3049
- onClick: g[1] || (g[1] = (b) => A(r)(E.value))
3074
+ )) : I("v-if", !0),
3075
+ g.value ? (C(), B(
3076
+ S(n),
3077
+ ee({ key: 1 }, g.value, {
3078
+ onClick: b[1] || (b[1] = (v) => S(r)(E.value))
3050
3079
  }),
3051
3080
  {
3052
- default: j(() => [
3053
- C(`
3081
+ default: U(() => [
3082
+ I(`
3054
3083
  @slot confirm-text slot - Place your confirm text
3055
3084
  `),
3056
3085
  q(c.$slots, "confirm-text", {}, () => [
3057
3086
  Q(
3058
- Y(p.value.text),
3087
+ Z(g.value.text),
3059
3088
  1
3060
3089
  /* TEXT */
3061
3090
  )
@@ -3066,7 +3095,7 @@ const vn = { class: "maz-flex maz-items-center maz-gap-2" }, pn = /* @__PURE__ *
3066
3095
  },
3067
3096
  16
3068
3097
  /* FULL_PROPS */
3069
- )) : C("v-if", !0)
3098
+ )) : I("v-if", !0)
3070
3099
  ],
3071
3100
  64
3072
3101
  /* STABLE_FRAGMENT */
@@ -3079,22 +3108,22 @@ const vn = { class: "maz-flex maz-items-center maz-gap-2" }, pn = /* @__PURE__ *
3079
3108
  }, 16, ["model-value"]);
3080
3109
  };
3081
3110
  }
3082
- }), tt = {
3111
+ }), nt = {
3083
3112
  identifier: "main-dialog"
3084
3113
  };
3085
- class gn {
3086
- constructor(e, t = tt) {
3114
+ class wn {
3115
+ constructor(e, t = nt) {
3087
3116
  this.app = e, this.globalOptions = t;
3088
3117
  }
3089
3118
  open(e) {
3090
3119
  const t = {
3091
- ...tt,
3120
+ ...nt,
3092
3121
  ...this.globalOptions,
3093
3122
  ...e
3094
- }, { destroy: n, vNode: o } = _e(pn, {
3123
+ }, { destroy: n, vNode: o } = We(bn, {
3095
3124
  props: t,
3096
3125
  app: this.app
3097
- }), { showDialogAndWaitChoice: i } = kt();
3126
+ }), { showDialogAndWaitChoice: i } = xt();
3098
3127
  function r() {
3099
3128
  var u, l, h;
3100
3129
  (l = (u = o.component) == null ? void 0 : u.exposed) == null || l.close(), (h = t.promiseCallback) == null || h.call(t), setTimeout(() => {
@@ -3110,14 +3139,14 @@ class gn {
3110
3139
  };
3111
3140
  }
3112
3141
  }
3113
- const lo = {
3142
+ const mo = {
3114
3143
  install(s, e) {
3115
- s.provide("dialog", new gn(s, e));
3144
+ s.provide("dialog", new wn(s, e));
3116
3145
  }
3117
- }, yn = { class: "m-toast__message-wrapper" }, bn = { class: "m-toast__message" }, wn = { class: "maz-flex maz-items-center maz-gap-2" }, En = { key: 0 }, zn = {
3146
+ }, En = { class: "m-toast__message-wrapper" }, Tn = { class: "m-toast__message" }, Ln = { class: "maz-flex maz-items-center maz-gap-2" }, zn = { key: 0 }, Cn = {
3118
3147
  key: 4,
3119
3148
  class: "progress-bar maz-absolute maz-inset-x-0 maz-bottom-0 maz-h-1"
3120
- }, Tn = /* @__PURE__ */ ve({
3149
+ }, In = /* @__PURE__ */ ge({
3121
3150
  __name: "MazToast",
3122
3151
  props: {
3123
3152
  message: { default: void 0 },
@@ -3134,15 +3163,15 @@ const lo = {
3134
3163
  },
3135
3164
  emits: ["close", "click", "open"],
3136
3165
  setup(s, { expose: e, emit: t }) {
3137
- const n = s, o = t, i = $(() => import("./MazBtn-CTqI4qhg.mjs")), r = $(() => import("./x-mark-CnZwVvA7.mjs")), a = $(
3166
+ const n = s, o = t, i = V(() => import("./MazBtn-BSnVxud6.mjs")), r = V(() => import("./x-mark-CnZwVvA7.mjs")), a = V(
3138
3167
  () => import("./arrow-top-right-on-square-jPmYJ34F.mjs")
3139
- ), u = $(
3168
+ ), u = V(
3140
3169
  () => import("./exclamation-triangle-Z6d0ygp8.mjs")
3141
- ), l = $(
3170
+ ), l = V(
3142
3171
  () => import("./exclamation-circle-CUk0ZajS.mjs")
3143
- ), h = $(
3172
+ ), h = V(
3144
3173
  () => import("./information-circle-C7e5b_nL.mjs")
3145
- ), p = $(() => import("./check-circle-Bf7AGSQ-.mjs")), E = $(() => import("./link-Br1lfjTR.mjs")), T = y(), P = f(() => {
3174
+ ), g = V(() => import("./check-circle-Bf7AGSQ-.mjs")), E = V(() => import("./link-Br1lfjTR.mjs")), T = y(), $ = f(() => {
3146
3175
  if (n.icon)
3147
3176
  switch (n.type) {
3148
3177
  case "danger":
@@ -3150,38 +3179,38 @@ const lo = {
3150
3179
  case "info":
3151
3180
  return h;
3152
3181
  case "success":
3153
- return p;
3182
+ return g;
3154
3183
  case "warning":
3155
3184
  return l;
3156
3185
  default:
3157
3186
  return;
3158
3187
  }
3159
- }), x = f(() => n.position.includes("top") ? "top" : "bottom"), c = f(() => n.position.includes("left") ? "left" : n.position.includes("right") ? "right" : "center"), g = f(() => c.value !== "center" ? c.value === "right" ? "m-slide-right" : "m-slide-left" : x.value === "top" ? "m-slide-top" : "m-slide-bottom"), k = y(!1), b = y(!1), D = y(), O = `m-toast-container --${x.value} --${c.value}`, z = `.${O.replaceAll(" ", ".")}`, B = zs({
3188
+ }), k = f(() => n.position.includes("top") ? "top" : "bottom"), c = f(() => n.position.includes("left") ? "left" : n.position.includes("right") ? "right" : "center"), b = f(() => c.value !== "center" ? c.value === "right" ? "m-slide-right" : "m-slide-left" : k.value === "top" ? "m-slide-top" : "m-slide-bottom"), D = y(!1), v = y(!1), x = y(), H = `m-toast-container --${k.value} --${c.value}`, L = `.${H.replaceAll(" ", ".")}`, P = Cs({
3160
3189
  callback: ne,
3161
3190
  timeout: typeof n.timeout == "number" ? n.timeout : 0,
3162
3191
  callbackOffsetTime: 200
3163
3192
  });
3164
- function _() {
3165
- const v = document.querySelector(z);
3166
- if (!v && !v) {
3167
- const I = document.body, m = document.createElement("div");
3168
- m.className = O, I.append(m);
3193
+ function j() {
3194
+ const m = document.querySelector(L);
3195
+ if (!m && !m) {
3196
+ const A = document.body, O = document.createElement("div");
3197
+ O.className = H, A.append(O);
3169
3198
  }
3170
3199
  }
3171
- function X() {
3172
- const v = document.querySelector(z);
3173
- return !n.queue && n.maxToasts === !1 ? !1 : typeof n.maxToasts == "number" && v ? n.maxToasts <= v.childElementCount : v && v.childElementCount > 0;
3200
+ function se() {
3201
+ const m = document.querySelector(L);
3202
+ return !n.queue && n.maxToasts === !1 ? !1 : typeof n.maxToasts == "number" && m ? n.maxToasts <= m.childElementCount : m && m.childElementCount > 0;
3174
3203
  }
3175
3204
  function G() {
3176
- if (X()) {
3177
- D.value = setTimeout(G, 250);
3205
+ if (se()) {
3206
+ x.value = setTimeout(G, 250);
3178
3207
  return;
3179
3208
  }
3180
- const v = document.querySelector(z);
3181
- T.value && v && v.prepend(T.value), b.value = !0, typeof n.timeout == "number" && n.timeout > 0 && B.start();
3209
+ const m = document.querySelector(L);
3210
+ T.value && m && m.prepend(T.value), v.value = !0, typeof n.timeout == "number" && n.timeout > 0 && P.start();
3182
3211
  }
3183
- const Ee = y("100%");
3184
- function de() {
3212
+ const ce = y("100%");
3213
+ function De() {
3185
3214
  switch (n.type) {
3186
3215
  case "danger":
3187
3216
  return "maz-bg-danger-700";
@@ -3192,129 +3221,129 @@ const lo = {
3192
3221
  case "warning":
3193
3222
  return "maz-bg-warning-700";
3194
3223
  default:
3195
- return "maz-bg-secondary";
3224
+ return "maz-bg-primary";
3196
3225
  }
3197
3226
  }
3198
- Z(
3199
- B.remainingTime,
3200
- (v) => {
3227
+ X(
3228
+ P.remainingTime,
3229
+ (m) => {
3201
3230
  if (typeof n.timeout == "number") {
3202
- const I = 100 * v / n.timeout;
3203
- Ee.value = `${I}%`;
3231
+ const A = 100 * m / n.timeout;
3232
+ ce.value = `${A}%`;
3204
3233
  }
3205
3234
  }
3206
3235
  );
3207
- function se(v) {
3208
- o("click", v), n.persistent || ne();
3236
+ function de(m) {
3237
+ o("click", m), n.persistent || ne();
3209
3238
  }
3210
- async function xe(v, I) {
3211
- var m;
3212
- k.value = !0, await v(), k.value = !1, (m = n.action) != null && m.closeToast && se(I);
3239
+ async function me(m, A) {
3240
+ var O;
3241
+ D.value = !0, await m(), D.value = !1, (O = n.action) != null && O.closeToast && de(A);
3213
3242
  }
3214
- function me(v) {
3215
- n.noPauseOnHover || (v ? B.pause() : B.resume());
3243
+ function fe(m) {
3244
+ n.noPauseOnHover || (m ? P.pause() : P.resume());
3216
3245
  }
3217
- function ze() {
3218
- B.stop(), D.value && clearTimeout(D.value);
3246
+ function Pe() {
3247
+ P.stop(), x.value && clearTimeout(x.value);
3219
3248
  }
3220
3249
  function ne() {
3221
- ze(), b.value = !1;
3250
+ Pe(), v.value = !1;
3222
3251
  }
3223
3252
  e({ closeToast: ne });
3224
- function oe() {
3253
+ function Le() {
3225
3254
  o("open");
3226
3255
  }
3227
- function Oe() {
3228
- var I;
3229
- o("close"), (I = T.value) == null || I.remove();
3230
- const v = document.querySelector(z);
3231
- v && !(v != null && v.hasChildNodes()) && v.remove();
3256
+ function ze() {
3257
+ var A;
3258
+ o("close"), (A = T.value) == null || A.remove();
3259
+ const m = document.querySelector(L);
3260
+ m && !(m != null && m.hasChildNodes()) && m.remove();
3232
3261
  }
3233
- return ce(() => {
3234
- _(), G();
3235
- }), (v, I) => (L(), V(at, {
3236
- name: g.value,
3237
- onAfterLeave: Oe,
3238
- onAfterEnter: oe,
3262
+ return ue(() => {
3263
+ j(), G();
3264
+ }), (m, A) => (C(), B(ut, {
3265
+ name: b.value,
3266
+ onAfterLeave: ze,
3267
+ onAfterEnter: Le,
3239
3268
  persisted: ""
3240
3269
  }, {
3241
- default: j(() => [
3242
- it(H(
3270
+ default: U(() => [
3271
+ at(F(
3243
3272
  "button",
3244
3273
  {
3245
3274
  ref_key: "Toaster",
3246
3275
  ref: T,
3247
- class: ue(["m-toast", [
3248
- `--${v.type}`,
3249
- `--${x.value}`,
3276
+ class: le(["m-toast", [
3277
+ `--${m.type}`,
3278
+ `--${k.value}`,
3250
3279
  `--${c.value}`,
3251
- { "maz-pb-1": typeof v.timeout == "number" && v.timeout > 0, "--persistent": v.persistent }
3280
+ { "maz-pb-1": typeof m.timeout == "number" && m.timeout > 0, "--persistent": m.persistent }
3252
3281
  ]]),
3253
3282
  role: "alert",
3254
- onMouseover: I[2] || (I[2] = (m) => me(!0)),
3255
- onMouseleave: I[3] || (I[3] = (m) => me(!1)),
3256
- onClick: I[4] || (I[4] = K((m) => {
3257
- var w;
3258
- return v.link && !((w = v.link) != null && w.closeToast) ? void 0 : se(m);
3283
+ onMouseover: A[2] || (A[2] = (O) => fe(!0)),
3284
+ onMouseleave: A[3] || (A[3] = (O) => fe(!1)),
3285
+ onClick: A[4] || (A[4] = Y((O) => {
3286
+ var he;
3287
+ return m.link && !((he = m.link) != null && he.closeToast) ? void 0 : de(O);
3259
3288
  }, ["stop"]))
3260
3289
  },
3261
3290
  [
3262
- P.value ? (L(), V(Ft(P.value), {
3291
+ $.value ? (C(), B(_t($.value), {
3263
3292
  key: 0,
3264
3293
  class: "maz-text-2xl"
3265
- })) : C("v-if", !0),
3266
- H("div", yn, [
3267
- H(
3294
+ })) : I("v-if", !0),
3295
+ F("div", En, [
3296
+ F(
3268
3297
  "p",
3269
- bn,
3270
- Y(v.message),
3298
+ Tn,
3299
+ Z(m.message),
3271
3300
  1
3272
3301
  /* TEXT */
3273
3302
  )
3274
3303
  ]),
3275
- v.action ? (L(), V(A(i), {
3304
+ m.action ? (C(), B(S(i), {
3276
3305
  key: 1,
3277
3306
  "data-test": "action-btn",
3278
- color: v.type,
3307
+ color: m.type,
3279
3308
  pastel: "",
3280
- loading: k.value,
3309
+ loading: D.value,
3281
3310
  size: "sm",
3282
- onClick: I[0] || (I[0] = K((m) => v.action ? xe(v.action.func, m) : void 0, ["stop"]))
3311
+ onClick: A[0] || (A[0] = Y((O) => m.action ? me(m.action.func, O) : void 0, ["stop"]))
3283
3312
  }, {
3284
- default: j(() => [
3313
+ default: U(() => [
3285
3314
  Q(
3286
- Y(v.action.text),
3315
+ Z(m.action.text),
3287
3316
  1
3288
3317
  /* TEXT */
3289
3318
  )
3290
3319
  ]),
3291
3320
  _: 1
3292
3321
  /* STABLE */
3293
- }, 8, ["color", "loading"])) : C("v-if", !0),
3294
- v.link ? (L(), V(A(i), {
3322
+ }, 8, ["color", "loading"])) : I("v-if", !0),
3323
+ m.link ? (C(), B(S(i), {
3295
3324
  key: 2,
3296
3325
  "data-test": "link-btn",
3297
- color: v.type,
3326
+ color: m.type,
3298
3327
  pastel: "",
3299
3328
  size: "xs",
3300
- href: v.link.href,
3301
- target: v.link.target ?? "_self"
3329
+ href: m.link.href,
3330
+ target: m.link.target ?? "_self"
3302
3331
  }, {
3303
- default: j(() => {
3304
- var m;
3332
+ default: U(() => {
3333
+ var O;
3305
3334
  return [
3306
- H("div", wn, [
3307
- v.link.text ? (L(), U(
3335
+ F("div", Ln, [
3336
+ m.link.text ? (C(), _(
3308
3337
  "span",
3309
- En,
3310
- Y(v.link.text),
3338
+ zn,
3339
+ Z(m.link.text),
3311
3340
  1
3312
3341
  /* TEXT */
3313
- )) : C("v-if", !0),
3314
- ((m = v.link) == null ? void 0 : m.target) === "_blank" ? (L(), V(A(a), {
3342
+ )) : I("v-if", !0),
3343
+ ((O = m.link) == null ? void 0 : O.target) === "_blank" ? (C(), B(S(a), {
3315
3344
  key: 1,
3316
3345
  class: "maz-text-xl"
3317
- })) : (L(), V(A(E), {
3346
+ })) : (C(), B(S(E), {
3318
3347
  key: 2,
3319
3348
  class: "maz-text-xl"
3320
3349
  }))
@@ -3323,56 +3352,56 @@ const lo = {
3323
3352
  }),
3324
3353
  _: 1
3325
3354
  /* STABLE */
3326
- }, 8, ["color", "href", "target"])) : C("v-if", !0),
3327
- v.persistent ? C("v-if", !0) : (L(), U("button", {
3355
+ }, 8, ["color", "href", "target"])) : I("v-if", !0),
3356
+ m.persistent ? I("v-if", !0) : (C(), _("button", {
3328
3357
  key: 3,
3329
3358
  class: "--close",
3330
- onClick: I[1] || (I[1] = K((m) => se(m), ["stop"]))
3359
+ onClick: A[1] || (A[1] = Y((O) => de(O), ["stop"]))
3331
3360
  }, [
3332
- J(A(r), { class: "--icon maz-text-xl" })
3361
+ J(S(r), { class: "--icon maz-text-xl" })
3333
3362
  ])),
3334
- typeof v.timeout == "number" && v.timeout > 0 ? (L(), U("div", zn, [
3335
- H(
3363
+ typeof m.timeout == "number" && m.timeout > 0 ? (C(), _("div", Cn, [
3364
+ F(
3336
3365
  "div",
3337
3366
  {
3338
- style: Nt({
3339
- width: Ee.value
3367
+ style: qt({
3368
+ width: ce.value
3340
3369
  }),
3341
- class: ue(["maz-h-full !maz-transition-all !maz-duration-200 !maz-ease-linear", de()])
3370
+ class: le(["maz-h-full !maz-transition-all !maz-duration-200 !maz-ease-linear", De()])
3342
3371
  },
3343
3372
  null,
3344
3373
  6
3345
3374
  /* CLASS, STYLE */
3346
3375
  )
3347
- ])) : C("v-if", !0)
3376
+ ])) : I("v-if", !0)
3348
3377
  ],
3349
3378
  34
3350
3379
  /* CLASS, NEED_HYDRATION */
3351
3380
  ), [
3352
- [rt, b.value]
3381
+ [lt, v.value]
3353
3382
  ])
3354
3383
  ]),
3355
3384
  _: 1
3356
3385
  /* STABLE */
3357
3386
  }, 8, ["name"]));
3358
3387
  }
3359
- }), Ln = /* @__PURE__ */ qe(Tn, [["__scopeId", "data-v-309639e4"]]), Cn = {
3388
+ }), kn = /* @__PURE__ */ Re(In, [["__scopeId", "data-v-c8684398"]]), An = {
3360
3389
  position: "bottom-right",
3361
3390
  timeout: 1e4,
3362
3391
  persistent: !1,
3363
3392
  icon: !0
3364
3393
  };
3365
- class In {
3394
+ class Sn {
3366
3395
  constructor(e, t) {
3367
3396
  this.app = e, this.globalOptions = t;
3368
3397
  }
3369
3398
  show(e, t) {
3370
3399
  const n = {
3371
- ...Cn,
3400
+ ...An,
3372
3401
  ...this.globalOptions,
3373
3402
  ...t,
3374
3403
  message: e
3375
- }, { destroy: o, vNode: i } = _e(Ln, {
3404
+ }, { destroy: o, vNode: i } = We(kn, {
3376
3405
  props: n,
3377
3406
  app: this.app
3378
3407
  });
@@ -3406,112 +3435,112 @@ class In {
3406
3435
  return this.show(e, this.getLocalOptions("warning", t));
3407
3436
  }
3408
3437
  }
3409
- function kn(s, e) {
3410
- return new In(s, e);
3438
+ function xn(s, e) {
3439
+ return new Sn(s, e);
3411
3440
  }
3412
- const uo = {
3441
+ const fo = {
3413
3442
  install(s, e) {
3414
- s.provide("toast", kn(s, e));
3443
+ s.provide("toast", xn(s, e));
3415
3444
  }
3416
- }, ae = "";
3417
- function An(s) {
3445
+ }, re = "";
3446
+ function On(s) {
3418
3447
  return s.filter((e, t, n) => t === n.indexOf(e));
3419
3448
  }
3420
- function Sn(s) {
3421
- return (e = ae) => typeof e == "function" ? s.findIndex((...t) => e(...t)) > -1 : s.includes(e);
3449
+ function Dn(s) {
3450
+ return (e = re) => typeof e == "function" ? s.findIndex((...t) => e(...t)) > -1 : s.includes(e);
3422
3451
  }
3423
- const xn = (s) => s.length > 0;
3424
- function On(s) {
3425
- return (e = ae) => An([...s, e]);
3452
+ const Pn = (s) => s.length > 0;
3453
+ function Mn(s) {
3454
+ return (e = re) => On([...s, e]);
3426
3455
  }
3427
- function Dn(s) {
3428
- return (e = ae) => s.filter((t) => t !== e);
3456
+ function $n(s) {
3457
+ return (e = re) => s.filter((t) => t !== e);
3429
3458
  }
3430
- class Mn {
3459
+ class Hn {
3431
3460
  constructor() {
3432
3461
  d(this, "_loaders", y([]));
3433
3462
  }
3434
3463
  get loaders() {
3435
3464
  return f(() => this._loaders.value);
3436
3465
  }
3437
- stop(e = ae) {
3438
- this._loaders.value = Dn(this._loaders.value)(e);
3466
+ stop(e = re) {
3467
+ this._loaders.value = $n(this._loaders.value)(e);
3439
3468
  }
3440
- start(e = ae) {
3441
- return this._loaders.value = On(this._loaders.value)(e), () => this.stop(e);
3469
+ start(e = re) {
3470
+ return this._loaders.value = Mn(this._loaders.value)(e), () => this.stop(e);
3442
3471
  }
3443
3472
  get anyLoading() {
3444
- return f(() => xn(this._loaders.value));
3473
+ return f(() => Pn(this._loaders.value));
3445
3474
  }
3446
- isLoading(e = ae) {
3447
- return f(() => Sn(this._loaders.value)(e)).value;
3475
+ isLoading(e = re) {
3476
+ return f(() => Dn(this._loaders.value)(e)).value;
3448
3477
  }
3449
3478
  }
3450
- const Pn = new Mn(), co = {
3479
+ const Vn = new Hn(), ho = {
3451
3480
  install: (s) => {
3452
- s.provide("wait", Pn);
3481
+ s.provide("wait", Vn);
3453
3482
  }
3454
3483
  };
3455
3484
  export {
3456
- ro as $,
3457
- Fs as A,
3458
- Bs as B,
3459
- js as C,
3460
- Jn as D,
3461
- Ws as E,
3462
- qs as F,
3463
- to as G,
3464
- Ks as H,
3465
- Gs as I,
3466
- Js as J,
3467
- tn as K,
3468
- _t as L,
3485
+ uo as $,
3486
+ qs as A,
3487
+ _s as B,
3488
+ Rs as C,
3489
+ ro as D,
3490
+ Xs as E,
3491
+ Zs as F,
3492
+ lo as G,
3493
+ Qs as H,
3494
+ sn as I,
3495
+ on as J,
3496
+ an as K,
3497
+ ct as L,
3469
3498
  so as M,
3470
3499
  no as N,
3471
- us as O,
3472
- F as P,
3473
- _e as Q,
3474
- Ze as R,
3500
+ ms as O,
3501
+ N as P,
3502
+ We as Q,
3503
+ Ge as R,
3475
3504
  oo as S,
3476
- on as T,
3477
- bs as U,
3505
+ Hs as T,
3506
+ Ts as U,
3478
3507
  io as V,
3479
- nn as W,
3480
- Ts as X,
3481
- rn as Y,
3482
- ao as Z,
3483
- qe as _,
3484
- Bn as a,
3485
- gn as a0,
3486
- lo as a1,
3487
- uo as a2,
3488
- In as a3,
3489
- Pn as a4,
3490
- co as a5,
3491
- Mn as a6,
3492
- Fn as b,
3493
- Nn as c,
3494
- jn as d,
3495
- Un as e,
3496
- _n as f,
3497
- cs as g,
3498
- qn as h,
3499
- Se as i,
3500
- Wn as j,
3501
- Rn as k,
3502
- Kn as l,
3503
- Yn as m,
3504
- zs as n,
3505
- Zn as o,
3506
- Xn as p,
3507
- Gn as q,
3508
- Ut as r,
3509
- eo as s,
3510
- Cs as t,
3511
- Vn as u,
3512
- Is as v,
3513
- Ss as w,
3514
- xs as x,
3515
- Qn as y,
3516
- Os as z
3508
+ $s as W,
3509
+ Is as X,
3510
+ un as Y,
3511
+ co as Z,
3512
+ Re as _,
3513
+ jn as a,
3514
+ wn as a0,
3515
+ mo as a1,
3516
+ fo as a2,
3517
+ Sn as a3,
3518
+ Vn as a4,
3519
+ ho as a5,
3520
+ Hn as a6,
3521
+ Un as b,
3522
+ _n as c,
3523
+ qn as d,
3524
+ Wn as e,
3525
+ Rn as f,
3526
+ fs as g,
3527
+ Kn as h,
3528
+ Oe as i,
3529
+ Yn as j,
3530
+ Zn as k,
3531
+ Xn as l,
3532
+ Gn as m,
3533
+ Cs as n,
3534
+ Qn as o,
3535
+ Jn as p,
3536
+ eo as q,
3537
+ Rt as r,
3538
+ ao as s,
3539
+ As as t,
3540
+ Nn as u,
3541
+ Ss as v,
3542
+ Ds as w,
3543
+ Ps as x,
3544
+ to as y,
3545
+ Ms as z
3517
3546
  };