23 lines
461 B
TypeScript
23 lines
461 B
TypeScript
'use client';
|
|
|
|
import { Stack } from '@/ui/primitives/Stack';
|
|
import React from 'react';
|
|
|
|
interface AuthFormProps {
|
|
children: React.ReactNode;
|
|
onSubmit: (e: React.FormEvent<HTMLFormElement>) => void;
|
|
}
|
|
|
|
/**
|
|
* AuthForm
|
|
*
|
|
* Semantic form wrapper for auth flows.
|
|
*/
|
|
export function AuthForm({ children, onSubmit }: AuthFormProps) {
|
|
return (
|
|
<Stack as="form" {...({ onSubmit, noValidate: true } as any)} gap={6}>
|
|
{children}
|
|
</Stack>
|
|
);
|
|
}
|