Forms
FormFieldSet type="datepicker" -- single date or range, with time and presets.
| Prop | Type | Default | Description |
|---|---|---|---|
value / defaultValue | string | { start: string; end: string } | — | Controlled / uncontrolled value. YYYY-MM-DD, or YYYY-MM-DDTHH:mm when withTime. |
startIcon / endIcon / prefix / suffix | ReactNode | — | Adornments on the trigger. |
label | ReactNode | — | Field label. |
description | ReactNode | — | Helper text below the control. |
error | ReactNode | boolean | — | Error message, or true for an invalid state with no message. |
value / defaultValue
string | { start: string; end: string }
Default: —
Controlled / uncontrolled value. YYYY-MM-DD, or YYYY-MM-DDTHH:mm when withTime.
startIcon / endIcon / prefix / suffix
ReactNode
Default: —
Adornments on the trigger.
label
ReactNode
Default: —
Field label.
description
ReactNode
Default: —
Helper text below the control.
error
ReactNode | boolean
Default: —
Error message, or true for an invalid state with no message.
| Prop | Type | Default | Description |
|---|---|---|---|
onChange | (next) => void | — | Called when the selection changes. |
onClear | () => void | — | Called in addition to onChange when the clear action is used. |
onChange
(next) => void
Default: —
Called when the selection changes.
onClear
() => void
Default: —
Called in addition to onChange when the clear action is used.
| Prop | Type | Default | Description |
|---|---|---|---|
range | boolean | false | Enables range mode (value becomes { start, end }). |
withTime | boolean | false | Enables time selection alongside the date. |
showPresets / presets | boolean / Array<preset name> | false / built-in set | Preset shortcut buttons (Today, This week, …). |
clearable | boolean | true | Shows a clear action (hidden when required). |
minDate / maxDate | Date | string | — | Earliest/latest selectable date. |
blockedDates | Array<Date | string> | [] | Disabled dates list. |
disabled | boolean | false | Disables the control. |
required | boolean | false | Marks the field required. |
range
boolean
Default: false
Enables range mode (value becomes { start, end }).
withTime
boolean
Default: false
Enables time selection alongside the date.
showPresets / presets
boolean / Array<preset name>
Default: false / built-in set
Preset shortcut buttons (Today, This week, …).
clearable
boolean
Default: true
Shows a clear action (hidden when required).
minDate / maxDate
Date | string
Default: —
Earliest/latest selectable date.
blockedDates
Array<Date | string>
Default: []
Disabled dates list.
disabled
boolean
Default: false
Disables the control.
required
boolean
Default: false
Marks the field required.
| Prop | Type | Default | Description |
|---|---|---|---|
rangeTrigger | "single" | "dual" | "single" | Range only: one trigger vs. separate start/end inputs. |
monthsToShow | 1 | 2 | 1 (2 for range) | Calendar months visible at once. |
labelPlacement | "top" | "left" | "right" | "floating" | "top" | Label position relative to the control. |
colSpan | number | — | Sets `grid-column: span N` on the field wrapper — a real home for a layout hint in a spread config object (instead of leaking to the <input>). |
rangeTrigger
"single" | "dual"
Default: "single"
Range only: one trigger vs. separate start/end inputs.
monthsToShow
1 | 2
Default: 1 (2 for range)
Calendar months visible at once.
labelPlacement
"top" | "left" | "right" | "floating"
Default: "top"
Label position relative to the control.
colSpan
number
Default: —
Sets `grid-column: span N` on the field wrapper — a real home for a layout hint in a spread config object (instead of leaking to the <input>).
| Prop | Type | Default | Description |
|---|---|---|---|
displayFormat | "pretty" | "iso" | "pretty" | Trigger display format. |
size | "xs" | "xs-sm" | "sm" | "md" | "lg" | "xl" | "md" | Control size. |
variant | "bordered" | "soft" | "filled" | "underlined" | "bordered" | Visual variant. "filled" (text types) is borderless with a neutral fill at rest, border + ring on focus; other field types fall back to "bordered". "default"/"underline" are legacy aliases. |
color | "default" | "primary" | "secondary" | "info" | "success" | "warning" | "danger" | string | "default" | Semantic tone. |
colorDepth | number | 500 | Shade depth for color. |
radius | "none" | "xs" | "xs-sm" | "sm" | "md" | "lg" | "full" | "md" | Corner radius. `rounded` is a legacy alias. |
displayFormat
"pretty" | "iso"
Default: "pretty"
Trigger display format.
size
"xs" | "xs-sm" | "sm" | "md" | "lg" | "xl"
Default: "md"
Control size.
variant
"bordered" | "soft" | "filled" | "underlined"
Default: "bordered"
Visual variant. "filled" (text types) is borderless with a neutral fill at rest, border + ring on focus; other field types fall back to "bordered". "default"/"underline" are legacy aliases.
color
"default" | "primary" | "secondary" | "info" | "success" | "warning" | "danger" | string
Default: "default"
Semantic tone.
colorDepth
number
Default: 500
Shade depth for color.
radius
"none" | "xs" | "xs-sm" | "sm" | "md" | "lg" | "full"
Default: "md"
Corner radius. `rounded` is a legacy alias.
| Prop | Type | Default | Description |
|---|---|---|---|
wrapperClassName | string | — | Class on the field wrapper (the element that also carries colSpan), separate from `className` on the control. |
className | string | — | Class applied to the root element. |
style | CSSProperties | — | Inline styles for the root element. |
wrapperClassName
string
Default: —
Class on the field wrapper (the element that also carries colSpan), separate from `className` on the control.
className
string
Default: —
Class applied to the root element.
style
CSSProperties
Default: —
Inline styles for the root element.
| Prop | Type | Default | Description |
|---|---|---|---|
children | ReactNode | — | FormFieldSet fields and other form content. |
children
ReactNode
Default: —
FormFieldSet fields and other form content.
| Prop | Type | Default | Description |
|---|---|---|---|
validationMode | "blur" | "change" | "blur" | When fields are (re-)validated. |
showErrorsOn | "blur" | "change" | "blur" | When validation errors start showing. |
validateOnMount | boolean | false | Runs validation immediately on mount. |
initialValues | FormData | {} | Initial values for uncontrolled fields. |
disableAutofill | boolean | true | Adds autocomplete/autofill-defeating attributes to the form. |
validationMode
"blur" | "change"
Default: "blur"
When fields are (re-)validated.
showErrorsOn
"blur" | "change"
Default: "blur"
When validation errors start showing.
validateOnMount
boolean
Default: false
Runs validation immediately on mount.
initialValues
FormData
Default: {}
Initial values for uncontrolled fields.
disableAutofill
boolean
Default: true
Adds autocomplete/autofill-defeating attributes to the form.
| Prop | Type | Default | Description |
|---|---|---|---|
onSubmit | (formData: FormData) => void | Promise<void> | — | Called with collected field values on submit (required). |
onError | (errors: FormErrors) => void | — | Called when submit is blocked by validation errors. |
onSubmit
(formData: FormData) => void | Promise<void>
Default: —
Called with collected field values on submit (required).
onError
(errors: FormErrors) => void
Default: —
Called when submit is blocked by validation errors.
| Prop | Type | Default | Description |
|---|---|---|---|
className | string | "" | Class applied to the form element. |
className
string
Default: ""
Class applied to the form element.