chore: add avalonia border demo.
This commit is contained in:
1 parent
40bb60164e
commit
17c2b8473b
8 files changed
+248
-73
No files matched your search
@@ -16,7 +16,7 @@
|
||||
Grid.Row="0"
|
||||
CornerRadius="10,10,0,0"
|
||||
Background="{DynamicResource TitleBrush}"
|
||||
Classes="clip">
|
||||
Theme="{StaticResource BorderClip}">
|
||||
<Panel>
|
||||
<TextBlock Foreground="White"
|
||||
HorizontalAlignment="Center"
|
||||
|
||||
@@ -0,0 +1,89 @@
|
||||
<UserControl xmlns="https://github.com/avaloniaui"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:hc="https://handyorg.github.io/handycontrol"
|
||||
x:Class="HandyControlDemo.UserControl.BorderDemoCtl"
|
||||
Background="{DynamicResource RegionBrush}">
|
||||
<ScrollViewer>
|
||||
<hc:UniformSpacingPanel Margin="32"
|
||||
Orientation="Vertical"
|
||||
Spacing="32"
|
||||
MaxWidth="664">
|
||||
<hc:UniformSpacingPanel Spacing="32"
|
||||
ItemWidth="200"
|
||||
ItemHeight="200"
|
||||
ChildWrapping="Wrap"
|
||||
HorizontalAlignment="Center">
|
||||
<Border Theme="{StaticResource BorderRegion}">
|
||||
<Border Background="{DynamicResource PrimaryBrush}">
|
||||
<TextBlock Text="Content"
|
||||
VerticalAlignment="Center"
|
||||
HorizontalAlignment="Center"
|
||||
Foreground="White" />
|
||||
</Border>
|
||||
</Border>
|
||||
<Border Theme="{StaticResource BorderRegion}"
|
||||
Effect="{StaticResource EffectShadow1}">
|
||||
<Border Background="{DynamicResource InfoBrush}">
|
||||
<TextBlock Text="Content"
|
||||
VerticalAlignment="Center"
|
||||
HorizontalAlignment="Center"
|
||||
Foreground="White" />
|
||||
</Border>
|
||||
</Border>
|
||||
<Border Theme="{StaticResource BorderRegion}"
|
||||
Effect="{StaticResource EffectShadow2}">
|
||||
<Border Background="{DynamicResource WarningBrush}">
|
||||
<TextBlock Text="Content"
|
||||
VerticalAlignment="Center"
|
||||
HorizontalAlignment="Center"
|
||||
Foreground="White" />
|
||||
</Border>
|
||||
</Border>
|
||||
<Border Theme="{StaticResource BorderRegion}"
|
||||
Effect="{StaticResource EffectShadow3}">
|
||||
<Border Background="{DynamicResource DangerBrush}">
|
||||
<TextBlock Text="Content"
|
||||
VerticalAlignment="Center"
|
||||
HorizontalAlignment="Center"
|
||||
Foreground="White" />
|
||||
</Border>
|
||||
</Border>
|
||||
<Border Theme="{StaticResource BorderRegion}"
|
||||
Effect="{StaticResource EffectShadow4}">
|
||||
<Border Background="{DynamicResource AccentBrush}">
|
||||
<TextBlock Text="Content"
|
||||
VerticalAlignment="Center"
|
||||
HorizontalAlignment="Center"
|
||||
Foreground="White" />
|
||||
</Border>
|
||||
</Border>
|
||||
<Border Theme="{StaticResource BorderRegion}"
|
||||
Effect="{StaticResource EffectShadow5}">
|
||||
<Border Background="{DynamicResource BorderBrush}">
|
||||
<TextBlock Text="Content"
|
||||
VerticalAlignment="Center"
|
||||
HorizontalAlignment="Center" />
|
||||
</Border>
|
||||
</Border>
|
||||
</hc:UniformSpacingPanel>
|
||||
<hc:UniformSpacingPanel Orientation="Vertical"
|
||||
Spacing="10">
|
||||
<Border Theme="{StaticResource BorderTipPrimary}">
|
||||
<TextBlock Text="TitleTitleTitleTitleTitleTitleTitleTitleTitleTitle" />
|
||||
</Border>
|
||||
<Border Theme="{StaticResource BorderTipDanger}">
|
||||
<TextBlock Text="TitleTitleTitleTitleTitleTitleTitleTitleTitleTitle" />
|
||||
</Border>
|
||||
<Border Theme="{StaticResource BorderTipWarning}">
|
||||
<TextBlock Text="TitleTitleTitleTitleTitleTitleTitleTitleTitleTitle" />
|
||||
</Border>
|
||||
<Border Theme="{StaticResource BorderTipInfo}">
|
||||
<TextBlock Text="TitleTitleTitleTitleTitleTitleTitleTitleTitleTitle" />
|
||||
</Border>
|
||||
<Border Theme="{StaticResource BorderTipSuccess}">
|
||||
<TextBlock Text="TitleTitleTitleTitleTitleTitleTitleTitleTitleTitle" />
|
||||
</Border>
|
||||
</hc:UniformSpacingPanel>
|
||||
</hc:UniformSpacingPanel>
|
||||
</ScrollViewer>
|
||||
</UserControl>
|
||||
@@ -0,0 +1,9 @@
|
||||
namespace HandyControlDemo.UserControl;
|
||||
|
||||
public partial class BorderDemoCtl : Avalonia.Controls.UserControl
|
||||
{
|
||||
public BorderDemoCtl()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user