Waterfall 瀑布流布局
A layout that places elements in optimal positions based on available vertical space.
Basic Usage
loading
Five Columns
Use the cols prop to set the layout to five columns.
loading
Image Waterfall
Waterfall is perfect for displaying images with different heights.
loading
API
| Prop | Description | Type | Default |
|---|---|---|---|
| items | Array of items to display | any[] | [] |
| cols | Number of columns | number | 3 |
| gap | Gap between items in pixels | number | 16 |
Slots
| Name | Description |
|---|---|
| default | Custom content for each item, scoped with { item } |