Skip to main content

Overflow Wrap

Set how words wrap when they overflow their container.

View as Markdown
baselinewidely
ClassCSS
ow:bwoverflow-wrap: break-word;
ow:noverflow-wrap: normal;

Variants

Prefix any class with a variant to apply it only under that condition. Variants stack, as in @md:h:ow:n.

Breakpoints

Apply a class from a viewport width up. Each breakpoint covers its width & every width above it.

@xs:ow:nFrom 32rem up.
@sm:ow:nFrom 40rem up.
@md:ow:nFrom 48rem up.
@lg:ow:nFrom 64rem up.
@xl:ow:nFrom 80rem up.
@xxl:ow:nFrom 96rem up.

Containers

Apply a class from a container's width up, not the viewport's. Mark the parent with ct:is first.

@c:xs:ow:nContainer from 32rem up.
@c:sm:ow:nContainer from 40rem up.
@c:md:ow:nContainer from 48rem up.
@c:lg:ow:nContainer from 64rem up.
@c:xl:ow:nContainer from 80rem up.
@c:xxl:ow:nContainer from 96rem up.

Media

Apply a class when the device or the page matches a condition, or on the first frame an element renders.

@pc:ow:nOn a touch screen.
@prm:ow:nWith reduced motion on.
@st:ow:nOn the first frame.

States

Apply a class only while the element is in a state, such as hovered, focused or checked.

h:ow:nOn :hover.
f:ow:nOn :focus.
fv:ow:nOn :focus-visible.
a:ow:nOn :active.
d:ow:nOn :disabled.
fc:ow:nOn :first-child.
c:ow:nOn :checked.
e:ow:nOn :empty.
fw:ow:nOn :focus-within.
i:ow:nOn :invalid.
in:ow:nOn :indeterminate.
lc:ow:nOn :last-child.
nc:ow:nOn :nth-child.
r:ow:nOn :required.
ro:ow:nOn :read-only.
v:ow:nOn :valid.

Pseudo Elements

Style a part of the element rather than the element itself, such as its placeholder or the selected text.

a::ow:nOn ::after.
b::ow:nOn ::before.
p::ow:nOn ::placeholder.
s::ow:nOn ::selection.