agent-tower 0.7.0-beta.0 → 0.7.0-beta.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (150) hide show
  1. package/dist/runtime/acp/acp-driver.d.ts.map +1 -1
  2. package/dist/runtime/acp/acp-driver.js +25 -2
  3. package/dist/runtime/acp/acp-driver.js.map +1 -1
  4. package/dist/services/__tests__/member-heartbeat-scheduler.test.js +29 -0
  5. package/dist/services/__tests__/member-heartbeat-scheduler.test.js.map +1 -1
  6. package/dist/services/__tests__/team-member-admission-barrier.test.d.ts +2 -0
  7. package/dist/services/__tests__/team-member-admission-barrier.test.d.ts.map +1 -0
  8. package/dist/services/__tests__/team-member-admission-barrier.test.js +51 -0
  9. package/dist/services/__tests__/team-member-admission-barrier.test.js.map +1 -0
  10. package/dist/services/__tests__/team-reconciler.service.test.js +115 -0
  11. package/dist/services/__tests__/team-reconciler.service.test.js.map +1 -1
  12. package/dist/services/__tests__/team-scheduler.service.test.js +87 -0
  13. package/dist/services/__tests__/team-scheduler.service.test.js.map +1 -1
  14. package/dist/services/member-heartbeat-scheduler.d.ts +11 -0
  15. package/dist/services/member-heartbeat-scheduler.d.ts.map +1 -1
  16. package/dist/services/member-heartbeat-scheduler.js +31 -2
  17. package/dist/services/member-heartbeat-scheduler.js.map +1 -1
  18. package/dist/services/session-manager.d.ts.map +1 -1
  19. package/dist/services/session-manager.js +1 -1
  20. package/dist/services/session-manager.js.map +1 -1
  21. package/dist/services/team-member-admission-barrier.d.ts +23 -1
  22. package/dist/services/team-member-admission-barrier.d.ts.map +1 -1
  23. package/dist/services/team-member-admission-barrier.js +68 -2
  24. package/dist/services/team-member-admission-barrier.js.map +1 -1
  25. package/dist/services/team-reconciler.service.d.ts +20 -2
  26. package/dist/services/team-reconciler.service.d.ts.map +1 -1
  27. package/dist/services/team-reconciler.service.js +112 -20
  28. package/dist/services/team-reconciler.service.js.map +1 -1
  29. package/dist/services/team-scheduler.service.d.ts +7 -0
  30. package/dist/services/team-scheduler.service.d.ts.map +1 -1
  31. package/dist/services/team-scheduler.service.js +15 -5
  32. package/dist/services/team-scheduler.service.js.map +1 -1
  33. package/dist/web/assets/{AgentDemoPage-Cb99MrCc.js → AgentDemoPage-DP9u0ylA.js} +1 -1
  34. package/dist/web/assets/{AgentEnvironmentSettingsPage-ebCjwkrN.js → AgentEnvironmentSettingsPage-B571SLF5.js} +1 -1
  35. package/dist/web/assets/{AgentLogo-DonTQxM9.js → AgentLogo-VGcaaJum.js} +1 -1
  36. package/dist/web/assets/ConversationPage-CbMlQ5UC.js +3 -0
  37. package/dist/web/assets/CreateTaskInput-kkWy5nmc.js +1 -0
  38. package/dist/web/assets/{DemoPage-Bgivi3Ks.js → DemoPage-CpMV8Rv7.js} +1 -1
  39. package/dist/web/assets/{GeneralSettingsPage-DvMYB2cP.js → GeneralSettingsPage-BvME4SJc.js} +1 -1
  40. package/dist/web/assets/{Icons-CjfPc49M.js → Icons-DXzgw2xT.js} +1 -1
  41. package/dist/web/assets/{LoadingPreviewPage-CYzE_rah.js → LoadingPreviewPage-D6OzaV9-.js} +1 -1
  42. package/dist/web/assets/{McpSettingsPage-D5OEjiw4.js → McpSettingsPage-CCWuZ-IU.js} +1 -1
  43. package/dist/web/assets/{MemberAvatar-CK6Kg4RE.js → MemberAvatar-DeKYSBH9.js} +1 -1
  44. package/dist/web/assets/{NotificationSettingsPage-G7b4V0bX.js → NotificationSettingsPage-BOhJqIXv.js} +1 -1
  45. package/dist/web/assets/{ProfileSettingsPage-nKzInN5R.js → ProfileSettingsPage-BEMuDjhF.js} +1 -1
  46. package/dist/web/assets/{ProjectKanbanPage-BbRguX0a.js → ProjectKanbanPage-Ka243_RU.js} +5 -5
  47. package/dist/web/assets/{ProjectSettingsPage-B_uG_eME.js → ProjectSettingsPage-sE0Thu7d.js} +1 -1
  48. package/dist/web/assets/{ProviderSettingsPage-Yhr6QSK3.js → ProviderSettingsPage-BCXTXcbc.js} +1 -1
  49. package/dist/web/assets/{SettingsMasterDetail-fY_-qGyA.js → SettingsMasterDetail-DmqYixrL.js} +1 -1
  50. package/dist/web/assets/{TeamSettingsPage-C3bS2GiK.js → TeamSettingsPage-Dxk7-1fD.js} +1 -1
  51. package/dist/web/assets/{arc-BO0W2mHj.js → arc-Bl7tPfS7.js} +1 -1
  52. package/dist/web/assets/{architectureDiagram-3BPJPVTR-C3cEkBBe.js → architectureDiagram-3BPJPVTR-CoP7qomY.js} +1 -1
  53. package/dist/web/assets/{arrow-left-KfI6LIDH.js → arrow-left-4_9exfZH.js} +1 -1
  54. package/dist/web/assets/{blockDiagram-GPEHLZMM-DWXMs31a.js → blockDiagram-GPEHLZMM-Dyj3wCtX.js} +1 -1
  55. package/dist/web/assets/{c4Diagram-AAUBKEIU-Br4Xlw_Z.js → c4Diagram-AAUBKEIU-BHpYwHH5.js} +1 -1
  56. package/dist/web/assets/channel-D6ei4By-.js +1 -0
  57. package/dist/web/assets/check-CIGH6GLr.js +1 -0
  58. package/dist/web/assets/{chevron-down-BeBVnkqU.js → chevron-down-B8PIP1yU.js} +1 -1
  59. package/dist/web/assets/{chevron-right-Q1Dgt2I3.js → chevron-right-h-JkCAHM.js} +1 -1
  60. package/dist/web/assets/{chevron-up-D2HXcF3G.js → chevron-up-C5SQd6qy.js} +1 -1
  61. package/dist/web/assets/{chunk-2J33WTMH-BX5SFZtu.js → chunk-2J33WTMH--mm3IA_q.js} +1 -1
  62. package/dist/web/assets/{chunk-4BX2VUAB-CQvYESAm.js → chunk-4BX2VUAB-DSTjg6vT.js} +1 -1
  63. package/dist/web/assets/{chunk-55IACEB6-D9YFdDf3.js → chunk-55IACEB6-BMI8DRl6.js} +1 -1
  64. package/dist/web/assets/{chunk-727SXJPM-BUCrEURW.js → chunk-727SXJPM-DB6yt8nI.js} +1 -1
  65. package/dist/web/assets/{chunk-AQP2D5EJ-C8ERMAty.js → chunk-AQP2D5EJ-BMFO2BIQ.js} +1 -1
  66. package/dist/web/assets/{chunk-FMBD7UC4-CzEZabFM.js → chunk-FMBD7UC4-BWW53Tgv.js} +1 -1
  67. package/dist/web/assets/{chunk-ND2GUHAM-Dw35tn0f.js → chunk-ND2GUHAM-3Q1rz4Rn.js} +1 -1
  68. package/dist/web/assets/{chunk-QZHKN3VN-CR7z6_1v.js → chunk-QZHKN3VN-DHZfBhTv.js} +1 -1
  69. package/dist/web/assets/{circle-alert-Dwtt3OAP.js → circle-alert-B2WJJFVc.js} +1 -1
  70. package/dist/web/assets/classDiagram-4FO5ZUOK-Dy0gEbpJ.js +1 -0
  71. package/dist/web/assets/classDiagram-v2-Q7XG4LA2-Dy0gEbpJ.js +1 -0
  72. package/dist/web/assets/{code-block-OCS4YCEC-CAzJ3mQn.js → code-block-OCS4YCEC-DAvNvPo_.js} +1 -1
  73. package/dist/web/assets/{confirm-dialog-BcfJ2Xus.js → confirm-dialog-59aNupkb.js} +1 -1
  74. package/dist/web/assets/{cose-bilkent-S5V4N54A-CUXR9dk3.js → cose-bilkent-S5V4N54A-BkBXPAOW.js} +1 -1
  75. package/dist/web/assets/{cssMode-BpC8I4Ek.js → cssMode-r4PsUEeI.js} +1 -1
  76. package/dist/web/assets/{dagre-BM42HDAG-Dhy7S5s1.js → dagre-BM42HDAG-0o3tAN58.js} +1 -1
  77. package/dist/web/assets/{diagram-2AECGRRQ-DIR5PGZF.js → diagram-2AECGRRQ-BaozWVAC.js} +1 -1
  78. package/dist/web/assets/{diagram-5GNKFQAL-DzXKfh_N.js → diagram-5GNKFQAL-BQGxsEX-.js} +1 -1
  79. package/dist/web/assets/{diagram-KO2AKTUF-us7dQ7xA.js → diagram-KO2AKTUF-BhOfCrvE.js} +1 -1
  80. package/dist/web/assets/{diagram-LMA3HP47-BjK9ExKN.js → diagram-LMA3HP47-1C0Ajian.js} +1 -1
  81. package/dist/web/assets/{diagram-OG6HWLK6-BTx88v4L.js → diagram-OG6HWLK6-BZsvylQi.js} +1 -1
  82. package/dist/web/assets/{erDiagram-TEJ5UH35-8rgd6uCk.js → erDiagram-TEJ5UH35-BODPoCQX.js} +1 -1
  83. package/dist/web/assets/{flowDiagram-I6XJVG4X-C47DsydX.js → flowDiagram-I6XJVG4X-B0BsMsro.js} +1 -1
  84. package/dist/web/assets/{folder-picker-NzVodD5j.js → folder-picker-B5RdK3CX.js} +1 -1
  85. package/dist/web/assets/{freemarker2-Gzu5EJMh.js → freemarker2-B62GnwxO.js} +1 -1
  86. package/dist/web/assets/{ganttDiagram-6RSMTGT7-B7qxtFDa.js → ganttDiagram-6RSMTGT7-BsXOoMru.js} +1 -1
  87. package/dist/web/assets/{gitGraphDiagram-PVQCEYII-DtXsV-rD.js → gitGraphDiagram-PVQCEYII-DVuq4oVA.js} +1 -1
  88. package/dist/web/assets/{handlebars-3Znn7m4J.js → handlebars-BBm4KBDp.js} +1 -1
  89. package/dist/web/assets/{html-Dgt18Ofs.js → html-BlMJourI.js} +1 -1
  90. package/dist/web/assets/{htmlMode-C2t1O0sW.js → htmlMode-vGjPTlal.js} +1 -1
  91. package/dist/web/assets/{index-BVh0eL1_.js → index-BziFEuBL.js} +4 -4
  92. package/dist/web/assets/{index--1agBpnq.js → index-DfRNL5pP.js} +4 -4
  93. package/dist/web/assets/index-KjsBZlkg.css +1 -0
  94. package/dist/web/assets/{infoDiagram-5YYISTIA-AQRMJJ6t.js → infoDiagram-5YYISTIA-CkI-s2fN.js} +1 -1
  95. package/dist/web/assets/{ishikawaDiagram-YF4QCWOH-CTcfBywF.js → ishikawaDiagram-YF4QCWOH-DExbu0jt.js} +1 -1
  96. package/dist/web/assets/javascript-CnnNs3bZ.js +1 -0
  97. package/dist/web/assets/{journeyDiagram-JHISSGLW-CRv0PNLh.js → journeyDiagram-JHISSGLW-C03_8hib.js} +1 -1
  98. package/dist/web/assets/{jsonMode-DQPoQ9kR.js → jsonMode-SxmrKu-q.js} +1 -1
  99. package/dist/web/assets/{kanban-definition-UN3LZRKU-AcoPh0xh.js → kanban-definition-UN3LZRKU-CkQ5JqTm.js} +1 -1
  100. package/dist/web/assets/{layers-DePAliGw.js → layers-DVjF8vaY.js} +1 -1
  101. package/dist/web/assets/{linear-GlxaBVoM.js → linear-VXyesiU2.js} +1 -1
  102. package/dist/web/assets/{liquid-Dr6EmgCe.js → liquid-B_CJMcDS.js} +1 -1
  103. package/dist/web/assets/{lspLanguageFeatures-DN91604C.js → lspLanguageFeatures-D46XQnYj.js} +1 -1
  104. package/dist/web/assets/{mdx-JG8OT2YG.js → mdx-B2i6poYS.js} +1 -1
  105. package/dist/web/assets/mermaid-NOHMQCX5-Cxj8y3xL.js +125 -0
  106. package/dist/web/assets/{message-square-DWgJpKCx.js → message-square-BleDaJqD.js} +1 -1
  107. package/dist/web/assets/{mindmap-definition-RKZ34NQL-DGrhHpUO.js → mindmap-definition-RKZ34NQL-OB13sryT.js} +1 -1
  108. package/dist/web/assets/{modal-CORyqdln.js → modal-DCycqy3L.js} +1 -1
  109. package/dist/web/assets/{monaco-ORn-kQwM.js → monaco-C5uCiSc1.js} +3 -3
  110. package/dist/web/assets/{pencil-B1BeYe1f.js → pencil-7Lu7CiFO.js} +1 -1
  111. package/dist/web/assets/{pieDiagram-4H26LBE5-BX2kHm8X.js → pieDiagram-4H26LBE5-CU-pnTSj.js} +1 -1
  112. package/dist/web/assets/{python-v-kAqpdQ.js → python-CdqaVxbU.js} +1 -1
  113. package/dist/web/assets/{quadrantDiagram-W4KKPZXB-D8kpdSHK.js → quadrantDiagram-W4KKPZXB-yZ7s-n8V.js} +1 -1
  114. package/dist/web/assets/{razor-1mzCjQ7_.js → razor-BZtfxDHk.js} +1 -1
  115. package/dist/web/assets/{requirementDiagram-4Y6WPE33-BeCKrFYk.js → requirementDiagram-4Y6WPE33-B0anLb96.js} +1 -1
  116. package/dist/web/assets/{sankeyDiagram-5OEKKPKP-BhppOHK-.js → sankeyDiagram-5OEKKPKP-DHcV9eve.js} +1 -1
  117. package/dist/web/assets/{select-C0_GwcaL.js → select-EnAkHFwg.js} +1 -1
  118. package/dist/web/assets/{sequenceDiagram-3UESZ5HK-kd48NbrY.js → sequenceDiagram-3UESZ5HK-DqgRRD9W.js} +1 -1
  119. package/dist/web/assets/{server-ezmEd1Bn.js → server-a_4ZRCwE.js} +1 -1
  120. package/dist/web/assets/{stateDiagram-AJRCARHV-BVEJJ862.js → stateDiagram-AJRCARHV-BM_vAe4X.js} +1 -1
  121. package/dist/web/assets/stateDiagram-v2-BHNVJYJU-DXSW0BBn.js +1 -0
  122. package/dist/web/assets/{switch-DTs2bsdf.js → switch-D_UoJD1K.js} +1 -1
  123. package/dist/web/assets/{textarea-DDugro1C.js → textarea-Cmy7-X_E.js} +1 -1
  124. package/dist/web/assets/{timeline-definition-PNZ67QCA-DSTFfNuv.js → timeline-definition-PNZ67QCA-BRstBzgi.js} +1 -1
  125. package/dist/web/assets/{trash-2-0qxC5GZF.js → trash-2-0UA8zJ8I.js} +1 -1
  126. package/dist/web/assets/{tsMode-BiIcawoi.js → tsMode-BASXySxT.js} +1 -1
  127. package/dist/web/assets/{typescript-ChINO0ge.js → typescript-DbOfWuuq.js} +1 -1
  128. package/dist/web/assets/{upload-Bvn4pVZf.js → upload-CfzBeWxL.js} +1 -1
  129. package/dist/web/assets/{use-profiles-DQpUUzXs.js → use-profiles-MVQfFrhT.js} +1 -1
  130. package/dist/web/assets/{use-projects-BQB2BPEN.js → use-projects-CJ8Wn6Xl.js} +1 -1
  131. package/dist/web/assets/{use-providers--I6m_J5h.js → use-providers-DvV0mdqo.js} +1 -1
  132. package/dist/web/assets/{useNormalizedLogs-BB31QSMo.js → useNormalizedLogs-D8-yjxOI.js} +1 -1
  133. package/dist/web/assets/{vennDiagram-CIIHVFJN-CQ8tm8nY.js → vennDiagram-CIIHVFJN-DzhupKpF.js} +1 -1
  134. package/dist/web/assets/{wardley-L42UT6IY-DKg1J16d.js → wardley-L42UT6IY-BwWhS3dk.js} +1 -1
  135. package/dist/web/assets/{wardleyDiagram-YWT4CUSO-DnqGz1sa.js → wardleyDiagram-YWT4CUSO-iG6xXnIJ.js} +1 -1
  136. package/dist/web/assets/{xml-YFMD1O7m.js → xml-Dn2Ep0JI.js} +1 -1
  137. package/dist/web/assets/{xychartDiagram-2RQKCTM6-BTCVgq8k.js → xychartDiagram-2RQKCTM6-hgKK9aU8.js} +1 -1
  138. package/dist/web/assets/{yaml-pAIxoEG3.js → yaml-CA2Cgl3R.js} +1 -1
  139. package/dist/web/index.html +2 -2
  140. package/package.json +1 -1
  141. package/dist/web/assets/ConversationPage-Bd1WHiCB.js +0 -3
  142. package/dist/web/assets/CreateTaskInput-C9aO7QVE.js +0 -1
  143. package/dist/web/assets/channel-TREDjZBM.js +0 -1
  144. package/dist/web/assets/check-VbbiSgv8.js +0 -1
  145. package/dist/web/assets/classDiagram-4FO5ZUOK-C8tJPglt.js +0 -1
  146. package/dist/web/assets/classDiagram-v2-Q7XG4LA2-C8tJPglt.js +0 -1
  147. package/dist/web/assets/index-CVgeXPf_.css +0 -1
  148. package/dist/web/assets/javascript-BfysNn1k.js +0 -1
  149. package/dist/web/assets/mermaid-NOHMQCX5-Cc97ICqZ.js +0 -122
  150. package/dist/web/assets/stateDiagram-v2-BHNVJYJU-aOH6_7W_.js +0 -1
