Improve accessibility of rustdoc pages
This commit is contained in:
parent
645dd013ac
commit
bb9ec82563
@ -2548,10 +2548,11 @@ fn render_impl(w: &mut fmt::Formatter, cx: &Context, i: &Impl, link: AssocItemLi
|
||||
if !is_static || render_static {
|
||||
let id = derive_id(format!("{}.{}", shortty, name));
|
||||
write!(w, "<h4 id='{}' class='{}'>", id, shortty)?;
|
||||
render_stability_since_raw(w, item.stable_since(), outer_version)?;
|
||||
write!(w, "<code>")?;
|
||||
render_assoc_item(w, item, link.anchor(&id))?;
|
||||
write!(w, "</code></h4>\n")?;
|
||||
write!(w, "</code>")?;
|
||||
render_stability_since_raw(w, item.stable_since(), outer_version)?;
|
||||
write!(w, "</h4>\n")?;
|
||||
}
|
||||
}
|
||||
clean::TypedefItem(ref tydef, _) => {
|
||||
|
@ -981,7 +981,7 @@
|
||||
$(".method").each(function() {
|
||||
if ($(this).next().is(".docblock") ||
|
||||
($(this).next().is(".stability") && $(this).next().next().is(".docblock"))) {
|
||||
$(this).children().first().after(toggle.clone());
|
||||
$(this).children().last().after(toggle.clone());
|
||||
}
|
||||
});
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user