Skip to content

Commit 75b452d

Browse files
committed
feat: add class text-balanced
Refs: twbs#41389
1 parent 06f4e79 commit 75b452d

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

scss/_utilities.scss

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -565,6 +565,11 @@ $utilities: map-merge(
565565
nowrap: nowrap,
566566
)
567567
),
568+
"text-wrap": (
569+
property: text-wrap,
570+
class: text,
571+
values: (balanced: balance)
572+
),
568573
"word-wrap": (
569574
property: word-wrap word-break,
570575
class: text,

site/src/content/docs/utilities/text.mdx

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,12 @@ Change the line height with `.lh-*` utilities.
9292
<p class="lh-base">This is a long paragraph written to show how the line-height of an element is affected by our utilities. Classes are applied to the element itself or sometimes the parent element. These classes can be customized as needed with our utility API.</p>
9393
<p class="lh-lg">This is a long paragraph written to show how the line-height of an element is affected by our utilities. Classes are applied to the element itself or sometimes the parent element. These classes can be customized as needed with our utility API.</p>`} />
9494

95+
## Balanced Text
96+
97+
Use the `.text-balanced` class to balance text.
98+
99+
<Example code={`<p class="text-balanced">his is a long paragraph written to show how the line-height of an element is affected by our utilities. Classes are applied to the element itself or sometimes the parent element. These classes can be customized as needed with our utility API.</p>`} />
100+
95101
## Monospace
96102

97103
Change a selection to our monospace font stack with `.font-monospace`.

0 commit comments

Comments
 (0)