import { tableFieldHeight, tableHeaderHeight } from "../data/constants"; import { calcPath } from "../utils/calcPath"; export default function Thumbnail({ diagram, i, zoom, theme }) { return ( {diagram.subjectAreas?.map((a) => ( 0 ? a.width : 0} height={a.height > 0 ? a.height : 0} >
{a.name}
))} {diagram.relationships?.map((r, i) => ( ))} {diagram.tables?.map((table, i) => { const height = table.fields.length * tableFieldHeight + tableHeaderHeight + 7; return (
{table.name}
{table.fields.map((f, j) => (
{f.name}
{f.type}
))}
); })} {diagram.notes?.map((n) => { const x = n.x; const y = n.y; const w = 180; const r = 3; const fold = 24; const h = n.height; return (
{n.content}
); })} ); }