Carregando…
Carregando…
Carregando…Swatch grid with hex input and native color picker integration.
$ npx kikitocn add color-pickerimport { ColorPicker } from "@/components/ui/cn/color-picker/ColorPicker";
export function ColorPickerExample() {
return (
<ColorPicker />
);
}| Prop | Tipo | Padrão | Descrição |
|---|---|---|---|
value | string | — | Cor selecionada (controlado) |
defaultValue | string | — | Cor inicial (não-controlado) |
onChange | (color: string) => void | — | Callback ao selecionar cor |
swatches | string[] | — | Array de cores pré-definidas |
showInput | boolean | true | Exibir campo de texto hex |
disabled | boolean | false | Desabilitar interações |
className | string | — | Classes CSS extras |
Swatches + hex input