Skip to components
DEVELOPER REFERENCE · v4.0.0

ColorPicker API

Props, callbacks and methods. Select an underlined type to explore its fields, allowed values and callback arguments.

ColorPicker10 props1 callbacks0 methods

Props10

ColorPicker props
NameTypeDescription
labelRequiredstringLabel content or accessible name for the component, as rendered by this control.
valueOptionalstring | undefinedValue to display or edit. The declared type identifies the supported representation; change callbacks describe how edited values are emitted.
defaultLabelRequiredstringLabel for the default or unset color choice.
customLabelRequiredstringLabel for choosing a custom color.
customHexLabelOptionalstring | undefinedAccessible label for entering a custom hexadecimal color.
invalidColorOptionalstring | undefinedValidation message shown when the entered color is invalid.
colorLabelsRequired
Readonly<Record<string, string>>Inspect type
Maps color values to localized display/accessibility labels.
optionalOptionalboolean | undefinedAllows the color value to be cleared or left unset.
allowHexInputOptionalboolean | undefinedSet false for a selection-only palette and native color chooser.
disabledOptionalboolean | undefinedDisables user interaction with the control.

Events and callbacks1

ColorPicker events and callbacks
NameTypeDescription
onChangeRequired
(value: string | undefined) => voidInspect type
Receives the new value when the user changes the control. Update the corresponding value prop for controlled use.

Methods0

No component-specific imperative methods. Use props and callbacks to control this component.