MediaWiki:Common.css: Difference between revisions
MediaWiki interface page
More actions
No edit summary |
No edit summary |
||
| (7 intermediate revisions by the same user not shown) | |||
| Line 90: | Line 90: | ||
font-size: 0.95em; | font-size: 0.95em; | ||
} | } | ||
/* Top "hero" row: icon+name on left, description on right */ | /* Top "hero" row: icon+name on left, description on right */ | ||
| Line 133: | Line 121: | ||
} | } | ||
/* Default label cells */ | /* Default label cells (exclude hero row so names never clip) */ | ||
table.spiritvale-skill-infobox tbody tr th:not(.spiritvale-infobox-section-header), | table.spiritvale-skill-infobox tbody tr:not(.spiritvale-infobox-main) th:not(.spiritvale-infobox-section-header), | ||
table.spiritvale-passive-infobox tbody tr th:not(.spiritvale-infobox-section-header) { | table.spiritvale-passive-infobox tbody tr:not(.spiritvale-infobox-main) th:not(.spiritvale-infobox-section-header) { | ||
width: 26%; | width: 26%; | ||
padding: 0.45em 0.85em; | padding: 0.45em 0.85em; | ||
| Line 199: | Line 187: | ||
/* ============================================================ | /* ============================================================ | ||
SpiritVale: Passives ( | SpiritVale: Passives (single source of truth) | ||
- Fixed, consistent desktop width | |||
- Centered body cells | |||
- Mobile hero stays side-by-side (no stacking) | |||
========================================================== */ | ========================================================== */ | ||
/* | /* Desktop tooltip width knob */ | ||
:root { | :root { --sv-passive-width: 540px; } | ||
} | |||
/* | /* Consistent tooltip footprint for ALL passives (desktop) */ | ||
table.spiritvale-passive-infobox { | table.spiritvale-passive-infobox { | ||
width: | width: var(--sv-passive-width); | ||
max-width: var(--sv-passive | max-width: var(--sv-passive-width); /* <-- important: makes desktop actually widen */ | ||
margin: 1em auto; | margin: 1em auto; | ||
table-layout: fixed; | |||
} | |||
/* Keep hero row healthy: allow wrapping in the hero title area */ | |||
table.spiritvale-passive-infobox > tbody > tr.spiritvale-infobox-main > th { | |||
width: 42%; | |||
white-space: normal; | |||
} | |||
table.spiritvale-passive-infobox > tbody > tr.spiritvale-infobox-main > td { | |||
width: 58%; | |||
} | } | ||
/* Center + wrap ALL non-hero rows | /* Center + wrap ALL non-hero rows */ | ||
table.spiritvale-passive-infobox tbody tr:not(.spiritvale-infobox-main) th, | table.spiritvale-passive-infobox tbody tr:not(.spiritvale-infobox-main) th, | ||
table.spiritvale-passive-infobox tbody tr:not(.spiritvale-infobox-main) td { | table.spiritvale-passive-infobox tbody tr:not(.spiritvale-infobox-main) td { | ||
text-align: center; | text-align: center; | ||
vertical-align: middle; | vertical-align: middle; | ||
white-space: normal; | |||
white-space: normal; | |||
overflow-wrap: anywhere; | overflow-wrap: anywhere; | ||
word-break: break-word; | word-break: break-word; | ||
} | } | ||
/* | /* Allow label column to wrap (generic CSS defaults it to nowrap) */ | ||
table.spiritvale-passive-infobox tbody tr:not(.spiritvale-infobox-main) | table.spiritvale-passive-infobox tbody tr:not(.spiritvale-infobox-main) | ||
th:not(.spiritvale-infobox-section-header) { | th:not(.spiritvale-infobox-section-header) { | ||
| Line 240: | Line 234: | ||
} | } | ||
/* | /* Prevent description max-width from pushing weird layout at small widths */ | ||
table.spiritvale-passive-infobox .spiritvale-infobox-description { | table.spiritvale-passive-infobox .spiritvale-infobox-description { | ||
max-width: 100%; | |||
overflow-wrap: anywhere; | overflow-wrap: anywhere; | ||
word-break: break-word; | word-break: break-word; | ||
} | } | ||
/* | /* Passive list layout */ | ||
.spiritvale-passive-list { | .spiritvale-passive-list { | ||
display: flex; | display: flex; | ||
| Line 254: | Line 249: | ||
} | } | ||
/* | /* Citizen/table wrappers: remove the “mystery outline” around some passives in lists */ | ||
.spiritvale-passive-list .mw-table-wrapper, | .spiritvale-passive-list .mw-table-wrapper, | ||
.spiritvale-passive-list .table-overflow, | .spiritvale-passive-list .table-overflow, | ||
| Line 295: | Line 261: | ||
} | } | ||
/* | /* Mobile / portrait / small tablets (Citizen): keep hero row side-by-side */ | ||
@media (max-width: 768px) { | |||
table.spiritvale-passive-infobox | body.skin-citizen table.spiritvale-passive-infobox { | ||
width: 100%; | |||
max-width: 100%; | |||
display: table !important; | |||
} | |||
body.skin-citizen table.spiritvale-passive-infobox > tbody { | |||
display: table-row-group !important; | |||
} | |||
} | |||
body.skin-citizen table.spiritvale-passive-infobox > tbody > tr.spiritvale-infobox-main { | |||
display: table-row !important; | |||
} | } | ||
body.skin-citizen table.spiritvale-passive-infobox > tbody > tr.spiritvale-infobox-main > th, | |||
body.skin-citizen table.spiritvale-passive-infobox > tbody > tr.spiritvale-infobox-main > td { | |||
display: table-cell !important; | |||
float: none !important; | |||
box-sizing: border-box; | |||
vertical-align: middle; | |||
text-align: center; | |||
white-space: normal; | |||
overflow-wrap: anywhere; | |||
word-break: break-word; | |||
} | |||
body.skin-citizen table.spiritvale-passive-infobox > tbody > tr.spiritvale-infobox-main > th { | |||
width: 46% !important; | |||
padding: 0.75em 0.75em; | |||
} | |||
body.skin-citizen table.spiritvale-passive-infobox > tbody > tr.spiritvale-infobox-main > td { | |||
width: 54% !important; | |||
padding: 0.75em 0.75em; | |||
} | |||
body.skin-citizen table.spiritvale-passive-infobox > tbody > tr.spiritvale-infobox-main > th .image img { | |||
width: 64px !important; | |||
height: auto !important; | |||
} | |||
body.skin-citizen table.spiritvale-passive-infobox .spiritvale-infobox-title, | |||
body.skin-citizen table.spiritvale-passive-infobox .spiritvale-infobox-description { | |||
white-space: normal; | |||
overflow-wrap: anywhere; | |||
word-break: break-word; | |||
} | |||
} | } | ||