<!-- Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT License. See LICENSE in the project root for license information. -->
<ui:Page
    x:Class="MUXControlsTestApp.Samples.FlowLayoutDemoPage"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:ui="http://schemas.modernwpf.com/2019"
    xmlns:mux="clr-namespace:ModernWpf.Controls;assembly=ModernWpf.Controls"
    xmlns:local="clr-namespace:MUXControlsTestApp.Samples">

    <mux:ItemsRepeaterScrollHost Width="180">
        <ScrollViewer>
            <mux:ItemsRepeater
                x:Name="repeater"
                HorizontalAlignment="Center"
                HorizontalCacheLength="0"
                VerticalCacheLength="0">
                <mux:ItemsRepeater.Layout>
                    <mux:FlowLayout
                        LineAlignment="Start"
                        MinRowSpacing="10"
                        MinColumnSpacing="10" />
                </mux:ItemsRepeater.Layout>
                <mux:ItemsRepeater.ItemTemplate>
                    <DataTemplate>
                        <Button
                            Width="50"
                            Content="{Binding Label}"
                            Height="{Binding Height}"
                            BorderBrush="Black"
                            BorderThickness="1" />
                    </DataTemplate>
                </mux:ItemsRepeater.ItemTemplate>
            </mux:ItemsRepeater>
        </ScrollViewer>
    </mux:ItemsRepeaterScrollHost>
</ui:Page>
