CSS UtilitiesCluster

Cluster

A cluster arranges its children inline with even spacing and wraps them onto a new line whenever the container runs out of room. Reach for it whenever you have a horizontal group of items of varying widths, like tag lists, button rows, inline metadata, or breadcrumb-style trails, and want the layout to stay tidy on every screen size without writing any media queries.

By default, cluster children are centered vertically. Pair cs-cluster with a cs-gap-* class to change the spacing and a cs-align-items-* class to change how items align on the cross axis.

Examples

Clusters are great for inline lists and aligning items of varying sizes.

Withywindle Pub and Eatery

4.6 (419 reviews)
• Comfort Food Gastropub Cocktail Bar Vegetarian Gluten Free

Align Items

By default, items are centered in the block direction of the cs-cluster container. Add any cs-align-items-* class to change how items line up in the block direction.

Gap

By default, the gap between cluster items uses --cs-space-m from your theme. Add any cs-gap-* class to change the spacing between items.