diff --git a/README.md b/README.md index 249aa8361..bc4d9619e 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # pydata-sphinx-theme -![pypi](https://img.shields.io/pypi/v/pydata-sphinx-theme) [![conda-forge](https://img.shields.io/conda/vn/conda-forge/pydata-sphinx-theme.svg)](https://anaconda.org/conda-forge/pydata-sphinx-theme) [![continuous-integration](https://github.com/pydata/pydata-sphinx-theme/actions/workflows/tests.yml/badge.svg)](https://github.com/pydata/pydata-sphinx-theme/actions/workflows/tests.yml) [![docs](https://readthedocs.org/projects/pydata-sphinx-theme/badge/)](https://readthedocs.org/projects/pydata-sphinx-theme/builds/) [![codecov](https://codecov.io/gh/pydata/pydata-sphinx-theme/branch/master/graph/badge.svg?token=NwOObjYacn)](https://codecov.io/gh/pydata/pydata-sphinx-theme) +![pypi](https://img.shields.io/pypi/v/pydata-sphinx-theme) [![conda-forge](https://img.shields.io/conda/vn/conda-forge/pydata-sphinx-theme.svg)](https://anaconda.org/conda-forge/pydata-sphinx-theme) [![continuous-integration](https://github.com/pydata/pydata-sphinx-theme/actions/workflows/tests.yml/badge.svg)](https://github.com/pydata/pydata-sphinx-theme/actions/workflows/tests.yml) [![docs](https://readthedocs.org/projects/pydata-sphinx-theme/badge/)](https://readthedocs.org/projects/pydata-sphinx-theme/builds/) [![codecov](https://codecov.io/gh/pydata/pydata-sphinx-theme/branch/main/graph/badge.svg?token=NwOObjYacn)](https://codecov.io/gh/pydata/pydata-sphinx-theme) A Bootstrap-based Sphinx theme from the PyData community. diff --git a/docs/conf.py b/docs/conf.py index 4f8ecc5e0..2dadf7171 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -149,9 +149,9 @@ myst_heading_anchors = 2 html_context = { - "github_user": "pandas-dev", + "github_user": "pydata", "github_repo": "pydata-sphinx-theme", - "github_version": "master", + "github_version": "main", "doc_path": "docs", } diff --git a/docs/user_guide/configuring.rst b/docs/user_guide/configuring.rst index 5d960cb0f..882cee940 100644 --- a/docs/user_guide/configuring.rst +++ b/docs/user_guide/configuring.rst @@ -19,7 +19,7 @@ doc path's _static folder, and use the following configuration: html_logo = "_static/logo.png" -The logo links to ``master_doc`` (usually the first page of your documentation) by default. +The logo links to ``root_doc`` (usually the first page of your documentation) by default. If you'd like it to link to another page or use an external link instead, use the following configuration: .. code:: python @@ -167,7 +167,7 @@ For example: { "name": "Pandas", "url": "https://pandas.pydata.org", - "icon": "https://raw.githubusercontent.com/pydata/pydata-sphinx-theme/master/docs/_static/pandas-square.svg", + "icon": "https://raw.githubusercontent.com/pydata/pydata-sphinx-theme/main/docs/_static/pandas-square.svg", "type": "url", }, ], diff --git a/docs/user_guide/customizing.rst b/docs/user_guide/customizing.rst index 23c40d63c..546c9144b 100644 --- a/docs/user_guide/customizing.rst +++ b/docs/user_guide/customizing.rst @@ -279,8 +279,8 @@ The default body and header fonts can be changed as follows: specifically the binary font files. This ensure the files will be loaded before waiting for the CSS to be parsed, but should be used with care. -.. _pydata-css-variables: https://github.com/pydata/pydata-sphinx-theme/blob/master/src/pydata_sphinx_theme/theme/pydata_sphinx_theme/static/styles/theme.css -.. _pydata-css-colors: https://github.com/pydata/pydata-sphinx-theme/blob/master/src/pydata_sphinx_theme/assets/styles/base/_color.scss +.. _pydata-css-variables: https://github.com/pydata/pydata-sphinx-theme/blob/main/src/pydata_sphinx_theme/theme/pydata_sphinx_theme/static/styles/theme.css +.. _pydata-css-colors: https://github.com/pydata/pydata-sphinx-theme/blob/main/src/pydata_sphinx_theme/assets/styles/base/_color.scss .. _css-variable-help: https://developer.mozilla.org/en-US/docs/Web/CSS/Using_CSS_custom_properties .. meta:: diff --git a/docs/user_guide/install.rst b/docs/user_guide/install.rst index 2870e5cde..f7ff89a8f 100644 --- a/docs/user_guide/install.rst +++ b/docs/user_guide/install.rst @@ -42,14 +42,14 @@ install it from the git repo: .. code:: console - $ pip install git+https://github.com/pydata/pydata-sphinx-theme.git@master + $ pip install git+https://github.com/pydata/pydata-sphinx-theme.git@main or in a conda environment yml file, you can add: .. code:: none - pip: - - git+https://github.com/pydata/pydata-sphinx-theme.git@master + - git+https://github.com/pydata/pydata-sphinx-theme.git@main .. meta:: :description lang=en: diff --git a/src/pydata_sphinx_theme/__init__.py b/src/pydata_sphinx_theme/__init__.py index 643563590..1977b4666 100644 --- a/src/pydata_sphinx_theme/__init__.py +++ b/src/pydata_sphinx_theme/__init__.py @@ -365,8 +365,8 @@ def _get_local_toctree_for( ): """Return the "local" TOC nodetree (relative to `indexname`).""" # this is a copy of `TocTree.get_toctree_for`, but where the sphinx version - # always uses the "master" doctree: - # doctree = self.env.get_doctree(self.env.config.master_doc) + # always uses the "root" doctree: + # doctree = self.env.get_doctree(self.env.config.root_doc) # we here use the `indexname` additional argument to be able to use a subset # of the doctree (e.g. starting at a second level for the sidebar): # doctree = app.env.tocs[indexname].deepcopy() diff --git a/src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-logo.html b/src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-logo.html index b561735fc..3e15bf6fc 100644 --- a/src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-logo.html +++ b/src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-logo.html @@ -1,6 +1,6 @@ {% if logo %} {% if not theme_logo_link %} - + {% elif theme_logo_link[:4] == 'http' %} @@ -13,7 +13,7 @@ {% endif %} {% else %} - +

