-
Notifications
You must be signed in to change notification settings - Fork 25
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
HiddenInput div appears when hitting backspace on empty div #7
Comments
Thanks, yes, the div is used in the undoer (a hack because there is no undo API to hook into). You can fix this by modifying _cleanUpAttributes as follows. Besides avoiding the problem you noticed, this also makes sure the editor is left with a blank paragraph in its "empty" state. I will fold this into the coming update.
|
Thanks Steven! This seems to be working well. I can also create a PR to merge into your main branch. |
… <I>, etc) across a selection. Fix delete on empty doc per #7
This fix is included in 0.3.2. Thx. |
Hi @stevengharris,
I have noticed that when the content is empty, hitting backspace will cause a div counter to be visible at the bottom of the main editable div. I went through the logic in markup.js file to get a gist of it, its related to the undo and redo function, and there is a logic that modifies the visibility style of the div. I am not sure what is the purpose of it being visible.
I have attached a screen recording of this occurring.
https://user-images.githubusercontent.com/4402214/167055277-ac743213-878e-4e9a-be7a-8282dc5e37da.mp4
The text was updated successfully, but these errors were encountered: