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

Added Dark Mode support to option tables #253

Merged
merged 12 commits into from
Mar 12, 2024
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
minor_changes:
- Add support for "Dark-Mode" inside the Option-Tables (https://github.com/ansible-community/antsibull-docs/pull/253).
SebastianGode marked this conversation as resolved.
Show resolved Hide resolved
2 changes: 1 addition & 1 deletion src/sphinx_antsibull_ext/antsibull-minimal.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

72 changes: 72 additions & 0 deletions src/sphinx_antsibull_ext/css/antsibull-minimal.scss
Original file line number Diff line number Diff line change
Expand Up @@ -261,6 +261,78 @@ table.ansible-option-table {
.ansible-attribute-support-label {
display: none;
}

@media (prefers-color-scheme: dark) {
thead tr {
background-color: #48484b;
}

tbody {
.row-odd td {
background-color: #242426 !important;
}

.row-even td {
background-color: #1c1c1e !important;
}
}

td, th {
border-color: #656569 !important;
}

.ansible-option-type {
color: #ff93ff;
}

.ansible-option-elements {
color: #ff93ff;
}

.ansible-option-aliases {
color: #71d471;
}

.ansible-option-versionadded {
color: #71d471;
}

.ansible-option-required {
color: #ff8282;
}

.ansible-option-default, .ansible-option-choices-default-mark {
color: #adadff;
}

.ansible-option-default-bold {
color: #adadff;
}

.ansible-option-sample {
color: #adadff;
}

.ansible-option-sample-bold {
color: white;
}

.ansible-attribute-support-none {
color: #ff8282;
}

.ansible-attribute-support-partial {
color: #b6b600;
}

.ansible-attribute-support-full {
color: #00cc00;
}

.ansible-option-indent {
border-right: 1px solid #656569;
}
}
}

@media (max-width: 1200px) {
Expand Down
Loading