Skip to content

Commit 3a3bf5f

Browse files
GuillaumeGomezMark-Simulacrum
authored andcommitted
Remove implementors setting
1 parent 42c8fbc commit 3a3bf5f

File tree

3 files changed

+1
-16
lines changed

3 files changed

+1
-16
lines changed

src/librustdoc/html/render/mod.rs

-1
Original file line numberDiff line numberDiff line change
@@ -451,7 +451,6 @@ fn settings(root_path: &str, suffix: &str, themes: &[StylePath]) -> Result<Strin
451451
("auto-hide-method-docs", "Auto-hide item methods' documentation", false).into(),
452452
("auto-hide-trait-implementations", "Auto-hide trait implementation documentation", false)
453453
.into(),
454-
("auto-collapse-implementors", "Auto-hide implementors of a trait", true).into(),
455454
("go-to-only-result", "Directly go to item in search if there is only one result", false)
456455
.into(),
457456
("line-numbers", "Show line numbers on code examples", false).into(),

src/librustdoc/html/static/js/main.js

-5
Original file line numberDiff line numberDiff line change
@@ -789,7 +789,6 @@ function hideThemeButtonState() {
789789
}
790790

791791
var hideMethodDocs = getSettingValue("auto-hide-method-docs") === "true";
792-
var hideImplementors = getSettingValue("auto-collapse-implementors") !== "false";
793792
var hideImplementations = getSettingValue("auto-hide-trait-implementations") === "true";
794793
var hideLargeItemContents = getSettingValue("auto-hide-large-items") !== "false";
795794

@@ -807,10 +806,6 @@ function hideThemeButtonState() {
807806
setImplementorsTogglesOpen("blanket-implementations-list", false);
808807
}
809808

810-
if (!hideImplementors) {
811-
setImplementorsTogglesOpen("implementors-list", true);
812-
}
813-
814809
onEachLazy(document.getElementsByClassName("rustdoc-toggle"), function (e) {
815810
if (!hideLargeItemContents && hasClass(e, "type-contents-toggle")) {
816811
e.open = true;
+1-10
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,4 @@
1-
// This test ensures two things:
2-
//
3-
// 1. The implementors toggle are not open by default.
4-
// 2. The "auto-collapse-implementors" setting is working as expected.
1+
// This test ensures that the implementors toggle are not open by default.
52
goto: file://|DOC_PATH|/implementors/trait.Whatever.html
63

7-
// First, checking that they are not open by default.
84
assert-attribute-false: ("#implementors-list > details", {"open": ""}, ALL)
9-
10-
// Second, checking "auto-collapse-implementors" setting.
11-
local-storage: {"rustdoc-auto-collapse-implementors": false}
12-
reload:
13-
assert-attribute: ("#implementors-list > details", {"open": ""}, ALL)

0 commit comments

Comments
 (0)