text-wrap: pretty

Chrome 117, Safari 26.0 (verbesserter Algorithmus); Firefox noch nicht (caniuse bis 158).

Chrome 117Edge 117Safari 26Firefox no

Besserer Absatzumbruch: vermeidet verwaiste Wörter, verbessert die Silbentrennung und gleicht den Flatterrand über den ganzen Absatz aus (Safari bewertet den ganzen Absatz; Chrome die letzten Zeilen). Das Fließtext-Gegenstück zu `balance`.

Pretty wrapping evaluates line breaks across the paragraph to avoid a single stranded word on the final line and to keep the right edge from looking ragged, which is what typographers do by hand.

CSS
.fx-041 {
  text-wrap: pretty;
  max-width: 42ch;
  font-family: Georgia,serif;
  line-height: 1.5;
  hyphens: auto
}
HTML
<p class="fx-041">Pretty wrapping evaluates line breaks across the paragraph to avoid a single stranded word on the final line and to keep the right edge from looking ragged, which is what typographers do by hand.</p>

Fallback: Firefox bricht normal um; harmlos.

Quelle: caniuse.com/mdn-css_properties_text-wrap_pretty and https://webkit.org/blog/17333/webkit-features-in-safari-26-0/

Prompt

Setze `text-wrap: pretty` auf Fließtext, Listenelemente und Beschreibungen (jede mehrzeilige Prosa) und `text-wrap: balance` auf Überschriften. Es kostet nichts, wo es nicht unterstützt wird, also wende es global auf `p, li, dd, blockquote` an.