@kong-ui-public/documentation 0.3.42 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (155) hide show
  1. package/dist/Tableau10-GLA_9iAD-BMurskAd.js +9 -0
  2. package/dist/arc-BSRpyMf3-C5dasNo_.js +86 -0
  3. package/dist/array-CqVTtuYm-fKLgkG2b.js +6 -0
  4. package/dist/astro-mwoSwJnq-CNh-xuM0.js +27 -0
  5. package/dist/blockDiagram-6b2b5046-D02VCbQO-CPmGy0xX.js +1224 -0
  6. package/dist/c-eDnjw9rh-eDnjw9rh.js +87 -0
  7. package/dist/c4Diagram-b947cdbb-gYcL5VzP-DIDY83e1.js +1578 -0
  8. package/dist/channel-DHTQ8Ynn-7OPGex2S.js +5 -0
  9. package/dist/classDiagram-35230388-JdSKLSZv-D2crBRy-.js +217 -0
  10. package/dist/classDiagram-v2-412acd34-DFFRHXE_-B6aCxlD1.js +200 -0
  11. package/dist/clone-p6h9XXNm-3JQ-HRC6.js +8 -0
  12. package/dist/coffee-CRlSxcc3-CY091_1T.js +108 -0
  13. package/dist/cpp-DizfY48B-CA38N4Mn.js +208 -0
  14. package/dist/createText-423428c9-LivTKT7b-BXNfjcdp.js +2964 -0
  15. package/dist/csharp-uGDiXTZn-uGDiXTZn.js +762 -0
  16. package/dist/css-CAzixsid-CEpuX1HY.js +511 -0
  17. package/dist/csv-D4BoHddH-D4BoHddH.js +7 -0
  18. package/dist/diff-Bo5iyMQ2-Bo5iyMQ2.js +7 -0
  19. package/dist/docker-B10O2enb-B10O2enb.js +7 -0
  20. package/dist/documentation.es.js +5 -3130
  21. package/dist/documentation.umd.js +10152 -50
  22. package/dist/edges-d417c7a0-C1ggiwWz-Aj0OUf7e.js +1082 -0
  23. package/dist/erDiagram-0ea73325-mz0Z_-DA-Dr01LsTB.js +924 -0
  24. package/dist/flowDb-d35e309a-CPyxEMIt-lofeyUuw.js +1126 -0
  25. package/dist/flowDiagram-d949d7c1-DqCa0HNN-BK5wNO9Z.js +782 -0
  26. package/dist/flowDiagram-v2-49332944-UMosz1sZ-BG39AuNP.js +17 -0
  27. package/dist/flowchart-elk-definition-27cc417a-D2UKpS6N-r2p34307.js +48387 -0
  28. package/dist/ganttDiagram-5c869e3b-CVBHw4pG-CaG9QXQM.js +2490 -0
  29. package/dist/git-commit-CWf81VOF-DtOZSoIU.js +9 -0
  30. package/dist/git-rebase-sR-yVH_J-D5M2oE9O.js +9 -0
  31. package/dist/gitGraphDiagram-b9d81de9-BGm3fU0n-CbCpf-4j.js +1262 -0
  32. package/dist/go-BCCWZWY1-BCCWZWY1.js +7 -0
  33. package/dist/graph-4FyIWFHN-774TpNLL.js +870 -0
  34. package/dist/graphql-CT32SSoq-1pBWfpcR.js +18 -0
  35. package/dist/haml-8RvrfhLO-Bbc4xoLP.js +19 -0
  36. package/dist/handlebars-Cr5ro0bH-CLcCNLtV.js +15 -0
  37. package/dist/haskell-BfFu8DD8-BmkPJdLL.js +565 -0
  38. package/dist/html-BZB5lEhh-B74zAnWx.js +84 -0
  39. package/dist/html-derivative-0y7sV5Qc-D8-muTWn.js +9 -0
  40. package/dist/index-8fae9850-_CN7MNjP-Cq-s0PmS.js +373 -0
  41. package/dist/index-B-5DuDrq.js +29996 -0
  42. package/dist/infoDiagram-db7b18fc-V446j9uR-GSa8bniv.js +319 -0
  43. package/dist/ini-BsUFIxsI-BsUFIxsI.js +7 -0
  44. package/dist/init-DjUOC4st-C8Nwz6AJ.js +16 -0
  45. package/dist/java-Bk2JzfKB-Bk2JzfKB.js +74 -0
  46. package/dist/javascript-DqVBMyXe-DqVBMyXe.js +705 -0
  47. package/dist/journeyDiagram-d5636530-CFiu7dnV-DJMu6A22.js +803 -0
  48. package/dist/json-B12k4-6m-B12k4-6m.js +31 -0
  49. package/dist/json5-CvqQZK9I-CvqQZK9I.js +23 -0
  50. package/dist/jsonc-v2qGKRJY-v2qGKRJY.js +31 -0
  51. package/dist/jsonl-izxnMeZX-izxnMeZX.js +31 -0
  52. package/dist/jsx-aDp7j9_Z-aDp7j9_Z.js +705 -0
  53. package/dist/kotlin-NOMOielb-NOMOielb.js +7 -0
  54. package/dist/latex-Bw_ghldO-BlUAi6pB.js +339 -0
  55. package/dist/layout-2-aEcfuw-BqqWy5wB.js +1524 -0
  56. package/dist/less-CW2GmQHL-CW2GmQHL.js +165 -0
  57. package/dist/line-nVq5kEiy-DtZd3PHZ.js +34 -0
  58. package/dist/linear-Bz4oRFvQ-C869GXbm.js +447 -0
  59. package/dist/liquid-DJ2rh7oT-FwZwa67Y.js +28 -0
  60. package/dist/lua-5TZ-G8Be-CogscVHC.js +9 -0
  61. package/dist/make-whncTQWE-whncTQWE.js +7 -0
  62. package/dist/markdown-DYKdIx5--DYKdIx5-.js +135 -0
  63. package/dist/material-theme-lighter-BRE1Bis3-BRE1Bis3.js +769 -0
  64. package/dist/material-theme-palenight-Dhz61Tee-Dhz61Tee.js +769 -0
  65. package/dist/mdc-D0DPLwil-BfE3hy8_.js +88 -0
  66. package/dist/mdx-CKDMxEaL-CKDMxEaL.js +7 -0
  67. package/dist/mermaid-BxNM-z-u-BxNM-z-u.js +7 -0
  68. package/dist/mindmap-definition-377f8f1f-C2vFYDMs-B71SGbvx.js +19078 -0
  69. package/dist/nginx-C082G13W-vryM9k1W.js +9 -0
  70. package/dist/objective-c-BVtzkNiv-BVtzkNiv.js +115 -0
  71. package/dist/onig-BonMD2gC-BonMD2gC.js +4 -0
  72. package/dist/ordinal-MUacOSdK-B1MUT0BL.js +65 -0
  73. package/dist/pascal-CrvtytWS-CrvtytWS.js +7 -0
  74. package/dist/path-Crsf9Nsj-SiSjwXsf.js +91 -0
  75. package/dist/perl-D29UPKP6-Dez6-HRy.js +17 -0
  76. package/dist/php-D7Tl-iS7-BtPFrDEt.js +789 -0
  77. package/dist/pieDiagram-b0208e96-DhA_SoTh-CfDd9YdA.js +501 -0
  78. package/dist/plsql-8SPzZKaa-8SPzZKaa.js +7 -0
  79. package/dist/postcss-Cz2vjx_4-Cz2vjx_4.js +7 -0
  80. package/dist/powershell-B0buHCuS-B0buHCuS.js +7 -0
  81. package/dist/proto-6YaU_lta-6YaU_lta.js +7 -0
  82. package/dist/pug-DbFO7359-duYD8LVa.js +21 -0
  83. package/dist/python-BQXev0_W-BQXev0_W.js +524 -0
  84. package/dist/quadrantDiagram-0332be45-C8q96Ohm-DMblaqnx.js +903 -0
  85. package/dist/r-DU7Q70f1-DU7Q70f1.js +7 -0
  86. package/dist/reg-DoGLEyFr-DoGLEyFr.js +7 -0
  87. package/dist/requirementDiagram-bf7890df-D30zCZjB-B_JBC9RM.js +767 -0
  88. package/dist/rst-Bm1i8IkK-C9EaDq6g.js +26 -0
  89. package/dist/ruby-CZZKXaz8-BxaDEkRP.js +102 -0
  90. package/dist/rust-CIl6NRUt-CIl6NRUt.js +7 -0
  91. package/dist/sankeyDiagram-0acdec17-B4vNjMaS-Bauvtonp.js +816 -0
  92. package/dist/sass-LqXmC1Fh-LqXmC1Fh.js +8 -0
  93. package/dist/scss-DjxgF7f7-DGTzny6p.js +98 -0
  94. package/dist/sequenceDiagram-c18d009d-BniqGSPK-DuYYUmiZ.js +2201 -0
  95. package/dist/shellscript-CUUTQKn5-CUUTQKn5.js +7 -0
  96. package/dist/shellsession-BIPXtZci-D6avbCwN.js +9 -0
  97. package/dist/splunk-C0K00wNV-C0K00wNV.js +7 -0
  98. package/dist/sql-DkzN59UV-DkzN59UV.js +27 -0
  99. package/dist/ssh-config-BbWAW6SY-BbWAW6SY.js +7 -0
  100. package/dist/stateDiagram-43596fc0-F0V9suMd-L2Ywe-J_.js +266 -0
  101. package/dist/stateDiagram-v2-2ead4f9c-DUgJH8tF-BVo1q2i1.js +184 -0
  102. package/dist/style.css +1 -1
  103. package/dist/styles-6860f46c-Dflmq0ac-BRNSwis6.js +1089 -0
  104. package/dist/styles-7383a064-Dg7mXkpq-C4bItohl.js +430 -0
  105. package/dist/styles-b2c874b6-HpcOhE4Y-Bj0upXzO.js +960 -0
  106. package/dist/stylus-CAHdVuhm-CAHdVuhm.js +21 -0
  107. package/dist/svelte-DAxjO8Sh-D0e501jC.js +29 -0
  108. package/dist/svgDrawCommon-0ee1b4e9-CNkCfzsJ-Bz_doYLk.js +64 -0
  109. package/dist/swift-x2DVyVjN-Bz5PC9YM.js +550 -0
  110. package/dist/timeline-definition-d977decf-Cl38e_0g-D_Dlqa-R.js +794 -0
  111. package/dist/toml-Dbtbfmwk-Dbtbfmwk.js +75 -0
  112. package/dist/tsx-BmwsDeeh-BmwsDeeh.js +705 -0
  113. package/dist/twig-B_Gr-ODl-Cl9Q0GWo.js +58 -0
  114. package/dist/types/components/DocumentationContent.vue.d.ts +8 -1
  115. package/dist/types/components/DocumentationContent.vue.d.ts.map +1 -1
  116. package/dist/types/components/DocumentationDisplay.vue.d.ts +5 -1
  117. package/dist/types/components/DocumentationDisplay.vue.d.ts.map +1 -1
  118. package/dist/types/components/ProductDocumentModal.vue.d.ts +1 -1
  119. package/dist/types/components/ProductDocumentModal.vue.d.ts.map +1 -1
  120. package/dist/types/composables/useI18n.d.ts +4 -0
  121. package/dist/types/composables/useI18n.d.ts.map +1 -1
  122. package/dist/typescript-AEg-ehu7-AEg-ehu7.js +672 -0
  123. package/dist/v-BuvBsUKm-BuvBsUKm.js +7 -0
  124. package/dist/vb-cqjo5dul-cqjo5dul.js +7 -0
  125. package/dist/viml-h3ATW6He-h3ATW6He.js +7 -0
  126. package/dist/vue-Dz-azHaT-B9qBHMZi.js +71 -0
  127. package/dist/vue-html-DIGKAAs4-BeHSIJcx.js +11 -0
  128. package/dist/wasm-xOGcJ9Ts-xOGcJ9Ts.js +7 -0
  129. package/dist/wgsl-hGLOfCya-hGLOfCya.js +7 -0
  130. package/dist/xml-CfRpfi_B-BH3JRQfc.js +9 -0
  131. package/dist/xsl-BAqhSCYL-BTKPZRNQ.js +9 -0
  132. package/dist/xychartDiagram-e50adddc-JdLmRUgg-HmDalTeo.js +1282 -0
  133. package/dist/yaml-PGla5xPP-HJurM_FJ.js +206 -0
  134. package/package.json +13 -13
  135. package/dist/prism-bash.min-DDo5CyRs-DihCfXgx.js +0 -7
  136. package/dist/prism-css.min-BrrzZC7b-BrrzZC7b.js +0 -7
  137. package/dist/prism-docker.min-DnIEokC3-D0v8IWN_.js +0 -22
  138. package/dist/prism-go.min-C7UmK6TW-C7UmK6TW.js +0 -1
  139. package/dist/prism-http.min-CsU3-jB8-CQ8PCDXl.js +0 -23
  140. package/dist/prism-javascript.min-CEqHqgbm-CEqHqgbm.js +0 -8
  141. package/dist/prism-jq.min-Q555vXZm-Q555vXZm.js +0 -8
  142. package/dist/prism-json.min-B1GJqK1k-B1GJqK1k.js +0 -1
  143. package/dist/prism-log.min-SDopTpKN-SDopTpKN.js +0 -1
  144. package/dist/prism-lua.min-DwRnUVfS-DwRnUVfS.js +0 -1
  145. package/dist/prism-makefile.min-DyutknhE-DyutknhE.js +0 -1
  146. package/dist/prism-markdown.min-B7US-xc7-DB9aF_ZA.js +0 -63
  147. package/dist/prism-python.min-BIfpAh5K-BIfpAh5K.js +0 -1
  148. package/dist/prism-regex.min-f8DNqi8X-f8DNqi8X.js +0 -4
  149. package/dist/prism-rest.min-B6veHRJF-B6veHRJF.js +0 -1
  150. package/dist/prism-rust.min-Cb-Mi-h0-Cb-Mi-h0.js +0 -9
  151. package/dist/prism-scss.min-B0csyGJo-B0csyGJo.js +0 -1
  152. package/dist/prism-sql.min-BHXzX-c_-BHXzX-c_.js +0 -1
  153. package/dist/prism-typescript.min-oSVeWCAd-oSVeWCAd.js +0 -5
  154. package/dist/prism-xml-doc.min-yj0YzRGe-KgTQx-dc.js +0 -7
  155. package/dist/prism-yaml.min-CTetcdKA-C1YzP_OY.js +0 -28
