Resizable
Split pane layouts with draggable handles for resizing panels.
Interactive
Requires:
veritheme.js
JS init: automatic
Horizontal
Two side-by-side panels separated by a vertical drag handle. Drag to resize.
html
Panel 1
60%
Panel 2
40%
<div class="vt-resizable vt-h-64" data-vt-resizable="horizontal">
<div class="vt-resizable-panel" style="width: 60%">
<span>Panel 1</span>
<span class="vt-size-label vt-tabular-nums vt-font-medium vt-text-foreground-disabled">60%</span>
</div>
<div class="vt-resize-handle" role="separator" aria-orientation="vertical" aria-label="Resize">
<span class="vt-resize-handle-dot"></span>
<span class="vt-resize-handle-dot"></span>
<span class="vt-resize-handle-dot"></span>
</div>
<div class="vt-resizable-panel" style="width: 40%">
<span>Panel 2</span>
<span class="vt-size-label vt-tabular-nums vt-font-medium vt-text-foreground-disabled">40%</span>
</div>
</div>
Vertical
Two stacked panels separated by a horizontal drag handle. Drag to resize.
html
Top Panel
50%
Bottom Panel
50%
<div class="vt-resizable vt-h-80" data-vt-resizable="vertical">
<div class="vt-resizable-panel" style="height: 50%">
<span>Top Panel</span>
<span class="vt-size-label vt-tabular-nums vt-font-medium vt-text-foreground-disabled">50%</span>
</div>
<div class="vt-resize-handle" role="separator" aria-orientation="horizontal" aria-label="Resize">
<span class="vt-resize-handle-dot"></span>
<span class="vt-resize-handle-dot"></span>
<span class="vt-resize-handle-dot"></span>
</div>
<div class="vt-resizable-panel" style="height: 50%">
<span>Bottom Panel</span>
<span class="vt-size-label vt-tabular-nums vt-font-medium vt-text-foreground-disabled">50%</span>
</div>
</div>
Three Panels
Three horizontal panels with two drag handles. Drag to resize.
html
Panel 1
30%
Panel 2
40%
Panel 3
30%
<div class="vt-resizable vt-h-64" data-vt-resizable="horizontal">
<div class="vt-resizable-panel" style="width: 30%">
<span>Panel 1</span>
<span class="vt-size-label vt-tabular-nums vt-font-medium vt-text-foreground-disabled">30%</span>
</div>
<div class="vt-resize-handle" role="separator" aria-orientation="vertical" aria-label="Resize">
<span class="vt-resize-handle-dot"></span>
<span class="vt-resize-handle-dot"></span>
<span class="vt-resize-handle-dot"></span>
</div>
<div class="vt-resizable-panel" style="width: 40%">
<span>Panel 2</span>
<span class="vt-size-label vt-tabular-nums vt-font-medium vt-text-foreground-disabled">40%</span>
</div>
<div class="vt-resize-handle" role="separator" aria-orientation="vertical" aria-label="Resize">
<span class="vt-resize-handle-dot"></span>
<span class="vt-resize-handle-dot"></span>
<span class="vt-resize-handle-dot"></span>
</div>
<div class="vt-resizable-panel" style="width: 30%">
<span>Panel 3</span>
<span class="vt-size-label vt-tabular-nums vt-font-medium vt-text-foreground-disabled">30%</span>
</div>
</div>
With Content
Resizable IDE-like layout: a file tree beside an editor. Drag the handle to resize.
html
Explorer
index.ts
import app from './app' const port = 3000 app.listen(port)
<div class="vt-resizable vt-h-80" data-vt-resizable="horizontal">
<div class="vt-resizable-panel" style="width: 30%">
<p class="vt-section-label">Explorer</p>
<div class="vt-tree" data-vt-tree="">
<a class="vt-tree-leaf vt-tree-active"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" fill="none" class="vt-tree-icon" aria-hidden="true">
<path d="M8 18H16" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path><path d="M8 14H16" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path><path d="M8 10H10" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path><path d="M13 2.5V3C13 5.82843 13 7.24264 13.8787 8.12132C14.7574 9 16.1716 9 19 9H19.5M20 10.6569V14C20 17.7712 20 19.6569 18.8284 20.8284C17.6569 22 15.7712 22 12 22C8.22876 22 6.34315 22 5.17157 20.8284C4 19.6569 4 17.7712 4 14V9.45584C4 6.21082 4 4.58831 4.88607 3.48933C5.06508 3.26731 5.26731 3.06508 5.48933 2.88607C6.58831 2 8.21082 2 11.4558 2C12.1614 2 12.5141 2 12.8372 2.11401C12.9044 2.13772 12.9702 2.165 13.0345 2.19575C13.3436 2.34355 13.593 2.593 14.0919 3.09188L18.8284 7.82843C19.4065 8.40649 19.6955 8.69552 19.8478 9.06306C20 9.4306 20 9.83935 20 10.6569Z" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path>
</svg> index.ts</a>
<a class="vt-tree-leaf"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" fill="none" class="vt-tree-icon" aria-hidden="true">
<path d="M8 18H16" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path><path d="M8 14H16" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path><path d="M8 10H10" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path><path d="M13 2.5V3C13 5.82843 13 7.24264 13.8787 8.12132C14.7574 9 16.1716 9 19 9H19.5M20 10.6569V14C20 17.7712 20 19.6569 18.8284 20.8284C17.6569 22 15.7712 22 12 22C8.22876 22 6.34315 22 5.17157 20.8284C4 19.6569 4 17.7712 4 14V9.45584C4 6.21082 4 4.58831 4.88607 3.48933C5.06508 3.26731 5.26731 3.06508 5.48933 2.88607C6.58831 2 8.21082 2 11.4558 2C12.1614 2 12.5141 2 12.8372 2.11401C12.9044 2.13772 12.9702 2.165 13.0345 2.19575C13.3436 2.34355 13.593 2.593 14.0919 3.09188L18.8284 7.82843C19.4065 8.40649 19.6955 8.69552 19.8478 9.06306C20 9.4306 20 9.83935 20 10.6569Z" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path>
</svg> utils.ts</a>
<a class="vt-tree-leaf"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" fill="none" class="vt-tree-icon" aria-hidden="true">
<path d="M8 18H16" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path><path d="M8 14H16" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path><path d="M8 10H10" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path><path d="M13 2.5V3C13 5.82843 13 7.24264 13.8787 8.12132C14.7574 9 16.1716 9 19 9H19.5M20 10.6569V14C20 17.7712 20 19.6569 18.8284 20.8284C17.6569 22 15.7712 22 12 22C8.22876 22 6.34315 22 5.17157 20.8284C4 19.6569 4 17.7712 4 14V9.45584C4 6.21082 4 4.58831 4.88607 3.48933C5.06508 3.26731 5.26731 3.06508 5.48933 2.88607C6.58831 2 8.21082 2 11.4558 2C12.1614 2 12.5141 2 12.8372 2.11401C12.9044 2.13772 12.9702 2.165 13.0345 2.19575C13.3436 2.34355 13.593 2.593 14.0919 3.09188L18.8284 7.82843C19.4065 8.40649 19.6955 8.69552 19.8478 9.06306C20 9.4306 20 9.83935 20 10.6569Z" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path>
</svg> styles.css</a>
<a class="vt-tree-leaf"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" fill="none" class="vt-tree-icon" aria-hidden="true">
<path d="M13.6656 6.49446H16C18.8284 6.49446 20.2426 6.49446 21.1213 7.37314C22 8.25182 22 9.66603 22 12.4945V14.5C22 17.3284 22 18.7426 21.1213 19.6213C20.2426 20.5 18.8284 20.5 16 20.5H8C5.17157 20.5 3.75736 20.5 2.87868 19.6213C2 18.7426 2 17.3284 2 14.5V8.99183C2 6.65409 2 5.48521 2.61604 4.67881C2.7778 4.46706 2.96706 4.2778 3.17881 4.11604C3.98521 3.5 5.15409 3.5 7.49183 3.5C8.16633 3.5 8.50358 3.5 8.81392 3.60442C8.8976 3.63257 8.97932 3.66623 9.05854 3.70518C9.35239 3.84965 9.59179 4.08719 10.0706 4.56227L10.8483 5.33389C11.4254 5.9066 11.714 6.19295 12.08 6.3437C12.446 6.49446 12.8525 6.49446 13.6656 6.49446Z" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path>
</svg> components</a>
<a class="vt-tree-leaf"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" fill="none" class="vt-tree-icon" aria-hidden="true">
<path d="M8 18H16" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path><path d="M8 14H16" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path><path d="M8 10H10" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path><path d="M13 2.5V3C13 5.82843 13 7.24264 13.8787 8.12132C14.7574 9 16.1716 9 19 9H19.5M20 10.6569V14C20 17.7712 20 19.6569 18.8284 20.8284C17.6569 22 15.7712 22 12 22C8.22876 22 6.34315 22 5.17157 20.8284C4 19.6569 4 17.7712 4 14V9.45584C4 6.21082 4 4.58831 4.88607 3.48933C5.06508 3.26731 5.26731 3.06508 5.48933 2.88607C6.58831 2 8.21082 2 11.4558 2C12.1614 2 12.5141 2 12.8372 2.11401C12.9044 2.13772 12.9702 2.165 13.0345 2.19575C13.3436 2.34355 13.593 2.593 14.0919 3.09188L18.8284 7.82843C19.4065 8.40649 19.6955 8.69552 19.8478 9.06306C20 9.4306 20 9.83935 20 10.6569Z" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path>
</svg> README.md</a>
</div>
</div>
<div class="vt-resize-handle" role="separator" aria-orientation="vertical" aria-label="Resize">
<span class="vt-resize-handle-dot"></span>
<span class="vt-resize-handle-dot"></span>
<span class="vt-resize-handle-dot"></span>
</div>
<div class="vt-resizable-panel" style="width: 70%">
<p class="vt-section-label">index.ts</p>
<pre class="vt-code">import app from './app'
const port = 3000
app.listen(port)</pre>
</div>
</div>
Nested
Horizontal split with a nested vertical split. Drag handles to resize.
html
Sidebar
20%
Editor
60%
Terminal
40%
<div class="vt-resizable vt-h-80" data-vt-resizable="horizontal">
<div class="vt-resizable-panel" style="width: 20%">
<span>Sidebar</span>
<span class="vt-size-label vt-tabular-nums vt-font-medium vt-text-foreground-disabled">20%</span>
</div>
<div class="vt-resize-handle" role="separator" aria-orientation="vertical" aria-label="Resize">
<span class="vt-resize-handle-dot"></span>
<span class="vt-resize-handle-dot"></span>
<span class="vt-resize-handle-dot"></span>
</div>
<div class="vt-resizable-panel vt-resizable" style="width: 80%" data-vt-resizable="vertical">
<div class="vt-resizable-panel" style="height: 60%">
<span>Editor</span>
<span class="vt-size-label vt-tabular-nums vt-font-medium vt-text-foreground-disabled">60%</span>
</div>
<div class="vt-resize-handle" role="separator" aria-orientation="horizontal" aria-label="Resize">
<span class="vt-resize-handle-dot"></span>
<span class="vt-resize-handle-dot"></span>
<span class="vt-resize-handle-dot"></span>
</div>
<div class="vt-resizable-panel" style="height: 40%">
<span>Terminal</span>
<span class="vt-size-label vt-tabular-nums vt-font-medium vt-text-foreground-disabled">40%</span>
</div>
</div>
</div>
With Min/Max Constraints
Drag to resize. Each panel stays between 20% and 70% of the group (data-vt-min, data-vt-max).
html
Sidebar · min 20%, max 70%
40%
Content · min 20%, max 70%
60%
<div class="vt-resizable vt-h-64" data-vt-resizable="horizontal" data-vt-min="20" data-vt-max="70">
<div class="vt-resizable-panel" style="width: 40%">
<span>Sidebar · min 20%, max 70%</span>
<span class="vt-size-label vt-tabular-nums vt-font-medium vt-text-foreground-disabled">40%</span>
</div>
<div class="vt-resize-handle" role="separator" aria-orientation="vertical" aria-label="Resize">
<span class="vt-resize-handle-dot"></span>
<span class="vt-resize-handle-dot"></span>
<span class="vt-resize-handle-dot"></span>
</div>
<div class="vt-resizable-panel" style="width: 60%">
<span>Content · min 20%, max 70%</span>
<span class="vt-size-label vt-tabular-nums vt-font-medium vt-text-foreground-disabled">60%</span>
</div>
</div>
Guidelines
Editor
Preview
Acme
Home · Pricing · Docs
API Reference
| Class | Type | Description |
|---|---|---|
vt-resizable |
Base | Group — a bordered, rounded frame whose panels sit in a row |
data-vt-resizable="horizontal" |
Data | Side-by-side panels, dragged left and right (the JS bundle reads it) |
data-vt-resizable="vertical" |
Data | Stacked panels, dragged up and down; the group becomes a column and its handles horizontal bars |
vt-resizable-panel |
Part | Panel — a padded column (16px, 12px between blocks), Body/SM, secondary; starts at its width/height and shares the rest |
vt-resize-handle |
Part | Drag handle between two panels — a 6px bar, brand on hover; orientation follows the group |
vt-resize-handle-dot |
Part | Grip dot of the handle, 2px — three per handle |
vt-resizable-panelvt-resizable |
Modifier | A group nested as a panel of another — no frame, no padding |
data-vt-min/data-vt-max |
Data | Smallest and largest panel size, percent of the group (default 10 and 90) |
Accessibility
| Feature | Details |
|---|---|
| Role | Resize handle uses role="separator" with aria-orientation |
| Keyboard | Arrow keys resize panels when handle is focused |
| Label | Handle should have aria-label="Resize" for screen readers |
| Min/Max | Use aria-valuemin, aria-valuemax, aria-valuenow on the handle |