Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
[css-align][css-grid] Synthesizing baselines for elements orthogonal to the baseline-axis #1038
The CSS Box Alignment spec states the following:
When applied to actual orthogonal items (orthogonal flow respecting the grid container), the text above matches perfectly to what the CSS Writing Modes spec states about synthesizing baselines:
Well, the CSS Box Alignment spec clarifies that the edges used to synthesize the baseline depend on the formatting context:
Hence, for grid items it seems that under border edge must be used to synthesize elements orthogonal to the baseline-axis (or equivalent, parallel to the alignment context’s axis). As I said, when applied to actual orthogonal boxes this under is resolved as bottom or left depending on the grid item's writing-mode. This makes a lot of sense, so far.
But the spec states that we should treat in the same way parallel elements when they are orthogonal to the baseline-axis. Hence, that would imply that we will have to resolve the under logical direction assuming those elements are "orthogonal" to the grid container, instead of using strictly their writing mode. Is this assumption right ?
Only the row-axis (justify-self) applies as baseline-axis, which determines we must select items which
All items have a block flow direction parallel to the alignment context's axis, hence we must treat them as:
As the CSS Sizing spec states, we must synthesized the items' baseline using their under border edge. If we use the table defined in the CSS Writing Modes spec, we should map under to bottom because the items are horizontal. However, that doesn't make sense because the baseline-axis is the row axis, in this case, the horizontal axis.
So, I assumed that we must treat those items as orthogonal to the grid container, hence vertical, so that we map under to left
I wonder whether my assumption is correct, and in that case, whether it's properly described in the specs.