Loading...
h1 {
text-wrap: balance;
}
p {
text-wrap: balance;
}h1 {
text-wrap: balance;
}
p {
text-wrap: pretty;
}'balance' is meant for short blocks like headings, while 'pretty' avoids a lone last word in paragraphs.
<br> tags.'balance' evens out the length of all lines in a short block. 'pretty' keeps normal wrapping but avoids very short last lines.
It has the same wrapping effect. text-wrap: nowrap sets only text-wrap-mode, while white-space also sets how spaces collapse.
Browsers limit balancing to a small number of lines for performance, so long paragraphs keep normal wrapping.