Merge pull request #1771 from keepassxreboot/fix/remove_overflow_menu_exceptions

Remove special handling for Firefox overflow/hamburger menu
This commit is contained in:
Sami Vänttinen 2023-12-17 12:55:07 +02:00 committed by GitHub
commit 924560db4b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 1 additions and 33 deletions

View file

@ -4,10 +4,9 @@ body {
display: flex;
font-family: sans-serif;
font-size: 14px !important;
overflow: hidden;
padding-top: 8px;
padding-bottom: 8px;
width: fit-content;
width: 460px;
}
code {

View file

@ -15,9 +15,6 @@
<script defer src="../common/translate.js"></script>
</head>
<body>
<script>
setDefaultPopupSize();
</script>
<div class="container">
<div id="settings" class="settings">
<div class="action-buttons-area">

View file

@ -75,7 +75,6 @@ const sendMessageToTab = async function(message) {
};
(async () => {
resizePopup();
await initColorTheme();
$('#connect-button').addEventListener('click', async () => {

View file

@ -4,9 +4,6 @@ const $ = function(elem) {
return document.querySelector(elem);
};
const DEFAULT_POPUP_SIZE = '460px';
const PINNED_POPUP_SIZE = '380px';
function updateAvailableResponse(available) {
if (available) {
$('#update-available').show();
@ -58,22 +55,6 @@ async function getLoginData() {
return logins;
}
// Sets default popup size for Chromium based browsers to prevent flash on popup open
function setDefaultPopupSize() {
if (!isFirefox()) {
document.body.style.width = DEFAULT_POPUP_SIZE;
}
}
// Resizes the popup to the default size if the width is too small
function resizePopup() {
if (document.body.offsetWidth > 0 && document.body.offsetWidth < 100) {
document.body.style.width = isFirefox() ? PINNED_POPUP_SIZE : DEFAULT_POPUP_SIZE;
} else {
document.body.style.width = DEFAULT_POPUP_SIZE;
}
}
(async () => {
if (document.readyState === 'complete' || (document.readyState !== 'loading' && !document.documentElement.doScroll)) {
await initSettings();

View file

@ -15,9 +15,6 @@
<script defer src="../common/translate.js"></script>
</head>
<body>
<script>
setDefaultPopupSize();
</script>
<div class="container">
<div id="settings" class="settings">
<div class="function-buttons-area">

View file

@ -1,7 +1,6 @@
'use strict';
(async () => {
resizePopup();
await initColorTheme();
$('#lock-database-button').show();

View file

@ -15,9 +15,6 @@
<script defer src="../common/translate.js"></script>
</head>
<body>
<script>
setDefaultPopupSize();
</script>
<div class="container">
<div id="settings" class="settings">
<div class="function-buttons-area">

View file

@ -1,7 +1,6 @@
'use strict';
(async () => {
resizePopup();
await initColorTheme();
$('#lock-database-button').show();