@keycloak/keycloak-ui-shared 26.7.5 → 26.8.0

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