Skip to content

Commit e758579

Browse files
committed
Docs: fix list spacing
Workaround sphinx-rtd-theme regression on spacing in "open" lists.
1 parent 5949069 commit e758579

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

docs/_static/anymail-theme.css

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,3 +53,20 @@ table.sticky-left th:first-of-type[colspan] > p {
5353
border-radius: 50px;
5454
padding: 6px 12px;
5555
}
56+
57+
/* Improve list item spacing in "open" lists.
58+
https://github.com/readthedocs/sphinx_rtd_theme/issues/1555
59+
60+
Undoes this rule in non-.simple lists:
61+
https://github.com/readthedocs/sphinx_rtd_theme/blob/2.0.0/src/sass/_theme_rst.sass#L174-L175
62+
*/
63+
.rst-content .section ol:not(.simple) > li > p:only-child,
64+
.rst-content .section ol:not(.simple) > li > p:only-child:last-child,
65+
.rst-content .section ul:not(.simple) > li > p:only-child,
66+
.rst-content .section ul:not(.simple) > li > p:only-child:last-child,
67+
.rst-content section ol:not(.simple) > li > p:only-child,
68+
.rst-content section ol:not(.simple) > li > p:only-child:last-child,
69+
.rst-content section ul:not(.simple) > li > p:only-child,
70+
.rst-content section ul:not(.simple) > li > p:only-child:last-child {
71+
margin-bottom: 12px;
72+
}

0 commit comments

Comments
 (0)