-
Notifications
You must be signed in to change notification settings - Fork 12.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
rustdoc: remove docblock
class from item-decl
#102027
rustdoc: remove docblock
class from item-decl
#102027
Conversation
This class was originally added in 73b97c7 to support hiding and showing the item, because `main.js` went through all `docblock` elements in the DOM and added toggles to them. https://github.com/rust-lang/rust/blob/73b97c7e7c9cfac4dfa4804654b1db6ab687b589/src/librustdoc/html/static/main.js#L1856-L1867 The `item-decl` is no longer auto-hidden since c96f86d removed it. `item-decl` used to be called `type-decl`: that name was changed in 8b7a2dd. The `docblock` class is no longer used for implementing toggles, since rustdoc switched to using `<details>` elements.
Some changes occurred in HTML/CSS/JS. cc @GuillaumeGomez, @Folyd, @jsha |
r? @CraftSpider (rust-highfive has picked a reviewer for you, use r? to override) |
This comment has been minimized.
This comment has been minimized.
0bd23da
to
8e6cf7d
Compare
@@ -1,4 +1,4 @@ | |||
<div class="docblock item-decl"><pre class="rust struct"><code>pub struct Struct<'a, B: ?<a class="trait" href="{{channel}}/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a> + 'a> <span class="where fmt-newline">where<br />    B: <a class="trait" href="trait.ToOwned.html" title="trait foo::ToOwned">ToOwned</a><dyn <a class="trait" href="{{channel}}/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>>, </span>{ | |||
<div class="item-decl"><pre class="rust struct"><code>pub struct Struct<'a, B: ?<a class="trait" href="{{channel}}/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a> + 'a><span class="where fmt-newline">where<br />    B: <a class="trait" href="trait.ToOwned.html" title="trait foo::ToOwned">ToOwned</a><dyn <a class="trait" href="{{channel}}/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>>,</span>{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There seem to have more than a simple class removal in all these files. Any idea why? I can't figure it out simply from the code changes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh I see. Then all good!
Thanks! @bors r+ rollup |
…decl, r=GuillaumeGomez rustdoc: remove `docblock` class from `item-decl` This class was originally added in 73b97c7 to support hiding and showing the item, because `main.js` went through all `docblock` elements in the DOM and added toggles to them. https://github.com/rust-lang/rust/blob/73b97c7e7c9cfac4dfa4804654b1db6ab687b589/src/librustdoc/html/static/main.js#L1856-L1867 The `item-decl` is no longer auto-hidden since c96f86d removed it. `item-decl` used to be called `type-decl`: that name was changed in 8b7a2dd. The `docblock` class is no longer used for implementing toggles, since rustdoc switched to using `<details>` elements. Preview: https://notriddle.com/notriddle-rustdoc-test/docblock-item-decl/rustdoc/clean/types/enum.Type.html
…decl, r=GuillaumeGomez rustdoc: remove `docblock` class from `item-decl` This class was originally added in 73b97c7 to support hiding and showing the item, because `main.js` went through all `docblock` elements in the DOM and added toggles to them. https://github.com/rust-lang/rust/blob/73b97c7e7c9cfac4dfa4804654b1db6ab687b589/src/librustdoc/html/static/main.js#L1856-L1867 The `item-decl` is no longer auto-hidden since c96f86d removed it. `item-decl` used to be called `type-decl`: that name was changed in 8b7a2dd. The `docblock` class is no longer used for implementing toggles, since rustdoc switched to using `<details>` elements. Preview: https://notriddle.com/notriddle-rustdoc-test/docblock-item-decl/rustdoc/clean/types/enum.Type.html
…decl, r=GuillaumeGomez rustdoc: remove `docblock` class from `item-decl` This class was originally added in 73b97c7 to support hiding and showing the item, because `main.js` went through all `docblock` elements in the DOM and added toggles to them. https://github.com/rust-lang/rust/blob/73b97c7e7c9cfac4dfa4804654b1db6ab687b589/src/librustdoc/html/static/main.js#L1856-L1867 The `item-decl` is no longer auto-hidden since c96f86d removed it. `item-decl` used to be called `type-decl`: that name was changed in 8b7a2dd. The `docblock` class is no longer used for implementing toggles, since rustdoc switched to using `<details>` elements. Preview: https://notriddle.com/notriddle-rustdoc-test/docblock-item-decl/rustdoc/clean/types/enum.Type.html
Rollup of 12 pull requests Successful merges: - rust-lang#100250 (Manually cleanup token stream when macro expansion aborts.) - rust-lang#101014 (Fix -Zmeta-stats ICE by giving `FileEncoder` file read permissions) - rust-lang#101958 (Improve error for when query is unsupported by crate) - rust-lang#101976 (MirPhase: clarify that linting is not a semantic change) - rust-lang#102001 (Use LLVM C-API to build atomic cmpxchg and fence) - rust-lang#102008 (Add GUI test for notable traits element position) - rust-lang#102013 (Simplify rpitit handling on lower_fn_decl) - rust-lang#102021 (some post-valtree cleanup) - rust-lang#102027 (rustdoc: remove `docblock` class from `item-decl`) - rust-lang#102034 (rustdoc: remove no-op CSS `h1-6 { border-bottom-color }`) - rust-lang#102038 (Make the `normalize-overflow` rustdoc test actually do something) - rust-lang#102053 (:arrow_up: rust-analyzer) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
This class was originally added in 73b97c7 to support hiding and showing the item, because
main.js
went through alldocblock
elements in the DOM and added toggles to them.rust/src/librustdoc/html/static/main.js
Lines 1856 to 1867 in 73b97c7
The
item-decl
is no longer auto-hidden since c96f86d removed it.item-decl
used to be calledtype-decl
: that name was changed in 8b7a2dd.The
docblock
class is no longer used for implementing toggles, since rustdoc switched to using<details>
elements.Preview: https://notriddle.com/notriddle-rustdoc-test/docblock-item-decl/rustdoc/clean/types/enum.Type.html