Skip to content

Commit

Permalink
changes for v11
Browse files Browse the repository at this point in the history
  • Loading branch information
PieroCastillo committed Jan 29, 2024
1 parent 658de73 commit 2ecdeb1
Show file tree
Hide file tree
Showing 12 changed files with 305 additions and 276 deletions.
40 changes: 17 additions & 23 deletions src/Aura.UI.FluentTheme/Controls/AuraTabItemStyles.xaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Styles xmlns="https://github.com/avaloniaui"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:i="using:Avalonia.Xaml.Interactivity"
xmlns:b="using:Avalonia.Xaml.Interactivity.Draggable">
xmlns:id="using:Avalonia.Xaml.Interactions.Draggable">
<Design.PreviewWith>
<AuraTabView TabStripPlacement="Right">
<AuraTabItem Header="Hello"
Expand Down Expand Up @@ -51,7 +51,7 @@
<Setter Property="(i:Interaction.Behaviors)">
<i:BehaviorCollectionTemplate>
<i:BehaviorCollection>
<b:ItemDragBehavior Orientation="Horizontal" />
<id:ItemDragBehavior Orientation="Horizontal" />
</i:BehaviorCollection>
</i:BehaviorCollectionTemplate>
</Setter>
Expand Down Expand Up @@ -112,13 +112,11 @@
<Style Selector="AuraTabItem[TabStripPlacement=Bottom]">
<Setter Property="CornerRadius" Value="0,0,7,7" />
<Setter Property="(i:Interaction.Behaviors)">
<b:SharedContentTemplate>
<b:SharedContent>
<i:BehaviorCollection>
<b:ItemDragBehavior Orientation="Horizontal"/>
</i:BehaviorCollection>
</b:SharedContent>
</b:SharedContentTemplate>
<i:BehaviorCollectionTemplate>
<i:BehaviorCollection>
<id:ItemDragBehavior Orientation="Horizontal" />
</i:BehaviorCollection>
</i:BehaviorCollectionTemplate>
</Setter>
<Setter Property="Template">
<ControlTemplate>
Expand Down Expand Up @@ -169,13 +167,11 @@
<Style Selector="AuraTabItem[TabStripPlacement=Left]">
<Setter Property="CornerRadius" Value="7,0,0,7" />
<Setter Property="(i:Interaction.Behaviors)">
<b:SharedContentTemplate>
<b:SharedContent>
<i:BehaviorCollection>
<b:ItemDragBehavior Orientation="Vertical"/>
</i:BehaviorCollection>
</b:SharedContent>
</b:SharedContentTemplate>
<i:BehaviorCollectionTemplate>
<i:BehaviorCollection>
<id:ItemDragBehavior Orientation="Vertical" />
</i:BehaviorCollection>
</i:BehaviorCollectionTemplate>
</Setter>
<Setter Property="Template">
<ControlTemplate>
Expand Down Expand Up @@ -239,13 +235,11 @@
<Style Selector="AuraTabItem[TabStripPlacement=Right]">
<Setter Property="CornerRadius" Value="0,7,7,0" />
<Setter Property="(i:Interaction.Behaviors)">
<b:SharedContentTemplate>
<b:SharedContent>
<i:BehaviorCollection>
<b:ItemDragBehavior Orientation="Vertical"/>
</i:BehaviorCollection>
</b:SharedContent>
</b:SharedContentTemplate>
<i:BehaviorCollectionTemplate>
<i:BehaviorCollection>
<id:ItemDragBehavior Orientation="Vertical" />
</i:BehaviorCollection>
</i:BehaviorCollectionTemplate>
</Setter>
<Setter Property="Template">
<ControlTemplate>
Expand Down
58 changes: 28 additions & 30 deletions src/Aura.UI.FluentTheme/Controls/AuraTabViewStyles.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,19 @@
</DrawingImage>
</Styles.Resources>
<Style Selector="AuraTabView">
<Setter Property="Background" Value="{DynamicResource AuraTabViewBackground}"/>
<Setter Property="Background" Value="{DynamicResource AuraTabViewBackground}"/>
<Setter Property="SecondaryBackground" Value="Transparent"/>
</Style>
<Style Selector="AuraTabView /template/ ContentPresenter#PART_FallBackContent">
<Setter Property="IsVisible" Value="false"/>
</Style>
<Style Selector="AuraTabView:empty /template/ ContentPresenter#PART_FallBackContent">
<Style Selector="AuraTabView /template/ ContentPresenter#PART_HeaderPresenter">
<Setter Property="FontSize" Value="15"/>
</Style>
<Style Selector="AuraTabView /template/ ContentPresenter#PART_FooterPresenter">
<Setter Property="FontSize" Value="15"/>
</Style>
<Style Selector="AuraTabView:empty /template/ ContentPresenter#PART_FallBackContent">
<Setter Property="IsVisible" Value="True"/>
</Style>
<Style Selector="Border#PART_InternalBorder">
Expand Down Expand Up @@ -73,10 +79,10 @@
Width="{TemplateBinding Width}"
ColumnDefinitions="auto,auto,*,auto">
<!--Header-->
<ContentPresenter Grid.Column="0"
Content="{TemplateBinding Header}"
<ContentPresenter Name="PART_HeaderPresenter"
Grid.Column="0"
Content="{TemplateBinding Header}"
ContentTemplate="{TemplateBinding HeaderTemplate}"
TextBlock.FontSize="15"
TextBlock.Foreground="{DynamicResource ThemeForegroundBrush}"
VerticalContentAlignment="Center"
Margin="5, 0"
Expand All @@ -89,9 +95,7 @@
</Grid.ColumnDefinitions>
<ItemsPresenter Grid.Column="0"
Name="PART_ItemsPresenter"
Items="{TemplateBinding Items}"
ItemsPanel="{TemplateBinding ItemsPanel}"
ItemTemplate="{TemplateBinding ItemTemplate}"
HorizontalAlignment="Left"
MaxWidth="{TemplateBinding MaxWidthOfItemsPresenter}">
<ItemsPresenter.Transitions>
Expand Down Expand Up @@ -128,10 +132,10 @@
</Border>
</Grid>
<!--Footer-->
<ContentPresenter Grid.Column="3"
Content="{TemplateBinding Footer}"
<ContentPresenter Name="PART_FooterPresenter"
Grid.Column="3"
Content="{TemplateBinding Footer}"
ContentTemplate="{TemplateBinding FooterTemplate}"
TextBlock.FontSize="15"
TextBlock.Foreground="{DynamicResource ThemeForegroundLowBrush}"
VerticalContentAlignment="Center"
Margin="5,0"
Expand Down Expand Up @@ -187,10 +191,10 @@
Background="{TemplateBinding SecondaryBackground}"
Width="{TemplateBinding Width}" ColumnDefinitions="auto,auto,*,auto">
<!--Header-->
<ContentPresenter Grid.Column="0"
Content="{TemplateBinding Header}"
<ContentPresenter Name="PART_HeaderPresenter"
Grid.Column="0"
Content="{TemplateBinding Header}"
ContentTemplate="{TemplateBinding HeaderTemplate}"
TextBlock.FontSize="15"
TextBlock.Foreground="{DynamicResource ThemeForegroundBrush}"
VerticalContentAlignment="Center"
Margin="5, 0"
Expand All @@ -203,9 +207,7 @@
</Grid.ColumnDefinitions>
<ItemsPresenter Grid.Column="0"
Name="PART_ItemsPresenter"
Items="{TemplateBinding Items}"
ItemsPanel="{TemplateBinding ItemsPanel}"
ItemTemplate="{TemplateBinding ItemTemplate}"
HorizontalAlignment="Left"
MaxWidth="{TemplateBinding MaxWidthOfItemsPresenter}">
<ItemsPresenter.Transitions>
Expand Down Expand Up @@ -240,10 +242,10 @@
</Grid>

