@levo-so/react 0.1.59 → 0.1.60
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/audience/components/block.d.ts.map +1 -0
- package/dist/audience/components/component.d.ts.map +1 -0
- package/dist/audience/components/page.d.ts.map +1 -0
- package/dist/audience/hooks/useBounce.d.ts.map +1 -0
- package/dist/audience/hooks/useCurrentTab.d.ts.map +1 -0
- package/dist/audience/hooks/useIdentifyAudience.d.ts.map +1 -0
- package/dist/audience/hooks/useOpenTabs.d.ts.map +1 -0
- package/dist/audience/hooks/useScrollBehavior.d.ts.map +1 -0
- package/dist/audience/hooks/useTextSelection.d.ts.map +1 -0
- package/dist/audience/hooks/useTrackClicks.d.ts.map +1 -0
- package/dist/audience/index.d.ts.map +1 -0
- package/dist/audience/utils/autocapture.d.ts.map +1 -0
- package/dist/audience/utils/rageclick.d.ts.map +1 -0
- package/dist/components/Dialog.d.ts.map +1 -0
- package/dist/components/DialogWrapper.d.ts.map +1 -0
- package/dist/components/Sonner.d.ts.map +1 -0
- package/dist/components/Spinner.d.ts.map +1 -0
- package/dist/components/Table.d.ts.map +1 -0
- package/dist/components/Tabs.d.ts.map +1 -0
- package/dist/components/Tooltip.d.ts.map +1 -0
- package/dist/components/button/Button.d.ts.map +1 -0
- package/dist/components/button/buttonVariants.d.ts.map +1 -0
- package/dist/components/button/index.d.ts.map +1 -0
- package/dist/components/index.d.ts.map +1 -0
- package/dist/constants/fileUploadPresets.d.ts.map +1 -0
- package/dist/constants/index.d.ts.map +1 -0
- package/dist/index.css +1 -1
- package/dist/index.js +779 -915
- package/dist/membership/components/Button.d.ts.map +1 -0
- package/dist/membership/components/Container.d.ts.map +1 -0
- package/dist/membership/components/Core.d.ts.map +1 -0
- package/dist/membership/components/Popup.d.ts.map +1 -0
- package/dist/membership/index.d.ts.map +1 -0
- package/dist/membership/useLevoOAuth.d.ts.map +1 -0
- package/dist/providers/LevoProvider.d.ts.map +1 -0
- package/dist/utils/byteToSize.d.ts.map +1 -0
- package/dist/utils/cn.d.ts.map +1 -0
- package/dist/utils/errorHandler.d.ts.map +1 -0
- package/dist/utils/index.d.ts.map +1 -0
- package/dist/utils/isDateObject.d.ts.map +1 -0
- package/dist/utils/isEmptyObject.d.ts.map +1 -0
- package/dist/utils/isNullOrUndefined.d.ts.map +1 -0
- package/dist/utils/isObject.d.ts.map +1 -0
- package/package.json +22 -22
- package/dist/audience/hooks/useDownloadSpeed.d.ts +0 -3
- package/dist/audience/hooks/usePerformanceMetrics.d.ts +0 -12
package/dist/index.js
CHANGED
|
@@ -1,19 +1,16 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
|
|
14
|
-
import { Toaster as bt, toast as me } from "sonner";
|
|
15
|
-
import { toast as Br } from "sonner";
|
|
16
|
-
const vt = [
|
|
2
|
+
import * as A from "react";
|
|
3
|
+
import L, { createContext as tt, useContext as je, useState as O, useEffect as x, useMemo as Ne, useRef as ke, useCallback as ae } from "react";
|
|
4
|
+
import { clsx as nt } from "clsx";
|
|
5
|
+
import { twMerge as Se } from "tailwind-merge";
|
|
6
|
+
import { usePageLifecycle as rt, LifecycleState as se } from "use-page-lifecycle";
|
|
7
|
+
import { Slot as ot, Dialog as N, Tabs as $, Tooltip as F } from "radix-ui";
|
|
8
|
+
import { cva as st } from "class-variance-authority";
|
|
9
|
+
import { X as it } from "lucide-react";
|
|
10
|
+
import { Toaster as at, toast as ce } from "sonner";
|
|
11
|
+
import { toast as Sr } from "sonner";
|
|
12
|
+
import { getLevoError as Ce } from "@levo-so/core";
|
|
13
|
+
const ct = [
|
|
17
14
|
"pdf",
|
|
18
15
|
"txt",
|
|
19
16
|
"xml",
|
|
@@ -27,7 +24,7 @@ const vt = [
|
|
|
27
24
|
"odp",
|
|
28
25
|
"ppt",
|
|
29
26
|
"pptx"
|
|
30
|
-
],
|
|
27
|
+
], lt = [
|
|
31
28
|
"svg",
|
|
32
29
|
"png",
|
|
33
30
|
"jpg",
|
|
@@ -35,7 +32,7 @@ const vt = [
|
|
|
35
32
|
"gif",
|
|
36
33
|
"webp",
|
|
37
34
|
"avif"
|
|
38
|
-
],
|
|
35
|
+
], ut = ["mp4", "ogv", "webm"], dt = ["mp3", "ogg", "opus"], ft = {
|
|
39
36
|
"application/xml": [".xml"],
|
|
40
37
|
"text/plain": [".txt"],
|
|
41
38
|
"application/pdf": [".pdf"],
|
|
@@ -48,7 +45,7 @@ const vt = [
|
|
|
48
45
|
".docx"
|
|
49
46
|
],
|
|
50
47
|
"text/csv": [".csv"]
|
|
51
|
-
},
|
|
48
|
+
}, mt = {
|
|
52
49
|
"image/jpeg": [".jpeg", ".jpg"],
|
|
53
50
|
"image/jpg": [".jpg"],
|
|
54
51
|
"image/png": [".png"],
|
|
@@ -57,332 +54,312 @@ const vt = [
|
|
|
57
54
|
"image/svg+xml": [".svg"],
|
|
58
55
|
"image/webp": [".webp"],
|
|
59
56
|
"image/avif": [".avif"]
|
|
60
|
-
},
|
|
57
|
+
}, gt = {
|
|
61
58
|
"video/mp4": [".mp4"],
|
|
62
59
|
"video/mpeg": [".mpeg"],
|
|
63
60
|
"video/webm": [".webm"]
|
|
64
|
-
},
|
|
61
|
+
}, pt = {
|
|
65
62
|
"audio/mpeg": [".mp3"],
|
|
66
63
|
"audio/ogg": [".oga"],
|
|
67
64
|
"audio/opus": [".opus"]
|
|
68
|
-
},
|
|
69
|
-
audio:
|
|
70
|
-
document:
|
|
71
|
-
image:
|
|
72
|
-
video:
|
|
73
|
-
},
|
|
74
|
-
audio:
|
|
75
|
-
document:
|
|
76
|
-
image:
|
|
77
|
-
video:
|
|
78
|
-
},
|
|
79
|
-
...
|
|
80
|
-
...
|
|
81
|
-
...
|
|
82
|
-
...
|
|
83
|
-
],
|
|
84
|
-
...
|
|
85
|
-
...
|
|
86
|
-
...
|
|
87
|
-
...
|
|
65
|
+
}, G = {
|
|
66
|
+
audio: pt,
|
|
67
|
+
document: ft,
|
|
68
|
+
image: mt,
|
|
69
|
+
video: gt
|
|
70
|
+
}, J = {
|
|
71
|
+
audio: dt,
|
|
72
|
+
document: ct,
|
|
73
|
+
image: lt,
|
|
74
|
+
video: ut
|
|
75
|
+
}, cr = [
|
|
76
|
+
...J.audio,
|
|
77
|
+
...J.document,
|
|
78
|
+
...J.image,
|
|
79
|
+
...J.video
|
|
80
|
+
], lr = {
|
|
81
|
+
...G.audio,
|
|
82
|
+
...G.document,
|
|
83
|
+
...G.image,
|
|
84
|
+
...G.video
|
|
88
85
|
};
|
|
89
|
-
var
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
95
|
-
*
|
|
96
|
-
* This source code is licensed under the MIT license found in the
|
|
97
|
-
* LICENSE file in the root directory of this source tree.
|
|
98
|
-
*/
|
|
99
|
-
var Ee;
|
|
100
|
-
function _t() {
|
|
101
|
-
if (Ee) return z;
|
|
102
|
-
Ee = 1;
|
|
86
|
+
var X = { exports: {} }, Y = {};
|
|
87
|
+
var ve;
|
|
88
|
+
function bt() {
|
|
89
|
+
if (ve) return Y;
|
|
90
|
+
ve = 1;
|
|
103
91
|
var e = Symbol.for("react.transitional.element"), t = Symbol.for("react.fragment");
|
|
104
|
-
function n(r, o,
|
|
105
|
-
var
|
|
106
|
-
if (
|
|
107
|
-
|
|
108
|
-
for (var
|
|
109
|
-
|
|
110
|
-
} else
|
|
111
|
-
return o =
|
|
92
|
+
function n(r, o, i) {
|
|
93
|
+
var a = null;
|
|
94
|
+
if (i !== void 0 && (a = "" + i), o.key !== void 0 && (a = "" + o.key), "key" in o) {
|
|
95
|
+
i = {};
|
|
96
|
+
for (var c in o)
|
|
97
|
+
c !== "key" && (i[c] = o[c]);
|
|
98
|
+
} else i = o;
|
|
99
|
+
return o = i.ref, {
|
|
112
100
|
$$typeof: e,
|
|
113
101
|
type: r,
|
|
114
|
-
key:
|
|
102
|
+
key: a,
|
|
115
103
|
ref: o !== void 0 ? o : null,
|
|
116
|
-
props:
|
|
104
|
+
props: i
|
|
117
105
|
};
|
|
118
106
|
}
|
|
119
|
-
return
|
|
107
|
+
return Y.Fragment = t, Y.jsx = n, Y.jsxs = n, Y;
|
|
120
108
|
}
|
|
121
|
-
var
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
function St() {
|
|
133
|
-
return ke || (ke = 1, process.env.NODE_ENV !== "production" && function() {
|
|
134
|
-
function e(i) {
|
|
135
|
-
if (i == null) return null;
|
|
136
|
-
if (typeof i == "function")
|
|
137
|
-
return i.$$typeof === ot ? null : i.displayName || i.name || null;
|
|
138
|
-
if (typeof i == "string") return i;
|
|
139
|
-
switch (i) {
|
|
140
|
-
case S:
|
|
109
|
+
var z = {};
|
|
110
|
+
var ye;
|
|
111
|
+
function ht() {
|
|
112
|
+
return ye || (ye = 1, process.env.NODE_ENV !== "production" && function() {
|
|
113
|
+
function e(s) {
|
|
114
|
+
if (s == null) return null;
|
|
115
|
+
if (typeof s == "function")
|
|
116
|
+
return s.$$typeof === Ze ? null : s.displayName || s.name || null;
|
|
117
|
+
if (typeof s == "string") return s;
|
|
118
|
+
switch (s) {
|
|
119
|
+
case j:
|
|
141
120
|
return "Fragment";
|
|
142
|
-
case
|
|
121
|
+
case h:
|
|
143
122
|
return "Profiler";
|
|
144
|
-
case
|
|
123
|
+
case S:
|
|
145
124
|
return "StrictMode";
|
|
146
|
-
case
|
|
125
|
+
case b:
|
|
147
126
|
return "Suspense";
|
|
148
|
-
case
|
|
127
|
+
case P:
|
|
149
128
|
return "SuspenseList";
|
|
150
|
-
case
|
|
129
|
+
case Ke:
|
|
151
130
|
return "Activity";
|
|
152
131
|
}
|
|
153
|
-
if (typeof
|
|
154
|
-
switch (typeof
|
|
132
|
+
if (typeof s == "object")
|
|
133
|
+
switch (typeof s.tag == "number" && console.error(
|
|
155
134
|
"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
|
|
156
|
-
),
|
|
157
|
-
case
|
|
135
|
+
), s.$$typeof) {
|
|
136
|
+
case k:
|
|
158
137
|
return "Portal";
|
|
159
|
-
case
|
|
160
|
-
return
|
|
138
|
+
case M:
|
|
139
|
+
return s.displayName || "Context";
|
|
161
140
|
case T:
|
|
162
|
-
return (
|
|
163
|
-
case
|
|
164
|
-
var
|
|
165
|
-
return
|
|
166
|
-
case
|
|
167
|
-
return
|
|
168
|
-
case
|
|
169
|
-
|
|
141
|
+
return (s._context.displayName || "Context") + ".Consumer";
|
|
142
|
+
case U:
|
|
143
|
+
var u = s.render;
|
|
144
|
+
return s = s.displayName, s || (s = u.displayName || u.name || "", s = s !== "" ? "ForwardRef(" + s + ")" : "ForwardRef"), s;
|
|
145
|
+
case I:
|
|
146
|
+
return u = s.displayName || null, u !== null ? u : e(s.type) || "Memo";
|
|
147
|
+
case B:
|
|
148
|
+
u = s._payload, s = s._init;
|
|
170
149
|
try {
|
|
171
|
-
return e(
|
|
150
|
+
return e(s(u));
|
|
172
151
|
} catch {
|
|
173
152
|
}
|
|
174
153
|
}
|
|
175
154
|
return null;
|
|
176
155
|
}
|
|
177
|
-
function t(
|
|
178
|
-
return "" +
|
|
156
|
+
function t(s) {
|
|
157
|
+
return "" + s;
|
|
179
158
|
}
|
|
180
|
-
function n(
|
|
159
|
+
function n(s) {
|
|
181
160
|
try {
|
|
182
|
-
t(
|
|
183
|
-
var
|
|
161
|
+
t(s);
|
|
162
|
+
var u = !1;
|
|
184
163
|
} catch {
|
|
185
|
-
|
|
164
|
+
u = !0;
|
|
186
165
|
}
|
|
187
|
-
if (
|
|
188
|
-
|
|
189
|
-
var
|
|
190
|
-
return
|
|
191
|
-
|
|
166
|
+
if (u) {
|
|
167
|
+
u = console;
|
|
168
|
+
var p = u.error, y = typeof Symbol == "function" && Symbol.toStringTag && s[Symbol.toStringTag] || s.constructor.name || "Object";
|
|
169
|
+
return p.call(
|
|
170
|
+
u,
|
|
192
171
|
"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
|
|
193
|
-
|
|
194
|
-
), t(
|
|
172
|
+
y
|
|
173
|
+
), t(s);
|
|
195
174
|
}
|
|
196
175
|
}
|
|
197
|
-
function r(
|
|
198
|
-
if (
|
|
199
|
-
if (typeof
|
|
176
|
+
function r(s) {
|
|
177
|
+
if (s === j) return "<>";
|
|
178
|
+
if (typeof s == "object" && s !== null && s.$$typeof === B)
|
|
200
179
|
return "<...>";
|
|
201
180
|
try {
|
|
202
|
-
var
|
|
203
|
-
return
|
|
181
|
+
var u = e(s);
|
|
182
|
+
return u ? "<" + u + ">" : "<...>";
|
|
204
183
|
} catch {
|
|
205
184
|
return "<...>";
|
|
206
185
|
}
|
|
207
186
|
}
|
|
208
187
|
function o() {
|
|
209
|
-
var
|
|
210
|
-
return
|
|
188
|
+
var s = te.A;
|
|
189
|
+
return s === null ? null : s.getOwner();
|
|
211
190
|
}
|
|
212
|
-
function
|
|
191
|
+
function i() {
|
|
213
192
|
return Error("react-stack-top-frame");
|
|
214
193
|
}
|
|
215
|
-
function
|
|
216
|
-
if (
|
|
217
|
-
var
|
|
218
|
-
if (
|
|
194
|
+
function a(s) {
|
|
195
|
+
if (fe.call(s, "key")) {
|
|
196
|
+
var u = Object.getOwnPropertyDescriptor(s, "key").get;
|
|
197
|
+
if (u && u.isReactWarning) return !1;
|
|
219
198
|
}
|
|
220
|
-
return
|
|
199
|
+
return s.key !== void 0;
|
|
221
200
|
}
|
|
222
|
-
function
|
|
223
|
-
function
|
|
224
|
-
|
|
201
|
+
function c(s, u) {
|
|
202
|
+
function p() {
|
|
203
|
+
me || (me = !0, console.error(
|
|
225
204
|
"%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)",
|
|
226
|
-
|
|
205
|
+
u
|
|
227
206
|
));
|
|
228
207
|
}
|
|
229
|
-
|
|
230
|
-
get:
|
|
208
|
+
p.isReactWarning = !0, Object.defineProperty(s, "key", {
|
|
209
|
+
get: p,
|
|
231
210
|
configurable: !0
|
|
232
211
|
});
|
|
233
212
|
}
|
|
234
|
-
function
|
|
235
|
-
var
|
|
236
|
-
return
|
|
213
|
+
function l() {
|
|
214
|
+
var s = e(this.type);
|
|
215
|
+
return ge[s] || (ge[s] = !0, console.error(
|
|
237
216
|
"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."
|
|
238
|
-
)),
|
|
217
|
+
)), s = this.props.ref, s !== void 0 ? s : null;
|
|
239
218
|
}
|
|
240
|
-
function
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
219
|
+
function g(s, u, p, y, V, re) {
|
|
220
|
+
var w = p.ref;
|
|
221
|
+
return s = {
|
|
222
|
+
$$typeof: _,
|
|
223
|
+
type: s,
|
|
224
|
+
key: u,
|
|
225
|
+
props: p,
|
|
226
|
+
_owner: y
|
|
227
|
+
}, (w !== void 0 ? w : null) !== null ? Object.defineProperty(s, "ref", {
|
|
248
228
|
enumerable: !1,
|
|
249
|
-
get:
|
|
250
|
-
}) : Object.defineProperty(
|
|
229
|
+
get: l
|
|
230
|
+
}) : Object.defineProperty(s, "ref", { enumerable: !1, value: null }), s._store = {}, Object.defineProperty(s._store, "validated", {
|
|
251
231
|
configurable: !1,
|
|
252
232
|
enumerable: !1,
|
|
253
233
|
writable: !0,
|
|
254
234
|
value: 0
|
|
255
|
-
}), Object.defineProperty(
|
|
235
|
+
}), Object.defineProperty(s, "_debugInfo", {
|
|
256
236
|
configurable: !1,
|
|
257
237
|
enumerable: !1,
|
|
258
238
|
writable: !0,
|
|
259
239
|
value: null
|
|
260
|
-
}), Object.defineProperty(
|
|
240
|
+
}), Object.defineProperty(s, "_debugStack", {
|
|
261
241
|
configurable: !1,
|
|
262
242
|
enumerable: !1,
|
|
263
243
|
writable: !0,
|
|
264
|
-
value:
|
|
265
|
-
}), Object.defineProperty(
|
|
244
|
+
value: V
|
|
245
|
+
}), Object.defineProperty(s, "_debugTask", {
|
|
266
246
|
configurable: !1,
|
|
267
247
|
enumerable: !1,
|
|
268
248
|
writable: !0,
|
|
269
|
-
value:
|
|
270
|
-
}), Object.freeze && (Object.freeze(
|
|
249
|
+
value: re
|
|
250
|
+
}), Object.freeze && (Object.freeze(s.props), Object.freeze(s)), s;
|
|
271
251
|
}
|
|
272
|
-
function
|
|
273
|
-
var
|
|
274
|
-
if (
|
|
275
|
-
if (
|
|
276
|
-
if (
|
|
277
|
-
for (
|
|
278
|
-
|
|
279
|
-
Object.freeze && Object.freeze(
|
|
252
|
+
function m(s, u, p, y, V, re) {
|
|
253
|
+
var w = u.children;
|
|
254
|
+
if (w !== void 0)
|
|
255
|
+
if (y)
|
|
256
|
+
if (Qe(w)) {
|
|
257
|
+
for (y = 0; y < w.length; y++)
|
|
258
|
+
f(w[y]);
|
|
259
|
+
Object.freeze && Object.freeze(w);
|
|
280
260
|
} else
|
|
281
261
|
console.error(
|
|
282
262
|
"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
|
|
283
263
|
);
|
|
284
|
-
else
|
|
285
|
-
if (
|
|
286
|
-
|
|
287
|
-
var
|
|
288
|
-
return
|
|
264
|
+
else f(w);
|
|
265
|
+
if (fe.call(u, "key")) {
|
|
266
|
+
w = e(s);
|
|
267
|
+
var W = Object.keys(u).filter(function(et) {
|
|
268
|
+
return et !== "key";
|
|
289
269
|
});
|
|
290
|
-
|
|
270
|
+
y = 0 < W.length ? "{key: someKey, " + W.join(": ..., ") + ": ...}" : "{key: someKey}", he[w + y] || (W = 0 < W.length ? "{" + W.join(": ..., ") + ": ...}" : "{}", console.error(
|
|
291
271
|
`A props object containing a "key" prop is being spread into JSX:
|
|
292
272
|
let props = %s;
|
|
293
273
|
<%s {...props} />
|
|
294
274
|
React keys must be passed directly to JSX without using spread:
|
|
295
275
|
let props = %s;
|
|
296
276
|
<%s key={someKey} {...props} />`,
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
),
|
|
277
|
+
y,
|
|
278
|
+
w,
|
|
279
|
+
W,
|
|
280
|
+
w
|
|
281
|
+
), he[w + y] = !0);
|
|
302
282
|
}
|
|
303
|
-
if (
|
|
304
|
-
|
|
305
|
-
for (var
|
|
306
|
-
|
|
307
|
-
} else
|
|
308
|
-
return
|
|
309
|
-
|
|
310
|
-
typeof
|
|
311
|
-
),
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
W,
|
|
283
|
+
if (w = null, p !== void 0 && (n(p), w = "" + p), a(u) && (n(u.key), w = "" + u.key), "key" in u) {
|
|
284
|
+
p = {};
|
|
285
|
+
for (var oe in u)
|
|
286
|
+
oe !== "key" && (p[oe] = u[oe]);
|
|
287
|
+
} else p = u;
|
|
288
|
+
return w && c(
|
|
289
|
+
p,
|
|
290
|
+
typeof s == "function" ? s.displayName || s.name || "Unknown" : s
|
|
291
|
+
), g(
|
|
292
|
+
s,
|
|
293
|
+
w,
|
|
294
|
+
p,
|
|
316
295
|
o(),
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
ae
|
|
296
|
+
V,
|
|
297
|
+
re
|
|
320
298
|
);
|
|
321
299
|
}
|
|
322
|
-
function
|
|
323
|
-
typeof
|
|
300
|
+
function f(s) {
|
|
301
|
+
E(s) ? s._store && (s._store.validated = 1) : typeof s == "object" && s !== null && s.$$typeof === B && (s._payload.status === "fulfilled" ? E(s._payload.value) && s._payload.value._store && (s._payload.value._store.validated = 1) : s._store && (s._store.validated = 1));
|
|
302
|
+
}
|
|
303
|
+
function E(s) {
|
|
304
|
+
return typeof s == "object" && s !== null && s.$$typeof === _;
|
|
324
305
|
}
|
|
325
|
-
var
|
|
306
|
+
var v = L, _ = Symbol.for("react.transitional.element"), k = Symbol.for("react.portal"), j = Symbol.for("react.fragment"), S = Symbol.for("react.strict_mode"), h = Symbol.for("react.profiler"), T = Symbol.for("react.consumer"), M = Symbol.for("react.context"), U = Symbol.for("react.forward_ref"), b = Symbol.for("react.suspense"), P = Symbol.for("react.suspense_list"), I = Symbol.for("react.memo"), B = Symbol.for("react.lazy"), Ke = Symbol.for("react.activity"), Ze = Symbol.for("react.client.reference"), te = v.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, fe = Object.prototype.hasOwnProperty, Qe = Array.isArray, ne = console.createTask ? console.createTask : function() {
|
|
326
307
|
return null;
|
|
327
308
|
};
|
|
328
|
-
|
|
329
|
-
react_stack_bottom_frame: function(
|
|
330
|
-
return
|
|
309
|
+
v = {
|
|
310
|
+
react_stack_bottom_frame: function(s) {
|
|
311
|
+
return s();
|
|
331
312
|
}
|
|
332
313
|
};
|
|
333
|
-
var
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
)(),
|
|
337
|
-
|
|
338
|
-
var
|
|
339
|
-
return
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
314
|
+
var me, ge = {}, pe = v.react_stack_bottom_frame.bind(
|
|
315
|
+
v,
|
|
316
|
+
i
|
|
317
|
+
)(), be = ne(r(i)), he = {};
|
|
318
|
+
z.Fragment = j, z.jsx = function(s, u, p) {
|
|
319
|
+
var y = 1e4 > te.recentlyCreatedOwnerStacks++;
|
|
320
|
+
return m(
|
|
321
|
+
s,
|
|
322
|
+
u,
|
|
323
|
+
p,
|
|
343
324
|
!1,
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
I ? Error("react-stack-top-frame") : ye,
|
|
347
|
-
I ? se(r(i)) : xe
|
|
325
|
+
y ? Error("react-stack-top-frame") : pe,
|
|
326
|
+
y ? ne(r(s)) : be
|
|
348
327
|
);
|
|
349
|
-
},
|
|
350
|
-
var
|
|
351
|
-
return
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
328
|
+
}, z.jsxs = function(s, u, p) {
|
|
329
|
+
var y = 1e4 > te.recentlyCreatedOwnerStacks++;
|
|
330
|
+
return m(
|
|
331
|
+
s,
|
|
332
|
+
u,
|
|
333
|
+
p,
|
|
355
334
|
!0,
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
I ? Error("react-stack-top-frame") : ye,
|
|
359
|
-
I ? se(r(i)) : xe
|
|
335
|
+
y ? Error("react-stack-top-frame") : pe,
|
|
336
|
+
y ? ne(r(s)) : be
|
|
360
337
|
);
|
|
361
338
|
};
|
|
362
|
-
}()),
|
|
339
|
+
}()), z;
|
|
363
340
|
}
|
|
364
|
-
var
|
|
365
|
-
function
|
|
366
|
-
return
|
|
341
|
+
var we;
|
|
342
|
+
function vt() {
|
|
343
|
+
return we || (we = 1, process.env.NODE_ENV === "production" ? X.exports = bt() : X.exports = ht()), X.exports;
|
|
367
344
|
}
|
|
368
|
-
var
|
|
345
|
+
var d = vt(), Re = {
|
|
369
346
|
color: void 0,
|
|
370
347
|
size: void 0,
|
|
371
348
|
className: void 0,
|
|
372
349
|
style: void 0,
|
|
373
350
|
attr: void 0
|
|
374
|
-
},
|
|
375
|
-
function
|
|
351
|
+
}, xe = L.createContext && /* @__PURE__ */ L.createContext(Re), yt = ["attr", "size", "title"];
|
|
352
|
+
function wt(e, t) {
|
|
376
353
|
if (e == null) return {};
|
|
377
|
-
var n =
|
|
354
|
+
var n = xt(e, t), r, o;
|
|
378
355
|
if (Object.getOwnPropertySymbols) {
|
|
379
|
-
var
|
|
380
|
-
for (o = 0; o <
|
|
381
|
-
r =
|
|
356
|
+
var i = Object.getOwnPropertySymbols(e);
|
|
357
|
+
for (o = 0; o < i.length; o++)
|
|
358
|
+
r = i[o], !(t.indexOf(r) >= 0) && Object.prototype.propertyIsEnumerable.call(e, r) && (n[r] = e[r]);
|
|
382
359
|
}
|
|
383
360
|
return n;
|
|
384
361
|
}
|
|
385
|
-
function
|
|
362
|
+
function xt(e, t) {
|
|
386
363
|
if (e == null) return {};
|
|
387
364
|
var n = {};
|
|
388
365
|
for (var r in e)
|
|
@@ -392,17 +369,17 @@ function Ct(e, t) {
|
|
|
392
369
|
}
|
|
393
370
|
return n;
|
|
394
371
|
}
|
|
395
|
-
function
|
|
396
|
-
return
|
|
372
|
+
function q() {
|
|
373
|
+
return q = Object.assign ? Object.assign.bind() : function(e) {
|
|
397
374
|
for (var t = 1; t < arguments.length; t++) {
|
|
398
375
|
var n = arguments[t];
|
|
399
376
|
for (var r in n)
|
|
400
377
|
Object.prototype.hasOwnProperty.call(n, r) && (e[r] = n[r]);
|
|
401
378
|
}
|
|
402
379
|
return e;
|
|
403
|
-
},
|
|
380
|
+
}, q.apply(this, arguments);
|
|
404
381
|
}
|
|
405
|
-
function
|
|
382
|
+
function Ee(e, t) {
|
|
406
383
|
var n = Object.keys(e);
|
|
407
384
|
if (Object.getOwnPropertySymbols) {
|
|
408
385
|
var r = Object.getOwnPropertySymbols(e);
|
|
@@ -412,25 +389,25 @@ function Oe(e, t) {
|
|
|
412
389
|
}
|
|
413
390
|
return n;
|
|
414
391
|
}
|
|
415
|
-
function
|
|
392
|
+
function K(e) {
|
|
416
393
|
for (var t = 1; t < arguments.length; t++) {
|
|
417
394
|
var n = arguments[t] != null ? arguments[t] : {};
|
|
418
|
-
t % 2 ?
|
|
419
|
-
|
|
420
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) :
|
|
395
|
+
t % 2 ? Ee(Object(n), !0).forEach(function(r) {
|
|
396
|
+
Et(e, r, n[r]);
|
|
397
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : Ee(Object(n)).forEach(function(r) {
|
|
421
398
|
Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(n, r));
|
|
422
399
|
});
|
|
423
400
|
}
|
|
424
401
|
return e;
|
|
425
402
|
}
|
|
426
|
-
function
|
|
427
|
-
return t =
|
|
403
|
+
function Et(e, t, n) {
|
|
404
|
+
return t = Tt(t), t in e ? Object.defineProperty(e, t, { value: n, enumerable: !0, configurable: !0, writable: !0 }) : e[t] = n, e;
|
|
428
405
|
}
|
|
429
|
-
function
|
|
430
|
-
var t =
|
|
406
|
+
function Tt(e) {
|
|
407
|
+
var t = _t(e, "string");
|
|
431
408
|
return typeof t == "symbol" ? t : t + "";
|
|
432
409
|
}
|
|
433
|
-
function
|
|
410
|
+
function _t(e, t) {
|
|
434
411
|
if (typeof e != "object" || !e) return e;
|
|
435
412
|
var n = e[Symbol.toPrimitive];
|
|
436
413
|
if (n !== void 0) {
|
|
@@ -440,43 +417,43 @@ function Pt(e, t) {
|
|
|
440
417
|
}
|
|
441
418
|
return (t === "string" ? String : Number)(e);
|
|
442
419
|
}
|
|
443
|
-
function
|
|
444
|
-
return e && e.map((t, n) => /* @__PURE__ */
|
|
420
|
+
function Pe(e) {
|
|
421
|
+
return e && e.map((t, n) => /* @__PURE__ */ L.createElement(t.tag, K({
|
|
445
422
|
key: n
|
|
446
|
-
}, t.attr),
|
|
423
|
+
}, t.attr), Pe(t.child)));
|
|
447
424
|
}
|
|
448
|
-
function
|
|
449
|
-
return (t) => /* @__PURE__ */
|
|
450
|
-
attr:
|
|
451
|
-
}, t),
|
|
425
|
+
function Ot(e) {
|
|
426
|
+
return (t) => /* @__PURE__ */ L.createElement(jt, q({
|
|
427
|
+
attr: K({}, e.attr)
|
|
428
|
+
}, t), Pe(e.child));
|
|
452
429
|
}
|
|
453
|
-
function
|
|
430
|
+
function jt(e) {
|
|
454
431
|
var t = (n) => {
|
|
455
432
|
var {
|
|
456
433
|
attr: r,
|
|
457
434
|
size: o,
|
|
458
|
-
title:
|
|
459
|
-
} = e,
|
|
460
|
-
return n.className && (
|
|
435
|
+
title: i
|
|
436
|
+
} = e, a = wt(e, yt), c = o || n.size || "1em", l;
|
|
437
|
+
return n.className && (l = n.className), e.className && (l = (l ? l + " " : "") + e.className), /* @__PURE__ */ L.createElement("svg", q({
|
|
461
438
|
stroke: "currentColor",
|
|
462
439
|
fill: "currentColor",
|
|
463
440
|
strokeWidth: "0"
|
|
464
|
-
}, n.attr, r,
|
|
465
|
-
className:
|
|
466
|
-
style:
|
|
441
|
+
}, n.attr, r, a, {
|
|
442
|
+
className: l,
|
|
443
|
+
style: K(K({
|
|
467
444
|
color: e.color || n.color
|
|
468
445
|
}, n.style), e.style),
|
|
469
|
-
height:
|
|
470
|
-
width:
|
|
446
|
+
height: c,
|
|
447
|
+
width: c,
|
|
471
448
|
xmlns: "http://www.w3.org/2000/svg"
|
|
472
|
-
}),
|
|
449
|
+
}), i && /* @__PURE__ */ L.createElement("title", null, i), e.children);
|
|
473
450
|
};
|
|
474
|
-
return
|
|
451
|
+
return xe !== void 0 ? /* @__PURE__ */ L.createElement(xe.Consumer, null, (n) => t(n)) : t(Re);
|
|
475
452
|
}
|
|
476
|
-
function
|
|
477
|
-
return
|
|
453
|
+
function Le(e) {
|
|
454
|
+
return Ot({ attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M12 22c5.421 0 10-4.579 10-10h-2c0 4.337-3.663 8-8 8s-8-3.663-8-8c0-4.336 3.663-8 8-8V2C6.579 2 2 6.58 2 12c0 5.421 4.579 10 10 10z" }, child: [] }] })(e);
|
|
478
455
|
}
|
|
479
|
-
const
|
|
456
|
+
const C = (...e) => Se(nt(e)), Nt = st(
|
|
480
457
|
"inline-flex items-center justify-center text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 disabled:cursor-not-allowed",
|
|
481
458
|
{
|
|
482
459
|
variants: {
|
|
@@ -511,83 +488,83 @@ const R = (...e) => De(lt(e)), Dt = gt(
|
|
|
511
488
|
rounded: "default"
|
|
512
489
|
}
|
|
513
490
|
}
|
|
514
|
-
),
|
|
491
|
+
), kt = A.forwardRef(
|
|
515
492
|
({
|
|
516
493
|
className: e,
|
|
517
494
|
variant: t,
|
|
518
495
|
size: n,
|
|
519
496
|
rounded: r,
|
|
520
497
|
asChild: o = !1,
|
|
521
|
-
isLoading:
|
|
522
|
-
loadingText:
|
|
523
|
-
disabled:
|
|
524
|
-
...
|
|
525
|
-
},
|
|
526
|
-
const
|
|
527
|
-
return /* @__PURE__ */
|
|
528
|
-
|
|
498
|
+
isLoading: i = !1,
|
|
499
|
+
loadingText: a,
|
|
500
|
+
disabled: c,
|
|
501
|
+
...l
|
|
502
|
+
}, g) => {
|
|
503
|
+
const m = o ? ot.Root : "button";
|
|
504
|
+
return /* @__PURE__ */ d.jsx(
|
|
505
|
+
m,
|
|
529
506
|
{
|
|
530
|
-
className:
|
|
531
|
-
ref:
|
|
532
|
-
disabled:
|
|
507
|
+
className: C(Nt({ variant: t, size: n, rounded: r, className: e })),
|
|
508
|
+
ref: g,
|
|
509
|
+
disabled: c || i,
|
|
533
510
|
type: "button",
|
|
534
|
-
...
|
|
535
|
-
children:
|
|
536
|
-
/* @__PURE__ */
|
|
537
|
-
|
|
511
|
+
...l,
|
|
512
|
+
children: i ? /* @__PURE__ */ d.jsxs(d.Fragment, { children: [
|
|
513
|
+
/* @__PURE__ */ d.jsx(
|
|
514
|
+
Le,
|
|
538
515
|
{
|
|
539
|
-
className:
|
|
516
|
+
className: Se(
|
|
540
517
|
"h-4 w-4 animate-spin",
|
|
541
|
-
|
|
518
|
+
a ? "mr-2" : ""
|
|
542
519
|
)
|
|
543
520
|
}
|
|
544
521
|
),
|
|
545
|
-
|
|
546
|
-
] }) :
|
|
522
|
+
a
|
|
523
|
+
] }) : l.children
|
|
547
524
|
}
|
|
548
525
|
);
|
|
549
526
|
}
|
|
550
527
|
);
|
|
551
|
-
|
|
552
|
-
const
|
|
553
|
-
|
|
528
|
+
kt.displayName = "Button";
|
|
529
|
+
const St = N.Root, ur = N.Trigger, Ct = N.Portal, dr = N.Close, Ae = A.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ d.jsx(
|
|
530
|
+
N.Overlay,
|
|
554
531
|
{
|
|
555
532
|
ref: n,
|
|
556
|
-
className:
|
|
533
|
+
className: C(
|
|
557
534
|
"bg-background/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 grid max-h-screen place-items-center overflow-y-auto py-10 backdrop-blur-sm",
|
|
558
535
|
e
|
|
559
536
|
),
|
|
560
537
|
...t
|
|
561
538
|
}
|
|
562
539
|
));
|
|
563
|
-
|
|
564
|
-
const
|
|
540
|
+
Ae.displayName = N.Overlay.displayName;
|
|
541
|
+
const Ie = A.forwardRef(
|
|
565
542
|
({
|
|
566
543
|
className: e,
|
|
567
544
|
children: t,
|
|
568
545
|
container: n,
|
|
569
546
|
hideCloseButton: r,
|
|
570
547
|
overlayStyles: o,
|
|
571
|
-
...
|
|
572
|
-
},
|
|
573
|
-
|
|
548
|
+
...i
|
|
549
|
+
}, a) => /* @__PURE__ */ d.jsx(Ct, { container: n, children: /* @__PURE__ */ d.jsx(Ae, { className: o, children: /* @__PURE__ */ d.jsxs(
|
|
550
|
+
N.Content,
|
|
574
551
|
{
|
|
575
|
-
ref:
|
|
576
|
-
className:
|
|
552
|
+
ref: a,
|
|
553
|
+
className: C(
|
|
577
554
|
"bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 relative z-50 grid w-full max-w-lg gap-4 border p-6 shadow-lg duration-200 sm:rounded-lg",
|
|
578
555
|
e
|
|
579
556
|
),
|
|
580
|
-
...
|
|
557
|
+
...i,
|
|
581
558
|
children: [
|
|
582
559
|
t,
|
|
583
|
-
!r && /* @__PURE__ */
|
|
584
|
-
|
|
560
|
+
!r && /* @__PURE__ */ d.jsxs(
|
|
561
|
+
N.Close,
|
|
585
562
|
{
|
|
586
563
|
type: "button",
|
|
587
564
|
className: "ring-offset-background focus:ring-ring data-[state=open]:bg-accent data-[state=open]:text-muted-foreground absolute top-4 right-4 rounded-sm p-1 opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-none disabled:pointer-events-none",
|
|
588
565
|
children: [
|
|
589
|
-
/* @__PURE__ */
|
|
590
|
-
/* @__PURE__ */
|
|
566
|
+
/* @__PURE__ */ d.jsx(it, { className: "h-4 w-4" }),
|
|
567
|
+
/* @__PURE__ */ d.jsx("span", { className: "sr-only", children: "Close" })
|
|
591
568
|
]
|
|
592
569
|
}
|
|
593
570
|
)
|
|
@@ -595,72 +572,72 @@ const Ue = D.forwardRef(
|
|
|
595
572
|
}
|
|
596
573
|
) }) })
|
|
597
574
|
);
|
|
598
|
-
|
|
599
|
-
const
|
|
575
|
+
Ie.displayName = N.Content.displayName;
|
|
576
|
+
const De = ({
|
|
600
577
|
className: e,
|
|
601
578
|
...t
|
|
602
|
-
}) => /* @__PURE__ */
|
|
579
|
+
}) => /* @__PURE__ */ d.jsx(
|
|
603
580
|
"div",
|
|
604
581
|
{
|
|
605
|
-
className:
|
|
582
|
+
className: C(
|
|
606
583
|
"flex flex-col space-y-1.5 text-center sm:text-left",
|
|
607
584
|
e
|
|
608
585
|
),
|
|
609
586
|
...t
|
|
610
587
|
}
|
|
611
588
|
);
|
|
612
|
-
|
|
613
|
-
const
|
|
589
|
+
De.displayName = "DialogHeader";
|
|
590
|
+
const Rt = ({
|
|
614
591
|
className: e,
|
|
615
592
|
...t
|
|
616
|
-
}) => /* @__PURE__ */
|
|
593
|
+
}) => /* @__PURE__ */ d.jsx(
|
|
617
594
|
"div",
|
|
618
595
|
{
|
|
619
|
-
className:
|
|
596
|
+
className: C(
|
|
620
597
|
"flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",
|
|
621
598
|
e
|
|
622
599
|
),
|
|
623
600
|
...t
|
|
624
601
|
}
|
|
625
602
|
);
|
|
626
|
-
|
|
627
|
-
const
|
|
628
|
-
|
|
603
|
+
Rt.displayName = "DialogFooter";
|
|
604
|
+
const $e = A.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ d.jsx(
|
|
605
|
+
N.Title,
|
|
629
606
|
{
|
|
630
607
|
ref: n,
|
|
631
|
-
className:
|
|
608
|
+
className: C(
|
|
632
609
|
"text-lg leading-none font-semibold tracking-tight",
|
|
633
610
|
e
|
|
634
611
|
),
|
|
635
612
|
...t
|
|
636
613
|
}
|
|
637
614
|
));
|
|
638
|
-
|
|
639
|
-
const
|
|
640
|
-
|
|
615
|
+
$e.displayName = N.Title.displayName;
|
|
616
|
+
const Me = A.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ d.jsx(
|
|
617
|
+
N.Description,
|
|
641
618
|
{
|
|
642
619
|
ref: n,
|
|
643
|
-
className:
|
|
620
|
+
className: C("text-muted-foreground text-sm", e),
|
|
644
621
|
...t
|
|
645
622
|
}
|
|
646
623
|
));
|
|
647
|
-
|
|
648
|
-
const
|
|
624
|
+
Me.displayName = N.Description.displayName;
|
|
625
|
+
const fr = ({
|
|
649
626
|
isOpen: e,
|
|
650
627
|
onClose: t,
|
|
651
628
|
children: n,
|
|
652
629
|
title: r,
|
|
653
630
|
description: o = "",
|
|
654
|
-
contentClassName:
|
|
655
|
-
modal:
|
|
656
|
-
}) => /* @__PURE__ */
|
|
657
|
-
r && /* @__PURE__ */
|
|
658
|
-
/* @__PURE__ */
|
|
659
|
-
/* @__PURE__ */
|
|
631
|
+
contentClassName: i,
|
|
632
|
+
modal: a = !0
|
|
633
|
+
}) => /* @__PURE__ */ d.jsx(St, { open: e, onOpenChange: t, modal: a, children: /* @__PURE__ */ d.jsxs(Ie, { className: i, children: [
|
|
634
|
+
r && /* @__PURE__ */ d.jsxs(De, { className: "flex-1 font-medium", children: [
|
|
635
|
+
/* @__PURE__ */ d.jsx($e, { children: r }),
|
|
636
|
+
/* @__PURE__ */ d.jsx(Me, { children: o })
|
|
660
637
|
] }),
|
|
661
|
-
/* @__PURE__ */
|
|
662
|
-
] }) }),
|
|
663
|
-
|
|
638
|
+
/* @__PURE__ */ d.jsx("div", { className: "w-full", children: n })
|
|
639
|
+
] }) }), mr = ({ ...e }) => /* @__PURE__ */ d.jsx(
|
|
640
|
+
at,
|
|
664
641
|
{
|
|
665
642
|
closeButton: !0,
|
|
666
643
|
richColors: !0,
|
|
@@ -675,37 +652,37 @@ const kr = ({
|
|
|
675
652
|
},
|
|
676
653
|
...e
|
|
677
654
|
}
|
|
678
|
-
),
|
|
679
|
-
|
|
655
|
+
), Pt = (e, t = "Error", n = {}) => {
|
|
656
|
+
ce.error(t, {
|
|
680
657
|
description: e,
|
|
681
658
|
duration: 4e3,
|
|
682
659
|
position: "bottom-right",
|
|
683
660
|
...n
|
|
684
661
|
});
|
|
685
|
-
},
|
|
686
|
-
n
|
|
662
|
+
}, gr = (e, t = "Success", n = {}) => {
|
|
663
|
+
n?.id && ce.dismiss(n?.id), ce.success(t, {
|
|
687
664
|
description: e,
|
|
688
665
|
duration: 4e3,
|
|
689
666
|
position: "bottom-right",
|
|
690
667
|
...n
|
|
691
668
|
});
|
|
692
|
-
},
|
|
693
|
-
|
|
669
|
+
}, Lt = ({ className: e }) => /* @__PURE__ */ d.jsx(Le, { className: C("h-8 w-8 animate-spin font-light", e) }), pr = $.Root, At = A.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ d.jsx(
|
|
670
|
+
$.List,
|
|
694
671
|
{
|
|
695
672
|
ref: n,
|
|
696
|
-
className:
|
|
673
|
+
className: C(
|
|
697
674
|
"bg-muted text-muted-foreground inline-flex h-10 items-center justify-center rounded-md p-1",
|
|
698
675
|
e
|
|
699
676
|
),
|
|
700
677
|
...t
|
|
701
678
|
}
|
|
702
679
|
));
|
|
703
|
-
|
|
704
|
-
const
|
|
705
|
-
|
|
680
|
+
At.displayName = $.List.displayName;
|
|
681
|
+
const It = A.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ d.jsx(
|
|
682
|
+
$.Trigger,
|
|
706
683
|
{
|
|
707
684
|
ref: n,
|
|
708
|
-
className:
|
|
685
|
+
className: C(
|
|
709
686
|
"ring-offset-background focus-visible:ring-ring data-[state=active]:bg-background data-[state=active]:text-foreground inline-flex items-center justify-center rounded-sm px-3 py-1.5 text-sm font-medium whitespace-nowrap transition-all focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-none disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm",
|
|
710
687
|
e
|
|
711
688
|
),
|
|
@@ -713,247 +690,247 @@ const zt = D.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ p.jsx(
|
|
|
713
690
|
...t
|
|
714
691
|
}
|
|
715
692
|
));
|
|
716
|
-
|
|
717
|
-
const
|
|
718
|
-
|
|
693
|
+
It.displayName = $.Trigger.displayName;
|
|
694
|
+
const Dt = A.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ d.jsx(
|
|
695
|
+
$.Content,
|
|
719
696
|
{
|
|
720
697
|
ref: n,
|
|
721
|
-
className:
|
|
698
|
+
className: C(
|
|
722
699
|
"ring-offset-background focus-visible:ring-ring mt-2 focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-none",
|
|
723
700
|
e
|
|
724
701
|
),
|
|
725
702
|
...t
|
|
726
703
|
}
|
|
727
704
|
));
|
|
728
|
-
|
|
729
|
-
const
|
|
730
|
-
|
|
705
|
+
Dt.displayName = $.Content.displayName;
|
|
706
|
+
const br = F.Provider, $t = F.Root, Mt = F.Trigger, Bt = F.Portal, Be = A.forwardRef(({ className: e, sideOffset: t = 4, ...n }, r) => /* @__PURE__ */ d.jsx(
|
|
707
|
+
F.Content,
|
|
731
708
|
{
|
|
732
709
|
ref: r,
|
|
733
710
|
sideOffset: t,
|
|
734
|
-
className:
|
|
711
|
+
className: C(
|
|
735
712
|
"bg-popover text-popover-foreground animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 overflow-hidden rounded-md border px-3 py-1.5 text-xs shadow-md",
|
|
736
713
|
e
|
|
737
714
|
),
|
|
738
715
|
...n
|
|
739
716
|
}
|
|
740
717
|
));
|
|
741
|
-
|
|
742
|
-
const
|
|
718
|
+
Be.displayName = F.Content.displayName;
|
|
719
|
+
const hr = ({
|
|
743
720
|
children: e,
|
|
744
721
|
label: t,
|
|
745
722
|
labelClassName: n,
|
|
746
723
|
asChild: r = !0,
|
|
747
724
|
contentProps: o = {},
|
|
748
|
-
side:
|
|
749
|
-
}) => /* @__PURE__ */
|
|
750
|
-
t && /* @__PURE__ */
|
|
751
|
-
|
|
725
|
+
side: i
|
|
726
|
+
}) => /* @__PURE__ */ d.jsxs($t, { children: [
|
|
727
|
+
t && /* @__PURE__ */ d.jsx(Bt, { children: /* @__PURE__ */ d.jsx(
|
|
728
|
+
Be,
|
|
752
729
|
{
|
|
753
|
-
side:
|
|
730
|
+
side: i,
|
|
754
731
|
className: n,
|
|
755
732
|
...o,
|
|
756
733
|
children: t
|
|
757
734
|
}
|
|
758
735
|
) }),
|
|
759
|
-
/* @__PURE__ */
|
|
760
|
-
] }),
|
|
736
|
+
/* @__PURE__ */ d.jsx(Mt, { asChild: r, children: e })
|
|
737
|
+
] }), vr = (e, t = 2) => {
|
|
761
738
|
if (e === 0) return "0 B";
|
|
762
|
-
const n = 1024, r = t < 0 ? 0 : t, o = ["Bytes", "KB", "MB", "GB", "TB", "PB", "EB", "ZB", "YB"],
|
|
763
|
-
return `${Number.parseFloat((e / n **
|
|
764
|
-
},
|
|
765
|
-
const t =
|
|
766
|
-
return
|
|
767
|
-
id: `${
|
|
739
|
+
const n = 1024, r = t < 0 ? 0 : t, o = ["Bytes", "KB", "MB", "GB", "TB", "PB", "EB", "ZB", "YB"], i = Math.floor(Math.log(e) / Math.log(n));
|
|
740
|
+
return `${Number.parseFloat((e / n ** i).toFixed(r))} ${o[i]}`;
|
|
741
|
+
}, yr = (e) => {
|
|
742
|
+
const t = Ce(e);
|
|
743
|
+
return Pt(t?.message || "", t?.title || "Error", {
|
|
744
|
+
id: `${t?.title || ""}-${t?.message || ""}`
|
|
768
745
|
}), t;
|
|
769
|
-
},
|
|
770
|
-
const e =
|
|
746
|
+
}, Wt = (e) => e instanceof Date, Ft = (e) => e == null, Ut = (e) => typeof e == "object", Yt = (e) => !Ft(e) && !Array.isArray(e) && Ut(e) && !Wt(e), wr = (e) => Yt(e) && !Object.keys(e).length, We = tt(null), xr = ({ children: e, client: t }) => /* @__PURE__ */ d.jsx(We.Provider, { value: t, children: e }), R = () => {
|
|
747
|
+
const e = je(We);
|
|
771
748
|
if (!e)
|
|
772
749
|
throw new Error(
|
|
773
750
|
"useLevo must be used within a LevoProvider. Please ensure you have wrapped your component tree with LevoProvider."
|
|
774
751
|
);
|
|
775
752
|
return e;
|
|
776
|
-
},
|
|
777
|
-
const { audience: n } =
|
|
778
|
-
return
|
|
779
|
-
if (r || typeof
|
|
780
|
-
const
|
|
781
|
-
if (!
|
|
782
|
-
const
|
|
783
|
-
r || (n
|
|
753
|
+
}, Er = ({ id: e, properties: t = {} }) => {
|
|
754
|
+
const { audience: n } = R(), [r, o] = O(!1);
|
|
755
|
+
return x(() => {
|
|
756
|
+
if (r || typeof n?.track != "function") return;
|
|
757
|
+
const i = document.getElementById(e);
|
|
758
|
+
if (!i) return;
|
|
759
|
+
const a = () => {
|
|
760
|
+
r || (n?.track("block.view", {
|
|
784
761
|
...t,
|
|
785
762
|
resource: "block",
|
|
786
763
|
identifier: e
|
|
787
764
|
}), o(!0));
|
|
788
765
|
};
|
|
789
|
-
if (((
|
|
790
|
-
const
|
|
791
|
-
return
|
|
792
|
-
})(
|
|
793
|
-
|
|
766
|
+
if (((g) => {
|
|
767
|
+
const m = g.getBoundingClientRect();
|
|
768
|
+
return m.top >= 0 && m.left >= 0 && m.bottom <= (window.innerHeight || document.documentElement.clientHeight) && m.right <= (window.innerWidth || document.documentElement.clientWidth);
|
|
769
|
+
})(i)) {
|
|
770
|
+
a();
|
|
794
771
|
return;
|
|
795
772
|
}
|
|
796
|
-
const
|
|
797
|
-
(
|
|
798
|
-
|
|
799
|
-
|
|
773
|
+
const l = new IntersectionObserver(
|
|
774
|
+
(g) => {
|
|
775
|
+
g.forEach((m) => {
|
|
776
|
+
m.isIntersecting && (a(), l.disconnect());
|
|
800
777
|
});
|
|
801
778
|
},
|
|
802
779
|
{ threshold: 0 }
|
|
803
780
|
);
|
|
804
|
-
return
|
|
805
|
-
|
|
781
|
+
return l.observe(i), () => {
|
|
782
|
+
l.disconnect();
|
|
806
783
|
};
|
|
807
784
|
}, [n, e, t, r]), null;
|
|
808
|
-
},
|
|
809
|
-
const { audience: n } =
|
|
810
|
-
return
|
|
811
|
-
n
|
|
812
|
-
}, [n
|
|
785
|
+
}, Tr = ({ event: e, properties: t }) => {
|
|
786
|
+
const { audience: n } = R();
|
|
787
|
+
return x(() => {
|
|
788
|
+
n?.instance && n?.track(e, t);
|
|
789
|
+
}, [n?.instance, e, t]), null;
|
|
813
790
|
};
|
|
814
|
-
function
|
|
791
|
+
function le(e) {
|
|
815
792
|
var t = typeof e;
|
|
816
793
|
return e != null && (t == "object" || t == "function");
|
|
817
794
|
}
|
|
818
|
-
var
|
|
819
|
-
return
|
|
820
|
-
},
|
|
821
|
-
function
|
|
822
|
-
for (var t = e.length; t-- &&
|
|
795
|
+
var zt = typeof global == "object" && global && global.Object === Object && global, Ht = typeof self == "object" && self && self.Object === Object && self, Fe = zt || Ht || Function("return this")(), ie = function() {
|
|
796
|
+
return Fe.Date.now();
|
|
797
|
+
}, Vt = /\s/;
|
|
798
|
+
function Gt(e) {
|
|
799
|
+
for (var t = e.length; t-- && Vt.test(e.charAt(t)); )
|
|
823
800
|
;
|
|
824
801
|
return t;
|
|
825
802
|
}
|
|
826
|
-
var
|
|
827
|
-
function
|
|
828
|
-
return e && e.slice(0,
|
|
803
|
+
var Jt = /^\s+/;
|
|
804
|
+
function Xt(e) {
|
|
805
|
+
return e && e.slice(0, Gt(e) + 1).replace(Jt, "");
|
|
829
806
|
}
|
|
830
|
-
var
|
|
831
|
-
function
|
|
832
|
-
var t =
|
|
807
|
+
var Z = Fe.Symbol, Ue = Object.prototype, qt = Ue.hasOwnProperty, Kt = Ue.toString, H = Z ? Z.toStringTag : void 0;
|
|
808
|
+
function Zt(e) {
|
|
809
|
+
var t = qt.call(e, H), n = e[H];
|
|
833
810
|
try {
|
|
834
|
-
e[
|
|
811
|
+
e[H] = void 0;
|
|
835
812
|
var r = !0;
|
|
836
813
|
} catch {
|
|
837
814
|
}
|
|
838
|
-
var o =
|
|
839
|
-
return r && (t ? e[
|
|
815
|
+
var o = Kt.call(e);
|
|
816
|
+
return r && (t ? e[H] = n : delete e[H]), o;
|
|
840
817
|
}
|
|
841
|
-
var
|
|
842
|
-
function
|
|
843
|
-
return
|
|
818
|
+
var Qt = Object.prototype, en = Qt.toString;
|
|
819
|
+
function tn(e) {
|
|
820
|
+
return en.call(e);
|
|
844
821
|
}
|
|
845
|
-
var
|
|
846
|
-
function
|
|
847
|
-
return e == null ? e === void 0 ?
|
|
822
|
+
var nn = "[object Null]", rn = "[object Undefined]", Te = Z ? Z.toStringTag : void 0;
|
|
823
|
+
function on(e) {
|
|
824
|
+
return e == null ? e === void 0 ? rn : nn : Te && Te in Object(e) ? Zt(e) : tn(e);
|
|
848
825
|
}
|
|
849
|
-
function
|
|
826
|
+
function sn(e) {
|
|
850
827
|
return e != null && typeof e == "object";
|
|
851
828
|
}
|
|
852
|
-
var
|
|
853
|
-
function
|
|
854
|
-
return typeof e == "symbol" ||
|
|
829
|
+
var an = "[object Symbol]";
|
|
830
|
+
function cn(e) {
|
|
831
|
+
return typeof e == "symbol" || sn(e) && on(e) == an;
|
|
855
832
|
}
|
|
856
|
-
var
|
|
857
|
-
function
|
|
833
|
+
var _e = NaN, ln = /^[-+]0x[0-9a-f]+$/i, un = /^0b[01]+$/i, dn = /^0o[0-7]+$/i, fn = parseInt;
|
|
834
|
+
function Oe(e) {
|
|
858
835
|
if (typeof e == "number")
|
|
859
836
|
return e;
|
|
860
|
-
if (
|
|
861
|
-
return
|
|
862
|
-
if (
|
|
837
|
+
if (cn(e))
|
|
838
|
+
return _e;
|
|
839
|
+
if (le(e)) {
|
|
863
840
|
var t = typeof e.valueOf == "function" ? e.valueOf() : e;
|
|
864
|
-
e =
|
|
841
|
+
e = le(t) ? t + "" : t;
|
|
865
842
|
}
|
|
866
843
|
if (typeof e != "string")
|
|
867
844
|
return e === 0 ? e : +e;
|
|
868
|
-
e =
|
|
869
|
-
var n =
|
|
870
|
-
return n ||
|
|
845
|
+
e = Xt(e);
|
|
846
|
+
var n = un.test(e);
|
|
847
|
+
return n || dn.test(e) ? fn(e.slice(2), n ? 2 : 8) : ln.test(e) ? _e : +e;
|
|
871
848
|
}
|
|
872
|
-
var
|
|
873
|
-
function
|
|
874
|
-
var r, o,
|
|
849
|
+
var mn = "Expected a function", gn = Math.max, pn = Math.min;
|
|
850
|
+
function bn(e, t, n) {
|
|
851
|
+
var r, o, i, a, c, l, g = 0, m = !1, f = !1, E = !0;
|
|
875
852
|
if (typeof e != "function")
|
|
876
|
-
throw new TypeError(
|
|
877
|
-
t =
|
|
878
|
-
function v(
|
|
879
|
-
var P = r,
|
|
880
|
-
return r = o = void 0,
|
|
881
|
-
}
|
|
882
|
-
function _(w) {
|
|
883
|
-
return l = w, a = setTimeout(C, t), f ? v(w) : c;
|
|
853
|
+
throw new TypeError(mn);
|
|
854
|
+
t = Oe(t) || 0, le(n) && (m = !!n.leading, f = "maxWait" in n, i = f ? gn(Oe(n.maxWait) || 0, t) : i, E = "trailing" in n ? !!n.trailing : E);
|
|
855
|
+
function v(b) {
|
|
856
|
+
var P = r, I = o;
|
|
857
|
+
return r = o = void 0, g = b, a = e.apply(I, P), a;
|
|
884
858
|
}
|
|
885
|
-
function
|
|
886
|
-
|
|
887
|
-
return d ? kn(G, s - $) : G;
|
|
859
|
+
function _(b) {
|
|
860
|
+
return g = b, c = setTimeout(S, t), m ? v(b) : a;
|
|
888
861
|
}
|
|
889
|
-
function
|
|
890
|
-
var P =
|
|
891
|
-
return
|
|
862
|
+
function k(b) {
|
|
863
|
+
var P = b - l, I = b - g, B = t - P;
|
|
864
|
+
return f ? pn(B, i - I) : B;
|
|
892
865
|
}
|
|
893
|
-
function
|
|
894
|
-
var
|
|
895
|
-
|
|
896
|
-
return T(w);
|
|
897
|
-
a = setTimeout(C, S(w));
|
|
866
|
+
function j(b) {
|
|
867
|
+
var P = b - l, I = b - g;
|
|
868
|
+
return l === void 0 || P >= t || P < 0 || f && I >= i;
|
|
898
869
|
}
|
|
899
|
-
function
|
|
900
|
-
|
|
870
|
+
function S() {
|
|
871
|
+
var b = ie();
|
|
872
|
+
if (j(b))
|
|
873
|
+
return h(b);
|
|
874
|
+
c = setTimeout(S, k(b));
|
|
901
875
|
}
|
|
902
|
-
function
|
|
903
|
-
|
|
876
|
+
function h(b) {
|
|
877
|
+
return c = void 0, E && r ? v(b) : (r = o = void 0, a);
|
|
904
878
|
}
|
|
905
|
-
function
|
|
906
|
-
|
|
879
|
+
function T() {
|
|
880
|
+
c !== void 0 && clearTimeout(c), g = 0, r = l = o = c = void 0;
|
|
907
881
|
}
|
|
908
882
|
function M() {
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
883
|
+
return c === void 0 ? a : h(ie());
|
|
884
|
+
}
|
|
885
|
+
function U() {
|
|
886
|
+
var b = ie(), P = j(b);
|
|
887
|
+
if (r = arguments, o = this, l = b, P) {
|
|
888
|
+
if (c === void 0)
|
|
889
|
+
return _(l);
|
|
890
|
+
if (f)
|
|
891
|
+
return clearTimeout(c), c = setTimeout(S, t), v(l);
|
|
915
892
|
}
|
|
916
|
-
return
|
|
893
|
+
return c === void 0 && (c = setTimeout(S, t)), a;
|
|
917
894
|
}
|
|
918
|
-
return
|
|
895
|
+
return U.cancel = T, U.flush = M, U;
|
|
919
896
|
}
|
|
920
|
-
const
|
|
921
|
-
const [e, t] =
|
|
922
|
-
const
|
|
923
|
-
|
|
924
|
-
),
|
|
925
|
-
if (
|
|
897
|
+
const hn = () => {
|
|
898
|
+
const [e, t] = O(0), [n, r] = O(0), [o, i] = O(0), [a, c] = O(Date.now()), [l, g] = O("read"), m = bn(() => {
|
|
899
|
+
const f = window.scrollY, E = document.documentElement.scrollHeight, v = window.innerHeight, _ = Math.round(
|
|
900
|
+
f / (E - v) * 100
|
|
901
|
+
), k = Math.floor(_ / 5) * 5;
|
|
902
|
+
if (k <= n)
|
|
926
903
|
return;
|
|
927
|
-
const
|
|
928
|
-
|
|
904
|
+
const j = Date.now(), S = (j - a) / 1e3, T = Math.abs(f - o) / S;
|
|
905
|
+
g(T > 300 ? "scan" : "read"), i(f), c(j), r(k), t(k);
|
|
929
906
|
}, 250);
|
|
930
|
-
return
|
|
931
|
-
},
|
|
932
|
-
const e =
|
|
933
|
-
return
|
|
907
|
+
return x(() => (window.addEventListener("scroll", m), () => window.removeEventListener("scroll", m)), []), { depth: e, speedCategory: l };
|
|
908
|
+
}, vn = () => {
|
|
909
|
+
const e = R(), [t, n] = O(0);
|
|
910
|
+
return x(() => {
|
|
934
911
|
const r = Number(localStorage.getItem(e.audience.storage_keys.open_tabs)) || 0;
|
|
935
912
|
n(r), localStorage.setItem(
|
|
936
913
|
e.audience.storage_keys.open_tabs,
|
|
937
914
|
(r + 1).toString()
|
|
938
915
|
);
|
|
939
|
-
const o = (
|
|
940
|
-
|
|
916
|
+
const o = (a) => {
|
|
917
|
+
a.key === e.audience.storage_keys.open_tabs && n(Number(a.newValue) || 0);
|
|
941
918
|
};
|
|
942
919
|
window.addEventListener("storage", o);
|
|
943
|
-
const
|
|
944
|
-
const
|
|
945
|
-
|
|
920
|
+
const i = () => {
|
|
921
|
+
const a = Number(localStorage.getItem(e.audience.storage_keys.open_tabs)) || 0;
|
|
922
|
+
a > 0 && localStorage.setItem(
|
|
946
923
|
e.audience.storage_keys.open_tabs,
|
|
947
|
-
(
|
|
924
|
+
(a - 1).toString()
|
|
948
925
|
);
|
|
949
926
|
};
|
|
950
|
-
return window.addEventListener("beforeunload",
|
|
951
|
-
window.removeEventListener("storage", o), window.removeEventListener("beforeunload",
|
|
927
|
+
return window.addEventListener("beforeunload", i), () => {
|
|
928
|
+
window.removeEventListener("storage", o), window.removeEventListener("beforeunload", i);
|
|
952
929
|
};
|
|
953
930
|
}, []), t;
|
|
954
|
-
},
|
|
955
|
-
const e =
|
|
956
|
-
return
|
|
931
|
+
}, yn = () => {
|
|
932
|
+
const e = R(), [t, n] = O(null);
|
|
933
|
+
return x(() => {
|
|
957
934
|
let r = sessionStorage.getItem(
|
|
958
935
|
e.audience.storage_keys.current_tab
|
|
959
936
|
);
|
|
@@ -967,61 +944,58 @@ const Sn = () => {
|
|
|
967
944
|
e.audience.storage_keys.all_tabs,
|
|
968
945
|
JSON.stringify(o)
|
|
969
946
|
)), n(r);
|
|
970
|
-
const
|
|
971
|
-
const
|
|
972
|
-
(
|
|
947
|
+
const i = () => {
|
|
948
|
+
const a = o.filter(
|
|
949
|
+
(c) => c !== r
|
|
973
950
|
);
|
|
974
951
|
localStorage.setItem(
|
|
975
952
|
e.audience.storage_keys.all_tabs,
|
|
976
|
-
JSON.stringify(
|
|
953
|
+
JSON.stringify(a)
|
|
977
954
|
);
|
|
978
955
|
};
|
|
979
|
-
return window.addEventListener("beforeunload",
|
|
980
|
-
window.removeEventListener("beforeunload",
|
|
956
|
+
return window.addEventListener("beforeunload", i), () => {
|
|
957
|
+
window.removeEventListener("beforeunload", i);
|
|
981
958
|
};
|
|
982
959
|
}, []), t;
|
|
983
|
-
},
|
|
984
|
-
function
|
|
985
|
-
return !!e &&
|
|
960
|
+
}, Q = (e) => Object.prototype.toString.call(e) == "[object String]", wn = (e, t) => e.indexOf(t) !== -1, ee = (e) => e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, ""), Ye = (e) => e === void 0, xn = (e) => e === null, ze = (e) => Ye(e) || xn(e), He = (e) => !!e && e?.nodeType === 3;
|
|
961
|
+
function En(e) {
|
|
962
|
+
return !!e && e?.nodeType === 1;
|
|
986
963
|
}
|
|
987
|
-
function
|
|
988
|
-
return !!e && !!
|
|
964
|
+
function Tn(e, t) {
|
|
965
|
+
return !!e && !!e?.tagName && e?.tagName.toLowerCase() === t.toLowerCase();
|
|
989
966
|
}
|
|
990
|
-
function
|
|
991
|
-
return e ?
|
|
967
|
+
function _n(e) {
|
|
968
|
+
return e ? ee(e).split(/\s+/) : [];
|
|
992
969
|
}
|
|
993
|
-
function
|
|
970
|
+
function On(e) {
|
|
994
971
|
let t = "";
|
|
995
|
-
switch (typeof
|
|
972
|
+
switch (typeof e?.className) {
|
|
996
973
|
case "string":
|
|
997
|
-
t = e
|
|
974
|
+
t = e?.className;
|
|
998
975
|
break;
|
|
999
976
|
// TODO: when is this ever used?
|
|
1000
977
|
case "object":
|
|
1001
|
-
t = (e
|
|
978
|
+
t = (e?.className && "baseVal" in e?.className ? (e?.className).baseVal : null) || e?.getAttribute("class") || "";
|
|
1002
979
|
break;
|
|
1003
980
|
default:
|
|
1004
981
|
t = "";
|
|
1005
982
|
}
|
|
1006
|
-
return
|
|
983
|
+
return _n(t);
|
|
1007
984
|
}
|
|
1008
|
-
const
|
|
985
|
+
const D = (e, t = 255) => ze(e) ? "" : ee(e).split(/(\s+)/).filter((n) => de(n)).join("").replace(/[\r\n]/g, " ").replace(/[ ]+/g, " ").substring(0, t), ue = (e) => {
|
|
1009
986
|
let t = "";
|
|
1010
|
-
if (
|
|
1011
|
-
|
|
1012
|
-
for (const n of e
|
|
1013
|
-
|
|
1014
|
-
return
|
|
1015
|
-
},
|
|
1016
|
-
|
|
1017
|
-
return qe(e.target) ? (e == null ? void 0 : e.srcElement) || null : (t = e == null ? void 0 : e.target) != null && t.shadowRoot ? ((n = e == null ? void 0 : e.composedPath()) == null ? void 0 : n[0]) || null : (e == null ? void 0 : e.target) || null;
|
|
1018
|
-
}, Dn = (e, t) => {
|
|
1019
|
-
if (!window || !e || Ln(e, "html") || !Rn(e))
|
|
987
|
+
if (kn(e) && // !isSensitiveElement(el) &&
|
|
988
|
+
e?.childNodes && e?.childNodes.length)
|
|
989
|
+
for (const n of e?.childNodes)
|
|
990
|
+
He(n) && n.textContent && (t += D(n.textContent) ?? "");
|
|
991
|
+
return ee(t);
|
|
992
|
+
}, jn = (e) => Ye(e.target) ? e?.srcElement || null : e?.target?.shadowRoot ? e?.composedPath()?.[0] || null : e?.target || null, Nn = (e, t) => {
|
|
993
|
+
if (!window || !e || Tn(e, "html") || !En(e))
|
|
1020
994
|
return !1;
|
|
1021
995
|
const n = window.getComputedStyle(e);
|
|
1022
996
|
if (n && n.getPropertyValue("cursor") === "pointer" && t.type === "click")
|
|
1023
997
|
return !0;
|
|
1024
|
-
switch (e
|
|
998
|
+
switch (e?.tagName.toLowerCase()) {
|
|
1025
999
|
case "html":
|
|
1026
1000
|
return !1;
|
|
1027
1001
|
case "form":
|
|
@@ -1034,147 +1008,143 @@ const B = (e, t = 255) => Ke(e) ? "" : re(e).split(/(\s+)/).filter((n) => be(n))
|
|
|
1034
1008
|
return t.type === "click";
|
|
1035
1009
|
}
|
|
1036
1010
|
};
|
|
1037
|
-
function
|
|
1038
|
-
if (
|
|
1011
|
+
function kn(e) {
|
|
1012
|
+
if (wn(On(e), "ph-include"))
|
|
1039
1013
|
return !0;
|
|
1040
1014
|
const t = e.type || "";
|
|
1041
|
-
if (
|
|
1015
|
+
if (Q(t))
|
|
1042
1016
|
switch (t.toLowerCase()) {
|
|
1043
1017
|
case "hidden":
|
|
1044
1018
|
return !1;
|
|
1045
1019
|
case "password":
|
|
1046
1020
|
return !1;
|
|
1047
1021
|
}
|
|
1048
|
-
const n = e.name ||
|
|
1049
|
-
return !(
|
|
1022
|
+
const n = e.name || e?.id || "";
|
|
1023
|
+
return !(Q(n) && /^cc|cardnum|ccnum|creditcard|csc|cvc|cvv|exp|pass|pwd|routing|seccode|securitycode|securitynum|socialsec|socsec|ssn/i.test(n.replace(/[^a-zA-Z0-9]/g, "")));
|
|
1050
1024
|
}
|
|
1051
|
-
const
|
|
1052
|
-
let t =
|
|
1053
|
-
return t = `${t} ${
|
|
1025
|
+
const Ve = "(4[0-9]{12}(?:[0-9]{3})?)|(5[1-5][0-9]{14})|(6(?:011|5[0-9]{2})[0-9]{12})|(3[47][0-9]{13})|(3(?:0[0-5]|[68][0-9])[0-9]{11})|((?:2131|1800|35[0-9]{3})[0-9]{11})", Sn = new RegExp(`^(?:${Ve})$`), Cn = new RegExp(Ve), Ge = "\\d{3}-?\\d{2}-?\\d{4}", Rn = new RegExp(`^(${Ge})$`), Pn = new RegExp(`(${Ge})`), de = (e, t = !0) => !(ze(e) || Q(e) && (e = ee(e), (t ? Sn : Cn).test((e || "").replace(/[- ]/g, "")) || (t ? Rn : Pn).test(e))), Ln = (e) => Q(e) ? e.substring(0, 10) === "_ngcontent" || e.substring(0, 7) === "_nghost" : !1, An = (e) => {
|
|
1026
|
+
let t = ue(e);
|
|
1027
|
+
return t = `${t} ${Je(e)}`.trim(), de(t) ? t : "";
|
|
1054
1028
|
};
|
|
1055
|
-
function
|
|
1056
|
-
var n;
|
|
1029
|
+
function Je(e) {
|
|
1057
1030
|
let t = "";
|
|
1058
|
-
if (e
|
|
1059
|
-
for (const
|
|
1060
|
-
if (
|
|
1031
|
+
if (e?.childNodes.length) {
|
|
1032
|
+
for (const n of e.childNodes)
|
|
1033
|
+
if (n && n.tagName?.toLowerCase() === "span")
|
|
1061
1034
|
try {
|
|
1062
|
-
const
|
|
1063
|
-
t = `${t} ${
|
|
1035
|
+
const r = ue(n);
|
|
1036
|
+
t = `${t} ${r}`.trim(), n?.childNodes.length && (t = `${t} ${Je(n)}`.trim());
|
|
1064
1037
|
} catch {
|
|
1065
1038
|
}
|
|
1066
1039
|
}
|
|
1067
1040
|
return t;
|
|
1068
1041
|
}
|
|
1069
|
-
const
|
|
1070
|
-
|
|
1071
|
-
const t = (o = e == null ? void 0 : e.tagName) == null ? void 0 : o.toLowerCase(), n = {
|
|
1042
|
+
const In = ["input", "textarea", "select"], Xe = (e) => {
|
|
1043
|
+
const t = e?.tagName?.toLowerCase(), n = {
|
|
1072
1044
|
element: t
|
|
1073
1045
|
};
|
|
1074
|
-
|
|
1046
|
+
t?.toLowerCase() === "a" || t?.toLowerCase() === "button" ? n.text = An(e) : n.text = ue(e);
|
|
1075
1047
|
const r = Array.from(e.attributes).reduce(
|
|
1076
|
-
(
|
|
1077
|
-
if (
|
|
1078
|
-
if (
|
|
1079
|
-
return
|
|
1080
|
-
|
|
1048
|
+
(o, i) => {
|
|
1049
|
+
if (de(i.value) && !Ln(i.name)) {
|
|
1050
|
+
if (i.name === "class")
|
|
1051
|
+
return o;
|
|
1052
|
+
o[i.name] = typeof i?.value == "string" ? D(i.value) : i.value;
|
|
1081
1053
|
}
|
|
1082
|
-
return
|
|
1054
|
+
return o;
|
|
1083
1055
|
},
|
|
1084
1056
|
{}
|
|
1085
1057
|
);
|
|
1086
|
-
if (n.attributes = r,
|
|
1087
|
-
let
|
|
1088
|
-
e.matches('input[type="checkbox"], input[type="radio"]') ?
|
|
1089
|
-
let
|
|
1090
|
-
n
|
|
1091
|
-
|
|
1058
|
+
if (n.attributes = r, In.includes(t) || e?.getAttribute("contenteditable") === "true") {
|
|
1059
|
+
let o;
|
|
1060
|
+
e.matches('input[type="checkbox"], input[type="radio"]') ? o = e.checked : e.matches("input, select, textarea") && !e.matches('input[type="password"]') && (o = e.value), o !== void 0 && (n.value = typeof o == "string" || o === null ? D(o, 1024) : o);
|
|
1061
|
+
let i = "";
|
|
1062
|
+
n?.attributes.id && (i = D(
|
|
1063
|
+
document.querySelector(`label[for="${n?.attributes.id}"]`)?.textContent?.trim() || ""
|
|
1092
1064
|
));
|
|
1093
|
-
const
|
|
1094
|
-
|
|
1065
|
+
const a = e.closest("label");
|
|
1066
|
+
i || (i = D(a?.textContent?.trim() || "")), i && (n.label = i);
|
|
1095
1067
|
}
|
|
1096
1068
|
return n;
|
|
1097
|
-
},
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
Ze(n) && (n = n.parentNode || null);
|
|
1069
|
+
}, Dn = (e, t) => {
|
|
1070
|
+
let n = jn(e);
|
|
1071
|
+
He(n) && (n = n.parentNode || null);
|
|
1101
1072
|
const r = ["copy", "cut"].includes(t);
|
|
1102
|
-
if (n && (r ||
|
|
1103
|
-
const
|
|
1073
|
+
if (n && (r || Nn(n, e))) {
|
|
1074
|
+
const o = Xe(n);
|
|
1104
1075
|
if (r) {
|
|
1105
|
-
const
|
|
1106
|
-
|
|
1076
|
+
const i = D(window?.getSelection()?.toString()), a = e?.type || "clipboard";
|
|
1077
|
+
o.copy_text = i ?? "", o.copy_type = a;
|
|
1107
1078
|
}
|
|
1108
|
-
return
|
|
1079
|
+
return o;
|
|
1109
1080
|
}
|
|
1110
1081
|
return null;
|
|
1111
|
-
},
|
|
1112
|
-
class
|
|
1082
|
+
}, $n = 30, Mn = 1e3, Bn = 3;
|
|
1083
|
+
class Wn {
|
|
1084
|
+
clicks;
|
|
1113
1085
|
constructor() {
|
|
1114
|
-
J(this, "clicks");
|
|
1115
1086
|
this.clicks = [];
|
|
1116
1087
|
}
|
|
1117
1088
|
isRageClick(t, n, r) {
|
|
1118
1089
|
const o = this.clicks[this.clicks.length - 1];
|
|
1119
|
-
if (o && Math.abs(t - o.x) + Math.abs(n - o.y) <
|
|
1120
|
-
if (this.clicks.push({ x: t, y: n, timestamp: r }), this.clicks.length ===
|
|
1090
|
+
if (o && Math.abs(t - o.x) + Math.abs(n - o.y) < $n && r - o.timestamp < Mn) {
|
|
1091
|
+
if (this.clicks.push({ x: t, y: n, timestamp: r }), this.clicks.length === Bn)
|
|
1121
1092
|
return !0;
|
|
1122
1093
|
} else
|
|
1123
1094
|
this.clicks = [{ x: t, y: n, timestamp: r }];
|
|
1124
1095
|
return !1;
|
|
1125
1096
|
}
|
|
1126
1097
|
}
|
|
1127
|
-
const
|
|
1128
|
-
const { audience: e } =
|
|
1129
|
-
|
|
1098
|
+
const Fn = new Wn(), Un = () => {
|
|
1099
|
+
const { audience: e } = R();
|
|
1100
|
+
x(() => {
|
|
1130
1101
|
let t = null;
|
|
1131
|
-
const n = (
|
|
1102
|
+
const n = (i) => {
|
|
1132
1103
|
if (t) {
|
|
1133
1104
|
clearTimeout(t), t = null;
|
|
1134
1105
|
return;
|
|
1135
1106
|
}
|
|
1136
1107
|
t = setTimeout(() => {
|
|
1137
|
-
o(
|
|
1108
|
+
o(i, !1), t = null;
|
|
1138
1109
|
}, 250);
|
|
1139
|
-
}, r = (
|
|
1140
|
-
t && (clearTimeout(t), t = null), o(
|
|
1141
|
-
}, o = (
|
|
1142
|
-
var a;
|
|
1110
|
+
}, r = (i) => {
|
|
1111
|
+
t && (clearTimeout(t), t = null), o(i, !0);
|
|
1112
|
+
}, o = (i, a = !1) => {
|
|
1143
1113
|
try {
|
|
1144
|
-
let
|
|
1114
|
+
let c = {
|
|
1145
1115
|
hostname: window.location.hostname,
|
|
1146
1116
|
pathname: window.location.pathname,
|
|
1147
1117
|
page_title: document.title,
|
|
1148
1118
|
url: window.location.href,
|
|
1149
1119
|
created_at: (/* @__PURE__ */ new Date()).toISOString(),
|
|
1150
|
-
event_type:
|
|
1151
|
-
button_type:
|
|
1120
|
+
event_type: a ? "dblclick" : "click",
|
|
1121
|
+
button_type: i.button
|
|
1152
1122
|
};
|
|
1153
|
-
if (
|
|
1154
|
-
const l =
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1123
|
+
if (i.target instanceof HTMLElement) {
|
|
1124
|
+
const l = i.target;
|
|
1125
|
+
c.rage_click = Fn?.isRageClick(
|
|
1126
|
+
i.clientX,
|
|
1127
|
+
i.clientY,
|
|
1158
1128
|
(/* @__PURE__ */ new Date()).getTime()
|
|
1159
|
-
),
|
|
1160
|
-
...
|
|
1161
|
-
...
|
|
1129
|
+
), c = {
|
|
1130
|
+
...c,
|
|
1131
|
+
...Xe(l)
|
|
1162
1132
|
};
|
|
1163
|
-
let
|
|
1164
|
-
if (!
|
|
1165
|
-
let
|
|
1166
|
-
for (;
|
|
1167
|
-
const
|
|
1168
|
-
if (
|
|
1169
|
-
|
|
1133
|
+
let g = l?.getAttribute("href");
|
|
1134
|
+
if (!g) {
|
|
1135
|
+
let m = l.parentNode, f = 0;
|
|
1136
|
+
for (; m && f < 8; ) {
|
|
1137
|
+
const E = m?.parentElement?.getAttribute("href");
|
|
1138
|
+
if (E) {
|
|
1139
|
+
g = E;
|
|
1170
1140
|
break;
|
|
1171
1141
|
}
|
|
1172
|
-
|
|
1142
|
+
m = m.parentNode, f++;
|
|
1173
1143
|
}
|
|
1174
1144
|
}
|
|
1175
|
-
e
|
|
1176
|
-
...
|
|
1177
|
-
href:
|
|
1145
|
+
e?.track("page.click", {
|
|
1146
|
+
...c,
|
|
1147
|
+
href: g || void 0
|
|
1178
1148
|
});
|
|
1179
1149
|
}
|
|
1180
1150
|
} catch {
|
|
@@ -1184,61 +1154,18 @@ const de = new Xn(), qn = () => {
|
|
|
1184
1154
|
document.removeEventListener("click", n), document.removeEventListener("dblclick", r);
|
|
1185
1155
|
};
|
|
1186
1156
|
}, [e]);
|
|
1187
|
-
},
|
|
1188
|
-
const { audience:
|
|
1189
|
-
|
|
1190
|
-
timestamp: Z(Date.now())
|
|
1191
|
-
}), [r, o] = x({
|
|
1192
|
-
value: null,
|
|
1193
|
-
timestamp: null
|
|
1194
|
-
}), [s, c] = x({
|
|
1195
|
-
value: null,
|
|
1196
|
-
timestamp: null
|
|
1197
|
-
});
|
|
1198
|
-
return b(() => {
|
|
1199
|
-
let a = !0;
|
|
1200
|
-
const u = (d, m) => {
|
|
1201
|
-
a && d({ value: Z(m), timestamp: Z(Date.now()) });
|
|
1202
|
-
}, l = new PerformanceObserver((d) => {
|
|
1203
|
-
for (const m of d.getEntries())
|
|
1204
|
-
m.name === "first-contentful-paint" && u(o, m.startTime);
|
|
1205
|
-
});
|
|
1206
|
-
l.observe({ type: "paint", buffered: !0 });
|
|
1207
|
-
const f = () => u(c, performance.now());
|
|
1208
|
-
return document.readyState === "complete" ? u(c, performance.now()) : window.addEventListener("load", f), () => {
|
|
1209
|
-
a = !1, l.disconnect(), window.removeEventListener("load", f);
|
|
1210
|
-
};
|
|
1211
|
-
}, []), b(() => {
|
|
1212
|
-
n && t && (t == null || t.track("page.metrics", {
|
|
1213
|
-
script_load: n.value,
|
|
1214
|
-
script_load_at: n.timestamp,
|
|
1215
|
-
version: 2
|
|
1216
|
-
}));
|
|
1217
|
-
}, [n, t]), b(() => {
|
|
1218
|
-
r.value !== null && t && (t == null || t.track("page.metrics", {
|
|
1219
|
-
first_contentful_paint: r.value,
|
|
1220
|
-
first_contentful_paint_at: r.timestamp,
|
|
1221
|
-
version: 2
|
|
1222
|
-
}));
|
|
1223
|
-
}, [r, t]), b(() => {
|
|
1224
|
-
s.value !== null && t && (t == null || t.track("page.metrics", {
|
|
1225
|
-
window_onload: s.value,
|
|
1226
|
-
window_onload_at: s.timestamp,
|
|
1227
|
-
version: 2
|
|
1228
|
-
}));
|
|
1229
|
-
}, [s, t]), { script: n, fcp: r, window_onload: s };
|
|
1230
|
-
}, Zn = () => {
|
|
1231
|
-
const { audience: e } = L();
|
|
1232
|
-
b(() => {
|
|
1157
|
+
}, Yn = () => {
|
|
1158
|
+
const { audience: e } = R();
|
|
1159
|
+
x(() => {
|
|
1233
1160
|
let t;
|
|
1234
1161
|
const n = () => {
|
|
1235
1162
|
clearTimeout(t), t = setTimeout(() => {
|
|
1236
1163
|
const r = window.getSelection();
|
|
1237
|
-
if (r &&
|
|
1238
|
-
const o = r
|
|
1239
|
-
o &&
|
|
1240
|
-
text:
|
|
1241
|
-
})
|
|
1164
|
+
if (r && r?.rangeCount > 0) {
|
|
1165
|
+
const o = r?.toString();
|
|
1166
|
+
o && e?.track("page.selection", {
|
|
1167
|
+
text: D(o)
|
|
1168
|
+
});
|
|
1242
1169
|
}
|
|
1243
1170
|
}, 1e3);
|
|
1244
1171
|
};
|
|
@@ -1246,166 +1173,105 @@ const de = new Xn(), qn = () => {
|
|
|
1246
1173
|
clearTimeout(t), document.removeEventListener("selectionchange", n);
|
|
1247
1174
|
};
|
|
1248
1175
|
}, []);
|
|
1249
|
-
},
|
|
1250
|
-
const [t, n] = x(null);
|
|
1251
|
-
return b(() => {
|
|
1252
|
-
const r = localStorage.getItem(Re);
|
|
1253
|
-
if (r) {
|
|
1254
|
-
const { speed: a, timestamp: u } = JSON.parse(r);
|
|
1255
|
-
if (Date.now() - u < Qn) {
|
|
1256
|
-
n(a);
|
|
1257
|
-
return;
|
|
1258
|
-
}
|
|
1259
|
-
}
|
|
1260
|
-
let o = null;
|
|
1261
|
-
const s = async () => {
|
|
1262
|
-
const a = new dt("download_speed");
|
|
1263
|
-
if (a.acquireLock())
|
|
1264
|
-
try {
|
|
1265
|
-
const l = performance.now();
|
|
1266
|
-
await fetch(e, { cache: "no-store" });
|
|
1267
|
-
const d = (performance.now() - l) / 1e3, m = Math.round(8 / d);
|
|
1268
|
-
n(m), localStorage.setItem(
|
|
1269
|
-
Re,
|
|
1270
|
-
JSON.stringify({ speed: m, timestamp: Date.now() })
|
|
1271
|
-
);
|
|
1272
|
-
} catch {
|
|
1273
|
-
} finally {
|
|
1274
|
-
a.releaseLock();
|
|
1275
|
-
}
|
|
1276
|
-
}, c = () => {
|
|
1277
|
-
document.removeEventListener("mousemove", c), document.removeEventListener("keydown", c), document.removeEventListener("scroll", c), o = setTimeout(s, 5e3);
|
|
1278
|
-
};
|
|
1279
|
-
return document.addEventListener("mousemove", c, { once: !0 }), document.addEventListener("keydown", c, { once: !0 }), document.addEventListener("scroll", c, { once: !0 }), () => {
|
|
1280
|
-
o && clearTimeout(o), document.removeEventListener("mousemove", c), document.removeEventListener("keydown", c), document.removeEventListener("scroll", c);
|
|
1281
|
-
};
|
|
1282
|
-
}, [e]), t;
|
|
1283
|
-
}, tr = ({
|
|
1176
|
+
}, zn = ({
|
|
1284
1177
|
id: e,
|
|
1285
1178
|
properties: t = {},
|
|
1286
1179
|
href: n
|
|
1287
1180
|
}) => {
|
|
1288
|
-
const r =
|
|
1289
|
-
|
|
1181
|
+
const r = R();
|
|
1182
|
+
x(() => {
|
|
1290
1183
|
(() => {
|
|
1291
|
-
|
|
1292
|
-
r != null && r.insightsUrl && r.workspace && n && ((s = r == null ? void 0 : r.audience) != null && s.instance ? r == null || r.audience.instance.page({
|
|
1184
|
+
r?.insightsUrl && r.workspace && n && (r?.audience?.instance ? r?.audience.instance.page({
|
|
1293
1185
|
resource: "page",
|
|
1294
1186
|
identifier: e
|
|
1295
|
-
}) :
|
|
1187
|
+
}) : r?.audience?.initiate({
|
|
1296
1188
|
...t,
|
|
1297
1189
|
id: e,
|
|
1298
1190
|
created_at: (/* @__PURE__ */ new Date()).toISOString()
|
|
1299
1191
|
}));
|
|
1300
1192
|
})();
|
|
1301
|
-
}, [r
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
r.audience.storage_keys.identify
|
|
1306
|
-
);
|
|
1307
|
-
s.key === r.audience.storage_keys.identify && !(r != null && r.audience.is_identified) && !c && ((a = r == null ? void 0 : r.audience) == null || a.identify({
|
|
1308
|
-
withLock: !1
|
|
1309
|
-
}));
|
|
1310
|
-
};
|
|
1311
|
-
return window.addEventListener("storage", o), () => {
|
|
1312
|
-
window.removeEventListener("storage", o);
|
|
1313
|
-
};
|
|
1314
|
-
}, []);
|
|
1315
|
-
}, nr = ({ id: e }) => {
|
|
1316
|
-
const t = L();
|
|
1317
|
-
b(() => {
|
|
1193
|
+
}, [r?.insightsUrl, r?.workspace, n]);
|
|
1194
|
+
}, Hn = ({ id: e }) => {
|
|
1195
|
+
const t = R();
|
|
1196
|
+
x(() => {
|
|
1318
1197
|
const r = () => {
|
|
1319
|
-
|
|
1320
|
-
const o = (c = performance.getEntriesByType(
|
|
1198
|
+
const o = performance.getEntriesByType(
|
|
1321
1199
|
"navigation"
|
|
1322
|
-
)
|
|
1323
|
-
let
|
|
1200
|
+
)?.[0];
|
|
1201
|
+
let i = !1;
|
|
1324
1202
|
if (o)
|
|
1325
|
-
o.type === "navigate" && (
|
|
1203
|
+
o.type === "navigate" && (i = !0);
|
|
1326
1204
|
else
|
|
1327
1205
|
try {
|
|
1328
|
-
const
|
|
1329
|
-
|
|
1206
|
+
const a = document.activeElement;
|
|
1207
|
+
a?.tagName === "A" && a.href && (new URL(a.href).origin !== window.location.origin ? i = !0 : i = !1);
|
|
1330
1208
|
} catch {
|
|
1331
1209
|
}
|
|
1332
|
-
|
|
1210
|
+
t?.audience?.bounce({
|
|
1333
1211
|
resource: "page",
|
|
1334
1212
|
identifier: e,
|
|
1335
|
-
is_navigating_away:
|
|
1336
|
-
navigation_type: o
|
|
1213
|
+
is_navigating_away: i,
|
|
1214
|
+
navigation_type: o?.type
|
|
1337
1215
|
});
|
|
1338
1216
|
};
|
|
1339
1217
|
return window.addEventListener("beforeunload", r), () => {
|
|
1340
1218
|
window.removeEventListener("beforeunload", r);
|
|
1341
1219
|
};
|
|
1342
|
-
}, [t
|
|
1343
|
-
const [n] =
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
(n === ue.HIDDEN || n === ue.UNKNOWN || n === ue.FROZEN) && ((r = t == null ? void 0 : t.audience) == null || r.bounce({
|
|
1220
|
+
}, [t?.audience, e]);
|
|
1221
|
+
const [n] = rt();
|
|
1222
|
+
x(() => {
|
|
1223
|
+
(n === se.HIDDEN || n === se.UNKNOWN || n === se.FROZEN) && t?.audience?.bounce({
|
|
1347
1224
|
resource: "page",
|
|
1348
1225
|
identifier: e,
|
|
1349
1226
|
state: n
|
|
1350
|
-
})
|
|
1351
|
-
}, [n, t
|
|
1352
|
-
},
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
b(() => {
|
|
1227
|
+
});
|
|
1228
|
+
}, [n, t?.audience, e]);
|
|
1229
|
+
}, _r = ({ id: e, properties: t = {} }) => {
|
|
1230
|
+
const n = typeof window < "u" ? window.location.href : "", r = R();
|
|
1231
|
+
x(() => {
|
|
1356
1232
|
r && typeof window < "u" && (window.levo_client = r);
|
|
1357
|
-
}, [r]),
|
|
1358
|
-
r
|
|
1359
|
-
}, []),
|
|
1360
|
-
const o =
|
|
1361
|
-
|
|
1362
|
-
|
|
1363
|
-
(a = r == null ? void 0 : r.audience) != null && a.instance && o && (r == null || r.audience.track("user.speedtest", {
|
|
1364
|
-
speed: o,
|
|
1365
|
-
unit: "Mbps"
|
|
1366
|
-
}));
|
|
1367
|
-
}, [o]);
|
|
1368
|
-
const s = Sn();
|
|
1369
|
-
return b(() => {
|
|
1370
|
-
var a;
|
|
1371
|
-
(a = r == null ? void 0 : r.audience) != null && a.instance && (r == null || r.audience.track("page.scroll", {
|
|
1233
|
+
}, [r]), x(() => {
|
|
1234
|
+
r?.audience && typeof window < "u" && (window.levo_audience = r?.audience);
|
|
1235
|
+
}, []), vn(), yn(), Un();
|
|
1236
|
+
const o = hn();
|
|
1237
|
+
return x(() => {
|
|
1238
|
+
r?.audience?.instance && r?.audience.track("page.scroll", {
|
|
1372
1239
|
resource: "page",
|
|
1373
1240
|
identifier: e,
|
|
1374
|
-
percent:
|
|
1375
|
-
speed_category:
|
|
1376
|
-
})
|
|
1241
|
+
percent: o.depth,
|
|
1242
|
+
speed_category: o.speedCategory
|
|
1243
|
+
});
|
|
1377
1244
|
}, [
|
|
1378
|
-
|
|
1379
|
-
|
|
1380
|
-
|
|
1245
|
+
r?.audience?.instance,
|
|
1246
|
+
o.depth,
|
|
1247
|
+
o.speedCategory,
|
|
1381
1248
|
e
|
|
1382
|
-
]),
|
|
1249
|
+
]), Yn(), zn({
|
|
1383
1250
|
href: n,
|
|
1384
1251
|
id: e,
|
|
1385
1252
|
properties: t
|
|
1386
|
-
}),
|
|
1387
|
-
const
|
|
1253
|
+
}), Hn({ id: e }), x(() => {
|
|
1254
|
+
const i = {
|
|
1388
1255
|
change: "form.change",
|
|
1389
1256
|
submit: "form.submit",
|
|
1390
1257
|
copy: "page.copy",
|
|
1391
1258
|
cut: "page.copy"
|
|
1392
|
-
},
|
|
1393
|
-
|
|
1394
|
-
|
|
1395
|
-
|
|
1396
|
-
|
|
1397
|
-
|
|
1398
|
-
|
|
1399
|
-
|
|
1400
|
-
submit: u("submit")
|
|
1259
|
+
}, a = (l) => (g) => {
|
|
1260
|
+
const m = Dn(g, l);
|
|
1261
|
+
m && i[l] && r?.audience?.track(i[l], m);
|
|
1262
|
+
}, c = {
|
|
1263
|
+
change: a("change"),
|
|
1264
|
+
copy: a("copy"),
|
|
1265
|
+
cut: a("cut"),
|
|
1266
|
+
submit: a("submit")
|
|
1401
1267
|
};
|
|
1402
|
-
return document.addEventListener("change",
|
|
1403
|
-
document.removeEventListener("change",
|
|
1268
|
+
return document.addEventListener("change", c.change), document.addEventListener("copy", c.copy), document.addEventListener("cut", c.cut), document.addEventListener("submit", c.submit), () => {
|
|
1269
|
+
document.removeEventListener("change", c.change), document.removeEventListener("copy", c.copy), document.removeEventListener("cut", c.cut), document.removeEventListener("submit", c.submit);
|
|
1404
1270
|
};
|
|
1405
|
-
}, []), (!
|
|
1271
|
+
}, []), (!r?.insightsUrl || !r.workspace || !r.workspace.startsWith("W")) && console.error(
|
|
1406
1272
|
"[@levo-so/react] The utility could not be initialized, due to missing workspace, or endpoint for insights."
|
|
1407
1273
|
), null;
|
|
1408
|
-
},
|
|
1274
|
+
}, qe = L.createContext({
|
|
1409
1275
|
urls: null,
|
|
1410
1276
|
title: "",
|
|
1411
1277
|
isLoading: !1,
|
|
@@ -1413,68 +1279,67 @@ const de = new Xn(), qn = () => {
|
|
|
1413
1279
|
},
|
|
1414
1280
|
onError: () => {
|
|
1415
1281
|
}
|
|
1416
|
-
}),
|
|
1282
|
+
}), Vn = ({
|
|
1417
1283
|
title: e,
|
|
1418
1284
|
onSuccess: t,
|
|
1419
1285
|
onError: n,
|
|
1420
1286
|
children: r
|
|
1421
1287
|
}) => {
|
|
1422
|
-
const o =
|
|
1423
|
-
|
|
1424
|
-
|
|
1425
|
-
|
|
1426
|
-
|
|
1427
|
-
}).catch((m) => {
|
|
1288
|
+
const o = R(), i = typeof window < "u" ? window.location.href : "", [a, c] = O(null), [l, g] = O(!1);
|
|
1289
|
+
x(() => {
|
|
1290
|
+
o.membership && (g(!0), o.membership?.getOAuthURL().then((f) => {
|
|
1291
|
+
c(f);
|
|
1292
|
+
}).catch((f) => {
|
|
1428
1293
|
n({
|
|
1429
|
-
code:
|
|
1430
|
-
message:
|
|
1294
|
+
code: f?.code || "SOMETHING_WENT_WRONG",
|
|
1295
|
+
message: f?.message || "We could not connect with our service for your sign-in."
|
|
1431
1296
|
});
|
|
1432
1297
|
}).finally(() => {
|
|
1433
|
-
|
|
1298
|
+
g(!1);
|
|
1434
1299
|
}));
|
|
1435
1300
|
}, []);
|
|
1436
|
-
const
|
|
1437
|
-
() => ({ title: e, urls:
|
|
1438
|
-
[e,
|
|
1301
|
+
const m = Ne(
|
|
1302
|
+
() => ({ title: e, urls: a, isLoading: l, onSuccess: t, onError: n }),
|
|
1303
|
+
[e, a, t, n, l]
|
|
1439
1304
|
);
|
|
1440
|
-
return
|
|
1441
|
-
if (
|
|
1442
|
-
const
|
|
1443
|
-
for (const v of
|
|
1305
|
+
return x(() => {
|
|
1306
|
+
if (a && i) {
|
|
1307
|
+
const f = {}, E = Object.keys(a);
|
|
1308
|
+
for (const v of E)
|
|
1444
1309
|
try {
|
|
1445
|
-
const _ =
|
|
1310
|
+
const _ = a[v];
|
|
1446
1311
|
if (_) {
|
|
1447
|
-
const
|
|
1448
|
-
|
|
1449
|
-
const
|
|
1450
|
-
|
|
1312
|
+
const k = new URL(_), j = k.searchParams;
|
|
1313
|
+
j.set("redirect_uri", i);
|
|
1314
|
+
const S = o.pageContext;
|
|
1315
|
+
S && j.set("page_context", JSON.stringify(S)), f[v] = k.toString();
|
|
1451
1316
|
}
|
|
1452
1317
|
} catch {
|
|
1453
1318
|
}
|
|
1454
|
-
|
|
1319
|
+
c(f);
|
|
1455
1320
|
}
|
|
1456
|
-
}, [
|
|
1457
|
-
},
|
|
1458
|
-
const o = window.screenX + (window.outerWidth - r) / 2,
|
|
1321
|
+
}, [i]), /* @__PURE__ */ d.jsx(qe.Provider, { value: m, children: r });
|
|
1322
|
+
}, Gn = () => je(qe), Jn = ({ url: e, title: t, height: n, width: r }) => {
|
|
1323
|
+
const o = window.screenX + (window.outerWidth - r) / 2, i = window.screenY + (window.outerHeight - n) / 2.5;
|
|
1459
1324
|
return window.open(
|
|
1460
1325
|
e,
|
|
1461
1326
|
t,
|
|
1462
|
-
`width=${r},height=${n},left=${o},top=${
|
|
1327
|
+
`width=${r},height=${n},left=${o},top=${i}`
|
|
1463
1328
|
);
|
|
1464
|
-
},
|
|
1329
|
+
}, Xn = ({
|
|
1465
1330
|
title: e = "",
|
|
1466
1331
|
width: t = 500,
|
|
1467
1332
|
height: n = 500,
|
|
1468
1333
|
url: r,
|
|
1469
1334
|
children: o,
|
|
1470
|
-
onCode:
|
|
1471
|
-
onClose:
|
|
1335
|
+
onCode: i,
|
|
1336
|
+
onClose: a
|
|
1472
1337
|
}) => {
|
|
1473
|
-
const [
|
|
1474
|
-
window.clearInterval(
|
|
1475
|
-
},
|
|
1476
|
-
|
|
1477
|
-
|
|
1338
|
+
const [c, l] = O(), g = ke(void 0), m = () => {
|
|
1339
|
+
window.clearInterval(g.current);
|
|
1340
|
+
}, f = () => {
|
|
1341
|
+
l(
|
|
1342
|
+
Jn({
|
|
1478
1343
|
url: r,
|
|
1479
1344
|
title: e,
|
|
1480
1345
|
width: t,
|
|
@@ -1482,119 +1347,117 @@ const de = new Xn(), qn = () => {
|
|
|
1482
1347
|
})
|
|
1483
1348
|
);
|
|
1484
1349
|
};
|
|
1485
|
-
return
|
|
1350
|
+
return x(() => (c && (g.current = window.setInterval(() => {
|
|
1486
1351
|
try {
|
|
1487
|
-
const
|
|
1352
|
+
const E = c.location.href, v = new URL(E).searchParams, _ = v.get("code");
|
|
1488
1353
|
if (!_)
|
|
1489
1354
|
return;
|
|
1490
|
-
|
|
1355
|
+
i(_, v), m(), c.close();
|
|
1491
1356
|
} catch {
|
|
1492
1357
|
} finally {
|
|
1493
|
-
(!
|
|
1358
|
+
(!c || c.closed) && (a(), m());
|
|
1494
1359
|
}
|
|
1495
1360
|
}, 700)), () => {
|
|
1496
|
-
|
|
1497
|
-
}), [
|
|
1361
|
+
c && c.close(), a && a();
|
|
1362
|
+
}), [c]), /* @__PURE__ */ d.jsx(
|
|
1498
1363
|
"div",
|
|
1499
1364
|
{
|
|
1500
1365
|
onClick: () => {
|
|
1501
|
-
|
|
1366
|
+
f();
|
|
1502
1367
|
},
|
|
1503
1368
|
children: o
|
|
1504
1369
|
}
|
|
1505
1370
|
);
|
|
1506
|
-
},
|
|
1371
|
+
}, qn = ({
|
|
1507
1372
|
title: e = "Levo",
|
|
1508
1373
|
url: t,
|
|
1509
1374
|
children: n,
|
|
1510
1375
|
onSuccess: r,
|
|
1511
1376
|
onError: o,
|
|
1512
|
-
width:
|
|
1513
|
-
height:
|
|
1377
|
+
width: i = 500,
|
|
1378
|
+
height: a = 700
|
|
1514
1379
|
}) => {
|
|
1515
|
-
const
|
|
1516
|
-
|
|
1380
|
+
const c = ae((l, g) => {
|
|
1381
|
+
l.toLowerCase() === "success" ? r(g) : o(g);
|
|
1517
1382
|
}, []);
|
|
1518
|
-
return /* @__PURE__ */
|
|
1519
|
-
|
|
1383
|
+
return /* @__PURE__ */ d.jsx(
|
|
1384
|
+
Xn,
|
|
1520
1385
|
{
|
|
1521
1386
|
title: e,
|
|
1522
|
-
width:
|
|
1523
|
-
height:
|
|
1387
|
+
width: i,
|
|
1388
|
+
height: a,
|
|
1524
1389
|
onClose: () => {
|
|
1525
1390
|
},
|
|
1526
1391
|
url: t,
|
|
1527
|
-
onCode:
|
|
1392
|
+
onCode: c,
|
|
1528
1393
|
children: n
|
|
1529
1394
|
}
|
|
1530
1395
|
);
|
|
1531
|
-
},
|
|
1532
|
-
const { title: n, urls: r, isLoading: o, onSuccess:
|
|
1533
|
-
return
|
|
1534
|
-
|
|
1396
|
+
}, Kn = ({ children: e, provider: t }) => {
|
|
1397
|
+
const { title: n, urls: r, isLoading: o, onSuccess: i, onError: a } = Gn(), c = r?.[t];
|
|
1398
|
+
return c ? /* @__PURE__ */ d.jsx(
|
|
1399
|
+
qn,
|
|
1535
1400
|
{
|
|
1536
1401
|
title: n,
|
|
1537
1402
|
provider: t,
|
|
1538
|
-
url:
|
|
1539
|
-
onSuccess:
|
|
1540
|
-
onError:
|
|
1541
|
-
children: o ? /* @__PURE__ */
|
|
1403
|
+
url: c,
|
|
1404
|
+
onSuccess: i,
|
|
1405
|
+
onError: a,
|
|
1406
|
+
children: o ? /* @__PURE__ */ d.jsx("div", { className: "w-full items-center justify-center", children: /* @__PURE__ */ d.jsx(Lt, { className: "bg-brand h-5 w-5" }) }) : e
|
|
1542
1407
|
}
|
|
1543
1408
|
) : null;
|
|
1544
|
-
},
|
|
1545
|
-
const o = window.screenX + (window.outerWidth - r) / 2,
|
|
1409
|
+
}, Zn = ({ url: e, title: t, height: n, width: r }) => {
|
|
1410
|
+
const o = window.screenX + (window.outerWidth - r) / 2, i = window.screenY + (window.outerHeight - n) / 2.5;
|
|
1546
1411
|
return window.open(
|
|
1547
1412
|
e,
|
|
1548
1413
|
t,
|
|
1549
|
-
`width=${r},height=${n},left=${o},top=${
|
|
1414
|
+
`width=${r},height=${n},left=${o},top=${i}`
|
|
1550
1415
|
);
|
|
1551
|
-
},
|
|
1416
|
+
}, Or = ({
|
|
1552
1417
|
title: e = "Levo",
|
|
1553
1418
|
width: t = 500,
|
|
1554
1419
|
height: n = 700,
|
|
1555
1420
|
onSuccess: r
|
|
1556
1421
|
}) => {
|
|
1557
|
-
const o =
|
|
1422
|
+
const o = R(), [i, a] = O(!1), [c, l] = O(null), [g, m] = O(null), [f, E] = O(), v = ke(void 0), _ = () => {
|
|
1558
1423
|
window.clearInterval(v.current);
|
|
1559
|
-
},
|
|
1560
|
-
|
|
1424
|
+
}, k = ae((h, T) => {
|
|
1425
|
+
h.toLowerCase() === "success" ? (m(null), r(T)) : m(T);
|
|
1561
1426
|
}, []);
|
|
1562
|
-
|
|
1563
|
-
|
|
1564
|
-
|
|
1565
|
-
|
|
1566
|
-
return u(y), y;
|
|
1427
|
+
x(() => {
|
|
1428
|
+
o.membership && (a(!0), o.membership?.getOAuthURL().then((h) => {
|
|
1429
|
+
if (h)
|
|
1430
|
+
return l(h), h;
|
|
1567
1431
|
throw new Error();
|
|
1568
|
-
}).catch((
|
|
1569
|
-
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
message: (O == null ? void 0 : O.message) || "We could not connect with our service for your sign-in."
|
|
1432
|
+
}).catch((h) => {
|
|
1433
|
+
const T = Ce(h);
|
|
1434
|
+
o.logger?.error("Failed to get OAuth URL", T.message), m({
|
|
1435
|
+
code: T?.code || "SOMETHING_WENT_WRONG",
|
|
1436
|
+
message: T?.message || "We could not connect with our service for your sign-in."
|
|
1574
1437
|
});
|
|
1575
1438
|
}).finally(() => {
|
|
1576
|
-
|
|
1439
|
+
a(!1);
|
|
1577
1440
|
}));
|
|
1578
|
-
}, []),
|
|
1441
|
+
}, []), x(() => (f && (v.current = window.setInterval(() => {
|
|
1579
1442
|
try {
|
|
1580
|
-
const
|
|
1581
|
-
if (!
|
|
1443
|
+
const h = f.location.href, T = new URL(h).searchParams, M = T.get("code");
|
|
1444
|
+
if (!M)
|
|
1582
1445
|
return;
|
|
1583
|
-
|
|
1446
|
+
k(M, T), _(), f.close();
|
|
1584
1447
|
} catch {
|
|
1585
1448
|
} finally {
|
|
1586
|
-
(!
|
|
1449
|
+
(!f || f.closed) && (_(), m(null));
|
|
1587
1450
|
}
|
|
1588
1451
|
}, 700)), () => {
|
|
1589
|
-
|
|
1590
|
-
}), [
|
|
1591
|
-
const
|
|
1592
|
-
(
|
|
1593
|
-
if (
|
|
1594
|
-
const
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
url:
|
|
1452
|
+
f && f.close();
|
|
1453
|
+
}), [f]);
|
|
1454
|
+
const j = ae(
|
|
1455
|
+
(h) => {
|
|
1456
|
+
if (h && c !== null) {
|
|
1457
|
+
const T = c?.[h];
|
|
1458
|
+
T && (f && f.close(), E(
|
|
1459
|
+
Zn({
|
|
1460
|
+
url: T,
|
|
1598
1461
|
title: e,
|
|
1599
1462
|
width: t,
|
|
1600
1463
|
height: n
|
|
@@ -1602,74 +1465,75 @@ const de = new Xn(), qn = () => {
|
|
|
1602
1465
|
));
|
|
1603
1466
|
}
|
|
1604
1467
|
},
|
|
1605
|
-
[
|
|
1468
|
+
[c, f]
|
|
1606
1469
|
);
|
|
1607
1470
|
return {
|
|
1608
|
-
providers:
|
|
1609
|
-
(
|
|
1610
|
-
) : [], [
|
|
1611
|
-
isLoading:
|
|
1612
|
-
error:
|
|
1613
|
-
launchPopup:
|
|
1471
|
+
providers: Ne(() => c !== null ? Object.keys(c).filter(
|
|
1472
|
+
(h) => !!c[h]
|
|
1473
|
+
) : [], [c]),
|
|
1474
|
+
isLoading: i,
|
|
1475
|
+
error: g,
|
|
1476
|
+
launchPopup: j
|
|
1614
1477
|
};
|
|
1615
1478
|
};
|
|
1616
|
-
class
|
|
1479
|
+
class jr {
|
|
1480
|
+
static Container = Vn;
|
|
1481
|
+
static Button = Kn;
|
|
1617
1482
|
}
|
|
1618
|
-
J(Le, "Container", rr), J(Le, "Button", cr);
|
|
1619
1483
|
export {
|
|
1620
|
-
|
|
1621
|
-
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1634
|
-
|
|
1635
|
-
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
|
|
1639
|
-
|
|
1640
|
-
|
|
1641
|
-
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
|
|
1652
|
-
|
|
1653
|
-
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
|
|
1658
|
-
|
|
1659
|
-
|
|
1660
|
-
|
|
1661
|
-
|
|
1662
|
-
|
|
1663
|
-
|
|
1664
|
-
|
|
1665
|
-
|
|
1666
|
-
|
|
1667
|
-
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1672
|
-
|
|
1673
|
-
|
|
1674
|
-
|
|
1484
|
+
kt as Button,
|
|
1485
|
+
St as Dialog,
|
|
1486
|
+
dr as DialogClose,
|
|
1487
|
+
Ie as DialogContent,
|
|
1488
|
+
Me as DialogDescription,
|
|
1489
|
+
Rt as DialogFooter,
|
|
1490
|
+
De as DialogHeader,
|
|
1491
|
+
Ae as DialogOverlay,
|
|
1492
|
+
Ct as DialogPortal,
|
|
1493
|
+
$e as DialogTitle,
|
|
1494
|
+
ur as DialogTrigger,
|
|
1495
|
+
fr as DialogWrapper,
|
|
1496
|
+
Er as LevoInsightsBlock,
|
|
1497
|
+
Tr as LevoInsightsComponent,
|
|
1498
|
+
_r as LevoInsightsPage,
|
|
1499
|
+
jr as LevoOAuth,
|
|
1500
|
+
xr as LevoProvider,
|
|
1501
|
+
hr as SimpleTooltipWrapper,
|
|
1502
|
+
Lt as Spinner,
|
|
1503
|
+
pr as Tabs,
|
|
1504
|
+
Dt as TabsContent,
|
|
1505
|
+
At as TabsList,
|
|
1506
|
+
It as TabsTrigger,
|
|
1507
|
+
mr as Toaster,
|
|
1508
|
+
$t as Tooltip,
|
|
1509
|
+
Be as TooltipContent,
|
|
1510
|
+
Bt as TooltipPortal,
|
|
1511
|
+
br as TooltipProvider,
|
|
1512
|
+
Mt as TooltipTrigger,
|
|
1513
|
+
cr as allMediaFileExtensions,
|
|
1514
|
+
lr as allMediaMimetypes,
|
|
1515
|
+
dt as audioFileExtensions,
|
|
1516
|
+
pt as audioMimetype,
|
|
1517
|
+
Nt as buttonVariants,
|
|
1518
|
+
vr as byteToSize,
|
|
1519
|
+
C as cn,
|
|
1520
|
+
ct as documentFileExtensions,
|
|
1521
|
+
ft as documentMimetype,
|
|
1522
|
+
yr as errorHandler,
|
|
1523
|
+
Pt as errorToast,
|
|
1524
|
+
lt as imageFileExtensions,
|
|
1525
|
+
mt as imageMimetype,
|
|
1526
|
+
Wt as isDateObject,
|
|
1527
|
+
wr as isEmptyObject,
|
|
1528
|
+
Ft as isNullOrUndefined,
|
|
1529
|
+
Yt as isObject,
|
|
1530
|
+
Ut as isObjectType,
|
|
1531
|
+
J as mediaExtensionsByKind,
|
|
1532
|
+
G as mediaMimetypeByKind,
|
|
1533
|
+
gr as successToast,
|
|
1534
|
+
Sr as toast,
|
|
1535
|
+
R as useLevo,
|
|
1536
|
+
Or as useLevoOAuth,
|
|
1537
|
+
ut as videoFileExtensions,
|
|
1538
|
+
gt as videoMimetype
|
|
1675
1539
|
};
|