Created attachment 465152 [details] test-case In ResizeObservation::computeObservedSizes(), it calls `downcast<SVGElement>(*m_target).getBoundingBox()` which returns 0x0 when the layout size of SVG is not empty. See the attached test.
According to [1], > Web content can also contain SVG elements. SVG elements that do not have associated CSS layout boxes define bounding box instead of a content box. Content rect for the SVGGraphicsElements without CSS layout boxes is a rect whose: > width is bounding box width > height is bounding box height So from ResizeObserver size, it is correct to call `downcast<SVGElement>(*m_target).getBoundingBox()` in `ResizeObservation::computeObservedSizes()`. I'll leave this bug to an SVG Expert. [1] https://drafts.csswg.org/resize-observer/
Pull request: https://github.com/WebKit/WebKit/pull/10955
<rdar://problem/106194536>
Committed 262145@main (afa718b1cfd9): <https://commits.webkit.org/262145@main> Reviewed commits have been landed. Closing PR #10955 and removing active labels.