CSS: justify-self (grid)

By Xah Lee. Date: .
xtodo

ai answer

The CSS justify-self property aligns an individual element within its alignment container along the inline axis (horizontal in left-to-right languages). It is primarily used in CSS Grid layouts but also applies to block and absolutely positioned elements; it is ignored in Flexbox.

This property allows a single item to override the parent container’s justify-items setting. Key values include:

Unlike justify-items (which sets the default for all children) or justify-content (which aligns the entire grid within the container), justify-self targets only the specific element it is applied to.

CSS grid layout