From 51203c7eee074ddde768fb58c73186b2fe355e08 Mon Sep 17 00:00:00 2001 From: adevopg Date: Mon, 13 Jul 2026 10:08:14 +0000 Subject: [PATCH] web-next: paridad de los campos de login con el tema Django MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Turnstile: quitar clases Tailwind del wrapper (my-3/flex/justify-center) → estilo inline neutral centrado, como la web Django. - login/register/recover: el boton ya NO arranca deshabilitado (gris) por falta de captcha; se ve activo como en Django. El captcha lo sigue validando el servidor (devuelve captchaFailed). Se quita el SITE_KEY cliente ya innecesario. - reset-password: pagina que habia quedado sin migrar (usaba nw-btn/ nw-input/mx-auto/text-amber) → PageShell + middle-center-table + inputs planos + recover-button + alert-message, igual que el resto del flujo. Co-Authored-By: Claude Opus 4.8 (1M context) --- web-next/app/[locale]/login/LoginForm.tsx | 3 +- web-next/app/[locale]/recover/RecoverForm.tsx | 3 +- .../app/[locale]/register/RegisterForm.tsx | 3 +- .../app/[locale]/reset-password/ResetForm.tsx | 47 +++++++++++++------ web-next/app/[locale]/reset-password/page.tsx | 12 +++-- web-next/components/Turnstile.tsx | 2 +- 6 files changed, 44 insertions(+), 26 deletions(-) diff --git a/web-next/app/[locale]/login/LoginForm.tsx b/web-next/app/[locale]/login/LoginForm.tsx index cdc79ba..e95b760 100644 --- a/web-next/app/[locale]/login/LoginForm.tsx +++ b/web-next/app/[locale]/login/LoginForm.tsx @@ -6,7 +6,6 @@ import { useRouter } from '@/i18n/navigation' import { Turnstile } from '@/components/Turnstile' const ERROR_KEYS = ['invalidCredentials', 'missingFields', 'invalidRequest', 'captchaFailed'] as const -const SITE_KEY = process.env.NEXT_PUBLIC_TURNSTILE_SITE_KEY export function LoginForm() { const t = useTranslations('Login') @@ -99,7 +98,7 @@ export function LoginForm() { diff --git a/web-next/app/[locale]/recover/RecoverForm.tsx b/web-next/app/[locale]/recover/RecoverForm.tsx index c9b3523..de696d3 100644 --- a/web-next/app/[locale]/recover/RecoverForm.tsx +++ b/web-next/app/[locale]/recover/RecoverForm.tsx @@ -5,7 +5,6 @@ import { useTranslations } from 'next-intl' import { Turnstile } from '@/components/Turnstile' const ERROR_KEYS = ['invalidEmail', 'captchaFailed'] as const -const SITE_KEY = process.env.NEXT_PUBLIC_TURNSTILE_SITE_KEY export function RecoverForm() { const t = useTranslations('Recover') @@ -65,7 +64,7 @@ export function RecoverForm() { - diff --git a/web-next/app/[locale]/register/RegisterForm.tsx b/web-next/app/[locale]/register/RegisterForm.tsx index a8f0f2a..3ab12f4 100644 --- a/web-next/app/[locale]/register/RegisterForm.tsx +++ b/web-next/app/[locale]/register/RegisterForm.tsx @@ -13,7 +13,6 @@ const ERROR_KEYS = [ 'recruiterNotFound', 'captchaFailed', ] as const -const SITE_KEY = process.env.NEXT_PUBLIC_TURNSTILE_SITE_KEY export function RegisterForm() { const t = useTranslations('Register') @@ -97,7 +96,7 @@ export function RegisterForm() { - diff --git a/web-next/app/[locale]/reset-password/ResetForm.tsx b/web-next/app/[locale]/reset-password/ResetForm.tsx index ff3e939..679ef4e 100644 --- a/web-next/app/[locale]/reset-password/ResetForm.tsx +++ b/web-next/app/[locale]/reset-password/ResetForm.tsx @@ -42,25 +42,42 @@ export function ResetForm({ token }: { token: string }) { } } - const field = 'nw-input' - return ( -
-
- setPassword(e.target.value)} required className={field} /> - setConfPassword(e.target.value)} required className={field} /> - + <> + + + + + + + + + + + + + +
+ setPassword(e.target.value)} required /> +
+ setConfPassword(e.target.value)} required /> +
+ +
- {message &&

{message.text}

} +
+
+ {message && ( + {message.text} + )} +
{done && ( -

- - {t('goLogin')} - +

+ {t('goLogin')}

)} -
+ ) } diff --git a/web-next/app/[locale]/reset-password/page.tsx b/web-next/app/[locale]/reset-password/page.tsx index f45077f..d61c4d8 100644 --- a/web-next/app/[locale]/reset-password/page.tsx +++ b/web-next/app/[locale]/reset-password/page.tsx @@ -1,4 +1,5 @@ import { getTranslations, setRequestLocale } from 'next-intl/server' +import { PageShell } from '@/components/PageShell' import { ResetForm } from './ResetForm' export default async function ResetPasswordPage({ @@ -14,9 +15,12 @@ export default async function ResetPasswordPage({ const t = await getTranslations('Reset') return ( -
-

{t('title')}

- -
+ +
+
+ +
+
+
) } diff --git a/web-next/components/Turnstile.tsx b/web-next/components/Turnstile.tsx index 9e99345..dcb955a 100644 --- a/web-next/components/Turnstile.tsx +++ b/web-next/components/Turnstile.tsx @@ -74,5 +74,5 @@ export function Turnstile({ onVerify }: { onVerify: (token: string) => void }) { }, [siteKey]) if (!siteKey) return null - return
+ return
}