Fix 'Tags' padding to keep it farther from the edge and document the source of the...
[lhc/web/wiklou.git] / resources / src / mediawiki.legacy / commonPrint.css
1 /**
2 * MediaWiki print style sheet
3 * Largely based on work by Gabriel Wicke
4 *
5 * Originally derived from Plone (https://plone.org/) styles
6 * Copyright Alexander Limi
7 */
8
9 /**
10 * Hide all the elements irrelevant for printing
11 * Skins however can and should override.
12 */
13 /* General hide-in-print class, please only use sparely */
14 .noprint,
15 /* Various content classes, in alphabetical order */
16 .catlinks,
17 .magnify,
18 .mw-cite-backlink,
19 .mw-jump,
20 .mw-editsection,
21 .mw-editsection-like,
22 .mw-hidden-catlinks,
23 .mw-indicators,
24 .mw-redirectedfrom,
25 .patrollink,
26 .usermessage,
27 /* Various content ids, in alphabetical order */
28 #column-one,
29 #footer-places,
30 #jump-to-nav,
31 #mw-navigation,
32 #siteNotice,
33 /* Deprecated, changed in core */
34 #f-poweredbyico,
35 #f-copyrightico,
36 li#about,
37 li#disclaimer,
38 li#mobileview,
39 li#privacy {
40 display: none;
41 }
42
43 /**
44 * Generic HTML elements
45 */
46 body {
47 background: #fff;
48 color: #000;
49 margin: 0;
50 padding: 0;
51 }
52
53 /* Links */
54 a {
55 background: none !important; /* stylelint-disable-line declaration-no-important */
56 padding: 0 !important; /* stylelint-disable-line declaration-no-important */
57 }
58
59 a,
60 a.external,
61 a.new,
62 a.stub {
63 /* IE 6 & 7 don't understand `inherit` */
64 color: #000 !important; /* stylelint-disable-line declaration-no-important */
65 text-decoration: none !important; /* stylelint-disable-line declaration-no-important */
66 /* Modern browser will apply this, IE 6 & 7 ignore the unknown */
67 color: inherit !important; /* stylelint-disable-line declaration-block-no-duplicate-properties, declaration-no-important */
68 text-decoration: inherit !important; /* stylelint-disable-line declaration-block-no-duplicate-properties, declaration-no-important */
69 }
70
71 /* Expand URLs for printing */
72 .mw-parser-output a.external.text:after,
73 .mw-parser-output a.external.autonumber:after {
74 content: ' (' attr( href ) ')';
75 word-break: break-all;
76 word-wrap: break-word;
77 }
78
79 /* Expand protocol-relative URLs for printing */
80 .mw-parser-output a.external.text[ href^='//' ]:after,
81 .mw-parser-output a.external.autonumber[ href^='//' ]:after {
82 content: ' (https:' attr( href ) ')';
83 }
84
85 dt {
86 font-weight: bold;
87 }
88
89 h1,
90 h2,
91 h3,
92 h4,
93 h5,
94 h6 {
95 font-weight: bold;
96 /* Pagination */
97 page-break-after: avoid;
98 page-break-before: avoid;
99 }
100
101 p {
102 margin: 1em 0;
103 line-height: 1.2;
104 /* Pagination */
105 orphans: 3;
106 widows: 3;
107 }
108
109 img,
110 figure,
111 .wikitable,
112 .thumb {
113 /* Pagination */
114 page-break-inside: avoid;
115 }
116
117 img {
118 border: 0;
119 vertical-align: middle;
120 }
121
122 pre,
123 .mw-code {
124 background: #fff;
125 color: #000;
126 border: 1pt dashed #000;
127 padding: 1em 0;
128 font-size: 8pt;
129 white-space: pre-wrap;
130 word-wrap: break-word;
131 }
132
133 /* Prevent citations and subscripts from interfering with the line-height */
134 sup,
135 sub {
136 line-height: 1;
137 }
138
139 ul {
140 list-style-type: square;
141 }
142
143 /**
144 * MediaWiki-specific elements
145 */
146 #globalWrapper {
147 width: 100% !important; /* stylelint-disable-line declaration-no-important */
148 min-width: 0 !important; /* stylelint-disable-line declaration-no-important */
149 }
150
151 .mw-body {
152 background: #fff;
153 color: #000;
154 border: 0 !important; /* stylelint-disable-line declaration-no-important */
155 padding: 0 !important; /* stylelint-disable-line declaration-no-important */
156 margin: 0 !important; /* stylelint-disable-line declaration-no-important */
157 direction: ltr;
158 }
159
160 #column-content {
161 margin: 0 !important; /* stylelint-disable-line declaration-no-important */
162 }
163
164 #column-content .mw-body {
165 padding: 1em;
166 margin: 0 !important; /* stylelint-disable-line declaration-no-important */
167 }
168
169 .toc {
170 background-color: #f9f9f9;
171 border: 1pt solid #aaa;
172 padding: 5px;
173 display: table;
174 }
175
176 /* Separate columns for `.tocnumber` and `.toctext` */
177 .tocnumber,
178 .toctext {
179 display: table-cell;
180 }
181
182 /* Space between those columns */
183 .tocnumber {
184 padding-left: 0;
185 padding-right: 0.5em;
186 }
187
188 /* @noflip */
189 .mw-content-ltr .tocnumber {
190 padding-left: 0;
191 padding-right: 0.5em;
192 }
193
194 /* @noflip */
195 .mw-content-rtl .tocnumber {
196 padding-left: 0.5em;
197 padding-right: 0;
198 }
199
200 /**
201 * Floating divs (and thumbnails)
202 */
203 /* @noflip */
204 table.floatright,
205 div.floatright,
206 div.tright {
207 float: right;
208 clear: right;
209 position: relative;
210 }
211
212 /* @noflip */
213 table.floatleft,
214 div.floatleft,
215 div.tleft {
216 float: left;
217 clear: left;
218 position: relative;
219 }
220
221 /* @noflip */
222 div.tleft {
223 margin: 0.5em 1.4em 1.3em 0;
224 }
225
226 /* @noflip */
227 div.tright {
228 margin: 0.5em 0 1.3em 1.4em;
229 }
230
231 /* @noflip */
232 table.floatright,
233 div.floatright {
234 margin: 0 0 0.5em 0.5em;
235 border: 0;
236 }
237
238 /* @noflip */
239 table.floatleft,
240 div.floatleft {
241 margin: 0 0.5em 0.5em 0;
242 border: 0;
243 }
244
245 div.floatleft p,
246 div.floatright p {
247 font-style: italic;
248 }
249
250 .center {
251 text-align: center;
252 }
253
254 /**
255 * Thumbnails
256 */
257 div.thumb {
258 background-color: transparent;
259 width: auto;
260 }
261
262 div.thumb a {
263 border-bottom: 0;
264 }
265
266 div.thumbinner {
267 background-color: #fff;
268 border: 0;
269 border-radius: 2px;
270 padding: 5px;
271 font-size: 10pt;
272 color: #666;
273 text-align: center;
274 /* new block formatting context,
275 * to clear background from floating content */
276 overflow: hidden;
277 min-width: 100px;
278 }
279
280 html .thumbcaption {
281 text-align: left;
282 line-height: 1.4;
283 padding: 3px;
284 }
285
286 img.thumbborder {
287 border: 1pt solid #ddd;
288 }
289
290 /**
291 * Table rendering
292 */
293 /* Compare `table.wikitable` in shared.css */
294 table.wikitable,
295 .mw_metadata {
296 background: #fff;
297 margin: 1em 0;
298 border: 1pt solid #aaa;
299 border-collapse: collapse;
300 font-size: 10pt;
301 }
302
303 table.wikitable > caption,
304 .mw_metadata caption {
305 padding: 5px;
306 font-size: 10pt;
307 }
308
309 table.wikitable > tr > th,
310 table.wikitable > tr > td,
311 table.wikitable > * > tr > th,
312 table.wikitable > * > tr > td,
313 .mw_metadata th,
314 .mw_metadata td {
315 /* Important is required to override any inline styles provided by editors */
316 background: #fff !important; /* stylelint-disable-line declaration-no-important */
317 /* We need to also set color in case editors applied a light text color */
318 color: #000 !important; /* stylelint-disable-line declaration-no-important */
319 border: 1pt solid #aaa;
320 padding: 0.4em 0.6em;
321 }
322
323 table.wikitable > tr > th,
324 table.wikitable > * > tr > th,
325 .mw_metadata th {
326 text-align: center;
327 }
328
329 table.listing,
330 table.listing td {
331 border: 1pt solid #000;
332 border-collapse: collapse;
333 }
334
335 /**
336 * Categories
337 */
338 .catlinks ul {
339 display: inline;
340 padding: 0;
341 list-style: none none;
342 }
343
344 .catlinks li {
345 display: inline-block;
346 line-height: 1.15;
347 margin: 0.1em 0;
348 border-left: 1pt solid #aaa;
349 padding: 0 0.4em;
350 }
351
352 .catlinks li:first-child {
353 border-left: 0;
354 padding-left: 0.2em;
355 }
356
357 /**
358 * Footer
359 */
360 .printfooter {
361 padding: 1em 0;
362 }
363
364 #footer {
365 background: #fff;
366 color: #000;
367 margin-top: 1em;
368 border-top: 1pt solid #aaa;
369 padding-top: 5px;
370 direction: ltr;
371 }