MediaWiki:Common.css: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
| Line 1: | Line 1: | ||
.mw-parser-output . | /* Tighten vertical space in cover cells only */ | ||
.mw-parser-output .wikitable td:first-child { | |||
padding-top: 4px !important; /* was probably 8–12px or more */ | |||
padding-bottom: 4px !important; | |||
vertical-align: middle !important; /* keeps image centered vertically */ | |||
vertical-align: middle; | |||
} | } | ||
.mw-parser-output .cover-preview | /* Ensure the preview container hugs the image tightly */ | ||
width: | .mw-parser-output .cover-preview { | ||
position: relative; | |||
display: inline-block; | |||
width: 80px; /* your thumb width */ | |||
height: auto; | height: auto; | ||
line-height: 1; /* crucial: kills extra line spacing */ | |||
margin: 0; /* no extra margins */ | |||
} | } | ||
.mw-parser-output .cover-preview .cover- | /* Force the small image to have no extra space around it */ | ||
.mw-parser-output .cover-preview .cover-small { | |||
display: block; | |||
margin: 0 auto; /* centers if needed */ | |||
line-height: 1; | |||
vertical-align: middle; | |||
} | } | ||
.mw-parser-output . | /* Optional: if rows are still tall due to text in other columns, constrain overall row */ | ||
.mw-parser-output .wikitable tr { | |||
line-height: 1.2; /* default is often 1.5–1.6; lower it slightly */ | |||
} | } | ||
/* | /* If needed: target the whole cover column for even tighter padding */ | ||
.mw-parser-output .wikitable td:first-child | .mw-parser-output .wikitable td:first-child .cover-preview img { | ||
. | margin: 0 !important; | ||
padding: 0 !important; | |||
} | } | ||
Revision as of 12:03, 29 January 2026
/* Tighten vertical space in cover cells only */
.mw-parser-output .wikitable td:first-child {
padding-top: 4px !important; /* was probably 8–12px or more */
padding-bottom: 4px !important;
vertical-align: middle !important; /* keeps image centered vertically */
}
/* Ensure the preview container hugs the image tightly */
.mw-parser-output .cover-preview {
position: relative;
display: inline-block;
width: 80px; /* your thumb width */
height: auto;
line-height: 1; /* crucial: kills extra line spacing */
margin: 0; /* no extra margins */
}
/* Force the small image to have no extra space around it */
.mw-parser-output .cover-preview .cover-small {
display: block;
margin: 0 auto; /* centers if needed */
line-height: 1;
vertical-align: middle;
}
/* Optional: if rows are still tall due to text in other columns, constrain overall row */
.mw-parser-output .wikitable tr {
line-height: 1.2; /* default is often 1.5–1.6; lower it slightly */
}
/* If needed: target the whole cover column for even tighter padding */
.mw-parser-output .wikitable td:first-child .cover-preview img {
margin: 0 !important;
padding: 0 !important;
}