{{ project }}

{% endif %} diff --git a/tests/sites/base/conf.py b/tests/sites/base/conf.py index e497de1f3..5d63769ce 100644 --- a/tests/sites/base/conf.py +++ b/tests/sites/base/conf.py @@ -4,7 +4,7 @@ copyright = "2020, Pydata community" author = "Pydata community" -master_doc = "index" +root_doc = "index" # -- General configuration --------------------------------------------------- diff --git a/tests/sites/sidebars/conf.py b/tests/sites/sidebars/conf.py index 64dbb56f2..504e54d38 100644 --- a/tests/sites/sidebars/conf.py +++ b/tests/sites/sidebars/conf.py @@ -4,7 +4,7 @@ copyright = "2020, Pydata community" author = "Pydata community" -master_doc = "index" +root_doc = "index" # -- General configuration --------------------------------------------------- diff --git a/tests/sites/test_included_toc/conf.py b/tests/sites/test_included_toc/conf.py index a788bae46..8d681b914 100644 --- a/tests/sites/test_included_toc/conf.py +++ b/tests/sites/test_included_toc/conf.py @@ -6,7 +6,7 @@ # -- General configuration --------------------------------------------------- -master_doc = "index" +root_doc = "index" # -- Options for HTML output ------------------------------------------------- diff --git a/tests/sites/test_navbar_no_in_page_headers/conf.py b/tests/sites/test_navbar_no_in_page_headers/conf.py index 5a74eebf8..d56059e28 100644 --- a/tests/sites/test_navbar_no_in_page_headers/conf.py +++ b/tests/sites/test_navbar_no_in_page_headers/conf.py @@ -4,7 +4,7 @@ copyright = "2020, Pydata community" author = "Pydata community" -master_doc = "index" +root_doc = "index" # -- General configuration ---------------------------------------------------