about summary refs log tree commit diff
diff options
context:
space:
mode:
authorGuillaume Gomez <guillaume.gomez@huawei.com>2021-09-01 20:34:51 +0200
committerGuillaume Gomez <guillaume.gomez@huawei.com>2021-09-01 20:34:51 +0200
commit92dae39b64224ca9f706f5de8df09a72559947c5 (patch)
treeed0c2d9cb4ef4f9f5a42dbc4ff61912040450180
parentfba4149bf1d8959299379a5dc351a61bdb5b8c92 (diff)
downloadrust-92dae39b64224ca9f706f5de8df09a72559947c5.tar.gz
rust-92dae39b64224ca9f706f5de8df09a72559947c5.zip
Remove implementors setting
-rw-r--r--src/librustdoc/html/render/mod.rs1
-rw-r--r--src/librustdoc/html/static/js/main.js5
-rw-r--r--src/test/rustdoc-gui/toggle-implementors.goml11
3 files changed, 1 insertions, 16 deletions
diff --git a/src/librustdoc/html/render/mod.rs b/src/librustdoc/html/render/mod.rs
index a0a67610481..c17ddcc1f1b 100644
--- a/src/librustdoc/html/render/mod.rs
+++ b/src/librustdoc/html/render/mod.rs
@@ -453,7 +453,6 @@ fn settings(root_path: &str, suffix: &str, themes: &[StylePath]) -> Result<Strin
         ("auto-hide-method-docs", "Auto-hide item methods' documentation", false).into(),
         ("auto-hide-trait-implementations", "Auto-hide trait implementation documentation", false)
             .into(),
-        ("auto-collapse-implementors", "Auto-hide implementors of a trait", true).into(),
         ("go-to-only-result", "Directly go to item in search if there is only one result", false)
             .into(),
         ("line-numbers", "Show line numbers on code examples", false).into(),
diff --git a/src/librustdoc/html/static/js/main.js b/src/librustdoc/html/static/js/main.js
index 0a6fca7da20..1eebd392564 100644
--- a/src/librustdoc/html/static/js/main.js
+++ b/src/librustdoc/html/static/js/main.js
@@ -789,7 +789,6 @@ function hideThemeButtonState() {
         }
 
         var hideMethodDocs = getSettingValue("auto-hide-method-docs") === "true";
-        var hideImplementors = getSettingValue("auto-collapse-implementors") !== "false";
         var hideImplementations = getSettingValue("auto-hide-trait-implementations") === "true";
         var hideLargeItemContents = getSettingValue("auto-hide-large-items") !== "false";
 
@@ -807,10 +806,6 @@ function hideThemeButtonState() {
             setImplementorsTogglesOpen("blanket-implementations-list", false);
         }
 
-        if (!hideImplementors) {
-            setImplementorsTogglesOpen("implementors-list", true);
-        }
-
         onEachLazy(document.getElementsByClassName("rustdoc-toggle"), function (e) {
             if (!hideLargeItemContents && hasClass(e, "type-contents-toggle")) {
                 e.open = true;
diff --git a/src/test/rustdoc-gui/toggle-implementors.goml b/src/test/rustdoc-gui/toggle-implementors.goml
index 4b2a266c712..15521ff0f49 100644
--- a/src/test/rustdoc-gui/toggle-implementors.goml
+++ b/src/test/rustdoc-gui/toggle-implementors.goml
@@ -1,13 +1,4 @@
-// This test ensures two things:
-//
-// 1. The implementors toggle are not open by default.
-// 2. The "auto-collapse-implementors" setting is working as expected.
+// This test ensures that the implementors toggle are not open by default.
 goto: file://|DOC_PATH|/implementors/trait.Whatever.html
 
-// First, checking that they are not open by default.
 assert-attribute-false: ("#implementors-list > details", {"open": ""}, ALL)
-
-// Second, checking "auto-collapse-implementors" setting.
-local-storage: {"rustdoc-auto-collapse-implementors": false}
-reload:
-assert-attribute: ("#implementors-list > details", {"open": ""}, ALL)