TimePicker provides only the wheel-style time picker UI. Configure the trigger, bottom sheet, confirm and cancel buttons, and form serialization in the consuming screen.
You can control the selected time using value and onValueChange. onValueChange is called when scrolling settles on a selection item and the value is confirmed.
Currently, only 12-hour UI is supported. However, TimePickerValue used in value, defaultValue, and onValueChange is expressed in 24-hour format without separating AM/PM as a separate field.
Prop
Type
If no value is specified, it starts at 00:00. To start from the current time when no time is selected, pass the current time's hour and minute as defaultValue.
Provide valid values
hour and minute must each be integers within a valid range. Passing invalid value, defaultValue, or minuteStep will result in a RangeError.
Determine the layout based on the proportion of space Time Picker occupies on screen and the platform.
If time selection is the main task on the screen, use Inline.
For time input fields in mobile forms, consider Bottom Sheet first.
Bottom Sheet requires a trigger to open the surface. It can be composed with an input-style button like FieldButton that displays the current value. Inline confirmation is handled by the screen's action area, and Bottom Sheet confirmation is handled by the confirm button within the surface.
In mobile forms, configure Time Picker to appear at the bottom of the screen when the input field is tapped. Manage temporary values until the user completes, and reflect them as the input field's value when the confirm button is tapped.
TimePicker does not interpret dates or time zones. If your application manages Date as state, convert hour and minute to TimePickerValue, and reflect the changed time in the existing date.
minuteStep can be one of 1, 5, 10, 15, or 30, with a default value of 5.
If the selected minute doesn't match the interval, it rounds to the nearest value. For example, 9:13 displays as 9:15 with minuteStep={5}.
Rounding is calculated based on the entire time, so the hour can change together. For example, 23:59 becomes 0:00 with minuteStep={5}. When controlling value, normalization itself does not trigger onValueChange.
The minute column cycles, but the hour is maintained even when crossing boundaries. For example, selecting 00 (the next minute item) from 10:55 results in 10:00.
The AM/PM, number notation, and column order vary depending on locale.
The default accessibility names for the entire picker and each column are provided in Korean, English, or Japanese depending on locale. If a language other than the default is needed or to describe the context more specifically, directly specify aria-label, periodAriaLabel, hourAriaLabel, or minuteAriaLabel.
Time Picker as a whole is provided as group, and AM/PM, hour, and minute columns are each provided as spinbutton. On keyboard, use ArrowUp and ArrowDown to select previous/next items, and Home and End to select first/last items.
If there's an element on screen that indicates the Time Picker's name, you can connect it with aria-labelledby. If aria-labelledby is not provided, the default "Time Selection" is used for the entire component.