claude-mpm 5.4.36__py3-none-any.whl → 5.4.59__py3-none-any.whl

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.

Potentially problematic release.


This version of claude-mpm might be problematic. Click here for more details.

Files changed (137) hide show
  1. claude_mpm/VERSION +1 -1
  2. claude_mpm/agents/PM_INSTRUCTIONS.md +489 -177
  3. claude_mpm/agents/base_agent.json +1 -1
  4. claude_mpm/agents/frontmatter_validator.py +2 -2
  5. claude_mpm/cli/commands/configure_agent_display.py +12 -0
  6. claude_mpm/cli/commands/mpm_init/core.py +72 -0
  7. claude_mpm/cli/commands/profile.py +276 -0
  8. claude_mpm/cli/commands/skills.py +14 -18
  9. claude_mpm/cli/executor.py +10 -0
  10. claude_mpm/cli/parsers/base_parser.py +7 -0
  11. claude_mpm/cli/parsers/profile_parser.py +147 -0
  12. claude_mpm/cli/parsers/skills_parser.py +0 -6
  13. claude_mpm/cli/startup.py +433 -147
  14. claude_mpm/commands/mpm-config.md +13 -250
  15. claude_mpm/commands/mpm-doctor.md +9 -22
  16. claude_mpm/commands/mpm-help.md +5 -206
  17. claude_mpm/commands/mpm-init.md +81 -507
  18. claude_mpm/commands/mpm-monitor.md +15 -402
  19. claude_mpm/commands/mpm-organize.md +61 -441
  20. claude_mpm/commands/mpm-postmortem.md +6 -108
  21. claude_mpm/commands/mpm-session-resume.md +12 -363
  22. claude_mpm/commands/mpm-status.md +5 -69
  23. claude_mpm/commands/mpm-ticket-view.md +52 -495
  24. claude_mpm/commands/mpm-version.md +5 -107
  25. claude_mpm/core/optimized_startup.py +61 -0
  26. claude_mpm/core/shared/config_loader.py +3 -1
  27. claude_mpm/dashboard/static/svelte-build/_app/immutable/assets/0.DWzvg0-y.css +1 -0
  28. claude_mpm/dashboard/static/svelte-build/_app/immutable/assets/2.ThTw9_ym.css +1 -0
  29. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/{CWc5urbQ.js → 4TdZjIqw.js} +1 -1
  30. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/5shd3_w0.js +24 -0
  31. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/B0uc0UOD.js +36 -0
  32. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/B7RN905-.js +1 -0
  33. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/B7xVLGWV.js +2 -0
  34. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/BIF9m_hv.js +61 -0
  35. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/BKjSRqUr.js +1 -0
  36. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/BPYeabCQ.js +1 -0
  37. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/BQaXIfA_.js +331 -0
  38. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/{uj46x2Wr.js → BSNlmTZj.js} +1 -1
  39. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/Be7GpZd6.js +7 -0
  40. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/Bh0LDWpI.js +145 -0
  41. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/BofRWZRR.js +10 -0
  42. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/BovzEFCE.js +30 -0
  43. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/C30mlcqg.js +165 -0
  44. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/C4B-KCzX.js +1 -0
  45. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/C4JcI4KD.js +122 -0
  46. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/CBBdVcY8.js +1 -0
  47. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/CDuw-vjf.js +1 -0
  48. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/C_Usid8X.js +15 -0
  49. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/Cfqx1Qun.js +10 -0
  50. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/CiIAseT4.js +128 -0
  51. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/CmKTTxBW.js +1 -0
  52. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/CnA0NrzZ.js +1 -0
  53. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/Cs_tUR18.js +24 -0
  54. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/Cu_Erd72.js +261 -0
  55. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/CyWMqx4W.js +43 -0
  56. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/CzZX-COe.js +220 -0
  57. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/CzeYkLYB.js +65 -0
  58. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/D3k0OPJN.js +4 -0
  59. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/D9lljYKQ.js +1 -0
  60. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/DGkLK5U1.js +267 -0
  61. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/DI7hHRFL.js +1 -0
  62. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/DLVjFsZ3.js +139 -0
  63. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/DUrLdbGD.js +89 -0
  64. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/DVp1hx9R.js +1 -0
  65. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/DY1XQ8fi.js +2 -0
  66. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/DZX00Y4g.js +1 -0
  67. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/Da0KfYnO.js +1 -0
  68. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/DaimHw_p.js +68 -0
  69. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/Dfy6j1xT.js +323 -0
  70. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/Dhb8PKl3.js +1 -0
  71. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/Dle-35c7.js +64 -0
  72. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/DmxopI1J.js +1 -0
  73. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/DwBR2MJi.js +60 -0
  74. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/GYwsonyD.js +1 -0
  75. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/Gi6I4Gst.js +1 -0
  76. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/{DjhvlsAc.js → NqQ1dWOy.js} +1 -1
  77. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/RJiighC3.js +1 -0
  78. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/{N4qtv3Hx.js → Vzk33B_K.js} +1 -1
  79. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/ZGh7QtNv.js +7 -0
  80. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/bT1r9zLR.js +1 -0
  81. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/bTOqqlTd.js +1 -0
  82. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/eNVUfhuA.js +1 -0
  83. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/iEWssX7S.js +162 -0
  84. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/sQeU3Y1z.js +1 -0
  85. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/uuIeMWc-.js +1 -0
  86. claude_mpm/dashboard/static/svelte-build/_app/immutable/entry/app.D6-I5TpK.js +2 -0
  87. claude_mpm/dashboard/static/svelte-build/_app/immutable/entry/start.NWzMBYRp.js +1 -0
  88. claude_mpm/dashboard/static/svelte-build/_app/immutable/nodes/{0.CAGBuiOw.js → 0.m1gL8KXf.js} +1 -1
  89. claude_mpm/dashboard/static/svelte-build/_app/immutable/nodes/1.CgNOuw-d.js +1 -0
  90. claude_mpm/dashboard/static/svelte-build/_app/immutable/nodes/2.C0GcWctS.js +1 -0
  91. claude_mpm/dashboard/static/svelte-build/_app/version.json +1 -1
  92. claude_mpm/dashboard/static/svelte-build/index.html +10 -10
  93. claude_mpm/dashboard-svelte/node_modules/katex/src/fonts/generate_fonts.py +58 -0
  94. claude_mpm/dashboard-svelte/node_modules/katex/src/metrics/extract_tfms.py +114 -0
  95. claude_mpm/dashboard-svelte/node_modules/katex/src/metrics/extract_ttfs.py +122 -0
  96. claude_mpm/dashboard-svelte/node_modules/katex/src/metrics/format_json.py +28 -0
  97. claude_mpm/dashboard-svelte/node_modules/katex/src/metrics/parse_tfm.py +211 -0
  98. claude_mpm/hooks/kuzu_memory_hook.py +5 -5
  99. claude_mpm/init.py +276 -0
  100. claude_mpm/scripts/start_activity_logging.py +0 -0
  101. claude_mpm/services/agents/agent_builder.py +3 -3
  102. claude_mpm/services/agents/deployment/agent_deployment.py +22 -0
  103. claude_mpm/services/agents/deployment/agent_discovery_service.py +3 -1
  104. claude_mpm/services/agents/deployment/agent_format_converter.py +25 -13
  105. claude_mpm/services/agents/deployment/agent_template_builder.py +29 -17
  106. claude_mpm/services/agents/deployment/async_agent_deployment.py +31 -27
  107. claude_mpm/services/agents/deployment/local_template_deployment.py +3 -1
  108. claude_mpm/services/agents/deployment/multi_source_deployment_service.py +149 -4
  109. claude_mpm/services/agents/deployment/remote_agent_discovery_service.py +47 -26
  110. claude_mpm/services/agents/git_source_manager.py +21 -2
  111. claude_mpm/services/agents/sources/git_source_sync_service.py +116 -5
  112. claude_mpm/services/monitor/management/lifecycle.py +7 -1
  113. claude_mpm/services/pm_skills_deployer.py +711 -0
  114. claude_mpm/services/profile_manager.py +337 -0
  115. claude_mpm/services/skills/git_skill_source_manager.py +148 -11
  116. claude_mpm/services/skills/selective_skill_deployer.py +97 -48
  117. claude_mpm/services/skills_deployer.py +161 -65
  118. claude_mpm/skills/bundled/security-scanning.md +112 -0
  119. claude_mpm/skills/skill_manager.py +98 -3
  120. claude_mpm/templates/.pre-commit-config.yaml +112 -0
  121. {claude_mpm-5.4.36.dist-info → claude_mpm-5.4.59.dist-info}/METADATA +3 -2
  122. {claude_mpm-5.4.36.dist-info → claude_mpm-5.4.59.dist-info}/RECORD +126 -67
  123. claude_mpm/dashboard/static/svelte-build/_app/immutable/assets/0.B_FtCwCQ.css +0 -1
  124. claude_mpm/dashboard/static/svelte-build/_app/immutable/assets/2.Cl_eSA4x.css +0 -1
  125. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/BgChzWQ1.js +0 -1
  126. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/CIXEwuWe.js +0 -1
  127. claude_mpm/dashboard/static/svelte-build/_app/immutable/chunks/DMkZpdF2.js +0 -2
  128. claude_mpm/dashboard/static/svelte-build/_app/immutable/entry/app.DTL5mJO-.js +0 -2
  129. claude_mpm/dashboard/static/svelte-build/_app/immutable/entry/start.DzuEhzqh.js +0 -1
  130. claude_mpm/dashboard/static/svelte-build/_app/immutable/nodes/1.DFLC8jdE.js +0 -1
  131. claude_mpm/dashboard/static/svelte-build/_app/immutable/nodes/2.DPvEihJJ.js +0 -10
  132. claude_mpm/hooks/claude_hooks/services/__pycache__/connection_manager.cpython-311.pyc +0 -0
  133. {claude_mpm-5.4.36.dist-info → claude_mpm-5.4.59.dist-info}/WHEEL +0 -0
  134. {claude_mpm-5.4.36.dist-info → claude_mpm-5.4.59.dist-info}/entry_points.txt +0 -0
  135. {claude_mpm-5.4.36.dist-info → claude_mpm-5.4.59.dist-info}/licenses/LICENSE +0 -0
  136. {claude_mpm-5.4.36.dist-info → claude_mpm-5.4.59.dist-info}/licenses/LICENSE-FAQ.md +0 -0
  137. {claude_mpm-5.4.36.dist-info → claude_mpm-5.4.59.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,89 @@
1
+ import{_ as c,l as te,c as W,H as fe,af as ye,ag as be,ah as me,V as _e,F as K,i as G,t as Ee,J as ke,W as Se,X as le,Y as ce}from"./Dfy6j1xT.js";import{g as Ne}from"./C_Usid8X.js";var $=(function(){var t=c(function(_,s,n,a){for(n=n||{},a=_.length;a--;n[_[a]]=s);return n},"o"),g=[1,4],d=[1,13],r=[1,12],p=[1,15],E=[1,16],f=[1,20],h=[1,19],L=[6,7,8],C=[1,26],w=[1,24],N=[1,25],i=[6,7,11],H=[1,31],x=[6,7,11,24],P=[1,6,13,16,17,20,23],M=[1,35],U=[1,36],A=[1,6,7,11,13,16,17,20,23],j=[1,38],V={trace:c(function(){},"trace"),yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,KANBAN:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,shapeData:15,ICON:16,CLASS:17,nodeWithId:18,nodeWithoutId:19,NODE_DSTART:20,NODE_DESCR:21,NODE_DEND:22,NODE_ID:23,SHAPE_DATA:24,$accept:0,$end:1},terminals_:{2:"error",6:"SPACELINE",7:"NL",8:"KANBAN",11:"EOF",13:"SPACELIST",16:"ICON",17:"CLASS",20:"NODE_DSTART",21:"NODE_DESCR",22:"NODE_DEND",23:"NODE_ID",24:"SHAPE_DATA"},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,3],[12,2],[12,2],[12,2],[12,1],[12,2],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[19,3],[18,1],[18,4],[15,2],[15,1]],performAction:c(function(s,n,a,o,u,e,B){var l=e.length-1;switch(u){case 6:case 7:return o;case 8:o.getLogger().trace("Stop NL ");break;case 9:o.getLogger().trace("Stop EOF ");break;case 11:o.getLogger().trace("Stop NL2 ");break;case 12:o.getLogger().trace("Stop EOF2 ");break;case 15:o.getLogger().info("Node: ",e[l-1].id),o.addNode(e[l-2].length,e[l-1].id,e[l-1].descr,e[l-1].type,e[l]);break;case 16:o.getLogger().info("Node: ",e[l].id),o.addNode(e[l-1].length,e[l].id,e[l].descr,e[l].type);break;case 17:o.getLogger().trace("Icon: ",e[l]),o.decorateNode({icon:e[l]});break;case 18:case 23:o.decorateNode({class:e[l]});break;case 19:o.getLogger().trace("SPACELIST");break;case 20:o.getLogger().trace("Node: ",e[l-1].id),o.addNode(0,e[l-1].id,e[l-1].descr,e[l-1].type,e[l]);break;case 21:o.getLogger().trace("Node: ",e[l].id),o.addNode(0,e[l].id,e[l].descr,e[l].type);break;case 22:o.decorateNode({icon:e[l]});break;case 27:o.getLogger().trace("node found ..",e[l-2]),this.$={id:e[l-1],descr:e[l-1],type:o.getType(e[l-2],e[l])};break;case 28:this.$={id:e[l],descr:e[l],type:0};break;case 29:o.getLogger().trace("node found ..",e[l-3]),this.$={id:e[l-3],descr:e[l-1],type:o.getType(e[l-2],e[l])};break;case 30:this.$=e[l-1]+e[l];break;case 31:this.$=e[l];break}},"anonymous"),table:[{3:1,4:2,5:3,6:[1,5],8:g},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:g},{6:d,7:[1,10],9:9,12:11,13:r,14:14,16:p,17:E,18:17,19:18,20:f,23:h},t(L,[2,3]),{1:[2,2]},t(L,[2,4]),t(L,[2,5]),{1:[2,6],6:d,12:21,13:r,14:14,16:p,17:E,18:17,19:18,20:f,23:h},{6:d,9:22,12:11,13:r,14:14,16:p,17:E,18:17,19:18,20:f,23:h},{6:C,7:w,10:23,11:N},t(i,[2,24],{18:17,19:18,14:27,16:[1,28],17:[1,29],20:f,23:h}),t(i,[2,19]),t(i,[2,21],{15:30,24:H}),t(i,[2,22]),t(i,[2,23]),t(x,[2,25]),t(x,[2,26]),t(x,[2,28],{20:[1,32]}),{21:[1,33]},{6:C,7:w,10:34,11:N},{1:[2,7],6:d,12:21,13:r,14:14,16:p,17:E,18:17,19:18,20:f,23:h},t(P,[2,14],{7:M,11:U}),t(A,[2,8]),t(A,[2,9]),t(A,[2,10]),t(i,[2,16],{15:37,24:H}),t(i,[2,17]),t(i,[2,18]),t(i,[2,20],{24:j}),t(x,[2,31]),{21:[1,39]},{22:[1,40]},t(P,[2,13],{7:M,11:U}),t(A,[2,11]),t(A,[2,12]),t(i,[2,15],{24:j}),t(x,[2,30]),{22:[1,41]},t(x,[2,27]),t(x,[2,29])],defaultActions:{2:[2,1],6:[2,2]},parseError:c(function(s,n){if(n.recoverable)this.trace(s);else{var a=new Error(s);throw a.hash=n,a}},"parseError"),parse:c(function(s){var n=this,a=[0],o=[],u=[null],e=[],B=this.table,l="",z=0,ie=0,ue=2,re=1,ge=e.slice.call(arguments,1),b=Object.create(this.lexer),T={yy:{}};for(var J in this.yy)Object.prototype.hasOwnProperty.call(this.yy,J)&&(T.yy[J]=this.yy[J]);b.setInput(s,T.yy),T.yy.lexer=b,T.yy.parser=this,typeof b.yylloc>"u"&&(b.yylloc={});var q=b.yylloc;e.push(q);var de=b.options&&b.options.ranges;typeof T.yy.parseError=="function"?this.parseError=T.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function pe(S){a.length=a.length-2*S,u.length=u.length-S,e.length=e.length-S}c(pe,"popStack");function ae(){var S;return S=o.pop()||b.lex()||re,typeof S!="number"&&(S instanceof Array&&(o=S,S=o.pop()),S=n.symbols_[S]||S),S}c(ae,"lex");for(var k,R,v,Q,F={},X,I,oe,Y;;){if(R=a[a.length-1],this.defaultActions[R]?v=this.defaultActions[R]:((k===null||typeof k>"u")&&(k=ae()),v=B[R]&&B[R][k]),typeof v>"u"||!v.length||!v[0]){var Z="";Y=[];for(X in B[R])this.terminals_[X]&&X>ue&&Y.push("'"+this.terminals_[X]+"'");b.showPosition?Z="Parse error on line "+(z+1)+`:
2
+ `+b.showPosition()+`
3
+ Expecting `+Y.join(", ")+", got '"+(this.terminals_[k]||k)+"'":Z="Parse error on line "+(z+1)+": Unexpected "+(k==re?"end of input":"'"+(this.terminals_[k]||k)+"'"),this.parseError(Z,{text:b.match,token:this.terminals_[k]||k,line:b.yylineno,loc:q,expected:Y})}if(v[0]instanceof Array&&v.length>1)throw new Error("Parse Error: multiple actions possible at state: "+R+", token: "+k);switch(v[0]){case 1:a.push(k),u.push(b.yytext),e.push(b.yylloc),a.push(v[1]),k=null,ie=b.yyleng,l=b.yytext,z=b.yylineno,q=b.yylloc;break;case 2:if(I=this.productions_[v[1]][1],F.$=u[u.length-I],F._$={first_line:e[e.length-(I||1)].first_line,last_line:e[e.length-1].last_line,first_column:e[e.length-(I||1)].first_column,last_column:e[e.length-1].last_column},de&&(F._$.range=[e[e.length-(I||1)].range[0],e[e.length-1].range[1]]),Q=this.performAction.apply(F,[l,ie,z,T.yy,v[1],u,e].concat(ge)),typeof Q<"u")return Q;I&&(a=a.slice(0,-1*I*2),u=u.slice(0,-1*I),e=e.slice(0,-1*I)),a.push(this.productions_[v[1]][0]),u.push(F.$),e.push(F._$),oe=B[a[a.length-2]][a[a.length-1]],a.push(oe);break;case 3:return!0}}return!0},"parse")},m=(function(){var _={EOF:1,parseError:c(function(n,a){if(this.yy.parser)this.yy.parser.parseError(n,a);else throw new Error(n)},"parseError"),setInput:c(function(s,n){return this.yy=n||this.yy||{},this._input=s,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:c(function(){var s=this._input[0];this.yytext+=s,this.yyleng++,this.offset++,this.match+=s,this.matched+=s;var n=s.match(/(?:\r\n?|\n).*/g);return n?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),s},"input"),unput:c(function(s){var n=s.length,a=s.split(/(?:\r\n?|\n)/g);this._input=s+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-n),this.offset-=n;var o=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),a.length-1&&(this.yylineno-=a.length-1);var u=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:a?(a.length===o.length?this.yylloc.first_column:0)+o[o.length-a.length].length-a[0].length:this.yylloc.first_column-n},this.options.ranges&&(this.yylloc.range=[u[0],u[0]+this.yyleng-n]),this.yyleng=this.yytext.length,this},"unput"),more:c(function(){return this._more=!0,this},"more"),reject:c(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:c(function(s){this.unput(this.match.slice(s))},"less"),pastInput:c(function(){var s=this.matched.substr(0,this.matched.length-this.match.length);return(s.length>20?"...":"")+s.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:c(function(){var s=this.match;return s.length<20&&(s+=this._input.substr(0,20-s.length)),(s.substr(0,20)+(s.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:c(function(){var s=this.pastInput(),n=new Array(s.length+1).join("-");return s+this.upcomingInput()+`
5
+ `+n+"^"},"showPosition"),test_match:c(function(s,n){var a,o,u;if(this.options.backtrack_lexer&&(u={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&&(u.yylloc.range=this.yylloc.range.slice(0))),o=s[0].match(/(?:\r\n?|\n).*/g),o&&(this.yylineno+=o.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:o?o[o.length-1].length-o[o.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+s[0].length},this.yytext+=s[0],this.match+=s[0],this.matches=s,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(s[0].length),this.matched+=s[0],a=this.performAction.call(this,this.yy,this,n,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),a)return a;if(this._backtrack){for(var e in u)this[e]=u[e];return!1}return!1},"test_match"),next:c(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var s,n,a,o;this._more||(this.yytext="",this.match="");for(var u=this._currentRules(),e=0;e<u.length;e++)if(a=this._input.match(this.rules[u[e]]),a&&(!n||a[0].length>n[0].length)){if(n=a,o=e,this.options.backtrack_lexer){if(s=this.test_match(a,u[e]),s!==!1)return s;if(this._backtrack){n=!1;continue}else return!1}else if(!this.options.flex)break}return n?(s=this.test_match(n,u[o]),s!==!1?s:!1):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:c(function(){var n=this.next();return n||this.lex()},"lex"),begin:c(function(n){this.conditionStack.push(n)},"begin"),popState:c(function(){var n=this.conditionStack.length-1;return n>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:c(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:c(function(n){return n=this.conditionStack.length-1-Math.abs(n||0),n>=0?this.conditionStack[n]:"INITIAL"},"topState"),pushState:c(function(n){this.begin(n)},"pushState"),stateStackSize:c(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:c(function(n,a,o,u){switch(o){case 0:return this.pushState("shapeData"),a.yytext="",24;case 1:return this.pushState("shapeDataStr"),24;case 2:return this.popState(),24;case 3:const e=/\n\s*/g;return a.yytext=a.yytext.replace(e,"<br/>"),24;case 4:return 24;case 5:this.popState();break;case 6:return n.getLogger().trace("Found comment",a.yytext),6;case 7:return 8;case 8:this.begin("CLASS");break;case 9:return this.popState(),17;case 10:this.popState();break;case 11:n.getLogger().trace("Begin icon"),this.begin("ICON");break;case 12:return n.getLogger().trace("SPACELINE"),6;case 13:return 7;case 14:return 16;case 15:n.getLogger().trace("end icon"),this.popState();break;case 16:return n.getLogger().trace("Exploding node"),this.begin("NODE"),20;case 17:return n.getLogger().trace("Cloud"),this.begin("NODE"),20;case 18:return n.getLogger().trace("Explosion Bang"),this.begin("NODE"),20;case 19:return n.getLogger().trace("Cloud Bang"),this.begin("NODE"),20;case 20:return this.begin("NODE"),20;case 21:return this.begin("NODE"),20;case 22:return this.begin("NODE"),20;case 23:return this.begin("NODE"),20;case 24:return 13;case 25:return 23;case 26:return 11;case 27:this.begin("NSTR2");break;case 28:return"NODE_DESCR";case 29:this.popState();break;case 30:n.getLogger().trace("Starting NSTR"),this.begin("NSTR");break;case 31:return n.getLogger().trace("description:",a.yytext),"NODE_DESCR";case 32:this.popState();break;case 33:return this.popState(),n.getLogger().trace("node end ))"),"NODE_DEND";case 34:return this.popState(),n.getLogger().trace("node end )"),"NODE_DEND";case 35:return this.popState(),n.getLogger().trace("node end ...",a.yytext),"NODE_DEND";case 36:return this.popState(),n.getLogger().trace("node end (("),"NODE_DEND";case 37:return this.popState(),n.getLogger().trace("node end (-"),"NODE_DEND";case 38:return this.popState(),n.getLogger().trace("node end (-"),"NODE_DEND";case 39:return this.popState(),n.getLogger().trace("node end (("),"NODE_DEND";case 40:return this.popState(),n.getLogger().trace("node end (("),"NODE_DEND";case 41:return n.getLogger().trace("Long description:",a.yytext),21;case 42:return n.getLogger().trace("Long description:",a.yytext),21}},"anonymous"),rules:[/^(?:@\{)/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^\"]+)/i,/^(?:[^}^"]+)/i,/^(?:\})/i,/^(?:\s*%%.*)/i,/^(?:kanban\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:{shapeDataEndBracket:{rules:[],inclusive:!1},shapeDataStr:{rules:[2,3],inclusive:!1},shapeData:{rules:[1,4,5],inclusive:!1},CLASS:{rules:[9,10],inclusive:!1},ICON:{rules:[14,15],inclusive:!1},NSTR2:{rules:[28,29],inclusive:!1},NSTR:{rules:[31,32],inclusive:!1},NODE:{rules:[27,30,33,34,35,36,37,38,39,40,41,42],inclusive:!1},INITIAL:{rules:[0,6,7,8,11,12,13,16,17,18,19,20,21,22,23,24,25,26],inclusive:!0}}};return _})();V.lexer=m;function O(){this.yy={}}return c(O,"Parser"),O.prototype=V,V.Parser=O,new O})();$.parser=$;var xe=$,D=[],ne=[],ee=0,se={},ve=c(()=>{D=[],ne=[],ee=0,se={}},"clear"),De=c(t=>{if(D.length===0)return null;const g=D[0].level;let d=null;for(let r=D.length-1;r>=0;r--)if(D[r].level===g&&!d&&(d=D[r]),D[r].level<g)throw new Error('Items without section detected, found section ("'+D[r].label+'")');return t===(d==null?void 0:d.level)?null:d},"getSection"),he=c(function(){return ne},"getSections"),Le=c(function(){const t=[],g=[],d=he(),r=W();for(const p of d){const E={id:p.id,label:G(p.label??"",r),isGroup:!0,ticket:p.ticket,shape:"kanbanSection",level:p.level,look:r.look};g.push(E);const f=D.filter(h=>h.parentId===p.id);for(const h of f){const L={id:h.id,parentId:p.id,label:G(h.label??"",r),isGroup:!1,ticket:h==null?void 0:h.ticket,priority:h==null?void 0:h.priority,assigned:h==null?void 0:h.assigned,icon:h==null?void 0:h.icon,shape:"kanbanItem",level:h.level,rx:5,ry:5,cssStyles:["text-align: left"]};g.push(L)}}return{nodes:g,edges:t,other:{},config:W()}},"getData"),Oe=c((t,g,d,r,p)=>{var C,w;const E=W();let f=((C=E.mindmap)==null?void 0:C.padding)??K.mindmap.padding;switch(r){case y.ROUNDED_RECT:case y.RECT:case y.HEXAGON:f*=2}const h={id:G(g,E)||"kbn"+ee++,level:t,label:G(d,E),width:((w=E.mindmap)==null?void 0:w.maxNodeWidth)??K.mindmap.maxNodeWidth,padding:f,isGroup:!1};if(p!==void 0){let N;p.includes(`
7
+ `)?N=p+`
8
+ `:N=`{
9
+ `+p+`
10
+ }`;const i=Ee(N,{schema:ke});if(i.shape&&(i.shape!==i.shape.toLowerCase()||i.shape.includes("_")))throw new Error(`No such shape: ${i.shape}. Shape names should be lowercase.`);i!=null&&i.shape&&i.shape==="kanbanItem"&&(h.shape=i==null?void 0:i.shape),i!=null&&i.label&&(h.label=i==null?void 0:i.label),i!=null&&i.icon&&(h.icon=i==null?void 0:i.icon.toString()),i!=null&&i.assigned&&(h.assigned=i==null?void 0:i.assigned.toString()),i!=null&&i.ticket&&(h.ticket=i==null?void 0:i.ticket.toString()),i!=null&&i.priority&&(h.priority=i==null?void 0:i.priority)}const L=De(t);L?h.parentId=L.id||"kbn"+ee++:ne.push(h),D.push(h)},"addNode"),y={DEFAULT:0,NO_BORDER:0,ROUNDED_RECT:1,RECT:2,CIRCLE:3,CLOUD:4,BANG:5,HEXAGON:6},Ie=c((t,g)=>{switch(te.debug("In get type",t,g),t){case"[":return y.RECT;case"(":return g===")"?y.ROUNDED_RECT:y.CLOUD;case"((":return y.CIRCLE;case")":return y.CLOUD;case"))":return y.BANG;case"{{":return y.HEXAGON;default:return y.DEFAULT}},"getType"),Ce=c((t,g)=>{se[t]=g},"setElementForId"),we=c(t=>{if(!t)return;const g=W(),d=D[D.length-1];t.icon&&(d.icon=G(t.icon,g)),t.class&&(d.cssClasses=G(t.class,g))},"decorateNode"),Ae=c(t=>{switch(t){case y.DEFAULT:return"no-border";case y.RECT:return"rect";case y.ROUNDED_RECT:return"rounded-rect";case y.CIRCLE:return"circle";case y.CLOUD:return"cloud";case y.BANG:return"bang";case y.HEXAGON:return"hexgon";default:return"no-border"}},"type2Str"),Te=c(()=>te,"getLogger"),Re=c(t=>se[t],"getElementById"),Pe={clear:ve,addNode:Oe,getSections:he,getData:Le,nodeType:y,getType:Ie,setElementForId:Ce,decorateNode:we,type2Str:Ae,getLogger:Te,getElementById:Re},Ve=Pe,Be=c(async(t,g,d,r)=>{var M,U,A,j,V;te.debug(`Rendering kanban diagram
11
+ `+t);const E=r.db.getData(),f=W();f.htmlLabels=!1;const h=fe(g),L=h.append("g");L.attr("class","sections");const C=h.append("g");C.attr("class","items");const w=E.nodes.filter(m=>m.isGroup);let N=0;const i=10,H=[];let x=25;for(const m of w){const O=((M=f==null?void 0:f.kanban)==null?void 0:M.sectionWidth)||200;N=N+1,m.x=O*N+(N-1)*i/2,m.width=O,m.y=0,m.height=O*3,m.rx=5,m.ry=5,m.cssClasses=m.cssClasses+" section-"+N;const _=await ye(L,m);x=Math.max(x,(U=_==null?void 0:_.labelBBox)==null?void 0:U.height),H.push(_)}let P=0;for(const m of w){const O=H[P];P=P+1;const _=((A=f==null?void 0:f.kanban)==null?void 0:A.sectionWidth)||200,s=-_*3/2+x;let n=s;const a=E.nodes.filter(e=>e.parentId===m.id);for(const e of a){if(e.isGroup)throw new Error("Groups within groups are not allowed in Kanban diagrams");e.x=m.x,e.width=_-1.5*i;const l=(await be(C,e,{config:f})).node().getBBox();e.y=n+l.height/2,await me(e),n=e.y+l.height/2+i/2}const o=O.cluster.select("rect"),u=Math.max(n-s+3*i,50)+(x-25);o.attr("height",u)}_e(void 0,h,((j=f.mindmap)==null?void 0:j.padding)??K.kanban.padding,((V=f.mindmap)==null?void 0:V.useMaxWidth)??K.kanban.useMaxWidth)},"draw"),Fe={draw:Be},Ge=c(t=>{let g="";for(let r=0;r<t.THEME_COLOR_LIMIT;r++)t["lineColor"+r]=t["lineColor"+r]||t["cScaleInv"+r],Se(t["lineColor"+r])?t["lineColor"+r]=le(t["lineColor"+r],20):t["lineColor"+r]=ce(t["lineColor"+r],20);const d=c((r,p)=>t.darkMode?ce(r,p):le(r,p),"adjuster");for(let r=0;r<t.THEME_COLOR_LIMIT;r++){const p=""+(17-3*r);g+=`
12
+ .section-${r-1} rect, .section-${r-1} path, .section-${r-1} circle, .section-${r-1} polygon, .section-${r-1} path {
13
+ fill: ${d(t["cScale"+r],10)};
14
+ stroke: ${d(t["cScale"+r],10)};
15
+
16
+ }
17
+ .section-${r-1} text {
18
+ fill: ${t["cScaleLabel"+r]};
19
+ }
20
+ .node-icon-${r-1} {
21
+ font-size: 40px;
22
+ color: ${t["cScaleLabel"+r]};
23
+ }
24
+ .section-edge-${r-1}{
25
+ stroke: ${t["cScale"+r]};
26
+ }
27
+ .edge-depth-${r-1}{
28
+ stroke-width: ${p};
29
+ }
30
+ .section-${r-1} line {
31
+ stroke: ${t["cScaleInv"+r]} ;
32
+ stroke-width: 3;
33
+ }
34
+
35
+ .disabled, .disabled circle, .disabled text {
36
+ fill: lightgray;
37
+ }
38
+ .disabled text {
39
+ fill: #efefef;
40
+ }
41
+
42
+ .node rect,
43
+ .node circle,
44
+ .node ellipse,
45
+ .node polygon,
46
+ .node path {
47
+ fill: ${t.background};
48
+ stroke: ${t.nodeBorder};
49
+ stroke-width: 1px;
50
+ }
51
+
52
+ .kanban-ticket-link {
53
+ fill: ${t.background};
54
+ stroke: ${t.nodeBorder};
55
+ text-decoration: underline;
56
+ }
57
+ `}return g},"genSections"),He=c(t=>`
58
+ .edge {
59
+ stroke-width: 3;
60
+ }
61
+ ${Ge(t)}
62
+ .section-root rect, .section-root path, .section-root circle, .section-root polygon {
63
+ fill: ${t.git0};
64
+ }
65
+ .section-root text {
66
+ fill: ${t.gitBranchLabel0};
67
+ }
68
+ .icon-container {
69
+ height:100%;
70
+ display: flex;
71
+ justify-content: center;
72
+ align-items: center;
73
+ }
74
+ .edge {
75
+ fill: none;
76
+ }
77
+ .cluster-label, .label {
78
+ color: ${t.textColor};
79
+ fill: ${t.textColor};
80
+ }
81
+ .kanban-label {
82
+ dy: 1em;
83
+ alignment-baseline: middle;
84
+ text-anchor: middle;
85
+ dominant-baseline: middle;
86
+ text-align: center;
87
+ }
88
+ ${Ne()}
89
+ `,"getStyles"),Me=He,We={db:Ve,renderer:Fe,parser:xe,styles:Me};export{We as diagram};
@@ -0,0 +1 @@
1
+ var ne=Object.defineProperty;var $=t=>{throw TypeError(t)};var ie=(t,e,s)=>e in t?ne(t,e,{enumerable:!0,configurable:!0,writable:!0,value:s}):t[e]=s;var q=(t,e,s)=>ie(t,typeof e!="symbol"?e+"":e,s),Y=(t,e,s)=>e.has(t)||$("Cannot "+s);var a=(t,e,s)=>(Y(t,e,"read from private field"),s?s.call(t):e.get(t)),m=(t,e,s)=>e.has(t)?$("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,s),K=(t,e,s,r)=>(Y(t,e,"write to private field"),r?r.call(t,s):e.set(t,s),s);import{ao as z,ap as ae,X as L,O as fe,A as G,M as H,x as B,y as ue,V as ce,aq as oe,J as le,z as de,a0 as he,ar as pe,L as _e,Z as ve,C as be,ab as J,as as Pe,G as Se,b as k,I as me,at as U,au as Z,al as we,av as ye,ai as ee,aw as ge,g as R,a4 as Ee,a6 as Re,ax as C,ay as Ae,az as te,f as Oe,aA as xe,aB as Ie,aC as Te,w as j,aD as De,aE as Le,aF as Be,aG as Ce,aH as Ne,aI as Ue,aj as se,F as je,aJ as V,P as W,aK as E}from"./NqQ1dWOy.js";var v,b,h,y,A,O,T;class Fe{constructor(e,s=!0){q(this,"anchor");m(this,v,new Map);m(this,b,new Map);m(this,h,new Map);m(this,y,new Set);m(this,A,!0);m(this,O,()=>{var e=z;if(a(this,v).has(e)){var s=a(this,v).get(e),r=a(this,b).get(s);if(r)ae(r),a(this,y).delete(s);else{var n=a(this,h).get(s);n&&(a(this,b).set(s,n.effect),a(this,h).delete(s),n.fragment.lastChild.remove(),this.anchor.before(n.fragment),r=n.effect)}for(const[i,u]of a(this,v)){if(a(this,v).delete(i),i===e)break;const f=a(this,h).get(u);f&&(L(f.effect),a(this,h).delete(u))}for(const[i,u]of a(this,b)){if(i===s||a(this,y).has(i))continue;const f=()=>{if(Array.from(a(this,v).values()).includes(i)){var p=document.createDocumentFragment();ce(u,p),p.append(G()),a(this,h).set(i,{effect:u,fragment:p})}else L(u);a(this,y).delete(i),a(this,b).delete(i)};a(this,A)||!r?(a(this,y).add(i),fe(u,f,!1)):f()}}});m(this,T,e=>{a(this,v).delete(e);const s=Array.from(a(this,v).values());for(const[r,n]of a(this,h))s.includes(r)||(L(n.effect),a(this,h).delete(r))});this.anchor=e,K(this,A,s)}ensure(e,s){var r=z,n=oe();if(s&&!a(this,b).has(e)&&!a(this,h).has(e))if(n){var i=document.createDocumentFragment(),u=G();i.append(u),a(this,h).set(e,{effect:H(()=>s(u)),fragment:i})}else a(this,b).set(e,H(()=>s(this.anchor)));if(a(this,v).set(r,e),n){for(const[f,c]of a(this,b))f===e?r.skipped_effects.delete(c):r.skipped_effects.add(c);for(const[f,c]of a(this,h))f===e?r.skipped_effects.delete(c.effect):r.skipped_effects.add(c.effect);r.oncommit(a(this,O)),r.ondiscard(a(this,T))}else B&&(this.anchor=ue),a(this,O).call(this)}}v=new WeakMap,b=new WeakMap,h=new WeakMap,y=new WeakMap,A=new WeakMap,O=new WeakMap,T=new WeakMap;function Je(t,e,s=!1){B&&de();var r=new Fe(t),n=s?he:0;function i(u,f){if(B){const p=pe(t)===_e;if(u===p){var c=ve();be(c),r.anchor=c,J(!1),r.ensure(u,f),J(!0);return}}r.ensure(u,f)}le(()=>{var u=!1;e((f,c=!0)=>{u=!0,i(c,f)}),u||i(!1,null)},n)}function X(t,e){return t===e||(t==null?void 0:t[U])===e}function Ze(t={},e,s,r){return Pe(()=>{var n,i;return Se(()=>{n=i,i=[],k(()=>{t!==s(...i)&&(e(t,...i),n&&X(s(...n),t)&&e(null,...n))})}),()=>{me(()=>{i&&X(s(...i),t)&&e(null,...i)})}}),t}let I=!1,N=Symbol();function Ve(t,e,s){const r=s[e]??(s[e]={store:null,source:we(void 0),unsubscribe:Z});if(r.store!==t&&!(N in s))if(r.unsubscribe(),r.store=t??null,t==null)r.source.v=void 0,r.unsubscribe=Z;else{var n=!0;r.unsubscribe=ye(t,i=>{n?r.source.v=i:ee(r.source,i)}),n=!1}return t&&N in s?ge(t):R(r.source)}function We(t,e){return t.set(e),e}function Xe(){const t={};function e(){Ee(()=>{for(var s in t)t[s].unsubscribe();Re(t,N,{enumerable:!1,value:!0})})}return[t,e]}function Me(t){var e=I;try{return I=!1,[t(),I]}finally{I=e}}const $e={get(t,e){if(!t.exclude.includes(e))return R(t.version),e in t.special?t.special[e]():t.props[e]},set(t,e,s){if(!(e in t.special)){var r=j;try{W(t.parent_effect),t.special[e]=Ye({get[e](){return t.props[e]}},e,te)}finally{W(r)}}return t.special[e](s),V(t.version),!0},getOwnPropertyDescriptor(t,e){if(!t.exclude.includes(e)&&e in t.props)return{enumerable:!0,configurable:!0,value:t.props[e]}},deleteProperty(t,e){return t.exclude.includes(e)||(t.exclude.push(e),V(t.version)),!0},has(t,e){return t.exclude.includes(e)?!1:e in t.props},ownKeys(t){return Reflect.ownKeys(t.props).filter(e=>!t.exclude.includes(e))}};function Qe(t,e){return new Proxy({props:t,exclude:e,special:{},version:je(0),parent_effect:j},$e)}const qe={get(t,e){let s=t.props.length;for(;s--;){let r=t.props[s];if(E(r)&&(r=r()),typeof r=="object"&&r!==null&&e in r)return r[e]}},set(t,e,s){let r=t.props.length;for(;r--;){let n=t.props[r];E(n)&&(n=n());const i=C(n,e);if(i&&i.set)return i.set(s),!0}return!1},getOwnPropertyDescriptor(t,e){let s=t.props.length;for(;s--;){let r=t.props[s];if(E(r)&&(r=r()),typeof r=="object"&&r!==null&&e in r){const n=C(r,e);return n&&!n.configurable&&(n.configurable=!0),n}}},has(t,e){if(e===U||e===se)return!1;for(let s of t.props)if(E(s)&&(s=s()),s!=null&&e in s)return!0;return!1},ownKeys(t){const e=[];for(let s of t.props)if(E(s)&&(s=s()),!!s){for(const r in s)e.includes(r)||e.push(r);for(const r of Object.getOwnPropertySymbols(s))e.includes(r)||e.push(r)}return e}};function ke(...t){return new Proxy({props:t},qe)}function Ye(t,e,s,r){var F;var n=!Be||(s&Ce)!==0,i=(s&Le)!==0,u=(s&Ue)!==0,f=r,c=!0,p=()=>(c&&(c=!1,f=u?k(r):r),f),o;if(i){var P=U in t||se in t;o=((F=C(t,e))==null?void 0:F.set)??(P&&e in t?d=>t[e]=d:void 0)}var _,D=!1;i?[_,D]=Me(()=>t[e]):_=t[e],_===void 0&&r!==void 0&&(_=p(),o&&(n&&Ae(),o(_)));var l;if(n?l=()=>{var d=t[e];return d===void 0?p():(c=!0,d)}:l=()=>{var d=t[e];return d!==void 0&&(f=void 0),d===void 0?f:d},n&&(s&te)===0)return l;if(o){var w=t.$$legacy;return(function(d,x){return arguments.length>0?((!n||!x||w||D)&&o(x?l():d),d):l()})}var S=!1,g=((s&Ne)!==0?Oe:xe)(()=>(S=!1,l()));i&&R(g);var re=j;return(function(d,x){if(arguments.length>0){const M=x?R(g):n&&i?Ie(d):d;return ee(g,M),S=!0,f!==void 0&&(f=M),d}return Te&&S||(re.f&De)!==0?g.v:R(g)})}const Ke="modulepreload",ze=function(t,e){return new URL(t,e).href},Q={},et=function(e,s,r){let n=Promise.resolve();if(s&&s.length>0){let u=function(o){return Promise.all(o.map(P=>Promise.resolve(P).then(_=>({status:"fulfilled",value:_}),_=>({status:"rejected",reason:_}))))};const f=document.getElementsByTagName("link"),c=document.querySelector("meta[property=csp-nonce]"),p=(c==null?void 0:c.nonce)||(c==null?void 0:c.getAttribute("nonce"));n=u(s.map(o=>{if(o=ze(o,r),o in Q)return;Q[o]=!0;const P=o.endsWith(".css"),_=P?'[rel="stylesheet"]':"";if(!!r)for(let w=f.length-1;w>=0;w--){const S=f[w];if(S.href===o&&(!P||S.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${o}"]${_}`))return;const l=document.createElement("link");if(l.rel=P?"stylesheet":Ke,P||(l.as="script"),l.crossOrigin="",l.href=o,p&&l.setAttribute("nonce",p),document.head.appendChild(l),P)return new Promise((w,S)=>{l.addEventListener("load",w),l.addEventListener("error",()=>S(new Error(`Unable to preload CSS for ${o}`)))})}))}function i(u){const f=new Event("vite:preloadError",{cancelable:!0});if(f.payload=u,window.dispatchEvent(f),!f.defaultPrevented)throw u}return n.then(u=>{for(const f of u||[])f.status==="rejected"&&i(f.reason);return e().catch(i)})};export{Fe as B,et as _,Xe as a,Ze as b,We as c,ke as d,Je as i,Qe as l,Ye as p,Ve as s};
@@ -0,0 +1,2 @@
1
+ var kt=Object.defineProperty;var ht=e=>{throw TypeError(e)};var Rt=(e,t,i)=>t in e?kt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i;var ct=(e,t,i)=>Rt(e,typeof t!="symbol"?t+"":t,i),Q=(e,t,i)=>t.has(e)||ht("Cannot "+i);var s=(e,t,i)=>(Q(e,t,"read from private field"),i?i.call(e):t.get(e)),u=(e,t,i)=>t.has(e)?ht("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,i),n=(e,t,i,a)=>(Q(e,t,"write to private field"),a?a.call(e,i):t.set(e,i),i),_=(e,t,i)=>(Q(e,t,"access private method"),i);import{D as St,g as gt,F as vt,G as Nt,b as At,H as ft,I as ot,y as L,x as O,w as W,J as Dt,z as Lt,K as lt,L as Ot,M as D,N as j,O as X,A as yt,P as z,Q as P,R as dt,S as Ft,U as tt,c as bt,V as It,W as Mt,X as Z,C as G,Y as Vt,Z as Ct,_ as _t,$ as Pt,a0 as Bt,a1 as Ht,a2 as Wt,a3 as Yt,a4 as xt,a5 as jt,a6 as qt,a7 as et,n as Ut,a8 as $t,a9 as zt,aa as st,ab as q,ac as Gt,ad as Jt,ae as Kt,af as Qt,p as Xt,ag as Zt,ah as te,i as ee}from"./NqQ1dWOy.js";import{b as se}from"./4TdZjIqw.js";function ie(e){let t=0,i=vt(0),a;return()=>{St()&&(gt(i),Nt(()=>(t===0&&(a=At(()=>e(()=>ft(i)))),t+=1,()=>{ot(()=>{t-=1,t===0&&(a==null||a(),a=void 0,ft(i))})})))}}var re=Bt|Ht|Wt;function ne(e,t,i){new ae(e,t,i)}var g,p,Y,E,F,m,v,d,w,R,S,I,N,M,A,J,l,Et,mt,it,U,$,rt;class ae{constructor(t,i,a){u(this,l);ct(this,"parent");u(this,g,!1);u(this,p);u(this,Y,O?L:null);u(this,E);u(this,F);u(this,m);u(this,v,null);u(this,d,null);u(this,w,null);u(this,R,null);u(this,S,null);u(this,I,0);u(this,N,0);u(this,M,!1);u(this,A,null);u(this,J,ie(()=>(n(this,A,vt(s(this,I))),()=>{n(this,A,null)})));n(this,p,t),n(this,E,i),n(this,F,a),this.parent=W.b,n(this,g,!!s(this,E).pending),n(this,m,Dt(()=>{if(W.b=this,O){const r=s(this,Y);Lt(),r.nodeType===lt&&r.data===Ot?_(this,l,mt).call(this):_(this,l,Et).call(this)}else{var o=_(this,l,it).call(this);try{n(this,v,D(()=>a(o)))}catch(r){this.error(r)}s(this,N)>0?_(this,l,$).call(this):n(this,g,!1)}return()=>{var r;(r=s(this,S))==null||r.remove()}},re)),O&&n(this,p,L)}is_pending(){return s(this,g)||!!this.parent&&this.parent.is_pending()}has_pending_snippet(){return!!s(this,E).pending}update_pending_count(t){_(this,l,rt).call(this,t),n(this,I,s(this,I)+t),s(this,A)&&Mt(s(this,A),s(this,I))}get_effect_pending(){return s(this,J).call(this),gt(s(this,A))}error(t){var i=s(this,E).onerror;let a=s(this,E).failed;if(s(this,M)||!i&&!a)throw t;s(this,v)&&(Z(s(this,v)),n(this,v,null)),s(this,d)&&(Z(s(this,d)),n(this,d,null)),s(this,w)&&(Z(s(this,w)),n(this,w,null)),O&&(G(s(this,Y)),Vt(),G(Ct()));var o=!1,r=!1;const h=()=>{if(o){Yt();return}o=!0,r&&Pt(),j.ensure(),n(this,I,0),s(this,w)!==null&&X(s(this,w),()=>{n(this,w,null)}),n(this,g,this.has_pending_snippet()),n(this,v,_(this,l,U).call(this,()=>(n(this,M,!1),D(()=>s(this,F).call(this,s(this,p)))))),s(this,N)>0?_(this,l,$).call(this):n(this,g,!1)};var b=tt;try{P(null),r=!0,i==null||i(t,h),r=!1}catch(y){_t(y,s(this,m)&&s(this,m).parent)}finally{P(b)}a&&ot(()=>{n(this,w,_(this,l,U).call(this,()=>{j.ensure(),n(this,M,!0);try{return D(()=>{a(s(this,p),()=>t,()=>h)})}catch(y){return _t(y,s(this,m).parent),null}finally{n(this,M,!1)}}))})}}g=new WeakMap,p=new WeakMap,Y=new WeakMap,E=new WeakMap,F=new WeakMap,m=new WeakMap,v=new WeakMap,d=new WeakMap,w=new WeakMap,R=new WeakMap,S=new WeakMap,I=new WeakMap,N=new WeakMap,M=new WeakMap,A=new WeakMap,J=new WeakMap,l=new WeakSet,Et=function(){try{n(this,v,D(()=>s(this,F).call(this,s(this,p))))}catch(t){this.error(t)}n(this,g,!1)},mt=function(){const t=s(this,E).pending;t&&(n(this,d,D(()=>t(s(this,p)))),j.enqueue(()=>{var i=_(this,l,it).call(this);n(this,v,_(this,l,U).call(this,()=>(j.ensure(),D(()=>s(this,F).call(this,i))))),s(this,N)>0?_(this,l,$).call(this):(X(s(this,d),()=>{n(this,d,null)}),n(this,g,!1))}))},it=function(){var t=s(this,p);return s(this,g)&&(n(this,S,yt()),s(this,p).before(s(this,S)),t=s(this,S)),t},U=function(t){var i=W,a=tt,o=bt;z(s(this,m)),P(s(this,m)),dt(s(this,m).ctx);try{return t()}catch(r){return Ft(r),null}finally{z(i),P(a),dt(o)}},$=function(){const t=s(this,E).pending;s(this,v)!==null&&(n(this,R,document.createDocumentFragment()),s(this,R).append(s(this,S)),It(s(this,v),s(this,R))),s(this,d)===null&&n(this,d,D(()=>t(s(this,p))))},rt=function(t){var i;if(!this.has_pending_snippet()){this.parent&&_(i=this.parent,l,rt).call(i,t);return}n(this,N,s(this,N)+t),s(this,N)===0&&(n(this,g,!1),s(this,d)&&X(s(this,d),()=>{n(this,d,null)}),s(this,R)&&(s(this,p).before(s(this,R)),n(this,R,null)))};function ge(e){return e.endsWith("capture")&&e!=="gotpointercapture"&&e!=="lostpointercapture"}const oe=["beforeinput","click","change","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"];function ve(e){return oe.includes(e)}const le={formnovalidate:"formNoValidate",ismap:"isMap",nomodule:"noModule",playsinline:"playsInline",readonly:"readOnly",defaultvalue:"defaultValue",defaultchecked:"defaultChecked",srcobject:"srcObject",novalidate:"noValidate",allowfullscreen:"allowFullscreen",disablepictureinpicture:"disablePictureInPicture",disableremoteplayback:"disableRemotePlayback"};function ye(e){return e=e.toLowerCase(),le[e]??e}const ue=["touchstart","touchmove"];function he(e){return ue.includes(e)}const wt=new Set,nt=new Set;function ce(e,t,i,a={}){function o(r){if(a.capture||H.call(t,r),!r.cancelBubble)return jt(()=>i==null?void 0:i.call(this,r))}return e.startsWith("pointer")||e.startsWith("touch")||e==="wheel"?ot(()=>{t.addEventListener(e,o,a)}):t.addEventListener(e,o,a),o}function be(e,t,i,a,o){var r={capture:a,passive:o},h=ce(e,t,i,r);(t===document.body||t===window||t===document||t instanceof HTMLMediaElement)&&xt(()=>{t.removeEventListener(e,h,r)})}function Ee(e){for(var t=0;t<e.length;t++)wt.add(e[t]);for(var i of nt)i(e)}let pt=null;function H(e){var ut;var t=this,i=t.ownerDocument,a=e.type,o=((ut=e.composedPath)==null?void 0:ut.call(e))||[],r=o[0]||e.target;pt=e;var h=0,b=pt===e&&e.__root;if(b){var y=o.indexOf(b);if(y!==-1&&(t===document||t===window)){e.__root=t;return}var V=o.indexOf(t);if(V===-1)return;y<=V&&(h=y)}if(r=o[h]||e.target,r!==t){qt(e,"currentTarget",{configurable:!0,get(){return r||i}});var K=tt,T=W;P(null),z(null);try{for(var c,f=[];r!==null;){var k=r.assignedSlot||r.parentNode||r.host||null;try{var B=r["__"+a];B!=null&&(!r.disabled||e.target===r)&&B.call(r,e)}catch(x){c?f.push(x):c=x}if(e.cancelBubble||k===t||k===null)break;r=k}if(c){for(let x of f)queueMicrotask(()=>{throw x});throw c}}finally{e.__root=t,delete e.currentTarget,P(K),z(T)}}}function me(e,t){var i=t==null?"":typeof t=="object"?t+"":t;i!==(e.__t??(e.__t=e.nodeValue))&&(e.__t=i,e.nodeValue=i+"")}function fe(e,t){return Tt(e,t)}function we(e,t){et(),t.intro=t.intro??!1;const i=t.target,a=O,o=L;try{for(var r=Ut(i);r&&(r.nodeType!==lt||r.data!==$t);)r=zt(r);if(!r)throw st;q(!0),G(r);const h=Tt(e,{...t,anchor:r});return q(!1),h}catch(h){if(h instanceof Error&&h.message.split(`
2
+ `).some(b=>b.startsWith("https://svelte.dev/e/")))throw h;return h!==st&&console.warn("Failed to hydrate: ",h),t.recover===!1&&Gt(),et(),Jt(i),q(!1),fe(e,t)}finally{q(a),G(o)}}const C=new Map;function Tt(e,{target:t,anchor:i,props:a={},events:o,context:r,intro:h=!0}){et();var b=new Set,y=T=>{for(var c=0;c<T.length;c++){var f=T[c];if(!b.has(f)){b.add(f);var k=he(f);t.addEventListener(f,H,{passive:k});var B=C.get(f);B===void 0?(document.addEventListener(f,H,{passive:k}),C.set(f,1)):C.set(f,B+1)}}};y(Kt(wt)),nt.add(y);var V=void 0,K=Qt(()=>{var T=i??t.appendChild(yt());return ne(T,{pending:()=>{}},c=>{if(r){Xt({});var f=bt;f.c=r}if(o&&(a.$$events=o),O&&se(c,null),V=e(c,a)||{},O&&(W.nodes.end=L,L===null||L.nodeType!==lt||L.data!==Zt))throw te(),st;r&&ee()}),()=>{var k;for(var c of b){t.removeEventListener(c,H);var f=C.get(c);--f===0?(document.removeEventListener(c,H),C.delete(c)):C.set(c,f)}nt.delete(y),T!==i&&((k=T.parentNode)==null||k.removeChild(T))}});return at.set(V,K),V}let at=new WeakMap;function Te(e,t){const i=at.get(e);return i?(at.delete(e),i(t)):Promise.resolve()}export{ve as a,ce as c,Ee as d,be as e,we as h,ge as i,fe as m,ye as n,me as s,Te as u};
@@ -0,0 +1 @@
1
+ import{s as r,c as s,a as e,C as t}from"./C30mlcqg.js";import{_ as l}from"./Dfy6j1xT.js";var d={parser:e,get db(){return new t},renderer:s,styles:r,init:l(a=>{a.class||(a.class={}),a.class.arrowMarkerAbsolute=a.arrowMarkerAbsolute},"init")};export{d as diagram};
@@ -0,0 +1 @@
1
+ import{ap as o,aq as n}from"./Dfy6j1xT.js";const t=(a,r)=>o.lang.round(n.parse(a)[r]);export{t as c};
@@ -0,0 +1,68 @@
1
+ import{g as le}from"./CnA0NrzZ.js";import{s as he}from"./BPYeabCQ.js";import{_ as l,l as I,o as de,r as ge,F as j,c as X,i as B,aC as ue,W as pe,X as fe,Y as ye}from"./Dfy6j1xT.js";const E=[];for(let t=0;t<256;++t)E.push((t+256).toString(16).slice(1));function me(t,e=0){return(E[t[e+0]]+E[t[e+1]]+E[t[e+2]]+E[t[e+3]]+"-"+E[t[e+4]]+E[t[e+5]]+"-"+E[t[e+6]]+E[t[e+7]]+"-"+E[t[e+8]]+E[t[e+9]]+"-"+E[t[e+10]]+E[t[e+11]]+E[t[e+12]]+E[t[e+13]]+E[t[e+14]]+E[t[e+15]]).toLowerCase()}let Y;const Ee=new Uint8Array(16);function _e(){if(!Y){if(typeof crypto>"u"||!crypto.getRandomValues)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");Y=crypto.getRandomValues.bind(crypto)}return Y(Ee)}const be=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),ne={randomUUID:be};function Se(t,e,n){var u;if(ne.randomUUID&&!t)return ne.randomUUID();t=t||{};const c=t.random??((u=t.rng)==null?void 0:u.call(t))??_e();if(c.length<16)throw new Error("Random bytes length must be >= 16");return c[6]=c[6]&15|64,c[8]=c[8]&63|128,me(c)}var q=(function(){var t=l(function(v,s,i,a){for(i=i||{},a=v.length;a--;i[v[a]]=s);return i},"o"),e=[1,4],n=[1,13],c=[1,12],u=[1,15],h=[1,16],p=[1,20],y=[1,19],_=[6,7,8],b=[1,26],m=[1,24],w=[1,25],D=[6,7,11],J=[1,6,13,15,16,19,22],K=[1,33],Q=[1,34],A=[1,6,7,11,13,15,16,19,22],G={trace:l(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:l(function(s,i,a,o,g,r,U){var d=r.length-1;switch(g){case 6:case 7:return o;case 8:o.getLogger().trace("Stop NL ");break;case 9:o.getLogger().trace("Stop EOF ");break;case 11:o.getLogger().trace("Stop NL2 ");break;case 12:o.getLogger().trace("Stop EOF2 ");break;case 15:o.getLogger().info("Node: ",r[d].id),o.addNode(r[d-1].length,r[d].id,r[d].descr,r[d].type);break;case 16:o.getLogger().trace("Icon: ",r[d]),o.decorateNode({icon:r[d]});break;case 17:case 21:o.decorateNode({class:r[d]});break;case 18:o.getLogger().trace("SPACELIST");break;case 19:o.getLogger().trace("Node: ",r[d].id),o.addNode(0,r[d].id,r[d].descr,r[d].type);break;case 20:o.decorateNode({icon:r[d]});break;case 25:o.getLogger().trace("node found ..",r[d-2]),this.$={id:r[d-1],descr:r[d-1],type:o.getType(r[d-2],r[d])};break;case 26:this.$={id:r[d],descr:r[d],type:o.nodeType.DEFAULT};break;case 27:o.getLogger().trace("node found ..",r[d-3]),this.$={id:r[d-3],descr:r[d-1],type:o.getType(r[d-2],r[d])};break}},"anonymous"),table:[{3:1,4:2,5:3,6:[1,5],8:e},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:e},{6:n,7:[1,10],9:9,12:11,13:c,14:14,15:u,16:h,17:17,18:18,19:p,22:y},t(_,[2,3]),{1:[2,2]},t(_,[2,4]),t(_,[2,5]),{1:[2,6],6:n,12:21,13:c,14:14,15:u,16:h,17:17,18:18,19:p,22:y},{6:n,9:22,12:11,13:c,14:14,15:u,16:h,17:17,18:18,19:p,22:y},{6:b,7:m,10:23,11:w},t(D,[2,22],{17:17,18:18,14:27,15:[1,28],16:[1,29],19:p,22:y}),t(D,[2,18]),t(D,[2,19]),t(D,[2,20]),t(D,[2,21]),t(D,[2,23]),t(D,[2,24]),t(D,[2,26],{19:[1,30]}),{20:[1,31]},{6:b,7:m,10:32,11:w},{1:[2,7],6:n,12:21,13:c,14:14,15:u,16:h,17:17,18:18,19:p,22:y},t(J,[2,14],{7:K,11:Q}),t(A,[2,8]),t(A,[2,9]),t(A,[2,10]),t(D,[2,15]),t(D,[2,16]),t(D,[2,17]),{20:[1,35]},{21:[1,36]},t(J,[2,13],{7:K,11:Q}),t(A,[2,11]),t(A,[2,12]),{21:[1,37]},t(D,[2,25]),t(D,[2,27])],defaultActions:{2:[2,1],6:[2,2]},parseError:l(function(s,i){if(i.recoverable)this.trace(s);else{var a=new Error(s);throw a.hash=i,a}},"parseError"),parse:l(function(s){var i=this,a=[0],o=[],g=[null],r=[],U=this.table,d="",M=0,Z=0,re=2,ee=1,ae=r.slice.call(arguments,1),f=Object.create(this.lexer),T={yy:{}};for(var H in this.yy)Object.prototype.hasOwnProperty.call(this.yy,H)&&(T.yy[H]=this.yy[H]);f.setInput(s,T.yy),T.yy.lexer=f,T.yy.parser=this,typeof f.yylloc>"u"&&(f.yylloc={});var $=f.yylloc;r.push($);var oe=f.options&&f.options.ranges;typeof T.yy.parseError=="function"?this.parseError=T.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function ce(N){a.length=a.length-2*N,g.length=g.length-N,r.length=r.length-N}l(ce,"popStack");function te(){var N;return N=o.pop()||f.lex()||ee,typeof N!="number"&&(N instanceof Array&&(o=N,N=o.pop()),N=i.symbols_[N]||N),N}l(te,"lex");for(var S,O,k,W,C={},V,L,ie,F;;){if(O=a[a.length-1],this.defaultActions[O]?k=this.defaultActions[O]:((S===null||typeof S>"u")&&(S=te()),k=U[O]&&U[O][S]),typeof k>"u"||!k.length||!k[0]){var z="";F=[];for(V in U[O])this.terminals_[V]&&V>re&&F.push("'"+this.terminals_[V]+"'");f.showPosition?z="Parse error on line "+(M+1)+`:
2
+ `+f.showPosition()+`
3
+ Expecting `+F.join(", ")+", got '"+(this.terminals_[S]||S)+"'":z="Parse error on line "+(M+1)+": Unexpected "+(S==ee?"end of input":"'"+(this.terminals_[S]||S)+"'"),this.parseError(z,{text:f.match,token:this.terminals_[S]||S,line:f.yylineno,loc:$,expected:F})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+O+", token: "+S);switch(k[0]){case 1:a.push(S),g.push(f.yytext),r.push(f.yylloc),a.push(k[1]),S=null,Z=f.yyleng,d=f.yytext,M=f.yylineno,$=f.yylloc;break;case 2:if(L=this.productions_[k[1]][1],C.$=g[g.length-L],C._$={first_line:r[r.length-(L||1)].first_line,last_line:r[r.length-1].last_line,first_column:r[r.length-(L||1)].first_column,last_column:r[r.length-1].last_column},oe&&(C._$.range=[r[r.length-(L||1)].range[0],r[r.length-1].range[1]]),W=this.performAction.apply(C,[d,Z,M,T.yy,k[1],g,r].concat(ae)),typeof W<"u")return W;L&&(a=a.slice(0,-1*L*2),g=g.slice(0,-1*L),r=r.slice(0,-1*L)),a.push(this.productions_[k[1]][0]),g.push(C.$),r.push(C._$),ie=U[a[a.length-2]][a[a.length-1]],a.push(ie);break;case 3:return!0}}return!0},"parse")},se=(function(){var v={EOF:1,parseError:l(function(i,a){if(this.yy.parser)this.yy.parser.parseError(i,a);else throw new Error(i)},"parseError"),setInput:l(function(s,i){return this.yy=i||this.yy||{},this._input=s,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:l(function(){var s=this._input[0];this.yytext+=s,this.yyleng++,this.offset++,this.match+=s,this.matched+=s;var i=s.match(/(?:\r\n?|\n).*/g);return i?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),s},"input"),unput:l(function(s){var i=s.length,a=s.split(/(?:\r\n?|\n)/g);this._input=s+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-i),this.offset-=i;var o=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),a.length-1&&(this.yylineno-=a.length-1);var g=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:a?(a.length===o.length?this.yylloc.first_column:0)+o[o.length-a.length].length-a[0].length:this.yylloc.first_column-i},this.options.ranges&&(this.yylloc.range=[g[0],g[0]+this.yyleng-i]),this.yyleng=this.yytext.length,this},"unput"),more:l(function(){return this._more=!0,this},"more"),reject:l(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:l(function(s){this.unput(this.match.slice(s))},"less"),pastInput:l(function(){var s=this.matched.substr(0,this.matched.length-this.match.length);return(s.length>20?"...":"")+s.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:l(function(){var s=this.match;return s.length<20&&(s+=this._input.substr(0,20-s.length)),(s.substr(0,20)+(s.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:l(function(){var s=this.pastInput(),i=new Array(s.length+1).join("-");return s+this.upcomingInput()+`
5
+ `+i+"^"},"showPosition"),test_match:l(function(s,i){var a,o,g;if(this.options.backtrack_lexer&&(g={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&&(g.yylloc.range=this.yylloc.range.slice(0))),o=s[0].match(/(?:\r\n?|\n).*/g),o&&(this.yylineno+=o.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:o?o[o.length-1].length-o[o.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+s[0].length},this.yytext+=s[0],this.match+=s[0],this.matches=s,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(s[0].length),this.matched+=s[0],a=this.performAction.call(this,this.yy,this,i,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),a)return a;if(this._backtrack){for(var r in g)this[r]=g[r];return!1}return!1},"test_match"),next:l(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var s,i,a,o;this._more||(this.yytext="",this.match="");for(var g=this._currentRules(),r=0;r<g.length;r++)if(a=this._input.match(this.rules[g[r]]),a&&(!i||a[0].length>i[0].length)){if(i=a,o=r,this.options.backtrack_lexer){if(s=this.test_match(a,g[r]),s!==!1)return s;if(this._backtrack){i=!1;continue}else return!1}else if(!this.options.flex)break}return i?(s=this.test_match(i,g[o]),s!==!1?s:!1):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:l(function(){var i=this.next();return i||this.lex()},"lex"),begin:l(function(i){this.conditionStack.push(i)},"begin"),popState:l(function(){var i=this.conditionStack.length-1;return i>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:l(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:l(function(i){return i=this.conditionStack.length-1-Math.abs(i||0),i>=0?this.conditionStack[i]:"INITIAL"},"topState"),pushState:l(function(i){this.begin(i)},"pushState"),stateStackSize:l(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:l(function(i,a,o,g){switch(o){case 0:return i.getLogger().trace("Found comment",a.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:i.getLogger().trace("Begin icon"),this.begin("ICON");break;case 6:return i.getLogger().trace("SPACELINE"),6;case 7:return 7;case 8:return 15;case 9:i.getLogger().trace("end icon"),this.popState();break;case 10:return i.getLogger().trace("Exploding node"),this.begin("NODE"),19;case 11:return i.getLogger().trace("Cloud"),this.begin("NODE"),19;case 12:return i.getLogger().trace("Explosion Bang"),this.begin("NODE"),19;case 13:return i.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:i.getLogger().trace("Starting NSTR"),this.begin("NSTR");break;case 25:return i.getLogger().trace("description:",a.yytext),"NODE_DESCR";case 26:this.popState();break;case 27:return this.popState(),i.getLogger().trace("node end ))"),"NODE_DEND";case 28:return this.popState(),i.getLogger().trace("node end )"),"NODE_DEND";case 29:return this.popState(),i.getLogger().trace("node end ...",a.yytext),"NODE_DEND";case 30:return this.popState(),i.getLogger().trace("node end (("),"NODE_DEND";case 31:return this.popState(),i.getLogger().trace("node end (-"),"NODE_DEND";case 32:return this.popState(),i.getLogger().trace("node end (-"),"NODE_DEND";case 33:return this.popState(),i.getLogger().trace("node end (("),"NODE_DEND";case 34:return this.popState(),i.getLogger().trace("node end (("),"NODE_DEND";case 35:return i.getLogger().trace("Long description:",a.yytext),20;case 36:return i.getLogger().trace("Long description:",a.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}}};return v})();G.lexer=se;function P(){this.yy={}}return l(P,"Parser"),P.prototype=G,G.Parser=P,new P})();q.parser=q;var De=q,x={DEFAULT:0,NO_BORDER:0,ROUNDED_RECT:1,RECT:2,CIRCLE:3,CLOUD:4,BANG:5,HEXAGON:6},R,Ne=(R=class{constructor(){this.nodes=[],this.count=0,this.elements={},this.getLogger=this.getLogger.bind(this),this.nodeType=x,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)}clear(){this.nodes=[],this.count=0,this.elements={},this.baseLevel=void 0}getParent(e){for(let n=this.nodes.length-1;n>=0;n--)if(this.nodes[n].level<e)return this.nodes[n];return null}getMindmap(){return this.nodes.length>0?this.nodes[0]:null}addNode(e,n,c,u){var m,w;I.info("addNode",e,n,c,u);let h=!1;this.nodes.length===0?(this.baseLevel=e,e=0,h=!0):this.baseLevel!==void 0&&(e=e-this.baseLevel,h=!1);const p=X();let y=((m=p.mindmap)==null?void 0:m.padding)??j.mindmap.padding;switch(u){case this.nodeType.ROUNDED_RECT:case this.nodeType.RECT:case this.nodeType.HEXAGON:y*=2;break}const _={id:this.count++,nodeId:B(n,p),level:e,descr:B(c,p),type:u,children:[],width:((w=p.mindmap)==null?void 0:w.maxNodeWidth)??j.mindmap.maxNodeWidth,padding:y,isRoot:h},b=this.getParent(e);if(b)b.children.push(_),this.nodes.push(_);else if(h)this.nodes.push(_);else throw new Error(`There can be only one root. No parent could be found for ("${_.descr}")`)}getType(e,n){switch(I.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,n){this.elements[e]=n}getElementById(e){return this.elements[e]}decorateNode(e){if(!e)return;const n=X(),c=this.nodes[this.nodes.length-1];e.icon&&(c.icon=B(e.icon,n)),e.class&&(c.class=B(e.class,n))}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,n){if(e.level===0?e.section=void 0:e.section=n,e.children)for(const[c,u]of e.children.entries()){const h=e.level===0?c:n;this.assignSections(u,h)}}flattenNodes(e,n){const c=["mindmap-node"];e.isRoot===!0?c.push("section-root","section--1"):e.section!==void 0&&c.push(`section-${e.section}`),e.class&&c.push(e.class);const u=c.join(" "),h=l(y=>{switch(y){case x.CIRCLE:return"mindmapCircle";case x.RECT:return"rect";case x.ROUNDED_RECT:return"rounded";case x.CLOUD:return"cloud";case x.BANG:return"bang";case x.HEXAGON:return"hexagon";case x.DEFAULT:return"defaultMindmapNode";case x.NO_BORDER:default:return"rect"}},"getShapeFromType"),p={id:e.id.toString(),domId:"node_"+e.id.toString(),label:e.descr,isGroup:!1,shape:h(e.type),width:e.width,height:e.height??0,padding:e.padding,cssClasses:u,cssStyles:[],look:"default",icon:e.icon,x:e.x,y:e.y,level:e.level,nodeId:e.nodeId,type:e.type,section:e.section};if(n.push(p),e.children)for(const y of e.children)this.flattenNodes(y,n)}generateEdges(e,n){if(e.children)for(const c of e.children){let u="edge";c.section!==void 0&&(u+=` section-edge-${c.section}`);const h=e.level+1;u+=` edge-depth-${h}`;const p={id:`edge_${e.id}_${c.id}`,start:e.id.toString(),end:c.id.toString(),type:"normal",curve:"basis",thickness:"normal",look:"default",classes:u,depth:e.level,section:c.section};n.push(p),this.generateEdges(c,n)}}getData(){const e=this.getMindmap(),n=X(),u=ue().layout!==void 0,h=n;if(u||(h.layout="cose-bilkent"),!e)return{nodes:[],edges:[],config:h};I.debug("getData: mindmapRoot",e,n),this.assignSections(e);const p=[],y=[];this.flattenNodes(e,p),this.generateEdges(e,y),I.debug(`getData: processed ${p.length} nodes and ${y.length} edges`);const _=new Map;for(const b of p)_.set(b.id,{shape:b.shape,width:b.width,height:b.height,padding:b.padding});return{nodes:p,edges:y,config:h,rootNode:e,markers:["point"],direction:"TB",nodeSpacing:50,rankSpacing:50,shapes:Object.fromEntries(_),type:"mindmap",diagramId:"mindmap-"+Se()}}getLogger(){return I}},l(R,"MindmapDB"),R),ke=l(async(t,e,n,c)=>{var _,b;I.debug(`Rendering mindmap diagram
7
+ `+t);const u=c.db,h=u.getData(),p=le(e,h.config.securityLevel);h.type=c.type,h.layoutAlgorithm=de(h.config.layout,{fallback:"cose-bilkent"}),h.diagramId=e,u.getMindmap()&&(h.nodes.forEach(m=>{m.shape==="rounded"?(m.radius=15,m.taper=15,m.stroke="none",m.width=0,m.padding=15):m.shape==="circle"?m.padding=10:m.shape==="rect"&&(m.width=0,m.padding=10)}),await ge(h,p),he(p,((_=h.config.mindmap)==null?void 0:_.padding)??j.mindmap.padding,"mindmapDiagram",((b=h.config.mindmap)==null?void 0:b.useMaxWidth)??j.mindmap.useMaxWidth))},"draw"),Le={draw:ke},xe=l(t=>{let e="";for(let n=0;n<t.THEME_COLOR_LIMIT;n++)t["lineColor"+n]=t["lineColor"+n]||t["cScaleInv"+n],pe(t["lineColor"+n])?t["lineColor"+n]=fe(t["lineColor"+n],20):t["lineColor"+n]=ye(t["lineColor"+n],20);for(let n=0;n<t.THEME_COLOR_LIMIT;n++){const c=""+(17-3*n);e+=`
8
+ .section-${n-1} rect, .section-${n-1} path, .section-${n-1} circle, .section-${n-1} polygon, .section-${n-1} path {
9
+ fill: ${t["cScale"+n]};
10
+ }
11
+ .section-${n-1} text {
12
+ fill: ${t["cScaleLabel"+n]};
13
+ }
14
+ .node-icon-${n-1} {
15
+ font-size: 40px;
16
+ color: ${t["cScaleLabel"+n]};
17
+ }
18
+ .section-edge-${n-1}{
19
+ stroke: ${t["cScale"+n]};
20
+ }
21
+ .edge-depth-${n-1}{
22
+ stroke-width: ${c};
23
+ }
24
+ .section-${n-1} line {
25
+ stroke: ${t["cScaleInv"+n]} ;
26
+ stroke-width: 3;
27
+ }
28
+
29
+ .disabled, .disabled circle, .disabled text {
30
+ fill: lightgray;
31
+ }
32
+ .disabled text {
33
+ fill: #efefef;
34
+ }
35
+ `}return e},"genSections"),ve=l(t=>`
36
+ .edge {
37
+ stroke-width: 3;
38
+ }
39
+ ${xe(t)}
40
+ .section-root rect, .section-root path, .section-root circle, .section-root polygon {
41
+ fill: ${t.git0};
42
+ }
43
+ .section-root text {
44
+ fill: ${t.gitBranchLabel0};
45
+ }
46
+ .section-root span {
47
+ color: ${t.gitBranchLabel0};
48
+ }
49
+ .section-2 span {
50
+ color: ${t.gitBranchLabel0};
51
+ }
52
+ .icon-container {
53
+ height:100%;
54
+ display: flex;
55
+ justify-content: center;
56
+ align-items: center;
57
+ }
58
+ .edge {
59
+ fill: none;
60
+ }
61
+ .mindmap-node-label {
62
+ dy: 1em;
63
+ alignment-baseline: middle;
64
+ text-anchor: middle;
65
+ dominant-baseline: middle;
66
+ text-align: center;
67
+ }
68
+ `,"getStyles"),Te=ve,Re={get db(){return new Ne},renderer:Le,parser:De,styles:Te};export{Re as diagram};