[css-inline-3] Clarification on text-box-trim propagation and independent block formatting contexts
Nobody has claimed this yet.
- Dominant language
- Bikeshed
- Stars
- 4.9k
- Forks
- 816
- PR merge metrics
- PR metrics pending
Description
There was a related issue at https://github.com/w3c/csswg-drafts/issues/11038 but I couldn't quite identift whether this specific question about text-box-trim was resolved.
CSS Inline 3 says the below regarding text-box-trim, which doesn't seem to include specific behavior for independent BFCs. I don't see anything else about propagation in this property definition (other than column containers).
Note: Like ::first-line, this property does not apply to, or propagate through, flex, grid, or table formatting contexts.
CSS Pseudo 4 does say the following about the first formatted line, though.
Note: The first line of a block container that does not itself participate in a block formatting context cannot be the first formatted line of an ancestor element.
I'm not 100% sure, but I think the "does not itself participate in a block formatting context" is synonymous with "establishes an independent block formatting context"? Does this definition mean that text-box-trim does not propagate through independent BFCs?
That's my interpretation, but there's an existing WPT that asserts the opposite - new-fc-001.html passes if text-box-trim does propagate to an independent BFC (a display: flow-root in this case). Blink passes that, Gecko and WebKit do not. I was going to add additional tests to assert that propagation doesn't happen with other BFC-establishing children, but this existing WPT has me a bit perplexed.
(Tracking this on the Gecko side at https://bugzilla.mozilla.org/show_bug.cgi?id=2049484)
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Read the CSS Inline 3 text-box-trim definition and the CSS Pseudo 4 first-formatted-line wording, then compare them with the related issue 11038. Run or inspect the WPT case css/css-inline/text-box-trim/new-fc-001.html and review the linked Gecko bug. Done means the propagation behavior for independent BFCs is resolved in the specification and the test expectation is aligned.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- css
- Domain
- documentation, testing
- Issue type
- Documentation
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100