using Material.Icons;
using ReactiveUI;

namespace PSCHelpdesk.Plugins.HetznerServer.Models;

public class Plugin : ReactiveObject
{
    public string Title { get; set; }
    
    private bool _installed;
    
    public bool Installed
    {
        get => _installed;
        set
        {
            this.RaiseAndSetIfChanged(ref _installed, value);
        }
    }

    private MaterialIconKind _icon;
    
    public MaterialIconKind Icon
    {
        get => Installed==true? MaterialIconKind.Check:MaterialIconKind.Delete;
        set => this.RaiseAndSetIfChanged(ref _icon, value);
    }
    
    public string Uuid { get; set; }

    public Plugin()
    {
        Installed = false;
        Icon = MaterialIconKind.Remove;
    }
}