From cb31b875f920abbbdd06bebb0f4e6edd90845cda Mon Sep 17 00:00:00 2001 From: Tanguy Krotoff Date: Thu, 27 Mar 2014 11:13:44 +0100 Subject: [PATCH] fix(modal): give a reason of rejection when escape key pressed Fixes #1956 Closes #1991 --- src/modal/modal.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modal/modal.js b/src/modal/modal.js index 3b30469a29..c86048ded3 100644 --- a/src/modal/modal.js +++ b/src/modal/modal.js @@ -200,7 +200,7 @@ angular.module('ui.bootstrap.modal', ['ui.bootstrap.transition']) modal = openedWindows.top(); if (modal && modal.value.keyboard) { $rootScope.$apply(function () { - $modalStack.dismiss(modal.key); + $modalStack.dismiss(modal.key, 'escape key press'); }); } }