viewgate-wrapper 1.10.10 → 1.10.12

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,37 +1,37 @@
1
1
  (function(){"use strict";try{if(typeof document<"u"){var r=document.createElement("style");r.appendChild(document.createTextNode('@import"https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap";body{margin:0!important;padding:0!important}:root{--vg-primary: #6366f1;--vg-primary-glow: rgba(99, 102, 241, .5);--vg-primary-gradient: linear-gradient(135deg, #6366f1 0%, #a855f7 100%);--vg-bg-glass: rgba(255, 255, 255, .7);--vg-radius: 16px;--vg-font-main: "Inter", system-ui, sans-serif;--vg-font-alt: "Inter", system-ui, sans-serif;--placeholder-color: #94a3b8;--vg-glass-border: rgba(255, 255, 255, .3);--vg-shadow-premium: 0 20px 50px rgba(0, 0, 0, .1)}.vg-container,.vg-container *{box-sizing:border-box}.vg-container{font-family:var(--vg-font-main);-webkit-font-smoothing:antialiased}.vg-glassmorphism{background:var(--vg-bg-glass);backdrop-filter:blur(16px) saturate(180%);-webkit-backdrop-filter:blur(16px) saturate(180%);border:1px solid var(--vg-glass-border);box-shadow:0 8px 32px #0000001a;border-radius:var(--vg-radius);position:relative}.vg-button-primary{background:var(--vg-primary-gradient);color:#fff;border:none;padding:12px 24px;font-family:var(--vg-font-main);font-size:14px;font-weight:700;cursor:pointer;transition:all .2s ease;border-radius:99px;display:flex;align-items:center;justify-content:center;gap:8px;box-shadow:0 4px 12px #6366f14d}.vg-button-primary:hover{transform:translateY(-2px);box-shadow:0 6px 20px #6366f166}.vg-button-primary:disabled,.vg-button-ghost:disabled{opacity:.5;cursor:not-allowed;filter:grayscale(.4);transform:none!important;box-shadow:none!important;pointer-events:none}.vg-button-ghost{background:#fffc;color:#1e293b;border:1px solid #e2e8f0;padding:10px 24px;font-family:var(--vg-font-main);font-size:14px;font-weight:600;cursor:pointer;transition:all .2s ease;border-radius:99px;display:flex;align-items:center;justify-content:center;gap:8px}.vg-button-ghost:hover{background:#fff;border-color:#cbd5e1;box-shadow:0 4px 12px #0000000d}.vg-badge{background:#f1f5f9;color:#64748b;padding:4px 12px;font-size:11px;border-radius:99px;font-weight:600;display:inline-flex;align-items:center;gap:6px}.vg-textarea{width:100%;box-sizing:border-box;border:1px solid #e2e8f0;border-radius:12px;padding:12px;font-family:var(--vg-font-main);font-size:15px;color:#0f172a;resize:none;outline:none;background:#f8fafc;transition:all .2s ease}.vg-textarea:focus{background:#fff;border-color:var(--vg-primary);box-shadow:0 0 0 4px #6366f11a}@keyframes vg-pop-in{0%{transform:scale(.6);opacity:0}70%{transform:scale(1.08);opacity:1}to{transform:scale(1);opacity:1}}@keyframes vg-slide-up-fade{0%{transform:translateY(12px) scale(.95);opacity:0}to{transform:translateY(0) scale(1);opacity:1}}.vg-animate-pop{animation:vg-pop-in .5s cubic-bezier(.34,1.56,.64,1) forwards}.vg-animate-slide-up{animation:vg-slide-up-fade .4s cubic-bezier(.22,1,.36,1) forwards}.vg-button-primary,.vg-button-ghost,.vg-pin-container,.vg-action-bar,.vg-glassmorphism{transition:all .3s cubic-bezier(.4,0,.2,1)}.vg-animate-slide{animation:vg-slide-in .4s cubic-bezier(.22,1,.36,1) forwards}.vg-animate-fade{animation:vg-fade-in .3s ease-out forwards}.vg-toasts{position:fixed;top:24px;right:24px;display:flex;flex-direction:column;gap:12px}.vg-toast{padding:12px 20px;display:flex;align-items:center;gap:12px;min-width:300px;border-radius:12px;box-shadow:0 10px 30px #0000001a;background:#fff}.vg-toast.success{border-left:6px solid #22c55e}.vg-toast.error{border-left:6px solid #ef4444}.vg-backdrop-blur{position:fixed;top:0;left:0;width:100%;height:100%;-webkit-backdrop-filter:blur(8px) grayscale(.2);backdrop-filter:blur(8px) grayscale(.2);background:#0000001a;pointer-events:none;transition:opacity .3s ease,clip-path .2s cubic-bezier(.19,1,.22,1)}.vg-selection-pulse{position:fixed;pointer-events:none;border:2px solid var(--vg-primary);border-radius:8px;box-shadow:0 0 0 0 var(--vg-primary-glow);animation:vg-pulse 2s infinite;transition:all .2s cubic-bezier(.19,1,.22,1)}@keyframes vg-pulse{0%{box-shadow:0 0 0 0 var(--vg-primary-glow)}70%{box-shadow:0 0 0 15px #6366f100}to{box-shadow:0 0 #6366f100}}.vg-selection-label{position:absolute;top:-40px;left:0;background:var(--vg-primary-gradient);color:#fff;padding:8px 16px;border-radius:20px;font-size:13px;font-weight:700;white-space:nowrap;box-shadow:0 4px 12px #6366f14d;display:flex;align-items:center;gap:8px}.vg-pin-container{transition:transform .2s ease}.vg-pin-container:hover{transform:scale(1.1)}.vg-formal-pin{width:32px;height:32px;border-radius:50%;background:var(--vg-primary-gradient);border:3px solid white;box-shadow:0 4px 12px #6366f166;display:flex;align-items:center;justify-content:center;color:#fff;transition:all .2s ease}.vg-formal-pin.ready{background:linear-gradient(135deg,#10b981,#059669);box-shadow:0 4px 12px #10b98166}.vg-formal-pin.modal-variant{background:linear-gradient(135deg,#f59e0b,#d97706);box-shadow:0 4px 12px #f59e0b66;border-style:dashed}.vg-pin-tooltip{position:absolute;top:calc(100% + 12px);left:50%;transform:translate(-50%);padding:12px 16px;border-radius:12px;background:#fff;color:#1e293b;width:240px;font-size:13px;box-shadow:0 10px 40px #00000026;opacity:0;pointer-events:none;transition:all .2s ease;border:1px solid #e2e8f0}.vg-pin-tooltip.vg-top{top:auto;bottom:calc(100% + 12px)}.vg-pin-container:hover .vg-pin-tooltip{opacity:1;transform:translate(-50%) translateY(-5px)}.vg-action-bar{display:flex;gap:12px;padding:0;background:transparent;border:none;box-shadow:none;-webkit-backdrop-filter:none;backdrop-filter:none}.vg-custom-scrollbar::-webkit-scrollbar{width:6px}.vg-custom-scrollbar::-webkit-scrollbar-track{background:transparent}.vg-custom-scrollbar::-webkit-scrollbar-thumb{background:#6366f166;border-radius:10px;transition:all .2s ease}.vg-custom-scrollbar::-webkit-scrollbar-thumb:hover{background:#6366f1b3}.vg-spinner{border:3px solid rgba(99,102,241,.1);border-top:3px solid var(--vg-primary);border-radius:50%;width:32px;height:32px;animation:vg-spin .8s linear infinite}@keyframes vg-spin{to{transform:rotate(360deg)}}.vg-animate-spin{animation:vg-spin .8s linear infinite}.vg-cursor-pointer,.vg-cursor-pointer *{cursor:pointer!important}')),document.head.appendChild(r)}}catch(a){console.error("vite-plugin-css-injected-by-js",a)}})();
