@apolitical/component-library 2.2.1 → 2.2.2
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/form/components/form/form.d.ts +1 -1
- package/index.js +18 -18
- package/index.mjs +1007 -1009
- package/package.json +1 -1
- package/style.css +1 -1
package/index.mjs
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import K, { memo as Fe, useState as te, useEffect as
|
|
1
|
+
import K, { memo as Fe, useState as te, useEffect as ae, useRef as pe, useMemo as vt, createContext as Un, useContext as Ce, Children as Fn, useCallback as Kr, useReducer as zn, Fragment as ht, Suspense as ui } from "react";
|
|
2
2
|
import ut from "lodash.clonedeep";
|
|
3
3
|
import fi from "lodash.set";
|
|
4
4
|
import { useIntl as G, IntlProvider as mi, FormattedMessage as _e, createIntl as pi } from "react-intl";
|
|
5
5
|
import Ke from "truncate";
|
|
6
6
|
import { QueryClient as hi, QueryClientProvider as gi, useMutation as ke, useQueryClient as Zn, useInfiniteQuery as Gr, useQuery as vi } from "@tanstack/react-query";
|
|
7
7
|
import { ReactQueryDevtools as bi } from "@tanstack/react-query-devtools";
|
|
8
|
-
import
|
|
8
|
+
import Ft from "posthog-js";
|
|
9
9
|
import { CookiesProvider as yi, useCookies as Qr } from "react-cookie";
|
|
10
10
|
import Xe from "markdown-to-jsx";
|
|
11
11
|
import { ReactMultiEmail as _i } from "react-multi-email";
|
|
@@ -74,14 +74,14 @@ var ta = { exports: {} };
|
|
|
74
74
|
})();
|
|
75
75
|
})(ta);
|
|
76
76
|
var ji = ta.exports;
|
|
77
|
-
const
|
|
77
|
+
const S = /* @__PURE__ */ Xr(ji), Ti = ({
|
|
78
78
|
element: t = "span",
|
|
79
79
|
showOnFocus: e = !0,
|
|
80
80
|
children: n,
|
|
81
81
|
...r
|
|
82
82
|
}) => K.createElement(t, {
|
|
83
83
|
...r,
|
|
84
|
-
className:
|
|
84
|
+
className: S("hidden", { "show-on-focus": e }),
|
|
85
85
|
children: n
|
|
86
86
|
}), be = Fe(Ti), Ei = ({
|
|
87
87
|
element: t = "span",
|
|
@@ -139,36 +139,36 @@ function Ci() {
|
|
|
139
139
|
var g = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
140
140
|
function y(h) {
|
|
141
141
|
{
|
|
142
|
-
for (var P = arguments.length,
|
|
143
|
-
|
|
144
|
-
E("error", h,
|
|
142
|
+
for (var P = arguments.length, L = new Array(P > 1 ? P - 1 : 0), ne = 1; ne < P; ne++)
|
|
143
|
+
L[ne - 1] = arguments[ne];
|
|
144
|
+
E("error", h, L);
|
|
145
145
|
}
|
|
146
146
|
}
|
|
147
|
-
function E(h, P,
|
|
147
|
+
function E(h, P, L) {
|
|
148
148
|
{
|
|
149
149
|
var ne = g.ReactDebugCurrentFrame, le = ne.getStackAddendum();
|
|
150
|
-
le !== "" && (P += "%s",
|
|
151
|
-
var me =
|
|
150
|
+
le !== "" && (P += "%s", L = L.concat([le]));
|
|
151
|
+
var me = L.map(function(ce) {
|
|
152
152
|
return String(ce);
|
|
153
153
|
});
|
|
154
154
|
me.unshift("Warning: " + P), Function.prototype.apply.call(console[h], console, me);
|
|
155
155
|
}
|
|
156
156
|
}
|
|
157
|
-
var j = !1, w = !1,
|
|
157
|
+
var j = !1, w = !1, z = !1, F = !1, q = !1, M;
|
|
158
158
|
M = Symbol.for("react.module.reference");
|
|
159
159
|
function O(h) {
|
|
160
|
-
return !!(typeof h == "string" || typeof h == "function" || h === r || h === s || q || h === i || h === l || h === u ||
|
|
160
|
+
return !!(typeof h == "string" || typeof h == "function" || h === r || h === s || q || h === i || h === l || h === u || F || h === p || j || w || z || typeof h == "object" && h !== null && (h.$$typeof === m || h.$$typeof === d || h.$$typeof === o || h.$$typeof === c || h.$$typeof === f || // This needs to include all possible module reference object
|
|
161
161
|
// types supported by any Flight configuration anywhere since
|
|
162
162
|
// we don't know which Flight build this will end up being used
|
|
163
163
|
// with.
|
|
164
164
|
h.$$typeof === M || h.getModuleId !== void 0));
|
|
165
165
|
}
|
|
166
|
-
function
|
|
166
|
+
function C(h, P, L) {
|
|
167
167
|
var ne = h.displayName;
|
|
168
168
|
if (ne)
|
|
169
169
|
return ne;
|
|
170
170
|
var le = P.displayName || P.name || "";
|
|
171
|
-
return le !== "" ?
|
|
171
|
+
return le !== "" ? L + "(" + le + ")" : L;
|
|
172
172
|
}
|
|
173
173
|
function T(h) {
|
|
174
174
|
return h.displayName || "Context";
|
|
@@ -200,10 +200,10 @@ function Ci() {
|
|
|
200
200
|
var P = h;
|
|
201
201
|
return T(P) + ".Consumer";
|
|
202
202
|
case o:
|
|
203
|
-
var
|
|
204
|
-
return T(
|
|
203
|
+
var L = h;
|
|
204
|
+
return T(L._context) + ".Provider";
|
|
205
205
|
case f:
|
|
206
|
-
return
|
|
206
|
+
return C(h, h.render, "ForwardRef");
|
|
207
207
|
case d:
|
|
208
208
|
var ne = h.displayName || null;
|
|
209
209
|
return ne !== null ? ne : x(h.type) || "Memo";
|
|
@@ -218,18 +218,18 @@ function Ci() {
|
|
|
218
218
|
}
|
|
219
219
|
return null;
|
|
220
220
|
}
|
|
221
|
-
var
|
|
222
|
-
function
|
|
221
|
+
var $ = Object.assign, I = 0, U, A, W, J, k, N, Z;
|
|
222
|
+
function B() {
|
|
223
223
|
}
|
|
224
|
-
|
|
225
|
-
function
|
|
224
|
+
B.__reactDisabledLog = !0;
|
|
225
|
+
function H() {
|
|
226
226
|
{
|
|
227
|
-
if (
|
|
228
|
-
|
|
227
|
+
if (I === 0) {
|
|
228
|
+
U = console.log, A = console.info, W = console.warn, J = console.error, k = console.group, N = console.groupCollapsed, Z = console.groupEnd;
|
|
229
229
|
var h = {
|
|
230
230
|
configurable: !0,
|
|
231
231
|
enumerable: !0,
|
|
232
|
-
value:
|
|
232
|
+
value: B,
|
|
233
233
|
writable: !0
|
|
234
234
|
};
|
|
235
235
|
Object.defineProperties(console, {
|
|
@@ -242,77 +242,77 @@ function Ci() {
|
|
|
242
242
|
groupEnd: h
|
|
243
243
|
});
|
|
244
244
|
}
|
|
245
|
-
|
|
245
|
+
I++;
|
|
246
246
|
}
|
|
247
247
|
}
|
|
248
|
-
function
|
|
248
|
+
function ee() {
|
|
249
249
|
{
|
|
250
|
-
if (
|
|
250
|
+
if (I--, I === 0) {
|
|
251
251
|
var h = {
|
|
252
252
|
configurable: !0,
|
|
253
253
|
enumerable: !0,
|
|
254
254
|
writable: !0
|
|
255
255
|
};
|
|
256
256
|
Object.defineProperties(console, {
|
|
257
|
-
log:
|
|
258
|
-
value:
|
|
257
|
+
log: $({}, h, {
|
|
258
|
+
value: U
|
|
259
259
|
}),
|
|
260
|
-
info:
|
|
261
|
-
value:
|
|
260
|
+
info: $({}, h, {
|
|
261
|
+
value: A
|
|
262
262
|
}),
|
|
263
|
-
warn:
|
|
264
|
-
value:
|
|
263
|
+
warn: $({}, h, {
|
|
264
|
+
value: W
|
|
265
265
|
}),
|
|
266
|
-
error:
|
|
267
|
-
value:
|
|
266
|
+
error: $({}, h, {
|
|
267
|
+
value: J
|
|
268
268
|
}),
|
|
269
|
-
group:
|
|
269
|
+
group: $({}, h, {
|
|
270
270
|
value: k
|
|
271
271
|
}),
|
|
272
|
-
groupCollapsed:
|
|
272
|
+
groupCollapsed: $({}, h, {
|
|
273
273
|
value: N
|
|
274
274
|
}),
|
|
275
|
-
groupEnd:
|
|
275
|
+
groupEnd: $({}, h, {
|
|
276
276
|
value: Z
|
|
277
277
|
})
|
|
278
278
|
});
|
|
279
279
|
}
|
|
280
|
-
|
|
280
|
+
I < 0 && y("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
|
|
281
281
|
}
|
|
282
282
|
}
|
|
283
|
-
var Y = g.ReactCurrentDispatcher,
|
|
284
|
-
function
|
|
283
|
+
var Y = g.ReactCurrentDispatcher, V;
|
|
284
|
+
function X(h, P, L) {
|
|
285
285
|
{
|
|
286
|
-
if (
|
|
286
|
+
if (V === void 0)
|
|
287
287
|
try {
|
|
288
288
|
throw Error();
|
|
289
289
|
} catch (le) {
|
|
290
290
|
var ne = le.stack.trim().match(/\n( *(at )?)/);
|
|
291
|
-
|
|
291
|
+
V = ne && ne[1] || "";
|
|
292
292
|
}
|
|
293
293
|
return `
|
|
294
|
-
` +
|
|
294
|
+
` + V + h;
|
|
295
295
|
}
|
|
296
296
|
}
|
|
297
|
-
var re = !1,
|
|
297
|
+
var re = !1, R;
|
|
298
298
|
{
|
|
299
299
|
var oe = typeof WeakMap == "function" ? WeakMap : Map;
|
|
300
|
-
|
|
300
|
+
R = new oe();
|
|
301
301
|
}
|
|
302
|
-
function
|
|
302
|
+
function D(h, P) {
|
|
303
303
|
if (!h || re)
|
|
304
304
|
return "";
|
|
305
305
|
{
|
|
306
|
-
var
|
|
307
|
-
if (
|
|
308
|
-
return
|
|
306
|
+
var L = R.get(h);
|
|
307
|
+
if (L !== void 0)
|
|
308
|
+
return L;
|
|
309
309
|
}
|
|
310
310
|
var ne;
|
|
311
311
|
re = !0;
|
|
312
312
|
var le = Error.prepareStackTrace;
|
|
313
313
|
Error.prepareStackTrace = void 0;
|
|
314
314
|
var me;
|
|
315
|
-
me = Y.current, Y.current = null,
|
|
315
|
+
me = Y.current, Y.current = null, H();
|
|
316
316
|
try {
|
|
317
317
|
if (P) {
|
|
318
318
|
var ce = function() {
|
|
@@ -358,48 +358,48 @@ function Ci() {
|
|
|
358
358
|
if (he--, ge--, ge < 0 || se[he] !== xe[ge]) {
|
|
359
359
|
var je = `
|
|
360
360
|
` + se[he].replace(" at new ", " at ");
|
|
361
|
-
return h.displayName && je.includes("<anonymous>") && (je = je.replace("<anonymous>", h.displayName)), typeof h == "function" &&
|
|
361
|
+
return h.displayName && je.includes("<anonymous>") && (je = je.replace("<anonymous>", h.displayName)), typeof h == "function" && R.set(h, je), je;
|
|
362
362
|
}
|
|
363
363
|
while (he >= 1 && ge >= 0);
|
|
364
364
|
break;
|
|
365
365
|
}
|
|
366
366
|
}
|
|
367
367
|
} finally {
|
|
368
|
-
re = !1, Y.current = me,
|
|
368
|
+
re = !1, Y.current = me, ee(), Error.prepareStackTrace = le;
|
|
369
369
|
}
|
|
370
|
-
var We = h ? h.displayName || h.name : "", pr = We ?
|
|
371
|
-
return typeof h == "function" &&
|
|
370
|
+
var We = h ? h.displayName || h.name : "", pr = We ? X(We) : "";
|
|
371
|
+
return typeof h == "function" && R.set(h, pr), pr;
|
|
372
372
|
}
|
|
373
|
-
function ve(h, P,
|
|
374
|
-
return
|
|
373
|
+
function ve(h, P, L) {
|
|
374
|
+
return D(h, !1);
|
|
375
375
|
}
|
|
376
376
|
function $e(h) {
|
|
377
377
|
var P = h.prototype;
|
|
378
378
|
return !!(P && P.isReactComponent);
|
|
379
379
|
}
|
|
380
|
-
function Ee(h, P,
|
|
380
|
+
function Ee(h, P, L) {
|
|
381
381
|
if (h == null)
|
|
382
382
|
return "";
|
|
383
383
|
if (typeof h == "function")
|
|
384
|
-
return
|
|
384
|
+
return D(h, $e(h));
|
|
385
385
|
if (typeof h == "string")
|
|
386
|
-
return
|
|
386
|
+
return X(h);
|
|
387
387
|
switch (h) {
|
|
388
388
|
case l:
|
|
389
|
-
return
|
|
389
|
+
return X("Suspense");
|
|
390
390
|
case u:
|
|
391
|
-
return
|
|
391
|
+
return X("SuspenseList");
|
|
392
392
|
}
|
|
393
393
|
if (typeof h == "object")
|
|
394
394
|
switch (h.$$typeof) {
|
|
395
395
|
case f:
|
|
396
396
|
return ve(h.render);
|
|
397
397
|
case d:
|
|
398
|
-
return Ee(h.type, P,
|
|
398
|
+
return Ee(h.type, P, L);
|
|
399
399
|
case m: {
|
|
400
400
|
var ne = h, le = ne._payload, me = ne._init;
|
|
401
401
|
try {
|
|
402
|
-
return Ee(me(le), P,
|
|
402
|
+
return Ee(me(le), P, L);
|
|
403
403
|
} catch {
|
|
404
404
|
}
|
|
405
405
|
}
|
|
@@ -407,14 +407,14 @@ function Ci() {
|
|
|
407
407
|
return "";
|
|
408
408
|
}
|
|
409
409
|
var Le = Object.prototype.hasOwnProperty, nr = {}, rr = g.ReactDebugCurrentFrame;
|
|
410
|
-
function
|
|
410
|
+
function wt(h) {
|
|
411
411
|
if (h) {
|
|
412
|
-
var P = h._owner,
|
|
413
|
-
rr.setExtraStackFrame(
|
|
412
|
+
var P = h._owner, L = Ee(h.type, h._source, P ? P.type : null);
|
|
413
|
+
rr.setExtraStackFrame(L);
|
|
414
414
|
} else
|
|
415
415
|
rr.setExtraStackFrame(null);
|
|
416
416
|
}
|
|
417
|
-
function Wa(h, P,
|
|
417
|
+
function Wa(h, P, L, ne, le) {
|
|
418
418
|
{
|
|
419
419
|
var me = Function.call.bind(Le);
|
|
420
420
|
for (var ce in h)
|
|
@@ -422,14 +422,14 @@ function Ci() {
|
|
|
422
422
|
var se = void 0;
|
|
423
423
|
try {
|
|
424
424
|
if (typeof h[ce] != "function") {
|
|
425
|
-
var xe = Error((ne || "React class") + ": " +
|
|
425
|
+
var xe = Error((ne || "React class") + ": " + L + " type `" + ce + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof h[ce] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
|
|
426
426
|
throw xe.name = "Invariant Violation", xe;
|
|
427
427
|
}
|
|
428
|
-
se = h[ce](P, ce, ne,
|
|
428
|
+
se = h[ce](P, ce, ne, L, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
|
|
429
429
|
} catch (he) {
|
|
430
430
|
se = he;
|
|
431
431
|
}
|
|
432
|
-
se && !(se instanceof Error) && (
|
|
432
|
+
se && !(se instanceof Error) && (wt(le), y("%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).", ne || "React class", L, ce, typeof se), wt(null)), se instanceof Error && !(se.message in nr) && (nr[se.message] = !0, wt(le), y("Failed %s type: %s", L, se.message), wt(null));
|
|
433
433
|
}
|
|
434
434
|
}
|
|
435
435
|
}
|
|
@@ -439,8 +439,8 @@ function Ci() {
|
|
|
439
439
|
}
|
|
440
440
|
function Va(h) {
|
|
441
441
|
{
|
|
442
|
-
var P = typeof Symbol == "function" && Symbol.toStringTag,
|
|
443
|
-
return
|
|
442
|
+
var P = typeof Symbol == "function" && Symbol.toStringTag, L = P && h[Symbol.toStringTag] || h.constructor.name || "Object";
|
|
443
|
+
return L;
|
|
444
444
|
}
|
|
445
445
|
}
|
|
446
446
|
function Ya(h) {
|
|
@@ -482,40 +482,40 @@ function Ci() {
|
|
|
482
482
|
}
|
|
483
483
|
function Ja(h, P) {
|
|
484
484
|
if (typeof h.ref == "string" && nt.current && P && nt.current.stateNode !== P) {
|
|
485
|
-
var
|
|
486
|
-
an[
|
|
485
|
+
var L = x(nt.current.type);
|
|
486
|
+
an[L] || (y('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', x(nt.current.type), h.ref), an[L] = !0);
|
|
487
487
|
}
|
|
488
488
|
}
|
|
489
489
|
function Xa(h, P) {
|
|
490
490
|
{
|
|
491
|
-
var
|
|
491
|
+
var L = function() {
|
|
492
492
|
sr || (sr = !0, y("%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)", P));
|
|
493
493
|
};
|
|
494
|
-
|
|
495
|
-
get:
|
|
494
|
+
L.isReactWarning = !0, Object.defineProperty(h, "key", {
|
|
495
|
+
get: L,
|
|
496
496
|
configurable: !0
|
|
497
497
|
});
|
|
498
498
|
}
|
|
499
499
|
}
|
|
500
500
|
function ei(h, P) {
|
|
501
501
|
{
|
|
502
|
-
var
|
|
502
|
+
var L = function() {
|
|
503
503
|
or || (or = !0, y("%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)", P));
|
|
504
504
|
};
|
|
505
|
-
|
|
506
|
-
get:
|
|
505
|
+
L.isReactWarning = !0, Object.defineProperty(h, "ref", {
|
|
506
|
+
get: L,
|
|
507
507
|
configurable: !0
|
|
508
508
|
});
|
|
509
509
|
}
|
|
510
510
|
}
|
|
511
|
-
var ti = function(h, P,
|
|
511
|
+
var ti = function(h, P, L, ne, le, me, ce) {
|
|
512
512
|
var se = {
|
|
513
513
|
// This tag allows us to uniquely identify this as a React Element
|
|
514
514
|
$$typeof: e,
|
|
515
515
|
// Built-in properties that belong on the element
|
|
516
516
|
type: h,
|
|
517
517
|
key: P,
|
|
518
|
-
ref:
|
|
518
|
+
ref: L,
|
|
519
519
|
props: ce,
|
|
520
520
|
// Record the component responsible for creating this element.
|
|
521
521
|
_owner: me
|
|
@@ -537,10 +537,10 @@ function Ci() {
|
|
|
537
537
|
value: le
|
|
538
538
|
}), Object.freeze && (Object.freeze(se.props), Object.freeze(se)), se;
|
|
539
539
|
};
|
|
540
|
-
function ni(h, P,
|
|
540
|
+
function ni(h, P, L, ne, le) {
|
|
541
541
|
{
|
|
542
542
|
var me, ce = {}, se = null, xe = null;
|
|
543
|
-
|
|
543
|
+
L !== void 0 && (ir(L), se = "" + L), Qa(P) && (ir(P.key), se = "" + P.key), Ga(P) && (xe = P.ref, Ja(P, le));
|
|
544
544
|
for (me in P)
|
|
545
545
|
Le.call(P, me) && !Ka.hasOwnProperty(me) && (ce[me] = P[me]);
|
|
546
546
|
if (h && h.defaultProps) {
|
|
@@ -558,8 +558,8 @@ function Ci() {
|
|
|
558
558
|
var sn = g.ReactCurrentOwner, cr = g.ReactDebugCurrentFrame;
|
|
559
559
|
function Ze(h) {
|
|
560
560
|
if (h) {
|
|
561
|
-
var P = h._owner,
|
|
562
|
-
cr.setExtraStackFrame(
|
|
561
|
+
var P = h._owner, L = Ee(h.type, h._source, P ? P.type : null);
|
|
562
|
+
cr.setExtraStackFrame(L);
|
|
563
563
|
} else
|
|
564
564
|
cr.setExtraStackFrame(null);
|
|
565
565
|
}
|
|
@@ -583,10 +583,10 @@ Check the render method of \`` + h + "`.";
|
|
|
583
583
|
function ri(h) {
|
|
584
584
|
{
|
|
585
585
|
if (h !== void 0) {
|
|
586
|
-
var P = h.fileName.replace(/^.*[\\\/]/, ""),
|
|
586
|
+
var P = h.fileName.replace(/^.*[\\\/]/, ""), L = h.lineNumber;
|
|
587
587
|
return `
|
|
588
588
|
|
|
589
|
-
Check your code at ` + P + ":" +
|
|
589
|
+
Check your code at ` + P + ":" + L + ".";
|
|
590
590
|
}
|
|
591
591
|
return "";
|
|
592
592
|
}
|
|
@@ -596,10 +596,10 @@ Check your code at ` + P + ":" + B + ".";
|
|
|
596
596
|
{
|
|
597
597
|
var P = lr();
|
|
598
598
|
if (!P) {
|
|
599
|
-
var
|
|
600
|
-
|
|
599
|
+
var L = typeof h == "string" ? h : h.displayName || h.name;
|
|
600
|
+
L && (P = `
|
|
601
601
|
|
|
602
|
-
Check the top-level render call using <` +
|
|
602
|
+
Check the top-level render call using <` + L + ">.");
|
|
603
603
|
}
|
|
604
604
|
return P;
|
|
605
605
|
}
|
|
@@ -609,12 +609,12 @@ Check the top-level render call using <` + B + ">.");
|
|
|
609
609
|
if (!h._store || h._store.validated || h.key != null)
|
|
610
610
|
return;
|
|
611
611
|
h._store.validated = !0;
|
|
612
|
-
var
|
|
613
|
-
if (dr[
|
|
612
|
+
var L = ai(P);
|
|
613
|
+
if (dr[L])
|
|
614
614
|
return;
|
|
615
|
-
dr[
|
|
615
|
+
dr[L] = !0;
|
|
616
616
|
var ne = "";
|
|
617
|
-
h && h._owner && h._owner !== sn.current && (ne = " It was passed a child from " + x(h._owner.type) + "."), Ze(h), y('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',
|
|
617
|
+
h && h._owner && h._owner !== sn.current && (ne = " It was passed a child from " + x(h._owner.type) + "."), Ze(h), y('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', L, ne), Ze(null);
|
|
618
618
|
}
|
|
619
619
|
}
|
|
620
620
|
function fr(h, P) {
|
|
@@ -622,8 +622,8 @@ Check the top-level render call using <` + B + ">.");
|
|
|
622
622
|
if (typeof h != "object")
|
|
623
623
|
return;
|
|
624
624
|
if (rn(h))
|
|
625
|
-
for (var
|
|
626
|
-
var ne = h[
|
|
625
|
+
for (var L = 0; L < h.length; L++) {
|
|
626
|
+
var ne = h[L];
|
|
627
627
|
cn(ne) && ur(ne, P);
|
|
628
628
|
}
|
|
629
629
|
else if (cn(h))
|
|
@@ -641,18 +641,18 @@ Check the top-level render call using <` + B + ">.");
|
|
|
641
641
|
var P = h.type;
|
|
642
642
|
if (P == null || typeof P == "string")
|
|
643
643
|
return;
|
|
644
|
-
var
|
|
644
|
+
var L;
|
|
645
645
|
if (typeof P == "function")
|
|
646
|
-
|
|
646
|
+
L = P.propTypes;
|
|
647
647
|
else if (typeof P == "object" && (P.$$typeof === f || // Note: Memo only checks outer props here.
|
|
648
648
|
// Inner props are checked in the reconciler.
|
|
649
649
|
P.$$typeof === d))
|
|
650
|
-
|
|
650
|
+
L = P.propTypes;
|
|
651
651
|
else
|
|
652
652
|
return;
|
|
653
|
-
if (
|
|
653
|
+
if (L) {
|
|
654
654
|
var ne = x(P);
|
|
655
|
-
Wa(
|
|
655
|
+
Wa(L, h.props, "prop", ne, h);
|
|
656
656
|
} else if (P.PropTypes !== void 0 && !on) {
|
|
657
657
|
on = !0;
|
|
658
658
|
var le = x(P);
|
|
@@ -663,8 +663,8 @@ Check the top-level render call using <` + B + ">.");
|
|
|
663
663
|
}
|
|
664
664
|
function si(h) {
|
|
665
665
|
{
|
|
666
|
-
for (var P = Object.keys(h.props),
|
|
667
|
-
var ne = P[
|
|
666
|
+
for (var P = Object.keys(h.props), L = 0; L < P.length; L++) {
|
|
667
|
+
var ne = P[L];
|
|
668
668
|
if (ne !== "children" && ne !== "key") {
|
|
669
669
|
Ze(h), y("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", ne), Ze(null);
|
|
670
670
|
break;
|
|
@@ -673,7 +673,7 @@ Check the top-level render call using <` + B + ">.");
|
|
|
673
673
|
h.ref !== null && (Ze(h), y("Invalid attribute `ref` supplied to `React.Fragment`."), Ze(null));
|
|
674
674
|
}
|
|
675
675
|
}
|
|
676
|
-
function mr(h, P,
|
|
676
|
+
function mr(h, P, L, ne, le, me) {
|
|
677
677
|
{
|
|
678
678
|
var ce = O(h);
|
|
679
679
|
if (!ce) {
|
|
@@ -684,7 +684,7 @@ Check the top-level render call using <` + B + ">.");
|
|
|
684
684
|
var he;
|
|
685
685
|
h === null ? he = "null" : rn(h) ? he = "array" : h !== void 0 && h.$$typeof === e ? (he = "<" + (x(h.type) || "Unknown") + " />", se = " Did you accidentally export a JSX literal instead of a component?") : he = typeof h, y("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", he, se);
|
|
686
686
|
}
|
|
687
|
-
var ge = ni(h, P,
|
|
687
|
+
var ge = ni(h, P, L, le, me);
|
|
688
688
|
if (ge == null)
|
|
689
689
|
return ge;
|
|
690
690
|
if (ce) {
|
|
@@ -703,11 +703,11 @@ Check the top-level render call using <` + B + ">.");
|
|
|
703
703
|
return h === r ? si(ge) : ii(ge), ge;
|
|
704
704
|
}
|
|
705
705
|
}
|
|
706
|
-
function oi(h, P,
|
|
707
|
-
return mr(h, P,
|
|
706
|
+
function oi(h, P, L) {
|
|
707
|
+
return mr(h, P, L, !0);
|
|
708
708
|
}
|
|
709
|
-
function ci(h, P,
|
|
710
|
-
return mr(h, P,
|
|
709
|
+
function ci(h, P, L) {
|
|
710
|
+
return mr(h, P, L, !1);
|
|
711
711
|
}
|
|
712
712
|
var li = ci, di = oi;
|
|
713
713
|
at.Fragment = r, at.jsx = li, at.jsxs = di;
|
|
@@ -720,12 +720,12 @@ const $i = () => {
|
|
|
720
720
|
const r = window.location.pathname;
|
|
721
721
|
e(r);
|
|
722
722
|
};
|
|
723
|
-
return
|
|
723
|
+
return ae(() => (window.addEventListener("popstate", n), () => {
|
|
724
724
|
window.removeEventListener("popstate", n);
|
|
725
725
|
}), []), t;
|
|
726
726
|
}, gt = (t, e) => {
|
|
727
727
|
const n = pe(!1);
|
|
728
|
-
|
|
728
|
+
ae(() => {
|
|
729
729
|
n.current ? t() : n.current = !0;
|
|
730
730
|
}, e);
|
|
731
731
|
};
|
|
@@ -737,36 +737,36 @@ function Ni(t, e, n) {
|
|
|
737
737
|
throw new TypeError("Expected a function");
|
|
738
738
|
e = +e || 0;
|
|
739
739
|
var v = !!(n = n || {}).leading, b = !("trailing" in n) || !!n.trailing, _ = "maxWait" in n, g = "debounceOnServer" in n && !!n.debounceOnServer, y = _ ? Math.max(+n.maxWait || 0, e) : null;
|
|
740
|
-
|
|
740
|
+
ae(function() {
|
|
741
741
|
return d.current = !0, function() {
|
|
742
742
|
d.current = !1;
|
|
743
743
|
};
|
|
744
744
|
}, []);
|
|
745
745
|
var E = vt(function() {
|
|
746
746
|
var j = function(O) {
|
|
747
|
-
var
|
|
748
|
-
return c.current = f.current = null, s.current = O, l.current = u.current.apply(T,
|
|
749
|
-
}, w = function(O,
|
|
750
|
-
p && cancelAnimationFrame(o.current), o.current = p ? requestAnimationFrame(O) : setTimeout(O,
|
|
751
|
-
},
|
|
747
|
+
var C = c.current, T = f.current;
|
|
748
|
+
return c.current = f.current = null, s.current = O, l.current = u.current.apply(T, C);
|
|
749
|
+
}, w = function(O, C) {
|
|
750
|
+
p && cancelAnimationFrame(o.current), o.current = p ? requestAnimationFrame(O) : setTimeout(O, C);
|
|
751
|
+
}, z = function(O) {
|
|
752
752
|
if (!d.current)
|
|
753
753
|
return !1;
|
|
754
|
-
var
|
|
755
|
-
return !i.current ||
|
|
756
|
-
},
|
|
754
|
+
var C = O - i.current;
|
|
755
|
+
return !i.current || C >= e || C < 0 || _ && O - s.current >= y;
|
|
756
|
+
}, F = function(O) {
|
|
757
757
|
return o.current = null, b && c.current ? j(O) : (c.current = f.current = null, l.current);
|
|
758
758
|
}, q = function O() {
|
|
759
|
-
var
|
|
760
|
-
if (
|
|
761
|
-
return
|
|
759
|
+
var C = Date.now();
|
|
760
|
+
if (z(C))
|
|
761
|
+
return F(C);
|
|
762
762
|
if (d.current) {
|
|
763
|
-
var T = e - (
|
|
763
|
+
var T = e - (C - i.current), x = _ ? Math.min(T, y - (C - s.current)) : T;
|
|
764
764
|
w(O, x);
|
|
765
765
|
}
|
|
766
766
|
}, M = function() {
|
|
767
767
|
if (m || g) {
|
|
768
|
-
var O = Date.now(),
|
|
769
|
-
if (c.current = [].slice.call(arguments), f.current = r, i.current = O,
|
|
768
|
+
var O = Date.now(), C = z(O);
|
|
769
|
+
if (c.current = [].slice.call(arguments), f.current = r, i.current = O, C) {
|
|
770
770
|
if (!o.current && d.current)
|
|
771
771
|
return s.current = i.current, w(q, e), v ? j(i.current) : l.current;
|
|
772
772
|
if (_)
|
|
@@ -780,7 +780,7 @@ function Ni(t, e, n) {
|
|
|
780
780
|
}, M.isPending = function() {
|
|
781
781
|
return !!o.current;
|
|
782
782
|
}, M.flush = function() {
|
|
783
|
-
return o.current ?
|
|
783
|
+
return o.current ? F(Date.now()) : l.current;
|
|
784
784
|
}, M;
|
|
785
785
|
}, [v, _, e, y, b, p, m, g]);
|
|
786
786
|
return E;
|
|
@@ -795,7 +795,7 @@ const bt = (t = !0, e = !1, n = "window") => {
|
|
|
795
795
|
return;
|
|
796
796
|
const [r, i] = K.useState(0) || [!1, () => {
|
|
797
797
|
}];
|
|
798
|
-
|
|
798
|
+
ae(() => (c(), window.addEventListener("resize", l), window.addEventListener("hiddenSectionVisible", f), () => {
|
|
799
799
|
clearTimeout(ln), l.flush(), window.removeEventListener("resize", l), window.removeEventListener("hiddenSectionVisible", f);
|
|
800
800
|
}), n === "window" ? [] : [n]);
|
|
801
801
|
const o = () => {
|
|
@@ -836,7 +836,7 @@ const bt = (t = !0, e = !1, n = "window") => {
|
|
|
836
836
|
scrollUp: !1
|
|
837
837
|
}) || [!1, () => {
|
|
838
838
|
}];
|
|
839
|
-
|
|
839
|
+
ae(() => (f(), window.addEventListener("scroll", l), () => {
|
|
840
840
|
l.flush(), window.removeEventListener("scroll", l);
|
|
841
841
|
}), []);
|
|
842
842
|
const f = () => {
|
|
@@ -914,7 +914,7 @@ const qe = {
|
|
|
914
914
|
year: "numeric"
|
|
915
915
|
}), Dn = (t) => {
|
|
916
916
|
let e;
|
|
917
|
-
const n =
|
|
917
|
+
const n = At(), r = At(new Date(t));
|
|
918
918
|
try {
|
|
919
919
|
e = n.getTime() - r.getTime();
|
|
920
920
|
} catch {
|
|
@@ -927,12 +927,12 @@ const qe = {
|
|
|
927
927
|
return { path: "days", number: s };
|
|
928
928
|
const o = Math.floor(s / 7);
|
|
929
929
|
return o <= qe.year.weeks ? { path: "weeks", number: o } : { path: "years", number: Math.floor(s / qe.year.days) };
|
|
930
|
-
},
|
|
930
|
+
}, At = (t) => {
|
|
931
931
|
const n = (t || /* @__PURE__ */ new Date()).toUTCString();
|
|
932
932
|
return new Date(n);
|
|
933
933
|
}, Di = (t, e, n) => {
|
|
934
934
|
let r;
|
|
935
|
-
const i =
|
|
935
|
+
const i = At(), s = At(new Date(t));
|
|
936
936
|
try {
|
|
937
937
|
r = i.getTime() - s.getTime();
|
|
938
938
|
} catch {
|
|
@@ -1341,7 +1341,7 @@ Thank you for helping to protect the Apolitical community from abusive content.`
|
|
|
1341
1341
|
}
|
|
1342
1342
|
}
|
|
1343
1343
|
return r;
|
|
1344
|
-
},
|
|
1344
|
+
}, Ot = (t, e) => K.Children.map(t, (n) => Object.is(n, null) ? n : K.cloneElement(n, {
|
|
1345
1345
|
...e
|
|
1346
1346
|
})), zi = (t = 0) => {
|
|
1347
1347
|
setTimeout(() => {
|
|
@@ -1358,7 +1358,7 @@ Thank you for helping to protect the Apolitical community from abusive content.`
|
|
|
1358
1358
|
includesLowerAndUppercase: r
|
|
1359
1359
|
}
|
|
1360
1360
|
};
|
|
1361
|
-
},
|
|
1361
|
+
}, ie = ({
|
|
1362
1362
|
variant: t = "primary",
|
|
1363
1363
|
size: e = "medium",
|
|
1364
1364
|
styling: n = { muted: !1, fullWidth: !1 },
|
|
@@ -1381,7 +1381,7 @@ Thank you for helping to protect the Apolitical community from abusive content.`
|
|
|
1381
1381
|
typeof e == "string" && v.push(e), r && (v.push("icon"), typeof r == "object" ? (v.push(r.icon), r.position ? v.push(r.position) : v.push("left"), r.hover && v.push(`hover_${r.hover}`), r.animate && (v.push("animate"), typeof r.animate == "string" && v.push(r.animate))) : (v.push(r), !r.includes("right") && !r.includes("left") && v.push("left"))), n.muted && v.push("muted"), n.fullWidth && v.push("full-width");
|
|
1382
1382
|
const b = {
|
|
1383
1383
|
...d,
|
|
1384
|
-
className:
|
|
1384
|
+
className: S(t, c, v, {
|
|
1385
1385
|
"no-text": !u,
|
|
1386
1386
|
disabled: f,
|
|
1387
1387
|
button: i
|
|
@@ -1396,17 +1396,17 @@ Thank you for helping to protect the Apolitical community from abusive content.`
|
|
|
1396
1396
|
b,
|
|
1397
1397
|
u || (l ? /* @__PURE__ */ a.jsx(be, { showOnFocus: !1, children: l }) : null)
|
|
1398
1398
|
);
|
|
1399
|
-
},
|
|
1400
|
-
const r = t.length > 1 ? "ul" : "p", i = t.map((s, o) => r === "p" ? /* @__PURE__ */ a.jsx(
|
|
1399
|
+
}, yt = ({ buttons: t, className: e = "", ...n }) => {
|
|
1400
|
+
const r = t.length > 1 ? "ul" : "p", i = t.map((s, o) => r === "p" ? /* @__PURE__ */ a.jsx(ie, { ...s }, o) : /* @__PURE__ */ a.jsx("li", { children: /* @__PURE__ */ a.jsx(ie, { ...s }) }, o));
|
|
1401
1401
|
return K.createElement(r, {
|
|
1402
|
-
className:
|
|
1402
|
+
className: S("button-wrapper", e),
|
|
1403
1403
|
...n,
|
|
1404
1404
|
children: i
|
|
1405
1405
|
});
|
|
1406
1406
|
};
|
|
1407
1407
|
const Re = ({ className: t = "", maxWidth: e = !1 }) => {
|
|
1408
1408
|
const n = e ? { "--max-width": `${e / 16}rem` } : {};
|
|
1409
|
-
return /* @__PURE__ */ a.jsx("hr", { className:
|
|
1409
|
+
return /* @__PURE__ */ a.jsx("hr", { className: S(t, { "has-max-width": e }), style: n });
|
|
1410
1410
|
}, vr = {
|
|
1411
1411
|
card: {
|
|
1412
1412
|
range: [
|
|
@@ -1526,7 +1526,7 @@ const Re = ({ className: t = "", maxWidth: e = !1 }) => {
|
|
|
1526
1526
|
query: r,
|
|
1527
1527
|
width: s
|
|
1528
1528
|
})} ${s}w`).join(", ");
|
|
1529
|
-
const
|
|
1529
|
+
const _t = ({ image: t, className: e, testId: n }) => {
|
|
1530
1530
|
const {
|
|
1531
1531
|
description: r,
|
|
1532
1532
|
height: i,
|
|
@@ -1571,9 +1571,9 @@ const pl = ({ image: t, className: e, testId: n }) => /* @__PURE__ */ a.jsx(
|
|
|
1571
1571
|
{
|
|
1572
1572
|
className: `image-container ${e}`,
|
|
1573
1573
|
"data-testid": n || "image-container",
|
|
1574
|
-
children: t && /* @__PURE__ */ a.jsx(
|
|
1574
|
+
children: t && /* @__PURE__ */ a.jsx(_t, { image: { ...t }, className: "image" })
|
|
1575
1575
|
}
|
|
1576
|
-
),
|
|
1576
|
+
), xt = ({
|
|
1577
1577
|
href: t,
|
|
1578
1578
|
children: e,
|
|
1579
1579
|
fallbackElement: n,
|
|
@@ -1585,7 +1585,7 @@ const pl = ({ image: t, className: e, testId: n }) => /* @__PURE__ */ a.jsx(
|
|
|
1585
1585
|
}) => {
|
|
1586
1586
|
if (t) {
|
|
1587
1587
|
const f = { ...c };
|
|
1588
|
-
return i && (f.onClick = i), s && (f["data-gtm-event-context"] = s), o && (f["data-gtm-event-type"] = o), /* @__PURE__ */ a.jsx("a", { href: t, className:
|
|
1588
|
+
return i && (f.onClick = i), s && (f["data-gtm-event-context"] = s), o && (f["data-gtm-event-type"] = o), /* @__PURE__ */ a.jsx("a", { href: t, className: S("gtm-trackable", r), ...f, children: e });
|
|
1589
1589
|
}
|
|
1590
1590
|
return n ? K.createElement(n, { children: e, className: r, ...c }) : e;
|
|
1591
1591
|
};
|
|
@@ -1600,7 +1600,7 @@ const hl = ({ elementId: t, offset: e = 20 }) => {
|
|
|
1600
1600
|
});
|
|
1601
1601
|
};
|
|
1602
1602
|
return /* @__PURE__ */ a.jsx(
|
|
1603
|
-
|
|
1603
|
+
ie,
|
|
1604
1604
|
{
|
|
1605
1605
|
variant: "secondary",
|
|
1606
1606
|
className: "return-to-nav",
|
|
@@ -1614,7 +1614,7 @@ const hl = ({ elementId: t, offset: e = 20 }) => {
|
|
|
1614
1614
|
let it = !1;
|
|
1615
1615
|
const Vi = ({ isOpen: t = !1, isLoading: e = !1, children: n }) => {
|
|
1616
1616
|
const r = G(), i = pe(null), [s, o] = te("hidden");
|
|
1617
|
-
|
|
1617
|
+
ae(() => {
|
|
1618
1618
|
const f = i.current;
|
|
1619
1619
|
if (f)
|
|
1620
1620
|
return f.addEventListener("transitionend", c), () => {
|
|
@@ -1634,7 +1634,7 @@ const Vi = ({ isOpen: t = !1, isLoading: e = !1, children: n }) => {
|
|
|
1634
1634
|
"aside",
|
|
1635
1635
|
{
|
|
1636
1636
|
ref: i,
|
|
1637
|
-
className:
|
|
1637
|
+
className: S("tooltip text-medium", s, { loading: e }),
|
|
1638
1638
|
hidden: s === "hidden",
|
|
1639
1639
|
children: e ? /* @__PURE__ */ a.jsx("p", { children: r.formatMessage({ id: "tooltip_loading" }) }) : typeof n == "string" ? /* @__PURE__ */ a.jsx("p", { children: n }) : n
|
|
1640
1640
|
}
|
|
@@ -1650,10 +1650,10 @@ const gl = ({ className: t = "", image: e, ...n }) => e ? (typeof e == "string"
|
|
|
1650
1650
|
{ height: 200, width: 768 },
|
|
1651
1651
|
{ height: 200, width: 1368 }
|
|
1652
1652
|
], e.query = "fit=thumb&f=center", /* @__PURE__ */ a.jsx(
|
|
1653
|
-
|
|
1653
|
+
_t,
|
|
1654
1654
|
{
|
|
1655
1655
|
...n,
|
|
1656
|
-
className:
|
|
1656
|
+
className: S("banner", t),
|
|
1657
1657
|
image: { ...e, aspect: "banner" }
|
|
1658
1658
|
}
|
|
1659
1659
|
)) : null;
|
|
@@ -1667,7 +1667,7 @@ const et = ({
|
|
|
1667
1667
|
return /* @__PURE__ */ a.jsx(
|
|
1668
1668
|
"section",
|
|
1669
1669
|
{
|
|
1670
|
-
className:
|
|
1670
|
+
className: S("full-width-section", e, {
|
|
1671
1671
|
[i]: i !== "default"
|
|
1672
1672
|
}),
|
|
1673
1673
|
...r,
|
|
@@ -1688,13 +1688,13 @@ const vl = ({ text: t, buttons: e, className: n = "" }) => {
|
|
|
1688
1688
|
target: "_blank",
|
|
1689
1689
|
children: i.text
|
|
1690
1690
|
});
|
|
1691
|
-
}), /* @__PURE__ */ a.jsx(et, { className:
|
|
1691
|
+
}), /* @__PURE__ */ a.jsx(et, { className: S("download-section", n), children: /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
1692
1692
|
K.createElement(
|
|
1693
1693
|
typeof t == "string" ? "h2" : t.element,
|
|
1694
1694
|
{ className: "text" },
|
|
1695
1695
|
typeof t == "string" ? t : t.text
|
|
1696
1696
|
),
|
|
1697
|
-
/* @__PURE__ */ a.jsx(
|
|
1697
|
+
/* @__PURE__ */ a.jsx(yt, { buttons: r })
|
|
1698
1698
|
] }) });
|
|
1699
1699
|
};
|
|
1700
1700
|
function ca({ href: t, setShowModal: e }) {
|
|
@@ -1702,9 +1702,9 @@ function ca({ href: t, setShowModal: e }) {
|
|
|
1702
1702
|
}
|
|
1703
1703
|
const Yi = ({ icon: t, description: e, ctaMessage: n, href: r, showEditButton: i, setShowModal: s }) => {
|
|
1704
1704
|
const { formatMessage: o } = G();
|
|
1705
|
-
return /* @__PURE__ */ a.jsxs("div", { className:
|
|
1705
|
+
return /* @__PURE__ */ a.jsxs("div", { className: S("edit-section-placeholder", { "has-icon": !!t }), style: Fi(t), children: [
|
|
1706
1706
|
/* @__PURE__ */ a.jsx("p", { children: e || o({ id: "edit_section_placeholder_description" }) }),
|
|
1707
|
-
i && /* @__PURE__ */ a.jsx(
|
|
1707
|
+
i && /* @__PURE__ */ a.jsx(ie, { href: r, variant: "secondary", size: "small", onClick: () => ca({ href: r, setShowModal: s }), children: n || o({ id: "edit_section_placeholder_cta" }) })
|
|
1708
1708
|
] });
|
|
1709
1709
|
}, bl = ({
|
|
1710
1710
|
children: t,
|
|
@@ -1717,7 +1717,7 @@ const Yi = ({ icon: t, description: e, ctaMessage: n, href: r, showEditButton: i
|
|
|
1717
1717
|
showDivider: c = !0
|
|
1718
1718
|
}) => {
|
|
1719
1719
|
const [f, l] = K.useState(!1), u = typeof r == "string" || !!n, d = () => l(!1);
|
|
1720
|
-
return /* @__PURE__ */ a.jsxs("section", { className:
|
|
1720
|
+
return /* @__PURE__ */ a.jsxs("section", { className: S("edit-section", e), children: [
|
|
1721
1721
|
n && /* @__PURE__ */ a.jsx(
|
|
1722
1722
|
Xt,
|
|
1723
1723
|
{
|
|
@@ -1726,7 +1726,7 @@ const Yi = ({ icon: t, description: e, ctaMessage: n, href: r, showEditButton: i
|
|
|
1726
1726
|
showDivider: !1,
|
|
1727
1727
|
showIcon: !1,
|
|
1728
1728
|
functions: { onClose: d },
|
|
1729
|
-
className:
|
|
1729
|
+
className: S("edit-section-modal"),
|
|
1730
1730
|
children: /* @__PURE__ */ a.jsx(Qn, { ...n, fields: n.fields, meta: {
|
|
1731
1731
|
...n == null ? void 0 : n.meta,
|
|
1732
1732
|
shouldShowCancelButton: !0,
|
|
@@ -1744,7 +1744,7 @@ const Yi = ({ icon: t, description: e, ctaMessage: n, href: r, showEditButton: i
|
|
|
1744
1744
|
),
|
|
1745
1745
|
/* @__PURE__ */ a.jsxs("div", { className: "edit-section-header", children: [
|
|
1746
1746
|
/* @__PURE__ */ a.jsx("h2", { className: "edit-section-header-title", children: i }),
|
|
1747
|
-
u && /* @__PURE__ */ a.jsx(
|
|
1747
|
+
u && /* @__PURE__ */ a.jsx(ie, { href: r, variant: "tertiary", size: "small", icon: "pencil", onClick: () => ca({ href: r, setShowModal: l }), children: "Edit" })
|
|
1748
1748
|
] }),
|
|
1749
1749
|
t || /* @__PURE__ */ a.jsx(Yi, { ...o, href: r, setShowModal: l, showEditButton: u }),
|
|
1750
1750
|
c && /* @__PURE__ */ a.jsx(Re, {})
|
|
@@ -1762,12 +1762,12 @@ const yl = ({
|
|
|
1762
1762
|
element: typeof t == "object" ? t.element : "h2",
|
|
1763
1763
|
text: typeof t == "string" ? t : typeof t == "object" ? t.text : ""
|
|
1764
1764
|
};
|
|
1765
|
-
return /* @__PURE__ */ a.jsxs("div", { className:
|
|
1765
|
+
return /* @__PURE__ */ a.jsxs("div", { className: S("logos", n), children: [
|
|
1766
1766
|
t && K.createElement(i.element, { className: "title" }, i.text),
|
|
1767
1767
|
/* @__PURE__ */ a.jsx(
|
|
1768
1768
|
"ul",
|
|
1769
1769
|
{
|
|
1770
|
-
className:
|
|
1770
|
+
className: S({
|
|
1771
1771
|
"two-col": r === 2 || r === 4,
|
|
1772
1772
|
"three-col": r === 5 || r <= 10 && r % 3 === 0
|
|
1773
1773
|
}),
|
|
@@ -1850,7 +1850,7 @@ const Ki = [
|
|
|
1850
1850
|
}), /* @__PURE__ */ a.jsx(
|
|
1851
1851
|
et,
|
|
1852
1852
|
{
|
|
1853
|
-
className:
|
|
1853
|
+
className: S("banner-section", r, i, t, {
|
|
1854
1854
|
"has-image": n,
|
|
1855
1855
|
"has-extra-spacing": i === "normal" && u.eyebrow && u.title
|
|
1856
1856
|
}),
|
|
@@ -1859,13 +1859,13 @@ const Ki = [
|
|
|
1859
1859
|
f.map((d) => {
|
|
1860
1860
|
if (u[d] && typeof u[d] == "object") {
|
|
1861
1861
|
const { text: m, element: p = "" } = u[d];
|
|
1862
|
-
return d === "text" ? /* @__PURE__ */ a.jsx(
|
|
1862
|
+
return d === "text" ? /* @__PURE__ */ a.jsx(It, { overrideType: "text-only", className: "text", children: m }, d) : K.createElement(p, { key: d, className: d }, m);
|
|
1863
1863
|
}
|
|
1864
1864
|
return null;
|
|
1865
1865
|
}),
|
|
1866
1866
|
c,
|
|
1867
1867
|
o && o.text && o.link && /* @__PURE__ */ a.jsx(
|
|
1868
|
-
|
|
1868
|
+
ie,
|
|
1869
1869
|
{
|
|
1870
1870
|
variant: n || r === "light" ? "primary" : "secondary",
|
|
1871
1871
|
size: { mobile: "medium", 768: "large" },
|
|
@@ -1875,7 +1875,7 @@ const Ki = [
|
|
|
1875
1875
|
}
|
|
1876
1876
|
)
|
|
1877
1877
|
] }),
|
|
1878
|
-
n && /* @__PURE__ */ a.jsx(
|
|
1878
|
+
n && /* @__PURE__ */ a.jsx(_t, { image: { ...n, aspect: "banner" } })
|
|
1879
1879
|
] })
|
|
1880
1880
|
}
|
|
1881
1881
|
);
|
|
@@ -1887,26 +1887,26 @@ const Qi = ({
|
|
|
1887
1887
|
image: r
|
|
1888
1888
|
}) => {
|
|
1889
1889
|
const i = () => typeof n == "string" ? /* @__PURE__ */ a.jsx(Xe, { children: n }) : n;
|
|
1890
|
-
return /* @__PURE__ */ a.jsxs(et, { className:
|
|
1890
|
+
return /* @__PURE__ */ a.jsxs(et, { className: S("highlight-section", e), children: [
|
|
1891
1891
|
r && /* @__PURE__ */ a.jsx(
|
|
1892
1892
|
"div",
|
|
1893
1893
|
{
|
|
1894
|
-
className:
|
|
1894
|
+
className: S("highlight-container highlight-image", {
|
|
1895
1895
|
[`highlight-image-${t}`]: t === "right"
|
|
1896
1896
|
}),
|
|
1897
|
-
children: /* @__PURE__ */ a.jsx(
|
|
1897
|
+
children: /* @__PURE__ */ a.jsx(_t, { image: r })
|
|
1898
1898
|
}
|
|
1899
1899
|
),
|
|
1900
1900
|
/* @__PURE__ */ a.jsx(
|
|
1901
1901
|
"div",
|
|
1902
1902
|
{
|
|
1903
|
-
className:
|
|
1903
|
+
className: S("highlight-container highlight-content-wrapper", {
|
|
1904
1904
|
"no-image": !r
|
|
1905
1905
|
}),
|
|
1906
1906
|
children: /* @__PURE__ */ a.jsx(
|
|
1907
1907
|
"div",
|
|
1908
1908
|
{
|
|
1909
|
-
className:
|
|
1909
|
+
className: S("highlight-content", {
|
|
1910
1910
|
"highlight-content-right": t === "left"
|
|
1911
1911
|
}),
|
|
1912
1912
|
children: i()
|
|
@@ -1922,11 +1922,11 @@ const wl = ({
|
|
|
1922
1922
|
title: n,
|
|
1923
1923
|
text: r,
|
|
1924
1924
|
gtmContext: i
|
|
1925
|
-
}) => !n && !r ? null : /* @__PURE__ */ a.jsxs("aside", { className:
|
|
1925
|
+
}) => !n && !r ? null : /* @__PURE__ */ a.jsxs("aside", { className: S("marketing-block", t), children: [
|
|
1926
1926
|
n && /* @__PURE__ */ a.jsx("p", { className: "title", children: n }),
|
|
1927
1927
|
r && /* @__PURE__ */ a.jsx("p", { children: r }),
|
|
1928
1928
|
e && /* @__PURE__ */ a.jsx(
|
|
1929
|
-
|
|
1929
|
+
ie,
|
|
1930
1930
|
{
|
|
1931
1931
|
variant: "secondary",
|
|
1932
1932
|
size: "medium",
|
|
@@ -1954,10 +1954,10 @@ const wl = ({
|
|
|
1954
1954
|
t && /* @__PURE__ */ a.jsx(bi, { initialIsOpen: !1 })
|
|
1955
1955
|
] });
|
|
1956
1956
|
};
|
|
1957
|
-
var Xi = Un({ client:
|
|
1957
|
+
var Xi = Un({ client: Ft });
|
|
1958
1958
|
function es(t) {
|
|
1959
1959
|
var e = t.children, n = t.client, r = t.apiKey, i = t.options, s = vt(function() {
|
|
1960
|
-
return n && r && console.warn("[PostHog.js] You have provided both a client and an apiKey to PostHogProvider. The apiKey will be ignored in favour of the client."), n && i && console.warn("[PostHog.js] You have provided both a client and options to PostHogProvider. The options will be ignored in favour of the client."), n || (r && (
|
|
1960
|
+
return n && r && console.warn("[PostHog.js] You have provided both a client and an apiKey to PostHogProvider. The apiKey will be ignored in favour of the client."), n && i && console.warn("[PostHog.js] You have provided both a client and options to PostHogProvider. The options will be ignored in favour of the client."), n || (r && (Ft.__loaded && console.warn("[PostHog.js] was already loaded elsewhere. This may cause issues."), Ft.init(r, i)), Ft);
|
|
1961
1961
|
}, [n, r]);
|
|
1962
1962
|
return K.createElement(Xi.Provider, { value: { client: s } }, e);
|
|
1963
1963
|
}
|
|
@@ -1992,7 +1992,7 @@ function Vn() {
|
|
|
1992
1992
|
}
|
|
1993
1993
|
const rs = ({ children: t, user: e }) => /* @__PURE__ */ a.jsx(Oe.Provider, { value: e, children: t }), kl = ({ bootstrap: t, children: e, intl: n, showDevTools: r }) => {
|
|
1994
1994
|
const [i, s] = te({ isLoading: !0 });
|
|
1995
|
-
return
|
|
1995
|
+
return ae(() => {
|
|
1996
1996
|
t().then((o) => {
|
|
1997
1997
|
s({ ...o, isLoading: !1 }), zi(5e3);
|
|
1998
1998
|
}).catch(() => s({ isLoading: !1 }));
|
|
@@ -2000,7 +2000,7 @@ const rs = ({ children: t, user: e }) => /* @__PURE__ */ a.jsx(Oe.Provider, { va
|
|
|
2000
2000
|
};
|
|
2001
2001
|
const la = ({ label: t = !1, className: e = "", children: n }) => {
|
|
2002
2002
|
const r = G();
|
|
2003
|
-
return /* @__PURE__ */ a.jsxs("details", { className:
|
|
2003
|
+
return /* @__PURE__ */ a.jsxs("details", { className: S("collapsible-section", e), children: [
|
|
2004
2004
|
/* @__PURE__ */ a.jsx("summary", { children: t || r.formatMessage({ id: "collapsibleSection_summary" }) }),
|
|
2005
2005
|
/* @__PURE__ */ a.jsx("div", { className: "content", children: n })
|
|
2006
2006
|
] });
|
|
@@ -2016,7 +2016,7 @@ const Ae = ({
|
|
|
2016
2016
|
return /* @__PURE__ */ a.jsx(
|
|
2017
2017
|
"div",
|
|
2018
2018
|
{
|
|
2019
|
-
className:
|
|
2019
|
+
className: S("highlighted-text-box", t, n, {
|
|
2020
2020
|
"has-icon": e
|
|
2021
2021
|
}),
|
|
2022
2022
|
style: s,
|
|
@@ -2047,11 +2047,11 @@ const tt = ({
|
|
|
2047
2047
|
Ae,
|
|
2048
2048
|
{
|
|
2049
2049
|
variant: "subtle",
|
|
2050
|
-
className:
|
|
2050
|
+
className: S("empty-state-box", t, r),
|
|
2051
2051
|
children: /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
2052
2052
|
e && typeof e == "string" ? /* @__PURE__ */ a.jsx(Xe, { options: { forceBlock: !0 }, children: e }) : e,
|
|
2053
2053
|
i && typeof n == "object" && (l || /* @__PURE__ */ a.jsx(
|
|
2054
|
-
|
|
2054
|
+
ie,
|
|
2055
2055
|
{
|
|
2056
2056
|
...u,
|
|
2057
2057
|
variant: n.variant ? n.variant : "secondary",
|
|
@@ -2070,7 +2070,7 @@ const as = ({
|
|
|
2070
2070
|
className: e = "",
|
|
2071
2071
|
heading: n = !1,
|
|
2072
2072
|
children: r
|
|
2073
|
-
}) => /* @__PURE__ */ a.jsxs("div", { className:
|
|
2073
|
+
}) => /* @__PURE__ */ a.jsxs("div", { className: S("helper-text-box text-small", t, e), children: [
|
|
2074
2074
|
n && /* @__PURE__ */ a.jsx("p", { className: "title", children: n }),
|
|
2075
2075
|
typeof r == "string" ? /* @__PURE__ */ a.jsx(
|
|
2076
2076
|
Xe,
|
|
@@ -2092,13 +2092,13 @@ const jl = ({
|
|
|
2092
2092
|
children: i
|
|
2093
2093
|
}) => {
|
|
2094
2094
|
const s = G(), o = pe(null), [c, f] = te(""), [l, u] = te("closed");
|
|
2095
|
-
|
|
2095
|
+
ae(() => {
|
|
2096
2096
|
const p = o.current;
|
|
2097
2097
|
if (p)
|
|
2098
2098
|
return p.addEventListener("transitionend", d), () => {
|
|
2099
2099
|
p.removeEventListener("transitionend", d);
|
|
2100
2100
|
};
|
|
2101
|
-
}, []),
|
|
2101
|
+
}, []), ae(() => {
|
|
2102
2102
|
if (!r || typeof r != "string")
|
|
2103
2103
|
return;
|
|
2104
2104
|
const p = r.split(`
|
|
@@ -2107,7 +2107,7 @@ const jl = ({
|
|
|
2107
2107
|
p.length < 3 ? `${r.substring(0, 400)}...` : p.slice(0, 3).join(`
|
|
2108
2108
|
`)
|
|
2109
2109
|
);
|
|
2110
|
-
}, [r]),
|
|
2110
|
+
}, [r]), ae(() => {
|
|
2111
2111
|
l === "ready-to-close" && u("closing");
|
|
2112
2112
|
}, [l]);
|
|
2113
2113
|
const d = ({ propertyName: p }) => {
|
|
@@ -2120,19 +2120,19 @@ const jl = ({
|
|
|
2120
2120
|
Ae,
|
|
2121
2121
|
{
|
|
2122
2122
|
variant: "subtle",
|
|
2123
|
-
className:
|
|
2123
|
+
className: S("hide-show-text-box", t),
|
|
2124
2124
|
children: [
|
|
2125
|
-
/* @__PURE__ */ a.jsxs("div", { ref: o, className:
|
|
2125
|
+
/* @__PURE__ */ a.jsxs("div", { ref: o, className: S("content", l), children: [
|
|
2126
2126
|
/* @__PURE__ */ a.jsx(Xe, { options: { forceBlock: !0 }, children: l === "closed" ? c : r }),
|
|
2127
2127
|
l !== "closed" && i
|
|
2128
2128
|
] }),
|
|
2129
2129
|
/* @__PURE__ */ a.jsx("p", { className: "cta", children: /* @__PURE__ */ a.jsx(
|
|
2130
|
-
|
|
2130
|
+
ie,
|
|
2131
2131
|
{
|
|
2132
2132
|
variant: "tertiary",
|
|
2133
2133
|
icon: { icon: "navigation_arrow", position: "left", animate: !0 },
|
|
2134
2134
|
styling: { muted: !0 },
|
|
2135
|
-
className:
|
|
2135
|
+
className: S({ "rotate-180": m }),
|
|
2136
2136
|
onClick: () => {
|
|
2137
2137
|
u(m ? "ready-to-close" : "opening");
|
|
2138
2138
|
},
|
|
@@ -2231,7 +2231,7 @@ const jl = ({
|
|
|
2231
2231
|
else
|
|
2232
2232
|
break;
|
|
2233
2233
|
}
|
|
2234
|
-
return i ? (n = { ...n, className: "button primary medium" }, /* @__PURE__ */ a.jsx("p", { className: "center", children: /* @__PURE__ */ a.jsx(
|
|
2234
|
+
return i ? (n = { ...n, className: "button primary medium" }, /* @__PURE__ */ a.jsx("p", { className: "center", children: /* @__PURE__ */ a.jsx(ie, { variant: "primary", size: "medium", ...n, children: r }) })) : /* @__PURE__ */ a.jsx("a", { ...n, children: r });
|
|
2235
2235
|
}, us = ({ children: t }) => /* @__PURE__ */ a.jsx("span", { children: t });
|
|
2236
2236
|
const fs = {
|
|
2237
2237
|
default: {
|
|
@@ -2265,7 +2265,7 @@ const fs = {
|
|
|
2265
2265
|
iframe: ye,
|
|
2266
2266
|
button: ye
|
|
2267
2267
|
}
|
|
2268
|
-
},
|
|
2268
|
+
}, It = ({
|
|
2269
2269
|
className: t = "",
|
|
2270
2270
|
options: e = {},
|
|
2271
2271
|
children: n,
|
|
@@ -2277,7 +2277,7 @@ const fs = {
|
|
|
2277
2277
|
forceBlock: !0,
|
|
2278
2278
|
overrides: fs[r]
|
|
2279
2279
|
};
|
|
2280
|
-
return /* @__PURE__ */ a.jsx("div", { className:
|
|
2280
|
+
return /* @__PURE__ */ a.jsx("div", { className: S("markdown-text", t), children: /* @__PURE__ */ a.jsx(Xe, { options: { ...i, ...e }, children: n }) });
|
|
2281
2281
|
};
|
|
2282
2282
|
const ms = ({
|
|
2283
2283
|
maxWidth: t = !1,
|
|
@@ -2287,8 +2287,8 @@ const ms = ({
|
|
|
2287
2287
|
className: i = ""
|
|
2288
2288
|
}) => {
|
|
2289
2289
|
const s = t ? { "--max-width": `${t / 16}rem` } : {};
|
|
2290
|
-
return /* @__PURE__ */ a.jsxs("section", { className:
|
|
2291
|
-
/* @__PURE__ */ a.jsxs("div", { className:
|
|
2290
|
+
return /* @__PURE__ */ a.jsxs("section", { className: S("page-heading", i), children: [
|
|
2291
|
+
/* @__PURE__ */ a.jsxs("div", { className: S("content", { "has-max-width": t }), style: s, children: [
|
|
2292
2292
|
e && e.text && K.createElement(e.element || "h1", { className: "title" }, e.text),
|
|
2293
2293
|
n && n.text && K.createElement(
|
|
2294
2294
|
n.element || "h2",
|
|
@@ -2299,14 +2299,14 @@ const ms = ({
|
|
|
2299
2299
|
r
|
|
2300
2300
|
] });
|
|
2301
2301
|
};
|
|
2302
|
-
const
|
|
2302
|
+
const Lt = ({
|
|
2303
2303
|
size: t = "medium",
|
|
2304
2304
|
variant: e = "default",
|
|
2305
2305
|
className: n = "",
|
|
2306
2306
|
children: r,
|
|
2307
2307
|
...i
|
|
2308
|
-
}) => /* @__PURE__ */ a.jsx("span", { className:
|
|
2309
|
-
const
|
|
2308
|
+
}) => /* @__PURE__ */ a.jsx("span", { className: S("pill", t, e, n), ...i, children: r });
|
|
2309
|
+
const Bt = ({
|
|
2310
2310
|
element: t = "p",
|
|
2311
2311
|
children: e = null,
|
|
2312
2312
|
className: n = "",
|
|
@@ -2315,7 +2315,7 @@ const Lt = ({
|
|
|
2315
2315
|
t,
|
|
2316
2316
|
{
|
|
2317
2317
|
...r,
|
|
2318
|
-
className:
|
|
2318
|
+
className: S("status-banner text-small", n),
|
|
2319
2319
|
"aria-live": "assertive"
|
|
2320
2320
|
},
|
|
2321
2321
|
e
|
|
@@ -2330,7 +2330,7 @@ const hs = ({ progress: t = 0, text: e = !1, className: n = "" }) => {
|
|
|
2330
2330
|
return /* @__PURE__ */ a.jsx(
|
|
2331
2331
|
"span",
|
|
2332
2332
|
{
|
|
2333
|
-
className:
|
|
2333
|
+
className: S(`progress-bar section-${i}`, n),
|
|
2334
2334
|
style: s,
|
|
2335
2335
|
children: /* @__PURE__ */ a.jsx(be, { children: e ? `${t} ${e}` : r.formatMessage({ id: "progressBar" }, { number: t }) })
|
|
2336
2336
|
}
|
|
@@ -2353,7 +2353,7 @@ const un = "loadingBlock_", vs = ({ progress: t = 0, steps: e = !1, className: n
|
|
|
2353
2353
|
return /* @__PURE__ */ a.jsxs(
|
|
2354
2354
|
Ae,
|
|
2355
2355
|
{
|
|
2356
|
-
className:
|
|
2356
|
+
className: S("loading-block", n, {
|
|
2357
2357
|
"has-icon": i && e[i].icon
|
|
2358
2358
|
}),
|
|
2359
2359
|
variant: "subtle",
|
|
@@ -2369,7 +2369,7 @@ const Te = ({ element: t = "div", className: e = "", ...n }) => /* @__PURE__ */
|
|
|
2369
2369
|
Wn,
|
|
2370
2370
|
{
|
|
2371
2371
|
element: t,
|
|
2372
|
-
className:
|
|
2372
|
+
className: S("loading-placeholder", e),
|
|
2373
2373
|
...n
|
|
2374
2374
|
}
|
|
2375
2375
|
);
|
|
@@ -2408,17 +2408,17 @@ const In = {
|
|
|
2408
2408
|
"cards-section",
|
|
2409
2409
|
"footer"
|
|
2410
2410
|
]
|
|
2411
|
-
}, ua = (t, e) => t in In ? /* @__PURE__ */ a.jsx("div", { className: t, children: In[t].map((n, r) => ua(n, r)) }, e) : /* @__PURE__ */ a.jsx(Te, { className: t }, e), fa = ({ layout: t = "overview-page", ...e }) => /* @__PURE__ */ a.jsx("div", { className:
|
|
2411
|
+
}, ua = (t, e) => t in In ? /* @__PURE__ */ a.jsx("div", { className: t, children: In[t].map((n, r) => ua(n, r)) }, e) : /* @__PURE__ */ a.jsx(Te, { className: t }, e), fa = ({ layout: t = "overview-page", ...e }) => /* @__PURE__ */ a.jsx("div", { className: S("loading-state", t), ...e, children: In[t].map((n, r) => ua(n, r)) }), ma = (t) => {
|
|
2412
2412
|
const e = t && t.toUpperCase().split(" ");
|
|
2413
2413
|
return Array.isArray(e) && e.length > 1 && e[0] !== "" ? e[1] === "" ? e[0][0] : e[0][0] + e[e.length - 1][0] : t ? t.substr(0, 1) : "";
|
|
2414
|
-
},
|
|
2415
|
-
const e = Math.ceil(26 /
|
|
2414
|
+
}, kt = ["#5AB6A3", "#A2D7AF", "#806056", "#3962B3"], bs = (t) => {
|
|
2415
|
+
const e = Math.ceil(26 / kt.length), n = ma(t).toLowerCase();
|
|
2416
2416
|
if (n === "")
|
|
2417
|
-
return
|
|
2417
|
+
return kt[0];
|
|
2418
2418
|
const r = n.charCodeAt(0) - 96;
|
|
2419
|
-
for (let i = 0; i <
|
|
2419
|
+
for (let i = 0; i < kt.length; i++)
|
|
2420
2420
|
if (r <= e * (i + 1))
|
|
2421
|
-
return
|
|
2421
|
+
return kt[i];
|
|
2422
2422
|
};
|
|
2423
2423
|
const yr = 256, ze = ({
|
|
2424
2424
|
className: t = "",
|
|
@@ -2430,7 +2430,7 @@ const yr = 256, ze = ({
|
|
|
2430
2430
|
...o
|
|
2431
2431
|
}) => {
|
|
2432
2432
|
const [c, f] = te(!1), l = pe(null);
|
|
2433
|
-
|
|
2433
|
+
ae(() => {
|
|
2434
2434
|
const d = l.current;
|
|
2435
2435
|
if (!d)
|
|
2436
2436
|
return;
|
|
@@ -2444,7 +2444,7 @@ const yr = 256, ze = ({
|
|
|
2444
2444
|
return e && e !== "" && !c && (e.includes("http") || e.includes("//")) && (u = !0), /* @__PURE__ */ a.jsx(
|
|
2445
2445
|
"figure",
|
|
2446
2446
|
{
|
|
2447
|
-
className:
|
|
2447
|
+
className: S("profile-picture", t, { error: c }),
|
|
2448
2448
|
...o,
|
|
2449
2449
|
children: u ? /* @__PURE__ */ a.jsx(
|
|
2450
2450
|
"img",
|
|
@@ -2498,9 +2498,9 @@ const Yn = ({
|
|
|
2498
2498
|
}));
|
|
2499
2499
|
const { name: f, url: l, image: u } = c, d = ys(c), m = n && n.createdAt ? Dn(n.createdAt) : !1, p = n && n.createdAt ? sa(n.createdAt) : "";
|
|
2500
2500
|
return K.createElement(t, {
|
|
2501
|
-
className:
|
|
2501
|
+
className: S("member text-medium", s),
|
|
2502
2502
|
children: /* @__PURE__ */ a.jsxs(
|
|
2503
|
-
|
|
2503
|
+
xt,
|
|
2504
2504
|
{
|
|
2505
2505
|
href: l,
|
|
2506
2506
|
gtmType: i,
|
|
@@ -2545,7 +2545,7 @@ const _r = {
|
|
|
2545
2545
|
const u = G();
|
|
2546
2546
|
return !n || n.length === 0 ? null : K.createElement(t, {
|
|
2547
2547
|
...l,
|
|
2548
|
-
className:
|
|
2548
|
+
className: S("contributors", f, i, { "has-gap": s }),
|
|
2549
2549
|
children: /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
2550
2550
|
/* @__PURE__ */ a.jsx("ul", { children: n.map((d, m) => {
|
|
2551
2551
|
let p, v = "";
|
|
@@ -2567,7 +2567,7 @@ const _r = {
|
|
|
2567
2567
|
p = /* @__PURE__ */ a.jsxs(
|
|
2568
2568
|
"small",
|
|
2569
2569
|
{
|
|
2570
|
-
className:
|
|
2570
|
+
className: S({ "large-number": b > 99 }),
|
|
2571
2571
|
children: [
|
|
2572
2572
|
"+",
|
|
2573
2573
|
Ui(b, 0)
|
|
@@ -2575,13 +2575,13 @@ const _r = {
|
|
|
2575
2575
|
}
|
|
2576
2576
|
), v = "number-left";
|
|
2577
2577
|
}
|
|
2578
|
-
return p ? /* @__PURE__ */ a.jsx("li", { className:
|
|
2578
|
+
return p ? /* @__PURE__ */ a.jsx("li", { className: S("contributor", v), children: p }, m) : null;
|
|
2579
2579
|
}) }),
|
|
2580
2580
|
r && /* @__PURE__ */ a.jsx("span", { className: "label", children: typeof r == "string" ? r : n.length === 1 ? typeof n[0] == "string" ? u.formatMessage({ id: `member_${n[0]}` }) : Ke(n[0].name || "", 20) : null })
|
|
2581
2581
|
] })
|
|
2582
2582
|
});
|
|
2583
2583
|
};
|
|
2584
|
-
var Ln = { exports: {} },
|
|
2584
|
+
var Ln = { exports: {} }, jt = { exports: {} }, de = {};
|
|
2585
2585
|
/** @license React v16.13.1
|
|
2586
2586
|
* react-is.production.min.js
|
|
2587
2587
|
*
|
|
@@ -2598,8 +2598,8 @@ function _s() {
|
|
|
2598
2598
|
var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, i = t ? Symbol.for("react.strict_mode") : 60108, s = t ? Symbol.for("react.profiler") : 60114, o = t ? Symbol.for("react.provider") : 60109, c = t ? Symbol.for("react.context") : 60110, f = t ? Symbol.for("react.async_mode") : 60111, l = t ? Symbol.for("react.concurrent_mode") : 60111, u = t ? Symbol.for("react.forward_ref") : 60112, d = t ? Symbol.for("react.suspense") : 60113, m = t ? Symbol.for("react.suspense_list") : 60120, p = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, b = t ? Symbol.for("react.block") : 60121, _ = t ? Symbol.for("react.fundamental") : 60117, g = t ? Symbol.for("react.responder") : 60118, y = t ? Symbol.for("react.scope") : 60119;
|
|
2599
2599
|
function E(w) {
|
|
2600
2600
|
if (typeof w == "object" && w !== null) {
|
|
2601
|
-
var
|
|
2602
|
-
switch (
|
|
2601
|
+
var z = w.$$typeof;
|
|
2602
|
+
switch (z) {
|
|
2603
2603
|
case e:
|
|
2604
2604
|
switch (w = w.type, w) {
|
|
2605
2605
|
case f:
|
|
@@ -2618,11 +2618,11 @@ function _s() {
|
|
|
2618
2618
|
case o:
|
|
2619
2619
|
return w;
|
|
2620
2620
|
default:
|
|
2621
|
-
return
|
|
2621
|
+
return z;
|
|
2622
2622
|
}
|
|
2623
2623
|
}
|
|
2624
2624
|
case n:
|
|
2625
|
-
return
|
|
2625
|
+
return z;
|
|
2626
2626
|
}
|
|
2627
2627
|
}
|
|
2628
2628
|
}
|
|
@@ -2670,16 +2670,16 @@ var wr;
|
|
|
2670
2670
|
function xs() {
|
|
2671
2671
|
return wr || (wr = 1, process.env.NODE_ENV !== "production" && function() {
|
|
2672
2672
|
var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, i = t ? Symbol.for("react.strict_mode") : 60108, s = t ? Symbol.for("react.profiler") : 60114, o = t ? Symbol.for("react.provider") : 60109, c = t ? Symbol.for("react.context") : 60110, f = t ? Symbol.for("react.async_mode") : 60111, l = t ? Symbol.for("react.concurrent_mode") : 60111, u = t ? Symbol.for("react.forward_ref") : 60112, d = t ? Symbol.for("react.suspense") : 60113, m = t ? Symbol.for("react.suspense_list") : 60120, p = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, b = t ? Symbol.for("react.block") : 60121, _ = t ? Symbol.for("react.fundamental") : 60117, g = t ? Symbol.for("react.responder") : 60118, y = t ? Symbol.for("react.scope") : 60119;
|
|
2673
|
-
function E(
|
|
2674
|
-
return typeof
|
|
2675
|
-
|
|
2673
|
+
function E(D) {
|
|
2674
|
+
return typeof D == "string" || typeof D == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
|
|
2675
|
+
D === r || D === l || D === s || D === i || D === d || D === m || typeof D == "object" && D !== null && (D.$$typeof === v || D.$$typeof === p || D.$$typeof === o || D.$$typeof === c || D.$$typeof === u || D.$$typeof === _ || D.$$typeof === g || D.$$typeof === y || D.$$typeof === b);
|
|
2676
2676
|
}
|
|
2677
|
-
function j(
|
|
2678
|
-
if (typeof
|
|
2679
|
-
var ve =
|
|
2677
|
+
function j(D) {
|
|
2678
|
+
if (typeof D == "object" && D !== null) {
|
|
2679
|
+
var ve = D.$$typeof;
|
|
2680
2680
|
switch (ve) {
|
|
2681
2681
|
case e:
|
|
2682
|
-
var $e =
|
|
2682
|
+
var $e = D.type;
|
|
2683
2683
|
switch ($e) {
|
|
2684
2684
|
case f:
|
|
2685
2685
|
case l:
|
|
@@ -2706,52 +2706,52 @@ function xs() {
|
|
|
2706
2706
|
}
|
|
2707
2707
|
}
|
|
2708
2708
|
}
|
|
2709
|
-
var w = f,
|
|
2710
|
-
function
|
|
2711
|
-
return
|
|
2709
|
+
var w = f, z = l, F = c, q = o, M = e, O = u, C = r, T = v, x = p, $ = n, I = s, U = i, A = d, W = !1;
|
|
2710
|
+
function J(D) {
|
|
2711
|
+
return W || (W = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), k(D) || j(D) === f;
|
|
2712
2712
|
}
|
|
2713
|
-
function k(
|
|
2714
|
-
return j(
|
|
2713
|
+
function k(D) {
|
|
2714
|
+
return j(D) === l;
|
|
2715
2715
|
}
|
|
2716
|
-
function N(
|
|
2717
|
-
return j(
|
|
2716
|
+
function N(D) {
|
|
2717
|
+
return j(D) === c;
|
|
2718
2718
|
}
|
|
2719
|
-
function Z(
|
|
2720
|
-
return j(
|
|
2719
|
+
function Z(D) {
|
|
2720
|
+
return j(D) === o;
|
|
2721
2721
|
}
|
|
2722
|
-
function
|
|
2723
|
-
return typeof
|
|
2722
|
+
function B(D) {
|
|
2723
|
+
return typeof D == "object" && D !== null && D.$$typeof === e;
|
|
2724
2724
|
}
|
|
2725
|
-
function
|
|
2726
|
-
return j(
|
|
2725
|
+
function H(D) {
|
|
2726
|
+
return j(D) === u;
|
|
2727
2727
|
}
|
|
2728
|
-
function
|
|
2729
|
-
return j(
|
|
2728
|
+
function ee(D) {
|
|
2729
|
+
return j(D) === r;
|
|
2730
2730
|
}
|
|
2731
|
-
function Y(
|
|
2732
|
-
return j(
|
|
2731
|
+
function Y(D) {
|
|
2732
|
+
return j(D) === v;
|
|
2733
2733
|
}
|
|
2734
|
-
function
|
|
2735
|
-
return j(
|
|
2734
|
+
function V(D) {
|
|
2735
|
+
return j(D) === p;
|
|
2736
2736
|
}
|
|
2737
|
-
function
|
|
2738
|
-
return j(
|
|
2737
|
+
function X(D) {
|
|
2738
|
+
return j(D) === n;
|
|
2739
2739
|
}
|
|
2740
|
-
function re(
|
|
2741
|
-
return j(
|
|
2740
|
+
function re(D) {
|
|
2741
|
+
return j(D) === s;
|
|
2742
2742
|
}
|
|
2743
|
-
function
|
|
2744
|
-
return j(
|
|
2743
|
+
function R(D) {
|
|
2744
|
+
return j(D) === i;
|
|
2745
2745
|
}
|
|
2746
|
-
function oe(
|
|
2747
|
-
return j(
|
|
2746
|
+
function oe(D) {
|
|
2747
|
+
return j(D) === d;
|
|
2748
2748
|
}
|
|
2749
|
-
ue.AsyncMode = w, ue.ConcurrentMode =
|
|
2749
|
+
ue.AsyncMode = w, ue.ConcurrentMode = z, ue.ContextConsumer = F, ue.ContextProvider = q, ue.Element = M, ue.ForwardRef = O, ue.Fragment = C, ue.Lazy = T, ue.Memo = x, ue.Portal = $, ue.Profiler = I, ue.StrictMode = U, ue.Suspense = A, ue.isAsyncMode = J, ue.isConcurrentMode = k, ue.isContextConsumer = N, ue.isContextProvider = Z, ue.isElement = B, ue.isForwardRef = H, ue.isFragment = ee, ue.isLazy = Y, ue.isMemo = V, ue.isPortal = X, ue.isProfiler = re, ue.isStrictMode = R, ue.isSuspense = oe, ue.isValidElementType = E, ue.typeOf = j;
|
|
2750
2750
|
}()), ue;
|
|
2751
2751
|
}
|
|
2752
2752
|
var kr;
|
|
2753
2753
|
function ga() {
|
|
2754
|
-
return kr || (kr = 1, process.env.NODE_ENV === "production" ?
|
|
2754
|
+
return kr || (kr = 1, process.env.NODE_ENV === "production" ? jt.exports = _s() : jt.exports = xs()), jt.exports;
|
|
2755
2755
|
}
|
|
2756
2756
|
/*
|
|
2757
2757
|
object-assign
|
|
@@ -2905,10 +2905,10 @@ function js() {
|
|
|
2905
2905
|
arrayOf: E,
|
|
2906
2906
|
element: j(),
|
|
2907
2907
|
elementType: w(),
|
|
2908
|
-
instanceOf:
|
|
2908
|
+
instanceOf: z,
|
|
2909
2909
|
node: O(),
|
|
2910
2910
|
objectOf: q,
|
|
2911
|
-
oneOf:
|
|
2911
|
+
oneOf: F,
|
|
2912
2912
|
oneOfType: M,
|
|
2913
2913
|
shape: T,
|
|
2914
2914
|
exact: x
|
|
@@ -2923,33 +2923,33 @@ function js() {
|
|
|
2923
2923
|
function _(k) {
|
|
2924
2924
|
if (process.env.NODE_ENV !== "production")
|
|
2925
2925
|
var N = {}, Z = 0;
|
|
2926
|
-
function
|
|
2927
|
-
if (
|
|
2926
|
+
function B(ee, Y, V, X, re, R, oe) {
|
|
2927
|
+
if (X = X || m, R = R || V, oe !== n) {
|
|
2928
2928
|
if (f) {
|
|
2929
|
-
var
|
|
2929
|
+
var D = new Error(
|
|
2930
2930
|
"Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types"
|
|
2931
2931
|
);
|
|
2932
|
-
throw
|
|
2932
|
+
throw D.name = "Invariant Violation", D;
|
|
2933
2933
|
} else if (process.env.NODE_ENV !== "production" && typeof console < "u") {
|
|
2934
|
-
var ve =
|
|
2934
|
+
var ve = X + ":" + V;
|
|
2935
2935
|
!N[ve] && // Avoid spamming the console because they are often not actionable except for lib authors
|
|
2936
2936
|
Z < 3 && (s(
|
|
2937
|
-
"You are manually calling a React.PropTypes validation function for the `" +
|
|
2937
|
+
"You are manually calling a React.PropTypes validation function for the `" + R + "` prop on `" + X + "`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."
|
|
2938
2938
|
), N[ve] = !0, Z++);
|
|
2939
2939
|
}
|
|
2940
2940
|
}
|
|
2941
|
-
return Y[
|
|
2941
|
+
return Y[V] == null ? ee ? Y[V] === null ? new b("The " + re + " `" + R + "` is marked as required " + ("in `" + X + "`, but its value is `null`.")) : new b("The " + re + " `" + R + "` is marked as required in " + ("`" + X + "`, but its value is `undefined`.")) : null : k(Y, V, X, re, R);
|
|
2942
2942
|
}
|
|
2943
|
-
var
|
|
2944
|
-
return
|
|
2943
|
+
var H = B.bind(null, !1);
|
|
2944
|
+
return H.isRequired = B.bind(null, !0), H;
|
|
2945
2945
|
}
|
|
2946
2946
|
function g(k) {
|
|
2947
|
-
function N(Z,
|
|
2948
|
-
var
|
|
2947
|
+
function N(Z, B, H, ee, Y, V) {
|
|
2948
|
+
var X = Z[B], re = U(X);
|
|
2949
2949
|
if (re !== k) {
|
|
2950
|
-
var
|
|
2950
|
+
var R = A(X);
|
|
2951
2951
|
return new b(
|
|
2952
|
-
"Invalid " +
|
|
2952
|
+
"Invalid " + ee + " `" + Y + "` of type " + ("`" + R + "` supplied to `" + H + "`, expected ") + ("`" + k + "`."),
|
|
2953
2953
|
{ expectedType: k }
|
|
2954
2954
|
);
|
|
2955
2955
|
}
|
|
@@ -2961,84 +2961,84 @@ function js() {
|
|
|
2961
2961
|
return _(o);
|
|
2962
2962
|
}
|
|
2963
2963
|
function E(k) {
|
|
2964
|
-
function N(Z,
|
|
2964
|
+
function N(Z, B, H, ee, Y) {
|
|
2965
2965
|
if (typeof k != "function")
|
|
2966
|
-
return new b("Property `" + Y + "` of component `" +
|
|
2967
|
-
var
|
|
2968
|
-
if (!Array.isArray(
|
|
2969
|
-
var
|
|
2970
|
-
return new b("Invalid " +
|
|
2966
|
+
return new b("Property `" + Y + "` of component `" + H + "` has invalid PropType notation inside arrayOf.");
|
|
2967
|
+
var V = Z[B];
|
|
2968
|
+
if (!Array.isArray(V)) {
|
|
2969
|
+
var X = U(V);
|
|
2970
|
+
return new b("Invalid " + ee + " `" + Y + "` of type " + ("`" + X + "` supplied to `" + H + "`, expected an array."));
|
|
2971
2971
|
}
|
|
2972
|
-
for (var re = 0; re <
|
|
2973
|
-
var
|
|
2974
|
-
if (
|
|
2975
|
-
return
|
|
2972
|
+
for (var re = 0; re < V.length; re++) {
|
|
2973
|
+
var R = k(V, re, H, ee, Y + "[" + re + "]", n);
|
|
2974
|
+
if (R instanceof Error)
|
|
2975
|
+
return R;
|
|
2976
2976
|
}
|
|
2977
2977
|
return null;
|
|
2978
2978
|
}
|
|
2979
2979
|
return _(N);
|
|
2980
2980
|
}
|
|
2981
2981
|
function j() {
|
|
2982
|
-
function k(N, Z,
|
|
2982
|
+
function k(N, Z, B, H, ee) {
|
|
2983
2983
|
var Y = N[Z];
|
|
2984
2984
|
if (!c(Y)) {
|
|
2985
|
-
var
|
|
2986
|
-
return new b("Invalid " +
|
|
2985
|
+
var V = U(Y);
|
|
2986
|
+
return new b("Invalid " + H + " `" + ee + "` of type " + ("`" + V + "` supplied to `" + B + "`, expected a single ReactElement."));
|
|
2987
2987
|
}
|
|
2988
2988
|
return null;
|
|
2989
2989
|
}
|
|
2990
2990
|
return _(k);
|
|
2991
2991
|
}
|
|
2992
2992
|
function w() {
|
|
2993
|
-
function k(N, Z,
|
|
2993
|
+
function k(N, Z, B, H, ee) {
|
|
2994
2994
|
var Y = N[Z];
|
|
2995
2995
|
if (!t.isValidElementType(Y)) {
|
|
2996
|
-
var
|
|
2997
|
-
return new b("Invalid " +
|
|
2996
|
+
var V = U(Y);
|
|
2997
|
+
return new b("Invalid " + H + " `" + ee + "` of type " + ("`" + V + "` supplied to `" + B + "`, expected a single ReactElement type."));
|
|
2998
2998
|
}
|
|
2999
2999
|
return null;
|
|
3000
3000
|
}
|
|
3001
3001
|
return _(k);
|
|
3002
3002
|
}
|
|
3003
|
-
function
|
|
3004
|
-
function N(Z,
|
|
3005
|
-
if (!(Z[
|
|
3006
|
-
var
|
|
3007
|
-
return new b("Invalid " +
|
|
3003
|
+
function z(k) {
|
|
3004
|
+
function N(Z, B, H, ee, Y) {
|
|
3005
|
+
if (!(Z[B] instanceof k)) {
|
|
3006
|
+
var V = k.name || m, X = J(Z[B]);
|
|
3007
|
+
return new b("Invalid " + ee + " `" + Y + "` of type " + ("`" + X + "` supplied to `" + H + "`, expected ") + ("instance of `" + V + "`."));
|
|
3008
3008
|
}
|
|
3009
3009
|
return null;
|
|
3010
3010
|
}
|
|
3011
3011
|
return _(N);
|
|
3012
3012
|
}
|
|
3013
|
-
function
|
|
3013
|
+
function F(k) {
|
|
3014
3014
|
if (!Array.isArray(k))
|
|
3015
3015
|
return process.env.NODE_ENV !== "production" && (arguments.length > 1 ? s(
|
|
3016
3016
|
"Invalid arguments supplied to oneOf, expected an array, got " + arguments.length + " arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."
|
|
3017
3017
|
) : s("Invalid argument supplied to oneOf, expected an array.")), o;
|
|
3018
|
-
function N(Z,
|
|
3019
|
-
for (var
|
|
3020
|
-
if (v(
|
|
3018
|
+
function N(Z, B, H, ee, Y) {
|
|
3019
|
+
for (var V = Z[B], X = 0; X < k.length; X++)
|
|
3020
|
+
if (v(V, k[X]))
|
|
3021
3021
|
return null;
|
|
3022
|
-
var re = JSON.stringify(k, function(oe,
|
|
3023
|
-
var ve =
|
|
3024
|
-
return ve === "symbol" ? String(
|
|
3022
|
+
var re = JSON.stringify(k, function(oe, D) {
|
|
3023
|
+
var ve = A(D);
|
|
3024
|
+
return ve === "symbol" ? String(D) : D;
|
|
3025
3025
|
});
|
|
3026
|
-
return new b("Invalid " +
|
|
3026
|
+
return new b("Invalid " + ee + " `" + Y + "` of value `" + String(V) + "` " + ("supplied to `" + H + "`, expected one of " + re + "."));
|
|
3027
3027
|
}
|
|
3028
3028
|
return _(N);
|
|
3029
3029
|
}
|
|
3030
3030
|
function q(k) {
|
|
3031
|
-
function N(Z,
|
|
3031
|
+
function N(Z, B, H, ee, Y) {
|
|
3032
3032
|
if (typeof k != "function")
|
|
3033
|
-
return new b("Property `" + Y + "` of component `" +
|
|
3034
|
-
var
|
|
3035
|
-
if (
|
|
3036
|
-
return new b("Invalid " +
|
|
3037
|
-
for (var re in
|
|
3038
|
-
if (r(
|
|
3039
|
-
var
|
|
3040
|
-
if (
|
|
3041
|
-
return
|
|
3033
|
+
return new b("Property `" + Y + "` of component `" + H + "` has invalid PropType notation inside objectOf.");
|
|
3034
|
+
var V = Z[B], X = U(V);
|
|
3035
|
+
if (X !== "object")
|
|
3036
|
+
return new b("Invalid " + ee + " `" + Y + "` of type " + ("`" + X + "` supplied to `" + H + "`, expected an object."));
|
|
3037
|
+
for (var re in V)
|
|
3038
|
+
if (r(V, re)) {
|
|
3039
|
+
var R = k(V, re, H, ee, Y + "." + re, n);
|
|
3040
|
+
if (R instanceof Error)
|
|
3041
|
+
return R;
|
|
3042
3042
|
}
|
|
3043
3043
|
return null;
|
|
3044
3044
|
}
|
|
@@ -3051,42 +3051,42 @@ function js() {
|
|
|
3051
3051
|
var Z = k[N];
|
|
3052
3052
|
if (typeof Z != "function")
|
|
3053
3053
|
return s(
|
|
3054
|
-
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " +
|
|
3054
|
+
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + W(Z) + " at index " + N + "."
|
|
3055
3055
|
), o;
|
|
3056
3056
|
}
|
|
3057
|
-
function
|
|
3058
|
-
for (var re = [],
|
|
3059
|
-
var oe = k[
|
|
3060
|
-
if (
|
|
3057
|
+
function B(H, ee, Y, V, X) {
|
|
3058
|
+
for (var re = [], R = 0; R < k.length; R++) {
|
|
3059
|
+
var oe = k[R], D = oe(H, ee, Y, V, X, n);
|
|
3060
|
+
if (D == null)
|
|
3061
3061
|
return null;
|
|
3062
|
-
|
|
3062
|
+
D.data && r(D.data, "expectedType") && re.push(D.data.expectedType);
|
|
3063
3063
|
}
|
|
3064
3064
|
var ve = re.length > 0 ? ", expected one of type [" + re.join(", ") + "]" : "";
|
|
3065
|
-
return new b("Invalid " +
|
|
3065
|
+
return new b("Invalid " + V + " `" + X + "` supplied to " + ("`" + Y + "`" + ve + "."));
|
|
3066
3066
|
}
|
|
3067
|
-
return _(
|
|
3067
|
+
return _(B);
|
|
3068
3068
|
}
|
|
3069
3069
|
function O() {
|
|
3070
|
-
function k(N, Z,
|
|
3071
|
-
return
|
|
3070
|
+
function k(N, Z, B, H, ee) {
|
|
3071
|
+
return $(N[Z]) ? null : new b("Invalid " + H + " `" + ee + "` supplied to " + ("`" + B + "`, expected a ReactNode."));
|
|
3072
3072
|
}
|
|
3073
3073
|
return _(k);
|
|
3074
3074
|
}
|
|
3075
|
-
function
|
|
3075
|
+
function C(k, N, Z, B, H) {
|
|
3076
3076
|
return new b(
|
|
3077
|
-
(k || "React class") + ": " + N + " type `" + Z + "." +
|
|
3077
|
+
(k || "React class") + ": " + N + " type `" + Z + "." + B + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + H + "`."
|
|
3078
3078
|
);
|
|
3079
3079
|
}
|
|
3080
3080
|
function T(k) {
|
|
3081
|
-
function N(Z,
|
|
3082
|
-
var
|
|
3083
|
-
if (
|
|
3084
|
-
return new b("Invalid " +
|
|
3081
|
+
function N(Z, B, H, ee, Y) {
|
|
3082
|
+
var V = Z[B], X = U(V);
|
|
3083
|
+
if (X !== "object")
|
|
3084
|
+
return new b("Invalid " + ee + " `" + Y + "` of type `" + X + "` " + ("supplied to `" + H + "`, expected `object`."));
|
|
3085
3085
|
for (var re in k) {
|
|
3086
|
-
var
|
|
3087
|
-
if (typeof
|
|
3088
|
-
return
|
|
3089
|
-
var oe =
|
|
3086
|
+
var R = k[re];
|
|
3087
|
+
if (typeof R != "function")
|
|
3088
|
+
return C(H, ee, Y, re, A(R));
|
|
3089
|
+
var oe = R(V, re, H, ee, Y + "." + re, n);
|
|
3090
3090
|
if (oe)
|
|
3091
3091
|
return oe;
|
|
3092
3092
|
}
|
|
@@ -3095,29 +3095,29 @@ function js() {
|
|
|
3095
3095
|
return _(N);
|
|
3096
3096
|
}
|
|
3097
3097
|
function x(k) {
|
|
3098
|
-
function N(Z,
|
|
3099
|
-
var
|
|
3100
|
-
if (
|
|
3101
|
-
return new b("Invalid " +
|
|
3102
|
-
var re = e({}, Z[
|
|
3103
|
-
for (var
|
|
3104
|
-
var oe = k[
|
|
3105
|
-
if (r(k,
|
|
3106
|
-
return
|
|
3098
|
+
function N(Z, B, H, ee, Y) {
|
|
3099
|
+
var V = Z[B], X = U(V);
|
|
3100
|
+
if (X !== "object")
|
|
3101
|
+
return new b("Invalid " + ee + " `" + Y + "` of type `" + X + "` " + ("supplied to `" + H + "`, expected `object`."));
|
|
3102
|
+
var re = e({}, Z[B], k);
|
|
3103
|
+
for (var R in re) {
|
|
3104
|
+
var oe = k[R];
|
|
3105
|
+
if (r(k, R) && typeof oe != "function")
|
|
3106
|
+
return C(H, ee, Y, R, A(oe));
|
|
3107
3107
|
if (!oe)
|
|
3108
3108
|
return new b(
|
|
3109
|
-
"Invalid " +
|
|
3109
|
+
"Invalid " + ee + " `" + Y + "` key `" + R + "` supplied to `" + H + "`.\nBad object: " + JSON.stringify(Z[B], null, " ") + `
|
|
3110
3110
|
Valid keys: ` + JSON.stringify(Object.keys(k), null, " ")
|
|
3111
3111
|
);
|
|
3112
|
-
var
|
|
3113
|
-
if (
|
|
3114
|
-
return
|
|
3112
|
+
var D = oe(V, R, H, ee, Y + "." + R, n);
|
|
3113
|
+
if (D)
|
|
3114
|
+
return D;
|
|
3115
3115
|
}
|
|
3116
3116
|
return null;
|
|
3117
3117
|
}
|
|
3118
3118
|
return _(N);
|
|
3119
3119
|
}
|
|
3120
|
-
function
|
|
3120
|
+
function $(k) {
|
|
3121
3121
|
switch (typeof k) {
|
|
3122
3122
|
case "number":
|
|
3123
3123
|
case "string":
|
|
@@ -3127,20 +3127,20 @@ Valid keys: ` + JSON.stringify(Object.keys(k), null, " ")
|
|
|
3127
3127
|
return !k;
|
|
3128
3128
|
case "object":
|
|
3129
3129
|
if (Array.isArray(k))
|
|
3130
|
-
return k.every(
|
|
3130
|
+
return k.every($);
|
|
3131
3131
|
if (k === null || c(k))
|
|
3132
3132
|
return !0;
|
|
3133
3133
|
var N = d(k);
|
|
3134
3134
|
if (N) {
|
|
3135
|
-
var Z = N.call(k),
|
|
3135
|
+
var Z = N.call(k), B;
|
|
3136
3136
|
if (N !== k.entries) {
|
|
3137
|
-
for (; !(
|
|
3138
|
-
if (
|
|
3137
|
+
for (; !(B = Z.next()).done; )
|
|
3138
|
+
if (!$(B.value))
|
|
3139
3139
|
return !1;
|
|
3140
3140
|
} else
|
|
3141
|
-
for (; !(
|
|
3142
|
-
var
|
|
3143
|
-
if (
|
|
3141
|
+
for (; !(B = Z.next()).done; ) {
|
|
3142
|
+
var H = B.value;
|
|
3143
|
+
if (H && !$(H[1]))
|
|
3144
3144
|
return !1;
|
|
3145
3145
|
}
|
|
3146
3146
|
} else
|
|
@@ -3150,17 +3150,17 @@ Valid keys: ` + JSON.stringify(Object.keys(k), null, " ")
|
|
|
3150
3150
|
return !1;
|
|
3151
3151
|
}
|
|
3152
3152
|
}
|
|
3153
|
-
function
|
|
3153
|
+
function I(k, N) {
|
|
3154
3154
|
return k === "symbol" ? !0 : N ? N["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && N instanceof Symbol : !1;
|
|
3155
3155
|
}
|
|
3156
|
-
function
|
|
3156
|
+
function U(k) {
|
|
3157
3157
|
var N = typeof k;
|
|
3158
|
-
return Array.isArray(k) ? "array" : k instanceof RegExp ? "object" :
|
|
3158
|
+
return Array.isArray(k) ? "array" : k instanceof RegExp ? "object" : I(N, k) ? "symbol" : N;
|
|
3159
3159
|
}
|
|
3160
|
-
function
|
|
3160
|
+
function A(k) {
|
|
3161
3161
|
if (typeof k > "u" || k === null)
|
|
3162
3162
|
return "" + k;
|
|
3163
|
-
var N =
|
|
3163
|
+
var N = U(k);
|
|
3164
3164
|
if (N === "object") {
|
|
3165
3165
|
if (k instanceof Date)
|
|
3166
3166
|
return "date";
|
|
@@ -3169,8 +3169,8 @@ Valid keys: ` + JSON.stringify(Object.keys(k), null, " ")
|
|
|
3169
3169
|
}
|
|
3170
3170
|
return N;
|
|
3171
3171
|
}
|
|
3172
|
-
function
|
|
3173
|
-
var N =
|
|
3172
|
+
function W(k) {
|
|
3173
|
+
var N = A(k);
|
|
3174
3174
|
switch (N) {
|
|
3175
3175
|
case "array":
|
|
3176
3176
|
case "object":
|
|
@@ -3183,7 +3183,7 @@ Valid keys: ` + JSON.stringify(Object.keys(k), null, " ")
|
|
|
3183
3183
|
return N;
|
|
3184
3184
|
}
|
|
3185
3185
|
}
|
|
3186
|
-
function
|
|
3186
|
+
function J(k) {
|
|
3187
3187
|
return !k.constructor || !k.constructor.name ? m : k.constructor.name;
|
|
3188
3188
|
}
|
|
3189
3189
|
return p.checkPropTypes = i, p.resetWarningCache = i.resetWarningCache, p.PropTypes = p, p;
|
|
@@ -3248,13 +3248,13 @@ var Cs = Ln.exports;
|
|
|
3248
3248
|
* tabbable 6.2.0
|
|
3249
3249
|
* @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE
|
|
3250
3250
|
*/
|
|
3251
|
-
var ba = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])", "a[href]:not([inert])", "button:not([inert])", "[tabindex]:not(slot):not([inert])", "audio[controls]:not([inert])", "video[controls]:not([inert])", '[contenteditable]:not([contenteditable="false"]):not([inert])', "details>summary:first-of-type:not([inert])", "details:not([inert])"],
|
|
3252
|
-
} : Element.prototype.matches || Element.prototype.msMatchesSelector || Element.prototype.webkitMatchesSelector,
|
|
3251
|
+
var ba = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])", "a[href]:not([inert])", "button:not([inert])", "[tabindex]:not(slot):not([inert])", "audio[controls]:not([inert])", "video[controls]:not([inert])", '[contenteditable]:not([contenteditable="false"]):not([inert])', "details>summary:first-of-type:not([inert])", "details:not([inert])"], qt = /* @__PURE__ */ ba.join(","), ya = typeof Element > "u", Ue = ya ? function() {
|
|
3252
|
+
} : Element.prototype.matches || Element.prototype.msMatchesSelector || Element.prototype.webkitMatchesSelector, Ut = !ya && Element.prototype.getRootNode ? function(t) {
|
|
3253
3253
|
var e;
|
|
3254
3254
|
return t == null || (e = t.getRootNode) === null || e === void 0 ? void 0 : e.call(t);
|
|
3255
3255
|
} : function(t) {
|
|
3256
3256
|
return t == null ? void 0 : t.ownerDocument;
|
|
3257
|
-
},
|
|
3257
|
+
}, zt = function t(e, n) {
|
|
3258
3258
|
var r;
|
|
3259
3259
|
n === void 0 && (n = !0);
|
|
3260
3260
|
var i = e == null || (r = e.getAttribute) === null || r === void 0 ? void 0 : r.call(e, "inert"), s = i === "" || i === "true", o = s || n && e && t(e.parentNode);
|
|
@@ -3263,14 +3263,14 @@ var ba = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
3263
3263
|
var n, r = e == null || (n = e.getAttribute) === null || n === void 0 ? void 0 : n.call(e, "contenteditable");
|
|
3264
3264
|
return r === "" || r === "true";
|
|
3265
3265
|
}, _a = function(e, n, r) {
|
|
3266
|
-
if (
|
|
3266
|
+
if (zt(e))
|
|
3267
3267
|
return [];
|
|
3268
|
-
var i = Array.prototype.slice.apply(e.querySelectorAll(
|
|
3269
|
-
return n && Ue.call(e,
|
|
3268
|
+
var i = Array.prototype.slice.apply(e.querySelectorAll(qt));
|
|
3269
|
+
return n && Ue.call(e, qt) && i.unshift(e), i = i.filter(r), i;
|
|
3270
3270
|
}, xa = function t(e, n, r) {
|
|
3271
3271
|
for (var i = [], s = Array.from(e); s.length; ) {
|
|
3272
3272
|
var o = s.shift();
|
|
3273
|
-
if (!
|
|
3273
|
+
if (!zt(o, !1))
|
|
3274
3274
|
if (o.tagName === "SLOT") {
|
|
3275
3275
|
var c = o.assignedElements(), f = c.length ? c : o.children, l = t(f, !0, r);
|
|
3276
3276
|
r.flatten ? i.push.apply(i, l) : i.push({
|
|
@@ -3278,10 +3278,10 @@ var ba = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
3278
3278
|
candidates: l
|
|
3279
3279
|
});
|
|
3280
3280
|
} else {
|
|
3281
|
-
var u = Ue.call(o,
|
|
3281
|
+
var u = Ue.call(o, qt);
|
|
3282
3282
|
u && r.filter(o) && (n || !e.includes(o)) && i.push(o);
|
|
3283
3283
|
var d = o.shadowRoot || // check for an undisclosed shadow
|
|
3284
|
-
typeof r.getShadowRoot == "function" && r.getShadowRoot(o), m = !
|
|
3284
|
+
typeof r.getShadowRoot == "function" && r.getShadowRoot(o), m = !zt(d, !1) && (!r.shadowRootFilter || r.shadowRootFilter(o));
|
|
3285
3285
|
if (d && m) {
|
|
3286
3286
|
var p = t(d === !0 ? o.children : d.children, !0, r);
|
|
3287
3287
|
r.flatten ? i.push.apply(i, p) : i.push({
|
|
@@ -3320,7 +3320,7 @@ var ba = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
3320
3320
|
}, Os = function(e) {
|
|
3321
3321
|
if (!e.name)
|
|
3322
3322
|
return !0;
|
|
3323
|
-
var n = e.form ||
|
|
3323
|
+
var n = e.form || Ut(e), r = function(c) {
|
|
3324
3324
|
return n.querySelectorAll('input[type="radio"][name="' + c + '"]');
|
|
3325
3325
|
}, i;
|
|
3326
3326
|
if (typeof window < "u" && typeof window.CSS < "u" && typeof window.CSS.escape == "function")
|
|
@@ -3338,12 +3338,12 @@ var ba = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
3338
3338
|
}, As = function(e) {
|
|
3339
3339
|
return Ds(e) && !Os(e);
|
|
3340
3340
|
}, Is = function(e) {
|
|
3341
|
-
var n, r = e &&
|
|
3341
|
+
var n, r = e && Ut(e), i = (n = r) === null || n === void 0 ? void 0 : n.host, s = !1;
|
|
3342
3342
|
if (r && r !== e) {
|
|
3343
3343
|
var o, c, f;
|
|
3344
3344
|
for (s = !!((o = i) !== null && o !== void 0 && (c = o.ownerDocument) !== null && c !== void 0 && c.contains(i) || e != null && (f = e.ownerDocument) !== null && f !== void 0 && f.contains(e)); !s && i; ) {
|
|
3345
3345
|
var l, u, d;
|
|
3346
|
-
r =
|
|
3346
|
+
r = Ut(i), i = (l = r) === null || l === void 0 ? void 0 : l.host, s = !!((u = i) !== null && u !== void 0 && (d = u.ownerDocument) !== null && d !== void 0 && d.contains(i));
|
|
3347
3347
|
}
|
|
3348
3348
|
}
|
|
3349
3349
|
return s;
|
|
@@ -3360,7 +3360,7 @@ var ba = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
3360
3360
|
if (!r || r === "full" || r === "legacy-full") {
|
|
3361
3361
|
if (typeof i == "function") {
|
|
3362
3362
|
for (var c = e; e; ) {
|
|
3363
|
-
var f = e.parentElement, l =
|
|
3363
|
+
var f = e.parentElement, l = Ut(e);
|
|
3364
3364
|
if (f && !f.shadowRoot && i(f) === !0)
|
|
3365
3365
|
return Nr(e);
|
|
3366
3366
|
e.assignedSlot ? e = e.assignedSlot : !f && l !== e.ownerDocument ? e = l.host : e = f;
|
|
@@ -3388,14 +3388,14 @@ var ba = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
3388
3388
|
n = n.parentElement;
|
|
3389
3389
|
}
|
|
3390
3390
|
return !1;
|
|
3391
|
-
},
|
|
3391
|
+
}, Zt = function(e, n) {
|
|
3392
3392
|
return !(n.disabled || // we must do an inert look up to filter out any elements inside an inert ancestor
|
|
3393
3393
|
// because we're limited in the type of selectors we can use in JSDom (see related
|
|
3394
3394
|
// note related to `candidateSelectors`)
|
|
3395
|
-
|
|
3395
|
+
zt(n) || Ms(n) || Ls(n, e) || // For a details element with a summary, the summary element gets the focus
|
|
3396
3396
|
Rs(n) || Bs(n));
|
|
3397
3397
|
}, Bn = function(e, n) {
|
|
3398
|
-
return !(As(n) || De(n) < 0 || !
|
|
3398
|
+
return !(As(n) || De(n) < 0 || !Zt(e, n));
|
|
3399
3399
|
}, qs = function(e) {
|
|
3400
3400
|
var n = parseInt(e.getAttribute("tabindex"), 10);
|
|
3401
3401
|
return !!(isNaN(n) || n >= 0);
|
|
@@ -3426,24 +3426,24 @@ var ba = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
3426
3426
|
n = n || {};
|
|
3427
3427
|
var r;
|
|
3428
3428
|
return n.getShadowRoot ? r = xa([e], n.includeContainer, {
|
|
3429
|
-
filter:
|
|
3429
|
+
filter: Zt.bind(null, n),
|
|
3430
3430
|
flatten: !0,
|
|
3431
3431
|
getShadowRoot: n.getShadowRoot
|
|
3432
|
-
}) : r = _a(e, n.includeContainer,
|
|
3432
|
+
}) : r = _a(e, n.includeContainer, Zt.bind(null, n)), r;
|
|
3433
3433
|
}, Be = function(e, n) {
|
|
3434
3434
|
if (n = n || {}, !e)
|
|
3435
3435
|
throw new Error("No node provided");
|
|
3436
|
-
return Ue.call(e,
|
|
3437
|
-
}, zs = /* @__PURE__ */ ba.concat("iframe").join(","),
|
|
3436
|
+
return Ue.call(e, qt) === !1 ? !1 : Bn(n, e);
|
|
3437
|
+
}, zs = /* @__PURE__ */ ba.concat("iframe").join(","), Dt = function(e, n) {
|
|
3438
3438
|
if (n = n || {}, !e)
|
|
3439
3439
|
throw new Error("No node provided");
|
|
3440
|
-
return Ue.call(e, zs) === !1 ? !1 :
|
|
3440
|
+
return Ue.call(e, zs) === !1 ? !1 : Zt(n, e);
|
|
3441
3441
|
};
|
|
3442
3442
|
const Zs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
3443
3443
|
__proto__: null,
|
|
3444
3444
|
focusable: Ta,
|
|
3445
3445
|
getTabIndex: De,
|
|
3446
|
-
isFocusable:
|
|
3446
|
+
isFocusable: Dt,
|
|
3447
3447
|
isTabbable: Be,
|
|
3448
3448
|
tabbable: ja
|
|
3449
3449
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
@@ -3530,7 +3530,7 @@ var Rr = {
|
|
|
3530
3530
|
for (var n = arguments.length, r = new Array(n > 1 ? n - 1 : 0), i = 1; i < n; i++)
|
|
3531
3531
|
r[i - 1] = arguments[i];
|
|
3532
3532
|
return typeof e == "function" ? e.apply(void 0, r) : e;
|
|
3533
|
-
},
|
|
3533
|
+
}, Tt = function(e) {
|
|
3534
3534
|
return e.target.shadowRoot && typeof e.composedPath == "function" ? e.composedPath()[0] : e.target;
|
|
3535
3535
|
}, Js = [], Xs = function(e, n) {
|
|
3536
3536
|
var r = (n == null ? void 0 : n.document) || document, i = (n == null ? void 0 : n.trapStack) || Js, s = Mr({
|
|
@@ -3575,69 +3575,69 @@ var Rr = {
|
|
|
3575
3575
|
delayInitialFocusTimer: void 0,
|
|
3576
3576
|
// the most recent KeyboardEvent for the configured nav key (typically [SHIFT+]TAB), if any
|
|
3577
3577
|
recentNavEvent: void 0
|
|
3578
|
-
}, c, f = function(T, x,
|
|
3579
|
-
return T && T[x] !== void 0 ? T[x] : s[
|
|
3578
|
+
}, c, f = function(T, x, $) {
|
|
3579
|
+
return T && T[x] !== void 0 ? T[x] : s[$ || x];
|
|
3580
3580
|
}, l = function(T, x) {
|
|
3581
|
-
var
|
|
3582
|
-
return o.containerGroups.findIndex(function(
|
|
3583
|
-
var
|
|
3584
|
-
return
|
|
3581
|
+
var $ = typeof (x == null ? void 0 : x.composedPath) == "function" ? x.composedPath() : void 0;
|
|
3582
|
+
return o.containerGroups.findIndex(function(I) {
|
|
3583
|
+
var U = I.container, A = I.tabbableNodes;
|
|
3584
|
+
return U.contains(T) || // fall back to explicit tabbable search which will take into consideration any
|
|
3585
3585
|
// web components if the `tabbableOptions.getShadowRoot` option was used for
|
|
3586
3586
|
// the trap, enabling shadow DOM support in tabbable (`Node.contains()` doesn't
|
|
3587
3587
|
// look inside web components even if open)
|
|
3588
|
-
(
|
|
3589
|
-
return
|
|
3588
|
+
($ == null ? void 0 : $.includes(U)) || A.find(function(W) {
|
|
3589
|
+
return W === T;
|
|
3590
3590
|
});
|
|
3591
3591
|
});
|
|
3592
3592
|
}, u = function(T) {
|
|
3593
3593
|
var x = s[T];
|
|
3594
3594
|
if (typeof x == "function") {
|
|
3595
|
-
for (var
|
|
3596
|
-
|
|
3597
|
-
x = x.apply(void 0,
|
|
3595
|
+
for (var $ = arguments.length, I = new Array($ > 1 ? $ - 1 : 0), U = 1; U < $; U++)
|
|
3596
|
+
I[U - 1] = arguments[U];
|
|
3597
|
+
x = x.apply(void 0, I);
|
|
3598
3598
|
}
|
|
3599
3599
|
if (x === !0 && (x = void 0), !x) {
|
|
3600
3600
|
if (x === void 0 || x === !1)
|
|
3601
3601
|
return x;
|
|
3602
3602
|
throw new Error("`".concat(T, "` was specified but was not a node, or did not return a node"));
|
|
3603
3603
|
}
|
|
3604
|
-
var
|
|
3605
|
-
if (typeof x == "string" && (
|
|
3604
|
+
var A = x;
|
|
3605
|
+
if (typeof x == "string" && (A = r.querySelector(x), !A))
|
|
3606
3606
|
throw new Error("`".concat(T, "` as selector refers to no known node"));
|
|
3607
|
-
return
|
|
3607
|
+
return A;
|
|
3608
3608
|
}, d = function() {
|
|
3609
3609
|
var T = u("initialFocus");
|
|
3610
3610
|
if (T === !1)
|
|
3611
3611
|
return !1;
|
|
3612
|
-
if (T === void 0 || !
|
|
3612
|
+
if (T === void 0 || !Dt(T, s.tabbableOptions))
|
|
3613
3613
|
if (l(r.activeElement) >= 0)
|
|
3614
3614
|
T = r.activeElement;
|
|
3615
3615
|
else {
|
|
3616
|
-
var x = o.tabbableGroups[0],
|
|
3617
|
-
T =
|
|
3616
|
+
var x = o.tabbableGroups[0], $ = x && x.firstTabbableNode;
|
|
3617
|
+
T = $ || u("fallbackFocus");
|
|
3618
3618
|
}
|
|
3619
3619
|
if (!T)
|
|
3620
3620
|
throw new Error("Your focus-trap needs to have at least one focusable element");
|
|
3621
3621
|
return T;
|
|
3622
3622
|
}, m = function() {
|
|
3623
3623
|
if (o.containerGroups = o.containers.map(function(T) {
|
|
3624
|
-
var x = ja(T, s.tabbableOptions),
|
|
3624
|
+
var x = ja(T, s.tabbableOptions), $ = Ta(T, s.tabbableOptions), I = x.length > 0 ? x[0] : void 0, U = x.length > 0 ? x[x.length - 1] : void 0, A = $.find(function(k) {
|
|
3625
3625
|
return Be(k);
|
|
3626
|
-
}),
|
|
3626
|
+
}), W = $.slice().reverse().find(function(k) {
|
|
3627
3627
|
return Be(k);
|
|
3628
|
-
}),
|
|
3628
|
+
}), J = !!x.find(function(k) {
|
|
3629
3629
|
return De(k) > 0;
|
|
3630
3630
|
});
|
|
3631
3631
|
return {
|
|
3632
3632
|
container: T,
|
|
3633
3633
|
tabbableNodes: x,
|
|
3634
|
-
focusableNodes:
|
|
3634
|
+
focusableNodes: $,
|
|
3635
3635
|
/** True if at least one node with positive `tabindex` was found in this container. */
|
|
3636
|
-
posTabIndexesFound:
|
|
3636
|
+
posTabIndexesFound: J,
|
|
3637
3637
|
/** First tabbable node in container, __tabindex__ order; `undefined` if none. */
|
|
3638
|
-
firstTabbableNode:
|
|
3638
|
+
firstTabbableNode: I,
|
|
3639
3639
|
/** Last tabbable node in container, __tabindex__ order; `undefined` if none. */
|
|
3640
|
-
lastTabbableNode:
|
|
3640
|
+
lastTabbableNode: U,
|
|
3641
3641
|
// NOTE: DOM order is NOT NECESSARILY "document position" order, but figuring that out
|
|
3642
3642
|
// would require more than just https://developer.mozilla.org/en-US/docs/Web/API/Node/compareDocumentPosition
|
|
3643
3643
|
// because that API doesn't work with Shadow DOM as well as it should (@see
|
|
@@ -3646,9 +3646,9 @@ var Rr = {
|
|
|
3646
3646
|
// "close enough most of the time" alternative for positive tabindexes which should generally
|
|
3647
3647
|
// be avoided anyway...
|
|
3648
3648
|
/** First tabbable node in container, __DOM__ order; `undefined` if none. */
|
|
3649
|
-
firstDomTabbableNode:
|
|
3649
|
+
firstDomTabbableNode: A,
|
|
3650
3650
|
/** Last tabbable node in container, __DOM__ order; `undefined` if none. */
|
|
3651
|
-
lastDomTabbableNode:
|
|
3651
|
+
lastDomTabbableNode: W,
|
|
3652
3652
|
/**
|
|
3653
3653
|
* Finds the __tabbable__ node that follows the given node in the specified direction,
|
|
3654
3654
|
* in this container, if any.
|
|
@@ -3658,12 +3658,12 @@ var Rr = {
|
|
|
3658
3658
|
* @returns {HTMLElement|undefined} The next tabbable node, if any.
|
|
3659
3659
|
*/
|
|
3660
3660
|
nextTabbableNode: function(N) {
|
|
3661
|
-
var Z = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0,
|
|
3662
|
-
return
|
|
3663
|
-
return Be(
|
|
3664
|
-
}) :
|
|
3665
|
-
return Be(
|
|
3666
|
-
}) : x[
|
|
3661
|
+
var Z = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0, B = x.indexOf(N);
|
|
3662
|
+
return B < 0 ? Z ? $.slice($.indexOf(N) + 1).find(function(H) {
|
|
3663
|
+
return Be(H);
|
|
3664
|
+
}) : $.slice(0, $.indexOf(N)).reverse().find(function(H) {
|
|
3665
|
+
return Be(H);
|
|
3666
|
+
}) : x[B + (Z ? 1 : -1)];
|
|
3667
3667
|
}
|
|
3668
3668
|
};
|
|
3669
3669
|
}), o.tabbableGroups = o.containerGroups.filter(function(T) {
|
|
@@ -3674,14 +3674,14 @@ var Rr = {
|
|
|
3674
3674
|
return T.posTabIndexesFound;
|
|
3675
3675
|
}) && o.containerGroups.length > 1)
|
|
3676
3676
|
throw new Error("At least one node with a positive tabindex was found in one of your focus-trap's multiple containers. Positive tabindexes are only supported in single-container focus-traps.");
|
|
3677
|
-
}, p = function
|
|
3677
|
+
}, p = function C(T) {
|
|
3678
3678
|
var x = T.activeElement;
|
|
3679
3679
|
if (x)
|
|
3680
|
-
return x.shadowRoot && x.shadowRoot.activeElement !== null ?
|
|
3681
|
-
}, v = function
|
|
3680
|
+
return x.shadowRoot && x.shadowRoot.activeElement !== null ? C(x.shadowRoot) : x;
|
|
3681
|
+
}, v = function C(T) {
|
|
3682
3682
|
if (T !== !1 && T !== p(document)) {
|
|
3683
3683
|
if (!T || !T.focus) {
|
|
3684
|
-
|
|
3684
|
+
C(d());
|
|
3685
3685
|
return;
|
|
3686
3686
|
}
|
|
3687
3687
|
T.focus({
|
|
@@ -3692,39 +3692,39 @@ var Rr = {
|
|
|
3692
3692
|
var x = u("setReturnFocus", T);
|
|
3693
3693
|
return x || (x === !1 ? !1 : T);
|
|
3694
3694
|
}, _ = function(T) {
|
|
3695
|
-
var x = T.target,
|
|
3696
|
-
x = x ||
|
|
3697
|
-
var
|
|
3695
|
+
var x = T.target, $ = T.event, I = T.isBackward, U = I === void 0 ? !1 : I;
|
|
3696
|
+
x = x || Tt($), m();
|
|
3697
|
+
var A = null;
|
|
3698
3698
|
if (o.tabbableGroups.length > 0) {
|
|
3699
|
-
var
|
|
3700
|
-
if (
|
|
3701
|
-
|
|
3702
|
-
else if (
|
|
3699
|
+
var W = l(x, $), J = W >= 0 ? o.containerGroups[W] : void 0;
|
|
3700
|
+
if (W < 0)
|
|
3701
|
+
U ? A = o.tabbableGroups[o.tabbableGroups.length - 1].lastTabbableNode : A = o.tabbableGroups[0].firstTabbableNode;
|
|
3702
|
+
else if (U) {
|
|
3703
3703
|
var k = Or(o.tabbableGroups, function(Y) {
|
|
3704
|
-
var
|
|
3705
|
-
return x ===
|
|
3704
|
+
var V = Y.firstTabbableNode;
|
|
3705
|
+
return x === V;
|
|
3706
3706
|
});
|
|
3707
|
-
if (k < 0 && (
|
|
3707
|
+
if (k < 0 && (J.container === x || Dt(x, s.tabbableOptions) && !Be(x, s.tabbableOptions) && !J.nextTabbableNode(x, !1)) && (k = W), k >= 0) {
|
|
3708
3708
|
var N = k === 0 ? o.tabbableGroups.length - 1 : k - 1, Z = o.tabbableGroups[N];
|
|
3709
|
-
|
|
3709
|
+
A = De(x) >= 0 ? Z.lastTabbableNode : Z.lastDomTabbableNode;
|
|
3710
3710
|
} else
|
|
3711
|
-
ft(
|
|
3711
|
+
ft($) || (A = J.nextTabbableNode(x, !1));
|
|
3712
3712
|
} else {
|
|
3713
|
-
var
|
|
3714
|
-
var
|
|
3715
|
-
return x ===
|
|
3713
|
+
var B = Or(o.tabbableGroups, function(Y) {
|
|
3714
|
+
var V = Y.lastTabbableNode;
|
|
3715
|
+
return x === V;
|
|
3716
3716
|
});
|
|
3717
|
-
if (
|
|
3718
|
-
var
|
|
3719
|
-
|
|
3717
|
+
if (B < 0 && (J.container === x || Dt(x, s.tabbableOptions) && !Be(x, s.tabbableOptions) && !J.nextTabbableNode(x)) && (B = W), B >= 0) {
|
|
3718
|
+
var H = B === o.tabbableGroups.length - 1 ? 0 : B + 1, ee = o.tabbableGroups[H];
|
|
3719
|
+
A = De(x) >= 0 ? ee.firstTabbableNode : ee.firstDomTabbableNode;
|
|
3720
3720
|
} else
|
|
3721
|
-
ft(
|
|
3721
|
+
ft($) || (A = J.nextTabbableNode(x));
|
|
3722
3722
|
}
|
|
3723
3723
|
} else
|
|
3724
|
-
|
|
3725
|
-
return
|
|
3724
|
+
A = u("fallbackFocus");
|
|
3725
|
+
return A;
|
|
3726
3726
|
}, g = function(T) {
|
|
3727
|
-
var x =
|
|
3727
|
+
var x = Tt(T);
|
|
3728
3728
|
if (!(l(x, T) >= 0)) {
|
|
3729
3729
|
if (st(s.clickOutsideDeactivates, T)) {
|
|
3730
3730
|
c.deactivate({
|
|
@@ -3741,45 +3741,45 @@ var Rr = {
|
|
|
3741
3741
|
st(s.allowOutsideClick, T) || T.preventDefault();
|
|
3742
3742
|
}
|
|
3743
3743
|
}, y = function(T) {
|
|
3744
|
-
var x =
|
|
3745
|
-
if (
|
|
3746
|
-
|
|
3744
|
+
var x = Tt(T), $ = l(x, T) >= 0;
|
|
3745
|
+
if ($ || x instanceof Document)
|
|
3746
|
+
$ && (o.mostRecentlyFocusedNode = x);
|
|
3747
3747
|
else {
|
|
3748
3748
|
T.stopImmediatePropagation();
|
|
3749
|
-
var
|
|
3749
|
+
var I, U = !0;
|
|
3750
3750
|
if (o.mostRecentlyFocusedNode)
|
|
3751
3751
|
if (De(o.mostRecentlyFocusedNode) > 0) {
|
|
3752
|
-
var
|
|
3753
|
-
if (
|
|
3754
|
-
var
|
|
3752
|
+
var A = l(o.mostRecentlyFocusedNode), W = o.containerGroups[A].tabbableNodes;
|
|
3753
|
+
if (W.length > 0) {
|
|
3754
|
+
var J = W.findIndex(function(k) {
|
|
3755
3755
|
return k === o.mostRecentlyFocusedNode;
|
|
3756
3756
|
});
|
|
3757
|
-
|
|
3757
|
+
J >= 0 && (s.isKeyForward(o.recentNavEvent) ? J + 1 < W.length && (I = W[J + 1], U = !1) : J - 1 >= 0 && (I = W[J - 1], U = !1));
|
|
3758
3758
|
}
|
|
3759
3759
|
} else
|
|
3760
3760
|
o.containerGroups.some(function(k) {
|
|
3761
3761
|
return k.tabbableNodes.some(function(N) {
|
|
3762
3762
|
return De(N) > 0;
|
|
3763
3763
|
});
|
|
3764
|
-
}) || (
|
|
3764
|
+
}) || (U = !1);
|
|
3765
3765
|
else
|
|
3766
|
-
|
|
3767
|
-
|
|
3766
|
+
U = !1;
|
|
3767
|
+
U && (I = _({
|
|
3768
3768
|
// move FROM the MRU node, not event-related node (which will be the node that is
|
|
3769
3769
|
// outside the trap causing the focus escape we're trying to fix)
|
|
3770
3770
|
target: o.mostRecentlyFocusedNode,
|
|
3771
3771
|
isBackward: s.isKeyBackward(o.recentNavEvent)
|
|
3772
|
-
})), v(
|
|
3772
|
+
})), v(I || o.mostRecentlyFocusedNode || d());
|
|
3773
3773
|
}
|
|
3774
3774
|
o.recentNavEvent = void 0;
|
|
3775
3775
|
}, E = function(T) {
|
|
3776
3776
|
var x = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1;
|
|
3777
3777
|
o.recentNavEvent = T;
|
|
3778
|
-
var
|
|
3778
|
+
var $ = _({
|
|
3779
3779
|
event: T,
|
|
3780
3780
|
isBackward: x
|
|
3781
3781
|
});
|
|
3782
|
-
|
|
3782
|
+
$ && (ft(T) && T.preventDefault(), v($));
|
|
3783
3783
|
}, j = function(T) {
|
|
3784
3784
|
if (Ks(T) && st(s.escapeDeactivates, T) !== !1) {
|
|
3785
3785
|
T.preventDefault(), c.deactivate();
|
|
@@ -3787,9 +3787,9 @@ var Rr = {
|
|
|
3787
3787
|
}
|
|
3788
3788
|
(s.isKeyForward(T) || s.isKeyBackward(T)) && E(T, s.isKeyBackward(T));
|
|
3789
3789
|
}, w = function(T) {
|
|
3790
|
-
var x =
|
|
3790
|
+
var x = Tt(T);
|
|
3791
3791
|
l(x, T) >= 0 || st(s.clickOutsideDeactivates, T) || st(s.allowOutsideClick, T) || (T.preventDefault(), T.stopImmediatePropagation());
|
|
3792
|
-
},
|
|
3792
|
+
}, z = function() {
|
|
3793
3793
|
if (o.active)
|
|
3794
3794
|
return Rr.activateTrap(i, c), o.delayInitialFocusTimer = s.delayInitialFocus ? Fr(function() {
|
|
3795
3795
|
v(d());
|
|
@@ -3806,14 +3806,14 @@ var Rr = {
|
|
|
3806
3806
|
capture: !0,
|
|
3807
3807
|
passive: !1
|
|
3808
3808
|
}), c;
|
|
3809
|
-
},
|
|
3809
|
+
}, F = function() {
|
|
3810
3810
|
if (o.active)
|
|
3811
3811
|
return r.removeEventListener("focusin", y, !0), r.removeEventListener("mousedown", g, !0), r.removeEventListener("touchstart", g, !0), r.removeEventListener("click", w, !0), r.removeEventListener("keydown", j, !0), c;
|
|
3812
3812
|
}, q = function(T) {
|
|
3813
|
-
var x = T.some(function(
|
|
3814
|
-
var
|
|
3815
|
-
return
|
|
3816
|
-
return
|
|
3813
|
+
var x = T.some(function($) {
|
|
3814
|
+
var I = Array.from($.removedNodes);
|
|
3815
|
+
return I.some(function(U) {
|
|
3816
|
+
return U === o.mostRecentlyFocusedNode;
|
|
3817
3817
|
});
|
|
3818
3818
|
});
|
|
3819
3819
|
x && v(d());
|
|
@@ -3835,12 +3835,12 @@ var Rr = {
|
|
|
3835
3835
|
activate: function(T) {
|
|
3836
3836
|
if (o.active)
|
|
3837
3837
|
return this;
|
|
3838
|
-
var x = f(T, "onActivate"),
|
|
3839
|
-
|
|
3840
|
-
var
|
|
3841
|
-
|
|
3838
|
+
var x = f(T, "onActivate"), $ = f(T, "onPostActivate"), I = f(T, "checkCanFocusTrap");
|
|
3839
|
+
I || m(), o.active = !0, o.paused = !1, o.nodeFocusedBeforeActivation = r.activeElement, x == null || x();
|
|
3840
|
+
var U = function() {
|
|
3841
|
+
I && m(), z(), O(), $ == null || $();
|
|
3842
3842
|
};
|
|
3843
|
-
return
|
|
3843
|
+
return I ? (I(o.containers.concat()).then(U, U), this) : (U(), this);
|
|
3844
3844
|
},
|
|
3845
3845
|
deactivate: function(T) {
|
|
3846
3846
|
if (!o.active)
|
|
@@ -3850,32 +3850,32 @@ var Rr = {
|
|
|
3850
3850
|
onPostDeactivate: s.onPostDeactivate,
|
|
3851
3851
|
checkCanReturnFocus: s.checkCanReturnFocus
|
|
3852
3852
|
}, T);
|
|
3853
|
-
clearTimeout(o.delayInitialFocusTimer), o.delayInitialFocusTimer = void 0,
|
|
3854
|
-
var
|
|
3855
|
-
|
|
3856
|
-
var
|
|
3853
|
+
clearTimeout(o.delayInitialFocusTimer), o.delayInitialFocusTimer = void 0, F(), o.active = !1, o.paused = !1, O(), Rr.deactivateTrap(i, c);
|
|
3854
|
+
var $ = f(x, "onDeactivate"), I = f(x, "onPostDeactivate"), U = f(x, "checkCanReturnFocus"), A = f(x, "returnFocus", "returnFocusOnDeactivate");
|
|
3855
|
+
$ == null || $();
|
|
3856
|
+
var W = function() {
|
|
3857
3857
|
Fr(function() {
|
|
3858
|
-
|
|
3858
|
+
A && v(b(o.nodeFocusedBeforeActivation)), I == null || I();
|
|
3859
3859
|
});
|
|
3860
3860
|
};
|
|
3861
|
-
return
|
|
3861
|
+
return A && U ? (U(b(o.nodeFocusedBeforeActivation)).then(W, W), this) : (W(), this);
|
|
3862
3862
|
},
|
|
3863
3863
|
pause: function(T) {
|
|
3864
3864
|
if (o.paused || !o.active)
|
|
3865
3865
|
return this;
|
|
3866
|
-
var x = f(T, "onPause"),
|
|
3867
|
-
return o.paused = !0, x == null || x(),
|
|
3866
|
+
var x = f(T, "onPause"), $ = f(T, "onPostPause");
|
|
3867
|
+
return o.paused = !0, x == null || x(), F(), O(), $ == null || $(), this;
|
|
3868
3868
|
},
|
|
3869
3869
|
unpause: function(T) {
|
|
3870
3870
|
if (!o.paused || !o.active)
|
|
3871
3871
|
return this;
|
|
3872
|
-
var x = f(T, "onUnpause"),
|
|
3873
|
-
return o.paused = !1, x == null || x(), m(),
|
|
3872
|
+
var x = f(T, "onUnpause"), $ = f(T, "onPostUnpause");
|
|
3873
|
+
return o.paused = !1, x == null || x(), m(), z(), O(), $ == null || $(), this;
|
|
3874
3874
|
},
|
|
3875
3875
|
updateContainerElements: function(T) {
|
|
3876
3876
|
var x = [].concat(T).filter(Boolean);
|
|
3877
|
-
return o.containers = x.map(function(
|
|
3878
|
-
return typeof
|
|
3877
|
+
return o.containers = x.map(function($) {
|
|
3878
|
+
return typeof $ == "string" ? r.querySelector($) : $;
|
|
3879
3879
|
}), o.active && m(), O(), this;
|
|
3880
3880
|
}
|
|
3881
3881
|
}, c.updateContainerElements(e), c;
|
|
@@ -3918,9 +3918,9 @@ function qn(t, e) {
|
|
|
3918
3918
|
function so(t) {
|
|
3919
3919
|
var e = co();
|
|
3920
3920
|
return function() {
|
|
3921
|
-
var r =
|
|
3921
|
+
var r = Wt(t), i;
|
|
3922
3922
|
if (e) {
|
|
3923
|
-
var s =
|
|
3923
|
+
var s = Wt(this).constructor;
|
|
3924
3924
|
i = Reflect.construct(r, arguments, s);
|
|
3925
3925
|
} else
|
|
3926
3926
|
i = r.apply(this, arguments);
|
|
@@ -3951,10 +3951,10 @@ function co() {
|
|
|
3951
3951
|
return !1;
|
|
3952
3952
|
}
|
|
3953
3953
|
}
|
|
3954
|
-
function
|
|
3955
|
-
return
|
|
3954
|
+
function Wt(t) {
|
|
3955
|
+
return Wt = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(n) {
|
|
3956
3956
|
return n.__proto__ || Object.getPrototypeOf(n);
|
|
3957
|
-
},
|
|
3957
|
+
}, Wt(t);
|
|
3958
3958
|
}
|
|
3959
3959
|
function lo(t, e, n) {
|
|
3960
3960
|
return e = Ea(e), e in t ? Object.defineProperty(t, e, { value: n, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = n, t;
|
|
@@ -3975,7 +3975,7 @@ function uo(t, e) {
|
|
|
3975
3975
|
}
|
|
3976
3976
|
return (e === "string" ? String : Number)(t);
|
|
3977
3977
|
}
|
|
3978
|
-
var
|
|
3978
|
+
var Et = K, Q = Cs, fo = to, mo = fo.createFocusTrap, po = no, ho = po.isFocusable, Gn = /* @__PURE__ */ function(t) {
|
|
3979
3979
|
io(n, t);
|
|
3980
3980
|
var e = so(n);
|
|
3981
3981
|
function n(r) {
|
|
@@ -4147,14 +4147,14 @@ var Tt = K, Q = Cs, fo = to, mo = fo.createFocusTrap, po = no, ho = po.isFocusab
|
|
|
4147
4147
|
}, {
|
|
4148
4148
|
key: "render",
|
|
4149
4149
|
value: function() {
|
|
4150
|
-
var i = this, s = this.props.children ?
|
|
4150
|
+
var i = this, s = this.props.children ? Et.Children.only(this.props.children) : void 0;
|
|
4151
4151
|
if (s) {
|
|
4152
|
-
if (s.type && s.type ===
|
|
4152
|
+
if (s.type && s.type === Et.Fragment)
|
|
4153
4153
|
throw new Error("A focus-trap cannot use a Fragment as its child container. Try replacing it with a <div> element.");
|
|
4154
4154
|
var o = function(l) {
|
|
4155
4155
|
var u = i.props.containerElements;
|
|
4156
4156
|
s && (typeof s.ref == "function" ? s.ref(l) : s.ref && (s.ref.current = l)), i.focusTrapElements = u || [l];
|
|
4157
|
-
}, c =
|
|
4157
|
+
}, c = Et.cloneElement(s, {
|
|
4158
4158
|
ref: o
|
|
4159
4159
|
});
|
|
4160
4160
|
return c;
|
|
@@ -4162,7 +4162,7 @@ var Tt = K, Q = Cs, fo = to, mo = fo.createFocusTrap, po = no, ho = po.isFocusab
|
|
|
4162
4162
|
return null;
|
|
4163
4163
|
}
|
|
4164
4164
|
}]), n;
|
|
4165
|
-
}(
|
|
4165
|
+
}(Et.Component), ot = typeof Element > "u" ? Function : Element;
|
|
4166
4166
|
Gn.propTypes = {
|
|
4167
4167
|
active: Q.bool,
|
|
4168
4168
|
paused: Q.bool,
|
|
@@ -4220,7 +4220,7 @@ Gn.defaultProps = {
|
|
|
4220
4220
|
var go = Gn;
|
|
4221
4221
|
const vo = /* @__PURE__ */ Xr(go);
|
|
4222
4222
|
const Sa = ({ element: t = "section", children: e, className: n, ...r }) => K.createElement(t, {
|
|
4223
|
-
className:
|
|
4223
|
+
className: S("modal", n),
|
|
4224
4224
|
children: typeof e == "string" ? /* @__PURE__ */ a.jsx("p", { children: e }) : e,
|
|
4225
4225
|
...r
|
|
4226
4226
|
});
|
|
@@ -4242,21 +4242,21 @@ const Xt = ({
|
|
|
4242
4242
|
const m = G(), [p, v] = te(e), b = (y) => {
|
|
4243
4243
|
y.key === "Escape" && _(!1);
|
|
4244
4244
|
};
|
|
4245
|
-
|
|
4245
|
+
ae(() => (window.addEventListener("keyup", b), () => {
|
|
4246
4246
|
window.removeEventListener("keyup", b);
|
|
4247
4247
|
}));
|
|
4248
4248
|
const _ = (y) => {
|
|
4249
4249
|
v(y), y ? (i(), document.body.classList.add("has-overlay")) : (s(), document.body.classList.remove("has-overlay"));
|
|
4250
4250
|
};
|
|
4251
|
-
|
|
4251
|
+
ae(() => {
|
|
4252
4252
|
_(e);
|
|
4253
4253
|
}, [e]);
|
|
4254
4254
|
const g = r ? { "--max-width": `${r / 16}rem` } : {};
|
|
4255
|
-
return /* @__PURE__ */ a.jsx("div", { className:
|
|
4255
|
+
return /* @__PURE__ */ a.jsx("div", { className: S("overlay", { open: p }), role: "dialog", children: /* @__PURE__ */ a.jsx(
|
|
4256
4256
|
Sa,
|
|
4257
4257
|
{
|
|
4258
4258
|
id: t,
|
|
4259
|
-
className:
|
|
4259
|
+
className: S("overlay-modal", u, {
|
|
4260
4260
|
"has-max-width": r
|
|
4261
4261
|
}),
|
|
4262
4262
|
hidden: !p,
|
|
@@ -4265,7 +4265,7 @@ const Xt = ({
|
|
|
4265
4265
|
/* @__PURE__ */ a.jsxs("div", { className: "top", children: [
|
|
4266
4266
|
c && /* @__PURE__ */ a.jsx("h2", { className: "modal-title", children: c }),
|
|
4267
4267
|
/* @__PURE__ */ a.jsx(
|
|
4268
|
-
|
|
4268
|
+
ie,
|
|
4269
4269
|
{
|
|
4270
4270
|
variant: "tertiary",
|
|
4271
4271
|
size: "medium",
|
|
@@ -4282,9 +4282,9 @@ const Xt = ({
|
|
|
4282
4282
|
f,
|
|
4283
4283
|
l && /* @__PURE__ */ a.jsxs("div", { className: "bottom", children: [
|
|
4284
4284
|
/* @__PURE__ */ a.jsx(Re, {}),
|
|
4285
|
-
/* @__PURE__ */ a.jsx(
|
|
4285
|
+
/* @__PURE__ */ a.jsx(yt, { buttons: l })
|
|
4286
4286
|
] }),
|
|
4287
|
-
o && /* @__PURE__ */ a.jsx(
|
|
4287
|
+
o && /* @__PURE__ */ a.jsx(Bt, { className: "error", children: o })
|
|
4288
4288
|
] }) })
|
|
4289
4289
|
}
|
|
4290
4290
|
) });
|
|
@@ -4293,14 +4293,14 @@ const Xt = ({
|
|
|
4293
4293
|
"aria-expanded": e,
|
|
4294
4294
|
"aria-controls": t
|
|
4295
4295
|
});
|
|
4296
|
-
const
|
|
4296
|
+
const St = "emailHelperTextBox_", yo = ({
|
|
4297
4297
|
type: t,
|
|
4298
4298
|
email: e,
|
|
4299
4299
|
redirectPath: n,
|
|
4300
4300
|
resendVerificationCode: r
|
|
4301
4301
|
}) => {
|
|
4302
4302
|
const i = G(), [s, o] = te({
|
|
4303
|
-
path: `${
|
|
4303
|
+
path: `${St}default`,
|
|
4304
4304
|
type: "default",
|
|
4305
4305
|
link: {},
|
|
4306
4306
|
mail: {},
|
|
@@ -4310,7 +4310,7 @@ const Et = "emailHelperTextBox_", yo = ({
|
|
|
4310
4310
|
p.preventDefault(), p.stopPropagation();
|
|
4311
4311
|
const v = (b) => {
|
|
4312
4312
|
o({
|
|
4313
|
-
path: `${
|
|
4313
|
+
path: `${St}error_verificationFailedToSend`,
|
|
4314
4314
|
type: "error",
|
|
4315
4315
|
link: {
|
|
4316
4316
|
"data-gtm-event-context": "VerifyEmailBox",
|
|
@@ -4330,7 +4330,7 @@ const Et = "emailHelperTextBox_", yo = ({
|
|
|
4330
4330
|
});
|
|
4331
4331
|
};
|
|
4332
4332
|
if (typeof r != "function") {
|
|
4333
|
-
v(i.formatMessage({ id: `${
|
|
4333
|
+
v(i.formatMessage({ id: `${St}error_noFunction` }));
|
|
4334
4334
|
return;
|
|
4335
4335
|
}
|
|
4336
4336
|
f(!0), r(e).then(() => {
|
|
@@ -4344,9 +4344,9 @@ const Et = "emailHelperTextBox_", yo = ({
|
|
|
4344
4344
|
/* eslint-disable react-hooks/exhaustive-deps */
|
|
4345
4345
|
[e, n, r]
|
|
4346
4346
|
);
|
|
4347
|
-
|
|
4347
|
+
ae(
|
|
4348
4348
|
() => {
|
|
4349
|
-
let p =
|
|
4349
|
+
let p = St, v = "default", b = {}, _ = {};
|
|
4350
4350
|
switch (t) {
|
|
4351
4351
|
case "gov":
|
|
4352
4352
|
p += "autoApproved", v = "success";
|
|
@@ -4452,7 +4452,7 @@ const Et = "emailHelperTextBox_", yo = ({
|
|
|
4452
4452
|
type: c,
|
|
4453
4453
|
id: n,
|
|
4454
4454
|
name: s,
|
|
4455
|
-
className:
|
|
4455
|
+
className: S(t, e, {
|
|
4456
4456
|
"has-scrollbar": c === "textarea" && d.current && d.current.clientHeight < d.current.scrollHeight
|
|
4457
4457
|
}),
|
|
4458
4458
|
value: f,
|
|
@@ -4489,14 +4489,14 @@ const He = {
|
|
|
4489
4489
|
activePredictionIndex: -1,
|
|
4490
4490
|
isPredictionSelected: !!t
|
|
4491
4491
|
}), { formatMessage: p } = G();
|
|
4492
|
-
e || (e = p({ id: "inputAutocomplete_placeholder" })),
|
|
4492
|
+
e || (e = p({ id: "inputAutocomplete_placeholder" })), ae(() => {
|
|
4493
4493
|
const g = setTimeout(() => {
|
|
4494
4494
|
d || f((y) => ({ ...y, debouncedInput: s }));
|
|
4495
4495
|
}, _o);
|
|
4496
4496
|
return () => {
|
|
4497
4497
|
clearTimeout(g);
|
|
4498
4498
|
};
|
|
4499
|
-
}, [s, d]),
|
|
4499
|
+
}, [s, d]), ae(() => {
|
|
4500
4500
|
c && !d ? (async () => {
|
|
4501
4501
|
try {
|
|
4502
4502
|
const y = await i(c) || [];
|
|
@@ -4505,7 +4505,7 @@ const He = {
|
|
|
4505
4505
|
console.error("Error fetching predictions:", y), m((E) => ({ ...E, predictions: [] }));
|
|
4506
4506
|
}
|
|
4507
4507
|
})() : m((g) => ({ ...g, predictions: [] }));
|
|
4508
|
-
}, [c, d]),
|
|
4508
|
+
}, [c, d]), ae(() => {
|
|
4509
4509
|
u >= 0 && l[u] && f((g) => ({ ...g, displayInput: l[u].description }));
|
|
4510
4510
|
}, [u, l]);
|
|
4511
4511
|
const v = (g) => {
|
|
@@ -4531,7 +4531,7 @@ const He = {
|
|
|
4531
4531
|
{
|
|
4532
4532
|
onClick: () => _(g),
|
|
4533
4533
|
onMouseEnter: () => m((E) => ({ ...E, activePredictionIndex: y })),
|
|
4534
|
-
className:
|
|
4534
|
+
className: S("predictions-list-item", { active: y === u }),
|
|
4535
4535
|
children: g.description
|
|
4536
4536
|
},
|
|
4537
4537
|
y
|
|
@@ -4584,7 +4584,7 @@ const Ca = ({
|
|
|
4584
4584
|
const y = g.target;
|
|
4585
4585
|
y.nodeName.toLowerCase() === "a" || y.parentNode && y.parentNode.nodeName.toLowerCase() === "a" || (g.preventDefault(), g.stopPropagation(), b());
|
|
4586
4586
|
},
|
|
4587
|
-
className:
|
|
4587
|
+
className: S("checkbox-wrapper", t),
|
|
4588
4588
|
...d,
|
|
4589
4589
|
...v
|
|
4590
4590
|
},
|
|
@@ -4597,7 +4597,7 @@ const wo = Fe(function({
|
|
|
4597
4597
|
return /* @__PURE__ */ a.jsx(
|
|
4598
4598
|
Wn,
|
|
4599
4599
|
{
|
|
4600
|
-
className:
|
|
4600
|
+
className: S("rotating-chevron", `direction-${e}`)
|
|
4601
4601
|
}
|
|
4602
4602
|
);
|
|
4603
4603
|
});
|
|
@@ -4617,23 +4617,23 @@ const ko = ({
|
|
|
4617
4617
|
}) => {
|
|
4618
4618
|
const u = G(), [d, m] = te(!1), p = r || n, v = Array.isArray(p) ? [...p] : p ? [p] : [], [b, _] = te(v);
|
|
4619
4619
|
let g;
|
|
4620
|
-
Array.isArray(b) && b.length === 1 && typeof b[0] == "string" ? g = e && b ? e.find((
|
|
4620
|
+
Array.isArray(b) && b.length === 1 && typeof b[0] == "string" ? g = e && b ? e.find((F) => F.id === b[0]) : e ? e[0] : { id: "", label: "" } : Array.isArray(b) && b.length === 1 && typeof b[0] != "string" ? g = b[0] : g = { id: "", label: "" }, ae(() => {
|
|
4621
4621
|
_(v);
|
|
4622
4622
|
}, [r, n]);
|
|
4623
|
-
const { onChange: y, onMultiSelectSubmit: E, ...j } = i, w = (
|
|
4623
|
+
const { onChange: y, onMultiSelectSubmit: E, ...j } = i, w = (F) => {
|
|
4624
4624
|
if (c) {
|
|
4625
4625
|
let q = [];
|
|
4626
|
-
b != null && b.includes(
|
|
4626
|
+
b != null && b.includes(F.id) ? q = b.filter((M) => M !== F.id) : q = [...b, F.id], _([...q]), y && y([...q]);
|
|
4627
4627
|
} else
|
|
4628
|
-
_([
|
|
4629
|
-
},
|
|
4630
|
-
if (
|
|
4628
|
+
_([F]), y && y(F.id), m(!1);
|
|
4629
|
+
}, z = (F) => {
|
|
4630
|
+
if (F === "all") {
|
|
4631
4631
|
const q = (e == null ? void 0 : e.map((M) => M.id)) || [];
|
|
4632
4632
|
_(q), y && y(q);
|
|
4633
4633
|
} else
|
|
4634
4634
|
_([]), y && y([]);
|
|
4635
4635
|
};
|
|
4636
|
-
return /* @__PURE__ */ a.jsxs("div", { className:
|
|
4636
|
+
return /* @__PURE__ */ a.jsxs("div", { className: S("dropdown-wrapper", t), children: [
|
|
4637
4637
|
/* @__PURE__ */ a.jsxs(
|
|
4638
4638
|
"button",
|
|
4639
4639
|
{
|
|
@@ -4641,8 +4641,8 @@ const ko = ({
|
|
|
4641
4641
|
"aria-expanded": d,
|
|
4642
4642
|
"aria-haspopup": "listbox",
|
|
4643
4643
|
"aria-controls": "dropdown-list",
|
|
4644
|
-
onClick: (
|
|
4645
|
-
|
|
4644
|
+
onClick: (F) => {
|
|
4645
|
+
F.preventDefault(), F.stopPropagation(), m(!d);
|
|
4646
4646
|
},
|
|
4647
4647
|
"data-testid": "dropdown-selector",
|
|
4648
4648
|
...j,
|
|
@@ -4656,14 +4656,14 @@ const ko = ({
|
|
|
4656
4656
|
"select",
|
|
4657
4657
|
{
|
|
4658
4658
|
defaultValue: g.id,
|
|
4659
|
-
onChange: (
|
|
4660
|
-
|
|
4661
|
-
const q = e && e.find((M) => M.id ===
|
|
4659
|
+
onChange: (F) => {
|
|
4660
|
+
F.preventDefault(), F.stopPropagation();
|
|
4661
|
+
const q = e && e.find((M) => M.id === F.target.value);
|
|
4662
4662
|
w(q);
|
|
4663
4663
|
},
|
|
4664
4664
|
hidden: !d,
|
|
4665
4665
|
...j,
|
|
4666
|
-
children: e == null ? void 0 : e.map((
|
|
4666
|
+
children: e == null ? void 0 : e.map((F) => /* @__PURE__ */ a.jsx("option", { value: F.id, children: F.label }, F.id))
|
|
4667
4667
|
}
|
|
4668
4668
|
),
|
|
4669
4669
|
/* @__PURE__ */ a.jsxs(
|
|
@@ -4678,54 +4678,54 @@ const ko = ({
|
|
|
4678
4678
|
/* @__PURE__ */ a.jsx("p", { children: `${b == null ? void 0 : b.length} selected` }),
|
|
4679
4679
|
/* @__PURE__ */ a.jsxs("ul", { children: [
|
|
4680
4680
|
/* @__PURE__ */ a.jsx("li", { children: /* @__PURE__ */ a.jsx(
|
|
4681
|
-
|
|
4681
|
+
ie,
|
|
4682
4682
|
{
|
|
4683
4683
|
variant: "tertiary",
|
|
4684
4684
|
size: "small",
|
|
4685
|
-
onClick: () =>
|
|
4685
|
+
onClick: () => z("all"),
|
|
4686
4686
|
className: "gtm-trackable",
|
|
4687
4687
|
children: u.formatMessage({ id: "dropdown_menu_multiselect_all" })
|
|
4688
4688
|
}
|
|
4689
4689
|
) }),
|
|
4690
4690
|
/* @__PURE__ */ a.jsx("li", { children: /* @__PURE__ */ a.jsx(
|
|
4691
|
-
|
|
4691
|
+
ie,
|
|
4692
4692
|
{
|
|
4693
4693
|
variant: "tertiary",
|
|
4694
4694
|
size: "small",
|
|
4695
|
-
onClick: () =>
|
|
4695
|
+
onClick: () => z("none"),
|
|
4696
4696
|
className: "gtm-trackable",
|
|
4697
4697
|
children: u.formatMessage({ id: "dropdown_menu_multiselect_none" })
|
|
4698
4698
|
}
|
|
4699
4699
|
) })
|
|
4700
4700
|
] })
|
|
4701
4701
|
] }),
|
|
4702
|
-
/* @__PURE__ */ a.jsx("ul", { children: e == null ? void 0 : e.map((
|
|
4703
|
-
const q =
|
|
4702
|
+
/* @__PURE__ */ a.jsx("ul", { children: e == null ? void 0 : e.map((F) => {
|
|
4703
|
+
const q = F.id === g.id || (b == null ? void 0 : b.includes(F)) || (b == null ? void 0 : b.includes(F.id));
|
|
4704
4704
|
return /* @__PURE__ */ a.jsx("li", { "data-testid": "dropdown-options", children: /* @__PURE__ */ a.jsxs(
|
|
4705
4705
|
"button",
|
|
4706
4706
|
{
|
|
4707
|
-
className:
|
|
4707
|
+
className: S("gtm-trackable", {
|
|
4708
4708
|
selected: q,
|
|
4709
4709
|
"selected-single": q && !c
|
|
4710
4710
|
}),
|
|
4711
|
-
"data-gtm-event-type": `${
|
|
4711
|
+
"data-gtm-event-type": `${F}-click`,
|
|
4712
4712
|
"data-gtm-event-context": s,
|
|
4713
4713
|
onClick: (M) => {
|
|
4714
|
-
M.preventDefault(), M.stopPropagation(), w(
|
|
4714
|
+
M.preventDefault(), M.stopPropagation(), w(F);
|
|
4715
4715
|
},
|
|
4716
4716
|
role: "menuitem",
|
|
4717
4717
|
"aria-current": q,
|
|
4718
4718
|
"data-testid": q ? "current-selection" : "",
|
|
4719
4719
|
children: [
|
|
4720
4720
|
c && /* @__PURE__ */ a.jsx("span", { className: "pretty-checkbox", "data-testid": "pretty-checkbox" }),
|
|
4721
|
-
/* @__PURE__ */ a.jsx("span", { className:
|
|
4721
|
+
/* @__PURE__ */ a.jsx("span", { className: S({ "menu-option-label": c }), children: F.label })
|
|
4722
4722
|
]
|
|
4723
4723
|
}
|
|
4724
|
-
) },
|
|
4724
|
+
) }, F.id);
|
|
4725
4725
|
}) })
|
|
4726
4726
|
] }),
|
|
4727
4727
|
(f == null ? void 0 : f.submitSection) && /* @__PURE__ */ a.jsx("p", { className: "submit", children: /* @__PURE__ */ a.jsx(
|
|
4728
|
-
|
|
4728
|
+
ie,
|
|
4729
4729
|
{
|
|
4730
4730
|
variant: "secondary",
|
|
4731
4731
|
onClick: () => {
|
|
@@ -4766,7 +4766,7 @@ const jo = ({
|
|
|
4766
4766
|
"ul",
|
|
4767
4767
|
{
|
|
4768
4768
|
...d,
|
|
4769
|
-
className:
|
|
4769
|
+
className: S("options-wrapper", t),
|
|
4770
4770
|
"data-testid": `ul-${r}`,
|
|
4771
4771
|
children: c == null ? void 0 : c.map(
|
|
4772
4772
|
({
|
|
@@ -4780,8 +4780,8 @@ const jo = ({
|
|
|
4780
4780
|
return;
|
|
4781
4781
|
let w;
|
|
4782
4782
|
if (s) {
|
|
4783
|
-
const
|
|
4784
|
-
Array.isArray(p) &&
|
|
4783
|
+
const z = p == null ? void 0 : p.indexOf(g);
|
|
4784
|
+
Array.isArray(p) && z >= 0 ? (w = p, w.splice(z, 1)) : (!p || p.length === 0 ? w = [] : w = p, w.push(g));
|
|
4785
4785
|
} else
|
|
4786
4786
|
w = v === g ? void 0 : g;
|
|
4787
4787
|
e.onChange(w);
|
|
@@ -4826,7 +4826,7 @@ const To = ({
|
|
|
4826
4826
|
"button",
|
|
4827
4827
|
{
|
|
4828
4828
|
type: "button",
|
|
4829
|
-
className:
|
|
4829
|
+
className: S("show-password gtm-trackable", {
|
|
4830
4830
|
"password-visible": c
|
|
4831
4831
|
}),
|
|
4832
4832
|
"data-gtm-event-context": n,
|
|
@@ -4900,7 +4900,7 @@ const Ve = {
|
|
|
4900
4900
|
{
|
|
4901
4901
|
..._,
|
|
4902
4902
|
label: g,
|
|
4903
|
-
className:
|
|
4903
|
+
className: S("field-wrapper", n)
|
|
4904
4904
|
}
|
|
4905
4905
|
),
|
|
4906
4906
|
/* @__PURE__ */ a.jsx(y, { as: "p" })
|
|
@@ -4910,7 +4910,7 @@ const Ve = {
|
|
|
4910
4910
|
className: "checkboxes-label text-small",
|
|
4911
4911
|
"data-testid": `label-${t}`
|
|
4912
4912
|
});
|
|
4913
|
-
return /* @__PURE__ */ a.jsxs("dl", { className:
|
|
4913
|
+
return /* @__PURE__ */ a.jsxs("dl", { className: S("field-wrapper text-medium", n), children: [
|
|
4914
4914
|
/* @__PURE__ */ a.jsx("dt", { children: /* @__PURE__ */ a.jsxs(E, { ...b, children: [
|
|
4915
4915
|
g,
|
|
4916
4916
|
m && o && /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
@@ -4927,7 +4927,7 @@ const Ve = {
|
|
|
4927
4927
|
s > 0 ? /* @__PURE__ */ a.jsxs(
|
|
4928
4928
|
"small",
|
|
4929
4929
|
{
|
|
4930
|
-
className:
|
|
4930
|
+
className: S("character-limit", {
|
|
4931
4931
|
"near-limit": p >= 0.99 * s,
|
|
4932
4932
|
"approaching-limit": p >= 0.9 * s && p < 0.99 * s
|
|
4933
4933
|
}),
|
|
@@ -5056,18 +5056,28 @@ const Qn = ({
|
|
|
5056
5056
|
variant: "secondary",
|
|
5057
5057
|
size: "large"
|
|
5058
5058
|
},
|
|
5059
|
-
meta: {
|
|
5059
|
+
meta: {
|
|
5060
|
+
shouldShowCancelButton: c = !1,
|
|
5061
|
+
shouldReset: f = !0,
|
|
5062
|
+
showRequiredLabels: l = !0,
|
|
5063
|
+
showSuccessMessage: u = !1
|
|
5064
|
+
} = {
|
|
5060
5065
|
shouldShowCancelButton: !1,
|
|
5061
5066
|
shouldReset: !0,
|
|
5062
5067
|
showRequiredLabels: !0,
|
|
5063
5068
|
showSuccessMessage: !1
|
|
5064
5069
|
},
|
|
5065
5070
|
gtm: d = { context: "Form", event: "form-submit-click" },
|
|
5066
|
-
functions: {
|
|
5067
|
-
|
|
5068
|
-
|
|
5069
|
-
|
|
5070
|
-
|
|
5071
|
+
functions: {
|
|
5072
|
+
onSuccess: m = async () => {
|
|
5073
|
+
},
|
|
5074
|
+
onCancel: p = () => {
|
|
5075
|
+
},
|
|
5076
|
+
onCatch: v = () => {
|
|
5077
|
+
},
|
|
5078
|
+
onFailure: b = () => {
|
|
5079
|
+
}
|
|
5080
|
+
} = {
|
|
5071
5081
|
onSuccess: async () => {
|
|
5072
5082
|
},
|
|
5073
5083
|
onCancel: () => {
|
|
@@ -5079,95 +5089,122 @@ const Qn = ({
|
|
|
5079
5089
|
},
|
|
5080
5090
|
..._
|
|
5081
5091
|
}) => {
|
|
5082
|
-
const { customOnSubmit: g, hideButton: y, ...E } = s, j = 40, w = G(),
|
|
5083
|
-
t.length && t.forEach((
|
|
5084
|
-
const
|
|
5085
|
-
|
|
5092
|
+
const { customOnSubmit: g, hideButton: y, ...E } = s, j = 40, w = G(), z = {};
|
|
5093
|
+
t.length && t.forEach((A) => {
|
|
5094
|
+
const W = A.id || A.name;
|
|
5095
|
+
W && (z[W] = A.value || "");
|
|
5086
5096
|
});
|
|
5087
|
-
const [
|
|
5097
|
+
const [F, q] = zn(So, {
|
|
5088
5098
|
isSubmitting: !1,
|
|
5089
5099
|
formSubmitted: !1,
|
|
5090
5100
|
errors: {},
|
|
5091
|
-
values:
|
|
5092
|
-
}), { errors: M, isSubmitting: O, formSubmitted:
|
|
5093
|
-
|
|
5094
|
-
f &&
|
|
5101
|
+
values: z
|
|
5102
|
+
}), { errors: M, isSubmitting: O, formSubmitted: C, values: T } = F;
|
|
5103
|
+
ae(() => {
|
|
5104
|
+
f && C && (bn = setTimeout(() => {
|
|
5095
5105
|
q({
|
|
5096
5106
|
type: "updateValue",
|
|
5097
5107
|
payload: { key: "formSubmitted", value: !1 }
|
|
5098
5108
|
});
|
|
5099
5109
|
}, 3e3));
|
|
5100
|
-
}, [
|
|
5110
|
+
}, [C]), ae(() => () => {
|
|
5101
5111
|
bn && clearTimeout(bn);
|
|
5102
|
-
}, []),
|
|
5103
|
-
const
|
|
5112
|
+
}, []), ae(() => {
|
|
5113
|
+
const A = (W) => {
|
|
5104
5114
|
q({
|
|
5105
5115
|
type: "updateValue",
|
|
5106
|
-
payload: { key:
|
|
5116
|
+
payload: { key: W.detail.id, value: W.detail.value }
|
|
5107
5117
|
});
|
|
5108
5118
|
};
|
|
5109
5119
|
return document.addEventListener(
|
|
5110
5120
|
"dropdownMultiSelectSubmit",
|
|
5111
|
-
|
|
5121
|
+
A
|
|
5112
5122
|
), () => {
|
|
5113
5123
|
document.removeEventListener(
|
|
5114
5124
|
"dropdownMultiSelectSubmit",
|
|
5115
|
-
|
|
5125
|
+
A
|
|
5116
5126
|
);
|
|
5117
5127
|
};
|
|
5118
5128
|
}, []);
|
|
5119
|
-
const x = pe(null),
|
|
5129
|
+
const x = pe(null), $ = r || x;
|
|
5120
5130
|
if (!t.length)
|
|
5121
5131
|
return null;
|
|
5122
5132
|
s.text || (s.text = w.formatMessage({ id: "form_submit" }));
|
|
5123
|
-
const
|
|
5124
|
-
|
|
5125
|
-
|
|
5126
|
-
|
|
5127
|
-
|
|
5128
|
-
|
|
5129
|
-
|
|
5130
|
-
|
|
5131
|
-
|
|
5132
|
-
|
|
5133
|
-
|
|
5134
|
-
|
|
5135
|
-
|
|
5136
|
-
payload: {
|
|
5137
|
-
fields: t,
|
|
5138
|
-
dispatch: q,
|
|
5139
|
-
intl: w
|
|
5133
|
+
const U = [
|
|
5134
|
+
{
|
|
5135
|
+
...E,
|
|
5136
|
+
icon: C ? { icon: "tick", position: "left" } : !1,
|
|
5137
|
+
className: "gtm-trackable",
|
|
5138
|
+
onClick: (A) => {
|
|
5139
|
+
var k;
|
|
5140
|
+
if (A.preventDefault(), A.stopPropagation(), O)
|
|
5141
|
+
return;
|
|
5142
|
+
let W = 0;
|
|
5143
|
+
if ((k = $ == null ? void 0 : $.current) != null && k.id) {
|
|
5144
|
+
const N = document.getElementById($.current.id);
|
|
5145
|
+
N && (W = N.getBoundingClientRect().top + window.scrollY);
|
|
5140
5146
|
}
|
|
5141
|
-
|
|
5142
|
-
|
|
5143
|
-
|
|
5144
|
-
|
|
5145
|
-
|
|
5146
|
-
|
|
5147
|
-
|
|
5148
|
-
|
|
5149
|
-
|
|
5150
|
-
|
|
5151
|
-
|
|
5152
|
-
|
|
5153
|
-
|
|
5147
|
+
const J = document.getElementById("header");
|
|
5148
|
+
if (J && (W = W - J.offsetHeight - j), W < 0 && (W = 0), window.scrollTo({ top: W, behavior: "smooth" }), q({ type: "toggleSubmitting" }), s.disabled) {
|
|
5149
|
+
typeof s.disabled == "object" && s.disabled.isClickable && q({
|
|
5150
|
+
type: "submitForm",
|
|
5151
|
+
payload: {
|
|
5152
|
+
fields: t,
|
|
5153
|
+
dispatch: q,
|
|
5154
|
+
intl: w
|
|
5155
|
+
}
|
|
5156
|
+
});
|
|
5157
|
+
return;
|
|
5158
|
+
}
|
|
5159
|
+
q({
|
|
5160
|
+
type: "submitForm",
|
|
5161
|
+
payload: {
|
|
5162
|
+
fields: t,
|
|
5163
|
+
dispatch: q,
|
|
5164
|
+
onSuccess: async (N) => {
|
|
5165
|
+
try {
|
|
5166
|
+
await m(N), q({ type: f ? "formSubmittedAndReset" : "formSubmitted" });
|
|
5167
|
+
} catch (Z) {
|
|
5168
|
+
v(Z), q({
|
|
5169
|
+
type: "updateValue",
|
|
5170
|
+
payload: { key: "isSubmitting", value: !1 }
|
|
5171
|
+
});
|
|
5172
|
+
}
|
|
5173
|
+
},
|
|
5174
|
+
onFailure: (N, Z) => {
|
|
5175
|
+
b(N, Z), q({
|
|
5176
|
+
type: "updateValue",
|
|
5177
|
+
payload: { key: "isSubmitting", value: !1 }
|
|
5178
|
+
});
|
|
5179
|
+
},
|
|
5180
|
+
intl: w
|
|
5154
5181
|
}
|
|
5155
|
-
}
|
|
5156
|
-
|
|
5157
|
-
|
|
5158
|
-
|
|
5159
|
-
|
|
5160
|
-
|
|
5161
|
-
|
|
5162
|
-
|
|
5163
|
-
|
|
5182
|
+
});
|
|
5183
|
+
},
|
|
5184
|
+
disabled: O || C || s.disabled,
|
|
5185
|
+
"data-gtm-event-context": d.context,
|
|
5186
|
+
"data-gtm-event-type": d.event,
|
|
5187
|
+
children: O || C ? w.formatMessage({
|
|
5188
|
+
id: `form_${O ? "submitting" : "submitted"}`
|
|
5189
|
+
}) : s.text
|
|
5190
|
+
}
|
|
5191
|
+
];
|
|
5192
|
+
return c && U.unshift({
|
|
5193
|
+
...o,
|
|
5194
|
+
className: "gtm-trackable",
|
|
5195
|
+
"data-gtm-event-context": d.context,
|
|
5196
|
+
"data-gtm-event-type": d.event,
|
|
5197
|
+
disabled: O || C,
|
|
5198
|
+
onClick: p,
|
|
5199
|
+
children: o.text || w.formatMessage({ id: "form_cancel" })
|
|
5200
|
+
}), /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
5164
5201
|
/* @__PURE__ */ a.jsxs(
|
|
5165
5202
|
"form",
|
|
5166
5203
|
{
|
|
5167
5204
|
..._,
|
|
5168
5205
|
id: n,
|
|
5169
|
-
className:
|
|
5170
|
-
ref:
|
|
5206
|
+
className: S("form", e),
|
|
5207
|
+
ref: $,
|
|
5171
5208
|
children: [
|
|
5172
5209
|
M != null && M.general ? /* @__PURE__ */ a.jsx(
|
|
5173
5210
|
tt,
|
|
@@ -5176,90 +5213,51 @@ const Qn = ({
|
|
|
5176
5213
|
text: w.formatMessage({ id: "form_error_generalError" })
|
|
5177
5214
|
}
|
|
5178
5215
|
) : null,
|
|
5179
|
-
(!O && !
|
|
5216
|
+
(!O && !C || g) && t.map((A, W) => {
|
|
5180
5217
|
const {
|
|
5181
|
-
id:
|
|
5182
|
-
component:
|
|
5183
|
-
functions:
|
|
5218
|
+
id: J = A.name || W,
|
|
5219
|
+
component: k,
|
|
5220
|
+
functions: N = { onChange: () => {
|
|
5184
5221
|
} }
|
|
5185
|
-
} =
|
|
5186
|
-
if (
|
|
5187
|
-
return /* @__PURE__ */ a.jsx(
|
|
5188
|
-
const
|
|
5222
|
+
} = A;
|
|
5223
|
+
if (k)
|
|
5224
|
+
return /* @__PURE__ */ a.jsx(k, { ...A.props || {} }, `component-${J}-${W}`);
|
|
5225
|
+
const Z = T ? T[J] : "";
|
|
5189
5226
|
return /* @__PURE__ */ a.jsx(
|
|
5190
5227
|
Eo,
|
|
5191
5228
|
{
|
|
5192
5229
|
intlPath: i,
|
|
5193
|
-
...
|
|
5230
|
+
...A,
|
|
5194
5231
|
showRequiredLabels: l,
|
|
5195
|
-
value:
|
|
5196
|
-
error: M == null ? void 0 : M[
|
|
5232
|
+
value: Z,
|
|
5233
|
+
error: M == null ? void 0 : M[J],
|
|
5197
5234
|
functions: {
|
|
5198
|
-
...
|
|
5199
|
-
onChange: (
|
|
5200
|
-
q({ type: "updateValue", payload: { key:
|
|
5235
|
+
...N,
|
|
5236
|
+
onChange: (B) => {
|
|
5237
|
+
q({ type: "updateValue", payload: { key: J, value: B } }), N.onChange(B && B.toString(), q);
|
|
5201
5238
|
}
|
|
5202
5239
|
}
|
|
5203
5240
|
},
|
|
5204
|
-
|
|
5241
|
+
J
|
|
5205
5242
|
);
|
|
5206
5243
|
}),
|
|
5207
|
-
y ? null : (O ||
|
|
5208
|
-
|
|
5209
|
-
ae,
|
|
5210
|
-
{
|
|
5211
|
-
...o,
|
|
5212
|
-
className: "gtm-trackable",
|
|
5213
|
-
"data-gtm-event-context": d.context,
|
|
5214
|
-
"data-gtm-event-type": d.event,
|
|
5215
|
-
disabled: O || S,
|
|
5216
|
-
onClick: p,
|
|
5217
|
-
children: o.text || w.formatMessage({ id: "form_cancel" })
|
|
5218
|
-
}
|
|
5219
|
-
),
|
|
5220
|
-
"customOnSubmit"
|
|
5221
|
-
] }) : /* @__PURE__ */ a.jsx(
|
|
5222
|
-
"div",
|
|
5244
|
+
y ? null : (O || C) && g ? g : /* @__PURE__ */ a.jsx(
|
|
5245
|
+
yt,
|
|
5223
5246
|
{
|
|
5224
|
-
className:
|
|
5225
|
-
|
|
5226
|
-
|
|
5227
|
-
|
|
5228
|
-
|
|
5229
|
-
...o,
|
|
5230
|
-
className: "gtm-trackable",
|
|
5231
|
-
"data-gtm-event-context": d.context,
|
|
5232
|
-
"data-gtm-event-type": d.event,
|
|
5233
|
-
disabled: O || S,
|
|
5234
|
-
onClick: p,
|
|
5235
|
-
children: o.text || w.formatMessage({ id: "form_cancel" })
|
|
5236
|
-
}
|
|
5237
|
-
),
|
|
5238
|
-
/* @__PURE__ */ a.jsx(
|
|
5239
|
-
ae,
|
|
5240
|
-
{
|
|
5241
|
-
...E,
|
|
5242
|
-
icon: S ? { icon: "tick", position: "left" } : !1,
|
|
5243
|
-
className: "gtm-trackable",
|
|
5244
|
-
onClick: L,
|
|
5245
|
-
disabled: O || S || s.disabled,
|
|
5246
|
-
"data-gtm-event-context": d.context,
|
|
5247
|
-
"data-gtm-event-type": d.event,
|
|
5248
|
-
children: O || S ? w.formatMessage({
|
|
5249
|
-
id: `form_${O ? "submitting" : "submitted"}`
|
|
5250
|
-
}) : s.text
|
|
5251
|
-
}
|
|
5252
|
-
)
|
|
5253
|
-
] })
|
|
5247
|
+
className: S("cta", {
|
|
5248
|
+
center: O || C,
|
|
5249
|
+
submitted: C
|
|
5250
|
+
}),
|
|
5251
|
+
buttons: U
|
|
5254
5252
|
}
|
|
5255
5253
|
)
|
|
5256
5254
|
]
|
|
5257
5255
|
}
|
|
5258
5256
|
),
|
|
5259
|
-
u &&
|
|
5257
|
+
u && C && /* @__PURE__ */ a.jsx(Bt, { className: "success", children: typeof u == "string" ? u : w.formatMessage({ id: "form_success" }) })
|
|
5260
5258
|
] });
|
|
5261
5259
|
};
|
|
5262
|
-
const
|
|
5260
|
+
const Ct = "passwordRules_", $a = "isMoreThanEightCharacters", Na = "includesNumberAndSymbol", Pa = "includesLowerAndUppercase", Co = {
|
|
5263
5261
|
[$a]: "8Characters",
|
|
5264
5262
|
[Na]: "numberSymbol",
|
|
5265
5263
|
[Pa]: "lowercaseUppercase"
|
|
@@ -5272,22 +5270,22 @@ const St = "passwordRules_", $a = "isMoreThanEightCharacters", Na = "includesNum
|
|
|
5272
5270
|
className: e = ""
|
|
5273
5271
|
}) => {
|
|
5274
5272
|
const n = G();
|
|
5275
|
-
return /* @__PURE__ */ a.jsxs("aside", { className:
|
|
5276
|
-
/* @__PURE__ */ a.jsx("small", { children: n.formatMessage({ id: `${
|
|
5273
|
+
return /* @__PURE__ */ a.jsxs("aside", { className: S("password-rules", e), children: [
|
|
5274
|
+
/* @__PURE__ */ a.jsx("small", { children: n.formatMessage({ id: `${Ct}intro` }) }),
|
|
5277
5275
|
/* @__PURE__ */ a.jsx("ul", { children: [$a, Na, Pa].map(
|
|
5278
5276
|
(r) => /* @__PURE__ */ a.jsxs(
|
|
5279
5277
|
"li",
|
|
5280
5278
|
{
|
|
5281
|
-
className:
|
|
5279
|
+
className: S({ matches: t[r] }),
|
|
5282
5280
|
children: [
|
|
5283
5281
|
/* @__PURE__ */ a.jsxs(be, { children: [
|
|
5284
|
-
n.formatMessage({ id: `${
|
|
5282
|
+
n.formatMessage({ id: `${Ct}rule_label` }),
|
|
5285
5283
|
" "
|
|
5286
5284
|
] }),
|
|
5287
|
-
/* @__PURE__ */ a.jsx("span", { children: n.formatMessage({ id: `${
|
|
5285
|
+
/* @__PURE__ */ a.jsx("span", { children: n.formatMessage({ id: `${Ct}rule_${Co[r]}` }) }),
|
|
5288
5286
|
!t[r] && /* @__PURE__ */ a.jsxs(be, { element: "strong", children: [
|
|
5289
5287
|
" ",
|
|
5290
|
-
n.formatMessage({ id: `${
|
|
5288
|
+
n.formatMessage({ id: `${Ct}notMet` })
|
|
5291
5289
|
] })
|
|
5292
5290
|
]
|
|
5293
5291
|
},
|
|
@@ -5327,7 +5325,7 @@ const Cl = ({
|
|
|
5327
5325
|
l((y) => ({ ...y, setUp: !0, disabled: !0 })), i(g);
|
|
5328
5326
|
}
|
|
5329
5327
|
};
|
|
5330
|
-
if (
|
|
5328
|
+
if (ae(() => {
|
|
5331
5329
|
o && !f.setUp && u();
|
|
5332
5330
|
}, [o]), !o)
|
|
5333
5331
|
return /* @__PURE__ */ a.jsx(Te, { className: "rating-placeholder" });
|
|
@@ -5347,16 +5345,16 @@ const Cl = ({
|
|
|
5347
5345
|
l((y) => ({ ...y, disabled: !1 }));
|
|
5348
5346
|
}
|
|
5349
5347
|
};
|
|
5350
|
-
return /* @__PURE__ */ a.jsxs("div", { className:
|
|
5348
|
+
return /* @__PURE__ */ a.jsxs("div", { className: S("rating", s), children: [
|
|
5351
5349
|
/* @__PURE__ */ a.jsx("span", { className: "label", children: b[m ? "success" : "text"] }),
|
|
5352
5350
|
/* @__PURE__ */ a.jsx("ol", { children: Array.from(new Array(e).keys()).map((g) => {
|
|
5353
5351
|
const y = g + 1;
|
|
5354
5352
|
return /* @__PURE__ */ a.jsx(
|
|
5355
5353
|
"li",
|
|
5356
5354
|
{
|
|
5357
|
-
className:
|
|
5355
|
+
className: S({ selected: m && y <= m }),
|
|
5358
5356
|
children: /* @__PURE__ */ a.jsx(
|
|
5359
|
-
|
|
5357
|
+
ie,
|
|
5360
5358
|
{
|
|
5361
5359
|
variant: "tertiary",
|
|
5362
5360
|
size: "small",
|
|
@@ -5394,7 +5392,7 @@ const $l = ({
|
|
|
5394
5392
|
const [c, f] = te(
|
|
5395
5393
|
typeof r == "boolean" || typeof r == "string" ? r : n[0].value
|
|
5396
5394
|
);
|
|
5397
|
-
|
|
5395
|
+
ae(() => {
|
|
5398
5396
|
r && f(r);
|
|
5399
5397
|
}, [r]);
|
|
5400
5398
|
const l = (u) => {
|
|
@@ -5403,7 +5401,7 @@ const $l = ({
|
|
|
5403
5401
|
return /* @__PURE__ */ a.jsxs(
|
|
5404
5402
|
"div",
|
|
5405
5403
|
{
|
|
5406
|
-
className:
|
|
5404
|
+
className: S("toggle", o),
|
|
5407
5405
|
onClick: (u) => {
|
|
5408
5406
|
u.preventDefault(), u.stopPropagation(), l(c === n[0].value ? n[1].value : n[0].value);
|
|
5409
5407
|
},
|
|
@@ -5412,7 +5410,7 @@ const $l = ({
|
|
|
5412
5410
|
/* @__PURE__ */ a.jsx(
|
|
5413
5411
|
"ul",
|
|
5414
5412
|
{
|
|
5415
|
-
className:
|
|
5413
|
+
className: S("toggle-options", {
|
|
5416
5414
|
disabled: s,
|
|
5417
5415
|
on: c === n[1].value
|
|
5418
5416
|
}),
|
|
@@ -5462,7 +5460,7 @@ function Nl({ className: t = "", userId: e, userName: n, src: r, setUserImage: i
|
|
|
5462
5460
|
}
|
|
5463
5461
|
c(!1);
|
|
5464
5462
|
};
|
|
5465
|
-
return /* @__PURE__ */ a.jsxs("div", { className:
|
|
5463
|
+
return /* @__PURE__ */ a.jsxs("div", { className: S("profile-image-change-figure", t), children: [
|
|
5466
5464
|
/* @__PURE__ */ a.jsx(ze, { className: "profile-image-change-picture", name: n, src: r, "data-testid": "profile-picture" }),
|
|
5467
5465
|
f && /* @__PURE__ */ a.jsx("p", { className: "error text-small", children: /* @__PURE__ */ a.jsx(_e, { id: "profile_image_change_error" }) }),
|
|
5468
5466
|
/* @__PURE__ */ a.jsx(
|
|
@@ -5478,7 +5476,7 @@ function Nl({ className: t = "", userId: e, userName: n, src: r, setUserImage: i
|
|
|
5478
5476
|
}
|
|
5479
5477
|
),
|
|
5480
5478
|
/* @__PURE__ */ a.jsx(
|
|
5481
|
-
|
|
5479
|
+
ie,
|
|
5482
5480
|
{
|
|
5483
5481
|
onClick: () => u.current && u.current.click(),
|
|
5484
5482
|
variant: "secondary",
|
|
@@ -5583,15 +5581,15 @@ const Po = ({
|
|
|
5583
5581
|
] }) }),
|
|
5584
5582
|
/* @__PURE__ */ a.jsx(Re, {}),
|
|
5585
5583
|
/* @__PURE__ */ a.jsx("div", { className: "footer", children: v === "SUCCESS" ? /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
5586
|
-
/* @__PURE__ */ a.jsx(
|
|
5587
|
-
/* @__PURE__ */ a.jsx(
|
|
5588
|
-
] }) : /* @__PURE__ */ a.jsx(
|
|
5584
|
+
/* @__PURE__ */ a.jsx(ie, { variant: "secondary", onClick: y, children: _({ id: "inviteForm_ctaSendMoreInvites" }) }),
|
|
5585
|
+
/* @__PURE__ */ a.jsx(ie, { onClick: E, children: _({ id: "inviteForm_ctaDone" }) })
|
|
5586
|
+
] }) : /* @__PURE__ */ a.jsx(ie, { onClick: y, children: _({ id: "inviteForm_ctaTryAgain" }) }) })
|
|
5589
5587
|
] }) : /* @__PURE__ */ a.jsx("div", { className: "invite-form-wrapper", children: /* @__PURE__ */ a.jsxs(
|
|
5590
5588
|
"form",
|
|
5591
5589
|
{
|
|
5592
5590
|
style: { backgroundColor: s },
|
|
5593
5591
|
onSubmit: g,
|
|
5594
|
-
className:
|
|
5592
|
+
className: S("invite-form gtm-trackable"),
|
|
5595
5593
|
children: [
|
|
5596
5594
|
/* @__PURE__ */ a.jsxs("fieldset", { className: "content", children: [
|
|
5597
5595
|
/* @__PURE__ */ a.jsx("h2", { className: "title", style: { color: r }, children: t }),
|
|
@@ -5607,16 +5605,16 @@ const Po = ({
|
|
|
5607
5605
|
d(j), p(!j.length);
|
|
5608
5606
|
},
|
|
5609
5607
|
autoFocus: !1,
|
|
5610
|
-
getLabel: (j, w,
|
|
5608
|
+
getLabel: (j, w, z) => /* @__PURE__ */ a.jsxs("div", { className: "email text-medium", children: [
|
|
5611
5609
|
/* @__PURE__ */ a.jsx("div", { "data-tag-item": !0, children: j }),
|
|
5612
5610
|
/* @__PURE__ */ a.jsx(
|
|
5613
|
-
|
|
5611
|
+
ie,
|
|
5614
5612
|
{
|
|
5615
5613
|
variant: "tertiary",
|
|
5616
5614
|
size: "small",
|
|
5617
5615
|
icon: { icon: "close" },
|
|
5618
5616
|
onClick: () => {
|
|
5619
|
-
|
|
5617
|
+
z(w), p(!u.length);
|
|
5620
5618
|
},
|
|
5621
5619
|
className: "remove-email-button",
|
|
5622
5620
|
screenreaderText: _({ id: "overlay_close" })
|
|
@@ -5627,7 +5625,7 @@ const Po = ({
|
|
|
5627
5625
|
)
|
|
5628
5626
|
] }),
|
|
5629
5627
|
/* @__PURE__ */ a.jsx(Re, {}),
|
|
5630
|
-
/* @__PURE__ */ a.jsx("fieldset", { className: "footer", children: /* @__PURE__ */ a.jsx(
|
|
5628
|
+
/* @__PURE__ */ a.jsx("fieldset", { className: "footer", children: /* @__PURE__ */ a.jsx(ie, { className: "sendEmailsButton", disabled: m, children: n }) })
|
|
5631
5629
|
]
|
|
5632
5630
|
}
|
|
5633
5631
|
) });
|
|
@@ -5651,7 +5649,7 @@ const Mo = ({
|
|
|
5651
5649
|
"form",
|
|
5652
5650
|
{
|
|
5653
5651
|
onSubmit: u,
|
|
5654
|
-
className:
|
|
5652
|
+
className: S("search-form gtm-trackable", e),
|
|
5655
5653
|
"data-gtm-event-context": i,
|
|
5656
5654
|
"data-gtm-event-type": s,
|
|
5657
5655
|
children: /* @__PURE__ */ a.jsx(
|
|
@@ -5936,7 +5934,7 @@ const Mo = ({
|
|
|
5936
5934
|
const Do = ({ className: t = "" }) => /* @__PURE__ */ a.jsxs(
|
|
5937
5935
|
"div",
|
|
5938
5936
|
{
|
|
5939
|
-
className:
|
|
5937
|
+
className: S("success-message", t),
|
|
5940
5938
|
"data-testid": "success-message",
|
|
5941
5939
|
children: [
|
|
5942
5940
|
/* @__PURE__ */ a.jsx("p", { className: "success-title", children: /* @__PURE__ */ a.jsx(_e, { id: "signup_success_title" }) }),
|
|
@@ -6003,11 +6001,11 @@ const Ao = {
|
|
|
6003
6001
|
tc: K.createRef(),
|
|
6004
6002
|
hiddenValidation: K.createRef()
|
|
6005
6003
|
};
|
|
6006
|
-
|
|
6004
|
+
ae(() => {
|
|
6007
6005
|
d === !0 && _.jobTitle.current && _.jobTitle.current.focus();
|
|
6008
|
-
}, [d]),
|
|
6006
|
+
}, [d]), ae(() => {
|
|
6009
6007
|
(s.showSuccessMessage || v["signup-this-session"]) && f([{ type: "showSuccessMessage", value: !0 }]);
|
|
6010
|
-
}, [v]),
|
|
6008
|
+
}, [v]), ae(() => {
|
|
6011
6009
|
if (m && v["functional-cookie-consent"]) {
|
|
6012
6010
|
const E = {
|
|
6013
6011
|
path: "/",
|
|
@@ -6028,7 +6026,7 @@ const Ao = {
|
|
|
6028
6026
|
return n.successMessage && m ? /* @__PURE__ */ a.jsx(Do, { className: t }) : /* @__PURE__ */ a.jsxs(
|
|
6029
6027
|
"fieldset",
|
|
6030
6028
|
{
|
|
6031
|
-
className:
|
|
6029
|
+
className: S("signup-form-fieldset", t),
|
|
6032
6030
|
"data-testid": "signup-form",
|
|
6033
6031
|
children: [
|
|
6034
6032
|
n.title && /* @__PURE__ */ a.jsx("p", { className: "signup-title", children: /* @__PURE__ */ a.jsx(_e, { id: "signup_title" }) }),
|
|
@@ -6085,7 +6083,7 @@ const Ao = {
|
|
|
6085
6083
|
),
|
|
6086
6084
|
/* @__PURE__ */ a.jsx("button", { className: "validation-button", ref: _.hiddenValidation }),
|
|
6087
6085
|
n.logInButton && /* @__PURE__ */ a.jsx(
|
|
6088
|
-
|
|
6086
|
+
ie,
|
|
6089
6087
|
{
|
|
6090
6088
|
className: "login-button",
|
|
6091
6089
|
styling: { fullWidth: !0 },
|
|
@@ -6121,7 +6119,7 @@ const Ml = ({
|
|
|
6121
6119
|
showDivider: !1,
|
|
6122
6120
|
showIcon: o,
|
|
6123
6121
|
functions: { onClose: c },
|
|
6124
|
-
className:
|
|
6122
|
+
className: S("invite-modal", t, { success: !!n }),
|
|
6125
6123
|
children: /* @__PURE__ */ a.jsx(
|
|
6126
6124
|
Po,
|
|
6127
6125
|
{
|
|
@@ -6160,7 +6158,7 @@ const Rl = ({ members: t }) => {
|
|
|
6160
6158
|
isOpen: e !== !1,
|
|
6161
6159
|
children: e === !1 ? "" : /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
6162
6160
|
r(e),
|
|
6163
|
-
/* @__PURE__ */ a.jsx(
|
|
6161
|
+
/* @__PURE__ */ a.jsx(It, { children: e.text })
|
|
6164
6162
|
] }),
|
|
6165
6163
|
buttons: [
|
|
6166
6164
|
{
|
|
@@ -6209,7 +6207,7 @@ const Rl = ({ members: t }) => {
|
|
|
6209
6207
|
return /* @__PURE__ */ a.jsx("p", { className: "details", children: o ? n.formatMessage({ id: "card_bootcamp" }) : sa(u) });
|
|
6210
6208
|
if (c)
|
|
6211
6209
|
return /* @__PURE__ */ a.jsx(
|
|
6212
|
-
|
|
6210
|
+
Lt,
|
|
6213
6211
|
{
|
|
6214
6212
|
variant: c === "free" ? "subtle" : "highlighted",
|
|
6215
6213
|
className: c,
|
|
@@ -6233,7 +6231,7 @@ const Rl = ({ members: t }) => {
|
|
|
6233
6231
|
] });
|
|
6234
6232
|
}
|
|
6235
6233
|
return null;
|
|
6236
|
-
},
|
|
6234
|
+
}, Ht = {
|
|
6237
6235
|
customCard: {
|
|
6238
6236
|
className: "custom",
|
|
6239
6237
|
gtmEvent: "custom",
|
|
@@ -6296,12 +6294,12 @@ const Rl = ({ members: t }) => {
|
|
|
6296
6294
|
loading: !1,
|
|
6297
6295
|
registered: t.registered || !1
|
|
6298
6296
|
});
|
|
6299
|
-
|
|
6297
|
+
ae(() => {
|
|
6300
6298
|
t.registered && o((b) => ({ ...b, registered: !0 }));
|
|
6301
6299
|
}, [t.registered]);
|
|
6302
6300
|
const { startDate: c, dateHasPassed: f, pill: l, slug: u } = t, d = t.contentType;
|
|
6303
6301
|
let m = "";
|
|
6304
|
-
if ((v =
|
|
6302
|
+
if ((v = Ht[d]) != null && v.gtmEvent && (m = Ht[d].gtmEvent), c && f)
|
|
6305
6303
|
return /* @__PURE__ */ a.jsx(
|
|
6306
6304
|
"a",
|
|
6307
6305
|
{
|
|
@@ -6314,7 +6312,7 @@ const Rl = ({ members: t }) => {
|
|
|
6314
6312
|
);
|
|
6315
6313
|
if (d === "people")
|
|
6316
6314
|
return /* @__PURE__ */ a.jsx(
|
|
6317
|
-
|
|
6315
|
+
ie,
|
|
6318
6316
|
{
|
|
6319
6317
|
variant: "tertiary",
|
|
6320
6318
|
size: "small",
|
|
@@ -6339,7 +6337,7 @@ const Rl = ({ members: t }) => {
|
|
|
6339
6337
|
}
|
|
6340
6338
|
};
|
|
6341
6339
|
return /* @__PURE__ */ a.jsx(
|
|
6342
|
-
|
|
6340
|
+
ie,
|
|
6343
6341
|
{
|
|
6344
6342
|
onClick: _,
|
|
6345
6343
|
className: "gtm-trackable",
|
|
@@ -6387,7 +6385,7 @@ const qo = {
|
|
|
6387
6385
|
u(() => ({ data: q, isLoading: !1 }));
|
|
6388
6386
|
}).catch(() => u((q) => ({ ...q, isLoading: !1 })));
|
|
6389
6387
|
}, [t]);
|
|
6390
|
-
if (
|
|
6388
|
+
if (ae(() => {
|
|
6391
6389
|
p();
|
|
6392
6390
|
}, []), m || !d)
|
|
6393
6391
|
return /* @__PURE__ */ a.jsx(
|
|
@@ -6399,41 +6397,41 @@ const qo = {
|
|
|
6399
6397
|
}
|
|
6400
6398
|
);
|
|
6401
6399
|
const { contentType: v } = d;
|
|
6402
|
-
if (!v || !
|
|
6400
|
+
if (!v || !Ht[v])
|
|
6403
6401
|
return /* @__PURE__ */ a.jsx(Te, { element: "li", className: "card-wrapper" });
|
|
6404
6402
|
const {
|
|
6405
6403
|
basePath: b = "",
|
|
6406
6404
|
className: _,
|
|
6407
6405
|
length: g,
|
|
6408
6406
|
gtmEvent: y
|
|
6409
|
-
} =
|
|
6410
|
-
let
|
|
6411
|
-
j && (
|
|
6407
|
+
} = Ht[v], E = oa(`card_label_${v}`) ? o.formatMessage({ id: `card_label_${v}` }) : !1, j = d.slug ? `${b}${d.slug}` : !1, w = { ...qo, ...g };
|
|
6408
|
+
let z = { className: "card" };
|
|
6409
|
+
j && (z = {
|
|
6412
6410
|
href: j,
|
|
6413
6411
|
className: "card gtm-trackable",
|
|
6414
6412
|
"data-gtm-event-context": `${i}-CarouselCard`,
|
|
6415
6413
|
"data-gtm-event-type": `${y}-click`,
|
|
6416
6414
|
"data-testid": "link"
|
|
6417
|
-
}, d.openInNewTab && (
|
|
6418
|
-
const
|
|
6415
|
+
}, d.openInNewTab && (z.target = "_blank"));
|
|
6416
|
+
const F = d.customIcon ? { "--custom-icon": Bo(d.customIcon) } : {};
|
|
6419
6417
|
return /* @__PURE__ */ a.jsx(
|
|
6420
6418
|
"li",
|
|
6421
6419
|
{
|
|
6422
|
-
className:
|
|
6420
|
+
className: S("card-wrapper text-medium", _, s, {
|
|
6423
6421
|
"has-link": j,
|
|
6424
6422
|
"no-link": !j,
|
|
6425
6423
|
"has-custom-icon": d.customIcon,
|
|
6426
6424
|
"has-image": d.banner
|
|
6427
6425
|
}),
|
|
6428
|
-
style:
|
|
6426
|
+
style: F,
|
|
6429
6427
|
"data-testid": `${v}-card`,
|
|
6430
6428
|
children: K.createElement(
|
|
6431
6429
|
j ? "a" : "div",
|
|
6432
|
-
|
|
6430
|
+
z,
|
|
6433
6431
|
/* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
6434
|
-
(d.customLabel || E) && /* @__PURE__ */ a.jsx("small", { className:
|
|
6432
|
+
(d.customLabel || E) && /* @__PURE__ */ a.jsx("small", { className: S("card-label text-small", _), children: d.customLabel || E }),
|
|
6435
6433
|
d.startDate && !d.isOngoingEvent && /* @__PURE__ */ a.jsx(
|
|
6436
|
-
|
|
6434
|
+
Lt,
|
|
6437
6435
|
{
|
|
6438
6436
|
size: "small",
|
|
6439
6437
|
variant: d.dateHasPassed ? "default" : "information",
|
|
@@ -6442,8 +6440,8 @@ const qo = {
|
|
|
6442
6440
|
}
|
|
6443
6441
|
),
|
|
6444
6442
|
d.banner ? /* @__PURE__ */ a.jsxs("p", { className: "img", children: [
|
|
6445
|
-
d.registered && /* @__PURE__ */ a.jsx(
|
|
6446
|
-
/* @__PURE__ */ a.jsx(
|
|
6443
|
+
d.registered && /* @__PURE__ */ a.jsx(Lt, { size: "small", variant: "registered", children: o.formatMessage({ id: "card_registered" }) }),
|
|
6444
|
+
/* @__PURE__ */ a.jsx(_t, { image: d.banner })
|
|
6447
6445
|
] }) : _ === "people" ? /* @__PURE__ */ a.jsx(
|
|
6448
6446
|
ze,
|
|
6449
6447
|
{
|
|
@@ -6480,7 +6478,7 @@ const qo = {
|
|
|
6480
6478
|
}
|
|
6481
6479
|
);
|
|
6482
6480
|
};
|
|
6483
|
-
const Uo = ({ cards: t, cardTypes: e, className: n = "", ...r }) => /* @__PURE__ */ a.jsx("ul", { className:
|
|
6481
|
+
const Uo = ({ cards: t, cardTypes: e, className: n = "", ...r }) => /* @__PURE__ */ a.jsx("ul", { className: S("card-block", n), children: t.map((i, s) => {
|
|
6484
6482
|
const o = i.slug ? `${i.slug}-${e[s]}` : `${e[s]}-${s}`;
|
|
6485
6483
|
return /* @__PURE__ */ a.jsx(
|
|
6486
6484
|
Ma,
|
|
@@ -6500,7 +6498,7 @@ const Uo = ({ cards: t, cardTypes: e, className: n = "", ...r }) => /* @__PURE__
|
|
|
6500
6498
|
return null;
|
|
6501
6499
|
const { text: r, element: i = "h2", variant: s = "default", size: o = "medium", link: c } = e;
|
|
6502
6500
|
return K.createElement(i, {
|
|
6503
|
-
className:
|
|
6501
|
+
className: S("title", s, o, {
|
|
6504
6502
|
"highlighted-title": s === "highlighted"
|
|
6505
6503
|
}),
|
|
6506
6504
|
children: /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
@@ -6523,7 +6521,7 @@ const yn = {
|
|
|
6523
6521
|
threeCards: 769,
|
|
6524
6522
|
twoCards: 480
|
|
6525
6523
|
};
|
|
6526
|
-
let
|
|
6524
|
+
let $t = null;
|
|
6527
6525
|
const Wo = ({
|
|
6528
6526
|
id: t,
|
|
6529
6527
|
cards: e,
|
|
@@ -6540,7 +6538,7 @@ const Wo = ({
|
|
|
6540
6538
|
currentPage: 0,
|
|
6541
6539
|
loadedPages: [0]
|
|
6542
6540
|
}), { currentPage: v, loadedPages: b } = m, _ = e.length, g = Math.ceil(_ / u), y = pe(null), E = bt(!0, !0, y == null ? void 0 : y.current);
|
|
6543
|
-
|
|
6541
|
+
ae(() => {
|
|
6544
6542
|
let M = 1;
|
|
6545
6543
|
E && (E >= yn.fourCards ? M = 4 : E >= yn.threeCards ? M = 3 : E >= yn.twoCards && (M = 2), M > _ && (M = _)), l((O) => ({
|
|
6546
6544
|
...O,
|
|
@@ -6562,19 +6560,19 @@ const Wo = ({
|
|
|
6562
6560
|
return;
|
|
6563
6561
|
else
|
|
6564
6562
|
O = M;
|
|
6565
|
-
p((
|
|
6566
|
-
...
|
|
6563
|
+
p((C) => ({
|
|
6564
|
+
...C,
|
|
6567
6565
|
currentPage: O,
|
|
6568
6566
|
loadedPages: [.../* @__PURE__ */ new Set([...b, O])]
|
|
6569
6567
|
}));
|
|
6570
6568
|
}, w = (M) => {
|
|
6571
|
-
|
|
6572
|
-
},
|
|
6573
|
-
if (
|
|
6569
|
+
$t = M.touches[0].clientX;
|
|
6570
|
+
}, z = (M) => {
|
|
6571
|
+
if ($t === null)
|
|
6574
6572
|
return;
|
|
6575
|
-
const O = M.touches[0].clientX,
|
|
6576
|
-
|
|
6577
|
-
},
|
|
6573
|
+
const O = M.touches[0].clientX, C = $t - O;
|
|
6574
|
+
C > 5 ? j("next") : C < -5 && j("previous"), $t = null;
|
|
6575
|
+
}, F = {
|
|
6578
6576
|
"--width": `${E || 0}px`,
|
|
6579
6577
|
"--total-cards": _,
|
|
6580
6578
|
"--cards-per-page": u,
|
|
@@ -6584,14 +6582,14 @@ const Wo = ({
|
|
|
6584
6582
|
return /* @__PURE__ */ a.jsx(fa, { layout: `carousel${i ? "-with-title" : ""}` });
|
|
6585
6583
|
const q = (M, O) => {
|
|
6586
6584
|
var T;
|
|
6587
|
-
let
|
|
6588
|
-
return (T = M == null ? void 0 : M.sys) != null && T.id ?
|
|
6585
|
+
let C = null;
|
|
6586
|
+
return (T = M == null ? void 0 : M.sys) != null && T.id ? C = `card-${M.sys.id}` : M != null && M.slug ? C = `card-${M.slug}` : [n[O], M.contentType].includes("customCard") && (C = `card-${window.btoa(`${M.title} ${M.createdAt}`)}-${O}`), C;
|
|
6589
6587
|
};
|
|
6590
6588
|
return /* @__PURE__ */ a.jsxs(
|
|
6591
6589
|
"section",
|
|
6592
6590
|
{
|
|
6593
6591
|
ref: y,
|
|
6594
|
-
className:
|
|
6592
|
+
className: S("carousel-wrapper", s),
|
|
6595
6593
|
"data-testid": "carousel",
|
|
6596
6594
|
children: [
|
|
6597
6595
|
/* @__PURE__ */ a.jsx(Zo, { id: t, title: i }),
|
|
@@ -6600,35 +6598,35 @@ const Wo = ({
|
|
|
6600
6598
|
{
|
|
6601
6599
|
className: "carousel",
|
|
6602
6600
|
onTouchStart: w,
|
|
6603
|
-
onTouchMove:
|
|
6604
|
-
style:
|
|
6601
|
+
onTouchMove: z,
|
|
6602
|
+
style: F,
|
|
6605
6603
|
"data-testid": "carousel-list",
|
|
6606
6604
|
children: e.map((M, O) => {
|
|
6607
|
-
let
|
|
6608
|
-
return
|
|
6605
|
+
let C = q(M, O);
|
|
6606
|
+
return C && zo(O, u, v, b) ? /* @__PURE__ */ a.jsx(
|
|
6609
6607
|
Ma,
|
|
6610
6608
|
{
|
|
6611
|
-
id:
|
|
6609
|
+
id: C,
|
|
6612
6610
|
card: { ...M, contentType: n[O] },
|
|
6613
6611
|
buildCardData: r,
|
|
6614
6612
|
gtmContext: o
|
|
6615
6613
|
},
|
|
6616
|
-
|
|
6617
|
-
) : (
|
|
6614
|
+
C
|
|
6615
|
+
) : (C = C || `${t}-card-${O}`, /* @__PURE__ */ a.jsx(
|
|
6618
6616
|
Te,
|
|
6619
6617
|
{
|
|
6620
6618
|
element: "li",
|
|
6621
6619
|
className: "card-wrapper",
|
|
6622
6620
|
"data-testid": "card-placeholder"
|
|
6623
6621
|
},
|
|
6624
|
-
|
|
6622
|
+
C
|
|
6625
6623
|
));
|
|
6626
6624
|
})
|
|
6627
6625
|
}
|
|
6628
6626
|
),
|
|
6629
6627
|
g <= 1 ? null : /* @__PURE__ */ a.jsxs("ul", { className: "controls", "data-testid": "carousel-controls", children: [
|
|
6630
6628
|
/* @__PURE__ */ a.jsx("li", { className: "arrow previous", children: /* @__PURE__ */ a.jsx(
|
|
6631
|
-
|
|
6629
|
+
ie,
|
|
6632
6630
|
{
|
|
6633
6631
|
variant: "secondary",
|
|
6634
6632
|
size: "large",
|
|
@@ -6645,11 +6643,11 @@ const Wo = ({
|
|
|
6645
6643
|
[...Array(g)].map((M, O) => /* @__PURE__ */ a.jsx("li", { "data-testid": "carousel-controls-button", children: /* @__PURE__ */ a.jsx(
|
|
6646
6644
|
"button",
|
|
6647
6645
|
{
|
|
6648
|
-
className:
|
|
6646
|
+
className: S("page-indicator", {
|
|
6649
6647
|
selected: O === v
|
|
6650
6648
|
}),
|
|
6651
|
-
onClick: (
|
|
6652
|
-
|
|
6649
|
+
onClick: (C) => {
|
|
6650
|
+
C.preventDefault(), C.stopPropagation(), j(O);
|
|
6653
6651
|
},
|
|
6654
6652
|
children: /* @__PURE__ */ a.jsx(be, { showOnFocus: !1, children: c.formatMessage(
|
|
6655
6653
|
{ id: "carousel_pagination_page" },
|
|
@@ -6658,7 +6656,7 @@ const Wo = ({
|
|
|
6658
6656
|
}
|
|
6659
6657
|
) }, `page-indicator-${O}`)),
|
|
6660
6658
|
/* @__PURE__ */ a.jsx("li", { className: "arrow next", children: /* @__PURE__ */ a.jsx(
|
|
6661
|
-
|
|
6659
|
+
ie,
|
|
6662
6660
|
{
|
|
6663
6661
|
variant: "secondary",
|
|
6664
6662
|
size: "large",
|
|
@@ -6714,12 +6712,12 @@ const _n = "joinCommunityButton", Ra = ({
|
|
|
6714
6712
|
} }
|
|
6715
6713
|
}) => {
|
|
6716
6714
|
const i = G(), s = Ce(Oe), o = s && typeof s.id == "string", [c, f] = te(t), [l, u] = te(t ? "joined" : "notJoined");
|
|
6717
|
-
|
|
6715
|
+
ae(() => {
|
|
6718
6716
|
l === "joining" ? u("joined") : l === "leaving" && u("notJoined");
|
|
6719
6717
|
}, [c]);
|
|
6720
6718
|
const d = {}, m = {};
|
|
6721
6719
|
return c && l !== "leaving" && (d["data-hover-text"] = i.formatMessage({ id: `${_n}_leave` }), d["aria-label"] = i.formatMessage({ id: `${_n}_member_aria` }), m["aria-hidden"] = "true"), /* @__PURE__ */ a.jsx(
|
|
6722
|
-
|
|
6720
|
+
ie,
|
|
6723
6721
|
{
|
|
6724
6722
|
variant: c ? "secondary" : "primary",
|
|
6725
6723
|
size: "medium",
|
|
@@ -6728,7 +6726,7 @@ const _n = "joinCommunityButton", Ra = ({
|
|
|
6728
6726
|
onClick: async (p) => {
|
|
6729
6727
|
o && (p.currentTarget.blur(), c ? (u("leaving"), typeof r == "function" && await r()) : (u("joining"), typeof n == "function" && await n()), f(!c));
|
|
6730
6728
|
},
|
|
6731
|
-
className:
|
|
6729
|
+
className: S("join-community-button", l, {
|
|
6732
6730
|
active: l === "joining"
|
|
6733
6731
|
}),
|
|
6734
6732
|
disabled: !o,
|
|
@@ -6747,7 +6745,7 @@ const xn = "communityDetails_", Ol = ({
|
|
|
6747
6745
|
functions: { invite: s, ...o }
|
|
6748
6746
|
}) => {
|
|
6749
6747
|
const c = G(), f = 5, l = r || i.length, u = i.length ? i : Array(f).fill({}), d = `/communities/${n}/members` === window.location.pathname;
|
|
6750
|
-
return /* @__PURE__ */ a.jsxs("div", { className:
|
|
6748
|
+
return /* @__PURE__ */ a.jsxs("div", { className: S("community-details", t), children: [
|
|
6751
6749
|
/* @__PURE__ */ a.jsx(Re, {}),
|
|
6752
6750
|
/* @__PURE__ */ a.jsxs("div", { className: "member-details", children: [
|
|
6753
6751
|
/* @__PURE__ */ a.jsxs("div", { className: "top", children: [
|
|
@@ -6775,7 +6773,7 @@ const xn = "communityDetails_", Ol = ({
|
|
|
6775
6773
|
] }),
|
|
6776
6774
|
/* @__PURE__ */ a.jsx(Ra, { isMember: e, functions: { ...o } }),
|
|
6777
6775
|
e && /* @__PURE__ */ a.jsx(
|
|
6778
|
-
|
|
6776
|
+
ie,
|
|
6779
6777
|
{
|
|
6780
6778
|
variant: "primary",
|
|
6781
6779
|
onClick: s,
|
|
@@ -6796,7 +6794,7 @@ const Dl = ({ breadcrumbs: t, cutoff: e = 20, className: n = "" }) => {
|
|
|
6796
6794
|
children: r.formatMessage({ id: "breadcrumbs_label" })
|
|
6797
6795
|
}
|
|
6798
6796
|
),
|
|
6799
|
-
/* @__PURE__ */ a.jsx("ul", { className:
|
|
6797
|
+
/* @__PURE__ */ a.jsx("ul", { className: S("breadcrumbs text-small", n), children: t.map(
|
|
6800
6798
|
({ text: i, href: s, current: o = !1 }, c) => /* @__PURE__ */ a.jsxs("li", { children: [
|
|
6801
6799
|
o && /* @__PURE__ */ a.jsx(
|
|
6802
6800
|
be,
|
|
@@ -6805,7 +6803,7 @@ const Dl = ({ breadcrumbs: t, cutoff: e = 20, className: n = "" }) => {
|
|
|
6805
6803
|
children: r.formatMessage({ id: "breadcrumbs_currentPage" })
|
|
6806
6804
|
}
|
|
6807
6805
|
),
|
|
6808
|
-
/* @__PURE__ */ a.jsx(
|
|
6806
|
+
/* @__PURE__ */ a.jsx(xt, { href: o ? void 0 : s, children: Ke(i, e) })
|
|
6809
6807
|
] }, `${window.btoa(i)}_${c}`)
|
|
6810
6808
|
) })
|
|
6811
6809
|
] });
|
|
@@ -6828,7 +6826,7 @@ const Al = ({
|
|
|
6828
6826
|
let m = [];
|
|
6829
6827
|
c.includes(u) ? m = c.filter((p) => p !== u) : u === "all" ? m = ["all"] : n ? m = [...c.filter((p) => p !== "all"), u] : m = [u], f((p) => (r && typeof r == "function" && r({ current: m, previous: p }), m)), d && typeof d == "function" && d();
|
|
6830
6828
|
};
|
|
6831
|
-
return /* @__PURE__ */ a.jsx("ul", { className:
|
|
6829
|
+
return /* @__PURE__ */ a.jsx("ul", { className: S("filters", i), children: o.map(({ id: u, text: d, disabled: m = !1, callback: p = () => {
|
|
6832
6830
|
} }) => {
|
|
6833
6831
|
let v = {};
|
|
6834
6832
|
return m && (v = {
|
|
@@ -6837,7 +6835,7 @@ const Al = ({
|
|
|
6837
6835
|
}), /* @__PURE__ */ a.jsx("li", { children: /* @__PURE__ */ a.jsx(
|
|
6838
6836
|
"button",
|
|
6839
6837
|
{
|
|
6840
|
-
className:
|
|
6838
|
+
className: S(u, { selected: c.includes(u) }),
|
|
6841
6839
|
onClick: (b) => {
|
|
6842
6840
|
b.preventDefault(), b.stopPropagation(), l(u, p);
|
|
6843
6841
|
},
|
|
@@ -6860,7 +6858,7 @@ const wn = {
|
|
|
6860
6858
|
es: "Español",
|
|
6861
6859
|
fr: "Français",
|
|
6862
6860
|
pt: "Português"
|
|
6863
|
-
},
|
|
6861
|
+
}, Nt = "languageSwitcher_", Il = ({
|
|
6864
6862
|
currentLanguage: t,
|
|
6865
6863
|
isOriginalLanguage: e = !1,
|
|
6866
6864
|
isHumanTranslation: n = !1,
|
|
@@ -6873,22 +6871,22 @@ const wn = {
|
|
|
6873
6871
|
className: f = ""
|
|
6874
6872
|
}) => {
|
|
6875
6873
|
const l = G(), [u, d] = te(t);
|
|
6876
|
-
if (
|
|
6874
|
+
if (ae(() => {
|
|
6877
6875
|
t !== u && d(t);
|
|
6878
6876
|
}, [t]), !r || !Object.values(r).some(
|
|
6879
6877
|
(b) => b && b.post_name
|
|
6880
6878
|
))
|
|
6881
6879
|
return null;
|
|
6882
6880
|
const p = Object.keys(r), v = u !== t;
|
|
6883
|
-
return /* @__PURE__ */ a.jsxs("div", { className:
|
|
6881
|
+
return /* @__PURE__ */ a.jsxs("div", { className: S("language-switcher text-small", o, f), children: [
|
|
6884
6882
|
/* @__PURE__ */ a.jsxs("nav", { children: [
|
|
6885
|
-
o !== "short" && /* @__PURE__ */ a.jsx("p", { children: c || l.formatMessage({ id: `${
|
|
6883
|
+
o !== "short" && /* @__PURE__ */ a.jsx("p", { children: c || l.formatMessage({ id: `${Nt}label` }) }),
|
|
6886
6884
|
/* @__PURE__ */ a.jsx("ul", { children: p.map((b) => {
|
|
6887
6885
|
if (!wn[b])
|
|
6888
6886
|
return null;
|
|
6889
6887
|
let _ = { className: b };
|
|
6890
6888
|
return u === b ? _["aria-label"] = l.formatMessage(
|
|
6891
|
-
{ id: `${
|
|
6889
|
+
{ id: `${Nt}selected` },
|
|
6892
6890
|
{ language: wn[b] }
|
|
6893
6891
|
) : _ = {
|
|
6894
6892
|
..._,
|
|
@@ -6896,10 +6894,10 @@ const wn = {
|
|
|
6896
6894
|
onClick: (g) => {
|
|
6897
6895
|
g.preventDefault(), g.stopPropagation(), d(b), i(b);
|
|
6898
6896
|
}
|
|
6899
|
-
}, /* @__PURE__ */ a.jsx("li", { children: /* @__PURE__ */ a.jsx(
|
|
6897
|
+
}, /* @__PURE__ */ a.jsx("li", { children: /* @__PURE__ */ a.jsx(xt, { ..._, fallbackElement: "span", children: wn[b] }) }, b);
|
|
6900
6898
|
}) }),
|
|
6901
6899
|
o !== "short" && !v && /* @__PURE__ */ a.jsx("p", { children: l.formatMessage({
|
|
6902
|
-
id: `${
|
|
6900
|
+
id: `${Nt}translation_${e ? "original" : n ? "human" : "machine"}`
|
|
6903
6901
|
}) })
|
|
6904
6902
|
] }),
|
|
6905
6903
|
o !== "short" && !v && !e && !n && /* @__PURE__ */ a.jsx("small", {
|
|
@@ -6907,7 +6905,7 @@ const wn = {
|
|
|
6907
6905
|
// @ts-ignore
|
|
6908
6906
|
// `values` are throwing a type error: https://github.com/formatjs/formatjs/issues/3633
|
|
6909
6907
|
children: l.formatMessage(
|
|
6910
|
-
{ id: `${
|
|
6908
|
+
{ id: `${Nt}disclaimer` },
|
|
6911
6909
|
{
|
|
6912
6910
|
email: lt.support,
|
|
6913
6911
|
link: (b) => {
|
|
@@ -6942,8 +6940,8 @@ const kn = pi({ locale: "en", messages: Hn }), en = ({
|
|
|
6942
6940
|
p instanceof Error ? u(p.message) : u("Unknown error");
|
|
6943
6941
|
}
|
|
6944
6942
|
};
|
|
6945
|
-
return !l && !t && !o.endOfFeed ? null : /* @__PURE__ */ a.jsx("footer", { className:
|
|
6946
|
-
|
|
6943
|
+
return !l && !t && !o.endOfFeed ? null : /* @__PURE__ */ a.jsx("footer", { className: S("load-more", c), children: !l && t ? /* @__PURE__ */ a.jsx(
|
|
6944
|
+
ie,
|
|
6947
6945
|
{
|
|
6948
6946
|
variant: n,
|
|
6949
6947
|
size: r,
|
|
@@ -6967,12 +6965,12 @@ const Fa = ({
|
|
|
6967
6965
|
"a",
|
|
6968
6966
|
{
|
|
6969
6967
|
href: "/home/",
|
|
6970
|
-
className:
|
|
6968
|
+
className: S("logo", t, e, n),
|
|
6971
6969
|
...r,
|
|
6972
6970
|
children: /* @__PURE__ */ a.jsx(be, { children: /* @__PURE__ */ a.jsx(_e, { id: "apolitical" }) })
|
|
6973
6971
|
}
|
|
6974
6972
|
) });
|
|
6975
|
-
let
|
|
6973
|
+
let Pt = !1;
|
|
6976
6974
|
const Vo = ({
|
|
6977
6975
|
element: t = "div",
|
|
6978
6976
|
id: e = "more-menu",
|
|
@@ -6984,14 +6982,14 @@ const Vo = ({
|
|
|
6984
6982
|
), [o, c] = te(!1), f = (l) => {
|
|
6985
6983
|
s.current && l.target instanceof HTMLElement && !s.current.contains(l.target) && c(!1);
|
|
6986
6984
|
};
|
|
6987
|
-
return
|
|
6985
|
+
return ae(() => (document.addEventListener("click", f, !0), () => {
|
|
6988
6986
|
document.removeEventListener("click", f, !0);
|
|
6989
6987
|
})), K.createElement(t, {
|
|
6990
6988
|
ref: s,
|
|
6991
|
-
className:
|
|
6989
|
+
className: S("more-menu text-medium", r),
|
|
6992
6990
|
children: /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
6993
6991
|
/* @__PURE__ */ a.jsx(
|
|
6994
|
-
|
|
6992
|
+
ie,
|
|
6995
6993
|
{
|
|
6996
6994
|
variant: "tertiary",
|
|
6997
6995
|
size: "medium",
|
|
@@ -7010,16 +7008,16 @@ const Vo = ({
|
|
|
7010
7008
|
c(!1), typeof u == "function" && u(_);
|
|
7011
7009
|
},
|
|
7012
7010
|
onFocus: () => {
|
|
7013
|
-
|
|
7011
|
+
Pt && (clearTimeout(Pt), Pt = !1);
|
|
7014
7012
|
},
|
|
7015
7013
|
onBlur: () => {
|
|
7016
|
-
|
|
7014
|
+
Pt = setTimeout(() => {
|
|
7017
7015
|
c(!1);
|
|
7018
7016
|
}, 100);
|
|
7019
7017
|
}
|
|
7020
7018
|
};
|
|
7021
7019
|
return l && (b.href = l), /* @__PURE__ */ a.jsx("li", { children: /* @__PURE__ */ a.jsx(
|
|
7022
|
-
|
|
7020
|
+
ie,
|
|
7023
7021
|
{
|
|
7024
7022
|
variant: "tertiary",
|
|
7025
7023
|
size: "medium",
|
|
@@ -7055,7 +7053,7 @@ const Ko = [
|
|
|
7055
7053
|
Ko.map(({ key: i, href: s }) => /* @__PURE__ */ a.jsx(
|
|
7056
7054
|
"li",
|
|
7057
7055
|
{
|
|
7058
|
-
className:
|
|
7056
|
+
className: S(i, { active: Yo(s, t) }),
|
|
7059
7057
|
children: /* @__PURE__ */ a.jsx(
|
|
7060
7058
|
"a",
|
|
7061
7059
|
{
|
|
@@ -7142,14 +7140,14 @@ const Jo = "shareLinks_", Ll = ({
|
|
|
7142
7140
|
className: o = ""
|
|
7143
7141
|
}) => {
|
|
7144
7142
|
const c = G(), f = Qo({ title: t, link: e, referrer: n });
|
|
7145
|
-
return /* @__PURE__ */ a.jsxs("aside", { className:
|
|
7143
|
+
return /* @__PURE__ */ a.jsxs("aside", { className: S("share-links", i, s, o), children: [
|
|
7146
7144
|
/* @__PURE__ */ a.jsx("p", { className: "text-small", children: c.formatMessage({ id: "shareLinks_label" }) }),
|
|
7147
7145
|
/* @__PURE__ */ a.jsx("ul", { children: f.map(({ key: l, icon: u, url: d, shouldRender: m = !0, onClick: p }) => {
|
|
7148
7146
|
if (typeof m == "function" && !m())
|
|
7149
7147
|
return null;
|
|
7150
7148
|
const v = {};
|
|
7151
7149
|
return p && (v.onClick = (b) => p(b, d)), /* @__PURE__ */ a.jsx("li", { children: /* @__PURE__ */ a.jsx(
|
|
7152
|
-
|
|
7150
|
+
ie,
|
|
7153
7151
|
{
|
|
7154
7152
|
size: i,
|
|
7155
7153
|
variant: "tertiary",
|
|
@@ -7185,7 +7183,7 @@ const Bl = ({ tabs: t, className: e = "" }) => {
|
|
|
7185
7183
|
const [i, s] = te(
|
|
7186
7184
|
(f = t[r]) != null && f.id ? t[r].id : n(t[r].id, t[r].text, r)
|
|
7187
7185
|
);
|
|
7188
|
-
|
|
7186
|
+
ae(() => {
|
|
7189
7187
|
if (t[r].hasCarousel) {
|
|
7190
7188
|
const l = new CustomEvent("hiddenSectionVisible", {
|
|
7191
7189
|
detail: { id: i }
|
|
@@ -7218,7 +7216,7 @@ const Bl = ({ tabs: t, className: e = "" }) => {
|
|
|
7218
7216
|
{
|
|
7219
7217
|
href: m || `#${l}`,
|
|
7220
7218
|
id: `tab-${l}`,
|
|
7221
|
-
className:
|
|
7219
|
+
className: S({ selected: b }),
|
|
7222
7220
|
role: "tab",
|
|
7223
7221
|
"aria-selected": b,
|
|
7224
7222
|
..._,
|
|
@@ -7226,7 +7224,7 @@ const Bl = ({ tabs: t, className: e = "" }) => {
|
|
|
7226
7224
|
}
|
|
7227
7225
|
) }, `tab-${l}`)
|
|
7228
7226
|
);
|
|
7229
|
-
}), /* @__PURE__ */ a.jsxs("div", { className:
|
|
7227
|
+
}), /* @__PURE__ */ a.jsxs("div", { className: S("tabs-wrapper", e), children: [
|
|
7230
7228
|
/* @__PURE__ */ a.jsx("ul", { className: "tabs", role: "tablist", children: o }),
|
|
7231
7229
|
/* @__PURE__ */ a.jsx("div", { className: "tab-content", children: c })
|
|
7232
7230
|
] });
|
|
@@ -7243,7 +7241,7 @@ const Xo = {
|
|
|
7243
7241
|
}) => {
|
|
7244
7242
|
const i = bt(!0);
|
|
7245
7243
|
let s = r;
|
|
7246
|
-
return K.Children.count(r) === 1 && (s = K.Children.toArray(r)[0], s.props && (s = s.props.children)), /* @__PURE__ */ a.jsx("section", { className:
|
|
7244
|
+
return K.Children.count(r) === 1 && (s = K.Children.toArray(r)[0], s.props && (s = s.props.children)), /* @__PURE__ */ a.jsx("section", { className: S("columns", `layout-${t}`, n), children: K.Children.map(s, (o, c) => e !== !1 && c === e && i && i < Xo[t] ? null : o) });
|
|
7247
7245
|
};
|
|
7248
7246
|
let jn;
|
|
7249
7247
|
const Tn = "contactFooter_", ql = ({ onSuccess: t = async () => {
|
|
@@ -7256,7 +7254,7 @@ const Tn = "contactFooter_", ql = ({ onSuccess: t = async () => {
|
|
|
7256
7254
|
c(), o(!1);
|
|
7257
7255
|
}, 500));
|
|
7258
7256
|
};
|
|
7259
|
-
return
|
|
7257
|
+
return ae(() => (c(), window.addEventListener("resize", f), () => {
|
|
7260
7258
|
clearTimeout(jn), window.removeEventListener("resize", f);
|
|
7261
7259
|
}), []), /* @__PURE__ */ a.jsx(et, { id: "contactForm", className: "contact-footer", children: /* @__PURE__ */ a.jsxs("div", { className: "inner-wrapper", children: [
|
|
7262
7260
|
/* @__PURE__ */ a.jsx("h2", { children: /* @__PURE__ */ a.jsx(_e, { id: `${Tn}title` }) }),
|
|
@@ -7270,7 +7268,7 @@ const Tn = "contactFooter_", ql = ({ onSuccess: t = async () => {
|
|
|
7270
7268
|
children: [
|
|
7271
7269
|
/* @__PURE__ */ a.jsxs("aside", { children: [
|
|
7272
7270
|
/* @__PURE__ */ a.jsx("p", { children: /* @__PURE__ */ a.jsx(_e, { id: `${Tn}text` }) }),
|
|
7273
|
-
/* @__PURE__ */ a.jsx(
|
|
7271
|
+
/* @__PURE__ */ a.jsx(xt, { className: "mailto-link", href: "mailto:hello@apolitical.co", children: /* @__PURE__ */ a.jsx(_e, { id: `${Tn}email` }) })
|
|
7274
7272
|
] }),
|
|
7275
7273
|
/* @__PURE__ */ a.jsx(
|
|
7276
7274
|
No,
|
|
@@ -7337,7 +7335,7 @@ const En = "cookieBanner_", Sn = [
|
|
|
7337
7335
|
}), /* @__PURE__ */ a.jsxs("aside", { id: "cookie-banner", className: "text-medium", children: [
|
|
7338
7336
|
/* @__PURE__ */ a.jsx("h6", { children: t.formatMessage({ id: `${En}title` }) }),
|
|
7339
7337
|
/* @__PURE__ */ a.jsx("p", { children: t.formatMessage({ id: `${En}text` }) }),
|
|
7340
|
-
/* @__PURE__ */ a.jsx(
|
|
7338
|
+
/* @__PURE__ */ a.jsx(yt, { buttons: l })
|
|
7341
7339
|
] });
|
|
7342
7340
|
}, Me = {
|
|
7343
7341
|
platform: {
|
|
@@ -7432,7 +7430,7 @@ const En = "cookieBanner_", Sn = [
|
|
|
7432
7430
|
facebook: { href: "https://www.facebook.com/apoliticalco" }
|
|
7433
7431
|
}
|
|
7434
7432
|
};
|
|
7435
|
-
const Ye = "footer_",
|
|
7433
|
+
const Ye = "footer_", Vt = "SiteFooter", Lr = ({ group: t }) => {
|
|
7436
7434
|
const e = Me[t].order || [];
|
|
7437
7435
|
let n = !1;
|
|
7438
7436
|
return "text" in Me[t] && (n = Me[t].text), /* @__PURE__ */ a.jsxs(ht, { children: [
|
|
@@ -7446,7 +7444,7 @@ const Ye = "footer_", Ht = "SiteFooter", Lr = ({ group: t }) => {
|
|
|
7446
7444
|
{
|
|
7447
7445
|
href: i,
|
|
7448
7446
|
className: "gtm-trackable",
|
|
7449
|
-
"data-gtm-event-context":
|
|
7447
|
+
"data-gtm-event-context": Vt,
|
|
7450
7448
|
"data-gtm-event-type": s,
|
|
7451
7449
|
...o,
|
|
7452
7450
|
children: /* @__PURE__ */ a.jsx(_e, { id: `${Ye}${t}_${r}` })
|
|
@@ -7468,7 +7466,7 @@ const Ye = "footer_", Ht = "SiteFooter", Lr = ({ group: t }) => {
|
|
|
7468
7466
|
{
|
|
7469
7467
|
href: `mailto:${n[r].email}`,
|
|
7470
7468
|
className: "gtm-trackable",
|
|
7471
|
-
"data-gtm-event-context":
|
|
7469
|
+
"data-gtm-event-context": Vt,
|
|
7472
7470
|
"data-gtm-event-type": n[r].gtmType,
|
|
7473
7471
|
children: n[r].email
|
|
7474
7472
|
}
|
|
@@ -7484,7 +7482,7 @@ const Ye = "footer_", Ht = "SiteFooter", Lr = ({ group: t }) => {
|
|
|
7484
7482
|
variant: "inverted",
|
|
7485
7483
|
version: "full",
|
|
7486
7484
|
className: "gtm-trackable",
|
|
7487
|
-
"data-gtm-event-context":
|
|
7485
|
+
"data-gtm-event-context": Vt,
|
|
7488
7486
|
"data-gtm-event-type": "logo-homepage-link"
|
|
7489
7487
|
}
|
|
7490
7488
|
),
|
|
@@ -7503,7 +7501,7 @@ const Ye = "footer_", Ht = "SiteFooter", Lr = ({ group: t }) => {
|
|
|
7503
7501
|
target: "_blank",
|
|
7504
7502
|
rel: "noopener noreferrer",
|
|
7505
7503
|
className: "gtm-trackable",
|
|
7506
|
-
"data-gtm-event-context":
|
|
7504
|
+
"data-gtm-event-context": Vt,
|
|
7507
7505
|
"data-gtm-event-type": "social-click",
|
|
7508
7506
|
children: /* @__PURE__ */ a.jsx("span", { className: "hidden", children: /* @__PURE__ */ a.jsx(_e, { id: `${Ye}social_${t}` }) })
|
|
7509
7507
|
}
|
|
@@ -7621,7 +7619,7 @@ const Ye = "footer_", Ht = "SiteFooter", Lr = ({ group: t }) => {
|
|
|
7621
7619
|
}, 250);
|
|
7622
7620
|
}
|
|
7623
7621
|
}
|
|
7624
|
-
},
|
|
7622
|
+
}, Yt = {
|
|
7625
7623
|
order: ["home", "topics", "partners", "account"],
|
|
7626
7624
|
home: {
|
|
7627
7625
|
href: "/home/",
|
|
@@ -7696,7 +7694,7 @@ const Ye = "footer_", Ht = "SiteFooter", Lr = ({ group: t }) => {
|
|
|
7696
7694
|
props: { variant: "primary" }
|
|
7697
7695
|
}
|
|
7698
7696
|
}
|
|
7699
|
-
},
|
|
7697
|
+
}, Kt = ({
|
|
7700
7698
|
id: t,
|
|
7701
7699
|
isLoggedIn: e = !1,
|
|
7702
7700
|
isDesktopVersion: n = !1,
|
|
@@ -7705,7 +7703,7 @@ const Ye = "footer_", Ht = "SiteFooter", Lr = ({ group: t }) => {
|
|
|
7705
7703
|
},
|
|
7706
7704
|
doTrack: s = null
|
|
7707
7705
|
}) => {
|
|
7708
|
-
const o = G(), c = Jr(
|
|
7706
|
+
const o = G(), c = Jr(Yt, t);
|
|
7709
7707
|
if (!c || c.onlyShow && (c.onlyShow === "logged-in" && !e || c.onlyShow === "logged-out" && e))
|
|
7710
7708
|
return null;
|
|
7711
7709
|
const f = "doTrack" in c, l = s === null ? f ? c.doTrack : !0 : s, u = t.includes("buttons.");
|
|
@@ -7761,7 +7759,7 @@ const Ye = "footer_", Ht = "SiteFooter", Lr = ({ group: t }) => {
|
|
|
7761
7759
|
return /* @__PURE__ */ a.jsxs(
|
|
7762
7760
|
"li",
|
|
7763
7761
|
{
|
|
7764
|
-
className:
|
|
7762
|
+
className: S({
|
|
7765
7763
|
[c.className]: c.className,
|
|
7766
7764
|
"has-submenu": p,
|
|
7767
7765
|
parent: v,
|
|
@@ -7771,7 +7769,7 @@ const Ye = "footer_", Ht = "SiteFooter", Lr = ({ group: t }) => {
|
|
|
7771
7769
|
..._,
|
|
7772
7770
|
children: [
|
|
7773
7771
|
m ? K.createElement(
|
|
7774
|
-
u ?
|
|
7772
|
+
u ? ie : "a",
|
|
7775
7773
|
m,
|
|
7776
7774
|
o.formatMessage({ id: d })
|
|
7777
7775
|
) : o.formatMessage({ id: d }),
|
|
@@ -7788,13 +7786,13 @@ const Ye = "footer_", Ht = "SiteFooter", Lr = ({ group: t }) => {
|
|
|
7788
7786
|
return c[y].order ? /* @__PURE__ */ a.jsxs(
|
|
7789
7787
|
"li",
|
|
7790
7788
|
{
|
|
7791
|
-
className:
|
|
7789
|
+
className: S({
|
|
7792
7790
|
[c[y].className]: c[y].className
|
|
7793
7791
|
}),
|
|
7794
7792
|
children: [
|
|
7795
7793
|
o.formatMessage({ id: `${d}_${y}` }),
|
|
7796
7794
|
/* @__PURE__ */ a.jsx("ul", { children: c[y].order.map((j) => /* @__PURE__ */ a.jsx(
|
|
7797
|
-
|
|
7795
|
+
Kt,
|
|
7798
7796
|
{
|
|
7799
7797
|
id: `${t}.${y}.${j}`,
|
|
7800
7798
|
...E
|
|
@@ -7805,7 +7803,7 @@ const Ye = "footer_", Ht = "SiteFooter", Lr = ({ group: t }) => {
|
|
|
7805
7803
|
},
|
|
7806
7804
|
y
|
|
7807
7805
|
) : /* @__PURE__ */ a.jsx(
|
|
7808
|
-
|
|
7806
|
+
Kt,
|
|
7809
7807
|
{
|
|
7810
7808
|
id: `${t}.${y}`,
|
|
7811
7809
|
...E
|
|
@@ -7865,7 +7863,7 @@ const nc = { height: 67, height_desktop: 83 }, Da = ({ showNavigation: t = !0 })
|
|
|
7865
7863
|
"nav",
|
|
7866
7864
|
{
|
|
7867
7865
|
id: "header",
|
|
7868
|
-
className:
|
|
7866
|
+
className: S({
|
|
7869
7867
|
"logged-in": i,
|
|
7870
7868
|
"logged-out": !i,
|
|
7871
7869
|
visible: f
|
|
@@ -7906,8 +7904,8 @@ const nc = { height: 67, height_desktop: 83 }, Da = ({ showNavigation: t = !0 })
|
|
|
7906
7904
|
hidden: s.navigation || l.account ? !1 : !l.navigation,
|
|
7907
7905
|
role: "menu",
|
|
7908
7906
|
"data-showing": !s.navigation && l.account ? "account" : "default",
|
|
7909
|
-
children:
|
|
7910
|
-
|
|
7907
|
+
children: Yt.order.map((p) => /* @__PURE__ */ a.jsx(
|
|
7908
|
+
Kt,
|
|
7911
7909
|
{
|
|
7912
7910
|
id: p,
|
|
7913
7911
|
isLoggedIn: i,
|
|
@@ -7978,7 +7976,7 @@ const nc = { height: 67, height_desktop: 83 }, Da = ({ showNavigation: t = !0 })
|
|
|
7978
7976
|
)
|
|
7979
7977
|
]
|
|
7980
7978
|
}
|
|
7981
|
-
) : /* @__PURE__ */ a.jsx("ul", { className: "sign-in-buttons", children:
|
|
7979
|
+
) : /* @__PURE__ */ a.jsx("ul", { className: "sign-in-buttons", children: Yt.buttons.order.map((p) => /* @__PURE__ */ a.jsx(Kt, { id: `buttons.${p}` }, p)) })
|
|
7982
7980
|
] })
|
|
7983
7981
|
]
|
|
7984
7982
|
}
|
|
@@ -7987,7 +7985,7 @@ const nc = { height: 67, height_desktop: 83 }, Da = ({ showNavigation: t = !0 })
|
|
|
7987
7985
|
/* @__PURE__ */ a.jsx(
|
|
7988
7986
|
"div",
|
|
7989
7987
|
{
|
|
7990
|
-
className:
|
|
7988
|
+
className: S("overlay", {
|
|
7991
7989
|
open: l.navigation || l.account || !s.search && l.search
|
|
7992
7990
|
})
|
|
7993
7991
|
}
|
|
@@ -8017,19 +8015,19 @@ const rc = () => {
|
|
|
8017
8015
|
locale: c = "en"
|
|
8018
8016
|
}) => {
|
|
8019
8017
|
const { navigation: f = !0, footer: l = !0 } = i, { background: u = "default", variant: d = "default", circle: m = "default" } = s, p = $i();
|
|
8020
|
-
|
|
8018
|
+
ae(() => {
|
|
8021
8019
|
window.scrollTo(0, 0);
|
|
8022
8020
|
}, [p]);
|
|
8023
|
-
const v =
|
|
8021
|
+
const v = Ot(t, { locale: c }), b = Ot(e, {
|
|
8024
8022
|
locale: c
|
|
8025
|
-
}), _ =
|
|
8023
|
+
}), _ = Ot(n, {
|
|
8026
8024
|
locale: c
|
|
8027
8025
|
}), g = {};
|
|
8028
8026
|
return u !== "default" && (g[u] = !0), d !== "default" && (g[d] = !0), m !== "default" && (g[m] = !0), /* @__PURE__ */ a.jsx(xi, { onError: r, fallback: /* @__PURE__ */ a.jsx(rc, {}), children: /* @__PURE__ */ a.jsx(ui, { fallback: null, children: /* @__PURE__ */ a.jsxs(
|
|
8029
8027
|
"div",
|
|
8030
8028
|
{
|
|
8031
8029
|
id: "wrapper",
|
|
8032
|
-
className:
|
|
8030
|
+
className: S(o, g, { "has-footer": l }),
|
|
8033
8031
|
children: [
|
|
8034
8032
|
/* @__PURE__ */ a.jsx(Da, { showNavigation: f }),
|
|
8035
8033
|
/* @__PURE__ */ a.jsxs("section", { id: "content-wrapper", children: [
|
|
@@ -8068,7 +8066,7 @@ const rc = () => {
|
|
|
8068
8066
|
getTagDetails: (t) => {
|
|
8069
8067
|
if (t.includes("topic_")) {
|
|
8070
8068
|
if (t = $n.topic[t.replace("topic_", "")], t) {
|
|
8071
|
-
const e =
|
|
8069
|
+
const e = Yt.topics.topics[t].href;
|
|
8072
8070
|
return e ? { id: t, href: e, text: `${Br.headerTopics}${t}` } : null;
|
|
8073
8071
|
}
|
|
8074
8072
|
return null;
|
|
@@ -8097,7 +8095,7 @@ const zl = ({
|
|
|
8097
8095
|
}), f.length < 1 ? null : /* @__PURE__ */ a.jsx(
|
|
8098
8096
|
"ul",
|
|
8099
8097
|
{
|
|
8100
|
-
className:
|
|
8098
|
+
className: S("tags text-small", e, i, {
|
|
8101
8099
|
"one-line": n
|
|
8102
8100
|
}),
|
|
8103
8101
|
children: f.map((l) => {
|
|
@@ -8126,14 +8124,14 @@ const Zl = ({
|
|
|
8126
8124
|
className: o = ""
|
|
8127
8125
|
}) => {
|
|
8128
8126
|
const c = G();
|
|
8129
|
-
return t.length === 0 ? null : /* @__PURE__ */ a.jsxs("div", { className:
|
|
8127
|
+
return t.length === 0 ? null : /* @__PURE__ */ a.jsxs("div", { className: S("members-list", o), children: [
|
|
8130
8128
|
/* @__PURE__ */ a.jsxs("h1", { children: [
|
|
8131
8129
|
c.formatMessage({ id: "membersList" }),
|
|
8132
8130
|
/* @__PURE__ */ a.jsx("span", { className: "count", children: e })
|
|
8133
8131
|
] }),
|
|
8134
8132
|
/* @__PURE__ */ a.jsx("ul", { children: t.map((f, l) => /* @__PURE__ */ a.jsxs("li", { children: [
|
|
8135
8133
|
/* @__PURE__ */ a.jsx(Yn, { member: f, gtmContext: i, gtmType: s }),
|
|
8136
|
-
f.isAdmin && /* @__PURE__ */ a.jsx(
|
|
8134
|
+
f.isAdmin && /* @__PURE__ */ a.jsx(Lt, { children: c.formatMessage({ id: "membersList_admin" }) })
|
|
8137
8135
|
] }, l)) }),
|
|
8138
8136
|
n && /* @__PURE__ */ a.jsx(
|
|
8139
8137
|
en,
|
|
@@ -8146,7 +8144,7 @@ const Zl = ({
|
|
|
8146
8144
|
)
|
|
8147
8145
|
] });
|
|
8148
8146
|
};
|
|
8149
|
-
let
|
|
8147
|
+
let Mt = null;
|
|
8150
8148
|
const we = "discussion_form_", Jn = ({
|
|
8151
8149
|
content: t = { type: "response", slugs: {} },
|
|
8152
8150
|
userHasPermissions: e = !0,
|
|
@@ -8180,7 +8178,7 @@ const we = "discussion_form_", Jn = ({
|
|
|
8180
8178
|
},
|
|
8181
8179
|
gtmContext: l = "DiscussionForm"
|
|
8182
8180
|
}) => {
|
|
8183
|
-
var O,
|
|
8181
|
+
var O, C, T;
|
|
8184
8182
|
const u = G(), d = Ce(Oe), [m, p] = te(
|
|
8185
8183
|
n.isEditing && n.isEditing.text || ""
|
|
8186
8184
|
), [v, b] = te(c.error || !1), [_, g] = te(!1), y = pe(null);
|
|
@@ -8193,85 +8191,85 @@ const we = "discussion_form_", Jn = ({
|
|
|
8193
8191
|
}
|
|
8194
8192
|
);
|
|
8195
8193
|
const E = (x) => {
|
|
8196
|
-
const
|
|
8197
|
-
p(
|
|
8198
|
-
let
|
|
8199
|
-
!d || !d.id ?
|
|
8194
|
+
const $ = x.target.value;
|
|
8195
|
+
p($);
|
|
8196
|
+
let I;
|
|
8197
|
+
!d || !d.id ? I = Se(
|
|
8200
8198
|
u.formatMessage,
|
|
8201
8199
|
`${we}error_loggedOut`,
|
|
8202
8200
|
t.type,
|
|
8203
8201
|
"action"
|
|
8204
|
-
) : e ?
|
|
8202
|
+
) : e ? $.length >= s && (I = `${we}error_tooLong`) : I = Se(
|
|
8205
8203
|
u.formatMessage,
|
|
8206
8204
|
`${we}error_noPermission`,
|
|
8207
8205
|
t.type,
|
|
8208
8206
|
"action"
|
|
8209
|
-
),
|
|
8207
|
+
), I ? b(I) : v && b(!1);
|
|
8210
8208
|
};
|
|
8211
8209
|
let j = `${t.type}-form`;
|
|
8212
8210
|
if (t.type === "response" || t.type === "reply") {
|
|
8213
|
-
const x = ((O = t.slugs) == null ? void 0 : O.reply) || ((
|
|
8211
|
+
const x = ((O = t.slugs) == null ? void 0 : O.reply) || ((C = t.slugs) == null ? void 0 : C.answer) || ((T = t.slugs) == null ? void 0 : T.question) || "";
|
|
8214
8212
|
x && (j = `${j}-${x.slice(-15)}`);
|
|
8215
8213
|
}
|
|
8216
8214
|
const w = async (x) => {
|
|
8217
|
-
var
|
|
8218
|
-
if (x.preventDefault(), x.stopPropagation(), !d || !d.id || !e ||
|
|
8215
|
+
var I;
|
|
8216
|
+
if (x.preventDefault(), x.stopPropagation(), !d || !d.id || !e || F)
|
|
8219
8217
|
return;
|
|
8220
|
-
|
|
8221
|
-
const
|
|
8218
|
+
Mt && clearTimeout(Mt), g("submitting");
|
|
8219
|
+
const $ = window.location.pathname;
|
|
8222
8220
|
try {
|
|
8223
|
-
let
|
|
8221
|
+
let U;
|
|
8224
8222
|
switch (t.type) {
|
|
8225
8223
|
case "post":
|
|
8226
|
-
|
|
8224
|
+
U = await f.create({ content: m });
|
|
8227
8225
|
break;
|
|
8228
8226
|
case "question":
|
|
8229
|
-
|
|
8227
|
+
U = await f.create({
|
|
8230
8228
|
title: m,
|
|
8231
8229
|
authorId: d && d.id,
|
|
8232
|
-
...(
|
|
8230
|
+
...(I = f.props) == null ? void 0 : I.create
|
|
8233
8231
|
});
|
|
8234
8232
|
break;
|
|
8235
8233
|
case "response":
|
|
8236
|
-
|
|
8234
|
+
U = await f.create(
|
|
8237
8235
|
{ question: t.slugs.question },
|
|
8238
|
-
{ body: m, authorId: d && d.id, contentPath:
|
|
8236
|
+
{ body: m, authorId: d && d.id, contentPath: $ }
|
|
8239
8237
|
);
|
|
8240
8238
|
break;
|
|
8241
8239
|
case "reply":
|
|
8242
|
-
|
|
8240
|
+
U = await f.create(
|
|
8243
8241
|
{ question: t.slugs.question, answer: t.slugs.answer },
|
|
8244
|
-
{ body: m, authorId: d && d.id, contentPath:
|
|
8242
|
+
{ body: m, authorId: d && d.id, contentPath: $ }
|
|
8245
8243
|
);
|
|
8246
8244
|
break;
|
|
8247
8245
|
default:
|
|
8248
8246
|
break;
|
|
8249
8247
|
}
|
|
8250
|
-
await Ai(1e3), f.callback && await f.callback(
|
|
8248
|
+
await Ai(1e3), f.callback && await f.callback(U), Mt = setTimeout(() => {
|
|
8251
8249
|
p(""), g("submitted");
|
|
8252
|
-
const
|
|
8253
|
-
document.dispatchEvent(
|
|
8250
|
+
const A = new Event("discussionFormSubmitted");
|
|
8251
|
+
document.dispatchEvent(A), z();
|
|
8254
8252
|
}, 500);
|
|
8255
|
-
} catch (
|
|
8256
|
-
const
|
|
8257
|
-
let
|
|
8258
|
-
|
|
8253
|
+
} catch (U) {
|
|
8254
|
+
const A = U;
|
|
8255
|
+
let W = `${we}error`;
|
|
8256
|
+
A != null && A.message.includes("entry already exists") && (W = Se(
|
|
8259
8257
|
u.formatMessage,
|
|
8260
8258
|
`${we}error_alreadyExists`,
|
|
8261
8259
|
t.type,
|
|
8262
8260
|
"action"
|
|
8263
|
-
)),
|
|
8261
|
+
)), A != null && A.message.includes("429") ? W = Se(
|
|
8264
8262
|
u.formatMessage,
|
|
8265
8263
|
`${we}error_tooMany`,
|
|
8266
8264
|
t.type,
|
|
8267
8265
|
"action"
|
|
8268
|
-
) :
|
|
8266
|
+
) : A != null && A.message.includes("400") && (W = `${we}error`), b(W), z();
|
|
8269
8267
|
}
|
|
8270
|
-
},
|
|
8271
|
-
|
|
8268
|
+
}, z = () => {
|
|
8269
|
+
Mt = setTimeout(() => {
|
|
8272
8270
|
b(!1), g(!1);
|
|
8273
8271
|
}, 5e3);
|
|
8274
|
-
},
|
|
8272
|
+
}, F = !m || !Zi(m), q = _ === "submitting", M = [];
|
|
8275
8273
|
return (n.isEditing && !q || c.cancel) && M.push({
|
|
8276
8274
|
variant: "secondary",
|
|
8277
8275
|
size: { mobile: "small", 600: "medium" },
|
|
@@ -8297,7 +8295,7 @@ const we = "discussion_form_", Jn = ({
|
|
|
8297
8295
|
"data-gtm-event-context": l,
|
|
8298
8296
|
"data-gtm-event-type": `${n.isEditing ? "save" : "submit"}-${t.type}-click`,
|
|
8299
8297
|
"data-testid": "save-button",
|
|
8300
|
-
disabled: !d || !d.id || !e ||
|
|
8298
|
+
disabled: !d || !d.id || !e || F || q || n.isEditing && m === n.isEditing.text,
|
|
8301
8299
|
children: u.formatMessage({
|
|
8302
8300
|
id: `${we}${q ? n.isEditing ? "saving" : "posting" : n.isEditing ? "save" : "post"}`
|
|
8303
8301
|
})
|
|
@@ -8305,7 +8303,7 @@ const we = "discussion_form_", Jn = ({
|
|
|
8305
8303
|
"form",
|
|
8306
8304
|
{
|
|
8307
8305
|
id: j,
|
|
8308
|
-
className:
|
|
8306
|
+
className: S("discussion-card discussion-form", {
|
|
8309
8307
|
"no-styling": n.isInWrapper && n.isEditing
|
|
8310
8308
|
}),
|
|
8311
8309
|
"data-testid": `discussion-${t.type}-form`,
|
|
@@ -8355,9 +8353,9 @@ const we = "discussion_form_", Jn = ({
|
|
|
8355
8353
|
}
|
|
8356
8354
|
)
|
|
8357
8355
|
}) }),
|
|
8358
|
-
/* @__PURE__ */ a.jsx(
|
|
8359
|
-
_ === "submitted" && n.showSuccessMessage && /* @__PURE__ */ a.jsx(
|
|
8360
|
-
v && /* @__PURE__ */ a.jsx(
|
|
8356
|
+
/* @__PURE__ */ a.jsx(yt, { buttons: M }),
|
|
8357
|
+
_ === "submitted" && n.showSuccessMessage && /* @__PURE__ */ a.jsx(Bt, { className: "success", "data-testid": "success", children: Se(u.formatMessage, `${we}success`, t.type, "action") }),
|
|
8358
|
+
v && /* @__PURE__ */ a.jsx(Bt, { id: "error-message", className: "error", "data-testid": "error", children: c.error ? c.error : typeof v == "string" ? v.includes(" ") ? v : u.formatMessage(
|
|
8361
8359
|
{ id: v },
|
|
8362
8360
|
{
|
|
8363
8361
|
action: u.formatMessage({
|
|
@@ -8427,7 +8425,7 @@ const Nn = () => {
|
|
|
8427
8425
|
} } = {}
|
|
8428
8426
|
}) => {
|
|
8429
8427
|
const l = G();
|
|
8430
|
-
|
|
8428
|
+
ae(() => {
|
|
8431
8429
|
p(i);
|
|
8432
8430
|
}, [i]);
|
|
8433
8431
|
const [u, d] = te(e), [m, p] = te(i), [v, b] = te(!1), [_, g] = te(!1), y = vt(
|
|
@@ -8446,8 +8444,8 @@ const Nn = () => {
|
|
|
8446
8444
|
w < 0 && (w = 0), b(!0), d(w), p(!m);
|
|
8447
8445
|
try {
|
|
8448
8446
|
if (s && s.slugs) {
|
|
8449
|
-
const
|
|
8450
|
-
m ? await f(
|
|
8447
|
+
const z = cc(s.slugs);
|
|
8448
|
+
m ? await f(z) : await c(z, { contentPath: window.location.pathname });
|
|
8451
8449
|
}
|
|
8452
8450
|
} catch {
|
|
8453
8451
|
d(e), p(i);
|
|
@@ -8456,7 +8454,7 @@ const Nn = () => {
|
|
|
8456
8454
|
}
|
|
8457
8455
|
};
|
|
8458
8456
|
return K.createElement(t, {
|
|
8459
|
-
className:
|
|
8457
|
+
className: S("likes-wrapper text-medium action-button", {
|
|
8460
8458
|
"show-spinner": v,
|
|
8461
8459
|
"is-liked": m,
|
|
8462
8460
|
disabled: !o
|
|
@@ -8476,12 +8474,12 @@ const Nn = () => {
|
|
|
8476
8474
|
},
|
|
8477
8475
|
children: /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
8478
8476
|
/* @__PURE__ */ a.jsx(
|
|
8479
|
-
|
|
8477
|
+
ie,
|
|
8480
8478
|
{
|
|
8481
8479
|
variant: "tertiary",
|
|
8482
8480
|
size: "medium",
|
|
8483
8481
|
icon: { icon: m ? "heart" : "heart_empty", animate: "bounce" },
|
|
8484
|
-
className:
|
|
8482
|
+
className: S({ "do-animation": m && !i }),
|
|
8485
8483
|
screenreaderText: o ? l.formatMessage(
|
|
8486
8484
|
{
|
|
8487
8485
|
id: `discussion_likes_${m ? "unlike" : "like"}`
|
|
@@ -8503,7 +8501,7 @@ const Nn = () => {
|
|
|
8503
8501
|
/* @__PURE__ */ a.jsx(
|
|
8504
8502
|
"span",
|
|
8505
8503
|
{
|
|
8506
|
-
className:
|
|
8504
|
+
className: S("number-of-likes", { "no-likes": u === 0 }),
|
|
8507
8505
|
"data-testid": "number-of-likes",
|
|
8508
8506
|
children: l.formatMessage(
|
|
8509
8507
|
{ id: `discussion_likes${r ? "_short" : ""}` },
|
|
@@ -8513,12 +8511,12 @@ const Nn = () => {
|
|
|
8513
8511
|
),
|
|
8514
8512
|
n && /* @__PURE__ */ a.jsx(Vi, { isOpen: _, isLoading: n.length === 0, children: n.length && /* @__PURE__ */ a.jsxs("ul", { children: [
|
|
8515
8513
|
y.map((w) => typeof w == "string" || !w.name ? null : /* @__PURE__ */ a.jsx("li", { children: /* @__PURE__ */ a.jsx(
|
|
8516
|
-
|
|
8514
|
+
xt,
|
|
8517
8515
|
{
|
|
8518
8516
|
href: w.id ? `/profiles/${w.id}` : void 0,
|
|
8519
8517
|
gtmContext: "Likes",
|
|
8520
8518
|
gtmType: "liked-name-click",
|
|
8521
|
-
onClick: (
|
|
8519
|
+
onClick: (z) => z == null ? void 0 : z.stopPropagation(),
|
|
8522
8520
|
children: w.name
|
|
8523
8521
|
}
|
|
8524
8522
|
) }, w.id || window.btoa(w.name))),
|
|
@@ -8563,58 +8561,58 @@ const Pe = "discussion_", uc = 280, nn = ({
|
|
|
8563
8561
|
children: b,
|
|
8564
8562
|
isTruncated: _ = !1
|
|
8565
8563
|
}) => {
|
|
8566
|
-
const g = G(), y = Ce(Oe), E = Ce(Xn), { author: j, canLike: w, createdAt:
|
|
8564
|
+
const g = G(), y = Ce(Oe), E = Ce(Xn), { author: j, canLike: w, createdAt: z, id: F, likes: q = 0, userLiked: M, comments: O = 0 } = e, C = y && y.id && typeof j != "string" && j.id && j.id === y.id || !1, T = typeof w == "boolean" ? w : n ? !C : !1, x = C && (!e.createdAt || Di(e.createdAt, 10, "seconds")), $ = pe(null), [I, U] = te({
|
|
8567
8565
|
body: e && e.body || "",
|
|
8568
8566
|
isEditing: !1,
|
|
8569
8567
|
didEdit: e && e.isEdited || !1
|
|
8570
|
-
}), [
|
|
8568
|
+
}), [A, W] = te(!1), [J, k] = te(
|
|
8571
8569
|
x ? "highlighted" : "default"
|
|
8572
8570
|
/* Default */
|
|
8573
8571
|
), [N, Z] = te("");
|
|
8574
|
-
|
|
8575
|
-
const
|
|
8576
|
-
if (!(!
|
|
8577
|
-
return document.addEventListener("discussionFormSubmitted",
|
|
8578
|
-
document.removeEventListener("discussionFormSubmitted",
|
|
8572
|
+
ae(() => {
|
|
8573
|
+
const R = $.current;
|
|
8574
|
+
if (!(!R || J === "default"))
|
|
8575
|
+
return document.addEventListener("discussionFormSubmitted", B), R.addEventListener("transitionend", H), () => {
|
|
8576
|
+
document.removeEventListener("discussionFormSubmitted", B), R.removeEventListener("transitionend", H);
|
|
8579
8577
|
};
|
|
8580
|
-
}, []),
|
|
8581
|
-
|
|
8582
|
-
...
|
|
8578
|
+
}, []), ae(() => {
|
|
8579
|
+
U({
|
|
8580
|
+
...I,
|
|
8583
8581
|
body: e && e.body || "",
|
|
8584
8582
|
didEdit: e && e.isEdited || !1
|
|
8585
8583
|
});
|
|
8586
8584
|
}, [e.isEdited]);
|
|
8587
|
-
const
|
|
8585
|
+
const B = () => {
|
|
8588
8586
|
setTimeout(() => {
|
|
8589
8587
|
k(
|
|
8590
8588
|
"fading"
|
|
8591
8589
|
/* Fading */
|
|
8592
8590
|
);
|
|
8593
8591
|
}, 1e3);
|
|
8594
|
-
},
|
|
8595
|
-
|
|
8592
|
+
}, H = ({ propertyName: R }) => {
|
|
8593
|
+
R === "background-color" && k((oe) => (oe === "default" && (document.removeEventListener("discussionFormSubmitted", B), $.current && $.current.removeEventListener("transitionend", H)), oe === "fading" ? "default" : oe));
|
|
8596
8594
|
};
|
|
8597
8595
|
if (r || !e || e.type === "answer" && (!e.slugs || !e.slugs.question))
|
|
8598
8596
|
return /* @__PURE__ */ a.jsx(Te, { className: "discussion-card discussion-post" });
|
|
8599
|
-
const
|
|
8600
|
-
|
|
8597
|
+
const ee = _ ? Ke(I.body, uc) : I.body, Y = async (R) => {
|
|
8598
|
+
R || (R = ""), Z("");
|
|
8601
8599
|
try {
|
|
8602
|
-
if (!ki(
|
|
8603
|
-
const oe = e.type === "question" ? { title:
|
|
8600
|
+
if (!ki(R, I.body)) {
|
|
8601
|
+
const oe = e.type === "question" ? { title: R } : { body: R };
|
|
8604
8602
|
await f(qr(e.slugs), oe);
|
|
8605
8603
|
}
|
|
8606
|
-
|
|
8604
|
+
U({ body: R, isEditing: !1, didEdit: !0 });
|
|
8607
8605
|
} catch {
|
|
8608
8606
|
Z(`${Pe}form_error`);
|
|
8609
8607
|
}
|
|
8610
|
-
},
|
|
8608
|
+
}, V = () => {
|
|
8611
8609
|
E && E.updateConversation && E.updateConversation({ showForm: !0 }), setTimeout(() => {
|
|
8612
8610
|
var $e, Ee, Le;
|
|
8613
|
-
const oe = `reply-form-${(e.type === "answer" ? e.slug : (($e = e.slugs) == null ? void 0 : $e.reply) || ((Ee = e.slugs) == null ? void 0 : Ee.answer) || ((Le = e.slugs) == null ? void 0 : Le.question) || "").toLowerCase().slice(-15)}`,
|
|
8614
|
-
ve && ve.focus(),
|
|
8611
|
+
const oe = `reply-form-${(e.type === "answer" ? e.slug : (($e = e.slugs) == null ? void 0 : $e.reply) || ((Ee = e.slugs) == null ? void 0 : Ee.answer) || ((Le = e.slugs) == null ? void 0 : Le.question) || "").toLowerCase().slice(-15)}`, D = document.getElementById(oe), ve = document.getElementById(`${oe}-input`);
|
|
8612
|
+
ve && ve.focus(), D && D.scrollIntoView({ behavior: "smooth" });
|
|
8615
8613
|
}, 0);
|
|
8616
|
-
},
|
|
8617
|
-
|
|
8614
|
+
}, X = () => {
|
|
8615
|
+
W(!1);
|
|
8618
8616
|
try {
|
|
8619
8617
|
c(qr(e.slugs));
|
|
8620
8618
|
} catch {
|
|
@@ -8623,8 +8621,8 @@ const Pe = "discussion_", uc = 280, nn = ({
|
|
|
8623
8621
|
}, re = [
|
|
8624
8622
|
{
|
|
8625
8623
|
text: g.formatMessage({ id: `${Pe}moreMenu_report` }),
|
|
8626
|
-
onClick: (
|
|
8627
|
-
|
|
8624
|
+
onClick: (R) => {
|
|
8625
|
+
R.stopPropagation();
|
|
8628
8626
|
},
|
|
8629
8627
|
href: `mailto:community@apolitical.co?subject=${encodeURI(
|
|
8630
8628
|
g.formatMessage({ id: `${Pe}report_subject` })
|
|
@@ -8641,10 +8639,10 @@ const Pe = "discussion_", uc = 280, nn = ({
|
|
|
8641
8639
|
icon: "flag"
|
|
8642
8640
|
}
|
|
8643
8641
|
];
|
|
8644
|
-
return n &&
|
|
8642
|
+
return n && C && re.push(
|
|
8645
8643
|
{
|
|
8646
8644
|
text: g.formatMessage({ id: `${Pe}moreMenu_edit` }),
|
|
8647
|
-
onClick: () =>
|
|
8645
|
+
onClick: () => U({ ...I, isEditing: !0 }),
|
|
8648
8646
|
icon: "pencil-paper",
|
|
8649
8647
|
className: "gtm-trackable",
|
|
8650
8648
|
"data-gtm-event-context": v,
|
|
@@ -8652,45 +8650,45 @@ const Pe = "discussion_", uc = 280, nn = ({
|
|
|
8652
8650
|
},
|
|
8653
8651
|
{
|
|
8654
8652
|
text: g.formatMessage({ id: `${Pe}moreMenu_delete` }),
|
|
8655
|
-
onClick: (
|
|
8656
|
-
|
|
8653
|
+
onClick: (R) => {
|
|
8654
|
+
R.preventDefault(), R.stopPropagation(), W(!0);
|
|
8657
8655
|
},
|
|
8658
8656
|
icon: "trash",
|
|
8659
8657
|
className: "gtm-trackable",
|
|
8660
8658
|
"data-gtm-event-context": v,
|
|
8661
8659
|
"data-gtm-event-type": `delete-${e.type}-click`,
|
|
8662
|
-
...bo(`delete-${e.slug}-modal`,
|
|
8660
|
+
...bo(`delete-${e.slug}-modal`, A)
|
|
8663
8661
|
}
|
|
8664
8662
|
), K.createElement(t, {
|
|
8665
|
-
className:
|
|
8666
|
-
[
|
|
8663
|
+
className: S("discussion-post", p, {
|
|
8664
|
+
[J]: !p || !p.includes("highlighted-text-box")
|
|
8667
8665
|
}),
|
|
8668
|
-
ref:
|
|
8666
|
+
ref: $,
|
|
8669
8667
|
"data-testid": `discussion-${e.type}-thread`,
|
|
8670
8668
|
children: /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
8671
8669
|
/* @__PURE__ */ a.jsxs(
|
|
8672
8670
|
"div",
|
|
8673
8671
|
{
|
|
8674
|
-
id:
|
|
8675
|
-
className:
|
|
8676
|
-
editing:
|
|
8677
|
-
"has-link": m.post && !
|
|
8672
|
+
id: F || e.slug,
|
|
8673
|
+
className: S("discussion-card", e.type, {
|
|
8674
|
+
editing: I.isEditing,
|
|
8675
|
+
"has-link": m.post && !I.isEditing
|
|
8678
8676
|
}),
|
|
8679
|
-
onClick: (
|
|
8680
|
-
!m.post ||
|
|
8677
|
+
onClick: (R) => {
|
|
8678
|
+
!m.post || I.isEditing || (R.preventDefault(), R.stopPropagation(), window.location.href = m.post);
|
|
8681
8679
|
},
|
|
8682
8680
|
children: [
|
|
8683
|
-
!
|
|
8681
|
+
!I.isEditing && /* @__PURE__ */ a.jsx(
|
|
8684
8682
|
Yn,
|
|
8685
8683
|
{
|
|
8686
8684
|
member: j,
|
|
8687
|
-
additionalContent: { createdAt:
|
|
8685
|
+
additionalContent: { createdAt: z, didEdit: I.didEdit },
|
|
8688
8686
|
className: typeof j != "string" && j.id === i ? "highlighted" : "",
|
|
8689
8687
|
gtmContext: v,
|
|
8690
8688
|
gtmType: "profile-click"
|
|
8691
8689
|
}
|
|
8692
8690
|
),
|
|
8693
|
-
|
|
8691
|
+
I.isEditing ? /* @__PURE__ */ a.jsx(
|
|
8694
8692
|
Jn,
|
|
8695
8693
|
{
|
|
8696
8694
|
content: { type: e.type, slugs: e.slugs },
|
|
@@ -8698,7 +8696,7 @@ const Pe = "discussion_", uc = 280, nn = ({
|
|
|
8698
8696
|
meta: {
|
|
8699
8697
|
isLoading: r,
|
|
8700
8698
|
isInWrapper: !0,
|
|
8701
|
-
isEditing: { text:
|
|
8699
|
+
isEditing: { text: I.body }
|
|
8702
8700
|
},
|
|
8703
8701
|
maxLength: e.type === "question" ? 250 : 5e4,
|
|
8704
8702
|
forceShow: {
|
|
@@ -8715,7 +8713,7 @@ const Pe = "discussion_", uc = 280, nn = ({
|
|
|
8715
8713
|
create: o,
|
|
8716
8714
|
handleSaveEdit: Y,
|
|
8717
8715
|
handleCancel: () => {
|
|
8718
|
-
Z(""),
|
|
8716
|
+
Z(""), U({ ...I, isEditing: !1 });
|
|
8719
8717
|
}
|
|
8720
8718
|
},
|
|
8721
8719
|
gtmContext: `${v}Form`
|
|
@@ -8727,10 +8725,10 @@ const Pe = "discussion_", uc = 280, nn = ({
|
|
|
8727
8725
|
className: "gtm-trackable",
|
|
8728
8726
|
"data-gtm-event-context": v,
|
|
8729
8727
|
"data-gtm-event-type": "title-click",
|
|
8730
|
-
children: /* @__PURE__ */ a.jsx(
|
|
8728
|
+
children: /* @__PURE__ */ a.jsx(It, { options: { overrides: { a: us } }, children: ee })
|
|
8731
8729
|
}
|
|
8732
8730
|
) : /* @__PURE__ */ a.jsx(
|
|
8733
|
-
|
|
8731
|
+
It,
|
|
8734
8732
|
{
|
|
8735
8733
|
options: {
|
|
8736
8734
|
wrapper: e.type === "question" ? "h1" : K.Fragment,
|
|
@@ -8738,13 +8736,13 @@ const Pe = "discussion_", uc = 280, nn = ({
|
|
|
8738
8736
|
forceInline: e.type === "question",
|
|
8739
8737
|
forceBlock: e.type !== "question"
|
|
8740
8738
|
},
|
|
8741
|
-
children:
|
|
8739
|
+
children: ee
|
|
8742
8740
|
}
|
|
8743
8741
|
),
|
|
8744
|
-
!
|
|
8742
|
+
!I.isEditing && /* @__PURE__ */ a.jsxs(
|
|
8745
8743
|
"ul",
|
|
8746
8744
|
{
|
|
8747
|
-
className:
|
|
8745
|
+
className: S("actions text-medium", e.type),
|
|
8748
8746
|
"data-testid": `${e.type}-actions`,
|
|
8749
8747
|
children: [
|
|
8750
8748
|
/* @__PURE__ */ a.jsx(
|
|
@@ -8767,12 +8765,12 @@ const Pe = "discussion_", uc = 280, nn = ({
|
|
|
8767
8765
|
"li",
|
|
8768
8766
|
{
|
|
8769
8767
|
className: "action-button",
|
|
8770
|
-
onClick: (
|
|
8771
|
-
|
|
8768
|
+
onClick: (R) => {
|
|
8769
|
+
R.preventDefault(), R.stopPropagation(), m.comments && (window.location.href = m.comments), typeof d == "function" && d();
|
|
8772
8770
|
},
|
|
8773
8771
|
children: [
|
|
8774
8772
|
/* @__PURE__ */ a.jsx(
|
|
8775
|
-
|
|
8773
|
+
ie,
|
|
8776
8774
|
{
|
|
8777
8775
|
variant: "tertiary",
|
|
8778
8776
|
size: "medium",
|
|
@@ -8797,12 +8795,12 @@ const Pe = "discussion_", uc = 280, nn = ({
|
|
|
8797
8795
|
}
|
|
8798
8796
|
),
|
|
8799
8797
|
(e.type === "answer" || e.type === "reply") && /* @__PURE__ */ a.jsx("li", { children: /* @__PURE__ */ a.jsx(
|
|
8800
|
-
|
|
8798
|
+
ie,
|
|
8801
8799
|
{
|
|
8802
8800
|
variant: "tertiary",
|
|
8803
8801
|
size: "medium",
|
|
8804
8802
|
styling: { muted: !0 },
|
|
8805
|
-
onClick:
|
|
8803
|
+
onClick: V,
|
|
8806
8804
|
children: g.formatMessage({ id: `${Pe}reply` })
|
|
8807
8805
|
}
|
|
8808
8806
|
) }),
|
|
@@ -8825,9 +8823,9 @@ const Pe = "discussion_", uc = 280, nn = ({
|
|
|
8825
8823
|
Xt,
|
|
8826
8824
|
{
|
|
8827
8825
|
id: `delete-${e.slug}-modal`,
|
|
8828
|
-
isOpen:
|
|
8826
|
+
isOpen: A,
|
|
8829
8827
|
functions: { onOpen: () => {
|
|
8830
|
-
}, onClose: () =>
|
|
8828
|
+
}, onClose: () => W(!1) },
|
|
8831
8829
|
forceShow: {
|
|
8832
8830
|
error: N === "delete-error" ? g.formatMessage(
|
|
8833
8831
|
{ id: "discussion_delete_error" },
|
|
@@ -8845,13 +8843,13 @@ const Pe = "discussion_", uc = 280, nn = ({
|
|
|
8845
8843
|
buttons: [
|
|
8846
8844
|
{
|
|
8847
8845
|
variant: "secondary",
|
|
8848
|
-
onClick: () =>
|
|
8846
|
+
onClick: () => W(!1),
|
|
8849
8847
|
children: g.formatMessage({ id: "discussion_delete_cancel" })
|
|
8850
8848
|
},
|
|
8851
8849
|
{
|
|
8852
8850
|
variant: "primary",
|
|
8853
8851
|
className: "destructive",
|
|
8854
|
-
onClick:
|
|
8852
|
+
onClick: X,
|
|
8855
8853
|
children: g.formatMessage({ id: "discussion_delete_delete" })
|
|
8856
8854
|
}
|
|
8857
8855
|
],
|
|
@@ -8861,7 +8859,7 @@ const Pe = "discussion_", uc = 280, nn = ({
|
|
|
8861
8859
|
{
|
|
8862
8860
|
id: "discussion_delete_text",
|
|
8863
8861
|
values: {
|
|
8864
|
-
p: (
|
|
8862
|
+
p: (R) => /* @__PURE__ */ a.jsx("p", { children: R }),
|
|
8865
8863
|
action: g.formatMessage({
|
|
8866
8864
|
id: `discussion_action_${e.type}`
|
|
8867
8865
|
})
|
|
@@ -8893,7 +8891,7 @@ const mc = ({
|
|
|
8893
8891
|
form: r,
|
|
8894
8892
|
children: i
|
|
8895
8893
|
}) => {
|
|
8896
|
-
const s = G(), o = Ce(Xn), c =
|
|
8894
|
+
const s = G(), o = Ce(Xn), c = Ot(i, {
|
|
8897
8895
|
element: "li"
|
|
8898
8896
|
});
|
|
8899
8897
|
return /* @__PURE__ */ a.jsxs("div", { className: "thread-wrapper", children: [
|
|
@@ -8988,7 +8986,7 @@ function Ur({ activity: t, user: e }) {
|
|
|
8988
8986
|
...gc()
|
|
8989
8987
|
};
|
|
8990
8988
|
}
|
|
8991
|
-
function
|
|
8989
|
+
function Gt({ activity: t, reaction: e }) {
|
|
8992
8990
|
var n, r, i;
|
|
8993
8991
|
e ? (t.latest_reactions = {
|
|
8994
8992
|
...t.latest_reactions || {},
|
|
@@ -9068,7 +9066,7 @@ const qa = (t) => {
|
|
|
9068
9066
|
};
|
|
9069
9067
|
let Wr, Rn = 0;
|
|
9070
9068
|
const Ua = () => {
|
|
9071
|
-
|
|
9069
|
+
ae(() => (document.addEventListener("discussionPostAdded", t), () => {
|
|
9072
9070
|
document.removeEventListener(
|
|
9073
9071
|
"discussionPostAdded",
|
|
9074
9072
|
t
|
|
@@ -9280,7 +9278,7 @@ function Tc({
|
|
|
9280
9278
|
const { mutate: r } = ke({
|
|
9281
9279
|
mutationFn: t,
|
|
9282
9280
|
onMutate: ({ activityId: i, content: s }) => e((o) => {
|
|
9283
|
-
const c =
|
|
9281
|
+
const c = Qt(i, o);
|
|
9284
9282
|
return c && (c.content = s), o;
|
|
9285
9283
|
}),
|
|
9286
9284
|
onError: n
|
|
@@ -9331,13 +9329,13 @@ function Sc({
|
|
|
9331
9329
|
const { mutate: s } = ke({
|
|
9332
9330
|
mutationFn: t,
|
|
9333
9331
|
onMutate: ({ activityId: o }) => e((c) => {
|
|
9334
|
-
const f =
|
|
9335
|
-
return f &&
|
|
9332
|
+
const f = Qt(o, c);
|
|
9333
|
+
return f && Gt({ activity: f }), c;
|
|
9336
9334
|
}),
|
|
9337
9335
|
onError: n,
|
|
9338
9336
|
onSuccess: (o, { activityId: c }, f) => {
|
|
9339
|
-
const l =
|
|
9340
|
-
l &&
|
|
9337
|
+
const l = Qt(c, f);
|
|
9338
|
+
l && Gt({ activity: l, reaction: o }), r.setQueryData(i, f);
|
|
9341
9339
|
}
|
|
9342
9340
|
});
|
|
9343
9341
|
return s;
|
|
@@ -9388,7 +9386,7 @@ function Nc({
|
|
|
9388
9386
|
const { mutate: i } = ke({
|
|
9389
9387
|
mutationFn: t,
|
|
9390
9388
|
onMutate: ({ activityId: s }) => e((o) => {
|
|
9391
|
-
const c =
|
|
9389
|
+
const c = Qt(s, o);
|
|
9392
9390
|
return c && Ba({ activity: c, user: r }), o;
|
|
9393
9391
|
}),
|
|
9394
9392
|
onError: n
|
|
@@ -9404,7 +9402,7 @@ function Hr(t, e, n = !1) {
|
|
|
9404
9402
|
pageParams: [""]
|
|
9405
9403
|
};
|
|
9406
9404
|
}
|
|
9407
|
-
function
|
|
9405
|
+
function Qt(t, e) {
|
|
9408
9406
|
if (e)
|
|
9409
9407
|
for (const { results: n } of e.pages) {
|
|
9410
9408
|
const r = n.find(({ id: i }) => i === t);
|
|
@@ -9466,19 +9464,19 @@ const Wl = ({
|
|
|
9466
9464
|
}
|
|
9467
9465
|
),
|
|
9468
9466
|
c == null ? void 0 : c.map((E, j) => {
|
|
9469
|
-
var
|
|
9467
|
+
var I, U, A, W, J, k, N, Z;
|
|
9470
9468
|
const {
|
|
9471
9469
|
id: w,
|
|
9472
|
-
own_reactions:
|
|
9473
|
-
latest_reactions:
|
|
9470
|
+
own_reactions: z,
|
|
9471
|
+
latest_reactions: F,
|
|
9474
9472
|
reaction_counts: q
|
|
9475
|
-
} = E, M = (((
|
|
9476
|
-
var
|
|
9473
|
+
} = E, M = (((I = F == null ? void 0 : F.like) == null ? void 0 : I.length) || 0) > 0, O = (((U = z == null ? void 0 : z.like) == null ? void 0 : U.length) || 0) > 0, C = O ? z == null ? void 0 : z.like[0].id : "", T = M ? (A = F == null ? void 0 : F.like) == null ? void 0 : A.map((B) => {
|
|
9474
|
+
var H, ee, Y;
|
|
9477
9475
|
return {
|
|
9478
|
-
id: (
|
|
9479
|
-
name: (Y = (
|
|
9476
|
+
id: (H = B == null ? void 0 : B.user) == null ? void 0 : H.id,
|
|
9477
|
+
name: (Y = (ee = B == null ? void 0 : B.user) == null ? void 0 : ee.data) == null ? void 0 : Y.name
|
|
9480
9478
|
};
|
|
9481
|
-
}) : !1, x = E == null ? void 0 : E.actor,
|
|
9479
|
+
}) : !1, x = E == null ? void 0 : E.actor, $ = (x == null ? void 0 : x.id) === (g == null ? void 0 : g.id);
|
|
9482
9480
|
return /* @__PURE__ */ a.jsxs(ht, { children: [
|
|
9483
9481
|
/* @__PURE__ */ a.jsx(
|
|
9484
9482
|
nn,
|
|
@@ -9486,7 +9484,7 @@ const Wl = ({
|
|
|
9486
9484
|
content: {
|
|
9487
9485
|
type: "post",
|
|
9488
9486
|
body: E == null ? void 0 : E.content,
|
|
9489
|
-
canLike: tn(n,
|
|
9487
|
+
canLike: tn(n, $),
|
|
9490
9488
|
createdAt: (E == null ? void 0 : E.time) || "",
|
|
9491
9489
|
slugs: {
|
|
9492
9490
|
question: `${t}/${e}`,
|
|
@@ -9495,8 +9493,8 @@ const Wl = ({
|
|
|
9495
9493
|
slug: w,
|
|
9496
9494
|
author: {
|
|
9497
9495
|
id: x == null ? void 0 : x.id,
|
|
9498
|
-
name: (
|
|
9499
|
-
organization: (
|
|
9496
|
+
name: (W = x == null ? void 0 : x.data) == null ? void 0 : W.name,
|
|
9497
|
+
organization: (J = x == null ? void 0 : x.data) == null ? void 0 : J.organization,
|
|
9500
9498
|
jobTitle: (k = x == null ? void 0 : x.data) == null ? void 0 : k.jobTitle,
|
|
9501
9499
|
location: (N = x == null ? void 0 : x.data) == null ? void 0 : N.location,
|
|
9502
9500
|
image: {
|
|
@@ -9517,11 +9515,11 @@ const Wl = ({
|
|
|
9517
9515
|
createContent: () => null,
|
|
9518
9516
|
deleteContent: () => v({ activityId: w }),
|
|
9519
9517
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
9520
|
-
updateContent: (
|
|
9518
|
+
updateContent: (B, { body: H }) => p({ activityId: w, content: H })
|
|
9521
9519
|
},
|
|
9522
9520
|
likes: {
|
|
9523
9521
|
createLike: () => b({ activityId: w }),
|
|
9524
|
-
deleteLike: () => _({ activityId: w, reactionId:
|
|
9522
|
+
deleteLike: () => _({ activityId: w, reactionId: C })
|
|
9525
9523
|
},
|
|
9526
9524
|
comments: {
|
|
9527
9525
|
openComments: () => null
|
|
@@ -10137,7 +10135,7 @@ function Fc({
|
|
|
10137
10135
|
const { mutate: r } = ke({
|
|
10138
10136
|
mutationFn: t,
|
|
10139
10137
|
onMutate: ({ replyId: i, content: s }) => e((o) => {
|
|
10140
|
-
const c =
|
|
10138
|
+
const c = Jt(i, o);
|
|
10141
10139
|
return c && (c.data.content = s), o;
|
|
10142
10140
|
}),
|
|
10143
10141
|
onError: n
|
|
@@ -10188,12 +10186,12 @@ function Oc({
|
|
|
10188
10186
|
const { mutate: s } = ke({
|
|
10189
10187
|
mutationFn: t,
|
|
10190
10188
|
onMutate: ({ replyId: o }) => e((c) => {
|
|
10191
|
-
const f =
|
|
10189
|
+
const f = Jt(o, c);
|
|
10192
10190
|
return f && Zr({ reply: f }), c;
|
|
10193
10191
|
}),
|
|
10194
10192
|
onError: n,
|
|
10195
10193
|
onSuccess: (o, { replyId: c }, f) => {
|
|
10196
|
-
const l =
|
|
10194
|
+
const l = Jt(c, f);
|
|
10197
10195
|
l && Zr({ reply: l, reaction: o }), r.setQueryData(i, f);
|
|
10198
10196
|
}
|
|
10199
10197
|
});
|
|
@@ -10246,7 +10244,7 @@ function Ic({
|
|
|
10246
10244
|
const { mutate: i } = ke({
|
|
10247
10245
|
mutationFn: t,
|
|
10248
10246
|
onMutate: ({ replyId: s }) => e((o) => {
|
|
10249
|
-
const c =
|
|
10247
|
+
const c = Jt(s, o);
|
|
10250
10248
|
return c && _c({ reply: c, user: r }), o;
|
|
10251
10249
|
}),
|
|
10252
10250
|
onError: n
|
|
@@ -10272,7 +10270,7 @@ function qc(t, e, n) {
|
|
|
10272
10270
|
function Vr(t, e, n) {
|
|
10273
10271
|
return e ? n != null && n.append ? Bc(t, e, n) : qc(t, e, n) : Lc(t);
|
|
10274
10272
|
}
|
|
10275
|
-
function
|
|
10273
|
+
function Jt(t, e) {
|
|
10276
10274
|
if (e)
|
|
10277
10275
|
for (const { results: n } of e.pages) {
|
|
10278
10276
|
const r = n.find(({ id: i }) => i === t);
|
|
@@ -10337,22 +10335,22 @@ const Zc = ({
|
|
|
10337
10335
|
meta: { isEditing: !1, showSuccessMessage: !1 }
|
|
10338
10336
|
},
|
|
10339
10337
|
children: o && o.length > 0 ? o == null ? void 0 : o.map((_) => {
|
|
10340
|
-
var
|
|
10338
|
+
var I, U, A, W, J, k, N, Z, B, H, ee, Y;
|
|
10341
10339
|
const {
|
|
10342
10340
|
id: g,
|
|
10343
10341
|
own_children: y,
|
|
10344
10342
|
latest_children: E,
|
|
10345
10343
|
children_counts: j
|
|
10346
|
-
} = _,
|
|
10347
|
-
var
|
|
10348
|
-
return ((
|
|
10349
|
-
}) : !1,
|
|
10350
|
-
var
|
|
10344
|
+
} = _, z = (((I = y == null ? void 0 : y.like) == null ? void 0 : I.length) || 0) > 0 ? (U = y == null ? void 0 : y.like) == null ? void 0 : U.find((V) => {
|
|
10345
|
+
var X;
|
|
10346
|
+
return ((X = V == null ? void 0 : V.user) == null ? void 0 : X.id) === (b == null ? void 0 : b.id);
|
|
10347
|
+
}) : !1, F = z ? z == null ? void 0 : z.id : "", q = !!z, O = (((A = E == null ? void 0 : E.like) == null ? void 0 : A.length) || 0) > 0 ? (W = E == null ? void 0 : E.like) == null ? void 0 : W.map((V) => {
|
|
10348
|
+
var X, re, R;
|
|
10351
10349
|
return {
|
|
10352
|
-
id: (
|
|
10353
|
-
name: (
|
|
10350
|
+
id: (X = V == null ? void 0 : V.user) == null ? void 0 : X.id,
|
|
10351
|
+
name: (R = (re = V == null ? void 0 : V.user) == null ? void 0 : re.data) == null ? void 0 : R.name
|
|
10354
10352
|
};
|
|
10355
|
-
}) : !1,
|
|
10353
|
+
}) : !1, C = _ == null ? void 0 : _.user, T = (C == null ? void 0 : C.id) === (b == null ? void 0 : b.id), x = tn(i, T), $ = typeof _.data.content == "string" ? (J = _ == null ? void 0 : _.data) == null ? void 0 : J.content : (
|
|
10356
10354
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
10357
10355
|
((N = (k = _ == null ? void 0 : _.data) == null ? void 0 : k.content) == null ? void 0 : N.text) || ""
|
|
10358
10356
|
);
|
|
@@ -10362,7 +10360,7 @@ const Zc = ({
|
|
|
10362
10360
|
content: {
|
|
10363
10361
|
id: g,
|
|
10364
10362
|
type: "reply",
|
|
10365
|
-
body:
|
|
10363
|
+
body: $,
|
|
10366
10364
|
canLike: x,
|
|
10367
10365
|
createdAt: _ == null ? void 0 : _.created_at,
|
|
10368
10366
|
slugs: {
|
|
@@ -10374,13 +10372,13 @@ const Zc = ({
|
|
|
10374
10372
|
},
|
|
10375
10373
|
slug: "",
|
|
10376
10374
|
author: {
|
|
10377
|
-
id:
|
|
10378
|
-
name: (Z =
|
|
10379
|
-
organization: (
|
|
10380
|
-
jobTitle: (
|
|
10381
|
-
location: (
|
|
10375
|
+
id: C == null ? void 0 : C.id,
|
|
10376
|
+
name: (Z = C.data) == null ? void 0 : Z.name,
|
|
10377
|
+
organization: (B = C.data) == null ? void 0 : B.organization,
|
|
10378
|
+
jobTitle: (H = C.data) == null ? void 0 : H.jobTitle,
|
|
10379
|
+
location: (ee = C.data) == null ? void 0 : ee.location,
|
|
10382
10380
|
image: {
|
|
10383
|
-
thumbnail: ((Y =
|
|
10381
|
+
thumbnail: ((Y = C.data) == null ? void 0 : Y.thumbnail) || void 0
|
|
10384
10382
|
}
|
|
10385
10383
|
},
|
|
10386
10384
|
userLiked: q,
|
|
@@ -10392,11 +10390,11 @@ const Zc = ({
|
|
|
10392
10390
|
createContent: () => null,
|
|
10393
10391
|
deleteContent: () => p({ replyId: g }),
|
|
10394
10392
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
10395
|
-
updateContent: (
|
|
10393
|
+
updateContent: (V, { body: X }) => d({ replyId: g, content: X })
|
|
10396
10394
|
},
|
|
10397
10395
|
likes: {
|
|
10398
10396
|
createLike: () => m({ replyId: g }),
|
|
10399
|
-
deleteLike: () => v({ replyId: g, reactionId:
|
|
10397
|
+
deleteLike: () => v({ replyId: g, reactionId: F })
|
|
10400
10398
|
},
|
|
10401
10399
|
comments: {}
|
|
10402
10400
|
}
|
|
@@ -10449,19 +10447,19 @@ const Zc = ({
|
|
|
10449
10447
|
}
|
|
10450
10448
|
),
|
|
10451
10449
|
f == null ? void 0 : f.map((E) => {
|
|
10452
|
-
var
|
|
10453
|
-
const { id: j, own_children: w, latest_children:
|
|
10450
|
+
var W, J, k, N, Z, B, H, ee, Y, V, X, re;
|
|
10451
|
+
const { id: j, own_children: w, latest_children: z, children_counts: F } = E, M = (((W = w == null ? void 0 : w.like) == null ? void 0 : W.length) || 0) > 0 ? (J = w == null ? void 0 : w.like) == null ? void 0 : J.find((R) => {
|
|
10454
10452
|
var oe;
|
|
10455
|
-
return ((oe =
|
|
10456
|
-
}) : !1, O = M ? M == null ? void 0 : M.id : "",
|
|
10457
|
-
var oe,
|
|
10453
|
+
return ((oe = R == null ? void 0 : R.user) == null ? void 0 : oe.id) === (y == null ? void 0 : y.id);
|
|
10454
|
+
}) : !1, O = M ? M == null ? void 0 : M.id : "", C = !!M, x = (((k = z == null ? void 0 : z.like) == null ? void 0 : k.length) || 0) > 0 ? (N = z == null ? void 0 : z.like) == null ? void 0 : N.map((R) => {
|
|
10455
|
+
var oe, D, ve;
|
|
10458
10456
|
return {
|
|
10459
|
-
id: (oe =
|
|
10460
|
-
name: (ve = (
|
|
10457
|
+
id: (oe = R == null ? void 0 : R.user) == null ? void 0 : oe.id,
|
|
10458
|
+
name: (ve = (D = R == null ? void 0 : R.user) == null ? void 0 : D.data) == null ? void 0 : ve.name
|
|
10461
10459
|
};
|
|
10462
|
-
}) : !1,
|
|
10460
|
+
}) : !1, $ = E == null ? void 0 : E.user, I = ($ == null ? void 0 : $.id) === (y == null ? void 0 : y.id), U = tn(r, I), A = typeof E.data.content == "string" ? (Z = E == null ? void 0 : E.data) == null ? void 0 : Z.content : (
|
|
10463
10461
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
10464
|
-
((
|
|
10462
|
+
((H = (B = E == null ? void 0 : E.data) == null ? void 0 : B.content) == null ? void 0 : H.text) || ""
|
|
10465
10463
|
);
|
|
10466
10464
|
return /* @__PURE__ */ a.jsx(oc, { children: /* @__PURE__ */ a.jsx(
|
|
10467
10465
|
nn,
|
|
@@ -10469,8 +10467,8 @@ const Zc = ({
|
|
|
10469
10467
|
content: {
|
|
10470
10468
|
id: j,
|
|
10471
10469
|
type: "reply",
|
|
10472
|
-
body:
|
|
10473
|
-
canLike:
|
|
10470
|
+
body: A,
|
|
10471
|
+
canLike: U,
|
|
10474
10472
|
createdAt: E == null ? void 0 : E.created_at,
|
|
10475
10473
|
slugs: {
|
|
10476
10474
|
question: `${t}/${e}`,
|
|
@@ -10479,17 +10477,17 @@ const Zc = ({
|
|
|
10479
10477
|
},
|
|
10480
10478
|
slug: j,
|
|
10481
10479
|
author: {
|
|
10482
|
-
id:
|
|
10483
|
-
name: (
|
|
10484
|
-
organization: (Y =
|
|
10485
|
-
jobTitle: (
|
|
10486
|
-
location: (
|
|
10480
|
+
id: $ == null ? void 0 : $.id,
|
|
10481
|
+
name: (ee = $.data) == null ? void 0 : ee.name,
|
|
10482
|
+
organization: (Y = $.data) == null ? void 0 : Y.organization,
|
|
10483
|
+
jobTitle: (V = $.data) == null ? void 0 : V.jobTitle,
|
|
10484
|
+
location: (X = $.data) == null ? void 0 : X.location,
|
|
10487
10485
|
image: {
|
|
10488
|
-
thumbnail: ((re =
|
|
10486
|
+
thumbnail: ((re = $.data) == null ? void 0 : re.thumbnail) || void 0
|
|
10489
10487
|
}
|
|
10490
10488
|
},
|
|
10491
|
-
userLiked:
|
|
10492
|
-
likes: (
|
|
10489
|
+
userLiked: C,
|
|
10490
|
+
likes: (F == null ? void 0 : F.like) || 0,
|
|
10493
10491
|
peopleWhoLiked: x
|
|
10494
10492
|
},
|
|
10495
10493
|
functions: {
|
|
@@ -10497,7 +10495,7 @@ const Zc = ({
|
|
|
10497
10495
|
createContent: () => null,
|
|
10498
10496
|
deleteContent: () => _({ replyId: j }),
|
|
10499
10497
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
10500
|
-
updateContent: (
|
|
10498
|
+
updateContent: (R, { body: oe }) => v({ replyId: j, content: oe })
|
|
10501
10499
|
},
|
|
10502
10500
|
likes: {
|
|
10503
10501
|
createLike: () => b({ replyId: j }),
|
|
@@ -10606,10 +10604,10 @@ function Kc({
|
|
|
10606
10604
|
}) {
|
|
10607
10605
|
const { mutate: s } = ke({
|
|
10608
10606
|
mutationFn: t,
|
|
10609
|
-
onMutate: (o) => e((c) => (c &&
|
|
10607
|
+
onMutate: (o) => e((c) => (c && Gt({ activity: c }), c)),
|
|
10610
10608
|
onError: n,
|
|
10611
10609
|
onSuccess: (o, c, f) => {
|
|
10612
|
-
f &&
|
|
10610
|
+
f && Gt({ activity: f, reaction: o }), r.setQueryData(i, f);
|
|
10613
10611
|
}
|
|
10614
10612
|
});
|
|
10615
10613
|
return s;
|
|
@@ -10641,7 +10639,7 @@ const Vl = ({
|
|
|
10641
10639
|
leave: f
|
|
10642
10640
|
}
|
|
10643
10641
|
}) => {
|
|
10644
|
-
var M, O,
|
|
10642
|
+
var M, O, C, T, x, $, I, U, A, W;
|
|
10645
10643
|
const l = G(), u = Ce(Oe), {
|
|
10646
10644
|
activity: d,
|
|
10647
10645
|
error: m,
|
|
@@ -10661,13 +10659,13 @@ const Vl = ({
|
|
|
10661
10659
|
text: l.formatMessage({ id: "activitySection_notFoundError" })
|
|
10662
10660
|
}
|
|
10663
10661
|
);
|
|
10664
|
-
const { own_reactions: g, latest_reactions: y } = d, E = (((M = y == null ? void 0 : y.like) == null ? void 0 : M.length) || 0) > 0, j = (((O = g == null ? void 0 : g.like) == null ? void 0 : O.length) || 0) > 0, w = j ? g == null ? void 0 : g.like[0].id : "",
|
|
10662
|
+
const { own_reactions: g, latest_reactions: y } = d, E = (((M = y == null ? void 0 : y.like) == null ? void 0 : M.length) || 0) > 0, j = (((O = g == null ? void 0 : g.like) == null ? void 0 : O.length) || 0) > 0, w = j ? g == null ? void 0 : g.like[0].id : "", z = E ? (C = y == null ? void 0 : y.like) == null ? void 0 : C.map((J) => {
|
|
10665
10663
|
var k, N, Z;
|
|
10666
10664
|
return {
|
|
10667
|
-
id: (k =
|
|
10668
|
-
name: (Z = (N =
|
|
10665
|
+
id: (k = J == null ? void 0 : J.user) == null ? void 0 : k.id,
|
|
10666
|
+
name: (Z = (N = J == null ? void 0 : J.user) == null ? void 0 : N.data) == null ? void 0 : Z.name
|
|
10669
10667
|
};
|
|
10670
|
-
}) : !1,
|
|
10668
|
+
}) : !1, F = d == null ? void 0 : d.actor, q = (F == null ? void 0 : F.id) === (u == null ? void 0 : u.id);
|
|
10671
10669
|
return /* @__PURE__ */ a.jsxs("section", { className: "activity-section", children: [
|
|
10672
10670
|
/* @__PURE__ */ a.jsx(
|
|
10673
10671
|
nn,
|
|
@@ -10685,28 +10683,28 @@ const Vl = ({
|
|
|
10685
10683
|
},
|
|
10686
10684
|
slug: n,
|
|
10687
10685
|
author: {
|
|
10688
|
-
id:
|
|
10689
|
-
name: (T =
|
|
10690
|
-
organization: (x =
|
|
10691
|
-
jobTitle: (
|
|
10692
|
-
location: (
|
|
10686
|
+
id: F.id,
|
|
10687
|
+
name: (T = F.data) == null ? void 0 : T.name,
|
|
10688
|
+
organization: (x = F.data) == null ? void 0 : x.organization,
|
|
10689
|
+
jobTitle: ($ = F.data) == null ? void 0 : $.jobTitle,
|
|
10690
|
+
location: (I = F.data) == null ? void 0 : I.location,
|
|
10693
10691
|
image: {
|
|
10694
|
-
thumbnail: ((
|
|
10692
|
+
thumbnail: ((U = F.data) == null ? void 0 : U.thumbnail) || void 0
|
|
10695
10693
|
}
|
|
10696
10694
|
},
|
|
10697
10695
|
userLiked: j,
|
|
10698
|
-
likes: ((
|
|
10699
|
-
comments: ((
|
|
10700
|
-
peopleWhoLiked:
|
|
10696
|
+
likes: ((A = d == null ? void 0 : d.reaction_counts) == null ? void 0 : A.like) || 0,
|
|
10697
|
+
comments: ((W = d == null ? void 0 : d.reaction_counts) == null ? void 0 : W.reply) || 0,
|
|
10698
|
+
peopleWhoLiked: z
|
|
10701
10699
|
},
|
|
10702
|
-
originalAuthorId:
|
|
10700
|
+
originalAuthorId: F == null ? void 0 : F.id,
|
|
10703
10701
|
forceHide: { comments: !0 },
|
|
10704
10702
|
functions: {
|
|
10705
10703
|
content: {
|
|
10706
10704
|
createContent: () => null,
|
|
10707
10705
|
deleteContent: i,
|
|
10708
10706
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
10709
|
-
updateContent: (
|
|
10707
|
+
updateContent: (J, { body: k }) => v({ content: k })
|
|
10710
10708
|
},
|
|
10711
10709
|
likes: {
|
|
10712
10710
|
createLike: () => b({ activityId: n }),
|
|
@@ -10788,10 +10786,10 @@ const Vl = ({
|
|
|
10788
10786
|
contributors: ["community"]
|
|
10789
10787
|
}
|
|
10790
10788
|
];
|
|
10791
|
-
const
|
|
10789
|
+
const Rt = "notFoundError_", Kl = () => {
|
|
10792
10790
|
const t = G(), e = [];
|
|
10793
10791
|
return Yr.forEach((n, r) => {
|
|
10794
|
-
n.title = t.formatMessage({ id: `${
|
|
10792
|
+
n.title = t.formatMessage({ id: `${Rt}post_${r + 1}` }), e.push("solutionArticle");
|
|
10795
10793
|
}), /* @__PURE__ */ a.jsxs(
|
|
10796
10794
|
ac,
|
|
10797
10795
|
{
|
|
@@ -10808,15 +10806,15 @@ const Mt = "notFoundError_", Kl = () => {
|
|
|
10808
10806
|
})
|
|
10809
10807
|
}
|
|
10810
10808
|
),
|
|
10811
|
-
/* @__PURE__ */ a.jsx(
|
|
10809
|
+
/* @__PURE__ */ a.jsx(ie, { href: "/solution-articles/", children: t.formatMessage({ id: `${Rt}cta` }) })
|
|
10812
10810
|
] })
|
|
10813
10811
|
},
|
|
10814
10812
|
reportError: () => {
|
|
10815
10813
|
},
|
|
10816
10814
|
className: "not-found-error",
|
|
10817
10815
|
children: [
|
|
10818
|
-
/* @__PURE__ */ a.jsx("h1", { children: t.formatMessage({ id: `${
|
|
10819
|
-
/* @__PURE__ */ a.jsx("p", { children: t.formatMessage({ id: `${
|
|
10816
|
+
/* @__PURE__ */ a.jsx("h1", { children: t.formatMessage({ id: `${Rt}title` }) }),
|
|
10817
|
+
/* @__PURE__ */ a.jsx("p", { children: t.formatMessage({ id: `${Rt}text` }) })
|
|
10820
10818
|
]
|
|
10821
10819
|
}
|
|
10822
10820
|
);
|
|
@@ -10829,8 +10827,8 @@ export {
|
|
|
10829
10827
|
gl as Banner,
|
|
10830
10828
|
_l as BannerSection,
|
|
10831
10829
|
Dl as Breadcrumbs,
|
|
10832
|
-
|
|
10833
|
-
|
|
10830
|
+
ie as Button,
|
|
10831
|
+
yt as ButtonWrapper,
|
|
10834
10832
|
Ji as CacheProvider,
|
|
10835
10833
|
Ma as Card,
|
|
10836
10834
|
Uo as CardBlock,
|
|
@@ -10873,14 +10871,14 @@ export {
|
|
|
10873
10871
|
Ml as InviteModal,
|
|
10874
10872
|
Ra as JoinButton,
|
|
10875
10873
|
Il as LanguageSwitcher,
|
|
10876
|
-
|
|
10874
|
+
xt as Link,
|
|
10877
10875
|
en as LoadMore,
|
|
10878
10876
|
El as LoadingBlock,
|
|
10879
10877
|
Te as LoadingPlaceholder,
|
|
10880
10878
|
fa as LoadingState,
|
|
10881
10879
|
Fa as Logo,
|
|
10882
10880
|
yl as LogoSection,
|
|
10883
|
-
|
|
10881
|
+
It as MarkdownText,
|
|
10884
10882
|
wl as MarketingBlock,
|
|
10885
10883
|
Yn as Member,
|
|
10886
10884
|
Zl as MembersList,
|
|
@@ -10893,20 +10891,20 @@ export {
|
|
|
10893
10891
|
ms as PageHeading,
|
|
10894
10892
|
ac as PageLayout,
|
|
10895
10893
|
Sl as PasswordRules,
|
|
10896
|
-
|
|
10894
|
+
Lt as Pill,
|
|
10897
10895
|
Nl as ProfileImageChange,
|
|
10898
10896
|
ze as ProfilePicture,
|
|
10899
10897
|
gs as ProgressBar,
|
|
10900
10898
|
Cl as Rating,
|
|
10901
10899
|
Wc as RepliesFeed,
|
|
10902
10900
|
fc as ResponsesHeading,
|
|
10903
|
-
|
|
10901
|
+
_t as ResponsiveImage,
|
|
10904
10902
|
hl as ReturnToNavButton,
|
|
10905
10903
|
Mo as SearchForm,
|
|
10906
10904
|
Ll as ShareLinks,
|
|
10907
10905
|
Pl as SignupForm,
|
|
10908
10906
|
us as Span,
|
|
10909
|
-
|
|
10907
|
+
Bt as StatusBanner,
|
|
10910
10908
|
Bl as Tabs,
|
|
10911
10909
|
zl as Tags,
|
|
10912
10910
|
Tl as TestimonialBlock,
|
|
@@ -10919,7 +10917,7 @@ export {
|
|
|
10919
10917
|
bo as addAriaProps,
|
|
10920
10918
|
Fi as generateCssIcon,
|
|
10921
10919
|
pa as getMember,
|
|
10922
|
-
|
|
10920
|
+
Yt as headerData,
|
|
10923
10921
|
Yl as mapGetStreamData,
|
|
10924
10922
|
zi as pageReady,
|
|
10925
10923
|
ml as passwordValidator,
|