“MediaWiki:Mobile.css”的版本间的差异

来自侠行天下-维基百科
跳到导航 跳到搜索
(创建页面,内容为“→‎这里放置的CSS将影响使用移动版网站的用户 →‎info类模板 .infoBox { margin: 0 auto; } .infoBoxTitle { margin: 3px auto;…”
 
 
第1行: 第1行:
 
/* 这里放置的CSS将影响使用移动版网站的用户 */
 
/* 这里放置的CSS将影响使用移动版网站的用户 */
  
/* info类模板 */
+
.heimu, .heimu a, a .heimu, .heimu a.new {
.infoBox {
+
    background-color: #252525;
     margin: 0 auto;
+
    color: #252525;
}
+
    text-shadow: none;
.infoBoxTitle {
+
}
     margin: 3px auto;
+
.heimu:hover, .heimu:active {
     padding: 0;
+
    color: white;
     text-align: center;
+
}
     font-weight: 700;
+
.heimu:hover a, a:hover .heimu {
}
+
    color: lightblue;
.infoBoxIcon {
+
}
     display: table-cell;
+
.heimu:hover .new, .heimu .new:hover, .new:hover .heimu {
     padding: 2px 0 2px .5em;
+
    color: #BA0000;
     vertical-align: middle;
+
}
}
+
/* 修复单元格莫名空行 */
.infoBoxText {
+
td {
     display: table-cell;
+
    vertical-align: middle;
     padding: .25em .5em .25em 1.3em;
+
}
     width: 100%;
+
/* 修复子页面列表和common-box宽度不足 */
     vertical-align: middle;
+
.mw-prefixindex-list-table,
}
+
.common-box {
.infoBoxContent {
+
    width: 100%!important;
     border: 1px solid #ddd;
+
}
     border-left-width: 0;
+
/* 侧边栏和替换logo图片隐藏 */
     background: #fbfbfb;
+
#sidebar-character,
}
+
#wglogo {
.infoBoxBelow {
+
    display: none;
     margin: 0 auto;
+
}
     padding: 0;
+
/* 导航条 */
     text-align: center;
+
#breadcrumb {
}
+
    font: bold 18px Arial, Helvetica, sans-serif;
+
    color: black;
/*阅读更多:https://zh.moegirl.org/MediaWiki:Common.css
+
    border: solid 1px rgb(204, 204, 204);
info相关模板引自萌娘百科(https://zh.moegirl.org/),文字内容遵守【知识共享 署名-非商业性使用-相同方式共享 3.0】协议。 */
+
    width: 100%;
+
    overflow: hidden;
+
    margin: 0;
/* 黑幕模板配合CSS */
+
    padding: 0 0 .5em 0;
/* 把这几行单独拎出来写,否则会被Firefox合并到“.heimu a”这条规则,然后又被上面的“点过外链不变色”规则override */
+
}
span.heimu a.external,
+
#breadcrumb span {
span.heimu a.external:visited,
+
    list-style-type: none;
span.heimu a.extiw,
+
    float: left;
span.heimu a.extiw:visited {
+
    padding-left: 10px;
     color: #252525;
+
}
}
+
#breadcrumb span:after {
.heimu,
+
    content: "·"
.heimu a,
+
}
a .heimu,
+
#breadcrumb span:last-child:after {
.heimu a.new {
+
    content: "";
     background-color: #252525;
+
}
     color: #252525;
+
#breadcrumb a {
     text-shadow: none;
+
    text-align: center;
}
+
    vertical-align: middle;
body:not(.heimu_toggle_on) .heimu:hover,
+
    display: inline-block;
body:not(.heimu_toggle_on) .heimu:active,
+
    padding-right: 15px;
