MediaWiki:Common.css
来自Mindustry中文wiki
注意:在发布之后,您可能需要清除浏览器缓存才能看到所作出的变更的影响。
- 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将应用于所有皮肤 */
/* 让横幅图片自动适应手机屏幕 */
.banner img {
width: 100% !important;
height: auto !important;
}
/* ========== 简易暗黑模式开始 ========== */
/* 1. 全局背景变黑,文字变白 */
body, .mw-page-container {
background-color: #1a1a1a !important; /* 深灰背景 */
color: #e0e0e0 !important; /* 浅灰文字 */
}
/* 2. 中间内容文章区域 */
.mw-body, #content, .mw-page-container-inner {
background-color: #242424 !important; /*稍微浅一点的黑 */
border-color: #444 !important; /* 边框变暗 */
}
/* 3. 链接颜色 (深色背景下蓝色看不清,要改亮一点) */
a { color: #66b0ff !important; } /* 浅蓝色链接 */
a:visited { color: #b084f0 !important; } /* 点过的链接变浅紫 */
a.new { color: #ff6666 !important; } /* 红链变浅红 */
/* 4. 顶部导航栏和侧边栏 */
.vector-header-container, .vector-main-menu-container {
background-color: #222 !important;
}
.mw-ui-icon {
filter: invert(1); /* 图标反色,变成白色 */
}
/* 5. 表格美化 (最重要,否则表格还是白的) */
.wikitable, table {
background-color: #333 !important;
color: white !important;
border: 1px solid #555 !important;
}
.wikitable th, .wikitable td {
border-color: #555 !important;
background-color: #333 !important;
}
.wikitable th {
background-color: #444 !important; /* 表头稍微亮一点 */
}
/* 6. 编辑框和输入框 */
textarea, input, .wikiEditor-ui {
background-color: #333 !important;
color: white !important;
border-color: #555 !important;
}
/* 7. 去掉一些白色的阴影和遮罩 */
.mw-body-content::after { display: none; }
/* ========== 简易暗黑模式结束 ========== */
