MediaWiki:Common.css:修订间差异
MediaWiki界面页面
更多操作
ContentBot2(留言 | 贡献) 深色模式重写:属性选择器 !important 覆盖内联样式 + 渐变标题增强 |
ContentBot2(留言 | 贡献) 深色模式:属性选择器 !important + 渐变标题 @supports |
||
| 第41行: | 第41行: | ||
} | } | ||
/* === | /* === 深色模式(!important 覆盖内联样式) === */ | ||
. | /* night — 手动深色 */ | ||
. | html.skin-theme-clientpref-night [style*="color:#2a4b8a"] { color:#4a90d9 !important; } | ||
. | html.skin-theme-clientpref-night [style*="color:#666"] { color:#999 !important; } | ||
. | html.skin-theme-clientpref-night [style*="border:1px solid #e0e4ea"] { border-color:#2a3040 !important; } | ||
. | html.skin-theme-clientpref-night [style*="background:#fff"] { background:#1c2028 !important; } | ||
. | html.skin-theme-clientpref-night [style*="color:#1a1a2e"] { color:#e0e4ea !important; } | ||
. | html.skin-theme-clientpref-night [style*="color:#555"] { color:#aaa !important; } | ||
. | html.skin-theme-clientpref-night [style*="background:#f0f7ff"] { background:#182230 !important; } | ||
. | html.skin-theme-clientpref-night [style*="border:1px solid #b8d4f0"] { border-color:#2a3a50 !important; } | ||
. | /* os — 跟随系统 */ | ||
. | @media (prefers-color-scheme: dark) { | ||
. | html.skin-theme-clientpref-os [style*="color:#2a4b8a"] { color:#4a90d9 !important; } | ||
. | html.skin-theme-clientpref-os [style*="color:#666"] { color:#999 !important; } | ||
.robuddy- | html.skin-theme-clientpref-os [style*="border:1px solid #e0e4ea"] { border-color:#2a3040 !important; } | ||
html.skin-theme-clientpref-os [style*="background:#fff"] { background:#1c2028 !important; } | |||
.robuddy- | html.skin-theme-clientpref-os [style*="color:#1a1a2e"] { color:#e0e4ea !important; } | ||
html.skin-theme-clientpref-os [style*="color:#555"] { color:#aaa !important; } | |||
html.skin-theme-clientpref-os [style*="background:#f0f7ff"] { background:#182230 !important; } | |||
html.skin-theme-clientpref-os [style*="border:1px solid #b8d4f0"] { border-color:#2a3a50 !important; } | |||
} | |||
/* 渐变标题 — 仅现代浏览器 */ | |||
@supports (-webkit-background-clip: text) { | |||
.robuddy-hero-title { background:linear-gradient(135deg,#2a4b8a,#00b4d8) !important; -webkit-background-clip:text !important; -webkit-text-fill-color:transparent !important; background-clip:text !important; color:transparent !important; } | |||
html.skin-theme-clientpref-night .robuddy-hero-title, | |||
html.skin-theme-clientpref-os .robuddy-hero-title { background:linear-gradient(135deg,#4a90d9,#00b4d8) !important; } | |||
} | |||
2026年7月19日 (日) 23:04的版本
/* 隐藏页脚底部徽章和编辑提示,保留品牌链接 */
.citizen-footer__bottom { display:none; }
/* 浅色模式 */
.robuddy-infobox { float:right; margin-left:1em; margin-bottom:1em; width:280px; border:1px solid #c8ccd1; border-collapse:collapse; background:#fff; border-radius:8px; overflow:hidden; }
.robuddy-infobox-title { background:#2a4b8a; color:#fff; text-align:center; padding:10px 8px; font-weight:bold; }
.robuddy-infobox-image { text-align:center; padding:8px; }
.robuddy-infobox-row { background:#f6f7f9; }
.robuddy-infobox-row:nth-child(even) { background:#eef0f3; }
.robuddy-infobox-label { width:90px; font-weight:bold; padding:5px 10px; color:#333; }
.robuddy-infobox-value { padding:5px 10px; color:#222; }
.robuddy-infobox-en { font-size:smaller; color:#666; }
.robuddy-warning, .robuddy-note, .robuddy-danger { padding:10px 14px; margin:0.6em 0; border-radius:6px; border-left:4px solid; }
.robuddy-warning { background:#fffbf0; border-color:#e5a800; color:#5c4800; }
.robuddy-note { background:#f0f7ff; border-color:#3b82f6; color:#1e3a5f; }
.robuddy-danger { background:#fff0f0; border-color:#dc2626; color:#7f1d1d; }
/* 深色模式 - 手动切换(night) */
html.skin-theme-clientpref-night .robuddy-infobox { border-color:#333a44; background:#1c2028; }
html.skin-theme-clientpref-night .robuddy-infobox-title { background:#2e3a4e; color:#dce4f0; }
html.skin-theme-clientpref-night .robuddy-infobox-row { background:#222830; }
html.skin-theme-clientpref-night .robuddy-infobox-row:nth-child(even) { background:#1c2028; }
html.skin-theme-clientpref-night .robuddy-infobox-label { color:#a0aab8; }
html.skin-theme-clientpref-night .robuddy-infobox-value { color:#c8d0dc; }
html.skin-theme-clientpref-night .robuddy-infobox-en { color:#7a8494; }
html.skin-theme-clientpref-night .robuddy-warning { background:#2a2518; border-color:#c49a30; color:#d4b060; }
html.skin-theme-clientpref-night .robuddy-note { background:#182230; border-color:#4a90d9; color:#7ab8e8; }
html.skin-theme-clientpref-night .robuddy-danger { background:#2a1a1a; border-color:#c44040; color:#e08080; }
/* 深色模式 - 跟随系统(os) */
@media (prefers-color-scheme: dark) {
html.skin-theme-clientpref-os .robuddy-infobox { border-color:#333a44; background:#1c2028; }
html.skin-theme-clientpref-os .robuddy-infobox-title { background:#2e3a4e; color:#dce4f0; }
html.skin-theme-clientpref-os .robuddy-infobox-row { background:#222830; }
html.skin-theme-clientpref-os .robuddy-infobox-row:nth-child(even) { background:#1c2028; }
html.skin-theme-clientpref-os .robuddy-infobox-label { color:#a0aab8; }
html.skin-theme-clientpref-os .robuddy-infobox-value { color:#c8d0dc; }
html.skin-theme-clientpref-os .robuddy-infobox-en { color:#7a8494; }
html.skin-theme-clientpref-os .robuddy-warning { background:#2a2518; border-color:#c49a30; color:#d4b060; }
html.skin-theme-clientpref-os .robuddy-note { background:#182230; border-color:#4a90d9; color:#7ab8e8; }
html.skin-theme-clientpref-os .robuddy-danger { background:#2a1a1a; border-color:#c44040; color:#e08080; }
}
/* === 深色模式(!important 覆盖内联样式) === */
/* night — 手动深色 */
html.skin-theme-clientpref-night [style*="color:#2a4b8a"] { color:#4a90d9 !important; }
html.skin-theme-clientpref-night [style*="color:#666"] { color:#999 !important; }
html.skin-theme-clientpref-night [style*="border:1px solid #e0e4ea"] { border-color:#2a3040 !important; }
html.skin-theme-clientpref-night [style*="background:#fff"] { background:#1c2028 !important; }
html.skin-theme-clientpref-night [style*="color:#1a1a2e"] { color:#e0e4ea !important; }
html.skin-theme-clientpref-night [style*="color:#555"] { color:#aaa !important; }
html.skin-theme-clientpref-night [style*="background:#f0f7ff"] { background:#182230 !important; }
html.skin-theme-clientpref-night [style*="border:1px solid #b8d4f0"] { border-color:#2a3a50 !important; }
/* os — 跟随系统 */
@media (prefers-color-scheme: dark) {
html.skin-theme-clientpref-os [style*="color:#2a4b8a"] { color:#4a90d9 !important; }
html.skin-theme-clientpref-os [style*="color:#666"] { color:#999 !important; }
html.skin-theme-clientpref-os [style*="border:1px solid #e0e4ea"] { border-color:#2a3040 !important; }
html.skin-theme-clientpref-os [style*="background:#fff"] { background:#1c2028 !important; }
html.skin-theme-clientpref-os [style*="color:#1a1a2e"] { color:#e0e4ea !important; }
html.skin-theme-clientpref-os [style*="color:#555"] { color:#aaa !important; }
html.skin-theme-clientpref-os [style*="background:#f0f7ff"] { background:#182230 !important; }
html.skin-theme-clientpref-os [style*="border:1px solid #b8d4f0"] { border-color:#2a3a50 !important; }
}
/* 渐变标题 — 仅现代浏览器 */
@supports (-webkit-background-clip: text) {
.robuddy-hero-title { background:linear-gradient(135deg,#2a4b8a,#00b4d8) !important; -webkit-background-clip:text !important; -webkit-text-fill-color:transparent !important; background-clip:text !important; color:transparent !important; }
html.skin-theme-clientpref-night .robuddy-hero-title,
html.skin-theme-clientpref-os .robuddy-hero-title { background:linear-gradient(135deg,#4a90d9,#00b4d8) !important; }
}