First test
This commit is contained in:
@ -1,36 +1,32 @@
|
||||
import { resetPassword } from "@/actions/auth";
|
||||
import { resetPassword } from '@/actions/auth';
|
||||
import { FormMessage, type Message, SubmitButton } from '@/components/default';
|
||||
import { Input, Label } from "@/components/ui";
|
||||
import { Input, Label } from '@/components/ui';
|
||||
|
||||
const ResetPassword = async (props: {
|
||||
searchParams: Promise<Message>;
|
||||
}) => {
|
||||
const ResetPassword = async (props: { searchParams: Promise<Message> }) => {
|
||||
const searchParams = await props.searchParams;
|
||||
return (
|
||||
<form className="flex flex-col w-full max-w-md p-4 gap-2 [&>input]:mb-4">
|
||||
<h1 className="text-2xl font-medium">Reset password</h1>
|
||||
<p className="text-sm text-foreground/60">
|
||||
<form className='flex flex-col w-full max-w-md p-4 gap-2 [&>input]:mb-4'>
|
||||
<h1 className='text-2xl font-medium'>Reset password</h1>
|
||||
<p className='text-sm text-foreground/60'>
|
||||
Please enter your new password below.
|
||||
</p>
|
||||
<Label htmlFor="password">New password</Label>
|
||||
<Label htmlFor='password'>New password</Label>
|
||||
<Input
|
||||
type="password"
|
||||
name="password"
|
||||
placeholder="New password"
|
||||
type='password'
|
||||
name='password'
|
||||
placeholder='New password'
|
||||
required
|
||||
/>
|
||||
<Label htmlFor="confirmPassword">Confirm password</Label>
|
||||
<Label htmlFor='confirmPassword'>Confirm password</Label>
|
||||
<Input
|
||||
type="password"
|
||||
name="confirmPassword"
|
||||
placeholder="Confirm password"
|
||||
type='password'
|
||||
name='confirmPassword'
|
||||
placeholder='Confirm password'
|
||||
required
|
||||
/>
|
||||
<SubmitButton formAction={resetPassword}>
|
||||
Reset password
|
||||
</SubmitButton>
|
||||
<SubmitButton formAction={resetPassword}>Reset password</SubmitButton>
|
||||
<FormMessage message={searchParams} />
|
||||
</form>
|
||||
);
|
||||
}
|
||||
};
|
||||
export default ResetPassword;
|
||||
|
Reference in New Issue
Block a user