body:not(.heimu_toggle_on) .heimu.off {
+
    text-decoration: none;
     color: white;
+
    color: #454545!important;
}
+
}
body:not(.heimu_toggle_on) .heimu:hover a,
+
.home {
body:not(.heimu_toggle_on) a:hover .heimu,
+
    border: none;
body:not(.heimu_toggle_on) .heimu.off a,
+
    margin: 8px 0;
body:not(.heimu_toggle_on) a:hover .heimu.off {
+
}
     color: lightblue;
+
/* 注释文字 */
}
+
sup.mobileref {
body:not(.heimu_toggle_on) .heimu.off .new,
+
    display:none;
body:not(.heimu_toggle_on) .heimu.off .new:hover,
+
}
body:not(.heimu_toggle_on) .new:hover .heimu.off,
+
sup.mobileref:after {
body:not(.heimu_toggle_on) .heimu.off .new,
+
    content: " (" attr(title) ")";
body:not(.heimu_toggle_on) .heimu.off .new:hover,
+
    display: inline;
body:not(.heimu_toggle_on) .new:hover .heimu.off {
+
}
    color: #BA0000;
+
/* 首页适配 */
}
+
.page-Main_Page .gallery div,
+
.page-Main_Page .gallery div img,
/*阅读更多:https://zh.moegirl.org/MediaWiki:Common.css
+
.page-Main_Page .gallery p {
heimu相关css引自萌娘百科(https://zh.moegirl.org/),文字内容遵守【知识共享 署名-非商业性使用-相同方式共享 3.0】协议。*/
+
    position: initial !important;
 +
    display: inline;
 +
    margin-bottom: 7px;
 +
}
 +
.page-Main_Page .mainpage-title {
 +
    border-top: 1px solid rgb(204, 204, 204);
 +
    border-bottom: 1px solid rgb(204, 204, 204);
 +
    text-align: center;
 +
    font-size: larger;
 +
    font-family: Arial, Tahoma, Microsoft YaHei, \5fae\8f6f\96c5\9ed1, Hiragino Sans GB, Microsoft JhengHei, 微軟正黑體, sans-serif;
 +
    margin: 7px;
 +
}
 +
/* 页顶提示模板相关 */
 +
#commonBoxInfo {
 +
    color: #f00;
 +
    font-weight: bold;
 +
    text-align: center;
 +
}
 +
#commonBoxList > .commonBoxButton {
 +
    display: inline-block;
 +
    border-bottom: 3px solid #000;
 +
    width: 40px;
 +
    height: 40px;
 +
    background: #fff 50% 50% no-repeat;
 +
    background-size: contain;
 +
    cursor: pointer;
 +
    transition: opacity .5s;
 +
}
 +
#commonBoxList.open > .commonBoxButton {
 +
    opacity: .1;
 +
}
 +
#commonBoxList.open > .commonBoxButton.current {
 +
    opacity: 1;
 +
}
 +
/* infoBox */
 +
.infoBox {
 +
     margin: 0 auto;
 +
    clear: both;
 +
}
 +
.infoBoxTitle {
 +
     margin: 3px auto;
 +
     padding: 0;
 +
     text-align: center;
 +
     font-weight: bold;
 +
}
 +
.infoBoxIcon {
 +
     display: table-cell;
 +
     padding: 2px 0 2px 0.5em;
 +
     vertical-align: middle;
 +
}
 +
.infoBoxText {
 +
     display: table-cell;
 +
     padding: 0.25em 0.5em 0.25em 1.3em;
 +
     width: 100%;
 +
     vertical-align: middle;
 +
}
 +
.infoBoxContent {
 +
     border: 1px solid #ddd;
 +
     border-left-width: 0;
 +
     background: #fbfbfb;
 +
}
 +
.infoBoxBelow {
 +
     margin: 0 auto;
 +
     padding: 0;
 +
     text-align: center;
 +
}
 +
/* code 内边距修复 */
 +
code {
 +
    padding: 3px
 +
}
 +
/* Tabs */
 +
.tab .TabLabelText {
 +
    display: inline-block;
 +
    padding: 1px;
 +
    cursor: pointer;
 +
}
 +
.tab .TabLabel {
 +
    z-index: 2;
 +
    position: sticky;
 +
    top: 0;
 +
    -webkit-user-select: none;
 +
    -moz-user-select: none;
 +
    -ms-user-select: none;
 +
    -o-user-select: none;
 +
    user-select: none;
 +
}
 +
