mirror of
https://github.com/vale981/sphinx-multiversion
synced 2025-03-05 09:31:40 -05:00
docs: Add version sidebar
This commit is contained in:
parent
8d36aebb61
commit
afad67376e
2 changed files with 30 additions and 0 deletions
14
docs/_templates/versioning.html
vendored
Normal file
14
docs/_templates/versioning.html
vendored
Normal file
|
@ -0,0 +1,14 @@
|
|||
{% if versions %}
|
||||
<h3>{{ _('Branches') }}</h3>
|
||||
<ul>
|
||||
{%- for item in versions.branches %}
|
||||
<li><a href="{{ item.url }}">{{ item.name }}</a></li>
|
||||
{%- endfor %}
|
||||
</ul>
|
||||
<h3>{{ _('Tags') }}</h3>
|
||||
<ul>
|
||||
{%- for item in versions.tags %}
|
||||
<li><a href="{{ item.url }}">{{ item.name }}</a></li>
|
||||
{%- endfor %}
|
||||
</ul>
|
||||
{% endif %}
|
16
docs/conf.py
16
docs/conf.py
|
@ -15,3 +15,19 @@ templates_path = ["_templates"]
|
|||
extensions = [
|
||||
"sphinx_multiversion",
|
||||
]
|
||||
|
||||
templates_path = [
|
||||
"_templates",
|
||||
]
|
||||
|
||||
html_sidebars = {
|
||||
"**": [
|
||||
"about.html",
|
||||
"navigation.html",
|
||||
"relations.html",
|
||||
"searchbox.html",
|
||||
"versioning.html",
|
||||
],
|
||||
}
|
||||
|
||||
mv_remote_whitelist = r"^origin$"
|
||||
|
|
Loading…
Add table
Reference in a new issue