@slashid/jump-page 0.0.8-package.13 → 0.0.8-package.15
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/_astro/{app.1e2eff21.js → app.b40faa4b.js} +1 -1
- package/dist/_astro/{sdk.0e66b66d.css → sdk.a5e3db34.css} +1 -1
- package/dist/_astro/{sdk.c4317c20.css → sdk.f9c04234.css} +1 -1
- package/dist/sdk.html +1 -1
- package/package/astro.config.d.mts +2 -0
- package/package/dist/_astro/app.b40faa4b.d.ts +2 -0
- package/package/dist/_astro/client.2acc8023.d.ts +7 -0
- package/package/dist/_astro/index.2e7fe26b.d.ts +5 -0
- package/package/favicon.png +0 -0
- package/package/main.js +2241 -0
- package/package/main.js.map +1 -0
- package/package/src/components/app/app.component.d.ts +1 -0
- package/package/src/components/app/app.context.d.ts +22 -0
- package/package/src/components/app/app.css.d.ts +1 -0
- package/package/src/components/app/index.d.ts +1 -0
- package/package/src/components/card/card.component.d.ts +10 -0
- package/package/src/components/card/card.css.d.ts +4 -0
- package/package/src/components/card/index.d.ts +1 -0
- package/package/src/components/flow/flow.component.d.ts +1 -0
- package/package/src/components/flow/flow.css.d.ts +3 -0
- package/package/src/components/flow/flow.error.d.ts +5 -0
- package/package/src/components/flow/flow.initial.d.ts +1 -0
- package/package/src/components/flow/flow.loader.d.ts +1 -0
- package/package/src/components/flow/flow.loading.d.ts +1 -0
- package/package/src/components/flow/flow.progress.d.ts +11 -0
- package/package/src/components/flow/flow.recover.d.ts +1 -0
- package/package/src/components/flow/flow.success.d.ts +3 -0
- package/package/src/components/flow/flow.types.d.ts +37 -0
- package/package/src/components/flow/index.d.ts +3 -0
- package/package/src/components/text/index.d.ts +1 -0
- package/package/src/components/text/text.component.d.ts +6 -0
- package/package/src/components/text/use-i18n.d.ts +1 -0
- package/package/src/config.d.ts +4 -0
- package/package/src/domain/errors.d.ts +1 -0
- package/package/src/domain/i18n.d.ts +43 -0
- package/package/src/main.d.ts +9 -0
- package/package/style.css +1 -0
- package/package/vite.config.d.ts +2 -0
- package/package.json +15 -15
package/package/main.js
ADDED
|
@@ -0,0 +1,2241 @@
|
|
|
1
|
+
var Zt = Object.defineProperty;
|
|
2
|
+
var er = (t, e, n) => e in t ? Zt(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
|
|
3
|
+
var Je = (t, e, n) => (er(t, typeof e != "symbol" ? e + "" : e, n), n);
|
|
4
|
+
import { Logo as tr, Text as _e, Circle as be, Spinner as rr, Stack as ne, Skeleton as Ke, Exclamation as nr, PasswordInput as ze, sprinkles as sr, Button as ir, interpolate as ar } from "@slashid/react-primitives";
|
|
5
|
+
import { TextProvider as Tn, ThemeRoot as jn } from "@slashid/react-primitives";
|
|
6
|
+
import st, { createContext as or, useContext as cr, useMemo as ur, useState as Z, useEffect as it } from "react";
|
|
7
|
+
const S = {
|
|
8
|
+
"footer.text": "Top-tier security by SlashID",
|
|
9
|
+
"initial.title": "Logging you in...",
|
|
10
|
+
"initial.details": "Please follow the on-screen instructions.",
|
|
11
|
+
"recover.password.title": "Reset password",
|
|
12
|
+
"recover.password.details": "Enter your new password.",
|
|
13
|
+
"recover.password.input.password.label": "Password",
|
|
14
|
+
"recover.password.input.confirmPassword.label": "Confirm password",
|
|
15
|
+
"recover.password.input.placeholder": "Type your new password",
|
|
16
|
+
"recover.password.submit": "Reset password",
|
|
17
|
+
"recover.password.validation.passwordsDoNotMatch": "Passwords do not match",
|
|
18
|
+
"recover.password.validation.length": "8-256 characters required",
|
|
19
|
+
"recover.password.validation.password_variants": "Contains word 'password'",
|
|
20
|
+
"recover.password.validation.admin_variants": "Contains word 'admin'",
|
|
21
|
+
"recover.password.validation.user_variants": "Contains word 'user'",
|
|
22
|
+
"recover.password.validation.alphanumeric_sequences_1": "Illegal sequence: {{ILLEGAL_SEQUENCE}}",
|
|
23
|
+
"recover.password.validation.alphanumeric_sequences_2": "Illegal sequence: {{ILLEGAL_SEQUENCE}}",
|
|
24
|
+
"recover.password.validation.numeric_sequences_ascending": "Illegal sequence: {{ILLEGAL_SEQUENCE}}",
|
|
25
|
+
"recover.password.validation.numeric_subsequences_ascending": "Illegal sequence: {{ILLEGAL_SEQUENCE}}",
|
|
26
|
+
"recover.password.validation.numeric_sequences_descending": "Illegal sequence: {{ILLEGAL_SEQUENCE}}",
|
|
27
|
+
"recover.password.validation.numeric_subsequences_descending": "Illegal sequence: {{ILLEGAL_SEQUENCE}}",
|
|
28
|
+
"recover.password.validation.common_password_xkcd": "Common password",
|
|
29
|
+
"success.title": "All done!",
|
|
30
|
+
"success.details": "Please return to the website.",
|
|
31
|
+
"error.title": "Something went wrong...",
|
|
32
|
+
"error.detail": "Please log in again."
|
|
33
|
+
}, lr = {
|
|
34
|
+
en: S,
|
|
35
|
+
ja: {
|
|
36
|
+
"footer.text": S["footer.text"],
|
|
37
|
+
"initial.title": "ログイン処理を行っています。",
|
|
38
|
+
"initial.details": "処理完了後、画面は自動で切り替わります。",
|
|
39
|
+
"success.title": "認証が完了しました!",
|
|
40
|
+
"success.details": "このページを閉じて、元のページへ戻ってください。",
|
|
41
|
+
"recover.password.title": S["recover.password.title"],
|
|
42
|
+
"recover.password.details": S["recover.password.details"],
|
|
43
|
+
"recover.password.input.password.label": S["recover.password.input.password.label"],
|
|
44
|
+
"recover.password.input.confirmPassword.label": S["recover.password.input.confirmPassword.label"],
|
|
45
|
+
"recover.password.input.placeholder": S["recover.password.input.placeholder"],
|
|
46
|
+
"recover.password.submit": S["recover.password.submit"],
|
|
47
|
+
"recover.password.validation.passwordsDoNotMatch": S["recover.password.validation.passwordsDoNotMatch"],
|
|
48
|
+
"recover.password.validation.length": S["recover.password.validation.length"],
|
|
49
|
+
"recover.password.validation.password_variants": S["recover.password.validation.password_variants"],
|
|
50
|
+
"recover.password.validation.admin_variants": S["recover.password.validation.admin_variants"],
|
|
51
|
+
"recover.password.validation.user_variants": S["recover.password.validation.user_variants"],
|
|
52
|
+
"recover.password.validation.alphanumeric_sequences_1": S["recover.password.validation.alphanumeric_sequences_1"],
|
|
53
|
+
"recover.password.validation.alphanumeric_sequences_2": S["recover.password.validation.alphanumeric_sequences_2"],
|
|
54
|
+
"recover.password.validation.numeric_sequences_ascending": S["recover.password.validation.numeric_sequences_ascending"],
|
|
55
|
+
"recover.password.validation.numeric_subsequences_ascending": S["recover.password.validation.numeric_subsequences_ascending"],
|
|
56
|
+
"recover.password.validation.numeric_sequences_descending": S["recover.password.validation.numeric_sequences_descending"],
|
|
57
|
+
"recover.password.validation.numeric_subsequences_descending": S["recover.password.validation.numeric_subsequences_descending"],
|
|
58
|
+
"recover.password.validation.common_password_xkcd": S["recover.password.validation.common_password_xkcd"],
|
|
59
|
+
"error.title": S["error.title"],
|
|
60
|
+
"error.detail": "再度ログインをしてください。"
|
|
61
|
+
}
|
|
62
|
+
}, dr = (t) => (e) => lr[t][e];
|
|
63
|
+
var ge = { exports: {} }, W = {};
|
|
64
|
+
/**
|
|
65
|
+
* @license React
|
|
66
|
+
* react-jsx-runtime.production.min.js
|
|
67
|
+
*
|
|
68
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
69
|
+
*
|
|
70
|
+
* This source code is licensed under the MIT license found in the
|
|
71
|
+
* LICENSE file in the root directory of this source tree.
|
|
72
|
+
*/
|
|
73
|
+
var Qe;
|
|
74
|
+
function fr() {
|
|
75
|
+
if (Qe)
|
|
76
|
+
return W;
|
|
77
|
+
Qe = 1;
|
|
78
|
+
var t = st, e = Symbol.for("react.element"), n = Symbol.for("react.fragment"), s = Object.prototype.hasOwnProperty, i = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, c = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
79
|
+
function u(h, f, m) {
|
|
80
|
+
var E, y = {}, j = null, x = null;
|
|
81
|
+
m !== void 0 && (j = "" + m), f.key !== void 0 && (j = "" + f.key), f.ref !== void 0 && (x = f.ref);
|
|
82
|
+
for (E in f)
|
|
83
|
+
s.call(f, E) && !c.hasOwnProperty(E) && (y[E] = f[E]);
|
|
84
|
+
if (h && h.defaultProps)
|
|
85
|
+
for (E in f = h.defaultProps, f)
|
|
86
|
+
y[E] === void 0 && (y[E] = f[E]);
|
|
87
|
+
return { $$typeof: e, type: h, key: j, ref: x, props: y, _owner: i.current };
|
|
88
|
+
}
|
|
89
|
+
return W.Fragment = n, W.jsx = u, W.jsxs = u, W;
|
|
90
|
+
}
|
|
91
|
+
var H = {};
|
|
92
|
+
/**
|
|
93
|
+
* @license React
|
|
94
|
+
* react-jsx-runtime.development.js
|
|
95
|
+
*
|
|
96
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
97
|
+
*
|
|
98
|
+
* This source code is licensed under the MIT license found in the
|
|
99
|
+
* LICENSE file in the root directory of this source tree.
|
|
100
|
+
*/
|
|
101
|
+
var Xe;
|
|
102
|
+
function pr() {
|
|
103
|
+
return Xe || (Xe = 1, process.env.NODE_ENV !== "production" && function() {
|
|
104
|
+
var t = st, e = Symbol.for("react.element"), n = Symbol.for("react.portal"), s = Symbol.for("react.fragment"), i = Symbol.for("react.strict_mode"), c = Symbol.for("react.profiler"), u = Symbol.for("react.provider"), h = Symbol.for("react.context"), f = Symbol.for("react.forward_ref"), m = Symbol.for("react.suspense"), E = Symbol.for("react.suspense_list"), y = Symbol.for("react.memo"), j = Symbol.for("react.lazy"), x = Symbol.for("react.offscreen"), $ = Symbol.iterator, mt = "@@iterator";
|
|
105
|
+
function Et(r) {
|
|
106
|
+
if (r === null || typeof r != "object")
|
|
107
|
+
return null;
|
|
108
|
+
var a = $ && r[$] || r[mt];
|
|
109
|
+
return typeof a == "function" ? a : null;
|
|
110
|
+
}
|
|
111
|
+
var q = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
112
|
+
function C(r) {
|
|
113
|
+
{
|
|
114
|
+
for (var a = arguments.length, o = new Array(a > 1 ? a - 1 : 0), d = 1; d < a; d++)
|
|
115
|
+
o[d - 1] = arguments[d];
|
|
116
|
+
bt("error", r, o);
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
function bt(r, a, o) {
|
|
120
|
+
{
|
|
121
|
+
var d = q.ReactDebugCurrentFrame, g = d.getStackAddendum();
|
|
122
|
+
g !== "" && (a += "%s", o = o.concat([g]));
|
|
123
|
+
var v = o.map(function(_) {
|
|
124
|
+
return String(_);
|
|
125
|
+
});
|
|
126
|
+
v.unshift("Warning: " + a), Function.prototype.apply.call(console[r], console, v);
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
var St = !1, wt = !1, yt = !1, xt = !1, Ct = !1, xe;
|
|
130
|
+
xe = Symbol.for("react.module.reference");
|
|
131
|
+
function Rt(r) {
|
|
132
|
+
return !!(typeof r == "string" || typeof r == "function" || r === s || r === c || Ct || r === i || r === m || r === E || xt || r === x || St || wt || yt || typeof r == "object" && r !== null && (r.$$typeof === j || r.$$typeof === y || r.$$typeof === u || r.$$typeof === h || r.$$typeof === f || // This needs to include all possible module reference object
|
|
133
|
+
// types supported by any Flight configuration anywhere since
|
|
134
|
+
// we don't know which Flight build this will end up being used
|
|
135
|
+
// with.
|
|
136
|
+
r.$$typeof === xe || r.getModuleId !== void 0));
|
|
137
|
+
}
|
|
138
|
+
function Tt(r, a, o) {
|
|
139
|
+
var d = r.displayName;
|
|
140
|
+
if (d)
|
|
141
|
+
return d;
|
|
142
|
+
var g = a.displayName || a.name || "";
|
|
143
|
+
return g !== "" ? o + "(" + g + ")" : o;
|
|
144
|
+
}
|
|
145
|
+
function Ce(r) {
|
|
146
|
+
return r.displayName || "Context";
|
|
147
|
+
}
|
|
148
|
+
function D(r) {
|
|
149
|
+
if (r == null)
|
|
150
|
+
return null;
|
|
151
|
+
if (typeof r.tag == "number" && C("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof r == "function")
|
|
152
|
+
return r.displayName || r.name || null;
|
|
153
|
+
if (typeof r == "string")
|
|
154
|
+
return r;
|
|
155
|
+
switch (r) {
|
|
156
|
+
case s:
|
|
157
|
+
return "Fragment";
|
|
158
|
+
case n:
|
|
159
|
+
return "Portal";
|
|
160
|
+
case c:
|
|
161
|
+
return "Profiler";
|
|
162
|
+
case i:
|
|
163
|
+
return "StrictMode";
|
|
164
|
+
case m:
|
|
165
|
+
return "Suspense";
|
|
166
|
+
case E:
|
|
167
|
+
return "SuspenseList";
|
|
168
|
+
}
|
|
169
|
+
if (typeof r == "object")
|
|
170
|
+
switch (r.$$typeof) {
|
|
171
|
+
case h:
|
|
172
|
+
var a = r;
|
|
173
|
+
return Ce(a) + ".Consumer";
|
|
174
|
+
case u:
|
|
175
|
+
var o = r;
|
|
176
|
+
return Ce(o._context) + ".Provider";
|
|
177
|
+
case f:
|
|
178
|
+
return Tt(r, r.render, "ForwardRef");
|
|
179
|
+
case y:
|
|
180
|
+
var d = r.displayName || null;
|
|
181
|
+
return d !== null ? d : D(r.type) || "Memo";
|
|
182
|
+
case j: {
|
|
183
|
+
var g = r, v = g._payload, _ = g._init;
|
|
184
|
+
try {
|
|
185
|
+
return D(_(v));
|
|
186
|
+
} catch {
|
|
187
|
+
return null;
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
return null;
|
|
192
|
+
}
|
|
193
|
+
var A = Object.assign, G = 0, Re, Te, je, Oe, Pe, De, Ie;
|
|
194
|
+
function Ne() {
|
|
195
|
+
}
|
|
196
|
+
Ne.__reactDisabledLog = !0;
|
|
197
|
+
function jt() {
|
|
198
|
+
{
|
|
199
|
+
if (G === 0) {
|
|
200
|
+
Re = console.log, Te = console.info, je = console.warn, Oe = console.error, Pe = console.group, De = console.groupCollapsed, Ie = console.groupEnd;
|
|
201
|
+
var r = {
|
|
202
|
+
configurable: !0,
|
|
203
|
+
enumerable: !0,
|
|
204
|
+
value: Ne,
|
|
205
|
+
writable: !0
|
|
206
|
+
};
|
|
207
|
+
Object.defineProperties(console, {
|
|
208
|
+
info: r,
|
|
209
|
+
log: r,
|
|
210
|
+
warn: r,
|
|
211
|
+
error: r,
|
|
212
|
+
group: r,
|
|
213
|
+
groupCollapsed: r,
|
|
214
|
+
groupEnd: r
|
|
215
|
+
});
|
|
216
|
+
}
|
|
217
|
+
G++;
|
|
218
|
+
}
|
|
219
|
+
}
|
|
220
|
+
function Ot() {
|
|
221
|
+
{
|
|
222
|
+
if (G--, G === 0) {
|
|
223
|
+
var r = {
|
|
224
|
+
configurable: !0,
|
|
225
|
+
enumerable: !0,
|
|
226
|
+
writable: !0
|
|
227
|
+
};
|
|
228
|
+
Object.defineProperties(console, {
|
|
229
|
+
log: A({}, r, {
|
|
230
|
+
value: Re
|
|
231
|
+
}),
|
|
232
|
+
info: A({}, r, {
|
|
233
|
+
value: Te
|
|
234
|
+
}),
|
|
235
|
+
warn: A({}, r, {
|
|
236
|
+
value: je
|
|
237
|
+
}),
|
|
238
|
+
error: A({}, r, {
|
|
239
|
+
value: Oe
|
|
240
|
+
}),
|
|
241
|
+
group: A({}, r, {
|
|
242
|
+
value: Pe
|
|
243
|
+
}),
|
|
244
|
+
groupCollapsed: A({}, r, {
|
|
245
|
+
value: De
|
|
246
|
+
}),
|
|
247
|
+
groupEnd: A({}, r, {
|
|
248
|
+
value: Ie
|
|
249
|
+
})
|
|
250
|
+
});
|
|
251
|
+
}
|
|
252
|
+
G < 0 && C("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
|
|
253
|
+
}
|
|
254
|
+
}
|
|
255
|
+
var oe = q.ReactCurrentDispatcher, ce;
|
|
256
|
+
function J(r, a, o) {
|
|
257
|
+
{
|
|
258
|
+
if (ce === void 0)
|
|
259
|
+
try {
|
|
260
|
+
throw Error();
|
|
261
|
+
} catch (g) {
|
|
262
|
+
var d = g.stack.trim().match(/\n( *(at )?)/);
|
|
263
|
+
ce = d && d[1] || "";
|
|
264
|
+
}
|
|
265
|
+
return `
|
|
266
|
+
` + ce + r;
|
|
267
|
+
}
|
|
268
|
+
}
|
|
269
|
+
var ue = !1, K;
|
|
270
|
+
{
|
|
271
|
+
var Pt = typeof WeakMap == "function" ? WeakMap : Map;
|
|
272
|
+
K = new Pt();
|
|
273
|
+
}
|
|
274
|
+
function Le(r, a) {
|
|
275
|
+
if (!r || ue)
|
|
276
|
+
return "";
|
|
277
|
+
{
|
|
278
|
+
var o = K.get(r);
|
|
279
|
+
if (o !== void 0)
|
|
280
|
+
return o;
|
|
281
|
+
}
|
|
282
|
+
var d;
|
|
283
|
+
ue = !0;
|
|
284
|
+
var g = Error.prepareStackTrace;
|
|
285
|
+
Error.prepareStackTrace = void 0;
|
|
286
|
+
var v;
|
|
287
|
+
v = oe.current, oe.current = null, jt();
|
|
288
|
+
try {
|
|
289
|
+
if (a) {
|
|
290
|
+
var _ = function() {
|
|
291
|
+
throw Error();
|
|
292
|
+
};
|
|
293
|
+
if (Object.defineProperty(_.prototype, "props", {
|
|
294
|
+
set: function() {
|
|
295
|
+
throw Error();
|
|
296
|
+
}
|
|
297
|
+
}), typeof Reflect == "object" && Reflect.construct) {
|
|
298
|
+
try {
|
|
299
|
+
Reflect.construct(_, []);
|
|
300
|
+
} catch (I) {
|
|
301
|
+
d = I;
|
|
302
|
+
}
|
|
303
|
+
Reflect.construct(r, [], _);
|
|
304
|
+
} else {
|
|
305
|
+
try {
|
|
306
|
+
_.call();
|
|
307
|
+
} catch (I) {
|
|
308
|
+
d = I;
|
|
309
|
+
}
|
|
310
|
+
r.call(_.prototype);
|
|
311
|
+
}
|
|
312
|
+
} else {
|
|
313
|
+
try {
|
|
314
|
+
throw Error();
|
|
315
|
+
} catch (I) {
|
|
316
|
+
d = I;
|
|
317
|
+
}
|
|
318
|
+
r();
|
|
319
|
+
}
|
|
320
|
+
} catch (I) {
|
|
321
|
+
if (I && d && typeof I.stack == "string") {
|
|
322
|
+
for (var p = I.stack.split(`
|
|
323
|
+
`), R = d.stack.split(`
|
|
324
|
+
`), b = p.length - 1, w = R.length - 1; b >= 1 && w >= 0 && p[b] !== R[w]; )
|
|
325
|
+
w--;
|
|
326
|
+
for (; b >= 1 && w >= 0; b--, w--)
|
|
327
|
+
if (p[b] !== R[w]) {
|
|
328
|
+
if (b !== 1 || w !== 1)
|
|
329
|
+
do
|
|
330
|
+
if (b--, w--, w < 0 || p[b] !== R[w]) {
|
|
331
|
+
var T = `
|
|
332
|
+
` + p[b].replace(" at new ", " at ");
|
|
333
|
+
return r.displayName && T.includes("<anonymous>") && (T = T.replace("<anonymous>", r.displayName)), typeof r == "function" && K.set(r, T), T;
|
|
334
|
+
}
|
|
335
|
+
while (b >= 1 && w >= 0);
|
|
336
|
+
break;
|
|
337
|
+
}
|
|
338
|
+
}
|
|
339
|
+
} finally {
|
|
340
|
+
ue = !1, oe.current = v, Ot(), Error.prepareStackTrace = g;
|
|
341
|
+
}
|
|
342
|
+
var Y = r ? r.displayName || r.name : "", He = Y ? J(Y) : "";
|
|
343
|
+
return typeof r == "function" && K.set(r, He), He;
|
|
344
|
+
}
|
|
345
|
+
function Dt(r, a, o) {
|
|
346
|
+
return Le(r, !1);
|
|
347
|
+
}
|
|
348
|
+
function It(r) {
|
|
349
|
+
var a = r.prototype;
|
|
350
|
+
return !!(a && a.isReactComponent);
|
|
351
|
+
}
|
|
352
|
+
function z(r, a, o) {
|
|
353
|
+
if (r == null)
|
|
354
|
+
return "";
|
|
355
|
+
if (typeof r == "function")
|
|
356
|
+
return Le(r, It(r));
|
|
357
|
+
if (typeof r == "string")
|
|
358
|
+
return J(r);
|
|
359
|
+
switch (r) {
|
|
360
|
+
case m:
|
|
361
|
+
return J("Suspense");
|
|
362
|
+
case E:
|
|
363
|
+
return J("SuspenseList");
|
|
364
|
+
}
|
|
365
|
+
if (typeof r == "object")
|
|
366
|
+
switch (r.$$typeof) {
|
|
367
|
+
case f:
|
|
368
|
+
return Dt(r.render);
|
|
369
|
+
case y:
|
|
370
|
+
return z(r.type, a, o);
|
|
371
|
+
case j: {
|
|
372
|
+
var d = r, g = d._payload, v = d._init;
|
|
373
|
+
try {
|
|
374
|
+
return z(v(g), a, o);
|
|
375
|
+
} catch {
|
|
376
|
+
}
|
|
377
|
+
}
|
|
378
|
+
}
|
|
379
|
+
return "";
|
|
380
|
+
}
|
|
381
|
+
var Q = Object.prototype.hasOwnProperty, ke = {}, Ae = q.ReactDebugCurrentFrame;
|
|
382
|
+
function X(r) {
|
|
383
|
+
if (r) {
|
|
384
|
+
var a = r._owner, o = z(r.type, r._source, a ? a.type : null);
|
|
385
|
+
Ae.setExtraStackFrame(o);
|
|
386
|
+
} else
|
|
387
|
+
Ae.setExtraStackFrame(null);
|
|
388
|
+
}
|
|
389
|
+
function Nt(r, a, o, d, g) {
|
|
390
|
+
{
|
|
391
|
+
var v = Function.call.bind(Q);
|
|
392
|
+
for (var _ in r)
|
|
393
|
+
if (v(r, _)) {
|
|
394
|
+
var p = void 0;
|
|
395
|
+
try {
|
|
396
|
+
if (typeof r[_] != "function") {
|
|
397
|
+
var R = Error((d || "React class") + ": " + o + " type `" + _ + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof r[_] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
|
|
398
|
+
throw R.name = "Invariant Violation", R;
|
|
399
|
+
}
|
|
400
|
+
p = r[_](a, _, d, o, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
|
|
401
|
+
} catch (b) {
|
|
402
|
+
p = b;
|
|
403
|
+
}
|
|
404
|
+
p && !(p instanceof Error) && (X(g), C("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", d || "React class", o, _, typeof p), X(null)), p instanceof Error && !(p.message in ke) && (ke[p.message] = !0, X(g), C("Failed %s type: %s", o, p.message), X(null));
|
|
405
|
+
}
|
|
406
|
+
}
|
|
407
|
+
}
|
|
408
|
+
var Lt = Array.isArray;
|
|
409
|
+
function le(r) {
|
|
410
|
+
return Lt(r);
|
|
411
|
+
}
|
|
412
|
+
function kt(r) {
|
|
413
|
+
{
|
|
414
|
+
var a = typeof Symbol == "function" && Symbol.toStringTag, o = a && r[Symbol.toStringTag] || r.constructor.name || "Object";
|
|
415
|
+
return o;
|
|
416
|
+
}
|
|
417
|
+
}
|
|
418
|
+
function At(r) {
|
|
419
|
+
try {
|
|
420
|
+
return Ue(r), !1;
|
|
421
|
+
} catch {
|
|
422
|
+
return !0;
|
|
423
|
+
}
|
|
424
|
+
}
|
|
425
|
+
function Ue(r) {
|
|
426
|
+
return "" + r;
|
|
427
|
+
}
|
|
428
|
+
function Fe(r) {
|
|
429
|
+
if (At(r))
|
|
430
|
+
return C("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", kt(r)), Ue(r);
|
|
431
|
+
}
|
|
432
|
+
var V = q.ReactCurrentOwner, Ut = {
|
|
433
|
+
key: !0,
|
|
434
|
+
ref: !0,
|
|
435
|
+
__self: !0,
|
|
436
|
+
__source: !0
|
|
437
|
+
}, Me, qe, de;
|
|
438
|
+
de = {};
|
|
439
|
+
function Ft(r) {
|
|
440
|
+
if (Q.call(r, "ref")) {
|
|
441
|
+
var a = Object.getOwnPropertyDescriptor(r, "ref").get;
|
|
442
|
+
if (a && a.isReactWarning)
|
|
443
|
+
return !1;
|
|
444
|
+
}
|
|
445
|
+
return r.ref !== void 0;
|
|
446
|
+
}
|
|
447
|
+
function Mt(r) {
|
|
448
|
+
if (Q.call(r, "key")) {
|
|
449
|
+
var a = Object.getOwnPropertyDescriptor(r, "key").get;
|
|
450
|
+
if (a && a.isReactWarning)
|
|
451
|
+
return !1;
|
|
452
|
+
}
|
|
453
|
+
return r.key !== void 0;
|
|
454
|
+
}
|
|
455
|
+
function qt(r, a) {
|
|
456
|
+
if (typeof r.ref == "string" && V.current && a && V.current.stateNode !== a) {
|
|
457
|
+
var o = D(V.current.type);
|
|
458
|
+
de[o] || (C('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', D(V.current.type), r.ref), de[o] = !0);
|
|
459
|
+
}
|
|
460
|
+
}
|
|
461
|
+
function Bt(r, a) {
|
|
462
|
+
{
|
|
463
|
+
var o = function() {
|
|
464
|
+
Me || (Me = !0, C("%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://reactjs.org/link/special-props)", a));
|
|
465
|
+
};
|
|
466
|
+
o.isReactWarning = !0, Object.defineProperty(r, "key", {
|
|
467
|
+
get: o,
|
|
468
|
+
configurable: !0
|
|
469
|
+
});
|
|
470
|
+
}
|
|
471
|
+
}
|
|
472
|
+
function Yt(r, a) {
|
|
473
|
+
{
|
|
474
|
+
var o = function() {
|
|
475
|
+
qe || (qe = !0, C("%s: `ref` 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://reactjs.org/link/special-props)", a));
|
|
476
|
+
};
|
|
477
|
+
o.isReactWarning = !0, Object.defineProperty(r, "ref", {
|
|
478
|
+
get: o,
|
|
479
|
+
configurable: !0
|
|
480
|
+
});
|
|
481
|
+
}
|
|
482
|
+
}
|
|
483
|
+
var $t = function(r, a, o, d, g, v, _) {
|
|
484
|
+
var p = {
|
|
485
|
+
// This tag allows us to uniquely identify this as a React Element
|
|
486
|
+
$$typeof: e,
|
|
487
|
+
// Built-in properties that belong on the element
|
|
488
|
+
type: r,
|
|
489
|
+
key: a,
|
|
490
|
+
ref: o,
|
|
491
|
+
props: _,
|
|
492
|
+
// Record the component responsible for creating this element.
|
|
493
|
+
_owner: v
|
|
494
|
+
};
|
|
495
|
+
return p._store = {}, Object.defineProperty(p._store, "validated", {
|
|
496
|
+
configurable: !1,
|
|
497
|
+
enumerable: !1,
|
|
498
|
+
writable: !0,
|
|
499
|
+
value: !1
|
|
500
|
+
}), Object.defineProperty(p, "_self", {
|
|
501
|
+
configurable: !1,
|
|
502
|
+
enumerable: !1,
|
|
503
|
+
writable: !1,
|
|
504
|
+
value: d
|
|
505
|
+
}), Object.defineProperty(p, "_source", {
|
|
506
|
+
configurable: !1,
|
|
507
|
+
enumerable: !1,
|
|
508
|
+
writable: !1,
|
|
509
|
+
value: g
|
|
510
|
+
}), Object.freeze && (Object.freeze(p.props), Object.freeze(p)), p;
|
|
511
|
+
};
|
|
512
|
+
function Gt(r, a, o, d, g) {
|
|
513
|
+
{
|
|
514
|
+
var v, _ = {}, p = null, R = null;
|
|
515
|
+
o !== void 0 && (Fe(o), p = "" + o), Mt(a) && (Fe(a.key), p = "" + a.key), Ft(a) && (R = a.ref, qt(a, g));
|
|
516
|
+
for (v in a)
|
|
517
|
+
Q.call(a, v) && !Ut.hasOwnProperty(v) && (_[v] = a[v]);
|
|
518
|
+
if (r && r.defaultProps) {
|
|
519
|
+
var b = r.defaultProps;
|
|
520
|
+
for (v in b)
|
|
521
|
+
_[v] === void 0 && (_[v] = b[v]);
|
|
522
|
+
}
|
|
523
|
+
if (p || R) {
|
|
524
|
+
var w = typeof r == "function" ? r.displayName || r.name || "Unknown" : r;
|
|
525
|
+
p && Bt(_, w), R && Yt(_, w);
|
|
526
|
+
}
|
|
527
|
+
return $t(r, p, R, g, d, V.current, _);
|
|
528
|
+
}
|
|
529
|
+
}
|
|
530
|
+
var fe = q.ReactCurrentOwner, Be = q.ReactDebugCurrentFrame;
|
|
531
|
+
function B(r) {
|
|
532
|
+
if (r) {
|
|
533
|
+
var a = r._owner, o = z(r.type, r._source, a ? a.type : null);
|
|
534
|
+
Be.setExtraStackFrame(o);
|
|
535
|
+
} else
|
|
536
|
+
Be.setExtraStackFrame(null);
|
|
537
|
+
}
|
|
538
|
+
var pe;
|
|
539
|
+
pe = !1;
|
|
540
|
+
function he(r) {
|
|
541
|
+
return typeof r == "object" && r !== null && r.$$typeof === e;
|
|
542
|
+
}
|
|
543
|
+
function Ye() {
|
|
544
|
+
{
|
|
545
|
+
if (fe.current) {
|
|
546
|
+
var r = D(fe.current.type);
|
|
547
|
+
if (r)
|
|
548
|
+
return `
|
|
549
|
+
|
|
550
|
+
Check the render method of \`` + r + "`.";
|
|
551
|
+
}
|
|
552
|
+
return "";
|
|
553
|
+
}
|
|
554
|
+
}
|
|
555
|
+
function Vt(r) {
|
|
556
|
+
{
|
|
557
|
+
if (r !== void 0) {
|
|
558
|
+
var a = r.fileName.replace(/^.*[\\\/]/, ""), o = r.lineNumber;
|
|
559
|
+
return `
|
|
560
|
+
|
|
561
|
+
Check your code at ` + a + ":" + o + ".";
|
|
562
|
+
}
|
|
563
|
+
return "";
|
|
564
|
+
}
|
|
565
|
+
}
|
|
566
|
+
var $e = {};
|
|
567
|
+
function Wt(r) {
|
|
568
|
+
{
|
|
569
|
+
var a = Ye();
|
|
570
|
+
if (!a) {
|
|
571
|
+
var o = typeof r == "string" ? r : r.displayName || r.name;
|
|
572
|
+
o && (a = `
|
|
573
|
+
|
|
574
|
+
Check the top-level render call using <` + o + ">.");
|
|
575
|
+
}
|
|
576
|
+
return a;
|
|
577
|
+
}
|
|
578
|
+
}
|
|
579
|
+
function Ge(r, a) {
|
|
580
|
+
{
|
|
581
|
+
if (!r._store || r._store.validated || r.key != null)
|
|
582
|
+
return;
|
|
583
|
+
r._store.validated = !0;
|
|
584
|
+
var o = Wt(a);
|
|
585
|
+
if ($e[o])
|
|
586
|
+
return;
|
|
587
|
+
$e[o] = !0;
|
|
588
|
+
var d = "";
|
|
589
|
+
r && r._owner && r._owner !== fe.current && (d = " It was passed a child from " + D(r._owner.type) + "."), B(r), C('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', o, d), B(null);
|
|
590
|
+
}
|
|
591
|
+
}
|
|
592
|
+
function Ve(r, a) {
|
|
593
|
+
{
|
|
594
|
+
if (typeof r != "object")
|
|
595
|
+
return;
|
|
596
|
+
if (le(r))
|
|
597
|
+
for (var o = 0; o < r.length; o++) {
|
|
598
|
+
var d = r[o];
|
|
599
|
+
he(d) && Ge(d, a);
|
|
600
|
+
}
|
|
601
|
+
else if (he(r))
|
|
602
|
+
r._store && (r._store.validated = !0);
|
|
603
|
+
else if (r) {
|
|
604
|
+
var g = Et(r);
|
|
605
|
+
if (typeof g == "function" && g !== r.entries)
|
|
606
|
+
for (var v = g.call(r), _; !(_ = v.next()).done; )
|
|
607
|
+
he(_.value) && Ge(_.value, a);
|
|
608
|
+
}
|
|
609
|
+
}
|
|
610
|
+
}
|
|
611
|
+
function Ht(r) {
|
|
612
|
+
{
|
|
613
|
+
var a = r.type;
|
|
614
|
+
if (a == null || typeof a == "string")
|
|
615
|
+
return;
|
|
616
|
+
var o;
|
|
617
|
+
if (typeof a == "function")
|
|
618
|
+
o = a.propTypes;
|
|
619
|
+
else if (typeof a == "object" && (a.$$typeof === f || // Note: Memo only checks outer props here.
|
|
620
|
+
// Inner props are checked in the reconciler.
|
|
621
|
+
a.$$typeof === y))
|
|
622
|
+
o = a.propTypes;
|
|
623
|
+
else
|
|
624
|
+
return;
|
|
625
|
+
if (o) {
|
|
626
|
+
var d = D(a);
|
|
627
|
+
Nt(o, r.props, "prop", d, r);
|
|
628
|
+
} else if (a.PropTypes !== void 0 && !pe) {
|
|
629
|
+
pe = !0;
|
|
630
|
+
var g = D(a);
|
|
631
|
+
C("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", g || "Unknown");
|
|
632
|
+
}
|
|
633
|
+
typeof a.getDefaultProps == "function" && !a.getDefaultProps.isReactClassApproved && C("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
634
|
+
}
|
|
635
|
+
}
|
|
636
|
+
function Jt(r) {
|
|
637
|
+
{
|
|
638
|
+
for (var a = Object.keys(r.props), o = 0; o < a.length; o++) {
|
|
639
|
+
var d = a[o];
|
|
640
|
+
if (d !== "children" && d !== "key") {
|
|
641
|
+
B(r), C("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", d), B(null);
|
|
642
|
+
break;
|
|
643
|
+
}
|
|
644
|
+
}
|
|
645
|
+
r.ref !== null && (B(r), C("Invalid attribute `ref` supplied to `React.Fragment`."), B(null));
|
|
646
|
+
}
|
|
647
|
+
}
|
|
648
|
+
function We(r, a, o, d, g, v) {
|
|
649
|
+
{
|
|
650
|
+
var _ = Rt(r);
|
|
651
|
+
if (!_) {
|
|
652
|
+
var p = "";
|
|
653
|
+
(r === void 0 || typeof r == "object" && r !== null && Object.keys(r).length === 0) && (p += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
|
|
654
|
+
var R = Vt(g);
|
|
655
|
+
R ? p += R : p += Ye();
|
|
656
|
+
var b;
|
|
657
|
+
r === null ? b = "null" : le(r) ? b = "array" : r !== void 0 && r.$$typeof === e ? (b = "<" + (D(r.type) || "Unknown") + " />", p = " Did you accidentally export a JSX literal instead of a component?") : b = typeof r, C("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", b, p);
|
|
658
|
+
}
|
|
659
|
+
var w = Gt(r, a, o, g, v);
|
|
660
|
+
if (w == null)
|
|
661
|
+
return w;
|
|
662
|
+
if (_) {
|
|
663
|
+
var T = a.children;
|
|
664
|
+
if (T !== void 0)
|
|
665
|
+
if (d)
|
|
666
|
+
if (le(T)) {
|
|
667
|
+
for (var Y = 0; Y < T.length; Y++)
|
|
668
|
+
Ve(T[Y], r);
|
|
669
|
+
Object.freeze && Object.freeze(T);
|
|
670
|
+
} else
|
|
671
|
+
C("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
|
|
672
|
+
else
|
|
673
|
+
Ve(T, r);
|
|
674
|
+
}
|
|
675
|
+
return r === s ? Jt(w) : Ht(w), w;
|
|
676
|
+
}
|
|
677
|
+
}
|
|
678
|
+
function Kt(r, a, o) {
|
|
679
|
+
return We(r, a, o, !0);
|
|
680
|
+
}
|
|
681
|
+
function zt(r, a, o) {
|
|
682
|
+
return We(r, a, o, !1);
|
|
683
|
+
}
|
|
684
|
+
var Qt = zt, Xt = Kt;
|
|
685
|
+
H.Fragment = s, H.jsx = Qt, H.jsxs = Xt;
|
|
686
|
+
}()), H;
|
|
687
|
+
}
|
|
688
|
+
process.env.NODE_ENV === "production" ? ge.exports = fr() : ge.exports = pr();
|
|
689
|
+
var l = ge.exports;
|
|
690
|
+
function at(t) {
|
|
691
|
+
var e, n, s = "";
|
|
692
|
+
if (typeof t == "string" || typeof t == "number")
|
|
693
|
+
s += t;
|
|
694
|
+
else if (typeof t == "object")
|
|
695
|
+
if (Array.isArray(t)) {
|
|
696
|
+
var i = t.length;
|
|
697
|
+
for (e = 0; e < i; e++)
|
|
698
|
+
t[e] && (n = at(t[e])) && (s && (s += " "), s += n);
|
|
699
|
+
} else
|
|
700
|
+
for (n in t)
|
|
701
|
+
t[n] && (s && (s += " "), s += n);
|
|
702
|
+
return s;
|
|
703
|
+
}
|
|
704
|
+
function hr() {
|
|
705
|
+
for (var t, e, n = 0, s = "", i = arguments.length; n < i; n++)
|
|
706
|
+
(t = arguments[n]) && (e = at(t)) && (s && (s += " "), s += e);
|
|
707
|
+
return s;
|
|
708
|
+
}
|
|
709
|
+
const _r = {
|
|
710
|
+
logo: /* @__PURE__ */ l.jsx(tr, {}),
|
|
711
|
+
language: "en",
|
|
712
|
+
state: "initial",
|
|
713
|
+
sdk: void 0,
|
|
714
|
+
setLogo: () => {
|
|
715
|
+
}
|
|
716
|
+
}, gr = or(_r), se = () => cr(gr), M = (t) => /* @__PURE__ */ l.jsx(_e, { ...t });
|
|
717
|
+
var vr = "_1vg0oop0", mr = "_1vg0oop1", Er = "_1vg0oop2", Ze = "_1vg0oop3";
|
|
718
|
+
function br() {
|
|
719
|
+
const { logo: t } = se();
|
|
720
|
+
return /* @__PURE__ */ l.jsx("div", { className: Ze, children: typeof t == "string" ? /* @__PURE__ */ l.jsx("img", { src: t, alt: "logo", className: Ze }) : t });
|
|
721
|
+
}
|
|
722
|
+
function Sr() {
|
|
723
|
+
return /* @__PURE__ */ l.jsx(
|
|
724
|
+
M,
|
|
725
|
+
{
|
|
726
|
+
t: "footer.text",
|
|
727
|
+
variant: {
|
|
728
|
+
size: "xs",
|
|
729
|
+
weight: "semibold",
|
|
730
|
+
color: "placeholder"
|
|
731
|
+
}
|
|
732
|
+
}
|
|
733
|
+
);
|
|
734
|
+
}
|
|
735
|
+
function bn({ children: t, className: e, header: n = /* @__PURE__ */ l.jsx(br, {}), footer: s = /* @__PURE__ */ l.jsx(Sr, {}), style: i }) {
|
|
736
|
+
return /* @__PURE__ */ l.jsxs("article", { style: i, className: hr(vr, e), children: [
|
|
737
|
+
n && /* @__PURE__ */ l.jsx("header", { className: mr, children: n }),
|
|
738
|
+
/* @__PURE__ */ l.jsx("div", { children: t }),
|
|
739
|
+
s && /* @__PURE__ */ l.jsx("footer", { className: Er, children: s })
|
|
740
|
+
] });
|
|
741
|
+
}
|
|
742
|
+
function ot() {
|
|
743
|
+
return /* @__PURE__ */ l.jsx(be, { variant: "primary", children: /* @__PURE__ */ l.jsx(rr, {}) });
|
|
744
|
+
}
|
|
745
|
+
function Sn() {
|
|
746
|
+
return /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
|
|
747
|
+
/* @__PURE__ */ l.jsxs(ne, { space: "2", children: [
|
|
748
|
+
/* @__PURE__ */ l.jsx(Ke, { width: "75%", height: 24 }),
|
|
749
|
+
/* @__PURE__ */ l.jsx(Ke, { width: "50%", height: 16 })
|
|
750
|
+
] }),
|
|
751
|
+
/* @__PURE__ */ l.jsx(ot, {})
|
|
752
|
+
] });
|
|
753
|
+
}
|
|
754
|
+
function wr({ type: t }) {
|
|
755
|
+
return /* @__PURE__ */ l.jsx(be, { variant: t === "warning" ? "blue" : "red", shouldAnimate: !1, children: /* @__PURE__ */ l.jsx(nr, {}) });
|
|
756
|
+
}
|
|
757
|
+
function wn({ type: t, redirectUri: e }) {
|
|
758
|
+
return e && window.location.replace(e), /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
|
|
759
|
+
/* @__PURE__ */ l.jsxs(ne, { space: "0.25", children: [
|
|
760
|
+
/* @__PURE__ */ l.jsx(
|
|
761
|
+
M,
|
|
762
|
+
{
|
|
763
|
+
as: "h1",
|
|
764
|
+
variant: { size: "2xl-title", weight: "bold" },
|
|
765
|
+
t: "error.title"
|
|
766
|
+
}
|
|
767
|
+
),
|
|
768
|
+
/* @__PURE__ */ l.jsx(
|
|
769
|
+
M,
|
|
770
|
+
{
|
|
771
|
+
as: "h2",
|
|
772
|
+
t: "error.detail",
|
|
773
|
+
variant: { color: "contrast", weight: "semibold" }
|
|
774
|
+
}
|
|
775
|
+
)
|
|
776
|
+
] }),
|
|
777
|
+
/* @__PURE__ */ l.jsx(wr, { type: t })
|
|
778
|
+
] });
|
|
779
|
+
}
|
|
780
|
+
const yr = () => /* @__PURE__ */ l.jsx(be, { variant: "primary", children: /* @__PURE__ */ l.jsx("svg", { width: "21", height: "18", viewBox: "0 0 21 18", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ l.jsx(
|
|
781
|
+
"path",
|
|
782
|
+
{
|
|
783
|
+
fillRule: "evenodd",
|
|
784
|
+
clipRule: "evenodd",
|
|
785
|
+
d: "M19.8505 0.705985C20.6342 1.38283 20.7209 2.56684 20.044 3.35055L8.16908 17.1005C7.80192 17.5256 7.2635 17.7637 6.70195 17.7493C6.1404 17.7349 5.61489 17.4695 5.27002 17.0261L0.895049 11.4011C0.259296 10.5837 0.406547 9.4057 1.22394 8.76995C2.04134 8.13419 3.21935 8.28145 3.8551 9.09884L6.82592 12.9185L17.2059 0.89949C17.8828 0.115778 19.0668 0.0291434 19.8505 0.705985Z",
|
|
786
|
+
fill: "white"
|
|
787
|
+
}
|
|
788
|
+
) }) });
|
|
789
|
+
function yn({ redirectUri: t } = {}) {
|
|
790
|
+
return t && window.location.replace(t), /* @__PURE__ */ l.jsxs("article", { "data-testid": "sid-form-success-state", children: [
|
|
791
|
+
/* @__PURE__ */ l.jsx(M, { as: "h1", t: "success.title", variant: { size: "2xl-title", weight: "bold" } }),
|
|
792
|
+
/* @__PURE__ */ l.jsx(M, { as: "h2", t: "success.details", variant: { color: "contrast", weight: "semibold" } }),
|
|
793
|
+
/* @__PURE__ */ l.jsx(yr, {})
|
|
794
|
+
] });
|
|
795
|
+
}
|
|
796
|
+
var xr = "_8vopmj0", Cr = "_8vopmj2";
|
|
797
|
+
function Rr() {
|
|
798
|
+
const { language: t } = se();
|
|
799
|
+
return ur(() => dr(t), [t]);
|
|
800
|
+
}
|
|
801
|
+
function Tr(t) {
|
|
802
|
+
return `recover.password.validation.${t.failedRules[0].name}`;
|
|
803
|
+
}
|
|
804
|
+
function jr({
|
|
805
|
+
errorEvent: t,
|
|
806
|
+
password: e
|
|
807
|
+
}) {
|
|
808
|
+
const n = t.failedRules[0];
|
|
809
|
+
let s = "";
|
|
810
|
+
if (n.matchType === "must_not_match") {
|
|
811
|
+
const i = n.regexp.exec(e);
|
|
812
|
+
s = i !== null ? i[0] : "";
|
|
813
|
+
}
|
|
814
|
+
return s ? {
|
|
815
|
+
ILLEGAL_SEQUENCE: s
|
|
816
|
+
} : {};
|
|
817
|
+
}
|
|
818
|
+
function Or({ message: t }) {
|
|
819
|
+
return /* @__PURE__ */ l.jsx("span", { className: Cr, children: t });
|
|
820
|
+
}
|
|
821
|
+
function Pr() {
|
|
822
|
+
const t = Rr(), { sdk: e } = se(), [n, s] = Z(""), [i, c] = Z(""), [u, h] = Z(null), [f, m] = Z("initial");
|
|
823
|
+
it(() => {
|
|
824
|
+
const x = ($) => {
|
|
825
|
+
h(
|
|
826
|
+
ar(
|
|
827
|
+
t(Tr($)),
|
|
828
|
+
jr({ errorEvent: $, password: n })
|
|
829
|
+
)
|
|
830
|
+
), m("initial");
|
|
831
|
+
};
|
|
832
|
+
return e == null || e.subscribe("invalidPasswordSubmitted", x), () => {
|
|
833
|
+
e == null || e.unsubscribe("invalidPasswordSubmitted", x);
|
|
834
|
+
};
|
|
835
|
+
}, [t, e, n, h]);
|
|
836
|
+
const E = (x) => {
|
|
837
|
+
if (x.preventDefault(), !!e) {
|
|
838
|
+
if (!n || n !== i) {
|
|
839
|
+
h(t("recover.password.validation.passwordsDoNotMatch"));
|
|
840
|
+
return;
|
|
841
|
+
}
|
|
842
|
+
e.publish("passwordSubmitted", n), m("submitting");
|
|
843
|
+
}
|
|
844
|
+
}, y = (x) => {
|
|
845
|
+
s(x.target.value), h(null);
|
|
846
|
+
}, j = (x) => {
|
|
847
|
+
c(x.target.value), h(null);
|
|
848
|
+
};
|
|
849
|
+
return /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
|
|
850
|
+
/* @__PURE__ */ l.jsxs(ne, { space: "0.25", children: [
|
|
851
|
+
/* @__PURE__ */ l.jsx(_e, { as: "h1", variant: { size: "2xl-title", weight: "bold" }, t: "recover.password.title" }),
|
|
852
|
+
/* @__PURE__ */ l.jsx(_e, { variant: { color: "contrast", weight: "semibold" }, as: "h2", t: "recover.password.details" })
|
|
853
|
+
] }),
|
|
854
|
+
/* @__PURE__ */ l.jsxs("form", { onSubmit: E, children: [
|
|
855
|
+
/* @__PURE__ */ l.jsxs("div", { className: xr, children: [
|
|
856
|
+
/* @__PURE__ */ l.jsx(
|
|
857
|
+
ze,
|
|
858
|
+
{
|
|
859
|
+
id: "password-input",
|
|
860
|
+
label: t("recover.password.input.password.label"),
|
|
861
|
+
placeholder: t("recover.password.input.placeholder"),
|
|
862
|
+
name: "password",
|
|
863
|
+
value: n ?? "",
|
|
864
|
+
onChange: y,
|
|
865
|
+
error: !!u,
|
|
866
|
+
autoComplete: "new-password"
|
|
867
|
+
}
|
|
868
|
+
),
|
|
869
|
+
/* @__PURE__ */ l.jsx(
|
|
870
|
+
ze,
|
|
871
|
+
{
|
|
872
|
+
id: "password-input-confirm",
|
|
873
|
+
label: t("recover.password.input.confirmPassword.label"),
|
|
874
|
+
placeholder: t("recover.password.input.placeholder"),
|
|
875
|
+
name: "passwordConfirm",
|
|
876
|
+
value: i ?? "",
|
|
877
|
+
onChange: j,
|
|
878
|
+
className: sr({ marginTop: "4" }),
|
|
879
|
+
error: !!u,
|
|
880
|
+
autoComplete: "new-password"
|
|
881
|
+
}
|
|
882
|
+
),
|
|
883
|
+
u && /* @__PURE__ */ l.jsx(Or, { message: u })
|
|
884
|
+
] }),
|
|
885
|
+
/* @__PURE__ */ l.jsx(
|
|
886
|
+
ir,
|
|
887
|
+
{
|
|
888
|
+
type: "submit",
|
|
889
|
+
variant: "primary",
|
|
890
|
+
testId: "sid-form-initial-submit-button",
|
|
891
|
+
disabled: f === "submitting",
|
|
892
|
+
loading: f === "submitting",
|
|
893
|
+
children: t("recover.password.submit")
|
|
894
|
+
}
|
|
895
|
+
)
|
|
896
|
+
] })
|
|
897
|
+
] });
|
|
898
|
+
}
|
|
899
|
+
const Dr = Object.prototype.toString;
|
|
900
|
+
function Ir(t, e) {
|
|
901
|
+
return Dr.call(t) === `[object ${e}]`;
|
|
902
|
+
}
|
|
903
|
+
function ct(t) {
|
|
904
|
+
return Ir(t, "Object");
|
|
905
|
+
}
|
|
906
|
+
function Se(t) {
|
|
907
|
+
return !!(t && t.then && typeof t.then == "function");
|
|
908
|
+
}
|
|
909
|
+
function ee(t) {
|
|
910
|
+
return t && t.Math == Math ? t : void 0;
|
|
911
|
+
}
|
|
912
|
+
const O = typeof globalThis == "object" && ee(globalThis) || // eslint-disable-next-line no-restricted-globals
|
|
913
|
+
typeof window == "object" && ee(window) || typeof self == "object" && ee(self) || typeof global == "object" && ee(global) || /* @__PURE__ */ function() {
|
|
914
|
+
return this;
|
|
915
|
+
}() || {};
|
|
916
|
+
function ut(t, e, n) {
|
|
917
|
+
const s = n || O, i = s.__SENTRY__ = s.__SENTRY__ || {};
|
|
918
|
+
return i[t] || (i[t] = e());
|
|
919
|
+
}
|
|
920
|
+
const Nr = typeof __SENTRY_DEBUG__ > "u" || __SENTRY_DEBUG__, Lr = "Sentry Logger ", et = [
|
|
921
|
+
"debug",
|
|
922
|
+
"info",
|
|
923
|
+
"warn",
|
|
924
|
+
"error",
|
|
925
|
+
"log",
|
|
926
|
+
"assert",
|
|
927
|
+
"trace"
|
|
928
|
+
], tt = {};
|
|
929
|
+
function lt(t) {
|
|
930
|
+
if (!("console" in O))
|
|
931
|
+
return t();
|
|
932
|
+
const e = O.console, n = {}, s = Object.keys(tt);
|
|
933
|
+
s.forEach((i) => {
|
|
934
|
+
const c = tt[i];
|
|
935
|
+
n[i] = e[i], e[i] = c;
|
|
936
|
+
});
|
|
937
|
+
try {
|
|
938
|
+
return t();
|
|
939
|
+
} finally {
|
|
940
|
+
s.forEach((i) => {
|
|
941
|
+
e[i] = n[i];
|
|
942
|
+
});
|
|
943
|
+
}
|
|
944
|
+
}
|
|
945
|
+
function kr() {
|
|
946
|
+
let t = !1;
|
|
947
|
+
const e = {
|
|
948
|
+
enable: () => {
|
|
949
|
+
t = !0;
|
|
950
|
+
},
|
|
951
|
+
disable: () => {
|
|
952
|
+
t = !1;
|
|
953
|
+
},
|
|
954
|
+
isEnabled: () => t
|
|
955
|
+
};
|
|
956
|
+
return Nr ? et.forEach((n) => {
|
|
957
|
+
e[n] = (...s) => {
|
|
958
|
+
t && lt(() => {
|
|
959
|
+
O.console[n](`${Lr}[${n}]:`, ...s);
|
|
960
|
+
});
|
|
961
|
+
};
|
|
962
|
+
}) : et.forEach((n) => {
|
|
963
|
+
e[n] = () => {
|
|
964
|
+
};
|
|
965
|
+
}), e;
|
|
966
|
+
}
|
|
967
|
+
const k = kr();
|
|
968
|
+
function U(t) {
|
|
969
|
+
return ve(t, /* @__PURE__ */ new Map());
|
|
970
|
+
}
|
|
971
|
+
function ve(t, e) {
|
|
972
|
+
if (Ar(t)) {
|
|
973
|
+
const n = e.get(t);
|
|
974
|
+
if (n !== void 0)
|
|
975
|
+
return n;
|
|
976
|
+
const s = {};
|
|
977
|
+
e.set(t, s);
|
|
978
|
+
for (const i of Object.keys(t))
|
|
979
|
+
typeof t[i] < "u" && (s[i] = ve(t[i], e));
|
|
980
|
+
return s;
|
|
981
|
+
}
|
|
982
|
+
if (Array.isArray(t)) {
|
|
983
|
+
const n = e.get(t);
|
|
984
|
+
if (n !== void 0)
|
|
985
|
+
return n;
|
|
986
|
+
const s = [];
|
|
987
|
+
return e.set(t, s), t.forEach((i) => {
|
|
988
|
+
s.push(ve(i, e));
|
|
989
|
+
}), s;
|
|
990
|
+
}
|
|
991
|
+
return t;
|
|
992
|
+
}
|
|
993
|
+
function Ar(t) {
|
|
994
|
+
if (!ct(t))
|
|
995
|
+
return !1;
|
|
996
|
+
try {
|
|
997
|
+
const e = Object.getPrototypeOf(t).constructor.name;
|
|
998
|
+
return !e || e === "Object";
|
|
999
|
+
} catch {
|
|
1000
|
+
return !0;
|
|
1001
|
+
}
|
|
1002
|
+
}
|
|
1003
|
+
function P() {
|
|
1004
|
+
const t = O, e = t.crypto || t.msCrypto;
|
|
1005
|
+
let n = () => Math.random() * 16;
|
|
1006
|
+
try {
|
|
1007
|
+
if (e && e.randomUUID)
|
|
1008
|
+
return e.randomUUID().replace(/-/g, "");
|
|
1009
|
+
e && e.getRandomValues && (n = () => {
|
|
1010
|
+
const s = new Uint8Array(1);
|
|
1011
|
+
return e.getRandomValues(s), s[0];
|
|
1012
|
+
});
|
|
1013
|
+
} catch {
|
|
1014
|
+
}
|
|
1015
|
+
return ("10000000100040008000" + 1e11).replace(
|
|
1016
|
+
/[018]/g,
|
|
1017
|
+
(s) => (
|
|
1018
|
+
// eslint-disable-next-line no-bitwise
|
|
1019
|
+
(s ^ (n() & 15) >> s / 4).toString(16)
|
|
1020
|
+
)
|
|
1021
|
+
);
|
|
1022
|
+
}
|
|
1023
|
+
function Ur(t) {
|
|
1024
|
+
return Array.isArray(t) ? t : [t];
|
|
1025
|
+
}
|
|
1026
|
+
var N;
|
|
1027
|
+
(function(t) {
|
|
1028
|
+
t[t.PENDING = 0] = "PENDING";
|
|
1029
|
+
const n = 1;
|
|
1030
|
+
t[t.RESOLVED = n] = "RESOLVED";
|
|
1031
|
+
const s = 2;
|
|
1032
|
+
t[t.REJECTED = s] = "REJECTED";
|
|
1033
|
+
})(N || (N = {}));
|
|
1034
|
+
class L {
|
|
1035
|
+
constructor(e) {
|
|
1036
|
+
L.prototype.__init.call(this), L.prototype.__init2.call(this), L.prototype.__init3.call(this), L.prototype.__init4.call(this), this._state = N.PENDING, this._handlers = [];
|
|
1037
|
+
try {
|
|
1038
|
+
e(this._resolve, this._reject);
|
|
1039
|
+
} catch (n) {
|
|
1040
|
+
this._reject(n);
|
|
1041
|
+
}
|
|
1042
|
+
}
|
|
1043
|
+
/** JSDoc */
|
|
1044
|
+
then(e, n) {
|
|
1045
|
+
return new L((s, i) => {
|
|
1046
|
+
this._handlers.push([
|
|
1047
|
+
!1,
|
|
1048
|
+
(c) => {
|
|
1049
|
+
if (!e)
|
|
1050
|
+
s(c);
|
|
1051
|
+
else
|
|
1052
|
+
try {
|
|
1053
|
+
s(e(c));
|
|
1054
|
+
} catch (u) {
|
|
1055
|
+
i(u);
|
|
1056
|
+
}
|
|
1057
|
+
},
|
|
1058
|
+
(c) => {
|
|
1059
|
+
if (!n)
|
|
1060
|
+
i(c);
|
|
1061
|
+
else
|
|
1062
|
+
try {
|
|
1063
|
+
s(n(c));
|
|
1064
|
+
} catch (u) {
|
|
1065
|
+
i(u);
|
|
1066
|
+
}
|
|
1067
|
+
}
|
|
1068
|
+
]), this._executeHandlers();
|
|
1069
|
+
});
|
|
1070
|
+
}
|
|
1071
|
+
/** JSDoc */
|
|
1072
|
+
catch(e) {
|
|
1073
|
+
return this.then((n) => n, e);
|
|
1074
|
+
}
|
|
1075
|
+
/** JSDoc */
|
|
1076
|
+
finally(e) {
|
|
1077
|
+
return new L((n, s) => {
|
|
1078
|
+
let i, c;
|
|
1079
|
+
return this.then(
|
|
1080
|
+
(u) => {
|
|
1081
|
+
c = !1, i = u, e && e();
|
|
1082
|
+
},
|
|
1083
|
+
(u) => {
|
|
1084
|
+
c = !0, i = u, e && e();
|
|
1085
|
+
}
|
|
1086
|
+
).then(() => {
|
|
1087
|
+
if (c) {
|
|
1088
|
+
s(i);
|
|
1089
|
+
return;
|
|
1090
|
+
}
|
|
1091
|
+
n(i);
|
|
1092
|
+
});
|
|
1093
|
+
});
|
|
1094
|
+
}
|
|
1095
|
+
/** JSDoc */
|
|
1096
|
+
__init() {
|
|
1097
|
+
this._resolve = (e) => {
|
|
1098
|
+
this._setResult(N.RESOLVED, e);
|
|
1099
|
+
};
|
|
1100
|
+
}
|
|
1101
|
+
/** JSDoc */
|
|
1102
|
+
__init2() {
|
|
1103
|
+
this._reject = (e) => {
|
|
1104
|
+
this._setResult(N.REJECTED, e);
|
|
1105
|
+
};
|
|
1106
|
+
}
|
|
1107
|
+
/** JSDoc */
|
|
1108
|
+
__init3() {
|
|
1109
|
+
this._setResult = (e, n) => {
|
|
1110
|
+
if (this._state === N.PENDING) {
|
|
1111
|
+
if (Se(n)) {
|
|
1112
|
+
n.then(this._resolve, this._reject);
|
|
1113
|
+
return;
|
|
1114
|
+
}
|
|
1115
|
+
this._state = e, this._value = n, this._executeHandlers();
|
|
1116
|
+
}
|
|
1117
|
+
};
|
|
1118
|
+
}
|
|
1119
|
+
/** JSDoc */
|
|
1120
|
+
__init4() {
|
|
1121
|
+
this._executeHandlers = () => {
|
|
1122
|
+
if (this._state === N.PENDING)
|
|
1123
|
+
return;
|
|
1124
|
+
const e = this._handlers.slice();
|
|
1125
|
+
this._handlers = [], e.forEach((n) => {
|
|
1126
|
+
n[0] || (this._state === N.RESOLVED && n[1](this._value), this._state === N.REJECTED && n[2](this._value), n[0] = !0);
|
|
1127
|
+
});
|
|
1128
|
+
};
|
|
1129
|
+
}
|
|
1130
|
+
}
|
|
1131
|
+
const dt = 1e3;
|
|
1132
|
+
function we() {
|
|
1133
|
+
return Date.now() / dt;
|
|
1134
|
+
}
|
|
1135
|
+
function Fr() {
|
|
1136
|
+
const { performance: t } = O;
|
|
1137
|
+
if (!t || !t.now)
|
|
1138
|
+
return we;
|
|
1139
|
+
const e = Date.now() - t.now(), n = t.timeOrigin == null ? e : t.timeOrigin;
|
|
1140
|
+
return () => (n + t.now()) / dt;
|
|
1141
|
+
}
|
|
1142
|
+
const ft = Fr();
|
|
1143
|
+
(() => {
|
|
1144
|
+
const { performance: t } = O;
|
|
1145
|
+
if (!t || !t.now)
|
|
1146
|
+
return;
|
|
1147
|
+
const e = 3600 * 1e3, n = t.now(), s = Date.now(), i = t.timeOrigin ? Math.abs(t.timeOrigin + n - s) : e, c = i < e, u = t.timing && t.timing.navigationStart, f = typeof u == "number" ? Math.abs(u + n - s) : e, m = f < e;
|
|
1148
|
+
return c || m ? i <= f ? t.timeOrigin : u : s;
|
|
1149
|
+
})();
|
|
1150
|
+
const te = typeof __SENTRY_DEBUG__ > "u" || __SENTRY_DEBUG__, pt = "production";
|
|
1151
|
+
function Mr() {
|
|
1152
|
+
return ut("globalEventProcessors", () => []);
|
|
1153
|
+
}
|
|
1154
|
+
function me(t, e, n, s = 0) {
|
|
1155
|
+
return new L((i, c) => {
|
|
1156
|
+
const u = t[s];
|
|
1157
|
+
if (e === null || typeof u != "function")
|
|
1158
|
+
i(e);
|
|
1159
|
+
else {
|
|
1160
|
+
const h = u({ ...e }, n);
|
|
1161
|
+
te && u.id && h === null && k.log(`Event processor "${u.id}" dropped event`), Se(h) ? h.then((f) => me(t, f, n, s + 1).then(i)).then(null, c) : me(t, h, n, s + 1).then(i).then(null, c);
|
|
1162
|
+
}
|
|
1163
|
+
});
|
|
1164
|
+
}
|
|
1165
|
+
function qr(t) {
|
|
1166
|
+
const e = ft(), n = {
|
|
1167
|
+
sid: P(),
|
|
1168
|
+
init: !0,
|
|
1169
|
+
timestamp: e,
|
|
1170
|
+
started: e,
|
|
1171
|
+
duration: 0,
|
|
1172
|
+
status: "ok",
|
|
1173
|
+
errors: 0,
|
|
1174
|
+
ignoreDuration: !1,
|
|
1175
|
+
toJSON: () => Yr(n)
|
|
1176
|
+
};
|
|
1177
|
+
return t && ie(n, t), n;
|
|
1178
|
+
}
|
|
1179
|
+
function ie(t, e = {}) {
|
|
1180
|
+
if (e.user && (!t.ipAddress && e.user.ip_address && (t.ipAddress = e.user.ip_address), !t.did && !e.did && (t.did = e.user.id || e.user.email || e.user.username)), t.timestamp = e.timestamp || ft(), e.abnormal_mechanism && (t.abnormal_mechanism = e.abnormal_mechanism), e.ignoreDuration && (t.ignoreDuration = e.ignoreDuration), e.sid && (t.sid = e.sid.length === 32 ? e.sid : P()), e.init !== void 0 && (t.init = e.init), !t.did && e.did && (t.did = `${e.did}`), typeof e.started == "number" && (t.started = e.started), t.ignoreDuration)
|
|
1181
|
+
t.duration = void 0;
|
|
1182
|
+
else if (typeof e.duration == "number")
|
|
1183
|
+
t.duration = e.duration;
|
|
1184
|
+
else {
|
|
1185
|
+
const n = t.timestamp - t.started;
|
|
1186
|
+
t.duration = n >= 0 ? n : 0;
|
|
1187
|
+
}
|
|
1188
|
+
e.release && (t.release = e.release), e.environment && (t.environment = e.environment), !t.ipAddress && e.ipAddress && (t.ipAddress = e.ipAddress), !t.userAgent && e.userAgent && (t.userAgent = e.userAgent), typeof e.errors == "number" && (t.errors = e.errors), e.status && (t.status = e.status);
|
|
1189
|
+
}
|
|
1190
|
+
function Br(t, e) {
|
|
1191
|
+
let n = {};
|
|
1192
|
+
e ? n = { status: e } : t.status === "ok" && (n = { status: "exited" }), ie(t, n);
|
|
1193
|
+
}
|
|
1194
|
+
function Yr(t) {
|
|
1195
|
+
return U({
|
|
1196
|
+
sid: `${t.sid}`,
|
|
1197
|
+
init: t.init,
|
|
1198
|
+
// Make sure that sec is converted to ms for date constructor
|
|
1199
|
+
started: new Date(t.started * 1e3).toISOString(),
|
|
1200
|
+
timestamp: new Date(t.timestamp * 1e3).toISOString(),
|
|
1201
|
+
status: t.status,
|
|
1202
|
+
errors: t.errors,
|
|
1203
|
+
did: typeof t.did == "number" || typeof t.did == "string" ? `${t.did}` : void 0,
|
|
1204
|
+
duration: t.duration,
|
|
1205
|
+
abnormal_mechanism: t.abnormal_mechanism,
|
|
1206
|
+
attrs: {
|
|
1207
|
+
release: t.release,
|
|
1208
|
+
environment: t.environment,
|
|
1209
|
+
ip_address: t.ipAddress,
|
|
1210
|
+
user_agent: t.userAgent
|
|
1211
|
+
}
|
|
1212
|
+
});
|
|
1213
|
+
}
|
|
1214
|
+
const $r = 1;
|
|
1215
|
+
function Gr(t) {
|
|
1216
|
+
const { spanId: e, traceId: n } = t.spanContext(), { data: s, op: i, parent_span_id: c, status: u, tags: h, origin: f } = re(t);
|
|
1217
|
+
return U({
|
|
1218
|
+
data: s,
|
|
1219
|
+
op: i,
|
|
1220
|
+
parent_span_id: c,
|
|
1221
|
+
span_id: e,
|
|
1222
|
+
status: u,
|
|
1223
|
+
tags: h,
|
|
1224
|
+
trace_id: n,
|
|
1225
|
+
origin: f
|
|
1226
|
+
});
|
|
1227
|
+
}
|
|
1228
|
+
function re(t) {
|
|
1229
|
+
return Vr(t) ? t.getSpanJSON() : typeof t.toJSON == "function" ? t.toJSON() : {};
|
|
1230
|
+
}
|
|
1231
|
+
function Vr(t) {
|
|
1232
|
+
return typeof t.getSpanJSON == "function";
|
|
1233
|
+
}
|
|
1234
|
+
function Wr(t) {
|
|
1235
|
+
const { traceFlags: e } = t.spanContext();
|
|
1236
|
+
return !!(e & $r);
|
|
1237
|
+
}
|
|
1238
|
+
function Hr(t) {
|
|
1239
|
+
if (t)
|
|
1240
|
+
return Jr(t) ? { captureContext: t } : zr(t) ? {
|
|
1241
|
+
captureContext: t
|
|
1242
|
+
} : t;
|
|
1243
|
+
}
|
|
1244
|
+
function Jr(t) {
|
|
1245
|
+
return t instanceof F || typeof t == "function";
|
|
1246
|
+
}
|
|
1247
|
+
const Kr = [
|
|
1248
|
+
"user",
|
|
1249
|
+
"level",
|
|
1250
|
+
"extra",
|
|
1251
|
+
"contexts",
|
|
1252
|
+
"tags",
|
|
1253
|
+
"fingerprint",
|
|
1254
|
+
"requestSession",
|
|
1255
|
+
"propagationContext"
|
|
1256
|
+
];
|
|
1257
|
+
function zr(t) {
|
|
1258
|
+
return Object.keys(t).some((e) => Kr.includes(e));
|
|
1259
|
+
}
|
|
1260
|
+
function Qr(t, e) {
|
|
1261
|
+
return ye().captureException(t, Hr(e));
|
|
1262
|
+
}
|
|
1263
|
+
function Xr() {
|
|
1264
|
+
return ye().getClient();
|
|
1265
|
+
}
|
|
1266
|
+
function Zr() {
|
|
1267
|
+
return ye().getScope();
|
|
1268
|
+
}
|
|
1269
|
+
function ht(t) {
|
|
1270
|
+
return t.transaction;
|
|
1271
|
+
}
|
|
1272
|
+
function en(t, e, n) {
|
|
1273
|
+
const s = e.getOptions(), { publicKey: i } = e.getDsn() || {}, { segment: c } = n && n.getUser() || {}, u = U({
|
|
1274
|
+
environment: s.environment || pt,
|
|
1275
|
+
release: s.release,
|
|
1276
|
+
user_segment: c,
|
|
1277
|
+
public_key: i,
|
|
1278
|
+
trace_id: t
|
|
1279
|
+
});
|
|
1280
|
+
return e.emit && e.emit("createDsc", u), u;
|
|
1281
|
+
}
|
|
1282
|
+
function tn(t) {
|
|
1283
|
+
const e = Xr();
|
|
1284
|
+
if (!e)
|
|
1285
|
+
return {};
|
|
1286
|
+
const n = en(re(t).trace_id || "", e, Zr()), s = ht(t);
|
|
1287
|
+
if (!s)
|
|
1288
|
+
return n;
|
|
1289
|
+
const i = s && s._frozenDynamicSamplingContext;
|
|
1290
|
+
if (i)
|
|
1291
|
+
return i;
|
|
1292
|
+
const { sampleRate: c, source: u } = s.metadata;
|
|
1293
|
+
c != null && (n.sample_rate = `${c}`);
|
|
1294
|
+
const h = re(s);
|
|
1295
|
+
return u && u !== "url" && (n.transaction = h.description), n.sampled = String(Wr(s)), e.emit && e.emit("createDsc", n), n;
|
|
1296
|
+
}
|
|
1297
|
+
function rn(t, e) {
|
|
1298
|
+
const { fingerprint: n, span: s, breadcrumbs: i, sdkProcessingMetadata: c } = e;
|
|
1299
|
+
nn(t, e), s && on(t, s), cn(t, n), sn(t, i), an(t, c);
|
|
1300
|
+
}
|
|
1301
|
+
function nn(t, e) {
|
|
1302
|
+
const {
|
|
1303
|
+
extra: n,
|
|
1304
|
+
tags: s,
|
|
1305
|
+
user: i,
|
|
1306
|
+
contexts: c,
|
|
1307
|
+
level: u,
|
|
1308
|
+
// eslint-disable-next-line deprecation/deprecation
|
|
1309
|
+
transactionName: h
|
|
1310
|
+
} = e, f = U(n);
|
|
1311
|
+
f && Object.keys(f).length && (t.extra = { ...f, ...t.extra });
|
|
1312
|
+
const m = U(s);
|
|
1313
|
+
m && Object.keys(m).length && (t.tags = { ...m, ...t.tags });
|
|
1314
|
+
const E = U(i);
|
|
1315
|
+
E && Object.keys(E).length && (t.user = { ...E, ...t.user });
|
|
1316
|
+
const y = U(c);
|
|
1317
|
+
y && Object.keys(y).length && (t.contexts = { ...y, ...t.contexts }), u && (t.level = u), h && (t.transaction = h);
|
|
1318
|
+
}
|
|
1319
|
+
function sn(t, e) {
|
|
1320
|
+
const n = [...t.breadcrumbs || [], ...e];
|
|
1321
|
+
t.breadcrumbs = n.length ? n : void 0;
|
|
1322
|
+
}
|
|
1323
|
+
function an(t, e) {
|
|
1324
|
+
t.sdkProcessingMetadata = {
|
|
1325
|
+
...t.sdkProcessingMetadata,
|
|
1326
|
+
...e
|
|
1327
|
+
};
|
|
1328
|
+
}
|
|
1329
|
+
function on(t, e) {
|
|
1330
|
+
t.contexts = { trace: Gr(e), ...t.contexts };
|
|
1331
|
+
const n = ht(e);
|
|
1332
|
+
if (n) {
|
|
1333
|
+
t.sdkProcessingMetadata = {
|
|
1334
|
+
dynamicSamplingContext: tn(e),
|
|
1335
|
+
...t.sdkProcessingMetadata
|
|
1336
|
+
};
|
|
1337
|
+
const s = re(n).description;
|
|
1338
|
+
s && (t.tags = { transaction: s, ...t.tags });
|
|
1339
|
+
}
|
|
1340
|
+
}
|
|
1341
|
+
function cn(t, e) {
|
|
1342
|
+
t.fingerprint = t.fingerprint ? Ur(t.fingerprint) : [], e && (t.fingerprint = t.fingerprint.concat(e)), t.fingerprint && !t.fingerprint.length && delete t.fingerprint;
|
|
1343
|
+
}
|
|
1344
|
+
const un = 100;
|
|
1345
|
+
class F {
|
|
1346
|
+
/** Flag if notifying is happening. */
|
|
1347
|
+
/** Callback for client to receive scope changes. */
|
|
1348
|
+
/** Callback list that will be called after {@link applyToEvent}. */
|
|
1349
|
+
/** Array of breadcrumbs. */
|
|
1350
|
+
/** User */
|
|
1351
|
+
/** Tags */
|
|
1352
|
+
/** Extra */
|
|
1353
|
+
/** Contexts */
|
|
1354
|
+
/** Attachments */
|
|
1355
|
+
/** Propagation Context for distributed tracing */
|
|
1356
|
+
/**
|
|
1357
|
+
* A place to stash data which is needed at some point in the SDK's event processing pipeline but which shouldn't get
|
|
1358
|
+
* sent to Sentry
|
|
1359
|
+
*/
|
|
1360
|
+
/** Fingerprint */
|
|
1361
|
+
/** Severity */
|
|
1362
|
+
// eslint-disable-next-line deprecation/deprecation
|
|
1363
|
+
/**
|
|
1364
|
+
* Transaction Name
|
|
1365
|
+
*/
|
|
1366
|
+
/** Span */
|
|
1367
|
+
/** Session */
|
|
1368
|
+
/** Request Mode Session Status */
|
|
1369
|
+
/** The client on this scope */
|
|
1370
|
+
// NOTE: Any field which gets added here should get added not only to the constructor but also to the `clone` method.
|
|
1371
|
+
constructor() {
|
|
1372
|
+
this._notifyingListeners = !1, this._scopeListeners = [], this._eventProcessors = [], this._breadcrumbs = [], this._attachments = [], this._user = {}, this._tags = {}, this._extra = {}, this._contexts = {}, this._sdkProcessingMetadata = {}, this._propagationContext = rt();
|
|
1373
|
+
}
|
|
1374
|
+
/**
|
|
1375
|
+
* Inherit values from the parent scope.
|
|
1376
|
+
* @deprecated Use `scope.clone()` and `new Scope()` instead.
|
|
1377
|
+
*/
|
|
1378
|
+
static clone(e) {
|
|
1379
|
+
return e ? e.clone() : new F();
|
|
1380
|
+
}
|
|
1381
|
+
/**
|
|
1382
|
+
* Clone this scope instance.
|
|
1383
|
+
*/
|
|
1384
|
+
clone() {
|
|
1385
|
+
const e = new F();
|
|
1386
|
+
return e._breadcrumbs = [...this._breadcrumbs], e._tags = { ...this._tags }, e._extra = { ...this._extra }, e._contexts = { ...this._contexts }, e._user = this._user, e._level = this._level, e._span = this._span, e._session = this._session, e._transactionName = this._transactionName, e._fingerprint = this._fingerprint, e._eventProcessors = [...this._eventProcessors], e._requestSession = this._requestSession, e._attachments = [...this._attachments], e._sdkProcessingMetadata = { ...this._sdkProcessingMetadata }, e._propagationContext = { ...this._propagationContext }, e._client = this._client, e;
|
|
1387
|
+
}
|
|
1388
|
+
/** Update the client on the scope. */
|
|
1389
|
+
setClient(e) {
|
|
1390
|
+
this._client = e;
|
|
1391
|
+
}
|
|
1392
|
+
/**
|
|
1393
|
+
* Get the client assigned to this scope.
|
|
1394
|
+
*
|
|
1395
|
+
* It is generally recommended to use the global function `Sentry.getClient()` instead, unless you know what you are doing.
|
|
1396
|
+
*/
|
|
1397
|
+
getClient() {
|
|
1398
|
+
return this._client;
|
|
1399
|
+
}
|
|
1400
|
+
/**
|
|
1401
|
+
* Add internal on change listener. Used for sub SDKs that need to store the scope.
|
|
1402
|
+
* @hidden
|
|
1403
|
+
*/
|
|
1404
|
+
addScopeListener(e) {
|
|
1405
|
+
this._scopeListeners.push(e);
|
|
1406
|
+
}
|
|
1407
|
+
/**
|
|
1408
|
+
* @inheritDoc
|
|
1409
|
+
*/
|
|
1410
|
+
addEventProcessor(e) {
|
|
1411
|
+
return this._eventProcessors.push(e), this;
|
|
1412
|
+
}
|
|
1413
|
+
/**
|
|
1414
|
+
* @inheritDoc
|
|
1415
|
+
*/
|
|
1416
|
+
setUser(e) {
|
|
1417
|
+
return this._user = e || {
|
|
1418
|
+
email: void 0,
|
|
1419
|
+
id: void 0,
|
|
1420
|
+
ip_address: void 0,
|
|
1421
|
+
segment: void 0,
|
|
1422
|
+
username: void 0
|
|
1423
|
+
}, this._session && ie(this._session, { user: e }), this._notifyScopeListeners(), this;
|
|
1424
|
+
}
|
|
1425
|
+
/**
|
|
1426
|
+
* @inheritDoc
|
|
1427
|
+
*/
|
|
1428
|
+
getUser() {
|
|
1429
|
+
return this._user;
|
|
1430
|
+
}
|
|
1431
|
+
/**
|
|
1432
|
+
* @inheritDoc
|
|
1433
|
+
*/
|
|
1434
|
+
getRequestSession() {
|
|
1435
|
+
return this._requestSession;
|
|
1436
|
+
}
|
|
1437
|
+
/**
|
|
1438
|
+
* @inheritDoc
|
|
1439
|
+
*/
|
|
1440
|
+
setRequestSession(e) {
|
|
1441
|
+
return this._requestSession = e, this;
|
|
1442
|
+
}
|
|
1443
|
+
/**
|
|
1444
|
+
* @inheritDoc
|
|
1445
|
+
*/
|
|
1446
|
+
setTags(e) {
|
|
1447
|
+
return this._tags = {
|
|
1448
|
+
...this._tags,
|
|
1449
|
+
...e
|
|
1450
|
+
}, this._notifyScopeListeners(), this;
|
|
1451
|
+
}
|
|
1452
|
+
/**
|
|
1453
|
+
* @inheritDoc
|
|
1454
|
+
*/
|
|
1455
|
+
setTag(e, n) {
|
|
1456
|
+
return this._tags = { ...this._tags, [e]: n }, this._notifyScopeListeners(), this;
|
|
1457
|
+
}
|
|
1458
|
+
/**
|
|
1459
|
+
* @inheritDoc
|
|
1460
|
+
*/
|
|
1461
|
+
setExtras(e) {
|
|
1462
|
+
return this._extra = {
|
|
1463
|
+
...this._extra,
|
|
1464
|
+
...e
|
|
1465
|
+
}, this._notifyScopeListeners(), this;
|
|
1466
|
+
}
|
|
1467
|
+
/**
|
|
1468
|
+
* @inheritDoc
|
|
1469
|
+
*/
|
|
1470
|
+
setExtra(e, n) {
|
|
1471
|
+
return this._extra = { ...this._extra, [e]: n }, this._notifyScopeListeners(), this;
|
|
1472
|
+
}
|
|
1473
|
+
/**
|
|
1474
|
+
* @inheritDoc
|
|
1475
|
+
*/
|
|
1476
|
+
setFingerprint(e) {
|
|
1477
|
+
return this._fingerprint = e, this._notifyScopeListeners(), this;
|
|
1478
|
+
}
|
|
1479
|
+
/**
|
|
1480
|
+
* @inheritDoc
|
|
1481
|
+
*/
|
|
1482
|
+
setLevel(e) {
|
|
1483
|
+
return this._level = e, this._notifyScopeListeners(), this;
|
|
1484
|
+
}
|
|
1485
|
+
/**
|
|
1486
|
+
* Sets the transaction name on the scope for future events.
|
|
1487
|
+
*/
|
|
1488
|
+
setTransactionName(e) {
|
|
1489
|
+
return this._transactionName = e, this._notifyScopeListeners(), this;
|
|
1490
|
+
}
|
|
1491
|
+
/**
|
|
1492
|
+
* @inheritDoc
|
|
1493
|
+
*/
|
|
1494
|
+
setContext(e, n) {
|
|
1495
|
+
return n === null ? delete this._contexts[e] : this._contexts[e] = n, this._notifyScopeListeners(), this;
|
|
1496
|
+
}
|
|
1497
|
+
/**
|
|
1498
|
+
* Sets the Span on the scope.
|
|
1499
|
+
* @param span Span
|
|
1500
|
+
* @deprecated Instead of setting a span on a scope, use `startSpan()`/`startSpanManual()` instead.
|
|
1501
|
+
*/
|
|
1502
|
+
setSpan(e) {
|
|
1503
|
+
return this._span = e, this._notifyScopeListeners(), this;
|
|
1504
|
+
}
|
|
1505
|
+
/**
|
|
1506
|
+
* Returns the `Span` if there is one.
|
|
1507
|
+
* @deprecated Use `getActiveSpan()` instead.
|
|
1508
|
+
*/
|
|
1509
|
+
getSpan() {
|
|
1510
|
+
return this._span;
|
|
1511
|
+
}
|
|
1512
|
+
/**
|
|
1513
|
+
* Returns the `Transaction` attached to the scope (if there is one).
|
|
1514
|
+
* @deprecated You should not rely on the transaction, but just use `startSpan()` APIs instead.
|
|
1515
|
+
*/
|
|
1516
|
+
getTransaction() {
|
|
1517
|
+
const e = this._span;
|
|
1518
|
+
return e && e.transaction;
|
|
1519
|
+
}
|
|
1520
|
+
/**
|
|
1521
|
+
* @inheritDoc
|
|
1522
|
+
*/
|
|
1523
|
+
setSession(e) {
|
|
1524
|
+
return e ? this._session = e : delete this._session, this._notifyScopeListeners(), this;
|
|
1525
|
+
}
|
|
1526
|
+
/**
|
|
1527
|
+
* @inheritDoc
|
|
1528
|
+
*/
|
|
1529
|
+
getSession() {
|
|
1530
|
+
return this._session;
|
|
1531
|
+
}
|
|
1532
|
+
/**
|
|
1533
|
+
* @inheritDoc
|
|
1534
|
+
*/
|
|
1535
|
+
update(e) {
|
|
1536
|
+
if (!e)
|
|
1537
|
+
return this;
|
|
1538
|
+
const n = typeof e == "function" ? e(this) : e;
|
|
1539
|
+
if (n instanceof F) {
|
|
1540
|
+
const s = n.getScopeData();
|
|
1541
|
+
this._tags = { ...this._tags, ...s.tags }, this._extra = { ...this._extra, ...s.extra }, this._contexts = { ...this._contexts, ...s.contexts }, s.user && Object.keys(s.user).length && (this._user = s.user), s.level && (this._level = s.level), s.fingerprint.length && (this._fingerprint = s.fingerprint), n.getRequestSession() && (this._requestSession = n.getRequestSession()), s.propagationContext && (this._propagationContext = s.propagationContext);
|
|
1542
|
+
} else if (ct(n)) {
|
|
1543
|
+
const s = e;
|
|
1544
|
+
this._tags = { ...this._tags, ...s.tags }, this._extra = { ...this._extra, ...s.extra }, this._contexts = { ...this._contexts, ...s.contexts }, s.user && (this._user = s.user), s.level && (this._level = s.level), s.fingerprint && (this._fingerprint = s.fingerprint), s.requestSession && (this._requestSession = s.requestSession), s.propagationContext && (this._propagationContext = s.propagationContext);
|
|
1545
|
+
}
|
|
1546
|
+
return this;
|
|
1547
|
+
}
|
|
1548
|
+
/**
|
|
1549
|
+
* @inheritDoc
|
|
1550
|
+
*/
|
|
1551
|
+
clear() {
|
|
1552
|
+
return this._breadcrumbs = [], this._tags = {}, this._extra = {}, this._user = {}, this._contexts = {}, this._level = void 0, this._transactionName = void 0, this._fingerprint = void 0, this._requestSession = void 0, this._span = void 0, this._session = void 0, this._notifyScopeListeners(), this._attachments = [], this._propagationContext = rt(), this;
|
|
1553
|
+
}
|
|
1554
|
+
/**
|
|
1555
|
+
* @inheritDoc
|
|
1556
|
+
*/
|
|
1557
|
+
addBreadcrumb(e, n) {
|
|
1558
|
+
const s = typeof n == "number" ? n : un;
|
|
1559
|
+
if (s <= 0)
|
|
1560
|
+
return this;
|
|
1561
|
+
const i = {
|
|
1562
|
+
timestamp: we(),
|
|
1563
|
+
...e
|
|
1564
|
+
}, c = this._breadcrumbs;
|
|
1565
|
+
return c.push(i), this._breadcrumbs = c.length > s ? c.slice(-s) : c, this._notifyScopeListeners(), this;
|
|
1566
|
+
}
|
|
1567
|
+
/**
|
|
1568
|
+
* @inheritDoc
|
|
1569
|
+
*/
|
|
1570
|
+
getLastBreadcrumb() {
|
|
1571
|
+
return this._breadcrumbs[this._breadcrumbs.length - 1];
|
|
1572
|
+
}
|
|
1573
|
+
/**
|
|
1574
|
+
* @inheritDoc
|
|
1575
|
+
*/
|
|
1576
|
+
clearBreadcrumbs() {
|
|
1577
|
+
return this._breadcrumbs = [], this._notifyScopeListeners(), this;
|
|
1578
|
+
}
|
|
1579
|
+
/**
|
|
1580
|
+
* @inheritDoc
|
|
1581
|
+
*/
|
|
1582
|
+
addAttachment(e) {
|
|
1583
|
+
return this._attachments.push(e), this;
|
|
1584
|
+
}
|
|
1585
|
+
/**
|
|
1586
|
+
* @inheritDoc
|
|
1587
|
+
* @deprecated Use `getScopeData()` instead.
|
|
1588
|
+
*/
|
|
1589
|
+
getAttachments() {
|
|
1590
|
+
return this.getScopeData().attachments;
|
|
1591
|
+
}
|
|
1592
|
+
/**
|
|
1593
|
+
* @inheritDoc
|
|
1594
|
+
*/
|
|
1595
|
+
clearAttachments() {
|
|
1596
|
+
return this._attachments = [], this;
|
|
1597
|
+
}
|
|
1598
|
+
/** @inheritDoc */
|
|
1599
|
+
getScopeData() {
|
|
1600
|
+
const {
|
|
1601
|
+
_breadcrumbs: e,
|
|
1602
|
+
_attachments: n,
|
|
1603
|
+
_contexts: s,
|
|
1604
|
+
_tags: i,
|
|
1605
|
+
_extra: c,
|
|
1606
|
+
_user: u,
|
|
1607
|
+
_level: h,
|
|
1608
|
+
_fingerprint: f,
|
|
1609
|
+
_eventProcessors: m,
|
|
1610
|
+
_propagationContext: E,
|
|
1611
|
+
_sdkProcessingMetadata: y,
|
|
1612
|
+
_transactionName: j,
|
|
1613
|
+
_span: x
|
|
1614
|
+
} = this;
|
|
1615
|
+
return {
|
|
1616
|
+
breadcrumbs: e,
|
|
1617
|
+
attachments: n,
|
|
1618
|
+
contexts: s,
|
|
1619
|
+
tags: i,
|
|
1620
|
+
extra: c,
|
|
1621
|
+
user: u,
|
|
1622
|
+
level: h,
|
|
1623
|
+
fingerprint: f || [],
|
|
1624
|
+
eventProcessors: m,
|
|
1625
|
+
propagationContext: E,
|
|
1626
|
+
sdkProcessingMetadata: y,
|
|
1627
|
+
transactionName: j,
|
|
1628
|
+
span: x
|
|
1629
|
+
};
|
|
1630
|
+
}
|
|
1631
|
+
/**
|
|
1632
|
+
* Applies data from the scope to the event and runs all event processors on it.
|
|
1633
|
+
*
|
|
1634
|
+
* @param event Event
|
|
1635
|
+
* @param hint Object containing additional information about the original exception, for use by the event processors.
|
|
1636
|
+
* @hidden
|
|
1637
|
+
* @deprecated Use `applyScopeDataToEvent()` directly
|
|
1638
|
+
*/
|
|
1639
|
+
applyToEvent(e, n = {}, s = []) {
|
|
1640
|
+
rn(e, this.getScopeData());
|
|
1641
|
+
const i = [
|
|
1642
|
+
...s,
|
|
1643
|
+
// eslint-disable-next-line deprecation/deprecation
|
|
1644
|
+
...Mr(),
|
|
1645
|
+
...this._eventProcessors
|
|
1646
|
+
];
|
|
1647
|
+
return me(i, e, n);
|
|
1648
|
+
}
|
|
1649
|
+
/**
|
|
1650
|
+
* Add data which will be accessible during event processing but won't get sent to Sentry
|
|
1651
|
+
*/
|
|
1652
|
+
setSDKProcessingMetadata(e) {
|
|
1653
|
+
return this._sdkProcessingMetadata = { ...this._sdkProcessingMetadata, ...e }, this;
|
|
1654
|
+
}
|
|
1655
|
+
/**
|
|
1656
|
+
* @inheritDoc
|
|
1657
|
+
*/
|
|
1658
|
+
setPropagationContext(e) {
|
|
1659
|
+
return this._propagationContext = e, this;
|
|
1660
|
+
}
|
|
1661
|
+
/**
|
|
1662
|
+
* @inheritDoc
|
|
1663
|
+
*/
|
|
1664
|
+
getPropagationContext() {
|
|
1665
|
+
return this._propagationContext;
|
|
1666
|
+
}
|
|
1667
|
+
/**
|
|
1668
|
+
* Capture an exception for this scope.
|
|
1669
|
+
*
|
|
1670
|
+
* @param exception The exception to capture.
|
|
1671
|
+
* @param hint Optinal additional data to attach to the Sentry event.
|
|
1672
|
+
* @returns the id of the captured Sentry event.
|
|
1673
|
+
*/
|
|
1674
|
+
captureException(e, n) {
|
|
1675
|
+
const s = n && n.event_id ? n.event_id : P();
|
|
1676
|
+
if (!this._client)
|
|
1677
|
+
return k.warn("No client configured on scope - will not capture exception!"), s;
|
|
1678
|
+
const i = new Error("Sentry syntheticException");
|
|
1679
|
+
return this._client.captureException(
|
|
1680
|
+
e,
|
|
1681
|
+
{
|
|
1682
|
+
originalException: e,
|
|
1683
|
+
syntheticException: i,
|
|
1684
|
+
...n,
|
|
1685
|
+
event_id: s
|
|
1686
|
+
},
|
|
1687
|
+
this
|
|
1688
|
+
), s;
|
|
1689
|
+
}
|
|
1690
|
+
/**
|
|
1691
|
+
* Capture a message for this scope.
|
|
1692
|
+
*
|
|
1693
|
+
* @param message The message to capture.
|
|
1694
|
+
* @param level An optional severity level to report the message with.
|
|
1695
|
+
* @param hint Optional additional data to attach to the Sentry event.
|
|
1696
|
+
* @returns the id of the captured message.
|
|
1697
|
+
*/
|
|
1698
|
+
captureMessage(e, n, s) {
|
|
1699
|
+
const i = s && s.event_id ? s.event_id : P();
|
|
1700
|
+
if (!this._client)
|
|
1701
|
+
return k.warn("No client configured on scope - will not capture message!"), i;
|
|
1702
|
+
const c = new Error(e);
|
|
1703
|
+
return this._client.captureMessage(
|
|
1704
|
+
e,
|
|
1705
|
+
n,
|
|
1706
|
+
{
|
|
1707
|
+
originalException: e,
|
|
1708
|
+
syntheticException: c,
|
|
1709
|
+
...s,
|
|
1710
|
+
event_id: i
|
|
1711
|
+
},
|
|
1712
|
+
this
|
|
1713
|
+
), i;
|
|
1714
|
+
}
|
|
1715
|
+
/**
|
|
1716
|
+
* Captures a manually created event for this scope and sends it to Sentry.
|
|
1717
|
+
*
|
|
1718
|
+
* @param exception The event to capture.
|
|
1719
|
+
* @param hint Optional additional data to attach to the Sentry event.
|
|
1720
|
+
* @returns the id of the captured event.
|
|
1721
|
+
*/
|
|
1722
|
+
captureEvent(e, n) {
|
|
1723
|
+
const s = n && n.event_id ? n.event_id : P();
|
|
1724
|
+
return this._client ? (this._client.captureEvent(e, { ...n, event_id: s }, this), s) : (k.warn("No client configured on scope - will not capture event!"), s);
|
|
1725
|
+
}
|
|
1726
|
+
/**
|
|
1727
|
+
* This will be called on every set call.
|
|
1728
|
+
*/
|
|
1729
|
+
_notifyScopeListeners() {
|
|
1730
|
+
this._notifyingListeners || (this._notifyingListeners = !0, this._scopeListeners.forEach((e) => {
|
|
1731
|
+
e(this);
|
|
1732
|
+
}), this._notifyingListeners = !1);
|
|
1733
|
+
}
|
|
1734
|
+
}
|
|
1735
|
+
function rt() {
|
|
1736
|
+
return {
|
|
1737
|
+
traceId: P(),
|
|
1738
|
+
spanId: P().substring(16)
|
|
1739
|
+
};
|
|
1740
|
+
}
|
|
1741
|
+
const ln = "7.108.0", _t = parseFloat(ln), dn = 100;
|
|
1742
|
+
class gt {
|
|
1743
|
+
/** Is a {@link Layer}[] containing the client and scope */
|
|
1744
|
+
/** Contains the last event id of a captured event. */
|
|
1745
|
+
/**
|
|
1746
|
+
* Creates a new instance of the hub, will push one {@link Layer} into the
|
|
1747
|
+
* internal stack on creation.
|
|
1748
|
+
*
|
|
1749
|
+
* @param client bound to the hub.
|
|
1750
|
+
* @param scope bound to the hub.
|
|
1751
|
+
* @param version number, higher number means higher priority.
|
|
1752
|
+
*
|
|
1753
|
+
* @deprecated Instantiation of Hub objects is deprecated and the constructor will be removed in version 8 of the SDK.
|
|
1754
|
+
*
|
|
1755
|
+
* If you are currently using the Hub for multi-client use like so:
|
|
1756
|
+
*
|
|
1757
|
+
* ```
|
|
1758
|
+
* // OLD
|
|
1759
|
+
* const hub = new Hub();
|
|
1760
|
+
* hub.bindClient(client);
|
|
1761
|
+
* makeMain(hub)
|
|
1762
|
+
* ```
|
|
1763
|
+
*
|
|
1764
|
+
* instead initialize the client as follows:
|
|
1765
|
+
*
|
|
1766
|
+
* ```
|
|
1767
|
+
* // NEW
|
|
1768
|
+
* Sentry.withIsolationScope(() => {
|
|
1769
|
+
* Sentry.setCurrentClient(client);
|
|
1770
|
+
* client.init();
|
|
1771
|
+
* });
|
|
1772
|
+
* ```
|
|
1773
|
+
*
|
|
1774
|
+
* If you are using the Hub to capture events like so:
|
|
1775
|
+
*
|
|
1776
|
+
* ```
|
|
1777
|
+
* // OLD
|
|
1778
|
+
* const client = new Client();
|
|
1779
|
+
* const hub = new Hub(client);
|
|
1780
|
+
* hub.captureException()
|
|
1781
|
+
* ```
|
|
1782
|
+
*
|
|
1783
|
+
* instead capture isolated events as follows:
|
|
1784
|
+
*
|
|
1785
|
+
* ```
|
|
1786
|
+
* // NEW
|
|
1787
|
+
* const client = new Client();
|
|
1788
|
+
* const scope = new Scope();
|
|
1789
|
+
* scope.setClient(client);
|
|
1790
|
+
* scope.captureException();
|
|
1791
|
+
* ```
|
|
1792
|
+
*/
|
|
1793
|
+
constructor(e, n, s, i = _t) {
|
|
1794
|
+
this._version = i;
|
|
1795
|
+
let c;
|
|
1796
|
+
n ? c = n : (c = new F(), c.setClient(e));
|
|
1797
|
+
let u;
|
|
1798
|
+
s ? u = s : (u = new F(), u.setClient(e)), this._stack = [{ scope: c }], e && this.bindClient(e), this._isolationScope = u;
|
|
1799
|
+
}
|
|
1800
|
+
/**
|
|
1801
|
+
* Checks if this hub's version is older than the given version.
|
|
1802
|
+
*
|
|
1803
|
+
* @param version A version number to compare to.
|
|
1804
|
+
* @return True if the given version is newer; otherwise false.
|
|
1805
|
+
*
|
|
1806
|
+
* @deprecated This will be removed in v8.
|
|
1807
|
+
*/
|
|
1808
|
+
isOlderThan(e) {
|
|
1809
|
+
return this._version < e;
|
|
1810
|
+
}
|
|
1811
|
+
/**
|
|
1812
|
+
* This binds the given client to the current scope.
|
|
1813
|
+
* @param client An SDK client (client) instance.
|
|
1814
|
+
*
|
|
1815
|
+
* @deprecated Use `initAndBind()` directly, or `setCurrentClient()` and/or `client.init()` instead.
|
|
1816
|
+
*/
|
|
1817
|
+
bindClient(e) {
|
|
1818
|
+
const n = this.getStackTop();
|
|
1819
|
+
n.client = e, n.scope.setClient(e), e && e.setupIntegrations && e.setupIntegrations();
|
|
1820
|
+
}
|
|
1821
|
+
/**
|
|
1822
|
+
* @inheritDoc
|
|
1823
|
+
*
|
|
1824
|
+
* @deprecated Use `withScope` instead.
|
|
1825
|
+
*/
|
|
1826
|
+
pushScope() {
|
|
1827
|
+
const e = this.getScope().clone();
|
|
1828
|
+
return this.getStack().push({
|
|
1829
|
+
// eslint-disable-next-line deprecation/deprecation
|
|
1830
|
+
client: this.getClient(),
|
|
1831
|
+
scope: e
|
|
1832
|
+
}), e;
|
|
1833
|
+
}
|
|
1834
|
+
/**
|
|
1835
|
+
* @inheritDoc
|
|
1836
|
+
*
|
|
1837
|
+
* @deprecated Use `withScope` instead.
|
|
1838
|
+
*/
|
|
1839
|
+
popScope() {
|
|
1840
|
+
return this.getStack().length <= 1 ? !1 : !!this.getStack().pop();
|
|
1841
|
+
}
|
|
1842
|
+
/**
|
|
1843
|
+
* @inheritDoc
|
|
1844
|
+
*
|
|
1845
|
+
* @deprecated Use `Sentry.withScope()` instead.
|
|
1846
|
+
*/
|
|
1847
|
+
withScope(e) {
|
|
1848
|
+
const n = this.pushScope();
|
|
1849
|
+
let s;
|
|
1850
|
+
try {
|
|
1851
|
+
s = e(n);
|
|
1852
|
+
} catch (i) {
|
|
1853
|
+
throw this.popScope(), i;
|
|
1854
|
+
}
|
|
1855
|
+
return Se(s) ? s.then(
|
|
1856
|
+
(i) => (this.popScope(), i),
|
|
1857
|
+
(i) => {
|
|
1858
|
+
throw this.popScope(), i;
|
|
1859
|
+
}
|
|
1860
|
+
) : (this.popScope(), s);
|
|
1861
|
+
}
|
|
1862
|
+
/**
|
|
1863
|
+
* @inheritDoc
|
|
1864
|
+
*
|
|
1865
|
+
* @deprecated Use `Sentry.getClient()` instead.
|
|
1866
|
+
*/
|
|
1867
|
+
getClient() {
|
|
1868
|
+
return this.getStackTop().client;
|
|
1869
|
+
}
|
|
1870
|
+
/**
|
|
1871
|
+
* Returns the scope of the top stack.
|
|
1872
|
+
*
|
|
1873
|
+
* @deprecated Use `Sentry.getCurrentScope()` instead.
|
|
1874
|
+
*/
|
|
1875
|
+
getScope() {
|
|
1876
|
+
return this.getStackTop().scope;
|
|
1877
|
+
}
|
|
1878
|
+
/**
|
|
1879
|
+
* @deprecated Use `Sentry.getIsolationScope()` instead.
|
|
1880
|
+
*/
|
|
1881
|
+
getIsolationScope() {
|
|
1882
|
+
return this._isolationScope;
|
|
1883
|
+
}
|
|
1884
|
+
/**
|
|
1885
|
+
* Returns the scope stack for domains or the process.
|
|
1886
|
+
* @deprecated This will be removed in v8.
|
|
1887
|
+
*/
|
|
1888
|
+
getStack() {
|
|
1889
|
+
return this._stack;
|
|
1890
|
+
}
|
|
1891
|
+
/**
|
|
1892
|
+
* Returns the topmost scope layer in the order domain > local > process.
|
|
1893
|
+
* @deprecated This will be removed in v8.
|
|
1894
|
+
*/
|
|
1895
|
+
getStackTop() {
|
|
1896
|
+
return this._stack[this._stack.length - 1];
|
|
1897
|
+
}
|
|
1898
|
+
/**
|
|
1899
|
+
* @inheritDoc
|
|
1900
|
+
*
|
|
1901
|
+
* @deprecated Use `Sentry.captureException()` instead.
|
|
1902
|
+
*/
|
|
1903
|
+
captureException(e, n) {
|
|
1904
|
+
const s = this._lastEventId = n && n.event_id ? n.event_id : P(), i = new Error("Sentry syntheticException");
|
|
1905
|
+
return this.getScope().captureException(e, {
|
|
1906
|
+
originalException: e,
|
|
1907
|
+
syntheticException: i,
|
|
1908
|
+
...n,
|
|
1909
|
+
event_id: s
|
|
1910
|
+
}), s;
|
|
1911
|
+
}
|
|
1912
|
+
/**
|
|
1913
|
+
* @inheritDoc
|
|
1914
|
+
*
|
|
1915
|
+
* @deprecated Use `Sentry.captureMessage()` instead.
|
|
1916
|
+
*/
|
|
1917
|
+
captureMessage(e, n, s) {
|
|
1918
|
+
const i = this._lastEventId = s && s.event_id ? s.event_id : P(), c = new Error(e);
|
|
1919
|
+
return this.getScope().captureMessage(e, n, {
|
|
1920
|
+
originalException: e,
|
|
1921
|
+
syntheticException: c,
|
|
1922
|
+
...s,
|
|
1923
|
+
event_id: i
|
|
1924
|
+
}), i;
|
|
1925
|
+
}
|
|
1926
|
+
/**
|
|
1927
|
+
* @inheritDoc
|
|
1928
|
+
*
|
|
1929
|
+
* @deprecated Use `Sentry.captureEvent()` instead.
|
|
1930
|
+
*/
|
|
1931
|
+
captureEvent(e, n) {
|
|
1932
|
+
const s = n && n.event_id ? n.event_id : P();
|
|
1933
|
+
return e.type || (this._lastEventId = s), this.getScope().captureEvent(e, { ...n, event_id: s }), s;
|
|
1934
|
+
}
|
|
1935
|
+
/**
|
|
1936
|
+
* @inheritDoc
|
|
1937
|
+
*
|
|
1938
|
+
* @deprecated This will be removed in v8.
|
|
1939
|
+
*/
|
|
1940
|
+
lastEventId() {
|
|
1941
|
+
return this._lastEventId;
|
|
1942
|
+
}
|
|
1943
|
+
/**
|
|
1944
|
+
* @inheritDoc
|
|
1945
|
+
*
|
|
1946
|
+
* @deprecated Use `Sentry.addBreadcrumb()` instead.
|
|
1947
|
+
*/
|
|
1948
|
+
addBreadcrumb(e, n) {
|
|
1949
|
+
const { scope: s, client: i } = this.getStackTop();
|
|
1950
|
+
if (!i)
|
|
1951
|
+
return;
|
|
1952
|
+
const { beforeBreadcrumb: c = null, maxBreadcrumbs: u = dn } = i.getOptions && i.getOptions() || {};
|
|
1953
|
+
if (u <= 0)
|
|
1954
|
+
return;
|
|
1955
|
+
const f = { timestamp: we(), ...e }, m = c ? lt(() => c(f, n)) : f;
|
|
1956
|
+
m !== null && (i.emit && i.emit("beforeAddBreadcrumb", m, n), s.addBreadcrumb(m, u));
|
|
1957
|
+
}
|
|
1958
|
+
/**
|
|
1959
|
+
* @inheritDoc
|
|
1960
|
+
* @deprecated Use `Sentry.setUser()` instead.
|
|
1961
|
+
*/
|
|
1962
|
+
setUser(e) {
|
|
1963
|
+
this.getScope().setUser(e), this.getIsolationScope().setUser(e);
|
|
1964
|
+
}
|
|
1965
|
+
/**
|
|
1966
|
+
* @inheritDoc
|
|
1967
|
+
* @deprecated Use `Sentry.setTags()` instead.
|
|
1968
|
+
*/
|
|
1969
|
+
setTags(e) {
|
|
1970
|
+
this.getScope().setTags(e), this.getIsolationScope().setTags(e);
|
|
1971
|
+
}
|
|
1972
|
+
/**
|
|
1973
|
+
* @inheritDoc
|
|
1974
|
+
* @deprecated Use `Sentry.setExtras()` instead.
|
|
1975
|
+
*/
|
|
1976
|
+
setExtras(e) {
|
|
1977
|
+
this.getScope().setExtras(e), this.getIsolationScope().setExtras(e);
|
|
1978
|
+
}
|
|
1979
|
+
/**
|
|
1980
|
+
* @inheritDoc
|
|
1981
|
+
* @deprecated Use `Sentry.setTag()` instead.
|
|
1982
|
+
*/
|
|
1983
|
+
setTag(e, n) {
|
|
1984
|
+
this.getScope().setTag(e, n), this.getIsolationScope().setTag(e, n);
|
|
1985
|
+
}
|
|
1986
|
+
/**
|
|
1987
|
+
* @inheritDoc
|
|
1988
|
+
* @deprecated Use `Sentry.setExtra()` instead.
|
|
1989
|
+
*/
|
|
1990
|
+
setExtra(e, n) {
|
|
1991
|
+
this.getScope().setExtra(e, n), this.getIsolationScope().setExtra(e, n);
|
|
1992
|
+
}
|
|
1993
|
+
/**
|
|
1994
|
+
* @inheritDoc
|
|
1995
|
+
* @deprecated Use `Sentry.setContext()` instead.
|
|
1996
|
+
*/
|
|
1997
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
1998
|
+
setContext(e, n) {
|
|
1999
|
+
this.getScope().setContext(e, n), this.getIsolationScope().setContext(e, n);
|
|
2000
|
+
}
|
|
2001
|
+
/**
|
|
2002
|
+
* @inheritDoc
|
|
2003
|
+
*
|
|
2004
|
+
* @deprecated Use `getScope()` directly.
|
|
2005
|
+
*/
|
|
2006
|
+
configureScope(e) {
|
|
2007
|
+
const { scope: n, client: s } = this.getStackTop();
|
|
2008
|
+
s && e(n);
|
|
2009
|
+
}
|
|
2010
|
+
/**
|
|
2011
|
+
* @inheritDoc
|
|
2012
|
+
*/
|
|
2013
|
+
run(e) {
|
|
2014
|
+
const n = nt(this);
|
|
2015
|
+
try {
|
|
2016
|
+
e(this);
|
|
2017
|
+
} finally {
|
|
2018
|
+
nt(n);
|
|
2019
|
+
}
|
|
2020
|
+
}
|
|
2021
|
+
/**
|
|
2022
|
+
* @inheritDoc
|
|
2023
|
+
* @deprecated Use `Sentry.getClient().getIntegrationByName()` instead.
|
|
2024
|
+
*/
|
|
2025
|
+
getIntegration(e) {
|
|
2026
|
+
const n = this.getClient();
|
|
2027
|
+
if (!n)
|
|
2028
|
+
return null;
|
|
2029
|
+
try {
|
|
2030
|
+
return n.getIntegration(e);
|
|
2031
|
+
} catch {
|
|
2032
|
+
return te && k.warn(`Cannot retrieve integration ${e.id} from the current Hub`), null;
|
|
2033
|
+
}
|
|
2034
|
+
}
|
|
2035
|
+
/**
|
|
2036
|
+
* Starts a new `Transaction` and returns it. This is the entry point to manual tracing instrumentation.
|
|
2037
|
+
*
|
|
2038
|
+
* A tree structure can be built by adding child spans to the transaction, and child spans to other spans. To start a
|
|
2039
|
+
* new child span within the transaction or any span, call the respective `.startChild()` method.
|
|
2040
|
+
*
|
|
2041
|
+
* Every child span must be finished before the transaction is finished, otherwise the unfinished spans are discarded.
|
|
2042
|
+
*
|
|
2043
|
+
* The transaction must be finished with a call to its `.end()` method, at which point the transaction with all its
|
|
2044
|
+
* finished child spans will be sent to Sentry.
|
|
2045
|
+
*
|
|
2046
|
+
* @param context Properties of the new `Transaction`.
|
|
2047
|
+
* @param customSamplingContext Information given to the transaction sampling function (along with context-dependent
|
|
2048
|
+
* default values). See {@link Options.tracesSampler}.
|
|
2049
|
+
*
|
|
2050
|
+
* @returns The transaction which was just started
|
|
2051
|
+
*
|
|
2052
|
+
* @deprecated Use `startSpan()`, `startSpanManual()` or `startInactiveSpan()` instead.
|
|
2053
|
+
*/
|
|
2054
|
+
startTransaction(e, n) {
|
|
2055
|
+
const s = this._callExtensionMethod("startTransaction", e, n);
|
|
2056
|
+
return te && !s && (this.getClient() ? k.warn(`Tracing extension 'startTransaction' has not been added. Call 'addTracingExtensions' before calling 'init':
|
|
2057
|
+
Sentry.addTracingExtensions();
|
|
2058
|
+
Sentry.init({...});
|
|
2059
|
+
`) : k.warn(
|
|
2060
|
+
"Tracing extension 'startTransaction' is missing. You should 'init' the SDK before calling 'startTransaction'"
|
|
2061
|
+
)), s;
|
|
2062
|
+
}
|
|
2063
|
+
/**
|
|
2064
|
+
* @inheritDoc
|
|
2065
|
+
* @deprecated Use `spanToTraceHeader()` instead.
|
|
2066
|
+
*/
|
|
2067
|
+
traceHeaders() {
|
|
2068
|
+
return this._callExtensionMethod("traceHeaders");
|
|
2069
|
+
}
|
|
2070
|
+
/**
|
|
2071
|
+
* @inheritDoc
|
|
2072
|
+
*
|
|
2073
|
+
* @deprecated Use top level `captureSession` instead.
|
|
2074
|
+
*/
|
|
2075
|
+
captureSession(e = !1) {
|
|
2076
|
+
if (e)
|
|
2077
|
+
return this.endSession();
|
|
2078
|
+
this._sendSessionUpdate();
|
|
2079
|
+
}
|
|
2080
|
+
/**
|
|
2081
|
+
* @inheritDoc
|
|
2082
|
+
* @deprecated Use top level `endSession` instead.
|
|
2083
|
+
*/
|
|
2084
|
+
endSession() {
|
|
2085
|
+
const n = this.getStackTop().scope, s = n.getSession();
|
|
2086
|
+
s && Br(s), this._sendSessionUpdate(), n.setSession();
|
|
2087
|
+
}
|
|
2088
|
+
/**
|
|
2089
|
+
* @inheritDoc
|
|
2090
|
+
* @deprecated Use top level `startSession` instead.
|
|
2091
|
+
*/
|
|
2092
|
+
startSession(e) {
|
|
2093
|
+
const { scope: n, client: s } = this.getStackTop(), { release: i, environment: c = pt } = s && s.getOptions() || {}, { userAgent: u } = O.navigator || {}, h = qr({
|
|
2094
|
+
release: i,
|
|
2095
|
+
environment: c,
|
|
2096
|
+
user: n.getUser(),
|
|
2097
|
+
...u && { userAgent: u },
|
|
2098
|
+
...e
|
|
2099
|
+
}), f = n.getSession && n.getSession();
|
|
2100
|
+
return f && f.status === "ok" && ie(f, { status: "exited" }), this.endSession(), n.setSession(h), h;
|
|
2101
|
+
}
|
|
2102
|
+
/**
|
|
2103
|
+
* Returns if default PII should be sent to Sentry and propagated in ourgoing requests
|
|
2104
|
+
* when Tracing is used.
|
|
2105
|
+
*
|
|
2106
|
+
* @deprecated Use top-level `getClient().getOptions().sendDefaultPii` instead. This function
|
|
2107
|
+
* only unnecessarily increased API surface but only wrapped accessing the option.
|
|
2108
|
+
*/
|
|
2109
|
+
shouldSendDefaultPii() {
|
|
2110
|
+
const e = this.getClient(), n = e && e.getOptions();
|
|
2111
|
+
return !!(n && n.sendDefaultPii);
|
|
2112
|
+
}
|
|
2113
|
+
/**
|
|
2114
|
+
* Sends the current Session on the scope
|
|
2115
|
+
*/
|
|
2116
|
+
_sendSessionUpdate() {
|
|
2117
|
+
const { scope: e, client: n } = this.getStackTop(), s = e.getSession();
|
|
2118
|
+
s && n && n.captureSession && n.captureSession(s);
|
|
2119
|
+
}
|
|
2120
|
+
/**
|
|
2121
|
+
* Calls global extension method and binding current instance to the function call
|
|
2122
|
+
*/
|
|
2123
|
+
// @ts-expect-error Function lacks ending return statement and return type does not include 'undefined'. ts(2366)
|
|
2124
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
2125
|
+
_callExtensionMethod(e, ...n) {
|
|
2126
|
+
const i = ae().__SENTRY__;
|
|
2127
|
+
if (i && i.extensions && typeof i.extensions[e] == "function")
|
|
2128
|
+
return i.extensions[e].apply(this, n);
|
|
2129
|
+
te && k.warn(`Extension method ${e} couldn't be found, doing nothing.`);
|
|
2130
|
+
}
|
|
2131
|
+
}
|
|
2132
|
+
function ae() {
|
|
2133
|
+
return O.__SENTRY__ = O.__SENTRY__ || {
|
|
2134
|
+
extensions: {},
|
|
2135
|
+
hub: void 0
|
|
2136
|
+
}, O;
|
|
2137
|
+
}
|
|
2138
|
+
function nt(t) {
|
|
2139
|
+
const e = ae(), n = Ee(e);
|
|
2140
|
+
return vt(e, t), n;
|
|
2141
|
+
}
|
|
2142
|
+
function ye() {
|
|
2143
|
+
const t = ae();
|
|
2144
|
+
if (t.__SENTRY__ && t.__SENTRY__.acs) {
|
|
2145
|
+
const e = t.__SENTRY__.acs.getCurrentHub();
|
|
2146
|
+
if (e)
|
|
2147
|
+
return e;
|
|
2148
|
+
}
|
|
2149
|
+
return fn(t);
|
|
2150
|
+
}
|
|
2151
|
+
function fn(t = ae()) {
|
|
2152
|
+
return (!pn(t) || // eslint-disable-next-line deprecation/deprecation
|
|
2153
|
+
Ee(t).isOlderThan(_t)) && vt(t, new gt()), Ee(t);
|
|
2154
|
+
}
|
|
2155
|
+
function pn(t) {
|
|
2156
|
+
return !!(t && t.__SENTRY__ && t.__SENTRY__.hub);
|
|
2157
|
+
}
|
|
2158
|
+
function Ee(t) {
|
|
2159
|
+
return ut("hub", () => new gt(), t);
|
|
2160
|
+
}
|
|
2161
|
+
function vt(t, e) {
|
|
2162
|
+
if (!t)
|
|
2163
|
+
return !1;
|
|
2164
|
+
const n = t.__SENTRY__ = t.__SENTRY__ || {};
|
|
2165
|
+
return n.hub = e, !0;
|
|
2166
|
+
}
|
|
2167
|
+
class hn extends Error {
|
|
2168
|
+
constructor(n) {
|
|
2169
|
+
super(n.length > 0 ? n[0].message : "Unknown SlashID error");
|
|
2170
|
+
Je(this, "errors");
|
|
2171
|
+
this.errors = n;
|
|
2172
|
+
}
|
|
2173
|
+
}
|
|
2174
|
+
function _n(t) {
|
|
2175
|
+
return !!(typeof t == "object" && t !== null && "errors" in t && Array.isArray(t.errors));
|
|
2176
|
+
}
|
|
2177
|
+
function gn(t) {
|
|
2178
|
+
if (t instanceof Error)
|
|
2179
|
+
return t;
|
|
2180
|
+
if (_n(t))
|
|
2181
|
+
return new hn(t.errors);
|
|
2182
|
+
let e = "[Unable to stringify the thrown value]";
|
|
2183
|
+
try {
|
|
2184
|
+
e = JSON.stringify(t);
|
|
2185
|
+
} catch {
|
|
2186
|
+
}
|
|
2187
|
+
return new Error(
|
|
2188
|
+
`This value was thrown as is, not through an Error: ${e}`
|
|
2189
|
+
);
|
|
2190
|
+
}
|
|
2191
|
+
function xn({ onSuccess: t, onError: e, flowType: n, onRedirectDiscovered: s }) {
|
|
2192
|
+
const { sdk: i } = se();
|
|
2193
|
+
return it(() => {
|
|
2194
|
+
if (!i)
|
|
2195
|
+
return;
|
|
2196
|
+
s && (i == null || i.subscribe("redirectUriDiscovered", s));
|
|
2197
|
+
async function c() {
|
|
2198
|
+
try {
|
|
2199
|
+
await (i == null ? void 0 : i.getUserFromURL()), t();
|
|
2200
|
+
} catch (u) {
|
|
2201
|
+
const h = gn(u);
|
|
2202
|
+
Qr(h), e({ error: h });
|
|
2203
|
+
}
|
|
2204
|
+
}
|
|
2205
|
+
return c(), () => {
|
|
2206
|
+
s && i.unsubscribe("redirectUriDiscovered", s);
|
|
2207
|
+
};
|
|
2208
|
+
}, [n, e, t, i]), n === "password-recovery" ? /* @__PURE__ */ l.jsx(Pr, {}) : /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
|
|
2209
|
+
/* @__PURE__ */ l.jsxs(ne, { space: "0.25", children: [
|
|
2210
|
+
/* @__PURE__ */ l.jsx(
|
|
2211
|
+
M,
|
|
2212
|
+
{
|
|
2213
|
+
as: "h1",
|
|
2214
|
+
variant: { size: "2xl-title", weight: "bold" },
|
|
2215
|
+
t: "initial.title"
|
|
2216
|
+
}
|
|
2217
|
+
),
|
|
2218
|
+
/* @__PURE__ */ l.jsx(
|
|
2219
|
+
M,
|
|
2220
|
+
{
|
|
2221
|
+
variant: { color: "contrast", weight: "semibold" },
|
|
2222
|
+
as: "h2",
|
|
2223
|
+
t: "initial.details"
|
|
2224
|
+
}
|
|
2225
|
+
)
|
|
2226
|
+
] }),
|
|
2227
|
+
/* @__PURE__ */ l.jsx(ot, {})
|
|
2228
|
+
] });
|
|
2229
|
+
}
|
|
2230
|
+
export {
|
|
2231
|
+
bn as Card,
|
|
2232
|
+
wn as Error,
|
|
2233
|
+
lr as I18N,
|
|
2234
|
+
Sn as Initial,
|
|
2235
|
+
xn as Progress,
|
|
2236
|
+
Pr as Recover,
|
|
2237
|
+
yn as Success,
|
|
2238
|
+
Tn as TextProvider,
|
|
2239
|
+
jn as ThemeRoot
|
|
2240
|
+
};
|
|
2241
|
+
//# sourceMappingURL=main.js.map
|