108 lines
4.3 KiB
XML
108 lines
4.3 KiB
XML
<ResourceDictionary
|
|
x:Class="BeWo.Styles.DataTemplates.DataTemplates"
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:conv="clr-namespace:BeWo.Converter"
|
|
xmlns:vm="clr-namespace:BeWo.ViewModel"
|
|
x:ClassModifier="public">
|
|
|
|
<HierarchicalDataTemplate
|
|
x:Key="ai_promptbaustein_folder_itemtemplate"
|
|
DataType="{x:Type vm:AiPromptbausteinFolderVM}"
|
|
ItemsSource="{Binding Path=SubFolders.VMList}">
|
|
<Grid Margin="0" Background="Transparent">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="Auto" />
|
|
<ColumnDefinition Width="Auto" />
|
|
<ColumnDefinition Width="*" />
|
|
<ColumnDefinition Width="Auto" />
|
|
<ColumnDefinition Width="Auto" />
|
|
</Grid.ColumnDefinitions>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="*" />
|
|
</Grid.RowDefinitions>
|
|
<Image
|
|
Name="img"
|
|
Width="16"
|
|
Height="16"
|
|
Margin="0,0,0,2"
|
|
Source="..\..\Ressources\Icons\Folder.png"
|
|
Stretch="Fill" />
|
|
<TextBox
|
|
Grid.Column="1"
|
|
Height="21"
|
|
Margin="0,0,0,0"
|
|
Padding="0,0,0,0"
|
|
VerticalAlignment="Center"
|
|
Background="Transparent"
|
|
BorderThickness="0"
|
|
Cursor="Arrow"
|
|
Focusable="False"
|
|
FontSize="12"
|
|
FontWeight="{Binding FontWeight}"
|
|
IsReadOnly="True"
|
|
Text="{Binding Path=Title, UpdateSourceTrigger=PropertyChanged, Mode=OneWay}"
|
|
ToolTipService.ShowDuration="100000">
|
|
<TextBox.ToolTip>
|
|
<StackPanel Orientation="Vertical">
|
|
<Label Content="{Binding Path=Title, Mode=OneWay}" FontWeight="Bold" />
|
|
<TextBox
|
|
MaxWidth="500"
|
|
Padding="3,1,0,0"
|
|
VerticalAlignment="Center"
|
|
AcceptsReturn="True"
|
|
Background="Transparent"
|
|
BorderThickness="0"
|
|
IsReadOnly="True"
|
|
Text="{Binding Path=Description}"
|
|
TextWrapping="Wrap" />
|
|
</StackPanel>
|
|
</TextBox.ToolTip>
|
|
</TextBox>
|
|
<Border
|
|
x:Name="border1"
|
|
Grid.Column="3"
|
|
MinWidth="24"
|
|
Margin="0,0,3,0"
|
|
Padding="3"
|
|
VerticalAlignment="Stretch"
|
|
Background="#EEEDFE"
|
|
CornerRadius="7">
|
|
<TextBlock
|
|
Margin="1,0,0,0"
|
|
HorizontalAlignment="Center"
|
|
VerticalAlignment="Center"
|
|
FontSize="10"
|
|
Text="{Binding TotalPromptCount, StringFormat={}{0}P}"
|
|
TextWrapping="Wrap" />
|
|
</Border>
|
|
|
|
<Border
|
|
x:Name="border2"
|
|
Grid.Column="4"
|
|
MinWidth="24"
|
|
Margin="0,0,3,0"
|
|
Padding="3"
|
|
VerticalAlignment="Stretch"
|
|
Background="#E1F5EE"
|
|
CornerRadius="7">
|
|
<TextBlock
|
|
Margin="1,0,0,0"
|
|
HorizontalAlignment="Center"
|
|
VerticalAlignment="Center"
|
|
FontSize="10"
|
|
Text="{Binding TotalRoutineCount, StringFormat={}{0}R}"
|
|
TextWrapping="Wrap" />
|
|
</Border>
|
|
</Grid>
|
|
<HierarchicalDataTemplate.Triggers>
|
|
<DataTrigger Binding="{Binding TotalPromptCount}" Value="0">
|
|
<Setter TargetName="border1" Property="Visibility" Value="Collapsed" />
|
|
</DataTrigger>
|
|
<DataTrigger Binding="{Binding TotalRoutineCount}" Value="0">
|
|
<Setter TargetName="border2" Property="Visibility" Value="Collapsed" />
|
|
</DataTrigger>
|
|
</HierarchicalDataTemplate.Triggers>
|
|
</HierarchicalDataTemplate>
|
|
</ResourceDictionary> |