about summary refs log tree commit diff
path: root/src/librustdoc/html
diff options
context:
space:
mode:
authorMichael Howell <michael@notriddle.com>2022-09-28 17:38:25 -0700
committerMichael Howell <michael@notriddle.com>2022-09-28 21:11:40 -0700
commit0b9b4b70683db6ef707755f520f139eb7b92a944 (patch)
tree544dbd5c2d19cd6131cb635a23a4ac455be84cc5 /src/librustdoc/html
parentce7f0f1aa0f02c45cad0749e63f3086234b1f422 (diff)
downloadrust-0b9b4b70683db6ef707755f520f139eb7b92a944.tar.gz
rust-0b9b4b70683db6ef707755f520f139eb7b92a944.zip
rustdoc: add method spacing to trait methods
More cleanup for 8846c0853d8687fda0e5f23f6687b03b243980ee, this time in trait
layouts when things are collapsed.
Diffstat (limited to 'src/librustdoc/html')
-rw-r--r--src/librustdoc/html/render/print_item.rs2
-rw-r--r--src/librustdoc/html/static/css/rustdoc.css3
2 files changed, 3 insertions, 2 deletions
diff --git a/src/librustdoc/html/render/print_item.rs b/src/librustdoc/html/render/print_item.rs
index 3e324bbb069..9f6b6b52536 100644
--- a/src/librustdoc/html/render/print_item.rs
+++ b/src/librustdoc/html/render/print_item.rs
@@ -716,7 +716,7 @@ fn item_trait(w: &mut Buffer, cx: &mut Context<'_>, it: &clean::Item, t: &clean:
         document(&mut content, cx, m, Some(t), HeadingOffset::H5);
         let toggled = !content.is_empty();
         if toggled {
-            write!(w, "<details class=\"rustdoc-toggle\" open><summary>");
+            write!(w, "<details class=\"rustdoc-toggle method-toggle\" open><summary>");
         }
         write!(w, "<div id=\"{}\" class=\"method has-srclink\">", id);
         render_rightside(w, cx, m, t, RenderMode::Normal);
diff --git a/src/librustdoc/html/static/css/rustdoc.css b/src/librustdoc/html/static/css/rustdoc.css
index 0ea6d9c38b6..ebac83315bb 100644
--- a/src/librustdoc/html/static/css/rustdoc.css
+++ b/src/librustdoc/html/static/css/rustdoc.css
@@ -2011,7 +2011,8 @@ in storage.js plus the media query with (min-width: 701px)
 
 .method-toggle summary,
 .implementors-toggle summary,
-.impl {
+.impl,
+#implementors-list > .docblock {
 	margin-bottom: 0.75em;
 }