From e1e43bfd4a3cf2deb176530d7be7e8ab2bf524f5 Mon Sep 17 00:00:00 2001 From: Innei Date: Fri, 31 Oct 2025 15:28:04 +0800 Subject: [PATCH] style: update header and login card styles for improved UI - Enhanced header button styles for better visual consistency. - Increased width of the card in the forget password and reset password pages for improved layout. - Removed unnecessary button component from the card title for a cleaner design. Signed-off-by: Innei --- .../ssr/client/components/layout/header/index.tsx | 7 +++---- apps/ssr/client/pages/(login)/forget-password.tsx | 15 +++------------ apps/ssr/client/pages/(login)/reset-password.tsx | 12 ++---------- 3 files changed, 8 insertions(+), 26 deletions(-) diff --git a/apps/ssr/client/components/layout/header/index.tsx b/apps/ssr/client/components/layout/header/index.tsx index 0479ccf07..f4e03572c 100644 --- a/apps/ssr/client/components/layout/header/index.tsx +++ b/apps/ssr/client/components/layout/header/index.tsx @@ -99,8 +99,8 @@ export const Header = () => { whileHover={{ scale: 1.02 }} whileTap={{ scale: 0.98 }} className={cn( - "inline-flex items-center gap-2 rounded-full border px-6 font-medium", - "bg-fill/60 text-sm text-text hover:bg-fill/80", + "inline-flex items-center gap-2 rounded-full border border-fill-tertiary px-6 font-medium", + "bg-fill-quinary text-sm text-text backdrop-blur-background hover:bg-fill-tertiary", isCompact ? "h-8" : "h-10", )} > @@ -115,8 +115,7 @@ export const Header = () => { whileTap={{ scale: 0.98 }} className={cn( "inline-flex items-center justify-center rounded-full px-6 font-medium", - "bg-white text-sm text-black shadow-sm hover:shadow", - "dark:bg-zinc-50 dark:text-zinc-900", + "border border-accent/20 bg-accent/90 text-sm text-white shadow-sm hover:shadow", isCompact ? "h-8" : "h-10", )} > diff --git a/apps/ssr/client/pages/(login)/forget-password.tsx b/apps/ssr/client/pages/(login)/forget-password.tsx index bd835274f..76799dc2b 100644 --- a/apps/ssr/client/pages/(login)/forget-password.tsx +++ b/apps/ssr/client/pages/(login)/forget-password.tsx @@ -1,5 +1,5 @@ import { forgetPassword } from "@client/lib/auth" -import { Button, MotionButtonBase } from "@follow/components/ui/button/index.jsx" +import { Button } from "@follow/components/ui/button/index.jsx" import { Card, CardContent, @@ -24,7 +24,6 @@ import { useRef } from "react" import * as React from "react" import { useForm } from "react-hook-form" import { useTranslation } from "react-i18next" -import { useNavigate } from "react-router" import { toast } from "sonner" import { z } from "zod" @@ -38,7 +37,7 @@ const createEmailSchema = (t: any) => export function Component() { const { t } = useTranslation() - const navigate = useNavigate() + const captchaRef = useRef(null) const EmailSchema = createEmailSchema(t) @@ -85,17 +84,9 @@ export function Component() { return (
- + - { - history.length > 1 ? history.back() : navigate("/login") - }} - className="-ml-1 inline-flex cursor-pointer items-center" - > - - {t("login.forget_password.label")} diff --git a/apps/ssr/client/pages/(login)/reset-password.tsx b/apps/ssr/client/pages/(login)/reset-password.tsx index e3be97868..8739bcee8 100644 --- a/apps/ssr/client/pages/(login)/reset-password.tsx +++ b/apps/ssr/client/pages/(login)/reset-password.tsx @@ -1,5 +1,5 @@ import { resetPassword } from "@client/lib/auth" -import { Button, MotionButtonBase } from "@follow/components/ui/button/index.jsx" +import { Button } from "@follow/components/ui/button/index.jsx" import { Card, CardContent, @@ -77,17 +77,9 @@ export function Component() { return (
- + - { - history.length > 1 ? history.back() : navigate("/login") - }} - className="-ml-1 inline-flex cursor-pointer items-center" - > - - {t("login.forget_password.label")}