MediaWiki:Common.css
注意:在发布之后,您可能需要清除浏览器缓存才能看到所作出的变更的影响。
- Firefox或Safari:按住Shift的同时单击刷新,或按Ctrl-F5或Ctrl-R(Mac为⌘-R)
- Google Chrome:按Ctrl-Shift-R(Mac为⌘-Shift-R)
- Internet Explorer或Edge:按住Ctrl的同时单击刷新,或按Ctrl-F5
- Opera:按 Ctrl-F5。
/* 这里放置的CSS将应用于所有皮肤 */
:root {
--custom-background-blue: #ccf;
--custom-background-cyan: #cef;
--custom-background-green: #cfc;
--custom-background-gray: #d2d2d2;
--custom-background-grey: var(--custom-background-gray);
--custom-background-magenta: #fdf;
--custom-background-orange: #fdb;
--custom-background-purple: #ecf;
--custom-background-red: #fcc;
--custom-background-yellow: #ffc;
--custom-border-blue: #36e;
--custom-border-cyan: #9df;
--custom-border-green: #5d5;
--custom-border-gray: #bbb;
--custom-border-grey: var(--custom-border-gray);
--custom-border-magenta: #f9f;
--custom-border-orange: #f90;
--custom-border-purple: #96c;
--custom-border-red: #e44;
--custom-border-yellow: #fc3;
--custom-closed-topic-neutral: #eef;
--custom-closed-topic-no: #fee;
--custom-closed-topic-yes: #efe;
--custom-documentation: #eaf4f9;
--custom-documentation-baddoc: #f9f2ea;
--custom-documentation-nodoc: #f9eaea;
--custom-load-page-button-color: #fff8;
--custom-main-page-background: #fcfcfc;
--custom-main-page-border: var(--custom-border-gray);
--custom-main-page-edition-subheader: #333;
--custom-mcwiki-header-color: #bcd4f5;
--custom-navbox-background: #fff;
--custom-navbox-top: #ccc;
--custom-navbox-middle: #ddd;
--custom-navbox-thru: #eee;
--custom-nbt-inherit-color: #e6e6fa;
--custom-table-background: #f8f9fa;
--custom-table-alternate-background: #f0f1f2;
--custom-table-choice-always: #004100;
--custom-table-choice-always-background: #5dcc5d;
--custom-table-choice-default: #fff;
--custom-table-choice-in-off-background: #060;
--custom-table-choice-in-on-background: #0c0;
--custom-table-choice-na: #000;
--custom-table-choice-neutral: #9c6500;
--custom-table-choice-neutral-background: #ffeb9c;
--custom-table-choice-never: #700005;
--custom-table-choice-never-background: #ff5757;
--custom-table-choice-no: #9c0006;
--custom-table-choice-no-background: #ffc7ce;
--custom-table-choice-out-off-background: #900;
--custom-table-choice-out-on-background: #f00;
--custom-table-choice-partial: #8a7600;
--custom-table-choice-partial-background: #ffd;
--custom-table-choice-planned: #0131b7;
--custom-table-choice-planned-background: #dfdfff;
--custom-table-choice-rarely: #835400;
--custom-table-choice-rarely-background: #fdce5e;
--custom-table-choice-unknown: #222;
--custom-table-choice-unknown-background: #ccc;
--custom-table-choice-yes: #006100;
--custom-table-choice-yes-background: #c6efce;
--custom-table-header-background: #eaecf0;
--custom-topic-30-days: #bbb;
--custom-topic-7-days: #ddd;
}
body.theme-fandomdesktop-dark {
--custom-background-blue: hsl(240, 25%, 12%);
--custom-background-cyan: hsl(190, 25%, 12%);
--custom-background-green: hsl(120, 25%, 12%);
--custom-background-gray: hsl(0, 0%, 12%);
--custom-background-grey: var(--custom-background-gray);
--custom-background-magenta: hsl(310, 25%, 12%);
--custom-background-orange: hsl(40, 25%, 12%);
--custom-background-purple: hsl(260, 25%, 12%);
--custom-background-red: hsl(0, 25%, 12%);
--custom-background-yellow: hsl(60, 25%, 12%);
--custom-border-blue: hsl(240, 15%, 36%);
--custom-border-cyan: hsl(190, 15%, 36%);
--custom-border-green: hsl(120, 15%, 36%);
--custom-border-gray: hsl(0, 0%, 36%);
--custom-border-grey: var(--custom-border-gray);
--custom-border-magenta: hsl(310, 15%, 36%);
--custom-border-orange: hsl(40, 15%, 36%);
--custom-border-purple: hsl(260, 15%, 36%);
--custom-border-red: hsl(0, 15%, 36%);
--custom-border-yellow: hsl(60, 15%, 36%);
--custom-closed-topic-neutral: #2a2a33;
--custom-closed-topic-no: #332a2a;
--custom-closed-topic-yes: #2a332a;
--custom-documentation: #393e3f;
--custom-documentation-baddoc: #3f3c39;
--custom-documentation-nodoc: #3f3939;
--custom-load-page-button-color: #fff2;
--custom-main-page-background: #202125;
--custom-main-page-border: #2e2e2e;
--custom-main-page-edition-subheader: #ddd;
--custom-mcwiki-header-color: #222c39;
--custom-navbox-background: #131313;
--custom-navbox-top: #363636;
--custom-navbox-middle: #2d2d2d;
--custom-navbox-thru: #202020;
--custom-nbt-inherit-color: #404050;
--custom-table-background: #131313;
--custom-table-alternate-background: #202020;
--custom-table-header-background: #363636;
--custom-topic-30-days: #303030;
--custom-topic-7-days: #242424;
}
/* Minecraft font */
@font-face {
font-family: Minecraft;
src: url("/media/hydra/fonts/minecraft.woff") format('woff'),
url("/media/hydra/fonts/minecraft.ttf") format('truetype');
}
/** Main page stylings **/
@supports (flex-wrap: wrap) {
.edition-group {
display: flex;
flex-wrap: wrap;
}
.edition-group .edition-box {
flex: 17.4em;
}
}
/** Template stylings **/
/* [[Template:SimpleNavbox]] */
.navbox {
background: var(--custom-navbox-background);
border: 1px solid var(--theme-border-color);
margin: 1em auto 0;
width: 100%;
}
.navbox table {
background: var(--custom-navbox-background);
}
.navbox table,
.navbox .table-wide {
margin-left: -4px;
margin-right: -2px;
}
.navbox table:first-child,
.navbox .table-wide:first-child {
margin-top: -2px;
}
.navbox table:last-child,
.navbox .table-wide:last-child {
margin-bottom: -2px;
}
.navbox .table-wide {
clear: none;
}
.navbox .navbox-top {
white-space: nowrap;
background-color: var(--custom-navbox-top);
padding: 0 3px;
text-align: center;
}
.navbox .navbox-middle {
white-space: nowrap;
background-color: var(--custom-navbox-middle);
padding: 0 3px;
text-align: center;
}
.navbox .navbox-thru {
white-space: nowrap;
background-color: var(--custom-navbox-thru);
padding: 0 3px;
text-align: center;
}
.navbox-navbar,
.navbox-navbar-mini {
float: left;
font-size: 80%;
}
.navbox-title {
padding: 0 10px;
font-size: 110%;
}
.navbox th {
background-color: var(--custom-navbox-thru);
padding: 0 10px;
white-space: nowrap;
text-align: right;
}
.navbox td {
width: 100%;
padding: 0 0 0 2px;
}
.navbox .table-wide::before {
width: 0;
height: 0;
box-shadow: none;
}
.navbox .table-wide-inner,
.navbox .table-wide table {
margin: 0;
}
/* [[Template:LoadBox]] with navbox */
.loadbox-navbox {
padding: 2px !important;
margin: 1em 0 0 !important;
clear: both;
}
#content .loadbox-navbox > p {
background-color: var(--custom-navbox-top);
text-align: center;
margin: 0;
padding: 0 3px;
}
.loadbox-navbox > p > b {
font-size: 110%;
}
.loadbox-navbox .navbox {
margin: 0 -2px -2px;
border: 0;
}
.loadbox-navbox > .load-page-content > .mw-parser-output > .navbox > tbody > tr:first-child {
display: none;
}
/* [[Template:Hatnote]] */
.hatnote {
text-indent: 2em;
padding-bottom: 0.5em;
margin-bottom: 0.5em;
}
/* [[Template:Director table]] */
.director-table {
float: right;
width: 300px;
}
@media screen and (max-width: 720px) {
.director-table {
float: none;
width: 100%;
}
}
/* [[Template:Layered blueprint]] */
@-webkit-keyframes layered-blueprint-fade-in {
0% {
opacity: 0;
visibility: hidden;
}
100% {
opacity: 1;
visibility: visible;
}
}
@keyframes layered-blueprint-fade-in {
0% {
opacity: 0;
visibility: hidden;
}
100% {
opacity: 1;
visibility: visible;
}
}
.layered-blueprint-layer {
-webkit-animation: layered-blueprint-fade-in 200ms;
animation: layered-blueprint-fade-in 200ms;
}
@-webkit-keyframes layered-blueprint-fade-out {
0% {
opacity: 1;
visibility: visible;
}
100% {
opacity: 0;
visibility: hidden;
}
}
@keyframes layered-blueprint-fade-out {
0% {
opacity: 1;
visibility: visible;
}
100% {
opacity: 0;
visibility: hidden;
}
}
.layered-blueprint-radio:checked + .layered-blueprint-tab + .layered-blueprint-layer ~ .layered-blueprint-layer {
-webkit-animation: layered-blueprint-fade-out 200ms;
animation: layered-blueprint-fade-out 200ms;
}
/* Prevent page jump from the toolbar loading */
.client-js #editform {
/* To disable margin collapsing */
overflow: hidden;
}
.client-js .mw-editform > #wpTextbox1 {
margin-top: 73px;
}
.mw-editform .wikiEditor-ui-top {
min-height: 72px;
}
/* Alternating cell background */
.alternatecells:nth-child(2n+1) {
background-color: var(--custom-table-alternate-background, #f9f9f9);
}
/* Alternating table rows, primarily used with [[Template:Infobox row]] */
.alternaterows tr:nth-child(2n),
.infobox-rows tr:nth-child(2n) {
background-color: var(--custom-table-alternate-background, #f9f9f9);
}
/* Scale file page image to the width of the page */
#file img {
max-width: 100%;
height: auto;
}
/* Highlight clicked reference in blue to help navigation */
ol.references li:target,
sup.reference:target,
span.citation:target {
background-color: #C1DAF2;
}
/* Style the sitenotice, avoid content jumping */
#siteNotice {
margin-bottom: 2px;
text-align: center;
}
#localNotice {
height: 60px;
overflow: hidden;
}
/* Allow parts of toc to be hidden */
/* Section levels */
.toc-hidelevel2 .toclevel-1 ul,
.toc-hidelevel3 .toclevel-2 ul,
.toc-hidelevel4 .toclevel-3 ul,
/* Numbers */
.toc-nonumbers .tocnumber {
display: none;
}
/* Turn a list into a tree view style (See [[.minecraft]]) */
.treeview {
margin-top: 0.3em;
}
.treeview .treeview-header {
padding-left: 3px;
font-weight: bold;
}
.treeview .treeview-header:last-child {
border-color: #636363 !important;
border-left-style: dotted;
}
.treeview .treeview-header:not(:last-child)::before {
content: none;
}
.treeview .treeview-header:last-child::before {
border-bottom: 0;
}
.treeview ul,
.treeview li {
margin: 0;
padding: 0;
list-style-type: none;
list-style-image: none;
}
.treeview li li {
position: relative;
padding-left: 13px;
margin-left: 7px;
border-left: 1px solid #636363;
}
.treeview li li::before {
content: "";
position: absolute;
top: 0;
left: -1px;
width: 11px;
height: 11px;
border-bottom: 1px solid #636363;
}
.treeview li li:last-child:not(.treeview-continue) {
border-color: transparent;
}
.treeview li li:last-child:not(.treeview-continue)::before {
border-left: 1px solid #636363;
width: 10px;
}
.nbttree-inherited {
background-color: var(--custom-nbt-inherit-color);
}
/* Simulate link styling for JS only links */
.jslink {
color: var(--theme-link-color);
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
}
.jslink:hover {
text-decoration: underline;
cursor: pointer;
}
.jslink:active {
color: var(--theme-link-color--hover);
}
/* Try to use nearest neighbour scaling for pixelated images */
.filehistory a img,
.msgbox img,
.pixel-image,
.invslot-item-image,
.spriteedit-new-image,
.sprite {
image-rendering: optimizeSpeed;
image-rendering: -webkit-optimize-contrast;
image-rendering: optimize-contrast;
image-rendering: -moz-crisp-edges;
image-rendering: -o-crisp-edges;
image-rendering: crisp-edges;
image-rendering: pixelated;
-ms-interpolation-mode: nearest-neighbor;
}
/* Make external links the same colour as internal links, the icon is enough to differentiate them */
#mw-content-text a.external {
color: #0645ad;
}
#mw-content-text a.external:visited {
color: #0b0080;
}
#mw-content-text a.external:active {
color: #faa700;
}
/* Mark internal links as plain */
#mw-content-text a.external[href^="https://minecraft.fandom.com/zh/wiki/"],
#mw-content-text a.external[href^="//minecraft.fandom.com/zh/wiki/"] {
background: none;
padding-right: 0;
}
/* Make tabs the correct size */
body {
-moz-tab-size: 4;
-o-tab-size: 4;
tab-size: 4;
}
/* Classes corresponding to Minecraft formatting codes */
.format-0 {
color: #000;
text-shadow: 0.125em 0.125em 0 #000;
}
.format-1 {
color: #00A;
text-shadow: 0.125em 0.125em 0 #00002A;
}
.format-2 {
color: #0A0;
text-shadow: 0.125em 0.125em 0 #002A00;
}
.format-3 {
color: #0AA;
text-shadow: 0.125em 0.125em 0 #002A2A;
}
.format-4 {
color: #A00;
text-shadow: 0.125em 0.125em 0 #2A0000;
}
.format-5 {
color: #A0A;
text-shadow: 0.125em 0.125em 0 #2A002A;
}
.format-6 {
color: #FA0;
text-shadow: 0.125em 0.125em 0 #2A2A00;
}
.format-7 {
color: #AAA;
text-shadow: 0.125em 0.125em 0 #2A2A2A;
}
.format-8 {
color: #555;
text-shadow: 0.125em 0.125em 0 #151515;
}
.format-9 {
color: #55F;
text-shadow: 0.125em 0.125em 0 #15153F;
}
.format-a {
color: #5F5;
text-shadow: 0.125em 0.125em 0 #153F15;
}
.format-b {
color: #5FF;
text-shadow: 0.125em 0.125em 0 #153F3F;
}
.format-c {
color: #F55;
text-shadow: 0.125em 0.125em 0 #3F1515;
}
.format-d {
color: #F5F;
text-shadow: 0.125em 0.125em 0 #3F153F;
}
.format-e {
color: #FF5;
text-shadow: 0.125em 0.125em 0 #3F3F15;
}
.format-f,
#minetip-tooltip {
color: #FFF;
text-shadow: 0.125em 0.125em 0 #3F3F3F;
}
.format-l {
font-weight: bold;
letter-spacing: 0.125em;
}
.format-m {
text-decoration: line-through;
}
.format-n {
text-decoration: underline;
}
.format-o {
font-style: italic;
}
/* Styling for tooltip */
.explain {
border-bottom: 0;
text-decoration: underline dotted;
}
.explain.noline {
text-decoration: none;
}
#minetip-tooltip {
position: fixed;
top: 0;
left: 0;
background-color: #100010;
background-color: rgba(16, 0, 16, 0.94);
padding: 0.375em;
font-family: Minecraft, "Arial Black", Unifont, "WenQuanYi Bitmap Song", SimSun, MingLiU, "GB18030 Bitmap", Beijing, sans-serif;
font-size: 0.99em;
word-spacing: 4px;
white-space: nowrap;
line-height: 1.25em;
margin: 0.125em 0.25em;
pointer-events: none;
z-index: 9999;
}
#minetip-tooltip::before {
content: "";
position: absolute;
top: 0.125em;
right: -0.125em;
bottom: 0.125em;
left: -0.125em;
border: 0.125em solid #100010;
border-style: none solid;
border-color: rgba(16, 0, 16, 0.94);
}
#minetip-tooltip::after {
content: "";
position: absolute;
top: 0.125em;
right: 0;
bottom: 0.125em;
left: 0;
border: 0.125em solid #2D0A63;
border-image: -webkit-linear-gradient(rgba(80, 0, 255, 0.31), rgba(40, 0, 127, 0.31)) 1;
border-image: linear-gradient(rgba(80, 0, 255, 0.31), rgba(40, 0, 127, 0.31)) 1;
}
#minetip-tooltip > .description,
#minetip-tooltip > .minetip-description {
display: block;
margin-top: 0.25em;
}
.invslot-stacksize {
font-family: Minecraft, "Arial Black", sans-serif !important;
}
/* prevent sitenotice show/hide toggle from moving page contents down after pageload */
.globalNotice .globalNoticeDismiss {
float: right;
}
/* history table wrapping issue */
td > code {
display: inline-block;
line-height: 1.2;
}
/* Show abusefilter error footer only once at the end */
.errorbox li:not(:last-child) .abusefilter-message-footer {
display: none;
}
/* Add [[File:Mojang logo.svg]] to known Mojang employee userlinks */
.mw-userlink[title="User:Dinnerbone-gpuser"],
.mw-userlink[title="User:Jeb mojang"],
.mw-userlink[title="User:Jocopa3"],
.mw-userlink[title="User:MidnightEnforcer"],
.mw-userlink[title="User:Minecraft Staff"],
.mw-userlink[title="User:Mojang tommo"],
.mw-userlink[title="User:Slicedlime"],
/* legacy/deleted */
.mw-userlink[title="User:MidnightEnforcer43458@legacy41488102"],
/* previously User:Jonkagstrom47437 */
.mw-userlink[title="User:@DeletedUser40286849"],
/* previously User:shoghicp */
.mw-userlink[title="User:@DeletedUser40317681"] {
padding-left: 18px;
background: url(https://static.wikia.nocookie.net/minecraft_zh_gamepedia/images/a/ad/Mojang_logo.svg/revision/latest) no-repeat left center/16px;
}
/* Add [[File:Grass Block JE6 BE5.png]] to known Minecraft/Mojang-related contractor employee userlinks */
.mw-userlink[title="User:C418bla"] {
padding-left: 18px;
background: url(https://static.wikia.nocookie.net/minecraft_zh_gamepedia/images/6/6a/Grass_Block_JE6_BE5.png/revision/latest) no-repeat left center/16px;
}
/* Add [[File:Gray Mojang Thing.png]] to known ex-Mojang employee userlinks */
.mw-userlink[title="User:EvilSeph"],
.mw-userlink[title="User:ExcitedZe"],
.mw-userlink[title="User:HelenAngel"],
.mw-userlink[title="User:Neon Master"],
.mw-userlink[title="User:RazzleberryFox"],
.mw-userlink[title="User:Tahg"],
.mw-userlink[title="User:Tamerjeison"],
/* previously User:ProfMobius */
.mw-userlink[title="User:@DeletedUser40549330"] {
padding-left: 18px;
background: url(https://static.wikia.nocookie.net/minecraft_zh_gamepedia/images/d/df/Gray_Mojang_Thing.png/revision/latest) no-repeat left center/16px;
}
/* Add [[File:Curse flame.png]] to Gamepedia staff userlinks */
.mw-userlink[title="User:Alianin"],
.mw-userlink[title="User:Azgoodaz"],
.mw-userlink[title="User:Azxiana"],
.mw-userlink[title="User:Chaud"],
.mw-userlink[title="User:CrsBenjamin"],
.mw-userlink[title="User:DBTeamWiki"],
.mw-userlink[title="User:Doneholmes"],
.mw-userlink[title="User:Encredechine"],
.mw-userlink[title="User:Equazcion"],
.mw-userlink[title="User:Ferretwings"],
.mw-userlink[title="User:Ferthi"],
.mw-userlink[title="User:Furl"],
.mw-userlink[title="User:Gam3rkitteh"],
.mw-userlink[title="User:Game widow"],
.mw-userlink[title="User:Hectordonis"],
.mw-userlink[title="User:Heytots"],
.mw-userlink[title="User:HydraGPEBot"],
.mw-userlink[title="User:Majr"],
.mw-userlink[title="User:MannedTooth"],
.mw-userlink[title="User:MarkusRost"],
.mw-userlink[title="User:Misterwoodhouse"],
.mw-userlink[title="User:Mr Pie 5"],
.mw-userlink[title="User:Norrissium"],
.mw-userlink[title="User:OOeyes"],
.mw-userlink[title="User:Pcj"],
.mw-userlink[title="User:ReedemtheD3ad"],
.mw-userlink[title="User:RheingoldRiver"],
.mw-userlink[title="User:SandovalCurse"],
.mw-userlink[title="User:Sitb"],
.mw-userlink[title="User:Smokie"],
.mw-userlink[title="User:Surafbrov"],
.mw-userlink[title="User:Tagaziel"],
.mw-userlink[title="User:TheSatanicSanta"],
.mw-userlink[title="User:Wagnike2"] {
padding-left: 18px;
background: url(https://static.wikia.nocookie.net/minecraft_zh_gamepedia/images/0/02/Curse_flame.png/revision/latest) no-repeat left center/16px;
}
/* CUSTOMIZED RULES */
#siteNotice #localNotice, #siteNotice .globalNotice {
background-color: transparent;
border: none;
}
#localNotice .globalNoticeDismiss {
display: none;
}
/* Add icons for administrations, hide some Chinese varients */
#ca-varlang-1, #ca-varlang-2, #ca-varlang-5, #ca-varlang-6, #ca-varlang-7 {
display: none;
}
pre, tt, samp, .mw-code {
font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace, Courier;
}
code {
display: inline-block;
}
.load-page-button {
background-color: var(--custom-load-page-button-color);
}
.mw-userlink[title="User:Ff98sha"],
.mw-userlink[title="User:Lxazl5770"] {
padding-left: 18px;
background: url(https://static.wikia.nocookie.net/minecraft_zh_gamepedia/images/c/cc/Sprite-bureaucrat.png/revision/latest) no-repeat left center/16px;
}
.mw-userlink[title="User:Anterdc99"],
.mw-userlink[title="User:Hatsuki kiri"],
.mw-userlink[title="User:MysticNebula70"] {
padding-left: 18px;
background: url(https://static.wikia.nocookie.net/minecraft_zh_gamepedia/images/2/2d/Sprite-admin.png/revision/latest) no-repeat left center/16px;
}
.mw-userlink[title="User:KaplanSteve"],
.mw-userlink[title="User:Siiftun1857"],
.mw-userlink[title="User:XiaoXin666"] {
padding-left: 18px;
background: url(https://static.wikia.nocookie.net/minecraft_zh_gamepedia/images/4/4b/Sprite-patrol.png/revision/latest) no-repeat left center/16px;
}
@media screen and (max-width: 720px) {
div#mw-navigation div#mw-panel {
position: static !important;
}
body.page-Minecraft_Wiki.action-view img.banner-image {
display: none;
}
}
div.footer-post {
padding-bottom: 0;
}
/* search on small screens */
@media screen and (max-width: 720px) {
#mw-head {
top: 13px;
}
div#p-search form {
background: none;
border: none;
margin: 0;
}
div#p-search form::before,
div#p-search form::after {
border: none;
}
div#simpleSearch::before {
border-left-color: transparent;
}
div#simpleSearch::after {
border-top-color: transparent;
}
}
/* math symbol fix */
.mwe-math-fallback-image-inline {
padding: 0;
margin: 2px;
vertical-align: middle !important;
}