Split API

This page provides an overview of the Split component API, detailing its props, emits, slots, and exposed methods/states.

Props

The Split component accepts the following props:

PropDefaultTypeDescription
autoSaveNameundefinedstring or undefinedAutomatically saves the panel configuration under this name.
separatorType"strip""strip" or "hexagon" or IconsProps["type"]The type of separator used between panels.
separatorNotHoverOpacityundefinedboolean or undefinedControls opacity of the separator when not hovered.
class""StyleClass or undefinedCustom CSS class for the Split component container.
stylesundefinedISplitStyles or undefinedCustom styles for the panels in the Split component.
units"percentages""percentages" or "pixels" or undefinedThe units for panel sizes (percentages or pixels).
panels[]Array<Panel>The list of panels in the Split component.
direction"horizontal""vertical" or "horizontal" or undefinedThe direction of panel resizing (vertical or horizontal).

Slots

The Split component provides dynamic slots for each panel:

SlotPayloadDescription
default{ size: number, panel: Panel }Default slot for rendering content inside the panels. Each panel slot is dynamically named based on the panel's name property.

Emits

The Split component emits the following events:

EventPayloadDescription
updated-panels{ panels: Record<Panel["name"], number> }Emitted when the panel sizes are updated.
updated-size-panel{ panel: Size, namePanel: Panel["name"] }Emitted when a single panel's size is updated.
start-resize-panel{ $event?: MouseEvent, namePanel?: Panel["name"] }Emitted when resizing starts for a panel.
stop-resize-panel{ $event?: MouseEvent, namePanel?: Panel["name"] }Emitted when resizing stops for a panel.
move-resize-panel{ $event: MouseEvent, namePanel: Panel["name"] }Emitted when a panel is actively being resized.
out-resize-panel{ $event: MouseEvent, namePanel: Panel["name"] }Emitted when the resize action exits a panel boundary.

Expose

The Split component exposes the following methods and states via ref:

ExposeValueDescription
resizableGroupHTMLElement or undefinedReference to the resizable group container element.
resizablePanelsRecord<string, HTMLElement>References to the individual resizable panel elements.
sizePanelsRecord<Panel["name"], number>The current sizes of the panels.
cursorPanelsRecord<Panel["name"], CursorType>The current cursor type for resizing panels.
activeCursorPanelCursorTypeThe cursor type currently active during resizing.
unitsSplitProps["units"]The units used for panel sizes (percentages or pixels).
panelsSplitProps["panels"]The configuration for all panels in the Split component.
directionSplitProps["direction"]The direction of panel resizing (vertical or horizontal).
separatorTypeSplitProps["separatorType"]The type of separator used between panels.
separatorNotHoverOpacitySplitProps["separatorNotHoverOpacity"]Indicates whether the separator has reduced opacity when not hovered.
stylesSplitProps["styles"]The styles applied to the Split component.
classBaseStyleClassThe base CSS class for the Split component.

Types

Panel

Defines the configuration for a single panel within the Split component.

PropertyTypeDescription
namestringThe name of the panel.
sizeSize or undefinedThe initial size of the panel.
maxSizeSize or undefinedThe maximum size of the panel.
minSizeSize or undefinedThe minimum size of the panel.
disabledboolean or undefinedDisables resizing for the panel.
classStyleClass or undefinedCustom CSS class for the panel container.
[key: string]anyAny additional properties for the separator item.

ISplitStyles

Defines custom styles for the Split component.

PropertyTypeDescription
panelStyleClassCustom CSS class for the panel elements.

Size

The Size type represents the size value for panels in the Split component. It is defined as a number and can represent sizes in percentages or pixels, depending on the units prop of the Split component.

TypeDescription
numberNumeric value representing the size of a panel. The interpretation (percentage or pixels) depends on the units prop.
© 2025 FishtVue by Egoka