VitNode
Forms

Color Picker

Select a color from a color palette.

Preview

Usage

import { z } from 'zod';
import { AutoForm } from 'vitnode-frontend/form/auto-form';
import { AutoFormColorPicker } from 'vitnode-frontend/form/fields/color-picker';
const formSchema = z.object({
  color_primary: z.string(),
});
<AutoForm
  formSchema={formSchema}
  fields={[
    {
      id: 'color_primary',
      component: AutoFormColorPicker, 
    },
  ]}
/>

API Reference

PropTypeDefault
onChange
(value: string | null) => void;
-
value
string | null
-
required
boolean
-
disabled
boolean
-
clearOnClick
() => void
-

On this page