Automattic / Automattic/simplenote-electron
"End" key doesn't move cursor to the end of the current line for multi-line text
- Dominant language
- TypeScript
- Stars
- 5.3k
- Forks
- 588
- Avg merge
- 9h 45m
- Merged PRs (30d)
- 4
Description
Two reports from the forums about the unexpected behavior of pressing the "End" key on a muti-line text.
### Expected
Pressing the "End" will move the cursor to the end of the current line.
### Observed
The cursor moved to the beginning of the next line when pressing the "End" key. This is only happening when the text wraps in a few lines.
### Reproduced
1. Add a multi-line paragraph in the app
2. Move the cursor to the beginning of the paragraph
3. Press the "End" key on your keyboard
4. Notice the cursor moves to the beginning of the next line instead of the end of the current line
#### Screen recording
https://user-images.githubusercontent.com/40906847/231963727-854b4c79-4c4e-4f30-b425-799fc9eed35f.mp4
### Where did you see the bug
OS Version | App version
--- | ---
Linux Mint 20.3 Cinnamon | 2.21.0
Windows 10 | 2.21.0
Ubuntu 20.04 | 2.21.0
Contributor guide
Research direction
Start by reproducing the issue in the app with a wrapped multi-line paragraph, following the four steps in the report. Trace the text editor's handling of the End key and verify that it places the cursor at the end of the current visual line rather than at the beginning of the next line.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100