Merge "StringUtils: Add a utility for checking if a string is a valid regex"
[lhc/web/wiklou.git] / resources / src / mediawiki.legacy / shared.css
1 /**
2 * CSS in this file is used by *all* skins (that have any CSS at all). Be
3 * careful what you put in here, since what looks good in one skin may not in
4 * another, but don't ignore the poor pre-Monobook users either.
5 *
6 * NOTE: The images which are referenced in this file are no longer in use in
7 * essential interface components. They should NOT be embedded, because that
8 * optimizes for the uncommon case at the cost of bloating the size of render-
9 * blocking CSS common to all pages.
10 */
11
12 /* stylelint-disable selector-class-pattern */
13
14 /* GENERAL CLASSES FOR DIRECTIONALITY SUPPORT */
15
16 /**
17 * These classes should be used for text depending on the content direction.
18 * Content stuff like editsection, ul/ol and TOC depend on this.
19 */
20 .mw-content-ltr {
21 /* @noflip */
22 direction: ltr;
23 }
24
25 .mw-content-rtl {
26 /* @noflip */
27 direction: rtl;
28 }
29
30 /* Most input fields should be in site direction */
31 .sitedir-ltr textarea,
32 .sitedir-ltr input {
33 /* @noflip */
34 direction: ltr;
35 }
36
37 .sitedir-rtl textarea,
38 .sitedir-rtl input {
39 /* @noflip */
40 direction: rtl;
41 }
42
43 .mw-userlink {
44 unicode-bidi: embed;
45 }
46
47 /* User-Agent styles for new HTML5 elements */
48 mark {
49 background-color: #ff0;
50 color: #000;
51 }
52
53 /* Helper for wbr element on IE 8+; in HTML5, but not supported by default as of IE 11. */
54 /* Note canonical HTML5 styles recommend "content: \u200B", but this doesn't work as of IE 11. */
55 wbr {
56 display: inline-block;
57 }
58
59 /* Input types that should follow user direction, like buttons */
60 /* TODO: What about buttons in wikipage content ? */
61 input[ type='submit' ],
62 input[ type='button' ],
63 input[ type='reset' ],
64 input[ type='file' ] {
65 direction: ltr;
66 }
67
68 /* Override default values */
69 textarea[ dir='ltr' ],
70 input[ dir='ltr' ] {
71 /* @noflip */
72 direction: ltr;
73 }
74
75 textarea[ dir='rtl' ],
76 input[ dir='rtl' ] {
77 /* @noflip */
78 direction: rtl;
79 }
80
81 /* Default style for semantic tags */
82 abbr[ title ],
83 .explain[ title ] {
84 border-bottom: 1px dotted;
85 cursor: help;
86 }
87
88 @supports ( text-decoration: underline dotted ) {
89 abbr[ title ],
90 .explain[ title ] {
91 border-bottom: 0;
92 text-decoration: underline dotted;
93 }
94 }
95
96 /* Comment portions of RC entries */
97 span.comment {
98 font-style: italic;
99 unicode-bidi: -moz-isolate;
100 unicode-bidi: isolate;
101 }
102
103 /* Stop floats from intruding into edit area in previews */
104 #editform,
105 #toolbar,
106 #wpTextbox1 {
107 clear: both;
108 }
109
110 /* Prevent editing textarea from jumping when toolbar is loaded */
111 #toolbar {
112 height: 22px;
113 }
114
115 /* Underline preference */
116
117 .mw-underline-always a {
118 text-decoration: underline;
119 }
120
121 .mw-underline-never a {
122 text-decoration: none;
123 }
124
125 /**
126 * rev_deleted stuff
127 */
128 li span.deleted,
129 span.history-deleted {
130 text-decoration: line-through;
131 color: #72777d;
132 font-style: italic;
133 }
134
135 /**
136 * Patrol stuff
137 */
138 .not-patrolled {
139 background-color: #ffa;
140 }
141
142 .unpatrolled {
143 font-weight: bold;
144 color: #d33;
145 }
146
147 div.patrollink {
148 font-size: 75%;
149 text-align: right;
150 }
151
152 /**
153 * Forms
154 */
155 td.mw-label {
156 text-align: right;
157 vertical-align: middle;
158 }
159
160 td.mw-input {
161 text-align: left;
162 }
163
164 td.mw-submit {
165 text-align: left;
166 white-space: nowrap;
167 }
168
169 .mw-input-with-label {
170 white-space: nowrap;
171 display: inline-block;
172 }
173
174 /**
175 * Image captions.
176 *
177 * This is only meant to provide the most basic of styles, visual settings shouldn't be added here.
178 */
179
180 /* @noflip */
181 .mw-content-ltr .thumbcaption {
182 text-align: left;
183 }
184
185 /* @noflip */
186 .mw-content-ltr .magnify {
187 float: right;
188 }
189
190 /* @noflip */
191 .mw-content-rtl .thumbcaption {
192 text-align: right;
193 }
194
195 /* @noflip */
196 .mw-content-rtl .magnify {
197 float: left;
198 }
199
200 /**
201 * Categories
202 */
203 #catlinks {
204 /**
205 * Overrides text justification (user preference)
206 * See T33990
207 */
208 text-align: left;
209 }
210
211 .catlinks ul {
212 display: inline;
213 margin: 0;
214 padding: 0;
215 list-style: none none;
216 vertical-align: middle !ie;
217 }
218
219 .catlinks li {
220 display: inline-block;
221 line-height: 1.25em;
222 border-left: 1px solid #a2a9b1;
223 margin: 0.125em 0;
224 padding: 0 0.5em;
225 zoom: 1;
226 display: inline !ie; /* stylelint-disable-line declaration-block-no-duplicate-properties */
227 }
228
229 .catlinks li:first-child {
230 padding-left: 0.25em;
231 border-left: 0;
232 }
233
234 /* (T7346) make category redirects italic */
235 .catlinks li a.mw-redirect {
236 font-style: italic;
237 }
238
239 /**
240 * Hidden categories
241 */
242 .mw-hidden-cats-hidden {
243 display: none;
244 }
245
246 .catlinks-allhidden {
247 display: none;
248 }
249
250 /**
251 * Convenience links to edit delete and protect reasons
252 */
253 p.mw-protect-editreasons,
254 p.mw-filedelete-editreasons,
255 p.mw-delete-editreasons {
256 font-size: 90%;
257 text-align: right;
258 }
259
260 /* The auto-generated edit comments */
261 .autocomment,
262 .autocomment a,
263 .autocomment a:visited {
264 color: #72777d;
265 }
266
267 /** Generic minor/bot/newpage styling (recent changes) */
268 .newpage,
269 .minoredit,
270 .botedit {
271 font-weight: bold;
272 }
273
274 /**
275 * Recreating deleted page warning
276 * Reupload file warning
277 * Page protection warning
278 * incl. log entries for these warnings
279 */
280 div.mw-warning-with-logexcerpt {
281 padding: 3px;
282 margin-bottom: 3px;
283 border: 2px solid #2a4b8d;
284 clear: both;
285 }
286
287 div.mw-warning-with-logexcerpt ul li {
288 font-size: 90%;
289 }
290
291 /* (show/hide) revision deletion links */
292 span.mw-revdelundel-link,
293 strong.mw-revdelundel-link {
294 font-size: 90%;
295 }
296
297 span.mw-revdelundel-hidden,
298 input.mw-revdelundel-hidden {
299 visibility: hidden;
300 }
301
302 td.mw-revdel-checkbox,
303 th.mw-revdel-checkbox {
304 padding-right: 10px;
305 text-align: center;
306 }
307
308 /* red links; see T38276 */
309 a.new {
310 color: #ba0000;
311 }
312
313 /* Plainlinks - this can be used to switch
314 * off special external link styling */
315 .plainlinks a.external {
316 background: none !important; /* stylelint-disable-line declaration-no-important */
317 padding: 0 !important; /* stylelint-disable-line declaration-no-important */
318 }
319
320 /* External URLs should always be treated as LTR (T6330) */
321 /* @noflip */ .rtl a.external.free,
322 .rtl a.external.autonumber {
323 direction: ltr;
324 unicode-bidi: embed;
325 }
326
327 /**
328 * wikitable class for skinning normal tables
329 * keep in sync with commonPrint.css
330 */
331 .wikitable {
332 background-color: #f8f9fa;
333 color: #222;
334 margin: 1em 0;
335 border: 1px solid #a2a9b1;
336 border-collapse: collapse;
337 }
338
339 .wikitable > tr > th,
340 .wikitable > tr > td,
341 .wikitable > * > tr > th,
342 .wikitable > * > tr > td {
343 border: 1px solid #a2a9b1;
344 padding: 0.2em 0.4em;
345 }
346
347 .wikitable > tr > th,
348 .wikitable > * > tr > th {
349 background-color: #eaecf0;
350 text-align: center;
351 }
352
353 .wikitable > caption {
354 font-weight: bold;
355 }
356
357 /* Error, warning, success and neutral messages */
358 .error,
359 .warning,
360 .success {
361 font-size: larger;
362 }
363
364 .error {
365 color: #d33;
366 }
367
368 .warning {
369 color: #ac6600;
370 }
371
372 .success {
373 color: #14866d;
374 }
375
376 .messagebox,
377 .errorbox,
378 .warningbox,
379 .successbox {
380 color: #000;
381 display: inline-block;
382 margin-bottom: 1em;
383 border: 1px solid;
384 padding: 0.5em 1em;
385 }
386
387 .messagebox h2,
388 .errorbox h2,
389 .warningbox h2,
390 .successbox h2 {
391 color: inherit;
392 display: inline;
393 margin: 0 0.5em 0 0;
394 border: 0;
395 font-size: 1em;
396 font-weight: bold;
397 }
398
399 .messagebox {
400 background-color: #eaecf0;
401 border-color: #a2a9b1;
402 }
403
404 .errorbox {
405 background-color: #fee7e6;
406 border-color: #d33;
407 }
408
409 .warningbox {
410 background-color: #fef6e7;
411 border-color: #fc3;
412 }
413
414 .successbox {
415 background-color: #d5fdf4;
416 border-color: #14866d;
417 }
418
419 /* general info/warning box for SP */
420 .mw-infobox {
421 border: 2px solid #fc3;
422 margin: 0.5em;
423 clear: left;
424 overflow: hidden;
425 }
426
427 .mw-infobox-left {
428 margin: 7px;
429 float: left;
430 width: 35px;
431 }
432
433 .mw-infobox-right {
434 margin: 0.5em 0.5em 0.5em 49px;
435 }
436
437 /* Note on preview page */
438 .previewnote {
439 margin-bottom: 1em;
440 }
441
442 .visualClear {
443 clear: both;
444 }
445
446 /**
447 * Data table style
448 *
449 * Table with suddle borders
450 * and row-highlighting.
451 */
452 .mw-datatable {
453 border: 1px solid #a2a9b1;
454 border-collapse: collapse;
455 }
456
457 .mw-datatable td,
458 .mw-datatable th {
459 border: 1px solid #a2a9b1;
460 padding: 0.2em 0.4em;
461 }
462
463 .mw-datatable th {
464 background-color: #eaeeff;
465 }
466
467 .mw-datatable td {
468 background-color: #fff;
469 }
470
471 .mw-datatable tr:hover td {
472 background-color: #eaf3ff;
473 }
474
475 /* Correct directionality when page dir is different from site/user dir */
476 .mw-content-ltr ul,
477 .mw-content-rtl .mw-content-ltr ul {
478 /* @noflip */
479 margin: 0.3em 0 0 1.6em;
480 padding: 0;
481 }
482
483 .mw-content-rtl ul,
484 .mw-content-ltr .mw-content-rtl ul {
485 /* @noflip */
486 margin: 0.3em 1.6em 0 0;
487 padding: 0;
488 }
489
490 .mw-content-ltr ol,
491 .mw-content-rtl .mw-content-ltr ol {
492 /* @noflip */
493 margin: 0.3em 0 0 3.2em;
494 padding: 0;
495 }
496
497 .mw-content-rtl ol,
498 .mw-content-ltr .mw-content-rtl ol {
499 /* @noflip */
500 margin: 0.3em 3.2em 0 0;
501 padding: 0;
502 }
503
504 /* @noflip */
505 .mw-content-ltr dd,
506 .mw-content-rtl .mw-content-ltr dd {
507 margin-left: 1.6em;
508 margin-right: 0;
509 }
510
511 /* @noflip */
512 .mw-content-rtl dd,
513 .mw-content-ltr .mw-content-rtl dd {
514 margin-right: 1.6em;
515 margin-left: 0;
516 }
517
518 .mw-ajax-loader {
519 background-image: url( images/ajax-loader.gif );
520 background-position: center center;
521 background-repeat: no-repeat;
522 padding: 16px;
523 position: relative;
524 top: -16px;
525 }
526
527 .mw-small-spinner {
528 padding: 10px !important; /* stylelint-disable-line declaration-no-important */
529 margin-right: 0.6em;
530 background-image: url( images/spinner.gif );
531 background-position: center center;
532 background-repeat: no-repeat;
533 }
534
535 /* Language specific height correction for titles. Ref T31405 and T32809 */
536 /* Languages like hi or ml require slightly more vertical space to show diacritics properly */
537 h1:lang( anp ),
538 h1:lang( as ),
539 h1:lang( bh ), /* Macrolanguage, used on bh.wikipedia.org, should be removed one day */
540 h1:lang( bho ),
541 h1:lang( bn ),
542 h1:lang( gu ),
543 h1:lang( hi ),
544 h1:lang( kn ),
545 h1:lang( ks ),
546 h1:lang( ml ),
547 h1:lang( mr ),
548 h1:lang( my ),
549 h1:lang( mai ),
550 h1:lang( ne ),
551 h1:lang( new ),
552 h1:lang( or ),
553 h1:lang( pa ),
554 h1:lang( pi ),
555 h1:lang( sa ),
556 h1:lang( ta ),
557 h1:lang( te ) {
558 line-height: 1.6em !important; /* stylelint-disable-line declaration-no-important */
559 }
560
561 /* stylelint-disable selector-list-comma-newline-after */
562 h2:lang( anp ), h3:lang( anp ), h4:lang( anp ), h5:lang( anp ), h6:lang( anp ),
563 h2:lang( as ), h3:lang( as ), h4:lang( as ), h5:lang( as ), h6:lang( as ),
564 h2:lang( bho ), h3:lang( bho ), h4:lang( bho ), h5:lang( bho ), h6:lang( bho ),
565 h2:lang( bh ), h3:lang( bh ), h4:lang( bh ), h5:lang( bh ), h6:lang( bh ),
566 h2:lang( bn ), h3:lang( bn ), h4:lang( bn ), h5:lang( bn ), h6:lang( bn ),
567 h2:lang( gu ), h3:lang( gu ), h4:lang( gu ), h5:lang( gu ), h6:lang( gu ),
568 h2:lang( hi ), h3:lang( hi ), h4:lang( hi ), h5:lang( hi ), h6:lang( hi ),
569 h2:lang( kn ), h3:lang( kn ), h4:lang( kn ), h5:lang( kn ), h6:lang( kn ),
570 h2:lang( ks ), h3:lang( ks ), h4:lang( ks ), h5:lang( ks ), h6:lang( ks ),
571 h2:lang( ml ), h3:lang( ml ), h4:lang( ml ), h5:lang( ml ), h6:lang( ml ),
572 h2:lang( mr ), h3:lang( mr ), h4:lang( mr ), h5:lang( mr ), h6:lang( mr ),
573 h2:lang( my ), h3:lang( my ), h4:lang( my ), h5:lang( my ), h6:lang( my ),
574 h2:lang( mai ), h3:lang( mai ), h4:lang( mai ), h5:lang( mai ), h6:lang( mai ),
575 h2:lang( ne ), h3:lang( ne ), h4:lang( ne ), h5:lang( ne ), h6:lang( ne ),
576 h2:lang( new ), h3:lang( new ), h4:lang( new ), h5:lang( new ), h6:lang( new ),
577 h2:lang( or ), h3:lang( or ), h4:lang( or ), h5:lang( or ), h6:lang( or ),
578 h2:lang( pa ), h3:lang( pa ), h4:lang( pa ), h5:lang( pa ), h6:lang( pa ),
579 h2:lang( pi ), h3:lang( pi ), h4:lang( pi ), h5:lang( pi ), h6:lang( pi ),
580 h2:lang( sa ), h3:lang( sa ), h4:lang( sa ), h5:lang( sa ), h6:lang( sa ),
581 h2:lang( ta ), h3:lang( ta ), h4:lang( ta ), h5:lang( ta ), h6:lang( ta ),
582 h2:lang( te ), h3:lang( te ), h4:lang( te ), h5:lang( te ), h6:lang( te ) {
583 line-height: 1.2em;
584 }
585 /* stylelint-enable selector-list-comma-newline-after */
586
587 /* Localised ordered list numbering for some languages */
588 ol:lang( azb ) li,
589 ol:lang( bcc ) li,
590 ol:lang( bgn ) li,
591 ol:lang( bqi ) li,
592 ol:lang( fa ) li,
593 ol:lang( glk ) li,
594 ol:lang( kk-arab ) li,
595 ol:lang( lrc ) li,
596 ol:lang( luz ) li,
597 ol:lang( mzn ) li {
598 list-style-type: persian;
599 }
600
601 ol:lang( ckb ) li,
602 ol:lang( sdh ) li {
603 list-style-type: arabic-indic;
604 }
605
606 ol:lang( hi ) li,
607 ol:lang( mai ) li,
608 ol:lang( mr ) li,
609 ol:lang( ne ) li {
610 list-style-type: devanagari;
611 }
612
613 ol:lang( as ) li,
614 ol:lang( bn ) li {
615 list-style-type: bengali;
616 }
617
618 ol:lang( or ) li {
619 list-style-type: oriya;
620 }
621
622 .toc ul {
623 margin: 0.3em 0;
624 }
625
626 /* Correct directionality when page dir is different from site/user dir */
627 /* @noflip */ .mw-content-ltr .toc ul,
628 .mw-content-rtl .mw-content-ltr .toc ul {
629 text-align: left;
630 }
631
632 /* @noflip */ .mw-content-rtl .toc ul,
633 .mw-content-ltr .mw-content-rtl .toc ul {
634 text-align: right;
635 }
636
637 /* @noflip */ .mw-content-ltr .toc ul ul,
638 .mw-content-rtl .mw-content-ltr .toc ul ul {
639 margin: 0 0 0 2em;
640 }
641
642 /* @noflip */ .mw-content-rtl .toc ul ul,
643 .mw-content-ltr .mw-content-rtl .toc ul ul {
644 margin: 0 2em 0 0;
645 }
646
647 .toc .toctitle {
648 direction: ltr;
649 }
650
651 #mw-clearyourcache,
652 #mw-sitecsspreview,
653 #mw-sitejspreview,
654 #mw-usercsspreview,
655 #mw-userjspreview {
656 direction: ltr;
657 unicode-bidi: embed;
658 }
659
660 #mw-revision-info,
661 #mw-revision-info-current,
662 #mw-revision-nav {
663 direction: ltr;
664 }
665
666 /* Images */
667
668 /* @noflip */ div.tright,
669 div.floatright,
670 table.floatright {
671 clear: right;
672 float: right;
673 }
674
675 /* @noflip */ div.tleft,
676 div.floatleft,
677 table.floatleft {
678 float: left;
679 clear: left;
680 }
681
682 div.floatright,
683 table.floatright,
684 div.floatleft,
685 table.floatleft {
686 position: relative;
687 }
688
689 /* T14205 */
690 #mw-credits a {
691 unicode-bidi: embed;
692 }
693
694 /* Print footer should be hidden by default in screen. */
695 .printfooter {
696 display: none;
697 }
698
699 /* For developers */
700 .xdebug-error {
701 position: absolute;
702 z-index: 99;
703 }
704
705 .mw-editsection {
706 -moz-user-select: none;
707 -webkit-user-select: none;
708 -ms-user-select: none;
709 user-select: none;
710 }
711
712 /* Display editsection links smaller and next to headings */
713 .mw-editsection,
714 .mw-editsection-like {
715 font-size: small;
716 font-weight: normal;
717 margin-left: 1em;
718 vertical-align: baseline;
719 /* Reset line-height; headings tend to have it set to larger values */
720 line-height: 1em;
721 }
722
723 /* Correct directionality when page dir is different from site/user dir */
724 /* @noflip */
725 .mw-content-ltr .mw-editsection,
726 .mw-content-rtl .mw-content-ltr .mw-editsection {
727 margin-left: 1em;
728 }
729
730 /* @noflip */
731 .mw-content-rtl .mw-editsection,
732 .mw-content-ltr .mw-content-rtl .mw-editsection {
733 margin-right: 1em;
734 }
735
736 /* Prevent citations and subscripts from interfering with the line-height */
737 sup,
738 sub {
739 line-height: 1;
740 }