<?xml version="1.0" encoding="UTF-8"?>
<i:IllustDataCollectionPage xmlns="http://xamarin.com/schemas/2014/forms"
                            xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
                            xmlns:i="clr-namespace:Pixiview.Illust"
                            xmlns:u="clr-namespace:Pixiview.UI"
                            xmlns:r="clr-namespace:Pixiview.Resources"
                            x:Class="Pixiview.Illust.RecommendsPage"
                            BackgroundColor="{DynamicResource WindowColor}"
                            Title="{r:Text Recommends}">
    <ContentPage.ToolbarItems>
        <ToolbarItem Order="Primary" Clicked="Refresh_Clicked"
                     IconImageSource="{DynamicResource FontIconRefresh}"/>
    </ContentPage.ToolbarItems>
    <Grid>
        <ScrollView x:Name="scrollView" HorizontalOptions="Fill" HorizontalScrollBarVisibility="Never">
            <StackLayout>
                <ActivityIndicator x:Name="activityLoading" Margin="0, -40, 0, 0"
                                   HeightRequest="40"
                                   IsRunning="{Binding IsLoading}"
                                   IsVisible="{Binding IsLoading}"/>
                <u:FlowLayout ItemsSource="{Binding Users}" IsVisible="{Binding UserRecommendsVisible}"
                              HorizontalOptions="Fill" Column="{Binding UserColumns}"
                              Margin="16" RowSpacing="16"
                              ItemTemplate="{StaticResource userCardView}"/>
                <u:FlowLayout ItemsSource="{Binding Illusts}"
                              HorizontalOptions="Fill" Column="{Binding Columns}"
                              Margin="16" RowSpacing="16" ColumnSpacing="16"
                              ItemTemplate="{StaticResource cardView}"/>
            </StackLayout>
        </ScrollView>
    </Grid>
</i:IllustDataCollectionPage>
