Functions
colorDark
- colorDark(color: string, level: number): string
Parameters
color: string
level: number
Returns string
colorLighten
- colorLighten(color: string, level: number): string
Parameters
color: string
level: number
Returns string
colorToRgb
- colorToRgb(hexcolor: string): number[]
Parameters
Returns number[]
getContrastYIQ
- getContrastYIQ(color: string): keyof { black: any; white: any }
Parameters
Returns keyof { black: any; white: any }
isColorString
- isColorString(color: string): boolean
Parameters
Returns boolean
rgbToHexColor
- rgbToHexColor(rgb: number[]): string
颜色加深