Login
BlockA sign-in form with validation, social providers and a busy state.
- Authentication
- 7 components
- 1 file
Loading the example…
pnpm dlx @dowel-ui/cli add loginimport { LoginBlock } from "@/components/blocks/login"; export default function Page() { return <LoginBlock />;}<LoginBlock>
| Prop | Type | Default |
|---|---|---|
errorA server-side error, shown above the fields. | string | — |
forgotHrefWhere "Forgot password?" goes. | string | "/forgot-password" |
onSubmitCalled with the submitted credentials. | (values: { email: string; password: string; remember: boolean }) => void | — |
pendingDisables the form and shows the submit button as busy. | boolean | false |
signupHrefWhere "Create an account" goes. | string | "/signup" |
className | string | — |
Email and password fields carry the right type and autocomplete, so password managers and mobile keyboards behave. Field errors are tied to their inputs through the Form wiring; a server error is an assertive alert, because it arrived after the user acted and explains why nothing happened. The submit button reports its own busy state rather than going quiet.