Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Update alert.js #66

Merged
merged 2 commits into from
Mar 8, 2019
Merged

Update alert.js #66

merged 2 commits into from
Mar 8, 2019

Conversation

alexcanana
Copy link
Contributor

Related to #64.

Prevent the modal from closing on onCancel() and onConfirm().

Prevent the modal from closing onConfirm and onCancel
@VizuaaLOG
Copy link
Owner

This needs to be behind an option. In 99% of cases the alert will need to close when the button is pressed, so the default would need to do this.

Adding new options closeOnConfirm and closeOnCancel should be sufficient. Both defaulting to true.

@alexcanana
Copy link
Contributor Author

Alright, I can work on this tonight.

Thanks for the feedback.

@alexcanana
Copy link
Contributor Author

OK, I updated the plugin by adding two new options:

  • closeOnConfirm
  • closeOnCancel

Still think it's a little overkill since 2 to 4 parameters need initializing just to prevent an alert from closing.

@VizuaaLOG VizuaaLOG merged commit f929e76 into VizuaaLOG:master Mar 8, 2019
VizuaaLOG pushed a commit that referenced this pull request Jun 23, 2019
* Update alert.js

Prevent the modal from closing onConfirm and onCancel

* Add options to prevent an alert from closing
# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants