Skip to content

Commit 9d45b89

Browse files
committed
toctree-toggle styled dropdown + responsive grid
1 parent d83eea0 commit 9d45b89

File tree

4 files changed

+46
-17
lines changed

4 files changed

+46
-17
lines changed

doc/_static/mpl.css

+18
Original file line numberDiff line numberDiff line change
@@ -110,3 +110,21 @@ table.property-table td {
110110
list-style:none;
111111
padding-inline-start:0em;
112112
}
113+
114+
/* styles dropdown like toctree-toggle */
115+
details.sd-dropdown{
116+
box-shadow: none !important;
117+
}
118+
119+
details.sd-dropdown summary.sd-card-header,
120+
details.sd-dropdown summary.sd-card-header+div.sd-summary-content {
121+
--pst-sd-dropdown-color: none;
122+
}
123+
124+
details.sd-dropdown summary {
125+
/* padding: 1em; */
126+
padding: 0;
127+
}
128+
129+
.sd-dropdown>.sd-card-body{
130+
padding: 0;}

doc/users/explain/index.rst

+3-2
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,9 @@
22

33
.. redirect-from:: /users/explain
44

5-
Explanations
6-
------------
5+
6+
API Documentation
7+
=================
78

89
.. toctree::
910
:maxdepth: 2

doc/users/index.rst

+23-14
Original file line numberDiff line numberDiff line change
@@ -2,36 +2,41 @@
22

33
.. redirect-from:: /contents
44

5-
..
6-
.. grid:: 3
5+
==========
6+
User guide
7+
==========
8+
9+
.. grid:: 1 1 3 3
710

811
.. grid-item-card:: Information
12+
:shadow: none
13+
:class-card: sd-border-0
914

10-
.. dropdown:: Getting Started
15+
.. dropdown:: :doc:`getting_started/index`
1116
:open:
1217

1318
.. toctree::
1419
:maxdepth: 2
1520

1621
getting_started/index.rst
1722

18-
.. dropdown:: Installation
23+
.. dropdown:: :doc:`installing/index`
1924
:open:
2025

2126
.. toctree::
2227
:maxdepth: 2
2328

2429
installing/index.rst
2530

26-
.. dropdown:: Contributing
31+
.. dropdown:: :doc:`../devel/index`
2732
:open:
2833

2934
.. toctree::
3035
:maxdepth: 2
3136

3237
../devel/index.rst
3338

34-
.. dropdown:: About
39+
.. dropdown:: :doc:`project/index`
3540
:open:
3641

3742
.. toctree::
@@ -41,32 +46,34 @@
4146

4247

4348
.. grid-item-card:: Explanations & Examples
49+
:shadow: none
50+
:class-card: sd-border-0
4451

45-
.. dropdown:: API Explanations
52+
.. dropdown:: :doc:`explain/index`
4653
:open:
4754

4855
.. toctree::
4956
:maxdepth: 2
5057

5158
explain/index.rst
5259

53-
.. dropdown:: Plot Types
60+
.. dropdown:: :doc:`../plot_types/index`
5461
:open:
5562

5663
.. toctree::
5764
:maxdepth: 2
5865

5966
../plot_types/index.rst
6067

61-
.. dropdown:: Tutorials
68+
.. dropdown:: :doc:`../tutorials/index`
6269
:open:
6370

6471
.. toctree::
6572
:maxdepth: 2
6673

6774
../tutorials/index.rst
6875

69-
.. dropdown:: Example Gallery
76+
.. dropdown:: :doc:`../gallery/index`
7077
:open:
7178

7279
.. toctree::
@@ -76,32 +83,34 @@
7683

7784

7885
.. grid-item-card:: References & Resources
86+
:shadow: none
87+
:class-card: sd-border-0
7988

80-
.. dropdown:: API Reference
89+
.. dropdown:: :doc:`../api/index`
8190
:open:
8291

8392
.. toctree::
8493
:maxdepth: 2
8594

8695
../api/index.rst
8796

88-
.. dropdown:: Release Notes
97+
.. dropdown:: :doc:`release_notes`
8998
:open:
9099

91100
.. toctree::
92101
:maxdepth: 2
93102

94103
release_notes.rst
95104

96-
.. dropdown:: Troubleshooting
105+
.. dropdown:: :doc:`faq/index`
97106
:open:
98107

99108
.. toctree::
100109
:maxdepth: 2
101110

102111
faq/index.rst
103112

104-
.. dropdown:: External Resources
113+
.. dropdown:: :doc:`resources/index`
105114
:open:
106115

107116
.. toctree::

doc/users/project/index.rst

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
.. redirect-from:: /users/backmatter
22

3+
===================
34
Project information
4-
-------------------
5+
===================
56

67
.. toctree::
78
:maxdepth: 2

0 commit comments

Comments
 (0)