Bug 235270

Summary: Non-HTMLCanvasElement based canvas's don't support all the syntax that CSS supports for parsing colors
Product: WebKit Reporter: Sam Weinig <sam>
Component: CanvasAssignee: Nobody <webkit-unassigned>
Status: NEW ---    
Severity: Normal CC: dino, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: Other   
Hardware: Unspecified   
OS: Unspecified   

Description Sam Weinig 2022-01-15 12:25:52 PST
Non-HTMLCanvasElement based canvas's (OffscreenCanvas, CustomPaintCanvas) don't support all the syntax that CSS supports for parsing colors because they use a variant of CSSParser::parseColor that doesn't have a CSSParserContext initialized with the appropriate Settings object.

To make this work, we will need to find a way to initialize a CSSParserContext for these callers, perhaps using the ScriptExecutionContext for the worker cases.
Comment 1 Radar WebKit Bug Importer 2022-01-22 12:26:18 PST
<rdar://problem/87928857>