Problem/motivation
Ckeditor5 link url form submit on enter keypress or non-autocomplete selection does not remove existing data-* attributes.
This is a problem when changing a link from one that should be linkit url converted to a link that should not.

Steps to reproduce
1. Create a link from an autocomplete suggestion by mouse clicking on it.
View source to see that data-* attributes were set.
2. Edit the link, change the link by typing in a new value such as "google.com" and keypress enter.
View source to see that the href is now "google.com" but data-* attributes for previous entity still exists.
Comments
Comment #2
drpldrp commentedComment #3
drpldrp commentedComment #4
drpldrp commentedComment #5
drpldrp commentedComment #6
drpldrp commentedComment #7
drpldrp commentedComment #8
drpldrp commentedComment #9
drpldrp commentedThis one might be the cleanest but relies on addEventListener('input'.
Comment #10
drpldrp commentedComment #11
mark_fullmerComment #13
mark_fullmerI was able to reproduce the problem, verified the fix, and reviewed the logic of the code change. Thanks for reporting and for the fix!