Update AutoCompleteBox bindings and clean up project files (#802)

* fix: update ValueMemberBinding syntax for AutoCompleteBox components.

* chore: remove AvaloniaUseCompiledBindingsByDefault property from project files.

* ci: upgrade draft release version.
This commit is contained in:
Zhang Dian
2026-04-15 17:01:28 +08:00
committed by GitHub
parent 555ecf16d9
commit 89cdae2d39
9 changed files with 17 additions and 51 deletions

View File

@@ -1,28 +0,0 @@
using System;
using System.Collections.Generic;
using System.Globalization;
using Avalonia;
using Avalonia.Data.Converters;
using Avalonia.Metadata;
namespace Semi.Avalonia.Demo.Converters;
public class FileIconConverter : IMultiValueConverter
{
[Content] public IDictionary<string, object?> Items { get; } = new Dictionary<string, object?>();
public object? Convert(IList<object?> values, Type targetType, object? parameter, CultureInfo culture)
{
if (values[0] is bool isDirectory && values[1] is bool isOpen)
{
if (!isDirectory)
{
return Items["file"];
}
return isOpen ? Items["folderOpen"] : Items["folderClosed"];
}
return AvaloniaProperty.UnsetValue;
}
}