mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-08-26 03:36:41 +02:00
Removing hard coding with dynamic values for cardinalities
This commit is contained in:
@@ -50,6 +50,10 @@
|
|||||||
classA -- classC : link
|
classA -- classC : link
|
||||||
classC -- classD : link
|
classC -- classD : link
|
||||||
classB -- classD
|
classB -- classD
|
||||||
|
|
||||||
|
Customer "1" --> "*" Ticket
|
||||||
|
Student "1" --> "1..*" Course
|
||||||
|
Galaxy --> "many" Star : Contains
|
||||||
</div>
|
</div>
|
||||||
<script src="./mermaid.js"></script>
|
<script src="./mermaid.js"></script>
|
||||||
<script>
|
<script>
|
||||||
|
@@ -155,12 +155,11 @@ export const addRelations = function(relations, g) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
logger.info(edgeData, edge);
|
logger.info(edgeData, edge);
|
||||||
|
|
||||||
//Set edge extra labels
|
//Set edge extra labels
|
||||||
edgeData.startLabelLeft = 'TL';
|
//edgeData.startLabelLeft = edge.relationTitle1;
|
||||||
edgeData.startLabelRight = 'TR';
|
edgeData.startLabelRight = edge.relationTitle1 === 'none' ? '' : edge.relationTitle1;
|
||||||
edgeData.endLabelLeft = 'BL';
|
edgeData.endLabelLeft = edge.relationTitle2 === 'none' ? '' : edge.relationTitle2;
|
||||||
edgeData.endLabelRight = 'BR';
|
//edgeData.endLabelRight = edge.relationTitle2;
|
||||||
|
|
||||||
//Set relation arrow types
|
//Set relation arrow types
|
||||||
edgeData.arrowTypeStart = getArrowMarker(edge.relation.type1);
|
edgeData.arrowTypeStart = getArrowMarker(edge.relation.type1);
|
||||||
|
Reference in New Issue
Block a user