Skip to content

Commit 015de42

Browse files
alkorlostabatkins
andauthored
[css-align-3] Example 3 changing the order of images to match the text (#10598)
* [css-align-3] example 3 changing the order of images to match the text * [css-align-3] Fix broken link * Revert "[css-align-3] Fix broken link" This reverts commit 5a574ff. * Rewrite slightly Fixed a missing word, and rearranged the text a bit to avoid a huge (italicized, centered) caption. --------- Co-authored-by: Tab Atkins Jr. <jackalmage@gmail.com>
1 parent 9a60a07 commit 015de42

File tree

1 file changed

+22
-16
lines changed

1 file changed

+22
-16
lines changed

css-align-3/Overview.bs

+22-16
Original file line numberDiff line numberDiff line change
@@ -812,36 +812,42 @@ Overflow Alignment: the ''safe'' and ''unsafe'' keywords and scroll safety limit
812812
}
813813
</style>
814814
<div style="display:table; margin: 0 auto 1em;">
815-
<div style="display:table-cell; padding-right: 50px;" class='cross-auto-figure'>
815+
<div style="display:table-cell; padding-right: 70px;" class='cross-auto-figure'>
816816
<div>
817817
<div>About</div>
818-
<div style="white-space: nowrap; margin-left: -31px;">Authoritarianism</div>
818+
<div style="white-space: nowrap;">Authoritarianism</div>
819819
<div>Blog</div>
820820
</div>
821821
</div>
822-
<div style="display:table-cell; padding-left: 50px;" class='cross-auto-figure'>
822+
<div style="display:table-cell; padding-left: 70px;" class='cross-auto-figure'>
823823
<div>
824824
<div>About</div>
825-
<div style="white-space: nowrap;">Authoritarianism</div>
825+
<div style="white-space: nowrap; margin-left: -31px;">Authoritarianism</div>
826826
<div>Blog</div>
827827
</div>
828828
</div>
829829
</div>
830830
<figcaption>
831-
The items in the figure on the left are all strictly centered,
832-
even if the one that is too long to fit overflows on both sides,
833-
while those in the figure on the right are centered unless they overflow,
834-
in which case all the overflow goes off the end edge.
835-
If the container was placed
836-
against the left edge of the page,
837-
the “safe” behavior would be more desirable,
838-
as the long item would be fully readable,
839-
rather than clipped by the left edge of the screen.
840-
In other circumstances,
841-
the “unsafe” centering behavior might be better,
842-
as it correctly centers all the items.
831+
An example of "safe" (on the left)
832+
vs "unsafe" (on the right)
833+
centering,
834+
when the centered item is larger than its container.
843835
</figcaption>
844836
</figure>
837+
838+
The items in the figure on the left are centered unless they overflow,
839+
in which case all the overflow goes off the end edge,
840+
while those in the figure on the right are are all strictly centered,
841+
even if the one that is too long to fit overflows on both sides.
842+
843+
If the container was placed
844+
against the left edge of the page,
845+
the “safe” behavior would be more desirable,
846+
as the long item would be fully readable,
847+
rather than clipped by the left edge of the screen.
848+
In other circumstances,
849+
the “unsafe” centering behavior might be better,
850+
as it correctly centers all the items.
845851
</div>
846852

847853
To control this situation,

0 commit comments

Comments
 (0)