rustdoc: when running a function-signature search, tweak the tab bar#96590
rustdoc: when running a function-signature search, tweak the tab bar#96590bors merged 6 commits intorust-lang:masterfrom
Conversation
|
Some changes occurred in HTML/CSS/JS. |
|
r? @CraftSpider (rust-highfive has picked a reviewer for you, use r? to override) |
|
Considering it's a UI/UX change, I'd like to have @jsha and @Manishearth's opinion before going further. Personally I think it'd be a nice improvement. |
|
I think it's a good call! |
|
Agreed! This is something that's bugged me for a while. Thanks for fixing it. |
|
Ok so just remains to add a differentiation between returned value and "in function signature" and then let's go! |
|
There is a JS error when the results are displayed: The left/right arrows should be disabled in case there is only one column displayed, otherwise it looks like this (no "selected" header): Please add a check in your GUI test for the left/right arrows in such case to ensure that it doesn't change the selected header. |
This comment has been minimized.
This comment has been minimized.
1a4840f to
88aabf8
Compare
|
Okay, I've got the keyboard shortcut thing fixed. |
|
I can confirm it's working locally as expected. 👍 |
|
I see. The error came up when there was a parse error, because the code doesn't work well when there's no tabs at all. To avoid adding a bunch of special-cases just for the parse error screen, I've added an "In Names" tab (conceptually, this is where doc aliases go), fixing the console log error. |
|
Just one last weird thing: It's a bit of strange rendering with doc aliases. Not a blocker though. You can try it with: #[doc(alias = "->a")]
pub struct Foo;Just confirming it's not an issue then let's go! What do you think of this @Manishearth @jsha ? I personally think it's fine but asking just in case. |
|
I get why this seems strange, but
|
|
I think @notriddle's comment makes sense and I think the image @GuillaumeGomez showed is fine. |
|
☔ The latest upstream changes (presumably #96720) made this pull request unmergeable. Please resolve the merge conflicts. |
|
I said I was fine with it but thanks for the extra explanations. :) r=me once you fixed the conflict. |
Co-Authored-By: Guillaume Gomez <guillaume1.gomez@gmail.com>
* If it's just `-> a`, use "In Function Return Types" * If it's just `a b`, use "In Function Parameters" * Otherwise, still use "In Function Signatures"
45cf0be to
4c183cd
Compare
|
@bors r=GuillaumeGomez,jsha |
|
📌 Commit 4c183cd has been approved by |
…ch, r=GuillaumeGomez,jsha rustdoc: when running a function-signature search, tweak the tab bar # Before  # After 
…ch, r=GuillaumeGomez,jsha rustdoc: when running a function-signature search, tweak the tab bar # Before  # After 
…ch, r=GuillaumeGomez,jsha rustdoc: when running a function-signature search, tweak the tab bar # Before  # After 
…ch, r=GuillaumeGomez,jsha rustdoc: when running a function-signature search, tweak the tab bar # Before  # After 
…laumeGomez Rollup of 10 pull requests Successful merges: - rust-lang#96557 (Allow inline consts to reference generic params) - rust-lang#96590 (rustdoc: when running a function-signature search, tweak the tab bar) - rust-lang#96650 (Collect function instance used in `global_asm!` sym operand) - rust-lang#96733 (turn `append_place_to_string` from recursion into iteration) - rust-lang#96748 (Fixes reexports in search) - rust-lang#96752 (Put the incompatible_closure_captures lint messages in alphabetical order) - rust-lang#96754 (rustdoc: ensure HTML/JS side implementors don't have dups) - rust-lang#96772 (Suggest fully qualified path with appropriate params) - rust-lang#96776 (Fix two minor issues in hir.rs) - rust-lang#96782 (a small `mirror_expr` cleanup) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup




Before
After