A short quote form on the left, a booking calendar on the right; the calendar column drops away when no booking link is set.
lead, quote, booking, form
npx shadcn@latest add https://ner.sh/r/lead-form-split.json{
"registries": {
"@nertia": "https://ner.sh/r/{name}.json"
}
}npx shadcn@latest add @nertia/lead-form-splitnpm create nersh@latest my-site -- --site https://nertia.ai/components/contact/lead-form-split/site.json scaffolds a project from it.{
"slug": "lead-form-split",
"mode": "builder",
"status": "draft",
"skinId": "zinc",
"composition": {
"id": "lead-form-split",
"sections": [
{
"id": "layout-section",
"instanceId": "lead-band-r1",
"layout": "stack",
"children": [
{
"id": "layout-container",
"instanceId": "lead-intro-r1",
"layout": "stack",
"children": [
{
"id": "layout-column",
"instanceId": "lead-intro-col-r1",
"children": [
{
"id": "block-heading",
"instanceId": "lead-heading-r1"
},
{
"id": "block-text",
"instanceId": "lead-sub-r1"
}
]
}
]
},
{
"id": "layout-container",
"instanceId": "lead-row-r1",
"layout": "split-60-40",
"children": [
{
"id": "layout-column",
"instanceId": "lead-form-col-r1",
"span": 7,
"children": [
{
"id": "block-form",
"instanceId": "lead-form-r1",
"children": [
{
"id": "block-input",
"instanceId": "lead-name-r1"
},
{
"id": "block-input",
"instanceId": "lead-phone-r1"
},
{
"id": "block-input",
"instanceId": "lead-email-r1"
},
{
"id": "block-textarea",
"instanceId": "lead-notes-r1"
}
]
}
]
},
{
"id": "layout-column",
"instanceId": "lead-book-col-r1",
"span": 5,
"children": [
{
"id": "block-embed",
"instanceId": "lead-booking-r1"
}
]
}
]
}
],
"component": "lead-form-split@1"
}
]
},
"copy": {
"lead-band-r1.coverImage": "",
"lead-band-r1.coverStyle": "",
"lead-band-r1.coverScrim": "",
"lead-band-r1.anchor": "contact",
"lead-band-r1.navLabel": "",
"lead-band-r1.navHref": "",
"lead-band-r1.navSkip": "",
"lead-band-r1.landmark": "",
"lead-band-r1.tone": "",
"lead-band-r1.gutter": "",
"lead-band-r1.shape": "",
"lead-band-r1.padding": "",
"lead-band-r1.sticky": "",
"lead-band-r1.reveal": "",
"lead-band-r1.dismissible": "",
"lead-band-r1.width": "",
"lead-band-r1.gradient": "",
"lead-intro-r1.align": "center",
"lead-intro-r1.phone": "",
"lead-intro-col-r1.pad": "",
"lead-intro-col-r1.sticky": "",
"lead-heading-r1.text": "Get in touch",
"lead-heading-r1.level": "h2",
"lead-sub-r1.text": "One sentence on what happens after someone writes in.",
"lead-sub-r1.textStyle": "",
"lead-row-r1.align": "",
"lead-row-r1.phone": "",
"lead-form-col-r1.pad": "",
"lead-form-col-r1.sticky": "",
"lead-form-r1.submitLabel": "Send",
"lead-form-r1.email": "",
"lead-form-r1.successMessage": "Thanks. We will be in touch soon.",
"lead-name-r1.label": "Name",
"lead-name-r1.name": "name",
"lead-name-r1.inputType": "text",
"lead-name-r1.placeholder": "",
"lead-name-r1.required": "true",
"lead-phone-r1.label": "Phone",
"lead-phone-r1.name": "phone",
"lead-phone-r1.inputType": "tel",
"lead-phone-r1.placeholder": "(555) 555-5555",
"lead-phone-r1.required": "",
"lead-email-r1.label": "Email",
"lead-email-r1.name": "email",
"lead-email-r1.inputType": "email",
"lead-email-r1.placeholder": "",
"lead-email-r1.required": "true",
"lead-notes-r1.label": "What do you need?",
"lead-notes-r1.name": "notes",
"lead-notes-r1.placeholder": "",
"lead-notes-r1.required": "false",
"lead-book-col-r1.pad": "",
"lead-book-col-r1.sticky": "",
"lead-booking-r1.url": "",
"lead-booking-r1.title": "Book a time",
"lead-booking-r1.kind": ""
}
}
{
"slug": "lead-form-split",
"mode": "builder",
"status": "draft",
"skinId": "zinc",
"composition": {
"id": "lead-form-split",
"sections": [
{
"id": "layout-section",
"instanceId": "lead-band-r1",
"layout": "stack",
"children": [
{
"id": "layout-container",
"instanceId": "lead-intro-r1",
"layout": "stack",
"children": [
{
"id": "layout-column",
"instanceId": "lead-intro-col-r1",
"children": [
{
"id": "block-heading",
"instanceId": "lead-heading-r1"
},
{
"id": "block-text",
"instanceId": "lead-sub-r1"
}
]
}
]
},
{
"id": "layout-container",
"instanceId": "lead-row-r1",
"layout": "split-60-40",
"children": [
{
"id": "layout-column",
"instanceId": "lead-form-col-r1",
"span": 7,
"children": [
{
"id": "block-form",
"instanceId": "lead-form-r1",
"children": [
{
"id": "block-input",
"instanceId": "lead-name-r1"
},
{
"id": "block-input",
"instanceId": "lead-phone-r1"
},
{
"id": "block-input",
"instanceId": "lead-email-r1"
},
{
"id": "block-textarea",
"instanceId": "lead-notes-r1"
}
]
}
]
},
{
"id": "layout-column",
"instanceId": "lead-book-col-r1",
"span": 5,
"children": [
{
"id": "block-embed",
"instanceId": "lead-booking-r1"
}
]
}
]
}
],
"component": "lead-form-split@1"
}
]
},
"copy": {
"lead-band-r1.coverImage": "",
"lead-band-r1.coverStyle": "",
"lead-band-r1.coverScrim": "",
"lead-band-r1.anchor": "contact",
"lead-band-r1.navLabel": "",
"lead-band-r1.navHref": "",
"lead-band-r1.navSkip": "",
"lead-band-r1.landmark": "",
"lead-band-r1.tone": "",
"lead-band-r1.gutter": "",
"lead-band-r1.shape": "",
"lead-band-r1.padding": "",
"lead-band-r1.sticky": "",
"lead-band-r1.reveal": "",
"lead-band-r1.dismissible": "",
"lead-band-r1.width": "",
"lead-band-r1.gradient": "",
"lead-intro-r1.align": "center",
"lead-intro-r1.phone": "",
"lead-intro-col-r1.pad": "",
"lead-intro-col-r1.sticky": "",
"lead-heading-r1.text": "Get in touch",
"lead-heading-r1.level": "h2",
"lead-sub-r1.text": "One sentence on what happens after someone writes in.",
"lead-sub-r1.textStyle": "",
"lead-row-r1.align": "",
"lead-row-r1.phone": "",
"lead-form-col-r1.pad": "",
"lead-form-col-r1.sticky": "",
"lead-form-r1.submitLabel": "Send",
"lead-form-r1.email": "",
"lead-form-r1.successMessage": "Thanks. We will be in touch soon.",
"lead-name-r1.label": "Name",
"lead-name-r1.name": "name",
"lead-name-r1.inputType": "text",
"lead-name-r1.placeholder": "",
"lead-name-r1.required": "true",
"lead-phone-r1.label": "Phone",
"lead-phone-r1.name": "phone",
"lead-phone-r1.inputType": "tel",
"lead-phone-r1.placeholder": "(555) 555-5555",
"lead-phone-r1.required": "",
"lead-email-r1.label": "Email",
"lead-email-r1.name": "email",
"lead-email-r1.inputType": "email",
"lead-email-r1.placeholder": "",
"lead-email-r1.required": "true",
"lead-notes-r1.label": "What do you need?",
"lead-notes-r1.name": "notes",
"lead-notes-r1.placeholder": "",
"lead-notes-r1.required": "false",
"lead-book-col-r1.pad": "",
"lead-book-col-r1.sticky": "",
"lead-booking-r1.url": "",
"lead-booking-r1.title": "Book a time",
"lead-booking-r1.kind": ""
},
"ds": {}
}
import type { SectionRegistry } from '@nersh/render';
import { Component as BlockEmbed } from '@/sections/block-embed/Component';
import { Component as BlockForm } from '@/sections/block-form/Component';
import { Component as BlockHeading } from '@/sections/block-heading/Component';
import { Component as BlockInput } from '@/sections/block-input/Component';
import { Component as BlockText } from '@/sections/block-text/Component';
import { Component as BlockTextarea } from '@/sections/block-textarea/Component';
import { Component as LayoutColumn } from '@/sections/layout-column/Component';
import { Component as LayoutContainer } from '@/sections/layout-container/Component';
import { Component as LayoutSection } from '@/sections/layout-section/Component';
export const registry: SectionRegistry = {
'block-embed': BlockEmbed,
'block-form': BlockForm,
'block-heading': BlockHeading,
'block-input': BlockInput,
'block-text': BlockText,
'block-textarea': BlockTextarea,
'layout-column': LayoutColumn,
'layout-container': LayoutContainer,
'layout-section': LayoutSection,
};
"use client";
import { SiteRenderer } from "@nersh/render";
import { registry } from "./lead-form-split.registry";
import siteJson from "./lead-form-split.site.json";
// eslint-disable-next-line @typescript-eslint/no-explicit-any
const site = siteJson as any;
export default function LeadFormSplit() {
return <SiteRenderer site={site} registry={registry} />;
}