DatePicker
Lets the user pick a date.
Use it for: A date field, inside a Form.
- CategoryInput
- ChildrenNone
- DataOne field (bindings.value)
- ActionNone
| Prop | Required | Accepts | What it does |
|---|---|---|---|
label |
Yes | text, up to 200 characters | The visible label, also read by VoiceOver. |
required |
No | true or false |
The form cannot be saved while this is empty. |
disabled |
No | true or false |
Show it greyed out and ignore taps. |
Every component also accepts id (required, unique on its screen), and the optional preset and style described in Style options.
Example
Section titled “Example”From the fitness example project:
{ "id": "date", "type": "DatePicker", "props": { "label": "Workout date", "required": true }, "bindings": { "value": { "model": "workout", "field": "date" } }}