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

chore: support for shift+home/end keys #306

Merged
merged 5 commits into from
Jul 13, 2023

Conversation

MayurSMahajan
Copy link
Contributor

@MayurSMahajan MayurSMahajan commented Jul 12, 2023

Partially Solves: #2888

In the current AppFlowy Editor version the shortcut we support for selecting till the beginning of a line and till the end of a line is Ctrl/Cmd + shift + arrow left/arrow right. Although in Windows and Linux the default shortcut for this is Shift+home/end. This PR enables that.

Another default behavior on Windows and Linux is selecting a word with Ctrl+arrow left/arrow right, however, the current editor version achieves the same functionality by alt+arrow left/arrow right. This PR introduces the default command for Windows and Linux.

This PR also contains some new tests that improve the code coverage.

@codecov
Copy link

codecov bot commented Jul 12, 2023

Codecov Report

Merging #306 (681cd1d) into main (d87d353) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main     #306   +/-   ##
=======================================
  Coverage   74.53%   74.53%           
=======================================
  Files         237      237           
  Lines        9519     9519           
=======================================
  Hits         7095     7095           
  Misses       2424     2424           
Impacted Files Coverage Δ
...ts/command_shortcut_events/arrow_left_command.dart 92.53% <ø> (ø)
...s/command_shortcut_events/arrow_right_command.dart 91.93% <ø> (ø)

@LucasXu0 LucasXu0 merged commit 6830014 into AppFlowy-IO:main Jul 13, 2023
@MayurSMahajan MayurSMahajan deleted the fr_shift_home_end_key_2888 branch July 13, 2023 12:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants