We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
图设置为compactBox,边设置是polyline, 但是没有生效
无
我希望实现这种效果
No response
这是设置tree的代码 useEffect(() => { if (!graphData) return; if (!container.current) { return; } const width = container.current.scrollWidth; const height = container.current.scrollHeight
tree = new TreeGraph({ container: container.current, width, height, fitView: true, fitViewPadding: [10, 20], layout: { type: "compactBox", direction: "H", // nodeSep: 16, getHeight: () => { return 16; }, getWidth: (node: { level: number; label: any }) => { return node.level === 0 ? Util.getTextSize(node.label, 16)[0] + 12 : Util.getTextSize(node.label, 12)[0]; }, getVGap: () => { return 20; }, getHGap: () => { return 60; }, }, defaultEdge: { type: 'polyline', style: { stroke: "rgb(205, 97, 255)", lineWidth: 3, }, }, minZoom: 0.5, modes: { default: ["drag-canvas", "zoom-canvas", "dice-mindmap"], }, }); treeRef.current = tree; tree.data(dataTransform(graphData)); tree.render();
}, [graphData])
The text was updated successfully, but these errors were encountered:
No branches or pull requests
问题描述
图设置为compactBox,边设置是polyline,
但是没有生效
重现链接
无
重现步骤
无
预期行为
我希望实现这种效果
平台
屏幕截图或视频(可选)
No response
补充说明(可选)
这是设置tree的代码 useEffect(() => {
if (!graphData) return;
if (!container.current) {
return;
}
const width = container.current.scrollWidth;
const height = container.current.scrollHeight
}, [graphData])
The text was updated successfully, but these errors were encountered: