pub fn ensure_minimum_contrast(
foreground: Hsla,
background: Hsla,
minimum_apca_contrast: f32,
) -> HslaExpand description
Adjusts the foreground color to meet the minimum APCA contrast against the background. The minimum_apca_contrast should be an absolute value (e.g., 75 for Lc 75).
This implementation gradually adjusts the lightness while preserving the hue and saturation as much as possible, only falling back to black/white when necessary.