diff --git a/js/privatebin.js b/js/privatebin.js index f05afa79..e48ccbcb 100644 --- a/js/privatebin.js +++ b/js/privatebin.js @@ -2305,6 +2305,7 @@ jQuery.PrivateBin = (function($, RawDeflate) { backdrop: 'static', keyboard: false }); + $passwordModal.modal('show'); // focus password input $passwordDecrypt.focus(); // then re-focus it, when modal causes it to loose focus again @@ -3926,7 +3927,10 @@ jQuery.PrivateBin = (function($, RawDeflate) { text: window.location.href }); $('#qrcode-display').html(qrCanvas); - $('#qrcodemodal').modal('show'); + // only necessary for bootstrap 5, other templates won't have this + if (bootstrap.Tooltip.VERSION) { + $('#qrcodemodal').modal('show'); + } } /** diff --git a/tpl/bootstrap.php b/tpl/bootstrap.php index 23a06a48..3ea05f43 100644 --- a/tpl/bootstrap.php +++ b/tpl/bootstrap.php @@ -73,7 +73,7 @@ endif; ?> - + diff --git a/tpl/bootstrap5.php b/tpl/bootstrap5.php index 7857edd7..79f31aa8 100644 --- a/tpl/bootstrap5.php +++ b/tpl/bootstrap5.php @@ -57,7 +57,7 @@ endif; ?> - + @@ -86,7 +86,7 @@ endif;