ux: new style for Flyout

This commit is contained in:
leo 2024-08-27 16:28:20 +08:00
parent b16d267c9b
commit 64943044aa
No known key found for this signature in database

View file

@ -191,6 +191,38 @@
<Style Selector="FlyoutPresenter"> <Style Selector="FlyoutPresenter">
<Setter Property="MaxWidth" Value="1024"/> <Setter Property="MaxWidth" Value="1024"/>
<Setter Property="MaxHeight" Value="768"/> <Setter Property="MaxHeight" Value="768"/>
<Setter Property="Padding" Value="0"/>
<Setter Property="Template">
<ControlTemplate>
<Grid>
<Border Background="{DynamicResource Brush.Popup}" BorderThickness="0" Margin="4" CornerRadius="{TemplateBinding CornerRadius}">
<Border.Effect>
<DropShadowEffect OffsetX="0" OffsetY="0" BlurRadius="4" Color="Black" Opacity=".6"/>
</Border.Effect>
</Border>
<Border Name="LayoutRoot"
Margin="4"
Padding="12"
Background="{DynamicResource Brush.Popup}"
BorderThickness="0"
CornerRadius="{TemplateBinding CornerRadius}">
<ScrollViewer HorizontalScrollBarVisibility="{TemplateBinding ScrollViewer.HorizontalScrollBarVisibility}"
VerticalScrollBarVisibility="{TemplateBinding ScrollViewer.VerticalScrollBarVisibility}">
<ContentPresenter x:Name="PART_ContentPresenter"
Content="{TemplateBinding Content}"
ContentTemplate="{TemplateBinding ContentTemplate}"
Margin="0"
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
HorizontalContentAlignment="Stretch"
VerticalContentAlignment="Stretch" />
</ScrollViewer>
</Border>
</Grid>
</ControlTemplate>
</Setter>
</Style> </Style>
<Style Selector="Path"> <Style Selector="Path">