<UserControl xmlns="https://github.com/avaloniaui"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
             xmlns:viewModels="clr-namespace:detect.gui.ViewModels"
             mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
             x:Class="detect.gui.Controls.PageControl"
             x:DataType="viewModels:PageModelBase">
    <Border Padding="10,5">
        <StackPanel Orientation="Horizontal"
                    HorizontalAlignment="Right"
                    Spacing="0">
            <StackPanel.Styles>
                <Style Selector="TextBlock">
                    <Setter Property="Foreground" Value="#ffffff" />
                    <Setter Property="FontSize" Value="14" />
                </Style>
            </StackPanel.Styles>
            <TextBlock Text="总记录数: " />
            <TextBlock Text="{Binding RecordCount}" />
            <TextBlock Width="20" />
            <TextBlock Text="当前页: " />
            <TextBlock Text="{Binding PageNum}" />
            <TextBlock Text=" / " />
            <TextBlock Text="总页数: " />
            <TextBlock Text="{Binding PageCount}" />
            <TextBlock Width="20" />
            <Button Classes="icon-button circle first-page small page"
                    IsEnabled="{Binding CanFirst}"
                    Command="{Binding FirstCommand}" />
            <Button Classes="icon-button circle left-page small page"
                    IsEnabled="{Binding CanLeft}"
                    Command="{Binding LeftCommand}" />
            <Button Classes="icon-button circle right-page small page"
                    IsEnabled="{Binding CanRight}"
                    Command="{Binding RightCommand}" />
            <Button Classes="icon-button circle last-page small page"
                    IsEnabled="{Binding CanLast}"
                    Command="{Binding LastCommand}" />
        </StackPanel>
    </Border>
</UserControl>