Rollup merge of #85280 - jsha:move-trait-toggles, r=GuillaumeGomez
Toggle-wrap items differently than top-doc. This makes sure things like trait methods get wrapped at the `<h3><code>` level rather than at the `.docblock` level. Also it ensures that only the actual top documentation gets the `.top-doc` class. Fixes #85167 Before:  https://doc.rust-lang.org/nightly/std/io/trait.Read.html#tymethod.read After: 
This commit is contained in:
commit
d151ed8699
3 changed files with 14 additions and 2 deletions
|
@ -509,7 +509,11 @@ fn document(w: &mut Buffer, cx: &Context<'_>, item: &clean::Item, parent: Option
|
|||
info!("Documenting {}", name);
|
||||
}
|
||||
document_item_info(w, cx, item, parent);
|
||||
document_full_collapsible(w, item, cx);
|
||||
if parent.is_none() {
|
||||
document_full_collapsible(w, item, cx);
|
||||
} else {
|
||||
document_full(w, item, cx);
|
||||
}
|
||||
}
|
||||
|
||||
/// Render md_text as markdown.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue