Update eslint rules, add .prettierignore file, fix some formatting, and fix some bugs (#1756)

Update eslint rules, add .prettierignore file, fix some formatting, and fix some bugs
This commit is contained in:
Stefan Sundin 2022-11-16 03:11:13 -08:00 committed by GitHub
parent 2ea0fe2b97
commit f62c1d6a1f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
57 changed files with 402 additions and 381 deletions

View file

@ -1,5 +1,6 @@
{
"extends": ["eslint-config-airbnb-base" ],
"ignorePatterns": ["**/*.min.js"],
"env": {
"browser": true,
"es6": true,
@ -7,7 +8,7 @@
"webextensions": true
},
"parserOptions": {
"ecmaVersion": 2017
"ecmaVersion": 2020
},
"rules": {
"array-bracket-spacing": ["error", "always"],
@ -24,7 +25,9 @@
"dot-notation": "off",
"eqeqeq": "error",
"func-names": "off",
"function-paren-newline": "off",
"guard-for-in": "off",
"implicit-arrow-linebreak": "off",
"indent": ["error", 4],
"linebreak-style": ["error", "unix"],
"lines-around-comment": "off",
@ -35,9 +38,10 @@
"no-console": "off",
"no-continue": "off",
"no-control-regex": "off",
"no-global-assign": "off",
"no-else-return": "off",
"no-empty-function": ["error", { "allow": ["arrowFunctions", "methods", "asyncMethods"] }],
"no-extend-native": "off",
"no-global-assign": "off",
"no-lonely-if": "off",
"no-loop-func": "off",
"no-mixed-operators": "off",
@ -50,20 +54,20 @@
"no-restricted-syntax": "off",
"no-return-await": "off",
"no-tabs": "warn",
"no-underscore-dangle": "off",
"no-unused-vars": ["warn", { "args": "none", "varsIgnorePattern": "[A-Z_]+|tr|[$]" }],
"no-use-before-define": "off",
"no-useless-escape": "off",
"no-useless-return": "off",
"no-var": "off",
"no-underscore-dangle": "off",
"no-unused-vars": "warn",
"object-curly-spacing": ["warn", "always"],
"object-shorthand": "off",
"operator-linebreak": ["error", "before"],
"quote-props": "off",
"quotes": ["error", "single"],
"operator-linebreak": "off",
"prefer-arrow-callback": "off",
"prefer-destructuring": "off",
"prefer-template": "off",
"quote-props": "off",
"quotes": ["error", "single", { "avoidEscape": true }],
"semi": ["error", "always"],
"space-before-blocks": "warn",
"space-before-function-paren": "off",
@ -77,33 +81,49 @@
"_called": true,
"_f": true,
"acceptedOTPFields": true,
"assertInputFields": true,
"assertPasswordChangeFields": true,
"assertRegex": true,
"assertSearchField": true,
"assertSearchForm": true,
"assertTOTPField": true,
"AssociatedAction": true,
"Autocomplete": true,
"bootstrap": true,
"browser": true,
"browserAction": true,
"CHECK_UPDATE_NEVER": true,
"CHECK_UPDATE_ONE_MONTH": true,
"CHECK_UPDATE_ONE_WEEK": true,
"CHECK_UPDATE_THREE_DAYS": true,
"createResult": true,
"createStylesheet": true,
"DatabaseState": true,
"debugLogMessage": true,
"EXTENSION_NAME": true,
"getTopLevelDomainFromUrl": true,
"httpAuth": true,
"Icon": true,
"isEdge": true,
"isFirefox": true,
"IGNORE_AUTOSUBMIT": true,
"IGNORE_FULL": true,
"IGNORE_NORMAL": true,
"IGNORE_NOTHING": true,
"initColorTheme": true,
"isEdge": true,
"isFirefox": true,
"jQuery": true,
"keepass": true,
"keepassClient": true,
"kpxc": true,
"kpActions": true,
"kpErrors": true,
"kpxc": true,
"kpxcAssert": true,
"kpxcBanner": true,
"kpxcCustomLoginFieldsBanner": true,
"kpxcEvent": true,
"kpxcFields": true,
"kpxcFill": true,
"kpxcForm": true,
"kpxcEvent": true,
"kpxcIcons": true,
"kpxcObserverHelper": true,
"kpxcPasswordDialog": true,
@ -111,12 +131,17 @@
"kpxcSites": true,
"kpxcTOTPAutocomplete": true,
"kpxcTOTPIcons": true,
"kpxcUserAutocomplete": true,
"kpxcUsernameIcons": true,
"kpxcUI": true,
"kpxcUserAutocomplete": true,
"kpxcUsernameField": true,
"kpxcUsernameIcons": true,
"logDebug": true,
"logError": true,
"ManualFill": true,
"MAX_AUTOCOMPLETE_NAME_LEN": true,
"MAX_OPACITY": true,
"MAX_TOTP_INPUT_LENGTH": true,
"menuContexts": true,
"MIN_INPUT_FIELD_OFFSET_WIDTH": true,
"MIN_INPUT_FIELD_WIDTH_PX": true,
"MIN_OPACITY": true,
@ -124,13 +149,21 @@
"nacl": true,
"page": true,
"Pixels": true,
"PREDEFINED_SITELIST": true,
"resizePopup": true,
"sendMessage": true,
"showNotification": true,
"siteMatch": true,
"slashNeededForUrl": true,
"SORT_BY_GROUP_AND_TITLE": true,
"SORT_BY_GROUP_AND_USERNAME": true,
"SORT_BY_MATCHING_CREDENTIALS_SETTING": true,
"SORT_BY_RELEVANT_ENTRY": true,
"SORT_BY_TITLE": true,
"SORT_BY_USERNAME": true,
"statusResponse": true,
"Tests": true,
"tr": true,
"trimURL": true,
"PREDEFINED_SITELIST": true
"trimURL": true
}
}

6
.prettierignore Normal file
View file

@ -0,0 +1,6 @@
# This repository does not use prettier for formatting but if you want to use it for testing then you can comment out the following line:
*
# Should never format these files:
*.min.js
*.min.css

6
.prettierrc Normal file
View file

@ -0,0 +1,6 @@
{
"singleQuote": true,
"trailingComma": "all",
"arrowParens": "avoid",
"tabWidth": 4
}

View file

@ -32,8 +32,8 @@
"description": "Context menu parent item for filling a custom attribute."
},
"contextMenuRequestGlobalAutoType": {
"message": "",
"description": "Global Auto-Type shortcut text."
"message": "",
"description": "Global Auto-Type shortcut text."
},
"multipleCredentialsDetected": {
"message": "Открито е HTTP удостоверяване с множество идентификационни данни. Кликнете върху иконата на разширението, за да изберете правилните.",
@ -827,11 +827,11 @@
"message": "Комбинацията за $1 е променена успешно.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Комбинацията за $1 е нулирана.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Грешка: Комбинацията за $1 не е променена!",
"description": "Error message for changing keyboard shortcuts."
},
@ -891,11 +891,11 @@
"message": "Адрес на страница",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Игнориране",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Откриване само по потребителско име",
"description": "Site preferences list column title."
},

View file

@ -823,11 +823,11 @@
"message": "Klávesová zkratka $1 byla úspěšně změněna.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Klávesová zkratka pro $1 byla resetována.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Chyba: Klávesová zkratka pro $1 nebyla změněna!",
"description": "Error message for changing keyboard shortcuts."
},
@ -887,11 +887,11 @@
"message": "URL adresa stránky",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Ignorovat",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Zjišťování pouze uživatelského jména",
"description": "Site preferences list column title."
},

View file

@ -463,7 +463,7 @@
"message": " Abbrechen",
"description": "Cancel button text when removing database key or custom login fields."
},
"optionsButtonReset": {
"optionsButtonReset": {
"message": "Zurücksetzen",
"description": "Reset button text for keyboard shortcuts."
},
@ -639,11 +639,11 @@
"message": "Das Tastaturkürzel für $1 wurde geändert.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Das Tastaturkürzel für $1 wurde auf Standard zurückgesetzt.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Fehler: Tastaturkürzel für $1 wurde nicht geändert!",
"description": "Error message for changing keyboard shortcuts."
},
@ -691,11 +691,11 @@
"message": "Seiten-URL",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Ignorieren",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Reine Benutzernamenerkennung",
"description": "Site preferences list column title."
},

View file

@ -823,11 +823,11 @@
"message": "Η συντόμευση για $1 έχει αλλάξει με επιτυχία.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Έγινε επαναφορά της συντόμευσης για $1",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Σφάλμα: Η συντόμευση για το $1 δεν έχει αλλάξει!",
"description": "Error message for changing keyboard shortcuts."
},
@ -887,11 +887,11 @@
"message": "Διεύθυνση URL σελίδας",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Αγνοήστε",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Ανίχνευση μόνο-όνομα χρήστη",
"description": "Site preferences list column title."
},

View file

