diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 09b7e86..49657ab 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -2,7 +2,7 @@ Everyone is welcome to contribute to containers. Reach out to team members if you have questions: -- IRC: #containers on irc.mozilla.org +- Matrix chat: [#containers:mozilla.org](https://matrix.to/#/#containers:mozilla.org) - Email: containers@mozilla.com ## Filing bugs diff --git a/data/filters.svg b/data/filters.svg deleted file mode 100644 index 6119d59..0000000 --- a/data/filters.svg +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - diff --git a/data/usercontext.css b/data/usercontext.css deleted file mode 100644 index 0f36d19..0000000 --- a/data/usercontext.css +++ /dev/null @@ -1,143 +0,0 @@ -#userContext-indicator { - height: 16px; - list-style-image: none !important; - vertical-align: middle; - width: 16px; -} - -#userContext-label { - color: var(--identity-tab-color) !important; - margin-inline-end: 5px; - max-inline-size: 75px; - text-overflow: ellipsis; - white-space: nowrap; -} - -#userContext-icons { - -moz-box-align: center; - align-items: center; - display: flex; - max-inline-size: 120px; -} - -#userContext-icons[data-identity-color=""] { - display: none; -} - -/* containers experiment */ - -/* reset nightly containers */ -.tabbrowser-tab[usercontextid] { - background-image: none !important; - background-repeat: no-repeat; - background-size: 0; -} - -/* special styles run through a psuedo-class off of -these elements so they need to be relatively positioned. -these styles address both regular and compact themes, -special cases are addressed below */ -.tabbrowser-tab[usercontextid] .tab-background-middle, -#main-window[style*='compact'] .tabbrowser-tab[usercontextid] .tab-content, -#verticaltabs-box .tabbrowser-tab[usercontextid] .tab-content { - position: relative; -} - -.tabbrowser-tab[usercontextid] .tab-background-middle::after, -#main-window[style*='compact'] .tabbrowser-tab[usercontextid] .tab-content::after { - background-color: var(--identity-tab-color); - bottom: 0; - content: ''; - height: 2px; - left: 0; - position: absolute; - right: 0; - width: 100%; - z-index: 999; -} - -.tabbrowser-tab[usercontextid] .tab-background-middle::after { - background-color: var(--identity-tab-color); - border-radius: 2px 2px 0 0; - bottom: 1px; - height: 3px; -} - -.tabbrowser-tab[usercontextid]:not([visuallyselected="true"]) .tab-background-middle::after { - bottom: 2px; - height: 2px !important; -} - -.tabbrowser-tab[usercontextid][pinned="true"] .tab-background-middle::after { - left: -150%; - width: 400%; -} - -.tabs-newtab-button .toolbarbutton-icon[type="menu"] { - margin-inline-end: 0; -} - -.tabs-newtab-button .toolbarbutton-menu-dropmarker { - display: none; -} - -#new-tab-overlay { - --icon-size: 16px; - -moz-appearance: none; - background: transparent; - font-style: -moz-use-system-font; - inline-size: 180px; - margin-inline-start: -50px !important; - visibility: visible; -} - -#new-tab-overlay .panel-arrowcontent { - -moz-appearance: none !important; - background: none; - border: 0; - box-shadow: none; - display: block; - margin-block-end: 0; - margin-block-start: 2px; - padding-block-start: 0 !important; -} - -#new-tab-overlay .panel-arrowcontent, -#new-tab-overlay menuitem { - inline-size: 100%; -} - -#new-tab-overlay .panel-arrowbox { - display: none; -} - -#new-tab-overlay[hidden=true] { - display: none; -} - -#new-tab-overlay menuitem { - -moz-appearance: none; - background: white; - border-radius: 20px; - border: 0; - box-shadow: 0 0 7px #0004; - color: #4b4b4b; - margin-block-end: 5px; - padding-block-end: 10px; - padding-block-start: 10px; - padding-inline-end: 10px; - padding-inline-start: 10px; -} - -#new-tab-overlay menuitem:hover { - background: #f2f2f2; -} - -#new-tab-overlay .menuitem-iconic[data-usercontextid] > .menu-iconic-left > .menu-iconic-icon { - block-size: var(--icon-size); - inline-size: var(--icon-size); -} - -.menuitem-iconic[data-usercontextid] > .menu-iconic-left { - visibility: visible; -} diff --git a/data/usercontext.svg b/data/usercontext.svg deleted file mode 100644 index f58067a..0000000 --- a/data/usercontext.svg +++ /dev/null @@ -1,72 +0,0 @@ - - - - - - - - - - - - - - - - - diff --git a/package.json b/package.json index 26d2e1a..9e767a4 100644 --- a/package.json +++ b/package.json @@ -16,7 +16,7 @@ "eslint-plugin-no-unsanitized": "^2.0.0", "eslint-plugin-promise": "^3.4.0", "htmllint-cli": "0.0.7", - "json": "^9.0.6", + "json": ">=10.0.0", "mocha": "^6.2.2", "npm-run-all": "^4.0.0", "nyc": "^15.0.0", diff --git a/src/js/background/assignManager.js b/src/js/background/assignManager.js index c34f793..7593ef7 100644 --- a/src/js/background/assignManager.js +++ b/src/js/background/assignManager.js @@ -89,13 +89,13 @@ window.assignManager = { return; }, - async remove(pageUrlorUrlKey) { + async remove(pageUrlorUrlKey, shouldSync = true) { const siteStoreKey = this.getSiteStoreKey(pageUrlorUrlKey); // When we remove an assignment we should clear all the exemptions this.removeExempted(pageUrlorUrlKey); await this.area.remove([siteStoreKey]); const syncEnabled = await this.getSyncEnabled(); - if (syncEnabled) await sync.storageArea.backup({siteStoreKey}); + if (shouldSync && syncEnabled) await sync.storageArea.backup({siteStoreKey}); return; }, diff --git a/src/js/background/sync.js b/src/js/background/sync.js index b34ea00..6dfb629 100644 --- a/src/js/background/sync.js +++ b/src/js/background/sync.js @@ -493,9 +493,9 @@ async function reconcileSiteAssignments() { await sync.storageArea.getDeletedSiteList(); for(const siteStoreKey of deletedSiteList) { if (Object.prototype.hasOwnProperty.call(assignedSitesLocal,siteStoreKey)) { - assignManager + await assignManager .storageArea - .remove(siteStoreKey); + .remove(siteStoreKey, false); } }