<?php

namespace LaraBB\Settings\UI\Web\Handlers\Admin\Prefix;

use Illuminate\Contracts\View\Factory;
use Illuminate\Contracts\View\View;
use LaraBB\Settings\Actions\Prefix\OverviewAction;

/**
 * Class IndexHandler
 * @package LaraBB\Settings\UI\Web\Handlers\Admin\Prefix
 */
class OverviewHandler
{
    /**
     * IndexHandler constructor.
     * @param OverviewAction $overviewAction
     * @param Factory $view
     */
    public function __construct(private readonly OverviewAction $overviewAction, private readonly Factory $view)
    {

    }

    /**
     * @return View
     */
    public function __invoke(): View
    {
        return $this->view->make('settings::admin.prefix.index', $this->overviewAction->run());
    }
}
