]> git.lizzy.rs Git - rust.git/blob - src/librustdoc/html/static/css/themes/dark.css
Rollup merge of #100255 - thedanvail:issue-98861-fix, r=joshtriplett
[rust.git] / src / librustdoc / html / static / css / themes / dark.css
1 :root {
2         --main-background-color: #353535;
3         --main-color: #ddd;
4         --settings-input-color: #2196f3;
5         --sidebar-background-color: #505050;
6         --sidebar-background-color-hover: #676767;
7         --code-block-background-color: #2A2A2A;
8         --scrollbar-track-background-color: #717171;
9         --scrollbar-thumb-background-color: rgba(32, 34, 37, .6);
10         --scrollbar-color: rgba(32,34,37,.6) #5a5a5a;
11         --headings-border-bottom-color: #d2d2d2;
12 }
13
14 .slider {
15         background-color: #ccc;
16 }
17 .slider:before {
18         background-color: white;
19 }
20 input:focus + .slider {
21         box-shadow: 0 0 0 2px #0a84ff, 0 0 0 6px rgba(10, 132, 255, 0.3);
22 }
23
24 .in-band {
25         background-color: #353535;
26 }
27
28 .rust-logo {
29         filter: drop-shadow(1px 0 0px #fff)
30                 drop-shadow(0 1px 0 #fff)
31                 drop-shadow(-1px 0 0 #fff)
32                 drop-shadow(0 -1px 0 #fff)
33 }
34
35 .sidebar .current,
36 .sidebar a:hover {
37         background: #444;
38 }
39
40 .line-numbers span { color: #3B91E2; }
41 .line-numbers .line-highlighted {
42         background-color: #0a042f !important;
43 }
44
45 .docblock table td, .docblock table th {
46         border-color: #ddd;
47 }
48
49 .search-results a:hover {
50         background-color: #777;
51 }
52
53 .search-results a:focus {
54         color: #eee !important;
55         background-color: #616161;
56 }
57 .search-results a:focus span { color: #eee !important; }
58 a.result-trait:focus { background-color: #013191; }
59 a.result-traitalias:focus { background-color: #013191; }
60 a.result-mod:focus,
61 a.result-externcrate:focus { background-color: #884719; }
62 a.result-enum:focus { background-color: #194e9f; }
63 a.result-struct:focus { background-color: #194e9f; }
64 a.result-union:focus { background-color: #194e9f; }
65 a.result-fn:focus,
66 a.result-method:focus,
67 a.result-tymethod:focus { background-color: #4950ed; }
68 a.result-type:focus { background-color: #194e9f; }
69 a.result-associatedtype:focus { background-color: #884719; }
70 a.result-foreigntype:focus { background-color: #194e9f; }
71 a.result-attr:focus,
72 a.result-derive:focus,
73 a.result-macro:focus { background-color: #217d1c; }
74 a.result-constant:focus,
75 a.result-static:focus { background-color: #884719; }
76 a.result-primitive:focus { background-color: #194e9f; }
77 a.result-keyword:focus { background-color: #884719; }
78
79 .content .item-info::before { color: #ccc; }
80
81 .content span.enum, .content a.enum, .block a.current.enum { color: #2dbfb8; }
82 .content span.struct, .content a.struct, .block a.current.struct { color: #2dbfb8; }
83 .content span.type, .content a.type, .block a.current.type { color: #2dbfb8; }
84 .content span.associatedtype,
85 .content a.associatedtype,
86 .block a.current.associatedtype { color: #D2991D; }
87 .content span.foreigntype, .content a.foreigntype, .block a.current.foreigntype { color: #2dbfb8; }
88 .content span.attr, .content a.attr, .block a.current.attr,
89 .content span.derive, .content a.derive, .block a.current.derive,
90 .content span.macro, .content a.macro, .block a.current.macro { color: #09bd00; }
91 .content span.union, .content a.union, .block a.current.union { color: #2dbfb8; }
92 .content span.constant, .content a.constant, .block a.current.constant,
93 .content span.static, .content a.static, .block a.current.static { color: #D2991D; }
94 .content span.primitive, .content a.primitive, .block a.current.primitive { color: #2dbfb8; }
95 .content span.externcrate,
96 .content span.mod, .content a.mod, .block a.current.mod { color: #D2991D; }
97 .content span.trait, .content a.trait, .block a.current.trait { color: #b78cf2; }
98 .content span.traitalias, .content a.traitalias, .block a.current.traitalias { color: #b78cf2; }
99 .content span.fn, .content a.fn, .block a.current.fn,
100 .content span.method, .content a.method, .block a.current.method,
101 .content span.tymethod, .content a.tymethod, .block a.current.tymethod,
102 .content .fnname{ color: #2BAB63; }
103 .content span.keyword, .content a.keyword, .block a.current.keyword { color: #D2991D; }
104
105 .sidebar a { color: #fdbf35; }
106 .sidebar a.current.enum { color: #12ece2; }
107 .sidebar a.current.struct { color: #12ece2; }
108 .sidebar a.current.type { color: #12ece2; }
109 .sidebar a.current.associatedtype { color: #fdbf35; }
110 .sidebar a.current.foreigntype { color: #12ece2; }
111 .sidebar a.current.attr,
112 .sidebar a.current.derive,
113 .sidebar a.current.macro { color: #0be900; }
114 .sidebar a.current.union { color: #12ece2; }
115 .sidebar a.current.constant
116 .sidebar a.current.static { color: #fdbf35; }
117 .sidebar a.current.primitive { color: #12ece2; }
118 .sidebar a.current.externcrate
119 .sidebar a.current.mod { color: #fdbf35; }
120 .sidebar a.current.trait { color: #cca7ff; }
121 .sidebar a.current.traitalias { color: #cca7ff; }
122 .sidebar a.current.fn,
123 .sidebar a.current.method,
124 .sidebar a.current.tymethod { color: #32d479; }
125 .sidebar a.current.keyword { color: #fdbf35; }
126
127 pre.rust .comment { color: #8d8d8b; }
128 pre.rust .doccomment { color: #8ca375; }
129
130 nav.main .current {
131         border-top-color: #eee;
132         border-bottom-color: #eee;
133 }
134 nav.main .separator {
135         border-color: #eee;
136 }
137
138 a {
139         color: #D2991D;
140 }
141
142 body.source .example-wrap pre.rust a {
143         background: #333;
144 }
145
146 details.rustdoc-toggle > summary.hideme > span,
147 details.rustdoc-toggle > summary::before {
148         color: #999;
149 }
150
151 details.rustdoc-toggle > summary::before {
152         filter: invert(100%);
153 }
154
155 .search-input {
156         color: #111;
157         background-color: #f0f0f0;
158         border-color: #f0f0f0;
159 }
160
161 #crate-search {
162         /* Without the `!important`, the border-color is ignored for `<select>`...
163            It cannot be in the group above because `.search-input` has a different border color on
164            hover. */
165         border-color: #d2d2d2 !important;
166 }
167 #crate-search-div::after {
168         /* match border-color; uses https://codepen.io/sosuke/pen/Pjoqqp */
169         filter: invert(94%) sepia(0%) saturate(721%) hue-rotate(255deg) brightness(90%) contrast(90%);
170 }
171 #crate-search:hover, #crate-search:focus {
172         border-color: #2196f3 !important;
173 }
174 #crate-search-div:hover::after, #crate-search-div:focus-within::after {
175         filter: invert(69%) sepia(60%) saturate(6613%) hue-rotate(184deg) brightness(100%) contrast(91%);
176 }
177
178 .search-input {
179         border-color: #e0e0e0;
180 }
181
182 .search-input:focus {
183         border-color: #008dfd;
184 }
185
186 .stab { background: #314559; }
187
188 .stab.portability > code {
189         color: #e6e1cf;
190         background: none;
191 }
192
193 .rightside,
194 .out-of-band {
195         color: grey;
196 }
197
198 .line-numbers :target { background-color: transparent; }
199
200 /* Code highlighting */
201 pre.rust .kw { color: #ab8ac1; }
202 pre.rust .kw-2, pre.rust .prelude-ty { color: #769acb; }
203 pre.rust .number, pre.rust .string { color: #83a300; }
204 pre.rust .self, pre.rust .bool-val, pre.rust .prelude-val,
205 pre.rust .attribute, pre.rust .attribute .ident { color: #ee6868; }
206 pre.rust .macro, pre.rust .macro-nonterminal { color: #3E999F; }
207 pre.rust .lifetime { color: #d97f26; }
208 pre.rust .question-mark {
209         color: #ff9011;
210 }
211
212 .example-wrap > pre.line-number {
213         border-color: #4a4949;
214 }
215
216 a.test-arrow {
217         color: #dedede;
218         background-color: rgba(78, 139, 202, 0.2);
219 }
220
221 a.test-arrow:hover{
222         background-color: #4e8bca;
223 }
224
225 .toggle-label,
226 .code-attribute {
227         color: #999;
228 }
229
230 :target {
231         background-color: #494a3d;
232         border-right: 3px solid #bb7410;
233 }
234
235 pre.compile_fail {
236         border-left: 2px solid rgba(255,0,0,.8);
237 }
238
239 pre.compile_fail:hover, .information:hover + pre.compile_fail {
240         border-left: 2px solid #f00;
241 }
242
243 pre.should_panic {
244         border-left: 2px solid rgba(255,0,0,.8);
245 }
246
247 pre.should_panic:hover, .information:hover + pre.should_panic {
248         border-left: 2px solid #f00;
249 }
250
251 pre.ignore {
252         border-left: 2px solid rgba(255,142,0,.6);
253 }
254
255 pre.ignore:hover, .information:hover + pre.ignore {
256         border-left: 2px solid #ff9200;
257 }
258
259 .tooltip.compile_fail {
260         color: rgba(255,0,0,.8);
261 }
262
263 .information > .compile_fail:hover {
264         color: #f00;
265 }
266
267 .tooltip.should_panic {
268         color: rgba(255,0,0,.8);
269 }
270
271 .information > .should_panic:hover {
272         color: #f00;
273 }
274
275 .tooltip.ignore {
276         color: rgba(255,142,0,.6);
277 }
278
279 .information > .ignore:hover {
280         color: #ff9200;
281 }
282
283 .search-failed a {
284         color: #0089ff;
285 }
286
287 .tooltip::after {
288         background-color: #000;
289         color: #fff;
290         border-color: #000;
291 }
292
293 .tooltip::before {
294         border-color: transparent black transparent transparent;
295 }
296
297 .notable-traits-tooltiptext {
298         background-color: #111;
299         border-color: #777;
300 }
301
302 .notable-traits-tooltiptext .notable {
303         border-bottom-color: #d2d2d2;
304 }
305
306 #titles > button:not(.selected) {
307         background-color: #252525;
308         border-top-color: #252525;
309 }
310
311 #titles > button:hover, #titles > button.selected {
312         border-top-color: #0089ff;
313         background-color: #353535;
314 }
315
316 #titles > button > div.count {
317         color: #888;
318 }
319
320 @media (max-width: 700px) {
321         .sidebar-elems {
322                 border-right-color: #000;
323         }
324 }
325
326 kbd {
327         color: #000;
328         background-color: #fafbfc;
329         border-color: #d1d5da;
330         border-bottom-color: #c6cbd1;
331         box-shadow: inset 0 -1px 0 #c6cbd1;
332 }
333
334 #settings-menu > a, #help-button > button {
335         border-color: #e0e0e0;
336         background: #f0f0f0;
337         color: #000;
338 }
339
340 #settings-menu > a:hover, #settings-menu > a:focus,
341 #help-button > button:hover, #help-button > button:focus {
342         border-color: #ffb900;
343 }
344
345 .popover, .popover::before,
346 #help-button span.top, #help-button span.bottom {
347         border-color: #d2d2d2;
348 }
349
350 #copy-path {
351         color: #999;
352 }
353 #copy-path > img {
354         filter: invert(50%);
355 }
356 #copy-path:hover > img {
357         filter: invert(65%);
358 }
359
360 #theme-choices {
361         border-color: #e0e0e0;
362         background-color: #353535;
363 }
364
365 #theme-choices > button:not(:first-child) {
366         border-top-color: #e0e0e0;
367 }
368
369 #theme-choices > button:hover, #theme-choices > button:focus {
370         background-color: #4e4e4e;
371 }
372
373 .search-results .result-name span.alias {
374         color: #fff;
375 }
376 .search-results .result-name span.grey {
377         color: #ccc;
378 }
379
380 #source-sidebar > .title {
381         border-bottom-color: #ccc;
382 }
383 #source-sidebar div.files > a:hover, details.dir-entry summary:hover,
384 #source-sidebar div.files > a:focus, details.dir-entry summary:focus {
385         background-color: #444;
386 }
387 #source-sidebar div.files > a.selected {
388         background-color: #333;
389 }
390
391 .scraped-example-list .scrape-help {
392         border-color: #aaa;
393         color: #eee;
394 }
395 .scraped-example-list .scrape-help:hover {
396         border-color: white;
397         color: white;
398 }
399 .more-examples-toggle summary, .more-examples-toggle .hide-more {
400         color: #999;
401 }
402 .scraped-example .example-wrap .rust span.highlight {
403         background: rgb(91, 59, 1);
404 }
405 .scraped-example .example-wrap .rust span.highlight.focus {
406         background: rgb(124, 75, 15);
407 }
408 .scraped-example:not(.expanded) .code-wrapper:before {
409         background: linear-gradient(to bottom, rgba(53, 53, 53, 1), rgba(53, 53, 53, 0));
410 }
411 .scraped-example:not(.expanded) .code-wrapper:after {
412         background: linear-gradient(to top, rgba(53, 53, 53, 1), rgba(53, 53, 53, 0));
413 }
414 .toggle-line-inner {
415         background: #999;
416 }
417 .toggle-line:hover .toggle-line-inner {
418         background: #c5c5c5;
419 }