更新整理
This commit is contained in:
60
WPFluent.Gallery/Views/Pages/Windows/WindowsPage.xaml
Normal file
60
WPFluent.Gallery/Views/Pages/Windows/WindowsPage.xaml
Normal file
@@ -0,0 +1,60 @@
|
||||
<Page
|
||||
x:Class="WPFluent.Gallery.Views.Pages.Windows.WindowsPage"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:controls="clr-namespace:WPFluent.Gallery.Controls"
|
||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||
xmlns:local="clr-namespace:WPFluent.Gallery.Views.Pages.Windows"
|
||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||
xmlns:models="clr-namespace:WPFluent.Gallery.Models"
|
||||
xmlns:ui="https://github.com/ShrlAlgo/WPFluent"
|
||||
Title="WindowsPage"
|
||||
controls:PageControlDocumentation.Show="False"
|
||||
d:DataContext="{d:DesignInstance local:WindowsPage,
|
||||
IsDesignTimeCreatable=False}"
|
||||
d:DesignHeight="450"
|
||||
d:DesignWidth="800"
|
||||
ui:Design.Background="{DynamicResource ApplicationBackgroundBrush}"
|
||||
ui:Design.Foreground="{DynamicResource TextFillColorPrimaryBrush}"
|
||||
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
|
||||
mc:Ignorable="d">
|
||||
|
||||
<Grid>
|
||||
<ItemsControl ItemsSource="{Binding ViewModel.WindowCards, Mode=OneWay}">
|
||||
<ItemsControl.ItemTemplate>
|
||||
<DataTemplate DataType="{x:Type models:WindowCard}">
|
||||
<ui:CardAction
|
||||
Margin="4"
|
||||
HorizontalAlignment="Stretch"
|
||||
VerticalAlignment="Stretch"
|
||||
Command="{Binding ViewModel.OpenWindowCommand, RelativeSource={RelativeSource Mode=FindAncestor, AncestorType=local:WindowsPage}, Mode=OneWay}"
|
||||
CommandParameter="{Binding Value, Mode=OneTime}"
|
||||
Icon="{Binding Icon, Mode=OneTime}"
|
||||
IsChevronVisible="True">
|
||||
<StackPanel>
|
||||
<ui:TextBlock
|
||||
Margin="0"
|
||||
FontTypography="BodyStrong"
|
||||
Text="{Binding Name, Mode=OneTime}"
|
||||
TextWrapping="WrapWithOverflow" />
|
||||
<ui:TextBlock
|
||||
Appearance="Tertiary"
|
||||
Text="{Binding Description, Mode=OneTime}"
|
||||
TextWrapping="WrapWithOverflow" />
|
||||
</StackPanel>
|
||||
</ui:CardAction>
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
<ItemsControl.ItemsPanel>
|
||||
<ItemsPanelTemplate>
|
||||
<ui:VirtualizingWrapPanel
|
||||
IsItemsHost="True"
|
||||
ItemSize="290,80"
|
||||
Orientation="Vertical"
|
||||
SpacingMode="Uniform"
|
||||
StretchItems="True" />
|
||||
</ItemsPanelTemplate>
|
||||
</ItemsControl.ItemsPanel>
|
||||
</ItemsControl>
|
||||
</Grid>
|
||||
</Page>
|
||||
Reference in New Issue
Block a user