Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NavigationView: Add theme resources to enable easy flyout padding customization #2760

Conversation

Felix-Dev
Copy link
Contributor

@Felix-Dev Felix-Dev commented Jun 26, 2020

Description

This PR adds two theme resources to the NavigationView to provide easy padding customization for

  • the overflow menu in Top PaneDisplayMode and
  • the NavigationViewItem children flyout in the hierarchical NavigationView

Motivation and Context

Closes #2718.

How Has This Been Tested?

Tested visually.

Screenshots:

The following XAML

<Application.Resources>
    <Thickness x:Key="TopNavigationViewOverflowMenuPadding">0,24</Thickness>
    <Thickness x:Key="NavigationViewItemChildrenMenuFlyoutPadding">0</Thickness>
</Application.Resources>

gives the following resulting look:

Overflow Menu in Top PaneDisplayMode

image

NavigationViewItem children flyout

image

For reference, here is how the flyout padding looks by default (children flyout shown here, same padding used in the overflow menu):
image

@msft-github-bot msft-github-bot added the needs-triage Issue needs to be triaged by the area owners label Jun 26, 2020
@StephenLPeters
Copy link
Contributor

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@StephenLPeters StephenLPeters added area-NavigationView NavView control team-Controls Issue for the Controls team and removed needs-triage Issue needs to be triaged by the area owners labels Jun 26, 2020
Copy link
Contributor

@StephenLPeters StephenLPeters left a comment

Choose a reason for hiding this comment

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

:shipit:

@StephenLPeters StephenLPeters merged commit 6994eb9 into microsoft:master Jun 30, 2020
@Felix-Dev Felix-Dev deleted the user/Felix-Dev/navview-themeresources-flyoutpadding branch June 30, 2020 00:34
Kinnara added a commit to Kinnara/ModernWpf that referenced this pull request Dec 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-NavigationView NavView control team-Controls Issue for the Controls team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Proposal: NavigationView: Add theme resources to enable easy flyout padding customization
3 participants