@keycloak/keycloak-ui-shared 26.2.0 → 26.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,40 +1,40 @@
|
|
|
1
|
-
import { jsx as t, jsxs as
|
|
2
|
-
import { AlertGroup as en, Alert as tn, AlertVariant as
|
|
3
|
-
import { createContext as
|
|
4
|
-
import { useTranslation as
|
|
5
|
-
import { NetworkError as
|
|
1
|
+
import { jsx as t, jsxs as C, Fragment as W } from "react/jsx-runtime";
|
|
2
|
+
import { AlertGroup as en, Alert as tn, AlertVariant as Me, AlertActionCloseButton as nn, Page as rn, Modal as Ct, ModalVariant as an, TextContent as ln, Text as Le, Button as V, Spinner as kt, FormHelperText as He, HelperText as We, HelperTextItem as je, Popover as sn, Icon as Ne, FormGroup as It, NumberInput as on, ValidatedOptions as z, InputGroup as we, InputGroupItem as Be, TextInput as xe, Select as Se, SelectList as Te, SelectOption as Ge, MenuToggle as ue, MenuToggleStatus as ze, TextInputGroup as wt, TextInputGroupMain as xt, ChipGroup as Je, Chip as Ye, TextInputGroupUtilities as St, Switch as cn, TextArea as Tt, Title as dn, Card as un, CardHeader as hn, CardTitle as pn, CardBody as mn, Grid as fn, GridItem as st, PageSection as gn, JumpLinks as yn, JumpLinksItem as bn, ButtonVariant as ke, Checkbox as vn, Radio as Cn, MenuFooter as kn, Dropdown as In, DropdownList as wn, DropdownItem as ot, Masthead as xn, MastheadToggle as Sn, PageToggleButton as Tn, MastheadBrand as En, MastheadContent as An, Toolbar as Ce, ToolbarContent as Ve, ToolbarItem as H, Avatar as Rn, Bullseye as On, EmptyState as Dn, EmptyStateIcon as ct, EmptyStateHeader as Fn, EmptyStateBody as Pn, EmptyStateFooter as Mn, EmptyStateActions as Ln, SearchInput as Nn, Divider as Bn, Pagination as Vn, Badge as _n } from "@patternfly/react-core";
|
|
3
|
+
import { createContext as Et, useContext as At, useRef as J, useEffect as ae, useCallback as de, useState as A, useMemo as _, forwardRef as qn, useId as Rt, Fragment as Ot, Children as Dt, Component as $n, isValidElement as Un } from "react";
|
|
4
|
+
import { useTranslation as q } from "react-i18next";
|
|
5
|
+
import { NetworkError as Ft } from "@keycloak/keycloak-admin-client";
|
|
6
6
|
import Kn from "keycloak-js";
|
|
7
|
-
import { ExclamationCircleIcon as Hn, HelpIcon as
|
|
8
|
-
import { useFormContext as
|
|
9
|
-
import { get as
|
|
10
|
-
import
|
|
7
|
+
import { ExclamationCircleIcon as Hn, HelpIcon as dt, EyeIcon as Wn, EyeSlashIcon as jn, TimesIcon as Pt, CubeIcon as Gn, PaypalIcon as zn, InstagramIcon as Jn, BitbucketIcon as Yn, MicrosoftIcon as Qn, TwitterIcon as Xn, StackOverflowIcon as Zn, OpenshiftIcon as er, LinkedinIcon as tr, GoogleIcon as nr, GitlabIcon as rr, FacebookSquareIcon as ar, GithubIcon as lr, MinusCircleIcon as ir, PlusCircleIcon as Mt, EllipsisVIcon as sr, BarsIcon as or, SearchIcon as cr, SyncAltIcon as dr } from "@patternfly/react-icons";
|
|
8
|
+
import { useFormContext as Ee, Controller as le, useController as Qe, FormProvider as ur, useWatch as hr } from "react-hook-form";
|
|
9
|
+
import { get as B, cloneDeep as pr, intersectionBy as mr } from "lodash-es";
|
|
10
|
+
import ye from "@patternfly/react-styles/css/components/Avatar/avatar";
|
|
11
11
|
import { css as fr } from "@patternfly/react-styles";
|
|
12
|
-
import { Table as gr, TableVariant as yr, Thead as
|
|
13
|
-
import './main.css';function
|
|
14
|
-
const r =
|
|
12
|
+
import { Table as gr, TableVariant as yr, Thead as br, Tr as be, Th as Fe, Tbody as ut, Td as ne, ExpandableRowContent as vr, ActionsColumn as Cr, TableText as kr } from "@patternfly/react-table";
|
|
13
|
+
import './main.css';function Xe(e, n) {
|
|
14
|
+
const r = Et(n);
|
|
15
15
|
return r.displayName = e, r;
|
|
16
16
|
}
|
|
17
|
-
const Ir = ["error", "errorMessage"],
|
|
17
|
+
const Ir = ["error", "errorMessage"], Pe = "error_description";
|
|
18
18
|
function wr(e) {
|
|
19
19
|
if (typeof e == "string")
|
|
20
20
|
return e;
|
|
21
|
-
if (e instanceof
|
|
22
|
-
return
|
|
21
|
+
if (e instanceof Ft)
|
|
22
|
+
return Sr(e.responseData);
|
|
23
23
|
if (e instanceof Error)
|
|
24
24
|
return e.message;
|
|
25
25
|
throw new Error("Unable to determine error message.");
|
|
26
26
|
}
|
|
27
27
|
function xr(e) {
|
|
28
|
-
if (!(e instanceof
|
|
28
|
+
if (!(e instanceof Ft))
|
|
29
29
|
return;
|
|
30
30
|
const n = e.responseData;
|
|
31
|
-
return
|
|
31
|
+
return Lt(n);
|
|
32
32
|
}
|
|
33
|
-
function
|
|
34
|
-
if (typeof e == "object" && e !== null &&
|
|
35
|
-
return e[
|
|
33
|
+
function Lt(e) {
|
|
34
|
+
if (typeof e == "object" && e !== null && Pe in e && typeof e[Pe] == "string")
|
|
35
|
+
return e[Pe];
|
|
36
36
|
}
|
|
37
|
-
function
|
|
37
|
+
function Sr(e) {
|
|
38
38
|
if (!(typeof e != "object" || e === null))
|
|
39
39
|
for (const n of Ir) {
|
|
40
40
|
const r = e[n];
|
|
@@ -42,32 +42,32 @@ function Tr(e) {
|
|
|
42
42
|
return r;
|
|
43
43
|
}
|
|
44
44
|
}
|
|
45
|
-
const
|
|
46
|
-
function
|
|
45
|
+
const Tr = () => Math.floor(Math.random() * 1e3);
|
|
46
|
+
function Er(e) {
|
|
47
47
|
return e != null;
|
|
48
48
|
}
|
|
49
|
-
function
|
|
49
|
+
function Ze(e) {
|
|
50
50
|
const n = At(e);
|
|
51
|
-
if (
|
|
51
|
+
if (Er(n))
|
|
52
52
|
return n;
|
|
53
53
|
throw new Error(
|
|
54
54
|
`No provider found for ${e.displayName ? `the '${e.displayName}'` : "an unknown"} context, make sure it is included in your component hierarchy.`
|
|
55
55
|
);
|
|
56
56
|
}
|
|
57
|
-
function
|
|
58
|
-
const e =
|
|
59
|
-
|
|
57
|
+
function Ar() {
|
|
58
|
+
const e = J(!1), n = J(/* @__PURE__ */ new Set());
|
|
59
|
+
ae(() => (e.current = !1, () => {
|
|
60
60
|
e.current = !0, r();
|
|
61
61
|
}), []);
|
|
62
62
|
function r() {
|
|
63
63
|
n.current.forEach((a) => clearTimeout(a)), n.current.clear();
|
|
64
64
|
}
|
|
65
|
-
return
|
|
65
|
+
return de((a, l) => {
|
|
66
66
|
if (e.current)
|
|
67
67
|
throw new Error("Can't schedule a timeout on an unmounted component.");
|
|
68
|
-
const i = Number(setTimeout(
|
|
68
|
+
const i = Number(setTimeout(s, l));
|
|
69
69
|
n.current.add(i);
|
|
70
|
-
function
|
|
70
|
+
function s() {
|
|
71
71
|
n.current.delete(i), a();
|
|
72
72
|
}
|
|
73
73
|
return function() {
|
|
@@ -82,12 +82,12 @@ function Rr({ alerts: e, onCloseAlert: n }) {
|
|
|
82
82
|
"data-testid": "global-alerts",
|
|
83
83
|
isToast: !0,
|
|
84
84
|
style: { whiteSpace: "pre-wrap" },
|
|
85
|
-
children: e.map(({ id: r, variant: a, message: l, description: i },
|
|
85
|
+
children: e.map(({ id: r, variant: a, message: l, description: i }, s) => /* @__PURE__ */ t(
|
|
86
86
|
tn,
|
|
87
87
|
{
|
|
88
|
-
"data-testid":
|
|
88
|
+
"data-testid": s === 0 ? "last-alert" : void 0,
|
|
89
89
|
isLiveRegion: !0,
|
|
90
|
-
variant:
|
|
90
|
+
variant: Me[a],
|
|
91
91
|
component: "p",
|
|
92
92
|
variantLabel: "",
|
|
93
93
|
title: l,
|
|
@@ -105,40 +105,40 @@ function Rr({ alerts: e, onCloseAlert: n }) {
|
|
|
105
105
|
}
|
|
106
106
|
);
|
|
107
107
|
}
|
|
108
|
-
const Or = 8e3,
|
|
108
|
+
const Or = 8e3, Nt = Xe(
|
|
109
109
|
"AlertContext",
|
|
110
110
|
void 0
|
|
111
|
-
), Va = () =>
|
|
112
|
-
const { t: n } =
|
|
113
|
-
(
|
|
114
|
-
const
|
|
115
|
-
id:
|
|
116
|
-
message:
|
|
111
|
+
), Va = () => Ze(Nt), Dr = ({ children: e }) => {
|
|
112
|
+
const { t: n } = q(), r = Ar(), [a, l] = A([]), i = (c) => l((h) => h.filter((d) => d.id !== c)), s = de(
|
|
113
|
+
(c, h = Me.success, d) => {
|
|
114
|
+
const g = {
|
|
115
|
+
id: Tr(),
|
|
116
|
+
message: c,
|
|
117
117
|
variant: h,
|
|
118
|
-
description:
|
|
118
|
+
description: d
|
|
119
119
|
};
|
|
120
|
-
l((
|
|
120
|
+
l((y) => [g, ...y]), r(() => i(g.id), Or);
|
|
121
121
|
},
|
|
122
122
|
[r]
|
|
123
|
-
),
|
|
124
|
-
(
|
|
125
|
-
const
|
|
126
|
-
|
|
123
|
+
), o = de(
|
|
124
|
+
(c, h) => {
|
|
125
|
+
const d = n(c, { error: wr(h) }), g = xr(h);
|
|
126
|
+
s(d, Me.danger, g);
|
|
127
127
|
},
|
|
128
|
-
[
|
|
129
|
-
), u =
|
|
130
|
-
return /* @__PURE__ */
|
|
128
|
+
[s, n]
|
|
129
|
+
), u = _(() => ({ addAlert: s, addError: o }), [s, o]);
|
|
130
|
+
return /* @__PURE__ */ C(Nt.Provider, { value: u, children: [
|
|
131
131
|
/* @__PURE__ */ t(Rr, { alerts: a, onCloseAlert: i }),
|
|
132
132
|
e
|
|
133
133
|
] });
|
|
134
134
|
}, Fr = (e) => {
|
|
135
|
-
const { t: n } =
|
|
135
|
+
const { t: n } = q(), r = e.error, a = Pr(r) || Lt(r)?.replace(/\+/g, " ");
|
|
136
136
|
console.error(r);
|
|
137
137
|
function l() {
|
|
138
138
|
location.href = location.origin + location.pathname;
|
|
139
139
|
}
|
|
140
140
|
return /* @__PURE__ */ t(rn, { children: /* @__PURE__ */ t(
|
|
141
|
-
|
|
141
|
+
Ct,
|
|
142
142
|
{
|
|
143
143
|
variant: an.small,
|
|
144
144
|
title: a ? "" : n("somethingWentWrong"),
|
|
@@ -146,9 +146,9 @@ const Or = 8e3, Lt = Qe(
|
|
|
146
146
|
showClose: !1,
|
|
147
147
|
isOpen: !0,
|
|
148
148
|
actions: [
|
|
149
|
-
/* @__PURE__ */ t(
|
|
149
|
+
/* @__PURE__ */ t(V, { variant: "primary", onClick: l, children: n("tryAgain") }, "tryAgain")
|
|
150
150
|
],
|
|
151
|
-
children: /* @__PURE__ */ t(ln, { children: a ? /* @__PURE__ */ t(
|
|
151
|
+
children: /* @__PURE__ */ t(ln, { children: a ? /* @__PURE__ */ t(Le, { children: n(a) }) : /* @__PURE__ */ t(Le, { children: n("somethingWentWrongDescription") }) })
|
|
152
152
|
}
|
|
153
153
|
) });
|
|
154
154
|
};
|
|
@@ -156,46 +156,46 @@ function Pr(e) {
|
|
|
156
156
|
return typeof e == "string" ? e : e instanceof Error ? e.message : null;
|
|
157
157
|
}
|
|
158
158
|
function Mr(e, n, r) {
|
|
159
|
-
const [a, l] =
|
|
159
|
+
const [a, l] = A(
|
|
160
160
|
() => e.getItem(n) ?? r
|
|
161
|
-
), i =
|
|
162
|
-
l(
|
|
161
|
+
), i = de((s) => {
|
|
162
|
+
l(s), e.setItem(n, s);
|
|
163
163
|
}, []);
|
|
164
|
-
return
|
|
165
|
-
l(e.getItem(n) ?? r), window.addEventListener("storage",
|
|
166
|
-
function o
|
|
167
|
-
|
|
164
|
+
return ae(() => {
|
|
165
|
+
l(e.getItem(n) ?? r), window.addEventListener("storage", s);
|
|
166
|
+
function s(o) {
|
|
167
|
+
o.storageArea === e && (o.key === null || o.key === n) && l(o.newValue ?? r);
|
|
168
168
|
}
|
|
169
|
-
return () => window.removeEventListener("storage",
|
|
169
|
+
return () => window.removeEventListener("storage", s);
|
|
170
170
|
}, [e, n]), [a, i];
|
|
171
171
|
}
|
|
172
|
-
function
|
|
173
|
-
const a =
|
|
172
|
+
function Bt(e, n, r) {
|
|
173
|
+
const a = _(
|
|
174
174
|
() => JSON.stringify(r),
|
|
175
175
|
[r]
|
|
176
176
|
), [l, i] = Mr(
|
|
177
177
|
e,
|
|
178
178
|
n,
|
|
179
179
|
a
|
|
180
|
-
),
|
|
180
|
+
), s = _(() => JSON.parse(l), [l]), o = de(
|
|
181
181
|
(u) => i(JSON.stringify(u)),
|
|
182
182
|
[]
|
|
183
183
|
);
|
|
184
|
-
return [
|
|
184
|
+
return [s, o];
|
|
185
185
|
}
|
|
186
|
-
const
|
|
186
|
+
const Vt = Xe(
|
|
187
187
|
"HelpContext",
|
|
188
188
|
void 0
|
|
189
|
-
), Lr = () =>
|
|
190
|
-
const [n, r] =
|
|
189
|
+
), Lr = () => Ze(Vt), Nr = ({ children: e }) => {
|
|
190
|
+
const [n, r] = Bt(localStorage, "helpEnabled", !0);
|
|
191
191
|
function a() {
|
|
192
192
|
r(!n);
|
|
193
193
|
}
|
|
194
|
-
return /* @__PURE__ */ t(
|
|
195
|
-
}, Br = () =>
|
|
196
|
-
let
|
|
194
|
+
return /* @__PURE__ */ t(Vt.Provider, { value: { enabled: n, toggleHelp: a }, children: e });
|
|
195
|
+
}, Br = () => Et(void 0);
|
|
196
|
+
let _e;
|
|
197
197
|
const _a = () => {
|
|
198
|
-
const e = At(
|
|
198
|
+
const e = At(_e);
|
|
199
199
|
if (!e)
|
|
200
200
|
throw Error(
|
|
201
201
|
"no environment provider in the hierarchy make sure to add the provider"
|
|
@@ -205,32 +205,32 @@ const _a = () => {
|
|
|
205
205
|
environment: e,
|
|
206
206
|
children: n
|
|
207
207
|
}) => {
|
|
208
|
-
|
|
209
|
-
const r =
|
|
210
|
-
const
|
|
208
|
+
_e = Br();
|
|
209
|
+
const r = J(!1), [a, l] = A(!1), [i, s] = A(), o = _(() => {
|
|
210
|
+
const c = new Kn({
|
|
211
211
|
url: e.serverBaseUrl,
|
|
212
212
|
realm: e.realm,
|
|
213
213
|
clientId: e.clientId
|
|
214
214
|
});
|
|
215
|
-
return
|
|
215
|
+
return c.onAuthLogout = () => c.login(), c;
|
|
216
216
|
}, [e]);
|
|
217
|
-
|
|
217
|
+
ae(() => {
|
|
218
218
|
if (r.current)
|
|
219
219
|
return;
|
|
220
|
-
|
|
220
|
+
o.init({
|
|
221
221
|
onLoad: "check-sso",
|
|
222
222
|
pkceMethod: "S256",
|
|
223
223
|
responseMode: "query",
|
|
224
224
|
scope: e.scope
|
|
225
|
-
}).then(() => l(!0)).catch((h) =>
|
|
226
|
-
}, [
|
|
225
|
+
}).then(() => l(!0)).catch((h) => s(h)), r.current = !0;
|
|
226
|
+
}, [o]);
|
|
227
227
|
const u = new URLSearchParams(window.location.search);
|
|
228
228
|
return i || u.get("error_description") ? /* @__PURE__ */ t(
|
|
229
229
|
Fr,
|
|
230
230
|
{
|
|
231
231
|
error: i || u.get("error_description")
|
|
232
232
|
}
|
|
233
|
-
) : a ? /* @__PURE__ */ t(
|
|
233
|
+
) : a ? /* @__PURE__ */ t(_e.Provider, { value: { environment: e, keycloak: o }, children: /* @__PURE__ */ t(Dr, { children: /* @__PURE__ */ t(Nr, { children: n }) }) }) : /* @__PURE__ */ t(kt, {});
|
|
234
234
|
};
|
|
235
235
|
function $a() {
|
|
236
236
|
const n = document.getElementById("environment")?.textContent;
|
|
@@ -249,68 +249,68 @@ const Ua = ({
|
|
|
249
249
|
buttonTitle: a,
|
|
250
250
|
isDisabled: l,
|
|
251
251
|
buttonVariant: i,
|
|
252
|
-
buttonTestRole:
|
|
253
|
-
onContinue:
|
|
254
|
-
component: u =
|
|
255
|
-
children:
|
|
252
|
+
buttonTestRole: s,
|
|
253
|
+
onContinue: o,
|
|
254
|
+
component: u = V,
|
|
255
|
+
children: c,
|
|
256
256
|
...h
|
|
257
257
|
}) => {
|
|
258
|
-
const [
|
|
259
|
-
return /* @__PURE__ */
|
|
258
|
+
const [d, g] = A(!1);
|
|
259
|
+
return /* @__PURE__ */ C(W, { children: [
|
|
260
260
|
/* @__PURE__ */ t(
|
|
261
261
|
u,
|
|
262
262
|
{
|
|
263
263
|
variant: i,
|
|
264
|
-
onClick: () =>
|
|
264
|
+
onClick: () => g(!0),
|
|
265
265
|
isDisabled: l,
|
|
266
|
-
"data-testrole":
|
|
266
|
+
"data-testrole": s,
|
|
267
267
|
children: a
|
|
268
268
|
}
|
|
269
269
|
),
|
|
270
270
|
/* @__PURE__ */ t(
|
|
271
|
-
|
|
271
|
+
Ct,
|
|
272
272
|
{
|
|
273
273
|
variant: "small",
|
|
274
274
|
...h,
|
|
275
275
|
title: e,
|
|
276
|
-
isOpen:
|
|
277
|
-
onClose: () =>
|
|
276
|
+
isOpen: d,
|
|
277
|
+
onClose: () => g(!1),
|
|
278
278
|
actions: [
|
|
279
279
|
/* @__PURE__ */ t(
|
|
280
|
-
|
|
280
|
+
V,
|
|
281
281
|
{
|
|
282
282
|
id: "modal-confirm",
|
|
283
283
|
variant: "primary",
|
|
284
284
|
onClick: () => {
|
|
285
|
-
|
|
285
|
+
g(!1), o();
|
|
286
286
|
},
|
|
287
287
|
children: n
|
|
288
288
|
},
|
|
289
289
|
"confirm"
|
|
290
290
|
),
|
|
291
291
|
/* @__PURE__ */ t(
|
|
292
|
-
|
|
292
|
+
V,
|
|
293
293
|
{
|
|
294
294
|
id: "modal-cancel",
|
|
295
295
|
variant: "secondary",
|
|
296
|
-
onClick: () =>
|
|
296
|
+
onClick: () => g(!1),
|
|
297
297
|
children: r
|
|
298
298
|
},
|
|
299
299
|
"cancel"
|
|
300
300
|
)
|
|
301
301
|
],
|
|
302
|
-
children:
|
|
302
|
+
children: c
|
|
303
303
|
}
|
|
304
304
|
)
|
|
305
305
|
] });
|
|
306
|
-
},
|
|
306
|
+
}, _t = ({ message: e, ...n }) => /* @__PURE__ */ t(He, { ...n, children: /* @__PURE__ */ t(We, { children: /* @__PURE__ */ t(je, { icon: /* @__PURE__ */ t(Hn, {}), variant: "error", children: e }) }) }), qt = ({
|
|
307
307
|
helpText: e,
|
|
308
308
|
fieldLabelId: n,
|
|
309
309
|
noVerticalAlign: r = !0,
|
|
310
310
|
unWrap: a = !1
|
|
311
311
|
}) => {
|
|
312
312
|
const { enabled: l } = Lr();
|
|
313
|
-
return l ? /* @__PURE__ */ t(
|
|
313
|
+
return l ? /* @__PURE__ */ t(sn, { bodyContent: e, children: /* @__PURE__ */ C(W, { children: [
|
|
314
314
|
!a && /* @__PURE__ */ t(
|
|
315
315
|
"button",
|
|
316
316
|
{
|
|
@@ -318,33 +318,33 @@ const Ua = ({
|
|
|
318
318
|
"aria-label": n,
|
|
319
319
|
onClick: (i) => i.preventDefault(),
|
|
320
320
|
className: "pf-v5-c-form__group-label-help",
|
|
321
|
-
children: /* @__PURE__ */ t(
|
|
321
|
+
children: /* @__PURE__ */ t(Ne, { isInline: r, children: /* @__PURE__ */ t(dt, {}) })
|
|
322
322
|
}
|
|
323
323
|
),
|
|
324
|
-
a && /* @__PURE__ */ t(
|
|
324
|
+
a && /* @__PURE__ */ t(Ne, { isInline: r, children: /* @__PURE__ */ t(dt, {}) })
|
|
325
325
|
] }) }) : null;
|
|
326
326
|
};
|
|
327
|
-
function
|
|
327
|
+
function he(e) {
|
|
328
328
|
if (!(typeof e > "u" || e instanceof RegExp))
|
|
329
329
|
return typeof e == "object" ? e.value : e;
|
|
330
330
|
}
|
|
331
|
-
const
|
|
331
|
+
const te = ({
|
|
332
332
|
name: e,
|
|
333
333
|
label: n,
|
|
334
334
|
labelIcon: r,
|
|
335
335
|
error: a,
|
|
336
336
|
children: l,
|
|
337
337
|
...i
|
|
338
|
-
}) => /* @__PURE__ */
|
|
339
|
-
|
|
338
|
+
}) => /* @__PURE__ */ C(
|
|
339
|
+
It,
|
|
340
340
|
{
|
|
341
341
|
label: n || e,
|
|
342
342
|
fieldId: e,
|
|
343
|
-
labelIcon: r ? /* @__PURE__ */ t(
|
|
343
|
+
labelIcon: r ? /* @__PURE__ */ t(qt, { helpText: r, fieldLabelId: e }) : void 0,
|
|
344
344
|
...i,
|
|
345
345
|
children: [
|
|
346
346
|
l,
|
|
347
|
-
a && /* @__PURE__ */ t(
|
|
347
|
+
a && /* @__PURE__ */ t(_t, { "data-testid": `${e}-helper`, message: a.message })
|
|
348
348
|
]
|
|
349
349
|
}
|
|
350
350
|
), Ka = ({
|
|
@@ -356,41 +356,41 @@ const ee = ({
|
|
|
356
356
|
}) => {
|
|
357
357
|
const {
|
|
358
358
|
control: i,
|
|
359
|
-
formState: { errors:
|
|
360
|
-
} =
|
|
359
|
+
formState: { errors: s }
|
|
360
|
+
} = Ee();
|
|
361
361
|
return /* @__PURE__ */ t(
|
|
362
|
-
|
|
362
|
+
te,
|
|
363
363
|
{
|
|
364
364
|
name: e,
|
|
365
365
|
label: n,
|
|
366
366
|
isRequired: r.rules?.required === !0,
|
|
367
|
-
error:
|
|
367
|
+
error: s[e],
|
|
368
368
|
labelIcon: a,
|
|
369
369
|
children: /* @__PURE__ */ t(
|
|
370
|
-
|
|
370
|
+
le,
|
|
371
371
|
{
|
|
372
372
|
...r,
|
|
373
373
|
name: e,
|
|
374
374
|
control: i,
|
|
375
|
-
render: ({ field:
|
|
376
|
-
const u = !!r.rules?.required,
|
|
377
|
-
|
|
375
|
+
render: ({ field: o }) => {
|
|
376
|
+
const u = !!r.rules?.required, c = he(r.rules?.min), h = o.value ?? r.defaultValue, d = (g) => o.onChange(
|
|
377
|
+
c !== void 0 ? Math.max(g, Number(c)) : g
|
|
378
378
|
);
|
|
379
379
|
return /* @__PURE__ */ t(
|
|
380
|
-
|
|
380
|
+
on,
|
|
381
381
|
{
|
|
382
382
|
...l,
|
|
383
383
|
id: e,
|
|
384
384
|
value: h,
|
|
385
|
-
validated:
|
|
385
|
+
validated: s[e] ? z.error : z.default,
|
|
386
386
|
required: u,
|
|
387
|
-
min: Number(
|
|
387
|
+
min: Number(c),
|
|
388
388
|
max: Number(r.rules?.max),
|
|
389
|
-
onPlus: () =>
|
|
390
|
-
onMinus: () =>
|
|
391
|
-
onChange: (
|
|
392
|
-
const
|
|
393
|
-
|
|
389
|
+
onPlus: () => d(h + 1),
|
|
390
|
+
onMinus: () => d(h - 1),
|
|
391
|
+
onChange: (g) => {
|
|
392
|
+
const y = Number(g.currentTarget.value);
|
|
393
|
+
d(isNaN(y) ? r.defaultValue : y);
|
|
394
394
|
}
|
|
395
395
|
}
|
|
396
396
|
);
|
|
@@ -404,10 +404,10 @@ const ee = ({
|
|
|
404
404
|
innerRef: n,
|
|
405
405
|
...r
|
|
406
406
|
}) => {
|
|
407
|
-
const { t: a } =
|
|
408
|
-
return /* @__PURE__ */
|
|
409
|
-
/* @__PURE__ */ t(
|
|
410
|
-
|
|
407
|
+
const { t: a } = q(), [l, i] = A(!0);
|
|
408
|
+
return /* @__PURE__ */ C(we, { children: [
|
|
409
|
+
/* @__PURE__ */ t(Be, { isFill: !0, children: /* @__PURE__ */ t(
|
|
410
|
+
xe,
|
|
411
411
|
{
|
|
412
412
|
...r,
|
|
413
413
|
type: l ? "password" : "text",
|
|
@@ -415,7 +415,7 @@ const ee = ({
|
|
|
415
415
|
}
|
|
416
416
|
) }),
|
|
417
417
|
e && /* @__PURE__ */ t(
|
|
418
|
-
|
|
418
|
+
V,
|
|
419
419
|
{
|
|
420
420
|
variant: "control",
|
|
421
421
|
"aria-label": a("showPassword"),
|
|
@@ -424,37 +424,37 @@ const ee = ({
|
|
|
424
424
|
}
|
|
425
425
|
)
|
|
426
426
|
] });
|
|
427
|
-
},
|
|
427
|
+
}, $t = qn(
|
|
428
428
|
(e, n) => /* @__PURE__ */ t(Vr, { ...e, innerRef: n })
|
|
429
429
|
);
|
|
430
|
-
|
|
430
|
+
$t.displayName = "PasswordInput";
|
|
431
431
|
const Ha = (e) => {
|
|
432
|
-
const { labelIcon: n, ...r } = e, a = !!
|
|
432
|
+
const { labelIcon: n, ...r } = e, a = !!he(e.rules?.required), l = e.defaultValue ?? "", { field: i, fieldState: s } = Qe({
|
|
433
433
|
...e,
|
|
434
434
|
defaultValue: l
|
|
435
435
|
});
|
|
436
|
-
return /* @__PURE__ */
|
|
437
|
-
|
|
436
|
+
return /* @__PURE__ */ C(
|
|
437
|
+
te,
|
|
438
438
|
{
|
|
439
439
|
name: e.name,
|
|
440
440
|
label: e.label,
|
|
441
441
|
labelIcon: n,
|
|
442
442
|
isRequired: a,
|
|
443
|
-
error:
|
|
443
|
+
error: s.error,
|
|
444
444
|
children: [
|
|
445
445
|
/* @__PURE__ */ t(
|
|
446
|
-
|
|
446
|
+
$t,
|
|
447
447
|
{
|
|
448
448
|
isRequired: a,
|
|
449
449
|
id: e.name,
|
|
450
450
|
"data-testid": e.name,
|
|
451
|
-
validated:
|
|
451
|
+
validated: s.error ? z.error : z.default,
|
|
452
452
|
isDisabled: e.isDisabled,
|
|
453
453
|
...r,
|
|
454
454
|
...i
|
|
455
455
|
}
|
|
456
456
|
),
|
|
457
|
-
e.helperText && /* @__PURE__ */ t(
|
|
457
|
+
e.helperText && /* @__PURE__ */ t(He, { children: /* @__PURE__ */ t(We, { children: /* @__PURE__ */ t(je, { children: e.helperText }) }) })
|
|
458
458
|
]
|
|
459
459
|
}
|
|
460
460
|
);
|
|
@@ -465,215 +465,223 @@ const Ha = (e) => {
|
|
|
465
465
|
options: a,
|
|
466
466
|
controller: l,
|
|
467
467
|
labelIcon: i,
|
|
468
|
-
isDisabled:
|
|
469
|
-
onSelect:
|
|
468
|
+
isDisabled: s,
|
|
469
|
+
onSelect: o,
|
|
470
470
|
...u
|
|
471
471
|
}) => {
|
|
472
472
|
const {
|
|
473
|
-
control:
|
|
473
|
+
control: c,
|
|
474
474
|
formState: { errors: h }
|
|
475
|
-
} =
|
|
475
|
+
} = Ee(), [d, g] = A(!1), y = he(l.rules?.required) === !0;
|
|
476
476
|
return /* @__PURE__ */ t(
|
|
477
|
-
|
|
477
|
+
te,
|
|
478
478
|
{
|
|
479
479
|
name: n,
|
|
480
480
|
label: r,
|
|
481
|
-
isRequired:
|
|
482
|
-
error:
|
|
481
|
+
isRequired: y,
|
|
482
|
+
error: B(h, n),
|
|
483
483
|
labelIcon: i,
|
|
484
484
|
children: /* @__PURE__ */ t(
|
|
485
|
-
|
|
485
|
+
le,
|
|
486
486
|
{
|
|
487
487
|
...l,
|
|
488
488
|
name: n,
|
|
489
|
-
control:
|
|
490
|
-
render: ({ field: { onChange:
|
|
491
|
-
|
|
489
|
+
control: c,
|
|
490
|
+
render: ({ field: { onChange: v, value: x } }) => /* @__PURE__ */ t(
|
|
491
|
+
Se,
|
|
492
492
|
{
|
|
493
493
|
...u,
|
|
494
494
|
variant: "default",
|
|
495
|
-
onClick: () =>
|
|
496
|
-
onOpenChange: () =>
|
|
497
|
-
selected:
|
|
498
|
-
(p) => Array.isArray(
|
|
499
|
-
).map((p) => p.value) :
|
|
495
|
+
onClick: () => g(!d),
|
|
496
|
+
onOpenChange: () => g(!1),
|
|
497
|
+
selected: Z(a) ? a.filter(
|
|
498
|
+
(p) => Array.isArray(x) ? x.includes(p.key) : x === p.key
|
|
499
|
+
).map((p) => p.value) : x,
|
|
500
500
|
toggle: (p) => /* @__PURE__ */ t(
|
|
501
|
-
|
|
501
|
+
ue,
|
|
502
502
|
{
|
|
503
503
|
id: e || n.slice(n.lastIndexOf(".") + 1),
|
|
504
504
|
ref: p,
|
|
505
|
-
onClick: () =>
|
|
506
|
-
isExpanded:
|
|
505
|
+
onClick: () => g(!d),
|
|
506
|
+
isExpanded: d,
|
|
507
507
|
isFullWidth: !0,
|
|
508
|
-
status:
|
|
508
|
+
status: B(h, n) ? ze.danger : void 0,
|
|
509
509
|
"aria-label": r,
|
|
510
|
-
isDisabled:
|
|
511
|
-
children:
|
|
512
|
-
(
|
|
513
|
-
)?.value :
|
|
510
|
+
isDisabled: s,
|
|
511
|
+
children: Z(a) ? a.find(
|
|
512
|
+
(m) => m.key === (Array.isArray(x) ? x[0] : x)
|
|
513
|
+
)?.value : x
|
|
514
514
|
}
|
|
515
515
|
),
|
|
516
|
-
onSelect: (p,
|
|
517
|
-
const
|
|
518
|
-
|
|
516
|
+
onSelect: (p, m) => {
|
|
517
|
+
const E = m?.toString(), T = Array.isArray(x) ? [E] : E;
|
|
518
|
+
o ? o(T, v) : v(T), g(!1);
|
|
519
519
|
},
|
|
520
|
-
isOpen:
|
|
521
|
-
children: /* @__PURE__ */ t(
|
|
520
|
+
isOpen: d,
|
|
521
|
+
children: /* @__PURE__ */ t(Te, { "data-testid": `select-${n}`, children: a.map((p) => /* @__PURE__ */ t(Ge, { value: re(p), children: et(p) ? p : p.value }, re(p))) })
|
|
522
522
|
}
|
|
523
523
|
)
|
|
524
524
|
}
|
|
525
525
|
)
|
|
526
526
|
}
|
|
527
527
|
);
|
|
528
|
-
},
|
|
528
|
+
}, ve = (e) => et(e) ? e : e.value, qr = ({
|
|
529
529
|
id: e,
|
|
530
530
|
name: n,
|
|
531
531
|
label: r,
|
|
532
532
|
options: a,
|
|
533
|
-
|
|
534
|
-
|
|
533
|
+
selectedOptions: l = [],
|
|
534
|
+
controller: i,
|
|
535
|
+
labelIcon: s,
|
|
535
536
|
placeholderText: o,
|
|
536
|
-
onFilter:
|
|
537
|
-
variant:
|
|
538
|
-
...
|
|
537
|
+
onFilter: u,
|
|
538
|
+
variant: c,
|
|
539
|
+
...h
|
|
539
540
|
}) => {
|
|
540
541
|
const {
|
|
541
|
-
control:
|
|
542
|
-
formState: { errors:
|
|
543
|
-
} =
|
|
544
|
-
(
|
|
545
|
-
),
|
|
546
|
-
() =>
|
|
547
|
-
|
|
542
|
+
control: d,
|
|
543
|
+
formState: { errors: g }
|
|
544
|
+
} = Ee(), [y, v] = A(!1), [x, p] = A(""), [m, E] = A(0), [T, k] = A([]), b = J(), S = he(i.rules?.required) === !0, F = c === ce.typeaheadMulti, D = a.filter(
|
|
545
|
+
(f) => ve(f).toLowerCase().startsWith(x.toLowerCase())
|
|
546
|
+
), N = _(
|
|
547
|
+
() => D.map((f, w) => /* @__PURE__ */ t(
|
|
548
|
+
Ge,
|
|
548
549
|
{
|
|
549
|
-
value:
|
|
550
|
-
isFocused:
|
|
551
|
-
children:
|
|
550
|
+
value: re(f),
|
|
551
|
+
isFocused: m === w,
|
|
552
|
+
children: ve(f)
|
|
552
553
|
},
|
|
553
|
-
|
|
554
|
+
re(f)
|
|
554
555
|
)),
|
|
555
|
-
[
|
|
556
|
-
),
|
|
557
|
-
|
|
558
|
-
|
|
556
|
+
[m, D]
|
|
557
|
+
), K = (f, w) => {
|
|
558
|
+
w.value.includes(f) ? (w.onChange(w.value.filter((R) => R !== f)), Z(a) && k(
|
|
559
|
+
T.filter((R) => R.key !== f)
|
|
560
|
+
)) : (w.onChange([...w.value, f]), Z(a) && k([
|
|
561
|
+
...T,
|
|
562
|
+
a.find((R) => R.key === f)
|
|
563
|
+
]));
|
|
564
|
+
}, M = (f, w) => {
|
|
565
|
+
const R = D[m];
|
|
566
|
+
switch (v(!0), f.key) {
|
|
559
567
|
case "Enter": {
|
|
560
|
-
|
|
561
|
-
Array.isArray(A.value) ? [...A.value, X(O)] : X(O)
|
|
562
|
-
), g(!1), y(0);
|
|
568
|
+
f.preventDefault(), p(F ? "" : ve(R)), K(re(R), w), v(!1), E(0);
|
|
563
569
|
break;
|
|
564
570
|
}
|
|
565
571
|
case "Tab":
|
|
566
572
|
case "Escape": {
|
|
567
|
-
|
|
573
|
+
v(!1), w.onChange(void 0);
|
|
568
574
|
break;
|
|
569
575
|
}
|
|
570
576
|
case "Backspace": {
|
|
571
|
-
|
|
577
|
+
c === ce.typeahead && w.onChange("");
|
|
572
578
|
break;
|
|
573
579
|
}
|
|
574
580
|
case "ArrowUp":
|
|
575
581
|
case "ArrowDown": {
|
|
576
|
-
|
|
577
|
-
let
|
|
578
|
-
|
|
582
|
+
f.preventDefault();
|
|
583
|
+
let O = 0;
|
|
584
|
+
f.key === "ArrowUp" && (m === 0 ? O = a.length - 1 : O = m - 1), f.key === "ArrowDown" && (m === a.length - 1 ? O = 0 : O = m + 1), E(O);
|
|
579
585
|
break;
|
|
580
586
|
}
|
|
581
587
|
}
|
|
582
588
|
};
|
|
583
589
|
return /* @__PURE__ */ t(
|
|
584
|
-
|
|
590
|
+
te,
|
|
585
591
|
{
|
|
586
592
|
name: n,
|
|
587
593
|
label: r,
|
|
588
|
-
isRequired:
|
|
589
|
-
error:
|
|
590
|
-
labelIcon:
|
|
594
|
+
isRequired: S,
|
|
595
|
+
error: B(g, n),
|
|
596
|
+
labelIcon: s,
|
|
591
597
|
children: /* @__PURE__ */ t(
|
|
592
|
-
|
|
598
|
+
le,
|
|
593
599
|
{
|
|
594
|
-
...
|
|
600
|
+
...i,
|
|
595
601
|
name: n,
|
|
596
|
-
control:
|
|
597
|
-
render: ({ field:
|
|
598
|
-
|
|
602
|
+
control: d,
|
|
603
|
+
render: ({ field: f }) => /* @__PURE__ */ t(
|
|
604
|
+
Se,
|
|
599
605
|
{
|
|
600
|
-
...
|
|
601
|
-
onOpenChange: () =>
|
|
602
|
-
selected:
|
|
603
|
-
(
|
|
604
|
-
).map((
|
|
606
|
+
...h,
|
|
607
|
+
onOpenChange: () => v(!1),
|
|
608
|
+
selected: Z(a) ? a.filter(
|
|
609
|
+
(w) => Array.isArray(f.value) ? f.value.includes(w.key) : f.value === w.key
|
|
610
|
+
).map((w) => w.value) : f.value,
|
|
605
611
|
shouldFocusFirstItemOnOpen: !1,
|
|
606
|
-
toggle: (
|
|
607
|
-
|
|
612
|
+
toggle: (w) => /* @__PURE__ */ t(
|
|
613
|
+
ue,
|
|
608
614
|
{
|
|
609
|
-
ref:
|
|
615
|
+
ref: w,
|
|
610
616
|
id: e || n.slice(n.lastIndexOf(".") + 1),
|
|
611
617
|
variant: "typeahead",
|
|
612
618
|
onClick: () => {
|
|
613
|
-
|
|
619
|
+
v(!y), b.current?.focus();
|
|
614
620
|
},
|
|
615
|
-
isExpanded:
|
|
621
|
+
isExpanded: y,
|
|
616
622
|
isFullWidth: !0,
|
|
617
|
-
status:
|
|
618
|
-
children: /* @__PURE__ */
|
|
623
|
+
status: B(g, n) ? ze.danger : void 0,
|
|
624
|
+
children: /* @__PURE__ */ C(wt, { isPlain: !0, children: [
|
|
619
625
|
/* @__PURE__ */ t(
|
|
620
|
-
|
|
626
|
+
xt,
|
|
621
627
|
{
|
|
622
628
|
placeholder: o,
|
|
623
|
-
value:
|
|
624
|
-
(
|
|
625
|
-
)?.value :
|
|
626
|
-
onClick: () =>
|
|
627
|
-
onChange: (
|
|
628
|
-
|
|
629
|
+
value: c === ce.typeahead && f.value ? Z(a) ? a.find(
|
|
630
|
+
(R) => R.key === (Array.isArray(f.value) ? f.value[0] : f.value)
|
|
631
|
+
)?.value : f.value : x,
|
|
632
|
+
onClick: () => v(!y),
|
|
633
|
+
onChange: (R, O) => {
|
|
634
|
+
p(O), u?.(O);
|
|
629
635
|
},
|
|
630
|
-
onKeyDown: (
|
|
636
|
+
onKeyDown: (R) => M(R, f),
|
|
631
637
|
autoComplete: "off",
|
|
632
|
-
innerRef:
|
|
638
|
+
innerRef: b,
|
|
633
639
|
role: "combobox",
|
|
634
|
-
isExpanded:
|
|
640
|
+
isExpanded: y,
|
|
635
641
|
"aria-controls": "select-typeahead-listbox",
|
|
636
|
-
children:
|
|
637
|
-
(
|
|
638
|
-
|
|
642
|
+
children: c === ce.typeaheadMulti && Array.isArray(f.value) && /* @__PURE__ */ t(Je, { "aria-label": "Current selections", children: f.value.map(
|
|
643
|
+
(R, O) => /* @__PURE__ */ t(
|
|
644
|
+
Ye,
|
|
639
645
|
{
|
|
640
|
-
onClick: (
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
(
|
|
646
|
+
onClick: (ie) => {
|
|
647
|
+
ie.stopPropagation(), f.onChange(
|
|
648
|
+
f.value.filter(
|
|
649
|
+
($) => $ !== re(R)
|
|
644
650
|
)
|
|
645
651
|
);
|
|
646
652
|
},
|
|
647
|
-
children:
|
|
653
|
+
children: Z(a) ? [
|
|
654
|
+
...a,
|
|
655
|
+
...T,
|
|
656
|
+
...l
|
|
657
|
+
].find((ie) => R === ie.key)?.value : ve(R)
|
|
648
658
|
},
|
|
649
|
-
|
|
659
|
+
O
|
|
650
660
|
)
|
|
651
661
|
) })
|
|
652
662
|
}
|
|
653
663
|
),
|
|
654
|
-
/* @__PURE__ */ t(
|
|
655
|
-
|
|
664
|
+
/* @__PURE__ */ t(St, { children: (!!x || f.value) && /* @__PURE__ */ t(
|
|
665
|
+
V,
|
|
656
666
|
{
|
|
657
667
|
variant: "plain",
|
|
658
668
|
onClick: () => {
|
|
659
|
-
|
|
669
|
+
p(""), f.onChange(F ? [] : ""), b?.current?.focus();
|
|
660
670
|
},
|
|
661
671
|
"aria-label": "Clear input value",
|
|
662
|
-
children: /* @__PURE__ */ t(
|
|
672
|
+
children: /* @__PURE__ */ t(Pt, { "aria-hidden": !0 })
|
|
663
673
|
}
|
|
664
674
|
) })
|
|
665
675
|
] })
|
|
666
676
|
}
|
|
667
677
|
),
|
|
668
|
-
onSelect: (
|
|
669
|
-
|
|
670
|
-
const
|
|
671
|
-
|
|
672
|
-
m.value.filter((D) => D !== x)
|
|
673
|
-
) : m.onChange([...m.value, x]) : (m.onChange(Array.isArray(m.value) ? [x] : x), g(!1));
|
|
678
|
+
onSelect: (w, R) => {
|
|
679
|
+
w?.stopPropagation();
|
|
680
|
+
const O = R?.toString();
|
|
681
|
+
F && Array.isArray(f.value) ? (p(""), K(O || "", f)) : (f.onChange(Array.isArray(f.value) ? [O] : O), v(!1));
|
|
674
682
|
},
|
|
675
|
-
isOpen:
|
|
676
|
-
children: /* @__PURE__ */ t(
|
|
683
|
+
isOpen: y,
|
|
684
|
+
children: /* @__PURE__ */ t(Te, { children: N })
|
|
677
685
|
}
|
|
678
686
|
)
|
|
679
687
|
}
|
|
@@ -681,14 +689,14 @@ const Ha = (e) => {
|
|
|
681
689
|
}
|
|
682
690
|
);
|
|
683
691
|
};
|
|
684
|
-
var
|
|
685
|
-
const
|
|
692
|
+
var ce = /* @__PURE__ */ ((e) => (e.single = "single", e.typeahead = "typeahead", e.typeaheadMulti = "typeaheadMulti", e))(ce || {});
|
|
693
|
+
const Z = (e) => typeof e[0] != "string", et = (e) => typeof e == "string", re = (e) => et(e) ? e : e.key, $r = ({
|
|
686
694
|
variant: e = "single",
|
|
687
695
|
...n
|
|
688
|
-
}) => e === "single" ? /* @__PURE__ */ t(_r, { ...n }) : /* @__PURE__ */ t(qr, { ...n, variant: e }),
|
|
689
|
-
const l = n || r, i =
|
|
690
|
-
return e(
|
|
691
|
-
},
|
|
696
|
+
}) => e === "single" ? /* @__PURE__ */ t(_r, { ...n }) : /* @__PURE__ */ t(qr, { ...n, variant: e }), qe = (e) => e?.includes("${"), $e = (e) => e.substring(2, e.length - 1), ee = (e, n, r, a) => {
|
|
697
|
+
const l = n || r, i = qe(l) ? $e(l) : l, s = a ? `${a}.${i}` : i;
|
|
698
|
+
return e(s || "");
|
|
699
|
+
}, Ue = (e, n) => ee(e, n.displayName, n.name), Ur = ["username", "firstName", "lastName", "email"], Ut = (e) => e && Ur.includes(e), Y = (e) => `${Ut(e) ? "" : "attributes."}${e?.replaceAll(
|
|
692
700
|
".",
|
|
693
701
|
"🍺"
|
|
694
702
|
)}`, Wa = (e) => e.replaceAll(".", "🍺"), Kr = (e) => e.replaceAll("🍺", ".");
|
|
@@ -696,11 +704,11 @@ function ja(e, n, r) {
|
|
|
696
704
|
(e.responseData.errors !== void 0 ? e.responseData.errors : [e.responseData]).forEach((a) => {
|
|
697
705
|
const l = Object.assign(
|
|
698
706
|
{},
|
|
699
|
-
a.params?.map((i) =>
|
|
707
|
+
a.params?.map((i) => qe(i?.toString()) ? r($e(i)) : i)
|
|
700
708
|
);
|
|
701
|
-
n(
|
|
709
|
+
n(Y(a.field), {
|
|
702
710
|
message: r(
|
|
703
|
-
|
|
711
|
+
qe(a.errorMessage) ? $e(a.errorMessage) : a.errorMessage,
|
|
704
712
|
{
|
|
705
713
|
/* eslint-disable @typescript-eslint/no-misused-spread */
|
|
706
714
|
...l,
|
|
@@ -711,7 +719,7 @@ function ja(e, n, r) {
|
|
|
711
719
|
});
|
|
712
720
|
});
|
|
713
721
|
}
|
|
714
|
-
function
|
|
722
|
+
function Ae({
|
|
715
723
|
required: e
|
|
716
724
|
}) {
|
|
717
725
|
return e;
|
|
@@ -720,9 +728,9 @@ function Ga(e) {
|
|
|
720
728
|
if (typeof e != "object" || e === null || !("responseData" in e))
|
|
721
729
|
return !1;
|
|
722
730
|
const { responseData: n } = e;
|
|
723
|
-
return
|
|
731
|
+
return ht(n) ? !0 : typeof n != "object" || n === null || !("errors" in n) || !Array.isArray(n.errors) ? !1 : n.errors.every(ht);
|
|
724
732
|
}
|
|
725
|
-
function
|
|
733
|
+
function ht(e) {
|
|
726
734
|
return !(typeof e != "object" || e === null || !("field" in e) || typeof e.field != "string" || !("errorMessage" in e) || typeof e.errorMessage != "string");
|
|
727
735
|
}
|
|
728
736
|
const za = ({
|
|
@@ -732,9 +740,9 @@ const za = ({
|
|
|
732
740
|
labelIcon: a,
|
|
733
741
|
...l
|
|
734
742
|
}) => {
|
|
735
|
-
const
|
|
743
|
+
const s = r ?? (n ? "false" : !1), { control: o } = Ee();
|
|
736
744
|
return /* @__PURE__ */ t(
|
|
737
|
-
|
|
745
|
+
te,
|
|
738
746
|
{
|
|
739
747
|
hasNoPaddingTop: !0,
|
|
740
748
|
name: l.name,
|
|
@@ -742,22 +750,22 @@ const za = ({
|
|
|
742
750
|
label: l.label,
|
|
743
751
|
labelIcon: a,
|
|
744
752
|
children: /* @__PURE__ */ t(
|
|
745
|
-
|
|
753
|
+
le,
|
|
746
754
|
{
|
|
747
|
-
control:
|
|
755
|
+
control: o,
|
|
748
756
|
name: l.name,
|
|
749
|
-
defaultValue:
|
|
750
|
-
render: ({ field: { onChange: u, value:
|
|
757
|
+
defaultValue: s,
|
|
758
|
+
render: ({ field: { onChange: u, value: c } }) => /* @__PURE__ */ t(
|
|
751
759
|
cn,
|
|
752
760
|
{
|
|
753
761
|
...l,
|
|
754
762
|
id: l.name,
|
|
755
763
|
"data-testid": Kr(l.name),
|
|
756
764
|
label: e,
|
|
757
|
-
isChecked: n ?
|
|
758
|
-
onChange: (h,
|
|
759
|
-
const
|
|
760
|
-
l.onChange?.(h,
|
|
765
|
+
isChecked: n ? c === "true" : c,
|
|
766
|
+
onChange: (h, d) => {
|
|
767
|
+
const g = n ? d.toString() : d;
|
|
768
|
+
l.onChange?.(h, d), u(g);
|
|
761
769
|
}
|
|
762
770
|
}
|
|
763
771
|
)
|
|
@@ -766,12 +774,12 @@ const za = ({
|
|
|
766
774
|
}
|
|
767
775
|
);
|
|
768
776
|
}, Ja = (e) => {
|
|
769
|
-
const n = !!e.rules?.required, r = e.defaultValue ?? "", { field: a, fieldState: l } =
|
|
777
|
+
const n = !!e.rules?.required, r = e.defaultValue ?? "", { field: a, fieldState: l } = Qe({
|
|
770
778
|
...e,
|
|
771
779
|
defaultValue: r
|
|
772
780
|
});
|
|
773
781
|
return /* @__PURE__ */ t(
|
|
774
|
-
|
|
782
|
+
te,
|
|
775
783
|
{
|
|
776
784
|
isRequired: n,
|
|
777
785
|
label: e.label,
|
|
@@ -784,7 +792,7 @@ const za = ({
|
|
|
784
792
|
isRequired: n,
|
|
785
793
|
id: e.name,
|
|
786
794
|
"data-testid": e.name,
|
|
787
|
-
validated: l.error ?
|
|
795
|
+
validated: l.error ? z.error : z.default,
|
|
788
796
|
isDisabled: e.isDisabled,
|
|
789
797
|
...e,
|
|
790
798
|
...a
|
|
@@ -793,38 +801,38 @@ const za = ({
|
|
|
793
801
|
}
|
|
794
802
|
);
|
|
795
803
|
}, Ya = (e) => {
|
|
796
|
-
const { labelIcon: n, helperText: r, ...a } = e, l = !!
|
|
804
|
+
const { labelIcon: n, helperText: r, ...a } = e, l = !!he(e.rules?.required), i = e.defaultValue ?? "", { field: s, fieldState: o } = Qe({
|
|
797
805
|
...e,
|
|
798
806
|
defaultValue: i
|
|
799
807
|
});
|
|
800
|
-
return /* @__PURE__ */
|
|
801
|
-
|
|
808
|
+
return /* @__PURE__ */ C(
|
|
809
|
+
te,
|
|
802
810
|
{
|
|
803
811
|
name: e.name,
|
|
804
812
|
label: e.label,
|
|
805
813
|
labelIcon: n,
|
|
806
814
|
isRequired: l,
|
|
807
|
-
error:
|
|
815
|
+
error: o.error,
|
|
808
816
|
children: [
|
|
809
817
|
/* @__PURE__ */ t(
|
|
810
|
-
|
|
818
|
+
xe,
|
|
811
819
|
{
|
|
812
820
|
isRequired: l,
|
|
813
821
|
id: e.name,
|
|
814
822
|
"data-testid": e["data-testid"] || e.name,
|
|
815
|
-
validated:
|
|
823
|
+
validated: o.error ? z.error : z.default,
|
|
816
824
|
isDisabled: e.isDisabled,
|
|
817
825
|
...a,
|
|
818
|
-
...
|
|
826
|
+
...s
|
|
819
827
|
}
|
|
820
828
|
),
|
|
821
|
-
r && /* @__PURE__ */ t(
|
|
829
|
+
r && /* @__PURE__ */ t(He, { children: /* @__PURE__ */ t(We, { children: /* @__PURE__ */ t(je, { children: r }) }) })
|
|
822
830
|
]
|
|
823
831
|
}
|
|
824
832
|
);
|
|
825
833
|
}, Hr = Tt, Qa = ({ icon: e }) => {
|
|
826
834
|
const n = Wr(e);
|
|
827
|
-
return /* @__PURE__ */ t(
|
|
835
|
+
return /* @__PURE__ */ t(Ne, { size: "lg", children: /* @__PURE__ */ t(n, { alt: e }) });
|
|
828
836
|
};
|
|
829
837
|
function Wr(e) {
|
|
830
838
|
switch (e) {
|
|
@@ -859,7 +867,7 @@ function Wr(e) {
|
|
|
859
867
|
}
|
|
860
868
|
const jr = "_title_180i0_2", Gr = {
|
|
861
869
|
title: jr
|
|
862
|
-
},
|
|
870
|
+
}, Kt = ({
|
|
863
871
|
id: e,
|
|
864
872
|
title: n,
|
|
865
873
|
headingLevel: r = "h1",
|
|
@@ -882,44 +890,44 @@ const jr = "_title_180i0_2", Gr = {
|
|
|
882
890
|
scrollId: r,
|
|
883
891
|
className: a
|
|
884
892
|
}) => {
|
|
885
|
-
const l =
|
|
886
|
-
return /* @__PURE__ */
|
|
887
|
-
/* @__PURE__ */ t(hn, { className: "kc-form-panel__header", children: /* @__PURE__ */ t(pn, { tabIndex: 0, children: /* @__PURE__ */ t(
|
|
893
|
+
const l = Rt();
|
|
894
|
+
return /* @__PURE__ */ C(un, { id: l, className: a, isFlat: !0, children: [
|
|
895
|
+
/* @__PURE__ */ t(hn, { className: "kc-form-panel__header", children: /* @__PURE__ */ t(pn, { tabIndex: 0, children: /* @__PURE__ */ t(Kt, { id: r, title: e }) }) }),
|
|
888
896
|
/* @__PURE__ */ t(mn, { className: "kc-form-panel__body", children: n })
|
|
889
897
|
] });
|
|
890
898
|
}, Jr = (e) => {
|
|
891
899
|
const { title: n, children: r, scrollId: a, ...l } = e;
|
|
892
|
-
return /* @__PURE__ */ t("section", { ...l, style: { marginTop: "var(--pf-v5-global--spacer--lg)" }, children: /* @__PURE__ */
|
|
893
|
-
/* @__PURE__ */ t(
|
|
900
|
+
return /* @__PURE__ */ t("section", { ...l, style: { marginTop: "var(--pf-v5-global--spacer--lg)" }, children: /* @__PURE__ */ C(W, { children: [
|
|
901
|
+
/* @__PURE__ */ t(Kt, { id: a, title: n }),
|
|
894
902
|
r
|
|
895
903
|
] }) });
|
|
896
|
-
}, Yr = "_panel_1cdve_1", Qr = "_sticky_1cdve_5",
|
|
904
|
+
}, Yr = "_panel_1cdve_1", Qr = "_sticky_1cdve_5", pt = {
|
|
897
905
|
panel: Yr,
|
|
898
906
|
sticky: Qr
|
|
899
|
-
}, Xr = "kc-main-content-page-container",
|
|
907
|
+
}, Xr = "kc-main-content-page-container", mt = (e) => e.replace(/\s+/g, "-"), Zr = ({
|
|
900
908
|
label: e,
|
|
901
909
|
sections: n,
|
|
902
910
|
borders: r = !1,
|
|
903
911
|
...a
|
|
904
912
|
}) => {
|
|
905
|
-
const l =
|
|
913
|
+
const l = _(
|
|
906
914
|
() => n.filter(({ isHidden: i }) => !i),
|
|
907
915
|
[n]
|
|
908
916
|
);
|
|
909
|
-
return /* @__PURE__ */
|
|
910
|
-
/* @__PURE__ */ t(
|
|
911
|
-
const
|
|
912
|
-
return /* @__PURE__ */ t(
|
|
917
|
+
return /* @__PURE__ */ C(fn, { hasGutter: !0, ...a, children: [
|
|
918
|
+
/* @__PURE__ */ t(st, { md: 8, sm: 12, children: l.map(({ title: i, panel: s }) => {
|
|
919
|
+
const o = mt(i.toLowerCase());
|
|
920
|
+
return /* @__PURE__ */ t(Ot, { children: r ? /* @__PURE__ */ t(
|
|
913
921
|
zr,
|
|
914
922
|
{
|
|
915
|
-
scrollId:
|
|
923
|
+
scrollId: o,
|
|
916
924
|
title: i,
|
|
917
|
-
className:
|
|
918
|
-
children:
|
|
925
|
+
className: pt.panel,
|
|
926
|
+
children: s
|
|
919
927
|
}
|
|
920
|
-
) : /* @__PURE__ */ t(Jr, { scrollId:
|
|
928
|
+
) : /* @__PURE__ */ t(Jr, { scrollId: o, title: i, children: s }) }, i);
|
|
921
929
|
}) }),
|
|
922
|
-
/* @__PURE__ */ t(
|
|
930
|
+
/* @__PURE__ */ t(st, { md: 4, sm: 12, order: { default: "-1", md: "1" }, children: /* @__PURE__ */ t(gn, { className: pt.sticky, children: /* @__PURE__ */ t(
|
|
923
931
|
yn,
|
|
924
932
|
{
|
|
925
933
|
isVertical: !0,
|
|
@@ -927,14 +935,14 @@ const jr = "_title_180i0_2", Gr = {
|
|
|
927
935
|
label: e,
|
|
928
936
|
offset: 100,
|
|
929
937
|
children: l.map(({ title: i }) => {
|
|
930
|
-
const
|
|
938
|
+
const s = mt(i.toLowerCase());
|
|
931
939
|
return (
|
|
932
940
|
// note that JumpLinks currently does not work with spaces in the href
|
|
933
941
|
/* @__PURE__ */ t(
|
|
934
|
-
|
|
942
|
+
bn,
|
|
935
943
|
{
|
|
936
|
-
href: `#${
|
|
937
|
-
"data-testid": `jump-link-${
|
|
944
|
+
href: `#${s}`,
|
|
945
|
+
"data-testid": `jump-link-${s}`,
|
|
938
946
|
children: i
|
|
939
947
|
},
|
|
940
948
|
i
|
|
@@ -952,7 +960,7 @@ const jr = "_title_180i0_2", Gr = {
|
|
|
952
960
|
children: l,
|
|
953
961
|
...i
|
|
954
962
|
}) => /* @__PURE__ */ t(
|
|
955
|
-
|
|
963
|
+
V,
|
|
956
964
|
{
|
|
957
965
|
variant: "primary",
|
|
958
966
|
isDisabled: e && !ea(e, a, r) || n,
|
|
@@ -972,11 +980,11 @@ const jr = "_title_180i0_2", Gr = {
|
|
|
972
980
|
supportedLocales: r,
|
|
973
981
|
currentLocale: a
|
|
974
982
|
}) => {
|
|
975
|
-
const l =
|
|
983
|
+
const l = _(
|
|
976
984
|
() => r.map((i) => ({
|
|
977
985
|
key: i,
|
|
978
986
|
value: e(`locale_${i}`, ta(i) ?? i)
|
|
979
|
-
})).sort((i,
|
|
987
|
+
})).sort((i, s) => i.value.localeCompare(s.value, a)),
|
|
980
988
|
[r, a, e]
|
|
981
989
|
);
|
|
982
990
|
return l.length ? /* @__PURE__ */ t(ur, { ...n, children: /* @__PURE__ */ t(
|
|
@@ -990,33 +998,33 @@ const jr = "_title_180i0_2", Gr = {
|
|
|
990
998
|
variant: l.length >= 10 ? "typeahead" : "single"
|
|
991
999
|
}
|
|
992
1000
|
) }) : null;
|
|
993
|
-
},
|
|
1001
|
+
}, pe = ({
|
|
994
1002
|
t: e,
|
|
995
1003
|
form: n,
|
|
996
1004
|
attribute: r,
|
|
997
1005
|
renderer: a,
|
|
998
1006
|
children: l
|
|
999
1007
|
}) => {
|
|
1000
|
-
const i =
|
|
1008
|
+
const i = ee(
|
|
1001
1009
|
e,
|
|
1002
1010
|
r.annotations?.inputHelperTextBefore
|
|
1003
1011
|
), {
|
|
1004
|
-
formState: { errors:
|
|
1005
|
-
} = n,
|
|
1006
|
-
return /* @__PURE__ */
|
|
1007
|
-
|
|
1012
|
+
formState: { errors: s }
|
|
1013
|
+
} = n, o = a?.(r), u = B(s, Y(r.name));
|
|
1014
|
+
return /* @__PURE__ */ C(
|
|
1015
|
+
It,
|
|
1008
1016
|
{
|
|
1009
|
-
label:
|
|
1017
|
+
label: Ue(e, r) || "",
|
|
1010
1018
|
fieldId: r.name,
|
|
1011
|
-
isRequired:
|
|
1012
|
-
labelIcon: i ? /* @__PURE__ */ t(
|
|
1019
|
+
isRequired: Ae(r),
|
|
1020
|
+
labelIcon: i ? /* @__PURE__ */ t(qt, { helpText: i, fieldLabelId: r.name }) : void 0,
|
|
1013
1021
|
children: [
|
|
1014
|
-
|
|
1022
|
+
o ? /* @__PURE__ */ C(we, { children: [
|
|
1015
1023
|
l,
|
|
1016
|
-
|
|
1024
|
+
o
|
|
1017
1025
|
] }) : l,
|
|
1018
1026
|
u && /* @__PURE__ */ t(
|
|
1019
|
-
|
|
1027
|
+
_t,
|
|
1020
1028
|
{
|
|
1021
1029
|
"data-testid": `${r.name}-helper`,
|
|
1022
1030
|
message: u.message
|
|
@@ -1032,15 +1040,15 @@ const jr = "_title_180i0_2", Gr = {
|
|
|
1032
1040
|
attribute: r,
|
|
1033
1041
|
renderer: a,
|
|
1034
1042
|
...l
|
|
1035
|
-
}) => /* @__PURE__ */ t(
|
|
1043
|
+
}) => /* @__PURE__ */ t(pe, { t: e, form: n, attribute: r, renderer: a, children: /* @__PURE__ */ t(
|
|
1036
1044
|
aa,
|
|
1037
1045
|
{
|
|
1038
1046
|
t: e,
|
|
1039
1047
|
form: n,
|
|
1040
|
-
"aria-label":
|
|
1041
|
-
name:
|
|
1048
|
+
"aria-label": Ue(e, r),
|
|
1049
|
+
name: Y(r.name),
|
|
1042
1050
|
addButtonLabel: e("addMultivaluedLabel", {
|
|
1043
|
-
fieldLabel:
|
|
1051
|
+
fieldLabel: Ue(e, r)
|
|
1044
1052
|
}),
|
|
1045
1053
|
...l
|
|
1046
1054
|
}
|
|
@@ -1051,97 +1059,97 @@ const jr = "_title_180i0_2", Gr = {
|
|
|
1051
1059
|
form: a,
|
|
1052
1060
|
addButtonLabel: l,
|
|
1053
1061
|
isDisabled: i = !1,
|
|
1054
|
-
defaultValue:
|
|
1055
|
-
id:
|
|
1062
|
+
defaultValue: s,
|
|
1063
|
+
id: o,
|
|
1056
1064
|
...u
|
|
1057
1065
|
}) => {
|
|
1058
|
-
const { register:
|
|
1066
|
+
const { register: c, setValue: h, control: d } = a, g = hr({
|
|
1059
1067
|
name: n,
|
|
1060
|
-
control:
|
|
1061
|
-
defaultValue:
|
|
1062
|
-
}),
|
|
1063
|
-
|
|
1064
|
-
},
|
|
1065
|
-
|
|
1066
|
-
}, p = (
|
|
1067
|
-
|
|
1068
|
-
},
|
|
1069
|
-
const k =
|
|
1068
|
+
control: d,
|
|
1069
|
+
defaultValue: s || ""
|
|
1070
|
+
}), y = _(() => Array.isArray(g) && g.length !== 0 ? g : s || [""], [g]), v = (T) => {
|
|
1071
|
+
m([...y.slice(0, T), ...y.slice(T + 1)]);
|
|
1072
|
+
}, x = () => {
|
|
1073
|
+
m([...y, ""]);
|
|
1074
|
+
}, p = (T, k) => {
|
|
1075
|
+
m([...y.slice(0, T), k, ...y.slice(T + 1)]);
|
|
1076
|
+
}, m = (T) => {
|
|
1077
|
+
const k = T.flatMap((b) => b);
|
|
1070
1078
|
h(n, k, {
|
|
1071
1079
|
shouldDirty: !0
|
|
1072
1080
|
});
|
|
1073
|
-
},
|
|
1074
|
-
return
|
|
1075
|
-
|
|
1076
|
-
}, [
|
|
1077
|
-
/* @__PURE__ */
|
|
1078
|
-
/* @__PURE__ */ t(
|
|
1079
|
-
|
|
1081
|
+
}, E = r.startsWith("html") ? r.substring(6) : "text";
|
|
1082
|
+
return ae(() => {
|
|
1083
|
+
c(n);
|
|
1084
|
+
}, [c]), /* @__PURE__ */ t("div", { id: o, children: y.map((T, k) => /* @__PURE__ */ C(Ot, { children: [
|
|
1085
|
+
/* @__PURE__ */ C(we, { children: [
|
|
1086
|
+
/* @__PURE__ */ t(Be, { isFill: !0, children: /* @__PURE__ */ t(
|
|
1087
|
+
xe,
|
|
1080
1088
|
{
|
|
1081
1089
|
"data-testid": n + k,
|
|
1082
|
-
onChange: (
|
|
1090
|
+
onChange: (b, S) => p(k, S),
|
|
1083
1091
|
name: `${n}.${k}.value`,
|
|
1084
|
-
value:
|
|
1092
|
+
value: T,
|
|
1085
1093
|
isDisabled: i,
|
|
1086
|
-
type:
|
|
1094
|
+
type: E,
|
|
1087
1095
|
...u
|
|
1088
1096
|
}
|
|
1089
1097
|
) }),
|
|
1090
|
-
/* @__PURE__ */ t(
|
|
1091
|
-
|
|
1098
|
+
/* @__PURE__ */ t(Be, { children: /* @__PURE__ */ t(
|
|
1099
|
+
V,
|
|
1092
1100
|
{
|
|
1093
1101
|
"data-testid": "remove" + k,
|
|
1094
|
-
variant:
|
|
1095
|
-
onClick: () =>
|
|
1102
|
+
variant: ke.link,
|
|
1103
|
+
onClick: () => v(k),
|
|
1096
1104
|
tabIndex: -1,
|
|
1097
1105
|
"aria-label": e("remove"),
|
|
1098
|
-
isDisabled:
|
|
1106
|
+
isDisabled: y.length === 1 || i,
|
|
1099
1107
|
children: /* @__PURE__ */ t(ir, {})
|
|
1100
1108
|
}
|
|
1101
1109
|
) })
|
|
1102
1110
|
] }),
|
|
1103
|
-
k ===
|
|
1104
|
-
|
|
1111
|
+
k === y.length - 1 && /* @__PURE__ */ C(
|
|
1112
|
+
V,
|
|
1105
1113
|
{
|
|
1106
|
-
variant:
|
|
1107
|
-
onClick:
|
|
1114
|
+
variant: ke.link,
|
|
1115
|
+
onClick: x,
|
|
1108
1116
|
tabIndex: -1,
|
|
1109
1117
|
"aria-label": e("add"),
|
|
1110
1118
|
"data-testid": "addValue",
|
|
1111
|
-
isDisabled: !
|
|
1119
|
+
isDisabled: !T || i,
|
|
1112
1120
|
children: [
|
|
1113
|
-
/* @__PURE__ */ t(
|
|
1121
|
+
/* @__PURE__ */ t(Mt, {}),
|
|
1114
1122
|
" ",
|
|
1115
1123
|
e(l || "add")
|
|
1116
1124
|
]
|
|
1117
1125
|
}
|
|
1118
1126
|
)
|
|
1119
1127
|
] }, k)) });
|
|
1120
|
-
},
|
|
1121
|
-
const { form: n, inputType: r, attribute: a } = e, l =
|
|
1122
|
-
return /* @__PURE__ */ t(
|
|
1123
|
-
|
|
1128
|
+
}, ft = (e) => {
|
|
1129
|
+
const { form: n, inputType: r, attribute: a } = e, l = Ae(a), i = r.startsWith("multiselect"), s = i ? vn : Cn, o = a.validators?.options?.options || [], u = a.annotations?.inputOptionLabels || {}, c = a.annotations?.inputOptionLabelsI18nPrefix;
|
|
1130
|
+
return /* @__PURE__ */ t(pe, { ...e, children: /* @__PURE__ */ t(
|
|
1131
|
+
le,
|
|
1124
1132
|
{
|
|
1125
|
-
name:
|
|
1133
|
+
name: Y(a.name),
|
|
1126
1134
|
control: n.control,
|
|
1127
1135
|
defaultValue: "",
|
|
1128
|
-
render: ({ field: h }) => /* @__PURE__ */ t(
|
|
1129
|
-
|
|
1136
|
+
render: ({ field: h }) => /* @__PURE__ */ t(W, { children: o.map((d) => /* @__PURE__ */ t(
|
|
1137
|
+
s,
|
|
1130
1138
|
{
|
|
1131
|
-
id:
|
|
1132
|
-
"data-testid":
|
|
1133
|
-
label:
|
|
1134
|
-
value:
|
|
1135
|
-
isChecked: h.value.includes(
|
|
1139
|
+
id: d,
|
|
1140
|
+
"data-testid": d,
|
|
1141
|
+
label: ee(e.t, u[d], d, c),
|
|
1142
|
+
value: d,
|
|
1143
|
+
isChecked: h.value.includes(d),
|
|
1136
1144
|
onChange: () => {
|
|
1137
|
-
i ? h.value.includes(
|
|
1138
|
-
h.value.filter((
|
|
1139
|
-
) : h.onChange([...h.value,
|
|
1145
|
+
i ? h.value.includes(d) ? h.onChange(
|
|
1146
|
+
h.value.filter((g) => g !== d)
|
|
1147
|
+
) : h.onChange([...h.value, d]) : h.onChange([d]);
|
|
1140
1148
|
},
|
|
1141
1149
|
readOnly: a.readOnly,
|
|
1142
1150
|
isRequired: l
|
|
1143
1151
|
},
|
|
1144
|
-
|
|
1152
|
+
d
|
|
1145
1153
|
)) })
|
|
1146
1154
|
}
|
|
1147
1155
|
) });
|
|
@@ -1152,57 +1160,57 @@ const jr = "_title_180i0_2", Gr = {
|
|
|
1152
1160
|
selections: a,
|
|
1153
1161
|
isOpen: l,
|
|
1154
1162
|
menuAppendTo: i,
|
|
1155
|
-
direction:
|
|
1156
|
-
width:
|
|
1163
|
+
direction: s,
|
|
1164
|
+
width: o,
|
|
1157
1165
|
maxHeight: u,
|
|
1158
|
-
toggleIcon:
|
|
1166
|
+
toggleIcon: c,
|
|
1159
1167
|
className: h,
|
|
1160
|
-
isDisabled:
|
|
1161
|
-
children:
|
|
1162
|
-
...
|
|
1168
|
+
isDisabled: d,
|
|
1169
|
+
children: g,
|
|
1170
|
+
...y
|
|
1163
1171
|
}) => {
|
|
1164
|
-
const [
|
|
1165
|
-
|
|
1166
|
-
},
|
|
1167
|
-
|
|
1172
|
+
const [v, x] = A(!1), p = J(), m = () => {
|
|
1173
|
+
x(!v), n(!v);
|
|
1174
|
+
}, E = () => i === "parent" && p.current?.parentElement || "inline", T = Dt.toArray(
|
|
1175
|
+
g
|
|
1168
1176
|
);
|
|
1169
1177
|
return /* @__PURE__ */ t(
|
|
1170
|
-
|
|
1178
|
+
Se,
|
|
1171
1179
|
{
|
|
1172
1180
|
ref: p,
|
|
1173
|
-
maxMenuHeight:
|
|
1181
|
+
maxMenuHeight: Ie(u),
|
|
1174
1182
|
isScrollable: !0,
|
|
1175
1183
|
popperProps: {
|
|
1176
|
-
appendTo:
|
|
1177
|
-
direction:
|
|
1178
|
-
width:
|
|
1184
|
+
appendTo: E(),
|
|
1185
|
+
direction: s,
|
|
1186
|
+
width: Ie(o)
|
|
1179
1187
|
},
|
|
1180
|
-
...
|
|
1181
|
-
onClick:
|
|
1188
|
+
...y,
|
|
1189
|
+
onClick: m,
|
|
1182
1190
|
onOpenChange: (k) => {
|
|
1183
|
-
k !==
|
|
1191
|
+
k !== v && m();
|
|
1184
1192
|
},
|
|
1185
1193
|
selected: a,
|
|
1186
|
-
onSelect: (k,
|
|
1187
|
-
r?.(
|
|
1194
|
+
onSelect: (k, b) => {
|
|
1195
|
+
r?.(b || ""), m();
|
|
1188
1196
|
},
|
|
1189
1197
|
toggle: (k) => /* @__PURE__ */ t(
|
|
1190
|
-
|
|
1198
|
+
ue,
|
|
1191
1199
|
{
|
|
1192
1200
|
id: e,
|
|
1193
1201
|
ref: k,
|
|
1194
1202
|
className: h,
|
|
1195
|
-
onClick:
|
|
1203
|
+
onClick: m,
|
|
1196
1204
|
isExpanded: l,
|
|
1197
|
-
"aria-label":
|
|
1198
|
-
icon:
|
|
1199
|
-
isDisabled:
|
|
1205
|
+
"aria-label": y["aria-label"],
|
|
1206
|
+
icon: c,
|
|
1207
|
+
isDisabled: d,
|
|
1200
1208
|
isFullWidth: !0,
|
|
1201
|
-
children:
|
|
1209
|
+
children: T.find((b) => b.props.value === a)?.props.children || a || y["aria-label"]
|
|
1202
1210
|
}
|
|
1203
1211
|
),
|
|
1204
1212
|
isOpen: l,
|
|
1205
|
-
children: /* @__PURE__ */ t(
|
|
1213
|
+
children: /* @__PURE__ */ t(Te, { children: g })
|
|
1206
1214
|
}
|
|
1207
1215
|
);
|
|
1208
1216
|
}, ia = ({
|
|
@@ -1212,29 +1220,29 @@ const jr = "_title_180i0_2", Gr = {
|
|
|
1212
1220
|
onFilter: a,
|
|
1213
1221
|
variant: l,
|
|
1214
1222
|
validated: i,
|
|
1215
|
-
placeholderText:
|
|
1216
|
-
maxHeight:
|
|
1223
|
+
placeholderText: s,
|
|
1224
|
+
maxHeight: o,
|
|
1217
1225
|
width: u,
|
|
1218
|
-
toggleIcon:
|
|
1226
|
+
toggleIcon: c,
|
|
1219
1227
|
direction: h,
|
|
1220
|
-
selections:
|
|
1221
|
-
typeAheadAriaLabel:
|
|
1222
|
-
chipGroupComponent:
|
|
1223
|
-
chipGroupProps:
|
|
1224
|
-
footer:
|
|
1228
|
+
selections: d,
|
|
1229
|
+
typeAheadAriaLabel: g,
|
|
1230
|
+
chipGroupComponent: y,
|
|
1231
|
+
chipGroupProps: v,
|
|
1232
|
+
footer: x,
|
|
1225
1233
|
isDisabled: p,
|
|
1226
|
-
children:
|
|
1227
|
-
...
|
|
1234
|
+
children: m,
|
|
1235
|
+
...E
|
|
1228
1236
|
}) => {
|
|
1229
|
-
const [
|
|
1230
|
-
|
|
1231
|
-
),
|
|
1232
|
-
r?.(!
|
|
1233
|
-
},
|
|
1234
|
-
const
|
|
1235
|
-
switch (r?.(!0),
|
|
1237
|
+
const [T, k] = A(""), [b, S] = A(0), F = J(), D = Dt.toArray(
|
|
1238
|
+
m
|
|
1239
|
+
), N = () => {
|
|
1240
|
+
r?.(!E.isOpen);
|
|
1241
|
+
}, K = (M) => {
|
|
1242
|
+
const f = D[b];
|
|
1243
|
+
switch (r?.(!0), M.key) {
|
|
1236
1244
|
case "Enter": {
|
|
1237
|
-
|
|
1245
|
+
M.preventDefault(), l !== G.typeaheadMulti ? k(f.props.value) : k(""), n?.(f.props.value), r?.(!1), S(0);
|
|
1238
1246
|
break;
|
|
1239
1247
|
}
|
|
1240
1248
|
case "Escape": {
|
|
@@ -1242,159 +1250,159 @@ const jr = "_title_180i0_2", Gr = {
|
|
|
1242
1250
|
break;
|
|
1243
1251
|
}
|
|
1244
1252
|
case "Backspace": {
|
|
1245
|
-
l ===
|
|
1253
|
+
l === G.typeahead && n?.("");
|
|
1246
1254
|
break;
|
|
1247
1255
|
}
|
|
1248
1256
|
case "ArrowUp":
|
|
1249
1257
|
case "ArrowDown": {
|
|
1250
|
-
|
|
1251
|
-
let
|
|
1252
|
-
|
|
1258
|
+
M.preventDefault();
|
|
1259
|
+
let w = 0;
|
|
1260
|
+
M.key === "ArrowUp" && (b === 0 ? w = D.length - 1 : w = b - 1), M.key === "ArrowDown" && (b === D.length - 1 ? w = 0 : w = b + 1), S(w);
|
|
1253
1261
|
break;
|
|
1254
1262
|
}
|
|
1255
1263
|
}
|
|
1256
1264
|
};
|
|
1257
|
-
return /* @__PURE__ */
|
|
1258
|
-
|
|
1265
|
+
return /* @__PURE__ */ C(
|
|
1266
|
+
Se,
|
|
1259
1267
|
{
|
|
1260
|
-
...
|
|
1261
|
-
onClick:
|
|
1262
|
-
onOpenChange: (
|
|
1263
|
-
onSelect: (
|
|
1264
|
-
n?.(
|
|
1268
|
+
...E,
|
|
1269
|
+
onClick: N,
|
|
1270
|
+
onOpenChange: (M) => r?.(M),
|
|
1271
|
+
onSelect: (M, f) => {
|
|
1272
|
+
n?.(f || ""), a?.(""), k("");
|
|
1265
1273
|
},
|
|
1266
|
-
maxMenuHeight:
|
|
1267
|
-
popperProps: { direction: h, width:
|
|
1268
|
-
toggle: (
|
|
1269
|
-
|
|
1274
|
+
maxMenuHeight: Ie(o),
|
|
1275
|
+
popperProps: { direction: h, width: Ie(u) },
|
|
1276
|
+
toggle: (M) => /* @__PURE__ */ t(
|
|
1277
|
+
ue,
|
|
1270
1278
|
{
|
|
1271
|
-
ref:
|
|
1279
|
+
ref: M,
|
|
1272
1280
|
id: e,
|
|
1273
1281
|
variant: "typeahead",
|
|
1274
1282
|
onClick: () => r?.(!0),
|
|
1275
|
-
icon:
|
|
1283
|
+
icon: c,
|
|
1276
1284
|
isDisabled: p,
|
|
1277
|
-
isExpanded:
|
|
1285
|
+
isExpanded: E.isOpen,
|
|
1278
1286
|
isFullWidth: !0,
|
|
1279
|
-
status: i === "error" ?
|
|
1280
|
-
children: /* @__PURE__ */
|
|
1287
|
+
status: i === "error" ? ze.danger : void 0,
|
|
1288
|
+
children: /* @__PURE__ */ C(wt, { isPlain: !0, children: [
|
|
1281
1289
|
/* @__PURE__ */ t(
|
|
1282
|
-
|
|
1290
|
+
xt,
|
|
1283
1291
|
{
|
|
1284
|
-
placeholder:
|
|
1285
|
-
value: l ===
|
|
1286
|
-
onClick:
|
|
1287
|
-
onChange: (
|
|
1288
|
-
k(
|
|
1292
|
+
placeholder: s,
|
|
1293
|
+
value: l === G.typeahead && d ? d : T,
|
|
1294
|
+
onClick: N,
|
|
1295
|
+
onChange: (f, w) => {
|
|
1296
|
+
k(w), a?.(w);
|
|
1289
1297
|
},
|
|
1290
|
-
onKeyDown: (
|
|
1298
|
+
onKeyDown: (f) => K(f),
|
|
1291
1299
|
autoComplete: "off",
|
|
1292
|
-
innerRef:
|
|
1300
|
+
innerRef: F,
|
|
1293
1301
|
role: "combobox",
|
|
1294
|
-
isExpanded:
|
|
1302
|
+
isExpanded: E.isOpen,
|
|
1295
1303
|
"aria-controls": "select-typeahead-listbox",
|
|
1296
|
-
"aria-label":
|
|
1297
|
-
children: l ===
|
|
1298
|
-
|
|
1304
|
+
"aria-label": g,
|
|
1305
|
+
children: l === G.typeaheadMulti && Array.isArray(d) && (y || /* @__PURE__ */ t(Je, { ...v, children: d.map((f, w) => /* @__PURE__ */ t(
|
|
1306
|
+
Ye,
|
|
1299
1307
|
{
|
|
1300
|
-
onClick: (
|
|
1301
|
-
|
|
1308
|
+
onClick: (R) => {
|
|
1309
|
+
R.stopPropagation(), n?.(f);
|
|
1302
1310
|
},
|
|
1303
|
-
children:
|
|
1311
|
+
children: f
|
|
1304
1312
|
},
|
|
1305
|
-
|
|
1313
|
+
w
|
|
1306
1314
|
)) }))
|
|
1307
1315
|
}
|
|
1308
1316
|
),
|
|
1309
|
-
/* @__PURE__ */ t(
|
|
1310
|
-
|
|
1317
|
+
/* @__PURE__ */ t(St, { children: !!T && /* @__PURE__ */ t(
|
|
1318
|
+
V,
|
|
1311
1319
|
{
|
|
1312
1320
|
variant: "plain",
|
|
1313
1321
|
onClick: () => {
|
|
1314
|
-
n?.(""), k(""), a?.(""),
|
|
1322
|
+
n?.(""), k(""), a?.(""), F?.current?.focus();
|
|
1315
1323
|
},
|
|
1316
1324
|
"aria-label": "Clear input value",
|
|
1317
|
-
children: /* @__PURE__ */ t(
|
|
1325
|
+
children: /* @__PURE__ */ t(Pt, { "aria-hidden": !0 })
|
|
1318
1326
|
}
|
|
1319
1327
|
) })
|
|
1320
1328
|
] })
|
|
1321
1329
|
}
|
|
1322
1330
|
),
|
|
1323
1331
|
children: [
|
|
1324
|
-
/* @__PURE__ */ t(
|
|
1325
|
-
|
|
1332
|
+
/* @__PURE__ */ t(Te, { children: m }),
|
|
1333
|
+
x && /* @__PURE__ */ t(kn, { children: x })
|
|
1326
1334
|
]
|
|
1327
1335
|
}
|
|
1328
1336
|
);
|
|
1329
1337
|
};
|
|
1330
|
-
var
|
|
1331
|
-
const
|
|
1338
|
+
var G = /* @__PURE__ */ ((e) => (e.single = "single", e.typeahead = "typeahead", e.typeaheadMulti = "typeaheadMulti", e))(G || {});
|
|
1339
|
+
const Ie = (e) => typeof e == "number" ? e + "px" : e, sa = ({
|
|
1332
1340
|
variant: e = "single",
|
|
1333
1341
|
...n
|
|
1334
|
-
}) => e === "single" ? /* @__PURE__ */ t(la, { ...n }) : /* @__PURE__ */ t(ia, { ...n, variant: e }),
|
|
1335
|
-
const { t: n, form: r, inputType: a, attribute: l } = e, [i,
|
|
1336
|
-
|
|
1337
|
-
},
|
|
1338
|
-
(
|
|
1339
|
-
).map((
|
|
1340
|
-
|
|
1342
|
+
}) => e === "single" ? /* @__PURE__ */ t(la, { ...n }) : /* @__PURE__ */ t(ia, { ...n, variant: e }), gt = (e) => {
|
|
1343
|
+
const { t: n, form: r, inputType: a, attribute: l } = e, [i, s] = A(!1), [o, u] = A(""), c = a === "multiselect", h = (p, m) => {
|
|
1344
|
+
c ? m.value.includes(p) ? m.onChange(m.value.filter((E) => E !== p)) : Array.isArray(m.value) ? m.onChange([...m.value, p]) : m.onChange([p]) : m.onChange(p === m.value ? "" : p);
|
|
1345
|
+
}, d = l.validators?.options?.options || [], g = l.annotations?.inputOptionLabels || {}, y = l.annotations?.inputOptionLabelsI18nPrefix, v = (p) => ee(e.t, g[p], p, y), x = (p) => d.filter(
|
|
1346
|
+
(m) => v(m).toLowerCase().includes(o.toLowerCase())
|
|
1347
|
+
).map((m) => /* @__PURE__ */ t(
|
|
1348
|
+
Ge,
|
|
1341
1349
|
{
|
|
1342
|
-
selected: p ===
|
|
1343
|
-
value:
|
|
1344
|
-
children:
|
|
1350
|
+
selected: p === m,
|
|
1351
|
+
value: m,
|
|
1352
|
+
children: v(m)
|
|
1345
1353
|
},
|
|
1346
|
-
|
|
1354
|
+
m
|
|
1347
1355
|
));
|
|
1348
|
-
return /* @__PURE__ */ t(
|
|
1349
|
-
|
|
1356
|
+
return /* @__PURE__ */ t(pe, { ...e, children: /* @__PURE__ */ t(
|
|
1357
|
+
le,
|
|
1350
1358
|
{
|
|
1351
|
-
name:
|
|
1359
|
+
name: Y(l.name),
|
|
1352
1360
|
defaultValue: "",
|
|
1353
1361
|
control: r.control,
|
|
1354
1362
|
render: ({ field: p }) => /* @__PURE__ */ t(
|
|
1355
|
-
|
|
1363
|
+
sa,
|
|
1356
1364
|
{
|
|
1357
1365
|
toggleId: l.name,
|
|
1358
|
-
onToggle: (
|
|
1366
|
+
onToggle: (m) => s(m),
|
|
1359
1367
|
onClear: () => h("", p),
|
|
1360
|
-
onSelect: (
|
|
1361
|
-
const
|
|
1362
|
-
h(
|
|
1368
|
+
onSelect: (m) => {
|
|
1369
|
+
const E = m.toString();
|
|
1370
|
+
h(E, p), Array.isArray(p.value) || s(!1);
|
|
1363
1371
|
},
|
|
1364
|
-
selections:
|
|
1365
|
-
variant:
|
|
1372
|
+
selections: c && Array.isArray(p.value) ? p.value.map((m) => v(m)) : v(p.value),
|
|
1373
|
+
variant: c ? G.typeaheadMulti : d.length >= 10 ? G.typeahead : G.single,
|
|
1366
1374
|
"aria-label": n("selectOne"),
|
|
1367
1375
|
isOpen: i,
|
|
1368
1376
|
isDisabled: l.readOnly,
|
|
1369
|
-
onFilter: (
|
|
1370
|
-
children:
|
|
1377
|
+
onFilter: (m) => (u(m), x(p.value)),
|
|
1378
|
+
children: x(p.value)
|
|
1371
1379
|
}
|
|
1372
1380
|
)
|
|
1373
1381
|
}
|
|
1374
1382
|
) });
|
|
1375
|
-
},
|
|
1376
|
-
const { form: n, attribute: r } = e, a =
|
|
1377
|
-
return /* @__PURE__ */ t(
|
|
1383
|
+
}, oa = (e) => {
|
|
1384
|
+
const { form: n, attribute: r } = e, a = Ae(r);
|
|
1385
|
+
return /* @__PURE__ */ t(pe, { ...e, children: /* @__PURE__ */ t(
|
|
1378
1386
|
Hr,
|
|
1379
1387
|
{
|
|
1380
1388
|
id: r.name,
|
|
1381
1389
|
"data-testid": r.name,
|
|
1382
|
-
...n.register(
|
|
1390
|
+
...n.register(Y(r.name)),
|
|
1383
1391
|
cols: r.annotations?.inputTypeCols,
|
|
1384
1392
|
rows: r.annotations?.inputTypeRows,
|
|
1385
1393
|
readOnly: r.readOnly,
|
|
1386
1394
|
isRequired: a
|
|
1387
1395
|
}
|
|
1388
1396
|
) });
|
|
1389
|
-
},
|
|
1390
|
-
const { form: n, inputType: r, attribute: a } = e, l =
|
|
1391
|
-
return /* @__PURE__ */ t(
|
|
1392
|
-
|
|
1397
|
+
}, U = (e) => {
|
|
1398
|
+
const { form: n, inputType: r, attribute: a } = e, l = Ae(a), i = r.startsWith("html") ? r.substring(6) : "text";
|
|
1399
|
+
return /* @__PURE__ */ t(pe, { ...e, children: /* @__PURE__ */ t(
|
|
1400
|
+
xe,
|
|
1393
1401
|
{
|
|
1394
1402
|
id: a.name,
|
|
1395
1403
|
"data-testid": a.name,
|
|
1396
1404
|
type: i,
|
|
1397
|
-
placeholder: a.readOnly ? "" :
|
|
1405
|
+
placeholder: a.readOnly ? "" : ee(
|
|
1398
1406
|
e.t,
|
|
1399
1407
|
a.annotations?.inputTypePlaceholder,
|
|
1400
1408
|
"",
|
|
@@ -1402,25 +1410,25 @@ const Ce = (e) => typeof e == "number" ? e + "px" : e, oa = ({
|
|
|
1402
1410
|
),
|
|
1403
1411
|
readOnly: a.readOnly,
|
|
1404
1412
|
isRequired: l,
|
|
1405
|
-
...n.register(
|
|
1413
|
+
...n.register(Y(a.name))
|
|
1406
1414
|
}
|
|
1407
1415
|
) });
|
|
1408
|
-
},
|
|
1409
|
-
text:
|
|
1410
|
-
textarea:
|
|
1411
|
-
select:
|
|
1412
|
-
"select-radiobuttons":
|
|
1413
|
-
multiselect:
|
|
1414
|
-
"multiselect-checkboxes":
|
|
1415
|
-
"html5-email":
|
|
1416
|
-
"html5-tel":
|
|
1417
|
-
"html5-url":
|
|
1418
|
-
"html5-number":
|
|
1419
|
-
"html5-range":
|
|
1420
|
-
"html5-datetime-local":
|
|
1421
|
-
"html5-date":
|
|
1422
|
-
"html5-month":
|
|
1423
|
-
"html5-time":
|
|
1416
|
+
}, Ke = {
|
|
1417
|
+
text: U,
|
|
1418
|
+
textarea: oa,
|
|
1419
|
+
select: gt,
|
|
1420
|
+
"select-radiobuttons": ft,
|
|
1421
|
+
multiselect: gt,
|
|
1422
|
+
"multiselect-checkboxes": ft,
|
|
1423
|
+
"html5-email": U,
|
|
1424
|
+
"html5-tel": U,
|
|
1425
|
+
"html5-url": U,
|
|
1426
|
+
"html5-number": U,
|
|
1427
|
+
"html5-range": U,
|
|
1428
|
+
"html5-datetime-local": U,
|
|
1429
|
+
"html5-date": U,
|
|
1430
|
+
"html5-month": U,
|
|
1431
|
+
"html5-time": U,
|
|
1424
1432
|
"multi-input": ra
|
|
1425
1433
|
}, Za = ({
|
|
1426
1434
|
t: e,
|
|
@@ -1429,20 +1437,20 @@ const Ce = (e) => typeof e == "number" ? e + "px" : e, oa = ({
|
|
|
1429
1437
|
supportedLocales: a,
|
|
1430
1438
|
currentLocale: l,
|
|
1431
1439
|
hideReadOnly: i = !1,
|
|
1432
|
-
renderer:
|
|
1440
|
+
renderer: s
|
|
1433
1441
|
}) => {
|
|
1434
|
-
const
|
|
1442
|
+
const o = _(() => {
|
|
1435
1443
|
if (!r.attributes)
|
|
1436
1444
|
return [];
|
|
1437
|
-
const u = i ? r.attributes.filter(({ readOnly:
|
|
1445
|
+
const u = i ? r.attributes.filter(({ readOnly: c }) => !c) : r.attributes;
|
|
1438
1446
|
return [
|
|
1439
1447
|
// Insert an empty group for attributes without a group.
|
|
1440
1448
|
{ name: void 0 },
|
|
1441
1449
|
...r.groups ?? []
|
|
1442
|
-
].map((
|
|
1443
|
-
group:
|
|
1450
|
+
].map((c) => ({
|
|
1451
|
+
group: c,
|
|
1444
1452
|
attributes: u.filter(
|
|
1445
|
-
(h) => h.group ===
|
|
1453
|
+
(h) => h.group === c.name
|
|
1446
1454
|
)
|
|
1447
1455
|
}));
|
|
1448
1456
|
}, [
|
|
@@ -1450,22 +1458,22 @@ const Ce = (e) => typeof e == "number" ? e + "px" : e, oa = ({
|
|
|
1450
1458
|
r.groups,
|
|
1451
1459
|
r.attributes
|
|
1452
1460
|
]);
|
|
1453
|
-
return
|
|
1461
|
+
return o.length === 0 ? null : /* @__PURE__ */ t(
|
|
1454
1462
|
Zr,
|
|
1455
1463
|
{
|
|
1456
1464
|
label: e("jumpToSection"),
|
|
1457
|
-
sections:
|
|
1458
|
-
title:
|
|
1459
|
-
panel: /* @__PURE__ */
|
|
1460
|
-
u.displayDescription && /* @__PURE__ */ t(
|
|
1461
|
-
|
|
1465
|
+
sections: o.filter((u) => u.attributes.length > 0).map(({ group: u, attributes: c }) => ({
|
|
1466
|
+
title: ee(e, u.displayHeader, u.name) || e("general"),
|
|
1467
|
+
panel: /* @__PURE__ */ C("div", { className: "pf-v5-c-form", children: [
|
|
1468
|
+
u.displayDescription && /* @__PURE__ */ t(Le, { className: "pf-v5-u-pb-lg", children: ee(e, u.displayDescription, "") }),
|
|
1469
|
+
c.map((h) => /* @__PURE__ */ t(
|
|
1462
1470
|
ca,
|
|
1463
1471
|
{
|
|
1464
1472
|
t: e,
|
|
1465
1473
|
form: n,
|
|
1466
1474
|
supportedLocales: a,
|
|
1467
1475
|
currentLocale: l,
|
|
1468
|
-
renderer:
|
|
1476
|
+
renderer: s,
|
|
1469
1477
|
attribute: h
|
|
1470
1478
|
},
|
|
1471
1479
|
h.name
|
|
@@ -1482,9 +1490,9 @@ const Ce = (e) => typeof e == "number" ? e + "px" : e, oa = ({
|
|
|
1482
1490
|
currentLocale: l,
|
|
1483
1491
|
attribute: i
|
|
1484
1492
|
}) => {
|
|
1485
|
-
const
|
|
1486
|
-
|
|
1487
|
-
),
|
|
1493
|
+
const s = n.watch(
|
|
1494
|
+
Y(i.name)
|
|
1495
|
+
), o = _(() => ua(i), [i]), u = i.multivalued || pa(s) && i.annotations?.inputType === void 0 ? Ke["multi-input"] : Ke[o];
|
|
1488
1496
|
return i.name === "locale" ? /* @__PURE__ */ t(
|
|
1489
1497
|
na,
|
|
1490
1498
|
{
|
|
@@ -1499,30 +1507,30 @@ const Ce = (e) => typeof e == "number" ? e + "px" : e, oa = ({
|
|
|
1499
1507
|
{
|
|
1500
1508
|
t: e,
|
|
1501
1509
|
form: n,
|
|
1502
|
-
inputType:
|
|
1510
|
+
inputType: o,
|
|
1503
1511
|
attribute: i,
|
|
1504
1512
|
renderer: r
|
|
1505
1513
|
}
|
|
1506
1514
|
);
|
|
1507
1515
|
}, da = "text";
|
|
1508
1516
|
function ua(e) {
|
|
1509
|
-
if (
|
|
1517
|
+
if (Ut(e.name))
|
|
1510
1518
|
return "text";
|
|
1511
1519
|
const n = e.annotations?.inputType;
|
|
1512
1520
|
return ha(n) ? n : da;
|
|
1513
1521
|
}
|
|
1514
|
-
const ha = (e) => typeof e == "string" && e in
|
|
1522
|
+
const ha = (e) => typeof e == "string" && e in Ke, pa = (e) => Array.isArray(e) && e.length > 1, ma = ({
|
|
1515
1523
|
className: e = "",
|
|
1516
1524
|
border: n,
|
|
1517
1525
|
size: r = "md"
|
|
1518
|
-
}) => /* @__PURE__ */
|
|
1526
|
+
}) => /* @__PURE__ */ C(
|
|
1519
1527
|
"svg",
|
|
1520
1528
|
{
|
|
1521
1529
|
className: fr(
|
|
1522
|
-
|
|
1523
|
-
|
|
1524
|
-
n === "light" &&
|
|
1525
|
-
n === "dark" &&
|
|
1530
|
+
ye.avatar,
|
|
1531
|
+
ye.modifiers[r],
|
|
1532
|
+
n === "light" && ye.modifiers.light,
|
|
1533
|
+
n === "dark" && ye.modifiers.dark,
|
|
1526
1534
|
e
|
|
1527
1535
|
),
|
|
1528
1536
|
enableBackground: "new 0 0 36 36",
|
|
@@ -1571,7 +1579,7 @@ const ha = (e) => typeof e == "string" && e in Ue, pa = (e) => Array.isArray(e)
|
|
|
1571
1579
|
) })
|
|
1572
1580
|
}
|
|
1573
1581
|
),
|
|
1574
|
-
/* @__PURE__ */ t("g", { style: { filter: 'url("#a")' }, children: /* @__PURE__ */
|
|
1582
|
+
/* @__PURE__ */ t("g", { style: { filter: 'url("#a")' }, children: /* @__PURE__ */ C("g", { transform: "translate(5.04 6.88)", children: [
|
|
1575
1583
|
/* @__PURE__ */ t(
|
|
1576
1584
|
"path",
|
|
1577
1585
|
{
|
|
@@ -1631,13 +1639,13 @@ const ha = (e) => typeof e == "string" && e in Ue, pa = (e) => Array.isArray(e)
|
|
|
1631
1639
|
] }) })
|
|
1632
1640
|
]
|
|
1633
1641
|
}
|
|
1634
|
-
),
|
|
1642
|
+
), yt = ({
|
|
1635
1643
|
isKebab: e = !1,
|
|
1636
1644
|
title: n,
|
|
1637
1645
|
dropDownItems: r,
|
|
1638
1646
|
...a
|
|
1639
1647
|
}) => {
|
|
1640
|
-
const [l, i] =
|
|
1648
|
+
const [l, i] = A(!1);
|
|
1641
1649
|
return /* @__PURE__ */ t(
|
|
1642
1650
|
In,
|
|
1643
1651
|
{
|
|
@@ -1645,16 +1653,16 @@ const ha = (e) => typeof e == "string" && e in Ue, pa = (e) => Array.isArray(e)
|
|
|
1645
1653
|
popperProps: {
|
|
1646
1654
|
position: "right"
|
|
1647
1655
|
},
|
|
1648
|
-
onOpenChange: (
|
|
1649
|
-
toggle: (
|
|
1650
|
-
|
|
1656
|
+
onOpenChange: (s) => i(s),
|
|
1657
|
+
toggle: (s) => /* @__PURE__ */ t(
|
|
1658
|
+
ue,
|
|
1651
1659
|
{
|
|
1652
1660
|
"data-testid": `${a["data-testid"]}-toggle`,
|
|
1653
|
-
ref:
|
|
1661
|
+
ref: s,
|
|
1654
1662
|
onClick: () => i(!l),
|
|
1655
1663
|
isExpanded: l,
|
|
1656
1664
|
variant: e ? "plain" : "default",
|
|
1657
|
-
children: e ? /* @__PURE__ */ t(
|
|
1665
|
+
children: e ? /* @__PURE__ */ t(sr, {}) : n
|
|
1658
1666
|
}
|
|
1659
1667
|
),
|
|
1660
1668
|
isOpen: l,
|
|
@@ -1673,87 +1681,87 @@ const el = ({
|
|
|
1673
1681
|
brand: { src: n, alt: r, className: a, ...l },
|
|
1674
1682
|
avatar: i,
|
|
1675
1683
|
features: {
|
|
1676
|
-
hasLogout:
|
|
1677
|
-
hasManageAccount:
|
|
1684
|
+
hasLogout: s = !0,
|
|
1685
|
+
hasManageAccount: o = !0,
|
|
1678
1686
|
hasUsername: u = !0
|
|
1679
1687
|
} = {},
|
|
1680
|
-
kebabDropdownItems:
|
|
1688
|
+
kebabDropdownItems: c,
|
|
1681
1689
|
dropdownItems: h = [],
|
|
1682
|
-
toolbarItems:
|
|
1683
|
-
toolbar:
|
|
1684
|
-
...
|
|
1690
|
+
toolbarItems: d,
|
|
1691
|
+
toolbar: g,
|
|
1692
|
+
...y
|
|
1685
1693
|
}) => {
|
|
1686
|
-
const { t:
|
|
1687
|
-
|
|
1694
|
+
const { t: v } = q(), x = [];
|
|
1695
|
+
o && x.push(
|
|
1688
1696
|
/* @__PURE__ */ t(
|
|
1689
1697
|
ot,
|
|
1690
1698
|
{
|
|
1691
1699
|
onClick: () => e.accountManagement(),
|
|
1692
|
-
children:
|
|
1700
|
+
children: v("manageAccount")
|
|
1693
1701
|
},
|
|
1694
1702
|
"manageAccount"
|
|
1695
1703
|
)
|
|
1696
|
-
),
|
|
1697
|
-
/* @__PURE__ */ t(ot, { onClick: () => e.logout(), children:
|
|
1704
|
+
), s && x.push(
|
|
1705
|
+
/* @__PURE__ */ t(ot, { onClick: () => e.logout(), children: v("signOut") }, "signOut")
|
|
1698
1706
|
);
|
|
1699
1707
|
const p = e.idTokenParsed?.picture;
|
|
1700
|
-
return /* @__PURE__ */
|
|
1701
|
-
/* @__PURE__ */ t(
|
|
1702
|
-
/* @__PURE__ */ t(
|
|
1703
|
-
/* @__PURE__ */
|
|
1704
|
-
|
|
1705
|
-
/* @__PURE__ */ t(
|
|
1706
|
-
|
|
1708
|
+
return /* @__PURE__ */ C(xn, { ...y, children: [
|
|
1709
|
+
/* @__PURE__ */ t(Sn, { children: /* @__PURE__ */ t(Tn, { variant: "plain", "aria-label": v("navigation"), children: /* @__PURE__ */ t(or, {}) }) }),
|
|
1710
|
+
/* @__PURE__ */ t(En, { ...l, children: /* @__PURE__ */ t("img", { src: n, alt: r, className: a }) }),
|
|
1711
|
+
/* @__PURE__ */ C(An, { children: [
|
|
1712
|
+
g,
|
|
1713
|
+
/* @__PURE__ */ t(Ce, { children: /* @__PURE__ */ C(Ve, { children: [
|
|
1714
|
+
d?.map((m, E) => /* @__PURE__ */ t(H, { align: { default: "alignRight" }, children: m }, E)),
|
|
1707
1715
|
/* @__PURE__ */ t(
|
|
1708
|
-
|
|
1716
|
+
H,
|
|
1709
1717
|
{
|
|
1710
1718
|
visibility: {
|
|
1711
1719
|
default: "hidden",
|
|
1712
1720
|
md: "visible"
|
|
1713
1721
|
},
|
|
1714
1722
|
children: /* @__PURE__ */ t(
|
|
1715
|
-
|
|
1723
|
+
yt,
|
|
1716
1724
|
{
|
|
1717
1725
|
"data-testid": "options",
|
|
1718
|
-
dropDownItems: [...h,
|
|
1719
|
-
title: u ? fa(e.idTokenParsed,
|
|
1726
|
+
dropDownItems: [...h, x],
|
|
1727
|
+
title: u ? fa(e.idTokenParsed, v) : void 0
|
|
1720
1728
|
}
|
|
1721
1729
|
)
|
|
1722
1730
|
}
|
|
1723
1731
|
),
|
|
1724
1732
|
/* @__PURE__ */ t(
|
|
1725
|
-
|
|
1733
|
+
H,
|
|
1726
1734
|
{
|
|
1727
1735
|
align: { default: "alignLeft" },
|
|
1728
1736
|
visibility: {
|
|
1729
1737
|
md: "hidden"
|
|
1730
1738
|
},
|
|
1731
1739
|
children: /* @__PURE__ */ t(
|
|
1732
|
-
|
|
1740
|
+
yt,
|
|
1733
1741
|
{
|
|
1734
1742
|
"data-testid": "options-kebab",
|
|
1735
1743
|
isKebab: !0,
|
|
1736
1744
|
dropDownItems: [
|
|
1737
|
-
...
|
|
1738
|
-
|
|
1745
|
+
...c || h,
|
|
1746
|
+
x
|
|
1739
1747
|
]
|
|
1740
1748
|
}
|
|
1741
1749
|
)
|
|
1742
1750
|
}
|
|
1743
1751
|
),
|
|
1744
1752
|
/* @__PURE__ */ t(
|
|
1745
|
-
|
|
1753
|
+
H,
|
|
1746
1754
|
{
|
|
1747
1755
|
variant: "overflow-menu",
|
|
1748
1756
|
align: { default: "alignRight" },
|
|
1749
1757
|
className: "pf-v5-u-m-0-on-lg",
|
|
1750
|
-
children: p || i?.src ? /* @__PURE__ */ t(Rn, { src: p, alt:
|
|
1758
|
+
children: p || i?.src ? /* @__PURE__ */ t(Rn, { src: p, alt: v("avatar"), ...i }) : /* @__PURE__ */ t(ma, { ...i })
|
|
1751
1759
|
}
|
|
1752
1760
|
)
|
|
1753
1761
|
] }) })
|
|
1754
1762
|
] })
|
|
1755
1763
|
] });
|
|
1756
|
-
},
|
|
1764
|
+
}, Ht = Xe("ErrorBoundaryContext", void 0), Wt = () => Ze(Ht);
|
|
1757
1765
|
class tl extends $n {
|
|
1758
1766
|
state = {};
|
|
1759
1767
|
static getDerivedStateFromError = (n) => ({ error: n });
|
|
@@ -1762,7 +1770,7 @@ class tl extends $n {
|
|
|
1762
1770
|
};
|
|
1763
1771
|
render() {
|
|
1764
1772
|
return /* @__PURE__ */ t(
|
|
1765
|
-
|
|
1773
|
+
Ht.Provider,
|
|
1766
1774
|
{
|
|
1767
1775
|
value: { error: this.state.error, showBoundary: this.showBoundary },
|
|
1768
1776
|
children: this.props.children
|
|
@@ -1771,40 +1779,40 @@ class tl extends $n {
|
|
|
1771
1779
|
}
|
|
1772
1780
|
}
|
|
1773
1781
|
const nl = ({ children: e, fallback: n }) => {
|
|
1774
|
-
const { error: r } =
|
|
1782
|
+
const { error: r } = Wt();
|
|
1775
1783
|
return r ? /* @__PURE__ */ t(n, { error: r }) : e;
|
|
1776
1784
|
};
|
|
1777
1785
|
function ga(e, n, r) {
|
|
1778
|
-
const { showBoundary: a } =
|
|
1779
|
-
|
|
1786
|
+
const { showBoundary: a } = Wt();
|
|
1787
|
+
ae(() => {
|
|
1780
1788
|
const l = new AbortController(), { signal: i } = l;
|
|
1781
|
-
return e().then((
|
|
1782
|
-
i.aborted || n(
|
|
1783
|
-
}).catch((
|
|
1784
|
-
console.error(
|
|
1789
|
+
return e().then((s) => {
|
|
1790
|
+
i.aborted || n(s);
|
|
1791
|
+
}).catch((s) => {
|
|
1792
|
+
console.error(s), i.aborted || a(s);
|
|
1785
1793
|
}), () => l.abort();
|
|
1786
1794
|
}, r);
|
|
1787
1795
|
}
|
|
1788
1796
|
const ya = () => {
|
|
1789
|
-
const { t: e } =
|
|
1790
|
-
return /* @__PURE__ */ t(On, { children: /* @__PURE__ */ t(
|
|
1791
|
-
},
|
|
1797
|
+
const { t: e } = q();
|
|
1798
|
+
return /* @__PURE__ */ t(On, { children: /* @__PURE__ */ t(kt, { "aria-label": e("spinnerLoading") }) });
|
|
1799
|
+
}, ba = ({
|
|
1792
1800
|
message: e,
|
|
1793
1801
|
instructions: n,
|
|
1794
1802
|
onPrimaryAction: r,
|
|
1795
1803
|
hasIcon: a = !0,
|
|
1796
1804
|
isSearchVariant: l,
|
|
1797
1805
|
primaryActionText: i,
|
|
1798
|
-
secondaryActions:
|
|
1799
|
-
icon:
|
|
1806
|
+
secondaryActions: s,
|
|
1807
|
+
icon: o,
|
|
1800
1808
|
isDisabled: u = !1
|
|
1801
|
-
}) => /* @__PURE__ */
|
|
1802
|
-
a && l ? /* @__PURE__ */ t(
|
|
1809
|
+
}) => /* @__PURE__ */ C(Dn, { "data-testid": "empty-state", variant: "lg", children: [
|
|
1810
|
+
a && l ? /* @__PURE__ */ t(ct, { icon: cr }) : a && /* @__PURE__ */ t(ct, { icon: o || Mt }),
|
|
1803
1811
|
/* @__PURE__ */ t(Fn, { titleText: e, headingLevel: "h1" }),
|
|
1804
1812
|
/* @__PURE__ */ t(Pn, { children: n }),
|
|
1805
|
-
/* @__PURE__ */
|
|
1813
|
+
/* @__PURE__ */ C(Mn, { children: [
|
|
1806
1814
|
i && /* @__PURE__ */ t(
|
|
1807
|
-
|
|
1815
|
+
V,
|
|
1808
1816
|
{
|
|
1809
1817
|
"data-testid": `${e.replace(/\W+/g, "-").toLowerCase()}-empty-action`,
|
|
1810
1818
|
variant: "primary",
|
|
@@ -1813,71 +1821,71 @@ const ya = () => {
|
|
|
1813
1821
|
children: i
|
|
1814
1822
|
}
|
|
1815
1823
|
),
|
|
1816
|
-
|
|
1817
|
-
|
|
1824
|
+
s && /* @__PURE__ */ t(Ln, { children: s.map((c) => /* @__PURE__ */ t(
|
|
1825
|
+
V,
|
|
1818
1826
|
{
|
|
1819
|
-
"data-testid": `${
|
|
1820
|
-
variant:
|
|
1821
|
-
onClick:
|
|
1827
|
+
"data-testid": `${c.text.replace(/\W+/g, "-").toLowerCase()}-empty-action`,
|
|
1828
|
+
variant: c.type || ke.secondary,
|
|
1829
|
+
onClick: c.onClick,
|
|
1822
1830
|
isDisabled: u,
|
|
1823
|
-
children:
|
|
1831
|
+
children: c.text
|
|
1824
1832
|
},
|
|
1825
|
-
|
|
1833
|
+
c.text
|
|
1826
1834
|
)) })
|
|
1827
1835
|
] })
|
|
1828
|
-
] }),
|
|
1836
|
+
] }), va = ({
|
|
1829
1837
|
toolbarItem: e,
|
|
1830
1838
|
subToolbar: n,
|
|
1831
1839
|
toolbarItemFooter: r,
|
|
1832
1840
|
children: a,
|
|
1833
1841
|
searchTypeComponent: l,
|
|
1834
1842
|
inputGroupName: i,
|
|
1835
|
-
inputGroupPlaceholder:
|
|
1836
|
-
inputGroupOnEnter:
|
|
1843
|
+
inputGroupPlaceholder: s,
|
|
1844
|
+
inputGroupOnEnter: o
|
|
1837
1845
|
}) => {
|
|
1838
|
-
const { t: u } =
|
|
1839
|
-
h(
|
|
1840
|
-
},
|
|
1841
|
-
|
|
1846
|
+
const { t: u } = q(), [c, h] = A(""), d = (y) => {
|
|
1847
|
+
h(y.trim()), o?.(y.trim());
|
|
1848
|
+
}, g = (y) => {
|
|
1849
|
+
y.key === "Enter" && d(c);
|
|
1842
1850
|
};
|
|
1843
|
-
return /* @__PURE__ */
|
|
1844
|
-
/* @__PURE__ */ t(
|
|
1845
|
-
i && /* @__PURE__ */ t(
|
|
1851
|
+
return /* @__PURE__ */ C(W, { children: [
|
|
1852
|
+
/* @__PURE__ */ t(Ce, { "data-testid": "table-toolbar", children: /* @__PURE__ */ C(Ve, { children: [
|
|
1853
|
+
i && /* @__PURE__ */ t(H, { children: /* @__PURE__ */ C(we, { "data-testid": i, children: [
|
|
1846
1854
|
l,
|
|
1847
|
-
|
|
1855
|
+
s && /* @__PURE__ */ t(
|
|
1848
1856
|
Nn,
|
|
1849
1857
|
{
|
|
1850
1858
|
"data-testid": "table-search-input",
|
|
1851
|
-
placeholder:
|
|
1859
|
+
placeholder: s,
|
|
1852
1860
|
"aria-label": u("search"),
|
|
1853
|
-
value:
|
|
1854
|
-
onChange: (
|
|
1855
|
-
h(
|
|
1861
|
+
value: c,
|
|
1862
|
+
onChange: (y, v) => {
|
|
1863
|
+
h(v);
|
|
1856
1864
|
},
|
|
1857
|
-
onSearch: () => c
|
|
1858
|
-
onKeyDown:
|
|
1859
|
-
onClear: () =>
|
|
1865
|
+
onSearch: () => d(c),
|
|
1866
|
+
onKeyDown: g,
|
|
1867
|
+
onClear: () => d("")
|
|
1860
1868
|
}
|
|
1861
1869
|
)
|
|
1862
1870
|
] }) }),
|
|
1863
1871
|
e
|
|
1864
1872
|
] }) }),
|
|
1865
|
-
n && /* @__PURE__ */ t(
|
|
1873
|
+
n && /* @__PURE__ */ t(Ce, { children: /* @__PURE__ */ t(Ve, { children: n }) }),
|
|
1866
1874
|
/* @__PURE__ */ t(Bn, {}),
|
|
1867
1875
|
a,
|
|
1868
|
-
/* @__PURE__ */ t(
|
|
1876
|
+
/* @__PURE__ */ t(Ce, { children: r })
|
|
1869
1877
|
] });
|
|
1870
|
-
},
|
|
1878
|
+
}, bt = ({
|
|
1871
1879
|
id: e,
|
|
1872
1880
|
variant: n = "top",
|
|
1873
1881
|
count: r,
|
|
1874
1882
|
first: a,
|
|
1875
1883
|
max: l,
|
|
1876
1884
|
onNextClick: i,
|
|
1877
|
-
onPreviousClick:
|
|
1878
|
-
onPerPageSelect:
|
|
1885
|
+
onPreviousClick: s,
|
|
1886
|
+
onPerPageSelect: o
|
|
1879
1887
|
}) => {
|
|
1880
|
-
const { t: u } =
|
|
1888
|
+
const { t: u } = q(), c = Math.round(a / l);
|
|
1881
1889
|
return /* @__PURE__ */ t(
|
|
1882
1890
|
Vn,
|
|
1883
1891
|
{
|
|
@@ -1888,18 +1896,18 @@ const ya = () => {
|
|
|
1888
1896
|
isCompact: !0,
|
|
1889
1897
|
toggleTemplate: ({
|
|
1890
1898
|
firstIndex: h,
|
|
1891
|
-
lastIndex:
|
|
1892
|
-
}) => /* @__PURE__ */
|
|
1899
|
+
lastIndex: d
|
|
1900
|
+
}) => /* @__PURE__ */ C("b", { children: [
|
|
1893
1901
|
h,
|
|
1894
1902
|
" - ",
|
|
1895
|
-
|
|
1903
|
+
d
|
|
1896
1904
|
] }),
|
|
1897
|
-
itemCount: r +
|
|
1898
|
-
page:
|
|
1905
|
+
itemCount: r + c * l,
|
|
1906
|
+
page: c + 1,
|
|
1899
1907
|
perPage: l,
|
|
1900
|
-
onNextClick: (h,
|
|
1901
|
-
onPreviousClick: (h,
|
|
1902
|
-
onPerPageSelect: (h,
|
|
1908
|
+
onNextClick: (h, d) => i((d - 1) * l),
|
|
1909
|
+
onPreviousClick: (h, d) => s((d - 1) * l),
|
|
1910
|
+
onPerPageSelect: (h, d, g) => o(g - 1, d),
|
|
1903
1911
|
variant: n
|
|
1904
1912
|
}
|
|
1905
1913
|
);
|
|
@@ -1910,39 +1918,39 @@ const ya = () => {
|
|
|
1910
1918
|
subToolbar: a,
|
|
1911
1919
|
children: l,
|
|
1912
1920
|
inputGroupName: i,
|
|
1913
|
-
inputGroupPlaceholder:
|
|
1914
|
-
inputGroupOnEnter:
|
|
1921
|
+
inputGroupPlaceholder: s,
|
|
1922
|
+
inputGroupOnEnter: o,
|
|
1915
1923
|
...u
|
|
1916
1924
|
}) => /* @__PURE__ */ t(
|
|
1917
|
-
|
|
1925
|
+
va,
|
|
1918
1926
|
{
|
|
1919
1927
|
searchTypeComponent: n,
|
|
1920
|
-
toolbarItem: /* @__PURE__ */
|
|
1928
|
+
toolbarItem: /* @__PURE__ */ C(W, { children: [
|
|
1921
1929
|
r,
|
|
1922
|
-
/* @__PURE__ */ t(
|
|
1930
|
+
/* @__PURE__ */ t(H, { variant: "pagination", children: /* @__PURE__ */ t(bt, { count: e, ...u }) })
|
|
1923
1931
|
] }),
|
|
1924
1932
|
subToolbar: a,
|
|
1925
|
-
toolbarItemFooter: e !== 0 ? /* @__PURE__ */ t(
|
|
1933
|
+
toolbarItemFooter: e !== 0 ? /* @__PURE__ */ t(H, { variant: "pagination", children: /* @__PURE__ */ t(bt, { count: e, variant: "bottom", ...u }) }) : null,
|
|
1926
1934
|
inputGroupName: i,
|
|
1927
|
-
inputGroupPlaceholder:
|
|
1928
|
-
inputGroupOnEnter:
|
|
1935
|
+
inputGroupPlaceholder: s,
|
|
1936
|
+
inputGroupOnEnter: o,
|
|
1929
1937
|
children: l
|
|
1930
1938
|
}
|
|
1931
|
-
),
|
|
1939
|
+
), jt = (e) => !!e && e.title !== void 0, vt = ({
|
|
1932
1940
|
row: e,
|
|
1933
1941
|
index: n,
|
|
1934
1942
|
actions: r,
|
|
1935
1943
|
actionResolver: a
|
|
1936
|
-
}) => /* @__PURE__ */
|
|
1937
|
-
e.cells.map((l, i) => /* @__PURE__ */ t(
|
|
1938
|
-
(r || a) && /* @__PURE__ */ t(
|
|
1944
|
+
}) => /* @__PURE__ */ C(W, { children: [
|
|
1945
|
+
e.cells.map((l, i) => /* @__PURE__ */ t(ne, { children: jt(l) ? l.title : l }, `cell-${i}`)),
|
|
1946
|
+
(r || a) && /* @__PURE__ */ t(ne, { isActionCell: !0, children: /* @__PURE__ */ t(
|
|
1939
1947
|
Cr,
|
|
1940
1948
|
{
|
|
1941
1949
|
items: r || a?.(e, {}),
|
|
1942
1950
|
extraData: { rowIndex: n }
|
|
1943
1951
|
}
|
|
1944
1952
|
) })
|
|
1945
|
-
] }), ka = ({ row: e }) => e.cells.map((n, r) => /* @__PURE__ */ t("div", { children:
|
|
1953
|
+
] }), ka = ({ row: e }) => e.cells.map((n, r) => /* @__PURE__ */ t("div", { children: jt(n) ? n.title : n }, `cell-${r}`));
|
|
1946
1954
|
function Ia({
|
|
1947
1955
|
columns: e,
|
|
1948
1956
|
rows: n,
|
|
@@ -1950,94 +1958,94 @@ function Ia({
|
|
|
1950
1958
|
actionResolver: a,
|
|
1951
1959
|
ariaLabelKey: l,
|
|
1952
1960
|
selected: i,
|
|
1953
|
-
onSelect:
|
|
1954
|
-
onCollapse:
|
|
1961
|
+
onSelect: s,
|
|
1962
|
+
onCollapse: o,
|
|
1955
1963
|
canSelectAll: u,
|
|
1956
|
-
canSelect:
|
|
1964
|
+
canSelect: c,
|
|
1957
1965
|
isNotCompact: h,
|
|
1958
|
-
isRadio:
|
|
1959
|
-
...
|
|
1966
|
+
isRadio: d,
|
|
1967
|
+
...g
|
|
1960
1968
|
}) {
|
|
1961
|
-
const { t:
|
|
1969
|
+
const { t: y } = q(), [v, x] = A(i || []), [p, m] = A([]), E = _(
|
|
1962
1970
|
() => mr(
|
|
1963
|
-
|
|
1964
|
-
n.map((
|
|
1971
|
+
v,
|
|
1972
|
+
n.map((b) => b.data),
|
|
1965
1973
|
"id"
|
|
1966
1974
|
),
|
|
1967
|
-
[
|
|
1975
|
+
[v, n]
|
|
1968
1976
|
);
|
|
1969
|
-
|
|
1977
|
+
ae(() => {
|
|
1970
1978
|
if (u) {
|
|
1971
|
-
const
|
|
1972
|
-
if (
|
|
1973
|
-
const
|
|
1974
|
-
|
|
1979
|
+
const b = document.getElementsByName("check-all").item(0);
|
|
1980
|
+
if (b) {
|
|
1981
|
+
const S = b;
|
|
1982
|
+
S.indeterminate = E.length < n.length && E.length > 0;
|
|
1975
1983
|
}
|
|
1976
1984
|
}
|
|
1977
|
-
}, [
|
|
1978
|
-
const
|
|
1979
|
-
|
|
1980
|
-
}, k = (
|
|
1981
|
-
if (
|
|
1982
|
-
const
|
|
1983
|
-
|
|
1984
|
-
} else if (
|
|
1985
|
-
const
|
|
1986
|
-
(
|
|
1985
|
+
}, [v, u, n]);
|
|
1986
|
+
const T = (b) => {
|
|
1987
|
+
x(b), s?.(b);
|
|
1988
|
+
}, k = (b, S) => {
|
|
1989
|
+
if (d) {
|
|
1990
|
+
const F = S ? [n[b].data] : [];
|
|
1991
|
+
T(F);
|
|
1992
|
+
} else if (b === -1) {
|
|
1993
|
+
const F = E.map(
|
|
1994
|
+
(D) => B(D, "id")
|
|
1987
1995
|
);
|
|
1988
|
-
|
|
1989
|
-
|
|
1990
|
-
(
|
|
1996
|
+
T(
|
|
1997
|
+
S ? [...v, ...n.map((D) => D.data)] : v.filter(
|
|
1998
|
+
(D) => !F.includes(B(D, "id"))
|
|
1991
1999
|
)
|
|
1992
2000
|
);
|
|
1993
2001
|
} else
|
|
1994
|
-
|
|
1995
|
-
(
|
|
2002
|
+
T(S ? [...v, n[b].data] : v.filter(
|
|
2003
|
+
(F) => B(F, "id") !== n[b].data.id
|
|
1996
2004
|
));
|
|
1997
2005
|
};
|
|
1998
|
-
return /* @__PURE__ */
|
|
2006
|
+
return /* @__PURE__ */ C(
|
|
1999
2007
|
gr,
|
|
2000
2008
|
{
|
|
2001
|
-
...
|
|
2009
|
+
...g,
|
|
2002
2010
|
variant: h ? void 0 : yr.compact,
|
|
2003
|
-
"aria-label":
|
|
2011
|
+
"aria-label": y(l),
|
|
2004
2012
|
children: [
|
|
2005
|
-
/* @__PURE__ */ t(
|
|
2006
|
-
|
|
2013
|
+
/* @__PURE__ */ t(br, { children: /* @__PURE__ */ C(be, { children: [
|
|
2014
|
+
o && /* @__PURE__ */ t(Fe, { screenReaderText: y("expandRow") }),
|
|
2007
2015
|
u && /* @__PURE__ */ t(
|
|
2008
|
-
|
|
2016
|
+
Fe,
|
|
2009
2017
|
{
|
|
2010
|
-
screenReaderText:
|
|
2011
|
-
select:
|
|
2012
|
-
onSelect: (
|
|
2013
|
-
k(-1,
|
|
2018
|
+
screenReaderText: y("selectAll"),
|
|
2019
|
+
select: d ? void 0 : {
|
|
2020
|
+
onSelect: (b, S) => {
|
|
2021
|
+
k(-1, S);
|
|
2014
2022
|
},
|
|
2015
|
-
isSelected:
|
|
2023
|
+
isSelected: E.length === n.length
|
|
2016
2024
|
}
|
|
2017
2025
|
}
|
|
2018
2026
|
),
|
|
2019
|
-
e.map((
|
|
2020
|
-
|
|
2027
|
+
e.map((b) => /* @__PURE__ */ t(
|
|
2028
|
+
Fe,
|
|
2021
2029
|
{
|
|
2022
|
-
screenReaderText:
|
|
2023
|
-
className:
|
|
2024
|
-
children:
|
|
2030
|
+
screenReaderText: y("expandRow"),
|
|
2031
|
+
className: b.transforms?.[0]().className,
|
|
2032
|
+
children: y(b.displayKey || b.name)
|
|
2025
2033
|
},
|
|
2026
|
-
|
|
2034
|
+
b.displayKey || b.name
|
|
2027
2035
|
))
|
|
2028
2036
|
] }) }),
|
|
2029
|
-
|
|
2037
|
+
o ? n.map((b, S) => /* @__PURE__ */ t(ut, { children: S % 2 === 0 ? /* @__PURE__ */ C(be, { children: [
|
|
2030
2038
|
/* @__PURE__ */ t(
|
|
2031
|
-
|
|
2039
|
+
ne,
|
|
2032
2040
|
{
|
|
2033
|
-
expand: n[
|
|
2034
|
-
isExpanded: !!p[
|
|
2035
|
-
rowIndex:
|
|
2041
|
+
expand: n[S + 1].cells.length === 0 ? void 0 : {
|
|
2042
|
+
isExpanded: !!p[S],
|
|
2043
|
+
rowIndex: S,
|
|
2036
2044
|
expandId: "expandable-row-",
|
|
2037
|
-
onToggle: (
|
|
2038
|
-
|
|
2039
|
-
const
|
|
2040
|
-
|
|
2045
|
+
onToggle: (F, D, N) => {
|
|
2046
|
+
o(N, D);
|
|
2047
|
+
const K = [...p];
|
|
2048
|
+
K[S] = N, m(K);
|
|
2041
2049
|
}
|
|
2042
2050
|
}
|
|
2043
2051
|
}
|
|
@@ -2045,41 +2053,41 @@ function Ia({
|
|
|
2045
2053
|
/* @__PURE__ */ t(
|
|
2046
2054
|
vt,
|
|
2047
2055
|
{
|
|
2048
|
-
row:
|
|
2049
|
-
index:
|
|
2056
|
+
row: b,
|
|
2057
|
+
index: S,
|
|
2050
2058
|
actions: r,
|
|
2051
2059
|
actionResolver: a
|
|
2052
2060
|
}
|
|
2053
2061
|
)
|
|
2054
|
-
] }) : /* @__PURE__ */
|
|
2055
|
-
/* @__PURE__ */ t(
|
|
2056
|
-
/* @__PURE__ */ t(
|
|
2057
|
-
] }) },
|
|
2058
|
-
|
|
2059
|
-
|
|
2062
|
+
] }) : /* @__PURE__ */ C(be, { isExpanded: !!p[S - 1], children: [
|
|
2063
|
+
/* @__PURE__ */ t(ne, {}),
|
|
2064
|
+
/* @__PURE__ */ t(ne, { colSpan: e.length, children: /* @__PURE__ */ t(vr, { children: /* @__PURE__ */ t(ka, { row: b }) }) })
|
|
2065
|
+
] }) }, S)) : /* @__PURE__ */ t(ut, { children: n.map((b, S) => /* @__PURE__ */ C(be, { isExpanded: p[S], children: [
|
|
2066
|
+
c && /* @__PURE__ */ t(
|
|
2067
|
+
ne,
|
|
2060
2068
|
{
|
|
2061
2069
|
select: {
|
|
2062
|
-
rowIndex:
|
|
2063
|
-
onSelect: (
|
|
2064
|
-
k(
|
|
2070
|
+
rowIndex: S,
|
|
2071
|
+
onSelect: (F, D, N) => {
|
|
2072
|
+
k(N, D);
|
|
2065
2073
|
},
|
|
2066
|
-
isSelected: !!
|
|
2067
|
-
(
|
|
2074
|
+
isSelected: !!v.find(
|
|
2075
|
+
(F) => B(F, "id") === b.data.id
|
|
2068
2076
|
),
|
|
2069
|
-
variant:
|
|
2077
|
+
variant: d ? "radio" : "checkbox"
|
|
2070
2078
|
}
|
|
2071
2079
|
}
|
|
2072
2080
|
),
|
|
2073
2081
|
/* @__PURE__ */ t(
|
|
2074
2082
|
vt,
|
|
2075
2083
|
{
|
|
2076
|
-
row:
|
|
2077
|
-
index:
|
|
2084
|
+
row: b,
|
|
2085
|
+
index: S,
|
|
2078
2086
|
actions: r,
|
|
2079
2087
|
actionResolver: a
|
|
2080
2088
|
}
|
|
2081
2089
|
)
|
|
2082
|
-
] },
|
|
2090
|
+
] }, S)) })
|
|
2083
2091
|
]
|
|
2084
2092
|
}
|
|
2085
2093
|
);
|
|
@@ -2091,152 +2099,152 @@ function wa({
|
|
|
2091
2099
|
onSelect: a,
|
|
2092
2100
|
canSelectAll: l = !1,
|
|
2093
2101
|
isNotCompact: i,
|
|
2094
|
-
isRadio:
|
|
2095
|
-
detailColumns:
|
|
2102
|
+
isRadio: s,
|
|
2103
|
+
detailColumns: o,
|
|
2096
2104
|
isRowDisabled: u,
|
|
2097
|
-
loader:
|
|
2105
|
+
loader: c,
|
|
2098
2106
|
columns: h,
|
|
2099
|
-
actions:
|
|
2100
|
-
actionResolver:
|
|
2101
|
-
searchTypeComponent:
|
|
2102
|
-
toolbarItem:
|
|
2103
|
-
subToolbar:
|
|
2107
|
+
actions: d,
|
|
2108
|
+
actionResolver: g,
|
|
2109
|
+
searchTypeComponent: y,
|
|
2110
|
+
toolbarItem: v,
|
|
2111
|
+
subToolbar: x,
|
|
2104
2112
|
emptyState: p,
|
|
2105
|
-
icon:
|
|
2106
|
-
isSearching:
|
|
2107
|
-
...
|
|
2113
|
+
icon: m,
|
|
2114
|
+
isSearching: E = !1,
|
|
2115
|
+
...T
|
|
2108
2116
|
}) {
|
|
2109
|
-
const { t: k } =
|
|
2117
|
+
const { t: k } = q(), [b, S] = A([]), [F, D] = A(), [N, K] = A(), [M, f] = A(!1), [w, R] = Bt(
|
|
2110
2118
|
localStorage,
|
|
2111
2119
|
"pageSize",
|
|
2112
2120
|
10
|
|
2113
|
-
), [
|
|
2114
|
-
if ("cellFormatters" in
|
|
2115
|
-
const
|
|
2116
|
-
return
|
|
2121
|
+
), [O, ie] = A(w), [$, se] = A(0), [j, Re] = A(""), tt = J(), [me, Gt] = A(0), nt = J(), rt = () => Gt(me + 1), zt = Rt(), at = (I, P) => I.map((L) => {
|
|
2122
|
+
if ("cellFormatters" in L) {
|
|
2123
|
+
const X = B(P, L.name);
|
|
2124
|
+
return L.cellFormatters?.reduce((oe, ge) => ge(oe), X);
|
|
2117
2125
|
}
|
|
2118
|
-
if (
|
|
2119
|
-
const
|
|
2120
|
-
return { title: /* @__PURE__ */ t(
|
|
2126
|
+
if (L.cellRenderer) {
|
|
2127
|
+
const X = L.cellRenderer;
|
|
2128
|
+
return { title: /* @__PURE__ */ t(X, { ...P }) };
|
|
2121
2129
|
}
|
|
2122
|
-
return
|
|
2123
|
-
}),
|
|
2124
|
-
const
|
|
2125
|
-
return I.map((
|
|
2126
|
-
const
|
|
2130
|
+
return B(P, L.name);
|
|
2131
|
+
}), lt = (I) => {
|
|
2132
|
+
const P = (L) => o?.[0]?.enabled?.(L);
|
|
2133
|
+
return I.map((L, X) => {
|
|
2134
|
+
const oe = u ? u(L) : !1, ge = [
|
|
2127
2135
|
{
|
|
2128
|
-
data:
|
|
2129
|
-
disableSelection:
|
|
2130
|
-
disableActions:
|
|
2131
|
-
selected: !!
|
|
2132
|
-
isOpen:
|
|
2133
|
-
cells:
|
|
2136
|
+
data: L,
|
|
2137
|
+
disableSelection: oe,
|
|
2138
|
+
disableActions: oe,
|
|
2139
|
+
selected: !!b.find((Zt) => B(Zt, "id") === B(L, "id")),
|
|
2140
|
+
isOpen: P(L) ? !1 : void 0,
|
|
2141
|
+
cells: at(h, L)
|
|
2134
2142
|
}
|
|
2135
2143
|
];
|
|
2136
|
-
return
|
|
2137
|
-
parent:
|
|
2138
|
-
cells:
|
|
2139
|
-
}),
|
|
2144
|
+
return o && ge.push({
|
|
2145
|
+
parent: X * 2,
|
|
2146
|
+
cells: P(L) ? at(o, L) : []
|
|
2147
|
+
}), ge;
|
|
2140
2148
|
}).flat();
|
|
2141
|
-
},
|
|
2149
|
+
}, Oe = (I) => ["string", "number"].includes(typeof I) ? I.toString() : I instanceof Array ? I.map(Oe).join("") : typeof I == "object" ? Oe(
|
|
2142
2150
|
Un(I.title) ? I.title.props : Object.values(I)
|
|
2143
|
-
) : "",
|
|
2144
|
-
() =>
|
|
2151
|
+
) : "", it = _(
|
|
2152
|
+
() => j === "" || r ? void 0 : lt(N || []).filter(
|
|
2145
2153
|
(I) => I.cells.some(
|
|
2146
|
-
(
|
|
2154
|
+
(P) => P && Oe(P).toLowerCase().includes(j.toLowerCase())
|
|
2147
2155
|
)
|
|
2148
|
-
).slice($, $ +
|
|
2149
|
-
[
|
|
2156
|
+
).slice($, $ + O + 1),
|
|
2157
|
+
[j, $, O]
|
|
2150
2158
|
);
|
|
2151
2159
|
ga(
|
|
2152
2160
|
async () => {
|
|
2153
|
-
|
|
2154
|
-
const I =
|
|
2155
|
-
return I &&
|
|
2161
|
+
f(!0);
|
|
2162
|
+
const I = tt.current === "" && j !== "";
|
|
2163
|
+
return I && se(0), tt.current = j, typeof c == "function" ? me === nt.current && N ? N : await c(I ? 0 : $, O + 1, j) : c;
|
|
2156
2164
|
},
|
|
2157
2165
|
(I) => {
|
|
2158
|
-
|
|
2159
|
-
const
|
|
2160
|
-
|
|
2166
|
+
nt.current = me, r || (K(I), I.length > $ ? I = I.slice($, $ + O + 1) : se(0));
|
|
2167
|
+
const P = lt(I);
|
|
2168
|
+
D(P), f(!1);
|
|
2161
2169
|
},
|
|
2162
2170
|
[
|
|
2163
|
-
|
|
2171
|
+
me,
|
|
2164
2172
|
$,
|
|
2165
|
-
|
|
2166
|
-
|
|
2167
|
-
typeof
|
|
2173
|
+
O,
|
|
2174
|
+
j,
|
|
2175
|
+
typeof c != "function" ? c : void 0
|
|
2168
2176
|
]
|
|
2169
2177
|
);
|
|
2170
|
-
const Jt = () =>
|
|
2171
|
-
await
|
|
2172
|
-
(
|
|
2173
|
-
) && (r ||
|
|
2174
|
-
}, I)), Yt = (I,
|
|
2175
|
-
|
|
2176
|
-
},
|
|
2177
|
-
return /* @__PURE__ */
|
|
2178
|
-
(!
|
|
2178
|
+
const Jt = () => d && pr(d).map((I, P) => (delete I.onRowClick, I.onClick = async (L, X) => {
|
|
2179
|
+
await d[P].onRowClick(
|
|
2180
|
+
(it || F)[X].data
|
|
2181
|
+
) && (r || Re(""), rt());
|
|
2182
|
+
}, I)), Yt = (I, P) => {
|
|
2183
|
+
Q[P].isOpen = I, D([...Q]);
|
|
2184
|
+
}, Q = it || F, fe = !Q || Q.length === 0, De = j !== "" || E, Qt = o ? O * 2 : O, Xt = o ? (Q?.length || 0) / 2 : Q?.length || 0;
|
|
2185
|
+
return /* @__PURE__ */ C(W, { children: [
|
|
2186
|
+
(!fe || De) && /* @__PURE__ */ C(
|
|
2179
2187
|
Ca,
|
|
2180
2188
|
{
|
|
2181
2189
|
id: zt,
|
|
2182
2190
|
count: Xt,
|
|
2183
2191
|
first: $,
|
|
2184
|
-
max:
|
|
2185
|
-
onNextClick:
|
|
2186
|
-
onPreviousClick:
|
|
2187
|
-
onPerPageSelect: (I,
|
|
2188
|
-
|
|
2192
|
+
max: O,
|
|
2193
|
+
onNextClick: se,
|
|
2194
|
+
onPreviousClick: se,
|
|
2195
|
+
onPerPageSelect: (I, P) => {
|
|
2196
|
+
se(I), ie(P), R(P);
|
|
2189
2197
|
},
|
|
2190
2198
|
inputGroupName: n ? `${e}input` : void 0,
|
|
2191
|
-
inputGroupOnEnter:
|
|
2199
|
+
inputGroupOnEnter: Re,
|
|
2192
2200
|
inputGroupPlaceholder: k(n || ""),
|
|
2193
|
-
searchTypeComponent:
|
|
2194
|
-
toolbarItem: /* @__PURE__ */
|
|
2195
|
-
|
|
2201
|
+
searchTypeComponent: y,
|
|
2202
|
+
toolbarItem: /* @__PURE__ */ C(W, { children: [
|
|
2203
|
+
v,
|
|
2196
2204
|
" ",
|
|
2197
|
-
/* @__PURE__ */ t(
|
|
2205
|
+
/* @__PURE__ */ t(H, { variant: "separator" }),
|
|
2198
2206
|
" ",
|
|
2199
|
-
/* @__PURE__ */ t(
|
|
2207
|
+
/* @__PURE__ */ t(H, { children: /* @__PURE__ */ C(V, { variant: "link", onClick: rt, "data-testid": "refresh", children: [
|
|
2200
2208
|
/* @__PURE__ */ t(dr, {}),
|
|
2201
2209
|
" ",
|
|
2202
2210
|
k("refresh")
|
|
2203
2211
|
] }) })
|
|
2204
2212
|
] }),
|
|
2205
|
-
subToolbar:
|
|
2213
|
+
subToolbar: x,
|
|
2206
2214
|
children: [
|
|
2207
|
-
!
|
|
2215
|
+
!M && !fe && /* @__PURE__ */ t(
|
|
2208
2216
|
Ia,
|
|
2209
2217
|
{
|
|
2210
|
-
...
|
|
2218
|
+
...T,
|
|
2211
2219
|
canSelectAll: l,
|
|
2212
2220
|
canSelect: !!a,
|
|
2213
|
-
selected:
|
|
2221
|
+
selected: b,
|
|
2214
2222
|
onSelect: (I) => {
|
|
2215
|
-
|
|
2223
|
+
S(I), a?.(I);
|
|
2216
2224
|
},
|
|
2217
|
-
onCollapse:
|
|
2225
|
+
onCollapse: o ? Yt : void 0,
|
|
2218
2226
|
actions: Jt(),
|
|
2219
|
-
actionResolver:
|
|
2220
|
-
rows:
|
|
2227
|
+
actionResolver: g,
|
|
2228
|
+
rows: Q.slice(0, Qt),
|
|
2221
2229
|
columns: h,
|
|
2222
2230
|
isNotCompact: i,
|
|
2223
|
-
isRadio:
|
|
2231
|
+
isRadio: s,
|
|
2224
2232
|
ariaLabelKey: e
|
|
2225
2233
|
}
|
|
2226
2234
|
),
|
|
2227
|
-
!
|
|
2228
|
-
|
|
2235
|
+
!M && fe && De && /* @__PURE__ */ t(
|
|
2236
|
+
ba,
|
|
2229
2237
|
{
|
|
2230
2238
|
hasIcon: !0,
|
|
2231
|
-
icon:
|
|
2239
|
+
icon: m,
|
|
2232
2240
|
isSearchVariant: !0,
|
|
2233
2241
|
message: k("noSearchResults"),
|
|
2234
2242
|
instructions: k("noSearchResultsInstructions"),
|
|
2235
|
-
secondaryActions:
|
|
2243
|
+
secondaryActions: E ? [] : [
|
|
2236
2244
|
{
|
|
2237
2245
|
text: k("clearAllFilters"),
|
|
2238
|
-
onClick: () =>
|
|
2239
|
-
type:
|
|
2246
|
+
onClick: () => Re(""),
|
|
2247
|
+
type: ke.link
|
|
2240
2248
|
}
|
|
2241
2249
|
]
|
|
2242
2250
|
}
|
|
@@ -2244,13 +2252,13 @@ function wa({
|
|
|
2244
2252
|
]
|
|
2245
2253
|
}
|
|
2246
2254
|
),
|
|
2247
|
-
|
|
2248
|
-
!
|
|
2255
|
+
M && /* @__PURE__ */ t(ya, {}),
|
|
2256
|
+
!M && fe && !De && p
|
|
2249
2257
|
] });
|
|
2250
2258
|
}
|
|
2251
2259
|
const xa = ({ link: e, organization: n }) => {
|
|
2252
|
-
const { t: r } =
|
|
2253
|
-
return /* @__PURE__ */ t(kr, { wrapModifier: "truncate", children: /* @__PURE__ */
|
|
2260
|
+
const { t: r } = q();
|
|
2261
|
+
return /* @__PURE__ */ t(kr, { wrapModifier: "truncate", children: /* @__PURE__ */ C(e, { organization: n, children: [
|
|
2254
2262
|
n.name,
|
|
2255
2263
|
!n.enabled && /* @__PURE__ */ t(
|
|
2256
2264
|
_n,
|
|
@@ -2262,17 +2270,17 @@ const xa = ({ link: e, organization: n }) => {
|
|
|
2262
2270
|
`${n.id}-disabled`
|
|
2263
2271
|
)
|
|
2264
2272
|
] }) });
|
|
2265
|
-
},
|
|
2266
|
-
const { t: n } =
|
|
2273
|
+
}, Sa = (e) => {
|
|
2274
|
+
const { t: n } = q();
|
|
2267
2275
|
return /* @__PURE__ */ t(
|
|
2268
|
-
|
|
2276
|
+
Je,
|
|
2269
2277
|
{
|
|
2270
2278
|
numChips: 2,
|
|
2271
2279
|
expandedText: n("hide"),
|
|
2272
2280
|
collapsedText: n("showRemaining"),
|
|
2273
2281
|
children: e.domains?.map((r) => {
|
|
2274
2282
|
const a = typeof r == "string" ? r : r.name;
|
|
2275
|
-
return /* @__PURE__ */ t(
|
|
2283
|
+
return /* @__PURE__ */ t(Ye, { isReadOnly: !0, children: a }, a);
|
|
2276
2284
|
})
|
|
2277
2285
|
}
|
|
2278
2286
|
);
|
|
@@ -2283,12 +2291,12 @@ const xa = ({ link: e, organization: n }) => {
|
|
|
2283
2291
|
isSearching: a = !1,
|
|
2284
2292
|
searchPlaceholderKey: l,
|
|
2285
2293
|
onSelect: i,
|
|
2286
|
-
onDelete:
|
|
2287
|
-
deleteLabel:
|
|
2294
|
+
onDelete: s,
|
|
2295
|
+
deleteLabel: o = "delete",
|
|
2288
2296
|
link: u,
|
|
2289
|
-
children:
|
|
2297
|
+
children: c
|
|
2290
2298
|
}) => {
|
|
2291
|
-
const { t: h } =
|
|
2299
|
+
const { t: h } = q();
|
|
2292
2300
|
return /* @__PURE__ */ t(
|
|
2293
2301
|
wa,
|
|
2294
2302
|
{
|
|
@@ -2300,22 +2308,22 @@ const xa = ({ link: e, organization: n }) => {
|
|
|
2300
2308
|
toolbarItem: n,
|
|
2301
2309
|
onSelect: i,
|
|
2302
2310
|
canSelectAll: i !== void 0,
|
|
2303
|
-
actions:
|
|
2311
|
+
actions: s ? [
|
|
2304
2312
|
{
|
|
2305
|
-
title: h(
|
|
2306
|
-
onRowClick:
|
|
2313
|
+
title: h(o),
|
|
2314
|
+
onRowClick: s
|
|
2307
2315
|
}
|
|
2308
2316
|
] : void 0,
|
|
2309
2317
|
columns: [
|
|
2310
2318
|
{
|
|
2311
2319
|
name: "name",
|
|
2312
2320
|
displayKey: "name",
|
|
2313
|
-
cellRenderer: (
|
|
2321
|
+
cellRenderer: (d) => /* @__PURE__ */ t(xa, { link: u, organization: d })
|
|
2314
2322
|
},
|
|
2315
2323
|
{
|
|
2316
2324
|
name: "domains",
|
|
2317
2325
|
displayKey: "domains",
|
|
2318
|
-
cellRenderer:
|
|
2326
|
+
cellRenderer: Sa
|
|
2319
2327
|
},
|
|
2320
2328
|
{
|
|
2321
2329
|
name: "description",
|
|
@@ -2326,7 +2334,7 @@ const xa = ({ link: e, organization: n }) => {
|
|
|
2326
2334
|
displayKey: "membershipType"
|
|
2327
2335
|
}
|
|
2328
2336
|
],
|
|
2329
|
-
emptyState:
|
|
2337
|
+
emptyState: c
|
|
2330
2338
|
}
|
|
2331
2339
|
);
|
|
2332
2340
|
};
|
|
@@ -2336,52 +2344,52 @@ export {
|
|
|
2336
2344
|
nl as ErrorBoundaryFallback,
|
|
2337
2345
|
tl as ErrorBoundaryProvider,
|
|
2338
2346
|
Fr as ErrorPage,
|
|
2339
|
-
|
|
2347
|
+
_t as FormErrorText,
|
|
2340
2348
|
zr as FormPanel,
|
|
2341
2349
|
Xa as FormSubmitButton,
|
|
2342
2350
|
Nr as Help,
|
|
2343
|
-
|
|
2351
|
+
qt as HelpItem,
|
|
2344
2352
|
Qa as IconMapper,
|
|
2345
2353
|
wa as KeycloakDataTable,
|
|
2346
2354
|
el as KeycloakMasthead,
|
|
2347
2355
|
qa as KeycloakProvider,
|
|
2348
|
-
|
|
2356
|
+
sa as KeycloakSelect,
|
|
2349
2357
|
ya as KeycloakSpinner,
|
|
2350
2358
|
Hr as KeycloakTextArea,
|
|
2351
|
-
|
|
2359
|
+
ba as ListEmptyState,
|
|
2352
2360
|
Ka as NumberControl,
|
|
2353
2361
|
rl as OrganizationTable,
|
|
2354
2362
|
Ca as PaginatingTableToolbar,
|
|
2355
2363
|
Ha as PasswordControl,
|
|
2356
|
-
|
|
2364
|
+
$t as PasswordInput,
|
|
2357
2365
|
Zr as ScrollForm,
|
|
2358
2366
|
$r as SelectControl,
|
|
2359
|
-
|
|
2367
|
+
ce as SelectVariant,
|
|
2360
2368
|
za as SwitchControl,
|
|
2361
|
-
|
|
2369
|
+
va as TableToolbar,
|
|
2362
2370
|
Ja as TextAreaControl,
|
|
2363
2371
|
Ya as TextControl,
|
|
2364
2372
|
Za as UserProfileFields,
|
|
2365
2373
|
Wa as beerify,
|
|
2366
|
-
|
|
2374
|
+
Xe as createNamedContext,
|
|
2367
2375
|
Kr as debeerify,
|
|
2368
|
-
|
|
2376
|
+
Tr as generateId,
|
|
2369
2377
|
xr as getErrorDescription,
|
|
2370
2378
|
wr as getErrorMessage,
|
|
2371
2379
|
$a as getInjectedEnvironment,
|
|
2372
|
-
|
|
2373
|
-
|
|
2374
|
-
|
|
2380
|
+
Lt as getNetworkErrorDescription,
|
|
2381
|
+
Sr as getNetworkErrorMessage,
|
|
2382
|
+
Er as isDefined,
|
|
2375
2383
|
Ga as isUserProfileError,
|
|
2376
|
-
|
|
2384
|
+
ee as label,
|
|
2377
2385
|
Xr as mainPageContentId,
|
|
2378
2386
|
ja as setUserProfileServerError,
|
|
2379
2387
|
Va as useAlerts,
|
|
2380
2388
|
_a as useEnvironment,
|
|
2381
|
-
|
|
2389
|
+
Wt as useErrorBoundary,
|
|
2382
2390
|
ga as useFetch,
|
|
2383
2391
|
Lr as useHelp,
|
|
2384
|
-
|
|
2385
|
-
|
|
2386
|
-
|
|
2392
|
+
Ze as useRequiredContext,
|
|
2393
|
+
Ar as useSetTimeout,
|
|
2394
|
+
Bt as useStoredState
|
|
2387
2395
|
};
|