ColourPickerOptions

View as Markdown

Options for the Colour Picker.

TypeScript
export interface

Properties

PropertyTypeDescriptionDefault
filterColours(context:ColourPickerFilterContext) =>ColourPickerFilterResult | voidChooses which of the supplied colours (theme & colour palette) the Palette tab shows
orderPaletteColoursbooleanOrders Palette swatches around the colour wheel; if false, each colour stays the order suppliedtrue
removeDuplicatesbooleanLeave out duplicates of swatches already displayedtrue
showGroupLabelsbooleanShow Theme and Palette headings on the Palette tab (if both have colours)false
tabsColourPickerTab[]Colour Picker tabs to display in order provided; Custom, Palette, or both['Custom', 'Palette']

Property Details

filterColours

Chooses which of the supplied colours (theme & colour palette) the Palette tab shows

TypeScript
filterColours?: (context: ColourPickerFilterContext) => ColourPickerFilterResult | void;
Property Value

(context:ColourPickerFilterContext) =>ColourPickerFilterResult | void

orderPaletteColours

Orders Palette swatches around the colour wheel; if false, each colour stays the order supplied

TypeScript
orderPaletteColours?: boolean;
Default Value

true

Property Value

boolean

removeDuplicates

Leave out duplicates of swatches already displayed

TypeScript
removeDuplicates?: boolean;
Default Value

true

Property Value

boolean

showGroupLabels

Show Theme and Palette headings on the Palette tab (if both have colours)

TypeScript
showGroupLabels?: boolean;
Default Value

false

Property Value

boolean

tabs

Colour Picker tabs to display in order provided; Custom, Palette, or both

TypeScript
tabs?: ColourPickerTab[];
Default Value

['Custom', 'Palette']

Property Value

ColourPickerTab[]