Skip to content

Conversation

Shalini-Ashokan
Copy link
Contributor

Note

Are you waiting for the changes in this PR to be merged?
It would be very helpful if you could test the resulting artifacts from this PR and let us know in a comment if this change resolves your issue. Thank you!

Issue Details

Shell flyout items on Windows display unwanted corner radius styling when no explicit styling is applied.

Root Cause

NavigationView's RootSplitView container has a corner radius applied by default in the WinUI control template, which creates visual inconsistency.

Description of Change

Modified the default corner radius to zero by explicitly setting RootSplitView.CornerRadius = new Microsoft.UI.Xaml.CornerRadius(0) in the MauiNavigationView.OnApplyTemplate() method.

Validated the behavior in the following platforms

  • Android
  • Windows
  • iOS
  • Mac

Issues Fixed

Fixes #17414

Output ScreenShot

Before After
Before-Fix After-Fix

@dotnet-policy-service dotnet-policy-service bot added the community ✨ Community Contribution label Oct 9, 2025
Copy link
Contributor

Hey there @@Shalini-Ashokan! Thank you so much for your PR! Someone from the team will get assigned to your PR shortly and we'll get it reviewed.

@dotnet-policy-service dotnet-policy-service bot added the partner/syncfusion Issues / PR's with Syncfusion collaboration label Oct 9, 2025
// It causes the content to not be flush up against the title bar
PaneContentGrid.Margin = new WThickness(0, 0, 0, 0);
UpdateMenuItemsContainerHeight();
RootSplitView.CornerRadius = new UI.Xaml.CornerRadius(0);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could be possible to apply the fix in the NavigationView Resources?

This is the margin around the NavigationView.Header. By default WinUI will set a

In that way, developers that would like to keep the previous behavior or override it, can do easily just creating single resources and not require to override classes.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jsuarezruiz, Thank you for the suggestion! After investigating WinUI's NavigationView template, I found that RootSplitView uses the OverlayCornerRadius resource key directly, and changing this global key would affect all overlay scenarios. Since there's no specific resource key for NavigationView's RootSplitView CornerRadius, the C# approach ensures we only target our specific NavigationView instance without impacting other UI elements.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

community ✨ Community Contribution partner/syncfusion Issues / PR's with Syncfusion collaboration platform/windows shell-flyout

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Default styling for controls does not work!

2 participants