@apolitical/component-library 3.5.10 → 3.5.12
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/helpers/intl.d.ts +5 -1
- package/index.js +13 -13
- package/index.mjs +793 -777
- package/package.json +1 -1
- package/style.css +1 -1
- package/styles/base/_blockquotes.scss +11 -0
- package/styles/base/_lists.scss +3 -3
package/index.mjs
CHANGED
|
@@ -7,8 +7,8 @@ import et from "truncate";
|
|
|
7
7
|
import { QueryClient as Ts, QueryClientProvider as Es, useMutation as je, useQueryClient as Kn, useInfiniteQuery as ia, useQuery as Ss } from "@tanstack/react-query";
|
|
8
8
|
import { ReactQueryDevtools as Cs } from "@tanstack/react-query-devtools";
|
|
9
9
|
import Lt from "posthog-js";
|
|
10
|
-
import { CookiesProvider as
|
|
11
|
-
import { ReactMultiEmail as
|
|
10
|
+
import { CookiesProvider as Ns, useCookies as oa } from "react-cookie";
|
|
11
|
+
import { ReactMultiEmail as $s } from "react-multi-email";
|
|
12
12
|
import ca from "lodash.get";
|
|
13
13
|
import { ErrorBoundary as Ps } from "react-error-boundary";
|
|
14
14
|
import Ms from "react-textarea-autosize";
|
|
@@ -74,7 +74,7 @@ var da = { exports: {} };
|
|
|
74
74
|
})();
|
|
75
75
|
})(da);
|
|
76
76
|
var Fs = da.exports;
|
|
77
|
-
const
|
|
77
|
+
const E = /* @__PURE__ */ la(Fs), Os = ({
|
|
78
78
|
element: t = "span",
|
|
79
79
|
showOnFocus: e = !0,
|
|
80
80
|
children: n,
|
|
@@ -82,7 +82,7 @@ const S = /* @__PURE__ */ la(Fs), Os = ({
|
|
|
82
82
|
...s
|
|
83
83
|
}) => Y.createElement(t, {
|
|
84
84
|
...s,
|
|
85
|
-
className:
|
|
85
|
+
className: E("hidden", r, { "show-on-focus": e }),
|
|
86
86
|
children: n
|
|
87
87
|
}), be = Ae(Os), As = ({
|
|
88
88
|
element: t = "span",
|
|
@@ -131,23 +131,23 @@ var wr;
|
|
|
131
131
|
function Is() {
|
|
132
132
|
return wr || (wr = 1, process.env.NODE_ENV !== "production" && function() {
|
|
133
133
|
var t = Y, e = Symbol.for("react.element"), n = Symbol.for("react.portal"), r = Symbol.for("react.fragment"), s = Symbol.for("react.strict_mode"), i = Symbol.for("react.profiler"), o = Symbol.for("react.provider"), c = Symbol.for("react.context"), d = Symbol.for("react.forward_ref"), l = Symbol.for("react.suspense"), u = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), m = Symbol.for("react.lazy"), p = Symbol.for("react.offscreen"), g = Symbol.iterator, v = "@@iterator";
|
|
134
|
-
function
|
|
134
|
+
function _(h) {
|
|
135
135
|
if (h === null || typeof h != "object")
|
|
136
136
|
return null;
|
|
137
137
|
var M = g && h[g] || h[v];
|
|
138
138
|
return typeof M == "function" ? M : null;
|
|
139
139
|
}
|
|
140
|
-
var
|
|
140
|
+
var y = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
141
141
|
function x(h) {
|
|
142
142
|
{
|
|
143
143
|
for (var M = arguments.length, I = new Array(M > 1 ? M - 1 : 0), ne = 1; ne < M; ne++)
|
|
144
144
|
I[ne - 1] = arguments[ne];
|
|
145
|
-
|
|
145
|
+
S("error", h, I);
|
|
146
146
|
}
|
|
147
147
|
}
|
|
148
|
-
function
|
|
148
|
+
function S(h, M, I) {
|
|
149
149
|
{
|
|
150
|
-
var ne =
|
|
150
|
+
var ne = y.ReactDebugCurrentFrame, le = ne.getStackAddendum();
|
|
151
151
|
le !== "" && (M += "%s", I = I.concat([le]));
|
|
152
152
|
var me = I.map(function(ce) {
|
|
153
153
|
return String(ce);
|
|
@@ -155,10 +155,10 @@ function Is() {
|
|
|
155
155
|
me.unshift("Warning: " + M), Function.prototype.apply.call(console[h], console, me);
|
|
156
156
|
}
|
|
157
157
|
}
|
|
158
|
-
var w = !1,
|
|
158
|
+
var w = !1, b = !1, F = !1, R = !1, Q = !1, B;
|
|
159
159
|
B = Symbol.for("react.module.reference");
|
|
160
|
-
function
|
|
161
|
-
return !!(typeof h == "string" || typeof h == "function" || h === r || h === i || Q || h === s || h === l || h === u || R || h === p || w ||
|
|
160
|
+
function N(h) {
|
|
161
|
+
return !!(typeof h == "string" || typeof h == "function" || h === r || h === i || Q || h === s || h === l || h === u || R || h === p || w || b || F || typeof h == "object" && h !== null && (h.$$typeof === m || h.$$typeof === f || h.$$typeof === o || h.$$typeof === c || h.$$typeof === d || // This needs to include all possible module reference object
|
|
162
162
|
// types supported by any Flight configuration anywhere since
|
|
163
163
|
// we don't know which Flight build this will end up being used
|
|
164
164
|
// with.
|
|
@@ -219,7 +219,7 @@ function Is() {
|
|
|
219
219
|
}
|
|
220
220
|
return null;
|
|
221
221
|
}
|
|
222
|
-
var
|
|
222
|
+
var $ = Object.assign, A = 0, W, Z, z, K, T, P, q;
|
|
223
223
|
function L() {
|
|
224
224
|
}
|
|
225
225
|
L.__reactDisabledLog = !0;
|
|
@@ -255,25 +255,25 @@ function Is() {
|
|
|
255
255
|
writable: !0
|
|
256
256
|
};
|
|
257
257
|
Object.defineProperties(console, {
|
|
258
|
-
log:
|
|
258
|
+
log: $({}, h, {
|
|
259
259
|
value: W
|
|
260
260
|
}),
|
|
261
|
-
info:
|
|
261
|
+
info: $({}, h, {
|
|
262
262
|
value: Z
|
|
263
263
|
}),
|
|
264
|
-
warn:
|
|
264
|
+
warn: $({}, h, {
|
|
265
265
|
value: z
|
|
266
266
|
}),
|
|
267
|
-
error:
|
|
267
|
+
error: $({}, h, {
|
|
268
268
|
value: K
|
|
269
269
|
}),
|
|
270
|
-
group:
|
|
270
|
+
group: $({}, h, {
|
|
271
271
|
value: T
|
|
272
272
|
}),
|
|
273
|
-
groupCollapsed:
|
|
273
|
+
groupCollapsed: $({}, h, {
|
|
274
274
|
value: P
|
|
275
275
|
}),
|
|
276
|
-
groupEnd:
|
|
276
|
+
groupEnd: $({}, h, {
|
|
277
277
|
value: q
|
|
278
278
|
})
|
|
279
279
|
});
|
|
@@ -281,7 +281,7 @@ function Is() {
|
|
|
281
281
|
A < 0 && x("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
|
|
282
282
|
}
|
|
283
283
|
}
|
|
284
|
-
var G =
|
|
284
|
+
var G = y.ReactCurrentDispatcher, V;
|
|
285
285
|
function ee(h, M, I) {
|
|
286
286
|
{
|
|
287
287
|
if (V === void 0)
|
|
@@ -374,7 +374,7 @@ function Is() {
|
|
|
374
374
|
function ve(h, M, I) {
|
|
375
375
|
return D(h, !1);
|
|
376
376
|
}
|
|
377
|
-
function
|
|
377
|
+
function $e(h) {
|
|
378
378
|
var M = h.prototype;
|
|
379
379
|
return !!(M && M.isReactComponent);
|
|
380
380
|
}
|
|
@@ -382,7 +382,7 @@ function Is() {
|
|
|
382
382
|
if (h == null)
|
|
383
383
|
return "";
|
|
384
384
|
if (typeof h == "function")
|
|
385
|
-
return D(h,
|
|
385
|
+
return D(h, $e(h));
|
|
386
386
|
if (typeof h == "string")
|
|
387
387
|
return ee(h);
|
|
388
388
|
switch (h) {
|
|
@@ -407,7 +407,7 @@ function Is() {
|
|
|
407
407
|
}
|
|
408
408
|
return "";
|
|
409
409
|
}
|
|
410
|
-
var Ue = Object.prototype.hasOwnProperty, cr = {}, lr =
|
|
410
|
+
var Ue = Object.prototype.hasOwnProperty, cr = {}, lr = y.ReactDebugCurrentFrame;
|
|
411
411
|
function Et(h) {
|
|
412
412
|
if (h) {
|
|
413
413
|
var M = h._owner, I = Ce(h.type, h._source, M ? M.type : null);
|
|
@@ -458,7 +458,7 @@ function Is() {
|
|
|
458
458
|
if (as(h))
|
|
459
459
|
return x("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", rs(h)), ur(h);
|
|
460
460
|
}
|
|
461
|
-
var st =
|
|
461
|
+
var st = y.ReactCurrentOwner, ss = {
|
|
462
462
|
key: !0,
|
|
463
463
|
ref: !0,
|
|
464
464
|
__self: !0,
|
|
@@ -556,7 +556,7 @@ function Is() {
|
|
|
556
556
|
return ds(h, ie, xe, le, ne, st.current, ce);
|
|
557
557
|
}
|
|
558
558
|
}
|
|
559
|
-
var dn =
|
|
559
|
+
var dn = y.ReactCurrentOwner, pr = y.ReactDebugCurrentFrame;
|
|
560
560
|
function Ke(h) {
|
|
561
561
|
if (h) {
|
|
562
562
|
var M = h._owner, I = Ce(h.type, h._source, M ? M.type : null);
|
|
@@ -630,7 +630,7 @@ Check the top-level render call using <` + I + ">.");
|
|
|
630
630
|
else if (mn(h))
|
|
631
631
|
h._store && (h._store.validated = !0);
|
|
632
632
|
else if (h) {
|
|
633
|
-
var le =
|
|
633
|
+
var le = _(h);
|
|
634
634
|
if (typeof le == "function" && le !== h.entries)
|
|
635
635
|
for (var me = le.call(h), ce; !(ce = me.next()).done; )
|
|
636
636
|
mn(ce.value) && vr(ce.value, M);
|
|
@@ -676,7 +676,7 @@ Check the top-level render call using <` + I + ">.");
|
|
|
676
676
|
}
|
|
677
677
|
function yr(h, M, I, ne, le, me) {
|
|
678
678
|
{
|
|
679
|
-
var ce =
|
|
679
|
+
var ce = N(h);
|
|
680
680
|
if (!ce) {
|
|
681
681
|
var ie = "";
|
|
682
682
|
(h === void 0 || typeof h == "object" && h !== null && Object.keys(h).length === 0) && (ie += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
|
|
@@ -737,43 +737,43 @@ function Bs(t, e, n) {
|
|
|
737
737
|
if (typeof t != "function")
|
|
738
738
|
throw new TypeError("Expected a function");
|
|
739
739
|
e = +e || 0;
|
|
740
|
-
var g = !!(n = n || {}).leading, v = !("trailing" in n) || !!n.trailing,
|
|
740
|
+
var g = !!(n = n || {}).leading, v = !("trailing" in n) || !!n.trailing, _ = "maxWait" in n, y = "debounceOnServer" in n && !!n.debounceOnServer, x = _ ? Math.max(+n.maxWait || 0, e) : null;
|
|
741
741
|
ae(function() {
|
|
742
742
|
return f.current = !0, function() {
|
|
743
743
|
f.current = !1;
|
|
744
744
|
};
|
|
745
745
|
}, []);
|
|
746
|
-
var
|
|
747
|
-
var w = function(
|
|
746
|
+
var S = wt(function() {
|
|
747
|
+
var w = function(N) {
|
|
748
748
|
var C = c.current, k = d.current;
|
|
749
|
-
return c.current = d.current = null, i.current =
|
|
750
|
-
},
|
|
751
|
-
p && cancelAnimationFrame(o.current), o.current = p ? requestAnimationFrame(
|
|
752
|
-
}, F = function(
|
|
749
|
+
return c.current = d.current = null, i.current = N, l.current = u.current.apply(k, C);
|
|
750
|
+
}, b = function(N, C) {
|
|
751
|
+
p && cancelAnimationFrame(o.current), o.current = p ? requestAnimationFrame(N) : setTimeout(N, C);
|
|
752
|
+
}, F = function(N) {
|
|
753
753
|
if (!f.current)
|
|
754
754
|
return !1;
|
|
755
|
-
var C =
|
|
756
|
-
return !s.current || C >= e || C < 0 ||
|
|
757
|
-
}, R = function(
|
|
758
|
-
return o.current = null, v && c.current ? w(
|
|
759
|
-
}, Q = function
|
|
755
|
+
var C = N - s.current;
|
|
756
|
+
return !s.current || C >= e || C < 0 || _ && N - i.current >= x;
|
|
757
|
+
}, R = function(N) {
|
|
758
|
+
return o.current = null, v && c.current ? w(N) : (c.current = d.current = null, l.current);
|
|
759
|
+
}, Q = function N() {
|
|
760
760
|
var C = Date.now();
|
|
761
761
|
if (F(C))
|
|
762
762
|
return R(C);
|
|
763
763
|
if (f.current) {
|
|
764
|
-
var k = e - (C - s.current), j =
|
|
765
|
-
|
|
764
|
+
var k = e - (C - s.current), j = _ ? Math.min(k, x - (C - i.current)) : k;
|
|
765
|
+
b(N, j);
|
|
766
766
|
}
|
|
767
767
|
}, B = function() {
|
|
768
|
-
if (m ||
|
|
769
|
-
var
|
|
770
|
-
if (c.current = [].slice.call(arguments), d.current = r, s.current =
|
|
768
|
+
if (m || y) {
|
|
769
|
+
var N = Date.now(), C = F(N);
|
|
770
|
+
if (c.current = [].slice.call(arguments), d.current = r, s.current = N, C) {
|
|
771
771
|
if (!o.current && f.current)
|
|
772
|
-
return i.current = s.current,
|
|
773
|
-
if (
|
|
774
|
-
return
|
|
772
|
+
return i.current = s.current, b(Q, e), g ? w(s.current) : l.current;
|
|
773
|
+
if (_)
|
|
774
|
+
return b(Q, e), w(s.current);
|
|
775
775
|
}
|
|
776
|
-
return o.current ||
|
|
776
|
+
return o.current || b(Q, e), l.current;
|
|
777
777
|
}
|
|
778
778
|
};
|
|
779
779
|
return B.cancel = function() {
|
|
@@ -783,8 +783,8 @@ function Bs(t, e, n) {
|
|
|
783
783
|
}, B.flush = function() {
|
|
784
784
|
return o.current ? R(Date.now()) : l.current;
|
|
785
785
|
}, B;
|
|
786
|
-
}, [g,
|
|
787
|
-
return
|
|
786
|
+
}, [g, _, e, x, v, p, m, y]);
|
|
787
|
+
return S;
|
|
788
788
|
}
|
|
789
789
|
function fa(t, e, n) {
|
|
790
790
|
var r = n === void 0 ? {} : n, s = r.leading, i = r.trailing;
|
|
@@ -895,7 +895,7 @@ const jt = (t = !0, e = !1, n = "window") => {
|
|
|
895
895
|
ARTICLE: "microcourseArticle",
|
|
896
896
|
DISCUSSION: "microcourseDiscussion",
|
|
897
897
|
QUIZ: "assessmentQuiz"
|
|
898
|
-
},
|
|
898
|
+
}, Nl = "200,000+";
|
|
899
899
|
function Hs(t) {
|
|
900
900
|
return t ? {
|
|
901
901
|
"--icon": `url(${Be}icons/${t}.svg)`
|
|
@@ -983,10 +983,13 @@ const ze = {
|
|
|
983
983
|
card_member_type_member: "Member",
|
|
984
984
|
card_member_count: "{count} members",
|
|
985
985
|
card_cta_people: "View profile",
|
|
986
|
+
card_cta_communityPage: "Join now",
|
|
986
987
|
card_cta_event: "Register now",
|
|
987
988
|
card_cta_microcourse: "Enrol now",
|
|
989
|
+
card_cta_communityPage_loading: "Joining...",
|
|
988
990
|
card_cta_event_loading: "Registering...",
|
|
989
991
|
card_cta_microcourse_loading: "Enrolling...",
|
|
992
|
+
card_cta_communityPage_done: "Joined",
|
|
990
993
|
card_cta_event_done: "Registered",
|
|
991
994
|
card_cta_microcourse_done: "Enrolled",
|
|
992
995
|
carousel_pagination_previous: "Previous",
|
|
@@ -1218,7 +1221,7 @@ Thank you for helping to protect the Apolitical community from abusive content.`
|
|
|
1218
1221
|
timeToComplete_range_aria: "between {early} and {late}",
|
|
1219
1222
|
tooltip_loading: "Loading...",
|
|
1220
1223
|
return_to_nav_button: "Back to top",
|
|
1221
|
-
|
|
1224
|
+
progressTracker: "Step {current} of {total}",
|
|
1222
1225
|
/* Layout */
|
|
1223
1226
|
cookieBanner_title: "Cookies and your privacy",
|
|
1224
1227
|
cookieBanner_text: "We take your trust and privacy very seriously. Apolitical uses safe cookies (small files on your device) to run the site. You can reject non-essential cookies, but some site features may not work without them.",
|
|
@@ -1237,6 +1240,7 @@ Thank you for helping to protect the Apolitical community from abusive content.`
|
|
|
1237
1240
|
footer_community_join: "Who can join",
|
|
1238
1241
|
footer_community_guidelines: "Guidelines & values",
|
|
1239
1242
|
footer_company: "Company",
|
|
1243
|
+
footer_company_news: "News",
|
|
1240
1244
|
footer_company_story: "Our story",
|
|
1241
1245
|
footer_company_team: "Meet our team",
|
|
1242
1246
|
footer_company_careers: "Careers",
|
|
@@ -1401,7 +1405,7 @@ Thank you for helping to protect the Apolitical community from abusive content.`
|
|
|
1401
1405
|
es: Gs,
|
|
1402
1406
|
fr: Qs,
|
|
1403
1407
|
pt: Js
|
|
1404
|
-
}, Symbol.toStringTag, { value: "Module" })), Qn = (t, e = rt) => t in e,
|
|
1408
|
+
}, Symbol.toStringTag, { value: "Module" })), Qn = (t, e = rt) => t in e, Ne = (t, e, n, r, s = {}) => {
|
|
1405
1409
|
let i = "";
|
|
1406
1410
|
return Qn(`${e}_${n}`) ? i = t({ id: `${e}_${n}` }, s) : i = t({ id: e }, { [r]: n, ...s }), i;
|
|
1407
1411
|
}, ei = (t, e, n) => {
|
|
@@ -1451,20 +1455,20 @@ Thank you for helping to protect the Apolitical community from abusive content.`
|
|
|
1451
1455
|
}) => {
|
|
1452
1456
|
const p = jt(typeof e == "object");
|
|
1453
1457
|
if (typeof e == "object" && typeof p == "number") {
|
|
1454
|
-
const
|
|
1455
|
-
e = ha(p,
|
|
1458
|
+
const _ = Object.assign({}, e), y = pa(Object.keys(_));
|
|
1459
|
+
e = ha(p, y, _);
|
|
1456
1460
|
}
|
|
1457
1461
|
const g = [];
|
|
1458
1462
|
typeof e == "string" && g.push(e), r && (g.push("icon"), typeof r == "object" ? (g.push(r.icon), r.position ? g.push(r.position) : g.push("left"), r.hover && g.push(`hover_${r.hover}`), r.animate && (g.push("animate"), typeof r.animate == "string" && g.push(r.animate))) : (g.push(r), !r.includes("right") && !r.includes("left") && g.push("left"))), n.muted && g.push("muted"), n.fullWidth && g.push("full-width");
|
|
1459
1463
|
const v = {
|
|
1460
1464
|
...f,
|
|
1461
|
-
className:
|
|
1465
|
+
className: E(t, c, g, {
|
|
1462
1466
|
"no-text": !u,
|
|
1463
1467
|
disabled: d,
|
|
1464
1468
|
button: s
|
|
1465
1469
|
}),
|
|
1466
|
-
onClick: (
|
|
1467
|
-
(!s || s[0] === "#") && o && (
|
|
1470
|
+
onClick: (_) => {
|
|
1471
|
+
(!s || s[0] === "#") && o && (_.preventDefault(), _.stopPropagation()), o && o(_);
|
|
1468
1472
|
},
|
|
1469
1473
|
disabled: typeof d == "object" && "isClickable" in d ? !d.isClickable : d
|
|
1470
1474
|
};
|
|
@@ -1476,14 +1480,14 @@ Thank you for helping to protect the Apolitical community from abusive content.`
|
|
|
1476
1480
|
}, kt = ({ buttons: t, className: e = "", ...n }) => {
|
|
1477
1481
|
const r = t.length > 1 ? "ul" : "p", s = t.map((i, o) => r === "p" ? /* @__PURE__ */ a.jsx(se, { ...i }, o) : /* @__PURE__ */ a.jsx("li", { children: /* @__PURE__ */ a.jsx(se, { ...i }) }, o));
|
|
1478
1482
|
return Y.createElement(r, {
|
|
1479
|
-
className:
|
|
1483
|
+
className: E("button-wrapper", e),
|
|
1480
1484
|
...n,
|
|
1481
1485
|
children: s
|
|
1482
1486
|
});
|
|
1483
1487
|
};
|
|
1484
1488
|
const Oe = ({ className: t = "", maxWidth: e = !1 }) => {
|
|
1485
1489
|
const n = e ? { "--max-width": `${e / 16}rem` } : {};
|
|
1486
|
-
return /* @__PURE__ */ a.jsx("hr", { className:
|
|
1490
|
+
return /* @__PURE__ */ a.jsx("hr", { className: E(t, { "has-max-width": e }), style: n });
|
|
1487
1491
|
}, kr = {
|
|
1488
1492
|
card: {
|
|
1489
1493
|
range: [
|
|
@@ -1614,7 +1618,7 @@ const Tt = ({ image: t, className: e, testId: n }) => {
|
|
|
1614
1618
|
loading: l,
|
|
1615
1619
|
decoding: u,
|
|
1616
1620
|
fetchPriority: f
|
|
1617
|
-
} = t, { range: m, sizes: p } = ri(t), g = hn({ format: "avif", query: o, range: m, url: c }), v = hn({ format: "webp", query: o, range: m, url: c }),
|
|
1621
|
+
} = t, { range: m, sizes: p } = ri(t), g = hn({ format: "avif", query: o, range: m, url: c }), v = hn({ format: "webp", query: o, range: m, url: c }), _ = hn({ format: "", query: o, range: m, url: c });
|
|
1618
1622
|
return /* @__PURE__ */ a.jsxs("picture", { className: e, children: [
|
|
1619
1623
|
i !== "image/gif" && /* @__PURE__ */ a.jsx(
|
|
1620
1624
|
"source",
|
|
@@ -1629,7 +1633,7 @@ const Tt = ({ image: t, className: e, testId: n }) => {
|
|
|
1629
1633
|
/* @__PURE__ */ a.jsx(
|
|
1630
1634
|
"img",
|
|
1631
1635
|
{
|
|
1632
|
-
srcSet:
|
|
1636
|
+
srcSet: _,
|
|
1633
1637
|
sizes: p,
|
|
1634
1638
|
src: c,
|
|
1635
1639
|
alt: r,
|
|
@@ -1643,7 +1647,7 @@ const Tt = ({ image: t, className: e, testId: n }) => {
|
|
|
1643
1647
|
)
|
|
1644
1648
|
] });
|
|
1645
1649
|
};
|
|
1646
|
-
const
|
|
1650
|
+
const $l = ({ image: t, className: e = "", testId: n }) => /* @__PURE__ */ a.jsx(
|
|
1647
1651
|
"div",
|
|
1648
1652
|
{
|
|
1649
1653
|
className: `image-container ${e}`,
|
|
@@ -1662,7 +1666,7 @@ const Nl = ({ image: t, className: e, testId: n }) => /* @__PURE__ */ a.jsx(
|
|
|
1662
1666
|
}) => {
|
|
1663
1667
|
if (t) {
|
|
1664
1668
|
const d = { ...c };
|
|
1665
|
-
return s && (d.onClick = s), i && (d["data-gtm-event-context"] = i), o && (d["data-gtm-event-type"] = o), /* @__PURE__ */ a.jsx("a", { href: t, className:
|
|
1669
|
+
return s && (d.onClick = s), i && (d["data-gtm-event-context"] = i), o && (d["data-gtm-event-type"] = o), /* @__PURE__ */ a.jsx("a", { href: t, className: E("gtm-trackable", r), ...d, children: e });
|
|
1666
1670
|
}
|
|
1667
1671
|
return n ? Y.createElement(n, { children: e, className: r, ...c }) : /* @__PURE__ */ a.jsx(a.Fragment, { children: e });
|
|
1668
1672
|
};
|
|
@@ -1670,8 +1674,8 @@ const Pl = ({ currentStep: t = 1, steps: e = 1 }) => /* @__PURE__ */ a.jsxs(a.Fr
|
|
|
1670
1674
|
/* @__PURE__ */ a.jsx(be, { children: /* @__PURE__ */ a.jsx(
|
|
1671
1675
|
ye,
|
|
1672
1676
|
{
|
|
1673
|
-
id: "
|
|
1674
|
-
values: {
|
|
1677
|
+
id: "progressTracker",
|
|
1678
|
+
values: { current: t, total: e }
|
|
1675
1679
|
}
|
|
1676
1680
|
) }),
|
|
1677
1681
|
/* @__PURE__ */ a.jsx("div", { className: "progress-tracker", children: /* @__PURE__ */ a.jsx("div", { className: "dots-wrapper", children: new Array(e).fill("").map((n, r) => {
|
|
@@ -1680,7 +1684,7 @@ const Pl = ({ currentStep: t = 1, steps: e = 1 }) => /* @__PURE__ */ a.jsxs(a.Fr
|
|
|
1680
1684
|
/* @__PURE__ */ a.jsx(
|
|
1681
1685
|
"div",
|
|
1682
1686
|
{
|
|
1683
|
-
className:
|
|
1687
|
+
className: E("dot", {
|
|
1684
1688
|
active: s === t,
|
|
1685
1689
|
completed: s < t
|
|
1686
1690
|
}),
|
|
@@ -1690,7 +1694,7 @@ const Pl = ({ currentStep: t = 1, steps: e = 1 }) => /* @__PURE__ */ a.jsxs(a.Fr
|
|
|
1690
1694
|
/* @__PURE__ */ a.jsx(
|
|
1691
1695
|
"div",
|
|
1692
1696
|
{
|
|
1693
|
-
className:
|
|
1697
|
+
className: E("line", {
|
|
1694
1698
|
active: s < t
|
|
1695
1699
|
})
|
|
1696
1700
|
}
|
|
@@ -1779,7 +1783,7 @@ const Jn = ({
|
|
|
1779
1783
|
"details",
|
|
1780
1784
|
{
|
|
1781
1785
|
ref: i,
|
|
1782
|
-
className:
|
|
1786
|
+
className: E("collapsible-section", e, {
|
|
1783
1787
|
"should-animate": r
|
|
1784
1788
|
}),
|
|
1785
1789
|
children: [
|
|
@@ -1816,7 +1820,7 @@ const Cr = {
|
|
|
1816
1820
|
return !n && !o ? null : /* @__PURE__ */ a.jsx(
|
|
1817
1821
|
"small",
|
|
1818
1822
|
{
|
|
1819
|
-
className:
|
|
1823
|
+
className: E(
|
|
1820
1824
|
"content-type-label text-small",
|
|
1821
1825
|
t in Cr ? Cr[t] : t,
|
|
1822
1826
|
r,
|
|
@@ -1842,7 +1846,7 @@ const Fe = ({
|
|
|
1842
1846
|
return /* @__PURE__ */ a.jsx(
|
|
1843
1847
|
"div",
|
|
1844
1848
|
{
|
|
1845
|
-
className:
|
|
1849
|
+
className: E("highlighted-text-box", t, r, {
|
|
1846
1850
|
"has-icon": e,
|
|
1847
1851
|
"show-highlight": o,
|
|
1848
1852
|
[c]: c !== "default"
|
|
@@ -1875,7 +1879,7 @@ const He = ({
|
|
|
1875
1879
|
Fe,
|
|
1876
1880
|
{
|
|
1877
1881
|
variant: "subtle",
|
|
1878
|
-
className:
|
|
1882
|
+
className: E("empty-state-box", t, r),
|
|
1879
1883
|
children: /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
1880
1884
|
e && typeof e == "string" ? /* @__PURE__ */ a.jsx(Le, { options: { forceBlock: !0 }, children: e }) : e,
|
|
1881
1885
|
s && typeof n == "object" && (l || /* @__PURE__ */ a.jsx(
|
|
@@ -1898,7 +1902,7 @@ const ci = ({
|
|
|
1898
1902
|
className: e = "",
|
|
1899
1903
|
heading: n = !1,
|
|
1900
1904
|
children: r
|
|
1901
|
-
}) => /* @__PURE__ */ a.jsxs("div", { className:
|
|
1905
|
+
}) => /* @__PURE__ */ a.jsxs("div", { className: E("helper-text-box text-small", t, e), children: [
|
|
1902
1906
|
n && /* @__PURE__ */ a.jsx("p", { className: "title", children: n }),
|
|
1903
1907
|
typeof r == "string" ? /* @__PURE__ */ a.jsx(
|
|
1904
1908
|
Le,
|
|
@@ -1948,9 +1952,9 @@ const Rl = ({
|
|
|
1948
1952
|
Fe,
|
|
1949
1953
|
{
|
|
1950
1954
|
variant: "subtle",
|
|
1951
|
-
className:
|
|
1955
|
+
className: E("hide-show-text-box", t),
|
|
1952
1956
|
children: [
|
|
1953
|
-
/* @__PURE__ */ a.jsxs("div", { ref: o, className:
|
|
1957
|
+
/* @__PURE__ */ a.jsxs("div", { ref: o, className: E("content", l), children: [
|
|
1954
1958
|
/* @__PURE__ */ a.jsx(Le, { options: { forceBlock: !0 }, children: l === "closed" ? c : r }),
|
|
1955
1959
|
l !== "closed" && s
|
|
1956
1960
|
] }),
|
|
@@ -1960,7 +1964,7 @@ const Rl = ({
|
|
|
1960
1964
|
variant: "tertiary",
|
|
1961
1965
|
icon: { icon: "navigation_arrow", position: "left", animate: !0 },
|
|
1962
1966
|
styling: { muted: !0 },
|
|
1963
|
-
className:
|
|
1967
|
+
className: E({ "rotate-180": m }),
|
|
1964
1968
|
onClick: () => {
|
|
1965
1969
|
u(m ? "ready-to-close" : "opening");
|
|
1966
1970
|
},
|
|
@@ -1981,7 +1985,7 @@ const Fl = ({
|
|
|
1981
1985
|
}) => {
|
|
1982
1986
|
const { hasBorder: o = !1, zebraStriping: c = !1 } = s;
|
|
1983
1987
|
return Y.createElement(t, {
|
|
1984
|
-
className:
|
|
1988
|
+
className: E("icon-bulleted-list text-medium", n, i, {
|
|
1985
1989
|
"has-border": o,
|
|
1986
1990
|
"has-zebra-stripes": c,
|
|
1987
1991
|
[e]: t !== "dl"
|
|
@@ -2067,7 +2071,7 @@ const Fl = ({
|
|
|
2067
2071
|
),
|
|
2068
2072
|
/* @__PURE__ */ a.jsx("span", { id: `content-after-iframe-${n}`, tabIndex: -1 })
|
|
2069
2073
|
] });
|
|
2070
|
-
},
|
|
2074
|
+
}, Nr = (t) => {
|
|
2071
2075
|
let e = "";
|
|
2072
2076
|
return t && typeof t != "string" && typeof t != "number" && typeof t != "boolean" && "type" in t && (e = t.type), e;
|
|
2073
2077
|
}, hi = ({
|
|
@@ -2081,9 +2085,9 @@ const Fl = ({
|
|
|
2081
2085
|
if (!(!i || typeof i == "string" || typeof i == "number") && Y.isValidElement(i)) {
|
|
2082
2086
|
const o = i.type;
|
|
2083
2087
|
if (["button", "center", "span", "strong"].includes(o) && i.props && i.props.children && i.props.children[0])
|
|
2084
|
-
for ((o === "button" ||
|
|
2088
|
+
for ((o === "button" || Nr(i.props.children[0]) === "button") && (s = !0), r = i.props.children[0]; r && typeof r != "string" && !(typeof r == "boolean" || typeof r == "number" || !Y.isValidElement(r)); )
|
|
2085
2089
|
if (r.props && r.props.children && r.props.children[0])
|
|
2086
|
-
r = r.props.children[0], r &&
|
|
2090
|
+
r = r.props.children[0], r && Nr(r) === "button" && (s = !0);
|
|
2087
2091
|
else
|
|
2088
2092
|
break;
|
|
2089
2093
|
}
|
|
@@ -2139,7 +2143,7 @@ const vi = {
|
|
|
2139
2143
|
return /* @__PURE__ */ a.jsx(
|
|
2140
2144
|
"div",
|
|
2141
2145
|
{
|
|
2142
|
-
className:
|
|
2146
|
+
className: E("markdown-text", t, {
|
|
2143
2147
|
"highlight-titles": i
|
|
2144
2148
|
}),
|
|
2145
2149
|
children: /* @__PURE__ */ a.jsx(Le, { options: { ...o, ...e }, children: n })
|
|
@@ -2154,8 +2158,8 @@ const bi = ({
|
|
|
2154
2158
|
className: s = ""
|
|
2155
2159
|
}) => {
|
|
2156
2160
|
const i = t ? { "--max-width": `${t / 16}rem` } : {};
|
|
2157
|
-
return /* @__PURE__ */ a.jsxs("section", { className:
|
|
2158
|
-
/* @__PURE__ */ a.jsxs("div", { className:
|
|
2161
|
+
return /* @__PURE__ */ a.jsxs("section", { className: E("page-heading", s), children: [
|
|
2162
|
+
/* @__PURE__ */ a.jsxs("div", { className: E("content", { "has-max-width": t }), style: i, children: [
|
|
2159
2163
|
e && e.text && Y.createElement(e.element || "h1", { className: "title" }, e.text),
|
|
2160
2164
|
n && n.text && Y.createElement(
|
|
2161
2165
|
n.element || "h2",
|
|
@@ -2180,7 +2184,7 @@ const ht = ({
|
|
|
2180
2184
|
return /* @__PURE__ */ a.jsx(
|
|
2181
2185
|
"span",
|
|
2182
2186
|
{
|
|
2183
|
-
className:
|
|
2187
|
+
className: E("pill", t, e, n, {
|
|
2184
2188
|
"has-icon": r
|
|
2185
2189
|
}),
|
|
2186
2190
|
style: o,
|
|
@@ -2198,7 +2202,7 @@ const Wt = ({
|
|
|
2198
2202
|
t,
|
|
2199
2203
|
{
|
|
2200
2204
|
...r,
|
|
2201
|
-
className:
|
|
2205
|
+
className: E("status-banner text-small", n),
|
|
2202
2206
|
"aria-live": "assertive"
|
|
2203
2207
|
},
|
|
2204
2208
|
e
|
|
@@ -2232,7 +2236,7 @@ const Al = ({
|
|
|
2232
2236
|
Fe,
|
|
2233
2237
|
{
|
|
2234
2238
|
variant: "subtle",
|
|
2235
|
-
className:
|
|
2239
|
+
className: E("table-of-contents", n),
|
|
2236
2240
|
children: [
|
|
2237
2241
|
/* @__PURE__ */ a.jsx("h2", { children: r.formatMessage({ id: "tableOfContents" }) }),
|
|
2238
2242
|
/* @__PURE__ */ a.jsx("nav", { children: /* @__PURE__ */ a.jsx("ul", { children: s.map(({ id: o, text: c }) => /* @__PURE__ */ a.jsx("li", { children: /* @__PURE__ */ a.jsx("a", { href: `#${o}`, children: c }) }, o)) }) })
|
|
@@ -2274,11 +2278,11 @@ const Xn = ({
|
|
|
2274
2278
|
{ early: l, late: f }
|
|
2275
2279
|
);
|
|
2276
2280
|
}
|
|
2277
|
-
return n && (l = `${n} ${l}`, d = `${n} ${d}`), r && (l = `${l} ${r}`, d = `${d} ${r}`), /* @__PURE__ */ a.jsx("span", { className:
|
|
2281
|
+
return n && (l = `${n} ${l}`, d = `${n} ${d}`), r && (l = `${l} ${r}`, d = `${d} ${r}`), /* @__PURE__ */ a.jsx("span", { className: E("time-to-complete", s), "aria-label": l, children: d });
|
|
2278
2282
|
};
|
|
2279
2283
|
let ct = !1;
|
|
2280
2284
|
const _i = ({ isOpen: t = !1, isLoading: e = !1, children: n }) => {
|
|
2281
|
-
const r = H(), s = pe(null), [i, o] = X("hidden");
|
|
2285
|
+
const r = H(), s = pe(null), [i, o] = X(t ? "open" : "hidden");
|
|
2282
2286
|
ae(() => {
|
|
2283
2287
|
const d = s.current;
|
|
2284
2288
|
if (d)
|
|
@@ -2299,7 +2303,7 @@ const _i = ({ isOpen: t = !1, isLoading: e = !1, children: n }) => {
|
|
|
2299
2303
|
"aside",
|
|
2300
2304
|
{
|
|
2301
2305
|
ref: s,
|
|
2302
|
-
className:
|
|
2306
|
+
className: E("tooltip text-medium", i, { loading: e }),
|
|
2303
2307
|
hidden: i === "hidden",
|
|
2304
2308
|
children: e ? /* @__PURE__ */ a.jsx("p", { children: r.formatMessage({ id: "tooltip_loading" }) }) : typeof n == "string" ? /* @__PURE__ */ a.jsx("p", { children: n }) : n
|
|
2305
2309
|
}
|
|
@@ -2318,7 +2322,7 @@ const Dl = ({ className: t = "", image: e, ...n }) => e ? (typeof e == "string"
|
|
|
2318
2322
|
Tt,
|
|
2319
2323
|
{
|
|
2320
2324
|
...n,
|
|
2321
|
-
className:
|
|
2325
|
+
className: E("banner", t),
|
|
2322
2326
|
image: { ...e, aspect: "banner" }
|
|
2323
2327
|
}
|
|
2324
2328
|
)) : null;
|
|
@@ -2332,7 +2336,7 @@ const Ve = ({
|
|
|
2332
2336
|
return /* @__PURE__ */ a.jsx(
|
|
2333
2337
|
"section",
|
|
2334
2338
|
{
|
|
2335
|
-
className:
|
|
2339
|
+
className: E("full-width-section", e, {
|
|
2336
2340
|
[s]: s !== "default"
|
|
2337
2341
|
}),
|
|
2338
2342
|
...r,
|
|
@@ -2353,7 +2357,7 @@ const Il = ({ text: t, buttons: e, className: n = "" }) => {
|
|
|
2353
2357
|
target: "_blank",
|
|
2354
2358
|
children: s.text
|
|
2355
2359
|
});
|
|
2356
|
-
}), /* @__PURE__ */ a.jsx(Ve, { className:
|
|
2360
|
+
}), /* @__PURE__ */ a.jsx(Ve, { className: E("download-section", n), children: /* @__PURE__ */ a.jsxs("div", { className: "content-default", children: [
|
|
2357
2361
|
Y.createElement(
|
|
2358
2362
|
typeof t == "string" ? "h2" : t.element,
|
|
2359
2363
|
{ className: "text" },
|
|
@@ -2367,7 +2371,7 @@ function ba({ href: t, setShowModal: e }) {
|
|
|
2367
2371
|
}
|
|
2368
2372
|
const xi = ({ icon: t, description: e, ctaMessage: n, href: r, showEditButton: s, setShowModal: i }) => {
|
|
2369
2373
|
const { formatMessage: o } = H();
|
|
2370
|
-
return /* @__PURE__ */ a.jsxs("div", { className:
|
|
2374
|
+
return /* @__PURE__ */ a.jsxs("div", { className: E("edit-section-placeholder", { "has-icon": !!t }), style: Hs(t), children: [
|
|
2371
2375
|
/* @__PURE__ */ a.jsx("p", { children: e || o({ id: "edit_section_placeholder_description" }) }),
|
|
2372
2376
|
s && /* @__PURE__ */ a.jsx(se, { href: r, variant: "secondary", size: "small", onClick: () => ba({ href: r, setShowModal: i }), children: n || o({ id: "edit_section_placeholder_cta" }) })
|
|
2373
2377
|
] });
|
|
@@ -2382,7 +2386,7 @@ const xi = ({ icon: t, description: e, ctaMessage: n, href: r, showEditButton: s
|
|
|
2382
2386
|
showDivider: c = !0
|
|
2383
2387
|
}) => {
|
|
2384
2388
|
const [d, l] = Y.useState(!1), u = typeof r == "string" || !!n, f = () => l(!1);
|
|
2385
|
-
return /* @__PURE__ */ a.jsxs("section", { className:
|
|
2389
|
+
return /* @__PURE__ */ a.jsxs("section", { className: E("edit-section", e), children: [
|
|
2386
2390
|
n && /* @__PURE__ */ a.jsx(
|
|
2387
2391
|
an,
|
|
2388
2392
|
{
|
|
@@ -2391,7 +2395,7 @@ const xi = ({ icon: t, description: e, ctaMessage: n, href: r, showEditButton: s
|
|
|
2391
2395
|
showDivider: !1,
|
|
2392
2396
|
showIcon: !1,
|
|
2393
2397
|
functions: { onClose: f },
|
|
2394
|
-
className:
|
|
2398
|
+
className: E("edit-section-modal"),
|
|
2395
2399
|
children: /* @__PURE__ */ a.jsx(rn, { ...n, fields: n.fields, meta: {
|
|
2396
2400
|
...n == null ? void 0 : n.meta,
|
|
2397
2401
|
shouldShowCancelButton: !0,
|
|
@@ -2432,20 +2436,20 @@ const Bl = ({
|
|
|
2432
2436
|
return /* @__PURE__ */ a.jsxs(
|
|
2433
2437
|
"div",
|
|
2434
2438
|
{
|
|
2435
|
-
className:
|
|
2439
|
+
className: E("logos", r, `align-${c}`, {
|
|
2436
2440
|
[d]: d !== "block",
|
|
2437
2441
|
"wrap-logos": o
|
|
2438
2442
|
}),
|
|
2439
2443
|
children: [
|
|
2440
2444
|
t && Y.createElement(
|
|
2441
2445
|
i.element,
|
|
2442
|
-
{ className:
|
|
2446
|
+
{ className: E("title", i.className) },
|
|
2443
2447
|
i.text
|
|
2444
2448
|
),
|
|
2445
2449
|
/* @__PURE__ */ a.jsx(
|
|
2446
2450
|
"ul",
|
|
2447
2451
|
{
|
|
2448
|
-
className:
|
|
2452
|
+
className: E({
|
|
2449
2453
|
"two-col": s === 2 || s === 4,
|
|
2450
2454
|
"three-col": s === 5 || s <= 10 && s % 3 === 0
|
|
2451
2455
|
}),
|
|
@@ -2530,7 +2534,7 @@ const wi = [
|
|
|
2530
2534
|
}), /* @__PURE__ */ a.jsx(
|
|
2531
2535
|
Ve,
|
|
2532
2536
|
{
|
|
2533
|
-
className:
|
|
2537
|
+
className: E("banner-section", r, s, t, {
|
|
2534
2538
|
"has-image": n,
|
|
2535
2539
|
"has-extra-spacing": s === "normal" && u.eyebrow && u.title
|
|
2536
2540
|
}),
|
|
@@ -2570,7 +2574,7 @@ const Ul = ({
|
|
|
2570
2574
|
return t && (s["--image"] = `url(${t})`), /* @__PURE__ */ a.jsx(
|
|
2571
2575
|
Ve,
|
|
2572
2576
|
{
|
|
2573
|
-
className:
|
|
2577
|
+
className: E("custom-content-banner", e, r, {
|
|
2574
2578
|
"has-image": t
|
|
2575
2579
|
}),
|
|
2576
2580
|
style: s,
|
|
@@ -2585,11 +2589,11 @@ const ki = ({
|
|
|
2585
2589
|
image: r
|
|
2586
2590
|
}) => {
|
|
2587
2591
|
const s = typeof n == "string" ? /* @__PURE__ */ a.jsx(xt, { children: n }) : n;
|
|
2588
|
-
return /* @__PURE__ */ a.jsxs(Ve, { className:
|
|
2592
|
+
return /* @__PURE__ */ a.jsxs(Ve, { className: E("highlight-section", e), children: [
|
|
2589
2593
|
r && /* @__PURE__ */ a.jsx(
|
|
2590
2594
|
"div",
|
|
2591
2595
|
{
|
|
2592
|
-
className:
|
|
2596
|
+
className: E("highlight-container highlight-image", {
|
|
2593
2597
|
[`highlight-image-${t}`]: t === "right"
|
|
2594
2598
|
}),
|
|
2595
2599
|
children: /* @__PURE__ */ a.jsx(Tt, { image: r })
|
|
@@ -2598,13 +2602,13 @@ const ki = ({
|
|
|
2598
2602
|
/* @__PURE__ */ a.jsx(
|
|
2599
2603
|
"div",
|
|
2600
2604
|
{
|
|
2601
|
-
className:
|
|
2605
|
+
className: E("highlight-container highlight-content-wrapper", {
|
|
2602
2606
|
"no-image": !r
|
|
2603
2607
|
}),
|
|
2604
2608
|
children: /* @__PURE__ */ a.jsx(
|
|
2605
2609
|
"div",
|
|
2606
2610
|
{
|
|
2607
|
-
className:
|
|
2611
|
+
className: E("highlight-content", {
|
|
2608
2612
|
"highlight-content-right": t === "left"
|
|
2609
2613
|
}),
|
|
2610
2614
|
children: r ? s : /* @__PURE__ */ a.jsx("div", { className: "content-default", children: s })
|
|
@@ -2620,7 +2624,7 @@ const zl = ({
|
|
|
2620
2624
|
title: n,
|
|
2621
2625
|
text: r,
|
|
2622
2626
|
gtmContext: s
|
|
2623
|
-
}) => !n && !r ? null : /* @__PURE__ */ a.jsxs("aside", { className:
|
|
2627
|
+
}) => !n && !r ? null : /* @__PURE__ */ a.jsxs("aside", { className: E("marketing-block", t), children: [
|
|
2624
2628
|
n && /* @__PURE__ */ a.jsx("p", { className: "title", children: n }),
|
|
2625
2629
|
r && /* @__PURE__ */ a.jsx("p", { children: r }),
|
|
2626
2630
|
e && /* @__PURE__ */ a.jsx(
|
|
@@ -2678,7 +2682,7 @@ const Ci = ({ children: t, user: e }) => e.isLoading ? null : process.env.REACT_
|
|
|
2678
2682
|
},
|
|
2679
2683
|
children: t
|
|
2680
2684
|
}
|
|
2681
|
-
) : /* @__PURE__ */ a.jsx(a.Fragment, { children: t }),
|
|
2685
|
+
) : /* @__PURE__ */ a.jsx(a.Fragment, { children: t }), Ni = ({ children: t, locale: e, messages: n }) => {
|
|
2682
2686
|
const r = e || "en", s = {
|
|
2683
2687
|
...Xs[r],
|
|
2684
2688
|
...n || {}
|
|
@@ -2693,7 +2697,7 @@ const Ci = ({ children: t, user: e }) => e.isLoading ? null : process.env.REACT_
|
|
|
2693
2697
|
function er() {
|
|
2694
2698
|
return Ee(De);
|
|
2695
2699
|
}
|
|
2696
|
-
const
|
|
2700
|
+
const $i = ({ children: t, user: e }) => /* @__PURE__ */ a.jsx(De.Provider, { value: e, children: t }), Zl = ({ bootstrap: t, children: e, intl: n, showDevTools: r }) => {
|
|
2697
2701
|
const [s, i] = X({ isLoading: !0 }), o = (n == null ? void 0 : n.locale) || localStorage.getItem("language") || "en", [c, d] = X(o), l = (u) => {
|
|
2698
2702
|
localStorage.setItem("language", u), d(u);
|
|
2699
2703
|
};
|
|
@@ -2702,11 +2706,11 @@ const Ni = ({ children: t, user: e }) => /* @__PURE__ */ a.jsx(De.Provider, { va
|
|
|
2702
2706
|
i({ ...u, isLoading: !1 }), ti(5e3);
|
|
2703
2707
|
}).catch(() => i({ isLoading: !1 }));
|
|
2704
2708
|
}, []), /* @__PURE__ */ a.jsx(ya.Provider, { value: { language: c, updateLanguage: l }, children: /* @__PURE__ */ a.jsx(
|
|
2705
|
-
|
|
2709
|
+
Ni,
|
|
2706
2710
|
{
|
|
2707
2711
|
locale: c,
|
|
2708
2712
|
messages: n == null ? void 0 : n.messages,
|
|
2709
|
-
children: /* @__PURE__ */ a.jsx(
|
|
2713
|
+
children: /* @__PURE__ */ a.jsx(Ns, { children: /* @__PURE__ */ a.jsx($i, { user: s, children: /* @__PURE__ */ a.jsx(Ti, { showDevTools: r, children: /* @__PURE__ */ a.jsx(Ci, { user: s, children: e }) }) }) })
|
|
2710
2714
|
}
|
|
2711
2715
|
) });
|
|
2712
2716
|
};
|
|
@@ -2725,7 +2729,7 @@ const Pi = ({
|
|
|
2725
2729
|
return /* @__PURE__ */ a.jsx(
|
|
2726
2730
|
"span",
|
|
2727
2731
|
{
|
|
2728
|
-
className:
|
|
2732
|
+
className: E(`progress-bar section-${l}`, o, r, {
|
|
2729
2733
|
[c]: c !== "default",
|
|
2730
2734
|
[d !== "default" ? d : ""]: d !== "default"
|
|
2731
2735
|
}),
|
|
@@ -2754,7 +2758,7 @@ const vn = "loadingBlock_", Mi = ({ progress: t = 0, steps: e = !1, className: n
|
|
|
2754
2758
|
return /* @__PURE__ */ a.jsxs(
|
|
2755
2759
|
Fe,
|
|
2756
2760
|
{
|
|
2757
|
-
className:
|
|
2761
|
+
className: E("loading-block", n, {
|
|
2758
2762
|
"has-icon": s && e[s].icon
|
|
2759
2763
|
}),
|
|
2760
2764
|
variant: "subtle",
|
|
@@ -2770,7 +2774,7 @@ const Se = ({ element: t = "div", className: e = "", ...n }) => /* @__PURE__ */
|
|
|
2770
2774
|
Gn,
|
|
2771
2775
|
{
|
|
2772
2776
|
element: t,
|
|
2773
|
-
className:
|
|
2777
|
+
className: E("loading-placeholder", e),
|
|
2774
2778
|
...n
|
|
2775
2779
|
}
|
|
2776
2780
|
);
|
|
@@ -2823,7 +2827,7 @@ const zn = {
|
|
|
2823
2827
|
"course-navigation": ["button", "button"],
|
|
2824
2828
|
"course-lesson-page": ["breadcrumb", "course-navigation", "text-page"],
|
|
2825
2829
|
"course-lesson-quiz": ["text-page", "quiz-box"]
|
|
2826
|
-
}, xa = (t, e) => t in zn ? /* @__PURE__ */ a.jsx("div", { className: t, children: zn[t].map((n, r) => xa(n, r)) }, e) : /* @__PURE__ */ a.jsx(Se, { className: t }, e), wa = ({ layout: t = "overview-page", ...e }) => /* @__PURE__ */ a.jsx("div", { className:
|
|
2830
|
+
}, xa = (t, e) => t in zn ? /* @__PURE__ */ a.jsx("div", { className: t, children: zn[t].map((n, r) => xa(n, r)) }, e) : /* @__PURE__ */ a.jsx(Se, { className: t }, e), wa = ({ layout: t = "overview-page", ...e }) => /* @__PURE__ */ a.jsx("div", { className: E("loading-state", t), ...e, children: zn[t].map((n, r) => xa(n, r)) }), ja = (t) => {
|
|
2827
2831
|
const e = t && t.toUpperCase().trim().split(" ");
|
|
2828
2832
|
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) : "";
|
|
2829
2833
|
}, Ct = ["#5AB6A3", "#A2D7AF", "#806056", "#3962B3"], Ri = (t) => {
|
|
@@ -2835,13 +2839,13 @@ const zn = {
|
|
|
2835
2839
|
if (r <= e * (s + 1))
|
|
2836
2840
|
return Ct[s];
|
|
2837
2841
|
};
|
|
2838
|
-
const
|
|
2842
|
+
const $r = 256, Ye = ({
|
|
2839
2843
|
className: t = "",
|
|
2840
2844
|
src: e = "",
|
|
2841
2845
|
name: n,
|
|
2842
2846
|
alt: r,
|
|
2843
|
-
width: s =
|
|
2844
|
-
height: i =
|
|
2847
|
+
width: s = $r,
|
|
2848
|
+
height: i = $r,
|
|
2845
2849
|
...o
|
|
2846
2850
|
}) => {
|
|
2847
2851
|
const [c, d] = X(!1), l = pe(null);
|
|
@@ -2859,7 +2863,7 @@ const Nr = 256, Ye = ({
|
|
|
2859
2863
|
return e && e !== "" && !c && (e.includes("http") || e.includes("//")) && (u = !0), /* @__PURE__ */ a.jsx(
|
|
2860
2864
|
"figure",
|
|
2861
2865
|
{
|
|
2862
|
-
className:
|
|
2866
|
+
className: E("profile-picture", t, { error: c }),
|
|
2863
2867
|
...o,
|
|
2864
2868
|
children: u ? /* @__PURE__ */ a.jsx(
|
|
2865
2869
|
"img",
|
|
@@ -2913,7 +2917,7 @@ const tr = ({
|
|
|
2913
2917
|
}));
|
|
2914
2918
|
const { name: d, url: l, image: u } = c, f = Fi(c), m = n && n.createdAt ? Un(n.createdAt) : !1, p = n && n.createdAt ? ga(n.createdAt) : "";
|
|
2915
2919
|
return Y.createElement(t, {
|
|
2916
|
-
className:
|
|
2920
|
+
className: E("member text-medium", i),
|
|
2917
2921
|
children: /* @__PURE__ */ a.jsxs(
|
|
2918
2922
|
at,
|
|
2919
2923
|
{
|
|
@@ -2961,50 +2965,50 @@ const Pr = {
|
|
|
2961
2965
|
const f = H();
|
|
2962
2966
|
return !n || n.length === 0 ? null : Y.createElement(t, {
|
|
2963
2967
|
...u,
|
|
2964
|
-
className:
|
|
2968
|
+
className: E("contributors", l, s, { "has-gap": i }),
|
|
2965
2969
|
children: /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
2966
2970
|
/* @__PURE__ */ a.jsx("ul", { children: n.map((m, p) => {
|
|
2967
2971
|
let g, v = "";
|
|
2968
2972
|
if (p < c) {
|
|
2969
|
-
const { name:
|
|
2973
|
+
const { name: _ = "", image: y = "" } = ka(m);
|
|
2970
2974
|
if (o)
|
|
2971
2975
|
return /* @__PURE__ */ a.jsx(Se, { element: "li", className: "contributor" }, p);
|
|
2972
2976
|
g = /* @__PURE__ */ a.jsx(
|
|
2973
2977
|
Ye,
|
|
2974
2978
|
{
|
|
2975
|
-
name:
|
|
2976
|
-
src:
|
|
2979
|
+
name: _,
|
|
2980
|
+
src: y,
|
|
2977
2981
|
width: Pr[s || "medium"],
|
|
2978
2982
|
height: Pr[s || "medium"]
|
|
2979
2983
|
}
|
|
2980
2984
|
);
|
|
2981
2985
|
} else if (p === c) {
|
|
2982
|
-
const
|
|
2986
|
+
const _ = (e || n.length) - c;
|
|
2983
2987
|
g = /* @__PURE__ */ a.jsxs(
|
|
2984
2988
|
"small",
|
|
2985
2989
|
{
|
|
2986
|
-
className:
|
|
2990
|
+
className: E({ "large-number": _ > 99 }),
|
|
2987
2991
|
children: [
|
|
2988
2992
|
"+",
|
|
2989
|
-
ei(
|
|
2993
|
+
ei(_, 0)
|
|
2990
2994
|
]
|
|
2991
2995
|
}
|
|
2992
2996
|
), v = "number-left";
|
|
2993
2997
|
}
|
|
2994
|
-
return g ? /* @__PURE__ */ a.jsx("li", { className:
|
|
2998
|
+
return g ? /* @__PURE__ */ a.jsx("li", { className: E("contributor", v), children: g }, p) : null;
|
|
2995
2999
|
}) }),
|
|
2996
3000
|
r && /* @__PURE__ */ a.jsx("span", { className: "label", children: typeof r == "string" ? r : n.length === 1 ? typeof n[0] == "string" ? f.formatMessage({ id: `member_${n[0]}` }) : et(n[0].name || "", 20) : d || null })
|
|
2997
3001
|
] })
|
|
2998
3002
|
});
|
|
2999
3003
|
};
|
|
3000
|
-
const
|
|
3004
|
+
const Nt = "emailHelperTextBox_", Oi = ({
|
|
3001
3005
|
type: t,
|
|
3002
3006
|
email: e,
|
|
3003
3007
|
redirectPath: n,
|
|
3004
3008
|
resendVerificationCode: r
|
|
3005
3009
|
}) => {
|
|
3006
3010
|
const s = H(), [i, o] = X({
|
|
3007
|
-
path: `${
|
|
3011
|
+
path: `${Nt}default`,
|
|
3008
3012
|
type: "default",
|
|
3009
3013
|
link: {},
|
|
3010
3014
|
mail: {},
|
|
@@ -3014,13 +3018,13 @@ const $t = "emailHelperTextBox_", Oi = ({
|
|
|
3014
3018
|
p.preventDefault(), p.stopPropagation();
|
|
3015
3019
|
const g = (v) => {
|
|
3016
3020
|
o({
|
|
3017
|
-
path: `${
|
|
3021
|
+
path: `${Nt}error_verificationFailedToSend`,
|
|
3018
3022
|
type: "error",
|
|
3019
3023
|
link: {
|
|
3020
3024
|
"data-gtm-event-context": "VerifyEmailBox",
|
|
3021
3025
|
"data-gtm-event-type": "SendEmailClick",
|
|
3022
3026
|
className: "gtm-trackable",
|
|
3023
|
-
onClick: (
|
|
3027
|
+
onClick: (_) => l(_),
|
|
3024
3028
|
href: "#",
|
|
3025
3029
|
"data-testid": "send-verify-email-click"
|
|
3026
3030
|
},
|
|
@@ -3034,7 +3038,7 @@ const $t = "emailHelperTextBox_", Oi = ({
|
|
|
3034
3038
|
});
|
|
3035
3039
|
};
|
|
3036
3040
|
if (typeof r != "function") {
|
|
3037
|
-
g(s.formatMessage({ id: `${
|
|
3041
|
+
g(s.formatMessage({ id: `${Nt}error_noFunction` }));
|
|
3038
3042
|
return;
|
|
3039
3043
|
}
|
|
3040
3044
|
d(!0), r(e).then(() => {
|
|
@@ -3050,7 +3054,7 @@ const $t = "emailHelperTextBox_", Oi = ({
|
|
|
3050
3054
|
);
|
|
3051
3055
|
ae(
|
|
3052
3056
|
() => {
|
|
3053
|
-
let p =
|
|
3057
|
+
let p = Nt, g = "default", v = {}, _ = {};
|
|
3054
3058
|
switch (t) {
|
|
3055
3059
|
case "gov":
|
|
3056
3060
|
p += "autoApproved", g = "success";
|
|
@@ -3063,7 +3067,7 @@ const $t = "emailHelperTextBox_", Oi = ({
|
|
|
3063
3067
|
};
|
|
3064
3068
|
break;
|
|
3065
3069
|
case "pending":
|
|
3066
|
-
p += "pendingApproval", g = "error",
|
|
3070
|
+
p += "pendingApproval", g = "error", _ = {
|
|
3067
3071
|
href: "mailto:concierge@apolitical.co",
|
|
3068
3072
|
className: "gtm-trackable",
|
|
3069
3073
|
"data-gtm-event-context": "EmailExistsBox",
|
|
@@ -3076,7 +3080,7 @@ const $t = "emailHelperTextBox_", Oi = ({
|
|
|
3076
3080
|
"data-gtm-event-context": "VerifyEmailBox",
|
|
3077
3081
|
"data-gtm-event-type": "SendEmailClick",
|
|
3078
3082
|
className: "gtm-trackable",
|
|
3079
|
-
onClick: (
|
|
3083
|
+
onClick: (y) => l(y),
|
|
3080
3084
|
"data-testid": "send-verify-email-click"
|
|
3081
3085
|
};
|
|
3082
3086
|
break;
|
|
@@ -3085,7 +3089,7 @@ const $t = "emailHelperTextBox_", Oi = ({
|
|
|
3085
3089
|
href: "/user-onboarding/login",
|
|
3086
3090
|
"data-gtm-event-context": "EmailExistsBox",
|
|
3087
3091
|
"data-gtm-event-type": "login-click"
|
|
3088
|
-
},
|
|
3092
|
+
}, _ = {
|
|
3089
3093
|
href: "mailto:concierge@apolitical.co",
|
|
3090
3094
|
className: "gtm-trackable",
|
|
3091
3095
|
"data-gtm-event-context": "EmailExistsBox",
|
|
@@ -3100,7 +3104,7 @@ const $t = "emailHelperTextBox_", Oi = ({
|
|
|
3100
3104
|
};
|
|
3101
3105
|
break;
|
|
3102
3106
|
}
|
|
3103
|
-
o({ ...i, path: p, type: g, link: v, mail:
|
|
3107
|
+
o({ ...i, path: p, type: g, link: v, mail: _ });
|
|
3104
3108
|
},
|
|
3105
3109
|
/* eslint-disable react-hooks/exhaustive-deps */
|
|
3106
3110
|
[t]
|
|
@@ -3156,7 +3160,7 @@ const $t = "emailHelperTextBox_", Oi = ({
|
|
|
3156
3160
|
type: c,
|
|
3157
3161
|
id: n,
|
|
3158
3162
|
name: i,
|
|
3159
|
-
className:
|
|
3163
|
+
className: E(t, e, {
|
|
3160
3164
|
"has-scrollbar": c === "textarea" && f.current && f.current.clientHeight < f.current.scrollHeight
|
|
3161
3165
|
}),
|
|
3162
3166
|
value: d,
|
|
@@ -3198,10 +3202,10 @@ const Qe = {
|
|
|
3198
3202
|
predictions: [],
|
|
3199
3203
|
activePredictionIndex: -1,
|
|
3200
3204
|
isPredictionSelected: !!n
|
|
3201
|
-
}), { formatMessage:
|
|
3202
|
-
r || (r =
|
|
3205
|
+
}), { formatMessage: _ } = H();
|
|
3206
|
+
r || (r = _({ id: "inputAutocomplete_placeholder" })), ae(() => {
|
|
3203
3207
|
const w = setTimeout(() => {
|
|
3204
|
-
g || f((
|
|
3208
|
+
g || f((b) => ({ ...b, debouncedInput: d }));
|
|
3205
3209
|
}, Ai);
|
|
3206
3210
|
return () => {
|
|
3207
3211
|
clearTimeout(w);
|
|
@@ -3209,13 +3213,13 @@ const Qe = {
|
|
|
3209
3213
|
}, [d, g]), ae(() => {
|
|
3210
3214
|
u && !g ? (async () => {
|
|
3211
3215
|
try {
|
|
3212
|
-
const
|
|
3216
|
+
const b = await c(u) || [];
|
|
3213
3217
|
v((F) => ({
|
|
3214
3218
|
...F,
|
|
3215
|
-
predictions:
|
|
3219
|
+
predictions: b
|
|
3216
3220
|
}));
|
|
3217
|
-
} catch (
|
|
3218
|
-
console.error("Error fetching predictions:",
|
|
3221
|
+
} catch (b) {
|
|
3222
|
+
console.error("Error fetching predictions:", b), v((F) => ({ ...F, predictions: [] }));
|
|
3219
3223
|
}
|
|
3220
3224
|
})() : v((w) => ({ ...w, predictions: [] }));
|
|
3221
3225
|
}, [u, g]), ae(() => {
|
|
@@ -3224,38 +3228,38 @@ const Qe = {
|
|
|
3224
3228
|
displayInput: m[p].description
|
|
3225
3229
|
}));
|
|
3226
3230
|
}, [p, m]);
|
|
3227
|
-
const
|
|
3228
|
-
[Qe.DOWN, Qe.UP, Qe.ENTER].includes(w.key) && (w.preventDefault(), w.key === Qe.DOWN && p < m.length - 1 ? v((
|
|
3229
|
-
...
|
|
3231
|
+
const y = (w) => {
|
|
3232
|
+
[Qe.DOWN, Qe.UP, Qe.ENTER].includes(w.key) && (w.preventDefault(), w.key === Qe.DOWN && p < m.length - 1 ? v((b) => ({
|
|
3233
|
+
...b,
|
|
3230
3234
|
activePredictionIndex: p + 1
|
|
3231
|
-
})) : w.key === Qe.UP && p > 0 ? v((
|
|
3232
|
-
...
|
|
3235
|
+
})) : w.key === Qe.UP && p > 0 ? v((b) => ({
|
|
3236
|
+
...b,
|
|
3233
3237
|
activePredictionIndex: p - 1
|
|
3234
|
-
})) : w.key === Qe.ENTER && p > -1 && (o(m[p].description), f((
|
|
3235
|
-
...
|
|
3238
|
+
})) : w.key === Qe.ENTER && p > -1 && (o(m[p].description), f((b) => ({
|
|
3239
|
+
...b,
|
|
3236
3240
|
input: m[p].description
|
|
3237
|
-
})), v((
|
|
3238
|
-
...
|
|
3241
|
+
})), v((b) => ({
|
|
3242
|
+
...b,
|
|
3239
3243
|
predictions: [],
|
|
3240
3244
|
isPredictionSelected: !0
|
|
3241
3245
|
}))));
|
|
3242
3246
|
}, x = (w) => {
|
|
3243
|
-
o(w.target.value), f((
|
|
3244
|
-
...
|
|
3247
|
+
o(w.target.value), f((b) => ({
|
|
3248
|
+
...b,
|
|
3245
3249
|
input: w.target.value,
|
|
3246
3250
|
displayInput: w.target.value
|
|
3247
|
-
})), v((
|
|
3248
|
-
...
|
|
3251
|
+
})), v((b) => ({
|
|
3252
|
+
...b,
|
|
3249
3253
|
activePredictionIndex: -1,
|
|
3250
3254
|
isPredictionSelected: !1
|
|
3251
3255
|
}));
|
|
3252
|
-
},
|
|
3253
|
-
o(w.description), f((
|
|
3254
|
-
...
|
|
3256
|
+
}, S = (w) => {
|
|
3257
|
+
o(w.description), f((b) => ({
|
|
3258
|
+
...b,
|
|
3255
3259
|
input: w.description,
|
|
3256
3260
|
displayInput: w.description
|
|
3257
|
-
})), v((
|
|
3258
|
-
...
|
|
3261
|
+
})), v((b) => ({
|
|
3262
|
+
...b,
|
|
3259
3263
|
isPredictionSelected: !0,
|
|
3260
3264
|
predictions: []
|
|
3261
3265
|
}));
|
|
@@ -3267,27 +3271,27 @@ const Qe = {
|
|
|
3267
3271
|
type: "text",
|
|
3268
3272
|
value: l,
|
|
3269
3273
|
onChange: x,
|
|
3270
|
-
onKeyDown:
|
|
3274
|
+
onKeyDown: y,
|
|
3271
3275
|
placeholder: r,
|
|
3272
3276
|
name: e,
|
|
3273
3277
|
id: t,
|
|
3274
3278
|
...i
|
|
3275
3279
|
}
|
|
3276
3280
|
),
|
|
3277
|
-
/* @__PURE__ */ a.jsx("ul", { className: "predictions-list", children: m.map((w,
|
|
3281
|
+
/* @__PURE__ */ a.jsx("ul", { className: "predictions-list", children: m.map((w, b) => /* @__PURE__ */ a.jsx(
|
|
3278
3282
|
"li",
|
|
3279
3283
|
{
|
|
3280
|
-
onClick: () =>
|
|
3284
|
+
onClick: () => S(w),
|
|
3281
3285
|
onMouseEnter: () => v((F) => ({
|
|
3282
3286
|
...F,
|
|
3283
|
-
activePredictionIndex:
|
|
3287
|
+
activePredictionIndex: b
|
|
3284
3288
|
})),
|
|
3285
|
-
className:
|
|
3286
|
-
active:
|
|
3289
|
+
className: E("predictions-list-item", {
|
|
3290
|
+
active: b === p
|
|
3287
3291
|
}),
|
|
3288
3292
|
children: w.description
|
|
3289
3293
|
},
|
|
3290
|
-
|
|
3294
|
+
b
|
|
3291
3295
|
)) })
|
|
3292
3296
|
] });
|
|
3293
3297
|
};
|
|
@@ -3308,7 +3312,7 @@ const Ea = ({
|
|
|
3308
3312
|
}) => {
|
|
3309
3313
|
const m = H(), { onChange: p, ...g } = r, v = () => {
|
|
3310
3314
|
e || p(u ? null : d);
|
|
3311
|
-
},
|
|
3315
|
+
}, _ = /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
3312
3316
|
/* @__PURE__ */ a.jsx(
|
|
3313
3317
|
"input",
|
|
3314
3318
|
{
|
|
@@ -3318,8 +3322,8 @@ const Ea = ({
|
|
|
3318
3322
|
type: l,
|
|
3319
3323
|
value: d,
|
|
3320
3324
|
checked: u,
|
|
3321
|
-
onKeyDown: (
|
|
3322
|
-
(
|
|
3325
|
+
onKeyDown: (y) => {
|
|
3326
|
+
(y.key === "Enter" || y.code === "Space") && (y.preventDefault(), y.stopPropagation(), v());
|
|
3323
3327
|
},
|
|
3324
3328
|
readOnly: !0,
|
|
3325
3329
|
disabled: e
|
|
@@ -3333,15 +3337,15 @@ const Ea = ({
|
|
|
3333
3337
|
return Y.createElement(
|
|
3334
3338
|
n,
|
|
3335
3339
|
{
|
|
3336
|
-
onClick: (
|
|
3337
|
-
const x =
|
|
3338
|
-
x.nodeName.toLowerCase() === "a" || x.parentNode && x.parentNode.nodeName.toLowerCase() === "a" || (
|
|
3340
|
+
onClick: (y) => {
|
|
3341
|
+
const x = y.target;
|
|
3342
|
+
x.nodeName.toLowerCase() === "a" || x.parentNode && x.parentNode.nodeName.toLowerCase() === "a" || (y.preventDefault(), y.stopPropagation(), v());
|
|
3339
3343
|
},
|
|
3340
|
-
className:
|
|
3344
|
+
className: E("checkbox-wrapper", t),
|
|
3341
3345
|
...f,
|
|
3342
3346
|
...g
|
|
3343
3347
|
},
|
|
3344
|
-
|
|
3348
|
+
_
|
|
3345
3349
|
);
|
|
3346
3350
|
};
|
|
3347
3351
|
const Ii = Ae(function({
|
|
@@ -3350,7 +3354,7 @@ const Ii = Ae(function({
|
|
|
3350
3354
|
return /* @__PURE__ */ a.jsx(
|
|
3351
3355
|
Gn,
|
|
3352
3356
|
{
|
|
3353
|
-
className:
|
|
3357
|
+
className: E("rotating-chevron", `direction-${e}`)
|
|
3354
3358
|
}
|
|
3355
3359
|
);
|
|
3356
3360
|
});
|
|
@@ -3368,25 +3372,25 @@ const Li = ({
|
|
|
3368
3372
|
multiSelectOptions: d,
|
|
3369
3373
|
id: l
|
|
3370
3374
|
}) => {
|
|
3371
|
-
const u = H(), [f, m] = X(!1), p = r || n, g = Array.isArray(p) ? [...p] : p ? [p] : [], [v,
|
|
3372
|
-
let
|
|
3373
|
-
Array.isArray(v) && v.length === 1 && typeof v[0] == "string" ?
|
|
3374
|
-
|
|
3375
|
+
const u = H(), [f, m] = X(!1), p = r || n, g = Array.isArray(p) ? [...p] : p ? [p] : [], [v, _] = X(g);
|
|
3376
|
+
let y;
|
|
3377
|
+
Array.isArray(v) && v.length === 1 && typeof v[0] == "string" ? y = e && v ? e.find((R) => R.id === v[0]) : e ? e[0] : { id: "", label: "" } : Array.isArray(v) && v.length === 1 && typeof v[0] != "string" ? y = v[0] : y = { id: "", label: "" }, ae(() => {
|
|
3378
|
+
_(g);
|
|
3375
3379
|
}, [r, n]);
|
|
3376
|
-
const { onChange: x, onMultiSelectSubmit:
|
|
3380
|
+
const { onChange: x, onMultiSelectSubmit: S, ...w } = s, b = (R) => {
|
|
3377
3381
|
if (c) {
|
|
3378
3382
|
let Q = [];
|
|
3379
|
-
v != null && v.includes(R.id) ? Q = v.filter((B) => B !== R.id) : Q = [...v, R.id],
|
|
3383
|
+
v != null && v.includes(R.id) ? Q = v.filter((B) => B !== R.id) : Q = [...v, R.id], _([...Q]), x && x([...Q]);
|
|
3380
3384
|
} else
|
|
3381
|
-
|
|
3385
|
+
_([R]), x && x(R.id), m(!1);
|
|
3382
3386
|
}, F = (R) => {
|
|
3383
3387
|
if (R === "all") {
|
|
3384
3388
|
const Q = (e == null ? void 0 : e.map((B) => B.id)) || [];
|
|
3385
|
-
|
|
3389
|
+
_(Q), x && x(Q);
|
|
3386
3390
|
} else
|
|
3387
|
-
|
|
3391
|
+
_([]), x && x([]);
|
|
3388
3392
|
};
|
|
3389
|
-
return /* @__PURE__ */ a.jsxs("div", { className:
|
|
3393
|
+
return /* @__PURE__ */ a.jsxs("div", { className: E("dropdown-wrapper", t), children: [
|
|
3390
3394
|
/* @__PURE__ */ a.jsxs(
|
|
3391
3395
|
"button",
|
|
3392
3396
|
{
|
|
@@ -3400,7 +3404,7 @@ const Li = ({
|
|
|
3400
3404
|
"data-testid": "dropdown-selector",
|
|
3401
3405
|
...w,
|
|
3402
3406
|
children: [
|
|
3403
|
-
c ? `${o} · ${v.length}` :
|
|
3407
|
+
c ? `${o} · ${v.length}` : y.label,
|
|
3404
3408
|
/* @__PURE__ */ a.jsx(Ii, { direction: f ? "up" : "down" })
|
|
3405
3409
|
]
|
|
3406
3410
|
}
|
|
@@ -3408,11 +3412,11 @@ const Li = ({
|
|
|
3408
3412
|
/* @__PURE__ */ a.jsx(
|
|
3409
3413
|
"select",
|
|
3410
3414
|
{
|
|
3411
|
-
defaultValue:
|
|
3415
|
+
defaultValue: y.id,
|
|
3412
3416
|
onChange: (R) => {
|
|
3413
3417
|
R.preventDefault(), R.stopPropagation();
|
|
3414
3418
|
const Q = e && e.find((B) => B.id === R.target.value);
|
|
3415
|
-
|
|
3419
|
+
b(Q);
|
|
3416
3420
|
},
|
|
3417
3421
|
hidden: !f,
|
|
3418
3422
|
...w,
|
|
@@ -3453,25 +3457,25 @@ const Li = ({
|
|
|
3453
3457
|
] })
|
|
3454
3458
|
] }),
|
|
3455
3459
|
/* @__PURE__ */ a.jsx("ul", { children: e == null ? void 0 : e.map((R) => {
|
|
3456
|
-
const Q = R.id ===
|
|
3460
|
+
const Q = R.id === y.id || (v == null ? void 0 : v.includes(R)) || (v == null ? void 0 : v.includes(R.id));
|
|
3457
3461
|
return /* @__PURE__ */ a.jsx("li", { "data-testid": "dropdown-options", children: /* @__PURE__ */ a.jsxs(
|
|
3458
3462
|
"button",
|
|
3459
3463
|
{
|
|
3460
|
-
className:
|
|
3464
|
+
className: E("gtm-trackable", {
|
|
3461
3465
|
selected: Q,
|
|
3462
3466
|
"selected-single": Q && !c
|
|
3463
3467
|
}),
|
|
3464
3468
|
"data-gtm-event-type": `${R}-click`,
|
|
3465
3469
|
"data-gtm-event-context": i,
|
|
3466
3470
|
onClick: (B) => {
|
|
3467
|
-
B.preventDefault(), B.stopPropagation(),
|
|
3471
|
+
B.preventDefault(), B.stopPropagation(), b(R);
|
|
3468
3472
|
},
|
|
3469
3473
|
role: "menuitem",
|
|
3470
3474
|
"aria-current": Q,
|
|
3471
3475
|
"data-testid": Q ? "current-selection" : "",
|
|
3472
3476
|
children: [
|
|
3473
3477
|
c && /* @__PURE__ */ a.jsx("span", { className: "pretty-checkbox", "data-testid": "pretty-checkbox" }),
|
|
3474
|
-
/* @__PURE__ */ a.jsx("span", { className:
|
|
3478
|
+
/* @__PURE__ */ a.jsx("span", { className: E({ "menu-option-label": c }), children: R.label })
|
|
3475
3479
|
]
|
|
3476
3480
|
}
|
|
3477
3481
|
) }, R.id);
|
|
@@ -3482,7 +3486,7 @@ const Li = ({
|
|
|
3482
3486
|
{
|
|
3483
3487
|
variant: "secondary",
|
|
3484
3488
|
onClick: () => {
|
|
3485
|
-
|
|
3489
|
+
S && S(v), document.dispatchEvent(
|
|
3486
3490
|
new CustomEvent("dropdownMultiSelectSubmit", {
|
|
3487
3491
|
detail: {
|
|
3488
3492
|
id: l || "dropdown-multi-select",
|
|
@@ -3519,45 +3523,45 @@ const Bi = ({
|
|
|
3519
3523
|
"ul",
|
|
3520
3524
|
{
|
|
3521
3525
|
...f,
|
|
3522
|
-
className:
|
|
3526
|
+
className: E("options-wrapper", t),
|
|
3523
3527
|
"data-testid": `ul-${r}`,
|
|
3524
3528
|
children: c == null ? void 0 : c.map(
|
|
3525
3529
|
({
|
|
3526
3530
|
id: v,
|
|
3527
|
-
label:
|
|
3528
|
-
value:
|
|
3531
|
+
label: _ = !1,
|
|
3532
|
+
value: y = v,
|
|
3529
3533
|
disabled: x = !1
|
|
3530
3534
|
}) => {
|
|
3531
|
-
const
|
|
3535
|
+
const S = `${r}_${v}`, w = () => {
|
|
3532
3536
|
if (x)
|
|
3533
3537
|
return;
|
|
3534
|
-
let
|
|
3538
|
+
let b;
|
|
3535
3539
|
if (i) {
|
|
3536
|
-
const F = p == null ? void 0 : p.indexOf(
|
|
3537
|
-
Array.isArray(p) && F >= 0 ? (
|
|
3540
|
+
const F = p == null ? void 0 : p.indexOf(y);
|
|
3541
|
+
Array.isArray(p) && F >= 0 ? (b = p, b.splice(F, 1)) : (!p || p.length === 0 ? b = [] : b = p, b.push(y));
|
|
3538
3542
|
} else
|
|
3539
|
-
|
|
3540
|
-
e.onChange(
|
|
3543
|
+
b = g === y ? void 0 : y;
|
|
3544
|
+
e.onChange(b);
|
|
3541
3545
|
};
|
|
3542
3546
|
return /* @__PURE__ */ a.jsx(
|
|
3543
3547
|
Ea,
|
|
3544
3548
|
{
|
|
3545
3549
|
element: "li",
|
|
3546
|
-
id:
|
|
3550
|
+
id: S,
|
|
3547
3551
|
type: l === "checkboxes" ? "checkbox" : "radio",
|
|
3548
|
-
shownValue:
|
|
3549
|
-
value: i ? p == null ? void 0 : p.includes(
|
|
3552
|
+
shownValue: y,
|
|
3553
|
+
value: i ? p == null ? void 0 : p.includes(y) : g === y,
|
|
3550
3554
|
functions: {
|
|
3551
3555
|
...e,
|
|
3552
3556
|
onChange: w
|
|
3553
3557
|
},
|
|
3554
3558
|
intlPath: n,
|
|
3555
|
-
label:
|
|
3559
|
+
label: _ || m.formatMessage({
|
|
3556
3560
|
id: n ? `${n}_${v}` : v
|
|
3557
3561
|
}),
|
|
3558
3562
|
disabled: x
|
|
3559
3563
|
},
|
|
3560
|
-
|
|
3564
|
+
S
|
|
3561
3565
|
);
|
|
3562
3566
|
}
|
|
3563
3567
|
)
|
|
@@ -3579,7 +3583,7 @@ const qi = ({
|
|
|
3579
3583
|
"button",
|
|
3580
3584
|
{
|
|
3581
3585
|
type: "button",
|
|
3582
|
-
className:
|
|
3586
|
+
className: E("show-password gtm-trackable", {
|
|
3583
3587
|
"password-visible": c
|
|
3584
3588
|
}),
|
|
3585
3589
|
"data-gtm-event-context": n,
|
|
@@ -3621,7 +3625,7 @@ const Je = {
|
|
|
3621
3625
|
}) => {
|
|
3622
3626
|
const f = H(), m = d && d.some(({ condition: w }) => w === "required"), p = (l == null ? void 0 : l.toString().length) || 0, g = c && Je[c] && Je[c].component ? Je[c].component : gt, v = {};
|
|
3623
3627
|
c && ["checkboxes"].includes(c) ? v.element = "span" : v.htmlFor = t;
|
|
3624
|
-
let
|
|
3628
|
+
let _ = {
|
|
3625
3629
|
...u,
|
|
3626
3630
|
id: t,
|
|
3627
3631
|
name: t,
|
|
@@ -3632,10 +3636,10 @@ const Je = {
|
|
|
3632
3636
|
functions: pt(s),
|
|
3633
3637
|
value: l
|
|
3634
3638
|
};
|
|
3635
|
-
i > 0 && (
|
|
3639
|
+
i > 0 && (_["data-character-limit"] = i, _.functions && (_.functions.onChange = (w) => {
|
|
3636
3640
|
((w == null ? void 0 : w.toString().length) || 0) > i && (w = w == null ? void 0 : w.toString().slice(0, i)), s.onChange(w);
|
|
3637
|
-
})), c && Je[c] && Je[c].props && (
|
|
3638
|
-
const
|
|
3641
|
+
})), c && Je[c] && Je[c].props && (_ = { ..._, ...Je[c].props }), c && ["checkboxes"].includes(c) && (_.intlPath = `${e}_${t}`), r && (_["aria-invalid"] = !0, _["aria-describedby"] = `error-${t}`);
|
|
3642
|
+
const y = u.label || f.formatMessage({ id: e ? `${e}_${t}` : t }), x = ({ ...w }) => r ? Y.createElement(
|
|
3639
3643
|
w.as || "dd",
|
|
3640
3644
|
{
|
|
3641
3645
|
id: `error-${t}`,
|
|
@@ -3651,21 +3655,21 @@ const Je = {
|
|
|
3651
3655
|
/* @__PURE__ */ a.jsx(
|
|
3652
3656
|
g,
|
|
3653
3657
|
{
|
|
3654
|
-
...
|
|
3655
|
-
label:
|
|
3656
|
-
className:
|
|
3658
|
+
..._,
|
|
3659
|
+
label: y,
|
|
3660
|
+
className: E("field-wrapper", n)
|
|
3657
3661
|
}
|
|
3658
3662
|
),
|
|
3659
3663
|
/* @__PURE__ */ a.jsx(x, { as: "p" })
|
|
3660
3664
|
] });
|
|
3661
|
-
const
|
|
3665
|
+
const S = (w) => Y.createElement(w.element || "label", {
|
|
3662
3666
|
...w,
|
|
3663
3667
|
className: "checkboxes-label text-small",
|
|
3664
3668
|
"data-testid": `label-${t}`
|
|
3665
3669
|
});
|
|
3666
|
-
return /* @__PURE__ */ a.jsxs("dl", { className:
|
|
3667
|
-
/* @__PURE__ */ a.jsx("dt", { children: /* @__PURE__ */ a.jsxs(
|
|
3668
|
-
|
|
3670
|
+
return /* @__PURE__ */ a.jsxs("dl", { className: E("field-wrapper text-medium", n), children: [
|
|
3671
|
+
/* @__PURE__ */ a.jsx("dt", { children: /* @__PURE__ */ a.jsxs(S, { ...v, children: [
|
|
3672
|
+
y,
|
|
3669
3673
|
m && o && /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
3670
3674
|
" ",
|
|
3671
3675
|
/* @__PURE__ */ a.jsxs("small", { children: [
|
|
@@ -3676,11 +3680,11 @@ const Je = {
|
|
|
3676
3680
|
] })
|
|
3677
3681
|
] }) }),
|
|
3678
3682
|
/* @__PURE__ */ a.jsxs("dd", { children: [
|
|
3679
|
-
/* @__PURE__ */ a.jsx(g, { ...
|
|
3683
|
+
/* @__PURE__ */ a.jsx(g, { ..._ }),
|
|
3680
3684
|
i > 0 ? /* @__PURE__ */ a.jsxs(
|
|
3681
3685
|
"small",
|
|
3682
3686
|
{
|
|
3683
|
-
className:
|
|
3687
|
+
className: E("character-limit", {
|
|
3684
3688
|
"near-limit": p >= 0.99 * i,
|
|
3685
3689
|
"approaching-limit": p >= 0.9 * i && p < 0.99 * i
|
|
3686
3690
|
}),
|
|
@@ -3737,36 +3741,36 @@ const Je = {
|
|
|
3737
3741
|
if (m.validation)
|
|
3738
3742
|
for (let p = 0; p < m.validation.length; p++) {
|
|
3739
3743
|
const { condition: g = "required", error: v = !1 } = m.validation[p];
|
|
3740
|
-
let
|
|
3744
|
+
let _ = !1;
|
|
3741
3745
|
if (typeof g == "function") {
|
|
3742
|
-
const
|
|
3743
|
-
|
|
3746
|
+
const y = g(i);
|
|
3747
|
+
y && (_ = v || y);
|
|
3744
3748
|
} else {
|
|
3745
|
-
const
|
|
3749
|
+
const y = i[m.id];
|
|
3746
3750
|
switch (g) {
|
|
3747
3751
|
case "required":
|
|
3748
|
-
(!
|
|
3752
|
+
(!y || typeof y == "string" && y.trim().length === 0) && (_ = v || (u == null ? void 0 : u.formatMessage({ id: "form_error_required" })));
|
|
3749
3753
|
break;
|
|
3750
3754
|
case "no-numbers": {
|
|
3751
|
-
|
|
3755
|
+
y && !/^([^0-9]*)$/.test(y) && (_ = v || (u == null ? void 0 : u.formatMessage({ id: "form_error_numbers" })));
|
|
3752
3756
|
break;
|
|
3753
3757
|
}
|
|
3754
3758
|
case "valid-email": {
|
|
3755
|
-
|
|
3759
|
+
y && !/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(y) && (_ = v || (u == null ? void 0 : u.formatMessage({ id: "form_error_email" })));
|
|
3756
3760
|
break;
|
|
3757
3761
|
}
|
|
3758
3762
|
case "valid-url": {
|
|
3759
|
-
|
|
3763
|
+
y && !/^(?:http(s)?:\/\/)?[\w.-]+(?:\.[\w\.-]+)+[\w\-\._~:/?#[\]@!\$&'\(\)\*\+,;=.]+$/.test(y) && (_ = v || (u == null ? void 0 : u.formatMessage({ id: "form_error_url" })));
|
|
3760
3764
|
break;
|
|
3761
3765
|
}
|
|
3762
3766
|
default:
|
|
3763
3767
|
console.warn("WARNING! No field validation condition has been set");
|
|
3764
3768
|
}
|
|
3765
3769
|
}
|
|
3766
|
-
if (
|
|
3770
|
+
if (_) {
|
|
3767
3771
|
c({
|
|
3768
3772
|
type: "addError",
|
|
3769
|
-
payload: { key: m.id, value:
|
|
3773
|
+
payload: { key: m.id, value: _ }
|
|
3770
3774
|
}), f.push(m.id);
|
|
3771
3775
|
break;
|
|
3772
3776
|
}
|
|
@@ -3832,11 +3836,11 @@ const rn = ({
|
|
|
3832
3836
|
},
|
|
3833
3837
|
...p
|
|
3834
3838
|
}) => {
|
|
3835
|
-
const { customOnSubmit: g, hideButton: v, ...
|
|
3839
|
+
const { customOnSubmit: g, hideButton: v, ..._ } = i, y = 40, {
|
|
3836
3840
|
shouldShowCancelButton: x = !1,
|
|
3837
|
-
shouldReset:
|
|
3841
|
+
shouldReset: S = !0,
|
|
3838
3842
|
showRequiredLabels: w = !0,
|
|
3839
|
-
showSuccessMessage:
|
|
3843
|
+
showSuccessMessage: b = !1
|
|
3840
3844
|
} = c || {}, F = H(), R = {};
|
|
3841
3845
|
t.length && t.forEach((z) => {
|
|
3842
3846
|
const K = z.id || z.name;
|
|
@@ -3847,9 +3851,9 @@ const rn = ({
|
|
|
3847
3851
|
formSubmitted: !1,
|
|
3848
3852
|
errors: {},
|
|
3849
3853
|
values: R
|
|
3850
|
-
}), { errors:
|
|
3854
|
+
}), { errors: N, isSubmitting: C, formSubmitted: k, values: j } = Q;
|
|
3851
3855
|
ae(() => {
|
|
3852
|
-
|
|
3856
|
+
S && k && (bn = setTimeout(() => {
|
|
3853
3857
|
B({
|
|
3854
3858
|
type: "updateValue",
|
|
3855
3859
|
payload: { key: "formSubmitted", value: !1 }
|
|
@@ -3874,13 +3878,13 @@ const rn = ({
|
|
|
3874
3878
|
);
|
|
3875
3879
|
};
|
|
3876
3880
|
}, []);
|
|
3877
|
-
const
|
|
3881
|
+
const $ = pe(null), A = r || $;
|
|
3878
3882
|
if (!t.length)
|
|
3879
3883
|
return null;
|
|
3880
3884
|
i.text || (i.text = F.formatMessage({ id: "form_submit" }));
|
|
3881
3885
|
const Z = [
|
|
3882
3886
|
{
|
|
3883
|
-
...
|
|
3887
|
+
..._,
|
|
3884
3888
|
icon: k ? { icon: "tick", position: "left" } : !1,
|
|
3885
3889
|
className: "gtm-trackable",
|
|
3886
3890
|
onClick: (z) => {
|
|
@@ -3893,7 +3897,7 @@ const rn = ({
|
|
|
3893
3897
|
q && (K = q.getBoundingClientRect().top + window.scrollY);
|
|
3894
3898
|
}
|
|
3895
3899
|
const T = document.getElementById("header");
|
|
3896
|
-
if (T && (K = K - T.offsetHeight -
|
|
3900
|
+
if (T && (K = K - T.offsetHeight - y), K < 0 && (K = 0), window.scrollTo({ top: K, behavior: "smooth" }), B({ type: "toggleSubmitting" }), i.disabled) {
|
|
3897
3901
|
typeof i.disabled == "object" && i.disabled.isClickable && B({
|
|
3898
3902
|
type: "submitForm",
|
|
3899
3903
|
payload: {
|
|
@@ -3911,7 +3915,7 @@ const rn = ({
|
|
|
3911
3915
|
dispatch: B,
|
|
3912
3916
|
onSuccess: async (q) => {
|
|
3913
3917
|
try {
|
|
3914
|
-
await l(q), B({ type:
|
|
3918
|
+
await l(q), B({ type: S ? "formSubmittedAndReset" : "formSubmitted" });
|
|
3915
3919
|
} catch (L) {
|
|
3916
3920
|
f(L), B({
|
|
3917
3921
|
type: "updateValue",
|
|
@@ -3951,17 +3955,17 @@ const rn = ({
|
|
|
3951
3955
|
{
|
|
3952
3956
|
...p,
|
|
3953
3957
|
id: n,
|
|
3954
|
-
className:
|
|
3958
|
+
className: E("form", e),
|
|
3955
3959
|
ref: A,
|
|
3956
3960
|
children: [
|
|
3957
|
-
|
|
3961
|
+
N != null && N.general ? /* @__PURE__ */ a.jsx(
|
|
3958
3962
|
He,
|
|
3959
3963
|
{
|
|
3960
3964
|
variant: "error",
|
|
3961
3965
|
text: F.formatMessage({ id: "form_error_generalError" })
|
|
3962
3966
|
}
|
|
3963
3967
|
) : null,
|
|
3964
|
-
(!
|
|
3968
|
+
(!S || !C && !k || g) && t.map((z, K) => {
|
|
3965
3969
|
const {
|
|
3966
3970
|
id: T = z.name || K,
|
|
3967
3971
|
component: P,
|
|
@@ -3978,7 +3982,7 @@ const rn = ({
|
|
|
3978
3982
|
...z,
|
|
3979
3983
|
showRequiredLabels: w,
|
|
3980
3984
|
value: L,
|
|
3981
|
-
error:
|
|
3985
|
+
error: N == null ? void 0 : N[T],
|
|
3982
3986
|
functions: {
|
|
3983
3987
|
...q,
|
|
3984
3988
|
onChange: (U) => {
|
|
@@ -3992,7 +3996,7 @@ const rn = ({
|
|
|
3992
3996
|
v ? null : (C || k) && g ? g : /* @__PURE__ */ a.jsx(
|
|
3993
3997
|
kt,
|
|
3994
3998
|
{
|
|
3995
|
-
className:
|
|
3999
|
+
className: E("cta", {
|
|
3996
4000
|
center: C || k,
|
|
3997
4001
|
submitted: k
|
|
3998
4002
|
}),
|
|
@@ -4002,13 +4006,13 @@ const rn = ({
|
|
|
4002
4006
|
]
|
|
4003
4007
|
}
|
|
4004
4008
|
),
|
|
4005
|
-
|
|
4009
|
+
b && k && /* @__PURE__ */ a.jsx(Wt, { className: "success", children: typeof b == "string" ? b : F.formatMessage({ id: "form_success" }) })
|
|
4006
4010
|
] });
|
|
4007
4011
|
};
|
|
4008
|
-
const
|
|
4012
|
+
const $t = "passwordRules_", Sa = "isMoreThanEightCharacters", Ca = "includesNumberAndSymbol", Na = "includesLowerAndUppercase", zi = {
|
|
4009
4013
|
[Sa]: "8Characters",
|
|
4010
4014
|
[Ca]: "numberSymbol",
|
|
4011
|
-
[
|
|
4015
|
+
[Na]: "lowercaseUppercase"
|
|
4012
4016
|
}, Zi = ({
|
|
4013
4017
|
matchingRules: t = {
|
|
4014
4018
|
isMoreThanEightCharacters: !1,
|
|
@@ -4018,22 +4022,22 @@ const Nt = "passwordRules_", Sa = "isMoreThanEightCharacters", Ca = "includesNum
|
|
|
4018
4022
|
className: e = ""
|
|
4019
4023
|
}) => {
|
|
4020
4024
|
const n = H();
|
|
4021
|
-
return /* @__PURE__ */ a.jsxs("aside", { className:
|
|
4022
|
-
/* @__PURE__ */ a.jsx("small", { children: n.formatMessage({ id: `${
|
|
4023
|
-
/* @__PURE__ */ a.jsx("ul", { children: [Sa, Ca,
|
|
4025
|
+
return /* @__PURE__ */ a.jsxs("aside", { className: E("password-rules", e), children: [
|
|
4026
|
+
/* @__PURE__ */ a.jsx("small", { children: n.formatMessage({ id: `${$t}intro` }) }),
|
|
4027
|
+
/* @__PURE__ */ a.jsx("ul", { children: [Sa, Ca, Na].map(
|
|
4024
4028
|
(r) => /* @__PURE__ */ a.jsxs(
|
|
4025
4029
|
"li",
|
|
4026
4030
|
{
|
|
4027
|
-
className:
|
|
4031
|
+
className: E({ matches: t[r] }),
|
|
4028
4032
|
children: [
|
|
4029
4033
|
/* @__PURE__ */ a.jsxs(be, { children: [
|
|
4030
|
-
n.formatMessage({ id: `${
|
|
4034
|
+
n.formatMessage({ id: `${$t}rule_label` }),
|
|
4031
4035
|
" "
|
|
4032
4036
|
] }),
|
|
4033
|
-
/* @__PURE__ */ a.jsx("span", { children: n.formatMessage({ id: `${
|
|
4037
|
+
/* @__PURE__ */ a.jsx("span", { children: n.formatMessage({ id: `${$t}rule_${zi[r]}` }) }),
|
|
4034
4038
|
!t[r] && /* @__PURE__ */ a.jsxs(be, { element: "strong", children: [
|
|
4035
4039
|
" ",
|
|
4036
|
-
n.formatMessage({ id: `${
|
|
4040
|
+
n.formatMessage({ id: `${$t}notMet` })
|
|
4037
4041
|
] })
|
|
4038
4042
|
]
|
|
4039
4043
|
},
|
|
@@ -4062,15 +4066,15 @@ const Vl = ({
|
|
|
4062
4066
|
disabled: !0
|
|
4063
4067
|
}), u = async () => {
|
|
4064
4068
|
try {
|
|
4065
|
-
const
|
|
4069
|
+
const y = await n();
|
|
4066
4070
|
l((x) => ({
|
|
4067
4071
|
...x,
|
|
4068
4072
|
setUp: !0,
|
|
4069
|
-
id:
|
|
4073
|
+
id: y && y.id,
|
|
4070
4074
|
disabled: !1
|
|
4071
4075
|
}));
|
|
4072
|
-
} catch (
|
|
4073
|
-
l((x) => ({ ...x, setUp: !0, disabled: !0 })), s(
|
|
4076
|
+
} catch (y) {
|
|
4077
|
+
l((x) => ({ ...x, setUp: !0, disabled: !0 })), s(y);
|
|
4074
4078
|
}
|
|
4075
4079
|
};
|
|
4076
4080
|
if (ae(() => {
|
|
@@ -4083,24 +4087,24 @@ const Vl = ({
|
|
|
4083
4087
|
high: c.formatMessage({ id: `${g}high` }),
|
|
4084
4088
|
success: c.formatMessage({ id: `${g}success` }),
|
|
4085
4089
|
...t
|
|
4086
|
-
},
|
|
4090
|
+
}, _ = async (y) => {
|
|
4087
4091
|
if (!(!f || p))
|
|
4088
4092
|
try {
|
|
4089
|
-
l((x) => ({ ...x, rating:
|
|
4093
|
+
l((x) => ({ ...x, rating: y, disabled: !0 })), await r({ id: f, value: y });
|
|
4090
4094
|
} catch (x) {
|
|
4091
|
-
l((
|
|
4095
|
+
l((S) => ({ ...S, rating: null })), s(x);
|
|
4092
4096
|
} finally {
|
|
4093
4097
|
l((x) => ({ ...x, disabled: !1 }));
|
|
4094
4098
|
}
|
|
4095
4099
|
};
|
|
4096
|
-
return /* @__PURE__ */ a.jsxs("div", { className:
|
|
4100
|
+
return /* @__PURE__ */ a.jsxs("div", { className: E("rating", i), children: [
|
|
4097
4101
|
/* @__PURE__ */ a.jsx("span", { className: "label", children: v[m ? "success" : "text"] }),
|
|
4098
|
-
/* @__PURE__ */ a.jsx("ol", { children: Array.from(new Array(e).keys()).map((
|
|
4099
|
-
const x =
|
|
4102
|
+
/* @__PURE__ */ a.jsx("ol", { children: Array.from(new Array(e).keys()).map((y) => {
|
|
4103
|
+
const x = y + 1;
|
|
4100
4104
|
return /* @__PURE__ */ a.jsx(
|
|
4101
4105
|
"li",
|
|
4102
4106
|
{
|
|
4103
|
-
className:
|
|
4107
|
+
className: E({ selected: m && x <= m }),
|
|
4104
4108
|
children: /* @__PURE__ */ a.jsx(
|
|
4105
4109
|
se,
|
|
4106
4110
|
{
|
|
@@ -4115,8 +4119,8 @@ const Vl = ({
|
|
|
4115
4119
|
{ id: `${g}stars` },
|
|
4116
4120
|
{ number: x, total: e }
|
|
4117
4121
|
)}${x === 1 || x === e ? ` - ${v[x === 1 ? "low" : "high"]}` : ""}`,
|
|
4118
|
-
onClick: (
|
|
4119
|
-
|
|
4122
|
+
onClick: (S) => {
|
|
4123
|
+
S.preventDefault(), S.stopPropagation(), _(x);
|
|
4120
4124
|
},
|
|
4121
4125
|
disabled: p
|
|
4122
4126
|
}
|
|
@@ -4149,7 +4153,7 @@ const Yl = ({
|
|
|
4149
4153
|
return /* @__PURE__ */ a.jsxs(
|
|
4150
4154
|
"div",
|
|
4151
4155
|
{
|
|
4152
|
-
className:
|
|
4156
|
+
className: E("toggle", o),
|
|
4153
4157
|
onClick: (u) => {
|
|
4154
4158
|
u.preventDefault(), u.stopPropagation(), l(c === n[0].value ? n[1].value : n[0].value);
|
|
4155
4159
|
},
|
|
@@ -4158,7 +4162,7 @@ const Yl = ({
|
|
|
4158
4162
|
/* @__PURE__ */ a.jsx(
|
|
4159
4163
|
"ul",
|
|
4160
4164
|
{
|
|
4161
|
-
className:
|
|
4165
|
+
className: E("toggle-options", {
|
|
4162
4166
|
disabled: i,
|
|
4163
4167
|
on: c === n[1].value
|
|
4164
4168
|
}),
|
|
@@ -4208,7 +4212,7 @@ function Kl({ className: t = "", userId: e, userName: n, src: r, setUserImage: s
|
|
|
4208
4212
|
}
|
|
4209
4213
|
c(!1);
|
|
4210
4214
|
};
|
|
4211
|
-
return /* @__PURE__ */ a.jsxs("div", { className:
|
|
4215
|
+
return /* @__PURE__ */ a.jsxs("div", { className: E("profile-image-change-figure", t), children: [
|
|
4212
4216
|
/* @__PURE__ */ a.jsx(Ye, { className: "profile-image-change-picture", name: n, src: r, "data-testid": "profile-picture" }),
|
|
4213
4217
|
d && /* @__PURE__ */ a.jsx("p", { className: "error text-small", children: /* @__PURE__ */ a.jsx(ye, { id: "profile_image_change_error" }) }),
|
|
4214
4218
|
/* @__PURE__ */ a.jsx(
|
|
@@ -4298,62 +4302,62 @@ const Yi = ({
|
|
|
4298
4302
|
initialFormStatus: l = "NOT_SUBMITTED"
|
|
4299
4303
|
/* NOT_SUBMITTED */
|
|
4300
4304
|
}) => {
|
|
4301
|
-
const [u, f] = X([]), [m, p] = X(!0), [g, v] = X(l), { formatMessage:
|
|
4305
|
+
const [u, f] = X([]), [m, p] = X(!0), [g, v] = X(l), { formatMessage: _ } = H(), y = async (w) => {
|
|
4302
4306
|
w.preventDefault();
|
|
4303
4307
|
try {
|
|
4304
4308
|
await d(u), f([]), v(
|
|
4305
4309
|
"SUCCESS"
|
|
4306
4310
|
/* SUCCESS */
|
|
4307
4311
|
);
|
|
4308
|
-
} catch (
|
|
4312
|
+
} catch (b) {
|
|
4309
4313
|
v(
|
|
4310
4314
|
"ERROR"
|
|
4311
4315
|
/* ERROR */
|
|
4312
|
-
), c(
|
|
4316
|
+
), c(b);
|
|
4313
4317
|
}
|
|
4314
4318
|
}, x = (w) => {
|
|
4315
4319
|
w.preventDefault(), v(
|
|
4316
4320
|
"NOT_SUBMITTED"
|
|
4317
4321
|
/* NOT_SUBMITTED */
|
|
4318
4322
|
), p(!0), f([]);
|
|
4319
|
-
},
|
|
4323
|
+
}, S = (w) => {
|
|
4320
4324
|
w.preventDefault(), o(), v(
|
|
4321
4325
|
"CLOSED"
|
|
4322
4326
|
/* CLOSED */
|
|
4323
4327
|
);
|
|
4324
4328
|
};
|
|
4325
4329
|
return g === "CLOSED" ? null : g === "ERROR" || g === "SUCCESS" ? /* @__PURE__ */ a.jsxs("div", { className: "invite-form-wrapper", children: [
|
|
4326
|
-
/* @__PURE__ */ a.jsx("div", { className: "content centred", children: g === "SUCCESS" ? /* @__PURE__ */ a.jsx("h2", { className: "success-title", children:
|
|
4330
|
+
/* @__PURE__ */ a.jsx("div", { className: "content centred", children: g === "SUCCESS" ? /* @__PURE__ */ a.jsx("h2", { className: "success-title", children: _({ id: "inviteForm_success" }) }) : /* @__PURE__ */ a.jsxs("h2", { className: "error-title", children: [
|
|
4327
4331
|
" ",
|
|
4328
|
-
|
|
4332
|
+
_({ id: "inviteForm_error" })
|
|
4329
4333
|
] }) }),
|
|
4330
4334
|
/* @__PURE__ */ a.jsx(Oe, {}),
|
|
4331
4335
|
/* @__PURE__ */ a.jsx("div", { className: "footer", children: g === "SUCCESS" ? /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
4332
|
-
/* @__PURE__ */ a.jsx(se, { variant: "secondary", onClick: x, children:
|
|
4333
|
-
/* @__PURE__ */ a.jsx(se, { onClick:
|
|
4334
|
-
] }) : /* @__PURE__ */ a.jsx(se, { onClick: x, children:
|
|
4336
|
+
/* @__PURE__ */ a.jsx(se, { variant: "secondary", onClick: x, children: _({ id: "inviteForm_ctaSendMoreInvites" }) }),
|
|
4337
|
+
/* @__PURE__ */ a.jsx(se, { onClick: S, children: _({ id: "inviteForm_ctaDone" }) })
|
|
4338
|
+
] }) : /* @__PURE__ */ a.jsx(se, { onClick: x, children: _({ id: "inviteForm_ctaTryAgain" }) }) })
|
|
4335
4339
|
] }) : /* @__PURE__ */ a.jsx("div", { className: "invite-form-wrapper", children: /* @__PURE__ */ a.jsxs(
|
|
4336
4340
|
"form",
|
|
4337
4341
|
{
|
|
4338
4342
|
style: { backgroundColor: i },
|
|
4339
|
-
onSubmit:
|
|
4340
|
-
className:
|
|
4343
|
+
onSubmit: y,
|
|
4344
|
+
className: E("invite-form gtm-trackable"),
|
|
4341
4345
|
children: [
|
|
4342
4346
|
/* @__PURE__ */ a.jsxs("fieldset", { className: "content", children: [
|
|
4343
4347
|
/* @__PURE__ */ a.jsx("h2", { className: "title", style: { color: r }, children: t }),
|
|
4344
4348
|
/* @__PURE__ */ a.jsx("label", { htmlFor: "email-input", className: "label", style: { color: s }, children: e }),
|
|
4345
4349
|
/* @__PURE__ */ a.jsx(
|
|
4346
|
-
|
|
4350
|
+
$s,
|
|
4347
4351
|
{
|
|
4348
4352
|
id: "email-input",
|
|
4349
4353
|
inputClassName: "email-input input",
|
|
4350
|
-
placeholder:
|
|
4354
|
+
placeholder: _({ id: "inviteForm_email_placeholder" }),
|
|
4351
4355
|
emails: u,
|
|
4352
4356
|
onChange: (w) => {
|
|
4353
4357
|
f(w), p(!w.length);
|
|
4354
4358
|
},
|
|
4355
4359
|
autoFocus: !1,
|
|
4356
|
-
getLabel: (w,
|
|
4360
|
+
getLabel: (w, b, F) => /* @__PURE__ */ a.jsxs("div", { className: "email text-medium", children: [
|
|
4357
4361
|
/* @__PURE__ */ a.jsx("div", { "data-tag-item": !0, children: w }),
|
|
4358
4362
|
/* @__PURE__ */ a.jsx(
|
|
4359
4363
|
se,
|
|
@@ -4362,13 +4366,13 @@ const Yi = ({
|
|
|
4362
4366
|
size: "small",
|
|
4363
4367
|
icon: { icon: "close" },
|
|
4364
4368
|
onClick: () => {
|
|
4365
|
-
F(
|
|
4369
|
+
F(b), p(!u.length);
|
|
4366
4370
|
},
|
|
4367
4371
|
className: "remove-email-button",
|
|
4368
|
-
screenreaderText:
|
|
4372
|
+
screenreaderText: _({ id: "overlay_close" })
|
|
4369
4373
|
}
|
|
4370
4374
|
)
|
|
4371
|
-
] },
|
|
4375
|
+
] }, b)
|
|
4372
4376
|
}
|
|
4373
4377
|
)
|
|
4374
4378
|
] }),
|
|
@@ -4465,7 +4469,7 @@ const Ki = ({
|
|
|
4465
4469
|
"form",
|
|
4466
4470
|
{
|
|
4467
4471
|
onSubmit: u,
|
|
4468
|
-
className:
|
|
4472
|
+
className: E("search-form gtm-trackable", e),
|
|
4469
4473
|
"data-gtm-event-context": s,
|
|
4470
4474
|
"data-gtm-event-type": i,
|
|
4471
4475
|
children: /* @__PURE__ */ a.jsx(
|
|
@@ -4753,7 +4757,7 @@ const Ki = ({
|
|
|
4753
4757
|
const Xi = ({ className: t = "" }) => /* @__PURE__ */ a.jsxs(
|
|
4754
4758
|
"div",
|
|
4755
4759
|
{
|
|
4756
|
-
className:
|
|
4760
|
+
className: E("success-message", t),
|
|
4757
4761
|
"data-testid": "success-message",
|
|
4758
4762
|
children: [
|
|
4759
4763
|
/* @__PURE__ */ a.jsx("p", { className: "success-title", children: /* @__PURE__ */ a.jsx(ye, { id: "signup_success_title" }) }),
|
|
@@ -4811,12 +4815,12 @@ const eo = {
|
|
|
4811
4815
|
url: f,
|
|
4812
4816
|
logInButton: m,
|
|
4813
4817
|
successMessage: p
|
|
4814
|
-
}, [v,
|
|
4815
|
-
validFields:
|
|
4818
|
+
}, [v, _] = Yn(ma, eo), {
|
|
4819
|
+
validFields: y,
|
|
4816
4820
|
emailDetails: x,
|
|
4817
|
-
shouldManuallyApprove:
|
|
4821
|
+
shouldManuallyApprove: S,
|
|
4818
4822
|
shouldDisableButton: w,
|
|
4819
|
-
showSuccessMessage:
|
|
4823
|
+
showSuccessMessage: b,
|
|
4820
4824
|
showError: F
|
|
4821
4825
|
} = v, [R, Q] = oa([
|
|
4822
4826
|
"signup-this-session",
|
|
@@ -4831,30 +4835,30 @@ const eo = {
|
|
|
4831
4835
|
hiddenValidation: Y.createRef()
|
|
4832
4836
|
};
|
|
4833
4837
|
ae(() => {
|
|
4834
|
-
|
|
4835
|
-
}, [
|
|
4836
|
-
R["signup-this-session"] &&
|
|
4838
|
+
S === !0 && B.jobTitle.current && B.jobTitle.current.focus();
|
|
4839
|
+
}, [S]), ae(() => {
|
|
4840
|
+
R["signup-this-session"] && _([{ type: "showSuccessMessage", value: !0 }]);
|
|
4837
4841
|
}, [R]), ae(() => {
|
|
4838
|
-
|
|
4842
|
+
b && R["functional-cookie-consent"] && Q("signup-this-session", "true", {
|
|
4839
4843
|
path: "/",
|
|
4840
4844
|
maxAge: 3600
|
|
4841
4845
|
});
|
|
4842
|
-
}, [
|
|
4843
|
-
const
|
|
4846
|
+
}, [b]);
|
|
4847
|
+
const N = wt(() => Ji({
|
|
4844
4848
|
placeholders: n,
|
|
4845
4849
|
labels: e,
|
|
4846
4850
|
shouldShow: g,
|
|
4847
4851
|
functions: r,
|
|
4848
4852
|
refs: B,
|
|
4849
4853
|
state: v,
|
|
4850
|
-
dispatch:
|
|
4854
|
+
dispatch: _,
|
|
4851
4855
|
dataToSubmit: o,
|
|
4852
4856
|
intl: d
|
|
4853
|
-
}), [o, r, d, B, g, v]), C = w ? !0 :
|
|
4854
|
-
return g.successMessage &&
|
|
4857
|
+
}), [o, r, d, B, g, v]), C = w ? !0 : S ? !Object.values(y).every((k) => k === !0) : !y.name || !y.email || ["exists", "pending", "verify"].includes(x.boxType);
|
|
4858
|
+
return g.successMessage && b ? /* @__PURE__ */ a.jsx(Xi, { className: t }) : /* @__PURE__ */ a.jsxs(
|
|
4855
4859
|
"fieldset",
|
|
4856
4860
|
{
|
|
4857
|
-
className:
|
|
4861
|
+
className: E("signup-form-fieldset", t),
|
|
4858
4862
|
"data-testid": "signup-form",
|
|
4859
4863
|
children: [
|
|
4860
4864
|
g.title && /* @__PURE__ */ a.jsx("p", { className: "signup-title", children: /* @__PURE__ */ a.jsx(ye, { id: "signup_title" }) }),
|
|
@@ -4871,7 +4875,7 @@ const eo = {
|
|
|
4871
4875
|
className: "signup-form",
|
|
4872
4876
|
formRef: B.form,
|
|
4873
4877
|
id: "sign-up-form",
|
|
4874
|
-
fields:
|
|
4878
|
+
fields: N,
|
|
4875
4879
|
intlPath: "signup",
|
|
4876
4880
|
button: {
|
|
4877
4881
|
variant: "primary",
|
|
@@ -4907,12 +4911,12 @@ const eo = {
|
|
|
4907
4911
|
dataToSubmit: o,
|
|
4908
4912
|
createAccount: r.createAccount,
|
|
4909
4913
|
onSuccess: r.onSuccess,
|
|
4910
|
-
dispatch:
|
|
4914
|
+
dispatch: _,
|
|
4911
4915
|
state: v
|
|
4912
4916
|
});
|
|
4913
4917
|
},
|
|
4914
4918
|
onCatch: (k) => {
|
|
4915
|
-
r.handleError(k),
|
|
4919
|
+
r.handleError(k), _([
|
|
4916
4920
|
{ type: "showSuccessMessage", value: !1 },
|
|
4917
4921
|
{ type: "showError", value: !0 }
|
|
4918
4922
|
]);
|
|
@@ -4939,28 +4943,28 @@ function to() {
|
|
|
4939
4943
|
if (Rr)
|
|
4940
4944
|
return ue;
|
|
4941
4945
|
Rr = 1;
|
|
4942
|
-
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, s = t ? Symbol.for("react.strict_mode") : 60108, i = t ? Symbol.for("react.profiler") : 60114, o = t ? Symbol.for("react.provider") : 60109, c = t ? Symbol.for("react.context") : 60110, d = t ? Symbol.for("react.async_mode") : 60111, l = t ? Symbol.for("react.concurrent_mode") : 60111, u = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, m = t ? Symbol.for("react.suspense_list") : 60120, p = t ? Symbol.for("react.memo") : 60115, g = t ? Symbol.for("react.lazy") : 60116, v = t ? Symbol.for("react.block") : 60121,
|
|
4943
|
-
function
|
|
4944
|
-
if (typeof
|
|
4945
|
-
var F =
|
|
4946
|
+
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, s = t ? Symbol.for("react.strict_mode") : 60108, i = t ? Symbol.for("react.profiler") : 60114, o = t ? Symbol.for("react.provider") : 60109, c = t ? Symbol.for("react.context") : 60110, d = t ? Symbol.for("react.async_mode") : 60111, l = t ? Symbol.for("react.concurrent_mode") : 60111, u = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, m = t ? Symbol.for("react.suspense_list") : 60120, p = t ? Symbol.for("react.memo") : 60115, g = t ? Symbol.for("react.lazy") : 60116, v = t ? Symbol.for("react.block") : 60121, _ = t ? Symbol.for("react.fundamental") : 60117, y = t ? Symbol.for("react.responder") : 60118, x = t ? Symbol.for("react.scope") : 60119;
|
|
4947
|
+
function S(b) {
|
|
4948
|
+
if (typeof b == "object" && b !== null) {
|
|
4949
|
+
var F = b.$$typeof;
|
|
4946
4950
|
switch (F) {
|
|
4947
4951
|
case e:
|
|
4948
|
-
switch (
|
|
4952
|
+
switch (b = b.type, b) {
|
|
4949
4953
|
case d:
|
|
4950
4954
|
case l:
|
|
4951
4955
|
case r:
|
|
4952
4956
|
case i:
|
|
4953
4957
|
case s:
|
|
4954
4958
|
case f:
|
|
4955
|
-
return
|
|
4959
|
+
return b;
|
|
4956
4960
|
default:
|
|
4957
|
-
switch (
|
|
4961
|
+
switch (b = b && b.$$typeof, b) {
|
|
4958
4962
|
case c:
|
|
4959
4963
|
case u:
|
|
4960
4964
|
case g:
|
|
4961
4965
|
case p:
|
|
4962
4966
|
case o:
|
|
4963
|
-
return
|
|
4967
|
+
return b;
|
|
4964
4968
|
default:
|
|
4965
4969
|
return F;
|
|
4966
4970
|
}
|
|
@@ -4970,36 +4974,36 @@ function to() {
|
|
|
4970
4974
|
}
|
|
4971
4975
|
}
|
|
4972
4976
|
}
|
|
4973
|
-
function w(
|
|
4974
|
-
return
|
|
4977
|
+
function w(b) {
|
|
4978
|
+
return S(b) === l;
|
|
4975
4979
|
}
|
|
4976
|
-
return ue.AsyncMode = d, ue.ConcurrentMode = l, ue.ContextConsumer = c, ue.ContextProvider = o, ue.Element = e, ue.ForwardRef = u, ue.Fragment = r, ue.Lazy = g, ue.Memo = p, ue.Portal = n, ue.Profiler = i, ue.StrictMode = s, ue.Suspense = f, ue.isAsyncMode = function(
|
|
4977
|
-
return w(
|
|
4978
|
-
}, ue.isConcurrentMode = w, ue.isContextConsumer = function(
|
|
4979
|
-
return
|
|
4980
|
-
}, ue.isContextProvider = function(
|
|
4981
|
-
return
|
|
4982
|
-
}, ue.isElement = function(
|
|
4983
|
-
return typeof
|
|
4984
|
-
}, ue.isForwardRef = function(
|
|
4985
|
-
return
|
|
4986
|
-
}, ue.isFragment = function(
|
|
4987
|
-
return
|
|
4988
|
-
}, ue.isLazy = function(
|
|
4989
|
-
return
|
|
4990
|
-
}, ue.isMemo = function(
|
|
4991
|
-
return
|
|
4992
|
-
}, ue.isPortal = function(
|
|
4993
|
-
return
|
|
4994
|
-
}, ue.isProfiler = function(
|
|
4995
|
-
return
|
|
4996
|
-
}, ue.isStrictMode = function(
|
|
4997
|
-
return
|
|
4998
|
-
}, ue.isSuspense = function(
|
|
4999
|
-
return
|
|
5000
|
-
}, ue.isValidElementType = function(
|
|
5001
|
-
return typeof
|
|
5002
|
-
}, ue.typeOf =
|
|
4980
|
+
return ue.AsyncMode = d, ue.ConcurrentMode = l, ue.ContextConsumer = c, ue.ContextProvider = o, ue.Element = e, ue.ForwardRef = u, ue.Fragment = r, ue.Lazy = g, ue.Memo = p, ue.Portal = n, ue.Profiler = i, ue.StrictMode = s, ue.Suspense = f, ue.isAsyncMode = function(b) {
|
|
4981
|
+
return w(b) || S(b) === d;
|
|
4982
|
+
}, ue.isConcurrentMode = w, ue.isContextConsumer = function(b) {
|
|
4983
|
+
return S(b) === c;
|
|
4984
|
+
}, ue.isContextProvider = function(b) {
|
|
4985
|
+
return S(b) === o;
|
|
4986
|
+
}, ue.isElement = function(b) {
|
|
4987
|
+
return typeof b == "object" && b !== null && b.$$typeof === e;
|
|
4988
|
+
}, ue.isForwardRef = function(b) {
|
|
4989
|
+
return S(b) === u;
|
|
4990
|
+
}, ue.isFragment = function(b) {
|
|
4991
|
+
return S(b) === r;
|
|
4992
|
+
}, ue.isLazy = function(b) {
|
|
4993
|
+
return S(b) === g;
|
|
4994
|
+
}, ue.isMemo = function(b) {
|
|
4995
|
+
return S(b) === p;
|
|
4996
|
+
}, ue.isPortal = function(b) {
|
|
4997
|
+
return S(b) === n;
|
|
4998
|
+
}, ue.isProfiler = function(b) {
|
|
4999
|
+
return S(b) === i;
|
|
5000
|
+
}, ue.isStrictMode = function(b) {
|
|
5001
|
+
return S(b) === s;
|
|
5002
|
+
}, ue.isSuspense = function(b) {
|
|
5003
|
+
return S(b) === f;
|
|
5004
|
+
}, ue.isValidElementType = function(b) {
|
|
5005
|
+
return typeof b == "string" || typeof b == "function" || b === r || b === l || b === i || b === s || b === f || b === m || typeof b == "object" && b !== null && (b.$$typeof === g || b.$$typeof === p || b.$$typeof === o || b.$$typeof === c || b.$$typeof === u || b.$$typeof === _ || b.$$typeof === y || b.$$typeof === x || b.$$typeof === v);
|
|
5006
|
+
}, ue.typeOf = S, ue;
|
|
5003
5007
|
}
|
|
5004
5008
|
var de = {};
|
|
5005
5009
|
/** @license React v16.13.1
|
|
@@ -5013,27 +5017,27 @@ var de = {};
|
|
|
5013
5017
|
var Fr;
|
|
5014
5018
|
function no() {
|
|
5015
5019
|
return Fr || (Fr = 1, process.env.NODE_ENV !== "production" && function() {
|
|
5016
|
-
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, s = t ? Symbol.for("react.strict_mode") : 60108, i = t ? Symbol.for("react.profiler") : 60114, o = t ? Symbol.for("react.provider") : 60109, c = t ? Symbol.for("react.context") : 60110, d = t ? Symbol.for("react.async_mode") : 60111, l = t ? Symbol.for("react.concurrent_mode") : 60111, u = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, m = t ? Symbol.for("react.suspense_list") : 60120, p = t ? Symbol.for("react.memo") : 60115, g = t ? Symbol.for("react.lazy") : 60116, v = t ? Symbol.for("react.block") : 60121,
|
|
5017
|
-
function
|
|
5020
|
+
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, s = t ? Symbol.for("react.strict_mode") : 60108, i = t ? Symbol.for("react.profiler") : 60114, o = t ? Symbol.for("react.provider") : 60109, c = t ? Symbol.for("react.context") : 60110, d = t ? Symbol.for("react.async_mode") : 60111, l = t ? Symbol.for("react.concurrent_mode") : 60111, u = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, m = t ? Symbol.for("react.suspense_list") : 60120, p = t ? Symbol.for("react.memo") : 60115, g = t ? Symbol.for("react.lazy") : 60116, v = t ? Symbol.for("react.block") : 60121, _ = t ? Symbol.for("react.fundamental") : 60117, y = t ? Symbol.for("react.responder") : 60118, x = t ? Symbol.for("react.scope") : 60119;
|
|
5021
|
+
function S(D) {
|
|
5018
5022
|
return typeof D == "string" || typeof D == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
|
|
5019
|
-
D === r || D === l || D === i || D === s || D === f || D === m || typeof D == "object" && D !== null && (D.$$typeof === g || D.$$typeof === p || D.$$typeof === o || D.$$typeof === c || D.$$typeof === u || D.$$typeof ===
|
|
5023
|
+
D === r || D === l || D === i || D === s || D === f || D === m || typeof D == "object" && D !== null && (D.$$typeof === g || D.$$typeof === p || D.$$typeof === o || D.$$typeof === c || D.$$typeof === u || D.$$typeof === _ || D.$$typeof === y || D.$$typeof === x || D.$$typeof === v);
|
|
5020
5024
|
}
|
|
5021
5025
|
function w(D) {
|
|
5022
5026
|
if (typeof D == "object" && D !== null) {
|
|
5023
5027
|
var ve = D.$$typeof;
|
|
5024
5028
|
switch (ve) {
|
|
5025
5029
|
case e:
|
|
5026
|
-
var
|
|
5027
|
-
switch (
|
|
5030
|
+
var $e = D.type;
|
|
5031
|
+
switch ($e) {
|
|
5028
5032
|
case d:
|
|
5029
5033
|
case l:
|
|
5030
5034
|
case r:
|
|
5031
5035
|
case i:
|
|
5032
5036
|
case s:
|
|
5033
5037
|
case f:
|
|
5034
|
-
return
|
|
5038
|
+
return $e;
|
|
5035
5039
|
default:
|
|
5036
|
-
var Ce =
|
|
5040
|
+
var Ce = $e && $e.$$typeof;
|
|
5037
5041
|
switch (Ce) {
|
|
5038
5042
|
case c:
|
|
5039
5043
|
case u:
|
|
@@ -5050,7 +5054,7 @@ function no() {
|
|
|
5050
5054
|
}
|
|
5051
5055
|
}
|
|
5052
5056
|
}
|
|
5053
|
-
var
|
|
5057
|
+
var b = d, F = l, R = c, Q = o, B = e, N = u, C = r, k = g, j = p, $ = n, A = i, W = s, Z = f, z = !1;
|
|
5054
5058
|
function K(D) {
|
|
5055
5059
|
return z || (z = !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.")), T(D) || w(D) === d;
|
|
5056
5060
|
}
|
|
@@ -5090,11 +5094,11 @@ function no() {
|
|
|
5090
5094
|
function oe(D) {
|
|
5091
5095
|
return w(D) === f;
|
|
5092
5096
|
}
|
|
5093
|
-
de.AsyncMode =
|
|
5097
|
+
de.AsyncMode = b, de.ConcurrentMode = F, de.ContextConsumer = R, de.ContextProvider = Q, de.Element = B, de.ForwardRef = N, de.Fragment = C, de.Lazy = k, de.Memo = j, de.Portal = $, de.Profiler = A, de.StrictMode = W, de.Suspense = Z, de.isAsyncMode = K, de.isConcurrentMode = T, de.isContextConsumer = P, de.isContextProvider = q, de.isElement = L, de.isForwardRef = U, de.isFragment = te, de.isLazy = G, de.isMemo = V, de.isPortal = ee, de.isProfiler = re, de.isStrictMode = O, de.isSuspense = oe, de.isValidElementType = S, de.typeOf = w;
|
|
5094
5098
|
}()), de;
|
|
5095
5099
|
}
|
|
5096
5100
|
var Or;
|
|
5097
|
-
function
|
|
5101
|
+
function $a() {
|
|
5098
5102
|
return Or || (Or = 1, process.env.NODE_ENV === "production" ? Pt.exports = to() : Pt.exports = no()), Pt.exports;
|
|
5099
5103
|
}
|
|
5100
5104
|
/*
|
|
@@ -5216,7 +5220,7 @@ function so() {
|
|
|
5216
5220
|
if (Br)
|
|
5217
5221
|
return kn;
|
|
5218
5222
|
Br = 1;
|
|
5219
|
-
var t =
|
|
5223
|
+
var t = $a(), e = ro(), n = nr(), r = Pa(), s = ao(), i = function() {
|
|
5220
5224
|
};
|
|
5221
5225
|
process.env.NODE_ENV !== "production" && (i = function(c) {
|
|
5222
5226
|
var d = "Warning: " + c;
|
|
@@ -5237,20 +5241,20 @@ function so() {
|
|
|
5237
5241
|
return P;
|
|
5238
5242
|
}
|
|
5239
5243
|
var m = "<<anonymous>>", p = {
|
|
5240
|
-
array:
|
|
5241
|
-
bigint:
|
|
5242
|
-
bool:
|
|
5243
|
-
func:
|
|
5244
|
-
number:
|
|
5245
|
-
object:
|
|
5246
|
-
string:
|
|
5247
|
-
symbol:
|
|
5244
|
+
array: y("array"),
|
|
5245
|
+
bigint: y("bigint"),
|
|
5246
|
+
bool: y("boolean"),
|
|
5247
|
+
func: y("function"),
|
|
5248
|
+
number: y("number"),
|
|
5249
|
+
object: y("object"),
|
|
5250
|
+
string: y("string"),
|
|
5251
|
+
symbol: y("symbol"),
|
|
5248
5252
|
any: x(),
|
|
5249
|
-
arrayOf:
|
|
5253
|
+
arrayOf: S,
|
|
5250
5254
|
element: w(),
|
|
5251
|
-
elementType:
|
|
5255
|
+
elementType: b(),
|
|
5252
5256
|
instanceOf: F,
|
|
5253
|
-
node:
|
|
5257
|
+
node: N(),
|
|
5254
5258
|
objectOf: Q,
|
|
5255
5259
|
oneOf: R,
|
|
5256
5260
|
oneOfType: B,
|
|
@@ -5264,7 +5268,7 @@ function so() {
|
|
|
5264
5268
|
this.message = T, this.data = P && typeof P == "object" ? P : {}, this.stack = "";
|
|
5265
5269
|
}
|
|
5266
5270
|
v.prototype = Error.prototype;
|
|
5267
|
-
function
|
|
5271
|
+
function _(T) {
|
|
5268
5272
|
if (process.env.NODE_ENV !== "production")
|
|
5269
5273
|
var P = {}, q = 0;
|
|
5270
5274
|
function L(te, G, V, ee, re, O, oe) {
|
|
@@ -5287,7 +5291,7 @@ function so() {
|
|
|
5287
5291
|
var U = L.bind(null, !1);
|
|
5288
5292
|
return U.isRequired = L.bind(null, !0), U;
|
|
5289
5293
|
}
|
|
5290
|
-
function
|
|
5294
|
+
function y(T) {
|
|
5291
5295
|
function P(q, L, U, te, G, V) {
|
|
5292
5296
|
var ee = q[L], re = W(ee);
|
|
5293
5297
|
if (re !== T) {
|
|
@@ -5299,12 +5303,12 @@ function so() {
|
|
|
5299
5303
|
}
|
|
5300
5304
|
return null;
|
|
5301
5305
|
}
|
|
5302
|
-
return
|
|
5306
|
+
return _(P);
|
|
5303
5307
|
}
|
|
5304
5308
|
function x() {
|
|
5305
|
-
return
|
|
5309
|
+
return _(o);
|
|
5306
5310
|
}
|
|
5307
|
-
function
|
|
5311
|
+
function S(T) {
|
|
5308
5312
|
function P(q, L, U, te, G) {
|
|
5309
5313
|
if (typeof T != "function")
|
|
5310
5314
|
return new v("Property `" + G + "` of component `" + U + "` has invalid PropType notation inside arrayOf.");
|
|
@@ -5320,7 +5324,7 @@ function so() {
|
|
|
5320
5324
|
}
|
|
5321
5325
|
return null;
|
|
5322
5326
|
}
|
|
5323
|
-
return
|
|
5327
|
+
return _(P);
|
|
5324
5328
|
}
|
|
5325
5329
|
function w() {
|
|
5326
5330
|
function T(P, q, L, U, te) {
|
|
@@ -5331,9 +5335,9 @@ function so() {
|
|
|
5331
5335
|
}
|
|
5332
5336
|
return null;
|
|
5333
5337
|
}
|
|
5334
|
-
return
|
|
5338
|
+
return _(T);
|
|
5335
5339
|
}
|
|
5336
|
-
function
|
|
5340
|
+
function b() {
|
|
5337
5341
|
function T(P, q, L, U, te) {
|
|
5338
5342
|
var G = P[q];
|
|
5339
5343
|
if (!t.isValidElementType(G)) {
|
|
@@ -5342,7 +5346,7 @@ function so() {
|
|
|
5342
5346
|
}
|
|
5343
5347
|
return null;
|
|
5344
5348
|
}
|
|
5345
|
-
return
|
|
5349
|
+
return _(T);
|
|
5346
5350
|
}
|
|
5347
5351
|
function F(T) {
|
|
5348
5352
|
function P(q, L, U, te, G) {
|
|
@@ -5352,7 +5356,7 @@ function so() {
|
|
|
5352
5356
|
}
|
|
5353
5357
|
return null;
|
|
5354
5358
|
}
|
|
5355
|
-
return
|
|
5359
|
+
return _(P);
|
|
5356
5360
|
}
|
|
5357
5361
|
function R(T) {
|
|
5358
5362
|
if (!Array.isArray(T))
|
|
@@ -5369,7 +5373,7 @@ function so() {
|
|
|
5369
5373
|
});
|
|
5370
5374
|
return new v("Invalid " + te + " `" + G + "` of value `" + String(V) + "` " + ("supplied to `" + U + "`, expected one of " + re + "."));
|
|
5371
5375
|
}
|
|
5372
|
-
return
|
|
5376
|
+
return _(P);
|
|
5373
5377
|
}
|
|
5374
5378
|
function Q(T) {
|
|
5375
5379
|
function P(q, L, U, te, G) {
|
|
@@ -5386,7 +5390,7 @@ function so() {
|
|
|
5386
5390
|
}
|
|
5387
5391
|
return null;
|
|
5388
5392
|
}
|
|
5389
|
-
return
|
|
5393
|
+
return _(P);
|
|
5390
5394
|
}
|
|
5391
5395
|
function B(T) {
|
|
5392
5396
|
if (!Array.isArray(T))
|
|
@@ -5408,13 +5412,13 @@ function so() {
|
|
|
5408
5412
|
var ve = re.length > 0 ? ", expected one of type [" + re.join(", ") + "]" : "";
|
|
5409
5413
|
return new v("Invalid " + V + " `" + ee + "` supplied to " + ("`" + G + "`" + ve + "."));
|
|
5410
5414
|
}
|
|
5411
|
-
return
|
|
5415
|
+
return _(L);
|
|
5412
5416
|
}
|
|
5413
|
-
function
|
|
5417
|
+
function N() {
|
|
5414
5418
|
function T(P, q, L, U, te) {
|
|
5415
|
-
return
|
|
5419
|
+
return $(P[q]) ? null : new v("Invalid " + U + " `" + te + "` supplied to " + ("`" + L + "`, expected a ReactNode."));
|
|
5416
5420
|
}
|
|
5417
|
-
return
|
|
5421
|
+
return _(T);
|
|
5418
5422
|
}
|
|
5419
5423
|
function C(T, P, q, L, U) {
|
|
5420
5424
|
return new v(
|
|
@@ -5436,7 +5440,7 @@ function so() {
|
|
|
5436
5440
|
}
|
|
5437
5441
|
return null;
|
|
5438
5442
|
}
|
|
5439
|
-
return
|
|
5443
|
+
return _(P);
|
|
5440
5444
|
}
|
|
5441
5445
|
function j(T) {
|
|
5442
5446
|
function P(q, L, U, te, G) {
|
|
@@ -5459,9 +5463,9 @@ Valid keys: ` + JSON.stringify(Object.keys(T), null, " ")
|
|
|
5459
5463
|
}
|
|
5460
5464
|
return null;
|
|
5461
5465
|
}
|
|
5462
|
-
return
|
|
5466
|
+
return _(P);
|
|
5463
5467
|
}
|
|
5464
|
-
function
|
|
5468
|
+
function $(T) {
|
|
5465
5469
|
switch (typeof T) {
|
|
5466
5470
|
case "number":
|
|
5467
5471
|
case "string":
|
|
@@ -5471,7 +5475,7 @@ Valid keys: ` + JSON.stringify(Object.keys(T), null, " ")
|
|
|
5471
5475
|
return !T;
|
|
5472
5476
|
case "object":
|
|
5473
5477
|
if (Array.isArray(T))
|
|
5474
|
-
return T.every(
|
|
5478
|
+
return T.every($);
|
|
5475
5479
|
if (T === null || c(T))
|
|
5476
5480
|
return !0;
|
|
5477
5481
|
var P = f(T);
|
|
@@ -5479,12 +5483,12 @@ Valid keys: ` + JSON.stringify(Object.keys(T), null, " ")
|
|
|
5479
5483
|
var q = P.call(T), L;
|
|
5480
5484
|
if (P !== T.entries) {
|
|
5481
5485
|
for (; !(L = q.next()).done; )
|
|
5482
|
-
if (
|
|
5486
|
+
if (!$(L.value))
|
|
5483
5487
|
return !1;
|
|
5484
5488
|
} else
|
|
5485
5489
|
for (; !(L = q.next()).done; ) {
|
|
5486
5490
|
var U = L.value;
|
|
5487
|
-
if (U &&
|
|
5491
|
+
if (U && !$(U[1]))
|
|
5488
5492
|
return !1;
|
|
5489
5493
|
}
|
|
5490
5494
|
} else
|
|
@@ -5583,7 +5587,7 @@ function io() {
|
|
|
5583
5587
|
}, Tn;
|
|
5584
5588
|
}
|
|
5585
5589
|
if (process.env.NODE_ENV !== "production") {
|
|
5586
|
-
var oo =
|
|
5590
|
+
var oo = $a(), co = !0;
|
|
5587
5591
|
Zn.exports = so()(oo.isElement, co);
|
|
5588
5592
|
} else
|
|
5589
5593
|
Zn.exports = io()();
|
|
@@ -5817,7 +5821,7 @@ function zr(t) {
|
|
|
5817
5821
|
return t;
|
|
5818
5822
|
}
|
|
5819
5823
|
function So(t, e, n) {
|
|
5820
|
-
return e =
|
|
5824
|
+
return e = No(e), e in t ? Object.defineProperty(t, e, {
|
|
5821
5825
|
value: n,
|
|
5822
5826
|
enumerable: !0,
|
|
5823
5827
|
configurable: !0,
|
|
@@ -5836,7 +5840,7 @@ function Co(t, e) {
|
|
|
5836
5840
|
}
|
|
5837
5841
|
return (e === "string" ? String : Number)(t);
|
|
5838
5842
|
}
|
|
5839
|
-
function
|
|
5843
|
+
function No(t) {
|
|
5840
5844
|
var e = Co(t, "string");
|
|
5841
5845
|
return typeof e == "symbol" ? e : String(e);
|
|
5842
5846
|
}
|
|
@@ -5853,7 +5857,7 @@ var Zr = {
|
|
|
5853
5857
|
var r = e.indexOf(n);
|
|
5854
5858
|
r !== -1 && e.splice(r, 1), e.length > 0 && e[e.length - 1].unpause();
|
|
5855
5859
|
}
|
|
5856
|
-
},
|
|
5860
|
+
}, $o = function(e) {
|
|
5857
5861
|
return e.tagName && e.tagName.toLowerCase() === "input" && typeof e.select == "function";
|
|
5858
5862
|
}, Po = function(e) {
|
|
5859
5863
|
return (e == null ? void 0 : e.key) === "Escape" || (e == null ? void 0 : e.key) === "Esc" || (e == null ? void 0 : e.keyCode) === 27;
|
|
@@ -5919,24 +5923,24 @@ var Zr = {
|
|
|
5919
5923
|
delayInitialFocusTimer: void 0,
|
|
5920
5924
|
// the most recent KeyboardEvent for the configured nav key (typically [SHIFT+]TAB), if any
|
|
5921
5925
|
recentNavEvent: void 0
|
|
5922
|
-
}, c, d = function(k, j,
|
|
5923
|
-
return k && k[j] !== void 0 ? k[j] : i[
|
|
5926
|
+
}, c, d = function(k, j, $) {
|
|
5927
|
+
return k && k[j] !== void 0 ? k[j] : i[$ || j];
|
|
5924
5928
|
}, l = function(k, j) {
|
|
5925
|
-
var
|
|
5929
|
+
var $ = typeof (j == null ? void 0 : j.composedPath) == "function" ? j.composedPath() : void 0;
|
|
5926
5930
|
return o.containerGroups.findIndex(function(A) {
|
|
5927
5931
|
var W = A.container, Z = A.tabbableNodes;
|
|
5928
5932
|
return W.contains(k) || // fall back to explicit tabbable search which will take into consideration any
|
|
5929
5933
|
// web components if the `tabbableOptions.getShadowRoot` option was used for
|
|
5930
5934
|
// the trap, enabling shadow DOM support in tabbable (`Node.contains()` doesn't
|
|
5931
5935
|
// look inside web components even if open)
|
|
5932
|
-
(
|
|
5936
|
+
($ == null ? void 0 : $.includes(W)) || Z.find(function(z) {
|
|
5933
5937
|
return z === k;
|
|
5934
5938
|
});
|
|
5935
5939
|
});
|
|
5936
5940
|
}, u = function(k) {
|
|
5937
5941
|
var j = i[k];
|
|
5938
5942
|
if (typeof j == "function") {
|
|
5939
|
-
for (var
|
|
5943
|
+
for (var $ = arguments.length, A = new Array($ > 1 ? $ - 1 : 0), W = 1; W < $; W++)
|
|
5940
5944
|
A[W - 1] = arguments[W];
|
|
5941
5945
|
j = j.apply(void 0, A);
|
|
5942
5946
|
}
|
|
@@ -5957,17 +5961,17 @@ var Zr = {
|
|
|
5957
5961
|
if (l(r.activeElement) >= 0)
|
|
5958
5962
|
k = r.activeElement;
|
|
5959
5963
|
else {
|
|
5960
|
-
var j = o.tabbableGroups[0],
|
|
5961
|
-
k =
|
|
5964
|
+
var j = o.tabbableGroups[0], $ = j && j.firstTabbableNode;
|
|
5965
|
+
k = $ || u("fallbackFocus");
|
|
5962
5966
|
}
|
|
5963
5967
|
if (!k)
|
|
5964
5968
|
throw new Error("Your focus-trap needs to have at least one focusable element");
|
|
5965
5969
|
return k;
|
|
5966
5970
|
}, m = function() {
|
|
5967
5971
|
if (o.containerGroups = o.containers.map(function(k) {
|
|
5968
|
-
var j = Ia(k, i.tabbableOptions),
|
|
5972
|
+
var j = Ia(k, i.tabbableOptions), $ = La(k, i.tabbableOptions), A = j.length > 0 ? j[0] : void 0, W = j.length > 0 ? j[j.length - 1] : void 0, Z = $.find(function(T) {
|
|
5969
5973
|
return We(T);
|
|
5970
|
-
}), z =
|
|
5974
|
+
}), z = $.slice().reverse().find(function(T) {
|
|
5971
5975
|
return We(T);
|
|
5972
5976
|
}), K = !!j.find(function(T) {
|
|
5973
5977
|
return Ie(T) > 0;
|
|
@@ -5975,7 +5979,7 @@ var Zr = {
|
|
|
5975
5979
|
return {
|
|
5976
5980
|
container: k,
|
|
5977
5981
|
tabbableNodes: j,
|
|
5978
|
-
focusableNodes:
|
|
5982
|
+
focusableNodes: $,
|
|
5979
5983
|
/** True if at least one node with positive `tabindex` was found in this container. */
|
|
5980
5984
|
posTabIndexesFound: K,
|
|
5981
5985
|
/** First tabbable node in container, __tabindex__ order; `undefined` if none. */
|
|
@@ -6003,9 +6007,9 @@ var Zr = {
|
|
|
6003
6007
|
*/
|
|
6004
6008
|
nextTabbableNode: function(P) {
|
|
6005
6009
|
var q = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0, L = j.indexOf(P);
|
|
6006
|
-
return L < 0 ? q ?
|
|
6010
|
+
return L < 0 ? q ? $.slice($.indexOf(P) + 1).find(function(U) {
|
|
6007
6011
|
return We(U);
|
|
6008
|
-
}) :
|
|
6012
|
+
}) : $.slice(0, $.indexOf(P)).reverse().find(function(U) {
|
|
6009
6013
|
return We(U);
|
|
6010
6014
|
}) : j[L + (q ? 1 : -1)];
|
|
6011
6015
|
}
|
|
@@ -6030,17 +6034,17 @@ var Zr = {
|
|
|
6030
6034
|
}
|
|
6031
6035
|
k.focus({
|
|
6032
6036
|
preventScroll: !!i.preventScroll
|
|
6033
|
-
}), o.mostRecentlyFocusedNode = k,
|
|
6037
|
+
}), o.mostRecentlyFocusedNode = k, $o(k) && k.select();
|
|
6034
6038
|
}
|
|
6035
6039
|
}, v = function(k) {
|
|
6036
6040
|
var j = u("setReturnFocus", k);
|
|
6037
6041
|
return j || (j === !1 ? !1 : k);
|
|
6038
|
-
},
|
|
6039
|
-
var j = k.target,
|
|
6040
|
-
j = j || Mt(
|
|
6042
|
+
}, _ = function(k) {
|
|
6043
|
+
var j = k.target, $ = k.event, A = k.isBackward, W = A === void 0 ? !1 : A;
|
|
6044
|
+
j = j || Mt($), m();
|
|
6041
6045
|
var Z = null;
|
|
6042
6046
|
if (o.tabbableGroups.length > 0) {
|
|
6043
|
-
var z = l(j,
|
|
6047
|
+
var z = l(j, $), K = z >= 0 ? o.containerGroups[z] : void 0;
|
|
6044
6048
|
if (z < 0)
|
|
6045
6049
|
W ? Z = o.tabbableGroups[o.tabbableGroups.length - 1].lastTabbableNode : Z = o.tabbableGroups[0].firstTabbableNode;
|
|
6046
6050
|
else if (W) {
|
|
@@ -6052,7 +6056,7 @@ var Zr = {
|
|
|
6052
6056
|
var P = T === 0 ? o.tabbableGroups.length - 1 : T - 1, q = o.tabbableGroups[P];
|
|
6053
6057
|
Z = Ie(j) >= 0 ? q.lastTabbableNode : q.lastDomTabbableNode;
|
|
6054
6058
|
} else
|
|
6055
|
-
vt(
|
|
6059
|
+
vt($) || (Z = K.nextTabbableNode(j, !1));
|
|
6056
6060
|
} else {
|
|
6057
6061
|
var L = Vr(o.tabbableGroups, function(G) {
|
|
6058
6062
|
var V = G.lastTabbableNode;
|
|
@@ -6062,12 +6066,12 @@ var Zr = {
|
|
|
6062
6066
|
var U = L === o.tabbableGroups.length - 1 ? 0 : L + 1, te = o.tabbableGroups[U];
|
|
6063
6067
|
Z = Ie(j) >= 0 ? te.firstTabbableNode : te.firstDomTabbableNode;
|
|
6064
6068
|
} else
|
|
6065
|
-
vt(
|
|
6069
|
+
vt($) || (Z = K.nextTabbableNode(j));
|
|
6066
6070
|
}
|
|
6067
6071
|
} else
|
|
6068
6072
|
Z = u("fallbackFocus");
|
|
6069
6073
|
return Z;
|
|
6070
|
-
},
|
|
6074
|
+
}, y = function(k) {
|
|
6071
6075
|
var j = Mt(k);
|
|
6072
6076
|
if (!(l(j, k) >= 0)) {
|
|
6073
6077
|
if (lt(i.clickOutsideDeactivates, k)) {
|
|
@@ -6085,9 +6089,9 @@ var Zr = {
|
|
|
6085
6089
|
lt(i.allowOutsideClick, k) || k.preventDefault();
|
|
6086
6090
|
}
|
|
6087
6091
|
}, x = function(k) {
|
|
6088
|
-
var j = Mt(k),
|
|
6089
|
-
if (
|
|
6090
|
-
|
|
6092
|
+
var j = Mt(k), $ = l(j, k) >= 0;
|
|
6093
|
+
if ($ || j instanceof Document)
|
|
6094
|
+
$ && (o.mostRecentlyFocusedNode = j);
|
|
6091
6095
|
else {
|
|
6092
6096
|
k.stopImmediatePropagation();
|
|
6093
6097
|
var A, W = !0;
|
|
@@ -6108,7 +6112,7 @@ var Zr = {
|
|
|
6108
6112
|
}) || (W = !1);
|
|
6109
6113
|
else
|
|
6110
6114
|
W = !1;
|
|
6111
|
-
W && (A =
|
|
6115
|
+
W && (A = _({
|
|
6112
6116
|
// move FROM the MRU node, not event-related node (which will be the node that is
|
|
6113
6117
|
// outside the trap causing the focus escape we're trying to fix)
|
|
6114
6118
|
target: o.mostRecentlyFocusedNode,
|
|
@@ -6116,34 +6120,34 @@ var Zr = {
|
|
|
6116
6120
|
})), g(A || o.mostRecentlyFocusedNode || f());
|
|
6117
6121
|
}
|
|
6118
6122
|
o.recentNavEvent = void 0;
|
|
6119
|
-
},
|
|
6123
|
+
}, S = function(k) {
|
|
6120
6124
|
var j = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1;
|
|
6121
6125
|
o.recentNavEvent = k;
|
|
6122
|
-
var
|
|
6126
|
+
var $ = _({
|
|
6123
6127
|
event: k,
|
|
6124
6128
|
isBackward: j
|
|
6125
6129
|
});
|
|
6126
|
-
|
|
6130
|
+
$ && (vt(k) && k.preventDefault(), g($));
|
|
6127
6131
|
}, w = function(k) {
|
|
6128
6132
|
if (Po(k) && lt(i.escapeDeactivates, k) !== !1) {
|
|
6129
6133
|
k.preventDefault(), c.deactivate();
|
|
6130
6134
|
return;
|
|
6131
6135
|
}
|
|
6132
|
-
(i.isKeyForward(k) || i.isKeyBackward(k)) &&
|
|
6133
|
-
},
|
|
6136
|
+
(i.isKeyForward(k) || i.isKeyBackward(k)) && S(k, i.isKeyBackward(k));
|
|
6137
|
+
}, b = function(k) {
|
|
6134
6138
|
var j = Mt(k);
|
|
6135
6139
|
l(j, k) >= 0 || lt(i.clickOutsideDeactivates, k) || lt(i.allowOutsideClick, k) || (k.preventDefault(), k.stopImmediatePropagation());
|
|
6136
6140
|
}, F = function() {
|
|
6137
6141
|
if (o.active)
|
|
6138
6142
|
return Zr.activateTrap(s, c), o.delayInitialFocusTimer = i.delayInitialFocus ? Hr(function() {
|
|
6139
6143
|
g(f());
|
|
6140
|
-
}) : g(f()), r.addEventListener("focusin", x, !0), r.addEventListener("mousedown",
|
|
6144
|
+
}) : g(f()), r.addEventListener("focusin", x, !0), r.addEventListener("mousedown", y, {
|
|
6141
6145
|
capture: !0,
|
|
6142
6146
|
passive: !1
|
|
6143
|
-
}), r.addEventListener("touchstart",
|
|
6147
|
+
}), r.addEventListener("touchstart", y, {
|
|
6144
6148
|
capture: !0,
|
|
6145
6149
|
passive: !1
|
|
6146
|
-
}), r.addEventListener("click",
|
|
6150
|
+
}), r.addEventListener("click", b, {
|
|
6147
6151
|
capture: !0,
|
|
6148
6152
|
passive: !1
|
|
6149
6153
|
}), r.addEventListener("keydown", w, {
|
|
@@ -6152,16 +6156,16 @@ var Zr = {
|
|
|
6152
6156
|
}), c;
|
|
6153
6157
|
}, R = function() {
|
|
6154
6158
|
if (o.active)
|
|
6155
|
-
return r.removeEventListener("focusin", x, !0), r.removeEventListener("mousedown",
|
|
6159
|
+
return r.removeEventListener("focusin", x, !0), r.removeEventListener("mousedown", y, !0), r.removeEventListener("touchstart", y, !0), r.removeEventListener("click", b, !0), r.removeEventListener("keydown", w, !0), c;
|
|
6156
6160
|
}, Q = function(k) {
|
|
6157
|
-
var j = k.some(function(
|
|
6158
|
-
var A = Array.from(
|
|
6161
|
+
var j = k.some(function($) {
|
|
6162
|
+
var A = Array.from($.removedNodes);
|
|
6159
6163
|
return A.some(function(W) {
|
|
6160
6164
|
return W === o.mostRecentlyFocusedNode;
|
|
6161
6165
|
});
|
|
6162
6166
|
});
|
|
6163
6167
|
j && g(f());
|
|
6164
|
-
}, B = typeof window < "u" && "MutationObserver" in window ? new MutationObserver(Q) : void 0,
|
|
6168
|
+
}, B = typeof window < "u" && "MutationObserver" in window ? new MutationObserver(Q) : void 0, N = function() {
|
|
6165
6169
|
B && (B.disconnect(), o.active && !o.paused && o.containers.map(function(k) {
|
|
6166
6170
|
B.observe(k, {
|
|
6167
6171
|
subtree: !0,
|
|
@@ -6179,10 +6183,10 @@ var Zr = {
|
|
|
6179
6183
|
activate: function(k) {
|
|
6180
6184
|
if (o.active)
|
|
6181
6185
|
return this;
|
|
6182
|
-
var j = d(k, "onActivate"),
|
|
6186
|
+
var j = d(k, "onActivate"), $ = d(k, "onPostActivate"), A = d(k, "checkCanFocusTrap");
|
|
6183
6187
|
A || m(), o.active = !0, o.paused = !1, o.nodeFocusedBeforeActivation = r.activeElement, j == null || j();
|
|
6184
6188
|
var W = function() {
|
|
6185
|
-
A && m(), F(),
|
|
6189
|
+
A && m(), F(), N(), $ == null || $();
|
|
6186
6190
|
};
|
|
6187
6191
|
return A ? (A(o.containers.concat()).then(W, W), this) : (W(), this);
|
|
6188
6192
|
},
|
|
@@ -6194,9 +6198,9 @@ var Zr = {
|
|
|
6194
6198
|
onPostDeactivate: i.onPostDeactivate,
|
|
6195
6199
|
checkCanReturnFocus: i.checkCanReturnFocus
|
|
6196
6200
|
}, k);
|
|
6197
|
-
clearTimeout(o.delayInitialFocusTimer), o.delayInitialFocusTimer = void 0, R(), o.active = !1, o.paused = !1,
|
|
6198
|
-
var
|
|
6199
|
-
|
|
6201
|
+
clearTimeout(o.delayInitialFocusTimer), o.delayInitialFocusTimer = void 0, R(), o.active = !1, o.paused = !1, N(), Zr.deactivateTrap(s, c);
|
|
6202
|
+
var $ = d(j, "onDeactivate"), A = d(j, "onPostDeactivate"), W = d(j, "checkCanReturnFocus"), Z = d(j, "returnFocus", "returnFocusOnDeactivate");
|
|
6203
|
+
$ == null || $();
|
|
6200
6204
|
var z = function() {
|
|
6201
6205
|
Hr(function() {
|
|
6202
6206
|
Z && g(v(o.nodeFocusedBeforeActivation)), A == null || A();
|
|
@@ -6207,20 +6211,20 @@ var Zr = {
|
|
|
6207
6211
|
pause: function(k) {
|
|
6208
6212
|
if (o.paused || !o.active)
|
|
6209
6213
|
return this;
|
|
6210
|
-
var j = d(k, "onPause"),
|
|
6211
|
-
return o.paused = !0, j == null || j(), R(),
|
|
6214
|
+
var j = d(k, "onPause"), $ = d(k, "onPostPause");
|
|
6215
|
+
return o.paused = !0, j == null || j(), R(), N(), $ == null || $(), this;
|
|
6212
6216
|
},
|
|
6213
6217
|
unpause: function(k) {
|
|
6214
6218
|
if (!o.paused || !o.active)
|
|
6215
6219
|
return this;
|
|
6216
|
-
var j = d(k, "onUnpause"),
|
|
6217
|
-
return o.paused = !1, j == null || j(), m(), F(),
|
|
6220
|
+
var j = d(k, "onUnpause"), $ = d(k, "onPostUnpause");
|
|
6221
|
+
return o.paused = !1, j == null || j(), m(), F(), N(), $ == null || $(), this;
|
|
6218
6222
|
},
|
|
6219
6223
|
updateContainerElements: function(k) {
|
|
6220
6224
|
var j = [].concat(k).filter(Boolean);
|
|
6221
|
-
return o.containers = j.map(function(
|
|
6222
|
-
return typeof
|
|
6223
|
-
}), o.active && m(),
|
|
6225
|
+
return o.containers = j.map(function($) {
|
|
6226
|
+
return typeof $ == "string" ? r.querySelector($) : $;
|
|
6227
|
+
}), o.active && m(), N(), this;
|
|
6224
6228
|
}
|
|
6225
6229
|
}, c.updateContainerElements(e), c;
|
|
6226
6230
|
};
|
|
@@ -6564,7 +6568,7 @@ rr.defaultProps = {
|
|
|
6564
6568
|
var Qo = rr;
|
|
6565
6569
|
const Jo = /* @__PURE__ */ la(Qo);
|
|
6566
6570
|
const qa = ({ element: t = "section", children: e, className: n, ...r }) => Y.createElement(t, {
|
|
6567
|
-
className:
|
|
6571
|
+
className: E("modal", n),
|
|
6568
6572
|
children: typeof e == "string" ? /* @__PURE__ */ a.jsx("p", { children: e }) : e,
|
|
6569
6573
|
...r
|
|
6570
6574
|
});
|
|
@@ -6584,27 +6588,27 @@ const an = ({
|
|
|
6584
6588
|
gtmContext: f = "Modal"
|
|
6585
6589
|
}) => {
|
|
6586
6590
|
const m = H(), [p, g] = X(e), v = (x) => {
|
|
6587
|
-
x.key === "Escape" &&
|
|
6591
|
+
x.key === "Escape" && _(!1);
|
|
6588
6592
|
};
|
|
6589
6593
|
ae(() => (window.addEventListener("keyup", v), () => {
|
|
6590
6594
|
window.removeEventListener("keyup", v);
|
|
6591
6595
|
}));
|
|
6592
|
-
const
|
|
6596
|
+
const _ = (x) => {
|
|
6593
6597
|
g(x), x ? (s(), document.body.classList.add("has-overlay")) : (i(), document.body.classList.remove("has-overlay"));
|
|
6594
6598
|
};
|
|
6595
6599
|
ae(() => {
|
|
6596
|
-
|
|
6600
|
+
_(e);
|
|
6597
6601
|
}, [e]);
|
|
6598
|
-
const
|
|
6599
|
-
return /* @__PURE__ */ a.jsx("div", { className:
|
|
6602
|
+
const y = r ? { "--max-width": `${r / 16}rem` } : {};
|
|
6603
|
+
return /* @__PURE__ */ a.jsx("div", { className: E("overlay", { open: p }), role: "dialog", children: /* @__PURE__ */ a.jsx(
|
|
6600
6604
|
qa,
|
|
6601
6605
|
{
|
|
6602
6606
|
id: t,
|
|
6603
|
-
className:
|
|
6607
|
+
className: E("overlay-modal", u, {
|
|
6604
6608
|
"has-max-width": r
|
|
6605
6609
|
}),
|
|
6606
6610
|
hidden: !p,
|
|
6607
|
-
style:
|
|
6611
|
+
style: y,
|
|
6608
6612
|
children: e && /* @__PURE__ */ a.jsx(Jo, { children: /* @__PURE__ */ a.jsxs("div", { className: "overlay-content", children: [
|
|
6609
6613
|
/* @__PURE__ */ a.jsxs("div", { className: "top", children: [
|
|
6610
6614
|
c && /* @__PURE__ */ a.jsx("h2", { className: "modal-title", children: c }),
|
|
@@ -6614,7 +6618,7 @@ const an = ({
|
|
|
6614
6618
|
variant: "tertiary",
|
|
6615
6619
|
size: "medium",
|
|
6616
6620
|
icon: { icon: "close" },
|
|
6617
|
-
onClick: () =>
|
|
6621
|
+
onClick: () => _(!1),
|
|
6618
6622
|
className: "gtm-trackable",
|
|
6619
6623
|
"data-gtm-event-type": "close-modal-click",
|
|
6620
6624
|
"data-gtm-event-context": f,
|
|
@@ -6659,7 +6663,7 @@ const Jl = ({
|
|
|
6659
6663
|
showDivider: !1,
|
|
6660
6664
|
showIcon: o,
|
|
6661
6665
|
functions: { onClose: c },
|
|
6662
|
-
className:
|
|
6666
|
+
className: E("invite-modal", t, { success: !!n }),
|
|
6663
6667
|
children: /* @__PURE__ */ a.jsx(
|
|
6664
6668
|
Yi,
|
|
6665
6669
|
{
|
|
@@ -6835,13 +6839,13 @@ const Xl = ({ members: t }) => {
|
|
|
6835
6839
|
gtmEvent: "learning-hub"
|
|
6836
6840
|
}
|
|
6837
6841
|
}, tc = ({ data: t, cta: e, link: n, gtmContext: r }) => {
|
|
6838
|
-
var v;
|
|
6842
|
+
var v, _;
|
|
6839
6843
|
const s = H(), [i, o] = X({
|
|
6840
6844
|
loading: !1,
|
|
6841
6845
|
registered: t.registered || !1
|
|
6842
6846
|
});
|
|
6843
6847
|
ae(() => {
|
|
6844
|
-
t.registered && o((
|
|
6848
|
+
t.registered && o((y) => ({ ...y, registered: !0 }));
|
|
6845
6849
|
}, [t.registered]);
|
|
6846
6850
|
const { customLinkText: c, startDate: d, dateHasPassed: l, pill: u, slug: f } = t, m = t.contentType;
|
|
6847
6851
|
let p = "";
|
|
@@ -6869,35 +6873,43 @@ const Xl = ({ members: t }) => {
|
|
|
6869
6873
|
children: c || s.formatMessage({ id: "card_cta_people" })
|
|
6870
6874
|
}
|
|
6871
6875
|
) : null;
|
|
6872
|
-
const g = ["microcourse", "event"];
|
|
6876
|
+
const g = ["communityPage", "microcourse", "event"];
|
|
6873
6877
|
if (e && e.onClick && g.includes(m) && u !== "premium") {
|
|
6874
|
-
const
|
|
6875
|
-
if (
|
|
6876
|
-
o((
|
|
6878
|
+
const y = i.loading || i.registered || ((_ = t == null ? void 0 : t.members) == null ? void 0 : _.isMember), x = async (S) => {
|
|
6879
|
+
if (S.preventDefault(), S.stopPropagation(), !(y || !e || !e.onClick)) {
|
|
6880
|
+
o((w) => ({ ...w, loading: !0 }));
|
|
6877
6881
|
try {
|
|
6878
|
-
const
|
|
6879
|
-
o(
|
|
6882
|
+
const w = await e.onClick(t);
|
|
6883
|
+
o(w === "success" ? () => ({ registered: !0, loading: !1 }) : (b) => ({ ...b, loading: !1 }));
|
|
6880
6884
|
} catch {
|
|
6881
|
-
o((
|
|
6885
|
+
o((b) => ({ ...b, loading: !1 }));
|
|
6882
6886
|
}
|
|
6883
6887
|
}
|
|
6884
6888
|
};
|
|
6885
|
-
return /* @__PURE__ */ a.jsx(
|
|
6886
|
-
|
|
6889
|
+
return /* @__PURE__ */ a.jsx(
|
|
6890
|
+
"p",
|
|
6887
6891
|
{
|
|
6888
|
-
|
|
6889
|
-
|
|
6890
|
-
|
|
6891
|
-
|
|
6892
|
-
|
|
6893
|
-
|
|
6894
|
-
|
|
6895
|
-
|
|
6896
|
-
|
|
6897
|
-
|
|
6898
|
-
|
|
6892
|
+
className: E("cta-wrapper", {
|
|
6893
|
+
"has-member-section": t == null ? void 0 : t.members
|
|
6894
|
+
}),
|
|
6895
|
+
children: /* @__PURE__ */ a.jsx(
|
|
6896
|
+
se,
|
|
6897
|
+
{
|
|
6898
|
+
onClick: x,
|
|
6899
|
+
className: "gtm-trackable",
|
|
6900
|
+
size: "small",
|
|
6901
|
+
styling: { fullWidth: !0 },
|
|
6902
|
+
disabled: y,
|
|
6903
|
+
"data-gtm-event-context": `${r}Page-${m}: ${f}`,
|
|
6904
|
+
"data-gtm-event-type": `${r}-${m}-register-click`,
|
|
6905
|
+
"data-testid": "in-card-button",
|
|
6906
|
+
children: c || s.formatMessage({
|
|
6907
|
+
id: `card_cta_${m}${y ? `_${i.loading ? "loading" : "done"}` : ""}`
|
|
6908
|
+
})
|
|
6909
|
+
}
|
|
6910
|
+
)
|
|
6899
6911
|
}
|
|
6900
|
-
)
|
|
6912
|
+
);
|
|
6901
6913
|
}
|
|
6902
6914
|
return null;
|
|
6903
6915
|
};
|
|
@@ -6920,9 +6932,9 @@ const nc = {
|
|
|
6920
6932
|
data: null,
|
|
6921
6933
|
isLoading: !0
|
|
6922
6934
|
}), { data: m, isLoading: p } = u, g = sa(() => {
|
|
6923
|
-
n(e, l).then((
|
|
6924
|
-
f(() => ({ data:
|
|
6925
|
-
}).catch(() => f((
|
|
6935
|
+
n(e, l).then((N) => {
|
|
6936
|
+
f(() => ({ data: N, isLoading: !1 }));
|
|
6937
|
+
}).catch(() => f((N) => ({ ...N, isLoading: !1 })));
|
|
6926
6938
|
}, [t]);
|
|
6927
6939
|
if (ae(() => {
|
|
6928
6940
|
g();
|
|
@@ -6943,25 +6955,25 @@ const nc = {
|
|
|
6943
6955
|
if (!v || !Kt[v])
|
|
6944
6956
|
return /* @__PURE__ */ a.jsx(Se, { element: "li", className: "card-wrapper" });
|
|
6945
6957
|
const {
|
|
6946
|
-
basePath:
|
|
6947
|
-
className:
|
|
6958
|
+
basePath: _ = "",
|
|
6959
|
+
className: y,
|
|
6948
6960
|
length: x,
|
|
6949
|
-
gtmEvent:
|
|
6961
|
+
gtmEvent: S
|
|
6950
6962
|
} = Kt[v];
|
|
6951
|
-
let w = m.slug ? `${
|
|
6963
|
+
let w = m.slug ? `${_}${m.slug}` : !1;
|
|
6952
6964
|
m.slug && (m.slug.slice(0, 4) === "http" || m.slug.slice(0, 2) === "//" || m.slug.slice(0, 6) === "mailto" || m.slug.slice(0, 3) === "tel") && (w = m.slug);
|
|
6953
|
-
const
|
|
6965
|
+
const b = { ...nc, ...x };
|
|
6954
6966
|
let F = { className: "card" };
|
|
6955
6967
|
return w && (F = {
|
|
6956
6968
|
href: w,
|
|
6957
6969
|
className: "card gtm-trackable",
|
|
6958
6970
|
"data-gtm-event-context": `${s}-CarouselCard`,
|
|
6959
|
-
"data-gtm-event-type": `${
|
|
6971
|
+
"data-gtm-event-type": `${S}-click`,
|
|
6960
6972
|
"data-testid": "link"
|
|
6961
6973
|
}, m.openInNewTab && (F.target = "_blank")), /* @__PURE__ */ a.jsx(
|
|
6962
6974
|
"li",
|
|
6963
6975
|
{
|
|
6964
|
-
className:
|
|
6976
|
+
className: E("card-wrapper text-medium", y, i, {
|
|
6965
6977
|
"has-link": w,
|
|
6966
6978
|
"no-link": !w,
|
|
6967
6979
|
"has-image": m.banner
|
|
@@ -6992,7 +7004,7 @@ const nc = {
|
|
|
6992
7004
|
m.banner ? /* @__PURE__ */ a.jsxs("p", { className: "img", children: [
|
|
6993
7005
|
m.registered && /* @__PURE__ */ a.jsx(ht, { size: "small", variant: "registered", children: c.formatMessage({ id: "card_registered" }) }),
|
|
6994
7006
|
/* @__PURE__ */ a.jsx(Tt, { image: m.banner })
|
|
6995
|
-
] }) :
|
|
7007
|
+
] }) : y === "people" ? /* @__PURE__ */ a.jsx(
|
|
6996
7008
|
Ye,
|
|
6997
7009
|
{
|
|
6998
7010
|
name: m.title || "",
|
|
@@ -7006,7 +7018,7 @@ const nc = {
|
|
|
7006
7018
|
contributors: { data: m.contributors },
|
|
7007
7019
|
styling: {
|
|
7008
7020
|
size: "small",
|
|
7009
|
-
showGap:
|
|
7021
|
+
showGap: y !== "question",
|
|
7010
7022
|
showText: !0
|
|
7011
7023
|
},
|
|
7012
7024
|
multipleText: ["event", "solutionArticle"].includes(v) ? c.formatMessage({ id: `card_contributors_${v}` }) : void 0,
|
|
@@ -7016,14 +7028,14 @@ const nc = {
|
|
|
7016
7028
|
m.partner && /* @__PURE__ */ a.jsx("p", { className: "partners", "data-testid": "partners", children: m.partner.length > 1 ? c.formatMessage(
|
|
7017
7029
|
{ id: "card_partner" },
|
|
7018
7030
|
{ partner: m.partner[0], number: m.partner.length - 1 }
|
|
7019
|
-
) : et(m.partner[0],
|
|
7031
|
+
) : et(m.partner[0], b.partner) }),
|
|
7020
7032
|
/* Text */
|
|
7021
|
-
["title", "text", "secondaryText"].map((
|
|
7022
|
-
const C = m[
|
|
7033
|
+
["title", "text", "secondaryText"].map((N) => {
|
|
7034
|
+
const C = m[N];
|
|
7023
7035
|
if (!C)
|
|
7024
7036
|
return null;
|
|
7025
|
-
const k = Ws(
|
|
7026
|
-
return /* @__PURE__ */ a.jsx("p", { className: k, "data-testid": k, children: et(C,
|
|
7037
|
+
const k = Ws(N);
|
|
7038
|
+
return /* @__PURE__ */ a.jsx("p", { className: k, "data-testid": k, children: et(C, b[N]) }, N);
|
|
7027
7039
|
}),
|
|
7028
7040
|
(m == null ? void 0 : m.members) && /* @__PURE__ */ a.jsxs("span", { className: "member-information", children: [
|
|
7029
7041
|
((R = m == null ? void 0 : m.members) == null ? void 0 : R.isMember) && /* @__PURE__ */ a.jsx(
|
|
@@ -7043,14 +7055,14 @@ const nc = {
|
|
|
7043
7055
|
{ count: m == null ? void 0 : m.members.count }
|
|
7044
7056
|
) })
|
|
7045
7057
|
] }),
|
|
7046
|
-
/* @__PURE__ */ a.jsx(ec, { type:
|
|
7058
|
+
/* @__PURE__ */ a.jsx(ec, { type: y || "", data: m }),
|
|
7047
7059
|
/* @__PURE__ */ a.jsx(tc, { data: m, cta: r, link: w || "", gtmContext: s })
|
|
7048
7060
|
] })
|
|
7049
7061
|
)
|
|
7050
7062
|
}
|
|
7051
7063
|
);
|
|
7052
7064
|
};
|
|
7053
|
-
const rc = ({ cards: t, cardTypes: e, className: n = "", ...r }) => /* @__PURE__ */ a.jsx("ul", { className:
|
|
7065
|
+
const rc = ({ cards: t, cardTypes: e, className: n = "", ...r }) => /* @__PURE__ */ a.jsx("ul", { className: E("card-block", n), children: t.map((s, i) => {
|
|
7054
7066
|
const o = s.slug ? `${s.slug}-${e[i]}` : `${e[i]}-${i}`;
|
|
7055
7067
|
return /* @__PURE__ */ a.jsx(
|
|
7056
7068
|
Ua,
|
|
@@ -7070,7 +7082,7 @@ const rc = ({ cards: t, cardTypes: e, className: n = "", ...r }) => /* @__PURE__
|
|
|
7070
7082
|
return null;
|
|
7071
7083
|
const { text: r, element: s = "h2", variant: i = "default", size: o = "medium", link: c } = e;
|
|
7072
7084
|
return Y.createElement(s, {
|
|
7073
|
-
className:
|
|
7085
|
+
className: E("title", i, o, {
|
|
7074
7086
|
"highlighted-title": i === "highlighted"
|
|
7075
7087
|
}),
|
|
7076
7088
|
children: /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
@@ -7110,19 +7122,19 @@ const ic = ({
|
|
|
7110
7122
|
}), { cardsPerPage: f, isLoading: m } = l, [p, g] = X({
|
|
7111
7123
|
currentPage: 0,
|
|
7112
7124
|
loadedPages: [0]
|
|
7113
|
-
}), { currentPage: v, loadedPages:
|
|
7125
|
+
}), { currentPage: v, loadedPages: _ } = p, y = e.length, x = Math.ceil(y / f), S = pe(null), w = jt(!0, !0, S == null ? void 0 : S.current);
|
|
7114
7126
|
ae(() => {
|
|
7115
|
-
let
|
|
7116
|
-
w && (w >= En.fourCards ?
|
|
7127
|
+
let N = 1;
|
|
7128
|
+
w && (w >= En.fourCards ? N = 4 : w >= En.threeCards ? N = 3 : w >= En.twoCards && (N = 2), N > y && (N = y)), u((C) => ({
|
|
7117
7129
|
...C,
|
|
7118
|
-
cardsPerPage:
|
|
7130
|
+
cardsPerPage: N,
|
|
7119
7131
|
isLoading: !1
|
|
7120
7132
|
}));
|
|
7121
|
-
}, [w,
|
|
7122
|
-
const
|
|
7133
|
+
}, [w, y]);
|
|
7134
|
+
const b = (N = "next") => {
|
|
7123
7135
|
let C = v;
|
|
7124
|
-
if (typeof
|
|
7125
|
-
if (
|
|
7136
|
+
if (typeof N == "string")
|
|
7137
|
+
if (N === "next")
|
|
7126
7138
|
if (v < x - 1)
|
|
7127
7139
|
C = v + 1;
|
|
7128
7140
|
else
|
|
@@ -7132,37 +7144,37 @@ const ic = ({
|
|
|
7132
7144
|
else
|
|
7133
7145
|
return;
|
|
7134
7146
|
else
|
|
7135
|
-
C =
|
|
7147
|
+
C = N;
|
|
7136
7148
|
g((k) => ({
|
|
7137
7149
|
...k,
|
|
7138
7150
|
currentPage: C,
|
|
7139
|
-
loadedPages: [.../* @__PURE__ */ new Set([...
|
|
7151
|
+
loadedPages: [.../* @__PURE__ */ new Set([..._, C])]
|
|
7140
7152
|
}));
|
|
7141
|
-
}, F = (
|
|
7142
|
-
Ft =
|
|
7143
|
-
}, R = (
|
|
7153
|
+
}, F = (N) => {
|
|
7154
|
+
Ft = N.touches[0].clientX;
|
|
7155
|
+
}, R = (N) => {
|
|
7144
7156
|
if (Ft === null)
|
|
7145
7157
|
return;
|
|
7146
|
-
const C =
|
|
7147
|
-
k > 5 ?
|
|
7158
|
+
const C = N.touches[0].clientX, k = Ft - C;
|
|
7159
|
+
k > 5 ? b("next") : k < -5 && b("previous"), Ft = null;
|
|
7148
7160
|
}, Q = {
|
|
7149
7161
|
"--width": `${w || 0}px`,
|
|
7150
|
-
"--total-cards":
|
|
7162
|
+
"--total-cards": y,
|
|
7151
7163
|
"--cards-per-page": f,
|
|
7152
7164
|
"--page": v
|
|
7153
7165
|
};
|
|
7154
7166
|
if (m)
|
|
7155
7167
|
return /* @__PURE__ */ a.jsx(wa, { layout: `carousel${s ? "-with-title" : ""}` });
|
|
7156
|
-
const B = (
|
|
7168
|
+
const B = (N, C) => {
|
|
7157
7169
|
var j;
|
|
7158
7170
|
let k = null;
|
|
7159
|
-
return (j =
|
|
7171
|
+
return (j = N == null ? void 0 : N.sys) != null && j.id ? k = `card-${N.sys.id}` : N != null && N.slug ? k = `card-${N.slug}` : [n[C], N.contentType].includes("customCard") && (k = `card-${window.btoa(`${N.title} ${N.createdAt}`)}-${C}`), k;
|
|
7160
7172
|
};
|
|
7161
7173
|
return /* @__PURE__ */ a.jsxs(
|
|
7162
7174
|
"section",
|
|
7163
7175
|
{
|
|
7164
|
-
ref:
|
|
7165
|
-
className:
|
|
7176
|
+
ref: S,
|
|
7177
|
+
className: E("carousel-wrapper", i),
|
|
7166
7178
|
"data-testid": "carousel",
|
|
7167
7179
|
children: [
|
|
7168
7180
|
/* @__PURE__ */ a.jsx(sc, { id: t, title: s }),
|
|
@@ -7174,13 +7186,13 @@ const ic = ({
|
|
|
7174
7186
|
onTouchMove: R,
|
|
7175
7187
|
style: Q,
|
|
7176
7188
|
"data-testid": "carousel-list",
|
|
7177
|
-
children: e.map((
|
|
7178
|
-
let k = B(
|
|
7179
|
-
return k && ac(C, f, v,
|
|
7189
|
+
children: e.map((N, C) => {
|
|
7190
|
+
let k = B(N, C);
|
|
7191
|
+
return k && ac(C, f, v, _) ? /* @__PURE__ */ a.jsx(
|
|
7180
7192
|
Ua,
|
|
7181
7193
|
{
|
|
7182
7194
|
id: k,
|
|
7183
|
-
card: {
|
|
7195
|
+
card: { ...N, contentType: n[C] },
|
|
7184
7196
|
buildCardData: r,
|
|
7185
7197
|
gtmContext: o,
|
|
7186
7198
|
...c
|
|
@@ -7205,8 +7217,8 @@ const ic = ({
|
|
|
7205
7217
|
variant: "secondary",
|
|
7206
7218
|
size: "large",
|
|
7207
7219
|
icon: { icon: "chevron_left" },
|
|
7208
|
-
onClick: (
|
|
7209
|
-
|
|
7220
|
+
onClick: (N) => {
|
|
7221
|
+
N.preventDefault(), N.stopPropagation(), b("previous");
|
|
7210
7222
|
},
|
|
7211
7223
|
screenreaderText: d.formatMessage({
|
|
7212
7224
|
id: "carousel_pagination_previous"
|
|
@@ -7214,14 +7226,14 @@ const ic = ({
|
|
|
7214
7226
|
disabled: v <= 0
|
|
7215
7227
|
}
|
|
7216
7228
|
) }),
|
|
7217
|
-
[...Array(x)].map((
|
|
7229
|
+
[...Array(x)].map((N, C) => /* @__PURE__ */ a.jsx("li", { "data-testid": "carousel-controls-button", children: /* @__PURE__ */ a.jsx(
|
|
7218
7230
|
"button",
|
|
7219
7231
|
{
|
|
7220
|
-
className:
|
|
7232
|
+
className: E("page-indicator", {
|
|
7221
7233
|
selected: C === v
|
|
7222
7234
|
}),
|
|
7223
7235
|
onClick: (k) => {
|
|
7224
|
-
k.preventDefault(), k.stopPropagation(),
|
|
7236
|
+
k.preventDefault(), k.stopPropagation(), b(C);
|
|
7225
7237
|
},
|
|
7226
7238
|
children: /* @__PURE__ */ a.jsx(be, { showOnFocus: !1, children: d.formatMessage(
|
|
7227
7239
|
{ id: "carousel_pagination_page" },
|
|
@@ -7235,8 +7247,8 @@ const ic = ({
|
|
|
7235
7247
|
variant: "secondary",
|
|
7236
7248
|
size: "large",
|
|
7237
7249
|
icon: { icon: "chevron_right" },
|
|
7238
|
-
onClick: (
|
|
7239
|
-
|
|
7250
|
+
onClick: (N) => {
|
|
7251
|
+
N.preventDefault(), N.stopPropagation(), b("next");
|
|
7240
7252
|
},
|
|
7241
7253
|
screenreaderText: d.formatMessage({ id: "carousel_pagination_next" }),
|
|
7242
7254
|
disabled: v >= x - 1
|
|
@@ -7300,7 +7312,7 @@ const Sn = "joinCommunityButton", Wa = ({
|
|
|
7300
7312
|
onClick: async (p) => {
|
|
7301
7313
|
o && (p.currentTarget.blur(), c ? (u("leaving"), typeof r == "function" && await r()) : (u("joining"), typeof n == "function" && await n()), d(!c));
|
|
7302
7314
|
},
|
|
7303
|
-
className:
|
|
7315
|
+
className: E("join-community-button", l, {
|
|
7304
7316
|
active: l === "joining"
|
|
7305
7317
|
}),
|
|
7306
7318
|
disabled: !o,
|
|
@@ -7319,7 +7331,7 @@ const Cn = "communityDetails_", tu = ({
|
|
|
7319
7331
|
functions: { invite: i, ...o }
|
|
7320
7332
|
}) => {
|
|
7321
7333
|
const c = H(), d = 5, l = r || s.length, u = s.length ? s : Array(d).fill({}), f = `/communities/${n}/members` === window.location.pathname;
|
|
7322
|
-
return /* @__PURE__ */ a.jsxs("div", { className:
|
|
7334
|
+
return /* @__PURE__ */ a.jsxs("div", { className: E("community-details", t), children: [
|
|
7323
7335
|
/* @__PURE__ */ a.jsx(Oe, {}),
|
|
7324
7336
|
/* @__PURE__ */ a.jsxs("div", { className: "member-details", children: [
|
|
7325
7337
|
/* @__PURE__ */ a.jsxs("div", { className: "top", children: [
|
|
@@ -7368,7 +7380,7 @@ const nu = ({ breadcrumbs: t, cutoff: e = 20, className: n = "" }) => {
|
|
|
7368
7380
|
children: r.formatMessage({ id: "breadcrumbs_label" })
|
|
7369
7381
|
}
|
|
7370
7382
|
),
|
|
7371
|
-
/* @__PURE__ */ a.jsx("ul", { className:
|
|
7383
|
+
/* @__PURE__ */ a.jsx("ul", { className: E("breadcrumbs text-small", n), children: t.map(
|
|
7372
7384
|
({ text: s, href: i, current: o = !1 }, c) => /* @__PURE__ */ a.jsxs("li", { children: [
|
|
7373
7385
|
o && /* @__PURE__ */ a.jsx(
|
|
7374
7386
|
be,
|
|
@@ -7400,7 +7412,7 @@ const ru = ({
|
|
|
7400
7412
|
let m = [];
|
|
7401
7413
|
c.includes(u) ? m = c.filter((p) => p !== u) : u === "all" ? m = ["all"] : n ? m = [...c.filter((p) => p !== "all"), u] : m = [u], d((p) => (r && typeof r == "function" && r({ current: m, previous: p }), m)), f && typeof f == "function" && f();
|
|
7402
7414
|
};
|
|
7403
|
-
return /* @__PURE__ */ a.jsx("ul", { className:
|
|
7415
|
+
return /* @__PURE__ */ a.jsx("ul", { className: E("filters", s), children: o.map(({ id: u, text: f, disabled: m = !1, callback: p = () => {
|
|
7404
7416
|
} }) => {
|
|
7405
7417
|
let g = {};
|
|
7406
7418
|
return m && (g = {
|
|
@@ -7409,7 +7421,7 @@ const ru = ({
|
|
|
7409
7421
|
}), /* @__PURE__ */ a.jsx("li", { children: /* @__PURE__ */ a.jsx(
|
|
7410
7422
|
"button",
|
|
7411
7423
|
{
|
|
7412
|
-
className:
|
|
7424
|
+
className: E(u, { selected: c.includes(u) }),
|
|
7413
7425
|
onClick: (v) => {
|
|
7414
7426
|
v.preventDefault(), v.stopPropagation(), l(u, p);
|
|
7415
7427
|
},
|
|
@@ -7446,38 +7458,38 @@ const Ot = "languageSwitcher_", au = ({
|
|
|
7446
7458
|
if (ae(() => {
|
|
7447
7459
|
t !== f && m(t);
|
|
7448
7460
|
}, [t]), !r || !Object.values(r).some(
|
|
7449
|
-
(
|
|
7461
|
+
(_) => _ && _.post_name
|
|
7450
7462
|
))
|
|
7451
7463
|
return null;
|
|
7452
7464
|
const g = Object.keys(r), v = f !== t;
|
|
7453
|
-
return /* @__PURE__ */ a.jsxs("div", { className:
|
|
7465
|
+
return /* @__PURE__ */ a.jsxs("div", { className: E("language-switcher text-small", o, d), children: [
|
|
7454
7466
|
/* @__PURE__ */ a.jsxs("nav", { children: [
|
|
7455
7467
|
o !== "short" && /* @__PURE__ */ a.jsx("p", { children: c || l.formatMessage({ id: `${Ot}label` }) }),
|
|
7456
|
-
/* @__PURE__ */ a.jsx("ul", { children: g.map((
|
|
7457
|
-
var
|
|
7458
|
-
if (!gn[
|
|
7468
|
+
/* @__PURE__ */ a.jsx("ul", { children: g.map((_) => {
|
|
7469
|
+
var S;
|
|
7470
|
+
if (!gn[_])
|
|
7459
7471
|
return null;
|
|
7460
|
-
const
|
|
7461
|
-
let x = { className:
|
|
7462
|
-
if (f ===
|
|
7472
|
+
const y = (S = r[_]) == null ? void 0 : S.post_name;
|
|
7473
|
+
let x = { className: _ };
|
|
7474
|
+
if (f === _)
|
|
7463
7475
|
x["aria-label"] = l.formatMessage(
|
|
7464
7476
|
{ id: `${Ot}selected` },
|
|
7465
|
-
{ language: gn[
|
|
7477
|
+
{ language: gn[_] }
|
|
7466
7478
|
);
|
|
7467
7479
|
else {
|
|
7468
|
-
const w = oc(
|
|
7480
|
+
const w = oc(_, y, i);
|
|
7469
7481
|
x = {
|
|
7470
7482
|
...x,
|
|
7471
7483
|
href: typeof w == "string" ? w : w.url,
|
|
7472
|
-
onClick: (
|
|
7473
|
-
m(
|
|
7474
|
-
|
|
7484
|
+
onClick: (b) => {
|
|
7485
|
+
m(_), u(_), typeof s < "u" && (b.preventDefault(), b.stopPropagation(), s(
|
|
7486
|
+
_,
|
|
7475
7487
|
typeof w == "string" ? w : w.urlForRouter
|
|
7476
7488
|
));
|
|
7477
7489
|
}
|
|
7478
7490
|
};
|
|
7479
7491
|
}
|
|
7480
|
-
return /* @__PURE__ */ a.jsx("li", { children: /* @__PURE__ */ a.jsx(at, { ...x, fallbackElement: "span", children: gn[
|
|
7492
|
+
return /* @__PURE__ */ a.jsx("li", { children: /* @__PURE__ */ a.jsx(at, { ...x, fallbackElement: "span", children: gn[_] }) }, _);
|
|
7481
7493
|
}) }),
|
|
7482
7494
|
o !== "short" && !v && /* @__PURE__ */ a.jsx("p", { children: l.formatMessage({
|
|
7483
7495
|
id: `${Ot}translation_${e ? "original" : n ? "human" : "machine"}`
|
|
@@ -7491,16 +7503,16 @@ const Ot = "languageSwitcher_", au = ({
|
|
|
7491
7503
|
{ id: `${Ot}disclaimer` },
|
|
7492
7504
|
{
|
|
7493
7505
|
email: ft.support,
|
|
7494
|
-
link: (
|
|
7495
|
-
const
|
|
7496
|
-
return /* @__PURE__ */ a.jsx("a", { href:
|
|
7506
|
+
link: (_) => {
|
|
7507
|
+
const y = `mailto:${_}`;
|
|
7508
|
+
return /* @__PURE__ */ a.jsx("a", { href: y, children: _ });
|
|
7497
7509
|
}
|
|
7498
7510
|
}
|
|
7499
7511
|
)
|
|
7500
7512
|
})
|
|
7501
7513
|
] });
|
|
7502
7514
|
};
|
|
7503
|
-
const
|
|
7515
|
+
const Nn = ks({ locale: "en", messages: rt }), sn = ({
|
|
7504
7516
|
hasNextPage: t = !0,
|
|
7505
7517
|
loadNextPage: e = () => {
|
|
7506
7518
|
},
|
|
@@ -7510,9 +7522,9 @@ const $n = ks({ locale: "en", messages: rt }), sn = ({
|
|
|
7510
7522
|
styling: i = { muted: !1, fullWidth: !1 },
|
|
7511
7523
|
icon: o = !1,
|
|
7512
7524
|
messages: c = {
|
|
7513
|
-
button:
|
|
7514
|
-
endOfFeed:
|
|
7515
|
-
error:
|
|
7525
|
+
button: Nn.formatMessage({ id: "loadMore_button" }),
|
|
7526
|
+
endOfFeed: Nn.formatMessage({ id: "loadMore_endOfFeed" }),
|
|
7527
|
+
error: Nn.formatMessage({ id: "loadMore_error" })
|
|
7516
7528
|
},
|
|
7517
7529
|
className: d = "",
|
|
7518
7530
|
gtmContext: l = "LoadMore"
|
|
@@ -7525,7 +7537,7 @@ const $n = ks({ locale: "en", messages: rt }), sn = ({
|
|
|
7525
7537
|
g instanceof Error ? f(g.message) : f("Unknown error");
|
|
7526
7538
|
}
|
|
7527
7539
|
};
|
|
7528
|
-
return !u && !t && !c.endOfFeed ? null : /* @__PURE__ */ a.jsx("footer", { className:
|
|
7540
|
+
return !u && !t && !c.endOfFeed ? null : /* @__PURE__ */ a.jsx("footer", { className: E("load-more", d), children: !u && t ? /* @__PURE__ */ a.jsx(
|
|
7529
7541
|
se,
|
|
7530
7542
|
{
|
|
7531
7543
|
variant: r,
|
|
@@ -7551,7 +7563,7 @@ const za = ({
|
|
|
7551
7563
|
"a",
|
|
7552
7564
|
{
|
|
7553
7565
|
href: "/home/",
|
|
7554
|
-
className:
|
|
7566
|
+
className: E("logo", t, e, n),
|
|
7555
7567
|
...r,
|
|
7556
7568
|
children: /* @__PURE__ */ a.jsx(be, { children: /* @__PURE__ */ a.jsx(ye, { id: "apolitical" }) })
|
|
7557
7569
|
}
|
|
@@ -7572,7 +7584,7 @@ const cc = ({
|
|
|
7572
7584
|
document.removeEventListener("click", d, !0);
|
|
7573
7585
|
})), Y.createElement(t, {
|
|
7574
7586
|
ref: i,
|
|
7575
|
-
className:
|
|
7587
|
+
className: E("more-menu text-medium", r),
|
|
7576
7588
|
children: /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
7577
7589
|
/* @__PURE__ */ a.jsx(
|
|
7578
7590
|
se,
|
|
@@ -7590,8 +7602,8 @@ const cc = ({
|
|
|
7590
7602
|
/* @__PURE__ */ a.jsx("ul", { id: e, hidden: !o, children: n.map(({ href: l, onClick: u, text: f, icon: m, ...p }, g) => {
|
|
7591
7603
|
const v = {
|
|
7592
7604
|
...p,
|
|
7593
|
-
onClick: (
|
|
7594
|
-
c(!1), typeof u == "function" && u(
|
|
7605
|
+
onClick: (_) => {
|
|
7606
|
+
c(!1), typeof u == "function" && u(_);
|
|
7595
7607
|
},
|
|
7596
7608
|
onFocus: () => {
|
|
7597
7609
|
At && (clearTimeout(At), At = !1);
|
|
@@ -7643,7 +7655,7 @@ const uc = [
|
|
|
7643
7655
|
uc.map(({ key: s, href: i }) => /* @__PURE__ */ a.jsx(
|
|
7644
7656
|
"li",
|
|
7645
7657
|
{
|
|
7646
|
-
className:
|
|
7658
|
+
className: E(s, { active: lc(i, t) }),
|
|
7647
7659
|
children: /* @__PURE__ */ a.jsx(
|
|
7648
7660
|
"a",
|
|
7649
7661
|
{
|
|
@@ -7730,7 +7742,7 @@ const mc = "shareLinks_", su = ({
|
|
|
7730
7742
|
className: o = ""
|
|
7731
7743
|
}) => {
|
|
7732
7744
|
const c = H(), d = fc({ title: t, link: e, referrer: n });
|
|
7733
|
-
return /* @__PURE__ */ a.jsxs("aside", { className:
|
|
7745
|
+
return /* @__PURE__ */ a.jsxs("aside", { className: E("share-links", s, i, o), children: [
|
|
7734
7746
|
/* @__PURE__ */ a.jsx("p", { className: "text-small", children: c.formatMessage({ id: "shareLinks_label" }) }),
|
|
7735
7747
|
/* @__PURE__ */ a.jsx("ul", { children: d.map(({ key: l, icon: u, url: f, shouldRender: m = !0, onClick: p }) => {
|
|
7736
7748
|
if (typeof m == "function" && !m())
|
|
@@ -7784,18 +7796,18 @@ const iu = ({ tabs: t, className: e = "", preventLocationChange: n }) => {
|
|
|
7784
7796
|
const c = [], d = [];
|
|
7785
7797
|
return t.forEach(({ id: u, text: f, content: m, href: p, hasCarousel: g }, v) => {
|
|
7786
7798
|
u = r(u, f, v);
|
|
7787
|
-
const
|
|
7788
|
-
p || (
|
|
7799
|
+
const _ = i === u, y = {};
|
|
7800
|
+
p || (y["aria-controls"] = u, y.onClick = (x) => {
|
|
7789
7801
|
x.preventDefault(), x.stopPropagation(), o(u), !n && (window.location.hash = `#${u}`);
|
|
7790
7802
|
}, d.push(
|
|
7791
7803
|
/* @__PURE__ */ a.jsx(
|
|
7792
7804
|
"section",
|
|
7793
7805
|
{
|
|
7794
7806
|
id: u,
|
|
7795
|
-
hidden: !
|
|
7807
|
+
hidden: !_,
|
|
7796
7808
|
role: "tabpanel",
|
|
7797
7809
|
"aria-labelledby": `tab-${u}`,
|
|
7798
|
-
"aria-live":
|
|
7810
|
+
"aria-live": _ ? "assertive" : "off",
|
|
7799
7811
|
children: typeof m == "string" ? /* @__PURE__ */ a.jsx("p", { children: m }) : m
|
|
7800
7812
|
},
|
|
7801
7813
|
`section-${u}`
|
|
@@ -7806,15 +7818,15 @@ const iu = ({ tabs: t, className: e = "", preventLocationChange: n }) => {
|
|
|
7806
7818
|
{
|
|
7807
7819
|
href: p || `#${u}`,
|
|
7808
7820
|
id: `tab-${u}`,
|
|
7809
|
-
className:
|
|
7821
|
+
className: E({ selected: _ }),
|
|
7810
7822
|
role: "tab",
|
|
7811
|
-
"aria-selected":
|
|
7812
|
-
...
|
|
7823
|
+
"aria-selected": _,
|
|
7824
|
+
...y,
|
|
7813
7825
|
children: f
|
|
7814
7826
|
}
|
|
7815
7827
|
) }, `tab-${u}`)
|
|
7816
7828
|
);
|
|
7817
|
-
}), /* @__PURE__ */ a.jsxs("div", { className:
|
|
7829
|
+
}), /* @__PURE__ */ a.jsxs("div", { className: E("tabs-wrapper", e), children: [
|
|
7818
7830
|
/* @__PURE__ */ a.jsx("ul", { className: "tabs", role: "tablist", children: c }),
|
|
7819
7831
|
/* @__PURE__ */ a.jsx("div", { className: "tab-content", children: d })
|
|
7820
7832
|
] });
|
|
@@ -7835,26 +7847,26 @@ const pc = {
|
|
|
7835
7847
|
return Y.Children.count(s) === 1 && (o = Y.Children.toArray(s)[0], o.props && (o = o.props.children)), /* @__PURE__ */ a.jsx(
|
|
7836
7848
|
"section",
|
|
7837
7849
|
{
|
|
7838
|
-
className:
|
|
7850
|
+
className: E("columns", `layout-${t}`, r, {
|
|
7839
7851
|
"has-containers": n
|
|
7840
7852
|
}),
|
|
7841
7853
|
children: Y.Children.map(o, (c, d) => e !== !1 && d === e && i && i < pc[t] ? null : c)
|
|
7842
7854
|
}
|
|
7843
7855
|
);
|
|
7844
7856
|
};
|
|
7845
|
-
let
|
|
7857
|
+
let $n;
|
|
7846
7858
|
const Pn = "contactFooter_", ou = ({ onSuccess: t = async () => {
|
|
7847
7859
|
}, onFailure: e = () => {
|
|
7848
7860
|
} }) => {
|
|
7849
7861
|
const n = pe(null), [r, s] = Y.useState(0), [i, o] = Y.useState(!1), c = () => {
|
|
7850
7862
|
n.current && s(n.current.clientHeight);
|
|
7851
7863
|
}, d = () => {
|
|
7852
|
-
i || (o(!0), clearTimeout(
|
|
7864
|
+
i || (o(!0), clearTimeout($n), $n = setTimeout(() => {
|
|
7853
7865
|
c(), o(!1);
|
|
7854
7866
|
}, 500));
|
|
7855
7867
|
};
|
|
7856
7868
|
return ae(() => (c(), window.addEventListener("resize", d), () => {
|
|
7857
|
-
clearTimeout(
|
|
7869
|
+
clearTimeout($n), window.removeEventListener("resize", d);
|
|
7858
7870
|
}), []), /* @__PURE__ */ a.jsx(Ve, { id: "contactForm", className: "contact-footer", children: /* @__PURE__ */ a.jsxs("div", { className: "inner-wrapper", children: [
|
|
7859
7871
|
/* @__PURE__ */ a.jsx("h2", { children: /* @__PURE__ */ a.jsx(ye, { id: `${Pn}title` }) }),
|
|
7860
7872
|
/* @__PURE__ */ a.jsxs(
|
|
@@ -7963,7 +7975,11 @@ const Mn = "cookieBanner_", Rn = [
|
|
|
7963
7975
|
}
|
|
7964
7976
|
},
|
|
7965
7977
|
company: {
|
|
7966
|
-
order: ["story", "team", "careers", "partner", "contact"],
|
|
7978
|
+
order: ["news", "story", "team", "careers", "partner", "contact"],
|
|
7979
|
+
news: {
|
|
7980
|
+
href: "/learning-hub/updates/",
|
|
7981
|
+
gtmType: "news-click"
|
|
7982
|
+
},
|
|
7967
7983
|
story: {
|
|
7968
7984
|
href: "/pages/our-story",
|
|
7969
7985
|
gtmType: "our-story-click"
|
|
@@ -8318,8 +8334,8 @@ const Xe = "footer_", Gt = "SiteFooter", Kr = ({ group: t }) => {
|
|
|
8318
8334
|
if (c.href) {
|
|
8319
8335
|
let x = c.gtmType || `${t}-click`;
|
|
8320
8336
|
if (x.includes(".")) {
|
|
8321
|
-
const
|
|
8322
|
-
x = `${w === "topics" ? `${w}-` : ""}${
|
|
8337
|
+
const S = x.split("."), w = S[S.length - 2];
|
|
8338
|
+
x = `${w === "topics" ? `${w}-` : ""}${S[S.length - 1]}`;
|
|
8323
8339
|
}
|
|
8324
8340
|
m = {
|
|
8325
8341
|
href: c.href,
|
|
@@ -8337,17 +8353,17 @@ const Xe = "footer_", Gt = "SiteFooter", Kr = ({ group: t }) => {
|
|
|
8337
8353
|
});
|
|
8338
8354
|
}
|
|
8339
8355
|
const p = c.order && c.order[0] && c[c.order[0]], g = p && c[c.order[0]].order, v = m && window.location.pathname === c.href;
|
|
8340
|
-
let
|
|
8356
|
+
let _ = {}, y = {};
|
|
8341
8357
|
if (p) {
|
|
8342
|
-
const x = c.menuId || t,
|
|
8358
|
+
const x = c.menuId || t, S = {
|
|
8343
8359
|
onClick: (w) => fe.events.onClick(w, { id: x, callback: s, isOpen: r[x] }),
|
|
8344
8360
|
onFocus: () => fe.events.onFocus({ id: x }),
|
|
8345
8361
|
onBlur: () => fe.events.onBlur({ id: x, callback: s }),
|
|
8346
8362
|
onMouseLeave: () => fe.events.onBlur({ id: x, callback: s }),
|
|
8347
8363
|
onMouseEnter: () => fe.events.onMouseEnter({ id: x, callback: s })
|
|
8348
8364
|
};
|
|
8349
|
-
n && (g && (
|
|
8350
|
-
...
|
|
8365
|
+
n && (g && (_ = {
|
|
8366
|
+
...S,
|
|
8351
8367
|
onKeyPress: (w) => {
|
|
8352
8368
|
w.key === "Enter" && fe.events.onClick(w, { id: x, callback: s, isOpen: r[x] });
|
|
8353
8369
|
},
|
|
@@ -8356,32 +8372,32 @@ const Xe = "footer_", Gt = "SiteFooter", Kr = ({ group: t }) => {
|
|
|
8356
8372
|
"aria-haspopup": !0,
|
|
8357
8373
|
"aria-expanded": r[x],
|
|
8358
8374
|
"aria-controls": x
|
|
8359
|
-
}),
|
|
8360
|
-
...
|
|
8361
|
-
...
|
|
8375
|
+
}), y = { hidden: x in r ? !r[x] : !0 }), g || (y = {
|
|
8376
|
+
...y,
|
|
8377
|
+
...S
|
|
8362
8378
|
});
|
|
8363
8379
|
}
|
|
8364
8380
|
return /* @__PURE__ */ a.jsxs(
|
|
8365
8381
|
"li",
|
|
8366
8382
|
{
|
|
8367
|
-
className:
|
|
8383
|
+
className: E({
|
|
8368
8384
|
[c.className]: c.className,
|
|
8369
8385
|
"has-submenu": p,
|
|
8370
8386
|
parent: g,
|
|
8371
8387
|
active: v
|
|
8372
8388
|
}),
|
|
8373
8389
|
role: "none",
|
|
8374
|
-
...
|
|
8390
|
+
..._,
|
|
8375
8391
|
children: [
|
|
8376
8392
|
m ? Y.createElement(
|
|
8377
8393
|
u ? se : "a",
|
|
8378
8394
|
m,
|
|
8379
8395
|
o.formatMessage({ id: f })
|
|
8380
8396
|
) : o.formatMessage({ id: f }),
|
|
8381
|
-
c.order && /* @__PURE__ */ a.jsx("ul", { ...
|
|
8397
|
+
c.order && /* @__PURE__ */ a.jsx("ul", { ...y, children: c.order.map((x) => {
|
|
8382
8398
|
if (!c[x])
|
|
8383
8399
|
return null;
|
|
8384
|
-
const
|
|
8400
|
+
const S = {
|
|
8385
8401
|
isLoggedIn: e,
|
|
8386
8402
|
isDesktopVersion: n,
|
|
8387
8403
|
menus: r,
|
|
@@ -8391,7 +8407,7 @@ const Xe = "footer_", Gt = "SiteFooter", Kr = ({ group: t }) => {
|
|
|
8391
8407
|
return c[x].order ? /* @__PURE__ */ a.jsxs(
|
|
8392
8408
|
"li",
|
|
8393
8409
|
{
|
|
8394
|
-
className:
|
|
8410
|
+
className: E({
|
|
8395
8411
|
[c[x].className]: c[x].className
|
|
8396
8412
|
}),
|
|
8397
8413
|
children: [
|
|
@@ -8400,7 +8416,7 @@ const Xe = "footer_", Gt = "SiteFooter", Kr = ({ group: t }) => {
|
|
|
8400
8416
|
Jt,
|
|
8401
8417
|
{
|
|
8402
8418
|
id: `${t}.${x}.${w}`,
|
|
8403
|
-
...
|
|
8419
|
+
...S
|
|
8404
8420
|
},
|
|
8405
8421
|
w
|
|
8406
8422
|
)) })
|
|
@@ -8411,7 +8427,7 @@ const Xe = "footer_", Gt = "SiteFooter", Kr = ({ group: t }) => {
|
|
|
8411
8427
|
Jt,
|
|
8412
8428
|
{
|
|
8413
8429
|
id: `${t}.${x}`,
|
|
8414
|
-
...
|
|
8430
|
+
...S
|
|
8415
8431
|
},
|
|
8416
8432
|
x
|
|
8417
8433
|
);
|
|
@@ -8468,7 +8484,7 @@ const vc = { height: 67, height_desktop: 83 }, Ha = ({ showNavigation: t = !0 })
|
|
|
8468
8484
|
"nav",
|
|
8469
8485
|
{
|
|
8470
8486
|
id: "header",
|
|
8471
|
-
className:
|
|
8487
|
+
className: E({
|
|
8472
8488
|
"logged-in": s,
|
|
8473
8489
|
"logged-out": !s,
|
|
8474
8490
|
visible: d
|
|
@@ -8590,7 +8606,7 @@ const vc = { height: 67, height_desktop: 83 }, Ha = ({ showNavigation: t = !0 })
|
|
|
8590
8606
|
/* @__PURE__ */ a.jsx(
|
|
8591
8607
|
"div",
|
|
8592
8608
|
{
|
|
8593
|
-
className:
|
|
8609
|
+
className: E("overlay", {
|
|
8594
8610
|
open: l.navigation || l.account || !i.search && l.search
|
|
8595
8611
|
})
|
|
8596
8612
|
}
|
|
@@ -8628,35 +8644,35 @@ const bc = () => {
|
|
|
8628
8644
|
ae(() => {
|
|
8629
8645
|
window.scrollTo(0, 0);
|
|
8630
8646
|
}, [g]);
|
|
8631
|
-
const v = Bt(t, { locale: c }),
|
|
8647
|
+
const v = Bt(t, { locale: c }), _ = Bt(e, {
|
|
8632
8648
|
locale: c
|
|
8633
|
-
}),
|
|
8649
|
+
}), y = Bt(n, {
|
|
8634
8650
|
locale: c
|
|
8635
8651
|
}), x = {};
|
|
8636
8652
|
return u !== "default" && (x[u] = !0), f !== "default" && (x[f] = !0), m !== "default" && (x[m] = !0), /* @__PURE__ */ a.jsx(Ps, { onError: r, fallback: /* @__PURE__ */ a.jsx(bc, {}), children: /* @__PURE__ */ a.jsx(xs, { fallback: null, children: /* @__PURE__ */ a.jsxs(
|
|
8637
8653
|
"div",
|
|
8638
8654
|
{
|
|
8639
8655
|
id: "wrapper",
|
|
8640
|
-
className:
|
|
8656
|
+
className: E(o, x, { "has-footer": l }),
|
|
8641
8657
|
children: [
|
|
8642
8658
|
/* @__PURE__ */ a.jsx(Ha, { showNavigation: d }),
|
|
8643
8659
|
/* @__PURE__ */ a.jsxs("section", { id: "content-wrapper", children: [
|
|
8644
|
-
|
|
8660
|
+
_ && /* @__PURE__ */ a.jsx(
|
|
8645
8661
|
"div",
|
|
8646
8662
|
{
|
|
8647
|
-
className:
|
|
8663
|
+
className: E("additional-content prepended", {
|
|
8648
8664
|
"large-modal": p === "large"
|
|
8649
8665
|
}),
|
|
8650
|
-
children:
|
|
8666
|
+
children: _
|
|
8651
8667
|
}
|
|
8652
8668
|
),
|
|
8653
8669
|
Y.createElement(u === "bold" ? qa : "div", {
|
|
8654
8670
|
id: "content",
|
|
8655
8671
|
children: v,
|
|
8656
|
-
className:
|
|
8672
|
+
className: E({ "large-modal": p === "large" })
|
|
8657
8673
|
})
|
|
8658
8674
|
] }),
|
|
8659
|
-
|
|
8675
|
+
y && /* @__PURE__ */ a.jsx("div", { className: "additional-content appended", children: y }),
|
|
8660
8676
|
l && /* @__PURE__ */ a.jsx(Za, {}),
|
|
8661
8677
|
/* @__PURE__ */ a.jsx(gc, {})
|
|
8662
8678
|
]
|
|
@@ -8714,7 +8730,7 @@ const lu = ({
|
|
|
8714
8730
|
}), d.length < 1 ? null : /* @__PURE__ */ a.jsx(
|
|
8715
8731
|
"ul",
|
|
8716
8732
|
{
|
|
8717
|
-
className:
|
|
8733
|
+
className: E("tags text-small", e, s, {
|
|
8718
8734
|
"one-line": n
|
|
8719
8735
|
}),
|
|
8720
8736
|
children: d.map((l) => {
|
|
@@ -8743,7 +8759,7 @@ const uu = ({
|
|
|
8743
8759
|
className: o = ""
|
|
8744
8760
|
}) => {
|
|
8745
8761
|
const c = H();
|
|
8746
|
-
return t.length === 0 ? null : /* @__PURE__ */ a.jsxs("div", { className:
|
|
8762
|
+
return t.length === 0 ? null : /* @__PURE__ */ a.jsxs("div", { className: E("members-list", o), children: [
|
|
8747
8763
|
/* @__PURE__ */ a.jsxs("h1", { children: [
|
|
8748
8764
|
c.formatMessage({ id: "membersList" }),
|
|
8749
8765
|
/* @__PURE__ */ a.jsx("span", { className: "count", children: e })
|
|
@@ -8779,7 +8795,7 @@ const du = ({
|
|
|
8779
8795
|
l > 99 ? l = 100 : l < 1 && (l = 0);
|
|
8780
8796
|
const { highlightPercentage: u = !1 } = o;
|
|
8781
8797
|
return Y.createElement(t, {
|
|
8782
|
-
className:
|
|
8798
|
+
className: E("course-progression", c, {
|
|
8783
8799
|
"highlight-percentage": u,
|
|
8784
8800
|
"has-circle-graph": i === "circle"
|
|
8785
8801
|
}),
|
|
@@ -8818,7 +8834,7 @@ const xc = ({
|
|
|
8818
8834
|
title: r,
|
|
8819
8835
|
className: s = ""
|
|
8820
8836
|
}) => Y.createElement(t, {
|
|
8821
|
-
className:
|
|
8837
|
+
className: E("lesson-name", s),
|
|
8822
8838
|
"data-number": `${e}.${n}`,
|
|
8823
8839
|
children: r
|
|
8824
8840
|
});
|
|
@@ -8831,8 +8847,8 @@ const wc = ({
|
|
|
8831
8847
|
children: i
|
|
8832
8848
|
}) => {
|
|
8833
8849
|
const o = H(), c = Qn(`lessonType_${s}`) ? o.formatMessage({ id: `lessonType_${s}` }) : Zs(s || "");
|
|
8834
|
-
return /* @__PURE__ */ a.jsxs("small", { className:
|
|
8835
|
-
/* @__PURE__ */ a.jsx("span", { className:
|
|
8850
|
+
return /* @__PURE__ */ a.jsxs("small", { className: E("content-type", { [t]: t !== "default" }), children: [
|
|
8851
|
+
/* @__PURE__ */ a.jsx("span", { className: E("type", n), children: c }),
|
|
8836
8852
|
" ",
|
|
8837
8853
|
e > 0 && !r && /* @__PURE__ */ a.jsx(Xn, { time: e }),
|
|
8838
8854
|
" ",
|
|
@@ -8883,32 +8899,32 @@ const fu = ({
|
|
|
8883
8899
|
({
|
|
8884
8900
|
completed: g,
|
|
8885
8901
|
completionTime: v,
|
|
8886
|
-
contentType:
|
|
8887
|
-
icon:
|
|
8902
|
+
contentType: _,
|
|
8903
|
+
icon: y,
|
|
8888
8904
|
image: x,
|
|
8889
|
-
isIntroduction:
|
|
8905
|
+
isIntroduction: S,
|
|
8890
8906
|
optional: w,
|
|
8891
|
-
slug:
|
|
8907
|
+
slug: b,
|
|
8892
8908
|
subsectionId: F,
|
|
8893
8909
|
title: R,
|
|
8894
8910
|
type: Q
|
|
8895
8911
|
}) => {
|
|
8896
|
-
const B = s && e ||
|
|
8897
|
-
return x && (
|
|
8912
|
+
const B = s && e || S, N = {};
|
|
8913
|
+
return x && (N.style = { "--image": `url(${x})` }), /* @__PURE__ */ a.jsx(
|
|
8898
8914
|
"li",
|
|
8899
8915
|
{
|
|
8900
|
-
className:
|
|
8901
|
-
article:
|
|
8902
|
-
discussion:
|
|
8903
|
-
quiz:
|
|
8904
|
-
completed: g &&
|
|
8916
|
+
className: E({
|
|
8917
|
+
article: _ === St.ARTICLE,
|
|
8918
|
+
discussion: _ === St.DISCUSSION,
|
|
8919
|
+
quiz: _ === St.QUIZ,
|
|
8920
|
+
completed: g && _ === St.ARTICLE,
|
|
8905
8921
|
locked: !B
|
|
8906
8922
|
}),
|
|
8907
|
-
|
|
8923
|
+
...N,
|
|
8908
8924
|
children: /* @__PURE__ */ a.jsx(
|
|
8909
8925
|
at,
|
|
8910
8926
|
{
|
|
8911
|
-
href: B ? `/microcourses/en/${c}/${
|
|
8927
|
+
href: B ? `/microcourses/en/${c}/${b}` : void 0,
|
|
8912
8928
|
fallbackElement: "span",
|
|
8913
8929
|
className: "inner",
|
|
8914
8930
|
gtmContext: `MicrocourseOutline${zs(R)}`,
|
|
@@ -8928,17 +8944,17 @@ const fu = ({
|
|
|
8928
8944
|
wc,
|
|
8929
8945
|
{
|
|
8930
8946
|
completionTime: v,
|
|
8931
|
-
icon:
|
|
8947
|
+
icon: y,
|
|
8932
8948
|
optional: w,
|
|
8933
8949
|
type: Q,
|
|
8934
|
-
children: u && u[
|
|
8950
|
+
children: u && u[b] && /* @__PURE__ */ a.jsx("span", { className: "quiz-score", children: `${u[b]}%` })
|
|
8935
8951
|
}
|
|
8936
8952
|
)
|
|
8937
8953
|
] })
|
|
8938
8954
|
}
|
|
8939
8955
|
)
|
|
8940
8956
|
},
|
|
8941
|
-
|
|
8957
|
+
b
|
|
8942
8958
|
);
|
|
8943
8959
|
}
|
|
8944
8960
|
) })
|
|
@@ -8962,7 +8978,7 @@ const mu = ({
|
|
|
8962
8978
|
hover: "check-inside-circle_no-overlap_inverted"
|
|
8963
8979
|
},
|
|
8964
8980
|
onClick: e,
|
|
8965
|
-
className:
|
|
8981
|
+
className: E("mark-complete-button center gtm-trackable", {
|
|
8966
8982
|
completed: t
|
|
8967
8983
|
}),
|
|
8968
8984
|
"data-gtm-event-type": "mark-as-complete",
|
|
@@ -9005,10 +9021,10 @@ const we = "discussion_form_", ar = ({
|
|
|
9005
9021
|
},
|
|
9006
9022
|
gtmContext: l = "DiscussionForm"
|
|
9007
9023
|
}) => {
|
|
9008
|
-
var
|
|
9024
|
+
var N, C, k;
|
|
9009
9025
|
const u = H(), f = Ee(De), [m, p] = X(
|
|
9010
9026
|
n.isEditing && n.isEditing.text || ""
|
|
9011
|
-
), [g, v] = X(c.error || !1), [
|
|
9027
|
+
), [g, v] = X(c.error || !1), [_, y] = X(!1), x = pe(null);
|
|
9012
9028
|
if (r || (r = x), n.isLoading)
|
|
9013
9029
|
return /* @__PURE__ */ a.jsx(
|
|
9014
9030
|
Se,
|
|
@@ -9017,16 +9033,16 @@ const we = "discussion_form_", ar = ({
|
|
|
9017
9033
|
"data-testid": "loading-placeholder"
|
|
9018
9034
|
}
|
|
9019
9035
|
);
|
|
9020
|
-
const
|
|
9021
|
-
const
|
|
9022
|
-
p(
|
|
9036
|
+
const S = (j) => {
|
|
9037
|
+
const $ = j.target.value;
|
|
9038
|
+
p($);
|
|
9023
9039
|
let A;
|
|
9024
|
-
!f || !f.id ? A =
|
|
9040
|
+
!f || !f.id ? A = Ne(
|
|
9025
9041
|
u.formatMessage,
|
|
9026
9042
|
`${we}error_loggedOut`,
|
|
9027
9043
|
t.type,
|
|
9028
9044
|
"action"
|
|
9029
|
-
) : e ?
|
|
9045
|
+
) : e ? $.length >= i && (A = `${we}error_tooLong`) : A = Ne(
|
|
9030
9046
|
u.formatMessage,
|
|
9031
9047
|
`${we}error_noPermission`,
|
|
9032
9048
|
t.type,
|
|
@@ -9035,15 +9051,15 @@ const we = "discussion_form_", ar = ({
|
|
|
9035
9051
|
};
|
|
9036
9052
|
let w = `${t.type}-form`;
|
|
9037
9053
|
if (t.type === "response" || t.type === "reply") {
|
|
9038
|
-
const j = ((
|
|
9054
|
+
const j = ((N = t.slugs) == null ? void 0 : N.reply) || ((C = t.slugs) == null ? void 0 : C.answer) || ((k = t.slugs) == null ? void 0 : k.question) || "";
|
|
9039
9055
|
j && (w = `${w}-${j.slice(-15)}`);
|
|
9040
9056
|
}
|
|
9041
|
-
const
|
|
9057
|
+
const b = async (j) => {
|
|
9042
9058
|
var A;
|
|
9043
9059
|
if (j.preventDefault(), j.stopPropagation(), !f || !f.id || !e || R)
|
|
9044
9060
|
return;
|
|
9045
|
-
Dt && clearTimeout(Dt),
|
|
9046
|
-
const
|
|
9061
|
+
Dt && clearTimeout(Dt), y("submitting");
|
|
9062
|
+
const $ = window.location.pathname;
|
|
9047
9063
|
try {
|
|
9048
9064
|
let W;
|
|
9049
9065
|
switch (t.type) {
|
|
@@ -9060,32 +9076,32 @@ const we = "discussion_form_", ar = ({
|
|
|
9060
9076
|
case "response":
|
|
9061
9077
|
W = await d.create(
|
|
9062
9078
|
{ questionSlug: t.slugs.question },
|
|
9063
|
-
{ body: m, authorId: f && f.id, contentPath:
|
|
9079
|
+
{ body: m, authorId: f && f.id, contentPath: $ }
|
|
9064
9080
|
);
|
|
9065
9081
|
break;
|
|
9066
9082
|
case "reply":
|
|
9067
9083
|
W = await d.create(
|
|
9068
9084
|
{ questionSlug: t.slugs.question, answerSlug: t.slugs.answer },
|
|
9069
|
-
{ body: m, authorId: f && f.id, contentPath:
|
|
9085
|
+
{ body: m, authorId: f && f.id, contentPath: $ }
|
|
9070
9086
|
);
|
|
9071
9087
|
break;
|
|
9072
9088
|
default:
|
|
9073
9089
|
break;
|
|
9074
9090
|
}
|
|
9075
9091
|
await Ks(1e3), d.callback && await d.callback(W), Dt = setTimeout(() => {
|
|
9076
|
-
p(""),
|
|
9092
|
+
p(""), y("submitted");
|
|
9077
9093
|
const Z = new Event("discussionFormSubmitted");
|
|
9078
9094
|
document.dispatchEvent(Z), F();
|
|
9079
9095
|
}, 500);
|
|
9080
9096
|
} catch (W) {
|
|
9081
9097
|
const Z = W;
|
|
9082
9098
|
let z = `${we}error`;
|
|
9083
|
-
Z != null && Z.message.includes("entry already exists") && (z =
|
|
9099
|
+
Z != null && Z.message.includes("entry already exists") && (z = Ne(
|
|
9084
9100
|
u.formatMessage,
|
|
9085
9101
|
`${we}error_alreadyExists`,
|
|
9086
9102
|
t.type,
|
|
9087
9103
|
"action"
|
|
9088
|
-
)), Z != null && Z.message.includes("429") ? z =
|
|
9104
|
+
)), Z != null && Z.message.includes("429") ? z = Ne(
|
|
9089
9105
|
u.formatMessage,
|
|
9090
9106
|
`${we}error_tooMany`,
|
|
9091
9107
|
t.type,
|
|
@@ -9094,9 +9110,9 @@ const we = "discussion_form_", ar = ({
|
|
|
9094
9110
|
}
|
|
9095
9111
|
}, F = () => {
|
|
9096
9112
|
Dt = setTimeout(() => {
|
|
9097
|
-
v(!1),
|
|
9113
|
+
v(!1), y(!1);
|
|
9098
9114
|
}, 5e3);
|
|
9099
|
-
}, R = !m || !ni(m), Q =
|
|
9115
|
+
}, R = !m || !ni(m), Q = _ === "submitting", B = [];
|
|
9100
9116
|
return (n.isEditing && !Q || c.cancel) && B.push({
|
|
9101
9117
|
variant: "secondary",
|
|
9102
9118
|
size: { mobile: "small", 600: "medium" },
|
|
@@ -9111,12 +9127,12 @@ const we = "discussion_form_", ar = ({
|
|
|
9111
9127
|
size: { mobile: "small", 600: "medium" },
|
|
9112
9128
|
onClick: (j) => {
|
|
9113
9129
|
if (n.isEditing) {
|
|
9114
|
-
|
|
9130
|
+
y("submitting"), d.handleSaveEdit && d.handleSaveEdit(
|
|
9115
9131
|
x.current && "value" in x.current ? x.current.value : ""
|
|
9116
9132
|
);
|
|
9117
9133
|
return;
|
|
9118
9134
|
}
|
|
9119
|
-
|
|
9135
|
+
b(j);
|
|
9120
9136
|
},
|
|
9121
9137
|
className: "gtm-trackable",
|
|
9122
9138
|
"data-gtm-event-context": l,
|
|
@@ -9130,12 +9146,12 @@ const we = "discussion_form_", ar = ({
|
|
|
9130
9146
|
"form",
|
|
9131
9147
|
{
|
|
9132
9148
|
id: w,
|
|
9133
|
-
className:
|
|
9149
|
+
className: E("discussion-card discussion-form", {
|
|
9134
9150
|
"no-styling": n.isInWrapper && n.isEditing
|
|
9135
9151
|
}),
|
|
9136
9152
|
"data-testid": `discussion-${t.type}-form`,
|
|
9137
9153
|
children: [
|
|
9138
|
-
(n == null ? void 0 : n.showTitle) && !n.isEditing && ["question"].includes(t.type) && /* @__PURE__ */ a.jsx("h2", { children:
|
|
9154
|
+
(n == null ? void 0 : n.showTitle) && !n.isEditing && ["question"].includes(t.type) && /* @__PURE__ */ a.jsx("h2", { children: Ne(u.formatMessage, `${we}title`, t.type, "action") }),
|
|
9139
9155
|
/* @__PURE__ */ a.jsx(
|
|
9140
9156
|
tr,
|
|
9141
9157
|
{
|
|
@@ -9144,21 +9160,21 @@ const we = "discussion_form_", ar = ({
|
|
|
9144
9160
|
gtmType: "profile-click"
|
|
9145
9161
|
}
|
|
9146
9162
|
),
|
|
9147
|
-
/* @__PURE__ */ a.jsx(be, { element: "label", showOnFocus: !1, htmlFor: `${w}-input`, children:
|
|
9163
|
+
/* @__PURE__ */ a.jsx(be, { element: "label", showOnFocus: !1, htmlFor: `${w}-input`, children: Ne(u.formatMessage, `${we}label`, t.type, "action") }),
|
|
9148
9164
|
/* @__PURE__ */ a.jsx(
|
|
9149
9165
|
Ms,
|
|
9150
9166
|
{
|
|
9151
9167
|
ref: r,
|
|
9152
9168
|
id: `${w}-input`,
|
|
9153
9169
|
name: t.type,
|
|
9154
|
-
placeholder: s ||
|
|
9170
|
+
placeholder: s || Ne(
|
|
9155
9171
|
u.formatMessage,
|
|
9156
9172
|
`${we}placeholder`,
|
|
9157
9173
|
t.type,
|
|
9158
9174
|
"action"
|
|
9159
9175
|
),
|
|
9160
|
-
onChange:
|
|
9161
|
-
value:
|
|
9176
|
+
onChange: S,
|
|
9177
|
+
value: _ === "submitting" && !g ? "" : m,
|
|
9162
9178
|
maxLength: i,
|
|
9163
9179
|
"aria-invalid": !!g,
|
|
9164
9180
|
"aria-errormessage": "error-message",
|
|
@@ -9166,7 +9182,7 @@ const we = "discussion_form_", ar = ({
|
|
|
9166
9182
|
autoFocus: !!n.isEditing
|
|
9167
9183
|
}
|
|
9168
9184
|
),
|
|
9169
|
-
/* @__PURE__ */ a.jsx("small", { children:
|
|
9185
|
+
/* @__PURE__ */ a.jsx("small", { children: Ne(u.formatMessage, `${we}explainer`, t.type, "action", {
|
|
9170
9186
|
a: (j) => /* @__PURE__ */ a.jsx(
|
|
9171
9187
|
"a",
|
|
9172
9188
|
{
|
|
@@ -9181,7 +9197,7 @@ const we = "discussion_form_", ar = ({
|
|
|
9181
9197
|
)
|
|
9182
9198
|
}) }),
|
|
9183
9199
|
/* @__PURE__ */ a.jsx(kt, { buttons: B }),
|
|
9184
|
-
|
|
9200
|
+
_ === "submitted" && n.showSuccessMessage && /* @__PURE__ */ a.jsx(Wt, { className: "success", "data-testid": "success", children: Ne(u.formatMessage, `${we}success`, t.type, "action") }),
|
|
9185
9201
|
g && /* @__PURE__ */ a.jsx(Wt, { id: "error-message", className: "error", "data-testid": "error", children: c.error ? c.error : typeof g == "string" ? g.includes(" ") ? g : u.formatMessage(
|
|
9186
9202
|
{ id: g },
|
|
9187
9203
|
{
|
|
@@ -9255,11 +9271,11 @@ const An = () => {
|
|
|
9255
9271
|
ae(() => {
|
|
9256
9272
|
p(s);
|
|
9257
9273
|
}, [s]);
|
|
9258
|
-
const [u, f] = X(e), [m, p] = X(s), [g, v] = X(!1), [
|
|
9274
|
+
const [u, f] = X(e), [m, p] = X(s), [g, v] = X(!1), [_, y] = X(!1), x = wt(
|
|
9259
9275
|
() => Ec(n, Dn),
|
|
9260
9276
|
[n]
|
|
9261
|
-
),
|
|
9262
|
-
if (
|
|
9277
|
+
), S = (b) => {
|
|
9278
|
+
if (b.preventDefault(), b.stopPropagation(), y(!1), bt)
|
|
9263
9279
|
return An(), !1;
|
|
9264
9280
|
if (An(), g || !o)
|
|
9265
9281
|
return !1;
|
|
@@ -9267,8 +9283,8 @@ const An = () => {
|
|
|
9267
9283
|
}, w = async () => {
|
|
9268
9284
|
if (An(), g || !o)
|
|
9269
9285
|
return !1;
|
|
9270
|
-
let
|
|
9271
|
-
|
|
9286
|
+
let b = m ? u - 1 : u + 1;
|
|
9287
|
+
b < 0 && (b = 0), v(!0), f(b), p(!m);
|
|
9272
9288
|
try {
|
|
9273
9289
|
if (i && i.slugs) {
|
|
9274
9290
|
const F = Tc(i.slugs);
|
|
@@ -9284,23 +9300,23 @@ const An = () => {
|
|
|
9284
9300
|
}
|
|
9285
9301
|
};
|
|
9286
9302
|
return Y.createElement(t, {
|
|
9287
|
-
className:
|
|
9303
|
+
className: E("likes-wrapper text-medium action-button", {
|
|
9288
9304
|
"show-spinner": g,
|
|
9289
9305
|
"is-liked": m,
|
|
9290
9306
|
disabled: !o
|
|
9291
9307
|
}),
|
|
9292
|
-
onClick:
|
|
9308
|
+
onClick: S,
|
|
9293
9309
|
onMouseEnter: () => {
|
|
9294
|
-
|
|
9310
|
+
y(!0);
|
|
9295
9311
|
},
|
|
9296
9312
|
onMouseLeave: () => {
|
|
9297
|
-
|
|
9313
|
+
y(!1);
|
|
9298
9314
|
},
|
|
9299
9315
|
onFocus: () => {
|
|
9300
|
-
|
|
9316
|
+
y(!0);
|
|
9301
9317
|
},
|
|
9302
9318
|
onBlur: () => {
|
|
9303
|
-
|
|
9319
|
+
y(!1);
|
|
9304
9320
|
},
|
|
9305
9321
|
children: /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
9306
9322
|
/* @__PURE__ */ a.jsx(
|
|
@@ -9309,7 +9325,7 @@ const An = () => {
|
|
|
9309
9325
|
variant: "tertiary",
|
|
9310
9326
|
size: "medium",
|
|
9311
9327
|
icon: { icon: m ? "heart" : "heart_empty", animate: "bounce" },
|
|
9312
|
-
className:
|
|
9328
|
+
className: E({ "do-animation": m && !s }),
|
|
9313
9329
|
screenreaderText: o ? l.formatMessage(
|
|
9314
9330
|
{
|
|
9315
9331
|
id: `discussion_likes_${m ? "unlike" : "like"}`
|
|
@@ -9320,7 +9336,7 @@ const An = () => {
|
|
|
9320
9336
|
})
|
|
9321
9337
|
}
|
|
9322
9338
|
) : !1,
|
|
9323
|
-
onClick:
|
|
9339
|
+
onClick: S,
|
|
9324
9340
|
disabled: !o,
|
|
9325
9341
|
"aria-hidden": !o,
|
|
9326
9342
|
"data-testid": "like-button",
|
|
@@ -9331,7 +9347,7 @@ const An = () => {
|
|
|
9331
9347
|
/* @__PURE__ */ a.jsx(
|
|
9332
9348
|
"span",
|
|
9333
9349
|
{
|
|
9334
|
-
className:
|
|
9350
|
+
className: E("number-of-likes", { "no-likes": u === 0 }),
|
|
9335
9351
|
"data-testid": "number-of-likes",
|
|
9336
9352
|
children: l.formatMessage(
|
|
9337
9353
|
{ id: `discussion_likes${r ? "_short" : ""}` },
|
|
@@ -9339,17 +9355,17 @@ const An = () => {
|
|
|
9339
9355
|
)
|
|
9340
9356
|
}
|
|
9341
9357
|
),
|
|
9342
|
-
n && /* @__PURE__ */ a.jsx(_i, { isOpen:
|
|
9343
|
-
x.map((
|
|
9358
|
+
n && /* @__PURE__ */ a.jsx(_i, { isOpen: _, isLoading: n.length === 0, children: n.length && /* @__PURE__ */ a.jsxs("ul", { children: [
|
|
9359
|
+
x.map((b) => typeof b == "string" || !b.name ? null : /* @__PURE__ */ a.jsx("li", { children: /* @__PURE__ */ a.jsx(
|
|
9344
9360
|
at,
|
|
9345
9361
|
{
|
|
9346
|
-
href:
|
|
9362
|
+
href: b.id ? `/profiles/${b.id}` : void 0,
|
|
9347
9363
|
gtmContext: "Likes",
|
|
9348
9364
|
gtmType: "liked-name-click",
|
|
9349
9365
|
onClick: (F) => F == null ? void 0 : F.stopPropagation(),
|
|
9350
|
-
children:
|
|
9366
|
+
children: b.name
|
|
9351
9367
|
}
|
|
9352
|
-
) },
|
|
9368
|
+
) }, b.id || window.btoa(b.name))),
|
|
9353
9369
|
e > Dn && /* @__PURE__ */ a.jsx("li", { children: l.formatMessage(
|
|
9354
9370
|
{ id: "discussion_likes_more" },
|
|
9355
9371
|
{ number: e - Dn }
|
|
@@ -9391,9 +9407,9 @@ const Me = "discussion_", Cc = 280, cn = ({
|
|
|
9391
9407
|
className: p,
|
|
9392
9408
|
gtmContext: g = "DiscussionAnswer",
|
|
9393
9409
|
children: v,
|
|
9394
|
-
isTruncated:
|
|
9410
|
+
isTruncated: _ = !1
|
|
9395
9411
|
}) => {
|
|
9396
|
-
const
|
|
9412
|
+
const y = H(), x = Ee(De), S = Ee(sr), { author: w, canLike: b, createdAt: F, id: R, likes: Q = 0, userLiked: B, comments: N = 0 } = e, C = x && x.id && typeof w != "string" && w.id && w.id === x.id || !1, k = typeof b == "boolean" ? b : n ? !C : !1, j = C && (!e.createdAt || Ys(e.createdAt, 10, "seconds")), $ = pe(null), [A, W] = X({
|
|
9397
9413
|
body: e && e.body || "",
|
|
9398
9414
|
isEditing: !1,
|
|
9399
9415
|
didEdit: e && e.isEdited || !1
|
|
@@ -9402,7 +9418,7 @@ const Me = "discussion_", Cc = 280, cn = ({
|
|
|
9402
9418
|
/* Default */
|
|
9403
9419
|
), [P, q] = X("");
|
|
9404
9420
|
ae(() => {
|
|
9405
|
-
const O =
|
|
9421
|
+
const O = $.current;
|
|
9406
9422
|
if (!(!O || K === "default"))
|
|
9407
9423
|
return document.addEventListener("discussionFormSubmitted", L), O.addEventListener("transitionend", U), () => {
|
|
9408
9424
|
document.removeEventListener("discussionFormSubmitted", L), O.removeEventListener("transitionend", U);
|
|
@@ -9422,11 +9438,11 @@ const Me = "discussion_", Cc = 280, cn = ({
|
|
|
9422
9438
|
);
|
|
9423
9439
|
}, 1e3);
|
|
9424
9440
|
}, U = ({ propertyName: O }) => {
|
|
9425
|
-
O === "background-color" && T((oe) => (oe === "default" && (document.removeEventListener("discussionFormSubmitted", L),
|
|
9441
|
+
O === "background-color" && T((oe) => (oe === "default" && (document.removeEventListener("discussionFormSubmitted", L), $.current && $.current.removeEventListener("transitionend", U)), oe === "fading" ? "default" : oe));
|
|
9426
9442
|
};
|
|
9427
9443
|
if (r || !e || e.type === "answer" && (!e.slugs || !e.slugs.question))
|
|
9428
9444
|
return /* @__PURE__ */ a.jsx(Se, { className: "discussion-card discussion-post" });
|
|
9429
|
-
const te =
|
|
9445
|
+
const te = _ ? et(A.body, Cc) : A.body, G = async (O) => {
|
|
9430
9446
|
O || (O = ""), q("");
|
|
9431
9447
|
try {
|
|
9432
9448
|
if (!Rs(O, A.body)) {
|
|
@@ -9438,9 +9454,9 @@ const Me = "discussion_", Cc = 280, cn = ({
|
|
|
9438
9454
|
q(`${Me}form_error`);
|
|
9439
9455
|
}
|
|
9440
9456
|
}, V = () => {
|
|
9441
|
-
|
|
9442
|
-
var
|
|
9443
|
-
const oe = `reply-form-${(e.type === "answer" ? e.slug : ((
|
|
9457
|
+
S && S.updateConversation && S.updateConversation({ showForm: !0 }), setTimeout(() => {
|
|
9458
|
+
var $e, Ce, Ue;
|
|
9459
|
+
const oe = `reply-form-${(e.type === "answer" ? e.slug : (($e = e.slugs) == null ? void 0 : $e.reply) || ((Ce = e.slugs) == null ? void 0 : Ce.answer) || ((Ue = e.slugs) == null ? void 0 : Ue.question) || "").toLowerCase().slice(-15)}`, D = document.getElementById(oe), ve = document.getElementById(`${oe}-input`);
|
|
9444
9460
|
ve && ve.focus(), D && D.scrollIntoView({ behavior: "smooth" });
|
|
9445
9461
|
}, 0);
|
|
9446
9462
|
}, ee = async () => {
|
|
@@ -9452,14 +9468,14 @@ const Me = "discussion_", Cc = 280, cn = ({
|
|
|
9452
9468
|
}
|
|
9453
9469
|
}, re = [
|
|
9454
9470
|
{
|
|
9455
|
-
text:
|
|
9471
|
+
text: y.formatMessage({ id: `${Me}moreMenu_report` }),
|
|
9456
9472
|
onClick: (O) => {
|
|
9457
9473
|
O.stopPropagation();
|
|
9458
9474
|
},
|
|
9459
9475
|
href: `mailto:community@apolitical.co?subject=${encodeURI(
|
|
9460
|
-
|
|
9476
|
+
y.formatMessage({ id: `${Me}report_subject` })
|
|
9461
9477
|
)}&body=${encodeURI(
|
|
9462
|
-
|
|
9478
|
+
y.formatMessage(
|
|
9463
9479
|
{ id: `${Me}report_body` },
|
|
9464
9480
|
{
|
|
9465
9481
|
contentType: e.type || "",
|
|
@@ -9473,7 +9489,7 @@ const Me = "discussion_", Cc = 280, cn = ({
|
|
|
9473
9489
|
];
|
|
9474
9490
|
return n && C && re.push(
|
|
9475
9491
|
{
|
|
9476
|
-
text:
|
|
9492
|
+
text: y.formatMessage({ id: `${Me}moreMenu_edit` }),
|
|
9477
9493
|
onClick: () => W({ ...A, isEditing: !0 }),
|
|
9478
9494
|
icon: "pencil-paper",
|
|
9479
9495
|
className: "gtm-trackable",
|
|
@@ -9481,7 +9497,7 @@ const Me = "discussion_", Cc = 280, cn = ({
|
|
|
9481
9497
|
"data-gtm-event-type": `edit-${e.type}-click`
|
|
9482
9498
|
},
|
|
9483
9499
|
{
|
|
9484
|
-
text:
|
|
9500
|
+
text: y.formatMessage({ id: `${Me}moreMenu_delete` }),
|
|
9485
9501
|
onClick: (O) => {
|
|
9486
9502
|
O.preventDefault(), O.stopPropagation(), z(!0);
|
|
9487
9503
|
},
|
|
@@ -9492,17 +9508,17 @@ const Me = "discussion_", Cc = 280, cn = ({
|
|
|
9492
9508
|
...Xo(`delete-${e.slug}-modal`, Z)
|
|
9493
9509
|
}
|
|
9494
9510
|
), Y.createElement(t, {
|
|
9495
|
-
className:
|
|
9511
|
+
className: E("discussion-post", p, {
|
|
9496
9512
|
[K]: !p || !p.includes("highlighted-text-box")
|
|
9497
9513
|
}),
|
|
9498
|
-
ref:
|
|
9514
|
+
ref: $,
|
|
9499
9515
|
"data-testid": `discussion-${e.type}-thread`,
|
|
9500
9516
|
children: /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
9501
9517
|
/* @__PURE__ */ a.jsxs(
|
|
9502
9518
|
"div",
|
|
9503
9519
|
{
|
|
9504
9520
|
id: R || e.slug,
|
|
9505
|
-
className:
|
|
9521
|
+
className: E("discussion-card", e.type, {
|
|
9506
9522
|
editing: A.isEditing,
|
|
9507
9523
|
"has-link": m.post && !A.isEditing
|
|
9508
9524
|
}),
|
|
@@ -9532,10 +9548,10 @@ const Me = "discussion_", Cc = 280, cn = ({
|
|
|
9532
9548
|
},
|
|
9533
9549
|
maxLength: e.type === "question" ? 250 : 5e4,
|
|
9534
9550
|
forceShow: {
|
|
9535
|
-
error: P !== "" && P !== "delete-error" ?
|
|
9551
|
+
error: P !== "" && P !== "delete-error" ? y.formatMessage(
|
|
9536
9552
|
{ id: P },
|
|
9537
9553
|
{
|
|
9538
|
-
action:
|
|
9554
|
+
action: y.formatMessage({
|
|
9539
9555
|
id: `discussion_action_${e.type}`
|
|
9540
9556
|
})
|
|
9541
9557
|
}
|
|
@@ -9574,7 +9590,7 @@ const Me = "discussion_", Cc = 280, cn = ({
|
|
|
9574
9590
|
!A.isEditing && !(i != null && i.actionBar) && /* @__PURE__ */ a.jsxs(
|
|
9575
9591
|
"ul",
|
|
9576
9592
|
{
|
|
9577
|
-
className:
|
|
9593
|
+
className: E("actions text-medium", e.type),
|
|
9578
9594
|
"data-testid": `${e.type}-actions`,
|
|
9579
9595
|
children: [
|
|
9580
9596
|
!i.likes && /* @__PURE__ */ a.jsx(
|
|
@@ -9613,15 +9629,15 @@ const Me = "discussion_", Cc = 280, cn = ({
|
|
|
9613
9629
|
className: "gtm-trackable",
|
|
9614
9630
|
"data-gtm-event-context": g,
|
|
9615
9631
|
"data-gtm-event-type": `answer-${e.type}-click`,
|
|
9616
|
-
screenreaderText:
|
|
9632
|
+
screenreaderText: y.formatMessage(
|
|
9617
9633
|
{ id: `${Me}comments_screenReader` },
|
|
9618
|
-
{ count:
|
|
9634
|
+
{ count: N }
|
|
9619
9635
|
)
|
|
9620
9636
|
}
|
|
9621
9637
|
),
|
|
9622
|
-
/* @__PURE__ */ a.jsx("span", { children:
|
|
9638
|
+
/* @__PURE__ */ a.jsx("span", { children: y.formatMessage(
|
|
9623
9639
|
{ id: `${Me}comments` },
|
|
9624
|
-
{ count:
|
|
9640
|
+
{ count: N }
|
|
9625
9641
|
) })
|
|
9626
9642
|
]
|
|
9627
9643
|
}
|
|
@@ -9633,7 +9649,7 @@ const Me = "discussion_", Cc = 280, cn = ({
|
|
|
9633
9649
|
size: "medium",
|
|
9634
9650
|
styling: { muted: !0 },
|
|
9635
9651
|
onClick: V,
|
|
9636
|
-
children:
|
|
9652
|
+
children: y.formatMessage({ id: `${Me}reply` })
|
|
9637
9653
|
}
|
|
9638
9654
|
) }),
|
|
9639
9655
|
/* @__PURE__ */ a.jsx(
|
|
@@ -9659,30 +9675,30 @@ const Me = "discussion_", Cc = 280, cn = ({
|
|
|
9659
9675
|
functions: { onOpen: () => {
|
|
9660
9676
|
}, onClose: () => z(!1) },
|
|
9661
9677
|
forceShow: {
|
|
9662
|
-
error: P === "delete-error" ?
|
|
9678
|
+
error: P === "delete-error" ? y.formatMessage(
|
|
9663
9679
|
{ id: "discussion_delete_error" },
|
|
9664
9680
|
{
|
|
9665
|
-
action:
|
|
9681
|
+
action: y.formatMessage({
|
|
9666
9682
|
id: `discussion_action_${e.type}`
|
|
9667
9683
|
})
|
|
9668
9684
|
}
|
|
9669
9685
|
) : !1
|
|
9670
9686
|
},
|
|
9671
|
-
title:
|
|
9687
|
+
title: y.formatMessage(
|
|
9672
9688
|
{ id: "discussion_delete_title" },
|
|
9673
|
-
{ action:
|
|
9689
|
+
{ action: y.formatMessage({ id: `discussion_action_${e.type}` }) }
|
|
9674
9690
|
),
|
|
9675
9691
|
buttons: [
|
|
9676
9692
|
{
|
|
9677
9693
|
variant: "secondary",
|
|
9678
9694
|
onClick: () => z(!1),
|
|
9679
|
-
children:
|
|
9695
|
+
children: y.formatMessage({ id: "discussion_delete_cancel" })
|
|
9680
9696
|
},
|
|
9681
9697
|
{
|
|
9682
9698
|
variant: "primary",
|
|
9683
9699
|
className: "destructive",
|
|
9684
9700
|
onClick: ee,
|
|
9685
|
-
children:
|
|
9701
|
+
children: y.formatMessage({ id: "discussion_delete_delete" })
|
|
9686
9702
|
}
|
|
9687
9703
|
],
|
|
9688
9704
|
gtmContext: `${e.type.charAt(0).toUpperCase()}${e.type.slice(1)}:${e.slug}`,
|
|
@@ -9692,7 +9708,7 @@ const Me = "discussion_", Cc = 280, cn = ({
|
|
|
9692
9708
|
id: "discussion_delete_text",
|
|
9693
9709
|
values: {
|
|
9694
9710
|
p: (O) => /* @__PURE__ */ a.jsx("p", { children: O }),
|
|
9695
|
-
action:
|
|
9711
|
+
action: y.formatMessage({
|
|
9696
9712
|
id: `discussion_action_${e.type}`
|
|
9697
9713
|
})
|
|
9698
9714
|
}
|
|
@@ -9703,17 +9719,17 @@ const Me = "discussion_", Cc = 280, cn = ({
|
|
|
9703
9719
|
] })
|
|
9704
9720
|
});
|
|
9705
9721
|
};
|
|
9706
|
-
const In = "discussion_responses_",
|
|
9722
|
+
const In = "discussion_responses_", Nc = ({ type: t = "answer", responses: e = 0 }) => {
|
|
9707
9723
|
const n = H();
|
|
9708
9724
|
return e = parseInt(e), /* @__PURE__ */ a.jsxs("div", { className: "responses-heading", children: [
|
|
9709
9725
|
/* @__PURE__ */ a.jsx("h4", { children: n.formatMessage(
|
|
9710
9726
|
{ id: `${In}title` },
|
|
9711
9727
|
{ action: n.formatMessage({ id: `${In}${t}` }), count: e }
|
|
9712
9728
|
) }),
|
|
9713
|
-
e === 0 && /* @__PURE__ */ a.jsx("p", { children:
|
|
9729
|
+
e === 0 && /* @__PURE__ */ a.jsx("p", { children: Ne(n.formatMessage, `${In}empty`, t, t) })
|
|
9714
9730
|
] });
|
|
9715
9731
|
};
|
|
9716
|
-
const
|
|
9732
|
+
const $c = ({
|
|
9717
9733
|
loadMore: { isLoading: t, hasNextPage: e, loadNextPage: n } = {
|
|
9718
9734
|
isLoading: !1,
|
|
9719
9735
|
hasNextPage: !1,
|
|
@@ -10135,9 +10151,9 @@ function Wc({
|
|
|
10135
10151
|
},
|
|
10136
10152
|
user: d,
|
|
10137
10153
|
...l
|
|
10138
|
-
}, f = qc({ ...u, mutationFn: t }), m = Uc({ ...u, mutationFn: e }), p = zc({ ...u, mutationFn: n }), g = Hc({ ...u, mutationFn: s }), v = Vc({ ...u, mutationFn: i }), { activities:
|
|
10154
|
+
}, f = qc({ ...u, mutationFn: t }), m = Uc({ ...u, mutationFn: e }), p = zc({ ...u, mutationFn: n }), g = Hc({ ...u, mutationFn: s }), v = Vc({ ...u, mutationFn: i }), { activities: _, ...y } = Zc({ queryKey: o, queryFn: r });
|
|
10139
10155
|
return {
|
|
10140
|
-
activities:
|
|
10156
|
+
activities: _,
|
|
10141
10157
|
mutations: {
|
|
10142
10158
|
create: f,
|
|
10143
10159
|
edit: m,
|
|
@@ -10146,7 +10162,7 @@ function Wc({
|
|
|
10146
10162
|
unlike: v
|
|
10147
10163
|
},
|
|
10148
10164
|
user: d,
|
|
10149
|
-
...
|
|
10165
|
+
...y
|
|
10150
10166
|
};
|
|
10151
10167
|
}
|
|
10152
10168
|
function zc({
|
|
@@ -10268,8 +10284,8 @@ const pu = ({
|
|
|
10268
10284
|
fetchNextPage: l,
|
|
10269
10285
|
hasNextPage: u,
|
|
10270
10286
|
isLoading: f,
|
|
10271
|
-
mutations: { create: m, edit: p, remove: g, like: v, unlike:
|
|
10272
|
-
user:
|
|
10287
|
+
mutations: { create: m, edit: p, remove: g, like: v, unlike: _ },
|
|
10288
|
+
user: y
|
|
10273
10289
|
} = Wc({
|
|
10274
10290
|
queryKey: [t, e, "activities"],
|
|
10275
10291
|
queryFns: r
|
|
@@ -10295,34 +10311,34 @@ const pu = ({
|
|
|
10295
10311
|
}
|
|
10296
10312
|
}
|
|
10297
10313
|
),
|
|
10298
|
-
c == null ? void 0 : c.map((
|
|
10314
|
+
c == null ? void 0 : c.map((S, w) => {
|
|
10299
10315
|
var A, W, Z, z, K, T, P, q;
|
|
10300
10316
|
const {
|
|
10301
|
-
id:
|
|
10317
|
+
id: b,
|
|
10302
10318
|
own_reactions: F,
|
|
10303
10319
|
latest_reactions: R,
|
|
10304
10320
|
reaction_counts: Q
|
|
10305
|
-
} =
|
|
10321
|
+
} = S, B = (((A = R == null ? void 0 : R.like) == null ? void 0 : A.length) || 0) > 0, N = (((W = F == null ? void 0 : F.like) == null ? void 0 : W.length) || 0) > 0, C = N ? F == null ? void 0 : F.like[0].id : "", k = B ? (Z = R == null ? void 0 : R.like) == null ? void 0 : Z.map((L) => {
|
|
10306
10322
|
var U, te, G;
|
|
10307
10323
|
return {
|
|
10308
10324
|
id: (U = L == null ? void 0 : L.user) == null ? void 0 : U.id,
|
|
10309
10325
|
name: (G = (te = L == null ? void 0 : L.user) == null ? void 0 : te.data) == null ? void 0 : G.name
|
|
10310
10326
|
};
|
|
10311
|
-
}) : !1, j =
|
|
10327
|
+
}) : !1, j = S == null ? void 0 : S.actor, $ = (j == null ? void 0 : j.id) === (y == null ? void 0 : y.id);
|
|
10312
10328
|
return /* @__PURE__ */ a.jsxs(yt, { children: [
|
|
10313
10329
|
/* @__PURE__ */ a.jsx(
|
|
10314
10330
|
cn,
|
|
10315
10331
|
{
|
|
10316
10332
|
content: {
|
|
10317
10333
|
type: "post",
|
|
10318
|
-
body:
|
|
10319
|
-
canLike: on(n,
|
|
10320
|
-
createdAt: (
|
|
10334
|
+
body: S == null ? void 0 : S.content,
|
|
10335
|
+
canLike: on(n, $),
|
|
10336
|
+
createdAt: (S == null ? void 0 : S.time) || "",
|
|
10321
10337
|
slugs: {
|
|
10322
10338
|
question: `${t}/${e}`,
|
|
10323
|
-
answer:
|
|
10339
|
+
answer: b
|
|
10324
10340
|
},
|
|
10325
|
-
slug:
|
|
10341
|
+
slug: b,
|
|
10326
10342
|
author: {
|
|
10327
10343
|
id: j == null ? void 0 : j.id,
|
|
10328
10344
|
name: (z = j == null ? void 0 : j.data) == null ? void 0 : z.name,
|
|
@@ -10333,25 +10349,25 @@ const pu = ({
|
|
|
10333
10349
|
thumbnail: ((q = j == null ? void 0 : j.data) == null ? void 0 : q.thumbnail) || void 0
|
|
10334
10350
|
}
|
|
10335
10351
|
},
|
|
10336
|
-
userLiked:
|
|
10352
|
+
userLiked: N,
|
|
10337
10353
|
likes: (Q == null ? void 0 : Q.like) || 0,
|
|
10338
10354
|
comments: (Q == null ? void 0 : Q.reply) || 0,
|
|
10339
10355
|
peopleWhoLiked: k
|
|
10340
10356
|
},
|
|
10341
10357
|
links: {
|
|
10342
|
-
post: `${t}/${e}/${
|
|
10343
|
-
comments: `${t}/${e}/${
|
|
10358
|
+
post: `${t}/${e}/${b}`,
|
|
10359
|
+
comments: `${t}/${e}/${b}`
|
|
10344
10360
|
},
|
|
10345
10361
|
functions: {
|
|
10346
10362
|
content: {
|
|
10347
10363
|
createContent: () => null,
|
|
10348
|
-
deleteContent: () => g({ activityId:
|
|
10364
|
+
deleteContent: () => g({ activityId: b }),
|
|
10349
10365
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
10350
|
-
updateContent: (L, { body: U }) => p({ activityId:
|
|
10366
|
+
updateContent: (L, { body: U }) => p({ activityId: b, content: U })
|
|
10351
10367
|
},
|
|
10352
10368
|
likes: {
|
|
10353
|
-
createLike: () => v({ activityId:
|
|
10354
|
-
deleteLike: () =>
|
|
10369
|
+
createLike: () => v({ activityId: b }),
|
|
10370
|
+
deleteLike: () => _({ activityId: b, reactionId: C })
|
|
10355
10371
|
},
|
|
10356
10372
|
comments: {
|
|
10357
10373
|
openComments: () => null
|
|
@@ -10361,7 +10377,7 @@ const pu = ({
|
|
|
10361
10377
|
}
|
|
10362
10378
|
),
|
|
10363
10379
|
x > w + 1 && /* @__PURE__ */ a.jsx(Oe, {})
|
|
10364
|
-
] },
|
|
10380
|
+
] }, b);
|
|
10365
10381
|
}),
|
|
10366
10382
|
!f && /* @__PURE__ */ a.jsx(
|
|
10367
10383
|
sn,
|
|
@@ -10992,9 +11008,9 @@ function es({
|
|
|
10992
11008
|
},
|
|
10993
11009
|
user: d,
|
|
10994
11010
|
...l
|
|
10995
|
-
}, f = Gc({ ...u, mutationFn: t }), m = Qc({ ...u, mutationFn: e }), p = Jc({ ...u, mutationFn: n }), g = el({ ...u, mutationFn: s }), v = tl({ ...u, mutationFn: i }), { replies:
|
|
11011
|
+
}, f = Gc({ ...u, mutationFn: t }), m = Qc({ ...u, mutationFn: e }), p = Jc({ ...u, mutationFn: n }), g = el({ ...u, mutationFn: s }), v = tl({ ...u, mutationFn: i }), { replies: _, ...y } = Xc({ queryKey: o, queryFn: r });
|
|
10996
11012
|
return {
|
|
10997
|
-
replies:
|
|
11013
|
+
replies: _,
|
|
10998
11014
|
mutations: {
|
|
10999
11015
|
create: f,
|
|
11000
11016
|
edit: m,
|
|
@@ -11003,7 +11019,7 @@ function es({
|
|
|
11003
11019
|
unlike: v
|
|
11004
11020
|
},
|
|
11005
11021
|
user: d,
|
|
11006
|
-
...
|
|
11022
|
+
...y
|
|
11007
11023
|
};
|
|
11008
11024
|
}
|
|
11009
11025
|
function Jc({
|
|
@@ -11144,11 +11160,11 @@ const ol = ({
|
|
|
11144
11160
|
queryFns: {
|
|
11145
11161
|
...i,
|
|
11146
11162
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
11147
|
-
list: (
|
|
11163
|
+
list: (_) => i.list({ ..._, reactionId: r })
|
|
11148
11164
|
}
|
|
11149
11165
|
});
|
|
11150
11166
|
return /* @__PURE__ */ a.jsx(
|
|
11151
|
-
|
|
11167
|
+
$c,
|
|
11152
11168
|
{
|
|
11153
11169
|
loadMore: { isLoading: l, hasNextPage: d, loadNextPage: () => c() },
|
|
11154
11170
|
form: {
|
|
@@ -11162,45 +11178,45 @@ const ol = ({
|
|
|
11162
11178
|
},
|
|
11163
11179
|
functions: {
|
|
11164
11180
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
11165
|
-
create: (
|
|
11181
|
+
create: (_, { body: y }) => u({ activityId: n, replyId: r, content: y })
|
|
11166
11182
|
},
|
|
11167
11183
|
meta: { isEditing: !1, showSuccessMessage: !1 }
|
|
11168
11184
|
},
|
|
11169
|
-
children: o && o.length > 0 ? o == null ? void 0 : o.map((
|
|
11185
|
+
children: o && o.length > 0 ? o == null ? void 0 : o.map((_) => {
|
|
11170
11186
|
var A, W, Z, z, K, T, P, q, L, U, te, G;
|
|
11171
11187
|
const {
|
|
11172
|
-
id:
|
|
11188
|
+
id: y,
|
|
11173
11189
|
own_children: x,
|
|
11174
|
-
latest_children:
|
|
11190
|
+
latest_children: S,
|
|
11175
11191
|
children_counts: w
|
|
11176
|
-
} =
|
|
11192
|
+
} = _, F = (((A = x == null ? void 0 : x.like) == null ? void 0 : A.length) || 0) > 0 ? (W = x == null ? void 0 : x.like) == null ? void 0 : W.find((V) => {
|
|
11177
11193
|
var ee;
|
|
11178
11194
|
return ((ee = V == null ? void 0 : V.user) == null ? void 0 : ee.id) === (v == null ? void 0 : v.id);
|
|
11179
|
-
}) : !1, R = F ? F == null ? void 0 : F.id : "", Q = !!F,
|
|
11195
|
+
}) : !1, R = F ? F == null ? void 0 : F.id : "", Q = !!F, N = (((Z = S == null ? void 0 : S.like) == null ? void 0 : Z.length) || 0) > 0 ? (z = S == null ? void 0 : S.like) == null ? void 0 : z.map((V) => {
|
|
11180
11196
|
var ee, re, O;
|
|
11181
11197
|
return {
|
|
11182
11198
|
id: (ee = V == null ? void 0 : V.user) == null ? void 0 : ee.id,
|
|
11183
11199
|
name: (O = (re = V == null ? void 0 : V.user) == null ? void 0 : re.data) == null ? void 0 : O.name
|
|
11184
11200
|
};
|
|
11185
|
-
}) : !1, C =
|
|
11201
|
+
}) : !1, C = _ == null ? void 0 : _.user, k = (C == null ? void 0 : C.id) === (v == null ? void 0 : v.id), j = on(s, k), $ = typeof _.data.content == "string" ? (K = _ == null ? void 0 : _.data) == null ? void 0 : K.content : (
|
|
11186
11202
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
11187
|
-
((P = (T =
|
|
11203
|
+
((P = (T = _ == null ? void 0 : _.data) == null ? void 0 : T.content) == null ? void 0 : P.text) || ""
|
|
11188
11204
|
);
|
|
11189
11205
|
return /* @__PURE__ */ a.jsx(
|
|
11190
11206
|
cn,
|
|
11191
11207
|
{
|
|
11192
11208
|
content: {
|
|
11193
|
-
id:
|
|
11209
|
+
id: y,
|
|
11194
11210
|
type: "reply",
|
|
11195
|
-
body:
|
|
11211
|
+
body: $,
|
|
11196
11212
|
canLike: j,
|
|
11197
|
-
createdAt:
|
|
11213
|
+
createdAt: _ == null ? void 0 : _.created_at,
|
|
11198
11214
|
slugs: {
|
|
11199
11215
|
question: `${t}/${e}`,
|
|
11200
11216
|
answer: n,
|
|
11201
11217
|
// Stop-gap solution to avoid having to change the DiscussionPost component
|
|
11202
11218
|
// The `reply` is currently used to define the form ID which handles the focus
|
|
11203
|
-
reply:
|
|
11219
|
+
reply: _ == null ? void 0 : _.parent
|
|
11204
11220
|
},
|
|
11205
11221
|
slug: "",
|
|
11206
11222
|
author: {
|
|
@@ -11215,23 +11231,23 @@ const ol = ({
|
|
|
11215
11231
|
},
|
|
11216
11232
|
userLiked: Q,
|
|
11217
11233
|
likes: (w == null ? void 0 : w.like) || 0,
|
|
11218
|
-
peopleWhoLiked:
|
|
11234
|
+
peopleWhoLiked: N
|
|
11219
11235
|
},
|
|
11220
11236
|
functions: {
|
|
11221
11237
|
content: {
|
|
11222
11238
|
createContent: () => null,
|
|
11223
|
-
deleteContent: () => p({ replyId:
|
|
11239
|
+
deleteContent: () => p({ replyId: y }),
|
|
11224
11240
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
11225
|
-
updateContent: (V, { body: ee }) => f({ replyId:
|
|
11241
|
+
updateContent: (V, { body: ee }) => f({ replyId: y, content: ee })
|
|
11226
11242
|
},
|
|
11227
11243
|
likes: {
|
|
11228
|
-
createLike: () => m({ replyId:
|
|
11229
|
-
deleteLike: () => g({ replyId:
|
|
11244
|
+
createLike: () => m({ replyId: y }),
|
|
11245
|
+
deleteLike: () => g({ replyId: y, reactionId: R })
|
|
11230
11246
|
},
|
|
11231
11247
|
comments: {}
|
|
11232
11248
|
}
|
|
11233
11249
|
},
|
|
11234
|
-
|
|
11250
|
+
y
|
|
11235
11251
|
);
|
|
11236
11252
|
}) : null
|
|
11237
11253
|
}
|
|
@@ -11249,14 +11265,14 @@ const ol = ({
|
|
|
11249
11265
|
fetchNextPage: u,
|
|
11250
11266
|
hasNextPage: f,
|
|
11251
11267
|
isLoading: m,
|
|
11252
|
-
mutations: { create: p, edit: g, like: v, remove:
|
|
11268
|
+
mutations: { create: p, edit: g, like: v, remove: _, unlike: y },
|
|
11253
11269
|
user: x
|
|
11254
11270
|
} = es({
|
|
11255
11271
|
queryKey: [t, e, n, "replies"],
|
|
11256
11272
|
queryFns: s
|
|
11257
11273
|
});
|
|
11258
11274
|
return Us(), Ja(), /* @__PURE__ */ a.jsxs("section", { children: [
|
|
11259
|
-
/* @__PURE__ */ a.jsx(
|
|
11275
|
+
/* @__PURE__ */ a.jsx(Nc, { type: "comment", responses: l }),
|
|
11260
11276
|
/* @__PURE__ */ a.jsx(
|
|
11261
11277
|
Va,
|
|
11262
11278
|
{
|
|
@@ -11264,7 +11280,7 @@ const ol = ({
|
|
|
11264
11280
|
content: { type: "reply", slugs: {} },
|
|
11265
11281
|
functions: {
|
|
11266
11282
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
11267
|
-
create: (
|
|
11283
|
+
create: (S, { body: w }) => p({ activityId: n, content: w })
|
|
11268
11284
|
},
|
|
11269
11285
|
meta: { isEditing: !1, showSuccessMessage: !1 },
|
|
11270
11286
|
placeholder: c.formatMessage({ id: "discussion_responses_placeholder" })
|
|
@@ -11278,20 +11294,20 @@ const ol = ({
|
|
|
11278
11294
|
}
|
|
11279
11295
|
}
|
|
11280
11296
|
),
|
|
11281
|
-
d == null ? void 0 : d.map((
|
|
11297
|
+
d == null ? void 0 : d.map((S) => {
|
|
11282
11298
|
var z, K, T, P, q, L, U, te, G, V, ee, re;
|
|
11283
|
-
const { id: w, own_children:
|
|
11299
|
+
const { id: w, own_children: b, latest_children: F, children_counts: R } = S, B = (((z = b == null ? void 0 : b.like) == null ? void 0 : z.length) || 0) > 0 ? (K = b == null ? void 0 : b.like) == null ? void 0 : K.find((O) => {
|
|
11284
11300
|
var oe;
|
|
11285
11301
|
return ((oe = O == null ? void 0 : O.user) == null ? void 0 : oe.id) === (x == null ? void 0 : x.id);
|
|
11286
|
-
}) : !1,
|
|
11302
|
+
}) : !1, N = B ? B == null ? void 0 : B.id : "", C = !!B, j = (((T = F == null ? void 0 : F.like) == null ? void 0 : T.length) || 0) > 0 ? (P = F == null ? void 0 : F.like) == null ? void 0 : P.map((O) => {
|
|
11287
11303
|
var oe, D, ve;
|
|
11288
11304
|
return {
|
|
11289
11305
|
id: (oe = O == null ? void 0 : O.user) == null ? void 0 : oe.id,
|
|
11290
11306
|
name: (ve = (D = O == null ? void 0 : O.user) == null ? void 0 : D.data) == null ? void 0 : ve.name
|
|
11291
11307
|
};
|
|
11292
|
-
}) : !1,
|
|
11308
|
+
}) : !1, $ = S == null ? void 0 : S.user, A = ($ == null ? void 0 : $.id) === (x == null ? void 0 : x.id), W = on(r, A), Z = typeof S.data.content == "string" ? (q = S == null ? void 0 : S.data) == null ? void 0 : q.content : (
|
|
11293
11309
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
11294
|
-
((U = (L =
|
|
11310
|
+
((U = (L = S == null ? void 0 : S.data) == null ? void 0 : L.content) == null ? void 0 : U.text) || ""
|
|
11295
11311
|
);
|
|
11296
11312
|
return /* @__PURE__ */ a.jsx(kc, { children: /* @__PURE__ */ a.jsx(
|
|
11297
11313
|
cn,
|
|
@@ -11301,7 +11317,7 @@ const ol = ({
|
|
|
11301
11317
|
type: "reply",
|
|
11302
11318
|
body: Z,
|
|
11303
11319
|
canLike: W,
|
|
11304
|
-
createdAt:
|
|
11320
|
+
createdAt: S == null ? void 0 : S.created_at,
|
|
11305
11321
|
slugs: {
|
|
11306
11322
|
question: `${t}/${e}`,
|
|
11307
11323
|
answer: n,
|
|
@@ -11309,13 +11325,13 @@ const ol = ({
|
|
|
11309
11325
|
},
|
|
11310
11326
|
slug: w,
|
|
11311
11327
|
author: {
|
|
11312
|
-
id:
|
|
11313
|
-
name: (te =
|
|
11314
|
-
organization: (G =
|
|
11315
|
-
jobTitle: (V =
|
|
11316
|
-
location: (ee =
|
|
11328
|
+
id: $ == null ? void 0 : $.id,
|
|
11329
|
+
name: (te = $.data) == null ? void 0 : te.name,
|
|
11330
|
+
organization: (G = $.data) == null ? void 0 : G.organization,
|
|
11331
|
+
jobTitle: (V = $.data) == null ? void 0 : V.jobTitle,
|
|
11332
|
+
location: (ee = $.data) == null ? void 0 : ee.location,
|
|
11317
11333
|
image: {
|
|
11318
|
-
thumbnail: ((re =
|
|
11334
|
+
thumbnail: ((re = $.data) == null ? void 0 : re.thumbnail) || void 0
|
|
11319
11335
|
}
|
|
11320
11336
|
},
|
|
11321
11337
|
userLiked: C,
|
|
@@ -11325,13 +11341,13 @@ const ol = ({
|
|
|
11325
11341
|
functions: {
|
|
11326
11342
|
content: {
|
|
11327
11343
|
createContent: () => null,
|
|
11328
|
-
deleteContent: () =>
|
|
11344
|
+
deleteContent: () => _({ replyId: w }),
|
|
11329
11345
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
11330
11346
|
updateContent: (O, { body: oe }) => g({ replyId: w, content: oe })
|
|
11331
11347
|
},
|
|
11332
11348
|
likes: {
|
|
11333
11349
|
createLike: () => v({ replyId: w }),
|
|
11334
|
-
deleteLike: () =>
|
|
11350
|
+
deleteLike: () => y({ replyId: w, reactionId: N })
|
|
11335
11351
|
},
|
|
11336
11352
|
comments: {}
|
|
11337
11353
|
},
|
|
@@ -11471,12 +11487,12 @@ const gu = ({
|
|
|
11471
11487
|
leave: d
|
|
11472
11488
|
}
|
|
11473
11489
|
}) => {
|
|
11474
|
-
var B,
|
|
11490
|
+
var B, N, C, k, j, $, A, W, Z, z;
|
|
11475
11491
|
const l = H(), u = Ee(De), {
|
|
11476
11492
|
activity: f,
|
|
11477
11493
|
error: m,
|
|
11478
11494
|
isLoading: p,
|
|
11479
|
-
mutations: { edit: g, like: v, unlike:
|
|
11495
|
+
mutations: { edit: g, like: v, unlike: _ }
|
|
11480
11496
|
} = dl({
|
|
11481
11497
|
queryFns: i,
|
|
11482
11498
|
queryKey: [t, e, n]
|
|
@@ -11491,7 +11507,7 @@ const gu = ({
|
|
|
11491
11507
|
text: l.formatMessage({ id: "activitySection_notFoundError" })
|
|
11492
11508
|
}
|
|
11493
11509
|
);
|
|
11494
|
-
const { own_reactions:
|
|
11510
|
+
const { own_reactions: y, latest_reactions: x } = f, S = (((B = x == null ? void 0 : x.like) == null ? void 0 : B.length) || 0) > 0, w = (((N = y == null ? void 0 : y.like) == null ? void 0 : N.length) || 0) > 0, b = w ? y == null ? void 0 : y.like[0].id : "", F = S ? (C = x == null ? void 0 : x.like) == null ? void 0 : C.map((K) => {
|
|
11495
11511
|
var T, P, q;
|
|
11496
11512
|
return {
|
|
11497
11513
|
id: (T = K == null ? void 0 : K.user) == null ? void 0 : T.id,
|
|
@@ -11518,7 +11534,7 @@ const gu = ({
|
|
|
11518
11534
|
id: R.id,
|
|
11519
11535
|
name: (k = R.data) == null ? void 0 : k.name,
|
|
11520
11536
|
organization: (j = R.data) == null ? void 0 : j.organization,
|
|
11521
|
-
jobTitle: (
|
|
11537
|
+
jobTitle: ($ = R.data) == null ? void 0 : $.jobTitle,
|
|
11522
11538
|
location: (A = R.data) == null ? void 0 : A.location,
|
|
11523
11539
|
image: {
|
|
11524
11540
|
thumbnail: ((W = R.data) == null ? void 0 : W.thumbnail) || void 0
|
|
@@ -11540,7 +11556,7 @@ const gu = ({
|
|
|
11540
11556
|
},
|
|
11541
11557
|
likes: {
|
|
11542
11558
|
createLike: () => v({ activityId: n }),
|
|
11543
|
-
deleteLike: () =>
|
|
11559
|
+
deleteLike: () => _({ activityId: n, reactionId: b })
|
|
11544
11560
|
},
|
|
11545
11561
|
comments: {
|
|
11546
11562
|
openComments: () => {
|
|
@@ -11683,7 +11699,7 @@ export {
|
|
|
11683
11699
|
ar as DiscussionForm,
|
|
11684
11700
|
Sc as DiscussionLikes,
|
|
11685
11701
|
cn as DiscussionPost,
|
|
11686
|
-
|
|
11702
|
+
$c as DiscussionThread,
|
|
11687
11703
|
Oe as Divider,
|
|
11688
11704
|
Il as DownloadSection,
|
|
11689
11705
|
ft as EMAILS,
|
|
@@ -11703,8 +11719,8 @@ export {
|
|
|
11703
11719
|
Wl as HighlightSection,
|
|
11704
11720
|
Fe as HighlightedTextBox,
|
|
11705
11721
|
Fl as IconBulletedList,
|
|
11706
|
-
|
|
11707
|
-
|
|
11722
|
+
$l as ImageContainer,
|
|
11723
|
+
Ni as IntlProvider,
|
|
11708
11724
|
Yi as InviteForm,
|
|
11709
11725
|
Jl as InviteModal,
|
|
11710
11726
|
Wa as JoinButton,
|
|
@@ -11726,7 +11742,7 @@ export {
|
|
|
11726
11742
|
uu as MembersList,
|
|
11727
11743
|
qa as Modal,
|
|
11728
11744
|
cc as MoreMenu,
|
|
11729
|
-
|
|
11745
|
+
Nl as NUMBER_OF_USERS,
|
|
11730
11746
|
dc as NavigationMenu,
|
|
11731
11747
|
bu as NotFoundError,
|
|
11732
11748
|
an as Overlay,
|
|
@@ -11741,7 +11757,7 @@ export {
|
|
|
11741
11757
|
Pl as ProgressTracker,
|
|
11742
11758
|
Vl as Rating,
|
|
11743
11759
|
cl as RepliesFeed,
|
|
11744
|
-
|
|
11760
|
+
Nc as ResponsesHeading,
|
|
11745
11761
|
Tt as ResponsiveImage,
|
|
11746
11762
|
Ml as ReturnToNavButton,
|
|
11747
11763
|
Ki as SearchForm,
|
|
@@ -11758,7 +11774,7 @@ export {
|
|
|
11758
11774
|
_i as Tooltip,
|
|
11759
11775
|
cu as TopLevelPage,
|
|
11760
11776
|
De as UserContext,
|
|
11761
|
-
|
|
11777
|
+
$i as UserProvider,
|
|
11762
11778
|
be as VisuallyHidden,
|
|
11763
11779
|
Xo as addAriaProps,
|
|
11764
11780
|
ma as basicReducer,
|