mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-30 17:34:54 +00:00
Add trait methods as well
This commit is contained in:
parent
85dcf2ecb6
commit
d86621f69e
@ -2400,8 +2400,9 @@ fn item_trait(w: &mut fmt::Formatter, cx: &Context, it: &clean::Item,
|
||||
let item_type = m.type_();
|
||||
let id = derive_id(format!("{}.{}", item_type, name));
|
||||
let ns_id = derive_id(format!("{}.{}", name, item_type.name_space()));
|
||||
write!(w, "<h3 id='{id}' class='method'>\
|
||||
write!(w, "{extra}<h3 id='{id}' class='method'>\
|
||||
<span id='{ns_id}' class='invisible'><code>",
|
||||
extra = render_spotlight_traits(m)?,
|
||||
id = id,
|
||||
ns_id = ns_id)?;
|
||||
render_assoc_item(w, m, AssocItemLink::Anchor(Some(&id)), ItemType::Impl)?;
|
||||
|
@ -438,10 +438,11 @@ h4 > code, h3 > code, .invisible > code {
|
||||
font-size: 0.8em;
|
||||
}
|
||||
|
||||
.content .methods > div { margin-left: 40px; }
|
||||
.content .methods > div:not(.important-traits) { margin-left: 40px; }
|
||||
|
||||
.content .impl-items .docblock, .content .impl-items .stability {
|
||||
margin-left: 40px;
|
||||
margin-bottom: .6em;
|
||||
}
|
||||
.content .impl-items .method, .content .impl-items > .type, .impl-items > .associatedconstant {
|
||||
margin-left: 20px;
|
||||
@ -1045,4 +1046,10 @@ h3.important {
|
||||
position: absolute;
|
||||
left: -24px;
|
||||
margin-top: 16px;
|
||||
}
|
||||
|
||||
.content > .methods > div.important-traits {
|
||||
position: absolute;
|
||||
left: -42px;
|
||||
margin-top: 2px;
|
||||
}
|
Loading…
Reference in New Issue
Block a user