You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I put an absolutely-positioned element in an SVG <foreignObject>, in Ladybird, it is positioned relative to the next abspos-containing-block-creating ancestor outside the entire SVG, not the foreignObject.
See this resolution and behavior in other browsers, which, to my knowledge, has not lead to a spec change yet.
The only thing I can find in the SVG spec is the note at the bottom of Establishing a stacking context in SVG, which only speaks of a "fixed position containing block" in CSS terms.
Operating system
Linux
Steps to reproduce
Make an SVG with a <foreignObject> in it.
Put anything with position: absolute; top: 0; left: 0 inside that.
Notice how that element aligns with the top left of whatever is outside the SVG, not the foreignObject.
Expected behavior
A foreignObject should create a containing block for absolutely (and fixed) positioned elements.
Actual behavior
A foreignObject does not create a containing block for absolutely positioned elements.
Summary
When I put an absolutely-positioned element in an SVG <foreignObject>, in Ladybird, it is positioned relative to the next abspos-containing-block-creating ancestor outside the entire SVG, not the foreignObject.
See this resolution and behavior in other browsers, which, to my knowledge, has not lead to a spec change yet.
The only thing I can find in the SVG spec is the note at the bottom of Establishing a stacking context in SVG, which only speaks of a
"fixed position containing block" in CSS terms
.Operating system
Linux
Steps to reproduce
position: absolute; top: 0; left: 0
inside that.Expected behavior
A foreignObject should create a containing block for absolutely (and fixed) positioned elements.
Actual behavior
A foreignObject does not create a containing block for absolutely positioned elements.
URL for a reduced test case
N/A
HTML/SVG/etc. source for a reduced test case
Log output and (if possible) backtrace
Screenshots or screen recordings
The reduced test case in:
Firefox:
Ladybird:
Build flags or config settings
None
Contribute a patch?
The text was updated successfully, but these errors were encountered: