MediaWiki:Common.css: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
| Line 1: | Line 1: | ||
/* 1. | /* 1. The Table Cell - Lock the height so it CANNOT collapse */ | ||
.mw-parser-output .wikitable td { | .mw-parser-output .wikitable td { | ||
height: | height: 85px !important; | ||
padding: | padding: 10px 15px !important; /* This adds your 'Ends of the world' spacing */ | ||
vertical-align: middle !important; | vertical-align: middle !important; | ||
overflow: visible !important; | overflow: visible !important; | ||
} | } | ||
/* 2. The Container */ | /* 2. The Container - Fixed size box */ | ||
.mw-parser-output .coverSmall { | .mw-parser-output .coverSmall { | ||
display: block !important; | display: block !important; | ||
| Line 16: | Line 16: | ||
} | } | ||
/* 3. The Image | /* 3. The Spacer Image - This stays in the table to hold the space */ | ||
.mw-parser-output .coverSmall img { | .mw-parser-output .coverSmall img.spacer-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; | ||
visibility: visible !important; | |||
position: static !important; /* Keeps it in the normal flow */ | |||
} | } | ||
/* 4. The Zoom ( | /* 4. The Zoom Image - Normal State (Hidden on top of spacer) */ | ||
.mw-parser-output . | .mw-parser-output .coverSmall img.zoom-img { | ||
width: 60px !important; | |||
height: 80px !important; | |||
position: absolute !important; | position: absolute !important; | ||
top: 0; | top: 0; | ||
left: 0; | left: 0; | ||
opacity: 0; /* Hide it until hover */ | |||
} | |||
/* 5. The Zoom Image - Hover State (The "Pop Out") */ | |||
.mw-parser-output .coverThumb:hover .coverSmall img.zoom-img { | |||
opacity: 1 !important; | |||
width: 350px !important; | width: 350px !important; | ||
height: auto !important; | height: auto !important; | ||
max-width: none !important; | max-width: none !important; | ||
object-fit: contain !important; | |||
/* | /* Move it right to clear the thumb and the 15px padding */ | ||
transform: translate(100px, -20px) !important; | |||
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 11:00, 29 January 2026
/* 1. The Table Cell - Lock the height so it CANNOT collapse */
.mw-parser-output .wikitable td {
height: 85px !important;
padding: 10px 15px !important; /* This adds your 'Ends of the world' spacing */
vertical-align: middle !important;
overflow: visible !important;
}
/* 2. The Container - Fixed size box */
.mw-parser-output .coverSmall {
display: block !important;
width: 60px !important;
height: 80px !important;
margin: 0 auto;
position: relative !important;
}
/* 3. The Spacer Image - This stays in the table to hold the space */
.mw-parser-output .coverSmall img.spacer-img {
width: 60px !important;
height: 80px !important;
object-fit: cover !important;
display: block !important;
visibility: visible !important;
position: static !important; /* Keeps it in the normal flow */
}
/* 4. The Zoom Image - Normal State (Hidden on top of spacer) */
.mw-parser-output .coverSmall img.zoom-img {
width: 60px !important;
height: 80px !important;
position: absolute !important;
top: 0;
left: 0;
opacity: 0; /* Hide it until hover */
}
/* 5. The Zoom Image - Hover State (The "Pop Out") */
.mw-parser-output .coverThumb:hover .coverSmall img.zoom-img {
opacity: 1 !important;
width: 350px !important;
height: auto !important;
max-width: none !important;
object-fit: contain !important;
/* Move it right to clear the thumb and the 15px padding */
transform: translate(100px, -20px) !important;
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);
}