-
Notifications
You must be signed in to change notification settings - Fork 671
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[css-inline-3] Naming text-box-trim et al. #10675
Comments
To be consistent with margin-trim, I would suggest renaming |
I have concerns about this default behavior. It's an uncommon pattern that might cause issues when defining content with mixed languages. Consider a scenario where we want to define text-edges for headlines or sections with different writing systems, allowing for trim based on another class: <h1 class="ideographic">こんにちは</h1>
<h1 class="alphabetic">Hello</h1> With the proposed default trimming, we would need to explicitly set .ideographic {
text-box-edge: ideographic;
text-box-trim: none;
} The benefit of this default seems very small especially given that trimming can be set directly with the .shorthand {
text-box: trim ideographic;
} I personally would prefer a simple solution where authors wouldn't have to think about such a side effect. |
If you want to set the edges in one rule and the trim with another, you would use the longhands like this:
If you use the shorthand to set the edges (or if you set both the edges and the trim using the longhands as in your example), then whether the trim takes effect will depend on the cascade order of the declarations. Note in this example, the h2 selector has less specificity—it’s important that Shorthands always set all their longhands, and I figure in most cases if you’re specifying the edges you’re wanting to trim to them also, not to reset the trim to none, hence the default to trim. |
|
Yes, margin-trim does not have a
Margin trim example: margin-trim: inline; https://developer.mozilla.org/en-US/docs/Web/CSS/margin-trim |
The proposal looks fine to me, thank you. I'm also fine with either |
@kojiishi Should we change |
The CSS Working Group just discussed
The full IRC log of that discussion<matthieud> fantasai: we took resolution to split text-box-edge<matthieud> fantasai: one for line box sizing, one for triming block container <matthieud> fantasai: we need to discuss some details about the syntax, the names of the properties, names of the values <matthieud> fantasai: there is a new property line-fit-edge which inherits <matthieud> fantasai: and also text-box-edge not inherited initial value auto which compute to the value of the line-fit-edge <matthieud> fantasai: and shorthands for them together <matthieud> fantasai: with a "normal" keyword for the shorthand which compute to "none" and "auto" <astearns> seems OK to me, no better idea for line-fit-edge <matthieud> florian: which part is resolved and which part is your invention ? <matthieud> no resolved name for line-fit-edge, no resolved on the new keyword, no discussion for the shorthand text-box syntax <matthieud> fantasai: no resolved name for line-fit-edge, no resolved on the new keyword, no discussion for the shorthand text-box syntax <chrishtr> Koji from my team reviewed and thought it was fine, so good from Chrome's POV <ntim> lgtm for the whole proposal <matthieud> chrishtr: names of properties are fine <matthieud> chrishtr: line-fit-edge details might need more discussion about behavior <matthieud> Rossen4: we can resolve on the names ? <ntim> I think these are already resolved on <matthieud> RESOLVED: name of properties are text-box-edge and text-box-trim <matthieud> fantasai: the shorthand is text-box but for the values there is a new normal keyword but the rest is weird like text-box-start ... etc <matthieud> fantasai: maybe we should rename some values to add trim-start trim-end trim-both <matthieud> fantasai: would be consistent with text-spacing <matthieud> fantasai: or maybe trim instead of trim-both <matthieud> florian: seems a bit hard to understand how they relate, so in favor of those changes <fantasai> text-box: normal | <'text-box-trim'> || <'text-box-edge'> <fantasai> but text-box: start (e.g.) is pretty weird, so suggest text-box: trim-start <fantasai> Precedent: text-spacing: space-all | normal | space-first | trim-start | trim-both | trim-all <ntim> trim is ambiguous whether it's trim-both or trim-all <matthieud> Rossen4: what is the difference between trim-both and trim-all <matthieud> fantasai: trim-all trim all characters, trim-both only trim only the start edge and end edge <matthieud> florian: the important is that stuff that trim is prefixed by trim-* <matthieud> florian: in the text-box case the difference between both and all doesnt exist so they have the same behavior <matthieud> florian: so "trim" makes sense in the text-box case <matthieud> fantasai: trim and trim-both makes sense, do we want to make the keyword shorter or not <fantasai> s/makes sense/both make sense/ <fantasai> s/or not/or compatible with text-spacing/ <TabAtkins> I think the `trim-*` names sound reasonable, pesonally <fantasai> sure, but between `trim` and `trim-both`? <TabAtkins> Ah, trim-both, if it's less than trim-all <fantasai> OK. But for text-box there's no trim-all in this case, just in text-spacing <TabAtkins> Sure, but consistency is good across the props <fantasai> RESOLVED: Use trim-start and trim-end instead of start and end <fantasai> POLL: text-box: trim; or text-box: trim-both; <ntim> B <astearns> b <kbabbitt> B <florian> 0 (ok either way) <TabAtkins> b <schenney> B <fantasai> (clear property is clear: none | left | right | both) <Rossen4> B <fantasai> 0 <miriam> 0 <ChrisL> abstain <matthieud> 0 <fantasai> kojiishii: A <ntim> We should resolve on the fact the `text-box` exists as a shorthand fwiw <matthieud> RESOLVED: the value "trim-both" for property "text-box" <fantasai> s/text-box/text-box-trim/ <matthieud> fantasai: the initial value of text-box-edge is auto, but text-box-trim is none. What would be the one for text-box ? <florian> +1 to the name and to the normal keyword <astearns> +1 to what florian +1ed <matthieud> PROPOSED RESOLUTION: "text-box" shorthand with value "normal" set the longhands default <ntim> +1 <fantasai> s/What would be the one for text-box ?/That leaves 'text-box: none' or 'text-box: auto' for setting the initial value, and both of these read very weirdly, so I added a normal keyword to the shorthand/ <matthieud> RESOLVED: "text-box" shorthand with value "normal" set the longhands default <fantasai> https://drafts.csswg.org/css-inline-3/#changes <matthieud> fantasai: I will republish the working draft <fantasai> RESOLVED: Republish as WD <matthieud> TabAtkins: don't have anything ready for republication |
https://bugs.webkit.org/show_bug.cgi?id=277970 Reviewed by Antti Koivisto. see w3c/csswg-drafts#10675 (and https://www.w3.org/TR/css-inline-3/#propdef-text-box-trim) * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/inheritance.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-accumulation-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-atomic-inline-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-block-in-inline-end-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-block-in-inline-end-002.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-block-in-inline-end-003.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-block-in-inline-end-004.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-block-in-inline-start-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-block-in-inline-start-002.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-block-in-inline-start-003.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-dynamic-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-dynamic-002.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-end-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-end-empty-line-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-float-clear-br-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-float-clear-br-002.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-float-start-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-half-leading-block-box-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-half-leading-block-box-002.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-half-leading-block-box-003.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-height-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-height-002.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-initial-letter-end-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-initial-letter-start-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-line-clamp-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-multicol-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-multicol-002.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-om-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-ruby-end-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-ruby-start-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-ruby-start-002.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-start-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-tall-line-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-text-emphasis-start-001-expected.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-text-emphasis-start-001-ref.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-text-emphasis-start-001.html: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-valid-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-valid.html: * Source/WebCore/css/CSSPrimitiveValueMappings.h: * Source/WebCore/css/CSSProperties.json: * Source/WebCore/css/SVGCSSValueKeywords.in: * Source/WebCore/layout/formattingContexts/inline/InlineLineBoxBuilder.cpp: (WebCore::Layout::LineBoxBuilder::setVerticalPropertiesForInlineLevelBox const): * Source/WebCore/rendering/RenderBlockFlow.cpp: (WebCore::TextBoxTrimmer::setTextBoxTrimForSubtree): (WebCore::RenderBlockFlow::layoutInFlowChildren): * Source/WebCore/rendering/style/RenderStyleConstants.cpp: (WebCore::operator<<): * Source/WebCore/rendering/style/RenderStyleConstants.h: Canonical link: https://commits.webkit.org/282180@main
This patch renames `text-box-trim` values from: ``` text-box-trim: none | start | end | both ``` to: ``` text-box-trim: none | trim-start | trim-end | trim-both ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-trim There is no functionality changes other than the renaming. Bug: 358204934, 40254880 Change-Id: I5370cac4cfb44d3d4e399cb507e163d3a75a0194
This patch renames `text-box-trim` values from: ``` text-box-trim: none | start | end | both ``` to: ``` text-box-trim: none | trim-start | trim-end | trim-both ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-trim There is no functionality changes other than the renaming. Bug: 358204934, 40254880 Change-Id: I5370cac4cfb44d3d4e399cb507e163d3a75a0194 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5779079 Commit-Queue: Kent Tamura <[email protected]> Auto-Submit: Koji Ishii <[email protected]> Reviewed-by: Kent Tamura <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341342}
This patch renames `text-box-trim` values from: ``` text-box-trim: none | start | end | both ``` to: ``` text-box-trim: none | trim-start | trim-end | trim-both ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-trim There is no functionality changes other than the renaming. Bug: 358204934, 40254880 Change-Id: I5370cac4cfb44d3d4e399cb507e163d3a75a0194 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5779079 Commit-Queue: Kent Tamura <[email protected]> Auto-Submit: Koji Ishii <[email protected]> Reviewed-by: Kent Tamura <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341342}
This patch renames `text-box-trim` values from: ``` text-box-trim: none | start | end | both ``` to: ``` text-box-trim: none | trim-start | trim-end | trim-both ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-trim There is no functionality changes other than the renaming. Bug: 358204934, 40254880 Change-Id: I5370cac4cfb44d3d4e399cb507e163d3a75a0194 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5779079 Commit-Queue: Kent Tamura <[email protected]> Auto-Submit: Koji Ishii <[email protected]> Reviewed-by: Kent Tamura <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341342}
This patch renames `text-box-edge` values from: ``` text-box-edge: leading | <text-edge> ``` to: ``` text-box-edge: auto | <text-edge> ``` Note the `<text-edge>` definition is unchanged. ``` <text-edge> = [ text | cap | ex ] [ text | alphabetic ]? ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-edge As per the new spec, the new `auto` value is identical to `text` when the `line-fit-edge` property is initial. The functionality the `leading` value provided is removed. Bug: 358204934, 40254880 Change-Id: I738058cc79b5525b2cbb151b5765f65363b44e7f
This patch renames `text-box-edge` values from: ``` text-box-edge: leading | <text-edge> ``` to: ``` text-box-edge: auto | <text-edge> ``` Note the `<text-edge>` definition is unchanged. ``` <text-edge> = [ text | cap | ex ] [ text | alphabetic ]? ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-edge As per the new spec, the new `auto` value is identical to `text` when the `line-fit-edge` property is initial. The functionality the `leading` value provided is removed. Bug: 358204934, 40254880 Change-Id: I738058cc79b5525b2cbb151b5765f65363b44e7f
This patch renames `text-box-edge` values from: ``` text-box-edge: leading | <text-edge> ``` to: ``` text-box-edge: auto | <text-edge> ``` Note the `<text-edge>` definition is unchanged. ``` <text-edge> = [ text | cap | ex ] [ text | alphabetic ]? ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-edge As per the new spec, the new `auto` value is identical to `text` when the `line-fit-edge` property is initial. The functionality the `leading` value provided is removed. Bug: 358204934, 40254880 Change-Id: I738058cc79b5525b2cbb151b5765f65363b44e7f Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776349 Reviewed-by: Lingqi Chi <[email protected]> Commit-Queue: Koji Ishii <[email protected]> Reviewed-by: Kent Tamura <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341434}
This patch renames `text-box-edge` values from: ``` text-box-edge: leading | <text-edge> ``` to: ``` text-box-edge: auto | <text-edge> ``` Note the `<text-edge>` definition is unchanged. ``` <text-edge> = [ text | cap | ex ] [ text | alphabetic ]? ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-edge As per the new spec, the new `auto` value is identical to `text` when the `line-fit-edge` property is initial. The functionality the `leading` value provided is removed. Bug: 358204934, 40254880 Change-Id: I738058cc79b5525b2cbb151b5765f65363b44e7f Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776349 Reviewed-by: Lingqi Chi <[email protected]> Commit-Queue: Koji Ishii <[email protected]> Reviewed-by: Kent Tamura <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341434}
This patch renames `text-box-edge` values from: ``` text-box-edge: leading | <text-edge> ``` to: ``` text-box-edge: auto | <text-edge> ``` Note the `<text-edge>` definition is unchanged. ``` <text-edge> = [ text | cap | ex ] [ text | alphabetic ]? ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-edge As per the new spec, the new `auto` value is identical to `text` when the `line-fit-edge` property is initial. The functionality the `leading` value provided is removed. Bug: 358204934, 40254880 Change-Id: I738058cc79b5525b2cbb151b5765f65363b44e7f Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776349 Reviewed-by: Lingqi Chi <[email protected]> Commit-Queue: Koji Ishii <[email protected]> Reviewed-by: Kent Tamura <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341434}
Adding the
|
As per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box Bug: 358204934, 40254880 Change-Id: I641340e92855267627dbed6628b2df50c4608cec Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776351 Reviewed-by: Anders Hartvoll Ruud <[email protected]> Commit-Queue: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341553}
As per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box Bug: 358204934, 40254880 Change-Id: I641340e92855267627dbed6628b2df50c4608cec Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776351 Reviewed-by: Anders Hartvoll Ruud <[email protected]> Commit-Queue: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341553}
As per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box Bug: 358204934, 40254880 Change-Id: I641340e92855267627dbed6628b2df50c4608cec Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776351 Reviewed-by: Anders Hartvoll Ruud <[email protected]> Commit-Queue: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341553}
…alues, a=testonly Automatic update from web-platform-tests [text-box-trim] Rename `text-box-trim` values This patch renames `text-box-trim` values from: ``` text-box-trim: none | start | end | both ``` to: ``` text-box-trim: none | trim-start | trim-end | trim-both ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-trim There is no functionality changes other than the renaming. Bug: 358204934, 40254880 Change-Id: I5370cac4cfb44d3d4e399cb507e163d3a75a0194 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5779079 Commit-Queue: Kent Tamura <[email protected]> Auto-Submit: Koji Ishii <[email protected]> Reviewed-by: Kent Tamura <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341342} -- wpt-commits: 2e6b59c7cb6c5ca476586f5f96840a170697c809 wpt-pr: 47595
…alues, a=testonly Automatic update from web-platform-tests [text-box-trim] Rename `text-box-edge` values This patch renames `text-box-edge` values from: ``` text-box-edge: leading | <text-edge> ``` to: ``` text-box-edge: auto | <text-edge> ``` Note the `<text-edge>` definition is unchanged. ``` <text-edge> = [ text | cap | ex ] [ text | alphabetic ]? ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-edge As per the new spec, the new `auto` value is identical to `text` when the `line-fit-edge` property is initial. The functionality the `leading` value provided is removed. Bug: 358204934, 40254880 Change-Id: I738058cc79b5525b2cbb151b5765f65363b44e7f Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776349 Reviewed-by: Lingqi Chi <[email protected]> Commit-Queue: Koji Ishii <[email protected]> Reviewed-by: Kent Tamura <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341434} -- wpt-commits: 277b9cb6fd5ba4dc0c41afa30410960b38a9fab8 wpt-pr: 47598
…, a=testonly Automatic update from web-platform-tests [text-box-trim] Add `text-box` shorthand As per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box Bug: 358204934, 40254880 Change-Id: I641340e92855267627dbed6628b2df50c4608cec Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776351 Reviewed-by: Anders Hartvoll Ruud <[email protected]> Commit-Queue: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341553} -- wpt-commits: b38816e5fdb12c0e2a7f5c98fe37905a59bbbd0a wpt-pr: 47599
…alues, a=testonly Automatic update from web-platform-tests [text-box-trim] Rename `text-box-trim` values This patch renames `text-box-trim` values from: ``` text-box-trim: none | start | end | both ``` to: ``` text-box-trim: none | trim-start | trim-end | trim-both ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-trim There is no functionality changes other than the renaming. Bug: 358204934, 40254880 Change-Id: I5370cac4cfb44d3d4e399cb507e163d3a75a0194 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5779079 Commit-Queue: Kent Tamura <[email protected]> Auto-Submit: Koji Ishii <[email protected]> Reviewed-by: Kent Tamura <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341342} -- wpt-commits: 2e6b59c7cb6c5ca476586f5f96840a170697c809 wpt-pr: 47595
…alues, a=testonly Automatic update from web-platform-tests [text-box-trim] Rename `text-box-edge` values This patch renames `text-box-edge` values from: ``` text-box-edge: leading | <text-edge> ``` to: ``` text-box-edge: auto | <text-edge> ``` Note the `<text-edge>` definition is unchanged. ``` <text-edge> = [ text | cap | ex ] [ text | alphabetic ]? ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-edge As per the new spec, the new `auto` value is identical to `text` when the `line-fit-edge` property is initial. The functionality the `leading` value provided is removed. Bug: 358204934, 40254880 Change-Id: I738058cc79b5525b2cbb151b5765f65363b44e7f Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776349 Reviewed-by: Lingqi Chi <[email protected]> Commit-Queue: Koji Ishii <[email protected]> Reviewed-by: Kent Tamura <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341434} -- wpt-commits: 277b9cb6fd5ba4dc0c41afa30410960b38a9fab8 wpt-pr: 47598
…, a=testonly Automatic update from web-platform-tests [text-box-trim] Add `text-box` shorthand As per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box Bug: 358204934, 40254880 Change-Id: I641340e92855267627dbed6628b2df50c4608cec Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776351 Reviewed-by: Anders Hartvoll Ruud <[email protected]> Commit-Queue: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341553} -- wpt-commits: b38816e5fdb12c0e2a7f5c98fe37905a59bbbd0a wpt-pr: 47599
@yisibl The behavior of |
This patch renames `text-box-trim` values from: ``` text-box-trim: none | start | end | both ``` to: ``` text-box-trim: none | trim-start | trim-end | trim-both ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-trim There is no functionality changes other than the renaming. Bug: 358204934, 40254880 Change-Id: I5370cac4cfb44d3d4e399cb507e163d3a75a0194 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5779079 Commit-Queue: Kent Tamura <[email protected]> Auto-Submit: Koji Ishii <[email protected]> Reviewed-by: Kent Tamura <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341342}
This patch renames `text-box-edge` values from: ``` text-box-edge: leading | <text-edge> ``` to: ``` text-box-edge: auto | <text-edge> ``` Note the `<text-edge>` definition is unchanged. ``` <text-edge> = [ text | cap | ex ] [ text | alphabetic ]? ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-edge As per the new spec, the new `auto` value is identical to `text` when the `line-fit-edge` property is initial. The functionality the `leading` value provided is removed. Bug: 358204934, 40254880 Change-Id: I738058cc79b5525b2cbb151b5765f65363b44e7f Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776349 Reviewed-by: Lingqi Chi <[email protected]> Commit-Queue: Koji Ishii <[email protected]> Reviewed-by: Kent Tamura <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341434}
As per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box Bug: 358204934, 40254880 Change-Id: I641340e92855267627dbed6628b2df50c4608cec Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776351 Reviewed-by: Anders Hartvoll Ruud <[email protected]> Commit-Queue: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341553}
…alues, a=testonly Automatic update from web-platform-tests [text-box-trim] Rename `text-box-trim` values This patch renames `text-box-trim` values from: ``` text-box-trim: none | start | end | both ``` to: ``` text-box-trim: none | trim-start | trim-end | trim-both ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-trim There is no functionality changes other than the renaming. Bug: 358204934, 40254880 Change-Id: I5370cac4cfb44d3d4e399cb507e163d3a75a0194 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5779079 Commit-Queue: Kent Tamura <[email protected]> Auto-Submit: Koji Ishii <[email protected]> Reviewed-by: Kent Tamura <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341342} -- wpt-commits: 2e6b59c7cb6c5ca476586f5f96840a170697c809 wpt-pr: 47595
…alues, a=testonly Automatic update from web-platform-tests [text-box-trim] Rename `text-box-edge` values This patch renames `text-box-edge` values from: ``` text-box-edge: leading | <text-edge> ``` to: ``` text-box-edge: auto | <text-edge> ``` Note the `<text-edge>` definition is unchanged. ``` <text-edge> = [ text | cap | ex ] [ text | alphabetic ]? ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-edge As per the new spec, the new `auto` value is identical to `text` when the `line-fit-edge` property is initial. The functionality the `leading` value provided is removed. Bug: 358204934, 40254880 Change-Id: I738058cc79b5525b2cbb151b5765f65363b44e7f Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776349 Reviewed-by: Lingqi Chi <[email protected]> Commit-Queue: Koji Ishii <[email protected]> Reviewed-by: Kent Tamura <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341434} -- wpt-commits: 277b9cb6fd5ba4dc0c41afa30410960b38a9fab8 wpt-pr: 47598
…, a=testonly Automatic update from web-platform-tests [text-box-trim] Add `text-box` shorthand As per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box Bug: 358204934, 40254880 Change-Id: I641340e92855267627dbed6628b2df50c4608cec Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776351 Reviewed-by: Anders Hartvoll Ruud <[email protected]> Commit-Queue: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1341553} -- wpt-commits: b38816e5fdb12c0e2a7f5c98fe37905a59bbbd0a wpt-pr: 47599
…alues, a=testonly Automatic update from web-platform-tests [text-box-trim] Rename `text-box-trim` values This patch renames `text-box-trim` values from: ``` text-box-trim: none | start | end | both ``` to: ``` text-box-trim: none | trim-start | trim-end | trim-both ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-trim There is no functionality changes other than the renaming. Bug: 358204934, 40254880 Change-Id: I5370cac4cfb44d3d4e399cb507e163d3a75a0194 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5779079 Commit-Queue: Kent Tamura <tkentchromium.org> Auto-Submit: Koji Ishii <kojiichromium.org> Reviewed-by: Kent Tamura <tkentchromium.org> Cr-Commit-Position: refs/heads/main{#1341342} -- wpt-commits: 2e6b59c7cb6c5ca476586f5f96840a170697c809 wpt-pr: 47595 UltraBlame original commit: b78c67344e4d5b59f7f9d97d6da49f6e9e55579b
…alues, a=testonly Automatic update from web-platform-tests [text-box-trim] Rename `text-box-edge` values This patch renames `text-box-edge` values from: ``` text-box-edge: leading | <text-edge> ``` to: ``` text-box-edge: auto | <text-edge> ``` Note the `<text-edge>` definition is unchanged. ``` <text-edge> = [ text | cap | ex ] [ text | alphabetic ]? ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-edge As per the new spec, the new `auto` value is identical to `text` when the `line-fit-edge` property is initial. The functionality the `leading` value provided is removed. Bug: 358204934, 40254880 Change-Id: I738058cc79b5525b2cbb151b5765f65363b44e7f Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776349 Reviewed-by: Lingqi Chi <lingqichromium.org> Commit-Queue: Koji Ishii <kojiichromium.org> Reviewed-by: Kent Tamura <tkentchromium.org> Cr-Commit-Position: refs/heads/main{#1341434} -- wpt-commits: 277b9cb6fd5ba4dc0c41afa30410960b38a9fab8 wpt-pr: 47598 UltraBlame original commit: a6f222a47421d0eeb256a58b55a6298d1607a93c
…, a=testonly Automatic update from web-platform-tests [text-box-trim] Add `text-box` shorthand As per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box Bug: 358204934, 40254880 Change-Id: I641340e92855267627dbed6628b2df50c4608cec Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776351 Reviewed-by: Anders Hartvoll Ruud <andruudchromium.org> Commit-Queue: Koji Ishii <kojiichromium.org> Cr-Commit-Position: refs/heads/main{#1341553} -- wpt-commits: b38816e5fdb12c0e2a7f5c98fe37905a59bbbd0a wpt-pr: 47599 UltraBlame original commit: 928219d06dfe8f5376cb775f9876f73071887157
…alues, a=testonly Automatic update from web-platform-tests [text-box-trim] Rename `text-box-trim` values This patch renames `text-box-trim` values from: ``` text-box-trim: none | start | end | both ``` to: ``` text-box-trim: none | trim-start | trim-end | trim-both ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-trim There is no functionality changes other than the renaming. Bug: 358204934, 40254880 Change-Id: I5370cac4cfb44d3d4e399cb507e163d3a75a0194 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5779079 Commit-Queue: Kent Tamura <tkentchromium.org> Auto-Submit: Koji Ishii <kojiichromium.org> Reviewed-by: Kent Tamura <tkentchromium.org> Cr-Commit-Position: refs/heads/main{#1341342} -- wpt-commits: 2e6b59c7cb6c5ca476586f5f96840a170697c809 wpt-pr: 47595 UltraBlame original commit: b78c67344e4d5b59f7f9d97d6da49f6e9e55579b
…alues, a=testonly Automatic update from web-platform-tests [text-box-trim] Rename `text-box-edge` values This patch renames `text-box-edge` values from: ``` text-box-edge: leading | <text-edge> ``` to: ``` text-box-edge: auto | <text-edge> ``` Note the `<text-edge>` definition is unchanged. ``` <text-edge> = [ text | cap | ex ] [ text | alphabetic ]? ``` as per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box-edge As per the new spec, the new `auto` value is identical to `text` when the `line-fit-edge` property is initial. The functionality the `leading` value provided is removed. Bug: 358204934, 40254880 Change-Id: I738058cc79b5525b2cbb151b5765f65363b44e7f Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776349 Reviewed-by: Lingqi Chi <lingqichromium.org> Commit-Queue: Koji Ishii <kojiichromium.org> Reviewed-by: Kent Tamura <tkentchromium.org> Cr-Commit-Position: refs/heads/main{#1341434} -- wpt-commits: 277b9cb6fd5ba4dc0c41afa30410960b38a9fab8 wpt-pr: 47598 UltraBlame original commit: a6f222a47421d0eeb256a58b55a6298d1607a93c
…, a=testonly Automatic update from web-platform-tests [text-box-trim] Add `text-box` shorthand As per the resolution at: w3c/csswg-drafts#10675 (comment) and the new spec at: https://drafts.csswg.org/css-inline-3/#propdef-text-box Bug: 358204934, 40254880 Change-Id: I641340e92855267627dbed6628b2df50c4608cec Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5776351 Reviewed-by: Anders Hartvoll Ruud <andruudchromium.org> Commit-Queue: Koji Ishii <kojiichromium.org> Cr-Commit-Position: refs/heads/main{#1341553} -- wpt-commits: b38816e5fdb12c0e2a7f5c98fe37905a59bbbd0a wpt-pr: 47599 UltraBlame original commit: 928219d06dfe8f5376cb775f9876f73071887157
Just landed the edits to split
text-box-edge
into two properties and add a shorthand with text-box-trim in 7869dc6 ; seeWe had left open some amount of syntax bikeshedding to follow up on, so before I publish the Editor's Draft I wanted to run the current state by the CSSWG.
Here's the syntax overview:
Shorthand details:
text-box: normal
sets to initial values (none
/auto
).<text-trim>
defaultstext-box-edge
toauto
(initial value).<text-edges>
defaultstext-box-trim
toboth
(not initial value).Additional details:
text-box-edge: auto
copies fromline-fit-edge
, treatingleading
astext
.line-fit-edge
values other thanleading
opt into the newer line box sizing model (leading only on root inline, honoring margin/border/padding on inline boxes).Consequences:
<text-trim>
value.line-fit-edge
property, that gets passed through as the default trim edges.text-box
shorthand or cascade one independently with thetext-box-edge
longhand.text-box
means that:text-box: both
sets trimming to the default edge on both sides.text-box: cap alphabetic
sets trimming to those edges on both sides.text-box: normal
does the normal thing of not trimming the line box. :)We should rename the trim keywords:
Having the
text-box
shorthand takestart | end | both
reads badly, suggest renaming these keywords totrim-start | trim-end | trim-both
for two reasons:text-spacing-trim
text-box: trim-both
rather thantext-box: both
which is weird.Proposed Resolutions:
text-box
/text-box-trim
/text-box-edge
properties as outlined above.start | end | both
values oftext-box-trim
totrim-start | trim-end | trim-both
.text-line-edge
to contrast withtext-box-edge
) toline-fit-edge
(for now), or to some alternative that people might suggest here.The text was updated successfully, but these errors were encountered: