Update color-contrast() to support a target contrast ratio
Created attachment 425696 [details] Patch
Created attachment 425710 [details] Patch
Committed r275826 (236396@main): <https://commits.webkit.org/236396@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 425710 [details].
<rdar://problem/76543214>
Comment on attachment 425710 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=425710&action=review > Source/WebCore/css/parser/CSSPropertyParserHelpers.cpp:1533 > + size_t indexOfColorWithHigestContrastRatio = 0; Could use a const Color* instead of an index, and then could switch to a range-based for loop. Or could use std::max_element instead of writing a loop.