Skip to content

Add esc-to-deselect-line feature - #1878

Merged
fregante merged 5 commits into
masterfrom
deselect-line
Mar 25, 2019
Merged

Add esc-to-deselect-line feature#1878
fregante merged 5 commits into
masterfrom
deselect-line

Conversation

@fregante

@fregante fregante commented Mar 22, 2019

Copy link
Copy Markdown
Member

@sindresorhus

Copy link
Copy Markdown
Member

@fregante

fregante commented Mar 24, 2019

Copy link
Copy Markdown
Member Author

Indeed. Currently it only checks for #L but that is #diff-, which is not necessarily just a line selection, but it could also be a file selection.

@sindresorhus

sindresorhus commented Mar 24, 2019

Copy link
Copy Markdown
Member

You can detect it though. Notice how line selections end in R23 where 23 is the line number, while file selections don't.

@fregante
fregante merged commit f26911b into master Mar 25, 2019
@sindresorhus
sindresorhus deleted the deselect-line branch March 25, 2019 04:44
@fregante fregante mentioned this pull request Mar 30, 2019
@tomirons

Copy link
Copy Markdown

This doesn't work on Chrome for MacOS 74.0.3729.169. I tried viewing a commit and a specific file, neither of them worked.

Any tips for Mac users?

@fregante

fregante commented May 30, 2019

Copy link
Copy Markdown
Member Author

It works for me in Firefox and Chrome.

  1. Visit this
  2. Press ESC
  3. Notice the 2 selected lines becoming unselected

@tomirons

Copy link
Copy Markdown

Unfortunately that still doesn't work. I even tried key combinations like cmd + esc, option + esc, control + esc, and fn + esc.

@afolarin

Copy link
Copy Markdown

Esc not working for me on Chrome
Google Chrome 78.0.3904.70 (Official Build) (64-bit)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

Unselect selected lines on files or commits

4 participants