// frontend/components/research/ChartCard.tsx — 시각화 + 추세 예측 (예측 막대) "use client"; import { Icon } from "@/components/Icon"; import { sanitizeHtml } from "@/lib/research/sanitize"; import type { ResearchChart } from "@/lib/types"; export function ChartCard({ chart }: { chart?: ResearchChart }) { if (!chart || chart.bars.length === 0) return
; const c = chart; const max = Math.max(...c.bars.map((b) => b.v)); return (
시각화 & 추세 예측

{c.title}

{c.asked}
{c.bars.map((b, i) => (
{b.v}
{b.forecast && 예측}
{b.y}
))}

{c.caution}
); }