moonstone/ Day Picker
Exports the moonstone/DayPicker.DayPicker component.
import DayPicker from '@enact/moonstone/DayPicker';
Members
DayPickerComponent
moonstone/DayPicker.DayPicker is a component that allows the user to choose day(s) of the week.
By default, DayPicker
maintains the state of its selected
property. Supply the
defaultSelected
property to control its initial value. If you wish to directly control updates
to the component, supply a value to selected
at creation time and update it in response to
onChange
events.
DayPicker
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 DayPicker from '@enact/moonstone/DayPicker';
DayPickerBaseComponent
moonstone/DayPicker.DayPicker is a component that allows the user to choose day(s) of the week.
import {DayPickerBase} from '@enact/moonstone/DayPicker';
Properties
- title •
The primary text of the Picker.
- disabled
When
true
, applies a disabled style and the control becomes non-interactive.Default: false- onClose
Callback to be called when a condition occurs which should cause the expandable to close
Default: null- onOpen
Callback to be called when a condition occurs which should cause the expandable to open
Default: null- onSelect
Called when an item is selected. The first parameter will be an object containing a
selected
member, containing the array of numbers representing the selected days, 0 indexed- open
When
true
, the control in rendered in the expanded state, with the contents visible?Default: false- selected
An array of numbers (0-indexed) representing the selected days of the week.