add: more things

Signed-off-by: Kenneth Obsequio <k80308392@gmail.com>
This commit is contained in:
2026-07-04 03:35:22 +08:00
parent 72298b86cd
commit b0f40e5133
78 changed files with 2116 additions and 1621 deletions
-11
View File
@@ -1,11 +0,0 @@
import React from "react";
import { renderToStaticMarkup } from "react-dom/server";
import ReactMarkdown from "react-markdown";
// Same renderer used for the live Preview tab (via <ReactMarkdown>), so the
// stored html_body always matches what the admin saw in preview.
export function markdownToHtml(markdown) {
const trimmed = (markdown ?? "").trim();
if (!trimmed) return "";
return renderToStaticMarkup(React.createElement(ReactMarkdown, null, trimmed));
}