namespace ll::form {
using CustomFormElementResult = std::variant<std::monostate, uint64, double, std::string>;
using CustomFormResult = std::optional<std::unordered_map<std::string, CustomFormElementResult>>;
class CustomForm : public Form {
public:
using Callback = std::function<void(Player&, CustomFormResult const&, FormCancelReason)>;
CustomForm();
CustomForm(std::string const& title);
CustomForm& setTitle(std::string const& title);
CustomForm& setSubmitButton(std::string const& text);
CustomForm& appendHeader(std::string const& text);
CustomForm& appendLabel(std::string const& text);
CustomForm& appendDivider();
CustomForm& appendInput(name, text, placeholder, defaultVal, tooltip);
CustomForm& appendToggle(name, text, defaultVal, tooltip);
CustomForm& appendDropdown(name, text, options, defaultVal, tooltip);
CustomForm& appendSlider(name, text, min, max, step, defaultVal, tooltip);
CustomForm& appendStepSlider(name, text, steps, defaultVal, tooltip);
CustomForm& sendTo(Player& player, Callback callback = {});
CustomForm& sendUpdate(Player& player, Callback callback = {});
};
}