feat: supply broker context with context
This commit is contained in:
@ -5,7 +5,7 @@ import type { KcContextBase } from "../getKcContext/KcContextBase";
|
|||||||
import { useKcMessage } from "../i18n/useKcMessage";
|
import { useKcMessage } from "../i18n/useKcMessage";
|
||||||
|
|
||||||
export const LoginIdpLinkEmail = memo(({ kcContext, ...props }: { kcContext: KcContextBase.LoginIdpLinkEmail } & KcProps) => {
|
export const LoginIdpLinkEmail = memo(({ kcContext, ...props }: { kcContext: KcContextBase.LoginIdpLinkEmail } & KcProps) => {
|
||||||
const { url, realm, idpAlias } = kcContext;
|
const { url, realm, brokerContext, idpAlias } = kcContext;
|
||||||
|
|
||||||
const { msg } = useKcMessage();
|
const { msg } = useKcMessage();
|
||||||
|
|
||||||
@ -17,7 +17,7 @@ export const LoginIdpLinkEmail = memo(({ kcContext, ...props }: { kcContext: KcC
|
|||||||
formNode={
|
formNode={
|
||||||
<>
|
<>
|
||||||
<p id="instruction1" className="instruction">
|
<p id="instruction1" className="instruction">
|
||||||
{msg("emailLinkIdp1", idpAlias, realm.displayName)}
|
{msg("emailLinkIdp1", idpAlias, brokerContext.username, realm.displayName)}
|
||||||
</p>
|
</p>
|
||||||
<p id="instruction2" className="instruction">
|
<p id="instruction2" className="instruction">
|
||||||
{msg("emailLinkIdp2")} <a href={url.loginAction}>{msg("doClickHere")}</a> {msg("emailLinkIdp3")}
|
{msg("emailLinkIdp2")} <a href={url.loginAction}>{msg("doClickHere")}</a> {msg("emailLinkIdp3")}
|
||||||
|
@ -218,6 +218,9 @@ export declare namespace KcContextBase {
|
|||||||
|
|
||||||
export type LoginIdpLinkEmail = Common & {
|
export type LoginIdpLinkEmail = Common & {
|
||||||
pageId: "login-idp-link-email.ftl";
|
pageId: "login-idp-link-email.ftl";
|
||||||
|
brokerContext: {
|
||||||
|
username: string;
|
||||||
|
};
|
||||||
idpAlias: string;
|
idpAlias: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user