Show OpenID4VCI Credential Issuer Metadata link in admin ui (#32968) (#32969)

Fixes #32968

Signed-off-by: Thomas Darimont <thomas.darimont@googlemail.com>
This commit is contained in:
Thomas Darimont 2024-09-17 14:16:14 +02:00 committed by GitHub
parent cf90247441
commit d5fb919dcd
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 13 additions and 0 deletions

View file

@ -1636,6 +1636,7 @@ notVerified=Not verified
encryptionKeysConfig=Encryption keys config encryptionKeysConfig=Encryption keys config
updateClientProfileSuccess=Client profile updated successfully updateClientProfileSuccess=Client profile updated successfully
openIDEndpointConfiguration=OpenID Endpoint Configuration openIDEndpointConfiguration=OpenID Endpoint Configuration
oid4vcIssuerMetadata=OpenID4VCI Credential Issuer Metadata
prompts.login=Login prompts.login=Login
users=Users users=Users
keyTabHelp=Location of Kerberos KeyTab file containing the credentials of server principal. For example, /etc/krb5.keytab keyTabHelp=Location of Kerberos KeyTab file containing the credentials of server principal. For example, /etc/krb5.keytab

View file

@ -110,6 +110,7 @@ function RealmSettingsGeneralTabForm({
} = form; } = form;
const isFeatureEnabled = useIsFeatureEnabled(); const isFeatureEnabled = useIsFeatureEnabled();
const isOrganizationsEnabled = isFeatureEnabled(Feature.Organizations); const isOrganizationsEnabled = isFeatureEnabled(Feature.Organizations);
const isOpenid4vciEnabled = isFeatureEnabled(Feature.OpenId4VCI);
const setupForm = () => { const setupForm = () => {
convertToFormValues(realm, setValue); convertToFormValues(realm, setValue);
@ -265,6 +266,16 @@ function RealmSettingsGeneralTabForm({
title={t("samlIdentityProviderMetadata")} title={t("samlIdentityProviderMetadata")}
/> />
</StackItem> </StackItem>
{isOpenid4vciEnabled && (
<StackItem>
<FormattedLink
href={`${addTrailingSlash(
serverBaseUrl,
)}realms/${realmName}/.well-known/openid-credential-issuer`}
title={t("oid4vcIssuerMetadata")}
/>
</StackItem>
)}
</Stack> </Stack>
</FormGroup> </FormGroup>
<FixedButtonsGroup <FixedButtonsGroup

View file

@ -11,6 +11,7 @@ export enum Feature {
ClientTypes = "CLIENT_TYPES", ClientTypes = "CLIENT_TYPES",
DeclarativeUI = "DECLARATIVE_UI", DeclarativeUI = "DECLARATIVE_UI",
Organizations = "ORGANIZATION", Organizations = "ORGANIZATION",
OpenId4VCI = "OID4VC_VCI",
} }
export default function useIsFeatureEnabled() { export default function useIsFeatureEnabled() {