lowcoder-comps 0.0.32 → 0.0.33

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 (43) hide show
  1. package/{c289b0aa.js → 00bb478a.js} +49 -49
  2. package/{4a860f5d.js → 02bef5a4.js} +58 -58
  3. package/{f8b68c1a.js → 057d2a44.js} +21 -21
  4. package/{d8c50a91.js → 0964fcc6.js} +5 -5
  5. package/{cc799554.js → 14220e98.js} +52 -52
  6. package/{24307cf2.js → 1c074fe4.js} +11 -11
  7. package/{ee801edf.js → 250a6954.js} +36 -36
  8. package/{4cc9caa5.js → 2cd27cf0.js} +2 -2
  9. package/{fcee2d3c.js → 2f064957.js} +5 -5
  10. package/{4a489df6.js → 30c4916b.js} +1 -1
  11. package/{e6388bfd.js → 36ec7270.js} +2 -2
  12. package/{c9bb75eb.js → 38c14832.js} +1 -1
  13. package/{debd9490.js → 3ae34bed.js} +11 -11
  14. package/{97059d88.js → 3e2939fa.js} +75 -75
  15. package/{4564a1bc.js → 3f5f874f.js} +28 -28
  16. package/{1e5cb9c2.js → 3fb86fb9.js} +18 -18
  17. package/{fd51bb2f.js → 415177f9.js} +2 -2
  18. package/{a40faea7.js → 47848c42.js} +317 -305
  19. package/4c6a0ece.js +162535 -0
  20. package/{d3700d97.js → 4db8e48b.js} +22 -22
  21. package/{e06dcfb0.js → 531065f1.js} +14 -14
  22. package/{6deaf0be.js → 5a398ea8.js} +29 -29
  23. package/{444e09f1.js → 5ab1614c.js} +18 -18
  24. package/{64d87c95.js → 65bbb6ae.js} +2 -2
  25. package/{a969f4ca.js → 777cd15c.js} +2057 -2057
  26. package/{df803461.js → 7dacfa82.js} +26 -26
  27. package/{a408f817.js → 800cf0d0.js} +18 -18
  28. package/{7a3f27e4.js → 93e9bd3a.js} +6 -6
  29. package/98622dfa.js +16582 -0
  30. package/{2b031be2.js → a2e74e62.js} +1 -1
  31. package/{c4d99b09.js → a61c3bd3.js} +1 -1
  32. package/{dce9fa3f.js → b8f48ff4.js} +4 -4
  33. package/{7ae6dd1c.js → bd0f5f65.js} +6 -6
  34. package/{aa82b740.js → bf4428f5.js} +56 -56
  35. package/{aa1becc7.js → cb1972f7.js} +9 -9
  36. package/{d622fb26.js → dfc10c94.js} +66 -66
  37. package/{794e64d5.js → ed2c9753.js} +13 -13
  38. package/{cb40fdd9.js → ef2833e6.js} +308 -314
  39. package/{de8c90a7.js → f9e72519.js} +30 -30
  40. package/{f7c6b13d.js → fe063d15.js} +7498 -7263
  41. package/index.js +2 -2
  42. package/package.json +27 -1
  43. package/98955949.js +0 -134435
@@ -1,117 +1,111 @@
1
- import { c as Z, s as Et, g as mt, b as gt, a as kt, C as xt, D as Rt, l as V, E as Ot, h as rt, A as bt, i as Nt, F as Tt, G as At } from "./98955949.js";
2
- import { G as Mt } from "./6deaf0be.js";
3
- import { l as St } from "./64d87c95.js";
4
- import { l as wt } from "./d8c50a91.js";
1
+ import { E as _t, e as Y, s as Et, a as mt, d as gt, b as kt, F as xt, G as Rt, l as K, H as Ot, j as et, C as bt, k as Nt, I as Tt, J as At } from "./4c6a0ece.js";
2
+ import { G as Mt } from "./5a398ea8.js";
3
+ import { l as It } from "./65bbb6ae.js";
4
+ import { l as wt } from "./0964fcc6.js";
5
5
  import "./2ff2c7a6.js";
6
6
  import "./256b619e.js";
7
- const It = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;
7
+ const St = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;
8
8
  function Dt(t) {
9
- return typeof t == "string" && It.test(t);
9
+ return typeof t == "string" && St.test(t);
10
10
  }
