Merge pull request #1667 from mozilla/more-bugfixes

Made selector for keyboard shortcuts more specific to fix #1666
This commit is contained in:
luke crouch 2020-02-28 10:39:28 -06:00 committed by GitHub
commit ae1f80b8b5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 4 deletions

View file

@ -2,7 +2,7 @@
"name": "testpilot-containers",
"title": "Multi-Account Containers",
"description": "Containers helps you keep all the parts of your online life contained in different tabs. Custom labels and color-coded tabs help keep different activities — like online shopping, travel planning, or checking work email — separate.",
"version": "6.2.2",
"version": "6.2.3",
"author": "Andrea Marchesini, Luke Crouch and Jonathan Kingston",
"bugs": {
"url": "https://github.com/mozilla/multi-account-containers/issues"

View file

@ -611,7 +611,7 @@ Logic.registerPanel(P_CONTAINERS_LIST, {
});
document.addEventListener("keydown", (e) => {
const selectables = [...document.querySelectorAll("[tabindex='0'], [tabindex='-1']")];
const selectables = [...document.querySelectorAll(".open-newtab[tabindex='0']")];
const element = document.activeElement;
const index = selectables.indexOf(element) || 0;
function next() {
@ -652,7 +652,7 @@ Logic.registerPanel(P_CONTAINERS_LIST, {
default:
if ((e.keyCode >= 49 && e.keyCode <= 57) &&
Logic._currentPanel === "containersList") {
const element = selectables[e.keyCode - 48];
const element = selectables[e.keyCode - 49];
if (element) {
element.click();
}

View file

@ -1,7 +1,7 @@
{
"manifest_version": 2,
"name": "Firefox Multi-Account Containers",
"version": "6.2.2",
"version": "6.2.3",
"incognito": "not_allowed",
"description": "Multi-Account Containers helps you keep all the parts of your online life contained in different tabs. Custom labels and color-coded tabs help keep different activities — like online shopping, travel planning, or checking work email — separate.",
"icons": {