Time Picker
Formsatlas-time-pickerExamples
24-hour and 12-hour
The value is a TimeValue ( { hours, minutes } ); use12Hour adds an AM/PM toggle.
:
:
14:30
Minute step
minuteStep limits the minutes to a grid (here every 15 minutes), for meeting slots and bookings. The value stays { hours, minutes } in 24-hour time, also with use12Hour .
:
Value: 14:30
In a form field
Inside atlas-form-field the label names the time picker and the hint describes it; no ids to write.
:
Your local time.
API
Generated from the library source, so it always matches the code.
AtlasTimePickerComponent atlas-time-picker
| Input | Type | Default | Description |
|---|---|---|---|
| value two-way | TimeValue | — | |
| use12Hour | boolean | false | |
| minuteStep | number | 1 | |
| disabled | boolean | false | |
| errors | readonly ValidationError.WithOptionalFieldTree[] | [] | [field] . |
| required | boolean | false | [field] . |
| invalid | boolean | false | [field] . |
| touched | boolean | false | [field] . |
| readonly | boolean | false | [field] . |
| pending | boolean | false | [field] . |
| name | string | '' | [field] . |
| ariaLabel | string | null | null | |
| inputId | string | undefined | undefined | id of the focusable element, so a visible <label atlasLabel for="…"> names it. Inside atlas-form-field the field supplies one. |
| ariaDescribedBy | string | null | null | aria-describedby , merged with the surrounding form field's hint or error. |
| class | string | '' | cn() ; yours win on conflicts. |
| Output | Payload | Description |
|---|---|---|
| touch | void |
Types
TimeValue
| Property | Type | Description |
|---|---|---|
| hours | number | |
| minutes | number |