1

I have a .NET MAUI Shell application with a Flyout menu targeting .NET 9. The Action Bar in both Light and Dark mode is set to be black. I want the hamburger menu icon and the back button to be white in both cases.

When I tested on iOS 26.0 these icons are not displaying correctly. They show as white, as expected, in Dark Mode. But in Light Mode they're not taking my custom colors.

enter image description here

There seems to be a difference between how iOS handles the color of the Hamburger menu and Back button in iOS 26.0 and iOS 18.6.

In iOS 18.6, these buttons show as white on the black background as expected. But in iOS 26.0 they're constantly being shown as Black. The OS seems to be overwriting the colors I set in my app.

Here's the difference for the Menu item: Menu Item differences between iOS 26.0 and iOS 18.6

And here's the difference for the Back button Back button difference between iOS 26.0 and iOS 18.6

I have the resource dictionary in my App.xaml as follows:

    <Style TargetType="NavigationPage">
        <Setter Property="BarBackgroundColor" Value="{DynamicResource NavigationBarColor}" />
        <Setter Property="BarTextColor" Value="{DynamicResource NavigationTextColor}" />
    </Style>
    <Style x:Key="BaseStyle" TargetType="Element">
        <Setter Property="Shell.BackgroundColor" Value="{DynamicResource NavigationBarColor}" />
        <Setter Property="Shell.ForegroundColor" Value="{DynamicResource NavigationTextColor}" />
        <Setter Property="Shell.TitleColor" Value="{DynamicResource NavigationTextColor}" />
        <Setter Property="Shell.DisabledColor" Value="{DynamicResource DisabledButtonTextColor}" />
        <Setter Property="Shell.UnselectedColor" Value="{DynamicResource MenuBackgroundColor}" />
        <Setter Property="Shell.TabBarBackgroundColor" Value="{DynamicResource PageBackgroundColor}" />
        <Setter Property="Shell.TabBarForegroundColor" Value="{DynamicResource NavigationTextColor}" />
        <Setter Property="Shell.TabBarUnselectedColor" Value="{DynamicResource DisabledButtonTextColor}" />
        <Setter Property="Shell.TabBarTitleColor" Value="{DynamicResource NavigationTextColor}" />
    </Style>
    <Style TargetType="TabBar" BasedOn="{StaticResource BaseStyle}" />
    <Style TargetType="FlyoutItem" BasedOn="{StaticResource BaseStyle}" />

The NavigationBarColor and NavigationTextColor are the same in both Light and Dark themes here:

<Color x:Key="NavigationBarColor">#1F1F1F</Color>
<Color x:Key="NavigationTextColor">#FFFFFF</Color>

I can't find anything specific online regarding this issue and iOS version. What do I need to do get iOS 26.0 to show the hamburger menu item and back button correctly?

6
  • I've found a way to get around this. It's due to the new glass affects for buttons, icons, etc. in iOS 26. To get it to look the same as iOS 18.6, I can add the following to my info.plist <key>UIDesignRequiresCompatibility</key>true/>. This is not ideal as it will only work until iOS27. Hopefully there's a better way implemented between now and then. Commented Oct 24 at 15:14
  • I think Gerlard has mentioed they are looking into a better fix for this. Liquid glass will be a pain! Commented Oct 26 at 20:09
  • 1
    Following up what I said, Gerald had said in response to me asking if there is a long term opt out-> "This is what Apple wants you to do and we’re not going to build our own custom UI to opt out 🙂" Commented Oct 26 at 21:46
  • That's fair! It doesn't have to look the exact same, but a way to set the color of the glass would be great in future so it doesn't blend in the background like in my case. Commented Oct 28 at 8:26
  • I would presume there will, or at least I hope. I plan to use custom styles to avoid it all :D Commented Oct 28 at 9:03

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.