Files
buzz-sheet/components/rich-text-content.tsx
T
gunshiz 4c30ee14f1
CI / Verify (push) Failing after 1m1s
CI / Build immutable images and deploy (push) Skipped
feat :just remove theme switch
2026-10-10 01:24:50 +07:00

20 lines
423 B
TypeScript

import { cn } from "@/lib/utils";
import { sanitizeRichTextHtml } from "@/lib/rich-text";
export function RichTextContent({
html,
className,
}: {
html: string;
className?: string;
}) {
if (!html) return null;
return (
<div
className={cn("prose prose-sm prose-invert max-w-none leading-snug [&>p]:m-0", className)}
dangerouslySetInnerHTML={{ __html: sanitizeRichTextHtml(html) }}
/>
);
}