import * as colors from "https://deno.land/x/colors@v2.0.0-rc.1/src/color.ts";
Functions
Get average of colors. Can be used for grayscale. | |
Calculate chroma | |
f cmyk | Convert RGB(A) to CMYK |
Get contrast ratio | |
f hcg | Convert RGB(A) to HCG |
f hex | Convert RGB(A) to Hex |
f hsl | Convert RGB(A) to Hue, Saturation, Lightness |
f hsv | Convert RGB(A) to Hue, Saturation, Value |
f hue | Calculate hue using chroma |
Invert a color linearly | |
Bright colors darken, dark colors brighten. | |
f json | |
f lab | CIE Lab color space |
Get lightness of color. | |
Get linear rgb values | |
Calculate luminance | |
f max | Get maximum of r, g, b |
f min | Get minimum of r, g, b |
f mix | Mix with a different color. Copyright (c) 2006-2009 Hampton Catlin, Natalie Weizenbaum, and Chris Eppstein http://sass-lang.com |
Get perceived lightness | |
Get saturation | |
Get a shade of the color | |
Stringify the RGBA color | |
f tint | Get a tint of the color |
f xyz | CIE 1931 XYZ |