Skip to content

Conversation

@jdm
Copy link
Member

@jdm jdm commented Oct 29, 2025

We were not following the specification for computing the values of the content rect. Additionally, any non-content-box observer would get confused because we never stored the correct size, leading to infinite notifications when the latest size didn't match the last observed size.

Testing: Various tests now pass.
Fixes: #32549
Fixes: #40107

@servo-highfive servo-highfive added the S-awaiting-review There is new code that needs to be reviewed. label Oct 29, 2025
Copy link
Member

@mrobinson mrobinson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a few comments...

@jdm jdm requested a review from mrobinson October 30, 2025 07:51
@servo-highfive servo-highfive added S-needs-rebase There are merge conflict errors. and removed S-awaiting-review There is new code that needs to be reviewed. labels Oct 30, 2025
jdm added 6 commits October 30, 2025 14:33
…puting content rect.

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
… box.

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
Signed-off-by: Josh Matthews <josh@joshmatthews.net>
Signed-off-by: Josh Matthews <josh@joshmatthews.net>
Signed-off-by: Josh Matthews <josh@joshmatthews.net>
Signed-off-by: Josh Matthews <josh@joshmatthews.net>
@jdm jdm force-pushed the resize-observer-padding branch from ec14234 to 1921aef Compare October 30, 2025 18:35
@servo-highfive servo-highfive added S-awaiting-review There is new code that needs to be reviewed. and removed S-needs-rebase There are merge conflict errors. labels Oct 30, 2025
@jdm jdm enabled auto-merge October 30, 2025 18:35
Signed-off-by: Josh Matthews <josh@joshmatthews.net>
@jdm jdm added this pull request to the merge queue Oct 31, 2025
@servo-highfive servo-highfive added the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Oct 31, 2025
Merged via the queue into servo:main with commit b3868c2 Oct 31, 2025
32 checks passed
@jdm jdm deleted the resize-observer-padding branch October 31, 2025 19:10
@servo-highfive servo-highfive removed the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Oct 31, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-awaiting-review There is new code that needs to be reviewed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ResizeObserver.contentRect needs to adjust for non-SVG elements Fix DOMRect calc in ResizeObserverEntry

4 participants