tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

commit fd25face9d31224ecfeb785d9931843e34f7360b
parent 0b818646649d7167fddffb9392dd4c224e77100a
Author: Reem H <42309026+reemhamz@users.noreply.github.com>
Date:   Fri, 14 Nov 2025 03:51:19 +0000

Bug 1998829 - Add 'Stories' section to Firefox Home Settings Redesign. r=home-newtab-reviewers,fluent-reviewers,npypchenko,bolsson

Differential Revision: https://phabricator.services.mozilla.com/D271919

Diffstat:
Mbrowser/components/preferences/home.js | 10++++++++++
Mbrowser/components/preferences/main.js | 5+++++
Mbrowser/locales/en-US/browser/preferences/preferences.ftl | 4++++
Apython/l10n/fluent_migrations/bug_1998829_settings_redesign_stories_description.py | 24++++++++++++++++++++++++
4 files changed, 43 insertions(+), 0 deletions(-)

diff --git a/browser/components/preferences/home.js b/browser/components/preferences/home.js @@ -81,6 +81,10 @@ if (Services.prefs.getBoolPref("browser.settings-redesign.enabled")) { type: "int", }, { + id: "browser.newtabpage.activity-stream.feeds.section.topstories", + type: "bool", + }, + { id: "browser.newtabpage.activity-stream.feeds.section.highlights", type: "bool", }, @@ -166,6 +170,12 @@ if (Services.prefs.getBoolPref("browser.settings-redesign.enabled")) { pref: "browser.newtabpage.activity-stream.topSitesRows", }); + // Stories + Preferences.addSetting({ + id: "stories", + pref: "browser.newtabpage.activity-stream.feeds.section.topstories", + }); + // Recent activity Preferences.addSetting({ id: "recentActivity", diff --git a/browser/components/preferences/main.js b/browser/components/preferences/main.js @@ -1245,6 +1245,11 @@ let SETTINGS_CONFIG = { ], }, { + id: "stories", + l10nId: "home-prefs-stories-header2", + control: "moz-toggle", + }, + { id: "recentActivity", l10nId: "home-prefs-recent-activity-header", control: "moz-toggle", diff --git a/browser/locales/en-US/browser/preferences/preferences.ftl b/browser/locales/en-US/browser/preferences/preferences.ftl @@ -767,6 +767,10 @@ home-prefs-stories-header = .label = Stories home-prefs-stories-description = Personalized stories based on your activity +home-prefs-stories-header2 = + .label = Stories + .description = Exceptional content curated by the { -brand-product-name } family + ## home-prefs-recommended-by-learn-more = How it works diff --git a/python/l10n/fluent_migrations/bug_1998829_settings_redesign_stories_description.py b/python/l10n/fluent_migrations/bug_1998829_settings_redesign_stories_description.py @@ -0,0 +1,24 @@ +# Any copyright is dedicated to the Public Domain. +# http://creativecommons.org/publicdomain/zero/1.0/ + +from fluent.migrate.helpers import transforms_from + + +def migrate(ctx): + """Bug 1998829 - Add 'Stories' section to Firefox Home Settings Redesign, part {index}""" + + source = "browser/browser/preferences/preferences.ftl" + target = source + + ctx.add_transforms( + target, + target, + transforms_from( + """ +home-prefs-stories-header2 = + .label = { COPY_PATTERN(from_path, "home-prefs-stories-header.label")} + .description = { COPY_PATTERN(from_path, "home-prefs-recommended-by-description-generic")} +""", + from_path=source, + ), + )