Skip to content

Splitter

A split component that resizes the left/right panel widths, adjustable via mouse drag or arrow keys.

Basic usage

Default 50/50

Left panel

Custom initial ratio

30% / 70%

Left panel 30%

Range limits

min / max limits

Left panel 20% ~ 80%

Resize event

oas-resize event

Left ratio: 50%
Left panel
Drag the divider, or focus it and use the ← / → arrow keys to adjust

API

Attributes

AttributeDescriptionTypeDefault
maxLeft panel maximum ratio (%)string90
minLeft panel minimum ratio (%)string10
percentLeft panel ratio (%)string50

Events

EventDescription
oas-resizeFired after resizing, detail: { percent }

Slots

NameDescription
left
right

The divider is role="separator" + tabindex="0"; once focused, / adjust by 1% each time.