MediaWiki:Common.css

MediaWiki interface page
Revision as of 16:54, 2 December 2020 by RogerDodger (talk | contribs)

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)
  • Internet Explorer / Edge: Hold Ctrl while clicking Refresh, or press Ctrl-F5
  • Opera: Press Ctrl-F5.
/* 
 * CSS placed here will be applied to all skins
 */

/* less table padding, and not wasting space in cells without a sort button */

.skin-citizen table.wikitable tr td,
.skin-citizen table.wikitable tr th {
   padding: 5px;
}

.skin-citizen table.wikitable tr th.headerSort {
  padding-right: 21px;
}

/* helper classes to change alignment of columns in table */

.col-1-center td:nth-child(1) { text-align: center; }
.col-2-center td:nth-child(2) { text-align: center; }
.col-3-center td:nth-child(3) { text-align: center; }
.col-4-center td:nth-child(4) { text-align: center; }
.col-5-center td:nth-child(5) { text-align: center; }
.col-6-center td:nth-child(6) { text-align: center; }
.col-7-center td:nth-child(7) { text-align: center; }
.col-8-center td:nth-child(8) { text-align: center; }
.col-9-center td:nth-child(9) { text-align: center; }

.col-1-end td:nth-child(1) { text-align: end; }
.col-2-end td:nth-child(2) { text-align: end; }
.col-3-end td:nth-child(3) { text-align: end; }
.col-4-end td:nth-child(4) { text-align: end; }
.col-5-end td:nth-child(5) { text-align: end; }
.col-6-end td:nth-child(6) { text-align: end; }
.col-7-end td:nth-child(7) { text-align: end; }
.col-8-end td:nth-child(8) { text-align: end; }
.col-9-end td:nth-child(9) { text-align: end; }

/* font based on in-game Tekken symbols */

@font-face {
   font-family: IronFist;
   src: url('/w/skins/Tekken/Iron-Fist.woff');
   font-weight: normal;
   font-style: normal;
   font-display: block;
}

.ironfist {
  font-family: IronFist;
}

/*
 * Colors are from https://www.hsluv.org/ color space
 * 
 * Light mode bg: hsluv(0, 0, 100)
 * Dark mode bg: hsluv(0, 0, 5)
 *
 * == hue
 * red    12
 * yellow 65
 * green  120
 * blue   240
 *
 * == saturation
 * base   100
 * muddy  50
 *
 * == lightness
 * base   80
 * {n}    100 - {n}
 * 
 * == lightness (dark mode)
 * base   25
 * {n}    5 + {n}
 */
 
:root {
   --blue-muddy-05: #ecf1f8;
   --yellow: #efc200;
   --green: #6de000;
   --red: #ffb3b3;
}

@media (prefers-color-scheme: dark) {
   :root {
      --blue-muddy-05: #121d26;
      --yellow: #493a00;
      --green: #1c4400;
      --red: #7e0002;
   }
   
   body.skin-citizen {
      background-color: #111111;
   }
}

.bg-green { background-color: var(--green); }
.bg-red { background-color: var(--red); }
.bg-yellow { background-color: var(--yellow); }

.hover-bg-blue-muddy-05:hover {
	background-color: var(--blue-muddy-05);
}