using Models;
using System.Diagnostics;

namespace LOLAPP.View
{
    public partial class Strat : ContentPage
    {
        public List<Strategie> StratList { get; set; }
        public Manager Mgr => (App.Current as App).MyManager;
        public Strat()
        {
            InitializeComponent();

            // Initialisez la liste des stratégies
            StratList = Mgr.UtilisateurConnecte._strat;

            // Liez la liste des stratégies à la ListView
           // stratListView.ItemsSource = StratList;
        }

       /* private void StratListView_OnItemSelected(object sender, SelectedItemChangedEventArgs e)
        {
            if (e.SelectedItem is Strategie selectedStrat)
            {
                UpdateDetails(selectedStrat);
            }
        }

        private void UpdateDetails(Strategie strat)
        {
            nameLabel.Text = strat.Name;

            championsLayout.Children.Clear();
            foreach (var champion in strat.Champions.Take(5))
            {
                var image = new Image
                {
                    Source = champion.Image
                };
                championsLayout.Children.Add(image);
            }

            descriptionLabel.Text = strat.Description;
        }*/
    }
}
