Loading editor/widgets/accordion/accordion.cpp +8 −0 Changes for editor/widgets/accordion/accordion.cpp: 8 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -33,6 +33,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include <htmlpp/html.h> #include "plugin.h" #include "llms_text.h" extern "C" { namespace blogi::webedit { Loading Loading @@ -346,6 +347,13 @@ extern "C" { } } // Panel content is real child widgets, walked separately by the // llms.txt tree walker — this only surfaces the panel's own header. std::optional<std::string> toLlmsBlock() const override { if (headerLabel.empty()) return std::nullopt; return llms::mdHeading(3, headerLabel); } // --- JSON Properties Helpers --- std::string toPropertiesJson() { json_object *obj = json_object_new_object(); Loading editor/widgets/article/article.cpp +6 −0 Changes for editor/widgets/article/article.cpp: 6 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -33,6 +33,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include <htmlpp/html.h> #include "plugin.h" #include "llms_text.h" extern "C" { namespace blogi::webedit { Loading Loading @@ -319,6 +320,11 @@ extern "C" { } } std::optional<std::string> toLlmsBlock() const override { if (content.empty()) return std::nullopt; return llms::stripHtml(content); } // --- JSON Properties --- std::string toPropertiesJson() { Loading editor/widgets/customhtml/customhtml.cpp +6 −0 Changes for editor/widgets/customhtml/customhtml.cpp: 6 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -33,6 +33,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include <htmlpp/html.h> #include "plugin.h" #include "llms_text.h" extern "C" { namespace blogi::webedit { Loading Loading @@ -257,6 +258,11 @@ extern "C" { } } std::optional<std::string> toLlmsBlock() const override { if (htmlContent.empty()) return std::nullopt; return llms::stripHtml(htmlContent); } // --- JSON Properties Helpers --- std::string toPropertiesJson() { json_object *obj = json_object_new_object(); Loading editor/widgets/faq/faq.cpp +17 −0 Changes for editor/widgets/faq/faq.cpp: 17 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -36,6 +36,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include <json-c/json.h> #include "plugin.h" #include "llms_text.h" extern "C" { namespace blogi::webedit { Loading Loading @@ -406,6 +407,22 @@ extern "C" { } } std::optional<std::string> toLlmsBlock() const override { std::string block; auto add = [&block](const std::string &part) { if (part.empty()) return; if (!block.empty()) block += "\n\n"; block += part; }; if (!title.empty()) add(llms::mdHeading(2, title)); for (const auto &item : items) { if (!item.question.empty()) add(llms::mdHeading(3, item.question)); if (!item.answer.empty()) add(item.answer); } if (block.empty()) return std::nullopt; return block; } // --- JSON Properties Helpers --- std::string toPropertiesJson() { json_object *obj = json_object_new_object(); Loading editor/widgets/list/list.cpp +13 −0 Changes for editor/widgets/list/list.cpp: 13 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -34,6 +34,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include <htmlpp/html.h> #include "plugin.h" #include "llms_text.h" extern "C" { namespace blogi::webedit { Loading Loading @@ -343,6 +344,18 @@ extern "C" { } } std::optional<std::string> toLlmsBlock() const override { std::string block; for (const auto &item : items) { std::string plain = llms::stripHtml(item); if (plain.empty()) continue; if (!block.empty()) block += "\n"; block += "- " + plain; } if (block.empty()) return std::nullopt; return block; } // --- JSON Properties --- std::string toPropertiesJson() { json_object *obj = json_object_new_object(); Loading Loading
editor/widgets/accordion/accordion.cpp +8 −0 Changes for editor/widgets/accordion/accordion.cpp: 8 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -33,6 +33,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include <htmlpp/html.h> #include "plugin.h" #include "llms_text.h" extern "C" { namespace blogi::webedit { Loading Loading @@ -346,6 +347,13 @@ extern "C" { } } // Panel content is real child widgets, walked separately by the // llms.txt tree walker — this only surfaces the panel's own header. std::optional<std::string> toLlmsBlock() const override { if (headerLabel.empty()) return std::nullopt; return llms::mdHeading(3, headerLabel); } // --- JSON Properties Helpers --- std::string toPropertiesJson() { json_object *obj = json_object_new_object(); Loading
editor/widgets/article/article.cpp +6 −0 Changes for editor/widgets/article/article.cpp: 6 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -33,6 +33,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include <htmlpp/html.h> #include "plugin.h" #include "llms_text.h" extern "C" { namespace blogi::webedit { Loading Loading @@ -319,6 +320,11 @@ extern "C" { } } std::optional<std::string> toLlmsBlock() const override { if (content.empty()) return std::nullopt; return llms::stripHtml(content); } // --- JSON Properties --- std::string toPropertiesJson() { Loading
editor/widgets/customhtml/customhtml.cpp +6 −0 Changes for editor/widgets/customhtml/customhtml.cpp: 6 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -33,6 +33,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include <htmlpp/html.h> #include "plugin.h" #include "llms_text.h" extern "C" { namespace blogi::webedit { Loading Loading @@ -257,6 +258,11 @@ extern "C" { } } std::optional<std::string> toLlmsBlock() const override { if (htmlContent.empty()) return std::nullopt; return llms::stripHtml(htmlContent); } // --- JSON Properties Helpers --- std::string toPropertiesJson() { json_object *obj = json_object_new_object(); Loading
editor/widgets/faq/faq.cpp +17 −0 Changes for editor/widgets/faq/faq.cpp: 17 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -36,6 +36,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include <json-c/json.h> #include "plugin.h" #include "llms_text.h" extern "C" { namespace blogi::webedit { Loading Loading @@ -406,6 +407,22 @@ extern "C" { } } std::optional<std::string> toLlmsBlock() const override { std::string block; auto add = [&block](const std::string &part) { if (part.empty()) return; if (!block.empty()) block += "\n\n"; block += part; }; if (!title.empty()) add(llms::mdHeading(2, title)); for (const auto &item : items) { if (!item.question.empty()) add(llms::mdHeading(3, item.question)); if (!item.answer.empty()) add(item.answer); } if (block.empty()) return std::nullopt; return block; } // --- JSON Properties Helpers --- std::string toPropertiesJson() { json_object *obj = json_object_new_object(); Loading
editor/widgets/list/list.cpp +13 −0 Changes for editor/widgets/list/list.cpp: 13 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -34,6 +34,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include <htmlpp/html.h> #include "plugin.h" #include "llms_text.h" extern "C" { namespace blogi::webedit { Loading Loading @@ -343,6 +344,18 @@ extern "C" { } } std::optional<std::string> toLlmsBlock() const override { std::string block; for (const auto &item : items) { std::string plain = llms::stripHtml(item); if (plain.empty()) continue; if (!block.empty()) block += "\n"; block += "- " + plain; } if (block.empty()) return std::nullopt; return block; } // --- JSON Properties --- std::string toPropertiesJson() { json_object *obj = json_object_new_object(); Loading