using Microsoft.CommandPalette.Extensions;

namespace Olive.Pages;

internal sealed class GifPickerPageState
{
  private readonly List<IListItem> _items = [];

  public int DisplayItemCount => _items.Count;

  public IListItem[] Snapshot()
  {
    return [.. _items];
  }

  public void ReplaceItems(IListItem[] items)
  {
    _items.Clear();
    _items.AddRange(items);
  }
}