@ -32,8 +32,8 @@
"description": "Context menu parent item for filling a custom attribute."
},
"contextMenuRequestGlobalAutoType": {
"message": "Request Global Auto-Type",
"description": "Global Auto-Type shortcut text."
"message": "Request Global Auto-Type",
"description": "Global Auto-Type shortcut text."
},
"multipleCredentialsDetected": {
"message": "HTTP authentication with multiple credentials detected. Click on the extension icon to choose the correct one.",
@ -252,9 +252,9 @@
"description": "Help text when choosing custom login fields."
},
"defineChooseCustomLoginFieldText": {
"message": "Choose a Custom Login Field",
"description": "Help text for Custom Login Field banner."
},
"message": "Choose a Custom Login Field",
"description": "Help text for Custom Login Field banner."
},
"username": {
"message": "Username",
"description": "General text for username."
@ -264,8 +264,8 @@
"description": "General text for password."
},
"stringFields": {
"message": "String Fields",
"description": "General text for a String Fields."
"message": "String Fields",
"description": "General text for a String Fields."
},
"credentialsNoUsername": {
"message": "- no username -",
@ -364,16 +364,16 @@
"description": "Popup Getting Started Guide link text."
},
"popupAlertHide": {
"message": "Hide and don't show again.",
"description": "Hide alert close button title."
"message": "Hide and don't show again.",
"description": "Hide alert close button title."
},
"popupTroubleshootingText": {
"message": "Cannot connect to KeePassXC? Maybe our wiki page could help.",
"description": "Popup information message about Troubleshooting Guide."
"message": "Cannot connect to KeePassXC? Maybe our wiki page could help.",
"description": "Popup information message about Troubleshooting Guide."
},
"popupTroubleshootingLinkText": {
"message": "Troubleshooting Guide",
"description": "Popup Troubleshooting Guide link text."
"message": "Troubleshooting Guide",
"description": "Popup Troubleshooting Guide link text."
},
"popupCheckingStatus": {
"message": "Checking status...",
@ -879,11 +879,11 @@
"message": "Shortcut for $1 has been successfully changed.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Shortcut for $1 has been reset.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Error: Shortcut for $1 has not been changed!",
"description": "Error message for changing keyboard shortcuts."
},
@ -943,11 +943,11 @@
"message": "Page URL",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Ignore",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Username-only Detection",
"description": "Site preferences list column title."
},

View file

@ -823,11 +823,11 @@
"message": "El acceso directo para $1 ha sido cambiado con éxito.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Acceso directo para $1 se ha restablecido.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Error: Acceso directo para $1 no ha cambiado!",
"description": "Error message for changing keyboard shortcuts."
},
@ -887,11 +887,11 @@
"message": "URL de la página",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Ignorar",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Detección por nombre de usuario únicamente",
"description": "Site preferences list column title."
},

View file

@ -32,8 +32,8 @@
"description": "Context menu parent item for filling a custom attribute."
},
"contextMenuRequestGlobalAutoType": {
"message": "",
"description": "Global Auto-Type shortcut text."
"message": "",
"description": "Global Auto-Type shortcut text."
},
"multipleCredentialsDetected": {
"message": "",
@ -827,11 +827,11 @@
"message": "Otsetee $1 jaoks on edukalt muudetud.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Otsetee $1 jaoks on lähtestatud.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Tõrge: Otseteed $1 jaoks pole muudetud!",
"description": "Error message for changing keyboard shortcuts."
},
@ -891,11 +891,11 @@
"message": "Lehe URL",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Eiramine",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Ainult kasutajanime tuvastus",
"description": "Site preferences list column title."
},

View file

@ -463,7 +463,7 @@
"message": "Peruuta",
"description": "Cancel button text when removing database key or custom login fields."
},
"optionsButtonReset": {
"optionsButtonReset": {
"message": "Palauta oletus",
"description": "Reset button text for keyboard shortcuts."
},
@ -639,11 +639,11 @@
"message": "Näppäinoikotie toiminnolle $1 on muutettu.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Näppäinoikotie toiminnolle $1 on palautettu oletusasetukseen.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Virhe: Näppäinoikotietä toiminnolle $1 ei pystytty muuttamaan!",
"description": "Error message for changing keyboard shortcuts."
},
@ -691,11 +691,11 @@
"message": "Sivun URL",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Älä huomioi",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Pelkän käyttäjänimikentän tunnistus",
"description": "Site preferences list column title."
},

View file

@ -463,7 +463,7 @@
"message": " Annuler",
"description": "Cancel button text when removing database key or custom login fields."
},
"optionsButtonReset": {
"optionsButtonReset": {
"message": "Réinitialiser",
"description": "Reset button text for keyboard shortcuts."
},
@ -639,11 +639,11 @@
"message": "Le raccourci pour $1 à été modifié avec succès.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Le raccourci pour $1 à été réinitialisé.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Erreur : Le raccourci pour $1 n'a pas été modifié!",
"description": "Error message for changing keyboard shortcuts."
},
@ -691,11 +691,11 @@
"message": "URL de la page",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Ignorer",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Détection des noms d'utilisateurs uniquement",
"description": "Site preferences list column title."
},

View file

@ -32,8 +32,8 @@
"description": "Context menu parent item for filling a custom attribute."
},
"contextMenuRequestGlobalAutoType": {
"message": "בקשת הקלדה־אוטומטית כללית",
"description": "Global Auto-Type shortcut text."
"message": "בקשת הקלדה־אוטומטית כללית",
"description": "Global Auto-Type shortcut text."
},
"multipleCredentialsDetected": {
"message": "זוהה אימות HTTP עם אישורים מרובים. נא להקיש על סמל ההרחבה כדי לבחור את הסמל הנכון.",
@ -843,11 +843,11 @@
"message": "קיצור הדרך ל־$1 השתנה בהצלחה.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "קיצור הדרך ל־$1 אופס.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "שגיאה: קיצור הדרך ל־$1 לא השתנה!",
"description": "Error message for changing keyboard shortcuts."
},
@ -907,11 +907,11 @@
"message": "מען URL עמוד",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "להתעלם",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "זיהוי שמות משתמשים בלבד",
"description": "Site preferences list column title."
},

View file

@ -463,7 +463,7 @@
"message": "Mégse",
"description": "Cancel button text when removing database key or custom login fields."
},
"optionsButtonReset": {
"optionsButtonReset": {
"message": "Alapállapot",
"description": "Reset button text for keyboard shortcuts."
},
@ -639,11 +639,11 @@
"message": "A funkcióhoz tartozó gyorsbillentyű sikeresen megváltozott: $1.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "A funkcióhoz tartozó gyorsbillentyű alapállapotba lett hozva:$1.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Hiba: A funkcióhoz tartozó gyorsbillentyű nem változott: $1.",
"description": "Error message for changing keyboard shortcuts."
},
@ -691,11 +691,11 @@
"message": "Oldal URL",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Mellőzés",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Csak felhasználónév felismerés",
"description": "Site preferences list column title."
},

View file

@ -823,11 +823,11 @@
"message": "La scorciatoia per $1 è stata modificata con successo.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "La scorciatoia per $1 è stata reimpostata.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Errore: la scorciatoia per $1 non è stata modificata!",
"description": "Error message for changing keyboard shortcuts."
},
@ -887,11 +887,11 @@
"message": "URL della pagina",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Ignora",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Rilevamento solo del nome utente",
"description": "Site preferences list column title."
},

View file

@ -463,7 +463,7 @@
"message": "キャンセル",
"description": "Cancel button text when removing database key or custom login fields."
},
"optionsButtonReset": {
"optionsButtonReset": {
"message": "元に戻す",
"description": "Reset button text for keyboard shortcuts."
},
@ -639,11 +639,11 @@
"message": "ショートカット ($1) が正常に変更されました。",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "ショートカット ($1) がリセットされました。",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "エラー: ショートカット ($1) は変更されていません。",
"description": "Error message for changing keyboard shortcuts."
},
@ -691,11 +691,11 @@
"message": "ページの URL",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "無視",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "ユーザー名のみ検出",
"description": "Site preferences list column title."
},

View file

@ -463,7 +463,7 @@
"message": "취소",
"description": "Cancel button text when removing database key or custom login fields."
},
"optionsButtonReset": {
"optionsButtonReset": {
"message": "초기화",
"description": "Reset button text for keyboard shortcuts."
},
@ -639,11 +639,11 @@
"message": "$1의 단축키가 변경되었습니다.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "$1의 단축키를 초기화했습니다.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "오류: $1의 단축키가 변경되지 않았습니다!",
"description": "Error message for changing keyboard shortcuts."
},
@ -691,11 +691,11 @@
"message": "페이지 URL",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "무시",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "사용자 이름만 감지",
"description": "Site preferences list column title."
},

View file

@ -463,7 +463,7 @@
"message": "Cancella",
"description": "Cancel button text when removing database key or custom login fields."
},
"optionsButtonReset": {
"optionsButtonReset": {
"message": "Reimpone",
"description": "Reset button text for keyboard shortcuts."
},
@ -639,11 +639,11 @@
"message": "Excurtiatus pro $1 sine errore mutatus est.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Excurtiatus for $1 reimpositus est.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Error: Excurtiatus pro $1 mutatus non est!",
"description": "Error message for changing keyboard shortcuts."
},
@ -691,11 +691,11 @@
"message": "Paginae URL",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Praetere",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Detectio nominis usorii tantum",
"description": "Site preferences list column title."
},

View file

@ -32,8 +32,8 @@
"description": "Context menu parent item for filling a custom attribute."
},
"contextMenuRequestGlobalAutoType": {
"message": "ကမ္ဘာသုံး အလိုအလျောက်စာရိုက်ခြင်းကို တောင်းဆိုရန်",
"description": "Global Auto-Type shortcut text."
"message": "ကမ္ဘာသုံး အလိုအလျောက်စာရိုက်ခြင်းကို တောင်းဆိုရန်",
"description": "Global Auto-Type shortcut text."
},
"multipleCredentialsDetected": {
"message": "အထောက်အထားများစွာဖြင့် HTTP စစ်မှန်ကြောင်းအတည်ပြုခြင်းကို တွေ့ရှိထားသည်။ မှန်ကန်သော အထောက်အထားကိုရွေးရန် အဆက်အိုင်ကွန်ပေါ်တွင် နှိပ်ပါ။",
@ -827,11 +827,11 @@
"message": "$1 အတွက် ရှော့(တ်)ကတ်ကို အောင်မြင်စွာ ပြောင်းပြီးပါပြီ။",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "$1 အတွက် ရှော့(တ်)ကတ်ကို ပြန်လည် သတ်မှတ်ပြီးပါပြီ။",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "ပြဿနာ - $1 အတွက် ရှော့(တ်)ကတ်ကို မပြောင်းရသေးပါ။",
"description": "Error message for changing keyboard shortcuts."
},
@ -891,11 +891,11 @@
"message": "စာမျက်နှာ URL",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "လျစ်လျူရှုရန်",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "အသုံးပြုသူအမည် သီးသန့် ရှာတွေ့ခြင်း",
"description": "Site preferences list column title."
},

View file

@ -32,8 +32,8 @@
"description": "Context menu parent item for filling a custom attribute."
},
"contextMenuRequestGlobalAutoType": {
"message": "",
"description": "Global Auto-Type shortcut text."
"message": "",
"description": "Global Auto-Type shortcut text."
},
"multipleCredentialsDetected": {
"message": "HTTP-authenticatie met meerdere inloggegevens gedetecteerd. Klik op het extensiepictogram om de juiste te kiezen.",
@ -827,11 +827,11 @@
"message": "Sneltoets voor $1 is veranderd.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Sneltoets voor $1 is hersteld.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Fout: Sneltoets voor $1 is niet veranderd!",
"description": "Error message for changing keyboard shortcuts."
},
@ -891,11 +891,11 @@
"message": "Pagina-URL",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Negeren",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Alleen-gebruikersnaam-detectie",
"description": "Site preferences list column title."
},

View file

@ -463,7 +463,7 @@
"message": "Annuleren",
"description": "Cancel button text when removing database key or custom login fields."
},
"optionsButtonReset": {
"optionsButtonReset": {
"message": "Terugzetten",
"description": "Reset button text for keyboard shortcuts."
},
@ -639,11 +639,11 @@
"message": "Sneltoets voor $1 is veranderd.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Sneltoets voor $1 is hersteld.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Fout: Sneltoets voor $1 is niet veranderd!",
"description": "Error message for changing keyboard shortcuts."
},
@ -691,11 +691,11 @@
"message": "Pagina-URL",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Negeren",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Alleen gebruikersnamen detecteren",
"description": "Site preferences list column title."
},

View file

@ -823,11 +823,11 @@
"message": "Skrót do $1 został pomyślnie zmieniony.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Skrót dla $1 został zresetowany.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Błąd: Skrót dla $1 nie został zmieniony!",
"description": "Error message for changing keyboard shortcuts."
},
@ -887,11 +887,11 @@
"message": "Adres URL strony",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Ignorowanie",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Wykrywanie tylko nazwy użytkownika",
"description": "Site preferences list column title."
},

View file

@ -463,7 +463,7 @@
"message": " Cancelar",
"description": "Cancel button text when removing database key or custom login fields."
},
"optionsButtonReset": {
"optionsButtonReset": {
"message": "Repôr",
"description": "Reset button text for keyboard shortcuts."
},
@ -639,11 +639,11 @@
"message": "O atalho para $1foi mudado com successo",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "O atalho para $1foi reposto",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Erro: O atalho para $1não foi mudado!",
"description": "Error message for changing keyboard shortcuts."
},
@ -691,11 +691,11 @@
"message": "URL da página",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Ignorar",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Deteção apenas de nome de utilizador",
"description": "Site preferences list column title."
},

View file

@ -463,7 +463,7 @@
"message": "Cancelar",
"description": "Cancel button text when removing database key or custom login fields."
},
"optionsButtonReset": {
"optionsButtonReset": {
"message": "Restaurar",
"description": "Reset button text for keyboard shortcuts."
},
@ -639,11 +639,11 @@
"message": "Atalho para $1 foi alterado com sucesso.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Atalho para $1 foi restaurado.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Erro: Atalho para $1 não foi alterado!",
"description": "Error message for changing keyboard shortcuts."
},
@ -691,11 +691,11 @@
"message": "URL da página",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Ignorar",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Detecção apenas de nome de usuário",
"description": "Site preferences list column title."
},

View file

@ -823,11 +823,11 @@
"message": "O atalho para $1foi mudado com successo",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "O atalho para $1foi reposto",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Erro: O atalho para $1não foi mudado!",
"description": "Error message for changing keyboard shortcuts."
},
@ -887,11 +887,11 @@
"message": "URL da página",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Ignorar",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Deteção apenas de nome de utilizador",
"description": "Site preferences list column title."
},

View file

@ -32,8 +32,8 @@
"description": "Context menu parent item for filling a custom attribute."
},
"contextMenuRequestGlobalAutoType": {
"message": "",
"description": "Global Auto-Type shortcut text."
"message": "",
"description": "Global Auto-Type shortcut text."
},
"multipleCredentialsDetected": {
"message": "Autentificare HTTP cu mai multe acreditări detectate. Faceți clic pe pictograma de prelungire pentru a alege una corectă.",
@ -827,11 +827,11 @@
"message": "Comanda rapidă pentru $1 s-a modificat cu succes.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Comandă rapidă pentru $1 a fost resetat.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Eroare: shortcut pentru $1 nu a fost schimbat!",
"description": "Error message for changing keyboard shortcuts."
},
@ -891,11 +891,11 @@
"message": "URL pagină",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Ignora",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Detectarea numai a numelui de utilizator",
"description": "Site preferences list column title."
},

View file

@ -463,7 +463,7 @@
"message": "Отмена",
"description": "Cancel button text when removing database key or custom login fields."
},
"optionsButtonReset": {
"optionsButtonReset": {
"message": "Сброс",
"description": "Reset button text for keyboard shortcuts."
},
@ -639,11 +639,11 @@
"message": "Ярлык для $1 был успешно изменен.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Ярлык для $1 был сброшен.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Ошибка: Ярлык для $1 изменен не был!",
"description": "Error message for changing keyboard shortcuts."
},
@ -691,11 +691,11 @@
"message": "URL страницы",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Пропустить",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Определение только по логину",
"description": "Site preferences list column title."
},

View file

@ -32,8 +32,8 @@
"description": "Context menu parent item for filling a custom attribute."
},
"contextMenuRequestGlobalAutoType": {
"message": "",
"description": "Global Auto-Type shortcut text."
"message": "",
"description": "Global Auto-Type shortcut text."
},
"multipleCredentialsDetected": {
"message": "Zaznana je HTTP avtentikacija z več povernicami. Kliknite na ikono razširitve, da izberete želeno povernico.",
@ -827,11 +827,11 @@
"message": "Bližnjica za $1 je bila uspešno spremenjena.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Bližnjica za $1 je bila ponastavjena.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Napaka: Bližnjica za $1 ni bila spremenjena!",
"description": "Error message for changing keyboard shortcuts."
},
@ -891,11 +891,11 @@
"message": "URL spletna mesta",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Prezri",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Zaznavanje samo uporabniškega imena",
"description": "Site preferences list column title."
},

View file

@ -463,7 +463,7 @@
"message": "Avbryt",
"description": "Cancel button text when removing database key or custom login fields."
},
"optionsButtonReset": {
"optionsButtonReset": {
"message": "Återställ",
"description": "Reset button text for keyboard shortcuts."
},
@ -639,11 +639,11 @@
"message": "Genväg för $1 har ändrats framgångsrikt.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Genväg för $1 har återställts.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Fel: Genväg för $1 har inte ändrats!",
"description": "Error message for changing keyboard shortcuts."
},
@ -691,11 +691,11 @@
"message": "Sid-URL",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Ignorera",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Identifiera endast användarnamn",
"description": "Site preferences list column title."
},

View file

@ -32,8 +32,8 @@
"description": "Context menu parent item for filling a custom attribute."
},
"contextMenuRequestGlobalAutoType": {
"message": "Genel otomatik yazma isteği",
"description": "Global Auto-Type shortcut text."
"message": "Genel otomatik yazma isteği",
"description": "Global Auto-Type shortcut text."
},
"multipleCredentialsDetected": {
"message": "HTTP kimlik doğrulaması için kullanılabilecek birden çok kimlik doğrulama bilgisi bulundu. Doğru bilgileri seçmek için uzantı simgesine tıklayın.",
@ -843,11 +843,11 @@
"message": "$1 kısayolu değiştirildi.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "$1 kısayolu sıfırlandı.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Hata: $1 kısayolu değiştirilmedi!",
"description": "Error message for changing keyboard shortcuts."
},
@ -907,11 +907,11 @@
"message": "Sayfa adresi",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Yok say",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Yalnız kullanıcı adı algılaması",
"description": "Site preferences list column title."
},

View file

@ -463,7 +463,7 @@
"message": "Скасувати",
"description": "Cancel button text when removing database key or custom login fields."
},
"optionsButtonReset": {
"optionsButtonReset": {
"message": "Reset",
"description": "Reset button text for keyboard shortcuts."
},
@ -639,11 +639,11 @@
"message": "Shortcut for $1 has been successfully changed.",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "Shortcut for $1 has been reset.",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Error: Shortcut for $1 has not been changed!",
"description": "Error message for changing keyboard shortcuts."
},
@ -691,11 +691,11 @@
"message": "URL сторінки",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "Нехтувати",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Визначення виключно за іменем користувача",
"description": "Site preferences list column title."
},

View file

@ -823,11 +823,11 @@
"message": "$1 的快捷方式已成功更改。",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "$1 的快捷方式已重置。",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "错误: $1 的快捷方式未更改!",
"description": "Error message for changing keyboard shortcuts."
},
@ -887,11 +887,11 @@
"message": "页面网址",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "忽略",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "仅用户名检测",
"description": "Site preferences list column title."
},

View file

@ -463,7 +463,7 @@
"message": "取消",
"description": "Cancel button text when removing database key or custom login fields."
},
"optionsButtonReset": {
"optionsButtonReset": {
"message": "重設",
"description": "Reset button text for keyboard shortcuts."
},
@ -639,11 +639,11 @@
"message": "$1 的快速鍵已成功更改。",
"description": "Message for successful keyboard shortcut change."
},
"optionsShortcutsInfo": {
"optionsShortcutsInfo": {
"message": "$1 的快速鍵已重設。",
"description": "Info message for changing keyboard shortcuts."
},
"optionsShortcutsDanger": {
"optionsShortcutsDanger": {
"message": "Error: Shortcut for $1 has not been changed!",
"description": "Error message for changing keyboard shortcuts."
},
@ -691,11 +691,11 @@
"message": "網頁 URL",
"description": "Site preferences list column title."
},
"optionsColumnIgnore": {
"optionsColumnIgnore": {
"message": "忽略",
"description": "Site preferences list column title."
},
"optionsColumnUsernameOnly": {
"optionsColumnUsernameOnly": {
"message": "Username-only Detection",
"description": "Site preferences list column title."
},

View file

@ -555,7 +555,7 @@ keepass.createNewGroup = async function(tab, args = []) {
keepass.updateLastUsed(keepass.databaseHash);
return response;
} else {
logError(`getDatabaseGroups rejected`);
logError('getDatabaseGroups rejected');
}
browserAction.showDefault(tab);
@ -750,9 +750,7 @@ keepass.disableAutomaticReconnect = function() {
keepass.reconnect = async function(tab, connectionTimeout) {
keepassClient.connectToNative();
keepass.generateNewKeyPair();
const keyChangeResult = await keepass.changePublicKeys(tab, true, connectionTimeout).catch((e) => {
return false;
});
const keyChangeResult = await keepass.changePublicKeys(tab, true, connectionTimeout).catch(() => false);
// Change public keys timeout
if (!keyChangeResult) {
@ -802,7 +800,7 @@ keepass.setcurrentKeePassXCVersion = function(version) {
};
keepass.keePassXCUpdateAvailable = function() {
if (page.settings.checkUpdateKeePassXC && page.settings.checkUpdateKeePassXC != CHECK_UPDATE_NEVER) {
if (page.settings.checkUpdateKeePassXC && page.settings.checkUpdateKeePassXC !== CHECK_UPDATE_NEVER) {
const lastChecked = (keepass.latestKeePassXC.lastChecked) ? new Date(keepass.latestKeePassXC.lastChecked) : new Date(1986, 11, 21);
const daysSinceLastCheck = Math.floor(((new Date()).getTime() - lastChecked.getTime()) / 86400000);
if (daysSinceLastCheck >= page.settings.checkUpdateKeePassXC) {
@ -886,7 +884,7 @@ keepass.updateDatabaseHashToContent = async function() {
hash: { old: keepass.previousDatabaseHash, new: keepass.databaseHash },
connected: keepass.isKeePassXCAvailable
}).catch((err) => {
logError(`No content script available for this tab.`);
logError('No content script available for this tab.');
});
keepass.previousDatabaseHash = keepass.databaseHash;
}

View file

@ -404,7 +404,7 @@ page.updateContextMenu = async function(tab, credentials) {
}
};
const createContextMenuItem = function({action, args, ...options}) {
const createContextMenuItem = function({ action, args, ...options }) {
return browser.contextMenus.create({
contexts: menuContexts,
onclick: (info, tab) => {

View file

@ -77,8 +77,7 @@ const matchPatternToRegExp = function(pattern) {
pattern = pattern.replace(/\./g, '\\.');
if (pattern.endsWith('*')) {
regex += pattern.slice(0, -1);
}
else {
} else {
regex += `${pattern}$`;
}
return new RegExp(regex);

View file

@ -7,7 +7,7 @@ for (const item of items) {
let attr = '';
[ attr, key ] = trAttribute(key);
const placeholder = item.getAttribute('i18n-placeholder');
const placeholder = item.getAttribute('data-i18n-placeholder');
const translation = placeholder ? browser.i18n.getMessage(key, placeholder) : browser.i18n.getMessage(key);
if (attr) {
item.setAttribute(attr, translation);

View file

@ -153,7 +153,7 @@ class Autocomplete {
deselectItem() {
const items = this.list.querySelectorAll('div.kpxcAutocomplete-active');
items.forEach(item => item.classList.remove('kpxcAutocomplete-active'));
items.forEach(item => item.classList.remove('kpxcAutocomplete-active'));
}
closeList() {

View file

@ -188,7 +188,7 @@ kpxcBanner.saveNewCredentials = async function(credentials = {}) {
}
}
const addChildren = function(group, parentElement, depth) {
const addChildren = function(group, parentElement, depth = 0) {
++depth;
const padding = depth * 20;
@ -227,13 +227,12 @@ kpxcBanner.saveNewCredentials = async function(credentials = {}) {
kpxcBanner.createGroupDialog();
// Create the link list for group selection
let depth = 0;
for (const g of result.groups) {
const a = createLink(g.name, g.uuid, g.children.length > 0);
a.setAttribute('id', 'root');
kpxcBanner.shadowSelector('ul#list').appendChild(a);
addChildren(g, a, depth);
addChildren(g, a);
}
kpxcBanner.shadowSelector('.kpxc-banner-dialog').style.display = 'block';
@ -325,7 +324,7 @@ kpxcBanner.verifyResult = async function(code) {
// Traverse the groups and ensure all paths are found
kpxcBanner.getDefaultGroup = function(groups, defaultGroup) {
const getGroup = function(group, splitted, depth) {
const getGroup = function(group, splitted, depth = -1) {
++depth;
for (const g of group) {
if (g.name === splitted[depth]) {
@ -338,9 +337,8 @@ kpxcBanner.getDefaultGroup = function(groups, defaultGroup) {
return [ '', '' ];
};
let depth = -1;
const splitted = defaultGroup.split('/');
return getGroup(groups, splitted, depth);
return getGroup(groups, splitted);
};
kpxcBanner.createCredentialDialog = async function() {

View file

@ -669,7 +669,7 @@ const dataStepToString = function() {
} else if (kpxcCustomLoginFieldsBanner.dataStep === STEP_SELECT_STRING_FIELDS) {
return tr('defineStringField');
}
}
};
//--------------------------------------------------------------------------
// IFrame support
@ -764,4 +764,4 @@ const sendMessageToParent = function(message, selection) {
if (window.self !== window.top) {
window.top.postMessage({ message, selection }, '*');
}
}
};

View file

@ -104,13 +104,6 @@ kpxcFill.fillFromPopup = async function(id, uuid) {
return;
}
// For Google password field we need to do some special handling. The password field is actually in the
// second combination that was just detected after a username fill.
let combination = kpxc.combinations[0];
if (kpxcSites.popupExceptionFound(kpxc.combinations)) {
combination = kpxc.combinations[1];
}
const foundCombination = kpxcFields.getCombinationFromAllInputs();
kpxcFill.fillInCredentials(foundCombination, selectedCredentials.login, uuid);
kpxcUserAutocomplete.closeList();
@ -326,4 +319,4 @@ kpxcFill.performAutoSubmit = async function(combination, skipAutoSubmit) {
} else {
(combination.username || combination.password).focus();
}
}
};

View file

@ -69,7 +69,7 @@ kpxcForm.getFormSubmitButton = function(form) {
// Retrieve new password from a form with three elements: Current, New, Repeat New
kpxcForm.getNewPassword = function(passwordInputs = []) {
if (passwordInputs.length < 2) {
logDebug('Error: Not enough input fields to detect possible new password.')
logDebug('Error: Not enough input fields to detect possible new password.');
return '';
}

View file

@ -151,8 +151,7 @@ kpxcObserverHelper.getInputs = function(target, ignoreVisibility = false) {
}
// Traverse children, only if Improved Field Detection is enabled for the site
if (kpxc.improvedFieldDetectionEnabledForPage)
{
if (kpxc.improvedFieldDetectionEnabledForPage) {
const traversedChildren = kpxcObserverHelper.findInputsFromChildren(target);
for (const child of traversedChildren) {
if (!inputFields.includes(child)) {

View file

@ -43,8 +43,8 @@
"background/page.js",
"background/event.js",
"background/init.js"
]
},
]
},
"content_scripts": [
{
"matches": [
@ -154,13 +154,12 @@
"http://*/*",
"https://api.github.com/"
],
"content_security_policy": "script-src 'self' 'sha256-UD5WN2QEhRDEZ6vkLdHKFlkHwzbemzW2ppJiOLooI8o='; object-src 'none'",
"content_security_policy": "script-src 'self' 'sha256-4nJ8uLezzRE3SiBFdkVN/uNwV9YTOGCqRXg6AvB5rCY='; object-src 'none'",
"content_security_policy": "script-src 'self' 'sha256-UD5WN2QEhRDEZ6vkLdHKFlkHwzbemzW2ppJiOLooI8o=' 'sha256-4nJ8uLezzRE3SiBFdkVN/uNwV9YTOGCqRXg6AvB5rCY='; object-src 'none'",
"applications": {
"gecko": {
"id": "keepassxc-browser@keepassxc.org",
"strict_min_version": "67.0"
}
},
"default_locale": "en"
"gecko": {
"id": "keepassxc-browser@keepassxc.org",
"strict_min_version": "67.0"
}
},
"default_locale": "en"
}

View file

@ -129,6 +129,7 @@ table td:last-of-type {
.card {
background-color: var(--kpxc-card-background-color);
border-color: var(--kpxc-card-border-color);
overflow: hidden; /* fix border radius looking fuzzy */
}
.card-header {

View file

@ -4,10 +4,10 @@
<title data-i18n="optionsTitle"></title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<link rel="stylesheet" href="../css/colors.css" />
<link rel="stylesheet" href="../bootstrap/bootstrap.min.css" />
<link rel="stylesheet" href="../fonts/fork-awesome.min.css" />
<link rel="stylesheet" href="options.css" />
<link rel="stylesheet" href="../css/colors.css">
<link rel="stylesheet" href="../bootstrap/bootstrap.min.css">
<link rel="stylesheet" href="../fonts/fork-awesome.min.css">
<link rel="stylesheet" href="options.css">
<link rel="icon" type="image/png" href="../icons/keepassxc_32x32.png" sizes="32x32">
<link rel="icon" type="image/png" href="../icons/keepassxc_64x64.png" sizes="64x64">
<link rel="icon" type="image/png" href="../icons/keepassxc_96x96.png" sizes="96x96">
@ -100,7 +100,7 @@
<!-- Activate username icons -->
<div class="form-group">
<div class="form-check">
<input class="form-check-input" type="checkbox" name="showLoginFormIcon" id="usernameIconsCheckBox" value="true" />
<input class="form-check-input" type="checkbox" name="showLoginFormIcon" id="usernameIconsCheckBox" value="true">
<label class="form-check-label" for="usernameIconsCheckBox" data-i18n="optionsCheckboxUsernameIcons"></label>
<div id="passwordHelpBlock" class="form-text" data-i18n="optionsShowLoginFormIconHelpText"></div>
</div>
@ -109,7 +109,7 @@
<!-- Activate password icons -->
<div class="form-group">
<div class="form-check">
<input class="form-check-input" type="checkbox" name="usePasswordGeneratorIcons" id="passwordIconsCheckBox" value="true" />
<input class="form-check-input" type="checkbox" name="usePasswordGeneratorIcons" id="passwordIconsCheckBox" value="true">
<label class="form-check-label" for="passwordIconsCheckBox" data-i18n="optionsCheckboxUsePasswordGenerator"></label>
<div class="form-text" data-i18n="optionsUsePasswordGeneratorHelpText"></div>
<div class="form-text" data-i18n="optionsUsePasswordGeneratorHelpTextSecond"></div>
@ -119,7 +119,7 @@
<!-- Activate TOTP icons -->
<div class="form-group">
<div class="form-check">
<input class="form-check-input" type="checkbox" name="showOTPIcon" id="totpIconsCheckBox" value="true" />
<input class="form-check-input" type="checkbox" name="showOTPIcon" id="totpIconsCheckBox" value="true">
<label class="form-check-label" for="totpIconsCheckBox" data-i18n="optionsCheckboxOTPIcons"></label>
<div class="form-text" data-i18n="optionsShowOTPIconHelpText"></div>
</div>
@ -128,7 +128,7 @@
<!-- Show notifications -->
<div class="form-group">
<div class="form-check">
<input class="form-check-input" type="checkbox" name="showNotifications" id="notificationCheckBox" value="true" />
<input class="form-check-input" type="checkbox" name="showNotifications" id="notificationCheckBox" value="true">
<label class="form-check-label" for="notificationCheckBox" data-i18n="optionsCheckboxShowNotifications"></label>
<div class="form-text" data-i18n="optionsShowNotificationsHelpText"></div>
</div>
@ -144,9 +144,9 @@
</div>
<div class="card-body">
<p>
<span data-i18n="contextMenuFillUsernameAndPassword"></span>: <span id="fill_username_password-shortcut">error</span><br />
<span data-i18n="contextMenuFillPassword"></span>: <span id="fill_password-shortcut">error</span><br />
<span data-i18n="contextMenuFillTOTP"></span>: <span id="fill_totp-shortcut">error</span><br />
<span data-i18n="contextMenuFillUsernameAndPassword"></span>: <span id="fill_username_password-shortcut">error</span><br>
<span data-i18n="contextMenuFillPassword"></span>: <span id="fill_password-shortcut">error</span><br>
<span data-i18n="contextMenuFillTOTP"></span>: <span id="fill_totp-shortcut">error</span><br>
<span data-i18n="contextMenuShowPasswordGenerator"></span>: <span id="show_password_generator-shortcut">error</span>
</p>
<p>
@ -168,7 +168,7 @@
<!-- Automatically retrieve credentials -->
<div class="form-group">
<div class="form-check">
<input class="form-check-input" type="checkbox" name="autoRetrieveCredentials" id="autoRetrieveCredentials" value="true" />
<input class="form-check-input" type="checkbox" name="autoRetrieveCredentials" id="autoRetrieveCredentials" value="true">
<label class="form-check-label" for="autoRetrieveCredentials" data-i18n="optionsCheckboxAutoRetrieveCredentials"></label>
<div class="form-text" data-i18n="optionsAutoRetrieveCredentialsHelpText"></div>
</div>
@ -177,7 +177,7 @@
<!-- Use Autocomplete Menu -->
<div class="form-group">
<div class="form-check">
<input class="form-check-input" type="checkbox" name="autoCompleteUsernames" id="autoCompleteUsernames" value="true" />
<input class="form-check-input" type="checkbox" name="autoCompleteUsernames" id="autoCompleteUsernames" value="true">
<label class="form-check-label" for="autoCompleteUsernames" data-i18n="optionsCheckboxAutoCompleteUsernames"></label>
<div class="form-text" data-i18n="optionsAutocompleteUsernamesHelpText"></div>
</div>
@ -221,7 +221,7 @@
<!-- Use Auto-Submit -->
<div class="form-group py-2">
<div class="form-check">
<input class="form-check-input" type="checkbox" name="autoSubmit" id="autoSubmit" value="true" />
<input class="form-check-input" type="checkbox" name="autoSubmit" id="autoSubmit" value="true">
<label class="form-check-label" for="autoSubmit" data-i18n="optionsCheckboxAutoSubmit"></label>
<div class="form-text" data-i18n="optionsAutoSubmitHelpText"></div>
</div>
@ -230,7 +230,7 @@
<!-- Automatically fill single-credential entries -->
<div class="form-group">
<div class="form-check">
<input class="form-check-input" type="checkbox" name="autoFillSingleEntry" id="autoFillSingleEntry" value="true" />
<input class="form-check-input" type="checkbox" name="autoFillSingleEntry" id="autoFillSingleEntry" value="true">
<label class="form-check-label" for="autoFillSingleEntry" data-i18n="optionsCheckboxAutoFillSingleEntry"></label>
<div class="form-text" data-i18n="optionsAutoFillSingleEntryHelpText"></div>
<div class="alert alert-warning mt-3 col-lg-9" role="alert">
@ -309,8 +309,8 @@
<!-- Number of allowed redirects -->
<div class="form-group w-50">
<label id="redirectAllowanceLabel" class="font-weight-normal" for="redirectAllowance" data-i18n="optionsRedirectAllowance" i18n-placeholder="1"></label>
<input type="range" class="form-range" id="redirectAllowance" name="redirectAllowance" min="1" max="11" step="1" value="1" />
<label id="redirectAllowanceLabel" class="font-weight-normal" for="redirectAllowance" data-i18n="optionsRedirectAllowance" data-i18n-placeholder="1"></label>
<input type="range" class="form-range" id="redirectAllowance" name="redirectAllowance" min="1" max="11" step="1" value="1">
<div class="form-text help-text" data-i18n="optionsRedirectAllowanceHelpText"></div>
</div>
</div>
@ -324,16 +324,16 @@
</div>
<div class="card-body">
<div class="help-block kphVersion">
<p>
<p>
<span data-i18n="optionsVersionInfoText"></span>
<br />
<span data-i18n="optionsVersionDownload" i18n-placeholder="<a target='_blank' href='https://keepassxc.org/'>https://keepassxc.org/</a>"></span>
<br>
<span data-i18n="optionsVersionDownload" data-i18n-placeholder="<a target='_blank' href='https://keepassxc.org/'>https://keepassxc.org/</a>"></span>
</p>
<p>
<span data-i18n="optionsVersionRunning" i18n-placeholder="<em class='yourVersion'></em>"></span>
<span data-i18n="optionsVersionRunning" data-i18n-placeholder="<em class='yourVersion'></em>"></span>
</p>
<p>
<span data-i18n="optionsLatestVersion" i18n-placeholder="<em class='latestVersion'></em>"></span>
<span data-i18n="optionsLatestVersion" data-i18n-placeholder="<em class='latestVersion'></em>"></span>
</p>
<button class="btn btn-sm btn-success checkUpdateKeePassXC"><i class="fa fa-refresh" aria-hidden="true"></i><span data-i18n="optionsButtonUpdate"></span></button>
<div class="mt-3">
@ -370,7 +370,7 @@
<div class="card-body">
<div class="form-group">
<div class="form-check">
<input class="form-check-input" type="checkbox" name="useObserver" id="useObserver" value="true" />
<input class="form-check-input" type="checkbox" name="useObserver" id="useObserver" value="true">
<label class="form-check-label" for="useObserver" data-i18n="optionsUseObserver"></label>
<div class="form-text" data-i18n="optionsUseObserverHelpText"></div>
</div>
@ -379,12 +379,12 @@
<!-- Display group name -->
<div class="form-group">
<div class="form-check">
<input class="form-check-input" type="checkbox" name="showGroupNameInAutocomplete" id="showGroupNameInAutocomplete" value="true" />
<input class="form-check-input" type="checkbox" name="showGroupNameInAutocomplete" id="showGroupNameInAutocomplete" value="true">
<label class="form-check-label" for="showGroupNameInAutocomplete" data-i18n="optionsCheckboxShowGroupNameInAutocomplete"></label>
<div class="form-text" data-i18n="optionsShowGroupNameInAutocompleteHelpText"></div>
<div class="alert alert-info mt-3 col-lg-9" role="alert" id="versionRequiredAlert">
<i class="fa fa-exclamation-circle" aria-hidden="true"></i>
<span data-i18n="optionsKeePassXCVersionRequired" i18n-placeholder="2.6.0"></span>
<span data-i18n="optionsKeePassXCVersionRequired" data-i18n-placeholder="2.6.0"></span>
</div>
</div>
</div>
@ -392,7 +392,7 @@
<!-- Automatic reconnect -->
<div class="form-group" hidden>
<div class="form-check">
<input class="form-check-input" type="checkbox" name="autoReconnect" id="autoReconnect" value="true" />
<input class="form-check-input" type="checkbox" name="autoReconnect" id="autoReconnect" value="true">
<label class="form-check-label" for="autoReconnect" data-i18n="optionsCheckboxAutomaticReconnect"></label>
<div class="form-text" data-i18n="optionsAutomaticReconnectHelpText"></div>
<div class="alert alert-warning mt-3 col-lg-9" role="alert">
@ -405,7 +405,7 @@
<!-- Save domain only -->
<div class="form-group">
<div class="form-check">
<input class="form-check-input" type="checkbox" name="saveDomainOnly" id="saveDomainOnly" value="true" />
<input class="form-check-input" type="checkbox" name="saveDomainOnly" id="saveDomainOnly" value="true">
<label class="form-check-label" for="saveDomainOnly" data-i18n="optionsSaveDomainOnly"></label>
<div class="form-text" data-i18n="optionsSaveDomainOnlyCustomLoginHelpText"></div>
</div>
@ -414,7 +414,7 @@
<!-- Use predefined sites -->
<div class="form-group">
<div class="form-check">
<input class="form-check-input" type="checkbox" name="usePredefinedSites" id="usePredefinedSites" value="true" />
<input class="form-check-input" type="checkbox" name="usePredefinedSites" id="usePredefinedSites" value="true">
<label class="form-check-label" for="usePredefinedSites" data-i18n="optionsUsePredefinedSites"></label>
<div class="form-text" data-i18n="optionsUsePredefinedSitesHelpText"></div>
<details id="predefinedSiteList">
@ -437,7 +437,7 @@
<!-- Debug logging -->
<div class="form-group">
<div class="form-check">
<input class="form-check-input" type="checkbox" name="debugLogging" id="debugLogging" value="false" />
<input class="form-check-input" type="checkbox" name="debugLogging" id="debugLogging" value="false">
<label class="form-check-label" for="debugLogging" data-i18n="optionsDebugLogging"></label>
<div class="form-text" data-i18n="optionsDebugLoggingHelpText"></div>
</div>
@ -523,7 +523,7 @@
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
<p><span data-i18n="optionsDatabasesRemoveIdentifierConfirmFirst" i18n-placeholder="<strong></strong>"></span></p>
<p><span data-i18n="optionsDatabasesRemoveIdentifierConfirmFirst" data-i18n-placeholder="<strong></strong>"></span></p>
<p class="help-block" data-i18n="optionsDatabasesRemoveIdentifierConfirmSecond"></p>
</div>
<div class="modal-footer">
@ -545,7 +545,7 @@
<div class="card-body">
<p>
<span data-i18n="optionsCustomFieldsTabHelpTextFirst"></span>
<br />
<br>
<span data-i18n="optionsCustomFieldsTabHelpTextSecond"></span><em><span data-i18n="popupChooseCredentialsText"></span></em>.
</p>
<div class="table-responsive">
@ -577,7 +577,7 @@
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
<p><span data-i18n="optionsCustomFieldsConfirmation" i18n-placeholder="<strong></strong>"></span></p>
<p><span data-i18n="optionsCustomFieldsConfirmation" data-i18n-placeholder="<strong></strong>"></span></p>
<p class="help-block" data-i18n="optionsCustomFieldsConfirmationHelpText"></p>
</div>
<div class="modal-footer">
@ -597,14 +597,16 @@
<div class="card my-4 shadow">
<div class="card-body">
<p>
<span data-i18n="optionsSitePreferencesTabHelpTextFirst"></span>
<li><span data-i18n="optionsSitePreferencesTabHelpTextSecond"></span></li>
<li><span data-i18n="optionsSitePreferencesTabHelpTextThird"></span></li>
<li><span data-i18n="optionsSitePreferencesTabHelpTextFourth"></span></li>
<li><span data-i18n="optionsSitePreferencesImprovedInputFieldDetectionHelpText"></span></li>
</p>
<hr class="mt-0" />
<div>
<p data-i18n="optionsSitePreferencesTabHelpTextFirst"></p>
<ul>
<li><span data-i18n="optionsSitePreferencesTabHelpTextSecond"></span></li>
<li><span data-i18n="optionsSitePreferencesTabHelpTextThird"></span></li>
<li><span data-i18n="optionsSitePreferencesTabHelpTextFourth"></span></li>
<li><span data-i18n="optionsSitePreferencesImprovedInputFieldDetectionHelpText"></span></li>
</ul>
</div>
<hr class="mt-0">
<form class="was-validated">
<div class="form-group">
@ -659,7 +661,7 @@
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
<p><span data-i18n="optionsSitePreferencesConfirmation" i18n-placeholder="<strong></strong>"></span></p>
<p><span data-i18n="optionsSitePreferencesConfirmation" data-i18n-placeholder="<strong></strong>"></span></p>
<p class="help-block" data-i18n="optionsSitePreferencesConfirmationHelpText"></p>
</div>
<div class="modal-footer">
@ -699,14 +701,14 @@
<a target="_blank" href="https://github.com/keepassxreboot/keepassxc-browser" data-i18n="[title]openNewTab" tabindex="9">
<span data-i18n="optionsAboutGitHub"></span></a>
</p>
<hr class="mt-0" />
<hr class="mt-0">
<p>
<span data-i18n="optionsAboutExtensionVersion" i18n-placeholder="<em class='versionCIP'></em>"></span>
<span data-i18n="optionsAboutExtensionVersion" data-i18n-placeholder="<em class='versionCIP'></em>"></span>
</p>
<p>
<span data-i18n="optionsAboutKeePassXCVersion" i18n-placeholder="<em class='versionKPH'></em>"></span>
<span data-i18n="optionsAboutKeePassXCVersion" data-i18n-placeholder="<em class='versionKPH'></em>"></span>
</p>
<hr class="mt-0" />
<hr class="mt-0">
<p>
<span data-i18n="optionsAboutContributors"></span>:<br>
<a target="_blank" href="https://github.com/pfn/" data-i18n="[title]openNewTab" tabindex="10">Perry Nguyen</a>,
@ -737,7 +739,7 @@
<div class="card-body">
<p>
<a target="_blank" href="https://github.com/keepassxreboot/keepassxc-browser/issues/new" tabindex="14"><span data-i18n="optionsAboutCreateNewIssue"></span></a>
<br /><span data-i18n="optionsAboutDebugInfo"></span>:
<br><span data-i18n="optionsAboutDebugInfo"></span>:
</p>
<p id="versionInfo" class="float-left">KeePassXC - <span class="kpxcVersion"></span>
<br>KeePassXC-Browser - <span class="kpxcbrVersion"></span>

View file

@ -31,8 +31,6 @@ options.initMenu = function() {
sideBarLinks.forEach(function(elem) {
elem.addEventListener('click', function(e) {
e.preventDefault();
sideBarLinks.forEach(t => t.parentElement.classList.remove('active'));
elem.parentElement.classList.add('active');
tabs.forEach(t => t.hide());
@ -44,6 +42,10 @@ options.initMenu = function() {
});
$('div.tab').show();
if (window.location.hash !== '') {
document.querySelector(`a[href='${window.location.hash}']`)?.click();
}
};
options.saveSetting = async function(name) {
@ -232,7 +234,7 @@ options.initGeneralSettings = function() {
const dialogImportSettingsModal = new bootstrap.Modal($('#dialogImportSettings'),
{ keyboard: true, show: false, backdrop: true });
$('#importSettingsButton').addEventListener('click', function(e) {
$('#importSettingsButton').addEventListener('click', function() {
var link = document.createElement('input');
link.setAttribute('type', 'file');
link.onchange = function(e) {

View file

@ -3,10 +3,10 @@
<head>
<title data-i18n="popupTitle"></title>
<meta charset="UTF-8">
<link rel="stylesheet" href="../css/colors.css" />
<link rel="stylesheet" href="../bootstrap/bootstrap.min.css" />
<link rel="stylesheet" href="../fonts/fork-awesome.min.css" />
<link rel="stylesheet" href="shortcuts.css" />
<link rel="stylesheet" href="../css/colors.css">
<link rel="stylesheet" href="../bootstrap/bootstrap.min.css">
<link rel="stylesheet" href="../fonts/fork-awesome.min.css">
<link rel="stylesheet" href="shortcuts.css">
<link rel="icon" type="image/png" href="../icons/keepassxc_32x32.png" sizes="32x32">
<link rel="icon" type="image/png" href="../icons/keepassxc_64x64.png" sizes="64x64">
<link rel="icon" type="image/png" href="../icons/keepassxc_96x96.png" sizes="96x96">
@ -20,36 +20,36 @@
<div class="conf-container">
<div class="conf-title">
<div id="icon">
<img src="/icons/keepassxc_19x19.png" alt="logo" />
<img src="/icons/keepassxc_19x19.png" alt="logo">
</div>
<div id="title">
<h5 class="muted"><span data-i18n="optionsConfigureShortcuts"/></h5>
<h5 class="muted"><span data-i18n="optionsConfigureShortcuts"></span></h5>
</div>
</div>
<hr />
<hr>
<div class="conf-content">
<div class="conf-row">
<div><label for="fill_username_password" data-i18n="contextMenuFillUsernameAndPassword"></label></div>
<input type="text" id="fill_username_password"/>
<button class="btn btn-sm btn-primary" id="buttonSaveUserandPass" type="button"><i class="fa fa-save" aria-hidden="true"></i> <span data-i18n="optionsButtonSave"/></button>
<input type="text" id="fill_username_password">
<button class="btn btn-sm btn-primary" id="buttonSaveUserandPass" type="button"><i class="fa fa-save" aria-hidden="true"></i> <span data-i18n="optionsButtonSave"></span></button>
<button class="btn btn-sm btn-danger"><i class="fa fa-remove" aria-hidden="true"></i> <span data-i18n="optionsButtonReset"></span></button>
</div>
<div class="conf-row">
<div><label for="fill_password" data-i18n="contextMenuFillPassword"></label></div>
<input type="text" id="fill_password"/>
<button class="btn btn-sm btn-primary" id="buttonSavePass" type="button"><i class="fa fa-save" aria-hidden="true"></i> <span data-i18n="optionsButtonSave"/></button>
<input type="text" id="fill_password">
<button class="btn btn-sm btn-primary" id="buttonSavePass" type="button"><i class="fa fa-save" aria-hidden="true"></i> <span data-i18n="optionsButtonSave"></span></button>
<button class="btn btn-sm btn-danger"><i class="fa fa-remove" aria-hidden="true"></i> <span data-i18n="optionsButtonReset"></span></button>
</div>
<div class="conf-row">
<div><label for="fill_totp" data-i18n="contextMenuFillTOTP"></label></div>
<input type="text" id="fill_totp"/>
<button class="btn btn-sm btn-primary" id="buttonSaveTotp" type="button"><i class="fa fa-save" aria-hidden="true"></i> <span data-i18n="optionsButtonSave"/></button>
<input type="text" id="fill_totp">
<button class="btn btn-sm btn-primary" id="buttonSaveTotp" type="button"><i class="fa fa-save" aria-hidden="true"></i> <span data-i18n="optionsButtonSave"></span></button>
<button class="btn btn-sm btn-danger"><i class="fa fa-remove" aria-hidden="true"></i> <span data-i18n="optionsButtonReset"></span></button>
</div>
<div class="conf-row">
<div><label for="show_password_generator" data-i18n="contextMenuShowPasswordGenerator"></label></div>
<input type="text" id="show_password_generator"/>
<button class="btn btn-sm btn-primary" id="buttonSaveGenerator" type="button"><i class="fa fa-save" aria-hidden="true"></i> <span data-i18n="optionsButtonSave"/></button>
<input type="text" id="show_password_generator">
<button class="btn btn-sm btn-primary" id="buttonSaveGenerator" type="button"><i class="fa fa-save" aria-hidden="true"></i> <span data-i18n="optionsButtonSave"></span></button>
<button class="btn btn-sm btn-danger"><i class="fa fa-remove" aria-hidden="true"></i> <span data-i18n="optionsButtonReset"></span></button>
</div>
</div>

View file

@ -152,15 +152,15 @@ code {
}
#login-filter {
outline: none;
border-radius: 4px;
border: 1px solid #ccc;
margin-bottom: 5px;
padding: 2px 10px;
width: 100%;
outline: none;
border-radius: 4px;
border: 1px solid #ccc;
margin-bottom: 5px;
padding: 2px 10px;
width: 100%;
}
#right-align {
.right-align {
text-align: right;
}

View file

@ -3,10 +3,10 @@
<head>
<title data-i18n="popupTitle"></title>
<meta charset="UTF-8">
<link rel="stylesheet" href="../css/colors.css" />
<link rel="stylesheet" href="popup.css" />
<link rel="stylesheet" href="../bootstrap/bootstrap.min.css" />
<link rel="stylesheet" href="../fonts/fork-awesome.min.css" />
<link rel="stylesheet" href="../css/colors.css">
<link rel="stylesheet" href="popup.css">
<link rel="stylesheet" href="../bootstrap/bootstrap.min.css">
<link rel="stylesheet" href="../fonts/fork-awesome.min.css">
<script src="../common/browser-polyfill.min.js"></script>
<script src="../common/global.js"></script>
<script src="../bootstrap/bootstrap.min.js"></script>
@ -32,38 +32,32 @@
<div id="popup-alerts">
<div id="update-available" class="alert alert-warning">
<span data-i18n="popupUpdateAvailable"></span>
<br />
<br>
<a target="_blank" class="alert-link" href="https://keepassxc.org/download"><span data-i18n="popupDownloadNewVersion"></span></a>.
</div>
<div id="getting-started-guide" class="alert alert-info alert-dismissible">
<span data-i18n="popupGettingStartedText"></span>
<br />
<br>
<a target="_blank" class="alert-link" href="https://keepassxc.org/docs/KeePassXC_GettingStarted.html#_setup_browser_integration"><span data-i18n="popupGettingStartedLinkText"></span></a>
<button type="button" id="getting-started-alert-close-button" class="btn-close" data-bs-dismiss="alert" data-i18n="[title]popupAlertHide"></button>
</div>
<div id="troubleshooting-guide" class="alert alert-info alert-dismissible">
<span data-i18n="popupTroubleshootingText"></span>
<br />
<br>
<a target="_blank" class="alert-link" href="https://github.com/keepassxreboot/keepassxc-browser/wiki/Troubleshooting-guide"><span data-i18n="popupTroubleshootingLinkText"></span></a>
<button type="button" id="troubleshooting-guide-alert-close-button" class="btn-close" data-bs-dismiss="alert" data-i18n="[title]popupAlertHide"></button>
</div>
</div>
<div id="update-available" class="alert alert-warning">
<span data-i18n="popupUpdateAvailable"></span>
<br />
<a target="_blank" class="alert-link" href="https://keepassxc.org/download"><span data-i18n="popupDownloadNewVersion"></span></a>.
</div>
<div id="initial-state">
<p><div class="loader"></div> <span data-i18n="popupCheckingStatus"/></p>
<div class="loader"></div> <p data-i18n="popupCheckingStatus"></p>
</div>
<div id="not-configured" style="display: none">
<p data-i18n="popupNotConfigured"></p>
<div id="right-align">
<div class="right-align">
<button id="connect-button" class="btn btn-sm btn-primary"><i class="fa fa-link" aria-hidden="true"></i> <span data-i18n="popupConnectButton"></span></button>
</div>
</div>
@ -74,18 +68,18 @@
<code id="need-reconfigure-message"></code>
</p>
<p data-i18n="popupNeedReconfigureMessage"></p>
<div id="right-align">
<div class="right-align">
<button id="reconnect-button" class="btn btn-sm btn-primary"><i class="fa fa-refresh" aria-hidden="true"></i> <span data-i18n="popupReconnectButton"></span></button>
</div>
</div>
<div id="configured-not-associated" style="display: none">
<span data-i18n="popupConfiguredNotAssociated" i18n-placeholder="<span class='bg-warning' id='unassociated-identifier'></span>"></span>
<span data-i18n="popupConfiguredNotAssociated" data-i18n-placeholder="<span class='bg-warning' id='unassociated-identifier'></span>"></span>
</div>
<div id="configured-and-associated" style="display: none">
<p data-i18n="popupConfiguredAndAssociated" i18n-placeholder="<span class='bg-success' id='associated-identifier'></span>"></p>
<div id="right-align">
<p data-i18n="popupConfiguredAndAssociated" data-i18n-placeholder="<span class='bg-success' id='associated-identifier'></span>"></p>
<div class="right-align">
<button id="redetect-fields-button" class="btn btn-sm btn-primary"><i class="fa fa-list-alt" aria-hidden="true"></i> <span data-i18n="popupRedetectButton"></span></button>
</div>
</div>
@ -95,7 +89,7 @@
<p style="margin-left: 1em">
<code id="error-message"></code>
</p>
<div id="right-align">
<div class="right-align">
<button id="reload-status-button" class="btn btn-sm btn-primary"><i class="fa fa-refresh" aria-hidden="true"></i> <span data-i18n="popupReloadButton"></span></button>
</div>
</div>
@ -105,17 +99,17 @@
<p style="margin-left: 1em">
<code id="database-error-message"></code>
</p>
<div id="right-align">
<div class="right-align">
<button id="reopen-database-button" class="btn btn-sm btn-primary"><i class="fa fa-lock" aria-hidden="true"></i> <span data-i18n="popupReopenButton"></span></button>
</div>
</div>
<div id="username-field-detected" style="display: none">
<hr />
<hr>
<p data-i18n="popupUsernameFieldDetected"></p>
<div id="right-align">
<button id="username-only-button" class="btn btn-sm btn-primary"><i class="fa fa-plus" aria-hidden="true"></i> <span data-i18n="popupUsernameButton"></span></button>
</div>
<div class="right-align">
<button id="username-only-button" class="btn btn-sm btn-primary"><i class="fa fa-plus" aria-hidden="true"></i> <span data-i18n="popupUsernameButton"></span></button>
</div>
</div>
</div>
</body>

View file

@ -30,8 +30,7 @@ function statusResponse(r) {
if (r.showTroubleshootingGuideAlert && reloadCount >= 2) {
$('#troubleshooting-guide').show();
}
else {
} else {
$('#troubleshooting-guide').hide();
}
} else if (r.keePassXCAvailable && r.databaseClosed) {

View file

@ -3,10 +3,10 @@
<head>
<title data-i18n="popupTitle"></title>
<meta charset="UTF-8">
<link rel="stylesheet" href="../css/colors.css" />
<link rel="stylesheet" href="popup.css" />
<link rel="stylesheet" href="../bootstrap/bootstrap.min.css" />
<link rel="stylesheet" href="../fonts/fork-awesome.min.css" />
<link rel="stylesheet" href="../css/colors.css">
<link rel="stylesheet" href="popup.css">
<link rel="stylesheet" href="../bootstrap/bootstrap.min.css">
<link rel="stylesheet" href="../fonts/fork-awesome.min.css">
<script src="../common/browser-polyfill.min.js"></script>
<script src="../common/global.js"></script>
<script src="../bootstrap/bootstrap.min.js"></script>
@ -31,7 +31,7 @@
<div id="update-available" class="alert alert-warning">
<span data-i18n="popupUpdateAvailable"></span>
<br />
<br>
<a target="_blank" class="alert-link" href="https://keepassxc.org/download"><span data-i18n="popupDownloadNewVersion"></span></a>.
</div>
@ -44,7 +44,7 @@
</div>
<div id="database-not-opened" style="display: none">
<p data-i18n="popupErrorEncountered"/>
<p data-i18n="popupErrorEncountered"></p>
<p style="margin-left: 1em">
<code id="database-error-message"></code>
</p>

View file

@ -3,10 +3,10 @@
<head>
<title data-i18n="popupTitle"></title>
<meta charset="UTF-8">
<link rel="stylesheet" href="../css/colors.css" />
<link rel="stylesheet" href="popup.css" />
<link rel="stylesheet" href="../bootstrap/bootstrap.min.css" />
<link rel="stylesheet" href="../fonts/fork-awesome.min.css" />
<link rel="stylesheet" href="../css/colors.css">
<link rel="stylesheet" href="popup.css">
<link rel="stylesheet" href="../bootstrap/bootstrap.min.css">
<link rel="stylesheet" href="../fonts/fork-awesome.min.css">
<script src="../common/browser-polyfill.min.js"></script>
<script src="../common/global.js"></script>
<script src="../bootstrap/bootstrap.min.js"></script>
@ -31,7 +31,7 @@
<div id="update-available" class="alert alert-warning">
<span data-i18n="popupUpdateAvailable"></span>
<br />
<br>
<a target="_blank" class="alert-link" href="https://keepassxc.org/download"><span data-i18n="popupDownloadNewVersion"></span></a>.
</div>
@ -45,7 +45,7 @@
</div>
<div id="database-not-opened" style="display: none">
<p data-i18n="popupErrorEncountered"/>
<p data-i18n="popupErrorEncountered"></p>
<p style="margin-left: 1em">
<code id="database-error-message"></code>
</p>

View file

@ -20,38 +20,32 @@ function assertRegex(func, expected, card, testName) {
}
async function assertInputFields(localDiv, expectedFieldCount, actionElementId) {
return new Promise(async (resolve) => {
const div = document.getElementById(localDiv);
div.style.display = 'block';
const div = document.getElementById(localDiv);
div.style.display = 'block';
// An user interaction is required before testing
if (actionElementId) {
const actionElement = div.querySelector(actionElementId);
if (actionElement) {
actionElement.click();
}
// An user interaction is required before testing
if (actionElementId) {
const actionElement = div.querySelector(actionElementId);
if (actionElement) {
actionElement.click();
}
}
const inputs = kpxcObserverHelper.getInputs(div);
kpxcAssert(inputs.length, expectedFieldCount, Tests.INPUT_FIELDS, `getInputs() for ${localDiv} with ${expectedFieldCount} fields`);
const inputs = kpxcObserverHelper.getInputs(div);
kpxcAssert(inputs.length, expectedFieldCount, Tests.INPUT_FIELDS, `getInputs() for ${localDiv} with ${expectedFieldCount} fields`);
div.style.display = 'none';
resolve();
});
div.style.display = 'none';
}
async function assertPasswordChangeFields(localDiv, expectedNewPassword) {
return new Promise(async (resolve) => {
const div = document.getElementById(localDiv);
div.style.display = 'block';
const div = document.getElementById(localDiv);
div.style.display = 'block';
const inputs = kpxcObserverHelper.getInputs(div, true);
const newPassword = kpxcForm.getNewPassword(inputs);
kpxcAssert(newPassword, expectedNewPassword, Tests.PASSWORD_CHANGE, `New password matches for ${localDiv}`);
const inputs = kpxcObserverHelper.getInputs(div, true);
const newPassword = kpxcForm.getNewPassword(inputs);
kpxcAssert(newPassword, expectedNewPassword, Tests.PASSWORD_CHANGE, `New password matches for ${localDiv}`);
div.style.display = 'none';
resolve();
});
div.style.display = 'none';
}
async function assertTOTPField(classStr, properties, testName, expectedResult) {

View file

@ -1,4 +1,4 @@
const fs = require('@npmcli/fs')
const fs = require('@npmcli/fs');
const DEST = 'keepassxc-browser/tests';

View file

@ -1,4 +1,4 @@
const fs = require('@npmcli/fs')
const fs = require('@npmcli/fs');
const DEST = 'keepassxc-browser/tests';

View file

@ -4,10 +4,10 @@
<title data-i18n="popupTitle"></title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<link rel="stylesheet" href="../css/colors.css" />
<link rel="stylesheet" href="../bootstrap/bootstrap.min.css" />
<link rel="stylesheet" href="../fonts/fork-awesome.min.css" />
<link rel="stylesheet" href="../options/options.css" />
<link rel="stylesheet" href="../css/colors.css">
<link rel="stylesheet" href="../bootstrap/bootstrap.min.css">
<link rel="stylesheet" href="../fonts/fork-awesome.min.css">
<link rel="stylesheet" href="../options/options.css">
<link rel="icon" type="image/png" href="../icons/keepassxc_32x32.png" sizes="32x32">
<link rel="icon" type="image/png" href="../icons/keepassxc_64x64.png" sizes="64x64">
<link rel="icon" type="image/png" href="../icons/keepassxc_96x96.png" sizes="96x96">
@ -30,14 +30,12 @@
<script defer src="../content/username-field.js"></script>
<script defer src="assert.js"></script>
<script defer src="tests.js"></script>
<style>
.hiddenOne {
visibility: hidden;
}
</style>
</head>
<style>
.hiddenOne {
visibility: hidden;
}
</style>
<body class="pt-3 pb-5">
<div class="container-fluid">
<div class="row">
@ -151,46 +149,46 @@
</div>
<div id="passwordChange1" style="display: none;">
<br /><input type="password" name="Old password" value="oldPassword">
<br /><input type="password" name="New password" value="newPassword">
<br /><input type="password" name="Repeat password" value="newPassword">
<br><input type="password" name="Old password" value="oldPassword">
<br><input type="password" name="New password" value="newPassword">
<br><input type="password" name="Repeat password" value="newPassword">
</div>
<div id="passwordChange2" style="display: none;">
<br /><input type="password" name="New password" value="newPassword">
<br /><input type="password" name="Repeat password" value="newPassword">
<br /><input type="password" name="Old password" value="oldPassword">
<br><input type="password" name="New password" value="newPassword">
<br><input type="password" name="Repeat password" value="newPassword">
<br><input type="password" name="Old password" value="oldPassword">
</div>
<div id="passwordChange3" style="display: none;">
<form action="secondPage">
<br /><input type="password" name="Old password" value="oldPassword">
<br /><input type="password" name="New password" value="newPassword">
<br /><input type="password" name="Repeat password" value="newPassword">
<br /><input type="submit" value="Change password">
<br><input type="password" name="Old password" value="oldPassword">
<br><input type="password" name="New password" value="newPassword">
<br><input type="password" name="Repeat password" value="newPassword">
<br><input type="submit" value="Change password">
</form>
</div>
<div id="passwordChange4" style="display: none;">
<form action="secondPage">
<br /><input type="password" name="New password" value="newPassword">
<br /><input type="password" name="Repeat password" value="newPassword">
<br /><input type="password" name="Old password" value="oldPassword">
<br /><input type="submit" value="Change password">
<br><input type="password" name="New password" value="newPassword">
<br><input type="password" name="Repeat password" value="newPassword">
<br><input type="password" name="Old password" value="oldPassword">
<br><input type="submit" value="Change password">
</form>
</div>
<div id="passwordChange5" style="display: none;">
<form action="firstForm">
<br /><input type="password" name="Old password" value="oldPassword">
<br><input type="password" name="Old password" value="oldPassword">
</form>
<form action="secondForm">
<br /><input type="password" name="New password" value="newPassword">
<br><input type="password" name="New password" value="newPassword">
</form>
<form action="thirdForm">
<br /><input type="password" name="Repeat password" value="newPassword">
<br><input type="password" name="Repeat password" value="newPassword">
</form>
</div>
</main>