diff --git a/docs/conf.py b/docs/conf.py index e148716..18b8e08 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -29,7 +29,8 @@ # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom # ones. extensions = [ - 'matplotlib.sphinxext.plot_directive', + "matplotlib.sphinxext.plot_directive", + "sphinx_design" ] # Add any paths that contain templates here, relative to this directory. @@ -61,6 +62,12 @@ "navbar_links": "absolute", } +html_sidebars = { + "index": [ + "donate_sidebar.html", + ], +} + # Add any paths that contain custom static files (such as style sheets) here, # relative to this directory. They are copied after the builtin static files, # so a file named "default.css" will overwrite the builtin "default.css". diff --git a/mpl_sphinx_theme/donate_sidebar.html b/mpl_sphinx_theme/donate_sidebar.html index a4a0777..9744abe 100644 --- a/mpl_sphinx_theme/donate_sidebar.html +++ b/mpl_sphinx_theme/donate_sidebar.html @@ -1,8 +1,5 @@ - - - + + Support Matplotlib + + diff --git a/mpl_sphinx_theme/static/css/style.css b/mpl_sphinx_theme/static/css/style.css index 4284099..fe65596 100644 --- a/mpl_sphinx_theme/static/css/style.css +++ b/mpl_sphinx_theme/static/css/style.css @@ -14,15 +14,15 @@ html[data-theme="dark"] { } :root { ---pst-color-link-hover: var(--pst-color-secondary); + --pst-color-link-hover: var(--pst-color-secondary); } -.sidebar-cheatsheets, .sidebar-donate { - margin: 2.75rem 0; +.sidebar-donate > .sd-btn { + width: 100%; } #navbar-icon-links { - margin-left: 1.5em; + margin-left: 1.5em; } #navbar-icon-links .nav-link { @@ -32,4 +32,3 @@ html[data-theme="dark"] { #navbar-icon-links .nav-link:hover { color: var(--pst-color-primary); } - diff --git a/pyproject.toml b/pyproject.toml index 55a2847..076ce2f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -21,6 +21,7 @@ classifiers = [ dependencies = [ "pydata-sphinx-theme>=0.13.1", "matplotlib", + "sphinx-design", ] [project.urls]