<!-- Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT License. See LICENSE in the project root for license information. -->
<local:TestPage
    x:Class="MUXControlsTestApp.NavigationViewPageDataContext"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="clr-namespace:MUXControlsTestApp"
    xmlns:muxcontrols="http://schemas.modernwpf.com/2019"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d">

    <StackPanel Orientation="Horizontal">        
        <muxcontrols:NavigationView
            x:Name="NavView"
            AutomationProperties.Name="NavView"
            AutomationProperties.AutomationId="NavView"
            SelectionChanged="NavView_SelectionChanged"
            PaneDisplayMode="Left">
            <StackPanel>
                <StackPanel Orientation="Horizontal" Margin="0 5">
                    <TextBlock Margin="5" HorizontalAlignment="Center" VerticalAlignment="Center">DataContext of SelectedItem:</TextBlock>
                    <TextBlock x:Name="NavViewSelectedDataContext" AutomationProperties.Name="NavViewSelectedDataContext" VerticalAlignment="Center"/>
                </StackPanel>
                <StackPanel Orientation="Horizontal" Margin="0 5">
                    <Button x:Name="GetNavViewActiveVisualStates" AutomationProperties.Name="GetNavViewActiveVisualStates" Content="GetNavViewActiveVisualStates" Click="GetNavViewActiveVisualStates_Click"/>
                    <TextBlock Margin="5" HorizontalAlignment="Center" VerticalAlignment="Center">NavView Active VisualStates:</TextBlock>
                    <TextBlock x:Name="NavViewActiveVisualStatesResult" AutomationProperties.Name="NavViewActiveVisualStatesResult" VerticalAlignment="Center"/>
                </StackPanel>
            </StackPanel>
        </muxcontrols:NavigationView>

        <muxcontrols:NavigationView
                Width="400" PaneDisplayMode="Left"
                MenuItemsSource="{x:Bind Pages, Mode=OneWay}"
                ItemInvoked="NavigationView_ItemInvoked">
            <muxcontrols:NavigationView.MenuItemTemplate>
                <DataTemplate>
                    <muxcontrols:NavigationViewItem Content="{Binding Name}" AutomationProperties.Name="{Binding Name}"/>
                </DataTemplate>
            </muxcontrols:NavigationView.MenuItemTemplate>

            <TextBlock Text="{Binding SelectedPage.Name}" />
        </muxcontrols:NavigationView>
    </StackPanel>

</local:TestPage>
