Page MenuHomePhabricator

Bug 1731541 - Add CSS property text-wrap: auto | stable | balance. r=#style
ClosedPublic

Authored by jfkthame on Sep 6 2023, 10:28 AM.
Referenced Files
Unknown Object (File)
Nov 13 2025, 11:53 AM
Unknown Object (File)
Oct 15 2025, 9:05 PM
Unknown Object (File)
Oct 14 2025, 4:35 PM
Unknown Object (File)
Oct 13 2025, 4:36 PM
Unknown Object (File)
Aug 5 2025, 11:13 PM
Unknown Object (File)
Aug 5 2025, 10:54 AM
Unknown Object (File)
Aug 5 2025, 12:59 AM
Unknown Object (File)
Aug 2 2025, 1:36 AM

Details

Summary

Just the CSS property; not hooked up to any rendering behavior yet.

Currently this is implemented as a simple longhand text-wrap property,
but we'll want to rename it to text-wrap-style when we update white-space
to be a shorthand and introduce white-space-collapse, text-wrap-mode, etc.

The 'pretty' value is omitted as we have no immediate plans to implement it.
Initially, 'auto' and 'stable' will behave identically, although 'auto' could
change in future once we have higher-quality algorithms available.

Event Timeline

phab-bot changed the visibility from "Custom Policy" to "Public (No Login Required)".
phab-bot changed the edit policy from "Custom Policy" to "Restricted Project (Project)".
phab-bot removed a project: secure-revision.
ochameau added a subscriber: ochameau.

(properties db is soon to be removed in D187492)

This revision is now accepted and ready to land.Sep 6 2023, 9:41 PM

(properties db is soon to be removed in D187492)

It's gone now! This patch wants to ditch the devtools/shared/css/generated/properties-db.js changes since that file is now gone \o/

layout/style/nsStyleConsts.h
418–419

note: I just filed bug 1852478 on this shorthand conversion for white-space, if you want to add a mention of the bug number in the code-comment here.

It looks like we don't have a bug for the conversion for text-wrap yet (makes sense since it doesn't exist in our tree until this patch lands). Maybe bug 1758391 should be morphed to become that bug? (If so, you might also reference that bug number here.)

jfkthame edited the summary of this revision. (Show Details)
jfkthame edited the summary of this revision. (Show Details)
jfkthame edited the summary of this revision. (Show Details)

Rebase

jfkthame edited the summary of this revision. (Show Details)
This revision is now accepted and ready to land.Sep 28 2023, 9:13 AM
This revision is now accepted and ready to land.Sep 28 2023, 8:52 PM