@tempots/color

LUV class

Represents a color in the LUV color space.

Signature:

declare class LUV 

Constructors

Constructor

Modifiers

Description

(constructor)(l, u, v)

Creates a new instance of the LUV color.

Properties

Property

Modifiers

Type

Description

equals

readonly

(other: LUV, tollerance?: number) => boolean

Checks if the current LUV color is equal to another LUV color.

l

readonly

number

The lightness component of the Luv color model.

ofChannels

static

readonly

([l, u, v]: [l: number, u: number, v: number]) => LUV

toChannels

readonly

() => [number, number, number]

Converts the LUV color to an array of channels.

toString

readonly

() => string

Returns a string representation of the LUV color. The string is formatted as "luv(l, u, v)".

u

readonly

number

The u component of the Luv color model.

v

readonly

number

The v component of the Luv color model.

withL

readonly

(l: number) => LUV

Creates a new LUV color with the specified lightness value.

withU

readonly

(u: number) => LUV

Creates a new LUV instance with the specified u value.

withV

readonly

(v: number) => LUV

Creates a new LUV instance with the specified v value.