commit 6aa243df328bf3031c994dad8eb2e8a67a653842
parent 4903e6275b2f9d65ad17d1dbb9b367ac2415955e
Author: Rebecca King <rking@mozilla.com>
Date: Thu, 30 Oct 2025 19:52:44 +0000
Bug 1993266 - Create section for Firefox VPN additional links in about:settings - r=ip-protection-reviewers,fluent-reviewers,mstriemer,fchasen,bolsson
Differential Revision: https://phabricator.services.mozilla.com/D270398
Diffstat:
4 files changed, 65 insertions(+), 0 deletions(-)
diff --git a/browser/components/preferences/main.js b/browser/components/preferences/main.js
@@ -1536,6 +1536,28 @@ let SETTINGS_CONFIG = {
},
],
},
+ {
+ id: "ipProtectionAdditionalLinks",
+ control: "moz-box-group",
+ options: [
+ {
+ id: "ipProtectionSupportLink",
+ l10nId: "ip-protection-contact-support-link",
+ control: "moz-box-link",
+ controlAttrs: {
+ href: "https://support.mozilla.org/questions/new/mozilla-vpn/form",
+ },
+ },
+ {
+ id: "ipProtectionUpgradeLink",
+ l10nId: "ip-protection-upgrade-link",
+ control: "moz-box-link",
+ controlAttrs: {
+ href: "https://www.mozilla.org/products/vpn/",
+ },
+ },
+ ],
+ },
],
},
cookiesAndSiteData: {
diff --git a/browser/components/preferences/privacy.js b/browser/components/preferences/privacy.js
@@ -1298,6 +1298,11 @@ Preferences.addSetting({
deps: ["ipProtectionVisible", "ipProtectionAutoStart"],
visible: ({ ipProtectionVisible }) => ipProtectionVisible.value,
});
+Preferences.addSetting({
+ id: "ipProtectionAdditionalLinks",
+ deps: ["ipProtectionVisible"],
+ visible: ({ ipProtectionVisible }) => ipProtectionVisible.value,
+});
// Study opt out
if (AppConstants.MOZ_DATA_REPORTING) {
diff --git a/browser/components/preferences/tests/browser_privacy_ipprotection.js b/browser/components/preferences/tests/browser_privacy_ipprotection.js
@@ -267,3 +267,36 @@ add_task(async function test_autostart_checkboxes() {
}
);
});
+
+// Test that additional links exist
+add_task(async function test_additional_links() {
+ await setupVpnPrefs({
+ feature: "beta",
+ });
+
+ await BrowserTestUtils.withNewTab(
+ { gBrowser, url: "about:preferences#privacy" },
+ async function (browser) {
+ let section = browser.contentDocument.getElementById(SECTION_ID);
+ let settingGroup = section.querySelector(
+ `setting-group[groupid="ipprotection"]`
+ );
+ is_element_visible(section, "#dataIPProtectionGroup is shown");
+ is_element_visible(settingGroup, "ipprotection setting group is shown");
+
+ let additionalLinks = settingGroup?.querySelector(
+ "#ipProtectionAdditionalLinks"
+ );
+ is_element_visible(additionalLinks, "Additional links section is shown");
+
+ let ipProtectionSupportLink = additionalLinks?.querySelector(
+ "#ipProtectionSupportLink"
+ );
+ let ipProtectionUpgradeLink = additionalLinks?.querySelector(
+ "#ipProtectionUpgradeLink"
+ );
+ is_element_visible(ipProtectionSupportLink, "Support link is shown");
+ is_element_visible(ipProtectionUpgradeLink, "Upgrade link is shown");
+ }
+ );
+});
diff --git a/browser/locales-preview/ipProtection.ftl b/browser/locales-preview/ipProtection.ftl
@@ -97,6 +97,11 @@ ip-protection-autostart-checkbox =
ip-protection-autostart-private-checkbox =
.label = In private windows
+ip-protection-contact-support-link =
+ .label = Contact support
+ip-protection-upgrade-link =
+ .label = Upgrade to { -mozilla-vpn-brand-name }
+
# "Select" is an adjective here to describe a setting that allows running the VPN on certain sites only.
# Not to be confused with the action of selecting a site, which is not at all applicable to this setting.
ip-protection-site-exceptions-select-sites-radio =