Closed mi-dh closed 6 years ago
Hello,
"cancel" button exists.
As for not doing nothing if input is the same. I'll see about adding new features in the future, for now it's resurrecting from the dead mode, and only bugfixes :)
You can use onsubmit hook for that. If it returns false, no ajax request will be made :)
Currently, only an "OK" button is available (as far as I am aware). It would be nice to also have an optional "cancel" button. But that is just a side note.
Actually I would embrace a simple (most likely optional) check on whether the effective data has changed and if not, (optionally) simply dismiss the Ajax part (=reducing redundant overhead). Achieving this from outside/around the plugin is no option as the Ajax call is fired straightforwardly after the submit action and there is no (simple or sense-making) way to control the user input.
It should be really easy to achieve, by just storing the input element's value right after its markup creation in the DOM and comparing it to what is about to be sent afterwards. What do you think?