.tab .TabLabelText.selected {
 +
    border-top: 3px solid green;
 +
    padding: 1px;
 +
    background: white;
 +
    border-left: 1px solid #aaa;
 +
    border-right: 1px solid #aaa;
 +
}
 +
.tab .TabContent {
 +
    background: white;
 +
    padding: 20px 30px;
 +
    position: relative;
 +
    z-index: 1;
 +
     border: 1px solid #aaa;
 +
}
 +
.tab .TabContentText {
 +
    display: none;
 +
}
 +
.tab .TabContentText.selected {
 +
     display: block;
 +
}
 +
.Tabs {
 +
     position: relative;
 +
}
 +
.Tabs .Tab {
 +
     border-bottom: 1px solid #aaa;
 +
}
 +
.Tabs .Tab:first-child {
 +
    border-top: 1px solid #aaa;
 +
}
 +
.Tabs .Tab .TabLabelText {
 +
    padding: 7px;
 +
}
 +
.Tabs .Tab .TabContentText {
 +
     padding: 3px;
 +
}
 +
/* wikitable green */
 +
table.wikitable-green {
 +
    background: #c9f6e1
 +
}
 +
.wikitable-green th {
 +
    background: #13ec93
 +
}
 +
.wikitable-green td {
 +
    background: #f3f3f3
 +
}
 +
/* wikitable border */
 +
#content.content table.wikitable {
 +
    border: none;
 +
}
 +
/* 大家族模板 */
 +
.navbox th, .navbox-group {
 +
     background: #a5e4a5;
 +
}
 +
/* 来个高优先级的 */
 +
body .content .navbox {
 +
    display: table!important;
 +
}
 +
.navbox .content table {
 +
    width: 100% !important;
 +
}
 +
.navbox {
 +
    border: 1px solid #aaa;
 +
    clear: both;
 +
    padding: 1px;
 +
    text-align: center;
 +
    width: 100%;
 +
}
 +
.navbox-group {
 +
    white-space: nowrap;
 +
}
 +
.navbox table {
 +
    width: 100% !important;
 +
    margin: 0 !important;
 +
}
 +
.navbox-subgroup .navbox-group {
 +
    background: #e6f6e6;
 +
}
 +
.navbox-title > div:first-of-type {
 +
    display: none;
 +
}
 +
/* Fix by case : Rev 1327309 ([[Special:Permalink/1327309]])
 +
    Address alignment issue of nested tabs in Navbox */
 +
.navbox .TabLabel {
 +
    text-align: left;
 +
}
 +
@media screen and (max-width: 640px) {
 +
    .navbox-group {
 +
        display: block;
 +
    }
 +
    .navbox-group + * {
 +
        display: block;
 +
        width: 100%;
 +
        border-left: 1em solid #a5e4a5 !important;
 +
        padding-left: 3px !important;
 +
        padding-top: 3px !important;
 +
        box-sizing: border-box;
 +
    }
 +
    .navbox-subgroup .navbox-group + * {
 +
        border-left: 1em solid #e6f6e6 !important;
 +
    }
 +
}
 +
/* 修复用户页欢迎辞覆盖编辑框的bug */
 +
.overlay.visible {
 +
    z-index: 999;
 +
}
 +
/* Fix by case: Tracklist doesn't display on mobile devices due to inappropriate margin configuration  */
 +
.tracklist {
 +
    margin:0 !important;
 +
}
 +
/* 链接提示 */
 +
.linkConfirmprompt {
 +
    border: 1px solid black;
 +
    display: none;
 +
    padding: 3px 7px;
 +
    position: absolute;
 +
    text-align: center;
 +
    width: 300px;
 +
    z-index: 99999;
 +
    background: rgb(255, 255, 255);
 +
}
 +
.linkConfirmpromptTextnode {
 +
    max-height: 2.5em;
 +
    text-align: left;
 +
    word-break: break-all;
 +
}
 +
.linkConfirmprompt a {
 +
    margin: 0 1.5em;
 +
    cursor: pointer;
 +
}
  
/* Default style for navigation boxes */
+
/*阅读更多:https://zh.moegirl.org/MediaWiki:Mobile.css
.navbox {                    /* Navbox container style */
+
本文引自萌娘百科(https://zh.moegirl.org/),文字内容遵守【知识共享 署名-非商业性使用-相同方式共享 3.0】协议。*/
width: 100% !important;
 
max-width: 950px;
 
margin: auto;
 
clear: both;
 
font-size: 88%;
 
text-align: center;
 
padding: 1px;
 
}
 
.navbox + .navbox {
 
margin-top: -1px;        /* Single pixel border between adjacent navboxes */
 
}
 
.navbox-group,
 
.navbox-title,
 
.navbox-abovebelow {
 
padding: 0.25em 1em;      /* Title, group and above/below styles */
 
line-height: 1.5em;
 
text-align: center;
 
}
 
th.navbox-group {            /* Group style */
 
white-space: nowrap;
 
/* @noflip */
 
text-align: right;
 
}
 
.navbox,
 
.navbox-subgroup {
 
background: #fdfdfd;      /* Background color */
 
}
 
.navbox-list {
 
line-height: 1.5em;
 
border-color: #fdfdfd;    /* Must match background color */
 
}
 
/* cell spacing for navbox cells */
 
tr + tr > .navbox-abovebelow,
 
tr + tr > .navbox-group,
 
tr + tr > .navbox-image,
 
tr + tr > .navbox-list {    /* Borders above 2nd, 3rd, etc. rows */
 
border-top: 2px solid #fdfdfd; /* Must match background color */
 
}
 
.navbox th,
 
.navbox-title {
 
background: #ccccff;      /* Level 1 color */
 
}
 
.navbox-abovebelow,
 
th.navbox-group,
 
.navbox-subgroup .navbox-title {
 
background: #ddddff;      /* Level 2 color */
 
}
 
.navbox-subgroup .navbox-group,
 
.navbox-subgroup .navbox-abovebelow {
 
background: #e6e6ff;      /* Level 3 color */
 
}
 
.navbox-even {
 
background: #f7f7f7;      /* Even row striping */
 
}
 
.navbox-odd {
 
background: transparent;  /* Odd row striping */
 
}
 
.navbox .hlist td dl,
 
.navbox .hlist td ol,
 
.navbox .hlist td ul,
 
.navbox td.hlist dl,
 
.navbox td.hlist ol,
 
.navbox td.hlist ul {
 
padding: 0.125em 0;      /* Adjust hlist padding in navboxes */
 
}
 
 
 
 
/* Default styling for Navbar template */
 
.navbar {
 
display: inline;
 
font-size: 88%;
 
font-weight: normal;
 
}
 
.navbar ul {
 
display: inline;
 
white-space: nowrap;
 
}
 
.mw-body-content .navbar ul {
 
line-height: inherit;
 
}
 
.navbar li {
 
word-spacing: -0.125em;
 
}
 
.navbar.mini li abbr[title] {
 
font-variant: small-caps;
 
border-bottom: none;
 
text-decoration: none;
 
cursor: inherit;
 
}
 
/* Navbar styling when nested in infobox and navbox */
 
.infobox .navbar {
 
font-size: 100%;
 
}
 
.navbox .navbar {
 
display: block;
 
font-size: 100%;
 
}
 
.navbox-title .navbar {
 
/* @noflip */
 
float: left;
 
/* @noflip */
 
text-align: left;
 
/* @noflip */
 
margin-right: 0.5em;
 
}
 
 
.navbox-title,
 
.navbox-abovebelow,
 
table.navbox th {
 
  text-align: center;      /* Title and above/below styles */
 
  padding-left: 1em;
 
  padding-right: 1em;
 
}
 
.navbox-group {            /* Group style */
 
  white-space: nowrap;
 
  text-align: right;
 
  font-weight: bold;
 
  padding-left: 1em;
 
  padding-right: 1em;
 
}
 
.navbox, .navbox-subgroup {
 
  background: #fdfdfd;    /* Background color */
 
}
 
.navbox-list {
 
  border-color: #fdfdfd;  /* Must match background color */
 
  text-align: left;
 
}
 
.navbox-title,
 
table.navbox th {
 
  background: #cedaff;    /* Level 1 color */
 
}
 
.navbox-abovebelow,
 
.navbox-group,
 
.navbox-subgroup .navbox-title {
 
  background: #dde6ff;    /* Level 2 color */
 
}
 
.navbox-subgroup .navbox-group, .navbox-subgroup .navbox-abovebelow {
 
  background: #dde6ff;    /* Level 3 color */
 
}
 
.navbox-even {
 
  background: #f7f7f7;    /* Even row striping */
 
}
 
.navbox-odd {
 
  background: transparent; /* Odd row striping */
 
}
 

2018年5月26日 (六) 15:13的最新版本

/* 这里放置的CSS将影响使用移动版网站的用户 */

.heimu, .heimu a, a .heimu, .heimu a.new {
    background-color: #252525;
    color: #252525;
    text-shadow: none;
}
.heimu:hover, .heimu:active {
    color: white;
}
.heimu:hover a, a:hover .heimu {
    color: lightblue;
}
.heimu:hover .new, .heimu .new:hover, .new:hover .heimu {
    color: #BA0000;
}
/* 修复单元格莫名空行 */
td {
    vertical-align: middle;
}
/* 修复子页面列表和common-box宽度不足 */
.mw-prefixindex-list-table,
.common-box {
    width: 100%!important;
}
/* 侧边栏和替换logo图片隐藏 */
#sidebar-character,
#wglogo {
    display: none;
}
/* 导航条 */
#breadcrumb {
    font: bold 18px Arial, Helvetica, sans-serif;
    color: black;
    border: solid 1px rgb(204, 204, 204);
    width: 100%;
    overflow: hidden;
    margin: 0;
    padding: 0 0 .5em 0;
}
#breadcrumb span {
    list-style-type: none;
    float: left;
    padding-left: 10px;
}
#breadcrumb span:after {
    content: "·"
}
#breadcrumb span:last-child:after {
    content: "";
}
#breadcrumb a {
    text-align: center;
    vertical-align: middle;
    display: inline-block;
    padding-right: 15px;
    text-decoration: none;
    color: #454545!important;
}
.home {
    border: none;
    margin: 8px 0;
}
/* 注释文字 */
sup.mobileref {
    display:none;
}
sup.mobileref:after {
    content: " (" attr(title) ")";
    display: inline;
}
/* 首页适配 */
.page-Main_Page .gallery div,
.page-Main_Page .gallery div img,
.page-Main_Page .gallery p {
    position: initial !important;
    display: inline;
    margin-bottom: 7px;
}
.page-Main_Page .mainpage-title {
    border-top: 1px solid rgb(204, 204, 204);
    border-bottom: 1px solid rgb(204, 204, 204);
    text-align: center;
    font-size: larger;
    font-family: Arial, Tahoma, Microsoft YaHei, \5fae\8f6f\96c5\9ed1, Hiragino Sans GB, Microsoft JhengHei, 微軟正黑體, sans-serif;
    margin: 7px;
}
/* 页顶提示模板相关 */
#commonBoxInfo {
    color: #f00;
    font-weight: bold;
    text-align: center;
}
#commonBoxList > .commonBoxButton {
    display: inline-block;
    border-bottom: 3px solid #000;
    width: 40px;
    height: 40px;
    background: #fff 50% 50% no-repeat;
    background-size: contain;
    cursor: pointer;
    transition: opacity .5s;
}
#commonBoxList.open > .commonBoxButton {
    opacity: .1;
}
#commonBoxList.open > .commonBoxButton.current {
    opacity: 1;
}
/* infoBox */
.infoBox {
    margin: 0 auto;
    clear: both;
}
.infoBoxTitle {
    margin: 3px auto;
    padding: 0;
    text-align: center;
    font-weight: bold;
}
.infoBoxIcon {
    display: table-cell;
    padding: 2px 0 2px 0.5em;
    vertical-align: middle;
}
.infoBoxText {
    display: table-cell;
    padding: 0.25em 0.5em 0.25em 1.3em;
    width: 100%;
    vertical-align: middle;
}
.infoBoxContent {
    border: 1px solid #ddd;
    border-left-width: 0;
    background: #fbfbfb;
}
.infoBoxBelow {
    margin: 0 auto;
    padding: 0;
    text-align: center;
}
/* code 内边距修复 */
code {
    padding: 3px
}
/* Tabs */
.tab .TabLabelText {
    display: inline-block;
    padding: 1px;
    cursor: pointer;
}
.tab .TabLabel {
    z-index: 2;
    position: sticky;
    top: 0;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    -o-user-select: none;
    user-select: none;
}
.tab .TabLabelText.selected {
    border-top: 3px solid green;
    padding: 1px;
    background: white;
    border-left: 1px solid #aaa;
    border-right: 1px solid #aaa;
}
.tab .TabContent {
    background: white;
    padding: 20px 30px;
    position: relative;
    z-index: 1;
    border: 1px solid #aaa;
}
.tab .TabContentText {
    display: none;
}
.tab .TabContentText.selected {
    display: block;
}
.Tabs {
    position: relative;
}
.Tabs .Tab {
    border-bottom: 1px solid #aaa;
}
.Tabs .Tab:first-child {
    border-top: 1px solid #aaa;
}
.Tabs .Tab .TabLabelText {
    padding: 7px;
}
.Tabs .Tab .TabContentText {
    padding: 3px;
}
/* wikitable green */
table.wikitable-green {
    background: #c9f6e1
}
.wikitable-green th {
    background: #13ec93
}
.wikitable-green td {
    background: #f3f3f3
}
/* wikitable border */
#content.content table.wikitable {
    border: none;
}
/* 大家族模板 */
.navbox th, .navbox-group {
    background: #a5e4a5;
}
/* 来个高优先级的 */
body .content .navbox {
    display: table!important;
}
.navbox .content table {
    width: 100% !important;
}
.navbox {
    border: 1px solid #aaa;
    clear: both;
    padding: 1px;
    text-align: center;
    width: 100%;
}
.navbox-group {
    white-space: nowrap;
}
.navbox table {
    width: 100% !important;
    margin: 0 !important;
}
.navbox-subgroup .navbox-group {
    background: #e6f6e6;
}
.navbox-title > div:first-of-type {
    display: none;
}
/* Fix by case : Rev 1327309 ([[Special:Permalink/1327309]])
    Address alignment issue of nested tabs in Navbox */
