LLWiki正在建设中,欢迎加入我们!
“MediaWiki:Gadget-stickyHeading.css”的版本间差异
跳转到导航
跳转到搜索
小 |
小 |
||
第1行: | 第1行: | ||
.stickyHeading .section-container { |
.stickyHeading .section-container { |
||
position:relative; |
position: relative; |
||
} |
} |
||
.stickyHeading .section-container h2 { |
.stickyHeading .section-container h2 { /* 防止误伤目录中的h2 */ |
||
position:sticky; |
position: sticky; |
||
top:0; |
top: 0; |
||
z-index: |
z-index: 50; |
||
} |
} |
||
.skin-vector .stickyHeading .section-container h2 { |
.skin-vector .stickyHeading .section-container h2 { |
||
background-color:rgb(247,251,255); |
background-color: rgb(247,251,255); |
||
} |
} |
||
.skin-minerva .stickyHeading .section-container h2 { |
.skin-minerva .stickyHeading .section-container h2 { |
||
background-color:#fff; |
background-color: #fff; |
||
} |
|||
⚫ | |||
⚫ | |||
⚫ | |||
} |
} |
||
⚫ | |||
#Wikiplus-Quickedit-Preview-Output .stickyHeading .section-container h2 { |
#Wikiplus-Quickedit-Preview-Output .stickyHeading .section-container h2 { |
||
⚫ | |||
background-color:transparent; |
|||
⚫ | |||
} |
} |
||
/* 正常情况下 .infoboxtemplate和#toc都开始于h2的上方,并不需要以下CSS */ |
|||
.stickyHeading .infoboxtemplate, .stickyHeading |
.stickyHeading .infoboxtemplate, .stickyHeading #toc { |
||
position:relative; |
position: relative; |
||
z-index:1000000; |
|||
z-index: 51; /* 防止错误压盖右侧float元素 */ |
|||
} |
} |
||
.collapseHeading .sec-hide { |
.collapseHeading .sec-hide { |
||
display:none !important; |
display: none !important; |
||
} |
} |
||
.collapseHeading .section-container h2 { |
.collapseHeading .section-container h2 { |
||
cursor:pointer; |
cursor: pointer; |
||
} |
} |
||
.collapseHeading .mw-ui-icon-before.mw-ui-icon::before { |
.collapseHeading .mw-ui-icon-before.mw-ui-icon::before { |
||
第35行: | 第34行: | ||
background-size: 66.67% auto; |
background-size: 66.67% auto; |
||
background-position: center; |
background-position: center; |
||
background-repeat:no-repeat; |
background-repeat: no-repeat; |
||
float: left; |
float: left; |
||
min-height: 1.5em; |
min-height: 1.5em; |
||
第42行: | 第41行: | ||
} |
} |
||
.collapseHeading .mw-ui-icon { |
.collapseHeading .mw-ui-icon { |
||
line-height:1.5; |
line-height: 1.5; |
||
margin-left:-0.8em; |
margin-left: -0.8em; |
||
} |
} |
||
/* [[category:CSS小工具]] [[category:桌面版小工具]] [[category:手机版小工具]] [[category:讨论工具]] [[category:默认开启的小工具]] */ |
/* [[category:CSS小工具]] [[category:桌面版小工具]] [[category:手机版小工具]] [[category:讨论工具]] [[category:默认开启的小工具]] */ |
2021年1月21日 (四) 06:24的最新版本
.stickyHeading .section-container { position: relative; } .stickyHeading .section-container h2 { /* 防止误伤目录中的h2 */ position: sticky; top: 0; z-index: 50; } .skin-vector .stickyHeading .section-container h2 { background-color: rgb(247,251,255); } .skin-minerva .stickyHeading .section-container h2 { background-color: #fff; } .stickyHeading .section-container .documentation h2, #Wikiplus-Quickedit-Preview-Output .stickyHeading .section-container h2 { position: static; background-color: transparent; } /* 正常情况下 .infoboxtemplate和#toc都开始于h2的上方,并不需要以下CSS */ .stickyHeading .infoboxtemplate, .stickyHeading #toc { position: relative; z-index: 51; /* 防止错误压盖右侧float元素 */ } .collapseHeading .sec-hide { display: none !important; } .collapseHeading .section-container h2 { cursor: pointer; } .collapseHeading .mw-ui-icon-before.mw-ui-icon::before { content: ""; background-size: 66.67% auto; background-position: center; background-repeat: no-repeat; float: left; min-height: 1.5em; width: 1.5em; margin-right: 1em; } .collapseHeading .mw-ui-icon { line-height: 1.5; margin-left: -0.8em; } /* [[category:CSS小工具]] [[category:桌面版小工具]] [[category:手机版小工具]] [[category:讨论工具]] [[category:默认开启的小工具]] */ /* {{DEFAULTSORT:stickyHeading.css}} */