Skip to content

Commit

Permalink
Bug 1665957 - rename Pioneer to Ion r=maxxcrawford,fluent-reviewers,flod
Browse files Browse the repository at this point in the history
  • Loading branch information
rhelmer committed Sep 23, 2020
1 parent 6f5a5f8 commit 4748e0a
Show file tree
Hide file tree
Showing 29 changed files with 429 additions and 440 deletions.
2 changes: 1 addition & 1 deletion browser/base/content/browser-siteIdentity.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ var gIdentityHandler = {
* RegExp used to decide if an about url should be shown as being part of
* the browser UI.
*/
_secureInternalPages: /^(?:accounts|addons|cache|certificate|config|crashes|downloads|license|logins|preferences|protections|rights|sessionrestore|support|welcomeback|pioneer)(?:[?#]|$)/i,
_secureInternalPages: /^(?:accounts|addons|cache|certificate|config|crashes|downloads|license|logins|preferences|protections|rights|sessionrestore|support|welcomeback|ion)(?:[?#]|$)/i,

/**
* Whether the established HTTPS connection is considered "broken".
Expand Down
2 changes: 1 addition & 1 deletion browser/base/content/browser.css
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ toolbar[customizing] > .overflow-button {
display: none;
}

toolbar[customizing] #pioneer-button,
toolbar[customizing] #ion-button,
toolbar[customizing] #whats-new-menu-button {
display: none;
}
Expand Down
6 changes: 3 additions & 3 deletions browser/base/content/browser.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -2001,12 +2001,12 @@

<toolbaritem id="PanelUI-button"
removable="false">
<toolbarbutton id="pioneer-button"
<toolbarbutton id="ion-button"
class="toolbarbutton-1"
hidden="true"
badged="true"
onmousedown="switchToTabHavingURI('about:pioneer', true);"
onkeypress="switchToTabHavingURI('about:pioneer', true);"/>
onmousedown="switchToTabHavingURI('about:ion', true);"
onkeypress="switchToTabHavingURI('about:ion', true);"/>
<toolbarbutton id="whats-new-menu-button"
class="toolbarbutton-1"
hidden="true"
Expand Down
50 changes: 22 additions & 28 deletions browser/components/BrowserGlue.jsm
Original file line number Diff line number Diff line change
Expand Up @@ -2207,47 +2207,44 @@ BrowserGlue.prototype = {
_checkHTTPSOnlyPBMPref();
},

_monitorPioneerPref() {
const PREF_PIONEER_ID = "toolkit.telemetry.pioneerId";
_monitorIonPref() {
const PREF_ION_ID = "toolkit.telemetry.pioneerId";

const _checkPioneerPref = async () => {
const _checkIonPref = async () => {
for (let win of Services.wm.getEnumerator("navigator:browser")) {
win.document.getElementById(
"pioneer-button"
).hidden = !Services.prefs.getStringPref(PREF_PIONEER_ID, null);
"ion-button"
).hidden = !Services.prefs.getStringPref(PREF_ION_ID, null);
}
};

const windowListener = {
onOpenWindow(xulWindow) {
const win = xulWindow.docShell.domWindow;
win.addEventListener("load", () => {
const pioneerButton = win.document.getElementById("pioneer-button");
if (pioneerButton) {
pioneerButton.hidden = !Services.prefs.getStringPref(
PREF_PIONEER_ID,
null
);
const ionButton = win.document.getElementById("ion-button");
if (ionButton) {
ionButton.hidden = !Services.prefs.getStringPref(PREF_ION_ID, null);
}
});
},
onCloseWindow() {},
};

Services.prefs.addObserver(PREF_PIONEER_ID, _checkPioneerPref);
Services.prefs.addObserver(PREF_ION_ID, _checkIonPref);
Services.wm.addListener(windowListener);
_checkPioneerPref();
_checkIonPref();
},

_monitorPioneerStudies() {
_monitorIonStudies() {
const STUDY_ADDON_COLLECTION_KEY = "pioneer-study-addons-v1";
const PREF_PIONEER_NEW_STUDIES_AVAILABLE =
const PREF_ION_NEW_STUDIES_AVAILABLE =
"toolkit.telemetry.pioneer-new-studies-available";

const _badgeIcon = async () => {
for (let win of Services.wm.getEnumerator("navigator:browser")) {
win.document
.getElementById("pioneer-button")
.getElementById("ion-button")
.querySelector(".toolbarbutton-badge")
.classList.add("feature-callout");
}
Expand All @@ -2257,14 +2254,11 @@ BrowserGlue.prototype = {
onOpenWindow(xulWindow) {
const win = xulWindow.docShell.domWindow;
win.addEventListener("load", () => {
const pioneerButton = win.document.getElementById("pioneer-button");
if (pioneerButton) {
const badge = pioneerButton.querySelector(".toolbarbutton-badge");
const ionButton = win.document.getElementById("ion-button");
if (ionButton) {
const badge = ionButton.querySelector(".toolbarbutton-badge");
if (
Services.prefs.getBoolPref(
PREF_PIONEER_NEW_STUDIES_AVAILABLE,
false
)
Services.prefs.getBoolPref(PREF_ION_NEW_STUDIES_AVAILABLE, false)
) {
badge.classList.add("feature-callout");
} else {
Expand All @@ -2277,15 +2271,15 @@ BrowserGlue.prototype = {
};

// Update all open windows if the pref changes.
Services.prefs.addObserver(PREF_PIONEER_NEW_STUDIES_AVAILABLE, _badgeIcon);
Services.prefs.addObserver(PREF_ION_NEW_STUDIES_AVAILABLE, _badgeIcon);

// Badge any currently-open windows.
if (Services.prefs.getBoolPref(PREF_PIONEER_NEW_STUDIES_AVAILABLE, false)) {
if (Services.prefs.getBoolPref(PREF_ION_NEW_STUDIES_AVAILABLE, false)) {
_badgeIcon();
}

RemoteSettings(STUDY_ADDON_COLLECTION_KEY).on("sync", async event => {
Services.prefs.setBoolPref(PREF_PIONEER_NEW_STUDIES_AVAILABLE, true);
Services.prefs.setBoolPref(PREF_ION_NEW_STUDIES_AVAILABLE, true);
});

// When a new window opens, check if we need to badge the icon.
Expand Down Expand Up @@ -2382,8 +2376,8 @@ BrowserGlue.prototype = {
this._monitorScreenshotsPref();
this._monitorWebcompatReporterPref();
this._monitorHTTPSOnlyPref();
this._monitorPioneerPref();
this._monitorPioneerStudies();
this._monitorIonPref();
this._monitorIonStudies();

let pService = Cc["@mozilla.org/toolkit/profile-service;1"].getService(
Ci.nsIToolkitProfileService
Expand Down
2 changes: 1 addition & 1 deletion browser/components/about/AboutRedirector.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ static const RedirEntry kRedirMap[] = {
nsIAboutModule::URI_SAFE_FOR_UNTRUSTED_CONTENT |
nsIAboutModule::URI_MUST_LOAD_IN_CHILD | nsIAboutModule::ALLOW_SCRIPT |
nsIAboutModule::URI_CAN_LOAD_IN_PRIVILEGEDABOUT_PROCESS},
{"pioneer", "chrome://browser/content/pioneer.html",
{"ion", "chrome://browser/content/ion.html",
nsIAboutModule::ALLOW_SCRIPT | nsIAboutModule::HIDE_FROM_ABOUTABOUT},
};

Expand Down
2 changes: 1 addition & 1 deletion browser/components/about/components.conf
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ pages = [
'logins',
'newinstall',
'newtab',
'pioneer',
'ion',
'pocket-saved',
'pocket-signup',
'policies',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ details > summary {
display: none !important;
}

#pioneer-icon {
#ion-icon {
-moz-context-properties: fill;
fill: currentColor;
}
Expand Down
76 changes: 76 additions & 0 deletions browser/components/ion/content/ion.ftl
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.

### This file is not in a locales directory to prevent it from
### being translated as the feature is still in heavy development
### and strings are likely to change often.

-ion-brand-short-name = Ion
ion = { -ion-brand-short-name }
ion-document-title = Put your data to work for a better internet
ion-summary = { -ion-brand-short-name } puts your data to work to address some of today’s most pressing technology concerns, like misinformation, data privacy, and ethical AI. The data you agree to share with Mozilla (the makers of Firefox) helps create tools for better internet transparency and design products that give control back to the people who use them. As a { -ion-brand-short-name } participant, you’ll also have the option to contribute your data to studies sponsored by research institutions and other organizations.
ion-study-prompt = Join to enroll
ion-join-study = Join Study
ion-leave-study = Leave Study
ion-enrollment-button = Join { -ion-brand-short-name }
ion-unenrollment-button = Leave { -ion-brand-short-name }
ion-current-studies = Current Studies
ion-no-current-studies = No current studies, please check back later.
ion-end-study = End Study
ion-ended-study = Study Ended
ion-accept-participate = Accept and Participate
ion-accept-leave = Accept and Leave
ion-cancel = Cancel
ion-consent-notice = { -ion-brand-short-name } Privacy Notice
ion-consent-study-notice = { -ion-brand-short-name } Study Privacy Consent Notice
ion-leave = Leaving { -ion-brand-short-name }
ion-consent-study-title = Leaving Study
ion-consent-study-join = Accept and Join Study
ion-consent-study-leave = Accept and Leave Study
ion-program-consent-intro = When you enroll in { -ion-brand-short-name }, you are sharing personal information. Keeping that information safe is important to us and to the integrity of { -ion-brand-short-name }. Here is how we safeguard your data and protect your identity.
ion-program-study-intro = When you enroll in this study, you are sharing personal information. Keeping that information safe is important to us and to the integrity of { -ion-brand-short-name }. Here is how we safeguard your data and protect your identity.
ion-works-title = How it works:
ion-works-bullet-get-started-title = Get started.
ion-works-bullet-get-started-content = Select the { ion-enrollment-button } button, review and agree to our Privacy Notice, and answer a few (optional) demographic questions. Note that { -ion-brand-short-name } is currently open to participants in the US who are 19 or older.
ion-works-bullet-enroll-title = Enroll in studies.
ion-works-bullet-enroll-content = Share your data with studies run by { -vendor-short-name } and our { -ion-brand-short-name } research partners. You’ll have the opportunity to learn about a study’s goals, the data it collects, and its research team before you enroll.
ion-works-bullet-control-title = Stay in control.
ion-works-bullet-control-content = The { -ion-brand-short-name } icon will appear on the { -brand-product-name } toolbar. Select the icon any time you want to return to this page to update your settings, enroll in a study, or leave a study or the { -ion-brand-short-name } program.
ion-your-data-title = Your data: why it matters and how we protect it
ion-your-data-summary = { -ion-brand-short-name } puts your data to work for a better internet. Our goal is to better understand topics like internet usage, online privacy, algorithmic bias, discrimination, and misinformation. This in turn can lead to new products that fundamentally change the tech landscape and hand more power and control back to users.
ion-your-data-bullet-know = You’ll know the information we plan to collect before we collect it. We publish our data collection documentation, so you can confirm this for yourself. Read each privacy notice for detailed information.
ion-your-data-bullet-lengths = We prioritize securing your data and protecting your privacy.
ion-your-data-bullet-leave = You can leave the { -ion-brand-short-name } program at any time, and we’ll stop collecting data when you do.
ion-your-data-learn-more = Learn more about <a data-l10n-name="privacy-policy">managing the data you share</a> with { -ion-brand-short-name }.
ion-us-only = Sorry, { -ion-brand-short-name } is currently only open to participants in the US.
ion-enroll-effective-date = Effective September 1, 2020
ion-enroll-summary = { -ion-brand-short-name } is an experimental initiative led by Mozilla to better understand how our users use and navigate the internet. { -ion-brand-short-name } is available to Firefox users in the United States who are 19 or older.
ion-enroll-demographic = When you join { -ion-brand-short-name }, we’ll ask you to provide optional demographic data. We’ll also collect basic technical and interaction data as long as you’re participating in { -ion-brand-short-name }. Once you’ve enrolled, you’ll have the opportunity to join available studies—each study will have a specific research purpose and unique privacy notice for you to review before you join it.
ion-enroll-privacy-notice = In this Privacy Notice, we detail what data the { -ion-brand-short-name } program collects and discloses, and why. Read each study’s privacy notice for information about how data is collected and handled in that particular study. We also adhere to the <a data-l10n-name="privacy-notice">Mozilla Privacy Policy</a> for how we receive, handle, and share information.
ion-enroll-data-disclosure = To see a full list of the data we collect, click <a data-l10n-name="privacy-policy">here</a>.
ion-enroll-what-we-collect = What Information We Collect:
ion-enroll-collect-demographic = <strong>Demographic data:</strong> We collect optional, self-reported demographic data from { -ion-brand-short-name } participants, including their age, gender, race/ethnicity, education level, household income, and zip code.
ion-enroll-technical-data = <strong>Technical data:</strong> We collect basic information about your device’s operating system. When Firefox sends data to us, your IP address is temporarily collected as part of our server logs.
ion-enroll-interaction-data = <strong>Interaction data:</strong> We collect data about your interactions with Firefox, like number and type of installed Firefox Add-ons and your active browsing session duration.
ion-enroll-location-data = <strong>Location data:</strong> We will use your IP address to approximate your country location, in addition to collecting your self-reported zip code (if you provide it).
ion-enroll-how-we-use = How We Use Your Information:
ion-enroll-r-and-d = We use the information we collect for for <strong>research and development</strong>, including:
ion-enroll-bullet-criteria = To determine which participants meet the criteria to be available to participate in particular research studies
ion-enroll-bullet-representative = To ensure our data sets are representative of the many users of Firefox
ion-enroll-bullet-improve-existing = To improve our existing products and services
ion-enroll-bullet-create = To create and develop new products
ion-enroll-who-we-disclose-to = Who We May Disclose Information To:
ion-enroll-who-we-disclose-bullet-gcp = <strong>Google Cloud Platform (GCP):</strong> We use GCP as our cloud-storage service. Mozilla has contracted with GCP requiring them to handle the data in ways that are approved by us.
ion-enroll-who-we-disclose-bullet-third-party = <strong>Third-party researchers:</strong> As part of being part of the { -ion-brand-short-name } program, we will offer you the ability to join studies. If necessary for the study, we may ask you to share all or some of the data collected under this Privacy Notice with the third party researcher(s) administering a study. Mozilla will contractually obligate the third party researchers to ensure that your data is handled in ways that are approved by us.
ion-enroll-who-we-disclose-bullet-public = <strong>General public:</strong> To advance our <a data-l10n-name="mozilla-manifesto">mission of being open</a>, we may release data sets to the general public. When we do so, we will aggregate the data and remove identifying information, so the data won’t reveal the behaviors or characteristics of individual users.
ion-enroll-data-management = Data Management:
ion-enroll-data-management-learn-more = You can learn more about managing your { -ion-brand-short-name } and individual study data <a data-l10n-name="privacy-policy">here</a>. If you have any other questions regarding our privacy practices, please contact us at <a data-l10n-name="compliance-email">[email protected]</a>.
Loading

0 comments on commit 4748e0a

Please sign in to comment.