55 xmlns : controls =" using:Microsoft.Toolkit.Uwp.UI.Controls"
66 xmlns : d =" http://schemas.microsoft.com/expression/blend/2008"
77 xmlns : local =" using:Files"
8+ xmlns : muxc =" using:Microsoft.UI.Xaml.Controls"
89 xmlns : mc =" http://schemas.openxmlformats.org/markup-compatibility/2006"
910 Background =" {ThemeResource ApplicationPageBackgroundThemeBrush}"
1011 mc : Ignorable =" d" >
11- <UserControl .Resources>
12- <Style
13- x : Key =" AdaptiveGridViewItemContainerStyle2"
14- BasedOn =" {StaticResource GridViewItemExpanded}"
15- TargetType =" GridViewItem" >
16- <Setter Property =" Background" Value =" Transparent" />
17- <Setter Property =" BorderThickness" Value =" 0" />
18- <Setter Property =" CornerRadius" Value =" 4" />
19- <Setter Property =" HorizontalContentAlignment" Value =" Stretch" />
20- <Setter Property =" VerticalContentAlignment" Value =" Stretch" />
21- <Setter Property =" Margin" Value =" 0,0,8,0" />
22- </Style >
23- </UserControl .Resources>
24-
2512 <Grid >
26- <controls : AdaptiveGridView
13+ <muxc : ItemsRepeater
2714 x : Name =" CardsList"
2815 Grid.Row=" 0"
2916 HorizontalAlignment =" Stretch"
30- DesiredWidth =" 100"
31- IsItemClickEnabled =" True"
32- ItemContainerStyle =" {StaticResource AdaptiveGridViewItemContainerStyle2}"
33- ItemHeight =" 90"
34- ItemsSource =" {x:Bind local:LibraryCards.itemsAdded}"
35- OneRowModeEnabled =" True"
36- ScrollViewer.HorizontalScrollBarVisibility=" Hidden"
37- SelectionMode =" None"
38- StretchContentForSingleRow =" True" >
39- <controls : AdaptiveGridView .ItemTemplate>
17+ ItemsSource =" {x:Bind local:LibraryCards.itemsAdded}" >
18+ <muxc : ItemsRepeater .Layout>
19+ <muxc : UniformGridLayout ItemsStretch =" Fill" Orientation =" Horizontal" MinItemWidth =" 100" MaximumRowsOrColumns =" 5" MinItemHeight =" 90" MinRowSpacing =" 8" MinColumnSpacing =" 8" />
20+ </muxc : ItemsRepeater .Layout>
21+ <muxc : ItemsRepeater .ItemTemplate>
4022 <DataTemplate x : DataType =" local:FavoriteLocationItem" >
4123 <Grid >
42- <Grid >
43- <Grid .Resources>
44- <ResourceDictionary >
45- <ResourceDictionary .ThemeDictionaries>
46- <ResourceDictionary x : Name =" Light" >
47- <SolidColorBrush x : Key =" YourHomeCardBackgroundColor" Color =" #f3f1ef" />
48- </ResourceDictionary >
49- <ResourceDictionary x : Name =" Dark" >
50- <SolidColorBrush x : Key =" YourHomeCardBackgroundColor" Color =" Black" />
51- </ResourceDictionary >
52- <ResourceDictionary x : Name =" HighContrast" >
53- <SolidColorBrush x : Key =" YourHomeCardBackgroundColor" Color =" Black" />
54- </ResourceDictionary >
55- </ResourceDictionary .ThemeDictionaries>
56- </ResourceDictionary >
57- </Grid .Resources>
58- <Button
24+ <Grid .Resources>
25+ <ResourceDictionary >
26+ <ResourceDictionary .ThemeDictionaries>
27+ <ResourceDictionary x : Name =" Light" >
28+ <SolidColorBrush x : Key =" YourHomeCardBackgroundColor" Color =" #f3f1ef" />
29+ </ResourceDictionary >
30+ <ResourceDictionary x : Name =" Dark" >
31+ <SolidColorBrush x : Key =" YourHomeCardBackgroundColor" Color =" Black" />
32+ </ResourceDictionary >
33+ <ResourceDictionary x : Name =" HighContrast" >
34+ <SolidColorBrush x : Key =" YourHomeCardBackgroundColor" Color =" Black" />
35+ </ResourceDictionary >
36+ </ResourceDictionary .ThemeDictionaries>
37+ </ResourceDictionary >
38+ </Grid .Resources>
39+ <Button
5940 Padding =" 0"
6041 HorizontalAlignment =" Stretch"
6142 VerticalAlignment =" Stretch"
6849 Style =" {StaticResource ButtonRevealStyle}"
6950 Tag =" {x:Bind Tag}" >
7051
71- <Grid
52+ <Grid
7253 Margin =" 8,14"
7354 HorizontalAlignment =" Stretch"
7455 VerticalAlignment =" Stretch"
7556 RowSpacing =" 2" >
76- <Grid .RowDefinitions>
77- <RowDefinition Height =" *" />
78- <RowDefinition Height =" Auto" />
79- </Grid .RowDefinitions>
80- <FontIcon
57+ <Grid .RowDefinitions>
58+ <RowDefinition Height =" *" />
59+ <RowDefinition Height =" Auto" />
60+ </Grid .RowDefinitions>
61+ <FontIcon
8162 Grid.Row=" 0"
8263 HorizontalAlignment =" Stretch"
8364 VerticalAlignment =" Stretch"
8465 FontFamily =" {StaticResource FluentUIGlyphs}"
8566 FontSize =" 28"
8667 Glyph =" {x:Bind Icon}" />
87- <TextBlock
68+ <TextBlock
8869 x : Name =" ItemLocationName"
8970 Grid.Row=" 1"
9071 HorizontalAlignment =" Stretch"
9475 HorizontalTextAlignment =" Center"
9576 Text =" {x:Bind Text}"
9677 TextWrapping =" WrapWholeWords" />
97- </Grid >
98- </Button >
99- </Grid >
78+ </Grid >
79+ </Button >
10080 </Grid >
10181 </DataTemplate >
102- </controls : AdaptiveGridView .ItemTemplate>
103- </controls : AdaptiveGridView >
82+ </muxc : ItemsRepeater .ItemTemplate>
83+ </muxc : ItemsRepeater >
10484 </Grid >
10585</UserControl >
0 commit comments