UIColor.isBrightColor()
Determines whether a color has high perceived brightness.
static isBrightColor(color: UIColor, threshold?: number): boolean;
Parameters
- color — A UIColor instance.
- threshold — The brightness threshold, from 0 to 1; defaults to 0.72.
Return value
True if the color’s perceived brightness exceeds the threshold.
Related
class UIColor
A class that represents a single color value.
