Fix spurious ~34px horizontal scroll on csskit.rs (bump taffy) - #727
Merged
Merged
Conversation
Bump taffy to pick up the fix that only includes a container's own end-side padding in its content_size when the container is a scroll container. Ordinary padded boxes no longer propagate spurious overflow to the viewport (e.g. the ~34px horizontal scroll on csskit.rs). Also adapt to taffy's LayoutOutput::baselines API rename.
Contributor
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
This was referenced Aug 16, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
https://csskit.rs showed a spurious ~34px horizontal scroll at a 1200px viewport. Root cause: taffy's block/grid (and flexbox) algorithms unconditionally added a container's own end-side padding to its
content_size, even for boxes that are not scroll containers. The page'sfooter(a padded block whose child<p>has negative horizontal margins pulling it into the padding) reportedcontent_size.width = 1234, which propagated to the root and made the document scrollable (scroll_width = 34).Fixed upstream in DioxusLabs/taffy#1114: end-side padding is now only included in
content_sizewhen the container is a scroll container, matching browser scrollable-overflow semantics. This PR bumps the taffy rev to pick that up (the pinned rev is the fix commit on the PR branch; can be re-pinned once the taffy PR merges), and adapts to taffy'sLayoutOutput::first_baselines→baselines: Baselinesrename that landed on taffy main in between:Verified with the screenshot example: the csskit.rs root goes from
content_size=1234x3246, scroll_width=34tocontent_size=1200x3246, scroll_width=0, with rendering unchanged.cargo test --workspace, clippy and fmt pass.Link to Devin session: https://dioxus.staging.devinenterprise.com/sessions/b6f5529e9a3e4823b603788b475ab109
Requested by: @nicoburns
WPT results
No changes in test results compared to
main.Generated by the WPT workflow.