Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DOC] Tooltips are always shown in light mode, even in dark mode. #2348

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions docs/sphinx/source/_static/hoverxref-darkmode.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
/* Overrides for sphinx-hoverxref since it does not support a native dark theme, see */
/* https://github.com/readthedocs/sphinx-hoverxref/issues/231 */
/* Inspired by https://github.com/pybamm-team/PyBaMM/pull/3083 */

/* These will ensure that the tooltip inherits the pydata-sphinx-theme colours */

.tooltipster-sidetip.tooltipster-shadow .tooltipster-box {
background: var(--pst-color-background) !important;
}

.tooltipster-sidetip.tooltipster-shadow .tooltipster-content {
color: var(--pst-color-text-base) !important;
}
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ doc = [
'sphinx-toggleprompt == 0.5.2',
'sphinx-favicon',
'solarfactors',
'sphinx-hoverxref',
'sphinx-hoverxref ~= 1.4.2',
]
test = [
'pytest',
Expand Down
Loading