#pragma once #include "esphome/core/component.h" #include "esphome/components/light/light_output.h" #include namespace esphome { namespace custom { class CustomLightOutputConstructor { public: CustomLightOutputConstructor(const std::function()> &init) { this->outputs_ = init(); } light::LightOutput *get_light(int i) { return this->outputs_[i]; } protected: std::vector outputs_; }; } // namespace custom } // namespace esphome