Skip to main content

Interface: CustomColorOption

Configuration for a custom color selection option.

CustomColorOption defines how a color picker is configured and applied to a product. This includes which material the color affects, preset color options, and pricing and visibility rules for the color customization.

Extends

Indexable

[key: string]: unknown

Properties

code?

optional code: string

Configuration code for this color option. Used in generating the complete product code when this option is selected.


color?

optional color: string

Currently selected color value in hex format (#RRGGBB). Represents the active color selection.


materialId?

optional materialId: string

ID of the material to apply the color to. Specifies which part of the model should receive the selected color.


presets?

optional presets: string[]

List of predefined color values in hex format. These colors appear as swatches or presets in the color picker.


priceCode?

optional priceCode: string

Code used for price calculations related to this color option. This code is matched against price lists to determine any additional charges.


showPresets?

optional showPresets: boolean

If true, predefined color presets will be shown in the color picker. Provides quick selection of common or recommended colors.


visibility-code?

optional visibility-code: string

Visibility code that determines when this color option is available. Used for conditional display based on other selected options.