

Every state


default


focus


filled


invalid-date


future-year


too-young


disabled
Props
| Prop | Type | Default | What it does |
|---|---|---|---|
| id | string | "dob" | Id prefix; the fields are `${id}-day`, `${id}-month` and `${id}-year`. |
| name | string | "date-of-birth" | Form name of the hidden ISO date, set once the date is valid. |
| legend | string | "Date of birth" | The group's visible label. |
| description | string | – | Help line under the legend. |
| defaultValue | DatePickerBirthDateParts | – | The fields at the start: day, month (1 to 12) and year, as strings. |
| minAge | number | 18 | The youngest age allowed; 0 for no limit. |
| today | Date | – | Today's date; defaults to the real today. |
| locale | string | "en-GB" | Locale for month names and the date read back. |
| onValueChange | (iso: string) => void | – | Called with the ISO date when it is valid, or an empty string. |
| required | boolean | – | Requires all three fields. |
| disabled | boolean | – | Disables the group. |
| error | string | – | An outside error message; wins over the field's own checks. |
| className | string | – | Extra classes on the fieldset. |


