@keycloak/keycloak-admin-ui 26.2.4 → 26.3.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.
Files changed (56) hide show
  1. package/lib/.vite/manifest.json +42 -32
  2. package/lib/AddOAuth2-BdQ5f8j5.js +72 -0
  3. package/lib/AddOAuth2-BdQ5f8j5.js.map +1 -0
  4. package/lib/{CreateFlow-D4uM_8WC.js → CreateFlow-QW6oEhyd.js} +6 -6
  5. package/lib/{CreateFlow-D4uM_8WC.js.map → CreateFlow-QW6oEhyd.js.map} +1 -1
  6. package/lib/{DetailOrganization-COJeYoGE.js → DetailOrganization-BA1Z02u1.js} +46 -46
  7. package/lib/{DetailOrganization-COJeYoGE.js.map → DetailOrganization-BA1Z02u1.js.map} +1 -1
  8. package/lib/{ExecutorForm-BxTSytPh.js → ExecutorForm-BaJ7yk2s.js} +16 -16
  9. package/lib/{ExecutorForm-BxTSytPh.js.map → ExecutorForm-BaJ7yk2s.js.map} +1 -1
  10. package/lib/{FlowDetails-nR6R7QwB.js → FlowDetails-DBaoCEnX.js} +20 -17
  11. package/lib/{FlowDetails-nR6R7QwB.js.map → FlowDetails-DBaoCEnX.js.map} +1 -1
  12. package/lib/NewOrganization-Dz3NVBFR.js +36 -0
  13. package/lib/{NewOrganization-C8OgoMUL.js.map → NewOrganization-Dz3NVBFR.js.map} +1 -1
  14. package/lib/{PermissionConfigurationDetails-0hvEwSNW.js → PermissionConfigurationDetails-dIiFB9YL.js} +61 -61
  15. package/lib/{PermissionConfigurationDetails-0hvEwSNW.js.map → PermissionConfigurationDetails-dIiFB9YL.js.map} +1 -1
  16. package/lib/{PermissionDetails-ATEUBMrD.js → PermissionDetails-0JqG_vH7.js} +66 -66
  17. package/lib/{PermissionDetails-ATEUBMrD.js.map → PermissionDetails-0JqG_vH7.js.map} +1 -1
  18. package/lib/{RealmSection-DEj7Pofo.js → RealmSection-2ac_W3pw.js} +18 -18
  19. package/lib/{RealmSection-DEj7Pofo.js.map → RealmSection-2ac_W3pw.js.map} +1 -1
  20. package/lib/{ResourceDetails-C88S7tXu.js → ResourceDetails-CTjm-Bb1.js} +36 -36
  21. package/lib/{ResourceDetails-C88S7tXu.js.map → ResourceDetails-CTjm-Bb1.js.map} +1 -1
  22. package/lib/{ScopeDetails-BLW92hEw.js → ScopeDetails-BTzWF0ph.js} +12 -12
  23. package/lib/{ScopeDetails-BLW92hEw.js.map → ScopeDetails-BTzWF0ph.js.map} +1 -1
  24. package/lib/{ScopePicker-Cbywl8IC.js → ScopePicker-BOG72GXl.js} +15 -15
  25. package/lib/{ScopePicker-Cbywl8IC.js.map → ScopePicker-BOG72GXl.js.map} +1 -1
  26. package/lib/clients/keys/ImportKeyDialog.d.ts +1 -4
  27. package/lib/clients/keys/SamlImportKeyDialog.d.ts +2 -1
  28. package/lib/components/key-value-form/KeyValueInput.d.ts +11 -3
  29. package/lib/components/role-mapping/AddRoleMappingModal.d.ts +11 -1
  30. package/lib/context/realm-context/useHash.d.ts +1 -0
  31. package/lib/identity-providers/add/AddOAuth2.d.ts +1 -0
  32. package/lib/identity-providers/add/AdvancedSettings.d.ts +2 -1
  33. package/lib/identity-providers/add/DiscoverySettings.d.ts +2 -1
  34. package/lib/identity-providers/add/ExtendedOAuth2Settings.d.ts +1 -0
  35. package/lib/identity-providers/add/OAuth2UserProfileClaimsSettings.d.ts +1 -0
  36. package/lib/identity-providers/add/OpenIdConnectSettings.d.ts +5 -1
  37. package/lib/identity-providers/routes/IdentityProviderOAuth2.d.ts +2 -0
  38. package/lib/{index-Bd4uRM2j.js → index-Dcc2DpAw.js} +24573 -24379
  39. package/lib/{index-Bd4uRM2j.js.map → index-Dcc2DpAw.js.map} +1 -1
  40. package/lib/index.d.ts +2 -2
  41. package/lib/keycloak-admin-ui.css +1 -1
  42. package/lib/keycloak-admin-ui.js +39 -39
  43. package/lib/realm-settings/event-config/EventsTypeTable.d.ts +2 -1
  44. package/lib/realm-settings/security-defences/Time.d.ts +2 -1
  45. package/lib/realm-settings/themes/FileNameDialog.d.ts +6 -0
  46. package/lib/realm-settings/themes/ThemesTab.d.ts +1 -0
  47. package/lib/realm-settings/themes/UploadJar.d.ts +6 -0
  48. package/lib/realm-settings/user-profile/attribute/AddTranslationsDialog.d.ts +2 -1
  49. package/lib/{components/key-value-form → realm-settings/user-profile/attribute}/KeySelect.d.ts +2 -2
  50. package/lib/realm-settings/user-profile/attribute/TranslatableField.d.ts +2 -1
  51. package/lib/realm-settings/user-profile/attribute/ValueSelect.d.ts +6 -0
  52. package/lib/user/user-credentials/CredentialDataDialog.d.ts +2 -1
  53. package/lib/utils/useIsFeatureEnabled.d.ts +2 -1
  54. package/package.json +19 -18
  55. package/lib/NewOrganization-C8OgoMUL.js +0 -36
  56. package/lib/components/key-value-form/ValueSelect.d.ts +0 -8
