diff --git a/doc/source/conf.py b/doc/source/conf.py index e7ce8511b76a1..be6150d4e54ba 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -230,11 +230,13 @@ # further. For a list of options available for each theme, see the # documentation. -switcher_version = version if ".dev" in version: switcher_version = "dev" elif "rc" in version: switcher_version = version.split("rc", maxsplit=1)[0] + " (rc)" +else: + # only keep major.minor version number to match versions.json + switcher_version = ".".join(version.split(".")[:2]) html_theme_options = { "external_links": [], @@ -246,11 +248,13 @@ "plausible_analytics_url": "https://views.scientific-python.org/js/script.js", }, "logo": {"image_dark": "https://pandas.pydata.org/static/img/pandas_white.svg"}, + "navbar_align": "left", "navbar_end": ["version-switcher", "theme-switcher", "navbar-icon-links"], "switcher": { "json_url": "https://pandas.pydata.org/versions.json", "version_match": switcher_version, }, + "show_version_warning_banner": True, "icon_links": [ { "name": "Mastodon", diff --git a/environment.yml b/environment.yml index 5fad8b5031b0a..74317d47e2e53 100644 --- a/environment.yml +++ b/environment.yml @@ -86,7 +86,7 @@ dependencies: - google-auth - natsort # DataFrame.sort_values doctest - numpydoc - - pydata-sphinx-theme=0.13 + - pydata-sphinx-theme=0.14 - pytest-cython # doctest - sphinx - sphinx-design diff --git a/requirements-dev.txt b/requirements-dev.txt index 76f4de2d8f0c4..cbfb6336b2e16 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -61,7 +61,7 @@ gitdb google-auth natsort numpydoc -pydata-sphinx-theme==0.13 +pydata-sphinx-theme==0.14 pytest-cython sphinx sphinx-design diff --git a/web/pandas/versions.json b/web/pandas/versions.json index 43efaf8ebe259..e355005c7c937 100644 --- a/web/pandas/versions.json +++ b/web/pandas/versions.json @@ -7,7 +7,8 @@ { "name": "2.1 (stable)", "version": "2.1", - "url": "https://pandas.pydata.org/docs/" + "url": "https://pandas.pydata.org/docs/", + "preferred": true }, { "name": "2.0",