Skip to content

Commit 973999a

Browse files
committed
Preferred color is not always the selected one
1 parent 2e1267b commit 973999a

File tree

1 file changed

+32
-34
lines changed

1 file changed

+32
-34
lines changed

scripts/md2html/main.css

Lines changed: 32 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,6 @@ a.bibref {
7272
text-decoration: underline;
7373
}
7474

75-
@media (prefers-color-scheme: dark) {
7675
body.darkmode {
7776
--toclink-underline: #6a9000;
7877
--toclink-visited-underline: #fff;
@@ -88,41 +87,40 @@ a.bibref {
8887
color: #e66c33;
8988
}
9089

91-
body.darkmode:not(.toc-inline) #toc h2,
92-
body.darkmode h1,
93-
body.darkmode h2,
94-
body.darkmode h3,
95-
body.darkmode h4,
96-
body.darkmode h5,
97-
body.darkmode h6,
98-
body.darkmode #title,
99-
body.darkmode #subtitle,
100-
body.darkmode .toc-inline,
101-
body.darkmode .dt-published {
102-
color: #7bb01c;
103-
}
90+
body.darkmode:not(.toc-inline) #toc h2,
91+
body.darkmode h1,
92+
body.darkmode h2,
93+
body.darkmode h3,
94+
body.darkmode h4,
95+
body.darkmode h5,
96+
body.darkmode h6,
97+
body.darkmode #title,
98+
body.darkmode #subtitle,
99+
body.darkmode .toc-inline,
100+
body.darkmode .dt-published {
101+
color: #7bb01c;
102+
}
104103

105-
body.darkmode pre,
106-
body.darkmode table tr:nth-child(2n),
107-
body.darkmode table tr {
108-
background-color: #1e1e1e !important;
109-
color: #dcdcdc;
110-
}
104+
body.darkmode pre,
105+
body.darkmode table tr:nth-child(2n),
106+
body.darkmode table tr {
107+
background-color: #1e1e1e !important;
108+
color: #dcdcdc;
109+
}
111110

112-
body.darkmode img {
113-
background: transparent;
114-
}
111+
body.darkmode img {
112+
background: transparent;
113+
}
115114

116-
body.darkmode .logo img {
117-
display: none;
118-
}
115+
body.darkmode .logo img {
116+
display: none;
117+
}
119118

120-
body.darkmode .logo::before {
121-
content: "";
122-
display: inline-block;
123-
height: 48px;
124-
width: 175px;
125-
background: url("https://raw.githubusercontent.com/OAI/OpenAPI-Style-Guide/refs/heads/main/graphics/bitmap/OpenAPI_Logo_Pantone.png") no-repeat center / contain;
126-
vertical-align: middle;
127-
}
119+
body.darkmode .logo::before {
120+
content: "";
121+
display: inline-block;
122+
height: 48px;
123+
width: 175px;
124+
background: url("https://raw.githubusercontent.com/OAI/OpenAPI-Style-Guide/refs/heads/main/graphics/bitmap/OpenAPI_Logo_Pantone.png") no-repeat center / contain;
125+
vertical-align: middle;
128126
}

0 commit comments

Comments
 (0)