import type { Image } from './image.model'; export interface OptionValue { /** * The label of the value. * * @example '34L' */ label: string; /** * Identifier for the value. This may be a database key or other non-human-readable * string. * * @example 'bcs5vaOjgEQ9Uaaadk9zQIrXE6' */ value: string; /** * Swatches to display instead of the text, typically used for colors * Can be a string to represent a color or an image */ swatch?: Image | string; /** * Images to display when this option is selected * Typically used for color swatches to show images of the product in the matching color */ images?: Image[]; /** * Boolean to indicate if the option is currently selected. Should be populated by the initial * state of the product (ie. if a variant is selected, the appropriate value should be set) */ isSelected?: boolean; /** * Boolean to indicate if the option can be selected. */ isSelectable?: boolean; }