Commit c8999d9
authored
Rollup merge of rust-lang#93286 - jsha:sidebar-nowrap, r=GuillaumeGomez
Add white-space: nowrap to links in the sidebar
We already have overflow: hidden on these links, but if there is a possibility to wrap, they will wrap. This happens in particular for trait implementations because the punctuation (`<>, `) introduces opportunities for breaks. That produces inconsistent UI. Fix it by forcing them not to wrap.
Demo: https://rustdoc.crud.net/jsha/sidebar-nowrap/std/string/struct.String.html
To see the effect, scroll down to the "Trait Implementations" portion of the sidebar and look at IndexMut. Compare vs:
https://doc.rust-lang.org/std/string/struct.String.html
https://doc.rust-lang.org/nightly/std/string/struct.String.html
r? `@camelid`File tree
3 files changed
+14
-0
lines changed- src
- librustdoc/html/static/css
- test/rustdoc-gui
- src/lib2
3 files changed
+14
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
484 | 484 | | |
485 | 485 | | |
486 | 486 | | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
| 490 | + | |
487 | 491 | | |
488 | 492 | | |
489 | 493 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
74 | 74 | | |
75 | 75 | | |
76 | 76 | | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
114 | 114 | | |
115 | 115 | | |
116 | 116 | | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
0 commit comments