Bug 200851
Summary: | CSS reference filter doesn't work if the filter comes after the target element in the DOM | ||
---|---|---|---|
Product: | WebKit | Reporter: | Simon Fraser (smfr) <simon.fraser> |
Component: | SVG | Assignee: | Nobody <webkit-unassigned> |
Status: | RESOLVED CONFIGURATION CHANGED | ||
Severity: | Normal | CC: | ahmad.saleem792, ap, bfulgham, rniwa, sabouhallawa, simon.fraser, tanaka.toshiyuki, webkit-bug-importer, zimmermann |
Priority: | P2 | Keywords: | InRadar |
Version: | WebKit Nightly Build | ||
Hardware: | Unspecified | ||
OS: | Unspecified |
Simon Fraser (smfr)
https://codepen.io/tigt/pen/d820feb6082472382ec0778063e9ac08?editors=1100
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Simon Fraser (smfr)
This is about ordering. If the <svg> comes after the <img>, it works.
Simon Fraser (smfr)
The filter element build() functions return null if they have no renderer yet.
What we need to do is to invalidate the filtered element when the filter renderers change.
Simon Fraser (smfr)
I think the main difference between SVG and CSS filters here is that SVG builds the filter chain at paint time, but CSS builds it at style change time, which is too early because we're still building the render tree at that point.
Ahmad Saleem
I am able to reproduce this bug in Safari 15.5 on macOS 12.4 based on codepen mentioned in Description. Safari 15.5 shows lightening as "blue" while all other browsers (Chrome Canary 105 and Firefox Nightly 104) shows it as "red". Thanks!
Radar WebKit Bug Importer
<rdar://problem/97210640>
Ahmad Saleem
(In reply to Ahmad Saleem from comment #4)
> I am able to reproduce this bug in Safari 15.5 on macOS 12.4 based on
> codepen mentioned in Description. Safari 15.5 shows lightening as "blue"
> while all other browsers (Chrome Canary 105 and Firefox Nightly 104) shows
> it as "red". Thanks!
I am not able to reproduce this in Safari 16.4 and now it show a 'red' lightening similar to other browsers.
Marking this as "RESOLVED CONFIGURATION CHANGED". Thanks!