antvis/G6

请问支持节点中嵌入 G6 Darge 流程图么? #4560

xiaoke-mgl posted onGitHub

问题描述

在G6 Darge 流程图的节点中,再嵌入完整的 一个 Darge 流程图。

重现链接

https://g6.antv.antgroup.com/zh/examples/item/customNode/#intervalChartNode

重现步骤

  1. 类似 https://g6.antv.antgroup.com/zh/examples/item/customNode/#intervalChartNode 节点中嵌入 G2 的柱状图一样,想在节点中嵌入 g6 的 Darge 流程图

预期行为

类似 https://g6.antv.antgroup.com/zh/examples/item/customNode/#intervalChartNode 节点中嵌入 G2 的柱状图一样,支持节点中嵌入 g6 的 Darge 流程图。

平台

  • 操作系统: [macOS, Windows, Linux, React Native ...]
  • 网页浏览器: [Google Chrome, Safari, Firefox]
  • G6 版本: [4.5.1 ... ]

屏幕截图或视频(可选)

想实现这样的效果 <img width="1036" alt="image" src="https://github.com/antvis/G6/assets/60725422/cbf65ff5-e918-436e-8934-2e8abb29c180">

补充说明(可选)

No response


我可以很负责地告诉你,是可以实现这种布局的。 看一下我之前实现的。 具体思路就是先给节点分组,每一组使用dagre算法生成坐标,然后给他们排版,最后套一个壳combo。链接到其他的节点。

image

posted by PmcFizz almost 2 years ago

我可以很负责地告诉你,是可以实现这种布局的。 看一下我之前实现的。 具体思路就是先给节点分组,每一组使用dagre算法生成坐标,然后给他们排版,最后套一个壳combo。链接到其他的节点。

image

太牛了,愿意贡献到官网 demo 吗

posted by Yanyan-Wang almost 2 years ago

@PmcFizz 感谢解答,我看了文档,和节点分组不一样,因为我要实现的是点击节点上的+号之后,要根据当前节点的name去调用接口,再动态渲染节点内部嵌套的darge 流程图。外层节点是连线的,内层darge流程图不会和外部的节点连线。

posted by xiaoke-mgl almost 2 years ago

@PmcFizz 感谢解答,我看了文档,和节点分组不一样,因为我要实现的是点击节点上的+号之后,要根据当前节点的name去调用接口,再动态渲染节点内部嵌套的darge 流程图。外层节点是连线的,内层darge流程图不会和外部的节点连线。

边可以连接到 combo 上,不连接到节点上就好了

posted by Yanyan-Wang almost 2 years ago

我可以很负责地告诉你,是可以实现这种布局的。 看一下我之前实现的。 具体思路就是先给节点分组,每一组使用dagre算法生成坐标,然后给他们排版,最后套一个壳combo。链接到其他的节点。 image

太牛了,愿意贡献到官网 demo 吗

好的,我抽时间整理一下。

posted by PmcFizz almost 2 years ago

Fund this Issue

$0.00
Funded

Pull requests