using Model;

namespace ViewModel
{
    public class ChampionVM : BaseToolkit
    {
        public Champion Model
        {
            get => _model;
            set
            {
                //if (_model.Equals(value) || _model.Equals(null)) return;
                _model = value;
                OnPropertyChanged();
            }
        }
        private Champion _model;


        public ChampionVM(Champion model)
        {
            Model = model;
        }

        public ChampionVM()
        {
            Model = new Champion("Poppy", ChampionClass.Tank);
        }

        public string Name
        {
            get => Model.Name;
        }

        public string Bio
        {
            get => Model.Bio;
            set
            {
                if (value == null) return;
                _model.Bio = value;
                OnPropertyChanged();
            }
        }
    }
}