Add jupyter-dark-detect for automatic matplotlib dark mode theming#153
Open
brycelelbach wants to merge 1 commit intomainfrom
Open
Add jupyter-dark-detect for automatic matplotlib dark mode theming#153brycelelbach wants to merge 1 commit intomainfrom
brycelelbach wants to merge 1 commit intomainfrom
Conversation
Detects whether the browser is in dark mode via jupyter-dark-detect and sets the matplotlib style accordingly. Replaces hardcoded color constants in nvmath-python visualization cells with a COLOR1-COLOR6 palette that adapts to light/dark mode.
Contributor
❌ Link Check FailedBroken links were detected in this PR. Please check the workflow run logs for details on which links are broken. Common fixes:
To test links locally:./brev/test-links.bash . |
Collaborator
Author
|
Link check/validator broken until #151 is merged. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
jupyter-dark-detect == 0.1.0to all 5 tutorialrequirements.txtfiles so matplotlib can detect whether the browser is in dark modeimport matplotlib.pyplot as pltwith a 3-line pattern (from jupyter_dark_detect import is_dark/import matplotlib.pyplot as plt/plt.style.use(...)) across all notebooks and helper.pyfiles that import matplotlibnvmath-pythonvisualization cells (05_device_api,04_callbacks) and03__numpy_to_cupy__ndarray_basics__SOLUTIONinto aCOLOR1–COLOR6palette that adapts foreground/accent colors to light vs dark mode