mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-17 22:57:21 +01:00
Fixes task left in odd setting when cancelling editing with ESC / Escape Key; add click outside to close modal #8308 #8321 (#8382)
* Remove backdrop property from open modal call to allow click-outside to close, call cancelTaskEdit function on dismissal of edit modal via ESC or click-outside * Remove commented out code, change catch function to normal (non-arrow) * Modify task services test mock openModal function, to handle new use of subsequent promise resolution functionality * Tidy old edit controls away
This commit is contained in:
committed by
Keith Holliday
parent
2b80931202
commit
ef4aeb29ab
@@ -271,7 +271,10 @@ angular.module('habitrpg')
|
||||
}
|
||||
modalScope.cancelTaskEdit = cancelTaskEdit;
|
||||
|
||||
$rootScope.openModal('task-edit', {scope: modalScope, backdrop: 'static'});
|
||||
$rootScope.openModal('task-edit', {scope: modalScope })
|
||||
.result.catch(function() {
|
||||
cancelTaskEdit(task);
|
||||
});
|
||||
}
|
||||
|
||||
function cancelTaskEdit(task) {
|
||||
|
||||
Reference in New Issue
Block a user