Skip to content

Commit fa456d0

Browse files
12rambaugabalafoudrammocktransifex-integration[bot]dependabot[bot]
authored
docs: add the list of component using a directive (#1476)
* fix: create the component list automatically * fix: read the first comment as documentation * docs: add disclaimer on .html suffix * docs: document every component with a simple one liner * fix: use regex to identify comments * update component branch (#15) * Change default logo alt text (#1472) * Default logo alt text only if no extra text * change default logo * use docstitle as default logo alt text * update docs to reflect change * Apply suggestions from code review Co-authored-by: Daniel McCloy <[email protected]> * use string formatting operator * Update docs/user_guide/branding.rst * docs fixes * Update docs/user_guide/branding.rst * add test * Update pyproject.toml * revert to original --------- Co-authored-by: Daniel McCloy <[email protected]> Co-authored-by: Rambaud Pierrick <[email protected]> * chore(i18n) catalan (#1488) i18n: Translate sphinx.po in ca 100% translated source file: 'sphinx.po' on 'ca'. Co-authored-by: transifex-integration[bot] <43880903+transifex-integration[bot]@users.noreply.github.com> * Build(deps): Bump postcss and css-loader (#1494) Bumps [postcss](https://github.com/postcss/postcss) to 8.4.31 and updates ancestor dependency [css-loader](https://github.com/webpack-contrib/css-loader). These dependencies need to be updated together. Updates `postcss` from 8.4.21 to 8.4.31 - [Release notes](https://github.com/postcss/postcss/releases) - [Changelog](https://github.com/postcss/postcss/blob/main/CHANGELOG.md) - [Commits](postcss/postcss@8.4.21...8.4.31) Updates `css-loader` from 3.6.0 to 6.8.1 - [Release notes](https://github.com/webpack-contrib/css-loader/releases) - [Changelog](https://github.com/webpack-contrib/css-loader/blob/master/CHANGELOG.md) - [Commits](webpack-contrib/css-loader@v3.6.0...v6.8.1) --- updated-dependencies: - dependency-name: postcss dependency-type: indirect - dependency-name: css-loader dependency-type: direct:development ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Revert "Build(deps): Bump postcss and css-loader" (#1509) Revert "Build(deps): Bump postcss and css-loader (#1494)" This reverts commit 185a37a. * Update pst docs buttons (#1502) * call them button-links * copy edit * docs: link back to GitHub from PyPI metadata (#1504) This will add a "Source" link in the PyPI page. * navigation_with_keys = False (#1503) * navigation_with_keys = False * None -> False * Apply suggestions from code review --------- Co-authored-by: Daniel McCloy <[email protected]> * fix: convert "stable" to actual version number (#1512) * convert "stable" to actual version number * fix tests re: navigation_with_keys * try bumping autoapi * refactor: use nbsphinx as the default execution lib (#1482) * refactor: use nbsphinx as the default execution lib * add nbstripout to the pre-commits' * add pandoc to the readthedocs deps * refactor: clean the notebook * move the example to the correct folder * fix: solve link issue * install pandoc in the test environment * fix: display of large table in executed cells * avoid Userwarnings from matplotlib * hide the matplotlib wrning management cell * Update readthedocs.yml * build: use pandoc_binary to install pandoc * docs: add reference to pandoc in the setup * update docs * remove pypandoc_binary * Update pyproject.toml Co-authored-by: gabalafou <[email protected]> * ci: use back setup-pandoc * Trigger CI build --------- Co-authored-by: Gabriel Fouasnon <[email protected]> * BUG - Clear alt_text in conf.py (#1471) * comment out alt_text in conf.py * set alt_text to empty string * remove alt_text from conf.py * fix: use 12rambau fork until it's merged with nikeee repo (#1517) * deps: drop support for Sphinx 5 (#1516) * remove ref to myst-nb * update minimal supported version of sphinx * Fix: (webpack.config.js) css-loader API change (#1508) * Fix: (webpack.config.js) css-loader API change The build was broken in <https://github.com/pydata/pydata-sphinx-theme/commit/185a37aa36820f77bffa4c87a772092e9e7cc380>/<https://github.com/pydata/pydata-sphinx-theme/pull/1494>. This change fixes the build, and it seems to be in accordance with the current API as described at <https://github.com/webpack-contrib/css-loader/blob/c6f36cf91ac61743a70e81cfb077faa0f8730ebe/README.md#boolean>. Closes <#1507>. * dedup * restore version bump --------- Co-authored-by: Daniel McCloy <[email protected]> * Fix duplicate HTML IDs (#1425) * Fix duplicate HTML IDs * fix tests * Do not animate the version admonitions colors. (#1424) Otherwise a delay has to be added to the accessibility color contrast checks, to wait for the colors to fully transition. * BUG - Remove redundant ARIA in breadcrumb navigation (#1426) * style(i18n): French Typo fixed (#1430) * Add the ability to add a center section to the footer (#1432) * Add a center section for the footer * Add docs for footer_center * Add a test site for the center footer * test it in our own docs * remove new test site * add footer test --------- Co-authored-by: Daniel McCloy <[email protected]> * Build(deps): Bump actions/checkout from 3 to 4 (#1433) Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](actions/checkout@v3...v4) --- updated-dependencies: - dependency-name: actions/checkout dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Add dropdown_text argument to generate_header_nav_html (#1423) * Add dropdown_text argument to generate_header_nav_html * Add a test, fix typo in theme.conf and remove header_dropdown_text from docs/conf.py * fixed? --------- Co-authored-by: Daniel McCloy <[email protected]> * fix: rollback ref and Id changes (#1438) * bump: version 0.13.3 → 0.14.0 (#1440) * bump version * update version switcher * back to dev * fix: change the z-index of the dropdown (#1442) In order to be on top of the primary sidebar on small screens. * fix: set the same background for dark/light (#1443) * fix: set the same background for dark/light et the same background color for all state of the search field. It is currently only applied when hovered * fix: wrong css selector * Update src/pydata_sphinx_theme/assets/styles/components/_search.scss * Update src/pydata_sphinx_theme/assets/styles/components/_search.scss * Fix duplicate HTML IDs * fix tests * unique_html_id * backwards-compat generate_header_nav_html * feedback review * update fixture * ughhhh...caching * code cleanup * fix test snapshot * put comment inside def --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: Denis Bitouzé <[email protected]> Co-authored-by: Stuart Mumford <[email protected]> Co-authored-by: Daniel McCloy <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Alenka Frim <[email protected]> Co-authored-by: Rambaud Pierrick <[email protected]> * chore: build the devcontainer automatically in codespace (#1483) * chore: build the devcontainer automaticallyin codespace * refactor: lint * add pandoc to the environment * Fix font color in search input box (#1524) * Fix color * Use --pst-color-text-base * docs: add DecentralChain (#1528) Co-authored-by: jourlez <[email protected]> * Updates for file src/pydata_sphinx_theme/locale/en/LC_MESSAGES/sphinx.po in ru [Manual Sync] (#1527) i18n: Translate sphinx.po in ru [Manual Sync] 96% of minimum 20% translated source file: 'sphinx.po' on 'ru'. Sync of partially translated files: untranslated content is included with an empty translation or source language content depending on file format Co-authored-by: transifex-integration[bot] <43880903+transifex-integration[bot]@users.noreply.github.com> * ignore transient errors in windows build CI (#1520) * use warning list * clean up notebook * refactor to pass on all platforms? * simplify * fix logic * iterate backwards * fix plaform detection? also don't log unnecessarily�[H * ignore empty string warnings * remove notebook metawarning * Revert "remove notebook metawarning" This reverts commit 42f4672. * try again * debug the mysterious empty warning * escape color codes * import * triage by intermittency, not by platform; better var names * simplify * fix list.remove * undo what I broke * Update tests/utils/check_warnings.py * refactor: remove extention on component set-up (#1529) * use event.key for search shortcut (#1525) * use event.key for search shortcut * suggestions from review * caps lock --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: gabalafou <[email protected]> Co-authored-by: Daniel McCloy <[email protected]> Co-authored-by: transifex-integration[bot] <43880903+transifex-integration[bot]@users.noreply.github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Ned Batchelder <[email protected]> Co-authored-by: Adam Porter <[email protected]> Co-authored-by: Denis Bitouzé <[email protected]> Co-authored-by: Stuart Mumford <[email protected]> Co-authored-by: Alenka Frim <[email protected]> Co-authored-by: Harutaka Kawamura <[email protected]> Co-authored-by: jourlez <[email protected]> * fix: use a directive instead of raw html * fix: make links externals * fix: set reference in paragraphs * fix: missing parameter * fix: use the stem for the component name * refactor: remove never used variables * standardize component descriptions --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: gabalafou <[email protected]> Co-authored-by: Daniel McCloy <[email protected]> Co-authored-by: transifex-integration[bot] <43880903+transifex-integration[bot]@users.noreply.github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Ned Batchelder <[email protected]> Co-authored-by: Adam Porter <[email protected]> Co-authored-by: Denis Bitouzé <[email protected]> Co-authored-by: Stuart Mumford <[email protected]> Co-authored-by: Alenka Frim <[email protected]> Co-authored-by: Harutaka Kawamura <[email protected]> Co-authored-by: jourlez <[email protected]>
1 parent 2a469a8 commit fa456d0

25 files changed

+132
-38
lines changed
+98
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,98 @@
1+
"""A directive to generate the list of all the built-in components.
2+
3+
Read the content of the component folder and generate a list of all the components.
4+
This list will display some informations about the component and a link to the
5+
GitHub file.
6+
"""
7+
import re
8+
from pathlib import Path
9+
from typing import Any, Dict, List
10+
11+
from docutils import nodes
12+
from sphinx.application import Sphinx
13+
from sphinx.util import logging
14+
from sphinx.util.docutils import SphinxDirective
15+
16+
logger = logging.getLogger(__name__)
17+
18+
19+
class ComponentListDirective(SphinxDirective):
20+
"""A directive to generate the list of all the built-in components.
21+
22+
Read the content of the component folder and generate a list of all the components.
23+
This list will display some informations about the component and a link to the
24+
GitHub file.
25+
"""
26+
27+
name = "component-list"
28+
has_content = True
29+
required_arguments = 0
30+
optional_arguments = 0
31+
final_argument_whitespace = True
32+
33+
def run(self) -> List[nodes.Node]:
34+
"""Create the list."""
35+
# get the list of all th jinja templates
36+
# not that to remain compatible with sphinx they are labeled as html files
37+
root = Path(__file__).parents[2]
38+
component_dir = (
39+
root
40+
/ "src"
41+
/ "pydata_sphinx_theme"
42+
/ "theme"
43+
/ "pydata_sphinx_theme"
44+
/ "components"
45+
)
46+
if not component_dir.is_dir():
47+
raise FileNotFoundError(
48+
f"Could not find component folder at {component_dir}."
49+
)
50+
components = sorted(component_dir.glob("*.html"))
51+
52+
# create the list of all the components description using bs4
53+
# at the moment we use dummy information
54+
docs = []
55+
pattern = re.compile(r"(?<={#).*?(?=#})", flags=re.DOTALL)
56+
for c in components:
57+
comment = pattern.findall(c.read_text())
58+
docs.append(comment[0].strip() if comment else "No description available.")
59+
60+
# get the urls from the github repo latest branch
61+
github_url = "https://github.com/pydata/pydata-sphinx-theme/blob/main"
62+
urls = [
63+
f"{github_url}/{component.relative_to(root)}" for component in components
64+
]
65+
66+
# build the list of all the components
67+
items = []
68+
for component, url, doc in zip(components, urls, docs):
69+
items.append(
70+
nodes.list_item(
71+
"",
72+
nodes.paragraph(
73+
"",
74+
"",
75+
nodes.reference("", component.stem, internal=False, refuri=url),
76+
nodes.Text(f": {doc}"),
77+
),
78+
)
79+
)
80+
81+
return [nodes.bullet_list("", *items)]
82+
83+
84+
def setup(app: Sphinx) -> Dict[str, Any]:
85+
"""Add custom configuration to sphinx app.
86+
87+
Args:
88+
app: the Sphinx application
89+
90+
Returns:
91+
the 2 parallel parameters set to ``True``.
92+
"""
93+
app.add_directive("component-list", ComponentListDirective)
94+
95+
return {
96+
"parallel_read_safe": True,
97+
"parallel_write_safe": True,
98+
}

docs/conf.py

+3-2
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,9 @@
3434
"sphinx_design",
3535
"sphinx_copybutton",
3636
"autoapi.extension",
37+
# custom extentions
38+
"_extension.gallery_directive",
39+
"_extension.component_directive",
3740
# For extension examples and demos
3841
"myst_parser",
3942
"ablog",
@@ -44,8 +47,6 @@
4447
"sphinx_togglebutton",
4548
"jupyterlite_sphinx",
4649
"sphinx_favicon",
47-
# custom extentions
48-
"_extension.gallery_directive",
4950
]
5051

5152
jupyterlite_config = "jupyterlite_config.json"

docs/user_guide/layout.rst

+6-23
Original file line numberDiff line numberDiff line change
@@ -518,29 +518,12 @@ Below is a list of built-in templates that you can insert into any section.
518518
Note that some of them may have CSS rules that assume a specific section (and
519519
will be named accordingly).
520520

521-
.. refer to files in: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/
522-
523-
- ``breadcrumbs.html``
524-
- ``copyright.html``
525-
- ``edit-this-page.html``
526-
- ``footer-article/prev-next.html``
527-
- ``icon-links.html``
528-
- ``last-updated.html``
529-
- ``navbar-icon-links.html``
530-
- ``navbar-logo.html``
531-
- ``navbar-nav.html``
532-
- ``page-toc.html``
533-
- ``searchbox.html``
534-
- ``search-button.html``
535-
- ``search-field.html``
536-
- ``sidebar-ethical-ads.html``
537-
- ``sidebar-nav-bs.html``
538-
- ``sourcelink.html``
539-
- ``sphinx-version.html``
540-
- ``theme-switcher.html``
541-
- ``version-switcher.html``
542-
- ``indices.html``
543-
- ``theme-version.html``
521+
.. note::
522+
523+
When adding/changing/overwritting a component, the ".html" suffix is optional.
524+
That's why all of them are displayed without it in the following list.
525+
526+
.. component-list::
544527

545528

546529
Add your own HTML templates to theme sections

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/breadcrumbs.html

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{# Displays (and links to) the parent section(s) of the currently viewed page. #}
12
{%- block breadcrumbs %}
23
{#
34
If we have more than 3 parents (excluding the home page) then we remove

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/copyright.html

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{# Displays the copyright information (which is defined in conf.py). #}
12
{% if show_copyright and copyright %}
23
<p class="copyright">
34
{% if hasdoc('copyright') %}

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/edit-this-page.html

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{# Displays a link to the edit interface of the page source in the specified Version Control System. #}
12
{% if sourcename is defined and theme_use_edit_page_button==true and page_source_suffix %}
23
{% set src = sourcename.split('.') %}
34
<div class="tocsection editthispage">

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/icon-links.html

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{# Displays icon-links as list items. #}
12
{%- macro icon_link_nav_item(url, icon, name, type, attributes='') -%}
23
{%- if url | length > 2 %}
34
<li class="nav-item">

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/indices.html

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{# Displays links to the Sphinx-generated indices (genindex, modindex, py-modindex). #}
12
<nav class="sidebar-indices-items">
23
<p class="sidebar-indices-items__title" role="heading" aria-level="1">{{ _("Indices") }}</p>
34
<ul class="indices-link">

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/last-updated.html

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{# Displays the date and time that the documentation was last built. #}
12
{%- if last_updated -%}
23
<p class="last-updated">
34
{% trans last_updated=last_updated|e %}Last updated on {{ last_updated }}.{% endtrans %}
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{# Displays icon-links in the header navbar. #}
12
{%- block icon_links -%}
23
{%- include "icon-links.html" with context -%}
34
{%- endblock icon_links %}

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-logo.html

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{# Displays the logo of your documentation site, in the header navbar. #}
12
{# Logo link generation -#}
23
{% if not theme_logo.get("link") %}
34
{% set href = pathto(root_doc) %}

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-nav.html

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{# Displays links to the top-level TOCtree elements, in the header navbar. #}
12
<nav class="navbar-nav">
23
<p class="sidebar-header-items__title"
34
role="heading"

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/page-toc.html

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{# Displays the current page's Table of Contents. #}
12
{% set page_toc = generate_toc_html() %}
23
{%- if page_toc | length >= 1 %}
34
<div class="page-toc tocsection onthispage">

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/prev-next.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!-- Previous / next buttons -->
1+
{# Displays links to the previous and next page in the TOCtree order. #}
22
<div class="prev-next-area">
33
{%- if prev %}
44
<a class="left-prev"

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/search-button-field.html

+2-4
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
1-
{# Behaves the same as `search-button.html` but looks more like a search field.
2-
#
3-
# As this function will only work when JavaScript is enabled, we add it through JavaScript.
4-
#}
1+
{# Displays a search field image that opens a search overlay when clicked. #}
2+
{# As this function will only work when JavaScript is enabled, we add it through JavaScript. #}
53
<script>
64
document.write(`
75
<button class="btn navbar-btn search-button-field search-button__button" title="{{ _('Search') }}" aria-label="{{ _('Search') }}" data-bs-placement="bottom" data-bs-toggle="tooltip">

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/search-button.html

+2-4
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
1-
{# A button that, when clicked, will trigger a search popup overlay.
2-
#
3-
# As this function will only work when JavaScript is enabled, we add it through JavaScript.
4-
#}
1+
{# Displays a magnifying glass icon that opens a search overlay when clicked. #}
2+
{# As this function will only work when JavaScript is enabled, we add it through JavaScript. #}
53
<script>
64
document.write(`
75
<button class="btn btn-sm navbar-btn search-button search-button__button" title="{{ _('Search') }}" aria-label="{{ _('Search') }}" data-bs-placement="bottom" data-bs-toggle="tooltip">

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/search-field.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
{# A bootstrap-styled field that will direct to the `search.html` page when submitted #}
1+
{# Displays an interactive search field directly on the page. #}
22
<form class="bd-search d-flex align-items-center"
33
action="{{ pathto('search') }}"
44
method="get">
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
{# div#searchbox hosts the "Hide Search Matches" link #}
1+
{# An empty container that holds the "Hide Search Matches" button when it's needed. #}
22
<div id="searchbox"></div>

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/sidebar-ethical-ads.html

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{# For sites hosted on ReadTheDocs, displays "ethical ads". #}
12
{% if READTHEDOCS %}
23
<div id="ethical-ad-placement"
34
class="flat"

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/sidebar-nav-bs.html

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{# Displays the TOC-subtree for pages nested under the currently active top-level TOCtree element. #}
12
<nav class="bd-docs-nav bd-links"
23
aria-label="{{ _('Section Navigation') }}">
34
<p class="bd-links__title" role="heading" aria-level="1">{{ _("Section Navigation") }}</p>

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/sourcelink.html

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{# Displays a link to the .rst source of the current page. #}
12
{% if show_source and has_source and sourcename %}
23
<div class="tocsection sourcelink">
34
<a href="{{ pathto('_sources/' + sourcename, true)|e }}">

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/sphinx-version.html

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{# Display the version of Sphinx used to build your documentation. #}
12
{% if show_sphinx %}
23
<p class="sphinx-version">
34
{% trans sphinx_version=sphinx_version|e %}Created using <a href="https://www.sphinx-doc.org/">Sphinx</a> {{ sphinx_version }}.{% endtrans %}

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/theme-switcher.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
{# As the theme switcher will only work when JavaScript is enabled, we add it through JavaScript.
2-
#}
1+
{# Displays an icon to switch between light mode, dark mode, and auto (use browser's setting). #}
2+
{# As the theme switcher will only work when JavaScript is enabled, we add it through JavaScript. #}
33
<script>
44
document.write(`
55
<button class="btn btn-sm navbar-btn theme-switch-button" title="{{ _('light/dark') }}" aria-label="{{ _('light/dark') }}" data-bs-placement="bottom" data-bs-toggle="tooltip">
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{# Displays the version of pydata-sphinx-theme used to build the documentation. #}
12
<p class="theme-version">
23
{% trans theme_version=theme_version|e %}Built with the <a href="https://pydata-sphinx-theme.readthedocs.io/en/stable/index.html">PyData Sphinx Theme</a> {{ theme_version }}.{% endtrans %}
34
</p>

src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/version-switcher.html

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{# Displays a dropdown box for switching among different versions of your documentation. #}
12
{%- set button_id = unique_html_id("pst-version-switcher-button") -%}
23
{%- set dropdown_id = unique_html_id("pst-version-switcher-list") -%}
34
{# As the version switcher will only work when JavaScript is enabled, we add it through JavaScript. #}

0 commit comments

Comments
 (0)