viewgate-wrapper 1.10.10 → 1.10.11

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,11 +1,11 @@
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 fe, useState as j, useEffect as X, forwardRef as mt, createElement as Me, createContext as Vt, useContext as Pt, useCallback as be } from "react";
3
+ import { createPortal as At } from "react-dom";
4
+ var Ce = { exports: {} }, pe = {};
5
+ var Xe;
6
+ function Gt() {
7
+ if (Xe) return pe;
8
+ Xe = 1;
9
9
  var e = /* @__PURE__ */ Symbol.for("react.transitional.element"), t = /* @__PURE__ */ Symbol.for("react.fragment");
10
10
  function r(n, a, s) {
11
11
  var i = null;
@@ -25,9 +25,9 @@ function At() {
25
25
  return pe.Fragment = t, pe.jsx = r, pe.jsxs = r, pe;
26
26
  }
27
27
  var me = {};
28
- var Ye;
29
- function Gt() {
30
- return Ye || (Ye = 1, process.env.NODE_ENV !== "production" && (function() {
28
+ var Je;
29
+ function $t() {
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")
@@ -40,11 +40,11 @@ function Gt() {
40
40
  return "Profiler";
41
41
  case z:
42
42
  return "StrictMode";
43
- case Re:
43
+ case Oe:
44
44
  return "Suspense";
45
45
  case F:
46
46
  return "SuspenseList";
47
- case He:
47
+ case Be:
48
48
  return "Activity";
49
49
  }
50
50
  if (typeof c == "object")
@@ -57,15 +57,15 @@ function Gt() {
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;
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;
60
+ case _:
61
+ var g = c.render;
62
+ return c = c.displayName, c || (c = g.displayName || g.name || "", c = c !== "" ? "ForwardRef(" + c + ")" : "ForwardRef"), c;
63
+ case W:
64
+ return g = c.displayName || null, g !== null ? g : e(c.type) || "Memo";
65
+ case ge:
66
+ g = c._payload, c = c._init;
67
67
  try {
68
- return e(c(h));
68
+ return e(c(g));
69
69
  } catch {
70
70
  }
71
71
  }
@@ -77,27 +77,27 @@ function Gt() {
77
77
  function r(c) {
78
78
  try {
79
79
  t(c);
80
- var h = !1;
80
+ var g = !1;
81
81
  } catch {
82
- h = !0;
82
+ g = !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";
84
+ if (g) {
85
+ g = console;
86
+ var v = g.error, k = typeof Symbol == "function" && Symbol.toStringTag && c[Symbol.toStringTag] || c.constructor.name || "Object";
87
87
  return v.call(
88
- h,
88
+ g,
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 === ge)
97
97
  return "<...>";
98
98
  try {
99
- var h = e(c);
100
- return h ? "<" + h + ">" : "<...>";
99
+ var g = e(c);
100
+ return g ? "<" + g + ">" : "<...>";
101
101
  } catch {
102
102
  return "<...>";
103
103
  }
@@ -110,17 +110,17 @@ function Gt() {
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 (ye.call(c, "key")) {
114
+ var g = Object.getOwnPropertyDescriptor(c, "key").get;
115
+ if (g && g.isReactWarning) return !1;
116
116
  }
117
117
  return c.key !== void 0;
118
118
  }
119
- function d(c, h) {
119
+ function d(c, g) {
120
120
  function v() {
121
121
  ee || (ee = !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
+ g
124
124
  ));
125
125
  }
126
126
  v.isReactWarning = !0, Object.defineProperty(c, "key", {
@@ -134,15 +134,15 @@ function Gt() {
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, g, v, k, te, q) {
138
+ var O = v.ref;
139
139
  return c = {
140
140
  $$typeof: b,
141
141
  type: c,
142
- key: h,
142
+ key: g,
143
143
  props: v,
144
- _owner: E
145
- }, (j !== void 0 ? j : null) !== null ? Object.defineProperty(c, "ref", {
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", {
@@ -164,64 +164,64 @@ function Gt() {
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 w(c, g, v, k, te, q) {
171
+ var O = g.children;
172
+ if (O !== void 0)
173
+ if (k)
174
+ if (xe(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 (ye.call(g, "key")) {
184
+ O = e(c);
185
+ var V = Object.keys(g).filter(function(_e) {
186
+ return _e !== "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}", we[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
+ ), we[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) {
201
+ if (O = null, v !== void 0 && (r(v), O = "" + v), i(g) && (r(g.key), O = "" + g.key), "key" in g) {
202
202
  v = {};
203
- for (var ce in h)
204
- ce !== "key" && (v[ce] = h[ce]);
205
- } else v = h;
206
- return j && d(
203
+ for (var ce in g)
204
+ ce !== "key" && (v[ce] = g[ce]);
205
+ } else v = g;
206
+ return O && d(
207
207
  v,
208
208
  typeof c == "function" ? c.displayName || c.name || "Unknown" : c
209
209
  ), u(
210
210
  c,
211
- j,
211
+ O,
212
212
  v,
213
213
  a(),
214
214
  te,
215
- U
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 === ge && (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
222
  return typeof c == "object" && c !== null && c.$$typeof === b;
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 y = Tt, 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"), _ = /* @__PURE__ */ Symbol.for("react.forward_ref"), Oe = /* @__PURE__ */ Symbol.for("react.suspense"), F = /* @__PURE__ */ Symbol.for("react.suspense_list"), W = /* @__PURE__ */ Symbol.for("react.memo"), ge = /* @__PURE__ */ Symbol.for("react.lazy"), Be = /* @__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, ye = Object.prototype.hasOwnProperty, xe = Array.isArray, B = console.createTask ? console.createTask : function() {
225
225
  return null;
226
226
  };
227
227
  y = {
@@ -232,37 +232,37 @@ React keys must be passed directly to JSX without using spread:
232
232
  var ee, Z = {}, ie = y.react_stack_bottom_frame.bind(
233
233
  y,
234
234
  s
235
- )(), B = W(n(s)), xe = {};
236
- me.Fragment = P, me.jsx = function(c, h, v) {
237
- var E = 1e4 > Q.recentlyCreatedOwnerStacks++;
235
+ )(), U = B(n(s)), we = {};
236
+ me.Fragment = P, me.jsx = function(c, g, v) {
237
+ var k = 1e4 > Q.recentlyCreatedOwnerStacks++;
238
238
  return w(
239
239
  c,
240
- h,
240
+ g,
241
241
  v,
242
242
  !1,
243
- E ? Error("react-stack-top-frame") : ie,
244
- E ? W(n(c)) : B
243
+ k ? Error("react-stack-top-frame") : ie,
244
+ k ? B(n(c)) : U
245
245
  );
246
- }, me.jsxs = function(c, h, v) {
247
- var E = 1e4 > Q.recentlyCreatedOwnerStacks++;
246
+ }, me.jsxs = function(c, g, v) {
247
+ var k = 1e4 > Q.recentlyCreatedOwnerStacks++;
248
248
  return w(
249
249
  c,
250
- h,
250
+ g,
251
251
  v,
252
252
  !0,
253
- E ? Error("react-stack-top-frame") : ie,
254
- E ? W(n(c)) : B
253
+ k ? Error("react-stack-top-frame") : ie,
254
+ k ? B(n(c)) : U
255
255
  );
256
256
  };
257
257
  })()), me;
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" ? Ce.exports = Gt() : Ce.exports = $t()), Ce.exports;
262
262
  }
263
- var o = $t();
264
- const Lt = ({ children: e }) => {
265
- const t = fe(null), [r, n] = S(null);
263
+ var o = Lt();
264
+ const Nt = ({ children: e }) => {
265
+ const t = fe(null), [r, n] = j(null);
266
266
  return X(() => {
267
267
  if (t.current && !t.current.shadowRoot) {
268
268
  const a = t.current.attachShadow({ mode: "open" });
@@ -272,19 +272,19 @@ const Lt = ({ children: e }) => {
272
272
  const i = document.createElement("link");
273
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);
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();
279
- const It = (e) => e.replace(
277
+ const ft = (...e) => e.filter((t, r, n) => !!t && t.trim() !== "" && n.indexOf(t) === r).join(" ").trim();
278
+ const It = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase();
279
+ const Mt = (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) => {
284
- const t = It(e);
283
+ const Ke = (e) => {
284
+ const t = Mt(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,13 +295,13 @@ 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,
@@ -311,59 +311,59 @@ const Dt = pt(
311
311
  children: s,
312
312
  iconNode: i,
313
313
  ...d
314
- }, p) => Ne(
314
+ }, p) => Me(
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", a),
324
+ ...!s && !Dt(d) && { "aria-hidden": "true" },
325
325
  ...d
326
326
  },
327
327
  [
328
- ...i.map(([u, w]) => Ne(u, w)),
328
+ ...i.map(([u, w]) => Me(u, w)),
329
329
  ...Array.isArray(s) ? s : [s]
330
330
  ]
331
331
  )
332
332
  );
333
- const L = (e, t) => {
334
- const r = pt(
335
- ({ className: n, ...a }, s) => Ne(Dt, {
333
+ const N = (e, t) => {
334
+ const r = mt(
335
+ ({ className: n, ...a }, s) => Me(Ft, {
336
336
  ref: s,
337
337
  iconNode: t,
338
- className: mt(
339
- `lucide-${Nt(Je(e))}`,
338
+ className: ft(
339
+ `lucide-${It(Ke(e))}`,
340
340
  `lucide-${e}`,
341
341
  n
342
342
  ),
343
343
  ...a
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
+ ], ae = 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
+ ], Ae = 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 sr = [
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
+ ], ar = N("rotate-ccw", sr);
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,22 +527,22 @@ 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
+ }, ze = "viewgate_enabled", pr = () => typeof window > "u" ? !1 : new URLSearchParams(window.location.search).has("viewgate") ? (sessionStorage.setItem(ze, "true"), !0) : sessionStorage.getItem(ze) === "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([]);
540
+ const [a, s] = j(!1), [i, d] = j([]);
541
541
  X(() => {
542
- s(ur());
542
+ s(pr());
543
543
  }, []);
544
544
  const p = () => {
545
- if (sessionStorage.removeItem(Ie), s(!1), typeof window < "u") {
545
+ if (sessionStorage.removeItem(ze), s(!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
  }
@@ -551,8 +551,8 @@ const cr = [
551
551
  d((b) => [...b, { id: y, message: m, type: x }]), setTimeout(() => {
552
552
  d((b) => b.filter((T) => T.id !== y));
553
553
  }, 4e3);
554
- }, w = lr[t];
555
- return /* @__PURE__ */ o.jsxs(ft.Provider, { "data-source-path": "/src/components/ViewGateProvider.tsx:248", value: {
554
+ }, w = 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
558
  t: w,
@@ -562,10 +562,10 @@ const cr = [
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
+ a && /* @__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(ae, { "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
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 }),
571
571
  /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateProvider.tsx:274", style: { fontSize: "14px", color: "#000000" }, children: m.message })
@@ -574,7 +574,7 @@ const cr = [
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(/^\/\//))
@@ -584,7 +584,7 @@ function pr(e, t) {
584
584
  const r = document.implementation.createHTMLDocument(), n = r.createElement("base"), a = r.createElement("a");
585
585
  return r.head.appendChild(n), r.body.appendChild(a), t && (n.href = t), a.href = e, a.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
@@ -599,26 +599,26 @@ function J(e) {
599
599
  return t;
600
600
  }
601
601
  let ne = null;
602
- function ht(e = {}) {
602
+ function gt(e = {}) {
603
603
  return ne || (e.includeStyleProperties ? (ne = e.includeStyleProperties, ne) : (ne = J(window.getComputedStyle(document.documentElement)), ne));
604
604
  }
605
- function Ce(e, t) {
605
+ function Se(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 = Se(e, "border-left-width"), r = Se(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 = Se(e, "border-top-width"), r = Se(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;
@@ -627,11 +627,11 @@ function gr() {
627
627
  const r = t && t.env ? t.env.devicePixelRatio : null;
628
628
  return r && (e = parseInt(r, 10), Number.isNaN(e) && (e = 1)), e || window.devicePixelRatio || 1;
629
629
  }
630
- const I = 16384;
631
- function yr(e) {
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));
630
+ const M = 16384;
631
+ function xr(e) {
632
+ (e.width > M || e.height > M) && (e.width > M && e.height > M ? e.width > e.height ? (e.height *= M / e.width, e.width = M) : (e.width *= M / e.height, e.height = M) : e.width > M ? (e.height *= M / e.width, e.width = M) : (e.width *= M / e.height, e.height = M));
633
633
  }
634
- function Ee(e) {
634
+ function ke(e) {
635
635
  return new Promise((t, r) => {
636
636
  const n = new Image();
637
637
  n.onload = () => {
@@ -641,80 +641,80 @@ 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) {
647
+ async function vr(e, t, r) {
648
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);
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), wr(a);
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) => {
661
+ function Cr(e, t) {
662
+ return gt(t).map((r) => {
663
663
  const n = e.getPropertyValue(r), a = e.getPropertyPriority(r);
664
664
  return `${r}: ${n}${a ? " !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);
667
+ function Er(e, t, r, n) {
668
+ const a = `.${e}:${t}`, s = r.cssText ? br(r) : Cr(r, n);
669
669
  return document.createTextNode(`${a}{${s}}`);
670
670
  }
671
- function tt(e, t, r, n) {
671
+ function nt(e, t, r, n) {
672
672
  const a = window.getComputedStyle(e, r), s = a.getPropertyValue("content");
673
673
  if (s === "" || s === "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, a, 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 st = "application/font-woff", at = "image/jpeg", kr = {
688
+ woff: st,
689
+ woff2: st,
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: at,
694
+ jpeg: at,
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 De(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`);
@@ -730,86 +730,86 @@ async function yt(e, t, r) {
730
730
  }, d.readAsDataURL(a);
731
731
  });
732
732
  }
733
- const Ae = {};
734
- function Or(e, t, r) {
733
+ const $e = {};
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 ($e[n] != null)
741
+ return $e[n];
742
742
  r.cacheBust && (e += (/\?/.test(e) ? "&" : "?") + (/* @__PURE__ */ new Date()).getTime());
743
743
  let a;
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);
745
+ const s = await xt(e, r.fetchRequestInit, ({ res: i, result: d }) => (t || (t = i.headers.get("Content-Type") || ""), jr(d)));
746
+ a = Or(s, t);
747
747
  } catch (s) {
748
748
  a = r.imagePlaceholder || "";
749
749
  let i = `Failed to fetch resource: ${e}`;
750
750
  s && (i = typeof s == "string" ? s : s.message), i && console.warn(i);
751
751
  }
752
- return Ae[n] = a, a;
752
+ return $e[n] = a, a;
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) : ke(t);
757
757
  }
758
- async function Tr(e, t) {
758
+ async function Vr(e, t) {
759
759
  if (e.currentSrc) {
760
760
  const s = document.createElement("canvas"), i = s.getContext("2d");
761
761
  s.width = e.clientWidth, s.height = e.clientHeight, i?.drawImage(e, 0, 0, s.width, s.height);
762
762
  const d = s.toDataURL();
763
- return Ee(d);
763
+ return ke(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), a = await We(r, n, t);
766
+ return ke(a);
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 Re(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";
781
- async function Gr(e, t, r) {
780
+ const Gr = (e) => e.tagName != null && e.tagName.toUpperCase() === "SLOT", wt = (e) => e.tagName != null && e.tagName.toUpperCase() === "SVG";
781
+ async function $r(e, t, r) {
782
782
  var n, a;
783
- if (xt(t))
783
+ if (wt(t))
784
784
  return t;
785
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) => {
786
+ return Gr(e) && e.assignedNodes ? s = J(e.assignedNodes()) : L(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 || L(e, HTMLVideoElement) || await s.reduce((i, d) => i.then(() => Re(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
794
  const a = window.getComputedStyle(e);
795
- a.cssText ? (n.cssText = a.cssText, n.transformOrigin = a.transformOrigin) : ht(r).forEach((s) => {
795
+ a.cssText ? (n.cssText = a.cssText, n.transformOrigin = a.transformOrigin) : gt(r).forEach((s) => {
796
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));
797
+ s === "font-size" && i.endsWith("px") && (i = `${Math.floor(parseFloat(i.substring(0, i.length - 2))) - 0.1}px`), L(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));
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)) {
801
+ L(e, HTMLTextAreaElement) && (t.innerHTML = e.value), L(e, HTMLInputElement) && t.setAttribute("value", e.value);
802
+ }
803
+ function Ir(e, t) {
804
+ if (L(e, HTMLSelectElement)) {
805
805
  const n = Array.from(t.children).find((a) => e.value === a.getAttribute("value"));
806
806
  n && n.setAttribute("selected", "");
807
807
  }
808
808
  }
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;
809
+ function Mr(e, t, r) {
810
+ return L(t, Element) && (Lr(e, t, r), Sr(e, t, r), Nr(e, t), Ir(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;
@@ -818,7 +818,7 @@ async function Mr(e, t) {
818
818
  const d = r[s].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 Re(u, t, !0));
822
822
  }
823
823
  }
824
824
  const a = Object.values(n);
@@ -833,31 +833,31 @@ async function Mr(e, t) {
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 Re(e, t, r) {
837
+ return !r && t.filter && !t.filter(e) ? null : Promise.resolve(e).then((n) => Ar(n, t)).then((n) => $r(e, n, t)).then((n) => Mr(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, a) => (t.push(a), r)), t.filter((r) => !De(r));
847
847
  }
848
- async function Wr(e, t, r, n, a) {
848
+ async function Br(e, t, r, n, a) {
849
849
  try {
850
- const s = r ? pr(t, r) : t, i = De(t);
850
+ const s = 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 a || (d = await We(s, 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) || [];
860
+ const [n, , a] = Dr.exec(r) || [];
861
861
  if (!a)
862
862
  return "";
863
863
  if (a === t)
@@ -865,32 +865,32 @@ function Br(e, { preferredFontFormat: t }) {
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((s, i) => s.then((d) => Br(d, i, t, r)), Promise.resolve(n));
876
876
  }
877
877
  async function se(e, t, r) {
878
878
  var n;
879
879
  const a = (n = t.style) === null || n === void 0 ? void 0 : n.getPropertyValue(e);
880
880
  if (a) {
881
- const s = await bt(a, null, r);
881
+ const s = await Ct(a, null, r);
882
882
  return t.style.setProperty(e, s, t.style.getPropertyPriority(e)), !0;
883
883
  }
884
884
  return !1;
885
885
  }
886
- async function Ur(e, t) {
886
+ async function qr(e, t) {
887
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
888
  }
889
- async function qr(e, t) {
890
- const r = $(e, HTMLImageElement);
891
- if (!(r && !Me(e.src)) && !($(e, SVGImageElement) && !Me(e.href.baseVal)))
889
+ async function Yr(e, t) {
890
+ const r = L(e, HTMLImageElement);
891
+ if (!(r && !De(e.src)) && !(L(e, SVGImageElement) && !De(e.href.baseVal)))
892
892
  return;
893
- const n = r ? e.src : e.href.baseVal, a = await Fe(n, De(n), t);
893
+ const n = r ? e.src : e.href.baseVal, a = await We(n, He(n), t);
894
894
  await new Promise((s, i) => {
895
895
  e.onload = s, e.onerror = t.onImageErrorHandler ? (...p) => {
896
896
  try {
@@ -903,14 +903,14 @@ async function qr(e, t) {
903
903
  d.decode && (d.decode = s), d.loading === "lazy" && (d.loading = "eager"), r ? (e.srcset = "", e.src = a) : e.href.baseVal = a;
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 = J(e.childNodes).map((a) => Et(a, 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;
@@ -918,23 +918,23 @@ function Xr(e, t) {
918
918
  r[a] = n[a];
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
931
  const n = /url\(["']?([^"')]+)["']?\)/g, s = (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
935
  return Promise.all(s).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;
@@ -960,7 +960,7 @@ function it(e) {
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
965
  return e.forEach((a) => {
966
966
  if ("cssRules" in a)
@@ -968,7 +968,7 @@ async function Jr(e, t) {
968
968
  J(a.cssRules || []).forEach((s, i) => {
969
969
  if (s.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 = s.href, u = it(p).then((w) => ct(w, t)).then((w) => lt(w).forEach((m) => {
972
972
  try {
973
973
  a.insertRule(m, m.startsWith("@import") ? d += 1 : a.cssRules.length);
974
974
  } catch (x) {
@@ -985,7 +985,7 @@ async function Jr(e, t) {
985
985
  });
986
986
  } catch (s) {
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
+ a.href != null && n.push(it(a.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);
@@ -1002,66 +1002,66 @@ async function Jr(e, t) {
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 = J(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
1020
  (n.style.fontFamily || getComputedStyle(n).fontFamily).split(",").forEach((s) => {
1021
- t.add(Et(s));
1021
+ t.add(St(s));
1022
1022
  }), Array.from(n.children).forEach((s) => {
1023
1023
  s instanceof HTMLElement && r(s);
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) => {
1028
+ async function tn(e, t) {
1029
+ const r = await Qr(e, t), n = en(e);
1030
+ return (await Promise.all(r.filter((s) => n.has(St(s.style.fontFamily))).map((s) => {
1031
1031
  const i = s.parentStyleSheet ? s.parentStyleSheet.href : null;
1032
- return bt(s.cssText, i, t);
1032
+ return Ct(s.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
1039
  const n = document.createElement("style"), a = document.createTextNode(r);
1040
1040
  n.appendChild(a), 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), a = await Re(e, t, !0);
1045
+ return await rn(a, t), await Et(a, t), Jr(a, t), await vr(a, r, n);
1046
+ }
1047
+ async function sn(e, t = {}) {
1048
+ const { width: r, height: n } = yt(e, t), a = await nn(e, t), s = await ke(a), i = document.createElement("canvas"), d = i.getContext("2d"), p = t.pixelRatio || yr(), u = t.canvasWidth || r, w = t.canvasHeight || n;
1049
+ return i.width = u * p, i.height = w * p, t.skipAutoScale || xr(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;
1050
1050
  }
1051
- async function ct(e, t = {}) {
1052
- return (await nn(e, t)).toDataURL();
1051
+ async function dt(e, t = {}) {
1052
+ return (await sn(e, t)).toDataURL();
1053
1053
  }
1054
- const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 15, cn = () => {
1054
+ const je = 2147483647, Le = je, Ne = 2e6, an = je - 10, on = je - 5, cn = je - 15, he = "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,10 +1076,10 @@ 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
@@ -1089,7 +1089,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1089
1089
  a && (r.role = a);
1090
1090
  const s = e.getAttribute("name");
1091
1091
  return s && (r.name = s), r;
1092
- }, pn = /* @__PURE__ */ (() => {
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;
@@ -1110,7 +1110,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1110
1110
  }
1111
1111
  return r;
1112
1112
  };
1113
- })(), lt = (e, t, r, n) => new Promise((a) => {
1113
+ })(), ut = (e, t, r, n) => new Promise((a) => {
1114
1114
  const s = new Image();
1115
1115
  s.onload = () => {
1116
1116
  const i = document.createElement("canvas"), d = window.devicePixelRatio || 1, p = t.width + r * 2, u = t.height + r * 2;
@@ -1123,7 +1123,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1123
1123
  }
1124
1124
  a(i.toDataURL("image/png"));
1125
1125
  }, s.onerror = () => a(""), s.src = e;
1126
- }), mn = (e) => {
1126
+ }), fn = (e) => {
1127
1127
  const t = window.getComputedStyle(e), r = {};
1128
1128
  return [
1129
1129
  "display",
@@ -1138,9 +1138,9 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1138
1138
  "z-index"
1139
1139
  ].forEach((a) => {
1140
1140
  const s = t.getPropertyValue(a);
1141
- r[a] = pn(s);
1141
+ r[a] = mn(s);
1142
1142
  }), r;
1143
- }, fn = (e) => {
1143
+ }, hn = (e) => {
1144
1144
  const r = Object.keys(e).find((s) => s.startsWith("__reactFiber$") || s.startsWith("__reactInternalInstance$"));
1145
1145
  if (!r) return "";
1146
1146
  const n = [];
@@ -1154,13 +1154,13 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1154
1154
  a = a.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
1161
  const s = 120;
1162
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) => {
1163
+ }, Fe = (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;
@@ -1172,19 +1172,19 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
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
+ }, Ee = (e, t = document) => {
1176
1176
  const r = t.querySelector(e);
1177
1177
  if (r) return r;
1178
1178
  const n = t.querySelectorAll("*");
1179
1179
  for (const a of Array.from(n)) {
1180
1180
  const s = a.shadowRoot;
1181
1181
  if (s) {
1182
- const i = ze(e, s);
1182
+ const i = Ee(e, s);
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,7 +1192,7 @@ 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;
@@ -1202,33 +1202,37 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1202
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);
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 = Ee(`[${he}="${t}"]`);
1208
+ if (n && Fe(n)) return n;
1209
+ }
1210
+ let r = Ee(e.selector);
1211
+ if (r) return r;
1208
1212
  if (e.fallbackSelectors) {
1209
- for (const r of e.fallbackSelectors)
1210
- if (t = ze(r), t) return t;
1213
+ for (const n of e.fallbackSelectors)
1214
+ if (r = Ee(n), r) return r;
1211
1215
  }
1212
- return t = hn(e), t || null;
1213
- }, Le = (e) => ({
1216
+ return r = gn(e), r || null;
1217
+ }, Ie = (e) => ({
1214
1218
  tag: e.tagName.toLowerCase(),
1215
1219
  text: (e.innerText || e.getAttribute("placeholder") || "").slice(0, 50).trim(),
1216
1220
  role: e.getAttribute("role") || void 0,
1217
1221
  type: e.getAttribute("type") || void 0
1218
- }), yn = (e) => {
1222
+ }), xn = (e) => {
1219
1223
  const t = e.parentElement;
1220
1224
  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);
1225
+ const r = Array.from(t.children).filter((i) => i !== e).slice(0, 5).map((i) => Ie(i)), n = Array.from(t.children), a = n.indexOf(e);
1222
1226
  let s = "middle";
1223
1227
  return a === 0 && (s = "start"), a === n.length - 1 && (s = "end"), {
1224
1228
  target: {
1225
- ...Le(e),
1229
+ ...Ie(e),
1226
1230
  location: `${s} of ${t.tagName.toLowerCase()}`
1227
1231
  },
1228
- parent: Le(t),
1232
+ parent: Ie(t),
1229
1233
  siblings: r
1230
1234
  };
1231
- }, xn = (e) => {
1235
+ }, wn = (e) => {
1232
1236
  let t = "unknown:0", r = e;
1233
1237
  for (; r; ) {
1234
1238
  const m = r.getAttribute("data-source-path");
@@ -1238,7 +1242,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1238
1242
  }
1239
1243
  r = r.parentElement;
1240
1244
  }
1241
- const n = fn(e), a = [], s = [], i = (m) => {
1245
+ const n = hn(e), a = [], s = [], i = (m) => {
1242
1246
  const x = [];
1243
1247
  let y = m;
1244
1248
  for (; y && y.nodeType === Node.ELEMENT_NODE; ) {
@@ -1265,15 +1269,15 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1265
1269
  b = `${y.localName}[name="${A}"]`, x.unshift(b);
1266
1270
  break;
1267
1271
  } else {
1268
- let G = y, O = 1;
1272
+ let G = y, _ = 1;
1269
1273
  for (; G.previousElementSibling; )
1270
- G = G.previousElementSibling, G.nodeName.toLowerCase() === y.nodeName.toLowerCase() && O++;
1271
- O > 1 && (b += `:nth-of-type(${O})`);
1274
+ G = G.previousElementSibling, G.nodeName.toLowerCase() === y.nodeName.toLowerCase() && _++;
1275
+ _ > 1 && (b += `:nth-of-type(${_})`);
1272
1276
  }
1273
1277
  x.unshift(b), y = y.parentElement;
1274
1278
  }
1275
1279
  return x.join(" > ");
1276
- }, d = St(e.closest('[role="dialog"], [aria-modal="true"], .modal, .modal-content')), p = i(e), u = {};
1280
+ }, d = kt(e.closest('[role="dialog"], [aria-modal="true"], .modal, .modal-content')), p = i(e), u = {};
1277
1281
  ["placeholder", "aria-label", "name", "type", "alt", "title", "value", "role"].forEach((m) => {
1278
1282
  const x = e.getAttribute(m);
1279
1283
  x && (u[m] = x);
@@ -1294,96 +1298,102 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1294
1298
  fallbackSelectors: [...new Set(a)].slice(0, 5),
1295
1299
  domPath: s.slice(-10),
1296
1300
  viewportSize: { width: window.innerWidth, height: window.innerHeight },
1297
- uiContext: yn(e),
1298
- fingerprint: un(e),
1301
+ uiContext: xn(e),
1302
+ fingerprint: pn(e),
1299
1303
  metadata: {
1300
1304
  hint: `Edit ${t.split(":")[0]} at line ${t.split(":")[1] || "?"}`,
1301
- computedStyles: mn(e),
1302
- viewportBreakpoint: cn(),
1305
+ computedStyles: fn(e),
1306
+ viewportBreakpoint: ln(),
1303
1307
  outerHtml: e.outerHTML.slice(0, 1500),
1304
1308
  scrollPosition: { x: window.scrollX, y: window.scrollY },
1305
1309
  isModal: d
1306
1310
  }
1307
1311
  };
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(() => {
1312
+ }, vn = () => {
1313
+ const { addToast: e, language: t, t: r, apiKey: n, baseUrl: a, disableViewGate: s, hasActiveToasts: i } = ur(), [d, p] = j(!1), [u, w] = j(null), [m, x] = j(null), [y, b] = j(""), [T, P] = j(!1), [z, D] = j(!1), [A, G] = j(!1), [_, Oe] = j([]), [F, W] = j(null), [ge, Be] = j(!1), [oe, Q] = j(!1), [ye, xe] = j({}), [B, ee] = j(null), [Z, ie] = j(!1), [U, we] = j(() => {
1310
1314
  if (typeof window > "u") return { top: 24, right: 24 };
1311
1315
  const l = localStorage.getItem("vg-exit-pos");
1312
1316
  return l ? JSON.parse(l) : { top: 24, right: 24 };
1313
- }), [c, h] = S(!1), v = fe(null), [E, te] = S(() => {
1317
+ }), [c, g] = j(!1), v = fe(null), [k, te] = j(() => {
1314
1318
  if (typeof window > "u") return { bottom: 30, right: 30 };
1315
1319
  const l = localStorage.getItem("vg-bar-pos");
1316
1320
  return l ? JSON.parse(l) : { bottom: 30, right: 30 };
1317
- }), [U, j] = S(!1), V = fe(null), ce = (l) => {
1321
+ }), [q, O] = j(!1), V = fe(null), ce = (l) => {
1318
1322
  l.preventDefault(), l.stopPropagation();
1319
1323
  const f = l.currentTarget.parentElement?.getBoundingClientRect();
1320
- f && (h(!0), v.current = {
1324
+ f && (g(!0), v.current = {
1321
1325
  x: l.clientX,
1322
1326
  y: l.clientY,
1323
- top: B.top,
1324
- right: B.right,
1327
+ top: U.top,
1328
+ right: U.right,
1325
1329
  width: f.width,
1326
1330
  height: f.height
1327
1331
  });
1328
- }, je = (l) => {
1332
+ }, _e = (l) => {
1329
1333
  l.preventDefault(), l.stopPropagation();
1330
1334
  const f = l.currentTarget.parentElement?.getBoundingClientRect();
1331
- f && (j(!0), V.current = {
1335
+ f && (O(!0), V.current = {
1332
1336
  x: l.clientX,
1333
1337
  y: l.clientY,
1334
- bottom: E.bottom,
1335
- right: E.right,
1338
+ bottom: k.bottom,
1339
+ right: k.right,
1336
1340
  width: f.width,
1337
1341
  height: f.height
1338
1342
  });
1339
1343
  };
1340
1344
  X(() => {
1341
- if (!c && !U) return;
1342
- const l = (g) => {
1345
+ if (!c && !q) return;
1346
+ const l = (h) => {
1343
1347
  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;
1348
+ const $ = h.clientX - v.current.x, S = h.clientY - v.current.y;
1349
+ let C = v.current.top + S, E = v.current.right - $;
1346
1350
  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 });
1351
+ C = Math.max(R, Math.min(window.innerHeight - v.current.height - R, C)), E = Math.max(R, Math.min(window.innerWidth - v.current.width - R, E)), we({ top: C, right: E });
1348
1352
  }
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;
1353
+ if (q && V.current) {
1354
+ const $ = h.clientX - V.current.x, S = h.clientY - V.current.y;
1355
+ let C = V.current.bottom - S, E = V.current.right - $;
1352
1356
  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 });
1357
+ C = Math.max(R, Math.min(window.innerHeight - V.current.height - R, C)), E = Math.max(R, Math.min(window.innerWidth - V.current.width - R, E)), te({ bottom: C, right: E });
1354
1358
  }
1355
1359
  }, 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);
1360
+ c && (g(!1), localStorage.setItem("vg-exit-pos", JSON.stringify(U)), v.current = null), q && (O(!1), localStorage.setItem("vg-bar-pos", JSON.stringify(k)), V.current = null);
1357
1361
  };
1358
1362
  return window.addEventListener("mousemove", l), window.addEventListener("mouseup", f), () => {
1359
1363
  window.removeEventListener("mousemove", l), window.removeEventListener("mouseup", f);
1360
1364
  };
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(() => {
1365
+ }, [c, q, U, k]);
1366
+ const [Ue, Te] = j(null), [qe, Ye] = j(""), [jt, Ot] = j({}), re = fe(null), le = fe(null), de = be(() => {
1363
1367
  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)) {
1368
+ const l = {}, h = Array.from(document.querySelectorAll('[role="dialog"], [aria-modal="true"], .modal, .modal-content')).find((S) => kt(S) && Fe(S)), $ = !!h;
1369
+ _.forEach((S) => {
1370
+ if (!S.reference) return;
1371
+ const C = yn(S.reference, S._id), E = !!S.reference.metadata?.isModal;
1372
+ if (C && Fe(C)) {
1373
+ if (!C.hasAttribute(he))
1374
+ C.setAttribute(he, S._id);
1375
+ else {
1376
+ const H = C.getAttribute(he);
1377
+ H !== S._id && H?.startsWith("temp-") && C.setAttribute(he, S._id);
1378
+ }
1369
1379
  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))
1380
+ if ($ ? R = h.contains(C) : R = !E, !R) return;
1381
+ const I = C.getBoundingClientRect(), Y = I.left + I.width / 2, ue = I.top + I.height / 2;
1382
+ if (Y >= 0 && Y <= window.innerWidth && ue >= 0 && ue <= window.innerHeight) {
1383
+ const H = document.elementFromPoint(Y, ue);
1384
+ if (H && !C.contains(H) && !re.current?.contains(H))
1375
1385
  return;
1376
1386
  }
1377
- l[_._id] = {
1378
- top: N.top + window.scrollY,
1379
- left: N.left + window.scrollX,
1380
- width: N.width,
1381
- isModal: C
1387
+ l[S._id] = {
1388
+ top: I.top + window.scrollY,
1389
+ left: I.left + window.scrollX,
1390
+ width: I.width,
1391
+ isModal: E
1382
1392
  };
1383
1393
  }
1384
- }), jt(l), le.current = null;
1394
+ }), Ot(l), le.current = null;
1385
1395
  }));
1386
- }, [O]), K = ve(async () => {
1396
+ }, [_]), K = be(async () => {
1387
1397
  if (n) {
1388
1398
  Q(!0);
1389
1399
  try {
@@ -1391,8 +1401,8 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1391
1401
  headers: { "x-api-key": n }
1392
1402
  });
1393
1403
  if (l.ok) {
1394
- const f = await l.json();
1395
- Re(f.data || []);
1404
+ const $ = ((await l.json()).data || []).reduce((S, C) => S.find((R) => R._id === C._id) ? S : S.concat([C]), []);
1405
+ Oe($);
1396
1406
  }
1397
1407
  } catch (l) {
1398
1408
  console.error("Failed to fetch annotations", l);
@@ -1402,99 +1412,99 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1402
1412
  }
1403
1413
  }, [n, a]);
1404
1414
  X(() => {
1405
- A && O.length === 0 && !oe && G(!1);
1406
- }, [A, O.length, oe]), X(() => {
1407
- if (!d && O.length > 0) {
1415
+ A && _.length === 0 && !oe && G(!1);
1416
+ }, [A, _.length, oe]), X(() => {
1417
+ if (!d && _.length > 0) {
1408
1418
  de();
1409
- const l = new MutationObserver(() => de()), f = new ResizeObserver(() => de()), g = () => de();
1419
+ const l = new MutationObserver(() => de()), f = new ResizeObserver(() => de()), h = () => de();
1410
1420
  return l.observe(document.documentElement, {
1411
1421
  childList: !0,
1412
1422
  subtree: !0,
1413
1423
  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);
1424
+ }), f.observe(document.documentElement), window.addEventListener("scroll", h, !0), () => {
1425
+ l.disconnect(), f.disconnect(), window.removeEventListener("scroll", h, !0), le.current && cancelAnimationFrame(le.current);
1416
1426
  };
1417
1427
  }
1418
- }, [d, O.length, de]), X(() => {
1428
+ }, [d, _.length, de]), X(() => {
1419
1429
  K();
1420
1430
  }, [K]), X(() => {
1421
1431
  re.current = document.getElementById("viewgate-shadow-host");
1422
1432
  }, []);
1423
- const _e = ve((l) => {
1433
+ const Ve = be((l) => {
1424
1434
  if (!d || m) return;
1425
- const f = ut(l.clientX, l.clientY);
1435
+ const f = pt(l.clientX, l.clientY);
1426
1436
  if (!f || re.current?.contains(f) || f.closest(".vg-no-capture")) {
1427
1437
  w(null);
1428
1438
  return;
1429
1439
  }
1430
- const g = f.getBoundingClientRect();
1440
+ const h = f.getBoundingClientRect();
1431
1441
  w({
1432
1442
  tag: f.tagName.toLowerCase(),
1433
1443
  source: f.getAttribute("data-source-path") || "unknown:0",
1434
- rect: g,
1444
+ rect: h,
1435
1445
  element: f,
1436
1446
  previewText: (f.innerText || "").slice(0, 100) || (f.getAttribute("placeholder") || "").slice(0, 100) || f.tagName.toLowerCase(),
1437
1447
  semanticReference: {
1438
- ...xn(f),
1448
+ ...wn(f),
1439
1449
  normalizedOffset: {
1440
- x: (l.clientX - g.left) / g.width,
1441
- y: (l.clientY - g.top) / g.height
1450
+ x: (l.clientX - h.left) / h.width,
1451
+ y: (l.clientY - h.top) / h.height
1442
1452
  }
1443
1453
  }
1444
1454
  });
1445
- }, [d, m]), Te = ve(async (l) => {
1455
+ }, [d, m]), Pe = be(async (l) => {
1446
1456
  if (!d || m) return;
1447
- const f = ut(l.clientX, l.clientY);
1457
+ const f = pt(l.clientX, l.clientY);
1448
1458
  if (!(!f || re.current?.contains(f) || f.closest(".vg-no-capture")) && u) {
1449
1459
  l.preventDefault(), l.stopPropagation(), D(!0);
1450
1460
  try {
1451
- const _ = window.scrollX, k = window.scrollY, C = await ct(document.documentElement, {
1461
+ const S = window.scrollX, C = window.scrollY, E = await dt(document.documentElement, {
1452
1462
  pixelRatio: 1.5,
1453
1463
  cacheBust: !0,
1454
1464
  width: window.innerWidth,
1455
1465
  height: window.innerHeight,
1456
1466
  backgroundColor: "#ffffff",
1457
1467
  style: {
1458
- transform: `scale(${1 / window.devicePixelRatio}) translate(-${_}px, -${k}px)`,
1468
+ transform: `scale(${1 / window.devicePixelRatio}) translate(-${S}px, -${C}px)`,
1459
1469
  transformOrigin: "top left"
1460
1470
  },
1461
- filter: (Y) => {
1462
- const we = Y;
1463
- return !(re.current?.contains(we) || we.id === "viewgate-ui");
1471
+ filter: (H) => {
1472
+ const ve = H;
1473
+ return !(re.current?.contains(ve) || ve.id === "viewgate-ui");
1464
1474
  }
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);
1475
+ }), R = u.element.getBoundingClientRect(), I = R.top >= 0 && R.left >= 0 && R.bottom <= window.innerHeight && R.right <= window.innerWidth;
1476
+ let Y = "";
1477
+ if (I && R.width > 0 && R.height > 0)
1478
+ Y = await ut(E, R, 24, 1.5);
1469
1479
  else
1470
1480
  try {
1471
- q = await ct(u.element, {
1481
+ Y = await dt(u.element, {
1472
1482
  pixelRatio: 2,
1473
1483
  cacheBust: !0,
1474
1484
  backgroundColor: "#ffffff",
1475
- filter: (Y) => {
1476
- const we = Y;
1477
- return !re.current?.contains(we);
1485
+ filter: (H) => {
1486
+ const ve = H;
1487
+ return !re.current?.contains(ve);
1478
1488
  }
1479
1489
  });
1480
1490
  } catch {
1481
- q = await lt(C, R, 24, 1.5);
1491
+ Y = await ut(E, R, 24, 1.5);
1482
1492
  }
1483
1493
  const ue = {
1484
1494
  ...u.semanticReference,
1485
1495
  metadata: {
1486
1496
  ...u.semanticReference.metadata,
1487
- screenshotUrl: C,
1488
- elementScreenshot: q
1497
+ screenshotUrl: E,
1498
+ elementScreenshot: Y
1489
1499
  }
1490
1500
  };
1491
1501
  x({
1492
1502
  ...u,
1493
- visualPreview: q,
1503
+ visualPreview: Y,
1494
1504
  semanticReference: ue
1495
1505
  });
1496
- } catch (g) {
1497
- console.error("Failed to capture preview:", g), x(u);
1506
+ } catch (h) {
1507
+ console.error("Failed to capture preview:", h), x(u);
1498
1508
  } finally {
1499
1509
  D(!1), w(null);
1500
1510
  }
@@ -1506,24 +1516,24 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1506
1516
  m ? x(null) : A ? G(!1) : d && p(!1);
1507
1517
  return;
1508
1518
  }
1509
- const M = (() => {
1510
- let C = document.activeElement;
1511
- for (; C && C.shadowRoot && C.shadowRoot.activeElement; )
1512
- C = C.shadowRoot.activeElement;
1513
- return C;
1519
+ const $ = (() => {
1520
+ let E = document.activeElement;
1521
+ for (; E && E.shadowRoot && E.shadowRoot.activeElement; )
1522
+ E = E.shadowRoot.activeElement;
1523
+ return E;
1514
1524
  })();
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));
1525
+ if (["input", "textarea"].includes(($?.tagName || "").toLowerCase()) || $?.isContentEditable) return;
1526
+ const C = f.key.toLowerCase();
1527
+ C === "c" && !m && !A && p((E) => !E), C === "v" && !m && (_.length > 0 || A) && (G((E) => !E), A || p(!1));
1518
1528
  };
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);
1529
+ return d && !m ? document.body.classList.add("vg-cursor-pointer") : document.body.classList.remove("vg-cursor-pointer"), window.addEventListener("keydown", l), window.addEventListener("mousemove", Ve, !0), window.addEventListener("click", Pe, !0), () => {
1530
+ document.body.classList.remove("vg-cursor-pointer"), window.removeEventListener("keydown", l), window.removeEventListener("mousemove", Ve, !0), window.removeEventListener("click", Pe, !0);
1521
1531
  };
1522
- }, [d, m, A, O, _e, Te]);
1523
- const Ot = async () => {
1532
+ }, [d, m, A, _, Ve, Pe]);
1533
+ const _t = async () => {
1524
1534
  if (!m || !y.trim()) return;
1525
1535
  P(!0);
1526
- const { semanticReference: l } = m, [f, g] = (l.source || "").split(":"), M = g || "0";
1536
+ const { semanticReference: l } = m, [f, h] = (l.source || "").split(":"), $ = h || "0";
1527
1537
  try {
1528
1538
  if (!(await fetch(`${a}/api/annotations`, {
1529
1539
  method: "POST",
@@ -1533,7 +1543,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1533
1543
  },
1534
1544
  body: JSON.stringify({
1535
1545
  filePath: f,
1536
- line: parseInt(M),
1546
+ line: parseInt($),
1537
1547
  url: window.location.href,
1538
1548
  message: y,
1539
1549
  componentName: l.componentPath || m.tag,
@@ -1549,21 +1559,21 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1549
1559
  })
1550
1560
  })).ok) throw new Error("Backend failed");
1551
1561
  e(r.success, "success"), x(null), b(""), p(!1), K();
1552
- } catch (_) {
1553
- console.error(_), e(r.error, "error");
1562
+ } catch (S) {
1563
+ console.error(S), e(r.error, "error");
1554
1564
  } finally {
1555
1565
  P(!1);
1556
1566
  }
1557
1567
  };
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: [
1568
+ return /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1021", className: "vg-container", children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1022", className: "vg-no-capture", children: [
1559
1569
  !i && /* @__PURE__ */ o.jsxs(
1560
1570
  "div",
1561
1571
  {
1562
1572
  style: {
1563
1573
  position: "fixed",
1564
- top: `${B.top}px`,
1565
- right: `${B.right}px`,
1566
- zIndex: Ge + 10,
1574
+ top: `${U.top}px`,
1575
+ right: `${U.right}px`,
1576
+ zIndex: Le + 10,
1567
1577
  display: "flex",
1568
1578
  alignItems: "center",
1569
1579
  gap: "8px",
@@ -1597,14 +1607,14 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1597
1607
  onMouseLeave: (l) => {
1598
1608
  l.currentTarget.style.backgroundColor = "rgba(255, 255, 255, 0.85)", l.currentTarget.style.color = "#1e293b";
1599
1609
  },
1600
- children: /* @__PURE__ */ o.jsx(Qe, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1032", size: 14 })
1610
+ children: /* @__PURE__ */ o.jsx(tt, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1066", size: 14 })
1601
1611
  }
1602
1612
  ),
1603
1613
  /* @__PURE__ */ o.jsx(
1604
1614
  "button",
1605
1615
  {
1606
1616
  onClick: (l) => {
1607
- l.stopPropagation(), H({
1617
+ l.stopPropagation(), W({
1608
1618
  title: r.exitConfirmTitle || "Close ViewGate?",
1609
1619
  message: r.exitConfirmMessage || "Are you sure you want to close ViewGate?",
1610
1620
  type: "danger",
@@ -1633,7 +1643,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1633
1643
  onMouseLeave: (l) => {
1634
1644
  l.currentTarget.style.transform = "scale(1) rotate(0deg)", l.currentTarget.style.color = "#64748b", l.currentTarget.style.backgroundColor = "rgba(255, 255, 255, 0.9)";
1635
1645
  },
1636
- children: /* @__PURE__ */ o.jsx(Pe, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1072", size: 20, strokeWidth: 2.5 })
1646
+ children: /* @__PURE__ */ o.jsx(Ge, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1106", size: 20, strokeWidth: 2.5 })
1637
1647
  }
1638
1648
  )
1639
1649
  ]
@@ -1642,23 +1652,23 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1642
1652
  /* @__PURE__ */ o.jsxs(
1643
1653
  "div",
1644
1654
  {
1645
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1078",
1655
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1112",
1646
1656
  style: {
1647
1657
  position: "fixed",
1648
- bottom: `${E.bottom}px`,
1649
- right: `${E.right}px`,
1650
- zIndex: Ge,
1658
+ bottom: `${k.bottom}px`,
1659
+ right: `${k.right}px`,
1660
+ zIndex: Le,
1651
1661
  display: "flex",
1652
1662
  alignItems: "center",
1653
1663
  gap: "8px",
1654
- transition: U ? "none" : "all 0.4s cubic-bezier(0.4, 0, 0.2, 1)"
1664
+ transition: q ? "none" : "all 0.4s cubic-bezier(0.4, 0, 0.2, 1)"
1655
1665
  },
1656
1666
  id: "viewgate-ui",
1657
1667
  children: [
1658
1668
  /* @__PURE__ */ o.jsx(
1659
1669
  "div",
1660
1670
  {
1661
- onMouseDown: je,
1671
+ onMouseDown: _e,
1662
1672
  style: {
1663
1673
  width: "24px",
1664
1674
  height: "40px",
@@ -1683,10 +1693,10 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1683
1693
  l.currentTarget.style.backgroundColor = "rgba(255, 255, 255, 0.85)", l.currentTarget.style.color = "#1e293b";
1684
1694
  },
1685
1695
  className: "vg-animate-slide-up",
1686
- children: /* @__PURE__ */ o.jsx(Qe, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1121", size: 16 })
1696
+ children: /* @__PURE__ */ o.jsx(tt, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1155", size: 16 })
1687
1697
  }
1688
1698
  ),
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: [
1699
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1158", className: "vg-action-bar vg-animate-slide-up", style: { transition: "all 0.4s cubic-bezier(0.4, 0, 0.2, 1)" }, children: [
1690
1700
  /* @__PURE__ */ o.jsx(
1691
1701
  "button",
1692
1702
  {
@@ -1696,13 +1706,13 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1696
1706
  padding: "12px 24px",
1697
1707
  background: d ? "#ef4444" : void 0
1698
1708
  },
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 })
1709
+ children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1167", style: { display: "flex", alignItems: "center", gap: "10px" }, children: [
1710
+ d ? /* @__PURE__ */ o.jsx(Ge, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1168", size: 20, className: "vg-animate-pop" }) : /* @__PURE__ */ o.jsx(Ae, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1168", size: 20, className: "vg-animate-pop" }),
1711
+ /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1169", children: d ? r.exitMode : r.enterMode })
1702
1712
  ] })
1703
1713
  }
1704
1714
  ),
1705
- O.length > 0 && /* @__PURE__ */ o.jsxs(
1715
+ _.length > 0 && /* @__PURE__ */ o.jsxs(
1706
1716
  "button",
1707
1717
  {
1708
1718
  onClick: () => {
@@ -1711,8 +1721,8 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1711
1721
  className: "vg-button-ghost vg-animate-pop",
1712
1722
  style: { animationDelay: "0.1s" },
1713
1723
  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 })
1724
+ /* @__PURE__ */ o.jsx(Xt, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1182", size: 20 }),
1725
+ /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1183", children: r.viewComments })
1716
1726
  ]
1717
1727
  }
1718
1728
  )
@@ -1720,7 +1730,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1720
1730
  ]
1721
1731
  }
1722
1732
  ),
1723
- z && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1157", style: {
1733
+ z && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1191", style: {
1724
1734
  position: "fixed",
1725
1735
  top: 0,
1726
1736
  left: 0,
@@ -1731,16 +1741,16 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1731
1741
  display: "flex",
1732
1742
  alignItems: "center",
1733
1743
  justifyContent: "center",
1734
- zIndex: Ge + 1,
1744
+ zIndex: Le + 1,
1735
1745
  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..." })
1746
+ }, children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1197", className: "vg-glassmorphism", style: { padding: "30px 50px", display: "flex", flexDirection: "column", alignItems: "center", gap: "16px" }, children: [
1747
+ /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1198", className: "vg-spinner" }),
1748
+ /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1199", style: { fontWeight: 600, fontSize: "14px", color: "#000000" }, children: "Capturando..." })
1739
1749
  ] }) }),
1740
1750
  d && !m && /* @__PURE__ */ o.jsx(
1741
1751
  "div",
1742
1752
  {
1743
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1172",
1753
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1206",
1744
1754
  className: "vg-backdrop-blur",
1745
1755
  style: {
1746
1756
  opacity: 1,
@@ -1752,36 +1762,36 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1752
1762
  ${u.rect.left}px ${u.rect.bottom}px,
1753
1763
  ${u.rect.left}px ${u.rect.top}px
1754
1764
  )` : "none",
1755
- zIndex: sn
1765
+ zIndex: an
1756
1766
  }
1757
1767
  }
1758
1768
  ),
1759
1769
  d && u && !m && !z && /* @__PURE__ */ o.jsx(
1760
1770
  "div",
1761
1771
  {
1762
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1191",
1772
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1225",
1763
1773
  className: "vg-selection-pulse",
1764
1774
  style: {
1765
1775
  top: u.rect.top - 4,
1766
1776
  left: u.rect.left - 4,
1767
1777
  width: u.rect.width + 8,
1768
1778
  height: u.rect.height + 8,
1769
- zIndex: an
1779
+ zIndex: on
1770
1780
  },
1771
1781
  children: /* @__PURE__ */ o.jsxs(
1772
1782
  "div",
1773
1783
  {
1774
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1201",
1784
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1235",
1775
1785
  className: "vg-selection-label",
1776
1786
  style: {
1777
1787
  ...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
1788
  ...u.rect.left + 200 > window.innerWidth ? { left: "auto", right: "0" } : { left: "0", right: "auto" }
1779
1789
  },
1780
1790
  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: [
1791
+ /* @__PURE__ */ o.jsx(tr, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1251", size: 16 }),
1792
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1252", style: { display: "flex", flexDirection: "column" }, children: [
1793
+ /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1253", style: { fontWeight: 700 }, children: r.selectToComment }),
1794
+ /* @__PURE__ */ o.jsxs("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1254", style: { fontSize: "10px", opacity: 0.8, fontFamily: "monospace" }, children: [
1785
1795
  Math.round(u.rect.width),
1786
1796
  " × ",
1787
1797
  Math.round(u.rect.height)
@@ -1792,7 +1802,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1792
1802
  )
1793
1803
  }
1794
1804
  ),
1795
- m && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1230", className: "vg-animate-fade", style: {
1805
+ m && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1264", className: "vg-animate-fade", style: {
1796
1806
  position: "fixed",
1797
1807
  top: 0,
1798
1808
  left: 0,
@@ -1803,14 +1813,14 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1803
1813
  display: "flex",
1804
1814
  alignItems: "center",
1805
1815
  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: {
1816
+ zIndex: Ne
1817
+ }, children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1269", className: "vg-glassmorphism vg-animate-slide", style: {
1808
1818
  padding: "40px",
1809
1819
  width: "500px",
1810
1820
  boxShadow: "0 25px 50px -12px rgba(0, 0, 0, 0.25)"
1811
1821
  }, 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: {
1822
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1273", style: { textAlign: "center", marginBottom: "32px" }, children: [
1823
+ /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1274", style: {
1814
1824
  width: "48px",
1815
1825
  height: "48px",
1816
1826
  background: "var(--vg-primary-gradient)",
@@ -1821,11 +1831,11 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1821
1831
  margin: "0 auto 16px",
1822
1832
  color: "white",
1823
1833
  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 })
1834
+ }, children: /* @__PURE__ */ o.jsx(Ae, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1279", size: 24 }) }),
1835
+ /* @__PURE__ */ o.jsx("h2", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1281", style: { margin: "0 0 8px 0", fontSize: "24px", fontWeight: 800, color: "#0f172a" }, children: r.feedbackHeader }),
1836
+ /* @__PURE__ */ o.jsx("p", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1282", style: { margin: 0, color: "#000000", fontSize: "15px" }, children: r.feedbackSubheader })
1827
1837
  ] }),
1828
- m.visualPreview && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1252", style: {
1838
+ m.visualPreview && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1286", style: {
1829
1839
  marginBottom: "24px",
1830
1840
  borderRadius: "12px",
1831
1841
  overflow: "hidden",
@@ -1853,7 +1863,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1853
1863
  style: { fontSize: "15px", padding: "16px", marginBottom: "24px" }
1854
1864
  }
1855
1865
  ),
1856
- /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1279", style: { display: "flex", gap: "12px" }, children: [
1866
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1313", style: { display: "flex", gap: "12px" }, children: [
1857
1867
  /* @__PURE__ */ o.jsx(
1858
1868
  "button",
1859
1869
  {
@@ -1867,19 +1877,19 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1867
1877
  /* @__PURE__ */ o.jsx(
1868
1878
  "button",
1869
1879
  {
1870
- onClick: Ot,
1880
+ onClick: _t,
1871
1881
  className: "vg-button-primary",
1872
1882
  disabled: T || !y.trim(),
1873
1883
  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" })
1884
+ children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1328", style: { display: "flex", alignItems: "center", gap: "8px" }, children: [
1885
+ T ? /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1329", className: "vg-spinner", style: { width: "16px", height: "16px", borderWidth: "2px" } }) : /* @__PURE__ */ o.jsx(ir, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1329", size: 18 }),
1886
+ /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1330", children: T ? r.submitting : r.sendFeedback || "Send Comment" })
1877
1887
  ] })
1878
1888
  }
1879
1889
  )
1880
1890
  ] })
1881
1891
  ] }) }),
1882
- A && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1306", className: "vg-animate-fade", style: {
1892
+ A && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1340", className: "vg-animate-fade", style: {
1883
1893
  position: "fixed",
1884
1894
  top: 0,
1885
1895
  left: 0,
@@ -1890,24 +1900,24 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1890
1900
  display: "flex",
1891
1901
  alignItems: "center",
1892
1902
  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: {
1903
+ zIndex: Ne
1904
+ }, children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1345", className: "vg-glassmorphism vg-animate-slide", style: {
1895
1905
  padding: "32px",
1896
1906
  width: "650px",
1897
1907
  maxHeight: "85vh",
1898
1908
  display: "flex",
1899
1909
  flexDirection: "column"
1900
1910
  }, 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 })
1911
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1349", style: { display: "flex", alignItems: "center", justifyContent: "space-between", marginBottom: "20px" }, children: [
1912
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1350", style: { display: "flex", alignItems: "center", gap: "12px" }, children: [
1913
+ /* @__PURE__ */ o.jsx("h2", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1351", style: { margin: 0, fontSize: "20px", fontWeight: 800, color: "#0f172a" }, children: B ? r.commentDetails : r.annotations }),
1914
+ !B && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1355", className: "vg-badge", style: { background: "#e0e7ff", color: "#6366f1" }, children: _.length })
1905
1915
  ] }),
1906
- /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1326", style: { display: "flex", gap: "8px" }, children: [
1907
- W && /* @__PURE__ */ o.jsx(
1916
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1360", style: { display: "flex", gap: "8px" }, children: [
1917
+ B && /* @__PURE__ */ o.jsx(
1908
1918
  "button",
1909
1919
  {
1910
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1328",
1920
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1362",
1911
1921
  className: "vg-button-ghost",
1912
1922
  style: { padding: "6px 14px", fontSize: "12px" },
1913
1923
  onClick: () => ee(null),
@@ -1917,21 +1927,21 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1917
1927
  /* @__PURE__ */ o.jsx(
1918
1928
  "button",
1919
1929
  {
1920
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1336",
1930
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1370",
1921
1931
  className: "vg-button-ghost",
1922
1932
  style: { padding: "8px", borderRadius: "50%" },
1923
1933
  onClick: () => {
1924
1934
  G(!1), ee(null);
1925
1935
  },
1926
- children: /* @__PURE__ */ o.jsx(Pe, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1341", size: 20 })
1936
+ children: /* @__PURE__ */ o.jsx(Ge, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1375", size: 20 })
1927
1937
  }
1928
1938
  )
1929
1939
  ] })
1930
1940
  ] }),
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(
1941
+ /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1380", style: { maxHeight: "60vh", overflowY: "auto", paddingRight: "10px" }, className: "vg-custom-scrollbar", children: oe ? /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1382", style: { display: "flex", justifyContent: "center", padding: "40px" }, children: /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1383", className: "vg-spinner" }) }) : (B ? _.filter((l) => l._id === B) : _).map((l, f) => /* @__PURE__ */ o.jsxs(
1932
1942
  "div",
1933
1943
  {
1934
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1353",
1944
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1387",
1935
1945
  className: "vg-glassmorphism vg-animate-slide",
1936
1946
  style: {
1937
1947
  padding: "20px",
@@ -1941,34 +1951,34 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1941
1951
  animationDelay: `${f * 0.05}s`
1942
1952
  },
1943
1953
  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 }),
1954
+ /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1398", style: { display: "flex", justifyContent: "space-between", marginBottom: "16px", alignItems: "center" }, children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1399", style: { display: "flex", gap: "12px", alignItems: "center" }, children: [
1955
+ l.status === "ready_for_review" ? /* @__PURE__ */ o.jsxs("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1401", className: "vg-badge", style: { backgroundColor: "#f0fdf4", color: "#16a34a" }, children: [
1956
+ /* @__PURE__ */ o.jsx(ae, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1402", size: 14 }),
1947
1957
  " ",
1948
1958
  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 }),
1959
+ ] }) : /* @__PURE__ */ o.jsxs("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1405", className: "vg-badge", style: { backgroundColor: "#fff7ed", color: "#ea580c" }, children: [
1960
+ /* @__PURE__ */ o.jsx(Qe, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1406", size: 14 }),
1951
1961
  " ",
1952
1962
  r.pending
1953
1963
  ] }),
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) })
1964
+ /* @__PURE__ */ o.jsx("span", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1409", style: { fontSize: "12px", color: "#000000" }, children: un(l.timestamp || l.createdAt || l.reference?.timestamp, t) })
1955
1965
  ] }) }),
1956
- We === l._id ? /* @__PURE__ */ o.jsx(
1966
+ Ue === l._id ? /* @__PURE__ */ o.jsx(
1957
1967
  "textarea",
1958
1968
  {
1959
1969
  className: "vg-textarea",
1960
- value: Be,
1961
- onChange: (g) => Ue(g.target.value),
1970
+ value: qe,
1971
+ onChange: (h) => Ye(h.target.value),
1962
1972
  rows: 3,
1963
1973
  autoFocus: !0,
1964
1974
  style: { marginBottom: "16px" }
1965
1975
  }
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: [
1976
+ ) : /* @__PURE__ */ o.jsx("p", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1425", style: { margin: "0 0 20px 0", fontSize: "16px", color: "#1e293b", lineHeight: 1.6 }, children: l.message }),
1977
+ /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1428", 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
1978
  /* @__PURE__ */ o.jsx(
1969
1979
  "button",
1970
1980
  {
1971
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1397",
1981
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1431",
1972
1982
  className: "vg-button-primary vg-animate-pop",
1973
1983
  style: { padding: "8px 16px", fontSize: "13px" },
1974
1984
  onClick: async () => {
@@ -1976,8 +1986,8 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1976
1986
  (await fetch(`${a}/api/annotations/${l._id}`, {
1977
1987
  method: "PATCH",
1978
1988
  headers: { "Content-Type": "application/json", "x-api-key": n },
1979
- body: JSON.stringify({ message: Be })
1980
- })).ok && (Oe(null), K(), e(r.updateSuccess, "success"));
1989
+ body: JSON.stringify({ message: qe })
1990
+ })).ok && (Te(null), K(), e(r.updateSuccess, "success"));
1981
1991
  } catch {
1982
1992
  e(r.error, "error");
1983
1993
  }
@@ -1985,19 +1995,19 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
1985
1995
  children: r.save
1986
1996
  }
1987
1997
  ),
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 })
1998
+ /* @__PURE__ */ o.jsx("button", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1453", className: "vg-button-ghost vg-animate-pop", style: { padding: "8px 16px", fontSize: "13px" }, onClick: () => Te(null), children: r.cancel })
1989
1999
  ] }) : /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
1990
2000
  /* @__PURE__ */ o.jsxs(
1991
2001
  "button",
1992
2002
  {
1993
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1423",
2003
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1457",
1994
2004
  className: "vg-button-ghost vg-animate-pop",
1995
2005
  style: { padding: "8px 16px", fontSize: "13px" },
1996
2006
  onClick: () => {
1997
- Oe(l._id), Ue(l.message);
2007
+ Te(l._id), Ye(l.message);
1998
2008
  },
1999
2009
  children: [
2000
- /* @__PURE__ */ o.jsx(rr, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1431", size: 14 }),
2010
+ /* @__PURE__ */ o.jsx(nr, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1465", size: 14 }),
2001
2011
  " ",
2002
2012
  r.edit
2003
2013
  ]
@@ -2006,14 +2016,14 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2006
2016
  /* @__PURE__ */ o.jsxs(
2007
2017
  "button",
2008
2018
  {
2009
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1433",
2019
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1467",
2010
2020
  className: "vg-button-ghost vg-animate-pop",
2011
2021
  style: { padding: "8px 16px", fontSize: "13px", animationDelay: "0.05s" },
2012
2022
  onClick: () => {
2013
2023
  l.url && (window.location.href = l.url);
2014
2024
  },
2015
2025
  children: [
2016
- /* @__PURE__ */ o.jsx(Ke, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1440", size: 14 }),
2026
+ /* @__PURE__ */ o.jsx(et, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1474", size: 14 }),
2017
2027
  " ",
2018
2028
  r.review
2019
2029
  ]
@@ -2022,11 +2032,11 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2022
2032
  l.status === "pending" ? /* @__PURE__ */ o.jsxs(
2023
2033
  "button",
2024
2034
  {
2025
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1443",
2035
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1477",
2026
2036
  className: "vg-button-primary vg-animate-pop",
2027
2037
  style: { padding: "8px 16px", fontSize: "13px", animationDelay: "0.1s" },
2028
2038
  onClick: () => {
2029
- H({
2039
+ W({
2030
2040
  title: r.markReadyConfirm,
2031
2041
  message: r.confirmMarkReady,
2032
2042
  type: "success",
@@ -2040,13 +2050,13 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2040
2050
  } catch {
2041
2051
  e(r.error, "error");
2042
2052
  } finally {
2043
- H(null);
2053
+ W(null);
2044
2054
  }
2045
2055
  }
2046
2056
  });
2047
2057
  },
2048
2058
  children: [
2049
- /* @__PURE__ */ o.jsx(ae, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1471", size: 14 }),
2059
+ /* @__PURE__ */ o.jsx(ae, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1505", size: 14 }),
2050
2060
  " ",
2051
2061
  r.markReady
2052
2062
  ]
@@ -2054,11 +2064,11 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2054
2064
  ) : /* @__PURE__ */ o.jsxs(
2055
2065
  "button",
2056
2066
  {
2057
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1474",
2067
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1508",
2058
2068
  className: "vg-button-ghost vg-animate-pop",
2059
2069
  style: { padding: "8px 16px", fontSize: "13px", animationDelay: "0.1s" },
2060
2070
  onClick: () => {
2061
- H({
2071
+ W({
2062
2072
  title: r.reopenConfirm,
2063
2073
  message: r.confirmReopen,
2064
2074
  type: "success",
@@ -2073,13 +2083,13 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2073
2083
  } catch {
2074
2084
  e(r.error, "error");
2075
2085
  } finally {
2076
- H(null);
2086
+ W(null);
2077
2087
  }
2078
2088
  }
2079
2089
  });
2080
2090
  },
2081
2091
  children: [
2082
- /* @__PURE__ */ o.jsx(sr, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1502", size: 14 }),
2092
+ /* @__PURE__ */ o.jsx(ar, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1536", size: 14 }),
2083
2093
  " ",
2084
2094
  r.reopen
2085
2095
  ]
@@ -2088,11 +2098,11 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2088
2098
  /* @__PURE__ */ o.jsx(
2089
2099
  "button",
2090
2100
  {
2091
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1505",
2101
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1539",
2092
2102
  className: "vg-button-ghost vg-animate-pop",
2093
2103
  style: { padding: "8px 12px", color: "#ef4444", borderColor: "#fee2e2", animationDelay: "0.15s" },
2094
2104
  onClick: () => {
2095
- H({
2105
+ W({
2096
2106
  title: r.deleteConfirm,
2097
2107
  message: r.confirmDelete,
2098
2108
  type: "danger",
@@ -2105,12 +2115,12 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2105
2115
  } catch {
2106
2116
  e(r.error, "error");
2107
2117
  } finally {
2108
- H(null);
2118
+ W(null);
2109
2119
  }
2110
2120
  }
2111
2121
  });
2112
2122
  },
2113
- children: /* @__PURE__ */ o.jsx(et, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1532", size: 16 })
2123
+ children: /* @__PURE__ */ o.jsx(rt, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1566", size: 16 })
2114
2124
  }
2115
2125
  )
2116
2126
  ] }) })
@@ -2119,7 +2129,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2119
2129
  l._id
2120
2130
  )) })
2121
2131
  ] }) }),
2122
- F && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1547", className: "vg-animate-fade", style: {
2132
+ F && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1581", className: "vg-animate-fade", style: {
2123
2133
  position: "fixed",
2124
2134
  top: 0,
2125
2135
  left: 0,
@@ -2130,15 +2140,15 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2130
2140
  display: "flex",
2131
2141
  alignItems: "center",
2132
2142
  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: {
2143
+ zIndex: Ne + 100
2144
+ }, children: /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1586", className: "vg-glassmorphism vg-animate-slide", style: {
2135
2145
  padding: "40px",
2136
2146
  width: "420px",
2137
2147
  textAlign: "center",
2138
2148
  border: "1px solid rgba(255, 255, 255, 0.1)",
2139
2149
  boxShadow: "0 25px 50px -12px rgba(0, 0, 0, 0.5)"
2140
2150
  }, children: [
2141
- /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1559", style: {
2151
+ /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1593", style: {
2142
2152
  width: "64px",
2143
2153
  height: "64px",
2144
2154
  background: F.type === "danger" ? "rgba(239, 68, 68, 0.1)" : "rgba(99, 102, 241, 0.1)",
@@ -2149,17 +2159,17 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2149
2159
  margin: "0 auto 24px",
2150
2160
  color: F.type === "danger" ? "#ef4444" : "#6366f1",
2151
2161
  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: [
2162
+ }, children: F.type === "danger" ? /* @__PURE__ */ o.jsx(rt, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1602", size: 32 }) : /* @__PURE__ */ o.jsx(ae, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1602", size: 32 }) }),
2163
+ /* @__PURE__ */ o.jsx("h3", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1604", style: { margin: "0 0 12px 0", fontSize: "20px", fontWeight: 800, color: "#000000", letterSpacing: "-0.02em" }, children: F.title }),
2164
+ /* @__PURE__ */ o.jsx("p", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1605", style: { margin: "0 0 32px 0", fontSize: "15px", color: "#000000", lineHeight: 1.6 }, children: F.message }),
2165
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1606", style: { display: "flex", gap: "16px" }, children: [
2156
2166
  /* @__PURE__ */ o.jsx(
2157
2167
  "button",
2158
2168
  {
2159
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1573",
2169
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1607",
2160
2170
  className: "vg-button-ghost",
2161
2171
  style: { flex: 1, height: "44px" },
2162
- onClick: () => !Z && H(null),
2172
+ onClick: () => !Z && W(null),
2163
2173
  disabled: Z,
2164
2174
  children: r.no
2165
2175
  }
@@ -2167,7 +2177,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2167
2177
  /* @__PURE__ */ o.jsx(
2168
2178
  "button",
2169
2179
  {
2170
- "data-source-path": "/src/components/ViewGateOverlay.tsx:1581",
2180
+ "data-source-path": "/src/components/ViewGateOverlay.tsx:1615",
2171
2181
  className: "vg-button-primary",
2172
2182
  style: {
2173
2183
  flex: 1,
@@ -2190,16 +2200,16 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2190
2200
  ie(!1);
2191
2201
  }
2192
2202
  },
2193
- children: Z ? /* @__PURE__ */ o.jsx(Zt, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1606", size: 18, className: "vg-animate-spin" }) : r.yes
2203
+ children: Z ? /* @__PURE__ */ o.jsx(Kt, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1640", size: 18, className: "vg-animate-spin" }) : r.yes
2194
2204
  }
2195
2205
  )
2196
2206
  ] })
2197
2207
  ] }) }),
2198
- !d && !A && O.map((l, f) => {
2199
- const g = Rt[l._id];
2200
- if (!g) return null;
2201
- const _ = O.slice(0, f).filter(
2202
- (k) => k.reference?.selector && k.reference.selector === l.reference?.selector
2208
+ !d && !A && _.map((l, f) => {
2209
+ const h = jt[l._id];
2210
+ if (!h) return null;
2211
+ const S = _.slice(0, f).filter(
2212
+ (C) => C.reference?.selector && C.reference.selector === l.reference?.selector
2203
2213
  ).length * 34;
2204
2214
  return /* @__PURE__ */ o.jsxs(
2205
2215
  "div",
@@ -2207,38 +2217,38 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2207
2217
  className: "vg-pin-container vg-animate-pop",
2208
2218
  style: {
2209
2219
  position: "fixed",
2210
- top: g.top - 20 - window.scrollY,
2211
- left: g.left + g.width / 2 - 16 + _ - window.scrollX,
2220
+ top: h.top - 20 - window.scrollY,
2221
+ left: h.left + h.width / 2 - 16 + S - window.scrollX,
2212
2222
  cursor: "pointer",
2213
2223
  animationDelay: `${f * 0.08}s`,
2214
2224
  transition: "all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275)",
2215
- zIndex: on - f
2225
+ zIndex: cn - f
2216
2226
  // Ensure staggered pins don't overlap tooltips weirdly
2217
2227
  },
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]: "" }));
2228
+ onMouseEnter: (C) => {
2229
+ const E = C.currentTarget.getBoundingClientRect();
2230
+ window.innerHeight - E.bottom < 180 ? xe((I) => ({ ...I, [l._id]: "vg-top" })) : xe((I) => ({ ...I, [l._id]: "" }));
2221
2231
  },
2222
2232
  onClick: () => {
2223
2233
  G(!0), ee(l._id);
2224
2234
  },
2225
2235
  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 }),
2236
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1687", className: `vg-pin-tooltip ${ye[l._id] || ""}`, children: [
2237
+ /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1688", style: { display: "flex", alignItems: "center", gap: "8px", marginBottom: "8px" }, children: [
2238
+ l.status === "ready_for_review" ? /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1690", style: { display: "flex", alignItems: "center", gap: "6px", color: "#16a34a", fontWeight: 700, fontSize: "11px" }, children: [
2239
+ /* @__PURE__ */ o.jsx(ae, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1691", size: 12 }),
2230
2240
  " ",
2231
2241
  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 }),
2242
+ ] }) : /* @__PURE__ */ o.jsxs("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1694", style: { display: "flex", alignItems: "center", gap: "6px", color: h.isModal ? "#f59e0b" : "#ea580c", fontWeight: 700, fontSize: "11px" }, children: [
2243
+ /* @__PURE__ */ o.jsx(Qe, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1695", size: 12 }),
2234
2244
  " ",
2235
2245
  r.pending
2236
2246
  ] }),
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" }) })
2247
+ h.isModal && /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1699", 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:1700", children: "MODAL" }) })
2238
2248
  ] }),
2239
- /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1670", style: { fontWeight: 500, color: "#1e293b", lineHeight: 1.4 }, children: l.message })
2249
+ /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1704", style: { fontWeight: 500, color: "#1e293b", lineHeight: 1.4 }, children: l.message })
2240
2250
  ] }),
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 }) })
2251
+ /* @__PURE__ */ o.jsx("div", { "data-source-path": "/src/components/ViewGateOverlay.tsx:1707", className: `vg-formal-pin ${l.status === "ready_for_review" ? "ready" : ""} ${h.isModal ? "modal-variant" : ""}`, children: l.status === "ready_for_review" ? /* @__PURE__ */ o.jsx(ae, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1708", size: 18 }) : h.isModal ? /* @__PURE__ */ o.jsx(et, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1708", size: 16 }) : /* @__PURE__ */ o.jsx(Ae, { "data-source-path": "/src/components/ViewGateOverlay.tsx:1708", size: 16 }) })
2242
2252
  ]
2243
2253
  },
2244
2254
  `pin-${l._id}`
@@ -2246,7 +2256,7 @@ const ke = 2147483647, Ge = ke, $e = 2e6, sn = ke - 10, an = ke - 5, on = ke - 1
2246
2256
  })
2247
2257
  ] }) });
2248
2258
  };
2249
- function kt(e, t, r) {
2259
+ function Rt(e, t, r) {
2250
2260
  if (!t.endsWith(".tsx") && !t.endsWith(".jsx") || t.includes("node_modules")) return e;
2251
2261
  const n = (d) => d.replace(/\\/g, "/"), a = n(t).replace(n(r), "");
2252
2262
  return e.split(`
@@ -2256,27 +2266,27 @@ function kt(e, t, r) {
2256
2266
  }).join(`
2257
2267
  `);
2258
2268
  }
2259
- function En() {
2269
+ function Sn() {
2260
2270
  return {
2261
2271
  name: "vite-plugin-viewgate",
2262
2272
  enforce: "pre",
2263
2273
  transform(e, t) {
2264
2274
  return {
2265
- code: kt(e, t, process.cwd()),
2275
+ code: Rt(e, t, process.cwd()),
2266
2276
  map: null
2267
2277
  };
2268
2278
  }
2269
2279
  };
2270
2280
  }
2271
- function Sn(e) {
2281
+ function kn(e) {
2272
2282
  const t = this.resourcePath;
2273
- return t ? (process.env.NODE_ENV, kt(e, t, process.cwd())) : e;
2283
+ return t ? (process.env.NODE_ENV, Rt(e, t, process.cwd())) : e;
2274
2284
  }
2275
2285
  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
2286
+ En as ViewGate,
2287
+ vn as ViewGateOverlay,
2288
+ Rt as transformSourcePaths,
2289
+ ur as useViewGate,
2290
+ kn as viewgateNextLoader,
2291
+ Sn as viewgatePlugin
2282
2292
  };