moonstone/ Expandable Item
Moonstone styled expandable item.
import ExpandableItem from '@enact/moonstone/ExpandableItem';Members
ExpandableItemComponent
A component that renders a LabeledItem that can be expanded to show additional contents.
ExpandableItem 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 ExpandableItem from '@enact/moonstone/ExpandableItem';ExpandableHigher-Order Component
A higher-order component that manages the open state of a component and adds ui/Cancelable.Cancelable
support to call the onClose handler on
cancel.
import {Expandable} from '@enact/moonstone/ExpandableItem';Configuration
When
trueand used in conjunction withnoAutoFocuswhenfalse, the contents of the container will receive spotlight focus expanded, even in pointer mode.Default: false
ExpandableItemBaseComponent
A stateless component that renders a LabeledItem that can be expanded to show additional contents.
import {ExpandableItemBase} from '@enact/moonstone/ExpandableItem';Properties
The primary text of the item.
Closes the expandable automatically when the user navigates to the
titleof the component using 5-way controls; iffalse, the user must select/tap the title to close the expandable.Default: falseThe contents of the expandable item displayed when
openistrue.Disables voice control.
The voice control group.
The voice control intent.
The voice control label.
Disables ExpandableItem and the control becomes non-interactive.
Default: falseThe secondary, or supportive text. Typically under the
title, a subtitle.Prevents the user from moving Spotlight past the bottom of the expandable (when open) using 5-way controls.
Default: falseText to display when no
labelorvalueis set.Called when a condition occurs which should cause the expandable to close.
Called when a condition occurs which should cause the expandable to open.
Called when the component is removed while retaining focus.
Called prior to focus leaving the expandable when the 5-way down key is pressed.
Called prior to focus leaving the expandable when the 5-way left key is pressed.
Called prior to focus leaving the expandable when the 5-way right key is pressed.
Called prior to focus leaving the expandable when the 5-way up key is pressed.
Opens ExpandableItem with the contents visible.
Default: falseControls when
labelis shown.'always'- The label is always visible'never'- The label is never visible'auto'- The label is visible when the expandable is closed
Default: 'auto'Disables spotlight navigation into the component.
Default: false