Note: if you want a reliable library use something like color instead.
Docs
ColorConverters
RGBToHSV
/** * Takes an `RGBColor` and converts it to `HSVColor` */;
HSVToRGB
/** * Takes an `HSVColor` and converts it to `RGBColor` */;
StringToRGB
/** * Takes an `StringColor` and converts it to `RGBColor`, * If input string is invalid `null` will be returned. */;
StringToHVS
/** * Takes an `StringColor` and converts it to `HSVColor`, * If input string is invalid `null` will be returned. */;
HSVToHEX
/** * Takes an `HSVColor` and converts it to `String` (HEX Format) */
RGBToHEX
/** * Takes an `RGBColor` and converts it to `String` (HEX Format) */;
ColorTypes
RGBColor
/** * Represents a color in the rgb(a) format. * * * Range `[0 - 1]` */
HSVColor
/** * Represents a color in the hsv(a) format. * * * Range `[h 0 - 360, v/s/a 0 - 1]` */
StringColor
/** * Represents a color in a string format. * Valid strings are `#000 | #0000 | #000000 | #00000000` * Or `rgb(0, 0, 0, 0) | rgba(0, 0, 0, 0, 0)` Range [rgb 0-255, a: 0-1] * */
HandleGet
HandleGetHex
;
HandleSet
ConvertString
;
HandleConvertHexString
/** * **assumes that the input is valid** */;
UtilityFunction
GetReadableTextColor
;
ShiftHue
/** * Shifts the hue of the `HSVColor` by the Value */;
index
interfaces
GetColorTypeHex
;
GetColorType
;
GetColorOptions
regex
isValidHex
;
isValidRGB
;
utils
GetReadableTextColor
;
ShiftHue
/** * Shifts the hue of the `HSVColor` by the Value */;
convertCssColorToHex
/**Returns the hex value of the color string or the input string */;
validators
isValidStringColor
;
Generated with suf-cli
License
Copyright (c) 2020 Leonard Grosoli Licensed under the MIT license.