]> git.lizzy.rs Git - rust.git/blob - src/librustdoc/html/static/css/themes/light.css
Rollup merge of #100934 - a1phyr:improve_fmt_PadAdapter, r=Mark-Simulacrum
[rust.git] / src / librustdoc / html / static / css / themes / light.css
1 :root {
2         --main-background-color: white;
3         --main-color: black;
4         --settings-input-color: #2196f3;
5         --sidebar-background-color: #F5F5F5;
6         --sidebar-background-color-hover: #E0E0E0;
7         --code-block-background-color: #F5F5F5;
8         --scrollbar-track-background-color: #dcdcdc;
9         --scrollbar-thumb-background-color: rgba(36, 37, 39, 0.6);
10         --scrollbar-color: rgba(36, 37, 39, 0.6) #d9d9d9;
11         --headings-border-bottom-color: #ddd;
12         --border-color: #e0e0e0;
13         --button-background-color: #fff;
14 }
15
16 .slider {
17         background-color: #ccc;
18 }
19 .slider:before {
20         background-color: white;
21 }
22 input:focus + .slider {
23         box-shadow: 0 0 0 2px #0a84ff, 0 0 0 6px rgba(10, 132, 255, 0.3);
24 }
25
26 .rust-logo {
27         /* This rule exists to force other themes to explicitly style the logo.
28          * Rustdoc has a custom linter for this purpose.
29          */
30 }
31
32 .sidebar .current,
33 .sidebar a:hover {
34         background-color: #fff;
35 }
36
37 .line-numbers span { color: #c67e2d; }
38 .line-numbers .line-highlighted {
39         background-color: #FDFFD3 !important;
40 }
41
42 .search-results a:hover {
43         background-color: #ddd;
44 }
45
46 .search-results a:focus {
47         color: #000 !important;
48         background-color: #ccc;
49 }
50 .search-results a:focus span { color: #000 !important; }
51 a.result-trait:focus { background-color: #c7b6ff; }
52 a.result-traitalias:focus { background-color: #c7b6ff; }
53 a.result-mod:focus,
54 a.result-externcrate:focus { background-color: #afc6e4; }
55 a.result-enum:focus { background-color: #e7b1a0; }
56 a.result-struct:focus { background-color: #e7b1a0; }
57 a.result-union:focus { background-color: #e7b1a0; }
58 a.result-fn:focus,
59 a.result-method:focus,
60 a.result-tymethod:focus { background-color: #c6afb3; }
61 a.result-type:focus { background-color: #e7b1a0; }
62 a.result-associatedtype:focus { background-color: #afc6e4; }
63 a.result-foreigntype:focus { background-color: #e7b1a0; }
64 a.result-attr:focus,
65 a.result-derive:focus,
66 a.result-macro:focus { background-color: #8ce488; }
67 a.result-constant:focus,
68 a.result-static:focus { background-color: #afc6e4; }
69 a.result-primitive:focus { background-color: #e7b1a0; }
70 a.result-keyword:focus { background-color: #afc6e4; }
71
72 .content .item-info::before { color: #ccc; }
73
74 .content span.enum, .content a.enum, .block a.current.enum { color: #AD378A; }
75 .content span.struct, .content a.struct, .block a.current.struct { color: #AD378A; }
76 .content span.type, .content a.type, .block a.current.type { color:  #AD378A; }
77 .content span.foreigntype, .content a.foreigntype, .block a.current.foreigntype { color: #3873AD; }
78 .content span.associatedtype,
79 .content a.associatedtype,
80 .block a.current.associatedtype { color: #3873AD; }
81 .content span.attr, .content a.attr, .block a.current.attr,
82 .content span.derive, .content a.derive, .block a.current.derive,
83 .content span.macro, .content a.macro, .block a.current.macro { color: #068000; }
84 .content span.union, .content a.union, .block a.current.union { color: #AD378A; }
85 .content span.constant, .content a.constant, .block a.current.constant,
86 .content span.static, .content a.static, .block a.current.static { color: #3873AD; }
87 .content span.primitive, .content a.primitive, .block a.current.primitive { color: #AD378A; }
88 .content span.externcrate,
89 .content span.mod, .content a.mod, .block a.current.mod { color: #3873AD; }
90 .content span.trait, .content a.trait, .block a.current.trait { color: #6E4FC9; }
91 .content span.traitalias, .content a.traitalias, .block a.current.traitalias { color: #5137AD; }
92 .content span.fn, .content a.fn, .block a.current.fn,
93 .content span.method, .content a.method, .block a.current.method,
94 .content span.tymethod, .content a.tymethod, .block a.current.tymethod,
95 .content .fnname { color: #AD7C37; }
96 .content span.keyword, .content a.keyword, .block a.current.keyword { color: #3873AD; }
97
98 .sidebar a { color: #356da4; }
99 .sidebar a.current.enum { color: #a63283; }
100 .sidebar a.current.struct { color: #a63283; }
101 .sidebar a.current.type { color: #a63283; }
102 .sidebar a.current.associatedtype { color: #356da4; }
103 .sidebar a.current.foreigntype { color: #356da4; }
104 .sidebar a.current.attr,
105 .sidebar a.current.derive,
106 .sidebar a.current.macro { color: #067901; }
107 .sidebar a.current.union { color: #a63283; }
108 .sidebar a.current.constant
109 .sidebar a.current.static { color: #356da4; }
110 .sidebar a.current.primitive { color: #a63283; }
111 .sidebar a.current.externcrate
112 .sidebar a.current.mod { color: #356da4; }
113 .sidebar a.current.trait { color: #6849c3; }
114 .sidebar a.current.traitalias { color: #4b349e; }
115 .sidebar a.current.fn,
116 .sidebar a.current.method,
117 .sidebar a.current.tymethod { color: #a67736; }
118 .sidebar a.current.keyword { color: #356da4; }
119
120 a {
121         color: #3873AD;
122 }
123
124 body.source .example-wrap pre.rust a {
125         background: #eee;
126 }
127
128 details.rustdoc-toggle > summary.hideme > span,
129 details.rustdoc-toggle > summary::before {
130         color: #999;
131 }
132
133 #crate-search-div::after {
134         /* match border-color; uses https://codepen.io/sosuke/pen/Pjoqqp */
135         filter: invert(100%) sepia(0%) saturate(4223%) hue-rotate(289deg) brightness(114%) contrast(76%);
136 }
137 #crate-search:hover, #crate-search:focus {
138         border-color: #717171 !important;
139 }
140 #crate-search-div:hover::after, #crate-search-div:focus-within::after {
141         filter: invert(44%) sepia(18%) saturate(23%) hue-rotate(317deg) brightness(96%) contrast(93%);
142 }
143
144 .search-input:focus {
145         border-color: #66afe9;
146 }
147
148 .stab { background: #FFF5D6; border-color: #FFC600; }
149 .stab.portability > code { background: none; }
150
151 .rightside:not(a),
152 .out-of-band {
153         color: grey;
154 }
155
156 .line-numbers :target { background-color: transparent; }
157
158 /* Code highlighting */
159 pre.rust .kw { color: #8959A8; }
160 pre.rust .kw-2, pre.rust .prelude-ty { color: #4271AE; }
161 pre.rust .number, pre.rust .string { color: #718C00; }
162 pre.rust .self, pre.rust .bool-val, pre.rust .prelude-val,
163 pre.rust .attribute { color: #C82829; }
164 pre.rust .comment { color: #8E908C; }
165 pre.rust .doccomment { color: #4D4D4C; }
166 pre.rust .macro, pre.rust .macro-nonterminal { color: #3E999F; }
167 pre.rust .lifetime { color: #B76514; }
168 pre.rust .question-mark {
169         color: #ff9011;
170 }
171
172 .example-wrap > pre.line-number {
173         border-color: #c7c7c7;
174 }
175
176 a.test-arrow {
177         color: #f5f5f5;
178         background-color: rgba(78, 139, 202, 0.2);
179 }
180
181 a.test-arrow:hover{
182         background-color: #4e8bca;
183 }
184
185 .toggle-label,
186 .code-attribute {
187         color: #999;
188 }
189
190 :target {
191         background: #FDFFD3;
192         border-right: 3px solid #AD7C37;
193 }
194
195 pre.compile_fail {
196         border-left: 2px solid rgba(255,0,0,.5);
197 }
198
199 pre.compile_fail:hover, .information:hover + pre.compile_fail {
200         border-left: 2px solid #f00;
201 }
202
203 pre.should_panic {
204         border-left: 2px solid rgba(255,0,0,.5);
205 }
206
207 pre.should_panic:hover, .information:hover + pre.should_panic {
208         border-left: 2px solid #f00;
209 }
210
211 pre.ignore {
212         border-left: 2px solid rgba(255,142,0,.6);
213 }
214
215 pre.ignore:hover, .information:hover + pre.ignore {
216         border-left: 2px solid #ff9200;
217 }
218
219 .tooltip.compile_fail {
220         color: rgba(255,0,0,.5);
221 }
222
223 .information > .compile_fail:hover {
224         color: #f00;
225 }
226
227 .tooltip.should_panic {
228         color: rgba(255,0,0,.5);
229 }
230
231 .information > .should_panic:hover {
232         color: #f00;
233 }
234
235 .tooltip.ignore {
236         color: rgba(255,142,0,.6);
237 }
238
239 .information > .ignore:hover {
240         color: #ff9200;
241 }
242
243 .search-failed a {
244         color: #3873AD;
245 }
246
247 .tooltip::after {
248         background-color: #000;
249         color: #fff;
250 }
251
252 .tooltip::before {
253         border-color: transparent black transparent transparent;
254 }
255
256 .notable-traits-tooltiptext {
257         background-color: #eee;
258 }
259
260 #titles > button:not(.selected) {
261         background-color: #e6e6e6;
262         border-top-color: #e6e6e6;
263 }
264
265 #titles > button:hover, #titles > button.selected {
266         background-color: #ffffff;
267         border-top-color: #0089ff;
268 }
269
270 #titles > button > div.count {
271         color: #888;
272 }
273
274 kbd {
275         color: #000;
276         background-color: #fafbfc;
277         box-shadow: inset 0 -1px 0 #c6cbd1;
278 }
279
280 #settings-menu > a:hover, #settings-menu > a:focus,
281 #help-button > button:hover, #help-button > button:focus {
282         border-color: #717171;
283 }
284
285 #copy-path {
286         color: #999;
287 }
288 #copy-path > img {
289         filter: invert(50%);
290 }
291 #copy-path:hover > img {
292         filter: invert(35%);
293 }
294
295 .search-results .result-name span.alias {
296         color: #000;
297 }
298 .search-results .result-name span.grey {
299         color: #999;
300 }
301
302 #source-sidebar div.files > a:hover, details.dir-entry summary:hover,
303 #source-sidebar div.files > a:focus, details.dir-entry summary:focus {
304         background-color: #E0E0E0;
305 }
306 #source-sidebar div.files > a.selected {
307         background-color: #fff;
308 }
309 .scraped-example-list .scrape-help {
310         border-color: #555;
311         color: #333;
312 }
313 .scraped-example-list .scrape-help:hover {
314         border-color: black;
315         color: black;
316 }
317 .more-examples-toggle summary, .more-examples-toggle .hide-more {
318         color: #999;
319 }
320 .scraped-example .example-wrap .rust span.highlight {
321         background: #fcffd6;
322 }
323 .scraped-example .example-wrap .rust span.highlight.focus {
324         background: #f6fdb0;
325 }
326 .scraped-example:not(.expanded) .code-wrapper:before {
327         background: linear-gradient(to bottom, rgba(255, 255, 255, 1), rgba(255, 255, 255, 0));
328 }
329 .scraped-example:not(.expanded) .code-wrapper:after {
330         background: linear-gradient(to top, rgba(255, 255, 255, 1), rgba(255, 255, 255, 0));
331 }
332 .toggle-line-inner {
333         background: #ccc;
334 }
335 .toggle-line:hover .toggle-line-inner {
336         background: #999;
337 }