keycloakify 10.0.0-rc.77 → 10.0.0-rc.79
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.
- package/account/Template.js +2 -2
- package/account/Template.js.map +1 -1
- package/account/i18n/i18n.d.ts +5 -5
- package/account/i18n/i18n.js +13 -35
- package/account/i18n/i18n.js.map +1 -1
- package/account/i18n/index.d.ts +1 -1
- package/account/i18n/index.js +1 -1
- package/account/i18n/index.js.map +1 -1
- package/account/i18n/useI18n.d.ts +13 -0
- package/account/i18n/useI18n.js +26 -0
- package/account/i18n/useI18n.js.map +1 -0
- package/bin/440.index.js +15 -19
- package/bin/751.index.js +0 -2
- package/bin/shared/constants.d.ts +0 -1
- package/bin/shared/constants.js +0 -1
- package/bin/shared/constants.js.map +1 -1
- package/login/KcContext/KcContext.d.ts +5 -1
- package/login/KcContext/KcContext.js +0 -1
- package/login/KcContext/KcContext.js.map +1 -1
- package/login/KcContext/kcContextMocks.js +4 -1
- package/login/KcContext/kcContextMocks.js.map +1 -1
- package/login/Template.js +2 -2
- package/login/Template.js.map +1 -1
- package/login/i18n/i18n.d.ts +8 -5
- package/login/i18n/i18n.js +24 -39
- package/login/i18n/i18n.js.map +1 -1
- package/login/i18n/index.d.ts +1 -1
- package/login/i18n/index.js +1 -1
- package/login/i18n/index.js.map +1 -1
- package/login/i18n/useI18n.d.ts +13 -0
- package/login/i18n/useI18n.js +26 -0
- package/login/i18n/useI18n.js.map +1 -0
- package/login/lib/useDownloadTerms.d.ts +5 -4
- package/login/lib/useDownloadTerms.js +26 -5
- package/login/lib/useDownloadTerms.js.map +1 -1
- package/login/pages/Register.js +7 -6
- package/login/pages/Register.js.map +1 -1
- package/login/pages/Terms.d.ts +1 -1
- package/login/pages/Terms.js +6 -4
- package/login/pages/Terms.js.map +1 -1
- package/package.json +15 -7
- package/src/account/Template.tsx +2 -2
- package/src/account/i18n/i18n.tsx +22 -56
- package/src/account/i18n/index.ts +1 -1
- package/src/account/i18n/useI18n.ts +44 -0
- package/src/bin/keycloakify/generateFtl/generateFtl.ts +1 -6
- package/src/bin/keycloakify/generateFtl/kcContextDeclarationTemplate.ftl +8 -1
- package/src/bin/keycloakify/generateResources/generateMessageProperties.ts +23 -17
- package/src/bin/shared/constants.ts +0 -2
- package/src/login/KcContext/KcContext.ts +6 -14
- package/src/login/KcContext/kcContextMocks.ts +4 -1
- package/src/login/Template.tsx +2 -2
- package/src/login/i18n/i18n.tsx +40 -61
- package/src/login/i18n/index.ts +1 -1
- package/src/login/i18n/useI18n.ts +44 -0
- package/src/login/lib/useDownloadTerms.tsx +88 -0
- package/src/login/pages/Register.tsx +12 -12
- package/src/login/pages/Terms.tsx +12 -11
- package/src/tools/react-markdown.ts +3 -0
- package/tools/react-markdown.d.ts +3 -0
- package/tools/react-markdown.js +4 -0
- package/tools/react-markdown.js.map +1 -0
- package/vite-plugin/index.js +0 -2
- package/src/login/lib/useDownloadTerms.ts +0 -57
- package/src/tools/Markdown.ts +0 -3
- package/tools/Markdown.d.ts +0 -2
- package/tools/Markdown.js +0 -3
- package/tools/Markdown.js.map +0 -1
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"kcContextMocks.js","sourceRoot":"","sources":["../../src/login/KcContext/kcContextMocks.ts"],"names":[],"mappings":"AAAA,OAAO,sCAAsC,CAAC;AAE9C,OAAO,EACH,gBAAgB,EAChB,kBAAkB,EAErB,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAE,EAAE,EAAE,MAAM,UAAU,CAAC;AAC9B,OAAO,EAAE,MAAM,EAAe,MAAM,cAAc,CAAC;AACnD,OAAO,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAEpD,MAAM,gBAAgB,GAAG,MAAM,CAAC,WAAW,CACvC,EAAE,CAAc;IACZ;QACI,UAAU,EAAE;YACR,MAAM,EAAE;gBACJ,oBAAoB,EAAE,IAAI;gBAC1B,GAAG,EAAE,GAAG;gBACR,GAAG,EAAE,KAAK;aACb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js
CHANGED
@@ -9,7 +9,7 @@ import { useSetClassName } from "../tools/useSetClassName";
|
|
9
9
|
export default function Template(props) {
|
10
10
|
const { displayInfo = false, displayMessage = true, displayRequiredFields = false, headerNode, showUsernameNode = null, socialProvidersNode = null, infoNode = null, documentTitle, bodyClassName, kcContext, i18n, doUseDefaultCss, classes, children } = props;
|
11
11
|
const { kcClsx } = getKcClsx({ doUseDefaultCss, classes });
|
12
|
-
const { msg, msgStr,
|
12
|
+
const { msg, msgStr, getChangeLocaleUrl, labelBySupportedLanguageTag, currentLanguageTag } = i18n;
|
13
13
|
const { realm, locale, auth, url, message, isAppInitiatedAction, authenticationSession, scripts } = kcContext;
|
14
14
|
useEffect(() => {
|
15
15
|
document.title = documentTitle !== null && documentTitle !== void 0 ? documentTitle : msgStr("loginTitle", kcContext.realm.displayName);
|
@@ -80,7 +80,7 @@ export default function Template(props) {
|
|
80
80
|
if (!areAllStyleSheetsLoaded) {
|
81
81
|
return null;
|
82
82
|
}
|
83
|
-
return (_jsxs("div", Object.assign({ className: kcClsx("kcLoginClass") }, { children: [_jsx("div", Object.assign({ id: "kc-header", className: kcClsx("kcHeaderClass") }, { children: _jsx("div", Object.assign({ id: "kc-header-wrapper", className: kcClsx("kcHeaderWrapperClass") }, { children: msg("loginTitleHtml", realm.displayNameHtml) })) })), _jsxs("div", Object.assign({ className: kcClsx("kcFormCardClass") }, { children: [_jsxs("header", Object.assign({ className: kcClsx("kcFormHeaderClass") }, { children: [realm.internationalizationEnabled && (assert(locale !== undefined), locale.supported.length > 1) && (_jsx("div", Object.assign({ className: kcClsx("kcLocaleMainClass"), id: "kc-locale" }, { children: _jsx("div", Object.assign({ id: "kc-locale-wrapper", className: kcClsx("kcLocaleWrapperClass") }, { children: _jsxs("div", Object.assign({ id: "kc-locale-dropdown", className: clsx("menu-button-links", kcClsx("kcLocaleDropDownClass")) }, { children: [_jsx("button", Object.assign({ tabIndex: 1, id: "kc-current-locale-link", "aria-label": msgStr("languages"), "aria-haspopup": "true", "aria-expanded": "false", "aria-controls": "language-switch1" }, { children: labelBySupportedLanguageTag[currentLanguageTag] })), _jsx("ul", Object.assign({ role: "menu", tabIndex: -1, "aria-labelledby": "kc-current-locale-link", "aria-activedescendant": "", id: "language-switch1", className: kcClsx("kcLocaleListClass") }, { children: locale.supported.map(({ languageTag }, i) => (_jsx("li", Object.assign({ className: kcClsx("kcLocaleListItemClass"), role: "none" }, { children: _jsx("a", Object.assign({ role: "menuitem", id: `language-${i + 1}`, className: kcClsx("kcLocaleItemClass"), href:
|
83
|
+
return (_jsxs("div", Object.assign({ className: kcClsx("kcLoginClass") }, { children: [_jsx("div", Object.assign({ id: "kc-header", className: kcClsx("kcHeaderClass") }, { children: _jsx("div", Object.assign({ id: "kc-header-wrapper", className: kcClsx("kcHeaderWrapperClass") }, { children: msg("loginTitleHtml", realm.displayNameHtml) })) })), _jsxs("div", Object.assign({ className: kcClsx("kcFormCardClass") }, { children: [_jsxs("header", Object.assign({ className: kcClsx("kcFormHeaderClass") }, { children: [realm.internationalizationEnabled && (assert(locale !== undefined), locale.supported.length > 1) && (_jsx("div", Object.assign({ className: kcClsx("kcLocaleMainClass"), id: "kc-locale" }, { children: _jsx("div", Object.assign({ id: "kc-locale-wrapper", className: kcClsx("kcLocaleWrapperClass") }, { children: _jsxs("div", Object.assign({ id: "kc-locale-dropdown", className: clsx("menu-button-links", kcClsx("kcLocaleDropDownClass")) }, { children: [_jsx("button", Object.assign({ tabIndex: 1, id: "kc-current-locale-link", "aria-label": msgStr("languages"), "aria-haspopup": "true", "aria-expanded": "false", "aria-controls": "language-switch1" }, { children: labelBySupportedLanguageTag[currentLanguageTag] })), _jsx("ul", Object.assign({ role: "menu", tabIndex: -1, "aria-labelledby": "kc-current-locale-link", "aria-activedescendant": "", id: "language-switch1", className: kcClsx("kcLocaleListClass") }, { children: locale.supported.map(({ languageTag }, i) => (_jsx("li", Object.assign({ className: kcClsx("kcLocaleListItemClass"), role: "none" }, { children: _jsx("a", Object.assign({ role: "menuitem", id: `language-${i + 1}`, className: kcClsx("kcLocaleItemClass"), href: getChangeLocaleUrl(languageTag) }, { children: labelBySupportedLanguageTag[languageTag] })) }), languageTag))) }))] })) })) }))), !(auth !== undefined && auth.showUsername && !auth.showResetCredentials) ? (displayRequiredFields ? (_jsxs("div", Object.assign({ className: kcClsx("kcContentWrapperClass") }, { children: [_jsx("div", Object.assign({ className: clsx(kcClsx("kcLabelWrapperClass"), "subtitle") }, { children: _jsxs("span", Object.assign({ className: "subtitle" }, { children: [_jsx("span", Object.assign({ className: "required" }, { children: "*" })), msg("requiredFields")] })) })), _jsx("div", Object.assign({ className: "col-md-10" }, { children: _jsx("h1", Object.assign({ id: "kc-page-title" }, { children: headerNode })) }))] }))) : (_jsx("h1", Object.assign({ id: "kc-page-title" }, { children: headerNode })))) : displayRequiredFields ? (_jsxs("div", Object.assign({ className: kcClsx("kcContentWrapperClass") }, { children: [_jsx("div", Object.assign({ className: clsx(kcClsx("kcLabelWrapperClass"), "subtitle") }, { children: _jsxs("span", Object.assign({ className: "subtitle" }, { children: [_jsx("span", Object.assign({ className: "required" }, { children: "*" })), " ", msg("requiredFields")] })) })), _jsxs("div", Object.assign({ className: "col-md-10" }, { children: [showUsernameNode, _jsxs("div", Object.assign({ id: "kc-username", className: kcClsx("kcFormGroupClass") }, { children: [_jsx("label", Object.assign({ id: "kc-attempted-username" }, { children: auth.attemptedUsername })), _jsx("a", Object.assign({ id: "reset-login", href: url.loginRestartFlowUrl, "aria-label": msgStr("restartLoginTooltip") }, { children: _jsxs("div", Object.assign({ className: "kc-login-tooltip" }, { children: [_jsx("i", { className: kcClsx("kcResetFlowIcon") }), _jsx("span", Object.assign({ className: "kc-tooltip-text" }, { children: msg("restartLoginTooltip") }))] })) }))] }))] }))] }))) : (_jsxs(_Fragment, { children: [showUsernameNode, _jsxs("div", Object.assign({ id: "kc-username", className: kcClsx("kcFormGroupClass") }, { children: [_jsx("label", Object.assign({ id: "kc-attempted-username" }, { children: auth.attemptedUsername })), _jsx("a", Object.assign({ id: "reset-login", href: url.loginRestartFlowUrl, "aria-label": msgStr("restartLoginTooltip") }, { children: _jsxs("div", Object.assign({ className: "kc-login-tooltip" }, { children: [_jsx("i", { className: kcClsx("kcResetFlowIcon") }), _jsx("span", Object.assign({ className: "kc-tooltip-text" }, { children: msg("restartLoginTooltip") }))] })) }))] }))] }))] })), _jsx("div", Object.assign({ id: "kc-content" }, { children: _jsxs("div", Object.assign({ id: "kc-content-wrapper" }, { children: [displayMessage && message !== undefined && (message.type !== "warning" || !isAppInitiatedAction) && (_jsxs("div", Object.assign({ className: clsx(`alert-${message.type}`, kcClsx("kcAlertClass"), `pf-m-${(message === null || message === void 0 ? void 0 : message.type) === "error" ? "danger" : message.type}`) }, { children: [_jsxs("div", Object.assign({ className: "pf-c-alert__icon" }, { children: [message.type === "success" && _jsx("span", { className: kcClsx("kcFeedbackSuccessIcon") }), message.type === "warning" && _jsx("span", { className: kcClsx("kcFeedbackWarningIcon") }), message.type === "error" && _jsx("span", { className: kcClsx("kcFeedbackErrorIcon") }), message.type === "info" && _jsx("span", { className: kcClsx("kcFeedbackInfoIcon") })] })), _jsx("span", { className: kcClsx("kcAlertTitleClass"), dangerouslySetInnerHTML: {
|
84
84
|
__html: message.summary
|
85
85
|
} })] }))), children, auth !== undefined && auth.showTryAnotherWayLink && (_jsx("form", Object.assign({ id: "kc-select-try-another-way-form", action: url.loginAction, method: "post" }, { children: _jsx("div", Object.assign({ className: kcClsx("kcFormGroupClass") }, { children: _jsxs("div", Object.assign({ className: kcClsx("kcFormGroupClass") }, { children: [_jsx("input", { type: "hidden", name: "tryAnotherWay", value: "on" }), _jsx("a", Object.assign({ href: "#", id: "try-another-way", onClick: () => {
|
86
86
|
document.forms["kc-select-try-another-way-form"].submit();
|
package/login/Template.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Template.js","sourceRoot":"","sources":["../src/login/Template.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,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6BAAK,SAAS,EAAE,MAAM,CAAC,kBAAkB,CAAC,iBACtC,gBAAO,IAAI,EAAC,QAAQ,EAAC,IAAI,EAAC,eAAe,EAAC,KAAK,EAAC,IAAI,GAAG,EACvD,0BACI,IAAI,EAAC,GAAG,EACR,EAAE,EAAC,iBAAiB,EACpB,OAAO,EAAE,GAAG,EAAE;wDACV,QAAQ,CAAC,KAAK,CAAC,gCAAyC,CAAC,CAAC,MAAM,EAAE,CAAC;wDACnE,OAAO,KAAK,CAAC;oDACjB,CAAC,gBAEA,GAAG,CAAC,iBAAiB,CAAC,IACvB,KACF,IACJ,IACH,CACV,EACA,mBAAmB,EACnB,WAAW,IAAI,CACZ,4BAAK,EAAE,EAAC,SAAS,EAAC,SAAS,EAAE,MAAM,CAAC,eAAe,CAAC,gBAChD,4BAAK,EAAE,EAAC,iBAAiB,EAAC,SAAS,EAAE,MAAM,CAAC,wBAAwB,CAAC,gBAChE,QAAQ,IACP,IACJ,CACT,KACC,IACJ,KACJ,KACJ,CACT,CAAC;AACN,CAAC"}
|
package/login/i18n/i18n.d.ts
CHANGED
@@ -11,7 +11,10 @@ export type KcContextLike = {
|
|
11
11
|
label: string;
|
12
12
|
}[];
|
13
13
|
};
|
14
|
-
|
14
|
+
"x-keycloakify": {
|
15
|
+
realmMessageBundleUserProfile: Record<string, string> | undefined;
|
16
|
+
realmMessageBundleTermsText: string | undefined;
|
17
|
+
};
|
15
18
|
};
|
16
19
|
export type MessageKey = keyof typeof messages_fallbackLanguage;
|
17
20
|
export type GenericI18n<MessageKey extends string> = {
|
@@ -25,7 +28,7 @@ export type GenericI18n<MessageKey extends string> = {
|
|
25
28
|
* Redirect to this url to change the language.
|
26
29
|
* After reload currentLanguageTag === newLanguageTag
|
27
30
|
*/
|
28
|
-
|
31
|
+
getChangeLocaleUrl: (newLanguageTag: string) => string;
|
29
32
|
/**
|
30
33
|
* e.g. "en" => "English", "fr" => "Français", ...
|
31
34
|
*
|
@@ -81,15 +84,15 @@ export type GenericI18n<MessageKey extends string> = {
|
|
81
84
|
*/
|
82
85
|
isFetchingTranslations: boolean;
|
83
86
|
};
|
84
|
-
export declare function
|
87
|
+
export declare function createGetI18n<ExtraMessageKey extends string = never>(messageBundle: {
|
85
88
|
[languageTag: string]: {
|
86
89
|
[key in ExtraMessageKey]: string;
|
87
90
|
};
|
88
91
|
}): {
|
89
|
-
|
92
|
+
getI18n: (params: {
|
90
93
|
kcContext: KcContextLike;
|
91
94
|
}) => {
|
92
95
|
i18n: GenericI18n<"region" | "address" | "email" | "password" | "totpAppFreeOTPName" | "totpAppMicrosoftAuthenticatorName" | "totpAppGoogleName" | "doCancel" | "doLogIn" | "noAccessMessage" | "updatePasswordTitle" | "updatePasswordMessage" | "authenticatorCode" | "firstName" | "givenName" | "fullName" | "lastName" | "familyName" | "passwordConfirm" | "passwordNew" | "username" | "street" | "locality" | "postal_code" | "country" | "emailVerified" | "website" | "phoneNumber" | "phoneNumberVerified" | "gender" | "birthday" | "zoneinfo" | "gssDelegationCredential" | "profileScopeConsentText" | "emailScopeConsentText" | "addressScopeConsentText" | "phoneScopeConsentText" | "offlineAccessScopeConsentText" | "samlRoleListScopeConsentText" | "rolesScopeConsentText" | "role_admin" | "role_realm-admin" | "role_create-realm" | "role_view-realm" | "role_view-users" | "role_view-applications" | "role_view-clients" | "role_view-events" | "role_view-identity-providers" | "role_manage-realm" | "role_manage-users" | "role_manage-applications" | "role_manage-identity-providers" | "role_manage-clients" | "role_manage-events" | "role_view-profile" | "role_manage-account" | "role_manage-account-links" | "role_read-token" | "role_offline-access" | "client_account" | "client_account-console" | "client_security-admin-console" | "client_admin-cli" | "client_realm-management" | "client_broker" | "requiredFields" | "backToApplication" | "inResource" | "irreversibleAction" | "deletingImplies" | "errasingData" | "loggingOutImmediately" | "accountUnusable" | "missingUsernameMessage" | "missingFirstNameMessage" | "invalidEmailMessage" | "missingLastNameMessage" | "missingEmailMessage" | "missingPasswordMessage" | "notMatchPasswordMessage" | "invalidUserMessage" | "missingTotpMessage" | "missingTotpDeviceNameMessage" | "invalidPasswordExistingMessage" | "invalidPasswordConfirmMessage" | "invalidTotpMessage" | "usernameExistsMessage" | "emailExistsMessage" | "readOnlyUsernameMessage" | "accountUpdatedMessage" | "accountPasswordUpdatedMessage" | "identityProviderNotFoundMessage" | "identityProviderAlreadyLinkedMessage" | "consentDenied" | "access-denied-when-idp-auth" | "accountDisabledMessage" | "accountTemporarilyDisabledMessage" | "invalidPasswordMinLengthMessage" | "invalidPasswordMaxLengthMessage" | "invalidPasswordMinLowerCaseCharsMessage" | "invalidPasswordMinDigitsMessage" | "invalidPasswordMinUpperCaseCharsMessage" | "invalidPasswordMinSpecialCharsMessage" | "invalidPasswordNotUsernameMessage" | "invalidPasswordNotEmailMessage" | "invalidPasswordRegexPatternMessage" | "invalidPasswordHistoryMessage" | "invalidPasswordBlacklistedMessage" | "invalidPasswordGenericMessage" | "locale_ar" | "locale_ca" | "locale_cs" | "locale_de" | "locale_en" | "locale_es" | "locale_fr" | "locale_hu" | "locale_it" | "locale_ja" | "locale_lt" | "locale_nl" | "locale_no" | "locale_pl" | "locale_pt-BR" | "locale_ru" | "locale_sk" | "locale_sv" | "locale_th" | "locale_tr" | "locale_uk" | "locale_zh-CN" | "locale_fi" | "clientNotFoundMessage" | "openshift.scope.user_info" | "openshift.scope.user_check-access" | "openshift.scope.user_full" | "openshift.scope.list-projects" | "error-invalid-value" | "error-invalid-blank" | "error-empty" | "error-invalid-length" | "error-invalid-length-too-short" | "error-invalid-length-too-long" | "error-invalid-email" | "error-invalid-number" | "error-number-out-of-range" | "error-number-out-of-range-too-small" | "error-number-out-of-range-too-big" | "error-pattern-no-match" | "error-invalid-uri" | "error-invalid-uri-scheme" | "error-invalid-uri-fragment" | "error-user-attribute-required" | "error-invalid-date" | "error-user-attribute-read-only" | "error-username-invalid-character" | "error-person-name-invalid-character" | "remove" | "usb" | "nfc" | "bluetooth" | "doRegister" | "doRegisterSecurityKey" | "doSubmit" | "doBack" | "doYes" | "doNo" | "doContinue" | "doIgnore" | "doAccept" | "doDecline" | "doForgotPassword" | "doClickHere" | "doImpersonate" | "doTryAgain" | "doTryAnotherWay" | "doConfirmDelete" | "errorDeletingAccount" | "deletingAccountForbidden" | "kerberosNotConfigured" | "kerberosNotConfiguredTitle" | "bypassKerberosDetail" | "kerberosNotSetUp" | "registerTitle" | "loginAccountTitle" | "loginTitle" | "loginTitleHtml" | "impersonateTitle" | "impersonateTitleHtml" | "realmChoice" | "unknownUser" | "loginTotpTitle" | "loginProfileTitle" | "loginIdpReviewProfileTitle" | "loginTimeout" | "reauthenticate" | "authenticateStrong" | "oauthGrantTitle" | "oauthGrantTitleHtml" | "oauthGrantInformation" | "oauthGrantReview" | "oauthGrantTos" | "oauthGrantPolicy" | "errorTitle" | "errorTitleHtml" | "emailVerifyTitle" | "emailForgotTitle" | "updateEmailTitle" | "emailUpdateConfirmationSentTitle" | "emailUpdateConfirmationSent" | "emailUpdatedTitle" | "emailUpdated" | "codeSuccessTitle" | "codeErrorTitle" | "displayUnsupported" | "browserRequired" | "browserContinue" | "browserContinuePrompt" | "browserContinueAnswer" | "internal" | "unknown" | "termsTitle" | "termsText" | "termsPlainText" | "termsAcceptanceRequired" | "acceptTerms" | "deleteCredentialTitle" | "deleteCredentialMessage" | "recaptchaFailed" | "recaptchaNotConfigured" | "noAccount" | "usernameOrEmail" | "passwordNewConfirm" | "hidePassword" | "showPassword" | "rememberMe" | "logoutOtherSessions" | "restartLoginTooltip" | "loginTotpIntro" | "loginTotpStep1" | "loginTotpStep2" | "loginTotpStep3" | "loginTotpStep3DeviceName" | "loginTotpManualStep2" | "loginTotpManualStep3" | "loginTotpUnableToScan" | "loginTotpScanBarcode" | "loginCredential" | "loginOtpOneTime" | "loginTotpType" | "loginTotpAlgorithm" | "loginTotpDigits" | "loginTotpInterval" | "loginTotpCounter" | "loginTotpDeviceName" | "loginTotp.totp" | "loginTotp.hotp" | "loginChooseAuthenticator" | "oauthGrantRequest" | "oauth2DeviceVerificationTitle" | "verifyOAuth2DeviceUserCode" | "oauth2DeviceInvalidUserCodeMessage" | "oauth2DeviceExpiredUserCodeMessage" | "oauth2DeviceVerificationCompleteHeader" | "oauth2DeviceVerificationCompleteMessage" | "oauth2DeviceVerificationFailedHeader" | "oauth2DeviceVerificationFailedMessage" | "oauth2DeviceConsentDeniedMessage" | "oauth2DeviceAuthorizationGrantDisabledMessage" | "emailVerifyInstruction1" | "emailVerifyInstruction2" | "emailVerifyInstruction3" | "emailLinkIdpTitle" | "emailLinkIdp1" | "emailLinkIdp2" | "emailLinkIdp3" | "emailLinkIdp4" | "emailLinkIdp5" | "backToLogin" | "emailInstruction" | "emailInstructionUsername" | "copyCodeInstruction" | "pageExpiredTitle" | "pageExpiredMsg1" | "pageExpiredMsg2" | "personalInfo" | "role_create-client" | "invalidUsernameMessage" | "invalidUsernameOrEmailMessage" | "invalidPasswordMessage" | "expiredCodeMessage" | "expiredActionMessage" | "expiredActionTokenNoSessionMessage" | "expiredActionTokenSessionExistsMessage" | "sessionLimitExceeded" | "error-reset-otp-missing-id" | "federatedIdentityExistsMessage" | "federatedIdentityUnavailableMessage" | "federatedIdentityUnmatchedEssentialClaimMessage" | "confirmLinkIdpTitle" | "federatedIdentityConfirmLinkMessage" | "federatedIdentityConfirmReauthenticateMessage" | "nestedFirstBrokerFlowMessage" | "confirmLinkIdpReviewProfile" | "confirmLinkIdpContinue" | "configureTotpMessage" | "configureBackupCodesMessage" | "updateProfileMessage" | "updateEmailMessage" | "resetPasswordMessage" | "verifyEmailMessage" | "linkIdpMessage" | "emailSentMessage" | "emailSendErrorMessage" | "delegationCompleteHeader" | "delegationCompleteMessage" | "delegationFailedHeader" | "delegationFailedMessage" | "failedToProcessResponseMessage" | "httpsRequiredMessage" | "realmNotEnabledMessage" | "invalidRequestMessage" | "successLogout" | "failedLogout" | "unknownLoginRequesterMessage" | "loginRequesterNotEnabledMessage" | "bearerOnlyMessage" | "standardFlowDisabledMessage" | "implicitFlowDisabledMessage" | "invalidRedirectUriMessage" | "unsupportedNameIdFormatMessage" | "invalidRequesterMessage" | "registrationNotAllowedMessage" | "resetCredentialNotAllowedMessage" | "permissionNotApprovedMessage" | "noRelayStateInResponseMessage" | "insufficientPermissionMessage" | "couldNotProceedWithAuthenticationRequestMessage" | "couldNotObtainTokenMessage" | "unexpectedErrorRetrievingTokenMessage" | "unexpectedErrorHandlingResponseMessage" | "identityProviderAuthenticationFailedMessage" | "couldNotSendAuthenticationRequestMessage" | "unexpectedErrorHandlingRequestMessage" | "invalidAccessCodeMessage" | "sessionNotActiveMessage" | "invalidCodeMessage" | "cookieNotFoundMessage" | "insufficientLevelOfAuthentication" | "identityProviderUnexpectedErrorMessage" | "identityProviderMissingStateMessage" | "identityProviderMissingCodeOrErrorMessage" | "identityProviderInvalidResponseMessage" | "identityProviderInvalidSignatureMessage" | "identityProviderLinkSuccess" | "staleCodeMessage" | "realmSupportsNoCredentialsMessage" | "credentialSetupRequired" | "identityProviderNotUniqueMessage" | "emailVerifiedMessage" | "emailVerifiedAlreadyMessage" | "staleEmailVerificationLink" | "confirmAccountLinking" | "confirmEmailAddressVerification" | "confirmExecutionOfActions" | "locale_da" | "locale_lv" | "missingParameterMessage" | "clientDisabledMessage" | "invalidParameterMessage" | "alreadyLoggedIn" | "differentUserAuthenticated" | "brokerLinkingSessionExpired" | "proceedWithAction" | "acrNotFulfilled" | "requiredAction.CONFIGURE_TOTP" | "requiredAction.TERMS_AND_CONDITIONS" | "requiredAction.UPDATE_PASSWORD" | "requiredAction.UPDATE_PROFILE" | "requiredAction.VERIFY_EMAIL" | "requiredAction.CONFIGURE_RECOVERY_AUTHN_CODES" | "requiredAction.webauthn-register-passwordless" | "invalidTokenRequiredActions" | "doX509Login" | "clientCertificate" | "noCertificate" | "pageNotFound" | "internalServerError" | "console-username" | "console-password" | "console-otp" | "console-new-password" | "console-confirm-password" | "console-update-password" | "console-verify-email" | "console-email-code" | "console-accept-terms" | "console-accept" | "saml.post-form.title" | "saml.post-form.message" | "saml.post-form.js-disabled" | "saml.artifactResolutionServiceInvalidResponse" | "otp-display-name" | "otp-help-text" | "otp-reset-description" | "password-display-name" | "password-help-text" | "auth-username-form-display-name" | "auth-username-form-help-text" | "auth-username-password-form-display-name" | "auth-username-password-form-help-text" | "auth-recovery-authn-code-form-display-name" | "auth-recovery-authn-code-form-help-text" | "auth-recovery-code-info-message" | "auth-recovery-code-prompt" | "auth-recovery-code-header" | "recovery-codes-error-invalid" | "recovery-code-config-header" | "recovery-code-config-warning-title" | "recovery-code-config-warning-message" | "recovery-codes-print" | "recovery-codes-download" | "recovery-codes-copy" | "recovery-codes-copied" | "recovery-codes-confirmation-message" | "recovery-codes-action-complete" | "recovery-codes-action-cancel" | "recovery-codes-download-file-header" | "recovery-codes-download-file-description" | "recovery-codes-download-file-date" | "recovery-codes-label-default" | "webauthn-display-name" | "webauthn-help-text" | "webauthn-passwordless-display-name" | "webauthn-passwordless-help-text" | "webauthn-login-title" | "webauthn-registration-title" | "webauthn-available-authenticators" | "webauthn-unsupported-browser-text" | "webauthn-doAuthenticate" | "webauthn-createdAt-label" | "webauthn-error-title" | "webauthn-error-registration" | "webauthn-error-api-get" | "webauthn-error-different-user" | "webauthn-error-auth-verification" | "webauthn-error-register-verification" | "webauthn-error-user-not-found" | "identity-provider-redirector" | "identity-provider-login-label" | "idp-email-verification-display-name" | "idp-email-verification-help-text" | "idp-username-password-form-display-name" | "idp-username-password-form-help-text" | "finalDeletionConfirmation" | "deleteAccountConfirm" | "userDeletedSuccessfully" | "access-denied" | "frontchannel-logout.title" | "frontchannel-logout.message" | "logoutConfirmTitle" | "logoutConfirmHeader" | "doLogout" | "error-invalid-multivalued-size" | "shouldBeEqual" | "shouldBeDifferent" | "shouldMatchPattern" | "mustBeAnInteger" | "notAValidOption" | "selectAnOption" | "addValue" | "languages" | ExtraMessageKey>;
|
96
|
+
prI18n_currentLanguage: Promise<GenericI18n<"region" | "address" | "email" | "password" | "totpAppFreeOTPName" | "totpAppMicrosoftAuthenticatorName" | "totpAppGoogleName" | "doCancel" | "doLogIn" | "noAccessMessage" | "updatePasswordTitle" | "updatePasswordMessage" | "authenticatorCode" | "firstName" | "givenName" | "fullName" | "lastName" | "familyName" | "passwordConfirm" | "passwordNew" | "username" | "street" | "locality" | "postal_code" | "country" | "emailVerified" | "website" | "phoneNumber" | "phoneNumberVerified" | "gender" | "birthday" | "zoneinfo" | "gssDelegationCredential" | "profileScopeConsentText" | "emailScopeConsentText" | "addressScopeConsentText" | "phoneScopeConsentText" | "offlineAccessScopeConsentText" | "samlRoleListScopeConsentText" | "rolesScopeConsentText" | "role_admin" | "role_realm-admin" | "role_create-realm" | "role_view-realm" | "role_view-users" | "role_view-applications" | "role_view-clients" | "role_view-events" | "role_view-identity-providers" | "role_manage-realm" | "role_manage-users" | "role_manage-applications" | "role_manage-identity-providers" | "role_manage-clients" | "role_manage-events" | "role_view-profile" | "role_manage-account" | "role_manage-account-links" | "role_read-token" | "role_offline-access" | "client_account" | "client_account-console" | "client_security-admin-console" | "client_admin-cli" | "client_realm-management" | "client_broker" | "requiredFields" | "backToApplication" | "inResource" | "irreversibleAction" | "deletingImplies" | "errasingData" | "loggingOutImmediately" | "accountUnusable" | "missingUsernameMessage" | "missingFirstNameMessage" | "invalidEmailMessage" | "missingLastNameMessage" | "missingEmailMessage" | "missingPasswordMessage" | "notMatchPasswordMessage" | "invalidUserMessage" | "missingTotpMessage" | "missingTotpDeviceNameMessage" | "invalidPasswordExistingMessage" | "invalidPasswordConfirmMessage" | "invalidTotpMessage" | "usernameExistsMessage" | "emailExistsMessage" | "readOnlyUsernameMessage" | "accountUpdatedMessage" | "accountPasswordUpdatedMessage" | "identityProviderNotFoundMessage" | "identityProviderAlreadyLinkedMessage" | "consentDenied" | "access-denied-when-idp-auth" | "accountDisabledMessage" | "accountTemporarilyDisabledMessage" | "invalidPasswordMinLengthMessage" | "invalidPasswordMaxLengthMessage" | "invalidPasswordMinLowerCaseCharsMessage" | "invalidPasswordMinDigitsMessage" | "invalidPasswordMinUpperCaseCharsMessage" | "invalidPasswordMinSpecialCharsMessage" | "invalidPasswordNotUsernameMessage" | "invalidPasswordNotEmailMessage" | "invalidPasswordRegexPatternMessage" | "invalidPasswordHistoryMessage" | "invalidPasswordBlacklistedMessage" | "invalidPasswordGenericMessage" | "locale_ar" | "locale_ca" | "locale_cs" | "locale_de" | "locale_en" | "locale_es" | "locale_fr" | "locale_hu" | "locale_it" | "locale_ja" | "locale_lt" | "locale_nl" | "locale_no" | "locale_pl" | "locale_pt-BR" | "locale_ru" | "locale_sk" | "locale_sv" | "locale_th" | "locale_tr" | "locale_uk" | "locale_zh-CN" | "locale_fi" | "clientNotFoundMessage" | "openshift.scope.user_info" | "openshift.scope.user_check-access" | "openshift.scope.user_full" | "openshift.scope.list-projects" | "error-invalid-value" | "error-invalid-blank" | "error-empty" | "error-invalid-length" | "error-invalid-length-too-short" | "error-invalid-length-too-long" | "error-invalid-email" | "error-invalid-number" | "error-number-out-of-range" | "error-number-out-of-range-too-small" | "error-number-out-of-range-too-big" | "error-pattern-no-match" | "error-invalid-uri" | "error-invalid-uri-scheme" | "error-invalid-uri-fragment" | "error-user-attribute-required" | "error-invalid-date" | "error-user-attribute-read-only" | "error-username-invalid-character" | "error-person-name-invalid-character" | "remove" | "usb" | "nfc" | "bluetooth" | "doRegister" | "doRegisterSecurityKey" | "doSubmit" | "doBack" | "doYes" | "doNo" | "doContinue" | "doIgnore" | "doAccept" | "doDecline" | "doForgotPassword" | "doClickHere" | "doImpersonate" | "doTryAgain" | "doTryAnotherWay" | "doConfirmDelete" | "errorDeletingAccount" | "deletingAccountForbidden" | "kerberosNotConfigured" | "kerberosNotConfiguredTitle" | "bypassKerberosDetail" | "kerberosNotSetUp" | "registerTitle" | "loginAccountTitle" | "loginTitle" | "loginTitleHtml" | "impersonateTitle" | "impersonateTitleHtml" | "realmChoice" | "unknownUser" | "loginTotpTitle" | "loginProfileTitle" | "loginIdpReviewProfileTitle" | "loginTimeout" | "reauthenticate" | "authenticateStrong" | "oauthGrantTitle" | "oauthGrantTitleHtml" | "oauthGrantInformation" | "oauthGrantReview" | "oauthGrantTos" | "oauthGrantPolicy" | "errorTitle" | "errorTitleHtml" | "emailVerifyTitle" | "emailForgotTitle" | "updateEmailTitle" | "emailUpdateConfirmationSentTitle" | "emailUpdateConfirmationSent" | "emailUpdatedTitle" | "emailUpdated" | "codeSuccessTitle" | "codeErrorTitle" | "displayUnsupported" | "browserRequired" | "browserContinue" | "browserContinuePrompt" | "browserContinueAnswer" | "internal" | "unknown" | "termsTitle" | "termsText" | "termsPlainText" | "termsAcceptanceRequired" | "acceptTerms" | "deleteCredentialTitle" | "deleteCredentialMessage" | "recaptchaFailed" | "recaptchaNotConfigured" | "noAccount" | "usernameOrEmail" | "passwordNewConfirm" | "hidePassword" | "showPassword" | "rememberMe" | "logoutOtherSessions" | "restartLoginTooltip" | "loginTotpIntro" | "loginTotpStep1" | "loginTotpStep2" | "loginTotpStep3" | "loginTotpStep3DeviceName" | "loginTotpManualStep2" | "loginTotpManualStep3" | "loginTotpUnableToScan" | "loginTotpScanBarcode" | "loginCredential" | "loginOtpOneTime" | "loginTotpType" | "loginTotpAlgorithm" | "loginTotpDigits" | "loginTotpInterval" | "loginTotpCounter" | "loginTotpDeviceName" | "loginTotp.totp" | "loginTotp.hotp" | "loginChooseAuthenticator" | "oauthGrantRequest" | "oauth2DeviceVerificationTitle" | "verifyOAuth2DeviceUserCode" | "oauth2DeviceInvalidUserCodeMessage" | "oauth2DeviceExpiredUserCodeMessage" | "oauth2DeviceVerificationCompleteHeader" | "oauth2DeviceVerificationCompleteMessage" | "oauth2DeviceVerificationFailedHeader" | "oauth2DeviceVerificationFailedMessage" | "oauth2DeviceConsentDeniedMessage" | "oauth2DeviceAuthorizationGrantDisabledMessage" | "emailVerifyInstruction1" | "emailVerifyInstruction2" | "emailVerifyInstruction3" | "emailLinkIdpTitle" | "emailLinkIdp1" | "emailLinkIdp2" | "emailLinkIdp3" | "emailLinkIdp4" | "emailLinkIdp5" | "backToLogin" | "emailInstruction" | "emailInstructionUsername" | "copyCodeInstruction" | "pageExpiredTitle" | "pageExpiredMsg1" | "pageExpiredMsg2" | "personalInfo" | "role_create-client" | "invalidUsernameMessage" | "invalidUsernameOrEmailMessage" | "invalidPasswordMessage" | "expiredCodeMessage" | "expiredActionMessage" | "expiredActionTokenNoSessionMessage" | "expiredActionTokenSessionExistsMessage" | "sessionLimitExceeded" | "error-reset-otp-missing-id" | "federatedIdentityExistsMessage" | "federatedIdentityUnavailableMessage" | "federatedIdentityUnmatchedEssentialClaimMessage" | "confirmLinkIdpTitle" | "federatedIdentityConfirmLinkMessage" | "federatedIdentityConfirmReauthenticateMessage" | "nestedFirstBrokerFlowMessage" | "confirmLinkIdpReviewProfile" | "confirmLinkIdpContinue" | "configureTotpMessage" | "configureBackupCodesMessage" | "updateProfileMessage" | "updateEmailMessage" | "resetPasswordMessage" | "verifyEmailMessage" | "linkIdpMessage" | "emailSentMessage" | "emailSendErrorMessage" | "delegationCompleteHeader" | "delegationCompleteMessage" | "delegationFailedHeader" | "delegationFailedMessage" | "failedToProcessResponseMessage" | "httpsRequiredMessage" | "realmNotEnabledMessage" | "invalidRequestMessage" | "successLogout" | "failedLogout" | "unknownLoginRequesterMessage" | "loginRequesterNotEnabledMessage" | "bearerOnlyMessage" | "standardFlowDisabledMessage" | "implicitFlowDisabledMessage" | "invalidRedirectUriMessage" | "unsupportedNameIdFormatMessage" | "invalidRequesterMessage" | "registrationNotAllowedMessage" | "resetCredentialNotAllowedMessage" | "permissionNotApprovedMessage" | "noRelayStateInResponseMessage" | "insufficientPermissionMessage" | "couldNotProceedWithAuthenticationRequestMessage" | "couldNotObtainTokenMessage" | "unexpectedErrorRetrievingTokenMessage" | "unexpectedErrorHandlingResponseMessage" | "identityProviderAuthenticationFailedMessage" | "couldNotSendAuthenticationRequestMessage" | "unexpectedErrorHandlingRequestMessage" | "invalidAccessCodeMessage" | "sessionNotActiveMessage" | "invalidCodeMessage" | "cookieNotFoundMessage" | "insufficientLevelOfAuthentication" | "identityProviderUnexpectedErrorMessage" | "identityProviderMissingStateMessage" | "identityProviderMissingCodeOrErrorMessage" | "identityProviderInvalidResponseMessage" | "identityProviderInvalidSignatureMessage" | "identityProviderLinkSuccess" | "staleCodeMessage" | "realmSupportsNoCredentialsMessage" | "credentialSetupRequired" | "identityProviderNotUniqueMessage" | "emailVerifiedMessage" | "emailVerifiedAlreadyMessage" | "staleEmailVerificationLink" | "confirmAccountLinking" | "confirmEmailAddressVerification" | "confirmExecutionOfActions" | "locale_da" | "locale_lv" | "missingParameterMessage" | "clientDisabledMessage" | "invalidParameterMessage" | "alreadyLoggedIn" | "differentUserAuthenticated" | "brokerLinkingSessionExpired" | "proceedWithAction" | "acrNotFulfilled" | "requiredAction.CONFIGURE_TOTP" | "requiredAction.TERMS_AND_CONDITIONS" | "requiredAction.UPDATE_PASSWORD" | "requiredAction.UPDATE_PROFILE" | "requiredAction.VERIFY_EMAIL" | "requiredAction.CONFIGURE_RECOVERY_AUTHN_CODES" | "requiredAction.webauthn-register-passwordless" | "invalidTokenRequiredActions" | "doX509Login" | "clientCertificate" | "noCertificate" | "pageNotFound" | "internalServerError" | "console-username" | "console-password" | "console-otp" | "console-new-password" | "console-confirm-password" | "console-update-password" | "console-verify-email" | "console-email-code" | "console-accept-terms" | "console-accept" | "saml.post-form.title" | "saml.post-form.message" | "saml.post-form.js-disabled" | "saml.artifactResolutionServiceInvalidResponse" | "otp-display-name" | "otp-help-text" | "otp-reset-description" | "password-display-name" | "password-help-text" | "auth-username-form-display-name" | "auth-username-form-help-text" | "auth-username-password-form-display-name" | "auth-username-password-form-help-text" | "auth-recovery-authn-code-form-display-name" | "auth-recovery-authn-code-form-help-text" | "auth-recovery-code-info-message" | "auth-recovery-code-prompt" | "auth-recovery-code-header" | "recovery-codes-error-invalid" | "recovery-code-config-header" | "recovery-code-config-warning-title" | "recovery-code-config-warning-message" | "recovery-codes-print" | "recovery-codes-download" | "recovery-codes-copy" | "recovery-codes-copied" | "recovery-codes-confirmation-message" | "recovery-codes-action-complete" | "recovery-codes-action-cancel" | "recovery-codes-download-file-header" | "recovery-codes-download-file-description" | "recovery-codes-download-file-date" | "recovery-codes-label-default" | "webauthn-display-name" | "webauthn-help-text" | "webauthn-passwordless-display-name" | "webauthn-passwordless-help-text" | "webauthn-login-title" | "webauthn-registration-title" | "webauthn-available-authenticators" | "webauthn-unsupported-browser-text" | "webauthn-doAuthenticate" | "webauthn-createdAt-label" | "webauthn-error-title" | "webauthn-error-registration" | "webauthn-error-api-get" | "webauthn-error-different-user" | "webauthn-error-auth-verification" | "webauthn-error-register-verification" | "webauthn-error-user-not-found" | "identity-provider-redirector" | "identity-provider-login-label" | "idp-email-verification-display-name" | "idp-email-verification-help-text" | "idp-username-password-form-display-name" | "idp-username-password-form-help-text" | "finalDeletionConfirmation" | "deleteAccountConfirm" | "userDeletedSuccessfully" | "access-denied" | "frontchannel-logout.title" | "frontchannel-logout.message" | "logoutConfirmTitle" | "logoutConfirmHeader" | "doLogout" | "error-invalid-multivalued-size" | "shouldBeEqual" | "shouldBeDifferent" | "shouldMatchPattern" | "mustBeAnInteger" | "notAValidOption" | "selectAnOption" | "addValue" | "languages" | ExtraMessageKey>> | undefined;
|
93
97
|
};
|
94
|
-
ofTypeI18n: GenericI18n<"region" | "address" | "email" | "password" | "totpAppFreeOTPName" | "totpAppMicrosoftAuthenticatorName" | "totpAppGoogleName" | "doCancel" | "doLogIn" | "noAccessMessage" | "updatePasswordTitle" | "updatePasswordMessage" | "authenticatorCode" | "firstName" | "givenName" | "fullName" | "lastName" | "familyName" | "passwordConfirm" | "passwordNew" | "username" | "street" | "locality" | "postal_code" | "country" | "emailVerified" | "website" | "phoneNumber" | "phoneNumberVerified" | "gender" | "birthday" | "zoneinfo" | "gssDelegationCredential" | "profileScopeConsentText" | "emailScopeConsentText" | "addressScopeConsentText" | "phoneScopeConsentText" | "offlineAccessScopeConsentText" | "samlRoleListScopeConsentText" | "rolesScopeConsentText" | "role_admin" | "role_realm-admin" | "role_create-realm" | "role_view-realm" | "role_view-users" | "role_view-applications" | "role_view-clients" | "role_view-events" | "role_view-identity-providers" | "role_manage-realm" | "role_manage-users" | "role_manage-applications" | "role_manage-identity-providers" | "role_manage-clients" | "role_manage-events" | "role_view-profile" | "role_manage-account" | "role_manage-account-links" | "role_read-token" | "role_offline-access" | "client_account" | "client_account-console" | "client_security-admin-console" | "client_admin-cli" | "client_realm-management" | "client_broker" | "requiredFields" | "backToApplication" | "inResource" | "irreversibleAction" | "deletingImplies" | "errasingData" | "loggingOutImmediately" | "accountUnusable" | "missingUsernameMessage" | "missingFirstNameMessage" | "invalidEmailMessage" | "missingLastNameMessage" | "missingEmailMessage" | "missingPasswordMessage" | "notMatchPasswordMessage" | "invalidUserMessage" | "missingTotpMessage" | "missingTotpDeviceNameMessage" | "invalidPasswordExistingMessage" | "invalidPasswordConfirmMessage" | "invalidTotpMessage" | "usernameExistsMessage" | "emailExistsMessage" | "readOnlyUsernameMessage" | "accountUpdatedMessage" | "accountPasswordUpdatedMessage" | "identityProviderNotFoundMessage" | "identityProviderAlreadyLinkedMessage" | "consentDenied" | "access-denied-when-idp-auth" | "accountDisabledMessage" | "accountTemporarilyDisabledMessage" | "invalidPasswordMinLengthMessage" | "invalidPasswordMaxLengthMessage" | "invalidPasswordMinLowerCaseCharsMessage" | "invalidPasswordMinDigitsMessage" | "invalidPasswordMinUpperCaseCharsMessage" | "invalidPasswordMinSpecialCharsMessage" | "invalidPasswordNotUsernameMessage" | "invalidPasswordNotEmailMessage" | "invalidPasswordRegexPatternMessage" | "invalidPasswordHistoryMessage" | "invalidPasswordBlacklistedMessage" | "invalidPasswordGenericMessage" | "locale_ar" | "locale_ca" | "locale_cs" | "locale_de" | "locale_en" | "locale_es" | "locale_fr" | "locale_hu" | "locale_it" | "locale_ja" | "locale_lt" | "locale_nl" | "locale_no" | "locale_pl" | "locale_pt-BR" | "locale_ru" | "locale_sk" | "locale_sv" | "locale_th" | "locale_tr" | "locale_uk" | "locale_zh-CN" | "locale_fi" | "clientNotFoundMessage" | "openshift.scope.user_info" | "openshift.scope.user_check-access" | "openshift.scope.user_full" | "openshift.scope.list-projects" | "error-invalid-value" | "error-invalid-blank" | "error-empty" | "error-invalid-length" | "error-invalid-length-too-short" | "error-invalid-length-too-long" | "error-invalid-email" | "error-invalid-number" | "error-number-out-of-range" | "error-number-out-of-range-too-small" | "error-number-out-of-range-too-big" | "error-pattern-no-match" | "error-invalid-uri" | "error-invalid-uri-scheme" | "error-invalid-uri-fragment" | "error-user-attribute-required" | "error-invalid-date" | "error-user-attribute-read-only" | "error-username-invalid-character" | "error-person-name-invalid-character" | "remove" | "usb" | "nfc" | "bluetooth" | "doRegister" | "doRegisterSecurityKey" | "doSubmit" | "doBack" | "doYes" | "doNo" | "doContinue" | "doIgnore" | "doAccept" | "doDecline" | "doForgotPassword" | "doClickHere" | "doImpersonate" | "doTryAgain" | "doTryAnotherWay" | "doConfirmDelete" | "errorDeletingAccount" | "deletingAccountForbidden" | "kerberosNotConfigured" | "kerberosNotConfiguredTitle" | "bypassKerberosDetail" | "kerberosNotSetUp" | "registerTitle" | "loginAccountTitle" | "loginTitle" | "loginTitleHtml" | "impersonateTitle" | "impersonateTitleHtml" | "realmChoice" | "unknownUser" | "loginTotpTitle" | "loginProfileTitle" | "loginIdpReviewProfileTitle" | "loginTimeout" | "reauthenticate" | "authenticateStrong" | "oauthGrantTitle" | "oauthGrantTitleHtml" | "oauthGrantInformation" | "oauthGrantReview" | "oauthGrantTos" | "oauthGrantPolicy" | "errorTitle" | "errorTitleHtml" | "emailVerifyTitle" | "emailForgotTitle" | "updateEmailTitle" | "emailUpdateConfirmationSentTitle" | "emailUpdateConfirmationSent" | "emailUpdatedTitle" | "emailUpdated" | "codeSuccessTitle" | "codeErrorTitle" | "displayUnsupported" | "browserRequired" | "browserContinue" | "browserContinuePrompt" | "browserContinueAnswer" | "internal" | "unknown" | "termsTitle" | "termsText" | "termsPlainText" | "termsAcceptanceRequired" | "acceptTerms" | "deleteCredentialTitle" | "deleteCredentialMessage" | "recaptchaFailed" | "recaptchaNotConfigured" | "noAccount" | "usernameOrEmail" | "passwordNewConfirm" | "hidePassword" | "showPassword" | "rememberMe" | "logoutOtherSessions" | "restartLoginTooltip" | "loginTotpIntro" | "loginTotpStep1" | "loginTotpStep2" | "loginTotpStep3" | "loginTotpStep3DeviceName" | "loginTotpManualStep2" | "loginTotpManualStep3" | "loginTotpUnableToScan" | "loginTotpScanBarcode" | "loginCredential" | "loginOtpOneTime" | "loginTotpType" | "loginTotpAlgorithm" | "loginTotpDigits" | "loginTotpInterval" | "loginTotpCounter" | "loginTotpDeviceName" | "loginTotp.totp" | "loginTotp.hotp" | "loginChooseAuthenticator" | "oauthGrantRequest" | "oauth2DeviceVerificationTitle" | "verifyOAuth2DeviceUserCode" | "oauth2DeviceInvalidUserCodeMessage" | "oauth2DeviceExpiredUserCodeMessage" | "oauth2DeviceVerificationCompleteHeader" | "oauth2DeviceVerificationCompleteMessage" | "oauth2DeviceVerificationFailedHeader" | "oauth2DeviceVerificationFailedMessage" | "oauth2DeviceConsentDeniedMessage" | "oauth2DeviceAuthorizationGrantDisabledMessage" | "emailVerifyInstruction1" | "emailVerifyInstruction2" | "emailVerifyInstruction3" | "emailLinkIdpTitle" | "emailLinkIdp1" | "emailLinkIdp2" | "emailLinkIdp3" | "emailLinkIdp4" | "emailLinkIdp5" | "backToLogin" | "emailInstruction" | "emailInstructionUsername" | "copyCodeInstruction" | "pageExpiredTitle" | "pageExpiredMsg1" | "pageExpiredMsg2" | "personalInfo" | "role_create-client" | "invalidUsernameMessage" | "invalidUsernameOrEmailMessage" | "invalidPasswordMessage" | "expiredCodeMessage" | "expiredActionMessage" | "expiredActionTokenNoSessionMessage" | "expiredActionTokenSessionExistsMessage" | "sessionLimitExceeded" | "error-reset-otp-missing-id" | "federatedIdentityExistsMessage" | "federatedIdentityUnavailableMessage" | "federatedIdentityUnmatchedEssentialClaimMessage" | "confirmLinkIdpTitle" | "federatedIdentityConfirmLinkMessage" | "federatedIdentityConfirmReauthenticateMessage" | "nestedFirstBrokerFlowMessage" | "confirmLinkIdpReviewProfile" | "confirmLinkIdpContinue" | "configureTotpMessage" | "configureBackupCodesMessage" | "updateProfileMessage" | "updateEmailMessage" | "resetPasswordMessage" | "verifyEmailMessage" | "linkIdpMessage" | "emailSentMessage" | "emailSendErrorMessage" | "delegationCompleteHeader" | "delegationCompleteMessage" | "delegationFailedHeader" | "delegationFailedMessage" | "failedToProcessResponseMessage" | "httpsRequiredMessage" | "realmNotEnabledMessage" | "invalidRequestMessage" | "successLogout" | "failedLogout" | "unknownLoginRequesterMessage" | "loginRequesterNotEnabledMessage" | "bearerOnlyMessage" | "standardFlowDisabledMessage" | "implicitFlowDisabledMessage" | "invalidRedirectUriMessage" | "unsupportedNameIdFormatMessage" | "invalidRequesterMessage" | "registrationNotAllowedMessage" | "resetCredentialNotAllowedMessage" | "permissionNotApprovedMessage" | "noRelayStateInResponseMessage" | "insufficientPermissionMessage" | "couldNotProceedWithAuthenticationRequestMessage" | "couldNotObtainTokenMessage" | "unexpectedErrorRetrievingTokenMessage" | "unexpectedErrorHandlingResponseMessage" | "identityProviderAuthenticationFailedMessage" | "couldNotSendAuthenticationRequestMessage" | "unexpectedErrorHandlingRequestMessage" | "invalidAccessCodeMessage" | "sessionNotActiveMessage" | "invalidCodeMessage" | "cookieNotFoundMessage" | "insufficientLevelOfAuthentication" | "identityProviderUnexpectedErrorMessage" | "identityProviderMissingStateMessage" | "identityProviderMissingCodeOrErrorMessage" | "identityProviderInvalidResponseMessage" | "identityProviderInvalidSignatureMessage" | "identityProviderLinkSuccess" | "staleCodeMessage" | "realmSupportsNoCredentialsMessage" | "credentialSetupRequired" | "identityProviderNotUniqueMessage" | "emailVerifiedMessage" | "emailVerifiedAlreadyMessage" | "staleEmailVerificationLink" | "confirmAccountLinking" | "confirmEmailAddressVerification" | "confirmExecutionOfActions" | "locale_da" | "locale_lv" | "missingParameterMessage" | "clientDisabledMessage" | "invalidParameterMessage" | "alreadyLoggedIn" | "differentUserAuthenticated" | "brokerLinkingSessionExpired" | "proceedWithAction" | "acrNotFulfilled" | "requiredAction.CONFIGURE_TOTP" | "requiredAction.TERMS_AND_CONDITIONS" | "requiredAction.UPDATE_PASSWORD" | "requiredAction.UPDATE_PROFILE" | "requiredAction.VERIFY_EMAIL" | "requiredAction.CONFIGURE_RECOVERY_AUTHN_CODES" | "requiredAction.webauthn-register-passwordless" | "invalidTokenRequiredActions" | "doX509Login" | "clientCertificate" | "noCertificate" | "pageNotFound" | "internalServerError" | "console-username" | "console-password" | "console-otp" | "console-new-password" | "console-confirm-password" | "console-update-password" | "console-verify-email" | "console-email-code" | "console-accept-terms" | "console-accept" | "saml.post-form.title" | "saml.post-form.message" | "saml.post-form.js-disabled" | "saml.artifactResolutionServiceInvalidResponse" | "otp-display-name" | "otp-help-text" | "otp-reset-description" | "password-display-name" | "password-help-text" | "auth-username-form-display-name" | "auth-username-form-help-text" | "auth-username-password-form-display-name" | "auth-username-password-form-help-text" | "auth-recovery-authn-code-form-display-name" | "auth-recovery-authn-code-form-help-text" | "auth-recovery-code-info-message" | "auth-recovery-code-prompt" | "auth-recovery-code-header" | "recovery-codes-error-invalid" | "recovery-code-config-header" | "recovery-code-config-warning-title" | "recovery-code-config-warning-message" | "recovery-codes-print" | "recovery-codes-download" | "recovery-codes-copy" | "recovery-codes-copied" | "recovery-codes-confirmation-message" | "recovery-codes-action-complete" | "recovery-codes-action-cancel" | "recovery-codes-download-file-header" | "recovery-codes-download-file-description" | "recovery-codes-download-file-date" | "recovery-codes-label-default" | "webauthn-display-name" | "webauthn-help-text" | "webauthn-passwordless-display-name" | "webauthn-passwordless-help-text" | "webauthn-login-title" | "webauthn-registration-title" | "webauthn-available-authenticators" | "webauthn-unsupported-browser-text" | "webauthn-doAuthenticate" | "webauthn-createdAt-label" | "webauthn-error-title" | "webauthn-error-registration" | "webauthn-error-api-get" | "webauthn-error-different-user" | "webauthn-error-auth-verification" | "webauthn-error-register-verification" | "webauthn-error-user-not-found" | "identity-provider-redirector" | "identity-provider-login-label" | "idp-email-verification-display-name" | "idp-email-verification-help-text" | "idp-username-password-form-display-name" | "idp-username-password-form-help-text" | "finalDeletionConfirmation" | "deleteAccountConfirm" | "userDeletedSuccessfully" | "access-denied" | "frontchannel-logout.title" | "frontchannel-logout.message" | "logoutConfirmTitle" | "logoutConfirmHeader" | "doLogout" | "error-invalid-multivalued-size" | "shouldBeEqual" | "shouldBeDifferent" | "shouldMatchPattern" | "mustBeAnInteger" | "notAValidOption" | "selectAnOption" | "addValue" | "languages" | ExtraMessageKey>;
|
95
98
|
};
|
package/login/i18n/i18n.js
CHANGED
@@ -1,13 +1,11 @@
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
2
2
|
import "../../tools/Object.fromEntries";
|
3
|
-
import { useEffect, useState } from "react";
|
4
3
|
import { assert } from "tsafe/assert";
|
5
4
|
import messages_fallbackLanguage from "./baseMessages/en";
|
6
5
|
import { getMessages } from "./baseMessages";
|
7
|
-
import { Reflect } from "tsafe/Reflect";
|
8
6
|
export const fallbackLanguageTag = "en";
|
9
7
|
assert();
|
10
|
-
function createGetI18n(
|
8
|
+
export function createGetI18n(messageBundle) {
|
11
9
|
const cachedResultByKcContext = new WeakMap();
|
12
10
|
function getI18n(params) {
|
13
11
|
var _a, _b, _c, _d;
|
@@ -21,7 +19,7 @@ function createGetI18n(extraMessages) {
|
|
21
19
|
}
|
22
20
|
const partialI18n = {
|
23
21
|
currentLanguageTag: (_b = (_a = kcContext.locale) === null || _a === void 0 ? void 0 : _a.currentLanguageTag) !== null && _b !== void 0 ? _b : fallbackLanguageTag,
|
24
|
-
|
22
|
+
getChangeLocaleUrl: newLanguageTag => {
|
25
23
|
const { locale } = kcContext;
|
26
24
|
assert(locale !== undefined, "Internationalization not enabled");
|
27
25
|
const targetSupportedLocale = locale.supported.find(({ languageTag }) => languageTag === newLanguageTag);
|
@@ -32,18 +30,21 @@ function createGetI18n(extraMessages) {
|
|
32
30
|
};
|
33
31
|
const { createI18nTranslationFunctions } = createI18nTranslationFunctionsFactory({
|
34
32
|
messages_fallbackLanguage,
|
35
|
-
|
36
|
-
|
37
|
-
|
33
|
+
messageBundle_fallbackLanguage: messageBundle[fallbackLanguageTag],
|
34
|
+
messageBundle_currentLanguage: messageBundle[partialI18n.currentLanguageTag],
|
35
|
+
realmMessageBundleUserProfile: kcContext["x-keycloakify"].realmMessageBundleUserProfile,
|
36
|
+
realmMessageBundleTermsText: kcContext["x-keycloakify"].realmMessageBundleTermsText
|
38
37
|
});
|
39
38
|
const isCurrentLanguageFallbackLanguage = partialI18n.currentLanguageTag === fallbackLanguageTag;
|
40
39
|
const result = {
|
41
|
-
i18n: Object.assign(Object.assign(Object.assign({}, partialI18n), createI18nTranslationFunctions({
|
40
|
+
i18n: Object.assign(Object.assign(Object.assign({}, partialI18n), createI18nTranslationFunctions({
|
41
|
+
messages_currentLanguage: isCurrentLanguageFallbackLanguage ? messages_fallbackLanguage : undefined
|
42
|
+
})), { isFetchingTranslations: !isCurrentLanguageFallbackLanguage }),
|
42
43
|
prI18n_currentLanguage: isCurrentLanguageFallbackLanguage
|
43
44
|
? undefined
|
44
45
|
: (async () => {
|
45
|
-
const
|
46
|
-
const i18n_currentLanguage = Object.assign(Object.assign(Object.assign({}, partialI18n), createI18nTranslationFunctions({
|
46
|
+
const messages_currentLanguage = await getMessages(partialI18n.currentLanguageTag);
|
47
|
+
const i18n_currentLanguage = Object.assign(Object.assign(Object.assign({}, partialI18n), createI18nTranslationFunctions({ messages_currentLanguage })), { isFetchingTranslations: false });
|
47
48
|
// NOTE: This promise.resolve is just because without it we TypeScript
|
48
49
|
// gives a Variable 'result' is used before being assigned. error
|
49
50
|
await Promise.resolve().then(() => {
|
@@ -58,37 +59,21 @@ function createGetI18n(extraMessages) {
|
|
58
59
|
}
|
59
60
|
return { getI18n };
|
60
61
|
}
|
61
|
-
export function createUseI18n(extraMessages) {
|
62
|
-
const { getI18n } = createGetI18n(extraMessages);
|
63
|
-
function useI18n(params) {
|
64
|
-
const { kcContext } = params;
|
65
|
-
const { i18n, prI18n_currentLanguage } = getI18n({ kcContext });
|
66
|
-
const [i18n_toReturn, setI18n_toReturn] = useState(i18n);
|
67
|
-
useEffect(() => {
|
68
|
-
let isActive = true;
|
69
|
-
prI18n_currentLanguage === null || prI18n_currentLanguage === void 0 ? void 0 : prI18n_currentLanguage.then(i18n => {
|
70
|
-
if (!isActive) {
|
71
|
-
return;
|
72
|
-
}
|
73
|
-
setI18n_toReturn(i18n);
|
74
|
-
});
|
75
|
-
return () => {
|
76
|
-
isActive = false;
|
77
|
-
};
|
78
|
-
}, []);
|
79
|
-
return { i18n: i18n_toReturn };
|
80
|
-
}
|
81
|
-
return { useI18n, ofTypeI18n: Reflect() };
|
82
|
-
}
|
83
62
|
function createI18nTranslationFunctionsFactory(params) {
|
84
|
-
const {
|
85
|
-
const messages_fallbackLanguage = Object.assign(Object.assign({}, params.messages_fallbackLanguage), params.
|
63
|
+
const { messageBundle_currentLanguage, realmMessageBundleUserProfile, realmMessageBundleTermsText } = params;
|
64
|
+
const messages_fallbackLanguage = Object.assign(Object.assign({}, params.messages_fallbackLanguage), params.messageBundle_fallbackLanguage);
|
86
65
|
function createI18nTranslationFunctions(params) {
|
87
|
-
const
|
66
|
+
const messages_currentLanguage = Object.assign(Object.assign({}, params.messages_currentLanguage), messageBundle_currentLanguage);
|
88
67
|
function resolveMsg(props) {
|
89
|
-
var _a;
|
90
68
|
const { key, args, doRenderAsHtml } = props;
|
91
|
-
const messageOrUndefined = (
|
69
|
+
const messageOrUndefined = (() => {
|
70
|
+
var _a;
|
71
|
+
const messageOrUndefined = (_a = messages_currentLanguage[key]) !== null && _a !== void 0 ? _a : messages_fallbackLanguage[key];
|
72
|
+
if (key === "termsText") {
|
73
|
+
return realmMessageBundleTermsText;
|
74
|
+
}
|
75
|
+
return messageOrUndefined;
|
76
|
+
})();
|
92
77
|
if (messageOrUndefined === undefined) {
|
93
78
|
return undefined;
|
94
79
|
}
|
@@ -118,8 +103,8 @@ function createI18nTranslationFunctionsFactory(params) {
|
|
118
103
|
}
|
119
104
|
function resolveMsgAdvanced(props) {
|
120
105
|
const { key, args, doRenderAsHtml } = props;
|
121
|
-
if (
|
122
|
-
const resolvedMessage =
|
106
|
+
if (realmMessageBundleUserProfile !== undefined && key in realmMessageBundleUserProfile) {
|
107
|
+
const resolvedMessage = realmMessageBundleUserProfile[key];
|
123
108
|
return doRenderAsHtml ? (_jsx("span", {
|
124
109
|
// NOTE: The message is trusted. The arguments are not but are escaped.
|
125
110
|
dangerouslySetInnerHTML: {
|
package/login/i18n/i18n.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"i18n.js","sourceRoot":"","sources":["../../src/login/i18n/i18n.tsx"],"names":[],"mappings":";AAAA,OAAO,sCAAsC,CAAC;AAC9C,OAAO,EAAE,
|
1
|
+
{"version":3,"file":"i18n.js","sourceRoot":"","sources":["../../src/login/i18n/i18n.tsx"],"names":[],"mappings":";AAAA,OAAO,sCAAsC,CAAC;AAC9C,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AACtC,OAAO,yBAAyB,MAAM,mBAAmB,CAAC;AAC1D,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAG7C,MAAM,CAAC,MAAM,mBAAmB,GAAG,IAAI,CAAC;AAaxC,MAAM,EAAkD,CAAC;AAyEzD,MAAM,UAAU,aAAa,CAAyC,aAErE;IAKG,MAAM,uBAAuB,GAAG,IAAI,OAAO,EAAyB,CAAC;IAErE,SAAS,OAAO,CAAC,MAAoC;;QACjD,MAAM,EAAE,SAAS,EAAE,GAAG,MAAM,CAAC;QAE7B,SAAS,EAAE;YACP,MAAM,YAAY,GAAG,uBAAuB,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC;YAE5D,IAAI,YAAY,KAAK,SAAS,EAAE;gBAC5B,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CAAC,EAAE,EAAE;;gBAC1E,MAAM,SAAS,GAAG,MAAA,UAAU,CAAC,EAAE,GAAG,EAAE,KAAK,EAAE,IAAI,EAAE,YAAY,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,cAAc,EAAE,KAAK,EAAE,CAAC,mCAAI,KAAK,CAAC;gBAE7G,YAAY,GAAG,KAAK,CAAC;gBAErB,OAAO,SAAS,CAAC;YACrB,CAAC,CAAC,CAAC;YAEH,OAAO,cAAc,CAAC,CAAC,CAAC,eAAM,uBAAuB,EAAE,EAAE,MAAM,EAAE,sBAAsB,EAAE,GAAI,CAAC,CAAC,CAAC,sBAAsB,CAAC;QAC3H,CAAC;QAED,OAAO;YACH,MAAM,EAAE,CAAC,GAAG,EAAE,GAAG,IAAI,EAAE,EAAE,CAAC,UAAU,CAAC,EAAE,GAAG,EAAE,IAAI,EAAE,cAAc,EAAE,KAAK,EAAE,CAAW;YACpF,GAAG,EAAE,CAAC,GAAG,EAAE,GAAG,IAAI,EAAE,EAAE,CAAC,UAAU,CAAC,EAAE,GAAG,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,EAAE,CAAgB;YACrF,WAAW,EAAE,CAAC,GAAG,EAAE,GAAG,IAAI,EAAE,EAAE,CAC1B,kBAAkB,CAAC;gBACf,GAAG;gBACH,IAAI;gBACJ,cAAc,EAAE,IAAI;aACvB,CAAgB;YACrB,cAAc,EAAE,CAAC,GAAG,EAAE,GAAG,IAAI,EAAE,EAAE,CAC7B,kBAAkB,CAAC;gBACf,GAAG;gBACH,IAAI;gBACJ,cAAc,EAAE,KAAK;aACxB,CAAW;SACnB,CAAC;IACN,CAAC;IAED,OAAO,EAAE,8BAA8B,EAAE,CAAC;AAC9C,CAAC"}
|
package/login/i18n/index.d.ts
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
import type { GenericI18n, MessageKey, KcContextLike } from "./i18n";
|
2
2
|
export type { MessageKey, KcContextLike };
|
3
3
|
export type I18n = GenericI18n<MessageKey>;
|
4
|
-
export { createUseI18n } from "./
|
4
|
+
export { createUseI18n } from "./useI18n";
|
5
5
|
export { fallbackLanguageTag } from "./i18n";
|
package/login/i18n/index.js
CHANGED
package/login/i18n/index.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/login/i18n/index.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,aAAa,EAAE,MAAM,
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/login/i18n/index.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,mBAAmB,EAAE,MAAM,QAAQ,CAAC"}
|
@@ -0,0 +1,13 @@
|
|
1
|
+
import { type GenericI18n, type KcContextLike } from "./i18n";
|
2
|
+
export declare function createUseI18n<ExtraMessageKey extends string = never>(extraMessages: {
|
3
|
+
[languageTag: string]: {
|
4
|
+
[key in ExtraMessageKey]: string;
|
5
|
+
};
|
6
|
+
}): {
|
7
|
+
useI18n: (params: {
|
8
|
+
kcContext: KcContextLike;
|
9
|
+
}) => {
|
10
|
+
i18n: GenericI18n<"region" | "address" | "email" | "password" | "totpAppFreeOTPName" | "totpAppMicrosoftAuthenticatorName" | "totpAppGoogleName" | "doCancel" | "doLogIn" | "noAccessMessage" | "updatePasswordTitle" | "updatePasswordMessage" | "authenticatorCode" | "firstName" | "givenName" | "fullName" | "lastName" | "familyName" | "passwordConfirm" | "passwordNew" | "username" | "street" | "locality" | "postal_code" | "country" | "emailVerified" | "website" | "phoneNumber" | "phoneNumberVerified" | "gender" | "birthday" | "zoneinfo" | "gssDelegationCredential" | "profileScopeConsentText" | "emailScopeConsentText" | "addressScopeConsentText" | "phoneScopeConsentText" | "offlineAccessScopeConsentText" | "samlRoleListScopeConsentText" | "rolesScopeConsentText" | "role_admin" | "role_realm-admin" | "role_create-realm" | "role_view-realm" | "role_view-users" | "role_view-applications" | "role_view-clients" | "role_view-events" | "role_view-identity-providers" | "role_manage-realm" | "role_manage-users" | "role_manage-applications" | "role_manage-identity-providers" | "role_manage-clients" | "role_manage-events" | "role_view-profile" | "role_manage-account" | "role_manage-account-links" | "role_read-token" | "role_offline-access" | "client_account" | "client_account-console" | "client_security-admin-console" | "client_admin-cli" | "client_realm-management" | "client_broker" | "requiredFields" | "backToApplication" | "inResource" | "irreversibleAction" | "deletingImplies" | "errasingData" | "loggingOutImmediately" | "accountUnusable" | "missingUsernameMessage" | "missingFirstNameMessage" | "invalidEmailMessage" | "missingLastNameMessage" | "missingEmailMessage" | "missingPasswordMessage" | "notMatchPasswordMessage" | "invalidUserMessage" | "missingTotpMessage" | "missingTotpDeviceNameMessage" | "invalidPasswordExistingMessage" | "invalidPasswordConfirmMessage" | "invalidTotpMessage" | "usernameExistsMessage" | "emailExistsMessage" | "readOnlyUsernameMessage" | "accountUpdatedMessage" | "accountPasswordUpdatedMessage" | "identityProviderNotFoundMessage" | "identityProviderAlreadyLinkedMessage" | "consentDenied" | "access-denied-when-idp-auth" | "accountDisabledMessage" | "accountTemporarilyDisabledMessage" | "invalidPasswordMinLengthMessage" | "invalidPasswordMaxLengthMessage" | "invalidPasswordMinLowerCaseCharsMessage" | "invalidPasswordMinDigitsMessage" | "invalidPasswordMinUpperCaseCharsMessage" | "invalidPasswordMinSpecialCharsMessage" | "invalidPasswordNotUsernameMessage" | "invalidPasswordNotEmailMessage" | "invalidPasswordRegexPatternMessage" | "invalidPasswordHistoryMessage" | "invalidPasswordBlacklistedMessage" | "invalidPasswordGenericMessage" | "locale_ar" | "locale_ca" | "locale_cs" | "locale_de" | "locale_en" | "locale_es" | "locale_fr" | "locale_hu" | "locale_it" | "locale_ja" | "locale_lt" | "locale_nl" | "locale_no" | "locale_pl" | "locale_pt-BR" | "locale_ru" | "locale_sk" | "locale_sv" | "locale_th" | "locale_tr" | "locale_uk" | "locale_zh-CN" | "locale_fi" | "clientNotFoundMessage" | "openshift.scope.user_info" | "openshift.scope.user_check-access" | "openshift.scope.user_full" | "openshift.scope.list-projects" | "error-invalid-value" | "error-invalid-blank" | "error-empty" | "error-invalid-length" | "error-invalid-length-too-short" | "error-invalid-length-too-long" | "error-invalid-email" | "error-invalid-number" | "error-number-out-of-range" | "error-number-out-of-range-too-small" | "error-number-out-of-range-too-big" | "error-pattern-no-match" | "error-invalid-uri" | "error-invalid-uri-scheme" | "error-invalid-uri-fragment" | "error-user-attribute-required" | "error-invalid-date" | "error-user-attribute-read-only" | "error-username-invalid-character" | "error-person-name-invalid-character" | "remove" | "usb" | "nfc" | "bluetooth" | "doRegister" | "doRegisterSecurityKey" | "doSubmit" | "doBack" | "doYes" | "doNo" | "doContinue" | "doIgnore" | "doAccept" | "doDecline" | "doForgotPassword" | "doClickHere" | "doImpersonate" | "doTryAgain" | "doTryAnotherWay" | "doConfirmDelete" | "errorDeletingAccount" | "deletingAccountForbidden" | "kerberosNotConfigured" | "kerberosNotConfiguredTitle" | "bypassKerberosDetail" | "kerberosNotSetUp" | "registerTitle" | "loginAccountTitle" | "loginTitle" | "loginTitleHtml" | "impersonateTitle" | "impersonateTitleHtml" | "realmChoice" | "unknownUser" | "loginTotpTitle" | "loginProfileTitle" | "loginIdpReviewProfileTitle" | "loginTimeout" | "reauthenticate" | "authenticateStrong" | "oauthGrantTitle" | "oauthGrantTitleHtml" | "oauthGrantInformation" | "oauthGrantReview" | "oauthGrantTos" | "oauthGrantPolicy" | "errorTitle" | "errorTitleHtml" | "emailVerifyTitle" | "emailForgotTitle" | "updateEmailTitle" | "emailUpdateConfirmationSentTitle" | "emailUpdateConfirmationSent" | "emailUpdatedTitle" | "emailUpdated" | "codeSuccessTitle" | "codeErrorTitle" | "displayUnsupported" | "browserRequired" | "browserContinue" | "browserContinuePrompt" | "browserContinueAnswer" | "internal" | "unknown" | "termsTitle" | "termsText" | "termsPlainText" | "termsAcceptanceRequired" | "acceptTerms" | "deleteCredentialTitle" | "deleteCredentialMessage" | "recaptchaFailed" | "recaptchaNotConfigured" | "noAccount" | "usernameOrEmail" | "passwordNewConfirm" | "hidePassword" | "showPassword" | "rememberMe" | "logoutOtherSessions" | "restartLoginTooltip" | "loginTotpIntro" | "loginTotpStep1" | "loginTotpStep2" | "loginTotpStep3" | "loginTotpStep3DeviceName" | "loginTotpManualStep2" | "loginTotpManualStep3" | "loginTotpUnableToScan" | "loginTotpScanBarcode" | "loginCredential" | "loginOtpOneTime" | "loginTotpType" | "loginTotpAlgorithm" | "loginTotpDigits" | "loginTotpInterval" | "loginTotpCounter" | "loginTotpDeviceName" | "loginTotp.totp" | "loginTotp.hotp" | "loginChooseAuthenticator" | "oauthGrantRequest" | "oauth2DeviceVerificationTitle" | "verifyOAuth2DeviceUserCode" | "oauth2DeviceInvalidUserCodeMessage" | "oauth2DeviceExpiredUserCodeMessage" | "oauth2DeviceVerificationCompleteHeader" | "oauth2DeviceVerificationCompleteMessage" | "oauth2DeviceVerificationFailedHeader" | "oauth2DeviceVerificationFailedMessage" | "oauth2DeviceConsentDeniedMessage" | "oauth2DeviceAuthorizationGrantDisabledMessage" | "emailVerifyInstruction1" | "emailVerifyInstruction2" | "emailVerifyInstruction3" | "emailLinkIdpTitle" | "emailLinkIdp1" | "emailLinkIdp2" | "emailLinkIdp3" | "emailLinkIdp4" | "emailLinkIdp5" | "backToLogin" | "emailInstruction" | "emailInstructionUsername" | "copyCodeInstruction" | "pageExpiredTitle" | "pageExpiredMsg1" | "pageExpiredMsg2" | "personalInfo" | "role_create-client" | "invalidUsernameMessage" | "invalidUsernameOrEmailMessage" | "invalidPasswordMessage" | "expiredCodeMessage" | "expiredActionMessage" | "expiredActionTokenNoSessionMessage" | "expiredActionTokenSessionExistsMessage" | "sessionLimitExceeded" | "error-reset-otp-missing-id" | "federatedIdentityExistsMessage" | "federatedIdentityUnavailableMessage" | "federatedIdentityUnmatchedEssentialClaimMessage" | "confirmLinkIdpTitle" | "federatedIdentityConfirmLinkMessage" | "federatedIdentityConfirmReauthenticateMessage" | "nestedFirstBrokerFlowMessage" | "confirmLinkIdpReviewProfile" | "confirmLinkIdpContinue" | "configureTotpMessage" | "configureBackupCodesMessage" | "updateProfileMessage" | "updateEmailMessage" | "resetPasswordMessage" | "verifyEmailMessage" | "linkIdpMessage" | "emailSentMessage" | "emailSendErrorMessage" | "delegationCompleteHeader" | "delegationCompleteMessage" | "delegationFailedHeader" | "delegationFailedMessage" | "failedToProcessResponseMessage" | "httpsRequiredMessage" | "realmNotEnabledMessage" | "invalidRequestMessage" | "successLogout" | "failedLogout" | "unknownLoginRequesterMessage" | "loginRequesterNotEnabledMessage" | "bearerOnlyMessage" | "standardFlowDisabledMessage" | "implicitFlowDisabledMessage" | "invalidRedirectUriMessage" | "unsupportedNameIdFormatMessage" | "invalidRequesterMessage" | "registrationNotAllowedMessage" | "resetCredentialNotAllowedMessage" | "permissionNotApprovedMessage" | "noRelayStateInResponseMessage" | "insufficientPermissionMessage" | "couldNotProceedWithAuthenticationRequestMessage" | "couldNotObtainTokenMessage" | "unexpectedErrorRetrievingTokenMessage" | "unexpectedErrorHandlingResponseMessage" | "identityProviderAuthenticationFailedMessage" | "couldNotSendAuthenticationRequestMessage" | "unexpectedErrorHandlingRequestMessage" | "invalidAccessCodeMessage" | "sessionNotActiveMessage" | "invalidCodeMessage" | "cookieNotFoundMessage" | "insufficientLevelOfAuthentication" | "identityProviderUnexpectedErrorMessage" | "identityProviderMissingStateMessage" | "identityProviderMissingCodeOrErrorMessage" | "identityProviderInvalidResponseMessage" | "identityProviderInvalidSignatureMessage" | "identityProviderLinkSuccess" | "staleCodeMessage" | "realmSupportsNoCredentialsMessage" | "credentialSetupRequired" | "identityProviderNotUniqueMessage" | "emailVerifiedMessage" | "emailVerifiedAlreadyMessage" | "staleEmailVerificationLink" | "confirmAccountLinking" | "confirmEmailAddressVerification" | "confirmExecutionOfActions" | "locale_da" | "locale_lv" | "missingParameterMessage" | "clientDisabledMessage" | "invalidParameterMessage" | "alreadyLoggedIn" | "differentUserAuthenticated" | "brokerLinkingSessionExpired" | "proceedWithAction" | "acrNotFulfilled" | "requiredAction.CONFIGURE_TOTP" | "requiredAction.TERMS_AND_CONDITIONS" | "requiredAction.UPDATE_PASSWORD" | "requiredAction.UPDATE_PROFILE" | "requiredAction.VERIFY_EMAIL" | "requiredAction.CONFIGURE_RECOVERY_AUTHN_CODES" | "requiredAction.webauthn-register-passwordless" | "invalidTokenRequiredActions" | "doX509Login" | "clientCertificate" | "noCertificate" | "pageNotFound" | "internalServerError" | "console-username" | "console-password" | "console-otp" | "console-new-password" | "console-confirm-password" | "console-update-password" | "console-verify-email" | "console-email-code" | "console-accept-terms" | "console-accept" | "saml.post-form.title" | "saml.post-form.message" | "saml.post-form.js-disabled" | "saml.artifactResolutionServiceInvalidResponse" | "otp-display-name" | "otp-help-text" | "otp-reset-description" | "password-display-name" | "password-help-text" | "auth-username-form-display-name" | "auth-username-form-help-text" | "auth-username-password-form-display-name" | "auth-username-password-form-help-text" | "auth-recovery-authn-code-form-display-name" | "auth-recovery-authn-code-form-help-text" | "auth-recovery-code-info-message" | "auth-recovery-code-prompt" | "auth-recovery-code-header" | "recovery-codes-error-invalid" | "recovery-code-config-header" | "recovery-code-config-warning-title" | "recovery-code-config-warning-message" | "recovery-codes-print" | "recovery-codes-download" | "recovery-codes-copy" | "recovery-codes-copied" | "recovery-codes-confirmation-message" | "recovery-codes-action-complete" | "recovery-codes-action-cancel" | "recovery-codes-download-file-header" | "recovery-codes-download-file-description" | "recovery-codes-download-file-date" | "recovery-codes-label-default" | "webauthn-display-name" | "webauthn-help-text" | "webauthn-passwordless-display-name" | "webauthn-passwordless-help-text" | "webauthn-login-title" | "webauthn-registration-title" | "webauthn-available-authenticators" | "webauthn-unsupported-browser-text" | "webauthn-doAuthenticate" | "webauthn-createdAt-label" | "webauthn-error-title" | "webauthn-error-registration" | "webauthn-error-api-get" | "webauthn-error-different-user" | "webauthn-error-auth-verification" | "webauthn-error-register-verification" | "webauthn-error-user-not-found" | "identity-provider-redirector" | "identity-provider-login-label" | "idp-email-verification-display-name" | "idp-email-verification-help-text" | "idp-username-password-form-display-name" | "idp-username-password-form-help-text" | "finalDeletionConfirmation" | "deleteAccountConfirm" | "userDeletedSuccessfully" | "access-denied" | "frontchannel-logout.title" | "frontchannel-logout.message" | "logoutConfirmTitle" | "logoutConfirmHeader" | "doLogout" | "error-invalid-multivalued-size" | "shouldBeEqual" | "shouldBeDifferent" | "shouldMatchPattern" | "mustBeAnInteger" | "notAValidOption" | "selectAnOption" | "addValue" | "languages" | ExtraMessageKey>;
|
11
|
+
};
|
12
|
+
ofTypeI18n: GenericI18n<"region" | "address" | "email" | "password" | "totpAppFreeOTPName" | "totpAppMicrosoftAuthenticatorName" | "totpAppGoogleName" | "doCancel" | "doLogIn" | "noAccessMessage" | "updatePasswordTitle" | "updatePasswordMessage" | "authenticatorCode" | "firstName" | "givenName" | "fullName" | "lastName" | "familyName" | "passwordConfirm" | "passwordNew" | "username" | "street" | "locality" | "postal_code" | "country" | "emailVerified" | "website" | "phoneNumber" | "phoneNumberVerified" | "gender" | "birthday" | "zoneinfo" | "gssDelegationCredential" | "profileScopeConsentText" | "emailScopeConsentText" | "addressScopeConsentText" | "phoneScopeConsentText" | "offlineAccessScopeConsentText" | "samlRoleListScopeConsentText" | "rolesScopeConsentText" | "role_admin" | "role_realm-admin" | "role_create-realm" | "role_view-realm" | "role_view-users" | "role_view-applications" | "role_view-clients" | "role_view-events" | "role_view-identity-providers" | "role_manage-realm" | "role_manage-users" | "role_manage-applications" | "role_manage-identity-providers" | "role_manage-clients" | "role_manage-events" | "role_view-profile" | "role_manage-account" | "role_manage-account-links" | "role_read-token" | "role_offline-access" | "client_account" | "client_account-console" | "client_security-admin-console" | "client_admin-cli" | "client_realm-management" | "client_broker" | "requiredFields" | "backToApplication" | "inResource" | "irreversibleAction" | "deletingImplies" | "errasingData" | "loggingOutImmediately" | "accountUnusable" | "missingUsernameMessage" | "missingFirstNameMessage" | "invalidEmailMessage" | "missingLastNameMessage" | "missingEmailMessage" | "missingPasswordMessage" | "notMatchPasswordMessage" | "invalidUserMessage" | "missingTotpMessage" | "missingTotpDeviceNameMessage" | "invalidPasswordExistingMessage" | "invalidPasswordConfirmMessage" | "invalidTotpMessage" | "usernameExistsMessage" | "emailExistsMessage" | "readOnlyUsernameMessage" | "accountUpdatedMessage" | "accountPasswordUpdatedMessage" | "identityProviderNotFoundMessage" | "identityProviderAlreadyLinkedMessage" | "consentDenied" | "access-denied-when-idp-auth" | "accountDisabledMessage" | "accountTemporarilyDisabledMessage" | "invalidPasswordMinLengthMessage" | "invalidPasswordMaxLengthMessage" | "invalidPasswordMinLowerCaseCharsMessage" | "invalidPasswordMinDigitsMessage" | "invalidPasswordMinUpperCaseCharsMessage" | "invalidPasswordMinSpecialCharsMessage" | "invalidPasswordNotUsernameMessage" | "invalidPasswordNotEmailMessage" | "invalidPasswordRegexPatternMessage" | "invalidPasswordHistoryMessage" | "invalidPasswordBlacklistedMessage" | "invalidPasswordGenericMessage" | "locale_ar" | "locale_ca" | "locale_cs" | "locale_de" | "locale_en" | "locale_es" | "locale_fr" | "locale_hu" | "locale_it" | "locale_ja" | "locale_lt" | "locale_nl" | "locale_no" | "locale_pl" | "locale_pt-BR" | "locale_ru" | "locale_sk" | "locale_sv" | "locale_th" | "locale_tr" | "locale_uk" | "locale_zh-CN" | "locale_fi" | "clientNotFoundMessage" | "openshift.scope.user_info" | "openshift.scope.user_check-access" | "openshift.scope.user_full" | "openshift.scope.list-projects" | "error-invalid-value" | "error-invalid-blank" | "error-empty" | "error-invalid-length" | "error-invalid-length-too-short" | "error-invalid-length-too-long" | "error-invalid-email" | "error-invalid-number" | "error-number-out-of-range" | "error-number-out-of-range-too-small" | "error-number-out-of-range-too-big" | "error-pattern-no-match" | "error-invalid-uri" | "error-invalid-uri-scheme" | "error-invalid-uri-fragment" | "error-user-attribute-required" | "error-invalid-date" | "error-user-attribute-read-only" | "error-username-invalid-character" | "error-person-name-invalid-character" | "remove" | "usb" | "nfc" | "bluetooth" | "doRegister" | "doRegisterSecurityKey" | "doSubmit" | "doBack" | "doYes" | "doNo" | "doContinue" | "doIgnore" | "doAccept" | "doDecline" | "doForgotPassword" | "doClickHere" | "doImpersonate" | "doTryAgain" | "doTryAnotherWay" | "doConfirmDelete" | "errorDeletingAccount" | "deletingAccountForbidden" | "kerberosNotConfigured" | "kerberosNotConfiguredTitle" | "bypassKerberosDetail" | "kerberosNotSetUp" | "registerTitle" | "loginAccountTitle" | "loginTitle" | "loginTitleHtml" | "impersonateTitle" | "impersonateTitleHtml" | "realmChoice" | "unknownUser" | "loginTotpTitle" | "loginProfileTitle" | "loginIdpReviewProfileTitle" | "loginTimeout" | "reauthenticate" | "authenticateStrong" | "oauthGrantTitle" | "oauthGrantTitleHtml" | "oauthGrantInformation" | "oauthGrantReview" | "oauthGrantTos" | "oauthGrantPolicy" | "errorTitle" | "errorTitleHtml" | "emailVerifyTitle" | "emailForgotTitle" | "updateEmailTitle" | "emailUpdateConfirmationSentTitle" | "emailUpdateConfirmationSent" | "emailUpdatedTitle" | "emailUpdated" | "codeSuccessTitle" | "codeErrorTitle" | "displayUnsupported" | "browserRequired" | "browserContinue" | "browserContinuePrompt" | "browserContinueAnswer" | "internal" | "unknown" | "termsTitle" | "termsText" | "termsPlainText" | "termsAcceptanceRequired" | "acceptTerms" | "deleteCredentialTitle" | "deleteCredentialMessage" | "recaptchaFailed" | "recaptchaNotConfigured" | "noAccount" | "usernameOrEmail" | "passwordNewConfirm" | "hidePassword" | "showPassword" | "rememberMe" | "logoutOtherSessions" | "restartLoginTooltip" | "loginTotpIntro" | "loginTotpStep1" | "loginTotpStep2" | "loginTotpStep3" | "loginTotpStep3DeviceName" | "loginTotpManualStep2" | "loginTotpManualStep3" | "loginTotpUnableToScan" | "loginTotpScanBarcode" | "loginCredential" | "loginOtpOneTime" | "loginTotpType" | "loginTotpAlgorithm" | "loginTotpDigits" | "loginTotpInterval" | "loginTotpCounter" | "loginTotpDeviceName" | "loginTotp.totp" | "loginTotp.hotp" | "loginChooseAuthenticator" | "oauthGrantRequest" | "oauth2DeviceVerificationTitle" | "verifyOAuth2DeviceUserCode" | "oauth2DeviceInvalidUserCodeMessage" | "oauth2DeviceExpiredUserCodeMessage" | "oauth2DeviceVerificationCompleteHeader" | "oauth2DeviceVerificationCompleteMessage" | "oauth2DeviceVerificationFailedHeader" | "oauth2DeviceVerificationFailedMessage" | "oauth2DeviceConsentDeniedMessage" | "oauth2DeviceAuthorizationGrantDisabledMessage" | "emailVerifyInstruction1" | "emailVerifyInstruction2" | "emailVerifyInstruction3" | "emailLinkIdpTitle" | "emailLinkIdp1" | "emailLinkIdp2" | "emailLinkIdp3" | "emailLinkIdp4" | "emailLinkIdp5" | "backToLogin" | "emailInstruction" | "emailInstructionUsername" | "copyCodeInstruction" | "pageExpiredTitle" | "pageExpiredMsg1" | "pageExpiredMsg2" | "personalInfo" | "role_create-client" | "invalidUsernameMessage" | "invalidUsernameOrEmailMessage" | "invalidPasswordMessage" | "expiredCodeMessage" | "expiredActionMessage" | "expiredActionTokenNoSessionMessage" | "expiredActionTokenSessionExistsMessage" | "sessionLimitExceeded" | "error-reset-otp-missing-id" | "federatedIdentityExistsMessage" | "federatedIdentityUnavailableMessage" | "federatedIdentityUnmatchedEssentialClaimMessage" | "confirmLinkIdpTitle" | "federatedIdentityConfirmLinkMessage" | "federatedIdentityConfirmReauthenticateMessage" | "nestedFirstBrokerFlowMessage" | "confirmLinkIdpReviewProfile" | "confirmLinkIdpContinue" | "configureTotpMessage" | "configureBackupCodesMessage" | "updateProfileMessage" | "updateEmailMessage" | "resetPasswordMessage" | "verifyEmailMessage" | "linkIdpMessage" | "emailSentMessage" | "emailSendErrorMessage" | "delegationCompleteHeader" | "delegationCompleteMessage" | "delegationFailedHeader" | "delegationFailedMessage" | "failedToProcessResponseMessage" | "httpsRequiredMessage" | "realmNotEnabledMessage" | "invalidRequestMessage" | "successLogout" | "failedLogout" | "unknownLoginRequesterMessage" | "loginRequesterNotEnabledMessage" | "bearerOnlyMessage" | "standardFlowDisabledMessage" | "implicitFlowDisabledMessage" | "invalidRedirectUriMessage" | "unsupportedNameIdFormatMessage" | "invalidRequesterMessage" | "registrationNotAllowedMessage" | "resetCredentialNotAllowedMessage" | "permissionNotApprovedMessage" | "noRelayStateInResponseMessage" | "insufficientPermissionMessage" | "couldNotProceedWithAuthenticationRequestMessage" | "couldNotObtainTokenMessage" | "unexpectedErrorRetrievingTokenMessage" | "unexpectedErrorHandlingResponseMessage" | "identityProviderAuthenticationFailedMessage" | "couldNotSendAuthenticationRequestMessage" | "unexpectedErrorHandlingRequestMessage" | "invalidAccessCodeMessage" | "sessionNotActiveMessage" | "invalidCodeMessage" | "cookieNotFoundMessage" | "insufficientLevelOfAuthentication" | "identityProviderUnexpectedErrorMessage" | "identityProviderMissingStateMessage" | "identityProviderMissingCodeOrErrorMessage" | "identityProviderInvalidResponseMessage" | "identityProviderInvalidSignatureMessage" | "identityProviderLinkSuccess" | "staleCodeMessage" | "realmSupportsNoCredentialsMessage" | "credentialSetupRequired" | "identityProviderNotUniqueMessage" | "emailVerifiedMessage" | "emailVerifiedAlreadyMessage" | "staleEmailVerificationLink" | "confirmAccountLinking" | "confirmEmailAddressVerification" | "confirmExecutionOfActions" | "locale_da" | "locale_lv" | "missingParameterMessage" | "clientDisabledMessage" | "invalidParameterMessage" | "alreadyLoggedIn" | "differentUserAuthenticated" | "brokerLinkingSessionExpired" | "proceedWithAction" | "acrNotFulfilled" | "requiredAction.CONFIGURE_TOTP" | "requiredAction.TERMS_AND_CONDITIONS" | "requiredAction.UPDATE_PASSWORD" | "requiredAction.UPDATE_PROFILE" | "requiredAction.VERIFY_EMAIL" | "requiredAction.CONFIGURE_RECOVERY_AUTHN_CODES" | "requiredAction.webauthn-register-passwordless" | "invalidTokenRequiredActions" | "doX509Login" | "clientCertificate" | "noCertificate" | "pageNotFound" | "internalServerError" | "console-username" | "console-password" | "console-otp" | "console-new-password" | "console-confirm-password" | "console-update-password" | "console-verify-email" | "console-email-code" | "console-accept-terms" | "console-accept" | "saml.post-form.title" | "saml.post-form.message" | "saml.post-form.js-disabled" | "saml.artifactResolutionServiceInvalidResponse" | "otp-display-name" | "otp-help-text" | "otp-reset-description" | "password-display-name" | "password-help-text" | "auth-username-form-display-name" | "auth-username-form-help-text" | "auth-username-password-form-display-name" | "auth-username-password-form-help-text" | "auth-recovery-authn-code-form-display-name" | "auth-recovery-authn-code-form-help-text" | "auth-recovery-code-info-message" | "auth-recovery-code-prompt" | "auth-recovery-code-header" | "recovery-codes-error-invalid" | "recovery-code-config-header" | "recovery-code-config-warning-title" | "recovery-code-config-warning-message" | "recovery-codes-print" | "recovery-codes-download" | "recovery-codes-copy" | "recovery-codes-copied" | "recovery-codes-confirmation-message" | "recovery-codes-action-complete" | "recovery-codes-action-cancel" | "recovery-codes-download-file-header" | "recovery-codes-download-file-description" | "recovery-codes-download-file-date" | "recovery-codes-label-default" | "webauthn-display-name" | "webauthn-help-text" | "webauthn-passwordless-display-name" | "webauthn-passwordless-help-text" | "webauthn-login-title" | "webauthn-registration-title" | "webauthn-available-authenticators" | "webauthn-unsupported-browser-text" | "webauthn-doAuthenticate" | "webauthn-createdAt-label" | "webauthn-error-title" | "webauthn-error-registration" | "webauthn-error-api-get" | "webauthn-error-different-user" | "webauthn-error-auth-verification" | "webauthn-error-register-verification" | "webauthn-error-user-not-found" | "identity-provider-redirector" | "identity-provider-login-label" | "idp-email-verification-display-name" | "idp-email-verification-help-text" | "idp-username-password-form-display-name" | "idp-username-password-form-help-text" | "finalDeletionConfirmation" | "deleteAccountConfirm" | "userDeletedSuccessfully" | "access-denied" | "frontchannel-logout.title" | "frontchannel-logout.message" | "logoutConfirmTitle" | "logoutConfirmHeader" | "doLogout" | "error-invalid-multivalued-size" | "shouldBeEqual" | "shouldBeDifferent" | "shouldMatchPattern" | "mustBeAnInteger" | "notAValidOption" | "selectAnOption" | "addValue" | "languages" | ExtraMessageKey>;
|
13
|
+
};
|
@@ -0,0 +1,26 @@
|
|
1
|
+
import { useEffect, useState } from "react";
|
2
|
+
import { createGetI18n } from "./i18n";
|
3
|
+
import { Reflect } from "tsafe/Reflect";
|
4
|
+
export function createUseI18n(extraMessages) {
|
5
|
+
const { getI18n } = createGetI18n(extraMessages);
|
6
|
+
function useI18n(params) {
|
7
|
+
const { kcContext } = params;
|
8
|
+
const { i18n, prI18n_currentLanguage } = getI18n({ kcContext });
|
9
|
+
const [i18n_toReturn, setI18n_toReturn] = useState(i18n);
|
10
|
+
useEffect(() => {
|
11
|
+
let isActive = true;
|
12
|
+
prI18n_currentLanguage === null || prI18n_currentLanguage === void 0 ? void 0 : prI18n_currentLanguage.then(i18n => {
|
13
|
+
if (!isActive) {
|
14
|
+
return;
|
15
|
+
}
|
16
|
+
setI18n_toReturn(i18n);
|
17
|
+
});
|
18
|
+
return () => {
|
19
|
+
isActive = false;
|
20
|
+
};
|
21
|
+
}, []);
|
22
|
+
return { i18n: i18n_toReturn };
|
23
|
+
}
|
24
|
+
return { useI18n, ofTypeI18n: Reflect() };
|
25
|
+
}
|
26
|
+
//# sourceMappingURL=useI18n.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useI18n.js","sourceRoot":"","sources":["../../src/login/i18n/useI18n.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,EACH,aAAa,EAIhB,MAAM,QAAQ,CAAC;AAChB,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAExC,MAAM,UAAU,aAAa,CAAyC,aAErE;IAGG,MAAM,EAAE,OAAO,EAAE,GAAG,aAAa,CAAC,aAAa,CAAC,CAAC;IAEjD,SAAS,OAAO,CAAC,MAAoC;QACjD,MAAM,EAAE,SAAS,EAAE,GAAG,MAAM,CAAC;QAE7B,MAAM,EAAE,IAAI,EAAE,sBAAsB,EAAE,GAAG,OAAO,CAAC,EAAE,SAAS,EAAE,CAAC,CAAC;QAEhE,MAAM,CAAC,aAAa,EAAE,gBAAgB,CAAC,GAAG,QAAQ,CAAO,IAAI,CAAC,CAAC;QAE/D,SAAS,CAAC,GAAG,EAAE;YACX,IAAI,QAAQ,GAAG,IAAI,CAAC;YAEpB,sBAAsB,aAAtB,sBAAsB,uBAAtB,sBAAsB,CAAE,IAAI,CAAC,IAAI,CAAC,EAAE;gBAChC,IAAI,CAAC,QAAQ,EAAE;oBACX,OAAO;iBACV;gBAED,gBAAgB,CAAC,IAAI,CAAC,CAAC;YAC3B,CAAC,CAAC,CAAC;YAEH,OAAO,GAAG,EAAE;gBACR,QAAQ,GAAG,KAAK,CAAC;YACrB,CAAC,CAAC;QACN,CAAC,EAAE,EAAE,CAAC,CAAC;QAEP,OAAO,EAAE,IAAI,EAAE,aAAa,EAAE,CAAC;IACnC,CAAC;IAED,OAAO,EAAE,OAAO,EAAE,UAAU,EAAE,OAAO,EAAQ,EAAE,CAAC;AACpD,CAAC"}
|