@oxide/design-system 1.7.7--canary.c74e439.0 → 1.7.7--canary.5c25e1b.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/dist/index.d.ts +0 -3
- package/components/dist/index.js +145 -1804
- package/components/dist/index.js.map +1 -1
- package/package.json +1 -2
- package/components/dist/architecture-I3QFYML2-YZWO3N3B.js +0 -14
- package/components/dist/architecture-I3QFYML2-YZWO3N3B.js.map +0 -1
- package/components/dist/architectureDiagram-UYN6MBPD-HXPGIDN7.js +0 -8846
- package/components/dist/architectureDiagram-UYN6MBPD-HXPGIDN7.js.map +0 -1
- package/components/dist/blockDiagram-ZHA2E4KO-OAYYKCLF.js +0 -3721
- package/components/dist/blockDiagram-ZHA2E4KO-OAYYKCLF.js.map +0 -1
- package/components/dist/c4Diagram-6F5ED5ID-TBHFK2XY.js +0 -2599
- package/components/dist/c4Diagram-6F5ED5ID-TBHFK2XY.js.map +0 -1
- package/components/dist/chunk-2DDKDUUO.js +0 -439
- package/components/dist/chunk-2DDKDUUO.js.map +0 -1
- package/components/dist/chunk-2NHDMTP7.js +0 -26905
- package/components/dist/chunk-2NHDMTP7.js.map +0 -1
- package/components/dist/chunk-4IJS44L3.js +0 -22
- package/components/dist/chunk-4IJS44L3.js.map +0 -1
- package/components/dist/chunk-562WOS3Z.js +0 -1109
- package/components/dist/chunk-562WOS3Z.js.map +0 -1
- package/components/dist/chunk-6UD2HOKB.js +0 -17082
- package/components/dist/chunk-6UD2HOKB.js.map +0 -1
- package/components/dist/chunk-76BOQ7BT.js +0 -63
- package/components/dist/chunk-76BOQ7BT.js.map +0 -1
- package/components/dist/chunk-7I5DT373.js +0 -97
- package/components/dist/chunk-7I5DT373.js.map +0 -1
- package/components/dist/chunk-BPREMNVP.js +0 -1875
- package/components/dist/chunk-BPREMNVP.js.map +0 -1
- package/components/dist/chunk-BVYAEHG3.js +0 -122
- package/components/dist/chunk-BVYAEHG3.js.map +0 -1
- package/components/dist/chunk-BW7DFBOS.js +0 -152
- package/components/dist/chunk-BW7DFBOS.js.map +0 -1
- package/components/dist/chunk-EZG2MNHW.js +0 -59
- package/components/dist/chunk-EZG2MNHW.js.map +0 -1
- package/components/dist/chunk-G6QWNAHJ.js +0 -43
- package/components/dist/chunk-G6QWNAHJ.js.map +0 -1
- package/components/dist/chunk-H72D3HRR.js +0 -1244
- package/components/dist/chunk-H72D3HRR.js.map +0 -1
- package/components/dist/chunk-K532NZMW.js +0 -46
- package/components/dist/chunk-K532NZMW.js.map +0 -1
- package/components/dist/chunk-LC3BX2KL.js +0 -25
- package/components/dist/chunk-LC3BX2KL.js.map +0 -1
- package/components/dist/chunk-LQ2ABR7F.js +0 -5665
- package/components/dist/chunk-LQ2ABR7F.js.map +0 -1
- package/components/dist/chunk-M6L3MM6K.js +0 -22
- package/components/dist/chunk-M6L3MM6K.js.map +0 -1
- package/components/dist/chunk-MWA4PRRW.js +0 -122
- package/components/dist/chunk-MWA4PRRW.js.map +0 -1
- package/components/dist/chunk-ND3FLKHU.js +0 -570
- package/components/dist/chunk-ND3FLKHU.js.map +0 -1
- package/components/dist/chunk-NIVHLOPB.js +0 -2621
- package/components/dist/chunk-NIVHLOPB.js.map +0 -1
- package/components/dist/chunk-R6F6FFK7.js +0 -65
- package/components/dist/chunk-R6F6FFK7.js.map +0 -1
- package/components/dist/chunk-RN5R3L7O.js +0 -2041
- package/components/dist/chunk-RN5R3L7O.js.map +0 -1
- package/components/dist/chunk-RWDBBMDN.js +0 -10910
- package/components/dist/chunk-RWDBBMDN.js.map +0 -1
- package/components/dist/chunk-T7HPDS4Z.js +0 -573
- package/components/dist/chunk-T7HPDS4Z.js.map +0 -1
- package/components/dist/chunk-TG4YEU4Q.js +0 -23
- package/components/dist/chunk-TG4YEU4Q.js.map +0 -1
- package/components/dist/chunk-U5WCXBW2.js +0 -48
- package/components/dist/chunk-U5WCXBW2.js.map +0 -1
- package/components/dist/chunk-V6PWN6OH.js +0 -1875
- package/components/dist/chunk-V6PWN6OH.js.map +0 -1
- package/components/dist/chunk-VLTHNCSD.js +0 -48
- package/components/dist/chunk-VLTHNCSD.js.map +0 -1
- package/components/dist/chunk-WDK4G4UR.js +0 -2791
- package/components/dist/chunk-WDK4G4UR.js.map +0 -1
- package/components/dist/chunk-WLVQWTC6.js +0 -77
- package/components/dist/chunk-WLVQWTC6.js.map +0 -1
- package/components/dist/chunk-YDLS5R4M.js +0 -48
- package/components/dist/chunk-YDLS5R4M.js.map +0 -1
- package/components/dist/chunk-YGFBWU2Q.js +0 -7
- package/components/dist/chunk-YGFBWU2Q.js.map +0 -1
- package/components/dist/chunk-ZBL4CWCH.js +0 -2120
- package/components/dist/chunk-ZBL4CWCH.js.map +0 -1
- package/components/dist/classDiagram-LNE6IOMH-VRQHEQWM.js +0 -40
- package/components/dist/classDiagram-LNE6IOMH-VRQHEQWM.js.map +0 -1
- package/components/dist/classDiagram-v2-MQ7JQ4JX-5GB4NXXM.js +0 -40
- package/components/dist/classDiagram-v2-MQ7JQ4JX-5GB4NXXM.js.map +0 -1
- package/components/dist/dagre-4EVJKHTY-XW45LMKR.js +0 -734
- package/components/dist/dagre-4EVJKHTY-XW45LMKR.js.map +0 -1
- package/components/dist/diagram-QW4FP2JN-J2YMUPB5.js +0 -226
- package/components/dist/diagram-QW4FP2JN-J2YMUPB5.js.map +0 -1
- package/components/dist/erDiagram-6RL3IURR-HQULDVJI.js +0 -1381
- package/components/dist/erDiagram-6RL3IURR-HQULDVJI.js.map +0 -1
- package/components/dist/flowDiagram-7ASYPVHJ-2542732I.js +0 -2349
- package/components/dist/flowDiagram-7ASYPVHJ-2542732I.js.map +0 -1
- package/components/dist/ganttDiagram-NTVNEXSI-V66YQQB3.js +0 -2413
- package/components/dist/ganttDiagram-NTVNEXSI-V66YQQB3.js.map +0 -1
- package/components/dist/gitGraph-YCYPL57B-AAXPWQN7.js +0 -14
- package/components/dist/gitGraph-YCYPL57B-AAXPWQN7.js.map +0 -1
- package/components/dist/gitGraphDiagram-NRZ2UAAF-5DU6QMYZ.js +0 -1763
- package/components/dist/gitGraphDiagram-NRZ2UAAF-5DU6QMYZ.js.map +0 -1
- package/components/dist/info-46DW6VJ7-43TTIEYF.js +0 -14
- package/components/dist/info-46DW6VJ7-43TTIEYF.js.map +0 -1
- package/components/dist/infoDiagram-A4XQUW5V-UZERSQDI.js +0 -54
- package/components/dist/infoDiagram-A4XQUW5V-UZERSQDI.js.map +0 -1
- package/components/dist/journeyDiagram-G5WM74LC-RVKMRGRW.js +0 -1244
- package/components/dist/journeyDiagram-G5WM74LC-RVKMRGRW.js.map +0 -1
- package/components/dist/kanban-definition-QRCXZQQD-NWU5I3TK.js +0 -1119
- package/components/dist/kanban-definition-QRCXZQQD-NWU5I3TK.js.map +0 -1
- package/components/dist/katex-WNZY3CE5.js +0 -14484
- package/components/dist/katex-WNZY3CE5.js.map +0 -1
- package/components/dist/mindmap-definition-GWI6TPTV-MISEH6LG.js +0 -6013
- package/components/dist/mindmap-definition-GWI6TPTV-MISEH6LG.js.map +0 -1
- package/components/dist/packet-W2GHVCYJ-FBZCFIPR.js +0 -14
- package/components/dist/packet-W2GHVCYJ-FBZCFIPR.js.map +0 -1
- package/components/dist/pie-BEWT4RHE-UFFBBCXM.js +0 -14
- package/components/dist/pie-BEWT4RHE-UFFBBCXM.js.map +0 -1
- package/components/dist/pieDiagram-YF2LJOPJ-IXEVHPCM.js +0 -223
- package/components/dist/pieDiagram-YF2LJOPJ-IXEVHPCM.js.map +0 -1
- package/components/dist/quadrantDiagram-OS5C2QUG-MW26UCZV.js +0 -1408
- package/components/dist/quadrantDiagram-OS5C2QUG-MW26UCZV.js.map +0 -1
- package/components/dist/requirementDiagram-MIRIMTAZ-BX24AAHL.js +0 -1175
- package/components/dist/requirementDiagram-MIRIMTAZ-BX24AAHL.js.map +0 -1
- package/components/dist/sankeyDiagram-Y46BX6SQ-5RKUGG63.js +0 -1278
- package/components/dist/sankeyDiagram-Y46BX6SQ-5RKUGG63.js.map +0 -1
- package/components/dist/sequenceDiagram-G6AWOVSC-2T3JBUZ2.js +0 -3529
- package/components/dist/sequenceDiagram-G6AWOVSC-2T3JBUZ2.js.map +0 -1
- package/components/dist/stateDiagram-MAYHULR4-HZ5EGLPA.js +0 -505
- package/components/dist/stateDiagram-MAYHULR4-HZ5EGLPA.js.map +0 -1
- package/components/dist/stateDiagram-v2-4JROLMXI-DN2FEZV3.js +0 -40
- package/components/dist/stateDiagram-v2-4JROLMXI-DN2FEZV3.js.map +0 -1
- package/components/dist/timeline-definition-U7ZMHBDA-GB6AKKW4.js +0 -1260
- package/components/dist/timeline-definition-U7ZMHBDA-GB6AKKW4.js.map +0 -1
- package/components/dist/xychartDiagram-6QU3TZC5-BFFLEHUP.js +0 -1877
- package/components/dist/xychartDiagram-6QU3TZC5-BFFLEHUP.js.map +0 -1
|
@@ -1,570 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
at,
|
|
3
|
-
createLabel_default
|
|
4
|
-
} from "./chunk-LQ2ABR7F.js";
|
|
5
|
-
import {
|
|
6
|
-
getLineFunctionsWithOffset
|
|
7
|
-
} from "./chunk-BW7DFBOS.js";
|
|
8
|
-
import {
|
|
9
|
-
getSubGraphTitleMargins
|
|
10
|
-
} from "./chunk-M6L3MM6K.js";
|
|
11
|
-
import {
|
|
12
|
-
createText
|
|
13
|
-
} from "./chunk-NIVHLOPB.js";
|
|
14
|
-
import {
|
|
15
|
-
utils_default
|
|
16
|
-
} from "./chunk-T7HPDS4Z.js";
|
|
17
|
-
import {
|
|
18
|
-
__name,
|
|
19
|
-
basis_default,
|
|
20
|
-
evaluate,
|
|
21
|
-
getConfig2,
|
|
22
|
-
line_default,
|
|
23
|
-
log,
|
|
24
|
-
select_default
|
|
25
|
-
} from "./chunk-RWDBBMDN.js";
|
|
26
|
-
|
|
27
|
-
// node_modules/mermaid/dist/chunks/mermaid.core/chunk-66SQ7PYY.mjs
|
|
28
|
-
var addEdgeMarkers = /* @__PURE__ */ __name((svgPath, edge, url, id, diagramType) => {
|
|
29
|
-
if (edge.arrowTypeStart) {
|
|
30
|
-
addEdgeMarker(svgPath, "start", edge.arrowTypeStart, url, id, diagramType);
|
|
31
|
-
}
|
|
32
|
-
if (edge.arrowTypeEnd) {
|
|
33
|
-
addEdgeMarker(svgPath, "end", edge.arrowTypeEnd, url, id, diagramType);
|
|
34
|
-
}
|
|
35
|
-
}, "addEdgeMarkers");
|
|
36
|
-
var arrowTypesMap = {
|
|
37
|
-
arrow_cross: "cross",
|
|
38
|
-
arrow_point: "point",
|
|
39
|
-
arrow_barb: "barb",
|
|
40
|
-
arrow_circle: "circle",
|
|
41
|
-
aggregation: "aggregation",
|
|
42
|
-
extension: "extension",
|
|
43
|
-
composition: "composition",
|
|
44
|
-
dependency: "dependency",
|
|
45
|
-
lollipop: "lollipop"
|
|
46
|
-
};
|
|
47
|
-
var addEdgeMarker = /* @__PURE__ */ __name((svgPath, position, arrowType, url, id, diagramType) => {
|
|
48
|
-
const endMarkerType = arrowTypesMap[arrowType];
|
|
49
|
-
if (!endMarkerType) {
|
|
50
|
-
log.warn(`Unknown arrow type: ${arrowType}`);
|
|
51
|
-
return;
|
|
52
|
-
}
|
|
53
|
-
const suffix = position === "start" ? "Start" : "End";
|
|
54
|
-
svgPath.attr(`marker-${position}`, `url(${url}#${id}_${diagramType}-${endMarkerType}${suffix})`);
|
|
55
|
-
}, "addEdgeMarker");
|
|
56
|
-
var edgeLabels = /* @__PURE__ */ new Map();
|
|
57
|
-
var terminalLabels = /* @__PURE__ */ new Map();
|
|
58
|
-
var clear = /* @__PURE__ */ __name(() => {
|
|
59
|
-
edgeLabels.clear();
|
|
60
|
-
terminalLabels.clear();
|
|
61
|
-
}, "clear");
|
|
62
|
-
var getLabelStyles = /* @__PURE__ */ __name((styleArray) => {
|
|
63
|
-
let styles = styleArray ? styleArray.reduce((acc, style) => acc + ";" + style, "") : "";
|
|
64
|
-
return styles;
|
|
65
|
-
}, "getLabelStyles");
|
|
66
|
-
var insertEdgeLabel = /* @__PURE__ */ __name(async (elem, edge) => {
|
|
67
|
-
let useHtmlLabels = evaluate(getConfig2().flowchart.htmlLabels);
|
|
68
|
-
const labelElement = await createText(elem, edge.label, {
|
|
69
|
-
style: getLabelStyles(edge.labelStyle),
|
|
70
|
-
useHtmlLabels,
|
|
71
|
-
addSvgBackground: true,
|
|
72
|
-
isNode: false
|
|
73
|
-
});
|
|
74
|
-
log.info("abc82", edge, edge.labelType);
|
|
75
|
-
const edgeLabel = elem.insert("g").attr("class", "edgeLabel");
|
|
76
|
-
const label = edgeLabel.insert("g").attr("class", "label");
|
|
77
|
-
label.node().appendChild(labelElement);
|
|
78
|
-
let bbox = labelElement.getBBox();
|
|
79
|
-
if (useHtmlLabels) {
|
|
80
|
-
const div = labelElement.children[0];
|
|
81
|
-
const dv = select_default(labelElement);
|
|
82
|
-
bbox = div.getBoundingClientRect();
|
|
83
|
-
dv.attr("width", bbox.width);
|
|
84
|
-
dv.attr("height", bbox.height);
|
|
85
|
-
}
|
|
86
|
-
label.attr("transform", "translate(" + -bbox.width / 2 + ", " + -bbox.height / 2 + ")");
|
|
87
|
-
edgeLabels.set(edge.id, edgeLabel);
|
|
88
|
-
edge.width = bbox.width;
|
|
89
|
-
edge.height = bbox.height;
|
|
90
|
-
let fo;
|
|
91
|
-
if (edge.startLabelLeft) {
|
|
92
|
-
const startLabelElement = await createLabel_default(
|
|
93
|
-
edge.startLabelLeft,
|
|
94
|
-
getLabelStyles(edge.labelStyle)
|
|
95
|
-
);
|
|
96
|
-
const startEdgeLabelLeft = elem.insert("g").attr("class", "edgeTerminals");
|
|
97
|
-
const inner = startEdgeLabelLeft.insert("g").attr("class", "inner");
|
|
98
|
-
fo = inner.node().appendChild(startLabelElement);
|
|
99
|
-
const slBox = startLabelElement.getBBox();
|
|
100
|
-
inner.attr("transform", "translate(" + -slBox.width / 2 + ", " + -slBox.height / 2 + ")");
|
|
101
|
-
if (!terminalLabels.get(edge.id)) {
|
|
102
|
-
terminalLabels.set(edge.id, {});
|
|
103
|
-
}
|
|
104
|
-
terminalLabels.get(edge.id).startLeft = startEdgeLabelLeft;
|
|
105
|
-
setTerminalWidth(fo, edge.startLabelLeft);
|
|
106
|
-
}
|
|
107
|
-
if (edge.startLabelRight) {
|
|
108
|
-
const startLabelElement = await createLabel_default(
|
|
109
|
-
edge.startLabelRight,
|
|
110
|
-
getLabelStyles(edge.labelStyle)
|
|
111
|
-
);
|
|
112
|
-
const startEdgeLabelRight = elem.insert("g").attr("class", "edgeTerminals");
|
|
113
|
-
const inner = startEdgeLabelRight.insert("g").attr("class", "inner");
|
|
114
|
-
fo = startEdgeLabelRight.node().appendChild(startLabelElement);
|
|
115
|
-
inner.node().appendChild(startLabelElement);
|
|
116
|
-
const slBox = startLabelElement.getBBox();
|
|
117
|
-
inner.attr("transform", "translate(" + -slBox.width / 2 + ", " + -slBox.height / 2 + ")");
|
|
118
|
-
if (!terminalLabels.get(edge.id)) {
|
|
119
|
-
terminalLabels.set(edge.id, {});
|
|
120
|
-
}
|
|
121
|
-
terminalLabels.get(edge.id).startRight = startEdgeLabelRight;
|
|
122
|
-
setTerminalWidth(fo, edge.startLabelRight);
|
|
123
|
-
}
|
|
124
|
-
if (edge.endLabelLeft) {
|
|
125
|
-
const endLabelElement = await createLabel_default(edge.endLabelLeft, getLabelStyles(edge.labelStyle));
|
|
126
|
-
const endEdgeLabelLeft = elem.insert("g").attr("class", "edgeTerminals");
|
|
127
|
-
const inner = endEdgeLabelLeft.insert("g").attr("class", "inner");
|
|
128
|
-
fo = inner.node().appendChild(endLabelElement);
|
|
129
|
-
const slBox = endLabelElement.getBBox();
|
|
130
|
-
inner.attr("transform", "translate(" + -slBox.width / 2 + ", " + -slBox.height / 2 + ")");
|
|
131
|
-
endEdgeLabelLeft.node().appendChild(endLabelElement);
|
|
132
|
-
if (!terminalLabels.get(edge.id)) {
|
|
133
|
-
terminalLabels.set(edge.id, {});
|
|
134
|
-
}
|
|
135
|
-
terminalLabels.get(edge.id).endLeft = endEdgeLabelLeft;
|
|
136
|
-
setTerminalWidth(fo, edge.endLabelLeft);
|
|
137
|
-
}
|
|
138
|
-
if (edge.endLabelRight) {
|
|
139
|
-
const endLabelElement = await createLabel_default(edge.endLabelRight, getLabelStyles(edge.labelStyle));
|
|
140
|
-
const endEdgeLabelRight = elem.insert("g").attr("class", "edgeTerminals");
|
|
141
|
-
const inner = endEdgeLabelRight.insert("g").attr("class", "inner");
|
|
142
|
-
fo = inner.node().appendChild(endLabelElement);
|
|
143
|
-
const slBox = endLabelElement.getBBox();
|
|
144
|
-
inner.attr("transform", "translate(" + -slBox.width / 2 + ", " + -slBox.height / 2 + ")");
|
|
145
|
-
endEdgeLabelRight.node().appendChild(endLabelElement);
|
|
146
|
-
if (!terminalLabels.get(edge.id)) {
|
|
147
|
-
terminalLabels.set(edge.id, {});
|
|
148
|
-
}
|
|
149
|
-
terminalLabels.get(edge.id).endRight = endEdgeLabelRight;
|
|
150
|
-
setTerminalWidth(fo, edge.endLabelRight);
|
|
151
|
-
}
|
|
152
|
-
return labelElement;
|
|
153
|
-
}, "insertEdgeLabel");
|
|
154
|
-
function setTerminalWidth(fo, value) {
|
|
155
|
-
if (getConfig2().flowchart.htmlLabels && fo) {
|
|
156
|
-
fo.style.width = value.length * 9 + "px";
|
|
157
|
-
fo.style.height = "12px";
|
|
158
|
-
}
|
|
159
|
-
}
|
|
160
|
-
__name(setTerminalWidth, "setTerminalWidth");
|
|
161
|
-
var positionEdgeLabel = /* @__PURE__ */ __name((edge, paths) => {
|
|
162
|
-
log.debug("Moving label abc88 ", edge.id, edge.label, edgeLabels.get(edge.id), paths);
|
|
163
|
-
let path = paths.updatedPath ? paths.updatedPath : paths.originalPath;
|
|
164
|
-
const siteConfig = getConfig2();
|
|
165
|
-
const { subGraphTitleTotalMargin } = getSubGraphTitleMargins(siteConfig);
|
|
166
|
-
if (edge.label) {
|
|
167
|
-
const el = edgeLabels.get(edge.id);
|
|
168
|
-
let x = edge.x;
|
|
169
|
-
let y = edge.y;
|
|
170
|
-
if (path) {
|
|
171
|
-
const pos = utils_default.calcLabelPosition(path);
|
|
172
|
-
log.debug(
|
|
173
|
-
"Moving label " + edge.label + " from (",
|
|
174
|
-
x,
|
|
175
|
-
",",
|
|
176
|
-
y,
|
|
177
|
-
") to (",
|
|
178
|
-
pos.x,
|
|
179
|
-
",",
|
|
180
|
-
pos.y,
|
|
181
|
-
") abc88"
|
|
182
|
-
);
|
|
183
|
-
if (paths.updatedPath) {
|
|
184
|
-
x = pos.x;
|
|
185
|
-
y = pos.y;
|
|
186
|
-
}
|
|
187
|
-
}
|
|
188
|
-
el.attr("transform", `translate(${x}, ${y + subGraphTitleTotalMargin / 2})`);
|
|
189
|
-
}
|
|
190
|
-
if (edge.startLabelLeft) {
|
|
191
|
-
const el = terminalLabels.get(edge.id).startLeft;
|
|
192
|
-
let x = edge.x;
|
|
193
|
-
let y = edge.y;
|
|
194
|
-
if (path) {
|
|
195
|
-
const pos = utils_default.calcTerminalLabelPosition(edge.arrowTypeStart ? 10 : 0, "start_left", path);
|
|
196
|
-
x = pos.x;
|
|
197
|
-
y = pos.y;
|
|
198
|
-
}
|
|
199
|
-
el.attr("transform", `translate(${x}, ${y})`);
|
|
200
|
-
}
|
|
201
|
-
if (edge.startLabelRight) {
|
|
202
|
-
const el = terminalLabels.get(edge.id).startRight;
|
|
203
|
-
let x = edge.x;
|
|
204
|
-
let y = edge.y;
|
|
205
|
-
if (path) {
|
|
206
|
-
const pos = utils_default.calcTerminalLabelPosition(
|
|
207
|
-
edge.arrowTypeStart ? 10 : 0,
|
|
208
|
-
"start_right",
|
|
209
|
-
path
|
|
210
|
-
);
|
|
211
|
-
x = pos.x;
|
|
212
|
-
y = pos.y;
|
|
213
|
-
}
|
|
214
|
-
el.attr("transform", `translate(${x}, ${y})`);
|
|
215
|
-
}
|
|
216
|
-
if (edge.endLabelLeft) {
|
|
217
|
-
const el = terminalLabels.get(edge.id).endLeft;
|
|
218
|
-
let x = edge.x;
|
|
219
|
-
let y = edge.y;
|
|
220
|
-
if (path) {
|
|
221
|
-
const pos = utils_default.calcTerminalLabelPosition(edge.arrowTypeEnd ? 10 : 0, "end_left", path);
|
|
222
|
-
x = pos.x;
|
|
223
|
-
y = pos.y;
|
|
224
|
-
}
|
|
225
|
-
el.attr("transform", `translate(${x}, ${y})`);
|
|
226
|
-
}
|
|
227
|
-
if (edge.endLabelRight) {
|
|
228
|
-
const el = terminalLabels.get(edge.id).endRight;
|
|
229
|
-
let x = edge.x;
|
|
230
|
-
let y = edge.y;
|
|
231
|
-
if (path) {
|
|
232
|
-
const pos = utils_default.calcTerminalLabelPosition(edge.arrowTypeEnd ? 10 : 0, "end_right", path);
|
|
233
|
-
x = pos.x;
|
|
234
|
-
y = pos.y;
|
|
235
|
-
}
|
|
236
|
-
el.attr("transform", `translate(${x}, ${y})`);
|
|
237
|
-
}
|
|
238
|
-
}, "positionEdgeLabel");
|
|
239
|
-
var outsideNode = /* @__PURE__ */ __name((node, point2) => {
|
|
240
|
-
const x = node.x;
|
|
241
|
-
const y = node.y;
|
|
242
|
-
const dx = Math.abs(point2.x - x);
|
|
243
|
-
const dy = Math.abs(point2.y - y);
|
|
244
|
-
const w = node.width / 2;
|
|
245
|
-
const h = node.height / 2;
|
|
246
|
-
return dx >= w || dy >= h;
|
|
247
|
-
}, "outsideNode");
|
|
248
|
-
var intersection = /* @__PURE__ */ __name((node, outsidePoint, insidePoint) => {
|
|
249
|
-
log.debug(`intersection calc abc89:
|
|
250
|
-
outsidePoint: ${JSON.stringify(outsidePoint)}
|
|
251
|
-
insidePoint : ${JSON.stringify(insidePoint)}
|
|
252
|
-
node : x:${node.x} y:${node.y} w:${node.width} h:${node.height}`);
|
|
253
|
-
const x = node.x;
|
|
254
|
-
const y = node.y;
|
|
255
|
-
const dx = Math.abs(x - insidePoint.x);
|
|
256
|
-
const w = node.width / 2;
|
|
257
|
-
let r = insidePoint.x < outsidePoint.x ? w - dx : w + dx;
|
|
258
|
-
const h = node.height / 2;
|
|
259
|
-
const Q = Math.abs(outsidePoint.y - insidePoint.y);
|
|
260
|
-
const R = Math.abs(outsidePoint.x - insidePoint.x);
|
|
261
|
-
if (Math.abs(y - outsidePoint.y) * w > Math.abs(x - outsidePoint.x) * h) {
|
|
262
|
-
let q = insidePoint.y < outsidePoint.y ? outsidePoint.y - h - y : y - h - outsidePoint.y;
|
|
263
|
-
r = R * q / Q;
|
|
264
|
-
const res = {
|
|
265
|
-
x: insidePoint.x < outsidePoint.x ? insidePoint.x + r : insidePoint.x - R + r,
|
|
266
|
-
y: insidePoint.y < outsidePoint.y ? insidePoint.y + Q - q : insidePoint.y - Q + q
|
|
267
|
-
};
|
|
268
|
-
if (r === 0) {
|
|
269
|
-
res.x = outsidePoint.x;
|
|
270
|
-
res.y = outsidePoint.y;
|
|
271
|
-
}
|
|
272
|
-
if (R === 0) {
|
|
273
|
-
res.x = outsidePoint.x;
|
|
274
|
-
}
|
|
275
|
-
if (Q === 0) {
|
|
276
|
-
res.y = outsidePoint.y;
|
|
277
|
-
}
|
|
278
|
-
log.debug(`abc89 top/bottom calc, Q ${Q}, q ${q}, R ${R}, r ${r}`, res);
|
|
279
|
-
return res;
|
|
280
|
-
} else {
|
|
281
|
-
if (insidePoint.x < outsidePoint.x) {
|
|
282
|
-
r = outsidePoint.x - w - x;
|
|
283
|
-
} else {
|
|
284
|
-
r = x - w - outsidePoint.x;
|
|
285
|
-
}
|
|
286
|
-
let q = Q * r / R;
|
|
287
|
-
let _x = insidePoint.x < outsidePoint.x ? insidePoint.x + R - r : insidePoint.x - R + r;
|
|
288
|
-
let _y = insidePoint.y < outsidePoint.y ? insidePoint.y + q : insidePoint.y - q;
|
|
289
|
-
log.debug(`sides calc abc89, Q ${Q}, q ${q}, R ${R}, r ${r}`, { _x, _y });
|
|
290
|
-
if (r === 0) {
|
|
291
|
-
_x = outsidePoint.x;
|
|
292
|
-
_y = outsidePoint.y;
|
|
293
|
-
}
|
|
294
|
-
if (R === 0) {
|
|
295
|
-
_x = outsidePoint.x;
|
|
296
|
-
}
|
|
297
|
-
if (Q === 0) {
|
|
298
|
-
_y = outsidePoint.y;
|
|
299
|
-
}
|
|
300
|
-
return { x: _x, y: _y };
|
|
301
|
-
}
|
|
302
|
-
}, "intersection");
|
|
303
|
-
var cutPathAtIntersect = /* @__PURE__ */ __name((_points, boundaryNode) => {
|
|
304
|
-
log.warn("abc88 cutPathAtIntersect", _points, boundaryNode);
|
|
305
|
-
let points = [];
|
|
306
|
-
let lastPointOutside = _points[0];
|
|
307
|
-
let isInside = false;
|
|
308
|
-
_points.forEach((point2) => {
|
|
309
|
-
log.info("abc88 checking point", point2, boundaryNode);
|
|
310
|
-
if (!outsideNode(boundaryNode, point2) && !isInside) {
|
|
311
|
-
const inter = intersection(boundaryNode, lastPointOutside, point2);
|
|
312
|
-
log.debug("abc88 inside", point2, lastPointOutside, inter);
|
|
313
|
-
log.debug("abc88 intersection", inter, boundaryNode);
|
|
314
|
-
let pointPresent = false;
|
|
315
|
-
points.forEach((p) => {
|
|
316
|
-
pointPresent = pointPresent || p.x === inter.x && p.y === inter.y;
|
|
317
|
-
});
|
|
318
|
-
if (!points.some((e) => e.x === inter.x && e.y === inter.y)) {
|
|
319
|
-
points.push(inter);
|
|
320
|
-
} else {
|
|
321
|
-
log.warn("abc88 no intersect", inter, points);
|
|
322
|
-
}
|
|
323
|
-
isInside = true;
|
|
324
|
-
} else {
|
|
325
|
-
log.warn("abc88 outside", point2, lastPointOutside);
|
|
326
|
-
lastPointOutside = point2;
|
|
327
|
-
if (!isInside) {
|
|
328
|
-
points.push(point2);
|
|
329
|
-
}
|
|
330
|
-
}
|
|
331
|
-
});
|
|
332
|
-
log.debug("returning points", points);
|
|
333
|
-
return points;
|
|
334
|
-
}, "cutPathAtIntersect");
|
|
335
|
-
function extractCornerPoints(points) {
|
|
336
|
-
const cornerPoints = [];
|
|
337
|
-
const cornerPointPositions = [];
|
|
338
|
-
for (let i = 1; i < points.length - 1; i++) {
|
|
339
|
-
const prev = points[i - 1];
|
|
340
|
-
const curr = points[i];
|
|
341
|
-
const next = points[i + 1];
|
|
342
|
-
if (prev.x === curr.x && curr.y === next.y && Math.abs(curr.x - next.x) > 5 && Math.abs(curr.y - prev.y) > 5) {
|
|
343
|
-
cornerPoints.push(curr);
|
|
344
|
-
cornerPointPositions.push(i);
|
|
345
|
-
} else if (prev.y === curr.y && curr.x === next.x && Math.abs(curr.x - prev.x) > 5 && Math.abs(curr.y - next.y) > 5) {
|
|
346
|
-
cornerPoints.push(curr);
|
|
347
|
-
cornerPointPositions.push(i);
|
|
348
|
-
}
|
|
349
|
-
}
|
|
350
|
-
return { cornerPoints, cornerPointPositions };
|
|
351
|
-
}
|
|
352
|
-
__name(extractCornerPoints, "extractCornerPoints");
|
|
353
|
-
var findAdjacentPoint = /* @__PURE__ */ __name(function(pointA, pointB, distance) {
|
|
354
|
-
const xDiff = pointB.x - pointA.x;
|
|
355
|
-
const yDiff = pointB.y - pointA.y;
|
|
356
|
-
const length = Math.sqrt(xDiff * xDiff + yDiff * yDiff);
|
|
357
|
-
const ratio = distance / length;
|
|
358
|
-
return { x: pointB.x - ratio * xDiff, y: pointB.y - ratio * yDiff };
|
|
359
|
-
}, "findAdjacentPoint");
|
|
360
|
-
var fixCorners = /* @__PURE__ */ __name(function(lineData) {
|
|
361
|
-
const { cornerPointPositions } = extractCornerPoints(lineData);
|
|
362
|
-
const newLineData = [];
|
|
363
|
-
for (let i = 0; i < lineData.length; i++) {
|
|
364
|
-
if (cornerPointPositions.includes(i)) {
|
|
365
|
-
const prevPoint = lineData[i - 1];
|
|
366
|
-
const nextPoint = lineData[i + 1];
|
|
367
|
-
const cornerPoint = lineData[i];
|
|
368
|
-
const newPrevPoint = findAdjacentPoint(prevPoint, cornerPoint, 5);
|
|
369
|
-
const newNextPoint = findAdjacentPoint(nextPoint, cornerPoint, 5);
|
|
370
|
-
const xDiff = newNextPoint.x - newPrevPoint.x;
|
|
371
|
-
const yDiff = newNextPoint.y - newPrevPoint.y;
|
|
372
|
-
newLineData.push(newPrevPoint);
|
|
373
|
-
const a = Math.sqrt(2) * 2;
|
|
374
|
-
let newCornerPoint = { x: cornerPoint.x, y: cornerPoint.y };
|
|
375
|
-
if (Math.abs(nextPoint.x - prevPoint.x) > 10 && Math.abs(nextPoint.y - prevPoint.y) >= 10) {
|
|
376
|
-
log.debug(
|
|
377
|
-
"Corner point fixing",
|
|
378
|
-
Math.abs(nextPoint.x - prevPoint.x),
|
|
379
|
-
Math.abs(nextPoint.y - prevPoint.y)
|
|
380
|
-
);
|
|
381
|
-
const r = 5;
|
|
382
|
-
if (cornerPoint.x === newPrevPoint.x) {
|
|
383
|
-
newCornerPoint = {
|
|
384
|
-
x: xDiff < 0 ? newPrevPoint.x - r + a : newPrevPoint.x + r - a,
|
|
385
|
-
y: yDiff < 0 ? newPrevPoint.y - a : newPrevPoint.y + a
|
|
386
|
-
};
|
|
387
|
-
} else {
|
|
388
|
-
newCornerPoint = {
|
|
389
|
-
x: xDiff < 0 ? newPrevPoint.x - a : newPrevPoint.x + a,
|
|
390
|
-
y: yDiff < 0 ? newPrevPoint.y - r + a : newPrevPoint.y + r - a
|
|
391
|
-
};
|
|
392
|
-
}
|
|
393
|
-
} else {
|
|
394
|
-
log.debug(
|
|
395
|
-
"Corner point skipping fixing",
|
|
396
|
-
Math.abs(nextPoint.x - prevPoint.x),
|
|
397
|
-
Math.abs(nextPoint.y - prevPoint.y)
|
|
398
|
-
);
|
|
399
|
-
}
|
|
400
|
-
newLineData.push(newCornerPoint, newNextPoint);
|
|
401
|
-
} else {
|
|
402
|
-
newLineData.push(lineData[i]);
|
|
403
|
-
}
|
|
404
|
-
}
|
|
405
|
-
return newLineData;
|
|
406
|
-
}, "fixCorners");
|
|
407
|
-
var insertEdge = /* @__PURE__ */ __name(function(elem, edge, clusterDb, diagramType, startNode, endNode, id) {
|
|
408
|
-
const { handDrawnSeed } = getConfig2();
|
|
409
|
-
let points = edge.points;
|
|
410
|
-
let pointsHasChanged = false;
|
|
411
|
-
const tail = startNode;
|
|
412
|
-
var head = endNode;
|
|
413
|
-
if (head.intersect && tail.intersect) {
|
|
414
|
-
points = points.slice(1, edge.points.length - 1);
|
|
415
|
-
points.unshift(tail.intersect(points[0]));
|
|
416
|
-
log.debug(
|
|
417
|
-
"Last point APA12",
|
|
418
|
-
edge.start,
|
|
419
|
-
"-->",
|
|
420
|
-
edge.end,
|
|
421
|
-
points[points.length - 1],
|
|
422
|
-
head,
|
|
423
|
-
head.intersect(points[points.length - 1])
|
|
424
|
-
);
|
|
425
|
-
points.push(head.intersect(points[points.length - 1]));
|
|
426
|
-
}
|
|
427
|
-
if (edge.toCluster) {
|
|
428
|
-
log.info("to cluster abc88", clusterDb.get(edge.toCluster));
|
|
429
|
-
points = cutPathAtIntersect(edge.points, clusterDb.get(edge.toCluster).node);
|
|
430
|
-
pointsHasChanged = true;
|
|
431
|
-
}
|
|
432
|
-
if (edge.fromCluster) {
|
|
433
|
-
log.debug(
|
|
434
|
-
"from cluster abc88",
|
|
435
|
-
clusterDb.get(edge.fromCluster),
|
|
436
|
-
JSON.stringify(points, null, 2)
|
|
437
|
-
);
|
|
438
|
-
points = cutPathAtIntersect(points.reverse(), clusterDb.get(edge.fromCluster).node).reverse();
|
|
439
|
-
pointsHasChanged = true;
|
|
440
|
-
}
|
|
441
|
-
let lineData = points.filter((p) => !Number.isNaN(p.y));
|
|
442
|
-
lineData = fixCorners(lineData);
|
|
443
|
-
let curve = basis_default;
|
|
444
|
-
if (edge.curve) {
|
|
445
|
-
curve = edge.curve;
|
|
446
|
-
}
|
|
447
|
-
const { x, y } = getLineFunctionsWithOffset(edge);
|
|
448
|
-
const lineFunction = line_default().x(x).y(y).curve(curve);
|
|
449
|
-
let strokeClasses;
|
|
450
|
-
switch (edge.thickness) {
|
|
451
|
-
case "normal":
|
|
452
|
-
strokeClasses = "edge-thickness-normal";
|
|
453
|
-
break;
|
|
454
|
-
case "thick":
|
|
455
|
-
strokeClasses = "edge-thickness-thick";
|
|
456
|
-
break;
|
|
457
|
-
case "invisible":
|
|
458
|
-
strokeClasses = "edge-thickness-invisible";
|
|
459
|
-
break;
|
|
460
|
-
default:
|
|
461
|
-
strokeClasses = "edge-thickness-normal";
|
|
462
|
-
}
|
|
463
|
-
switch (edge.pattern) {
|
|
464
|
-
case "solid":
|
|
465
|
-
strokeClasses += " edge-pattern-solid";
|
|
466
|
-
break;
|
|
467
|
-
case "dotted":
|
|
468
|
-
strokeClasses += " edge-pattern-dotted";
|
|
469
|
-
break;
|
|
470
|
-
case "dashed":
|
|
471
|
-
strokeClasses += " edge-pattern-dashed";
|
|
472
|
-
break;
|
|
473
|
-
default:
|
|
474
|
-
strokeClasses += " edge-pattern-solid";
|
|
475
|
-
}
|
|
476
|
-
let svgPath;
|
|
477
|
-
let linePath = lineFunction(lineData);
|
|
478
|
-
const edgeStyles = Array.isArray(edge.style) ? edge.style : [edge.style];
|
|
479
|
-
if (edge.look === "handDrawn") {
|
|
480
|
-
const rc = at.svg(elem);
|
|
481
|
-
Object.assign([], lineData);
|
|
482
|
-
const svgPathNode = rc.path(linePath, {
|
|
483
|
-
roughness: 0.3,
|
|
484
|
-
seed: handDrawnSeed
|
|
485
|
-
});
|
|
486
|
-
strokeClasses += " transition";
|
|
487
|
-
svgPath = select_default(svgPathNode).select("path").attr("id", edge.id).attr("class", " " + strokeClasses + (edge.classes ? " " + edge.classes : "")).attr("style", edgeStyles ? edgeStyles.reduce((acc, style) => acc + ";" + style, "") : "");
|
|
488
|
-
let d = svgPath.attr("d");
|
|
489
|
-
svgPath.attr("d", d);
|
|
490
|
-
elem.node().appendChild(svgPath.node());
|
|
491
|
-
} else {
|
|
492
|
-
svgPath = elem.append("path").attr("d", linePath).attr("id", edge.id).attr("class", " " + strokeClasses + (edge.classes ? " " + edge.classes : "")).attr("style", edgeStyles ? edgeStyles.reduce((acc, style) => acc + ";" + style, "") : "");
|
|
493
|
-
}
|
|
494
|
-
let url = "";
|
|
495
|
-
if (getConfig2().flowchart.arrowMarkerAbsolute || getConfig2().state.arrowMarkerAbsolute) {
|
|
496
|
-
url = window.location.protocol + "//" + window.location.host + window.location.pathname + window.location.search;
|
|
497
|
-
url = url.replace(/\(/g, "\\(").replace(/\)/g, "\\)");
|
|
498
|
-
}
|
|
499
|
-
log.info("arrowTypeStart", edge.arrowTypeStart);
|
|
500
|
-
log.info("arrowTypeEnd", edge.arrowTypeEnd);
|
|
501
|
-
addEdgeMarkers(svgPath, edge, url, id, diagramType);
|
|
502
|
-
let paths = {};
|
|
503
|
-
if (pointsHasChanged) {
|
|
504
|
-
paths.updatedPath = points;
|
|
505
|
-
}
|
|
506
|
-
paths.originalPath = edge.points;
|
|
507
|
-
return paths;
|
|
508
|
-
}, "insertEdge");
|
|
509
|
-
var insertMarkers = /* @__PURE__ */ __name((elem, markerArray, type, id) => {
|
|
510
|
-
markerArray.forEach((markerName) => {
|
|
511
|
-
markers[markerName](elem, type, id);
|
|
512
|
-
});
|
|
513
|
-
}, "insertMarkers");
|
|
514
|
-
var extension = /* @__PURE__ */ __name((elem, type, id) => {
|
|
515
|
-
log.trace("Making markers for ", id);
|
|
516
|
-
elem.append("defs").append("marker").attr("id", id + "_" + type + "-extensionStart").attr("class", "marker extension " + type).attr("refX", 18).attr("refY", 7).attr("markerWidth", 190).attr("markerHeight", 240).attr("orient", "auto").append("path").attr("d", "M 1,7 L18,13 V 1 Z");
|
|
517
|
-
elem.append("defs").append("marker").attr("id", id + "_" + type + "-extensionEnd").attr("class", "marker extension " + type).attr("refX", 1).attr("refY", 7).attr("markerWidth", 20).attr("markerHeight", 28).attr("orient", "auto").append("path").attr("d", "M 1,1 V 13 L18,7 Z");
|
|
518
|
-
}, "extension");
|
|
519
|
-
var composition = /* @__PURE__ */ __name((elem, type, id) => {
|
|
520
|
-
elem.append("defs").append("marker").attr("id", id + "_" + type + "-compositionStart").attr("class", "marker composition " + type).attr("refX", 18).attr("refY", 7).attr("markerWidth", 190).attr("markerHeight", 240).attr("orient", "auto").append("path").attr("d", "M 18,7 L9,13 L1,7 L9,1 Z");
|
|
521
|
-
elem.append("defs").append("marker").attr("id", id + "_" + type + "-compositionEnd").attr("class", "marker composition " + type).attr("refX", 1).attr("refY", 7).attr("markerWidth", 20).attr("markerHeight", 28).attr("orient", "auto").append("path").attr("d", "M 18,7 L9,13 L1,7 L9,1 Z");
|
|
522
|
-
}, "composition");
|
|
523
|
-
var aggregation = /* @__PURE__ */ __name((elem, type, id) => {
|
|
524
|
-
elem.append("defs").append("marker").attr("id", id + "_" + type + "-aggregationStart").attr("class", "marker aggregation " + type).attr("refX", 18).attr("refY", 7).attr("markerWidth", 190).attr("markerHeight", 240).attr("orient", "auto").append("path").attr("d", "M 18,7 L9,13 L1,7 L9,1 Z");
|
|
525
|
-
elem.append("defs").append("marker").attr("id", id + "_" + type + "-aggregationEnd").attr("class", "marker aggregation " + type).attr("refX", 1).attr("refY", 7).attr("markerWidth", 20).attr("markerHeight", 28).attr("orient", "auto").append("path").attr("d", "M 18,7 L9,13 L1,7 L9,1 Z");
|
|
526
|
-
}, "aggregation");
|
|
527
|
-
var dependency = /* @__PURE__ */ __name((elem, type, id) => {
|
|
528
|
-
elem.append("defs").append("marker").attr("id", id + "_" + type + "-dependencyStart").attr("class", "marker dependency " + type).attr("refX", 6).attr("refY", 7).attr("markerWidth", 190).attr("markerHeight", 240).attr("orient", "auto").append("path").attr("d", "M 5,7 L9,13 L1,7 L9,1 Z");
|
|
529
|
-
elem.append("defs").append("marker").attr("id", id + "_" + type + "-dependencyEnd").attr("class", "marker dependency " + type).attr("refX", 13).attr("refY", 7).attr("markerWidth", 20).attr("markerHeight", 28).attr("orient", "auto").append("path").attr("d", "M 18,7 L9,13 L14,7 L9,1 Z");
|
|
530
|
-
}, "dependency");
|
|
531
|
-
var lollipop = /* @__PURE__ */ __name((elem, type, id) => {
|
|
532
|
-
elem.append("defs").append("marker").attr("id", id + "_" + type + "-lollipopStart").attr("class", "marker lollipop " + type).attr("refX", 13).attr("refY", 7).attr("markerWidth", 190).attr("markerHeight", 240).attr("orient", "auto").append("circle").attr("stroke", "black").attr("fill", "transparent").attr("cx", 7).attr("cy", 7).attr("r", 6);
|
|
533
|
-
elem.append("defs").append("marker").attr("id", id + "_" + type + "-lollipopEnd").attr("class", "marker lollipop " + type).attr("refX", 1).attr("refY", 7).attr("markerWidth", 190).attr("markerHeight", 240).attr("orient", "auto").append("circle").attr("stroke", "black").attr("fill", "transparent").attr("cx", 7).attr("cy", 7).attr("r", 6);
|
|
534
|
-
}, "lollipop");
|
|
535
|
-
var point = /* @__PURE__ */ __name((elem, type, id) => {
|
|
536
|
-
elem.append("marker").attr("id", id + "_" + type + "-pointEnd").attr("class", "marker " + type).attr("viewBox", "0 0 10 10").attr("refX", 5).attr("refY", 5).attr("markerUnits", "userSpaceOnUse").attr("markerWidth", 8).attr("markerHeight", 8).attr("orient", "auto").append("path").attr("d", "M 0 0 L 10 5 L 0 10 z").attr("class", "arrowMarkerPath").style("stroke-width", 1).style("stroke-dasharray", "1,0");
|
|
537
|
-
elem.append("marker").attr("id", id + "_" + type + "-pointStart").attr("class", "marker " + type).attr("viewBox", "0 0 10 10").attr("refX", 4.5).attr("refY", 5).attr("markerUnits", "userSpaceOnUse").attr("markerWidth", 8).attr("markerHeight", 8).attr("orient", "auto").append("path").attr("d", "M 0 5 L 10 10 L 10 0 z").attr("class", "arrowMarkerPath").style("stroke-width", 1).style("stroke-dasharray", "1,0");
|
|
538
|
-
}, "point");
|
|
539
|
-
var circle = /* @__PURE__ */ __name((elem, type, id) => {
|
|
540
|
-
elem.append("marker").attr("id", id + "_" + type + "-circleEnd").attr("class", "marker " + type).attr("viewBox", "0 0 10 10").attr("refX", 11).attr("refY", 5).attr("markerUnits", "userSpaceOnUse").attr("markerWidth", 11).attr("markerHeight", 11).attr("orient", "auto").append("circle").attr("cx", "5").attr("cy", "5").attr("r", "5").attr("class", "arrowMarkerPath").style("stroke-width", 1).style("stroke-dasharray", "1,0");
|
|
541
|
-
elem.append("marker").attr("id", id + "_" + type + "-circleStart").attr("class", "marker " + type).attr("viewBox", "0 0 10 10").attr("refX", -1).attr("refY", 5).attr("markerUnits", "userSpaceOnUse").attr("markerWidth", 11).attr("markerHeight", 11).attr("orient", "auto").append("circle").attr("cx", "5").attr("cy", "5").attr("r", "5").attr("class", "arrowMarkerPath").style("stroke-width", 1).style("stroke-dasharray", "1,0");
|
|
542
|
-
}, "circle");
|
|
543
|
-
var cross = /* @__PURE__ */ __name((elem, type, id) => {
|
|
544
|
-
elem.append("marker").attr("id", id + "_" + type + "-crossEnd").attr("class", "marker cross " + type).attr("viewBox", "0 0 11 11").attr("refX", 12).attr("refY", 5.2).attr("markerUnits", "userSpaceOnUse").attr("markerWidth", 11).attr("markerHeight", 11).attr("orient", "auto").append("path").attr("d", "M 1,1 l 9,9 M 10,1 l -9,9").attr("class", "arrowMarkerPath").style("stroke-width", 2).style("stroke-dasharray", "1,0");
|
|
545
|
-
elem.append("marker").attr("id", id + "_" + type + "-crossStart").attr("class", "marker cross " + type).attr("viewBox", "0 0 11 11").attr("refX", -1).attr("refY", 5.2).attr("markerUnits", "userSpaceOnUse").attr("markerWidth", 11).attr("markerHeight", 11).attr("orient", "auto").append("path").attr("d", "M 1,1 l 9,9 M 10,1 l -9,9").attr("class", "arrowMarkerPath").style("stroke-width", 2).style("stroke-dasharray", "1,0");
|
|
546
|
-
}, "cross");
|
|
547
|
-
var barb = /* @__PURE__ */ __name((elem, type, id) => {
|
|
548
|
-
elem.append("defs").append("marker").attr("id", id + "_" + type + "-barbEnd").attr("refX", 19).attr("refY", 7).attr("markerWidth", 20).attr("markerHeight", 14).attr("markerUnits", "userSpaceOnUse").attr("orient", "auto").append("path").attr("d", "M 19,7 L9,13 L14,7 L9,1 Z");
|
|
549
|
-
}, "barb");
|
|
550
|
-
var markers = {
|
|
551
|
-
extension,
|
|
552
|
-
composition,
|
|
553
|
-
aggregation,
|
|
554
|
-
dependency,
|
|
555
|
-
lollipop,
|
|
556
|
-
point,
|
|
557
|
-
circle,
|
|
558
|
-
cross,
|
|
559
|
-
barb
|
|
560
|
-
};
|
|
561
|
-
var markers_default = insertMarkers;
|
|
562
|
-
|
|
563
|
-
export {
|
|
564
|
-
clear,
|
|
565
|
-
insertEdgeLabel,
|
|
566
|
-
positionEdgeLabel,
|
|
567
|
-
insertEdge,
|
|
568
|
-
markers_default
|
|
569
|
-
};
|
|
570
|
-
//# sourceMappingURL=chunk-ND3FLKHU.js.map
|