-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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
Fixed issue when escape key is pressed to close prompt #25349
Changes from 12 commits
a4a2ff7
c42d48a
b8e0c42
d6995f7
c9f9757
240fc19
da6b361
db51191
3e25bd1
633ea17
5d676b6
997959f
d3aa932
65b2afe
727679d
b41ea13
552eaaf
ce6614e
c14fbed
257eb00
b1ab6a9
53fe8ee
437fab3
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -154,8 +154,7 @@ define([ | |
*/ | ||
closeModal: function (result) { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Modify these functions to accept the event as an argument and use it in closeModal function call as a first argument(same as in confirm.js). After that, start accepting in closeModal event as first argument and result as second(example). |
||
var value; | ||
|
||
if (result) { | ||
if (result && !(result instanceof $.Event)) { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What is the purpose of the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Actually, Initially we are passing only event so when this if condition is executed then result is taking as true so I've additional condition added that result should be instance of the event but I think we don't need now cause I have added condition if result is not passed then result will take as false |
||
if (this.options.validation && !this.validate()) { | ||
return false; | ||
} | ||
|
@@ -177,3 +176,4 @@ define([ | |
return $('<div class="prompt-message"></div>').html(config.content).prompt(config); | ||
}; | ||
}); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please, revert these changes. Apply function doesn't accept the third argument.