.navbox .TabLabel {
    text-align: left;
}
@media screen and (max-width: 640px) {
    .navbox-group {
        display: block;
    }
    .navbox-group + * {
        display: block;
        width: 100%;
        border-left: 1em solid #a5e4a5 !important;
        padding-left: 3px !important;
        padding-top: 3px !important;
        box-sizing: border-box;
    }
    .navbox-subgroup .navbox-group + * {
        border-left: 1em solid #e6f6e6 !important;
    }
}
/* 修复用户页欢迎辞覆盖编辑框的bug */
.overlay.visible {
    z-index: 999;
}
/* Fix by case: Tracklist doesn't display on mobile devices due to inappropriate margin configuration  */
.tracklist {
    margin:0 !important;
}
/* 链接提示 */
.linkConfirmprompt {
    border: 1px solid black;
    display: none;
    padding: 3px 7px;
    position: absolute;
    text-align: center;
    width: 300px;
    z-index: 99999;
    background: rgb(255, 255, 255);
}
.linkConfirmpromptTextnode {
    max-height: 2.5em;
    text-align: left;
    word-break: break-all;
}
.linkConfirmprompt a {
    margin: 0 1.5em;
    cursor: pointer;
}

/*阅读更多:https://zh.moegirl.org/MediaWiki:Mobile.css
本文引自萌娘百科(https://zh.moegirl.org/),文字内容遵守【知识共享 署名-非商业性使用-相同方式共享 3.0】协议。*/