Repository navigation
layout: Fixes for the percentage height quirk - #64322
Merged
servo-wpt-sync merged 1 commit intoNov 4, 2026
Merged
Conversation
wpt-pr-bot
approved these changes
Oct 28, 2026
wpt-pr-bot
left a comment
Collaborator
There was a problem hiding this comment.
The review process for this patch is being conducted in the Servo project.
servo-wpt-sync
force-pushed
the
servo_export_49366
branch
2 times, most recently
from
November 4, 2026 01:02
fb00902 to
414017a
Compare
This implements 4 changes: - Restricts the quirk to elements that have a percentage in `height`. E.g. `100%` won't be quirky in `height: auto; min-height: 100%`, but it will in `height: 0%; min-height: 100%`. This matches the spec and Gecko, though Blink and WebKit only enforce it on replaced elements. - More concretely, it requires a `<percentage>`, as opposed to a `<length-percentage>` containing a percentage. E.g. `calc(100% + 1px)` won't be quirky, but `100%`, `calc(100%)` and `calc(100% + 0px)` will. This matches the spec and Gecko, but not Blink and WebKit. - Restricts the quirk to percentage resolution. E.g. `height: stretch` won't be quirky. This matches Blink, the spec is unclear. - Restricts the quirk to sizing purposes. E.g. `top: 100%` won't be quirky. This matches the spec, Blink and WebKit, but not Gecko. Signed-off-by: Oriol Brufau <[email protected]>
servo-wpt-sync
force-pushed
the
servo_export_49366
branch
from
November 4, 2026 01:17
414017a to
a70384a
Compare
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.
This implements 4 changes:
height. E.g.100%won't be quirky inheight: auto; min-height: 100%, but it will inheight: 0%; min-height: 100%. This matches the spec and Gecko, though Blink and WebKit only enforce it on replaced elements.How does height percentage quirk affect min/max-height? whatwg/quirks#95
<percentage>, as opposed to a<length-percentage>containing a percentage. E.g.calc(100% + 1px)won't be quirky, but100%,calc(100%)andcalc(100% + 0px)will. This matches the spec and Gecko, but not Blink and WebKit.Should we do percentage height quirk for calc()? whatwg/quirks#48
height: stretchwon't be quirky. This matches Blink, the spec is unclear.[css-sizing][quirks] Should
stretchbe affected by percentage height calculation quirk? w3c/csswg-drafts#12421top: 100%won't be quirky. This matches the spec, Blink and WebKit, but not Gecko.Percentage height quirk doesn't affect relpos positioning, right? whatwg/quirks#94
Testing: 2 existing tests improve, also adding new tests
Fixes: #49025
Reviewed in servo/servo#49366