Product Variant Swatch Selector
A production-scale, light + dark Product Variant Swatch Selector component. Copy-paste via the CLI; you own the code.
npx lerpa-cli add product-variant-swatch-selectorLive preview available in the gallery.
Usage
import { ProductVariantSwatchSelector } from "@lerpa/ui";
<ProductVariantSwatchSelector />Props
| Prop | Type | Default | Description |
|---|---|---|---|
| className | string | — | |
| colors | VariantColor[] | — | |
| sizes | VariantSize[] | — | |
| outOfStock | Set<string> | — |
Accessibility
- Keyboard accessible interactive elements.
- Respects prefers-reduced-motion where animated.
- Color is never the only signal.