feat(ui): pulse, hover, modal, and row-add animations
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -7,7 +7,8 @@
|
||||
<StackPanel Margin="14,12" Spacing="6">
|
||||
<!-- Row 1: status dot · status label · model · turns · tokens -->
|
||||
<StackPanel Orientation="Horizontal" Spacing="10">
|
||||
<Ellipse Width="8" Height="8" Fill="{DynamicResource MossBrush}" VerticalAlignment="Center"/>
|
||||
<Ellipse Width="8" Height="8" Fill="{DynamicResource MossBrush}" VerticalAlignment="Center"
|
||||
Classes.status-pulse="{Binding IsRunning}"/>
|
||||
<TextBlock Text="{Binding AgentStatusLabel}" FontSize="12"
|
||||
Foreground="{DynamicResource TextBrush}" VerticalAlignment="Center"/>
|
||||
<TextBlock Text="{Binding Model}" FontFamily="{DynamicResource MonoFamily}"
|
||||
|
||||
@@ -1,8 +1,33 @@
|
||||
using Avalonia;
|
||||
using Avalonia.Animation;
|
||||
using Avalonia.Animation.Easings;
|
||||
using Avalonia.Controls;
|
||||
using Avalonia.Media;
|
||||
using Avalonia.Styling;
|
||||
|
||||
namespace ClaudeDo.Ui.Views.Islands;
|
||||
|
||||
public partial class TaskRowView : UserControl
|
||||
{
|
||||
public TaskRowView() { InitializeComponent(); }
|
||||
|
||||
protected override async void OnAttachedToVisualTree(VisualTreeAttachmentEventArgs e)
|
||||
{
|
||||
base.OnAttachedToVisualTree(e);
|
||||
RenderTransform = new TranslateTransform(0, 8);
|
||||
Opacity = 0;
|
||||
var anim = new Avalonia.Animation.Animation
|
||||
{
|
||||
Duration = TimeSpan.FromMilliseconds(300),
|
||||
Easing = new CubicEaseOut(),
|
||||
Children =
|
||||
{
|
||||
new KeyFrame { Cue = new Cue(0), Setters = { new Setter(OpacityProperty, 0d) } },
|
||||
new KeyFrame { Cue = new Cue(1), Setters = { new Setter(OpacityProperty, 1d) } },
|
||||
}
|
||||
};
|
||||
await anim.RunAsync(this);
|
||||
Opacity = 1;
|
||||
RenderTransform = null;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user