apostrophe icon indicating copy to clipboard operation
apostrophe copied to clipboard

UX bug: Cursor jumps around when editing Slug field

Open dmschulman opened this issue 4 years ago • 2 comments

To Reproduce

  1. Click into Pages and edit a page
  2. On Basics pane, edit the Slug field
  3. Enter a slug with 3 or more words separated by hyphens (ie "my-great-field")
  4. Use delete key to remove the middle word ("great") from the slug
  5. When the word is removed, cursor jumps to the end of the slug field.

Expected behavior

When editing a parameter in a text field, I would expect the text cursor to stay in the same position no matter what edit was made.

Describe the bug

I first noticed this when editing a Form, but it also applies to editing Pages, Users, and any area that uses the Slug field.

Text cursor jumps to the end of the slug value when editing the Slug field. This only appears to happen when 3 or more words, separated by hyphens, are in the slug value and a user edits the slug.

If the slug is "my-great-field" and I remove "great" from the value, we're left with "my-field" and the text cursor jumps to the end of the line instead of remaining in position.

Details

Version of Node.js: 17.7.2

Server Operating System: Arch Linux x64, kernel 5.16.14

Additional context: Using Google Chrome on desktop

dmschulman avatar Mar 22 '22 18:03 dmschulman

Hi, can I get assigned to this issue, Thanks

jyzib avatar Apr 18 '23 06:04 jyzib

Hi @jyzib - We don't use that feature. If you would like to work on this problem, you can just keep us updated here until you file a PR. I wouldn't mind getting an update about whether you can repeat the bug and what your approach will be. Cheers, Bob

BoDonkey avatar Apr 18 '23 09:04 BoDonkey