MediaWiki:Common.css: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
| Line 1: | Line 1: | ||
/* 1. | /* 1. Add padding to all table cells so text doesn't hit the edges */ | ||
.mw-parser-output .wikitable td { | .mw-parser-output .wikitable td, | ||
.mw-parser-output .wikitable th { | |||
padding: | padding: 8px 12px !important; /* Adds space on top/bottom and sides */ | ||
vertical-align: middle !important; | vertical-align: middle !important; | ||
overflow: visible !important; | overflow: visible !important; /* Keeps the zoom working */ | ||
} | |||
/* 2. Specific fix for the Cover column to ensure it doesn't squeeze others */ | |||
.mw-parser-output .wikitable td:first-child { | |||
width: 70px !important; /* Gives the thumbnail box a bit of a buffer */ | |||
text-align: center; | |||
} | } | ||
/* | /* 3. Your existing stable box code */ | ||
.mw-parser-output .coverSmall { | .mw-parser-output .coverSmall { | ||
display: block !important; | display: block !important; | ||
| Line 16: | Line 22: | ||
} | } | ||
/* | /* 4. The Image (Normal View) */ | ||
.mw-parser-output .coverSmall img { | .mw-parser-output .coverSmall img { | ||
width: 60px !important; | width: 60px !important; | ||
height: 80px !important; | height: 80px !important; | ||
object-fit: cover !important; | object-fit: cover !important; | ||
display: block !important; | display: block !important; | ||
} | } | ||
/* | /* 5. The Zoom (Hover) */ | ||
.mw-parser-output .coverThumb:hover .coverSmall img { | .mw-parser-output .coverThumb:hover .coverSmall img { | ||
position: absolute !important; | position: absolute !important; | ||
top: 0; | top: 0; | ||
left: 0; | left: 0; | ||
width: 350px !important; | width: 350px !important; | ||
height: auto !important; | height: auto !important; | ||
max-width: none !important; | max-width: none !important; | ||
object-fit: contain !important; | object-fit: contain !important; | ||
transform: translate(85px, -10px) !important; /* Increased move-right to clear new padding */ | |||
transform: translate( | |||
z-index: 10000 !important; | z-index: 10000 !important; | ||
pointer-events: none !important; | pointer-events: none !important; | ||
background: #fff; | background: #fff; | ||
border: 1px solid #888; | border: 1px solid #888; | ||
box-shadow: 0 10px 30px rgba(0,0,0,0.5); | box-shadow: 0 10px 30px rgba(0,0,0,0.5); | ||
} | } | ||
Revision as of 10:14, 29 January 2026
/* 1. Add padding to all table cells so text doesn't hit the edges */
.mw-parser-output .wikitable td,
.mw-parser-output .wikitable th {
padding: 8px 12px !important; /* Adds space on top/bottom and sides */
vertical-align: middle !important;
overflow: visible !important; /* Keeps the zoom working */
}
/* 2. Specific fix for the Cover column to ensure it doesn't squeeze others */
.mw-parser-output .wikitable td:first-child {
width: 70px !important; /* Gives the thumbnail box a bit of a buffer */
text-align: center;
}
/* 3. Your existing stable box code */
.mw-parser-output .coverSmall {
display: block !important;
width: 60px !important;
height: 80px !important;
margin: 0 auto;
position: relative !important;
}
/* 4. The Image (Normal View) */
.mw-parser-output .coverSmall img {
width: 60px !important;
height: 80px !important;
object-fit: cover !important;
display: block !important;
}
/* 5. The Zoom (Hover) */
.mw-parser-output .coverThumb:hover .coverSmall img {
position: absolute !important;
top: 0;
left: 0;
width: 350px !important;
height: auto !important;
max-width: none !important;
object-fit: contain !important;
transform: translate(85px, -10px) !important; /* Increased move-right to clear new padding */
z-index: 10000 !important;
pointer-events: none !important;
background: #fff;
border: 1px solid #888;
box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}