Skip to content
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

No setting to disable invokeOnClose #8

Closed
quietsy opened this issue Oct 1, 2014 · 3 comments
Closed

No setting to disable invokeOnClose #8

quietsy opened this issue Oct 1, 2014 · 3 comments

Comments

@quietsy
Copy link

quietsy commented Oct 1, 2014

Hello,
I've added a new setting to allow disabling invokeOnClose in confirm dialogs when needed, if this is useful for other people, maybe it can be added to the source.

            case 'disableInvokeCancelOnClose':
                if (newValue === true) {
                    this.__internal.buttons[1].invokeOnClose = false;
                }
                break;

Thanks for this great project.

@MohammadYounes
Copy link
Owner

Hi,

Shouldn't closing the dialog be equal to clicking Cancel ? This way the user will have 3 options instead of 2:

  1. Click Ok to confirm.
  2. Click Cancel to decline.
  3. Close the dialog ... which means what ?

@quietsy
Copy link
Author

quietsy commented Oct 1, 2014

For example, if the user made changes in a form and then presses a link:

  1. Save changes (save+navigate to the link)
  2. Discard changes (discard+navigate to the link)
  3. Close and stay on the page without navigating

@MohammadYounes
Copy link
Owner

I think its somehow confusing to the user, a better option would be a dialog with 3 buttons (Save, Discard and Cancel).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants