Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
<?xml version="1.0" encoding="UTF-8"?>
<MasterDetailPage xmlns="http://xamarin.com/schemas/2014/forms"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="PrismForms.Views.AppShell"
xmlns:prism="clr-namespace:Prism.Mvvm;assembly=Prism.Forms"
prism:ViewModelLocator.AutowireViewModel="True">
<MasterDetailPage.Master>
<!-- Be mindful of the Title and Icon properties; they are required -->
<NavigationPage Title="Required" Icon="slideout.png" BarTextColor="White" BarBackgroundColor="#87A3BA">
<x:Arguments>
<ContentPage Title="{Binding Title}" BackgroundColor="#F4F4F4">
<ListView Grid.Row="1" ItemsSource="{Binding MenuItems}" HasUnevenRows="true" SeparatorVisibility="None" SelectedItem="{Binding SelectedItem, Mode=TwoWay}" BackgroundColor="Transparent">
<ListView.ItemTemplate>
<DataTemplate>
<ViewCell>
<StackLayout Padding="10,0" Spacing="0">
<StackLayout Orientation="Horizontal">
<Image HeightRequest="50" WidthRequest="50" Source="{Binding Image}" />
<Label HeightRequest="50" Text="{Binding Title}" VerticalTextAlignment="Center" HorizontalOptions="StartAndExpand" />
</StackLayout>
<BoxView Style="{StaticResource DividerBoxView}" />
</StackLayout>
</ViewCell>
</DataTemplate>
</ListView.ItemTemplate>
</ListView>
</ContentPage>
</x:Arguments>
</NavigationPage>
</MasterDetailPage.Master>
</MasterDetailPage>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.