@@ -1,4 +1,4 @@
1
- import{_ as o,D as pt,ac as Ct,ad as Rt,ae as Wt,c as gt,l as E,I as Pt,N as Bt,af as ft,d as X,C as Vt,ag as Ft,z as zt}from"./index--1agBpnq.js";import{d as ot}from"./arc-BO0W2mHj.js";import"./index-BVh0eL1_.js";var tt=(function(){var e=o(function(k,s,d,l){for(d=d||{},l=k.length;l--;d[k[l]]=s);return d},"o"),t=[6,11,13,14,15,17,19,20,23,24],n=[1,12],i=[1,13],r=[1,14],h=[1,15],c=[1,16],a=[1,19],f=[1,20],g={trace:o(function(){},"trace"),yy:{},symbols_:{error:2,start:3,timeline_header:4,document:5,EOF:6,timeline:7,timeline_lr:8,timeline_td:9,line:10,SPACE:11,statement:12,NEWLINE:13,title:14,acc_title:15,acc_title_value:16,acc_descr:17,acc_descr_value:18,acc_descr_multiline_value:19,section:20,period_statement:21,event_statement:22,period:23,event:24,$accept:0,$end:1},terminals_:{2:"error",6:"EOF",7:"timeline",8:"timeline_lr",9:"timeline_td",11:"SPACE",13:"NEWLINE",14:"title",15:"acc_title",16:"acc_title_value",17:"acc_descr",18:"acc_descr_value",19:"acc_descr_multiline_value",20:"section",23:"period",24:"event"},productions_:[0,[3,3],[4,1],[4,1],[4,1],[5,0],[5,2],[10,2],[10,1],[10,1],[10,1],[12,1],[12,2],[12,2],[12,1],[12,1],[12,1],[12,1],[21,1],[22,1]],performAction:o(function(s,d,l,p,x,u,S){var v=u.length-1;switch(x){case 1:return u[v-1];case 3:p.setDirection("LR");break;case 4:p.setDirection("TD");break;case 5:this.$=[];break;case 6:u[v-1].push(u[v]),this.$=u[v-1];break;case 7:case 8:this.$=u[v];break;case 9:case 10:this.$=[];break;case 11:p.getCommonDb().setDiagramTitle(u[v].substr(6)),this.$=u[v].substr(6);break;case 12:this.$=u[v].trim(),p.getCommonDb().setAccTitle(this.$);break;case 13:case 14:this.$=u[v].trim(),p.getCommonDb().setAccDescription(this.$);break;case 15:p.addSection(u[v].substr(8)),this.$=u[v].substr(8);break;case 18:p.addTask(u[v],0,""),this.$=u[v];break;case 19:p.addEvent(u[v].substr(2)),this.$=u[v];break}},"anonymous"),table:[{3:1,4:2,7:[1,3],8:[1,4],9:[1,5]},{1:[3]},e(t,[2,5],{5:6}),e(t,[2,2]),e(t,[2,3]),e(t,[2,4]),{6:[1,7],10:8,11:[1,9],12:10,13:[1,11],14:n,15:i,17:r,19:h,20:c,21:17,22:18,23:a,24:f},e(t,[2,10],{1:[2,1]}),e(t,[2,6]),{12:21,14:n,15:i,17:r,19:h,20:c,21:17,22:18,23:a,24:f},e(t,[2,8]),e(t,[2,9]),e(t,[2,11]),{16:[1,22]},{18:[1,23]},e(t,[2,14]),e(t,[2,15]),e(t,[2,16]),e(t,[2,17]),e(t,[2,18]),e(t,[2,19]),e(t,[2,7]),e(t,[2,12]),e(t,[2,13])],defaultActions:{},parseError:o(function(s,d){if(d.recoverable)this.trace(s);else{var l=new Error(s);throw l.hash=d,l}},"parseError"),parse:o(function(s){var d=this,l=[0],p=[],x=[null],u=[],S=this.table,v="",I=0,C=0,W=2,O=1,L=u.slice.call(arguments,1),w=Object.create(this.lexer),H={yy:{}};for(var V in this.yy)Object.prototype.hasOwnProperty.call(this.yy,V)&&(H.yy[V]=this.yy[V]);w.setInput(s,H.yy),H.yy.lexer=w,H.yy.parser=this,typeof w.yylloc>"u"&&(w.yylloc={});var F=w.yylloc;u.push(F);var U=w.options&&w.options.ranges;typeof H.yy.parseError=="function"?this.parseError=H.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function N(A){l.length=l.length-2*A,x.length=x.length-A,u.length=u.length-A}o(N,"popStack");function b(){var A;return A=p.pop()||w.lex()||O,typeof A!="number"&&(A instanceof Array&&(p=A,A=p.pop()),A=d.symbols_[A]||A),A}o(b,"lex");for(var _,$,T,P,R={},G,B,Z,j;;){if($=l[l.length-1],this.defaultActions[$]?T=this.defaultActions[$]:((_===null||typeof _>"u")&&(_=b()),T=S[$]&&S[$][_]),typeof T>"u"||!T.length||!T[0]){var Y="";j=[];for(G in S[$])this.terminals_[G]&&G>W&&j.push("'"+this.terminals_[G]+"'");w.showPosition?Y="Parse error on line "+(I+1)+`:
1
+ import{_ as o,D as pt,ac as Ct,ad as Rt,ae as Wt,c as gt,l as E,I as Pt,N as Bt,af as ft,d as X,C as Vt,ag as Ft,z as zt}from"./index-DfRNL5pP.js";import{d as ot}from"./arc-Bl7tPfS7.js";import"./index-BziFEuBL.js";var tt=(function(){var e=o(function(k,s,d,l){for(d=d||{},l=k.length;l--;d[k[l]]=s);return d},"o"),t=[6,11,13,14,15,17,19,20,23,24],n=[1,12],i=[1,13],r=[1,14],h=[1,15],c=[1,16],a=[1,19],f=[1,20],g={trace:o(function(){},"trace"),yy:{},symbols_:{error:2,start:3,timeline_header:4,document:5,EOF:6,timeline:7,timeline_lr:8,timeline_td:9,line:10,SPACE:11,statement:12,NEWLINE:13,title:14,acc_title:15,acc_title_value:16,acc_descr:17,acc_descr_value:18,acc_descr_multiline_value:19,section:20,period_statement:21,event_statement:22,period:23,event:24,$accept:0,$end:1},terminals_:{2:"error",6:"EOF",7:"timeline",8:"timeline_lr",9:"timeline_td",11:"SPACE",13:"NEWLINE",14:"title",15:"acc_title",16:"acc_title_value",17:"acc_descr",18:"acc_descr_value",19:"acc_descr_multiline_value",20:"section",23:"period",24:"event"},productions_:[0,[3,3],[4,1],[4,1],[4,1],[5,0],[5,2],[10,2],[10,1],[10,1],[10,1],[12,1],[12,2],[12,2],[12,1],[12,1],[12,1],[12,1],[21,1],[22,1]],performAction:o(function(s,d,l,p,x,u,S){var v=u.length-1;switch(x){case 1:return u[v-1];case 3:p.setDirection("LR");break;case 4:p.setDirection("TD");break;case 5:this.$=[];break;case 6:u[v-1].push(u[v]),this.$=u[v-1];break;case 7:case 8:this.$=u[v];break;case 9:case 10:this.$=[];break;case 11:p.getCommonDb().setDiagramTitle(u[v].substr(6)),this.$=u[v].substr(6);break;case 12:this.$=u[v].trim(),p.getCommonDb().setAccTitle(this.$);break;case 13:case 14:this.$=u[v].trim(),p.getCommonDb().setAccDescription(this.$);break;case 15:p.addSection(u[v].substr(8)),this.$=u[v].substr(8);break;case 18:p.addTask(u[v],0,""),this.$=u[v];break;case 19:p.addEvent(u[v].substr(2)),this.$=u[v];break}},"anonymous"),table:[{3:1,4:2,7:[1,3],8:[1,4],9:[1,5]},{1:[3]},e(t,[2,5],{5:6}),e(t,[2,2]),e(t,[2,3]),e(t,[2,4]),{6:[1,7],10:8,11:[1,9],12:10,13:[1,11],14:n,15:i,17:r,19:h,20:c,21:17,22:18,23:a,24:f},e(t,[2,10],{1:[2,1]}),e(t,[2,6]),{12:21,14:n,15:i,17:r,19:h,20:c,21:17,22:18,23:a,24:f},e(t,[2,8]),e(t,[2,9]),e(t,[2,11]),{16:[1,22]},{18:[1,23]},e(t,[2,14]),e(t,[2,15]),e(t,[2,16]),e(t,[2,17]),e(t,[2,18]),e(t,[2,19]),e(t,[2,7]),e(t,[2,12]),e(t,[2,13])],defaultActions:{},parseError:o(function(s,d){if(d.recoverable)this.trace(s);else{var l=new Error(s);throw l.hash=d,l}},"parseError"),parse:o(function(s){var d=this,l=[0],p=[],x=[null],u=[],S=this.table,v="",I=0,C=0,W=2,O=1,L=u.slice.call(arguments,1),w=Object.create(this.lexer),H={yy:{}};for(var V in this.yy)Object.prototype.hasOwnProperty.call(this.yy,V)&&(H.yy[V]=this.yy[V]);w.setInput(s,H.yy),H.yy.lexer=w,H.yy.parser=this,typeof w.yylloc>"u"&&(w.yylloc={});var F=w.yylloc;u.push(F);var U=w.options&&w.options.ranges;typeof H.yy.parseError=="function"?this.parseError=H.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function N(A){l.length=l.length-2*A,x.length=x.length-A,u.length=u.length-A}o(N,"popStack");function b(){var A;return A=p.pop()||w.lex()||O,typeof A!="number"&&(A instanceof Array&&(p=A,A=p.pop()),A=d.symbols_[A]||A),A}o(b,"lex");for(var _,$,T,P,R={},G,B,Z,j;;){if($=l[l.length-1],this.defaultActions[$]?T=this.defaultActions[$]:((_===null||typeof _>"u")&&(_=b()),T=S[$]&&S[$][_]),typeof T>"u"||!T.length||!T[0]){var Y="";j=[];for(G in S[$])this.terminals_[G]&&G>W&&j.push("'"+this.terminals_[G]+"'");w.showPosition?Y="Parse error on line "+(I+1)+`:
2
2
  `+w.showPosition()+`
3
3
  Expecting `+j.join(", ")+", got '"+(this.terminals_[_]||_)+"'":Y="Parse error on line "+(I+1)+": Unexpected "+(_==O?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(Y,{text:w.match,token:this.terminals_[_]||_,line:w.yylineno,loc:F,expected:j})}if(T[0]instanceof Array&&T.length>1)throw new Error("Parse Error: multiple actions possible at state: "+$+", token: "+_);switch(T[0]){case 1:l.push(_),x.push(w.yytext),u.push(w.yylloc),l.push(T[1]),_=null,C=w.yyleng,v=w.yytext,I=w.yylineno,F=w.yylloc;break;case 2:if(B=this.productions_[T[1]][1],R.$=x[x.length-B],R._$={first_line:u[u.length-(B||1)].first_line,last_line:u[u.length-1].last_line,first_column:u[u.length-(B||1)].first_column,last_column:u[u.length-1].last_column},U&&(R._$.range=[u[u.length-(B||1)].range[0],u[u.length-1].range[1]]),P=this.performAction.apply(R,[v,C,I,H.yy,T[1],x,u].concat(L)),typeof P<"u")return P;B&&(l=l.slice(0,-1*B*2),x=x.slice(0,-1*B),u=u.slice(0,-1*B)),l.push(this.productions_[T[1]][0]),x.push(R.$),u.push(R._$),Z=S[l[l.length-2]][l[l.length-1]],l.push(Z);break;case 3:return!0}}return!0},"parse")},m=(function(){var k={EOF:1,parseError:o(function(d,l){if(this.yy.parser)this.yy.parser.parseError(d,l);else throw new Error(d)},"parseError"),setInput:o(function(s,d){return this.yy=d||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:o(function(){var s=this._input[0];this.yytext+=s,this.yyleng++,this.offset++,this.match+=s,this.matched+=s;var d=s.match(/(?:\r\n?|\n).*/g);return d?(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:o(function(s){var d=s.length,l=s.split(/(?:\r\n?|\n)/g);this._input=s+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-d),this.offset-=d;var p=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),l.length-1&&(this.yylineno-=l.length-1);var x=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:l?(l.length===p.length?this.yylloc.first_column:0)+p[p.length-l.length].length-l[0].length:this.yylloc.first_column-d},this.options.ranges&&(this.yylloc.range=[x[0],x[0]+this.yyleng-d]),this.yyleng=this.yytext.length,this},"unput"),more:o(function(){return this._more=!0,this},"more"),reject:o(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
4
  `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:o(function(s){this.unput(this.match.slice(s))},"less"),pastInput:o(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:o(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:o(function(){var s=this.pastInput(),d=new Array(s.length+1).join("-");return s+this.upcomingInput()+`
@@ -1 +1 @@
1
- import{k as a}from"./index-BVh0eL1_.js";const t=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],h=a("plus",t);const e=[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]],s=a("trash-2",e);export{h as P,s as T};
1
+ import{k as a}from"./index-BziFEuBL.js";const t=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],h=a("plus",t);const e=[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]],s=a("trash-2",e);export{h as P,s as T};
@@ -1,4 +1,4 @@
1
- import{c as M,e as w,U as F,a as P,M as v,l as f,t as K,R as O}from"./monaco-ORn-kQwM.js";import"./ProjectKanbanPage-BbRguX0a.js";import"./index-BVh0eL1_.js";import"./mermaid-NOHMQCX5-Cc97ICqZ.js";import"./chevron-right-Q1Dgt2I3.js";import"./chevron-down-BeBVnkqU.js";import"./confirm-dialog-BcfJ2Xus.js";import"./modal-CORyqdln.js";import"./Icons-CjfPc49M.js";import"./CreateTaskInput-C9aO7QVE.js";import"./AgentLogo-DonTQxM9.js";import"./check-VbbiSgv8.js";import"./use-projects-BQB2BPEN.js";import"./MemberAvatar-CK6Kg4RE.js";import"./use-providers--I6m_J5h.js";import"./trash-2-0qxC5GZF.js";import"./useNormalizedLogs-BB31QSMo.js";import"./folder-picker-NzVodD5j.js";import"./circle-alert-Dwtt3OAP.js";import"./message-square-DWgJpKCx.js";import"./layers-DePAliGw.js";import"./chevron-up-D2HXcF3G.js";import"./select-C0_GwcaL.js";import"./textarea-DDugro1C.js";import"./server-ezmEd1Bn.js";import"./upload-Bvn4pVZf.js";import"./arrow-left-KfI6LIDH.js";import"./pencil-B1BeYe1f.js";class E{constructor(e,t){this._modeId=e,this._defaults=t,this._worker=null,this._client=null,this._configChangeListener=this._defaults.onDidChange(()=>this._stopWorker()),this._updateExtraLibsToken=0,this._extraLibsChangeListener=this._defaults.onDidExtraLibsChange(()=>this._updateExtraLibs())}dispose(){this._configChangeListener.dispose(),this._extraLibsChangeListener.dispose(),this._stopWorker()}_stopWorker(){this._worker&&(this._worker.dispose(),this._worker=null),this._client=null}async _updateExtraLibs(){if(!this._worker)return;const e=++this._updateExtraLibsToken,t=await this._worker.getProxy();this._updateExtraLibsToken===e&&t.updateExtraLibs(this._defaults.getExtraLibs())}_getClient(){return this._client||(this._client=(async()=>(this._worker=M({moduleId:"vs/language/typescript/tsWorker",createWorker:()=>new Worker(new URL("/assets/ts.worker-BH9nVgjN.js",import.meta.url),{type:"module"}),label:this._modeId,keepIdleModels:!0,createData:{compilerOptions:this._defaults.getCompilerOptions(),extraLibs:this._defaults.getExtraLibs(),customWorkerPath:this._defaults.workerOptions.customWorkerPath,inlayHintsOptions:this._defaults.inlayHintsOptions}}),this._defaults.getEagerModelSync()?await this._worker.withSyncedResources(w.getModels().filter(e=>e.getLanguageId()===this._modeId).map(e=>e.uri)):await this._worker.getProxy()))()),this._client}async getLanguageServiceWorker(...e){const t=await this._getClient();return this._worker&&await this._worker.withSyncedResources(e),t}}const s={};s["lib.d.ts"]=!0;s["lib.decorators.d.ts"]=!0;s["lib.decorators.legacy.d.ts"]=!0;s["lib.dom.asynciterable.d.ts"]=!0;s["lib.dom.d.ts"]=!0;s["lib.dom.iterable.d.ts"]=!0;s["lib.es2015.collection.d.ts"]=!0;s["lib.es2015.core.d.ts"]=!0;s["lib.es2015.d.ts"]=!0;s["lib.es2015.generator.d.ts"]=!0;s["lib.es2015.iterable.d.ts"]=!0;s["lib.es2015.promise.d.ts"]=!0;s["lib.es2015.proxy.d.ts"]=!0;s["lib.es2015.reflect.d.ts"]=!0;s["lib.es2015.symbol.d.ts"]=!0;s["lib.es2015.symbol.wellknown.d.ts"]=!0;s["lib.es2016.array.include.d.ts"]=!0;s["lib.es2016.d.ts"]=!0;s["lib.es2016.full.d.ts"]=!0;s["lib.es2016.intl.d.ts"]=!0;s["lib.es2017.arraybuffer.d.ts"]=!0;s["lib.es2017.d.ts"]=!0;s["lib.es2017.date.d.ts"]=!0;s["lib.es2017.full.d.ts"]=!0;s["lib.es2017.intl.d.ts"]=!0;s["lib.es2017.object.d.ts"]=!0;s["lib.es2017.sharedmemory.d.ts"]=!0;s["lib.es2017.string.d.ts"]=!0;s["lib.es2017.typedarrays.d.ts"]=!0;s["lib.es2018.asyncgenerator.d.ts"]=!0;s["lib.es2018.asynciterable.d.ts"]=!0;s["lib.es2018.d.ts"]=!0;s["lib.es2018.full.d.ts"]=!0;s["lib.es2018.intl.d.ts"]=!0;s["lib.es2018.promise.d.ts"]=!0;s["lib.es2018.regexp.d.ts"]=!0;s["lib.es2019.array.d.ts"]=!0;s["lib.es2019.d.ts"]=!0;s["lib.es2019.full.d.ts"]=!0;s["lib.es2019.intl.d.ts"]=!0;s["lib.es2019.object.d.ts"]=!0;s["lib.es2019.string.d.ts"]=!0;s["lib.es2019.symbol.d.ts"]=!0;s["lib.es2020.bigint.d.ts"]=!0;s["lib.es2020.d.ts"]=!0;s["lib.es2020.date.d.ts"]=!0;s["lib.es2020.full.d.ts"]=!0;s["lib.es2020.intl.d.ts"]=!0;s["lib.es2020.number.d.ts"]=!0;s["lib.es2020.promise.d.ts"]=!0;s["lib.es2020.sharedmemory.d.ts"]=!0;s["lib.es2020.string.d.ts"]=!0;s["lib.es2020.symbol.wellknown.d.ts"]=!0;s["lib.es2021.d.ts"]=!0;s["lib.es2021.full.d.ts"]=!0;s["lib.es2021.intl.d.ts"]=!0;s["lib.es2021.promise.d.ts"]=!0;s["lib.es2021.string.d.ts"]=!0;s["lib.es2021.weakref.d.ts"]=!0;s["lib.es2022.array.d.ts"]=!0;s["lib.es2022.d.ts"]=!0;s["lib.es2022.error.d.ts"]=!0;s["lib.es2022.full.d.ts"]=!0;s["lib.es2022.intl.d.ts"]=!0;s["lib.es2022.object.d.ts"]=!0;s["lib.es2022.regexp.d.ts"]=!0;s["lib.es2022.string.d.ts"]=!0;s["lib.es2023.array.d.ts"]=!0;s["lib.es2023.collection.d.ts"]=!0;s["lib.es2023.d.ts"]=!0;s["lib.es2023.full.d.ts"]=!0;s["lib.es2023.intl.d.ts"]=!0;s["lib.es2024.arraybuffer.d.ts"]=!0;s["lib.es2024.collection.d.ts"]=!0;s["lib.es2024.d.ts"]=!0;s["lib.es2024.full.d.ts"]=!0;s["lib.es2024.object.d.ts"]=!0;s["lib.es2024.promise.d.ts"]=!0;s["lib.es2024.regexp.d.ts"]=!0;s["lib.es2024.sharedmemory.d.ts"]=!0;s["lib.es2024.string.d.ts"]=!0;s["lib.es5.d.ts"]=!0;s["lib.es6.d.ts"]=!0;s["lib.esnext.array.d.ts"]=!0;s["lib.esnext.collection.d.ts"]=!0;s["lib.esnext.d.ts"]=!0;s["lib.esnext.decorators.d.ts"]=!0;s["lib.esnext.disposable.d.ts"]=!0;s["lib.esnext.error.d.ts"]=!0;s["lib.esnext.float16.d.ts"]=!0;s["lib.esnext.full.d.ts"]=!0;s["lib.esnext.intl.d.ts"]=!0;s["lib.esnext.iterator.d.ts"]=!0;s["lib.esnext.promise.d.ts"]=!0;s["lib.esnext.sharedmemory.d.ts"]=!0;s["lib.scripthost.d.ts"]=!0;s["lib.webworker.asynciterable.d.ts"]=!0;s["lib.webworker.d.ts"]=!0;s["lib.webworker.importscripts.d.ts"]=!0;s["lib.webworker.iterable.d.ts"]=!0;function A(c,e,t=0){if(typeof c=="string")return c;if(c===void 0)return"";let o="";if(t){o+=e;for(let i=0;i<t;i++)o+=" "}if(o+=c.messageText,t++,c.next)for(const i of c.next)o+=A(i,e,t);return o}function _(c){return c?c.map(e=>e.text).join(""):""}class y{constructor(e){this._worker=e}_textSpanToRange(e,t){let o=e.getPositionAt(t.start),i=e.getPositionAt(t.start+t.length),{lineNumber:l,column:p}=o,{lineNumber:n,column:r}=i;return{startLineNumber:l,startColumn:p,endLineNumber:n,endColumn:r}}}class H{constructor(e){this._worker=e,this._libFiles={},this._hasFetchedLibFiles=!1,this._fetchLibFilesPromise=null}isLibFile(e){return e&&e.path.indexOf("/lib.")===0?!!s[e.path.slice(1)]:!1}getOrCreateModel(e){const t=F.parse(e),o=w.getModel(t);if(o)return o;if(this.isLibFile(t)&&this._hasFetchedLibFiles)return w.createModel(this._libFiles[t.path.slice(1)],"typescript",t);const i=K.getExtraLibs()[e];return i?w.createModel(i.content,"typescript",t):null}_containsLibFile(e){for(let t of e)if(this.isLibFile(t))return!0;return!1}async fetchLibFilesIfNecessary(e){this._containsLibFile(e)&&await this._fetchLibFiles()}_fetchLibFiles(){return this._fetchLibFilesPromise||(this._fetchLibFilesPromise=this._worker().then(e=>e.getLibFiles()).then(e=>{this._hasFetchedLibFiles=!0,this._libFiles=e})),this._fetchLibFilesPromise}}class V extends y{constructor(e,t,o,i){super(i),this._libFiles=e,this._defaults=t,this._selector=o,this._disposables=[],this._listener=Object.create(null);const l=r=>{if(r.getLanguageId()!==o)return;const u=()=>{const{onlyVisible:m}=this._defaults.getDiagnosticsOptions();m?r.isAttachedToEditor()&&this._doValidate(r):this._doValidate(r)};let d;const g=r.onDidChangeContent(()=>{clearTimeout(d),d=window.setTimeout(u,500)}),b=r.onDidChangeAttached(()=>{const{onlyVisible:m}=this._defaults.getDiagnosticsOptions();m&&(r.isAttachedToEditor()?u():w.setModelMarkers(r,this._selector,[]))});this._listener[r.uri.toString()]={dispose(){g.dispose(),b.dispose(),clearTimeout(d)}},u()},p=r=>{w.setModelMarkers(r,this._selector,[]);const u=r.uri.toString();this._listener[u]&&(this._listener[u].dispose(),delete this._listener[u])};this._disposables.push(w.onDidCreateModel(r=>l(r))),this._disposables.push(w.onWillDisposeModel(p)),this._disposables.push(w.onDidChangeModelLanguage(r=>{p(r.model),l(r.model)})),this._disposables.push({dispose(){for(const r of w.getModels())p(r)}});const n=()=>{for(const r of w.getModels())p(r),l(r)};this._disposables.push(this._defaults.onDidChange(n)),this._disposables.push(this._defaults.onDidExtraLibsChange(n)),w.getModels().forEach(r=>l(r))}dispose(){this._disposables.forEach(e=>e&&e.dispose()),this._disposables=[]}async _doValidate(e){const t=await this._worker(e.uri);if(e.isDisposed())return;const o=[],{noSyntaxValidation:i,noSemanticValidation:l,noSuggestionDiagnostics:p}=this._defaults.getDiagnosticsOptions();i||o.push(t.getSyntacticDiagnostics(e.uri.toString())),l||o.push(t.getSemanticDiagnostics(e.uri.toString())),p||o.push(t.getSuggestionDiagnostics(e.uri.toString()));const n=await Promise.all(o);if(!n||e.isDisposed())return;const r=n.reduce((d,g)=>g.concat(d),[]).filter(d=>(this._defaults.getDiagnosticsOptions().diagnosticCodesToIgnore||[]).indexOf(d.code)===-1),u=r.map(d=>d.relatedInformation||[]).reduce((d,g)=>g.concat(d),[]).map(d=>d.file?F.parse(d.file.fileName):null);await this._libFiles.fetchLibFilesIfNecessary(u),!e.isDisposed()&&w.setModelMarkers(e,this._selector,r.map(d=>this._convertDiagnostics(e,d)))}_convertDiagnostics(e,t){const o=t.start||0,i=t.length||1,{lineNumber:l,column:p}=e.getPositionAt(o),{lineNumber:n,column:r}=e.getPositionAt(o+i),u=[];return t.reportsUnnecessary&&u.push(P.Unnecessary),t.reportsDeprecated&&u.push(P.Deprecated),{severity:this._tsDiagnosticCategoryToMarkerSeverity(t.category),startLineNumber:l,startColumn:p,endLineNumber:n,endColumn:r,message:A(t.messageText,`
1
+ import{c as M,e as w,U as F,a as P,M as v,l as f,t as K,R as O}from"./monaco-C5uCiSc1.js";import"./ProjectKanbanPage-Ka243_RU.js";import"./index-BziFEuBL.js";import"./mermaid-NOHMQCX5-Cxj8y3xL.js";import"./chevron-right-h-JkCAHM.js";import"./chevron-down-B8PIP1yU.js";import"./confirm-dialog-59aNupkb.js";import"./modal-DCycqy3L.js";import"./Icons-DXzgw2xT.js";import"./CreateTaskInput-kkWy5nmc.js";import"./AgentLogo-VGcaaJum.js";import"./check-CIGH6GLr.js";import"./use-projects-CJ8Wn6Xl.js";import"./MemberAvatar-DeKYSBH9.js";import"./use-providers-DvV0mdqo.js";import"./trash-2-0UA8zJ8I.js";import"./useNormalizedLogs-D8-yjxOI.js";import"./folder-picker-B5RdK3CX.js";import"./circle-alert-B2WJJFVc.js";import"./message-square-BleDaJqD.js";import"./layers-DVjF8vaY.js";import"./chevron-up-C5SQd6qy.js";import"./select-EnAkHFwg.js";import"./textarea-Cmy7-X_E.js";import"./server-a_4ZRCwE.js";import"./upload-CfzBeWxL.js";import"./arrow-left-4_9exfZH.js";import"./pencil-7Lu7CiFO.js";class E{constructor(e,t){this._modeId=e,this._defaults=t,this._worker=null,this._client=null,this._configChangeListener=this._defaults.onDidChange(()=>this._stopWorker()),this._updateExtraLibsToken=0,this._extraLibsChangeListener=this._defaults.onDidExtraLibsChange(()=>this._updateExtraLibs())}dispose(){this._configChangeListener.dispose(),this._extraLibsChangeListener.dispose(),this._stopWorker()}_stopWorker(){this._worker&&(this._worker.dispose(),this._worker=null),this._client=null}async _updateExtraLibs(){if(!this._worker)return;const e=++this._updateExtraLibsToken,t=await this._worker.getProxy();this._updateExtraLibsToken===e&&t.updateExtraLibs(this._defaults.getExtraLibs())}_getClient(){return this._client||(this._client=(async()=>(this._worker=M({moduleId:"vs/language/typescript/tsWorker",createWorker:()=>new Worker(new URL("/assets/ts.worker-BH9nVgjN.js",import.meta.url),{type:"module"}),label:this._modeId,keepIdleModels:!0,createData:{compilerOptions:this._defaults.getCompilerOptions(),extraLibs:this._defaults.getExtraLibs(),customWorkerPath:this._defaults.workerOptions.customWorkerPath,inlayHintsOptions:this._defaults.inlayHintsOptions}}),this._defaults.getEagerModelSync()?await this._worker.withSyncedResources(w.getModels().filter(e=>e.getLanguageId()===this._modeId).map(e=>e.uri)):await this._worker.getProxy()))()),this._client}async getLanguageServiceWorker(...e){const t=await this._getClient();return this._worker&&await this._worker.withSyncedResources(e),t}}const s={};s["lib.d.ts"]=!0;s["lib.decorators.d.ts"]=!0;s["lib.decorators.legacy.d.ts"]=!0;s["lib.dom.asynciterable.d.ts"]=!0;s["lib.dom.d.ts"]=!0;s["lib.dom.iterable.d.ts"]=!0;s["lib.es2015.collection.d.ts"]=!0;s["lib.es2015.core.d.ts"]=!0;s["lib.es2015.d.ts"]=!0;s["lib.es2015.generator.d.ts"]=!0;s["lib.es2015.iterable.d.ts"]=!0;s["lib.es2015.promise.d.ts"]=!0;s["lib.es2015.proxy.d.ts"]=!0;s["lib.es2015.reflect.d.ts"]=!0;s["lib.es2015.symbol.d.ts"]=!0;s["lib.es2015.symbol.wellknown.d.ts"]=!0;s["lib.es2016.array.include.d.ts"]=!0;s["lib.es2016.d.ts"]=!0;s["lib.es2016.full.d.ts"]=!0;s["lib.es2016.intl.d.ts"]=!0;s["lib.es2017.arraybuffer.d.ts"]=!0;s["lib.es2017.d.ts"]=!0;s["lib.es2017.date.d.ts"]=!0;s["lib.es2017.full.d.ts"]=!0;s["lib.es2017.intl.d.ts"]=!0;s["lib.es2017.object.d.ts"]=!0;s["lib.es2017.sharedmemory.d.ts"]=!0;s["lib.es2017.string.d.ts"]=!0;s["lib.es2017.typedarrays.d.ts"]=!0;s["lib.es2018.asyncgenerator.d.ts"]=!0;s["lib.es2018.asynciterable.d.ts"]=!0;s["lib.es2018.d.ts"]=!0;s["lib.es2018.full.d.ts"]=!0;s["lib.es2018.intl.d.ts"]=!0;s["lib.es2018.promise.d.ts"]=!0;s["lib.es2018.regexp.d.ts"]=!0;s["lib.es2019.array.d.ts"]=!0;s["lib.es2019.d.ts"]=!0;s["lib.es2019.full.d.ts"]=!0;s["lib.es2019.intl.d.ts"]=!0;s["lib.es2019.object.d.ts"]=!0;s["lib.es2019.string.d.ts"]=!0;s["lib.es2019.symbol.d.ts"]=!0;s["lib.es2020.bigint.d.ts"]=!0;s["lib.es2020.d.ts"]=!0;s["lib.es2020.date.d.ts"]=!0;s["lib.es2020.full.d.ts"]=!0;s["lib.es2020.intl.d.ts"]=!0;s["lib.es2020.number.d.ts"]=!0;s["lib.es2020.promise.d.ts"]=!0;s["lib.es2020.sharedmemory.d.ts"]=!0;s["lib.es2020.string.d.ts"]=!0;s["lib.es2020.symbol.wellknown.d.ts"]=!0;s["lib.es2021.d.ts"]=!0;s["lib.es2021.full.d.ts"]=!0;s["lib.es2021.intl.d.ts"]=!0;s["lib.es2021.promise.d.ts"]=!0;s["lib.es2021.string.d.ts"]=!0;s["lib.es2021.weakref.d.ts"]=!0;s["lib.es2022.array.d.ts"]=!0;s["lib.es2022.d.ts"]=!0;s["lib.es2022.error.d.ts"]=!0;s["lib.es2022.full.d.ts"]=!0;s["lib.es2022.intl.d.ts"]=!0;s["lib.es2022.object.d.ts"]=!0;s["lib.es2022.regexp.d.ts"]=!0;s["lib.es2022.string.d.ts"]=!0;s["lib.es2023.array.d.ts"]=!0;s["lib.es2023.collection.d.ts"]=!0;s["lib.es2023.d.ts"]=!0;s["lib.es2023.full.d.ts"]=!0;s["lib.es2023.intl.d.ts"]=!0;s["lib.es2024.arraybuffer.d.ts"]=!0;s["lib.es2024.collection.d.ts"]=!0;s["lib.es2024.d.ts"]=!0;s["lib.es2024.full.d.ts"]=!0;s["lib.es2024.object.d.ts"]=!0;s["lib.es2024.promise.d.ts"]=!0;s["lib.es2024.regexp.d.ts"]=!0;s["lib.es2024.sharedmemory.d.ts"]=!0;s["lib.es2024.string.d.ts"]=!0;s["lib.es5.d.ts"]=!0;s["lib.es6.d.ts"]=!0;s["lib.esnext.array.d.ts"]=!0;s["lib.esnext.collection.d.ts"]=!0;s["lib.esnext.d.ts"]=!0;s["lib.esnext.decorators.d.ts"]=!0;s["lib.esnext.disposable.d.ts"]=!0;s["lib.esnext.error.d.ts"]=!0;s["lib.esnext.float16.d.ts"]=!0;s["lib.esnext.full.d.ts"]=!0;s["lib.esnext.intl.d.ts"]=!0;s["lib.esnext.iterator.d.ts"]=!0;s["lib.esnext.promise.d.ts"]=!0;s["lib.esnext.sharedmemory.d.ts"]=!0;s["lib.scripthost.d.ts"]=!0;s["lib.webworker.asynciterable.d.ts"]=!0;s["lib.webworker.d.ts"]=!0;s["lib.webworker.importscripts.d.ts"]=!0;s["lib.webworker.iterable.d.ts"]=!0;function A(c,e,t=0){if(typeof c=="string")return c;if(c===void 0)return"";let o="";if(t){o+=e;for(let i=0;i<t;i++)o+=" "}if(o+=c.messageText,t++,c.next)for(const i of c.next)o+=A(i,e,t);return o}function _(c){return c?c.map(e=>e.text).join(""):""}class y{constructor(e){this._worker=e}_textSpanToRange(e,t){let o=e.getPositionAt(t.start),i=e.getPositionAt(t.start+t.length),{lineNumber:l,column:p}=o,{lineNumber:n,column:r}=i;return{startLineNumber:l,startColumn:p,endLineNumber:n,endColumn:r}}}class H{constructor(e){this._worker=e,this._libFiles={},this._hasFetchedLibFiles=!1,this._fetchLibFilesPromise=null}isLibFile(e){return e&&e.path.indexOf("/lib.")===0?!!s[e.path.slice(1)]:!1}getOrCreateModel(e){const t=F.parse(e),o=w.getModel(t);if(o)return o;if(this.isLibFile(t)&&this._hasFetchedLibFiles)return w.createModel(this._libFiles[t.path.slice(1)],"typescript",t);const i=K.getExtraLibs()[e];return i?w.createModel(i.content,"typescript",t):null}_containsLibFile(e){for(let t of e)if(this.isLibFile(t))return!0;return!1}async fetchLibFilesIfNecessary(e){this._containsLibFile(e)&&await this._fetchLibFiles()}_fetchLibFiles(){return this._fetchLibFilesPromise||(this._fetchLibFilesPromise=this._worker().then(e=>e.getLibFiles()).then(e=>{this._hasFetchedLibFiles=!0,this._libFiles=e})),this._fetchLibFilesPromise}}class V extends y{constructor(e,t,o,i){super(i),this._libFiles=e,this._defaults=t,this._selector=o,this._disposables=[],this._listener=Object.create(null);const l=r=>{if(r.getLanguageId()!==o)return;const u=()=>{const{onlyVisible:m}=this._defaults.getDiagnosticsOptions();m?r.isAttachedToEditor()&&this._doValidate(r):this._doValidate(r)};let d;const g=r.onDidChangeContent(()=>{clearTimeout(d),d=window.setTimeout(u,500)}),b=r.onDidChangeAttached(()=>{const{onlyVisible:m}=this._defaults.getDiagnosticsOptions();m&&(r.isAttachedToEditor()?u():w.setModelMarkers(r,this._selector,[]))});this._listener[r.uri.toString()]={dispose(){g.dispose(),b.dispose(),clearTimeout(d)}},u()},p=r=>{w.setModelMarkers(r,this._selector,[]);const u=r.uri.toString();this._listener[u]&&(this._listener[u].dispose(),delete this._listener[u])};this._disposables.push(w.onDidCreateModel(r=>l(r))),this._disposables.push(w.onWillDisposeModel(p)),this._disposables.push(w.onDidChangeModelLanguage(r=>{p(r.model),l(r.model)})),this._disposables.push({dispose(){for(const r of w.getModels())p(r)}});const n=()=>{for(const r of w.getModels())p(r),l(r)};this._disposables.push(this._defaults.onDidChange(n)),this._disposables.push(this._defaults.onDidExtraLibsChange(n)),w.getModels().forEach(r=>l(r))}dispose(){this._disposables.forEach(e=>e&&e.dispose()),this._disposables=[]}async _doValidate(e){const t=await this._worker(e.uri);if(e.isDisposed())return;const o=[],{noSyntaxValidation:i,noSemanticValidation:l,noSuggestionDiagnostics:p}=this._defaults.getDiagnosticsOptions();i||o.push(t.getSyntacticDiagnostics(e.uri.toString())),l||o.push(t.getSemanticDiagnostics(e.uri.toString())),p||o.push(t.getSuggestionDiagnostics(e.uri.toString()));const n=await Promise.all(o);if(!n||e.isDisposed())return;const r=n.reduce((d,g)=>g.concat(d),[]).filter(d=>(this._defaults.getDiagnosticsOptions().diagnosticCodesToIgnore||[]).indexOf(d.code)===-1),u=r.map(d=>d.relatedInformation||[]).reduce((d,g)=>g.concat(d),[]).map(d=>d.file?F.parse(d.file.fileName):null);await this._libFiles.fetchLibFilesIfNecessary(u),!e.isDisposed()&&w.setModelMarkers(e,this._selector,r.map(d=>this._convertDiagnostics(e,d)))}_convertDiagnostics(e,t){const o=t.start||0,i=t.length||1,{lineNumber:l,column:p}=e.getPositionAt(o),{lineNumber:n,column:r}=e.getPositionAt(o+i),u=[];return t.reportsUnnecessary&&u.push(P.Unnecessary),t.reportsDeprecated&&u.push(P.Deprecated),{severity:this._tsDiagnosticCategoryToMarkerSeverity(t.category),startLineNumber:l,startColumn:p,endLineNumber:n,endColumn:r,message:A(t.messageText,`
2
2
  `),code:t.code.toString(),tags:u,relatedInformation:this._convertRelatedInformation(e,t.relatedInformation)}}_convertRelatedInformation(e,t){if(!t)return[];const o=[];return t.forEach(i=>{let l=e;if(i.file&&(l=this._libFiles.getOrCreateModel(i.file.fileName)),!l)return;const p=i.start||0,n=i.length||1,{lineNumber:r,column:u}=l.getPositionAt(p),{lineNumber:d,column:g}=l.getPositionAt(p+n);o.push({resource:l.uri,startLineNumber:r,startColumn:u,endLineNumber:d,endColumn:g,message:A(i.messageText,`
3
3
  `)})}),o}_tsDiagnosticCategoryToMarkerSeverity(e){switch(e){case 1:return v.Error;case 3:return v.Info;case 0:return v.Warning;case 2:return v.Hint}return v.Info}}class C extends y{get triggerCharacters(){return["."]}async provideCompletionItems(e,t,o,i){const l=e.getWordUntilPosition(t),p=new O(t.lineNumber,l.startColumn,t.lineNumber,l.endColumn),n=e.uri,r=e.getOffsetAt(t),u=await this._worker(n);if(e.isDisposed())return;const d=await u.getCompletionsAtPosition(n.toString(),r);return!d||e.isDisposed()?void 0:{suggestions:d.entries.map(b=>{let m=p;if(b.replacementSpan){const x=e.getPositionAt(b.replacementSpan.start),D=e.getPositionAt(b.replacementSpan.start+b.replacementSpan.length);m=new O(x.lineNumber,x.column,D.lineNumber,D.column)}const k=[];return b.kindModifiers!==void 0&&b.kindModifiers.indexOf("deprecated")!==-1&&k.push(f.CompletionItemTag.Deprecated),{uri:n,position:t,offset:r,range:m,label:b.name,insertText:b.name,sortText:b.sortText,kind:C.convertKind(b.kind),tags:k}})}}async resolveCompletionItem(e,t){const o=e,i=o.uri,l=o.position,p=o.offset,r=await(await this._worker(i)).getCompletionEntryDetails(i.toString(),p,o.label);return r?{uri:i,position:l,label:r.name,kind:C.convertKind(r.kind),detail:_(r.displayParts),documentation:{value:C.createDocumentationString(r)}}:o}static convertKind(e){switch(e){case a.primitiveType:case a.keyword:return f.CompletionItemKind.Keyword;case a.variable:case a.localVariable:return f.CompletionItemKind.Variable;case a.memberVariable:case a.memberGetAccessor:case a.memberSetAccessor:return f.CompletionItemKind.Field;case a.function:case a.memberFunction:case a.constructSignature:case a.callSignature:case a.indexSignature:return f.CompletionItemKind.Function;case a.enum:return f.CompletionItemKind.Enum;case a.module:return f.CompletionItemKind.Module;case a.class:return f.CompletionItemKind.Class;case a.interface:return f.CompletionItemKind.Interface;case a.warning:return f.CompletionItemKind.File}return f.CompletionItemKind.Property}static createDocumentationString(e){let t=_(e.documentation);if(e.tags)for(const o of e.tags)t+=`
4
4
 
@@ -1 +1 @@
1
- import{l as e}from"./monaco-ORn-kQwM.js";import"./ProjectKanbanPage-BbRguX0a.js";import"./index-BVh0eL1_.js";import"./mermaid-NOHMQCX5-Cc97ICqZ.js";import"./chevron-right-Q1Dgt2I3.js";import"./chevron-down-BeBVnkqU.js";import"./confirm-dialog-BcfJ2Xus.js";import"./modal-CORyqdln.js";import"./Icons-CjfPc49M.js";import"./CreateTaskInput-C9aO7QVE.js";import"./AgentLogo-DonTQxM9.js";import"./check-VbbiSgv8.js";import"./use-projects-BQB2BPEN.js";import"./MemberAvatar-CK6Kg4RE.js";import"./use-providers--I6m_J5h.js";import"./trash-2-0qxC5GZF.js";import"./useNormalizedLogs-BB31QSMo.js";import"./folder-picker-NzVodD5j.js";import"./circle-alert-Dwtt3OAP.js";import"./message-square-DWgJpKCx.js";import"./layers-DePAliGw.js";import"./chevron-up-D2HXcF3G.js";import"./select-C0_GwcaL.js";import"./textarea-DDugro1C.js";import"./server-ezmEd1Bn.js";import"./upload-Bvn4pVZf.js";import"./arrow-left-KfI6LIDH.js";import"./pencil-B1BeYe1f.js";const C={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\#\%\^\&\*\(\)\-\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],onEnterRules:[{beforeText:/^\s*\/\*\*(?!\/)([^\*]|\*(?!\/))*$/,afterText:/^\s*\*\/$/,action:{indentAction:e.IndentAction.IndentOutdent,appendText:" * "}},{beforeText:/^\s*\/\*\*(?!\/)([^\*]|\*(?!\/))*$/,action:{indentAction:e.IndentAction.None,appendText:" * "}},{beforeText:/^(\t|(\ \ ))*\ \*(\ ([^\*]|\*(?!\/))*)?$/,action:{indentAction:e.IndentAction.None,appendText:"* "}},{beforeText:/^(\t|(\ \ ))*\ \*\/\s*$/,action:{indentAction:e.IndentAction.None,removeText:1}}],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string","comment"]},{open:"`",close:"`",notIn:["string","comment"]},{open:"/**",close:" */",notIn:["string"]}],folding:{markers:{start:new RegExp("^\\s*//\\s*#?region\\b"),end:new RegExp("^\\s*//\\s*#?endregion\\b")}}},E={defaultToken:"invalid",tokenPostfix:".ts",keywords:["abstract","any","as","asserts","bigint","boolean","break","case","catch","class","continue","const","constructor","debugger","declare","default","delete","do","else","enum","export","extends","false","finally","for","from","function","get","if","implements","import","in","infer","instanceof","interface","is","keyof","let","module","namespace","never","new","null","number","object","out","package","private","protected","public","override","readonly","require","global","return","satisfies","set","static","string","super","switch","symbol","this","throw","true","try","type","typeof","undefined","unique","unknown","var","void","while","with","yield","async","await","of"],operators:["<=",">=","==","!=","===","!==","=>","+","-","**","*","/","%","++","--","<<","</",">>",">>>","&","|","^","!","~","&&","||","??","?",":","=","+=","-=","*=","**=","/=","%=","<<=",">>=",">>>=","&=","|=","^=","@"],symbols:/[=><!~?:&|+\-*\/\^%]+/,escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,digits:/\d+(_+\d+)*/,octaldigits:/[0-7]+(_+[0-7]+)*/,binarydigits:/[0-1]+(_+[0-1]+)*/,hexdigits:/[[0-9a-fA-F]+(_+[0-9a-fA-F]+)*/,regexpctl:/[(){}\[\]\$\^|\-*+?\.]/,regexpesc:/\\(?:[bBdDfnrstvwWn0\\\/]|@regexpctl|c[A-Z]|x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4})/,tokenizer:{root:[[/[{}]/,"delimiter.bracket"],{include:"common"}],common:[[/#?[a-z_$][\w$]*/,{cases:{"@keywords":"keyword","@default":"identifier"}}],[/[A-Z][\w\$]*/,"type.identifier"],{include:"@whitespace"},[/\/(?=([^\\\/]|\\.)+\/([dgimsuy]*)(\s*)(\.|;|,|\)|\]|\}|$))/,{token:"regexp",bracket:"@open",next:"@regexp"}],[/[()\[\]]/,"@brackets"],[/[<>](?!@symbols)/,"@brackets"],[/!(?=([^=]|$))/,"delimiter"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/(@digits)[eE]([\-+]?(@digits))?/,"number.float"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?/,"number.float"],[/0[xX](@hexdigits)n?/,"number.hex"],[/0[oO]?(@octaldigits)n?/,"number.octal"],[/0[bB](@binarydigits)n?/,"number.binary"],[/(@digits)n?/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/'([^'\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string_double"],[/'/,"string","@string_single"],[/`/,"string","@string_backtick"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@jsdoc"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],jsdoc:[[/[^\/*]+/,"comment.doc"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],regexp:[[/(\{)(\d+(?:,\d*)?)(\})/,["regexp.escape.control","regexp.escape.control","regexp.escape.control"]],[/(\[)(\^?)(?=(?:[^\]\\\/]|\\.)+)/,["regexp.escape.control",{token:"regexp.escape.control",next:"@regexrange"}]],[/(\()(\?:|\?=|\?!)/,["regexp.escape.control","regexp.escape.control"]],[/[()]/,"regexp.escape.control"],[/@regexpctl/,"regexp.escape.control"],[/[^\\\/]/,"regexp"],[/@regexpesc/,"regexp.escape"],[/\\\./,"regexp.invalid"],[/(\/)([dgimsuy]*)/,[{token:"regexp",bracket:"@close",next:"@pop"},"keyword.other"]]],regexrange:[[/-/,"regexp.escape.control"],[/\^/,"regexp.invalid"],[/@regexpesc/,"regexp.escape"],[/[^\]]/,"regexp"],[/\]/,{token:"regexp.escape.control",next:"@pop",bracket:"@close"}]],string_double:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],string_single:[[/[^\\']+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/'/,"string","@pop"]],string_backtick:[[/\$\{/,{token:"delimiter.bracket",next:"@bracketCounting"}],[/[^\\`$]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/`/,"string","@pop"]],bracketCounting:[[/\{/,"delimiter.bracket","@bracketCounting"],[/\}/,"delimiter.bracket","@pop"],{include:"common"}]}};export{C as conf,E as language};
1
+ import{l as e}from"./monaco-C5uCiSc1.js";import"./ProjectKanbanPage-Ka243_RU.js";import"./index-BziFEuBL.js";import"./mermaid-NOHMQCX5-Cxj8y3xL.js";import"./chevron-right-h-JkCAHM.js";import"./chevron-down-B8PIP1yU.js";import"./confirm-dialog-59aNupkb.js";import"./modal-DCycqy3L.js";import"./Icons-DXzgw2xT.js";import"./CreateTaskInput-kkWy5nmc.js";import"./AgentLogo-VGcaaJum.js";import"./check-CIGH6GLr.js";import"./use-projects-CJ8Wn6Xl.js";import"./MemberAvatar-DeKYSBH9.js";import"./use-providers-DvV0mdqo.js";import"./trash-2-0UA8zJ8I.js";import"./useNormalizedLogs-D8-yjxOI.js";import"./folder-picker-B5RdK3CX.js";import"./circle-alert-B2WJJFVc.js";import"./message-square-BleDaJqD.js";import"./layers-DVjF8vaY.js";import"./chevron-up-C5SQd6qy.js";import"./select-EnAkHFwg.js";import"./textarea-Cmy7-X_E.js";import"./server-a_4ZRCwE.js";import"./upload-CfzBeWxL.js";import"./arrow-left-4_9exfZH.js";import"./pencil-7Lu7CiFO.js";const C={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\#\%\^\&\*\(\)\-\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],onEnterRules:[{beforeText:/^\s*\/\*\*(?!\/)([^\*]|\*(?!\/))*$/,afterText:/^\s*\*\/$/,action:{indentAction:e.IndentAction.IndentOutdent,appendText:" * "}},{beforeText:/^\s*\/\*\*(?!\/)([^\*]|\*(?!\/))*$/,action:{indentAction:e.IndentAction.None,appendText:" * "}},{beforeText:/^(\t|(\ \ ))*\ \*(\ ([^\*]|\*(?!\/))*)?$/,action:{indentAction:e.IndentAction.None,appendText:"* "}},{beforeText:/^(\t|(\ \ ))*\ \*\/\s*$/,action:{indentAction:e.IndentAction.None,removeText:1}}],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string","comment"]},{open:"`",close:"`",notIn:["string","comment"]},{open:"/**",close:" */",notIn:["string"]}],folding:{markers:{start:new RegExp("^\\s*//\\s*#?region\\b"),end:new RegExp("^\\s*//\\s*#?endregion\\b")}}},E={defaultToken:"invalid",tokenPostfix:".ts",keywords:["abstract","any","as","asserts","bigint","boolean","break","case","catch","class","continue","const","constructor","debugger","declare","default","delete","do","else","enum","export","extends","false","finally","for","from","function","get","if","implements","import","in","infer","instanceof","interface","is","keyof","let","module","namespace","never","new","null","number","object","out","package","private","protected","public","override","readonly","require","global","return","satisfies","set","static","string","super","switch","symbol","this","throw","true","try","type","typeof","undefined","unique","unknown","var","void","while","with","yield","async","await","of"],operators:["<=",">=","==","!=","===","!==","=>","+","-","**","*","/","%","++","--","<<","</",">>",">>>","&","|","^","!","~","&&","||","??","?",":","=","+=","-=","*=","**=","/=","%=","<<=",">>=",">>>=","&=","|=","^=","@"],symbols:/[=><!~?:&|+\-*\/\^%]+/,escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,digits:/\d+(_+\d+)*/,octaldigits:/[0-7]+(_+[0-7]+)*/,binarydigits:/[0-1]+(_+[0-1]+)*/,hexdigits:/[[0-9a-fA-F]+(_+[0-9a-fA-F]+)*/,regexpctl:/[(){}\[\]\$\^|\-*+?\.]/,regexpesc:/\\(?:[bBdDfnrstvwWn0\\\/]|@regexpctl|c[A-Z]|x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4})/,tokenizer:{root:[[/[{}]/,"delimiter.bracket"],{include:"common"}],common:[[/#?[a-z_$][\w$]*/,{cases:{"@keywords":"keyword","@default":"identifier"}}],[/[A-Z][\w\$]*/,"type.identifier"],{include:"@whitespace"},[/\/(?=([^\\\/]|\\.)+\/([dgimsuy]*)(\s*)(\.|;|,|\)|\]|\}|$))/,{token:"regexp",bracket:"@open",next:"@regexp"}],[/[()\[\]]/,"@brackets"],[/[<>](?!@symbols)/,"@brackets"],[/!(?=([^=]|$))/,"delimiter"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/(@digits)[eE]([\-+]?(@digits))?/,"number.float"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?/,"number.float"],[/0[xX](@hexdigits)n?/,"number.hex"],[/0[oO]?(@octaldigits)n?/,"number.octal"],[/0[bB](@binarydigits)n?/,"number.binary"],[/(@digits)n?/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/'([^'\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string_double"],[/'/,"string","@string_single"],[/`/,"string","@string_backtick"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@jsdoc"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],jsdoc:[[/[^\/*]+/,"comment.doc"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],regexp:[[/(\{)(\d+(?:,\d*)?)(\})/,["regexp.escape.control","regexp.escape.control","regexp.escape.control"]],[/(\[)(\^?)(?=(?:[^\]\\\/]|\\.)+)/,["regexp.escape.control",{token:"regexp.escape.control",next:"@regexrange"}]],[/(\()(\?:|\?=|\?!)/,["regexp.escape.control","regexp.escape.control"]],[/[()]/,"regexp.escape.control"],[/@regexpctl/,"regexp.escape.control"],[/[^\\\/]/,"regexp"],[/@regexpesc/,"regexp.escape"],[/\\\./,"regexp.invalid"],[/(\/)([dgimsuy]*)/,[{token:"regexp",bracket:"@close",next:"@pop"},"keyword.other"]]],regexrange:[[/-/,"regexp.escape.control"],[/\^/,"regexp.invalid"],[/@regexpesc/,"regexp.escape"],[/[^\]]/,"regexp"],[/\]/,{token:"regexp.escape.control",next:"@pop",bracket:"@close"}]],string_double:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],string_single:[[/[^\\']+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/'/,"string","@pop"]],string_backtick:[[/\$\{/,{token:"delimiter.bracket",next:"@bracketCounting"}],[/[^\\`$]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/`/,"string","@pop"]],bracketCounting:[[/\{/,"delimiter.bracket","@bracketCounting"],[/\}/,"delimiter.bracket","@pop"],{include:"common"}]}};export{C as conf,E as language};
@@ -1 +1 @@
1
- import{k as a}from"./index-BVh0eL1_.js";const o=[["path",{d:"M12 3v12",key:"1x0j5s"}],["path",{d:"m17 8-5-5-5 5",key:"7q97r8"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}]],t=a("upload",o);export{t as U};
1
+ import{k as a}from"./index-BziFEuBL.js";const o=[["path",{d:"M12 3v12",key:"1x0j5s"}],["path",{d:"m17 8-5-5-5 5",key:"7q97r8"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}]],t=a("upload",o);export{t as U};
@@ -1 +1 @@
1
- import{m as n,o as i,n as a,q as s,p as r}from"./index-BVh0eL1_.js";function f(){return n({queryKey:s.profiles.all,queryFn:()=>r.get("/profiles")})}function y(){return n({queryKey:s.profiles.defaults,queryFn:()=>r.get("/profiles/defaults")})}function c(e){return n({queryKey:s.profiles.agent(e),queryFn:()=>r.get(`/profiles/${e}`),enabled:!!e})}function p(){const e=i();return a({mutationFn:({agentType:u,variant:t,config:l})=>r.put(`/profiles/${u}/${t}`,l),onSuccess:()=>{e.invalidateQueries({queryKey:s.profiles.all})}})}function q(){const e=i();return a({mutationFn:({agentType:u,variant:t})=>r.delete(`/profiles/${u}/${t}`),onSuccess:()=>{e.invalidateQueries({queryKey:s.profiles.all})}})}export{y as a,p as b,q as c,c as d,f as u};
1
+ import{m as n,o as i,n as a,q as s,p as r}from"./index-BziFEuBL.js";function f(){return n({queryKey:s.profiles.all,queryFn:()=>r.get("/profiles")})}function y(){return n({queryKey:s.profiles.defaults,queryFn:()=>r.get("/profiles/defaults")})}function c(e){return n({queryKey:s.profiles.agent(e),queryFn:()=>r.get(`/profiles/${e}`),enabled:!!e})}function p(){const e=i();return a({mutationFn:({agentType:u,variant:t,config:l})=>r.put(`/profiles/${u}/${t}`,l),onSuccess:()=>{e.invalidateQueries({queryKey:s.profiles.all})}})}function q(){const e=i();return a({mutationFn:({agentType:u,variant:t})=>r.delete(`/profiles/${u}/${t}`),onSuccess:()=>{e.invalidateQueries({queryKey:s.profiles.all})}})}export{y as a,p as b,q as c,c as d,f as u};
@@ -1 +1 @@
1
- import{k as c,m as n,o as s,n as u,q as r,p as i}from"./index-BVh0eL1_.js";const l=[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]],y=c("folder",l);function d(e){const t={};return e?.page!=null&&(t.page=String(e.page)),e?.limit!=null&&(t.limit=String(e.limit)),e?.includeArchived&&(t.includeArchived="true"),n({queryKey:r.projects.list(e),queryFn:()=>i.get("/projects",{params:t})})}function p(e){return n({queryKey:r.projects.detail(e),queryFn:()=>i.get(`/projects/${e}`),enabled:!!e})}function j(){const e=s();return u({mutationFn:t=>i.post("/projects",t),onSuccess:()=>{e.invalidateQueries({queryKey:r.projects.all})}})}function q(){const e=s();return u({mutationFn:({id:t,...a})=>i.put(`/projects/${t}`,a),onSuccess:(t,a)=>{e.invalidateQueries({queryKey:r.projects.all}),e.invalidateQueries({queryKey:r.projects.detail(a.id)})}})}function v(){const e=s();return u({mutationFn:({id:t,deleteRepo:a})=>i.post(`/projects/${t}/archive`,{deleteRepo:a??!1}),onSuccess:(t,a)=>{e.invalidateQueries({queryKey:r.projects.all}),e.invalidateQueries({queryKey:r.projects.detail(a.id)}),e.invalidateQueries({queryKey:r.tasks.all}),e.invalidateQueries({queryKey:r.workspaces.all})}})}function K(){const e=s();return u({mutationFn:({id:t,repoPath:a})=>i.post(`/projects/${t}/restore`,a?{repoPath:a}:{}),onSuccess:(t,a)=>{e.invalidateQueries({queryKey:r.projects.all}),e.invalidateQueries({queryKey:r.projects.detail(a.id)}),e.invalidateQueries({queryKey:r.tasks.all}),e.invalidateQueries({queryKey:r.workspaces.all})}})}function Q(){const e=s();return u({mutationFn:({id:t})=>i.get(`/projects/${t}/git-capability`),onSuccess:(t,a)=>{e.setQueryData(r.projects.gitCapability(a.id),t),e.invalidateQueries({queryKey:r.projects.all}),e.invalidateQueries({queryKey:r.projects.detail(a.id)}),e.invalidateQueries({queryKey:r.tasks.all})}})}export{y as F,q as a,v as b,K as c,Q as d,p as e,j as f,d as u};
1
+ import{k as c,m as n,o as s,n as u,q as r,p as i}from"./index-BziFEuBL.js";const l=[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]],y=c("folder",l);function d(e){const t={};return e?.page!=null&&(t.page=String(e.page)),e?.limit!=null&&(t.limit=String(e.limit)),e?.includeArchived&&(t.includeArchived="true"),n({queryKey:r.projects.list(e),queryFn:()=>i.get("/projects",{params:t})})}function p(e){return n({queryKey:r.projects.detail(e),queryFn:()=>i.get(`/projects/${e}`),enabled:!!e})}function j(){const e=s();return u({mutationFn:t=>i.post("/projects",t),onSuccess:()=>{e.invalidateQueries({queryKey:r.projects.all})}})}function q(){const e=s();return u({mutationFn:({id:t,...a})=>i.put(`/projects/${t}`,a),onSuccess:(t,a)=>{e.invalidateQueries({queryKey:r.projects.all}),e.invalidateQueries({queryKey:r.projects.detail(a.id)})}})}function v(){const e=s();return u({mutationFn:({id:t,deleteRepo:a})=>i.post(`/projects/${t}/archive`,{deleteRepo:a??!1}),onSuccess:(t,a)=>{e.invalidateQueries({queryKey:r.projects.all}),e.invalidateQueries({queryKey:r.projects.detail(a.id)}),e.invalidateQueries({queryKey:r.tasks.all}),e.invalidateQueries({queryKey:r.workspaces.all})}})}function K(){const e=s();return u({mutationFn:({id:t,repoPath:a})=>i.post(`/projects/${t}/restore`,a?{repoPath:a}:{}),onSuccess:(t,a)=>{e.invalidateQueries({queryKey:r.projects.all}),e.invalidateQueries({queryKey:r.projects.detail(a.id)}),e.invalidateQueries({queryKey:r.tasks.all}),e.invalidateQueries({queryKey:r.workspaces.all})}})}function Q(){const e=s();return u({mutationFn:({id:t})=>i.get(`/projects/${t}/git-capability`),onSuccess:(t,a)=>{e.setQueryData(r.projects.gitCapability(a.id),t),e.invalidateQueries({queryKey:r.projects.all}),e.invalidateQueries({queryKey:r.projects.detail(a.id)}),e.invalidateQueries({queryKey:r.tasks.all})}})}export{y as F,q as a,v as b,K as c,Q as d,p as e,j as f,d as u};
@@ -1 +1 @@
1
- import{m as d,n as s,o as u,q as i,p as t}from"./index-BVh0eL1_.js";function c(){return d({queryKey:i.providers.all,queryFn:()=>t.get("/providers")})}function v(e,r){const o=r?.trim()||void 0;return d({queryKey:i.providers.capabilities(e,o),queryFn:()=>{const n=new URLSearchParams;e&&n.set("agentType",e),o&&n.set("model",o);const a=n.toString();return t.get(`/providers/capabilities${a?`?${a}`:""}`)},staleTime:300*1e3})}function l(){const e=u();return s({mutationFn:r=>t.post("/providers",r),onSuccess:r=>{e.setQueryData(i.providers.detail(r.id),r),e.invalidateQueries({queryKey:i.providers.all})}})}function y(){const e=u();return s({mutationFn:({id:r,data:o})=>t.put(`/providers/${r}`,o),onSuccess:r=>{e.setQueryData(i.providers.detail(r.id),r),e.invalidateQueries({queryKey:i.providers.all}),e.invalidateQueries({queryKey:i.providers.detail(r.id)})}})}function m(){return s({mutationFn:e=>t.post("/providers/test",e)})}function f(){const e=u();return s({mutationFn:r=>t.delete(`/providers/${r}`),onSuccess:()=>{e.invalidateQueries({queryKey:i.providers.all})}})}function q(){return s({mutationFn:()=>t.get("/providers/backup")})}function P(){return s({mutationFn:e=>t.post("/providers/import/preview",e)})}function F(){const e=u();return s({mutationFn:r=>t.post("/providers/import",r),onSuccess:()=>{e.invalidateQueries({queryKey:i.providers.all})}})}export{m as a,v as b,l as c,y as d,f as e,q as f,P as g,F as h,c as u};
1
+ import{m as d,n as s,o as u,q as i,p as t}from"./index-BziFEuBL.js";function c(){return d({queryKey:i.providers.all,queryFn:()=>t.get("/providers")})}function v(e,r){const o=r?.trim()||void 0;return d({queryKey:i.providers.capabilities(e,o),queryFn:()=>{const n=new URLSearchParams;e&&n.set("agentType",e),o&&n.set("model",o);const a=n.toString();return t.get(`/providers/capabilities${a?`?${a}`:""}`)},staleTime:300*1e3})}function l(){const e=u();return s({mutationFn:r=>t.post("/providers",r),onSuccess:r=>{e.setQueryData(i.providers.detail(r.id),r),e.invalidateQueries({queryKey:i.providers.all})}})}function y(){const e=u();return s({mutationFn:({id:r,data:o})=>t.put(`/providers/${r}`,o),onSuccess:r=>{e.setQueryData(i.providers.detail(r.id),r),e.invalidateQueries({queryKey:i.providers.all}),e.invalidateQueries({queryKey:i.providers.detail(r.id)})}})}function m(){return s({mutationFn:e=>t.post("/providers/test",e)})}function f(){const e=u();return s({mutationFn:r=>t.delete(`/providers/${r}`),onSuccess:()=>{e.invalidateQueries({queryKey:i.providers.all})}})}function q(){return s({mutationFn:()=>t.get("/providers/backup")})}function P(){return s({mutationFn:e=>t.post("/providers/import/preview",e)})}function F(){const e=u();return s({mutationFn:r=>t.post("/providers/import",r),onSuccess:()=>{e.invalidateQueries({queryKey:i.providers.all})}})}export{m as a,v as b,l as c,y as d,f as e,q as f,P as g,F as h,c as u};
@@ -1 +1 @@
1
- import{k as re,u as Ie,r,j as d,U as k,V as v,W as be,p as Te}from"./index-BVh0eL1_.js";import{C as Oe}from"./chevron-down-BeBVnkqU.js";import{C as _e}from"./check-VbbiSgv8.js";import{c as L,E as ke,S as B,n as Le,d as qe,e as Pe,f as De,s as $e}from"./mermaid-NOHMQCX5-Cc97ICqZ.js";const je=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}]],Me=re("circle-dot",je);const Ue=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],ie=re("circle",Ue);const Ye=[["path",{d:"m16 6-8.414 8.586a2 2 0 0 0 2.829 2.829l8.414-8.586a4 4 0 1 0-5.657-5.657l-8.379 8.551a6 6 0 1 0 8.485 8.485l8.379-8.551",key:"1miecu"}]],et=re("paperclip",Ye),ue="agent-tower-todo-panel-open";function ze(t,e){const n=e?"h-3 w-3":"h-3.5 w-3.5",a=(t||"").toLowerCase();return a==="completed"?d.jsx(_e,{"aria-hidden":!0,className:`${n} text-emerald-500`}):a==="in_progress"||a==="in-progress"?d.jsx(Me,{"aria-hidden":!0,className:`${n} text-blue-500`}):a==="cancelled"?d.jsx(ie,{"aria-hidden":!0,className:`${n} text-neutral-300`}):d.jsx(ie,{"aria-hidden":!0,className:`${n} text-neutral-400`})}function tt({todos:t,compact:e}){const{t:n}=Ie(),[a,o]=r.useState(()=>{if(e)return!1;const i=localStorage.getItem(ue);return i===null?!0:i==="true"});if(r.useEffect(()=>{localStorage.setItem(ue,String(a))},[a]),!t||t.length===0)return null;const l=t.filter(i=>i.status?.toLowerCase()==="completed").length,M=t.length>0?l/t.length*100:0;return d.jsxs("details",{className:"group",open:a,onToggle:i=>o(i.target.open),children:[d.jsx("summary",{className:"list-none cursor-pointer select-none [&::-webkit-details-marker]:hidden",children:d.jsxs("div",{className:`bg-neutral-50/80 border border-neutral-100 rounded-lg flex items-center justify-between hover:bg-neutral-100/80 transition-colors ${e?"px-3 py-1.5":"px-3 py-2"}`,children:[d.jsxs("div",{className:"flex items-center gap-2 min-w-0",children:[d.jsx("span",{className:"text-neutral-500 font-medium text-xs",children:n("待办")}),d.jsxs("span",{className:"text-neutral-400 tabular-nums text-xs",children:[l,"/",t.length]}),d.jsx("div",{className:"w-12 h-1 bg-neutral-200/60 rounded-full overflow-hidden",children:d.jsx("div",{className:"h-full bg-emerald-400 rounded-full transition-all duration-300",style:{width:`${M}%`}})})]}),d.jsx(Oe,{"aria-hidden":!0,className:`text-neutral-400 transition-transform group-open:rotate-180 ${e?"h-3 w-3":"h-3.5 w-3.5"}`})]})}),d.jsx("div",{className:`pt-1.5 pb-0.5 ${e?"max-h-28 overflow-y-auto px-1":"px-1"}`,children:d.jsx("ul",{className:"space-y-px",role:"list","aria-label":"Agent todo list",children:t.map((i,q)=>{const U=i.status?.toLowerCase()==="cancelled",V=i.status?.toLowerCase()==="completed";return d.jsxs("li",{className:`flex items-center gap-1.5 rounded-md px-2 ${e?"py-0.5":"py-[3px]"} ${V?"opacity-60":""}`,children:[d.jsx("span",{className:`flex items-center justify-center shrink-0 ${e?"h-3 w-3":"h-3.5 w-3.5"}`,children:ze(i.status,e)}),d.jsx("span",{className:`${e?"text-[11px] leading-[14px]":"text-xs leading-4"} text-neutral-600 wrap-break-word truncate ${U?"line-through text-neutral-400":""} ${V?"text-neutral-400":""}`,children:i.content})]},`${i.content}-${q}`)})})})]})}function st(t){return r.useMemo(()=>{let e=[],n=0;for(const o of t)if(o.entryType==="tool_use"&&o.metadata?.action==="todo_management"&&o.metadata.todos&&o.metadata.todos.length>0){const l=o.metadata.todos;l.every(i=>i.content&&i.content.trim().length>0&&i.status)&&o.timestamp>=n&&(e=l,n=o.timestamp)}const a=e.find(o=>{const l=o.status?.toLowerCase();return l==="in_progress"||l==="in-progress"})??null;return{todos:e,inProgressTodo:a}},[t])}const Ge=!1,Fe=1500,le=[250,1e3,3e3],He=1e4;function he(t){return t instanceof DOMException&&t.name==="AbortError"}function Be(t){if(he(t))return!1;const e=typeof t=="object"&&t!==null&&"status"in t?t.status:void 0;return typeof e!="number"?!0:e===408||e===429||e>=500}function Ve(t,e){return new Promise(n=>{if(e.aborted){n(!1);return}const a=window.setTimeout(()=>{e.removeEventListener("abort",o),n(!0)},t),o=()=>{window.clearTimeout(a),n(!1)};e.addEventListener("abort",o,{once:!0})})}function j(t){return t===B.COMPLETED||t===B.FAILED||t===B.CANCELLED}function Ke(t){return typeof t?.seq=="number"?t.seq:0}function de(t){return!j(t)}function me(t){return t.entryType==="user_message"||t.entryType==="user_feedback"}function ge(t){return!me(t)&&t.entryType!=="loading"&&t.entryType!=="token_usage_info"&&t.content.trim()!==""}function ne(t,e){let n=e,a,o;for(const l of t)o??=l.timestamp,me(l)?(n=l.timestamp,a=void 0):ge(l)&&(n??=l.timestamp,a=l.timestamp);return{processingStartedAt:n??o,lastOutputAt:a}}function fe(t){if(typeof t=="number")return Number.isFinite(t)?t:void 0;if(typeof t!="string"||t.trim()==="")return;const e=Date.parse(t);return Number.isNaN(e)?void 0:e}function pe(t,e){return t.some(n=>{if(n.op==="remove")return!1;const a=n.path.match(/^\/entries\/(\d+)(?:\/|$)/);if(!a)return!1;const o=e[Number(a[1])];return o?ge(o):!1})}function nt(t){const{sessionId:e,sessionStatus:n,sessionStartedAt:a,sessionEndedAt:o,onAgentSessionId:l,onExit:M,onError:i}=t,q=fe(a),U=fe(o),[V,K]=r.useState(()=>k.isConnected()),[Q,N]=r.useState(!1),[Se,oe]=r.useState(!1),[xe,Z]=r.useState(null),[ce,C]=r.useState(!1),[Ae,Y]=r.useState(()=>!j(n)),[Ee,I]=r.useState(()=>U??null),W=L(r.useCallback(s=>s.conversations[e]??ke,[e])),g=r.useRef(!1),P=r.useRef({}),b=r.useRef(null),z=r.useRef(new Map),G=r.useRef(new Map),y=r.useRef(0),ee=r.useRef(q);ee.current=q;const T=r.useRef({sessionId:e});T.current.sessionId!==e&&(T.current={sessionId:e});const F=r.useRef(e);F.current=e;const X=r.useRef({onAgentSessionId:l,onExit:M,onError:i});X.current={onAgentSessionId:l,onExit:M,onError:i};const J=r.useRef(n);J.current=n,r.useEffect(()=>{j(n)?(Y(!1),I(U??null)):((n===B.RUNNING||n===B.PENDING)&&Y(!0),I(null))},[e,n,U]),r.useEffect(()=>{if(!e)return;const s=k.getSocket(),f=P.current,u=z.current,m=G.current;K(s.connected);let O=!j(n);const S=()=>{y.current+=1,K(!0),b.current?.()},p=()=>{y.current+=1,K(!1),N(!1),g.current=!1,f[e]=[],u.get(e)?.controller.abort();const c=m.get(e);c!==void 0&&(window.clearTimeout(c),m.delete(e))},se=c=>{if(c.sessionId!==e)return;if(Y(!0),I(null),!g.current){f[e]=[...f[e]??[],c],b.current?.();return}const D=L.getState();if(!D.applyPatch(e,c.patch,c.seq)){g.current=!1,f[e]=[],b.current?.();return}const x=D.getConversation(e)?.entries??[],A=ne(x,ee.current);T.current.processingStartedAt!==A?.processingStartedAt&&(T.current={sessionId:e,processingStartedAt:A?.processingStartedAt}),pe(c.patch,x)&&(T.current.lastOutputAt=Date.now()),C(!0)},H=c=>{c.sessionId===e&&(Z(c.agentSessionId),X.current.onAgentSessionId?.(c.agentSessionId))},R=c=>{c.sessionId===e&&(O=!1,N(!1),C(!1),Y(!1),I(Date.now()),X.current.onExit?.(c.exitCode))},_=c=>{c.sessionId===e&&X.current.onError?.(c.message)};return s.on("connect",S),s.on("disconnect",p),s.on(v.SESSION_PATCH,se),s.on(v.SESSION_ID,H),s.on(v.SESSION_EXIT,R),s.on(v.SESSION_ERROR,_),K(s.connected),()=>{s.off("connect",S),s.off("disconnect",p),s.off(v.SESSION_PATCH,se),s.off(v.SESSION_ID,H),s.off(v.SESSION_EXIT,R),s.off(v.SESSION_ERROR,_),y.current+=1,u.get(e)?.controller.abort();const c=m.get(e);c!==void 0&&(window.clearTimeout(c),m.delete(e)),g.current=!1,f[e]=[],Z(null),C(!1),I(null),N(!1),O||L.getState().truncateSession(e)}},[e]);const te=r.useCallback(()=>{if(!e)return Promise.resolve(!1);const s=e,f=y.current,u=()=>F.current===s,m=z.current.get(s);if(m)return m.epoch!==f&&(m.reloadRequested=!0,m.controller.abort()),m.promise;const O=G.current.get(s);O!==void 0&&(window.clearTimeout(O),G.current.delete(s));const S=new AbortController,p={controller:S,epoch:f,promise:Promise.resolve(!1),reloadRequested:!1},H=(async()=>{const R=L.getState(),_=R.conversations[s];_&&_.entries.length>0&&(R.touchAccess(s),u()&&C(de(J.current))),u()&&(g.current=!1,N(!1)),!(_&&_.entries.length>0)&&u()&&oe(!0);for(let D=0;D<=le.length;D+=1){const $=k.getSocket();if(S.signal.aborted||!$.connected||!u()||p.epoch!==y.current)return!1;P.current[s]=[];try{const x=Pe(await Te.get(`/sessions/${s}/logs`,{cache:"no-store",signal:S.signal}));if(S.signal.aborted||!$.connected||!u()||p.epoch!==y.current)return p.reloadRequested=$.connected&&u(),!1;const A=P.current[s]??[];P.current[s]=[];let E=x,w=Ke(x);for(const h of A){if(typeof h.seq=="number"){if(h.seq<=w)continue;if(h.seq!==w+1)throw new Error(`Buffered patch sequence gap: expected ${w+1}, received ${h.seq}`)}E=De(E,h.patch,!0,!1).newDocument,typeof h.seq=="number"&&h.seq>w&&(w=h.seq)}E={...E,seq:w,isTruncated:!1};const Ne=ne(E.entries,ee.current);T.current={sessionId:s,processingStartedAt:Ne?.processingStartedAt,lastOutputAt:A.some(h=>pe(h.patch,E.entries))?Date.now():void 0};const Ce=R.getConversation(s);if(A.length>0||$e(Ce,E)?R.setConversation(s,E):R.touchAccess(s),u()){g.current=!0,N(!0);const h=L.getState().getConversation(s);h&&h.entries.length>0&&C(de(J.current))}return!0}catch(x){if(S.signal.aborted||he(x))return!1;if(!u()||p.epoch!==y.current||!$.connected)return p.reloadRequested=$.connected&&u(),!1;if(console.error("[useNormalizedLogs:loadSnapshot] Failed to reconcile snapshot:",x),P.current[s]=[],g.current=!1,N(!1),C(!1),!Be(x))return!1;const A=le[D];if(A===void 0){const ae=p.epoch,w=window.setTimeout(()=>{G.current.delete(s),F.current===s&&y.current===ae&&k.getSocket().connected&&b.current?.()},He);return G.current.set(s,w),!1}if(!await Ve(A,S.signal))return!1}}return!1})().finally(()=>{z.current.get(s)===p&&z.current.delete(s),p.reloadRequested&&F.current===s&&k.getSocket().connected&&queueMicrotask(()=>{b.current?.()}),F.current===s&&oe(!1)});return p.promise=H,z.current.set(s,p),H},[e]);b.current=te;const ye=r.useCallback(()=>new Promise(s=>{if(!k.getSocket().connected){s(!1);return}if(g.current){const u=L.getState().getConversation(e);if(!(j(J.current)||u?.isTruncated===!0)){s(!0);return}}te().then(s)}),[e,te]);r.useEffect(()=>{if(!e||!j(n))return;const s=window.setTimeout(()=>{b.current?.()},Fe);return()=>window.clearTimeout(s)},[e,n]);const Re=r.useCallback(s=>{k.getSocket().emit(be.INPUT,{sessionId:e,data:s})},[e]),we=r.useCallback(()=>{L.getState().removeSession(e),Z(null),C(!1),Y(!1),I(null),N(!1),g.current=!1,P.current[e]=[]},[e]),ve=r.useMemo(()=>{const s=Le(W.entries);if(ce&&Q){const f=ne(W.entries,q),u=T.current,O=u.sessionId===e&&u.processingStartedAt===f?.processingStartedAt&&u.lastOutputAt?Math.max(u.lastOutputAt,f?.lastOutputAt??0):f?.lastOutputAt;s.push(qe({processingStartedAt:f?.processingStartedAt,lastOutputAt:O}))}return s},[W.entries,ce,Q,e,q]);return{isConnected:V,isAttached:Q,isLoadingSnapshot:Se,isOutputActive:Ae,lastExitAt:Ee,logs:ve,entries:W.entries,agentSessionId:xe,attach:ye,sendInput:Re,clearLogs:we}}export{et as P,tt as T,st as a,nt as u};
1
+ import{k as re,u as Ie,r,j as d,U as k,V as v,W as be,p as Te}from"./index-BziFEuBL.js";import{C as Oe}from"./chevron-down-B8PIP1yU.js";import{C as _e}from"./check-CIGH6GLr.js";import{c as L,E as ke,S as B,n as Le,d as qe,e as Pe,f as De,s as $e}from"./mermaid-NOHMQCX5-Cxj8y3xL.js";const je=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}]],Me=re("circle-dot",je);const Ue=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],ie=re("circle",Ue);const Ye=[["path",{d:"m16 6-8.414 8.586a2 2 0 0 0 2.829 2.829l8.414-8.586a4 4 0 1 0-5.657-5.657l-8.379 8.551a6 6 0 1 0 8.485 8.485l8.379-8.551",key:"1miecu"}]],et=re("paperclip",Ye),ue="agent-tower-todo-panel-open";function ze(t,e){const n=e?"h-3 w-3":"h-3.5 w-3.5",a=(t||"").toLowerCase();return a==="completed"?d.jsx(_e,{"aria-hidden":!0,className:`${n} text-emerald-500`}):a==="in_progress"||a==="in-progress"?d.jsx(Me,{"aria-hidden":!0,className:`${n} text-blue-500`}):a==="cancelled"?d.jsx(ie,{"aria-hidden":!0,className:`${n} text-neutral-300`}):d.jsx(ie,{"aria-hidden":!0,className:`${n} text-neutral-400`})}function tt({todos:t,compact:e}){const{t:n}=Ie(),[a,o]=r.useState(()=>{if(e)return!1;const i=localStorage.getItem(ue);return i===null?!0:i==="true"});if(r.useEffect(()=>{localStorage.setItem(ue,String(a))},[a]),!t||t.length===0)return null;const l=t.filter(i=>i.status?.toLowerCase()==="completed").length,M=t.length>0?l/t.length*100:0;return d.jsxs("details",{className:"group",open:a,onToggle:i=>o(i.target.open),children:[d.jsx("summary",{className:"list-none cursor-pointer select-none [&::-webkit-details-marker]:hidden",children:d.jsxs("div",{className:`bg-neutral-50/80 border border-neutral-100 rounded-lg flex items-center justify-between hover:bg-neutral-100/80 transition-colors ${e?"px-3 py-1.5":"px-3 py-2"}`,children:[d.jsxs("div",{className:"flex items-center gap-2 min-w-0",children:[d.jsx("span",{className:"text-neutral-500 font-medium text-xs",children:n("待办")}),d.jsxs("span",{className:"text-neutral-400 tabular-nums text-xs",children:[l,"/",t.length]}),d.jsx("div",{className:"w-12 h-1 bg-neutral-200/60 rounded-full overflow-hidden",children:d.jsx("div",{className:"h-full bg-emerald-400 rounded-full transition-all duration-300",style:{width:`${M}%`}})})]}),d.jsx(Oe,{"aria-hidden":!0,className:`text-neutral-400 transition-transform group-open:rotate-180 ${e?"h-3 w-3":"h-3.5 w-3.5"}`})]})}),d.jsx("div",{className:`pt-1.5 pb-0.5 ${e?"max-h-28 overflow-y-auto px-1":"px-1"}`,children:d.jsx("ul",{className:"space-y-px",role:"list","aria-label":"Agent todo list",children:t.map((i,q)=>{const U=i.status?.toLowerCase()==="cancelled",V=i.status?.toLowerCase()==="completed";return d.jsxs("li",{className:`flex items-center gap-1.5 rounded-md px-2 ${e?"py-0.5":"py-[3px]"} ${V?"opacity-60":""}`,children:[d.jsx("span",{className:`flex items-center justify-center shrink-0 ${e?"h-3 w-3":"h-3.5 w-3.5"}`,children:ze(i.status,e)}),d.jsx("span",{className:`${e?"text-[11px] leading-[14px]":"text-xs leading-4"} text-neutral-600 wrap-break-word truncate ${U?"line-through text-neutral-400":""} ${V?"text-neutral-400":""}`,children:i.content})]},`${i.content}-${q}`)})})})]})}function st(t){return r.useMemo(()=>{let e=[],n=0;for(const o of t)if(o.entryType==="tool_use"&&o.metadata?.action==="todo_management"&&o.metadata.todos&&o.metadata.todos.length>0){const l=o.metadata.todos;l.every(i=>i.content&&i.content.trim().length>0&&i.status)&&o.timestamp>=n&&(e=l,n=o.timestamp)}const a=e.find(o=>{const l=o.status?.toLowerCase();return l==="in_progress"||l==="in-progress"})??null;return{todos:e,inProgressTodo:a}},[t])}const Ge=!1,Fe=1500,le=[250,1e3,3e3],He=1e4;function he(t){return t instanceof DOMException&&t.name==="AbortError"}function Be(t){if(he(t))return!1;const e=typeof t=="object"&&t!==null&&"status"in t?t.status:void 0;return typeof e!="number"?!0:e===408||e===429||e>=500}function Ve(t,e){return new Promise(n=>{if(e.aborted){n(!1);return}const a=window.setTimeout(()=>{e.removeEventListener("abort",o),n(!0)},t),o=()=>{window.clearTimeout(a),n(!1)};e.addEventListener("abort",o,{once:!0})})}function j(t){return t===B.COMPLETED||t===B.FAILED||t===B.CANCELLED}function Ke(t){return typeof t?.seq=="number"?t.seq:0}function de(t){return!j(t)}function me(t){return t.entryType==="user_message"||t.entryType==="user_feedback"}function ge(t){return!me(t)&&t.entryType!=="loading"&&t.entryType!=="token_usage_info"&&t.content.trim()!==""}function ne(t,e){let n=e,a,o;for(const l of t)o??=l.timestamp,me(l)?(n=l.timestamp,a=void 0):ge(l)&&(n??=l.timestamp,a=l.timestamp);return{processingStartedAt:n??o,lastOutputAt:a}}function fe(t){if(typeof t=="number")return Number.isFinite(t)?t:void 0;if(typeof t!="string"||t.trim()==="")return;const e=Date.parse(t);return Number.isNaN(e)?void 0:e}function pe(t,e){return t.some(n=>{if(n.op==="remove")return!1;const a=n.path.match(/^\/entries\/(\d+)(?:\/|$)/);if(!a)return!1;const o=e[Number(a[1])];return o?ge(o):!1})}function nt(t){const{sessionId:e,sessionStatus:n,sessionStartedAt:a,sessionEndedAt:o,onAgentSessionId:l,onExit:M,onError:i}=t,q=fe(a),U=fe(o),[V,K]=r.useState(()=>k.isConnected()),[Q,N]=r.useState(!1),[Se,oe]=r.useState(!1),[xe,Z]=r.useState(null),[ce,C]=r.useState(!1),[Ae,Y]=r.useState(()=>!j(n)),[Ee,I]=r.useState(()=>U??null),W=L(r.useCallback(s=>s.conversations[e]??ke,[e])),g=r.useRef(!1),P=r.useRef({}),b=r.useRef(null),z=r.useRef(new Map),G=r.useRef(new Map),y=r.useRef(0),ee=r.useRef(q);ee.current=q;const T=r.useRef({sessionId:e});T.current.sessionId!==e&&(T.current={sessionId:e});const F=r.useRef(e);F.current=e;const X=r.useRef({onAgentSessionId:l,onExit:M,onError:i});X.current={onAgentSessionId:l,onExit:M,onError:i};const J=r.useRef(n);J.current=n,r.useEffect(()=>{j(n)?(Y(!1),I(U??null)):((n===B.RUNNING||n===B.PENDING)&&Y(!0),I(null))},[e,n,U]),r.useEffect(()=>{if(!e)return;const s=k.getSocket(),f=P.current,u=z.current,m=G.current;K(s.connected);let O=!j(n);const S=()=>{y.current+=1,K(!0),b.current?.()},p=()=>{y.current+=1,K(!1),N(!1),g.current=!1,f[e]=[],u.get(e)?.controller.abort();const c=m.get(e);c!==void 0&&(window.clearTimeout(c),m.delete(e))},se=c=>{if(c.sessionId!==e)return;if(Y(!0),I(null),!g.current){f[e]=[...f[e]??[],c],b.current?.();return}const D=L.getState();if(!D.applyPatch(e,c.patch,c.seq)){g.current=!1,f[e]=[],b.current?.();return}const x=D.getConversation(e)?.entries??[],A=ne(x,ee.current);T.current.processingStartedAt!==A?.processingStartedAt&&(T.current={sessionId:e,processingStartedAt:A?.processingStartedAt}),pe(c.patch,x)&&(T.current.lastOutputAt=Date.now()),C(!0)},H=c=>{c.sessionId===e&&(Z(c.agentSessionId),X.current.onAgentSessionId?.(c.agentSessionId))},R=c=>{c.sessionId===e&&(O=!1,N(!1),C(!1),Y(!1),I(Date.now()),X.current.onExit?.(c.exitCode))},_=c=>{c.sessionId===e&&X.current.onError?.(c.message)};return s.on("connect",S),s.on("disconnect",p),s.on(v.SESSION_PATCH,se),s.on(v.SESSION_ID,H),s.on(v.SESSION_EXIT,R),s.on(v.SESSION_ERROR,_),K(s.connected),()=>{s.off("connect",S),s.off("disconnect",p),s.off(v.SESSION_PATCH,se),s.off(v.SESSION_ID,H),s.off(v.SESSION_EXIT,R),s.off(v.SESSION_ERROR,_),y.current+=1,u.get(e)?.controller.abort();const c=m.get(e);c!==void 0&&(window.clearTimeout(c),m.delete(e)),g.current=!1,f[e]=[],Z(null),C(!1),I(null),N(!1),O||L.getState().truncateSession(e)}},[e]);const te=r.useCallback(()=>{if(!e)return Promise.resolve(!1);const s=e,f=y.current,u=()=>F.current===s,m=z.current.get(s);if(m)return m.epoch!==f&&(m.reloadRequested=!0,m.controller.abort()),m.promise;const O=G.current.get(s);O!==void 0&&(window.clearTimeout(O),G.current.delete(s));const S=new AbortController,p={controller:S,epoch:f,promise:Promise.resolve(!1),reloadRequested:!1},H=(async()=>{const R=L.getState(),_=R.conversations[s];_&&_.entries.length>0&&(R.touchAccess(s),u()&&C(de(J.current))),u()&&(g.current=!1,N(!1)),!(_&&_.entries.length>0)&&u()&&oe(!0);for(let D=0;D<=le.length;D+=1){const $=k.getSocket();if(S.signal.aborted||!$.connected||!u()||p.epoch!==y.current)return!1;P.current[s]=[];try{const x=Pe(await Te.get(`/sessions/${s}/logs`,{cache:"no-store",signal:S.signal}));if(S.signal.aborted||!$.connected||!u()||p.epoch!==y.current)return p.reloadRequested=$.connected&&u(),!1;const A=P.current[s]??[];P.current[s]=[];let E=x,w=Ke(x);for(const h of A){if(typeof h.seq=="number"){if(h.seq<=w)continue;if(h.seq!==w+1)throw new Error(`Buffered patch sequence gap: expected ${w+1}, received ${h.seq}`)}E=De(E,h.patch,!0,!1).newDocument,typeof h.seq=="number"&&h.seq>w&&(w=h.seq)}E={...E,seq:w,isTruncated:!1};const Ne=ne(E.entries,ee.current);T.current={sessionId:s,processingStartedAt:Ne?.processingStartedAt,lastOutputAt:A.some(h=>pe(h.patch,E.entries))?Date.now():void 0};const Ce=R.getConversation(s);if(A.length>0||$e(Ce,E)?R.setConversation(s,E):R.touchAccess(s),u()){g.current=!0,N(!0);const h=L.getState().getConversation(s);h&&h.entries.length>0&&C(de(J.current))}return!0}catch(x){if(S.signal.aborted||he(x))return!1;if(!u()||p.epoch!==y.current||!$.connected)return p.reloadRequested=$.connected&&u(),!1;if(console.error("[useNormalizedLogs:loadSnapshot] Failed to reconcile snapshot:",x),P.current[s]=[],g.current=!1,N(!1),C(!1),!Be(x))return!1;const A=le[D];if(A===void 0){const ae=p.epoch,w=window.setTimeout(()=>{G.current.delete(s),F.current===s&&y.current===ae&&k.getSocket().connected&&b.current?.()},He);return G.current.set(s,w),!1}if(!await Ve(A,S.signal))return!1}}return!1})().finally(()=>{z.current.get(s)===p&&z.current.delete(s),p.reloadRequested&&F.current===s&&k.getSocket().connected&&queueMicrotask(()=>{b.current?.()}),F.current===s&&oe(!1)});return p.promise=H,z.current.set(s,p),H},[e]);b.current=te;const ye=r.useCallback(()=>new Promise(s=>{if(!k.getSocket().connected){s(!1);return}if(g.current){const u=L.getState().getConversation(e);if(!(j(J.current)||u?.isTruncated===!0)){s(!0);return}}te().then(s)}),[e,te]);r.useEffect(()=>{if(!e||!j(n))return;const s=window.setTimeout(()=>{b.current?.()},Fe);return()=>window.clearTimeout(s)},[e,n]);const Re=r.useCallback(s=>{k.getSocket().emit(be.INPUT,{sessionId:e,data:s})},[e]),we=r.useCallback(()=>{L.getState().removeSession(e),Z(null),C(!1),Y(!1),I(null),N(!1),g.current=!1,P.current[e]=[]},[e]),ve=r.useMemo(()=>{const s=Le(W.entries);if(ce&&Q){const f=ne(W.entries,q),u=T.current,O=u.sessionId===e&&u.processingStartedAt===f?.processingStartedAt&&u.lastOutputAt?Math.max(u.lastOutputAt,f?.lastOutputAt??0):f?.lastOutputAt;s.push(qe({processingStartedAt:f?.processingStartedAt,lastOutputAt:O}))}return s},[W.entries,ce,Q,e,q]);return{isConnected:V,isAttached:Q,isLoadingSnapshot:Se,isOutputActive:Ae,lastExitAt:Ee,logs:ve,entries:W.entries,agentSessionId:xe,attach:ye,sendInput:Re,clearLogs:we}}export{et as P,tt as T,st as a,nt as u};
@@ -1,4 +1,4 @@
1
- import{aU as Gt,s as Wt,g as Kt,q as Ht,p as Yt,a as Xt,b as Zt,_ as w,D as wt,I as Jt,d as ot,al as Qt,ac as $t,ad as te,ae as ee,e as ne,z as se,F as ie,G as oe}from"./index--1agBpnq.js";import"./index-BVh0eL1_.js";const kt=(t,n)=>Gt(t,"a",-n),_t=1e-10;function st(t,n){const s=ae(t),e=s.filter(c=>re(c,t));let i=0,o=0;const a=[];if(e.length>1){const c=Et(e);for(let u=0;u<e.length;++u){const r=e[u];r.angle=Math.atan2(r.x-c.x,r.y-c.y)}e.sort((u,r)=>r.angle-u.angle);let h=e[e.length-1];for(let u=0;u<e.length;++u){const r=e[u];o+=(h.x+r.x)*(r.y-h.y);const y={x:(r.x+h.x)/2,y:(r.y+h.y)/2};let d=null;for(let b=0;b<r.parentIndex.length;++b)if(h.parentIndex.includes(r.parentIndex[b])){const x=t[r.parentIndex[b]],M=Math.atan2(r.x-x.x,r.y-x.y),A=Math.atan2(h.x-x.x,h.y-x.y);let T=A-M;T<0&&(T+=2*Math.PI);const S=A-T/2;let g=q(y,{x:x.x+x.radius*Math.sin(S),y:x.y+x.radius*Math.cos(S)});g>x.radius*2&&(g=x.radius*2),(d==null||d.width>g)&&(d={circle:x,width:g,p1:r,p2:h,large:g>x.radius,sweep:!0})}d!=null&&(a.push(d),i+=lt(d.circle.radius,d.width),h=r)}}else{let c=t[0];for(let u=1;u<t.length;++u)t[u].radius<c.radius&&(c=t[u]);let h=!1;for(let u=0;u<t.length;++u)if(q(t[u],c)>Math.abs(c.radius-t[u].radius)){h=!0;break}h?i=o=0:(i=c.radius*c.radius*Math.PI,a.push({circle:c,p1:{x:c.x,y:c.y+c.radius},p2:{x:c.x-_t,y:c.y+c.radius},width:c.radius*2,large:!0,sweep:!0}))}return o/=2,n&&(n.area=i+o,n.arcArea=i,n.polygonArea=o,n.arcs=a,n.innerPoints=e,n.intersectionPoints=s),i+o}function re(t,n){return n.every(s=>q(t,s)<s.radius+_t)}function ae(t){const n=[];for(let s=0;s<t.length;++s)for(let e=s+1;e<t.length;++e){const i=Tt(t[s],t[e]);for(const o of i)o.parentIndex=[s,e],n.push(o)}return n}function lt(t,n){return t*t*Math.acos(1-n/t)-(t-n)*Math.sqrt(n*(2*t-n))}function q(t,n){return Math.sqrt((t.x-n.x)*(t.x-n.x)+(t.y-n.y)*(t.y-n.y))}function xt(t,n,s){if(s>=t+n)return 0;if(s<=Math.abs(t-n))return Math.PI*Math.min(t,n)*Math.min(t,n);const e=t-(s*s-n*n+t*t)/(2*s),i=n-(s*s-t*t+n*n)/(2*s);return lt(t,e)+lt(n,i)}function Tt(t,n){const s=q(t,n),e=t.radius,i=n.radius;if(s>=e+i||s<=Math.abs(e-i))return[];const o=(e*e-i*i+s*s)/(2*s),a=Math.sqrt(e*e-o*o),c=t.x+o*(n.x-t.x)/s,h=t.y+o*(n.y-t.y)/s,u=-(n.y-t.y)*(a/s),r=-(n.x-t.x)*(a/s);return[{x:c+u,y:h-r},{x:c-u,y:h+r}]}function Et(t){const n={x:0,y:0};for(const s of t)n.x+=s.x,n.y+=s.y;return n.x/=t.length,n.y/=t.length,n}function le(t,n,s,e){e=e||{};const i=e.maxIterations||100,o=e.tolerance||1e-10,a=t(n),c=t(s);let h=s-n;if(a*c>0)throw"Initial bisect points must have opposite signs";if(a===0)return n;if(c===0)return s;for(let u=0;u<i;++u){h/=2;const r=n+h,y=t(r);if(y*a>=0&&(n=r),Math.abs(h)<o||y===0)return r}return n+h}function ct(t){const n=new Array(t);for(let s=0;s<t;++s)n[s]=0;return n}function Mt(t,n){return ct(t).map(()=>ct(n))}function $(t,n){let s=0;for(let e=0;e<t.length;++e)s+=t[e]*n[e];return s}function ut(t){return Math.sqrt($(t,t))}function ft(t,n,s){for(let e=0;e<n.length;++e)t[e]=n[e]*s}function J(t,n,s,e,i){for(let o=0;o<t.length;++o)t[o]=n*s[o]+e*i[o]}function zt(t,n,s){s=s||{};const e=s.maxIterations||n.length*200,i=s.nonZeroDelta||1.05,o=s.zeroDelta||.001,a=s.minErrorDelta||1e-6,c=s.minErrorDelta||1e-5,h=s.rho!==void 0?s.rho:1,u=s.chi!==void 0?s.chi:2,r=s.psi!==void 0?s.psi:-.5,y=s.sigma!==void 0?s.sigma:.5;let d;const b=n.length,x=new Array(b+1);x[0]=n,x[0].fx=t(n),x[0].id=0;for(let v=0;v<b;++v){const l=n.slice();l[v]=l[v]?l[v]*i:o,x[v+1]=l,x[v+1].fx=t(l),x[v+1].id=v+1}function M(v){for(let l=0;l<v.length;l++)x[b][l]=v[l];x[b].fx=v.fx}const A=(v,l)=>v.fx-l.fx,T=n.slice(),S=n.slice(),g=n.slice(),m=n.slice();for(let v=0;v<e;++v){if(x.sort(A),s.history){const p=x.map(f=>{const N=f.slice();return N.fx=f.fx,N.id=f.id,N});p.sort((f,N)=>f.id-N.id),s.history.push({x:x[0].slice(),fx:x[0].fx,simplex:p})}d=0;for(let p=0;p<b;++p)d=Math.max(d,Math.abs(x[0][p]-x[1][p]));if(Math.abs(x[0].fx-x[b].fx)<a&&d<c)break;for(let p=0;p<b;++p){T[p]=0;for(let f=0;f<b;++f)T[p]+=x[f][p];T[p]/=b}const l=x[b];if(J(S,1+h,T,-h,l),S.fx=t(S),S.fx<x[0].fx)J(m,1+u,T,-u,l),m.fx=t(m),m.fx<S.fx?M(m):M(S);else if(S.fx>=x[b-1].fx){let p=!1;if(S.fx>l.fx?(J(g,1+r,T,-r,l),g.fx=t(g),g.fx<l.fx?M(g):p=!0):(J(g,1-r*h,T,r*h,l),g.fx=t(g),g.fx<S.fx?M(g):p=!0),p){if(y>=1)break;for(let f=1;f<x.length;++f)J(x[f],1-y,x[0],y,x[f]),x[f].fx=t(x[f])}}else M(S)}return x.sort(A),{fx:x[0].fx,x:x[0]}}function ce(t,n,s,e,i,o,a){const c=s.fx,h=$(s.fxprime,n);let u=c,r=c,y=h,d=0;i=i||1,o=o||1e-6,a=a||.1;function b(x,M,A){for(let T=0;T<16;++T)if(i=(x+M)/2,J(e.x,1,s.x,i,n),u=e.fx=t(e.x,e.fxprime),y=$(e.fxprime,n),u>c+o*i*h||u>=A)M=i;else{if(Math.abs(y)<=-a*h)return i;y*(M-x)>=0&&(M=x),x=i,A=u}return 0}for(let x=0;x<10;++x){if(J(e.x,1,s.x,i,n),u=e.fx=t(e.x,e.fxprime),y=$(e.fxprime,n),u>c+o*i*h||x&&u>=r)return b(d,i,r);if(Math.abs(y)<=-a*h)return i;if(y>=0)return b(i,d,u);r=u,d=i,i*=2}return i}function ue(t,n,s){let e={x:n.slice(),fx:0,fxprime:n.slice()},i={x:n.slice(),fx:0,fxprime:n.slice()};const o=n.slice();let a,c,h=1,u;s=s||{},u=s.maxIterations||n.length*20,e.fx=t(e.x,e.fxprime),a=e.fxprime.slice(),ft(a,e.fxprime,-1);for(let r=0;r<u;++r){if(h=ce(t,a,e,i,h),s.history&&s.history.push({x:e.x.slice(),fx:e.fx,fxprime:e.fxprime.slice(),alpha:h}),!h)ft(a,e.fxprime,-1);else{J(o,1,i.fxprime,-1,e.fxprime);const y=$(e.fxprime,e.fxprime),d=Math.max(0,$(o,i.fxprime)/y);J(a,d,a,-1,i.fxprime),c=e,e=i,i=c}if(ut(e.fxprime)<=1e-5)break}return s.history&&s.history.push({x:e.x.slice(),fx:e.fx,fxprime:e.fxprime.slice(),alpha:h}),e}function At(t,n={}){n.maxIterations=n.maxIterations||500;const s=n.initialLayout||ge,e=n.lossFunction||tt,i=fe(t,n),o=s(i,n),a=Object.keys(o),c=[];for(const r of a)c.push(o[r].x),c.push(o[r].y);const u=zt(r=>{const y={};for(let d=0;d<a.length;++d){const b=a[d];y[b]={x:r[2*d],y:r[2*d+1],radius:o[b].radius}}return e(y,i)},c,n).x;for(let r=0;r<a.length;++r){const y=a[r];o[y].x=u[2*r],o[y].y=u[2*r+1]}return o}const Rt=1e-10;function ht(t,n,s){return Math.min(t,n)*Math.min(t,n)*Math.PI<=s+Rt?Math.abs(t-n):le(e=>xt(t,n,e)-s,0,t+n)}function fe(t,n={}){const s=n.distinct,e=t.map(c=>Object.assign({},c));function i(c){return c.join(";")}if(s){const c=new Map;for(const h of e)for(let u=0;u<h.sets.length;u++){const r=String(h.sets[u]);c.set(r,h.size+(c.get(r)||0));for(let y=u+1;y<h.sets.length;y++){const d=String(h.sets[y]),b=`${r};${d}`,x=`${d};${r}`;c.set(b,h.size+(c.get(b)||0)),c.set(x,h.size+(c.get(x)||0))}}for(const h of e)h.sets.length<3&&(h.size=c.get(i(h.sets)))}const o=[],a=new Set;for(const c of e)if(c.sets.length===1)o.push(c.sets[0]);else if(c.sets.length===2){const h=c.sets[0],u=c.sets[1];a.add(i(c.sets)),a.add(i([u,h]))}o.sort((c,h)=>c===h?0:c<h?-1:1);for(let c=0;c<o.length;++c){const h=o[c];for(let u=c+1;u<o.length;++u){const r=o[u];a.has(i([h,r]))||e.push({sets:[h,r],size:0})}}return e}function he(t,n,s){const e=Mt(n.length,n.length),i=Mt(n.length,n.length);return t.filter(o=>o.sets.length===2).forEach(o=>{const a=s[o.sets[0]],c=s[o.sets[1]],h=Math.sqrt(n[a].size/Math.PI),u=Math.sqrt(n[c].size/Math.PI),r=ht(h,u,o.size);e[a][c]=e[c][a]=r;let y=0;o.size+1e-10>=Math.min(n[a].size,n[c].size)?y=1:o.size<=1e-10&&(y=-1),i[a][c]=i[c][a]=y}),{distances:e,constraints:i}}function de(t,n,s,e){for(let o=0;o<n.length;++o)n[o]=0;let i=0;for(let o=0;o<s.length;++o){const a=t[2*o],c=t[2*o+1];for(let h=o+1;h<s.length;++h){const u=t[2*h],r=t[2*h+1],y=s[o][h],d=e[o][h],b=(u-a)*(u-a)+(r-c)*(r-c),x=Math.sqrt(b),M=b-y*y;d>0&&x<=y||d<0&&x>=y||(i+=2*M*M,n[2*o]+=4*M*(a-u),n[2*o+1]+=4*M*(c-r),n[2*h]+=4*M*(u-a),n[2*h+1]+=4*M*(r-c))}}return i}function ge(t,n={}){let s=ye(t,n);const e=n.lossFunction||tt;if(t.length>=8){const i=xe(t,n),o=e(i,t),a=e(s,t);o+1e-8<a&&(s=i)}return s}function xe(t,n={}){const s=n.restarts||10,e=[],i={};for(const d of t)d.sets.length===1&&(i[d.sets[0]]=e.length,e.push(d));let{distances:o,constraints:a}=he(t,e,i);const c=ut(o.map(ut))/o.length;o=o.map(d=>d.map(b=>b/c));const h=(d,b)=>de(d,b,o,a);let u=null;for(let d=0;d<s;++d){const b=ct(o.length*2).map(Math.random),x=ue(h,b,n);(!u||x.fx<u.fx)&&(u=x)}const r=u.x,y={};for(let d=0;d<e.length;++d){const b=e[d];y[b.sets[0]]={x:r[2*d]*c,y:r[2*d+1]*c,radius:Math.sqrt(b.size/Math.PI)}}if(n.history)for(const d of n.history)ft(d.x,c);return y}function ye(t,n){const s=n&&n.lossFunction?n.lossFunction:tt,e={},i={};for(const y of t)if(y.sets.length===1){const d=y.sets[0];e[d]={x:1e10,y:1e10,rowid:e.length,size:y.size,radius:Math.sqrt(y.size/Math.PI)},i[d]=[]}t=t.filter(y=>y.sets.length===2);for(const y of t){let d=y.weight!=null?y.weight:1;const b=y.sets[0],x=y.sets[1];y.size+Rt>=Math.min(e[b].size,e[x].size)&&(d=0),i[b].push({set:x,size:y.size,weight:d}),i[x].push({set:b,size:y.size,weight:d})}const o=[];Object.keys(i).forEach(y=>{let d=0;for(let b=0;b<i[y].length;++b)d+=i[y][b].size*i[y][b].weight;o.push({set:y,size:d})});function a(y,d){return d.size-y.size}o.sort(a);const c={};function h(y){return y.set in c}function u(y,d){e[d].x=y.x,e[d].y=y.y,c[d]=!0}u({x:0,y:0},o[0].set);for(let y=1;y<o.length;++y){const d=o[y].set,b=i[d].filter(h),x=e[d];if(b.sort(a),b.length===0)throw"ERROR: missing pairwise overlap information";const M=[];for(var r=0;r<b.length;++r){const S=e[b[r].set],g=ht(x.radius,S.radius,b[r].size);M.push({x:S.x+g,y:S.y}),M.push({x:S.x-g,y:S.y}),M.push({y:S.y+g,x:S.x}),M.push({y:S.y-g,x:S.x});for(let m=r+1;m<b.length;++m){const v=e[b[m].set],l=ht(x.radius,v.radius,b[m].size),p=Tt({x:S.x,y:S.y,radius:g},{x:v.x,y:v.y,radius:l});M.push(...p)}}let A=1e50,T=M[0];for(const S of M){e[d].x=S.x,e[d].y=S.y;const g=s(e,t);g<A&&(A=g,T=S)}u(T,d)}return e}function tt(t,n){let s=0;for(const e of n){if(e.sets.length===1)continue;let i;if(e.sets.length===2){const a=t[e.sets[0]],c=t[e.sets[1]];i=xt(a.radius,c.radius,q(a,c))}else i=st(e.sets.map(a=>t[a]));const o=e.weight!=null?e.weight:1;s+=o*(i-e.size)*(i-e.size)}return s}function Dt(t,n){let s=0;for(const e of n){if(e.sets.length===1)continue;let i;if(e.sets.length===2){const c=t[e.sets[0]],h=t[e.sets[1]];i=xt(c.radius,h.radius,q(c,h))}else i=st(e.sets.map(c=>t[c]));const o=e.weight!=null?e.weight:1,a=Math.log((i+1)/(e.size+1));s+=o*a*a}return s}function pe(t,n,s){if(s==null?t.sort((i,o)=>o.radius-i.radius):t.sort(s),t.length>0){const i=t[0].x,o=t[0].y;for(const a of t)a.x-=i,a.y-=o}if(t.length===2&&q(t[0],t[1])<Math.abs(t[1].radius-t[0].radius)&&(t[1].x=t[0].x+t[0].radius-t[1].radius-1e-10,t[1].y=t[0].y),t.length>1){const i=Math.atan2(t[1].x,t[1].y)-n,o=Math.cos(i),a=Math.sin(i);for(const c of t){const h=c.x,u=c.y;c.x=o*h-a*u,c.y=a*h+o*u}}if(t.length>2){let i=Math.atan2(t[2].x,t[2].y)-n;for(;i<0;)i+=2*Math.PI;for(;i>2*Math.PI;)i-=2*Math.PI;if(i>Math.PI){const o=t[1].y/(1e-10+t[1].x);for(const a of t){var e=(a.x+o*a.y)/(1+o*o);a.x=2*e-a.x,a.y=2*e*o-a.y}}}}function me(t){t.forEach(i=>{i.parent=i});function n(i){return i.parent!==i&&(i.parent=n(i.parent)),i.parent}function s(i,o){const a=n(i),c=n(o);a.parent=c}for(let i=0;i<t.length;++i)for(let o=i+1;o<t.length;++o){const a=t[i].radius+t[o].radius;q(t[i],t[o])+1e-10<a&&s(t[o],t[i])}const e=new Map;for(let i=0;i<t.length;++i){const o=n(t[i]).parent.setid;e.has(o)||e.set(o,[]),e.get(o).push(t[i])}return t.forEach(i=>{delete i.parent}),Array.from(e.values())}function dt(t){const n=s=>{const e=t.reduce((o,a)=>Math.max(o,a[s]+a.radius),Number.NEGATIVE_INFINITY),i=t.reduce((o,a)=>Math.min(o,a[s]-a.radius),Number.POSITIVE_INFINITY);return{max:e,min:i}};return{xRange:n("x"),yRange:n("y")}}function Ct(t,n,s){n==null&&(n=Math.PI/2);let e=Ft(t).map(u=>Object.assign({},u));const i=me(e);for(const u of i){pe(u,n,s);const r=dt(u);u.size=(r.xRange.max-r.xRange.min)*(r.yRange.max-r.yRange.min),u.bounds=r}i.sort((u,r)=>r.size-u.size),e=i[0];let o=e.bounds;const a=(o.xRange.max-o.xRange.min)/50;function c(u,r,y){if(!u)return;const d=u.bounds;let b,x;if(r)b=o.xRange.max-d.xRange.min+a;else{b=o.xRange.max-d.xRange.max;const M=(d.xRange.max-d.xRange.min)/2-(o.xRange.max-o.xRange.min)/2;M<0&&(b+=M)}if(y)x=o.yRange.max-d.yRange.min+a;else{x=o.yRange.max-d.yRange.max;const M=(d.yRange.max-d.yRange.min)/2-(o.yRange.max-o.yRange.min)/2;M<0&&(x+=M)}for(const M of u)M.x+=b,M.y+=x,e.push(M)}let h=1;for(;h<i.length;)c(i[h],!0,!1),c(i[h+1],!1,!0),c(i[h+2],!0,!0),h+=3,o=dt(e);return Ot(e)}function Nt(t,n,s,e,i){const o=Ft(t);n-=2*e,s-=2*e;const{xRange:a,yRange:c}=dt(o);if(a.max===a.min||c.max===c.min)return console.log("not scaling solution: zero size detected"),t;let h,u;if(i){const b=Math.sqrt(i/Math.PI)*2;h=n/b,u=s/b}else h=n/(a.max-a.min),u=s/(c.max-c.min);const r=Math.min(u,h),y=(n-(a.max-a.min)*r)/2,d=(s-(c.max-c.min)*r)/2;return Ot(o.map(b=>({radius:r*b.radius,x:e+y+(b.x-a.min)*r,y:e+d+(b.y-c.min)*r,setid:b.setid})))}function Ot(t){const n={};for(const s of t)n[s.setid]=s;return n}function Ft(t){return Object.keys(t).map(s=>Object.assign(t[s],{setid:s}))}function be(t={}){let n=!1,s=600,e=350,i=15,o=1e3,a=Math.PI/2,c=!0,h=null,u=!0,r=!0,y=null,d=null,b=!1,x=null,M=t&&t.symmetricalTextCentre?t.symmetricalTextCentre:!1,A={},T=t&&t.colourScheme?t.colourScheme:t&&t.colorScheme?t.colorScheme:["#1f77b4","#ff7f0e","#2ca02c","#d62728","#9467bd","#8c564b","#e377c2","#7f7f7f","#bcbd22","#17becf"],S=0,g=function(p){if(p in A)return A[p];var f=A[p]=T[S];return S+=1,S>=T.length&&(S=0),f},m=At,v=tt;function l(p){let f=p.datum();const N=new Set;f.forEach(k=>{k.size==0&&k.sets.length==1&&N.add(k.sets[0])}),f=f.filter(k=>!k.sets.some(F=>N.has(F)));let I={},D={};if(f.length>0){let k=m(f,{lossFunction:v,distinct:b});c&&(k=Ct(k,a,d)),I=Nt(k,s,e,i,h),D=jt(I,f,M)}const U={};f.forEach(k=>{k.label&&(U[k.sets]=k.label)});function j(k){if(k.sets in U)return U[k.sets];if(k.sets.length==1)return""+k.sets[0]}p.selectAll("svg").data([I]).enter().append("svg");const E=p.select("svg");n?E.attr("viewBox",`0 0 ${s} ${e}`):E.attr("width",s).attr("height",e);const R={};let _=!1;E.selectAll(".venn-area path").each(function(k){const F=this.getAttribute("d");k.sets.length==1&&F&&!b&&(_=!0,R[k.sets[0]]=ke(F))});function P(k){return F=>{const H=k.sets.map(et=>{let Y=R[et],Z=I[et];return Y||(Y={x:s/2,y:e/2,radius:1}),Z||(Z={x:s/2,y:e/2,radius:1}),{x:Y.x*(1-F)+Z.x*F,y:Y.y*(1-F)+Z.y*F,radius:Y.radius*(1-F)+Z.radius*F}});return St(H,x)}}const V=E.selectAll(".venn-area").data(f,k=>k.sets),O=V.enter().append("g").attr("class",k=>`venn-area venn-${k.sets.length==1?"circle":"intersection"}${k.colour||k.color?" venn-coloured":""}`).attr("data-venn-sets",k=>k.sets.join("_")),B=O.append("path"),W=O.append("text").attr("class","label").text(k=>j(k)).attr("text-anchor","middle").attr("dy",".35em").attr("x",s/2).attr("y",e/2);r&&(B.style("fill-opacity","0").filter(k=>k.sets.length==1).style("fill",k=>k.colour?k.colour:k.color?k.color:g(k.sets)).style("fill-opacity",".25"),W.style("fill",k=>k.colour||k.color?"#FFF":t.textFill?t.textFill:k.sets.length==1?g(k.sets):"#444"));function K(k){return typeof k.transition=="function"?k.transition("venn").duration(o):k}let z=p;_&&typeof z.transition=="function"?(z=K(p),z.selectAll("path").attrTween("d",P)):z.selectAll("path").attr("d",k=>St(k.sets.map(F=>I[F])),x);const L=z.selectAll("text").filter(k=>k.sets in D).text(k=>j(k)).attr("x",k=>Math.floor(D[k.sets].x)).attr("y",k=>Math.floor(D[k.sets].y));u&&(_?"on"in L?L.on("end",rt(I,j)):L.each("end",rt(I,j)):L.each(rt(I,j)));const C=K(V.exit()).remove();typeof V.transition=="function"&&C.selectAll("path").attrTween("d",P);const X=C.selectAll("text").attr("x",s/2).attr("y",e/2);return y!==null&&(W.style("font-size","0px"),L.style("font-size",y),X.style("font-size","0px")),{circles:I,textCentres:D,nodes:V,enter:O,update:z,exit:C}}return l.wrap=function(p){return arguments.length?(u=p,l):u},l.useViewBox=function(){return n=!0,l},l.width=function(p){return arguments.length?(s=p,l):s},l.height=function(p){return arguments.length?(e=p,l):e},l.padding=function(p){return arguments.length?(i=p,l):i},l.distinct=function(p){return arguments.length?(b=p,l):b},l.colours=function(p){return arguments.length?(g=p,l):g},l.colors=function(p){return arguments.length?(g=p,l):g},l.fontSize=function(p){return arguments.length?(y=p,l):y},l.round=function(p){return arguments.length?(x=p,l):x},l.duration=function(p){return arguments.length?(o=p,l):o},l.layoutFunction=function(p){return arguments.length?(m=p,l):m},l.normalize=function(p){return arguments.length?(c=p,l):c},l.scaleToFit=function(p){return arguments.length?(h=p,l):h},l.styled=function(p){return arguments.length?(r=p,l):r},l.orientation=function(p){return arguments.length?(a=p,l):a},l.orientationOrder=function(p){return arguments.length?(d=p,l):d},l.lossFunction=function(p){return arguments.length?(v=p==="default"?tt:p==="logRatio"?Dt:p,l):v},l}function rt(t,n){return function(s){const e=this,i=t[s.sets[0]].radius||50,o=n(s)||"",a=o.split(/\s+/).reverse(),h=(o.length+a.length)/3;let u=a.pop(),r=[u],y=0;const d=1.1;e.textContent=null;const b=[];function x(g){const m=e.ownerDocument.createElementNS(e.namespaceURI,"tspan");return m.textContent=g,b.push(m),e.append(m),m}let M=x(u);for(;u=a.pop(),!!u;){r.push(u);const g=r.join(" ");M.textContent=g,g.length>h&&M.getComputedTextLength()>i&&(r.pop(),M.textContent=r.join(" "),r=[u],M=x(u),y++)}const A=.35-y*d/2,T=e.getAttribute("x"),S=e.getAttribute("y");b.forEach((g,m)=>{g.setAttribute("x",T),g.setAttribute("y",S),g.setAttribute("dy",`${A+m*d}em`)})}}function at(t,n,s){let e=n[0].radius-q(n[0],t);for(let i=1;i<n.length;++i){const o=n[i].radius-q(n[i],t);o<=e&&(e=o)}for(let i=0;i<s.length;++i){const o=q(s[i],t)-s[i].radius;o<=e&&(e=o)}return e}function Lt(t,n,s){const e=[];for(const r of t)e.push({x:r.x,y:r.y}),e.push({x:r.x+r.radius/2,y:r.y}),e.push({x:r.x-r.radius/2,y:r.y}),e.push({x:r.x,y:r.y+r.radius/2}),e.push({x:r.x,y:r.y-r.radius/2});let i=e[0],o=at(e[0],t,n);for(let r=1;r<e.length;++r){const y=at(e[r],t,n);y>=o&&(i=e[r],o=y)}const a=zt(r=>-1*at({x:r[0],y:r[1]},t,n),[i.x,i.y],{maxIterations:500,minErrorDelta:1e-10}).x,c={x:s?0:a[0],y:a[1]};let h=!0;for(const r of t)if(q(c,r)>r.radius){h=!1;break}for(const r of n)if(q(c,r)<r.radius){h=!1;break}if(h)return c;if(t.length==1)return{x:t[0].x,y:t[0].y};const u={};return st(t,u),u.arcs.length===0?{x:0,y:-1e3,disjoint:!0}:u.arcs.length==1?{x:u.arcs[0].circle.x,y:u.arcs[0].circle.y}:n.length?Lt(t,[]):Et(u.arcs.map(r=>r.p1))}function ve(t){const n={},s=Object.keys(t);for(const e of s)n[e]=[];for(let e=0;e<s.length;e++){const i=s[e],o=t[i];for(let a=e+1;a<s.length;++a){const c=s[a],h=t[c],u=q(o,h);u+h.radius<=o.radius+1e-10?n[c].push(i):u+o.radius<=h.radius+1e-10&&n[i].push(c)}}return n}function jt(t,n,s){const e={},i=ve(t);for(let o=0;o<n.length;++o){const a=n[o].sets,c={},h={};for(let d=0;d<a.length;++d){c[a[d]]=!0;const b=i[a[d]];for(let x=0;x<b.length;++x)h[b[x]]=!0}const u=[],r=[];for(let d in t)d in c?u.push(t[d]):d in h||r.push(t[d]);const y=Lt(u,r,s);e[a]=y,y.disjoint&&n[o].size>0&&console.log("WARNING: area "+a+" not represented on screen")}return e}function Ie(t,n,s){const e=[];return e.push(`
1
+ import{aU as Gt,s as Wt,g as Kt,q as Ht,p as Yt,a as Xt,b as Zt,_ as w,D as wt,I as Jt,d as ot,al as Qt,ac as $t,ad as te,ae as ee,e as ne,z as se,F as ie,G as oe}from"./index-DfRNL5pP.js";import"./index-BziFEuBL.js";const kt=(t,n)=>Gt(t,"a",-n),_t=1e-10;function st(t,n){const s=ae(t),e=s.filter(c=>re(c,t));let i=0,o=0;const a=[];if(e.length>1){const c=Et(e);for(let u=0;u<e.length;++u){const r=e[u];r.angle=Math.atan2(r.x-c.x,r.y-c.y)}e.sort((u,r)=>r.angle-u.angle);let h=e[e.length-1];for(let u=0;u<e.length;++u){const r=e[u];o+=(h.x+r.x)*(r.y-h.y);const y={x:(r.x+h.x)/2,y:(r.y+h.y)/2};let d=null;for(let b=0;b<r.parentIndex.length;++b)if(h.parentIndex.includes(r.parentIndex[b])){const x=t[r.parentIndex[b]],M=Math.atan2(r.x-x.x,r.y-x.y),A=Math.atan2(h.x-x.x,h.y-x.y);let T=A-M;T<0&&(T+=2*Math.PI);const S=A-T/2;let g=q(y,{x:x.x+x.radius*Math.sin(S),y:x.y+x.radius*Math.cos(S)});g>x.radius*2&&(g=x.radius*2),(d==null||d.width>g)&&(d={circle:x,width:g,p1:r,p2:h,large:g>x.radius,sweep:!0})}d!=null&&(a.push(d),i+=lt(d.circle.radius,d.width),h=r)}}else{let c=t[0];for(let u=1;u<t.length;++u)t[u].radius<c.radius&&(c=t[u]);let h=!1;for(let u=0;u<t.length;++u)if(q(t[u],c)>Math.abs(c.radius-t[u].radius)){h=!0;break}h?i=o=0:(i=c.radius*c.radius*Math.PI,a.push({circle:c,p1:{x:c.x,y:c.y+c.radius},p2:{x:c.x-_t,y:c.y+c.radius},width:c.radius*2,large:!0,sweep:!0}))}return o/=2,n&&(n.area=i+o,n.arcArea=i,n.polygonArea=o,n.arcs=a,n.innerPoints=e,n.intersectionPoints=s),i+o}function re(t,n){return n.every(s=>q(t,s)<s.radius+_t)}function ae(t){const n=[];for(let s=0;s<t.length;++s)for(let e=s+1;e<t.length;++e){const i=Tt(t[s],t[e]);for(const o of i)o.parentIndex=[s,e],n.push(o)}return n}function lt(t,n){return t*t*Math.acos(1-n/t)-(t-n)*Math.sqrt(n*(2*t-n))}function q(t,n){return Math.sqrt((t.x-n.x)*(t.x-n.x)+(t.y-n.y)*(t.y-n.y))}function xt(t,n,s){if(s>=t+n)return 0;if(s<=Math.abs(t-n))return Math.PI*Math.min(t,n)*Math.min(t,n);const e=t-(s*s-n*n+t*t)/(2*s),i=n-(s*s-t*t+n*n)/(2*s);return lt(t,e)+lt(n,i)}function Tt(t,n){const s=q(t,n),e=t.radius,i=n.radius;if(s>=e+i||s<=Math.abs(e-i))return[];const o=(e*e-i*i+s*s)/(2*s),a=Math.sqrt(e*e-o*o),c=t.x+o*(n.x-t.x)/s,h=t.y+o*(n.y-t.y)/s,u=-(n.y-t.y)*(a/s),r=-(n.x-t.x)*(a/s);return[{x:c+u,y:h-r},{x:c-u,y:h+r}]}function Et(t){const n={x:0,y:0};for(const s of t)n.x+=s.x,n.y+=s.y;return n.x/=t.length,n.y/=t.length,n}function le(t,n,s,e){e=e||{};const i=e.maxIterations||100,o=e.tolerance||1e-10,a=t(n),c=t(s);let h=s-n;if(a*c>0)throw"Initial bisect points must have opposite signs";if(a===0)return n;if(c===0)return s;for(let u=0;u<i;++u){h/=2;const r=n+h,y=t(r);if(y*a>=0&&(n=r),Math.abs(h)<o||y===0)return r}return n+h}function ct(t){const n=new Array(t);for(let s=0;s<t;++s)n[s]=0;return n}function Mt(t,n){return ct(t).map(()=>ct(n))}function $(t,n){let s=0;for(let e=0;e<t.length;++e)s+=t[e]*n[e];return s}function ut(t){return Math.sqrt($(t,t))}function ft(t,n,s){for(let e=0;e<n.length;++e)t[e]=n[e]*s}function J(t,n,s,e,i){for(let o=0;o<t.length;++o)t[o]=n*s[o]+e*i[o]}function zt(t,n,s){s=s||{};const e=s.maxIterations||n.length*200,i=s.nonZeroDelta||1.05,o=s.zeroDelta||.001,a=s.minErrorDelta||1e-6,c=s.minErrorDelta||1e-5,h=s.rho!==void 0?s.rho:1,u=s.chi!==void 0?s.chi:2,r=s.psi!==void 0?s.psi:-.5,y=s.sigma!==void 0?s.sigma:.5;let d;const b=n.length,x=new Array(b+1);x[0]=n,x[0].fx=t(n),x[0].id=0;for(let v=0;v<b;++v){const l=n.slice();l[v]=l[v]?l[v]*i:o,x[v+1]=l,x[v+1].fx=t(l),x[v+1].id=v+1}function M(v){for(let l=0;l<v.length;l++)x[b][l]=v[l];x[b].fx=v.fx}const A=(v,l)=>v.fx-l.fx,T=n.slice(),S=n.slice(),g=n.slice(),m=n.slice();for(let v=0;v<e;++v){if(x.sort(A),s.history){const p=x.map(f=>{const N=f.slice();return N.fx=f.fx,N.id=f.id,N});p.sort((f,N)=>f.id-N.id),s.history.push({x:x[0].slice(),fx:x[0].fx,simplex:p})}d=0;for(let p=0;p<b;++p)d=Math.max(d,Math.abs(x[0][p]-x[1][p]));if(Math.abs(x[0].fx-x[b].fx)<a&&d<c)break;for(let p=0;p<b;++p){T[p]=0;for(let f=0;f<b;++f)T[p]+=x[f][p];T[p]/=b}const l=x[b];if(J(S,1+h,T,-h,l),S.fx=t(S),S.fx<x[0].fx)J(m,1+u,T,-u,l),m.fx=t(m),m.fx<S.fx?M(m):M(S);else if(S.fx>=x[b-1].fx){let p=!1;if(S.fx>l.fx?(J(g,1+r,T,-r,l),g.fx=t(g),g.fx<l.fx?M(g):p=!0):(J(g,1-r*h,T,r*h,l),g.fx=t(g),g.fx<S.fx?M(g):p=!0),p){if(y>=1)break;for(let f=1;f<x.length;++f)J(x[f],1-y,x[0],y,x[f]),x[f].fx=t(x[f])}}else M(S)}return x.sort(A),{fx:x[0].fx,x:x[0]}}function ce(t,n,s,e,i,o,a){const c=s.fx,h=$(s.fxprime,n);let u=c,r=c,y=h,d=0;i=i||1,o=o||1e-6,a=a||.1;function b(x,M,A){for(let T=0;T<16;++T)if(i=(x+M)/2,J(e.x,1,s.x,i,n),u=e.fx=t(e.x,e.fxprime),y=$(e.fxprime,n),u>c+o*i*h||u>=A)M=i;else{if(Math.abs(y)<=-a*h)return i;y*(M-x)>=0&&(M=x),x=i,A=u}return 0}for(let x=0;x<10;++x){if(J(e.x,1,s.x,i,n),u=e.fx=t(e.x,e.fxprime),y=$(e.fxprime,n),u>c+o*i*h||x&&u>=r)return b(d,i,r);if(Math.abs(y)<=-a*h)return i;if(y>=0)return b(i,d,u);r=u,d=i,i*=2}return i}function ue(t,n,s){let e={x:n.slice(),fx:0,fxprime:n.slice()},i={x:n.slice(),fx:0,fxprime:n.slice()};const o=n.slice();let a,c,h=1,u;s=s||{},u=s.maxIterations||n.length*20,e.fx=t(e.x,e.fxprime),a=e.fxprime.slice(),ft(a,e.fxprime,-1);for(let r=0;r<u;++r){if(h=ce(t,a,e,i,h),s.history&&s.history.push({x:e.x.slice(),fx:e.fx,fxprime:e.fxprime.slice(),alpha:h}),!h)ft(a,e.fxprime,-1);else{J(o,1,i.fxprime,-1,e.fxprime);const y=$(e.fxprime,e.fxprime),d=Math.max(0,$(o,i.fxprime)/y);J(a,d,a,-1,i.fxprime),c=e,e=i,i=c}if(ut(e.fxprime)<=1e-5)break}return s.history&&s.history.push({x:e.x.slice(),fx:e.fx,fxprime:e.fxprime.slice(),alpha:h}),e}function At(t,n={}){n.maxIterations=n.maxIterations||500;const s=n.initialLayout||ge,e=n.lossFunction||tt,i=fe(t,n),o=s(i,n),a=Object.keys(o),c=[];for(const r of a)c.push(o[r].x),c.push(o[r].y);const u=zt(r=>{const y={};for(let d=0;d<a.length;++d){const b=a[d];y[b]={x:r[2*d],y:r[2*d+1],radius:o[b].radius}}return e(y,i)},c,n).x;for(let r=0;r<a.length;++r){const y=a[r];o[y].x=u[2*r],o[y].y=u[2*r+1]}return o}const Rt=1e-10;function ht(t,n,s){return Math.min(t,n)*Math.min(t,n)*Math.PI<=s+Rt?Math.abs(t-n):le(e=>xt(t,n,e)-s,0,t+n)}function fe(t,n={}){const s=n.distinct,e=t.map(c=>Object.assign({},c));function i(c){return c.join(";")}if(s){const c=new Map;for(const h of e)for(let u=0;u<h.sets.length;u++){const r=String(h.sets[u]);c.set(r,h.size+(c.get(r)||0));for(let y=u+1;y<h.sets.length;y++){const d=String(h.sets[y]),b=`${r};${d}`,x=`${d};${r}`;c.set(b,h.size+(c.get(b)||0)),c.set(x,h.size+(c.get(x)||0))}}for(const h of e)h.sets.length<3&&(h.size=c.get(i(h.sets)))}const o=[],a=new Set;for(const c of e)if(c.sets.length===1)o.push(c.sets[0]);else if(c.sets.length===2){const h=c.sets[0],u=c.sets[1];a.add(i(c.sets)),a.add(i([u,h]))}o.sort((c,h)=>c===h?0:c<h?-1:1);for(let c=0;c<o.length;++c){const h=o[c];for(let u=c+1;u<o.length;++u){const r=o[u];a.has(i([h,r]))||e.push({sets:[h,r],size:0})}}return e}function he(t,n,s){const e=Mt(n.length,n.length),i=Mt(n.length,n.length);return t.filter(o=>o.sets.length===2).forEach(o=>{const a=s[o.sets[0]],c=s[o.sets[1]],h=Math.sqrt(n[a].size/Math.PI),u=Math.sqrt(n[c].size/Math.PI),r=ht(h,u,o.size);e[a][c]=e[c][a]=r;let y=0;o.size+1e-10>=Math.min(n[a].size,n[c].size)?y=1:o.size<=1e-10&&(y=-1),i[a][c]=i[c][a]=y}),{distances:e,constraints:i}}function de(t,n,s,e){for(let o=0;o<n.length;++o)n[o]=0;let i=0;for(let o=0;o<s.length;++o){const a=t[2*o],c=t[2*o+1];for(let h=o+1;h<s.length;++h){const u=t[2*h],r=t[2*h+1],y=s[o][h],d=e[o][h],b=(u-a)*(u-a)+(r-c)*(r-c),x=Math.sqrt(b),M=b-y*y;d>0&&x<=y||d<0&&x>=y||(i+=2*M*M,n[2*o]+=4*M*(a-u),n[2*o+1]+=4*M*(c-r),n[2*h]+=4*M*(u-a),n[2*h+1]+=4*M*(r-c))}}return i}function ge(t,n={}){let s=ye(t,n);const e=n.lossFunction||tt;if(t.length>=8){const i=xe(t,n),o=e(i,t),a=e(s,t);o+1e-8<a&&(s=i)}return s}function xe(t,n={}){const s=n.restarts||10,e=[],i={};for(const d of t)d.sets.length===1&&(i[d.sets[0]]=e.length,e.push(d));let{distances:o,constraints:a}=he(t,e,i);const c=ut(o.map(ut))/o.length;o=o.map(d=>d.map(b=>b/c));const h=(d,b)=>de(d,b,o,a);let u=null;for(let d=0;d<s;++d){const b=ct(o.length*2).map(Math.random),x=ue(h,b,n);(!u||x.fx<u.fx)&&(u=x)}const r=u.x,y={};for(let d=0;d<e.length;++d){const b=e[d];y[b.sets[0]]={x:r[2*d]*c,y:r[2*d+1]*c,radius:Math.sqrt(b.size/Math.PI)}}if(n.history)for(const d of n.history)ft(d.x,c);return y}function ye(t,n){const s=n&&n.lossFunction?n.lossFunction:tt,e={},i={};for(const y of t)if(y.sets.length===1){const d=y.sets[0];e[d]={x:1e10,y:1e10,rowid:e.length,size:y.size,radius:Math.sqrt(y.size/Math.PI)},i[d]=[]}t=t.filter(y=>y.sets.length===2);for(const y of t){let d=y.weight!=null?y.weight:1;const b=y.sets[0],x=y.sets[1];y.size+Rt>=Math.min(e[b].size,e[x].size)&&(d=0),i[b].push({set:x,size:y.size,weight:d}),i[x].push({set:b,size:y.size,weight:d})}const o=[];Object.keys(i).forEach(y=>{let d=0;for(let b=0;b<i[y].length;++b)d+=i[y][b].size*i[y][b].weight;o.push({set:y,size:d})});function a(y,d){return d.size-y.size}o.sort(a);const c={};function h(y){return y.set in c}function u(y,d){e[d].x=y.x,e[d].y=y.y,c[d]=!0}u({x:0,y:0},o[0].set);for(let y=1;y<o.length;++y){const d=o[y].set,b=i[d].filter(h),x=e[d];if(b.sort(a),b.length===0)throw"ERROR: missing pairwise overlap information";const M=[];for(var r=0;r<b.length;++r){const S=e[b[r].set],g=ht(x.radius,S.radius,b[r].size);M.push({x:S.x+g,y:S.y}),M.push({x:S.x-g,y:S.y}),M.push({y:S.y+g,x:S.x}),M.push({y:S.y-g,x:S.x});for(let m=r+1;m<b.length;++m){const v=e[b[m].set],l=ht(x.radius,v.radius,b[m].size),p=Tt({x:S.x,y:S.y,radius:g},{x:v.x,y:v.y,radius:l});M.push(...p)}}let A=1e50,T=M[0];for(const S of M){e[d].x=S.x,e[d].y=S.y;const g=s(e,t);g<A&&(A=g,T=S)}u(T,d)}return e}function tt(t,n){let s=0;for(const e of n){if(e.sets.length===1)continue;let i;if(e.sets.length===2){const a=t[e.sets[0]],c=t[e.sets[1]];i=xt(a.radius,c.radius,q(a,c))}else i=st(e.sets.map(a=>t[a]));const o=e.weight!=null?e.weight:1;s+=o*(i-e.size)*(i-e.size)}return s}function Dt(t,n){let s=0;for(const e of n){if(e.sets.length===1)continue;let i;if(e.sets.length===2){const c=t[e.sets[0]],h=t[e.sets[1]];i=xt(c.radius,h.radius,q(c,h))}else i=st(e.sets.map(c=>t[c]));const o=e.weight!=null?e.weight:1,a=Math.log((i+1)/(e.size+1));s+=o*a*a}return s}function pe(t,n,s){if(s==null?t.sort((i,o)=>o.radius-i.radius):t.sort(s),t.length>0){const i=t[0].x,o=t[0].y;for(const a of t)a.x-=i,a.y-=o}if(t.length===2&&q(t[0],t[1])<Math.abs(t[1].radius-t[0].radius)&&(t[1].x=t[0].x+t[0].radius-t[1].radius-1e-10,t[1].y=t[0].y),t.length>1){const i=Math.atan2(t[1].x,t[1].y)-n,o=Math.cos(i),a=Math.sin(i);for(const c of t){const h=c.x,u=c.y;c.x=o*h-a*u,c.y=a*h+o*u}}if(t.length>2){let i=Math.atan2(t[2].x,t[2].y)-n;for(;i<0;)i+=2*Math.PI;for(;i>2*Math.PI;)i-=2*Math.PI;if(i>Math.PI){const o=t[1].y/(1e-10+t[1].x);for(const a of t){var e=(a.x+o*a.y)/(1+o*o);a.x=2*e-a.x,a.y=2*e*o-a.y}}}}function me(t){t.forEach(i=>{i.parent=i});function n(i){return i.parent!==i&&(i.parent=n(i.parent)),i.parent}function s(i,o){const a=n(i),c=n(o);a.parent=c}for(let i=0;i<t.length;++i)for(let o=i+1;o<t.length;++o){const a=t[i].radius+t[o].radius;q(t[i],t[o])+1e-10<a&&s(t[o],t[i])}const e=new Map;for(let i=0;i<t.length;++i){const o=n(t[i]).parent.setid;e.has(o)||e.set(o,[]),e.get(o).push(t[i])}return t.forEach(i=>{delete i.parent}),Array.from(e.values())}function dt(t){const n=s=>{const e=t.reduce((o,a)=>Math.max(o,a[s]+a.radius),Number.NEGATIVE_INFINITY),i=t.reduce((o,a)=>Math.min(o,a[s]-a.radius),Number.POSITIVE_INFINITY);return{max:e,min:i}};return{xRange:n("x"),yRange:n("y")}}function Ct(t,n,s){n==null&&(n=Math.PI/2);let e=Ft(t).map(u=>Object.assign({},u));const i=me(e);for(const u of i){pe(u,n,s);const r=dt(u);u.size=(r.xRange.max-r.xRange.min)*(r.yRange.max-r.yRange.min),u.bounds=r}i.sort((u,r)=>r.size-u.size),e=i[0];let o=e.bounds;const a=(o.xRange.max-o.xRange.min)/50;function c(u,r,y){if(!u)return;const d=u.bounds;let b,x;if(r)b=o.xRange.max-d.xRange.min+a;else{b=o.xRange.max-d.xRange.max;const M=(d.xRange.max-d.xRange.min)/2-(o.xRange.max-o.xRange.min)/2;M<0&&(b+=M)}if(y)x=o.yRange.max-d.yRange.min+a;else{x=o.yRange.max-d.yRange.max;const M=(d.yRange.max-d.yRange.min)/2-(o.yRange.max-o.yRange.min)/2;M<0&&(x+=M)}for(const M of u)M.x+=b,M.y+=x,e.push(M)}let h=1;for(;h<i.length;)c(i[h],!0,!1),c(i[h+1],!1,!0),c(i[h+2],!0,!0),h+=3,o=dt(e);return Ot(e)}function Nt(t,n,s,e,i){const o=Ft(t);n-=2*e,s-=2*e;const{xRange:a,yRange:c}=dt(o);if(a.max===a.min||c.max===c.min)return console.log("not scaling solution: zero size detected"),t;let h,u;if(i){const b=Math.sqrt(i/Math.PI)*2;h=n/b,u=s/b}else h=n/(a.max-a.min),u=s/(c.max-c.min);const r=Math.min(u,h),y=(n-(a.max-a.min)*r)/2,d=(s-(c.max-c.min)*r)/2;return Ot(o.map(b=>({radius:r*b.radius,x:e+y+(b.x-a.min)*r,y:e+d+(b.y-c.min)*r,setid:b.setid})))}function Ot(t){const n={};for(const s of t)n[s.setid]=s;return n}function Ft(t){return Object.keys(t).map(s=>Object.assign(t[s],{setid:s}))}function be(t={}){let n=!1,s=600,e=350,i=15,o=1e3,a=Math.PI/2,c=!0,h=null,u=!0,r=!0,y=null,d=null,b=!1,x=null,M=t&&t.symmetricalTextCentre?t.symmetricalTextCentre:!1,A={},T=t&&t.colourScheme?t.colourScheme:t&&t.colorScheme?t.colorScheme:["#1f77b4","#ff7f0e","#2ca02c","#d62728","#9467bd","#8c564b","#e377c2","#7f7f7f","#bcbd22","#17becf"],S=0,g=function(p){if(p in A)return A[p];var f=A[p]=T[S];return S+=1,S>=T.length&&(S=0),f},m=At,v=tt;function l(p){let f=p.datum();const N=new Set;f.forEach(k=>{k.size==0&&k.sets.length==1&&N.add(k.sets[0])}),f=f.filter(k=>!k.sets.some(F=>N.has(F)));let I={},D={};if(f.length>0){let k=m(f,{lossFunction:v,distinct:b});c&&(k=Ct(k,a,d)),I=Nt(k,s,e,i,h),D=jt(I,f,M)}const U={};f.forEach(k=>{k.label&&(U[k.sets]=k.label)});function j(k){if(k.sets in U)return U[k.sets];if(k.sets.length==1)return""+k.sets[0]}p.selectAll("svg").data([I]).enter().append("svg");const E=p.select("svg");n?E.attr("viewBox",`0 0 ${s} ${e}`):E.attr("width",s).attr("height",e);const R={};let _=!1;E.selectAll(".venn-area path").each(function(k){const F=this.getAttribute("d");k.sets.length==1&&F&&!b&&(_=!0,R[k.sets[0]]=ke(F))});function P(k){return F=>{const H=k.sets.map(et=>{let Y=R[et],Z=I[et];return Y||(Y={x:s/2,y:e/2,radius:1}),Z||(Z={x:s/2,y:e/2,radius:1}),{x:Y.x*(1-F)+Z.x*F,y:Y.y*(1-F)+Z.y*F,radius:Y.radius*(1-F)+Z.radius*F}});return St(H,x)}}const V=E.selectAll(".venn-area").data(f,k=>k.sets),O=V.enter().append("g").attr("class",k=>`venn-area venn-${k.sets.length==1?"circle":"intersection"}${k.colour||k.color?" venn-coloured":""}`).attr("data-venn-sets",k=>k.sets.join("_")),B=O.append("path"),W=O.append("text").attr("class","label").text(k=>j(k)).attr("text-anchor","middle").attr("dy",".35em").attr("x",s/2).attr("y",e/2);r&&(B.style("fill-opacity","0").filter(k=>k.sets.length==1).style("fill",k=>k.colour?k.colour:k.color?k.color:g(k.sets)).style("fill-opacity",".25"),W.style("fill",k=>k.colour||k.color?"#FFF":t.textFill?t.textFill:k.sets.length==1?g(k.sets):"#444"));function K(k){return typeof k.transition=="function"?k.transition("venn").duration(o):k}let z=p;_&&typeof z.transition=="function"?(z=K(p),z.selectAll("path").attrTween("d",P)):z.selectAll("path").attr("d",k=>St(k.sets.map(F=>I[F])),x);const L=z.selectAll("text").filter(k=>k.sets in D).text(k=>j(k)).attr("x",k=>Math.floor(D[k.sets].x)).attr("y",k=>Math.floor(D[k.sets].y));u&&(_?"on"in L?L.on("end",rt(I,j)):L.each("end",rt(I,j)):L.each(rt(I,j)));const C=K(V.exit()).remove();typeof V.transition=="function"&&C.selectAll("path").attrTween("d",P);const X=C.selectAll("text").attr("x",s/2).attr("y",e/2);return y!==null&&(W.style("font-size","0px"),L.style("font-size",y),X.style("font-size","0px")),{circles:I,textCentres:D,nodes:V,enter:O,update:z,exit:C}}return l.wrap=function(p){return arguments.length?(u=p,l):u},l.useViewBox=function(){return n=!0,l},l.width=function(p){return arguments.length?(s=p,l):s},l.height=function(p){return arguments.length?(e=p,l):e},l.padding=function(p){return arguments.length?(i=p,l):i},l.distinct=function(p){return arguments.length?(b=p,l):b},l.colours=function(p){return arguments.length?(g=p,l):g},l.colors=function(p){return arguments.length?(g=p,l):g},l.fontSize=function(p){return arguments.length?(y=p,l):y},l.round=function(p){return arguments.length?(x=p,l):x},l.duration=function(p){return arguments.length?(o=p,l):o},l.layoutFunction=function(p){return arguments.length?(m=p,l):m},l.normalize=function(p){return arguments.length?(c=p,l):c},l.scaleToFit=function(p){return arguments.length?(h=p,l):h},l.styled=function(p){return arguments.length?(r=p,l):r},l.orientation=function(p){return arguments.length?(a=p,l):a},l.orientationOrder=function(p){return arguments.length?(d=p,l):d},l.lossFunction=function(p){return arguments.length?(v=p==="default"?tt:p==="logRatio"?Dt:p,l):v},l}function rt(t,n){return function(s){const e=this,i=t[s.sets[0]].radius||50,o=n(s)||"",a=o.split(/\s+/).reverse(),h=(o.length+a.length)/3;let u=a.pop(),r=[u],y=0;const d=1.1;e.textContent=null;const b=[];function x(g){const m=e.ownerDocument.createElementNS(e.namespaceURI,"tspan");return m.textContent=g,b.push(m),e.append(m),m}let M=x(u);for(;u=a.pop(),!!u;){r.push(u);const g=r.join(" ");M.textContent=g,g.length>h&&M.getComputedTextLength()>i&&(r.pop(),M.textContent=r.join(" "),r=[u],M=x(u),y++)}const A=.35-y*d/2,T=e.getAttribute("x"),S=e.getAttribute("y");b.forEach((g,m)=>{g.setAttribute("x",T),g.setAttribute("y",S),g.setAttribute("dy",`${A+m*d}em`)})}}function at(t,n,s){let e=n[0].radius-q(n[0],t);for(let i=1;i<n.length;++i){const o=n[i].radius-q(n[i],t);o<=e&&(e=o)}for(let i=0;i<s.length;++i){const o=q(s[i],t)-s[i].radius;o<=e&&(e=o)}return e}function Lt(t,n,s){const e=[];for(const r of t)e.push({x:r.x,y:r.y}),e.push({x:r.x+r.radius/2,y:r.y}),e.push({x:r.x-r.radius/2,y:r.y}),e.push({x:r.x,y:r.y+r.radius/2}),e.push({x:r.x,y:r.y-r.radius/2});let i=e[0],o=at(e[0],t,n);for(let r=1;r<e.length;++r){const y=at(e[r],t,n);y>=o&&(i=e[r],o=y)}const a=zt(r=>-1*at({x:r[0],y:r[1]},t,n),[i.x,i.y],{maxIterations:500,minErrorDelta:1e-10}).x,c={x:s?0:a[0],y:a[1]};let h=!0;for(const r of t)if(q(c,r)>r.radius){h=!1;break}for(const r of n)if(q(c,r)<r.radius){h=!1;break}if(h)return c;if(t.length==1)return{x:t[0].x,y:t[0].y};const u={};return st(t,u),u.arcs.length===0?{x:0,y:-1e3,disjoint:!0}:u.arcs.length==1?{x:u.arcs[0].circle.x,y:u.arcs[0].circle.y}:n.length?Lt(t,[]):Et(u.arcs.map(r=>r.p1))}function ve(t){const n={},s=Object.keys(t);for(const e of s)n[e]=[];for(let e=0;e<s.length;e++){const i=s[e],o=t[i];for(let a=e+1;a<s.length;++a){const c=s[a],h=t[c],u=q(o,h);u+h.radius<=o.radius+1e-10?n[c].push(i):u+o.radius<=h.radius+1e-10&&n[i].push(c)}}return n}function jt(t,n,s){const e={},i=ve(t);for(let o=0;o<n.length;++o){const a=n[o].sets,c={},h={};for(let d=0;d<a.length;++d){c[a[d]]=!0;const b=i[a[d]];for(let x=0;x<b.length;++x)h[b[x]]=!0}const u=[],r=[];for(let d in t)d in c?u.push(t[d]):d in h||r.push(t[d]);const y=Lt(u,r,s);e[a]=y,y.disjoint&&n[o].size>0&&console.log("WARNING: area "+a+" not represented on screen")}return e}function Ie(t,n,s){const e=[];return e.push(`
2
2
  M`,t,n),e.push(`
3
3
  m`,-s,0),e.push(`
4
4
  a`,s,s,0,1,0,s*2,0),e.push(`
@@ -1,4 +1,4 @@
1
- import{ay as er}from"./index-BVh0eL1_.js";var LN=Object.create,pc=Object.defineProperty,DN=Object.getOwnPropertyDescriptor,xh=Object.getOwnPropertyNames,MN=Object.getPrototypeOf,xN=Object.prototype.hasOwnProperty,s=(t,e)=>pc(t,"name",{value:e,configurable:!0}),FN=(t,e)=>function(){return t&&(e=(0,t[xh(t)[0]])(t=0)),e},Y=(t,e)=>function(){return e||(0,t[xh(t)[0]])((e={exports:{}}).exports,e),e.exports},Zr=(t,e)=>{for(var r in e)pc(t,r,{get:e[r],enumerable:!0})},Fh=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of xh(e))!xN.call(t,a)&&a!==r&&pc(t,a,{get:()=>e[a],enumerable:!(n=DN(e,a))||n.enumerable});return t},uf=(t,e,r)=>(Fh(t,e,"default"),r),Gh=(t,e,r)=>(r=t!=null?LN(MN(t)):{},Fh(pc(r,"default",{value:t,enumerable:!0}),t)),jh=t=>Fh(pc({},"__esModule",{value:!0}),t),ff={};Zr(ff,{AnnotatedTextEdit:()=>Tr,ChangeAnnotation:()=>un,ChangeAnnotationIdentifier:()=>Xe,CodeAction:()=>Ap,CodeActionContext:()=>$p,CodeActionKind:()=>Rp,CodeActionTriggerKind:()=>Il,CodeDescription:()=>Zd,CodeLens:()=>Ep,Color:()=>tu,ColorInformation:()=>Wd,ColorPresentation:()=>Vd,Command:()=>cn,CompletionItem:()=>lp,CompletionItemKind:()=>rp,CompletionItemLabelDetails:()=>op,CompletionItemTag:()=>ap,CompletionList:()=>cp,CreateFile:()=>Ta,DeleteFile:()=>$a,Diagnostic:()=>Cl,DiagnosticRelatedInformation:()=>ru,DiagnosticSeverity:()=>Xd,DiagnosticTag:()=>Jd,DocumentHighlight:()=>hp,DocumentHighlightKind:()=>pp,DocumentLink:()=>Cp,DocumentSymbol:()=>Tp,DocumentUri:()=>Bd,EOL:()=>hT,FoldingRange:()=>Yd,FoldingRangeKind:()=>Hd,FormattingOptions:()=>_p,Hover:()=>up,InlayHint:()=>Lp,InlayHintKind:()=>iu,InlayHintLabelPart:()=>su,InlineCompletionContext:()=>jp,InlineCompletionItem:()=>Mp,InlineCompletionList:()=>xp,InlineCompletionTriggerKind:()=>Fp,InlineValueContext:()=>Op,InlineValueEvaluatableExpression:()=>Pp,InlineValueText:()=>Np,InlineValueVariableLookup:()=>kp,InsertReplaceEdit:()=>ip,InsertTextFormat:()=>np,InsertTextMode:()=>sp,Location:()=>_l,LocationLink:()=>qd,MarkedString:()=>wl,MarkupContent:()=>Aa,MarkupKind:()=>au,OptionalVersionedTextDocumentIdentifier:()=>bl,ParameterInformation:()=>fp,Position:()=>ie,Range:()=>ee,RenameFile:()=>Ra,SelectedCompletionInfo:()=>Gp,SelectionRange:()=>Sp,SemanticTokenModifiers:()=>wp,SemanticTokenTypes:()=>bp,SemanticTokens:()=>Ip,SignatureInformation:()=>dp,StringValue:()=>Dp,SymbolInformation:()=>yp,SymbolKind:()=>mp,SymbolTag:()=>gp,TextDocument:()=>zp,TextDocumentEdit:()=>Sl,TextDocumentIdentifier:()=>Qd,TextDocumentItem:()=>tp,TextEdit:()=>rr,URI:()=>eu,VersionedTextDocumentIdentifier:()=>ep,WorkspaceChange:()=>pT,WorkspaceEdit:()=>nu,WorkspaceFolder:()=>Up,WorkspaceSymbol:()=>vp,integer:()=>Kd,uinteger:()=>El});var Bd,eu,Kd,El,ie,ee,_l,qd,tu,Wd,Vd,Hd,Yd,ru,Xd,Jd,Zd,Cl,cn,rr,un,Xe,Tr,Sl,Ta,Ra,$a,nu,pl,Rd,pT,Qd,ep,bl,tp,au,Aa,rp,np,ap,ip,sp,op,lp,cp,wl,up,fp,dp,pp,hp,mp,gp,yp,vp,Tp,Rp,Il,$p,Ap,Ep,_p,Cp,Sp,bp,wp,Ip,Np,kp,Pp,Op,iu,su,Lp,Dp,Mp,xp,Fp,Gp,jp,Up,hT,zp,Ey,E,hc=FN({"../../node_modules/.pnpm/vscode-languageserver-types@3.17.5/node_modules/vscode-languageserver-types/lib/esm/main.js"(){var t,e,r,n;(function(a){function i(o){return typeof o=="string"}s(i,"is"),a.is=i})(Bd||(Bd={})),(function(a){function i(o){return typeof o=="string"}s(i,"is"),a.is=i})(eu||(eu={})),(function(a){a.MIN_VALUE=-2147483648,a.MAX_VALUE=2147483647;function i(o){return typeof o=="number"&&a.MIN_VALUE<=o&&o<=a.MAX_VALUE}s(i,"is"),a.is=i})(Kd||(Kd={})),(function(a){a.MIN_VALUE=0,a.MAX_VALUE=2147483647;function i(o){return typeof o=="number"&&a.MIN_VALUE<=o&&o<=a.MAX_VALUE}s(i,"is"),a.is=i})(El||(El={})),(function(a){function i(c,l){return c===Number.MAX_VALUE&&(c=El.MAX_VALUE),l===Number.MAX_VALUE&&(l=El.MAX_VALUE),{line:c,character:l}}s(i,"create"),a.create=i;function o(c){let l=c;return E.objectLiteral(l)&&E.uinteger(l.line)&&E.uinteger(l.character)}s(o,"is"),a.is=o})(ie||(ie={})),(function(a){function i(c,l,u,f){if(E.uinteger(c)&&E.uinteger(l)&&E.uinteger(u)&&E.uinteger(f))return{start:ie.create(c,l),end:ie.create(u,f)};if(ie.is(c)&&ie.is(l))return{start:c,end:l};throw new Error(`Range#create called with invalid arguments[${c}, ${l}, ${u}, ${f}]`)}s(i,"create"),a.create=i;function o(c){let l=c;return E.objectLiteral(l)&&ie.is(l.start)&&ie.is(l.end)}s(o,"is"),a.is=o})(ee||(ee={})),(function(a){function i(c,l){return{uri:c,range:l}}s(i,"create"),a.create=i;function o(c){let l=c;return E.objectLiteral(l)&&ee.is(l.range)&&(E.string(l.uri)||E.undefined(l.uri))}s(o,"is"),a.is=o})(_l||(_l={})),(function(a){function i(c,l,u,f){return{targetUri:c,targetRange:l,targetSelectionRange:u,originSelectionRange:f}}s(i,"create"),a.create=i;function o(c){let l=c;return E.objectLiteral(l)&&ee.is(l.targetRange)&&E.string(l.targetUri)&&ee.is(l.targetSelectionRange)&&(ee.is(l.originSelectionRange)||E.undefined(l.originSelectionRange))}s(o,"is"),a.is=o})(qd||(qd={})),(function(a){function i(c,l,u,f){return{red:c,green:l,blue:u,alpha:f}}s(i,"create"),a.create=i;function o(c){const l=c;return E.objectLiteral(l)&&E.numberRange(l.red,0,1)&&E.numberRange(l.green,0,1)&&E.numberRange(l.blue,0,1)&&E.numberRange(l.alpha,0,1)}s(o,"is"),a.is=o})(tu||(tu={})),(function(a){function i(c,l){return{range:c,color:l}}s(i,"create"),a.create=i;function o(c){const l=c;return E.objectLiteral(l)&&ee.is(l.range)&&tu.is(l.color)}s(o,"is"),a.is=o})(Wd||(Wd={})),(function(a){function i(c,l,u){return{label:c,textEdit:l,additionalTextEdits:u}}s(i,"create"),a.create=i;function o(c){const l=c;return E.objectLiteral(l)&&E.string(l.label)&&(E.undefined(l.textEdit)||rr.is(l))&&(E.undefined(l.additionalTextEdits)||E.typedArray(l.additionalTextEdits,rr.is))}s(o,"is"),a.is=o})(Vd||(Vd={})),(function(a){a.Comment="comment",a.Imports="imports",a.Region="region"})(Hd||(Hd={})),(function(a){function i(c,l,u,f,d,p){const g={startLine:c,endLine:l};return E.defined(u)&&(g.startCharacter=u),E.defined(f)&&(g.endCharacter=f),E.defined(d)&&(g.kind=d),E.defined(p)&&(g.collapsedText=p),g}s(i,"create"),a.create=i;function o(c){const l=c;return E.objectLiteral(l)&&E.uinteger(l.startLine)&&E.uinteger(l.startLine)&&(E.undefined(l.startCharacter)||E.uinteger(l.startCharacter))&&(E.undefined(l.endCharacter)||E.uinteger(l.endCharacter))&&(E.undefined(l.kind)||E.string(l.kind))}s(o,"is"),a.is=o})(Yd||(Yd={})),(function(a){function i(c,l){return{location:c,message:l}}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&_l.is(l.location)&&E.string(l.message)}s(o,"is"),a.is=o})(ru||(ru={})),(function(a){a.Error=1,a.Warning=2,a.Information=3,a.Hint=4})(Xd||(Xd={})),(function(a){a.Unnecessary=1,a.Deprecated=2})(Jd||(Jd={})),(function(a){function i(o){const c=o;return E.objectLiteral(c)&&E.string(c.href)}s(i,"is"),a.is=i})(Zd||(Zd={})),(function(a){function i(c,l,u,f,d,p){let g={range:c,message:l};return E.defined(u)&&(g.severity=u),E.defined(f)&&(g.code=f),E.defined(d)&&(g.source=d),E.defined(p)&&(g.relatedInformation=p),g}s(i,"create"),a.create=i;function o(c){var l;let u=c;return E.defined(u)&&ee.is(u.range)&&E.string(u.message)&&(E.number(u.severity)||E.undefined(u.severity))&&(E.integer(u.code)||E.string(u.code)||E.undefined(u.code))&&(E.undefined(u.codeDescription)||E.string((l=u.codeDescription)===null||l===void 0?void 0:l.href))&&(E.string(u.source)||E.undefined(u.source))&&(E.undefined(u.relatedInformation)||E.typedArray(u.relatedInformation,ru.is))}s(o,"is"),a.is=o})(Cl||(Cl={})),(function(a){function i(c,l,...u){let f={title:c,command:l};return E.defined(u)&&u.length>0&&(f.arguments=u),f}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&E.string(l.title)&&E.string(l.command)}s(o,"is"),a.is=o})(cn||(cn={})),(function(a){function i(u,f){return{range:u,newText:f}}s(i,"replace"),a.replace=i;function o(u,f){return{range:{start:u,end:u},newText:f}}s(o,"insert"),a.insert=o;function c(u){return{range:u,newText:""}}s(c,"del"),a.del=c;function l(u){const f=u;return E.objectLiteral(f)&&E.string(f.newText)&&ee.is(f.range)}s(l,"is"),a.is=l})(rr||(rr={})),(function(a){function i(c,l,u){const f={label:c};return l!==void 0&&(f.needsConfirmation=l),u!==void 0&&(f.description=u),f}s(i,"create"),a.create=i;function o(c){const l=c;return E.objectLiteral(l)&&E.string(l.label)&&(E.boolean(l.needsConfirmation)||l.needsConfirmation===void 0)&&(E.string(l.description)||l.description===void 0)}s(o,"is"),a.is=o})(un||(un={})),(function(a){function i(o){const c=o;return E.string(c)}s(i,"is"),a.is=i})(Xe||(Xe={})),(function(a){function i(u,f,d){return{range:u,newText:f,annotationId:d}}s(i,"replace"),a.replace=i;function o(u,f,d){return{range:{start:u,end:u},newText:f,annotationId:d}}s(o,"insert"),a.insert=o;function c(u,f){return{range:u,newText:"",annotationId:f}}s(c,"del"),a.del=c;function l(u){const f=u;return rr.is(f)&&(un.is(f.annotationId)||Xe.is(f.annotationId))}s(l,"is"),a.is=l})(Tr||(Tr={})),(function(a){function i(c,l){return{textDocument:c,edits:l}}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&bl.is(l.textDocument)&&Array.isArray(l.edits)}s(o,"is"),a.is=o})(Sl||(Sl={})),(function(a){function i(c,l,u){let f={kind:"create",uri:c};return l!==void 0&&(l.overwrite!==void 0||l.ignoreIfExists!==void 0)&&(f.options=l),u!==void 0&&(f.annotationId=u),f}s(i,"create"),a.create=i;function o(c){let l=c;return l&&l.kind==="create"&&E.string(l.uri)&&(l.options===void 0||(l.options.overwrite===void 0||E.boolean(l.options.overwrite))&&(l.options.ignoreIfExists===void 0||E.boolean(l.options.ignoreIfExists)))&&(l.annotationId===void 0||Xe.is(l.annotationId))}s(o,"is"),a.is=o})(Ta||(Ta={})),(function(a){function i(c,l,u,f){let d={kind:"rename",oldUri:c,newUri:l};return u!==void 0&&(u.overwrite!==void 0||u.ignoreIfExists!==void 0)&&(d.options=u),f!==void 0&&(d.annotationId=f),d}s(i,"create"),a.create=i;function o(c){let l=c;return l&&l.kind==="rename"&&E.string(l.oldUri)&&E.string(l.newUri)&&(l.options===void 0||(l.options.overwrite===void 0||E.boolean(l.options.overwrite))&&(l.options.ignoreIfExists===void 0||E.boolean(l.options.ignoreIfExists)))&&(l.annotationId===void 0||Xe.is(l.annotationId))}s(o,"is"),a.is=o})(Ra||(Ra={})),(function(a){function i(c,l,u){let f={kind:"delete",uri:c};return l!==void 0&&(l.recursive!==void 0||l.ignoreIfNotExists!==void 0)&&(f.options=l),u!==void 0&&(f.annotationId=u),f}s(i,"create"),a.create=i;function o(c){let l=c;return l&&l.kind==="delete"&&E.string(l.uri)&&(l.options===void 0||(l.options.recursive===void 0||E.boolean(l.options.recursive))&&(l.options.ignoreIfNotExists===void 0||E.boolean(l.options.ignoreIfNotExists)))&&(l.annotationId===void 0||Xe.is(l.annotationId))}s(o,"is"),a.is=o})($a||($a={})),(function(a){function i(o){let c=o;return c&&(c.changes!==void 0||c.documentChanges!==void 0)&&(c.documentChanges===void 0||c.documentChanges.every(l=>E.string(l.kind)?Ta.is(l)||Ra.is(l)||$a.is(l):Sl.is(l)))}s(i,"is"),a.is=i})(nu||(nu={})),pl=(t=class{constructor(i,o){this.edits=i,this.changeAnnotations=o}insert(i,o,c){let l,u;if(c===void 0?l=rr.insert(i,o):Xe.is(c)?(u=c,l=Tr.insert(i,o,c)):(this.assertChangeAnnotations(this.changeAnnotations),u=this.changeAnnotations.manage(c),l=Tr.insert(i,o,u)),this.edits.push(l),u!==void 0)return u}replace(i,o,c){let l,u;if(c===void 0?l=rr.replace(i,o):Xe.is(c)?(u=c,l=Tr.replace(i,o,c)):(this.assertChangeAnnotations(this.changeAnnotations),u=this.changeAnnotations.manage(c),l=Tr.replace(i,o,u)),this.edits.push(l),u!==void 0)return u}delete(i,o){let c,l;if(o===void 0?c=rr.del(i):Xe.is(o)?(l=o,c=Tr.del(i,o)):(this.assertChangeAnnotations(this.changeAnnotations),l=this.changeAnnotations.manage(o),c=Tr.del(i,l)),this.edits.push(c),l!==void 0)return l}add(i){this.edits.push(i)}all(){return this.edits}clear(){this.edits.splice(0,this.edits.length)}assertChangeAnnotations(i){if(i===void 0)throw new Error("Text edit change is not configured to manage change annotations.")}},s(t,"TextEditChangeImpl"),t),Rd=(e=class{constructor(i){this._annotations=i===void 0?Object.create(null):i,this._counter=0,this._size=0}all(){return this._annotations}get size(){return this._size}manage(i,o){let c;if(Xe.is(i)?c=i:(c=this.nextId(),o=i),this._annotations[c]!==void 0)throw new Error(`Id ${c} is already in use.`);if(o===void 0)throw new Error(`No annotation provided for id ${c}`);return this._annotations[c]=o,this._size++,c}nextId(){return this._counter++,this._counter.toString()}},s(e,"ChangeAnnotations"),e),pT=(r=class{constructor(i){this._textEditChanges=Object.create(null),i!==void 0?(this._workspaceEdit=i,i.documentChanges?(this._changeAnnotations=new Rd(i.changeAnnotations),i.changeAnnotations=this._changeAnnotations.all(),i.documentChanges.forEach(o=>{if(Sl.is(o)){const c=new pl(o.edits,this._changeAnnotations);this._textEditChanges[o.textDocument.uri]=c}})):i.changes&&Object.keys(i.changes).forEach(o=>{const c=new pl(i.changes[o]);this._textEditChanges[o]=c})):this._workspaceEdit={}}get edit(){return this.initDocumentChanges(),this._changeAnnotations!==void 0&&(this._changeAnnotations.size===0?this._workspaceEdit.changeAnnotations=void 0:this._workspaceEdit.changeAnnotations=this._changeAnnotations.all()),this._workspaceEdit}getTextEditChange(i){if(bl.is(i)){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");const o={uri:i.uri,version:i.version};let c=this._textEditChanges[o.uri];if(!c){const l=[],u={textDocument:o,edits:l};this._workspaceEdit.documentChanges.push(u),c=new pl(l,this._changeAnnotations),this._textEditChanges[o.uri]=c}return c}else{if(this.initChanges(),this._workspaceEdit.changes===void 0)throw new Error("Workspace edit is not configured for normal text edit changes.");let o=this._textEditChanges[i];if(!o){let c=[];this._workspaceEdit.changes[i]=c,o=new pl(c),this._textEditChanges[i]=o}return o}}initDocumentChanges(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._changeAnnotations=new Rd,this._workspaceEdit.documentChanges=[],this._workspaceEdit.changeAnnotations=this._changeAnnotations.all())}initChanges(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._workspaceEdit.changes=Object.create(null))}createFile(i,o,c){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");let l;un.is(o)||Xe.is(o)?l=o:c=o;let u,f;if(l===void 0?u=Ta.create(i,c):(f=Xe.is(l)?l:this._changeAnnotations.manage(l),u=Ta.create(i,c,f)),this._workspaceEdit.documentChanges.push(u),f!==void 0)return f}renameFile(i,o,c,l){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");let u;un.is(c)||Xe.is(c)?u=c:l=c;let f,d;if(u===void 0?f=Ra.create(i,o,l):(d=Xe.is(u)?u:this._changeAnnotations.manage(u),f=Ra.create(i,o,l,d)),this._workspaceEdit.documentChanges.push(f),d!==void 0)return d}deleteFile(i,o,c){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");let l;un.is(o)||Xe.is(o)?l=o:c=o;let u,f;if(l===void 0?u=$a.create(i,c):(f=Xe.is(l)?l:this._changeAnnotations.manage(l),u=$a.create(i,c,f)),this._workspaceEdit.documentChanges.push(u),f!==void 0)return f}},s(r,"WorkspaceChange"),r),(function(a){function i(c){return{uri:c}}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&E.string(l.uri)}s(o,"is"),a.is=o})(Qd||(Qd={})),(function(a){function i(c,l){return{uri:c,version:l}}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&E.string(l.uri)&&E.integer(l.version)}s(o,"is"),a.is=o})(ep||(ep={})),(function(a){function i(c,l){return{uri:c,version:l}}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&E.string(l.uri)&&(l.version===null||E.integer(l.version))}s(o,"is"),a.is=o})(bl||(bl={})),(function(a){function i(c,l,u,f){return{uri:c,languageId:l,version:u,text:f}}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&E.string(l.uri)&&E.string(l.languageId)&&E.integer(l.version)&&E.string(l.text)}s(o,"is"),a.is=o})(tp||(tp={})),(function(a){a.PlainText="plaintext",a.Markdown="markdown";function i(o){const c=o;return c===a.PlainText||c===a.Markdown}s(i,"is"),a.is=i})(au||(au={})),(function(a){function i(o){const c=o;return E.objectLiteral(o)&&au.is(c.kind)&&E.string(c.value)}s(i,"is"),a.is=i})(Aa||(Aa={})),(function(a){a.Text=1,a.Method=2,a.Function=3,a.Constructor=4,a.Field=5,a.Variable=6,a.Class=7,a.Interface=8,a.Module=9,a.Property=10,a.Unit=11,a.Value=12,a.Enum=13,a.Keyword=14,a.Snippet=15,a.Color=16,a.File=17,a.Reference=18,a.Folder=19,a.EnumMember=20,a.Constant=21,a.Struct=22,a.Event=23,a.Operator=24,a.TypeParameter=25})(rp||(rp={})),(function(a){a.PlainText=1,a.Snippet=2})(np||(np={})),(function(a){a.Deprecated=1})(ap||(ap={})),(function(a){function i(c,l,u){return{newText:c,insert:l,replace:u}}s(i,"create"),a.create=i;function o(c){const l=c;return l&&E.string(l.newText)&&ee.is(l.insert)&&ee.is(l.replace)}s(o,"is"),a.is=o})(ip||(ip={})),(function(a){a.asIs=1,a.adjustIndentation=2})(sp||(sp={})),(function(a){function i(o){const c=o;return c&&(E.string(c.detail)||c.detail===void 0)&&(E.string(c.description)||c.description===void 0)}s(i,"is"),a.is=i})(op||(op={})),(function(a){function i(o){return{label:o}}s(i,"create"),a.create=i})(lp||(lp={})),(function(a){function i(o,c){return{items:o||[],isIncomplete:!!c}}s(i,"create"),a.create=i})(cp||(cp={})),(function(a){function i(c){return c.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")}s(i,"fromPlainText"),a.fromPlainText=i;function o(c){const l=c;return E.string(l)||E.objectLiteral(l)&&E.string(l.language)&&E.string(l.value)}s(o,"is"),a.is=o})(wl||(wl={})),(function(a){function i(o){let c=o;return!!c&&E.objectLiteral(c)&&(Aa.is(c.contents)||wl.is(c.contents)||E.typedArray(c.contents,wl.is))&&(o.range===void 0||ee.is(o.range))}s(i,"is"),a.is=i})(up||(up={})),(function(a){function i(o,c){return c?{label:o,documentation:c}:{label:o}}s(i,"create"),a.create=i})(fp||(fp={})),(function(a){function i(o,c,...l){let u={label:o};return E.defined(c)&&(u.documentation=c),E.defined(l)?u.parameters=l:u.parameters=[],u}s(i,"create"),a.create=i})(dp||(dp={})),(function(a){a.Text=1,a.Read=2,a.Write=3})(pp||(pp={})),(function(a){function i(o,c){let l={range:o};return E.number(c)&&(l.kind=c),l}s(i,"create"),a.create=i})(hp||(hp={})),(function(a){a.File=1,a.Module=2,a.Namespace=3,a.Package=4,a.Class=5,a.Method=6,a.Property=7,a.Field=8,a.Constructor=9,a.Enum=10,a.Interface=11,a.Function=12,a.Variable=13,a.Constant=14,a.String=15,a.Number=16,a.Boolean=17,a.Array=18,a.Object=19,a.Key=20,a.Null=21,a.EnumMember=22,a.Struct=23,a.Event=24,a.Operator=25,a.TypeParameter=26})(mp||(mp={})),(function(a){a.Deprecated=1})(gp||(gp={})),(function(a){function i(o,c,l,u,f){let d={name:o,kind:c,location:{uri:u,range:l}};return f&&(d.containerName=f),d}s(i,"create"),a.create=i})(yp||(yp={})),(function(a){function i(o,c,l,u){return u!==void 0?{name:o,kind:c,location:{uri:l,range:u}}:{name:o,kind:c,location:{uri:l}}}s(i,"create"),a.create=i})(vp||(vp={})),(function(a){function i(c,l,u,f,d,p){let g={name:c,detail:l,kind:u,range:f,selectionRange:d};return p!==void 0&&(g.children=p),g}s(i,"create"),a.create=i;function o(c){let l=c;return l&&E.string(l.name)&&E.number(l.kind)&&ee.is(l.range)&&ee.is(l.selectionRange)&&(l.detail===void 0||E.string(l.detail))&&(l.deprecated===void 0||E.boolean(l.deprecated))&&(l.children===void 0||Array.isArray(l.children))&&(l.tags===void 0||Array.isArray(l.tags))}s(o,"is"),a.is=o})(Tp||(Tp={})),(function(a){a.Empty="",a.QuickFix="quickfix",a.Refactor="refactor",a.RefactorExtract="refactor.extract",a.RefactorInline="refactor.inline",a.RefactorRewrite="refactor.rewrite",a.Source="source",a.SourceOrganizeImports="source.organizeImports",a.SourceFixAll="source.fixAll"})(Rp||(Rp={})),(function(a){a.Invoked=1,a.Automatic=2})(Il||(Il={})),(function(a){function i(c,l,u){let f={diagnostics:c};return l!=null&&(f.only=l),u!=null&&(f.triggerKind=u),f}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&E.typedArray(l.diagnostics,Cl.is)&&(l.only===void 0||E.typedArray(l.only,E.string))&&(l.triggerKind===void 0||l.triggerKind===Il.Invoked||l.triggerKind===Il.Automatic)}s(o,"is"),a.is=o})($p||($p={})),(function(a){function i(c,l,u){let f={title:c},d=!0;return typeof l=="string"?(d=!1,f.kind=l):cn.is(l)?f.command=l:f.edit=l,d&&u!==void 0&&(f.kind=u),f}s(i,"create"),a.create=i;function o(c){let l=c;return l&&E.string(l.title)&&(l.diagnostics===void 0||E.typedArray(l.diagnostics,Cl.is))&&(l.kind===void 0||E.string(l.kind))&&(l.edit!==void 0||l.command!==void 0)&&(l.command===void 0||cn.is(l.command))&&(l.isPreferred===void 0||E.boolean(l.isPreferred))&&(l.edit===void 0||nu.is(l.edit))}s(o,"is"),a.is=o})(Ap||(Ap={})),(function(a){function i(c,l){let u={range:c};return E.defined(l)&&(u.data=l),u}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&ee.is(l.range)&&(E.undefined(l.command)||cn.is(l.command))}s(o,"is"),a.is=o})(Ep||(Ep={})),(function(a){function i(c,l){return{tabSize:c,insertSpaces:l}}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&E.uinteger(l.tabSize)&&E.boolean(l.insertSpaces)}s(o,"is"),a.is=o})(_p||(_p={})),(function(a){function i(c,l,u){return{range:c,target:l,data:u}}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&ee.is(l.range)&&(E.undefined(l.target)||E.string(l.target))}s(o,"is"),a.is=o})(Cp||(Cp={})),(function(a){function i(c,l){return{range:c,parent:l}}s(i,"create"),a.create=i;function o(c){let l=c;return E.objectLiteral(l)&&ee.is(l.range)&&(l.parent===void 0||a.is(l.parent))}s(o,"is"),a.is=o})(Sp||(Sp={})),(function(a){a.namespace="namespace",a.type="type",a.class="class",a.enum="enum",a.interface="interface",a.struct="struct",a.typeParameter="typeParameter",a.parameter="parameter",a.variable="variable",a.property="property",a.enumMember="enumMember",a.event="event",a.function="function",a.method="method",a.macro="macro",a.keyword="keyword",a.modifier="modifier",a.comment="comment",a.string="string",a.number="number",a.regexp="regexp",a.operator="operator",a.decorator="decorator"})(bp||(bp={})),(function(a){a.declaration="declaration",a.definition="definition",a.readonly="readonly",a.static="static",a.deprecated="deprecated",a.abstract="abstract",a.async="async",a.modification="modification",a.documentation="documentation",a.defaultLibrary="defaultLibrary"})(wp||(wp={})),(function(a){function i(o){const c=o;return E.objectLiteral(c)&&(c.resultId===void 0||typeof c.resultId=="string")&&Array.isArray(c.data)&&(c.data.length===0||typeof c.data[0]=="number")}s(i,"is"),a.is=i})(Ip||(Ip={})),(function(a){function i(c,l){return{range:c,text:l}}s(i,"create"),a.create=i;function o(c){const l=c;return l!=null&&ee.is(l.range)&&E.string(l.text)}s(o,"is"),a.is=o})(Np||(Np={})),(function(a){function i(c,l,u){return{range:c,variableName:l,caseSensitiveLookup:u}}s(i,"create"),a.create=i;function o(c){const l=c;return l!=null&&ee.is(l.range)&&E.boolean(l.caseSensitiveLookup)&&(E.string(l.variableName)||l.variableName===void 0)}s(o,"is"),a.is=o})(kp||(kp={})),(function(a){function i(c,l){return{range:c,expression:l}}s(i,"create"),a.create=i;function o(c){const l=c;return l!=null&&ee.is(l.range)&&(E.string(l.expression)||l.expression===void 0)}s(o,"is"),a.is=o})(Pp||(Pp={})),(function(a){function i(c,l){return{frameId:c,stoppedLocation:l}}s(i,"create"),a.create=i;function o(c){const l=c;return E.defined(l)&&ee.is(c.stoppedLocation)}s(o,"is"),a.is=o})(Op||(Op={})),(function(a){a.Type=1,a.Parameter=2;function i(o){return o===1||o===2}s(i,"is"),a.is=i})(iu||(iu={})),(function(a){function i(c){return{value:c}}s(i,"create"),a.create=i;function o(c){const l=c;return E.objectLiteral(l)&&(l.tooltip===void 0||E.string(l.tooltip)||Aa.is(l.tooltip))&&(l.location===void 0||_l.is(l.location))&&(l.command===void 0||cn.is(l.command))}s(o,"is"),a.is=o})(su||(su={})),(function(a){function i(c,l,u){const f={position:c,label:l};return u!==void 0&&(f.kind=u),f}s(i,"create"),a.create=i;function o(c){const l=c;return E.objectLiteral(l)&&ie.is(l.position)&&(E.string(l.label)||E.typedArray(l.label,su.is))&&(l.kind===void 0||iu.is(l.kind))&&l.textEdits===void 0||E.typedArray(l.textEdits,rr.is)&&(l.tooltip===void 0||E.string(l.tooltip)||Aa.is(l.tooltip))&&(l.paddingLeft===void 0||E.boolean(l.paddingLeft))&&(l.paddingRight===void 0||E.boolean(l.paddingRight))}s(o,"is"),a.is=o})(Lp||(Lp={})),(function(a){function i(o){return{kind:"snippet",value:o}}s(i,"createSnippet"),a.createSnippet=i})(Dp||(Dp={})),(function(a){function i(o,c,l,u){return{insertText:o,filterText:c,range:l,command:u}}s(i,"create"),a.create=i})(Mp||(Mp={})),(function(a){function i(o){return{items:o}}s(i,"create"),a.create=i})(xp||(xp={})),(function(a){a.Invoked=0,a.Automatic=1})(Fp||(Fp={})),(function(a){function i(o,c){return{range:o,text:c}}s(i,"create"),a.create=i})(Gp||(Gp={})),(function(a){function i(o,c){return{triggerKind:o,selectedCompletionInfo:c}}s(i,"create"),a.create=i})(jp||(jp={})),(function(a){function i(o){const c=o;return E.objectLiteral(c)&&eu.is(c.uri)&&E.string(c.name)}s(i,"is"),a.is=i})(Up||(Up={})),hT=[`
1
+ import{ay as er}from"./index-BziFEuBL.js";var LN=Object.create,pc=Object.defineProperty,DN=Object.getOwnPropertyDescriptor,xh=Object.getOwnPropertyNames,MN=Object.getPrototypeOf,xN=Object.prototype.hasOwnProperty,s=(t,e)=>pc(t,"name",{value:e,configurable:!0}),FN=(t,e)=>function(){return t&&(e=(0,t[xh(t)[0]])(t=0)),e},Y=(t,e)=>function(){return e||(0,t[xh(t)[0]])((e={exports:{}}).exports,e),e.exports},Zr=(t,e)=>{for(var r in e)pc(t,r,{get:e[r],enumerable:!0})},Fh=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of xh(e))!xN.call(t,a)&&a!==r&&pc(t,a,{get:()=>e[a],enumerable:!(n=DN(e,a))||n.enumerable});return t},uf=(t,e,r)=>(Fh(t,e,"default"),r),Gh=(t,e,r)=>(r=t!=null?LN(MN(t)):{},Fh(pc(r,"default",{value:t,enumerable:!0}),t)),jh=t=>Fh(pc({},"__esModule",{value:!0}),t),ff={};Zr(ff,{AnnotatedTextEdit:()=>Tr,ChangeAnnotation:()=>un,ChangeAnnotationIdentifier:()=>Xe,CodeAction:()=>Ap,CodeActionContext:()=>$p,CodeActionKind:()=>Rp,CodeActionTriggerKind:()=>Il,CodeDescription:()=>Zd,CodeLens:()=>Ep,Color:()=>tu,ColorInformation:()=>Wd,ColorPresentation:()=>Vd,Command:()=>cn,CompletionItem:()=>lp,CompletionItemKind:()=>rp,CompletionItemLabelDetails:()=>op,CompletionItemTag:()=>ap,CompletionList:()=>cp,CreateFile:()=>Ta,DeleteFile:()=>$a,Diagnostic:()=>Cl,DiagnosticRelatedInformation:()=>ru,DiagnosticSeverity:()=>Xd,DiagnosticTag:()=>Jd,DocumentHighlight:()=>hp,DocumentHighlightKind:()=>pp,DocumentLink:()=>Cp,DocumentSymbol:()=>Tp,DocumentUri:()=>Bd,EOL:()=>hT,FoldingRange:()=>Yd,FoldingRangeKind:()=>Hd,FormattingOptions:()=>_p,Hover:()=>up,InlayHint:()=>Lp,InlayHintKind:()=>iu,InlayHintLabelPart:()=>su,InlineCompletionContext:()=>jp,InlineCompletionItem:()=>Mp,InlineCompletionList:()=>xp,InlineCompletionTriggerKind:()=>Fp,InlineValueContext:()=>Op,InlineValueEvaluatableExpression:()=>Pp,InlineValueText:()=>Np,InlineValueVariableLookup:()=>kp,InsertReplaceEdit:()=>ip,InsertTextFormat:()=>np,InsertTextMode:()=>sp,Location:()=>_l,LocationLink:()=>qd,MarkedString:()=>wl,MarkupContent:()=>Aa,MarkupKind:()=>au,OptionalVersionedTextDocumentIdentifier:()=>bl,ParameterInformation:()=>fp,Position:()=>ie,Range:()=>ee,RenameFile:()=>Ra,SelectedCompletionInfo:()=>Gp,SelectionRange:()=>Sp,SemanticTokenModifiers:()=>wp,SemanticTokenTypes:()=>bp,SemanticTokens:()=>Ip,SignatureInformation:()=>dp,StringValue:()=>Dp,SymbolInformation:()=>yp,SymbolKind:()=>mp,SymbolTag:()=>gp,TextDocument:()=>zp,TextDocumentEdit:()=>Sl,TextDocumentIdentifier:()=>Qd,TextDocumentItem:()=>tp,TextEdit:()=>rr,URI:()=>eu,VersionedTextDocumentIdentifier:()=>ep,WorkspaceChange:()=>pT,WorkspaceEdit:()=>nu,WorkspaceFolder:()=>Up,WorkspaceSymbol:()=>vp,integer:()=>Kd,uinteger:()=>El});var Bd,eu,Kd,El,ie,ee,_l,qd,tu,Wd,Vd,Hd,Yd,ru,Xd,Jd,Zd,Cl,cn,rr,un,Xe,Tr,Sl,Ta,Ra,$a,nu,pl,Rd,pT,Qd,ep,bl,tp,au,Aa,rp,np,ap,ip,sp,op,lp,cp,wl,up,fp,dp,pp,hp,mp,gp,yp,vp,Tp,Rp,Il,$p,Ap,Ep,_p,Cp,Sp,bp,wp,Ip,Np,kp,Pp,Op,iu,su,Lp,Dp,Mp,xp,Fp,Gp,jp,Up,hT,zp,Ey,E,hc=FN({"../../node_modules/.pnpm/vscode-languageserver-types@3.17.5/node_modules/vscode-languageserver-types/lib/esm/main.js"(){var t,e,r,n;(function(a){function i(o){return typeof o=="string"}s(i,"is"),a.is=i})(Bd||(Bd={})),(function(a){function i(o){return typeof o=="string"}s(i,"is"),a.is=i})(eu||(eu={})),(function(a){a.MIN_VALUE=-2147483648,a.MAX_VALUE=2147483647;function i(o){return typeof o=="number"&&a.MIN_VALUE<=o&&o<=a.MAX_VALUE}s(i,"is"),a.is=i})(Kd||(Kd={})),(function(a){a.MIN_VALUE=0,a.MAX_VALUE=2147483647;function i(o){return typeof o=="number"&&a.MIN_VALUE<=o&&o<=a.MAX_VALUE}s(i,"is"),a.is=i})(El||(El={})),(function(a){function i(c,l){return c===Number.MAX_VALUE&&(c=El.MAX_VALUE),l===Number.MAX_VALUE&&(l=El.MAX_VALUE),{line:c,character:l}}s(i,"create"),a.create=i;function o(c){let l=c;return E.objectLiteral(l)&&E.uinteger(l.line)&&E.uinteger(l.character)}s(o,"is"),a.is=o})(ie||(ie={})),(function(a){function i(c,l,u,f){if(E.uinteger(c)&&E.uinteger(l)&&E.uinteger(u)&&E.uinteger(f))return{start:ie.create(c,l),end:ie.create(u,f)};if(ie.is(c)&&ie.is(l))return{start:c,end:l};throw new Error(`Range#create called with invalid arguments[${c}, ${l}, ${u}, ${f}]`)}s(i,"create"),a.create=i;function o(c){let l=c;return E.objectLiteral(l)&&ie.is(l.start)&&ie.is(l.end)}s(o,"is"),a.is=o})(ee||(ee={})),(function(a){function i(c,l){return{uri:c,range:l}}s(i,"create"),a.create=i;function o(c){let l=c;return E.objectLiteral(l)&&ee.is(l.range)&&(E.string(l.uri)||E.undefined(l.uri))}s(o,"is"),a.is=o})(_l||(_l={})),(function(a){function i(c,l,u,f){return{targetUri:c,targetRange:l,targetSelectionRange:u,originSelectionRange:f}}s(i,"create"),a.create=i;function o(c){let l=c;return E.objectLiteral(l)&&ee.is(l.targetRange)&&E.string(l.targetUri)&&ee.is(l.targetSelectionRange)&&(ee.is(l.originSelectionRange)||E.undefined(l.originSelectionRange))}s(o,"is"),a.is=o})(qd||(qd={})),(function(a){function i(c,l,u,f){return{red:c,green:l,blue:u,alpha:f}}s(i,"create"),a.create=i;function o(c){const l=c;return E.objectLiteral(l)&&E.numberRange(l.red,0,1)&&E.numberRange(l.green,0,1)&&E.numberRange(l.blue,0,1)&&E.numberRange(l.alpha,0,1)}s(o,"is"),a.is=o})(tu||(tu={})),(function(a){function i(c,l){return{range:c,color:l}}s(i,"create"),a.create=i;function o(c){const l=c;return E.objectLiteral(l)&&ee.is(l.range)&&tu.is(l.color)}s(o,"is"),a.is=o})(Wd||(Wd={})),(function(a){function i(c,l,u){return{label:c,textEdit:l,additionalTextEdits:u}}s(i,"create"),a.create=i;function o(c){const l=c;return E.objectLiteral(l)&&E.string(l.label)&&(E.undefined(l.textEdit)||rr.is(l))&&(E.undefined(l.additionalTextEdits)||E.typedArray(l.additionalTextEdits,rr.is))}s(o,"is"),a.is=o})(Vd||(Vd={})),(function(a){a.Comment="comment",a.Imports="imports",a.Region="region"})(Hd||(Hd={})),(function(a){function i(c,l,u,f,d,p){const g={startLine:c,endLine:l};return E.defined(u)&&(g.startCharacter=u),E.defined(f)&&(g.endCharacter=f),E.defined(d)&&(g.kind=d),E.defined(p)&&(g.collapsedText=p),g}s(i,"create"),a.create=i;function o(c){const l=c;return E.objectLiteral(l)&&E.uinteger(l.startLine)&&E.uinteger(l.startLine)&&(E.undefined(l.startCharacter)||E.uinteger(l.startCharacter))&&(E.undefined(l.endCharacter)||E.uinteger(l.endCharacter))&&(E.undefined(l.kind)||E.string(l.kind))}s(o,"is"),a.is=o})(Yd||(Yd={})),(function(a){function i(c,l){return{location:c,message:l}}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&_l.is(l.location)&&E.string(l.message)}s(o,"is"),a.is=o})(ru||(ru={})),(function(a){a.Error=1,a.Warning=2,a.Information=3,a.Hint=4})(Xd||(Xd={})),(function(a){a.Unnecessary=1,a.Deprecated=2})(Jd||(Jd={})),(function(a){function i(o){const c=o;return E.objectLiteral(c)&&E.string(c.href)}s(i,"is"),a.is=i})(Zd||(Zd={})),(function(a){function i(c,l,u,f,d,p){let g={range:c,message:l};return E.defined(u)&&(g.severity=u),E.defined(f)&&(g.code=f),E.defined(d)&&(g.source=d),E.defined(p)&&(g.relatedInformation=p),g}s(i,"create"),a.create=i;function o(c){var l;let u=c;return E.defined(u)&&ee.is(u.range)&&E.string(u.message)&&(E.number(u.severity)||E.undefined(u.severity))&&(E.integer(u.code)||E.string(u.code)||E.undefined(u.code))&&(E.undefined(u.codeDescription)||E.string((l=u.codeDescription)===null||l===void 0?void 0:l.href))&&(E.string(u.source)||E.undefined(u.source))&&(E.undefined(u.relatedInformation)||E.typedArray(u.relatedInformation,ru.is))}s(o,"is"),a.is=o})(Cl||(Cl={})),(function(a){function i(c,l,...u){let f={title:c,command:l};return E.defined(u)&&u.length>0&&(f.arguments=u),f}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&E.string(l.title)&&E.string(l.command)}s(o,"is"),a.is=o})(cn||(cn={})),(function(a){function i(u,f){return{range:u,newText:f}}s(i,"replace"),a.replace=i;function o(u,f){return{range:{start:u,end:u},newText:f}}s(o,"insert"),a.insert=o;function c(u){return{range:u,newText:""}}s(c,"del"),a.del=c;function l(u){const f=u;return E.objectLiteral(f)&&E.string(f.newText)&&ee.is(f.range)}s(l,"is"),a.is=l})(rr||(rr={})),(function(a){function i(c,l,u){const f={label:c};return l!==void 0&&(f.needsConfirmation=l),u!==void 0&&(f.description=u),f}s(i,"create"),a.create=i;function o(c){const l=c;return E.objectLiteral(l)&&E.string(l.label)&&(E.boolean(l.needsConfirmation)||l.needsConfirmation===void 0)&&(E.string(l.description)||l.description===void 0)}s(o,"is"),a.is=o})(un||(un={})),(function(a){function i(o){const c=o;return E.string(c)}s(i,"is"),a.is=i})(Xe||(Xe={})),(function(a){function i(u,f,d){return{range:u,newText:f,annotationId:d}}s(i,"replace"),a.replace=i;function o(u,f,d){return{range:{start:u,end:u},newText:f,annotationId:d}}s(o,"insert"),a.insert=o;function c(u,f){return{range:u,newText:"",annotationId:f}}s(c,"del"),a.del=c;function l(u){const f=u;return rr.is(f)&&(un.is(f.annotationId)||Xe.is(f.annotationId))}s(l,"is"),a.is=l})(Tr||(Tr={})),(function(a){function i(c,l){return{textDocument:c,edits:l}}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&bl.is(l.textDocument)&&Array.isArray(l.edits)}s(o,"is"),a.is=o})(Sl||(Sl={})),(function(a){function i(c,l,u){let f={kind:"create",uri:c};return l!==void 0&&(l.overwrite!==void 0||l.ignoreIfExists!==void 0)&&(f.options=l),u!==void 0&&(f.annotationId=u),f}s(i,"create"),a.create=i;function o(c){let l=c;return l&&l.kind==="create"&&E.string(l.uri)&&(l.options===void 0||(l.options.overwrite===void 0||E.boolean(l.options.overwrite))&&(l.options.ignoreIfExists===void 0||E.boolean(l.options.ignoreIfExists)))&&(l.annotationId===void 0||Xe.is(l.annotationId))}s(o,"is"),a.is=o})(Ta||(Ta={})),(function(a){function i(c,l,u,f){let d={kind:"rename",oldUri:c,newUri:l};return u!==void 0&&(u.overwrite!==void 0||u.ignoreIfExists!==void 0)&&(d.options=u),f!==void 0&&(d.annotationId=f),d}s(i,"create"),a.create=i;function o(c){let l=c;return l&&l.kind==="rename"&&E.string(l.oldUri)&&E.string(l.newUri)&&(l.options===void 0||(l.options.overwrite===void 0||E.boolean(l.options.overwrite))&&(l.options.ignoreIfExists===void 0||E.boolean(l.options.ignoreIfExists)))&&(l.annotationId===void 0||Xe.is(l.annotationId))}s(o,"is"),a.is=o})(Ra||(Ra={})),(function(a){function i(c,l,u){let f={kind:"delete",uri:c};return l!==void 0&&(l.recursive!==void 0||l.ignoreIfNotExists!==void 0)&&(f.options=l),u!==void 0&&(f.annotationId=u),f}s(i,"create"),a.create=i;function o(c){let l=c;return l&&l.kind==="delete"&&E.string(l.uri)&&(l.options===void 0||(l.options.recursive===void 0||E.boolean(l.options.recursive))&&(l.options.ignoreIfNotExists===void 0||E.boolean(l.options.ignoreIfNotExists)))&&(l.annotationId===void 0||Xe.is(l.annotationId))}s(o,"is"),a.is=o})($a||($a={})),(function(a){function i(o){let c=o;return c&&(c.changes!==void 0||c.documentChanges!==void 0)&&(c.documentChanges===void 0||c.documentChanges.every(l=>E.string(l.kind)?Ta.is(l)||Ra.is(l)||$a.is(l):Sl.is(l)))}s(i,"is"),a.is=i})(nu||(nu={})),pl=(t=class{constructor(i,o){this.edits=i,this.changeAnnotations=o}insert(i,o,c){let l,u;if(c===void 0?l=rr.insert(i,o):Xe.is(c)?(u=c,l=Tr.insert(i,o,c)):(this.assertChangeAnnotations(this.changeAnnotations),u=this.changeAnnotations.manage(c),l=Tr.insert(i,o,u)),this.edits.push(l),u!==void 0)return u}replace(i,o,c){let l,u;if(c===void 0?l=rr.replace(i,o):Xe.is(c)?(u=c,l=Tr.replace(i,o,c)):(this.assertChangeAnnotations(this.changeAnnotations),u=this.changeAnnotations.manage(c),l=Tr.replace(i,o,u)),this.edits.push(l),u!==void 0)return u}delete(i,o){let c,l;if(o===void 0?c=rr.del(i):Xe.is(o)?(l=o,c=Tr.del(i,o)):(this.assertChangeAnnotations(this.changeAnnotations),l=this.changeAnnotations.manage(o),c=Tr.del(i,l)),this.edits.push(c),l!==void 0)return l}add(i){this.edits.push(i)}all(){return this.edits}clear(){this.edits.splice(0,this.edits.length)}assertChangeAnnotations(i){if(i===void 0)throw new Error("Text edit change is not configured to manage change annotations.")}},s(t,"TextEditChangeImpl"),t),Rd=(e=class{constructor(i){this._annotations=i===void 0?Object.create(null):i,this._counter=0,this._size=0}all(){return this._annotations}get size(){return this._size}manage(i,o){let c;if(Xe.is(i)?c=i:(c=this.nextId(),o=i),this._annotations[c]!==void 0)throw new Error(`Id ${c} is already in use.`);if(o===void 0)throw new Error(`No annotation provided for id ${c}`);return this._annotations[c]=o,this._size++,c}nextId(){return this._counter++,this._counter.toString()}},s(e,"ChangeAnnotations"),e),pT=(r=class{constructor(i){this._textEditChanges=Object.create(null),i!==void 0?(this._workspaceEdit=i,i.documentChanges?(this._changeAnnotations=new Rd(i.changeAnnotations),i.changeAnnotations=this._changeAnnotations.all(),i.documentChanges.forEach(o=>{if(Sl.is(o)){const c=new pl(o.edits,this._changeAnnotations);this._textEditChanges[o.textDocument.uri]=c}})):i.changes&&Object.keys(i.changes).forEach(o=>{const c=new pl(i.changes[o]);this._textEditChanges[o]=c})):this._workspaceEdit={}}get edit(){return this.initDocumentChanges(),this._changeAnnotations!==void 0&&(this._changeAnnotations.size===0?this._workspaceEdit.changeAnnotations=void 0:this._workspaceEdit.changeAnnotations=this._changeAnnotations.all()),this._workspaceEdit}getTextEditChange(i){if(bl.is(i)){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");const o={uri:i.uri,version:i.version};let c=this._textEditChanges[o.uri];if(!c){const l=[],u={textDocument:o,edits:l};this._workspaceEdit.documentChanges.push(u),c=new pl(l,this._changeAnnotations),this._textEditChanges[o.uri]=c}return c}else{if(this.initChanges(),this._workspaceEdit.changes===void 0)throw new Error("Workspace edit is not configured for normal text edit changes.");let o=this._textEditChanges[i];if(!o){let c=[];this._workspaceEdit.changes[i]=c,o=new pl(c),this._textEditChanges[i]=o}return o}}initDocumentChanges(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._changeAnnotations=new Rd,this._workspaceEdit.documentChanges=[],this._workspaceEdit.changeAnnotations=this._changeAnnotations.all())}initChanges(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._workspaceEdit.changes=Object.create(null))}createFile(i,o,c){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");let l;un.is(o)||Xe.is(o)?l=o:c=o;let u,f;if(l===void 0?u=Ta.create(i,c):(f=Xe.is(l)?l:this._changeAnnotations.manage(l),u=Ta.create(i,c,f)),this._workspaceEdit.documentChanges.push(u),f!==void 0)return f}renameFile(i,o,c,l){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");let u;un.is(c)||Xe.is(c)?u=c:l=c;let f,d;if(u===void 0?f=Ra.create(i,o,l):(d=Xe.is(u)?u:this._changeAnnotations.manage(u),f=Ra.create(i,o,l,d)),this._workspaceEdit.documentChanges.push(f),d!==void 0)return d}deleteFile(i,o,c){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");let l;un.is(o)||Xe.is(o)?l=o:c=o;let u,f;if(l===void 0?u=$a.create(i,c):(f=Xe.is(l)?l:this._changeAnnotations.manage(l),u=$a.create(i,c,f)),this._workspaceEdit.documentChanges.push(u),f!==void 0)return f}},s(r,"WorkspaceChange"),r),(function(a){function i(c){return{uri:c}}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&E.string(l.uri)}s(o,"is"),a.is=o})(Qd||(Qd={})),(function(a){function i(c,l){return{uri:c,version:l}}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&E.string(l.uri)&&E.integer(l.version)}s(o,"is"),a.is=o})(ep||(ep={})),(function(a){function i(c,l){return{uri:c,version:l}}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&E.string(l.uri)&&(l.version===null||E.integer(l.version))}s(o,"is"),a.is=o})(bl||(bl={})),(function(a){function i(c,l,u,f){return{uri:c,languageId:l,version:u,text:f}}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&E.string(l.uri)&&E.string(l.languageId)&&E.integer(l.version)&&E.string(l.text)}s(o,"is"),a.is=o})(tp||(tp={})),(function(a){a.PlainText="plaintext",a.Markdown="markdown";function i(o){const c=o;return c===a.PlainText||c===a.Markdown}s(i,"is"),a.is=i})(au||(au={})),(function(a){function i(o){const c=o;return E.objectLiteral(o)&&au.is(c.kind)&&E.string(c.value)}s(i,"is"),a.is=i})(Aa||(Aa={})),(function(a){a.Text=1,a.Method=2,a.Function=3,a.Constructor=4,a.Field=5,a.Variable=6,a.Class=7,a.Interface=8,a.Module=9,a.Property=10,a.Unit=11,a.Value=12,a.Enum=13,a.Keyword=14,a.Snippet=15,a.Color=16,a.File=17,a.Reference=18,a.Folder=19,a.EnumMember=20,a.Constant=21,a.Struct=22,a.Event=23,a.Operator=24,a.TypeParameter=25})(rp||(rp={})),(function(a){a.PlainText=1,a.Snippet=2})(np||(np={})),(function(a){a.Deprecated=1})(ap||(ap={})),(function(a){function i(c,l,u){return{newText:c,insert:l,replace:u}}s(i,"create"),a.create=i;function o(c){const l=c;return l&&E.string(l.newText)&&ee.is(l.insert)&&ee.is(l.replace)}s(o,"is"),a.is=o})(ip||(ip={})),(function(a){a.asIs=1,a.adjustIndentation=2})(sp||(sp={})),(function(a){function i(o){const c=o;return c&&(E.string(c.detail)||c.detail===void 0)&&(E.string(c.description)||c.description===void 0)}s(i,"is"),a.is=i})(op||(op={})),(function(a){function i(o){return{label:o}}s(i,"create"),a.create=i})(lp||(lp={})),(function(a){function i(o,c){return{items:o||[],isIncomplete:!!c}}s(i,"create"),a.create=i})(cp||(cp={})),(function(a){function i(c){return c.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")}s(i,"fromPlainText"),a.fromPlainText=i;function o(c){const l=c;return E.string(l)||E.objectLiteral(l)&&E.string(l.language)&&E.string(l.value)}s(o,"is"),a.is=o})(wl||(wl={})),(function(a){function i(o){let c=o;return!!c&&E.objectLiteral(c)&&(Aa.is(c.contents)||wl.is(c.contents)||E.typedArray(c.contents,wl.is))&&(o.range===void 0||ee.is(o.range))}s(i,"is"),a.is=i})(up||(up={})),(function(a){function i(o,c){return c?{label:o,documentation:c}:{label:o}}s(i,"create"),a.create=i})(fp||(fp={})),(function(a){function i(o,c,...l){let u={label:o};return E.defined(c)&&(u.documentation=c),E.defined(l)?u.parameters=l:u.parameters=[],u}s(i,"create"),a.create=i})(dp||(dp={})),(function(a){a.Text=1,a.Read=2,a.Write=3})(pp||(pp={})),(function(a){function i(o,c){let l={range:o};return E.number(c)&&(l.kind=c),l}s(i,"create"),a.create=i})(hp||(hp={})),(function(a){a.File=1,a.Module=2,a.Namespace=3,a.Package=4,a.Class=5,a.Method=6,a.Property=7,a.Field=8,a.Constructor=9,a.Enum=10,a.Interface=11,a.Function=12,a.Variable=13,a.Constant=14,a.String=15,a.Number=16,a.Boolean=17,a.Array=18,a.Object=19,a.Key=20,a.Null=21,a.EnumMember=22,a.Struct=23,a.Event=24,a.Operator=25,a.TypeParameter=26})(mp||(mp={})),(function(a){a.Deprecated=1})(gp||(gp={})),(function(a){function i(o,c,l,u,f){let d={name:o,kind:c,location:{uri:u,range:l}};return f&&(d.containerName=f),d}s(i,"create"),a.create=i})(yp||(yp={})),(function(a){function i(o,c,l,u){return u!==void 0?{name:o,kind:c,location:{uri:l,range:u}}:{name:o,kind:c,location:{uri:l}}}s(i,"create"),a.create=i})(vp||(vp={})),(function(a){function i(c,l,u,f,d,p){let g={name:c,detail:l,kind:u,range:f,selectionRange:d};return p!==void 0&&(g.children=p),g}s(i,"create"),a.create=i;function o(c){let l=c;return l&&E.string(l.name)&&E.number(l.kind)&&ee.is(l.range)&&ee.is(l.selectionRange)&&(l.detail===void 0||E.string(l.detail))&&(l.deprecated===void 0||E.boolean(l.deprecated))&&(l.children===void 0||Array.isArray(l.children))&&(l.tags===void 0||Array.isArray(l.tags))}s(o,"is"),a.is=o})(Tp||(Tp={})),(function(a){a.Empty="",a.QuickFix="quickfix",a.Refactor="refactor",a.RefactorExtract="refactor.extract",a.RefactorInline="refactor.inline",a.RefactorRewrite="refactor.rewrite",a.Source="source",a.SourceOrganizeImports="source.organizeImports",a.SourceFixAll="source.fixAll"})(Rp||(Rp={})),(function(a){a.Invoked=1,a.Automatic=2})(Il||(Il={})),(function(a){function i(c,l,u){let f={diagnostics:c};return l!=null&&(f.only=l),u!=null&&(f.triggerKind=u),f}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&E.typedArray(l.diagnostics,Cl.is)&&(l.only===void 0||E.typedArray(l.only,E.string))&&(l.triggerKind===void 0||l.triggerKind===Il.Invoked||l.triggerKind===Il.Automatic)}s(o,"is"),a.is=o})($p||($p={})),(function(a){function i(c,l,u){let f={title:c},d=!0;return typeof l=="string"?(d=!1,f.kind=l):cn.is(l)?f.command=l:f.edit=l,d&&u!==void 0&&(f.kind=u),f}s(i,"create"),a.create=i;function o(c){let l=c;return l&&E.string(l.title)&&(l.diagnostics===void 0||E.typedArray(l.diagnostics,Cl.is))&&(l.kind===void 0||E.string(l.kind))&&(l.edit!==void 0||l.command!==void 0)&&(l.command===void 0||cn.is(l.command))&&(l.isPreferred===void 0||E.boolean(l.isPreferred))&&(l.edit===void 0||nu.is(l.edit))}s(o,"is"),a.is=o})(Ap||(Ap={})),(function(a){function i(c,l){let u={range:c};return E.defined(l)&&(u.data=l),u}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&ee.is(l.range)&&(E.undefined(l.command)||cn.is(l.command))}s(o,"is"),a.is=o})(Ep||(Ep={})),(function(a){function i(c,l){return{tabSize:c,insertSpaces:l}}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&E.uinteger(l.tabSize)&&E.boolean(l.insertSpaces)}s(o,"is"),a.is=o})(_p||(_p={})),(function(a){function i(c,l,u){return{range:c,target:l,data:u}}s(i,"create"),a.create=i;function o(c){let l=c;return E.defined(l)&&ee.is(l.range)&&(E.undefined(l.target)||E.string(l.target))}s(o,"is"),a.is=o})(Cp||(Cp={})),(function(a){function i(c,l){return{range:c,parent:l}}s(i,"create"),a.create=i;function o(c){let l=c;return E.objectLiteral(l)&&ee.is(l.range)&&(l.parent===void 0||a.is(l.parent))}s(o,"is"),a.is=o})(Sp||(Sp={})),(function(a){a.namespace="namespace",a.type="type",a.class="class",a.enum="enum",a.interface="interface",a.struct="struct",a.typeParameter="typeParameter",a.parameter="parameter",a.variable="variable",a.property="property",a.enumMember="enumMember",a.event="event",a.function="function",a.method="method",a.macro="macro",a.keyword="keyword",a.modifier="modifier",a.comment="comment",a.string="string",a.number="number",a.regexp="regexp",a.operator="operator",a.decorator="decorator"})(bp||(bp={})),(function(a){a.declaration="declaration",a.definition="definition",a.readonly="readonly",a.static="static",a.deprecated="deprecated",a.abstract="abstract",a.async="async",a.modification="modification",a.documentation="documentation",a.defaultLibrary="defaultLibrary"})(wp||(wp={})),(function(a){function i(o){const c=o;return E.objectLiteral(c)&&(c.resultId===void 0||typeof c.resultId=="string")&&Array.isArray(c.data)&&(c.data.length===0||typeof c.data[0]=="number")}s(i,"is"),a.is=i})(Ip||(Ip={})),(function(a){function i(c,l){return{range:c,text:l}}s(i,"create"),a.create=i;function o(c){const l=c;return l!=null&&ee.is(l.range)&&E.string(l.text)}s(o,"is"),a.is=o})(Np||(Np={})),(function(a){function i(c,l,u){return{range:c,variableName:l,caseSensitiveLookup:u}}s(i,"create"),a.create=i;function o(c){const l=c;return l!=null&&ee.is(l.range)&&E.boolean(l.caseSensitiveLookup)&&(E.string(l.variableName)||l.variableName===void 0)}s(o,"is"),a.is=o})(kp||(kp={})),(function(a){function i(c,l){return{range:c,expression:l}}s(i,"create"),a.create=i;function o(c){const l=c;return l!=null&&ee.is(l.range)&&(E.string(l.expression)||l.expression===void 0)}s(o,"is"),a.is=o})(Pp||(Pp={})),(function(a){function i(c,l){return{frameId:c,stoppedLocation:l}}s(i,"create"),a.create=i;function o(c){const l=c;return E.defined(l)&&ee.is(c.stoppedLocation)}s(o,"is"),a.is=o})(Op||(Op={})),(function(a){a.Type=1,a.Parameter=2;function i(o){return o===1||o===2}s(i,"is"),a.is=i})(iu||(iu={})),(function(a){function i(c){return{value:c}}s(i,"create"),a.create=i;function o(c){const l=c;return E.objectLiteral(l)&&(l.tooltip===void 0||E.string(l.tooltip)||Aa.is(l.tooltip))&&(l.location===void 0||_l.is(l.location))&&(l.command===void 0||cn.is(l.command))}s(o,"is"),a.is=o})(su||(su={})),(function(a){function i(c,l,u){const f={position:c,label:l};return u!==void 0&&(f.kind=u),f}s(i,"create"),a.create=i;function o(c){const l=c;return E.objectLiteral(l)&&ie.is(l.position)&&(E.string(l.label)||E.typedArray(l.label,su.is))&&(l.kind===void 0||iu.is(l.kind))&&l.textEdits===void 0||E.typedArray(l.textEdits,rr.is)&&(l.tooltip===void 0||E.string(l.tooltip)||Aa.is(l.tooltip))&&(l.paddingLeft===void 0||E.boolean(l.paddingLeft))&&(l.paddingRight===void 0||E.boolean(l.paddingRight))}s(o,"is"),a.is=o})(Lp||(Lp={})),(function(a){function i(o){return{kind:"snippet",value:o}}s(i,"createSnippet"),a.createSnippet=i})(Dp||(Dp={})),(function(a){function i(o,c,l,u){return{insertText:o,filterText:c,range:l,command:u}}s(i,"create"),a.create=i})(Mp||(Mp={})),(function(a){function i(o){return{items:o}}s(i,"create"),a.create=i})(xp||(xp={})),(function(a){a.Invoked=0,a.Automatic=1})(Fp||(Fp={})),(function(a){function i(o,c){return{range:o,text:c}}s(i,"create"),a.create=i})(Gp||(Gp={})),(function(a){function i(o,c){return{triggerKind:o,selectedCompletionInfo:c}}s(i,"create"),a.create=i})(jp||(jp={})),(function(a){function i(o){const c=o;return E.objectLiteral(c)&&eu.is(c.uri)&&E.string(c.name)}s(i,"is"),a.is=i})(Up||(Up={})),hT=[`
2
2
  `,`\r
3
3
  `,"\r"],(function(a){function i(u,f,d,p){return new Ey(u,f,d,p)}s(i,"create"),a.create=i;function o(u){let f=u;return!!(E.defined(f)&&E.string(f.uri)&&(E.undefined(f.languageId)||E.string(f.languageId))&&E.uinteger(f.lineCount)&&E.func(f.getText)&&E.func(f.positionAt)&&E.func(f.offsetAt))}s(o,"is"),a.is=o;function c(u,f){let d=u.getText(),p=l(f,(m,T)=>{let _=m.range.start.line-T.range.start.line;return _===0?m.range.start.character-T.range.start.character:_}),g=d.length;for(let m=p.length-1;m>=0;m--){let T=p[m],_=u.offsetAt(T.range.start),v=u.offsetAt(T.range.end);if(v<=g)d=d.substring(0,_)+T.newText+d.substring(v,d.length);else throw new Error("Overlapping edit");g=_}return d}s(c,"applyEdits"),a.applyEdits=c;function l(u,f){if(u.length<=1)return u;const d=u.length/2|0,p=u.slice(0,d),g=u.slice(d);l(p,f),l(g,f);let m=0,T=0,_=0;for(;m<p.length&&T<g.length;)f(p[m],g[T])<=0?u[_++]=p[m++]:u[_++]=g[T++];for(;m<p.length;)u[_++]=p[m++];for(;T<g.length;)u[_++]=g[T++];return u}s(l,"mergeSort")})(zp||(zp={})),Ey=(n=class{constructor(i,o,c,l){this._uri=i,this._languageId=o,this._version=c,this._content=l,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(i){if(i){let o=this.offsetAt(i.start),c=this.offsetAt(i.end);return this._content.substring(o,c)}return this._content}update(i,o){this._content=i.text,this._version=o,this._lineOffsets=void 0}getLineOffsets(){if(this._lineOffsets===void 0){let i=[],o=this._content,c=!0;for(let l=0;l<o.length;l++){c&&(i.push(l),c=!1);let u=o.charAt(l);c=u==="\r"||u===`
4
4
  `,u==="\r"&&l+1<o.length&&o.charAt(l+1)===`