mirror of
https://github.com/PrivateBin/PrivateBin.git
synced 2025-07-24 07:20:45 -04:00
change loading confirm prefix, fix password modal focus, again
This commit is contained in:
parent
03d2291ec7
commit
25de89c954
3 changed files with 9 additions and 11 deletions
|
@ -82,7 +82,7 @@ jQuery.PrivateBin = (function($, RawDeflate) {
|
|||
*
|
||||
* @private
|
||||
*/
|
||||
const loadConfirmPrefix = '#?';
|
||||
const loadConfirmPrefix = '#-';
|
||||
|
||||
/**
|
||||
* CryptoData class
|
||||
|
@ -2303,7 +2303,12 @@ jQuery.PrivateBin = (function($, RawDeflate) {
|
|||
backdrop: 'static',
|
||||
keyboard: false
|
||||
});
|
||||
// focus password input
|
||||
$passwordDecrypt.focus();
|
||||
// then re-focus it, when modal causes it to loose focus again
|
||||
setTimeout(function () {
|
||||
$passwordDecrypt.focus();
|
||||
}, 500);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -2363,13 +2368,7 @@ jQuery.PrivateBin = (function($, RawDeflate) {
|
|||
$passwordForm = $('#passwordform');
|
||||
$passwordModal = $('#passwordmodal');
|
||||
|
||||
// bind events
|
||||
|
||||
// focus password input when it is shown
|
||||
$passwordModal.on('shown.bs.Model', function () {
|
||||
$passwordDecrypt.focus();
|
||||
});
|
||||
// handle Model password submission
|
||||
// bind events - handle Model password submission
|
||||
$passwordForm.submit(submitPasswordModal);
|
||||
};
|
||||
|
||||
|
@ -3603,7 +3602,6 @@ jQuery.PrivateBin = (function($, RawDeflate) {
|
|||
if (fadeOut === true) {
|
||||
setTimeout(function () {
|
||||
$comment.removeClass('highlight');
|
||||
|
||||
}, 300);
|
||||
}
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue