Implement flex-wrap: balance and flex-line-count (CSS Flexbox Level 2, Servo-only) - #1
Open
nicoburns wants to merge 1 commit into
Open
Implement flex-wrap: balance and flex-line-count (CSS Flexbox Level 2, Servo-only)#1nicoburns wants to merge 1 commit into
flex-wrap: balance and flex-line-count (CSS Flexbox Level 2, Servo-only)#1nicoburns wants to merge 1 commit into
Conversation
🤖 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:
|
staging-devin-ai-integration
Bot
force-pushed
the
devin/1786716636-flex-wrap-balance
branch
from
August 14, 2026 14:13
c303a93 to
afd4730
Compare
nicoburns
force-pushed
the
devin/1786716636-flex-wrap-balance
branch
2 times, most recently
from
August 14, 2026 15:18
1a89e79 to
5d66fdc
Compare
…sing (Servo-only) (r?#style) Differential Revision: https://phabricator.services.mozilla.com/D318746
nicoburns
force-pushed
the
devin/1786716636-flex-wrap-balance
branch
from
August 14, 2026 15:53
e465760 to
f15dc59
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.
Summary
Port of DioxusLabs/stylo#12 to the Firefox tree (
servo/components/style). Servo-engine-only, gated behindlayout.flexbox.balance(always false on Gecko builds):flex-wrapswitches from a generated keyword property to a customspecified::FlexWraptype (also the computed value) parsing the Level 2 grammarnowrap | [ wrap | wrap-reverse ] || balance:wrap balance/balance wrap/ barebalance→Balance;wrap-reverse balance→WrapReverseBalance;nowrap balancerejected. Serializes to canonicalbalance/wrap-reverse balance. TheBalance*variants are#[cfg(feature = "servo")], and thebalancekeyword only parses whenstatic_prefs::pref!("layout.flexbox.balance")is true (that pref lookup is also servo-cfg'd, so Gecko never references a nonexistent pref).flex-line-countlonghand (positive<integer>, initial1),engine = "servo"withservo_pref = "layout.flexbox.balance"— not generated at all for Gecko.gecko.mako.rsgains manualset/copy/reset/clone_flex_wrapmapping tostructs::StyleFlexWrap(balance variants are unreachable on Gecko builds).Differences from the DioxusLabs/stylo PR: the
stylo_static_prefs/preferences.tomlhunk (adding"layout.flexbox.balance" = false) has no equivalent here — that crate only exists in the standalone Stylo repo; in this treestatic_prefsis Gecko'smodules/libprefcrate and the pref reference is servo-cfg'd out for Gecko. Everything else applied cleanly with only thestyle/→servo/components/style/path change.Verification: ran
properties/build.pyfor bothgeckoandservoproducts — both generate successfully; the gecko output contains noflex_line_countand uses the manualflex_wrapglue, the servo output contains the new longhand. Did not run./mach buildper instructions; the Servo cfg paths are not compiled in this tree.Link to Devin session: https://dioxus.staging.devinenterprise.com/sessions/53c65c43aed94d578c1203fdc9994176
Requested by: @nicoburns