#pragma once #include #include #include #include #include "katja/repository.hpp" namespace katja { class PackageListBase : public ftxui::ComponentBase { std::string title; const std::vector packages; std::optional selected; public: PackageListBase(const std::string& title, const std::vector& packages = {}); ftxui::Element OnRender() override; bool OnEvent(ftxui::Event event) override; }; ftxui::Component PackageList(const std::string& title, const std::vector& packages = {}); }