import React from "react"; import { CustomNodeProps } from "src/components/CustomNode"; import * as Styled from "./styles"; export const ObjectNode: React.FC = ({ node, x, y }) => { const { text, width, height, data } = node; const ref = React.useRef(null); if (data.isEmpty) return null; return ( {text.map((val, idx) => { return ( {JSON.stringify(val[0]).replaceAll('"', "")}:{" "} {JSON.stringify(val[1])} ); })} ); };