Merge "Print styles: Wrap CSS-generated URLs"
[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 */
12 .noprint,
13 div#jump-to-nav,
14 .mw-jump,
15 div.top,
16 div#column-one,
17 .mw-editsection,
18 .mw-editsection-like,
19 #footer-places,
20 .mw-hidden-catlinks,
21 .usermessage,
22 .patrollink,
23 .ns-0 .mw-redirectedfrom,
24 div.magnify,
25 #mw-navigation,
26 #siteNotice,
27 /* Deprecated, changed in core */
28 div#f-poweredbyico,
29 div#f-copyrightico,
30 li#about,
31 li#disclaimer,
32 li#mobileview,
33 li#privacy {
34 display: none;
35 }
36
37 /**
38 * Generic HTML elements
39 */
40 body {
41 background: #fff;
42 color: #000;
43 margin: 0;
44 padding: 0;
45 }
46
47 h1,
48 h2,
49 h3,
50 h4,
51 h5,
52 h6 {
53 font-weight: bold;
54 /* Pagination */
55 page-break-after: avoid;
56 }
57
58 dt {
59 font-weight: bold;
60 }
61
62 ul {
63 list-style-type: square;
64 }
65
66 p {
67 margin: 1em 0;
68 line-height: 1.2em;
69 /* Pagination */
70 orphans: 3;
71 widows: 3;
72 }
73
74 pre,
75 .mw-code {
76 background: #fff;
77 color: #000;
78 border: 1pt dashed #000;
79 padding: 1em 0;
80 font-size: 8pt;
81 white-space: pre;
82 word-wrap: break-word;
83 overflow: auto;
84 }
85
86 img,
87 figure,
88 .wikitable,
89 .thumb {
90 /* Pagination */
91 page-break-inside: avoid;
92 }
93
94 img {
95 border: 0;
96 vertical-align: middle;
97 }
98
99 /**
100 * MediaWiki-specific elements
101 */
102 #globalWrapper {
103 width: 100% !important;
104 min-width: 0 !important;
105 }
106
107 .mw-body {
108 background: #fff;
109 color: #000;
110 border: 0 !important;
111 padding: 0 !important;
112 margin: 0 !important;
113 direction: ltr;
114 }
115
116 #column-content {
117 margin: 0 !important;
118 }
119
120 #column-content .mw-body {
121 padding: 1em;
122 margin: 0 !important;
123 }
124
125 #toc {
126 background-color: #f9f9f9;
127 border: 1pt solid #aaa;
128 padding: 5px;
129 display: table;
130 }
131
132 /* Separate columns for tocnumber and toctext */
133 .tocnumber,
134 .toctext {
135 display: table-cell;
136 }
137
138 /* Space between the columns for tocnumber and toctext */
139 .tocnumber {
140 padding-left: 0;
141 padding-right: 0.5em;
142 }
143
144 /* @noflip */
145 .mw-content-ltr .tocnumber {
146 padding-left: 0;
147 padding-right: 0.5em;
148 }
149
150 /* @noflip */
151 .mw-content-rtl .tocnumber {
152 padding-left: 0.5em;
153 padding-right: 0;
154 }
155
156 #footer {
157 background: #fff;
158 color: #000;
159 margin-top: 1em;
160 border-top: 1pt solid #aaa;
161 direction: ltr;
162 }
163
164 /**
165 * Links
166 */
167 a {
168 background: none !important;
169 padding: 0 !important;
170 }
171
172 /* Expand URLs for printing */
173 .mw-body a.external.text:after,
174 .mw-body a.external.autonumber:after {
175 content: " (" attr( href ) ")";
176 word-break: break-all;
177 word-wrap: break-word;
178 }
179
180 /* Expand protocol-relative URLs for printing */
181 .mw-body a.external.text[href^='//']:after,
182 .mw-body a.external.autonumber[href^='//']:after {
183 content: " (https:" attr( href ) ")";
184 }
185
186 /* MSIE/Win doesn't understand 'inherit' */
187 a,
188 a.external,
189 a.new,
190 a.stub {
191 color: #000 !important;
192 text-decoration: none !important;
193 }
194
195 /* Continue ... */
196 a,
197 a.external,
198 a.new,
199 a.stub {
200 color: inherit !important;
201 text-decoration: inherit !important;
202 }
203
204 /**
205 * Floating divs
206 */
207 /* @noflip */
208 div.floatright {
209 float: right;
210 clear: right;
211 position: relative;
212 margin: 0.5em 0 0.8em 1.4em;
213 }
214
215 div.floatright p {
216 font-style: italic;
217 }
218
219 /* @noflip */
220 div.floatleft {
221 float: left;
222 clear: left;
223 position: relative;
224 margin: 0.5em 1.4em 0.8em 0;
225 }
226
227 div.floatleft p {
228 font-style: italic;
229 }
230
231 div.center {
232 text-align: center;
233 }
234
235 /**
236 * Thumbnails
237 */
238 div.thumb {
239 background-color: transparent;
240 border: 0;
241 width: auto;
242 margin-top: 0.5em;
243 margin-bottom: 0.8em;
244 }
245
246 div.thumbinner {
247 background-color: #fff;
248 border: 1pt solid #ccc;
249 padding: 3px !important;
250 font-size: 94%;
251 text-align: center;
252 }
253
254 html .thumbimage {
255 border: 1pt solid #ccc;
256 }
257
258 html .thumbcaption {
259 border: none;
260 text-align: left;
261 line-height: 1.4em;
262 padding: 3px !important;
263 font-size: 94%;
264 overflow: hidden;
265 word-wrap: break-word;
266 }
267
268 /* @noflip */
269 div.tright {
270 float: right;
271 clear: right;
272 margin: 0.5em 0 0.8em 1.4em;
273 }
274
275 /* @noflip */
276 div.tleft {
277 float: left;
278 clear: left;
279 margin: 0.5em 1.4em 0.8em 0;
280 }
281
282 img.thumbborder {
283 border: 1pt solid #ddd;
284 }
285
286 /**
287 * Table rendering
288 * As on shared.css but with white background.
289 */
290 table.wikitable,
291 table.mw_metadata {
292 background: #fff;
293 margin: 1em 0;
294 border: 1pt solid #aaa;
295 border-collapse: collapse;
296 }
297
298 table.wikitable > tr > th,
299 table.wikitable > tr > td,
300 table.wikitable > * > tr > th,
301 table.wikitable > * > tr > td,
302 .mw_metadata th,
303 .mw_metadata td {
304 border: 1pt solid #aaa;
305 padding: 0.2em;
306 }
307
308 table.wikitable > tr > th,
309 table.wikitable > * > tr > th,
310 .mw_metadata th {
311 background: #fff;
312 font-weight: bold;
313 text-align: center;
314 }
315
316 table.wikitable > caption,
317 .mw_metadata caption {
318 font-weight: bold;
319 }
320
321 table.listing,
322 table.listing td {
323 border: 1pt solid #000;
324 border-collapse: collapse;
325 }
326
327 a.sortheader {
328 margin: 0 0.3em;
329 }
330
331 /**
332 * Categories
333 */
334 .catlinks ul {
335 display: inline;
336 padding: 0;
337 list-style: none none;
338 }
339
340 .catlinks li {
341 display: inline-block;
342 line-height: 1.15em;
343 padding: 0 .4em;
344 border-left: 1pt solid #aaa;
345 margin: 0.1em 0;
346 }
347
348 .catlinks li:first-child {
349 padding-left: .2em;
350 border-left: 0;
351 }
352
353 .printfooter {
354 padding: 1em 0;
355 }