Skip to content

Commit a8ae966

Browse files
authored
Adding left margin to lists in admonition (#231)
1 parent 190f32b commit a8ae966

File tree

5 files changed

+16
-4
lines changed

5 files changed

+16
-4
lines changed

docs/demo/demo.rst

+7
Original file line numberDiff line numberDiff line change
@@ -409,6 +409,13 @@ Admonitions
409409
Equations within a note:
410410
:math:`G_{\mu\nu} = 8 \pi G (T_{\mu\nu} + \rho_\Lambda g_{\mu\nu})`.
411411

412+
.. Note:: Lists in admonitions.
413+
414+
1. Here's a list item
415+
2. And another list item
416+
417+
They should be in-line with the text around them!
418+
412419
.. Tip:: 15% if the service is good.
413420

414421
+---------+

pydata_sphinx_theme/static/css/index.ce93c4bad7c1e5d5e6f0259f1a164f49.css renamed to pydata_sphinx_theme/static/css/index.d431a4ee1c1efae0e38bdfebc22debff.css

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pydata_sphinx_theme/static/webpack-macros.html

+3-3
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,13 @@
1616
{% endmacro %}
1717

1818
{% macro head_pre_bootstrap() %}
19-
<link rel="stylesheet" href="{{ pathto('_static/css/index.ce93c4bad7c1e5d5e6f0259f1a164f49.css', 1) }}">
19+
<link rel="stylesheet" href="{{ pathto('_static/css/index.d431a4ee1c1efae0e38bdfebc22debff.css', 1) }}">
2020
{% endmacro %}
2121

2222
{% macro head_js_preload() %}
23-
<link rel="preload" as="script" href="{{ pathto('_static/js/index.6f94ef916480b5a8afd0.js', 1) }}">
23+
<link rel="preload" as="script" href="{{ pathto('_static/js/index.30270b6e4c972e43c488.js', 1) }}">
2424
{% endmacro %}
2525

2626
{% macro body_post() %}
27-
<script src="{{ pathto('_static/js/index.6f94ef916480b5a8afd0.js', 1) }}"></script>
27+
<script src="{{ pathto('_static/js/index.30270b6e4c972e43c488.js', 1) }}"></script>
2828
{% endmacro %}

src/scss/_admonitions.scss

+5
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,11 @@
2020
padding: 0 1.4rem;
2121
}
2222

23+
// Lists need to have left margin so they don't spill into it
24+
> ol, > ul {
25+
margin-left: 1em;
26+
}
27+
2328
// Defaults for all admonitions
2429
.admonition-title {
2530
position: relative;

0 commit comments

Comments
 (0)