#822: text-wrap: balance

Visit on Github.

Opened Feb 28, 2023

Hello TAG!

I'm requesting a TAG review of the text-wrap: balance CSS property.

This feature adjusts line breaking to balance the length of each line box in a block, for better readability and to prevent typographic widows. This feature is often used in headlines.

There are several JavaScript libraries to achieve this effect, such as NYTimes text balancer, React Wrap Balancer, or Adobe Balance Text.

Jen's tweet has a sample image, and it got a lot of positive responses from web developers.

  • Explainer¹ (minimally containing user needs and example code): url
  • Specification URL: spec url
  • Tests: wpt folder(s), if available
  • User research: [url to public summary/results of research]
  • Security and Privacy self-review²: [url]
  • GitHub repo (if you prefer feedback filed there): [url]
  • Primary contacts (and their relationship to the specification):
    • @kojiishi (Implementer), @bfgeek (Implementer), @fantasai (Spec Editor)
  • Organization(s)/project(s) driving the specification: Google
  • Key pieces of existing multi-stakeholder review or discussion of this specification:
  • External status/issue trackers for this specification (publicly visible, e.g. Chrome Status): https://chromestatus.com/feature/5196960707903488

Further details:

  • I have reviewed the TAG's Web Platform Design Principles
  • Relevant time constraints or deadlines: Implementation complete.
  • The group where the work on this specification is currently being done: CSSWG
  • The group where standardization of this work is intended to be done (if current group is a community group or other incubation venue): CSSWG
  • Major unresolved issues with or opposition to this specification:
  • This work is being funded by: Blink implementation is being done by Google.

💬 leave review feedback as a comment in this issue and @-notify [github usernames]

Discussions

2023-03-13

Minutes

Lea: process should be if there's no objection in channel - rather... People should be more active on slack...

Lea: things should not be accepted and closed summarilly without people looking at it.

Lea: a lot of excitement in the open community about this.

we leave to async process to close

Hi - just a quick request hopefully - we noticed that the explainer is a google doc, not in a markdown next to the spec.  There doesn't appear to be an answer to the security & privacy questionnaire. The chrome status also doesn't reflect the reality as shown by the web platform tests info. We recognise that this is already in the spec and there's significant developer support but can you please update the request info so we can progress?

Dan: leaves comment

2023-03-20

Minutes

Tess: I think we can close it. They've thought about the issue.. Algorithmic complexity... 10 or more lines...

Peter: just for screen?

Tess: in most browsers the user experience of print styles being different from screen styles confuses people.. it's worth raising...

Rossen: what's the printing point?

Tess: if you're printing the UA can...

agreed to close with satisified