directix 1.9.0 → 1.10.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.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * directix v1.9.0
2
+ * directix v1.10.0
3
3
  * A comprehensive, easy-to-use, and high-performance Vue custom directives library supporting both Vue 2 and Vue 3
4
4
  * (c) 2021-present saqqdy <https://github.com/saqqdy>
5
5
  * Released under the MIT License.
@@ -58,7 +58,7 @@ var __async = (__this, __arguments, generator) => {
58
58
  });
59
59
  };
60
60
  /*!
61
- * directix v1.9.0
61
+ * directix v1.10.0
62
62
  * A comprehensive, easy-to-use, and high-performance Vue custom directives library supporting both Vue 2 and Vue 3
63
63
  * (c) 2021-present saqqdy <https://github.com/saqqdy>
64
64
  * Released under the MIT License.
@@ -202,7 +202,7 @@ var __async = (__this, __arguments, generator) => {
202
202
  return null;
203
203
  }
204
204
  function getVueVersion() {
205
- var _a2, _b;
205
+ var _a2, _b2;
206
206
  if (_vueVersion !== null) return _vueVersion;
207
207
  if (typeof process !== "undefined") {
208
208
  const envVersion = process.env.DIRECTIX_VUE_VERSION;
@@ -254,7 +254,7 @@ var __async = (__this, __arguments, generator) => {
254
254
  return _vueVersion;
255
255
  }
256
256
  }
257
- if ((_b = devtools == null ? void 0 : devtools.apps) == null ? void 0 : _b.length) {
257
+ if ((_b2 = devtools == null ? void 0 : devtools.apps) == null ? void 0 : _b2.length) {
258
258
  _vueVersion = 3;
259
259
  return _vueVersion;
260
260
  }
@@ -334,10 +334,10 @@ var __async = (__this, __arguments, generator) => {
334
334
  return isBrowser() && "MutationObserver" in window;
335
335
  };
336
336
  function defineDirective(definition) {
337
- var _b;
337
+ var _b2;
338
338
  const _a2 = definition, { name, version, ssr, defaults } = _a2, hooks = __objRest(_a2, ["name", "version", "ssr", "defaults"]);
339
339
  if (isSSR() && !ssr) {
340
- if (typeof process !== "undefined" && ((_b = process.env) == null ? void 0 : _b.NODE_ENV) !== "test") {
340
+ if (typeof process !== "undefined" && ((_b2 = process.env) == null ? void 0 : _b2.NODE_ENV) !== "test") {
341
341
  console.warn(
342
342
  `[Directix] Directive "${name}" is not compatible with SSR. It will be a no-op on the server side.`
343
343
  );
@@ -365,8 +365,8 @@ var __async = (__this, __arguments, generator) => {
365
365
  }
366
366
  function createHook(hookName) {
367
367
  return function(el, binding, vnode, prevVnode) {
368
- var _a2, _b;
369
- (_b = (_a2 = getDirective())[hookName]) == null ? void 0 : _b.call(_a2, el, binding, vnode, prevVnode);
368
+ var _a2, _b2;
369
+ (_b2 = (_a2 = getDirective())[hookName]) == null ? void 0 : _b2.call(_a2, el, binding, vnode, prevVnode);
370
370
  };
371
371
  }
372
372
  return {
@@ -1549,7 +1549,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
1549
1549
  return word.charAt(0).toUpperCase() + word.slice(1).toLowerCase();
1550
1550
  }
1551
1551
  function normalizeOptions$Q(binding) {
1552
- var _a2, _b, _c;
1552
+ var _a2, _b2, _c;
1553
1553
  if (binding === void 0 || binding === true) {
1554
1554
  return { every: true, onInput: true };
1555
1555
  }
@@ -1558,7 +1558,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
1558
1558
  }
1559
1559
  return {
1560
1560
  every: (_a2 = binding.every) != null ? _a2 : true,
1561
- keepLower: (_b = binding.keepLower) != null ? _b : DEFAULT_KEEP_LOWER$1,
1561
+ keepLower: (_b2 = binding.keepLower) != null ? _b2 : DEFAULT_KEEP_LOWER$1,
1562
1562
  onInput: (_c = binding.onInput) != null ? _c : true
1563
1563
  };
1564
1564
  }
@@ -1617,7 +1617,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
1617
1617
  };
1618
1618
  }
1619
1619
  function normalizeOptions$P(binding, directiveBinding) {
1620
- var _a2, _b, _c, _d;
1620
+ var _a2, _b2, _c, _d;
1621
1621
  const delay = parseTime(directiveBinding.arg) || 300;
1622
1622
  if (typeof binding === "function") {
1623
1623
  return {
@@ -1634,7 +1634,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
1634
1634
  return {
1635
1635
  handler: binding.handler,
1636
1636
  delay: (_a2 = binding.delay) != null ? _a2 : delay,
1637
- disabled: (_b = binding.disabled) != null ? _b : false,
1637
+ disabled: (_b2 = binding.disabled) != null ? _b2 : false,
1638
1638
  pendingClass: (_c = binding.pendingClass) != null ? _c : "v-click-delay--pending",
1639
1639
  feedback: (_d = binding.feedback) != null ? _d : true
1640
1640
  };
@@ -1792,7 +1792,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
1792
1792
  }
1793
1793
  });
1794
1794
  function normalizeOptions$O(binding) {
1795
- var _a2, _b, _c, _d, _e;
1795
+ var _a2, _b2, _c, _d, _e;
1796
1796
  if (typeof binding === "function") {
1797
1797
  return {
1798
1798
  handler: binding,
@@ -1808,7 +1808,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
1808
1808
  }
1809
1809
  return __spreadValues({
1810
1810
  capture: (_a2 = binding.capture) != null ? _a2 : true,
1811
- events: (_b = binding.events) != null ? _b : ["click"],
1811
+ events: (_b2 = binding.events) != null ? _b2 : ["click"],
1812
1812
  disabled: (_c = binding.disabled) != null ? _c : false,
1813
1813
  stop: (_d = binding.stop) != null ? _d : false,
1814
1814
  prevent: (_e = binding.prevent) != null ? _e : false
@@ -2042,7 +2042,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2042
2042
  const state2 = {
2043
2043
  options,
2044
2044
  contextMenuHandler: (e) => {
2045
- var _a2, _b;
2045
+ var _a2, _b2;
2046
2046
  e.preventDefault();
2047
2047
  if (state2.menuElement) {
2048
2048
  removeMenu(state2.menuElement);
@@ -2056,7 +2056,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2056
2056
  setTimeout(() => {
2057
2057
  document.addEventListener("click", state2.clickOutsideHandler);
2058
2058
  }, 0);
2059
- (_b = options.onAfterShow) == null ? void 0 : _b.call(options);
2059
+ (_b2 = options.onAfterShow) == null ? void 0 : _b2.call(options);
2060
2060
  },
2061
2061
  menuElement: null,
2062
2062
  clickOutsideHandler: (e) => {
@@ -2138,7 +2138,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2138
2138
  options
2139
2139
  };
2140
2140
  state2.handler = () => __async(null, null, function* () {
2141
- var _a2, _b, _c, _d;
2141
+ var _a2, _b2, _c, _d;
2142
2142
  const text = state2.options.value;
2143
2143
  if (!text) {
2144
2144
  console.warn("[Directix] v-copy: No text to copy");
@@ -2147,7 +2147,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2147
2147
  try {
2148
2148
  const success = yield copyToClipboard$1(text);
2149
2149
  if (success) {
2150
- (_b = (_a2 = state2.options).onSuccess) == null ? void 0 : _b.call(_a2, text);
2150
+ (_b2 = (_a2 = state2.options).onSuccess) == null ? void 0 : _b2.call(_a2, text);
2151
2151
  el.dispatchEvent(new CustomEvent("copy:success", { detail: { text } }));
2152
2152
  } else {
2153
2153
  throw new Error("Copy failed");
@@ -2211,14 +2211,14 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2211
2211
  return result;
2212
2212
  }
2213
2213
  function normalizeOptions$K(binding) {
2214
- var _a2, _b, _c, _d;
2214
+ var _a2, _b2, _c, _d;
2215
2215
  if (typeof binding === "object" && binding !== null && "target" in binding) {
2216
2216
  return {
2217
2217
  target: binding.target,
2218
2218
  format: (_a2 = binding.format) != null ? _a2 : "hh:mm:ss",
2219
2219
  onComplete: binding.onComplete,
2220
2220
  onTick: binding.onTick,
2221
- interval: (_b = binding.interval) != null ? _b : 1e3,
2221
+ interval: (_b2 = binding.interval) != null ? _b2 : 1e3,
2222
2222
  showMilliseconds: (_c = binding.showMilliseconds) != null ? _c : false,
2223
2223
  autoStart: (_d = binding.autoStart) != null ? _d : true,
2224
2224
  labels: binding.labels
@@ -2400,7 +2400,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2400
2400
  state2.startTime = null;
2401
2401
  (_a2 = options.onStart) == null ? void 0 : _a2.call(options);
2402
2402
  function animate2(timestamp) {
2403
- var _a3, _b;
2403
+ var _a3, _b2;
2404
2404
  if (!state2.startTime) {
2405
2405
  state2.startTime = timestamp;
2406
2406
  }
@@ -2418,7 +2418,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2418
2418
  state2.currentValue = endValue;
2419
2419
  el.textContent = formatNumber$3(endValue, options);
2420
2420
  state2.animationFrame = null;
2421
- (_b = options.onComplete) == null ? void 0 : _b.call(options, endValue);
2421
+ (_b2 = options.onComplete) == null ? void 0 : _b2.call(options, endValue);
2422
2422
  }
2423
2423
  }
2424
2424
  state2.animationFrame = requestAnimationFrame(animate2);
@@ -2483,7 +2483,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2483
2483
  }
2484
2484
  });
2485
2485
  function getBoundary$1(_el, boundary) {
2486
- var _a2, _b;
2486
+ var _a2, _b2;
2487
2487
  if (!boundary) return null;
2488
2488
  if (typeof boundary === "function") {
2489
2489
  const boundaryEl = boundary();
@@ -2491,7 +2491,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2491
2491
  }
2492
2492
  if (typeof boundary === "string") {
2493
2493
  const boundaryEl = document.querySelector(boundary);
2494
- return (_b = boundaryEl == null ? void 0 : boundaryEl.getBoundingClientRect()) != null ? _b : null;
2494
+ return (_b2 = boundaryEl == null ? void 0 : boundaryEl.getBoundingClientRect()) != null ? _b2 : null;
2495
2495
  }
2496
2496
  return boundary.getBoundingClientRect();
2497
2497
  }
@@ -2511,7 +2511,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2511
2511
  return { x: 0, y: 0 };
2512
2512
  }
2513
2513
  function normalizeOptions$H(binding) {
2514
- var _a2, _b, _c;
2514
+ var _a2, _b2, _c;
2515
2515
  if (binding === void 0 || binding === true) {
2516
2516
  return { axis: "both", constrain: false, disabled: false };
2517
2517
  }
@@ -2520,7 +2520,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2520
2520
  }
2521
2521
  return {
2522
2522
  axis: (_a2 = binding.axis) != null ? _a2 : "both",
2523
- constrain: (_b = binding.constrain) != null ? _b : false,
2523
+ constrain: (_b2 = binding.constrain) != null ? _b2 : false,
2524
2524
  boundary: binding.boundary,
2525
2525
  handle: binding.handle,
2526
2526
  disabled: (_c = binding.disabled) != null ? _c : false,
@@ -2561,7 +2561,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2561
2561
  targetEl.addEventListener("mousedown", startDrag);
2562
2562
  targetEl.addEventListener("touchstart", startDrag, { passive: false });
2563
2563
  function startDrag(e) {
2564
- var _a2, _b, _c;
2564
+ var _a2, _b2, _c;
2565
2565
  if (state2.options.disabled) return;
2566
2566
  if (e.type === "touchstart") {
2567
2567
  e.preventDefault();
@@ -2587,7 +2587,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2587
2587
  }
2588
2588
  el.classList.add("v-draggable--dragging");
2589
2589
  state2.moveHandler = (moveEvent) => {
2590
- var _a3, _b2;
2590
+ var _a3, _b3;
2591
2591
  if (!state2.isDragging) return;
2592
2592
  const { clientX: moveX, clientY: moveY } = getClientCoords$1(moveEvent);
2593
2593
  let deltaX = moveX - state2.startX, deltaY = moveY - state2.startY;
@@ -2612,10 +2612,10 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2612
2612
  newY = state2.offsetY + (constrainedTop - state2.initialTop);
2613
2613
  }
2614
2614
  el.style.transform = `translate(${newX}px, ${newY}px)`;
2615
- (_b2 = (_a3 = state2.options).onDrag) == null ? void 0 : _b2.call(_a3, { x: newX, y: newY }, moveEvent);
2615
+ (_b3 = (_a3 = state2.options).onDrag) == null ? void 0 : _b3.call(_a3, { x: newX, y: newY }, moveEvent);
2616
2616
  };
2617
2617
  state2.endHandler = () => {
2618
- var _a3, _b2;
2618
+ var _a3, _b3;
2619
2619
  if (!state2.isDragging) return;
2620
2620
  state2.isDragging = false;
2621
2621
  el.classList.remove("v-draggable--dragging");
@@ -2628,13 +2628,13 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2628
2628
  document.removeEventListener("touchend", state2.endHandler);
2629
2629
  }
2630
2630
  const { x: finalX, y: finalY } = parseTranslate$1(el.style.transform);
2631
- (_b2 = (_a3 = state2.options).onEnd) == null ? void 0 : _b2.call(_a3, { x: finalX, y: finalY }, new MouseEvent("mouseup"));
2631
+ (_b3 = (_a3 = state2.options).onEnd) == null ? void 0 : _b3.call(_a3, { x: finalX, y: finalY }, new MouseEvent("mouseup"));
2632
2632
  };
2633
2633
  document.addEventListener("mousemove", state2.moveHandler);
2634
2634
  document.addEventListener("touchmove", state2.moveHandler, { passive: false });
2635
2635
  document.addEventListener("mouseup", state2.endHandler);
2636
2636
  document.addEventListener("touchend", state2.endHandler);
2637
- (_c = (_b = state2.options).onStart) == null ? void 0 : _c.call(_b, { x: state2.offsetX, y: state2.offsetY }, e);
2637
+ (_c = (_b2 = state2.options).onStart) == null ? void 0 : _c.call(_b2, { x: state2.offsetX, y: state2.offsetY }, e);
2638
2638
  }
2639
2639
  },
2640
2640
  updated(el, binding) {
@@ -2787,7 +2787,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2787
2787
  return el.scrollWidth > el.clientWidth || el.scrollHeight > el.clientHeight;
2788
2788
  }
2789
2789
  function normalizeOptions$G(binding) {
2790
- var _a2, _b, _c, _d;
2790
+ var _a2, _b2, _c, _d;
2791
2791
  if (typeof binding === "number") {
2792
2792
  return {
2793
2793
  lines: binding,
@@ -2798,7 +2798,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
2798
2798
  }
2799
2799
  return {
2800
2800
  lines: (_a2 = binding == null ? void 0 : binding.lines) != null ? _a2 : 1,
2801
- ellipsis: (_b = binding == null ? void 0 : binding.ellipsis) != null ? _b : "...",
2801
+ ellipsis: (_b2 = binding == null ? void 0 : binding.ellipsis) != null ? _b2 : "...",
2802
2802
  expandable: (_c = binding == null ? void 0 : binding.expandable) != null ? _c : false,
2803
2803
  titleBehavior: (_d = binding == null ? void 0 : binding.titleBehavior) != null ? _d : "auto"
2804
2804
  };
@@ -3041,8 +3041,8 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
3041
3041
  const state2 = {
3042
3042
  options,
3043
3043
  clickHandler: () => {
3044
- var _a2, _b, _c, _d, _e, _f;
3045
- if (((_b = (_a2 = state2.options).onBeforeExport) == null ? void 0 : _b.call(_a2)) === false) {
3044
+ var _a2, _b2, _c, _d, _e, _f;
3045
+ if (((_b2 = (_a2 = state2.options).onBeforeExport) == null ? void 0 : _b2.call(_a2)) === false) {
3046
3046
  return;
3047
3047
  }
3048
3048
  try {
@@ -3360,13 +3360,13 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
3360
3360
  }
3361
3361
  },
3362
3362
  changeHandler: () => {
3363
- var _a2, _b, _c, _d, _e, _f;
3363
+ var _a2, _b2, _c, _d, _e, _f;
3364
3364
  const wasFullscreen = state2.isFullscreen;
3365
3365
  state2.isFullscreen = getFullscreenElement$1() === el;
3366
3366
  if (wasFullscreen !== state2.isFullscreen) {
3367
3367
  if (state2.isFullscreen) {
3368
3368
  el.classList.add(state2.options.fullscreenClass || "v-fullscreen--active");
3369
- (_b = (_a2 = state2.options).onEnter) == null ? void 0 : _b.call(_a2);
3369
+ (_b2 = (_a2 = state2.options).onEnter) == null ? void 0 : _b2.call(_a2);
3370
3370
  } else {
3371
3371
  el.classList.remove(state2.options.fullscreenClass || "v-fullscreen--active");
3372
3372
  (_d = (_c = state2.options).onExit) == null ? void 0 : _d.call(_c);
@@ -3509,23 +3509,23 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
3509
3509
  }
3510
3510
  });
3511
3511
  function applyHighlight(el, state2) {
3512
- var _a2, _b;
3512
+ var _a2, _b2;
3513
3513
  if (isTextNodeOnly(el)) {
3514
3514
  const highlighted = highlightKeywords(state2.originalContent, state2.options);
3515
3515
  el.innerHTML = highlighted;
3516
3516
  const count = el.querySelectorAll(state2.options.tag || "mark").length;
3517
- (_b = (_a2 = state2.options).onHighlight) == null ? void 0 : _b.call(_a2, count);
3517
+ (_b2 = (_a2 = state2.options).onHighlight) == null ? void 0 : _b2.call(_a2, count);
3518
3518
  } else {
3519
3519
  processTextNodes(el, state2);
3520
3520
  }
3521
3521
  }
3522
3522
  function processTextNodes(element, state2) {
3523
- var _a2, _b, _c, _d;
3523
+ var _a2, _b2, _c, _d;
3524
3524
  const walker = document.createTreeWalker(element, NodeFilter.SHOW_TEXT, null);
3525
3525
  const textNodes = [];
3526
3526
  let node = walker.nextNode(), highlightCount = 0;
3527
3527
  while (node) {
3528
- if (((_b = (_a2 = node.parentNode) == null ? void 0 : _a2.tagName) == null ? void 0 : _b.toLowerCase()) === (state2.options.tag || "mark").toLowerCase()) {
3528
+ if (((_b2 = (_a2 = node.parentNode) == null ? void 0 : _a2.tagName) == null ? void 0 : _b2.toLowerCase()) === (state2.options.tag || "mark").toLowerCase()) {
3529
3529
  node = walker.nextNode();
3530
3530
  continue;
3531
3531
  }
@@ -3613,13 +3613,13 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
3613
3613
  return true;
3614
3614
  }
3615
3615
  function createEntry(key, modifiers, handler, options = {}) {
3616
- var _a2, _b, _c;
3616
+ var _a2, _b2, _c;
3617
3617
  return {
3618
3618
  key: normalizeKey(key),
3619
3619
  modifiers: new Set(modifiers),
3620
3620
  handler,
3621
3621
  prevent: (_a2 = options.prevent) != null ? _a2 : true,
3622
- stop: (_b = options.stop) != null ? _b : true,
3622
+ stop: (_b2 = options.stop) != null ? _b2 : true,
3623
3623
  disabled: (_c = options.disabled) != null ? _c : false
3624
3624
  };
3625
3625
  }
@@ -3793,24 +3793,24 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
3793
3793
  }, binding);
3794
3794
  }
3795
3795
  function applyHoverState(el, state2, e) {
3796
- var _a2, _b;
3796
+ var _a2, _b2;
3797
3797
  const { options } = state2;
3798
3798
  if (options.class) {
3799
3799
  el.classList.add(options.class);
3800
3800
  }
3801
3801
  el.dispatchEvent(new CustomEvent("hover:enter", { detail: { event: e } }));
3802
3802
  (_a2 = options.onEnter) == null ? void 0 : _a2.call(options, e);
3803
- (_b = options.handler) == null ? void 0 : _b.call(options, true, e);
3803
+ (_b2 = options.handler) == null ? void 0 : _b2.call(options, true, e);
3804
3804
  }
3805
3805
  function applyLeaveState(el, state2, e) {
3806
- var _a2, _b;
3806
+ var _a2, _b2;
3807
3807
  const { options } = state2;
3808
3808
  if (options.class) {
3809
3809
  el.classList.remove(options.class);
3810
3810
  }
3811
3811
  el.dispatchEvent(new CustomEvent("hover:leave", { detail: { event: e } }));
3812
3812
  (_a2 = options.onLeave) == null ? void 0 : _a2.call(options, e);
3813
- (_b = options.handler) == null ? void 0 : _b.call(options, false, e);
3813
+ (_b2 = options.handler) == null ? void 0 : _b2.call(options, false, e);
3814
3814
  }
3815
3815
  const vHover = defineDirective({
3816
3816
  name: "hover",
@@ -4162,7 +4162,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
4162
4162
  return { handleTouchStart, handleTouchMove, handleTouchEnd, handleMouseDown, handleMouseMove, handleMouseUp, handleWheel };
4163
4163
  }
4164
4164
  function normalizeOptions$y(binding, el) {
4165
- var _a2, _b, _c, _d, _e, _f, _g, _h, _i, _j;
4165
+ var _a2, _b2, _c, _d, _e, _f, _g, _h, _i, _j;
4166
4166
  const elSrc = el.tagName === "IMG" ? el.src : void 0;
4167
4167
  const elPreviewSrc = el.getAttribute("data-preview") || void 0;
4168
4168
  const elAlt = el.tagName === "IMG" ? el.alt : el.getAttribute("alt") || void 0;
@@ -4187,7 +4187,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
4187
4187
  previewSrc: (binding == null ? void 0 : binding.previewSrc) || elPreviewSrc,
4188
4188
  alt: (binding == null ? void 0 : binding.alt) || elAlt,
4189
4189
  disabled: (_a2 = binding == null ? void 0 : binding.disabled) != null ? _a2 : false,
4190
- closeOnClickOutside: (_b = binding == null ? void 0 : binding.closeOnClickOutside) != null ? _b : true,
4190
+ closeOnClickOutside: (_b2 = binding == null ? void 0 : binding.closeOnClickOutside) != null ? _b2 : true,
4191
4191
  closeOnEsc: (_c = binding == null ? void 0 : binding.closeOnEsc) != null ? _c : true,
4192
4192
  showCloseButton: (_d = binding == null ? void 0 : binding.showCloseButton) != null ? _d : true,
4193
4193
  zIndex: binding == null ? void 0 : binding.zIndex,
@@ -4244,7 +4244,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
4244
4244
  if (!state2.isOpen || !state2.overlay) return;
4245
4245
  state2.overlay.style.opacity = "0";
4246
4246
  setTimeout(() => {
4247
- var _a2, _b;
4247
+ var _a2, _b2;
4248
4248
  if (!state2.overlay) return;
4249
4249
  state2.overlay.remove();
4250
4250
  state2.overlay = null;
@@ -4262,12 +4262,12 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
4262
4262
  if (handlers.mouseMove) document.removeEventListener("mousemove", handlers.mouseMove);
4263
4263
  if (handlers.mouseUp) document.removeEventListener("mouseup", handlers.mouseUp);
4264
4264
  if (handlers.wheel) document.removeEventListener("wheel", handlers.wheel);
4265
- (_b = (_a2 = state2.options).onClose) == null ? void 0 : _b.call(_a2);
4265
+ (_b2 = (_a2 = state2.options).onClose) == null ? void 0 : _b2.call(_a2);
4266
4266
  }, DEFAULTS.animationDuration);
4267
4267
  };
4268
4268
  const gestureHandlers = createGestureHandlers(state2, transformManager, closePreview);
4269
4269
  const openPreview = () => {
4270
- var _a2, _b, _c;
4270
+ var _a2, _b2, _c;
4271
4271
  if (state2.isOpen || state2.options.disabled) return;
4272
4272
  const { overlay, imageContainer, image } = createOverlay(state2.options);
4273
4273
  state2.overlay = overlay;
@@ -4312,7 +4312,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
4312
4312
  };
4313
4313
  document.addEventListener("keydown", state2.handlers.esc);
4314
4314
  }
4315
- (_c = (_b = state2.options).onOpen) == null ? void 0 : _c.call(_b);
4315
+ (_c = (_b2 = state2.options).onOpen) == null ? void 0 : _c.call(_b2);
4316
4316
  };
4317
4317
  state2.handlers.click = openPreview;
4318
4318
  el.addEventListener("click", openPreview);
@@ -4447,9 +4447,9 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
4447
4447
  }
4448
4448
  function triggerLoad(state2, el) {
4449
4449
  return __async(this, null, function* () {
4450
- var _a2, _b, _c, _d, _e, _f;
4450
+ var _a2, _b2, _c, _d, _e, _f;
4451
4451
  state2.isLoading = true;
4452
- (_b = (_a2 = state2.options).onLoadStart) == null ? void 0 : _b.call(_a2);
4452
+ (_b2 = (_a2 = state2.options).onLoadStart) == null ? void 0 : _b2.call(_a2);
4453
4453
  el.classList.add("v-infinite-scroll--loading");
4454
4454
  try {
4455
4455
  yield state2.options.handler();
@@ -4500,12 +4500,12 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
4500
4500
  }
4501
4501
  function createObserverCallback(el, state2, options) {
4502
4502
  return (entries) => {
4503
- var _a2, _b, _c, _d;
4503
+ var _a2, _b2, _c, _d;
4504
4504
  for (const entry of entries) {
4505
4505
  if (options.once && state2.hasTriggeredOnce) continue;
4506
4506
  const { isIntersecting } = entry;
4507
4507
  (_a2 = options.handler) == null ? void 0 : _a2.call(options, entry, state2.observer);
4508
- (_b = options.onChange) == null ? void 0 : _b.call(options, isIntersecting, entry);
4508
+ (_b2 = options.onChange) == null ? void 0 : _b2.call(options, isIntersecting, entry);
4509
4509
  if (isIntersecting) {
4510
4510
  (_c = options.onEnter) == null ? void 0 : _c.call(options, entry, state2.observer);
4511
4511
  if (options.once) state2.hasTriggeredOnce = true;
@@ -4550,7 +4550,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
4550
4550
  state2.observer.observe(el);
4551
4551
  },
4552
4552
  updated(el, binding) {
4553
- var _a2, _b, _c;
4553
+ var _a2, _b2, _c;
4554
4554
  const state2 = el[STATE_KEY$3];
4555
4555
  if (!state2) return;
4556
4556
  const newOptions = normalizeOptions$w(binding.value);
@@ -4559,7 +4559,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
4559
4559
  if (newOptions.disabled) {
4560
4560
  (_a2 = state2.observer) == null ? void 0 : _a2.disconnect();
4561
4561
  } else {
4562
- (_b = state2.observer) == null ? void 0 : _b.observe(el);
4562
+ (_b2 = state2.observer) == null ? void 0 : _b2.observe(el);
4563
4563
  }
4564
4564
  }
4565
4565
  if (observerOptionsChanged) {
@@ -4619,15 +4619,15 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
4619
4619
  el.classList.add("v-lazy--loading");
4620
4620
  const img = new Image();
4621
4621
  img.onload = () => {
4622
- var _a2, _b;
4622
+ var _a2, _b2;
4623
4623
  setSrc$1(el, state2.options.src);
4624
4624
  setLazyState(el, "loaded");
4625
4625
  el.classList.remove("v-lazy--loading");
4626
4626
  el.classList.add("v-lazy--loaded");
4627
- (_b = (_a2 = state2.options).onLoad) == null ? void 0 : _b.call(_a2, el);
4627
+ (_b2 = (_a2 = state2.options).onLoad) == null ? void 0 : _b2.call(_a2, el);
4628
4628
  };
4629
4629
  img.onerror = () => {
4630
- var _a2, _b;
4630
+ var _a2, _b2;
4631
4631
  el.classList.remove("v-lazy--loading");
4632
4632
  if (state2.attempt < (state2.options.attempt || 1)) {
4633
4633
  setTimeout(() => load(el), 1e3 * state2.attempt);
@@ -4638,7 +4638,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
4638
4638
  }
4639
4639
  setLazyState(el, "error");
4640
4640
  el.classList.add("v-lazy--error");
4641
- (_b = (_a2 = state2.options).onError) == null ? void 0 : _b.call(_a2, el, new Error("Failed to load image"));
4641
+ (_b2 = (_a2 = state2.options).onError) == null ? void 0 : _b2.call(_a2, el, new Error("Failed to load image"));
4642
4642
  };
4643
4643
  img.src = state2.options.src;
4644
4644
  }
@@ -5187,7 +5187,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
5187
5187
  return text.toLowerCase();
5188
5188
  }
5189
5189
  function normalizeOptions$r(binding) {
5190
- var _a2, _b;
5190
+ var _a2, _b2;
5191
5191
  if (binding === void 0 || binding === true) {
5192
5192
  return { first: false, onInput: true };
5193
5193
  }
@@ -5196,7 +5196,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
5196
5196
  }
5197
5197
  return {
5198
5198
  first: (_a2 = binding.first) != null ? _a2 : false,
5199
- onInput: (_b = binding.onInput) != null ? _b : true
5199
+ onInput: (_b2 = binding.onInput) != null ? _b2 : true
5200
5200
  };
5201
5201
  }
5202
5202
  const vLowercase = defineDirective({
@@ -5307,7 +5307,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
5307
5307
  const placeholder = options.placeholder || "_";
5308
5308
  const tokens = parseMask$1(options.mask, placeholder);
5309
5309
  const inputHandler = (e) => {
5310
- var _a3, _b, _c;
5310
+ var _a3, _b2, _c;
5311
5311
  const target = e.target;
5312
5312
  const rawValue = target.value;
5313
5313
  const cursorPos = target.selectionStart || 0;
@@ -5318,7 +5318,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
5318
5318
  target.dispatchEvent(new Event("input", { bubbles: true }));
5319
5319
  return;
5320
5320
  }
5321
- (_b = options.onChange) == null ? void 0 : _b.call(options, formatted, getRawValue(formatted, tokens, placeholder));
5321
+ (_b2 = options.onChange) == null ? void 0 : _b2.call(options, formatted, getRawValue(formatted, tokens, placeholder));
5322
5322
  if (isComplete(formatted, tokens, placeholder)) {
5323
5323
  (_c = options.onComplete) == null ? void 0 : _c.call(options, formatted);
5324
5324
  }
@@ -5472,9 +5472,9 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
5472
5472
  name: "money",
5473
5473
  ssr: true,
5474
5474
  mounted(el, binding) {
5475
- var _a2, _b, _c;
5475
+ var _a2, _b2, _c;
5476
5476
  const options = typeof binding.value === "string" ? { symbol: binding.value } : (_a2 = binding.value) != null ? _a2 : {};
5477
- options.precision = (_b = options.precision) != null ? _b : 2;
5477
+ options.precision = (_b2 = options.precision) != null ? _b2 : 2;
5478
5478
  if (isInputElement(el)) {
5479
5479
  const { symbol = "$", symbolPosition = "before" } = options;
5480
5480
  const prefix = symbolPosition === "before" ? symbol : "";
@@ -5509,9 +5509,9 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
5509
5509
  }
5510
5510
  },
5511
5511
  updated(el, binding) {
5512
- var _a2, _b;
5512
+ var _a2, _b2;
5513
5513
  const options = typeof binding.value === "string" ? { symbol: binding.value } : (_a2 = binding.value) != null ? _a2 : {};
5514
- options.precision = (_b = options.precision) != null ? _b : 2;
5514
+ options.precision = (_b2 = options.precision) != null ? _b2 : 2;
5515
5515
  const state2 = el.__money;
5516
5516
  if (state2) {
5517
5517
  state2.options = options;
@@ -5636,7 +5636,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
5636
5636
  name: "number",
5637
5637
  ssr: true,
5638
5638
  mounted(el, binding) {
5639
- var _a2, _b;
5639
+ var _a2, _b2;
5640
5640
  const options = typeof binding.value === "number" ? { precision: binding.value } : (_a2 = binding.value) != null ? _a2 : {};
5641
5641
  if (isInputElement(el)) {
5642
5642
  const cleanup2 = setupNumberInput(el, options, formatNumber$2);
@@ -5661,7 +5661,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
5661
5661
  } else if (binding.value && typeof binding.value === "object" && "value" in binding.value) {
5662
5662
  value = binding.value.value;
5663
5663
  } else {
5664
- const textContent = (_b = el.textContent) == null ? void 0 : _b.trim();
5664
+ const textContent = (_b2 = el.textContent) == null ? void 0 : _b2.trim();
5665
5665
  if (textContent) {
5666
5666
  value = parseToNumber(textContent, options.decimal || ".");
5667
5667
  }
@@ -5749,7 +5749,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
5749
5749
  name: "pan",
5750
5750
  ssr: false,
5751
5751
  mounted(el, binding) {
5752
- var _a2, _b;
5752
+ var _a2, _b2;
5753
5753
  if (!isBrowser()) return;
5754
5754
  const options = normalizeOptions$o(binding.value);
5755
5755
  const state2 = {
@@ -5774,7 +5774,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
5774
5774
  on(el, "touchend", state2.touchendHandler);
5775
5775
  on(el, "touchcancel", state2.touchendHandler);
5776
5776
  }
5777
- if ((_b = options.pointers) == null ? void 0 : _b.includes("mouse")) {
5777
+ if ((_b2 = options.pointers) == null ? void 0 : _b2.includes("mouse")) {
5778
5778
  on(el, "mousedown", state2.mousedownHandler);
5779
5779
  }
5780
5780
  el.classList.add("v-pan");
@@ -5816,7 +5816,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
5816
5816
  }
5817
5817
  }
5818
5818
  function handleMove$2(e, state2, _el) {
5819
- var _a2, _b, _c, _d;
5819
+ var _a2, _b2, _c, _d;
5820
5820
  const pos = getPosition$1(e);
5821
5821
  state2.currentX = pos.x;
5822
5822
  state2.currentY = pos.y;
@@ -5838,17 +5838,17 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
5838
5838
  state2.isPanning = true;
5839
5839
  const panEvent = createPanEvent(e, state2, !wasPanning);
5840
5840
  if (!wasPanning) {
5841
- (_b = (_a2 = state2.options).onStart) == null ? void 0 : _b.call(_a2, panEvent);
5841
+ (_b2 = (_a2 = state2.options).onStart) == null ? void 0 : _b2.call(_a2, panEvent);
5842
5842
  }
5843
5843
  (_d = (_c = state2.options).onPan) == null ? void 0 : _d.call(_c, panEvent);
5844
5844
  }
5845
5845
  function handleEnd$2(e, state2) {
5846
- var _a2, _b;
5846
+ var _a2, _b2;
5847
5847
  document.removeEventListener("mousemove", state2.mousemoveHandler);
5848
5848
  document.removeEventListener("mouseup", state2.mouseupHandler);
5849
5849
  if (!state2.isPanning) return;
5850
5850
  const panEvent = createPanEvent(e, state2, false, true);
5851
- (_b = (_a2 = state2.options).onEnd) == null ? void 0 : _b.call(_a2, panEvent);
5851
+ (_b2 = (_a2 = state2.options).onEnd) == null ? void 0 : _b2.call(_a2, panEvent);
5852
5852
  state2.isPanning = false;
5853
5853
  }
5854
5854
  function normalizeOptions$n(binding) {
@@ -6016,13 +6016,13 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
6016
6016
  return mode === "every" ? required.every(checkSingle) : required.some(checkSingle);
6017
6017
  }
6018
6018
  function handleDenied(el, action, state2) {
6019
- var _a2, _b;
6019
+ var _a2, _b2;
6020
6020
  switch (action) {
6021
6021
  case "remove":
6022
6022
  state2.parentNode = el.parentNode;
6023
6023
  state2.placeholder = document.createComment("v-permission");
6024
6024
  (_a2 = el.parentNode) == null ? void 0 : _a2.insertBefore(state2.placeholder, el);
6025
- (_b = el.parentNode) == null ? void 0 : _b.removeChild(el);
6025
+ (_b2 = el.parentNode) == null ? void 0 : _b2.removeChild(el);
6026
6026
  break;
6027
6027
  case "disable":
6028
6028
  state2.originalDisabled = el.getAttribute("disabled") || false;
@@ -6072,11 +6072,11 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
6072
6072
  return el[STATE_KEY$1];
6073
6073
  }
6074
6074
  function checkPermission(el, binding) {
6075
- var _a2, _b;
6075
+ var _a2, _b2;
6076
6076
  const state2 = getState(el);
6077
6077
  state2.options = normalizeOptions$m(binding.value);
6078
6078
  const granted = verifyPermission(state2.options);
6079
- (_b = (_a2 = state2.options).onChange) == null ? void 0 : _b.call(_a2, granted);
6079
+ (_b2 = (_a2 = state2.options).onChange) == null ? void 0 : _b2.call(_a2, granted);
6080
6080
  const action = state2.options.action || "remove";
6081
6081
  if (granted) {
6082
6082
  handleGranted(el, action, state2);
@@ -6203,7 +6203,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
6203
6203
  }
6204
6204
  }
6205
6205
  function handleMove$1(e, state2, el) {
6206
- var _a2, _b, _c, _d;
6206
+ var _a2, _b2, _c, _d;
6207
6207
  if (e.touches.length !== 2) return;
6208
6208
  state2.currentDistance = getDistance$2(e.touches);
6209
6209
  if (state2.initialDistance <= 0) return;
@@ -6217,7 +6217,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
6217
6217
  state2.isPinching = true;
6218
6218
  const pinchEvent = createPinchEvent(e, state2, !wasPinching);
6219
6219
  if (!wasPinching) {
6220
- (_b = (_a2 = state2.options).onStart) == null ? void 0 : _b.call(_a2, pinchEvent);
6220
+ (_b2 = (_a2 = state2.options).onStart) == null ? void 0 : _b2.call(_a2, pinchEvent);
6221
6221
  }
6222
6222
  if (state2.options.enableTransform) {
6223
6223
  const transformOrigin = state2.options.transformOrigin || "center center";
@@ -6227,7 +6227,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
6227
6227
  (_d = (_c = state2.options).onPinch) == null ? void 0 : _d.call(_c, pinchEvent);
6228
6228
  }
6229
6229
  function handleEnd$1(e, state2, el) {
6230
- var _a2, _b;
6230
+ var _a2, _b2;
6231
6231
  if (!state2.isPinching) return;
6232
6232
  if (state2.options.enableTransform) {
6233
6233
  el.style.transition = state2.savedTransition;
@@ -6236,7 +6236,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
6236
6236
  touches: e.touches.length >= 2 ? e.touches : []
6237
6237
  });
6238
6238
  const pinchEvent = createPinchEvent(finalEvent, state2, false, true);
6239
- (_b = (_a2 = state2.options).onEnd) == null ? void 0 : _b.call(_a2, pinchEvent);
6239
+ (_b2 = (_a2 = state2.options).onEnd) == null ? void 0 : _b2.call(_a2, pinchEvent);
6240
6240
  state2.isPinching = false;
6241
6241
  state2.initialDistance = 0;
6242
6242
  state2.currentDistance = 0;
@@ -6310,7 +6310,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
6310
6310
  }
6311
6311
  function printInIframe$1(el, options) {
6312
6312
  return __async(this, null, function* () {
6313
- var _a2, _b, _c;
6313
+ var _a2, _b2, _c;
6314
6314
  const iframe = document.createElement("iframe");
6315
6315
  iframe.style.cssText = "position: absolute; top: -10000px; left: -10000px; width: 0; height: 0; border: none;";
6316
6316
  document.body.appendChild(iframe);
@@ -6326,7 +6326,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
6326
6326
  iframeDoc.close();
6327
6327
  yield waitForImages$1(iframeDoc);
6328
6328
  try {
6329
- (_b = iframe.contentWindow) == null ? void 0 : _b.focus();
6329
+ (_b2 = iframe.contentWindow) == null ? void 0 : _b2.focus();
6330
6330
  (_c = iframe.contentWindow) == null ? void 0 : _c.print();
6331
6331
  } catch (err) {
6332
6332
  console.error("[Directix] v-print: Print failed", err);
@@ -6577,7 +6577,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
6577
6577
  }
6578
6578
  });
6579
6579
  function setProgress(state2, value) {
6580
- var _a2, _b;
6580
+ var _a2, _b2;
6581
6581
  const { options, progressBar, container } = state2;
6582
6582
  if (!progressBar || !container) return;
6583
6583
  const min = options.min || 0;
@@ -6594,7 +6594,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
6594
6594
  state2.currentValue = clampedValue;
6595
6595
  (_a2 = options.onChange) == null ? void 0 : _a2.call(options, clampedValue, percent);
6596
6596
  if (percent >= 100) {
6597
- (_b = options.onComplete) == null ? void 0 : _b.call(options);
6597
+ (_b2 = options.onComplete) == null ? void 0 : _b2.call(options);
6598
6598
  }
6599
6599
  }
6600
6600
  const DEFAULT_DISTANCE = 60;
@@ -6610,12 +6610,12 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
6610
6610
  error: "✗ Failed"
6611
6611
  };
6612
6612
  function normalizeOptions$i(binding) {
6613
- var _a2, _b, _c, _d, _e;
6613
+ var _a2, _b2, _c, _d, _e;
6614
6614
  if (typeof binding === "function") return { handler: binding };
6615
6615
  return {
6616
6616
  handler: binding.handler,
6617
6617
  distance: (_a2 = binding.distance) != null ? _a2 : DEFAULT_DISTANCE,
6618
- maxDistance: (_b = binding.maxDistance) != null ? _b : DEFAULT_MAX_DISTANCE,
6618
+ maxDistance: (_b2 = binding.maxDistance) != null ? _b2 : DEFAULT_MAX_DISTANCE,
6619
6619
  disabled: (_c = binding.disabled) != null ? _c : false,
6620
6620
  indicator: binding.indicator,
6621
6621
  successDuration: (_d = binding.successDuration) != null ? _d : DEFAULT_SUCCESS_DURATION,
@@ -6651,11 +6651,11 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
6651
6651
  el.textContent = customIndicator || DEFAULT_INDICATORS[state2];
6652
6652
  }
6653
6653
  function setState(internal, newState) {
6654
- var _a2, _b;
6654
+ var _a2, _b2;
6655
6655
  if (internal.state === newState) return;
6656
6656
  internal.state = newState;
6657
6657
  updateIndicator(internal.indicatorEl, newState, internal.options);
6658
- (_b = (_a2 = internal.options).onStateChange) == null ? void 0 : _b.call(_a2, newState);
6658
+ (_b2 = (_a2 = internal.options).onStateChange) == null ? void 0 : _b2.call(_a2, newState);
6659
6659
  }
6660
6660
  function applyTransform(internal, distance, showIndicator) {
6661
6661
  internal.contentEl.style.transform = `translateY(${distance}px)`;
@@ -7137,7 +7137,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
7137
7137
  }
7138
7138
  }
7139
7139
  function handleMove(e, state2, el) {
7140
- var _a2, _b, _c, _d;
7140
+ var _a2, _b2, _c, _d;
7141
7141
  if (e.touches.length !== 2) return;
7142
7142
  state2.currentAngle = getAngle$2(e.touches);
7143
7143
  if (state2.options.preventDefault) {
@@ -7147,7 +7147,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
7147
7147
  state2.isRotating = true;
7148
7148
  const rotateEvent = createRotateEvent(e, state2, !wasRotating);
7149
7149
  if (!wasRotating) {
7150
- (_b = (_a2 = state2.options).onStart) == null ? void 0 : _b.call(_a2, rotateEvent);
7150
+ (_b2 = (_a2 = state2.options).onStart) == null ? void 0 : _b2.call(_a2, rotateEvent);
7151
7151
  }
7152
7152
  if (state2.options.enableTransform) {
7153
7153
  const rotation = state2.currentAngle - state2.initialAngle;
@@ -7158,7 +7158,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
7158
7158
  (_d = (_c = state2.options).onRotate) == null ? void 0 : _d.call(_c, rotateEvent);
7159
7159
  }
7160
7160
  function handleEnd(e, state2, el) {
7161
- var _a2, _b;
7161
+ var _a2, _b2;
7162
7162
  if (!state2.isRotating) return;
7163
7163
  if (state2.options.enableTransform) {
7164
7164
  el.style.transition = state2.savedTransition;
@@ -7167,28 +7167,28 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
7167
7167
  touches: e.touches.length >= 2 ? e.touches : []
7168
7168
  });
7169
7169
  const rotateEvent = createRotateEvent(finalEvent, state2, false, true);
7170
- (_b = (_a2 = state2.options).onEnd) == null ? void 0 : _b.call(_a2, rotateEvent);
7170
+ (_b2 = (_a2 = state2.options).onEnd) == null ? void 0 : _b2.call(_a2, rotateEvent);
7171
7171
  state2.isRotating = false;
7172
7172
  state2.initialAngle = 0;
7173
7173
  state2.currentAngle = 0;
7174
7174
  }
7175
- const DEFAULT_ALLOWED_TAGS$1 = ["b", "i", "u", "strong", "em", "br", "p", "span", "div"];
7176
- const DEFAULT_ALLOWED_ATTRIBUTES$1 = ["title", "alt", "href", "src"];
7177
- const DANGEROUS_TAGS$1 = ["script", "iframe", "object", "embed", "form", "input", "style", "link", "meta", "base"];
7178
- const DANGEROUS_ATTRIBUTES$1 = ["onclick", "onerror", "onload", "onmouseover", "onfocus", "onblur", "onchange", "onsubmit"];
7175
+ const DEFAULT_ALLOWED_TAGS$2 = ["b", "i", "u", "strong", "em", "br", "p", "span", "div"];
7176
+ const DEFAULT_ALLOWED_ATTRIBUTES$2 = ["title", "alt", "href", "src"];
7177
+ const DANGEROUS_TAGS$2 = ["script", "iframe", "object", "embed", "form", "input", "style", "link", "meta", "base"];
7178
+ const DANGEROUS_ATTRIBUTES$2 = ["onclick", "onerror", "onload", "onmouseover", "onfocus", "onblur", "onchange", "onsubmit"];
7179
7179
  function normalizeOptions$e(binding) {
7180
7180
  if (binding === false) {
7181
7181
  return { disabled: true };
7182
7182
  }
7183
7183
  if (binding === true) {
7184
7184
  return {
7185
- allowedTags: DEFAULT_ALLOWED_TAGS$1,
7186
- allowedAttributes: DEFAULT_ALLOWED_ATTRIBUTES$1
7185
+ allowedTags: DEFAULT_ALLOWED_TAGS$2,
7186
+ allowedAttributes: DEFAULT_ALLOWED_ATTRIBUTES$2
7187
7187
  };
7188
7188
  }
7189
7189
  return __spreadValues({
7190
- allowedTags: DEFAULT_ALLOWED_TAGS$1,
7191
- allowedAttributes: DEFAULT_ALLOWED_ATTRIBUTES$1,
7190
+ allowedTags: DEFAULT_ALLOWED_TAGS$2,
7191
+ allowedAttributes: DEFAULT_ALLOWED_ATTRIBUTES$2,
7192
7192
  allowDataUrls: false,
7193
7193
  allowStyles: false,
7194
7194
  allowClass: false,
@@ -7197,14 +7197,14 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
7197
7197
  sanitizeOnUpdate: true
7198
7198
  }, binding);
7199
7199
  }
7200
- function sanitizeHtml(html, options) {
7200
+ function sanitizeHtml$1(html, options) {
7201
7201
  var _a2;
7202
7202
  if (options.handler) {
7203
7203
  return options.handler(html);
7204
7204
  }
7205
7205
  const temp = document.createElement("div");
7206
7206
  temp.innerHTML = html;
7207
- for (const tag of DANGEROUS_TAGS$1) {
7207
+ for (const tag of DANGEROUS_TAGS$2) {
7208
7208
  const elements = temp.getElementsByTagName(tag);
7209
7209
  while (elements.length > 0) {
7210
7210
  (_a2 = elements[0].parentNode) == null ? void 0 : _a2.removeChild(elements[0]);
@@ -7218,7 +7218,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
7218
7218
  (_a3 = el.parentNode) == null ? void 0 : _a3.replaceChild(text, el);
7219
7219
  return;
7220
7220
  }
7221
- for (const attr of DANGEROUS_ATTRIBUTES$1) {
7221
+ for (const attr of DANGEROUS_ATTRIBUTES$2) {
7222
7222
  el.removeAttribute(attr);
7223
7223
  }
7224
7224
  const href = el.getAttribute("href");
@@ -7256,8 +7256,8 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
7256
7256
  name: "sanitize",
7257
7257
  ssr: true,
7258
7258
  defaults: {
7259
- allowedTags: DEFAULT_ALLOWED_TAGS$1,
7260
- allowedAttributes: DEFAULT_ALLOWED_ATTRIBUTES$1,
7259
+ allowedTags: DEFAULT_ALLOWED_TAGS$2,
7260
+ allowedAttributes: DEFAULT_ALLOWED_ATTRIBUTES$2,
7261
7261
  allowDataUrls: false,
7262
7262
  allowStyles: false,
7263
7263
  allowClass: false,
@@ -7272,7 +7272,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
7272
7272
  if (options.disabled) return;
7273
7273
  const content = el.innerHTML;
7274
7274
  if (content) {
7275
- el.innerHTML = sanitizeHtml(content, options);
7275
+ el.innerHTML = sanitizeHtml$1(content, options);
7276
7276
  }
7277
7277
  },
7278
7278
  updated(el, binding) {
@@ -7284,14 +7284,14 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
7284
7284
  if (prevDisabled && !state2.options.disabled) {
7285
7285
  const content2 = el.innerHTML;
7286
7286
  if (content2) {
7287
- el.innerHTML = sanitizeHtml(content2, state2.options);
7287
+ el.innerHTML = sanitizeHtml$1(content2, state2.options);
7288
7288
  }
7289
7289
  }
7290
7290
  return;
7291
7291
  }
7292
7292
  const content = el.innerHTML;
7293
7293
  if (content) {
7294
- el.innerHTML = sanitizeHtml(content, state2.options);
7294
+ el.innerHTML = sanitizeHtml$1(content, state2.options);
7295
7295
  }
7296
7296
  },
7297
7297
  unmounted(el) {
@@ -7603,7 +7603,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
7603
7603
  }
7604
7604
  }
7605
7605
  function setSticky(el, state2, topOffset, containerTop) {
7606
- var _a2, _b, _c;
7606
+ var _a2, _b2, _c;
7607
7607
  state2.isSticky = true;
7608
7608
  const placeholder = document.createElement("div");
7609
7609
  placeholder.style.cssText = `width:${el.offsetWidth}px;height:${el.offsetHeight}px`;
@@ -7619,13 +7619,13 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
7619
7619
  }
7620
7620
  state2.options.stickyClass && el.classList.add(state2.options.stickyClass);
7621
7621
  el.dispatchEvent(new CustomEvent("sticky:change", { detail: { isSticky: true } }));
7622
- (_c = (_b = state2.options).onChange) == null ? void 0 : _c.call(_b, true);
7622
+ (_c = (_b2 = state2.options).onChange) == null ? void 0 : _c.call(_b2, true);
7623
7623
  }
7624
7624
  function unsetSticky(el, state2) {
7625
- var _a2, _b, _c, _d;
7625
+ var _a2, _b2, _c, _d;
7626
7626
  if (!state2.isSticky) return;
7627
7627
  state2.isSticky = false;
7628
- (_b = (_a2 = state2.placeholder) == null ? void 0 : _a2.parentNode) == null ? void 0 : _b.removeChild(state2.placeholder);
7628
+ (_b2 = (_a2 = state2.placeholder) == null ? void 0 : _a2.parentNode) == null ? void 0 : _b2.removeChild(state2.placeholder);
7629
7629
  state2.placeholder = null;
7630
7630
  Object.assign(el.style, state2.originalStyles);
7631
7631
  state2.options.stickyClass && el.classList.remove(state2.options.stickyClass);
@@ -7668,10 +7668,10 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
7668
7668
  checkSticky(el, state2);
7669
7669
  },
7670
7670
  unmounted(el) {
7671
- var _a2, _b;
7671
+ var _a2, _b2;
7672
7672
  const state2 = el[STATE_KEY];
7673
7673
  if (!state2) return;
7674
- (_b = (_a2 = state2.placeholder) == null ? void 0 : _a2.parentNode) == null ? void 0 : _b.removeChild(state2.placeholder);
7674
+ (_b2 = (_a2 = state2.placeholder) == null ? void 0 : _a2.parentNode) == null ? void 0 : _b2.removeChild(state2.placeholder);
7675
7675
  Object.assign(el.style, state2.originalStyles);
7676
7676
  el.classList.remove("v-sticky", state2.options.stickyClass || "v-sticky--fixed");
7677
7677
  off(state2.container, "scroll", state2.scrollHandler);
@@ -7694,12 +7694,12 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
7694
7694
  }
7695
7695
  }
7696
7696
  function normalizeOptions$a(binding) {
7697
- var _a2, _b, _c, _d, _e, _f;
7697
+ var _a2, _b2, _c, _d, _e, _f;
7698
7698
  if (typeof binding === "function") return { handler: binding };
7699
7699
  return {
7700
7700
  handler: binding.handler,
7701
7701
  threshold: (_a2 = binding.threshold) != null ? _a2 : DEFAULT_THRESHOLD,
7702
- maxTime: (_b = binding.maxTime) != null ? _b : DEFAULT_MAX_TIME,
7702
+ maxTime: (_b2 = binding.maxTime) != null ? _b2 : DEFAULT_MAX_TIME,
7703
7703
  directions: (_c = binding.directions) != null ? _c : [...DEFAULT_DIRECTIONS$1],
7704
7704
  preventScrollOnSwipe: (_d = binding.preventScrollOnSwipe) != null ? _d : true,
7705
7705
  disabled: (_e = binding.disabled) != null ? _e : false,
@@ -7711,11 +7711,11 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
7711
7711
  };
7712
7712
  }
7713
7713
  function triggerSwipe(state2, deltaX, deltaY, deltaTime, event, el) {
7714
- var _a2, _b, _c, _d, _e;
7714
+ var _a2, _b2, _c, _d, _e;
7715
7715
  const { options } = state2;
7716
7716
  if (deltaTime > ((_a2 = options.maxTime) != null ? _a2 : DEFAULT_MAX_TIME)) return;
7717
7717
  const distance = Math.max(Math.abs(deltaX), Math.abs(deltaY));
7718
- if (distance < ((_b = options.threshold) != null ? _b : DEFAULT_THRESHOLD)) return;
7718
+ if (distance < ((_b2 = options.threshold) != null ? _b2 : DEFAULT_THRESHOLD)) return;
7719
7719
  const direction = getSwipeDirection$1(deltaX, deltaY, (_c = options.directions) != null ? _c : DEFAULT_DIRECTIONS$1);
7720
7720
  if (!direction) return;
7721
7721
  if (options.preventScrollOnSwipe && event.cancelable) {
@@ -7826,7 +7826,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
7826
7826
  bindEvents(el, state2);
7827
7827
  },
7828
7828
  updated(el, binding) {
7829
- var _a2, _b;
7829
+ var _a2, _b2;
7830
7830
  const state2 = el.__swipe;
7831
7831
  const newOptions = normalizeOptions$a(binding.value);
7832
7832
  if (!state2) {
@@ -7839,7 +7839,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
7839
7839
  }
7840
7840
  const wasDisabled = state2.options.disabled;
7841
7841
  const wasMouseEnabled = (_a2 = state2.options.mouse) != null ? _a2 : true;
7842
- const nowMouseEnabled = (_b = newOptions.mouse) != null ? _b : true;
7842
+ const nowMouseEnabled = (_b2 = newOptions.mouse) != null ? _b2 : true;
7843
7843
  state2.options = newOptions;
7844
7844
  if (newOptions.disabled && !wasDisabled) {
7845
7845
  unbindEvents(el, state2);
@@ -8036,7 +8036,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8036
8036
  state2.hideTimeout = null;
8037
8037
  }
8038
8038
  const doShow = () => {
8039
- var _a2, _b;
8039
+ var _a2, _b2;
8040
8040
  const tooltip = createTooltip(state2.options);
8041
8041
  state2.tooltip = tooltip;
8042
8042
  getTooltipContainer().appendChild(tooltip);
@@ -8047,7 +8047,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8047
8047
  });
8048
8048
  });
8049
8049
  state2.isVisible = true;
8050
- (_b = (_a2 = state2.options).onShow) == null ? void 0 : _b.call(_a2);
8050
+ (_b2 = (_a2 = state2.options).onShow) == null ? void 0 : _b2.call(_a2);
8051
8051
  };
8052
8052
  if (state2.options.delay && state2.options.delay > 0) {
8053
8053
  state2.showTimeout = setTimeout(doShow, state2.options.delay);
@@ -8062,7 +8062,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8062
8062
  state2.showTimeout = null;
8063
8063
  }
8064
8064
  const doHide = () => {
8065
- var _a2, _b;
8065
+ var _a2, _b2;
8066
8066
  if (state2.tooltip) {
8067
8067
  state2.tooltip.style.opacity = "0";
8068
8068
  setTimeout(() => {
@@ -8072,7 +8072,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8072
8072
  }, 200);
8073
8073
  }
8074
8074
  state2.isVisible = false;
8075
- (_b = (_a2 = state2.options).onHide) == null ? void 0 : _b.call(_a2);
8075
+ (_b2 = (_a2 = state2.options).onHide) == null ? void 0 : _b2.call(_a2);
8076
8076
  };
8077
8077
  if (state2.options.hideDelay && state2.options.hideDelay > 0) {
8078
8078
  state2.hideTimeout = setTimeout(doHide, state2.options.hideDelay);
@@ -8121,7 +8121,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8121
8121
  }
8122
8122
  }
8123
8123
  function normalizeOptions$8(binding) {
8124
- var _a2, _b, _c, _d, _e, _f, _g, _h;
8124
+ var _a2, _b2, _c, _d, _e, _f, _g, _h;
8125
8125
  if (typeof binding === "string") {
8126
8126
  return { content: binding, placement: "top", trigger: "hover" };
8127
8127
  }
@@ -8131,7 +8131,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8131
8131
  return {
8132
8132
  content: binding.content,
8133
8133
  placement: (_a2 = binding.placement) != null ? _a2 : "top",
8134
- trigger: (_b = binding.trigger) != null ? _b : "hover",
8134
+ trigger: (_b2 = binding.trigger) != null ? _b2 : "hover",
8135
8135
  delay: (_c = binding.delay) != null ? _c : 0,
8136
8136
  hideDelay: (_d = binding.hideDelay) != null ? _d : 0,
8137
8137
  offset: (_e = binding.offset) != null ? _e : 8,
@@ -8254,7 +8254,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8254
8254
  return Math.abs(x - state2.startX) > threshold || Math.abs(y - state2.startY) > threshold;
8255
8255
  };
8256
8256
  const handleGestureEnd = (endX, endY, event) => {
8257
- var _a2, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l;
8257
+ var _a2, _b2, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l;
8258
8258
  if (state2.isLongPress) return;
8259
8259
  const duration = Date.now() - state2.startTime;
8260
8260
  const deltaX = endX - state2.startX;
@@ -8262,7 +8262,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8262
8262
  const distance = Math.sqrt(__pow(deltaX, 2) + __pow(deltaY, 2));
8263
8263
  if (state2.options.enableSwipe && distance >= (state2.options.swipeThreshold || 30) && duration <= (state2.options.swipeTimeout || 500)) {
8264
8264
  const direction = Math.abs(deltaX) > Math.abs(deltaY) ? deltaX > 0 ? "right" : "left" : deltaY > 0 ? "down" : "up";
8265
- (_b = (_a2 = state2.options).onSwipe) == null ? void 0 : _b.call(_a2, direction, event);
8265
+ (_b2 = (_a2 = state2.options).onSwipe) == null ? void 0 : _b2.call(_a2, direction, event);
8266
8266
  if (direction === "left") (_d = (_c = state2.options).onSwipeLeft) == null ? void 0 : _d.call(_c, event);
8267
8267
  else if (direction === "right") (_f = (_e = state2.options).onSwipeRight) == null ? void 0 : _f.call(_e, event);
8268
8268
  else if (direction === "up") (_h = (_g = state2.options).onSwipeUp) == null ? void 0 : _h.call(_g, event);
@@ -8272,7 +8272,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8272
8272
  }
8273
8273
  };
8274
8274
  const handleTouchStart = (e) => {
8275
- var _a2, _b;
8275
+ var _a2, _b2;
8276
8276
  if (e.touches.length > 1) {
8277
8277
  e.preventDefault();
8278
8278
  }
@@ -8290,10 +8290,10 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8290
8290
  state2.lastScale = 1;
8291
8291
  state2.lastAngle = 0;
8292
8292
  }
8293
- (_b = (_a2 = state2.options).onTouchStart) == null ? void 0 : _b.call(_a2, e);
8293
+ (_b2 = (_a2 = state2.options).onTouchStart) == null ? void 0 : _b2.call(_a2, e);
8294
8294
  };
8295
8295
  const handleTouchMove = (e) => {
8296
- var _a2, _b;
8296
+ var _a2, _b2;
8297
8297
  if (e.touches.length >= 1) {
8298
8298
  e.preventDefault();
8299
8299
  }
@@ -8319,20 +8319,20 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8319
8319
  }
8320
8320
  }
8321
8321
  }
8322
- (_b = (_a2 = state2.options).onTouchMove) == null ? void 0 : _b.call(_a2, e);
8322
+ (_b2 = (_a2 = state2.options).onTouchMove) == null ? void 0 : _b2.call(_a2, e);
8323
8323
  };
8324
8324
  const handleTouchEnd = (e) => {
8325
- var _a2, _b;
8325
+ var _a2, _b2;
8326
8326
  clearLongPressTimer();
8327
8327
  if (e.touches.length === 0) {
8328
8328
  state2.lastTouchEndTime = Date.now();
8329
8329
  const touch = e.changedTouches[0];
8330
8330
  handleGestureEnd(touch.clientX, touch.clientY, e);
8331
8331
  }
8332
- (_b = (_a2 = state2.options).onTouchEnd) == null ? void 0 : _b.call(_a2, e);
8332
+ (_b2 = (_a2 = state2.options).onTouchEnd) == null ? void 0 : _b2.call(_a2, e);
8333
8333
  };
8334
8334
  const handleMouseDown = (e) => {
8335
- var _a2, _b;
8335
+ var _a2, _b2;
8336
8336
  if (!state2.options.enableMouse) return;
8337
8337
  if (Date.now() - state2.lastTouchEndTime < MOUSE_IGNORE_DURATION) return;
8338
8338
  e.preventDefault();
@@ -8342,25 +8342,25 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8342
8342
  state2.startY = e.clientY;
8343
8343
  state2.isLongPress = false;
8344
8344
  startLongPressTimer(e);
8345
- (_b = (_a2 = state2.options).onTouchStart) == null ? void 0 : _b.call(_a2, e);
8345
+ (_b2 = (_a2 = state2.options).onTouchStart) == null ? void 0 : _b2.call(_a2, e);
8346
8346
  };
8347
8347
  const handleMouseMove = (e) => {
8348
- var _a2, _b;
8348
+ var _a2, _b2;
8349
8349
  if (!state2.isMouseDown || !state2.options.enableMouse) return;
8350
8350
  if (state2.longPressTimer && exceedsThreshold(e.clientX, e.clientY)) {
8351
8351
  clearLongPressTimer();
8352
8352
  }
8353
- (_b = (_a2 = state2.options).onTouchMove) == null ? void 0 : _b.call(_a2, e);
8353
+ (_b2 = (_a2 = state2.options).onTouchMove) == null ? void 0 : _b2.call(_a2, e);
8354
8354
  };
8355
8355
  const handleMouseUp = (e) => {
8356
- var _a2, _b;
8356
+ var _a2, _b2;
8357
8357
  if (!state2.isMouseDown || !state2.options.enableMouse) return;
8358
8358
  state2.isMouseDown = false;
8359
8359
  clearLongPressTimer();
8360
8360
  if (!state2.isLongPress) {
8361
8361
  handleGestureEnd(e.clientX, e.clientY, e);
8362
8362
  }
8363
- (_b = (_a2 = state2.options).onTouchEnd) == null ? void 0 : _b.call(_a2, e);
8363
+ (_b2 = (_a2 = state2.options).onTouchEnd) == null ? void 0 : _b2.call(_a2, e);
8364
8364
  };
8365
8365
  state2.handlers = { touchStart: handleTouchStart, touchMove: handleTouchMove, touchEnd: handleTouchEnd, mouseDown: handleMouseDown, mouseMove: handleMouseMove, mouseUp: handleMouseUp };
8366
8366
  el.addEventListener("touchstart", handleTouchStart, { passive: false });
@@ -8393,10 +8393,10 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8393
8393
  }
8394
8394
  });
8395
8395
  function normalizeOptions$7(binding) {
8396
- var _a2, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l;
8396
+ var _a2, _b2, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l;
8397
8397
  return {
8398
8398
  swipeThreshold: (_a2 = binding == null ? void 0 : binding.swipeThreshold) != null ? _a2 : 30,
8399
- swipeTimeout: (_b = binding == null ? void 0 : binding.swipeTimeout) != null ? _b : 500,
8399
+ swipeTimeout: (_b2 = binding == null ? void 0 : binding.swipeTimeout) != null ? _b2 : 500,
8400
8400
  pinchThreshold: (_c = binding == null ? void 0 : binding.pinchThreshold) != null ? _c : 0.1,
8401
8401
  enableSwipe: (_d = binding == null ? void 0 : binding.enableSwipe) != null ? _d : true,
8402
8402
  enablePinch: (_e = binding == null ? void 0 : binding.enablePinch) != null ? _e : true,
@@ -8506,7 +8506,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8506
8506
  }
8507
8507
  }
8508
8508
  function normalizeOptions$6(binding) {
8509
- var _a2, _b, _c;
8509
+ var _a2, _b2, _c;
8510
8510
  if (binding === void 0 || binding === true) {
8511
8511
  return { position: "both", onInput: true, onBlur: true };
8512
8512
  }
@@ -8518,7 +8518,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8518
8518
  }
8519
8519
  return {
8520
8520
  position: (_a2 = binding.position) != null ? _a2 : "both",
8521
- onInput: (_b = binding.onInput) != null ? _b : true,
8521
+ onInput: (_b2 = binding.onInput) != null ? _b2 : true,
8522
8522
  onBlur: (_c = binding.onBlur) != null ? _c : true,
8523
8523
  chars: binding.chars
8524
8524
  };
@@ -8594,7 +8594,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8594
8594
  }
8595
8595
  }
8596
8596
  function normalizeOptions$5(binding) {
8597
- var _a2, _b, _c, _d, _e;
8597
+ var _a2, _b2, _c, _d, _e;
8598
8598
  if (typeof binding === "number") {
8599
8599
  return {
8600
8600
  length: binding,
@@ -8606,7 +8606,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8606
8606
  }
8607
8607
  return {
8608
8608
  length: (_a2 = binding == null ? void 0 : binding.length) != null ? _a2 : 100,
8609
- position: (_b = binding == null ? void 0 : binding.position) != null ? _b : "end",
8609
+ position: (_b2 = binding == null ? void 0 : binding.position) != null ? _b2 : "end",
8610
8610
  ellipsis: (_c = binding == null ? void 0 : binding.ellipsis) != null ? _c : "...",
8611
8611
  useCss: (_d = binding == null ? void 0 : binding.useCss) != null ? _d : false,
8612
8612
  showTitle: (_e = binding == null ? void 0 : binding.showTitle) != null ? _e : true
@@ -8727,7 +8727,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8727
8727
  (_a2 = options.onStart) == null ? void 0 : _a2.call(options);
8728
8728
  const text = options.text;
8729
8729
  function typeNextChar(index) {
8730
- var _a3, _b;
8730
+ var _a3, _b2;
8731
8731
  if (index >= text.length) {
8732
8732
  state2.isTyping = false;
8733
8733
  (_a3 = options.onComplete) == null ? void 0 : _a3.call(options);
@@ -8744,7 +8744,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8744
8744
  if (cursorElement) {
8745
8745
  el.appendChild(cursorElement);
8746
8746
  }
8747
- (_b = options.onType) == null ? void 0 : _b.call(options, char, index);
8747
+ (_b2 = options.onType) == null ? void 0 : _b2.call(options, char, index);
8748
8748
  state2.timeoutId = setTimeout(() => {
8749
8749
  typeNextChar(index + 1);
8750
8750
  }, options.speed || 50);
@@ -8799,7 +8799,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8799
8799
  return text.toUpperCase();
8800
8800
  }
8801
8801
  function normalizeOptions$3(binding) {
8802
- var _a2, _b;
8802
+ var _a2, _b2;
8803
8803
  if (binding === void 0 || binding === true) {
8804
8804
  return { first: false, onInput: true };
8805
8805
  }
@@ -8808,7 +8808,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8808
8808
  }
8809
8809
  return {
8810
8810
  first: (_a2 = binding.first) != null ? _a2 : false,
8811
- onInput: (_b = binding.onInput) != null ? _b : true
8811
+ onInput: (_b2 = binding.onInput) != null ? _b2 : true
8812
8812
  };
8813
8813
  }
8814
8814
  const vUppercase = defineDirective({
@@ -8892,7 +8892,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8892
8892
  return { startIndex, endIndex, offsetY };
8893
8893
  }
8894
8894
  function normalizeOptions$2(binding) {
8895
- var _a2, _b, _c, _d;
8895
+ var _a2, _b2, _c, _d;
8896
8896
  if (Array.isArray(binding)) {
8897
8897
  return {
8898
8898
  items: binding,
@@ -8905,7 +8905,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
8905
8905
  return {
8906
8906
  items: binding.items,
8907
8907
  itemSize: (_a2 = binding.itemSize) != null ? _a2 : 50,
8908
- height: (_b = binding.height) != null ? _b : 400,
8908
+ height: (_b2 = binding.height) != null ? _b2 : 400,
8909
8909
  overscan: (_c = binding.overscan) != null ? _c : 3,
8910
8910
  render: binding.render,
8911
8911
  keyField: (_d = binding.keyField) != null ? _d : "id",
@@ -9064,7 +9064,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
9064
9064
  useHidden: false
9065
9065
  },
9066
9066
  mounted(el, binding) {
9067
- var _a2, _b;
9067
+ var _a2, _b2;
9068
9068
  if (!isBrowser()) return;
9069
9069
  const options = normalizeOptions$1(binding.value);
9070
9070
  const originalDisplay = el.style.display;
@@ -9084,7 +9084,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
9084
9084
  };
9085
9085
  el.__visible = state2;
9086
9086
  on(el, "transitionend", state2.transitionEndHandler);
9087
- applyVisibility(el, state2, (_b = options.initial) != null ? _b : true);
9087
+ applyVisibility(el, state2, (_b2 = options.initial) != null ? _b2 : true);
9088
9088
  },
9089
9089
  updated(el, binding) {
9090
9090
  var _a2;
@@ -9203,14 +9203,14 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
9203
9203
  return el;
9204
9204
  }
9205
9205
  function normalizeOptions(binding) {
9206
- var _a2, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;
9206
+ var _a2, _b2, _c, _d, _e, _f, _g, _h, _i, _j, _k;
9207
9207
  if (typeof binding === "string") {
9208
9208
  return { content: binding };
9209
9209
  }
9210
9210
  return {
9211
9211
  content: binding.content,
9212
9212
  width: (_a2 = binding.width) != null ? _a2 : 300,
9213
- height: (_b = binding.height) != null ? _b : 200,
9213
+ height: (_b2 = binding.height) != null ? _b2 : 200,
9214
9214
  rotate: (_c = binding.rotate) != null ? _c : -22,
9215
9215
  fontSize: (_d = binding.fontSize) != null ? _d : 16,
9216
9216
  fontFamily: (_e = binding.fontFamily) != null ? _e : "sans-serif",
@@ -9339,7 +9339,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
9339
9339
  const isVisible = vue.ref((_a2 = vue.unref(options.visible)) != null ? _a2 : false);
9340
9340
  let overlayElement = null, originalOverflow = "";
9341
9341
  function show() {
9342
- var _a3, _b;
9342
+ var _a3, _b2;
9343
9343
  if (overlayElement || !isBrowser()) return;
9344
9344
  isVisible.value = true;
9345
9345
  overlayElement = createBlurOverlay(__spreadProps(__spreadValues({}, options), {
@@ -9352,7 +9352,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
9352
9352
  originalOverflow = document.body.style.overflow;
9353
9353
  document.body.style.overflow = "hidden";
9354
9354
  }
9355
- (_b = options.onShow) == null ? void 0 : _b.call(options);
9355
+ (_b2 = options.onShow) == null ? void 0 : _b2.call(options);
9356
9356
  }
9357
9357
  function hide() {
9358
9358
  var _a3;
@@ -9673,11 +9673,11 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
9673
9673
  currentElement.appendChild(wave);
9674
9674
  }
9675
9675
  function trigger(event) {
9676
- var _a2, _b;
9676
+ var _a2, _b2;
9677
9677
  if (!currentElement || vue.unref(disabled)) return;
9678
9678
  const rect = currentElement.getBoundingClientRect();
9679
9679
  const x = (_a2 = event == null ? void 0 : event.x) != null ? _a2 : rect.width / 2;
9680
- const y = (_b = event == null ? void 0 : event.y) != null ? _b : rect.height / 2;
9680
+ const y = (_b2 = event == null ? void 0 : event.y) != null ? _b2 : rect.height / 2;
9681
9681
  const wave = createWaveElement(x, y, currentElement, vue.unref(color), vue.unref(duration), sizeRatio);
9682
9682
  currentElement.appendChild(wave);
9683
9683
  }
@@ -10085,7 +10085,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
10085
10085
  const isAnimating = vue.ref(false);
10086
10086
  let currentElement = null, animationFrame = null, startTime = null, targetValue = vue.unref(options.value), startVal = currentValue.value;
10087
10087
  function animate2(timestamp) {
10088
- var _a3, _b;
10088
+ var _a3, _b2;
10089
10089
  if (!startTime) {
10090
10090
  startTime = timestamp;
10091
10091
  }
@@ -10110,7 +10110,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
10110
10110
  }
10111
10111
  isAnimating.value = false;
10112
10112
  animationFrame = null;
10113
- (_b = options.onComplete) == null ? void 0 : _b.call(options, targetValue);
10113
+ (_b2 = options.onComplete) == null ? void 0 : _b2.call(options, targetValue);
10114
10114
  }
10115
10115
  }
10116
10116
  function start() {
@@ -10238,7 +10238,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
10238
10238
  return debounce(fn, wait, options);
10239
10239
  }
10240
10240
  function getBoundary(boundary) {
10241
- var _a2, _b;
10241
+ var _a2, _b2;
10242
10242
  if (!boundary) return null;
10243
10243
  if (typeof boundary === "function") {
10244
10244
  const boundaryEl = boundary();
@@ -10246,7 +10246,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
10246
10246
  }
10247
10247
  if (typeof boundary === "string") {
10248
10248
  const boundaryEl = document.querySelector(boundary);
10249
- return (_b = boundaryEl == null ? void 0 : boundaryEl.getBoundingClientRect()) != null ? _b : null;
10249
+ return (_b2 = boundaryEl == null ? void 0 : boundaryEl.getBoundingClientRect()) != null ? _b2 : null;
10250
10250
  }
10251
10251
  return boundary.getBoundingClientRect();
10252
10252
  }
@@ -10672,7 +10672,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
10672
10672
  }
10673
10673
  function useExport(options) {
10674
10674
  function doExport(format) {
10675
- var _a2, _b, _c;
10675
+ var _a2, _b2, _c;
10676
10676
  if (((_a2 = options.onBeforeExport) == null ? void 0 : _a2.call(options)) === false) return;
10677
10677
  try {
10678
10678
  const data = vue.unref(options.data);
@@ -10695,7 +10695,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
10695
10695
  break;
10696
10696
  }
10697
10697
  downloadFile(content, filename, exportFormat);
10698
- (_b = options.onAfterExport) == null ? void 0 : _b.call(options);
10698
+ (_b2 = options.onAfterExport) == null ? void 0 : _b2.call(options);
10699
10699
  } catch (error2) {
10700
10700
  (_c = options.onError) == null ? void 0 : _c.call(options, error2);
10701
10701
  }
@@ -12981,7 +12981,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
12981
12981
  }
12982
12982
  function printInIframe(el, options) {
12983
12983
  return __async(this, null, function* () {
12984
- var _a2, _b, _c;
12984
+ var _a2, _b2, _c;
12985
12985
  const iframe = document.createElement("iframe");
12986
12986
  iframe.style.cssText = "position: absolute; top: -10000px; left: -10000px; width: 0; height: 0; border: none;";
12987
12987
  document.body.appendChild(iframe);
@@ -12997,7 +12997,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
12997
12997
  iframeDoc.close();
12998
12998
  yield waitForImages(iframeDoc);
12999
12999
  try {
13000
- (_b = iframe.contentWindow) == null ? void 0 : _b.focus();
13000
+ (_b2 = iframe.contentWindow) == null ? void 0 : _b2.focus();
13001
13001
  (_c = iframe.contentWindow) == null ? void 0 : _c.print();
13002
13002
  } catch (err) {
13003
13003
  console.error("[Directix] usePrint: Print failed", err);
@@ -13118,9 +13118,9 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
13118
13118
  document.head.appendChild(style);
13119
13119
  }
13120
13120
  function useProgress(options = {}) {
13121
- var _a2, _b, _c;
13121
+ var _a2, _b2, _c;
13122
13122
  const value = vue.ref((_a2 = vue.unref(options.value)) != null ? _a2 : 0);
13123
- const max = (_b = options.max) != null ? _b : 100;
13123
+ const max = (_b2 = options.max) != null ? _b2 : 100;
13124
13124
  const min = (_c = options.min) != null ? _c : 0;
13125
13125
  const percent = vue.computed(() => {
13126
13126
  const v = Math.max(min, Math.min(max, value.value));
@@ -13196,7 +13196,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
13196
13196
  currentElement.appendChild(container);
13197
13197
  }
13198
13198
  function updateProgress() {
13199
- var _a3, _b2;
13199
+ var _a3, _b3;
13200
13200
  if (!progressBar) return;
13201
13201
  if (!vue.unref(options.indeterminate)) {
13202
13202
  progressBar.style.width = `${percent.value}%`;
@@ -13205,7 +13205,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
13205
13205
  }
13206
13206
  (_a3 = options.onChange) == null ? void 0 : _a3.call(options, value.value, percent.value);
13207
13207
  if (percent.value >= 100) {
13208
- (_b2 = options.onComplete) == null ? void 0 : _b2.call(options);
13208
+ (_b3 = options.onComplete) == null ? void 0 : _b3.call(options);
13209
13209
  }
13210
13210
  }
13211
13211
  }
@@ -13535,11 +13535,11 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
13535
13535
  currentElement.appendChild(ripple);
13536
13536
  }
13537
13537
  function trigger(event) {
13538
- var _a2, _b;
13538
+ var _a2, _b2;
13539
13539
  if (!currentElement || vue.unref(disabled)) return;
13540
13540
  const rect = currentElement.getBoundingClientRect();
13541
13541
  const x = (_a2 = event == null ? void 0 : event.x) != null ? _a2 : rect.width / 2;
13542
- const y = (_b = event == null ? void 0 : event.y) != null ? _b : rect.height / 2;
13542
+ const y = (_b2 = event == null ? void 0 : event.y) != null ? _b2 : rect.height / 2;
13543
13543
  const ripple = createRippleElement(
13544
13544
  x,
13545
13545
  y,
@@ -13699,14 +13699,14 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
13699
13699
  bind
13700
13700
  };
13701
13701
  }
13702
- const DEFAULT_ALLOWED_TAGS = ["b", "i", "u", "strong", "em", "br", "p", "span", "div"];
13703
- const DEFAULT_ALLOWED_ATTRIBUTES = ["title", "alt", "href", "src"];
13704
- const DANGEROUS_TAGS = ["script", "iframe", "object", "embed", "form", "input", "style", "link", "meta", "base"];
13705
- const DANGEROUS_ATTRIBUTES = ["onclick", "onerror", "onload", "onmouseover", "onfocus", "onblur", "onchange", "onsubmit"];
13702
+ const DEFAULT_ALLOWED_TAGS$1 = ["b", "i", "u", "strong", "em", "br", "p", "span", "div"];
13703
+ const DEFAULT_ALLOWED_ATTRIBUTES$1 = ["title", "alt", "href", "src"];
13704
+ const DANGEROUS_TAGS$1 = ["script", "iframe", "object", "embed", "form", "input", "style", "link", "meta", "base"];
13705
+ const DANGEROUS_ATTRIBUTES$1 = ["onclick", "onerror", "onload", "onmouseover", "onfocus", "onblur", "onchange", "onsubmit"];
13706
13706
  function useSanitize(options = {}) {
13707
13707
  const {
13708
- allowedTags = DEFAULT_ALLOWED_TAGS,
13709
- allowedAttributes = DEFAULT_ALLOWED_ATTRIBUTES,
13708
+ allowedTags = DEFAULT_ALLOWED_TAGS$1,
13709
+ allowedAttributes = DEFAULT_ALLOWED_ATTRIBUTES$1,
13710
13710
  allowDataUrls = false,
13711
13711
  allowStyles = false,
13712
13712
  allowClass = false,
@@ -13721,7 +13721,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
13721
13721
  if (!isBrowser()) return html;
13722
13722
  const temp = document.createElement("div");
13723
13723
  temp.innerHTML = html;
13724
- for (const tag of DANGEROUS_TAGS) {
13724
+ for (const tag of DANGEROUS_TAGS$1) {
13725
13725
  const elements = temp.getElementsByTagName(tag);
13726
13726
  while (elements.length > 0) {
13727
13727
  (_a2 = elements[0].parentNode) == null ? void 0 : _a2.removeChild(elements[0]);
@@ -13735,7 +13735,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
13735
13735
  (_a3 = el.parentNode) == null ? void 0 : _a3.replaceChild(text, el);
13736
13736
  return;
13737
13737
  }
13738
- for (const attr of DANGEROUS_ATTRIBUTES) {
13738
+ for (const attr of DANGEROUS_ATTRIBUTES$1) {
13739
13739
  el.removeAttribute(attr);
13740
13740
  }
13741
13741
  const href = el.getAttribute("href");
@@ -13996,7 +13996,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
13996
13996
  updateSkeleton();
13997
13997
  }
13998
13998
  function updateSkeleton() {
13999
- var _a3, _b, _c;
13999
+ var _a3, _b2, _c;
14000
14000
  if (!currentElement) return;
14001
14001
  if (isLoading.value) {
14002
14002
  originalDisplay = currentElement.style.display || getComputedStyle(currentElement).display;
@@ -14004,7 +14004,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
14004
14004
  if (!skeletonElement) {
14005
14005
  skeletonElement = createSkeletonElement(__spreadProps(__spreadValues({}, options), {
14006
14006
  width: (_a3 = options.width) != null ? _a3 : currentElement.offsetWidth,
14007
- height: (_b = options.height) != null ? _b : currentElement.offsetHeight
14007
+ height: (_b2 = options.height) != null ? _b2 : currentElement.offsetHeight
14008
14008
  }));
14009
14009
  }
14010
14010
  if (!skeletonElement.parentNode) {
@@ -14841,7 +14841,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
14841
14841
  }
14842
14842
  }
14843
14843
  function typeCharacter() {
14844
- var _a2, _b;
14844
+ var _a2, _b2;
14845
14845
  const text = vue.unref(options.text);
14846
14846
  if (currentIndex >= text.length) {
14847
14847
  isTyping.value = false;
@@ -14857,7 +14857,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
14857
14857
  displayedText.value += char;
14858
14858
  currentIndex++;
14859
14859
  updateElement();
14860
- (_b = options.onType) == null ? void 0 : _b.call(options, char, currentIndex - 1);
14860
+ (_b2 = options.onType) == null ? void 0 : _b2.call(options, char, currentIndex - 1);
14861
14861
  timeoutId = setTimeout(typeCharacter, options.speed || 50);
14862
14862
  }
14863
14863
  function startTyping2() {
@@ -15335,11 +15335,11 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
15335
15335
  };
15336
15336
  }
15337
15337
  function createWatermarkUrl(content, options = {}) {
15338
- var _a2, _b, _c, _d, _e;
15338
+ var _a2, _b2, _c, _d, _e;
15339
15339
  const canvas = createWatermarkCanvas({
15340
15340
  content,
15341
15341
  width: (_a2 = options.width) != null ? _a2 : 300,
15342
- height: (_b = options.height) != null ? _b : 200,
15342
+ height: (_b2 = options.height) != null ? _b2 : 200,
15343
15343
  fontSize: (_c = options.fontSize) != null ? _c : 16,
15344
15344
  fontFamily: "sans-serif",
15345
15345
  fontWeight: "normal",
@@ -15771,6 +15771,1734 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
15771
15771
  }
15772
15772
  });
15773
15773
  }
15774
+ function applyAriaAttributes(el, config) {
15775
+ clearAriaAttributes(el);
15776
+ if (config.role) {
15777
+ el.setAttribute("role", config.role);
15778
+ }
15779
+ if (config.ariaExpanded !== void 0) {
15780
+ el.setAttribute("aria-expanded", String(config.ariaExpanded));
15781
+ }
15782
+ if (config.ariaSelected !== void 0) {
15783
+ el.setAttribute("aria-selected", String(config.ariaSelected));
15784
+ }
15785
+ if (config.ariaChecked !== void 0) {
15786
+ el.setAttribute("aria-checked", String(config.ariaChecked));
15787
+ }
15788
+ if (config.ariaDisabled !== void 0) {
15789
+ el.setAttribute("aria-disabled", String(config.ariaDisabled));
15790
+ if (config.ariaDisabled) {
15791
+ el.setAttribute("tabindex", "-1");
15792
+ }
15793
+ }
15794
+ if (config.ariaHidden !== void 0) {
15795
+ el.setAttribute("aria-hidden", String(config.ariaHidden));
15796
+ }
15797
+ if (config.ariaBusy !== void 0) {
15798
+ el.setAttribute("aria-busy", String(config.ariaBusy));
15799
+ }
15800
+ if (config.ariaPressed !== void 0) {
15801
+ el.setAttribute("aria-pressed", String(config.ariaPressed));
15802
+ }
15803
+ if (config.ariaCurrent !== void 0) {
15804
+ el.setAttribute("aria-current", typeof config.ariaCurrent === "boolean" ? String(config.ariaCurrent) : config.ariaCurrent);
15805
+ }
15806
+ if (config.ariaLabel) {
15807
+ el.setAttribute("aria-label", config.ariaLabel);
15808
+ }
15809
+ if (config.ariaLabelledBy) {
15810
+ el.setAttribute("aria-labelledby", config.ariaLabelledBy);
15811
+ }
15812
+ if (config.ariaDescribedBy) {
15813
+ el.setAttribute("aria-describedby", config.ariaDescribedBy);
15814
+ }
15815
+ if (config.ariaControls) {
15816
+ el.setAttribute("aria-controls", config.ariaControls);
15817
+ }
15818
+ if (config.ariaOwns) {
15819
+ el.setAttribute("aria-owns", config.ariaOwns);
15820
+ }
15821
+ if (config.ariaHasPopup !== void 0) {
15822
+ const value = typeof config.ariaHasPopup === "boolean" ? "true" : config.ariaHasPopup;
15823
+ el.setAttribute("aria-haspopup", value);
15824
+ }
15825
+ if (config.ariaAutoComplete) {
15826
+ el.setAttribute("aria-autocomplete", config.ariaAutoComplete);
15827
+ }
15828
+ if (config.ariaLive) {
15829
+ el.setAttribute("aria-live", config.ariaLive);
15830
+ }
15831
+ if (config.ariaAtomic !== void 0) {
15832
+ el.setAttribute("aria-atomic", String(config.ariaAtomic));
15833
+ }
15834
+ if (config.ariaRelevant) {
15835
+ el.setAttribute("aria-relevant", config.ariaRelevant);
15836
+ }
15837
+ if (config.ariaValueNow !== void 0) {
15838
+ el.setAttribute("aria-valuenow", String(config.ariaValueNow));
15839
+ }
15840
+ if (config.ariaValueMin !== void 0) {
15841
+ el.setAttribute("aria-valuemin", String(config.ariaValueMin));
15842
+ }
15843
+ if (config.ariaValueMax !== void 0) {
15844
+ el.setAttribute("aria-valuemax", String(config.ariaValueMax));
15845
+ }
15846
+ if (config.ariaValueText) {
15847
+ el.setAttribute("aria-valuetext", config.ariaValueText);
15848
+ }
15849
+ if (config.ariaPlaceholder) {
15850
+ el.setAttribute("aria-placeholder", config.ariaPlaceholder);
15851
+ }
15852
+ if (config.ariaRequired !== void 0) {
15853
+ el.setAttribute("aria-required", String(config.ariaRequired));
15854
+ }
15855
+ if (config.ariaReadonly !== void 0) {
15856
+ el.setAttribute("aria-readonly", String(config.ariaReadonly));
15857
+ }
15858
+ if (config.ariaModal !== void 0) {
15859
+ el.setAttribute("aria-modal", String(config.ariaModal));
15860
+ }
15861
+ if (config.tabIndex !== void 0) {
15862
+ el.setAttribute("tabindex", String(config.tabIndex));
15863
+ }
15864
+ }
15865
+ function clearAriaAttributes(el) {
15866
+ const ariaAttrs = Array.from(el.attributes).filter((attr) => attr.name.startsWith("aria-") || attr.name === "role");
15867
+ ariaAttrs.forEach((attr) => el.removeAttribute(attr.name));
15868
+ }
15869
+ function generateAriaId(prefix = "directix-aria") {
15870
+ return `${prefix}-${Math.random().toString(36).substring(2, 10)}`;
15871
+ }
15872
+ let announcerElement = null, announcerId = null;
15873
+ function ensureAnnouncer() {
15874
+ if (announcerElement && document.getElementById(announcerId || "")) {
15875
+ return announcerElement;
15876
+ }
15877
+ announcerId = "directix-sr-announcer";
15878
+ announcerElement = document.createElement("div");
15879
+ announcerElement.id = announcerId;
15880
+ announcerElement.setAttribute("aria-live", "polite");
15881
+ announcerElement.setAttribute("aria-atomic", "true");
15882
+ announcerElement.setAttribute(
15883
+ "style",
15884
+ "position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;"
15885
+ );
15886
+ document.body.appendChild(announcerElement);
15887
+ return announcerElement;
15888
+ }
15889
+ function announce(message, options = {}) {
15890
+ if (!isBrowser()) return;
15891
+ const { priority = "polite", timeout = 1e3, clear = true } = options;
15892
+ const announcer = ensureAnnouncer();
15893
+ announcer.setAttribute("aria-live", priority);
15894
+ announcer.textContent = "";
15895
+ requestAnimationFrame(() => {
15896
+ announcer.textContent = message;
15897
+ if (clear) {
15898
+ setTimeout(() => {
15899
+ if (announcer.textContent === message) {
15900
+ announcer.textContent = "";
15901
+ }
15902
+ }, timeout);
15903
+ }
15904
+ });
15905
+ }
15906
+ function clearAnnouncer() {
15907
+ if (announcerElement) {
15908
+ announcerElement.textContent = "";
15909
+ }
15910
+ }
15911
+ const DEFAULT_NEXT_KEYS = ["ArrowDown", "ArrowRight"];
15912
+ const DEFAULT_PREV_KEYS = ["ArrowUp", "ArrowLeft"];
15913
+ const DEFAULT_SELECT_KEYS = ["Enter", " "];
15914
+ const DEFAULT_CLOSE_KEYS = ["Escape"];
15915
+ const DEFAULT_HOME_KEYS = ["Home"];
15916
+ const DEFAULT_END_KEYS = ["End"];
15917
+ function useKeyboardNavigation(options = {}) {
15918
+ const {
15919
+ nextKeys = DEFAULT_NEXT_KEYS,
15920
+ prevKeys = DEFAULT_PREV_KEYS,
15921
+ selectKeys = DEFAULT_SELECT_KEYS,
15922
+ closeKeys = DEFAULT_CLOSE_KEYS,
15923
+ homeKeys = DEFAULT_HOME_KEYS,
15924
+ endKeys = DEFAULT_END_KEYS,
15925
+ focusTrap = false,
15926
+ returnFocus = true,
15927
+ mode: _mode = "linear",
15928
+ loop = true,
15929
+ rovingTabindex = false
15930
+ } = options;
15931
+ const focusedIndex = vue.ref(0);
15932
+ let items = [], triggerElement = null, cleanup2 = null;
15933
+ function getFocusables() {
15934
+ return items.filter((item) => !item.hasAttribute("disabled") && item.getAttribute("aria-disabled") !== "true");
15935
+ }
15936
+ function focusIndex(index) {
15937
+ const focusables = getFocusables();
15938
+ if (focusables.length === 0) return;
15939
+ let newIndex = index;
15940
+ if (newIndex < 0) {
15941
+ newIndex = loop ? focusables.length - 1 : 0;
15942
+ } else if (newIndex >= focusables.length) {
15943
+ newIndex = loop ? 0 : focusables.length - 1;
15944
+ }
15945
+ const target = focusables[newIndex];
15946
+ if (target) {
15947
+ target.focus();
15948
+ if (rovingTabindex) {
15949
+ focusables.forEach((item, i) => {
15950
+ item.setAttribute("tabindex", i === newIndex ? "0" : "-1");
15951
+ });
15952
+ }
15953
+ focusedIndex.value = newIndex;
15954
+ }
15955
+ }
15956
+ function focusNext() {
15957
+ focusIndex(focusedIndex.value + 1);
15958
+ }
15959
+ function focusPrev() {
15960
+ focusIndex(focusedIndex.value - 1);
15961
+ }
15962
+ function focusFirst() {
15963
+ focusIndex(0);
15964
+ }
15965
+ function focusLast() {
15966
+ focusIndex(getFocusables().length - 1);
15967
+ }
15968
+ function handleKeyDown(e) {
15969
+ var _a2;
15970
+ const isModified = e.altKey || e.ctrlKey || e.metaKey;
15971
+ if (isModified) return;
15972
+ if (focusTrap && e.key === "Tab") {
15973
+ const focusables = getFocusables();
15974
+ if (focusables.length === 0) return;
15975
+ e.preventDefault();
15976
+ if (e.shiftKey) {
15977
+ focusPrev();
15978
+ } else {
15979
+ focusNext();
15980
+ }
15981
+ return;
15982
+ }
15983
+ if (nextKeys.includes(e.key)) {
15984
+ e.preventDefault();
15985
+ focusNext();
15986
+ } else if (prevKeys.includes(e.key)) {
15987
+ e.preventDefault();
15988
+ focusPrev();
15989
+ } else if (homeKeys.includes(e.key)) {
15990
+ e.preventDefault();
15991
+ focusFirst();
15992
+ } else if (endKeys.includes(e.key)) {
15993
+ e.preventDefault();
15994
+ focusLast();
15995
+ } else if (selectKeys.includes(e.key)) {
15996
+ e.preventDefault();
15997
+ (_a2 = items[focusedIndex.value]) == null ? void 0 : _a2.click();
15998
+ } else if (closeKeys.includes(e.key)) {
15999
+ e.preventDefault();
16000
+ if (returnFocus && triggerElement) {
16001
+ triggerElement.focus();
16002
+ }
16003
+ }
16004
+ }
16005
+ function bind(el, itemElements) {
16006
+ cleanup2 == null ? void 0 : cleanup2();
16007
+ items = itemElements;
16008
+ triggerElement = document.activeElement;
16009
+ el.addEventListener("keydown", handleKeyDown);
16010
+ if (rovingTabindex && items.length > 0) {
16011
+ items.forEach((item, i) => {
16012
+ item.setAttribute("tabindex", i === 0 ? "0" : "-1");
16013
+ });
16014
+ }
16015
+ if (items.length > 0) {
16016
+ focusIndex(0);
16017
+ }
16018
+ cleanup2 = () => {
16019
+ el.removeEventListener("keydown", handleKeyDown);
16020
+ items = [];
16021
+ };
16022
+ return cleanup2;
16023
+ }
16024
+ vue.onUnmounted(() => {
16025
+ cleanup2 == null ? void 0 : cleanup2();
16026
+ });
16027
+ return {
16028
+ focusedIndex: vue.readonly(focusedIndex),
16029
+ bind,
16030
+ focusIndex,
16031
+ focusNext,
16032
+ focusPrev,
16033
+ focusFirst,
16034
+ focusLast
16035
+ };
16036
+ }
16037
+ function useFocusTrap(container, options = {}) {
16038
+ const {
16039
+ initialFocus,
16040
+ allowOutsideClick = false,
16041
+ escapeDeactivates = true,
16042
+ onActivate,
16043
+ onDeactivate
16044
+ } = options;
16045
+ const isActive = vue.ref(false);
16046
+ let lastFocusedElement = null;
16047
+ function getFocusableElements() {
16048
+ const el = container.value;
16049
+ if (!el) return [];
16050
+ const selector = [
16051
+ "a[href]",
16052
+ "button:not([disabled])",
16053
+ "textarea:not([disabled])",
16054
+ "input:not([disabled])",
16055
+ "select:not([disabled])",
16056
+ '[tabindex]:not([tabindex="-1"])'
16057
+ ].join(", ");
16058
+ return Array.from(el.querySelectorAll(selector)).filter((item) => !item.hasAttribute("aria-hidden"));
16059
+ }
16060
+ function handleKeyDown(e) {
16061
+ if (!isActive.value) return;
16062
+ if (escapeDeactivates && e.key === "Escape") {
16063
+ e.preventDefault();
16064
+ deactivate();
16065
+ return;
16066
+ }
16067
+ if (e.key !== "Tab") return;
16068
+ const el = container.value;
16069
+ if (!el) return;
16070
+ const focusables = getFocusableElements();
16071
+ if (focusables.length === 0) return;
16072
+ const firstFocusable = focusables[0];
16073
+ const lastFocusable = focusables[focusables.length - 1];
16074
+ const currentElement = document.activeElement;
16075
+ if (e.shiftKey) {
16076
+ if (currentElement === firstFocusable || !el.contains(currentElement)) {
16077
+ e.preventDefault();
16078
+ lastFocusable.focus();
16079
+ }
16080
+ } else {
16081
+ if (currentElement === lastFocusable || !el.contains(currentElement)) {
16082
+ e.preventDefault();
16083
+ firstFocusable.focus();
16084
+ }
16085
+ }
16086
+ }
16087
+ function handleOutsideClick(event) {
16088
+ if (!isActive.value) return;
16089
+ if (!container.value) return;
16090
+ if (typeof allowOutsideClick === "boolean" && !allowOutsideClick) {
16091
+ event.preventDefault();
16092
+ return;
16093
+ }
16094
+ if (typeof allowOutsideClick === "function" && !allowOutsideClick(event)) {
16095
+ event.preventDefault();
16096
+ }
16097
+ }
16098
+ function activate() {
16099
+ var _a2;
16100
+ if (isActive.value) return;
16101
+ lastFocusedElement = document.activeElement;
16102
+ if (initialFocus) {
16103
+ let initialEl = null;
16104
+ if (typeof initialFocus === "function") {
16105
+ initialEl = initialFocus();
16106
+ } else if (typeof initialFocus === "string") {
16107
+ initialEl = ((_a2 = container.value) == null ? void 0 : _a2.querySelector(initialFocus)) || null;
16108
+ } else {
16109
+ initialEl = initialFocus;
16110
+ }
16111
+ initialEl == null ? void 0 : initialEl.focus();
16112
+ } else {
16113
+ const focusables = getFocusableElements();
16114
+ if (focusables.length > 0) {
16115
+ focusables[0].focus();
16116
+ }
16117
+ }
16118
+ document.addEventListener("keydown", handleKeyDown);
16119
+ document.addEventListener("mousedown", handleOutsideClick);
16120
+ document.addEventListener("touchstart", handleOutsideClick);
16121
+ isActive.value = true;
16122
+ onActivate == null ? void 0 : onActivate();
16123
+ }
16124
+ function deactivate() {
16125
+ if (!isActive.value) return;
16126
+ document.removeEventListener("keydown", handleKeyDown);
16127
+ document.removeEventListener("mousedown", handleOutsideClick);
16128
+ document.removeEventListener("touchstart", handleOutsideClick);
16129
+ if (lastFocusedElement && lastFocusedElement.focus) {
16130
+ lastFocusedElement.focus();
16131
+ }
16132
+ isActive.value = false;
16133
+ onDeactivate == null ? void 0 : onDeactivate();
16134
+ }
16135
+ vue.onUnmounted(() => {
16136
+ deactivate();
16137
+ });
16138
+ return {
16139
+ activate,
16140
+ deactivate,
16141
+ isActive: vue.readonly(isActive)
16142
+ };
16143
+ }
16144
+ function getAutoAriaConfig(options) {
16145
+ const { type, label, expanded, disabled, relatedId } = options;
16146
+ const configs = {
16147
+ tooltip: {
16148
+ role: "tooltip",
16149
+ ariaHidden: expanded === void 0 ? true : !expanded
16150
+ },
16151
+ menu: {
16152
+ role: "menu",
16153
+ ariaLabel: label,
16154
+ ariaExpanded: expanded,
16155
+ ariaDisabled: disabled
16156
+ },
16157
+ dialog: {
16158
+ role: "dialog",
16159
+ ariaLabel: label,
16160
+ ariaModal: true
16161
+ },
16162
+ popover: {
16163
+ role: "region",
16164
+ ariaLabel: label,
16165
+ ariaExpanded: expanded
16166
+ },
16167
+ dropdown: {
16168
+ role: "listbox",
16169
+ ariaLabel: label,
16170
+ ariaExpanded: expanded
16171
+ },
16172
+ modal: {
16173
+ role: "dialog",
16174
+ ariaModal: true,
16175
+ ariaLabel: label
16176
+ },
16177
+ alert: {
16178
+ role: "alert",
16179
+ ariaLive: "assertive",
16180
+ ariaAtomic: true
16181
+ },
16182
+ region: {
16183
+ role: "region",
16184
+ ariaLabel: label
16185
+ }
16186
+ };
16187
+ const config = __spreadValues({}, configs[type] || {});
16188
+ if (relatedId) {
16189
+ if (type === "tooltip") {
16190
+ config.ariaDescribedBy = relatedId;
16191
+ } else {
16192
+ config.ariaControls = relatedId;
16193
+ }
16194
+ }
16195
+ return config;
16196
+ }
16197
+ const DEFAULT_THRESHOLDS = {
16198
+ tap: 10,
16199
+ longPress: 500,
16200
+ swipe: 30,
16201
+ pinch: 0.1,
16202
+ rotate: 5,
16203
+ doubleTap: 300,
16204
+ swipeVelocity: 0.3
16205
+ };
16206
+ function triggerHaptic(type = "light") {
16207
+ if (!isBrowser()) return;
16208
+ const nav = navigator;
16209
+ if (nav.vibrate) {
16210
+ const patterns = {
16211
+ light: 10,
16212
+ medium: 20,
16213
+ heavy: 30,
16214
+ selection: [10, 50, 10]
16215
+ };
16216
+ nav.vibrate(patterns[type]);
16217
+ }
16218
+ }
16219
+ function applyVisualFeedback(element, options = {}) {
16220
+ const {
16221
+ visualClass = "directix-touch-active",
16222
+ visualDuration = 150
16223
+ } = options;
16224
+ element.classList.add(visualClass);
16225
+ const timer = setTimeout(() => {
16226
+ element.classList.remove(visualClass);
16227
+ }, visualDuration);
16228
+ return () => {
16229
+ clearTimeout(timer);
16230
+ element.classList.remove(visualClass);
16231
+ };
16232
+ }
16233
+ function calculateVelocity(startX, startY, endX, endY, duration) {
16234
+ if (duration === 0) return 0;
16235
+ const distance = Math.sqrt(__pow(endX - startX, 2) + __pow(endY - startY, 2));
16236
+ return distance / duration;
16237
+ }
16238
+ function isEdgePoint(x, y, edgeSize = 20) {
16239
+ if (!isBrowser()) return { isEdge: false };
16240
+ const width = window.innerWidth;
16241
+ const height = window.innerHeight;
16242
+ if (x <= edgeSize) return { isEdge: true, edge: "left" };
16243
+ if (x >= width - edgeSize) return { isEdge: true, edge: "right" };
16244
+ if (y <= edgeSize) return { isEdge: true, edge: "top" };
16245
+ if (y >= height - edgeSize) return { isEdge: true, edge: "bottom" };
16246
+ return { isEdge: false };
16247
+ }
16248
+ function useEnhancedTouch(options = {}) {
16249
+ const {
16250
+ thresholds: userThresholds = {},
16251
+ feedback = {},
16252
+ debounce: debounce2 = 0,
16253
+ throttle: throttle2 = 16,
16254
+ passive = true,
16255
+ disabled = false,
16256
+ onTap,
16257
+ onDoubleTap,
16258
+ onLongPress,
16259
+ onSwipe,
16260
+ onSwipeLeft,
16261
+ onSwipeRight,
16262
+ onSwipeUp,
16263
+ onSwipeDown,
16264
+ onPan,
16265
+ onPinch,
16266
+ onPinchIn,
16267
+ onPinchOut,
16268
+ onRotate,
16269
+ onTwoFingerTap,
16270
+ onEdgeSwipe
16271
+ } = options;
16272
+ const thresholds = __spreadValues(__spreadValues({}, DEFAULT_THRESHOLDS), userThresholds);
16273
+ const activeGesture = vue.ref(null);
16274
+ const isTouching = vue.ref(false);
16275
+ let currentElement = null, startX = 0, startY = 0, startTime = 0, lastTapTime = 0, lastPanTime = 0, longPressTimer = null, initialPinchDistance = 0, initialAngle = 0, removeVisualFeedback = null, lastGestureTime = 0;
16276
+ function getTouchCenter(touches) {
16277
+ let x = 0, y = 0;
16278
+ for (let i = 0; i < touches.length; i++) {
16279
+ x += touches[i].clientX;
16280
+ y += touches[i].clientY;
16281
+ }
16282
+ return { x: x / touches.length, y: y / touches.length };
16283
+ }
16284
+ function getDistance2(t1, t2) {
16285
+ return Math.sqrt(__pow(t1.clientX - t2.clientX, 2) + __pow(t1.clientY - t2.clientY, 2));
16286
+ }
16287
+ function getAngle2(t1, t2) {
16288
+ return Math.atan2(t2.clientY - t1.clientY, t2.clientX - t1.clientX) * (180 / Math.PI);
16289
+ }
16290
+ function shouldProcessGesture() {
16291
+ if (typeof disabled === "boolean" ? disabled : disabled.value) return false;
16292
+ if (debounce2 > 0 && Date.now() - lastGestureTime < debounce2) return false;
16293
+ return true;
16294
+ }
16295
+ function handleTouchStart(e) {
16296
+ if (!shouldProcessGesture()) return;
16297
+ isTouching.value = true;
16298
+ startTime = Date.now();
16299
+ activeGesture.value = null;
16300
+ if (feedback.haptic) {
16301
+ triggerHaptic("light");
16302
+ }
16303
+ if (e.touches.length === 1) {
16304
+ startX = e.touches[0].clientX;
16305
+ startY = e.touches[0].clientY;
16306
+ if (onLongPress) {
16307
+ longPressTimer = setTimeout(() => {
16308
+ if (!activeGesture.value) {
16309
+ activeGesture.value = "longPress";
16310
+ lastGestureTime = Date.now();
16311
+ onLongPress({
16312
+ type: "longPress",
16313
+ center: { x: startX, y: startY },
16314
+ event: e,
16315
+ duration: Date.now() - startTime
16316
+ });
16317
+ if (feedback.haptic) triggerHaptic("medium");
16318
+ }
16319
+ }, thresholds.longPress);
16320
+ }
16321
+ } else if (e.touches.length === 2) {
16322
+ if (longPressTimer) {
16323
+ clearTimeout(longPressTimer);
16324
+ longPressTimer = null;
16325
+ }
16326
+ initialPinchDistance = getDistance2(e.touches[0], e.touches[1]);
16327
+ initialAngle = getAngle2(e.touches[0], e.touches[1]);
16328
+ }
16329
+ }
16330
+ function handleTouchMove(e) {
16331
+ if (!shouldProcessGesture()) return;
16332
+ if (longPressTimer) {
16333
+ clearTimeout(longPressTimer);
16334
+ longPressTimer = null;
16335
+ }
16336
+ if (e.touches.length === 1) {
16337
+ const currentX = e.touches[0].clientX;
16338
+ const currentY = e.touches[0].clientY;
16339
+ if (onPan) {
16340
+ const now = Date.now();
16341
+ if (now - lastPanTime >= throttle2) {
16342
+ lastPanTime = now;
16343
+ const deltaX = currentX - startX;
16344
+ const deltaY = currentY - startY;
16345
+ const distance = Math.sqrt(deltaX * deltaX + deltaY * deltaY);
16346
+ if (distance > thresholds.tap) {
16347
+ activeGesture.value = "pan";
16348
+ onPan({
16349
+ type: "pan",
16350
+ distance,
16351
+ angle: Math.atan2(deltaY, deltaX) * (180 / Math.PI),
16352
+ center: { x: currentX, y: currentY },
16353
+ event: e
16354
+ });
16355
+ }
16356
+ }
16357
+ }
16358
+ } else if (e.touches.length === 2) {
16359
+ const currentDistance = getDistance2(e.touches[0], e.touches[1]);
16360
+ const currentAngle = getAngle2(e.touches[0], e.touches[1]);
16361
+ if (onPinch && initialPinchDistance > 0) {
16362
+ const scale = currentDistance / initialPinchDistance;
16363
+ const deltaScale = Math.abs(scale - 1);
16364
+ if (deltaScale > thresholds.pinch) {
16365
+ activeGesture.value = "pinch";
16366
+ onPinch({
16367
+ type: "pinch",
16368
+ scale,
16369
+ center: getTouchCenter(e.touches),
16370
+ event: e
16371
+ });
16372
+ if (scale < 1 && onPinchIn) {
16373
+ onPinchIn({
16374
+ type: "pinchIn",
16375
+ scale,
16376
+ center: getTouchCenter(e.touches),
16377
+ event: e
16378
+ });
16379
+ } else if (scale > 1 && onPinchOut) {
16380
+ onPinchOut({
16381
+ type: "pinchOut",
16382
+ scale,
16383
+ center: getTouchCenter(e.touches),
16384
+ event: e
16385
+ });
16386
+ }
16387
+ }
16388
+ }
16389
+ if (onRotate) {
16390
+ const rotation = currentAngle - initialAngle;
16391
+ if (Math.abs(rotation) > thresholds.rotate) {
16392
+ activeGesture.value = "rotate";
16393
+ onRotate({
16394
+ type: "rotate",
16395
+ rotation,
16396
+ center: getTouchCenter(e.touches),
16397
+ event: e
16398
+ });
16399
+ }
16400
+ }
16401
+ }
16402
+ }
16403
+ function handleTouchEnd(e) {
16404
+ var _a2, _b2, _c, _d;
16405
+ if (!shouldProcessGesture()) return;
16406
+ isTouching.value = false;
16407
+ if (longPressTimer) {
16408
+ clearTimeout(longPressTimer);
16409
+ longPressTimer = null;
16410
+ }
16411
+ const duration = Date.now() - startTime;
16412
+ const endX = (_b2 = (_a2 = e.changedTouches[0]) == null ? void 0 : _a2.clientX) != null ? _b2 : startX;
16413
+ const endY = (_d = (_c = e.changedTouches[0]) == null ? void 0 : _c.clientY) != null ? _d : startY;
16414
+ const deltaX = endX - startX;
16415
+ const deltaY = endY - startY;
16416
+ const distance = Math.sqrt(deltaX * deltaX + deltaY * deltaY);
16417
+ const velocity = calculateVelocity(startX, startY, endX, endY, duration);
16418
+ if (e.touches.length === 0 && e.changedTouches.length === 2 && onTwoFingerTap) {
16419
+ const twoFingerDistance = getDistance2(e.changedTouches[0], e.changedTouches[1]);
16420
+ if (twoFingerDistance < 50) {
16421
+ activeGesture.value = "twoFingerTap";
16422
+ onTwoFingerTap({
16423
+ type: "twoFingerTap",
16424
+ center: getTouchCenter(e.changedTouches),
16425
+ event: e
16426
+ });
16427
+ }
16428
+ }
16429
+ if (e.changedTouches.length === 1) {
16430
+ if (distance >= thresholds.swipe) {
16431
+ let direction;
16432
+ if (Math.abs(deltaX) > Math.abs(deltaY)) {
16433
+ direction = deltaX > 0 ? "right" : "left";
16434
+ } else {
16435
+ direction = deltaY > 0 ? "down" : "up";
16436
+ }
16437
+ const edge = isEdgePoint(startX, startY);
16438
+ if (edge.isEdge && onEdgeSwipe) {
16439
+ activeGesture.value = "edgeSwipe";
16440
+ onEdgeSwipe({
16441
+ type: "edgeSwipe",
16442
+ direction,
16443
+ distance,
16444
+ velocity,
16445
+ center: { x: endX, y: endY },
16446
+ event: e
16447
+ });
16448
+ }
16449
+ if (!activeGesture.value) {
16450
+ activeGesture.value = "swipe";
16451
+ const swipeEvent = {
16452
+ type: "swipe",
16453
+ direction,
16454
+ distance,
16455
+ velocity,
16456
+ angle: Math.atan2(deltaY, deltaX) * (180 / Math.PI),
16457
+ center: { x: endX, y: endY },
16458
+ event: e,
16459
+ duration
16460
+ };
16461
+ onSwipe == null ? void 0 : onSwipe(swipeEvent);
16462
+ if (direction === "left") onSwipeLeft == null ? void 0 : onSwipeLeft(swipeEvent);
16463
+ if (direction === "right") onSwipeRight == null ? void 0 : onSwipeRight(swipeEvent);
16464
+ if (direction === "up") onSwipeUp == null ? void 0 : onSwipeUp(swipeEvent);
16465
+ if (direction === "down") onSwipeDown == null ? void 0 : onSwipeDown(swipeEvent);
16466
+ if (feedback.haptic) triggerHaptic("light");
16467
+ }
16468
+ } else if (distance < thresholds.tap && duration < 300) {
16469
+ const now = Date.now();
16470
+ const timeSinceLastTap = now - lastTapTime;
16471
+ if (timeSinceLastTap < thresholds.doubleTap && onDoubleTap) {
16472
+ activeGesture.value = "doubleTap";
16473
+ onDoubleTap({
16474
+ type: "doubleTap",
16475
+ center: { x: endX, y: endY },
16476
+ event: e,
16477
+ duration
16478
+ });
16479
+ if (feedback.haptic) triggerHaptic("medium");
16480
+ lastTapTime = 0;
16481
+ } else if (onTap) {
16482
+ if (onDoubleTap) {
16483
+ setTimeout(() => {
16484
+ if (activeGesture.value !== "doubleTap") {
16485
+ activeGesture.value = "tap";
16486
+ onTap({
16487
+ type: "tap",
16488
+ center: { x: endX, y: endY },
16489
+ event: e,
16490
+ duration
16491
+ });
16492
+ if (feedback.haptic) triggerHaptic("light");
16493
+ }
16494
+ }, thresholds.doubleTap);
16495
+ } else {
16496
+ activeGesture.value = "tap";
16497
+ onTap({
16498
+ type: "tap",
16499
+ center: { x: endX, y: endY },
16500
+ event: e,
16501
+ duration
16502
+ });
16503
+ if (feedback.haptic) triggerHaptic("light");
16504
+ }
16505
+ lastTapTime = now;
16506
+ }
16507
+ }
16508
+ }
16509
+ if (removeVisualFeedback) {
16510
+ removeVisualFeedback();
16511
+ removeVisualFeedback = null;
16512
+ }
16513
+ lastGestureTime = Date.now();
16514
+ setTimeout(() => {
16515
+ activeGesture.value = null;
16516
+ }, 100);
16517
+ }
16518
+ function bind(element) {
16519
+ if (!isBrowser()) return () => {
16520
+ };
16521
+ unbind();
16522
+ currentElement = element;
16523
+ const touchOptions = passive ? { passive: true } : void 0;
16524
+ element.addEventListener("touchstart", handleTouchStart, touchOptions);
16525
+ element.addEventListener("touchmove", handleTouchMove, { passive: false });
16526
+ element.addEventListener("touchend", handleTouchEnd);
16527
+ element.addEventListener("touchcancel", handleTouchEnd);
16528
+ if (feedback.visual) {
16529
+ element.addEventListener("touchstart", () => {
16530
+ removeVisualFeedback = applyVisualFeedback(element, feedback);
16531
+ });
16532
+ }
16533
+ return unbind;
16534
+ }
16535
+ function unbind() {
16536
+ if (currentElement) {
16537
+ currentElement.removeEventListener("touchstart", handleTouchStart);
16538
+ currentElement.removeEventListener("touchmove", handleTouchMove);
16539
+ currentElement.removeEventListener("touchend", handleTouchEnd);
16540
+ currentElement.removeEventListener("touchcancel", handleTouchEnd);
16541
+ }
16542
+ if (longPressTimer) {
16543
+ clearTimeout(longPressTimer);
16544
+ longPressTimer = null;
16545
+ }
16546
+ if (removeVisualFeedback) {
16547
+ removeVisualFeedback();
16548
+ removeVisualFeedback = null;
16549
+ }
16550
+ currentElement = null;
16551
+ activeGesture.value = null;
16552
+ isTouching.value = false;
16553
+ }
16554
+ vue.onUnmounted(unbind);
16555
+ return {
16556
+ activeGesture: vue.readonly(activeGesture),
16557
+ bind,
16558
+ isTouching: vue.readonly(isTouching)
16559
+ };
16560
+ }
16561
+ function addPassiveListener(element, event, handler, options) {
16562
+ element.addEventListener(event, handler, __spreadValues({ passive: true }, options));
16563
+ return () => element.removeEventListener(event, handler);
16564
+ }
16565
+ function addNonPassiveListener(element, event, handler, options) {
16566
+ element.addEventListener(event, handler, __spreadValues({ passive: false }, options));
16567
+ return () => element.removeEventListener(event, handler);
16568
+ }
16569
+ function isTouchDevice() {
16570
+ if (!isBrowser()) return false;
16571
+ return "ontouchstart" in window || navigator.maxTouchPoints > 0;
16572
+ }
16573
+ function isMobileDevice() {
16574
+ if (!isBrowser()) return false;
16575
+ return /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);
16576
+ }
16577
+ function getDevicePixelRatio() {
16578
+ if (!isBrowser()) return 1;
16579
+ return window.devicePixelRatio || 1;
16580
+ }
16581
+ function usePWA(config = {}) {
16582
+ const {
16583
+ serviceWorker: swConfig = {}
16584
+ } = config;
16585
+ const isOnline = vue.ref(isBrowser() ? navigator.onLine : true);
16586
+ const isRegistered = vue.ref(false);
16587
+ const needsUpdate = vue.ref(false);
16588
+ let registration = null;
16589
+ function handleOnline() {
16590
+ isOnline.value = true;
16591
+ }
16592
+ function handleOffline() {
16593
+ isOnline.value = false;
16594
+ }
16595
+ function register() {
16596
+ return __async(this, null, function* () {
16597
+ if (!isBrowser() || !("serviceWorker" in navigator)) return;
16598
+ if (!swConfig.enabled) return;
16599
+ try {
16600
+ registration = yield navigator.serviceWorker.register(
16601
+ swConfig.path || "/sw.js",
16602
+ { scope: swConfig.scope || "/" }
16603
+ );
16604
+ isRegistered.value = true;
16605
+ registration.addEventListener("updatefound", () => {
16606
+ const newWorker = registration == null ? void 0 : registration.installing;
16607
+ if (newWorker) {
16608
+ newWorker.addEventListener("statechange", () => {
16609
+ if (newWorker.state === "installed" && navigator.serviceWorker.controller) {
16610
+ needsUpdate.value = true;
16611
+ }
16612
+ });
16613
+ }
16614
+ });
16615
+ } catch (error2) {
16616
+ console.warn("[Directix] Service Worker registration failed:", error2);
16617
+ }
16618
+ });
16619
+ }
16620
+ function update() {
16621
+ return __async(this, null, function* () {
16622
+ if (!registration) return;
16623
+ try {
16624
+ yield registration.update();
16625
+ if (registration.waiting) {
16626
+ registration.waiting.postMessage({ type: "SKIP_WAITING" });
16627
+ }
16628
+ } catch (error2) {
16629
+ console.warn("[Directix] Service Worker update failed:", error2);
16630
+ }
16631
+ });
16632
+ }
16633
+ function unregister() {
16634
+ return __async(this, null, function* () {
16635
+ if (!registration) return;
16636
+ try {
16637
+ yield registration.unregister();
16638
+ isRegistered.value = false;
16639
+ registration = null;
16640
+ } catch (error2) {
16641
+ console.warn("[Directix] Service Worker unregistration failed:", error2);
16642
+ }
16643
+ });
16644
+ }
16645
+ function init() {
16646
+ if (!isBrowser()) return () => {
16647
+ };
16648
+ window.addEventListener("online", handleOnline);
16649
+ window.addEventListener("offline", handleOffline);
16650
+ register();
16651
+ return () => {
16652
+ window.removeEventListener("online", handleOnline);
16653
+ window.removeEventListener("offline", handleOffline);
16654
+ };
16655
+ }
16656
+ vue.onUnmounted(() => {
16657
+ unregister();
16658
+ });
16659
+ return {
16660
+ isOnline: vue.readonly(isOnline),
16661
+ isRegistered: vue.readonly(isRegistered),
16662
+ needsUpdate: vue.readonly(needsUpdate),
16663
+ register,
16664
+ update,
16665
+ unregister,
16666
+ init
16667
+ };
16668
+ }
16669
+ class ObjectPool {
16670
+ constructor(factory, reset, maxSize = 100) {
16671
+ __publicField(this, "pool", []);
16672
+ __publicField(this, "factory");
16673
+ __publicField(this, "reset");
16674
+ __publicField(this, "maxSize");
16675
+ this.factory = factory;
16676
+ this.reset = reset;
16677
+ this.maxSize = maxSize;
16678
+ }
16679
+ acquire() {
16680
+ if (this.pool.length > 0) {
16681
+ return this.pool.pop();
16682
+ }
16683
+ return this.factory();
16684
+ }
16685
+ release(item) {
16686
+ if (this.pool.length < this.maxSize) {
16687
+ this.reset(item);
16688
+ this.pool.push(item);
16689
+ }
16690
+ }
16691
+ get size() {
16692
+ return this.pool.length;
16693
+ }
16694
+ clear() {
16695
+ this.pool.length = 0;
16696
+ }
16697
+ }
16698
+ const DEFAULT_ALLOWED_TAGS = [
16699
+ "b",
16700
+ "i",
16701
+ "u",
16702
+ "strong",
16703
+ "em",
16704
+ "br",
16705
+ "p",
16706
+ "span",
16707
+ "div",
16708
+ "h1",
16709
+ "h2",
16710
+ "h3",
16711
+ "h4",
16712
+ "h5",
16713
+ "h6",
16714
+ "ul",
16715
+ "ol",
16716
+ "li",
16717
+ "blockquote",
16718
+ "pre",
16719
+ "code",
16720
+ "a",
16721
+ "img",
16722
+ "table",
16723
+ "thead",
16724
+ "tbody",
16725
+ "tr",
16726
+ "td",
16727
+ "th"
16728
+ ];
16729
+ const DEFAULT_ALLOWED_ATTRIBUTES = {
16730
+ "*": ["title", "alt", "class", "id"],
16731
+ a: ["href", "target", "rel", "title"],
16732
+ img: ["src", "alt", "title", "width", "height"]
16733
+ };
16734
+ const DEFAULT_ALLOWED_PROTOCOLS = ["http", "https", "mailto", "tel"];
16735
+ const DANGEROUS_TAGS = [
16736
+ "script",
16737
+ "iframe",
16738
+ "object",
16739
+ "embed",
16740
+ "applet",
16741
+ "form",
16742
+ "input",
16743
+ "button",
16744
+ "select",
16745
+ "textarea",
16746
+ "style",
16747
+ "link",
16748
+ "meta",
16749
+ "base",
16750
+ "frame",
16751
+ "frameset",
16752
+ "svg",
16753
+ "math",
16754
+ "template"
16755
+ ];
16756
+ const DANGEROUS_ATTRIBUTES = [
16757
+ "onclick",
16758
+ "onerror",
16759
+ "onload",
16760
+ "onmouseover",
16761
+ "onmouseout",
16762
+ "onmousedown",
16763
+ "onmouseup",
16764
+ "onmousemove",
16765
+ "onfocus",
16766
+ "onblur",
16767
+ "onchange",
16768
+ "onsubmit",
16769
+ "onreset",
16770
+ "onkeydown",
16771
+ "onkeyup",
16772
+ "onkeypress",
16773
+ "oninput",
16774
+ "onscroll",
16775
+ "onresize",
16776
+ "onunload",
16777
+ "onbeforeunload",
16778
+ "onabort",
16779
+ "oncanplay",
16780
+ "oncanplaythrough",
16781
+ "ondurationchange",
16782
+ "onemptied",
16783
+ "onended",
16784
+ "onloadeddata",
16785
+ "onloadedmetadata",
16786
+ "onloadstart",
16787
+ "onpause",
16788
+ "onplay",
16789
+ "onplaying",
16790
+ "onprogress",
16791
+ "onratechange",
16792
+ "onseeked",
16793
+ "onseeking",
16794
+ "onstalled",
16795
+ "onsuspend",
16796
+ "ontimeupdate",
16797
+ "onvolumechange",
16798
+ "onwaiting",
16799
+ "onafterprint",
16800
+ "onbeforeprint",
16801
+ "oncontextmenu",
16802
+ "oncopy",
16803
+ "oncut",
16804
+ "onpaste",
16805
+ "ondblclick",
16806
+ "ondrag",
16807
+ "ondragend",
16808
+ "ondragenter",
16809
+ "ondragleave",
16810
+ "ondragover",
16811
+ "ondragstart",
16812
+ "ondrop",
16813
+ // Form-related
16814
+ "formaction",
16815
+ "action",
16816
+ "method",
16817
+ "enctype"
16818
+ ];
16819
+ const DANGEROUS_URL_PATTERNS = [
16820
+ /^javascript:/i,
16821
+ /^data:/i,
16822
+ /^vbscript:/i,
16823
+ /^file:/i
16824
+ ];
16825
+ function isUrlSafe(url, allowedProtocols = DEFAULT_ALLOWED_PROTOCOLS) {
16826
+ if (!url) return true;
16827
+ const trimmed = url.trim();
16828
+ for (const pattern of DANGEROUS_URL_PATTERNS) {
16829
+ if (pattern.test(trimmed)) {
16830
+ return false;
16831
+ }
16832
+ }
16833
+ const protocolMatch = trimmed.match(/^([a-zA-Z][a-zA-Z0-9+.-]*):/);
16834
+ if (protocolMatch) {
16835
+ return allowedProtocols.includes(protocolMatch[1].toLowerCase());
16836
+ }
16837
+ return true;
16838
+ }
16839
+ function sanitizeUrl(url, allowedProtocols = DEFAULT_ALLOWED_PROTOCOLS) {
16840
+ if (!url) return "";
16841
+ const trimmed = url.trim();
16842
+ if (!isUrlSafe(trimmed, allowedProtocols)) {
16843
+ return "";
16844
+ }
16845
+ return trimmed;
16846
+ }
16847
+ function escapeHtml(str) {
16848
+ const escapeMap = {
16849
+ "&": "&amp;",
16850
+ "<": "&lt;",
16851
+ ">": "&gt;",
16852
+ '"': "&quot;",
16853
+ "'": "&#x27;",
16854
+ "/": "&#x2F;",
16855
+ "`": "&#x60;",
16856
+ "=": "&#x3D;"
16857
+ };
16858
+ return str.replace(/[&<>"'`=/]/g, (char) => escapeMap[char] || char);
16859
+ }
16860
+ function unescapeHtml(str) {
16861
+ const unescapeMap = {
16862
+ "&amp;": "&",
16863
+ "&lt;": "<",
16864
+ "&gt;": ">",
16865
+ "&quot;": '"',
16866
+ "&#x27;": "'",
16867
+ "&#x2F;": "/",
16868
+ "&#x60;": "`",
16869
+ "&#x3D;": "=",
16870
+ "&#39;": "'"
16871
+ };
16872
+ return str.replace(/&[^;]+;/g, (entity) => unescapeMap[entity] || entity).replace(/&#(\d+);/g, (_, code) => String.fromCharCode(parseInt(code, 10)));
16873
+ }
16874
+ function stripHtml(html) {
16875
+ return html.replace(/<[^>]*>/g, "");
16876
+ }
16877
+ function sanitizeHtml(html, config = {}) {
16878
+ var _a2;
16879
+ if (!html) return "";
16880
+ if (!isBrowser()) return html;
16881
+ const {
16882
+ allowedTags = DEFAULT_ALLOWED_TAGS,
16883
+ allowedAttributes = DEFAULT_ALLOWED_ATTRIBUTES,
16884
+ allowedProtocols = DEFAULT_ALLOWED_PROTOCOLS,
16885
+ allowDataUrls = false,
16886
+ allowInlineStyles = false,
16887
+ allowClass = true,
16888
+ allowId = false,
16889
+ detectDangerousPatterns = true,
16890
+ customFilters = []
16891
+ } = config;
16892
+ let result = html;
16893
+ for (const filter of customFilters) {
16894
+ result = filter(result);
16895
+ }
16896
+ if (detectDangerousPatterns) {
16897
+ const dangerousPatterns = [
16898
+ /<script[\s\S]*?>[\s\S]*?<\/script>/gi,
16899
+ /javascript:/gi,
16900
+ /on\w+\s*=/gi,
16901
+ /data:\s*text\/html/gi,
16902
+ /vbscript:/gi,
16903
+ /expression\s*\(/gi,
16904
+ /url\s*\(\s*["']?javascript:/gi
16905
+ ];
16906
+ for (const pattern of dangerousPatterns) {
16907
+ if (pattern.test(result)) {
16908
+ result = result.replace(pattern, "");
16909
+ }
16910
+ }
16911
+ }
16912
+ const temp = document.createElement("div");
16913
+ temp.innerHTML = result;
16914
+ for (const tag of DANGEROUS_TAGS) {
16915
+ const elements = temp.getElementsByTagName(tag);
16916
+ while (elements.length > 0) {
16917
+ (_a2 = elements[0].parentNode) == null ? void 0 : _a2.removeChild(elements[0]);
16918
+ }
16919
+ }
16920
+ function processElement(el) {
16921
+ var _a3;
16922
+ const tagName = el.tagName.toLowerCase();
16923
+ if (!allowedTags.includes(tagName)) {
16924
+ const text = document.createTextNode(el.textContent || "");
16925
+ (_a3 = el.parentNode) == null ? void 0 : _a3.replaceChild(text, el);
16926
+ return;
16927
+ }
16928
+ for (const attr of DANGEROUS_ATTRIBUTES) {
16929
+ el.removeAttribute(attr);
16930
+ }
16931
+ const attrs = Array.from(el.attributes);
16932
+ for (const attr of attrs) {
16933
+ const attrName = attr.name.toLowerCase();
16934
+ if (attrName.startsWith("on")) {
16935
+ el.removeAttribute(attr.name);
16936
+ continue;
16937
+ }
16938
+ let isAllowed2 = false;
16939
+ if (Array.isArray(allowedAttributes)) {
16940
+ isAllowed2 = allowedAttributes.includes(attrName);
16941
+ } else {
16942
+ const globalAttrs = allowedAttributes["*"] || [];
16943
+ const tagAttrs = allowedAttributes[tagName] || [];
16944
+ isAllowed2 = globalAttrs.includes(attrName) || tagAttrs.includes(attrName);
16945
+ }
16946
+ if (attrName === "class" && !allowClass) {
16947
+ el.removeAttribute(attr.name);
16948
+ continue;
16949
+ }
16950
+ if (attrName === "id" && !allowId) {
16951
+ el.removeAttribute(attr.name);
16952
+ continue;
16953
+ }
16954
+ if (attrName === "style" && !allowInlineStyles) {
16955
+ el.removeAttribute(attr.name);
16956
+ continue;
16957
+ }
16958
+ if (attrName === "href" || attrName === "src") {
16959
+ const url = attr.value;
16960
+ if (!isUrlSafe(url, allowDataUrls ? [...allowedProtocols, "data"] : allowedProtocols)) {
16961
+ el.removeAttribute(attr.name);
16962
+ continue;
16963
+ }
16964
+ }
16965
+ if (!isAllowed2 && attrName !== "class" && attrName !== "id" && attrName !== "style") {
16966
+ el.removeAttribute(attr.name);
16967
+ }
16968
+ }
16969
+ for (const child of Array.from(el.children)) {
16970
+ processElement(child);
16971
+ }
16972
+ }
16973
+ for (const child of Array.from(temp.children)) {
16974
+ processElement(child);
16975
+ }
16976
+ return temp.innerHTML;
16977
+ }
16978
+ function getCSPNonce() {
16979
+ if (!isBrowser()) return null;
16980
+ const meta = document.querySelector('meta[http-equiv="Content-Security-Policy"]');
16981
+ if (meta) {
16982
+ const content = meta.content;
16983
+ const match = content.match(/nonce-([a-zA-Z0-9+/=]+)/);
16984
+ if (match) {
16985
+ return match[1];
16986
+ }
16987
+ }
16988
+ const scripts = document.querySelectorAll("script[nonce]");
16989
+ if (scripts.length > 0) {
16990
+ return scripts[0].nonce || null;
16991
+ }
16992
+ return null;
16993
+ }
16994
+ function injectStylesCSP(css, options = {}) {
16995
+ if (!isBrowser()) return null;
16996
+ const { nonce } = options;
16997
+ if (nonce || getCSPNonce()) {
16998
+ const style2 = document.createElement("style");
16999
+ style2.setAttribute("nonce", nonce || getCSPNonce() || "");
17000
+ style2.textContent = css;
17001
+ document.head.appendChild(style2);
17002
+ return style2;
17003
+ }
17004
+ const style = document.createElement("style");
17005
+ style.textContent = css;
17006
+ document.head.appendChild(style);
17007
+ return style;
17008
+ }
17009
+ function injectScriptCSP(src, options = {}) {
17010
+ if (!isBrowser()) return null;
17011
+ const { nonce } = options;
17012
+ const script = document.createElement("script");
17013
+ script.src = src;
17014
+ if (nonce || getCSPNonce()) {
17015
+ script.setAttribute("nonce", nonce || getCSPNonce() || "");
17016
+ }
17017
+ document.head.appendChild(script);
17018
+ return script;
17019
+ }
17020
+ const SecurityAudit = {
17021
+ /**
17022
+ * Scan for potential security issues in HTML
17023
+ */
17024
+ scanHtml(html) {
17025
+ const issues = [];
17026
+ if (/<script[\s\S]*?>[\s\S]*?<\/script>/gi.test(html)) {
17027
+ issues.push({
17028
+ type: "script-injection",
17029
+ severity: "critical",
17030
+ description: "HTML contains script tags which could lead to XSS attacks",
17031
+ remediation: "Remove script tags or use a sanitization library"
17032
+ });
17033
+ }
17034
+ const eventHandlerMatch = html.match(/on\w+\s*=/gi);
17035
+ if (eventHandlerMatch) {
17036
+ issues.push({
17037
+ type: "event-handler",
17038
+ severity: "high",
17039
+ description: `Found ${eventHandlerMatch.length} event handler(s) which could be exploited`,
17040
+ remediation: "Remove inline event handlers and use addEventListener instead"
17041
+ });
17042
+ }
17043
+ if (/javascript:/gi.test(html)) {
17044
+ issues.push({
17045
+ type: "javascript-url",
17046
+ severity: "high",
17047
+ description: "HTML contains javascript: URLs which could lead to XSS attacks",
17048
+ remediation: "Remove javascript: URLs or validate/sanitize them"
17049
+ });
17050
+ }
17051
+ if (/data:\s*text\/html/gi.test(html)) {
17052
+ issues.push({
17053
+ type: "data-url",
17054
+ severity: "high",
17055
+ description: "HTML contains data:text/html URLs which could execute scripts",
17056
+ remediation: "Remove or sanitize data: URLs"
17057
+ });
17058
+ }
17059
+ if (/<iframe[\s\S]*?srcdoc=/gi.test(html)) {
17060
+ issues.push({
17061
+ type: "iframe-srcdoc",
17062
+ severity: "high",
17063
+ description: "HTML contains iframe with srcdoc attribute",
17064
+ remediation: "Avoid using srcdoc or sanitize its content"
17065
+ });
17066
+ }
17067
+ if (/<form[\s\S]*?action\s*=/gi.test(html)) {
17068
+ issues.push({
17069
+ type: "form-action",
17070
+ severity: "medium",
17071
+ description: "HTML contains form with action attribute",
17072
+ remediation: "Validate form actions or use CSRF protection"
17073
+ });
17074
+ }
17075
+ return issues;
17076
+ },
17077
+ /**
17078
+ * Check CSP configuration
17079
+ */
17080
+ checkCSP() {
17081
+ var _a2, _b2;
17082
+ const result = {
17083
+ policies: {},
17084
+ warnings: [],
17085
+ recommendations: []
17086
+ };
17087
+ if (!isBrowser()) {
17088
+ result.warnings.push("CSP check requires browser environment");
17089
+ return result;
17090
+ }
17091
+ const meta = document.querySelector('meta[http-equiv="Content-Security-Policy"]');
17092
+ if (meta) {
17093
+ const content = meta.content;
17094
+ const directives = content.split(";").map((d) => d.trim());
17095
+ for (const directive of directives) {
17096
+ const [name, ...values] = directive.split(/\s+/);
17097
+ if (name) {
17098
+ result.policies[name.toLowerCase()] = values;
17099
+ }
17100
+ }
17101
+ if ((_a2 = result.policies["script-src"]) == null ? void 0 : _a2.includes("'unsafe-inline'")) {
17102
+ result.warnings.push("CSP allows unsafe-inline scripts - this reduces XSS protection");
17103
+ }
17104
+ if ((_b2 = result.policies["script-src"]) == null ? void 0 : _b2.includes("'unsafe-eval'")) {
17105
+ result.warnings.push("CSP allows unsafe-eval - this reduces XSS protection");
17106
+ }
17107
+ const recommendedDirectives = ["default-src", "script-src", "style-src", "img-src", "connect-src"];
17108
+ for (const directive of recommendedDirectives) {
17109
+ if (!result.policies[directive]) {
17110
+ result.recommendations.push(`Consider adding ${directive} directive to CSP`);
17111
+ }
17112
+ }
17113
+ } else {
17114
+ result.warnings.push("No CSP meta tag found - consider adding Content Security Policy");
17115
+ result.recommendations.push("Add a Content-Security-Policy meta tag or header");
17116
+ }
17117
+ return result;
17118
+ },
17119
+ /**
17120
+ * Check for known dependency vulnerabilities (Node.js environment only)
17121
+ * Note: This is a client-side check that uses npm audit API when available.
17122
+ * For production use, run `npm audit` or `pnpm audit` in CI/CD.
17123
+ */
17124
+ checkDependencies() {
17125
+ return __async(this, null, function* () {
17126
+ var _a2, _b2, _c, _d, _e;
17127
+ const vulnerabilities = [];
17128
+ if (typeof process === "undefined" || !((_a2 = process.versions) == null ? void 0 : _a2.node)) {
17129
+ console.warn("[Directix] checkDependencies() is only available in Node.js environment");
17130
+ return vulnerabilities;
17131
+ }
17132
+ try {
17133
+ const { execSync } = yield import("node:child_process");
17134
+ try {
17135
+ const result = execSync("npm audit --json", {
17136
+ encoding: "utf-8",
17137
+ timeout: 3e4
17138
+ });
17139
+ const audit = JSON.parse(result);
17140
+ if (audit.vulnerabilities) {
17141
+ for (const [name, info2] of Object.entries(audit.vulnerabilities)) {
17142
+ if (info2.via && Array.isArray(info2.via)) {
17143
+ for (const via of info2.via) {
17144
+ if (typeof via === "object" && via.title) {
17145
+ vulnerabilities.push({
17146
+ name,
17147
+ id: (_c = (_b2 = via.url) == null ? void 0 : _b2.match(/(CVE-\d+-\d+|GHSA-[a-zA-Z0-9-]+)/)) == null ? void 0 : _c[0],
17148
+ version: info2.version || "unknown",
17149
+ severity: via.severity || info2.severity || "medium",
17150
+ title: via.title,
17151
+ url: via.url,
17152
+ patchedVersions: info2.fixAvailable ? "Available" : void 0
17153
+ });
17154
+ }
17155
+ }
17156
+ }
17157
+ }
17158
+ }
17159
+ } catch (execError) {
17160
+ if (execError.stdout) {
17161
+ try {
17162
+ const audit = JSON.parse(execError.stdout);
17163
+ if (audit.vulnerabilities) {
17164
+ for (const [name, info2] of Object.entries(audit.vulnerabilities)) {
17165
+ if (info2.via && Array.isArray(info2.via)) {
17166
+ for (const via of info2.via) {
17167
+ if (typeof via === "object" && via.title) {
17168
+ vulnerabilities.push({
17169
+ name,
17170
+ id: (_e = (_d = via.url) == null ? void 0 : _d.match(/(CVE-\d+-\d+|GHSA-[a-zA-Z0-9-]+)/)) == null ? void 0 : _e[0],
17171
+ version: info2.version || "unknown",
17172
+ severity: via.severity || info2.severity || "medium",
17173
+ title: via.title,
17174
+ url: via.url,
17175
+ patchedVersions: info2.fixAvailable ? "Available" : void 0
17176
+ });
17177
+ }
17178
+ }
17179
+ }
17180
+ }
17181
+ }
17182
+ } catch (e) {
17183
+ }
17184
+ }
17185
+ }
17186
+ } catch (error2) {
17187
+ console.warn("[Directix] Failed to check dependencies:", error2);
17188
+ }
17189
+ return vulnerabilities;
17190
+ });
17191
+ },
17192
+ /**
17193
+ * Generate security report
17194
+ */
17195
+ generateReport(html) {
17196
+ const report = {
17197
+ vulnerabilities: [],
17198
+ warnings: [],
17199
+ recommendations: [],
17200
+ timestamp: /* @__PURE__ */ new Date()
17201
+ };
17202
+ if (html) {
17203
+ report.vulnerabilities = this.scanHtml(html);
17204
+ }
17205
+ const cspResult = this.checkCSP();
17206
+ for (const warning of cspResult.warnings) {
17207
+ report.warnings.push({
17208
+ type: "csp-warning",
17209
+ severity: "medium",
17210
+ description: warning
17211
+ });
17212
+ }
17213
+ report.recommendations.push(...cspResult.recommendations);
17214
+ return report;
17215
+ },
17216
+ /**
17217
+ * Format security report
17218
+ */
17219
+ formatReport(report, format = "text") {
17220
+ if (format === "json") {
17221
+ return JSON.stringify(report, null, 2);
17222
+ }
17223
+ if (format === "html") {
17224
+ let html = '<div class="security-report">';
17225
+ html += `<h2>Security Report</h2>`;
17226
+ html += `<p>Generated: ${report.timestamp.toISOString()}</p>`;
17227
+ if (report.vulnerabilities.length > 0) {
17228
+ html += "<h3>Vulnerabilities</h3><ul>";
17229
+ for (const vuln of report.vulnerabilities) {
17230
+ html += `<li class="severity-${vuln.severity}"><strong>${vuln.type}</strong>: ${vuln.description}</li>`;
17231
+ }
17232
+ html += "</ul>";
17233
+ }
17234
+ if (report.warnings.length > 0) {
17235
+ html += "<h3>Warnings</h3><ul>";
17236
+ for (const warning of report.warnings) {
17237
+ html += `<li class="severity-${warning.severity}"><strong>${warning.type}</strong>: ${warning.description}</li>`;
17238
+ }
17239
+ html += "</ul>";
17240
+ }
17241
+ if (report.recommendations.length > 0) {
17242
+ html += "<h3>Recommendations</h3><ul>";
17243
+ for (const rec of report.recommendations) {
17244
+ html += `<li>${rec}</li>`;
17245
+ }
17246
+ html += "</ul>";
17247
+ }
17248
+ html += "</div>";
17249
+ return html;
17250
+ }
17251
+ let text = "Security Report\n";
17252
+ text += `Generated: ${report.timestamp.toISOString()}
17253
+
17254
+ `;
17255
+ if (report.vulnerabilities.length > 0) {
17256
+ text += "Vulnerabilities:\n";
17257
+ for (const vuln of report.vulnerabilities) {
17258
+ text += ` [${vuln.severity.toUpperCase()}] ${vuln.type}: ${vuln.description}
17259
+ `;
17260
+ }
17261
+ text += "\n";
17262
+ }
17263
+ if (report.warnings.length > 0) {
17264
+ text += "Warnings:\n";
17265
+ for (const warning of report.warnings) {
17266
+ text += ` [${warning.severity.toUpperCase()}] ${warning.type}: ${warning.description}
17267
+ `;
17268
+ }
17269
+ text += "\n";
17270
+ }
17271
+ if (report.recommendations.length > 0) {
17272
+ text += "Recommendations:\n";
17273
+ for (const rec of report.recommendations) {
17274
+ text += ` - ${rec}
17275
+ `;
17276
+ }
17277
+ }
17278
+ return text;
17279
+ }
17280
+ };
17281
+ class SafeContentHandler {
17282
+ constructor(config = {}) {
17283
+ __publicField(this, "config");
17284
+ this.config = config;
17285
+ }
17286
+ /**
17287
+ * Sanitize and set HTML content
17288
+ */
17289
+ setHtml(element, content) {
17290
+ element.innerHTML = sanitizeHtml(content, this.config);
17291
+ }
17292
+ /**
17293
+ * Sanitize and set text content
17294
+ */
17295
+ setText(element, content) {
17296
+ element.textContent = content;
17297
+ }
17298
+ /**
17299
+ * Set attribute with URL validation
17300
+ */
17301
+ setAttribute(element, name, value) {
17302
+ if (name.toLowerCase().startsWith("on")) {
17303
+ return;
17304
+ }
17305
+ if (name.toLowerCase() === "href" || name.toLowerCase() === "src") {
17306
+ value = sanitizeUrl(value, this.config.allowedProtocols);
17307
+ }
17308
+ element.setAttribute(name, value);
17309
+ }
17310
+ /**
17311
+ * Get sanitized HTML
17312
+ */
17313
+ getSanitizedHtml(content) {
17314
+ return sanitizeHtml(content, this.config);
17315
+ }
17316
+ }
17317
+ function createSafeContentHandler(config) {
17318
+ return new SafeContentHandler(config);
17319
+ }
17320
+ function useLazyOptimized(options = {}) {
17321
+ const {
17322
+ threshold = 0,
17323
+ rootMargin = "0px",
17324
+ once = true,
17325
+ onLoad
17326
+ } = options;
17327
+ const state2 = vue.shallowRef({
17328
+ loading: false,
17329
+ loaded: false,
17330
+ error: null,
17331
+ isVisible: false
17332
+ });
17333
+ let observer = null;
17334
+ function disconnect() {
17335
+ if (observer) {
17336
+ observer.disconnect();
17337
+ observer = null;
17338
+ }
17339
+ }
17340
+ function observe2(el) {
17341
+ disconnect();
17342
+ observer = new IntersectionObserver(
17343
+ (entries) => {
17344
+ const entry = entries[0];
17345
+ if (entry == null ? void 0 : entry.isIntersecting) {
17346
+ state2.value = __spreadProps(__spreadValues({}, state2.value), { isVisible: true });
17347
+ load2();
17348
+ if (once) {
17349
+ disconnect();
17350
+ }
17351
+ }
17352
+ },
17353
+ { threshold, rootMargin }
17354
+ );
17355
+ observer.observe(el);
17356
+ }
17357
+ function load2() {
17358
+ if (state2.value.loading || state2.value.loaded) return;
17359
+ state2.value = __spreadProps(__spreadValues({}, state2.value), { loading: true, error: null });
17360
+ try {
17361
+ onLoad == null ? void 0 : onLoad({});
17362
+ state2.value = __spreadProps(__spreadValues({}, state2.value), { loading: false, loaded: true });
17363
+ } catch (e) {
17364
+ state2.value = __spreadProps(__spreadValues({}, state2.value), { loading: false, error: e });
17365
+ }
17366
+ }
17367
+ return {
17368
+ state: vue.readonly(state2),
17369
+ observe: observe2,
17370
+ disconnect,
17371
+ load: load2
17372
+ };
17373
+ }
17374
+ function useDirectiveInstance(options = {}) {
17375
+ const { initialState = {}, shallow = false } = options;
17376
+ let element = null;
17377
+ const state2 = shallow ? vue.reactive(initialState) : vue.reactive(initialState);
17378
+ function setElement(el) {
17379
+ element = vue.markRaw(el);
17380
+ }
17381
+ function setState2(updater) {
17382
+ const newState = updater(vue.toRaw(state2));
17383
+ Object.assign(state2, newState);
17384
+ }
17385
+ function reset() {
17386
+ Object.assign(state2, initialState);
17387
+ }
17388
+ return {
17389
+ get element() {
17390
+ return element;
17391
+ },
17392
+ set element(el) {
17393
+ if (el) setElement(el);
17394
+ },
17395
+ state: vue.readonly(state2),
17396
+ setElement,
17397
+ setState: setState2,
17398
+ reset
17399
+ };
17400
+ }
17401
+ function computedWithCleanup(options) {
17402
+ const { get: get2, cleanup: cleanup2 } = options;
17403
+ let oldValue;
17404
+ return vue.computed({
17405
+ get() {
17406
+ const newValue = get2();
17407
+ if (oldValue !== void 0 && oldValue !== newValue) {
17408
+ cleanup2 == null ? void 0 : cleanup2(oldValue);
17409
+ }
17410
+ oldValue = newValue;
17411
+ return newValue;
17412
+ },
17413
+ set() {
17414
+ }
17415
+ });
17416
+ }
17417
+ function watchEffectBinding(options) {
17418
+ const { binding, effect } = options;
17419
+ let cleanupFn = null, cleanup2 = (fn) => {
17420
+ cleanupFn = fn;
17421
+ };
17422
+ const stop = vue.watchEffect((onCleanup) => {
17423
+ cleanup2 = onCleanup;
17424
+ if (cleanupFn) {
17425
+ cleanupFn();
17426
+ cleanupFn = null;
17427
+ }
17428
+ if (vue.isRef(binding)) {
17429
+ effect(binding.value, void 0, cleanup2);
17430
+ } else {
17431
+ effect(binding, void 0, cleanup2);
17432
+ }
17433
+ });
17434
+ return () => {
17435
+ if (cleanupFn) {
17436
+ cleanupFn();
17437
+ }
17438
+ stop();
17439
+ };
17440
+ }
17441
+ function useSuspenseDirective(options) {
17442
+ const { loader, onSuccess, onError } = options;
17443
+ const state2 = vue.shallowRef({
17444
+ loading: false,
17445
+ error: null,
17446
+ data: null
17447
+ });
17448
+ function load2() {
17449
+ return __async(this, null, function* () {
17450
+ if (state2.value.loading) return;
17451
+ state2.value = __spreadProps(__spreadValues({}, state2.value), { loading: true, error: null });
17452
+ try {
17453
+ const data = yield loader();
17454
+ state2.value = { loading: false, error: null, data };
17455
+ onSuccess == null ? void 0 : onSuccess(data);
17456
+ } catch (error2) {
17457
+ state2.value = __spreadProps(__spreadValues({}, state2.value), { loading: false, error: error2 });
17458
+ onError == null ? void 0 : onError(error2);
17459
+ }
17460
+ });
17461
+ }
17462
+ function retry() {
17463
+ return __async(this, null, function* () {
17464
+ state2.value = __spreadProps(__spreadValues({}, state2.value), { error: null });
17465
+ yield load2();
17466
+ });
17467
+ }
17468
+ return {
17469
+ state: vue.readonly(state2),
17470
+ load: load2,
17471
+ retry
17472
+ };
17473
+ }
17474
+ function ensureTeleportTarget(target) {
17475
+ if (typeof document === "undefined") return null;
17476
+ let el = document.querySelector(target);
17477
+ if (!el) {
17478
+ el = document.createElement("div");
17479
+ el.id = target.replace("#", "");
17480
+ document.body.appendChild(el);
17481
+ }
17482
+ return el;
17483
+ }
17484
+ function teleportContent(content, options) {
17485
+ const { to, disabled = false } = options;
17486
+ if (disabled || typeof document === "undefined") {
17487
+ return () => {
17488
+ };
17489
+ }
17490
+ const targetEl = typeof to === "string" ? ensureTeleportTarget(to) : to;
17491
+ if (!targetEl) return () => {
17492
+ };
17493
+ const parent = content.parentNode;
17494
+ const nextSibling = content.nextSibling;
17495
+ targetEl.appendChild(content);
17496
+ return () => {
17497
+ if (parent && content.parentNode === targetEl) {
17498
+ parent.insertBefore(content, nextSibling);
17499
+ }
17500
+ };
17501
+ }
15774
17502
  const zhCN = {
15775
17503
  directives: {
15776
17504
  debounce: {
@@ -17813,11 +19541,11 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
17813
19541
  typewriter: vTypewriter
17814
19542
  };
17815
19543
  const install = (app, options = {}) => {
17816
- var _a2, _b, _c, _d, _e, _f, _g;
19544
+ var _a2, _b2, _c, _d, _e, _f, _g;
17817
19545
  let vueVersion = null;
17818
19546
  if (typeof app === "function" && ((_a2 = app.version) == null ? void 0 : _a2.startsWith("2"))) {
17819
19547
  vueVersion = 2;
17820
- } else if ((app == null ? void 0 : app.config) && ((_b = app == null ? void 0 : app.version) == null ? void 0 : _b.startsWith("3"))) {
19548
+ } else if ((app == null ? void 0 : app.config) && ((_b2 = app == null ? void 0 : app.version) == null ? void 0 : _b2.startsWith("3"))) {
17821
19549
  vueVersion = 3;
17822
19550
  } else if (typeof (app == null ? void 0 : app.directive) === "function" && typeof (app == null ? void 0 : app.mixin) === "function" && ((_c = app.version) == null ? void 0 : _c.startsWith("2"))) {
17823
19551
  vueVersion = 2;
@@ -17852,10 +19580,17 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
17852
19580
  install
17853
19581
  };
17854
19582
  exports.Directix = Directix;
19583
+ exports.ObjectPool = ObjectPool;
17855
19584
  exports.PluginManager = PluginManager;
17856
19585
  exports.PluginRegistry = PluginRegistry;
19586
+ exports.SafeContentHandler = SafeContentHandler;
19587
+ exports.SecurityAudit = SecurityAudit;
17857
19588
  exports.addCleanupVue2 = addCleanup$1;
17858
19589
  exports.addCleanupVue3 = addCleanup;
19590
+ exports.addNonPassiveListener = addNonPassiveListener;
19591
+ exports.addPassiveListener = addPassiveListener;
19592
+ exports.announce = announce;
19593
+ exports.applyAriaAttributes = applyAriaAttributes;
17859
19594
  exports.assert = assert;
17860
19595
  exports.assertPositive = assertPositive;
17861
19596
  exports.assertRange = assertRange;
@@ -17864,8 +19599,11 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
17864
19599
  exports.calculateTime = calculateTime;
17865
19600
  exports.capitalizeText = capitalizeText;
17866
19601
  exports.capitalizeWord = capitalizeWord;
19602
+ exports.clearAnnouncer = clearAnnouncer;
19603
+ exports.clearAriaAttributes = clearAriaAttributes;
17867
19604
  exports.clearDevtoolsState = clearDevtoolsState;
17868
19605
  exports.clearPerformanceMetrics = clearPerformanceMetrics;
19606
+ exports.computedWithCleanup = computedWithCleanup;
17869
19607
  exports.configurePerformance = configurePerformance;
17870
19608
  exports.configurePermission = configurePermission;
17871
19609
  exports.createCapitalizer = createCapitalizer;
@@ -17877,6 +19615,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
17877
19615
  exports.createMoneyFormatter = createMoneyFormatter;
17878
19616
  exports.createNumberFormatter = createNumberFormatter;
17879
19617
  exports.createPermissionChecker = createPermissionChecker;
19618
+ exports.createSafeContentHandler = createSafeContentHandler;
17880
19619
  exports.createStyleDirective = createStyleDirective;
17881
19620
  exports.createTrimmer = createTrimmer;
17882
19621
  exports.createUppercaser = createUppercaser;
@@ -17899,7 +19638,9 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
17899
19638
  exports.enableDevtools = enableDevtools;
17900
19639
  exports.enablePerformance = enablePerformance;
17901
19640
  exports.endMeasure = endMeasure;
19641
+ exports.ensureTeleportTarget = ensureTeleportTarget;
17902
19642
  exports.error = error;
19643
+ exports.escapeHtml = escapeHtml;
17903
19644
  exports.exportPerformanceData = exportPerformanceData;
17904
19645
  exports.formatCurrencyLocale = formatCurrencyLocale;
17905
19646
  exports.formatDateLocale = formatDateLocale;
@@ -17907,9 +19648,13 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
17907
19648
  exports.formatNumber = formatNumber;
17908
19649
  exports.formatNumberLocale = formatNumberLocale;
17909
19650
  exports.formatTime = formatTime;
19651
+ exports.generateAriaId = generateAriaId;
17910
19652
  exports.generateId = generateId;
17911
19653
  exports.get = get;
19654
+ exports.getAutoAriaConfig = getAutoAriaConfig;
19655
+ exports.getCSPNonce = getCSPNonce;
17912
19656
  exports.getDateFormat = getDateFormat;
19657
+ exports.getDevicePixelRatio = getDevicePixelRatio;
17913
19658
  exports.getDevtoolsState = getDevtoolsState;
17914
19659
  exports.getDirectiveMetrics = getDirectiveMetrics;
17915
19660
  exports.getLocale = getLocale;
@@ -17926,18 +19671,23 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
17926
19671
  exports.getTimezoneInfo = getTimezoneInfo;
17927
19672
  exports.getVueVersion = getVueVersion;
17928
19673
  exports.info = info;
19674
+ exports.injectScriptCSP = injectScriptCSP;
19675
+ exports.injectStylesCSP = injectStylesCSP;
17929
19676
  exports.isArray = isArray;
17930
19677
  exports.isBoolean = isBoolean;
17931
19678
  exports.isBrowser = isBrowser;
17932
19679
  exports.isDevtoolsAvailable = isDevtoolsAvailable;
17933
19680
  exports.isEmpty = isEmpty;
17934
19681
  exports.isFunction = isFunction;
19682
+ exports.isMobileDevice = isMobileDevice;
17935
19683
  exports.isNumber = isNumber;
17936
19684
  exports.isObject = isObject;
17937
19685
  exports.isPerformanceEnabled = isPerformanceEnabled;
17938
19686
  exports.isPromise = isPromise;
17939
19687
  exports.isSSR = isSSR;
17940
19688
  exports.isString = isString;
19689
+ exports.isTouchDevice = isTouchDevice;
19690
+ exports.isUrlSafe = isUrlSafe;
17941
19691
  exports.isVue2 = isVue2;
17942
19692
  exports.isVue27 = isVue27;
17943
19693
  exports.isVue3 = isVue3;
@@ -17954,6 +19704,8 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
17954
19704
  exports.resetPluginManager = resetPluginManager;
17955
19705
  exports.resetPluginRegistry = resetPluginRegistry;
17956
19706
  exports.resetVueVersion = resetVueVersion;
19707
+ exports.sanitizeHtml = sanitizeHtml;
19708
+ exports.sanitizeUrl = sanitizeUrl;
17957
19709
  exports.set = set;
17958
19710
  exports.setLocale = setLocale;
17959
19711
  exports.setVueVersion = setVueVersion;
@@ -17961,17 +19713,21 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
17961
19713
  exports.setWarningI18n = setWarningI18n;
17962
19714
  exports.setWarningLevel = setWarningLevel;
17963
19715
  exports.startMeasure = startMeasure;
19716
+ exports.stripHtml = stripHtml;
17964
19717
  exports.supportsClipboard = supportsClipboard;
17965
19718
  exports.supportsIntersectionObserver = supportsIntersectionObserver;
17966
19719
  exports.supportsMutationObserver = supportsMutationObserver;
17967
19720
  exports.supportsPassive = supportsPassive;
17968
19721
  exports.supportsResizeObserver = supportsResizeObserver;
17969
19722
  exports.t = t;
19723
+ exports.teleportContent = teleportContent;
17970
19724
  exports.throttleFn = throttleFn;
17971
19725
  exports.trackDirective = trackDirective;
17972
19726
  exports.trackPlugin = trackPlugin;
19727
+ exports.triggerHaptic = triggerHaptic;
17973
19728
  exports.trimText = trimText;
17974
19729
  exports.truncateText = truncateText;
19730
+ exports.unescapeHtml = unescapeHtml;
17975
19731
  exports.untrackDirective = untrackDirective;
17976
19732
  exports.untrackPlugin = untrackPlugin;
17977
19733
  exports.uppercaseText = uppercaseText;
@@ -17985,12 +19741,15 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
17985
19741
  exports.useCountdown = useCountdown;
17986
19742
  exports.useCounter = useCounter;
17987
19743
  exports.useDebounce = useDebounce;
19744
+ exports.useDirectiveInstance = useDirectiveInstance;
17988
19745
  exports.useDraggable = useDraggable;
17989
19746
  exports.useEllipsis = useEllipsis;
17990
19747
  exports.useEmoji = useEmoji;
19748
+ exports.useEnhancedTouch = useEnhancedTouch;
17991
19749
  exports.useExport = useExport;
17992
19750
  exports.useFade = useFade;
17993
19751
  exports.useFocus = useFocus;
19752
+ exports.useFocusTrap = useFocusTrap;
17994
19753
  exports.useFullscreen = useFullscreen;
17995
19754
  exports.useHighlight = useHighlight;
17996
19755
  exports.useHotkey = useHotkey;
@@ -17998,7 +19757,9 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
17998
19757
  exports.useImagePreview = useImagePreview;
17999
19758
  exports.useInfiniteScroll = useInfiniteScroll;
18000
19759
  exports.useIntersect = useIntersect;
19760
+ exports.useKeyboardNavigation = useKeyboardNavigation;
18001
19761
  exports.useLazy = useLazy;
19762
+ exports.useLazyOptimized = useLazyOptimized;
18002
19763
  exports.useLoading = useLoading;
18003
19764
  exports.useLongPress = useLongPress;
18004
19765
  exports.useLottie = useLottie;
@@ -18007,6 +19768,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
18007
19768
  exports.useMoney = useMoney;
18008
19769
  exports.useMutation = useMutation;
18009
19770
  exports.useNumber = useNumber;
19771
+ exports.usePWA = usePWA;
18010
19772
  exports.usePan = usePan;
18011
19773
  exports.useParallax = useParallax;
18012
19774
  exports.usePermission = usePermission;
@@ -18021,6 +19783,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
18021
19783
  exports.useScroll = useScroll;
18022
19784
  exports.useSkeleton = useSkeleton;
18023
19785
  exports.useSticky = useSticky;
19786
+ exports.useSuspenseDirective = useSuspenseDirective;
18024
19787
  exports.useSwipe = useSwipe;
18025
19788
  exports.useThrottle = useThrottle;
18026
19789
  exports.useTooltip = useTooltip;
@@ -18095,6 +19858,7 @@ ${(_a2 = new Error("Stack trace").stack) == null ? void 0 : _a2.split("\n").slic
18095
19858
  exports.warnMissingParam = warnMissingParam;
18096
19859
  exports.warnNotSupported = warnNotSupported;
18097
19860
  exports.warnSSRNotSupported = warnSSRNotSupported;
19861
+ exports.watchEffectBinding = watchEffectBinding;
18098
19862
  exports.withPerformanceMonitoring = withPerformanceMonitoring;
18099
19863
  exports.wouldTextTruncate = wouldTextTruncate;
18100
19864
  exports.zhCN = zhCN;