using Avalonia.Controls;
using Avalonia.Controls.Primitives;
using Avalonia.Media;
using SukiUI.Controls;

namespace FootwearTest.Views
{
    public partial class MainWindow : SukiWindow
    {
        public MainWindow()
        {
            InitializeComponent();
        }

        protected override void OnApplyTemplate(TemplateAppliedEventArgs e)
        {
            base.OnApplyTemplate(e);

            var titleBarBackground = e.NameScope.Find<GlassCard>("PART_TitleBarBackground");
            if (titleBarBackground is not null)
            {
                titleBarBackground.IsOpaque = true;
                titleBarBackground.IsAnimated = false;
                titleBarBackground.BorderThickness = new Avalonia.Thickness(0);
            }

            var dragArea = e.NameScope.Find<Border>("DragArea");
            if (dragArea is not null)
            {
                dragArea.Background = SolidColorBrush.Parse("#EEF4F3");
            }
        }
    }
}
