Give import items their own CSS class.

This commit is contained in:
Tor Hovland 2021-04-13 17:23:27 +02:00
parent 41f49aac4e
commit 1e2ab998c3
5 changed files with 11 additions and 6 deletions

View File

@ -296,7 +296,7 @@ fn item_module(w: &mut Buffer, cx: &Context<'_>, item: &clean::Item, items: &[cl
write!(
w,
"<tr class=\"{stab}{add}module-item\">\
"<tr class=\"{stab}{add}import-item\">\
<td><code>{vis}{imp}</code></td>\
<td class=\"docblock-short\">{stab_tags}</td>\
</tr>",

View File

@ -868,7 +868,8 @@ body.blur > :not(#help) {
0 -1px 0 black;
}
.module-item .stab {
.module-item .stab,
.import-item .stab {
border-radius: 3px;
display: inline-block;
font-size: 80%;
@ -879,7 +880,8 @@ body.blur > :not(#help) {
vertical-align: text-bottom;
}
.module-item.unstable {
.module-item.unstable,
.import-item.unstable {
opacity: 0.65;
}

View File

@ -252,7 +252,8 @@ details.rustdoc-toggle > summary::before {
color: #929292;
}
.module-item .stab {
.module-item .stab,
.import-item .stab {
color: #000;
}

View File

@ -217,7 +217,8 @@ details.rustdoc-toggle > summary::before {
box-shadow: 0 0 8px 4px #078dd8;
}
.module-item .stab {
.module-item .stab,
.import-item .stab {
color: #ddd;
}

View File

@ -215,7 +215,8 @@ details.rustdoc-toggle > summary::before {
box-shadow: 0 0 8px #078dd8;
}
.module-item .stab {
.module-item .stab,
.import-item .stab {
color: #000;
}