Skip to content

Turn off dark mode default in docs #2051

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

Closed
canyon289 opened this issue Jun 18, 2022 · 2 comments · Fixed by #2057
Closed

Turn off dark mode default in docs #2051

canyon289 opened this issue Jun 18, 2022 · 2 comments · Fixed by #2057

Comments

@canyon289
Copy link
Member

Describe the bug
The docs don't look good in dark mode. Is there some setting to ensure it defaults to light mode initially?
image

To Reproduce
I'm not sure but I'm thinking its reading from my system or browser setting

Expected behavior
Light mode always

Additional context
Versions of arviz and other libraries used, operating system used, and anything else that may be useful.

@networkpsych
Copy link

networkpsych commented Jun 18, 2022

pydata/pydata-sphinx-theme#458

The same question was issued here, and the commenter mentioned changing the html_context for the sphinx setup:

html_context = {
   # other contexts
   "default_mode": "light"
}

@OriolAbril
Copy link
Member

OriolAbril commented Jun 18, 2022

We should pin the pydata-sphinx-theme to <0.9.0 in https://github.com/arviz-devs/arviz/blob/main/requirements-docs.txt.

The introduction of the dark theme (which defaults to whatever theme your browser is using but can be changed as pointed out by @Autoclitic and as explained in the theme docs) is quite secondary imo. The version has also changed how the layout works, so our trick from https://github.com/arviz-devs/arviz/blob/main/doc/_templates/layout.html no longer works, both sidebars appear and overlay with the content of the homepage which looks awful in both modes.

I think we should pin the theme (urgent) and then whenever we can open a PR to update the layout trick to remove all sidebars from the homepage (not urgent)

This was referenced Jun 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants