From 4bd412aa9b2160c699d0baea699752ab088169f9 Mon Sep 17 00:00:00 2001 From: Gitoffthelawn Date: Thu, 23 Jan 2020 02:02:12 -0800 Subject: [PATCH 01/16] Improve accessibility by adjusting AMO links Let's open this to everyone and not assume any specific language or country. AMO will automatically redirect to user's language and country. --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index e85c870..1ee8f84 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ The Firefox Multi-Account Containers extension lets you carve out a separate box for each of your online lives – no more opening a different browser just to check your work email! [Learn More Here](https://blog.mozilla.org/firefox/introducing-firefox-multi-account-containers/) -[Available on addons.mozilla.org](https://addons.mozilla.org/en-GB/firefox/addon/multi-account-containers/) +[Available on addons.mozilla.org](https://addons.mozilla.org/firefox/addon/multi-account-containers/) For more info, see: @@ -43,12 +43,12 @@ There is a timeout test that sometimes fails on certain machines, so make sure t #### Publish to AMO 1. `npm run-script build` -2. [Upload the `.zip` to AMO](https://addons.mozilla.org/en-US/developers/addon/multi-account-containers/versions/submit/) +2. [Upload the `.zip` to AMO](https://addons.mozilla.org/developers/addon/multi-account-containers/versions/submit/) #### Publish to GitHub Finally, we also publish the release to GitHub for those followers. -1. Download the signed `.xpi` from [the addon versions page](https://addons.mozilla.org/en-US/developers/addon/multi-account-containers/versions) +1. Download the signed `.xpi` from [the addon versions page](https://addons.mozilla.org/developers/addon/multi-account-containers/versions) 2. [Make the new release on GitHub](https://github.com/mozilla/multi-account-containers/releases/new) * Use the version number for "Tag version" and "Release title" From c03c3c118c1d55c4eea636a045cfe7dfa181c9ac Mon Sep 17 00:00:00 2001 From: Khansa Kiasatina Date: Sun, 8 Mar 2020 17:02:58 -0400 Subject: [PATCH 02/16] fix alignment --- src/css/confirm-page.css | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/css/confirm-page.css b/src/css/confirm-page.css index 113ffef..87c10f2 100644 --- a/src/css/confirm-page.css +++ b/src/css/confirm-page.css @@ -77,6 +77,10 @@ dfn { font-style: normal; } +#deny, #confirm { + flex-grow: 1; +} + .button-container > button { min-inline-size: 240px; } From 2ed9eaee8a71196fb2551ca35d58448e425d92d9 Mon Sep 17 00:00:00 2001 From: Khansa Kiasatina Date: Fri, 13 Mar 2020 17:25:09 -0400 Subject: [PATCH 03/16] fix lint --- src/css/confirm-page.css | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/css/confirm-page.css b/src/css/confirm-page.css index 87c10f2..9f86242 100644 --- a/src/css/confirm-page.css +++ b/src/css/confirm-page.css @@ -28,7 +28,7 @@ button .container-name, /* for a mid sized window we have enough for this but not our image */ .title { - background-image: url("chrome://global/skin/icons/info.svg"); + background-image: url('chrome://global/skin/icons/info.svg'); } } @@ -77,7 +77,8 @@ dfn { font-style: normal; } -#deny, #confirm { +#deny, +#confirm { flex-grow: 1; } From a1d01f8ff2f04d677a3423866a9df7d6f994f06b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andre=20Schr=C3=B6der?= Date: Wed, 23 Dec 2020 04:13:16 +0100 Subject: [PATCH 04/16] Fix development instructions in README web-ext will not work when following the instructions without having this diff applied: ``` $ ./node_modules/web-ext/bin/web-ext run -s src/ (node:41062) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency (Use `node --trace-warnings ...` to show where the warning was created) (node:41062) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'find' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'head' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'set' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'test' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'to' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency (node:41062) Warning: Accessing non-existent property 'which' of module exports inside circular dependency Applying config file: ./package.json Running web extension from /home/andre/Git/multi-account-containers/src Use --verbose or open Tools > Web Developer > Browser Console to see logging WebExtError: Temporary add-on installation is not supported in this version of Firefox (you need Firefox 49 or higher). For older Firefox versions, use --pre-install at FirefoxDesktopExtensionRunner._callee6$ (/home/andre/Git/multi-account-containers/node_modules/web-ext/dist/webpack:/src/extension-runners/firefox-desktop.js:273:19) at tryCatch (/home/andre/Git/multi-account-containers/node_modules/web-ext/node_modules/regenerator-runtime/runtime.js:62:40) at Generator.invoke [as _invoke] (/home/andre/Git/multi-account-containers/node_modules/web-ext/node_modules/regenerator-runtime/runtime.js:296:22) at Generator.prototype. [as throw] (/home/andre/Git/multi-account-containers/node_modules/web-ext/node_modules/regenerator-runtime/runtime.js:114:21) at step (/home/andre/Git/multi-account-containers/node_modules/web-ext/dist/webpack:/node_modules/babel-runtime/helpers/asyncToGenerator.js:17:1) at /home/andre/Git/multi-account-containers/node_modules/web-ext/dist/webpack:/node_modules/babel-runtime/helpers/asyncToGenerator.js:30:1 at processTicksAndRejections (node:internal/process/task_queues:93:5) ``` web-ext will work when following the instructions with having this diff applied: ``` $ web-ext run -s src/ Applying config file: ./package.json Running web extension from /home/andre/Git/multi-account-containers/src Use --verbose or open Tools > Web Developer > Browser Console to see logging Installed /home/andre/Git/multi-account-containers/src as a temporary add-on The extension will reload if any source file changes Press R to reload (and Ctrl-C to quit) ``` I copied the wording from https://github.com/mdn/webextensions-examples/blob/2184fee75afcde39328384b36adf9e52c5917949/README.md I guess the underlying problem is that the web-ext version specified in the package.json is very outdated. By installing the web-ext tool via the provided instructions it fixes the problem. Furthermore, the `webextensions-examples` repo doesn't specify web-ext in their package.json which means that installing web-ext via the provided instructions seems to be the preferred way. (So maybe web-ext should be removed from the package.json entirely?) Fixes #1926 --- README.md | 27 +++++++++++++++++++++------ 1 file changed, 21 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 47dce0c..67fef55 100644 --- a/README.md +++ b/README.md @@ -18,17 +18,32 @@ For more info, see: ## Development -1. `npm install` -2. `./node_modules/web-ext/bin/web-ext run -s src/` +To run this extension: + +1. Open Firefox and load the `about:debugging` page. Click + [Load Temporary Add-on](https://developer.mozilla.org/en-US/Add-ons/WebExtensions/Temporary_Installation_in_Firefox) + and select the `manifest.json` file within the folder of an example extension. + Here is a [video](https://www.youtube.com/watch?v=cer9EUKegG4) + that demonstrates how to do this. +2. Install the + [web-ext](https://developer.mozilla.org/en-US/Add-ons/WebExtensions/Getting_started_with_web-ext) + tool. At the command line, open the example extension's folder and type + `web-ext run -s src/`. This launches Firefox and installs the extension automatically. + This tool provides some additional development features, such as + [automatic reloading](https://developer.mozilla.org/en-US/Add-ons/WebExtensions/Getting_started_with_web-ext#Automatic_extension_reloading). ### Testing -`npm run test` -or +``` +# Install dependencies +npm install -`npm run lint` +# Run all tests +npm run test -for just the linter +# Only run the linter +npm run lint +``` There is a timeout test that sometimes fails on certain machines, so make sure to run the tests on your clone before you make any changes to see if you have this problem. From 649110ed454a9400b1d875cf4834ed4e4293bdf2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Schr=C3=B6der?= Date: Mon, 11 Jan 2021 20:09:11 +0100 Subject: [PATCH 05/16] fix concerns --- README.md | 51 +++++++++++++++++++++++++++++++-------------------- 1 file changed, 31 insertions(+), 20 deletions(-) diff --git a/README.md b/README.md index 67fef55..438ff2c 100644 --- a/README.md +++ b/README.md @@ -18,32 +18,43 @@ For more info, see: ## Development -To run this extension: +### Running Locally -1. Open Firefox and load the `about:debugging` page. Click - [Load Temporary Add-on](https://developer.mozilla.org/en-US/Add-ons/WebExtensions/Temporary_Installation_in_Firefox) - and select the `manifest.json` file within the folder of an example extension. - Here is a [video](https://www.youtube.com/watch?v=cer9EUKegG4) - that demonstrates how to do this. -2. Install the - [web-ext](https://developer.mozilla.org/en-US/Add-ons/WebExtensions/Getting_started_with_web-ext) - tool. At the command line, open the example extension's folder and type - `web-ext run -s src/`. This launches Firefox and installs the extension automatically. - This tool provides some additional development features, such as - [automatic reloading](https://developer.mozilla.org/en-US/Add-ons/WebExtensions/Getting_started_with_web-ext#Automatic_extension_reloading). +#### via WebExtensions API (web-ext) + +1. Install the [web-ext](https://developer.mozilla.org/en-US/Add-ons/WebExtensions/Getting_started_with_web-ext) tool. +2. Run `web-ext run -s src/`. This launches Firefox and installs the extension automatically. + +This tool provides some additional development features, such as [automatic reloading](https://developer.mozilla.org/en-US/Add-ons/WebExtensions/Getting_started_with_web-ext#Automatic_extension_reloading). + +#### via about:debugging in Firefox + +1. Open the `about:debugging` page in Firefox. +2. Click on `This FIrefox`. +3. Click on [Load Temporary Add-on](https://developer.mozilla.org/en-US/Add-ons/WebExtensions/Temporary_Installation_in_Firefox). +4. Select `src/manifest.json`. + +Here is a [video](https://www.youtube.com/watch?v=cer9EUKegG4) that demonstrates how to do this. ### Testing -``` -# Install dependencies -npm install +* Install dependencies: -# Run all tests -npm run test + ``` + npm install + ``` -# Only run the linter -npm run lint -``` +* Run all tests: + + ``` + npm run test + ``` + +* Only run the linter: + + ``` + npm run lint + ``` There is a timeout test that sometimes fails on certain machines, so make sure to run the tests on your clone before you make any changes to see if you have this problem. From 4d76c937fec9ab0a681c2fdd9ee9f82fde885426 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Schr=C3=B6der?= Date: Mon, 11 Jan 2021 20:11:06 +0100 Subject: [PATCH 06/16] fix typos --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 438ff2c..39b33c8 100644 --- a/README.md +++ b/README.md @@ -20,17 +20,17 @@ For more info, see: ### Running Locally -#### via WebExtensions API (web-ext) +#### Via WebExtensions API (web-ext) 1. Install the [web-ext](https://developer.mozilla.org/en-US/Add-ons/WebExtensions/Getting_started_with_web-ext) tool. 2. Run `web-ext run -s src/`. This launches Firefox and installs the extension automatically. This tool provides some additional development features, such as [automatic reloading](https://developer.mozilla.org/en-US/Add-ons/WebExtensions/Getting_started_with_web-ext#Automatic_extension_reloading). -#### via about:debugging in Firefox +#### Via about:debugging in Firefox 1. Open the `about:debugging` page in Firefox. -2. Click on `This FIrefox`. +2. Click on `This Firefox`. 3. Click on [Load Temporary Add-on](https://developer.mozilla.org/en-US/Add-ons/WebExtensions/Temporary_Installation_in_Firefox). 4. Select `src/manifest.json`. From 86edd8c8a29b4cc083692fbcbbb4be2b525d5ec6 Mon Sep 17 00:00:00 2001 From: Noah Callaway Date: Fri, 23 Apr 2021 00:10:37 -0700 Subject: [PATCH 07/16] Rename 'always open in' title --- src/js/popup.js | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/src/js/popup.js b/src/js/popup.js index 22a4b4c..98d2ef0 100644 --- a/src/js/popup.js +++ b/src/js/popup.js @@ -803,8 +803,8 @@ Logic.registerPanel(P_CONTAINER_INFO, { }); // Populating the panel: name and icon document.getElementById("container-info-title").textContent = identity.name; - - const alwaysOpen = document.querySelector("#always-open-in-info-panel"); + + const alwaysOpen = document.querySelector("#always-open-in-info-panel"); Utils.addEnterHandler(alwaysOpen, async () => { Utils.alwaysOpenInContainer(identity); window.close(); @@ -941,7 +941,7 @@ Logic.registerPanel(OPEN_NEW_CONTAINER_PICKER, { tr.setAttribute("tabindex", "0"); const td = document.createElement("td"); - td.innerHTML = Utils.escaped` + td.innerHTML = Utils.escaped`