mirror of
https://gitee.com/antv/g6.git
synced 2024-12-04 04:38:55 +08:00
fix: resolve conflict
This commit is contained in:
parent
600699b302
commit
294fbdd453
@ -1934,7 +1934,6 @@ export default class Graph extends EventEmitter implements IGraph {
|
||||
return true;
|
||||
});
|
||||
});
|
||||
|
||||
const edges = data.edges;
|
||||
edges && edges.forEach(edge => {
|
||||
const sourceDepth: number = dataDepthMap[edge.source] || 0;
|
||||
@ -1944,14 +1943,6 @@ export default class Graph extends EventEmitter implements IGraph {
|
||||
else depthMap[depth] = [edge.id];
|
||||
});
|
||||
|
||||
data.edges.forEach(edge => {
|
||||
const sourceDepth: number = dataDepthMap[edge.source] || 0;
|
||||
const targetDepth: number = dataDepthMap[edge.target] || 0;
|
||||
const depth = Math.max(sourceDepth, targetDepth);
|
||||
if (depthMap[depth]) depthMap[depth].push(edge.id);
|
||||
else depthMap[depth] = [ edge.id ];
|
||||
});
|
||||
|
||||
depthMap.forEach(array => {
|
||||
if (!array || !array.length) return;
|
||||
for (let i = array.length - 1; i >= 0; i--) {
|
||||
|
Loading…
Reference in New Issue
Block a user