<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms"
             xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
             xmlns:local="clr-namespace:TestDrive"
             xmlns:vm="clr-namespace:TestDrive.ViewModels"
             Title="Test Drive"
             x:Class="TestDrive.Views.ListagemView">
    <ContentPage.BindingContext>
        <vm:ListagemViewModel></vm:ListagemViewModel>
    </ContentPage.BindingContext>
    <ListView x:Name="listViewVeiculos" ItemsSource="{Binding Veiculos}" Margin="25"
              ItemTapped="listViewVeiculos_ItemTapped">
        <ListView.ItemTemplate>
            <DataTemplate>
                <ViewCell>
                    <ViewCell.View>
                        <StackLayout Orientation="Horizontal">
                            <Label Text="{Binding Nome}" FontSize="20" VerticalTextAlignment="Center"></Label>
                            <Label Text=" - " VerticalTextAlignment="Center"></Label>
                            <Label Text="{Binding PrecoFormatado}" FontAttributes="Bold" VerticalTextAlignment="Center"></Label>
                        </StackLayout>
                    </ViewCell.View>
                </ViewCell>
            </DataTemplate>
        </ListView.ItemTemplate>
    </ListView>

</ContentPage>