@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.
- package/dist/Tableau10-GLA_9iAD-BMurskAd.js +9 -0
- package/dist/arc-BSRpyMf3-C5dasNo_.js +86 -0
- package/dist/array-CqVTtuYm-fKLgkG2b.js +6 -0
- package/dist/astro-mwoSwJnq-CNh-xuM0.js +27 -0
- package/dist/blockDiagram-6b2b5046-D02VCbQO-CPmGy0xX.js +1224 -0
- package/dist/c-eDnjw9rh-eDnjw9rh.js +87 -0
- package/dist/c4Diagram-b947cdbb-gYcL5VzP-DIDY83e1.js +1578 -0
- package/dist/channel-DHTQ8Ynn-7OPGex2S.js +5 -0
- package/dist/classDiagram-35230388-JdSKLSZv-D2crBRy-.js +217 -0
- package/dist/classDiagram-v2-412acd34-DFFRHXE_-B6aCxlD1.js +200 -0
- package/dist/clone-p6h9XXNm-3JQ-HRC6.js +8 -0
- package/dist/coffee-CRlSxcc3-CY091_1T.js +108 -0
- package/dist/cpp-DizfY48B-CA38N4Mn.js +208 -0
- package/dist/createText-423428c9-LivTKT7b-BXNfjcdp.js +2964 -0
- package/dist/csharp-uGDiXTZn-uGDiXTZn.js +762 -0
- package/dist/css-CAzixsid-CEpuX1HY.js +511 -0
- package/dist/csv-D4BoHddH-D4BoHddH.js +7 -0
- package/dist/diff-Bo5iyMQ2-Bo5iyMQ2.js +7 -0
- package/dist/docker-B10O2enb-B10O2enb.js +7 -0
- package/dist/documentation.es.js +5 -3130
- package/dist/documentation.umd.js +10152 -50
- package/dist/edges-d417c7a0-C1ggiwWz-Aj0OUf7e.js +1082 -0
- package/dist/erDiagram-0ea73325-mz0Z_-DA-Dr01LsTB.js +924 -0
- package/dist/flowDb-d35e309a-CPyxEMIt-lofeyUuw.js +1126 -0
- package/dist/flowDiagram-d949d7c1-DqCa0HNN-BK5wNO9Z.js +782 -0
- package/dist/flowDiagram-v2-49332944-UMosz1sZ-BG39AuNP.js +17 -0
- package/dist/flowchart-elk-definition-27cc417a-D2UKpS6N-r2p34307.js +48387 -0
- package/dist/ganttDiagram-5c869e3b-CVBHw4pG-CaG9QXQM.js +2490 -0
- package/dist/git-commit-CWf81VOF-DtOZSoIU.js +9 -0
- package/dist/git-rebase-sR-yVH_J-D5M2oE9O.js +9 -0
- package/dist/gitGraphDiagram-b9d81de9-BGm3fU0n-CbCpf-4j.js +1262 -0
- package/dist/go-BCCWZWY1-BCCWZWY1.js +7 -0
- package/dist/graph-4FyIWFHN-774TpNLL.js +870 -0
- package/dist/graphql-CT32SSoq-1pBWfpcR.js +18 -0
- package/dist/haml-8RvrfhLO-Bbc4xoLP.js +19 -0
- package/dist/handlebars-Cr5ro0bH-CLcCNLtV.js +15 -0
- package/dist/haskell-BfFu8DD8-BmkPJdLL.js +565 -0
- package/dist/html-BZB5lEhh-B74zAnWx.js +84 -0
- package/dist/html-derivative-0y7sV5Qc-D8-muTWn.js +9 -0
- package/dist/index-8fae9850-_CN7MNjP-Cq-s0PmS.js +373 -0
- package/dist/index-B-5DuDrq.js +29996 -0
- package/dist/infoDiagram-db7b18fc-V446j9uR-GSa8bniv.js +319 -0
- package/dist/ini-BsUFIxsI-BsUFIxsI.js +7 -0
- package/dist/init-DjUOC4st-C8Nwz6AJ.js +16 -0
- package/dist/java-Bk2JzfKB-Bk2JzfKB.js +74 -0
- package/dist/javascript-DqVBMyXe-DqVBMyXe.js +705 -0
- package/dist/journeyDiagram-d5636530-CFiu7dnV-DJMu6A22.js +803 -0
- package/dist/json-B12k4-6m-B12k4-6m.js +31 -0
- package/dist/json5-CvqQZK9I-CvqQZK9I.js +23 -0
- package/dist/jsonc-v2qGKRJY-v2qGKRJY.js +31 -0
- package/dist/jsonl-izxnMeZX-izxnMeZX.js +31 -0
- package/dist/jsx-aDp7j9_Z-aDp7j9_Z.js +705 -0
- package/dist/kotlin-NOMOielb-NOMOielb.js +7 -0
- package/dist/latex-Bw_ghldO-BlUAi6pB.js +339 -0
- package/dist/layout-2-aEcfuw-BqqWy5wB.js +1524 -0
- package/dist/less-CW2GmQHL-CW2GmQHL.js +165 -0
- package/dist/line-nVq5kEiy-DtZd3PHZ.js +34 -0
- package/dist/linear-Bz4oRFvQ-C869GXbm.js +447 -0
- package/dist/liquid-DJ2rh7oT-FwZwa67Y.js +28 -0
- package/dist/lua-5TZ-G8Be-CogscVHC.js +9 -0
- package/dist/make-whncTQWE-whncTQWE.js +7 -0
- package/dist/markdown-DYKdIx5--DYKdIx5-.js +135 -0
- package/dist/material-theme-lighter-BRE1Bis3-BRE1Bis3.js +769 -0
- package/dist/material-theme-palenight-Dhz61Tee-Dhz61Tee.js +769 -0
- package/dist/mdc-D0DPLwil-BfE3hy8_.js +88 -0
- package/dist/mdx-CKDMxEaL-CKDMxEaL.js +7 -0
- package/dist/mermaid-BxNM-z-u-BxNM-z-u.js +7 -0
- package/dist/mindmap-definition-377f8f1f-C2vFYDMs-B71SGbvx.js +19078 -0
- package/dist/nginx-C082G13W-vryM9k1W.js +9 -0
- package/dist/objective-c-BVtzkNiv-BVtzkNiv.js +115 -0
- package/dist/onig-BonMD2gC-BonMD2gC.js +4 -0
- package/dist/ordinal-MUacOSdK-B1MUT0BL.js +65 -0
- package/dist/pascal-CrvtytWS-CrvtytWS.js +7 -0
- package/dist/path-Crsf9Nsj-SiSjwXsf.js +91 -0
- package/dist/perl-D29UPKP6-Dez6-HRy.js +17 -0
- package/dist/php-D7Tl-iS7-BtPFrDEt.js +789 -0
- package/dist/pieDiagram-b0208e96-DhA_SoTh-CfDd9YdA.js +501 -0
- package/dist/plsql-8SPzZKaa-8SPzZKaa.js +7 -0
- package/dist/postcss-Cz2vjx_4-Cz2vjx_4.js +7 -0
- package/dist/powershell-B0buHCuS-B0buHCuS.js +7 -0
- package/dist/proto-6YaU_lta-6YaU_lta.js +7 -0
- package/dist/pug-DbFO7359-duYD8LVa.js +21 -0
- package/dist/python-BQXev0_W-BQXev0_W.js +524 -0
- package/dist/quadrantDiagram-0332be45-C8q96Ohm-DMblaqnx.js +903 -0
- package/dist/r-DU7Q70f1-DU7Q70f1.js +7 -0
- package/dist/reg-DoGLEyFr-DoGLEyFr.js +7 -0
- package/dist/requirementDiagram-bf7890df-D30zCZjB-B_JBC9RM.js +767 -0
- package/dist/rst-Bm1i8IkK-C9EaDq6g.js +26 -0
- package/dist/ruby-CZZKXaz8-BxaDEkRP.js +102 -0
- package/dist/rust-CIl6NRUt-CIl6NRUt.js +7 -0
- package/dist/sankeyDiagram-0acdec17-B4vNjMaS-Bauvtonp.js +816 -0
- package/dist/sass-LqXmC1Fh-LqXmC1Fh.js +8 -0
- package/dist/scss-DjxgF7f7-DGTzny6p.js +98 -0
- package/dist/sequenceDiagram-c18d009d-BniqGSPK-DuYYUmiZ.js +2201 -0
- package/dist/shellscript-CUUTQKn5-CUUTQKn5.js +7 -0
- package/dist/shellsession-BIPXtZci-D6avbCwN.js +9 -0
- package/dist/splunk-C0K00wNV-C0K00wNV.js +7 -0
- package/dist/sql-DkzN59UV-DkzN59UV.js +27 -0
- package/dist/ssh-config-BbWAW6SY-BbWAW6SY.js +7 -0
- package/dist/stateDiagram-43596fc0-F0V9suMd-L2Ywe-J_.js +266 -0
- package/dist/stateDiagram-v2-2ead4f9c-DUgJH8tF-BVo1q2i1.js +184 -0
- package/dist/style.css +1 -1
- package/dist/styles-6860f46c-Dflmq0ac-BRNSwis6.js +1089 -0
- package/dist/styles-7383a064-Dg7mXkpq-C4bItohl.js +430 -0
- package/dist/styles-b2c874b6-HpcOhE4Y-Bj0upXzO.js +960 -0
- package/dist/stylus-CAHdVuhm-CAHdVuhm.js +21 -0
- package/dist/svelte-DAxjO8Sh-D0e501jC.js +29 -0
- package/dist/svgDrawCommon-0ee1b4e9-CNkCfzsJ-Bz_doYLk.js +64 -0
- package/dist/swift-x2DVyVjN-Bz5PC9YM.js +550 -0
- package/dist/timeline-definition-d977decf-Cl38e_0g-D_Dlqa-R.js +794 -0
- package/dist/toml-Dbtbfmwk-Dbtbfmwk.js +75 -0
- package/dist/tsx-BmwsDeeh-BmwsDeeh.js +705 -0
- package/dist/twig-B_Gr-ODl-Cl9Q0GWo.js +58 -0
- package/dist/types/components/DocumentationContent.vue.d.ts +8 -1
- package/dist/types/components/DocumentationContent.vue.d.ts.map +1 -1
- package/dist/types/components/DocumentationDisplay.vue.d.ts +5 -1
- package/dist/types/components/DocumentationDisplay.vue.d.ts.map +1 -1
- package/dist/types/components/ProductDocumentModal.vue.d.ts +1 -1
- package/dist/types/components/ProductDocumentModal.vue.d.ts.map +1 -1
- package/dist/types/composables/useI18n.d.ts +4 -0
- package/dist/types/composables/useI18n.d.ts.map +1 -1
- package/dist/typescript-AEg-ehu7-AEg-ehu7.js +672 -0
- package/dist/v-BuvBsUKm-BuvBsUKm.js +7 -0
- package/dist/vb-cqjo5dul-cqjo5dul.js +7 -0
- package/dist/viml-h3ATW6He-h3ATW6He.js +7 -0
- package/dist/vue-Dz-azHaT-B9qBHMZi.js +71 -0
- package/dist/vue-html-DIGKAAs4-BeHSIJcx.js +11 -0
- package/dist/wasm-xOGcJ9Ts-xOGcJ9Ts.js +7 -0
- package/dist/wgsl-hGLOfCya-hGLOfCya.js +7 -0
- package/dist/xml-CfRpfi_B-BH3JRQfc.js +9 -0
- package/dist/xsl-BAqhSCYL-BTKPZRNQ.js +9 -0
- package/dist/xychartDiagram-e50adddc-JdLmRUgg-HmDalTeo.js +1282 -0
- package/dist/yaml-PGla5xPP-HJurM_FJ.js +206 -0
- package/package.json +13 -13
- package/dist/prism-bash.min-DDo5CyRs-DihCfXgx.js +0 -7
- package/dist/prism-css.min-BrrzZC7b-BrrzZC7b.js +0 -7
- package/dist/prism-docker.min-DnIEokC3-D0v8IWN_.js +0 -22
- package/dist/prism-go.min-C7UmK6TW-C7UmK6TW.js +0 -1
- package/dist/prism-http.min-CsU3-jB8-CQ8PCDXl.js +0 -23
- package/dist/prism-javascript.min-CEqHqgbm-CEqHqgbm.js +0 -8
- package/dist/prism-jq.min-Q555vXZm-Q555vXZm.js +0 -8
- package/dist/prism-json.min-B1GJqK1k-B1GJqK1k.js +0 -1
- package/dist/prism-log.min-SDopTpKN-SDopTpKN.js +0 -1
- package/dist/prism-lua.min-DwRnUVfS-DwRnUVfS.js +0 -1
- package/dist/prism-makefile.min-DyutknhE-DyutknhE.js +0 -1
- package/dist/prism-markdown.min-B7US-xc7-DB9aF_ZA.js +0 -63
- package/dist/prism-python.min-BIfpAh5K-BIfpAh5K.js +0 -1
- package/dist/prism-regex.min-f8DNqi8X-f8DNqi8X.js +0 -4
- package/dist/prism-rest.min-B6veHRJF-B6veHRJF.js +0 -1
- package/dist/prism-rust.min-Cb-Mi-h0-Cb-Mi-h0.js +0 -9
- package/dist/prism-scss.min-B0csyGJo-B0csyGJo.js +0 -1
- package/dist/prism-sql.min-BHXzX-c_-BHXzX-c_.js +0 -1
- package/dist/prism-typescript.min-oSVeWCAd-oSVeWCAd.js +0 -5
- package/dist/prism-xml-doc.min-yj0YzRGe-KgTQx-dc.js +0 -7
- package/dist/prism-yaml.min-CTetcdKA-C1YzP_OY.js +0 -28
|
@@ -0,0 +1,803 @@
|
|
|
1
|
+
import { c as P, v as ut, x as yt, s as pt, g as dt, b as ft, a as gt, z as mt, h as Y, i as xt } from "./index-B-5DuDrq.js";
|
|
2
|
+
import { c as kt, d as _t, x as bt, g as nt } from "./svgDrawCommon-0ee1b4e9-CNkCfzsJ-Bz_doYLk.js";
|
|
3
|
+
import { v as J } from "./arc-BSRpyMf3-C5dasNo_.js";
|
|
4
|
+
var W = function() {
|
|
5
|
+
var t = function(f, i, r, l) {
|
|
6
|
+
for (r = r || {}, l = f.length; l--; r[f[l]] = i)
|
|
7
|
+
;
|
|
8
|
+
return r;
|
|
9
|
+
}, e = [6, 8, 10, 11, 12, 14, 16, 17, 18], s = [1, 9], o = [1, 10], n = [1, 11], h = [1, 12], c = [1, 13], p = [1, 14], y = {
|
|
10
|
+
trace: function() {
|
|
11
|
+
},
|
|
12
|
+
yy: {},
|
|
13
|
+
symbols_: { error: 2, start: 3, journey: 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, taskName: 18, taskData: 19, $accept: 0, $end: 1 },
|
|
14
|
+
terminals_: { 2: "error", 4: "journey", 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", 18: "taskName", 19: "taskData" },
|
|
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, 2]],
|
|
16
|
+
performAction: function(f, i, r, l, u, a, g) {
|
|
17
|
+
var x = a.length - 1;
|
|
18
|
+
switch (u) {
|
|
19
|
+
case 1:
|
|
20
|
+
return a[x - 1];
|
|
21
|
+
case 2:
|
|
22
|
+
this.$ = [];
|
|
23
|
+
break;
|
|
24
|
+
case 3:
|
|
25
|
+
a[x - 1].push(a[x]), this.$ = a[x - 1];
|
|
26
|
+
break;
|
|
27
|
+
case 4:
|
|
28
|
+
case 5:
|
|
29
|
+
this.$ = a[x];
|
|
30
|
+
break;
|
|
31
|
+
case 6:
|
|
32
|
+
case 7:
|
|
33
|
+
this.$ = [];
|
|
34
|
+
break;
|
|
35
|
+
case 8:
|
|
36
|
+
l.setDiagramTitle(a[x].substr(6)), this.$ = a[x].substr(6);
|
|
37
|
+
break;
|
|
38
|
+
case 9:
|
|
39
|
+
this.$ = a[x].trim(), l.setAccTitle(this.$);
|
|
40
|
+
break;
|
|
41
|
+
case 10:
|
|
42
|
+
case 11:
|
|
43
|
+
this.$ = a[x].trim(), l.setAccDescription(this.$);
|
|
44
|
+
break;
|
|
45
|
+
case 12:
|
|
46
|
+
l.addSection(a[x].substr(8)), this.$ = a[x].substr(8);
|
|
47
|
+
break;
|
|
48
|
+
case 13:
|
|
49
|
+
l.addTask(a[x - 1], a[x]), this.$ = "task";
|
|
50
|
+
break;
|
|
51
|
+
}
|
|
52
|
+
},
|
|
53
|
+
table: [{ 3: 1, 4: [1, 2] }, { 1: [3] }, t(e, [2, 2], { 5: 3 }), { 6: [1, 4], 7: 5, 8: [1, 6], 9: 7, 10: [1, 8], 11: s, 12: o, 14: n, 16: h, 17: c, 18: p }, t(e, [2, 7], { 1: [2, 1] }), t(e, [2, 3]), { 9: 15, 11: s, 12: o, 14: n, 16: h, 17: c, 18: p }, t(e, [2, 5]), t(e, [2, 6]), t(e, [2, 8]), { 13: [1, 16] }, { 15: [1, 17] }, t(e, [2, 11]), t(e, [2, 12]), { 19: [1, 18] }, t(e, [2, 4]), t(e, [2, 9]), t(e, [2, 10]), t(e, [2, 13])],
|
|
54
|
+
defaultActions: {},
|
|
55
|
+
parseError: function(f, i) {
|
|
56
|
+
if (i.recoverable)
|
|
57
|
+
this.trace(f);
|
|
58
|
+
else {
|
|
59
|
+
var r = new Error(f);
|
|
60
|
+
throw r.hash = i, r;
|
|
61
|
+
}
|
|
62
|
+
},
|
|
63
|
+
parse: function(f) {
|
|
64
|
+
var i = this, r = [0], l = [], u = [null], a = [], g = this.table, x = "", V = 0, H = 0, ot = 2, U = 1, ct = a.slice.call(arguments, 1), k = Object.create(this.lexer), T = { yy: {} };
|
|
65
|
+
for (var N in this.yy)
|
|
66
|
+
Object.prototype.hasOwnProperty.call(this.yy, N) && (T.yy[N] = this.yy[N]);
|
|
67
|
+
k.setInput(f, T.yy), T.yy.lexer = k, T.yy.parser = this, typeof k.yylloc > "u" && (k.yylloc = {});
|
|
68
|
+
var R = k.yylloc;
|
|
69
|
+
a.push(R);
|
|
70
|
+
var lt = k.options && k.options.ranges;
|
|
71
|
+
typeof T.yy.parseError == "function" ? this.parseError = T.yy.parseError : this.parseError = Object.getPrototypeOf(this).parseError;
|
|
72
|
+
function ht() {
|
|
73
|
+
var $;
|
|
74
|
+
return $ = l.pop() || k.lex() || U, typeof $ != "number" && ($ instanceof Array && (l = $, $ = l.pop()), $ = i.symbols_[$] || $), $;
|
|
75
|
+
}
|
|
76
|
+
for (var _, S, b, z, C = {}, L, w, Z, F; ; ) {
|
|
77
|
+
if (S = r[r.length - 1], this.defaultActions[S] ? b = this.defaultActions[S] : ((_ === null || typeof _ > "u") && (_ = ht()), b = g[S] && g[S][_]), typeof b > "u" || !b.length || !b[0]) {
|
|
78
|
+
var B = "";
|
|
79
|
+
F = [];
|
|
80
|
+
for (L in g[S])
|
|
81
|
+
this.terminals_[L] && L > ot && F.push("'" + this.terminals_[L] + "'");
|
|
82
|
+
k.showPosition ? B = "Parse error on line " + (V + 1) + `:
|
|
83
|
+
` + k.showPosition() + `
|
|
84
|
+
Expecting ` + F.join(", ") + ", got '" + (this.terminals_[_] || _) + "'" : B = "Parse error on line " + (V + 1) + ": Unexpected " + (_ == U ? "end of input" : "'" + (this.terminals_[_] || _) + "'"), this.parseError(B, {
|
|
85
|
+
text: k.match,
|
|
86
|
+
token: this.terminals_[_] || _,
|
|
87
|
+
line: k.yylineno,
|
|
88
|
+
loc: R,
|
|
89
|
+
expected: F
|
|
90
|
+
});
|
|
91
|
+
}
|
|
92
|
+
if (b[0] instanceof Array && b.length > 1)
|
|
93
|
+
throw new Error("Parse Error: multiple actions possible at state: " + S + ", token: " + _);
|
|
94
|
+
switch (b[0]) {
|
|
95
|
+
case 1:
|
|
96
|
+
r.push(_), u.push(k.yytext), a.push(k.yylloc), r.push(b[1]), _ = null, H = k.yyleng, x = k.yytext, V = k.yylineno, R = k.yylloc;
|
|
97
|
+
break;
|
|
98
|
+
case 2:
|
|
99
|
+
if (w = this.productions_[b[1]][1], C.$ = u[u.length - w], C._$ = {
|
|
100
|
+
first_line: a[a.length - (w || 1)].first_line,
|
|
101
|
+
last_line: a[a.length - 1].last_line,
|
|
102
|
+
first_column: a[a.length - (w || 1)].first_column,
|
|
103
|
+
last_column: a[a.length - 1].last_column
|
|
104
|
+
}, lt && (C._$.range = [
|
|
105
|
+
a[a.length - (w || 1)].range[0],
|
|
106
|
+
a[a.length - 1].range[1]
|
|
107
|
+
]), z = this.performAction.apply(C, [
|
|
108
|
+
x,
|
|
109
|
+
H,
|
|
110
|
+
V,
|
|
111
|
+
T.yy,
|
|
112
|
+
b[1],
|
|
113
|
+
u,
|
|
114
|
+
a
|
|
115
|
+
].concat(ct)), typeof z < "u")
|
|
116
|
+
return z;
|
|
117
|
+
w && (r = r.slice(0, -1 * w * 2), u = u.slice(0, -1 * w), a = a.slice(0, -1 * w)), r.push(this.productions_[b[1]][0]), u.push(C.$), a.push(C._$), Z = g[r[r.length - 2]][r[r.length - 1]], r.push(Z);
|
|
118
|
+
break;
|
|
119
|
+
case 3:
|
|
120
|
+
return !0;
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
return !0;
|
|
124
|
+
}
|
|
125
|
+
}, m = /* @__PURE__ */ function() {
|
|
126
|
+
var f = {
|
|
127
|
+
EOF: 1,
|
|
128
|
+
parseError: function(i, r) {
|
|
129
|
+
if (this.yy.parser)
|
|
130
|
+
this.yy.parser.parseError(i, r);
|
|
131
|
+
else
|
|
132
|
+
throw new Error(i);
|
|
133
|
+
},
|
|
134
|
+
// resets the lexer, sets new input
|
|
135
|
+
setInput: function(i, r) {
|
|
136
|
+
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 = {
|
|
137
|
+
first_line: 1,
|
|
138
|
+
first_column: 0,
|
|
139
|
+
last_line: 1,
|
|
140
|
+
last_column: 0
|
|
141
|
+
}, this.options.ranges && (this.yylloc.range = [0, 0]), this.offset = 0, this;
|
|
142
|
+
},
|
|
143
|
+
// consumes and returns one char from the input
|
|
144
|
+
input: function() {
|
|
145
|
+
var i = this._input[0];
|
|
146
|
+
this.yytext += i, this.yyleng++, this.offset++, this.match += i, this.matched += i;
|
|
147
|
+
var r = i.match(/(?:\r\n?|\n).*/g);
|
|
148
|
+
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;
|
|
149
|
+
},
|
|
150
|
+
// unshifts one char (or a string) into the input
|
|
151
|
+
unput: function(i) {
|
|
152
|
+
var r = i.length, l = i.split(/(?:\r\n?|\n)/g);
|
|
153
|
+
this._input = i + this._input, this.yytext = this.yytext.substr(0, this.yytext.length - r), this.offset -= r;
|
|
154
|
+
var u = this.match.split(/(?:\r\n?|\n)/g);
|
|
155
|
+
this.match = this.match.substr(0, this.match.length - 1), this.matched = this.matched.substr(0, this.matched.length - 1), l.length - 1 && (this.yylineno -= l.length - 1);
|
|
156
|
+
var a = this.yylloc.range;
|
|
157
|
+
return this.yylloc = {
|
|
158
|
+
first_line: this.yylloc.first_line,
|
|
159
|
+
last_line: this.yylineno + 1,
|
|
160
|
+
first_column: this.yylloc.first_column,
|
|
161
|
+
last_column: l ? (l.length === u.length ? this.yylloc.first_column : 0) + u[u.length - l.length].length - l[0].length : this.yylloc.first_column - r
|
|
162
|
+
}, this.options.ranges && (this.yylloc.range = [a[0], a[0] + this.yyleng - r]), this.yyleng = this.yytext.length, this;
|
|
163
|
+
},
|
|
164
|
+
// When called from action, caches matched text and appends it on next action
|
|
165
|
+
more: function() {
|
|
166
|
+
return this._more = !0, this;
|
|
167
|
+
},
|
|
168
|
+
// 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.
|
|
169
|
+
reject: function() {
|
|
170
|
+
if (this.options.backtrack_lexer)
|
|
171
|
+
this._backtrack = !0;
|
|
172
|
+
else
|
|
173
|
+
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).
|
|
174
|
+
` + this.showPosition(), {
|
|
175
|
+
text: "",
|
|
176
|
+
token: null,
|
|
177
|
+
line: this.yylineno
|
|
178
|
+
});
|
|
179
|
+
return this;
|
|
180
|
+
},
|
|
181
|
+
// retain first n characters of the match
|
|
182
|
+
less: function(i) {
|
|
183
|
+
this.unput(this.match.slice(i));
|
|
184
|
+
},
|
|
185
|
+
// displays already matched input, i.e. for error messages
|
|
186
|
+
pastInput: function() {
|
|
187
|
+
var i = this.matched.substr(0, this.matched.length - this.match.length);
|
|
188
|
+
return (i.length > 20 ? "..." : "") + i.substr(-20).replace(/\n/g, "");
|
|
189
|
+
},
|
|
190
|
+
// displays upcoming input, i.e. for error messages
|
|
191
|
+
upcomingInput: function() {
|
|
192
|
+
var i = this.match;
|
|
193
|
+
return i.length < 20 && (i += this._input.substr(0, 20 - i.length)), (i.substr(0, 20) + (i.length > 20 ? "..." : "")).replace(/\n/g, "");
|
|
194
|
+
},
|
|
195
|
+
// displays the character position where the lexing error occurred, i.e. for error messages
|
|
196
|
+
showPosition: function() {
|
|
197
|
+
var i = this.pastInput(), r = new Array(i.length + 1).join("-");
|
|
198
|
+
return i + this.upcomingInput() + `
|
|
199
|
+
` + r + "^";
|
|
200
|
+
},
|
|
201
|
+
// test the lexed token: return FALSE when not a match, otherwise return token
|
|
202
|
+
test_match: function(i, r) {
|
|
203
|
+
var l, u, a;
|
|
204
|
+
if (this.options.backtrack_lexer && (a = {
|
|
205
|
+
yylineno: this.yylineno,
|
|
206
|
+
yylloc: {
|
|
207
|
+
first_line: this.yylloc.first_line,
|
|
208
|
+
last_line: this.last_line,
|
|
209
|
+
first_column: this.yylloc.first_column,
|
|
210
|
+
last_column: this.yylloc.last_column
|
|
211
|
+
},
|
|
212
|
+
yytext: this.yytext,
|
|
213
|
+
match: this.match,
|
|
214
|
+
matches: this.matches,
|
|
215
|
+
matched: this.matched,
|
|
216
|
+
yyleng: this.yyleng,
|
|
217
|
+
offset: this.offset,
|
|
218
|
+
_more: this._more,
|
|
219
|
+
_input: this._input,
|
|
220
|
+
yy: this.yy,
|
|
221
|
+
conditionStack: this.conditionStack.slice(0),
|
|
222
|
+
done: this.done
|
|
223
|
+
}, this.options.ranges && (a.yylloc.range = this.yylloc.range.slice(0))), u = i[0].match(/(?:\r\n?|\n).*/g), u && (this.yylineno += u.length), this.yylloc = {
|
|
224
|
+
first_line: this.yylloc.last_line,
|
|
225
|
+
last_line: this.yylineno + 1,
|
|
226
|
+
first_column: this.yylloc.last_column,
|
|
227
|
+
last_column: u ? u[u.length - 1].length - u[u.length - 1].match(/\r?\n?/)[0].length : this.yylloc.last_column + i[0].length
|
|
228
|
+
}, 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], l = this.performAction.call(this, this.yy, this, r, this.conditionStack[this.conditionStack.length - 1]), this.done && this._input && (this.done = !1), l)
|
|
229
|
+
return l;
|
|
230
|
+
if (this._backtrack) {
|
|
231
|
+
for (var g in a)
|
|
232
|
+
this[g] = a[g];
|
|
233
|
+
return !1;
|
|
234
|
+
}
|
|
235
|
+
return !1;
|
|
236
|
+
},
|
|
237
|
+
// return next match in input
|
|
238
|
+
next: function() {
|
|
239
|
+
if (this.done)
|
|
240
|
+
return this.EOF;
|
|
241
|
+
this._input || (this.done = !0);
|
|
242
|
+
var i, r, l, u;
|
|
243
|
+
this._more || (this.yytext = "", this.match = "");
|
|
244
|
+
for (var a = this._currentRules(), g = 0; g < a.length; g++)
|
|
245
|
+
if (l = this._input.match(this.rules[a[g]]), l && (!r || l[0].length > r[0].length)) {
|
|
246
|
+
if (r = l, u = g, this.options.backtrack_lexer) {
|
|
247
|
+
if (i = this.test_match(l, a[g]), i !== !1)
|
|
248
|
+
return i;
|
|
249
|
+
if (this._backtrack) {
|
|
250
|
+
r = !1;
|
|
251
|
+
continue;
|
|
252
|
+
} else
|
|
253
|
+
return !1;
|
|
254
|
+
} else if (!this.options.flex)
|
|
255
|
+
break;
|
|
256
|
+
}
|
|
257
|
+
return r ? (i = this.test_match(r, a[u]), i !== !1 ? i : !1) : this._input === "" ? this.EOF : this.parseError("Lexical error on line " + (this.yylineno + 1) + `. Unrecognized text.
|
|
258
|
+
` + this.showPosition(), {
|
|
259
|
+
text: "",
|
|
260
|
+
token: null,
|
|
261
|
+
line: this.yylineno
|
|
262
|
+
});
|
|
263
|
+
},
|
|
264
|
+
// return next match that has a token
|
|
265
|
+
lex: function() {
|
|
266
|
+
var i = this.next();
|
|
267
|
+
return i || this.lex();
|
|
268
|
+
},
|
|
269
|
+
// activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)
|
|
270
|
+
begin: function(i) {
|
|
271
|
+
this.conditionStack.push(i);
|
|
272
|
+
},
|
|
273
|
+
// pop the previously active lexer condition state off the condition stack
|
|
274
|
+
popState: function() {
|
|
275
|
+
var i = this.conditionStack.length - 1;
|
|
276
|
+
return i > 0 ? this.conditionStack.pop() : this.conditionStack[0];
|
|
277
|
+
},
|
|
278
|
+
// produce the lexer rule set which is active for the currently active lexer condition state
|
|
279
|
+
_currentRules: function() {
|
|
280
|
+
return this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1] ? this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules : this.conditions.INITIAL.rules;
|
|
281
|
+
},
|
|
282
|
+
// return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available
|
|
283
|
+
topState: function(i) {
|
|
284
|
+
return i = this.conditionStack.length - 1 - Math.abs(i || 0), i >= 0 ? this.conditionStack[i] : "INITIAL";
|
|
285
|
+
},
|
|
286
|
+
// alias for begin(condition)
|
|
287
|
+
pushState: function(i) {
|
|
288
|
+
this.begin(i);
|
|
289
|
+
},
|
|
290
|
+
// return the number of states currently on the stack
|
|
291
|
+
stateStackSize: function() {
|
|
292
|
+
return this.conditionStack.length;
|
|
293
|
+
},
|
|
294
|
+
options: { "case-insensitive": !0 },
|
|
295
|
+
performAction: function(i, r, l, u) {
|
|
296
|
+
switch (l) {
|
|
297
|
+
case 0:
|
|
298
|
+
break;
|
|
299
|
+
case 1:
|
|
300
|
+
break;
|
|
301
|
+
case 2:
|
|
302
|
+
return 10;
|
|
303
|
+
case 3:
|
|
304
|
+
break;
|
|
305
|
+
case 4:
|
|
306
|
+
break;
|
|
307
|
+
case 5:
|
|
308
|
+
return 4;
|
|
309
|
+
case 6:
|
|
310
|
+
return 11;
|
|
311
|
+
case 7:
|
|
312
|
+
return this.begin("acc_title"), 12;
|
|
313
|
+
case 8:
|
|
314
|
+
return this.popState(), "acc_title_value";
|
|
315
|
+
case 9:
|
|
316
|
+
return this.begin("acc_descr"), 14;
|
|
317
|
+
case 10:
|
|
318
|
+
return this.popState(), "acc_descr_value";
|
|
319
|
+
case 11:
|
|
320
|
+
this.begin("acc_descr_multiline");
|
|
321
|
+
break;
|
|
322
|
+
case 12:
|
|
323
|
+
this.popState();
|
|
324
|
+
break;
|
|
325
|
+
case 13:
|
|
326
|
+
return "acc_descr_multiline_value";
|
|
327
|
+
case 14:
|
|
328
|
+
return 17;
|
|
329
|
+
case 15:
|
|
330
|
+
return 18;
|
|
331
|
+
case 16:
|
|
332
|
+
return 19;
|
|
333
|
+
case 17:
|
|
334
|
+
return ":";
|
|
335
|
+
case 18:
|
|
336
|
+
return 6;
|
|
337
|
+
case 19:
|
|
338
|
+
return "INVALID";
|
|
339
|
+
}
|
|
340
|
+
},
|
|
341
|
+
rules: [/^(?:%(?!\{)[^\n]*)/i, /^(?:[^\}]%%[^\n]*)/i, /^(?:[\n]+)/i, /^(?:\s+)/i, /^(?:#[^\n]*)/i, /^(?:journey\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, /^(?:[^#:\n;]+)/i, /^(?::[^#\n;]+)/i, /^(?::)/i, /^(?:$)/i, /^(?:.)/i],
|
|
342
|
+
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, 19], inclusive: !0 } }
|
|
343
|
+
};
|
|
344
|
+
return f;
|
|
345
|
+
}();
|
|
346
|
+
y.lexer = m;
|
|
347
|
+
function d() {
|
|
348
|
+
this.yy = {};
|
|
349
|
+
}
|
|
350
|
+
return d.prototype = y, y.Parser = d, new d();
|
|
351
|
+
}();
|
|
352
|
+
W.parser = W;
|
|
353
|
+
const vt = W;
|
|
354
|
+
let E = "";
|
|
355
|
+
const q = [], I = [], j = [], wt = function() {
|
|
356
|
+
q.length = 0, I.length = 0, E = "", j.length = 0, mt();
|
|
357
|
+
}, $t = function(t) {
|
|
358
|
+
E = t, q.push(t);
|
|
359
|
+
}, Mt = function() {
|
|
360
|
+
return q;
|
|
361
|
+
}, Tt = function() {
|
|
362
|
+
let t = Q();
|
|
363
|
+
const e = 100;
|
|
364
|
+
let s = 0;
|
|
365
|
+
for (; !t && s < e; )
|
|
366
|
+
t = Q(), s++;
|
|
367
|
+
return I.push(...j), I;
|
|
368
|
+
}, St = function() {
|
|
369
|
+
const t = [];
|
|
370
|
+
return I.forEach((e) => {
|
|
371
|
+
e.people && t.push(...e.people);
|
|
372
|
+
}), [...new Set(t)].sort();
|
|
373
|
+
}, At = function(t, e) {
|
|
374
|
+
const s = e.substr(1).split(":");
|
|
375
|
+
let o = 0, n = [];
|
|
376
|
+
s.length === 1 ? (o = Number(s[0]), n = []) : (o = Number(s[0]), n = s[1].split(","));
|
|
377
|
+
const h = n.map((p) => p.trim()), c = {
|
|
378
|
+
section: E,
|
|
379
|
+
type: E,
|
|
380
|
+
people: h,
|
|
381
|
+
task: t,
|
|
382
|
+
score: o
|
|
383
|
+
};
|
|
384
|
+
j.push(c);
|
|
385
|
+
}, Pt = function(t) {
|
|
386
|
+
const e = {
|
|
387
|
+
section: E,
|
|
388
|
+
type: E,
|
|
389
|
+
description: t,
|
|
390
|
+
task: t,
|
|
391
|
+
classes: []
|
|
392
|
+
};
|
|
393
|
+
I.push(e);
|
|
394
|
+
}, Q = function() {
|
|
395
|
+
const t = function(s) {
|
|
396
|
+
return j[s].processed;
|
|
397
|
+
};
|
|
398
|
+
let e = !0;
|
|
399
|
+
for (const [s, o] of j.entries())
|
|
400
|
+
t(s), e = e && o.processed;
|
|
401
|
+
return e;
|
|
402
|
+
}, Ct = function() {
|
|
403
|
+
return St();
|
|
404
|
+
}, K = {
|
|
405
|
+
getConfig: () => P().journey,
|
|
406
|
+
clear: wt,
|
|
407
|
+
setDiagramTitle: ut,
|
|
408
|
+
getDiagramTitle: yt,
|
|
409
|
+
setAccTitle: pt,
|
|
410
|
+
getAccTitle: dt,
|
|
411
|
+
setAccDescription: ft,
|
|
412
|
+
getAccDescription: gt,
|
|
413
|
+
addSection: $t,
|
|
414
|
+
getSections: Mt,
|
|
415
|
+
getTasks: Tt,
|
|
416
|
+
addTask: At,
|
|
417
|
+
addTaskOrg: Pt,
|
|
418
|
+
getActors: Ct
|
|
419
|
+
}, Et = (t) => `.label {
|
|
420
|
+
font-family: 'trebuchet ms', verdana, arial, sans-serif;
|
|
421
|
+
font-family: var(--mermaid-font-family);
|
|
422
|
+
color: ${t.textColor};
|
|
423
|
+
}
|
|
424
|
+
.mouth {
|
|
425
|
+
stroke: #666;
|
|
426
|
+
}
|
|
427
|
+
|
|
428
|
+
line {
|
|
429
|
+
stroke: ${t.textColor}
|
|
430
|
+
}
|
|
431
|
+
|
|
432
|
+
.legend {
|
|
433
|
+
fill: ${t.textColor};
|
|
434
|
+
}
|
|
435
|
+
|
|
436
|
+
.label text {
|
|
437
|
+
fill: #333;
|
|
438
|
+
}
|
|
439
|
+
.label {
|
|
440
|
+
color: ${t.textColor}
|
|
441
|
+
}
|
|
442
|
+
|
|
443
|
+
.face {
|
|
444
|
+
${t.faceColor ? `fill: ${t.faceColor}` : "fill: #FFF8DC"};
|
|
445
|
+
stroke: #999;
|
|
446
|
+
}
|
|
447
|
+
|
|
448
|
+
.node rect,
|
|
449
|
+
.node circle,
|
|
450
|
+
.node ellipse,
|
|
451
|
+
.node polygon,
|
|
452
|
+
.node path {
|
|
453
|
+
fill: ${t.mainBkg};
|
|
454
|
+
stroke: ${t.nodeBorder};
|
|
455
|
+
stroke-width: 1px;
|
|
456
|
+
}
|
|
457
|
+
|
|
458
|
+
.node .label {
|
|
459
|
+
text-align: center;
|
|
460
|
+
}
|
|
461
|
+
.node.clickable {
|
|
462
|
+
cursor: pointer;
|
|
463
|
+
}
|
|
464
|
+
|
|
465
|
+
.arrowheadPath {
|
|
466
|
+
fill: ${t.arrowheadColor};
|
|
467
|
+
}
|
|
468
|
+
|
|
469
|
+
.edgePath .path {
|
|
470
|
+
stroke: ${t.lineColor};
|
|
471
|
+
stroke-width: 1.5px;
|
|
472
|
+
}
|
|
473
|
+
|
|
474
|
+
.flowchart-link {
|
|
475
|
+
stroke: ${t.lineColor};
|
|
476
|
+
fill: none;
|
|
477
|
+
}
|
|
478
|
+
|
|
479
|
+
.edgeLabel {
|
|
480
|
+
background-color: ${t.edgeLabelBackground};
|
|
481
|
+
rect {
|
|
482
|
+
opacity: 0.5;
|
|
483
|
+
}
|
|
484
|
+
text-align: center;
|
|
485
|
+
}
|
|
486
|
+
|
|
487
|
+
.cluster rect {
|
|
488
|
+
}
|
|
489
|
+
|
|
490
|
+
.cluster text {
|
|
491
|
+
fill: ${t.titleColor};
|
|
492
|
+
}
|
|
493
|
+
|
|
494
|
+
div.mermaidTooltip {
|
|
495
|
+
position: absolute;
|
|
496
|
+
text-align: center;
|
|
497
|
+
max-width: 200px;
|
|
498
|
+
padding: 2px;
|
|
499
|
+
font-family: 'trebuchet ms', verdana, arial, sans-serif;
|
|
500
|
+
font-family: var(--mermaid-font-family);
|
|
501
|
+
font-size: 12px;
|
|
502
|
+
background: ${t.tertiaryColor};
|
|
503
|
+
border: 1px solid ${t.border2};
|
|
504
|
+
border-radius: 2px;
|
|
505
|
+
pointer-events: none;
|
|
506
|
+
z-index: 100;
|
|
507
|
+
}
|
|
508
|
+
|
|
509
|
+
.task-type-0, .section-type-0 {
|
|
510
|
+
${t.fillType0 ? `fill: ${t.fillType0}` : ""};
|
|
511
|
+
}
|
|
512
|
+
.task-type-1, .section-type-1 {
|
|
513
|
+
${t.fillType0 ? `fill: ${t.fillType1}` : ""};
|
|
514
|
+
}
|
|
515
|
+
.task-type-2, .section-type-2 {
|
|
516
|
+
${t.fillType0 ? `fill: ${t.fillType2}` : ""};
|
|
517
|
+
}
|
|
518
|
+
.task-type-3, .section-type-3 {
|
|
519
|
+
${t.fillType0 ? `fill: ${t.fillType3}` : ""};
|
|
520
|
+
}
|
|
521
|
+
.task-type-4, .section-type-4 {
|
|
522
|
+
${t.fillType0 ? `fill: ${t.fillType4}` : ""};
|
|
523
|
+
}
|
|
524
|
+
.task-type-5, .section-type-5 {
|
|
525
|
+
${t.fillType0 ? `fill: ${t.fillType5}` : ""};
|
|
526
|
+
}
|
|
527
|
+
.task-type-6, .section-type-6 {
|
|
528
|
+
${t.fillType0 ? `fill: ${t.fillType6}` : ""};
|
|
529
|
+
}
|
|
530
|
+
.task-type-7, .section-type-7 {
|
|
531
|
+
${t.fillType0 ? `fill: ${t.fillType7}` : ""};
|
|
532
|
+
}
|
|
533
|
+
|
|
534
|
+
.actor-0 {
|
|
535
|
+
${t.actor0 ? `fill: ${t.actor0}` : ""};
|
|
536
|
+
}
|
|
537
|
+
.actor-1 {
|
|
538
|
+
${t.actor1 ? `fill: ${t.actor1}` : ""};
|
|
539
|
+
}
|
|
540
|
+
.actor-2 {
|
|
541
|
+
${t.actor2 ? `fill: ${t.actor2}` : ""};
|
|
542
|
+
}
|
|
543
|
+
.actor-3 {
|
|
544
|
+
${t.actor3 ? `fill: ${t.actor3}` : ""};
|
|
545
|
+
}
|
|
546
|
+
.actor-4 {
|
|
547
|
+
${t.actor4 ? `fill: ${t.actor4}` : ""};
|
|
548
|
+
}
|
|
549
|
+
.actor-5 {
|
|
550
|
+
${t.actor5 ? `fill: ${t.actor5}` : ""};
|
|
551
|
+
}
|
|
552
|
+
`, It = Et, G = function(t, e) {
|
|
553
|
+
return kt(t, e);
|
|
554
|
+
}, jt = function(t, e) {
|
|
555
|
+
const s = t.append("circle").attr("cx", e.cx).attr("cy", e.cy).attr("class", "face").attr("r", 15).attr("stroke-width", 2).attr("overflow", "visible"), o = t.append("g");
|
|
556
|
+
o.append("circle").attr("cx", e.cx - 15 / 3).attr("cy", e.cy - 15 / 3).attr("r", 1.5).attr("stroke-width", 2).attr("fill", "#666").attr("stroke", "#666"), o.append("circle").attr("cx", e.cx + 15 / 3).attr("cy", e.cy - 15 / 3).attr("r", 1.5).attr("stroke-width", 2).attr("fill", "#666").attr("stroke", "#666");
|
|
557
|
+
function n(p) {
|
|
558
|
+
const y = J().startAngle(Math.PI / 2).endAngle(3 * (Math.PI / 2)).innerRadius(7.5).outerRadius(6.8181818181818175);
|
|
559
|
+
p.append("path").attr("class", "mouth").attr("d", y).attr("transform", "translate(" + e.cx + "," + (e.cy + 2) + ")");
|
|
560
|
+
}
|
|
561
|
+
function h(p) {
|
|
562
|
+
const y = J().startAngle(3 * Math.PI / 2).endAngle(5 * (Math.PI / 2)).innerRadius(7.5).outerRadius(6.8181818181818175);
|
|
563
|
+
p.append("path").attr("class", "mouth").attr("d", y).attr("transform", "translate(" + e.cx + "," + (e.cy + 7) + ")");
|
|
564
|
+
}
|
|
565
|
+
function c(p) {
|
|
566
|
+
p.append("line").attr("class", "mouth").attr("stroke", 2).attr("x1", e.cx - 5).attr("y1", e.cy + 7).attr("x2", e.cx + 5).attr("y2", e.cy + 7).attr("class", "mouth").attr("stroke-width", "1px").attr("stroke", "#666");
|
|
567
|
+
}
|
|
568
|
+
return e.score > 3 ? n(o) : e.score < 3 ? h(o) : c(o), s;
|
|
569
|
+
}, st = function(t, e) {
|
|
570
|
+
const s = t.append("circle");
|
|
571
|
+
return s.attr("cx", e.cx), s.attr("cy", e.cy), s.attr("class", "actor-" + e.pos), s.attr("fill", e.fill), s.attr("stroke", e.stroke), s.attr("r", e.r), s.class !== void 0 && s.attr("class", s.class), e.title !== void 0 && s.append("title").text(e.title), s;
|
|
572
|
+
}, rt = function(t, e) {
|
|
573
|
+
return _t(t, e);
|
|
574
|
+
}, Dt = function(t, e) {
|
|
575
|
+
function s(n, h, c, p, y) {
|
|
576
|
+
return n + "," + h + " " + (n + c) + "," + h + " " + (n + c) + "," + (h + p - y) + " " + (n + c - y * 1.2) + "," + (h + p) + " " + n + "," + (h + p);
|
|
577
|
+
}
|
|
578
|
+
const o = t.append("polygon");
|
|
579
|
+
o.attr("points", s(e.x, e.y, 50, 20, 7)), o.attr("class", "labelBox"), e.y = e.y + e.labelMargin, e.x = e.x + 0.5 * e.labelMargin, rt(t, e);
|
|
580
|
+
}, Vt = function(t, e, s) {
|
|
581
|
+
const o = t.append("g"), n = nt();
|
|
582
|
+
n.x = e.x, n.y = e.y, n.fill = e.fill, n.width = s.width * e.taskCount + // width of the tasks
|
|
583
|
+
s.diagramMarginX * (e.taskCount - 1), n.height = s.height, n.class = "journey-section section-type-" + e.num, n.rx = 3, n.ry = 3, G(o, n), at(s)(
|
|
584
|
+
e.text,
|
|
585
|
+
o,
|
|
586
|
+
n.x,
|
|
587
|
+
n.y,
|
|
588
|
+
n.width,
|
|
589
|
+
n.height,
|
|
590
|
+
{ class: "journey-section section-type-" + e.num },
|
|
591
|
+
s,
|
|
592
|
+
e.colour
|
|
593
|
+
);
|
|
594
|
+
};
|
|
595
|
+
let tt = -1;
|
|
596
|
+
const Lt = function(t, e, s) {
|
|
597
|
+
const o = e.x + s.width / 2, n = t.append("g");
|
|
598
|
+
tt++;
|
|
599
|
+
const h = 300 + 5 * 30;
|
|
600
|
+
n.append("line").attr("id", "task" + tt).attr("x1", o).attr("y1", e.y).attr("x2", o).attr("y2", h).attr("class", "task-line").attr("stroke-width", "1px").attr("stroke-dasharray", "4 2").attr("stroke", "#666"), jt(n, {
|
|
601
|
+
cx: o,
|
|
602
|
+
cy: 300 + (5 - e.score) * 30,
|
|
603
|
+
score: e.score
|
|
604
|
+
});
|
|
605
|
+
const c = nt();
|
|
606
|
+
c.x = e.x, c.y = e.y, c.fill = e.fill, c.width = s.width, c.height = s.height, c.class = "task task-type-" + e.num, c.rx = 3, c.ry = 3, G(n, c);
|
|
607
|
+
let p = e.x + 14;
|
|
608
|
+
e.people.forEach((y) => {
|
|
609
|
+
const m = e.actors[y].color, d = {
|
|
610
|
+
cx: p,
|
|
611
|
+
cy: e.y,
|
|
612
|
+
r: 7,
|
|
613
|
+
fill: m,
|
|
614
|
+
stroke: "#000",
|
|
615
|
+
title: y,
|
|
616
|
+
pos: e.actors[y].position
|
|
617
|
+
};
|
|
618
|
+
st(n, d), p += 10;
|
|
619
|
+
}), at(s)(
|
|
620
|
+
e.task,
|
|
621
|
+
n,
|
|
622
|
+
c.x,
|
|
623
|
+
c.y,
|
|
624
|
+
c.width,
|
|
625
|
+
c.height,
|
|
626
|
+
{ class: "task" },
|
|
627
|
+
s,
|
|
628
|
+
e.colour
|
|
629
|
+
);
|
|
630
|
+
}, Ft = function(t, e) {
|
|
631
|
+
bt(t, e);
|
|
632
|
+
}, at = /* @__PURE__ */ function() {
|
|
633
|
+
function t(n, h, c, p, y, m, d, f) {
|
|
634
|
+
const i = h.append("text").attr("x", c + y / 2).attr("y", p + m / 2 + 5).style("font-color", f).style("text-anchor", "middle").text(n);
|
|
635
|
+
o(i, d);
|
|
636
|
+
}
|
|
637
|
+
function e(n, h, c, p, y, m, d, f, i) {
|
|
638
|
+
const { taskFontSize: r, taskFontFamily: l } = f, u = n.split(/<br\s*\/?>/gi);
|
|
639
|
+
for (let a = 0; a < u.length; a++) {
|
|
640
|
+
const g = a * r - r * (u.length - 1) / 2, x = h.append("text").attr("x", c + y / 2).attr("y", p).attr("fill", i).style("text-anchor", "middle").style("font-size", r).style("font-family", l);
|
|
641
|
+
x.append("tspan").attr("x", c + y / 2).attr("dy", g).text(u[a]), x.attr("y", p + m / 2).attr("dominant-baseline", "central").attr("alignment-baseline", "central"), o(x, d);
|
|
642
|
+
}
|
|
643
|
+
}
|
|
644
|
+
function s(n, h, c, p, y, m, d, f) {
|
|
645
|
+
const i = h.append("switch"), r = i.append("foreignObject").attr("x", c).attr("y", p).attr("width", y).attr("height", m).attr("position", "fixed").append("xhtml:div").style("display", "table").style("height", "100%").style("width", "100%");
|
|
646
|
+
r.append("div").attr("class", "label").style("display", "table-cell").style("text-align", "center").style("vertical-align", "middle").text(n), e(n, i, c, p, y, m, d, f), o(r, d);
|
|
647
|
+
}
|
|
648
|
+
function o(n, h) {
|
|
649
|
+
for (const c in h)
|
|
650
|
+
c in h && n.attr(c, h[c]);
|
|
651
|
+
}
|
|
652
|
+
return function(n) {
|
|
653
|
+
return n.textPlacement === "fo" ? s : n.textPlacement === "old" ? t : e;
|
|
654
|
+
};
|
|
655
|
+
}(), Ot = function(t) {
|
|
656
|
+
t.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");
|
|
657
|
+
}, D = {
|
|
658
|
+
drawRect: G,
|
|
659
|
+
drawCircle: st,
|
|
660
|
+
drawSection: Vt,
|
|
661
|
+
drawText: rt,
|
|
662
|
+
drawLabel: Dt,
|
|
663
|
+
drawTask: Lt,
|
|
664
|
+
drawBackgroundRect: Ft,
|
|
665
|
+
initGraphics: Ot
|
|
666
|
+
}, Nt = function(t) {
|
|
667
|
+
Object.keys(t).forEach(function(e) {
|
|
668
|
+
O[e] = t[e];
|
|
669
|
+
});
|
|
670
|
+
}, M = {};
|
|
671
|
+
function Rt(t) {
|
|
672
|
+
const e = P().journey;
|
|
673
|
+
let s = 60;
|
|
674
|
+
Object.keys(M).forEach((o) => {
|
|
675
|
+
const n = M[o].color, h = {
|
|
676
|
+
cx: 20,
|
|
677
|
+
cy: s,
|
|
678
|
+
r: 7,
|
|
679
|
+
fill: n,
|
|
680
|
+
stroke: "#000",
|
|
681
|
+
pos: M[o].position
|
|
682
|
+
};
|
|
683
|
+
D.drawCircle(t, h);
|
|
684
|
+
const c = {
|
|
685
|
+
x: 40,
|
|
686
|
+
y: s + 7,
|
|
687
|
+
fill: "#666",
|
|
688
|
+
text: o,
|
|
689
|
+
textMargin: e.boxTextMargin | 5
|
|
690
|
+
};
|
|
691
|
+
D.drawText(t, c), s += 20;
|
|
692
|
+
});
|
|
693
|
+
}
|
|
694
|
+
const O = P().journey, A = O.leftMargin, zt = function(t, e, s, o) {
|
|
695
|
+
const n = P().journey, h = P().securityLevel;
|
|
696
|
+
let c;
|
|
697
|
+
h === "sandbox" && (c = Y("#i" + e));
|
|
698
|
+
const p = h === "sandbox" ? Y(c.nodes()[0].contentDocument.body) : Y("body");
|
|
699
|
+
v.init();
|
|
700
|
+
const y = p.select("#" + e);
|
|
701
|
+
D.initGraphics(y);
|
|
702
|
+
const m = o.db.getTasks(), d = o.db.getDiagramTitle(), f = o.db.getActors();
|
|
703
|
+
for (const g in M)
|
|
704
|
+
delete M[g];
|
|
705
|
+
let i = 0;
|
|
706
|
+
f.forEach((g) => {
|
|
707
|
+
M[g] = {
|
|
708
|
+
color: n.actorColours[i % n.actorColours.length],
|
|
709
|
+
position: i
|
|
710
|
+
}, i++;
|
|
711
|
+
}), Rt(y), v.insert(0, 0, A, Object.keys(M).length * 50), Bt(y, m, 0);
|
|
712
|
+
const r = v.getBounds();
|
|
713
|
+
d && y.append("text").text(d).attr("x", A).attr("font-size", "4ex").attr("font-weight", "bold").attr("y", 25);
|
|
714
|
+
const l = r.stopy - r.starty + 2 * n.diagramMarginY, u = A + r.stopx + 2 * n.diagramMarginX;
|
|
715
|
+
xt(y, l, u, n.useMaxWidth), y.append("line").attr("x1", A).attr("y1", n.height * 4).attr("x2", u - A - 4).attr("y2", n.height * 4).attr("stroke-width", 4).attr("stroke", "black").attr("marker-end", "url(#arrowhead)");
|
|
716
|
+
const a = d ? 70 : 0;
|
|
717
|
+
y.attr("viewBox", `${r.startx} -25 ${u} ${l + a}`), y.attr("preserveAspectRatio", "xMinYMin meet"), y.attr("height", l + a + 25);
|
|
718
|
+
}, v = {
|
|
719
|
+
data: {
|
|
720
|
+
startx: void 0,
|
|
721
|
+
stopx: void 0,
|
|
722
|
+
starty: void 0,
|
|
723
|
+
stopy: void 0
|
|
724
|
+
},
|
|
725
|
+
verticalPos: 0,
|
|
726
|
+
sequenceItems: [],
|
|
727
|
+
init: function() {
|
|
728
|
+
this.sequenceItems = [], this.data = {
|
|
729
|
+
startx: void 0,
|
|
730
|
+
stopx: void 0,
|
|
731
|
+
starty: void 0,
|
|
732
|
+
stopy: void 0
|
|
733
|
+
}, this.verticalPos = 0;
|
|
734
|
+
},
|
|
735
|
+
updateVal: function(t, e, s, o) {
|
|
736
|
+
t[e] === void 0 ? t[e] = s : t[e] = o(s, t[e]);
|
|
737
|
+
},
|
|
738
|
+
updateBounds: function(t, e, s, o) {
|
|
739
|
+
const n = P().journey, h = this;
|
|
740
|
+
let c = 0;
|
|
741
|
+
function p(y) {
|
|
742
|
+
return function(m) {
|
|
743
|
+
c++;
|
|
744
|
+
const d = h.sequenceItems.length - c + 1;
|
|
745
|
+
h.updateVal(m, "starty", e - d * n.boxMargin, Math.min), h.updateVal(m, "stopy", o + d * n.boxMargin, Math.max), h.updateVal(v.data, "startx", t - d * n.boxMargin, Math.min), h.updateVal(v.data, "stopx", s + d * n.boxMargin, Math.max), y !== "activation" && (h.updateVal(m, "startx", t - d * n.boxMargin, Math.min), h.updateVal(m, "stopx", s + d * n.boxMargin, Math.max), h.updateVal(v.data, "starty", e - d * n.boxMargin, Math.min), h.updateVal(v.data, "stopy", o + d * n.boxMargin, Math.max));
|
|
746
|
+
};
|
|
747
|
+
}
|
|
748
|
+
this.sequenceItems.forEach(p());
|
|
749
|
+
},
|
|
750
|
+
insert: function(t, e, s, o) {
|
|
751
|
+
const n = Math.min(t, s), h = Math.max(t, s), c = Math.min(e, o), p = Math.max(e, o);
|
|
752
|
+
this.updateVal(v.data, "startx", n, Math.min), this.updateVal(v.data, "starty", c, Math.min), this.updateVal(v.data, "stopx", h, Math.max), this.updateVal(v.data, "stopy", p, Math.max), this.updateBounds(n, c, h, p);
|
|
753
|
+
},
|
|
754
|
+
bumpVerticalPos: function(t) {
|
|
755
|
+
this.verticalPos = this.verticalPos + t, this.data.stopy = this.verticalPos;
|
|
756
|
+
},
|
|
757
|
+
getVerticalPos: function() {
|
|
758
|
+
return this.verticalPos;
|
|
759
|
+
},
|
|
760
|
+
getBounds: function() {
|
|
761
|
+
return this.data;
|
|
762
|
+
}
|
|
763
|
+
}, X = O.sectionFills, et = O.sectionColours, Bt = function(t, e, s) {
|
|
764
|
+
const o = P().journey;
|
|
765
|
+
let n = "";
|
|
766
|
+
const h = o.height * 2 + o.diagramMarginY, c = s + h;
|
|
767
|
+
let p = 0, y = "#CCC", m = "black", d = 0;
|
|
768
|
+
for (const [f, i] of e.entries()) {
|
|
769
|
+
if (n !== i.section) {
|
|
770
|
+
y = X[p % X.length], d = p % X.length, m = et[p % et.length];
|
|
771
|
+
let l = 0;
|
|
772
|
+
const u = i.section;
|
|
773
|
+
for (let g = f; g < e.length && e[g].section == u; g++)
|
|
774
|
+
l = l + 1;
|
|
775
|
+
const a = {
|
|
776
|
+
x: f * o.taskMargin + f * o.width + A,
|
|
777
|
+
y: 50,
|
|
778
|
+
text: i.section,
|
|
779
|
+
fill: y,
|
|
780
|
+
num: d,
|
|
781
|
+
colour: m,
|
|
782
|
+
taskCount: l
|
|
783
|
+
};
|
|
784
|
+
D.drawSection(t, a, o), n = i.section, p++;
|
|
785
|
+
}
|
|
786
|
+
const r = i.people.reduce((l, u) => (M[u] && (l[u] = M[u]), l), {});
|
|
787
|
+
i.x = f * o.taskMargin + f * o.width + A, i.y = c, i.width = o.diagramMarginX, i.height = o.diagramMarginY, i.colour = m, i.fill = y, i.num = d, i.actors = r, D.drawTask(t, i, o), v.insert(i.x, i.y, i.x + i.width + o.taskMargin, 300 + 5 * 30);
|
|
788
|
+
}
|
|
789
|
+
}, it = {
|
|
790
|
+
setConf: Nt,
|
|
791
|
+
draw: zt
|
|
792
|
+
}, qt = {
|
|
793
|
+
parser: vt,
|
|
794
|
+
db: K,
|
|
795
|
+
renderer: it,
|
|
796
|
+
styles: It,
|
|
797
|
+
init: (t) => {
|
|
798
|
+
it.setConf(t.journey), K.clear();
|
|
799
|
+
}
|
|
800
|
+
};
|
|
801
|
+
export {
|
|
802
|
+
qt as diagram
|
|
803
|
+
};
|