2
- import _t, { useRef as fe, useState as S, useEffect as X, forwardRef as pt, createElement as Ne, createContext as Tt, useContext as Vt, useCallback as ve } from "react";
3
- import { createPortal as Pt } from "react-dom";
4
- var be = { exports: {} }, pe = {};
5
- var qe;
6
- function At() {
7
- if (qe) return pe;
8
- qe = 1;
2
+ import Tt, { useRef as ge, useState as j, useEffect as Z, forwardRef as mt, createElement as ze, createContext as Vt, useContext as Pt, useCallback as Ce } from "react";
3
+ import { createPortal as At } from "react-dom";
4
+ var Ee = { exports: {} }, fe = {};
5
+ var Xe;
6
+ function $t() {
7
+ if (Xe) return fe;
8
+ Xe = 1;
9
9
  var e = /* @__PURE__ */ Symbol.for("react.transitional.element"), t = /* @__PURE__ */ Symbol.for("react.fragment");
10
- function r(n, a, s) {
10
+ function r(n, s, a) {
11
11
  var i = null;
12
- if (s !== void 0 && (i = "" + s), a.key !== void 0 && (i = "" + a.key), "key" in a) {
13
- s = {};
14
- for (var d in a)
15
- d !== "key" && (s[d] = a[d]);
16
- } else s = a;
17
- return a = s.ref, {
12
+ if (a !== void 0 && (i = "" + a), s.key !== void 0 && (i = "" + s.key), "key" in s) {
13
+ a = {};
14
+ for (var d in s)
15
+ d !== "key" && (a[d] = s[d]);
16
+ } else a = s;
17
+ return s = a.ref, {
18
18
  $$typeof: e,
19
19
  type: n,
20
20
  key: i,
21
- ref: a !== void 0 ? a : null,
22
- props: s
21
+ ref: s !== void 0 ? s : null,
22
+ props: a
23
23
  };
24
24
  }
25
- return pe.Fragment = t, pe.jsx = r, pe.jsxs = r, pe;
25
+ return fe.Fragment = t, fe.jsx = r, fe.jsxs = r, fe;
26
26
  }
27
- var me = {};
28
- var Ye;
27
+ var he = {};
28
+ var Je;
29
29
  function Gt() {
30
- return Ye || (Ye = 1, process.env.NODE_ENV !== "production" && (function() {
30
+ return Je || (Je = 1, process.env.NODE_ENV !== "production" && (function() {
31
31
  function e(c) {
32
32
  if (c == null) return null;
33
33
  if (typeof c == "function")
34
- return c.$$typeof === oe ? null : c.displayName || c.name || null;
34
+ return c.$$typeof === ce ? null : c.displayName || c.name || null;
35
35
  if (typeof c == "string") return c;
36
36
  switch (c) {
37
37
  case P:
@@ -40,11 +40,11 @@ function Gt() {
40
40
  return "Profiler";
41
41
  case z:
42
42
  return "StrictMode";
43
- case Re:
43
+ case W:
44
44
  return "Suspense";
45
- case F:
45
+ case $:
46
46
  return "SuspenseList";
47
- case He:
47
+ case Be:
48
48
  return "Activity";
49
49
  }
50
50
  if (typeof c == "object")
@@ -53,19 +53,19 @@ function Gt() {
53
53
  ), c.$$typeof) {
54
54
  case T:
55
55
  return "Portal";
56
- case G:
56
+ case F:
57
57
  return c.displayName || "Context";
58
58
  case A:
59
59
  return (c._context.displayName || "Context") + ".Consumer";
60
- case O:
61
- var h = c.render;
62
- return c = c.displayName, c || (c = h.displayName || h.name || "", c = c !== "" ? "ForwardRef(" + c + ")" : "ForwardRef"), c;
60
+ case _:
61
+ var y = c.render;
62
+ return c = c.displayName, c || (c = y.displayName || y.name || "", c = c !== "" ? "ForwardRef(" + c + ")" : "ForwardRef"), c;
63
63
  case H:
64
- return h = c.displayName || null, h !== null ? h : e(c.type) || "Memo";
65
- case he:
66
- h = c._payload, c = c._init;
64
+ return y = c.displayName || null, y !== null ? y : e(c.type) || "Memo";
65
+ case xe:
66
+ y = c._payload, c = c._init;
67
67
  try {
68
- return e(c(h));
68
+ return e(c(y));
69
69
  } catch {
70
70
  }
71
71
  }
@@ -77,72 +77,72 @@ function Gt() {
77
77
  function r(c) {
78
78
  try {
79
79
  t(c);
80
- var h = !1;
80
+ var y = !1;
81
81
  } catch {
82
- h = !0;
82
+ y = !0;
83
83
  }
84
- if (h) {
85
- h = console;
86
- var v = h.error, E = typeof Symbol == "function" && Symbol.toStringTag && c[Symbol.toStringTag] || c.constructor.name || "Object";
87
- return v.call(
88
- h,
84
+ if (y) {
85
+ y = console;
86
+ var b = y.error, k = typeof Symbol == "function" && Symbol.toStringTag && c[Symbol.toStringTag] || c.constructor.name || "Object";
87
+ return b.call(
88
+ y,
89
89
  "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
90
- E
90
+ k
91
91
  ), t(c);
92
92
  }
93
93
  }
94
94
  function n(c) {
95
95
  if (c === P) return "<>";
96
- if (typeof c == "object" && c !== null && c.$$typeof === he)
96
+ if (typeof c == "object" && c !== null && c.$$typeof === xe)
97
97
  return "<...>";
98
98
  try {
99
- var h = e(c);
100
- return h ? "<" + h + ">" : "<...>";
99
+ var y = e(c);
100
+ return y ? "<" + y + ">" : "<...>";
101
101
  } catch {
102
102
  return "<...>";
103
103
  }
104
104
  }
105
- function a() {
106
- var c = Q.A;
105
+ function s() {
106
+ var c = te.A;
107
107
  return c === null ? null : c.getOwner();
108
108
  }
109
- function s() {
109
+ function a() {
110
110
  return Error("react-stack-top-frame");
111
111
  }
112
112
  function i(c) {
113
- if (ge.call(c, "key")) {
114
- var h = Object.getOwnPropertyDescriptor(c, "key").get;
115
- if (h && h.isReactWarning) return !1;
113
+ if (we.call(c, "key")) {
114
+ var y = Object.getOwnPropertyDescriptor(c, "key").get;
115
+ if (y && y.isReactWarning) return !1;
116
116
  }
117
117
  return c.key !== void 0;
118
118
  }
119
- function d(c, h) {
120
- function v() {
121
- ee || (ee = !0, console.error(
119
+ function d(c, y) {
120
+ function b() {
121
+ re || (re = !0, console.error(
122
122
  "%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
123
- h
123
+ y
124
124
  ));
125
125
  }
126
- v.isReactWarning = !0, Object.defineProperty(c, "key", {
127
- get: v,
126
+ b.isReactWarning = !0, Object.defineProperty(c, "key", {
127
+ get: b,
128
128
  configurable: !0
129
129
  });
130
130
  }
131
131
  function p() {
132
132
  var c = e(this.type);
133
- return Z[c] || (Z[c] = !0, console.error(
133
+ return Q[c] || (Q[c] = !0, console.error(
134
134
  "Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
135
135
  )), c = this.props.ref, c !== void 0 ? c : null;
136
136
  }
137
- function u(c, h, v, E, te, U) {
138
- var j = v.ref;
137
+ function u(c, y, b, k, ne, q) {
138
+ var O = b.ref;
139
139
  return c = {
140
- $$typeof: b,
140
+ $$typeof: w,
141
141
  type: c,
142
- key: h,
143
- props: v,
144
- _owner: E
145
- }, (j !== void 0 ? j : null) !== null ? Object.defineProperty(c, "ref", {
142
+ key: y,
143
+ props: b,
144
+ _owner: k
145
+ }, (O !== void 0 ? O : null) !== null ? Object.defineProperty(c, "ref", {
146
146
  enumerable: !1,
147
147
  get: p
148
148
  }) : Object.defineProperty(c, "ref", { enumerable: !1, value: null }), c._store = {}, Object.defineProperty(c._store, "validated", {
@@ -159,132 +159,132 @@ function Gt() {
159
159
  configurable: !1,
160
160
  enumerable: !1,
161
161
  writable: !0,
162
- value: te
162
+ value: ne
163
163
  }), Object.defineProperty(c, "_debugTask", {
164
164
  configurable: !1,
165
165
  enumerable: !1,
166
166
  writable: !0,
167
- value: U
167
+ value: q
168
168
  }), Object.freeze && (Object.freeze(c.props), Object.freeze(c)), c;
169
169
  }
170
- function w(c, h, v, E, te, U) {
171
- var j = h.children;
172
- if (j !== void 0)
173
- if (E)
174
- if (ye(j)) {
175
- for (E = 0; E < j.length; E++)
176
- m(j[E]);
177
- Object.freeze && Object.freeze(j);
170
+ function v(c, y, b, k, ne, q) {
171
+ var O = y.children;
172
+ if (O !== void 0)
173
+ if (k)
174
+ if (ve(O)) {
175
+ for (k = 0; k < O.length; k++)
176
+ m(O[k]);
177
+ Object.freeze && Object.freeze(O);
178
178
  } else
179
179
  console.error(
180
180
  "React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
181
181
  );
182
- else m(j);
183
- if (ge.call(h, "key")) {
184
- j = e(c);
185
- var V = Object.keys(h).filter(function(je) {
186
- return je !== "key";
182
+ else m(O);
183
+ if (we.call(y, "key")) {
184
+ O = e(c);
185
+ var V = Object.keys(y).filter(function(Te) {
186
+ return Te !== "key";
187
187
  });
188
- E = 0 < V.length ? "{key: someKey, " + V.join(": ..., ") + ": ...}" : "{key: someKey}", xe[j + E] || (V = 0 < V.length ? "{" + V.join(": ..., ") + ": ...}" : "{}", console.error(
188
+ k = 0 < V.length ? "{key: someKey, " + V.join(": ..., ") + ": ...}" : "{key: someKey}", be[O + k] || (V = 0 < V.length ? "{" + V.join(": ..., ") + ": ...}" : "{}", console.error(
189
189
  `A props object containing a "key" prop is being spread into JSX:
190
190
  let props = %s;
191
191
  <%s {...props} />
192
192
  React keys must be passed directly to JSX without using spread:
193
193
  let props = %s;
194
194
  <%s key={someKey} {...props} />`,
195
- E,
196
- j,
195
+ k,
196
+ O,
197
197
  V,
198
- j
199
- ), xe[j + E] = !0);
198
+ O
199
+ ), be[O + k] = !0);
200
200
  }
201
- if (j = null, v !== void 0 && (r(v), j = "" + v), i(h) && (r(h.key), j = "" + h.key), "key" in h) {
202
- v = {};
203
- for (var ce in h)
204
- ce !== "key" && (v[ce] = h[ce]);
205
- } else v = h;
206
- return j && d(
207
- v,
201
+ if (O = null, b !== void 0 && (r(b), O = "" + b), i(y) && (r(y.key), O = "" + y.key), "key" in y) {
202
+ b = {};
203
+ for (var de in y)
204
+ de !== "key" && (b[de] = y[de]);
205
+ } else b = y;
206
+ return O && d(
207
+ b,
208
208
  typeof c == "function" ? c.displayName || c.name || "Unknown" : c
209
209
  ), u(
210
210
  c,
211
- j,
212
- v,
213
- a(),
214
- te,
215
- U
211
+ O,
212
+ b,
213
+ s(),
214
+ ne,
215
+ q
216
216
  );
217
217
  }
218
218
  function m(c) {
219
- x(c) ? c._store && (c._store.validated = 1) : typeof c == "object" && c !== null && c.$$typeof === he && (c._payload.status === "fulfilled" ? x(c._payload.value) && c._payload.value._store && (c._payload.value._store.validated = 1) : c._store && (c._store.validated = 1));
219
+ x(c) ? c._store && (c._store.validated = 1) : typeof c == "object" && c !== null && c.$$typeof === xe && (c._payload.status === "fulfilled" ? x(c._payload.value) && c._payload.value._store && (c._payload.value._store.validated = 1) : c._store && (c._store.validated = 1));
220
220
  }
221
221
  function x(c) {
222
- return typeof c == "object" && c !== null && c.$$typeof === b;
222
+ return typeof c == "object" && c !== null && c.$$typeof === w;
223
223
  }
224
- var y = _t, b = /* @__PURE__ */ Symbol.for("react.transitional.element"), T = /* @__PURE__ */ Symbol.for("react.portal"), P = /* @__PURE__ */ Symbol.for("react.fragment"), z = /* @__PURE__ */ Symbol.for("react.strict_mode"), D = /* @__PURE__ */ Symbol.for("react.profiler"), A = /* @__PURE__ */ Symbol.for("react.consumer"), G = /* @__PURE__ */ Symbol.for("react.context"), O = /* @__PURE__ */ Symbol.for("react.forward_ref"), Re = /* @__PURE__ */ Symbol.for("react.suspense"), F = /* @__PURE__ */ Symbol.for("react.suspense_list"), H = /* @__PURE__ */ Symbol.for("react.memo"), he = /* @__PURE__ */ Symbol.for("react.lazy"), He = /* @__PURE__ */ Symbol.for("react.activity"), oe = /* @__PURE__ */ Symbol.for("react.client.reference"), Q = y.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, ge = Object.prototype.hasOwnProperty, ye = Array.isArray, W = console.createTask ? console.createTask : function() {
224
+ var f = Tt, w = /* @__PURE__ */ Symbol.for("react.transitional.element"), T = /* @__PURE__ */ Symbol.for("react.portal"), P = /* @__PURE__ */ Symbol.for("react.fragment"), z = /* @__PURE__ */ Symbol.for("react.strict_mode"), D = /* @__PURE__ */ Symbol.for("react.profiler"), A = /* @__PURE__ */ Symbol.for("react.consumer"), F = /* @__PURE__ */ Symbol.for("react.context"), _ = /* @__PURE__ */ Symbol.for("react.forward_ref"), W = /* @__PURE__ */ Symbol.for("react.suspense"), $ = /* @__PURE__ */ Symbol.for("react.suspense_list"), H = /* @__PURE__ */ Symbol.for("react.memo"), xe = /* @__PURE__ */ Symbol.for("react.lazy"), Be = /* @__PURE__ */ Symbol.for("react.activity"), ce = /* @__PURE__ */ Symbol.for("react.client.reference"), te = f.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, we = Object.prototype.hasOwnProperty, ve = Array.isArray, B = console.createTask ? console.createTask : function() {
225
225
  return null;
226
226
  };
227
- y = {
227
+ f = {
228
228
  react_stack_bottom_frame: function(c) {
229
229
  return c();
230
230
  }
231
231
  };
232
- var ee, Z = {}, ie = y.react_stack_bottom_frame.bind(
233
- y,
234
- s
235
- )(), B = W(n(s)), xe = {};
236
- me.Fragment = P, me.jsx = function(c, h, v) {
237
- var E = 1e4 > Q.recentlyCreatedOwnerStacks++;
238
- return w(
232
+ var re, Q = {}, le = f.react_stack_bottom_frame.bind(
233
+ f,
234
+ a
235
+ )(), U = B(n(a)), be = {};
236
+ he.Fragment = P, he.jsx = function(c, y, b) {
237
+ var k = 1e4 > te.recentlyCreatedOwnerStacks++;
238
+ return v(
239
239
  c,
240
- h,
241
- v,
240
+ y,
241
+ b,
242
242
  !1,
243
- E ? Error("react-stack-top-frame") : ie,
244
- E ? W(n(c)) : B
243
+ k ? Error("react-stack-top-frame") : le,
244
+ k ? B(n(c)) : U
245
245
  );
246
- }, me.jsxs = function(c, h, v) {
247
- var E = 1e4 > Q.recentlyCreatedOwnerStacks++;
248
- return w(
246
+ }, he.jsxs = function(c, y, b) {
247
+ var k = 1e4 > te.recentlyCreatedOwnerStacks++;
248
+ return v(
249
249
  c,
250
- h,
251
- v,
250
+ y,
251
+ b,
252
252
  !0,
253
- E ? Error("react-stack-top-frame") : ie,
254
- E ? W(n(c)) : B
253
+ k ? Error("react-stack-top-frame") : le,
254
+ k ? B(n(c)) : U
255
255
  );
256
256
  };
257
- })()), me;
257
+ })()), he;
258
258
  }
259
- var Xe;
260
- function $t() {
261
- return Xe || (Xe = 1, process.env.NODE_ENV === "production" ? be.exports = At() : be.exports = Gt()), be.exports;
259
+ var Ze;
260
+ function Lt() {
261
+ return Ze || (Ze = 1, process.env.NODE_ENV === "production" ? Ee.exports = $t() : Ee.exports = Gt()), Ee.exports;
262
262
  }
263
- var o = $t();
264
- const Lt = ({ children: e }) => {
265
- const t = fe(null), [r, n] = S(null);
266
- return X(() => {
263
+ var o = Lt();
264
+ const Nt = ({ children: e }) => {
265
+ const t = ge(null), [r, n] = j(null);
266
+ return Z(() => {
267
267
  if (t.current && !t.current.shadowRoot) {
268
- const a = t.current.attachShadow({ mode: "open" });
268
+ const s = t.current.attachShadow({ mode: "open" });
269
269
  document.querySelectorAll("style[data-vite-dev-id], style:not([data-vite-dev-id])").forEach((d) => {
270
- (d.textContent?.includes(".vg-") || d.textContent?.includes("--vg-")) && a.appendChild(d.cloneNode(!0));
270
+ (d.textContent?.includes(".vg-") || d.textContent?.includes("--vg-")) && s.appendChild(d.cloneNode(!0));
271
271
  });
272
272
  const i = document.createElement("link");
273
- i.rel = "stylesheet", i.href = "https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700;800;900&display=swap", a.appendChild(i), n(a);
273
+ i.rel = "stylesheet", i.href = "https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700;800;900&display=swap", s.appendChild(i), n(s);
274
274
  }
275
- }, []), /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ShadowRootWrapper.tsx:38", ref: t, id: "viewgate-shadow-host", children: r && Pt(e, r) });
275
+ }, []), /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ShadowRootWrapper.tsx:38", ref: t, id: "viewgate-shadow-host", children: r && At(e, r) });
276
276
  };
277
- const mt = (...e) => e.filter((t, r, n) => !!t && t.trim() !== "" && n.indexOf(t) === r).join(" ").trim();
278
- const Nt = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase();
277
+ const ft = (...e) => e.filter((t, r, n) => !!t && t.trim() !== "" && n.indexOf(t) === r).join(" ").trim();
278
+ const Mt = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase();
279
279
  const It = (e) => e.replace(
280
280
  /^([A-Z])|[\s-_]+(\w)/g,
281
281
  (t, r, n) => n ? n.toUpperCase() : r.toLowerCase()
282
282
  );
283
- const Je = (e) => {
283
+ const Ke = (e) => {
284
284
  const t = It(e);
285
285
  return t.charAt(0).toUpperCase() + t.slice(1);
286
286
  };
287
- var Mt = {
287
+ var zt = {
288
288
  xmlns: "http://www.w3.org/2000/svg",
289
289
  width: 24,
290
290
  height: 24,
@@ -295,75 +295,75 @@ var Mt = {
295
295
  strokeLinecap: "round",
296
296
  strokeLinejoin: "round"
297
297
  };
298
- const zt = (e) => {
298
+ const Dt = (e) => {
299
299
  for (const t in e)
300
300
  if (t.startsWith("aria-") || t === "role" || t === "title")
301
301
  return !0;
302
302
  return !1;
303
303
  };
304
- const Dt = pt(
304
+ const Ft = mt(
305
305
  ({
306
306
  color: e = "currentColor",
307
307
  size: t = 24,
308
308
  strokeWidth: r = 2,
309
309
  absoluteStrokeWidth: n,
310
- className: a = "",
311
- children: s,
310
+ className: s = "",
311
+ children: a,
312
312
  iconNode: i,
313
313
  ...d
314
- }, p) => Ne(
314
+ }, p) => ze(
315
315
  "svg",
316
316
  {
317
317
  ref: p,
318
- ...Mt,
318
+ ...zt,
319
319
  width: t,
320
320
  height: t,
321
321
  stroke: e,
322
322
  strokeWidth: n ? Number(r) * 24 / Number(t) : r,
323
- className: mt("lucide", a),
324
- ...!s && !zt(d) && { "aria-hidden": "true" },
323
+ className: ft("lucide", s),
324
+ ...!a && !Dt(d) && { "aria-hidden": "true" },
325
325
  ...d
326
326
  },
327
327
  [
328
- ...i.map(([u, w]) => Ne(u, w)),
329
- ...Array.isArray(s) ? s : [s]
328
+ ...i.map(([u, v]) => ze(u, v)),
329
+ ...Array.isArray(a) ? a : [a]
330
330
  ]
331
331
  )
332
332
  );
333
- const L = (e, t) => {
334
- const r = pt(
335
- ({ className: n, ...a }, s) => Ne(Dt, {
336
- ref: s,
333
+ const N = (e, t) => {
334
+ const r = mt(
335
+ ({ className: n, ...s }, a) => ze(Ft, {
336
+ ref: a,
337
337
  iconNode: t,
338
- className: mt(
339
- `lucide-${Nt(Je(e))}`,
338
+ className: ft(
339
+ `lucide-${Mt(Ke(e))}`,
340
340
  `lucide-${e}`,
341
341
  n
342
342
  ),
343
- ...a
343
+ ...s
344
344
  })
345
345
  );
346
- return r.displayName = Je(e), r;
346
+ return r.displayName = Ke(e), r;
347
347
  };
348
- const Ft = [
348
+ const Ht = [
349
349
  ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
350
350
  ["line", { x1: "12", x2: "12", y1: "8", y2: "12", key: "1pkeuh" }],
351
351
  ["line", { x1: "12", x2: "12.01", y1: "16", y2: "16", key: "4dfq90" }]
352
- ], Ht = L("circle-alert", Ft);
353
- const Wt = [
352
+ ], Wt = N("circle-alert", Ht);
353
+ const Bt = [
354
354
  ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
355
355
  ["path", { d: "m9 12 2 2 4-4", key: "dzmm74" }]
356
- ], ae = L("circle-check", Wt);
357
- const Bt = [
356
+ ], ie = N("circle-check", Bt);
357
+ const Ut = [
358
358
  ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
359
359
  ["path", { d: "M12 6v6l4 2", key: "mmk7yg" }]
360
- ], Ze = L("clock", Bt);
361
- const Ut = [
360
+ ], Qe = N("clock", Ut);
361
+ const qt = [
362
362
  ["path", { d: "M15 3h6v6", key: "1q9fwt" }],
363
363
  ["path", { d: "M10 14 21 3", key: "gplh6r" }],
364
364
  ["path", { d: "M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6", key: "a6xqqp" }]
365
- ], Ke = L("external-link", Ut);
366
- const qt = [
365
+ ], et = N("external-link", qt);
366
+ const Yt = [
367
367
  [
368
368
  "path",
369
369
  {
@@ -372,17 +372,17 @@ const qt = [
372
372
  }
373
373
  ],
374
374
  ["circle", { cx: "12", cy: "12", r: "3", key: "1v7zrd" }]
375
- ], Yt = L("eye", qt);
376
- const Xt = [
375
+ ], Xt = N("eye", Yt);
376
+ const Jt = [
377
377
  ["circle", { cx: "9", cy: "12", r: "1", key: "1vctgf" }],
378
378
  ["circle", { cx: "9", cy: "5", r: "1", key: "hp0tcf" }],
379
379
  ["circle", { cx: "9", cy: "19", r: "1", key: "fkjjf6" }],
380
380
  ["circle", { cx: "15", cy: "12", r: "1", key: "1tmaij" }],
381
381
  ["circle", { cx: "15", cy: "5", r: "1", key: "19l28e" }],
382
382
  ["circle", { cx: "15", cy: "19", r: "1", key: "f4zoj3" }]
383
- ], Qe = L("grip-vertical", Xt);
384
- const Jt = [["path", { d: "M21 12a9 9 0 1 1-6.219-8.56", key: "13zald" }]], Zt = L("loader-circle", Jt);
385
- const Kt = [
383
+ ], tt = N("grip-vertical", Jt);
384
+ const Zt = [["path", { d: "M21 12a9 9 0 1 1-6.219-8.56", key: "13zald" }]], Kt = N("loader-circle", Zt);
385
+ const Qt = [
386
386
  [
387
387
  "path",
388
388
  {
@@ -390,8 +390,8 @@ const Kt = [
390
390
  key: "18887p"
391
391
  }
392
392
  ]
393
- ], Ve = L("message-square", Kt);
394
- const Qt = [
393
+ ], $e = N("message-square", Qt);
394
+ const er = [
395
395
  [
396
396
  "path",
397
397
  {
@@ -399,8 +399,8 @@ const Qt = [
399
399
  key: "edeuup"
400
400
  }
401
401
  ]
402
- ], er = L("mouse-pointer-2", Qt);
403
- const tr = [
402
+ ], tr = N("mouse-pointer-2", er);
403
+ const rr = [
404
404
  [
405
405
  "path",
406
406
  {
@@ -409,12 +409,12 @@ const tr = [
409
409
  }
410
410
  ],
411
411
  ["path", { d: "m15 5 4 4", key: "1mk7zo" }]
412
- ], rr = L("pencil", tr);
413
- const nr = [
412
+ ], nr = N("pencil", rr);
413
+ const ar = [
414
414
  ["path", { d: "M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8", key: "1357e3" }],
415
415
  ["path", { d: "M3 3v5h5", key: "1xhq8a" }]
416
- ], sr = L("rotate-ccw", nr);
417
- const ar = [
416
+ ], sr = N("rotate-ccw", ar);
417
+ const or = [
418
418
  [
419
419
  "path",
420
420
  {
@@ -423,18 +423,18 @@ const ar = [
423
423
  }
424
424
  ],
425
425
  ["path", { d: "m21.854 2.147-10.94 10.939", key: "12cjpa" }]
426
- ], or = L("send", ar);
427
- const ir = [
426
+ ], ir = N("send", or);
427
+ const cr = [
428
428
  ["path", { d: "M10 11v6", key: "nco0om" }],
429
429
  ["path", { d: "M14 11v6", key: "outv1u" }],
430
430
  ["path", { d: "M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6", key: "miytrc" }],
431
431
  ["path", { d: "M3 6h18", key: "d0wm0j" }],
432
432
  ["path", { d: "M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2", key: "e791ji" }]
433
- ], et = L("trash-2", ir);
434
- const cr = [
433
+ ], rt = N("trash-2", cr);
434
+ const lr = [
435
435
  ["path", { d: "M18 6 6 18", key: "1bl5f8" }],
436
436
  ["path", { d: "m6 6 12 12", key: "d8bk6v" }]
437
- ], Pe = L("x", cr), lr = {
437
+ ], Ge = N("x", lr), dr = {
438
438
  en: {
439
439
  enterMode: "Enter Feedback Mode",
440
440
  exitMode: "Exit Mode",
@@ -527,64 +527,64 @@ const cr = [
527
527
  exitConfirmTitle: "¿Cerrar ViewGate?",
528
528
  exitConfirmMessage: "¿Estás seguro de que deseas cerrar ViewGate? Puedes volver a activarlo en cualquier momento agregando ?viewgate=true a la URL."
529
529
  }
530
- }, ft = Tt(void 0), dr = () => {
531
- const e = Vt(ft);
530
+ }, ht = Vt(void 0), ur = () => {
531
+ const e = Pt(ht);
532
532
  if (!e) throw new Error("useViewGate must be used within a ViewGateProvider");
533
533
  return e;
534
- }, Ie = "viewgate_enabled", ur = () => typeof window > "u" ? !1 : new URLSearchParams(window.location.search).has("viewgate") ? (sessionStorage.setItem(Ie, "true"), !0) : sessionStorage.getItem(Ie) === "true", Cn = ({
534
+ }, De = "viewgate_enabled", pr = () => typeof window > "u" ? !1 : new URLSearchParams(window.location.search).has("viewgate") ? (sessionStorage.setItem(De, "true"), !0) : sessionStorage.getItem(De) === "true", En = ({
535
535
  children: e,
536
536
  language: t = "es",
537
537
  apiKey: r,
538
538
  baseUrl: n = "https://view-gate.vercel.app"
539
539
  }) => {
540
- const [a, s] = S(!1), [i, d] = S([]);
541
- X(() => {
542
- s(ur());
540
+ const [s, a] = j(!1), [i, d] = j([]);
541
+ Z(() => {
542
+ a(pr());
543
543
  }, []);
544
544
  const p = () => {
545
- if (sessionStorage.removeItem(Ie), s(!1), typeof window < "u") {
545
+ if (sessionStorage.removeItem(De), a(!1), typeof window < "u") {
546
546
  const m = new URL(window.location.href);
547
547
  m.searchParams.delete("viewgate"), window.history.replaceState({}, "", m.toString());
548
548
  }
549
549
  }, u = (m, x) => {
550
- const y = Date.now();
551
- d((b) => [...b, { id: y, message: m, type: x }]), setTimeout(() => {
552
- d((b) => b.filter((T) => T.id !== y));
550
+ const f = Date.now();
551
+ d((w) => [...w, { id: f, message: m, type: x }]), setTimeout(() => {
552
+ d((w) => w.filter((T) => T.id !== f));
553
553
  }, 4e3);
554
- }, w = lr[t];
555
- return /* @__PURE__ */ o.jsxs(ft.Provider, { "data-source-path": "/src/components/ViewGateProvider.tsx:248", value: {
554
+ }, v = dr[t];
555
+ return /* @__PURE__ */ o.jsxs(ht.Provider, { "data-source-path": "/src/components/ViewGateProvider.tsx:248", value: {
556
556
  addToast: u,
557
557
  language: t,
558
- t: w,
558
+ t: v,
559
559
  apiKey: r,
560
560
  baseUrl: n,
561
561
  disableViewGate: p,
562
562
  hasActiveToasts: i.length > 0
563
563
  }, children: [
564
564
  e,
565
- a && /* @__PURE__ */ o.jsx(Lt, { "data-source-path": "/src/components/ViewGateProvider.tsx:259", children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateProvider.tsx:260", className: "vg-container", children: [
566
- /* @__PURE__ */ o.jsx(wn, { "data-source-path": "/src/components/ViewGateProvider.tsx:261" }),
565
+ s && /* @__PURE__ */ o.jsx(Nt, { "data-source-path": "/src/components/ViewGateProvider.tsx:259", children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateProvider.tsx:260", className: "vg-container", children: [
566
+ /* @__PURE__ */ o.jsx(vn, { "data-source-path": "/src/components/ViewGateProvider.tsx:261" }),
567
567
  /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateProvider.tsx:262", className: "vg-toasts", style: { zIndex: 2147483646 }, children: i.map((m) => /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateProvider.tsx:264", className: `vg-toast vg-animate-slide ${m.type}`, children: [
568
- m.type === "success" ? /* @__PURE__ */ o.jsx(ae, { "data-source-path": "/src/components/ViewGateProvider.tsx:266", size: 24, color: "#22c55e" }) : /* @__PURE__ */ o.jsx(Ht, { "data-source-path": "/src/components/ViewGateProvider.tsx:268", size: 24, color: "#ef4444" }),
568
+ m.type === "success" ? /* @__PURE__ */ o.jsx(ie, { "data-source-path": "/src/components/ViewGateProvider.tsx:266", size: 24, color: "#22c55e" }) : /* @__PURE__ */ o.jsx(Wt, { "data-source-path": "/src/components/ViewGateProvider.tsx:268", size: 24, color: "#ef4444" }),
569
569
  /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateProvider.tsx:270", children: [
570
- /* @__PURE__ */ o.jsx("strong", { "data-source-path": "/src/components/ViewGateProvider.tsx:271", style: { display: "block", fontSize: "13px", color: "#0f172a", textTransform: "uppercase", marginBottom: "2px" }, children: m.type === "success" ? w.successHeader : w.errorHeader }),
570
+ /* @__PURE__ */ o.jsx("strong", { "data-source-path": "/src/components/ViewGateProvider.tsx:271", style: { display: "block", fontSize: "13px", color: "#0f172a", textTransform: "uppercase", marginBottom: "2px" }, children: m.type === "success" ? v.successHeader : v.errorHeader }),
571
571
  /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateProvider.tsx:274", style: { fontSize: "14px", color: "#000000" }, children: m.message })
572
572
  ] })
573
573
  ] }, m.id)) })
574
574
  ] }) })
575
575
  ] });
576
576
  };
577
- function pr(e, t) {
577
+ function mr(e, t) {
578
578
  if (e.match(/^[a-z]+:\/\//i))
579
579
  return e;
580
580
  if (e.match(/^\/\//))
581
581
  return window.location.protocol + e;
582
582
  if (e.match(/^[a-z]+:/i))
583
583
  return e;
584
- const r = document.implementation.createHTMLDocument(), n = r.createElement("base"), a = r.createElement("a");
585
- return r.head.appendChild(n), r.body.appendChild(a), t && (n.href = t), a.href = e, a.href;
584
+ const r = document.implementation.createHTMLDocument(), n = r.createElement("base"), s = r.createElement("a");
585
+ return r.head.appendChild(n), r.body.appendChild(s), t && (n.href = t), s.href = e, s.href;
586
586
  }
587
- const mr = /* @__PURE__ */ (() => {
587
+ const fr = /* @__PURE__ */ (() => {
588
588
  let e = 0;
589
589
  const t = () => (
590
590
  // eslint-disable-next-line no-bitwise
@@ -592,33 +592,33 @@ const mr = /* @__PURE__ */ (() => {
592
592
  );
593
593
  return () => (e += 1, `u${t()}${e}`);
594
594
  })();
595
- function J(e) {
595
+ function K(e) {
596
596
  const t = [];
597
597
  for (let r = 0, n = e.length; r < n; r++)
598
598
  t.push(e[r]);
599
599
  return t;
600
600
  }
601
- let ne = null;
602
- function ht(e = {}) {
603
- return ne || (e.includeStyleProperties ? (ne = e.includeStyleProperties, ne) : (ne = J(window.getComputedStyle(document.documentElement)), ne));
601
+ let se = null;
602
+ function gt(e = {}) {
603
+ return se || (e.includeStyleProperties ? (se = e.includeStyleProperties, se) : (se = K(window.getComputedStyle(document.documentElement)), se));
604
604
  }
605
- function Ce(e, t) {
605
+ function Re(e, t) {
606
606
  const n = (e.ownerDocument.defaultView || window).getComputedStyle(e).getPropertyValue(t);
607
607
  return n ? parseFloat(n.replace("px", "")) : 0;
608
608
  }
609
- function fr(e) {
610
- const t = Ce(e, "border-left-width"), r = Ce(e, "border-right-width");
609
+ function hr(e) {
610
+ const t = Re(e, "border-left-width"), r = Re(e, "border-right-width");
611
611
  return e.clientWidth + t + r;
612
612
  }
613
- function hr(e) {
614
- const t = Ce(e, "border-top-width"), r = Ce(e, "border-bottom-width");
613
+ function gr(e) {
614
+ const t = Re(e, "border-top-width"), r = Re(e, "border-bottom-width");
615
615
  return e.clientHeight + t + r;
616
616
  }
617
- function gt(e, t = {}) {
618
- const r = t.width || fr(e), n = t.height || hr(e);
617
+ function yt(e, t = {}) {
618
+ const r = t.width || hr(e), n = t.height || gr(e);
619
619
  return { width: r, height: n };
620
620
  }
621
- function gr() {
621
+ function yr() {
622
622
  let e, t;
623
623
  try {
624
624
  t = process;
@@ -628,10 +628,10 @@ function gr() {
628
628
  return r && (e = parseInt(r, 10), Number.isNaN(e) && (e = 1)), e || window.devicePixelRatio || 1;
629
629
  }
630
630
  const I = 16384;
631
- function yr(e) {
631
+ function xr(e) {
632
632
  (e.width > I || e.height > I) && (e.width > I && e.height > I ? e.width > e.height ? (e.height *= I / e.width, e.width = I) : (e.width *= I / e.height, e.height = I) : e.width > I ? (e.height *= I / e.width, e.width = I) : (e.width *= I / e.height, e.height = I));
633
633
  }
634
- function Ee(e) {
634
+ function je(e) {
635
635
  return new Promise((t, r) => {
636
636
  const n = new Image();
637
637
  n.onload = () => {
@@ -641,427 +641,427 @@ function Ee(e) {
641
641
  }, n.onerror = r, n.crossOrigin = "anonymous", n.decoding = "async", n.src = e;
642
642
  });
643
643
  }
644
- async function xr(e) {
644
+ async function wr(e) {
645
645
  return Promise.resolve().then(() => new XMLSerializer().serializeToString(e)).then(encodeURIComponent).then((t) => `data:image/svg+xml;charset=utf-8,${t}`);
646
646
  }
647
- async function wr(e, t, r) {
648
- const n = "http://www.w3.org/2000/svg", a = document.createElementNS(n, "svg"), s = document.createElementNS(n, "foreignObject");
649
- return a.setAttribute("width", `${t}`), a.setAttribute("height", `${r}`), a.setAttribute("viewBox", `0 0 ${t} ${r}`), s.setAttribute("width", "100%"), s.setAttribute("height", "100%"), s.setAttribute("x", "0"), s.setAttribute("y", "0"), s.setAttribute("externalResourcesRequired", "true"), a.appendChild(s), s.appendChild(e), xr(a);
647
+ async function vr(e, t, r) {
648
+ const n = "http://www.w3.org/2000/svg", s = document.createElementNS(n, "svg"), a = document.createElementNS(n, "foreignObject");
649
+ return s.setAttribute("width", `${t}`), s.setAttribute("height", `${r}`), s.setAttribute("viewBox", `0 0 ${t} ${r}`), a.setAttribute("width", "100%"), a.setAttribute("height", "100%"), a.setAttribute("x", "0"), a.setAttribute("y", "0"), a.setAttribute("externalResourcesRequired", "true"), s.appendChild(a), a.appendChild(e), wr(s);
650
650
  }
651
- const $ = (e, t) => {
651
+ const L = (e, t) => {
652
652
  if (e instanceof t)
653
653
  return !0;
654
654
  const r = Object.getPrototypeOf(e);
655
- return r === null ? !1 : r.constructor.name === t.name || $(r, t);
655
+ return r === null ? !1 : r.constructor.name === t.name || L(r, t);
656
656
  };
657
- function vr(e) {
657
+ function br(e) {
658
658
  const t = e.getPropertyValue("content");
659
659
  return `${e.cssText} content: '${t.replace(/'|"/g, "")}';`;
660
660
  }
661
- function br(e, t) {
662
- return ht(t).map((r) => {
663
- const n = e.getPropertyValue(r), a = e.getPropertyPriority(r);
664
- return `${r}: ${n}${a ? " !important" : ""};`;
661
+ function Cr(e, t) {
662
+ return gt(t).map((r) => {
663
+ const n = e.getPropertyValue(r), s = e.getPropertyPriority(r);
664
+ return `${r}: ${n}${s ? " !important" : ""};`;
665
665
  }).join(" ");
666
666
  }
667
- function Cr(e, t, r, n) {
668
- const a = `.${e}:${t}`, s = r.cssText ? vr(r) : br(r, n);
669
- return document.createTextNode(`${a}{${s}}`);
667
+ function Er(e, t, r, n) {
668
+ const s = `.${e}:${t}`, a = r.cssText ? br(r) : Cr(r, n);
669
+ return document.createTextNode(`${s}{${a}}`);
670
670
  }
671
- function tt(e, t, r, n) {
672
- const a = window.getComputedStyle(e, r), s = a.getPropertyValue("content");
673
- if (s === "" || s === "none")
671
+ function nt(e, t, r, n) {
672
+ const s = window.getComputedStyle(e, r), a = s.getPropertyValue("content");
673
+ if (a === "" || a === "none")
674
674
  return;
675
- const i = mr();
675
+ const i = fr();
676
676
  try {
677
677
  t.className = `${t.className} ${i}`;
678
678
  } catch {
679
679
  return;
680
680
  }
681
681
  const d = document.createElement("style");
682
- d.appendChild(Cr(i, r, a, n)), t.appendChild(d);
682
+ d.appendChild(Er(i, r, s, n)), t.appendChild(d);
683
683
  }
684
- function Er(e, t, r) {
685
- tt(e, t, ":before", r), tt(e, t, ":after", r);
684
+ function Sr(e, t, r) {
685
+ nt(e, t, ":before", r), nt(e, t, ":after", r);
686
686
  }
687
- const rt = "application/font-woff", nt = "image/jpeg", Sr = {
688
- woff: rt,
689
- woff2: rt,
687
+ const at = "application/font-woff", st = "image/jpeg", kr = {
688
+ woff: at,
689
+ woff2: at,
690
690
  ttf: "application/font-truetype",
691
691
  eot: "application/vnd.ms-fontobject",
692
692
  png: "image/png",
693
- jpg: nt,
694
- jpeg: nt,
693
+ jpg: st,
694
+ jpeg: st,
695
695
  gif: "image/gif",
696
696
  tiff: "image/tiff",
697
697
  svg: "image/svg+xml",
698
698
  webp: "image/webp"
699
699
  };
700
- function kr(e) {
700
+ function Rr(e) {
701
701
  const t = /\.([^./]*?)$/g.exec(e);
702
702
  return t ? t[1] : "";
703
703
  }
704
- function De(e) {
705
- const t = kr(e).toLowerCase();
706
- return Sr[t] || "";
704
+ function He(e) {
705
+ const t = Rr(e).toLowerCase();
706
+ return kr[t] || "";
707
707
  }
708
- function Rr(e) {
708
+ function jr(e) {
709
709
  return e.split(/,/)[1];
710
710
  }
711
- function Me(e) {
711
+ function Fe(e) {
712
712
  return e.search(/^(data:)/) !== -1;
713
713
  }
714
- function jr(e, t) {
714
+ function Or(e, t) {
715
715
  return `data:${t};base64,${e}`;
716
716
  }
717
- async function yt(e, t, r) {
717
+ async function xt(e, t, r) {
718
718
  const n = await fetch(e, t);
719
719
  if (n.status === 404)
720
720
  throw new Error(`Resource "${n.url}" not found`);
721
- const a = await n.blob();
722
- return new Promise((s, i) => {
721
+ const s = await n.blob();
722
+ return new Promise((a, i) => {
723
723
  const d = new FileReader();
724
724
  d.onerror = i, d.onloadend = () => {
725
725
  try {
726
- s(r({ res: n, result: d.result }));
726
+ a(r({ res: n, result: d.result }));
727
727
  } catch (p) {
728
728
  i(p);
729
729
  }
730
- }, d.readAsDataURL(a);
730
+ }, d.readAsDataURL(s);
731
731
  });
732
732
  }
733
- const Ae = {};
734
- function Or(e, t, r) {
733
+ const Le = {};
734
+ function _r(e, t, r) {
735
735
  let n = e.replace(/\?.*/, "");
736
736
  return r && (n = e), /ttf|otf|eot|woff2?/i.test(n) && (n = n.replace(/.*\//, "")), t ? `[${t}]${n}` : n;
737
737
  }
738
- async function Fe(e, t, r) {
739
- const n = Or(e, t, r.includeQueryParams);
740
- if (Ae[n] != null)
741
- return Ae[n];
738
+ async function We(e, t, r) {
739
+ const n = _r(e, t, r.includeQueryParams);
740
+ if (Le[n] != null)
741
+ return Le[n];
742
742
  r.cacheBust && (e += (/\?/.test(e) ? "&" : "?") + (/* @__PURE__ */ new Date()).getTime());
743
- let a;
743
+ let s;
744
744
  try {
745
- const s = await yt(e, r.fetchRequestInit, ({ res: i, result: d }) => (t || (t = i.headers.get("Content-Type") || ""), Rr(d)));
746
- a = jr(s, t);
747
- } catch (s) {
748
- a = r.imagePlaceholder || "";
745
+ const a = await xt(e, r.fetchRequestInit, ({ res: i, result: d }) => (t || (t = i.headers.get("Content-Type") || ""), jr(d)));
746
+ s = Or(a, t);
747
+ } catch (a) {
748
+ s = r.imagePlaceholder || "";
749
749
  let i = `Failed to fetch resource: ${e}`;
750
- s && (i = typeof s == "string" ? s : s.message), i && console.warn(i);
750
+ a && (i = typeof a == "string" ? a : a.message), i && console.warn(i);
751
751
  }
752
- return Ae[n] = a, a;
752
+ return Le[n] = s, s;
753
753
  }
754
- async function _r(e) {
754
+ async function Tr(e) {
755
755
  const t = e.toDataURL();
756
- return t === "data:," ? e.cloneNode(!1) : Ee(t);
756
+ return t === "data:," ? e.cloneNode(!1) : je(t);
757
757
  }
758
- async function Tr(e, t) {
758
+ async function Vr(e, t) {
759
759
  if (e.currentSrc) {
760
- const s = document.createElement("canvas"), i = s.getContext("2d");
761
- s.width = e.clientWidth, s.height = e.clientHeight, i?.drawImage(e, 0, 0, s.width, s.height);
762
- const d = s.toDataURL();
763
- return Ee(d);
760
+ const a = document.createElement("canvas"), i = a.getContext("2d");
761
+ a.width = e.clientWidth, a.height = e.clientHeight, i?.drawImage(e, 0, 0, a.width, a.height);
762
+ const d = a.toDataURL();
763
+ return je(d);
764
764
  }
765
- const r = e.poster, n = De(r), a = await Fe(r, n, t);
766
- return Ee(a);
765
+ const r = e.poster, n = He(r), s = await We(r, n, t);
766
+ return je(s);
767
767
  }
768
- async function Vr(e, t) {
768
+ async function Pr(e, t) {
769
769
  var r;
770
770
  try {
771
771
  if (!((r = e?.contentDocument) === null || r === void 0) && r.body)
772
- return await Se(e.contentDocument.body, t, !0);
772
+ return await Oe(e.contentDocument.body, t, !0);
773
773
  } catch {
774
774
  }
775
775
  return e.cloneNode(!1);
776
776
  }
777
- async function Pr(e, t) {
778
- return $(e, HTMLCanvasElement) ? _r(e) : $(e, HTMLVideoElement) ? Tr(e, t) : $(e, HTMLIFrameElement) ? Vr(e, t) : e.cloneNode(xt(e));
777
+ async function Ar(e, t) {
778
+ return L(e, HTMLCanvasElement) ? Tr(e) : L(e, HTMLVideoElement) ? Vr(e, t) : L(e, HTMLIFrameElement) ? Pr(e, t) : e.cloneNode(wt(e));
779
779
  }
780
- const Ar = (e) => e.tagName != null && e.tagName.toUpperCase() === "SLOT", xt = (e) => e.tagName != null && e.tagName.toUpperCase() === "SVG";
780
+ const $r = (e) => e.tagName != null && e.tagName.toUpperCase() === "SLOT", wt = (e) => e.tagName != null && e.tagName.toUpperCase() === "SVG";
781
781
  async function Gr(e, t, r) {
782
- var n, a;
783
- if (xt(t))
782
+ var n, s;
783
+ if (wt(t))
784
784
  return t;
785
- let s = [];
786
- return Ar(e) && e.assignedNodes ? s = J(e.assignedNodes()) : $(e, HTMLIFrameElement) && (!((n = e.contentDocument) === null || n === void 0) && n.body) ? s = J(e.contentDocument.body.childNodes) : s = J(((a = e.shadowRoot) !== null && a !== void 0 ? a : e).childNodes), s.length === 0 || $(e, HTMLVideoElement) || await s.reduce((i, d) => i.then(() => Se(d, r)).then((p) => {
785
+ let a = [];
786
+ return $r(e) && e.assignedNodes ? a = K(e.assignedNodes()) : L(e, HTMLIFrameElement) && (!((n = e.contentDocument) === null || n === void 0) && n.body) ? a = K(e.contentDocument.body.childNodes) : a = K(((s = e.shadowRoot) !== null && s !== void 0 ? s : e).childNodes), a.length === 0 || L(e, HTMLVideoElement) || await a.reduce((i, d) => i.then(() => Oe(d, r)).then((p) => {
787
787
  p && t.appendChild(p);
788
788
  }), Promise.resolve()), t;
789
789
  }
790
- function $r(e, t, r) {
790
+ function Lr(e, t, r) {
791
791
  const n = t.style;
792
792
  if (!n)
793
793
  return;
794
- const a = window.getComputedStyle(e);
795
- a.cssText ? (n.cssText = a.cssText, n.transformOrigin = a.transformOrigin) : ht(r).forEach((s) => {
796
- let i = a.getPropertyValue(s);
797
- s === "font-size" && i.endsWith("px") && (i = `${Math.floor(parseFloat(i.substring(0, i.length - 2))) - 0.1}px`), $(e, HTMLIFrameElement) && s === "display" && i === "inline" && (i = "block"), s === "d" && t.getAttribute("d") && (i = `path(${t.getAttribute("d")})`), n.setProperty(s, i, a.getPropertyPriority(s));
794
+ const s = window.getComputedStyle(e);
795
+ s.cssText ? (n.cssText = s.cssText, n.transformOrigin = s.transformOrigin) : gt(r).forEach((a) => {
796
+ let i = s.getPropertyValue(a);
797
+ a === "font-size" && i.endsWith("px") && (i = `${Math.floor(parseFloat(i.substring(0, i.length - 2))) - 0.1}px`), L(e, HTMLIFrameElement) && a === "display" && i === "inline" && (i = "block"), a === "d" && t.getAttribute("d") && (i = `path(${t.getAttribute("d")})`), n.setProperty(a, i, s.getPropertyPriority(a));
798
798
  });
799
799
  }
800
- function Lr(e, t) {
801
- $(e, HTMLTextAreaElement) && (t.innerHTML = e.value), $(e, HTMLInputElement) && t.setAttribute("value", e.value);
802
- }
803
800
  function Nr(e, t) {
804
- if ($(e, HTMLSelectElement)) {
805
- const n = Array.from(t.children).find((a) => e.value === a.getAttribute("value"));
801
+ L(e, HTMLTextAreaElement) && (t.innerHTML = e.value), L(e, HTMLInputElement) && t.setAttribute("value", e.value);
802
+ }
803
+ function Mr(e, t) {
804
+ if (L(e, HTMLSelectElement)) {
805
+ const n = Array.from(t.children).find((s) => e.value === s.getAttribute("value"));
806
806
  n && n.setAttribute("selected", "");
807
807
  }
808
808
  }
809
809
  function Ir(e, t, r) {
810
- return $(t, Element) && ($r(e, t, r), Er(e, t, r), Lr(e, t), Nr(e, t)), t;
810
+ return L(t, Element) && (Lr(e, t, r), Sr(e, t, r), Nr(e, t), Mr(e, t)), t;
811
811
  }
812
- async function Mr(e, t) {
812
+ async function zr(e, t) {
813
813
  const r = e.querySelectorAll ? e.querySelectorAll("use") : [];
814
814
  if (r.length === 0)
815
815
  return e;
816
816
  const n = {};
817
- for (let s = 0; s < r.length; s++) {
818
- const d = r[s].getAttribute("xlink:href");
817
+ for (let a = 0; a < r.length; a++) {
818
+ const d = r[a].getAttribute("xlink:href");
819
819
  if (d) {
820
820
  const p = e.querySelector(d), u = document.querySelector(d);
821
- !p && u && !n[d] && (n[d] = await Se(u, t, !0));
821
+ !p && u && !n[d] && (n[d] = await Oe(u, t, !0));
822
822
  }
823
823
  }
824
- const a = Object.values(n);
825
- if (a.length) {
826
- const s = "http://www.w3.org/1999/xhtml", i = document.createElementNS(s, "svg");
827
- i.setAttribute("xmlns", s), i.style.position = "absolute", i.style.width = "0", i.style.height = "0", i.style.overflow = "hidden", i.style.display = "none";
828
- const d = document.createElementNS(s, "defs");
824
+ const s = Object.values(n);
825
+ if (s.length) {
826
+ const a = "http://www.w3.org/1999/xhtml", i = document.createElementNS(a, "svg");
827
+ i.setAttribute("xmlns", a), i.style.position = "absolute", i.style.width = "0", i.style.height = "0", i.style.overflow = "hidden", i.style.display = "none";
828
+ const d = document.createElementNS(a, "defs");
829
829
  i.appendChild(d);
830
- for (let p = 0; p < a.length; p++)
831
- d.appendChild(a[p]);
830
+ for (let p = 0; p < s.length; p++)
831
+ d.appendChild(s[p]);
832
832
  e.appendChild(i);
833
833
  }
834
834
  return e;
835
835
  }
836
- async function Se(e, t, r) {
837
- return !r && t.filter && !t.filter(e) ? null : Promise.resolve(e).then((n) => Pr(n, t)).then((n) => Gr(e, n, t)).then((n) => Ir(e, n, t)).then((n) => Mr(n, t));
836
+ async function Oe(e, t, r) {
837
+ return !r && t.filter && !t.filter(e) ? null : Promise.resolve(e).then((n) => Ar(n, t)).then((n) => Gr(e, n, t)).then((n) => Ir(e, n, t)).then((n) => zr(n, t));
838
838
  }
839
- const wt = /url\((['"]?)([^'"]+?)\1\)/g, zr = /url\([^)]+\)\s*format\((["']?)([^"']+)\1\)/g, Dr = /src:\s*(?:url\([^)]+\)\s*format\([^)]+\)[,;]\s*)+/g;
840
- function Fr(e) {
839
+ const vt = /url\((['"]?)([^'"]+?)\1\)/g, Dr = /url\([^)]+\)\s*format\((["']?)([^"']+)\1\)/g, Fr = /src:\s*(?:url\([^)]+\)\s*format\([^)]+\)[,;]\s*)+/g;
840
+ function Hr(e) {
841
841
  const t = e.replace(/([.*+?^${}()|\[\]\/\\])/g, "\\$1");
842
842
  return new RegExp(`(url\\(['"]?)(${t})(['"]?\\))`, "g");
843
843
  }
844
- function Hr(e) {
844
+ function Wr(e) {
845
845
  const t = [];
846
- return e.replace(wt, (r, n, a) => (t.push(a), r)), t.filter((r) => !Me(r));
846
+ return e.replace(vt, (r, n, s) => (t.push(s), r)), t.filter((r) => !Fe(r));
847
847
  }
848
- async function Wr(e, t, r, n, a) {
848
+ async function Br(e, t, r, n, s) {
849
849
  try {
850
- const s = r ? pr(t, r) : t, i = De(t);
850
+ const a = r ? mr(t, r) : t, i = He(t);
851
851
  let d;
852
- return a || (d = await Fe(s, i, n)), e.replace(Fr(t), `$1${d}$3`);
852
+ return s || (d = await We(a, i, n)), e.replace(Hr(t), `$1${d}$3`);
853
853
  } catch {
854
854
  }
855
855
  return e;
856
856
  }
857
- function Br(e, { preferredFontFormat: t }) {
858
- return t ? e.replace(Dr, (r) => {
857
+ function Ur(e, { preferredFontFormat: t }) {
858
+ return t ? e.replace(Fr, (r) => {
859
859
  for (; ; ) {
860
- const [n, , a] = zr.exec(r) || [];
861
- if (!a)
860
+ const [n, , s] = Dr.exec(r) || [];
861
+ if (!s)
862
862
  return "";
863
- if (a === t)
863
+ if (s === t)
864
864
  return `src: ${n};`;
865
865
  }
866
866
  }) : e;
867
867
  }
868
- function vt(e) {
869
- return e.search(wt) !== -1;
868
+ function bt(e) {
869
+ return e.search(vt) !== -1;
870
870
  }
871
- async function bt(e, t, r) {
872
- if (!vt(e))
871
+ async function Ct(e, t, r) {
872
+ if (!bt(e))
873
873
  return e;
874
- const n = Br(e, r);
875
- return Hr(n).reduce((s, i) => s.then((d) => Wr(d, i, t, r)), Promise.resolve(n));
874
+ const n = Ur(e, r);
875
+ return Wr(n).reduce((a, i) => a.then((d) => Br(d, i, t, r)), Promise.resolve(n));
876
876
  }
877
- async function se(e, t, r) {
877
+ async function oe(e, t, r) {
878
878
  var n;
879
- const a = (n = t.style) === null || n === void 0 ? void 0 : n.getPropertyValue(e);
880
- if (a) {
881
- const s = await bt(a, null, r);
882
- return t.style.setProperty(e, s, t.style.getPropertyPriority(e)), !0;
879
+ const s = (n = t.style) === null || n === void 0 ? void 0 : n.getPropertyValue(e);
880
+ if (s) {
881
+ const a = await Ct(s, null, r);
882
+ return t.style.setProperty(e, a, t.style.getPropertyPriority(e)), !0;
883
883
  }
884
884
  return !1;
885
885
  }
886
- async function Ur(e, t) {
887
- await se("background", e, t) || await se("background-image", e, t), await se("mask", e, t) || await se("-webkit-mask", e, t) || await se("mask-image", e, t) || await se("-webkit-mask-image", e, t);
888
- }
889
886
  async function qr(e, t) {
890
- const r = $(e, HTMLImageElement);
891
- if (!(r && !Me(e.src)) && !($(e, SVGImageElement) && !Me(e.href.baseVal)))
887
+ await oe("background", e, t) || await oe("background-image", e, t), await oe("mask", e, t) || await oe("-webkit-mask", e, t) || await oe("mask-image", e, t) || await oe("-webkit-mask-image", e, t);
888
+ }
889
+ async function Yr(e, t) {
890
+ const r = L(e, HTMLImageElement);
891
+ if (!(r && !Fe(e.src)) && !(L(e, SVGImageElement) && !Fe(e.href.baseVal)))
892
892
  return;
893
- const n = r ? e.src : e.href.baseVal, a = await Fe(n, De(n), t);
894
- await new Promise((s, i) => {
895
- e.onload = s, e.onerror = t.onImageErrorHandler ? (...p) => {
893
+ const n = r ? e.src : e.href.baseVal, s = await We(n, He(n), t);
894
+ await new Promise((a, i) => {
895
+ e.onload = a, e.onerror = t.onImageErrorHandler ? (...p) => {
896
896
  try {
897
- s(t.onImageErrorHandler(...p));
897
+ a(t.onImageErrorHandler(...p));
898
898
  } catch (u) {
899
899
  i(u);
900
900
  }
901
901
  } : i;
902
902
  const d = e;
903
- d.decode && (d.decode = s), d.loading === "lazy" && (d.loading = "eager"), r ? (e.srcset = "", e.src = a) : e.href.baseVal = a;
903
+ d.decode && (d.decode = a), d.loading === "lazy" && (d.loading = "eager"), r ? (e.srcset = "", e.src = s) : e.href.baseVal = s;
904
904
  });
905
905
  }
906
- async function Yr(e, t) {
907
- const n = J(e.childNodes).map((a) => Ct(a, t));
906
+ async function Xr(e, t) {
907
+ const n = K(e.childNodes).map((s) => Et(s, t));
908
908
  await Promise.all(n).then(() => e);
909
909
  }
910
- async function Ct(e, t) {
911
- $(e, Element) && (await Ur(e, t), await qr(e, t), await Yr(e, t));
910
+ async function Et(e, t) {
911
+ L(e, Element) && (await qr(e, t), await Yr(e, t), await Xr(e, t));
912
912
  }
913
- function Xr(e, t) {
913
+ function Jr(e, t) {
914
914
  const { style: r } = e;
915
915
  t.backgroundColor && (r.backgroundColor = t.backgroundColor), t.width && (r.width = `${t.width}px`), t.height && (r.height = `${t.height}px`);
916
916
  const n = t.style;
917
- return n != null && Object.keys(n).forEach((a) => {
918
- r[a] = n[a];
917
+ return n != null && Object.keys(n).forEach((s) => {
918
+ r[s] = n[s];
919
919
  }), e;
920
920
  }
921
- const st = {};
922
- async function at(e) {
923
- let t = st[e];
921
+ const ot = {};
922
+ async function it(e) {
923
+ let t = ot[e];
924
924
  if (t != null)
925
925
  return t;
926
926
  const n = await (await fetch(e)).text();
927
- return t = { url: e, cssText: n }, st[e] = t, t;
927
+ return t = { url: e, cssText: n }, ot[e] = t, t;
928
928
  }
929
- async function ot(e, t) {
929
+ async function ct(e, t) {
930
930
  let r = e.cssText;
931
- const n = /url\(["']?([^"')]+)["']?\)/g, s = (r.match(/url\([^)]+\)/g) || []).map(async (i) => {
931
+ const n = /url\(["']?([^"')]+)["']?\)/g, a = (r.match(/url\([^)]+\)/g) || []).map(async (i) => {
932
932
  let d = i.replace(n, "$1");
933
- return d.startsWith("https://") || (d = new URL(d, e.url).href), yt(d, t.fetchRequestInit, ({ result: p }) => (r = r.replace(i, `url(${p})`), [i, p]));
933
+ return d.startsWith("https://") || (d = new URL(d, e.url).href), xt(d, t.fetchRequestInit, ({ result: p }) => (r = r.replace(i, `url(${p})`), [i, p]));
934
934
  });
935
- return Promise.all(s).then(() => r);
935
+ return Promise.all(a).then(() => r);
936
936
  }
937
- function it(e) {
937
+ function lt(e) {
938
938
  if (e == null)
939
939
  return [];
940
940
  const t = [], r = /(\/\*[\s\S]*?\*\/)/gi;
941
941
  let n = e.replace(r, "");
942
- const a = new RegExp("((@.*?keyframes [\\s\\S]*?){([\\s\\S]*?}\\s*?)})", "gi");
942
+ const s = new RegExp("((@.*?keyframes [\\s\\S]*?){([\\s\\S]*?}\\s*?)})", "gi");
943
943
  for (; ; ) {
944
- const p = a.exec(n);
944
+ const p = s.exec(n);
945
945
  if (p === null)
946
946
  break;
947
947
  t.push(p[0]);
948
948
  }
949
- n = n.replace(a, "");
950
- const s = /@import[\s\S]*?url\([^)]*\)[\s\S]*?;/gi, i = "((\\s*?(?:\\/\\*[\\s\\S]*?\\*\\/)?\\s*?@media[\\s\\S]*?){([\\s\\S]*?)}\\s*?})|(([\\s\\S]*?){([\\s\\S]*?)})", d = new RegExp(i, "gi");
949
+ n = n.replace(s, "");
950
+ const a = /@import[\s\S]*?url\([^)]*\)[\s\S]*?;/gi, i = "((\\s*?(?:\\/\\*[\\s\\S]*?\\*\\/)?\\s*?@media[\\s\\S]*?){([\\s\\S]*?)}\\s*?})|(([\\s\\S]*?){([\\s\\S]*?)})", d = new RegExp(i, "gi");
951
951
  for (; ; ) {
952
- let p = s.exec(n);
952
+ let p = a.exec(n);
953
953
  if (p === null) {
954
954
  if (p = d.exec(n), p === null)
955
955
  break;
956
- s.lastIndex = d.lastIndex;
956
+ a.lastIndex = d.lastIndex;
957
957
  } else
958
- d.lastIndex = s.lastIndex;
958
+ d.lastIndex = a.lastIndex;
959
959
  t.push(p[0]);
960
960
  }
961
961
  return t;
962
962
  }
963
- async function Jr(e, t) {
963
+ async function Zr(e, t) {
964
964
  const r = [], n = [];
965
- return e.forEach((a) => {
966
- if ("cssRules" in a)
965
+ return e.forEach((s) => {
966
+ if ("cssRules" in s)
967
967
  try {
968
- J(a.cssRules || []).forEach((s, i) => {
969
- if (s.type === CSSRule.IMPORT_RULE) {
968
+ K(s.cssRules || []).forEach((a, i) => {
969
+ if (a.type === CSSRule.IMPORT_RULE) {
970
970
  let d = i + 1;
971
- const p = s.href, u = at(p).then((w) => ot(w, t)).then((w) => it(w).forEach((m) => {
971
+ const p = a.href, u = it(p).then((v) => ct(v, t)).then((v) => lt(v).forEach((m) => {
972
972
  try {
973
- a.insertRule(m, m.startsWith("@import") ? d += 1 : a.cssRules.length);
973
+ s.insertRule(m, m.startsWith("@import") ? d += 1 : s.cssRules.length);
974
974
  } catch (x) {
975
975
  console.error("Error inserting rule from remote css", {
976
976
  rule: m,
977
977
  error: x
978
978
  });
979
979
  }
980
- })).catch((w) => {
981
- console.error("Error loading remote css", w.toString());
980
+ })).catch((v) => {
981
+ console.error("Error loading remote css", v.toString());
982
982
  });
983
983
  n.push(u);
984
984
  }
985
985
  });
986
- } catch (s) {
986
+ } catch (a) {
987
987
  const i = e.find((d) => d.href == null) || document.styleSheets[0];
988
- a.href != null && n.push(at(a.href).then((d) => ot(d, t)).then((d) => it(d).forEach((p) => {
988
+ s.href != null && n.push(it(s.href).then((d) => ct(d, t)).then((d) => lt(d).forEach((p) => {
989
989
  i.insertRule(p, i.cssRules.length);
990
990
  })).catch((d) => {
991
991
  console.error("Error loading remote stylesheet", d);
992
- })), console.error("Error inlining remote css file", s);
992
+ })), console.error("Error inlining remote css file", a);
993
993
  }
994
- }), Promise.all(n).then(() => (e.forEach((a) => {
995
- if ("cssRules" in a)
994
+ }), Promise.all(n).then(() => (e.forEach((s) => {
995
+ if ("cssRules" in s)
996
996
  try {
997
- J(a.cssRules || []).forEach((s) => {
998
- r.push(s);
997
+ K(s.cssRules || []).forEach((a) => {
998
+ r.push(a);
999
999
  });
1000
- } catch (s) {
1001
- console.error(`Error while reading CSS rules from ${a.href}`, s);
1000
+ } catch (a) {
1001
+ console.error(`Error while reading CSS rules from ${s.href}`, a);
1002
1002
  }
1003
1003
  }), r));
1004
1004
  }
1005
- function Zr(e) {
1006
- return e.filter((t) => t.type === CSSRule.FONT_FACE_RULE).filter((t) => vt(t.style.getPropertyValue("src")));
1005
+ function Kr(e) {
1006
+ return e.filter((t) => t.type === CSSRule.FONT_FACE_RULE).filter((t) => bt(t.style.getPropertyValue("src")));
1007
1007
  }
1008
- async function Kr(e, t) {
1008
+ async function Qr(e, t) {
1009
1009
  if (e.ownerDocument == null)
1010
1010
  throw new Error("Provided element is not within a Document");
1011
- const r = J(e.ownerDocument.styleSheets), n = await Jr(r, t);
1012
- return Zr(n);
1011
+ const r = K(e.ownerDocument.styleSheets), n = await Zr(r, t);
1012
+ return Kr(n);
1013
1013
  }
1014
- function Et(e) {
1014
+ function St(e) {
1015
1015
  return e.trim().replace(/["']/g, "");
1016
1016
  }
1017
- function Qr(e) {
1017
+ function en(e) {
1018
1018
  const t = /* @__PURE__ */ new Set();
1019
1019
  function r(n) {
1020
- (n.style.fontFamily || getComputedStyle(n).fontFamily).split(",").forEach((s) => {
1021
- t.add(Et(s));
1022
- }), Array.from(n.children).forEach((s) => {
1023
- s instanceof HTMLElement && r(s);
1020
+ (n.style.fontFamily || getComputedStyle(n).fontFamily).split(",").forEach((a) => {
1021
+ t.add(St(a));
1022
+ }), Array.from(n.children).forEach((a) => {
1023
+ a instanceof HTMLElement && r(a);
1024
1024
  });
1025
1025
  }
1026
1026
  return r(e), t;
1027
1027
  }
1028
- async function en(e, t) {
1029
- const r = await Kr(e, t), n = Qr(e);
1030
- return (await Promise.all(r.filter((s) => n.has(Et(s.style.fontFamily))).map((s) => {
1031
- const i = s.parentStyleSheet ? s.parentStyleSheet.href : null;
1032
- return bt(s.cssText, i, t);
1028
+ async function tn(e, t) {
1029
+ const r = await Qr(e, t), n = en(e);
1030
+ return (await Promise.all(r.filter((a) => n.has(St(a.style.fontFamily))).map((a) => {
1031
+ const i = a.parentStyleSheet ? a.parentStyleSheet.href : null;
1032
+ return Ct(a.cssText, i, t);
1033
1033
  }))).join(`
1034
1034
  `);
1035
1035
  }
1036
- async function tn(e, t) {
1037
- const r = t.fontEmbedCSS != null ? t.fontEmbedCSS : t.skipFonts ? null : await en(e, t);
1036
+ async function rn(e, t) {
1037
+ const r = t.fontEmbedCSS != null ? t.fontEmbedCSS : t.skipFonts ? null : await tn(e, t);
1038
1038
  if (r) {
1039
- const n = document.createElement("style"), a = document.createTextNode(r);
1040
- n.appendChild(a), e.firstChild ? e.insertBefore(n, e.firstChild) : e.appendChild(n);
1039
+ const n = document.createElement("style"), s = document.createTextNode(r);
1040
+ n.appendChild(s), e.firstChild ? e.insertBefore(n, e.firstChild) : e.appendChild(n);
1041
1041
  }
1042
1042
  }
1043
- async function rn(e, t = {}) {
1044
- const { width: r, height: n } = gt(e, t), a = await Se(e, t, !0);
1045
- return await tn(a, t), await Ct(a, t), Xr(a, t), await wr(a, r, n);
1046
- }
1047
1043
  async function nn(e, t = {}) {
1048
- const { width: r, height: n } = gt(e, t), a = await rn(e, t), s = await Ee(a), i = document.createElement("canvas"), d = i.getContext("2d"), p = t.pixelRatio || gr(), u = t.canvasWidth || r, w = t.canvasHeight || n;
1049
- return i.width = u * p, i.height = w * p, t.skipAutoScale || yr(i), i.style.width = `${u}`, i.style.height = `${w}`, t.backgroundColor && (d.fillStyle = t.backgroundColor, d.fillRect(0, 0, i.width, i.height)), d.drawImage(s, 0, 0, i.width, i.height), i;
1044
+ const { width: r, height: n } = yt(e, t), s = await Oe(e, t, !0);
1045
+ return await rn(s, t), await Et(s, t), Jr(s, t), await vr(s, r, n);
1050
1046
  }
1051
- async function ct(e, t = {}) {
1052
- return (await nn(e, t)).toDataURL();
1047
+ async function an(e, t = {}) {
1048
+ const { width: r, height: n } = yt(e, t), s = await nn(e, t), a = await je(s), i = document.createElement("canvas"), d = i.getContext("2d"), p = t.pixelRatio || yr(), u = t.canvasWidth || r, v = t.canvasHeight || n;
1049
+ return i.width = u * p, i.height = v * p, t.skipAutoScale || xr(i), i.style.width = `${u}`, i.style.height = `${v}`, t.backgroundColor && (d.fillStyle = t.backgroundColor, d.fillRect(0, 0, i.width, i.height)), d.drawImage(a, 0, 0, i.width, i.height), i;
1053
1050
  }
1054
- const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 15, cn = () => {
1051
+ async function dt(e, t = {}) {
1052
+ return (await an(e, t)).toDataURL();
1053
+ }
1054
+ const _e = 2147483647, Ne = _e, Me = 2e6, sn = _e - 10, on = _e - 5, cn = _e - 15, Se = "data-vg-pin-id", ln = () => {
1055
1055
  const e = window.innerWidth;
1056
1056
  return e < 768 ? "mobile" : e < 1024 ? "tablet" : "desktop";
1057
- }, ln = (e) => {
1057
+ }, dn = (e) => {
1058
1058
  let t = 0;
1059
1059
  for (let r = 0; r < e.length; r++) {
1060
1060
  const n = e.charCodeAt(r);
1061
1061
  t = (t << 5) - t + n, t = t & t;
1062
1062
  }
1063
1063
  return Math.abs(t).toString(16);
1064
- }, dn = (e, t) => {
1064
+ }, un = (e, t) => {
1065
1065
  if (!e) return "";
1066
1066
  try {
1067
1067
  const r = new Date(e);
@@ -1076,20 +1076,20 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1076
1076
  } catch {
1077
1077
  return "";
1078
1078
  }
1079
- }, un = (e) => {
1079
+ }, pn = (e) => {
1080
1080
  const t = (e.innerText || "").slice(0, 30).trim(), r = {
1081
1081
  tag: e.tagName.toLowerCase(),
1082
- classHash: ln(e.className),
1082
+ classHash: dn(e.className),
1083
1083
  textSnippet: t,
1084
1084
  parentTag: e.parentElement?.tagName.toLowerCase(),
1085
1085
  neighborCount: e.parentElement?.children.length || 0
1086
1086
  }, n = e.getAttribute("aria-label");
1087
1087
  n && (r.ariaLabel = n);
1088
- const a = e.getAttribute("role");
1089
- a && (r.role = a);
1090
- const s = e.getAttribute("name");
1091
- return s && (r.name = s), r;
1092
- }, pn = /* @__PURE__ */ (() => {
1088
+ const s = e.getAttribute("role");
1089
+ s && (r.role = s);
1090
+ const a = e.getAttribute("name");
1091
+ return a && (r.name = a), r;
1092
+ }, mn = /* @__PURE__ */ (() => {
1093
1093
  let e = null, t = null;
1094
1094
  return (r) => {
1095
1095
  if (!r || typeof window > "u" || typeof document > "u") return r;
@@ -1097,33 +1097,33 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1097
1097
  try {
1098
1098
  if (e || (e = document.createElement("canvas"), e.width = 1, e.height = 1), t || (t = e.getContext("2d", { willReadFrequently: !0 })), t) {
1099
1099
  t.fillStyle = "#000000", t.fillStyle = r;
1100
- const s = t.fillStyle;
1101
- if (s && !s.includes("oklch") && !s.includes("oklab"))
1102
- return s;
1100
+ const a = t.fillStyle;
1101
+ if (a && !a.includes("oklch") && !a.includes("oklab"))
1102
+ return a;
1103
1103
  }
1104
1104
  const n = document.createElement("div");
1105
1105
  n.style.color = r, document.body.appendChild(n);
1106
- const a = getComputedStyle(n).color;
1107
- return document.body.removeChild(n), a && !a.includes("oklch") ? a : "rgb(0,0,0)";
1106
+ const s = getComputedStyle(n).color;
1107
+ return document.body.removeChild(n), s && !s.includes("oklch") ? s : "rgb(0,0,0)";
1108
1108
  } catch {
1109
1109
  return "rgb(0,0,0)";
1110
1110
  }
1111
1111
  return r;
1112
1112
  };
1113
- })(), lt = (e, t, r, n) => new Promise((a) => {
1114
- const s = new Image();
1115
- s.onload = () => {
1113
+ })(), ut = (e, t, r, n) => new Promise((s) => {
1114
+ const a = new Image();
1115
+ a.onload = () => {
1116
1116
  const i = document.createElement("canvas"), d = window.devicePixelRatio || 1, p = t.width + r * 2, u = t.height + r * 2;
1117
1117
  i.width = p * d, i.height = u * d;
1118
- const w = i.getContext("2d");
1119
- if (w) {
1120
- w.scale(d, d);
1121
- let m = (t.left - r) * n, x = (t.top - r) * n, y = p * n, b = u * n, T = 0, P = 0, z = p, D = u;
1122
- m < 0 && (T = Math.abs(m) / n, y += m, z -= T, m = 0), m + y > s.width && (y = s.width - m, z = y / n), x < 0 && (P = Math.abs(x) / n, b += x, D -= P, x = 0), x + b > s.height && (b = s.height - x, D = b / n), w.fillStyle = "#ffffff", w.fillRect(0, 0, p, u), y > 0 && b > 0 && w.drawImage(s, m, x, y, b, T, P, z, D);
1118
+ const v = i.getContext("2d");
1119
+ if (v) {
1120
+ v.scale(d, d);
1121
+ let m = (t.left - r) * n, x = (t.top - r) * n, f = p * n, w = u * n, T = 0, P = 0, z = p, D = u;
1122
+ m < 0 && (T = Math.abs(m) / n, f += m, z -= T, m = 0), m + f > a.width && (f = a.width - m, z = f / n), x < 0 && (P = Math.abs(x) / n, w += x, D -= P, x = 0), x + w > a.height && (w = a.height - x, D = w / n), v.fillStyle = "#ffffff", v.fillRect(0, 0, p, u), f > 0 && w > 0 && v.drawImage(a, m, x, f, w, T, P, z, D);
1123
1123
  }
1124
- a(i.toDataURL("image/png"));
1125
- }, s.onerror = () => a(""), s.src = e;
1126
- }), mn = (e) => {
1124
+ s(i.toDataURL("image/png"));
1125
+ }, a.onerror = () => s(""), a.src = e;
1126
+ }), fn = (e) => {
1127
1127
  const t = window.getComputedStyle(e), r = {};
1128
1128
  return [
1129
1129
  "display",
@@ -1136,55 +1136,55 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1136
1136
  "width",
1137
1137
  "height",
1138
1138
  "z-index"
1139
- ].forEach((a) => {
1140
- const s = t.getPropertyValue(a);
1141
- r[a] = pn(s);
1139
+ ].forEach((s) => {
1140
+ const a = t.getPropertyValue(s);
1141
+ r[s] = mn(a);
1142
1142
  }), r;
1143
- }, fn = (e) => {
1144
- const r = Object.keys(e).find((s) => s.startsWith("__reactFiber$") || s.startsWith("__reactInternalInstance$"));
1143
+ }, hn = (e) => {
1144
+ const r = Object.keys(e).find((a) => a.startsWith("__reactFiber$") || a.startsWith("__reactInternalInstance$"));
1145
1145
  if (!r) return "";
1146
1146
  const n = [];
1147
- let a = e[r];
1148
- for (; a; ) {
1149
- const s = a.type;
1150
- if (typeof s == "function") {
1151
- const i = s.displayName || s.name;
1147
+ let s = e[r];
1148
+ for (; s; ) {
1149
+ const a = s.type;
1150
+ if (typeof a == "function") {
1151
+ const i = a.displayName || a.name;
1152
1152
  i && !i.includes("ViewGate") && !n.includes(i) && n.unshift(i);
1153
1153
  }
1154
- a = a.return;
1154
+ s = s.return;
1155
1155
  }
1156
1156
  return n.join(" > ") || "Generic Component";
1157
- }, St = (e) => {
1157
+ }, kt = (e) => {
1158
1158
  if (!e) return !1;
1159
1159
  const t = window.getComputedStyle(e), r = e.getBoundingClientRect(), n = e.getAttribute("role");
1160
1160
  if (n && ["listbox", "menu", "combobox", "tooltip", "option"].includes(n)) return !1;
1161
- const s = 120;
1162
- return r.width < s && r.height < s || t.position !== "fixed" && t.position !== "absolute" ? !1 : !!(e.closest('[role="dialog"]') || e.closest('[aria-modal="true"]') || e.classList.contains("modal") || e.classList.contains("modal-content"));
1163
- }, dt = (e) => {
1161
+ const a = 120;
1162
+ return r.width < a && r.height < a || t.position !== "fixed" && t.position !== "absolute" ? !1 : !!(e.closest('[role="dialog"]') || e.closest('[aria-modal="true"]') || e.classList.contains("modal") || e.classList.contains("modal-content"));
1163
+ }, ye = (e) => {
1164
1164
  if (!e.isConnected) return !1;
1165
1165
  const t = window.getComputedStyle(e);
1166
1166
  if (t.display === "none" || t.visibility === "hidden" || t.opacity === "0" || e.offsetWidth === 0 || e.offsetHeight === 0) return !1;
1167
1167
  let r = e.parentElement;
1168
1168
  for (; r; ) {
1169
- const a = window.getComputedStyle(r);
1170
- if (a.display === "none" || a.visibility === "hidden" || a.opacity === "0") return !1;
1169
+ const s = window.getComputedStyle(r);
1170
+ if (s.display === "none" || s.visibility === "hidden" || s.opacity === "0") return !1;
1171
1171
  r = r.parentElement;
1172
1172
  }
1173
1173
  const n = e.getBoundingClientRect();
1174
1174
  return !(n.width === 0 || n.height === 0 || n.top === 0 && n.left === 0 && n.width > window.innerWidth * 0.9);
1175
- }, ze = (e, t = document) => {
1175
+ }, ke = (e, t = document) => {
1176
1176
  const r = t.querySelector(e);
1177
1177
  if (r) return r;
1178
1178
  const n = t.querySelectorAll("*");
1179
- for (const a of Array.from(n)) {
1180
- const s = a.shadowRoot;
1181
- if (s) {
1182
- const i = ze(e, s);
1179
+ for (const s of Array.from(n)) {
1180
+ const a = s.shadowRoot;
1181
+ if (a) {
1182
+ const i = ke(e, a);
1183
1183
  if (i) return i;
1184
1184
  }
1185
1185
  }
1186
1186
  return null;
1187
- }, ut = (e, t) => {
1187
+ }, pt = (e, t) => {
1188
1188
  let r = document.elementFromPoint(e, t);
1189
1189
  for (; r && r.shadowRoot; ) {
1190
1190
  const n = r.shadowRoot.elementFromPoint(e, t);
@@ -1192,43 +1192,55 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1192
1192
  r = n;
1193
1193
  }
1194
1194
  return r;
1195
- }, hn = (e) => {
1195
+ }, gn = (e) => {
1196
1196
  if (!e.tag) return null;
1197
1197
  const t = document.getElementsByTagName(e.tag);
1198
1198
  let r = null, n = 0;
1199
- for (let a = 0; a < t.length; a++) {
1200
- const s = t[a];
1199
+ for (let s = 0; s < t.length; s++) {
1200
+ const a = t[s];
1201
1201
  let i = 0;
1202
- s.innerText?.includes(e.text.slice(0, 20)) && (i += 4), e.fingerprint?.classHash && s.className.includes(e.fingerprint.classHash) && (i += 2), e.fingerprint?.ariaLabel && s.getAttribute("aria-label") === e.fingerprint.ariaLabel && (i += 3), e.fingerprint?.role && s.getAttribute("role") === e.fingerprint.role && (i += 2), e.parentContext && (s.parentElement?.innerText || "").includes(e.parentContext.slice(0, 30)) && (i += 2), e.fingerprint?.neighborCount === s.parentElement?.children.length && (i += 1), e.fingerprint?.parentTag === s.parentElement?.tagName.toLowerCase() && (i += 1), i > n && i >= 5 && (n = i, r = s);
1202
+ a.innerText?.includes(e.text.slice(0, 20)) && (i += 4), e.fingerprint?.classHash && a.className.includes(e.fingerprint.classHash) && (i += 2), e.fingerprint?.ariaLabel && a.getAttribute("aria-label") === e.fingerprint.ariaLabel && (i += 3), e.fingerprint?.role && a.getAttribute("role") === e.fingerprint.role && (i += 2), e.parentContext && (a.parentElement?.innerText || "").includes(e.parentContext.slice(0, 30)) && (i += 2), e.fingerprint?.neighborCount === a.parentElement?.children.length && (i += 1), e.fingerprint?.parentTag === a.parentElement?.tagName.toLowerCase() && (i += 1), i > n && i >= 5 && (n = i, r = a);
1203
1203
  }
1204
1204
  return r;
1205
- }, gn = (e) => {
1206
- let t = ze(e.selector);
1207
- if (t) return t;
1205
+ }, yn = (e, t) => {
1206
+ if (t) {
1207
+ const n = ke(`[${Se}="${t}"]`);
1208
+ if (n)
1209
+ return ye(n) ? n : null;
1210
+ }
1211
+ let r = ke(e.selector);
1212
+ if (r && ye(r))
1213
+ if (e.metadata?.isModal && !r.closest('[role="dialog"], [aria-modal="true"], .modal, .modal-content'))
1214
+ r = null;
1215
+ else
1216
+ return r;
1208
1217
  if (e.fallbackSelectors) {
1209
- for (const r of e.fallbackSelectors)
1210
- if (t = ze(r), t) return t;
1218
+ for (const n of e.fallbackSelectors)
1219
+ if (r = ke(n), r && ye(r)) {
1220
+ if (e.metadata?.isModal && !r.closest('[role="dialog"], [aria-modal="true"], .modal, .modal-content')) continue;
1221
+ return r;
1222
+ }
1211
1223
  }
1212
- return t = hn(e), t || null;
1213
- }, Le = (e) => ({
1224
+ return r = gn(e), r && ye(r) ? e.metadata?.isModal && !r.closest('[role="dialog"], [aria-modal="true"], .modal, .modal-content') ? null : r : null;
1225
+ }, Ie = (e) => ({
1214
1226
  tag: e.tagName.toLowerCase(),
1215
1227
  text: (e.innerText || e.getAttribute("placeholder") || "").slice(0, 50).trim(),
1216
1228
  role: e.getAttribute("role") || void 0,
1217
1229
  type: e.getAttribute("type") || void 0
1218
- }), yn = (e) => {
1230
+ }), xn = (e) => {
1219
1231
  const t = e.parentElement;
1220
1232
  if (!t) return;
1221
- const r = Array.from(t.children).filter((i) => i !== e).slice(0, 5).map((i) => Le(i)), n = Array.from(t.children), a = n.indexOf(e);
1222
- let s = "middle";
1223
- return a === 0 && (s = "start"), a === n.length - 1 && (s = "end"), {
1233
+ const r = Array.from(t.children).filter((i) => i !== e).slice(0, 5).map((i) => Ie(i)), n = Array.from(t.children), s = n.indexOf(e);
1234
+ let a = "middle";
1235
+ return s === 0 && (a = "start"), s === n.length - 1 && (a = "end"), {
1224
1236
  target: {
1225
- ...Le(e),
1226
- location: `${s} of ${t.tagName.toLowerCase()}`
1237
+ ...Ie(e),
1238
+ location: `${a} of ${t.tagName.toLowerCase()}`
1227
1239
  },
1228
- parent: Le(t),
1240
+ parent: Ie(t),
1229
1241
  siblings: r
1230
1242
  };
1231
- }, xn = (e) => {
1243
+ }, wn = (e) => {
1232
1244
  let t = "unknown:0", r = e;
1233
1245
  for (; r; ) {
1234
1246
  const m = r.getAttribute("data-source-path");
@@ -1238,47 +1250,53 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1238
1250
  }
1239
1251
  r = r.parentElement;
1240
1252
  }
1241
- const n = fn(e), a = [], s = [], i = (m) => {
1253
+ const n = hn(e), s = [], a = [], i = (m) => {
1242
1254
  const x = [];
1243
- let y = m;
1244
- for (; y && y.nodeType === Node.ELEMENT_NODE; ) {
1245
- let b = y.nodeName.toLowerCase();
1246
- s.unshift(b);
1247
- const T = y.id && !y.id.startsWith("__") ? y.id : null;
1248
- T && a.push(`#${T}`);
1249
- const P = y.getAttribute("data-testid") || y.getAttribute("data-qa");
1250
- P && a.push(`[data-testid="${P}"]`);
1251
- const z = y.getAttribute("aria-label"), D = y.getAttribute("role"), A = y.getAttribute("name");
1255
+ let f = m;
1256
+ for (; f && f.nodeType === Node.ELEMENT_NODE; ) {
1257
+ let w = f.nodeName.toLowerCase();
1258
+ a.unshift(w);
1259
+ const T = f.id && !f.id.startsWith("__") ? f.id : null;
1260
+ T && s.push(`#${T}`);
1261
+ const P = f.getAttribute("data-testid") || f.getAttribute("data-qa");
1262
+ P && s.push(`[data-testid="${P}"]`);
1263
+ const z = f.getAttribute("placeholder"), D = f.getAttribute("aria-label"), A = f.getAttribute("role"), F = f.getAttribute("name"), _ = f.getAttribute("title");
1252
1264
  if (P) {
1253
- b = `[${y.hasAttribute("data-testid") ? "data-testid" : "data-qa"}="${P}"]`, x.unshift(b);
1265
+ w = `[${f.hasAttribute("data-testid") ? "data-testid" : "data-qa"}="${P}"]`, x.unshift(w);
1254
1266
  break;
1255
1267
  } else if (T) {
1256
- b = "#" + T, x.unshift(b);
1268
+ w = "#" + T, x.unshift(w);
1257
1269
  break;
1258
1270
  } else if (z) {
1259
- b = `${y.localName}[aria-label="${z}"]`, x.unshift(b);
1271
+ w = `${f.localName}[placeholder="${z}"]`, x.unshift(w);
1260
1272
  break;
1261
1273
  } else if (D) {
1262
- b = `${y.localName}[role="${D}"]`, x.unshift(b);
1274
+ w = `${f.localName}[aria-label="${D}"]`, x.unshift(w);
1263
1275
  break;
1264
1276
  } else if (A) {
1265
- b = `${y.localName}[name="${A}"]`, x.unshift(b);
1277
+ w = `${f.localName}[role="${A}"]`, x.unshift(w);
1278
+ break;
1279
+ } else if (F) {
1280
+ w = `${f.localName}[name="${F}"]`, x.unshift(w);
1281
+ break;
1282
+ } else if (_) {
1283
+ w = `${f.localName}[title="${_}"]`, x.unshift(w);
1266
1284
  break;
1267
1285
  } else {
1268
- let G = y, O = 1;
1269
- for (; G.previousElementSibling; )
1270
- G = G.previousElementSibling, G.nodeName.toLowerCase() === y.nodeName.toLowerCase() && O++;
1271
- O > 1 && (b += `:nth-of-type(${O})`);
1286
+ let W = f, $ = 1;
1287
+ for (; W.previousElementSibling; )
1288
+ W = W.previousElementSibling, W.nodeName.toLowerCase() === f.nodeName.toLowerCase() && $++;
1289
+ $ > 1 && (w += `:nth-of-type(${$})`);
1272
1290
  }
1273
- x.unshift(b), y = y.parentElement;
1291
+ x.unshift(w), f = f.parentElement;
1274
1292
  }
1275
1293
  return x.join(" > ");
1276
- }, d = St(e.closest('[role="dialog"], [aria-modal="true"], .modal, .modal-content')), p = i(e), u = {};
1294
+ }, d = kt(e.closest('[role="dialog"], [aria-modal="true"], .modal, .modal-content')), p = i(e), u = {};
1277
1295
  ["placeholder", "aria-label", "name", "type", "alt", "title", "value", "role"].forEach((m) => {
1278
1296
  const x = e.getAttribute(m);
1279
1297
  x && (u[m] = x);
1280
1298
  });
1281
- const w = `${e.tagName.toLowerCase()}-${(e.innerText || "").slice(0, 20).replace(/\s+/g, "_")}-${p.split(" > ").slice(-1)}`;
1299
+ const v = `${e.tagName.toLowerCase()}-${(e.innerText || "").slice(0, 20).replace(/\s+/g, "_")}-${p.split(" > ").slice(-1)}`;
1282
1300
  return {
1283
1301
  tag: e.tagName.toLowerCase(),
1284
1302
  id: e.id || "",
@@ -1288,254 +1306,256 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1288
1306
  outerHtml: e.outerHTML,
1289
1307
  parentContext: (e.parentElement?.innerText || "").slice(0, 150).trim(),
1290
1308
  componentPath: n,
1291
- signature: w,
1309
+ signature: v,
1292
1310
  source: t,
1293
1311
  attributes: u,
1294
- fallbackSelectors: [...new Set(a)].slice(0, 5),
1295
- domPath: s.slice(-10),
1312
+ fallbackSelectors: [...new Set(s)].slice(0, 5),
1313
+ domPath: a.slice(-10),
1296
1314
  viewportSize: { width: window.innerWidth, height: window.innerHeight },
1297
- uiContext: yn(e),
1298
- fingerprint: un(e),
1315
+ uiContext: xn(e),
1316
+ fingerprint: pn(e),
1299
1317
  metadata: {
1300
1318
  hint: `Edit ${t.split(":")[0]} at line ${t.split(":")[1] || "?"}`,
1301
- computedStyles: mn(e),
1302
- viewportBreakpoint: cn(),
1319
+ computedStyles: fn(e),
1320
+ viewportBreakpoint: ln(),
1303
1321
  outerHtml: e.outerHTML.slice(0, 1500),
1304
1322
  scrollPosition: { x: window.scrollX, y: window.scrollY },
1305
1323
  isModal: d
1306
1324
  }
1307
1325
  };
1308
- }, wn = () => {
1309
- const { addToast: e, language: t, t: r, apiKey: n, baseUrl: a, disableViewGate: s, hasActiveToasts: i } = dr(), [d, p] = S(!1), [u, w] = S(null), [m, x] = S(null), [y, b] = S(""), [T, P] = S(!1), [z, D] = S(!1), [A, G] = S(!1), [O, Re] = S([]), [F, H] = S(null), [he, He] = S(!1), [oe, Q] = S(!1), [ge, ye] = S({}), [W, ee] = S(null), [Z, ie] = S(!1), [B, xe] = S(() => {
1326
+ }, vn = () => {
1327
+ const { addToast: e, language: t, t: r, apiKey: n, baseUrl: s, disableViewGate: a, hasActiveToasts: i } = ur(), [d, p] = j(!1), [u, v] = j(null), [m, x] = j(null), [f, w] = j(""), [T, P] = j(!1), [z, D] = j(!1), [A, F] = j(!1), [_, W] = j([]), [$, H] = j(null), [xe, Be] = j(!1), [ce, te] = j(!1), [we, ve] = j({}), [B, re] = j(null), [Q, le] = j(!1), [U, be] = j(() => {
1310
1328
  if (typeof window > "u") return { top: 24, right: 24 };
1311
1329
  const l = localStorage.getItem("vg-exit-pos");
1312
1330
  return l ? JSON.parse(l) : { top: 24, right: 24 };
1313
- }), [c, h] = S(!1), v = fe(null), [E, te] = S(() => {
1331
+ }), [c, y] = j(!1), b = ge(null), [k, ne] = j(() => {
1314
1332
  if (typeof window > "u") return { bottom: 30, right: 30 };
1315
1333
  const l = localStorage.getItem("vg-bar-pos");
1316
1334
  return l ? JSON.parse(l) : { bottom: 30, right: 30 };
1317
- }), [U, j] = S(!1), V = fe(null), ce = (l) => {
1335
+ }), [q, O] = j(!1), V = ge(null), de = (l) => {
1318
1336
  l.preventDefault(), l.stopPropagation();
1319
- const f = l.currentTarget.parentElement?.getBoundingClientRect();
1320
- f && (h(!0), v.current = {
1337
+ const h = l.currentTarget.parentElement?.getBoundingClientRect();
1338
+ h && (y(!0), b.current = {
1321
1339
  x: l.clientX,
1322
1340
  y: l.clientY,
1323
- top: B.top,
1324
- right: B.right,
1325
- width: f.width,
1326
- height: f.height
1341
+ top: U.top,
1342
+ right: U.right,
1343
+ width: h.width,
1344
+ height: h.height
1327
1345
  });
1328
- }, je = (l) => {
1346
+ }, Te = (l) => {
1329
1347
  l.preventDefault(), l.stopPropagation();
1330
- const f = l.currentTarget.parentElement?.getBoundingClientRect();
1331
- f && (j(!0), V.current = {
1348
+ const h = l.currentTarget.parentElement?.getBoundingClientRect();
1349
+ h && (O(!0), V.current = {
1332
1350
  x: l.clientX,
1333
1351
  y: l.clientY,
1334
- bottom: E.bottom,
1335
- right: E.right,
1336
- width: f.width,
1337
- height: f.height
1352
+ bottom: k.bottom,
1353
+ right: k.right,
1354
+ width: h.width,
1355
+ height: h.height
1338
1356
  });
1339
1357
  };
1340
- X(() => {
1341
- if (!c && !U) return;
1358
+ Z(() => {
1359
+ if (!c && !q) return;
1342
1360
  const l = (g) => {
1343
- if (c && v.current) {
1344
- const M = g.clientX - v.current.x, _ = g.clientY - v.current.y;
1345
- let k = v.current.top + _, C = v.current.right - M;
1361
+ if (c && b.current) {
1362
+ const G = g.clientX - b.current.x, C = g.clientY - b.current.y;
1363
+ let E = b.current.top + C, S = b.current.right - G;
1346
1364
  const R = 10;
1347
- k = Math.max(R, Math.min(window.innerHeight - v.current.height - R, k)), C = Math.max(R, Math.min(window.innerWidth - v.current.width - R, C)), xe({ top: k, right: C });
1365
+ E = Math.max(R, Math.min(window.innerHeight - b.current.height - R, E)), S = Math.max(R, Math.min(window.innerWidth - b.current.width - R, S)), be({ top: E, right: S });
1348
1366
  }
1349
- if (U && V.current) {
1350
- const M = g.clientX - V.current.x, _ = g.clientY - V.current.y;
1351
- let k = V.current.bottom - _, C = V.current.right - M;
1367
+ if (q && V.current) {
1368
+ const G = g.clientX - V.current.x, C = g.clientY - V.current.y;
1369
+ let E = V.current.bottom - C, S = V.current.right - G;
1352
1370
  const R = 10;
1353
- k = Math.max(R, Math.min(window.innerHeight - V.current.height - R, k)), C = Math.max(R, Math.min(window.innerWidth - V.current.width - R, C)), te({ bottom: k, right: C });
1371
+ E = Math.max(R, Math.min(window.innerHeight - V.current.height - R, E)), S = Math.max(R, Math.min(window.innerWidth - V.current.width - R, S)), ne({ bottom: E, right: S });
1354
1372
  }
1355
- }, f = () => {
1356
- c && (h(!1), localStorage.setItem("vg-exit-pos", JSON.stringify(B)), v.current = null), U && (j(!1), localStorage.setItem("vg-bar-pos", JSON.stringify(E)), V.current = null);
1373
+ }, h = () => {
1374
+ c && (y(!1), localStorage.setItem("vg-exit-pos", JSON.stringify(U)), b.current = null), q && (O(!1), localStorage.setItem("vg-bar-pos", JSON.stringify(k)), V.current = null);
1357
1375
  };
1358
- return window.addEventListener("mousemove", l), window.addEventListener("mouseup", f), () => {
1359
- window.removeEventListener("mousemove", l), window.removeEventListener("mouseup", f);
1376
+ return window.addEventListener("mousemove", l), window.addEventListener("mouseup", h), () => {
1377
+ window.removeEventListener("mousemove", l), window.removeEventListener("mouseup", h);
1360
1378
  };
1361
- }, [c, U, B, E]);
1362
- const [We, Oe] = S(null), [Be, Ue] = S(""), [Rt, jt] = S({}), re = fe(null), le = fe(null), de = ve(() => {
1363
- le.current || (le.current = requestAnimationFrame(() => {
1364
- const l = {}, g = Array.from(document.querySelectorAll('[role="dialog"], [aria-modal="true"], .modal, .modal-content')).find((_) => St(_) && dt(_)), M = !!g;
1365
- O.forEach((_) => {
1366
- if (!_.reference) return;
1367
- const k = gn(_.reference), C = !!_.reference.metadata?.isModal;
1368
- if (k && dt(k)) {
1369
- let R = !1;
1370
- if (M ? R = g.contains(k) : R = !C, !R) return;
1371
- const N = k.getBoundingClientRect(), q = N.left + N.width / 2, ue = N.top + N.height / 2;
1372
- if (q >= 0 && q <= window.innerWidth && ue >= 0 && ue <= window.innerHeight) {
1373
- const Y = document.elementFromPoint(q, ue);
1374
- if (Y && !k.contains(Y) && !re.current?.contains(Y))
1379
+ }, [c, q, U, k]);
1380
+ const [Ue, Ve] = j(null), [qe, Ye] = j(""), [jt, Ot] = j({}), ae = ge(null), ue = ge(null), pe = Ce(() => {
1381
+ ue.current || (ue.current = requestAnimationFrame(() => {
1382
+ const l = {}, g = Array.from(document.querySelectorAll('[role="dialog"], [aria-modal="true"], .modal, .modal-content')).find((C) => kt(C) && ye(C)), G = !!g;
1383
+ _.forEach((C) => {
1384
+ if (!C.reference) return;
1385
+ const E = yn(C.reference, C._id), S = !!C.reference.metadata?.isModal;
1386
+ if (E) {
1387
+ const R = E.getAttribute(Se);
1388
+ R ? R !== C._id && (console.warn(`Element already tagged with ${R}, skipping ${C._id}`), R.length < 10 && E.setAttribute(Se, C._id)) : E.setAttribute(Se, C._id);
1389
+ let Y = !1;
1390
+ if (G ? Y = g.contains(E) : Y = !S, !Y) return;
1391
+ const M = E.getBoundingClientRect(), me = M.left + M.width / 2, X = M.top + M.height / 2;
1392
+ if (me >= 0 && me <= window.innerWidth && X >= 0 && X <= window.innerHeight) {
1393
+ const J = document.elementFromPoint(me, X);
1394
+ if (J && !E.contains(J) && !ae.current?.contains(J))
1375
1395
  return;
1376
1396
  }
1377
- l[_._id] = {
1378
- top: N.top + window.scrollY,
1379
- left: N.left + window.scrollX,
1380
- width: N.width,
1381
- isModal: C
1397
+ l[C._id] = {
1398
+ top: M.top + window.scrollY,
1399
+ left: M.left + window.scrollX,
1400
+ width: M.width,
1401
+ isModal: S
1382
1402
  };
1383
1403
  }
1384
- }), jt(l), le.current = null;
1404
+ }), Ot(l), ue.current = null;
1385
1405
  }));
1386
- }, [O]), K = ve(async () => {
1406
+ }, [_]), ee = Ce(async () => {
1387
1407
  if (n) {
1388
- Q(!0);
1408
+ te(!0);
1389
1409
  try {
1390
- const l = await fetch(`${a}/api/annotations`, {
1410
+ const l = await fetch(`${s}/api/annotations`, {
1391
1411
  headers: { "x-api-key": n }
1392
1412
  });
1393
1413
  if (l.ok) {
1394
- const f = await l.json();
1395
- Re(f.data || []);
1414
+ const G = ((await l.json()).data || []).reduce((C, E) => C.find((R) => R._id === E._id) ? C : C.concat([E]), []);
1415
+ W(G);
1396
1416
  }
1397
1417
  } catch (l) {
1398
1418
  console.error("Failed to fetch annotations", l);
1399
1419
  } finally {
1400
- Q(!1);
1420
+ te(!1);
1401
1421
  }
1402
1422
  }
1403
- }, [n, a]);
1404
- X(() => {
1405
- A && O.length === 0 && !oe && G(!1);
1406
- }, [A, O.length, oe]), X(() => {
1407
- if (!d && O.length > 0) {
1408
- de();
1409
- const l = new MutationObserver(() => de()), f = new ResizeObserver(() => de()), g = () => de();
1423
+ }, [n, s]);
1424
+ Z(() => {
1425
+ A && _.length === 0 && !ce && F(!1);
1426
+ }, [A, _.length, ce]), Z(() => {
1427
+ if (!d && _.length > 0) {
1428
+ pe();
1429
+ const l = new MutationObserver(() => pe()), h = new ResizeObserver(() => pe()), g = () => pe();
1410
1430
  return l.observe(document.documentElement, {
1411
1431
  childList: !0,
1412
1432
  subtree: !0,
1413
1433
  attributes: !0
1414
- }), f.observe(document.documentElement), window.addEventListener("scroll", g, !0), () => {
1415
- l.disconnect(), f.disconnect(), window.removeEventListener("scroll", g, !0), le.current && cancelAnimationFrame(le.current);
1434
+ }), h.observe(document.documentElement), window.addEventListener("scroll", g, !0), () => {
1435
+ l.disconnect(), h.disconnect(), window.removeEventListener("scroll", g, !0), ue.current && cancelAnimationFrame(ue.current);
1416
1436
  };
1417
1437
  }
1418
- }, [d, O.length, de]), X(() => {
1419
- K();
1420
- }, [K]), X(() => {
1421
- re.current = document.getElementById("viewgate-shadow-host");
1438
+ }, [d, _.length, pe]), Z(() => {
1439
+ ee();
1440
+ }, [ee]), Z(() => {
1441
+ ae.current = document.getElementById("viewgate-shadow-host");
1422
1442
  }, []);
1423
- const _e = ve((l) => {
1443
+ const Pe = Ce((l) => {
1424
1444
  if (!d || m) return;
1425
- const f = ut(l.clientX, l.clientY);
1426
- if (!f || re.current?.contains(f) || f.closest(".vg-no-capture")) {
1427
- w(null);
1445
+ const h = pt(l.clientX, l.clientY);
1446
+ if (!h || ae.current?.contains(h) || h.closest(".vg-no-capture")) {
1447
+ v(null);
1428
1448
  return;
1429
1449
  }
1430
- const g = f.getBoundingClientRect();
1431
- w({
1432
- tag: f.tagName.toLowerCase(),
1433
- source: f.getAttribute("data-source-path") || "unknown:0",
1450
+ const g = h.getBoundingClientRect();
1451
+ v({
1452
+ tag: h.tagName.toLowerCase(),
1453
+ source: h.getAttribute("data-source-path") || "unknown:0",
1434
1454
  rect: g,
1435
- element: f,
1436
- previewText: (f.innerText || "").slice(0, 100) || (f.getAttribute("placeholder") || "").slice(0, 100) || f.tagName.toLowerCase(),
1455
+ element: h,
1456
+ previewText: (h.innerText || "").slice(0, 100) || (h.getAttribute("placeholder") || "").slice(0, 100) || h.tagName.toLowerCase(),
1437
1457
  semanticReference: {
1438
- ...xn(f),
1458
+ ...wn(h),
1439
1459
  normalizedOffset: {
1440
1460
  x: (l.clientX - g.left) / g.width,
1441
1461
  y: (l.clientY - g.top) / g.height
1442
1462
  }
1443
1463
  }
1444
1464
  });
1445
- }, [d, m]), Te = ve(async (l) => {
1465
+ }, [d, m]), Ae = Ce(async (l) => {
1446
1466
  if (!d || m) return;
1447
- const f = ut(l.clientX, l.clientY);
1448
- if (!(!f || re.current?.contains(f) || f.closest(".vg-no-capture")) && u) {
1467
+ const h = pt(l.clientX, l.clientY);
1468
+ if (!(!h || ae.current?.contains(h) || h.closest(".vg-no-capture")) && u) {
1449
1469
  l.preventDefault(), l.stopPropagation(), D(!0);
1450
1470
  try {
1451
- const _ = window.scrollX, k = window.scrollY, C = await ct(document.documentElement, {
1471
+ const C = window.scrollX, E = window.scrollY, S = await dt(document.documentElement, {
1452
1472
  pixelRatio: 1.5,
1453
1473
  cacheBust: !0,
1454
1474
  width: window.innerWidth,
1455
1475
  height: window.innerHeight,
1456
1476
  backgroundColor: "#ffffff",
1457
1477
  style: {
1458
- transform: `scale(${1 / window.devicePixelRatio}) translate(-${_}px, -${k}px)`,
1478
+ transform: `scale(${1 / window.devicePixelRatio}) translate(-${C}px, -${E}px)`,
1459
1479
  transformOrigin: "top left"
1460
1480
  },
1461
- filter: (Y) => {
1462
- const we = Y;
1463
- return !(re.current?.contains(we) || we.id === "viewgate-ui");
1481
+ filter: (X) => {
1482
+ const J = X;
1483
+ return !(ae.current?.contains(J) || J.id === "viewgate-ui");
1464
1484
  }
1465
- }), R = u.element.getBoundingClientRect(), N = R.top >= 0 && R.left >= 0 && R.bottom <= window.innerHeight && R.right <= window.innerWidth;
1466
- let q = "";
1467
- if (N && R.width > 0 && R.height > 0)
1468
- q = await lt(C, R, 24, 1.5);
1485
+ }), R = u.element.getBoundingClientRect(), Y = R.top >= 0 && R.left >= 0 && R.bottom <= window.innerHeight && R.right <= window.innerWidth;
1486
+ let M = "";
1487
+ if (Y && R.width > 0 && R.height > 0)
1488
+ M = await ut(S, R, 24, 1.5);
1469
1489
  else
1470
1490
  try {
1471
- q = await ct(u.element, {
1491
+ M = await dt(u.element, {
1472
1492
  pixelRatio: 2,
1473
1493
  cacheBust: !0,
1474
1494
  backgroundColor: "#ffffff",
1475
- filter: (Y) => {
1476
- const we = Y;
1477
- return !re.current?.contains(we);
1495
+ filter: (X) => {
1496
+ const J = X;
1497
+ return !ae.current?.contains(J);
1478
1498
  }
1479
1499
  });
1480
1500
  } catch {
1481
- q = await lt(C, R, 24, 1.5);
1501
+ M = await ut(S, R, 24, 1.5);
1482
1502
  }
1483
- const ue = {
1503
+ const me = {
1484
1504
  ...u.semanticReference,
1485
1505
  metadata: {
1486
1506
  ...u.semanticReference.metadata,
1487
- screenshotUrl: C,
1488
- elementScreenshot: q
1507
+ screenshotUrl: S,
1508
+ elementScreenshot: M
1489
1509
  }
1490
1510
  };
1491
1511
  x({
1492
1512
  ...u,
1493
- visualPreview: q,
1494
- semanticReference: ue
1513
+ visualPreview: M,
1514
+ semanticReference: me
1495
1515
  });
1496
1516
  } catch (g) {
1497
1517
  console.error("Failed to capture preview:", g), x(u);
1498
1518
  } finally {
1499
- D(!1), w(null);
1519
+ D(!1), v(null);
1500
1520
  }
1501
1521
  }
1502
1522
  }, [d, u, m]);
1503
- X(() => {
1504
- const l = (f) => {
1505
- if (f.key === "Escape") {
1506
- m ? x(null) : A ? G(!1) : d && p(!1);
1523
+ Z(() => {
1524
+ const l = (h) => {
1525
+ if (h.key === "Escape") {
1526
+ m ? x(null) : A ? F(!1) : d && p(!1);
1507
1527
  return;
1508
1528
  }
1509
- const M = (() => {
1510
- let C = document.activeElement;
1511
- for (; C && C.shadowRoot && C.shadowRoot.activeElement; )
1512
- C = C.shadowRoot.activeElement;
1513
- return C;
1529
+ const G = (() => {
1530
+ let S = document.activeElement;
1531
+ for (; S && S.shadowRoot && S.shadowRoot.activeElement; )
1532
+ S = S.shadowRoot.activeElement;
1533
+ return S;
1514
1534
  })();
1515
- if (["input", "textarea"].includes((M?.tagName || "").toLowerCase()) || M?.isContentEditable) return;
1516
- const k = f.key.toLowerCase();
1517
- k === "c" && !m && !A && p((C) => !C), k === "v" && !m && (O.length > 0 || A) && (G((C) => !C), A || p(!1));
1535
+ if (["input", "textarea"].includes((G?.tagName || "").toLowerCase()) || G?.isContentEditable) return;
1536
+ const E = h.key.toLowerCase();
1537
+ E === "c" && !m && !A && p((S) => !S), E === "v" && !m && (_.length > 0 || A) && (F((S) => !S), A || p(!1));
1518
1538
  };
1519
- return d && !m ? document.body.classList.add("vg-cursor-pointer") : document.body.classList.remove("vg-cursor-pointer"), window.addEventListener("keydown", l), window.addEventListener("mousemove", _e, !0), window.addEventListener("click", Te, !0), () => {
1520
- document.body.classList.remove("vg-cursor-pointer"), window.removeEventListener("keydown", l), window.removeEventListener("mousemove", _e, !0), window.removeEventListener("click", Te, !0);
1539
+ return d && !m ? document.body.classList.add("vg-cursor-pointer") : document.body.classList.remove("vg-cursor-pointer"), window.addEventListener("keydown", l), window.addEventListener("mousemove", Pe, !0), window.addEventListener("click", Ae, !0), () => {
1540
+ document.body.classList.remove("vg-cursor-pointer"), window.removeEventListener("keydown", l), window.removeEventListener("mousemove", Pe, !0), window.removeEventListener("click", Ae, !0);
1521
1541
  };
1522
- }, [d, m, A, O, _e, Te]);
1523
- const Ot = async () => {
1524
- if (!m || !y.trim()) return;
1542
+ }, [d, m, A, _, Pe, Ae]);
1543
+ const _t = async () => {
1544
+ if (!m || !f.trim()) return;
1525
1545
  P(!0);
1526
- const { semanticReference: l } = m, [f, g] = (l.source || "").split(":"), M = g || "0";
1546
+ const { semanticReference: l } = m, [h, g] = (l.source || "").split(":"), G = g || "0";
1527
1547
  try {
1528
- if (!(await fetch(`${a}/api/annotations`, {
1548
+ if (!(await fetch(`${s}/api/annotations`, {
1529
1549
  method: "POST",
1530
1550
  headers: {
1531
1551
  "Content-Type": "application/json",
1532
1552
  "x-api-key": n
1533
1553
  },
1534
1554
  body: JSON.stringify({
1535
- filePath: f,
1536
- line: parseInt(M),
1555
+ filePath: h,
1556
+ line: parseInt(G),
1537
1557
  url: window.location.href,
1538
- message: y,
1558
+ message: f,
1539
1559
  componentName: l.componentPath || m.tag,
1540
1560
  reference: {
1541
1561
  ...l,
@@ -1548,22 +1568,22 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1548
1568
  }
1549
1569
  })
1550
1570
  })).ok) throw new Error("Backend failed");
1551
- e(r.success, "success"), x(null), b(""), p(!1), K();
1552
- } catch (_) {
1553
- console.error(_), e(r.error, "error");
1571
+ e(r.success, "success"), x(null), w(""), p(!1), ee();
1572
+ } catch (C) {
1573
+ console.error(C), e(r.error, "error");
1554
1574
  } finally {
1555
1575
  P(!1);
1556
1576
  }
1557
1577
  };
1558
- return /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:987", className: "vg-container", children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:988", className: "vg-no-capture", children: [
1578
+ return /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1051", className: "vg-container", children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1052", className: "vg-no-capture", children: [
1559
1579
  !i && /* @__PURE__ */ o.jsxs(
1560
1580
  "div",
1561
1581
  {
1562
1582
  style: {
1563
1583
  position: "fixed",
1564
- top: `${B.top}px`,
1565
- right: `${B.right}px`,
1566
- zIndex: Ge + 10,
1584
+ top: `${U.top}px`,
1585
+ right: `${U.right}px`,
1586
+ zIndex: Ne + 10,
1567
1587
  display: "flex",
1568
1588
  alignItems: "center",
1569
1589
  gap: "8px",
@@ -1573,7 +1593,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1573
1593
  /* @__PURE__ */ o.jsx(
1574
1594
  "div",
1575
1595
  {
1576
- onMouseDown: ce,
1596
+ onMouseDown: de,
1577
1597
  style: {
1578
1598
  width: "20px",
1579
1599
  height: "32px",
@@ -1597,7 +1617,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1597
1617
  onMouseLeave: (l) => {
1598
1618
  l.currentTarget.style.backgroundColor = "rgba(255, 255, 255, 0.85)", l.currentTarget.style.color = "#1e293b";
1599
1619
  },
1600
- children: /* @__PURE__ */ o.jsx(Qe, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1032", size: 14 })
1620
+ children: /* @__PURE__ */ o.jsx(tt, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1096", size: 14 })
1601
1621
  }
1602
1622
  ),
1603
1623
  /* @__PURE__ */ o.jsx(
@@ -1608,7 +1628,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1608
1628
  title: r.exitConfirmTitle || "Close ViewGate?",
1609
1629
  message: r.exitConfirmMessage || "Are you sure you want to close ViewGate?",
1610
1630
  type: "danger",
1611
- onConfirm: () => s()
1631
+ onConfirm: () => a()
1612
1632
  });
1613
1633
  },
1614
1634
  title: "Cerrar ViewGate",
@@ -1633,7 +1653,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1633
1653
  onMouseLeave: (l) => {
1634
1654
  l.currentTarget.style.transform = "scale(1) rotate(0deg)", l.currentTarget.style.color = "#64748b", l.currentTarget.style.backgroundColor = "rgba(255, 255, 255, 0.9)";
1635
1655
  },
1636
- children: /* @__PURE__ */ o.jsx(Pe, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1072", size: 20, strokeWidth: 2.5 })
1656
+ children: /* @__PURE__ */ o.jsx(Ge, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1136", size: 20, strokeWidth: 2.5 })
1637
1657
  }
1638
1658
  )
1639
1659
  ]
@@ -1642,23 +1662,23 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1642
1662
  /* @__PURE__ */ o.jsxs(
1643
1663
  "div",
1644
1664
  {
1645
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1078",
1665
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1142",
1646
1666
  style: {
1647
1667
  position: "fixed",
1648
- bottom: `${E.bottom}px`,
1649
- right: `${E.right}px`,
1650
- zIndex: Ge,
1668
+ bottom: `${k.bottom}px`,
1669
+ right: `${k.right}px`,
1670
+ zIndex: Ne,
1651
1671
  display: "flex",
1652
1672
  alignItems: "center",
1653
1673
  gap: "8px",
1654
- transition: U ? "none" : "all 0.4s cubic-bezier(0.4, 0, 0.2, 1)"
1674
+ transition: q ? "none" : "all 0.4s cubic-bezier(0.4, 0, 0.2, 1)"
1655
1675
  },
1656
1676
  id: "viewgate-ui",
1657
1677
  children: [
1658
1678
  /* @__PURE__ */ o.jsx(
1659
1679
  "div",
1660
1680
  {
1661
- onMouseDown: je,
1681
+ onMouseDown: Te,
1662
1682
  style: {
1663
1683
  width: "24px",
1664
1684
  height: "40px",
@@ -1683,10 +1703,10 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1683
1703
  l.currentTarget.style.backgroundColor = "rgba(255, 255, 255, 0.85)", l.currentTarget.style.color = "#1e293b";
1684
1704
  },
1685
1705
  className: "vg-animate-slide-up",
1686
- children: /* @__PURE__ */ o.jsx(Qe, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1121", size: 16 })
1706
+ children: /* @__PURE__ */ o.jsx(tt, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1185", size: 16 })
1687
1707
  }
1688
1708
  ),
1689
- /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1124", className: "vg-action-bar vg-animate-slide-up", style: { transition: "all 0.4s cubic-bezier(0.4, 0, 0.2, 1)" }, children: [
1709
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1188", className: "vg-action-bar vg-animate-slide-up", style: { transition: "all 0.4s cubic-bezier(0.4, 0, 0.2, 1)" }, children: [
1690
1710
  /* @__PURE__ */ o.jsx(
1691
1711
  "button",
1692
1712
  {
@@ -1696,23 +1716,23 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1696
1716
  padding: "12px 24px",
1697
1717
  background: d ? "#ef4444" : void 0
1698
1718
  },
1699
- children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1133", style: { display: "flex", alignItems: "center", gap: "10px" }, children: [
1700
- d ? /* @__PURE__ */ o.jsx(Pe, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1134", size: 20, className: "vg-animate-pop" }) : /* @__PURE__ */ o.jsx(Ve, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1134", size: 20, className: "vg-animate-pop" }),
1701
- /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1135", children: d ? r.exitMode : r.enterMode })
1719
+ children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1197", style: { display: "flex", alignItems: "center", gap: "10px" }, children: [
1720
+ d ? /* @__PURE__ */ o.jsx(Ge, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1198", size: 20, className: "vg-animate-pop" }) : /* @__PURE__ */ o.jsx($e, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1198", size: 20, className: "vg-animate-pop" }),
1721
+ /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1199", children: d ? r.exitMode : r.enterMode })
1702
1722
  ] })
1703
1723
  }
1704
1724
  ),
1705
- O.length > 0 && /* @__PURE__ */ o.jsxs(
1725
+ _.length > 0 && /* @__PURE__ */ o.jsxs(
1706
1726
  "button",
1707
1727
  {
1708
1728
  onClick: () => {
1709
- G(!A), p(!1), x(null);
1729
+ F(!A), p(!1), x(null);
1710
1730
  },
1711
1731
  className: "vg-button-ghost vg-animate-pop",
1712
1732
  style: { animationDelay: "0.1s" },
1713
1733
  children: [
1714
- /* @__PURE__ */ o.jsx(Yt, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1148", size: 20 }),
1715
- /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1149", children: r.viewComments })
1734
+ /* @__PURE__ */ o.jsx(Xt, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1212", size: 20 }),
1735
+ /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1213", children: r.viewComments })
1716
1736
  ]
1717
1737
  }
1718
1738
  )
@@ -1720,7 +1740,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1720
1740
  ]
1721
1741
  }
1722
1742
  ),
1723
- z && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1157", style: {
1743
+ z && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1221", style: {
1724
1744
  position: "fixed",
1725
1745
  top: 0,
1726
1746
  left: 0,
@@ -1731,16 +1751,16 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1731
1751
  display: "flex",
1732
1752
  alignItems: "center",
1733
1753
  justifyContent: "center",
1734
- zIndex: Ge + 1,
1754
+ zIndex: Ne + 1,
1735
1755
  cursor: "wait"
1736
- }, children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1163", className: "vg-glassmorphism", style: { padding: "30px 50px", display: "flex", flexDirection: "column", alignItems: "center", gap: "16px" }, children: [
1737
- /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1164", className: "vg-spinner" }),
1738
- /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1165", style: { fontWeight: 600, fontSize: "14px", color: "#000000" }, children: "Capturando..." })
1756
+ }, children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1227", className: "vg-glassmorphism", style: { padding: "30px 50px", display: "flex", flexDirection: "column", alignItems: "center", gap: "16px" }, children: [
1757
+ /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1228", className: "vg-spinner" }),
1758
+ /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1229", style: { fontWeight: 600, fontSize: "14px", color: "#000000" }, children: "Capturando..." })
1739
1759
  ] }) }),
1740
1760
  d && !m && /* @__PURE__ */ o.jsx(
1741
1761
  "div",
1742
1762
  {
1743
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1172",
1763
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1236",
1744
1764
  className: "vg-backdrop-blur",
1745
1765
  style: {
1746
1766
  opacity: 1,
@@ -1759,29 +1779,29 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1759
1779
  d && u && !m && !z && /* @__PURE__ */ o.jsx(
1760
1780
  "div",
1761
1781
  {
1762
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1191",
1782
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1255",
1763
1783
  className: "vg-selection-pulse",
1764
1784
  style: {
1765
1785
  top: u.rect.top - 4,
1766
1786
  left: u.rect.left - 4,
1767
1787
  width: u.rect.width + 8,
1768
1788
  height: u.rect.height + 8,
1769
- zIndex: an
1789
+ zIndex: on
1770
1790
  },
1771
1791
  children: /* @__PURE__ */ o.jsxs(
1772
1792
  "div",
1773
1793
  {
1774
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1201",
1794
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1265",
1775
1795
  className: "vg-selection-label",
1776
1796
  style: {
1777
1797
  ...u.rect.top < 60 ? u.rect.bottom > window.innerHeight - 60 ? { top: "8px", bottom: "auto" } : { top: "100%", marginTop: "8px", bottom: "auto" } : { top: "-40px", bottom: "auto" },
1778
1798
  ...u.rect.left + 200 > window.innerWidth ? { left: "auto", right: "0" } : { left: "0", right: "auto" }
1779
1799
  },
1780
1800
  children: [
1781
- /* @__PURE__ */ o.jsx(er, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1217", size: 16 }),
1782
- /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1218", style: { display: "flex", flexDirection: "column" }, children: [
1783
- /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1219", style: { fontWeight: 700 }, children: r.selectToComment }),
1784
- /* @__PURE__ */ o.jsxs("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1220", style: { fontSize: "10px", opacity: 0.8, fontFamily: "monospace" }, children: [
1801
+ /* @__PURE__ */ o.jsx(tr, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1281", size: 16 }),
1802
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1282", style: { display: "flex", flexDirection: "column" }, children: [
1803
+ /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1283", style: { fontWeight: 700 }, children: r.selectToComment }),
1804
+ /* @__PURE__ */ o.jsxs("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1284", style: { fontSize: "10px", opacity: 0.8, fontFamily: "monospace" }, children: [
1785
1805
  Math.round(u.rect.width),
1786
1806
  " × ",
1787
1807
  Math.round(u.rect.height)
@@ -1792,7 +1812,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1792
1812
  )
1793
1813
  }
1794
1814
  ),
1795
- m && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1230", className: "vg-animate-fade", style: {
1815
+ m && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1294", className: "vg-animate-fade", style: {
1796
1816
  position: "fixed",
1797
1817
  top: 0,
1798
1818
  left: 0,
@@ -1803,14 +1823,14 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1803
1823
  display: "flex",
1804
1824
  alignItems: "center",
1805
1825
  justifyContent: "center",
1806
- zIndex: $e
1807
- }, children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1235", className: "vg-glassmorphism vg-animate-slide", style: {
1826
+ zIndex: Me
1827
+ }, children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1299", className: "vg-glassmorphism vg-animate-slide", style: {
1808
1828
  padding: "40px",
1809
1829
  width: "500px",
1810
1830
  boxShadow: "0 25px 50px -12px rgba(0, 0, 0, 0.25)"
1811
1831
  }, children: [
1812
- /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1239", style: { textAlign: "center", marginBottom: "32px" }, children: [
1813
- /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1240", style: {
1832
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1303", style: { textAlign: "center", marginBottom: "32px" }, children: [
1833
+ /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1304", style: {
1814
1834
  width: "48px",
1815
1835
  height: "48px",
1816
1836
  background: "var(--vg-primary-gradient)",
@@ -1821,11 +1841,11 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1821
1841
  margin: "0 auto 16px",
1822
1842
  color: "white",
1823
1843
  boxShadow: "0 8px 16px rgba(99, 102, 241, 0.3)"
1824
- }, children: /* @__PURE__ */ o.jsx(Ve, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1245", size: 24 }) }),
1825
- /* @__PURE__ */ o.jsx("h2", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1247", style: { margin: "0 0 8px 0", fontSize: "24px", fontWeight: 800, color: "#0f172a" }, children: r.feedbackHeader }),
1826
- /* @__PURE__ */ o.jsx("p", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1248", style: { margin: 0, color: "#000000", fontSize: "15px" }, children: r.feedbackSubheader })
1844
+ }, children: /* @__PURE__ */ o.jsx($e, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1309", size: 24 }) }),
1845
+ /* @__PURE__ */ o.jsx("h2", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1311", style: { margin: "0 0 8px 0", fontSize: "24px", fontWeight: 800, color: "#0f172a" }, children: r.feedbackHeader }),
1846
+ /* @__PURE__ */ o.jsx("p", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1312", style: { margin: 0, color: "#000000", fontSize: "15px" }, children: r.feedbackSubheader })
1827
1847
  ] }),
1828
- m.visualPreview && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1252", style: {
1848
+ m.visualPreview && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1316", style: {
1829
1849
  marginBottom: "24px",
1830
1850
  borderRadius: "12px",
1831
1851
  overflow: "hidden",
@@ -1845,15 +1865,15 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1845
1865
  "textarea",
1846
1866
  {
1847
1867
  className: "vg-textarea",
1848
- value: y,
1849
- onChange: (l) => b(l.target.value),
1868
+ value: f,
1869
+ onChange: (l) => w(l.target.value),
1850
1870
  rows: 4,
1851
1871
  placeholder: r.placeholder,
1852
1872
  autoFocus: !0,
1853
1873
  style: { fontSize: "15px", padding: "16px", marginBottom: "24px" }
1854
1874
  }
1855
1875
  ),
1856
- /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1279", style: { display: "flex", gap: "12px" }, children: [
1876
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1343", style: { display: "flex", gap: "12px" }, children: [
1857
1877
  /* @__PURE__ */ o.jsx(
1858
1878
  "button",
1859
1879
  {
@@ -1867,19 +1887,19 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1867
1887
  /* @__PURE__ */ o.jsx(
1868
1888
  "button",
1869
1889
  {
1870
- onClick: Ot,
1890
+ onClick: _t,
1871
1891
  className: "vg-button-primary",
1872
- disabled: T || !y.trim(),
1892
+ disabled: T || !f.trim(),
1873
1893
  style: { flex: 2 },
1874
- children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1294", style: { display: "flex", alignItems: "center", gap: "8px" }, children: [
1875
- T ? /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1295", className: "vg-spinner", style: { width: "16px", height: "16px", borderWidth: "2px" } }) : /* @__PURE__ */ o.jsx(or, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1295", size: 18 }),
1876
- /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1296", children: T ? r.submitting : r.sendFeedback || "Send Comment" })
1894
+ children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1358", style: { display: "flex", alignItems: "center", gap: "8px" }, children: [
1895
+ T ? /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1359", className: "vg-spinner", style: { width: "16px", height: "16px", borderWidth: "2px" } }) : /* @__PURE__ */ o.jsx(ir, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1359", size: 18 }),
1896
+ /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1360", children: T ? r.submitting : r.sendFeedback || "Send Comment" })
1877
1897
  ] })
1878
1898
  }
1879
1899
  )
1880
1900
  ] })
1881
1901
  ] }) }),
1882
- A && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1306", className: "vg-animate-fade", style: {
1902
+ A && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1370", className: "vg-animate-fade", style: {
1883
1903
  position: "fixed",
1884
1904
  top: 0,
1885
1905
  left: 0,
@@ -1890,94 +1910,94 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1890
1910
  display: "flex",
1891
1911
  alignItems: "center",
1892
1912
  justifyContent: "center",
1893
- zIndex: $e
1894
- }, children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1311", className: "vg-glassmorphism vg-animate-slide", style: {
1913
+ zIndex: Me
1914
+ }, children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1375", className: "vg-glassmorphism vg-animate-slide", style: {
1895
1915
  padding: "32px",
1896
1916
  width: "650px",
1897
1917
  maxHeight: "85vh",
1898
1918
  display: "flex",
1899
1919
  flexDirection: "column"
1900
1920
  }, children: [
1901
- /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1315", style: { display: "flex", alignItems: "center", justifyContent: "space-between", marginBottom: "20px" }, children: [
1902
- /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1316", style: { display: "flex", alignItems: "center", gap: "12px" }, children: [
1903
- /* @__PURE__ */ o.jsx("h2", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1317", style: { margin: 0, fontSize: "20px", fontWeight: 800, color: "#0f172a" }, children: W ? r.commentDetails : r.annotations }),
1904
- !W && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1321", className: "vg-badge", style: { background: "#e0e7ff", color: "#6366f1" }, children: O.length })
1921
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1379", style: { display: "flex", alignItems: "center", justifyContent: "space-between", marginBottom: "20px" }, children: [
1922
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1380", style: { display: "flex", alignItems: "center", gap: "12px" }, children: [
1923
+ /* @__PURE__ */ o.jsx("h2", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1381", style: { margin: 0, fontSize: "20px", fontWeight: 800, color: "#0f172a" }, children: B ? r.commentDetails : r.annotations }),
1924
+ !B && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1385", className: "vg-badge", style: { background: "#e0e7ff", color: "#6366f1" }, children: _.length })
1905
1925
  ] }),
1906
- /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1326", style: { display: "flex", gap: "8px" }, children: [
1907
- W && /* @__PURE__ */ o.jsx(
1926
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1390", style: { display: "flex", gap: "8px" }, children: [
1927
+ B && /* @__PURE__ */ o.jsx(
1908
1928
  "button",
1909
1929
  {
1910
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1328",
1930
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1392",
1911
1931
  className: "vg-button-ghost",
1912
1932
  style: { padding: "6px 14px", fontSize: "12px" },
1913
- onClick: () => ee(null),
1933
+ onClick: () => re(null),
1914
1934
  children: r.viewAll || "View All"
1915
1935
  }
1916
1936
  ),
1917
1937
  /* @__PURE__ */ o.jsx(
1918
1938
  "button",
1919
1939
  {
1920
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1336",
1940
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1400",
1921
1941
  className: "vg-button-ghost",
1922
1942
  style: { padding: "8px", borderRadius: "50%" },
1923
1943
  onClick: () => {
1924
- G(!1), ee(null);
1944
+ F(!1), re(null);
1925
1945
  },
1926
- children: /* @__PURE__ */ o.jsx(Pe, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1341", size: 20 })
1946
+ children: /* @__PURE__ */ o.jsx(Ge, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1405", size: 20 })
1927
1947
  }
1928
1948
  )
1929
1949
  ] })
1930
1950
  ] }),
1931
- /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1346", style: { maxHeight: "60vh", overflowY: "auto", paddingRight: "10px" }, className: "vg-custom-scrollbar", children: oe ? /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1348", style: { display: "flex", justifyContent: "center", padding: "40px" }, children: /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1349", className: "vg-spinner" }) }) : (W ? O.filter((l) => l._id === W) : O).map((l, f) => /* @__PURE__ */ o.jsxs(
1951
+ /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1410", style: { maxHeight: "60vh", overflowY: "auto", paddingRight: "10px" }, className: "vg-custom-scrollbar", children: ce ? /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1412", style: { display: "flex", justifyContent: "center", padding: "40px" }, children: /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1413", className: "vg-spinner" }) }) : (B ? _.filter((l) => l._id === B) : _).map((l, h) => /* @__PURE__ */ o.jsxs(
1932
1952
  "div",
1933
1953
  {
1934
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1353",
1954
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1417",
1935
1955
  className: "vg-glassmorphism vg-animate-slide",
1936
1956
  style: {
1937
1957
  padding: "20px",
1938
1958
  marginBottom: "16px",
1939
1959
  border: "1px solid rgba(0,0,0,0.05)",
1940
1960
  background: "rgba(255,255,255,0.5)",
1941
- animationDelay: `${f * 0.05}s`
1961
+ animationDelay: `${h * 0.05}s`
1942
1962
  },
1943
1963
  children: [
1944
- /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1364", style: { display: "flex", justifyContent: "space-between", marginBottom: "16px", alignItems: "center" }, children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1365", style: { display: "flex", gap: "12px", alignItems: "center" }, children: [
1945
- l.status === "ready_for_review" ? /* @__PURE__ */ o.jsxs("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1367", className: "vg-badge", style: { backgroundColor: "#f0fdf4", color: "#16a34a" }, children: [
1946
- /* @__PURE__ */ o.jsx(ae, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1368", size: 14 }),
1964
+ /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1428", style: { display: "flex", justifyContent: "space-between", marginBottom: "16px", alignItems: "center" }, children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1429", style: { display: "flex", gap: "12px", alignItems: "center" }, children: [
1965
+ l.status === "ready_for_review" ? /* @__PURE__ */ o.jsxs("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1431", className: "vg-badge", style: { backgroundColor: "#f0fdf4", color: "#16a34a" }, children: [
1966
+ /* @__PURE__ */ o.jsx(ie, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1432", size: 14 }),
1947
1967
  " ",
1948
1968
  r.readyForReview
1949
- ] }) : /* @__PURE__ */ o.jsxs("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1371", className: "vg-badge", style: { backgroundColor: "#fff7ed", color: "#ea580c" }, children: [
1950
- /* @__PURE__ */ o.jsx(Ze, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1372", size: 14 }),
1969
+ ] }) : /* @__PURE__ */ o.jsxs("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1435", className: "vg-badge", style: { backgroundColor: "#fff7ed", color: "#ea580c" }, children: [
1970
+ /* @__PURE__ */ o.jsx(Qe, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1436", size: 14 }),
1951
1971
  " ",
1952
1972
  r.pending
1953
1973
  ] }),
1954
- /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1375", style: { fontSize: "12px", color: "#000000" }, children: dn(l.timestamp || l.createdAt || l.reference?.timestamp, t) })
1974
+ /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1439", style: { fontSize: "12px", color: "#000000" }, children: un(l.timestamp || l.createdAt || l.reference?.timestamp, t) })
1955
1975
  ] }) }),
1956
- We === l._id ? /* @__PURE__ */ o.jsx(
1976
+ Ue === l._id ? /* @__PURE__ */ o.jsx(
1957
1977
  "textarea",
1958
1978
  {
1959
1979
  className: "vg-textarea",
1960
- value: Be,
1961
- onChange: (g) => Ue(g.target.value),
1980
+ value: qe,
1981
+ onChange: (g) => Ye(g.target.value),
1962
1982
  rows: 3,
1963
1983
  autoFocus: !0,
1964
1984
  style: { marginBottom: "16px" }
1965
1985
  }
1966
- ) : /* @__PURE__ */ o.jsx("p", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1391", style: { margin: "0 0 20px 0", fontSize: "16px", color: "#1e293b", lineHeight: 1.6 }, children: l.message }),
1967
- /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1394", style: { display: "flex", gap: "12px", justifyContent: "flex-end", borderTop: "1px solid #f1f5f9", paddingTop: "16px" }, children: We === l._id ? /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
1986
+ ) : /* @__PURE__ */ o.jsx("p", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1455", style: { margin: "0 0 20px 0", fontSize: "16px", color: "#1e293b", lineHeight: 1.6 }, children: l.message }),
1987
+ /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1458", style: { display: "flex", gap: "12px", justifyContent: "flex-end", borderTop: "1px solid #f1f5f9", paddingTop: "16px" }, children: Ue === l._id ? /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
1968
1988
  /* @__PURE__ */ o.jsx(
1969
1989
  "button",
1970
1990
  {
1971
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1397",
1991
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1461",
1972
1992
  className: "vg-button-primary vg-animate-pop",
1973
1993
  style: { padding: "8px 16px", fontSize: "13px" },
1974
1994
  onClick: async () => {
1975
1995
  try {
1976
- (await fetch(`${a}/api/annotations/${l._id}`, {
1996
+ (await fetch(`${s}/api/annotations/${l._id}`, {
1977
1997
  method: "PATCH",
1978
1998
  headers: { "Content-Type": "application/json", "x-api-key": n },
1979
- body: JSON.stringify({ message: Be })
1980
- })).ok && (Oe(null), K(), e(r.updateSuccess, "success"));
1999
+ body: JSON.stringify({ message: qe })
2000
+ })).ok && (Ve(null), ee(), e(r.updateSuccess, "success"));
1981
2001
  } catch {
1982
2002
  e(r.error, "error");
1983
2003
  }
@@ -1985,19 +2005,19 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1985
2005
  children: r.save
1986
2006
  }
1987
2007
  ),
1988
- /* @__PURE__ */ o.jsx("button", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1419", className: "vg-button-ghost vg-animate-pop", style: { padding: "8px 16px", fontSize: "13px" }, onClick: () => Oe(null), children: r.cancel })
2008
+ /* @__PURE__ */ o.jsx("button", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1483", className: "vg-button-ghost vg-animate-pop", style: { padding: "8px 16px", fontSize: "13px" }, onClick: () => Ve(null), children: r.cancel })
1989
2009
  ] }) : /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
1990
2010
  /* @__PURE__ */ o.jsxs(
1991
2011
  "button",
1992
2012
  {
1993
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1423",
2013
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1487",
1994
2014
  className: "vg-button-ghost vg-animate-pop",
1995
2015
  style: { padding: "8px 16px", fontSize: "13px" },
1996
2016
  onClick: () => {
1997
- Oe(l._id), Ue(l.message);
2017
+ Ve(l._id), Ye(l.message);
1998
2018
  },
1999
2019
  children: [
2000
- /* @__PURE__ */ o.jsx(rr, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1431", size: 14 }),
2020
+ /* @__PURE__ */ o.jsx(nr, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1495", size: 14 }),
2001
2021
  " ",
2002
2022
  r.edit
2003
2023
  ]
@@ -2006,14 +2026,14 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2006
2026
  /* @__PURE__ */ o.jsxs(
2007
2027
  "button",
2008
2028
  {
2009
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1433",
2029
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1497",
2010
2030
  className: "vg-button-ghost vg-animate-pop",
2011
2031
  style: { padding: "8px 16px", fontSize: "13px", animationDelay: "0.05s" },
2012
2032
  onClick: () => {
2013
2033
  l.url && (window.location.href = l.url);
2014
2034
  },
2015
2035
  children: [
2016
- /* @__PURE__ */ o.jsx(Ke, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1440", size: 14 }),
2036
+ /* @__PURE__ */ o.jsx(et, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1504", size: 14 }),
2017
2037
  " ",
2018
2038
  r.review
2019
2039
  ]
@@ -2022,7 +2042,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2022
2042
  l.status === "pending" ? /* @__PURE__ */ o.jsxs(
2023
2043
  "button",
2024
2044
  {
2025
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1443",
2045
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1507",
2026
2046
  className: "vg-button-primary vg-animate-pop",
2027
2047
  style: { padding: "8px 16px", fontSize: "13px", animationDelay: "0.1s" },
2028
2048
  onClick: () => {
@@ -2032,11 +2052,11 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2032
2052
  type: "success",
2033
2053
  onConfirm: async () => {
2034
2054
  try {
2035
- (await fetch(`${a}/api/annotations/${l._id}`, {
2055
+ (await fetch(`${s}/api/annotations/${l._id}`, {
2036
2056
  method: "PATCH",
2037
2057
  headers: { "Content-Type": "application/json", "x-api-key": n },
2038
2058
  body: JSON.stringify({ status: "ready_for_review" })
2039
- })).ok && (K(), e(r.updateSuccess, "success"));
2059
+ })).ok && (ee(), e(r.updateSuccess, "success"));
2040
2060
  } catch {
2041
2061
  e(r.error, "error");
2042
2062
  } finally {
@@ -2046,7 +2066,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2046
2066
  });
2047
2067
  },
2048
2068
  children: [
2049
- /* @__PURE__ */ o.jsx(ae, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1471", size: 14 }),
2069
+ /* @__PURE__ */ o.jsx(ie, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1535", size: 14 }),
2050
2070
  " ",
2051
2071
  r.markReady
2052
2072
  ]
@@ -2054,7 +2074,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2054
2074
  ) : /* @__PURE__ */ o.jsxs(
2055
2075
  "button",
2056
2076
  {
2057
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1474",
2077
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1538",
2058
2078
  className: "vg-button-ghost vg-animate-pop",
2059
2079
  style: { padding: "8px 16px", fontSize: "13px", animationDelay: "0.1s" },
2060
2080
  onClick: () => {
@@ -2065,11 +2085,11 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2065
2085
  // Reopening is a positive action, use success theme (indigo/check) or we could add a neutral theme
2066
2086
  onConfirm: async () => {
2067
2087
  try {
2068
- (await fetch(`${a}/api/annotations/${l._id}`, {
2088
+ (await fetch(`${s}/api/annotations/${l._id}`, {
2069
2089
  method: "PATCH",
2070
2090
  headers: { "Content-Type": "application/json", "x-api-key": n },
2071
2091
  body: JSON.stringify({ status: "pending" })
2072
- })).ok && (K(), e(r.updateSuccess, "success"));
2092
+ })).ok && (ee(), e(r.updateSuccess, "success"));
2073
2093
  } catch {
2074
2094
  e(r.error, "error");
2075
2095
  } finally {
@@ -2079,7 +2099,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2079
2099
  });
2080
2100
  },
2081
2101
  children: [
2082
- /* @__PURE__ */ o.jsx(sr, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1502", size: 14 }),
2102
+ /* @__PURE__ */ o.jsx(sr, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1566", size: 14 }),
2083
2103
  " ",
2084
2104
  r.reopen
2085
2105
  ]
@@ -2088,7 +2108,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2088
2108
  /* @__PURE__ */ o.jsx(
2089
2109
  "button",
2090
2110
  {
2091
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1505",
2111
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1569",
2092
2112
  className: "vg-button-ghost vg-animate-pop",
2093
2113
  style: { padding: "8px 12px", color: "#ef4444", borderColor: "#fee2e2", animationDelay: "0.15s" },
2094
2114
  onClick: () => {
@@ -2098,10 +2118,10 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2098
2118
  type: "danger",
2099
2119
  onConfirm: async () => {
2100
2120
  try {
2101
- (await fetch(`${a}/api/annotations/${l._id}`, {
2121
+ (await fetch(`${s}/api/annotations/${l._id}`, {
2102
2122
  method: "DELETE",
2103
2123
  headers: { "x-api-key": n }
2104
- })).ok && (K(), e(r.deleteSuccess, "success"));
2124
+ })).ok && (ee(), e(r.deleteSuccess, "success"));
2105
2125
  } catch {
2106
2126
  e(r.error, "error");
2107
2127
  } finally {
@@ -2110,7 +2130,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2110
2130
  }
2111
2131
  });
2112
2132
  },
2113
- children: /* @__PURE__ */ o.jsx(et, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1532", size: 16 })
2133
+ children: /* @__PURE__ */ o.jsx(rt, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1596", size: 16 })
2114
2134
  }
2115
2135
  )
2116
2136
  ] }) })
@@ -2119,7 +2139,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2119
2139
  l._id
2120
2140
  )) })
2121
2141
  ] }) }),
2122
- F && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1547", className: "vg-animate-fade", style: {
2142
+ $ && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1611", className: "vg-animate-fade", style: {
2123
2143
  position: "fixed",
2124
2144
  top: 0,
2125
2145
  left: 0,
@@ -2130,76 +2150,76 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2130
2150
  display: "flex",
2131
2151
  alignItems: "center",
2132
2152
  justifyContent: "center",
2133
- zIndex: $e + 100
2134
- }, children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1552", className: "vg-glassmorphism vg-animate-slide", style: {
2153
+ zIndex: Me + 100
2154
+ }, children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1616", className: "vg-glassmorphism vg-animate-slide", style: {
2135
2155
  padding: "40px",
2136
2156
  width: "420px",
2137
2157
  textAlign: "center",
2138
2158
  border: "1px solid rgba(255, 255, 255, 0.1)",
2139
2159
  boxShadow: "0 25px 50px -12px rgba(0, 0, 0, 0.5)"
2140
2160
  }, children: [
2141
- /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1559", style: {
2161
+ /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1623", style: {
2142
2162
  width: "64px",
2143
2163
  height: "64px",
2144
- background: F.type === "danger" ? "rgba(239, 68, 68, 0.1)" : "rgba(99, 102, 241, 0.1)",
2164
+ background: $.type === "danger" ? "rgba(239, 68, 68, 0.1)" : "rgba(99, 102, 241, 0.1)",
2145
2165
  borderRadius: "20px",
2146
2166
  display: "flex",
2147
2167
  alignItems: "center",
2148
2168
  justifyContent: "center",
2149
2169
  margin: "0 auto 24px",
2150
- color: F.type === "danger" ? "#ef4444" : "#6366f1",
2170
+ color: $.type === "danger" ? "#ef4444" : "#6366f1",
2151
2171
  transform: "rotate(-5deg)"
2152
- }, children: F.type === "danger" ? /* @__PURE__ */ o.jsx(et, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1568", size: 32 }) : /* @__PURE__ */ o.jsx(ae, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1568", size: 32 }) }),
2153
- /* @__PURE__ */ o.jsx("h3", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1570", style: { margin: "0 0 12px 0", fontSize: "20px", fontWeight: 800, color: "#000000", letterSpacing: "-0.02em" }, children: F.title }),
2154
- /* @__PURE__ */ o.jsx("p", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1571", style: { margin: "0 0 32px 0", fontSize: "15px", color: "#000000", lineHeight: 1.6 }, children: F.message }),
2155
- /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1572", style: { display: "flex", gap: "16px" }, children: [
2172
+ }, children: $.type === "danger" ? /* @__PURE__ */ o.jsx(rt, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1632", size: 32 }) : /* @__PURE__ */ o.jsx(ie, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1632", size: 32 }) }),
2173
+ /* @__PURE__ */ o.jsx("h3", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1634", style: { margin: "0 0 12px 0", fontSize: "20px", fontWeight: 800, color: "#000000", letterSpacing: "-0.02em" }, children: $.title }),
2174
+ /* @__PURE__ */ o.jsx("p", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1635", style: { margin: "0 0 32px 0", fontSize: "15px", color: "#000000", lineHeight: 1.6 }, children: $.message }),
2175
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1636", style: { display: "flex", gap: "16px" }, children: [
2156
2176
  /* @__PURE__ */ o.jsx(
2157
2177
  "button",
2158
2178
  {
2159
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1573",
2179
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1637",
2160
2180
  className: "vg-button-ghost",
2161
2181
  style: { flex: 1, height: "44px" },
2162
- onClick: () => !Z && H(null),
2163
- disabled: Z,
2182
+ onClick: () => !Q && H(null),
2183
+ disabled: Q,
2164
2184
  children: r.no
2165
2185
  }
2166
2186
  ),
2167
2187
  /* @__PURE__ */ o.jsx(
2168
2188
  "button",
2169
2189
  {
2170
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1581",
2190
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1645",
2171
2191
  className: "vg-button-primary",
2172
2192
  style: {
2173
2193
  flex: 1,
2174
2194
  height: "44px",
2175
- backgroundColor: F.type === "danger" ? "#ef4444" : void 0,
2176
- backgroundImage: F.type === "danger" ? "none" : void 0,
2195
+ backgroundColor: $.type === "danger" ? "#ef4444" : void 0,
2196
+ backgroundImage: $.type === "danger" ? "none" : void 0,
2177
2197
  display: "flex",
2178
2198
  alignItems: "center",
2179
2199
  justifyContent: "center",
2180
2200
  gap: "8px"
2181
2201
  },
2182
- disabled: Z,
2202
+ disabled: Q,
2183
2203
  onClick: async () => {
2184
- ie(!0);
2204
+ le(!0);
2185
2205
  try {
2186
- await F.onConfirm();
2206
+ await $.onConfirm();
2187
2207
  } catch (l) {
2188
2208
  console.error("Confirmation error:", l);
2189
2209
  } finally {
2190
- ie(!1);
2210
+ le(!1);
2191
2211
  }
2192
2212
  },
2193
- children: Z ? /* @__PURE__ */ o.jsx(Zt, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1606", size: 18, className: "vg-animate-spin" }) : r.yes
2213
+ children: Q ? /* @__PURE__ */ o.jsx(Kt, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1670", size: 18, className: "vg-animate-spin" }) : r.yes
2194
2214
  }
2195
2215
  )
2196
2216
  ] })
2197
2217
  ] }) }),
2198
- !d && !A && O.map((l, f) => {
2199
- const g = Rt[l._id];
2218
+ !d && !A && _.map((l, h) => {
2219
+ const g = jt[l._id];
2200
2220
  if (!g) return null;
2201
- const _ = O.slice(0, f).filter(
2202
- (k) => k.reference?.selector && k.reference.selector === l.reference?.selector
2221
+ const C = _.slice(0, h).filter(
2222
+ (E) => E.reference?.selector && E.reference.selector === l.reference?.selector
2203
2223
  ).length * 34;
2204
2224
  return /* @__PURE__ */ o.jsxs(
2205
2225
  "div",
@@ -2208,37 +2228,37 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2208
2228
  style: {
2209
2229
  position: "fixed",
2210
2230
  top: g.top - 20 - window.scrollY,
2211
- left: g.left + g.width / 2 - 16 + _ - window.scrollX,
2231
+ left: g.left + g.width / 2 - 16 + C - window.scrollX,
2212
2232
  cursor: "pointer",
2213
- animationDelay: `${f * 0.08}s`,
2233
+ animationDelay: `${h * 0.08}s`,
2214
2234
  transition: "all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275)",
2215
- zIndex: on - f
2235
+ zIndex: cn - h
2216
2236
  // Ensure staggered pins don't overlap tooltips weirdly
2217
2237
  },
2218
- onMouseEnter: (k) => {
2219
- const C = k.currentTarget.getBoundingClientRect();
2220
- window.innerHeight - C.bottom < 180 ? ye((N) => ({ ...N, [l._id]: "vg-top" })) : ye((N) => ({ ...N, [l._id]: "" }));
2238
+ onMouseEnter: (E) => {
2239
+ const S = E.currentTarget.getBoundingClientRect();
2240
+ window.innerHeight - S.bottom < 180 ? ve((Y) => ({ ...Y, [l._id]: "vg-top" })) : ve((Y) => ({ ...Y, [l._id]: "" }));
2221
2241
  },
2222
2242
  onClick: () => {
2223
- G(!0), ee(l._id);
2243
+ F(!0), re(l._id);
2224
2244
  },
2225
2245
  children: [
2226
- /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1653", className: `vg-pin-tooltip ${ge[l._id] || ""}`, children: [
2227
- /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1654", style: { display: "flex", alignItems: "center", gap: "8px", marginBottom: "8px" }, children: [
2228
- l.status === "ready_for_review" ? /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1656", style: { display: "flex", alignItems: "center", gap: "6px", color: "#16a34a", fontWeight: 700, fontSize: "11px" }, children: [
2229
- /* @__PURE__ */ o.jsx(ae, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1657", size: 12 }),
2246
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1717", className: `vg-pin-tooltip ${we[l._id] || ""}`, children: [
2247
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1718", style: { display: "flex", alignItems: "center", gap: "8px", marginBottom: "8px" }, children: [
2248
+ l.status === "ready_for_review" ? /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1720", style: { display: "flex", alignItems: "center", gap: "6px", color: "#16a34a", fontWeight: 700, fontSize: "11px" }, children: [
2249
+ /* @__PURE__ */ o.jsx(ie, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1721", size: 12 }),
2230
2250
  " ",
2231
2251
  r.readyForReview
2232
- ] }) : /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1660", style: { display: "flex", alignItems: "center", gap: "6px", color: g.isModal ? "#f59e0b" : "#ea580c", fontWeight: 700, fontSize: "11px" }, children: [
2233
- /* @__PURE__ */ o.jsx(Ze, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1661", size: 12 }),
2252
+ ] }) : /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1724", style: { display: "flex", alignItems: "center", gap: "6px", color: g.isModal ? "#f59e0b" : "#ea580c", fontWeight: 700, fontSize: "11px" }, children: [
2253
+ /* @__PURE__ */ o.jsx(Qe, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1725", size: 12 }),
2234
2254
  " ",
2235
2255
  r.pending
2236
2256
  ] }),
2237
- g.isModal && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1665", style: { display: "flex", alignItems: "center", gap: "6px", color: "#f59e0b", fontWeight: 700, fontSize: "11px", marginLeft: "auto" }, children: /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1666", children: "MODAL" }) })
2257
+ g.isModal && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1729", style: { display: "flex", alignItems: "center", gap: "6px", color: "#f59e0b", fontWeight: 700, fontSize: "11px", marginLeft: "auto" }, children: /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1730", children: "MODAL" }) })
2238
2258
  ] }),
2239
- /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1670", style: { fontWeight: 500, color: "#1e293b", lineHeight: 1.4 }, children: l.message })
2259
+ /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1734", style: { fontWeight: 500, color: "#1e293b", lineHeight: 1.4 }, children: l.message })
2240
2260
  ] }),
2241
- /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1673", className: `vg-formal-pin ${l.status === "ready_for_review" ? "ready" : ""} ${g.isModal ? "modal-variant" : ""}`, children: l.status === "ready_for_review" ? /* @__PURE__ */ o.jsx(ae, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1674", size: 18 }) : g.isModal ? /* @__PURE__ */ o.jsx(Ke, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1674", size: 16 }) : /* @__PURE__ */ o.jsx(Ve, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1674", size: 16 }) })
2261
+ /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1737", className: `vg-formal-pin ${l.status === "ready_for_review" ? "ready" : ""} ${g.isModal ? "modal-variant" : ""}`, children: l.status === "ready_for_review" ? /* @__PURE__ */ o.jsx(ie, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1738", size: 18 }) : g.isModal ? /* @__PURE__ */ o.jsx(et, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1738", size: 16 }) : /* @__PURE__ */ o.jsx($e, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1738", size: 16 }) })
2242
2262
  ]
2243
2263
  },
2244
2264
  `pin-${l._id}`
@@ -2246,37 +2266,37 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2246
2266
  })
2247
2267
  ] }) });
2248
2268
  };
2249
- function kt(e, t, r) {
2269
+ function Rt(e, t, r) {
2250
2270
  if (!t.endsWith(".tsx") && !t.endsWith(".jsx") || t.includes("node_modules")) return e;
2251
- const n = (d) => d.replace(/\\/g, "/"), a = n(t).replace(n(r), "");
2271
+ const n = (d) => d.replace(/\\/g, "/"), s = n(t).replace(n(r), "");
2252
2272
  return e.split(`
2253
2273
  `).map((d, p) => {
2254
2274
  const u = p + 1;
2255
- return d.replace(/(^|[^a-zA-Z0-9])<([a-zA-Z][a-zA-Z0-9\.]*)(?=[ \t\n\/\>])/g, (w, m, x) => w.includes("data-source-path") || x === "Fragment" || x === "React.Fragment" ? w : `${m}<${x} data-source-path="${a}:${u}"`);
2275
+ return d.replace(/(^|[^a-zA-Z0-9])<([a-zA-Z][a-zA-Z0-9\.]*)(?=[ \t\n\/\>])/g, (v, m, x) => v.includes("data-source-path") || x === "Fragment" || x === "React.Fragment" ? v : `${m}<${x} data-source-path="${s}:${u}"`);
2256
2276
  }).join(`
2257
2277
  `);
2258
2278
  }
2259
- function En() {
2279
+ function Sn() {
2260
2280
  return {
2261
2281
  name: "vite-plugin-viewgate",
2262
2282
  enforce: "pre",
2263
2283
  transform(e, t) {
2264
2284
  return {
2265
- code: kt(e, t, process.cwd()),
2285
+ code: Rt(e, t, process.cwd()),
2266
2286
  map: null
2267
2287
  };
2268
2288
  }
2269
2289
  };
2270
2290
  }
2271
- function Sn(e) {
2291
+ function kn(e) {
2272
2292
  const t = this.resourcePath;
2273
- return t ? (process.env.NODE_ENV, kt(e, t, process.cwd())) : e;
2293
+ return t ? (process.env.NODE_ENV, Rt(e, t, process.cwd())) : e;
2274
2294
  }
2275
2295
  export {
2276
- Cn as ViewGate,
2277
- wn as ViewGateOverlay,
2278
- kt as transformSourcePaths,
2279
- dr as useViewGate,
2280
- Sn as viewgateNextLoader,
2281
- En as viewgatePlugin
2296
+ En as ViewGate,
2297
+ vn as ViewGateOverlay,
2298
+ Rt as transformSourcePaths,
2299
+ ur as useViewGate,
2300
+ kn as viewgateNextLoader,
2301
+ Sn as viewgatePlugin
2282
2302
  };