Upload a file with a password

This commit is contained in:
yflory
2018-05-28 17:50:28 +02:00
parent 8aac7bad45
commit 66655b4a23
4 changed files with 39 additions and 5 deletions

View File

@@ -425,9 +425,14 @@ define([
cb = cb || function () {};
opt = opt || {};
var input = dialog.textInput();
var inputBlock = opt.password ? UI.passwordInput() : dialog.textInput();
var input = opt.password ? $(inputBlock).find('input')[0] : inputBlock;
input.value = typeof(def) === 'string'? def: '';
if (opt.password) {
$(inputBlock).find('.cp-checkmark').css('margin-bottom', '15px');
}
var message;
if (typeof(msg) === 'string') {
if (!force) { msg = Util.fixHTML(msg); }
@@ -441,7 +446,7 @@ define([
var cancel = dialog.cancelButton(opt.cancel);
var frame = dialog.frame([
message,
input,
inputBlock,
dialog.nav([ cancel, ok, ]),
]);