Skip to content
Velkin LogoVelkin Logo
Velkin
VELKIN/UI

Modern UI components for product teams and their AI agents. Lit core, typed wrappers, live MCP.

sales@velkinui.com

Product

  • Docs
  • Components
  • Studio
  • Pricing

Resources

  • Quick start
  • Blog
  • Changelog
  • Roadmap
  • Status

Project

  • About
  • Contact
  • License
  • Privacy
  • Terms

© 2026 Velkin. MIT core · Pro licenses available.

VELKIN

Color Swatch

A color swatch component for palettes, presets, and recent colors.

vu-color-swatch · @velkin/react/color-swatch

Copy page

Import

React
npm i @velkin/react

import { VuColorSwatch } from "@velkin/react/color-swatch";

Examples

API

Props

PropTypeDefaultDescription
colorstring"transparent"CSS color painted on the chip. Default: `"transparent"`.
valuestring""Selection token in `vu-select` detail; defaults to `color`.
sizeVuColorSwatchSize"md"Visual size preset. Default: `"md"`.
shapeVuColorSwatchShape"circle"Chip outline (`circle` or `square`). Default: `"circle"`.
checkerboardbooleanfalseTransparency checkerboard under the fill (`checkerboard` attr).
selectedbooleanfalseContrast ring and checkmark (`selected` attr). Default: `false`.
selectablebooleanfalseFocusable and clickable; emits `vu-select` (`selectable` attr).
disabledbooleanfalseDisables interaction when `selectable` (`disabled` attr).
readonlybooleanfalseFocusable but does not emit `vu-select` when `selectable`.
colorNamestring""Accessible name; blank defaults to `Color {color}`.

Events

EventDetailDescription
vu-selectVuColorSwatchSelectDetailA `selectable` swatch was activated.

CSS parts

PartDescription
baseThe colored chip (`<button>` when selectable, `<div>` otherwise).

Types

NameDefinition
VuColorSwatchSelectDetail
{ color: string; value: string; }
VuColorSwatchShape
"circle" | "square"
VuColorSwatchSize
"sm" | "md" | "lg" | "xs" | "xl"

Related

Inputs

  • Advanced FilterAn advanced filter component with expression input and visual builder.
  • ButtonA clickable button component with multiple variants and states.
  • Button GroupA button group component with shared styling and optional selection.
  • CheckboxA checkbox component with label, hint, and validation.
  • Checkbox GroupA checkbox group component with shared label and validation.
  • Color AreaA two-dimensional color picker component for saturation and brightness.

Guides

  • FormsFormData, VuForm, and validation
  • EventsonVu* / v-model / e.detail
  • Appearancevariant, color, tone, size

Browse

  • Previous: Color SliderEarlier in the sidebar
  • Next: Color Swatch PickerLater in the sidebar
  • All componentsBrowse the full index