Default Cluster
Items line up horizontally and wrap when the container runs out of space.
<div class="wf-cluster">
<div>Item 1</div>
<div>Item 2</div>
<div>Item 3</div>
</div>
wf-cluster is a horizontal grouping primitive built on flex wrap. Items sit side by side and wrap to the next line when there is no more room — no media queries needed. Gap, alignment, and justification are all controlled with modifier classes.
Items line up horizontally and wrap when the container runs out of space.
<div class="wf-cluster">
<div>Item 1</div>
<div>Item 2</div>
<div>Item 3</div>
</div>
Combine any wf-gap-* modifier with wf-cluster to tune density per layout block.
wf-gap-2
wf-gap-5
wf-gap-xl
<div class="wf-cluster wf-gap-2">...</div>
<div class="wf-cluster wf-gap-5">...</div>
<div class="wf-cluster wf-gap-xl">...</div>
Children align to the top of the row.
<div class="wf-cluster wf-items-start">...</div>
Children align to the vertical midpoint — the default cluster behavior.
<div class="wf-cluster wf-items-center">...</div>
Children align to the bottom of the row.
<div class="wf-cluster wf-items-end">...</div>
Aligns children by their text baseline — useful when mixing font sizes.
<div class="wf-cluster wf-items-baseline">...</div>
Items pack toward the start of the row.
<div class="wf-cluster wf-justify-start">...</div>
Items center along the row.
<div class="wf-cluster wf-justify-center">...</div>
Free space is distributed between items — first and last items sit at the edges.
<div class="wf-cluster wf-justify-between">...</div>
Items pack toward the end of the row.
<div class="wf-cluster wf-justify-end">...</div>
Apply wf-self-* to a single child to override the cluster's cross-axis alignment for that item only.
<div class="wf-cluster wf-items-center">
<div class="wf-self-start">self-start</div>
<div>center (default)</div>
<div class="wf-self-end">self-end</div>
<div class="wf-self-stretch">self-stretch</div>
</div>
All modifier classes available on .wf-cluster
| Class Name | Type | Description |
|---|---|---|
| wf-cluster | Base | Flex wrap container. Items align center by default with --wf-space-4 gap. |
| wf-gap-1 … wf-gap-8 | Spacing | Numeric gap scale between items. |
| wf-gap-3xs … wf-gap-5xl | Spacing | Semantic gap scale between items. |
| wf-items-start / -center / -end / -stretch / -baseline | Alignment | Cross-axis alignment for all children. |
| wf-justify-start / -center / -end / -between / -around | Justification | Main-axis distribution of children. |
| wf-self-start / -center / -end / -stretch / -baseline | Self | Overrides cross-axis alignment for a single child item. |