@@ -1,5 +1,5 @@
1
- import { jsxs as u, Fragment as R, jsx as o } from "react/jsx-runtime";
2
- import { u as J, ao as V, V as Q, b7 as U, b as W, n as X, c as Y, P as Z, d as _, at as $, al as ee, am as te, an as oe, a4 as re, a7 as k, F as ae, a0 as ce, A as se, B as g, b8 as h, e as ne } from "./index-Bd4uRM2j.js";
1
+ import { jsxs as u, Fragment as M, jsx as o } from "react/jsx-runtime";
2
+ import { u as R, ao as k, _ as J, b7 as Q, b as U, y as W, V as X, P as Y, c as Z, au as $, al as ee, am as te, an as oe, a4 as re, a7 as V, F as ae, a0 as ce, A as se, B as g, b8 as h, d as ne } from "./index-Dcc2DpAw.js";
3
3
  import { useState as l } from "react";
4
4
  import { useTranslation as ie } from "react-i18next";
5
5
  import { useNavigate as le, Link as F } from "react-router-dom";
@@ -8,20 +8,20 @@ const I = {
8
8
  executor: ""
9
9
  };
10
10
  function ge() {
11
- const { adminClient: P } = J(), { t: c } = ie(), C = le(), { realm: d, profileName: n } = V(), { executorName: i } = V(), { addAlert: A, addError: H } = Q(), [N, T] = l(!1), x = U().componentTypes?.["org.keycloak.services.clientpolicy.executor.ClientPolicyExecutorProvider"], [f, O] = l([]), [B, G] = l([]), [v, D] = l([]), [L, j] = l([]), p = W({ defaultValues: I }), { control: w, reset: y, handleSubmit: q } = p, a = !!i, E = (e) => {
11
+ const { adminClient: P } = R(), { t: c } = ie(), C = le(), { realm: d, profileName: n } = k(), { executorName: i } = k(), { addAlert: A, addError: H } = J(), [N, T] = l(!1), x = Q().componentTypes?.["org.keycloak.services.clientpolicy.executor.ClientPolicyExecutorProvider"], [f, O] = l([]), [B, G] = l([]), [v, D] = l([]), [L, j] = l([]), p = U({ defaultValues: I }), { control: w, reset: y, handleSubmit: _ } = p, a = !!i, E = (e) => {
12
12
  const r = e.find((s) => s.name === n)?.executors?.find(
13
13
  (s) => s.executor === i
14
14
  );
15
15
  r && y({ config: r.configuration });
16
16
  };
17
- X(
17
+ W(
18
18
  () => P.clientPolicies.listProfiles({ includeGlobalProfiles: !0 }),
19
19
  (e) => {
20
20
  D(e.globalProfiles), j(e.profiles), E(e.profiles), E(e.globalProfiles);
21
21
  },
22
22
  []
23
23
  );
24
- const z = async () => {
24
+ const q = async () => {
25
25
  const e = p.getValues(), t = L.map((r) => {
26
26
  if (r.name !== n)
27
27
  return r;
@@ -31,7 +31,7 @@ function ge() {
31
31
  });
32
32
  if (a) {
33
33
  const S = r.executors.find(
34
- (M) => M.executor === i
34
+ (K) => K.executor === i
35
35
  );
36
36
  S.configuration = {
37
37
  ...S.configuration,
@@ -58,7 +58,7 @@ function ge() {
58
58
  (e) => e.name === n
59
59
  ), b = x?.find(
60
60
  (e) => e.id === i
61
- ), K = b?.properties.map(
61
+ ), z = b?.properties.map(
62
62
  (e) => {
63
63
  const t = a ? e.defaultValue : "";
64
64
  return {
@@ -67,17 +67,17 @@ function ge() {
67
67
  };
68
68
  }
69
69
  );
70
- return /* @__PURE__ */ u(R, { children: [
70
+ return /* @__PURE__ */ u(M, { children: [
71
71
  /* @__PURE__ */ o(
72
- Y,
72
+ X,
73
73
  {
74
74
  titleKey: a ? i : c("addExecutor"),
75
75
  divider: !0
76
76
  }
77
77
  ),
78
- /* @__PURE__ */ u(Z, { variant: "light", children: [
78
+ /* @__PURE__ */ u(Y, { variant: "light", children: [
79
79
  /* @__PURE__ */ u(
80
- _,
80
+ Z,
81
81
  {
82
82
  isHorizontal: !0,
83
83
  role: "manage-realm",
@@ -90,13 +90,13 @@ function ge() {
90
90
  label: c("executorType"),
91
91
  fieldId: "kc-executorType",
92
92
  labelIcon: f.length > 0 && f[0].helpText !== "" ? /* @__PURE__ */ o(
93
- k,
93
+ V,
94
94
  {
95
95
  helpText: f[0].helpText,
96
96
  fieldLabelId: "executorTypeHelpText"
97
97
  }
98
98
  ) : a ? /* @__PURE__ */ o(
99
- k,
99
+ V,
100
100
  {
101
101
  helpText: b?.helpText,
102
102
  fieldLabelId: "executorTypeHelpText"
@@ -150,7 +150,7 @@ function ge() {
150
150
  /* @__PURE__ */ o(ae, { ...p, children: /* @__PURE__ */ o(
151
151
  ce,
152
152
  {
153
- properties: a ? K : B
153
+ properties: a ? z : B
154
154
  }
155
155
  ) }),
156
156
  !m && /* @__PURE__ */ u(se, { children: [
@@ -158,7 +158,7 @@ function ge() {
158
158
  g,
159
159
  {
160
160
  variant: "primary",
161
- onClick: () => q(z)(),
161
+ onClick: () => _(q)(),
162
162
  "data-testid": "addExecutor-saveBtn",
163
163
  children: c(a ? "save" : "add")
164
164
  }
@@ -196,4 +196,4 @@ function ge() {
196
196
  export {
197
197
  ge as default
198
198
  };
199
- //# sourceMappingURL=ExecutorForm-BxTSytPh.js.map
199
+ //# sourceMappingURL=ExecutorForm-BaJ7yk2s.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ExecutorForm-BxTSytPh.js","sources":["../src/realm-settings/ExecutorForm.tsx"],"sourcesContent":["import type { ConfigPropertyRepresentation } from \"@keycloak/keycloak-admin-client/lib/defs/authenticatorConfigInfoRepresentation\";\nimport type ClientProfileRepresentation from \"@keycloak/keycloak-admin-client/lib/defs/clientProfileRepresentation\";\nimport type ComponentTypeRepresentation from \"@keycloak/keycloak-admin-client/lib/defs/componentTypeRepresentation\";\nimport {\n HelpItem,\n KeycloakSelect,\n SelectVariant,\n useAlerts,\n useFetch,\n} from \"@keycloak/keycloak-ui-shared\";\nimport {\n ActionGroup,\n AlertVariant,\n Button,\n FormGroup,\n PageSection,\n SelectOption,\n} from \"@patternfly/react-core\";\nimport { useState } from \"react\";\nimport { Controller, FormProvider, useForm } from \"react-hook-form\";\nimport { useTranslation } from \"react-i18next\";\nimport { Link, useNavigate } from \"react-router-dom\";\nimport { useAdminClient } from \"../admin-client\";\nimport { DynamicComponents } from \"../components/dynamic/DynamicComponents\";\nimport { FormAccess } from \"../components/form/FormAccess\";\nimport { ViewHeader } from \"../components/view-header/ViewHeader\";\nimport { useServerInfo } from \"../context/server-info/ServerInfoProvider\";\nimport { useParams } from \"../utils/useParams\";\nimport { ClientProfileParams, toClientProfile } from \"./routes/ClientProfile\";\nimport type { ExecutorParams } from \"./routes/Executor\";\n\ntype ExecutorForm = {\n config?: object;\n executor: string;\n};\n\nconst defaultValues: ExecutorForm = {\n config: {},\n executor: \"\",\n};\n\nexport default function ExecutorForm() {\n const { adminClient } = useAdminClient();\n\n const { t } = useTranslation();\n const navigate = useNavigate();\n const { realm, profileName } = useParams<ClientProfileParams>();\n const { executorName } = useParams<ExecutorParams>();\n const { addAlert, addError } = useAlerts();\n const [selectExecutorTypeOpen, setSelectExecutorTypeOpen] = useState(false);\n const serverInfo = useServerInfo();\n const executorTypes =\n serverInfo.componentTypes?.[\n \"org.keycloak.services.clientpolicy.executor.ClientPolicyExecutorProvider\"\n ];\n const [executors, setExecutors] = useState<ComponentTypeRepresentation[]>([]);\n const [executorProperties, setExecutorProperties] = useState<\n ConfigPropertyRepresentation[]\n >([]);\n const [globalProfiles, setGlobalProfiles] = useState<\n ClientProfileRepresentation[]\n >([]);\n const [profiles, setProfiles] = useState<ClientProfileRepresentation[]>([]);\n const form = useForm({ defaultValues });\n const { control, reset, handleSubmit } = form;\n const editMode = !!executorName;\n\n const setupForm = (profiles: ClientProfileRepresentation[]) => {\n const profile = profiles.find((profile) => profile.name === profileName);\n const executor = profile?.executors?.find(\n (executor) => executor.executor === executorName,\n );\n if (executor) reset({ config: executor.configuration });\n };\n\n useFetch(\n () =>\n adminClient.clientPolicies.listProfiles({ includeGlobalProfiles: true }),\n (profiles) => {\n setGlobalProfiles(profiles.globalProfiles!);\n setProfiles(profiles.profiles!);\n\n setupForm(profiles.profiles!);\n setupForm(profiles.globalProfiles!);\n },\n [],\n );\n\n const save = async () => {\n const formValues = form.getValues();\n const updatedProfiles = profiles.map((profile) => {\n if (profile.name !== profileName) {\n return profile;\n }\n\n const executors = (profile.executors ?? []).concat({\n executor: formValues.executor,\n configuration: formValues.config || {},\n });\n\n if (editMode) {\n const profileExecutor = profile.executors!.find(\n (executor) => executor.executor === executorName,\n );\n profileExecutor!.configuration = {\n ...profileExecutor!.configuration,\n ...formValues.config,\n };\n }\n\n if (editMode) {\n return profile;\n }\n return {\n ...profile,\n executors,\n };\n });\n try {\n await adminClient.clientPolicies.createProfiles({\n profiles: updatedProfiles,\n globalProfiles: globalProfiles,\n });\n addAlert(\n editMode ? t(\"updateExecutorSuccess\") : t(\"addExecutorSuccess\"),\n AlertVariant.success,\n );\n\n navigate(toClientProfile({ realm, profileName }));\n } catch (error) {\n addError(editMode ? \"updateExecutorError\" : \"addExecutorError\", error);\n }\n };\n\n const globalProfile = globalProfiles.find(\n (globalProfile) => globalProfile.name === profileName,\n );\n\n const profileExecutorType = executorTypes?.find(\n (executor) => executor.id === executorName,\n );\n\n const editedProfileExecutors =\n profileExecutorType?.properties.map<ConfigPropertyRepresentation>(\n (property) => {\n const globalDefaultValues = editMode ? property.defaultValue : \"\";\n return {\n ...property,\n defaultValue: globalDefaultValues,\n };\n },\n );\n\n return (\n <>\n <ViewHeader\n titleKey={editMode ? executorName : t(\"addExecutor\")}\n divider\n />\n <PageSection variant=\"light\">\n <FormAccess\n isHorizontal\n role=\"manage-realm\"\n className=\"pf-v5-u-mt-lg\"\n isReadOnly={!!globalProfile}\n >\n <FormGroup\n label={t(\"executorType\")}\n fieldId=\"kc-executorType\"\n labelIcon={\n executors.length > 0 && executors[0].helpText! !== \"\" ? (\n <HelpItem\n helpText={executors[0].helpText}\n fieldLabelId=\"executorTypeHelpText\"\n />\n ) : editMode ? (\n <HelpItem\n helpText={profileExecutorType?.helpText}\n fieldLabelId=\"executorTypeHelpText\"\n />\n ) : undefined\n }\n >\n <Controller\n name=\"executor\"\n defaultValue=\"\"\n control={control}\n render={({ field }) => (\n <KeycloakSelect\n toggleId=\"kc-executor\"\n placeholderText=\"Select an executor\"\n onToggle={(isOpen) => setSelectExecutorTypeOpen(isOpen)}\n onSelect={(value) => {\n reset({ ...defaultValues, executor: value.toString() });\n const selectedExecutor = executorTypes?.filter(\n (type) => type.id === value,\n );\n setExecutors(selectedExecutor ?? []);\n setExecutorProperties(\n selectedExecutor?.[0].properties ?? [],\n );\n setSelectExecutorTypeOpen(false);\n }}\n selections={editMode ? executorName : field.value}\n variant={SelectVariant.single}\n data-testid=\"executorType-select\"\n aria-label={t(\"executorType\")}\n isOpen={selectExecutorTypeOpen}\n maxHeight={580}\n isDisabled={editMode}\n >\n {executorTypes?.map((option) => (\n <SelectOption\n data-testid={option.id}\n selected={option.id === field.value}\n key={option.id}\n value={option.id}\n description={option.helpText}\n >\n {option.id}\n </SelectOption>\n ))}\n </KeycloakSelect>\n )}\n />\n </FormGroup>\n <FormProvider {...form}>\n <DynamicComponents\n properties={\n editMode ? editedProfileExecutors! : executorProperties\n }\n />\n </FormProvider>\n {!globalProfile && (\n <ActionGroup>\n <Button\n variant=\"primary\"\n onClick={() => handleSubmit(save)()}\n data-testid=\"addExecutor-saveBtn\"\n >\n {editMode ? t(\"save\") : t(\"add\")}\n </Button>\n <Button\n variant=\"link\"\n component={(props) => (\n <Link\n {...props}\n to={toClientProfile({ realm, profileName })}\n />\n )}\n data-testid=\"addExecutor-cancelBtn\"\n >\n {t(\"cancel\")}\n </Button>\n </ActionGroup>\n )}\n </FormAccess>\n {editMode && globalProfile && (\n <div className=\"kc-backToProfile\">\n <Button\n component={(props) => (\n <Link {...props} to={toClientProfile({ realm, profileName })} />\n )}\n variant=\"primary\"\n >\n {t(\"back\")}\n </Button>\n </div>\n )}\n </PageSection>\n </>\n );\n}\n"],"names":["defaultValues","ExecutorForm","adminClient","useAdminClient","t","useTranslation","navigate","useNavigate","realm","profileName","useParams","executorName","addAlert","addError","useAlerts","selectExecutorTypeOpen","setSelectExecutorTypeOpen","useState","executorTypes","useServerInfo","executors","setExecutors","executorProperties","setExecutorProperties","globalProfiles","setGlobalProfiles","profiles","setProfiles","form","useForm","control","reset","handleSubmit","editMode","setupForm","executor","profile","useFetch","save","formValues","updatedProfiles","profileExecutor","AlertVariant","toClientProfile","error","globalProfile","profileExecutorType","editedProfileExecutors","property","globalDefaultValues","jsxs","Fragment","jsx","ViewHeader","PageSection","FormAccess","FormGroup","HelpItem","Controller","field","KeycloakSelect","isOpen","value","selectedExecutor","type","SelectVariant","option","SelectOption","FormProvider","DynamicComponents","ActionGroup","Button","props","Link"],"mappings":";;;;;AAoCA,MAAMA,IAA8B;AAAA,EAClC,QAAQ,CAAC;AAAA,EACT,UAAU;AACZ;AAEA,SAAwBC,KAAe;AAC/B,QAAA,EAAE,aAAAC,EAAY,IAAIC,EAAe,GAEjC,EAAE,GAAAC,EAAE,IAAIC,GAAe,GACvBC,IAAWC,GAAY,GACvB,EAAE,OAAAC,GAAO,aAAAC,EAAY,IAAIC,EAA+B,GACxD,EAAE,cAAAC,EAAa,IAAID,EAA0B,GAC7C,EAAE,UAAAE,GAAU,UAAAC,EAAS,IAAIC,EAAU,GACnC,CAACC,GAAwBC,CAAyB,IAAIC,EAAS,EAAK,GAEpEC,IADaC,EAAc,EAEpB,iBACT,0EACF,GACI,CAACC,GAAWC,CAAY,IAAIJ,EAAwC,CAAA,CAAE,GACtE,CAACK,GAAoBC,CAAqB,IAAIN,EAElD,CAAA,CAA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,EAAA,CAAa,EAAG,CAAA;AAAA,UAEhE,SAAQ;AAAA,UAEP,YAAE,MAAM;AAAA,QAAA;AAAA,MAAA,EAEb,CAAA;AAAA,IAAA,EAEJ,CAAA;AAAA,EAAA,GACF;AAEJ;"}
1
+ {"version":3,"file":"ExecutorForm-BaJ7yk2s.js","sources":["../src/realm-settings/ExecutorForm.tsx"],"sourcesContent":["import type { ConfigPropertyRepresentation } from \"@keycloak/keycloak-admin-client/lib/defs/authenticatorConfigInfoRepresentation\";\nimport type ClientProfileRepresentation from \"@keycloak/keycloak-admin-client/lib/defs/clientProfileRepresentation\";\nimport type ComponentTypeRepresentation from \"@keycloak/keycloak-admin-client/lib/defs/componentTypeRepresentation\";\nimport {\n HelpItem,\n KeycloakSelect,\n SelectVariant,\n useAlerts,\n useFetch,\n} from \"@keycloak/keycloak-ui-shared\";\nimport {\n ActionGroup,\n AlertVariant,\n Button,\n FormGroup,\n PageSection,\n SelectOption,\n} from \"@patternfly/react-core\";\nimport { useState } from \"react\";\nimport { Controller, FormProvider, useForm } from \"react-hook-form\";\nimport { useTranslation } from \"react-i18next\";\nimport { Link, useNavigate } from \"react-router-dom\";\nimport { useAdminClient } from \"../admin-client\";\nimport { DynamicComponents } from \"../components/dynamic/DynamicComponents\";\nimport { FormAccess } from \"../components/form/FormAccess\";\nimport { ViewHeader } from \"../components/view-header/ViewHeader\";\nimport { useServerInfo } from \"../context/server-info/ServerInfoProvider\";\nimport { useParams } from \"../utils/useParams\";\nimport { ClientProfileParams, toClientProfile } from \"./routes/ClientProfile\";\nimport type { ExecutorParams } from \"./routes/Executor\";\n\ntype ExecutorForm = {\n config?: object;\n executor: string;\n};\n\nconst defaultValues: ExecutorForm = {\n config: {},\n executor: \"\",\n};\n\nexport default function ExecutorForm() {\n const { adminClient } = useAdminClient();\n\n const { t } = useTranslation();\n const navigate = useNavigate();\n const { realm, profileName } = useParams<ClientProfileParams>();\n const { executorName } = useParams<ExecutorParams>();\n const { addAlert, addError } = useAlerts();\n const [selectExecutorTypeOpen, setSelectExecutorTypeOpen] = useState(false);\n const serverInfo = useServerInfo();\n const executorTypes =\n serverInfo.componentTypes?.[\n \"org.keycloak.services.clientpolicy.executor.ClientPolicyExecutorProvider\"\n ];\n const [executors, setExecutors] = useState<ComponentTypeRepresentation[]>([]);\n const [executorProperties, setExecutorProperties] = useState<\n ConfigPropertyRepresentation[]\n >([]);\n const [globalProfiles, setGlobalProfiles] = useState<\n ClientProfileRepresentation[]\n >([]);\n const [profiles, setProfiles] = useState<ClientProfileRepresentation[]>([]);\n const form = useForm({ defaultValues });\n const { control, reset, handleSubmit } = form;\n const editMode = !!executorName;\n\n const setupForm = (profiles: ClientProfileRepresentation[]) => {\n const profile = profiles.find((profile) => profile.name === profileName);\n const executor = profile?.executors?.find(\n (executor) => executor.executor === executorName,\n );\n if (executor) reset({ config: executor.configuration });\n };\n\n useFetch(\n () =>\n adminClient.clientPolicies.listProfiles({ includeGlobalProfiles: true }),\n (profiles) => {\n setGlobalProfiles(profiles.globalProfiles!);\n setProfiles(profiles.profiles!);\n\n setupForm(profiles.profiles!);\n setupForm(profiles.globalProfiles!);\n },\n [],\n );\n\n const save = async () => {\n const formValues = form.getValues();\n const updatedProfiles = profiles.map((profile) => {\n if (profile.name !== profileName) {\n return profile;\n }\n\n const executors = (profile.executors ?? []).concat({\n executor: formValues.executor,\n configuration: formValues.config || {},\n });\n\n if (editMode) {\n const profileExecutor = profile.executors!.find(\n (executor) => executor.executor === executorName,\n );\n profileExecutor!.configuration = {\n ...profileExecutor!.configuration,\n ...formValues.config,\n };\n }\n\n if (editMode) {\n return profile;\n }\n return {\n ...profile,\n executors,\n };\n });\n try {\n await adminClient.clientPolicies.createProfiles({\n profiles: updatedProfiles,\n globalProfiles: globalProfiles,\n });\n addAlert(\n editMode ? t(\"updateExecutorSuccess\") : t(\"addExecutorSuccess\"),\n AlertVariant.success,\n );\n\n navigate(toClientProfile({ realm, profileName }));\n } catch (error) {\n addError(editMode ? \"updateExecutorError\" : \"addExecutorError\", error);\n }\n };\n\n const globalProfile = globalProfiles.find(\n (globalProfile) => globalProfile.name === profileName,\n );\n\n const profileExecutorType = executorTypes?.find(\n (executor) => executor.id === executorName,\n );\n\n const editedProfileExecutors =\n profileExecutorType?.properties.map<ConfigPropertyRepresentation>(\n (property) => {\n const globalDefaultValues = editMode ? property.defaultValue : \"\";\n return {\n ...property,\n defaultValue: globalDefaultValues,\n };\n },\n );\n\n return (\n <>\n <ViewHeader\n titleKey={editMode ? executorName : t(\"addExecutor\")}\n divider\n />\n <PageSection variant=\"light\">\n <FormAccess\n isHorizontal\n role=\"manage-realm\"\n className=\"pf-v5-u-mt-lg\"\n isReadOnly={!!globalProfile}\n >\n <FormGroup\n label={t(\"executorType\")}\n fieldId=\"kc-executorType\"\n labelIcon={\n executors.length > 0 && executors[0].helpText! !== \"\" ? (\n <HelpItem\n helpText={executors[0].helpText}\n fieldLabelId=\"executorTypeHelpText\"\n />\n ) : editMode ? (\n <HelpItem\n helpText={profileExecutorType?.helpText}\n fieldLabelId=\"executorTypeHelpText\"\n />\n ) : undefined\n }\n >\n <Controller\n name=\"executor\"\n defaultValue=\"\"\n control={control}\n render={({ field }) => (\n <KeycloakSelect\n toggleId=\"kc-executor\"\n placeholderText=\"Select an executor\"\n onToggle={(isOpen) => setSelectExecutorTypeOpen(isOpen)}\n onSelect={(value) => {\n reset({ ...defaultValues, executor: value.toString() });\n const selectedExecutor = executorTypes?.filter(\n (type) => type.id === value,\n );\n setExecutors(selectedExecutor ?? []);\n setExecutorProperties(\n selectedExecutor?.[0].properties ?? [],\n );\n setSelectExecutorTypeOpen(false);\n }}\n selections={editMode ? executorName : field.value}\n variant={SelectVariant.single}\n data-testid=\"executorType-select\"\n aria-label={t(\"executorType\")}\n isOpen={selectExecutorTypeOpen}\n maxHeight={580}\n isDisabled={editMode}\n >\n {executorTypes?.map((option) => (\n <SelectOption\n data-testid={option.id}\n selected={option.id === field.value}\n key={option.id}\n value={option.id}\n description={option.helpText}\n >\n {option.id}\n </SelectOption>\n ))}\n </KeycloakSelect>\n )}\n />\n </FormGroup>\n <FormProvider {...form}>\n <DynamicComponents\n properties={\n editMode ? editedProfileExecutors! : executorProperties\n }\n />\n </FormProvider>\n {!globalProfile && (\n <ActionGroup>\n <Button\n variant=\"primary\"\n onClick={() => handleSubmit(save)()}\n data-testid=\"addExecutor-saveBtn\"\n >\n {editMode ? t(\"save\") : t(\"add\")}\n </Button>\n <Button\n variant=\"link\"\n component={(props) => (\n <Link\n {...props}\n to={toClientProfile({ realm, profileName })}\n />\n )}\n data-testid=\"addExecutor-cancelBtn\"\n >\n {t(\"cancel\")}\n </Button>\n </ActionGroup>\n )}\n </FormAccess>\n {editMode && globalProfile && (\n <div className=\"kc-backToProfile\">\n <Button\n component={(props) => (\n <Link {...props} to={toClientProfile({ realm, profileName })} />\n )}\n variant=\"primary\"\n >\n {t(\"back\")}\n </Button>\n </div>\n )}\n </PageSection>\n </>\n );\n}\n"],"names":["defaultValues","ExecutorForm","adminClient","useAdminClient","t","useTranslation","navigate","useNavigate","realm","profileName","useParams","executorName","addAlert","addError","useAlerts","selectExecutorTypeOpen","setSelectExecutorTypeOpen","useState","executorTypes","useServerInfo","executors","setExecutors","executorProperties","setExecutorProperties","globalProfiles","setGlobalProfiles","profiles","setProfiles","form","useForm","control","reset","handleSubmit","editMode","setupForm","executor","profile","useFetch","save","formValues","updatedProfiles","profileExecutor","AlertVariant","toClientProfile","error","globalProfile","profileExecutorType","editedProfileExecutors","property","globalDefaultValues","jsxs","Fragment","jsx","ViewHeader","PageSection","FormAccess","FormGroup","HelpItem","Controller","field","KeycloakSelect","isOpen","value","selectedExecutor","type","SelectVariant","option","SelectOption","FormProvider","DynamicComponents","ActionGroup","Button","props","Link"],"mappings":";;;;;AAoCA,MAAMA,IAA8B;AAAA,EAClC,QAAQ,CAAA;AAAA,EACR,UAAU;AACZ;AAEA,SAAwBC,KAAe;AACrC,QAAM,EAAE,aAAAC,EAAA,IAAgBC,EAA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7B,EAAgB,EAAE,OAAAnC,GAAO,aAAAC,GAAa;AAAA,oBAAA;AAAA,kBAAA;AAAA,kBAG9C,eAAY;AAAA,kBAEX,YAAE,QAAQ;AAAA,gBAAA;AAAA,cAAA;AAAA,YACb,EAAA,CACF;AAAA,UAAA;AAAA,QAAA;AAAA,MAAA;AAAA,MAGHwB,KAAYY,KACX,gBAAAO,EAAC,OAAA,EAAI,WAAU,oBACb,UAAA,gBAAAA;AAAA,QAACmB;AAAA,QAAA;AAAA,UACC,WAAW,CAACC,MACV,gBAAApB,EAACqB,GAAA,EAAM,GAAGD,GAAO,IAAI7B,EAAgB,EAAE,OAAAnC,GAAO,aAAAC,EAAA,CAAa,EAAA,CAAG;AAAA,UAEhE,SAAQ;AAAA,UAEP,YAAE,MAAM;AAAA,QAAA;AAAA,MAAA,EACX,CACF;AAAA,IAAA,EAAA,CAEJ;AAAA,EAAA,GACF;AAEJ;"}
@@ -1,5 +1,5 @@
1
1
  import { jsx as T, jsxs as te, Fragment as be } from "react/jsx-runtime";
2
- import { g as Wt, _ as Lo, h as Dt, T as ia, i as Oc, s as Ac, L as Io, C as Tc, u as mt, V as Oo, b as zn, M as nn, j as rn, F as Vn, k as on, N as Dc, B as ge, l as Je, e as We, m as Rc, n as Rt, o as Pc, p as $c, P as sa, R as Fc, Y as Cn, $ as si, q as zc, r as ai, v as li, w as Vc, x as Hc, y as Bc, Z as qc, z as Gc, D as aa, E as Ye, G as Yc, H as Hn, I as jc, J as Wc, K as lt, O as la, Q as co, S as Xc, U as Zc, W as Uc, a0 as Kc, A as Qc, a1 as ca, a2 as Jc, a3 as eu, a4 as tu, a5 as nu, a6 as ru, a7 as ou, a8 as iu, a9 as Ve, a as su, aa as ci, ab as au, f as lu, ac as cu, c as uu, ad as du, ae as fu, af as tr, ag as hu, ah as pu, ai as gu, aj as mu, t as yu } from "./index-Bd4uRM2j.js";
2
+ import { g as Wt, h as Lo, i as Dt, T as ia, j as Oc, s as Ac, L as Io, C as Tc, u as mt, _ as Oo, b as zn, M as nn, k as rn, F as Vn, l as on, N as Dc, B as ge, m as Je, d as We, n as Rc, y as Rt, o as Pc, p as $c, P as sa, R as Fc, Q as Cn, $ as si, v as zc, q as ai, r as li, w as Vc, x as Hc, X as Bc, Z as qc, z as Gc, D as aa, E as Ye, G as Yc, H as Hn, I as jc, J as Wc, K as lt, O as la, S as co, U as Xc, Y as Zc, W as Uc, a0 as Kc, A as Qc, a1 as ca, a2 as Jc, a3 as eu, a4 as tu, a5 as nu, a6 as ru, a7 as ou, a8 as iu, a9 as Ve, a as su, aa as ci, t as au, ab as lu, f as cu, ac as uu, V as du, ad as fu, ae as hu, af as tr, ag as pu, ah as gu, ai as mu, aj as yu } from "./index-Dcc2DpAw.js";
3
3
  import * as Re from "react";
4
4
  import $, { useEffect as oe, useState as re, useMemo as Ne, forwardRef as ua, useCallback as de, memo as ae, useContext as Bn, createContext as da, useRef as Q } from "react";
5
5
  import { useTranslation as _e, Trans as ui } from "react-i18next";
@@ -6564,10 +6564,8 @@ function fe() {
6564
6564
  zipObject: D
6565
6565
  };
6566
6566
  function t(E, _, N, M) {
6567
- let O;
6568
- do
6567
+ for (var O = M; E.hasNode(O); )
6569
6568
  O = x(M);
6570
- while (E.hasNode(O));
6571
6569
  return N.dummy = _, E.setNode(O, N), O;
6572
6570
  }
6573
6571
  function n(E) {
@@ -6691,7 +6689,7 @@ function fe() {
6691
6689
  let w = 0;
6692
6690
  function x(E) {
6693
6691
  var _ = ++w;
6694
- return toString(E) + _;
6692
+ return E + ("" + _);
6695
6693
  }
6696
6694
  function b(E, _, N = 1) {
6697
6695
  _ == null && (_ = E, E = 0);
@@ -6932,6 +6930,9 @@ function l0() {
6932
6930
  var e = $n(), t = e.longestPath, n = Wl(), r = a0();
6933
6931
  qr = o;
6934
6932
  function o(c) {
6933
+ var u = c.graph().ranker;
6934
+ if (u instanceof Function)
6935
+ return u(c);
6935
6936
  switch (c.graph().ranker) {
6936
6937
  case "network-simplex":
6937
6938
  a(c);
@@ -6942,6 +6943,8 @@ function l0() {
6942
6943
  case "longest-path":
6943
6944
  s(c);
6944
6945
  break;
6946
+ case "none":
6947
+ break;
6945
6948
  default:
6946
6949
  a(c);
6947
6950
  }
@@ -7638,7 +7641,7 @@ function S0() {
7638
7641
  B.points = V.points, Object.hasOwn(V, "x") && (B.x = V.x, B.y = V.y);
7639
7642
  }), k.graph().width = I.graph().width, k.graph().height = I.graph().height;
7640
7643
  }
7641
- let g = ["nodesep", "edgesep", "ranksep", "marginx", "marginy"], m = { ranksep: 50, edgesep: 20, nodesep: 50, rankdir: "tb" }, w = ["acyclicer", "ranker", "rankdir", "align"], x = ["width", "height"], b = { width: 0, height: 0 }, C = ["minlen", "weight", "width", "height", "labeloffset"], S = {
7644
+ let g = ["nodesep", "edgesep", "ranksep", "marginx", "marginy"], m = { ranksep: 50, edgesep: 20, nodesep: 50, rankdir: "tb" }, w = ["acyclicer", "ranker", "rankdir", "align"], x = ["width", "height", "rank"], b = { width: 0, height: 0 }, C = ["minlen", "weight", "width", "height", "labeloffset"], S = {
7642
7645
  minlen: 1,
7643
7646
  weight: 1,
7644
7647
  width: 0,
@@ -7827,7 +7830,7 @@ function C0() {
7827
7830
  }
7828
7831
  var ao, Qs;
7829
7832
  function N0() {
7830
- return Qs || (Qs = 1, ao = "1.1.4"), ao;
7833
+ return Qs || (Qs = 1, ao = "1.1.5"), ao;
7831
7834
  }
7832
7835
  var lo, Js;
7833
7836
  function k0() {
@@ -8801,7 +8804,7 @@ function ly() {
8801
8804
  try {
8802
8805
  await e.authenticationManagement.deleteFlow({
8803
8806
  flowId: p.id
8804
- }), c(yu({ realm: n })), r(t("deleteFlowSuccess"), We.success);
8807
+ }), c(au({ realm: n })), r(t("deleteFlowSuccess"), We.success);
8805
8808
  } catch (V) {
8806
8809
  o("deleteFlowError", V);
8807
8810
  }
@@ -8844,12 +8847,12 @@ function ly() {
8844
8847
  ];
8845
8848
  return /* @__PURE__ */ te(zu, { children: [
8846
8849
  A && /* @__PURE__ */ T(
8847
- au,
8850
+ lu,
8848
8851
  {
8849
8852
  flowAlias: p?.alias,
8850
8853
  onClose: (V) => {
8851
8854
  L(), c(
8852
- lu({
8855
+ cu({
8853
8856
  realm: n,
8854
8857
  id: s,
8855
8858
  usedBy: V ? "DEFAULT" : "notInUse",
@@ -8860,7 +8863,7 @@ function ly() {
8860
8863
  }
8861
8864
  ),
8862
8865
  N && /* @__PURE__ */ T(
8863
- cu,
8866
+ uu,
8864
8867
  {
8865
8868
  name: p?.alias,
8866
8869
  description: p?.description,
@@ -8881,7 +8884,7 @@ function ly() {
8881
8884
  ),
8882
8885
  /* @__PURE__ */ T(I, {}),
8883
8886
  /* @__PURE__ */ T(
8884
- uu,
8887
+ du,
8885
8888
  {
8886
8889
  titleKey: p?.alias || "",
8887
8890
  badges: [
@@ -8896,7 +8899,7 @@ function ly() {
8896
8899
  ),
8897
8900
  /* @__PURE__ */ te(sa, { variant: "light", children: [
8898
8901
  g && P && /* @__PURE__ */ te(be, { children: [
8899
- /* @__PURE__ */ T(du, { id: "toolbar", children: /* @__PURE__ */ te(fu, { children: [
8902
+ /* @__PURE__ */ T(fu, { id: "toolbar", children: /* @__PURE__ */ te(hu, { children: [
8900
8903
  /* @__PURE__ */ T(tr, { children: /* @__PURE__ */ te(fa, { children: [
8901
8904
  /* @__PURE__ */ T(
8902
8905
  kn,
@@ -8940,7 +8943,7 @@ function ly() {
8940
8943
  ] }) }),
8941
8944
  /* @__PURE__ */ T(j, {}),
8942
8945
  f && /* @__PURE__ */ T(
8943
- hu,
8946
+ pu,
8944
8947
  {
8945
8948
  onDrag: ({ index: V }) => {
8946
8949
  const Y = g.findExecution(V);
@@ -8963,9 +8966,9 @@ function ly() {
8963
8966
  } else
8964
8967
  return x(t("onDragCancel")), !1;
8965
8968
  },
8966
- children: /* @__PURE__ */ T(pu, { hasNoWrapper: !0, children: /* @__PURE__ */ te(gu, { "aria-label": t("flows"), isTreeTable: !0, children: [
8969
+ children: /* @__PURE__ */ T(gu, { hasNoWrapper: !0, children: /* @__PURE__ */ te(mu, { "aria-label": t("flows"), isTreeTable: !0, children: [
8967
8970
  /* @__PURE__ */ T(W0, {}),
8968
- /* @__PURE__ */ T(be, { children: g.expandableList.map((V) => /* @__PURE__ */ T(mu, { draggable: !0, children: /* @__PURE__ */ T(
8971
+ /* @__PURE__ */ T(be, { children: g.expandableList.map((V) => /* @__PURE__ */ T(yu, { draggable: !0, children: /* @__PURE__ */ T(
8969
8972
  Ul,
8970
8973
  {
8971
8974
  builtIn: !!a,
@@ -9024,4 +9027,4 @@ export {
9024
9027
  ly as default,
9025
9028
  Fn as providerConditionFilter
9026
9029
  };
9027
- //# sourceMappingURL=FlowDetails-nR6R7QwB.js.map
9030
+ //# sourceMappingURL=FlowDetails-DBaoCEnX.js.map