Custom Tabs' "Copy" context-menu has a purple background (and is unreadable with a light theme), if Firefox Nightly has a private tab in the foreground
Categories
(Firefox for Android :: Tabs, defect, P1)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox148 | --- | unaffected |
| firefox149 | + | verified |
| firefox150 | --- | verified |
People
(Reporter: dholbert, Assigned: azinovyev)
References
(Regression)
Details
(Keywords: regression)
Attachments
(1 file, 3 obsolete files)
|
91.84 KB,
image/png
|
Details |
Steps to reproduce
- (optional but makes the bug more noticeable): Ensure that your device is using a "light" theme in System Settings; and in Firefox Nightly's Settings|Customize section, choose to follow the device theme.
- Set Firefox Nightly as your default browser.
- Open a private tab in Firefox Nightly (e.g. just tap the mask icon on the Firefox homepage)
- Switch to another app, e.g. Gmail, and tap a link to spawn a custom tab.
- Long-press the toolbar of the custom tab (where it shows the page title, back button, 3-dot menu, etc), to get a context menu with a "Copy" option.
Expected behavior
Regular-themed context menu.
Actual behavior
Context menu with purple background (private browsing themed) and black text, which is the wrong theme and also unreadable.
Device information
- Firefox version: Nightly 150.0a1 2026-02-27
- Android device model: Pixel 6a
- Android OS version: 16
Any additional information?
This is related to (but distinct from) recently-fixed bug 2012254 and bug 2019177.
| Reporter | ||
Comment 1•4 months ago
|
||
| Reporter | ||
Comment 2•4 months ago
|
||
Regression range:
Newest known good nightly: 2026-01-18
Oldest known bad nightly: 2026-01-19
--> Regression from bug 2009823 (like bug 2012254).
Comment 3•4 months ago
|
||
:azinovyev, since you are the author of the regressor, bug 2009823, could you take a look? Also, could you set the severity field?
For more information, please visit BugBot documentation.
| Assignee | ||
Comment 4•4 months ago
|
||
| Reporter | ||
Comment 5•4 months ago
|
||
(Thanks for the quick action!)
Comment 6•4 months ago
|
||
Set release status flags based on info from the regressing bug 2009823
Updated•4 months ago
|
Comment 7•4 months ago
|
||
This patch is intended to fix multiple bugs that were recently filed
which affect Custom Tab/PWA theming:
- Bug 2019993
- Bug 2020220
- Bug 2019177
- (maybe) Bug 2012254
The change considers intents from external tabs (even though the
function is named isCustomTabIntent) to return the appropriate theme
back. However, there is nuance to this because multi-tasking between
apps can cause the global AppState.mode to change and therefore affect
the theme for the external tabs as well.
We invoke the onModeChange during the BrowsingModeManager init because
it is currently the source of truth from where the AppState.mode is
derived. What is missing from the manager is a notification to the
AppStore and also during updateMode. Equally important, is that due to
the connection between BrowsingModeManager and AppStore, calling
onModeChange would typically cause a recursive call between the two.
This is prevented because of the themeManager.isInitialized check
within the themeManagerProvider constructor today - this makes our
patch here, highly dependant on that change.
Co-authored-by: Andrey Zinovyev <azinovyev@mozilla.com>
Updated•4 months ago
|
Updated•4 months ago
|
Updated•4 months ago
|
Comment 8•4 months ago
|
||
Andrey and I have been looking over this bug and we came to a conclusion that there is a tight coupling between two systems (browsing mode manager and theme manager) that we can't remove with as easily as we expected because those two are unaware of Custom Tabs/PWAs and our fixes are quite brittle. We decided it's best to revert the original patches instead. 🥲
See the linked reverts of bug 2012254, bug 2006631, and bug 2009823.
Comment 9•4 months ago
|
||
Closing as fixed by backouts
Updated•4 months ago
|
Updated•4 months ago
|
Comment 10•4 months ago
•
|
||
This issue does not reproduce anymore on Firefox for Android Nightly 150.0a1, and Beta 149.0b7 using a Samsung Galaxy Tab S9 Ultra (Android 16), Samsung Galaxy S9 (Android 8), and Realme C35 (Android 12).
Updated•4 months ago
|
Updated•4 months ago
|
Updated•4 months ago
|
Description
•