moonstone/ Grid List Image Item
Exports the moonstone/GridListImageItem.GridListImageItem and moonstone/GridListImageItem.GridListImageItemBase components. The default export is moonstone/GridListImageItem.GridListImageItem.
import GridListImageItem from '@enact/moonstone/GridListImageItem';
Members
GridListImageItemComponent
moonstone/GridListImageItem.GridListImageItem is a GridListImageItem with Moonstone styling, Marquee and Spottable applied.
Usage:
<GridListImageItem source="http://placehold.it/300x300/9037ab/ffffff&text=Image0" caption="image0" subCaption="sub-image0" />
import GridListImageItem from '@enact/moonstone/GridListImageItem';
GridListImageItemBaseComponent
moonstone/GridListImageItem.GridListImageItemBase is a stateless GridListImageItem with Moonstone styling applied.
import {GridListImageItemBase} from '@enact/moonstone/GridListImageItem';
Properties
- source •
The absolute URL path to the image.
- caption
The primary caption to be displayed with the image.
- placeholder
Placeholder image used while source is loaded.
Default: An image- selected
When
true
, applies a selected visual effect to the image, but only ifselectionOverlayShowing
is alsotrue
.Default: false- selectionOverlay
The custom selection overlay component to render. A component can be a stateless functional component,
kind()
or React component. The following is an example with custom selection overlay kind.Example Usage:
const SelectionOverlay = kind({ render: () => <div>custom overlay</div> }); <GridListImageItemBase selectionOverlay={SelectionOverlay} />
- selectionOverlayShowing
When
true
, a selection overlay with a centered icon is shown. Whenselected
is true, a check mark is shown.Default: false- subCaption
The second caption line to be displayed with the image.