MediaWiki:Common.css
Note: After publishing, you may have to bypass your browser's cache to see the changes.
- Firefox / Safari: Hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (⌘-R on a Mac)
- Google Chrome: Press Ctrl-Shift-R (⌘-Shift-R on a Mac)
- Edge: Hold Ctrl while clicking Refresh, or press Ctrl-F5.
/* 1. The Container - Holds the relative position */
.mw-parser-output .coverSmall {
position: relative !important;
display: inline-block !important;
width: 60px !important;
height: 80px !important;
vertical-align: middle;
}
/* 2. The Spacer - This image stays in the table flow to hold the row open */
.mw-parser-output .spacer-img {
width: 60px !important;
height: 80px !important;
object-fit: contain !important;
visibility: visible;
}
/* 3. The Zoom Image - Hidden by default, sits on top of the spacer */
.mw-parser-output .zoom-img {
position: absolute !important;
top: 0;
left: 0;
width: 60px !important;
height: 80px !important;
opacity: 0; /* Hidden but clickable */
transition: transform 0.1s ease-in-out !important;
}
/* 4. The Hover State */
.mw-parser-output .coverThumb:hover .zoom-img {
opacity: 1;
width: 350px !important;
height: auto !important;
max-width: none !important;
transform: translate(70px, -20px) !important;
z-index: 10000 !important;
pointer-events: none; /* Prevents flickering if mouse moves over the zoom */
/* Aesthetics */
background: #fff;
border: 1px solid #888;
box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}
/* 5. Keep the spacer visible during hover so the row doesn't collapse */
.mw-parser-output .coverThumb:hover .spacer-img {
visibility: visible !important;
}