word-break

Class Description

break-normal

Uses the default word break and overflow wrap rules.

CSS Rules

.break-normal {
  overflow-wrap: normal;
  word-break: normal;
}

Usage

<element class="break-normal" />

Responsive

Prefix .break-normal utility with a breakpoint variant (e.g., md:) to apply styles at specific screen sizes (Supported breakpoints are xm through 2xl).

<element class="md:break-normal" />

States

States are generated dynamically at runtime and always come last. Append a state like :hover or :focus to the end of the class. This works in conjunction with breakpoints .

Supported pseudo-classes: :hover, :active, :focus, :focus-visible, :focus-within, :target, :checked, :disabled, and :group-hover.

<element class="break-normal:hover" />

Group Hover Example

The :group-hover state applies styles when a parent element with the .group class is hovered.

<element class="group">
  <element class="break-normal:group-hover">...</element>
</element>

Pseudo-Elements

The ::before and ::after utility classes are supported too. Granted that you add the mandatory content-before or content-after class in order for them to work.

<element class="content-before break-normal::before" />

<element class="content-after break-normal::after" />
.break-normal Uses the default word break and overflow wrap rules.

break-words

Sets overflow-wrap: break-word. Breaks long words to prevent overflow.

CSS Rules

.break-words {
  overflow-wrap: break-word;
}

Usage

<element class="break-words" />

Responsive

Prefix .break-words utility with a breakpoint variant (e.g., md:) to apply styles at specific screen sizes (Supported breakpoints are xm through 2xl).

<element class="md:break-words" />

States

States are generated dynamically at runtime and always come last. Append a state like :hover or :focus to the end of the class. This works in conjunction with breakpoints .

Supported pseudo-classes: :hover, :active, :focus, :focus-visible, :focus-within, :target, :checked, :disabled, and :group-hover.

<element class="break-words:hover" />

Group Hover Example

The :group-hover state applies styles when a parent element with the .group class is hovered.

<element class="group">
  <element class="break-words:group-hover">...</element>
</element>

Pseudo-Elements

The ::before and ::after utility classes are supported too. Granted that you add the mandatory content-before or content-after class in order for them to work.

<element class="content-before break-words::before" />

<element class="content-after break-words::after" />
.break-words Sets overflow-wrap: break-word. Breaks long words to prevent overflow.

break-all

Sets word-break: break-all. Breaks words at any character.

CSS Rules

.break-all {
  word-break: break-all;
}

Usage

<element class="break-all" />

Responsive

Prefix .break-all utility with a breakpoint variant (e.g., md:) to apply styles at specific screen sizes (Supported breakpoints are xm through 2xl).

<element class="md:break-all" />

States

States are generated dynamically at runtime and always come last. Append a state like :hover or :focus to the end of the class. This works in conjunction with breakpoints .

Supported pseudo-classes: :hover, :active, :focus, :focus-visible, :focus-within, :target, :checked, :disabled, and :group-hover.

<element class="break-all:hover" />

Group Hover Example

The :group-hover state applies styles when a parent element with the .group class is hovered.

<element class="group">
  <element class="break-all:group-hover">...</element>
</element>

Pseudo-Elements

The ::before and ::after utility classes are supported too. Granted that you add the mandatory content-before or content-after class in order for them to work.

<element class="content-before break-all::before" />

<element class="content-after break-all::after" />
.break-all Sets word-break: break-all. Breaks words at any character.

break-keep

Prevents breaking within words, typically used for CJK text.

CSS Rules

.break-keep {
  word-break: keep-all;
}

Usage

<element class="break-keep" />

Responsive

Prefix .break-keep utility with a breakpoint variant (e.g., md:) to apply styles at specific screen sizes (Supported breakpoints are xm through 2xl).

<element class="md:break-keep" />

States

States are generated dynamically at runtime and always come last. Append a state like :hover or :focus to the end of the class. This works in conjunction with breakpoints .

Supported pseudo-classes: :hover, :active, :focus, :focus-visible, :focus-within, :target, :checked, :disabled, and :group-hover.

<element class="break-keep:hover" />

Group Hover Example

The :group-hover state applies styles when a parent element with the .group class is hovered.

<element class="group">
  <element class="break-keep:group-hover">...</element>
</element>

Pseudo-Elements

The ::before and ::after utility classes are supported too. Granted that you add the mandatory content-before or content-after class in order for them to work.

<element class="content-before break-keep::before" />

<element class="content-after break-keep::after" />
.break-keep Prevents breaking within words, typically used for CJK text.