-
Notifications
You must be signed in to change notification settings - Fork 51
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
Undo to the wrong state #5
Comments
Thanks for the report. Though since this is just a demo, I don't have plans for fixing this issue. I'd review a PR and merge it, but that's about it. |
Ok, thanks for the reply, I'm also reviewing Arthur's Undo Manager. If that ends up being a dead end, I may see what I can do as far as fixing yours. |
If you find something that works better than this proof of concept, I'd be happy to point everyone to that instead (in the readme). |
@jzaefferer This is a very nice undo plugin. but there is still a bug just like what @circleb told. |
Sorry to hear that, but my previous comments still apply. PRs are welcome, but I can't help beyond that. |
Yeah, that's fine. I'll try to take a look at your code later. |
Hi, I tested this plugin and I also discovered a bug in the demo, of the same type as the one explained by circleb. The problem comes from the variable "Startvalue": this variable is updated when the text changes but it is not updated when you click on the "Undo" button ... So after a "undo" the variable "startvalue" is not updated so when you modify the text you record in the undo stack an "EditCommand" with a bad value for the property "oldValue". 1- You can solve the first problem in several ways, here is a way:
by :
2- You can solve the second problem by replacing this code:
by :
|
There appears to be a bug with the contenteditable demo, here's how it goes:
I've tried hitting save at all of the various intervals in the sequence but this is very persistent...
The text was updated successfully, but these errors were encountered: