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