Bug 1570631 - Part 4 migrate doorhanger to cfr; r=johannh
authorLiang-Heng Chen <xeonchen@gmail.com>
Wed, 11 Sep 2019 09:16:11 +0000
changeset 492661 94c10676584a38959649712aeb7a0dbe29b8febf
parent 492660 cb70d201930184fd06fe7ef44f71cdc7132191d7
child 492662 26009ef5fd47591cfa37b25cb7b01b739d564729
push id95056
push userxeonchen@gmail.com
push dateWed, 11 Sep 2019 12:15:45 +0000
treeherderautoland@26009ef5fd47 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjohannh
bugs1570631
milestone71.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1570631 - Part 4 migrate doorhanger to cfr; r=johannh Differential Revision: https://phabricator.services.mozilla.com/D43752
browser/app/profile/firefox.js
browser/base/content/browser-siteProtections.js
browser/base/content/popup-notifications.inc
browser/base/content/test/trackingUI/browser.ini
browser/base/content/test/trackingUI/browser_trackingUI_socialtracking_doorhanger.js
browser/locales/en-US/chrome/browser/browser.properties
browser/themes/shared/notification-icons.inc.css
--- a/browser/app/profile/firefox.js
+++ b/browser/app/profile/firefox.js
@@ -1927,29 +1927,16 @@ pref("identity.fxaccounts.service.monito
 
 // Check bundled omni JARs for corruption.
 #ifdef RELEASE_OR_BETA
   pref("corroborator.enabled", false);
 #else
   pref("corroborator.enabled", true);
 #endif
 
-// Show notification popup for social tracking protection.
-pref("privacy.socialtracking.notification.enabled", true);
-// minimum number of page loads until showing popup.
-pref("privacy.socialtracking.notification.session.pageload.min", 4);
-// timestamp of last popup was shown.
-pref("privacy.socialtracking.notification.lastShown", "0");
-// don't show popup again within 2 days (2 * 86400 * 1000 milliseconds)
-pref("privacy.socialtracking.notification.period.min", 172800000);
-// current number of popup shown in the profile.
-pref("privacy.socialtracking.notification.counter", 0);
-// maximum number of popup shown in the profile.
-pref("privacy.socialtracking.notification.max", 2);
-
 // Disable WebIDE and ConnectPage by default (Bug 1539451)
 pref("devtools.webide.enabled", false);
 pref("devtools.connectpage.enabled", false);
 
 // Toolbox preferences
 pref("devtools.toolbox.footer.height", 250);
 pref("devtools.toolbox.sidebar.width", 500);
 pref("devtools.toolbox.host", "bottom");
--- a/browser/base/content/browser-siteProtections.js
+++ b/browser/base/content/browser-siteProtections.js
@@ -940,23 +940,16 @@ var ThirdPartyCookies = {
     }
 
     return listItem;
   },
 };
 
 var SocialTracking = {
   PREF_ENABLED: "privacy.socialtracking.block_cookies.enabled",
-  PREF_NOTIFICATION_UI_ENABLED: "privacy.socialtracking.notification.enabled",
-  PREF_SESSION_PAGELOAD_MIN:
-    "privacy.socialtracking.notification.session.pageload.min",
-  PREF_LAST_SHOWN: "privacy.socialtracking.notification.lastShown",
-  PREF_PERIOD_MIN: "privacy.socialtracking.notification.period.min",
-  PREF_COUNTER: "privacy.socialtracking.notification.counter",
-  PREF_MAX: "privacy.socialtracking.notification.max",
 
   strings: {
     get subViewBlocked() {
       delete this.subViewBlocked;
       return (this.subViewBlocked = gNavigatorBundle.getString(
         "contentBlocking.fingerprintersView.blocked.label"
       ));
     },
@@ -971,64 +964,25 @@ var SocialTracking = {
     get subViewTitleNotBlocking() {
       delete this.subViewTitleNotBlocking;
       return (this.subViewTitleNotBlocking = gNavigatorBundle.getString(
         "protections.notBlocking.socialMediaTrackers.title"
       ));
     },
   },
 
-  sessionPageLoad: 0,
-
-  // points to the object of current showing popup, this is used to avoid
-  // another popup from showing when it's still visible.
-  currentPopup: null,
-
   init() {
     XPCOMUtils.defineLazyPreferenceGetter(
       this,
       "enabled",
       this.PREF_ENABLED,
       false,
       this.updateCategoryItem.bind(this)
     );
     this.updateCategoryItem();
-    XPCOMUtils.defineLazyPreferenceGetter(
-      this,
-      "uiEnabled",
-      this.PREF_NOTIFICATION_UI_ENABLED
-    );
-    XPCOMUtils.defineLazyPreferenceGetter(
-      this,
-      "sessionPageLoadMin",
-      this.PREF_SESSION_PAGELOAD_MIN
-    );
-    XPCOMUtils.defineLazyPreferenceGetter(
-      this,
-      "lastShownMillisec",
-      this.PREF_LAST_SHOWN,
-      null,
-      str => parseInt(str)
-    );
-    XPCOMUtils.defineLazyPreferenceGetter(
-      this,
-      "periodMinMillisec",
-      this.PREF_PERIOD_MIN
-    );
-
-    XPCOMUtils.defineLazyPreferenceGetter(
-      this,
-      "numNotifications",
-      this.PREF_COUNTER
-    );
-    XPCOMUtils.defineLazyPreferenceGetter(
-      this,
-      "maxNotifications",
-      this.PREF_MAX
-    );
   },
 
   updateCategoryItem() {
     this.categoryItem.classList.toggle("blocked", this.enabled);
   },
 
   isBlocking(state) {
     let cookieTrackerBlocked =
@@ -1122,116 +1076,16 @@ var SocialTracking = {
     let label = document.createXULElement("label");
     label.value = uri.host;
     label.className = "protections-popup-list-host-label";
     label.setAttribute("crop", "end");
     listItem.append(label);
 
     return listItem;
   },
-
-  onBlocked() {
-    let nowMillisec = Date.now();
-    // The heuristics to show the pop-up are:
-    //   0. a social media tracker is blocked
-    //   1. user didn't disable notification UI by:
-    //      - check "don't show again"
-    //      - press "See Protections" button
-    //   2. only after the 4th page load
-    //   3. at most 1 time every 2 days
-    //   4. at most 5 times per profile
-    //   5. no other popup is showing
-    if (
-      !this.uiEnabled ||
-      this.sessionPageLoad <= this.sessionPageLoadMin ||
-      nowMillisec - this.lastShownMillisec < this.periodMinMillisec ||
-      this.numNotifications >= this.maxNotifications ||
-      this.currentPopup
-    ) {
-      return;
-    }
-
-    Services.prefs.setCharPref(this.PREF_LAST_SHOWN, nowMillisec.toString());
-    Services.prefs.setIntPref(this.PREF_COUNTER, this.numNotifications + 1);
-
-    let browser = gBrowser.selectedBrowser;
-    let learnMoreURL =
-      Services.urlFormatter.formatURLPref("app.support.baseURL") +
-      "social-media-tracking-report";
-
-    let mainAction = {
-      label: gNavigatorBundle.getString(
-        "contentBlocking.socialblock.primaryButton.label"
-      ),
-      accessKey: gNavigatorBundle.getString(
-        "contentBlocking.socialblock.primaryButton.accesskey"
-      ),
-      callback: arg => {
-        let { event } = arg;
-
-        Services.prefs.setBoolPref(this.PREF_NOTIFICATION_UI_ENABLED, false);
-
-        gProtectionsHandler.showProtectionsPopup({ event });
-      },
-    };
-
-    let secondaryAction = {
-      label: gNavigatorBundle.getString(
-        "contentBlocking.socialblock.secondaryButton.label"
-      ),
-      accessKey: gNavigatorBundle.getString(
-        "contentBlocking.socialblock.secondaryButton.accessKey"
-      ),
-      callback: arg => {
-        Services.prefs.setBoolPref(this.PREF_NOTIFICATION_UI_ENABLED, false);
-      },
-    };
-
-    let brandBundle = document.getElementById("bundle_brand");
-    let brandShortName = brandBundle.getString("brandShortName");
-    let options = {
-      hideClose: true,
-      removeOnDismissal: true,
-      learnMoreURL,
-      name: gNavigatorBundle.getFormattedString(
-        "contentBlocking.socialblock.title",
-        [brandShortName]
-      ),
-
-      eventCallback: state => {
-        switch (state) {
-          case "showing":
-            let doc = browser.ownerDocument;
-            let message = doc.getElementById("socialblock-message");
-            message.textContent = gNavigatorBundle.getFormattedString(
-              "contentBlocking.socialblock.prompt",
-              [brandShortName]
-            );
-            break;
-          case "removed":
-            this.currentPopup = null;
-            break;
-        }
-      },
-    };
-
-    // Make gIdentityHandler._trackingProtectionIconContainer as anchor object.
-    let anchorId = "stp";
-    browser[anchorId + "popupnotificationanchor"] = gProtectionsHandler.iconBox;
-
-    this.currentPopup = PopupNotifications.show(
-      browser,
-      "socialblock",
-      "",
-      anchorId,
-      mainAction,
-      [secondaryAction],
-      options
-    );
-  },
 };
 
 /**
  * Utility object to handle manipulations of the protections indicators in the UI
  */
 var gProtectionsHandler = {
   PREF_ANIMATIONS_ENABLED: "toolkit.cosmeticAnimations.enabled",
   PREF_REPORT_BREAKAGE_URL: "browser.contentblocking.reportBreakage.url",
@@ -1365,26 +1219,16 @@ var gProtectionsHandler = {
     ));
   },
   get _trackingProtectionIconTooltipLabel() {
     delete this._trackingProtectionIconTooltipLabel;
     return (this._trackingProtectionIconTooltipLabel = document.getElementById(
       "tracking-protection-icon-tooltip-label"
     ));
   },
-  get _socialblockPopupNotification() {
-    delete this._socialblockPopupNotification;
-    return (this._socialblockPopupNotification = document.getElementById(
-      "socialblock-notification"
-    ));
-  },
-
-  get _socialTrackingSessionPageLoad() {
-    return SocialTracking.sessionPageLoad;
-  },
 
   get noTrackersDetectedDescription() {
     delete this.noTrackersDetectedDescription;
     return (this.noTrackersDetectedDescription = document.getElementById(
       "protections-popup-no-trackers-found-description"
     ));
   },
 
@@ -1656,20 +1500,16 @@ var gProtectionsHandler = {
     // during the initiation but new records come after that.
     await this.maybeUpdateEarliestRecordedDateTooltip();
 
     this._updatingFooter = false;
   },
 
   // This triggers from top level location changes.
   onLocationChange() {
-    if (["http", "https"].includes(gBrowser.currentURI.scheme)) {
-      SocialTracking.sessionPageLoad += 1;
-    }
-
     if (this._showToastAfterRefresh) {
       this._showToastAfterRefresh = false;
 
       // We only display the toast if we're still on the same page.
       if (
         this._previousURI == gBrowser.currentURI.spec &&
         this._previousOuterWindowID == gBrowser.selectedBrowser.outerWindowID
       ) {
@@ -1796,18 +1636,33 @@ var gProtectionsHandler = {
       );
       this._trackingProtectionIconTooltipLabel.textContent = noTrackerTooltipStr;
       gIdentityHandler._trackingProtectionIconContainer.setAttribute(
         "aria-label",
         noTrackerTooltipStr
       );
     }
 
-    if (SocialTracking.isBlocking(event)) {
-      SocialTracking.onBlocked();
+    if (
+      Cryptomining.isBlocking(event) ||
+      Fingerprinting.isBlocking(event) ||
+      SocialTracking.isBlocking(event)
+    ) {
+      let uri = gBrowser.currentURI;
+      let uriHost = uri.asciiHost ? uri.host : uri.spec;
+      Services.obs.notifyObservers(
+        {
+          wrappedJSObject: {
+            browser: gBrowser.selectedBrowser,
+            host: uriHost,
+            event,
+          },
+        },
+        "SiteProtection:ContentBlockingEvent"
+      );
     }
 
     // We report up to one instance of fingerprinting and cryptomining
     // blocking and/or allowing per page load.
     let fingerprintingBlocking =
       Fingerprinting.isBlocking(event) &&
       !Fingerprinting.isBlocking(previousState);
     let fingerprintingAllowing =
--- a/browser/base/content/popup-notifications.inc
+++ b/browser/base/content/popup-notifications.inc
@@ -127,14 +127,8 @@
           <xul:description class="storage-access-perm-text"><html:span
             id="storage-access-perm-label"/><html:a id="storage-access-perm-learnmore"
             onclick="openTrustedLinkIn(this.href, 'tab'); return false;"
             class="text-link popup-notification-learnmore-link"/><html:span
             id="storage-access-perm-endlabel"/></xul:description>
         </xul:vbox>
       </popupnotificationcontent>
     </popupnotification>
-
-    <popupnotification id="socialblock-notification" hidden="true">
-      <popupnotificationcontent id="socialblock-content" orient="vertical">
-        <description id="socialblock-message"></description>
-      </popupnotificationcontent>
-    </popupnotification>
--- a/browser/base/content/test/trackingUI/browser.ini
+++ b/browser/base/content/test/trackingUI/browser.ini
@@ -31,18 +31,16 @@ support-files =
 [browser_trackingUI_fingerprinters.js]
 [browser_trackingUI_open_preferences.js]
 [browser_trackingUI_pbmode_exceptions.js]
 skip-if = fission # Crashes: @ mozilla::dom::BrowserBridgeParent::RecvShow(mozilla::gfx::IntSizeTyped<mozilla::ScreenPixel> const&, bool const&, nsSizeMode const&)
 [browser_trackingUI_report_breakage.js]
 skip-if = fission || debug || asan # Bug 1546797
 [browser_trackingUI_socialtracking.js]
 skip-if = fission && debug # Crashes: @ mozilla::net::HttpChannelChild::DoOnStartRequest(nsIRequest*, nsISupports*)
-[browser_trackingUI_socialtracking_doorhanger.js]
-skip-if = fission && debug # Crashes: @ mozilla::net::HttpChannelChild::DoOnStartRequest(nsIRequest*, nsISupports*)
 [browser_trackingUI_shield_visibility.js]
 skip-if = fission && debug #Bug 1574939
 [browser_trackingUI_state.js]
 skip-if = serviceworker_e10s || (fission && debug) # see https://bugzilla.mozilla.org/show_bug.cgi?id=1511303#c1 #Bug 1574939
 [browser_trackingUI_state_reset.js]
 skip-if = fission && debug #Bug 1574939
 [browser_trackingUI_telemetry.js]
 skip-if = fission && debug #Bug 1574939
deleted file mode 100644
--- a/browser/base/content/test/trackingUI/browser_trackingUI_socialtracking_doorhanger.js
+++ /dev/null
@@ -1,232 +0,0 @@
-/* Any copyright is dedicated to the Public Domain.
- * http://creativecommons.org/publicdomain/zero/1.0/ */
-
-"use strict";
-
-requestLongerTimeout(2);
-
-const TRACKING_PAGE =
-  "http://example.org/browser/browser/base/content/test/trackingUI/trackingPage.html";
-
-add_task(async function setup() {
-  await SpecialPowers.pushPrefEnv({
-    set: [
-      ["privacy.trackingprotection.socialtracking.enabled", true],
-      ["privacy.trackingprotection.socialtracking.annotate.enabled", true],
-      [
-        "urlclassifier.features.socialtracking.blacklistHosts",
-        "socialtracking.example.com",
-      ],
-      [
-        "urlclassifier.features.socialtracking.annotate.blacklistHosts",
-        "socialtracking.example.com",
-      ],
-      ["privacy.trackingprotection.enabled", false],
-      ["privacy.trackingprotection.annotate_channels", false],
-      ["privacy.trackingprotection.cryptomining.enabled", false],
-      ["privacy.trackingprotection.cryptomining.annotate.enabled", false],
-      ["privacy.trackingprotection.fingerprinting.enabled", false],
-      ["privacy.trackingprotection.fingerprinting.annotate.enabled", false],
-    ],
-  });
-});
-
-async function testPopup(hasPopup, buttonToClick) {
-  let numPageLoaded = gProtectionsHandler._socialTrackingSessionPageLoad;
-  let numPopupShown = Services.prefs.getIntPref(
-    "privacy.socialtracking.notification.counter",
-    0
-  );
-
-  let promise = BrowserTestUtils.openNewForegroundTab({
-    url: TRACKING_PAGE,
-    gBrowser,
-  });
-  let [tab] = await Promise.all([promise, waitForContentBlockingEvent()]);
-
-  ok(
-    !gProtectionsHandler._protectionsPopup.hasAttribute("detected"),
-    "socialtrackings are not detected"
-  );
-  ok(
-    !BrowserTestUtils.is_visible(
-      gProtectionsHandler._socialblockPopupNotification
-    ),
-    "popup is not visible"
-  );
-
-  promise = waitForContentBlockingEvent();
-  let popup = document.getElementById("notification-popup");
-  let popupShown = hasPopup
-    ? BrowserTestUtils.waitForEvent(popup, "PanelUpdated")
-    : null;
-
-  await ContentTask.spawn(tab.linkedBrowser, {}, function() {
-    content.postMessage("socialtracking", "*");
-  });
-
-  await Promise.all([promise, popupShown]);
-
-  ok(
-    gProtectionsHandler._protectionsPopup.hasAttribute("detected"),
-    "trackers are detected"
-  );
-  is(
-    BrowserTestUtils.is_visible(
-      gProtectionsHandler._socialblockPopupNotification
-    ),
-    hasPopup,
-    hasPopup ? "popup is visible" : "popup is not visible"
-  );
-
-  is(
-    gProtectionsHandler._socialTrackingSessionPageLoad,
-    numPageLoaded + 1,
-    "page loaded once"
-  );
-
-  if (hasPopup) {
-    // click on the button of the popup notification
-    if (typeof buttonToClick === "string") {
-      is(
-        Services.prefs.getBoolPref(
-          "privacy.socialtracking.notification.enabled",
-          false
-        ),
-        true,
-        "notification still enabled"
-      );
-
-      let notification = PopupNotifications.panel.firstElementChild;
-      EventUtils.synthesizeMouseAtCenter(notification[buttonToClick], {});
-
-      is(
-        Services.prefs.getBoolPref(
-          "privacy.socialtracking.notification.enabled",
-          true
-        ),
-        false,
-        "notification disabled now"
-      );
-    }
-
-    let lastShown = Services.prefs.getCharPref(
-      "privacy.socialtracking.notification.lastShown",
-      "0"
-    );
-    ok(lastShown !== "0", "last shown timestamp updated");
-    is(
-      Services.prefs.getIntPref(
-        "privacy.socialtracking.notification.counter",
-        0
-      ),
-      numPopupShown + 1,
-      "notification counter increased"
-    );
-  }
-
-  BrowserTestUtils.removeTab(tab);
-}
-
-add_task(async function testSocialTrackingPopups() {
-  let configs = [
-    {
-      description: "always-on notification",
-      results: [true, true],
-      prefs: [
-        ["privacy.socialtracking.notification.enabled", true],
-        ["privacy.socialtracking.notification.session.pageload.min", -1],
-        ["privacy.socialtracking.notification.lastShown", "0"],
-        ["privacy.socialtracking.notification.period.min", 0],
-        ["privacy.socialtracking.notification.counter", 0],
-        ["privacy.socialtracking.notification.max", 999],
-      ],
-    },
-    {
-      description: "always-off notification",
-      results: [false, false],
-      prefs: [
-        ["privacy.socialtracking.notification.enabled", false],
-        ["privacy.socialtracking.notification.session.pageload.min", -1],
-        ["privacy.socialtracking.notification.lastShown", "0"],
-        ["privacy.socialtracking.notification.period.min", 0],
-        ["privacy.socialtracking.notification.counter", 0],
-        ["privacy.socialtracking.notification.max", 999],
-      ],
-    },
-
-    {
-      description: "set minimum page loaded limitation",
-      results: [false, false, true],
-      prefs: [
-        ["privacy.socialtracking.notification.enabled", true],
-        ["privacy.socialtracking.notification.session.pageload.min", 2],
-        ["privacy.socialtracking.notification.lastShown", "0"],
-        ["privacy.socialtracking.notification.period.min", 0],
-        ["privacy.socialtracking.notification.counter", 0],
-        ["privacy.socialtracking.notification.max", 999],
-      ],
-    },
-    {
-      description: "set minimum period between popups",
-      results: [true, false],
-      prefs: [
-        ["privacy.socialtracking.notification.enabled", true],
-        ["privacy.socialtracking.notification.session.pageload.min", -1],
-        ["privacy.socialtracking.notification.lastShown", "0"],
-        ["privacy.socialtracking.notification.period.min", 3600000], // 1H
-        ["privacy.socialtracking.notification.counter", 0],
-        ["privacy.socialtracking.notification.max", 999],
-      ],
-    },
-    {
-      description: "define maximum number of notifications",
-      results: [true, true, false],
-      prefs: [
-        ["privacy.socialtracking.notification.enabled", true],
-        ["privacy.socialtracking.notification.session.pageload.min", -1],
-        ["privacy.socialtracking.notification.lastShown", "0"],
-        ["privacy.socialtracking.notification.period.min", 0],
-        ["privacy.socialtracking.notification.counter", 3],
-        ["privacy.socialtracking.notification.max", 5],
-      ],
-    },
-    {
-      description: "disable notification by clicking primaryButton",
-      results: [true, false],
-      button: "button",
-      prefs: [
-        ["privacy.socialtracking.notification.enabled", true],
-        ["privacy.socialtracking.notification.session.pageload.min", -1],
-        ["privacy.socialtracking.notification.lastShown", "0"],
-        ["privacy.socialtracking.notification.period.min", 0],
-        ["privacy.socialtracking.notification.counter", 0],
-        ["privacy.socialtracking.notification.max", 999],
-      ],
-    },
-    {
-      description: "disable notification by clicking secondaryButton",
-      results: [true, false],
-      button: "secondaryButton",
-      prefs: [
-        ["privacy.socialtracking.notification.enabled", true],
-        ["privacy.socialtracking.notification.session.pageload.min", -1],
-        ["privacy.socialtracking.notification.lastShown", "0"],
-        ["privacy.socialtracking.notification.period.min", 0],
-        ["privacy.socialtracking.notification.counter", 0],
-        ["privacy.socialtracking.notification.max", 999],
-      ],
-    },
-  ];
-
-  for (let config of configs) {
-    ok(config.description, config.description);
-    await SpecialPowers.pushPrefEnv({
-      set: config.prefs,
-    });
-    for (let result of config.results) {
-      await testPopup(result, config.button);
-    }
-    await SpecialPowers.popPrefEnv();
-  }
-});
--- a/browser/locales/en-US/chrome/browser/browser.properties
+++ b/browser/locales/en-US/chrome/browser/browser.properties
@@ -554,26 +554,16 @@ contentBlocking.cookiesView.removeButton
 #   It forms the end of the (imaginary) sentence "www.example.com [was] Blocked"
 contentBlocking.fingerprintersView.blocked.label=Blocked
 
 # LOCALIZATION NOTE (contentBlocking.cryptominersView.blocked.label):
 #   This label is shown next to a cryptominer in the cryptominers subview.
 #   It forms the end of the (imaginary) sentence "www.example.com [was] Blocked"
 contentBlocking.cryptominersView.blocked.label=Blocked
 
-# Social Tracking Protection
-# LOCALIZATION NOTE (contentBlocking.socialblock.title): %S is brandShortName
-contentBlocking.socialblock.title=%S stopped a social network from tracking you here
-# LOCALIZATION NOTE (contentBlocking.socialblock.prompt): %S is brandShortName
-contentBlocking.socialblock.prompt=Your privacy matters. %S now blocks common social media trackers, limiting how much data they can collect about what you do online.
-contentBlocking.socialblock.primaryButton.label=See Protections
-contentBlocking.socialblock.primaryButton.accesskey=P
-contentBlocking.socialblock.secondaryButton.label=Close
-contentBlocking.socialblock.secondaryButton.accessKey=C
-
 trackingProtection.icon.activeTooltip2=Blocking social media trackers, cross-site tracking cookies, and fingerprinters.
 trackingProtection.icon.disabledTooltip2=Enhanced Tracking Protection is OFF for this site.
 # LOCALIZATION NOTE (trackingProtection.icon.noTrackersDetectedTooltip): %S is brandShortName.
 trackingProtection.icon.noTrackersDetectedTooltip=No trackers known to %S were detected on this page.
 
 # LOCALIZATION NOTE (protections.header):
 # Header of the Protections Panel. %S is replaced with the site's hostname.
 protections.header=Protections for %S
--- a/browser/themes/shared/notification-icons.inc.css
+++ b/browser/themes/shared/notification-icons.inc.css
@@ -394,16 +394,8 @@ html|*#webRTC-previewVideo {
   background: #74BF43 url(chrome://browser/skin/notification-icons/update.svg) no-repeat center;
   border-radius: 50%;
 }
 
 .popup-notification-icon[popupid="update-unsupported"] {
   background: #FFE900 url(chrome://browser/skin/notification-icons/update.svg) no-repeat center;
   border-radius: 50%;
 }
-
-/* Social Tracking */
-:root[lwt-toolbar-field-brighttext] .popup-notification-icon[popupid="socialblock"] {
-  list-style-image: url(chrome://browser/skin/notification-icons/block-social-dark.svg);
-}
-.popup-notification-icon[popupid="socialblock"] {
-  list-style-image: url(chrome://browser/skin/notification-icons/block-social.svg);
-}