mirror of
https://github.com/keycloak/keycloak.git
synced 2026-01-10 15:32:05 -03:30
fixes: #39055 Signed-off-by: Erik Jan de Wit <erikjan.dewit@gmail.com> (cherry picked from commit 338ff88b06cb0c1af86387c0721c8eb58fc75818)
This commit is contained in:
parent
b4b6e086a3
commit
4411020cde
@ -215,6 +215,7 @@ export default function ClientDetails() {
|
||||
const form = useForm<FormFields>();
|
||||
const { clientId } = useParams<ClientParams>();
|
||||
const [key, setKey] = useState(0);
|
||||
const refresh = () => setKey(key + 1);
|
||||
|
||||
const isAdminPermissionsClient = useIsAdminPermissionsClient(clientId);
|
||||
|
||||
@ -465,6 +466,7 @@ export default function ClientDetails() {
|
||||
<Keys
|
||||
clientId={clientId}
|
||||
save={save}
|
||||
refresh={refresh}
|
||||
hasConfigureAccess={client.access?.configure}
|
||||
/>
|
||||
)}
|
||||
@ -487,7 +489,7 @@ export default function ClientDetails() {
|
||||
key={key}
|
||||
client={client}
|
||||
save={save}
|
||||
refresh={() => setKey(key + 1)}
|
||||
refresh={refresh}
|
||||
/>
|
||||
</Tab>
|
||||
)}
|
||||
|
||||
@ -29,13 +29,19 @@ import { ImportFile, ImportKeyDialog } from "./ImportKeyDialog";
|
||||
|
||||
type KeysProps = {
|
||||
save: () => void;
|
||||
refresh: () => void;
|
||||
clientId: string;
|
||||
hasConfigureAccess?: boolean;
|
||||
};
|
||||
|
||||
const attr = "jwt.credential";
|
||||
|
||||
export const Keys = ({ clientId, save, hasConfigureAccess }: KeysProps) => {
|
||||
export const Keys = ({
|
||||
clientId,
|
||||
save,
|
||||
refresh: refreshParent,
|
||||
hasConfigureAccess,
|
||||
}: KeysProps) => {
|
||||
const { adminClient } = useAdminClient();
|
||||
|
||||
const { t } = useTranslation();
|
||||
@ -51,7 +57,10 @@ export const Keys = ({ clientId, save, hasConfigureAccess }: KeysProps) => {
|
||||
useToggle();
|
||||
const [openImportKeys, toggleOpenImportKeys, setOpenImportKeys] = useToggle();
|
||||
const [key, setKey] = useState(0);
|
||||
const refresh = () => setKey(key + 1);
|
||||
const refresh = () => {
|
||||
setKey(key + 1);
|
||||
refreshParent();
|
||||
};
|
||||
|
||||
const useJwksUrl = useWatch({
|
||||
control,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user