mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
Merge pull request #7443 from mgeier/theme-options-toctree
Add globaltoc_collapse and globaltoc_includehidden options
This commit is contained in:
commit
1e3ce31b03
@ -155,6 +155,21 @@ These themes are:
|
||||
previous/next page using the keyboard's left and right arrows. Defaults to
|
||||
``False``.
|
||||
|
||||
- **globaltoc_collapse** (true or false): Only expand subsections
|
||||
of the current document in ``globaltoc.html``
|
||||
(see :confval:`html_sidebars`).
|
||||
Defaults to ``True``.
|
||||
|
||||
.. versionadded:: 3.1
|
||||
|
||||
- **globaltoc_includehidden** (true or false): Show even those
|
||||
subsections in ``globaltoc.html`` (see :confval:`html_sidebars`)
|
||||
which have been included with the ``:hidden:`` flag of the
|
||||
:rst:dir:`toctree` directive.
|
||||
Defaults to ``False``.
|
||||
|
||||
.. versionadded:: 3.1
|
||||
|
||||
**alabaster**
|
||||
`Alabaster theme`_ is a modified "Kr" Sphinx theme from @kennethreitz
|
||||
(especially as used in his Requests project), which was itself originally
|
||||
|
@ -8,4 +8,4 @@
|
||||
:license: BSD, see LICENSE for details.
|
||||
#}
|
||||
<h3><a href="{{ pathto(master_doc)|e }}">{{ _('Table of Contents') }}</a></h3>
|
||||
{{ toctree() }}
|
||||
{{ toctree(includehidden=theme_globaltoc_includehidden, collapse=theme_globaltoc_collapse) }}
|
||||
|
@ -10,3 +10,5 @@ sidebarwidth = 230
|
||||
body_min_width = 450
|
||||
body_max_width = 800
|
||||
navigation_with_keys = False
|
||||
globaltoc_collapse = true
|
||||
globaltoc_includehidden = false
|
||||
|
Loading…
Reference in New Issue
Block a user