@layers-app/editor 0.5.0 → 0.5.1

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 (240) hide show
  1. package/package.json +5 -4
  2. package/dist/index.cjs +0 -2
  3. package/dist/index.d.ts +0 -315
  4. package/dist/index.js +0 -13
  5. package/dist/layers.0GV8bqI4.js +0 -186
  6. package/dist/layers.2-v72gXD.js +0 -1
  7. package/dist/layers.271NUg7u.js +0 -39
  8. package/dist/layers.2YgiancJ.js +0 -116
  9. package/dist/layers.3DEO2eFX.js +0 -38
  10. package/dist/layers.3PKeLS62.js +0 -48146
  11. package/dist/layers.52famHy6.js +0 -1
  12. package/dist/layers.6M02Y2O6.js +0 -6
  13. package/dist/layers.7DTJccah.js +0 -10
  14. package/dist/layers.7JqFgE4-.js +0 -15
  15. package/dist/layers.7geZ_Z3x.js +0 -36
  16. package/dist/layers.88aO_Zsd.js +0 -14
  17. package/dist/layers.8hFVbiPY.js +0 -59
  18. package/dist/layers.9KaBpXFA.js +0 -1283
  19. package/dist/layers.9pNaFvaX.js +0 -1
  20. package/dist/layers.AIKsYMqL.js +0 -8
  21. package/dist/layers.B-0J3b5U.js +0 -40
  22. package/dist/layers.B19hGmey.js +0 -1
  23. package/dist/layers.B3D4g2HH.js +0 -1
  24. package/dist/layers.B4yEsxVs.js +0 -10
  25. package/dist/layers.B5Xhxhbr.js +0 -39
  26. package/dist/layers.B6jgTP72.js +0 -1
  27. package/dist/layers.B8a2ydDI.js +0 -1265
  28. package/dist/layers.B9EoV4pJ.js +0 -1
  29. package/dist/layers.BAI7Z-Wd.js +0 -40
  30. package/dist/layers.BAtv1CM7.js +0 -1
  31. package/dist/layers.BB24KMYM.js +0 -19
  32. package/dist/layers.BBWAKePM.js +0 -7
  33. package/dist/layers.BBWcXYuR.js +0 -5
  34. package/dist/layers.BC3JkNtz.js +0 -21938
  35. package/dist/layers.BFKY-mk1.js +0 -8
  36. package/dist/layers.BGnHNrIw.js +0 -38
  37. package/dist/layers.BIF7gnlw.js +0 -6
  38. package/dist/layers.BIeVwYKL.js +0 -1
  39. package/dist/layers.BJDrjORS.js +0 -244
  40. package/dist/layers.BJtqK_fc.js +0 -40
  41. package/dist/layers.BLMsv5-v.js +0 -295
  42. package/dist/layers.BLd2spTm.js +0 -1
  43. package/dist/layers.BLj5XN2k.js +0 -802
  44. package/dist/layers.BMzZVoyQ.js +0 -5
  45. package/dist/layers.BN0X-mKK.js +0 -41
  46. package/dist/layers.BNP0J0MG.js +0 -4
  47. package/dist/layers.BQgrfzZU.js +0 -7
  48. package/dist/layers.BRFujA4d.js +0 -8
  49. package/dist/layers.BSTBZrFn.js +0 -1
  50. package/dist/layers.BSXvhEG5.js +0 -5
  51. package/dist/layers.BSzdascH.js +0 -42
  52. package/dist/layers.BTsJAbTY.js +0 -37
  53. package/dist/layers.BUpmCmqT.js +0 -36
  54. package/dist/layers.BVAnEpZl.js +0 -10
  55. package/dist/layers.BW84v3Ox.js +0 -2
  56. package/dist/layers.B_Lan92M.js +0 -1
  57. package/dist/layers.BaW-t_Zc.js +0 -8
  58. package/dist/layers.BapT0txt.js +0 -425
  59. package/dist/layers.BbCfEXyj.js +0 -55
  60. package/dist/layers.BdqQLuaK.js +0 -40
  61. package/dist/layers.Bdwk_Ggl.js +0 -33
  62. package/dist/layers.Bg7-KHZC.js +0 -2235
  63. package/dist/layers.BgOa2ZQq.js +0 -7
  64. package/dist/layers.BiJ8hfRt.js +0 -1510
  65. package/dist/layers.BkFD_pHb.js +0 -40
  66. package/dist/layers.BlN6GnRT.js +0 -7
  67. package/dist/layers.Bm84E1I5.js +0 -39
  68. package/dist/layers.Bo3tMbEB.js +0 -42
  69. package/dist/layers.BoOcWXFs.js +0 -10
  70. package/dist/layers.BpilXLfW.js +0 -6
  71. package/dist/layers.BrHN_kMd.js +0 -41
  72. package/dist/layers.BruMG2wy.js +0 -160
  73. package/dist/layers.BsWPnWD1.js +0 -40
  74. package/dist/layers.Bu9ZoRYM.js +0 -40
  75. package/dist/layers.BvjpCDHj.js +0 -9
  76. package/dist/layers.Bwb7QBBL.js +0 -10
  77. package/dist/layers.Bx0DgrIz.js +0 -84
  78. package/dist/layers.By8wynAO.js +0 -40
  79. package/dist/layers.C0Lgw_Sx.js +0 -11688
  80. package/dist/layers.C3me1AOA.js +0 -904
  81. package/dist/layers.C5XL_KJW.js +0 -44
  82. package/dist/layers.C65tYhLf.js +0 -5
  83. package/dist/layers.C67fBVg3.js +0 -3
  84. package/dist/layers.C6HmVi2T.js +0 -39
  85. package/dist/layers.C8_lu5UH.js +0 -23
  86. package/dist/layers.C8oO_BiQ.js +0 -40
  87. package/dist/layers.C9AvvTRV.js +0 -32
  88. package/dist/layers.CA3DQGmO.js +0 -11
  89. package/dist/layers.CCoWlQxf.js +0 -70
  90. package/dist/layers.CCy49ah1.js +0 -37
  91. package/dist/layers.CDftR5Kg.js +0 -320
  92. package/dist/layers.CDw-iNbj.js +0 -9
  93. package/dist/layers.CEDfv2oj.js +0 -423
  94. package/dist/layers.CGeTu6ph.js +0 -1
  95. package/dist/layers.CHZsXQcr.js +0 -1
  96. package/dist/layers.CJlWYRtk.js +0 -41
  97. package/dist/layers.CKy_DRKv.js +0 -42
  98. package/dist/layers.COEorZbZ.js +0 -257
  99. package/dist/layers.CP2_7vUR.js +0 -32
  100. package/dist/layers.CPEzOey-.js +0 -84
  101. package/dist/layers.CSY_lOK0.js +0 -268
  102. package/dist/layers.CT_bvOgC.js +0 -1
  103. package/dist/layers.CUWVPrVU.js +0 -40
  104. package/dist/layers.CVCC2rNb.js +0 -139
  105. package/dist/layers.CXbK6Z0C.js +0 -8
  106. package/dist/layers.CXzpm8-U.js +0 -41
  107. package/dist/layers.CYwLZCUi.js +0 -1088
  108. package/dist/layers.CZ6FLSh1.js +0 -1
  109. package/dist/layers.CZzvHupu.js +0 -36
  110. package/dist/layers.CaZJgSbm.js +0 -4
  111. package/dist/layers.CcX1e4Cb.js +0 -6
  112. package/dist/layers.CgHCxAKJ.js +0 -35
  113. package/dist/layers.CgyRf-4B.js +0 -41
  114. package/dist/layers.ChtNiFGR.js +0 -11
  115. package/dist/layers.CiYt11kd.js +0 -7
  116. package/dist/layers.Cik9ty7R.js +0 -34
  117. package/dist/layers.Cizp88rb.js +0 -32
  118. package/dist/layers.Cjxg13wd.js +0 -47029
  119. package/dist/layers.Cl6-9OBf.js +0 -39
  120. package/dist/layers.ClExSsZJ.js +0 -36
  121. package/dist/layers.CqE1nYk3.js +0 -8
  122. package/dist/layers.CqVTtuYm.js +0 -6
  123. package/dist/layers.CsNI3f74.js +0 -7
  124. package/dist/layers.CuAECIsO.js +0 -39
  125. package/dist/layers.CuVNrIcW.js +0 -52
  126. package/dist/layers.Cv-z4RwC.js +0 -1089
  127. package/dist/layers.CvPdAUZN.js +0 -37
  128. package/dist/layers.CvQiknH6.js +0 -1
  129. package/dist/layers.Cwn1D7F6.js +0 -1619
  130. package/dist/layers.CyOP0v_-.js +0 -8
  131. package/dist/layers.CyvQNQUj.js +0 -139
  132. package/dist/layers.Cyzu9PKQ.js +0 -1
  133. package/dist/layers.Cz4E3Gls.js +0 -21763
  134. package/dist/layers.D-rCo5dz.js +0 -207
  135. package/dist/layers.D0zn4_Mx.js +0 -1
  136. package/dist/layers.D11yimAp.js +0 -230
  137. package/dist/layers.D1sBwAcX.js +0 -1
  138. package/dist/layers.D22AIgry.js +0 -1
  139. package/dist/layers.D2Y56Lcj.js +0 -1
  140. package/dist/layers.D2sjiqI3.js +0 -41
  141. package/dist/layers.D3OtVkCp.js +0 -38
  142. package/dist/layers.D3pymTps.js +0 -6
  143. package/dist/layers.D44d_6CD.js +0 -437
  144. package/dist/layers.D4T8fTcj.js +0 -1223
  145. package/dist/layers.D7jGxypv.js +0 -8
  146. package/dist/layers.D9umovmT.js +0 -10
  147. package/dist/layers.DE-6jvOp.js +0 -10
  148. package/dist/layers.DFWypiYS.js +0 -4
  149. package/dist/layers.DFZcoBfL.js +0 -42
  150. package/dist/layers.DGHPyPPP.js +0 -37
  151. package/dist/layers.DL_hhIIR.js +0 -793
  152. package/dist/layers.DLwuMfdd.js +0 -84
  153. package/dist/layers.DMkBISW1.js +0 -1
  154. package/dist/layers.DMkqdBNu.js +0 -1
  155. package/dist/layers.DN9HoVxI.js +0 -18
  156. package/dist/layers.DNpGJLyQ.js +0 -65
  157. package/dist/layers.DOrgOHBr.js +0 -1
  158. package/dist/layers.DPumOFMF.js +0 -51
  159. package/dist/layers.DQ9duwtV.js +0 -1359
  160. package/dist/layers.DQSx2qqb.js +0 -11
  161. package/dist/layers.DRj2t11p.js +0 -9
  162. package/dist/layers.DWvD3vql.js +0 -220
  163. package/dist/layers.DXVNKM5t.js +0 -33
  164. package/dist/layers.DXg_yjAg.js +0 -10
  165. package/dist/layers.DYXNu8ur.js +0 -6
  166. package/dist/layers.Da3-MQaS.js +0 -315
  167. package/dist/layers.DbEYtfVc.js +0 -9166
  168. package/dist/layers.DbaKVP5e.js +0 -1
  169. package/dist/layers.Dc79Ci3K.js +0 -501
  170. package/dist/layers.DdaAmsdK.js +0 -1
  171. package/dist/layers.DeGb7buU.js +0 -9
  172. package/dist/layers.DeUrAJLR.js +0 -2479
  173. package/dist/layers.DfLG2r9J.js +0 -1
  174. package/dist/layers.DfVTedYs.js +0 -1
  175. package/dist/layers.DgM9vwax.js +0 -1
  176. package/dist/layers.Dhzc98B1.js +0 -1
  177. package/dist/layers.Dit1Y-a1.js +0 -9
  178. package/dist/layers.Dj4g5Vb5.js +0 -10
  179. package/dist/layers.DjUOC4st.js +0 -16
  180. package/dist/layers.DkOYepgq.js +0 -10
  181. package/dist/layers.Dld8CjhI.js +0 -8
  182. package/dist/layers.Dlp-dPD8.js +0 -96
  183. package/dist/layers.DlrAk6DA.js +0 -9
  184. package/dist/layers.Dm5fcqXE.js +0 -5
  185. package/dist/layers.DpuQVg48.js +0 -2966
  186. package/dist/layers.DqT5Jouj.js +0 -11
  187. package/dist/layers.DrlOZ3DT.js +0 -9
  188. package/dist/layers.DsSMSFyE.js +0 -9
  189. package/dist/layers.DtcuZ6vs.js +0 -187
  190. package/dist/layers.DuGoIpLS.js +0 -769
  191. package/dist/layers.DxA6ocdw.js +0 -70
  192. package/dist/layers.DxS_nrN5.js +0 -32
  193. package/dist/layers.DxhSwb8B.js +0 -791
  194. package/dist/layers.DxwOJMY_.js +0 -2
  195. package/dist/layers.Dy1naDTQ.js +0 -14
  196. package/dist/layers.DyPFKCS6.js +0 -1580
  197. package/dist/layers.DyydDZDU.js +0 -41
  198. package/dist/layers.GaSOetZx.js +0 -7
  199. package/dist/layers.IAZiYFRK.js +0 -35
  200. package/dist/layers.JWCLFILJ.js +0 -1
  201. package/dist/layers.JgqeK3h7.js +0 -1
  202. package/dist/layers.K2rcpzhY.js +0 -4
  203. package/dist/layers.KIWs25tZ.js +0 -1
  204. package/dist/layers.LLke4z7b.js +0 -13
  205. package/dist/layers.Marfmnqs.js +0 -61
  206. package/dist/layers.OFho5MbN.js +0 -118
  207. package/dist/layers.R8QN7W65.js +0 -1
  208. package/dist/layers.RT_eBoD-.js +0 -35
  209. package/dist/layers.SbloXQp4.js +0 -9
  210. package/dist/layers.SvUN62A9.js +0 -11
  211. package/dist/layers.TGEy1wS6.js +0 -32
  212. package/dist/layers.TdE-jeZL.js +0 -7
  213. package/dist/layers.UWRNxgT8.js +0 -8
  214. package/dist/layers.VA5efHzM.js +0 -39
  215. package/dist/layers._2_sfSMa.js +0 -1
  216. package/dist/layers.ajIRcGd4.js +0 -1126
  217. package/dist/layers.b0h5ZBmD.js +0 -61
  218. package/dist/layers.cjE12qw2.js +0 -9
  219. package/dist/layers.dJvyCZ1b.js +0 -2
  220. package/dist/layers.da887to_.js +0 -8
  221. package/dist/layers.dhxVHEDE.js +0 -1
  222. package/dist/layers.ejvu1U9t.js +0 -122
  223. package/dist/layers.epvyXTdV.js +0 -373
  224. package/dist/layers.fm_nJlxH.js +0 -6
  225. package/dist/layers.guGfRsPS.js +0 -39
  226. package/dist/layers.hweLqW3I.js +0 -261
  227. package/dist/layers.j04tfCKj.js +0 -39
  228. package/dist/layers.kzDq9Q-l.js +0 -1
  229. package/dist/layers.lCpg7dOn.js +0 -21
  230. package/dist/layers.ldz4asX5.js +0 -202
  231. package/dist/layers.ov1rbOW3.js +0 -1
  232. package/dist/layers.pHVqEwm3.js +0 -32
  233. package/dist/layers.rgYI6gus.js +0 -803
  234. package/dist/layers.sTUiyAuM.js +0 -41
  235. package/dist/layers.uMaAjCOP.js +0 -931
  236. package/dist/layers.vJ0fdhPp.js +0 -282
  237. package/dist/layers.vqKLXMfn.js +0 -1034
  238. package/dist/layers.wSBHMHgW.js +0 -42
  239. package/dist/layers.yquOOwF7.js +0 -7
  240. package/dist/layers.zJTwyIu5.js +0 -960
