moonstone/ Time Picker
Exports the moonstone/TimePicker.TimePicker component
import TimePicker from '@enact/moonstone/TimePicker';
Members
TimePickerComponent
moonstone/TimePicker.TimePicker allows the selection (or simply display) of a hour, month, and meridiem.
Set the value property to a standard JavaScript {@glossary Date} object to initialize the picker.
By default, TimePicker
maintains the state of its value
property. Supply the
defaultValue
property to control its initial value. If you wish to directly control updates
to the component, supply a value to value
at creation time and update it in response to
onChange
events.
TimePicker
is an expandable component and it maintains its open/closed state by default. The
initial state can be supplied using defaultOpen
. In order to directly control the open/closed
state, supply a value for open
at creation time and update its value in response to
onClose
/onOpen
events.
import TimePicker from '@enact/moonstone/TimePicker';
Properties
- title •
The primary text of the item.
- noLabels
When
true
, omits the labels below the pickers- onClose
Callback to be called when a condition occurs which should cause the expandable to close
- value
The selected date