lowcoder-comps 2.4.14 → 2.4.16

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.
Files changed (51) hide show
  1. package/{fc3b7856.js → 1043ea14.js} +247 -258
  2. package/{52a11357.js → 14530b4e.js} +5 -5
  3. package/{029476f8.js → 145794bd.js} +4 -4
  4. package/248f3eba.js +797 -0
  5. package/{e6f7d4a7.js → 28364e9c.js} +411 -451
  6. package/{a3820fc3.js → 38ec0f55.js} +3 -3
  7. package/{6296008d.js → 40bee586.js} +55069 -55754
  8. package/{256b619e.js → 428ebac9.js} +14 -15
  9. package/{21e8a932.js → 4407a5f9.js} +1 -1
  10. package/{286121b3.js → 474d7e5f.js} +6 -6
  11. package/{32d11caf.js → 48ca2a1e.js} +2 -2
  12. package/5b2c9b5c.js +206 -0
  13. package/{b42bc0a6.js → 633f4ede.js} +919 -969
  14. package/{35b2542e.js → 668d3da2.js} +1 -1
  15. package/{005a58c0.js → 78321d1a.js} +4 -4
  16. package/{2ea4f729.js → 7c479abc.js} +8 -8
  17. package/{09ab5d81.js → 7c7200e7.js} +7 -7
  18. package/{d42741f5.js → 7e6d090c.js} +1067 -1085
  19. package/7e78c333.js +373 -0
  20. package/{abadf1f6.js → 88415712.js} +140 -141
  21. package/{43254cb0.js → 8ae1f7a4.js} +4 -5
  22. package/{af28f5d5.js → 8e6be41e.js} +4 -4
  23. package/{a73a7fb8.js → 8ffe69e1.js} +6 -6
  24. package/{14a0be5d.js → 9afbfdff.js} +1 -1
  25. package/{25f232c1.js → a8987699.js} +6 -6
  26. package/afdeb8e9.js +190 -0
  27. package/c0405acc.js +1083 -0
  28. package/{08ea4a8f.js → ca993649.js} +2 -2
  29. package/{bf684fc8.js → cc8ba9a3.js} +12713 -12735
  30. package/{bcd4bce3.js → d27497a0.js} +18 -18
  31. package/{c69763fa.js → dbeb2d17.js} +2 -2
  32. package/{6741b2b9.js → de3e61cd.js} +68 -69
  33. package/df15a543.js +817 -0
  34. package/{47848c42.js → e5b014a9.js} +5 -5
  35. package/e86c3e3a.js +1264 -0
  36. package/{0f43fe1e.js → eb52cd1a.js} +8 -8
  37. package/{0da7ca4d.js → ebbe2009.js} +92 -92
  38. package/{cb338c34.js → ecab0a38.js} +96 -99
  39. package/{268c902c.js → f3455869.js} +26 -27
  40. package/f701d7da.js +433 -0
  41. package/{6402852d.js → fc681b47.js} +12 -12
  42. package/index.js +2 -2
  43. package/package.json +1 -1
  44. package/04c7d898.js +0 -819
  45. package/078d4a18.js +0 -818
  46. package/18cd6b56.js +0 -391
  47. package/1a8f0a25.js +0 -455
  48. package/2b4f4275.js +0 -1276
  49. package/2efee7c6.js +0 -1102
  50. package/a6a69647.js +0 -237
  51. package/c2bb8612.js +0 -208
