Skip to content

[Android] Shell.FlyoutHeader background is incorrect #35416

Description

@dartasen

Description

On Android, Shell.FlyoutHeader seems to come from primary color, instead of FlyoutBackground

On Windows :
Image

On Android :
Image

Steps to Reproduce

  1. Create a new dotnet maui App
  2. In Resources\Styles\Styles.xaml, look for <Style TargetType="Shell" ApplyToDerivedTypes="True">
  3. Add <Setter Property="Shell.FlyoutBackground" Value="Red" />
  4. In AppShell.xaml :
<?xml version="1.0" encoding="UTF-8" ?>
<Shell x:Class="MauiApp1.AppShell"
       xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
       xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
       xmlns:local="clr-namespace:MauiApp1"
       FlyoutBehavior="Flyout"
       NavBarHasShadow="False"
       Title="MauiApp1">

    <ShellContent Title="Home"
                  ContentTemplate="{DataTemplate local:MainPage}"
                  Route="MainPage" />

    <Shell.FlyoutHeader>
        <Label Text="Hello I'm the header" />
    </Shell.FlyoutHeader>
    
    <Shell.FlyoutFooter>
        <Label Text="Hello I'm the footer" />
    </Shell.FlyoutFooter>
</Shell>
  1. Build the app and run on Android, the FlyoutHeader will have the primary color instead of the FlyoutBackground color

Link to public reproduction project repository

No response

Version with bug

10.0.60

Is this a regression from previous behavior?

Yes, this used to work in .NET MAUI

Last version that worked well

9.0.120 SR12

Affected platforms

Android

Affected platform versions

Android 13, 14, 15, 16

Did you find any workaround?

Add a component that takes all the FlyouterHeader space and override the background on this component

Relevant log output

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-controls-shellShell Navigation, Routes, Tabs, Flyouti/regressionThis issue described a confirmed regression on a currently supported versionpartner/syncfusionIssues / PR's with Syncfusion collaborationplatform/androidregressed-in-10-rc1s/triagedIssue has been revieweds/verifiedVerified / Reproducible Issue ready for Engineering Triaget/bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions