DocumentCarousel
A horizontal carousel composable that displays a collection of documents.
DocumentCarousel provides a highly interactive way to browse, select, and reorder documents. It features a "cover flow" style layout where the center item is elevated, and side items are scaled down.
Features
Snap Scrolling: Automatically snaps to the nearest card after dragging.
Reordering: Long-press and drag to reorder items (optional).
Focus Reporting: Reports which document is currently centered.
Custom Overlays: Supports custom views for selected item information and empty states.
Parameters
a Modifier.
a DocumentModel with the documents to show a carousel for.
the document to initially select.
if true allow the user to reorder documents by long pressing.
action to perform when a document is tapped.
called when a new document is focused.
called when the user has reordered a document, to update the underlying DocumentStore.
a composable to draw text underneath the focused document.
a composable to draw text when there are no documents. This will be rendered in the center of a dashed outline of a grey card .