maui icon indicating copy to clipboard operation
maui copied to clipboard

NavigationPage TitleBar Persists if child pages have a title

Open jknaudt21 opened this issue 2 years ago • 0 comments

Description

Creating a NavigationPage with HasNavigationBar="False" will still display a Navigation Bar if one of the child pages has a title.

image

Steps to Reproduce

  1. Create a new maui app
  2. Delete the App Shell
  3. Create a new xaml TabbedPage
  4. Make the app load the TabbedPage
  5. Inside the Tabbed Page paste this code:
    <NavigationPage Title="My Page"
                    HasNavigationBar="False">
        <x:Arguments>
            <local:MainPage/>
        </x:Arguments>
    </NavigationPage>
  1. Give MainPage.xaml a "Title" property
  2. Run the project. Obersve how the NavigationPage will still have a NavigationBar even though the property is set to false. You can even add the BarBackgroundColorProperty and it will be shown

Link to public reproduction project repository

see repro steps

Version with bug

7.0 (current)

Last version that worked well

7.0 (current)

Affected platforms

Android, Windows

Affected platform versions

Windows 11, Android, haven't tested iOS

Did you find any workaround?

Delete the "Title" property for all child pages of a NavigationPage

Relevant log output

No response

jknaudt21 avatar Mar 09 '23 23:03 jknaudt21