Class: PaletteColors

Palette. PaletteColors

Contains the color formats used by the color palette


new PaletteColors()

Default Constructor

Source:

Members


Black :number

Color Value

Black portion of the CMYK color format

Type:
  • number
Source:

Blue :number

Color Value

Blue portion of the RGB color format

Type:
  • number
Source:

CMYK :Array.<string>

Color Format

Represents four color values between 0-100%: Cyan, Magenta, Yellow, and Key(Black)

Type:
  • Array.<string>
Source:

Cyan :number

Color Value

Cyan portion of the CMYK color format

Type:
  • number
Source:

Green :number

Color Value

Green portion of the RGB color format

Type:
  • number
Source:

Hex :string

Color Format

A string combining three (3) hexadecimal values (Ex: #1188FF) representing red (11),

Type:
  • string
Source:

HSL :Array.<number>

Color Format

Represents three values; Hue (0-359), Saturation (0-100%), and Lightness (100%)

Type:
  • Array.<number>
Source:

Hue :number

Color Value

Hue portion of the HSL color format

Type:
  • number
Source:

Light :number

Color Value

Light portion of the HSL color format

Type:
  • number
Source:

Luminosity :number

Color Formula

Derived value of the RGB color format used to order colors by luminance. The value is a product of the
formula: Math.sqrt(.241 Red + .691 Green + .068 * Blue)

Type:
  • number
Source:

Magenta :number

Color Value

Magenta portion of the CMYK color format

Type:
  • number
Source:

Red :number

Color Value

Red portion of the RGB color format

Type:
  • number
Source:

RGB :Array.<number>

Color Format

Represents three colors values between 0-255: Red. Green, and Blue

Type:
  • Array.<number>
Source:

Saturation :number

Color Value

Saturation portion of the HSL color format

Type:
  • number
Source:

Yellow :number

Color Value

Yellow portion of the CMYK color format

Type:
  • number
Source:

Methods


createColorFormats(hexValue)

Color Format Creation

Creates the color formats (Hexadecimal, RGB, HSL, CMYK) used to create the color palette and
assigns the constituent properties of each format.

Parameters:
Name Type Description
hexValue string

Value used to create the color formats

Source: