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

Change background to make code listing more legible in dark mode. #3738

Merged
merged 2 commits into from
Jan 22, 2025
Merged
Changes from 1 commit
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
10 changes: 9 additions & 1 deletion Docs/_static/aimet-furo.css
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
--aimet-menu-hover: #e3efff;
--aimet-menu-font-active: #0058ff;
--aimet-code-grey: #fafafa;
--aimet-code-grey-dark: #535353;
--aimet-light-blue: #e7f2fa;
}

Expand Down Expand Up @@ -50,10 +51,17 @@ li.toctree-l2 [for^="toctree-checkbox-"] {
max-height: 25em;
}

*.highlight pre, pre.literal-block {
/* Change the code backgorund in light and default mode */
:not(body[data-theme="dark"]) *.highlight pre, :not(body[data-theme="dark"]) pre.literal-block {
background-color: var(--aimet-code-grey);
}

/* Change the code backgorund in dark mode */
body[data-theme="dark"] *.highlight pre, body[data-theme="dark"] pre.literal-block {
background-color: var(--aimet-code-grey-dark);
}


/*
* Glossary formatting
*/
Expand Down
Loading