Bug 232919

Summary: variable reference causes incorrect base URL to be applied to url() values
Product: WebKit Reporter: Cameron McCormack (:heycam) <heycam>
Component: CSSAssignee: Nobody <webkit-unassigned>
Status: RESOLVED DUPLICATE    
Severity: Normal CC: darin, marcos
Priority: P2    
Version: WebKit Local Build   
Hardware: Unspecified   
OS: Unspecified   
URL: https://mcc.id.au/temp/style-sheet-relative-image-var.html
See Also: https://bugs.webkit.org/show_bug.cgi?id=232906

Description Cameron McCormack (:heycam) 2021-11-09 19:05:04 PST
STR:

1. Open https://mcc.id.au/temp/style-sheet-relative-image-var.html.
2. Result should be green, not red.

The presence of the var() reference in the background-image declaration causes the previous url() to be resolved against the document URL, and not the style sheet URL.
Comment 1 Darin Adler 2021-11-10 11:30:19 PST
Surprised that this is still wrong after the fix for bug 230243.
Comment 2 Darin Adler 2021-11-10 15:04:31 PST
It’s not wrong. This is a duplicate of bug 230243 and already fixed on TOT.

*** This bug has been marked as a duplicate of bug 230243 ***