-
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: use javascript to layout notable traits popups #104129
rustdoc: use javascript to layout notable traits popups #104129
Conversation
r? @jsha (rustbot has picked a reviewer for you, use r? to override) |
Some changes occurred in HTML/CSS/JS. cc @GuillaumeGomez, @Folyd, @jsha |
424ba55
to
92afac0
Compare
92afac0
to
a45151e
Compare
It's similar to my approach in #91431. I personally like it. What do you think @Manishearth ? |
Seems like a clean way to do this. Not elated about having more JS but I think this is as good a place to have it if any. |
Let's just run a perf check beforehand but otherwise I think it's ready to go. @bors try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
⌛ Trying commit a45151e with merge 9e5dcb830b5225cf66838466cf4a2db1058fa8d8... |
☀️ Try build successful - checks-actions |
This comment has been minimized.
This comment has been minimized.
Finished benchmarking commit (9e5dcb830b5225cf66838466cf4a2db1058fa8d8): comparison URL. Overall result: ❌ regressions - no action neededBenchmarking this pull request likely means that it is perf-sensitive, so we're automatically marking it as not fit for rolling up. While you can manually mark this PR as fit for rollup, we strongly recommend not doing so since this PR may lead to changes in compiler perf. @bors rollup=never Instruction countThis is a highly reliable metric that was used to determine the overall result at the top of this comment.
Max RSS (memory usage)ResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
|
Seems fine so let's go! @bors r+ rollup |
…ble-trait, r=GuillaumeGomez rustdoc: use javascript to layout notable traits popups Fixes rust-lang#102576 Preview: https://notriddle.com/notriddle-rustdoc-demos/102576-js-notable-trait/std/iter/trait.Iterator.html#method.step_by ## Before ![image](https://user-images.githubusercontent.com/1593513/200432713-23aa8d49-ba2b-469f-9eab-089e0c174039.png) ## After ![image](https://user-images.githubusercontent.com/1593513/200432735-edd5b53d-e99d-4fc5-9410-8a79e0efdc9d.png)
…ble-trait, r=GuillaumeGomez rustdoc: use javascript to layout notable traits popups Fixes rust-lang#102576 Preview: https://notriddle.com/notriddle-rustdoc-demos/102576-js-notable-trait/std/iter/trait.Iterator.html#method.step_by ## Before ![image](https://user-images.githubusercontent.com/1593513/200432713-23aa8d49-ba2b-469f-9eab-089e0c174039.png) ## After ![image](https://user-images.githubusercontent.com/1593513/200432735-edd5b53d-e99d-4fc5-9410-8a79e0efdc9d.png)
…ble-trait, r=GuillaumeGomez rustdoc: use javascript to layout notable traits popups Fixes rust-lang#102576 Preview: https://notriddle.com/notriddle-rustdoc-demos/102576-js-notable-trait/std/iter/trait.Iterator.html#method.step_by ## Before ![image](https://user-images.githubusercontent.com/1593513/200432713-23aa8d49-ba2b-469f-9eab-089e0c174039.png) ## After ![image](https://user-images.githubusercontent.com/1593513/200432735-edd5b53d-e99d-4fc5-9410-8a79e0efdc9d.png)
b3edd70
to
05824cd
Compare
@bors r+ |
@bors rollup=iffy |
…earth Rollup of 8 pull requests Successful merges: - rust-lang#95292 (Allow specialized const trait impls.) - rust-lang#100386 (Make `Sized` coinductive, again) - rust-lang#102215 (Implement the `+whole-archive` modifier for `wasm-ld`) - rust-lang#103468 (Fix unused lint and parser caring about spaces to won't produce invalid code) - rust-lang#103531 (Suggest calling the instance method of the same name when method not found) - rust-lang#103960 (piece of diagnostic migrate) - rust-lang#104051 (update Miri) - rust-lang#104129 (rustdoc: use javascript to layout notable traits popups) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
…it-v2, r=GuillaumeGomez rustdoc: use consistent "popover" styling for notable traits Follow-up to rust-lang#104129 Fixes rust-lang#104313. Preview: https://notriddle.com/notriddle-rustdoc-demos/js-notable-trait-v2/std/iter/trait.Iterator.html#method.step_by ## Before ![image](https://user-images.githubusercontent.com/1593513/200710372-d2d992ce-0bdc-4437-9a2e-379a29df09cf.png) ![image](https://user-images.githubusercontent.com/1593513/200711266-e372b176-daa9-45f3-a022-738ef0a77d3c.png) ## After ![image](https://user-images.githubusercontent.com/1593513/200710601-09b3b717-116f-43c6-b14f-34a8b02b33c0.png) ![image](https://user-images.githubusercontent.com/1593513/200711288-3978cdc1-a6c2-47f6-9216-e22e3c1f5bdf.png)
…it-v2, r=GuillaumeGomez rustdoc: use consistent "popover" styling for notable traits Follow-up to rust-lang#104129 Fixes rust-lang#104313. Preview: https://notriddle.com/notriddle-rustdoc-demos/js-notable-trait-v2/std/iter/trait.Iterator.html#method.step_by ## Before ![image](https://user-images.githubusercontent.com/1593513/200710372-d2d992ce-0bdc-4437-9a2e-379a29df09cf.png) ![image](https://user-images.githubusercontent.com/1593513/200711266-e372b176-daa9-45f3-a022-738ef0a77d3c.png) ## After ![image](https://user-images.githubusercontent.com/1593513/200710601-09b3b717-116f-43c6-b14f-34a8b02b33c0.png) ![image](https://user-images.githubusercontent.com/1593513/200711288-3978cdc1-a6c2-47f6-9216-e22e3c1f5bdf.png)
…ble-trait, r=Manishearth rustdoc: use javascript to layout notable traits popups Fixes rust-lang#102576 Preview: https://notriddle.com/notriddle-rustdoc-demos/102576-js-notable-trait/std/iter/trait.Iterator.html#method.step_by ## Before ![image](https://user-images.githubusercontent.com/1593513/200432713-23aa8d49-ba2b-469f-9eab-089e0c174039.png) ## After ![image](https://user-images.githubusercontent.com/1593513/200432735-edd5b53d-e99d-4fc5-9410-8a79e0efdc9d.png)
…earth Rollup of 8 pull requests Successful merges: - rust-lang#95292 (Allow specialized const trait impls.) - rust-lang#100386 (Make `Sized` coinductive, again) - rust-lang#102215 (Implement the `+whole-archive` modifier for `wasm-ld`) - rust-lang#103468 (Fix unused lint and parser caring about spaces to won't produce invalid code) - rust-lang#103531 (Suggest calling the instance method of the same name when method not found) - rust-lang#103960 (piece of diagnostic migrate) - rust-lang#104051 (update Miri) - rust-lang#104129 (rustdoc: use javascript to layout notable traits popups) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
The old TODO comment stopped applying when rust-lang#104129 stopped nesting the notable traits popover within the header.
Fixes #102576
Preview: https://notriddle.com/notriddle-rustdoc-demos/102576-js-notable-trait/std/iter/trait.Iterator.html#method.step_by
Before
After