diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml
index b32f6964c..c8381aa89 100644
--- a/.github/workflows/tests.yml
+++ b/.github/workflows/tests.yml
@@ -97,6 +97,7 @@ jobs:
uses: codecov/codecov-action@v4
with:
fail_ci_if_error: true
+ verbose: true
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
diff --git a/babel.cfg b/babel.cfg
index 6d040b9b9..c835a5d51 100644
--- a/babel.cfg
+++ b/babel.cfg
@@ -1,4 +1,5 @@
-# See https://github.com/sphinx-doc/sphinx/blob/6.1.x/babel.cfg
+# See https://github.com/python-babel/babel/blob/2a1709a7768f6f07c3d2dbfdb03d3c8a6bd80aef/docs/messages.rst#extraction-method-mapping-and-configuration
+[python: **.py]
[jinja2: **.html]
encoding = utf-8
ignore_tags = script,style
diff --git a/docs/_static/pydata-icon.js b/docs/_static/pydata-icon.js
new file mode 100644
index 000000000..d111ec834
--- /dev/null
+++ b/docs/_static/pydata-icon.js
@@ -0,0 +1,16 @@
+/*******************************************************************************
+ * Set a custom icon for PyData
+ */
+FontAwesome.library.add(
+ (faListOldStyle = {
+ prefix: "fa-custom",
+ iconName: "pydata",
+ icon: [
+ 24, // viewBox width
+ 24, // viewBox height
+ [], // ligature
+ "e002", // unicode codepoint - private use area
+ "M12.1,17.8v5.8l-5-2.9v-5.8L12.1,17.8z M12.1,12v5.8l-5-2.9V9.1L12.1,12z M17,9.1L12.1,12v5.8l4.9-2.9V9.1z M12.1,6.2L7,9.1l5,2.9L17,9.1L12.1,6.2z M17,9.1V3.3l-4.9-2.8v5.8L17,9.1z",
+ ],
+ })
+);
diff --git a/docs/_static/pydata-logo.png b/docs/_static/pydata-logo.png
deleted file mode 100644
index bfdf323b9..000000000
Binary files a/docs/_static/pydata-logo.png and /dev/null differ
diff --git a/docs/conf.py b/docs/conf.py
index cd2827596..601d99451 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -13,6 +13,7 @@
import pydata_sphinx_theme
from sphinx.application import Sphinx
+from sphinx.locale import _
sys.path.append(str(Path(".").resolve()))
@@ -89,6 +90,11 @@
"jupyter": ("Jupyter", "https://jupyter.org"),
}
+# -- sphinx_togglebutton options ---------------------------------------------
+togglebutton_hint = str(_("Click to expand"))
+togglebutton_hint_hide = str(_("Click to collapse"))
+
+
# -- Options for HTML output -------------------------------------------------
html_theme = "pydata_sphinx_theme"
@@ -153,9 +159,7 @@
{
"name": "PyData",
"url": "https://pydata.org",
- "icon": "_static/pydata-logo.png",
- "type": "local",
- "attributes": {"target": "_blank"},
+ "icon": "fa-custom fa-pydata",
},
],
# alternative way to set twitter and github header icons
@@ -228,7 +232,7 @@
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ["_static"]
html_css_files = ["custom.css"]
-html_js_files = ["custom-icon.js"]
+html_js_files = ["pydata-icon.js", "custom-icon.js"]
todo_include_todos = True
# -- favicon options ---------------------------------------------------------
diff --git a/docs/examples/gallery.md b/docs/examples/gallery.md
index 755c63661..f2a7a21e7 100644
--- a/docs/examples/gallery.md
+++ b/docs/examples/gallery.md
@@ -38,8 +38,8 @@ Thanks for your support!
- title: Feature-engine
link-alt: Feature-engine docs
link: https://feature-engine.readthedocs.io/
-- title: idtracker.ai
- link-alt: idtracker.ai docs
+- title: idtracker.ai
+ link-alt: idtracker.ai docs
link: https://idtracker.ai/
- title: MegEngine
link-alt: MegEngine docs
diff --git a/docs/index.md b/docs/index.md
index 0e5562f93..c5f5d407f 100644
--- a/docs/index.md
+++ b/docs/index.md
@@ -21,13 +21,11 @@ A clean, Bootstrap-based Sphinx theme by and for [the PyData community](https://
- header: "{fas}`circle-half-stroke;pst-color-primary` Light / Dark theme"
content: "Users can toggle between light and dark themes interactively."
- header: "{fas}`palette;pst-color-primary` Customizable UI and themes"
- content: "Customize colors and branding with CSS variables, and build custom UIs with [Sphinx Design](user_guide/web-components)."
+ content: "Customize colors and branding with CSS variables, and build custom UIs with [Sphinx Design components](user_guide/web-components)."
- header: "{fab}`python;pst-color-primary` Supports PyData and Jupyter"
- content: "CSS and UI support for Jupyter extensions and PyData execution outputs."
- link: "examples/pydata.html"
+ content: "CSS and UI support for [Jupyter extensions](examples/execution) and [PyData execution outputs](examples/pydata.ipynb)."
- header: "{fas}`lightbulb;pst-color-primary` Example Gallery"
- content: "See our gallery of projects that use this theme."
- link: "examples/gallery.html"
+ content: "See [our gallery](examples/gallery.md) of projects that use this theme."
```
```{seealso}
diff --git a/docs/user_guide/accessibility.md b/docs/user_guide/accessibility.md
index 13cf9b1ed..01ca24329 100644
--- a/docs/user_guide/accessibility.md
+++ b/docs/user_guide/accessibility.md
@@ -33,6 +33,14 @@ page that lacks metadata, please open a pull request to add it!
- We have improved how we assign text colors to interactive elements such as buttons and dropdowns to ensure that they meet
WCAG 2 AA or AAA contrast requirements.
+### Keyboard Navigation Support
+
+For all buttons, dropdowns, tabbed panels, hamburger menus, modals, overlays,
+links and other interactive elements, we have worked to ensure they:
+
+- Have a visible focus indicator (WCAG 2.4.7)
+- Can be accessed via keyboard navigation (WCAG 2.1.1)
+
## What You Can Do
### Site configuration
diff --git a/docs/user_guide/styling.rst b/docs/user_guide/styling.rst
index 3e2df90a2..22136676d 100644
--- a/docs/user_guide/styling.rst
+++ b/docs/user_guide/styling.rst
@@ -117,18 +117,18 @@ Here is an overview of the colors available in the theme (change theme mode to s
- primary
- secondary
- accent
- success
- info
- warning
- danger
- background
- on-background
- surface
- on-surface
- target
+ primary
+ secondary
+ accent
+ success
+ info
+ warning
+ danger
+ background
+ on-background
+ surface
+ on-surface
+ target
diff --git a/docs/user_guide/web-components.rst b/docs/user_guide/web-components.rst
index 8527d5e20..4df92256d 100644
--- a/docs/user_guide/web-components.rst
+++ b/docs/user_guide/web-components.rst
@@ -4,16 +4,31 @@
Sphinx Design Components
========================
-The PyData Sphinx Theme uses `sphinx-design `__
-to add several UI components and provide extra flexibility for content creation.
-These include badges, buttons, cards, and tabs, among other components.
-This theme provides custom CSS to ensure that `sphinx-design `__ elements look and feel consistent with this theme.
+On this page, you will find user interface components such as badges, buttons,
+cards, and tabs.
+
+The components on this page are **not provided by PyData Theme**. They are
+provided by `Sphinx Design _` (a Sphinx extension). This means that if you wish
+to use the components on this page, you must install Sphinx Design separately and add it to your `conf.py`.
.. seealso::
- For more information about how to use these extensions, see `the sphinx-design documentation `_.
+ To add the Sphinx Design extension to your Sphinx project, refer to `Sphinx
+ Design - Getting Started
+ `_.
+
+Contributors to both projects have worked to ensure compatible styling so that
+Sphinx Design components look and feel consistent with the PyData Theme.
+
+This page shows you how the Sphinx Design components would look on your site if
+you were to use them in combination with the PyData Theme. Sphinx Design also
+provides a `PyData-themed version of the Sphinx Design site
+ `__; however, their site
+use an older version of this theme.
-Below you can find some examples of the components created with the :code:`sphinx-design` extension.
+Any customizations you make to the theme could affect how these components
+appear on your site. So what you see on this page might not match exactly what
+you see on your site even if your site uses this theme.
.. _badges-buttons:
diff --git a/src/pydata_sphinx_theme/__init__.py b/src/pydata_sphinx_theme/__init__.py
index f2d227130..77ab0dc11 100644
--- a/src/pydata_sphinx_theme/__init__.py
+++ b/src/pydata_sphinx_theme/__init__.py
@@ -194,6 +194,18 @@ def update_and_remove_templates(
if asset_path == theme_css_name:
del context["css_files"][i]
break
+ # Add links for favicons in the topbar
+ for favicon in context.get("theme_favicons", []):
+ icon_type = Path(favicon["href"]).suffix.strip(".")
+ opts = {
+ "rel": favicon.get("rel", "icon"),
+ "sizes": favicon.get("sizes", "16x16"),
+ "type": f"image/{icon_type}",
+ }
+ if "color" in favicon:
+ opts["color"] = favicon["color"]
+ # Sphinx will auto-resolve href if it's a local file
+ app.add_css_file(favicon["href"], **opts)
# Add metadata to DOCUMENTATION_OPTIONS so that we can re-use later
# Pagename to current page
diff --git a/src/pydata_sphinx_theme/assets/scripts/pydata-sphinx-theme.js b/src/pydata_sphinx_theme/assets/scripts/pydata-sphinx-theme.js
index 0dcc6ae42..e15194550 100644
--- a/src/pydata_sphinx_theme/assets/scripts/pydata-sphinx-theme.js
+++ b/src/pydata_sphinx_theme/assets/scripts/pydata-sphinx-theme.js
@@ -489,7 +489,7 @@ function showVersionWarningBanner(data) {
middle.classList = "bd-header-announcement__content";
inner.classList = "sidebar-message";
button.classList =
- "sd-btn sd-btn-danger sd-shadow-sm sd-text-wrap font-weight-bold ms-3 my-1 align-baseline";
+ "btn text-wrap font-weight-bold ms-3 my-1 align-baseline pst-button-link-to-stable-version";
button.href = `${preferredURL}${DOCUMENTATION_OPTIONS.pagename}.html`;
button.innerText = "Switch to stable version";
button.onclick = checkPageExistsAndRedirect;
@@ -609,6 +609,89 @@ function fixMoreLinksInMobileSidebar() {
}
}
+/*******************************************************************************
+ * Add keyboard functionality to mobile sidebars.
+ *
+ * Wire up the hamburger-style buttons using the click event which (on buttons)
+ * handles both mouse clicks and the space and enter keys.
+ */
+function setupMobileSidebarKeyboardHandlers() {
+ // These are hidden checkboxes at the top of the page whose :checked property
+ // allows the mobile sidebars to be hidden or revealed via CSS.
+ const primaryToggle = document.getElementById("pst-primary-sidebar-checkbox");
+ const secondaryToggle = document.getElementById(
+ "pst-secondary-sidebar-checkbox"
+ );
+ const primarySidebar = document.querySelector(".bd-sidebar-primary");
+ const secondarySidebar = document.querySelector(".bd-sidebar-secondary");
+
+ // Toggle buttons -
+ //
+ // These are the hamburger-style buttons in the header nav bar. When the user
+ // clicks, the button transmits the click to the hidden checkboxes used by the
+ // CSS to control whether the sidebar is open or closed.
+ const primaryClickTransmitter = document.querySelector(".primary-toggle");
+ const secondaryClickTransmitter = document.querySelector(".secondary-toggle");
+ [
+ [primaryClickTransmitter, primaryToggle, primarySidebar],
+ [secondaryClickTransmitter, secondaryToggle, secondarySidebar],
+ ].forEach(([clickTransmitter, toggle, sidebar]) => {
+ if (!clickTransmitter) {
+ return;
+ }
+ clickTransmitter.addEventListener("click", (event) => {
+ event.preventDefault();
+ event.stopPropagation();
+ toggle.checked = !toggle.checked;
+
+ // If we are opening the sidebar, move focus to the first focusable item
+ // in the sidebar
+ if (toggle.checked) {
+ // Note: this selector is not exhaustive, and we may need to update it
+ // in the future
+ const tabStop = sidebar.querySelector("a, button");
+ // use setTimeout because you cannot move focus synchronously during a
+ // click in the handler for the click event
+ setTimeout(() => tabStop.focus(), 100);
+ }
+ });
+ });
+
+ // Escape key -
+ //
+ // When sidebar is open, user should be able to press escape key to close the
+ // sidebar.
+ [
+ [primarySidebar, primaryToggle, primaryClickTransmitter],
+ [secondarySidebar, secondaryToggle, secondaryClickTransmitter],
+ ].forEach(([sidebar, toggle, transmitter]) => {
+ if (!sidebar) {
+ return;
+ }
+ sidebar.addEventListener("keydown", (event) => {
+ if (event.key === "Escape") {
+ event.preventDefault();
+ event.stopPropagation();
+ toggle.checked = false;
+ transmitter.focus();
+ }
+ });
+ });
+
+ // When the overlay is clicked to close the sidebar, return focus to
+ // the opener button in the nav bar.
+ [
+ [primaryToggle, primaryClickTransmitter],
+ [secondaryToggle, secondaryClickTransmitter],
+ ].forEach(([toggle, transmitter]) => {
+ toggle.addEventListener("change", (event) => {
+ if (!event.currentTarget.checked) {
+ transmitter.focus();
+ }
+ });
+ });
+}
+
/*******************************************************************************
* Call functions after document loading.
*/
@@ -618,4 +701,5 @@ documentReady(scrollToActive);
documentReady(addTOCInteractivity);
documentReady(setupSearchButtons);
documentReady(initRTDObserver);
+documentReady(setupMobileSidebarKeyboardHandlers);
documentReady(fixMoreLinksInMobileSidebar);
diff --git a/src/pydata_sphinx_theme/assets/styles/abstracts/_links.scss b/src/pydata_sphinx_theme/assets/styles/abstracts/_links.scss
index f3fe96be1..82f6e48ef 100644
--- a/src/pydata_sphinx_theme/assets/styles/abstracts/_links.scss
+++ b/src/pydata_sphinx_theme/assets/styles/abstracts/_links.scss
@@ -86,7 +86,6 @@ $link-hover-decoration-thickness: unquote("max(3px, .1875rem, .12em)") !default;
color: var(--pst-color-link-hover);
}
}
- @include focus-indicator;
}
// Text link styles
@@ -102,7 +101,6 @@ $link-hover-decoration-thickness: unquote("max(3px, .1875rem, .12em)") !default;
@include link-decoration;
@include link-decoration-hover;
}
- @include focus-indicator;
}
// Sidebar and TOC links
@@ -125,6 +123,12 @@ $link-hover-decoration-thickness: unquote("max(3px, .1875rem, .12em)") !default;
&:active {
color: var(--pst-color-link-hover);
}
+
+ &:focus-visible {
+ box-shadow: $focus-ring-box-shadow;
+ outline: none;
+ z-index: 10; // keep focus ring on top (prevent the link-sidebar-current notch from lying on top of the ring)
+ }
}
// Sidebar current page link styles
@@ -137,11 +141,16 @@ $link-hover-decoration-thickness: unquote("max(3px, .1875rem, .12em)") !default;
font-weight: 600;
color: var(--pst-color-primary);
@if $link-hover-decoration-thickness {
- box-shadow: inset
+ $notch-shadow: inset
$link-hover-decoration-thickness
0px
0px
var(--pst-color-primary);
+ box-shadow: $notch-shadow;
+ &:focus-visible {
+ box-shadow: $notch-shadow, $focus-ring-box-shadow;
+ outline: none;
+ }
}
}
@@ -176,9 +185,84 @@ $link-hover-decoration-thickness: unquote("max(3px, .1875rem, .12em)") !default;
}
}
-// Focus indicator
-@mixin focus-indicator {
- &:focus-visible {
- outline: 2px solid var(--pst-color-accent);
+/*
+Mixin for links in the header (and the More dropdown toggle).
+
+The mixin assumes it will be applied to some element X with a markup structure
+like: X > .nav-link, or X > .dropdown-toggle.
+
+It also assumes X.current is how the app annotates which item in the header nav
+corresponds to the section in the docs that the user is currently reading.
+*/
+@mixin header-link {
+ // Target the child and not the parent because we want the underline in the
+ // mobile sidebar to only span the width of the text not the entire row/line.
+ > .nav-link,
+ > .dropdown-toggle {
+ border-radius: 2px;
+ color: var(--pst-color-text-muted);
+ }
+
+ > .nav-link {
+ // Set up pseudo-element for hover and current states below.
+ position: relative;
+ &::before {
+ content: "";
+ display: block;
+ position: absolute;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ left: 0;
+ background-color: transparent;
+ }
+
+ // Underline on hover.
+ // - Don't use text-decoration because it will wrap across two lines if
+ // the link text also wraps across two lines.
+ // - Use pseudo-element in order to avoid the border-radius values
+ // rounding the edges of the underline. (And since a header link can be
+ // both focused and hovered at the same time and we want the focus ring
+ // but not the underline to be rounded, we cannot use a box shadow or
+ // bottom border link element to create the underline, or else it will
+ // be rounded and if we apply border-radius 0 then the hovered focus
+ // ring would go from rounded to sharp. So we have to use the
+ // pseudo-element.)
+ &:hover {
+ color: var(--pst-color-secondary);
+ text-decoration: none; // override the link-style-hover mixin
+ &::before {
+ border-bottom: 3px solid var(--pst-color-secondary);
+ }
+ }
+
+ &:focus-visible {
+ box-shadow: none; // override Bootstrap
+ outline: 3px solid var(--pst-color-accent);
+ outline-offset: 3px;
+ }
+ }
+
+ > .dropdown-toggle {
+ &:focus-visible {
+ box-shadow: $focus-ring-box-shadow;
+ }
+ &:hover {
+ text-decoration: none;
+ box-shadow: 0 0 0 $focus-ring-width var(--pst-color-link-hover); // purple focus ring
+ // Brighten the text on hover (muted -> base)
+ color: var(--pst-color-text-base);
+ }
+ }
+
+ &.current {
+ > .nav-link {
+ color: var(--pst-color-primary);
+
+ // Underline the current navbar item
+ &::before {
+ border-bottom: 3px solid var(--pst-color-primary);
+ }
+ }
}
}
diff --git a/src/pydata_sphinx_theme/assets/styles/base/_base.scss b/src/pydata_sphinx_theme/assets/styles/base/_base.scss
index f3a3a7ca0..ae4b2675e 100644
--- a/src/pydata_sphinx_theme/assets/styles/base/_base.scss
+++ b/src/pydata_sphinx_theme/assets/styles/base/_base.scss
@@ -178,4 +178,34 @@ pre {
color: var(--pst-color-secondary-text);
background-color: var(--pst-color-secondary);
border: none;
+
+ .fa-arrow-up {
+ // Using margin instead of a space character prevents the space between the
+ // icon and the text from being underlined when the button is hovered.
+ margin-inline-end: 0.5em;
+ }
+
+ @include link-style-hover;
+ &:hover {
+ text-decoration-thickness: 1px;
+ background-color: var(--pst-violet-600);
+ color: var(--pst-color-secondary-text);
+ }
+
+ &:focus-visible {
+ box-shadow: none;
+ outline: $focus-ring-outline;
+ outline-color: var(--pst-color-secondary);
+ outline-offset: $focus-ring-width;
+ }
+}
+
+// Focus ring
+//
+// Note: The Bootstrap stylesheet provides the focus ring (customized by this
+// theme via Sass variables in _bootstrap.scss) in some cases. This rule covers
+// all other cases.
+:focus-visible {
+ outline: $focus-ring-outline;
+ box-shadow: none; // override Bootstrap
}
diff --git a/src/pydata_sphinx_theme/assets/styles/components/_icon-links.scss b/src/pydata_sphinx_theme/assets/styles/components/_icon-links.scss
index 3c23f0d63..b8ec00c22 100644
--- a/src/pydata_sphinx_theme/assets/styles/components/_icon-links.scss
+++ b/src/pydata_sphinx_theme/assets/styles/components/_icon-links.scss
@@ -14,6 +14,9 @@
padding-left: 0;
padding-right: 0;
@include icon-navbar-hover;
+ &:focus {
+ color: inherit;
+ }
}
// Spacing and centering
@@ -51,4 +54,10 @@
height: 1.5em;
border-radius: 0.2rem;
}
+
+ .fa-pydata {
+ stroke: var(--pst-color-background);
+ stroke-linejoin: round;
+ stroke-width: 0.35;
+ }
}
diff --git a/src/pydata_sphinx_theme/assets/styles/components/_navbar-links.scss b/src/pydata_sphinx_theme/assets/styles/components/_navbar-links.scss
index a02aefeaf..4bfd7f323 100644
--- a/src/pydata_sphinx_theme/assets/styles/components/_navbar-links.scss
+++ b/src/pydata_sphinx_theme/assets/styles/components/_navbar-links.scss
@@ -26,30 +26,4 @@
@include link-style-text;
}
}
-
- /**
- * Togglable expand/collapse
- * This is only applicable to the primary sidebar which has these checkboxes
- */
- .toctree-checkbox {
- position: absolute;
- display: none;
- }
-
- .toctree-checkbox {
- ~ ul {
- display: none;
- }
- ~ label .fa-chevron-down {
- transform: rotate(0deg);
- }
- }
- .toctree-checkbox:checked {
- ~ ul {
- display: block;
- }
- ~ label .fa-chevron-down {
- transform: rotate(180deg);
- }
- }
}
diff --git a/src/pydata_sphinx_theme/assets/styles/components/_search.scss b/src/pydata_sphinx_theme/assets/styles/components/_search.scss
index 7a71894a3..4dad106aa 100644
--- a/src/pydata_sphinx_theme/assets/styles/components/_search.scss
+++ b/src/pydata_sphinx_theme/assets/styles/components/_search.scss
@@ -58,8 +58,6 @@
&:focus,
&:focus-visible {
border: none;
- box-shadow: none;
- outline: 3px solid var(--pst-color-accent);
background-color: var(--pst-color-background);
color: var(--pst-color-text-muted);
}
@@ -77,8 +75,15 @@
color: var(--pst-color-text-muted);
padding: 0;
border-radius: 0;
+ border: none; // Override Bootstrap button border
+ font-size: 1rem; // Override Bootstrap button font size
+
+ // Override Bootstrap button padding-x. Whitespace in nav bar is controlled
+ // via column gap rule on the container.
+ padding-left: 0;
+ padding-right: 0;
+
@include icon-navbar-hover;
- @include focus-indicator;
i {
font-size: 1.3rem;
@@ -135,19 +140,21 @@
* Lives at components/search-button-field.html
*/
.search-button-field {
+ $search-button-border-radius: 1.5em;
display: inline-flex;
align-items: center;
border: var(--pst-color-border) solid 1px;
- border-radius: 1.5em;
+ border-radius: $search-button-border-radius;
color: var(--pst-color-text-muted);
padding: 0.5em;
background-color: var(--pst-color-surface);
&:hover {
- border: 2px solid var(--pst-color-link-hover);
+ box-shadow: 0 0 0 $focus-ring-width var(--pst-color-link-hover);
}
+
&:focus-visible {
- border: 2px solid var(--pst-color-accent);
+ border-radius: $search-button-border-radius;
}
// The keyboard shotcut text
diff --git a/src/pydata_sphinx_theme/assets/styles/components/_switcher-theme.scss b/src/pydata_sphinx_theme/assets/styles/components/_switcher-theme.scss
index f723e0eb8..838afb268 100644
--- a/src/pydata_sphinx_theme/assets/styles/components/_switcher-theme.scss
+++ b/src/pydata_sphinx_theme/assets/styles/components/_switcher-theme.scss
@@ -3,18 +3,23 @@
*/
.theme-switch-button {
- // overide bootstrap settings
- margin: 0 -0.5rem;
- padding: 0; // We pad the `span` not the container
color: var(--pst-color-text-muted);
border-radius: 0;
- @include focus-indicator;
+ border: none; // Override Bootstrap button border
+ font-size: 1rem; // Override Bootstrap's button font size
+
+ // Override Bootstrap button padding-x. Whitespace in nav bar is controlled
+ // via column gap rule on the container.
+ padding-left: 0;
+ padding-right: 0;
+
+ &:hover {
+ @include icon-navbar-hover;
+ }
span {
display: none;
- padding: 0.5em;
- @include icon-navbar-hover;
&:active {
text-decoration: none;
color: var(--pst-color-link-hover);
diff --git a/src/pydata_sphinx_theme/assets/styles/components/_switcher-version.scss b/src/pydata_sphinx_theme/assets/styles/components/_switcher-version.scss
index 84baed7a7..d6281bf51 100644
--- a/src/pydata_sphinx_theme/assets/styles/components/_switcher-version.scss
+++ b/src/pydata_sphinx_theme/assets/styles/components/_switcher-version.scss
@@ -6,13 +6,17 @@ button.btn.version-switcher__button {
@include media-breakpoint-up($breakpoint-sidebar-primary) {
margin-bottom: unset;
}
-
- @include link-style-hover;
- @include focus-indicator;
+ &:hover {
+ box-shadow: 0 0 0 $focus-ring-width var(--pst-color-secondary);
+ border-color: transparent;
+ }
&:active {
color: var(--pst-color-text-base);
border-color: var(--pst-color-border);
}
+ &:focus-visible {
+ border-color: transparent;
+ }
}
.version-switcher__menu {
@@ -46,6 +50,9 @@ button.btn.version-switcher__button {
top: 0;
}
}
+ &:focus-visible {
+ z-index: 10; // keep focus ring on top (prevent the hover background of the next dropdown item from covering the ring)
+ }
}
}
diff --git a/src/pydata_sphinx_theme/assets/styles/components/_toc-inpage.scss b/src/pydata_sphinx_theme/assets/styles/components/_toc-inpage.scss
index 01db3945c..7bfc028c2 100644
--- a/src/pydata_sphinx_theme/assets/styles/components/_toc-inpage.scss
+++ b/src/pydata_sphinx_theme/assets/styles/components/_toc-inpage.scss
@@ -6,8 +6,7 @@ nav.page-toc {
margin-bottom: 1rem;
}
-.bd-toc .nav,
-.list-caption {
+.bd-toc .nav {
.nav {
display: none;
@@ -47,5 +46,9 @@ nav.page-toc {
color: var(--pst-color-link-hover);
}
}
+
+ &:focus-visible {
+ border-radius: $focus-ring-radius;
+ }
}
}
diff --git a/src/pydata_sphinx_theme/assets/styles/content/_admonitions.scss b/src/pydata_sphinx_theme/assets/styles/content/_admonitions.scss
index 74b5589aa..9a316c7d3 100644
--- a/src/pydata_sphinx_theme/assets/styles/content/_admonitions.scss
+++ b/src/pydata_sphinx_theme/assets/styles/content/_admonitions.scss
@@ -3,13 +3,14 @@
* Admonitions CSS originally inspired by https://squidfunk.github.io/mkdocs-material/getting-started/
*/
$admonition-border-radius: 0.25rem;
+$admonition-left-border-width: 0.2rem;
div.admonition,
.admonition {
margin: 1.5625em auto;
padding: 0 0.6rem 0.8rem 0.6rem;
overflow: hidden;
page-break-inside: avoid;
- border-left: 0.2rem solid;
+ border-left: $admonition-left-border-width solid;
border-color: var(--pst-color-info);
border-radius: $admonition-border-radius;
background-color: var(--pst-color-on-background);
@@ -205,7 +206,7 @@ div.admonition,
margin-top: 0;
// Undo the .sidebar directive border
- border-width: 0 0 0 0.2rem;
+ border-width: 0 0 0 $admonition-left-border-width;
// TODO: these semantic-color-names border-color rules might no longer be
// needed when we drop support for Sphinx 4 / docutils 0.17
diff --git a/src/pydata_sphinx_theme/assets/styles/extensions/_copybutton.scss b/src/pydata_sphinx_theme/assets/styles/extensions/_copybutton.scss
index be6c887f7..859dc78de 100644
--- a/src/pydata_sphinx_theme/assets/styles/extensions/_copybutton.scss
+++ b/src/pydata_sphinx_theme/assets/styles/extensions/_copybutton.scss
@@ -31,4 +31,13 @@ div.highlight button.copybtn {
color: var(--pst-color-text);
background-color: var(--pst-color-surface);
}
+
+ &:focus {
+ // For keyboard users, make the copy button visible when focussed.
+ opacity: 1;
+ }
+
+ &:focus-visible {
+ outline: $focus-ring-outline;
+ }
}
diff --git a/src/pydata_sphinx_theme/assets/styles/extensions/_sphinx_design.scss b/src/pydata_sphinx_theme/assets/styles/extensions/_sphinx_design.scss
index 2ebfb4d4e..66bdfdbfb 100644
--- a/src/pydata_sphinx_theme/assets/styles/extensions/_sphinx_design.scss
+++ b/src/pydata_sphinx_theme/assets/styles/extensions/_sphinx_design.scss
@@ -149,6 +149,22 @@ html[data-theme="light"] {
.sd-card-body {
background-color: var(--pst-color-panel-background);
}
+
+ // Focus ring for link-cards
+ .sd-stretched-link:focus-visible {
+ // Don't put the focus ring on the element (it has zero height in Sphinx Design cards)
+ outline: none;
+
+ // Put the focus ring on the element's ::after pseudo-element
+ &:after {
+ outline: $focus-ring-outline;
+ border-radius: 0.25rem; // copied from Sphinx Design CSS for .sd-card
+ }
+ }
+
+ &.sd-card-hover:hover {
+ border-color: var(--pst-color-link-hover);
+ }
}
/*******************************************************************************
* tabs
@@ -158,28 +174,53 @@ html[data-theme="light"] {
> input {
// Active tab label
&:checked + label {
- border-color: transparent transparent var(--pst-color-primary); // top LR bottom
+ border-style: solid solid none;
+ border-color: var(--pst-color-primary) var(--pst-color-primary)
+ transparent; // top LR bottom
+ border-width: 0.125rem 0.125rem 0;
+ border-radius: 0.125rem 0.125rem 0 0;
+ background-color: var(--pst-color-on-background);
+ transform: translateY(0.125rem);
color: var(--pst-color-primary);
}
+ &:focus-visible + label {
+ border: 0.125rem solid var(--pst-color-accent);
+ border-radius: 0.125rem;
+ background-color: var(--pst-color-accent-bg);
+ color: var(--pst-color-on-surface);
+ }
+
// Hover label
- &:not(:checked) + label:hover {
- border-color: var(--pst-color-secondary);
+ &:not(:checked):not(:focus-visible) + label:hover {
+ border-color: transparent;
color: var(--pst-color-secondary);
}
}
// Tab label
> label {
- color: var(--pst-color-text-muted);
- border-top: 0.125rem solid transparent; // so hover isn't just color change
- padding-top: 0.5em; // same as bottom padding, so hover overline looks OK
- // Hovered label
- html &:hover {
- color: var(--pst-color-secondary);
- border-color: var(--pst-color-secondary);
+ color: var(--pst-color-on-surface);
+ border: 0.125rem solid transparent;
+ border-radius: 0.125rem 0.125rem 0px 0px;
+ background-color: var(--pst-color-surface);
+ padding: 0 0.75em;
+ margin-inline-end: 0.25rem;
+ line-height: 1.95;
+
+ html[data-theme="dark"] & {
+ background-color: var(--pst-color-on-background);
}
}
+
+ // panel
+ .sd-tab-content {
+ border: 0.125rem solid var(--pst-color-primary);
+ border-radius: 0.1875rem;
+ box-shadow: unset;
+ padding: 0.625rem;
+ background-color: var(--pst-color-on-background);
+ }
}
/*******************************************************************************
@@ -255,5 +296,43 @@ details.sd-dropdown {
.sd-summary-down {
top: 0.7rem;
}
+
+ // Focus ring
+ &:focus-visible {
+ outline: $focus-ring-outline;
+ outline-offset: -$focus-ring-width;
+ }
+ }
+}
+
+/*******************************************************************************
+* Buttons (which in Sphinx Design are actually links that look like buttons)
+* ref: https://sphinx-design.readthedocs.io/en/pydata-theme/badges_buttons.html#buttons
+*/
+html {
+ .sd-btn {
+ min-width: 2.25rem;
+ padding: 0.3125rem 0.75rem 0.4375rem; // 5px 12px 7px
+
+ @include link-style-hover; // override Sphinx Design
+ &:hover {
+ text-decoration-thickness: 1px;
+ }
+ }
+
+ @each $name in $sd-semantic-color-names {
+ .sd-btn-#{$name},
+ .sd-btn-outline-#{$name} {
+ &:focus-visible {
+ // Override Sphinx Design's use of -highlight colors. The -highlight
+ // colors are 15% darker, so this would create the effect of darkening
+ // the button when focused but we just want the button to have a focus
+ // ring of the same (non-highlight) color.
+ background-color: var(--sd-color-#{$name}) !important;
+ border-color: var(--sd-color-#{$name}) !important;
+ outline: var(--sd-color-#{$name}) solid $focus-ring-width;
+ outline-offset: $focus-ring-width;
+ }
+ }
}
}
diff --git a/src/pydata_sphinx_theme/assets/styles/extensions/_togglebutton.scss b/src/pydata_sphinx_theme/assets/styles/extensions/_togglebutton.scss
index 9211b91ac..5013c0564 100644
--- a/src/pydata_sphinx_theme/assets/styles/extensions/_togglebutton.scss
+++ b/src/pydata_sphinx_theme/assets/styles/extensions/_togglebutton.scss
@@ -3,10 +3,69 @@
*/
.bd-content {
+ @mixin chevron-down {
+ .toggle-chevron-right {
+ transform: rotate(90deg); // point chevron down
+ transition: none; // match non-animated behavior of other chevrons on site
+ }
+ }
+
+ @mixin chevron-up {
+ .toggle-chevron-right {
+ transform: rotate(-90deg); // point chevron up
+ transition: none; // match non-animated behavior of other chevrons on site
+ }
+ }
+
// Admonition toggles
.admonition {
button.toggle-button {
color: inherit;
+
+ // When disclosure widget is closed
+ &.toggle-button-hidden {
+ @include chevron-down;
+ }
+
+ // When open
+ @include chevron-up;
+ }
+
+ // Focus ring
+ //
+ // Sphinx-togglebutton makes the entire admonition header clickable, but
+ // only the button within the header is focusable. We want the entire
+ // clickable area to be surrounded with a focus ring, so that's why we use
+ // the :focus-within selector, rather than a :focus-visible selector on the
+ // button.
+ &:focus-within {
+ overflow: visible;
+
+ // The complicated focus ring styles here are a consequence of the markup
+ // and border styles for this particular admonition class. (For the other
+ // type of admonition on this site, the focus ring style is achieved with
+ // simple `outline` and `outline-offset` rules on the admonition's
+ // header.) The problem is that Sphinx-togglebutton puts the admonition's
+ // left border on the outermost container (rather than separately setting
+ // the left border on the container's children). This makes it complicated
+ // to get the focus ring to simultaneously cover the left border in the
+ // header and align perfectly on the right with the body.
+ .admonition-title:focus-within:before {
+ content: "";
+ transform: translateX(
+ -$admonition-left-border-width
+ ); // align left edges of admonition and ring
+ width: calc(100% + $admonition-left-border-width); // align right edges
+ height: 100%;
+ border: $focus-ring-outline;
+ border-radius: $focus-ring-width;
+ }
+
+ // When expanded, sharpen the bottom left and right corners of the focus ring
+ &:not(.toggle-hidden) .admonition-title:focus-within:before {
+ border-bottom-left-radius: 0;
+ border-bottom-right-radius: 0;
+ }
}
}
@@ -15,6 +74,18 @@
// Over-ride border color to re-use our primary color
summary {
border-left: 3px solid var(--pst-color-primary);
+
+ @include chevron-down;
+ }
+
+ // When expanded, sharpen the bottom left and right corners of the focus ring
+ &[open] {
+ @include chevron-up;
+
+ :focus-visible {
+ border-bottom-left-radius: 0;
+ border-bottom-right-radius: 0;
+ }
}
}
}
diff --git a/src/pydata_sphinx_theme/assets/styles/sections/_announcement.scss b/src/pydata_sphinx_theme/assets/styles/sections/_announcement.scss
index 883087398..8fbc50b3c 100644
--- a/src/pydata_sphinx_theme/assets/styles/sections/_announcement.scss
+++ b/src/pydata_sphinx_theme/assets/styles/sections/_announcement.scss
@@ -33,6 +33,31 @@
a {
color: var(--pst-color-inline-code-links);
}
+
+ // The "Switch to stable version" link (styled like a button)
+ .pst-button-link-to-stable-version {
+ @include box-shadow();
+
+ $background-color: var(--pst-color-danger);
+ $hover-background-color: var(--pst-color-danger-highlight);
+ $color: var(--pst-color-danger-text);
+
+ background-color: $background-color;
+ border-color: $background-color;
+ color: $color;
+ border-radius: 0.25rem;
+
+ &:hover {
+ background-color: $hover-background-color;
+ border-color: $hover-background-color;
+ color: $color;
+ }
+
+ &:focus-visible {
+ outline: $focus-ring-width solid $background-color;
+ outline-offset: $focus-ring-width;
+ }
+ }
}
// Bg color is now defined in the theme color palette - using our secondary color
diff --git a/src/pydata_sphinx_theme/assets/styles/sections/_header.scss b/src/pydata_sphinx_theme/assets/styles/sections/_header.scss
index 0a7713a84..833d92811 100644
--- a/src/pydata_sphinx_theme/assets/styles/sections/_header.scss
+++ b/src/pydata_sphinx_theme/assets/styles/sections/_header.scss
@@ -28,6 +28,10 @@
padding-right: 1rem;
}
+ :focus-visible {
+ border-radius: $focus-ring-radius;
+ }
+
// These items will define the height of the header
.navbar-item {
height: var(--pst-header-height);
@@ -80,26 +84,33 @@
@include media-breakpoint-up($breakpoint-sidebar-primary) {
// Center align on wide screens so the dropdown button is centered properly
- align-items: center;
+ align-items: baseline;
}
- li a.nav-link {
- @include link-style-text;
+ li.pst-header-nav-item {
+ margin-inline: 2px; // breathing room so hover and focus styles do not overlap
+ &.dropdown {
+ margin-inline: 4px;
+ button {
+ padding-inline: 8px;
+ }
+ }
+ a {
+ padding-inline: 6px;
+ }
+ @include header-link;
}
- // Current page is always underlined in the navbar
- > .current > .nav-link {
- @include link-navbar-current;
+ li a.nav-link.dropdown-item {
+ @include link-style-text;
}
// Dropdowns for the extra links
.dropdown {
button {
display: unset;
- color: var(--pst-color-text-muted);
border: none;
@include link-style-hover;
- @include focus-indicator;
}
.dropdown-menu {
@@ -120,6 +131,10 @@
&:focus:not(:hover):not(:active) {
background-color: inherit;
}
+
+ &:focus-visible {
+ z-index: 10; // keep focus ring on top (prevent the hover background of the next dropdown item from covering the ring)
+ }
}
// Hide the menu unless show has been clicked
@@ -164,8 +179,8 @@
// Hide the header items on mobile
.bd-header {
- // Toggle labels
- label {
+ // Toggle buttons
+ button {
&.sidebar-toggle {
display: flex;
cursor: pointer;
@@ -174,6 +189,10 @@
color: var(--pst-color-muted);
margin-bottom: 0;
padding-bottom: 0.25rem;
+ background-color: inherit;
+ border: none;
+
+ @include icon-navbar-hover;
}
&.primary-toggle {
@@ -189,8 +208,6 @@
display: none;
}
}
- @include icon-navbar-hover;
- @include focus-indicator;
}
// Hide the navbar header items on mobile because they're in the sidebar
diff --git a/src/pydata_sphinx_theme/assets/styles/sections/_sidebar-primary.scss b/src/pydata_sphinx_theme/assets/styles/sections/_sidebar-primary.scss
index c8cfe75dc..f29d35309 100644
--- a/src/pydata_sphinx_theme/assets/styles/sections/_sidebar-primary.scss
+++ b/src/pydata_sphinx_theme/assets/styles/sections/_sidebar-primary.scss
@@ -3,6 +3,7 @@
* e.g., between-pages navigation.
*/
+$sidebar-padding-right: 1rem;
.bd-sidebar-primary {
display: flex;
flex-direction: column;
@@ -13,7 +14,7 @@
@include make-col(3);
// Borders padding and whitespace
- padding: 2rem 1rem 1rem 1rem;
+ padding: 2rem $sidebar-padding-right 1rem 1rem;
border-right: 1px solid var(--pst-color-border);
background-color: var(--pst-color-background);
overflow-y: auto;
@@ -23,6 +24,10 @@
font-size: var(--pst-sidebar-font-size);
}
+ :focus-visible {
+ border-radius: $focus-ring-radius;
+ }
+
// override bootstrap when navlink are displayed in the sidebar
.nav-link {
font-size: var(--pst-sidebar-font-size-mobile);
@@ -80,6 +85,26 @@
border: none;
background-color: inherit;
font-size: inherit;
+
+ .dropdown-item {
+ &:hover,
+ &:focus {
+ // In the mobile sidebar, the dropdown menu is inlined with the
+ // other links, which do not have background-color changes on hover
+ // and focus
+ background-color: unset;
+ }
+ }
+ }
+ }
+
+ .bd-navbar-elements {
+ .nav-link {
+ &:focus-visible {
+ box-shadow: none; // Override Bootstrap
+ outline: $focus-ring-outline;
+ outline-offset: $focus-ring-width;
+ }
}
}
@@ -93,7 +118,7 @@
.sidebar-header-items__end {
display: flex;
align-items: center;
- gap: 0.5rem;
+ gap: 1rem;
}
@include media-breakpoint-up($breakpoint-sidebar-primary) {
@@ -116,62 +141,107 @@
.list-caption {
list-style: none;
padding-left: 0px;
- }
- li {
- position: relative;
- // If it has children, add a bit more padding to wrap the content to avoid
- // overlapping with the
- &.has-children {
- > .reference {
- padding-right: 30px;
+
+ // Level 0 TOC heading is put inside the tag
+ // so let the tag take up more space
+ li.toctree-l0.has-children {
+ > details {
+ > summary {
+ position: relative;
+ height: auto;
+ width: auto;
+ display: flex;
+ justify-content: space-between;
+ align-items: baseline;
+
+ .toctree-toggle {
+ // Prevent toggle icon from getting squished by summary being a
+ // flexbox
+ flex: 0 0 auto;
+
+ // Make the level 0 chevron icon slightly bigger than descendant
+ // levels
+ .fa-chevron-down {
+ font-size: 1rem;
+ }
+ }
+ }
}
}
}
- // Navigation item chevrons
- label.toctree-toggle {
- position: absolute;
- top: 0;
- right: 0;
- height: 30px;
- width: 30px;
+ li.has-children {
+ $toctree-toggle-width: 30px;
- cursor: pointer;
+ position: relative;
- display: flex;
- justify-content: center;
align-items: center;
-
- &:hover {
- background-color: var(--pst-color-surface);
+ > .reference,
+ .caption {
+ margin-right: calc(
+ $toctree-toggle-width + $focus-ring-width
+ ); // keep clear of the toggle icon
+ padding-top: 0.25rem; // align caption text with toggle chevron
}
- i {
- display: inline-block;
- font-size: 0.75rem;
- text-align: center;
- &:hover {
- color: var(--pst-color-primary);
+ > details {
+ > summary {
+ // Remove browser default toggle icon
+ list-style: none;
+ &::-webkit-details-marker {
+ display: none;
+ }
+
+ // The summary element is natively focusable, but delegate the focus state to the toggle icon
+ &:focus-visible {
+ outline: none;
+
+ > .toctree-toggle {
+ outline: $focus-ring-outline;
+ outline-offset: -$focus-ring-width; // Prevent right side of focus ring from disappearing underneath the sidebar's right edge
+ }
+ }
+
+ // Container for expand/collapse chevron icon
+ .toctree-toggle {
+ cursor: pointer;
+
+ // Position it so that it's aligned with the top right corner of the
+ // last positioned element, in this case the li.has-children
+ position: absolute;
+ top: 0;
+ right: 0;
+
+ // Give it dimensions
+ width: $toctree-toggle-width;
+ height: $toctree-toggle-width; // make it square
+
+ // Vertically and horizontally center the icon within the container
+ display: inline-flex;
+ justify-content: center;
+ align-items: center;
+
+ .fa-chevron-down {
+ font-size: 0.75rem;
+ }
+ }
+ }
+
+ // The section is open/expanded, rotate the toggle icon (chevron) so it
+ // points up instead of down
+ &[open] {
+ > summary {
+ .fa-chevron-down {
+ transform: rotate(180deg);
+ }
+ }
}
- }
- }
- .label-parts {
- width: 100%;
- height: 100%;
- &:hover {
- background-color: none;
- }
- i {
- width: 30px;
- position: absolute;
- top: 0.3em; // aligning chevron with text
- right: 0em; // aligning chevron to the right
}
}
}
/* Between-page links and captions */
nav.bd-links {
- margin-right: -1rem;
+ margin-right: -$sidebar-padding-right; // align toctree toggle chevrons with right edge of sidebar and allow text to flow closer to the right edge
@include media-breakpoint-up($breakpoint-sidebar-primary) {
display: block;
@@ -191,6 +261,7 @@ nav.bd-links {
padding: 0.25rem 0.65rem;
@include link-sidebar;
box-shadow: none;
+ margin-right: $focus-ring-width; // prevent the right side focus ring from disappearing under the sidebar right edge
&.reference.external {
&:after {
@@ -202,11 +273,9 @@ nav.bd-links {
}
}
- .current {
- > a {
- @include link-sidebar-current;
- background-color: transparent;
- }
+ .current > a {
+ @include link-sidebar-current;
+ background-color: transparent;
}
// Title
diff --git a/src/pydata_sphinx_theme/assets/styles/sections/_sidebar-toggle.scss b/src/pydata_sphinx_theme/assets/styles/sections/_sidebar-toggle.scss
index 95657b53b..be4a3187b 100644
--- a/src/pydata_sphinx_theme/assets/styles/sections/_sidebar-toggle.scss
+++ b/src/pydata_sphinx_theme/assets/styles/sections/_sidebar-toggle.scss
@@ -28,20 +28,22 @@ label.overlay {
input {
// Show the correct overlay when its input is checked
- __primary:checked + label.overlay.overlay-primary,
- __secondary:checked + label.overlay.overlay-secondary {
+ pst-primary-sidebar-checkbox:checked + label.overlay.overlay-primary,
+ pst-secondary-sidebar-checkbox:checked + label.overlay.overlay-secondary {
height: 100vh;
width: 100vw;
}
// Primary sidebar slides in from the left
- __primary:checked ~ .bd-container .bd-sidebar-primary {
+ pst-primary-sidebar-checkbox:checked ~ .bd-container .bd-sidebar-primary {
visibility: visible;
margin-left: 0;
}
// Secondary sidebar slides in from the right
- __secondary:checked ~ .bd-container .bd-sidebar-secondary {
+ pst-secondary-sidebar-checkbox:checked
+ ~ .bd-container
+ .bd-sidebar-secondary {
visibility: visible;
margin-right: 0;
}
@@ -82,11 +84,11 @@ input {
// Primary sidebar hides/shows at earlier widths
@include media-breakpoint-up($breakpoint-sidebar-primary) {
- label.sidebar-toggle.primary-toggle {
+ .sidebar-toggle.primary-toggle {
display: none;
}
- input#__primary {
+ input#pst-primary-sidebar-checkbox {
&:checked + label.overlay.overlay-primary {
height: 0;
width: 0;
diff --git a/src/pydata_sphinx_theme/assets/styles/sections/_skip-link.scss b/src/pydata_sphinx_theme/assets/styles/sections/_skip-link.scss
index 2252ffb44..b82f94506 100644
--- a/src/pydata_sphinx_theme/assets/styles/sections/_skip-link.scss
+++ b/src/pydata_sphinx_theme/assets/styles/sections/_skip-link.scss
@@ -1,6 +1,6 @@
/***
- * Rules for the UX/UI of skip navigation link btn.
- *It's only visible to people
+ * Rules for the UX/UI of skip navigation link btn.
+ * It's only visible to people
* navigating with keyboard for accessibility purposes
* ref: https://www.youtube.com/watch?v=VUR0I5mqq7I
***/
@@ -12,8 +12,6 @@
right: 0;
text-align: center;
background-color: var(--pst-color-warning);
- // Ensure we are using a WCAG conformant colour
- color: var(--pst-color-warning-text) !important;
padding: 0.5rem;
z-index: $zindex-modal;
border-bottom: 1px solid var(--pst-color-border);
@@ -21,9 +19,17 @@
// This shows / hides the button
transform: translateY(-100%);
transition: transform 150ms ease-in-out;
- &:focus {
+ &:focus-within {
transform: translateY(0%);
- // ensure this is visible
- outline: 3px solid $foundation-black;
+ }
+
+ a {
+ // Ensure we are using a WCAG conformant colour
+ color: var(--pst-color-warning-text) !important;
+
+ &:focus-visible {
+ // use color with sufficient contrast
+ outline-color: $foundation-black;
+ }
}
}
diff --git a/src/pydata_sphinx_theme/assets/styles/variables/_bootstrap.scss b/src/pydata_sphinx_theme/assets/styles/variables/_bootstrap.scss
index 8cf8303d6..ded367106 100644
--- a/src/pydata_sphinx_theme/assets/styles/variables/_bootstrap.scss
+++ b/src/pydata_sphinx_theme/assets/styles/variables/_bootstrap.scss
@@ -22,3 +22,16 @@ $dropdown-link-hover-bg: var(--pst-color-surface);
$dropdown-dark-link-hover-bg: var(--pst-color-surface);
$dropdown-link-active-bg: var(--pst-color-surface);
$dropdown-dark-link-active-bg: var(--pst-color-surface);
+
+$focus-ring-width: 0.1875rem; // 3px at 100% zoom (0.1875 * 16px base font = 3px)
+$focus-ring-opacity: 1;
+$focus-ring-color: var(--pst-color-accent);
+$focus-ring-blur: 0;
+$focus-ring-box-shadow: 0 0 $focus-ring-blur $focus-ring-width $focus-ring-color;
+// outline creates the same style of focus ring, it just uses CSS outline instead of box shadow
+$focus-ring-outline: $focus-ring-color solid $focus-ring-width;
+$btn-focus-box-shadow: $focus-ring-box-shadow;
+
+.btn {
+ --bs-btn-focus-box-shadow: #{$btn-focus-box-shadow};
+}
diff --git a/src/pydata_sphinx_theme/assets/styles/variables/_layout.scss b/src/pydata_sphinx_theme/assets/styles/variables/_layout.scss
index 54e63cabd..1fbd63d8b 100644
--- a/src/pydata_sphinx_theme/assets/styles/variables/_layout.scss
+++ b/src/pydata_sphinx_theme/assets/styles/variables/_layout.scss
@@ -31,3 +31,7 @@ $animation-time: 200ms;
* UI shaping and padding
*/
$admonition-border-radius: 0.25rem;
+
+// In this theme, some focus rings have rounded corners while others do not.
+// This variable sets the border radius for the rounded focus rings.
+$focus-ring-radius: 0.125rem; // 2px at 100% zoom and 16px base font.
diff --git a/src/pydata_sphinx_theme/locale/ca/LC_MESSAGES/sphinx.po b/src/pydata_sphinx_theme/locale/ca/LC_MESSAGES/sphinx.po
index c6c1e2c70..e0c157e97 100644
--- a/src/pydata_sphinx_theme/locale/ca/LC_MESSAGES/sphinx.po
+++ b/src/pydata_sphinx_theme/locale/ca/LC_MESSAGES/sphinx.po
@@ -2,31 +2,39 @@
# Copyright (C) 2023 PyData developers
# This file is distributed under the same license as the pydata-sphinx-theme
# project.
-#
+#
# Translators:
# Oriol Abril-Pla , 2023
# Cristhian Rivera, 2024
-#
msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
-"POT-Creation-Date: 2023-12-21 07:30-0700\n"
+"POT-Creation-Date: 2024-03-11 13:22-0500\n"
"PO-Revision-Date: 2023-04-14 14:57+0000\n"
"Last-Translator: Cristhian Rivera, 2024\n"
-"Language-Team: Catalan (https://app.transifex.com/12rambau/teams/166811/ca/)\n"
+"Language: ca\n"
+"Language-Team: Catalan "
+"(https://app.transifex.com/12rambau/teams/166811/ca/)\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: Babel 2.13.0\n"
-"Language: ca\n"
-"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:53
+#: docs/conf.py:94
+msgid "Click to expand"
+msgstr ""
+
+#: docs/conf.py:95
+msgid "Click to collapse"
+msgstr ""
+
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:39
msgid "Skip to main content"
msgstr "Salta al contingut principal"
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:64
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:51
msgid "Back to top"
msgstr "Torna a l'inici"
@@ -94,12 +102,8 @@ msgstr "Índex de Mòduls Python"
msgid "Last updated on %(last_updated)s."
msgstr "Última actualització el %(last_updated)s."
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-nav.html:6
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-nav.html:7
-msgid "Site Navigation"
-msgstr "Navegació del lloc"
-
#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/page-toc.html:8
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/sections/header.html:43
msgid "On this page"
msgstr "Continguts de la pàgina"
@@ -152,6 +156,11 @@ msgstr ""
"theme.readthedocs.io/en/stable/index.html\">Tema PyData Sphinx "
"%(theme_version)s."
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/sections/header.html:3
+#, fuzzy
+msgid "Site navigation"
+msgstr "Navegació del lloc"
+
#~ msgid "Breadcrumbs"
#~ msgstr "Rutes de navegació"
@@ -166,3 +175,4 @@ msgstr ""
#~ msgid "Twitter"
#~ msgstr "Twitter"
+
diff --git a/src/pydata_sphinx_theme/locale/cs/LC_MESSAGES/sphinx.po b/src/pydata_sphinx_theme/locale/cs/LC_MESSAGES/sphinx.po
index c5205e224..53e02074a 100644
--- a/src/pydata_sphinx_theme/locale/cs/LC_MESSAGES/sphinx.po
+++ b/src/pydata_sphinx_theme/locale/cs/LC_MESSAGES/sphinx.po
@@ -2,30 +2,39 @@
# Copyright (C) 2023 PyData developers
# This file is distributed under the same license as the pydata-sphinx-theme
# project.
-#
+#
# Translators:
# Jan Breuer , 2024
-#
msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
-"POT-Creation-Date: 2023-12-21 07:30-0700\n"
+"POT-Creation-Date: 2024-03-11 13:22-0500\n"
"PO-Revision-Date: 2023-04-14 14:57+0000\n"
"Last-Translator: Jan Breuer , 2024\n"
-"Language-Team: Czech (https://app.transifex.com/12rambau/teams/166811/cs/)\n"
+"Language: cs\n"
+"Language-Team: Czech "
+"(https://app.transifex.com/12rambau/teams/166811/cs/)\n"
+"Plural-Forms: nplurals=4; plural=(n == 1 && n % 1 == 0) ? 0 : (n >= 2 && "
+"n <= 4 && n % 1 == 0) ? 1: (n % 1 != 0 ) ? 2 : 3;\n"
"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: Babel 2.13.0\n"
-"Language: cs\n"
-"Plural-Forms: nplurals=4; plural=(n == 1 && n % 1 == 0) ? 0 : (n >= 2 && n <= 4 && n % 1 == 0) ? 1: (n % 1 != 0 ) ? 2 : 3;\n"
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:53
+#: docs/conf.py:94
+msgid "Click to expand"
+msgstr ""
+
+#: docs/conf.py:95
+msgid "Click to collapse"
+msgstr ""
+
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:39
msgid "Skip to main content"
msgstr "Přejít k hlavnímu obsahu"
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:64
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:51
msgid "Back to top"
msgstr "Zpět na začátek"
@@ -93,12 +102,8 @@ msgstr "Rejstřík modulů jazyka Python"
msgid "Last updated on %(last_updated)s."
msgstr "Aktualizováno dne %(last_updated)s."
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-nav.html:6
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-nav.html:7
-msgid "Site Navigation"
-msgstr "Navigace na stránce"
-
#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/page-toc.html:8
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/sections/header.html:43
msgid "On this page"
msgstr "Na této stránce"
@@ -151,6 +156,11 @@ msgstr ""
"theme.readthedocs.io/en/stable/index.html\">PyData Sphinx Theme "
"%(theme_version)s."
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/sections/header.html:3
+#, fuzzy
+msgid "Site navigation"
+msgstr "Navigace na stránce"
+
#~ msgid "Breadcrumbs"
#~ msgstr "Struktury"
@@ -165,3 +175,4 @@ msgstr ""
#~ msgid "Twitter"
#~ msgstr "Twitter"
+
diff --git a/src/pydata_sphinx_theme/locale/en/LC_MESSAGES/sphinx.po b/src/pydata_sphinx_theme/locale/en/LC_MESSAGES/sphinx.po
index 3a9ab3357..31dfdab88 100644
--- a/src/pydata_sphinx_theme/locale/en/LC_MESSAGES/sphinx.po
+++ b/src/pydata_sphinx_theme/locale/en/LC_MESSAGES/sphinx.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
-"POT-Creation-Date: 2023-12-21 07:30-0700\n"
+"POT-Creation-Date: 2024-03-11 13:22-0500\n"
"PO-Revision-Date: 2023-02-16 13:19-0500\n"
"Last-Translator: FULL NAME \n"
"Language: en\n"
@@ -18,11 +18,19 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: Babel 2.13.0\n"
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:53
+#: docs/conf.py:94
+msgid "Click to expand"
+msgstr ""
+
+#: docs/conf.py:95
+msgid "Click to collapse"
+msgstr ""
+
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:39
msgid "Skip to main content"
msgstr ""
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:64
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:51
msgid "Back to top"
msgstr ""
@@ -90,12 +98,8 @@ msgstr ""
msgid "Last updated on %(last_updated)s."
msgstr ""
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-nav.html:6
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-nav.html:7
-msgid "Site Navigation"
-msgstr ""
-
#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/page-toc.html:8
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/sections/header.html:43
msgid "On this page"
msgstr ""
@@ -143,6 +147,10 @@ msgid ""
"%(theme_version)s."
msgstr ""
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/sections/header.html:3
+msgid "Site navigation"
+msgstr ""
+
#~ msgid "Breadcrumbs"
#~ msgstr ""
@@ -158,3 +166,6 @@ msgstr ""
#~ msgid "Twitter"
#~ msgstr ""
+#~ msgid "Site Navigation"
+#~ msgstr ""
+
diff --git a/src/pydata_sphinx_theme/locale/es/LC_MESSAGES/sphinx.po b/src/pydata_sphinx_theme/locale/es/LC_MESSAGES/sphinx.po
index 13eb8880a..5f72aba17 100644
--- a/src/pydata_sphinx_theme/locale/es/LC_MESSAGES/sphinx.po
+++ b/src/pydata_sphinx_theme/locale/es/LC_MESSAGES/sphinx.po
@@ -2,31 +2,40 @@
# Copyright (C) 2023 PyData developers
# This file is distributed under the same license as the pydata-sphinx-theme
# project.
-#
+#
# Translators:
# Rambaud Pierrick , 2023
# Cristhian Rivera, 2024
-#
msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
-"POT-Creation-Date: 2023-12-21 07:30-0700\n"
+"POT-Creation-Date: 2024-03-11 13:22-0500\n"
"PO-Revision-Date: 2023-04-14 14:57+0000\n"
"Last-Translator: Cristhian Rivera, 2024\n"
-"Language-Team: Spanish (https://app.transifex.com/12rambau/teams/166811/es/)\n"
+"Language: es\n"
+"Language-Team: Spanish "
+"(https://app.transifex.com/12rambau/teams/166811/es/)\n"
+"Plural-Forms: nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 "
+"? 1 : 2;\n"
"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: Babel 2.13.0\n"
-"Language: es\n"
-"Plural-Forms: nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;\n"
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:53
+#: docs/conf.py:94
+msgid "Click to expand"
+msgstr ""
+
+#: docs/conf.py:95
+msgid "Click to collapse"
+msgstr ""
+
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:39
msgid "Skip to main content"
msgstr "Saltar al contenido principal"
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:64
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:51
msgid "Back to top"
msgstr "Volver arriba"
@@ -44,8 +53,7 @@ msgstr "Error"
#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/search.html:9
msgid "Please activate JavaScript to enable the search functionality."
-msgstr ""
-"Por favor, active JavaScript para habilitar la funcionalidad de búsqueda."
+msgstr "Por favor, active JavaScript para habilitar la funcionalidad de búsqueda."
#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/breadcrumbs.html:13
msgid "Breadcrumb"
@@ -95,12 +103,8 @@ msgstr "Índice de Módulos Python"
msgid "Last updated on %(last_updated)s."
msgstr "Actualizado por última vez en %(last_updated)s."
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-nav.html:6
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-nav.html:7
-msgid "Site Navigation"
-msgstr "Navegación del sitio"
-
#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/page-toc.html:8
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/sections/header.html:43
msgid "On this page"
msgstr "En esta página"
@@ -153,6 +157,11 @@ msgstr ""
"theme.readthedocs.io/en/stable/index.html\">Tema PyData Sphinx "
"%(theme_version)s."
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/sections/header.html:3
+#, fuzzy
+msgid "Site navigation"
+msgstr "Navegación del sitio"
+
#~ msgid "Breadcrumbs"
#~ msgstr "Migas de pan"
@@ -167,3 +176,4 @@ msgstr ""
#~ msgid "Twitter"
#~ msgstr "Twitter"
+
diff --git a/src/pydata_sphinx_theme/locale/fr/LC_MESSAGES/sphinx.po b/src/pydata_sphinx_theme/locale/fr/LC_MESSAGES/sphinx.po
index a0bbe2b65..5bc5b7753 100644
--- a/src/pydata_sphinx_theme/locale/fr/LC_MESSAGES/sphinx.po
+++ b/src/pydata_sphinx_theme/locale/fr/LC_MESSAGES/sphinx.po
@@ -2,30 +2,39 @@
# Copyright (C) 2023 PyData developers
# This file is distributed under the same license as the pydata-sphinx-theme
# project.
-#
+#
# Translators:
# Rambaud Pierrick , 2024
-#
msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
-"POT-Creation-Date: 2023-12-21 07:30-0700\n"
+"POT-Creation-Date: 2024-03-11 13:22-0500\n"
"PO-Revision-Date: 2023-04-14 14:57+0000\n"
"Last-Translator: Rambaud Pierrick , 2024\n"
-"Language-Team: French (https://app.transifex.com/12rambau/teams/166811/fr/)\n"
+"Language: fr\n"
+"Language-Team: French "
+"(https://app.transifex.com/12rambau/teams/166811/fr/)\n"
+"Plural-Forms: nplurals=3; plural=(n == 0 || n == 1) ? 0 : n != 0 && n % "
+"1000000 == 0 ? 1 : 2;\n"
"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: Babel 2.13.0\n"
-"Language: fr\n"
-"Plural-Forms: nplurals=3; plural=(n == 0 || n == 1) ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;\n"
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:53
+#: docs/conf.py:94
+msgid "Click to expand"
+msgstr ""
+
+#: docs/conf.py:95
+msgid "Click to collapse"
+msgstr ""
+
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:39
msgid "Skip to main content"
msgstr "Passer au contenu principal"
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:64
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:51
msgid "Back to top"
msgstr "Haut de page"
@@ -93,12 +102,8 @@ msgstr "Index des modules Python"
msgid "Last updated on %(last_updated)s."
msgstr "Mis à jour le %(last_updated)s."
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-nav.html:6
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-nav.html:7
-msgid "Site Navigation"
-msgstr "Navigation du site"
-
#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/page-toc.html:8
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/sections/header.html:43
msgid "On this page"
msgstr "Sur cette page"
@@ -151,6 +156,11 @@ msgstr ""
"theme.readthedocs.io/en/stable/index.html\">Thème PyData Sphinx "
"%(theme_version)s."
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/sections/header.html:3
+#, fuzzy
+msgid "Site navigation"
+msgstr "Navigation du site"
+
#~ msgid "Breadcrumbs"
#~ msgstr "Fils d'Ariane"
@@ -165,3 +175,4 @@ msgstr ""
#~ msgid "Twitter"
#~ msgstr "Twitter"
+
diff --git a/src/pydata_sphinx_theme/locale/ru/LC_MESSAGES/sphinx.po b/src/pydata_sphinx_theme/locale/ru/LC_MESSAGES/sphinx.po
index 44aba751f..69466037e 100644
--- a/src/pydata_sphinx_theme/locale/ru/LC_MESSAGES/sphinx.po
+++ b/src/pydata_sphinx_theme/locale/ru/LC_MESSAGES/sphinx.po
@@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
-"POT-Creation-Date: 2023-12-21 07:30-0700\n"
+"POT-Creation-Date: 2024-03-11 13:22-0500\n"
"PO-Revision-Date: 2023-04-14 14:57+0000\n"
"Last-Translator: Rambaud Pierrick , 2023\n"
"Language: ru\n"
@@ -23,11 +23,19 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: Babel 2.13.0\n"
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:53
+#: docs/conf.py:94
+msgid "Click to expand"
+msgstr ""
+
+#: docs/conf.py:95
+msgid "Click to collapse"
+msgstr ""
+
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:39
msgid "Skip to main content"
msgstr "Перейти к основному содержанию"
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:64
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:51
msgid "Back to top"
msgstr ""
@@ -95,12 +103,8 @@ msgstr "Индекс модулей Python"
msgid "Last updated on %(last_updated)s."
msgstr "Последнее обновление %(last_updated)s."
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-nav.html:6
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-nav.html:7
-msgid "Site Navigation"
-msgstr "Навигация по сайту"
-
#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/page-toc.html:8
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/sections/header.html:43
msgid "On this page"
msgstr "На этой странице"
@@ -153,6 +157,11 @@ msgstr ""
"theme.readthedocs.io/en/stable/index.html\\\">PyData Sphinx "
"%(theme_version)s."
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/sections/header.html:3
+#, fuzzy
+msgid "Site navigation"
+msgstr "Навигация по сайту"
+
#~ msgid "Breadcrumbs"
#~ msgstr "Навигационная цепочка"
diff --git a/src/pydata_sphinx_theme/locale/sphinx.pot b/src/pydata_sphinx_theme/locale/sphinx.pot
index 3d7ba10ea..afa6cc4fd 100644
--- a/src/pydata_sphinx_theme/locale/sphinx.pot
+++ b/src/pydata_sphinx_theme/locale/sphinx.pot
@@ -1,14 +1,14 @@
# Translations template for PROJECT.
-# Copyright (C) 2023 ORGANIZATION
+# Copyright (C) 2024 ORGANIZATION
# This file is distributed under the same license as the PROJECT project.
-# FIRST AUTHOR , 2023.
+# FIRST AUTHOR , 2024.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
-"POT-Creation-Date: 2023-12-21 07:30-0700\n"
+"POT-Creation-Date: 2024-03-11 13:22-0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME \n"
"Language-Team: LANGUAGE \n"
@@ -17,11 +17,19 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: Babel 2.13.0\n"
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:53
+#: docs/conf.py:94
+msgid "Click to expand"
+msgstr ""
+
+#: docs/conf.py:95
+msgid "Click to collapse"
+msgstr ""
+
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:39
msgid "Skip to main content"
msgstr ""
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:64
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html:51
msgid "Back to top"
msgstr ""
@@ -89,12 +97,8 @@ msgstr ""
msgid "Last updated on %(last_updated)s."
msgstr ""
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-nav.html:6
-#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/navbar-nav.html:7
-msgid "Site Navigation"
-msgstr ""
-
#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/page-toc.html:8
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/sections/header.html:43
msgid "On this page"
msgstr ""
@@ -142,3 +146,7 @@ msgid ""
"%(theme_version)s."
msgstr ""
+#: src/pydata_sphinx_theme/theme/pydata_sphinx_theme/sections/header.html:3
+msgid "Site navigation"
+msgstr ""
+
diff --git a/src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html b/src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html
index e59de071d..ca939503c 100644
--- a/src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html
+++ b/src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html
@@ -36,7 +36,7 @@
{# A button hidden by default to help assistive devices quickly jump to main content #}
{# ref: https://www.youtube.com/watch?v=VUR0I5mqq7I #}
- {{ _("Skip to main content") }}
+
{%- endblock %}
@@ -48,22 +48,20 @@
{# the scroll to top button #}
- {{ _("Back to top") }}
+ {{- _("Back to top") -}}
{%- endif %}
{# checkbox to toggle primary sidebar #}
-
+ id="pst-primary-sidebar-checkbox"/>
+
{# Checkboxes to toggle the secondary sidebar #}
-
+ id="pst-secondary-sidebar-checkbox"/>
+
{# A search field pop-up that will only show when the search button is clicked #}