Supports any number of regions, two directions, and recursive nesting.
Regions and nesting
Nest more items inside the matching SplitterItem.
Supports any number of regions, two directions, and recursive nesting.
Nest more items inside the matching SplitterItem.
use-rest keeps the remaining space; precision snaps to 0.01 by default.
A single value controls both directions. Arrays use [rowGap, columnGap]; 0 consumes no space and remains draggable.
type SplitterSize = number | 'rest'
interface SplitterGroupValue {
type: 'horizontal' | 'vertical'
size: Array<SplitterSize | SplitterGroupValue>
value?: SplitterSize
}
Mismatched item counts are evenly recalculated. Object entries represent nested groups.
| Prop | Type | Default | Description |
|---|---|---|---|
min | number | inherited min-size | Minimum ratio for this region |
max | number | 1 | Maximum ratio for this region |
disabled | boolean | false | Disable the separator after this region |
use-rest | boolean | false | Permanently consume this level’s remainder; only one per level |
Supports pointer, touch, arrow, Home, and End keys.
Splitter does not clip item content. Add overflow: auto to an inner container when scrolling is needed.
Number | String | [, ]