Signupsignup-02
A signup form with social providers
A signup flow that emphasizes third-party providers and email signup.
templcn add signup-02 templ Signup02Preview() {
@PreviewLayout("Signup 02 Preview") {
<div class="grid min-h-screen place-items-center bg-background p-6">
@ui.Card(ui.DOMProps{Class: "w-full max-w-lg"}) {
@ui.CardHeader(ui.DOMProps{Class: "space-y-2 text-center"}) {
@ui.CardTitle(ui.DOMProps{}) { <span>Join the workspace</span> }
@ui.CardDescription(ui.DOMProps{}) { <span>Use a provider or your email to register.</span> }
}
@ui.CardContent(ui.DOMProps{}) {
<div class="grid gap-4">
<div class="grid gap-3 sm:grid-cols-2">
@ui.Button(ui.ButtonProps{Label: "Continue with GitHub", Variant: ui.ButtonVariantOutline})
@ui.Button(ui.ButtonProps{Label: "Continue with Google", Variant: ui.ButtonVariantOutline})
</div>
<div class="flex items-center gap-3">
@ui.Separator(ui.SeparatorProps{Decorative: true})
<span class="text-xs uppercase tracking-[0.24em] text-muted-foreground">or</span>
@ui.Separator(ui.SeparatorProps{Decorative: true})
</div>
<div class="grid gap-2">
@ui.Label(ui.LabelProps{For: "signup2-email"}) { <span>Email</span> }
@ui.Input(ui.InputProps{Type: "email", Placeholder: "name@company.com", DOMProps: ui.DOMProps{Attrs: t.Attributes{"id": "signup2-email"}}})
</div>
<div class="grid gap-2">
@ui.Label(ui.LabelProps{For: "signup2-password"}) { <span>Password</span> }
@ui.Input(ui.InputProps{Type: "password", Placeholder: "Create a password", DOMProps: ui.DOMProps{Attrs: t.Attributes{"id": "signup2-password"}}})
</div>
@ui.Button(ui.ButtonProps{Label: "Create workspace"})
<p class="text-center text-xs text-muted-foreground">By continuing you accept the privacy policy and terms.</p>
</div>
}
}
</div>
}
}Components Used
Dependencies for this block.
signup-form
File Structure
Files that make up this layout.
app/signup/page.templ
components/signup-form.templ