Skip to content

pantoken-root / plugins/pantoken/custom-theme-colors/src / deriveScale

Funksjon: deriveScale() ​

deriveScale(hex, curve): CustomColorScale

Beta

Avlei ei full primitive skala frå éin hex: fest ho til steget med næraste referanselysheit, og bygg deretter kvart steg oppatt ved si referanselysheit med inndata si hue og ein chroma skalert etter referanseforma.

Parametrar ​

hex ​

string

Ein hex-farge akseptert av parseHexColor.

curve ​

ReferenceCurve

Utdata frå buildReferenceCurve.

Returnerer ​

CustomColorScale

The CustomColorScale.