Contact Form
Contact form with validation
Overview
Provides a self-contained contact form with loading, success, and error states. The "split" variant renders a two-column layout with a colored left panel for features/benefits and a right panel for custom form content via children.
Usage
import { ContactForm } from '@leanicon/web-builder-library'Default
Built-in form with name, email, subject, and message fields. Handles loading, success, and error states internally.
Split
Two-column layout with a primary-colored left panel showing heading, subtitle, and feature checklist. The right panel accepts custom form content via children.
Accelerate your AI roadmap
Connect with an expert to explore how our products can fit your stack, data, and goals.
- Align AI to your workflows and use cases
- Choose deployment options that fit your infrastructure
- Move from pilot to production — safely and securely
Split — without features
Heading and subtitle only, no feature checklist.
Accelerate your AI roadmap
Connect with an expert to explore how our products can fit your stack, data, and goals.
Split — without subtitle
Heading and feature checklist, no subtitle.
Accelerate your AI roadmap
- Align AI to your workflows and use cases
- Choose deployment options that fit your infrastructure
- Move from pilot to production — safely and securely
Split — heading only
Minimal left panel with just a heading.
Get in touch
Dark mode
Split — dark mode
Accelerate your AI roadmap
Connect with an expert to explore how our products can fit your stack, data, and goals.
- Align AI to your workflows and use cases
- Choose deployment options that fit your infrastructure
- Move from pilot to production — safely and securely
Split — without features — dark mode
Accelerate your AI roadmap
Connect with an expert to explore how our products can fit your stack, data, and goals.
Split — without subtitle — dark mode
Accelerate your AI roadmap
- Align AI to your workflows and use cases
- Choose deployment options that fit your infrastructure
- Move from pilot to production — safely and securely
Split — heading only — dark mode
Get in touch
Props
Prop | Type | Default | Description |
|---|---|---|---|
|
|
| Layout variant |
|
| — | Callback on form submission (default variant) |
|
| — | Left panel heading (split variant) |
|
| — | Left panel subtitle (split variant) |
|
| — | Feature checklist items (split variant) |
|
| — | Custom form content for right panel (split variant) |
|
| — | Force light or dark mode |
|
| — | Additional CSS classes on root |
ContactFormData
Field | Type | Description |
|---|---|---|
|
| Sender name |
|
| Sender email |
|
| Message subject |
|
| Message body |
Notes
- The default variant manages all four fields and form state (loading, success, error) internally.
- The split variant's left panel uses
bg-primarywithtext-primary-foreground— it adapts to your theme. - Feature items render with a
CircleCheckicon from Lucide. - Dark mode: pass
colorScheme="dark"or place inside a.darkancestor.
Props
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
onSubmit | ((data: ContactFormData) => Promise<void>) | — | No | |
colorScheme | enum | — | No | |
className | string | — | No | |
variant | enum | default | No | |
heading | string | — | No | |
subtitle | string | — | No | |
features | string[] | — | No |