Page MenuHomePhabricator

[BUG] iPad floating tab bar auto-themes when it shouldn't
Open, Stalled, LowPublicBUG REPORT

Description

Steps to reproduce

  1. Open app on iPadOS 18. Ensure iOS Settings > Display & Brightness is set to Light appearance.
  2. Open app Settings > Reading preferences > change to "Light".
  3. Background app, go to iOS Settings, go to Display & Brightness and choose Dark appearance
  4. Go back to Wikipedia app.

Expected results

Floating tab bar should be frozen on light mode

Actual results

Floating tab bar switches to dark mode, but the rest of the app remains on light mode.

Screenshots

Settings.jpeg (2×1 px, 1 MB)

Environments observed

App version: 7.7.1 (4944) but not a new issue
OS versions: 18.3
Device model: iPad mini
Device language: EN

Engineering Notes

We run this code to override the root navigation controllers' user interface style when the user changes their theme, as well as when the app launches. I think we need try running similar logic at the same moment on WMFAppViewController itself (which is a UITabBarController subclass).

NSString *themeName = [NSUserDefaults.standardUserDefaults themeName];
if ([WMFTheme isDefaultThemeName:themeName]) {
    self.overrideUserInterfaceStyle = UIUserInterfaceStyleUnspecified;
} else if ([WMFTheme isDarkThemeName:themeName]) {
    self.overrideUserInterfaceStyle = UIUserInterfaceStyleDark;
} else {
    self.overrideUserInterfaceStyle = UIUserInterfaceStyleLight;
}

Event Timeline

Thank you for tagging this task with good first task for Wikimedia newcomers!

Newcomers often may not be aware of things that may seem obvious to seasoned contributors, so please take a moment to reflect on how this task might look to somebody who has never contributed to Wikimedia projects.

A good first task is a self-contained, non-controversial task with a clear approach. It should be well-described with pointers to help a completely new contributor, for example it should clearly pointed to the codebase URL and provide clear steps to help a contributor get setup for success. We've included some guidelines at https://phabricator.wikimedia.org/tag/good_first_task/ !

Thank you for helping us drive new contributions to our projects <3

Glofrumento changed the task status from In Progress to Stalled.Mar 17 2025, 4:20 AM

Unfortunately, this issue cannot be closed.

Quote from this issue:

The tab bar's text color (and image color) will inherit from the tintColor of the UITabBarController's view. Setting tabBarController.view.tintColor = ..." will allow you change that. Unfortunately, the background color of the bar cannot be changed and will respect the system appearance (or current user interface style) instead.

Pppery removed a project: good first task.
Pppery added a subscriber: Glofrumento.