mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-09-03 07:36:41 +02:00
1295 Lint fixes
This commit is contained in:
@@ -18,7 +18,7 @@
|
|||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<h1>info below</h1>
|
<h1>info below</h1>
|
||||||
<div style="display: flex;width: 100%; height: 100%">
|
<div style="display: flex;flex-direction:column;width: 100%; height: 100%">
|
||||||
<div class="mermaid2" style="width: 100%; height: 100%;display: none;">
|
<div class="mermaid2" style="width: 100%; height: 100%;display: none;">
|
||||||
flowchart LR
|
flowchart LR
|
||||||
A --> B & C & D
|
A --> B & C & D
|
||||||
@@ -33,25 +33,12 @@
|
|||||||
C --> D
|
C --> D
|
||||||
C --> D
|
C --> D
|
||||||
</div>
|
</div>
|
||||||
<div class="mermaid" style="width: 100%; height: 100%">
|
|
||||||
graph LR
|
|
||||||
A[apan klättrar]-- i träd -->B
|
|
||||||
subgraph id1 [Test with title wider then the node in the subgraph]
|
|
||||||
B
|
|
||||||
end
|
|
||||||
</div>
|
|
||||||
<div class="mermaid" style="width: 100%; height: 100%">
|
<div class="mermaid" style="width: 100%; height: 100%">
|
||||||
flowchart LR
|
flowchart LR
|
||||||
A-- i träd -->B
|
G-->H
|
||||||
|
G-->H
|
||||||
subgraph id1 [Test]
|
subgraph id1 [Test]
|
||||||
B
|
H
|
||||||
end
|
|
||||||
</div>
|
|
||||||
<div class="mermaid" style="width: 100%; height: 100%">
|
|
||||||
flowchart TB
|
|
||||||
C[apan klättrar]-- i träd -->D
|
|
||||||
subgraph id1 [Test]
|
|
||||||
D
|
|
||||||
end
|
end
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@@ -32,7 +32,6 @@ const rect = (parent, node) => {
|
|||||||
.attr('width', node.width + padding)
|
.attr('width', node.width + padding)
|
||||||
.attr('height', node.height + padding);
|
.attr('height', node.height + padding);
|
||||||
|
|
||||||
const adj = (node.width + node.padding - bbox.width) / 2;
|
|
||||||
logger.info('bbox', bbox.width, node.x, node.width);
|
logger.info('bbox', bbox.width, node.x, node.width);
|
||||||
// Center the label
|
// Center the label
|
||||||
// label.attr('transform', 'translate(' + adj + ', ' + (node.y - node.height / 2) + ')');
|
// label.attr('transform', 'translate(' + adj + ', ' + (node.y - node.height / 2) + ')');
|
||||||
|
@@ -1,7 +1,7 @@
|
|||||||
import dagre from 'dagre';
|
import dagre from 'dagre';
|
||||||
import insertMarkers from './markers';
|
import insertMarkers from './markers';
|
||||||
import { insertNode, positionNode } from './nodes';
|
import { insertNode, positionNode } from './nodes';
|
||||||
import { insertCluster, positionCluster, getClusterTitleWidth } from './clusters';
|
import { insertCluster } from './clusters';
|
||||||
import { insertEdgeLabel, positionEdgeLabel, insertEdge } from './edges';
|
import { insertEdgeLabel, positionEdgeLabel, insertEdge } from './edges';
|
||||||
import { logger } from '../logger';
|
import { logger } from '../logger';
|
||||||
|
|
||||||
@@ -15,7 +15,6 @@ export const render = (elem, graph) => {
|
|||||||
|
|
||||||
// Insert nodes, this will insert them into the dom and each node will get a size. The size is updated
|
// Insert nodes, this will insert them into the dom and each node will get a size. The size is updated
|
||||||
// to the abstract node and is later used by dagre for the layout
|
// to the abstract node and is later used by dagre for the layout
|
||||||
const nodes2expand = [];
|
|
||||||
graph.nodes().forEach(function(v) {
|
graph.nodes().forEach(function(v) {
|
||||||
const node = graph.node(v);
|
const node = graph.node(v);
|
||||||
logger.info('Node ' + v + ': ' + JSON.stringify(graph.node(v)));
|
logger.info('Node ' + v + ': ' + JSON.stringify(graph.node(v)));
|
||||||
|
Reference in New Issue
Block a user