An environment variable has been added to playwright config for running the server command. On billing error pages, an icon was added to the error message, and the duplicate billing error page was refactored to import from the existing page instead of maintaining separate code. Also, changes were made to the workflow to reflect new Playwright server command.
46 lines
1.2 KiB
TypeScript
46 lines
1.2 KiB
TypeScript
'use client';
|
|
|
|
import { useRouter } from 'next/navigation';
|
|
|
|
import { ExclamationTriangleIcon } from '@radix-ui/react-icons';
|
|
|
|
import { Alert, AlertDescription, AlertTitle } from '@kit/ui/alert';
|
|
import { Button } from '@kit/ui/button';
|
|
import { PageBody, PageHeader } from '@kit/ui/page';
|
|
import { Trans } from '@kit/ui/trans';
|
|
|
|
export default function BillingErrorPage() {
|
|
const router = useRouter();
|
|
|
|
return (
|
|
<>
|
|
<PageHeader
|
|
title={<Trans i18nKey={'common:billingTabLabel'} />}
|
|
description={<Trans i18nKey={'common:billingTabDescription'} />}
|
|
/>
|
|
|
|
<PageBody>
|
|
<div className={'flex flex-col space-y-4'}>
|
|
<Alert variant={'destructive'}>
|
|
<ExclamationTriangleIcon className={'h-4'} />
|
|
|
|
<AlertTitle>
|
|
<Trans i18nKey={'billing:planPickerAlertErrorTitle'} />
|
|
</AlertTitle>
|
|
|
|
<AlertDescription>
|
|
<Trans i18nKey={'billing:planPickerAlertErrorDescription'} />
|
|
</AlertDescription>
|
|
</Alert>
|
|
|
|
<div>
|
|
<Button variant={'outline'} onClick={() => router.refresh()}>
|
|
<Trans i18nKey={'common:retry'} />
|
|
</Button>
|
|
</div>
|
|
</div>
|
|
</PageBody>
|
|
</>
|
|
);
|
|
}
|