diff --git a/src/realm-roles/AssociatedRolesTab.tsx b/src/realm-roles/AssociatedRolesTab.tsx index 14dafa8c4f..944ecdf648 100644 --- a/src/realm-roles/AssociatedRolesTab.tsx +++ b/src/realm-roles/AssociatedRolesTab.tsx @@ -21,7 +21,6 @@ import { useAdminClient } from "../context/auth/AdminClient"; import type { RoleFormType } from "./RealmRoleTabs"; import type ClientRepresentation from "keycloak-admin/lib/defs/clientRepresentation"; import _ from "lodash"; -import { filter } from "cypress/types/bluebird"; type AssociatedRolesTabProps = { additionalRoles: Role[]; @@ -127,15 +126,6 @@ export const AssociatedRolesTab = ({ )!.clientId!) ); - console.log(filterDupes - .filter((role) => role.clientRole) - .map( - (role) => - (role.clientId = clients.find( - (client) => client.id === role.containerId - )!.clientId!) - )) - return alphabetize(additionalRoles); }); }; diff --git a/src/realm-settings/GeneralTab.tsx b/src/realm-settings/GeneralTab.tsx index 8d0b924427..e5a0138f29 100644 --- a/src/realm-settings/GeneralTab.tsx +++ b/src/realm-settings/GeneralTab.tsx @@ -49,7 +49,6 @@ export const RealmSettingsGeneralTab = ({ return asyncStateFetch( () => adminClient.realms.findOne({ realm: realmName }), (realm) => { - console.log(realm) setRealm(realm); setupForm(realm); }, diff --git a/src/realm-settings/KeysTab.tsx b/src/realm-settings/KeysTab.tsx index 2d6b4e6f53..cf06fb670a 100644 --- a/src/realm-settings/KeysTab.tsx +++ b/src/realm-settings/KeysTab.tsx @@ -31,6 +31,7 @@ export const KeysTabInner = ({ keys }: KeysTabInnerProps) => { const [certificate, setCertificate] = useState(""); const loader = async () => { +<<<<<<< HEAD <<<<<<< HEAD return keys; }; @@ -87,6 +88,32 @@ export const KeysTabInner = ({ keys }: KeysTabInnerProps) => { const toggleModal = () => setOpen(!open); >>>>>>> keys +======= + return keys; + }; + + React.useEffect(() => { + refresh(); + }, [keys]); + + const [togglePublicKeyDialog, PublicKeyDialog] = useConfirmDialog({ + titleKey: t("realm-settings:publicKeys").slice(0, -1), + messageKey: publicKey, + continueButtonLabel: "common:close", + continueButtonVariant: ButtonVariant.primary, + noCancelButton: true, + onConfirm: async () => {}, + }); + + const [toggleCertificateDialog, CertificateDialog] = useConfirmDialog({ + titleKey: t("realm-settings:certificate"), + messageKey: certificate, + continueButtonLabel: "common:close", + continueButtonVariant: ButtonVariant.primary, + noCancelButton: true, + onConfirm: async () => {}, + }); +>>>>>>> adds keys table to realm settings const goToCreate = () => history.push(`${url}/add-role`); @@ -94,6 +121,7 @@ export const KeysTabInner = ({ keys }: KeysTabInnerProps) => { return <>{provider}; }; +<<<<<<< HEAD <<<<<<< HEAD const ButtonRenderer = ({ provider, publicKey, certificate }: KeyData) => { if (provider === "ecdsa-generated") { @@ -103,6 +131,10 @@ export const KeysTabInner = ({ keys }: KeysTabInnerProps) => { const ButtonRenderer = ({ name }: ComponentRepresentation) => { if (name === "ecdsa-generated") { >>>>>>> keys +======= + const ButtonRenderer = ({ provider, publicKey, certificate }: KeyData) => { + if (provider === "ecdsa-generated") { +>>>>>>> adds keys table to realm settings return ( <> ); +<<<<<<< HEAD } if (provider === "rsa-generated" || provider === "fallback-RS256") { +======= + } else if (provider === "rsa-generated" || provider === "fallback-RS256") { +>>>>>>> adds keys table to realm settings return ( <>