mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-11 20:47:32 +00:00
translated
This commit is contained in:
@@ -15,7 +15,6 @@ import {
|
||||
registerTOTP,
|
||||
} from "@/lib/zitadel";
|
||||
import { RegisterTOTPResponse } from "@zitadel/proto/zitadel/user/v2/user_service_pb";
|
||||
import { getLocale, getTranslations } from "next-intl/server";
|
||||
import { headers } from "next/headers";
|
||||
import Link from "next/link";
|
||||
import { redirect } from "next/navigation";
|
||||
@@ -26,8 +25,6 @@ export default async function Page(props: {
|
||||
}) {
|
||||
const params = await props.params;
|
||||
const searchParams = await props.searchParams;
|
||||
const locale = getLocale();
|
||||
const t = await getTranslations({ locale, namespace: "otp" });
|
||||
|
||||
const { loginName, organization, sessionId, requestId, checkAfter } =
|
||||
searchParams;
|
||||
@@ -128,7 +125,9 @@ export default async function Page(props: {
|
||||
return (
|
||||
<DynamicTheme branding={branding}>
|
||||
<div className="flex flex-col items-center space-y-4">
|
||||
<h1>{t("set.title")}</h1>
|
||||
<h1>
|
||||
<Translated i18nKey="set.title" namespace="otp" />
|
||||
</h1>
|
||||
{!session && (
|
||||
<div className="py-4">
|
||||
<Alert>
|
||||
@@ -154,7 +153,12 @@ export default async function Page(props: {
|
||||
|
||||
{totpResponse && "uri" in totpResponse && "secret" in totpResponse ? (
|
||||
<>
|
||||
<p className="ztdl-p">{t("set.totpRegisterDescription")}</p>
|
||||
<p className="ztdl-p">
|
||||
<Translated
|
||||
i18nKey="set.totpRegisterDescription"
|
||||
namespace="otp"
|
||||
/>
|
||||
</p>
|
||||
<div>
|
||||
<TotpRegister
|
||||
uri={totpResponse.uri as string}
|
||||
@@ -188,7 +192,7 @@ export default async function Page(props: {
|
||||
className="self-end"
|
||||
variant={ButtonVariants.Primary}
|
||||
>
|
||||
{t("set.submit")}
|
||||
<Translated i18nKey="set.submit" namespace="otp" />
|
||||
</Button>
|
||||
</Link>
|
||||
</div>
|
||||
|
@@ -7,15 +7,12 @@ import { getSessionCookieById } from "@/lib/cookies";
|
||||
import { getServiceUrlFromHeaders } from "@/lib/service-url";
|
||||
import { loadMostRecentSession } from "@/lib/session";
|
||||
import { getBrandingSettings, getSession } from "@/lib/zitadel";
|
||||
import { getLocale, getTranslations } from "next-intl/server";
|
||||
import { headers } from "next/headers";
|
||||
|
||||
export default async function Page(props: {
|
||||
searchParams: Promise<Record<string | number | symbol, string | undefined>>;
|
||||
}) {
|
||||
const searchParams = await props.searchParams;
|
||||
const locale = getLocale();
|
||||
const t = await getTranslations({ locale, namespace: "passkey" });
|
||||
|
||||
const { loginName, altPassword, requestId, organization, sessionId } =
|
||||
searchParams;
|
||||
@@ -55,7 +52,9 @@ export default async function Page(props: {
|
||||
return (
|
||||
<DynamicTheme branding={branding}>
|
||||
<div className="flex flex-col items-center space-y-4">
|
||||
<h1>{t("verify.title")}</h1>
|
||||
<h1>
|
||||
<Translated i18nKey="verify.title" namespace="passkey" />
|
||||
</h1>
|
||||
|
||||
{sessionFactors && (
|
||||
<UserAvatar
|
||||
@@ -65,7 +64,9 @@ export default async function Page(props: {
|
||||
searchParams={searchParams}
|
||||
></UserAvatar>
|
||||
)}
|
||||
<p className="ztdl-p mb-6 block">{t("verify.description")}</p>
|
||||
<p className="ztdl-p mb-6 block">
|
||||
<Translated i18nKey="verify.description" namespace="passkey" />
|
||||
</p>
|
||||
|
||||
{!(loginName || sessionId) && (
|
||||
<Alert>
|
||||
|
Reference in New Issue
Block a user