diff --git a/doc/_templates/mpl_nav_bar.html b/doc/_templates/mpl_nav_bar.html
deleted file mode 100644
index 82b8586de449..000000000000
--- a/doc/_templates/mpl_nav_bar.html
+++ /dev/null
@@ -1,21 +0,0 @@
-
diff --git a/doc/conf.py b/doc/conf.py
index 95d74b9528de..a918c7bdf3a2 100644
--- a/doc/conf.py
+++ b/doc/conf.py
@@ -291,7 +291,7 @@ def _check_dependencies():
f"mpl.css?{SHA}",
]
-html_theme = "pydata_sphinx_theme"
+html_theme = "mpl_sphinx_theme"
# The name for this set of Sphinx documents. If None, it defaults to
# " v documentation".
@@ -301,34 +301,12 @@ def _check_dependencies():
# the sidebar.
html_logo = "_static/logo2.svg"
html_theme_options = {
+ "native_site": True,
"logo_link": "index",
# collapse_navigation in pydata-sphinx-theme is slow, so skipped for local
# and CI builds https://github.com/pydata/pydata-sphinx-theme/pull/386
"collapse_navigation": not is_release_build,
- "icon_links": [
- {
- "name": "gitter",
- "url": "https://gitter.im/matplotlib",
- "icon": "fab fa-gitter",
- },
- {
- "name": "discourse",
- "url": "https://discourse.matplotlib.org",
- "icon": "fab fa-discourse",
- },
- {
- "name": "GitHub",
- "url": "https://github.com/matplotlib/matplotlib",
- "icon": "fab fa-github-square",
- },
- {
- "name": "twitter",
- "url": "https://twitter.com/matplotlib/",
- "icon": "fab fa-twitter-square",
- },
- ],
"show_prev_next": False,
- "navbar_center": ["mpl_nav_bar.html"],
}
include_analytics = is_release_build
if include_analytics:
diff --git a/doc/devel/documenting_mpl.rst b/doc/devel/documenting_mpl.rst
index 2355a251be57..70241c493c85 100644
--- a/doc/devel/documenting_mpl.rst
+++ b/doc/devel/documenting_mpl.rst
@@ -1004,6 +1004,14 @@ Example:
:parts: 2
+Navbar and style
+----------------
+
+Matplotlib has a few subprojects that share the same navbar and style, so these
+are centralized as a sphinx theme at
+`mpl_sphinx_theme `_. Changes to the
+style or topbar should be made there to propagate across all subprojects.
+
.. TODO: Add section about uploading docs
.. _ReST: https://docutils.sourceforge.io/rst.html
diff --git a/environment.yml b/environment.yml
index 34a322e325ad..d73d7a99f579 100644
--- a/environment.yml
+++ b/environment.yml
@@ -36,6 +36,7 @@ dependencies:
- sphinx-panels
- pip
- pip:
+ - mpl-sphinx-theme
- sphinxcontrib-svg2pdfconverter
# testing
- coverage
diff --git a/requirements/doc/doc-requirements.txt b/requirements/doc/doc-requirements.txt
index 4e2188d65725..afb5c4105fae 100644
--- a/requirements/doc/doc-requirements.txt
+++ b/requirements/doc/doc-requirements.txt
@@ -14,7 +14,7 @@ ipywidgets
numpydoc>=0.8
packaging>=20
pyparsing<3.0.0
-pydata-sphinx-theme>=0.6.0
+mpl-sphinx-theme
sphinxcontrib-svg2pdfconverter>=1.1.0
sphinx-gallery>=0.10
sphinx-copybutton