Skip to content
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

Explain what ESC does #82522

Closed
wants to merge 2 commits into from
Closed

Conversation

TaKO8Ki
Copy link
Member

@TaKO8Ki TaKO8Ki commented Feb 25, 2021

This pull request adds a text to explain what ESC does in doc.

closes #82474

@rust-highfive
Copy link
Collaborator

Some changes occurred in HTML/CSS/JS.

cc @GuillaumeGomez

@rust-highfive
Copy link
Collaborator

r? @GuillaumeGomez

(rust-highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Feb 25, 2021
@TaKO8Ki TaKO8Ki force-pushed the explain-what-esc-does branch 2 times, most recently from 0c121bb to df0a27e Compare February 25, 2021 18:09
@@ -2913,6 +2913,7 @@ function defocusSearchBar() {
["⏎", "Go to active search result"],
["+", "Expand all sections"],
["-", "Collapse all sections"],
["esc", "Close the search view"],
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It does a few other things like:

  • Removing the query parameters from the URL (like ?whatever=12)
  • Closing the help popup
  • Closing the theme list if open
  • Blurring the focus from the search input

@TaKO8Ki TaKO8Ki force-pushed the explain-what-esc-does branch 5 times, most recently from 857cdbd to 56c5a4e Compare February 25, 2021 19:51
@TaKO8Ki TaKO8Ki closed this Feb 25, 2021
@TaKO8Ki TaKO8Ki reopened this Feb 25, 2021
@TaKO8Ki TaKO8Ki force-pushed the explain-what-esc-does branch 5 times, most recently from 21f796a to 4475900 Compare February 25, 2021 20:31
@jyn514 jyn514 added A-rustdoc-ui Area: Rustdoc UI (generated HTML) T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. labels Feb 26, 2021
@GuillaumeGomez
Copy link
Member

I'm not a big fan of this listing, even more since I'm sure it might do more things in the future (and I very likely forgot some of them...). However I don't have an idea on how to improve it... Maybe some from @rust-lang/rustdoc has an idea?

@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer
Copy link
Collaborator

The job mingw-check failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)
configure: rust.channel         := nightly
configure: rust.debug-assertions := True
configure: llvm.assertions      := True
configure: dist.missing-tools   := True
configure: build.configure-args := ['--enable-sccache', '--disable-manage-submodu ...
configure: writing `config.toml` in current directory
configure: 
configure: run `python /checkout/x.py --help`
configure: 
---
Checking which error codes lack tests...
Found 436 error codes
Found 0 error codes with no tests
Done!
tidy error: /checkout/src/librustdoc/html/static/main.js:2916: line longer than 100 chars
some tidy checks failed

command did not execute successfully: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-tools-bin/tidy" "/checkout" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0/bin/cargo" "/checkout/obj/build"
expected success, got: exit code: 1

@camelid
Copy link
Member

camelid commented Feb 26, 2021

I also don't feel this change makes sense. esc here doesn't do anything out of the ordinary; people expect esc to escape from a particular view. If we were using esc like Emacs, as a control key, then I think it should be documented, but none of these seem particularly helpful to document to me.

@TaKO8Ki
Copy link
Member Author

TaKO8Ki commented Mar 1, 2021

@camelid @GuillaumeGomez @jyn514
I think "↑" and "↓" don't do anything out of the ordinary, but they are documented. Considering that, I think esc should also be documented. Is it not necessary to explain what esc does?
If so, does anyone have the way to improve the listing?

@GuillaumeGomez
Copy link
Member

Both arrows definitely do something "out of the ordinary". You don't expect to be able to go through search results by simply pressing up and down arrows from the search input.

@TaKO8Ki
Copy link
Member Author

TaKO8Ki commented Mar 1, 2021

@GuillaumeGomez
Hmm. I think different people have different thoughts and we should define what is ordinary thing in this case. Anyway, I accepted your opinion. I'm going to close #82474 and this pull request.

@TaKO8Ki TaKO8Ki closed this Mar 1, 2021
@TaKO8Ki TaKO8Ki deleted the explain-what-esc-does branch March 1, 2021 16:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-rustdoc-ui Area: Rustdoc UI (generated HTML) S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[rustdoc]: Explain what ESC does in the help box
6 participants