@@ -0,0 +1,924 @@
1
+ import { c as Y, s as _t, g as ft, b as mt, a as Et, v as gt, x as bt, ar as kt, l as K, z as Ot, h as tt, y as Rt, i as Nt, ao as xt, as as Tt } from "./index-B-5DuDrq.js";
2
+ import { Z as At } from "./graph-4FyIWFHN-774TpNLL.js";
3
+ import { A as Mt } from "./layout-2-aEcfuw-BqqWy5wB.js";
4
+ import { P as Dt } from "./line-nVq5kEiy-DtZd3PHZ.js";
5
+ 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;
6
+ function vt(t) {
7
+ return typeof t == "string" && It.test(t);
8
+ }
9
+ function $t(t) {
10
+ if (!vt(t))
11
+ throw TypeError("Invalid UUID");
12
+ let r;
13
+ const e = new Uint8Array(16);
14
+ 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;
15
+ }
16
+ function Lt(t) {
17
+ t = unescape(encodeURIComponent(t));
18
+ const r = [];
19
+ for (let e = 0; e < t.length; ++e)
20
+ r.push(t.charCodeAt(e));
21
+ return r;
22
+ }
23
+ const wt = "6ba7b810-9dad-11d1-80b4-00c04fd430c8", St = "6ba7b811-9dad-11d1-80b4-00c04fd430c8";
24
+ function Bt(t, r, e) {
25
+ function u(l, p, h, c) {
26
+ var d;
27
+ if (typeof l == "string" && (l = Lt(l)), typeof p == "string" && (p = $t(p)), ((d = p) === null || d === void 0 ? void 0 : d.length) !== 16)
28
+ throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");
29
+ let f = new Uint8Array(16 + l.length);
30
+ if (f.set(p), f.set(l, p.length), f = e(f), f[6] = f[6] & 15 | r, f[8] = f[8] & 63 | 128, h) {
31
+ c = c || 0;
32
+ for (let m = 0; m < 16; ++m)
33
+ h[c + m] = f[m];
34
+ return h;
35
+ }
36
+ return kt(f);
37
+ }
38
+ try {
39
+ u.name = t;
40
+ } catch {
41
+ }
42
+ return u.DNS = wt, u.URL = St, u;
43
+ }
44
+ function Pt(t, r, e, u) {
45
+ switch (t) {
46
+ case 0:
47
+ return r & e ^ ~r & u;
48
+ case 1:
49
+ return r ^ e ^ u;
50
+ case 2:
51
+ return r & e ^ r & u ^ e & u;
52
+ case 3:
53
+ return r ^ e ^ u;
54
+ }
55
+ }
56
+ function et(t, r) {
57
+ return t << r | t >>> 32 - r;
58
+ }
59
+ function Yt(t) {
60
+ const r = [1518500249, 1859775393, 2400959708, 3395469782], e = [1732584193, 4023233417, 2562383102, 271733878, 3285377520];
61
+ if (typeof t == "string") {
62
+ const h = unescape(encodeURIComponent(t));
63
+ t = [];
64
+ for (let c = 0; c < h.length; ++c)
65
+ t.push(h.charCodeAt(c));
66
+ } else
67
+ Array.isArray(t) || (t = Array.prototype.slice.call(t));
68
+ t.push(128);
69
+ const u = t.length / 4 + 2, l = Math.ceil(u / 16), p = new Array(l);
70
+ for (let h = 0; h < l; ++h) {
71
+ const c = new Uint32Array(16);
72
+ for (let d = 0; d < 16; ++d)
73
+ c[d] = t[h * 64 + d * 4] << 24 | t[h * 64 + d * 4 + 1] << 16 | t[h * 64 + d * 4 + 2] << 8 | t[h * 64 + d * 4 + 3];
74
+ p[h] = c;
75
+ }
76
+ 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;
77
+ for (let h = 0; h < l; ++h) {
78
+ const c = new Uint32Array(80);
79
+ for (let _ = 0; _ < 16; ++_)
80
+ c[_] = p[h][_];
81
+ for (let _ = 16; _ < 80; ++_)
82
+ c[_] = et(c[_ - 3] ^ c[_ - 8] ^ c[_ - 14] ^ c[_ - 16], 1);
83
+ let d = e[0], f = e[1], m = e[2], E = e[3], g = e[4];
84
+ for (let _ = 0; _ < 80; ++_) {
85
+ const D = Math.floor(_ / 20), w = et(d, 5) + Pt(D, f, m, E) + g + r[D] + c[_] >>> 0;
86
+ g = E, E = m, m = et(f, 30) >>> 0, f = d, d = w;
87
+ }
88
+ e[0] = e[0] + d >>> 0, e[1] = e[1] + f >>> 0, e[2] = e[2] + m >>> 0, e[3] = e[3] + E >>> 0, e[4] = e[4] + g >>> 0;
89
+ }
90
+ 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];
91
+ }
92
+ const Zt = Bt("v5", 80, Yt);
93
+ var rt = function() {
94
+ var t = function(T, a, o, n) {
95
+ for (o = o || {}, n = T.length; n--; o[T[n]] = a)
96
+ ;
97
+ return o;
98
+ }, r = [6, 8, 10, 20, 22, 24, 26, 27, 28], e = [1, 10], u = [1, 11], l = [1, 12], p = [1, 13], h = [1, 14], c = [1, 15], d = [1, 21], f = [1, 22], m = [1, 23], E = [1, 24], g = [1, 25], _ = [6, 8, 10, 13, 15, 18, 19, 20, 22, 24, 26, 27, 28, 41, 42, 43, 44, 45], D = [1, 34], w = [27, 28, 46, 47], Z = [41, 42, 43, 44, 45], C = [17, 34], S = [1, 54], N = [1, 53], A = [17, 34, 36, 38], k = {
99
+ trace: function() {
100
+ },
101
+ yy: {},
102
+ 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 },
103
+ 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" },
104
+ 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]],
105
+ performAction: function(T, a, o, n, y, i, x) {
106
+ var s = i.length - 1;
107
+ switch (y) {
108
+ case 1:
109
+ break;
110
+ case 2:
111
+ this.$ = [];
112
+ break;
113
+ case 3:
114
+ i[s - 1].push(i[s]), this.$ = i[s - 1];
115
+ break;
116
+ case 4:
117
+ case 5:
118
+ this.$ = i[s];
119
+ break;
120
+ case 6:
121
+ case 7:
122
+ this.$ = [];
123
+ break;
124
+ case 8:
125
+ n.addEntity(i[s - 4]), n.addEntity(i[s - 2]), n.addRelationship(i[s - 4], i[s], i[s - 2], i[s - 3]);
126
+ break;
127
+ case 9:
128
+ n.addEntity(i[s - 3]), n.addAttributes(i[s - 3], i[s - 1]);
129
+ break;
130
+ case 10:
131
+ n.addEntity(i[s - 2]);
132
+ break;
133
+ case 11:
134
+ n.addEntity(i[s]);
135
+ break;
136
+ case 12:
137
+ n.addEntity(i[s - 6], i[s - 4]), n.addAttributes(i[s - 6], i[s - 1]);
138
+ break;
139
+ case 13:
140
+ n.addEntity(i[s - 5], i[s - 3]);
141
+ break;
142
+ case 14:
143
+ n.addEntity(i[s - 3], i[s - 1]);
144
+ break;
145
+ case 15:
146
+ case 16:
147
+ this.$ = i[s].trim(), n.setAccTitle(this.$);
148
+ break;
149
+ case 17:
150
+ case 18:
151
+ this.$ = i[s].trim(), n.setAccDescription(this.$);
152
+ break;
153
+ case 19:
154
+ case 43:
155
+ this.$ = i[s];
156
+ break;
157
+ case 20:
158
+ case 41:
159
+ case 42:
160
+ this.$ = i[s].replace(/"/g, "");
161
+ break;
162
+ case 21:
163
+ case 29:
164
+ this.$ = [i[s]];
165
+ break;
166
+ case 22:
167
+ i[s].push(i[s - 1]), this.$ = i[s];
168
+ break;
169
+ case 23:
170
+ this.$ = { attributeType: i[s - 1], attributeName: i[s] };
171
+ break;
172
+ case 24:
173
+ this.$ = { attributeType: i[s - 2], attributeName: i[s - 1], attributeKeyTypeList: i[s] };
174
+ break;
175
+ case 25:
176
+ this.$ = { attributeType: i[s - 2], attributeName: i[s - 1], attributeComment: i[s] };
177
+ break;
178
+ case 26:
179
+ this.$ = { attributeType: i[s - 3], attributeName: i[s - 2], attributeKeyTypeList: i[s - 1], attributeComment: i[s] };
180
+ break;
181
+ case 27:
182
+ case 28:
183
+ case 31:
184
+ this.$ = i[s];
185
+ break;
186
+ case 30:
187
+ i[s - 2].push(i[s]), this.$ = i[s - 2];
188
+ break;
189
+ case 32:
190
+ this.$ = i[s].replace(/"/g, "");
191
+ break;
192
+ case 33:
193
+ this.$ = { cardA: i[s], relType: i[s - 1], cardB: i[s - 2] };
194
+ break;
195
+ case 34:
196
+ this.$ = n.Cardinality.ZERO_OR_ONE;
197
+ break;
198
+ case 35:
199
+ this.$ = n.Cardinality.ZERO_OR_MORE;
200
+ break;
201
+ case 36:
202
+ this.$ = n.Cardinality.ONE_OR_MORE;
203
+ break;
204
+ case 37:
205
+ this.$ = n.Cardinality.ONLY_ONE;
206
+ break;
207
+ case 38:
208
+ this.$ = n.Cardinality.MD_PARENT;
209
+ break;
210
+ case 39:
211
+ this.$ = n.Identification.NON_IDENTIFYING;
212
+ break;
213
+ case 40:
214
+ this.$ = n.Identification.IDENTIFYING;
215
+ break;
216
+ }
217
+ },
218
+ 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: u, 24: l, 26: p, 27: h, 28: c }, t(r, [2, 7], { 1: [2, 1] }), t(r, [2, 3]), { 9: 16, 11: 9, 20: e, 22: u, 24: l, 26: p, 27: h, 28: c }, t(r, [2, 5]), t(r, [2, 6]), t(r, [2, 11], { 12: 17, 39: 20, 15: [1, 18], 18: [1, 19], 41: d, 42: f, 43: m, 44: E, 45: g }), { 21: [1, 26] }, { 23: [1, 27] }, { 25: [1, 28] }, t(r, [2, 18]), t(_, [2, 19]), t(_, [2, 20]), t(r, [2, 4]), { 11: 29, 27: h, 28: c }, { 16: 30, 17: [1, 31], 29: 32, 30: 33, 34: D }, { 11: 35, 27: h, 28: c }, { 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: D }, { 31: 42, 34: [1, 43] }, { 34: [2, 27] }, { 19: [1, 44] }, { 39: 45, 41: d, 42: f, 43: m, 44: E, 45: g }, 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(C, [2, 23], { 32: 50, 33: 51, 35: 52, 37: S, 38: N }), 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(C, [2, 24], { 33: 56, 36: [1, 57], 38: N }), t(C, [2, 25]), t(A, [2, 29]), t(C, [2, 32]), t(A, [2, 31]), { 16: 58, 17: [1, 59], 29: 32, 30: 33, 34: D }, t(C, [2, 26]), { 35: 60, 37: S }, { 17: [1, 61] }, t(r, [2, 13]), t(A, [2, 30]), t(r, [2, 12])],
219
+ defaultActions: { 34: [2, 27], 41: [2, 22] },
220
+ parseError: function(T, a) {
221
+ if (a.recoverable)
222
+ this.trace(T);
223
+ else {
224
+ var o = new Error(T);
225
+ throw o.hash = a, o;
226
+ }
227
+ },
228
+ parse: function(T) {
229
+ var a = this, o = [0], n = [], y = [null], i = [], x = this.table, s = "", X = 0, at = 0, dt = 2, nt = 1, ut = i.slice.call(arguments, 1), R = Object.create(this.lexer), W = { yy: {} };
230
+ for (var j in this.yy)
231
+ Object.prototype.hasOwnProperty.call(this.yy, j) && (W.yy[j] = this.yy[j]);
232
+ R.setInput(T, W.yy), W.yy.lexer = R, W.yy.parser = this, typeof R.yylloc > "u" && (R.yylloc = {});
233
+ var J = R.yylloc;
234
+ i.push(J);
235
+ var yt = R.options && R.options.ranges;
236
+ typeof W.yy.parseError == "function" ? this.parseError = W.yy.parseError : this.parseError = Object.getPrototypeOf(this).parseError;
237
+ function pt() {
238
+ var P;
239
+ return P = n.pop() || R.lex() || nt, typeof P != "number" && (P instanceof Array && (n = P, P = n.pop()), P = a.symbols_[P] || P), P;
240
+ }
241
+ for (var M, U, I, V, z = {}, G, B, st, Q; ; ) {
242
+ if (U = o[o.length - 1], this.defaultActions[U] ? I = this.defaultActions[U] : ((M === null || typeof M > "u") && (M = pt()), I = x[U] && x[U][M]), typeof I > "u" || !I.length || !I[0]) {
243
+ var q = "";
244
+ Q = [];
245
+ for (G in x[U])
246
+ this.terminals_[G] && G > dt && Q.push("'" + this.terminals_[G] + "'");
247
+ R.showPosition ? q = "Parse error on line " + (X + 1) + `:
248
+ ` + R.showPosition() + `
249
+ Expecting ` + Q.join(", ") + ", got '" + (this.terminals_[M] || M) + "'" : q = "Parse error on line " + (X + 1) + ": Unexpected " + (M == nt ? "end of input" : "'" + (this.terminals_[M] || M) + "'"), this.parseError(q, {
250
+ text: R.match,
251
+ token: this.terminals_[M] || M,
252
+ line: R.yylineno,
253
+ loc: J,
254
+ expected: Q
255
+ });
256
+ }
257
+ if (I[0] instanceof Array && I.length > 1)
258
+ throw new Error("Parse Error: multiple actions possible at state: " + U + ", token: " + M);
259
+ switch (I[0]) {
260
+ case 1:
261
+ o.push(M), y.push(R.yytext), i.push(R.yylloc), o.push(I[1]), M = null, at = R.yyleng, s = R.yytext, X = R.yylineno, J = R.yylloc;
262
+ break;
263
+ case 2:
264
+ if (B = this.productions_[I[1]][1], z.$ = y[y.length - B], z._$ = {
265
+ first_line: i[i.length - (B || 1)].first_line,
266
+ last_line: i[i.length - 1].last_line,
267
+ first_column: i[i.length - (B || 1)].first_column,
268
+ last_column: i[i.length - 1].last_column
269
+ }, yt && (z._$.range = [
270
+ i[i.length - (B || 1)].range[0],
271
+ i[i.length - 1].range[1]
272
+ ]), V = this.performAction.apply(z, [
273
+ s,
274
+ at,
275
+ X,
276
+ W.yy,
277
+ I[1],
278
+ y,
279
+ i
280
+ ].concat(ut)), typeof V < "u")
281
+ return V;
282
+ B && (o = o.slice(0, -1 * B * 2), y = y.slice(0, -1 * B), i = i.slice(0, -1 * B)), o.push(this.productions_[I[1]][0]), y.push(z.$), i.push(z._$), st = x[o[o.length - 2]][o[o.length - 1]], o.push(st);
283
+ break;
284
+ case 3:
285
+ return !0;
286
+ }
287
+ }
288
+ return !0;
289
+ }
290
+ }, O = /* @__PURE__ */ function() {
291
+ var T = {
292
+ EOF: 1,
293
+ parseError: function(a, o) {
294
+ if (this.yy.parser)
295
+ this.yy.parser.parseError(a, o);
296
+ else
297
+ throw new Error(a);
298
+ },
299
+ // resets the lexer, sets new input
300
+ setInput: function(a, o) {
301
+ return this.yy = o || 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
+ first_line: 1,
303
+ first_column: 0,
304
+ last_line: 1,
305
+ last_column: 0
306
+ }, this.options.ranges && (this.yylloc.range = [0, 0]), this.offset = 0, this;
307
+ },
308
+ // consumes and returns one char from the input
309
+ input: function() {
310
+ var a = this._input[0];
311
+ this.yytext += a, this.yyleng++, this.offset++, this.match += a, this.matched += a;
312
+ var o = a.match(/(?:\r\n?|\n).*/g);
313
+ return o ? (this.yylineno++, this.yylloc.last_line++) : this.yylloc.last_column++, this.options.ranges && this.yylloc.range[1]++, this._input = this._input.slice(1), a;
314
+ },
315
+ // unshifts one char (or a string) into the input
316
+ unput: function(a) {
317
+ var o = a.length, n = a.split(/(?:\r\n?|\n)/g);
318
+ this._input = a + this._input, this.yytext = this.yytext.substr(0, this.yytext.length - o), this.offset -= o;
319
+ var y = this.match.split(/(?:\r\n?|\n)/g);
320
+ this.match = this.match.substr(0, this.match.length - 1), this.matched = this.matched.substr(0, this.matched.length - 1), n.length - 1 && (this.yylineno -= n.length - 1);
321
+ var i = this.yylloc.range;
322
+ return this.yylloc = {
323
+ first_line: this.yylloc.first_line,
324
+ last_line: this.yylineno + 1,
325
+ first_column: this.yylloc.first_column,
326
+ last_column: n ? (n.length === y.length ? this.yylloc.first_column : 0) + y[y.length - n.length].length - n[0].length : this.yylloc.first_column - o
327
+ }, this.options.ranges && (this.yylloc.range = [i[0], i[0] + this.yyleng - o]), this.yyleng = this.yytext.length, this;
328
+ },
329
+ // When called from action, caches matched text and appends it on next action
330
+ more: function() {
331
+ return this._more = !0, this;
332
+ },
333
+ // When called from action, signals the lexer that this rule fails to match the input, so the next matching rule (regex) should be tested instead.
334
+ reject: function() {
335
+ if (this.options.backtrack_lexer)
336
+ this._backtrack = !0;
337
+ else
338
+ return this.parseError("Lexical error on line " + (this.yylineno + 1) + `. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
339
+ ` + this.showPosition(), {
340
+ text: "",
341
+ token: null,
342
+ line: this.yylineno
343
+ });
344
+ return this;
345
+ },
346
+ // retain first n characters of the match
347
+ less: function(a) {
348
+ this.unput(this.match.slice(a));
349
+ },
350
+ // displays already matched input, i.e. for error messages
351
+ pastInput: function() {
352
+ var a = this.matched.substr(0, this.matched.length - this.match.length);
353
+ return (a.length > 20 ? "..." : "") + a.substr(-20).replace(/\n/g, "");
354
+ },
355
+ // displays upcoming input, i.e. for error messages
356
+ upcomingInput: function() {
357
+ var a = this.match;
358
+ return a.length < 20 && (a += this._input.substr(0, 20 - a.length)), (a.substr(0, 20) + (a.length > 20 ? "..." : "")).replace(/\n/g, "");
359
+ },
360
+ // displays the character position where the lexing error occurred, i.e. for error messages
361
+ showPosition: function() {
362
+ var a = this.pastInput(), o = new Array(a.length + 1).join("-");
363
+ return a + this.upcomingInput() + `
364
+ ` + o + "^";
365
+ },
366
+ // test the lexed token: return FALSE when not a match, otherwise return token
367
+ test_match: function(a, o) {
368
+ var n, y, i;
369
+ if (this.options.backtrack_lexer && (i = {
370
+ yylineno: this.yylineno,
371
+ yylloc: {
372
+ first_line: this.yylloc.first_line,
373
+ last_line: this.last_line,
374
+ first_column: this.yylloc.first_column,
375
+ last_column: this.yylloc.last_column
376
+ },
377
+ yytext: this.yytext,
378
+ match: this.match,
379
+ matches: this.matches,
380
+ matched: this.matched,
381
+ yyleng: this.yyleng,
382
+ offset: this.offset,
383
+ _more: this._more,
384
+ _input: this._input,
385
+ yy: this.yy,
386
+ conditionStack: this.conditionStack.slice(0),
387
+ done: this.done
388
+ }, this.options.ranges && (i.yylloc.range = this.yylloc.range.slice(0))), y = a[0].match(/(?:\r\n?|\n).*/g), y && (this.yylineno += y.length), this.yylloc = {
389
+ first_line: this.yylloc.last_line,
390
+ last_line: this.yylineno + 1,
391
+ first_column: this.yylloc.last_column,
392
+ last_column: y ? y[y.length - 1].length - y[y.length - 1].match(/\r?\n?/)[0].length : this.yylloc.last_column + a[0].length
393
+ }, 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], n = this.performAction.call(this, this.yy, this, o, this.conditionStack[this.conditionStack.length - 1]), this.done && this._input && (this.done = !1), n)
394
+ return n;
395
+ if (this._backtrack) {
396
+ for (var x in i)
397
+ this[x] = i[x];
398
+ return !1;
399
+ }
400
+ return !1;
401
+ },
402
+ // return next match in input
403
+ next: function() {
404
+ if (this.done)
405
+ return this.EOF;
406
+ this._input || (this.done = !0);
407
+ var a, o, n, y;
408
+ this._more || (this.yytext = "", this.match = "");
409
+ for (var i = this._currentRules(), x = 0; x < i.length; x++)
410
+ if (n = this._input.match(this.rules[i[x]]), n && (!o || n[0].length > o[0].length)) {
411
+ if (o = n, y = x, this.options.backtrack_lexer) {
412
+ if (a = this.test_match(n, i[x]), a !== !1)
413
+ return a;
414
+ if (this._backtrack) {
415
+ o = !1;
416
+ continue;
417
+ } else
418
+ return !1;
419
+ } else if (!this.options.flex)
420
+ break;
421
+ }
422
+ return o ? (a = this.test_match(o, i[y]), a !== !1 ? a : !1) : this._input === "" ? this.EOF : this.parseError("Lexical error on line " + (this.yylineno + 1) + `. Unrecognized text.
423
+ ` + this.showPosition(), {
424
+ text: "",
425
+ token: null,
426
+ line: this.yylineno
427
+ });
428
+ },
429
+ // return next match that has a token
430
+ lex: function() {
431
+ var a = this.next();
432
+ return a || this.lex();
433
+ },
434
+ // activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)
435
+ begin: function(a) {
436
+ this.conditionStack.push(a);
437
+ },
438
+ // pop the previously active lexer condition state off the condition stack
439
+ popState: function() {
440
+ var a = this.conditionStack.length - 1;
441
+ return a > 0 ? this.conditionStack.pop() : this.conditionStack[0];
442
+ },
443
+ // produce the lexer rule set which is active for the currently active lexer condition state
444
+ _currentRules: function() {
445
+ return this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1] ? this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules : this.conditions.INITIAL.rules;
446
+ },
447
+ // return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available
448
+ topState: function(a) {
449
+ return a = this.conditionStack.length - 1 - Math.abs(a || 0), a >= 0 ? this.conditionStack[a] : "INITIAL";
450
+ },
451
+ // alias for begin(condition)
452
+ pushState: function(a) {
453
+ this.begin(a);
454
+ },
455
+ // return the number of states currently on the stack
456
+ stateStackSize: function() {
457
+ return this.conditionStack.length;
458
+ },
459
+ options: { "case-insensitive": !0 },
460
+ performAction: function(a, o, n, y) {
461
+ switch (n) {
462
+ case 0:
463
+ return this.begin("acc_title"), 22;
464
+ case 1:
465
+ return this.popState(), "acc_title_value";
466
+ case 2:
467
+ return this.begin("acc_descr"), 24;
468
+ case 3:
469
+ return this.popState(), "acc_descr_value";
470
+ case 4:
471
+ this.begin("acc_descr_multiline");
472
+ break;
473
+ case 5:
474
+ this.popState();
475
+ break;
476
+ case 6:
477
+ return "acc_descr_multiline_value";
478
+ case 7:
479
+ return 10;
480
+ case 8:
481
+ break;
482
+ case 9:
483
+ return 8;
484
+ case 10:
485
+ return 28;
486
+ case 11:
487
+ return 48;
488
+ case 12:
489
+ return 4;
490
+ case 13:
491
+ return this.begin("block"), 15;
492
+ case 14:
493
+ return 36;
494
+ case 15:
495
+ break;
496
+ case 16:
497
+ return 37;
498
+ case 17:
499
+ return 34;
500
+ case 18:
501
+ return 34;
502
+ case 19:
503
+ return 38;
504
+ case 20:
505
+ break;
506
+ case 21:
507
+ return this.popState(), 17;
508
+ case 22:
509
+ return o.yytext[0];
510
+ case 23:
511
+ return 18;
512
+ case 24:
513
+ return 19;
514
+ case 25:
515
+ return 41;
516
+ case 26:
517
+ return 43;
518
+ case 27:
519
+ return 43;
520
+ case 28:
521
+ return 43;
522
+ case 29:
523
+ return 41;
524
+ case 30:
525
+ return 41;
526
+ case 31:
527
+ return 42;
528
+ case 32:
529
+ return 42;
530
+ case 33:
531
+ return 42;
532
+ case 34:
533
+ return 42;
534
+ case 35:
535
+ return 42;
536
+ case 36:
537
+ return 43;
538
+ case 37:
539
+ return 42;
540
+ case 38:
541
+ return 43;
542
+ case 39:
543
+ return 44;
544
+ case 40:
545
+ return 44;
546
+ case 41:
547
+ return 44;
548
+ case 42:
549
+ return 44;
550
+ case 43:
551
+ return 41;
552
+ case 44:
553
+ return 42;
554
+ case 45:
555
+ return 43;
556
+ case 46:
557
+ return 45;
558
+ case 47:
559
+ return 46;
560
+ case 48:
561
+ return 47;
562
+ case 49:
563
+ return 47;
564
+ case 50:
565
+ return 46;
566
+ case 51:
567
+ return 46;
568
+ case 52:
569
+ return 46;
570
+ case 53:
571
+ return 27;
572
+ case 54:
573
+ return o.yytext[0];
574
+ case 55:
575
+ return 6;
576
+ }
577
+ },
578
+ 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],
579
+ 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 } }
580
+ };
581
+ return T;
582
+ }();
583
+ k.lexer = O;
584
+ function v() {
585
+ this.yy = {};
586
+ }
587
+ return v.prototype = k, k.Parser = v, new v();
588
+ }();
589
+ rt.parser = rt;
590
+ const Ct = rt;
591
+ let F = {}, it = [];
592
+ const Ft = {
593
+ ZERO_OR_ONE: "ZERO_OR_ONE",
594
+ ZERO_OR_MORE: "ZERO_OR_MORE",
595
+ ONE_OR_MORE: "ONE_OR_MORE",
596
+ ONLY_ONE: "ONLY_ONE",
597
+ MD_PARENT: "MD_PARENT"
598
+ }, Wt = {
599
+ NON_IDENTIFYING: "NON_IDENTIFYING",
600
+ IDENTIFYING: "IDENTIFYING"
601
+ }, lt = function(t, r = void 0) {
602
+ return F[t] === void 0 ? (F[t] = { attributes: [], alias: r }, K.info("Added new entity :", t)) : F[t] && !F[t].alias && r && (F[t].alias = r, K.info(`Add alias '${r}' to entity '${t}'`)), F[t];
603
+ }, Ut = () => F, zt = function(t, r) {
604
+ let e = lt(t), u;
605
+ for (u = r.length - 1; u >= 0; u--)
606
+ e.attributes.push(r[u]), K.debug("Added attribute ", r[u].attributeName);
607
+ }, Kt = function(t, r, e, u) {
608
+ let l = {
609
+ entityA: t,
610
+ roleA: r,
611
+ entityB: e,
612
+ relSpec: u
613
+ };
614
+ it.push(l), K.debug("Added new relationship :", l);
615
+ }, Ht = () => it, Xt = function() {
616
+ F = {}, it = [], Ot();
617
+ }, Gt = {
618
+ Cardinality: Ft,
619
+ Identification: Wt,
620
+ getConfig: () => Y().er,
621
+ addEntity: lt,
622
+ addAttributes: zt,
623
+ getEntities: Ut,
624
+ addRelationship: Kt,
625
+ getRelationships: Ht,
626
+ clear: Xt,
627
+ setAccTitle: _t,
628
+ getAccTitle: ft,
629
+ setAccDescription: mt,
630
+ getAccDescription: Et,
631
+ setDiagramTitle: gt,
632
+ getDiagramTitle: bt
633
+ }, $ = {
634
+ ONLY_ONE_START: "ONLY_ONE_START",
635
+ ONLY_ONE_END: "ONLY_ONE_END",
636
+ ZERO_OR_ONE_START: "ZERO_OR_ONE_START",
637
+ ZERO_OR_ONE_END: "ZERO_OR_ONE_END",
638
+ ONE_OR_MORE_START: "ONE_OR_MORE_START",
639
+ ONE_OR_MORE_END: "ONE_OR_MORE_END",
640
+ ZERO_OR_MORE_START: "ZERO_OR_MORE_START",
641
+ ZERO_OR_MORE_END: "ZERO_OR_MORE_END",
642
+ MD_PARENT_END: "MD_PARENT_END",
643
+ MD_PARENT_START: "MD_PARENT_START"
644
+ }, Qt = function(t, r) {
645
+ let e;
646
+ t.append("defs").append("marker").attr("id", $.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", $.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", $.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", $.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", $.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", $.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", $.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", $.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", $.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", $.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");
647
+ }, L = {
648
+ ERMarkers: $,
649
+ insertMarkers: Qt
650
+ }, jt = /[^\dA-Za-z](\W)*/g;
651
+ let b = {}, H = /* @__PURE__ */ new Map();
652
+ const Jt = function(t) {
653
+ const r = Object.keys(t);
654
+ for (const e of r)
655
+ b[e] = t[e];
656
+ }, Vt = (t, r, e) => {
657
+ const u = b.entityPadding / 3, l = b.entityPadding / 3, p = b.fontSize * 0.85, h = r.node().getBBox(), c = [];
658
+ let d = !1, f = !1, m = 0, E = 0, g = 0, _ = 0, D = h.height + u * 2, w = 1;
659
+ e.forEach((N) => {
660
+ N.attributeKeyTypeList !== void 0 && N.attributeKeyTypeList.length > 0 && (d = !0), N.attributeComment !== void 0 && (f = !0);
661
+ }), e.forEach((N) => {
662
+ const A = `${r.node().id}-attr-${w}`;
663
+ let k = 0;
664
+ const O = Tt(N.attributeType), v = 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(O), T = 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(N.attributeName), a = {};
665
+ a.tn = v, a.nn = T;
666
+ const o = v.node().getBBox(), n = T.node().getBBox();
667
+ if (m = Math.max(m, o.width), E = Math.max(E, n.width), k = Math.max(o.height, n.height), d) {
668
+ const y = N.attributeKeyTypeList !== void 0 ? N.attributeKeyTypeList.join(",") : "", i = 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(y);
669
+ a.kn = i;
670
+ const x = i.node().getBBox();
671
+ g = Math.max(g, x.width), k = Math.max(k, x.height);
672
+ }
673
+ if (f) {
674
+ const y = 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(N.attributeComment || "");
675
+ a.cn = y;
676
+ const i = y.node().getBBox();
677
+ _ = Math.max(_, i.width), k = Math.max(k, i.height);
678
+ }
679
+ a.height = k, c.push(a), D += k + u * 2, w += 1;
680
+ });
681
+ let Z = 4;
682
+ d && (Z += 2), f && (Z += 2);
683
+ const C = m + E + g + _, S = {
684
+ width: Math.max(
685
+ b.minEntityWidth,
686
+ Math.max(
687
+ h.width + b.entityPadding * 2,
688
+ C + l * Z
689
+ )
690
+ ),
691
+ height: e.length > 0 ? D : Math.max(b.minEntityHeight, h.height + b.entityPadding * 2)
692
+ };
693
+ if (e.length > 0) {
694
+ const N = Math.max(
695
+ 0,
696
+ (S.width - C - l * Z) / (Z / 2)
697
+ );
698
+ r.attr(
699
+ "transform",
700
+ "translate(" + S.width / 2 + "," + (u + h.height / 2) + ")"
701
+ );
702
+ let A = h.height + u * 2, k = "attributeBoxOdd";
703
+ c.forEach((O) => {
704
+ const v = A + u + O.height / 2;
705
+ O.tn.attr("transform", "translate(" + l + "," + v + ")");
706
+ const T = t.insert("rect", "#" + O.tn.node().id).classed(`er ${k}`, !0).attr("x", 0).attr("y", A).attr("width", m + l * 2 + N).attr("height", O.height + u * 2), a = parseFloat(T.attr("x")) + parseFloat(T.attr("width"));
707
+ O.nn.attr(
708
+ "transform",
709
+ "translate(" + (a + l) + "," + v + ")"
710
+ );
711
+ const o = t.insert("rect", "#" + O.nn.node().id).classed(`er ${k}`, !0).attr("x", a).attr("y", A).attr("width", E + l * 2 + N).attr("height", O.height + u * 2);
712
+ let n = parseFloat(o.attr("x")) + parseFloat(o.attr("width"));
713
+ if (d) {
714
+ O.kn.attr(
715
+ "transform",
716
+ "translate(" + (n + l) + "," + v + ")"
717
+ );
718
+ const y = t.insert("rect", "#" + O.kn.node().id).classed(`er ${k}`, !0).attr("x", n).attr("y", A).attr("width", g + l * 2 + N).attr("height", O.height + u * 2);
719
+ n = parseFloat(y.attr("x")) + parseFloat(y.attr("width"));
720
+ }
721
+ f && (O.cn.attr(
722
+ "transform",
723
+ "translate(" + (n + l) + "," + v + ")"
724
+ ), t.insert("rect", "#" + O.cn.node().id).classed(`er ${k}`, "true").attr("x", n).attr("y", A).attr("width", _ + l * 2 + N).attr("height", O.height + u * 2)), A += O.height + u * 2, k = k === "attributeBoxOdd" ? "attributeBoxEven" : "attributeBoxOdd";
725
+ });
726
+ } else
727
+ S.height = Math.max(b.minEntityHeight, D), r.attr("transform", "translate(" + S.width / 2 + "," + S.height / 2 + ")");
728
+ return S;
729
+ }, qt = function(t, r, e) {
730
+ const u = Object.keys(r);
731
+ let l;
732
+ return u.forEach(function(p) {
733
+ const h = ne(p, "entity");
734
+ H.set(p, h);
735
+ const c = t.append("g").attr("id", h);
736
+ l = l === void 0 ? h : l;
737
+ const d = "text-" + h, f = c.append("text").classed("er entityLabel", !0).attr("id", d).attr("x", 0).attr("y", 0).style("dominant-baseline", "middle").style("text-anchor", "middle").style("font-family", Y().fontFamily).style("font-size", b.fontSize + "px").text(r[p].alias ?? p), { width: m, height: E } = Vt(
738
+ c,
739
+ f,
740
+ r[p].attributes
741
+ ), g = c.insert("rect", "#" + d).classed("er entityBox", !0).attr("x", 0).attr("y", 0).attr("width", m).attr("height", E).node().getBBox();
742
+ e.setNode(h, {
743
+ width: g.width,
744
+ height: g.height,
745
+ shape: "rect",
746
+ id: h
747
+ });
748
+ }), l;
749
+ }, te = function(t, r) {
750
+ r.nodes().forEach(function(e) {
751
+ e !== void 0 && r.node(e) !== void 0 && t.select("#" + e).attr(
752
+ "transform",
753
+ "translate(" + (r.node(e).x - r.node(e).width / 2) + "," + (r.node(e).y - r.node(e).height / 2) + " )"
754
+ );
755
+ });
756
+ }, ht = function(t) {
757
+ return (t.entityA + t.roleA + t.entityB).replace(/\s/g, "");
758
+ }, ee = function(t, r) {
759
+ return t.forEach(function(e) {
760
+ r.setEdge(
761
+ H.get(e.entityA),
762
+ H.get(e.entityB),
763
+ { relationship: e },
764
+ ht(e)
765
+ );
766
+ }), t;
767
+ };
768
+ let ot = 0;
769
+ const re = function(t, r, e, u, l) {
770
+ ot++;
771
+ const p = e.edge(
772
+ H.get(r.entityA),
773
+ H.get(r.entityB),
774
+ ht(r)
775
+ ), h = Dt().x(function(_) {
776
+ return _.x;
777
+ }).y(function(_) {
778
+ return _.y;
779
+ }).curve(xt), c = t.insert("path", "#" + u).classed("er relationshipLine", !0).attr("d", h(p.points)).style("stroke", b.stroke).style("fill", "none");
780
+ r.relSpec.relType === l.db.Identification.NON_IDENTIFYING && c.attr("stroke-dasharray", "8,8");
781
+ let d = "";
782
+ switch (b.arrowMarkerAbsolute && (d = window.location.protocol + "//" + window.location.host + window.location.pathname + window.location.search, d = d.replace(/\(/g, "\\("), d = d.replace(/\)/g, "\\)")), r.relSpec.cardA) {
783
+ case l.db.Cardinality.ZERO_OR_ONE:
784
+ c.attr("marker-end", "url(" + d + "#" + L.ERMarkers.ZERO_OR_ONE_END + ")");
785
+ break;
786
+ case l.db.Cardinality.ZERO_OR_MORE:
787
+ c.attr("marker-end", "url(" + d + "#" + L.ERMarkers.ZERO_OR_MORE_END + ")");
788
+ break;
789
+ case l.db.Cardinality.ONE_OR_MORE:
790
+ c.attr("marker-end", "url(" + d + "#" + L.ERMarkers.ONE_OR_MORE_END + ")");
791
+ break;
792
+ case l.db.Cardinality.ONLY_ONE:
793
+ c.attr("marker-end", "url(" + d + "#" + L.ERMarkers.ONLY_ONE_END + ")");
794
+ break;
795
+ case l.db.Cardinality.MD_PARENT:
796
+ c.attr("marker-end", "url(" + d + "#" + L.ERMarkers.MD_PARENT_END + ")");
797
+ break;
798
+ }
799
+ switch (r.relSpec.cardB) {
800
+ case l.db.Cardinality.ZERO_OR_ONE:
801
+ c.attr(
802
+ "marker-start",
803
+ "url(" + d + "#" + L.ERMarkers.ZERO_OR_ONE_START + ")"
804
+ );
805
+ break;
806
+ case l.db.Cardinality.ZERO_OR_MORE:
807
+ c.attr(
808
+ "marker-start",
809
+ "url(" + d + "#" + L.ERMarkers.ZERO_OR_MORE_START + ")"
810
+ );
811
+ break;
812
+ case l.db.Cardinality.ONE_OR_MORE:
813
+ c.attr(
814
+ "marker-start",
815
+ "url(" + d + "#" + L.ERMarkers.ONE_OR_MORE_START + ")"
816
+ );
817
+ break;
818
+ case l.db.Cardinality.ONLY_ONE:
819
+ c.attr("marker-start", "url(" + d + "#" + L.ERMarkers.ONLY_ONE_START + ")");
820
+ break;
821
+ case l.db.Cardinality.MD_PARENT:
822
+ c.attr("marker-start", "url(" + d + "#" + L.ERMarkers.MD_PARENT_START + ")");
823
+ break;
824
+ }
825
+ const f = c.node().getTotalLength(), m = c.node().getPointAtLength(f * 0.5), E = "rel" + ot, g = t.append("text").classed("er relationshipLabel", !0).attr("id", E).attr("x", m.x).attr("y", m.y).style("text-anchor", "middle").style("dominant-baseline", "middle").style("font-family", Y().fontFamily).style("font-size", b.fontSize + "px").text(r.roleA).node().getBBox();
826
+ t.insert("rect", "#" + E).classed("er relationshipLabelBox", !0).attr("x", m.x - g.width / 2).attr("y", m.y - g.height / 2).attr("width", g.width).attr("height", g.height);
827
+ }, ie = function(t, r, e, u) {
828
+ b = Y().er, K.info("Drawing ER diagram");
829
+ const l = Y().securityLevel;
830
+ let p;
831
+ l === "sandbox" && (p = tt("#i" + r));
832
+ const h = (l === "sandbox" ? tt(p.nodes()[0].contentDocument.body) : tt("body")).select(`[id='${r}']`);
833
+ L.insertMarkers(h, b);
834
+ let c;
835
+ c = new At({
836
+ multigraph: !0,
837
+ directed: !0,
838
+ compound: !1
839
+ }).setGraph({
840
+ rankdir: b.layoutDirection,
841
+ marginx: 20,
842
+ marginy: 20,
843
+ nodesep: 100,
844
+ edgesep: 100,
845
+ ranksep: 100
846
+ }).setDefaultEdgeLabel(function() {
847
+ return {};
848
+ });
849
+ const d = qt(h, u.db.getEntities(), c), f = ee(u.db.getRelationships(), c);
850
+ Mt(c), te(h, c), f.forEach(function(D) {
851
+ re(h, D, c, d, u);
852
+ });
853
+ const m = b.diagramPadding;
854
+ Rt.insertTitle(h, "entityTitleText", b.titleTopMargin, u.db.getDiagramTitle());
855
+ const E = h.node().getBBox(), g = E.width + m * 2, _ = E.height + m * 2;
856
+ Nt(h, _, g, b.useMaxWidth), h.attr("viewBox", `${E.x - m} ${E.y - m} ${g} ${_}`);
857
+ }, ae = "28e9f9db-3c8d-5aa5-9faf-44286ae5937c";
858
+ function ne(t = "", r = "") {
859
+ const e = t.replace(jt, "");
860
+ return `${ct(r)}${ct(e)}${Zt(
861
+ t,
862
+ ae
863
+ )}`;
864
+ }
865
+ function ct(t = "") {
866
+ return t.length > 0 ? `${t}-` : "";
867
+ }
868
+ const se = {
869
+ setConf: Jt,
870
+ draw: ie
871
+ }, oe = (t) => `
872
+ .entityBox {
873
+ fill: ${t.mainBkg};
874
+ stroke: ${t.nodeBorder};
875
+ }
876
+
877
+ .attributeBoxOdd {
878
+ fill: ${t.attributeBackgroundColorOdd};
879
+ stroke: ${t.nodeBorder};
880
+ }
881
+
882
+ .attributeBoxEven {
883
+ fill: ${t.attributeBackgroundColorEven};
884
+ stroke: ${t.nodeBorder};
885
+ }
886
+
887
+ .relationshipLabelBox {
888
+ fill: ${t.tertiaryColor};
889
+ opacity: 0.7;
890
+ background-color: ${t.tertiaryColor};
891
+ rect {
892
+ opacity: 0.5;
893
+ }
894
+ }
895
+
896
+ .relationshipLine {
897
+ stroke: ${t.lineColor};
898
+ }
899
+
900
+ .entityTitleText {
901
+ text-anchor: middle;
902
+ font-size: 18px;
903
+ fill: ${t.textColor};
904
+ }
905
+ #MD_PARENT_START {
906
+ fill: #f5f5f5 !important;
907
+ stroke: ${t.lineColor} !important;
908
+ stroke-width: 1;
909
+ }
910
+ #MD_PARENT_END {
911
+ fill: #f5f5f5 !important;
912
+ stroke: ${t.lineColor} !important;
913
+ stroke-width: 1;
914
+ }
915
+
916
+ `, ce = oe, ye = {
917
+ parser: Ct,
918
+ db: Gt,
919
+ renderer: se,
920
+ styles: ce
921
+ };
922
+ export {
923
+ ye as diagram
924
+ };