about summary refs log tree commit diff
path: root/src/librustdoc/html/render
diff options
context:
space:
mode:
authorManish Goregaokar <manishsmail@gmail.com>2021-04-12 12:27:37 -0700
committerManish Goregaokar <manishsmail@gmail.com>2021-04-12 12:27:37 -0700
commit97cd30d337e4e460efc77faf03ba68ce192b5648 (patch)
tree172facfe607a9fe1792aa26067897b3257ea9d2c /src/librustdoc/html/render
parentb40bd5a9aaf8b20bdb394bf78a06490f60f13b57 (diff)
downloadrust-97cd30d337e4e460efc77faf03ba68ce192b5648.tar.gz
rust-97cd30d337e4e460efc77faf03ba68ce192b5648.zip
Wrap toggle_open()
Diffstat (limited to 'src/librustdoc/html/render')
-rw-r--r--src/librustdoc/html/render/print_item.rs5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/librustdoc/html/render/print_item.rs b/src/librustdoc/html/render/print_item.rs
index f6cce28ea2b..ff3518ad7a1 100644
--- a/src/librustdoc/html/render/print_item.rs
+++ b/src/librustdoc/html/render/print_item.rs
@@ -139,7 +139,10 @@ fn should_hide_fields(n_fields: usize) -> bool {
 fn toggle_open(w: &mut Buffer, text: &str) {
     write!(
         w,
-        "<details class=\"rustdoc-toggle type-contents-toggle\"><summary class=\"hideme\"><span>Show {}</span></summary>",
+        "<details class=\"rustdoc-toggle type-contents-toggle\">\
+            <summary class=\"hideme\">\
+                <span>Show {}</span>\
+            </summary>",
         text
     );
 }