refactor: update hero section content and improve user button behavior
- Changed the hero section title and description to better reflect the MkSaaS offering. - Updated the user button to use `replace` instead of `push` for navigation after sign out, ensuring a smoother user experience. - Modified the delete account card to also use `replace` for navigation after account deletion, enhancing consistency in routing behavior.
This commit is contained in:
parent
bb7e36cc85
commit
a7f7556a6d
@ -24,19 +24,18 @@ export default function HeroSection4() {
|
||||
<span className="bg-muted rounded-[calc(var(--radius)-0.25rem)] px-2 py-1 text-xs">
|
||||
New
|
||||
</span>
|
||||
<span className="text-sm">Introduction Tailus UI Html</span>
|
||||
<span className="text-sm">Introduce MkSaaS</span>
|
||||
<span className="bg-(--color-border) block h-4 w-px"></span>
|
||||
|
||||
<ArrowRight className="size-4" />
|
||||
</Link>
|
||||
|
||||
<h1 className="mt-8 text-balance text-4xl font-semibold md:text-5xl xl:text-6xl xl:[line-height:1.125]">
|
||||
Modern Software testing reimagined
|
||||
Launch your AI SaaS the easiest way
|
||||
</h1>
|
||||
<p className="mx-auto mt-8 hidden max-w-2xl text-wrap text-lg sm:block">
|
||||
Tailwindcss highly customizable components for building modern
|
||||
websites and applications that look and feel the way you mean
|
||||
it.
|
||||
MkSaaS is a boilerplate for building modern AI SaaS applications
|
||||
with Next.js, Tailwind CSS, Shadcn UI, Better Auth, Resend, Stripe, and Vercel AI SDK.
|
||||
</p>
|
||||
<p className="mx-auto mt-6 max-w-2xl text-wrap sm:hidden">
|
||||
Highly customizable components for building modern websites
|
||||
|
@ -38,7 +38,7 @@ export function UserButton() {
|
||||
fetchOptions: {
|
||||
onSuccess: () => {
|
||||
console.log('sign out success');
|
||||
localeRouter.push('/');
|
||||
localeRouter.replace('/');
|
||||
},
|
||||
onError: (error) => {
|
||||
console.error('sign out error:', error);
|
||||
|
@ -60,11 +60,14 @@ export function DeleteAccountCard() {
|
||||
onSuccess: () => {
|
||||
toast.success(t('deleteAccount.success'));
|
||||
refetch();
|
||||
router.push('/');
|
||||
router.replace('/');
|
||||
},
|
||||
onError: (ctx) => {
|
||||
console.error('delete account error:', ctx.error);
|
||||
// { "message": "Session expired. Re-authenticate to perform this action.", "code": "SESSION_EXPIRED_REAUTHENTICATE_TO_PERFORM_THIS_ACTION", "status": 400, "statusText": "BAD_REQUEST" }
|
||||
// { "message": "Session expired. Re-authenticate to perform this action.",
|
||||
// "code": "SESSION_EXPIRED_REAUTHENTICATE_TO_PERFORM_THIS_ACTION",
|
||||
// "status": 400, "statusText": "BAD_REQUEST" }
|
||||
// set freshAge to 0 to disable session refreshness check for user deletion
|
||||
setError(`${ctx.error.status}: ${ctx.error.message}`);
|
||||
toast.error(t('deleteAccount.fail'));
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user