11
- const A = [];
12
- for (let t = 0; t < 256; ++t)
13
- A.push((t + 256).toString(16).slice(1));
14
- function vt(t, e = 0) {
15
- return A[t[e + 0]] + A[t[e + 1]] + A[t[e + 2]] + A[t[e + 3]] + "-" + A[t[e + 4]] + A[t[e + 5]] + "-" + A[t[e + 6]] + A[t[e + 7]] + "-" + A[t[e + 8]] + A[t[e + 9]] + "-" + A[t[e + 10]] + A[t[e + 11]] + A[t[e + 12]] + A[t[e + 13]] + A[t[e + 14]] + A[t[e + 15]];
16
- }
17
- function Lt(t) {
11
+ function vt(t) {
18
12
  if (!Dt(t))
19
13
  throw TypeError("Invalid UUID");
20
- let e;
21
- const r = new Uint8Array(16);
22
- return r[0] = (e = parseInt(t.slice(0, 8), 16)) >>> 24, r[1] = e >>> 16 & 255, r[2] = e >>> 8 & 255, r[3] = e & 255, r[4] = (e = parseInt(t.slice(9, 13), 16)) >>> 8, r[5] = e & 255, r[6] = (e = parseInt(t.slice(14, 18), 16)) >>> 8, r[7] = e & 255, r[8] = (e = parseInt(t.slice(19, 23), 16)) >>> 8, r[9] = e & 255, r[10] = (e = parseInt(t.slice(24, 36), 16)) / 1099511627776 & 255, r[11] = e / 4294967296 & 255, r[12] = e >>> 24 & 255, r[13] = e >>> 16 & 255, r[14] = e >>> 8 & 255, r[15] = e & 255, r;
14
+ let r;
15
+ const e = new Uint8Array(16);
16
+ return e[0] = (r = parseInt(t.slice(0, 8), 16)) >>> 24, e[1] = r >>> 16 & 255, e[2] = r >>> 8 & 255, e[3] = r & 255, e[4] = (r = parseInt(t.slice(9, 13), 16)) >>> 8, e[5] = r & 255, e[6] = (r = parseInt(t.slice(14, 18), 16)) >>> 8, e[7] = r & 255, e[8] = (r = parseInt(t.slice(19, 23), 16)) >>> 8, e[9] = r & 255, e[10] = (r = parseInt(t.slice(24, 36), 16)) / 1099511627776 & 255, e[11] = r / 4294967296 & 255, e[12] = r >>> 24 & 255, e[13] = r >>> 16 & 255, e[14] = r >>> 8 & 255, e[15] = r & 255, e;
23
17
  }
24
- function Bt(t) {
18
+ function Lt(t) {
25
19
  t = unescape(encodeURIComponent(t));
26
- const e = [];
27
- for (let r = 0; r < t.length; ++r)
28
- e.push(t.charCodeAt(r));
29
- return e;
20
+ const r = [];
21
+ for (let e = 0; e < t.length; ++e)
22
+ r.push(t.charCodeAt(e));
23
+ return r;
30
24
  }
31
- const Ct = "6ba7b810-9dad-11d1-80b4-00c04fd430c8", Pt = "6ba7b811-9dad-11d1-80b4-00c04fd430c8";
32
- function Yt(t, e, r) {
33
- function u(l, p, f, o) {
25
+ const Bt = "6ba7b810-9dad-11d1-80b4-00c04fd430c8", Ct = "6ba7b811-9dad-11d1-80b4-00c04fd430c8";
26
+ function Pt(t, r, e) {
27
+ function f(l, p, u, o) {
34
28
  var h;
35
- if (typeof l == "string" && (l = Bt(l)), typeof p == "string" && (p = Lt(p)), ((h = p) === null || h === void 0 ? void 0 : h.length) !== 16)
29
+ if (typeof l == "string" && (l = Lt(l)), typeof p == "string" && (p = vt(p)), ((h = p) === null || h === void 0 ? void 0 : h.length) !== 16)
36
30
  throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");
37
31
  let _ = new Uint8Array(16 + l.length);
38
- if (_.set(p), _.set(l, p.length), _ = r(_), _[6] = _[6] & 15 | e, _[8] = _[8] & 63 | 128, f) {
32
+ if (_.set(p), _.set(l, p.length), _ = e(_), _[6] = _[6] & 15 | r, _[8] = _[8] & 63 | 128, u) {
39
33
  o = o || 0;
40
34
  for (let m = 0; m < 16; ++m)
41
- f[o + m] = _[m];
42
- return f;
35
+ u[o + m] = _[m];
36
+ return u;
43
37
  }
44
- return vt(_);
38
+ return _t(_);
45
39
  }
46
40
  try {
47
- u.name = t;
41
+ f.name = t;
48
42
  } catch (l) {
49
43
  }
50
- return u.DNS = Ct, u.URL = Pt, u;
44
+ return f.DNS = Bt, f.URL = Ct, f;
51
45
  }
52
- function Zt(t, e, r, u) {
46
+ function Yt(t, r, e, f) {
53
47
  switch (t) {
54
48
  case 0:
55
- return e & r ^ ~e & u;
49
+ return r & e ^ ~r & f;
56
50
  case 1:
57
- return e ^ r ^ u;
51
+ return r ^ e ^ f;
58
52
  case 2:
59
- return e & r ^ e & u ^ r & u;
53
+ return r & e ^ r & f ^ e & f;
60
54
  case 3:
61
- return e ^ r ^ u;
55
+ return r ^ e ^ f;
62
56
  }
63
57
  }
64
- function it(t, e) {
65
- return t << e | t >>> 32 - e;
58
+ function rt(t, r) {
59
+ return t << r | t >>> 32 - r;
66
60
  }
67
- function Ft(t) {
68
- const e = [1518500249, 1859775393, 2400959708, 3395469782], r = [1732584193, 4023233417, 2562383102, 271733878, 3285377520];
61
+ function Zt(t) {
62
+ const r = [1518500249, 1859775393, 2400959708, 3395469782], e = [1732584193, 4023233417, 2562383102, 271733878, 3285377520];
69
63
  if (typeof t == "string") {
70
- const f = unescape(encodeURIComponent(t));
64
+ const u = unescape(encodeURIComponent(t));
71
65
  t = [];
72
- for (let o = 0; o < f.length; ++o)
73
- t.push(f.charCodeAt(o));
66
+ for (let o = 0; o < u.length; ++o)
67
+ t.push(u.charCodeAt(o));
74
68
  } else
75
69
  Array.isArray(t) || (t = Array.prototype.slice.call(t));
76
70
  t.push(128);
77
- const u = t.length / 4 + 2, l = Math.ceil(u / 16), p = new Array(l);
78
- for (let f = 0; f < l; ++f) {
71
+ const f = t.length / 4 + 2, l = Math.ceil(f / 16), p = new Array(l);
72
+ for (let u = 0; u < l; ++u) {
79
73
  const o = new Uint32Array(16);
80
74
  for (let h = 0; h < 16; ++h)
81
- o[h] = t[f * 64 + h * 4] << 24 | t[f * 64 + h * 4 + 1] << 16 | t[f * 64 + h * 4 + 2] << 8 | t[f * 64 + h * 4 + 3];
82
- p[f] = o;
75
+ o[h] = t[u * 64 + h * 4] << 24 | t[u * 64 + h * 4 + 1] << 16 | t[u * 64 + h * 4 + 2] << 8 | t[u * 64 + h * 4 + 3];
76
+ p[u] = o;
83
77
  }
84
78
  p[l - 1][14] = (t.length - 1) * 8 / Math.pow(2, 32), p[l - 1][14] = Math.floor(p[l - 1][14]), p[l - 1][15] = (t.length - 1) * 8 & 4294967295;
85
- for (let f = 0; f < l; ++f) {
79
+ for (let u = 0; u < l; ++u) {
86
80
  const o = new Uint32Array(80);
87
81
  for (let y = 0; y < 16; ++y)
88
- o[y] = p[f][y];
82
+ o[y] = p[u][y];
89
83
  for (let y = 16; y < 80; ++y)
90
- o[y] = it(o[y - 3] ^ o[y - 8] ^ o[y - 14] ^ o[y - 16], 1);
91
- let h = r[0], _ = r[1], m = r[2], g = r[3], R = r[4];
84
+ o[y] = rt(o[y - 3] ^ o[y - 8] ^ o[y - 14] ^ o[y - 16], 1);
85
+ let h = e[0], _ = e[1], m = e[2], g = e[3], R = e[4];
92
86
  for (let y = 0; y < 80; ++y) {
93
- const k = Math.floor(y / 20), I = it(h, 5) + Zt(k, _, m, g) + R + e[k] + o[y] >>> 0;
94
- R = g, g = m, m = it(_, 30) >>> 0, _ = h, h = I;
87
+ const k = Math.floor(y / 20), w = rt(h, 5) + Yt(k, _, m, g) + R + r[k] + o[y] >>> 0;
88
+ R = g, g = m, m = rt(_, 30) >>> 0, _ = h, h = w;
95
89
  }
96
- r[0] = r[0] + h >>> 0, r[1] = r[1] + _ >>> 0, r[2] = r[2] + m >>> 0, r[3] = r[3] + g >>> 0, r[4] = r[4] + R >>> 0;
90
+ e[0] = e[0] + h >>> 0, e[1] = e[1] + _ >>> 0, e[2] = e[2] + m >>> 0, e[3] = e[3] + g >>> 0, e[4] = e[4] + R >>> 0;
97
91
  }
98
- return [r[0] >> 24 & 255, r[0] >> 16 & 255, r[0] >> 8 & 255, r[0] & 255, r[1] >> 24 & 255, r[1] >> 16 & 255, r[1] >> 8 & 255, r[1] & 255, r[2] >> 24 & 255, r[2] >> 16 & 255, r[2] >> 8 & 255, r[2] & 255, r[3] >> 24 & 255, r[3] >> 16 & 255, r[3] >> 8 & 255, r[3] & 255, r[4] >> 24 & 255, r[4] >> 16 & 255, r[4] >> 8 & 255, r[4] & 255];
92
+ return [e[0] >> 24 & 255, e[0] >> 16 & 255, e[0] >> 8 & 255, e[0] & 255, e[1] >> 24 & 255, e[1] >> 16 & 255, e[1] >> 8 & 255, e[1] & 255, e[2] >> 24 & 255, e[2] >> 16 & 255, e[2] >> 8 & 255, e[2] & 255, e[3] >> 24 & 255, e[3] >> 16 & 255, e[3] >> 8 & 255, e[3] & 255, e[4] >> 24 & 255, e[4] >> 16 & 255, e[4] >> 8 & 255, e[4] & 255];
99
93
  }
100
- const Wt = Yt("v5", 80, Ft), Ut = Wt;
94
+ const Ft = Pt("v5", 80, Zt), Wt = Ft;
101
95
  var at = function() {
102
- var t = function(S, a, n, c) {
103
- for (n = n || {}, c = S.length; c--; n[S[c]] = a)
96
+ var t = function(M, i, n, c) {
97
+ for (n = n || {}, c = M.length; c--; n[M[c]] = i)
104
98
  ;
105
99
  return n;
106
- }, e = [6, 8, 10, 20, 22, 24, 26, 27, 28], r = [1, 10], u = [1, 11], l = [1, 12], p = [1, 13], f = [1, 14], o = [1, 15], h = [1, 21], _ = [1, 22], m = [1, 23], g = [1, 24], R = [1, 25], y = [6, 8, 10, 13, 15, 18, 19, 20, 22, 24, 26, 27, 28, 41, 42, 43, 44, 45], k = [1, 34], I = [27, 28, 46, 47], F = [41, 42, 43, 44, 45], W = [17, 34], C = [1, 54], T = [1, 53], M = [17, 34, 36, 38], O = {
100
+ }, r = [6, 8, 10, 20, 22, 24, 26, 27, 28], e = [1, 10], f = [1, 11], l = [1, 12], p = [1, 13], u = [1, 14], o = [1, 15], h = [1, 21], _ = [1, 22], m = [1, 23], g = [1, 24], R = [1, 25], y = [6, 8, 10, 13, 15, 18, 19, 20, 22, 24, 26, 27, 28, 41, 42, 43, 44, 45], k = [1, 34], w = [27, 28, 46, 47], Z = [41, 42, 43, 44, 45], F = [17, 34], B = [1, 54], T = [1, 53], A = [17, 34, 36, 38], O = {
107
101
  trace: function() {
108
102
  },
109
103
  yy: {},
110
104
  symbols_: { error: 2, start: 3, ER_DIAGRAM: 4, document: 5, EOF: 6, line: 7, SPACE: 8, statement: 9, NEWLINE: 10, entityName: 11, relSpec: 12, ":": 13, role: 14, BLOCK_START: 15, attributes: 16, BLOCK_STOP: 17, SQS: 18, SQE: 19, title: 20, title_value: 21, acc_title: 22, acc_title_value: 23, acc_descr: 24, acc_descr_value: 25, acc_descr_multiline_value: 26, ALPHANUM: 27, ENTITY_NAME: 28, attribute: 29, attributeType: 30, attributeName: 31, attributeKeyTypeList: 32, attributeComment: 33, ATTRIBUTE_WORD: 34, attributeKeyType: 35, COMMA: 36, ATTRIBUTE_KEY: 37, COMMENT: 38, cardinality: 39, relType: 40, ZERO_OR_ONE: 41, ZERO_OR_MORE: 42, ONE_OR_MORE: 43, ONLY_ONE: 44, MD_PARENT: 45, NON_IDENTIFYING: 46, IDENTIFYING: 47, WORD: 48, $accept: 0, $end: 1 },
111
105
  terminals_: { 2: "error", 4: "ER_DIAGRAM", 6: "EOF", 8: "SPACE", 10: "NEWLINE", 13: ":", 15: "BLOCK_START", 17: "BLOCK_STOP", 18: "SQS", 19: "SQE", 20: "title", 21: "title_value", 22: "acc_title", 23: "acc_title_value", 24: "acc_descr", 25: "acc_descr_value", 26: "acc_descr_multiline_value", 27: "ALPHANUM", 28: "ENTITY_NAME", 34: "ATTRIBUTE_WORD", 36: "COMMA", 37: "ATTRIBUTE_KEY", 38: "COMMENT", 41: "ZERO_OR_ONE", 42: "ZERO_OR_MORE", 43: "ONE_OR_MORE", 44: "ONLY_ONE", 45: "MD_PARENT", 46: "NON_IDENTIFYING", 47: "IDENTIFYING", 48: "WORD" },
112
106
  productions_: [0, [3, 3], [5, 0], [5, 2], [7, 2], [7, 1], [7, 1], [7, 1], [9, 5], [9, 4], [9, 3], [9, 1], [9, 7], [9, 6], [9, 4], [9, 2], [9, 2], [9, 2], [9, 1], [11, 1], [11, 1], [16, 1], [16, 2], [29, 2], [29, 3], [29, 3], [29, 4], [30, 1], [31, 1], [32, 1], [32, 3], [35, 1], [33, 1], [12, 3], [39, 1], [39, 1], [39, 1], [39, 1], [39, 1], [40, 1], [40, 1], [14, 1], [14, 1], [14, 1]],
113
- performAction: function(a, n, c, d, E, i, K) {
114
- var s = i.length - 1;
107
+ performAction: function(i, n, c, d, E, a, z) {
108
+ var s = a.length - 1;
115
109
  switch (E) {
116
110
  case 1:
117
111
  break;
@@ -119,86 +113,86 @@ var at = function() {
119
113
  this.$ = [];
120
114
  break;
121
115
  case 3:
122
- i[s - 1].push(i[s]), this.$ = i[s - 1];
116
+ a[s - 1].push(a[s]), this.$ = a[s - 1];
123
117
  break;
124
118
  case 4:
125
119
  case 5:
126
- this.$ = i[s];
120
+ this.$ = a[s];
127
121
  break;
128
122
  case 6:
129
123
  case 7:
130
124
  this.$ = [];
131
125
  break;
132
126
  case 8:
133
- d.addEntity(i[s - 4]), d.addEntity(i[s - 2]), d.addRelationship(i[s - 4], i[s], i[s - 2], i[s - 3]);
127
+ d.addEntity(a[s - 4]), d.addEntity(a[s - 2]), d.addRelationship(a[s - 4], a[s], a[s - 2], a[s - 3]);
134
128
  break;
135
129
  case 9:
136
- d.addEntity(i[s - 3]), d.addAttributes(i[s - 3], i[s - 1]);
130
+ d.addEntity(a[s - 3]), d.addAttributes(a[s - 3], a[s - 1]);
137
131
  break;
138
132
  case 10:
139
- d.addEntity(i[s - 2]);
133
+ d.addEntity(a[s - 2]);
140
134
  break;
141
135
  case 11:
142
- d.addEntity(i[s]);
136
+ d.addEntity(a[s]);
143
137
  break;
144
138
  case 12:
145
- d.addEntity(i[s - 6], i[s - 4]), d.addAttributes(i[s - 6], i[s - 1]);
139
+ d.addEntity(a[s - 6], a[s - 4]), d.addAttributes(a[s - 6], a[s - 1]);
146
140
  break;
147
141
  case 13:
148
- d.addEntity(i[s - 5], i[s - 3]);
142
+ d.addEntity(a[s - 5], a[s - 3]);
149
143
  break;
150
144
  case 14:
151
- d.addEntity(i[s - 3], i[s - 1]);
145
+ d.addEntity(a[s - 3], a[s - 1]);
152
146
  break;
153
147
  case 15:
154
148
  case 16:
155
- this.$ = i[s].trim(), d.setAccTitle(this.$);
149
+ this.$ = a[s].trim(), d.setAccTitle(this.$);
156
150
  break;
157
151
  case 17:
158
152
  case 18:
159
- this.$ = i[s].trim(), d.setAccDescription(this.$);
153
+ this.$ = a[s].trim(), d.setAccDescription(this.$);
160
154
  break;
161
155
  case 19:
162
156
  case 43:
163
- this.$ = i[s];
157
+ this.$ = a[s];
164
158
  break;
165
159
  case 20:
166
160
  case 41:
167
161
  case 42:
168
- this.$ = i[s].replace(/"/g, "");
162
+ this.$ = a[s].replace(/"/g, "");
169
163
  break;
170
164
  case 21:
171
165
  case 29:
172
- this.$ = [i[s]];
166
+ this.$ = [a[s]];
173
167
  break;
174
168
  case 22:
175
- i[s].push(i[s - 1]), this.$ = i[s];
169
+ a[s].push(a[s - 1]), this.$ = a[s];
176
170
  break;
177
171
  case 23:
178
- this.$ = { attributeType: i[s - 1], attributeName: i[s] };
172
+ this.$ = { attributeType: a[s - 1], attributeName: a[s] };
179
173
  break;
180
174
  case 24:
181
- this.$ = { attributeType: i[s - 2], attributeName: i[s - 1], attributeKeyTypeList: i[s] };
175
+ this.$ = { attributeType: a[s - 2], attributeName: a[s - 1], attributeKeyTypeList: a[s] };
182
176
  break;
183
177
  case 25:
184
- this.$ = { attributeType: i[s - 2], attributeName: i[s - 1], attributeComment: i[s] };
178
+ this.$ = { attributeType: a[s - 2], attributeName: a[s - 1], attributeComment: a[s] };
185
179
  break;
186
180
  case 26:
187
- this.$ = { attributeType: i[s - 3], attributeName: i[s - 2], attributeKeyTypeList: i[s - 1], attributeComment: i[s] };
181
+ this.$ = { attributeType: a[s - 3], attributeName: a[s - 2], attributeKeyTypeList: a[s - 1], attributeComment: a[s] };
188
182
  break;
189
183
  case 27:
190
184
  case 28:
191
185
  case 31:
192
- this.$ = i[s];
186
+ this.$ = a[s];
193
187
  break;
194
188
  case 30:
195
- i[s - 2].push(i[s]), this.$ = i[s - 2];
189
+ a[s - 2].push(a[s]), this.$ = a[s - 2];
196
190
  break;
197
191
  case 32:
198
- this.$ = i[s].replace(/"/g, "");
192
+ this.$ = a[s].replace(/"/g, "");
199
193
  break;
200
194
  case 33:
201
- this.$ = { cardA: i[s], relType: i[s - 1], cardB: i[s - 2] };
195
+ this.$ = { cardA: a[s], relType: a[s - 1], cardB: a[s - 2] };
202
196
  break;
203
197
  case 34:
204
198
  this.$ = d.Cardinality.ZERO_OR_ONE;
@@ -223,71 +217,71 @@ var at = function() {
223
217
  break;
224
218
  }
225
219
  },
226
- table: [{ 3: 1, 4: [1, 2] }, { 1: [3] }, t(e, [2, 2], { 5: 3 }), { 6: [1, 4], 7: 5, 8: [1, 6], 9: 7, 10: [1, 8], 11: 9, 20: r, 22: u, 24: l, 26: p, 27: f, 28: o }, t(e, [2, 7], { 1: [2, 1] }), t(e, [2, 3]), { 9: 16, 11: 9, 20: r, 22: u, 24: l, 26: p, 27: f, 28: o }, t(e, [2, 5]), t(e, [2, 6]), t(e, [2, 11], { 12: 17, 39: 20, 15: [1, 18], 18: [1, 19], 41: h, 42: _, 43: m, 44: g, 45: R }), { 21: [1, 26] }, { 23: [1, 27] }, { 25: [1, 28] }, t(e, [2, 18]), t(y, [2, 19]), t(y, [2, 20]), t(e, [2, 4]), { 11: 29, 27: f, 28: o }, { 16: 30, 17: [1, 31], 29: 32, 30: 33, 34: k }, { 11: 35, 27: f, 28: o }, { 40: 36, 46: [1, 37], 47: [1, 38] }, t(I, [2, 34]), t(I, [2, 35]), t(I, [2, 36]), t(I, [2, 37]), t(I, [2, 38]), t(e, [2, 15]), t(e, [2, 16]), t(e, [2, 17]), { 13: [1, 39] }, { 17: [1, 40] }, t(e, [2, 10]), { 16: 41, 17: [2, 21], 29: 32, 30: 33, 34: k }, { 31: 42, 34: [1, 43] }, { 34: [2, 27] }, { 19: [1, 44] }, { 39: 45, 41: h, 42: _, 43: m, 44: g, 45: R }, t(F, [2, 39]), t(F, [2, 40]), { 14: 46, 27: [1, 49], 28: [1, 48], 48: [1, 47] }, t(e, [2, 9]), { 17: [2, 22] }, t(W, [2, 23], { 32: 50, 33: 51, 35: 52, 37: C, 38: T }), t([17, 34, 37, 38], [2, 28]), t(e, [2, 14], { 15: [1, 55] }), t([27, 28], [2, 33]), t(e, [2, 8]), t(e, [2, 41]), t(e, [2, 42]), t(e, [2, 43]), t(W, [2, 24], { 33: 56, 36: [1, 57], 38: T }), t(W, [2, 25]), t(M, [2, 29]), t(W, [2, 32]), t(M, [2, 31]), { 16: 58, 17: [1, 59], 29: 32, 30: 33, 34: k }, t(W, [2, 26]), { 35: 60, 37: C }, { 17: [1, 61] }, t(e, [2, 13]), t(M, [2, 30]), t(e, [2, 12])],
220
+ table: [{ 3: 1, 4: [1, 2] }, { 1: [3] }, t(r, [2, 2], { 5: 3 }), { 6: [1, 4], 7: 5, 8: [1, 6], 9: 7, 10: [1, 8], 11: 9, 20: e, 22: f, 24: l, 26: p, 27: u, 28: o }, t(r, [2, 7], { 1: [2, 1] }), t(r, [2, 3]), { 9: 16, 11: 9, 20: e, 22: f, 24: l, 26: p, 27: u, 28: o }, t(r, [2, 5]), t(r, [2, 6]), t(r, [2, 11], { 12: 17, 39: 20, 15: [1, 18], 18: [1, 19], 41: h, 42: _, 43: m, 44: g, 45: R }), { 21: [1, 26] }, { 23: [1, 27] }, { 25: [1, 28] }, t(r, [2, 18]), t(y, [2, 19]), t(y, [2, 20]), t(r, [2, 4]), { 11: 29, 27: u, 28: o }, { 16: 30, 17: [1, 31], 29: 32, 30: 33, 34: k }, { 11: 35, 27: u, 28: o }, { 40: 36, 46: [1, 37], 47: [1, 38] }, t(w, [2, 34]), t(w, [2, 35]), t(w, [2, 36]), t(w, [2, 37]), t(w, [2, 38]), t(r, [2, 15]), t(r, [2, 16]), t(r, [2, 17]), { 13: [1, 39] }, { 17: [1, 40] }, t(r, [2, 10]), { 16: 41, 17: [2, 21], 29: 32, 30: 33, 34: k }, { 31: 42, 34: [1, 43] }, { 34: [2, 27] }, { 19: [1, 44] }, { 39: 45, 41: h, 42: _, 43: m, 44: g, 45: R }, t(Z, [2, 39]), t(Z, [2, 40]), { 14: 46, 27: [1, 49], 28: [1, 48], 48: [1, 47] }, t(r, [2, 9]), { 17: [2, 22] }, t(F, [2, 23], { 32: 50, 33: 51, 35: 52, 37: B, 38: T }), t([17, 34, 37, 38], [2, 28]), t(r, [2, 14], { 15: [1, 55] }), t([27, 28], [2, 33]), t(r, [2, 8]), t(r, [2, 41]), t(r, [2, 42]), t(r, [2, 43]), t(F, [2, 24], { 33: 56, 36: [1, 57], 38: T }), t(F, [2, 25]), t(A, [2, 29]), t(F, [2, 32]), t(A, [2, 31]), { 16: 58, 17: [1, 59], 29: 32, 30: 33, 34: k }, t(F, [2, 26]), { 35: 60, 37: B }, { 17: [1, 61] }, t(r, [2, 13]), t(A, [2, 30]), t(r, [2, 12])],
227
221
  defaultActions: { 34: [2, 27], 41: [2, 22] },
228
- parseError: function(a, n) {
222
+ parseError: function(i, n) {
229
223
  if (n.recoverable)
230
- this.trace(a);
224
+ this.trace(i);
231
225
  else {
232
- var c = new Error(a);
226
+ var c = new Error(i);
233
227
  throw c.hash = n, c;
234
228
  }
235
229
  },
236
- parse: function(a) {
237
- var n = this, c = [0], d = [], E = [null], i = [], K = this.table, s = "", Q = 0, st = 0, ft = 2, ot = 1, yt = i.slice.call(arguments, 1), N = Object.create(this.lexer), G = { yy: {} };
230
+ parse: function(i) {
231
+ var n = this, c = [0], d = [], E = [null], a = [], z = this.table, s = "", X = 0, nt = 0, ft = 2, st = 1, ut = a.slice.call(arguments, 1), N = Object.create(this.lexer), U = { yy: {} };
238
232
  for (var J in this.yy)
239
- Object.prototype.hasOwnProperty.call(this.yy, J) && (G.yy[J] = this.yy[J]);
240
- N.setInput(a, G.yy), G.yy.lexer = N, G.yy.parser = this, typeof N.yylloc == "undefined" && (N.yylloc = {});
241
- var $ = N.yylloc;
242
- i.push($);
243
- var pt = N.options && N.options.ranges;
244
- typeof G.yy.parseError == "function" ? this.parseError = G.yy.parseError : this.parseError = Object.getPrototypeOf(this).parseError;
245
- function _t() {
246
- var Y;
247
- return Y = d.pop() || N.lex() || ot, typeof Y != "number" && (Y instanceof Array && (d = Y, Y = d.pop()), Y = n.symbols_[Y] || Y), Y;
233
+ Object.prototype.hasOwnProperty.call(this.yy, J) && (U.yy[J] = this.yy[J]);
234
+ N.setInput(i, U.yy), U.yy.lexer = N, U.yy.parser = this, typeof N.yylloc == "undefined" && (N.yylloc = {});
235
+ var q = N.yylloc;
236
+ a.push(q);
237
+ var yt = N.options && N.options.ranges;
238
+ typeof U.yy.parseError == "function" ? this.parseError = U.yy.parseError : this.parseError = Object.getPrototypeOf(this).parseError;
239
+ function pt() {
240
+ var P;
241
+ return P = d.pop() || N.lex() || st, typeof P != "number" && (P instanceof Array && (d = P, P = d.pop()), P = n.symbols_[P] || P), P;
248
242
  }
249
- for (var w, H, D, tt, z = {}, j, P, lt, q; ; ) {
250
- if (H = c[c.length - 1], this.defaultActions[H] ? D = this.defaultActions[H] : ((w === null || typeof w == "undefined") && (w = _t()), D = K[H] && K[H][w]), typeof D == "undefined" || !D.length || !D[0]) {
251
- var et = "";
252
- q = [];
253
- for (j in K[H])
254
- this.terminals_[j] && j > ft && q.push("'" + this.terminals_[j] + "'");
255
- N.showPosition ? et = "Parse error on line " + (Q + 1) + `:
243
+ for (var I, G, S, $, H = {}, Q, C, ot, j; ; ) {
244
+ if (G = c[c.length - 1], this.defaultActions[G] ? S = this.defaultActions[G] : ((I === null || typeof I == "undefined") && (I = pt()), S = z[G] && z[G][I]), typeof S == "undefined" || !S.length || !S[0]) {
245
+ var tt = "";
246
+ j = [];
247
+ for (Q in z[G])
248
+ this.terminals_[Q] && Q > ft && j.push("'" + this.terminals_[Q] + "'");
249
+ N.showPosition ? tt = "Parse error on line " + (X + 1) + `:
256
250
  ` + N.showPosition() + `
257
- Expecting ` + q.join(", ") + ", got '" + (this.terminals_[w] || w) + "'" : et = "Parse error on line " + (Q + 1) + ": Unexpected " + (w == ot ? "end of input" : "'" + (this.terminals_[w] || w) + "'"), this.parseError(et, {
251
+ Expecting ` + j.join(", ") + ", got '" + (this.terminals_[I] || I) + "'" : tt = "Parse error on line " + (X + 1) + ": Unexpected " + (I == st ? "end of input" : "'" + (this.terminals_[I] || I) + "'"), this.parseError(tt, {
258
252
  text: N.match,
259
- token: this.terminals_[w] || w,
253
+ token: this.terminals_[I] || I,
260
254
  line: N.yylineno,
261
- loc: $,
262
- expected: q
255
+ loc: q,
256
+ expected: j
263
257
  });
264
258
  }
265
- if (D[0] instanceof Array && D.length > 1)
266
- throw new Error("Parse Error: multiple actions possible at state: " + H + ", token: " + w);
267
- switch (D[0]) {
259
+ if (S[0] instanceof Array && S.length > 1)
260
+ throw new Error("Parse Error: multiple actions possible at state: " + G + ", token: " + I);
261
+ switch (S[0]) {
268
262
  case 1:
269
- c.push(w), E.push(N.yytext), i.push(N.yylloc), c.push(D[1]), w = null, st = N.yyleng, s = N.yytext, Q = N.yylineno, $ = N.yylloc;
263
+ c.push(I), E.push(N.yytext), a.push(N.yylloc), c.push(S[1]), I = null, nt = N.yyleng, s = N.yytext, X = N.yylineno, q = N.yylloc;
270
264
  break;
271
265
  case 2:
272
- if (P = this.productions_[D[1]][1], z.$ = E[E.length - P], z._$ = {
273
- first_line: i[i.length - (P || 1)].first_line,
274
- last_line: i[i.length - 1].last_line,
275
- first_column: i[i.length - (P || 1)].first_column,
276
- last_column: i[i.length - 1].last_column
277
- }, pt && (z._$.range = [
278
- i[i.length - (P || 1)].range[0],
279
- i[i.length - 1].range[1]
280
- ]), tt = this.performAction.apply(z, [
266
+ if (C = this.productions_[S[1]][1], H.$ = E[E.length - C], H._$ = {
267
+ first_line: a[a.length - (C || 1)].first_line,
268
+ last_line: a[a.length - 1].last_line,
269
+ first_column: a[a.length - (C || 1)].first_column,
270
+ last_column: a[a.length - 1].last_column
271
+ }, yt && (H._$.range = [
272
+ a[a.length - (C || 1)].range[0],
273
+ a[a.length - 1].range[1]
274
+ ]), $ = this.performAction.apply(H, [
281
275
  s,
282
- st,
283
- Q,
284
- G.yy,
285
- D[1],
276
+ nt,
277
+ X,
278
+ U.yy,
279
+ S[1],
286
280
  E,
287
- i
288
- ].concat(yt)), typeof tt != "undefined")
289
- return tt;
290
- P && (c = c.slice(0, -1 * P * 2), E = E.slice(0, -1 * P), i = i.slice(0, -1 * P)), c.push(this.productions_[D[1]][0]), E.push(z.$), i.push(z._$), lt = K[c[c.length - 2]][c[c.length - 1]], c.push(lt);
281
+ a
282
+ ].concat(ut)), typeof $ != "undefined")
283
+ return $;
284
+ C && (c = c.slice(0, -1 * C * 2), E = E.slice(0, -1 * C), a = a.slice(0, -1 * C)), c.push(this.productions_[S[1]][0]), E.push(H.$), a.push(H._$), ot = z[c[c.length - 2]][c[c.length - 1]], c.push(ot);
291
285
  break;
292
286
  case 3:
293
287
  return !0;
@@ -296,7 +290,7 @@ Expecting ` + q.join(", ") + ", got '" + (this.terminals_[w] || w) + "'" : et =
296
290
  return !0;
297
291
  }
298
292
  }, b = function() {
299
- var S = {
293
+ var M = {
300
294
  EOF: 1,
301
295
  parseError: function(n, c) {
302
296
  if (this.yy.parser)
@@ -305,8 +299,8 @@ Expecting ` + q.join(", ") + ", got '" + (this.terminals_[w] || w) + "'" : et =
305
299
  throw new Error(n);
306
300
  },
307
301
  // resets the lexer, sets new input
308
- setInput: function(a, n) {
309
- return this.yy = n || this.yy || {}, this._input = a, this._more = this._backtrack = this.done = !1, this.yylineno = this.yyleng = 0, this.yytext = this.matched = this.match = "", this.conditionStack = ["INITIAL"], this.yylloc = {
302
+ setInput: function(i, n) {
303
+ return this.yy = n || this.yy || {}, this._input = i, this._more = this._backtrack = this.done = !1, this.yylineno = this.yyleng = 0, this.yytext = this.matched = this.match = "", this.conditionStack = ["INITIAL"], this.yylloc = {
310
304
  first_line: 1,
311
305
  first_column: 0,
312
306
  last_line: 1,
@@ -315,15 +309,15 @@ Expecting ` + q.join(", ") + ", got '" + (this.terminals_[w] || w) + "'" : et =
315
309
  },
316
310
  // consumes and returns one char from the input
317
311
  input: function() {
318
- var a = this._input[0];
319
- this.yytext += a, this.yyleng++, this.offset++, this.match += a, this.matched += a;
320
- var n = a.match(/(?:\r\n?|\n).*/g);
321
- return n ? (this.yylineno++, this.yylloc.last_line++) : this.yylloc.last_column++, this.options.ranges && this.yylloc.range[1]++, this._input = this._input.slice(1), a;
312
+ var i = this._input[0];
313
+ this.yytext += i, this.yyleng++, this.offset++, this.match += i, this.matched += i;
314
+ var n = i.match(/(?:\r\n?|\n).*/g);
315
+ return n ? (this.yylineno++, this.yylloc.last_line++) : this.yylloc.last_column++, this.options.ranges && this.yylloc.range[1]++, this._input = this._input.slice(1), i;
322
316
  },
323
317
  // unshifts one char (or a string) into the input
324
- unput: function(a) {
325
- var n = a.length, c = a.split(/(?:\r\n?|\n)/g);
326
- this._input = a + this._input, this.yytext = this.yytext.substr(0, this.yytext.length - n), this.offset -= n;
318
+ unput: function(i) {
319
+ var n = i.length, c = i.split(/(?:\r\n?|\n)/g);
320
+ this._input = i + this._input, this.yytext = this.yytext.substr(0, this.yytext.length - n), this.offset -= n;
327
321
  var d = this.match.split(/(?:\r\n?|\n)/g);
328
322
  this.match = this.match.substr(0, this.match.length - 1), this.matched = this.matched.substr(0, this.matched.length - 1), c.length - 1 && (this.yylineno -= c.length - 1);
329
323
  var E = this.yylloc.range;
@@ -352,27 +346,27 @@ Expecting ` + q.join(", ") + ", got '" + (this.terminals_[w] || w) + "'" : et =
352
346
  return this;
353
347
  },
354
348
  // retain first n characters of the match
355
- less: function(a) {
356
- this.unput(this.match.slice(a));
349
+ less: function(i) {
350
+ this.unput(this.match.slice(i));
357
351
  },
358
352
  // displays already matched input, i.e. for error messages
359
353
  pastInput: function() {
360
- var a = this.matched.substr(0, this.matched.length - this.match.length);
361
- return (a.length > 20 ? "..." : "") + a.substr(-20).replace(/\n/g, "");
354
+ var i = this.matched.substr(0, this.matched.length - this.match.length);
355
+ return (i.length > 20 ? "..." : "") + i.substr(-20).replace(/\n/g, "");
362
356
  },
363
357
  // displays upcoming input, i.e. for error messages
364
358
  upcomingInput: function() {
365
- var a = this.match;
366
- return a.length < 20 && (a += this._input.substr(0, 20 - a.length)), (a.substr(0, 20) + (a.length > 20 ? "..." : "")).replace(/\n/g, "");
359
+ var i = this.match;
360
+ return i.length < 20 && (i += this._input.substr(0, 20 - i.length)), (i.substr(0, 20) + (i.length > 20 ? "..." : "")).replace(/\n/g, "");
367
361
  },
368
362
  // displays the character position where the lexing error occurred, i.e. for error messages
369
363
  showPosition: function() {
370
- var a = this.pastInput(), n = new Array(a.length + 1).join("-");
371
- return a + this.upcomingInput() + `
364
+ var i = this.pastInput(), n = new Array(i.length + 1).join("-");
365
+ return i + this.upcomingInput() + `
372
366
  ` + n + "^";
373
367
  },
374
368
  // test the lexed token: return FALSE when not a match, otherwise return token
375
- test_match: function(a, n) {
369
+ test_match: function(i, n) {
376
370
  var c, d, E;
377
371
  if (this.options.backtrack_lexer && (E = {
378
372
  yylineno: this.yylineno,
@@ -393,16 +387,16 @@ Expecting ` + q.join(", ") + ", got '" + (this.terminals_[w] || w) + "'" : et =
393
387
  yy: this.yy,
394
388
  conditionStack: this.conditionStack.slice(0),
395
389
  done: this.done
396
- }, this.options.ranges && (E.yylloc.range = this.yylloc.range.slice(0))), d = a[0].match(/(?:\r\n?|\n).*/g), d && (this.yylineno += d.length), this.yylloc = {
390
+ }, this.options.ranges && (E.yylloc.range = this.yylloc.range.slice(0))), d = i[0].match(/(?:\r\n?|\n).*/g), d && (this.yylineno += d.length), this.yylloc = {
397
391
  first_line: this.yylloc.last_line,
398
392
  last_line: this.yylineno + 1,
399
393
  first_column: this.yylloc.last_column,
400
- last_column: d ? d[d.length - 1].length - d[d.length - 1].match(/\r?\n?/)[0].length : this.yylloc.last_column + a[0].length
401
- }, this.yytext += a[0], this.match += a[0], this.matches = a, this.yyleng = this.yytext.length, this.options.ranges && (this.yylloc.range = [this.offset, this.offset += this.yyleng]), this._more = !1, this._backtrack = !1, this._input = this._input.slice(a[0].length), this.matched += a[0], c = this.performAction.call(this, this.yy, this, n, this.conditionStack[this.conditionStack.length - 1]), this.done && this._input && (this.done = !1), c)
394
+ last_column: d ? d[d.length - 1].length - d[d.length - 1].match(/\r?\n?/)[0].length : this.yylloc.last_column + i[0].length
395
+ }, this.yytext += i[0], this.match += i[0], this.matches = i, this.yyleng = this.yytext.length, this.options.ranges && (this.yylloc.range = [this.offset, this.offset += this.yyleng]), this._more = !1, this._backtrack = !1, this._input = this._input.slice(i[0].length), this.matched += i[0], c = this.performAction.call(this, this.yy, this, n, this.conditionStack[this.conditionStack.length - 1]), this.done && this._input && (this.done = !1), c)
402
396
  return c;
403
397
  if (this._backtrack) {
404
- for (var i in E)
405
- this[i] = E[i];
398
+ for (var a in E)
399
+ this[a] = E[a];
406
400
  return !1;
407
401
  }
408
402
  return !1;
@@ -412,13 +406,13 @@ Expecting ` + q.join(", ") + ", got '" + (this.terminals_[w] || w) + "'" : et =
412
406
  if (this.done)
413
407
  return this.EOF;
414
408
  this._input || (this.done = !0);
415
- var a, n, c, d;
409
+ var i, n, c, d;
416
410
  this._more || (this.yytext = "", this.match = "");
417
- for (var E = this._currentRules(), i = 0; i < E.length; i++)
418
- if (c = this._input.match(this.rules[E[i]]), c && (!n || c[0].length > n[0].length)) {
419
- if (n = c, d = i, this.options.backtrack_lexer) {
420
- if (a = this.test_match(c, E[i]), a !== !1)
421
- return a;
411
+ for (var E = this._currentRules(), a = 0; a < E.length; a++)
412
+ if (c = this._input.match(this.rules[E[a]]), c && (!n || c[0].length > n[0].length)) {
413
+ if (n = c, d = a, this.options.backtrack_lexer) {
414
+ if (i = this.test_match(c, E[a]), i !== !1)
415
+ return i;
422
416
  if (this._backtrack) {
423
417
  n = !1;
424
418
  continue;
@@ -427,7 +421,7 @@ Expecting ` + q.join(", ") + ", got '" + (this.terminals_[w] || w) + "'" : et =
427
421
  } else if (!this.options.flex)
428
422
  break;
429
423
  }
430
- return n ? (a = this.test_match(n, E[d]), a !== !1 ? a : !1) : this._input === "" ? this.EOF : this.parseError("Lexical error on line " + (this.yylineno + 1) + `. Unrecognized text.
424
+ return n ? (i = this.test_match(n, E[d]), i !== !1 ? i : !1) : this._input === "" ? this.EOF : this.parseError("Lexical error on line " + (this.yylineno + 1) + `. Unrecognized text.
431
425
  ` + this.showPosition(), {
432
426
  text: "",
433
427
  token: null,
@@ -586,59 +580,59 @@ Expecting ` + q.join(", ") + ", got '" + (this.terminals_[w] || w) + "'" : et =
586
580
  rules: [/^(?:accTitle\s*:\s*)/i, /^(?:(?!\n||)*[^\n]*)/i, /^(?:accDescr\s*:\s*)/i, /^(?:(?!\n||)*[^\n]*)/i, /^(?:accDescr\s*\{\s*)/i, /^(?:[\}])/i, /^(?:[^\}]*)/i, /^(?:[\n]+)/i, /^(?:\s+)/i, /^(?:[\s]+)/i, /^(?:"[^"%\r\n\v\b\\]+")/i, /^(?:"[^"]*")/i, /^(?:erDiagram\b)/i, /^(?:\{)/i, /^(?:,)/i, /^(?:\s+)/i, /^(?:\b((?:PK)|(?:FK)|(?:UK))\b)/i, /^(?:(.*?)[~](.*?)*[~])/i, /^(?:[\*A-Za-z_][A-Za-z0-9\-_\[\]\(\)]*)/i, /^(?:"[^"]*")/i, /^(?:[\n]+)/i, /^(?:\})/i, /^(?:.)/i, /^(?:\[)/i, /^(?:\])/i, /^(?:one or zero\b)/i, /^(?:one or more\b)/i, /^(?:one or many\b)/i, /^(?:1\+)/i, /^(?:\|o\b)/i, /^(?:zero or one\b)/i, /^(?:zero or more\b)/i, /^(?:zero or many\b)/i, /^(?:0\+)/i, /^(?:\}o\b)/i, /^(?:many\(0\))/i, /^(?:many\(1\))/i, /^(?:many\b)/i, /^(?:\}\|)/i, /^(?:one\b)/i, /^(?:only one\b)/i, /^(?:1\b)/i, /^(?:\|\|)/i, /^(?:o\|)/i, /^(?:o\{)/i, /^(?:\|\{)/i, /^(?:\s*u\b)/i, /^(?:\.\.)/i, /^(?:--)/i, /^(?:to\b)/i, /^(?:optionally to\b)/i, /^(?:\.-)/i, /^(?:-\.)/i, /^(?:[A-Za-z_][A-Za-z0-9\-_]*)/i, /^(?:.)/i, /^(?:$)/i],
587
581
  conditions: { acc_descr_multiline: { rules: [5, 6], inclusive: !1 }, acc_descr: { rules: [3], inclusive: !1 }, acc_title: { rules: [1], inclusive: !1 }, block: { rules: [14, 15, 16, 17, 18, 19, 20, 21, 22], inclusive: !1 }, INITIAL: { rules: [0, 2, 4, 7, 8, 9, 10, 11, 12, 13, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55], inclusive: !0 } }
588
582
  };
589
- return S;
583
+ return M;
590
584
  }();
591
585
  O.lexer = b;
592
- function v() {
586
+ function D() {
593
587
  this.yy = {};
594
588
  }
595
- return v.prototype = O, O.Parser = v, new v();
589
+ return D.prototype = O, O.Parser = D, new D();
596
590
  }();
597
591
  at.parser = at;
598
- const Gt = at;
599
- let U = {}, nt = [];
600
- const Ht = {
592
+ const Ut = at;
593
+ let W = {}, it = [];
594
+ const Gt = {
601
595
  ZERO_OR_ONE: "ZERO_OR_ONE",
602
596
  ZERO_OR_MORE: "ZERO_OR_MORE",
603
597
  ONE_OR_MORE: "ONE_OR_MORE",
604
598
  ONLY_ONE: "ONLY_ONE",
605
599
  MD_PARENT: "MD_PARENT"
606
- }, zt = {
600
+ }, Ht = {
607
601
  NON_IDENTIFYING: "NON_IDENTIFYING",
608
602
  IDENTIFYING: "IDENTIFYING"
609
- }, dt = function(t, e = void 0) {
610
- return U[t] === void 0 ? (U[t] = { attributes: [], alias: e }, V.info("Added new entity :", t)) : U[t] && !U[t].alias && e && (U[t].alias = e, V.info(`Add alias '${e}' to entity '${t}'`)), U[t];
611
- }, Kt = () => U, Vt = function(t, e) {
612
- let r = dt(t), u;
613
- for (u = e.length - 1; u >= 0; u--)
614
- r.attributes.push(e[u]), V.debug("Added attribute ", e[u].attributeName);
615
- }, Xt = function(t, e, r, u) {
603
+ }, ht = function(t, r = void 0) {
604
+ return W[t] === void 0 ? (W[t] = { attributes: [], alias: r }, K.info("Added new entity :", t)) : W[t] && !W[t].alias && r && (W[t].alias = r, K.info(`Add alias '${r}' to entity '${t}'`)), W[t];
605
+ }, zt = () => W, Kt = function(t, r) {
606
+ let e = ht(t), f;
607
+ for (f = r.length - 1; f >= 0; f--)
608
+ e.attributes.push(r[f]), K.debug("Added attribute ", r[f].attributeName);
609
+ }, Vt = function(t, r, e, f) {
616
610
  let l = {
617
611
  entityA: t,
618
- roleA: e,
619
- entityB: r,
620
- relSpec: u
612
+ roleA: r,
613
+ entityB: e,
614
+ relSpec: f
621
615
  };
622
- nt.push(l), V.debug("Added new relationship :", l);
623
- }, Qt = () => nt, jt = function() {
624
- U = {}, nt = [], Ot();
625
- }, qt = {
626
- Cardinality: Ht,
627
- Identification: zt,
628
- getConfig: () => Z().er,
629
- addEntity: dt,
630
- addAttributes: Vt,
631
- getEntities: Kt,
632
- addRelationship: Xt,
633
- getRelationships: Qt,
634
- clear: jt,
616
+ it.push(l), K.debug("Added new relationship :", l);
617
+ }, Xt = () => it, Qt = function() {
618
+ W = {}, it = [], Ot();
619
+ }, jt = {
620
+ Cardinality: Gt,
621
+ Identification: Ht,
622
+ getConfig: () => Y().er,
623
+ addEntity: ht,
624
+ addAttributes: Kt,
625
+ getEntities: zt,
626
+ addRelationship: Vt,
627
+ getRelationships: Xt,
628
+ clear: Qt,
635
629
  setAccTitle: Et,
636
630
  getAccTitle: mt,
637
631
  setAccDescription: gt,
638
632
  getAccDescription: kt,
639
633
  setDiagramTitle: xt,
640
634
  getDiagramTitle: Rt
641
- }, L = {
635
+ }, v = {
642
636
  ONLY_ONE_START: "ONLY_ONE_START",
643
637
  ONLY_ONE_END: "ONLY_ONE_END",
644
638
  ZERO_OR_ONE_START: "ZERO_OR_ONE_START",
@@ -649,197 +643,197 @@ const Ht = {
649
643
  ZERO_OR_MORE_END: "ZERO_OR_MORE_END",
650
644
  MD_PARENT_END: "MD_PARENT_END",
651
645
  MD_PARENT_START: "MD_PARENT_START"
652
- }, Jt = function(t, e) {
653
- let r;
654
- t.append("defs").append("marker").attr("id", L.MD_PARENT_START).attr("refX", 0).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"), t.append("defs").append("marker").attr("id", L.MD_PARENT_END).attr("refX", 19).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"), t.append("defs").append("marker").attr("id", L.ONLY_ONE_START).attr("refX", 0).attr("refY", 9).attr("markerWidth", 18).attr("markerHeight", 18).attr("orient", "auto").append("path").attr("stroke", e.stroke).attr("fill", "none").attr("d", "M9,0 L9,18 M15,0 L15,18"), t.append("defs").append("marker").attr("id", L.ONLY_ONE_END).attr("refX", 18).attr("refY", 9).attr("markerWidth", 18).attr("markerHeight", 18).attr("orient", "auto").append("path").attr("stroke", e.stroke).attr("fill", "none").attr("d", "M3,0 L3,18 M9,0 L9,18"), r = t.append("defs").append("marker").attr("id", L.ZERO_OR_ONE_START).attr("refX", 0).attr("refY", 9).attr("markerWidth", 30).attr("markerHeight", 18).attr("orient", "auto"), r.append("circle").attr("stroke", e.stroke).attr("fill", "white").attr("cx", 21).attr("cy", 9).attr("r", 6), r.append("path").attr("stroke", e.stroke).attr("fill", "none").attr("d", "M9,0 L9,18"), r = t.append("defs").append("marker").attr("id", L.ZERO_OR_ONE_END).attr("refX", 30).attr("refY", 9).attr("markerWidth", 30).attr("markerHeight", 18).attr("orient", "auto"), r.append("circle").attr("stroke", e.stroke).attr("fill", "white").attr("cx", 9).attr("cy", 9).attr("r", 6), r.append("path").attr("stroke", e.stroke).attr("fill", "none").attr("d", "M21,0 L21,18"), t.append("defs").append("marker").attr("id", L.ONE_OR_MORE_START).attr("refX", 18).attr("refY", 18).attr("markerWidth", 45).attr("markerHeight", 36).attr("orient", "auto").append("path").attr("stroke", e.stroke).attr("fill", "none").attr("d", "M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27"), t.append("defs").append("marker").attr("id", L.ONE_OR_MORE_END).attr("refX", 27).attr("refY", 18).attr("markerWidth", 45).attr("markerHeight", 36).attr("orient", "auto").append("path").attr("stroke", e.stroke).attr("fill", "none").attr("d", "M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18"), r = t.append("defs").append("marker").attr("id", L.ZERO_OR_MORE_START).attr("refX", 18).attr("refY", 18).attr("markerWidth", 57).attr("markerHeight", 36).attr("orient", "auto"), r.append("circle").attr("stroke", e.stroke).attr("fill", "white").attr("cx", 48).attr("cy", 18).attr("r", 6), r.append("path").attr("stroke", e.stroke).attr("fill", "none").attr("d", "M0,18 Q18,0 36,18 Q18,36 0,18"), r = t.append("defs").append("marker").attr("id", L.ZERO_OR_MORE_END).attr("refX", 39).attr("refY", 18).attr("markerWidth", 57).attr("markerHeight", 36).attr("orient", "auto"), r.append("circle").attr("stroke", e.stroke).attr("fill", "white").attr("cx", 9).attr("cy", 18).attr("r", 6), r.append("path").attr("stroke", e.stroke).attr("fill", "none").attr("d", "M21,18 Q39,0 57,18 Q39,36 21,18");
655
- }, B = {
656
- ERMarkers: L,
646
+ }, Jt = function(t, r) {
647
+ let e;
648
+ t.append("defs").append("marker").attr("id", v.MD_PARENT_START).attr("refX", 0).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"), t.append("defs").append("marker").attr("id", v.MD_PARENT_END).attr("refX", 19).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"), t.append("defs").append("marker").attr("id", v.ONLY_ONE_START).attr("refX", 0).attr("refY", 9).attr("markerWidth", 18).attr("markerHeight", 18).attr("orient", "auto").append("path").attr("stroke", r.stroke).attr("fill", "none").attr("d", "M9,0 L9,18 M15,0 L15,18"), t.append("defs").append("marker").attr("id", v.ONLY_ONE_END).attr("refX", 18).attr("refY", 9).attr("markerWidth", 18).attr("markerHeight", 18).attr("orient", "auto").append("path").attr("stroke", r.stroke).attr("fill", "none").attr("d", "M3,0 L3,18 M9,0 L9,18"), e = t.append("defs").append("marker").attr("id", v.ZERO_OR_ONE_START).attr("refX", 0).attr("refY", 9).attr("markerWidth", 30).attr("markerHeight", 18).attr("orient", "auto"), e.append("circle").attr("stroke", r.stroke).attr("fill", "white").attr("cx", 21).attr("cy", 9).attr("r", 6), e.append("path").attr("stroke", r.stroke).attr("fill", "none").attr("d", "M9,0 L9,18"), e = t.append("defs").append("marker").attr("id", v.ZERO_OR_ONE_END).attr("refX", 30).attr("refY", 9).attr("markerWidth", 30).attr("markerHeight", 18).attr("orient", "auto"), e.append("circle").attr("stroke", r.stroke).attr("fill", "white").attr("cx", 9).attr("cy", 9).attr("r", 6), e.append("path").attr("stroke", r.stroke).attr("fill", "none").attr("d", "M21,0 L21,18"), t.append("defs").append("marker").attr("id", v.ONE_OR_MORE_START).attr("refX", 18).attr("refY", 18).attr("markerWidth", 45).attr("markerHeight", 36).attr("orient", "auto").append("path").attr("stroke", r.stroke).attr("fill", "none").attr("d", "M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27"), t.append("defs").append("marker").attr("id", v.ONE_OR_MORE_END).attr("refX", 27).attr("refY", 18).attr("markerWidth", 45).attr("markerHeight", 36).attr("orient", "auto").append("path").attr("stroke", r.stroke).attr("fill", "none").attr("d", "M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18"), e = t.append("defs").append("marker").attr("id", v.ZERO_OR_MORE_START).attr("refX", 18).attr("refY", 18).attr("markerWidth", 57).attr("markerHeight", 36).attr("orient", "auto"), e.append("circle").attr("stroke", r.stroke).attr("fill", "white").attr("cx", 48).attr("cy", 18).attr("r", 6), e.append("path").attr("stroke", r.stroke).attr("fill", "none").attr("d", "M0,18 Q18,0 36,18 Q18,36 0,18"), e = t.append("defs").append("marker").attr("id", v.ZERO_OR_MORE_END).attr("refX", 39).attr("refY", 18).attr("markerWidth", 57).attr("markerHeight", 36).attr("orient", "auto"), e.append("circle").attr("stroke", r.stroke).attr("fill", "white").attr("cx", 9).attr("cy", 18).attr("r", 6), e.append("path").attr("stroke", r.stroke).attr("fill", "none").attr("d", "M21,18 Q39,0 57,18 Q39,36 21,18");
649
+ }, L = {
650
+ ERMarkers: v,
657
651
  insertMarkers: Jt
658
- }, $t = /[^\dA-Za-z](\W)*/g;
659
- let x = {}, X = /* @__PURE__ */ new Map();
660
- const te = function(t) {
661
- const e = Object.keys(t);
662
- for (const r of e)
663
- x[r] = t[r];
664
- }, ee = (t, e, r) => {
665
- const u = x.entityPadding / 3, l = x.entityPadding / 3, p = x.fontSize * 0.85, f = e.node().getBBox(), o = [];
666
- let h = !1, _ = !1, m = 0, g = 0, R = 0, y = 0, k = f.height + u * 2, I = 1;
667
- r.forEach((T) => {
652
+ }, qt = /[^\dA-Za-z](\W)*/g;
653
+ let x = {}, V = /* @__PURE__ */ new Map();
654
+ const $t = function(t) {
655
+ const r = Object.keys(t);
656
+ for (const e of r)
657
+ x[e] = t[e];
658
+ }, te = (t, r, e) => {
659
+ const f = x.entityPadding / 3, l = x.entityPadding / 3, p = x.fontSize * 0.85, u = r.node().getBBox(), o = [];
660
+ let h = !1, _ = !1, m = 0, g = 0, R = 0, y = 0, k = u.height + f * 2, w = 1;
661
+ e.forEach((T) => {
668
662
  T.attributeKeyTypeList !== void 0 && T.attributeKeyTypeList.length > 0 && (h = !0), T.attributeComment !== void 0 && (_ = !0);
669
- }), r.forEach((T) => {
670
- const M = `${e.node().id}-attr-${I}`;
663
+ }), e.forEach((T) => {
664
+ const A = `${r.node().id}-attr-${w}`;
671
665
  let O = 0;
672
- const b = At(T.attributeType), v = t.append("text").classed("er entityLabel", !0).attr("id", `${M}-type`).attr("x", 0).attr("y", 0).style("dominant-baseline", "middle").style("text-anchor", "left").style("font-family", Z().fontFamily).style("font-size", p + "px").text(b), S = t.append("text").classed("er entityLabel", !0).attr("id", `${M}-name`).attr("x", 0).attr("y", 0).style("dominant-baseline", "middle").style("text-anchor", "left").style("font-family", Z().fontFamily).style("font-size", p + "px").text(T.attributeName), a = {};
673
- a.tn = v, a.nn = S;
674
- const n = v.node().getBBox(), c = S.node().getBBox();
666
+ const b = At(T.attributeType), D = t.append("text").classed("er entityLabel", !0).attr("id", `${A}-type`).attr("x", 0).attr("y", 0).style("dominant-baseline", "middle").style("text-anchor", "left").style("font-family", Y().fontFamily).style("font-size", p + "px").text(b), M = t.append("text").classed("er entityLabel", !0).attr("id", `${A}-name`).attr("x", 0).attr("y", 0).style("dominant-baseline", "middle").style("text-anchor", "left").style("font-family", Y().fontFamily).style("font-size", p + "px").text(T.attributeName), i = {};
667
+ i.tn = D, i.nn = M;
668
+ const n = D.node().getBBox(), c = M.node().getBBox();
675
669
  if (m = Math.max(m, n.width), g = Math.max(g, c.width), O = Math.max(n.height, c.height), h) {
676
- const d = T.attributeKeyTypeList !== void 0 ? T.attributeKeyTypeList.join(",") : "", E = t.append("text").classed("er entityLabel", !0).attr("id", `${M}-key`).attr("x", 0).attr("y", 0).style("dominant-baseline", "middle").style("text-anchor", "left").style("font-family", Z().fontFamily).style("font-size", p + "px").text(d);
677
- a.kn = E;
678
- const i = E.node().getBBox();
679
- R = Math.max(R, i.width), O = Math.max(O, i.height);
670
+ const d = T.attributeKeyTypeList !== void 0 ? T.attributeKeyTypeList.join(",") : "", E = t.append("text").classed("er entityLabel", !0).attr("id", `${A}-key`).attr("x", 0).attr("y", 0).style("dominant-baseline", "middle").style("text-anchor", "left").style("font-family", Y().fontFamily).style("font-size", p + "px").text(d);
671
+ i.kn = E;
672
+ const a = E.node().getBBox();
673
+ R = Math.max(R, a.width), O = Math.max(O, a.height);
680
674
  }
681
675
  if (_) {
682
- const d = t.append("text").classed("er entityLabel", !0).attr("id", `${M}-comment`).attr("x", 0).attr("y", 0).style("dominant-baseline", "middle").style("text-anchor", "left").style("font-family", Z().fontFamily).style("font-size", p + "px").text(T.attributeComment || "");
683
- a.cn = d;
676
+ const d = t.append("text").classed("er entityLabel", !0).attr("id", `${A}-comment`).attr("x", 0).attr("y", 0).style("dominant-baseline", "middle").style("text-anchor", "left").style("font-family", Y().fontFamily).style("font-size", p + "px").text(T.attributeComment || "");
677
+ i.cn = d;
684
678
  const E = d.node().getBBox();
685
679
  y = Math.max(y, E.width), O = Math.max(O, E.height);
686
680
  }
687
- a.height = O, o.push(a), k += O + u * 2, I += 1;
681
+ i.height = O, o.push(i), k += O + f * 2, w += 1;
688
682
  });
689
- let F = 4;
690
- h && (F += 2), _ && (F += 2);
691
- const W = m + g + R + y, C = {
683
+ let Z = 4;
684
+ h && (Z += 2), _ && (Z += 2);
685
+ const F = m + g + R + y, B = {
692
686
  width: Math.max(
693
687
  x.minEntityWidth,
694
688
  Math.max(
695
- f.width + x.entityPadding * 2,
696
- W + l * F
689
+ u.width + x.entityPadding * 2,
690
+ F + l * Z
697
691
  )
698
692
  ),
699
- height: r.length > 0 ? k : Math.max(x.minEntityHeight, f.height + x.entityPadding * 2)
693
+ height: e.length > 0 ? k : Math.max(x.minEntityHeight, u.height + x.entityPadding * 2)
700
694
  };
701
- if (r.length > 0) {
695
+ if (e.length > 0) {
702
696
  const T = Math.max(
703
697
  0,
704
- (C.width - W - l * F) / (F / 2)
698
+ (B.width - F - l * Z) / (Z / 2)
705
699
  );
706
- e.attr(
700
+ r.attr(
707
701
  "transform",
708
- "translate(" + C.width / 2 + "," + (u + f.height / 2) + ")"
702
+ "translate(" + B.width / 2 + "," + (f + u.height / 2) + ")"
709
703
  );
710
- let M = f.height + u * 2, O = "attributeBoxOdd";
704
+ let A = u.height + f * 2, O = "attributeBoxOdd";
711
705
  o.forEach((b) => {
712
- const v = M + u + b.height / 2;
713
- b.tn.attr("transform", "translate(" + l + "," + v + ")");
714
- const S = t.insert("rect", "#" + b.tn.node().id).classed(`er ${O}`, !0).attr("x", 0).attr("y", M).attr("width", m + l * 2 + T).attr("height", b.height + u * 2), a = parseFloat(S.attr("x")) + parseFloat(S.attr("width"));
706
+ const D = A + f + b.height / 2;
707
+ b.tn.attr("transform", "translate(" + l + "," + D + ")");
708
+ const M = t.insert("rect", "#" + b.tn.node().id).classed(`er ${O}`, !0).attr("x", 0).attr("y", A).attr("width", m + l * 2 + T).attr("height", b.height + f * 2), i = parseFloat(M.attr("x")) + parseFloat(M.attr("width"));
715
709
  b.nn.attr(
716
710
  "transform",
717
- "translate(" + (a + l) + "," + v + ")"
711
+ "translate(" + (i + l) + "," + D + ")"
718
712
  );
719
- const n = t.insert("rect", "#" + b.nn.node().id).classed(`er ${O}`, !0).attr("x", a).attr("y", M).attr("width", g + l * 2 + T).attr("height", b.height + u * 2);
713
+ const n = t.insert("rect", "#" + b.nn.node().id).classed(`er ${O}`, !0).attr("x", i).attr("y", A).attr("width", g + l * 2 + T).attr("height", b.height + f * 2);
720
714
  let c = parseFloat(n.attr("x")) + parseFloat(n.attr("width"));
721
715
  if (h) {
722
716
  b.kn.attr(
723
717
  "transform",
724
- "translate(" + (c + l) + "," + v + ")"
718
+ "translate(" + (c + l) + "," + D + ")"
725
719
  );
726
- const d = t.insert("rect", "#" + b.kn.node().id).classed(`er ${O}`, !0).attr("x", c).attr("y", M).attr("width", R + l * 2 + T).attr("height", b.height + u * 2);
720
+ const d = t.insert("rect", "#" + b.kn.node().id).classed(`er ${O}`, !0).attr("x", c).attr("y", A).attr("width", R + l * 2 + T).attr("height", b.height + f * 2);
727
721
  c = parseFloat(d.attr("x")) + parseFloat(d.attr("width"));
728
722
  }
729
723
  _ && (b.cn.attr(
730
724
  "transform",
731
- "translate(" + (c + l) + "," + v + ")"
732
- ), t.insert("rect", "#" + b.cn.node().id).classed(`er ${O}`, "true").attr("x", c).attr("y", M).attr("width", y + l * 2 + T).attr("height", b.height + u * 2)), M += b.height + u * 2, O = O === "attributeBoxOdd" ? "attributeBoxEven" : "attributeBoxOdd";
725
+ "translate(" + (c + l) + "," + D + ")"
726
+ ), t.insert("rect", "#" + b.cn.node().id).classed(`er ${O}`, "true").attr("x", c).attr("y", A).attr("width", y + l * 2 + T).attr("height", b.height + f * 2)), A += b.height + f * 2, O = O === "attributeBoxOdd" ? "attributeBoxEven" : "attributeBoxOdd";
733
727
  });
734
728
  } else
735
- C.height = Math.max(x.minEntityHeight, k), e.attr("transform", "translate(" + C.width / 2 + "," + C.height / 2 + ")");
736
- return C;
737
- }, re = function(t, e, r) {
738
- const u = Object.keys(e);
729
+ B.height = Math.max(x.minEntityHeight, k), r.attr("transform", "translate(" + B.width / 2 + "," + B.height / 2 + ")");
730
+ return B;
731
+ }, ee = function(t, r, e) {
732
+ const f = Object.keys(r);
739
733
  let l;
740
- return u.forEach(function(p) {
734
+ return f.forEach(function(p) {
741
735
  var k;
742
- const f = le(p, "entity");
743
- X.set(p, f);
744
- const o = t.append("g").attr("id", f);
745
- l = l === void 0 ? f : l;
746
- const h = "text-" + f, _ = o.append("text").classed("er entityLabel", !0).attr("id", h).attr("x", 0).attr("y", 0).style("dominant-baseline", "middle").style("text-anchor", "middle").style("font-family", Z().fontFamily).style("font-size", x.fontSize + "px").text((k = e[p].alias) != null ? k : p), { width: m, height: g } = ee(
736
+ const u = oe(p, "entity");
737
+ V.set(p, u);
738
+ const o = t.append("g").attr("id", u);
739
+ l = l === void 0 ? u : l;
740
+ const h = "text-" + u, _ = o.append("text").classed("er entityLabel", !0).attr("id", h).attr("x", 0).attr("y", 0).style("dominant-baseline", "middle").style("text-anchor", "middle").style("font-family", Y().fontFamily).style("font-size", x.fontSize + "px").text((k = r[p].alias) != null ? k : p), { width: m, height: g } = te(
747
741
  o,
748
742
  _,
749
- e[p].attributes
743
+ r[p].attributes
750
744
  ), y = o.insert("rect", "#" + h).classed("er entityBox", !0).attr("x", 0).attr("y", 0).attr("width", m).attr("height", g).node().getBBox();
751
- r.setNode(f, {
745
+ e.setNode(u, {
752
746
  width: y.width,
753
747
  height: y.height,
754
748
  shape: "rect",
755
- id: f
749
+ id: u
756
750
  });
757
751
  }), l;
758
- }, ie = function(t, e) {
759
- e.nodes().forEach(function(r) {
760
- r !== void 0 && e.node(r) !== void 0 && t.select("#" + r).attr(
752
+ }, re = function(t, r) {
753
+ r.nodes().forEach(function(e) {
754
+ e !== void 0 && r.node(e) !== void 0 && t.select("#" + e).attr(
761
755
  "transform",
762
- "translate(" + (e.node(r).x - e.node(r).width / 2) + "," + (e.node(r).y - e.node(r).height / 2) + " )"
756
+ "translate(" + (r.node(e).x - r.node(e).width / 2) + "," + (r.node(e).y - r.node(e).height / 2) + " )"
763
757
  );
764
758
  });
765
- }, ut = function(t) {
759
+ }, dt = function(t) {
766
760
  return (t.entityA + t.roleA + t.entityB).replace(/\s/g, "");
767
- }, ae = function(t, e) {
768
- return t.forEach(function(r) {
769
- e.setEdge(
770
- X.get(r.entityA),
771
- X.get(r.entityB),
772
- { relationship: r },
773
- ut(r)
761
+ }, ae = function(t, r) {
762
+ return t.forEach(function(e) {
763
+ r.setEdge(
764
+ V.get(e.entityA),
765
+ V.get(e.entityB),
766
+ { relationship: e },
767
+ dt(e)
774
768
  );
775
769
  }), t;
776
770
  };
777
- let ct = 0;
778
- const ne = function(t, e, r, u, l) {
779
- ct++;
780
- const p = r.edge(
781
- X.get(e.entityA),
782
- X.get(e.entityB),
783
- ut(e)
784
- ), f = wt().x(function(k) {
771
+ let lt = 0;
772
+ const ie = function(t, r, e, f, l) {
773
+ lt++;
774
+ const p = e.edge(
775
+ V.get(r.entityA),
776
+ V.get(r.entityB),
777
+ dt(r)
778
+ ), u = wt().x(function(k) {
785
779
  return k.x;
786
780
  }).y(function(k) {
787
781
  return k.y;
788
- }).curve(Tt), o = t.insert("path", "#" + u).classed("er relationshipLine", !0).attr("d", f(p.points)).style("stroke", x.stroke).style("fill", "none");
789
- e.relSpec.relType === l.db.Identification.NON_IDENTIFYING && o.attr("stroke-dasharray", "8,8");
782
+ }).curve(Tt), o = t.insert("path", "#" + f).classed("er relationshipLine", !0).attr("d", u(p.points)).style("stroke", x.stroke).style("fill", "none");
783
+ r.relSpec.relType === l.db.Identification.NON_IDENTIFYING && o.attr("stroke-dasharray", "8,8");
790
784
  let h = "";
791
- switch (x.arrowMarkerAbsolute && (h = window.location.protocol + "//" + window.location.host + window.location.pathname + window.location.search, h = h.replace(/\(/g, "\\("), h = h.replace(/\)/g, "\\)")), e.relSpec.cardA) {
785
+ switch (x.arrowMarkerAbsolute && (h = window.location.protocol + "//" + window.location.host + window.location.pathname + window.location.search, h = h.replace(/\(/g, "\\("), h = h.replace(/\)/g, "\\)")), r.relSpec.cardA) {
792
786
  case l.db.Cardinality.ZERO_OR_ONE:
793
- o.attr("marker-end", "url(" + h + "#" + B.ERMarkers.ZERO_OR_ONE_END + ")");
787
+ o.attr("marker-end", "url(" + h + "#" + L.ERMarkers.ZERO_OR_ONE_END + ")");
794
788
  break;
795
789
  case l.db.Cardinality.ZERO_OR_MORE:
796
- o.attr("marker-end", "url(" + h + "#" + B.ERMarkers.ZERO_OR_MORE_END + ")");
790
+ o.attr("marker-end", "url(" + h + "#" + L.ERMarkers.ZERO_OR_MORE_END + ")");
797
791
  break;
798
792
  case l.db.Cardinality.ONE_OR_MORE:
799
- o.attr("marker-end", "url(" + h + "#" + B.ERMarkers.ONE_OR_MORE_END + ")");
793
+ o.attr("marker-end", "url(" + h + "#" + L.ERMarkers.ONE_OR_MORE_END + ")");
800
794
  break;
801
795
  case l.db.Cardinality.ONLY_ONE:
802
- o.attr("marker-end", "url(" + h + "#" + B.ERMarkers.ONLY_ONE_END + ")");
796
+ o.attr("marker-end", "url(" + h + "#" + L.ERMarkers.ONLY_ONE_END + ")");
803
797
  break;
804
798
  case l.db.Cardinality.MD_PARENT:
805
- o.attr("marker-end", "url(" + h + "#" + B.ERMarkers.MD_PARENT_END + ")");
799
+ o.attr("marker-end", "url(" + h + "#" + L.ERMarkers.MD_PARENT_END + ")");
806
800
  break;
807
801
  }
808
- switch (e.relSpec.cardB) {
802
+ switch (r.relSpec.cardB) {
809
803
  case l.db.Cardinality.ZERO_OR_ONE:
810
804
  o.attr(
811
805
  "marker-start",
812
- "url(" + h + "#" + B.ERMarkers.ZERO_OR_ONE_START + ")"
806
+ "url(" + h + "#" + L.ERMarkers.ZERO_OR_ONE_START + ")"
813
807
  );
814
808
  break;
815
809
  case l.db.Cardinality.ZERO_OR_MORE:
816
810
  o.attr(
817
811
  "marker-start",
818
- "url(" + h + "#" + B.ERMarkers.ZERO_OR_MORE_START + ")"
812
+ "url(" + h + "#" + L.ERMarkers.ZERO_OR_MORE_START + ")"
819
813
  );
820
814
  break;
821
815
  case l.db.Cardinality.ONE_OR_MORE:
822
816
  o.attr(
823
817
  "marker-start",
824
- "url(" + h + "#" + B.ERMarkers.ONE_OR_MORE_START + ")"
818
+ "url(" + h + "#" + L.ERMarkers.ONE_OR_MORE_START + ")"
825
819
  );
826
820
  break;
827
821
  case l.db.Cardinality.ONLY_ONE:
828
- o.attr("marker-start", "url(" + h + "#" + B.ERMarkers.ONLY_ONE_START + ")");
822
+ o.attr("marker-start", "url(" + h + "#" + L.ERMarkers.ONLY_ONE_START + ")");
829
823
  break;
830
824
  case l.db.Cardinality.MD_PARENT:
831
- o.attr("marker-start", "url(" + h + "#" + B.ERMarkers.MD_PARENT_START + ")");
825
+ o.attr("marker-start", "url(" + h + "#" + L.ERMarkers.MD_PARENT_START + ")");
832
826
  break;
833
827
  }
834
- const _ = o.node().getTotalLength(), m = o.node().getPointAtLength(_ * 0.5), g = "rel" + ct, y = t.append("text").classed("er relationshipLabel", !0).attr("id", g).attr("x", m.x).attr("y", m.y).style("text-anchor", "middle").style("dominant-baseline", "middle").style("font-family", Z().fontFamily).style("font-size", x.fontSize + "px").text(e.roleA).node().getBBox();
828
+ const _ = o.node().getTotalLength(), m = o.node().getPointAtLength(_ * 0.5), g = "rel" + lt, y = t.append("text").classed("er relationshipLabel", !0).attr("id", g).attr("x", m.x).attr("y", m.y).style("text-anchor", "middle").style("dominant-baseline", "middle").style("font-family", Y().fontFamily).style("font-size", x.fontSize + "px").text(r.roleA).node().getBBox();
835
829
  t.insert("rect", "#" + g).classed("er relationshipLabelBox", !0).attr("x", m.x - y.width / 2).attr("y", m.y - y.height / 2).attr("width", y.width).attr("height", y.height);
836
- }, se = function(t, e, r, u) {
837
- x = Z().er, V.info("Drawing ER diagram");
838
- const l = Z().securityLevel;
830
+ }, ne = function(t, r, e, f) {
831
+ x = Y().er, K.info("Drawing ER diagram");
832
+ const l = Y().securityLevel;
839
833
  let p;
840
- l === "sandbox" && (p = rt("#i" + e));
841
- const o = (l === "sandbox" ? rt(p.nodes()[0].contentDocument.body) : rt("body")).select(`[id='${e}']`);
842
- B.insertMarkers(o, x);
834
+ l === "sandbox" && (p = et("#i" + r));
835
+ const o = (l === "sandbox" ? et(p.nodes()[0].contentDocument.body) : et("body")).select(`[id='${r}']`);
836
+ L.insertMarkers(o, x);
843
837
  let h;
844
838
  h = new Mt({
845
839
  multigraph: !0,
@@ -855,29 +849,29 @@ const ne = function(t, e, r, u, l) {
855
849
  }).setDefaultEdgeLabel(function() {
856
850
  return {};
857
851
  });
858
- const _ = re(o, u.db.getEntities(), h), m = ae(u.db.getRelationships(), h);
859
- St(h), ie(o, h), m.forEach(function(I) {
860
- ne(o, I, h, _, u);
852
+ const _ = ee(o, f.db.getEntities(), h), m = ae(f.db.getRelationships(), h);
853
+ It(h), re(o, h), m.forEach(function(w) {
854
+ ie(o, w, h, _, f);
861
855
  });
862
856
  const g = x.diagramPadding;
863
- bt.insertTitle(o, "entityTitleText", x.titleTopMargin, u.db.getDiagramTitle());
857
+ bt.insertTitle(o, "entityTitleText", x.titleTopMargin, f.db.getDiagramTitle());
864
858
  const R = o.node().getBBox(), y = R.width + g * 2, k = R.height + g * 2;
865
859
  Nt(o, k, y, x.useMaxWidth), o.attr("viewBox", `${R.x - g} ${R.y - g} ${y} ${k}`);
866
- }, oe = "28e9f9db-3c8d-5aa5-9faf-44286ae5937c";
867
- function le(t = "", e = "") {
868
- const r = t.replace($t, "");
869
- return `${ht(e)}${ht(r)}${Ut(
860
+ }, se = "28e9f9db-3c8d-5aa5-9faf-44286ae5937c";
861
+ function oe(t = "", r = "") {
862
+ const e = t.replace(qt, "");
863
+ return `${ct(r)}${ct(e)}${Wt(
870
864
  t,
871
- oe
865
+ se
872
866
  )}`;
873
867
  }
874
- function ht(t = "") {
868
+ function ct(t = "") {
875
869
  return t.length > 0 ? `${t}-` : "";
876
870
  }
877
- const ce = {
878
- setConf: te,
879
- draw: se
880
- }, he = (t) => `
871
+ const le = {
872
+ setConf: $t,
873
+ draw: ne
874
+ }, ce = (t) => `
881
875
  .entityBox {
882
876
  fill: ${t.mainBkg};
883
877
  stroke: ${t.nodeBorder};
@@ -922,12 +916,12 @@ const ce = {
922
916
  stroke-width: 1;
923
917
  }
924
918
 
925
- `, de = he, me = {
926
- parser: Gt,
927
- db: qt,
928
- renderer: ce,
929
- styles: de
919
+ `, he = ce, Ee = {
920
+ parser: Ut,
921
+ db: jt,
922
+ renderer: le,
923
+ styles: he
930
924
  };
931
925
  export {
932
- me as diagram
926
+ Ee as diagram
933
927
  };