package/a6a69647.js DELETED
@@ -1,237 +0,0 @@
1
- var H = Object.defineProperty;
2
- var A = Object.getOwnPropertySymbols;
3
- var V = Object.prototype.hasOwnProperty, W = Object.prototype.propertyIsEnumerable;
4
- var $ = (l, t, n) => t in l ? H(l, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : l[t] = n, k = (l, t) => {
5
- for (var n in t || (t = {}))
6
- V.call(t, n) && $(l, n, t[n]);
7
- if (A)
8
- for (var n of A(t))
9
- W.call(t, n) && $(l, n, t[n]);
10
- return l;
11
- };
12
- var I = (l, t, n) => new Promise((i, e) => {
13
- var c = (o) => {
14
- try {
15
- r(n.next(o));
16
- } catch (a) {
17
- e(a);
18
- }
19
- }, s = (o) => {
20
- try {
21
- r(n.throw(o));
22
- } catch (a) {
23
- e(a);
24
- }
25
- }, r = (o) => o.done ? i(o.value) : Promise.resolve(o.value).then(c, s);
26
- r((n = n.apply(l, t)).next());
27
- });
28
- import { p as J, d as M, s as K } from "./005a58c0.js";
29
- import { l as p, e as d, j as S, C as Q, v as U, q as B, u as G, p as q, m as z } from "./6296008d.js";
30
- import { G as X } from "./32d11caf.js";
31
- import { r as Y } from "./18cd6b56.js";
32
- import "./c69763fa.js";
33
- import "./21e8a932.js";
34
- import "./2efee7c6.js";
35
- import "./43254cb0.js";
36
- import "./08ea4a8f.js";
37
- import "./2ff2c7a6.js";
38
- import "./256b619e.js";
39
- const L = (l) => z.sanitizeText(l, d());
40
- let T = {
41
- dividerMargin: 10,
42
- padding: 5,
43
- textHeight: 10,
44
- curve: void 0
45
- };
46
- const Z = function(l, t, n, i) {
47
- const e = Object.keys(l);
48
- p.info("keys:", e), p.info(l), e.forEach(function(c) {
49
- var y;
50
- var s, r;
51
- const o = l[c], f = {
52
- shape: "rect",
53
- id: o.id,
54
- domId: o.domId,
55
- labelText: L(o.id),
56
- labelStyle: "",
57
- style: "fill: none; stroke: black",
58
- // TODO V10: Flowchart ? Keeping flowchart for backwards compatibility. Remove in next major release
59
- padding: (y = (s = d().flowchart) == null ? void 0 : s.padding) != null ? y : (r = d().class) == null ? void 0 : r.padding
60
- };
61
- t.setNode(o.id, f), P(o.classes, t, n, i, o.id), p.info("setNode", f);
62
- });
63
- }, P = function(l, t, n, i, e) {
64
- const c = Object.keys(l);
65
- p.info("keys:", c), p.info(l), c.filter((s) => l[s].parent == e).forEach(function(s) {
66
- var x, m;
67
- var r, o;
68
- const a = l[s], f = a.cssClasses.join(" "), y = B(a.styles), v = (x = a.label) != null ? x : a.id, b = 0, h = "class_box", u = {
69
- labelStyle: y.labelStyle,
70
- shape: h,
71
- labelText: L(v),
72
- classData: a,
73
- rx: b,
74
- ry: b,
75
- class: f,
76
- style: y.style,
77
- id: a.id,
78
- domId: a.domId,
79
- tooltip: i.db.getTooltip(a.id, e) || "",
80
- haveCallback: a.haveCallback,
81
- link: a.link,
82
- width: a.type === "group" ? 500 : void 0,
83
- type: a.type,
84
- // TODO V10: Flowchart ? Keeping flowchart for backwards compatibility. Remove in next major release
85
- padding: (m = (r = d().flowchart) == null ? void 0 : r.padding) != null ? m : (o = d().class) == null ? void 0 : o.padding
86
- };
87
- t.setNode(a.id, u), e && t.setParent(a.id, e), p.info("setNode", u);
88
- });
89
- }, j = function(l, t, n, i) {
90
- p.info(l), l.forEach(function(e, c) {
91
- var m;
92
- var s, r;
93
- const o = e, a = "", f = { labelStyle: "", style: "" }, y = o.text, v = 0, b = "note", h = {
94
- labelStyle: f.labelStyle,
95
- shape: b,
96
- labelText: L(y),
97
- noteData: o,
98
- rx: v,
99
- ry: v,
100
- class: a,
101
- style: f.style,
102
- id: o.id,
103
- domId: o.id,
104
- tooltip: "",
105
- type: "note",
106
- // TODO V10: Flowchart ? Keeping flowchart for backwards compatibility. Remove in next major release
107
- padding: (m = (s = d().flowchart) == null ? void 0 : s.padding) != null ? m : (r = d().class) == null ? void 0 : r.padding
108
- };
109
- if (t.setNode(o.id, h), p.info("setNode", h), !o.class || !(o.class in i))
110
- return;
111
- const u = n + c, x = {
112
- id: `edgeNote${u}`,
113
- //Set relationship style and line type
114
- classes: "relation",
115
- pattern: "dotted",
116
- // Set link type for rendering
117
- arrowhead: "none",
118
- //Set edge extra labels
119
- startLabelRight: "",
120
- endLabelLeft: "",
121
- //Set relation arrow types
122
- arrowTypeStart: "none",
123
- arrowTypeEnd: "none",
124
- style: "fill:none",
125
- labelStyle: "",
126
- curve: G(T.curve, q)
127
- };
128
- t.setEdge(o.id, o.class, x, u);
129
- });
130
- }, O = function(l, t) {
131
- const n = d().flowchart;
132
- let i = 0;
133
- l.forEach(function(e) {
134
- var r;
135
- var c;
136
- i++;
137
- const s = {
138
- //Set relationship style and line type
139
- classes: "relation",
140
- pattern: e.relation.lineType == 1 ? "dashed" : "solid",
141
- id: `id_${e.id1}_${e.id2}_${i}`,
142
- // Set link type for rendering
143
- arrowhead: e.type === "arrow_open" ? "none" : "normal",
144
- //Set edge extra labels
145
- startLabelRight: e.relationTitle1 === "none" ? "" : e.relationTitle1,
146
- endLabelLeft: e.relationTitle2 === "none" ? "" : e.relationTitle2,
147
- //Set relation arrow types
148
- arrowTypeStart: R(e.relation.type1),
149
- arrowTypeEnd: R(e.relation.type2),
150
- style: "fill:none",
151
- labelStyle: "",
152
- curve: G(n == null ? void 0 : n.curve, q)
153
- };
154
- if (p.info(s, e), e.style !== void 0) {
155
- const o = B(e.style);
156
- s.style = o.style, s.labelStyle = o.labelStyle;
157
- }
158
- e.text = e.title, e.text === void 0 ? e.style !== void 0 && (s.arrowheadStyle = "fill: #333") : (s.arrowheadStyle = "fill: #333", s.labelpos = "c", ((r = (c = d().flowchart) == null ? void 0 : c.htmlLabels) != null ? r : d().htmlLabels) ? (s.labelType = "html", s.label = '<span class="edgeLabel">' + e.text + "</span>") : (s.labelType = "text", s.label = e.text.replace(z.lineBreakRegex, `
159
- `), e.style === void 0 && (s.style = s.style || "stroke: #333; stroke-width: 1.5px;fill:none"), s.labelStyle = s.labelStyle.replace("color:", "fill:"))), t.setEdge(e.id1, e.id2, s, i);
160
- });
161
- }, ee = function(l) {
162
- T = k(k({}, T), l);
163
- }, te = function(l, t, n, i) {
164
- return I(this, null, function* () {
165
- var m, _, N, C;
166
- p.info("Drawing class - ", t);
167
- const e = (m = d().flowchart) != null ? m : d().class, c = d().securityLevel;
168
- p.info("config:", e);
169
- const s = (_ = e == null ? void 0 : e.nodeSpacing) != null ? _ : 50, r = (N = e == null ? void 0 : e.rankSpacing) != null ? N : 50, o = new X({
170
- multigraph: !0,
171
- compound: !0
172
- }).setGraph({
173
- rankdir: i.db.getDirection(),
174
- nodesep: s,
175
- ranksep: r,
176
- marginx: 8,
177
- marginy: 8
178
- }).setDefaultEdgeLabel(function() {
179
- return {};
180
- }), a = i.db.getNamespaces(), f = i.db.getClasses(), y = i.db.getRelations(), v = i.db.getNotes();
181
- p.info(y), Z(a, o, t, i), P(f, o, t, i), O(y, o), j(v, o, y.length + 1, f);
182
- let b;
183
- c === "sandbox" && (b = S("#i" + t));
184
- const h = c === "sandbox" ? S(b.nodes()[0].contentDocument.body) : S("body"), u = h.select(`[id="${t}"]`), x = h.select("#" + t + " g");
185
- if (yield Y(
186
- x,
187
- o,
188
- ["aggregation", "extension", "composition", "dependency", "lollipop"],
189
- "classDiagram",
190
- t
191
- ), Q.insertTitle(u, "classTitleText", (C = e == null ? void 0 : e.titleTopMargin) != null ? C : 5, i.db.getDiagramTitle()), U(o, u, e == null ? void 0 : e.diagramPadding, e == null ? void 0 : e.useMaxWidth), !(e != null && e.htmlLabels)) {
192
- const D = c === "sandbox" ? b.nodes()[0].contentDocument : document, F = D.querySelectorAll('[id="' + t + '"] .edgeLabel .label');
193
- for (const w of F) {
194
- const E = w.getBBox(), g = D.createElementNS("http://www.w3.org/2000/svg", "rect");
195
- g.setAttribute("rx", 0), g.setAttribute("ry", 0), g.setAttribute("width", E.width), g.setAttribute("height", E.height), w.insertBefore(g, w.firstChild);
196
- }
197
- }
198
- });
199
- };
200
- function R(l) {
201
- let t;
202
- switch (l) {
203
- case 0:
204
- t = "aggregation";
205
- break;
206
- case 1:
207
- t = "extension";
208
- break;
209
- case 2:
210
- t = "composition";
211
- break;
212
- case 3:
213
- t = "dependency";
214
- break;
215
- case 4:
216
- t = "lollipop";
217
- break;
218
- default:
219
- t = "none";
220
- }
221
- return t;
222
- }
223
- const oe = {
224
- setConf: ee,
225
- draw: te
226
- }, ue = {
227
- parser: J,
228
- db: M,
229
- renderer: oe,
230
- styles: K,
231
- init: (l) => {
232
- l.class || (l.class = {}), l.class.arrowMarkerAbsolute = l.arrowMarkerAbsolute, M.clear();
233
- }
234
- };
235
- export {
236
- ue as diagram
237
- };
package/c2bb8612.js DELETED
@@ -1,208 +0,0 @@
1
- var B = (e, n, t) => new Promise((i, c) => {
2
- var r = (l) => {
3
- try {
4
- a(t.next(l));
5
- } catch (s) {
6
- c(s);
7
- }
8
- }, o = (l) => {
9
- try {
10
- a(t.throw(l));
11
- } catch (s) {
12
- c(s);
13
- }
14
- }, a = (l) => l.done ? i(l.value) : Promise.resolve(l.value).then(r, o);
15
- a((t = t.apply(e, n)).next());
16
- });
17
- import { p as Q, d as M, s as X, D as U, a as Z, S as F, b as I, c as tt } from "./a73a7fb8.js";
18
- import { G as et } from "./32d11caf.js";
19
- import { l as T, e as g, j as x, C as ot, k as st, m as w } from "./6296008d.js";
20
- import { r as nt } from "./18cd6b56.js";
21
- import "./c69763fa.js";
22
- import "./21e8a932.js";
23
- import "./2efee7c6.js";
24
- import "./43254cb0.js";
25
- import "./08ea4a8f.js";
26
- import "./2ff2c7a6.js";
27
- import "./256b619e.js";
28
- const h = "rect", C = "rectWithTitle", it = "start", ct = "end", rt = "divider", lt = "roundedWithTitle", at = "note", dt = "noteGroup", u = "statediagram", Et = "state", St = `${u}-${Et}`, V = "transition", Tt = "note", pt = "note-edge", _t = `${V} ${pt}`, ut = `${u}-${Tt}`, Dt = "cluster", bt = `${u}-${Dt}`, ft = "cluster-alt", At = `${u}-${ft}`, Y = "parent", m = "note", ht = "state", N = "----", yt = `${N}${m}`, H = `${N}${Y}`, W = "fill:none", z = "fill: #333", j = "c", q = "text", K = "normal";
29
- let y = {}, S = 0;
30
- const gt = function(e) {
31
- const n = Object.keys(e);
32
- for (const t of n)
33
- e[t];
34
- }, $t = function(e, n) {
35
- return n.db.extract(n.db.getRootDocV2()), n.db.getClasses();
36
- };
37
- function xt(e) {
38
- return e == null ? "" : e.classes ? e.classes.join(" ") : "";
39
- }
40
- function R(e = "", n = 0, t = "", i = N) {
41
- const c = t !== null && t.length > 0 ? `${i}${t}` : "";
42
- return `${ht}-${e}${c}-${n}`;
43
- }
44
- const A = (e, n, t, i, c, r) => {
45
- const o = t.id, a = xt(i[o]);
46
- if (o !== "root") {
47
- let l = h;
48
- t.start === !0 && (l = it), t.start === !1 && (l = ct), t.type !== U && (l = t.type), y[o] || (y[o] = {
49
- id: o,
50
- shape: l,
51
- description: w.sanitizeText(o, g()),
52
- classes: `${a} ${St}`
53
- });
54
- const s = y[o];
55
- t.description && (Array.isArray(s.description) ? (s.shape = C, s.description.push(t.description)) : s.description.length > 0 ? (s.shape = C, s.description === o ? s.description = [t.description] : s.description = [s.description, t.description]) : (s.shape = h, s.description = t.description), s.description = w.sanitizeTextOrArray(s.description, g())), s.description.length === 1 && s.shape === C && (s.shape = h), !s.type && t.doc && (T.info("Setting cluster for ", o, G(t)), s.type = "group", s.dir = G(t), s.shape = t.type === Z ? rt : lt, s.classes = s.classes + " " + bt + " " + (r ? At : ""));
56
- const _ = {
57
- labelStyle: "",
58
- shape: s.shape,
59
- labelText: s.description,
60
- // typeof newNode.description === 'object'
61
- // ? newNode.description[0]
62
- // : newNode.description,
63
- classes: s.classes,
64
- style: "",
65
- //styles.style,
66
- id: o,
67
- dir: s.dir,
68
- domId: R(o, S),
69
- type: s.type,
70
- padding: 15
71
- //getConfig().flowchart.padding
72
- };
73
- if (_.centerLabel = !0, t.note) {
74
- const d = {
75
- labelStyle: "",
76
- shape: at,
77
- labelText: t.note.text,
78
- classes: ut,
79
- // useHtmlLabels: false,
80
- style: "",
81
- // styles.style,
82
- id: o + yt + "-" + S,
83
- domId: R(o, S, m),
84
- type: s.type,
85
- padding: 15
86
- //getConfig().flowchart.padding
87
- }, E = {
88
- labelStyle: "",
89
- shape: dt,
90
- labelText: t.note.text,
91
- classes: s.classes,
92
- style: "",
93
- // styles.style,
94
- id: o + H,
95
- domId: R(o, S, Y),
96
- type: "group",
97
- padding: 0
98
- //getConfig().flowchart.padding
99
- };
100
- S++;
101
- const D = o + H;
102
- e.setNode(D, E), e.setNode(d.id, d), e.setNode(o, _), e.setParent(o, D), e.setParent(d.id, D);
103
- let p = o, b = d.id;
104
- t.note.position === "left of" && (p = d.id, b = o), e.setEdge(p, b, {
105
- arrowhead: "none",
106
- arrowType: "",
107
- style: W,
108
- labelStyle: "",
109
- classes: _t,
110
- arrowheadStyle: z,
111
- labelpos: j,
112
- labelType: q,
113
- thickness: K
114
- });
115
- } else
116
- e.setNode(o, _);
117
- }
118
- n && n.id !== "root" && (T.trace("Setting node ", o, " to be child of its parent ", n.id), e.setParent(o, n.id)), t.doc && (T.trace("Adding nodes children "), Ct(e, t, t.doc, i, c, !r));
119
- }, Ct = (e, n, t, i, c, r) => {
120
- T.trace("items", t), t.forEach((o) => {
121
- switch (o.stmt) {
122
- case I:
123
- A(e, n, o, i, c, r);
124
- break;
125
- case U:
126
- A(e, n, o, i, c, r);
127
- break;
128
- case F:
129
- {
130
- A(e, n, o.state1, i, c, r), A(e, n, o.state2, i, c, r);
131
- const a = {
132
- id: "edge" + S,
133
- arrowhead: "normal",
134
- arrowTypeEnd: "arrow_barb",
135
- style: W,
136
- labelStyle: "",
137
- label: w.sanitizeText(o.description, g()),
138
- arrowheadStyle: z,
139
- labelpos: j,
140
- labelType: q,
141
- thickness: K,
142
- classes: V
143
- };
144
- e.setEdge(o.state1.id, o.state2.id, a, S), S++;
145
- }
146
- break;
147
- }
148
- });
149
- }, G = (e, n = tt) => {
150
- let t = n;
151
- if (e.doc)
152
- for (let i = 0; i < e.doc.length; i++) {
153
- const c = e.doc[i];
154
- c.stmt === "dir" && (t = c.value);
155
- }
156
- return t;
157
- }, Rt = function(e, n, t, i) {
158
- return B(this, null, function* () {
159
- T.info("Drawing state diagram (v2)", n), y = {}, i.db.getDirection();
160
- const { securityLevel: c, state: r } = g(), o = r.nodeSpacing || 50, a = r.rankSpacing || 50;
161
- T.info(i.db.getRootDocV2()), i.db.extract(i.db.getRootDocV2()), T.info(i.db.getRootDocV2());
162
- const l = i.db.getStates(), s = new et({
163
- multigraph: !0,
164
- compound: !0
165
- }).setGraph({
166
- rankdir: G(i.db.getRootDocV2()),
167
- nodesep: o,
168
- ranksep: a,
169
- marginx: 8,
170
- marginy: 8
171
- }).setDefaultEdgeLabel(function() {
172
- return {};
173
- });
174
- A(s, void 0, i.db.getRootDocV2(), l, i.db, !0);
175
- let _;
176
- c === "sandbox" && (_ = x("#i" + n));
177
- const d = c === "sandbox" ? x(_.nodes()[0].contentDocument.body) : x("body"), E = d.select(`[id="${n}"]`), D = d.select("#" + n + " g");
178
- yield nt(D, s, ["barb"], u, n);
179
- const p = 8;
180
- ot.insertTitle(E, "statediagramTitleText", r.titleTopMargin, i.db.getDiagramTitle());
181
- const b = E.node().getBBox(), L = b.width + p * 2, P = b.height + p * 2;
182
- E.attr("class", u);
183
- const O = E.node().getBBox();
184
- st(E, P, L, r.useMaxWidth);
185
- const k = `${O.x - p} ${O.y - p} ${L} ${P}`;
186
- T.debug(`viewBox ${k}`), E.attr("viewBox", k);
187
- const J = document.querySelectorAll('[id="' + n + '"] .edgeLabel .label');
188
- for (const $ of J) {
189
- const v = $.getBBox(), f = document.createElementNS("http://www.w3.org/2000/svg", h);
190
- f.setAttribute("rx", 0), f.setAttribute("ry", 0), f.setAttribute("width", v.width), f.setAttribute("height", v.height), $.insertBefore(f, $.firstChild);
191
- }
192
- });
193
- }, wt = {
194
- setConf: gt,
195
- getClasses: $t,
196
- draw: Rt
197
- }, Yt = {
198
- parser: Q,
199
- db: M,
200
- renderer: wt,
201
- styles: X,
202
- init: (e) => {
203
- e.state || (e.state = {}), e.state.arrowMarkerAbsolute = e.arrowMarkerAbsolute, M.clear();
204
- }
205
- };
206
- export {
207
- Yt as diagram
208
- };