- Accordion new
- ActionSheet new
- Alert new
- Alert Dialog new
- Angle Slider new
- Autocomplete new
- Avatar new
- Badge new
- Breadcrumb new
- Button new
- Button Group new
- Card new
- Carousel new
- Checkbox new
- Clipboard new
- Collapsible new
- Color Picker new
- Date Input new
- Date Picker new
- Dialog new
- DialogCaller new
- Drawer beta
- Editable new
- Empty new
- Field new
- Fieldset new
- File Upload new
- Filters new
- Floating Panel new
- Hover Card new
- Image new
- Image Cropper new
- Input new
- Input Group new
- Json Tree View new
- Kbd new
- Listbox new
- Marquee new
- Menu new
- Number Input new
- Pagination new
- Password Input new
- PhoneField new
- Pin Input new
- Popover new
- Progress Circular new
- Progress Linear new
- Qr Code new
- Radio Group new
- Rating Group new
- Scroll Area new
- ScrollSpy new
- Segment Group new
- Select new
- Separator new
- Sidebar new
- Signature Pad new
- Skeleton new
- Slider new
- Splitter new
- Steps new
- Switch new
- Table new
- Tabs new
- Tags Input new
- Textarea new
- Timeline new
- Timer new
- Toast new
- Toc new
- Toggle new
- Toggle Group new
- Tooltip new
- Tour new
- Tree View new
- Typography new
Splitter
Vue splitter for resizable panes that let users adjust layout width or height interactively.
Installation
Install from the Vuzeno registry:
bunx --bun shadcn-vue@latest add https://vuzeno.com/r/splitter.json
npx shadcn-vue@latest add https://vuzeno.com/r/splitter.json
yarn dlx shadcn-vue@latest add https://vuzeno.com/r/splitter.json
pnpm dlx shadcn-vue@latest add https://vuzeno.com/r/splitter.json
Usage
<script setup lang="ts">
import { Splitter } from "@/components/ui/splitter";
</script>
<template>
<Splitter.Root>
<!-- … -->
</Splitter.Root>
</template>
Composition
Splitter.Root
├── Splitter.Context
├── Splitter.Panel
├── Splitter.ResizeTrigger
├── Splitter.ResizeTriggerIndicator
├── Splitter.RootProvider
Examples
Context
Access the splitter's API with Splitter.Context or the useSplitterContext hook. This lets you resize panels programmatically:
Vertical
By default, the Splitter component is horizontal. If you need a vertical splitter, use the orientation prop:
Collapsible Panels
To make a panel collapsible, set the collapsible prop to true on the panel you want to make collapsible. Additionally, you can use the collapsedSize prop to set the size of the panel when it's collapsed.
This can be useful for building sidebar layouts.
Multiple Panels
Here's an example of how to use the Splitter component with multiple panels.
Root Provider
An alternative way to control the splitter is to use the RootProvider component and the useSplitter hook. This way you can access the state and methods from outside the component.
Resize Indicator
Use the Splitter.ResizeTriggerIndicator component to show a visual indicator on the resize handle.
Dynamic Collapsible
Use the collapsePanel() and expandPanel() methods to programmatically control panel collapse based on viewport size. This is useful for responsive sidebar layouts that collapse on smaller screens.
Nested
Nest splitters to build grid-like layouts. Use createSplitterRegistry() to create a shared registry between splitter instances — this enables multi-drag at intersection points where horizontal and vertical splitters meet.
API
See Ark UI Splitter docs for full props and examples.