Free, open-source file converter. Convert 263 formats offline by drag & drop — images, PDF, Word, Excel, PowerPoint, HWP/HWPX, video, audio, e-books and archives. No upload, no Office needed.
C# audio-converteravaloniabatch-conversionconvertercsharpdocument-converterdocx-to-pdfdotnetdrag-and-dropfile-conversionfile-converterheic-converterhwphwpximage-converterlinuxmacospdf-convertervideo-converterwindows
Leave the Material You style and the control restyle out
KnifeLemon125de1cb70f4
diff --git a/src/Filee.App/Assets/i18n/en.json b/src/Filee.App/Assets/i18n/en.jsonindex 7d7c7d9d..87e01d60 100644--- a/src/Filee.App/Assets/i18n/en.json+++ b/src/Filee.App/Assets/i18n/en.json@@ -594,18 +594,12 @@"presets.select": "Select a preset to edit it","theme.title": "Theme",- "theme.style": "Theme style",- "theme.style.Soft": "Filee Soft",- "theme.style.MaterialYou": "Material You",- "theme.style.soft_hint": "Classic Filee look with soft rounded corners and pastel surfaces.",- "theme.style.material_you_hint": "Google Material 3 design with dynamic tonal palettes, pill shapes, and fluid motion.","theme.mode": "Appearance","theme.mode.System": "System","theme.mode.Light": "Light","theme.mode.Dark": "Dark","theme.accent": "Accent colour","theme.custom_color": "Custom",- "theme.tonal_palette": "Tonal harmony","theme.corner_radius": "Softness","theme.reduce_motion": "Reduce animations","theme.reduce_motion_hint": "Recommended for older PCs. Turns off transitions and the donut's bounce.",diff --git a/src/Filee.App/Assets/i18n/es.json b/src/Filee.App/Assets/i18n/es.jsonindex f04fb7c8..41e92942 100644--- a/src/Filee.App/Assets/i18n/es.json+++ b/src/Filee.App/Assets/i18n/es.json@@ -578,18 +578,12 @@"presets.name_required": "Escribe un nombre","presets.select": "Elige un ajuste preestablecido para editarlo","theme.title": "Tema",- "theme.style": "Estilo de tema",- "theme.style.Soft": "Filee Suave",- "theme.style.MaterialYou": "Material You",- "theme.style.soft_hint": "Aspecto clásico de Filee con esquinas redondeadas y superficies pastel.",- "theme.style.material_you_hint": "Diseño Google Material 3 con paletas tonales dinámicas, formas de píldora y movimiento fluido.","theme.mode": "Aspecto","theme.mode.System": "Sistema","theme.mode.Light": "Claro","theme.mode.Dark": "Oscuro","theme.accent": "Color de acento","theme.custom_color": "Personalizado",- "theme.tonal_palette": "Armonía tonal","theme.corner_radius": "Redondeo","theme.reduce_motion": "Reducir las animaciones","theme.reduce_motion_hint": "Recomendado para PC antiguos. Desactiva las transiciones y el rebote del menú circular.",diff --git a/src/Filee.App/Assets/i18n/hi.json b/src/Filee.App/Assets/i18n/hi.jsonindex 41c3367d..693f5653 100644--- a/src/Filee.App/Assets/i18n/hi.json+++ b/src/Filee.App/Assets/i18n/hi.json@@ -578,18 +578,12 @@"presets.name_required": "नाम दर्ज करें","presets.select": "संपादित करने के लिए कोई प्रीसेट चुनें","theme.title": "थीम",- "theme.style": "थीम शैली",- "theme.style.Soft": "Filee सॉफ्ट",- "theme.style.MaterialYou": "Material You",- "theme.style.soft_hint": "सॉफ्ट गोल कोनों और पेस्टल सतहों के साथ क्लासिक Filee लुक।",- "theme.style.material_you_hint": "डायनामिक टोनल पैलेट, पिल आकार और फ्लूइड मोशन के साथ Google Material 3 डिज़ाइन।","theme.mode": "रूप","theme.mode.System": "सिस्टम","theme.mode.Light": "लाइट","theme.mode.Dark": "डार्क","theme.accent": "एक्सेंट रंग","theme.custom_color": "कस्टम",- "theme.tonal_palette": "टोनल सामंजस्य","theme.corner_radius": "कोमलता","theme.reduce_motion": "एनिमेशन कम करें","theme.reduce_motion_hint": "पुराने PC के लिए अनुशंसित। ट्रांज़िशन और डोनट की उछाल बंद कर देता है।",diff --git a/src/Filee.App/Assets/i18n/ja.json b/src/Filee.App/Assets/i18n/ja.jsonindex 34ca137c..88ce8cc4 100644--- a/src/Filee.App/Assets/i18n/ja.json+++ b/src/Filee.App/Assets/i18n/ja.json@@ -578,18 +578,12 @@"presets.name_required": "名前を入力してください","presets.select": "編集するプリセットを選択してください","theme.title": "テーマ",- "theme.style": "テーマのスタイル",- "theme.style.Soft": "Filee ソフト",- "theme.style.MaterialYou": "Material You",- "theme.style.soft_hint": "柔らかな丸角とパステル調の質感を持つクラシックな Filee デザイン。",- "theme.style.material_you_hint": "動的な色調パレット、ピル形状、流れるようなアニメーションを備えた Google Material 3 デザイン。","theme.mode": "外観","theme.mode.System": "システム設定に合わせる","theme.mode.Light": "ライト","theme.mode.Dark": "ダーク","theme.accent": "アクセントカラー","theme.custom_color": "カスタム",- "theme.tonal_palette": "トーンの調和","theme.corner_radius": "角の丸み","theme.reduce_motion": "アニメーションを減らす","theme.reduce_motion_hint": "古いPCにおすすめです。画面切り替え時のアニメーションと、ドーナツメニューの弾む動きを無効にします。",diff --git a/src/Filee.App/Assets/i18n/ko.json b/src/Filee.App/Assets/i18n/ko.jsonindex a850f198..4b8e1284 100644--- a/src/Filee.App/Assets/i18n/ko.json+++ b/src/Filee.App/Assets/i18n/ko.json@@ -594,18 +594,12 @@"presets.select": "편집할 프리셋을 선택하세요","theme.title": "테마",- "theme.style": "테마 스타일",- "theme.style.Soft": "Filee 소프트",- "theme.style.MaterialYou": "Material You",- "theme.style.soft_hint": "부드러운 모서리와 파스텔 표면의 클래식 Filee 디자인입니다.",- "theme.style.material_you_hint": "동적 톤 팔레트, 알약 모양 및 유연한 모션의 Google Material 3 디자인입니다.","theme.mode": "모드","theme.mode.System": "시스템","theme.mode.Light": "라이트","theme.mode.Dark": "다크","theme.accent": "강조색","theme.custom_color": "직접 선택",- "theme.tonal_palette": "톤 조화","theme.corner_radius": "말랑함","theme.reduce_motion": "애니메이션 줄이기","theme.reduce_motion_hint": "저사양 PC에 권장해요. 전환 효과와 도넛의 튕김 효과를 꺼요.",diff --git a/src/Filee.App/Assets/i18n/pl.json b/src/Filee.App/Assets/i18n/pl.jsonindex 75442518..09fe62ba 100644--- a/src/Filee.App/Assets/i18n/pl.json+++ b/src/Filee.App/Assets/i18n/pl.json@@ -594,18 +594,12 @@"presets.select": "Wybierz ustawienie, aby je edytować","theme.title": "Motyw",- "theme.style": "Styl motywu",- "theme.style.Soft": "Filee Łagodny",- "theme.style.MaterialYou": "Material You",- "theme.style.soft_hint": "Klasyczny wygląd Filee z miękkimi zaokrąglonymi rogami i pastelowymi powierzchniami.",- "theme.style.material_you_hint": "Projekt Google Material 3 z dynamicznymi paletami tonalnymi, kształtami pigułek i płynnym ruchem.","theme.mode": "Wygląd","theme.mode.System": "Systemowy","theme.mode.Light": "Jasny","theme.mode.Dark": "Ciemny","theme.accent": "Kolor akcentu","theme.custom_color": "Własny",- "theme.tonal_palette": "Harmonia tonalna","theme.corner_radius": "Zaokrąglenie","theme.reduce_motion": "Ogranicz animacje","theme.reduce_motion_hint": "Zalecane na starszych komputerach. Wyłącza przejścia i odbijanie pierścienia.",diff --git a/src/Filee.App/Assets/i18n/ru.json b/src/Filee.App/Assets/i18n/ru.jsonindex 52d91cce..e95a938a 100644--- a/src/Filee.App/Assets/i18n/ru.json+++ b/src/Filee.App/Assets/i18n/ru.json@@ -594,18 +594,12 @@"presets.select": "Выберите пресет, чтобы изменить его","theme.title": "Тема",- "theme.style": "Стиль темы",- "theme.style.Soft": "Filee Мягкий",- "theme.style.MaterialYou": "Material You",- "theme.style.soft_hint": "Классический вид Filee с мягкими закругленными углами и пастельными поверхностями.",- "theme.style.material_you_hint": "Дизайн Google Material 3 с динамическими тональными палитрами, скругленными формами и плавной анимацией.","theme.mode": "Оформление","theme.mode.System": "Как в системе","theme.mode.Light": "Светлое","theme.mode.Dark": "Тёмное","theme.accent": "Акцентный цвет","theme.custom_color": "Свой",- "theme.tonal_palette": "Тональная гармония","theme.corner_radius": "Скругление","theme.reduce_motion": "Меньше анимации","theme.reduce_motion_hint": "Рекомендуется для старых компьютеров. Отключает переходы и подпрыгивание кругового меню.",diff --git a/src/Filee.App/Assets/i18n/zh-CN.json b/src/Filee.App/Assets/i18n/zh-CN.jsonindex bab67bbe..41b0b659 100644--- a/src/Filee.App/Assets/i18n/zh-CN.json+++ b/src/Filee.App/Assets/i18n/zh-CN.json@@ -594,18 +594,12 @@"presets.select": "选择要编辑的预设","theme.title": "主题",- "theme.style": "主题样式",- "theme.style.Soft": "Filee 柔和",- "theme.style.MaterialYou": "Material You",- "theme.style.soft_hint": "具有柔和圆角与柔和强调色的经典 Filee 外观。",- "theme.style.material_you_hint": "具有动态色调调色板、药丸形状和流畅动效的 Google Material 3 设计。","theme.mode": "外观","theme.mode.System": "跟随系统","theme.mode.Light": "浅色","theme.mode.Dark": "深色","theme.accent": "强调色","theme.custom_color": "自定义",- "theme.tonal_palette": "色调和谐","theme.corner_radius": "圆角","theme.reduce_motion": "减少动画","theme.reduce_motion_hint": "适合配置较低的电脑。关闭过渡效果和圆环的弹跳效果。",diff --git a/src/Filee.App/Controls/DonutMenu.Progress.cs b/src/Filee.App/Controls/DonutMenu.Progress.csindex af04c94a..fb0fd851 100644--- a/src/Filee.App/Controls/DonutMenu.Progress.cs+++ b/src/Filee.App/Controls/DonutMenu.Progress.cs@@ -319,11 +319,10 @@ public sealed partial class DonutMenuusing var _ = context.PushTransform(ringTransform);using var __ = context.PushOpacity(opacity);- var stroke = IsMaterialYou ? 10.0 : RingStroke;- var plateRadius = RingRadius + stroke + 2;+ var plateRadius = RingRadius + RingStroke + 2;DrawPlateShadow(context, center, plateRadius);context.DrawEllipse(CenterBrush, BorderPen(), center, plateRadius, plateRadius);- context.DrawEllipse(null, new Pen(WithOpacity(SecondaryForeground, IsMaterialYou ? 0.16 : 0.22), stroke), center, RingRadius, RingRadius);+ context.DrawEllipse(null, new Pen(WithOpacity(SecondaryForeground, 0.22), RingStroke), center, RingRadius, RingRadius);var arcBrush = _outcome switch{@@ -332,7 +331,7 @@ public sealed partial class DonutMenu_ => AccentBrush,};var sweep = _outcome == DonutProgressOutcome.Failed ? Math.Max(_shownProgress, 0.02) : _shownProgress;- DrawArc(context, center, RingRadius, sweep, new Pen(arcBrush, stroke, lineCap: PenLineCap.Round));+ DrawArc(context, center, RingRadius, sweep, new Pen(arcBrush, RingStroke, lineCap: PenLineCap.Round));var badge = _outcome is null ? 0 : Math.Max(0, _badge.Value);if (badge < 0.98)diff --git a/src/Filee.App/Controls/DonutMenu.cs b/src/Filee.App/Controls/DonutMenu.csindex 273c2a34..cbc7b819 100644--- a/src/Filee.App/Controls/DonutMenu.cs+++ b/src/Filee.App/Controls/DonutMenu.cs@@ -89,10 +89,6 @@ public sealed partial class DonutMenu : Controlpublic static readonly StyledProperty<IBrush?> DangerBrushProperty =AvaloniaProperty.Register<DonutMenu, IBrush?>(nameof(DangerBrush), Brushes.IndianRed);- /// <summary>Material You (Material Design 3) styling and expressive motion.</summary>- public static readonly StyledProperty<bool> IsMaterialYouProperty =- AvaloniaProperty.Register<DonutMenu, bool>(nameof(IsMaterialYou));-/// <summary>Gap between slices in pixels (keeps the donut "full" while separating slices).</summary>private const double GapPixels = 3;private const double PopOut = 7;@@ -135,7 +131,8 @@ public sealed partial class DonutMenu : ControlAffectsMeasure<DonutMenu>(OuterRadiusProperty, ReserveSubRingProperty);AffectsRender<DonutMenu>(HoleRatioProperty, SliceOpacityProperty, CenterTitleProperty, CenterSubtitleProperty,IsEditModeProperty, SliceBrushProperty, SliceBorderBrushProperty, CenterBrushProperty, AccentBrushProperty,- IsMaterialYouProperty, CenterHintProperty, CenterHintWheelProperty);+ OnAccentBrushProperty, ForegroundProperty, SecondaryForegroundProperty, SuccessBrushProperty, CornerRadiusProperty,+ CenterHintProperty, CenterHintWheelProperty);ItemsProperty.Changed.AddClassHandler<DonutMenu>((d, _) => d.OnItemsChanged());}@@ -174,7 +171,6 @@ public sealed partial class DonutMenu : Controlpublic IBrush? Foreground { get => GetValue(ForegroundProperty); set => SetValue(ForegroundProperty, value); }public IBrush? SecondaryForeground { get => GetValue(SecondaryForegroundProperty); set => SetValue(SecondaryForegroundProperty, value); }public IBrush? DangerBrush { get => GetValue(DangerBrushProperty); set => SetValue(DangerBrushProperty, value); }- public bool IsMaterialYou { get => GetValue(IsMaterialYouProperty); set => SetValue(IsMaterialYouProperty, value); }/// <summary>True while an external drag hovers the hole (drop = cancel).</summary>public bool IsCenterHot => _externalCenterHot;@@ -746,11 +742,10 @@ public sealed partial class DonutMenu : Control// Popping out bounces; letting go settles without a bounce: one below zero would make the faded accent// flash once more on its way back.for (var i = 0; i < _hover.Length; i++)- active |= i == ActiveIndex- ? _hover[i].Step(1, dt, IsMaterialYou ? 380 : 280, IsMaterialYou ? 24 : 18)- : _hover[i].Step(0, dt, 320, CriticalDamping);- active |= _centerPulse.Step(0, dt, IsMaterialYou ? 280 : 260, IsMaterialYou ? 14 : 12);- // A soft bounce opening, like the slices popping out; folding away settles without one.+ active |= i == ActiveIndex ? _hover[i].Step(1, dt) : _hover[i].Step(0, dt, 320, CriticalDamping);+ active |= _centerPulse.Step(0, dt, 260, 12);+ // A soft bounce opening, like the slices popping out; folding away settles without one. The bounce grows the+ // ring by about a pixel, well inside the room kept for it (SubRingSpace).active |= _expanded >= 0 ? _expand.Step(1, dt, 320, 24) : _expand.Step(0, dt, 320, CriticalDamping);if (_expanded < 0 && _expand.Value <= 0.001)_shownExpanded = -1;@@ -792,10 +787,10 @@ public sealed partial class DonutMenu : Controlcallback?.Invoke();}- private double EaseOutBack(double t)+ private static double EaseOutBack(double t){- double c1 = IsMaterialYou ? 1.75 : 1.55;- double c3 = c1 + 1;+ const double c1 = 1.55;+ const double c3 = c1 + 1;return 1 + c3 * Math.Pow(t - 1, 3) + c1 * Math.Pow(t - 1, 2);}@@ -864,39 +859,27 @@ public sealed partial class DonutMenu : Controlvar span = previewing ? _span[i].Value : DonutGeometry.Span(n);if (span < 0.01)continue;- var pop = IsMaterialYou ? PopOut * 1.4 : PopOut;- var offset = DonutGeometry.PointAt(new Point(0, 0), hover * pop, mid);+ var offset = DonutGeometry.PointAt(new Point(0, 0), hover * PopOut, mid);// Open animation: scale up from the centre with a small twist.var scale = 0.55 + 0.45 * open;- var rotate = (1 - Math.Min(open, 1)) * (IsMaterialYou ? -0.22 : -0.35);- var hoverScale = IsMaterialYou ? 1 + hover * 0.045 : 1 + hover * 0.025;+ var rotate = (1 - Math.Min(open, 1)) * -0.35;var transform =Matrix.CreateTranslation(-center.X, -center.Y) *Matrix.CreateRotation(rotate) *- Matrix.CreateScale(scale * hoverScale, scale * hoverScale) *+ Matrix.CreateScale(scale * (1 + hover * 0.025), scale * (1 + hover * 0.025)) *Matrix.CreateTranslation(center.X + offset.X, center.Y + offset.Y);using (context.PushTransform(transform))using (context.PushOpacity(Math.Clamp(open, 0, 1) * (i == _dimmedIndex ? 0.3 : 1))){- var corner = IsMaterialYou ? Math.Max(12, SliceCornerRadius * 1.4) : SliceCornerRadius;- var gap = IsMaterialYou ? 4.5 : GapPixels;- var wedge = CreateWedge(center, r1, r2, mid, span, corner, gap);-- if (IsMaterialYou && hover > 0.02)- {- // Ambient glow / elevation for active floating slice in Material You- var glowPen = new Pen(WithOpacity(AccentBrush, 0.28 * Math.Clamp(hover, 0, 1)), 4);- context.DrawGeometry(null, glowPen, wedge);- }-+ var wedge = CreateWedge(center, r1, r2, mid, span);context.DrawGeometry(WithOpacity(SliceBrush, SliceOpacity * (item.IsEnabled ? 1 : 0.55)), BorderPen(), wedge);// The accent fades in and out with the highlight (no floor: a floor made it vanish with a jump).var emphasis = i == _dropTargetIndex ? 1.0 : hover;if (emphasis > 0.01 && item.IsEnabled)- context.DrawGeometry(WithOpacity(AccentBrush, (IsMaterialYou ? 0.95 : 0.82) * Math.Clamp(emphasis, 0, 1)), null, wedge);+ context.DrawGeometry(WithOpacity(AccentBrush, 0.82 * Math.Clamp(emphasis, 0, 1)), null, wedge);var hot = (i == ActiveIndex || i == _dropTargetIndex) && item.IsEnabled;DrawLabel(context, item, center, (r1 + r2) / 2, mid, span * (r1 + r2) / 2 - 10,@@ -929,48 +912,27 @@ public sealed partial class DonutMenu : Controlprivate void DrawCenter(DrawingContext context, Point center, double r1, Typeface bold, Typeface regular){- var pulse = 1 + _centerPulse.Value * (IsMaterialYou ? 0.08 : 0.06);+ var pulse = 1 + _centerPulse.Value * 0.06;var radius = (r1 - 6) * pulse;var cancelHot = _externalCenterHot;-- if (IsMaterialYou)- DrawCenterShadow(context, center, radius);-context.DrawEllipse(CenterBrush, BorderPen(), center, radius, radius);if (cancelHot)- context.DrawEllipse(WithOpacity(DangerBrush, IsMaterialYou ? 0.32 : 0.18), null, center, radius, radius);+ context.DrawEllipse(WithOpacity(DangerBrush, 0.18), null, center, radius, radius);var maxWidth = radius * 1.6;- var title = MakeText(CenterTitle ?? "", bold, IsMaterialYou ? 14.5 : 14, Foreground, maxWidth, maxLines: 2);- var subtitle = MakeText(CenterSubtitle ?? "", regular, IsMaterialYou ? 10.5 : 11.5, cancelHot ? DangerBrush : SecondaryForeground, maxWidth, maxLines: 2);- var hasSubtitle = !string.IsNullOrEmpty(CenterSubtitle);+ var title = MakeText(CenterTitle ?? "", bold, 14, Foreground, maxWidth, maxLines: 2);+ var subtitle = MakeText(CenterSubtitle ?? "", regular, 11.5, cancelHot ? DangerBrush : SecondaryForeground, maxWidth, maxLines: 2);// "Tab ↻ back": small, under the rest, a little narrower (the hub is round).var hint = string.IsNullOrEmpty(CenterHint) ? null : MakeText(CenterHint, regular, 10.5, SecondaryForeground, maxWidth * 0.85);- var total = title.Height + (hasSubtitle ? subtitle.Height + (IsMaterialYou ? 4 : 2) : 0) + (hint is null ? 0 : hint.Height + 5);+ var total = title.Height + (string.IsNullOrEmpty(CenterSubtitle) ? 0 : subtitle.Height + 2) + (hint is null ? 0 : hint.Height + 5);var y = center.Y - total / 2;DrawCentered(context, title, center.X, y);y += title.Height;-- if (hasSubtitle)+ if (!string.IsNullOrEmpty(CenterSubtitle)){- var subY = y + (IsMaterialYou ? 3 : 2);- if (IsMaterialYou)- {- var padX = 7.0;- var padY = 2.0;- var badgeW = Math.Min(maxWidth, subtitle.Width + padX * 2);- var badgeH = subtitle.Height + padY * 2;- var badgeRect = new RoundedRect(new Rect(center.X - badgeW / 2, subY, badgeW, badgeH), badgeH / 2);- context.DrawRectangle(WithOpacity(AccentBrush, 0.18), null, badgeRect);- DrawCentered(context, MakeText(CenterSubtitle!, regular, 10, Foreground, badgeW), center.X, subY + padY);- }- else- {- DrawCentered(context, subtitle, center.X, subY);- }- y += subtitle.Height + (IsMaterialYou ? 4 : 2);+ DrawCentered(context, subtitle, center.X, y + 2);+ y += subtitle.Height + 2;}-if (hint is not null){using (context.PushOpacity(0.85))@@ -991,22 +953,6 @@ public sealed partial class DonutMenu : Control}}- private static void DrawCenterShadow(DrawingContext context, Point center, double radius)- {- var shadowRadius = radius + 9;- var brush = new RadialGradientBrush- {- GradientStops =- {- new GradientStop(Color.FromArgb(0, 0, 0, 0), 0),- new GradientStop(Color.FromArgb(0, 0, 0, 0), (radius - 4) / shadowRadius),- new GradientStop(Color.FromArgb(42, 0, 0, 0), (radius + 1) / shadowRadius),- new GradientStop(Color.FromArgb(0, 0, 0, 0), 1),- },- };- context.DrawEllipse(brush, null, new Point(center.X, center.Y + 2), shadowRadius, shadowRadius);- }-/// <summary>An outline of a mouse with its wheel, filling <paramref name="box"/>.</summary>private static void DrawMouse(DrawingContext context, Rect box, IBrush? brush){@@ -1156,31 +1102,31 @@ public sealed partial class DonutMenu : Control/// <summary>A rounded slice of <paramref name="span"/> radians centred on <paramref name="mid"/> (a ring when it is all of it).</summary>private StreamGeometry CreateWedge(Point c, double r1, double r2, double mid, double span) =>- CreateWedge(c, r1, r2, mid, span, IsMaterialYou ? Math.Max(12, SliceCornerRadius * 1.4) : SliceCornerRadius, IsMaterialYou ? 4.5 : GapPixels);+ CreateWedge(c, r1, r2, mid, span, SliceCornerRadius);// Slices are drawn every frame while the donut animates, but their shapes only change with the size, the layout// or the softness: the shapes are kept and reused. Animations move them with transforms; only the edit mode's// sliding slices make new ones, and the cache starts over when it fills up.- private readonly Dictionary<(Point C, double R1, double R2, double Mid, double Span, double Corner, double Gap), StreamGeometry> _wedges = new();+ private readonly Dictionary<(Point C, double R1, double R2, double Mid, double Span, double Corner), StreamGeometry> _wedges = new();private const int MaxCachedWedges = 256;- private StreamGeometry CreateWedge(Point c, double r1, double r2, double mid, double span, double cornerRadius, double gap = GapPixels)+ private StreamGeometry CreateWedge(Point c, double r1, double r2, double mid, double span, double cornerRadius){- var key = (c, r1, r2, mid, span, cornerRadius, gap);+ var key = (c, r1, r2, mid, span, cornerRadius);if (_wedges.TryGetValue(key, out var cached))return cached;if (_wedges.Count >= MaxCachedWedges)_wedges.Clear();- return _wedges[key] = BuildWedge(c, r1, r2, mid, span, cornerRadius, gap);+ return _wedges[key] = BuildWedge(c, r1, r2, mid, span, cornerRadius);}/// <summary>A slice with a constant-width gap to its neighbours and corners rounded by <paramref name="cornerRadius"/>.</summary>- private static StreamGeometry BuildWedge(Point c, double r1, double r2, double mid, double span, double cornerRadius, double gap = GapPixels)+ private static StreamGeometry BuildWedge(Point c, double r1, double r2, double mid, double span, double cornerRadius){if (span >= 2 * Math.PI - 0.001)return CreateRing(c, r1, r2);- var outline = DonutGeometry.Wedge(c, r1, r2, mid, span, gap, cornerRadius);+ var outline = DonutGeometry.Wedge(c, r1, r2, mid, span, GapPixels, cornerRadius);var geometry = new StreamGeometry();using var ctx = geometry.Open();ctx.BeginFigure(outline.Start, true);diff --git a/src/Filee.App/Services/MaterialYouPalette.cs b/src/Filee.App/Services/MaterialYouPalette.csdeleted file mode 100644index f6716ca3..00000000--- a/src/Filee.App/Services/MaterialYouPalette.cs+++ /dev/null@@ -1,796 +0,0 @@-// Material You (Material Design 3) dynamic tonal palette generator.-// Generates tonal color roles (Primary, PrimaryContainer, SecondaryContainer, SurfaceContainer, etc.)-// from a seed color for Light and Dark variants.--using System.Globalization;-using Avalonia;-using Avalonia.Media;--namespace Filee.App.Services;--/// <summary>Resolved Material Design 3 tonal color tokens.</summary>-public sealed class MaterialYouPalette-{- public required Color Primary { get; init; }- public required Color OnPrimary { get; init; }- public required Color PrimaryContainer { get; init; }- public required Color OnPrimaryContainer { get; init; }-- public required Color Secondary { get; init; }- public required Color OnSecondary { get; init; }- public required Color SecondaryContainer { get; init; }- public required Color OnSecondaryContainer { get; init; }-- public required Color Surface { get; init; }- public required Color SurfaceDim { get; init; }- public required Color SurfaceBright { get; init; }- public required Color SurfaceContainerLowest { get; init; }- public required Color SurfaceContainerLow { get; init; }- public required Color SurfaceContainer { get; init; }- public required Color SurfaceContainerHigh { get; init; }- public required Color SurfaceContainerHighest { get; init; }-- public required Color OnSurface { get; init; }- public required Color OnSurfaceVariant { get; init; }-- public required Color Outline { get; init; }- public required Color OutlineVariant { get; init; }-- public required Color Danger { get; init; }- public required Color Success { get; init; }- public required Color Warning { get; init; }-- public required BoxShadows CardShadow { get; init; }-- /// <summary>Calculates standard sRGB relative luminance.</summary>- public static double Luminance(Color c)- {- static double Channel(byte v)- {- double s = v / 255.0;- return s <= 0.03928 ? s / 12.92 : Math.Pow((s + 0.055) / 1.055, 2.4);- }- return 0.2126 * Channel(c.R) + 0.7152 * Channel(c.G) + 0.0722 * Channel(c.B);- }-- /// <summary>Calculates dynamic text contrast (dark charcoal vs crisp white) based on background luminance.</summary>- public static Color TextOn(Color bg)- {- return Luminance(bg) > 0.42 ? Color.Parse("#141E11") : Colors.White;- }-- /// <summary>Alpha-blends a foreground color over a background color (matching Inkora theme engine).</summary>- public static Color AlphaBlend(Color foreground, Color background)- {- double fA = foreground.A / 255.0;- double bA = background.A / 255.0;- double rA = fA + bA * (1.0 - fA);- if (rA <= 1e-5) return Colors.Transparent;- byte r = (byte)Math.Clamp(Math.Round((foreground.R * fA + background.R * bA * (1.0 - fA)) / rA), 0, 255);- byte g = (byte)Math.Clamp(Math.Round((foreground.G * fA + background.G * bA * (1.0 - fA)) / rA), 0, 255);- byte b = (byte)Math.Clamp(Math.Round((foreground.B * fA + background.B * bA * (1.0 - fA)) / rA), 0, 255);- byte a = (byte)Math.Clamp(Math.Round(rA * 255.0), 0, 255);- return Color.FromArgb(a, r, g, b);- }-- /// <summary>Generates the complete Material 3 tonal color system from a seed accent color, with Inkora pastel presets.</summary>- public static MaterialYouPalette Generate(Color seed, bool isDark)- {- // Check for matching Inkora curated pastel presets first- if (TryGetInkoraPreset(seed, isDark, out var presetPalette))- return presetPalette;-- var (h, s, l) = RgbToHsl(seed);- var baseSat = Math.Clamp(s, 0.25, 0.85);-- if (!isDark)- {- // ── Light Mode (Inkora alpha blend tinted paper surfaces) ──- var primary = seed;- var onPrimary = TextOn(primary);- var primaryContainer = HslToRgb(h, Math.Min(baseSat * 0.65, 0.50), 0.92);- var onPrimaryContainer = TextOn(primaryContainer);-- var secondary = HslToRgb(h, Math.Min(baseSat * 0.45, 0.38), 0.45);- var onSecondary = TextOn(secondary);- var secondaryContainer = HslToRgb(h, Math.Min(baseSat * 0.35, 0.28), 0.94);- var onSecondaryContainer = TextOn(secondaryContainer);-- // Inkora light tinted surface stack- var surface = AlphaBlend(Color.FromArgb((byte)(0.03 * 255), seed.R, seed.G, seed.B), Color.Parse("#FAF9FC"));- var surfaceDim = AlphaBlend(Color.FromArgb((byte)(0.05 * 255), seed.R, seed.G, seed.B), Color.Parse("#F5F3F9"));- var surfaceBright = Colors.White;- var surfaceContainerLowest = Colors.White;- var surfaceContainerLow = AlphaBlend(Color.FromArgb((byte)(0.06 * 255), seed.R, seed.G, seed.B), Color.Parse("#F3F1F7"));- var surfaceContainer = AlphaBlend(Color.FromArgb((byte)(0.09 * 255), seed.R, seed.G, seed.B), Color.Parse("#EBE8F2"));- var surfaceContainerHigh = AlphaBlend(Color.FromArgb((byte)(0.13 * 255), seed.R, seed.G, seed.B), Color.Parse("#E3DFEC"));- var surfaceContainerHighest = AlphaBlend(Color.FromArgb((byte)(0.17 * 255), seed.R, seed.G, seed.B), Color.Parse("#DCD7E7"));-- var onSurface = Color.Parse("#1E1B22");- var onSurfaceVariant = Color.Parse("#534F5C");-- var outline = AlphaBlend(Color.FromArgb((byte)(0.30 * 255), seed.R, seed.G, seed.B), Color.Parse("#8E889B"));- var outlineVariant = AlphaBlend(Color.FromArgb((byte)(0.18 * 255), seed.R, seed.G, seed.B), Color.Parse("#D5CFE3"));-- return new MaterialYouPalette- {- Primary = primary,- OnPrimary = onPrimary,- PrimaryContainer = primaryContainer,- OnPrimaryContainer = onPrimaryContainer,- Secondary = secondary,- OnSecondary = onSecondary,- SecondaryContainer = secondaryContainer,- OnSecondaryContainer = onSecondaryContainer,- Surface = surface,- SurfaceDim = surfaceDim,- SurfaceBright = surfaceBright,- SurfaceContainerLowest = surfaceContainerLowest,- SurfaceContainerLow = surfaceContainerLow,- SurfaceContainer = surfaceContainer,- SurfaceContainerHigh = surfaceContainerHigh,- SurfaceContainerHighest = surfaceContainerHighest,- OnSurface = onSurface,- OnSurfaceVariant = onSurfaceVariant,- Outline = outline,- OutlineVariant = outlineVariant,- Danger = Color.Parse("#BA1A1A"),- Success = Color.Parse("#1B6D24"),- Warning = Color.Parse("#825500"),- CardShadow = BoxShadows.Parse("0 1 3 0 #12000000, 0 4 12 1 #0D000000"),- };- }- else- {- // ── Dark Mode (Inkora alpha blend tinted deep charcoal surfaces) ──- var primary = seed;- var onPrimary = TextOn(primary);- var primaryContainer = HslToRgb(h, Math.Min(baseSat * 0.60, 0.42), 0.28);- var onPrimaryContainer = TextOn(primaryContainer);-- var secondary = HslToRgb(h, Math.Min(baseSat * 0.40, 0.32), 0.72);- var onSecondary = TextOn(secondary);- var secondaryContainer = HslToRgb(h, Math.Min(baseSat * 0.30, 0.25), 0.24);- var onSecondaryContainer = TextOn(secondaryContainer);-- // Inkora dark tinted surface stack- var surface = AlphaBlend(Color.FromArgb((byte)(0.08 * 255), seed.R, seed.G, seed.B), Color.Parse("#16151B"));- var surfaceDim = Color.Parse("#110F15");- var surfaceBright = AlphaBlend(Color.FromArgb((byte)(0.22 * 255), seed.R, seed.G, seed.B), Color.Parse("#322E3F"));- var surfaceContainerLowest = Color.Parse("#110F15");- var surfaceContainerLow = AlphaBlend(Color.FromArgb((byte)(0.12 * 255), seed.R, seed.G, seed.B), Color.Parse("#1D1B24"));- var surfaceContainer = AlphaBlend(Color.FromArgb((byte)(0.16 * 255), seed.R, seed.G, seed.B), Color.Parse("#24222E"));- var surfaceContainerHigh = AlphaBlend(Color.FromArgb((byte)(0.20 * 255), seed.R, seed.G, seed.B), Color.Parse("#2E2B3A"));- var surfaceContainerHighest = AlphaBlend(Color.FromArgb((byte)(0.24 * 255), seed.R, seed.G, seed.B), Color.Parse("#383547"));-- var onSurface = Color.Parse("#EDE8F4");- var onSurfaceVariant = Color.Parse("#C5BFCF");-- var outline = AlphaBlend(Color.FromArgb((byte)(0.35 * 255), seed.R, seed.G, seed.B), Color.Parse("#686477"));- var outlineVariant = AlphaBlend(Color.FromArgb((byte)(0.20 * 255), seed.R, seed.G, seed.B), Color.Parse("#403C4D"));-- return new MaterialYouPalette- {- Primary = primary,- OnPrimary = onPrimary,- PrimaryContainer = primaryContainer,- OnPrimaryContainer = onPrimaryContainer,- Secondary = secondary,- OnSecondary = onSecondary,- SecondaryContainer = secondaryContainer,- OnSecondaryContainer = onSecondaryContainer,- Surface = surface,- SurfaceDim = surfaceDim,- SurfaceBright = surfaceBright,- SurfaceContainerLowest = surfaceContainerLowest,- SurfaceContainerLow = surfaceContainerLow,- SurfaceContainer = surfaceContainer,- SurfaceContainerHigh = surfaceContainerHigh,- SurfaceContainerHighest = surfaceContainerHighest,- OnSurface = onSurface,- OnSurfaceVariant = onSurfaceVariant,- Outline = outline,- OutlineVariant = outlineVariant,- Danger = Color.Parse("#FFB4AB"),- Success = Color.Parse("#8CD692"),- Warning = Color.Parse("#FFBA2F"),- CardShadow = BoxShadows.Parse("0 1 3 0 #35000000, 0 8 20 0 #20000000"),- };- }- }-- private static bool ColorMatches(Color a, Color b) =>- Math.Abs(a.R - b.R) <= 3 && Math.Abs(a.G - b.G) <= 3 && Math.Abs(a.B - b.B) <= 3;-- private static bool TryGetInkoraPreset(Color seed, bool isDark, out MaterialYouPalette palette)- {- // 0. Monochrome (Pure Black & White)- if (ColorMatches(seed, Color.Parse("#111111")) || ColorMatches(seed, Color.Parse("#000000")) ||- ColorMatches(seed, Colors.White) || ColorMatches(seed, Color.Parse("#F5F5F5")))- {- palette = isDark ? new MaterialYouPalette- {- Primary = Color.Parse("#F5F5F5"),- OnPrimary = Color.Parse("#111111"),- PrimaryContainer = Color.Parse("#282828"),- OnPrimaryContainer = Color.Parse("#F5F5F5"),- Secondary = Color.Parse("#D4D4D4"),- OnSecondary = Color.Parse("#111111"),- SecondaryContainer = Color.Parse("#202020"),- OnSecondaryContainer = Color.Parse("#E0E0E0"),- Surface = Color.Parse("#0D0D0D"),- SurfaceDim = Color.Parse("#060606"),- SurfaceBright = Color.Parse("#1E1E1E"),- SurfaceContainerLowest = Color.Parse("#050505"),- SurfaceContainerLow = Color.Parse("#141414"),- SurfaceContainer = Color.Parse("#1B1B1B"),- SurfaceContainerHigh = Color.Parse("#242424"),- SurfaceContainerHighest = Color.Parse("#2E2E2E"),- OnSurface = Color.Parse("#F5F5F5"),- OnSurfaceVariant = Color.Parse("#B5B5B5"),- Outline = Color.Parse("#4C4C4C"),- OutlineVariant = Color.Parse("#2E2E2E"),- Danger = Color.Parse("#FF6B6B"),- Success = Color.Parse("#69DB7C"),- Warning = Color.Parse("#FFD43B"),- CardShadow = BoxShadows.Parse("0 1 3 0 #60000000, 0 8 20 0 #40000000"),- } : new MaterialYouPalette- {- Primary = Color.Parse("#111111"),- OnPrimary = Colors.White,- PrimaryContainer = Color.Parse("#EAEAEA"),- OnPrimaryContainer = Color.Parse("#111111"),- Secondary = Color.Parse("#333333"),- OnSecondary = Colors.White,- SecondaryContainer = Color.Parse("#F0F0F0"),- OnSecondaryContainer = Color.Parse("#111111"),- Surface = Colors.White,- SurfaceDim = Color.Parse("#F5F5F5"),- SurfaceBright = Colors.White,- SurfaceContainerLowest = Colors.White,- SurfaceContainerLow = Color.Parse("#F8F8F8"),- SurfaceContainer = Color.Parse("#F0F0F0"),- SurfaceContainerHigh = Color.Parse("#E8E8E8"),- SurfaceContainerHighest = Color.Parse("#DFDFDF"),- OnSurface = Color.Parse("#111111"),- OnSurfaceVariant = Color.Parse("#4A4A4A"),- Outline = Color.Parse("#B0B0B0"),- OutlineVariant = Color.Parse("#E0E0E0"),- Danger = Color.Parse("#BA1A1A"),- Success = Color.Parse("#1B6D24"),- Warning = Color.Parse("#825500"),- CardShadow = BoxShadows.Parse("0 1 3 0 #18000000, 0 4 12 1 #10000000"),- };- return true;- }-- // 1. Blush & Peach (Light: #E07A70, Dark: #F29B91)- if (ColorMatches(seed, Color.Parse("#E07A70")) || ColorMatches(seed, Color.Parse("#F29B91")))- {- palette = isDark ? new MaterialYouPalette- {- Primary = Color.Parse("#F29B91"),- OnPrimary = Color.Parse("#441814"),- PrimaryContainer = Color.Parse("#5D2D27"),- OnPrimaryContainer = Color.Parse("#FDE8E5"),- Secondary = Color.Parse("#9EC4B5"),- OnSecondary = Color.Parse("#13362B"),- SecondaryContainer = Color.Parse("#26443A"),- OnSecondaryContainer = Color.Parse("#DBEDE6"),- Surface = Color.Parse("#1D1413"),- SurfaceDim = Color.Parse("#140E0D"),- SurfaceBright = Color.Parse("#382725"),- SurfaceContainerLowest = Color.Parse("#140E0D"),- SurfaceContainerLow = Color.Parse("#231A18"),- SurfaceContainer = Color.Parse("#2A201E"),- SurfaceContainerHigh = Color.Parse("#352927"),- SurfaceContainerHighest = Color.Parse("#413331"),- OnSurface = Color.Parse("#F8ECE9"),- OnSurfaceVariant = Color.Parse("#CBB0AB"),- Outline = Color.Parse("#7D6561"),- OutlineVariant = Color.Parse("#51403D"),- Danger = Color.Parse("#FFB4AB"),- Success = Color.Parse("#8CD692"),- Warning = Color.Parse("#FFBA2F"),- CardShadow = BoxShadows.Parse("0 1 3 0 #35000000, 0 8 20 0 #20000000")- } : new MaterialYouPalette- {- Primary = Color.Parse("#E07A70"),- OnPrimary = Colors.White,- PrimaryContainer = Color.Parse("#FDECE8"),- OnPrimaryContainer = Color.Parse("#4A2825"),- Secondary = Color.Parse("#7FA898"),- OnSecondary = Colors.White,- SecondaryContainer = Color.Parse("#E4F0EC"),- OnSecondaryContainer = Color.Parse("#22362F"),- Surface = Color.Parse("#FDF9F7"),- SurfaceDim = Color.Parse("#F5EDE9"),- SurfaceBright = Colors.White,- SurfaceContainerLowest = Colors.White,- SurfaceContainerLow = Color.Parse("#FAF2EF"),- SurfaceContainer = Color.Parse("#F6EAE6"),- SurfaceContainerHigh = Color.Parse("#F0DFDA"),- SurfaceContainerHighest = Color.Parse("#EAD5CF"),- OnSurface = Color.Parse("#2D2423"),- OnSurfaceVariant = Color.Parse("#6B5854"),- Outline = Color.Parse("#B39893"),- OutlineVariant = Color.Parse("#E8D5D0"),- Danger = Color.Parse("#BA1A1A"),- Success = Color.Parse("#1B6D24"),- Warning = Color.Parse("#825500"),- CardShadow = BoxShadows.Parse("0 1 3 0 #12000000, 0 4 12 1 #0D000000")- };- return true;- }-- // 2. Strawberry Milk (Light: #E86483, Dark: #F79BB0)- if (ColorMatches(seed, Color.Parse("#E86483")) || ColorMatches(seed, Color.Parse("#F79BB0")))- {- palette = isDark ? new MaterialYouPalette- {- Primary = Color.Parse("#F79BB0"),- OnPrimary = Color.Parse("#471320"),- PrimaryContainer = Color.Parse("#632434"),- OnPrimaryContainer = Color.Parse("#FEDFE6"),- Secondary = Color.Parse("#98C4B0"),- OnSecondary = Color.Parse("#163829"),- SecondaryContainer = Color.Parse("#284839"),- OnSecondaryContainer = Color.Parse("#DBEFE6"),- Surface = Color.Parse("#1D1517"),- SurfaceDim = Color.Parse("#140E10"),- SurfaceBright = Color.Parse("#38272C"),- SurfaceContainerLowest = Color.Parse("#140E10"),- SurfaceContainerLow = Color.Parse("#23191C"),- SurfaceContainer = Color.Parse("#2A1E22"),- SurfaceContainerHigh = Color.Parse("#35272B"),- SurfaceContainerHighest = Color.Parse("#413136"),- OnSurface = Color.Parse("#F7ECEE"),- OnSurfaceVariant = Color.Parse("#C9B0B7"),- Outline = Color.Parse("#7C646B"),- OutlineVariant = Color.Parse("#503E44"),- Danger = Color.Parse("#FFB4AB"),- Success = Color.Parse("#8CD692"),- Warning = Color.Parse("#FFBA2F"),- CardShadow = BoxShadows.Parse("0 1 3 0 #35000000, 0 8 20 0 #20000000")- } : new MaterialYouPalette- {- Primary = Color.Parse("#E86483"),- OnPrimary = Colors.White,- PrimaryContainer = Color.Parse("#FFECF0"),- OnPrimaryContainer = Color.Parse("#4A1824"),- Secondary = Color.Parse("#76A893"),- OnSecondary = Colors.White,- SecondaryContainer = Color.Parse("#E2F0EA"),- OnSecondaryContainer = Color.Parse("#1E382E"),- Surface = Color.Parse("#FFF8F9"),- SurfaceDim = Color.Parse("#F7ECF0"),- SurfaceBright = Colors.White,- SurfaceContainerLowest = Colors.White,- SurfaceContainerLow = Color.Parse("#FDF1F4"),- SurfaceContainer = Color.Parse("#F9E8EC"),- SurfaceContainerHigh = Color.Parse("#F3DDE3"),- SurfaceContainerHighest = Color.Parse("#EBCFD6"),- OnSurface = Color.Parse("#2E2225"),- OnSurfaceVariant = Color.Parse("#6B5359"),- Outline = Color.Parse("#B8939C"),- OutlineVariant = Color.Parse("#EBD2D9"),- Danger = Color.Parse("#BA1A1A"),- Success = Color.Parse("#1B6D24"),- Warning = Color.Parse("#825500"),- CardShadow = BoxShadows.Parse("0 1 3 0 #12000000, 0 4 12 1 #0D000000")- };- return true;- }-- // 3. Matcha Latte (Light: #5A8E51, Dark: #8DC983)- if (ColorMatches(seed, Color.Parse("#5A8E51")) || ColorMatches(seed, Color.Parse("#8DC983")))- {- palette = isDark ? new MaterialYouPalette- {- Primary = Color.Parse("#8DC983"),- OnPrimary = Color.Parse("#143710"),- PrimaryContainer = Color.Parse("#26521F"),- OnPrimaryContainer = Color.Parse("#DFF5DA"),- Secondary = Color.Parse("#F1B782"),- OnSecondary = Color.Parse("#3F240A"),- SecondaryContainer = Color.Parse("#563515"),- OnSecondaryContainer = Color.Parse("#FEEDD8"),- Surface = Color.Parse("#141712"),- SurfaceDim = Color.Parse("#0E110D"),- SurfaceBright = Color.Parse("#2E372A"),- SurfaceContainerLowest = Color.Parse("#0E110D"),- SurfaceContainerLow = Color.Parse("#1A1F18"),- SurfaceContainer = Color.Parse("#1F251D"),- SurfaceContainerHigh = Color.Parse("#293126"),- SurfaceContainerHighest = Color.Parse("#343E31"),- OnSurface = Color.Parse("#ECF0E7"),- OnSurfaceVariant = Color.Parse("#BCC4B6"),- Outline = Color.Parse("#6B7565"),- OutlineVariant = Color.Parse("#3F483A"),- Danger = Color.Parse("#FFB4AB"),- Success = Color.Parse("#8CD692"),- Warning = Color.Parse("#FFBA2F"),- CardShadow = BoxShadows.Parse("0 1 3 0 #35000000, 0 8 20 0 #20000000")- } : new MaterialYouPalette- {- Primary = Color.Parse("#5A8E51"),- OnPrimary = Colors.White,- PrimaryContainer = Color.Parse("#E7F3E3"),- OnPrimaryContainer = Color.Parse("#193714"),- Secondary = Color.Parse("#CC8749"),- OnSecondary = Colors.White,- SecondaryContainer = Color.Parse("#FAEEDB"),- OnSecondaryContainer = Color.Parse("#3E2611"),- Surface = Color.Parse("#F9FAF5"),- SurfaceDim = Color.Parse("#F0F2EB"),- SurfaceBright = Colors.White,- SurfaceContainerLowest = Colors.White,- SurfaceContainerLow = Color.Parse("#F3F5EE"),- SurfaceContainer = Color.Parse("#ECF0E5"),- SurfaceContainerHigh = Color.Parse("#E2E7DA"),- SurfaceContainerHighest = Color.Parse("#D7DDCE"),- OnSurface = Color.Parse("#242721"),- OnSurfaceVariant = Color.Parse("#555B4F"),- Outline = Color.Parse("#8D9686"),- OutlineVariant = Color.Parse("#D4DCCE"),- Danger = Color.Parse("#BA1A1A"),- Success = Color.Parse("#1B6D24"),- Warning = Color.Parse("#825500"),- CardShadow = BoxShadows.Parse("0 1 3 0 #12000000, 0 4 12 1 #0D000000")- };- return true;- }-- // 4. Lavender Mist (Light: #8B7AB8, Dark: #BCAEE5)- if (ColorMatches(seed, Color.Parse("#8B7AB8")) || ColorMatches(seed, Color.Parse("#BCAEE5")) || ColorMatches(seed, Color.Parse("#C5B4E3")))- {- palette = isDark ? new MaterialYouPalette- {- Primary = Color.Parse("#BCAEE5"),- OnPrimary = Color.Parse("#291E47"),- PrimaryContainer = Color.Parse("#3F3260"),- OnPrimaryContainer = Color.Parse("#EFEBF9"),- Secondary = Color.Parse("#91CFC0"),- OnSecondary = Color.Parse("#123B32"),- SecondaryContainer = Color.Parse("#224940"),- OnSecondaryContainer = Color.Parse("#DBF2EC"),- Surface = Color.Parse("#181520"),- SurfaceDim = Color.Parse("#110F17"),- SurfaceBright = Color.Parse("#332D42"),- SurfaceContainerLowest = Color.Parse("#110F17"),- SurfaceContainerLow = Color.Parse("#1E1A27"),- SurfaceContainer = Color.Parse("#252030"),- SurfaceContainerHigh = Color.Parse("#302A3D"),- SurfaceContainerHighest = Color.Parse("#3C354B"),- OnSurface = Color.Parse("#F1EEF7"),- OnSurfaceVariant = Color.Parse("#C4BED0"),- Outline = Color.Parse("#777183"),- OutlineVariant = Color.Parse("#4A4456"),- Danger = Color.Parse("#FFB4AB"),- Success = Color.Parse("#8CD692"),- Warning = Color.Parse("#FFBA2F"),- CardShadow = BoxShadows.Parse("0 1 3 0 #35000000, 0 8 20 0 #20000000")- } : new MaterialYouPalette- {- Primary = Color.Parse("#8B7AB8"),- OnPrimary = Colors.White,- PrimaryContainer = Color.Parse("#EDE8F7"),- OnPrimaryContainer = Color.Parse("#2F2648"),- Secondary = Color.Parse("#6FA89A"),- OnSecondary = Colors.White,- SecondaryContainer = Color.Parse("#E1F2ED"),- OnSecondaryContainer = Color.Parse("#1D3630"),- Surface = Color.Parse("#FAF8FD"),- SurfaceDim = Color.Parse("#F1ECF7"),- SurfaceBright = Colors.White,- SurfaceContainerLowest = Colors.White,- SurfaceContainerLow = Color.Parse("#F5F2FA"),- SurfaceContainer = Color.Parse("#EFEBF7"),- SurfaceContainerHigh = Color.Parse("#E8E2F2"),- SurfaceContainerHighest = Color.Parse("#E0D8EC"),- OnSurface = Color.Parse("#26232E"),- OnSurfaceVariant = Color.Parse("#5D5769"),- Outline = Color.Parse("#928B9F"),- OutlineVariant = Color.Parse("#D8D1E6"),- Danger = Color.Parse("#BA1A1A"),- Success = Color.Parse("#1B6D24"),- Warning = Color.Parse("#825500"),- CardShadow = BoxShadows.Parse("0 1 3 0 #12000000, 0 4 12 1 #0D000000")- };- return true;- }-- // 5. Sage & Mint (Light: #529B7D, Dark: #88D5B1)- if (ColorMatches(seed, Color.Parse("#529B7D")) || ColorMatches(seed, Color.Parse("#88D5B1")))- {- palette = isDark ? new MaterialYouPalette- {- Primary = Color.Parse("#88D5B1"),- OnPrimary = Color.Parse("#103625"),- PrimaryContainer = Color.Parse("#22513B"),- OnPrimaryContainer = Color.Parse("#DDF5EB"),- Secondary = Color.Parse("#F4BE77"),- OnSecondary = Color.Parse("#412803"),- SecondaryContainer = Color.Parse("#57390E"),- OnSecondaryContainer = Color.Parse("#FCEFD9"),- Surface = Color.Parse("#121A16"),- SurfaceDim = Color.Parse("#0C120F"),- SurfaceBright = Color.Parse("#2C3B33"),- SurfaceContainerLowest = Color.Parse("#0C120F"),- SurfaceContainerLow = Color.Parse("#17211C"),- SurfaceContainer = Color.Parse("#1D2A24"),- SurfaceContainerHigh = Color.Parse("#27332C"),- SurfaceContainerHighest = Color.Parse("#33423A"),- OnSurface = Color.Parse("#EBF2EE"),- OnSurfaceVariant = Color.Parse("#BACCC3"),- Outline = Color.Parse("#677D72"),- OutlineVariant = Color.Parse("#3B4D44"),- Danger = Color.Parse("#FFB4AB"),- Success = Color.Parse("#8CD692"),- Warning = Color.Parse("#FFBA2F"),- CardShadow = BoxShadows.Parse("0 1 3 0 #35000000, 0 8 20 0 #20000000")- } : new MaterialYouPalette- {- Primary = Color.Parse("#529B7D"),- OnPrimary = Colors.White,- PrimaryContainer = Color.Parse("#E2F3EB"),- OnPrimaryContainer = Color.Parse("#17382B"),- Secondary = Color.Parse("#DE9843"),- OnSecondary = Colors.White,- SecondaryContainer = Color.Parse("#FDF0DF"),- OnSecondaryContainer = Color.Parse("#40280D"),- Surface = Color.Parse("#F7FAF8"),- SurfaceDim = Color.Parse("#EDF3EF"),- SurfaceBright = Colors.White,- SurfaceContainerLowest = Colors.White,- SurfaceContainerLow = Color.Parse("#F0F5F2"),- SurfaceContainer = Color.Parse("#E8F0EC"),- SurfaceContainerHigh = Color.Parse("#DFEAE5"),- SurfaceContainerHighest = Color.Parse("#D3E1DA"),- OnSurface = Color.Parse("#222925"),- OnSurfaceVariant = Color.Parse("#53605A"),- Outline = Color.Parse("#889790"),- OutlineVariant = Color.Parse("#D1DDD7"),- Danger = Color.Parse("#BA1A1A"),- Success = Color.Parse("#1B6D24"),- Warning = Color.Parse("#825500"),- CardShadow = BoxShadows.Parse("0 1 3 0 #12000000, 0 4 12 1 #0D000000")- };- return true;- }-- // 6. Honey & Amber (Light: #CB852A, Dark: #F0BA6A)- if (ColorMatches(seed, Color.Parse("#CB852A")) || ColorMatches(seed, Color.Parse("#F0BA6A")))- {- palette = isDark ? new MaterialYouPalette- {- Primary = Color.Parse("#F0BA6A"),- OnPrimary = Color.Parse("#3F2500"),- PrimaryContainer = Color.Parse("#5C3908"),- OnPrimaryContainer = Color.Parse("#FDEDD5"),- Secondary = Color.Parse("#A5C98E"),- OnSecondary = Color.Parse("#1D3510"),- SecondaryContainer = Color.Parse("#2F4A20"),- OnSecondaryContainer = Color.Parse("#E6F2DE"),- Surface = Color.Parse("#1B1712"),- SurfaceDim = Color.Parse("#13100B"),- SurfaceBright = Color.Parse("#3B3226"),- SurfaceContainerLowest = Color.Parse("#13100B"),- SurfaceContainerLow = Color.Parse("#211C16"),- SurfaceContainer = Color.Parse("#27211B"),- SurfaceContainerHigh = Color.Parse("#342D24"),- SurfaceContainerHighest = Color.Parse("#41382E"),- OnSurface = Color.Parse("#F7F2E9"),- OnSurfaceVariant = Color.Parse("#CDC2B3"),- Outline = Color.Parse("#7A6F60"),- OutlineVariant = Color.Parse("#494034"),- Danger = Color.Parse("#FFB4AB"),- Success = Color.Parse("#8CD692"),- Warning = Color.Parse("#FFBA2F"),- CardShadow = BoxShadows.Parse("0 1 3 0 #35000000, 0 8 20 0 #20000000")- } : new MaterialYouPalette- {- Primary = Color.Parse("#CB852A"),- OnPrimary = Colors.White,- PrimaryContainer = Color.Parse("#FBF0DC"),- OnPrimaryContainer = Color.Parse("#422806"),- Secondary = Color.Parse("#75995E"),- OnSecondary = Colors.White,- SecondaryContainer = Color.Parse("#EBF3E5"),- OnSecondaryContainer = Color.Parse("#24361A"),- Surface = Color.Parse("#FDF9F4"),- SurfaceDim = Color.Parse("#F3ECE0"),- SurfaceBright = Colors.White,- SurfaceContainerLowest = Colors.White,- SurfaceContainerLow = Color.Parse("#FAF3E9"),- SurfaceContainer = Color.Parse("#F6EBDE"),- SurfaceContainerHigh = Color.Parse("#EFE1D0"),- SurfaceContainerHighest = Color.Parse("#E7D6C0"),- OnSurface = Color.Parse("#2A251E"),- OnSurfaceVariant = Color.Parse("#635B4E"),- Outline = Color.Parse("#9C9281"),- OutlineVariant = Color.Parse("#E3DACB"),- Danger = Color.Parse("#BA1A1A"),- Success = Color.Parse("#1B6D24"),- Warning = Color.Parse("#825500"),- CardShadow = BoxShadows.Parse("0 1 3 0 #12000000, 0 4 12 1 #0D000000")- };- return true;- }-- // 7. Cloud & Sky (Light: #5B8BE3, Dark: #98B8F6)- if (ColorMatches(seed, Color.Parse("#5B8BE3")) || ColorMatches(seed, Color.Parse("#98B8F6")) || ColorMatches(seed, Color.Parse("#A0D2EB")))- {- palette = isDark ? new MaterialYouPalette- {- Primary = Color.Parse("#98B8F6"),- OnPrimary = Color.Parse("#132B5B"),- PrimaryContainer = Color.Parse("#223E75"),- OnPrimaryContainer = Color.Parse("#E3EDFE"),- Secondary = Color.Parse("#F5A3AA"),- OnSecondary = Color.Parse("#46171B"),- SecondaryContainer = Color.Parse("#5D2429"),- OnSecondaryContainer = Color.Parse("#FDE9EB"),- Surface = Color.Parse("#131722"),- SurfaceDim = Color.Parse("#0D101A"),- SurfaceBright = Color.Parse("#2E374E"),- SurfaceContainerLowest = Color.Parse("#0D101A"),- SurfaceContainerLow = Color.Parse("#171C29"),- SurfaceContainer = Color.Parse("#1D2331"),- SurfaceContainerHigh = Color.Parse("#272E40"),- SurfaceContainerHighest = Color.Parse("#333B50"),- OnSurface = Color.Parse("#EEF3FA"),- OnSurfaceVariant = Color.Parse("#B7C3D8"),- Outline = Color.Parse("#65748F"),- OutlineVariant = Color.Parse("#394357"),- Danger = Color.Parse("#FFB4AB"),- Success = Color.Parse("#8CD692"),- Warning = Color.Parse("#FFBA2F"),- CardShadow = BoxShadows.Parse("0 1 3 0 #35000000, 0 8 20 0 #20000000")- } : new MaterialYouPalette- {- Primary = Color.Parse("#5B8BE3"),- OnPrimary = Colors.White,- PrimaryContainer = Color.Parse("#E7EFFD"),- OnPrimaryContainer = Color.Parse("#17294A"),- Secondary = Color.Parse("#E57E86"),- OnSecondary = Colors.White,- SecondaryContainer = Color.Parse("#FDECEE"),- OnSecondaryContainer = Color.Parse("#441C20"),- Surface = Color.Parse("#F8FAFD"),- SurfaceDim = Color.Parse("#ECF0F7"),- SurfaceBright = Colors.White,- SurfaceContainerLowest = Colors.White,- SurfaceContainerLow = Color.Parse("#F0F4FA"),- SurfaceContainer = Color.Parse("#E8EEF7"),- SurfaceContainerHigh = Color.Parse("#DFE6F2"),- SurfaceContainerHighest = Color.Parse("#D3DCED"),- OnSurface = Color.Parse("#22262E"),- OnSurfaceVariant = Color.Parse("#555C6B"),- Outline = Color.Parse("#8993A6"),- OutlineVariant = Color.Parse("#D0D7E5"),- Danger = Color.Parse("#BA1A1A"),- Success = Color.Parse("#1B6D24"),- Warning = Color.Parse("#825500"),- CardShadow = BoxShadows.Parse("0 1 3 0 #12000000, 0 4 12 1 #0D000000")- };- return true;- }-- // 8. Golden Parchment (Light: #8A6B24, Dark: #D4AF37 / #E8C85A)- if (ColorMatches(seed, Color.Parse("#8A6B24")) || ColorMatches(seed, Color.Parse("#D4AF37")) || ColorMatches(seed, Color.Parse("#D5B572")))- {- palette = isDark ? new MaterialYouPalette- {- Primary = Color.Parse("#E8C85A"),- OnPrimary = Color.Parse("#252219"),- PrimaryContainer = Color.Parse("#383523"),- OnPrimaryContainer = Color.Parse("#FAF6ED"),- Secondary = Color.Parse("#D4AF37"),- OnSecondary = Color.Parse("#252219"),- SecondaryContainer = Color.Parse("#2F2D1F"),- OnSecondaryContainer = Color.Parse("#FAF6ED"),- Surface = Color.Parse("#252219"),- SurfaceDim = Color.Parse("#19180F"),- SurfaceBright = Color.Parse("#423B2A"),- SurfaceContainerLowest = Color.Parse("#19180F"),- SurfaceContainerLow = Color.Parse("#1E1D13"),- SurfaceContainer = Color.Parse("#262519"),- SurfaceContainerHigh = Color.Parse("#2E2D1F"),- SurfaceContainerHighest = Color.Parse("#373525"),- OnSurface = Color.Parse("#FAF6ED"),- OnSurfaceVariant = Color.Parse("#C7C0B0"),- Outline = Color.Parse("#6B654F"),- OutlineVariant = Color.Parse("#3E3C2F"),- Danger = Color.Parse("#FFB4AB"),- Success = Color.Parse("#8CD692"),- Warning = Color.Parse("#FFBA2F"),- CardShadow = BoxShadows.Parse("0 1 3 0 #35000000, 0 8 20 0 #20000000")- } : new MaterialYouPalette- {- Primary = Color.Parse("#8A6B24"),- OnPrimary = Color.Parse("#FFFDF7"),- PrimaryContainer = Color.Parse("#EFE3C7"),- OnPrimaryContainer = Color.Parse("#2E2A1A"),- Secondary = Color.Parse("#9E7E38"),- OnSecondary = Color.Parse("#FFFDF7"),- SecondaryContainer = Color.Parse("#E8DCBA"),- OnSecondaryContainer = Color.Parse("#2E2A1A"),- Surface = Color.Parse("#FAF6ED"),- SurfaceDim = Color.Parse("#F2ECE0"),- SurfaceBright = Colors.White,- SurfaceContainerLowest = Colors.White,- SurfaceContainerLow = Color.Parse("#F5EFE0"),- SurfaceContainer = Color.Parse("#EDE4D1"),- SurfaceContainerHigh = Color.Parse("#E5D9C2"),- SurfaceContainerHighest = Color.Parse("#DCCDB0"),- OnSurface = Color.Parse("#252219"),- OnSurfaceVariant = Color.Parse("#5A5445"),- Outline = Color.Parse("#928974"),- OutlineVariant = Color.Parse("#D8CFBC"),- Danger = Color.Parse("#BA1A1A"),- Success = Color.Parse("#1B6D24"),- Warning = Color.Parse("#825500"),- CardShadow = BoxShadows.Parse("0 1 3 0 #12000000, 0 4 12 1 #0D000000")- };- return true;- }-- palette = null!;- return false;- }--- /// <summary>RGB (0..255) to HSL (H: 0..360, S: 0..1, L: 0..1).</summary>- public static (double H, double S, double L) RgbToHsl(Color c)- {- double r = c.R / 255.0, g = c.G / 255.0, b = c.B / 255.0;- double max = Math.Max(r, Math.Max(g, b));- double min = Math.Min(r, Math.Min(g, b));- double h = 0, s = 0, l = (max + min) / 2.0;-- if (Math.Abs(max - min) > 1e-5)- {- double d = max - min;- s = l > 0.5 ? d / (2.0 - max - min) : d / (max + min);- if (Math.Abs(max - r) < 1e-5)- h = (g - b) / d + (g < b ? 6 : 0);- else if (Math.Abs(max - g) < 1e-5)- h = (b - r) / d + 2;- else- h = (r - g) / d + 4;- h /= 6.0;- }- return (h * 360.0, s, l);- }-- /// <summary>HSL (H: 0..360, S: 0..1, L: 0..1) to RGB Color.</summary>- public static Color HslToRgb(double h, double s, double l, byte a = 255)- {- h = (h % 360 + 360) % 360;- s = Math.Clamp(s, 0, 1);- l = Math.Clamp(l, 0, 1);-- if (s <= 1e-5)- {- var v = (byte)Math.Round(l * 255);- return Color.FromArgb(a, v, v, v);- }-- double q = l < 0.5 ? l * (1 + s) : l + s - l * s;- double p = 2 * l - q;- double hk = h / 360.0;-- byte Component(double tc)- {- if (tc < 0) tc += 1;- if (tc > 1) tc -= 1;- if (tc < 1.0 / 6.0) return (byte)Math.Round((p + (q - p) * 6.0 * tc) * 255);- if (tc < 1.0 / 2.0) return (byte)Math.Round(q * 255);- if (tc < 2.0 / 3.0) return (byte)Math.Round((p + (q - p) * (2.0 / 3.0 - tc) * 6.0) * 255);- return (byte)Math.Round(p * 255);- }-- return Color.FromArgb(a, Component(hk + 1.0 / 3.0), Component(hk), Component(hk - 1.0 / 3.0));- }-}diff --git a/src/Filee.App/Services/ThemeService.cs b/src/Filee.App/Services/ThemeService.csindex af3164d8..2ac2dd08 100644--- a/src/Filee.App/Services/ThemeService.cs+++ b/src/Filee.App/Services/ThemeService.cs@@ -1,10 +1,9 @@-// Applies ThemeSettings (light/dark, accent colour, corner radius, font order, reduced motion, theme style) and the user's+// Applies ThemeSettings (light/dark, accent colour, corner radius, font order, reduced motion) and the user's// theme.json colours at runtime by writing resources into Application.Resources. All styles reference these with// DynamicResource.using Avalonia;using Avalonia.Controls;-using Avalonia.Controls.ApplicationLifetimes;using Avalonia.Media;using Avalonia.Styling;using Filee.Core.Platform;@@ -13,69 +12,11 @@ using Filee.Core.Settings;namespace Filee.App.Services;/// <summary>Runtime theming.</summary>-public sealed class ThemeService+public sealed class ThemeService(IPlatformServices platform){- private readonly IPlatformServices _platform;-- private static readonly List<WeakReference<Window>> s_openWindows = [];-- public ThemeService(IPlatformServices platform)- {- _platform = platform;- Window.WindowOpenedEvent.AddClassHandler<Window>((w, _) =>- {- lock (s_openWindows)- {- s_openWindows.RemoveAll(r => !r.TryGetTarget(out var target) || target == w);- s_openWindows.Add(new WeakReference<Window>(w));- }- if (IsMaterialYou)- w.Classes.Set("material-you", true);- });- Window.WindowClosedEvent.AddClassHandler<Window>((w, _) =>- {- lock (s_openWindows)- {- s_openWindows.RemoveAll(r => !r.TryGetTarget(out var target) || target == w);- }- });- }-- /// <summary>Accent swatches offered in the Theme page for Soft theme.</summary>+ /// <summary>Accent swatches offered in the Theme page.</summary>public static readonly IReadOnlyList<string> Swatches =- ["#7F77DD", "#1D9E75", "#D85A30", "#378ADD", "#D4537E", "#BA7517", "#639922", "#5F5E5A", "#111111", "#FFFFFF"];-- /// <summary>Curated Material 3 seed swatches for Material You theme.</summary>- public static readonly IReadOnlyList<string> MaterialYouSwatches =- ["#6750A4", "#0B57D0", "#006C4C", "#B3261E", "#825500", "#7F77DD", "#006A6A", "#4C616B", "#111111", "#FFFFFF"];-- /// <summary>Inkora pastel preset definition with coordinated light and dark seeds.</summary>- public sealed record InkoraPastelPreset(string Key, string Name, string LightHex, string DarkHex);-- /// <summary>Curated Inkora pastel and monochrome presets with name and light/dark color mappings.</summary>- public static readonly IReadOnlyList<InkoraPastelPreset> InkoraPresets =- [- new("monochrome", "Black & White", "#111111", "#FFFFFF"),- new("blushPeach", "Blush & Peach", "#E07A70", "#F29B91"),- new("strawberryMilk", "Strawberry Milk", "#E86483", "#F79BB0"),- new("matchaLatte", "Matcha Latte", "#5A8E51", "#8DC983"),- new("lavenderMist", "Lavender Mist", "#8B7AB8", "#BCAEE5"),- new("sageMint", "Sage & Mint", "#529B7D", "#88D5B1"),- new("honeyAmber", "Honey & Amber", "#CB852A", "#F0BA6A"),- new("cloudSky", "Cloud & Sky", "#5B8BE3", "#98B8F6"),- new("goldenParchment", "Golden Parchment", "#8A6B24", "#D4AF37"),- ];-- /// <summary>Curated pastel palette add-on swatches from Inkora for both Material You and System/Soft themes.</summary>- public static readonly IReadOnlyList<string> PastelSwatches =- ["#E07A70", "#E86483", "#5A8E51", "#8B7AB8", "#529B7D", "#CB852A", "#5B8BE3", "#8A6B24",- "#F29B91", "#F79BB0", "#8DC983", "#BCAEE5", "#88D5B1", "#F0BA6A", "#98B8F6", "#D4AF37"];-- /// <summary>Currently active theme style.</summary>- public ThemeStyle CurrentStyle { get; private set; } = ThemeStyle.Soft;-- /// <summary>True when the Material You theme is currently applied.</summary>- public bool IsMaterialYou => CurrentStyle == ThemeStyle.MaterialYou;+ ["#7F77DD", "#1D9E75", "#D85A30", "#378ADD", "#D4537E", "#BA7517", "#639922", "#5F5E5A"];/// <summary>/// theme.json colour names → the brushes in Styles/Soft.axaml they replace. Must cover exactly@@ -99,10 +40,6 @@ public sealed class ThemeServicevar app = Application.Current ?? throw new InvalidOperationException("No application.");var res = app.Resources;- CurrentStyle = theme.Style;- var isM3 = theme.Style == ThemeStyle.MaterialYou;- res["IsMaterialYouTheme"] = isM3;-app.RequestedThemeVariant = theme.Mode switch{ThemeMode.Light => ThemeVariant.Light,@@ -110,160 +47,16 @@ public sealed class ThemeService_ => ThemeVariant.Default,};- // Accent colour + derived shades. Fluent controls read the System* keys.- var accent = Color.TryParse(theme.Accent, out var parsed) ? parsed : Color.Parse(isM3 ? "#6750A4" : SoftPalette.DefaultAccent);-- var isDarkVariant = theme.Mode switch- {- ThemeMode.Dark => true,- ThemeMode.Light => false,- _ => app.ActualThemeVariant == ThemeVariant.Dark- };-- if (isM3)- {- var lightM3 = MaterialYouPalette.Generate(accent, isDark: false);- var darkM3 = MaterialYouPalette.Generate(accent, isDark: true);- var activeM3 = isDarkVariant ? darkM3 : lightM3;-- res["AccentColor"] = activeM3.Primary;- res["AccentBrush"] = new SolidColorBrush(activeM3.Primary);- res["AccentSoftBrush"] = new SolidColorBrush(activeM3.PrimaryContainer);- res["AccentFaintBrush"] = new SolidColorBrush(activeM3.SecondaryContainer);- res["AccentStrongBrush"] = new SolidColorBrush(activeM3.OnPrimaryContainer);- res["OnAccentBrush"] = new SolidColorBrush(activeM3.OnPrimary);-- res["PrimaryContainerBrush"] = new SolidColorBrush(activeM3.PrimaryContainer);- res["OnPrimaryContainerBrush"] = new SolidColorBrush(activeM3.OnPrimaryContainer);- res["SecondaryContainerBrush"] = new SolidColorBrush(activeM3.SecondaryContainer);- res["OnSecondaryContainerBrush"] = new SolidColorBrush(activeM3.OnSecondaryContainer);-- res["SystemAccentColor"] = activeM3.Primary;- res["SystemAccentColorLight1"] = SoftPalette.Shade(activeM3.Primary, 0.15);- res["SystemAccentColorLight2"] = SoftPalette.Shade(activeM3.Primary, 0.30);- res["SystemAccentColorLight3"] = SoftPalette.Shade(activeM3.Primary, 0.45);- res["SystemAccentColorDark1"] = SoftPalette.Shade(activeM3.Primary, -0.15);- res["SystemAccentColorDark2"] = SoftPalette.Shade(activeM3.Primary, -0.30);- res["SystemAccentColorDark3"] = SoftPalette.Shade(activeM3.Primary, -0.45);-- // Fluent control brush keys harmonized with M3 roles- res["SliderTrackFill"] = new SolidColorBrush(activeM3.Primary);- res["SliderTrackValueFill"] = new SolidColorBrush(activeM3.Primary);- res["SliderThumbBackground"] = new SolidColorBrush(activeM3.Primary);- res["SliderThumbBorderBrush"] = new SolidColorBrush(activeM3.Primary);- res["SliderTrackBackground"] = new SolidColorBrush(activeM3.SurfaceContainerHighest);- res["ProgressBarTrackFill"] = new SolidColorBrush(activeM3.Primary);- res["ProgressBarBackground"] = new SolidColorBrush(activeM3.SurfaceContainerHighest);- res["ProgressBarProgress"] = new SolidColorBrush(activeM3.Primary);- res["ToggleSwitchFillOn"] = new SolidColorBrush(activeM3.Primary);- res["ToggleSwitchFillOff"] = new SolidColorBrush(activeM3.SurfaceContainerHighest);- res["ToggleSwitchKnobFillOn"] = new SolidColorBrush(activeM3.OnPrimary);- res["ToggleSwitchKnobFillOff"] = new SolidColorBrush(activeM3.Outline);- res["ToggleSwitchStrokeOff"] = new SolidColorBrush(activeM3.Outline);- res["CheckBoxCheckBackgroundFillChecked"] = new SolidColorBrush(activeM3.Primary);- res["CheckBoxCheckBackgroundStrokeChecked"] = new SolidColorBrush(activeM3.Primary);- res["CheckBoxCheckGlyphForegroundChecked"] = new SolidColorBrush(activeM3.OnPrimary);- res["AccentButtonBackground"] = new SolidColorBrush(activeM3.Primary);- res["AccentButtonForeground"] = new SolidColorBrush(activeM3.OnPrimary);- res["AccentButtonBackgroundPointerOver"] = new SolidColorBrush(activeM3.Secondary);- res["AccentButtonForegroundPointerOver"] = new SolidColorBrush(activeM3.OnSecondary);- res["AccentButtonBackgroundPressed"] = new SolidColorBrush(activeM3.PrimaryContainer);- res["AccentButtonForegroundPressed"] = new SolidColorBrush(activeM3.OnPrimaryContainer);-- // "Softness": Material You expressive pill and rounded containers- var r = Math.Clamp(theme.CornerRadius, 0, 28);- res["SoftRadius"] = new CornerRadius(Math.Max(16, r));- res["SoftRadiusSmall"] = new CornerRadius(12);- res["SoftRadiusLarge"] = new CornerRadius(24);- res["PillRadius"] = new CornerRadius(999);- res["ControlCornerRadius"] = new CornerRadius(12);- res["OverlayCornerRadius"] = new CornerRadius(20);-- ApplyMaterialYouTheme(res, ThemeVariant.Light, lightM3, custom?.Light);- ApplyMaterialYouTheme(res, ThemeVariant.Dark, darkM3, custom?.Dark);- }- else- {- SoftPalette.ApplyAccent(res, accent);- SoftPalette.ApplyCornerRadius(res, theme.CornerRadius);- res["PillRadius"] = new CornerRadius(999);-- res["DropZoneBackgroundBrush"] = isDarkVariant- ? new SolidColorBrush(Color.Parse("#252523"))- : new SolidColorBrush(Color.Parse("#F5F3ED"));- res["DropZoneBorderBrush"] = new SolidColorBrush(accent, 0.25);-- res["AccentButtonBackground"] = res["AccentBrush"];- res["AccentButtonForeground"] = res["OnAccentBrush"];- res["AccentButtonBackgroundPointerOver"] = res["AccentStrongBrush"];- res["AccentButtonForegroundPointerOver"] = res["OnAccentBrush"];- res["AccentButtonBackgroundPressed"] = res["AccentFaintBrush"];- res["AccentButtonForegroundPressed"] = res["OnAccentBrush"];-- // Clean up M3 Fluent overrides if present- res.Remove("SliderTrackFill");- res.Remove("SliderTrackValueFill");- res.Remove("SliderThumbBackground");- res.Remove("SliderThumbBorderBrush");- res.Remove("SliderTrackBackground");- res.Remove("ProgressBarTrackFill");- res.Remove("ProgressBarBackground");- res.Remove("ProgressBarProgress");- res.Remove("ToggleSwitchFillOn");- res.Remove("ToggleSwitchFillOff");- res.Remove("ToggleSwitchKnobFillOn");- res.Remove("ToggleSwitchKnobFillOff");- res.Remove("ToggleSwitchStrokeOff");- res.Remove("CheckBoxCheckBackgroundFillChecked");- res.Remove("CheckBoxCheckBackgroundStrokeChecked");- res.Remove("CheckBoxCheckGlyphForegroundChecked");-- ApplyCustom(res, ThemeVariant.Light, custom?.Light);- ApplyCustom(res, ThemeVariant.Dark, custom?.Dark);- }-+ // Accent colour + derived shades, corner radii and the font order (shared with the installer).+ SoftPalette.ApplyAccent(res, Color.TryParse(theme.Accent, out var parsed) ? parsed : Color.Parse(SoftPalette.DefaultAccent));+ SoftPalette.ApplyCornerRadius(res, theme.CornerRadius);res["AppFontFamily"] = SoftPalette.FontFamilyFor(language);- // Update all active windows- lock (s_openWindows)- {- s_openWindows.RemoveAll(r => !r.TryGetTarget(out _));- foreach (var r in s_openWindows)- if (r.TryGetTarget(out var window))- window.Classes.Set("material-you", isM3);- }- if (app.ApplicationLifetime is IClassicDesktopStyleApplicationLifetime desktop)- {- foreach (var window in desktop.Windows)- window.Classes.Set("material-you", isM3);- }-- Motion.Configure(theme.ReduceMotion, () => _platform.PrefersReducedMotion);- }-- /// <summary>Applies Material You generated colors to the theme dictionary for one variant.</summary>- private static void ApplyMaterialYouTheme(IResourceDictionary res, ThemeVariant variant, MaterialYouPalette m3, IReadOnlyDictionary<string, string>? custom)- {- var dict = new ResourceDictionary- {- ["PageBrush"] = new SolidColorBrush(m3.SurfaceContainerLowest),- ["SurfaceBrush"] = new SolidColorBrush(m3.Surface),- ["SurfaceAltBrush"] = new SolidColorBrush(m3.SurfaceContainerHigh),- ["SubtleBorderBrush"] = new SolidColorBrush(m3.OutlineVariant),- ["TextPrimaryBrush"] = new SolidColorBrush(m3.OnSurface),- ["TextSecondaryBrush"] = new SolidColorBrush(m3.OnSurfaceVariant),- ["DangerBrush"] = new SolidColorBrush(m3.Danger),- ["SuccessBrush"] = new SolidColorBrush(m3.Success),- ["WarningBrush"] = new SolidColorBrush(m3.Warning),- ["CardShadow"] = m3.CardShadow,- };-- // Custom colours from theme.json take precedence if present- foreach (var (name, value) in custom ?? new Dictionary<string, string>())- if (CustomBrushKeys.TryGetValue(name, out var key) && Color.TryParse(value, out var color))- dict[key] = new SolidColorBrush(color);+ // Application.Resources is searched before the styles, so these theme dictionaries win over Soft.axaml's.+ ApplyCustom(res, ThemeVariant.Light, custom?.Light);+ ApplyCustom(res, ThemeVariant.Dark, custom?.Dark);- res.ThemeDictionaries[variant] = dict;+ Motion.Configure(theme.ReduceMotion, () => platform.PrefersReducedMotion);}/// <summary>The UI font chain for <paramref name="language"/> (see <see cref="SoftPalette.FontFamilies"/>).</summary>diff --git a/src/Filee.App/Services/WindowService.cs b/src/Filee.App/Services/WindowService.csindex d639637d..54eea3e7 100644--- a/src/Filee.App/Services/WindowService.cs+++ b/src/Filee.App/Services/WindowService.cs@@ -71,10 +71,6 @@ public sealed class WindowService(ILocalizer loc, IServiceProvider services, Memif (page is null)model.Navigate(placement.Page);}- else if (page is null)- {- model.Navigate("home");- }main.Closing += (_, _) =>{// While it is still on screen: the release closes it hidden, when its position may no longer be known.diff --git a/src/Filee.App/Styles/Controls.axaml b/src/Filee.App/Styles/Controls.axamlindex df4e2f13..2894ad81 100644--- a/src/Filee.App/Styles/Controls.axaml+++ b/src/Filee.App/Styles/Controls.axaml@@ -16,8 +16,4 @@<Setter Property="DangerBrush" Value="{DynamicResource DangerBrush}" /><Setter Property="SuccessBrush" Value="{DynamicResource SuccessBrush}" /></Style>-- <Style Selector="Window.material-you c|DonutMenu, c|DonutMenu.material-you">- <Setter Property="IsMaterialYou" Value="True" />- </Style></Styles>diff --git a/src/Filee.App/Styles/Soft.axaml b/src/Filee.App/Styles/Soft.axamlindex 0ccf5a48..add41e68 100644--- a/src/Filee.App/Styles/Soft.axaml+++ b/src/Filee.App/Styles/Soft.axaml@@ -133,7 +133,7 @@</Style><!-- ───────── Buttons: soft corners and a springy press ───────── -->- <Style Selector="Button, ToggleButton">+ <Style Selector="Button, ToggleButton, RepeatButton"><Setter Property="CornerRadius" Value="{DynamicResource SoftRadiusSmall}" /><Setter Property="Padding" Value="14,7" /><Setter Property="Transitions">@@ -162,106 +162,14 @@<Setter Property="BorderThickness" Value="0" /></Style>- <!-- Choice Cards (Theme Style, Format cards) -->- <Style Selector="Button.choice-card">- <Setter Property="CornerRadius" Value="16" />- <Setter Property="Padding" Value="16,14" />- <Setter Property="MinHeight" Value="115" />- <Setter Property="Background" Value="{DynamicResource CardBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource SubtleBorderBrush}" />- <Setter Property="BorderThickness" Value="1.5" />- <Setter Property="HorizontalAlignment" Value="Stretch" />- <Setter Property="VerticalAlignment" Value="Stretch" />- <Setter Property="HorizontalContentAlignment" Value="Stretch" />- <Setter Property="VerticalContentAlignment" Value="Stretch" />- <Setter Property="Transitions">- <Transitions>- <TransformOperationsTransition Property="RenderTransform" Duration="0:0:0.18" Easing="{StaticResource SoftEase}" />- <BrushTransition Property="Background" Duration="0:0:0.18" />- <BrushTransition Property="BorderBrush" Duration="0:0:0.18" />- </Transitions>- </Setter>- </Style>- <Style Selector="Button.choice-card:pointerover">- <Setter Property="Background" Value="{DynamicResource SurfaceAltBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentSoftBrush}" />- </Style>- <Style Selector="Button.choice-card.selected">- <Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentBrush}" />- <Setter Property="BorderThickness" Value="1.5" />- </Style>- <Style Selector="Button.choice-card TextBlock.choice-title">- <Setter Property="FontSize" Value="13" />- <Setter Property="FontWeight" Value="SemiBold" />- <Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}" />- </Style>- <Style Selector="Button.choice-card.selected TextBlock.choice-title">- <Setter Property="Foreground" Value="{DynamicResource AccentStrongBrush}" />- <Setter Property="FontWeight" Value="Bold" />- </Style>- <Style Selector="Button.choice-card TextBlock.choice-desc">- <Setter Property="FontSize" Value="12" />- <Setter Property="Foreground" Value="{DynamicResource TextSecondaryBrush}" />- <Setter Property="LineHeight" Value="17" />- </Style>- <Style Selector="Button.choice-card.selected TextBlock.choice-desc">- <Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}" />- </Style>-- <!-- ───────── Progress bars / Loaders ───────── -->- <Style Selector="ProgressBar">- <Setter Property="CornerRadius" Value="999" />- <Setter Property="MinHeight" Value="6" />- <Setter Property="Height" Value="6" />- <Setter Property="Foreground" Value="{DynamicResource AccentBrush}" />- <Setter Property="Background" Value="{DynamicResource SurfaceAltBrush}" />- </Style><Style Selector="ProgressBar.soft"><Setter Property="CornerRadius" Value="999" /><Setter Property="MinHeight" Value="6" /><Setter Property="Height" Value="6" /></Style>- <!-- ───────── Seekbars / Sliders ───────── -->- <Style Selector="Slider">- <Setter Property="Foreground" Value="{DynamicResource AccentBrush}" />- </Style>- <Style Selector="Slider:horizontal">- <Setter Property="MinHeight" Value="36" />- </Style>- <Style Selector="Slider:horizontal /template/ Border#TrackBackground">- <Setter Property="Height" Value="8" />- <Setter Property="CornerRadius" Value="999" />- </Style>- <Style Selector="Slider:horizontal /template/ RepeatButton#PART_DecreaseButton /template/ Border">- <Setter Property="Height" Value="8" />- <Setter Property="CornerRadius" Value="999" />- <Setter Property="Background" Value="{DynamicResource AccentBrush}" />- </Style>- <Style Selector="Slider:horizontal /template/ RepeatButton#PART_IncreaseButton /template/ Border">- <Setter Property="Height" Value="8" />- <Setter Property="CornerRadius" Value="999" />- </Style>- <Style Selector="Slider:horizontal /template/ Thumb#PART_Thumb">- <Setter Property="Width" Value="20" />- <Setter Property="Height" Value="20" />- <Setter Property="CornerRadius" Value="999" />- <Setter Property="Background" Value="{DynamicResource AccentBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource SurfaceBrush}" />- <Setter Property="BorderThickness" Value="2" />- <Setter Property="Transitions">- <Transitions>- <TransformOperationsTransition Property="RenderTransform" Duration="0:0:0.18" Easing="{StaticResource SoftEase}" />- </Transitions>- </Setter>- </Style>- <Style Selector="Slider:horizontal /template/ Thumb#PART_Thumb:pointerover">- <Setter Property="RenderTransform" Value="scale(1.18)" />- </Style>-<Style Selector="TextBox, ComboBox, NumericUpDown">- <Setter Property="CornerRadius" Value="12" />+ <Setter Property="CornerRadius" Value="{DynamicResource SoftRadiusSmall}" /></Style><!-- ───────── Navigation list ───────── -->@@ -296,684 +204,12 @@<Setter Property="Background" Value="Transparent" /></Style><Style Selector="ListBox.soft ListBoxItem">- <Setter Property="CornerRadius" Value="12" />- <Setter Property="Padding" Value="12,8" />- <Setter Property="Margin" Value="2,1,6,1" />- </Style>- <Style Selector="ListBox.soft ListBoxItem:selected /template/ ContentPresenter#PART_ContentPresenter">- <Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- </Style>-- <!-- ───────── Material You (M3) design system ───────── -->-- <!-- Typography & Headings -->- <Style Selector="Window.material-you TextBlock.h1">- <Setter Property="FontSize" Value="26" />- <Setter Property="FontWeight" Value="SemiBold" />- <Setter Property="Margin" Value="0,0,0,4" />- </Style>- <Style Selector="Window.material-you TextBlock.h2">- <Setter Property="FontSize" Value="18" />- <Setter Property="FontWeight" Value="SemiBold" />- </Style>- <Style Selector="Window.material-you TextBlock.label">- <Setter Property="FontSize" Value="13" />- <Setter Property="FontWeight" Value="Medium" />- <Setter Property="Margin" Value="0,0,0,6" />- </Style>-- <!-- Cards: M3 elevated tonal surface, 20px corners, non-clipping -->- <Style Selector="Window.material-you Border.card">- <Setter Property="CornerRadius" Value="20" />- <Setter Property="Padding" Value="20,16" />- <Setter Property="Background" Value="{DynamicResource SurfaceContainerBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource SubtleBorderBrush}" />- <Setter Property="BorderThickness" Value="1" />- <Setter Property="BoxShadow" Value="{DynamicResource CardShadow}" />- <Setter Property="ClipToBounds" Value="False" />- </Style>-- <!-- Navigation items -->- <Style Selector="Window.material-you ListBox.nav ListBoxItem">- <Setter Property="CornerRadius" Value="999" />- <Setter Property="Padding" Value="16,10" />- <Setter Property="Margin" Value="0,2" />- <Setter Property="Transitions">- <Transitions>- <TransformOperationsTransition Property="RenderTransform" Duration="0:0:0.25" Easing="{StaticResource SoftEase}" />- <BrushTransition Property="Background" Duration="0:0:0.18" />- </Transitions>- </Setter>- </Style>- <Style Selector="Window.material-you ListBox.nav ListBoxItem:pointerover">- <Setter Property="RenderTransform" Value="scale(1.02)" />- </Style>- <Style Selector="Window.material-you ListBox.nav ListBoxItem:selected /template/ ContentPresenter#PART_ContentPresenter">- <Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- <Setter Property="Foreground" Value="{DynamicResource AccentStrongBrush}" />- <Setter Property="FontWeight" Value="SemiBold" />- </Style>- <Style Selector="Window.material-you ListBox.nav ListBoxItem:selected:pointerover /template/ ContentPresenter#PART_ContentPresenter">- <Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- </Style>-- <!-- List tiles (Presets, Profiles, Suggestions) -->- <Style Selector="Window.material-you ListBox.soft ListBoxItem">- <Setter Property="CornerRadius" Value="14" />- <Setter Property="Padding" Value="14,10" />- <Setter Property="Margin" Value="2,2,6,2" />- <Setter Property="Transitions">- <Transitions>- <TransformOperationsTransition Property="RenderTransform" Duration="0:0:0.22" Easing="{StaticResource SoftEase}" />- <BrushTransition Property="Background" Duration="0:0:0.18" />- </Transitions>- </Setter>- </Style>- <Style Selector="Window.material-you ListBox.soft ListBoxItem:pointerover">- <Setter Property="RenderTransform" Value="translateX(2px)" />- </Style>- <Style Selector="Window.material-you ListBox.soft ListBoxItem:selected /template/ ContentPresenter#PART_ContentPresenter">- <Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- <Setter Property="Foreground" Value="{DynamicResource AccentStrongBrush}" />- <Setter Property="FontWeight" Value="SemiBold" />- </Style>- <Style Selector="Window.material-you ListBox.soft ListBoxItem:selected:pointerover /template/ ContentPresenter#PART_ContentPresenter">- <Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- </Style>-- <!-- DropZone tile: dark tonal surface with subtle border -->- <Style Selector="Window.material-you Border#DropZone">- <Setter Property="CornerRadius" Value="24" />- <Setter Property="Padding" Value="28,24" />- <Setter Property="Background" Value="{DynamicResource SurfaceContainerLowBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource SubtleBorderBrush}" />- <Setter Property="BoxShadow" Value="{DynamicResource CardShadow}" />- </Style>- <Style Selector="Window.material-you Border#DropZone.over">- <Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentBrush}" />- <Setter Property="RenderTransform" Value="scale(1.02)" />- </Style>-- <!-- Buttons: M3 full pill with spring press (excluding multi-line choice cards) -->- <Style Selector="Window.material-you Button:not(.choice-card), Window.material-you ToggleButton">- <Setter Property="CornerRadius" Value="999" />- <Setter Property="Padding" Value="18,8" />- <Setter Property="FontWeight" Value="Medium" />- <Setter Property="Transitions">- <Transitions>- <TransformOperationsTransition Property="RenderTransform" Duration="0:0:0.20" Easing="{StaticResource SoftEase}" />- <BrushTransition Property="Background" Duration="0:0:0.18" />- </Transitions>- </Setter>- </Style>- <Style Selector="Window.material-you Button:not(.choice-card):pointerover, Window.material-you ToggleButton:pointerover">- <Setter Property="RenderTransform" Value="scale(1.02)" />- </Style>- <Style Selector="Window.material-you Button:not(.choice-card):pressed, Window.material-you ToggleButton:pressed">- <Setter Property="RenderTransform" Value="scale(0.94)" />- </Style>-- <!-- Multi-line Choice Cards in Material You -->- <Style Selector="Window.material-you Button.choice-card">- <Setter Property="CornerRadius" Value="16" />- <Setter Property="Padding" Value="16,14" />- <Setter Property="MinHeight" Value="115" />- <Setter Property="VerticalAlignment" Value="Stretch" />- <Setter Property="VerticalContentAlignment" Value="Stretch" />- <Setter Property="Background" Value="{DynamicResource CardBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource SubtleBorderBrush}" />- <Setter Property="BorderThickness" Value="1.5" />- <Setter Property="RenderTransform" Value="none" />- </Style>- <Style Selector="Window.material-you Button.choice-card:pointerover">- <Setter Property="Background" Value="{DynamicResource SurfaceAltBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentSoftBrush}" />- <Setter Property="RenderTransform" Value="none" />- </Style>- <Style Selector="Window.material-you Button.choice-card.selected">- <Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentBrush}" />- <Setter Property="BorderThickness" Value="1.5" />- <Setter Property="CornerRadius" Value="16" />- <Setter Property="RenderTransform" Value="none" />- </Style>- <Style Selector="Window.material-you Button.choice-card.selected:pointerover">- <Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentStrongBrush}" />- <Setter Property="RenderTransform" Value="none" />- </Style>-- <!-- Standard action buttons in Material You (Clear history, Export, Import, Reset, etc.) -->- <Style Selector="Window.material-you Button:not(.accent):not(.ghost):not(.icon):not(.navlink):not(.swatch):not(.preset-pill):not(.tonal):not(.choice-card)">- <Setter Property="Background" Value="{DynamicResource SurfaceAltBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource SubtleBorderBrush}" />- <Setter Property="BorderThickness" Value="1" />- <Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}" />- </Style>- <Style Selector="Window.material-you Button:not(.accent):not(.ghost):not(.icon):not(.navlink):not(.swatch):not(.preset-pill):not(.tonal):not(.choice-card):pointerover">- <Setter Property="Background" Value="{DynamicResource SurfaceContainerHighestBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentBrush}" />- <Setter Property="RenderTransform" Value="scale(1.02)" />- </Style>-- <!-- Swatch buttons for theme selection -->- <Style Selector="Button.swatch">- <Setter Property="Width" Value="32" />- <Setter Property="Height" Value="32" />- <Setter Property="CornerRadius" Value="999" />- <Setter Property="Padding" Value="0" />- <Setter Property="BorderThickness" Value="2" />- <Setter Property="BorderBrush" Value="Transparent" />- <Setter Property="RenderTransform" Value="none" />- <Setter Property="Transitions">- <Transitions>- <TransformOperationsTransition Property="RenderTransform" Duration="0:0:0.18" Easing="{StaticResource SoftEase}" />- <BrushTransition Property="BorderBrush" Duration="0:0:0.18" />- </Transitions>- </Setter>- </Style>- <Style Selector="Button.swatch:pointerover">- <Setter Property="RenderTransform" Value="scale(1.22)" />- <Setter Property="BorderBrush" Value="{DynamicResource TextPrimaryBrush}" />- </Style>- <Style Selector="Button.swatch:pointerover /template/ ContentPresenter#PART_ContentPresenter">- <Setter Property="Background" Value="{TemplateBinding Background}" />- </Style>- <Style Selector="Button.swatch:pressed /template/ ContentPresenter#PART_ContentPresenter">- <Setter Property="Background" Value="{TemplateBinding Background}" />- <Setter Property="Opacity" Value="0.82" />- </Style>-- <!-- Preset pill buttons in Theme Page -->- <Style Selector="Button.preset-pill">- <Setter Property="CornerRadius" Value="999" />- <Setter Property="Padding" Value="10,6" />- <Setter Property="Background" Value="{DynamicResource SurfaceBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource SubtleBorderBrush}" />- <Setter Property="BorderThickness" Value="1" />- <Setter Property="Transitions">- <Transitions>- <TransformOperationsTransition Property="RenderTransform" Duration="0:0:0.18" Easing="{StaticResource SoftEase}" />- <BrushTransition Property="Background" Duration="0:0:0.18" />- <BrushTransition Property="BorderBrush" Duration="0:0:0.18" />- </Transitions>- </Setter>- </Style>- <Style Selector="Button.preset-pill:pointerover">- <Setter Property="RenderTransform" Value="scale(1.03)" />- <Setter Property="Background" Value="{DynamicResource SurfaceAltBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentBrush}" />- </Style>- <Style Selector="Button.preset-pill:pressed">- <Setter Property="RenderTransform" Value="scale(0.96)" />- </Style>- <Style Selector="Button.preset-pill:pointerover /template/ ContentPresenter#PART_ContentPresenter">- <Setter Property="Background" Value="{DynamicResource SurfaceAltBrush}" />- </Style>-- <!-- Filled Accent Button -->- <Style Selector="Button.accent, Window.material-you Button.accent">- <Setter Property="Background" Value="{DynamicResource AccentBrush}" />- <Setter Property="Foreground" Value="{DynamicResource OnAccentBrush}" />- <Setter Property="BorderThickness" Value="0" />- <Setter Property="FontWeight" Value="SemiBold" />- </Style>- <Style Selector="Button.accent /template/ ContentPresenter#PART_ContentPresenter, Window.material-you Button.accent /template/ ContentPresenter#PART_ContentPresenter">- <Setter Property="Background" Value="{DynamicResource AccentBrush}" />- <Setter Property="Foreground" Value="{DynamicResource OnAccentBrush}" />- <Setter Property="BorderThickness" Value="0" />- </Style>- <Style Selector="Button.accent:pointerover /template/ ContentPresenter#PART_ContentPresenter, Window.material-you Button.accent:pointerover /template/ ContentPresenter#PART_ContentPresenter">- <Setter Property="Background" Value="{DynamicResource AccentButtonBackgroundPointerOver}" />- <Setter Property="Foreground" Value="{DynamicResource OnAccentBrush}" />- <Setter Property="BorderThickness" Value="0" />- </Style>- <Style Selector="Button.accent:pressed /template/ ContentPresenter#PART_ContentPresenter, Window.material-you Button.accent:pressed /template/ ContentPresenter#PART_ContentPresenter">- <Setter Property="Background" Value="{DynamicResource AccentFaintBrush}" />- <Setter Property="Foreground" Value="{DynamicResource OnAccentBrush}" />- <Setter Property="BorderThickness" Value="0" />- </Style>- <Style Selector="Button.accent PathIcon, Window.material-you Button.accent PathIcon,- Button.accent:pointerover PathIcon, Window.material-you Button.accent:pointerover PathIcon,- Button.accent:pressed PathIcon, Window.material-you Button.accent:pressed PathIcon">- <Setter Property="Foreground" Value="{DynamicResource OnAccentBrush}" />- </Style>- <Style Selector="Button.accent TextBlock, Window.material-you Button.accent TextBlock,- Button.accent:pointerover TextBlock, Window.material-you Button.accent:pointerover TextBlock,- Button.accent:pressed TextBlock, Window.material-you Button.accent:pressed TextBlock">- <Setter Property="Foreground" Value="{DynamicResource OnAccentBrush}" />- <Setter Property="FontWeight" Value="SemiBold" />- </Style>- <Style Selector="Button.accent:pointerover, Window.material-you Button.accent:pointerover">- <Setter Property="RenderTransform" Value="scale(1.02)" />- </Style>-- <!-- Filled Tonal Button -->- <Style Selector="Window.material-you Button.tonal">- <Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- <Setter Property="Foreground" Value="{DynamicResource AccentStrongBrush}" />- <Setter Property="BorderThickness" Value="0" />- </Style>-- <!-- Ghost / Text Button -->- <Style Selector="Window.material-you Button.ghost">- <Setter Property="Background" Value="Transparent" />- <Setter Property="BorderThickness" Value="0" />- <Setter Property="Foreground" Value="{DynamicResource AccentBrush}" />- </Style>- <Style Selector="Window.material-you Button.ghost:pointerover">- <Setter Property="Background" Value="{DynamicResource AccentFaintBrush}" />- </Style>-- <!-- Navlink Button -->- <Style Selector="Window.material-you Button.navlink">- <Setter Property="CornerRadius" Value="999" />- <Setter Property="Padding" Value="12,7" />- <Setter Property="Background" Value="{DynamicResource SurfaceAltBrush}" />- <Setter Property="BorderThickness" Value="0" />- </Style>- <Style Selector="Window.material-you Button.navlink:pointerover">- <Setter Property="Background" Value="{DynamicResource AccentFaintBrush}" />- </Style>-- <!-- Icon Button -->- <Style Selector="Window.material-you Button.icon">- <Setter Property="CornerRadius" Value="999" />- <Setter Property="Padding" Value="8" />- <Setter Property="Background" Value="Transparent" />- <Setter Property="BorderThickness" Value="0" />- </Style>- <Style Selector="Window.material-you Button.icon:pointerover">- <Setter Property="Background" Value="{DynamicResource AccentFaintBrush}" />- </Style>-- <!-- Chips & Badges -->- <Style Selector="Window.material-you Border.chip">- <Setter Property="CornerRadius" Value="999" />- <Setter Property="Padding" Value="14,6" />- <Setter Property="Margin" Value="3" />- <Setter Property="Background" Value="{DynamicResource SurfaceBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource SubtleBorderBrush}" />- <Setter Property="BorderThickness" Value="1" />- </Style>- <Style Selector="Window.material-you Border.chip:pointerover">- <Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentBrush}" />- <Setter Property="RenderTransform" Value="scale(1.04)" />- </Style>-- <Style Selector="Window.material-you Border.badge">- <Setter Property="CornerRadius" Value="999" />- <Setter Property="Padding" Value="10,3" />- <Setter Property="Background" Value="{DynamicResource SurfaceAltBrush}" />- </Style>- <Style Selector="Window.material-you Border.badge TextBlock">- <Setter Property="FontWeight" Value="Medium" />- </Style>- <Style Selector="Window.material-you Border.badge.ok">- <Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- </Style>-- <Style Selector="Window.material-you Border.tagchip">- <Setter Property="CornerRadius" Value="999" />- <Setter Property="Padding" Value="12,2,4,2" />- <Setter Property="Background" Value="{DynamicResource SurfaceAltBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource SubtleBorderBrush}" />- <Setter Property="BorderThickness" Value="1" />- </Style>- <Style Selector="Window.material-you Border.tagchip:focus">- <Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentBrush}" />- </Style>-- <Style Selector="Window.material-you ToggleButton.extchip">- <Setter Property="CornerRadius" Value="999" />- <Setter Property="Padding" Value="14,5" />- <Setter Property="Margin" Value="3" />- <Setter Property="FontWeight" Value="Medium" />- </Style>- <Style Selector="Window.material-you ToggleButton.extchip:checked /template/ ContentPresenter#PART_ContentPresenter">- <Setter Property="Background" Value="{DynamicResource AccentBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentBrush}" />- <Setter Property="Foreground" Value="{DynamicResource OnAccentBrush}" />- </Style>-- <!-- Loaders / ProgressBars -->- <Style Selector="Window.material-you ProgressBar, Window.material-you ProgressBar.soft">- <Setter Property="CornerRadius" Value="999" />- <Setter Property="Height" Value="8" />- <Setter Property="MinHeight" Value="8" />- <Setter Property="Foreground" Value="{DynamicResource AccentBrush}" />- <Setter Property="Background" Value="{DynamicResource AccentFaintBrush}" />- <Setter Property="BorderThickness" Value="0" />- </Style>-- <!-- Seekbars / Sliders: Authentic Material 3 rounded pill track & M3 capsule thumb -->- <Style Selector="Window.material-you Slider:horizontal">- <Setter Property="MinHeight" Value="42" />- <Setter Property="Height" Value="42" />- <Setter Property="Foreground" Value="{DynamicResource AccentBrush}" />- <Setter Property="VerticalAlignment" Value="Center" />- </Style>- <Style Selector="Window.material-you Slider:horizontal /template/ Border#TrackBackground">- <Setter Property="Height" Value="16" />- <Setter Property="CornerRadius" Value="999" />- <Setter Property="Background" Value="{DynamicResource SurfaceContainerHighestBrush}" />- </Style>- <Style Selector="Window.material-you Slider:horizontal /template/ RepeatButton#PART_DecreaseButton">- <Setter Property="Background" Value="{DynamicResource AccentBrush}" />- <Setter Property="Height" Value="16" />- <Setter Property="CornerRadius" Value="999" />- <Setter Property="VerticalAlignment" Value="Center" />- </Style>- <Style Selector="Window.material-you Slider:horizontal /template/ RepeatButton#PART_DecreaseButton /template/ Border">- <Setter Property="Background" Value="{DynamicResource AccentBrush}" />- <Setter Property="Height" Value="16" />- <Setter Property="CornerRadius" Value="999" />- </Style>- <Style Selector="Window.material-you Slider:horizontal /template/ RepeatButton#PART_IncreaseButton">- <Setter Property="Background" Value="{DynamicResource SurfaceContainerHighestBrush}" />- <Setter Property="Height" Value="16" />- <Setter Property="CornerRadius" Value="999" />- <Setter Property="VerticalAlignment" Value="Center" />- </Style>- <Style Selector="Window.material-you Slider:horizontal /template/ RepeatButton#PART_IncreaseButton /template/ Border">- <Setter Property="Background" Value="{DynamicResource SurfaceContainerHighestBrush}" />- <Setter Property="Height" Value="16" />- <Setter Property="CornerRadius" Value="999" />- </Style>- <Style Selector="Window.material-you Slider:horizontal /template/ Thumb#PART_Thumb">- <Setter Property="Width" Value="8" />- <Setter Property="Height" Value="28" />- <Setter Property="CornerRadius" Value="999" />- <Setter Property="Background" Value="{DynamicResource AccentBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource SurfaceBrush}" />- <Setter Property="BorderThickness" Value="1.5" />- <Setter Property="VerticalAlignment" Value="Center" />- <Setter Property="Transitions">- <Transitions>- <TransformOperationsTransition Property="RenderTransform" Duration="0:0:0.18" Easing="{StaticResource SoftEase}" />- </Transitions>- </Setter>- </Style>- <Style Selector="Window.material-you Slider:horizontal /template/ Thumb#PART_Thumb:pointerover">- <Setter Property="RenderTransform" Value="scale(1.25, 1.08)" />- </Style>- <Style Selector="Window.material-you Slider:horizontal /template/ Thumb#PART_Thumb:pressed">- <Setter Property="RenderTransform" Value="scale(1.4, 1.15)" />- </Style>-- <!-- ToggleButtons (Filter chips / Modifiers) -->- <Style Selector="Window.material-you ToggleButton">- <Setter Property="CornerRadius" Value="999" />- <Setter Property="Padding" Value="16,6" />- <Setter Property="FontWeight" Value="Medium" />- <Setter Property="Background" Value="{DynamicResource SurfaceAltBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource SubtleBorderBrush}" />- <Setter Property="BorderThickness" Value="1" />- </Style>- <Style Selector="Window.material-you ToggleButton:checked /template/ ContentPresenter#PART_ContentPresenter">- <Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentBrush}" />- <Setter Property="Foreground" Value="{DynamicResource AccentStrongBrush}" />- <Setter Property="FontWeight" Value="SemiBold" />- </Style>- <Style Selector="Window.material-you ToggleButton:checked">- <Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentBrush}" />- <Setter Property="Foreground" Value="{DynamicResource AccentStrongBrush}" />- <Setter Property="FontWeight" Value="SemiBold" />- </Style>-- <!-- Dropdowns (ComboBox): Material 3 container & popups -->- <Style Selector="Window.material-you ComboBox">- <Setter Property="MinHeight" Value="38" />- <Setter Property="CornerRadius" Value="14" />- <Setter Property="Background" Value="{DynamicResource SurfaceAltBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource SubtleBorderBrush}" />- <Setter Property="BorderThickness" Value="1" />- <Setter Property="Padding" Value="14,7" />- </Style>- <Style Selector="Window.material-you ComboBox:pointerover">- <Setter Property="Background" Value="{DynamicResource SurfaceContainerHighestBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentBrush}" />- </Style>- <Style Selector="Window.material-you ComboBox /template/ Border#PopupBorder">- <Setter Property="CornerRadius" Value="16" />- <Setter Property="Background" Value="{DynamicResource SurfaceContainerHighBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource SubtleBorderBrush}" />- <Setter Property="BorderThickness" Value="1" />- <Setter Property="Padding" Value="6" />- <Setter Property="BoxShadow" Value="{DynamicResource CardShadow}" />- </Style>- <!-- Dropdown opening: smooth, flicker-free opacity fade without layout margin shifts that cause popup window resize/flicker -->- <Style Selector="Window.material-you ComboBox[IsDropDownOpen=True] /template/ Border#PopupBorder, ComboBox[IsDropDownOpen=True] /template/ Border#PopupBorder">- <Style.Animations>- <Animation Duration="0:0:0.16" Easing="CubicEaseOut" FillMode="Forward">- <KeyFrame Cue="0%">- <Setter Property="Opacity" Value="0" />- </KeyFrame>- <KeyFrame Cue="100%">- <Setter Property="Opacity" Value="1" />- </KeyFrame>- </Animation>- </Style.Animations>- </Style>- <Style Selector="Window.material-you ComboBoxItem">- <Setter Property="CornerRadius" Value="10" />- <Setter Property="Padding" Value="12,8" />+ <Setter Property="CornerRadius" Value="{DynamicResource SoftRadiusSmall}" />+ <Setter Property="Padding" Value="10,7" /><Setter Property="Margin" Value="0,1" /></Style>- <Style Selector="Window.material-you ComboBoxItem:selected /template/ ContentPresenter#PART_ContentPresenter">- <Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- <Setter Property="Foreground" Value="{DynamicResource AccentStrongBrush}" />- <Setter Property="FontWeight" Value="SemiBold" />- </Style>-- <!-- ToggleSwitch: M3 track, knob and hover color -->- <Style Selector="Window.material-you ToggleSwitch">- <Setter Property="Transitions">- <Transitions>- <TransformOperationsTransition Property="RenderTransform" Duration="0:0:0.18" Easing="{StaticResource SoftEase}" />- </Transitions>- </Setter>- </Style>- <Style Selector="Window.material-you ToggleSwitch:pointerover">- <Setter Property="RenderTransform" Value="scale(1.02)" />- </Style>- <Style Selector="Window.material-you ToggleSwitch /template/ Border#SwitchKnobBounds">- <Setter Property="Transitions">- <Transitions>- <BrushTransition Property="Background" Duration="0:0:0.18" />- <BrushTransition Property="BorderBrush" Duration="0:0:0.18" />- </Transitions>- </Setter>- </Style>- <Style Selector="Window.material-you ToggleSwitch:pointerover /template/ Border#SwitchKnobBounds">- <Setter Property="Background" Value="{DynamicResource SurfaceContainerHighestBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentBrush}" />- </Style>- <Style Selector="Window.material-you ToggleSwitch:checked /template/ Border#SwitchKnobBounds">- <Setter Property="Background" Value="{DynamicResource AccentBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentBrush}" />- </Style>- <Style Selector="Window.material-you ToggleSwitch:checked:pointerover /template/ Border#SwitchKnobBounds">- <Setter Property="Background" Value="{DynamicResource AccentStrongBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentStrongBrush}" />- </Style>- <Style Selector="Window.material-you ToggleSwitch:checked /template/ Ellipse#SwitchKnob">- <Setter Property="Fill" Value="{DynamicResource OnAccentBrush}" />- </Style>-- <!-- Text inputs & NumericUpDown -->- <Style Selector="Window.material-you TextBox">- <Setter Property="MinHeight" Value="38" />- <Setter Property="CornerRadius" Value="14" />- <Setter Property="Background" Value="{DynamicResource SurfaceAltBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource SubtleBorderBrush}" />- <Setter Property="BorderThickness" Value="1" />- <Setter Property="Padding" Value="14,7" />- </Style>- <!-- Seamless NumericUpDown & ButtonSpinner (no inner boxes, seamless background, sleek chevrons) -->- <Style Selector="NumericUpDown">- <Style.Resources>- <SolidColorBrush x:Key="TextControlBackground" Color="Transparent" />- <SolidColorBrush x:Key="TextControlBackgroundPointerOver" Color="Transparent" />- <SolidColorBrush x:Key="TextControlBackgroundFocused" Color="Transparent" />- <SolidColorBrush x:Key="TextControlBorderBrush" Color="Transparent" />- <SolidColorBrush x:Key="TextControlBorderBrushPointerOver" Color="Transparent" />- <SolidColorBrush x:Key="TextControlBorderBrushFocused" Color="Transparent" />- <Thickness x:Key="TextControlBorderThemeThickness">0</Thickness>- <Thickness x:Key="TextControlBorderThemeThicknessFocused">0</Thickness>- <CornerRadius x:Key="ControlCornerRadius">0</CornerRadius>- </Style.Resources>- <Setter Property="CornerRadius" Value="12" />- <Setter Property="ClipToBounds" Value="True" />- <Setter Property="Background" Value="{DynamicResource SurfaceAltBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource SubtleBorderBrush}" />- <Setter Property="BorderThickness" Value="1" />- <Setter Property="Padding" Value="0" />- <Setter Property="MinHeight" Value="38" />- </Style>- <Style Selector="NumericUpDown:pointerover">- <Setter Property="Background" Value="{DynamicResource SurfaceContainerHighestBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentBrush}" />- </Style>-- <!-- Inner TextBox inside NumericUpDown: completely transparent, seamless, NO inner borders or pill -->- <Style Selector="NumericUpDown /template/ TextBox#PART_TextBox, Window.material-you NumericUpDown /template/ TextBox#PART_TextBox, NumericUpDown /template/ TextBox, ButtonSpinner TextBox">- <Setter Property="Background" Value="Transparent" />- <Setter Property="BorderThickness" Value="0" />- <Setter Property="BorderBrush" Value="Transparent" />- <Setter Property="CornerRadius" Value="0" />- <Setter Property="Padding" Value="14,0,4,0" />- <Setter Property="MinHeight" Value="0" />- <Setter Property="VerticalAlignment" Value="Stretch" />- <Setter Property="VerticalContentAlignment" Value="Center" />- </Style>- <Style Selector="NumericUpDown /template/ TextBox#PART_TextBox:pointerover, Window.material-you NumericUpDown /template/ TextBox#PART_TextBox:pointerover">- <Setter Property="Background" Value="Transparent" />- <Setter Property="BorderBrush" Value="Transparent" />- </Style>- <Style Selector="NumericUpDown /template/ TextBox#PART_TextBox:focus, Window.material-you NumericUpDown /template/ TextBox#PART_TextBox:focus">- <Setter Property="Background" Value="Transparent" />- <Setter Property="BorderBrush" Value="Transparent" />- </Style>-- <Style Selector="NumericUpDown:pointerover /template/ TextBox#PART_TextBox, Window.material-you NumericUpDown:pointerover /template/ TextBox#PART_TextBox, NumericUpDown /template/ TextBox#PART_TextBox:pointerover, Window.material-you NumericUpDown /template/ TextBox#PART_TextBox:pointerover">- <Setter Property="Background" Value="Transparent" />- <Setter Property="BorderBrush" Value="Transparent" />- <Setter Property="BorderThickness" Value="0" />- <Setter Property="CornerRadius" Value="0" />- </Style>-- <!-- ButtonSpinner root & repeat buttons: remove vertical divider lines and floating circles in all states -->- <Style Selector="ButtonSpinner">- <Setter Property="Background" Value="Transparent" />- <Setter Property="BorderThickness" Value="0" />- <Setter Property="BorderBrush" Value="Transparent" />- <Setter Property="CornerRadius" Value="0" />- <Setter Property="Padding" Value="0,0,6,0" />- </Style>- <Style Selector="ButtonSpinner /template/ Border#PART_RootBorder">- <Setter Property="Background" Value="Transparent" />- <Setter Property="BorderThickness" Value="0" />- <Setter Property="BorderBrush" Value="Transparent" />- </Style>- <Style Selector="ButtonSpinner /template/ RepeatButton,- ButtonSpinner:right /template/ RepeatButton,- ButtonSpinner:right /template/ RepeatButton#PART_IncreaseButton,- ButtonSpinner:right /template/ RepeatButton#PART_DecreaseButton,- ButtonSpinner /template/ RepeatButton#PART_IncreaseButton,- ButtonSpinner /template/ RepeatButton#PART_DecreaseButton,- Window.material-you ButtonSpinner /template/ RepeatButton">- <Setter Property="Background" Value="Transparent" />- <Setter Property="BorderThickness" Value="0" />- <Setter Property="BorderBrush" Value="Transparent" />- <Setter Property="CornerRadius" Value="8" />- <Setter Property="Width" Value="24" />- <Setter Property="Height" Value="24" />- <Setter Property="MinWidth" Value="24" />- <Setter Property="MinHeight" Value="24" />- <Setter Property="Margin" Value="1,0" />- <Setter Property="Padding" Value="0" />- <Setter Property="VerticalAlignment" Value="Center" />- <Setter Property="HorizontalContentAlignment" Value="Center" />- <Setter Property="VerticalContentAlignment" Value="Center" />- <Setter Property="RenderTransform" Value="none" />- <Setter Property="Transitions" Value="{x:Null}" />- <Setter Property="Foreground" Value="{DynamicResource TextSecondaryBrush}" />- </Style>- <Style Selector="ButtonSpinner /template/ RepeatButton /template/ ContentPresenter#PART_ContentPresenter,- ButtonSpinner:right /template/ RepeatButton /template/ ContentPresenter#PART_ContentPresenter,- ButtonSpinner:right /template/ RepeatButton#PART_IncreaseButton /template/ ContentPresenter#PART_ContentPresenter,- ButtonSpinner:right /template/ RepeatButton#PART_DecreaseButton /template/ ContentPresenter#PART_ContentPresenter,- ButtonSpinner /template/ RepeatButton#PART_IncreaseButton /template/ ContentPresenter#PART_ContentPresenter,- ButtonSpinner /template/ RepeatButton#PART_DecreaseButton /template/ ContentPresenter#PART_ContentPresenter,- Window.material-you ButtonSpinner /template/ RepeatButton /template/ ContentPresenter#PART_ContentPresenter">- <Setter Property="Background" Value="Transparent" />- <Setter Property="BorderThickness" Value="0" />- <Setter Property="BorderBrush" Value="Transparent" />- <Setter Property="CornerRadius" Value="8" />- </Style>- <Style Selector="ButtonSpinner /template/ RepeatButton:pointerover /template/ ContentPresenter#PART_ContentPresenter,- ButtonSpinner:right /template/ RepeatButton:pointerover /template/ ContentPresenter#PART_ContentPresenter,- ButtonSpinner:right /template/ RepeatButton#PART_IncreaseButton:pointerover /template/ ContentPresenter#PART_ContentPresenter,- ButtonSpinner:right /template/ RepeatButton#PART_DecreaseButton:pointerover /template/ ContentPresenter#PART_ContentPresenter,- ButtonSpinner /template/ RepeatButton#PART_IncreaseButton:pointerover /template/ ContentPresenter#PART_ContentPresenter,- ButtonSpinner /template/ RepeatButton#PART_DecreaseButton:pointerover /template/ ContentPresenter#PART_ContentPresenter,- Window.material-you ButtonSpinner /template/ RepeatButton:pointerover /template/ ContentPresenter#PART_ContentPresenter">+ <Style Selector="ListBox.soft ListBoxItem:selected /template/ ContentPresenter#PART_ContentPresenter"><Setter Property="Background" Value="{DynamicResource AccentSoftBrush}" />- <Setter Property="BorderThickness" Value="0" />- <Setter Property="BorderBrush" Value="Transparent" />- </Style>- <Style Selector="ButtonSpinner /template/ RepeatButton:pointerover,- ButtonSpinner:right /template/ RepeatButton:pointerover,- ButtonSpinner:right /template/ RepeatButton#PART_IncreaseButton:pointerover,- ButtonSpinner:right /template/ RepeatButton#PART_DecreaseButton:pointerover,- ButtonSpinner /template/ RepeatButton#PART_IncreaseButton:pointerover,- ButtonSpinner /template/ RepeatButton#PART_DecreaseButton:pointerover,- Window.material-you ButtonSpinner /template/ RepeatButton:pointerover">- <Setter Property="BorderThickness" Value="0" />- <Setter Property="BorderBrush" Value="Transparent" />- <Setter Property="Foreground" Value="{DynamicResource AccentStrongBrush}" />- </Style>- <Style Selector="ButtonSpinner /template/ RepeatButton:pressed /template/ ContentPresenter#PART_ContentPresenter,- ButtonSpinner:right /template/ RepeatButton:pressed /template/ ContentPresenter#PART_ContentPresenter,- ButtonSpinner:right /template/ RepeatButton#PART_IncreaseButton:pressed /template/ ContentPresenter#PART_ContentPresenter,- ButtonSpinner:right /template/ RepeatButton#PART_DecreaseButton:pressed /template/ ContentPresenter#PART_ContentPresenter,- ButtonSpinner /template/ RepeatButton#PART_IncreaseButton:pressed /template/ ContentPresenter#PART_ContentPresenter,- ButtonSpinner /template/ RepeatButton#PART_DecreaseButton:pressed /template/ ContentPresenter#PART_ContentPresenter,- Window.material-you ButtonSpinner /template/ RepeatButton:pressed /template/ ContentPresenter#PART_ContentPresenter">- <Setter Property="Background" Value="{DynamicResource SurfaceContainerHighestBrush}" />- <Setter Property="BorderThickness" Value="0" />- <Setter Property="BorderBrush" Value="Transparent" />- </Style>- <Style Selector="Window.material-you NumericUpDown">- <Style.Resources>- <SolidColorBrush x:Key="TextControlBackground" Color="Transparent" />- <SolidColorBrush x:Key="TextControlBackgroundPointerOver" Color="Transparent" />- <SolidColorBrush x:Key="TextControlBackgroundFocused" Color="Transparent" />- <SolidColorBrush x:Key="TextControlBorderBrush" Color="Transparent" />- <SolidColorBrush x:Key="TextControlBorderBrushPointerOver" Color="Transparent" />- <SolidColorBrush x:Key="TextControlBorderBrushFocused" Color="Transparent" />- <Thickness x:Key="TextControlBorderThemeThickness">0</Thickness>- <Thickness x:Key="TextControlBorderThemeThicknessFocused">0</Thickness>- <CornerRadius x:Key="ControlCornerRadius">0</CornerRadius>- </Style.Resources>- <Setter Property="MinHeight" Value="38" />- <Setter Property="CornerRadius" Value="14" />- <Setter Property="ClipToBounds" Value="True" />- <Setter Property="Background" Value="{DynamicResource SurfaceAltBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource SubtleBorderBrush}" />- <Setter Property="BorderThickness" Value="1" />- <Setter Property="Padding" Value="0" />- <Setter Property="MinWidth" Value="160" />- </Style>- <Style Selector="Window.material-you NumericUpDown:pointerover">- <Setter Property="Background" Value="{DynamicResource SurfaceContainerHighestBrush}" />- <Setter Property="BorderBrush" Value="{DynamicResource AccentBrush}" /></Style><!-- ───────── Page content fade-in (keyframes can't animate RenderTransform, so Margin slides) ───────── -->@@ -992,35 +228,18 @@</Style.Animations></Style>- <!-- ───────── History Card fade & slide animation for search filtering ───────── -->- <Style Selector="Border.history-card">- <Style.Animations>- <Animation Duration="0:0:0.22" Easing="CubicEaseOut" FillMode="Forward">- <KeyFrame Cue="0%">- <Setter Property="Opacity" Value="0" />- <Setter Property="Margin" Value="0,8,0,-8" />- </KeyFrame>- <KeyFrame Cue="100%">- <Setter Property="Opacity" Value="1" />- <Setter Property="Margin" Value="0" />- </KeyFrame>- </Animation>- </Style.Animations>- </Style>-<!-- ───────── Reduced motion: remove every transition and animation above ───────── -->- <Style Selector="Window.reduced-motion :is(Button), Window.reduced-motion :is(ToggleButton), Window.reduced-motion Border.chip, Window.reduced-motion ListBoxItem, Window.reduced-motion Slider /template/ Thumb#PART_Thumb">+ <Style Selector="Window.reduced-motion :is(Button), Window.reduced-motion :is(ToggleButton), Window.reduced-motion Border.chip, Window.reduced-motion ListBoxItem"><Setter Property="Transitions" Value="{x:Null}" /></Style>- <Style Selector="Window.reduced-motion Button:pressed, Window.reduced-motion ToggleButton:pressed, Window.reduced-motion Border.chip:pointerover, Window.reduced-motion ListBox.nav ListBoxItem:pointerover, Window.reduced-motion Slider /template/ Thumb#PART_Thumb:pointerover">+ <Style Selector="Window.reduced-motion Button:pressed, Window.reduced-motion ToggleButton:pressed, Window.reduced-motion Border.chip:pointerover, Window.reduced-motion ListBox.nav ListBoxItem:pointerover"><Setter Property="RenderTransform" Value="none" /></Style>- <Style Selector="Window.reduced-motion ContentControl.page > :is(Control), Window.reduced-motion Border.history-card">+ <Style Selector="Window.reduced-motion ContentControl.page > :is(Control)"><Style.Animations><Animation Duration="0:0:0.001" FillMode="Forward"><KeyFrame Cue="100%"><Setter Property="Opacity" Value="1" />- <Setter Property="Margin" Value="0" /></KeyFrame></Animation></Style.Animations>diff --git a/src/Filee.App/ViewModels/Pages/ThemePageViewModel.cs b/src/Filee.App/ViewModels/Pages/ThemePageViewModel.csindex 2a819f7e..badc7bc3 100644--- a/src/Filee.App/ViewModels/Pages/ThemePageViewModel.cs+++ b/src/Filee.App/ViewModels/Pages/ThemePageViewModel.cs@@ -1,8 +1,6 @@-// Theme: light/dark, style (Soft / Material You), accent colour, softness, reduce animations. Changes apply live.+// Theme: light/dark, accent colour, softness (corner radius), reduce animations. Changes apply live.-using Avalonia;using Avalonia.Media;-using Avalonia.Styling;using CommunityToolkit.Mvvm.ComponentModel;using CommunityToolkit.Mvvm.Input;using Filee.App.Controls;@@ -17,26 +15,18 @@ public sealed partial class ThemePageViewModel : ObservableObject{private readonly UserDataStore _store;private readonly bool _loading;- private MaterialYouPalette? _currentPalette;public ThemePageViewModel(UserDataStore store, ILocalizer loc, IPlatformServices platform){_store = store;_loading = true;var theme = store.Settings.Theme;-- Styles = Enum.GetValues<ThemeStyle>().Select(s => new Choice<ThemeStyle>(s, loc[$"theme.style.{s}"])).ToList();- Style = Styles.FirstOrDefault(s => s.Value == theme.Style) ?? Styles[0];-Modes = Enum.GetValues<ThemeMode>().Select(m => new Choice<ThemeMode>(m, loc[$"theme.mode.{m}"])).ToList();Mode = Modes.First(m => m.Value == theme.Mode);-- Accent = Color.TryParse(theme.Accent, out var c) ? c : (theme.Style == ThemeStyle.MaterialYou ? Color.Parse("#6750A4") : Colors.MediumPurple);+ Accent = Color.TryParse(theme.Accent, out var c) ? c : Colors.MediumPurple;AccentHex = $"#{Accent.R:X2}{Accent.G:X2}{Accent.B:X2}";CornerRadius = theme.CornerRadius;- DonutOpacity = Math.Clamp(Math.Round(store.Settings.Donut.Opacity * 100), 10, 100);ReduceMotion = theme.ReduceMotion ?? platform.PrefersReducedMotion;-PreviewItems =[new DonutItem { Id = "a", Label = "PNG" },@@ -46,94 +36,31 @@ public sealed partial class ThemePageViewModel : ObservableObjectnew DonutItem { Id = "e", Label = "JPG 70%", Caption = "JPG" },new DonutItem { Id = "f", Label = "TIFF" },];-- UpdateTonalPalette();_loading = false;}- public IReadOnlyList<Choice<ThemeStyle>> Styles { get; }public IReadOnlyList<Choice<ThemeMode>> Modes { get; }+ public IReadOnlyList<Color> Swatches { get; } = ThemeService.Swatches.Select(Color.Parse).ToList();public IReadOnlyList<DonutItem> PreviewItems { get; }- public sealed record InkoraPresetItem(string Key, string Name, Color LightColor, Color DarkColor, Color ActiveColor);-- public IReadOnlyList<InkoraPresetItem> InkoraPresets- {- get- {- var isDark = Mode?.Value == ThemeMode.Dark || (Mode?.Value == ThemeMode.System && Application.Current?.ActualThemeVariant == ThemeVariant.Dark);- return ThemeService.InkoraPresets.Select(p =>- {- var lc = Color.Parse(p.LightHex);- var dc = Color.Parse(p.DarkHex);- return new InkoraPresetItem(p.Key, p.Name, lc, dc, isDark ? dc : lc);- }).ToList();- }- }-- public IReadOnlyList<Color> StandardSwatches =>- (IsMaterialYou ? ThemeService.MaterialYouSwatches : ThemeService.Swatches).Select(Color.Parse).ToList();-- public IReadOnlyList<Color> PastelSwatches =>- ThemeService.PastelSwatches.Select(Color.Parse).ToList();-- public IReadOnlyList<Color> Swatches => StandardSwatches;-- public bool IsMaterialYou => Style?.Value == ThemeStyle.MaterialYou;-- [ObservableProperty] private Choice<ThemeStyle> _style = null!;[ObservableProperty] private Choice<ThemeMode> _mode = null!;[ObservableProperty, NotifyPropertyChangedFor(nameof(AccentBrush))] private Color _accent;[ObservableProperty] private string _accentHex = "";public IBrush AccentBrush => new SolidColorBrush(Accent);[ObservableProperty] private double _cornerRadius;- [ObservableProperty, NotifyPropertyChangedFor(nameof(DonutSliceOpacity))] private double _donutOpacity = 96;- public double DonutSliceOpacity => DonutOpacity / 100.0;[ObservableProperty] private bool _reduceMotion;- partial void OnDonutOpacityChanged(double value)- {- OnPropertyChanged(nameof(DonutSliceOpacity));- if (!_loading)- {- var clamped = Math.Clamp(value, 10, 100);- _store.Settings.Donut.Opacity = Math.Round(clamped) / 100.0;- _store.SaveSettings();- }- }-- // Material You Tonal Palette preview tokens- public IBrush TonalPrimary => new SolidColorBrush(_currentPalette?.Primary ?? Accent);- public IBrush TonalPrimaryContainer => new SolidColorBrush(_currentPalette?.PrimaryContainer ?? Accent);- public IBrush TonalSecondaryContainer => new SolidColorBrush(_currentPalette?.SecondaryContainer ?? Accent);- public IBrush TonalSurfaceContainer => new SolidColorBrush(_currentPalette?.SurfaceContainer ?? Colors.Gray);- public IBrush TonalSurface => new SolidColorBrush(_currentPalette?.Surface ?? Colors.White);-- partial void OnStyleChanged(Choice<ThemeStyle>? oldValue, Choice<ThemeStyle> newValue)- {- OnPropertyChanged(nameof(IsMaterialYou));- OnPropertyChanged(nameof(StandardSwatches));- OnPropertyChanged(nameof(Swatches));- UpdateTonalPalette();- if (!Choices.Restore(oldValue, newValue, v => Style = v))- Save(t => t.Style = newValue.Value);- }-partial void OnModeChanged(Choice<ThemeMode>? oldValue, Choice<ThemeMode> newValue){- OnPropertyChanged(nameof(InkoraPresets));- UpdateTonalPalette();if (!Choices.Restore(oldValue, newValue, v => Mode = v))Save(t => t.Mode = newValue.Value);}-partial void OnAccentChanged(Color value){var hex = $"#{value.R:X2}{value.G:X2}{value.B:X2}";if (!string.Equals(AccentHex, hex, StringComparison.OrdinalIgnoreCase))AccentHex = hex;- UpdateTonalPalette();Save(t => t.Accent = hex);}@@ -143,36 +70,12 @@ public sealed partial class ThemePageViewModel : ObservableObjectif (Color.TryParse(value.Trim(), out var color) && color != Accent)Accent = Color.FromRgb(color.R, color.G, color.B);}-partial void OnCornerRadiusChanged(double value) => Save(t => t.CornerRadius = Math.Round(value));partial void OnReduceMotionChanged(bool value) => Save(t => t.ReduceMotion = value);[RelayCommand]private void PickSwatch(Color color) => Accent = color;- [RelayCommand]- private void PickInkoraPreset(InkoraPresetItem preset) => Accent = preset.ActiveColor;-- [RelayCommand]- private void SetStyle(ThemeStyle target)- {- var match = Styles.FirstOrDefault(s => s.Value == target);- if (match != null && Style != match)- Style = match;- }-- private void UpdateTonalPalette()- {- var isDark = Mode?.Value == ThemeMode.Dark ||- (Mode?.Value == ThemeMode.System && Application.Current?.ActualThemeVariant == ThemeVariant.Dark);- _currentPalette = MaterialYouPalette.Generate(Accent, isDark);- OnPropertyChanged(nameof(TonalPrimary));- OnPropertyChanged(nameof(TonalPrimaryContainer));- OnPropertyChanged(nameof(TonalSecondaryContainer));- OnPropertyChanged(nameof(TonalSurfaceContainer));- OnPropertyChanged(nameof(TonalSurface));- }-private void Save(Action<ThemeSettings> change){if (_loading)diff --git a/src/Filee.App/Views/Pages/PresetsPage.axaml b/src/Filee.App/Views/Pages/PresetsPage.axamlindex 88829fb9..3da5b6da 100644--- a/src/Filee.App/Views/Pages/PresetsPage.axaml+++ b/src/Filee.App/Views/Pages/PresetsPage.axaml@@ -28,7 +28,7 @@<PathIcon Width="14" Height="14" Margin="10,0,0,0" Data="{StaticResource Icon.Search}" Foreground="{DynamicResource TextSecondaryBrush}" /></TextBox.InnerLeftContent></TextBox>- <ListBox Classes="soft" ItemsSource="{Binding VisiblePresets}" SelectedItem="{Binding SelectedPreset}" Margin="0,0,8,0">+ <ListBox Classes="soft" ItemsSource="{Binding VisiblePresets}" SelectedItem="{Binding SelectedPreset}"><ListBox.ItemTemplate><DataTemplate x:DataType="vm:PresetListItem"><StackPanel>diff --git a/src/Filee.App/Views/Pages/ThemePage.axaml b/src/Filee.App/Views/Pages/ThemePage.axamlindex 0099af95..6d96b46b 100644--- a/src/Filee.App/Views/Pages/ThemePage.axaml+++ b/src/Filee.App/Views/Pages/ThemePage.axaml@@ -2,61 +2,12 @@xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"xmlns:vm="using:Filee.App.ViewModels.Pages"xmlns:c="using:Filee.App.Controls"- xmlns:settings="using:Filee.Core.Settings"x:Class="Filee.App.Views.Pages.ThemePage"x:DataType="vm:ThemePageViewModel">- <Grid ColumnDefinitions="*,24,340" RowDefinitions="Auto,Auto">+ <Grid ColumnDefinitions="*,20,340" RowDefinitions="Auto,*"><TextBlock Grid.ColumnSpan="3" Classes="h1" Text="{DynamicResource theme.title}" Margin="0,0,0,18" /><StackPanel Grid.Row="1" Spacing="16">- <!-- Theme Style: Filee Soft vs Google Material You (M3) -->- <Border Classes="card">- <StackPanel Spacing="12">- <DockPanel>- <Border DockPanel.Dock="Right" CornerRadius="999" Background="{DynamicResource AccentSoftBrush}" Padding="8,2"- IsVisible="{Binding IsMaterialYou}">- <TextBlock Text="Material 3" FontSize="11" FontWeight="SemiBold" Foreground="{DynamicResource AccentStrongBrush}" />- </Border>- <TextBlock Classes="label" Text="{DynamicResource theme.style}" VerticalAlignment="Center" Margin="0" />- </DockPanel>-- <Grid ColumnDefinitions="*,12,*" RowDefinitions="1*">- <!-- Filee Soft Choice Card -->- <Button Classes="choice-card"- Classes.selected="{Binding !IsMaterialYou}"- Command="{Binding SetStyleCommand}"- CommandParameter="{x:Static settings:ThemeStyle.Soft}"- HorizontalAlignment="Stretch" HorizontalContentAlignment="Stretch"- VerticalAlignment="Stretch" VerticalContentAlignment="Stretch">- <StackPanel Spacing="6" VerticalAlignment="Top">- <TextBlock Classes="choice-title" Text="{DynamicResource theme.style.Soft}" />- <TextBlock Classes="choice-desc" Text="{DynamicResource theme.style.soft_hint}" TextWrapping="Wrap" />- </StackPanel>- </Button>-- <!-- Material You Choice Card -->- <Button Grid.Column="2"- Classes="choice-card"- Classes.selected="{Binding IsMaterialYou}"- Command="{Binding SetStyleCommand}"- CommandParameter="{x:Static settings:ThemeStyle.MaterialYou}"- HorizontalAlignment="Stretch" HorizontalContentAlignment="Stretch"- VerticalAlignment="Stretch" VerticalContentAlignment="Stretch">- <StackPanel Spacing="6" VerticalAlignment="Top">- <StackPanel Orientation="Horizontal" Spacing="6" VerticalAlignment="Center">- <TextBlock Classes="choice-title" Text="{DynamicResource theme.style.MaterialYou}" />- <Border CornerRadius="999" Background="{DynamicResource AccentBrush}" Padding="6,1">- <TextBlock Text="M3" FontSize="10" FontWeight="Bold" Foreground="{DynamicResource OnAccentBrush}" />- </Border>- </StackPanel>- <TextBlock Classes="choice-desc" Text="{DynamicResource theme.style.material_you_hint}" TextWrapping="Wrap" />- </StackPanel>- </Button>- </Grid>- </StackPanel>- </Border>-- <!-- Appearance Mode: System / Light / Dark --><Border Classes="card"><StackPanel Spacing="8"><TextBlock Classes="label" Text="{DynamicResource theme.mode}" />@@ -64,47 +15,10 @@</StackPanel></Border>- <!-- Accent Color & Dynamic Tonal Palette --><Border Classes="card">- <StackPanel Spacing="12">+ <StackPanel Spacing="10"><TextBlock Classes="label" Text="{DynamicResource theme.accent}" />-- <!-- Inkora Curated Pastel Presets -->- <DockPanel Margin="0,4,0,0">- <Border DockPanel.Dock="Right" CornerRadius="999" Background="{DynamicResource AccentSoftBrush}" Padding="8,2">- <TextBlock Text="Inkora Collection" FontSize="11" FontWeight="SemiBold" Foreground="{DynamicResource AccentStrongBrush}" />- </Border>- <TextBlock Classes="caption" Text="Curated Pastel Themes" FontWeight="SemiBold" VerticalAlignment="Center" />- </DockPanel>- <ItemsControl ItemsSource="{Binding InkoraPresets}">- <ItemsControl.ItemsPanel>- <ItemsPanelTemplate>- <UniformGrid Columns="2" />- </ItemsPanelTemplate>- </ItemsControl.ItemsPanel>- <ItemsControl.ItemTemplate>- <DataTemplate x:DataType="vm:ThemePageViewModel+InkoraPresetItem">- <Button Classes="preset-pill" Margin="0,0,6,6"- Command="{Binding $parent[ItemsControl].((vm:ThemePageViewModel)DataContext).PickInkoraPresetCommand}"- CommandParameter="{Binding}">- <DockPanel>- <Border DockPanel.Dock="Left" Width="18" Height="18" CornerRadius="999" Margin="0,0,8,0"- BorderBrush="{DynamicResource SubtleBorderBrush}" BorderThickness="1">- <Border.Background>- <SolidColorBrush Color="{Binding ActiveColor}" />- </Border.Background>- </Border>- <TextBlock Text="{Binding Name}" VerticalAlignment="Center" FontSize="12" FontWeight="Medium"- TextTrimming="CharacterEllipsis" />- </DockPanel>- </Button>- </DataTemplate>- </ItemsControl.ItemTemplate>- </ItemsControl>-- <!-- Standard / Vibrant Seeds -->- <TextBlock Classes="caption" Text="Vibrant & Signature Swatches" FontWeight="SemiBold" Margin="0,4,0,0" />- <ItemsControl ItemsSource="{Binding StandardSwatches}">+ <ItemsControl ItemsSource="{Binding Swatches}"><ItemsControl.ItemsPanel><ItemsPanelTemplate><WrapPanel />@@ -112,9 +26,9 @@</ItemsControl.ItemsPanel><ItemsControl.ItemTemplate><DataTemplate x:DataType="Color">- <Button Classes="swatch" Margin="0,0,8,8"+ <Button Width="34" Height="34" Margin="0,0,8,8" CornerRadius="999" Padding="0"Command="{Binding $parent[ItemsControl].((vm:ThemePageViewModel)DataContext).PickSwatchCommand}"- CommandParameter="{Binding}" ToolTip.Tip="{Binding}">+ CommandParameter="{Binding}"><Button.Background><SolidColorBrush Color="{Binding}" /></Button.Background>@@ -122,29 +36,14 @@</DataTemplate></ItemsControl.ItemTemplate></ItemsControl>-- <!-- Custom color row -->- <StackPanel Orientation="Horizontal" Spacing="10" Margin="0,4,0,0">- <Border Width="32" Height="32" CornerRadius="999" Background="{Binding AccentBrush}" BorderBrush="{DynamicResource SubtleBorderBrush}" BorderThickness="1" />+ <StackPanel Orientation="Horizontal" Spacing="10">+ <Border Width="34" Height="34" CornerRadius="999" Background="{Binding AccentBrush}" /><TextBlock Classes="label" VerticalAlignment="Center" Text="{DynamicResource theme.custom_color}" Margin="0" /><TextBox Text="{Binding AccentHex}" Width="120" PlaceholderText="#7F77DD" /></StackPanel>-- <!-- Dynamic Tonal Harmony preview for Material You -->- <StackPanel Spacing="6" Margin="0,6,0,0" IsVisible="{Binding IsMaterialYou}">- <TextBlock Classes="caption" Text="{DynamicResource theme.tonal_palette}" FontWeight="SemiBold" />- <Grid ColumnDefinitions="*,4,*,4,*,4,*,4,*">- <Border Height="28" CornerRadius="8,0,0,8" Background="{Binding TonalPrimary}" ToolTip.Tip="Primary" />- <Border Grid.Column="2" Height="28" Background="{Binding TonalPrimaryContainer}" ToolTip.Tip="Primary Container" />- <Border Grid.Column="4" Height="28" Background="{Binding TonalSecondaryContainer}" ToolTip.Tip="Secondary Container" />- <Border Grid.Column="6" Height="28" Background="{Binding TonalSurfaceContainer}" ToolTip.Tip="Surface Container" />- <Border Grid.Column="8" Height="28" CornerRadius="0,8,8,0" Background="{Binding TonalSurface}" ToolTip.Tip="Surface" />- </Grid>- </StackPanel></StackPanel></Border>- <!-- Softness / Corner Radius --><Border Classes="card"><StackPanel Spacing="8"><DockPanel>@@ -155,18 +54,6 @@</StackPanel></Border>- <!-- Donut Toolbar Transparency / Opacity (10% to 100%) -->- <Border Classes="card">- <StackPanel Spacing="8">- <DockPanel>- <TextBlock DockPanel.Dock="Right" FontWeight="SemiBold" Text="{Binding DonutOpacity, StringFormat={}{0:0}%}" />- <TextBlock Classes="label" Text="Donut toolbar transparency" />- </DockPanel>- <Slider Minimum="10" Maximum="100" Value="{Binding DonutOpacity}" TickFrequency="5" IsSnapToTickEnabled="True" />- </StackPanel>- </Border>-- <!-- Motion / Animations --><Border Classes="card"><StackPanel Spacing="4"><CheckBox Content="{DynamicResource theme.reduce_motion}" IsChecked="{Binding ReduceMotion}" FontWeight="SemiBold" />@@ -179,14 +66,7 @@<Border Grid.Row="1" Grid.Column="2" Classes="card" VerticalAlignment="Top"><StackPanel Spacing="14"><TextBlock Classes="label" Text="{DynamicResource theme.preview}" />- <c:DonutMenu x:Name="PreviewDonut"- Items="{Binding PreviewItems}"- OuterRadius="120"- CenterTitle="JPG × 3"- CenterSubtitle="3 files"- SliceOpacity="{Binding DonutSliceOpacity}"- HorizontalAlignment="Center"- IsMaterialYou="{Binding IsMaterialYou}" />+ <c:DonutMenu x:Name="PreviewDonut" Items="{Binding PreviewItems}" OuterRadius="120" CenterTitle="JPG × 3" HorizontalAlignment="Center" /><StackPanel Orientation="Horizontal" Spacing="8" HorizontalAlignment="Center"><Button Classes="accent" Content="{DynamicResource common.save}" /><Button Content="{DynamicResource common.cancel}" />diff --git a/src/Filee.App/Views/PresetEditorView.axaml b/src/Filee.App/Views/PresetEditorView.axamlindex f6a6038d..4468623d 100644--- a/src/Filee.App/Views/PresetEditorView.axaml+++ b/src/Filee.App/Views/PresetEditorView.axaml@@ -128,9 +128,8 @@</StackPanel></Grid><Grid ColumnDefinitions="Auto,12,*">- <CheckBox Content="{DynamicResource presets.dpi}" IsChecked="{Binding SetDpi}" VerticalAlignment="Center" />- <NumericUpDown Grid.Column="2" Value="{Binding Dpi}" Minimum="36" Maximum="2400" Increment="50" FormatString="0"- IsEnabled="{Binding SetDpi}" HorizontalAlignment="Left" Width="160" />+ <CheckBox Content="{DynamicResource presets.dpi}" IsChecked="{Binding SetDpi}" />+ <NumericUpDown Grid.Column="2" Value="{Binding Dpi}" Minimum="36" Maximum="2400" Increment="50" FormatString="0" IsEnabled="{Binding SetDpi}" /></Grid><WrapPanel><CheckBox Content="{DynamicResource presets.keep_metadata}" IsChecked="{Binding KeepMetadata}" Margin="0,0,18,0" />diff --git a/src/Filee.App/Views/ToastWindow.axaml b/src/Filee.App/Views/ToastWindow.axamlindex 6d0d8f77..b5585a8d 100644--- a/src/Filee.App/Views/ToastWindow.axaml+++ b/src/Filee.App/Views/ToastWindow.axaml@@ -70,13 +70,6 @@<Setter Property="MinHeight" Value="6" /><Setter Property="Height" Value="6" /></Style>- <Style Selector="Window.material-you ProgressBar">- <Setter Property="CornerRadius" Value="999" />- <Setter Property="MinHeight" Value="8" />- <Setter Property="Height" Value="8" />- <Setter Property="Foreground" Value="{DynamicResource AccentBrush}" />- <Setter Property="Background" Value="{DynamicResource AccentFaintBrush}" />- </Style></Window.Styles><ItemsControl x:Name="Jobs" ItemsSource="{Binding ToastJobs}" Margin="12">diff --git a/src/Filee.Core/Settings/AppSettings.cs b/src/Filee.Core/Settings/AppSettings.csindex 8e1aa033..d4105e6e 100644--- a/src/Filee.Core/Settings/AppSettings.cs+++ b/src/Filee.Core/Settings/AppSettings.cs@@ -13,16 +13,6 @@ public enum ThemeModeDark,}-/// <summary>Visual theme style.</summary>-public enum ThemeStyle-{- /// <summary>Filee classic soft pastel rounded design.</summary>- Soft,-- /// <summary>Google Material 3 design with dynamic tonal palettes and pill shapes.</summary>- MaterialYou,-}-/// <summary>What closing the main window does (Settings → General).</summary>public enum CloseAction{@@ -41,8 +31,6 @@ public sealed class ThemeSettings{public ThemeMode Mode { get; set; } = ThemeMode.System;- public ThemeStyle Style { get; set; } = ThemeStyle.Soft;-/// <summary>Accent colour as <c>#RRGGBB</c>.</summary>public string Accent { get; set; } = "#7F77DD";diff --git a/src/Filee.Core/Settings/FileeJsonContext.cs b/src/Filee.Core/Settings/FileeJsonContext.csindex 9b38b679..bb4e4b6b 100644--- a/src/Filee.Core/Settings/FileeJsonContext.cs+++ b/src/Filee.Core/Settings/FileeJsonContext.cs@@ -15,13 +15,12 @@ namespace Filee.Core.Settings;ReadCommentHandling = System.Text.Json.JsonCommentHandling.Skip,AllowTrailingCommas = true)][JsonSerializable(typeof(AppSettings))]-[JsonSerializable(typeof(ThemeStyle))][JsonSerializable(typeof(List<Preset>))][JsonSerializable(typeof(List<ToolbarProfile>))][JsonSerializable(typeof(PresetBundle))][JsonSerializable(typeof(List<HistoryEntry>))][JsonSerializable(typeof(CustomTheme))]-public sealed partial class FileeJsonContext : JsonSerializerContext;+internal sealed partial class FileeJsonContext : JsonSerializerContext;/// <summary>File format used to import / export presets and profiles.</summary>public sealed class PresetBundlediff --git a/tests/Filee.App.Tests/MaterialYouThemeTests.cs b/tests/Filee.App.Tests/MaterialYouThemeTests.csdeleted file mode 100644index c4553cc2..00000000--- a/tests/Filee.App.Tests/MaterialYouThemeTests.cs+++ /dev/null@@ -1,114 +0,0 @@-// Tests for Material You theme: dynamic tonal palette generation, theme application, window styling, and localization.--using System.Text.Json;-using Avalonia;-using Avalonia.Controls;-using Avalonia.Headless.XUnit;-using Avalonia.Media;-using Filee.App.Controls;-using Filee.App.Services;-using Filee.Core.Settings;--namespace Filee.App.Tests;--public class MaterialYouThemeTests-{- [Fact]- public void ThemeSettings_persists_ThemeStyle()- {- var settings = new AppSettings- {- Theme = new ThemeSettings- {- Style = ThemeStyle.MaterialYou,- Accent = "#6750A4",- },- };-- var json = JsonSerializer.Serialize(settings, FileeJsonContext.Default.AppSettings);- Assert.Contains("\"style\": \"MaterialYou\"", json);-- var restored = JsonSerializer.Deserialize(json, FileeJsonContext.Default.AppSettings);- Assert.NotNull(restored);- Assert.Equal(ThemeStyle.MaterialYou, restored.Theme.Style);- Assert.Equal("#6750A4", restored.Theme.Accent);- }-- [Fact]- public void Palette_generates_distinct_tonal_roles_for_light_and_dark()- {- var seed = Color.Parse("#6750A4");- var light = MaterialYouPalette.Generate(seed, isDark: false);- var dark = MaterialYouPalette.Generate(seed, isDark: true);-- // Light mode surfaces are bright, containers are soft pastels- Assert.True(light.Surface.R > 230 && light.Surface.G > 230 && light.Surface.B > 230);- Assert.True(light.OnSurface.R < 50 && light.OnSurface.G < 50 && light.OnSurface.B < 50);-- // Dark mode surfaces are deep dark, containers are rich dark- Assert.True(dark.Surface.R < 40 && dark.Surface.G < 40 && dark.Surface.B < 40);- Assert.True(dark.OnSurface.R > 200 && dark.OnSurface.G > 200 && dark.OnSurface.B > 200);-- // Primary is distinct from primary container- Assert.NotEqual(light.Primary, light.PrimaryContainer);- Assert.NotEqual(dark.Primary, dark.PrimaryContainer);- }-- [AvaloniaFact]- public void ThemeService_applies_MaterialYou_and_marks_windows()- {- TestServices.EnsureInitialized("en");- var themeService = AppHost.Get<ThemeService>();- var theme = new ThemeSettings- {- Style = ThemeStyle.MaterialYou,- Accent = "#6750A4",- };-- var window = new Window();-- try- {- themeService.Apply(theme, "en");- window.Show();-- Assert.Equal(ThemeStyle.MaterialYou, themeService.CurrentStyle);- Assert.True(themeService.IsMaterialYou);- Assert.Contains("material-you", window.Classes);-- // Brushes and corner radius are written into Application resources- var app = Application.Current!;- Assert.True(app.Resources.ContainsKey("PrimaryContainerBrush"));- Assert.True(app.Resources.ContainsKey("SecondaryContainerBrush"));- Assert.True(app.Resources.ContainsKey("SliderTrackFill"));- Assert.True(app.Resources.ContainsKey("ProgressBarTrackFill"));- Assert.True(app.Resources.ContainsKey("ToggleSwitchFillOn"));-- var radius = Assert.IsType<CornerRadius>(app.Resources["SoftRadiusSmall"]);- Assert.Equal(12, radius.TopLeft); // Smooth non-clipping inputs in Material You- var pill = Assert.IsType<CornerRadius>(app.Resources["PillRadius"]);- Assert.Equal(999, pill.TopLeft); // Full pill for chips & badges- }- finally- {- window.Close();- themeService.Apply(new ThemeSettings(), "en");- var app = Application.Current!;- Assert.False(app.Resources.ContainsKey("SliderTrackFill"));- }- }-- [AvaloniaFact]- public void DonutMenu_reflects_IsMaterialYou_property()- {- TestServices.EnsureInitialized("en");- var donut = new DonutMenu- {- IsMaterialYou = true,- };-- Assert.True(donut.IsMaterialYou);- donut.IsMaterialYou = false;- Assert.False(donut.IsMaterialYou);- }-}