You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Values other than ''justify-self/stretch'' cause <a href="http://www.w3.org/TR/CSS21/visudet.html#abs-non-replaced-width">non-replaced absolutely-positioned boxes</a>
829
-
to use shrink-to-fit sizing for calculating ''width/auto'' measures.
845
+
<table class="data align-details">
846
+
<tr>
847
+
<th>'justify-self' Axis
848
+
<td>
849
+
The block’s containing block’s <a>inline axis</a>.
850
+
<tr>
851
+
<th><a>Alignment Container</a>
852
+
<td>
853
+
The box's containing block,
854
+
as modified by the offset properties ('top'/'right'/'bottom'/'left').
855
+
<tr>
856
+
<th><a>Alignment Subject</a>
857
+
<td>
858
+
The box's margin box.
859
+
<tr>
860
+
<th>''justify-self/normal'' Behavior
861
+
<td>
862
+
Consistent with CSS2.1,
863
+
the ''justify-self/normal'' keyword behaves as ''start'' on replaced absolutely-positioned boxes,
864
+
and behaves as ''justify-self/stretch'' on all other absolutely-positioned boxes.
865
+
<tr>
866
+
<th>Other Details
867
+
<td>
868
+
In terms of CSS2.1 formatting [[!CSS21]],
869
+
the rules for “over-constrained” computations in <a href="http://www.w3.org/TR/CSS21/visudet.html#abs-non-replaced-width">section 10.3.7</a>
870
+
are ignored in favor of alignment as specified here,
871
+
and the used value of the offset properties are not adjusted to correct for the over-constraint.
830
872
831
-
The <a>alignment container</a> is the box's containing block
832
-
as modified by the offset properties ('top'/'right'/'bottom'/'left').
833
-
The <a>alignment subject</a> is the box's margin box.
873
+
Values other than ''justify-self/stretch'' cause <a href="http://www.w3.org/TR/CSS21/visudet.html#abs-non-replaced-width">non-replaced absolutely-positioned boxes</a>
874
+
to use <a>fit-content sizing</a> for calculating ''width/auto'' inline sizes.
834
875
835
-
In terms of CSS2.1 formatting [[!CSS21]],
836
-
the rules for "over-constrained" computations in <a href="http://www.w3.org/TR/CSS21/visudet.html#abs-non-replaced-width">section 10.3.7</a>
837
-
are ignored in favor of alignment as specified here
838
-
and the used value of the offset properties are not adjusted to correct for the over-constraint.
876
+
Note that ''justify-self/stretch'' does cause replaced absolutely-positioned elements to fill their containing block
877
+
just as non-replaced ones do.
839
878
879
+
If either offset property in this dimension is ''top/auto'',
880
+
'justify-self' has no effect.
881
+
</table>
840
882
841
-
<dt>Table Cells:
842
-
<dd>
843
-
This property does not apply to table cells,
844
-
because their position and size is fully constrained by table layout.
883
+
### Table Cells ### {#justify-self}
845
884
846
-
<dt>Flex Items:
847
-
<dd>
848
-
This property does not apply to <a>flex items</a>,
849
-
because there is more than one item in the <a>main axis</a>.
850
-
See 'flex' for stretching and 'justify-content' for <a>main-axis</a> alignment. [[!CSS3-FLEXBOX]]
885
+
This property does not apply to table cells,
886
+
because their position and size is fully constrained by table layout.
851
887
852
-
<dt>Grid Items:
853
-
<dd>
854
-
The 'justify-self' property applies along the grid's <a>row axis</a>.
888
+
### Flex Items ### {#justify-flex}
855
889
856
-
The <a>alignment container</a> is the <a>grid area</a>.
857
-
The <a>alignment subject</a> is the <a>grid item</a>’s margin box.
890
+
This property does not apply to <a>flex items</a>,
891
+
because there is more than one item in the <a>main axis</a>.
892
+
See 'flex' for stretching and 'justify-content' for <a>main-axis</a> alignment. [[!CSS-FLEXBOX-1]]
858
893
859
-
''justify-self/normal'' behaves as ''justify-self/stretch''.
860
-
</dl>
894
+
### Grid Items ### {#justify-grid}
861
895
862
-
<div class="example">
863
-
The effect of these rules is that an auto-sized block-level table,
864
-
for example, can be aligned while still having side margins.
865
-
If the table's max-content size is narrower than its containing block,
866
-
then it is shrink-wrapped to that size and aligned as specified.
867
-
If the table's max-content size is wider, then it fills its containing block,
868
-
and the margins provide appropriate spacing from the containing block edges.
869
-
</div>
896
+
<table class="data align-details">
897
+
<tr>
898
+
<th>'justify-self' Axis
899
+
<td>
900
+
The grid’s <a>row axis</a>.
901
+
<tr>
902
+
<th><a>Alignment Container</a>
903
+
<td>
904
+
The <a>grid area</a>.
905
+
<tr>
906
+
<th><a>Alignment Subject</a>
907
+
<td>
908
+
The <a>grid item’s</a> margin box.
909
+
<tr>
910
+
<th>''justify-self/normal'' Behavior
911
+
<td>
912
+
Behaves as ''justify-self/stretch''.
913
+
</table>
870
914
871
915
<h3 id='align-self-property'>
872
916
Block/Cross-Axis Alignment: the 'align-self' property</h3>
0 commit comments