mxrb 0.1.2 → 0.1.4
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.
- checksums.yaml +4 -4
- data/bin/mxrb +458 -10
- data/docs/de-DE/README.md +1 -0
- data/docs/de-DE/oql-sql.md +42 -0
- data/docs/de-DE/project-structure.md +201 -2
- data/docs/de-DE/runtime-ruby.md +104 -0
- data/docs/de-DE/runtime-schema-migrations.md +44 -0
- data/docs/de-DE/validation-matrix.md +42 -4
- data/docs/en-US/README.md +1 -0
- data/docs/en-US/oql-sql.md +41 -0
- data/docs/en-US/project-structure.md +192 -2
- data/docs/en-US/runtime-ruby.md +100 -0
- data/docs/en-US/runtime-schema-migrations.md +41 -0
- data/docs/en-US/validation-matrix.md +39 -4
- data/docs/pt-BR/README.md +1 -0
- data/docs/pt-BR/entity-dsl.md +8 -0
- data/docs/pt-BR/oql-sql.md +41 -0
- data/docs/pt-BR/project-structure.md +197 -2
- data/docs/pt-BR/runtime-ruby.md +108 -0
- data/docs/pt-BR/runtime-schema-migrations.md +40 -0
- data/docs/pt-BR/validation-matrix.md +42 -5
- data/docs/pt-BR/writing.md +28 -0
- data/lib/mxrb/cli/help.rb +426 -0
- data/lib/mxrb/cli/release.rb +137 -0
- data/lib/mxrb/compiler/compatibility_analyzer.rb +1 -1
- data/lib/mxrb/compiler/data_grid_bundle_compiler.rb +8 -1
- data/lib/mxrb/compiler/domain_document_compiler.rb +3 -0
- data/lib/mxrb/compiler/gallery_bundle_compiler.rb +11 -1
- data/lib/mxrb/compiler/generic_widget_bundle_compiler.rb +76 -19
- data/lib/mxrb/compiler/legacy_custom_widget_compiler.rb +159 -0
- data/lib/mxrb/compiler/legacy_data_grid_compiler.rb +43 -7
- data/lib/mxrb/compiler/legacy_page_builder.rb +1248 -23
- data/lib/mxrb/compiler/packager.rb +27 -13
- data/lib/mxrb/compiler/page_bundle_compiler.rb +13 -4
- data/lib/mxrb/compiler/portable_packager.rb +16 -11
- data/lib/mxrb/compiler/web_bundle_builder.rb +5 -1
- data/lib/mxrb/compiler/web_shell_materializer.rb +42 -2
- data/lib/mxrb/compiler/widget_package_extractor.rb +3 -0
- data/lib/mxrb/domain_diagram/lifecycle.rb +272 -0
- data/lib/mxrb/domain_diagram.rb +409 -0
- data/lib/mxrb/dsl/builder.rb +62 -11
- data/lib/mxrb/environment.rb +226 -0
- data/lib/mxrb/exporter.rb +265 -45
- data/lib/mxrb/http/server.rb +107 -0
- data/lib/mxrb/initializer.rb +80 -9
- data/lib/mxrb/integrity/validator.rb +32 -7
- data/lib/mxrb/io/bson_codec.rb +42 -1
- data/lib/mxrb/io/mpr_file.rb +146 -3
- data/lib/mxrb/model/attribute.rb +3 -0
- data/lib/mxrb/model/entity.rb +44 -2
- data/lib/mxrb/model/microflow.rb +3 -1
- data/lib/mxrb/model/module.rb +71 -0
- data/lib/mxrb/model/page.rb +126 -15
- data/lib/mxrb/model/project.rb +3 -0
- data/lib/mxrb/modeler/catalog.rb +178 -0
- data/lib/mxrb/official_marketplace/module_package_importer.rb +23 -12
- data/lib/mxrb/official_marketplace/widget_package_installer.rb +15 -11
- data/lib/mxrb/official_marketplace.rb +9 -3
- data/lib/mxrb/oql/reverse_translator.rb +394 -0
- data/lib/mxrb/oql/server.rb +4 -8
- data/lib/mxrb/oql.rb +32 -4
- data/lib/mxrb/progress.rb +242 -0
- data/lib/mxrb/project_lifecycle.rb +5 -2
- data/lib/mxrb/ruby_app/exporter.rb +1749 -0
- data/lib/mxrb/ruby_app/preset.rb +506 -0
- data/lib/mxrb/ruby_app/session_manager.rb +122 -0
- data/lib/mxrb/ruby_app.rb +1361 -0
- data/lib/mxrb/runtime/access_control.rb +408 -0
- data/lib/mxrb/runtime/native.rb +1015 -93
- data/lib/mxrb/runtime/scheduler.rb +396 -0
- data/lib/mxrb/runtime/schema_migrator.rb +598 -0
- data/lib/mxrb/runtime/shared_store.rb +335 -0
- data/lib/mxrb/runtime/sqlite_store.rb +729 -0
- data/lib/mxrb/scaffold/generator.rb +11 -3
- data/lib/mxrb/team_server.rb +10 -7
- data/lib/mxrb/uml/activity_diagram.rb +118 -0
- data/lib/mxrb/uml/class_diagram.rb +118 -0
- data/lib/mxrb/uml/sequence_diagram.rb +112 -0
- data/lib/mxrb/uml/server.rb +146 -0
- data/lib/mxrb/uml/support.rb +35 -0
- data/lib/mxrb/version.rb +1 -1
- data/lib/mxrb/web_ui/assets/abnfDiagram-N423BO3Z-C4JD3cEC.js +1 -0
- data/lib/mxrb/web_ui/assets/arc-3Z53kgFp.js +1 -0
- data/lib/mxrb/web_ui/assets/architecture-TIHT7OUA-BStBTLea.js +1 -0
- data/lib/mxrb/web_ui/assets/architectureDiagram-T3A2C74G-DBwqnM4J.js +36 -0
- data/lib/mxrb/web_ui/assets/array-BifhSqXX.js +1 -0
- data/lib/mxrb/web_ui/assets/blockDiagram-VBNYF7ZC-DLtuHt-j.js +132 -0
- data/lib/mxrb/web_ui/assets/c4Diagram-5PPSVZJV-ConSk_pe.js +10 -0
- data/lib/mxrb/web_ui/assets/channel-BhPvD7Dt.js +1 -0
- data/lib/mxrb/web_ui/assets/chunk-2GRJ4B5K-D2HpWsf_.js +1 -0
- data/lib/mxrb/web_ui/assets/chunk-2Q5K7J3B-C1jixKkw.js +1 -0
- data/lib/mxrb/web_ui/assets/chunk-4I5QYGJK-CiIdNwaF.js +1 -0
- data/lib/mxrb/web_ui/assets/chunk-5RXB4S5H-Bu_AaEkE.js +231 -0
- data/lib/mxrb/web_ui/assets/chunk-5VM5RSS4-ZNzvKenW.js +15 -0
- data/lib/mxrb/web_ui/assets/chunk-6Q2QTUOP-wQkNmt_X.js +88 -0
- data/lib/mxrb/web_ui/assets/chunk-7BUUIJ7U-Bb538aSH.js +1 -0
- data/lib/mxrb/web_ui/assets/chunk-GF5L2VYU-G8MmiBzU.js +206 -0
- data/lib/mxrb/web_ui/assets/chunk-I66GZJ75-CulcrLPh.js +127 -0
- data/lib/mxrb/web_ui/assets/chunk-JQJVKLGR-ukjzcdlL.js +156 -0
- data/lib/mxrb/web_ui/assets/chunk-JWPE2WC7-DVXcaiue.js +1 -0
- data/lib/mxrb/web_ui/assets/chunk-KBJHAD2P-Wm35lYov.js +1 -0
- data/lib/mxrb/web_ui/assets/chunk-KEIR6QF5-BICK3FdT.js +161 -0
- data/lib/mxrb/web_ui/assets/chunk-NSK5VX7P-D2nYrCY4.js +2 -0
- data/lib/mxrb/web_ui/assets/chunk-QR6OTTB3-BrdIzg4Q.js +62 -0
- data/lib/mxrb/web_ui/assets/chunk-RYQCIY6F-CCfZMcW6.js +1 -0
- data/lib/mxrb/web_ui/assets/chunk-UBXNYLIW-BPEVYsFK.js +1 -0
- data/lib/mxrb/web_ui/assets/chunk-W5SLKNZC-2E6OPhA4.js +1 -0
- data/lib/mxrb/web_ui/assets/chunk-WRU74C26-CBIvOyWp.js +70 -0
- data/lib/mxrb/web_ui/assets/chunk-XXDRQBXY-pH58XAyl.js +1 -0
- data/lib/mxrb/web_ui/assets/chunk-Y2CYZVJY-DsF7k-Jl.js +1 -0
- data/lib/mxrb/web_ui/assets/classDiagram-JCYQIIEL-xiqo4D89.js +1 -0
- data/lib/mxrb/web_ui/assets/classDiagram-v2-OCEON4UE-xiqo4D89.js +1 -0
- data/lib/mxrb/web_ui/assets/cose-bilkent-JH36ORCC-t_flPpii.js +1 -0
- data/lib/mxrb/web_ui/assets/cynefin-VYW2F7L2-BIqktTEv.js +1 -0
- data/lib/mxrb/web_ui/assets/cynefinDiagram-MW4NZA55-C2d--lut.js +62 -0
- data/lib/mxrb/web_ui/assets/cytoscape.esm-B-NFISlW.js +321 -0
- data/lib/mxrb/web_ui/assets/dagre-Buvkdvvj.js +1 -0
- data/lib/mxrb/web_ui/assets/dagre-VZM6K2ZE-CSz2_tb5.js +4 -0
- data/lib/mxrb/web_ui/assets/defaultLocale-BFoDCU3G.js +1 -0
- data/lib/mxrb/web_ui/assets/diagram-7IWD3JNH-DCt7u7V_.js +30 -0
- data/lib/mxrb/web_ui/assets/diagram-B4RE2ZJO-DqZBqkMu.js +3 -0
- data/lib/mxrb/web_ui/assets/diagram-LBJQPF4R-ClIYbIsI.js +24 -0
- data/lib/mxrb/web_ui/assets/diagram-Q27KOJAE-DFxhvthJ.js +24 -0
- data/lib/mxrb/web_ui/assets/diagram-UB23O5K3-BSUTXptv.js +41 -0
- data/lib/mxrb/web_ui/assets/dist-D2qOEbeJ.js +1 -0
- data/lib/mxrb/web_ui/assets/domain-mGOZ1KCG.css +1 -0
- data/lib/mxrb/web_ui/assets/domain-qsjXhy4v.js +1 -0
- data/lib/mxrb/web_ui/assets/ebnfDiagram-BXEA7PRR-B5reICEi.js +1 -0
- data/lib/mxrb/web_ui/assets/erDiagram-JOGREHBK-Co5Mxn2p.js +85 -0
- data/lib/mxrb/web_ui/assets/eventmodeling-45OFAUF4-C1ylhSks.js +1 -0
- data/lib/mxrb/web_ui/assets/flowDiagram-UKHOOZJN-CHXaJIaS.js +1 -0
- data/lib/mxrb/web_ui/assets/ganttDiagram-PKOTCBZU-DPPPaWaz.js +292 -0
- data/lib/mxrb/web_ui/assets/gitGraph-TEB2WS4Q-qS77ywA9.js +1 -0
- data/lib/mxrb/web_ui/assets/gitGraphDiagram-DS77QQ5N-DpAv6-BT.js +106 -0
- data/lib/mxrb/web_ui/assets/graphlib-DS17s2tU.js +1 -0
- data/lib/mxrb/web_ui/assets/info-DKCQHKI2-C9VD1Y4e.js +1 -0
- data/lib/mxrb/web_ui/assets/infoDiagram-6WML65LV-Bk1kbcCy.js +2 -0
- data/lib/mxrb/web_ui/assets/init-C-OQMol4.js +1 -0
- data/lib/mxrb/web_ui/assets/ishikawaDiagram-WSZJBQD7-0gcISBFR.js +70 -0
- data/lib/mxrb/web_ui/assets/journeyDiagram-NVQOT4AX-Dt0RQnlh.js +139 -0
- data/lib/mxrb/web_ui/assets/jsx-runtime-DV0a5kSb.js +9 -0
- data/lib/mxrb/web_ui/assets/kanban-definition-27J2QSJJ-DIPQM7w9.js +89 -0
- data/lib/mxrb/web_ui/assets/katex-CXMH3UgJ.js +257 -0
- data/lib/mxrb/web_ui/assets/line-C0rYD-tL.js +1 -0
- data/lib/mxrb/web_ui/assets/linear-BPPxWorj.js +1 -0
- data/lib/mxrb/web_ui/assets/map-BaFkSB1l.js +1 -0
- data/lib/mxrb/web_ui/assets/mermaid-parser.core-B_UPzTxa.js +7 -0
- data/lib/mxrb/web_ui/assets/mindmap-definition-FAOFIHXS-CdJRSMuk.js +96 -0
- data/lib/mxrb/web_ui/assets/modeler-BNqHthwk.css +1 -0
- data/lib/mxrb/web_ui/assets/modeler-CQmqflbg.js +1 -0
- data/lib/mxrb/web_ui/assets/ordinal-BDEzSJ7C.js +1 -0
- data/lib/mxrb/web_ui/assets/packet-7NZHBO7P-CwQ4NSBs.js +1 -0
- data/lib/mxrb/web_ui/assets/path-fybaL0A-.js +1 -0
- data/lib/mxrb/web_ui/assets/pegDiagram-VL7TDLO6-D40S7ppx.js +1 -0
- data/lib/mxrb/web_ui/assets/pie-RZYD4A2V-CJroHMKh.js +1 -0
- data/lib/mxrb/web_ui/assets/pieDiagram-7S7Q4E2Y-QB54__BV.js +39 -0
- data/lib/mxrb/web_ui/assets/quadrantDiagram-CIZ2JOQS-DBhDS6ag.js +7 -0
- data/lib/mxrb/web_ui/assets/radar-I7S5WNFK-DdIUwd2d.js +1 -0
- data/lib/mxrb/web_ui/assets/railroad-3IZDKUUU-B1Lw6Xyq.js +1 -0
- data/lib/mxrb/web_ui/assets/railroad-abnf-AHOZXSZD-CQgQoeak.js +1 -0
- data/lib/mxrb/web_ui/assets/railroad-ebnf-EBAXGLYW-D7qEQ2x8.js +1 -0
- data/lib/mxrb/web_ui/assets/railroad-peg-LSFZ7HO6-C005Vxbb.js +1 -0
- data/lib/mxrb/web_ui/assets/railroadDiagram-AXF67PYL-BBP2qk7M.js +1 -0
- data/lib/mxrb/web_ui/assets/requirementDiagram-LRYGKXZP-D2cLsAoI.js +84 -0
- data/lib/mxrb/web_ui/assets/rough.esm-Dy-Kn_BL.js +1 -0
- data/lib/mxrb/web_ui/assets/sankeyDiagram-W5VNT64P-Bpi3FiP2.js +40 -0
- data/lib/mxrb/web_ui/assets/sequenceDiagram-SI44F4Z6-DCRcDlVe.js +162 -0
- data/lib/mxrb/web_ui/assets/sizeCapture-X5ZJPWSS-B0uUizjq.js +1 -0
- data/lib/mxrb/web_ui/assets/src-CvxfUak2.js +1 -0
- data/lib/mxrb/web_ui/assets/stateDiagram-OKZ733FA-C2GCEoxl.js +1 -0
- data/lib/mxrb/web_ui/assets/stateDiagram-v2-UEYNNEHI-D2gWgedh.js +1 -0
- data/lib/mxrb/web_ui/assets/swimlanes-SLNWSIFB-CRI9irEW.js +2 -0
- data/lib/mxrb/web_ui/assets/swimlanesDiagram-ULZ7WXOC-C5Wb_-hZ.js +8 -0
- data/lib/mxrb/web_ui/assets/theme-_mxc7BdY.css +1 -0
- data/lib/mxrb/web_ui/assets/timeline-definition-Z64GVDOM-B1-mNg-h.js +120 -0
- data/lib/mxrb/web_ui/assets/treeView-QDETBFTQ-7CTvIwKq.js +1 -0
- data/lib/mxrb/web_ui/assets/treemap-6X3UGDF4-CtL22pq5.js +1 -0
- data/lib/mxrb/web_ui/assets/uml-C3KAFGTq.js +51 -0
- data/lib/mxrb/web_ui/assets/uml-Dn-qd01X.css +1 -0
- data/lib/mxrb/web_ui/assets/vennDiagram-T6HMQDX7-BzVnUEAy.js +34 -0
- data/lib/mxrb/web_ui/assets/wardley-OPB4EBWU-JNi-QNag.js +1 -0
- data/lib/mxrb/web_ui/assets/wardleyDiagram-T6FBY63Y-BUwmAQ-B.js +78 -0
- data/lib/mxrb/web_ui/assets/xychartDiagram-ELKLHX3M-DEQS8sKp.js +7 -0
- data/lib/mxrb/web_ui/domain.html +15 -0
- data/lib/mxrb/web_ui/modeler.html +16 -0
- data/lib/mxrb/web_ui/uml.html +31 -0
- data/lib/mxrb/web_ui.rb +89 -0
- data/lib/mxrb/widget_certification.rb +208 -0
- data/lib/mxrb/writer.rb +278 -41
- data/lib/mxrb.rb +38 -8
- metadata +157 -5
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{n as e,t}from"./path-fybaL0A-.js";import{t as n}from"./array-BifhSqXX.js";import{rt as r}from"./chunk-NSK5VX7P-D2nYrCY4.js";function i(e){return e[0]}function a(e){return e[1]}function o(o,s){var c=e(!0),l=null,u=r,d=null,f=t(p);o=typeof o==`function`?o:o===void 0?i:e(o),s=typeof s==`function`?s:s===void 0?a:e(s);function p(e){var t,r=(e=n(e)).length,i,a=!1,p;for(l??(d=u(p=f())),t=0;t<=r;++t)!(t<r&&c(i=e[t],t,e))===a&&((a=!a)?d.lineStart():d.lineEnd()),a&&d.point(+o(i,t,e),+s(i,t,e));if(p)return d=null,p+``||null}return p.x=function(t){return arguments.length?(o=typeof t==`function`?t:e(+t),p):o},p.y=function(t){return arguments.length?(s=typeof t==`function`?t:e(+t),p):s},p.defined=function(t){return arguments.length?(c=typeof t==`function`?t:e(!!t),p):c},p.curve=function(e){return arguments.length?(u=e,l!=null&&(d=u(l)),p):u},p.context=function(e){return arguments.length?(e==null?l=d=null:d=u(l=e),p):l},p}export{o as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{l as e,n as t,o as n,r,t as i}from"./src-CvxfUak2.js";import{i as a,n as o,r as s,t as c}from"./defaultLocale-BFoDCU3G.js";import{t as l}from"./init-C-OQMol4.js";function u(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function d(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function f(e){let t,n,r;e.length===2?(t=e===u||e===d?e:p,n=e,r=e):(t=u,n=(t,n)=>u(e(t),n),r=(t,n)=>e(t)-n);function i(e,r,i=0,a=e.length){if(i<a){if(t(r,r)!==0)return a;do{let t=i+a>>>1;n(e[t],r)<0?i=t+1:a=t}while(i<a)}return i}function a(e,r,i=0,a=e.length){if(i<a){if(t(r,r)!==0)return a;do{let t=i+a>>>1;n(e[t],r)<=0?i=t+1:a=t}while(i<a)}return i}function o(e,t,n=0,a=e.length){let o=i(e,t,n,a-1);return o>n&&r(e[o-1],t)>-r(e[o],t)?o-1:o}return{left:i,center:o,right:a}}function p(){return 0}function m(e){return e===null?NaN:+e}var h=f(u),g=h.right;h.left,f(m).center;var _=Math.sqrt(50),v=Math.sqrt(10),y=Math.sqrt(2);function b(e,t,n){let r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),a=r/10**i,o=a>=_?10:a>=v?5:a>=y?2:1,s,c,l;return i<0?(l=10**-i/o,s=Math.round(e*l),c=Math.round(t*l),s/l<e&&++s,c/l>t&&--c,l=-l):(l=10**i*o,s=Math.round(e/l),c=Math.round(t/l),s*l<e&&++s,c*l>t&&--c),c<s&&.5<=n&&n<2?b(e,t,n*2):[s,c,l]}function x(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];let r=t<e,[i,a,o]=r?b(t,e,n):b(e,t,n);if(!(a>=i))return[];let s=a-i+1,c=Array(s);if(r){if(o<0)for(let e=0;e<s;++e)c[e]=(a-e)/-o;else for(let e=0;e<s;++e)c[e]=(a-e)*o}else if(o<0)for(let e=0;e<s;++e)c[e]=(i+e)/-o;else for(let e=0;e<s;++e)c[e]=(i+e)*o;return c}function S(e,t,n){return t=+t,e=+e,n=+n,b(e,t,n)[2]}function C(e,t,n){t=+t,e=+e,n=+n;let r=t<e,i=r?S(t,e,n):S(e,t,n);return(r?-1:1)*(i<0?1/-i:i)}function w(e,t){t||=[];var n=e?Math.min(t.length,e.length):0,r=t.slice(),i;return function(a){for(i=0;i<n;++i)r[i]=e[i]*(1-a)+t[i]*a;return r}}function T(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function E(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,i=Array(r),a=Array(n),o;for(o=0;o<r;++o)i[o]=k(e[o],t[o]);for(;o<n;++o)a[o]=t[o];return function(e){for(o=0;o<r;++o)a[o]=i[o](e);return a}}function D(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function O(e,t){var n={},r={},i;for(i in(typeof e!=`object`||!e)&&(e={}),(typeof t!=`object`||!t)&&(t={}),t)i in e?n[i]=k(e[i],t[i]):r[i]=t[i];return function(e){for(i in n)r[i]=n[i](e);return r}}function k(a,o){var s=typeof o,c;return o==null||s===`boolean`?n(o):(s===`number`?t:s===`string`?(c=e(o))?(o=c,r):i:o instanceof e?r:o instanceof Date?D:T(o)?w:Array.isArray(o)?E:typeof o.valueOf!=`function`&&typeof o.toString!=`function`||isNaN(o)?O:t)(a,o)}function A(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}function j(e){return Math.max(0,-a(Math.abs(e)))}function M(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(a(t)/3)))*3-a(Math.abs(e)))}function N(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,a(t)-a(e))+1}function P(e){return function(){return e}}function F(e){return+e}var I=[0,1];function L(e){return e}function R(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:P(isNaN(t)?NaN:.5)}function z(e,t){var n;return e>t&&(n=e,e=t,t=n),function(n){return Math.max(e,Math.min(t,n))}}function B(e,t,n){var r=e[0],i=e[1],a=t[0],o=t[1];return i<r?(r=R(i,r),a=n(o,a)):(r=R(r,i),a=n(a,o)),function(e){return a(r(e))}}function V(e,t,n){var r=Math.min(e.length,t.length)-1,i=Array(r),a=Array(r),o=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++o<r;)i[o]=R(e[o],e[o+1]),a[o]=n(t[o],t[o+1]);return function(t){var n=g(e,t,1,r)-1;return a[n](i[n](t))}}function H(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function U(){var e=I,n=I,r=k,i,a,o,s=L,c,l,u;function d(){var t=Math.min(e.length,n.length);return s!==L&&(s=z(e[0],e[t-1])),c=t>2?V:B,l=u=null,f}function f(t){return t==null||isNaN(t=+t)?o:(l||=c(e.map(i),n,r))(i(s(t)))}return f.invert=function(r){return s(a((u||=c(n,e.map(i),t))(r)))},f.domain=function(t){return arguments.length?(e=Array.from(t,F),d()):e.slice()},f.range=function(e){return arguments.length?(n=Array.from(e),d()):n.slice()},f.rangeRound=function(e){return n=Array.from(e),r=A,d()},f.clamp=function(e){return arguments.length?(s=e?!0:L,d()):s!==L},f.interpolate=function(e){return arguments.length?(r=e,d()):r},f.unknown=function(e){return arguments.length?(o=e,f):o},function(e,t){return i=e,a=t,d()}}function W(){return U()(L,L)}function G(e,t,n,r){var i=C(e,t,n),a;switch(r=s(r??`,f`),r.type){case`s`:var l=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(a=M(i,l))&&(r.precision=a),o(r,l);case``:case`e`:case`g`:case`p`:case`r`:r.precision==null&&!isNaN(a=N(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=a-(r.type===`e`));break;case`f`:case`%`:r.precision==null&&!isNaN(a=j(i))&&(r.precision=a-(r.type===`%`)*2)}return c(r)}function K(e){var t=e.domain;return e.ticks=function(e){var n=t();return x(n[0],n[n.length-1],e??10)},e.tickFormat=function(e,n){var r=t();return G(r[0],r[r.length-1],e??10,n)},e.nice=function(n){n??=10;var r=t(),i=0,a=r.length-1,o=r[i],s=r[a],c,l,u=10;for(s<o&&(l=o,o=s,s=l,l=i,i=a,a=l);u-->0;){if(l=S(o,s,n),l===c)return r[i]=o,r[a]=s,t(r);if(l>0)o=Math.floor(o/l)*l,s=Math.ceil(s/l)*l;else if(l<0)o=Math.ceil(o*l)/l,s=Math.floor(s*l)/l;else break;c=l}return e},e}function q(){var e=W();return e.copy=function(){return H(e,q())},l.apply(e,arguments),K(e)}export{f as a,C as i,W as n,H as r,q as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{$ as e,F as t,G as n,H as r,I as i,M as a,P as o,Q as s,R as c,S as ee,Z as l,_ as u,b as d,f,g as p,it as m,j as h,k as g,l as _,q as v,rt as y,tt as b,v as te,w as ne,x as re,y as ie,z as x}from"./graphlib-DS17s2tU.js";var S=Object.create,ae=function(){function e(){}return function(t){if(!l(t))return{};if(S)return S(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function C(e,t){var n=-1,r=e.length;for(t||=Array(r);++n<r;)t[n]=e[n];return t}function w(e,t,n){t==`__proto__`&&v?v(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}var oe=Object.prototype.hasOwnProperty;function T(e,t,n){var i=e[t];(!(oe.call(e,t)&&r(i,n))||n===void 0&&!(t in e))&&w(e,t,n)}function E(e,t,n,r){var i=!n;n||={};for(var a=-1,o=t.length;++a<o;){var s=t[a],c=r?r(n[s],e[s],s,n,e):void 0;c===void 0&&(c=e[s]),i?w(n,s,c):T(n,s,c)}return n}function se(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var D=Object.prototype.hasOwnProperty;function ce(e){if(!l(e))return se(e);var t=c(e),n=[];for(var r in e)r==`constructor`&&(t||!D.call(e,r))||n.push(r);return n}function O(e){return x(e)?a(e,!0):ce(e)}var k=h(Object.getPrototypeOf,Object);function le(e,t){return e&&E(t,g(t),e)}function ue(e,t){return e&&E(t,O(t),e)}var A=typeof exports==`object`&&exports&&!exports.nodeType&&exports,j=A&&typeof module==`object`&&module&&!module.nodeType&&module,M=j&&j.exports===A?m.Buffer:void 0,N=M?M.allocUnsafe:void 0;function P(e,t){if(t)return e.slice();var n=e.length,r=N?N(n):new e.constructor(n);return e.copy(r),r}function de(e,t){return E(e,d(e),t)}var F=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)ne(t,d(e)),e=k(e);return t}:re;function fe(e,t){return E(e,F(e),t)}function pe(e){return ie(e,O,F)}var I=Object.prototype.hasOwnProperty;function L(e){var t=e.length,n=new e.constructor(t);return t&&typeof e[0]==`string`&&I.call(e,`index`)&&(n.index=e.index,n.input=e.input),n}function R(e){var t=new e.constructor(e.byteLength);return new p(t).set(new p(e)),t}function z(e,t){var n=t?R(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}var B=/\w*$/;function me(e){var t=new e.constructor(e.source,B.exec(e));return t.lastIndex=e.lastIndex,t}var V=y?y.prototype:void 0,H=V?V.valueOf:void 0;function he(e){return H?Object(H.call(e)):{}}function U(e,t){var n=t?R(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var ge=`[object Boolean]`,_e=`[object Date]`,ve=`[object Map]`,ye=`[object Number]`,be=`[object RegExp]`,xe=`[object Set]`,Se=`[object String]`,Ce=`[object Symbol]`,we=`[object ArrayBuffer]`,Te=`[object DataView]`,Ee=`[object Float32Array]`,De=`[object Float64Array]`,Oe=`[object Int8Array]`,ke=`[object Int16Array]`,Ae=`[object Int32Array]`,je=`[object Uint8Array]`,Me=`[object Uint8ClampedArray]`,Ne=`[object Uint16Array]`,Pe=`[object Uint32Array]`;function Fe(e,t,n){var r=e.constructor;switch(t){case we:return R(e);case ge:case _e:return new r(+e);case Te:return z(e,n);case Ee:case De:case Oe:case ke:case Ae:case je:case Me:case Ne:case Pe:return U(e,n);case ve:return new r;case ye:case Se:return new r(e);case be:return me(e);case xe:return new r;case Ce:return he(e)}}function W(e){return typeof e.constructor==`function`&&!c(e)?ae(k(e)):{}}var Ie=`[object Map]`;function Le(e){return b(e)&&u(e)==Ie}var G=o&&o.isMap,Re=G?t(G):Le,ze=`[object Set]`;function Be(e){return b(e)&&u(e)==ze}var K=o&&o.isSet,Ve=K?t(K):Be,He=1,Ue=2,We=4,q=`[object Arguments]`,Ge=`[object Array]`,Ke=`[object Boolean]`,qe=`[object Date]`,Je=`[object Error]`,J=`[object Function]`,Ye=`[object GeneratorFunction]`,Xe=`[object Map]`,Ze=`[object Number]`,Y=`[object Object]`,Qe=`[object RegExp]`,$e=`[object Set]`,et=`[object String]`,tt=`[object Symbol]`,nt=`[object WeakMap]`,rt=`[object ArrayBuffer]`,it=`[object DataView]`,X=`[object Float32Array]`,at=`[object Float64Array]`,ot=`[object Int8Array]`,st=`[object Int16Array]`,ct=`[object Int32Array]`,lt=`[object Uint8Array]`,ut=`[object Uint8ClampedArray]`,dt=`[object Uint16Array]`,ft=`[object Uint32Array]`,Z={};Z[q]=Z[Ge]=Z[rt]=Z[it]=Z[Ke]=Z[qe]=Z[X]=Z[at]=Z[ot]=Z[st]=Z[ct]=Z[Xe]=Z[Ze]=Z[Y]=Z[Qe]=Z[$e]=Z[et]=Z[tt]=Z[lt]=Z[ut]=Z[dt]=Z[ft]=!0,Z[Je]=Z[J]=Z[nt]=!1;function Q(e,t,r,a,o,c){var d,f=t&He,p=t&Ue,m=t&We;if(r&&(d=o?r(e,a,o,c):r(e)),d!==void 0)return d;if(!l(e))return e;var h=s(e);if(h){if(d=L(e),!f)return C(e,d)}else{var _=u(e),v=_==J||_==Ye;if(i(e))return P(e,f);if(_==Y||_==q||v&&!o){if(d=p||v?{}:W(e),!f)return p?fe(e,ue(d,e)):de(e,le(d,e))}else{if(!Z[_])return o?e:{};d=Fe(e,_,f)}}c||=new ee;var y=c.get(e);if(y)return y;c.set(e,d),Ve(e)?e.forEach(function(n){d.add(Q(n,t,r,n,e,c))}):Re(e)&&e.forEach(function(n,i){d.set(i,Q(n,t,r,i,e,c))});var b=h?void 0:(m?p?pe:te:p?O:g)(e);return n(b||e,function(n,i){b&&(i=n,n=e[i]),T(d,i,Q(n,t,r,i,e,c))}),d}function $(e,t){var n=-1,r=x(e)?Array(e.length):[];return _(e,function(e,i,a){r[++n]=t(e,i,a)}),r}function pt(t,n){return(s(t)?e:$)(t,f(n,3))}export{U as a,O as c,w as d,C as f,W as i,E as l,$ as n,P as o,Q as r,k as s,pt as t,T as u};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./info-DKCQHKI2-C9VD1Y4e.js","./chunk-KEIR6QF5-BICK3FdT.js","./packet-7NZHBO7P-CwQ4NSBs.js","./pie-RZYD4A2V-CJroHMKh.js","./treeView-QDETBFTQ-7CTvIwKq.js","./architecture-TIHT7OUA-BStBTLea.js","./gitGraph-TEB2WS4Q-qS77ywA9.js","./eventmodeling-45OFAUF4-C1ylhSks.js","./radar-I7S5WNFK-DdIUwd2d.js","./railroad-3IZDKUUU-B1Lw6Xyq.js","./railroad-ebnf-EBAXGLYW-D7qEQ2x8.js","./railroad-abnf-AHOZXSZD-CQgQoeak.js","./railroad-peg-LSFZ7HO6-C005Vxbb.js","./treemap-6X3UGDF4-CtL22pq5.js","./wardley-OPB4EBWU-JNi-QNag.js","./cynefin-VYW2F7L2-BIqktTEv.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{$ as e}from"./chunk-I66GZJ75-CulcrLPh.js";import{C as t,S as n,_ as r,a as i,b as a,c as o,d as ee,f as te,g as ne,h as re,i as s,l as ie,m as ae,n as c,o as l,p as oe,r as se,s as ce,t as u,u as d,v as le,w as f,x as p,y as ue}from"./chunk-KEIR6QF5-BICK3FdT.js";var de=class extends u{static{p(this,`ArchitectureTokenBuilder`)}constructor(){super([`architecture`])}},fe=class extends c{static{p(this,`ArchitectureValueConverter`)}runCustomConverter(e,t,n){if(e.name===`ARCH_ICON`)return t.replace(/[()]/g,``).trim();if(e.name===`ARCH_TEXT_ICON`)return t.replace(/["()]/g,``);if(e.name===`ARCH_TITLE`){let e=t.replace(/^\[|]$/g,``).trim();return(e.startsWith(`"`)&&e.endsWith(`"`)||e.startsWith(`'`)&&e.endsWith(`'`))&&(e=e.slice(1,-1),e=e.replace(/\\"/g,`"`).replace(/\\'/g,`'`)),e.trim()}}},m={parser:{TokenBuilder:p(()=>new de,`TokenBuilder`),ValueConverter:p(()=>new fe,`ValueConverter`)}};function h(e=l){let r=f(t(e),d),i=f(n({shared:r}),se,m);return r.ServiceRegistry.register(i),{shared:r,Architecture:i}}p(h,`createArchitectureServices`);var pe=class extends u{static{p(this,`CynefinTokenBuilder`)}constructor(){super([`cynefin-beta`])}},g={parser:{TokenBuilder:p(()=>new pe,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)}};function _(e=l){let r=f(t(e),d),a=f(n({shared:r}),i,g);return r.ServiceRegistry.register(a),{shared:r,Cynefin:a}}p(_,`createCynefinServices`);var me=class extends u{static{p(this,`EventModelingTokenBuilder`)}constructor(){super([`eventmodeling`])}},v=new Set([`cmd`,`command`]),y=new Set([`evt`,`event`]),b=new Set([`rmo`,`readmodel`]),x=new Set([`pcr`,`processor`]),S=new Set([`ui`]);function C(e){let t=e.validation.EventModelingValidator,n=e.validation.ValidationRegistry;if(n){let e={EmTimeFrame:t.checkSourceFrameTypes.bind(t),EmResetFrame:t.checkSourceFrameTypes.bind(t)};n.register(e,t)}}p(C,`registerValidationChecks`);var he=class{static{p(this,`EventModelingValidator`)}checkSourceFrameTypes(e,t){e.sourceFrames.length!==0&&(v.has(e.modelEntityType)?this.validateSources(e,new Set([...S,...x]),`command`,`ui or processor`,t):y.has(e.modelEntityType)?this.validateSources(e,v,`event`,`command`,t):b.has(e.modelEntityType)?this.validateSources(e,y,`read model`,`event`,t):x.has(e.modelEntityType)?this.validateSources(e,b,`processor`,`read model`,t):S.has(e.modelEntityType)&&this.validateSources(e,b,`ui`,`read model`,t))}validateSources(e,t,n,r,i){for(let a of e.sourceFrames){let o=a.ref;o!==void 0&&!t.has(o.modelEntityType)&&i(`error`,`A ${n} can only receive input from a ${r}, not from '${o.modelEntityType}'.`,{node:e,property:`sourceFrames`})}}},w={parser:{TokenBuilder:p(()=>new me,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)},validation:{EventModelingValidator:p(()=>new he,`EventModelingValidator`)}};function T(e=l){let r=f(t(e),d),i=f(n({shared:r}),ce,w);return r.ServiceRegistry.register(i),C(i),{shared:r,EventModel:i}}p(T,`createEventModelingServices`);var ge=class extends u{static{p(this,`GitGraphTokenBuilder`)}constructor(){super([`gitGraph`])}},E={parser:{TokenBuilder:p(()=>new ge,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)}};function D(e=l){let r=f(t(e),d),i=f(n({shared:r}),o,E);return r.ServiceRegistry.register(i),{shared:r,GitGraph:i}}p(D,`createGitGraphServices`);var _e=class extends u{static{p(this,`InfoTokenBuilder`)}constructor(){super([`info`,`showInfo`])}},O={parser:{TokenBuilder:p(()=>new _e,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)}};function k(e=l){let r=f(t(e),d),i=f(n({shared:r}),ie,O);return r.ServiceRegistry.register(i),{shared:r,Info:i}}p(k,`createInfoServices`);var ve=class extends u{static{p(this,`PacketTokenBuilder`)}constructor(){super([`packet`])}},A={parser:{TokenBuilder:p(()=>new ve,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)}};function j(e=l){let r=f(t(e),d),i=f(n({shared:r}),ee,A);return r.ServiceRegistry.register(i),{shared:r,Packet:i}}p(j,`createPacketServices`);var ye=class extends u{static{p(this,`PieTokenBuilder`)}constructor(){super([`pie`,`showData`])}},be=class extends c{static{p(this,`PieValueConverter`)}runCustomConverter(e,t,n){if(e.name===`PIE_SECTION_LABEL`)return t.replace(/"/g,``).trim()}},M={parser:{TokenBuilder:p(()=>new ye,`TokenBuilder`),ValueConverter:p(()=>new be,`ValueConverter`)}};function N(e=l){let r=f(t(e),d),i=f(n({shared:r}),te,M);return r.ServiceRegistry.register(i),{shared:r,Pie:i}}p(N,`createPieServices`);var xe=class extends u{static{p(this,`RadarTokenBuilder`)}constructor(){super([`radar-beta`])}},P={parser:{TokenBuilder:p(()=>new xe,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)}};function F(e=l){let r=f(t(e),d),i=f(n({shared:r}),oe,P);return r.ServiceRegistry.register(i),{shared:r,Radar:i}}p(F,`createRadarServices`);var Se=class extends u{static{p(this,`RailroadTokenBuilder`)}constructor(){super([`railroad-beta`])}},I=p(e=>{let t=e.slice(1,-1),n=``;for(let e=0;e<t.length;e++){let r=t[e];if(r===`\\`&&e+1<t.length){e++;let r=t[e];switch(r){case`n`:n+=`
|
|
3
|
+
`;break;case`r`:n+=`\r`;break;case`t`:n+=` `;break;default:n+=r}continue}n+=r}return n},`decodeEscapedString`),Ce=class extends c{static{p(this,`RailroadValueConverter`)}runConverter(e,t,n){let r=super.runConverter(e,t,n);if(e.name===`TITLE`&&typeof r==`string`){let e=r.trim();if(e.startsWith(`"`)&&e.endsWith(`"`)||e.startsWith(`'`)&&e.endsWith(`'`))return I(e)}return r}runCustomConverter(e,t,n){if(e.name===`RR_STRING`)return I(t)}},L={parser:{TokenBuilder:p(()=>new Se,`TokenBuilder`),ValueConverter:p(()=>new Ce,`ValueConverter`)}};function we(e=l){let r=f(t(e),d),i=f(n({shared:r}),ne,L);return r.ServiceRegistry.register(i),{shared:r,Railroad:i}}p(we,`createRailroadServices`);var Te=class extends u{static{p(this,`RailroadAbnfTokenBuilder`)}constructor(){super([`railroad-abnf-beta`])}},Ee=class extends c{static{p(this,`RailroadAbnfValueConverter`)}runConverter(e,t,n){let r=super.runConverter(e,t,n);if(e.name===`TITLE`&&typeof r==`string`){let e=r.trim();if(e.startsWith(`"`)&&e.endsWith(`"`)||e.startsWith(`'`)&&e.endsWith(`'`))return e.slice(1,-1)}return r}runCustomConverter(e,t,n){if(e.name===`ABNF_STRING`)return t.slice(1,-1)}},R={parser:{TokenBuilder:p(()=>new Te,`TokenBuilder`),ValueConverter:p(()=>new Ee,`ValueConverter`)}};function z(e=l){let r=f(t(e),d),i=f(n({shared:r}),ae,R);return r.ServiceRegistry.register(i),{shared:r,RailroadAbnf:i}}p(z,`createRailroadAbnfServices`);var De=class extends u{static{p(this,`RailroadEbnfTokenBuilder`)}constructor(){super([`railroad-ebnf-beta`])}},B=p(e=>{let t=e.slice(1,-1),n=``;for(let e=0;e<t.length;e++){let r=t[e];if(r===`\\`&&e+1<t.length){e++;let r=t[e];switch(r){case`n`:n+=`
|
|
4
|
+
`;break;case`r`:n+=`\r`;break;case`t`:n+=` `;break;default:n+=r}continue}n+=r}return n},`decodeEscapedString`),Oe=class extends c{static{p(this,`RailroadEbnfValueConverter`)}runConverter(e,t,n){let r=super.runConverter(e,t,n);if(e.name===`TITLE`&&typeof r==`string`){let e=r.trim();if(e.startsWith(`"`)&&e.endsWith(`"`)||e.startsWith(`'`)&&e.endsWith(`'`))return B(e)}return r}runCustomConverter(e,t,n){if(e.name===`EBNF_STRING`)return B(t);if(e.name===`EBNF_SPECIAL_SEQUENCE`)return t.slice(1,-1).trim()}},V={parser:{TokenBuilder:p(()=>new De,`TokenBuilder`),ValueConverter:p(()=>new Oe,`ValueConverter`)}};function H(e=l){let r=f(t(e),d),i=f(n({shared:r}),re,V);return r.ServiceRegistry.register(i),{shared:r,RailroadEbnf:i}}p(H,`createRailroadEbnfServices`);var ke=class extends u{static{p(this,`RailroadPegTokenBuilder`)}constructor(){super([`railroad-peg-beta`])}},U=p(e=>{let t=e.slice(1,-1),n=``;for(let e=0;e<t.length;e++){let r=t[e];if(r===`\\`&&e+1<t.length){e++;let r=t[e];switch(r){case`n`:n+=`
|
|
5
|
+
`;break;case`r`:n+=`\r`;break;case`t`:n+=` `;break;default:n+=r}continue}n+=r}return n},`decodeEscapedString`),Ae=class extends c{static{p(this,`RailroadPegValueConverter`)}runConverter(e,t,n){let r=super.runConverter(e,t,n);if(e.name===`TITLE`&&typeof r==`string`){let e=r.trim();if(e.startsWith(`"`)&&e.endsWith(`"`)||e.startsWith(`'`)&&e.endsWith(`'`))return U(e)}return r}runCustomConverter(e,t,n){if(e.name===`PEG_STRING`)return U(t)}},W={parser:{TokenBuilder:p(()=>new ke,`TokenBuilder`),ValueConverter:p(()=>new Ae,`ValueConverter`)}};function G(e=l){let i=f(t(e),d),a=f(n({shared:i}),r,W);return i.ServiceRegistry.register(a),{shared:i,RailroadPeg:a}}p(G,`createRailroadPegServices`);var je=class extends c{static{p(this,`TreeViewValueConverter`)}runCustomConverter(e,t,n){if(e.name===`INDENTATION`)return t?.length||0;if(e.name===`QUOTED_NAME`)return t.substring(1,t.length-1);if(e.name===`BARE_NAME`)return t.replace(/[\t ]+$/,``);if(e.name===`CLASS_ANNOTATION`)return t.trim().substring(3).trim();if(e.name===`ICON_ANNOTATION`){let e=t.trim();return e.substring(5,e.length-1)}if(e.name===`DESC_ANNOTATION`)return t.trim().substring(2).trim()}},Me=class extends u{static{p(this,`TreeViewTokenBuilder`)}constructor(){super([`treeView-beta`])}},K={parser:{TokenBuilder:p(()=>new Me,`TokenBuilder`),ValueConverter:p(()=>new je,`ValueConverter`)}};function q(e=l){let r=f(t(e),d),i=f(n({shared:r}),le,K);return r.ServiceRegistry.register(i),{shared:r,TreeView:i}}p(q,`createTreeViewServices`);var Ne=class extends u{static{p(this,`TreemapTokenBuilder`)}constructor(){super([`treemap`])}},Pe=/classDef\s+([A-Z_a-z]\w+)(?:\s+([^\n\r;]*))?;?/,Fe=class extends c{static{p(this,`TreemapValueConverter`)}runCustomConverter(e,t,n){if(e.name===`NUMBER2`)return parseFloat(t.replace(/,/g,``));if(e.name===`SEPARATOR`||e.name===`STRING2`)return t.substring(1,t.length-1);if(e.name===`INDENTATION`)return t.length;if(e.name===`ClassDef`){if(typeof t!=`string`)return t;let e=Pe.exec(t);if(e)return{$type:`ClassDefStatement`,className:e[1],styleText:e[2]||void 0}}}};function J(e){let t=e.validation.TreemapValidator,n=e.validation.ValidationRegistry;if(n){let e={Treemap:t.checkSingleRoot.bind(t)};n.register(e,t)}}p(J,`registerValidationChecks`);var Ie=class{static{p(this,`TreemapValidator`)}checkSingleRoot(e,t){let n;for(let r of e.TreemapRows)r.item&&(n===void 0&&r.indent===void 0?n=0:(r.indent===void 0||n!==void 0&&n>=parseInt(r.indent,10))&&t(`error`,`Multiple root nodes are not allowed in a treemap.`,{node:r,property:`item`}))}},Y={parser:{TokenBuilder:p(()=>new Ne,`TokenBuilder`),ValueConverter:p(()=>new Fe,`ValueConverter`)},validation:{TreemapValidator:p(()=>new Ie,`TreemapValidator`)}};function X(e=l){let r=f(t(e),d),i=f(n({shared:r}),ue,Y);return r.ServiceRegistry.register(i),J(i),{shared:r,Treemap:i}}p(X,`createTreemapServices`);var Le=class extends c{static{p(this,`WardleyValueConverter`)}runCustomConverter(e,t,n){switch(e.name.toUpperCase()){case`LINK_LABEL`:return t.substring(1).trim();default:return}}},Z={parser:{ValueConverter:p(()=>new Le,`ValueConverter`)}};function Q(e=l){let r=f(t(e),d),i=f(n({shared:r}),a,Z);return r.ServiceRegistry.register(i),{shared:r,Wardley:i}}p(Q,`createWardleyServices`);var $={},Re={info:p(async()=>{let{createInfoServices:t}=await e(async()=>{let{createInfoServices:e}=await import(`./info-DKCQHKI2-C9VD1Y4e.js`);return{createInfoServices:e}},__vite__mapDeps([0,1]),import.meta.url);$.info=t().Info.parser.LangiumParser},`info`),packet:p(async()=>{let{createPacketServices:t}=await e(async()=>{let{createPacketServices:e}=await import(`./packet-7NZHBO7P-CwQ4NSBs.js`);return{createPacketServices:e}},__vite__mapDeps([2,1]),import.meta.url);$.packet=t().Packet.parser.LangiumParser},`packet`),pie:p(async()=>{let{createPieServices:t}=await e(async()=>{let{createPieServices:e}=await import(`./pie-RZYD4A2V-CJroHMKh.js`);return{createPieServices:e}},__vite__mapDeps([3,1]),import.meta.url);$.pie=t().Pie.parser.LangiumParser},`pie`),treeView:p(async()=>{let{createTreeViewServices:t}=await e(async()=>{let{createTreeViewServices:e}=await import(`./treeView-QDETBFTQ-7CTvIwKq.js`);return{createTreeViewServices:e}},__vite__mapDeps([4,1]),import.meta.url);$.treeView=t().TreeView.parser.LangiumParser},`treeView`),architecture:p(async()=>{let{createArchitectureServices:t}=await e(async()=>{let{createArchitectureServices:e}=await import(`./architecture-TIHT7OUA-BStBTLea.js`);return{createArchitectureServices:e}},__vite__mapDeps([5,1]),import.meta.url);$.architecture=t().Architecture.parser.LangiumParser},`architecture`),gitGraph:p(async()=>{let{createGitGraphServices:t}=await e(async()=>{let{createGitGraphServices:e}=await import(`./gitGraph-TEB2WS4Q-qS77ywA9.js`);return{createGitGraphServices:e}},__vite__mapDeps([6,1]),import.meta.url);$.gitGraph=t().GitGraph.parser.LangiumParser},`gitGraph`),eventmodeling:p(async()=>{let{createEventModelingServices:t}=await e(async()=>{let{createEventModelingServices:e}=await import(`./eventmodeling-45OFAUF4-C1ylhSks.js`);return{createEventModelingServices:e}},__vite__mapDeps([7,1]),import.meta.url);$.eventmodeling=t().EventModel.parser.LangiumParser},`eventmodeling`),radar:p(async()=>{let{createRadarServices:t}=await e(async()=>{let{createRadarServices:e}=await import(`./radar-I7S5WNFK-DdIUwd2d.js`);return{createRadarServices:e}},__vite__mapDeps([8,1]),import.meta.url);$.radar=t().Radar.parser.LangiumParser},`radar`),railroad:p(async()=>{let{createRailroadServices:t}=await e(async()=>{let{createRailroadServices:e}=await import(`./railroad-3IZDKUUU-B1Lw6Xyq.js`);return{createRailroadServices:e}},__vite__mapDeps([9,1]),import.meta.url);$.railroad=t().Railroad.parser.LangiumParser},`railroad`),railroadEbnf:p(async()=>{let{createRailroadEbnfServices:t}=await e(async()=>{let{createRailroadEbnfServices:e}=await import(`./railroad-ebnf-EBAXGLYW-D7qEQ2x8.js`);return{createRailroadEbnfServices:e}},__vite__mapDeps([10,1]),import.meta.url);$.railroadEbnf=t().RailroadEbnf.parser.LangiumParser},`railroadEbnf`),railroadAbnf:p(async()=>{let{createRailroadAbnfServices:t}=await e(async()=>{let{createRailroadAbnfServices:e}=await import(`./railroad-abnf-AHOZXSZD-CQgQoeak.js`);return{createRailroadAbnfServices:e}},__vite__mapDeps([11,1]),import.meta.url);$.railroadAbnf=t().RailroadAbnf.parser.LangiumParser},`railroadAbnf`),railroadPeg:p(async()=>{let{createRailroadPegServices:t}=await e(async()=>{let{createRailroadPegServices:e}=await import(`./railroad-peg-LSFZ7HO6-C005Vxbb.js`);return{createRailroadPegServices:e}},__vite__mapDeps([12,1]),import.meta.url);$.railroadPeg=t().RailroadPeg.parser.LangiumParser},`railroadPeg`),treemap:p(async()=>{let{createTreemapServices:t}=await e(async()=>{let{createTreemapServices:e}=await import(`./treemap-6X3UGDF4-CtL22pq5.js`);return{createTreemapServices:e}},__vite__mapDeps([13,1]),import.meta.url);$.treemap=t().Treemap.parser.LangiumParser},`treemap`),wardley:p(async()=>{let{createWardleyServices:t}=await e(async()=>{let{createWardleyServices:e}=await import(`./wardley-OPB4EBWU-JNi-QNag.js`);return{createWardleyServices:e}},__vite__mapDeps([14,1]),import.meta.url);$.wardley=t().Wardley.parser.LangiumParser},`wardley`),cynefin:p(async()=>{let{createCynefinServices:t}=await e(async()=>{let{createCynefinServices:e}=await import(`./cynefin-VYW2F7L2-BIqktTEv.js`);return{createCynefinServices:e}},__vite__mapDeps([15,1]),import.meta.url);$.cynefin=t().Cynefin.parser.LangiumParser},`cynefin`)};async function ze(e,t){let n=Re[e];if(!n)throw Error(`Unknown diagram type: ${e}`);$[e]||await n();let r=$[e].parse(t);if(r.lexerErrors.length>0||r.parserErrors.length>0)throw new Be(r);return r.value}p(ze,`parse`);var Be=class extends Error{constructor(e){let t=e.lexerErrors.map(e=>`Lexer error on line ${e.line!==void 0&&!isNaN(e.line)?e.line:`?`}, column ${e.column!==void 0&&!isNaN(e.column)?e.column:`?`}: ${e.message}`).join(`
|
|
6
|
+
`),n=e.parserErrors.map(e=>`Parse error on line ${e.token.startLine!==void 0&&!isNaN(e.token.startLine)?e.token.startLine:`?`}, column ${e.token.startColumn!==void 0&&!isNaN(e.token.startColumn)?e.token.startColumn:`?`}: ${e.message}`).join(`
|
|
7
|
+
`);super(`Parsing failed: ${t} ${n}`),this.result=e}static{p(this,`MermaidParseError`)}};export{_ as A,O as C,w as D,D as E,h as M,T as O,j as S,E as T,P as _,Y as a,N as b,q as c,V as d,H as f,we as g,L as h,Q as i,m as j,g as k,W as l,z as m,ze as n,X as o,R as p,Z as r,K as s,Be as t,G as u,F as v,k as w,A as x,M as y};
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{m as t}from"./src-CvxfUak2.js";import{b as n,f as r,it as i,k as a,nt as o,tt as s,x as c,z as l}from"./chunk-I66GZJ75-CulcrLPh.js";import"./chunk-NSK5VX7P-D2nYrCY4.js";import"./chunk-W5SLKNZC-2E6OPhA4.js";import"./chunk-UBXNYLIW-BPEVYsFK.js";import"./chunk-4I5QYGJK-CiIdNwaF.js";import"./chunk-WRU74C26-CBIvOyWp.js";import"./chunk-QR6OTTB3-BrdIzg4Q.js";import"./chunk-7BUUIJ7U-Bb538aSH.js";import{n as u,t as d}from"./uml-C3KAFGTq.js";import{t as f}from"./chunk-XXDRQBXY-pH58XAyl.js";import{t as p}from"./chunk-KBJHAD2P-Wm35lYov.js";var m=[];for(let e=0;e<256;++e)m.push((e+256).toString(16).slice(1));function h(e,t=0){return(m[e[t+0]]+m[e[t+1]]+m[e[t+2]]+m[e[t+3]]+`-`+m[e[t+4]]+m[e[t+5]]+`-`+m[e[t+6]]+m[e[t+7]]+`-`+m[e[t+8]]+m[e[t+9]]+`-`+m[e[t+10]]+m[e[t+11]]+m[e[t+12]]+m[e[t+13]]+m[e[t+14]]+m[e[t+15]]).toLowerCase()}var g=new Uint8Array(16);function _(){return crypto.getRandomValues(g)}function v(e,t,n){return!t&&!e&&crypto.randomUUID?crypto.randomUUID():y(e,t,n)}function y(e,t,n){e||={};let r=e.random??e.rng?.()??_();if(r.length<16)throw Error(`Random bytes length must be >= 16`);if(r[6]=r[6]&15|64,r[8]=r[8]&63|128,t){if(n||=0,n<0||n+16>t.length)throw RangeError(`UUID byte range ${n}:${n+15} is out of buffer bounds`);for(let e=0;e<16;++e)t[n+e]=r[e];return t}return h(r)}var b=(function(){var t=e(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,4],r=[1,13],i=[1,12],a=[1,15],o=[1,16],s=[1,20],c=[1,19],l=[6,7,8],u=[1,26],d=[1,24],f=[1,25],p=[6,7,11],m=[1,6,13,15,16,19,22],h=[1,33],g=[1,34],_=[1,6,7,11,13,15,16,19,22],v={trace:e(function(){},`trace`),yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,MINDMAP:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,ICON:15,CLASS:16,nodeWithId:17,nodeWithoutId:18,NODE_DSTART:19,NODE_DESCR:20,NODE_DEND:21,NODE_ID:22,$accept:0,$end:1},terminals_:{2:`error`,6:`SPACELINE`,7:`NL`,8:`MINDMAP`,11:`EOF`,13:`SPACELIST`,15:`ICON`,16:`CLASS`,19:`NODE_DSTART`,20:`NODE_DESCR`,21:`NODE_DEND`,22:`NODE_ID`},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,2],[12,2],[12,2],[12,1],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[18,3],[17,1],[17,4]],performAction:e(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 6:case 7:return r;case 8:r.getLogger().trace(`Stop NL `);break;case 9:r.getLogger().trace(`Stop EOF `);break;case 11:r.getLogger().trace(`Stop NL2 `);break;case 12:r.getLogger().trace(`Stop EOF2 `);break;case 15:r.getLogger().info(`Node: `,a[s].id),r.addNode(a[s-1].length,a[s].id,a[s].descr,a[s].type);break;case 16:r.getLogger().trace(`Icon: `,a[s]),r.decorateNode({icon:a[s]});break;case 17:case 21:r.decorateNode({class:a[s]});break;case 18:r.getLogger().trace(`SPACELIST`);break;case 19:r.getLogger().trace(`Node: `,a[s].id),r.addNode(0,a[s].id,a[s].descr,a[s].type);break;case 20:r.decorateNode({icon:a[s]});break;case 25:r.getLogger().trace(`node found ..`,a[s-2]),this.$={id:a[s-1],descr:a[s-1],type:r.getType(a[s-2],a[s])};break;case 26:this.$={id:a[s],descr:a[s],type:r.nodeType.DEFAULT};break;case 27:r.getLogger().trace(`node found ..`,a[s-3]),this.$={id:a[s-3],descr:a[s-1],type:r.getType(a[s-2],a[s])}}},`anonymous`),table:[{3:1,4:2,5:3,6:[1,5],8:n},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:n},{6:r,7:[1,10],9:9,12:11,13:i,14:14,15:a,16:o,17:17,18:18,19:s,22:c},t(l,[2,3]),{1:[2,2]},t(l,[2,4]),t(l,[2,5]),{1:[2,6],6:r,12:21,13:i,14:14,15:a,16:o,17:17,18:18,19:s,22:c},{6:r,9:22,12:11,13:i,14:14,15:a,16:o,17:17,18:18,19:s,22:c},{6:u,7:d,10:23,11:f},t(p,[2,22],{17:17,18:18,14:27,15:[1,28],16:[1,29],19:s,22:c}),t(p,[2,18]),t(p,[2,19]),t(p,[2,20]),t(p,[2,21]),t(p,[2,23]),t(p,[2,24]),t(p,[2,26],{19:[1,30]}),{20:[1,31]},{6:u,7:d,10:32,11:f},{1:[2,7],6:r,12:21,13:i,14:14,15:a,16:o,17:17,18:18,19:s,22:c},t(m,[2,14],{7:h,11:g}),t(_,[2,8]),t(_,[2,9]),t(_,[2,10]),t(p,[2,15]),t(p,[2,16]),t(p,[2,17]),{20:[1,35]},{21:[1,36]},t(m,[2,13],{7:h,11:g}),t(_,[2,11]),t(_,[2,12]),{21:[1,37]},t(p,[2,25]),t(p,[2,27])],defaultActions:{2:[2,1],6:[2,2]},parseError:e(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:e(function(t){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(t,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}e(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}e(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`:
|
|
2
|
+
`+h.showPosition()+`
|
|
3
|
+
Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};v.lexer=(function(){return{EOF:1,parseError:e(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:e(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:e(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:e(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);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);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:e(function(){return this._more=!0,this},`more`),reject:e(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else 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).
|
|
4
|
+
`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:e(function(e){this.unput(this.match.slice(e))},`less`),pastInput:e(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:e(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:e(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+`
|
|
5
|
+
`+t+`^`},`showPosition`),test_match:e(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,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(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:e(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;a<i.length;a++)if(n=this._input.match(this.rules[i[a]]),n&&(!t||n[0].length>t[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text.
|
|
6
|
+
`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:e(function(){return this.next()||this.lex()},`lex`),begin:e(function(e){this.conditionStack.push(e)},`begin`),popState:e(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:e(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:e(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:e(function(e){this.begin(e)},`pushState`),stateStackSize:e(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:e(function(e,t,n,r){switch(n){case 0:return e.getLogger().trace(`Found comment`,t.yytext),6;case 1:return 8;case 2:this.begin(`CLASS`);break;case 3:return this.popState(),16;case 4:this.popState();break;case 5:e.getLogger().trace(`Begin icon`),this.begin(`ICON`);break;case 6:return e.getLogger().trace(`SPACELINE`),6;case 7:return 7;case 8:return 15;case 9:e.getLogger().trace(`end icon`),this.popState();break;case 10:return e.getLogger().trace(`Exploding node`),this.begin(`NODE`),19;case 11:return e.getLogger().trace(`Cloud`),this.begin(`NODE`),19;case 12:return e.getLogger().trace(`Explosion Bang`),this.begin(`NODE`),19;case 13:return e.getLogger().trace(`Cloud Bang`),this.begin(`NODE`),19;case 14:return this.begin(`NODE`),19;case 15:return this.begin(`NODE`),19;case 16:return this.begin(`NODE`),19;case 17:return this.begin(`NODE`),19;case 18:return 13;case 19:return 22;case 20:return 11;case 21:this.begin(`NSTR2`);break;case 22:return`NODE_DESCR`;case 23:this.popState();break;case 24:e.getLogger().trace(`Starting NSTR`),this.begin(`NSTR`);break;case 25:return e.getLogger().trace(`description:`,t.yytext),`NODE_DESCR`;case 26:this.popState();break;case 27:return this.popState(),e.getLogger().trace(`node end ))`),`NODE_DEND`;case 28:return this.popState(),e.getLogger().trace(`node end )`),`NODE_DEND`;case 29:return this.popState(),e.getLogger().trace(`node end ...`,t.yytext),`NODE_DEND`;case 30:return this.popState(),e.getLogger().trace(`node end ((`),`NODE_DEND`;case 31:return this.popState(),e.getLogger().trace(`node end (-`),`NODE_DEND`;case 32:return this.popState(),e.getLogger().trace(`node end (-`),`NODE_DEND`;case 33:return this.popState(),e.getLogger().trace(`node end ((`),`NODE_DEND`;case 34:return this.popState(),e.getLogger().trace(`node end ((`),`NODE_DEND`;case 35:return e.getLogger().trace(`Long description:`,t.yytext),20;case 36:return e.getLogger().trace(`Long description:`,t.yytext),20}},`anonymous`),rules:[/^(?:\s*%%.*)/i,/^(?:mindmap\b)/i,/^(?::::)/i,/^(?:.+)/i,/^(?:\n)/i,/^(?:::icon\()/i,/^(?:[\s]+[\n])/i,/^(?:[\n]+)/i,/^(?:[^\)]+)/i,/^(?:\))/i,/^(?:-\))/i,/^(?:\(-)/i,/^(?:\)\))/i,/^(?:\))/i,/^(?:\(\()/i,/^(?:\{\{)/i,/^(?:\()/i,/^(?:\[)/i,/^(?:[\s]+)/i,/^(?:[^\(\[\n\)\{\}]+)/i,/^(?:$)/i,/^(?:["][`])/i,/^(?:[^`"]+)/i,/^(?:[`]["])/i,/^(?:["])/i,/^(?:[^"]+)/i,/^(?:["])/i,/^(?:[\)]\))/i,/^(?:[\)])/i,/^(?:[\]])/i,/^(?:\}\})/i,/^(?:\(-)/i,/^(?:-\))/i,/^(?:\(\()/i,/^(?:\()/i,/^(?:[^\)\]\(\}]+)/i,/^(?:.+(?!\(\())/i],conditions:{CLASS:{rules:[3,4],inclusive:!1},ICON:{rules:[8,9],inclusive:!1},NSTR2:{rules:[22,23],inclusive:!1},NSTR:{rules:[25,26],inclusive:!1},NODE:{rules:[21,24,27,28,29,30,31,32,33,34,35,36],inclusive:!1},INITIAL:{rules:[0,1,2,5,6,7,10,11,12,13,14,15,16,17,18,19,20],inclusive:!0}}}})();function y(){this.yy={}}return e(y,`Parser`),y.prototype=v,v.Parser=y,new y})();b.parser=b;var x=b,S=12,C={DEFAULT:0,NO_BORDER:0,ROUNDED_RECT:1,RECT:2,CIRCLE:3,CLOUD:4,BANG:5,HEXAGON:6},w=class{constructor(){this.nodes=[],this.count=0,this.elements={},this.getLogger=this.getLogger.bind(this),this.nodeType=C,this.clear(),this.getType=this.getType.bind(this),this.getElementById=this.getElementById.bind(this),this.getParent=this.getParent.bind(this),this.getMindmap=this.getMindmap.bind(this),this.addNode=this.addNode.bind(this),this.decorateNode=this.decorateNode.bind(this)}static{e(this,`MindmapDB`)}clear(){this.nodes=[],this.count=0,this.elements={},this.baseLevel=void 0}getParent(e){for(let t=this.nodes.length-1;t>=0;t--)if(this.nodes[t].level<e)return this.nodes[t];return null}getMindmap(){return this.nodes.length>0?this.nodes[0]:null}addNode(e,n,i,a){t.info(`addNode`,e,n,i,a);let o=!1;this.nodes.length===0?(this.baseLevel=e,e=0,o=!0):this.baseLevel!==void 0&&(e-=this.baseLevel,o=!1);let s=c(),u=s.mindmap?.padding??r.mindmap.padding;switch(a){case this.nodeType.ROUNDED_RECT:case this.nodeType.RECT:case this.nodeType.HEXAGON:u*=2}let d={id:this.count++,nodeId:l(n,s),level:e,descr:l(i,s),type:a,children:[],width:s.mindmap?.maxNodeWidth??r.mindmap.maxNodeWidth,padding:u,isRoot:o},f=this.getParent(e);if(f)f.children.push(d),this.nodes.push(d);else if(o)this.nodes.push(d);else throw Error(`There can be only one root. No parent could be found for ("${d.descr}")`)}getType(e,n){switch(t.debug(`In get type`,e,n),e){case`[`:return this.nodeType.RECT;case`(`:return n===`)`?this.nodeType.ROUNDED_RECT:this.nodeType.CLOUD;case`((`:return this.nodeType.CIRCLE;case`)`:return this.nodeType.CLOUD;case`))`:return this.nodeType.BANG;case`{{`:return this.nodeType.HEXAGON;default:return this.nodeType.DEFAULT}}setElementForId(e,t){this.elements[e]=t}getElementById(e){return this.elements[e]}decorateNode(e){if(!e)return;let t=c(),n=this.nodes[this.nodes.length-1];e.icon&&(n.icon=l(e.icon,t)),e.class&&(n.class=l(e.class,t))}type2Str(e){switch(e){case this.nodeType.DEFAULT:return`no-border`;case this.nodeType.RECT:return`rect`;case this.nodeType.ROUNDED_RECT:return`rounded-rect`;case this.nodeType.CIRCLE:return`circle`;case this.nodeType.CLOUD:return`cloud`;case this.nodeType.BANG:return`bang`;case this.nodeType.HEXAGON:return`hexgon`;default:return`no-border`}}assignSections(e,t){if(e.section=e.level===0?void 0:t,e.children)for(let[n,r]of e.children.entries()){let i=e.level===0?n%(S-1):t;this.assignSections(r,i)}}flattenNodes(t,n){let r=c(),i=[`mindmap-node`];t.isRoot===!0?i.push(`section-root`,`section--1`):t.section!==void 0&&i.push(`section-${t.section}`),t.class&&i.push(t.class);let a=i.join(` `),o=e(e=>{let t=(r.theme?.toLowerCase()??``).includes(`redux`);switch(e){case C.CIRCLE:return`mindmapCircle`;case C.RECT:return`rect`;case C.ROUNDED_RECT:return`rounded`;case C.CLOUD:return`cloud`;case C.BANG:return`bang`;case C.HEXAGON:return`hexagon`;case C.DEFAULT:return t?`rounded`:`defaultMindmapNode`;case C.NO_BORDER:default:return`rect`}},`getShapeFromType`),s={id:t.id.toString(),domId:`node_`+t.id.toString(),label:t.descr,labelType:`markdown`,isGroup:!1,shape:o(t.type),width:t.width,height:t.height??0,padding:t.padding,cssClasses:a,cssStyles:[],look:r.look,icon:t.icon,x:t.x,y:t.y,level:t.level,nodeId:t.nodeId,type:t.type,section:t.section};if(n.push(s),t.children)for(let e of t.children)this.flattenNodes(e,n)}generateEdges(e,t){if(!e.children)return;let n=c();for(let r of e.children){let i=`edge`;r.section!==void 0&&(i+=` section-edge-${r.section}`);let a=e.level+1;i+=` edge-depth-${a}`;let o={id:`edge_${e.id}_${r.id}`,start:e.id.toString(),end:r.id.toString(),type:`normal`,curve:`basis`,thickness:`normal`,look:n.look,classes:i,depth:e.level,section:r.section};t.push(o),this.generateEdges(r,t)}}getData(){let e=this.getMindmap(),n=c(),r=a().layout!==void 0,i=n;if(r||(i.layout=`cose-bilkent`),!e)return{nodes:[],edges:[],config:i};t.debug(`getData: mindmapRoot`,e,n),this.assignSections(e);let o=[],s=[];this.flattenNodes(e,o),this.generateEdges(e,s),t.debug(`getData: processed ${o.length} nodes and ${s.length} edges`);let l=new Map;for(let e of o)l.set(e.id,{shape:e.shape,width:e.width,height:e.height,padding:e.padding});return{nodes:o,edges:s,config:i,rootNode:e,markers:[`point`],direction:`TB`,nodeSpacing:50,rankSpacing:50,shapes:Object.fromEntries(l),type:`mindmap`,diagramId:`mindmap-`+v()}}getLogger(){return t}},T={draw:e(async(e,i,a,o)=>{t.debug(`Rendering mindmap diagram
|
|
7
|
+
`+e);let s=o.db,c=s.getData(),l=f(i,c.config.securityLevel);if(c.type=o.type,c.layoutAlgorithm=d(c.config.layout,{fallback:`cose-bilkent`}),c.diagramId=i,!s.getMindmap())return;c.nodes.forEach(e=>{e.shape===`rounded`?(e.radius=15,e.taper=15,e.stroke=`none`,e.width=0,e.padding=15):e.shape===`circle`?e.padding=10:e.shape===`rect`?(e.width=0,e.padding=10):e.shape===`hexagon`&&(e.width=0,e.height=0)}),await u(c,l);let{themeVariables:m}=n(),{useGradient:h,gradientStart:g,gradientStop:_}=m;if(h&&g&&_){let e=l.attr(`id`),t=l.append(`defs`).append(`linearGradient`).attr(`id`,`${e}-gradient`).attr(`gradientUnits`,`objectBoundingBox`).attr(`x1`,`0%`).attr(`y1`,`0%`).attr(`x2`,`100%`).attr(`y2`,`0%`);t.append(`stop`).attr(`offset`,`0%`).attr(`stop-color`,g).attr(`stop-opacity`,1),t.append(`stop`).attr(`offset`,`100%`).attr(`stop-color`,_).attr(`stop-opacity`,1)}p(l,c.config.mindmap?.padding??r.mindmap.padding,`mindmapDiagram`,c.config.mindmap?.useMaxWidth??r.mindmap.useMaxWidth)},`draw`)},E=e(e=>{let{theme:t,look:n}=e,r=``;for(let t=0;t<e.THEME_COLOR_LIMIT;t++)e[`lineColor`+t]=e[`lineColor`+t]||e[`cScaleInv`+t],i(e[`lineColor`+t])?e[`lineColor`+t]=o(e[`lineColor`+t],20):e[`lineColor`+t]=s(e[`lineColor`+t],20);for(let i=0;i<e.THEME_COLOR_LIMIT;i++){let a=``+(n===`neo`?Math.max(10-(i-1)*2,2):17-3*i);r+=`
|
|
8
|
+
.section-${i-1} rect, .section-${i-1} path, .section-${i-1} circle, .section-${i-1} polygon, .section-${i-1} path {
|
|
9
|
+
fill: ${e[`cScale`+i]};
|
|
10
|
+
}
|
|
11
|
+
.section-${i-1} text {
|
|
12
|
+
fill: ${e[`cScaleLabel`+i]};
|
|
13
|
+
}
|
|
14
|
+
.section-${i-1} span {
|
|
15
|
+
color: ${e[`cScaleLabel`+i]};
|
|
16
|
+
}
|
|
17
|
+
.node-icon-${i-1} {
|
|
18
|
+
font-size: 40px;
|
|
19
|
+
color: ${e[`cScaleLabel`+i]};
|
|
20
|
+
}
|
|
21
|
+
.section-edge-${i-1}{
|
|
22
|
+
stroke: ${e[`cScale`+i]};
|
|
23
|
+
}
|
|
24
|
+
.edge-depth-${i-1}{
|
|
25
|
+
stroke-width: ${a};
|
|
26
|
+
}
|
|
27
|
+
.section-${i-1} line {
|
|
28
|
+
stroke: ${e[`cScaleInv`+i]} ;
|
|
29
|
+
stroke-width: 3;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.disabled, .disabled circle, .disabled text {
|
|
33
|
+
fill: lightgray;
|
|
34
|
+
}
|
|
35
|
+
.disabled text {
|
|
36
|
+
fill: #efefef;
|
|
37
|
+
}
|
|
38
|
+
[data-look="neo"].mindmap-node.section-${i-1} rect, [data-look="neo"].mindmap-node.section-${i-1} path, [data-look="neo"].mindmap-node.section-${i-1} circle, [data-look="neo"].mindmap-node.section-${i-1} polygon {
|
|
39
|
+
fill: ${t===`redux`||t===`redux-dark`||t===`neutral`?e.mainBkg:e[`cScale`+i]};
|
|
40
|
+
stroke: ${t===`redux`||t===`redux-dark`?e.nodeBorder:e[`cScale`+i]};
|
|
41
|
+
stroke-width: ${e.strokeWidth??2}px;
|
|
42
|
+
}
|
|
43
|
+
[data-look="neo"].section-edge-${i-1}{
|
|
44
|
+
stroke: ${t?.includes(`redux`)||t===`neo-dark`?e.nodeBorder:e[`cScale`+i]};
|
|
45
|
+
}
|
|
46
|
+
[data-look="neo"].mindmap-node.section-${i-1} text {
|
|
47
|
+
fill: ${t===`redux`||t===`redux-dark`?e.nodeBorder:e[`cScaleLabel`+(t===`neutral`?1:i)]};
|
|
48
|
+
}
|
|
49
|
+
`}return r},`genSections`),D=e((e,t,n)=>{let r=``;for(let i=0;i<e;i++)r+=`
|
|
50
|
+
[data-look="neo"].mindmap-node.section-${i-1} rect, [data-look="neo"].mindmap-node.section-${i-1} path, [data-look="neo"].mindmap-node.section-${i-1} circle, [data-look="neo"].mindmap-node.section-${i-1} polygon {
|
|
51
|
+
stroke: url(${t}-gradient);
|
|
52
|
+
fill: ${n};
|
|
53
|
+
}
|
|
54
|
+
.section-${i-1} line {
|
|
55
|
+
stroke-width: 0;
|
|
56
|
+
}`;return r},`genGradient`),O={get db(){return new w},renderer:T,parser:x,styles:e(e=>{let{theme:t}=e,n=e.svgId,r=e.dropShadow?e.dropShadow.replace(`url(#drop-shadow)`,`url(${n}-drop-shadow)`):`none`;return`
|
|
57
|
+
.edge {
|
|
58
|
+
stroke-width: 3;
|
|
59
|
+
}
|
|
60
|
+
${E(e)}
|
|
61
|
+
.section-root rect, .section-root path, .section-root circle, .section-root polygon {
|
|
62
|
+
fill: ${e.git0};
|
|
63
|
+
}
|
|
64
|
+
.section-root text {
|
|
65
|
+
fill: ${e.gitBranchLabel0};
|
|
66
|
+
}
|
|
67
|
+
.section-root span {
|
|
68
|
+
color: ${t?.includes(`redux`)?e.nodeBorder:e.gitBranchLabel0};
|
|
69
|
+
}
|
|
70
|
+
.icon-container {
|
|
71
|
+
height:100%;
|
|
72
|
+
display: flex;
|
|
73
|
+
justify-content: center;
|
|
74
|
+
align-items: center;
|
|
75
|
+
}
|
|
76
|
+
.edge {
|
|
77
|
+
fill: none;
|
|
78
|
+
}
|
|
79
|
+
.mindmap-node-label {
|
|
80
|
+
dy: 1em;
|
|
81
|
+
alignment-baseline: middle;
|
|
82
|
+
text-anchor: middle;
|
|
83
|
+
dominant-baseline: middle;
|
|
84
|
+
text-align: center;
|
|
85
|
+
}
|
|
86
|
+
[data-look="neo"].mindmap-node {
|
|
87
|
+
filter: ${r};
|
|
88
|
+
}
|
|
89
|
+
[data-look="neo"].mindmap-node.section-root rect, [data-look="neo"].mindmap-node.section-root path, [data-look="neo"].mindmap-node.section-root circle, [data-look="neo"].mindmap-node.section-root polygon {
|
|
90
|
+
fill: ${t?.includes(`redux`)?e.mainBkg:e.git0};
|
|
91
|
+
}
|
|
92
|
+
[data-look="neo"].mindmap-node.section-root .text-inner-tspan {
|
|
93
|
+
fill: ${t?.includes(`redux`)?e.nodeBorder:e[`cScaleLabel`+ +(t===`neutral`)]};
|
|
94
|
+
}
|
|
95
|
+
${e.useGradient&&n&&e.mainBkg?D(e.THEME_COLOR_LIMIT,n,e.mainBkg):``}
|
|
96
|
+
`},`getStyles`)};export{O as diagram};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
body{overflow:auto}.modeler-app{background:radial-gradient(circle at 80% -20%, #183253 0, transparent 35%), var(--mxrb-bg);color:#eaf1fa;min-height:100vh}.topbar{z-index:10;-webkit-backdrop-filter:blur(18px);backdrop-filter:blur(18px);background:#0a1019f0;border-bottom:1px solid #26364b;align-items:center;gap:28px;height:64px;padding:0 24px;display:flex;position:fixed;inset:0 0 auto}.brand{min-width:220px;color:inherit;align-items:center;gap:11px;text-decoration:none;display:flex}.brand>span{background:linear-gradient(145deg,#4e9cff,#7069ff);border-radius:9px;place-items:center;width:32px;height:32px;font-size:11px;font-weight:900;display:grid;box-shadow:0 8px 24px #315f9e55}.brand strong{letter-spacing:.02em;font-size:15px}.project-identity{flex:1;align-items:baseline;gap:10px;display:flex}.project-identity strong{font-size:14px}.project-identity span,.topbar nav a{color:var(--mxrb-muted);font-size:12px}.topbar nav{gap:18px;display:flex}.topbar nav a{text-decoration:none}.topbar nav a:hover{color:#fff}.sidebar{background:#0d1520db;border-right:1px solid #26364b;width:244px;padding:25px 16px;position:fixed;inset:64px auto 0 0}.sidebar>p{color:#68788e;letter-spacing:.14em;text-transform:uppercase;margin:0 12px 12px;font-size:10px;font-weight:800}.sidebar button{color:#9dacbf;cursor:pointer;text-align:left;background:0 0;border:1px solid #0000;border-radius:8px;align-items:center;gap:12px;width:100%;margin:3px 0;padding:10px 12px;font-size:13px;display:flex}.sidebar button span{color:#708299;text-align:center;width:18px}.sidebar button:hover{color:#eaf1fa;background:#172233}.sidebar button.active{color:#80baff;background:#19314c;border-color:#315b8a}.sidebar-footer{color:#708299;flex-direction:column;gap:4px;font-size:11px;display:flex;position:absolute;inset:auto 20px 24px}.sidebar-footer small{color:#536174}.modeler-main{min-height:100vh;margin-left:244px;padding:96px 34px 40px}.workspace-header{justify-content:space-between;align-items:end;gap:24px;margin-bottom:24px;display:flex}.workspace-header p,.section-heading p{color:#6e8098;letter-spacing:.13em;text-transform:uppercase;margin:0 0 5px;font-size:10px;font-weight:800}.workspace-header h1{letter-spacing:-.03em;margin:0;font-size:26px}.workspace-tools{gap:10px;display:flex}.workspace-tools input,.workspace-tools select{color:#dce7f5;background:#101927;border:1px solid #2a3b52;border-radius:8px;height:38px;padding:0 12px}.workspace-tools input{width:min(280px,30vw)}.workspace-tools select{min-width:155px}.metric-grid{grid-template-columns:repeat(4,minmax(120px,1fr));gap:12px;margin-bottom:18px;display:grid}.metric-card,.surface-card,.catalog-card{background:linear-gradient(145deg,#182435eb,#0f1825f0);border:1px solid #25364b;box-shadow:0 16px 42px #03070d33}.metric-card{border-radius:10px;padding:18px}.metric-card strong{color:#f4f8fe;margin-bottom:6px;font-size:24px;display:block}.metric-card span{color:#7f90a7;text-transform:capitalize;font-size:11px}.surface-card{border-radius:11px;padding:20px}.section-heading{justify-content:space-between;align-items:center;margin-bottom:17px;display:flex}.section-heading h2{margin:0;font-size:16px}.section-heading>span{color:#71839b;font-size:11px}.module-grid{grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:11px;display:grid}.module-card{background:#111b29;border:1px solid #283a50;border-radius:8px;padding:15px}.module-pill{color:#dce8f7;align-items:center;gap:7px;font-size:12px;font-weight:700;display:inline-flex}.module-pill small{color:#d1a7ff;font-size:9px;font-weight:600}.module-dot{background:#5ca9ff;border-radius:2px;width:7px;height:7px;box-shadow:0 0 12px #5ca9ff99}.module-card dl{grid-template-columns:1fr 1fr;gap:9px;margin:15px 0 0;display:grid}.module-card dl div{color:#71839a;justify-content:space-between;font-size:11px;display:flex}.module-card dd{color:#c8d5e5;margin:0}.catalog-list{grid-template-columns:repeat(auto-fit,minmax(285px,1fr));gap:12px;display:grid}.catalog-card{border-radius:10px;min-height:175px;padding:17px}.card-title{justify-content:space-between;align-items:center;gap:12px;display:flex}.kind{color:#82b9f4;letter-spacing:.07em;text-transform:uppercase;border:1px solid #34506e;border-radius:5px;padding:4px 7px;font-size:9px;font-weight:800}.kind.nanoflow{color:#b5adff;border-color:#4c4879}.catalog-card h3{margin:20px 0 5px;font-size:16px}.catalog-card>p{color:#788aa1;min-height:17px;margin:0 0 14px;font-size:11px}.card-facts{color:#9badc3;flex-wrap:wrap;gap:8px 15px;margin:0 0 15px;font-size:10px;display:flex}.tags{flex-wrap:wrap;gap:5px;display:inline-flex}.tags>span{color:#aebfd3;background:#243247;border-radius:4px;padding:3px 6px;font-size:9px}.muted{color:#66778d;font-size:10px}.navigation-tree{color:#9aabc0;padding-left:18px;font-size:11px}.navigation-tree li{padding:3px 0}.two-column{grid-template-columns:1fr 1fr;gap:14px;display:grid}.role-row{border-top:1px solid #233247;justify-content:space-between;align-items:start;gap:18px;padding:12px 0;display:flex}.role-row strong{font-size:12px}.role-row p{color:#718299;margin:4px 0 0;font-size:10px}.settings-stack{gap:14px;display:grid}.settings-grid{background:#28384c;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:1px;margin:0;display:grid}.settings-grid div{background:#121d2c;padding:11px}.settings-grid dt{color:#718299;text-transform:uppercase;font-size:9px}.settings-grid dd{word-break:break-word;margin:5px 0 0;font-size:11px}.empty-state,.load-screen{color:#73859b;place-items:center;min-height:260px;font-size:12px;display:grid}.load-screen{align-content:center;gap:12px;min-height:100vh}.load-screen.error strong{color:#ff8995}.spinner{border:2px solid #30435c;border-top-color:#66adff;border-radius:50%;width:24px;height:24px;animation:.8s linear infinite spin}@keyframes spin{to{transform:rotate(360deg)}}@media (width<=900px){.topbar nav{display:none}.sidebar{width:76px}.sidebar>p,.sidebar button:not(.active){font-size:0}.sidebar button{justify-content:center}.sidebar button.active{font-size:0}.sidebar-footer{display:none}.modeler-main{margin-left:76px;padding-inline:20px}.metric-grid{grid-template-columns:repeat(2,1fr)}.two-column{grid-template-columns:1fr}}@media (width<=620px){.project-identity{display:none}.workspace-header{flex-direction:column;align-items:stretch}.workspace-tools{flex-direction:column}.workspace-tools input{width:100%}.catalog-list,.module-grid{grid-template-columns:1fr}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{i as e,n as t,r as n,t as r}from"./jsx-runtime-DV0a5kSb.js";/* empty css */var i=e(),a=n();function o(e){return t(`./api/project`,{signal:e})}function s(e){return e instanceof Error?e.message:String(e)}function c(e,t){return e.toLocaleLowerCase().includes(t.trim().toLocaleLowerCase())}function l(e){return e.split(`$`).at(-1)?.replaceAll(/([a-z])([A-Z])/g,`$1 $2`)??e}var u=r(),d=[{id:`overview`,label:`Overview`,glyph:`⌂`},{id:`pages`,label:`Pages`,glyph:`▤`},{id:`logic`,label:`Logic`,glyph:`◇`},{id:`navigation`,label:`Navigation`,glyph:`↗`},{id:`security`,label:`Security`,glyph:`◈`},{id:`integrations`,label:`Integrations`,glyph:`⇄`},{id:`settings`,label:`Settings`,glyph:`⚙`}];function f(e){return e===`microflows`?`Microflows`:e===`nanoflows`?`Nanoflows`:l(e)}function p({children:e}){return(0,u.jsx)(`div`,{className:`empty-state`,children:e})}function m({values:e}){return e.length===0?(0,u.jsx)(`span`,{className:`muted`,children:`No restrictions`}):(0,u.jsx)(`span`,{className:`tags`,children:e.map(e=>(0,u.jsx)(`span`,{children:e},e))})}function h({module:e}){return(0,u.jsxs)(`span`,{className:`module-pill`,children:[(0,u.jsx)(`span`,{className:`module-dot`}),e.name,e.marketplace&&(0,u.jsx)(`small`,{children:`Marketplace`})]})}function g({catalog:e}){let t=Object.entries(e.summary);return(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(`section`,{className:`metric-grid`,children:t.map(([e,t])=>(0,u.jsxs)(`article`,{className:`metric-card`,children:[(0,u.jsx)(`strong`,{children:t}),(0,u.jsx)(`span`,{children:f(e)})]},e))}),(0,u.jsxs)(`section`,{className:`surface-card`,children:[(0,u.jsxs)(`div`,{className:`section-heading`,children:[(0,u.jsxs)(`div`,{children:[(0,u.jsx)(`p`,{children:`Application structure`}),(0,u.jsx)(`h2`,{children:`Modules`})]}),(0,u.jsxs)(`span`,{children:[e.modules.length,` loaded`]})]}),(0,u.jsx)(`div`,{className:`module-grid`,children:e.modules.map(e=>(0,u.jsxs)(`article`,{className:`module-card`,children:[(0,u.jsx)(h,{module:e}),(0,u.jsxs)(`dl`,{children:[(0,u.jsxs)(`div`,{children:[(0,u.jsx)(`dt`,{children:`Entities`}),(0,u.jsx)(`dd`,{children:e.entities.length})]}),(0,u.jsxs)(`div`,{children:[(0,u.jsx)(`dt`,{children:`Pages`}),(0,u.jsx)(`dd`,{children:e.pages.length})]}),(0,u.jsxs)(`div`,{children:[(0,u.jsx)(`dt`,{children:`Logic`}),(0,u.jsx)(`dd`,{children:e.microflows.length+e.nanoflows.length})]}),(0,u.jsxs)(`div`,{children:[(0,u.jsx)(`dt`,{children:`Roles`}),(0,u.jsx)(`dd`,{children:e.module_roles.length})]})]})]},e.id))})]})]})}function _({modules:e,search:t}){let n=e.flatMap(e=>e.pages.map(t=>({module:e,page:t}))).filter(({page:e})=>c(`${e.qualified_name} ${e.title} ${e.url}`,t));return n.length===0?(0,u.jsx)(p,{children:`No pages match the current scope.`}):(0,u.jsx)(`div`,{className:`catalog-list`,children:n.map(({module:e,page:t})=>(0,u.jsx)(v,{module:e,page:t},t.id))})}function v({module:e,page:t}){return(0,u.jsxs)(`article`,{className:`catalog-card`,children:[(0,u.jsxs)(`div`,{className:`card-title`,children:[(0,u.jsx)(h,{module:e}),(0,u.jsx)(`span`,{className:`kind`,children:`Page`})]}),(0,u.jsx)(`h3`,{children:t.name}),(0,u.jsx)(`p`,{children:t.title||`Untitled page`}),(0,u.jsxs)(`div`,{className:`card-facts`,children:[(0,u.jsxs)(`span`,{children:[t.widget_count,` widgets`]}),(0,u.jsxs)(`span`,{children:[Object.keys(t.widget_types).length,` widget types`]}),(0,u.jsx)(`span`,{children:t.url||`No URL`})]}),(0,u.jsx)(m,{values:t.allowed_module_roles})]})}function y({modules:e,search:t}){let n=e.flatMap(e=>[...e.microflows,...e.nanoflows].map(t=>({module:e,flow:t}))).filter(({flow:e})=>c(`${e.qualified_name} ${e.documentation}`,t));return n.length===0?(0,u.jsx)(p,{children:`No flows match the current scope.`}):(0,u.jsx)(`div`,{className:`catalog-list`,children:n.map(({module:e,flow:t})=>(0,u.jsx)(b,{module:e,flow:t},`${t.kind}-${t.id}`))})}function b({module:e,flow:t}){return(0,u.jsxs)(`article`,{className:`catalog-card`,children:[(0,u.jsxs)(`div`,{className:`card-title`,children:[(0,u.jsx)(h,{module:e}),(0,u.jsx)(`span`,{className:`kind ${t.kind}`,children:t.kind})]}),(0,u.jsx)(`h3`,{children:t.name}),(0,u.jsx)(`p`,{children:t.documentation||`No documentation`}),(0,u.jsxs)(`div`,{className:`card-facts`,children:[(0,u.jsxs)(`span`,{children:[t.parameter_count,` parameters`]}),(0,u.jsxs)(`span`,{children:[t.object_count,` objects`]}),(0,u.jsxs)(`span`,{children:[t.flow_count,` edges`]})]}),(0,u.jsx)(m,{values:t.allowed_module_roles})]})}function x({catalog:e}){return e.navigation.profiles.length===0?(0,u.jsx)(p,{children:`No navigation profiles were found.`}):(0,u.jsx)(`div`,{className:`catalog-list`,children:e.navigation.profiles.map(e=>(0,u.jsxs)(`article`,{className:`catalog-card navigation-card`,children:[(0,u.jsx)(`div`,{className:`card-title`,children:(0,u.jsx)(`span`,{className:`kind`,children:e.offline?`Offline`:`Online`})}),(0,u.jsx)(`h3`,{children:e.name||e.kind||`Navigation profile`}),(0,u.jsx)(`div`,{className:`card-facts`,children:(0,u.jsxs)(`span`,{children:[`Home: `,e.home_page||e.home_microflow||`not set`]})}),(0,u.jsx)(S,{items:e.items})]},`${e.kind}-${e.name}`))})}function S({items:e}){return e.length===0?(0,u.jsx)(`p`,{className:`muted`,children:`No menu items`}):(0,u.jsx)(`ul`,{className:`navigation-tree`,children:e.map((e,t)=>(0,u.jsxs)(`li`,{children:[(0,u.jsx)(`span`,{children:Object.values(e.caption??{})[0]||e.page||e.microflow||`Menu item`}),e.items&&(0,u.jsx)(S,{items:e.items})]},`${e.page||e.microflow||`item`}-${t}`))})}function C({catalog:e,modules:t}){return(0,u.jsxs)(`div`,{className:`two-column`,children:[(0,u.jsxs)(`section`,{className:`surface-card`,children:[(0,u.jsx)(`div`,{className:`section-heading`,children:(0,u.jsxs)(`div`,{children:[(0,u.jsx)(`p`,{children:`Project policy`}),(0,u.jsx)(`h2`,{children:e.security.level||`Not configured`})]})}),e.security.user_roles.length===0?(0,u.jsx)(p,{children:`No project user roles were found.`}):e.security.user_roles.map(e=>(0,u.jsxs)(`article`,{className:`role-row`,children:[(0,u.jsxs)(`div`,{children:[(0,u.jsx)(`strong`,{children:e.name}),(0,u.jsx)(`p`,{children:e.description||`No description`})]}),(0,u.jsx)(m,{values:e.module_roles})]},e.name))]}),(0,u.jsxs)(`section`,{className:`surface-card`,children:[(0,u.jsx)(`div`,{className:`section-heading`,children:(0,u.jsxs)(`div`,{children:[(0,u.jsx)(`p`,{children:`Module policy`}),(0,u.jsx)(`h2`,{children:`Module roles`})]})}),t.flatMap(e=>e.module_roles.map(t=>({module:e,role:t}))).map(({module:e,role:t})=>(0,u.jsx)(`article`,{className:`role-row`,children:(0,u.jsxs)(`div`,{children:[(0,u.jsxs)(`strong`,{children:[e.name,`.`,t.name]}),(0,u.jsx)(`p`,{children:t.description||`No description`})]})},`${e.id}-${t.name}`))]})]})}function w({modules:e,search:t,configuration:n=!1}){let r=e.flatMap(e=>(n?e.configurations:e.integrations).map(t=>({module:e,document:t}))).filter(({document:e})=>c(`${e.name} ${e.type} ${e.group}`,t));return r.length===0?(0,u.jsx)(p,{children:`No matching model documents were found.`}):(0,u.jsx)(`div`,{className:`catalog-list`,children:r.map(({module:e,document:t})=>(0,u.jsx)(T,{module:e,document:t},t.id))})}function T({module:e,document:t}){return(0,u.jsxs)(`article`,{className:`catalog-card`,children:[(0,u.jsxs)(`div`,{className:`card-title`,children:[(0,u.jsx)(h,{module:e}),(0,u.jsx)(`span`,{className:`kind`,children:t.group})]}),(0,u.jsx)(`h3`,{children:t.name}),(0,u.jsx)(`p`,{children:l(t.type)})]})}function E({catalog:e,modules:t,search:n}){return(0,u.jsxs)(`div`,{className:`settings-stack`,children:[(0,u.jsx)(w,{modules:t,search:n,configuration:!0}),e.settings.map(e=>(0,u.jsxs)(`section`,{className:`surface-card`,children:[(0,u.jsx)(`div`,{className:`section-heading`,children:(0,u.jsxs)(`div`,{children:[(0,u.jsx)(`p`,{children:l(e.type)}),(0,u.jsx)(`h2`,{children:e.name||`Project settings`})]})}),(0,u.jsx)(`dl`,{className:`settings-grid`,children:Object.entries(e.values).map(([e,t])=>(0,u.jsxs)(`div`,{children:[(0,u.jsx)(`dt`,{children:l(e)}),(0,u.jsx)(`dd`,{children:String(t)})]},e))})]},e.id))]})}function D(){let[e,t]=(0,i.useState)(null),[n,r]=(0,i.useState)(`overview`),[a,c]=(0,i.useState)(`all`),[l,f]=(0,i.useState)(``),[p,m]=(0,i.useState)(null);(0,i.useEffect)(()=>{let e=new AbortController;return o(e.signal).then(t).catch(t=>{e.signal.aborted||m(s(t))}),()=>e.abort()},[]);let h=(0,i.useMemo)(()=>e?.modules.filter(e=>a===`all`||e.name===a)??[],[e,a]);if(p)return(0,u.jsxs)(`main`,{className:`load-screen error`,children:[(0,u.jsx)(`strong`,{children:`Project modeler unavailable`}),(0,u.jsx)(`span`,{children:p})]});if(!e)return(0,u.jsxs)(`main`,{className:`load-screen`,children:[(0,u.jsx)(`span`,{className:`spinner`}),`Loading Mendix project…`]});let v=d.find(e=>e.id===n)?.label??n;return(0,u.jsxs)(`div`,{className:`modeler-app`,children:[(0,u.jsxs)(`header`,{className:`topbar`,children:[(0,u.jsxs)(`a`,{className:`brand`,href:`./modeler`,children:[(0,u.jsx)(`span`,{children:`MX`}),(0,u.jsx)(`strong`,{children:`MXRB Modeler`})]}),(0,u.jsxs)(`div`,{className:`project-identity`,children:[(0,u.jsx)(`strong`,{children:e.project.name}),(0,u.jsxs)(`span`,{children:[`Mendix `,e.project.mendix_version]})]}),(0,u.jsxs)(`nav`,{children:[(0,u.jsx)(`a`,{href:`./`,children:`UML diagrams`}),(0,u.jsx)(`a`,{href:`http://127.0.0.1:4568/`,children:`Domain editor`})]})]}),(0,u.jsxs)(`aside`,{className:`sidebar`,children:[(0,u.jsx)(`p`,{children:`Workspace`}),d.map(e=>(0,u.jsxs)(`button`,{className:n===e.id?`active`:``,onClick:()=>r(e.id),children:[(0,u.jsx)(`span`,{children:e.glyph}),e.label]},e.id)),(0,u.jsxs)(`div`,{className:`sidebar-footer`,children:[(0,u.jsx)(`span`,{children:`Read-only projection`}),(0,u.jsx)(`small`,{children:`Ruby backend · React TypeScript`})]})]}),(0,u.jsxs)(`main`,{className:`modeler-main`,children:[(0,u.jsxs)(`div`,{className:`workspace-header`,children:[(0,u.jsxs)(`div`,{children:[(0,u.jsx)(`p`,{children:`Project model`}),(0,u.jsx)(`h1`,{children:v})]}),(0,u.jsxs)(`div`,{className:`workspace-tools`,children:[(0,u.jsx)(`input`,{"aria-label":`Search artifacts`,onChange:e=>f(e.target.value),placeholder:`Search model…`,value:l}),(0,u.jsxs)(`select`,{"aria-label":`Filter module`,onChange:e=>c(e.target.value),value:a,children:[(0,u.jsx)(`option`,{value:`all`,children:`All modules`}),e.modules.map(e=>(0,u.jsx)(`option`,{value:e.name,children:e.name},e.id))]})]})]}),n===`overview`&&(0,u.jsx)(g,{catalog:{...e,modules:h}}),n===`pages`&&(0,u.jsx)(_,{modules:h,search:l}),n===`logic`&&(0,u.jsx)(y,{modules:h,search:l}),n===`navigation`&&(0,u.jsx)(x,{catalog:e}),n===`security`&&(0,u.jsx)(C,{catalog:e,modules:h}),n===`integrations`&&(0,u.jsx)(w,{modules:h,search:l}),n===`settings`&&(0,u.jsx)(E,{catalog:e,modules:h,search:l})]})]})}var O=document.getElementById(`root`);if(!O)throw Error(`MXRB modeler root element is missing`);(0,a.createRoot)(O).render((0,u.jsx)(i.StrictMode,{children:(0,u.jsx)(D,{})}));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{t as e}from"./init-C-OQMol4.js";var t=class extends Map{constructor(e,t=a){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:t}}),e!=null)for(let[t,n]of e)this.set(t,n)}get(e){return super.get(n(this,e))}has(e){return super.has(n(this,e))}set(e,t){return super.set(r(this,e),t)}delete(e){return super.delete(i(this,e))}};function n({_intern:e,_key:t},n){let r=t(n);return e.has(r)?e.get(r):n}function r({_intern:e,_key:t},n){let r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function i({_intern:e,_key:t},n){let r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function a(e){return typeof e==`object`&&e?e.valueOf():e}var o=Symbol(`implicit`);function s(){var n=new t,r=[],i=[],a=o;function c(e){let t=n.get(e);if(t===void 0){if(a!==o)return a;n.set(e,t=r.push(e)-1)}return i[t%i.length]}return c.domain=function(e){if(!arguments.length)return r.slice();r=[],n=new t;for(let t of e)n.has(t)||n.set(t,r.push(t)-1);return c},c.range=function(e){return arguments.length?(i=Array.from(e),c):i.slice()},c.unknown=function(e){return arguments.length?(a=e,c):a},c.copy=function(){return s(r,i).unknown(a)},e.apply(c,arguments),c}export{s as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./chunk-KEIR6QF5-BICK3FdT.js";import{S as e}from"./mermaid-parser.core-B_UPzTxa.js";export{e as createPacketServices};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var e=Math.PI,t=2*e,n=1e-6,r=t-n;function i(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function a(e){let t=Math.floor(e);if(!(t>=0))throw Error(`invalid digits: ${e}`);if(t>15)return i;let n=10**t;return function(e){this._+=e[0];for(let t=1,r=e.length;t<r;++t)this._+=Math.round(arguments[t]*n)/n+e[t]}}var o=class{constructor(e){this._x0=this._y0=this._x1=this._y1=null,this._=``,this._append=e==null?i:a(e)}moveTo(e,t){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+t}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(e,t){this._append`L${this._x1=+e},${this._y1=+t}`}quadraticCurveTo(e,t,n,r){this._append`Q${+e},${+t},${this._x1=+n},${this._y1=+r}`}bezierCurveTo(e,t,n,r,i,a){this._append`C${+e},${+t},${+n},${+r},${this._x1=+i},${this._y1=+a}`}arcTo(t,r,i,a,o){if(t=+t,r=+r,i=+i,a=+a,o=+o,o<0)throw Error(`negative radius: ${o}`);let s=this._x1,c=this._y1,l=i-t,u=a-r,d=s-t,f=c-r,p=d*d+f*f;if(this._x1===null)this._append`M${this._x1=t},${this._y1=r}`;else if(p>n){if(!(Math.abs(f*l-u*d)>n)||!o)this._append`L${this._x1=t},${this._y1=r}`;else{let m=i-s,h=a-c,g=l*l+u*u,_=m*m+h*h,v=Math.sqrt(g),y=Math.sqrt(p),b=o*Math.tan((e-Math.acos((g+p-_)/(2*v*y)))/2),x=b/y,S=b/v;Math.abs(x-1)>n&&this._append`L${t+x*d},${r+x*f}`,this._append`A${o},${o},0,0,${+(f*m>d*h)},${this._x1=t+S*l},${this._y1=r+S*u}`}}}arc(i,a,o,s,c,l){if(i=+i,a=+a,o=+o,l=!!l,o<0)throw Error(`negative radius: ${o}`);let u=o*Math.cos(s),d=o*Math.sin(s),f=i+u,p=a+d,m=1^l,h=l?s-c:c-s;this._x1===null?this._append`M${f},${p}`:(Math.abs(this._x1-f)>n||Math.abs(this._y1-p)>n)&&this._append`L${f},${p}`,o&&(h<0&&(h=h%t+t),h>r?this._append`A${o},${o},0,1,${m},${i-u},${a-d}A${o},${o},0,1,${m},${this._x1=f},${this._y1=p}`:h>n&&this._append`A${o},${o},0,${+(h>=e)},${m},${this._x1=i+o*Math.cos(c)},${this._y1=a+o*Math.sin(c)}`)}rect(e,t,n,r){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+t}h${n=+n}v${+r}h${-n}Z`}toString(){return this._}};o.prototype;function s(e){return function(){return e}}function c(e){let t=3;return e.digits=function(n){if(!arguments.length)return t;if(n==null)t=null;else{let e=Math.floor(n);if(!(e>=0))throw RangeError(`invalid digits: ${n}`);t=e}return e},()=>new o(t)}export{s as n,c as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{m as t}from"./src-CvxfUak2.js";import"./chunk-I66GZJ75-CulcrLPh.js";import"./uml-C3KAFGTq.js";import{t as n,u as r}from"./mermaid-parser.core-B_UPzTxa.js";import{n as i,r as a,t as o}from"./chunk-6Q2QTUOP-wQkNmt_X.js";import{t as s}from"./chunk-JWPE2WC7-DVXcaiue.js";var c=r().RailroadPeg.parser.LangiumParser,l=e(e=>{let t=e.alternatives.map(u);return t.length===1?t[0]:{type:`choice`,alternatives:t}},`transformOrderedChoice`),u=e(e=>{let t=e.elements.map(d);return t.length===1?t[0]:{type:`sequence`,elements:t}},`transformSequence`),d=e(e=>{let t=p(e.suffix);return e.operator?{type:`special`,text:e.operator===`&`?`&${f(t)}`:`!${f(t)}`}:t},`transformPrefix`),f=e(e=>{switch(e.type){case`terminal`:return`"${e.value}"`;case`nonterminal`:return e.name;case`special`:return e.text;default:return`(...)`}},`nodeToLabel`),p=e(e=>{let t=m(e.primary);if(!e.operator)return t;switch(e.operator){case`?`:return{type:`optional`,element:t};case`*`:return{type:`repetition`,element:t,min:0,max:1/0};case`+`:return{type:`repetition`,element:t,min:1,max:1/0};default:throw Error(`Unsupported PEG suffix operator: ${e.operator}`)}},`transformSuffix`),m=e(e=>{switch(e.$type){case`PegLiteral`:return{type:`terminal`,value:e.value};case`PegIdentifier`:return{type:`nonterminal`,name:e.name};case`PegGroup`:return l(e.element);case`PegAny`:return{type:`special`,text:e.dot};default:throw Error(`Unsupported PEG primary node: ${e.$type}`)}},`transformPrimary`),h=e(e=>({name:e.name,definition:l(e.definition)}),`transformRule`),g=e(e=>{s(e,o),e.title&&o.setTitle(e.title),e.rules.map(e=>o.addRule(h(e)))},`populateDb`),_={parser:{parse:e(e=>{o.clear(),t.debug(`[PEG Parser] Starting Langium parse`);let r=c.parse(e);if(r.lexerErrors.length>0||r.parserErrors.length>0)throw new n(r);let i=r.value;t.debug(`[PEG Parser] Parsed rules:`,i.rules.length),g(i),t.debug(`[PEG Parser] Parse complete`)},`parse`),parser:{yy:o}},db:o,renderer:a,styles:i};export{_ as diagram};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./chunk-KEIR6QF5-BICK3FdT.js";import{b as e}from"./mermaid-parser.core-B_UPzTxa.js";export{e as createPieServices};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{m as t}from"./src-CvxfUak2.js";import{H as n,K as r,U as i,a,c as o,f as s,v as c,w as l,x as u,y as d}from"./chunk-I66GZJ75-CulcrLPh.js";import{t as f}from"./ordinal-BDEzSJ7C.js";import{n as p}from"./path-fybaL0A-.js";import{m}from"./dist-D2qOEbeJ.js";import{t as h}from"./arc-3Z53kgFp.js";import{t as g}from"./array-BifhSqXX.js";import{i as _,p as v}from"./chunk-NSK5VX7P-D2nYrCY4.js";import{f as y}from"./uml-C3KAFGTq.js";import{n as b}from"./mermaid-parser.core-B_UPzTxa.js";import{t as x}from"./chunk-JWPE2WC7-DVXcaiue.js";function S(e,t){return t<e?-1:t>e?1:t>=e?0:NaN}function C(e){return e}function w(){var e=C,t=S,n=null,r=p(0),i=p(m),a=p(0);function o(o){var s,c=(o=g(o)).length,l,u,d=0,f=Array(c),p=Array(c),h=+r.apply(this,arguments),_=Math.min(m,Math.max(-m,i.apply(this,arguments)-h)),v,y=Math.min(Math.abs(_)/c,a.apply(this,arguments)),b=y*(_<0?-1:1),x;for(s=0;s<c;++s)(x=p[f[s]=s]=+e(o[s],s,o))>0&&(d+=x);for(t==null?n!=null&&f.sort(function(e,t){return n(o[e],o[t])}):f.sort(function(e,n){return t(p[e],p[n])}),s=0,u=d?(_-c*b)/d:0;s<c;++s,h=v)l=f[s],x=p[l],v=h+(x>0?x*u:0)+b,p[l]={data:o[l],index:s,value:x,startAngle:h,endAngle:v,padAngle:y};return p}return o.value=function(t){return arguments.length?(e=typeof t==`function`?t:p(+t),o):e},o.sortValues=function(e){return arguments.length?(t=e,n=null,o):t},o.sort=function(e){return arguments.length?(n=e,t=null,o):n},o.startAngle=function(e){return arguments.length?(r=typeof e==`function`?e:p(+e),o):r},o.endAngle=function(e){return arguments.length?(i=typeof e==`function`?e:p(+e),o):i},o.padAngle=function(e){return arguments.length?(a=typeof e==`function`?e:p(+e),o):a},o}var T=s.pie,E={sections:new Map,showData:!1,config:T},D=E.sections,O=E.showData,k=structuredClone(T),A={getConfig:e(()=>structuredClone(k),`getConfig`),clear:e(()=>{D=new Map,O=E.showData,a()},`clear`),setDiagramTitle:r,getDiagramTitle:l,setAccTitle:i,getAccTitle:d,setAccDescription:n,getAccDescription:c,addSection:e(({label:e,value:n})=>{if(n<0)throw Error(`"${e}" has invalid value: ${n}. Negative values are not allowed in pie charts. All slice values must be >= 0.`);D.has(e)||(D.set(e,n),t.debug(`added new section: ${e}, with value: ${n}`))},`addSection`),getSections:e(()=>D,`getSections`),setShowData:e(e=>{O=e},`setShowData`),getShowData:e(()=>O,`getShowData`)},j=e((e,t)=>{x(e,t),t.setShowData(e.showData),e.sections.map(t.addSection)},`populateDb`),M={parse:e(async e=>{let n=await b(`pie`,e);t.debug(n),j(n,A)},`parse`)},N=e(e=>`
|
|
2
|
+
.pieCircle{
|
|
3
|
+
stroke: ${e.pieStrokeColor};
|
|
4
|
+
stroke-width : ${e.pieStrokeWidth};
|
|
5
|
+
opacity : ${e.pieOpacity};
|
|
6
|
+
}
|
|
7
|
+
.pieCircle.highlighted{
|
|
8
|
+
scale: 1.05;
|
|
9
|
+
opacity: 1;
|
|
10
|
+
}
|
|
11
|
+
.pieCircle.highlightedOnHover:hover{
|
|
12
|
+
transition-duration: 250ms;
|
|
13
|
+
scale: 1.05;
|
|
14
|
+
opacity: 1;
|
|
15
|
+
}
|
|
16
|
+
.pieOuterCircle{
|
|
17
|
+
stroke: ${e.pieOuterStrokeColor};
|
|
18
|
+
stroke-width: ${e.pieOuterStrokeWidth};
|
|
19
|
+
fill: none;
|
|
20
|
+
}
|
|
21
|
+
.pieTitleText {
|
|
22
|
+
text-anchor: middle;
|
|
23
|
+
font-size: ${e.pieTitleTextSize};
|
|
24
|
+
fill: ${e.pieTitleTextColor};
|
|
25
|
+
font-family: ${e.fontFamily};
|
|
26
|
+
}
|
|
27
|
+
.slice {
|
|
28
|
+
font-family: ${e.fontFamily};
|
|
29
|
+
fill: ${e.pieSectionTextColor};
|
|
30
|
+
font-size:${e.pieSectionTextSize};
|
|
31
|
+
// fill: white;
|
|
32
|
+
}
|
|
33
|
+
.legend text {
|
|
34
|
+
fill: ${e.pieLegendTextColor};
|
|
35
|
+
font-family: ${e.fontFamily};
|
|
36
|
+
font-size: ${e.pieLegendTextSize};
|
|
37
|
+
}
|
|
38
|
+
`,`getStyles`),P=e(e=>{let t=[...e.values()].reduce((e,t)=>e+t,0),n=[...e.entries()].map(([e,t])=>({label:e,value:t})).filter(e=>e.value/t*100>=1);return w().value(e=>e.value).sort(null)(n)},`createPieArcs`),F={parser:M,db:A,renderer:{draw:e((e,n,r,i)=>{t.debug(`rendering pie chart
|
|
39
|
+
`+e);let a=i.db,s=u(),c=_(a.getConfig(),s.pie),l=y(n),d=l.append(`g`);d.attr(`transform`,`translate(225,225)`);let{themeVariables:p}=s,[m]=v(p.pieOuterStrokeWidth);m??=2;let g=c.legendPosition,b=c.textPosition,x=c.donutHole>0&&c.donutHole<=.9?c.donutHole:0,S=h().innerRadius(x*185).outerRadius(185),C=h().innerRadius(185*b).outerRadius(185*b),w=d.append(`g`);w.append(`circle`).attr(`cx`,0).attr(`cy`,0).attr(`r`,185+m/2).attr(`class`,`pieOuterCircle`);let T=a.getSections(),E=P(T),D=[p.pie1,p.pie2,p.pie3,p.pie4,p.pie5,p.pie6,p.pie7,p.pie8,p.pie9,p.pie10,p.pie11,p.pie12],O=0;T.forEach(e=>{O+=e});let k=E.filter(e=>(e.data.value/O*100).toFixed(0)!==`0`),A=f(D).domain([...T.keys()]);w.selectAll(`mySlices`).data(k).enter().append(`path`).attr(`d`,S).attr(`fill`,e=>A(e.data.label)).attr(`class`,e=>{let t=`pieCircle`;return c.highlightSlice===`hover`?t+=` highlightedOnHover`:c.highlightSlice===e.data.label&&(t+=` highlighted`),t}),w.selectAll(`mySlices`).data(k).enter().append(`text`).text(e=>(e.data.value/O*100).toFixed(0)+`%`).attr(`transform`,e=>`translate(`+C.centroid(e)+`)`).style(`text-anchor`,`middle`).attr(`class`,`slice`);let j=d.append(`text`).text(a.getDiagramTitle()).attr(`x`,0).attr(`y`,-200).attr(`class`,`pieTitleText`),M=[...T.entries()].map(([e,t])=>({label:e,value:t})),N=d.selectAll(`.legend`).data(M).enter().append(`g`).attr(`class`,`legend`);N.append(`rect`).attr(`width`,18).attr(`height`,18).style(`fill`,e=>A(e.label)).style(`stroke`,e=>A(e.label)),N.append(`text`).attr(`x`,22).attr(`y`,14).text(e=>a.getShowData()?`${e.label} [${e.value}]`:e.label);let F=Math.max(...N.selectAll(`text`).nodes().map(e=>e?.getBoundingClientRect().width??0)),I=450,L=490,R=M.length*22;switch(g){case`center`:N.attr(`transform`,(e,t)=>{let n=22*M.length/2,r=-F/2-22,i=t*22-n;return`translate(`+r+`,`+i+`)`});break;case`top`:I+=R,N.attr(`transform`,(e,t)=>`translate(${-F/2-22}, ${t*22-185})`),w.attr(`transform`,()=>`translate(0, ${R+22})`);break;case`bottom`:I+=R,N.attr(`transform`,(e,t)=>{let n=-F/2-22,r=t*22- -207;return`translate(`+n+`,`+r+`)`});break;case`left`:L+=22+F,N.attr(`transform`,(e,t)=>{let n=22*M.length/2;return`translate(-207,`+(t*22-n)+`)`}),w.attr(`transform`,()=>`translate(${F+18+4}, 0)`);break;default:L+=22+F,N.attr(`transform`,(e,t)=>{let n=22*M.length/2;return`translate(216,`+(t*22-n)+`)`})}let z=j.node()?.getBoundingClientRect().width??0,B=225-z/2,V=225+z/2,H=Math.min(0,B),U=Math.max(L,V)-H;l.attr(`viewBox`,`${H} 0 ${U} ${I}`),o(l,I,U,c.useMaxWidth)},`draw`)},styles:N};export{F as diagram};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{m as t,p as n}from"./src-CvxfUak2.js";import{D as r,H as i,K as a,U as o,a as s,c,f as l,v as u,w as d,x as f,y as p,z as m}from"./chunk-I66GZJ75-CulcrLPh.js";import{t as h}from"./linear-BPPxWorj.js";var g=(function(){var t=e(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,3],r=[1,4],i=[1,5],a=[1,6],o=[1,7],s=[1,4,5,10,12,13,14,15,18,25,35,37,39,41,42,48,50,51,52,53,54,55,56,57,60,61,63,64,65,66,67],c=[1,4,5,10,12,13,14,15,18,25,28,35,37,39,41,42,48,50,51,52,53,54,55,56,57,60,61,63,64,65,66,67],l=[55,56,57],u=[2,36],d=[1,37],f=[1,36],p=[1,38],m=[1,35],h=[1,43],g=[1,41],_=[1,45],v=[1,14],y=[1,23],b=[1,18],x=[1,19],S=[1,20],C=[1,21],w=[1,22],T=[1,24],E=[1,25],D=[1,26],O=[1,27],k=[1,28],A=[1,29],j=[1,32],M=[1,33],N=[1,34],P=[1,39],F=[1,40],I=[1,42],L=[1,44],R=[1,63],z=[1,62],B=[4,5,8,10,12,13,14,15,18,44,47,49,55,56,57,63,64,65,66,67],ee=[1,66],te=[1,67],ne=[1,68],re=[1,69],ie=[1,70],ae=[1,71],oe=[1,72],se=[1,73],ce=[1,74],le=[1,75],ue=[1,76],de=[1,77],V=[4,5,6,7,8,9,10,11,12,13,14,15,18],H=[1,91],U=[1,92],W=[1,93],G=[1,100],K=[1,94],q=[1,97],J=[1,95],Y=[1,96],X=[1,98],Z=[1,99],fe=[1,103],pe=[10,55,56,57],Q=[4,5,6,8,10,11,13,17,18,19,20,55,56,57],me={trace:e(function(){},`trace`),yy:{},symbols_:{error:2,idStringToken:3,ALPHA:4,NUM:5,NODE_STRING:6,DOWN:7,MINUS:8,DEFAULT:9,COMMA:10,COLON:11,AMP:12,BRKT:13,MULT:14,UNICODE_TEXT:15,styleComponent:16,UNIT:17,SPACE:18,STYLE:19,PCT:20,idString:21,style:22,stylesOpt:23,classDefStatement:24,CLASSDEF:25,start:26,eol:27,QUADRANT:28,document:29,line:30,statement:31,axisDetails:32,quadrantDetails:33,points:34,title:35,title_value:36,acc_title:37,acc_title_value:38,acc_descr:39,acc_descr_value:40,acc_descr_multiline_value:41,section:42,text:43,point_start:44,point_x:45,point_y:46,class_name:47,"X-AXIS":48,"AXIS-TEXT-DELIMITER":49,"Y-AXIS":50,QUADRANT_1:51,QUADRANT_2:52,QUADRANT_3:53,QUADRANT_4:54,NEWLINE:55,SEMI:56,EOF:57,alphaNumToken:58,textNoTagsToken:59,STR:60,MD_STR:61,alphaNum:62,PUNCTUATION:63,PLUS:64,EQUALS:65,DOT:66,UNDERSCORE:67,$accept:0,$end:1},terminals_:{2:`error`,4:`ALPHA`,5:`NUM`,6:`NODE_STRING`,7:`DOWN`,8:`MINUS`,9:`DEFAULT`,10:`COMMA`,11:`COLON`,12:`AMP`,13:`BRKT`,14:`MULT`,15:`UNICODE_TEXT`,17:`UNIT`,18:`SPACE`,19:`STYLE`,20:`PCT`,25:`CLASSDEF`,28:`QUADRANT`,35:`title`,36:`title_value`,37:`acc_title`,38:`acc_title_value`,39:`acc_descr`,40:`acc_descr_value`,41:`acc_descr_multiline_value`,42:`section`,44:`point_start`,45:`point_x`,46:`point_y`,47:`class_name`,48:`X-AXIS`,49:`AXIS-TEXT-DELIMITER`,50:`Y-AXIS`,51:`QUADRANT_1`,52:`QUADRANT_2`,53:`QUADRANT_3`,54:`QUADRANT_4`,55:`NEWLINE`,56:`SEMI`,57:`EOF`,60:`STR`,61:`MD_STR`,63:`PUNCTUATION`,64:`PLUS`,65:`EQUALS`,66:`DOT`,67:`UNDERSCORE`},productions_:[0,[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[21,1],[21,2],[22,1],[22,2],[23,1],[23,3],[24,5],[26,2],[26,2],[26,2],[29,0],[29,2],[30,2],[31,0],[31,1],[31,2],[31,1],[31,1],[31,1],[31,2],[31,2],[31,2],[31,1],[31,1],[34,4],[34,5],[34,5],[34,6],[32,4],[32,3],[32,2],[32,4],[32,3],[32,2],[33,2],[33,2],[33,2],[33,2],[27,1],[27,1],[27,1],[43,1],[43,2],[43,1],[43,1],[62,1],[62,2],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[59,1],[59,1],[59,1]],performAction:e(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 23:this.$=a[s];break;case 24:this.$=a[s-1]+``+a[s];break;case 26:this.$=a[s-1]+a[s];break;case 27:this.$=[a[s].trim()];break;case 28:a[s-2].push(a[s].trim()),this.$=a[s-2];break;case 29:this.$=a[s-4],r.addClass(a[s-2],a[s]);break;case 37:this.$=[];break;case 42:this.$=a[s].trim(),r.setDiagramTitle(this.$);break;case 43:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 44:case 45:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 46:r.addSection(a[s].substr(8)),this.$=a[s].substr(8);break;case 47:r.addPoint(a[s-3],``,a[s-1],a[s],[]);break;case 48:r.addPoint(a[s-4],a[s-3],a[s-1],a[s],[]);break;case 49:r.addPoint(a[s-4],``,a[s-2],a[s-1],a[s]);break;case 50:r.addPoint(a[s-5],a[s-4],a[s-2],a[s-1],a[s]);break;case 51:r.setXAxisLeftText(a[s-2]),r.setXAxisRightText(a[s]);break;case 52:a[s-1].text+=` ⟶ `,r.setXAxisLeftText(a[s-1]);break;case 53:r.setXAxisLeftText(a[s]);break;case 54:r.setYAxisBottomText(a[s-2]),r.setYAxisTopText(a[s]);break;case 55:a[s-1].text+=` ⟶ `,r.setYAxisBottomText(a[s-1]);break;case 56:r.setYAxisBottomText(a[s]);break;case 57:r.setQuadrant1Text(a[s]);break;case 58:r.setQuadrant2Text(a[s]);break;case 59:r.setQuadrant3Text(a[s]);break;case 60:r.setQuadrant4Text(a[s]);break;case 64:this.$={text:a[s],type:`text`};break;case 65:this.$={text:a[s-1].text+``+a[s],type:a[s-1].type};break;case 66:this.$={text:a[s],type:`text`};break;case 67:this.$={text:a[s],type:`markdown`};break;case 68:this.$=a[s];break;case 69:this.$=a[s-1]+``+a[s]}},`anonymous`),table:[{18:n,26:1,27:2,28:r,55:i,56:a,57:o},{1:[3]},{18:n,26:8,27:2,28:r,55:i,56:a,57:o},{18:n,26:9,27:2,28:r,55:i,56:a,57:o},t(s,[2,33],{29:10}),t(c,[2,61]),t(c,[2,62]),t(c,[2,63]),{1:[2,30]},{1:[2,31]},t(l,u,{30:11,31:12,24:13,32:15,33:16,34:17,43:30,58:31,1:[2,32],4:d,5:f,10:p,12:m,13:h,14:g,15:_,18:v,25:y,35:b,37:x,39:S,41:C,42:w,48:T,50:E,51:D,52:O,53:k,54:A,60:j,61:M,63:N,64:P,65:F,66:I,67:L}),t(s,[2,34]),{27:46,55:i,56:a,57:o},t(l,[2,37]),t(l,u,{24:13,32:15,33:16,34:17,43:30,58:31,31:47,4:d,5:f,10:p,12:m,13:h,14:g,15:_,18:v,25:y,35:b,37:x,39:S,41:C,42:w,48:T,50:E,51:D,52:O,53:k,54:A,60:j,61:M,63:N,64:P,65:F,66:I,67:L}),t(l,[2,39]),t(l,[2,40]),t(l,[2,41]),{36:[1,48]},{38:[1,49]},{40:[1,50]},t(l,[2,45]),t(l,[2,46]),{18:[1,51]},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:52,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:53,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:54,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:55,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:56,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:57,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,44:[1,58],47:[1,59],58:61,59:60,63:N,64:P,65:F,66:I,67:L},t(B,[2,64]),t(B,[2,66]),t(B,[2,67]),t(B,[2,70]),t(B,[2,71]),t(B,[2,72]),t(B,[2,73]),t(B,[2,74]),t(B,[2,75]),t(B,[2,76]),t(B,[2,77]),t(B,[2,78]),t(B,[2,79]),t(B,[2,80]),t(B,[2,81]),t(s,[2,35]),t(l,[2,38]),t(l,[2,42]),t(l,[2,43]),t(l,[2,44]),{3:65,4:ee,5:te,6:ne,7:re,8:ie,9:ae,10:oe,11:se,12:ce,13:le,14:ue,15:de,21:64},t(l,[2,53],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,49:[1,78],63:N,64:P,65:F,66:I,67:L}),t(l,[2,56],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,49:[1,79],63:N,64:P,65:F,66:I,67:L}),t(l,[2,57],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),t(l,[2,58],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),t(l,[2,59],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),t(l,[2,60],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),{45:[1,80]},{44:[1,81]},t(B,[2,65]),t(B,[2,82]),t(B,[2,83]),t(B,[2,84]),{3:83,4:ee,5:te,6:ne,7:re,8:ie,9:ae,10:oe,11:se,12:ce,13:le,14:ue,15:de,18:[1,82]},t(V,[2,23]),t(V,[2,1]),t(V,[2,2]),t(V,[2,3]),t(V,[2,4]),t(V,[2,5]),t(V,[2,6]),t(V,[2,7]),t(V,[2,8]),t(V,[2,9]),t(V,[2,10]),t(V,[2,11]),t(V,[2,12]),t(l,[2,52],{58:31,43:84,4:d,5:f,10:p,12:m,13:h,14:g,15:_,60:j,61:M,63:N,64:P,65:F,66:I,67:L}),t(l,[2,55],{58:31,43:85,4:d,5:f,10:p,12:m,13:h,14:g,15:_,60:j,61:M,63:N,64:P,65:F,66:I,67:L}),{46:[1,86]},{45:[1,87]},{4:H,5:U,6:W,8:G,11:K,13:q,16:90,17:J,18:Y,19:X,20:Z,22:89,23:88},t(V,[2,24]),t(l,[2,51],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),t(l,[2,54],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),t(l,[2,47],{22:89,16:90,23:101,4:H,5:U,6:W,8:G,11:K,13:q,17:J,18:Y,19:X,20:Z}),{46:[1,102]},t(l,[2,29],{10:fe}),t(pe,[2,27],{16:104,4:H,5:U,6:W,8:G,11:K,13:q,17:J,18:Y,19:X,20:Z}),t(Q,[2,25]),t(Q,[2,13]),t(Q,[2,14]),t(Q,[2,15]),t(Q,[2,16]),t(Q,[2,17]),t(Q,[2,18]),t(Q,[2,19]),t(Q,[2,20]),t(Q,[2,21]),t(Q,[2,22]),t(l,[2,49],{10:fe}),t(l,[2,48],{22:89,16:90,23:105,4:H,5:U,6:W,8:G,11:K,13:q,17:J,18:Y,19:X,20:Z}),{4:H,5:U,6:W,8:G,11:K,13:q,16:90,17:J,18:Y,19:X,20:Z,22:106},t(Q,[2,26]),t(l,[2,50],{10:fe}),t(pe,[2,28],{16:104,4:H,5:U,6:W,8:G,11:K,13:q,17:J,18:Y,19:X,20:Z})],defaultActions:{8:[2,30],9:[2,31]},parseError:e(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:e(function(t){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(t,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}e(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}e(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`:
|
|
2
|
+
`+h.showPosition()+`
|
|
3
|
+
Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};me.lexer=(function(){return{EOF:1,parseError:e(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:e(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:e(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:e(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);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);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:e(function(){return this._more=!0,this},`more`),reject:e(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else 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).
|
|
4
|
+
`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:e(function(e){this.unput(this.match.slice(e))},`less`),pastInput:e(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:e(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:e(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+`
|
|
5
|
+
`+t+`^`},`showPosition`),test_match:e(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,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(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:e(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;a<i.length;a++)if(n=this._input.match(this.rules[i[a]]),n&&(!t||n[0].length>t[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text.
|
|
6
|
+
`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:e(function(){return this.next()||this.lex()},`lex`),begin:e(function(e){this.conditionStack.push(e)},`begin`),popState:e(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:e(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:e(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:e(function(e){this.begin(e)},`pushState`),stateStackSize:e(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:e(function(e,t,n,r){switch(n){case 0:break;case 1:break;case 2:return 55;case 3:break;case 4:return this.begin(`title`),35;case 5:return this.popState(),`title_value`;case 6:return this.begin(`acc_title`),37;case 7:return this.popState(),`acc_title_value`;case 8:return this.begin(`acc_descr`),39;case 9:return this.popState(),`acc_descr_value`;case 10:this.begin(`acc_descr_multiline`);break;case 11:this.popState();break;case 12:return`acc_descr_multiline_value`;case 13:return 48;case 14:return 50;case 15:return 49;case 16:return 51;case 17:return 52;case 18:return 53;case 19:return 54;case 20:return 25;case 21:this.begin(`md_string`);break;case 22:return`MD_STR`;case 23:this.popState();break;case 24:this.begin(`string`);break;case 25:this.popState();break;case 26:return`STR`;case 27:this.begin(`class_name`);break;case 28:return this.popState(),47;case 29:return this.begin(`point_start`),44;case 30:return this.begin(`point_x`),45;case 31:this.popState();break;case 32:this.popState(),this.begin(`point_y`);break;case 33:return this.popState(),46;case 34:return 28;case 35:return 4;case 36:return 15;case 37:return 11;case 38:return 64;case 39:return 10;case 40:return 65;case 41:return 65;case 42:return 14;case 43:return 13;case 44:return 67;case 45:return 66;case 46:return 12;case 47:return 8;case 48:return 5;case 49:return 18;case 50:return 56;case 51:return 63;case 52:return 57}},`anonymous`),rules:[/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:title\b)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?: *x-axis *)/i,/^(?: *y-axis *)/i,/^(?: *--+> *)/i,/^(?: *quadrant-1 *)/i,/^(?: *quadrant-2 *)/i,/^(?: *quadrant-3 *)/i,/^(?: *quadrant-4 *)/i,/^(?:classDef\b)/i,/^(?:["][`])/i,/^(?:[^`"]+)/i,/^(?:[`]["])/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?::::)/i,/^(?:^\w+)/i,/^(?:\s*:\s*\[\s*)/i,/^(?:(1)|(0(.\d+)?))/i,/^(?:\s*\] *)/i,/^(?:\s*,\s*)/i,/^(?:(1)|(0(.\d+)?))/i,/^(?: *quadrantChart *)/i,/^(?:[A-Za-z]+)/i,/^(?:[^\x00-\x7F]+)/i,/^(?::)/i,/^(?:\+)/i,/^(?:,)/i,/^(?:=)/i,/^(?:=)/i,/^(?:\*)/i,/^(?:#)/i,/^(?:[\_])/i,/^(?:\.)/i,/^(?:&)/i,/^(?:-)/i,/^(?:[0-9]+)/i,/^(?:\s)/i,/^(?:;)/i,/^(?:[!"#$%&'*+,-.`?\\_/])/i,/^(?:$)/i],conditions:{class_name:{rules:[28],inclusive:!1},point_y:{rules:[33],inclusive:!1},point_x:{rules:[32],inclusive:!1},point_start:{rules:[30,31],inclusive:!1},acc_descr_multiline:{rules:[11,12],inclusive:!1},acc_descr:{rules:[9],inclusive:!1},acc_title:{rules:[7],inclusive:!1},title:{rules:[5],inclusive:!1},md_string:{rules:[22,23],inclusive:!1},string:{rules:[25,26],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,6,8,10,13,14,15,16,17,18,19,20,21,24,27,29,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52],inclusive:!0}}}})();function $(){this.yy={}}return e($,`Parser`),$.prototype=me,me.Parser=$,new $})();g.parser=g;var _=g,v=r(),y=class{constructor(){this.classes=new Map,this.config=this.getDefaultConfig(),this.themeConfig=this.getDefaultThemeConfig(),this.data=this.getDefaultData()}static{e(this,`QuadrantBuilder`)}getDefaultData(){return{titleText:``,quadrant1Text:``,quadrant2Text:``,quadrant3Text:``,quadrant4Text:``,xAxisLeftText:``,xAxisRightText:``,yAxisBottomText:``,yAxisTopText:``,points:[]}}getDefaultConfig(){return{showXAxis:!0,showYAxis:!0,showTitle:!0,chartHeight:l.quadrantChart?.chartWidth||500,chartWidth:l.quadrantChart?.chartHeight||500,titlePadding:l.quadrantChart?.titlePadding||10,titleFontSize:l.quadrantChart?.titleFontSize||20,quadrantPadding:l.quadrantChart?.quadrantPadding||5,xAxisLabelPadding:l.quadrantChart?.xAxisLabelPadding||5,yAxisLabelPadding:l.quadrantChart?.yAxisLabelPadding||5,xAxisLabelFontSize:l.quadrantChart?.xAxisLabelFontSize||16,yAxisLabelFontSize:l.quadrantChart?.yAxisLabelFontSize||16,quadrantLabelFontSize:l.quadrantChart?.quadrantLabelFontSize||16,quadrantTextTopPadding:l.quadrantChart?.quadrantTextTopPadding||5,pointTextPadding:l.quadrantChart?.pointTextPadding||5,pointLabelFontSize:l.quadrantChart?.pointLabelFontSize||12,pointRadius:l.quadrantChart?.pointRadius||5,xAxisPosition:l.quadrantChart?.xAxisPosition||`top`,yAxisPosition:l.quadrantChart?.yAxisPosition||`left`,quadrantInternalBorderStrokeWidth:l.quadrantChart?.quadrantInternalBorderStrokeWidth||1,quadrantExternalBorderStrokeWidth:l.quadrantChart?.quadrantExternalBorderStrokeWidth||2}}getDefaultThemeConfig(){return{quadrant1Fill:v.quadrant1Fill,quadrant2Fill:v.quadrant2Fill,quadrant3Fill:v.quadrant3Fill,quadrant4Fill:v.quadrant4Fill,quadrant1TextFill:v.quadrant1TextFill,quadrant2TextFill:v.quadrant2TextFill,quadrant3TextFill:v.quadrant3TextFill,quadrant4TextFill:v.quadrant4TextFill,quadrantPointFill:v.quadrantPointFill,quadrantPointTextFill:v.quadrantPointTextFill,quadrantXAxisTextFill:v.quadrantXAxisTextFill,quadrantYAxisTextFill:v.quadrantYAxisTextFill,quadrantTitleFill:v.quadrantTitleFill,quadrantInternalBorderStrokeFill:v.quadrantInternalBorderStrokeFill,quadrantExternalBorderStrokeFill:v.quadrantExternalBorderStrokeFill}}clear(){this.config=this.getDefaultConfig(),this.themeConfig=this.getDefaultThemeConfig(),this.data=this.getDefaultData(),this.classes=new Map,t.info(`clear called`)}setData(e){this.data={...this.data,...e}}addPoints(e){this.data.points=[...e,...this.data.points]}addClass(e,t){this.classes.set(e,t)}setConfig(e){t.trace(`setConfig called with: `,e),this.config={...this.config,...e}}setThemeConfig(e){t.trace(`setThemeConfig called with: `,e),this.themeConfig={...this.themeConfig,...e}}calculateSpace(e,t,n,r){let i=this.config.xAxisLabelPadding*2+this.config.xAxisLabelFontSize,a={top:e===`top`&&t?i:0,bottom:e===`bottom`&&t?i:0},o=this.config.yAxisLabelPadding*2+this.config.yAxisLabelFontSize,s={left:this.config.yAxisPosition===`left`&&n?o:0,right:this.config.yAxisPosition===`right`&&n?o:0},c=this.config.titleFontSize+this.config.titlePadding*2,l={top:r?c:0},u=this.config.quadrantPadding+s.left,d=this.config.quadrantPadding+a.top+l.top,f=this.config.chartWidth-this.config.quadrantPadding*2-s.left-s.right,p=this.config.chartHeight-this.config.quadrantPadding*2-a.top-a.bottom-l.top;return{xAxisSpace:a,yAxisSpace:s,titleSpace:l,quadrantSpace:{quadrantLeft:u,quadrantTop:d,quadrantWidth:f,quadrantHalfWidth:f/2,quadrantHeight:p,quadrantHalfHeight:p/2}}}getAxisLabels(e,t,n,r){let{quadrantSpace:i,titleSpace:a}=r,{quadrantHalfHeight:o,quadrantHeight:s,quadrantLeft:c,quadrantHalfWidth:l,quadrantTop:u,quadrantWidth:d}=i,f=!!this.data.xAxisRightText,p=!!this.data.yAxisTopText,m=[];return this.data.xAxisLeftText&&t&&m.push({text:this.data.xAxisLeftText,fill:this.themeConfig.quadrantXAxisTextFill,x:c+(f?l/2:0),y:e===`top`?this.config.xAxisLabelPadding+a.top:this.config.xAxisLabelPadding+u+s+this.config.quadrantPadding,fontSize:this.config.xAxisLabelFontSize,verticalPos:f?`center`:`left`,horizontalPos:`top`,rotation:0}),this.data.xAxisRightText&&t&&m.push({text:this.data.xAxisRightText,fill:this.themeConfig.quadrantXAxisTextFill,x:c+l+(f?l/2:0),y:e===`top`?this.config.xAxisLabelPadding+a.top:this.config.xAxisLabelPadding+u+s+this.config.quadrantPadding,fontSize:this.config.xAxisLabelFontSize,verticalPos:f?`center`:`left`,horizontalPos:`top`,rotation:0}),this.data.yAxisBottomText&&n&&m.push({text:this.data.yAxisBottomText,fill:this.themeConfig.quadrantYAxisTextFill,x:this.config.yAxisPosition===`left`?this.config.yAxisLabelPadding:this.config.yAxisLabelPadding+c+d+this.config.quadrantPadding,y:u+s-(p?o/2:0),fontSize:this.config.yAxisLabelFontSize,verticalPos:p?`center`:`left`,horizontalPos:`top`,rotation:-90}),this.data.yAxisTopText&&n&&m.push({text:this.data.yAxisTopText,fill:this.themeConfig.quadrantYAxisTextFill,x:this.config.yAxisPosition===`left`?this.config.yAxisLabelPadding:this.config.yAxisLabelPadding+c+d+this.config.quadrantPadding,y:u+o-(p?o/2:0),fontSize:this.config.yAxisLabelFontSize,verticalPos:p?`center`:`left`,horizontalPos:`top`,rotation:-90}),m}getQuadrants(e){let{quadrantSpace:t}=e,{quadrantHalfHeight:n,quadrantLeft:r,quadrantHalfWidth:i,quadrantTop:a}=t,o=[{text:{text:this.data.quadrant1Text,fill:this.themeConfig.quadrant1TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:`center`,horizontalPos:`middle`,rotation:0},x:r+i,y:a,width:i,height:n,fill:this.themeConfig.quadrant1Fill},{text:{text:this.data.quadrant2Text,fill:this.themeConfig.quadrant2TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:`center`,horizontalPos:`middle`,rotation:0},x:r,y:a,width:i,height:n,fill:this.themeConfig.quadrant2Fill},{text:{text:this.data.quadrant3Text,fill:this.themeConfig.quadrant3TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:`center`,horizontalPos:`middle`,rotation:0},x:r,y:a+n,width:i,height:n,fill:this.themeConfig.quadrant3Fill},{text:{text:this.data.quadrant4Text,fill:this.themeConfig.quadrant4TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:`center`,horizontalPos:`middle`,rotation:0},x:r+i,y:a+n,width:i,height:n,fill:this.themeConfig.quadrant4Fill}];for(let e of o)e.text.x=e.x+e.width/2,this.data.points.length===0?(e.text.y=e.y+e.height/2,e.text.horizontalPos=`middle`):(e.text.y=e.y+this.config.quadrantTextTopPadding,e.text.horizontalPos=`top`);return o}getQuadrantPoints(e){let{quadrantSpace:t}=e,{quadrantHeight:n,quadrantLeft:r,quadrantTop:i,quadrantWidth:a}=t,o=h().domain([0,1]).range([r,a+r]),s=h().domain([0,1]).range([n+i,i]);return this.data.points.map(e=>{let t=this.classes.get(e.className);return t&&(e={...t,...e}),{x:o(e.x),y:s(e.y),fill:e.color??this.themeConfig.quadrantPointFill,radius:e.radius??this.config.pointRadius,text:{text:e.text,fill:this.themeConfig.quadrantPointTextFill,x:o(e.x),y:s(e.y)+this.config.pointTextPadding,verticalPos:`center`,horizontalPos:`top`,fontSize:this.config.pointLabelFontSize,rotation:0},strokeColor:e.strokeColor??this.themeConfig.quadrantPointFill,strokeWidth:e.strokeWidth??`0px`}})}getBorders(e){let t=this.config.quadrantExternalBorderStrokeWidth/2,{quadrantSpace:n}=e,{quadrantHalfHeight:r,quadrantHeight:i,quadrantLeft:a,quadrantHalfWidth:o,quadrantTop:s,quadrantWidth:c}=n;return[{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a-t,y1:s,x2:a+c+t,y2:s},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a+c,y1:s+t,x2:a+c,y2:s+i-t},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a-t,y1:s+i,x2:a+c+t,y2:s+i},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a,y1:s+t,x2:a,y2:s+i-t},{strokeFill:this.themeConfig.quadrantInternalBorderStrokeFill,strokeWidth:this.config.quadrantInternalBorderStrokeWidth,x1:a+o,y1:s+t,x2:a+o,y2:s+i-t},{strokeFill:this.themeConfig.quadrantInternalBorderStrokeFill,strokeWidth:this.config.quadrantInternalBorderStrokeWidth,x1:a+t,y1:s+r,x2:a+c-t,y2:s+r}]}getTitle(e){if(e)return{text:this.data.titleText,fill:this.themeConfig.quadrantTitleFill,fontSize:this.config.titleFontSize,horizontalPos:`top`,verticalPos:`center`,rotation:0,y:this.config.titlePadding,x:this.config.chartWidth/2}}build(){let e=this.config.showXAxis&&!!(this.data.xAxisLeftText||this.data.xAxisRightText),t=this.config.showYAxis&&!!(this.data.yAxisTopText||this.data.yAxisBottomText),n=this.config.showTitle&&!!this.data.titleText,r=this.data.points.length>0?`bottom`:this.config.xAxisPosition,i=this.calculateSpace(r,e,t,n);return{points:this.getQuadrantPoints(i),quadrants:this.getQuadrants(i),axisLabels:this.getAxisLabels(r,e,t,i),borderLines:this.getBorders(i),title:this.getTitle(n)}}},b=class extends Error{static{e(this,`InvalidStyleError`)}constructor(e,t,n){super(`value for ${e} ${t} is invalid, please use a valid ${n}`),this.name=`InvalidStyleError`}};function x(e){return!/^#?([\dA-Fa-f]{6}|[\dA-Fa-f]{3})$/.test(e)}e(x,`validateHexCode`);function S(e){return!/^\d+$/.test(e)}e(S,`validateNumber`);function C(e){return!/^\d+px$/.test(e)}e(C,`validateSizeInPixels`);function w(e){return m(e.trim(),f())}e(w,`textSanitizer`);var T=new y;function E(e){T.setData({quadrant1Text:w(e.text)})}e(E,`setQuadrant1Text`);function D(e){T.setData({quadrant2Text:w(e.text)})}e(D,`setQuadrant2Text`);function O(e){T.setData({quadrant3Text:w(e.text)})}e(O,`setQuadrant3Text`);function k(e){T.setData({quadrant4Text:w(e.text)})}e(k,`setQuadrant4Text`);function A(e){T.setData({xAxisLeftText:w(e.text)})}e(A,`setXAxisLeftText`);function j(e){T.setData({xAxisRightText:w(e.text)})}e(j,`setXAxisRightText`);function M(e){T.setData({yAxisTopText:w(e.text)})}e(M,`setYAxisTopText`);function N(e){T.setData({yAxisBottomText:w(e.text)})}e(N,`setYAxisBottomText`);function P(e){let t={};for(let n of e){let[e,r]=n.trim().split(/\s*:\s*/);if(e===`radius`){if(S(r))throw new b(e,r,`number`);t.radius=parseInt(r)}else if(e===`color`){if(x(r))throw new b(e,r,`hex code`);t.color=r}else if(e===`stroke-color`){if(x(r))throw new b(e,r,`hex code`);t.strokeColor=r}else if(e===`stroke-width`){if(C(r))throw new b(e,r,`number of pixels (eg. 10px)`);t.strokeWidth=r}else throw Error(`style named ${e} is not supported.`)}return t}e(P,`parseStyles`);function F(e,t,n,r,i){let a=P(i);T.addPoints([{x:n,y:r,text:w(e.text),className:t,...a}])}e(F,`addPoint`);function I(e,t){T.addClass(e,P(t))}e(I,`addClass`);function L(e){T.setConfig({chartWidth:e})}e(L,`setWidth`);function R(e){T.setConfig({chartHeight:e})}e(R,`setHeight`);function z(){let{themeVariables:e,quadrantChart:t}=f();return t&&T.setConfig(t),T.setThemeConfig({quadrant1Fill:e.quadrant1Fill,quadrant2Fill:e.quadrant2Fill,quadrant3Fill:e.quadrant3Fill,quadrant4Fill:e.quadrant4Fill,quadrant1TextFill:e.quadrant1TextFill,quadrant2TextFill:e.quadrant2TextFill,quadrant3TextFill:e.quadrant3TextFill,quadrant4TextFill:e.quadrant4TextFill,quadrantPointFill:e.quadrantPointFill,quadrantPointTextFill:e.quadrantPointTextFill,quadrantXAxisTextFill:e.quadrantXAxisTextFill,quadrantYAxisTextFill:e.quadrantYAxisTextFill,quadrantExternalBorderStrokeFill:e.quadrantExternalBorderStrokeFill,quadrantInternalBorderStrokeFill:e.quadrantInternalBorderStrokeFill,quadrantTitleFill:e.quadrantTitleFill}),T.setData({titleText:d()}),T.build()}e(z,`getQuadrantData`);var B={parser:_,db:{setWidth:L,setHeight:R,setQuadrant1Text:E,setQuadrant2Text:D,setQuadrant3Text:O,setQuadrant4Text:k,setXAxisLeftText:A,setXAxisRightText:j,setYAxisTopText:M,setYAxisBottomText:N,parseStyles:P,addPoint:F,addClass:I,getQuadrantData:z,clear:e(function(){T.clear(),s()},`clear`),setAccTitle:o,getAccTitle:p,setDiagramTitle:a,getDiagramTitle:d,getAccDescription:u,setAccDescription:i},renderer:{draw:e((r,i,a,o)=>{function s(e){return e===`top`?`hanging`:`middle`}e(s,`getDominantBaseLine`);function l(e){return e===`left`?`start`:`middle`}e(l,`getTextAnchor`);function u(e){return`translate(${e.x}, ${e.y}) rotate(${e.rotation||0})`}e(u,`getTransformation`);let d=f();t.debug(`Rendering quadrant chart
|
|
7
|
+
`+r);let p=d.securityLevel,m;p===`sandbox`&&(m=n(`#i`+i));let h=n(p===`sandbox`?m.nodes()[0].contentDocument.body:`body`).select(`[id="${i}"]`),g=h.append(`g`).attr(`class`,`main`),_=d.quadrantChart?.chartWidth??500,v=d.quadrantChart?.chartHeight??500;c(h,v,_,d.quadrantChart?.useMaxWidth??!0),h.attr(`viewBox`,`0 0 `+_+` `+v),o.db.setHeight(v),o.db.setWidth(_);let y=o.db.getQuadrantData(),b=g.append(`g`).attr(`class`,`quadrants`),x=g.append(`g`).attr(`class`,`border`),S=g.append(`g`).attr(`class`,`data-points`),C=g.append(`g`).attr(`class`,`labels`),w=g.append(`g`).attr(`class`,`title`);y.title&&w.append(`text`).attr(`x`,0).attr(`y`,0).attr(`fill`,y.title.fill).attr(`font-size`,y.title.fontSize).attr(`dominant-baseline`,s(y.title.horizontalPos)).attr(`text-anchor`,l(y.title.verticalPos)).attr(`transform`,u(y.title)).text(y.title.text),y.borderLines&&x.selectAll(`line`).data(y.borderLines).enter().append(`line`).attr(`x1`,e=>e.x1).attr(`y1`,e=>e.y1).attr(`x2`,e=>e.x2).attr(`y2`,e=>e.y2).style(`stroke`,e=>e.strokeFill).style(`stroke-width`,e=>e.strokeWidth);let T=b.selectAll(`g.quadrant`).data(y.quadrants).enter().append(`g`).attr(`class`,`quadrant`);T.append(`rect`).attr(`x`,e=>e.x).attr(`y`,e=>e.y).attr(`width`,e=>e.width).attr(`height`,e=>e.height).attr(`fill`,e=>e.fill),T.append(`text`).attr(`x`,0).attr(`y`,0).attr(`fill`,e=>e.text.fill).attr(`font-size`,e=>e.text.fontSize).attr(`dominant-baseline`,e=>s(e.text.horizontalPos)).attr(`text-anchor`,e=>l(e.text.verticalPos)).attr(`transform`,e=>u(e.text)).text(e=>e.text.text),C.selectAll(`g.label`).data(y.axisLabels).enter().append(`g`).attr(`class`,`label`).append(`text`).attr(`x`,0).attr(`y`,0).text(e=>e.text).attr(`fill`,e=>e.fill).attr(`font-size`,e=>e.fontSize).attr(`dominant-baseline`,e=>s(e.horizontalPos)).attr(`text-anchor`,e=>l(e.verticalPos)).attr(`transform`,e=>u(e));let E=S.selectAll(`g.data-point`).data(y.points).enter().append(`g`).attr(`class`,`data-point`);E.append(`circle`).attr(`cx`,e=>e.x).attr(`cy`,e=>e.y).attr(`r`,e=>e.radius).attr(`fill`,e=>e.fill).attr(`stroke`,e=>e.strokeColor).attr(`stroke-width`,e=>e.strokeWidth),E.append(`text`).attr(`x`,0).attr(`y`,0).text(e=>e.text.text).attr(`fill`,e=>e.text.fill).attr(`font-size`,e=>e.text.fontSize).attr(`dominant-baseline`,e=>s(e.text.horizontalPos)).attr(`text-anchor`,e=>l(e.text.verticalPos)).attr(`transform`,e=>u(e.text))},`draw`)},styles:e(()=>``,`styles`)};export{B as diagram};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./chunk-KEIR6QF5-BICK3FdT.js";import{v as e}from"./mermaid-parser.core-B_UPzTxa.js";export{e as createRadarServices};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./chunk-KEIR6QF5-BICK3FdT.js";import{g as e}from"./mermaid-parser.core-B_UPzTxa.js";export{e as createRailroadServices};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./chunk-KEIR6QF5-BICK3FdT.js";import{m as e}from"./mermaid-parser.core-B_UPzTxa.js";export{e as createRailroadAbnfServices};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./chunk-KEIR6QF5-BICK3FdT.js";import{f as e}from"./mermaid-parser.core-B_UPzTxa.js";export{e as createRailroadEbnfServices};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./chunk-KEIR6QF5-BICK3FdT.js";import{u as e}from"./mermaid-parser.core-B_UPzTxa.js";export{e as createRailroadPegServices};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{m as t}from"./src-CvxfUak2.js";import"./chunk-I66GZJ75-CulcrLPh.js";import"./uml-C3KAFGTq.js";import{g as n,t as r}from"./mermaid-parser.core-B_UPzTxa.js";import{n as i,r as a,t as o}from"./chunk-6Q2QTUOP-wQkNmt_X.js";import{t as s}from"./chunk-JWPE2WC7-DVXcaiue.js";var c=n().Railroad.parser.LangiumParser,l=e(e=>{switch(e.$type){case`RailroadTerminalExpr`:return{type:`terminal`,value:e.value};case`RailroadNonTerminalExpr`:return{type:`nonterminal`,name:e.name};case`RailroadSpecialExpr`:return{type:`special`,text:e.text};case`RailroadSequenceExpr`:{let t=e.elements.map(l);return t.length===1?t[0]:{type:`sequence`,elements:t}}case`RailroadChoiceExpr`:{let t=e.alternatives.map(l);return t.length===1?t[0]:{type:`choice`,alternatives:t}}case`RailroadOptionalExpr`:return{type:`optional`,element:l(e.element)};case`RailroadOneOrMoreExpr`:return{type:`repetition`,element:l(e.element),min:1,max:1/0};case`RailroadZeroOrMoreExpr`:return{type:`repetition`,element:l(e.element),min:0,max:1/0};default:throw Error(`Unsupported railroad expression: ${e.$type}`)}},`transformExpression`),u=e(e=>({name:e.name,definition:l(e.definition)}),`transformRule`),d=e(e=>{s(e,o),e.title&&o.setTitle(e.title),e.rules.map(e=>o.addRule(u(e)))},`populateDb`),f={parser:{parse:e(e=>{o.clear(),t.debug(`[Railroad Parser] Starting Langium parse`);let n=c.parse(e);if(n.lexerErrors.length>0||n.parserErrors.length>0)throw new r(n);let i=n.value;t.debug(`[Railroad Parser] Parsed rules:`,i.rules.length),d(i),t.debug(`[Railroad Parser] Parse complete`)},`parse`),parser:{yy:o}},db:o,renderer:a,styles:i};export{f as diagram};
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import{n as e,t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{m as n}from"./src-CvxfUak2.js";import{H as r,K as i,U as a,a as o,b as s,v as c,w as l,x as u,y as d}from"./chunk-I66GZJ75-CulcrLPh.js";import{g as f}from"./chunk-NSK5VX7P-D2nYrCY4.js";import"./chunk-W5SLKNZC-2E6OPhA4.js";import"./chunk-UBXNYLIW-BPEVYsFK.js";import"./chunk-4I5QYGJK-CiIdNwaF.js";import"./chunk-WRU74C26-CBIvOyWp.js";import"./chunk-QR6OTTB3-BrdIzg4Q.js";import"./chunk-7BUUIJ7U-Bb538aSH.js";import{n as p,t as m}from"./uml-C3KAFGTq.js";import{t as h}from"./chunk-XXDRQBXY-pH58XAyl.js";import{t as g}from"./chunk-KBJHAD2P-Wm35lYov.js";var _=(function(){var t=e(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,3],r=[1,4],i=[1,5],a=[1,6],o=[5,6,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,77,89,90],s=[1,22],c=[2,7],l=[1,26],u=[1,27],d=[1,28],f=[1,29],p=[1,33],m=[1,34],h=[1,35],g=[1,36],_=[1,37],v=[1,38],y=[1,24],b=[1,31],x=[1,32],S=[1,30],C=[1,39],w=[1,40],T=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,77,89,90],E=[1,61],D=[89,90],O=[5,8,9,11,13,21,22,23,24,27,29,41,42,43,44,45,46,54,61,63,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],k=[27,29],ee=[1,70],A=[1,71],te=[1,72],ne=[1,73],re=[1,74],ie=[1,75],ae=[1,76],j=[1,83],M=[1,80],N=[1,84],P=[1,85],F=[1,86],I=[1,87],L=[1,88],R=[1,89],z=[1,90],B=[1,91],V=[1,92],oe=[5,8,9,11,13,21,22,23,24,27,41,42,43,44,45,46,54,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],H=[63,64],se=[1,101],ce=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,76,77,89,90],U=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],W=[1,110],G=[1,106],K=[1,107],q=[1,108],J=[1,109],Y=[1,111],X=[1,116],Z=[1,117],Q=[1,114],$=[1,115],le={trace:e(function(){},`trace`),yy:{},symbols_:{error:2,start:3,directive:4,NEWLINE:5,RD:6,diagram:7,EOF:8,acc_title:9,acc_title_value:10,acc_descr:11,acc_descr_value:12,acc_descr_multiline_value:13,requirementDef:14,elementDef:15,relationshipDef:16,direction:17,styleStatement:18,classDefStatement:19,classStatement:20,direction_tb:21,direction_bt:22,direction_rl:23,direction_lr:24,requirementType:25,requirementName:26,STRUCT_START:27,requirementBody:28,STYLE_SEPARATOR:29,idList:30,ID:31,COLONSEP:32,id:33,TEXT:34,text:35,RISK:36,riskLevel:37,VERIFYMTHD:38,verifyType:39,STRUCT_STOP:40,REQUIREMENT:41,FUNCTIONAL_REQUIREMENT:42,INTERFACE_REQUIREMENT:43,PERFORMANCE_REQUIREMENT:44,PHYSICAL_REQUIREMENT:45,DESIGN_CONSTRAINT:46,LOW_RISK:47,MED_RISK:48,HIGH_RISK:49,VERIFY_ANALYSIS:50,VERIFY_DEMONSTRATION:51,VERIFY_INSPECTION:52,VERIFY_TEST:53,ELEMENT:54,elementName:55,elementBody:56,TYPE:57,type:58,DOCREF:59,ref:60,END_ARROW_L:61,relationship:62,LINE:63,END_ARROW_R:64,CONTAINS:65,COPIES:66,DERIVES:67,SATISFIES:68,VERIFIES:69,REFINES:70,TRACES:71,CLASSDEF:72,stylesOpt:73,CLASS:74,ALPHA:75,COMMA:76,STYLE:77,style:78,styleComponent:79,NUM:80,COLON:81,UNIT:82,SPACE:83,BRKT:84,PCT:85,MINUS:86,LABEL:87,SEMICOLON:88,unqString:89,qString:90,$accept:0,$end:1},terminals_:{2:`error`,5:`NEWLINE`,6:`RD`,8:`EOF`,9:`acc_title`,10:`acc_title_value`,11:`acc_descr`,12:`acc_descr_value`,13:`acc_descr_multiline_value`,21:`direction_tb`,22:`direction_bt`,23:`direction_rl`,24:`direction_lr`,27:`STRUCT_START`,29:`STYLE_SEPARATOR`,31:`ID`,32:`COLONSEP`,34:`TEXT`,36:`RISK`,38:`VERIFYMTHD`,40:`STRUCT_STOP`,41:`REQUIREMENT`,42:`FUNCTIONAL_REQUIREMENT`,43:`INTERFACE_REQUIREMENT`,44:`PERFORMANCE_REQUIREMENT`,45:`PHYSICAL_REQUIREMENT`,46:`DESIGN_CONSTRAINT`,47:`LOW_RISK`,48:`MED_RISK`,49:`HIGH_RISK`,50:`VERIFY_ANALYSIS`,51:`VERIFY_DEMONSTRATION`,52:`VERIFY_INSPECTION`,53:`VERIFY_TEST`,54:`ELEMENT`,57:`TYPE`,59:`DOCREF`,61:`END_ARROW_L`,63:`LINE`,64:`END_ARROW_R`,65:`CONTAINS`,66:`COPIES`,67:`DERIVES`,68:`SATISFIES`,69:`VERIFIES`,70:`REFINES`,71:`TRACES`,72:`CLASSDEF`,74:`CLASS`,75:`ALPHA`,76:`COMMA`,77:`STYLE`,80:`NUM`,81:`COLON`,82:`UNIT`,83:`SPACE`,84:`BRKT`,85:`PCT`,86:`MINUS`,87:`LABEL`,88:`SEMICOLON`,89:`unqString`,90:`qString`},productions_:[0,[3,3],[3,2],[3,4],[4,2],[4,2],[4,1],[7,0],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[17,1],[17,1],[17,1],[17,1],[14,5],[14,7],[28,5],[28,5],[28,5],[28,5],[28,2],[28,1],[25,1],[25,1],[25,1],[25,1],[25,1],[25,1],[37,1],[37,1],[37,1],[39,1],[39,1],[39,1],[39,1],[15,5],[15,7],[56,5],[56,5],[56,2],[56,1],[16,5],[16,5],[62,1],[62,1],[62,1],[62,1],[62,1],[62,1],[62,1],[19,3],[20,3],[20,3],[30,1],[30,3],[30,1],[30,3],[18,3],[73,1],[73,3],[78,1],[78,2],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[26,1],[26,1],[33,1],[33,1],[35,1],[35,1],[55,1],[55,1],[58,1],[58,1],[60,1],[60,1]],performAction:e(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 4:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 5:case 6:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 7:this.$=[];break;case 17:r.setDirection(`TB`);break;case 18:r.setDirection(`BT`);break;case 19:r.setDirection(`RL`);break;case 20:r.setDirection(`LR`);break;case 21:r.addRequirement(a[s-3],a[s-4]);break;case 22:r.addRequirement(a[s-5],a[s-6]),r.setClass([a[s-5]],a[s-3]);break;case 23:r.setNewReqId(a[s-2]);break;case 24:r.setNewReqText(a[s-2]);break;case 25:r.setNewReqRisk(a[s-2]);break;case 26:r.setNewReqVerifyMethod(a[s-2]);break;case 29:this.$=r.RequirementType.REQUIREMENT;break;case 30:this.$=r.RequirementType.FUNCTIONAL_REQUIREMENT;break;case 31:this.$=r.RequirementType.INTERFACE_REQUIREMENT;break;case 32:this.$=r.RequirementType.PERFORMANCE_REQUIREMENT;break;case 33:this.$=r.RequirementType.PHYSICAL_REQUIREMENT;break;case 34:this.$=r.RequirementType.DESIGN_CONSTRAINT;break;case 35:this.$=r.RiskLevel.LOW_RISK;break;case 36:this.$=r.RiskLevel.MED_RISK;break;case 37:this.$=r.RiskLevel.HIGH_RISK;break;case 38:this.$=r.VerifyType.VERIFY_ANALYSIS;break;case 39:this.$=r.VerifyType.VERIFY_DEMONSTRATION;break;case 40:this.$=r.VerifyType.VERIFY_INSPECTION;break;case 41:this.$=r.VerifyType.VERIFY_TEST;break;case 42:r.addElement(a[s-3]);break;case 43:r.addElement(a[s-5]),r.setClass([a[s-5]],a[s-3]);break;case 44:r.setNewElementType(a[s-2]);break;case 45:r.setNewElementDocRef(a[s-2]);break;case 48:r.addRelationship(a[s-2],a[s],a[s-4]);break;case 49:r.addRelationship(a[s-2],a[s-4],a[s]);break;case 50:this.$=r.Relationships.CONTAINS;break;case 51:this.$=r.Relationships.COPIES;break;case 52:this.$=r.Relationships.DERIVES;break;case 53:this.$=r.Relationships.SATISFIES;break;case 54:this.$=r.Relationships.VERIFIES;break;case 55:this.$=r.Relationships.REFINES;break;case 56:this.$=r.Relationships.TRACES;break;case 57:this.$=a[s-2],r.defineClass(a[s-1],a[s]);break;case 58:r.setClass(a[s-1],a[s]);break;case 59:r.setClass([a[s-2]],a[s]);break;case 60:case 62:this.$=[a[s]];break;case 61:case 63:this.$=a[s-2].concat([a[s]]);break;case 64:this.$=a[s-2],r.setCssStyle(a[s-1],a[s]);break;case 65:this.$=[a[s]];break;case 66:a[s-2].push(a[s]),this.$=a[s-2];break;case 68:this.$=a[s-1]+a[s]}},`anonymous`),table:[{3:1,4:2,6:n,9:r,11:i,13:a},{1:[3]},{3:8,4:2,5:[1,7],6:n,9:r,11:i,13:a},{5:[1,9]},{10:[1,10]},{12:[1,11]},t(o,[2,6]),{3:12,4:2,6:n,9:r,11:i,13:a},{1:[2,2]},{4:17,5:s,7:13,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},t(o,[2,4]),t(o,[2,5]),{1:[2,1]},{8:[1,41]},{4:17,5:s,7:42,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:43,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:44,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:45,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:46,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:47,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:48,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:49,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:50,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{26:51,89:[1,52],90:[1,53]},{55:54,89:[1,55],90:[1,56]},{29:[1,59],61:[1,57],63:[1,58]},t(T,[2,17]),t(T,[2,18]),t(T,[2,19]),t(T,[2,20]),{30:60,33:62,75:E,89:C,90:w},{30:63,33:62,75:E,89:C,90:w},{30:64,33:62,75:E,89:C,90:w},t(D,[2,29]),t(D,[2,30]),t(D,[2,31]),t(D,[2,32]),t(D,[2,33]),t(D,[2,34]),t(O,[2,81]),t(O,[2,82]),{1:[2,3]},{8:[2,8]},{8:[2,9]},{8:[2,10]},{8:[2,11]},{8:[2,12]},{8:[2,13]},{8:[2,14]},{8:[2,15]},{8:[2,16]},{27:[1,65],29:[1,66]},t(k,[2,79]),t(k,[2,80]),{27:[1,67],29:[1,68]},t(k,[2,85]),t(k,[2,86]),{62:69,65:ee,66:A,67:te,68:ne,69:re,70:ie,71:ae},{62:77,65:ee,66:A,67:te,68:ne,69:re,70:ie,71:ae},{30:78,33:62,75:E,89:C,90:w},{73:79,75:j,76:M,78:81,79:82,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V},t(oe,[2,60]),t(oe,[2,62]),{73:93,75:j,76:M,78:81,79:82,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V},{30:94,33:62,75:E,76:M,89:C,90:w},{5:[1,95]},{30:96,33:62,75:E,89:C,90:w},{5:[1,97]},{30:98,33:62,75:E,89:C,90:w},{63:[1,99]},t(H,[2,50]),t(H,[2,51]),t(H,[2,52]),t(H,[2,53]),t(H,[2,54]),t(H,[2,55]),t(H,[2,56]),{64:[1,100]},t(T,[2,59],{76:M}),t(T,[2,64],{76:se}),{33:103,75:[1,102],89:C,90:w},t(ce,[2,65],{79:104,75:j,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V}),t(U,[2,67]),t(U,[2,69]),t(U,[2,70]),t(U,[2,71]),t(U,[2,72]),t(U,[2,73]),t(U,[2,74]),t(U,[2,75]),t(U,[2,76]),t(U,[2,77]),t(U,[2,78]),t(T,[2,57],{76:se}),t(T,[2,58],{76:M}),{5:W,28:105,31:G,34:K,36:q,38:J,40:Y},{27:[1,112],76:M},{5:X,40:Z,56:113,57:Q,59:$},{27:[1,118],76:M},{33:119,89:C,90:w},{33:120,89:C,90:w},{75:j,78:121,79:82,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V},t(oe,[2,61]),t(oe,[2,63]),t(U,[2,68]),t(T,[2,21]),{32:[1,122]},{32:[1,123]},{32:[1,124]},{32:[1,125]},{5:W,28:126,31:G,34:K,36:q,38:J,40:Y},t(T,[2,28]),{5:[1,127]},t(T,[2,42]),{32:[1,128]},{32:[1,129]},{5:X,40:Z,56:130,57:Q,59:$},t(T,[2,47]),{5:[1,131]},t(T,[2,48]),t(T,[2,49]),t(ce,[2,66],{79:104,75:j,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V}),{33:132,89:C,90:w},{35:133,89:[1,134],90:[1,135]},{37:136,47:[1,137],48:[1,138],49:[1,139]},{39:140,50:[1,141],51:[1,142],52:[1,143],53:[1,144]},t(T,[2,27]),{5:W,28:145,31:G,34:K,36:q,38:J,40:Y},{58:146,89:[1,147],90:[1,148]},{60:149,89:[1,150],90:[1,151]},t(T,[2,46]),{5:X,40:Z,56:152,57:Q,59:$},{5:[1,153]},{5:[1,154]},{5:[2,83]},{5:[2,84]},{5:[1,155]},{5:[2,35]},{5:[2,36]},{5:[2,37]},{5:[1,156]},{5:[2,38]},{5:[2,39]},{5:[2,40]},{5:[2,41]},t(T,[2,22]),{5:[1,157]},{5:[2,87]},{5:[2,88]},{5:[1,158]},{5:[2,89]},{5:[2,90]},t(T,[2,43]),{5:W,28:159,31:G,34:K,36:q,38:J,40:Y},{5:W,28:160,31:G,34:K,36:q,38:J,40:Y},{5:W,28:161,31:G,34:K,36:q,38:J,40:Y},{5:W,28:162,31:G,34:K,36:q,38:J,40:Y},{5:X,40:Z,56:163,57:Q,59:$},{5:X,40:Z,56:164,57:Q,59:$},t(T,[2,23]),t(T,[2,24]),t(T,[2,25]),t(T,[2,26]),t(T,[2,44]),t(T,[2,45])],defaultActions:{8:[2,2],12:[2,1],41:[2,3],42:[2,8],43:[2,9],44:[2,10],45:[2,11],46:[2,12],47:[2,13],48:[2,14],49:[2,15],50:[2,16],134:[2,83],135:[2,84],137:[2,35],138:[2,36],139:[2,37],141:[2,38],142:[2,39],143:[2,40],144:[2,41],147:[2,87],148:[2,88],150:[2,89],151:[2,90]},parseError:e(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:e(function(t){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(t,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}e(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}e(x,`lex`);for(var S,C,w,T,E,D={},O,k,ee,A;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var te=``;for(O in A=[],s[w])this.terminals_[O]&&O>f&&A.push(`'`+this.terminals_[O]+`'`);te=h.showPosition?`Parse error on line `+(l+1)+`:
|
|
2
|
+
`+h.showPosition()+`
|
|
3
|
+
Expecting `+A.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(te,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:A})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),ee=s[r[r.length-2]][r[r.length-1]],r.push(ee);break;case 3:return!0}}return!0},`parse`)};le.lexer=(function(){return{EOF:1,parseError:e(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:e(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:e(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:e(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);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);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:e(function(){return this._more=!0,this},`more`),reject:e(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else 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).
|
|
4
|
+
`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:e(function(e){this.unput(this.match.slice(e))},`less`),pastInput:e(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:e(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:e(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+`
|
|
5
|
+
`+t+`^`},`showPosition`),test_match:e(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,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(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:e(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;a<i.length;a++)if(n=this._input.match(this.rules[i[a]]),n&&(!t||n[0].length>t[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text.
|
|
6
|
+
`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:e(function(){return this.next()||this.lex()},`lex`),begin:e(function(e){this.conditionStack.push(e)},`begin`),popState:e(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:e(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:e(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:e(function(e){this.begin(e)},`pushState`),stateStackSize:e(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:e(function(e,t,n,r){switch(n){case 0:return`title`;case 1:return this.begin(`acc_title`),9;case 2:return this.popState(),`acc_title_value`;case 3:return this.begin(`acc_descr`),11;case 4:return this.popState(),`acc_descr_value`;case 5:this.begin(`acc_descr_multiline`);break;case 6:this.popState();break;case 7:return`acc_descr_multiline_value`;case 8:return 21;case 9:return 22;case 10:return 23;case 11:return 24;case 12:return 5;case 13:break;case 14:break;case 15:break;case 16:return 8;case 17:return 6;case 18:return 27;case 19:return 40;case 20:return 29;case 21:return 32;case 22:return 31;case 23:return 34;case 24:return 36;case 25:return 38;case 26:return 41;case 27:return 42;case 28:return 43;case 29:return 44;case 30:return 45;case 31:return 46;case 32:return 47;case 33:return 48;case 34:return 49;case 35:return 50;case 36:return 51;case 37:return 52;case 38:return 53;case 39:return 54;case 40:return 65;case 41:return 66;case 42:return 67;case 43:return 68;case 44:return 69;case 45:return 70;case 46:return 71;case 47:return 57;case 48:return 59;case 49:return this.begin(`style`),77;case 50:return 75;case 51:return 81;case 52:return 88;case 53:return`PERCENT`;case 54:return 86;case 55:return 84;case 56:break;case 57:this.begin(`string`);break;case 58:this.popState();break;case 59:return this.begin(`style`),72;case 60:return this.begin(`style`),74;case 61:return 61;case 62:return 64;case 63:return 63;case 64:this.begin(`string`);break;case 65:this.popState();break;case 66:return`qString`;case 67:return t.yytext=t.yytext.trim(),89;case 68:return 75;case 69:return 80;case 70:return 76}},`anonymous`),rules:[/^(?:title\s[^#\n;]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:(\r?\n)+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:$)/i,/^(?:requirementDiagram\b)/i,/^(?:\{)/i,/^(?:\})/i,/^(?::{3})/i,/^(?::)/i,/^(?:id\b)/i,/^(?:text\b)/i,/^(?:risk\b)/i,/^(?:verifyMethod\b)/i,/^(?:requirement\b)/i,/^(?:functionalRequirement\b)/i,/^(?:interfaceRequirement\b)/i,/^(?:performanceRequirement\b)/i,/^(?:physicalRequirement\b)/i,/^(?:designConstraint\b)/i,/^(?:low\b)/i,/^(?:medium\b)/i,/^(?:high\b)/i,/^(?:analysis\b)/i,/^(?:demonstration\b)/i,/^(?:inspection\b)/i,/^(?:test\b)/i,/^(?:element\b)/i,/^(?:contains\b)/i,/^(?:copies\b)/i,/^(?:derives\b)/i,/^(?:satisfies\b)/i,/^(?:verifies\b)/i,/^(?:refines\b)/i,/^(?:traces\b)/i,/^(?:type\b)/i,/^(?:docref\b)/i,/^(?:style\b)/i,/^(?:\w+)/i,/^(?::)/i,/^(?:;)/i,/^(?:%)/i,/^(?:-)/i,/^(?:#)/i,/^(?: )/i,/^(?:["])/i,/^(?:\n)/i,/^(?:classDef\b)/i,/^(?:class\b)/i,/^(?:<-)/i,/^(?:->)/i,/^(?:-)/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[\w][^:,\r\n\{\<\>\-\=]*)/i,/^(?:\w+)/i,/^(?:[0-9]+)/i,/^(?:,)/i],conditions:{acc_descr_multiline:{rules:[6,7,68,69,70],inclusive:!1},acc_descr:{rules:[4,68,69,70],inclusive:!1},acc_title:{rules:[2,68,69,70],inclusive:!1},style:{rules:[50,51,52,53,54,55,56,57,58,68,69,70],inclusive:!1},unqString:{rules:[68,69,70],inclusive:!1},token:{rules:[68,69,70],inclusive:!1},string:{rules:[65,66,68,69,70],inclusive:!1},INITIAL:{rules:[0,1,3,5,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,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,59,60,61,62,63,64,67,68,69,70],inclusive:!0}}}})();function ue(){this.yy={}}return e(ue,`Parser`),ue.prototype=le,le.Parser=ue,new ue})();_.parser=_;var v=_,y=class{constructor(){this.relations=[],this.latestRequirement=this.getInitialRequirement(),this.requirements=new Map,this.latestElement=this.getInitialElement(),this.elements=new Map,this.classes=new Map,this.direction=`TB`,this.RequirementType={REQUIREMENT:`Requirement`,FUNCTIONAL_REQUIREMENT:`Functional Requirement`,INTERFACE_REQUIREMENT:`Interface Requirement`,PERFORMANCE_REQUIREMENT:`Performance Requirement`,PHYSICAL_REQUIREMENT:`Physical Requirement`,DESIGN_CONSTRAINT:`Design Constraint`},this.RiskLevel={LOW_RISK:`Low`,MED_RISK:`Medium`,HIGH_RISK:`High`},this.VerifyType={VERIFY_ANALYSIS:`Analysis`,VERIFY_DEMONSTRATION:`Demonstration`,VERIFY_INSPECTION:`Inspection`,VERIFY_TEST:`Test`},this.Relationships={CONTAINS:`contains`,COPIES:`copies`,DERIVES:`derives`,SATISFIES:`satisfies`,VERIFIES:`verifies`,REFINES:`refines`,TRACES:`traces`},this.setAccTitle=a,this.getAccTitle=d,this.setAccDescription=r,this.getAccDescription=c,this.setDiagramTitle=i,this.getDiagramTitle=l,this.getConfig=e(()=>u().requirement,`getConfig`),this.clear(),this.setDirection=this.setDirection.bind(this),this.addRequirement=this.addRequirement.bind(this),this.setNewReqId=this.setNewReqId.bind(this),this.setNewReqRisk=this.setNewReqRisk.bind(this),this.setNewReqText=this.setNewReqText.bind(this),this.setNewReqVerifyMethod=this.setNewReqVerifyMethod.bind(this),this.addElement=this.addElement.bind(this),this.setNewElementType=this.setNewElementType.bind(this),this.setNewElementDocRef=this.setNewElementDocRef.bind(this),this.addRelationship=this.addRelationship.bind(this),this.setCssStyle=this.setCssStyle.bind(this),this.setClass=this.setClass.bind(this),this.defineClass=this.defineClass.bind(this),this.setAccTitle=this.setAccTitle.bind(this),this.setAccDescription=this.setAccDescription.bind(this)}static{e(this,`RequirementDB`)}getDirection(){return this.direction}setDirection(e){this.direction=e}resetLatestRequirement(){this.latestRequirement=this.getInitialRequirement()}resetLatestElement(){this.latestElement=this.getInitialElement()}getInitialRequirement(){return{requirementId:``,text:``,risk:``,verifyMethod:``,name:``,type:``,cssStyles:[],classes:[`default`]}}getInitialElement(){return{name:``,type:``,docRef:``,cssStyles:[],classes:[`default`]}}addRequirement(e,t){return this.requirements.has(e)||this.requirements.set(e,{name:e,type:t,requirementId:this.latestRequirement.requirementId,text:this.latestRequirement.text,risk:this.latestRequirement.risk,verifyMethod:this.latestRequirement.verifyMethod,cssStyles:[],classes:[`default`]}),this.resetLatestRequirement(),this.requirements.get(e)}getRequirements(){return this.requirements}setNewReqId(e){this.latestRequirement!==void 0&&(this.latestRequirement.requirementId=e)}setNewReqText(e){this.latestRequirement!==void 0&&(this.latestRequirement.text=e)}setNewReqRisk(e){this.latestRequirement!==void 0&&(this.latestRequirement.risk=e)}setNewReqVerifyMethod(e){this.latestRequirement!==void 0&&(this.latestRequirement.verifyMethod=e)}addElement(e){return this.elements.has(e)||(this.elements.set(e,{name:e,type:this.latestElement.type,docRef:this.latestElement.docRef,cssStyles:[],classes:[`default`]}),n.info(`Added new element: `,e)),this.resetLatestElement(),this.elements.get(e)}getElements(){return this.elements}setNewElementType(e){this.latestElement!==void 0&&(this.latestElement.type=e)}setNewElementDocRef(e){this.latestElement!==void 0&&(this.latestElement.docRef=e)}addRelationship(e,t,n){this.relations.push({type:e,src:t,dst:n})}getRelationships(){return this.relations}clear(){this.relations=[],this.resetLatestRequirement(),this.requirements=new Map,this.resetLatestElement(),this.elements=new Map,this.classes=new Map,o()}setCssStyle(e,t){for(let n of e){let e=this.requirements.get(n)??this.elements.get(n);if(!t||!e)return;for(let n of t)n.includes(`,`)?e.cssStyles.push(...n.split(`,`)):e.cssStyles.push(n)}}setClass(e,t){for(let n of e){let e=this.requirements.get(n)??this.elements.get(n);if(e)for(let n of t){e.classes.push(n);let t=this.classes.get(n)?.styles;t&&e.cssStyles.push(...t)}}}defineClass(e,t){for(let n of e){let e=this.classes.get(n);e===void 0&&(e={id:n,styles:[],textStyles:[]},this.classes.set(n,e)),t&&t.forEach(function(t){if(/color/.exec(t)){let n=t.replace(`fill`,`bgFill`);e.textStyles.push(n)}e.styles.push(t)}),this.requirements.forEach(e=>{e.classes.includes(n)&&e.cssStyles.push(...t.flatMap(e=>e.split(`,`)))}),this.elements.forEach(e=>{e.classes.includes(n)&&e.cssStyles.push(...t.flatMap(e=>e.split(`,`)))})}}getClasses(){return this.classes}getData(){let e=u(),t=[],n=[];for(let n of this.requirements.values()){let r=n;r.id=n.name,r.cssStyles=n.cssStyles,r.cssClasses=n.classes.join(` `),r.shape=`requirementBox`,r.look=e.look,r.colorIndex=t.length,t.push(r)}for(let n of this.elements.values()){let r=n;r.shape=`requirementBox`,r.look=e.look,r.id=n.name,r.cssStyles=n.cssStyles,r.cssClasses=n.classes.join(` `),r.colorIndex=t.length,t.push(r)}for(let t of this.relations){let r=0,i=t.type===this.Relationships.CONTAINS,a={id:`${t.src}-${t.dst}-${r}`,start:this.requirements.get(t.src)?.name??this.elements.get(t.src)?.name,end:this.requirements.get(t.dst)?.name??this.elements.get(t.dst)?.name,label:`<<${t.type}>>`,classes:`relationshipLine`,style:[`fill:none`,i?``:`stroke-dasharray: 10,7`],labelpos:`c`,thickness:`normal`,type:`normal`,pattern:i?`normal`:`dashed`,arrowTypeStart:i?`requirement_contains`:``,arrowTypeEnd:i?``:`requirement_arrow`,look:e.look,labelType:`markdown`};n.push(a),r++}return{nodes:t,edges:n,other:{},config:e,direction:this.getDirection()}}},b=e(e=>{let{themeVariables:t,look:n}=s(),{bkgColorArray:r,borderColorArray:i}=t;if(!i?.length)return``;let a=``;for(let t=0;t<e.THEME_COLOR_LIMIT;t++)a+=`
|
|
7
|
+
|
|
8
|
+
[data-look="${n}"][data-color-id="color-${t}"].node path {
|
|
9
|
+
stroke: ${i[t]};
|
|
10
|
+
fill: ${r?.length?r[t]:``};
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
[data-look="${n}"][data-color-id="color-${t}"].node rect {
|
|
14
|
+
stroke: ${i[t]};
|
|
15
|
+
fill: ${r?.length?r[t]:``};
|
|
16
|
+
}
|
|
17
|
+
`;return a},`genColor`),x=e(e=>{let{look:t,themeVariables:n}=s(),{requirementEdgeLabelBackground:r}=n;return`
|
|
18
|
+
${b(e)}
|
|
19
|
+
marker {
|
|
20
|
+
fill: ${e.relationColor};
|
|
21
|
+
stroke: ${e.relationColor};
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
marker.cross {
|
|
25
|
+
stroke: ${e.lineColor};
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
svg {
|
|
29
|
+
font-family: ${e.fontFamily};
|
|
30
|
+
font-size: ${e.fontSize};
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.reqBox {
|
|
34
|
+
fill: ${e.requirementBackground};
|
|
35
|
+
fill-opacity: 1.0;
|
|
36
|
+
stroke: ${e.requirementBorderColor};
|
|
37
|
+
stroke-width: ${e.requirementBorderSize};
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
.reqTitle, .reqLabel{
|
|
41
|
+
fill: ${e.requirementTextColor};
|
|
42
|
+
}
|
|
43
|
+
.reqLabelBox {
|
|
44
|
+
fill: ${e.relationLabelBackground};
|
|
45
|
+
fill-opacity: 1.0;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.req-title-line {
|
|
49
|
+
stroke: ${e.requirementBorderColor};
|
|
50
|
+
stroke-width: ${e.requirementBorderSize};
|
|
51
|
+
}
|
|
52
|
+
.relationshipLine {
|
|
53
|
+
stroke: ${e.relationColor};
|
|
54
|
+
stroke-width: ${t===`neo`?e.strokeWidth:`1px`};
|
|
55
|
+
}
|
|
56
|
+
.relationshipLabel {
|
|
57
|
+
fill: ${e.relationLabelColor};
|
|
58
|
+
}
|
|
59
|
+
.edgeLabel {
|
|
60
|
+
background-color: ${e.edgeLabelBackground};
|
|
61
|
+
}
|
|
62
|
+
.edgeLabel .label rect {
|
|
63
|
+
fill: ${e.edgeLabelBackground};
|
|
64
|
+
}
|
|
65
|
+
.edgeLabel .label text {
|
|
66
|
+
fill: ${e.relationLabelColor};
|
|
67
|
+
}
|
|
68
|
+
.divider {
|
|
69
|
+
stroke: ${e.nodeBorder};
|
|
70
|
+
stroke-width: 1;
|
|
71
|
+
}
|
|
72
|
+
.label {
|
|
73
|
+
font-family: ${e.fontFamily};
|
|
74
|
+
color: ${e.nodeTextColor||e.textColor};
|
|
75
|
+
}
|
|
76
|
+
.label text,span {
|
|
77
|
+
fill: ${e.nodeTextColor||e.textColor};
|
|
78
|
+
color: ${e.nodeTextColor||e.textColor};
|
|
79
|
+
}
|
|
80
|
+
.labelBkg {
|
|
81
|
+
background-color: ${r??e.edgeLabelBackground};
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
`},`getStyles`),S={};t(S,{draw:()=>C});var C=e(async function(e,t,r,i){n.info(`REF0:`),n.info(`Drawing requirement diagram (unified)`,t);let{securityLevel:a,state:o,layout:s,look:c}=u(),l=i.db.getData(),d=h(t,a);l.type=i.type,l.layoutAlgorithm=m(s),l.nodeSpacing=o?.nodeSpacing??50,l.rankSpacing=o?.rankSpacing??50,l.markers=c===`neo`?[`requirement_contains_neo`,`requirement_arrow_neo`]:[`requirement_contains`,`requirement_arrow`],l.diagramId=t,await p(l,d),f.insertTitle(d,`requirementDiagramTitleText`,o?.titleTopMargin??25,i.db.getDiagramTitle()),g(d,8,`requirementDiagram`,o?.useMaxWidth??!0)},`draw`),w={parser:v,get db(){return new y},renderer:S,styles:x};export{w as diagram};
|