Skip to content

Color

Type module

Sources

Items from Color can be imported/included and used via following ways.

/**
* Import via: Color.ts
* Access items like: $color.myVariable
*/
import * as $color from "@amcharts/amcharts4/Color";

Variables

Color does not have any variables.

Functions

castColor(value: any)

Returns Color

Converts any value to Color.

color(value?: string | iRGB | Color,
alpha?: number
)

Returns Color

Resolves an input variable to a normal iRGB color and creates Color object for it.

isColor(value: any)

Returns boolean

Checks if supplied argument is instance of Color.

toColor(value: any)

Returns Color

Converts any value into a Color.