mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-01-28 07:03:17 +08:00
fix(arch): fixed error from eslint refactor
This commit is contained in:
parent
a94fe811dd
commit
1b128cae77
@ -58,25 +58,25 @@ export const drawEdges = function (edgesEl: D3Element, cy: cytoscape.Core) {
|
|||||||
|
|
||||||
if (targetGroup) {
|
if (targetGroup) {
|
||||||
if (isArchitectureDirectionX(targetDir)) {
|
if (isArchitectureDirectionX(targetDir)) {
|
||||||
endX = targetDir === 'L' ? -groupEdgeShift : groupEdgeShift;
|
endX += targetDir === 'L' ? -groupEdgeShift : groupEdgeShift;
|
||||||
} else {
|
} else {
|
||||||
endY = targetDir === 'T' ? -groupEdgeShift : groupEdgeShift + 18;
|
endY += targetDir === 'T' ? -groupEdgeShift : groupEdgeShift + 18;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Adjust the edge distance if it doesn't have the {group} modifier and the endpoint is a junction node
|
// Adjust the edge distance if it doesn't have the {group} modifier and the endpoint is a junction node
|
||||||
if (!sourceGroup && db.getNode(source)?.type === 'junction') {
|
if (!sourceGroup && db.getNode(source)?.type === 'junction') {
|
||||||
if (isArchitectureDirectionX(sourceDir)) {
|
if (isArchitectureDirectionX(sourceDir)) {
|
||||||
startX = sourceDir === 'L' ? halfIconSize : -halfIconSize;
|
startX += sourceDir === 'L' ? halfIconSize : -halfIconSize;
|
||||||
} else {
|
} else {
|
||||||
startY = sourceDir === 'T' ? halfIconSize : -halfIconSize;
|
startY += sourceDir === 'T' ? halfIconSize : -halfIconSize;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!targetGroup && db.getNode(target)?.type === 'junction') {
|
if (!targetGroup && db.getNode(target)?.type === 'junction') {
|
||||||
if (isArchitectureDirectionX(targetDir)) {
|
if (isArchitectureDirectionX(targetDir)) {
|
||||||
endX = targetDir === 'L' ? halfIconSize : -halfIconSize;
|
endX += targetDir === 'L' ? halfIconSize : -halfIconSize;
|
||||||
} else {
|
} else {
|
||||||
endY = targetDir === 'T' ? halfIconSize : -halfIconSize;
|
endY += targetDir === 'T' ? halfIconSize : -halfIconSize;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user