11 KiB
| title | chunk | source | category | tags | date_saved | instance |
|---|---|---|---|---|---|---|
| Alignment subject - Glossary | MDN | 1/3 | https://developer.mozilla.org/en-US/docs/Glossary/Alignment_Subject | reference | web, html, css, javascript, documentation | 2026-05-05T05:24:12.904768+00:00 | kb-cron |
MDN HTML HTML: Markup language
HTML reference
HTML guides
Markup languages
CSS reference
CSS guides
Layout cookbook
JavaScriptJS JavaScript: Scripting language
JS reference
JS guides
Web APIs Web APIs: Programming interfaces
Web API reference
Web API guides
- Using the Web animation API
- Using the Fetch API
- Working with the History API
- Using the Web speech API
- Using web workers
Technologies
Topics
Learn Learn web development
Frontend developer course
- Getting started modules
- Core modules
- MDN Curriculum
- Check out the video course from Scrimba, our partner
Learn HTML
Learn CSS
Learn JavaScript
Tools Discover our tools
About Get to know MDN better
Alignment subject
In CSS box alignment the alignment subject is the thing (or things) being aligned within the alignment container by the property.
For justify-self and align-self, the alignment subject is the margin box of the box the property is set on, using the writing mode of that box. For justify-content and align-content, the writing mode of the box is also used.
The definition of the alignment subject depends on the layout mode being used.
Block containers (including table cells)
The entire content of the block as a single unit.
The column boxes, with any spacing inserted between column boxes added to the relevant column gaps.
For justify-content, the flex items in each flex line. For align-content, the flex lines. Note, this only has an effect on multi-line flex containers.
The grid tracks in the appropriate axis, with any spacing inserted between tracks added to the relevant gutters. Collapsed gutters are treated as a single opportunity for space insertion.
In this article
See also
- CSS box alignment module
- Related glossary terms: