MediaWiki:Common.css: Difference between revisions
MediaWiki interface page
More actions
Add scoped responsive Game screenshot alignment styles |
Account for skin table wrapper when matching screenshot and table height |
||
| Line 154: | Line 154: | ||
} | } | ||
.aftermarket-game-overview .aftermarket-game-details { min-width: 0; } | .aftermarket-game-overview .aftermarket-game-details { min-width: 0; } | ||
.aftermarket-game-overview .aftermarket-game-details | .aftermarket-game-overview .aftermarket-game-details .wikitable { | ||
width: 100%; | width: 100%; | ||
margin: 0; | margin: 0; | ||
Revision as of 19:47, 17 October 2026
/* CSS placed here will be applied to all skins */
/* Aftermarket Games: Game and Platform titles */
body:has(.aftermarket-game) #firstHeading,
body:has(.aftermarket-game) .mw-first-heading,
body:has(.aftermarket-game) .mw-page-title-main,
body:has(.aftermarket-platform) #firstHeading,
body:has(.aftermarket-platform) .mw-first-heading,
body:has(.aftermarket-platform) .mw-page-title-main {
font-size: 2em !important;
font-weight: 700 !important;
}
/* Aftermarket Games: Platform game directory */
.aftermarket-platform-games ul {
list-style: none !important;
padding-left: 0;
margin-left: 0;
}
.aftermarket-platform-games li {
margin-bottom: 6px;
}
/* Aftermarket Games: Platform device photograph */
.aftermarket-platform-photo {
display: flex;
align-items: flex-start;
justify-content: center;
height: 215px;
line-height: 0;
margin: 0;
}
.aftermarket-platform-photo p {
margin: 0;
}
/* Aftermarket Games: Dynamic Developer listings */
/* Dynamic Developer page heading */
.aftermarket-developer {
font-family: "Linux Libertine", Georgia, "Times New Roman", serif;
font-size: 3.8em;
font-weight: 700;
line-height: 1.05;
margin-top: -80px;
margin-bottom: 8px;
padding-bottom: 4px;
border-bottom: 4px solid #36c;
}
/* Remove MediaWiki paragraph spacing inside Developer headings */
.aftermarket-developer p {
margin: 0;
padding: 0;
}
/* Space between Games Developed heading and game listings */
.aftermarket-developer-games {
margin-top: 5px;
}
.aftermarket-developer-games ul {
column-count: 4;
column-gap: 24px;
list-style: none !important;
padding-left: 0;
margin-left: 0;
}
.aftermarket-developer-games li {
break-inside: avoid;
margin-bottom: 6px;
}
/* Adjust columns for smaller screens */
@media (max-width: 700px) {
.aftermarket-developer-games ul {
column-count: 2;
}
}
/* Hide the generic title on dynamic Developer listings only */
body:has(.aftermarket-developer) #firstHeading,
body:has(.aftermarket-developer) .mw-first-heading {
display: none;
}
/* Hide the extra query form on dynamic Developer pages */
body:has(.aftermarket-developer) #pfForm {
display: none;
}
/* Hide the Additional query heading on Developer pages */
body:has(.aftermarket-developer) h2:has(+ #pfForm) {
display: none;
}
/* Developer profile editing link */
.aftermarket-developer-edit {
margin: 8px 0 20px;
font-size: 0.9em;
}
.aftermarket-developer-edit a,
.aftermarket-developer-edit a.new {
color: #54595d;
text-decoration: none;
}
.aftermarket-developer-edit a::before {
content: "✎ ";
}
.aftermarket-developer-edit a:hover {
color: #36c;
text-decoration: underline;
}
/* Developer profile image alignment */
.aftermarket-developer-profile {
align-items: flex-start !important;
}
.aftermarket-developer-profile .aftermarket-platform-photo {
display: block;
align-self: flex-start;
height: auto;
margin: 0;
padding: 0;
line-height: 0;
}
.aftermarket-developer-profile .aftermarket-platform-photo p {
margin: 0;
padding: 0;
}
.aftermarket-developer-profile .aftermarket-platform-photo img {
display: block;
}
/* Game overview: screenshot left, table right; preserve the image aspect ratio. */
.aftermarket-game-overview {
display: grid;
grid-template-columns: minmax(0, 450px);
align-items: stretch;
gap: 24px;
max-width: 924px;
margin-top: 0;
container-type: inline-size;
}
.aftermarket-game-overview:has(.aftermarket-game-photo) {
grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}
.aftermarket-game-overview .aftermarket-game-details { min-width: 0; }
.aftermarket-game-overview .aftermarket-game-details .wikitable {
width: 100%;
margin: 0;
}
.aftermarket-game-overview .aftermarket-game-photo {
position: relative;
min-width: 0;
line-height: 0;
}
.aftermarket-game-overview .aftermarket-game-photo p { margin: 0; }
.aftermarket-game-overview .aftermarket-game-photo a.mw-file-description {
position: absolute;
inset: 0;
display: block;
}
.aftermarket-game-overview .aftermarket-game-photo img {
display: block;
width: 100% !important;
height: 100% !important;
max-width: 100%;
max-height: 100%;
object-fit: contain;
object-position: center;
}
/* Stack in a narrow content column, including sidebar-heavy layouts. */
@container (max-width: 640px) {
.aftermarket-game-overview .aftermarket-game-photo,
.aftermarket-game-overview .aftermarket-game-details { grid-column: 1 / -1; }
.aftermarket-game-overview .aftermarket-game-photo a.mw-file-description { position: static; }
.aftermarket-game-overview .aftermarket-game-photo img {
width: auto !important;
height: auto !important;
max-width: 100%;
max-height: none;
margin: 0 auto;
}
}