On this page
@addTagHelper *, Webority.Ui.RazorDemo request
Use a demo request form to collect a name, email and a few details, with name and email required.
Four fields, two required
Talk to us
Book a payroll demo
A specialist calls you back within one working day.
Left-aligned
Left-align the copy and form when the panel's text should share the page's left edge.
Checklist offer, muted band
Get the checklist
Field labels
Set your own field labels when the form's wording should match the page, not the built-in English.
Custom labels, message required
Book a payroll demo
Every option
Every value of every prop, one cell each.
title
title="Get the checklist"Get the checklist
description
description="A short paragraph above the form."Book a payroll demo
A short paragraph above the form.
fields
nameBook a payroll demo
emailBook a payroll demo
phoneBook a payroll demo
companyBook a payroll demo
messageBook a payroll demo
required
required="name"Book a payroll demo
required="name,email,message"Book a payroll demo
onSubmit
onSubmit (React only): a callback; this form posts to action insteadBook a payroll demo
action
action: the URL the form posts to, not visible on the pageBook a payroll demo
submitLabel
submit-label="Send" (default)Book a payroll demo
submit-label="Send me the checklist"Book a payroll demo
nameLabel
name-label="Name" (default)Book a payroll demo
name-label="Full name"Book a payroll demo
emailLabel
email-label="Email" (default)Book a payroll demo
email-label="Work email"Book a payroll demo
phoneLabel
phone-label="Phone number" (default)Book a payroll demo
phone-label="Mobile number"Book a payroll demo
companyLabel
company-label="Company" (default)Book a payroll demo
company-label="Organisation"Book a payroll demo
messageLabel
message-label="Message" (default)Book a payroll demo
message-label="How can we help?"Book a payroll demo
requiredText
requiredText (React only): the message for an empty required fieldBook a payroll demo
invalidEmailText
invalidEmailText (React only): the message for a malformed emailBook a payroll demo
submitErrorText
submitErrorText (React only): the message when a send failsBook a payroll demo
successTitle
success-title="Check your inbox" (shown after a send)Book a payroll demo
successText
success-text="A specialist will be in touch." (shown after a send)Book a payroll demo
sent
sent="false" (default)Book a payroll demo
sent="true"Book a payroll demo
consent
(content)Book a payroll demo
as
as="h1"
Book a payroll demo
as="h2" (default)
Book a payroll demo
as="h3"
Book a payroll demo
as="h4"
Book a payroll demo
as="h5"
Book a payroll demo
as="h6"
Book a payroll demo
eyebrow
eyebrow="Talk to us"Talk to us
Book a payroll demo
subtitle
subtitle="A specialist calls you back within one working day."Book a payroll demo
A specialist calls you back within one working day.
align
align="start"
Book a payroll demo
align="center" (default)
Book a payroll demo
variant
variant="default" (default)
Book a payroll demo
variant="muted"
Book a payroll demo
className
className (React only): extra class names on the root elementBook a payroll demo
Guidance
What to do, and what to avoid.
Use it when
- A marketing page that asks for a lead: a demo, a quote or a callback.
- Up to five short fields, sent by a server action that rejects with a curated message, never a raw exception, because the visitor sees it.
Reach for something else when
- A form with more than five fields, or with several steps. → AppFormSection
- A sign-in or account form. → AppFormSection
Reference
Try every prop, read the full list, and check keyboard and screen reader behaviour.
Talk to us
Book a payroll demo
A specialist calls you back within one working day.
<AppSectionLeadCapture eyebrow="Talk to us" title="Book a payroll demo" subtitle="A specialist calls you back within one working day." submitLabel="Send" fields={[{"name":"name","required":true},{"name":"email","required":true},{"name":"phone"},{"name":"company"},{"name":"message"}]} successTitle="Thanks, we have your enquiry" successText="A specialist will be in touch." consent="We use your details only to reply to this enquiry." onSubmit={saveLead} />
<app-section-lead-capture title="Book a payroll demo" eyebrow="Talk to us" subtitle="A specialist calls you back within one working day." fields="@(new[] { LeadCaptureField.Name, LeadCaptureField.Email, LeadCaptureField.Phone, LeadCaptureField.Company, LeadCaptureField.Message })" required="@(new[] { LeadCaptureField.Name, LeadCaptureField.Email })" action="/Components/AppSectionLeadCapture" success-title="Thanks, we have your enquiry" success-text="A specialist will be in touch.">We use your details only to reply to this enquiry.</app-section-lead-capture>
20 props. The 5 most used come first.
Used on most screens 5 props
| Prop | Type | Default | Description |
|---|---|---|---|
| titledefault - | string | - | The section's heading. Required. |
| fieldsdefault - | name, email, phone, company, message | - | The fields in order, as a comma list. Required. |
| name-labeldefault Name | string | Name | Replaces the built-in English text, for other languages. |
| email-labeldefault Email | string | Replaces the built-in English text, for other languages. | |
| phone-labeldefault Phone number | string | Phone number | Replaces the built-in English text, for other languages. |
Less common 15 props
| Prop | Type | Default | Description |
|---|---|---|---|
| descriptiondefault - | string | - | A paragraph above the form. Use subtitle for the sentence under the heading. |
| requireddefault - | string | - | The fields that must have a value, as a comma list of the names in fields. |
| actiondefault - | string | - | The URL the form posts to. Required. |
| submit-labeldefault Send | string | Send | The button's label. |
| company-labeldefault Company | string | Company | Replaces the built-in English text, for other languages. |
| message-labeldefault Message | string | Message | Replaces the built-in English text, for other languages. |
| success-titledefault - | string | - | The heading of the block shown after a send. Required. |
| success-textdefault - | string | - | The sentence under the success heading. |
| sentdefault false | bool | false | Draws the success block in place of the form. |
| eyebrowdefault - | string | - | A short label above the heading. |
| subtitledefault - | string | - | A sentence under the heading. |
| asdefault h2 | h1 | h2 | h3 | h4 | h5 | h6 | h2 | The heading element. |
| aligndefault center | start | center | center | Where the copy and form sit in the panel. |
| variantdefault default | default | muted | default | The section's background around the panel. |
| (content)default - | markup | - | A line under the button, such as a privacy notice. |
Screen reader
3 notes- Each field has a visible label, and a required field is marked as required to the browser.
- The form is not validated by the browser, so the messages shown are the section's own, next to each field.
- A failed send is announced in an alert above the button, and a sent form is replaced by a success alert.