export declare type HslColor2 = { h: number; s: number; l: number; a?: number; }; export declare const getContrastColor: (bgLuminance: number, fgLuminance: number, targetContrast: number, hue: number, saturation?: number, lightness?: number) => string; export declare const parseHsl: (hsl: string) => HslColor2; export declare const stringifyHsl: (hsl: HslColor2) => string; export declare const randomColorFromString: (str: string, $opts?: { h?: [number, number]; s?: [number, number]; l?: [number, number]; }) => string; /** * Returns white or black, based on which provides higher contrast when rendered on top of the passed in `color`. * @param color - the color in hex, rgb, or hsl * @param leeway - integer from -10 to 10. The more positive the number, the more that white will be weighted. Defaults to 0. */ export declare const readableColor: (color: string, leeway?: number) => "#000" | "#fff";