aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick H. Lauke <[email protected]>2017-04-09 22:00:51 +0100
committerGitHub <[email protected]>2017-04-09 22:00:51 +0100
commit6702107131b810da91fcec040c4d74f79d3a1a26 (patch)
tree8cc02aee663ccf69d055c34f3cfa9fb487a9f2c3
parent0719ab18887c5b7415b9042b3ac60008de593f9f (diff)
parent2626eba5f1218dc79064598e2f43a30116bd5742 (diff)
downloadbootstrap-6702107131b810da91fcec040c4d74f79d3a1a26.tar.xz
bootstrap-6702107131b810da91fcec040c4d74f79d3a1a26.zip
Merge pull request #22398 from patrickhlauke/v4-dev-modal-macos-fullscreen-esc-fix
Prevent default for ESC in modal.js
-rw-r--r--js/src/modal.js1
1 files changed, 1 insertions, 0 deletions
diff --git a/js/src/modal.js b/js/src/modal.js
index 779b9a402..02d463945 100644
--- a/js/src/modal.js
+++ b/js/src/modal.js
@@ -289,6 +289,7 @@ const Modal = (($) => {
if (this._isShown && this._config.keyboard) {
$(this._element).on(Event.KEYDOWN_DISMISS, (event) => {
if (event.which === ESCAPE_KEYCODE) {
+ event.preventDefault()
this.hide()
}
})