lowcoder-comps 0.0.20 → 0.0.22
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/029c585a.js +825 -0
- package/0f49842f.js +915 -0
- package/14c95def.js +2396 -0
- package/{5a7c40d7.js → 14de54b2.js} +7120 -6939
- package/17b0984b.js +1116 -0
- package/{a1f987b7.js → 1a4b39ab.js} +29 -30
- package/1e35aee7.js +932 -0
- package/{804e952b.js → 1f97d569.js} +73 -76
- package/3120eee5.js +1235 -0
- package/313e94fb.js +796 -0
- package/{384b70d4.js → 41a4677f.js} +10 -12
- package/{e1466a22.js → 48a69d01.js} +89 -97
- package/4a8006fe.js +2501 -0
- package/{a06ced05.js → 585231df.js} +64 -71
- package/5e96f5d8.js +64 -0
- package/5f9be850.js +1055 -0
- package/{3196b84f.js → 6e0c66a6.js} +97 -109
- package/76d315c1.js +2192 -0
- package/{31c6e136.js → 867cdd47.js} +1 -1
- package/{0d5d7030.js → 8a65542f.js} +58 -64
- package/913e1a65.js +804 -0
- package/92e85b65.js +65 -0
- package/97298a99.js +2966 -0
- package/{5fd0f607.js → a396e61e.js} +44 -44
- package/a6d42292.js +1284 -0
- package/afd2e4d5.js +86 -0
- package/be5f3226.js +768 -0
- package/{4791bdd6.js → bf75928a.js} +30142 -30663
- package/{011ccb4a.js → bfd01456.js} +4257 -4221
- package/c239ec69.js +1000 -0
- package/e731f493.js +502 -0
- package/ef3524ce.js +960 -0
- package/f5b4a4bc.js +365 -0
- package/{8d714103.js → fa29410e.js} +598 -622
- package/fbc7bdd4.js +218 -0
- package/index.js +2 -2
- package/package.json +2 -2
- package/01102044.js +0 -940
- package/0e8dfd52.js +0 -793
- package/0f25771b.js +0 -1118
- package/2470e1d8.js +0 -91
- package/32432dc3.js +0 -86
- package/36552e14.js +0 -849
- package/3ad35722.js +0 -365
- package/3f4db197.js +0 -943
- package/71827e37.js +0 -1032
- package/7a200c6a.js +0 -607
- package/872f2918.js +0 -7
- package/93b98f3e.js +0 -832
- package/a42a2ba9.js +0 -2103
- package/af0489f3.js +0 -2456
- package/b56f953d.js +0 -985
- package/b89c6a6a.js +0 -159
- package/bc7030d3.js +0 -70
- package/c739ba3e.js +0 -2679
- package/d306d59c.js +0 -2827
- package/d8adcd1e.js +0 -823
- package/ef845d7f.js +0 -1246
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var
|
|
1
|
+
var D = (e, l, s) => new Promise((a, i) => {
|
|
2
2
|
var p = (c) => {
|
|
3
3
|
try {
|
|
4
4
|
o(s.next(c));
|
|
@@ -14,23 +14,24 @@ var I = (e, l, s) => new Promise((a, i) => {
|
|
|
14
14
|
}, o = (c) => c.done ? a(c.value) : Promise.resolve(c.value).then(p, f);
|
|
15
15
|
o((s = s.apply(e, l)).next());
|
|
16
16
|
});
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
17
|
+
import { G as M } from "./14c95def.js";
|
|
18
|
+
import { S as z, u as R, v as F, _ as j, C as U, x as H, y as W, o as A, l as y, p as X, c as C, j as G, q as $, n as E, h as _, z as J, r as K, A as Q } from "./bf75928a.js";
|
|
19
|
+
import { r as Y } from "./f5b4a4bc.js";
|
|
20
|
+
function Z(e) {
|
|
21
|
+
return typeof e == "string" ? new z([document.querySelectorAll(e)], [document.documentElement]) : new z([F(e)], R);
|
|
22
|
+
}
|
|
23
|
+
const O = (e, l) => j.lang.round(U.parse(e)[l]), ee = O;
|
|
23
24
|
function ue(e, l) {
|
|
24
25
|
return !!e.children(l).length;
|
|
25
26
|
}
|
|
26
27
|
function we(e) {
|
|
27
28
|
return L(e.v) + ":" + L(e.w) + ":" + L(e.name);
|
|
28
29
|
}
|
|
29
|
-
var
|
|
30
|
+
var te = /:/g;
|
|
30
31
|
function L(e) {
|
|
31
|
-
return e ? String(e).replace(
|
|
32
|
+
return e ? String(e).replace(te, "\\:") : "";
|
|
32
33
|
}
|
|
33
|
-
function
|
|
34
|
+
function re(e, l) {
|
|
34
35
|
l && e.attr("style", l);
|
|
35
36
|
}
|
|
36
37
|
function he(e, l, s) {
|
|
@@ -38,14 +39,14 @@ function he(e, l, s) {
|
|
|
38
39
|
}
|
|
39
40
|
function ye(e, l) {
|
|
40
41
|
var s = l.graph();
|
|
41
|
-
if (
|
|
42
|
+
if (H(s)) {
|
|
42
43
|
var a = s.transition;
|
|
43
|
-
if (
|
|
44
|
+
if (W(a))
|
|
44
45
|
return a(e);
|
|
45
46
|
}
|
|
46
47
|
return e;
|
|
47
48
|
}
|
|
48
|
-
function
|
|
49
|
+
function le(e, l) {
|
|
49
50
|
var s = e.append("foreignObject").attr("width", "100000"), a = s.append("xhtml:div");
|
|
50
51
|
a.attr("xmlns", "http://www.w3.org/1999/xhtml");
|
|
51
52
|
var i = l.label;
|
|
@@ -61,35 +62,35 @@ function te(e, l) {
|
|
|
61
62
|
default:
|
|
62
63
|
a.html(i);
|
|
63
64
|
}
|
|
64
|
-
|
|
65
|
+
re(a, l.labelStyle), a.style("display", "inline-block"), a.style("white-space", "nowrap");
|
|
65
66
|
var p = a.node().getBoundingClientRect();
|
|
66
67
|
return s.attr("width", p.width).attr("height", p.height), s;
|
|
67
68
|
}
|
|
68
|
-
const
|
|
69
|
+
const q = {}, ae = function(e) {
|
|
69
70
|
const l = Object.keys(e);
|
|
70
71
|
for (const s of l)
|
|
71
|
-
|
|
72
|
+
q[s] = e[s];
|
|
72
73
|
}, P = function(e, l, s, a, i, p) {
|
|
73
74
|
const f = a.select(`[id="${s}"]`);
|
|
74
75
|
Object.keys(e).forEach(function(c) {
|
|
75
76
|
const r = e[c];
|
|
76
77
|
let g = "default";
|
|
77
78
|
r.classes.length > 0 && (g = r.classes.join(" ")), g = g + " flowchart-label";
|
|
78
|
-
const
|
|
79
|
+
const w = A(r.styles);
|
|
79
80
|
let t = r.text !== void 0 ? r.text : r.id, d;
|
|
80
|
-
if (
|
|
81
|
-
|
|
82
|
-
else if (
|
|
81
|
+
if (y.info("vertex", r, r.labelType), r.labelType === "markdown")
|
|
82
|
+
y.info("vertex", r, r.labelType);
|
|
83
|
+
else if (X(C().flowchart.htmlLabels)) {
|
|
83
84
|
const m = {
|
|
84
85
|
label: t.replace(
|
|
85
86
|
/fa[blrs]?:fa-[\w-]+/g,
|
|
86
87
|
(k) => `<i class='${k.replace(":", " ")}'></i>`
|
|
87
88
|
)
|
|
88
89
|
};
|
|
89
|
-
d =
|
|
90
|
+
d = le(f, m).node(), d.parentNode.removeChild(d);
|
|
90
91
|
} else {
|
|
91
92
|
const m = i.createElementNS("http://www.w3.org/2000/svg", "text");
|
|
92
|
-
m.setAttribute("style",
|
|
93
|
+
m.setAttribute("style", w.labelStyle.replace("color:", "fill:"));
|
|
93
94
|
const k = t.split(G.lineBreakRegex);
|
|
94
95
|
for (const T of k) {
|
|
95
96
|
const v = i.createElementNS("http://www.w3.org/2000/svg", "tspan");
|
|
@@ -154,14 +155,14 @@ const z = {}, re = function(e) {
|
|
|
154
155
|
n = "rect";
|
|
155
156
|
}
|
|
156
157
|
l.setNode(r.id, {
|
|
157
|
-
labelStyle:
|
|
158
|
+
labelStyle: w.labelStyle,
|
|
158
159
|
shape: n,
|
|
159
160
|
labelText: t,
|
|
160
161
|
labelType: r.labelType,
|
|
161
162
|
rx: b,
|
|
162
163
|
ry: b,
|
|
163
164
|
class: g,
|
|
164
|
-
style:
|
|
165
|
+
style: w.style,
|
|
165
166
|
id: r.id,
|
|
166
167
|
link: r.link,
|
|
167
168
|
linkTarget: r.linkTarget,
|
|
@@ -173,15 +174,15 @@ const z = {}, re = function(e) {
|
|
|
173
174
|
type: r.type,
|
|
174
175
|
props: r.props,
|
|
175
176
|
padding: C().flowchart.padding
|
|
176
|
-
}),
|
|
177
|
-
labelStyle:
|
|
177
|
+
}), y.info("setNode", {
|
|
178
|
+
labelStyle: w.labelStyle,
|
|
178
179
|
labelType: r.labelType,
|
|
179
180
|
shape: n,
|
|
180
181
|
labelText: t,
|
|
181
182
|
rx: b,
|
|
182
183
|
ry: b,
|
|
183
184
|
class: g,
|
|
184
|
-
style:
|
|
185
|
+
style: w.style,
|
|
185
186
|
id: r.id,
|
|
186
187
|
domId: p.db.lookUpDomId(r.id),
|
|
187
188
|
width: r.type === "group" ? 500 : void 0,
|
|
@@ -192,19 +193,19 @@ const z = {}, re = function(e) {
|
|
|
192
193
|
});
|
|
193
194
|
});
|
|
194
195
|
}, V = function(e, l, s) {
|
|
195
|
-
|
|
196
|
+
y.info("abc78 edges = ", e);
|
|
196
197
|
let a = 0, i = {}, p, f;
|
|
197
198
|
if (e.defaultStyle !== void 0) {
|
|
198
|
-
const o =
|
|
199
|
+
const o = A(e.defaultStyle);
|
|
199
200
|
p = o.style, f = o.labelStyle;
|
|
200
201
|
}
|
|
201
202
|
e.forEach(function(o) {
|
|
202
203
|
a++;
|
|
203
204
|
const c = "L-" + o.start + "-" + o.end;
|
|
204
|
-
i[c] === void 0 ? (i[c] = 0,
|
|
205
|
+
i[c] === void 0 ? (i[c] = 0, y.info("abc78 new entry", c, i[c])) : (i[c]++, y.info("abc78 new entry", c, i[c]));
|
|
205
206
|
let r = c + "-" + i[c];
|
|
206
|
-
|
|
207
|
-
const g = "LS-" + o.start,
|
|
207
|
+
y.info("abc78 new link id to be used is", c, r, i[c]);
|
|
208
|
+
const g = "LS-" + o.start, w = "LE-" + o.end, t = { style: "", labelStyle: "" };
|
|
208
209
|
switch (t.minlen = o.length || 1, o.type === "arrow_open" ? t.arrowhead = "none" : t.arrowhead = "normal", t.arrowTypeStart = "arrow_open", t.arrowTypeEnd = "arrow_open", o.type) {
|
|
209
210
|
case "double_arrow_cross":
|
|
210
211
|
t.arrowTypeStart = "arrow_cross";
|
|
@@ -238,28 +239,23 @@ const z = {}, re = function(e) {
|
|
|
238
239
|
break;
|
|
239
240
|
}
|
|
240
241
|
if (o.style !== void 0) {
|
|
241
|
-
const n =
|
|
242
|
+
const n = A(o.style);
|
|
242
243
|
d = n.style, b = n.labelStyle;
|
|
243
244
|
}
|
|
244
|
-
t.style = t.style += d, t.labelStyle = t.labelStyle += b, o.interpolate !== void 0 ? t.curve = $(o.interpolate, E) : e.defaultInterpolate !== void 0 ? t.curve = $(e.defaultInterpolate, E) : t.curve = $(
|
|
245
|
-
`), o.style === void 0 && (t.style = t.style || "stroke: #333; stroke-width: 1.5px;fill:none;"), t.labelStyle = t.labelStyle.replace("color:", "fill:"), t.id = r, t.classes = "flowchart-link " + g + " " +
|
|
245
|
+
t.style = t.style += d, t.labelStyle = t.labelStyle += b, o.interpolate !== void 0 ? t.curve = $(o.interpolate, E) : e.defaultInterpolate !== void 0 ? t.curve = $(e.defaultInterpolate, E) : t.curve = $(q.curve, E), o.text === void 0 ? o.style !== void 0 && (t.arrowheadStyle = "fill: #333") : (t.arrowheadStyle = "fill: #333", t.labelpos = "c"), t.labelType = o.labelType, t.label = o.text.replace(G.lineBreakRegex, `
|
|
246
|
+
`), o.style === void 0 && (t.style = t.style || "stroke: #333; stroke-width: 1.5px;fill:none;"), t.labelStyle = t.labelStyle.replace("color:", "fill:"), t.id = r, t.classes = "flowchart-link " + g + " " + w, l.setEdge(o.start, o.end, t, a);
|
|
246
247
|
});
|
|
247
|
-
},
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
return;
|
|
253
|
-
}
|
|
254
|
-
}, ae = function(e, l, s, a) {
|
|
255
|
-
return I(this, null, function* () {
|
|
256
|
-
w.info("Drawing flowchart"), a.db.clear(), K.setGen("gen-2"), a.parser.parse(e);
|
|
248
|
+
}, oe = function(e, l) {
|
|
249
|
+
return l.db.getClasses();
|
|
250
|
+
}, ne = function(e, l, s, a) {
|
|
251
|
+
return D(this, null, function* () {
|
|
252
|
+
y.info("Drawing flowchart");
|
|
257
253
|
let i = a.db.getDirection();
|
|
258
254
|
i === void 0 && (i = "TD");
|
|
259
255
|
const { securityLevel: p, flowchart: f } = C(), o = f.nodeSpacing || 50, c = f.rankSpacing || 50;
|
|
260
256
|
let r;
|
|
261
257
|
p === "sandbox" && (r = _("#i" + l));
|
|
262
|
-
const g = p === "sandbox" ? _(r.nodes()[0].contentDocument.body) : _("body"),
|
|
258
|
+
const g = p === "sandbox" ? _(r.nodes()[0].contentDocument.body) : _("body"), w = p === "sandbox" ? r.nodes()[0].contentDocument : document, t = new M({
|
|
263
259
|
multigraph: !0,
|
|
264
260
|
compound: !0
|
|
265
261
|
}).setGraph({
|
|
@@ -273,9 +269,9 @@ const z = {}, re = function(e) {
|
|
|
273
269
|
});
|
|
274
270
|
let d;
|
|
275
271
|
const b = a.db.getSubGraphs();
|
|
276
|
-
|
|
272
|
+
y.info("Subgraphs - ", b);
|
|
277
273
|
for (let u = b.length - 1; u >= 0; u--)
|
|
278
|
-
d = b[u],
|
|
274
|
+
d = b[u], y.info("Subgraph - ", d), a.db.addVertex(
|
|
279
275
|
d.id,
|
|
280
276
|
{ text: d.title, type: d.labelType },
|
|
281
277
|
"group",
|
|
@@ -284,20 +280,20 @@ const z = {}, re = function(e) {
|
|
|
284
280
|
d.dir
|
|
285
281
|
);
|
|
286
282
|
const n = a.db.getVertices(), m = a.db.getEdges();
|
|
287
|
-
|
|
283
|
+
y.info("Edges", m);
|
|
288
284
|
let k = 0;
|
|
289
285
|
for (k = b.length - 1; k >= 0; k--) {
|
|
290
|
-
d = b[k],
|
|
286
|
+
d = b[k], Z("cluster").append("text");
|
|
291
287
|
for (let u = 0; u < d.nodes.length; u++)
|
|
292
|
-
|
|
288
|
+
y.info("Setting up subgraphs", d.nodes[u], d.id), t.setParent(d.nodes[u], d.id);
|
|
293
289
|
}
|
|
294
|
-
P(n, t, l, g,
|
|
290
|
+
P(n, t, l, g, w, a), V(m, t);
|
|
295
291
|
const T = g.select(`[id="${l}"]`), v = g.select("#" + l + " g");
|
|
296
|
-
if (yield
|
|
297
|
-
const u =
|
|
292
|
+
if (yield Y(v, t, ["point", "circle", "cross"], "flowchart", l), J.insertTitle(T, "flowchartTitleText", f.titleTopMargin, a.db.getDiagramTitle()), K(t, T, f.diagramPadding, f.useMaxWidth), a.db.indexNodes("subGraph" + k), !f.htmlLabels) {
|
|
293
|
+
const u = w.querySelectorAll('[id="' + l + '"] .edgeLabel .label');
|
|
298
294
|
for (const x of u) {
|
|
299
|
-
const S = x.getBBox(),
|
|
300
|
-
|
|
295
|
+
const S = x.getBBox(), h = w.createElementNS("http://www.w3.org/2000/svg", "rect");
|
|
296
|
+
h.setAttribute("rx", 0), h.setAttribute("ry", 0), h.setAttribute("width", S.width), h.setAttribute("height", S.height), x.insertBefore(h, x.firstChild);
|
|
301
297
|
}
|
|
302
298
|
}
|
|
303
299
|
Object.keys(n).forEach(function(u) {
|
|
@@ -305,32 +301,32 @@ const z = {}, re = function(e) {
|
|
|
305
301
|
if (x.link) {
|
|
306
302
|
const S = _("#" + l + ' [id="' + u + '"]');
|
|
307
303
|
if (S) {
|
|
308
|
-
const
|
|
309
|
-
|
|
310
|
-
const
|
|
311
|
-
return
|
|
304
|
+
const h = w.createElementNS("http://www.w3.org/2000/svg", "a");
|
|
305
|
+
h.setAttributeNS("http://www.w3.org/2000/svg", "class", x.classes.join(" ")), h.setAttributeNS("http://www.w3.org/2000/svg", "href", x.link), h.setAttributeNS("http://www.w3.org/2000/svg", "rel", "noopener"), p === "sandbox" ? h.setAttributeNS("http://www.w3.org/2000/svg", "target", "_top") : x.linkTarget && h.setAttributeNS("http://www.w3.org/2000/svg", "target", x.linkTarget);
|
|
306
|
+
const N = S.insert(function() {
|
|
307
|
+
return h;
|
|
312
308
|
}, ":first-child"), B = S.select(".label-container");
|
|
313
|
-
B &&
|
|
309
|
+
B && N.append(function() {
|
|
314
310
|
return B.node();
|
|
315
311
|
});
|
|
316
|
-
const
|
|
317
|
-
|
|
318
|
-
return
|
|
312
|
+
const I = S.select(".label");
|
|
313
|
+
I && N.append(function() {
|
|
314
|
+
return I.node();
|
|
319
315
|
});
|
|
320
316
|
}
|
|
321
317
|
}
|
|
322
318
|
});
|
|
323
319
|
});
|
|
324
320
|
}, ge = {
|
|
325
|
-
setConf:
|
|
321
|
+
setConf: ae,
|
|
326
322
|
addVertices: P,
|
|
327
323
|
addEdges: V,
|
|
328
|
-
getClasses:
|
|
329
|
-
draw:
|
|
330
|
-
},
|
|
331
|
-
const s =
|
|
332
|
-
return
|
|
333
|
-
},
|
|
324
|
+
getClasses: oe,
|
|
325
|
+
draw: ne
|
|
326
|
+
}, se = (e, l) => {
|
|
327
|
+
const s = ee, a = s(e, "r"), i = s(e, "g"), p = s(e, "b");
|
|
328
|
+
return Q(a, i, p, l);
|
|
329
|
+
}, ie = (e) => `.label {
|
|
334
330
|
font-family: ${e.fontFamily};
|
|
335
331
|
color: ${e.nodeTextColor || e.textColor};
|
|
336
332
|
}
|
|
@@ -398,7 +394,7 @@ const z = {}, re = function(e) {
|
|
|
398
394
|
|
|
399
395
|
/* For html labels only */
|
|
400
396
|
.labelBkg {
|
|
401
|
-
background-color: ${
|
|
397
|
+
background-color: ${se(e.edgeLabelBackground, 0.5)};
|
|
402
398
|
// background-color:
|
|
403
399
|
}
|
|
404
400
|
|
|
@@ -438,14 +434,15 @@ const z = {}, re = function(e) {
|
|
|
438
434
|
font-size: 18px;
|
|
439
435
|
fill: ${e.textColor};
|
|
440
436
|
}
|
|
441
|
-
`, ke =
|
|
437
|
+
`, ke = ie;
|
|
442
438
|
export {
|
|
443
|
-
|
|
444
|
-
|
|
439
|
+
re as a,
|
|
440
|
+
le as b,
|
|
445
441
|
ye as c,
|
|
446
442
|
he as d,
|
|
447
443
|
we as e,
|
|
448
444
|
ge as f,
|
|
449
445
|
ke as g,
|
|
450
|
-
ue as i
|
|
446
|
+
ue as i,
|
|
447
|
+
Z as s
|
|
451
448
|
};
|