MediaWiki:Common.css:修订间差异
首页焦点故事: 背景图定位样式 |
新增 .mw-flag 行内标记样式(小卡片:78% 字号、上标、极窄内边距,三种语义色) |
||
| (未显示同一用户的9个中间版本) | |||
| 第130行: | 第130行: | ||
} | } | ||
.news-title { flex: | .news-title { | ||
flex: 0 0 auto; | |||
white-space: nowrap; | |||
} | |||
.news-summary { color: #888; font-size: 13px; } | .news-summary { color: #888; font-size: 13px; } | ||
| 第403行: | 第406行: | ||
overflow: hidden; | overflow: hidden; | ||
} | } | ||
.news-featured- | /* 文件链接会被 MediaWiki 包进 <p>, 命中 p 及其内 img */ | ||
.news-featured > p:first-child, | |||
.news-featured > p:first-child img { | |||
position: absolute; | position: absolute; | ||
inset: 0; | inset: 0; | ||
| 第410行: | 第415行: | ||
object-fit: cover; | object-fit: cover; | ||
z-index: 0; | z-index: 0; | ||
margin: 0; | |||
} | } | ||
.news-featured > :not( | .news-featured > :not(p:first-child) { | ||
position: relative; | position: relative; | ||
z-index: 1; | z-index: 1; | ||
| 第417行: | 第423行: | ||
.news-featured-img .news-featured-tag { | .news-featured-img .news-featured-tag { | ||
background: rgba(0, 0, 0, 0.55); | background: rgba(0, 0, 0, 0.55); | ||
} | |||
.news-featured-img .news-featured-title, | |||
.news-featured-img .news-featured-summary { | |||
display: inline-block; | |||
padding: 4px 10px; | |||
border-radius: 8px; | |||
background: rgba(0, 0, 0, 0.45); | |||
-webkit-backdrop-filter: blur(6px); | |||
backdrop-filter: blur(6px); | |||
} | } | ||
.news-featured-img .news-featured-summary { | .news-featured-img .news-featured-summary { | ||
| 第425行: | 第440行: | ||
text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8); | text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8); | ||
} | } | ||
.news-featured-img .news-featured-link { | |||
display: inline-block; | |||
padding: 4px 10px; | |||
border-radius: 8px; | |||
background: rgba(0, 0, 0, 0.45); | |||
-webkit-backdrop-filter: blur(6px); | |||
backdrop-filter: blur(6px); | |||
} | |||
.news-featured-img .news-featured-link a { | |||
color: #fff; | |||
} | |||
/* 新闻条目: 标题/摘要不换行(超长省略), 链接文字可换行 */ | |||
.news-summary { | |||
flex: 1 1 auto; | |||
min-width: 0; | |||
white-space: nowrap; | |||
overflow: hidden; | |||
text-overflow: ellipsis; | |||
} | |||
.news-link { | |||
flex: 0 0 auto; | |||
white-space: normal; | |||
word-break: break-word; | |||
} | |||
/* ===== 维护提示框 (模板:维护提示) ===== */ | |||
.mw-maint-box { | |||
border: 2px solid #d0d0d0; | |||
border-left-width: 6px; | |||
background: #f8f9fa; | |||
padding: 10px 14px; | |||
margin: 8px 0 16px 0; | |||
border-radius: 6px; | |||
font-size: 0.95em; | |||
line-height: 1.5; | |||
} | |||
.mw-maint-box b { font-size: 1.05em; } | |||
.mw-maint-note { | |||
margin-top: 6px; | |||
padding-top: 6px; | |||
border-top: 1px dashed #ccc; | |||
color: #555; | |||
} | |||
/* 类型配色 (左边条) */ | |||
.mw-maint-reg { border-left-color: #4a90d9; } /* 定期维护: 蓝 */ | |||
.mw-maint-care { border-left-color: #f0a030; } /* 谨慎: 橙 */ | |||
.mw-maint-admin { border-left-color: #d9534f; } /* 禁止: 红 */ | |||
.mw-maint-todo { border-left-color: #5cb85c; } /* 待补: 绿 */ | |||
.mw-maint-stale { border-left-color: #888; } /* 过时: 灰 */ | |||
.mw-maint-wip { border-left-color: #9460d0; } /* 施工: 紫 */ | |||
/* 默认隐藏, 仅已登录(有编辑权限, body.mw-editable)显示 */ | |||
.mw-maint-box { display: none; } | |||
body.mw-editable .mw-maint-box { display: block; } | |||
/* ===== 行内内容标记 模板:标记 (小卡片)===== */ | |||
.mw-flag { | |||
display: inline-block; | |||
font-size: 78%; | |||
line-height: 1.15; | |||
padding: 0 4px; | |||
margin: 0 2px; | |||
border: 1px solid; | |||
border-radius: 3px; | |||
white-space: nowrap; | |||
vertical-align: super; | |||
cursor: help; | |||
} | |||
.mw-flag-doubt { color: #8a5a00; background: #fff6e5; border-color: #e0b060; } | |||
.mw-flag-stale { color: #555555; background: #f2f2f2; border-color: #bbbbbb; } | |||
.mw-flag-orig { color: #5b3a8e; background: #f4eeff; border-color: #b9a3dd; } | |||