using TodoList.Maui.Models;
using TodoList.Maui.ViewModels;

namespace TodoList.Maui.Views;

public partial class QuickEntryPage : ContentPage
{
	private readonly Action _closeAction;

	public QuickEntryPage(Action closeAction)
	{
		InitializeComponent();
		_closeAction = closeAction;
		BindingContext = new QuickEntryViewModel(_closeAction);
	}

	protected override void OnAppearing()
	{
		base.OnAppearing();
		InputBox.Focus();
	}
}
