Skip to main content

Align Content

Set row alignment in multi-row Flex & Grid containers.

View as Markdown
baselinewidely
ClassCSS
ac:balign-content: baseline;
ac:calign-content: center;
ac:fealign-content: flex-end;
ac:fsalign-content: flex-start;
ac:nalign-content: normal;
ac:salign-content: stretch;
ac:saalign-content: space-around;
ac:sbalign-content: space-between;
ac:sealign-content: space-evenly;

Variants

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

Breakpoints

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

@xs:ac:nFrom 32rem up.
@sm:ac:nFrom 40rem up.
@md:ac:nFrom 48rem up.
@lg:ac:nFrom 64rem up.
@xl:ac:nFrom 80rem up.
@xxl:ac: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:ac:nContainer from 32rem up.
@c:sm:ac:nContainer from 40rem up.
@c:md:ac:nContainer from 48rem up.
@c:lg:ac:nContainer from 64rem up.
@c:xl:ac:nContainer from 80rem up.
@c:xxl:ac: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:ac:nOn a touch screen.
@prm:ac:nWith reduced motion on.
@st:ac:nOn the first frame.

States

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

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

Pseudo Elements

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

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