Template:Infobox hero/styles.css: Difference between revisions

Jump to navigation Jump to search
Vergir (talk | contribs)
Add stat cell modifier classes, replacing inline styles in the hero infobox (with help from vergir-bot LLM)
Vergir (talk | contribs)
Harden stat cell modifier selectors so they no longer depend on source order to win (with help from vergir-bot LLM)
Line 447: Line 447:
/* ------------ Stat Cell Modifiers -------------------*/
/* ------------ Stat Cell Modifiers -------------------*/
/* Applied by [[Module:InfoboxHero]] in place of inline styles.
/* Applied by [[Module:InfoboxHero]] in place of inline styles.
   Both selectors must out-specify
   The leading .infobox-h keeps these ahead of
   '.infobox-h-dropdown .infobox-h-subsection-child tr:first-child > td',
   '.infobox-h-dropdown .infobox-h-subsection-child tr:first-child > td',
   which would otherwise win. */
   which they would otherwise merely tie with, leaving them dependent on
  source order. */


/* Headroom for a section's first row when it carries a scaling icon. */
/* Headroom for a section's first row when it carries a scaling icon. */
.infobox-h-dropdown .infobox-h-subsection-child tr > td.infobox-h-stat-label-scaled{
.infobox-h .infobox-h-dropdown .infobox-h-subsection-child tr > td.infobox-h-stat-label-scaled{
padding-top: 8px;
padding-top: 8px;
}
}


/* Breathing room for value cells whose scaling icon sits near the edge. */
/* Breathing room for value cells whose scaling icon sits near the edge. */
.infobox-h-dropdown .infobox-h-subsection-child tr > td.infobox-h-stat-value-padded{
.infobox-h .infobox-h-dropdown .infobox-h-subsection-child tr > td.infobox-h-stat-value-padded{
padding-right: 5px;
padding-right: 5px;
}
}