Chip
Interactive, compact elements for filtering, selections, and tag management.
Default
Basic chips in different states.
html
Default
Selected
Removable
Disabled
<span class="vt-chip">Default</span>
<span class="vt-chip vt-chip-active">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true" class="lucide lucide-check vt-w-3.5 vt-h-3.5">
<path d="M20 6 9 17l-5-5"></path>
</svg> Selected
</span>
<span class="vt-chip">
Removable
<button class="vt-text-foreground-muted vt-hover:text-foreground-primary vt-transition-colors"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true" class="lucide lucide-x vt-w-3.5 vt-h-3.5">
<path d="M18 6 6 18"></path><path d="m6 6 12 12"></path>
</svg></button>
</span>
<span class="vt-chip vt-opacity-50 vt-cursor-not-allowed">Disabled</span>
Filter Chips
Toggleable chips for filtering content.
html
<div class="vt-flex vt-flex-wrap vt-gap-2" data-chip-group="filter">
<button class="vt-chip vt-chip-active" data-selected="true">All</button>
<button class="vt-chip">Design</button>
<button class="vt-chip">Development</button>
<button class="vt-chip">Marketing</button>
<button class="vt-chip">Sales</button>
</div>
With Icons
Chips with leading icons for additional context.
html
Featured
Recent
v2.0
John Doe
<span class="vt-chip">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true" class="lucide lucide-star vt-w-3.5 vt-h-3.5 vt-text-warning-fill">
<path d="M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z"></path>
</svg> Featured
</span>
<span class="vt-chip">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true" class="lucide lucide-clock vt-w-3.5 vt-h-3.5 vt-text-foreground-muted">
<circle cx="12" cy="12" r="10"></circle><path d="M12 6v6l4 2"></path>
</svg> Recent
</span>
<span class="vt-chip">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true" class="lucide lucide-tag vt-w-3.5 vt-h-3.5 vt-text-foreground-muted">
<path d="M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z"></path><circle cx="7.5" cy="7.5" r=".5" fill="currentColor"></circle>
</svg> v2.0
</span>
<span class="vt-chip">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true" class="lucide lucide-user vt-w-3.5 vt-h-3.5 vt-text-foreground-muted">
<path d="M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2"></path><circle cx="12" cy="7" r="4"></circle>
</svg> John Doe
<button class="vt-text-foreground-muted vt-hover:text-foreground-primary vt-transition-colors"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true" class="lucide lucide-x vt-w-3.5 vt-h-3.5">
<path d="M18 6 6 18"></path><path d="m6 6 12 12"></path>
</svg></button>
</span>
Sizes
Chips in small, default, and large sizes.
html
Small
Default
Large
<span class="vt-chip vt-gap-1 vt-px-2 vt-py-0.5">Small</span>
<span class="vt-chip">Default</span>
<span class="vt-chip vt-gap-2 vt-px-4 vt-py-2 vt-text-base">Large</span>
Input Chips
Chips inside an input field for multi-value entry.
html
React
TypeScript
Astro
<div class="vt-w-full vt-max-w-md">
<label class="vt-text-sm vt-font-medium vt-block vt-mb-2" for="chip-5-1">Technologies</label>
<div class="vt-flex vt-flex-wrap vt-items-center vt-gap-2 vt-p-2 vt-rounded-lg vt-border vt-border-border-strong vt-bg-surface-card vt-min-h-[42px]">
<span class="vt-chip vt-border-transparent vt-bg-surface-subtle vt-py-1 vt-pr-1.5">
React
<button class="vt-w-4 vt-h-4 vt-rounded-full vt-bg-foreground-disabled/20 vt-hover:bg-foreground-disabled/40 vt-flex vt-items-center vt-justify-center vt-transition-colors">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true" class="lucide lucide-x vt-w-2 vt-h-2 vt-text-foreground-secondary">
<path d="M18 6 6 18"></path><path d="m6 6 12 12"></path>
</svg>
</button>
</span>
<span class="vt-chip vt-border-transparent vt-bg-surface-subtle vt-py-1 vt-pr-1.5">
TypeScript
<button class="vt-w-4 vt-h-4 vt-rounded-full vt-bg-foreground-disabled/20 vt-hover:bg-foreground-disabled/40 vt-flex vt-items-center vt-justify-center vt-transition-colors">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true" class="lucide lucide-x vt-w-2 vt-h-2 vt-text-foreground-secondary">
<path d="M18 6 6 18"></path><path d="m6 6 12 12"></path>
</svg>
</button>
</span>
<span class="vt-chip vt-border-transparent vt-bg-surface-subtle vt-py-1 vt-pr-1.5">
Astro
<button class="vt-w-4 vt-h-4 vt-rounded-full vt-bg-foreground-disabled/20 vt-hover:bg-foreground-disabled/40 vt-flex vt-items-center vt-justify-center vt-transition-colors">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true" class="lucide lucide-x vt-w-2 vt-h-2 vt-text-foreground-secondary">
<path d="M18 6 6 18"></path><path d="m6 6 12 12"></path>
</svg>
</button>
</span>
<input type="text" placeholder="Add..." class="vt-flex-1 vt-min-w-[80px] vt-bg-transparent vt-text-sm vt-text-foreground-primary vt-placeholder:text-foreground-muted vt-outline-none vt-border-none vt-py-1" id="chip-5-1">
</div>
</div>
Colored
Chips with semantic color variants.
html
In Progress
Complete
Pending
Failed
<span class="vt-chip vt-border-info-fill/30 vt-bg-info-fill/10 vt-text-info-fill">
<span class="vt-w-1.5 vt-h-1.5 vt-rounded-full vt-bg-info-fill"></span> In Progress
</span>
<span class="vt-chip vt-border-success-fill/30 vt-bg-success-fill/10 vt-text-success-fill">
<span class="vt-w-1.5 vt-h-1.5 vt-rounded-full vt-bg-success-fill"></span> Complete
</span>
<span class="vt-chip vt-border-warning-fill/30 vt-bg-warning-fill/10 vt-text-warning-fill">
<span class="vt-w-1.5 vt-h-1.5 vt-rounded-full vt-bg-warning-fill"></span> Pending
</span>
<span class="vt-chip vt-border-error-fill/30 vt-bg-error-fill/10 vt-text-error-fill">
<span class="vt-w-1.5 vt-h-1.5 vt-rounded-full vt-bg-error-fill"></span> Failed
</span>
Guidelines
Selectable or removable token: filters, tag inputs, interest pickers (vt-chip-active for selected). NOT for pure read-only status → badge.
Do
Complete
Pending
Don't
Design
Do
Design
Don't
API Reference
All CSS classes and data attributes.
| Class | Type | Description |
|---|---|---|
vt-chip |
Base | Selectable token — rounded, bordered, hover state |
vt-chip-active |
State | Selected chip — brand-tinted fill and border |
data-selected |
Data | Selection state hook toggled by the JS bundle |
Accessibility
Keyboard and screen reader support.
| Feature | Details |
|---|---|
| Element | Use button for toggleable chips so they are focusable and keyboard-operable |
| State | Toggle chips expose aria-pressed matching the selected state |
| Removal | Removable chips need an aria-label on the remove control, e.g. "Remove Design" |