]> git.lizzy.rs Git - rust.git/blob - src/librustdoc/html/static/css/themes/light.css
Rollup merge of #99736 - lopopolo:lopopolo/gh-80996-partial-stabilization-bounds...
[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 .code-attribute {
186         color: #999;
187 }
188
189 :target {
190         background: #FDFFD3;
191         border-right: 3px solid #AD7C37;
192 }
193
194 pre.compile_fail {
195         border-left: 2px solid rgba(255,0,0,.5);
196 }
197
198 pre.compile_fail:hover, .information:hover + pre.compile_fail {
199         border-left: 2px solid #f00;
200 }
201
202 pre.should_panic {
203         border-left: 2px solid rgba(255,0,0,.5);
204 }
205
206 pre.should_panic:hover, .information:hover + pre.should_panic {
207         border-left: 2px solid #f00;
208 }
209
210 pre.ignore {
211         border-left: 2px solid rgba(255,142,0,.6);
212 }
213
214 pre.ignore:hover, .information:hover + pre.ignore {
215         border-left: 2px solid #ff9200;
216 }
217
218 .tooltip.compile_fail {
219         color: rgba(255,0,0,.5);
220 }
221
222 .information > .compile_fail:hover {
223         color: #f00;
224 }
225
226 .tooltip.should_panic {
227         color: rgba(255,0,0,.5);
228 }
229
230 .information > .should_panic:hover {
231         color: #f00;
232 }
233
234 .tooltip.ignore {
235         color: rgba(255,142,0,.6);
236 }
237
238 .information > .ignore:hover {
239         color: #ff9200;
240 }
241
242 .search-failed a {
243         color: #3873AD;
244 }
245
246 .tooltip::after {
247         background-color: #000;
248         color: #fff;
249 }
250
251 .tooltip::before {
252         border-color: transparent black transparent transparent;
253 }
254
255 .notable-traits-tooltiptext {
256         background-color: #eee;
257 }
258
259 #titles > button:not(.selected) {
260         background-color: #e6e6e6;
261         border-top-color: #e6e6e6;
262 }
263
264 #titles > button:hover, #titles > button.selected {
265         background-color: #ffffff;
266         border-top-color: #0089ff;
267 }
268
269 #titles > button > div.count {
270         color: #888;
271 }
272
273 kbd {
274         color: #000;
275         background-color: #fafbfc;
276         box-shadow: inset 0 -1px 0 #c6cbd1;
277 }
278
279 #settings-menu > a:hover, #settings-menu > a:focus,
280 #help-button > button:hover, #help-button > button:focus {
281         border-color: #717171;
282 }
283
284 #copy-path {
285         color: #999;
286 }
287 #copy-path > img {
288         filter: invert(50%);
289 }
290 #copy-path:hover > img {
291         filter: invert(35%);
292 }
293
294 .search-results .result-name span.alias {
295         color: #000;
296 }
297 .search-results .result-name span.grey {
298         color: #999;
299 }
300
301 #source-sidebar div.files > a:hover, details.dir-entry summary:hover,
302 #source-sidebar div.files > a:focus, details.dir-entry summary:focus {
303         background-color: #E0E0E0;
304 }
305 #source-sidebar div.files > a.selected {
306         background-color: #fff;
307 }
308 .scraped-example-list .scrape-help {
309         border-color: #555;
310         color: #333;
311 }
312 .scraped-example-list .scrape-help:hover {
313         border-color: black;
314         color: black;
315 }
316 .more-examples-toggle summary, .more-examples-toggle .hide-more {
317         color: #999;
318 }
319 .scraped-example .example-wrap .rust span.highlight {
320         background: #fcffd6;
321 }
322 .scraped-example .example-wrap .rust span.highlight.focus {
323         background: #f6fdb0;
324 }
325 .scraped-example:not(.expanded) .code-wrapper:before {
326         background: linear-gradient(to bottom, rgba(255, 255, 255, 1), rgba(255, 255, 255, 0));
327 }
328 .scraped-example:not(.expanded) .code-wrapper:after {
329         background: linear-gradient(to top, rgba(255, 255, 255, 1), rgba(255, 255, 255, 0));
330 }
331 .toggle-line-inner {
332         background: #ccc;
333 }
334 .toggle-line:hover .toggle-line-inner {
335         background: #999;
336 }