<!--Footer-->
<ContentPresenter Grid.Column="3"
<ContentPresenter Name="PART_FooterPresenter"
Grid.Column="3"
Content="{TemplateBinding Footer}"
ContentTemplate="{TemplateBinding FooterTemplate}"
TextBlock.FontSize="15"
TextBlock.Foreground="{DynamicResource ThemeForegroundLowBrush}"
VerticalContentAlignment="Center"
Margin="5,0"
Expand Down Expand Up @@ -300,9 +302,9 @@
Name="PART_DockContainer"
Height="{Binding $parent[AuraTabView].Bounds.Height}">
<!--Header-->
<ContentPresenter Content="{TemplateBinding Header}"
<ContentPresenter Name="PART_HeaderPresenter"
Content="{TemplateBinding Header}"
ContentTemplate="{TemplateBinding HeaderTemplate}"
TextBlock.FontSize="15"
TextBlock.Foreground="{DynamicResource ThemeForegroundBrush}"
VerticalContentAlignment="Center"
Margin="5, 5"
Expand All @@ -313,9 +315,7 @@
RowDefinitions="*,auto">
<ItemsPresenter Grid.Row="0"
Name="PART_ItemsPresenter"
Items="{TemplateBinding Items}"
ItemsPanel="{TemplateBinding ItemsPanel}"
ItemTemplate="{TemplateBinding ItemTemplate}"
HorizontalAlignment="Left" VerticalAlignment="Top"
MaxHeight="{TemplateBinding MaxWidthOfItemsPresenter}">
<ItemsPresenter.Transitions>
Expand Down Expand Up @@ -350,9 +350,9 @@
</Grid>

<!--Footer-->
<ContentPresenter Grid.Row="3" Content="{TemplateBinding Footer}"
<ContentPresenter Name="PART_FooterPresenter"
Grid.Row="3" Content="{TemplateBinding Footer}"
ContentTemplate="{TemplateBinding FooterTemplate}"
TextBlock.FontSize="15"
TextBlock.Foreground="{DynamicResource ThemeForegroundLowBrush}"
VerticalContentAlignment="Center"
Margin="5,5"
Expand Down Expand Up @@ -410,10 +410,10 @@
Height="{TemplateBinding Height}"
RowDefinitions="auto,auto,*,auto">
<!--Header-->
<ContentPresenter Grid.Row="0"
Content="{TemplateBinding Header}"
<ContentPresenter Name="PART_HeaderPresenter"
Grid.Row="0"
Content="{TemplateBinding Header}"
ContentTemplate="{TemplateBinding HeaderTemplate}"
TextBlock.FontSize="15"
TextBlock.Foreground="{DynamicResource ThemeForegroundBrush}"
VerticalContentAlignment="Center"
Margin="5, 5"
Expand All @@ -425,9 +425,7 @@
RowDefinitions="*,auto">
<ItemsPresenter Grid.Row="0"
Name="PART_ItemsPresenter"
Items="{TemplateBinding Items}"
ItemsPanel="{TemplateBinding ItemsPanel}"
ItemTemplate="{TemplateBinding ItemTemplate}"
HorizontalAlignment="Left"
MaxWidth="{TemplateBinding MaxWidthOfItemsPresenter}">
<ItemsPresenter.Transitions>
Expand Down Expand Up @@ -461,9 +459,9 @@
</Border>
</Grid>
<!--Footer-->
<ContentPresenter Grid.Row="3" Content="{TemplateBinding Footer}"
<ContentPresenter Name="PART_FooterPresenter"
Grid.Row="3" Content="{TemplateBinding Footer}"
ContentTemplate="{TemplateBinding FooterTemplate}"
TextBlock.FontSize="15"
TextBlock.Foreground="{DynamicResource ThemeForegroundLowBrush}"
VerticalContentAlignment="Center"
Margin="5,5"
Expand Down
13 changes: 6 additions & 7 deletions src/Aura.UI.FluentTheme/Controls/CardCollectionStyles.xaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
<Styles xmlns="https://github.com/avaloniaui"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<Style Selector="CardCollection /template/ ContentPresenter#PART_HeaderPresenter">
<Setter Property="FontSize" Value="15"/>
<Setter Property="FontWeight" Value="Bold"/>
</Style>
<Style Selector="CardCollection">
<Setter Property="Header" Value="CardCollection" />
<Setter Property="Padding" Value="{DynamicResource CardCollectionPadding}" />
Expand All @@ -8,17 +12,12 @@
<Border Padding="{TemplateBinding Padding}">
<Grid RowDefinitions="Auto,*">
<ContentPresenter Name="PART_HeaderPresenter"
Content="{TemplateBinding Header}"
TextBlock.FontWeight="Bold"
TextBlock.FontSize="18" />
Content="{TemplateBinding Header}" />
<ScrollViewer Grid.Row="1"
HorizontalScrollBarVisibility="Auto"
VerticalScrollBarVisibility="Auto">
<ItemsPresenter
Items="{TemplateBinding Items}"
ItemsPanel="{TemplateBinding ItemsPanel}"
ItemTemplate="{TemplateBinding ItemTemplate}"
VirtualizationMode="{TemplateBinding VirtualizationMode}"/>
ItemsPanel="{TemplateBinding ItemsPanel}" />
</ScrollViewer>
</Grid>
</Border>
Expand Down
15 changes: 10 additions & 5 deletions src/Aura.UI.FluentTheme/Controls/CardControlStyles.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@
</CardControl>
</Border>
</Design.PreviewWith>
<Style Selector="CardControl /template/ ContentPresenter#PART_HeaderPresenter">
<Setter Property="FontSize" Value="18"/>
</Style>
<Style Selector="CardControl /template/ ContentPresenter#PART_SecondaryHeaderPresenter">
<Setter Property="Foreground" Value="{DynamicResource SystemControlBackgroundBaseMediumHighBrush}"/>
</Style>
<Style Selector="CardControl">
<Setter Property="Padding" Value="10" />
<Setter Property="Width" Value="200"/>
Expand Down Expand Up @@ -43,12 +49,11 @@
Grid.Row="1"
Name="PART_HeaderPresenter"
Content="{TemplateBinding Header}"
ContentTemplate="{TemplateBinding HeaderTemplate}"
TextBlock.FontSize="18" />
<ContentPresenter Grid.Column="1"
ContentTemplate="{TemplateBinding HeaderTemplate}"/>
<ContentPresenter Name="PART_SecondaryHeaderPresenter"
Grid.Column="1"
Grid.Row="3"
Content="{TemplateBinding SecondaryHeader}"
TextBlock.Foreground="{DynamicResource SystemControlBackgroundBaseMediumHighBrush}" />
Content="{TemplateBinding SecondaryHeader}" />
</Grid>
</ExperimentalAcrylicBorder>
</Border>
Expand Down
4 changes: 0 additions & 4 deletions src/Aura.UI.FluentTheme/Controls/FloatingButtonBar.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@
</ToggleButton>
<ItemsPresenter Grid.Column="1"
Name="PART_ItemsPresenter"
Items="{TemplateBinding Items}"
ItemsPanel="{TemplateBinding ItemsPanel}">
<ItemsPresenter.Transitions>
<Transitions>
Expand Down Expand Up @@ -115,7 +114,6 @@
<ControlTemplate>
<Grid ColumnDefinitions="*,auto">
<ItemsPresenter Name="PART_ItemsPresenter"
Items="{TemplateBinding Items}"
ItemsPanel="{TemplateBinding ItemsPanel}"
HorizontalAlignment="Right">
<!--<ItemsPresenter.Transitions>
Expand Down Expand Up @@ -183,7 +181,6 @@
<ControlTemplate>
<Grid RowDefinitions="*,auto" ColumnDefinitions="auto">
<ItemsPresenter Name="PART_ItemsPresenter"
Items="{TemplateBinding Items}"
ItemsPanel="{TemplateBinding ItemsPanel}">
<!--<ItemsPresenter.Transitions>
<Transitions>
Expand Down Expand Up @@ -263,7 +260,6 @@
</ToggleButton.RenderTransform>
</ToggleButton>
<ItemsPresenter Grid.Row="1" Name="PART_ItemsPresenter"
Items="{TemplateBinding Items}"
ItemsPanel="{TemplateBinding ItemsPanel}">
<!--<ItemsPresenter.Transitions>
<Transitions>
Expand Down
32 changes: 18 additions & 14 deletions src/Aura.UI.FluentTheme/Controls/MessageDialogStyles.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
<GeometryDrawing Brush="#FFCC00" Geometry="M8.44 1H7.56L1 13.26L1.44 14H14.54L14.98 13.26L8.44 1ZM2.28 13L8 2.28L13.7 13H2.28ZM7.5 6H8.5V10H7.5V6ZM7.5 11H8.5V12H7.5V11Z" />
</DrawingImage>
</Styles.Resources>

<Style Selector="MessageDialog">
<Setter Property="Background" Value="{DynamicResource MessageDialogBackground}" />
<Setter Property="BorderBrush" Value="{DynamicResource MessageDialogBorderBrush}"/>
Expand Down Expand Up @@ -55,32 +56,35 @@
Grid.Column="1"
ColumnDefinitions="*,10,auto">
<ContentPresenter Name="PART_TitlePresenter"
Content="{TemplateBinding Title}"
TextBlock.FontSize="25"
TextBlock.FontWeight="DemiBold" />
<Button Grid.Column="2" Padding="3"
Name="PART_ButtonClose"
VerticalAlignment="Top"
HorizontalAlignment="Right"
Margin="0"
Width="15" Height="15">
Content="{TemplateBinding Title}" />
<Button Grid.Column="2" Padding="3"
Name="PART_ButtonClose"
VerticalAlignment="Top"
HorizontalAlignment="Right"
Margin="0"
Width="15" Height="15">
<Image Source="{DynamicResource EvaIcons.CloseOutline}" />
</Button>
</Grid>
<ContentPresenter Grid.Row="2"
Grid.Column="1"
Name="PART_ContentPresenter"
Content="{TemplateBinding Content}"
ContentTemplate="{TemplateBinding ContentTemplate}"
TextBlock.FontWeight="Medium" />
Name="PART_ContentPresenter"
Content="{TemplateBinding Content}"
ContentTemplate="{TemplateBinding ContentTemplate}"/>
</Grid>
</Grid>
</Border>
</Grid>
</ControlTemplate>
</Setter>
</Style>

<Style Selector="MessageDialog /template/ ContentPresenter#PART_TitlePresenter">
<Setter Property="FontSize" Value="25"/>
<Setter Property="FontWeight" Value="DemiBold"/>
</Style>
<Style Selector="MessageDialog /template/ ContentPresenter#PART_ContentPresenter">
<Setter Property="FontWeight" Value="Medium"/>
</Style>
<!--this animation is some strange...-->
<!--<Style Selector="MessageDialog /template/ Border#PART_Border">
<Style.Animations>
Expand Down
Loading

0 comments on commit 2ecdeb1

Please sign in to comment.