using Microsoft.UI.Xaml.Data;
using NixUniversalSDK;

namespace NixExampleWinUI.Helpers;

public class ReferenceWhiteToStringConverter : IValueConverter
{
    public object Convert(object value, Type targetType, object parameter, string language)
    {
        if (value is not ReferenceWhite)
        {
            throw new InvalidOperationException("The target must be a ReferenceWhite enum");
        }

        return ((ReferenceWhite)value).GetFullName();
    }

    public object ConvertBack(object value, Type targetType, object parameter, string language)
    {
        throw new NotImplementedException();
    }
}