1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-17 07:41:26 +00:00

[rename] click outside the form to hide the form

This commit is contained in:
llj
2015-09-09 14:23:14 +08:00
parent f986bfa5cd
commit d76b0d7065
2 changed files with 14 additions and 2 deletions

View File

@@ -89,6 +89,16 @@ define([
}
}
});
// hide 'rename form'
$(document).click(function(e) {
var target = e.target || event.srcElement;
var $form = $('#rename-form');
if ($form.length && !$form.find('*').is(target)) {
$('.cancel', $form).click();
}
});
},
showDir: function(category, repo_id, path) {