8000 Use sphinx-design for columns · matplotlib/cheatsheets@15b1482 · GitHub
[go: up one dir, main page]

Skip to content

Commit 15b1482

Browse files
committed
Use sphinx-design for columns
1 parent 82a1f80 commit 15b1482

File tree

4 files changed

+36
-36
lines changed

4 files changed

+36
-36
lines changed

docs/conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
# Add any Sphinx extension module names here, as strings. They can be
1515
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
1616
# ones.
17-
extensions = []
17+
extensions = ["sphinx_design"]
1818

1919
# Add any paths that contain templates here, relative to this directory.
2020

docs/index.rst

Lines changed: 30 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -7,23 +7,21 @@ Matplotlib cheatsheets and handouts
77
Cheatsheets
88
***********
99

10-
.. container:: twocol
10+
.. grid:: 2
1111

12-
.. container::
12+
.. grid-item::
1313

14-
.. image:: ../cheatsheets-1.png
15-
:width: 270px
16-
:align: center
17-
:alt: image of first page of cheatsheets
14+
.. image:: ../cheatsheets-1.png
15+
:width: 270px
16+
:align: center
17+
:alt: image of first page of cheatsheets
1818

19+
.. grid-item::
1920

20-
.. container::
21-
22-
.. image:: ../cheatsheets-2.png
23-
:width: 270px
24-
:align: center
25-
:alt: image of second page of cheatsheets
26-
21+
.. image:: ../cheatsheets-2.png
22+
:width: 270px
23+
:align: center
24+
:alt: image of second page of cheatsheets
2725

2826
`Cheatsheets [pdf] <./cheatsheets.pdf>`_
2927

@@ -32,36 +30,34 @@ Cheatsheets
3230
Handouts
3331
********
3432

35-
.. container:: twocol
36-
37-
.. container::
38-
39-
.. image:: ../handout-beginner.png
40-
:width: 270px
41-
:align: center
42-
:alt: image of beginner handout
33+
.. grid:: 3
4334

44-
`Beginner [pdf] <./handout-beginner.pdf>`_
35+
.. grid-item::
4536

37+
.. image:: ../handout-beginner.png
38+
:width: 270px
39+
:align: center
40+
:alt: image of beginner handout
4641

47-
.. container::
42+
`Beginner [pdf] <./handout-beginner.pdf>`_
4843

49-
.. image:: ../handout-intermediate.png
50-
:width: 270px
51-
:align: center
52-
:alt: image of intermediate handout
44+
.. grid-item::
5345

54-
`Intermediate [pdf] <./handout-intermediate.pdf>`_
46+
.. image:: ../handout-intermediate.png
47+
:width: 270px
48+
:align: center
49+
:alt: image of intermediate handout
5550

51+
`Intermediate [pdf] <./handout-intermediate.pdf>`_
5652

57-
.. container::
53+
.. grid-item::
5854

59-
.. image:: ../handout-tips.png
60-
:width: 270px
61-
:align: center
62-
:alt: image of tips handout
55+
.. image:: ../handout-tips.png
56+
:width: 270px
57+
:align: center
58+
:alt: image of tips handout
6359

64-
`Tips [pdf] <./handout-tips.pdf>`_
60+
`Tips [pdf] <./handout-tips.pdf>`_
6561

6662
Contribute
6763
**********

requirements/requirements.in

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ pip-tools
99
pre-commit
1010
scipy
1111
# Docs
12-
mpl-sphinx-theme==3.8.0
12+
mpl-sphinx-theme~=3.8
1313
pydata-sphinx-theme==0.13.3
1414
sphinx
15+
sphinx-design

requirements/requirements.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,9 @@ sphinx==7.2.6
154154
# via
155155
# -r requirements.in
156156
# pydata-sphinx-theme
157+
# sphinx-design
158+
sphinx-design==0.5.0
159+
# via -r requirements.in
157160
sphinxcontrib-applehelp==1.0.8
158161
# via sphinx
159162
sphinxcontrib-devhelp==1.0.6

0 commit comments

Comments
 (0)
0