@@ -1,793 +0,0 @@
1
- import { a2 as gt, a3 as ft, a4 as mt, g as xt, l as E, d as G, Y as _t, a5 as bt, q as kt } from "./layers.DbEYtfVc.js";
2
- import "./layers.Cz4E3Gls.js";
3
- import { a as D } from "./layers.CPEzOey-.js";
4
- var K = (function() {
5
- var n = function(f, i, r, c) {
6
- for (r = r || {}, c = f.length; c--; r[f[c]] = i)
7
- ;
8
- return r;
9
- }, t = [6, 8, 10, 11, 12, 14, 16, 17, 20, 21], e = [1, 9], a = [1, 10], s = [1, 11], h = [1, 12], l = [1, 13], p = [1, 16], y = [1, 17], g = {
10
- trace: function() {
11
- },
12
- yy: {},
13
- symbols_: { error: 2, start: 3, timeline: 4, document: 5, EOF: 6, line: 7, SPACE: 8, statement: 9, NEWLINE: 10, title: 11, acc_title: 12, acc_title_value: 13, acc_descr: 14, acc_descr_value: 15, acc_descr_multiline_value: 16, section: 17, period_statement: 18, event_statement: 19, period: 20, event: 21, $accept: 0, $end: 1 },
14
- terminals_: { 2: "error", 4: "timeline", 6: "EOF", 8: "SPACE", 10: "NEWLINE", 11: "title", 12: "acc_title", 13: "acc_title_value", 14: "acc_descr", 15: "acc_descr_value", 16: "acc_descr_multiline_value", 17: "section", 20: "period", 21: "event" },
15
- productions_: [0, [3, 3], [5, 0], [5, 2], [7, 2], [7, 1], [7, 1], [7, 1], [9, 1], [9, 2], [9, 2], [9, 1], [9, 1], [9, 1], [9, 1], [18, 1], [19, 1]],
16
- performAction: function(i, r, c, d, u, o, $) {
17
- var x = o.length - 1;
18
- switch (u) {
19
- case 1:
20
- return o[x - 1];
21
- case 2:
22
- this.$ = [];
23
- break;
24
- case 3:
25
- o[x - 1].push(o[x]), this.$ = o[x - 1];
26
- break;
27
- case 4:
28
- case 5:
29
- this.$ = o[x];
30
- break;
31
- case 6:
32
- case 7:
33
- this.$ = [];
34
- break;
35
- case 8:
36
- d.getCommonDb().setDiagramTitle(o[x].substr(6)), this.$ = o[x].substr(6);
37
- break;
38
- case 9:
39
- this.$ = o[x].trim(), d.getCommonDb().setAccTitle(this.$);
40
- break;
41
- case 10:
42
- case 11:
43
- this.$ = o[x].trim(), d.getCommonDb().setAccDescription(this.$);
44
- break;
45
- case 12:
46
- d.addSection(o[x].substr(8)), this.$ = o[x].substr(8);
47
- break;
48
- case 15:
49
- d.addTask(o[x], 0, ""), this.$ = o[x];
50
- break;
51
- case 16:
52
- d.addEvent(o[x].substr(2)), this.$ = o[x];
53
- break;
54
- }
55
- },
56
- table: [{ 3: 1, 4: [1, 2] }, { 1: [3] }, n(t, [2, 2], { 5: 3 }), { 6: [1, 4], 7: 5, 8: [1, 6], 9: 7, 10: [1, 8], 11: e, 12: a, 14: s, 16: h, 17: l, 18: 14, 19: 15, 20: p, 21: y }, n(t, [2, 7], { 1: [2, 1] }), n(t, [2, 3]), { 9: 18, 11: e, 12: a, 14: s, 16: h, 17: l, 18: 14, 19: 15, 20: p, 21: y }, n(t, [2, 5]), n(t, [2, 6]), n(t, [2, 8]), { 13: [1, 19] }, { 15: [1, 20] }, n(t, [2, 11]), n(t, [2, 12]), n(t, [2, 13]), n(t, [2, 14]), n(t, [2, 15]), n(t, [2, 16]), n(t, [2, 4]), n(t, [2, 9]), n(t, [2, 10])],
57
- defaultActions: {},
58
- parseError: function(i, r) {
59
- if (r.recoverable)
60
- this.trace(i);
61
- else {
62
- var c = new Error(i);
63
- throw c.hash = r, c;
64
- }
65
- },
66
- parse: function(i) {
67
- var r = this, c = [0], d = [], u = [null], o = [], $ = this.table, x = "", T = 0, W = 0, C = 2, A = 1, B = o.slice.call(arguments, 1), k = Object.create(this.lexer), w = { yy: {} };
68
- for (var v in this.yy)
69
- Object.prototype.hasOwnProperty.call(this.yy, v) && (w.yy[v] = this.yy[v]);
70
- k.setInput(i, w.yy), w.yy.lexer = k, w.yy.parser = this, typeof k.yylloc > "u" && (k.yylloc = {});
71
- var I = k.yylloc;
72
- o.push(I);
73
- var H = k.options && k.options.ranges;
74
- typeof w.yy.parseError == "function" ? this.parseError = w.yy.parseError : this.parseError = Object.getPrototypeOf(this).parseError;
75
- function z() {
76
- var M;
77
- return M = d.pop() || k.lex() || A, typeof M != "number" && (M instanceof Array && (d = M, M = d.pop()), M = r.symbols_[M] || M), M;
78
- }
79
- for (var b, L, S, Z, R = {}, O, N, Y, j; ; ) {
80
- if (L = c[c.length - 1], this.defaultActions[L] ? S = this.defaultActions[L] : ((b === null || typeof b > "u") && (b = z()), S = $[L] && $[L][b]), typeof S > "u" || !S.length || !S[0]) {
81
- var J = "";
82
- j = [];
83
- for (O in $[L])
84
- this.terminals_[O] && O > C && j.push("'" + this.terminals_[O] + "'");
85
- k.showPosition ? J = "Parse error on line " + (T + 1) + `:
86
- ` + k.showPosition() + `
87
- Expecting ` + j.join(", ") + ", got '" + (this.terminals_[b] || b) + "'" : J = "Parse error on line " + (T + 1) + ": Unexpected " + (b == A ? "end of input" : "'" + (this.terminals_[b] || b) + "'"), this.parseError(J, {
88
- text: k.match,
89
- token: this.terminals_[b] || b,
90
- line: k.yylineno,
91
- loc: I,
92
- expected: j
93
- });
94
- }
95
- if (S[0] instanceof Array && S.length > 1)
96
- throw new Error("Parse Error: multiple actions possible at state: " + L + ", token: " + b);
97
- switch (S[0]) {
98
- case 1:
99
- c.push(b), u.push(k.yytext), o.push(k.yylloc), c.push(S[1]), b = null, W = k.yyleng, x = k.yytext, T = k.yylineno, I = k.yylloc;
100
- break;
101
- case 2:
102
- if (N = this.productions_[S[1]][1], R.$ = u[u.length - N], R._$ = {
103
- first_line: o[o.length - (N || 1)].first_line,
104
- last_line: o[o.length - 1].last_line,
105
- first_column: o[o.length - (N || 1)].first_column,
106
- last_column: o[o.length - 1].last_column
107
- }, H && (R._$.range = [
108
- o[o.length - (N || 1)].range[0],
109
- o[o.length - 1].range[1]
110
- ]), Z = this.performAction.apply(R, [
111
- x,
112
- W,
113
- T,
114
- w.yy,
115
- S[1],
116
- u,
117
- o
118
- ].concat(B)), typeof Z < "u")
119
- return Z;
120
- N && (c = c.slice(0, -1 * N * 2), u = u.slice(0, -1 * N), o = o.slice(0, -1 * N)), c.push(this.productions_[S[1]][0]), u.push(R.$), o.push(R._$), Y = $[c[c.length - 2]][c[c.length - 1]], c.push(Y);
121
- break;
122
- case 3:
123
- return !0;
124
- }
125
- }
126
- return !0;
127
- }
128
- }, _ = /* @__PURE__ */ (function() {
129
- var f = {
130
- EOF: 1,
131
- parseError: function(r, c) {
132
- if (this.yy.parser)
133
- this.yy.parser.parseError(r, c);
134
- else
135
- throw new Error(r);
136
- },
137
- // resets the lexer, sets new input
138
- setInput: function(i, r) {
139
- return this.yy = r || 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 = {
140
- first_line: 1,
141
- first_column: 0,
142
- last_line: 1,
143
- last_column: 0
144
- }, this.options.ranges && (this.yylloc.range = [0, 0]), this.offset = 0, this;
145
- },
146
- // consumes and returns one char from the input
147
- input: function() {
148
- var i = this._input[0];
149
- this.yytext += i, this.yyleng++, this.offset++, this.match += i, this.matched += i;
150
- var r = i.match(/(?:\r\n?|\n).*/g);
151
- return r ? (this.yylineno++, this.yylloc.last_line++) : this.yylloc.last_column++, this.options.ranges && this.yylloc.range[1]++, this._input = this._input.slice(1), i;
152
- },
153
- // unshifts one char (or a string) into the input
154
- unput: function(i) {
155
- var r = i.length, c = i.split(/(?:\r\n?|\n)/g);
156
- this._input = i + this._input, this.yytext = this.yytext.substr(0, this.yytext.length - r), this.offset -= r;
157
- var d = this.match.split(/(?:\r\n?|\n)/g);
158
- 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);
159
- var u = this.yylloc.range;
160
- return this.yylloc = {
161
- first_line: this.yylloc.first_line,
162
- last_line: this.yylineno + 1,
163
- first_column: this.yylloc.first_column,
164
- last_column: c ? (c.length === d.length ? this.yylloc.first_column : 0) + d[d.length - c.length].length - c[0].length : this.yylloc.first_column - r
165
- }, this.options.ranges && (this.yylloc.range = [u[0], u[0] + this.yyleng - r]), this.yyleng = this.yytext.length, this;
166
- },
167
- // When called from action, caches matched text and appends it on next action
168
- more: function() {
169
- return this._more = !0, this;
170
- },
171
- // 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.
172
- reject: function() {
173
- if (this.options.backtrack_lexer)
174
- this._backtrack = !0;
175
- else
176
- 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).
177
- ` + this.showPosition(), {
178
- text: "",
179
- token: null,
180
- line: this.yylineno
181
- });
182
- return this;
183
- },
184
- // retain first n characters of the match
185
- less: function(i) {
186
- this.unput(this.match.slice(i));
187
- },
188
- // displays already matched input, i.e. for error messages
189
- pastInput: function() {
190
- var i = this.matched.substr(0, this.matched.length - this.match.length);
191
- return (i.length > 20 ? "..." : "") + i.substr(-20).replace(/\n/g, "");
192
- },
193
- // displays upcoming input, i.e. for error messages
194
- upcomingInput: function() {
195
- var i = this.match;
196
- return i.length < 20 && (i += this._input.substr(0, 20 - i.length)), (i.substr(0, 20) + (i.length > 20 ? "..." : "")).replace(/\n/g, "");
197
- },
198
- // displays the character position where the lexing error occurred, i.e. for error messages
199
- showPosition: function() {
200
- var i = this.pastInput(), r = new Array(i.length + 1).join("-");
201
- return i + this.upcomingInput() + `
202
- ` + r + "^";
203
- },
204
- // test the lexed token: return FALSE when not a match, otherwise return token
205
- test_match: function(i, r) {
206
- var c, d, u;
207
- if (this.options.backtrack_lexer && (u = {
208
- yylineno: this.yylineno,
209
- yylloc: {
210
- first_line: this.yylloc.first_line,
211
- last_line: this.last_line,
212
- first_column: this.yylloc.first_column,
213
- last_column: this.yylloc.last_column
214
- },
215
- yytext: this.yytext,
216
- match: this.match,
217
- matches: this.matches,
218
- matched: this.matched,
219
- yyleng: this.yyleng,
220
- offset: this.offset,
221
- _more: this._more,
222
- _input: this._input,
223
- yy: this.yy,
224
- conditionStack: this.conditionStack.slice(0),
225
- done: this.done
226
- }, this.options.ranges && (u.yylloc.range = this.yylloc.range.slice(0))), d = i[0].match(/(?:\r\n?|\n).*/g), d && (this.yylineno += d.length), this.yylloc = {
227
- first_line: this.yylloc.last_line,
228
- last_line: this.yylineno + 1,
229
- first_column: this.yylloc.last_column,
230
- last_column: d ? d[d.length - 1].length - d[d.length - 1].match(/\r?\n?/)[0].length : this.yylloc.last_column + i[0].length
231
- }, 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, r, this.conditionStack[this.conditionStack.length - 1]), this.done && this._input && (this.done = !1), c)
232
- return c;
233
- if (this._backtrack) {
234
- for (var o in u)
235
- this[o] = u[o];
236
- return !1;
237
- }
238
- return !1;
239
- },
240
- // return next match in input
241
- next: function() {
242
- if (this.done)
243
- return this.EOF;
244
- this._input || (this.done = !0);
245
- var i, r, c, d;
246
- this._more || (this.yytext = "", this.match = "");
247
- for (var u = this._currentRules(), o = 0; o < u.length; o++)
248
- if (c = this._input.match(this.rules[u[o]]), c && (!r || c[0].length > r[0].length)) {
249
- if (r = c, d = o, this.options.backtrack_lexer) {
250
- if (i = this.test_match(c, u[o]), i !== !1)
251
- return i;
252
- if (this._backtrack) {
253
- r = !1;
254
- continue;
255
- } else
256
- return !1;
257
- } else if (!this.options.flex)
258
- break;
259
- }
260
- return r ? (i = this.test_match(r, u[d]), i !== !1 ? i : !1) : this._input === "" ? this.EOF : this.parseError("Lexical error on line " + (this.yylineno + 1) + `. Unrecognized text.
261
- ` + this.showPosition(), {
262
- text: "",
263
- token: null,
264
- line: this.yylineno
265
- });
266
- },
267
- // return next match that has a token
268
- lex: function() {
269
- var r = this.next();
270
- return r || this.lex();
271
- },
272
- // activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)
273
- begin: function(r) {
274
- this.conditionStack.push(r);
275
- },
276
- // pop the previously active lexer condition state off the condition stack
277
- popState: function() {
278
- var r = this.conditionStack.length - 1;
279
- return r > 0 ? this.conditionStack.pop() : this.conditionStack[0];
280
- },
281
- // produce the lexer rule set which is active for the currently active lexer condition state
282
- _currentRules: function() {
283
- return this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1] ? this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules : this.conditions.INITIAL.rules;
284
- },
285
- // return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available
286
- topState: function(r) {
287
- return r = this.conditionStack.length - 1 - Math.abs(r || 0), r >= 0 ? this.conditionStack[r] : "INITIAL";
288
- },
289
- // alias for begin(condition)
290
- pushState: function(r) {
291
- this.begin(r);
292
- },
293
- // return the number of states currently on the stack
294
- stateStackSize: function() {
295
- return this.conditionStack.length;
296
- },
297
- options: { "case-insensitive": !0 },
298
- performAction: function(r, c, d, u) {
299
- switch (d) {
300
- case 0:
301
- break;
302
- case 1:
303
- break;
304
- case 2:
305
- return 10;
306
- case 3:
307
- break;
308
- case 4:
309
- break;
310
- case 5:
311
- return 4;
312
- case 6:
313
- return 11;
314
- case 7:
315
- return this.begin("acc_title"), 12;
316
- case 8:
317
- return this.popState(), "acc_title_value";
318
- case 9:
319
- return this.begin("acc_descr"), 14;
320
- case 10:
321
- return this.popState(), "acc_descr_value";
322
- case 11:
323
- this.begin("acc_descr_multiline");
324
- break;
325
- case 12:
326
- this.popState();
327
- break;
328
- case 13:
329
- return "acc_descr_multiline_value";
330
- case 14:
331
- return 17;
332
- case 15:
333
- return 21;
334
- case 16:
335
- return 20;
336
- case 17:
337
- return 6;
338
- case 18:
339
- return "INVALID";
340
- }
341
- },
342
- rules: [/^(?:%(?!\{)[^\n]*)/i, /^(?:[^\}]%%[^\n]*)/i, /^(?:[\n]+)/i, /^(?:\s+)/i, /^(?:#[^\n]*)/i, /^(?:timeline\b)/i, /^(?:title\s[^#\n;]+)/i, /^(?:accTitle\s*:\s*)/i, /^(?:(?!\n||)*[^\n]*)/i, /^(?:accDescr\s*:\s*)/i, /^(?:(?!\n||)*[^\n]*)/i, /^(?:accDescr\s*\{\s*)/i, /^(?:[\}])/i, /^(?:[^\}]*)/i, /^(?:section\s[^#:\n;]+)/i, /^(?::\s[^#:\n;]+)/i, /^(?:[^#:\n;]+)/i, /^(?:$)/i, /^(?:.)/i],
343
- conditions: { acc_descr_multiline: { rules: [12, 13], inclusive: !1 }, acc_descr: { rules: [10], inclusive: !1 }, acc_title: { rules: [8], inclusive: !1 }, INITIAL: { rules: [0, 1, 2, 3, 4, 5, 6, 7, 9, 11, 14, 15, 16, 17, 18], inclusive: !0 } }
344
- };
345
- return f;
346
- })();
347
- g.lexer = _;
348
- function m() {
349
- this.yy = {};
350
- }
351
- return m.prototype = g, g.Parser = m, new m();
352
- })();
353
- K.parser = K;
354
- const vt = K;
355
- let F = "", st = 0;
356
- const Q = [], q = [], V = [], it = () => bt, rt = function() {
357
- Q.length = 0, q.length = 0, F = "", V.length = 0, kt();
358
- }, at = function(n) {
359
- F = n, Q.push(n);
360
- }, lt = function() {
361
- return Q;
362
- }, ot = function() {
363
- let n = tt();
364
- const t = 100;
365
- let e = 0;
366
- for (; !n && e < t; )
367
- n = tt(), e++;
368
- return q.push(...V), q;
369
- }, ct = function(n, t, e) {
370
- const a = {
371
- id: st++,
372
- section: F,
373
- type: F,
374
- task: n,
375
- score: t || 0,
376
- //if event is defined, then add it the events array
377
- events: e ? [e] : []
378
- };
379
- V.push(a);
380
- }, ht = function(n) {
381
- V.find((e) => e.id === st - 1).events.push(n);
382
- }, dt = function(n) {
383
- const t = {
384
- section: F,
385
- type: F,
386
- description: n,
387
- task: n,
388
- classes: []
389
- };
390
- q.push(t);
391
- }, tt = function() {
392
- const n = function(e) {
393
- return V[e].processed;
394
- };
395
- let t = !0;
396
- for (const [e, a] of V.entries())
397
- n(e), t = t && a.processed;
398
- return t;
399
- }, wt = {
400
- clear: rt,
401
- getCommonDb: it,
402
- addSection: at,
403
- getSections: lt,
404
- getTasks: ot,
405
- addTask: ct,
406
- addTaskOrg: dt,
407
- addEvent: ht
408
- }, St = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
409
- __proto__: null,
410
- addEvent: ht,
411
- addSection: at,
412
- addTask: ct,
413
- addTaskOrg: dt,
414
- clear: rt,
415
- default: wt,
416
- getCommonDb: it,
417
- getSections: lt,
418
- getTasks: ot
419
- }, Symbol.toStringTag, { value: "Module" })), Et = 12, U = function(n, t) {
420
- const e = n.append("rect");
421
- return e.attr("x", t.x), e.attr("y", t.y), e.attr("fill", t.fill), e.attr("stroke", t.stroke), e.attr("width", t.width), e.attr("height", t.height), e.attr("rx", t.rx), e.attr("ry", t.ry), t.class !== void 0 && e.attr("class", t.class), e;
422
- }, Tt = function(n, t) {
423
- const a = n.append("circle").attr("cx", t.cx).attr("cy", t.cy).attr("class", "face").attr("r", 15).attr("stroke-width", 2).attr("overflow", "visible"), s = n.append("g");
424
- s.append("circle").attr("cx", t.cx - 15 / 3).attr("cy", t.cy - 15 / 3).attr("r", 1.5).attr("stroke-width", 2).attr("fill", "#666").attr("stroke", "#666"), s.append("circle").attr("cx", t.cx + 15 / 3).attr("cy", t.cy - 15 / 3).attr("r", 1.5).attr("stroke-width", 2).attr("fill", "#666").attr("stroke", "#666");
425
- function h(y) {
426
- const g = D().startAngle(Math.PI / 2).endAngle(3 * (Math.PI / 2)).innerRadius(7.5).outerRadius(6.8181818181818175);
427
- y.append("path").attr("class", "mouth").attr("d", g).attr("transform", "translate(" + t.cx + "," + (t.cy + 2) + ")");
428
- }
429
- function l(y) {
430
- const g = D().startAngle(3 * Math.PI / 2).endAngle(5 * (Math.PI / 2)).innerRadius(7.5).outerRadius(6.8181818181818175);
431
- y.append("path").attr("class", "mouth").attr("d", g).attr("transform", "translate(" + t.cx + "," + (t.cy + 7) + ")");
432
- }
433
- function p(y) {
434
- y.append("line").attr("class", "mouth").attr("stroke", 2).attr("x1", t.cx - 5).attr("y1", t.cy + 7).attr("x2", t.cx + 5).attr("y2", t.cy + 7).attr("class", "mouth").attr("stroke-width", "1px").attr("stroke", "#666");
435
- }
436
- return t.score > 3 ? h(s) : t.score < 3 ? l(s) : p(s), a;
437
- }, It = function(n, t) {
438
- const e = n.append("circle");
439
- return e.attr("cx", t.cx), e.attr("cy", t.cy), e.attr("class", "actor-" + t.pos), e.attr("fill", t.fill), e.attr("stroke", t.stroke), e.attr("r", t.r), e.class !== void 0 && e.attr("class", e.class), t.title !== void 0 && e.append("title").text(t.title), e;
440
- }, ut = function(n, t) {
441
- const e = t.text.replace(/<br\s*\/?>/gi, " "), a = n.append("text");
442
- a.attr("x", t.x), a.attr("y", t.y), a.attr("class", "legend"), a.style("text-anchor", t.anchor), t.class !== void 0 && a.attr("class", t.class);
443
- const s = a.append("tspan");
444
- return s.attr("x", t.x + t.textMargin * 2), s.text(e), a;
445
- }, $t = function(n, t) {
446
- function e(s, h, l, p, y) {
447
- return s + "," + h + " " + (s + l) + "," + h + " " + (s + l) + "," + (h + p - y) + " " + (s + l - y * 1.2) + "," + (h + p) + " " + s + "," + (h + p);
448
- }
449
- const a = n.append("polygon");
450
- a.attr("points", e(t.x, t.y, 50, 20, 7)), a.attr("class", "labelBox"), t.y = t.y + t.labelMargin, t.x = t.x + 0.5 * t.labelMargin, ut(n, t);
451
- }, Nt = function(n, t, e) {
452
- const a = n.append("g"), s = X();
453
- s.x = t.x, s.y = t.y, s.fill = t.fill, s.width = e.width, s.height = e.height, s.class = "journey-section section-type-" + t.num, s.rx = 3, s.ry = 3, U(a, s), pt(e)(
454
- t.text,
455
- a,
456
- s.x,
457
- s.y,
458
- s.width,
459
- s.height,
460
- { class: "journey-section section-type-" + t.num },
461
- e,
462
- t.colour
463
- );
464
- };
465
- let et = -1;
466
- const Mt = function(n, t, e) {
467
- const a = t.x + e.width / 2, s = n.append("g");
468
- et++, s.append("line").attr("id", "task" + et).attr("x1", a).attr("y1", t.y).attr("x2", a).attr("y2", 450).attr("class", "task-line").attr("stroke-width", "1px").attr("stroke-dasharray", "4 2").attr("stroke", "#666"), Tt(s, {
469
- cx: a,
470
- cy: 300 + (5 - t.score) * 30,
471
- score: t.score
472
- });
473
- const l = X();
474
- l.x = t.x, l.y = t.y, l.fill = t.fill, l.width = e.width, l.height = e.height, l.class = "task task-type-" + t.num, l.rx = 3, l.ry = 3, U(s, l), t.x + 14, pt(e)(
475
- t.task,
476
- s,
477
- l.x,
478
- l.y,
479
- l.width,
480
- l.height,
481
- { class: "task" },
482
- e,
483
- t.colour
484
- );
485
- }, Lt = function(n, t) {
486
- U(n, {
487
- x: t.startx,
488
- y: t.starty,
489
- width: t.stopx - t.startx,
490
- height: t.stopy - t.starty,
491
- fill: t.fill,
492
- class: "rect"
493
- }).lower();
494
- }, At = function() {
495
- return {
496
- x: 0,
497
- y: 0,
498
- fill: void 0,
499
- "text-anchor": "start",
500
- width: 100,
501
- height: 100,
502
- textMargin: 0,
503
- rx: 0,
504
- ry: 0
505
- };
506
- }, X = function() {
507
- return {
508
- x: 0,
509
- y: 0,
510
- width: 100,
511
- anchor: "start",
512
- height: 100,
513
- rx: 0,
514
- ry: 0
515
- };
516
- }, pt = /* @__PURE__ */ (function() {
517
- function n(s, h, l, p, y, g, _, m) {
518
- const f = h.append("text").attr("x", l + y / 2).attr("y", p + g / 2 + 5).style("font-color", m).style("text-anchor", "middle").text(s);
519
- a(f, _);
520
- }
521
- function t(s, h, l, p, y, g, _, m, f) {
522
- const { taskFontSize: i, taskFontFamily: r } = m, c = s.split(/<br\s*\/?>/gi);
523
- for (let d = 0; d < c.length; d++) {
524
- const u = d * i - i * (c.length - 1) / 2, o = h.append("text").attr("x", l + y / 2).attr("y", p).attr("fill", f).style("text-anchor", "middle").style("font-size", i).style("font-family", r);
525
- o.append("tspan").attr("x", l + y / 2).attr("dy", u).text(c[d]), o.attr("y", p + g / 2).attr("dominant-baseline", "central").attr("alignment-baseline", "central"), a(o, _);
526
- }
527
- }
528
- function e(s, h, l, p, y, g, _, m) {
529
- const f = h.append("switch"), r = f.append("foreignObject").attr("x", l).attr("y", p).attr("width", y).attr("height", g).attr("position", "fixed").append("xhtml:div").style("display", "table").style("height", "100%").style("width", "100%");
530
- r.append("div").attr("class", "label").style("display", "table-cell").style("text-align", "center").style("vertical-align", "middle").text(s), t(s, f, l, p, y, g, _, m), a(r, _);
531
- }
532
- function a(s, h) {
533
- for (const l in h)
534
- l in h && s.attr(l, h[l]);
535
- }
536
- return function(s) {
537
- return s.textPlacement === "fo" ? e : s.textPlacement === "old" ? n : t;
538
- };
539
- })(), Ht = function(n) {
540
- n.append("defs").append("marker").attr("id", "arrowhead").attr("refX", 5).attr("refY", 2).attr("markerWidth", 6).attr("markerHeight", 4).attr("orient", "auto").append("path").attr("d", "M 0,0 V 4 L6,2 Z");
541
- };
542
- function yt(n, t) {
543
- n.each(function() {
544
- var e = G(this), a = e.text().split(/(\s+|<br>)/).reverse(), s, h = [], l = 1.1, p = e.attr("y"), y = parseFloat(e.attr("dy")), g = e.text(null).append("tspan").attr("x", 0).attr("y", p).attr("dy", y + "em");
545
- for (let _ = 0; _ < a.length; _++)
546
- s = a[a.length - 1 - _], h.push(s), g.text(h.join(" ").trim()), (g.node().getComputedTextLength() > t || s === "<br>") && (h.pop(), g.text(h.join(" ").trim()), s === "<br>" ? h = [""] : h = [s], g = e.append("tspan").attr("x", 0).attr("y", p).attr("dy", l + "em").text(s));
547
- });
548
- }
549
- const Pt = function(n, t, e, a) {
550
- const s = e % Et - 1, h = n.append("g");
551
- t.section = s, h.attr(
552
- "class",
553
- (t.class ? t.class + " " : "") + "timeline-node " + ("section-" + s)
554
- );
555
- const l = h.append("g"), p = h.append("g"), g = p.append("text").text(t.descr).attr("dy", "1em").attr("alignment-baseline", "middle").attr("dominant-baseline", "middle").attr("text-anchor", "middle").call(yt, t.width).node().getBBox(), _ = a.fontSize && a.fontSize.replace ? a.fontSize.replace("px", "") : a.fontSize;
556
- return t.height = g.height + _ * 1.1 * 0.5 + t.padding, t.height = Math.max(t.height, t.maxHeight), t.width = t.width + 2 * t.padding, p.attr("transform", "translate(" + t.width / 2 + ", " + t.padding / 2 + ")"), zt(l, t, s), t;
557
- }, Ct = function(n, t, e) {
558
- const a = n.append("g"), h = a.append("text").text(t.descr).attr("dy", "1em").attr("alignment-baseline", "middle").attr("dominant-baseline", "middle").attr("text-anchor", "middle").call(yt, t.width).node().getBBox(), l = e.fontSize && e.fontSize.replace ? e.fontSize.replace("px", "") : e.fontSize;
559
- return a.remove(), h.height + l * 1.1 * 0.5 + t.padding;
560
- }, zt = function(n, t, e) {
561
- n.append("path").attr("id", "node-" + t.id).attr("class", "node-bkg node-" + t.type).attr(
562
- "d",
563
- `M0 ${t.height - 5} v${-t.height + 10} q0,-5 5,-5 h${t.width - 10} q5,0 5,5 v${t.height - 5} H0 Z`
564
- ), n.append("line").attr("class", "node-line-" + e).attr("x1", 0).attr("y1", t.height).attr("x2", t.width).attr("y2", t.height);
565
- }, P = {
566
- drawRect: U,
567
- drawCircle: It,
568
- drawSection: Nt,
569
- drawText: ut,
570
- drawLabel: $t,
571
- drawTask: Mt,
572
- drawBackgroundRect: Lt,
573
- getTextObj: At,
574
- getNoteRect: X,
575
- initGraphics: Ht,
576
- drawNode: Pt,
577
- getVirtualNodeHeight: Ct
578
- }, Rt = function(n, t, e, a) {
579
- var s, h;
580
- const l = xt(), p = l.leftMargin ?? 50;
581
- E.debug("timeline", a.db);
582
- const y = l.securityLevel;
583
- let g;
584
- y === "sandbox" && (g = G("#i" + t));
585
- const m = (y === "sandbox" ? G(g.nodes()[0].contentDocument.body) : G("body")).select("#" + t);
586
- m.append("g");
587
- const f = a.db.getTasks(), i = a.db.getCommonDb().getDiagramTitle();
588
- E.debug("task", f), P.initGraphics(m);
589
- const r = a.db.getSections();
590
- E.debug("sections", r);
591
- let c = 0, d = 0, u = 0, o = 0, $ = 50 + p, x = 50;
592
- o = 50;
593
- let T = 0, W = !0;
594
- r.forEach(function(w) {
595
- const v = {
596
- number: T,
597
- descr: w,
598
- section: T,
599
- width: 150,
600
- padding: 20,
601
- maxHeight: c
602
- }, I = P.getVirtualNodeHeight(m, v, l);
603
- E.debug("sectionHeight before draw", I), c = Math.max(c, I + 20);
604
- });
605
- let C = 0, A = 0;
606
- E.debug("tasks.length", f.length);
607
- for (const [w, v] of f.entries()) {
608
- const I = {
609
- number: w,
610
- descr: v,
611
- section: v.section,
612
- width: 150,
613
- padding: 20,
614
- maxHeight: d
615
- }, H = P.getVirtualNodeHeight(m, I, l);
616
- E.debug("taskHeight before draw", H), d = Math.max(d, H + 20), C = Math.max(C, v.events.length);
617
- let z = 0;
618
- for (let b = 0; b < v.events.length; b++) {
619
- const S = {
620
- descr: v.events[b],
621
- section: v.section,
622
- number: v.section,
623
- width: 150,
624
- padding: 20,
625
- maxHeight: 50
626
- };
627
- z += P.getVirtualNodeHeight(m, S, l);
628
- }
629
- A = Math.max(A, z);
630
- }
631
- E.debug("maxSectionHeight before draw", c), E.debug("maxTaskHeight before draw", d), r && r.length > 0 ? r.forEach((w) => {
632
- const v = f.filter((b) => b.section === w), I = {
633
- number: T,
634
- descr: w,
635
- section: T,
636
- width: 200 * Math.max(v.length, 1) - 50,
637
- padding: 20,
638
- maxHeight: c
639
- };
640
- E.debug("sectionNode", I);
641
- const H = m.append("g"), z = P.drawNode(H, I, T, l);
642
- E.debug("sectionNode output", z), H.attr("transform", `translate(${$}, ${o})`), x += c + 50, v.length > 0 && nt(
643
- m,
644
- v,
645
- T,
646
- $,
647
- x,
648
- d,
649
- l,
650
- C,
651
- A,
652
- c,
653
- !1
654
- ), $ += 200 * Math.max(v.length, 1), x = o, T++;
655
- }) : (W = !1, nt(
656
- m,
657
- f,
658
- T,
659
- $,
660
- x,
661
- d,
662
- l,
663
- C,
664
- A,
665
- c,
666
- !0
667
- ));
668
- const B = m.node().getBBox();
669
- E.debug("bounds", B), i && m.append("text").text(i).attr("x", B.width / 2 - p).attr("font-size", "4ex").attr("font-weight", "bold").attr("y", 20), u = W ? c + d + 150 : d + 100, m.append("g").attr("class", "lineWrapper").append("line").attr("x1", p).attr("y1", u).attr("x2", B.width + 3 * p).attr("y2", u).attr("stroke-width", 4).attr("stroke", "black").attr("marker-end", "url(#arrowhead)"), _t(
670
- void 0,
671
- m,
672
- ((s = l.timeline) == null ? void 0 : s.padding) ?? 50,
673
- ((h = l.timeline) == null ? void 0 : h.useMaxWidth) ?? !1
674
- );
675
- }, nt = function(n, t, e, a, s, h, l, p, y, g, _) {
676
- var m;
677
- for (const f of t) {
678
- const i = {
679
- descr: f.task,
680
- section: e,
681
- number: e,
682
- width: 150,
683
- padding: 20,
684
- maxHeight: h
685
- };
686
- E.debug("taskNode", i);
687
- const r = n.append("g").attr("class", "taskWrapper"), d = P.drawNode(r, i, e, l).height;
688
- if (E.debug("taskHeight after draw", d), r.attr("transform", `translate(${a}, ${s})`), h = Math.max(h, d), f.events) {
689
- const u = n.append("g").attr("class", "lineWrapper");
690
- let o = h;
691
- s += 100, o = o + Ft(n, f.events, e, a, s, l), s -= 100, u.append("line").attr("x1", a + 190 / 2).attr("y1", s + h).attr("x2", a + 190 / 2).attr(
692
- "y2",
693
- s + h + (_ ? h : g) + y + 120
694
- ).attr("stroke-width", 2).attr("stroke", "black").attr("marker-end", "url(#arrowhead)").attr("stroke-dasharray", "5,5");
695
- }
696
- a = a + 200, _ && !((m = l.timeline) != null && m.disableMulticolor) && e++;
697
- }
698
- s = s - 10;
699
- }, Ft = function(n, t, e, a, s, h) {
700
- let l = 0;
701
- const p = s;
702
- s = s + 100;
703
- for (const y of t) {
704
- const g = {
705
- descr: y,
706
- section: e,
707
- number: e,
708
- width: 150,
709
- padding: 20,
710
- maxHeight: 50
711
- };
712
- E.debug("eventNode", g);
713
- const _ = n.append("g").attr("class", "eventWrapper"), f = P.drawNode(_, g, e, h).height;
714
- l = l + f, _.attr("transform", `translate(${a}, ${s})`), s = s + 10 + f;
715
- }
716
- return s = p, l;
717
- }, Vt = {
718
- setConf: () => {
719
- },
720
- draw: Rt
721
- }, Wt = (n) => {
722
- let t = "";
723
- for (let e = 0; e < n.THEME_COLOR_LIMIT; e++)
724
- n["lineColor" + e] = n["lineColor" + e] || n["cScaleInv" + e], gt(n["lineColor" + e]) ? n["lineColor" + e] = ft(n["lineColor" + e], 20) : n["lineColor" + e] = mt(n["lineColor" + e], 20);
725
- for (let e = 0; e < n.THEME_COLOR_LIMIT; e++) {
726
- const a = "" + (17 - 3 * e);
727
- t += `
728
- .section-${e - 1} rect, .section-${e - 1} path, .section-${e - 1} circle, .section-${e - 1} path {
729
- fill: ${n["cScale" + e]};
730
- }
731
- .section-${e - 1} text {
732
- fill: ${n["cScaleLabel" + e]};
733
- }
734
- .node-icon-${e - 1} {
735
- font-size: 40px;
736
- color: ${n["cScaleLabel" + e]};
737
- }
738
- .section-edge-${e - 1}{
739
- stroke: ${n["cScale" + e]};
740
- }
741
- .edge-depth-${e - 1}{
742
- stroke-width: ${a};
743
- }
744
- .section-${e - 1} line {
745
- stroke: ${n["cScaleInv" + e]} ;
746
- stroke-width: 3;
747
- }
748
-
749
- .lineWrapper line{
750
- stroke: ${n["cScaleLabel" + e]} ;
751
- }
752
-
753
- .disabled, .disabled circle, .disabled text {
754
- fill: lightgray;
755
- }
756
- .disabled text {
757
- fill: #efefef;
758
- }
759
- `;
760
- }
761
- return t;
762
- }, Bt = (n) => `
763
- .edge {
764
- stroke-width: 3;
765
- }
766
- ${Wt(n)}
767
- .section-root rect, .section-root path, .section-root circle {
768
- fill: ${n.git0};
769
- }
770
- .section-root text {
771
- fill: ${n.gitBranchLabel0};
772
- }
773
- .icon-container {
774
- height:100%;
775
- display: flex;
776
- justify-content: center;
777
- align-items: center;
778
- }
779
- .edge {
780
- fill: none;
781
- }
782
- .eventWrapper {
783
- filter: brightness(120%);
784
- }
785
- `, Ot = Bt, Ut = {
786
- db: St,
787
- renderer: Vt,
788
- parser: vt,
789
- styles: Ot
790
- };
791
- export {
792
- Ut as diagram
793
- };