Closed enisn closed 2 months ago
Not the following syntax works as expected:
<material:InputField Title="test" HasValue="True" Margin="60"> <uranium:ExpanderView IsEnabled="True"> <uranium:ExpanderView.Header> <Label Margin="10" FontAttributes="Bold" Text="TreeView Expander" /> </uranium:ExpanderView.Header> <material:TreeView MinimumHeightRequest="120" SelectionMode="Multiple" x:Name="treeView" ItemsSource="{Binding Nodes}" LoadChildrenCommand="{Binding LoadChildrenCommand}" IsLeafPropertyName="IsLeaf"> <material:TreeView.ItemTemplate> <DataTemplate> <HorizontalStackLayout Spacing="5" VerticalOptions="Center"> <Image> <Image.Triggers> <DataTrigger TargetType="Image" Binding="{Binding IsDirectory}" Value="True"> <Setter Property="Source" Value="{FontImageSource FontFamily=MaterialSharp, Glyph={x:Static m:MaterialSharp.Folder}, Color={AppThemeBinding Light={StaticResource Primary}, Dark={StaticResource PrimaryDark}}}" /> </DataTrigger> <DataTrigger TargetType="Image" Binding="{Binding IsDirectory}" Value="False"> <Setter Property="Source" Value="{FontImageSource FontFamily=MaterialSharp, Glyph={x:Static m:MaterialSharp.File_open}, Color={AppThemeBinding Light={StaticResource Primary}, Dark={StaticResource PrimaryDark}}}" /> </DataTrigger> </Image.Triggers> </Image> <Label Text="{Binding Name}" FontAttributes="Bold" VerticalOptions="Center" /> </HorizontalStackLayout> </DataTemplate> </material:TreeView.ItemTemplate> </material:TreeView> </uranium:ExpanderView> </material:InputField>
Not the following syntax works as expected: