Docs: fix list spacing

Workaround sphinx-rtd-theme regression
on spacing in "open" lists.
This commit is contained in:
Mike Edmunds
2024-03-06 16:10:37 -08:00
parent 5949069321
commit e758579230

View File

@@ -53,3 +53,20 @@ table.sticky-left th:first-of-type[colspan] > p {
border-radius: 50px;
padding: 6px 12px;
}
/* Improve list item spacing in "open" lists.
https://github.com/readthedocs/sphinx_rtd_theme/issues/1555
Undoes this rule in non-.simple lists:
https://github.com/readthedocs/sphinx_rtd_theme/blob/2.0.0/src/sass/_theme_rst.sass#L174-L175
*/
.rst-content .section ol:not(.simple) > li > p:only-child,
.rst-content .section ol:not(.simple) > li > p:only-child:last-child,
.rst-content .section ul:not(.simple) > li > p:only-child,
.rst-content .section ul:not(.simple) > li > p:only-child:last-child,
.rst-content section ol:not(.simple) > li > p:only-child,
.rst-content section ol:not(.simple) > li > p:only-child:last-child,
.rst-content section ul:not(.simple) > li > p:only-child,
.rst-content section ul:not(.simple) > li > p:only-child:last-child {
margin-bottom: 12px;
}