@intent-hq/web 2.392.2 → 2.392.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/web/app/immutable/chunks/{8zgEfd8p.js → 1rapRTWt.js} +4 -4
- package/web/app/immutable/chunks/{Chq1aw8Z.js → 3a2EfPr3.js} +3 -3
- package/web/app/immutable/chunks/{iPZ0ylPo.js → 8cewiIKF.js} +1 -1
- package/web/app/immutable/chunks/{DG6P2gCG.js → 9syQWCSY.js} +7 -7
- package/web/app/immutable/chunks/{C5uq1gUG.js → B-dQn9uM.js} +3 -3
- package/web/app/immutable/chunks/{B0plrICi.js → B-gBwwL_.js} +1 -1
- package/web/app/immutable/chunks/{D8kaRNt1.js → B0tiNr4f.js} +1 -1
- package/web/app/immutable/chunks/{CEwjIkNX.js → B2PSQOFL.js} +1 -1
- package/web/app/immutable/chunks/{B3z7A_dN.js → B2R2ZgJF.js} +1 -1
- package/web/app/immutable/chunks/{C4pn-RG0.js → BD-vsB0h.js} +1 -1
- package/web/app/immutable/chunks/{THKJxtFa.js → BF5nqwtF.js} +1 -1
- package/web/app/immutable/chunks/{C4-ezAa_.js → BGVWM2OL.js} +1 -1
- package/web/app/immutable/chunks/{CfTZUiDx.js → BGXx97df.js} +1 -1
- package/web/app/immutable/chunks/{DERB0Jdj.js → BHza3UCm.js} +1 -1
- package/web/app/immutable/chunks/{Bbz7-Oyr.js → BKNpKZIw.js} +1 -1
- package/web/app/immutable/chunks/{D20BuQ34.js → BLJR_8Kv.js} +2 -2
- package/web/app/immutable/chunks/{D_h5QPHj.js → BLSBgBTe.js} +1 -1
- package/web/app/immutable/chunks/{DuuySJmX.js → BM0QeNkz.js} +1 -1
- package/web/app/immutable/chunks/{B1KwWsSa.js → BNDZKi6v.js} +2 -2
- package/web/app/immutable/chunks/{Bvre4WDp.js → BN_62-aj.js} +1 -1
- package/web/app/immutable/chunks/{Bosx7Vx3.js → BOi9rcQa.js} +4 -4
- package/web/app/immutable/chunks/{D5areLL_.js → BQ2fte0W.js} +1 -1
- package/web/app/immutable/chunks/{d0jTaI_s.js → BRUy0Mem.js} +1 -1
- package/web/app/immutable/chunks/{DceDM5vi.js → BSFEE-6K.js} +1 -1
- package/web/app/immutable/chunks/{COziev1s.js → BT1b_noP.js} +3 -3
- package/web/app/immutable/chunks/{BVEvAi2Z.js → BThkcEjN.js} +1 -1
- package/web/app/immutable/chunks/{CYkK72cK.js → BUfaQEep.js} +1 -1
- package/web/app/immutable/chunks/{BI5Znnvl.js → BUp6TFnM.js} +1 -1
- package/web/app/immutable/chunks/{COdzefrH.js → BWLKi_Oq.js} +1 -1
- package/web/app/immutable/chunks/{_4-WGEtP.js → BWkkvuFz.js} +1 -1
- package/web/app/immutable/chunks/{C7MxCYGe.js → BWu3ORt3.js} +1 -1
- package/web/app/immutable/chunks/{DJFngwyn.js → BXOwV523.js} +1 -1
- package/web/app/immutable/chunks/{DN4W-w9t.js → BZZOp-Go.js} +1 -1
- package/web/app/immutable/chunks/{BaHkhxpe.js → B_RYqFbn.js} +1 -1
- package/web/app/immutable/chunks/{C0vmnkBQ.js → Ba0ctoXN.js} +2 -2
- package/web/app/immutable/chunks/{CkYbvS58.js → BgCxENx1.js} +1 -1
- package/web/app/immutable/chunks/{DBmrZ3Yk.js → Bgy94TB4.js} +1 -1
- package/web/app/immutable/chunks/{CRS_Gu5_.js → BiQ44BNV.js} +1 -1
- package/web/app/immutable/chunks/{y3KZMSiK.js → BiwoewqC.js} +1 -1
- package/web/app/immutable/chunks/{giPqPYXa.js → BjtBOmkK.js} +1 -1
- package/web/app/immutable/chunks/{BNEmqkUA.js → BlRM8cg0.js} +1 -1
- package/web/app/immutable/chunks/{XO_-t4Ky.js → BnZq1xzV.js} +1 -1
- package/web/app/immutable/chunks/{Df7jhhBI.js → BqQNTHsB.js} +1 -1
- package/web/app/immutable/chunks/{xWBeRD3f.js → BqkzCflA.js} +1 -1
- package/web/app/immutable/chunks/{BheHEhKd.js → Bs9Q1k3q.js} +1 -1
- package/web/app/immutable/chunks/{BC5ygYt_.js → BtGc6nEi.js} +1 -1
- package/web/app/immutable/chunks/{BNSALBsz.js → BxiM2JR3.js} +2 -2
- package/web/app/immutable/chunks/{BgThAg3r.js → C1Keoa1n.js} +1 -1
- package/web/app/immutable/chunks/{CTS8A6ux.js → C7p3W1f1.js} +1 -1
- package/web/app/immutable/chunks/{BeO9oetE.js → C804avdU.js} +1 -1
- package/web/app/immutable/chunks/{CaeTGhTg.js → C9SWwe2v.js} +1 -1
- package/web/app/immutable/chunks/{DRWBGAqk.js → CC8htovw.js} +1 -1
- package/web/app/immutable/chunks/{Di5jyd6k.js → CH3jZcNq.js} +1 -1
- package/web/app/immutable/chunks/{DDKN4vcf.js → CKOF2XJr.js} +1 -1
- package/web/app/immutable/chunks/{BBNkFJWF.js → CLF38uvC.js} +1 -1
- package/web/app/immutable/chunks/{sO3fM1GP.js → CMZ4h45V.js} +1 -1
- package/web/app/immutable/chunks/{SMQhPblH.js → CQfllnM7.js} +1 -1
- package/web/app/immutable/chunks/{C_GcujO5.js → CV0ZZGg3.js} +1 -1
- package/web/app/immutable/chunks/{CKJ4i51B.js → CVCbL5Ny.js} +1 -1
- package/web/app/immutable/chunks/{1_KO_ip3.js → CWzP7a_C.js} +2 -2
- package/web/app/immutable/chunks/{C_YUZdUd.js → CXbNsxGs.js} +1 -1
- package/web/app/immutable/chunks/{DOSjgvd4.js → CZM_hlTe.js} +3 -3
- package/web/app/immutable/chunks/{DQliWD4b.js → Cc3530YY.js} +1 -1
- package/web/app/immutable/chunks/{Vh-BjeJL.js → CcA7qiuL.js} +1 -1
- package/web/app/immutable/chunks/{DNZ5cdd7.js → CcJSNYGE.js} +1 -1
- package/web/app/immutable/chunks/{KIfAnxvY.js → CctL9G3j.js} +1 -1
- package/web/app/immutable/chunks/{D3TJ4iaY.js → CdglrbOd.js} +2 -2
- package/web/app/immutable/chunks/{DXUWNyzc.js → Cefxa1Ij.js} +2 -2
- package/web/app/immutable/chunks/{Bshuzu80.js → Cei6kItG.js} +1 -1
- package/web/app/immutable/chunks/{Cgtlzlbv.js → CgeYxezq.js} +1 -1
- package/web/app/immutable/chunks/{DrtzIUiM.js → Cj0Js7c4.js} +1 -1
- package/web/app/immutable/chunks/{Cj1pm0MT.js → CmZ1fgxI.js} +1 -1
- package/web/app/immutable/chunks/{CSd3ES0N.js → CoUsOW3i.js} +1 -1
- package/web/app/immutable/chunks/{Cphslpp1.js → CrF1tS4G.js} +1 -1
- package/web/app/immutable/chunks/{CClkpbU_.js → CtEY2mp_.js} +1 -1
- package/web/app/immutable/chunks/{BworT-hG.js → CvHrN3gi.js} +1 -1
- package/web/app/immutable/chunks/{Da5b0o3C.js → CwCaEF7R.js} +1 -1
- package/web/app/immutable/chunks/{DXVUAQyy.js → Cz53SBs5.js} +1 -1
- package/web/app/immutable/chunks/{DO0aZyxl.js → Czp61MqP.js} +1 -1
- package/web/app/immutable/chunks/{DYCJZbxa.js → D2ZMjII-.js} +1 -1
- package/web/app/immutable/chunks/{DjrhPbR_.js → D4Ih4utJ.js} +1 -1
- package/web/app/immutable/chunks/{DFxTcA3E.js → D6QiN5t4.js} +1 -1
- package/web/app/immutable/chunks/{oS1TO8_n.js → DF7HzTjr.js} +1 -1
- package/web/app/immutable/chunks/{DHFudMqw.js → DFr2eom2.js} +1 -1
- package/web/app/immutable/chunks/{DLt_ME6N.js → DHZOgUKk.js} +1 -1
- package/web/app/immutable/chunks/{CBttKL23.js → DI6AAl0V.js} +1 -1
- package/web/app/immutable/chunks/{Bt2-MCLy.js → DI_1CazU.js} +1 -1
- package/web/app/immutable/chunks/{BnsvCrVF.js → DLV91R-8.js} +1 -1
- package/web/app/immutable/chunks/{xPQp-52E.js → DOVzLB_4.js} +1 -1
- package/web/app/immutable/chunks/{BM-e4VeL.js → DQ7FiFrG.js} +1 -1
- package/web/app/immutable/chunks/{sChr_bGo.js → DbeIbw-A.js} +1 -1
- package/web/app/immutable/chunks/{iqPe99td.js → DeFCWACO.js} +1 -1
- package/web/app/immutable/chunks/{CBNc1G45.js → DfxvTnp2.js} +1 -1
- package/web/app/immutable/chunks/{Cvhr4SQ6.js → DgegreSL.js} +1 -1
- package/web/app/immutable/chunks/{CU6Gap7x.js → DhfduYCG.js} +1 -1
- package/web/app/immutable/chunks/{Bq1RCxZy.js → Dl84MHT_.js} +1 -1
- package/web/app/immutable/chunks/{Budj_98H.js → DmJjL0FQ.js} +1 -1
- package/web/app/immutable/chunks/{YeB2MH-S.js → DsC3Hx4Y.js} +1 -1
- package/web/app/immutable/chunks/{BcwRYKt7.js → Dv8Ar9Yj.js} +2 -2
- package/web/app/immutable/chunks/{osg5eECY.js → DwHO9O_t.js} +1 -1
- package/web/app/immutable/chunks/{DCWe1Cbq.js → DxfrEGHE.js} +1 -1
- package/web/app/immutable/chunks/{DauNjtnc.js → Dxxx3b3f.js} +4 -4
- package/web/app/immutable/chunks/{Cgot5oOf.js → E51IEue4.js} +1 -1
- package/web/app/immutable/chunks/{DP6TPKre.js → ECTHIYjg.js} +1 -1
- package/web/app/immutable/chunks/{C4TLfn6n.js → FUWZfwsu.js} +1 -1
- package/web/app/immutable/chunks/{BaKSWwQZ.js → FrvrVKAr.js} +2 -2
- package/web/app/immutable/chunks/{QvexzmZW.js → GM6GOclC.js} +2 -2
- package/web/app/immutable/chunks/{uri-ziv4.js → K5Y15XEp.js} +1 -1
- package/web/app/immutable/chunks/{B0S6NxMp.js → Nw_03x_O.js} +2 -2
- package/web/app/immutable/chunks/{CWtOXclJ.js → XOkW4e42.js} +1 -1
- package/web/app/immutable/chunks/{CNP0L-eb.js → XoodpWig.js} +1 -1
- package/web/app/immutable/chunks/{C6U5NTf5.js → _4qWkW5Z.js} +1 -1
- package/web/app/immutable/chunks/{CqrBJHEX.js → b43vSRzv.js} +1 -1
- package/web/app/immutable/chunks/{VTJ8c5Pi.js → dH3g6nT7.js} +1 -1
- package/web/app/immutable/chunks/{CyrdNV-V.js → fTzkC5bu.js} +1 -1
- package/web/app/immutable/chunks/{BbBEGYG_.js → fjEL_jqG.js} +1 -1
- package/web/app/immutable/chunks/{lwgrrOYd.js → gjMcPpyn.js} +3 -3
- package/web/app/immutable/chunks/{B6vwIjYj.js → gwOwsb6Y.js} +1 -1
- package/web/app/immutable/chunks/{Dno6lZ_K.js → gyjx6cVc.js} +1 -1
- package/web/app/immutable/chunks/{BIBzuMxT.js → lAIshd25.js} +1 -1
- package/web/app/immutable/chunks/{ZZl62WTG.js → lI5NRJD5.js} +1 -1
- package/web/app/immutable/chunks/{CJD3ragP.js → oZleIIRl.js} +1 -1
- package/web/app/immutable/chunks/{C8EJQhtG.js → rSfDLws2.js} +1 -1
- package/web/app/immutable/chunks/{DkDnBUkd.js → wSfBv2Ay.js} +1 -1
- package/web/app/immutable/chunks/{X4OcqoCu.js → wpcomlxD.js} +1 -1
- package/web/app/immutable/chunks/{DDjTC9Ng.js → ypmJeQ7k.js} +1 -1
- package/web/app/immutable/chunks/{B0uzI9A2.js → zV7CDVYO.js} +3 -3
- package/web/app/immutable/entry/{app.DMjhiR3P.js → app.CxCYUzem.js} +2 -2
- package/web/app/immutable/entry/start.BfdrDzMA.js +1 -0
- package/web/app/immutable/nodes/{0.C7i9QD4T.js → 0.CbFCub9u.js} +1 -1
- package/web/app/immutable/nodes/{1.BLAkNjLi.js → 1.BF-jdAyu.js} +1 -1
- package/web/app/immutable/nodes/{10.BJQbFAUz.js → 10.B9pH_Sj2.js} +1 -1
- package/web/app/immutable/nodes/{11.BUUW97-1.js → 11.Cy4MC3g3.js} +1 -1
- package/web/app/immutable/nodes/{15.Bxp4-WNL.js → 15.j8isxC4q.js} +1 -1
- package/web/app/immutable/nodes/{19.EqYVVTCt.js → 19.Bk3ROmuN.js} +2 -2
- package/web/app/immutable/nodes/{2.C1A3hiDj.js → 2.CEReWbAF.js} +1 -1
- package/web/app/immutable/nodes/{3.xjaKKItm.js → 3.B4wW3oNl.js} +1 -1
- package/web/app/immutable/nodes/{4.fhY4DLRW.js → 4.C4SDmhJa.js} +1 -1
- package/web/app/immutable/nodes/{5.Gnb7dORS.js → 5.Bfum8GuB.js} +1 -1
- package/web/app/immutable/nodes/{6.DYxTUZ3Q.js → 6.BCEjjpDO.js} +1 -1
- package/web/app/immutable/nodes/{7.SR4e3Tlg.js → 7.Bq0Ec-or.js} +1 -1
- package/web/app/immutable/nodes/{8.2WJub-vx.js → 8.K-2IFlg9.js} +1 -1
- package/web/app/immutable/nodes/{9.DwsKz8rq.js → 9.DmkKCkNJ.js} +2 -2
- package/web/app/version.json +1 -1
- package/web/index.html +9 -9
- package/web/app/immutable/entry/start.Cj80d4qw.js +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{g as ae}from"./
|
|
1
|
+
import{g as ae}from"./B-gBwwL_.js";import{s as ce}from"./BqkzCflA.js";import{b as l,ay as C,a1 as le,aP as he,W as de,O as G,X as B,aV as F,a8 as ge,an as ue,au as pe,H as fe}from"./BOi9rcQa.js";var Y=(function(){var n=l(function(x,s,i,o){for(i=i||{},o=x.length;o--;i[x[o]]=s);return i},"o"),e=[1,4],a=[1,13],d=[1,12],t=[1,15],h=[1,16],u=[1,20],m=[1,19],E=[6,7,8],_=[1,26],D=[1,24],w=[1,25],g=[6,7,11],R=[1,6,13,15,16,19,22],q=[1,33],J=[1,34],A=[1,6,7,11,13,15,16,19,22],j={trace:l(function(){},"trace"),yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,MINDMAP:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,ICON:15,CLASS:16,nodeWithId:17,nodeWithoutId:18,NODE_DSTART:19,NODE_DESCR:20,NODE_DEND:21,NODE_ID:22,$accept:0,$end:1},terminals_:{2:"error",6:"SPACELINE",7:"NL",8:"MINDMAP",11:"EOF",13:"SPACELIST",15:"ICON",16:"CLASS",19:"NODE_DSTART",20:"NODE_DESCR",21:"NODE_DEND",22:"NODE_ID"},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,2],[12,2],[12,2],[12,1],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[18,3],[17,1],[17,4]],performAction:l(function(s,i,o,c,f,r,$){var p=r.length-1;switch(f){case 6:case 7:return c;case 8:c.getLogger().trace("Stop NL ");break;case 9:c.getLogger().trace("Stop EOF ");break;case 11:c.getLogger().trace("Stop NL2 ");break;case 12:c.getLogger().trace("Stop EOF2 ");break;case 15:c.getLogger().info("Node: ",r[p].id),c.addNode(r[p-1].length,r[p].id,r[p].descr,r[p].type);break;case 16:c.getLogger().trace("Icon: ",r[p]),c.decorateNode({icon:r[p]});break;case 17:case 21:c.decorateNode({class:r[p]});break;case 18:c.getLogger().trace("SPACELIST");break;case 19:c.getLogger().trace("Node: ",r[p].id),c.addNode(0,r[p].id,r[p].descr,r[p].type);break;case 20:c.decorateNode({icon:r[p]});break;case 25:c.getLogger().trace("node found ..",r[p-2]),this.$={id:r[p-1],descr:r[p-1],type:c.getType(r[p-2],r[p])};break;case 26:this.$={id:r[p],descr:r[p],type:c.nodeType.DEFAULT};break;case 27:c.getLogger().trace("node found ..",r[p-3]),this.$={id:r[p-3],descr:r[p-1],type:c.getType(r[p-2],r[p])};break}},"anonymous"),table:[{3:1,4:2,5:3,6:[1,5],8:e},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:e},{6:a,7:[1,10],9:9,12:11,13:d,14:14,15:t,16:h,17:17,18:18,19:u,22:m},n(E,[2,3]),{1:[2,2]},n(E,[2,4]),n(E,[2,5]),{1:[2,6],6:a,12:21,13:d,14:14,15:t,16:h,17:17,18:18,19:u,22:m},{6:a,9:22,12:11,13:d,14:14,15:t,16:h,17:17,18:18,19:u,22:m},{6:_,7:D,10:23,11:w},n(g,[2,22],{17:17,18:18,14:27,15:[1,28],16:[1,29],19:u,22:m}),n(g,[2,18]),n(g,[2,19]),n(g,[2,20]),n(g,[2,21]),n(g,[2,23]),n(g,[2,24]),n(g,[2,26],{19:[1,30]}),{20:[1,31]},{6:_,7:D,10:32,11:w},{1:[2,7],6:a,12:21,13:d,14:14,15:t,16:h,17:17,18:18,19:u,22:m},n(R,[2,14],{7:q,11:J}),n(A,[2,8]),n(A,[2,9]),n(A,[2,10]),n(g,[2,15]),n(g,[2,16]),n(g,[2,17]),{20:[1,35]},{21:[1,36]},n(R,[2,13],{7:q,11:J}),n(A,[2,11]),n(A,[2,12]),{21:[1,37]},n(g,[2,25]),n(g,[2,27])],defaultActions:{2:[2,1],6:[2,2]},parseError:l(function(s,i){if(i.recoverable)this.trace(s);else{var o=new Error(s);throw o.hash=i,o}},"parseError"),parse:l(function(s){var i=this,o=[0],c=[],f=[null],r=[],$=this.table,p="",M=0,K=0,ie=2,Q=1,se=r.slice.call(arguments,1),y=Object.create(this.lexer),v={yy:{}};for(var H in this.yy)Object.prototype.hasOwnProperty.call(this.yy,H)&&(v.yy[H]=this.yy[H]);y.setInput(s,v.yy),v.yy.lexer=y,v.yy.parser=this,typeof y.yylloc>"u"&&(y.yylloc={});var W=y.yylloc;r.push(W);var re=y.options&&y.options.ranges;typeof v.yy.parseError=="function"?this.parseError=v.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function oe(b){o.length=o.length-2*b,f.length=f.length-b,r.length=r.length-b}l(oe,"popStack");function Z(){var b;return b=c.pop()||y.lex()||Q,typeof b!="number"&&(b instanceof Array&&(c=b,b=c.pop()),b=i.symbols_[b]||b),b}l(Z,"lex");for(var k,T,S,X,O={},U,N,ee,V;;){if(T=o[o.length-1],this.defaultActions[T]?S=this.defaultActions[T]:((k===null||typeof k>"u")&&(k=Z()),S=$[T]&&$[T][k]),typeof S>"u"||!S.length||!S[0]){var z="";V=[];for(U in $[T])this.terminals_[U]&&U>ie&&V.push("'"+this.terminals_[U]+"'");y.showPosition?z="Parse error on line "+(M+1)+`:
|
|
2
2
|
`+y.showPosition()+`
|
|
3
3
|
Expecting `+V.join(", ")+", got '"+(this.terminals_[k]||k)+"'":z="Parse error on line "+(M+1)+": Unexpected "+(k==Q?"end of input":"'"+(this.terminals_[k]||k)+"'"),this.parseError(z,{text:y.match,token:this.terminals_[k]||k,line:y.yylineno,loc:W,expected:V})}if(S[0]instanceof Array&&S.length>1)throw new Error("Parse Error: multiple actions possible at state: "+T+", token: "+k);switch(S[0]){case 1:o.push(k),f.push(y.yytext),r.push(y.yylloc),o.push(S[1]),k=null,K=y.yyleng,p=y.yytext,M=y.yylineno,W=y.yylloc;break;case 2:if(N=this.productions_[S[1]][1],O.$=f[f.length-N],O._$={first_line:r[r.length-(N||1)].first_line,last_line:r[r.length-1].last_line,first_column:r[r.length-(N||1)].first_column,last_column:r[r.length-1].last_column},re&&(O._$.range=[r[r.length-(N||1)].range[0],r[r.length-1].range[1]]),X=this.performAction.apply(O,[p,K,M,v.yy,S[1],f,r].concat(se)),typeof X<"u")return X;N&&(o=o.slice(0,-1*N*2),f=f.slice(0,-1*N),r=r.slice(0,-1*N)),o.push(this.productions_[S[1]][0]),f.push(O.$),r.push(O._$),ee=$[o[o.length-2]][o[o.length-1]],o.push(ee);break;case 3:return!0}}return!0},"parse")},ne=(function(){var x={EOF:1,parseError:l(function(i,o){if(this.yy.parser)this.yy.parser.parseError(i,o);else throw new Error(i)},"parseError"),setInput:l(function(s,i){return this.yy=i||this.yy||{},this._input=s,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:l(function(){var s=this._input[0];this.yytext+=s,this.yyleng++,this.offset++,this.match+=s,this.matched+=s;var i=s.match(/(?:\r\n?|\n).*/g);return i?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),s},"input"),unput:l(function(s){var i=s.length,o=s.split(/(?:\r\n?|\n)/g);this._input=s+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-i),this.offset-=i;var c=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),o.length-1&&(this.yylineno-=o.length-1);var f=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:o?(o.length===c.length?this.yylloc.first_column:0)+c[c.length-o.length].length-o[0].length:this.yylloc.first_column-i},this.options.ranges&&(this.yylloc.range=[f[0],f[0]+this.yyleng-i]),this.yyleng=this.yytext.length,this},"unput"),more:l(function(){return this._more=!0,this},"more"),reject:l(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
4
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:l(function(s){this.unput(this.match.slice(s))},"less"),pastInput:l(function(){var s=this.matched.substr(0,this.matched.length-this.match.length);return(s.length>20?"...":"")+s.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:l(function(){var s=this.match;return s.length<20&&(s+=this._input.substr(0,20-s.length)),(s.substr(0,20)+(s.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:l(function(){var s=this.pastInput(),i=new Array(s.length+1).join("-");return s+this.upcomingInput()+`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var z1=Object.defineProperty;var js=t=>{throw TypeError(t)};var R1=(t,e,r)=>e in t?z1(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r;var le=(t,e,r)=>R1(t,typeof e!="symbol"?e+"":e,r),D1=(t,e,r)=>e.has(t)||js("Cannot "+r);var Vs=(t,e,r)=>e.has(t)?js("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,r);var tn=(t,e,r)=>(D1(t,e,"access private method"),r);import{cR as Vt,b4 as N1,dJ as Xl,a7 as _n,a5 as Ia,a6 as P1,a4 as _1,aa as L1,am as O1,a1 as $1,ea as B1,X as q1,bn as Yl,cU as qr,dI as Zl,b3 as F1,b8 as H1,cC as U1,cS as W1,cn as G1,dD as si,e2 as j1,dX as V1,aK as X0,ax as K1,aF as _i,dH as Ql,ee as Jl,dV as X1,ed as Y1}from"./cD292w1o.js";import{D as Ks,b3 as Z1,bd as Q1,aB as J1}from"./DO0aZyxl.js";import{M as eh,G as hn,I as th}from"./Bqd7fdCF.js";import{zz as y0,JH as E,n_ as ve,nZ as xe,aU as rh,m as ec,I as De,br as gn,kf as Li,mf as w0,ar as Xt,me as Xs,mo as Ys,ml as Zs,jO as tc,gA as oi,I2 as nh,tK as ah,B1 as ih,p1 as sh,n3 as k0,CB as oh,iO as lh,my as ch,m9 as uh}from"./D0qhIm1r.js";import{bm as ie}from"./Fcr7AvC-.js";import{l as rt}from"./C7b3vXLD.js";import{m as hh,f as Tr}from"./B0SSzYpD.js";import{a as vn}from"./BdWqymET.js";import{o as pe,r as Kt,e as bn,s as V,_ as Je,l as yn,g as dh,n as Le,c as dr,b as Ve,u as ph,d as mh}from"./CIyUrgF0.js";import{j as rc}from"./uXuxG9cN.js";import{u as fh}from"./BwweojP5.js";import{selectActiveWorkspaceIds as gh}from"./_IjN0Lbt.js";import{i as je}from"./CL3a4Hm1.js";import{l as za,c as Oi}from"./ChTqQfQN.js";import"./CDCAMh6o.js";import{e as vh,h as Er}from"./DONrLvvt.js";import{h as wn}from"./BAtAwQ72.js";import{i as Qs}from"./BBWuirRW.js";import{f as $i,o as nc,p as ac,h as bh,m as ic,i as yh,k as wh}from"./BeZe2Rt-.js";const Ze=[];for(let t=0;t<256;++t)Ze.push((t+256).toString(16).slice(1));function kh(t,e=0){return(Ze[t[e+0]]+Ze[t[e+1]]+Ze[t[e+2]]+Ze[t[e+3]]+"-"+Ze[t[e+4]]+Ze[t[e+5]]+"-"+Ze[t[e+6]]+Ze[t[e+7]]+"-"+Ze[t[e+8]]+Ze[t[e+9]]+"-"+Ze[t[e+10]]+Ze[t[e+11]]+Ze[t[e+12]]+Ze[t[e+13]]+Ze[t[e+14]]+Ze[t[e+15]]).toLowerCase()}const xh=new Uint8Array(16);function Sh(){return crypto.getRandomValues(xh)}function Bi(t,e,r){return crypto.randomUUID?crypto.randomUUID():Ah(t)}function Ah(t,e,r){t=t||{};const n=t.random??t.rng?.()??Sh();if(n.length<16)throw new Error("Random bytes length must be >= 16");return n[6]=n[6]&15|64,n[8]=n[8]&63|128,kh(n)}function qi(t,e){if(t.repositoryIdentity===null)return null;if(t.repositoryIdentity){const{provider:a,instanceBaseUrl:i,projectPath:s}=t.repositoryIdentity,o=qi({...t,repositoryIdentity:void 0,githubUrl:`${i}/${s}`},a==="gitlab"?i:void 0);return o?.provider===a?o:null}const r=t.githubUrl;if(!r)return null;const n=/^(?:https:\/\/github\.com\/|git@github\.com:)([A-Za-z0-9_.-]+)\/([A-Za-z0-9_.-]+?)(?:\.git)?\/?$/i.exec(r);return n&&!n.slice(1).some(a=>a==="."||a==="..")?{provider:"github",instanceBaseUrl:"https://github.com",projectPath:`${n[1]}/${n[2]}`}:e?eh(r.replace(/\.git\/?$/,""),e):null}function f3(t,e){return t.type==="local"?t.plainFolder?"folder":"local":qi(t,e)?.provider==="gitlab"?"gitlab":"github"}function sc(t){const e=t.split(/[\\/]/).filter(Boolean);return e[e.length-1]??""}function g3(t){if(t.type!=="local")return{ownerPrefix:t.owner,primary:t.name};const e=sc(t.path)||t.name,r=t.owner?`${t.owner}/${t.name}`:void 0;return{primary:e,suffix:r}}function v3(t){return t.type==="local"&&t.path?t.path:void 0}const Th=["/.clones/","/.repo-cache/"];function b3(t){const e=t.replaceAll("\\","/");return Th.some(r=>e.includes(r))}function y3(t){const e=new Set;for(const r of t){const{repositoryPath:n,worktreePath:a}=r;n&&a&&n===a&&e.add(n)}return e}function Eh(t){return t.includes("\\")||t.includes(":")||t.startsWith("/")?void 0:/^([^/]+)\/[^/]+$/.exec(t)?.[1]}function w3(t,e){const{selectedValue:r,selectedRepoType:n,confirmedGithubUrl:a}=t;if(!(n!=="github"||!r)){if(a){const i=e(a)?.owner;if(i)return i}return e(r)?.owner??Eh(r)}}function k3(t,e){const r=e.trim().toLowerCase();return r===""?!0:[t.name,t.path,sc(t.path),t.owner,t.owner?`${t.owner}/${t.name}`:void 0].some(a=>a?.toLowerCase().includes(r)??!1)}const Ch="known-repos",Mh=6e4;function Ih({saved:t,source:e,dismissed:r,mode:n}){if(!e)return[...t];const a=new Map;if(n==="all")for(const s of[...e.repos,...t]){const o=y0(s);a.has(o)||a.set(o,s)}else{for(const s of t)a.set(y0(s),s);for(const s of e.repos)a.set(y0(s),s)}const i=[...a.values()].filter(s=>!r[y0(s)]);return n==="all"?i:i.slice(0,9)}function x3(t){const e=t.lastUsedAt?Date.parse(t.lastUsedAt):NaN;return Number.isFinite(e)?e:0}function S3({visible:t,admission:e,entry:r,readyAt:n,now:a}){return!t||!e?"skip":!r||r.admission!==e?"load":r.status==="pending"?"reuse":r.status==="ready"&&n?.requestId===r.requestId&&a-n.at<Mh?"skip":"load"}function A3(t,e){if(t.type==="local")return t.plainFolder?{repoPath:t.path,plainFolder:!0}:{repoPath:t.path};const r=qi(t,e);return r?.provider==="gitlab"?{repositoryCheckoutDraft:{instanceBaseUrl:r.instanceBaseUrl,projectPath:r.projectPath}}:r?{githubUrl:`https://github.com/${r.projectPath}`,exactRemote:!0}:{githubUrl:t.githubUrl||`https://github.com/${t.path}`,exactRemote:!0}}function zh({compactFormState:t,lastSubmittedAgent:e,specialists:r,orchestratorId:n}){if(t?.isTeamMode??e?.isTeamMode??!1)return n;const i=o=>r.some(c=>c.id===o),s=t?.selectedSpecialist!==void 0?t.selectedSpecialist:e?.selectedSpecialist!==void 0?e.selectedSpecialist:i(Ks)?Ks:null;return s===null||!i(s)?null:s}const T3=E.createSelector(t=>t.workspaceInitializer.hydrated),E3=E.createSelector(t=>t.workspaceInitializer.compactFormState),C3=E.createSelector(t=>t.workspaceInitializer.onboardingFormState),M3=E.createSelector(t=>t.workspaceInitializer.lastSelectedRepo),I3=E.createSelector(t=>t.workspaceInitializer.branchByRepo),z3=E.createSelector(t=>t.workspaceInitializer.defaultParentPath),R3=E.createSelector(t=>ve(t.workspaceInitializer.recentRepos)),D3=E.createSelector((t,e)=>xe(t.workspaceInitializer.recentRepoRefreshes,e)),N3=E.createSelector((t,e)=>xe(t.workspaceInitializer.directoryStatusChecks,e)),P3=E.createSelector(t=>t.workspaceInitializer.dismissedRecentRepoKeys),_3=E.createSelector(t=>ve(t.workspaceInitializer.remoteSetups)),L3=E.createSelector(t=>t.workspaceInitializer.lastSubmittedAgent),O3=E.createSelector(t=>t.workspaceInitializer.agentByRepo),$3=E.createSelector(t=>t.workspaceInitializer.recentSpecialistIds),B3=E.createSelector((t,e)=>t.workspaceInitializer.agentByRepo[e]??null),q3=E.createSelector(t=>t.workspaceInitializer.pendingGitHubPrefill),F3=E.createSelector((t,e)=>({restore:xe(t.workspaceInitializer.draftRestores,e),clear:xe(t.workspaceInitializer.draftClears,e)})),H3=E.createSelector((t,e,r)=>{const n=xe(t.workspaceInitializer.initializationOutcomes,e);return n?.resourceId===r?n:void 0}),U3=E.createSelector((t,e)=>xe(t.workspaceInitializer.initializationOutcomes,e)),W3=E.createSelector((t,e)=>xe(t.workspaceInitializer.initializationResumes,e)),G3=E.createSelector(t=>zh({compactFormState:t.workspaceInitializer.compactFormState,lastSubmittedAgent:t.workspaceInitializer.lastSubmittedAgent,specialists:Q1.select(t),orchestratorId:Z1.select(t)?.id??null})),Rh=E.createSelector(t=>{const e=t.workspaceInitializer.gitCheckRequest,r=Vt.select(t);return e&&r&&N1.select(t)?JSON.stringify([r,e]):null}),j3=E.createSelector(t=>{const e=Rh.select(t),r=t.workspaceInitializer.gitCheck;return e&&r?.context===e?r.available:null}),Dh=E.createSelector(t=>{const e=xe(t.workspaceInitializer.recentRepoRefreshes,Ch),r=Vt.select(t);return Ih({saved:ve(t.workspaceInitializer.recentRepos),source:e&&r&&e.admission===r?e:null,dismissed:t.workspaceInitializer.dismissedRecentRepoKeys,mode:"all"})}),V3=E.createSelector(t=>Xl.select(t)?Dh.select(t):[]),K3=E.createSelector(t=>J1.select(t)||void 0),Js="workspace-debug-flags",x0={enableCreationAnimation:!0,animationDuration:300,enablePageTransitions:!0,enableComponentTransitions:!0,showDebugInfo:!1,showPerformanceMetrics:!1,logStateChanges:!1,enableAutofocus:!0,enableBranchCaching:!0,enableFormPersistence:!0,simulateSlowNetwork:!1,simulateErrors:!1,networkDelay:0};class Nh{constructor(){le(this,"flags");le(this,"listeners",new Set);this.flags=this.loadFlags()}loadFlags(){if(typeof localStorage>"u")return x0;try{const e=localStorage.getItem(Js);if(e)return{...x0,...JSON.parse(e)}}catch(e){za.error("Failed to load debug flags:",e)}return x0}saveFlags(){if(!(typeof localStorage>"u")){try{localStorage.setItem(Js,JSON.stringify(this.flags))}catch(e){za.error("Failed to save debug flags:",e)}this.listeners.forEach(e=>e(this.flags))}}get(e){return this.flags[e]}set(e,r){this.flags[e]=r,this.saveFlags()}toggle(e){typeof this.flags[e]=="boolean"&&(this.flags[e]=!this.flags[e],this.saveFlags())}reset(){this.flags={...x0},this.saveFlags()}getAll(){return{...this.flags}}subscribe(e){return this.listeners.add(e),()=>this.listeners.delete(e)}toggleDebugPanel(){this.toggle("showDebugInfo"),za.info("Debug panel:",this.flags.showDebugInfo?"ON":"OFF")}async simulateDelay(e){return this.flags.simulateSlowNetwork&&this.flags.networkDelay>0&&await new Promise(r=>setTimeout(r,this.flags.networkDelay)),e}}const Ra=new Nh;function X3(t){if(!t)return"";let e=t;return e=e.replace(/\*\*(.+?)\*\*/g,"$1"),e=e.replace(/__(.+?)__/g,"$1"),e=e.replace(/(?<!\*)\*(?!\*)(.+?)(?<!\*)\*(?!\*)/g,"$1"),e=e.replace(/(?<!_)_(?!_)(.+?)(?<!_)_(?!_)/g,"$1"),e=e.replace(/~~(.+?)~~/g,"$1"),e=e.replace(/`([^`]+)`/g,"$1"),e=e.replace(/\[([^\]]+)\]\([^)]+\)/g,"$1"),e=e.replace(/^#{1,6}\s+/gm,""),e=e.replace(/^\*+\s*/gm,""),e=e.replace(/\s*\*+$/gm,""),e.trim()}function Ph(t){return t.charAt(0).toUpperCase()+t.slice(1)}function Y3(t){if(!t||t.trim().length===0)return ie.workspace_sidebarHeader_branchEmpty_error();if(/[\s~^:\\?*\[\\]/.test(t))return ie.workspace_sidebarHeader_branchInvalidChars_error();if(t.includes("@{"))return ie.workspace_sidebarChanges_branchAtBrace_error({seq:"@{"});if(t==="@")return ie.workspace_sidebarChanges_branchAt_error({symbol:"@"});if(t.startsWith("."))return ie.workspace_sidebarHeader_branchStartsDot_error();if(t.endsWith(".lock"))return ie.workspace_sidebarHeader_branchEndsLock_error();if(t.includes(".."))return ie.workspace_sidebarHeader_branchDoubleDot_error();if(t.startsWith("/")||t.endsWith("/"))return ie.workspace_sidebarHeader_branchSlashEnds_error();if(t.includes("//"))return ie.workspace_sidebarHeader_branchDoubleSlash_error();if(t.startsWith("-"))return ie.workspace_sidebarHeader_branchStartsDash_error();if(t.endsWith("."))return ie.workspace_sidebarChanges_branchEndsPeriod_error();const e=t.split("/");for(const r of e){if(r.startsWith("."))return ie.workspace_sidebarChanges_branchComponentStartsDot_error();if(r.endsWith(".lock"))return ie.workspace_sidebarChanges_branchComponentEndsLock_error()}if(t.length>250)return ie.workspace_sidebarHeader_branchTooLong_error()}function Z3(t,e,r,n){return e&&r?`https://github.com/${e}/${r}/pull/${t}`:n||""}function li(t){return t==="Open"?"open":t==="Merged"?"merged":t==="Draft"?"draft":"closed"}function Q3(t,e){return`${e}:${t.agentId??"manual"}`}function _h(t,e){if(t.length===0||e>=t.length)return 0;const r=Math.max(0,e);let n=0;for(let a=r;a<t.length;a++)t[a].isPushed||n++;return n}function Lh(t,e){if(t.length===0||e<0)return 0;const r=Math.min(e,t.length-1);let n=0;for(let a=0;a<=r;a++)t[a].isPushed&&n++;return n}function Oh(t,e){if(t.length===0||e<0)return 0;const r=Math.min(e,t.length-1);let n=0;for(let a=0;a<=r;a++)t[a].isPushed||n++;return n}function J3(t,e,r,n){const a=_h(t,e),i=n?` (origin/${n})`:"";return r?a===1?ie.workspace_sidebarChanges_addToPr_one({suffix:i}):ie.workspace_sidebarChanges_addToPr_many({count:rt(a),suffix:i}):a===1?ie.workspace_sidebarChanges_pushToRemote_one({suffix:i}):ie.workspace_sidebarChanges_pushToRemote_many({count:rt(a),suffix:i})}function e6(t,e,r){const n=Lh(t,e),a=r?` (origin/${r})`:"";return n===1?ie.workspace_sidebarChanges_undoPush_one({suffix:a}):ie.workspace_sidebarChanges_undoPush_many({count:rt(n),suffix:a})}function t6(t,e){const r=Oh(t,e);return r===1?ie.workspace_sidebarChanges_undoCommit_one():ie.workspace_sidebarChanges_undoCommit_many({count:rt(r)})}function r6(t,e){return e===0&&t.length>0}function n6(t,e,r,n){return!r||n==null?!1:t===r&&e===n}function a6(t,e,r){const n=`${e?"staged":"unstaged"}:${t}`;return r.has(n)}function i6(t,e,r){return r?.path===t&&r?.staged===e}function s6(t){if(t.length===0)return[];const e=new Map,r=[...t].sort((n,a)=>n.timestamp-a.timestamp);for(const n of r)for(const a of n.files??[]){const i=e.get(a.path);i?e.set(a.path,{additions:i.additions+(a.additions||0),deletions:i.deletions+(a.deletions||0)}):e.set(a.path,{additions:a.additions||0,deletions:a.deletions||0})}return Array.from(e.entries()).map(([n,a])=>({path:n,additions:a.additions,deletions:a.deletions,staged:!1}))}function o6(t,e,r){const n=new Set;let a=0,i=0;for(const s of t)n.add(s.relativePath),a+=s.stats?.additions||0,i+=s.stats?.deletions||0;for(const s of e)n.add(s.relativePath),a+=s.stats?.additions||0,i+=s.stats?.deletions||0;for(const s of r)for(const o of s.files||[])n.add(o.path),a+=o.additions||0,i+=o.deletions||0;return{totalFilesChanged:n.size,totalAdditions:a,totalDeletions:i}}function $h(t){const e=t?.match(/^https?:\/\/github\.com\/([^/]+)\/([^/]+)\/pull\/\d+/i);return e?`${e[1]}/${e[2]}`:void 0}function l6(t,e,r,n,a){if(t&&t.length>0){const i=a?.split("/")[0];return t.map(s=>{const o=s.url||r(s.number),c=$h(s.url),h=c!==void 0&&c.toLowerCase()!==a?.toLowerCase()?c:void 0;return{number:s.number,title:n(s),url:o,htmlUrl:o,status:li(s.status),createdAt:s.createdAt,updatedAt:s.updatedAt,isInMergeQueue:s.isDraft?void 0:s.isInMergeQueue,crossRepo:h,crossRepoDisplay:h?Fi(h,i):void 0}})}return e?[{number:e.number,title:n(e),url:r(e.number,e.url),htmlUrl:r(e.number,e.url),status:li(e.status),createdAt:e.createdAt,updatedAt:e.updatedAt,isInMergeQueue:e.isDraft?void 0:e.isInMergeQueue}]:[]}function c6(t){const{prNumber:e,prUrl:r}=t;return e==null||!r?null:{id:`legacy-pr-${e}`,number:e,url:r,title:"",status:t.prStatus??rh.Open,createdAt:t.updatedAt,updatedAt:t.updatedAt}}function Bh(t){const e=t.lastSnapshot?.state?.toLowerCase();return e==="merged"?"merged":e==="closed"?"closed":t.lastSnapshot?.isDraft?"draft":t.state==="completed"?"closed":"open"}function Da(t,e,r){if(e.length===0)return t;const n=r?.split("/")[0],a=t.map(i=>({...i}));for(const i of e){const s=!i.resource&&!i.monitorAvailability&&(!r||i.repo===r),o=_n(i),c=o.toLowerCase(),h=a.find(d=>!!o&&d.url.toLowerCase()===c||(i.resource||i.monitorAvailability?d.monitorIdentity===Ia(i):!d.resource&&!d.monitorAvailability&&(s?!d.crossRepo&&d.number===i.prNumber:d.crossRepo===i.repo&&d.number===i.prNumber)));if(h){h.monitorAgentId=i.agentId,h.resource=i.resource,h.monitorAvailability=i.monitorAvailability,h.monitorIdentity=i.resource||i.monitorAvailability?Ia(i):void 0,h.monitorSnapshot=i.lastSnapshot??h.monitorSnapshot;continue}a.push({number:i.prNumber,title:i.title??`${i.repo}${P1(i,i.prNumber)}`,resource:i.resource,monitorAvailability:i.monitorAvailability,monitorIdentity:i.resource||i.monitorAvailability?Ia(i):void 0,url:o,htmlUrl:o,status:Bh(i),createdAt:i.createdAt,updatedAt:i.updatedAt,monitorAgentId:i.agentId,crossRepo:s?void 0:i.repo,crossRepoDisplay:s?void 0:Fi(i.repo,n),monitorSnapshot:i.lastSnapshot,monitorOnly:!0})}return a}function Fi(t,e){return e&&t.toLowerCase().startsWith(`${e.toLowerCase()}/`)?t.slice(e.length+1):t}function u6(t,e,r,n,a){const i=r?.toLowerCase(),s=new Set;for(const k of n)k.repoOwner&&k.repoName&&s.add(`${k.repoOwner}/${k.repoName}`.toLowerCase());let o=t;const c=[],h=[];if(t.some(k=>k.crossRepo)){o=[];for(const k of t)k.crossRepo?s.has(k.crossRepo.toLowerCase())?c.push(k):h.push(k):o.push(k)}const d=[],v=[],m=[];for(const k of e){const I=k.repo.toLowerCase();_n(k)&&o.some(R=>R.url===_n(k))||!k.resource&&!k.monitorAvailability&&(!i||I===i)?d.push(k):_n(k)&&c.some(R=>R.url===_n(k))||!k.resource&&!k.monitorAvailability&&s.has(I)?v.push(k):m.push(k)}const w=Da(o,d,r),A=r?.split("/")[0],C=new Set([...w,...c,...h].map(k=>`${(k.crossRepo??r??"").toLowerCase()}#${k.number}`)),M=[...c];for(const k of n){if(!k.repoOwner||!k.repoName)continue;const I=`${k.repoOwner}/${k.repoName}`;for(const R of k.pullRequests??[]){const Z=`${I.toLowerCase()}#${R.number}`;if(C.has(Z))continue;C.add(Z);const K=R.url||`https://github.com/${I}/pull/${R.number}`,ee=i!==void 0&&I.toLowerCase()===i;M.push({number:R.number,title:a(R),url:K,htmlUrl:K,status:li(R.status),createdAt:R.createdAt,updatedAt:R.updatedAt,crossRepo:ee?void 0:I,crossRepoDisplay:ee?void 0:Fi(I,A)})}}return{own:w,otherRoots:Da(M,v,r),otherTracked:Da(h,m,r)}}function eo(t){return t.status!=="open"?!1:t.monitorSnapshot?t.monitorSnapshot.isInMergeQueue===!0:t.isInMergeQueue===!0}function h6(t){const e=t.status==="merged"?ie.workspace_prSection_merged_label():t.status==="closed"?ie.workspace_prSection_closed_label():t.status==="draft"?ie.workspace_prSection_statusDraft_label():eo(t)?ie.workspace_prSection_statusQueued_label():ie.workspace_prSection_statusOpen_label(),r=[_1(t)??e],n=eo(t)?hh(t.monitorSnapshot?.mergeQueue):null;n&&r.push(n);const a=t.status==="merged"||t.status==="closed"?void 0:t.monitorSnapshot;return a&&(a.checks.total===null||a.checks.passed===null||a.checks.failed===null||a.checks.pending===null||a.availability&&a.availability.checks!=="available"?r.push(ie.chat_monitoredPrs_hover_checksUnknown_label()):a.checks.total>0&&r.push(ie.workspace_prSection_statusChecks_tooltip({passed:rt(a.checks.passed),failed:rt(a.checks.failed),pending:rt(a.checks.pending)})),r.push(a.approvals.have===null||a.availability&&a.availability.approvals!=="available"?ie.chat_monitoredPrs_hover_approvalsUnknown_label():a.approvals.needed!=null?ie.workspace_prSection_statusApprovalsOfNeeded_tooltip({count:rt(a.approvals.have),needed:rt(a.approvals.needed)}):ie.workspace_prSection_statusApprovals_tooltip({count:rt(a.approvals.have)})),a.approvals.changesRequested!==null&&a.approvals.changesRequested>0&&r.push(ie.workspace_prSection_statusChangesRequested_tooltip({count:rt(a.approvals.changesRequested)})),a.availability&&a.availability.discussions!=="available"?r.push(ie.workspace_prSection_statusUnresolvedThreadsUnknown_tooltip()):typeof a.threads.unresolved=="number"?a.threads.unresolved>0&&r.push(ie.workspace_prSection_statusUnresolvedThreads_tooltip({count:rt(a.threads.unresolved)})):a.threads.resolutionRequired&&r.push(ie.workspace_prSection_statusUnresolvedThreadsUnknown_tooltip()),a.mergeBlockedReason&&r.push(Ph(a.mergeBlockedReason))),r.join(`
|
|
1
|
+
var z1=Object.defineProperty;var js=t=>{throw TypeError(t)};var R1=(t,e,r)=>e in t?z1(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r;var le=(t,e,r)=>R1(t,typeof e!="symbol"?e+"":e,r),D1=(t,e,r)=>e.has(t)||js("Cannot "+r);var Vs=(t,e,r)=>e.has(t)?js("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,r);var tn=(t,e,r)=>(D1(t,e,"access private method"),r);import{cR as Vt,b4 as N1,dJ as Xl,a7 as _n,a5 as Ia,a6 as P1,a4 as _1,aa as L1,am as O1,a1 as $1,ea as B1,X as q1,bn as Yl,cU as qr,dI as Zl,b3 as F1,b8 as H1,cC as U1,cS as W1,cn as G1,dD as si,e2 as j1,dX as V1,aK as X0,ax as K1,aF as _i,dH as Ql,ee as Jl,dV as X1,ed as Y1}from"./cD292w1o.js";import{D as Ks,b3 as Z1,bd as Q1,aB as J1}from"./Czp61MqP.js";import{M as eh,G as hn,I as th}from"./Bqd7fdCF.js";import{zz as y0,JH as E,n_ as ve,nZ as xe,aU as rh,m as ec,I as De,br as gn,kf as Li,mf as w0,ar as Xt,me as Xs,mo as Ys,ml as Zs,jO as tc,gA as oi,I2 as nh,tK as ah,B1 as ih,p1 as sh,n3 as k0,CB as oh,iO as lh,my as ch,m9 as uh}from"./D0qhIm1r.js";import{bm as ie}from"./Fcr7AvC-.js";import{l as rt}from"./C7b3vXLD.js";import{m as hh,f as Tr}from"./B0SSzYpD.js";import{a as vn}from"./BdWqymET.js";import{o as pe,r as Kt,e as bn,s as V,_ as Je,l as yn,g as dh,n as Le,c as dr,b as Ve,u as ph,d as mh}from"./CIyUrgF0.js";import{j as rc}from"./uXuxG9cN.js";import{u as fh}from"./BwweojP5.js";import{selectActiveWorkspaceIds as gh}from"./_IjN0Lbt.js";import{i as je}from"./CL3a4Hm1.js";import{l as za,c as Oi}from"./ChTqQfQN.js";import"./CDCAMh6o.js";import{e as vh,h as Er}from"./DONrLvvt.js";import{h as wn}from"./BAtAwQ72.js";import{i as Qs}from"./BBWuirRW.js";import{f as $i,o as nc,p as ac,h as bh,m as ic,i as yh,k as wh}from"./BeZe2Rt-.js";const Ze=[];for(let t=0;t<256;++t)Ze.push((t+256).toString(16).slice(1));function kh(t,e=0){return(Ze[t[e+0]]+Ze[t[e+1]]+Ze[t[e+2]]+Ze[t[e+3]]+"-"+Ze[t[e+4]]+Ze[t[e+5]]+"-"+Ze[t[e+6]]+Ze[t[e+7]]+"-"+Ze[t[e+8]]+Ze[t[e+9]]+"-"+Ze[t[e+10]]+Ze[t[e+11]]+Ze[t[e+12]]+Ze[t[e+13]]+Ze[t[e+14]]+Ze[t[e+15]]).toLowerCase()}const xh=new Uint8Array(16);function Sh(){return crypto.getRandomValues(xh)}function Bi(t,e,r){return crypto.randomUUID?crypto.randomUUID():Ah(t)}function Ah(t,e,r){t=t||{};const n=t.random??t.rng?.()??Sh();if(n.length<16)throw new Error("Random bytes length must be >= 16");return n[6]=n[6]&15|64,n[8]=n[8]&63|128,kh(n)}function qi(t,e){if(t.repositoryIdentity===null)return null;if(t.repositoryIdentity){const{provider:a,instanceBaseUrl:i,projectPath:s}=t.repositoryIdentity,o=qi({...t,repositoryIdentity:void 0,githubUrl:`${i}/${s}`},a==="gitlab"?i:void 0);return o?.provider===a?o:null}const r=t.githubUrl;if(!r)return null;const n=/^(?:https:\/\/github\.com\/|git@github\.com:)([A-Za-z0-9_.-]+)\/([A-Za-z0-9_.-]+?)(?:\.git)?\/?$/i.exec(r);return n&&!n.slice(1).some(a=>a==="."||a==="..")?{provider:"github",instanceBaseUrl:"https://github.com",projectPath:`${n[1]}/${n[2]}`}:e?eh(r.replace(/\.git\/?$/,""),e):null}function f3(t,e){return t.type==="local"?t.plainFolder?"folder":"local":qi(t,e)?.provider==="gitlab"?"gitlab":"github"}function sc(t){const e=t.split(/[\\/]/).filter(Boolean);return e[e.length-1]??""}function g3(t){if(t.type!=="local")return{ownerPrefix:t.owner,primary:t.name};const e=sc(t.path)||t.name,r=t.owner?`${t.owner}/${t.name}`:void 0;return{primary:e,suffix:r}}function v3(t){return t.type==="local"&&t.path?t.path:void 0}const Th=["/.clones/","/.repo-cache/"];function b3(t){const e=t.replaceAll("\\","/");return Th.some(r=>e.includes(r))}function y3(t){const e=new Set;for(const r of t){const{repositoryPath:n,worktreePath:a}=r;n&&a&&n===a&&e.add(n)}return e}function Eh(t){return t.includes("\\")||t.includes(":")||t.startsWith("/")?void 0:/^([^/]+)\/[^/]+$/.exec(t)?.[1]}function w3(t,e){const{selectedValue:r,selectedRepoType:n,confirmedGithubUrl:a}=t;if(!(n!=="github"||!r)){if(a){const i=e(a)?.owner;if(i)return i}return e(r)?.owner??Eh(r)}}function k3(t,e){const r=e.trim().toLowerCase();return r===""?!0:[t.name,t.path,sc(t.path),t.owner,t.owner?`${t.owner}/${t.name}`:void 0].some(a=>a?.toLowerCase().includes(r)??!1)}const Ch="known-repos",Mh=6e4;function Ih({saved:t,source:e,dismissed:r,mode:n}){if(!e)return[...t];const a=new Map;if(n==="all")for(const s of[...e.repos,...t]){const o=y0(s);a.has(o)||a.set(o,s)}else{for(const s of t)a.set(y0(s),s);for(const s of e.repos)a.set(y0(s),s)}const i=[...a.values()].filter(s=>!r[y0(s)]);return n==="all"?i:i.slice(0,9)}function x3(t){const e=t.lastUsedAt?Date.parse(t.lastUsedAt):NaN;return Number.isFinite(e)?e:0}function S3({visible:t,admission:e,entry:r,readyAt:n,now:a}){return!t||!e?"skip":!r||r.admission!==e?"load":r.status==="pending"?"reuse":r.status==="ready"&&n?.requestId===r.requestId&&a-n.at<Mh?"skip":"load"}function A3(t,e){if(t.type==="local")return t.plainFolder?{repoPath:t.path,plainFolder:!0}:{repoPath:t.path};const r=qi(t,e);return r?.provider==="gitlab"?{repositoryCheckoutDraft:{instanceBaseUrl:r.instanceBaseUrl,projectPath:r.projectPath}}:r?{githubUrl:`https://github.com/${r.projectPath}`,exactRemote:!0}:{githubUrl:t.githubUrl||`https://github.com/${t.path}`,exactRemote:!0}}function zh({compactFormState:t,lastSubmittedAgent:e,specialists:r,orchestratorId:n}){if(t?.isTeamMode??e?.isTeamMode??!1)return n;const i=o=>r.some(c=>c.id===o),s=t?.selectedSpecialist!==void 0?t.selectedSpecialist:e?.selectedSpecialist!==void 0?e.selectedSpecialist:i(Ks)?Ks:null;return s===null||!i(s)?null:s}const T3=E.createSelector(t=>t.workspaceInitializer.hydrated),E3=E.createSelector(t=>t.workspaceInitializer.compactFormState),C3=E.createSelector(t=>t.workspaceInitializer.onboardingFormState),M3=E.createSelector(t=>t.workspaceInitializer.lastSelectedRepo),I3=E.createSelector(t=>t.workspaceInitializer.branchByRepo),z3=E.createSelector(t=>t.workspaceInitializer.defaultParentPath),R3=E.createSelector(t=>ve(t.workspaceInitializer.recentRepos)),D3=E.createSelector((t,e)=>xe(t.workspaceInitializer.recentRepoRefreshes,e)),N3=E.createSelector((t,e)=>xe(t.workspaceInitializer.directoryStatusChecks,e)),P3=E.createSelector(t=>t.workspaceInitializer.dismissedRecentRepoKeys),_3=E.createSelector(t=>ve(t.workspaceInitializer.remoteSetups)),L3=E.createSelector(t=>t.workspaceInitializer.lastSubmittedAgent),O3=E.createSelector(t=>t.workspaceInitializer.agentByRepo),$3=E.createSelector(t=>t.workspaceInitializer.recentSpecialistIds),B3=E.createSelector((t,e)=>t.workspaceInitializer.agentByRepo[e]??null),q3=E.createSelector(t=>t.workspaceInitializer.pendingGitHubPrefill),F3=E.createSelector((t,e)=>({restore:xe(t.workspaceInitializer.draftRestores,e),clear:xe(t.workspaceInitializer.draftClears,e)})),H3=E.createSelector((t,e,r)=>{const n=xe(t.workspaceInitializer.initializationOutcomes,e);return n?.resourceId===r?n:void 0}),U3=E.createSelector((t,e)=>xe(t.workspaceInitializer.initializationOutcomes,e)),W3=E.createSelector((t,e)=>xe(t.workspaceInitializer.initializationResumes,e)),G3=E.createSelector(t=>zh({compactFormState:t.workspaceInitializer.compactFormState,lastSubmittedAgent:t.workspaceInitializer.lastSubmittedAgent,specialists:Q1.select(t),orchestratorId:Z1.select(t)?.id??null})),Rh=E.createSelector(t=>{const e=t.workspaceInitializer.gitCheckRequest,r=Vt.select(t);return e&&r&&N1.select(t)?JSON.stringify([r,e]):null}),j3=E.createSelector(t=>{const e=Rh.select(t),r=t.workspaceInitializer.gitCheck;return e&&r?.context===e?r.available:null}),Dh=E.createSelector(t=>{const e=xe(t.workspaceInitializer.recentRepoRefreshes,Ch),r=Vt.select(t);return Ih({saved:ve(t.workspaceInitializer.recentRepos),source:e&&r&&e.admission===r?e:null,dismissed:t.workspaceInitializer.dismissedRecentRepoKeys,mode:"all"})}),V3=E.createSelector(t=>Xl.select(t)?Dh.select(t):[]),K3=E.createSelector(t=>J1.select(t)||void 0),Js="workspace-debug-flags",x0={enableCreationAnimation:!0,animationDuration:300,enablePageTransitions:!0,enableComponentTransitions:!0,showDebugInfo:!1,showPerformanceMetrics:!1,logStateChanges:!1,enableAutofocus:!0,enableBranchCaching:!0,enableFormPersistence:!0,simulateSlowNetwork:!1,simulateErrors:!1,networkDelay:0};class Nh{constructor(){le(this,"flags");le(this,"listeners",new Set);this.flags=this.loadFlags()}loadFlags(){if(typeof localStorage>"u")return x0;try{const e=localStorage.getItem(Js);if(e)return{...x0,...JSON.parse(e)}}catch(e){za.error("Failed to load debug flags:",e)}return x0}saveFlags(){if(!(typeof localStorage>"u")){try{localStorage.setItem(Js,JSON.stringify(this.flags))}catch(e){za.error("Failed to save debug flags:",e)}this.listeners.forEach(e=>e(this.flags))}}get(e){return this.flags[e]}set(e,r){this.flags[e]=r,this.saveFlags()}toggle(e){typeof this.flags[e]=="boolean"&&(this.flags[e]=!this.flags[e],this.saveFlags())}reset(){this.flags={...x0},this.saveFlags()}getAll(){return{...this.flags}}subscribe(e){return this.listeners.add(e),()=>this.listeners.delete(e)}toggleDebugPanel(){this.toggle("showDebugInfo"),za.info("Debug panel:",this.flags.showDebugInfo?"ON":"OFF")}async simulateDelay(e){return this.flags.simulateSlowNetwork&&this.flags.networkDelay>0&&await new Promise(r=>setTimeout(r,this.flags.networkDelay)),e}}const Ra=new Nh;function X3(t){if(!t)return"";let e=t;return e=e.replace(/\*\*(.+?)\*\*/g,"$1"),e=e.replace(/__(.+?)__/g,"$1"),e=e.replace(/(?<!\*)\*(?!\*)(.+?)(?<!\*)\*(?!\*)/g,"$1"),e=e.replace(/(?<!_)_(?!_)(.+?)(?<!_)_(?!_)/g,"$1"),e=e.replace(/~~(.+?)~~/g,"$1"),e=e.replace(/`([^`]+)`/g,"$1"),e=e.replace(/\[([^\]]+)\]\([^)]+\)/g,"$1"),e=e.replace(/^#{1,6}\s+/gm,""),e=e.replace(/^\*+\s*/gm,""),e=e.replace(/\s*\*+$/gm,""),e.trim()}function Ph(t){return t.charAt(0).toUpperCase()+t.slice(1)}function Y3(t){if(!t||t.trim().length===0)return ie.workspace_sidebarHeader_branchEmpty_error();if(/[\s~^:\\?*\[\\]/.test(t))return ie.workspace_sidebarHeader_branchInvalidChars_error();if(t.includes("@{"))return ie.workspace_sidebarChanges_branchAtBrace_error({seq:"@{"});if(t==="@")return ie.workspace_sidebarChanges_branchAt_error({symbol:"@"});if(t.startsWith("."))return ie.workspace_sidebarHeader_branchStartsDot_error();if(t.endsWith(".lock"))return ie.workspace_sidebarHeader_branchEndsLock_error();if(t.includes(".."))return ie.workspace_sidebarHeader_branchDoubleDot_error();if(t.startsWith("/")||t.endsWith("/"))return ie.workspace_sidebarHeader_branchSlashEnds_error();if(t.includes("//"))return ie.workspace_sidebarHeader_branchDoubleSlash_error();if(t.startsWith("-"))return ie.workspace_sidebarHeader_branchStartsDash_error();if(t.endsWith("."))return ie.workspace_sidebarChanges_branchEndsPeriod_error();const e=t.split("/");for(const r of e){if(r.startsWith("."))return ie.workspace_sidebarChanges_branchComponentStartsDot_error();if(r.endsWith(".lock"))return ie.workspace_sidebarChanges_branchComponentEndsLock_error()}if(t.length>250)return ie.workspace_sidebarHeader_branchTooLong_error()}function Z3(t,e,r,n){return e&&r?`https://github.com/${e}/${r}/pull/${t}`:n||""}function li(t){return t==="Open"?"open":t==="Merged"?"merged":t==="Draft"?"draft":"closed"}function Q3(t,e){return`${e}:${t.agentId??"manual"}`}function _h(t,e){if(t.length===0||e>=t.length)return 0;const r=Math.max(0,e);let n=0;for(let a=r;a<t.length;a++)t[a].isPushed||n++;return n}function Lh(t,e){if(t.length===0||e<0)return 0;const r=Math.min(e,t.length-1);let n=0;for(let a=0;a<=r;a++)t[a].isPushed&&n++;return n}function Oh(t,e){if(t.length===0||e<0)return 0;const r=Math.min(e,t.length-1);let n=0;for(let a=0;a<=r;a++)t[a].isPushed||n++;return n}function J3(t,e,r,n){const a=_h(t,e),i=n?` (origin/${n})`:"";return r?a===1?ie.workspace_sidebarChanges_addToPr_one({suffix:i}):ie.workspace_sidebarChanges_addToPr_many({count:rt(a),suffix:i}):a===1?ie.workspace_sidebarChanges_pushToRemote_one({suffix:i}):ie.workspace_sidebarChanges_pushToRemote_many({count:rt(a),suffix:i})}function e6(t,e,r){const n=Lh(t,e),a=r?` (origin/${r})`:"";return n===1?ie.workspace_sidebarChanges_undoPush_one({suffix:a}):ie.workspace_sidebarChanges_undoPush_many({count:rt(n),suffix:a})}function t6(t,e){const r=Oh(t,e);return r===1?ie.workspace_sidebarChanges_undoCommit_one():ie.workspace_sidebarChanges_undoCommit_many({count:rt(r)})}function r6(t,e){return e===0&&t.length>0}function n6(t,e,r,n){return!r||n==null?!1:t===r&&e===n}function a6(t,e,r){const n=`${e?"staged":"unstaged"}:${t}`;return r.has(n)}function i6(t,e,r){return r?.path===t&&r?.staged===e}function s6(t){if(t.length===0)return[];const e=new Map,r=[...t].sort((n,a)=>n.timestamp-a.timestamp);for(const n of r)for(const a of n.files??[]){const i=e.get(a.path);i?e.set(a.path,{additions:i.additions+(a.additions||0),deletions:i.deletions+(a.deletions||0)}):e.set(a.path,{additions:a.additions||0,deletions:a.deletions||0})}return Array.from(e.entries()).map(([n,a])=>({path:n,additions:a.additions,deletions:a.deletions,staged:!1}))}function o6(t,e,r){const n=new Set;let a=0,i=0;for(const s of t)n.add(s.relativePath),a+=s.stats?.additions||0,i+=s.stats?.deletions||0;for(const s of e)n.add(s.relativePath),a+=s.stats?.additions||0,i+=s.stats?.deletions||0;for(const s of r)for(const o of s.files||[])n.add(o.path),a+=o.additions||0,i+=o.deletions||0;return{totalFilesChanged:n.size,totalAdditions:a,totalDeletions:i}}function $h(t){const e=t?.match(/^https?:\/\/github\.com\/([^/]+)\/([^/]+)\/pull\/\d+/i);return e?`${e[1]}/${e[2]}`:void 0}function l6(t,e,r,n,a){if(t&&t.length>0){const i=a?.split("/")[0];return t.map(s=>{const o=s.url||r(s.number),c=$h(s.url),h=c!==void 0&&c.toLowerCase()!==a?.toLowerCase()?c:void 0;return{number:s.number,title:n(s),url:o,htmlUrl:o,status:li(s.status),createdAt:s.createdAt,updatedAt:s.updatedAt,isInMergeQueue:s.isDraft?void 0:s.isInMergeQueue,crossRepo:h,crossRepoDisplay:h?Fi(h,i):void 0}})}return e?[{number:e.number,title:n(e),url:r(e.number,e.url),htmlUrl:r(e.number,e.url),status:li(e.status),createdAt:e.createdAt,updatedAt:e.updatedAt,isInMergeQueue:e.isDraft?void 0:e.isInMergeQueue}]:[]}function c6(t){const{prNumber:e,prUrl:r}=t;return e==null||!r?null:{id:`legacy-pr-${e}`,number:e,url:r,title:"",status:t.prStatus??rh.Open,createdAt:t.updatedAt,updatedAt:t.updatedAt}}function Bh(t){const e=t.lastSnapshot?.state?.toLowerCase();return e==="merged"?"merged":e==="closed"?"closed":t.lastSnapshot?.isDraft?"draft":t.state==="completed"?"closed":"open"}function Da(t,e,r){if(e.length===0)return t;const n=r?.split("/")[0],a=t.map(i=>({...i}));for(const i of e){const s=!i.resource&&!i.monitorAvailability&&(!r||i.repo===r),o=_n(i),c=o.toLowerCase(),h=a.find(d=>!!o&&d.url.toLowerCase()===c||(i.resource||i.monitorAvailability?d.monitorIdentity===Ia(i):!d.resource&&!d.monitorAvailability&&(s?!d.crossRepo&&d.number===i.prNumber:d.crossRepo===i.repo&&d.number===i.prNumber)));if(h){h.monitorAgentId=i.agentId,h.resource=i.resource,h.monitorAvailability=i.monitorAvailability,h.monitorIdentity=i.resource||i.monitorAvailability?Ia(i):void 0,h.monitorSnapshot=i.lastSnapshot??h.monitorSnapshot;continue}a.push({number:i.prNumber,title:i.title??`${i.repo}${P1(i,i.prNumber)}`,resource:i.resource,monitorAvailability:i.monitorAvailability,monitorIdentity:i.resource||i.monitorAvailability?Ia(i):void 0,url:o,htmlUrl:o,status:Bh(i),createdAt:i.createdAt,updatedAt:i.updatedAt,monitorAgentId:i.agentId,crossRepo:s?void 0:i.repo,crossRepoDisplay:s?void 0:Fi(i.repo,n),monitorSnapshot:i.lastSnapshot,monitorOnly:!0})}return a}function Fi(t,e){return e&&t.toLowerCase().startsWith(`${e.toLowerCase()}/`)?t.slice(e.length+1):t}function u6(t,e,r,n,a){const i=r?.toLowerCase(),s=new Set;for(const k of n)k.repoOwner&&k.repoName&&s.add(`${k.repoOwner}/${k.repoName}`.toLowerCase());let o=t;const c=[],h=[];if(t.some(k=>k.crossRepo)){o=[];for(const k of t)k.crossRepo?s.has(k.crossRepo.toLowerCase())?c.push(k):h.push(k):o.push(k)}const d=[],v=[],m=[];for(const k of e){const I=k.repo.toLowerCase();_n(k)&&o.some(R=>R.url===_n(k))||!k.resource&&!k.monitorAvailability&&(!i||I===i)?d.push(k):_n(k)&&c.some(R=>R.url===_n(k))||!k.resource&&!k.monitorAvailability&&s.has(I)?v.push(k):m.push(k)}const w=Da(o,d,r),A=r?.split("/")[0],C=new Set([...w,...c,...h].map(k=>`${(k.crossRepo??r??"").toLowerCase()}#${k.number}`)),M=[...c];for(const k of n){if(!k.repoOwner||!k.repoName)continue;const I=`${k.repoOwner}/${k.repoName}`;for(const R of k.pullRequests??[]){const Z=`${I.toLowerCase()}#${R.number}`;if(C.has(Z))continue;C.add(Z);const K=R.url||`https://github.com/${I}/pull/${R.number}`,ee=i!==void 0&&I.toLowerCase()===i;M.push({number:R.number,title:a(R),url:K,htmlUrl:K,status:li(R.status),createdAt:R.createdAt,updatedAt:R.updatedAt,crossRepo:ee?void 0:I,crossRepoDisplay:ee?void 0:Fi(I,A)})}}return{own:w,otherRoots:Da(M,v,r),otherTracked:Da(h,m,r)}}function eo(t){return t.status!=="open"?!1:t.monitorSnapshot?t.monitorSnapshot.isInMergeQueue===!0:t.isInMergeQueue===!0}function h6(t){const e=t.status==="merged"?ie.workspace_prSection_merged_label():t.status==="closed"?ie.workspace_prSection_closed_label():t.status==="draft"?ie.workspace_prSection_statusDraft_label():eo(t)?ie.workspace_prSection_statusQueued_label():ie.workspace_prSection_statusOpen_label(),r=[_1(t)??e],n=eo(t)?hh(t.monitorSnapshot?.mergeQueue):null;n&&r.push(n);const a=t.status==="merged"||t.status==="closed"?void 0:t.monitorSnapshot;return a&&(a.checks.total===null||a.checks.passed===null||a.checks.failed===null||a.checks.pending===null||a.availability&&a.availability.checks!=="available"?r.push(ie.chat_monitoredPrs_hover_checksUnknown_label()):a.checks.total>0&&r.push(ie.workspace_prSection_statusChecks_tooltip({passed:rt(a.checks.passed),failed:rt(a.checks.failed),pending:rt(a.checks.pending)})),r.push(a.approvals.have===null||a.availability&&a.availability.approvals!=="available"?ie.chat_monitoredPrs_hover_approvalsUnknown_label():a.approvals.needed!=null?ie.workspace_prSection_statusApprovalsOfNeeded_tooltip({count:rt(a.approvals.have),needed:rt(a.approvals.needed)}):ie.workspace_prSection_statusApprovals_tooltip({count:rt(a.approvals.have)})),a.approvals.changesRequested!==null&&a.approvals.changesRequested>0&&r.push(ie.workspace_prSection_statusChangesRequested_tooltip({count:rt(a.approvals.changesRequested)})),a.availability&&a.availability.discussions!=="available"?r.push(ie.workspace_prSection_statusUnresolvedThreadsUnknown_tooltip()):typeof a.threads.unresolved=="number"?a.threads.unresolved>0&&r.push(ie.workspace_prSection_statusUnresolvedThreads_tooltip({count:rt(a.threads.unresolved)})):a.threads.resolutionRequired&&r.push(ie.workspace_prSection_statusUnresolvedThreadsUnknown_tooltip()),a.mergeBlockedReason&&r.push(Ph(a.mergeBlockedReason))),r.join(`
|
|
2
2
|
`)}function d6(t,e){return e.has(t??"manual")}function p6(t,e){return{path:t.relativePath,additions:t.stats.additions,deletions:t.stats.deletions,staged:e,status:t.status,attribution:t.attribution?.agent?{agentId:t.attribution.agent.agentId,agentName:t.attribution.agent.agentName,sessionId:t.attribution.agent.sessionId,turnNumber:t.attribution.agent.turnNumber,timestamp:t.attribution.timestamp}:void 0}}const oc=500;function m6(t,e=oc){const r=Math.max(0,Math.floor(e));return t.length<=r?{visible:t,shown:t.length,hiddenCount:0}:{visible:t.slice(0,r),shown:r,hiddenCount:t.length-r}}function f6(t,e,r=oc){let n=Math.max(0,Math.floor(r)),a=0,i=0;return{groups:t.map(o=>{if(e(o))return{group:o,visibleFiles:[]};const c=Math.min(n,o.files.length);return n-=c,a+=c,i+=o.files.length-c,{group:o,visibleFiles:c===o.files.length?o.files:o.files.slice(0,c)}}),shown:a,hiddenCount:i}}function g6(t){if(t.hiddenCount<=0)return"";const e=rt(t.shown),r=rt(t.shown+t.hiddenCount);return t.hiddenCount===1?ie.workspace_fileChanges_hiddenFiles_one({shown:e,total:r}):ie.workspace_fileChanges_hiddenFiles_many({shown:e,total:r,count:rt(t.hiddenCount)})}function qh(t){if(!t)return{};try{const e=JSON.parse(t);return e&&typeof e=="object"?e:{}}catch{return{}}}function ci(t){return t.startsWith("@")?t.slice(1):t}function Fh(t,e,r,n){const a=t.fullPath||t.path||t.filename;if(a)return ci(String(a));const i=[r,e,n.trim()].map(ci).filter(Boolean),s=i.find(o=>o.includes("/"))??i[0];return s?L1(s).path:void 0}function Hh(t){const e=t.line??t.startLine??t.range?.start;return typeof e=="number"&&Number.isFinite(e)?e:void 0}function Uh(t){if(!t||t.getAttribute("data-mention")===null)return null;const e=t.getAttribute("data-type")||"",r=t.getAttribute("data-id")||"",n=t.getAttribute("data-label")||"",a=t.getAttribute("data-uri")||"",i=qh(t.getAttribute("data-meta")),s={type:e,id:r,label:n,uri:a,meta:i},o=a.startsWith("intent://")?a:typeof i.fullUrl=="string"&&i.fullUrl.startsWith("intent://")?i.fullUrl:void 0;if(o&&(s.intentUrl=o),e==="file"||e==="file-range"){const c=Fh(i,n,r,t.textContent||"");c&&(s.filePath=c);const h=Hh(i);h!==void 0&&(s.line=h)}else if(e==="folder"||e==="source-folder"){const c=i.fullPath||i.path||r||n,h=c?ci(String(c)).replace(/\/+$/,""):"";h&&(s.folderPath=h)}else if(e==="note"||e==="note-range"){const c=i.noteId||r;c&&(s.note=i.isExternalLink&&i.workspaceId?{id:c,workspaceId:String(i.workspaceId)}:{id:c})}return s}function v6(t){return{sidebarTabId:"files",type:"file",filePath:`${t}/`}}function Hi(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var Fr=Hi();function lc(t){Fr=t}var Nr={exec:()=>null};function Cr(t){let e=[];return r=>{let n=Math.max(0,Math.min(3,r-1)),a=e[n];return a||(a=t(n),e[n]=a),a}}function oe(t,e=""){let r=typeof t=="string"?t:t.source,n={replace:(a,i)=>{let s=typeof i=="string"?i:i.source;return s=s.replace(Ue.caret,"$1"),r=r.replace(a,s),n},getRegex:()=>new RegExp(r,e)};return n}var cc=((t="")=>{try{return!!new RegExp("(?<=1)(?<!1)"+t)}catch{return!1}})(),Ue={codeRemoveIndent:/^(?: {0,3}\t| {1,4})/gm,listInterruptsParagraph:/^ {0,3}(?:[*+-]|1[.)])[ \t]+[^ \t\n]/,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,endingSpaceTabChar:/[ \t]$/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,leadingSpaceTab:/^[ \t]+/,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+)[ \t]*)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,blockquoteMarkerWhitespace:/^( {0,3}>)(\t[ \t]*)/gm,nestedBlockMarker:/^ {0,3}(?:(?:[*+-]|\d{1,9}[.)])(?: |$)|> ?)/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\][ \t]+\S/,listReplaceTask:/^\[[ xX]\][ \t]+/,listTaskCheckbox:/\[[ xX]\]/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,numericCharacterReference:/&#(?:(\d{1,7})|[Xx]([A-Fa-f0-9]{1,6}));/,numericCharacterReferenceOrAmpersand:/&#(?:(\d{1,7})|[Xx]([A-Fa-f0-9]{1,6}));|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:t=>new RegExp(`^( {0,3}${t})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:Cr(t=>new RegExp(`^ {0,${t}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`)),hrRegex:Cr(t=>new RegExp(`^ {0,${t}}((?:-[ ]*){3,}|(?:_[ ]*){3,}|(?:\\*[ ]*){3,})(?:\\n+|$)`)),fencesBeginRegex:Cr(t=>new RegExp(`^ {0,${t}}(?:\`\`\`|~~~)`)),headingBeginRegex:Cr(t=>new RegExp(`^ {0,${t}}#{1,6}(?:\\s|$)`)),pedanticHeadingBeginRegex:Cr(t=>new RegExp(`^ {0,${t}}#`)),htmlBeginRegex:Cr(t=>new RegExp(`^ {0,${t}}(?:</?(?:${Wi})(?:[ \\t]+|$|/?>)|<(?:(?:script|pre|style|textarea)(?:[\\s>]|$)|!--)|<\\?|<![A-Za-z]|<!\\[CDATA\\[)`,"i")),blockquoteBeginRegex:Cr(t=>new RegExp(`^ {0,${t}}>`)),nestedContainerMarkers:/^(?: {0,3}(?:(?:[*+-]|\d{1,9}[.)])[ \t]+|>[ \t]?))+/},Wh=/^(?:[ \t]*(?:\n|$))+/,Gh=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,jh=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}(?:(?=`)\1`*|(?=~)\1~*) *(?=\n|$)|$)/,Kn=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,Vh=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,Ui=/ {0,3}(?:[*+-]|\d{1,9}[.)])/,Wi="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",Xn=oe(" {0,3}(?:</?(?:tag)(?:[ \\t]+|\\n|/?>)|<(?:(?:script|pre|style|textarea)(?:[\\s>]|$)|!--)|<\\?|<![A-Za-z]|<!\\[CDATA\\[)").replace("tag",Wi).getRegex(),uc=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |fences|blockquote|heading|hr|html|table))+?)\n {0,3}(=+|-+)[ \t]*(?:\n+|$)/,hc=oe(uc).replace(/bull/g,Ui).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}(?:\s|$)/).replace(/hr/g,/ {0,3}(?:(?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/).replace(/\|table/g,"").replace(/html/g,Xn).getRegex(),Kh=oe(uc).replace(/bull/g,Ui).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}(?:\s|$)/).replace(/hr/g,/ {0,3}(?:(?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).replace(/html/g,Xn).getRegex(),Gi=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table|[ \t]+\n)[^\n]+)*)/,Xh=/^[^\n]+/,ji=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\\n]|\n(?![ \t]*\n))+/,Yh=oe(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<(?:\\.|[^\n<>\\])*>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",ji).replace("title",/(?:"(?:\\[\s\S]|[^"\\])*"|'(?:\\[\s\S]|[^'\\\n]|\n(?!\n))*'|\((?:\\[\s\S]|[^()\\])*\))/).getRegex(),Zh=oe(/^(bull)([ \t][^\n]*?)?(?:\n|$)/).replace(/bull/g,Ui).getRegex(),Vi=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,Qh=oe("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n*|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>[^\\n]*\\n*|$)|<![A-Z][\\s\\S]*?(?:>[^\\n]*\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>[^\\n]*\\n*|$)|</?(tag)(?:[ \\t]+|\\n|/?>|$)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!(?:script|pre|style|textarea)(?![a-z0-9-]))([a-z][a-z0-9-]*)(?:attribute)*?[ \\t]*/?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</[a-z][a-z0-9-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",Vi).replace("tag",Wi).replace("attribute",/[ \t]+[a-zA-Z:_][\w.:-]*(?:[ \t]*=[ \t]*"[^"\n]*"|[ \t]*=[ \t]*'[^'\n]*'|[ \t]*=[ \t]*[^\s"'=<>`]+)?/).getRegex(),dc=t=>oe(Gi).replace("hr",Kn).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace("list",t).replace("html",Xn).getRegex(),Jh=dc(/ {0,3}(?:[*+-]|1[.)])[ \t]+[^ \t\n]/),ed=dc(/ {0,3}(?:[*+-]|\d{1,9}[.)])(?:[ \t]|\n|$)/),td=oe(/^( {0,3}> ?(?:(?![ \t]*(?:\n|$))(paragraph)|[^\n]*)(?:\n|$))+/).replace("paragraph",ed).getRegex(),Ki={blockquote:td,code:Gh,def:Yh,fences:jh,heading:Vh,hr:Kn,html:Qh,lheading:hc,list:Zh,newline:Wh,paragraph:Jh,table:Nr,text:Xh},to=oe("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",Kn).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html",Xn).getRegex(),rd={...Ki,lheading:Kh,table:to,paragraph:oe(Gi).replace("hr",Kn).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",to).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]+[^ \\t\\n]").replace("html",Xn).getRegex()},nd={...Ki,html:oe(`^ *(?:comment(?: *\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1>(?: *\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?>(?: *\\n{2,}|\\s*$))`).replace("comment",Vi).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:Nr,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:oe(Gi).replace("hr",Kn).replace("heading",` *#{1,6} *[^
|
|
3
3
|
]`).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").replace("lheading",hc).getRegex()},ad=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,id=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,pc=/^( {2,}|\\)\n(?!\s*$)[ \t]*/,sd=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,Pt=/[\p{P}\p{S}]/u,kn=/[\s\p{P}\p{S}]/u,Yn=/[^\s\p{P}\p{S}]/u,od=oe(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,kn).getRegex(),ld=/[\p{Pi}\p{Ps}"']/u,mc=/(?!~)[\p{P}\p{S}]/u,cd=/(?!~)[\s\p{P}\p{S}]/u,ud=/(?:[^\s\p{P}\p{S}]|~)/u,hd=oe(/link|precode-code|html/,"g").replace("link",/\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-",cc?"(?<!`)()":"(^^|[^`])").replace("code",/(?<b>`+)[^`]+\k<b>(?!`)/).replace("html",/<(?! )[^<>]*?>/).getRegex(),fc=/^(?:\*+(?:((?!\*)punct)|([^\s*]))?)|^_+(?:((?!_)punct)|([^\s_]))?/,dd=oe(fc,"u").replace(/punct/g,Pt).getRegex(),pd=oe(fc,"u").replace(/punct/g,mc).getRegex(),md=/^(?:\*+(?:((?!\*)(?!openQuote)punct)|([^\s*]))?)|^_+(?:((?!_)(?!openQuote)punct)|([^\s_]))?/,fd=oe(md,"u").replace(/openQuote/g,ld).replace(/punct/g,Pt).getRegex(),gc="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",gd=oe(gc,"gu").replace(/notPunctSpace/g,Yn).replace(/punctSpace/g,kn).replace(/punct/g,Pt).getRegex(),vd=oe(gc,"gu").replace(/notPunctSpace/g,ud).replace(/punctSpace/g,cd).replace(/punct/g,mc).getRegex(),bd="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)[\\s](\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|(?:(?!\\*)punct|notPunctSpace)(\\*+)(?!\\*)(?=notPunctSpace)",yd=oe(bd,"gu").replace(/notPunctSpace/g,Yn).replace(/punctSpace/g,kn).replace(/punct/g,Pt).getRegex(),wd=oe("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,Yn).replace(/punctSpace/g,kn).replace(/punct/g,Pt).getRegex(),kd="^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)[\\s](_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)|(?:(?!_)punct|notPunctSpace)(_+)(?!_)(?=notPunctSpace)",xd=oe(kd,"gu").replace(/notPunctSpace/g,Yn).replace(/punctSpace/g,kn).replace(/punct/g,Pt).getRegex(),Sd=oe(/^~~?(?:((?!~)punct)|[^\s~])/,"u").replace(/punct/g,Pt).getRegex(),Ad="^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)",Td=oe(Ad,"gu").replace(/notPunctSpace/g,Yn).replace(/punctSpace/g,kn).replace(/punct/g,Pt).getRegex(),Ed=oe(/\\(punct)/,"gu").replace(/punct/g,Pt).getRegex(),Cd=oe(/(`+)(?:[^`]|[^`][\s\S]*?[^`])\1(?!`)|`+|\\(punct)/,"gu").replace(/punct/g,Pt).getRegex(),Md=oe(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),Id=oe(Vi).replace("(?:-->|$)","-->").getRegex(),zd=oe("^comment|^</[a-zA-Z][a-zA-Z0-9-]*\\s*>|^<[a-zA-Z][a-zA-Z0-9-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",Id).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),vc=/\[(?:\\[\s\S]|[^\[\]\\])*\]/,q0=oe(/(?:\[(?:brackets|\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\])|[^\[\]\\`])*?/).replace("brackets",vc).getRegex(),Rd=oe(/^!?\[(label)\]\([ \t\n]*(href)(?:(?:[ \t]+(?:\n[ \t]*)?|\n[ \t]*)(title))?[ \t\n]*\)/).replace("label",q0).replace("href",/<(?:\\.|[^\n<>\\])*>|(?!<)[^ \t\n\x00-\x1f]+|(?=\))/).replace("title",/"(?:\\[\s\S]|[^"\\])*"|'(?:\\[\s\S]|[^'\\])*'|\((?:\\[\s\S]|[^)\\])*\)/).getRegex(),Dd=oe(/^!?\[(label)\]\[(ref)\]/).replace("label",q0).replace("ref",ji).getRegex(),Nd=oe(/^!?\[(ref)\](?:\[\])?/).replace("ref",ji).getRegex(),ro=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\]){1,999}/,Pd=oe(/(?:[^\[\]\\`]*(?:\[(?:brackets|\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\]))){0,999}?[^\[\]\\`]*?/).replace("brackets",vc).getRegex(),_d=oe("reflink|nolink(?!\\()","g").replace("reflink",oe(/^!?\[(label)\]\[(ref)\]/).replace("label",Pd).replace("ref",ro).getRegex()).replace("nolink",oe(/^!?\[(ref)\](?:\[\])?/).replace("ref",ro).getRegex()).getRegex(),no=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,Ld=/[A-Za-z0-9._+-]+@[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![\w-])/,Od=oe(/(?:mailto:email|xmpp:email(?:\/[A-Za-z0-9@.]+)?)/).replace(/email/g,Ld).getRegex(),Xi={_backpedal:Nr,anyPunctuation:Ed,anyPunctuationOutsideCode:Cd,autolink:Md,blockSkip:hd,br:pc,code:id,del:Nr,delLDelim:Nr,delRDelim:Nr,emStrongLDelim:dd,emStrongRDelimAst:gd,emStrongRDelimUnd:wd,escape:ad,link:Rd,nolink:Nd,punctuation:od,reflink:Dd,reflinkSearch:_d,tag:zd,text:sd,url:Nr},$d={...Xi,emStrongLDelim:fd,emStrongRDelimAst:yd,emStrongRDelimUnd:xd,link:oe(/^!?\[(label)\]\((.*?)\)/).replace("label",q0).getRegex(),reflink:oe(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",q0).getRegex()},ui={...Xi,emStrongRDelimAst:vd,emStrongLDelim:pd,delLDelim:Sd,delRDelim:Td,url:oe(/^emailProtocol|^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("emailProtocol",Od).replace("protocol",no).replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![\w-])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:oe(/^(?:[^a-zA-Z0-9](?=emailProtocol)|(`+|~+|[^`~])(?:(?=[`~])|(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|wwwStart|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9](?=emailProtocol)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@))))/).replace("protocol",no).replace(/emailProtocol/g,/(?:mailto|xmpp):/).replace("wwwStart",cc?"(?<![^\\s*_~(])www\\.":"www\\.").getRegex()},Bd={...ui,br:oe(pc).replace("{2,}","*").getRegex(),text:oe(ui.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},S0={normal:Ki,gfm:rd,pedantic:nd},Mn={normal:Xi,gfm:ui,breaks:Bd,pedantic:$d},qd={"&":"&","<":"<",">":">",'"':""","'":"'"},ao=t=>qd[t];function mt(t,e){if(e){if(Ue.escapeTest.test(t))return t.replace(Ue.escapeReplace,ao)}else if(Ue.escapeTestNoEncode.test(t))return t.replace(Ue.escapeReplaceNoEncode,ao);return t}function Fd(t){return Ue.numericCharacterReference.test(t)?t.replace(Ue.numericCharacterReferenceOrAmpersand,(e,r,n)=>{if(r===void 0&&n===void 0)return"&";let a=r===void 0?Number.parseInt(n,16):Number.parseInt(r,10);return a===0||a>1114111||a>=55296&&a<=57343?"�":a===38?"&":String.fromCodePoint(a)}):t}function io(t){try{t=encodeURI(t).replace(Ue.percentDecode,"%")}catch{return null}return t}function so(t,e){let r=t.replace(Ue.findPipe,(i,s,o)=>{let c=!1,h=s;for(;--h>=0&&o[h]==="\\";)c=!c;return c?"|":" |"}),n=r.split(Ue.splitPipe),a=0;if(n[0].trim()||n.shift(),n.length>0&&!n.at(-1)?.trim()&&n.pop(),e)if(n.length>e)n.splice(e);else for(;n.length<e;)n.push("");for(;a<n.length;a++)n[a]=n[a].trim().replace(Ue.slashPipe,"|");return n}function qt(t,e,r){let n=t.length;if(n===0)return"";let a=0;for(;a<n&&t.charAt(n-a-1)===e;)a++;return t.slice(0,n-a)}function oo(t){let e=t.split(`
|
|
4
4
|
`),r=e.length-1;for(;r>=0&&Ue.blankLine.test(e[r]);)r--;return e.length-r<=2?t:e.slice(0,r+1).join(`
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["/app/immutable/chunks/
|
|
2
|
-
import{bm as o,t as st,bo as K,bw as nt,b as ot,bq as Ft,bs as Fe,_ as Ut}from"./Fcr7AvC-.js";import{bs as it,a5 as f,aD as t,bA as v,b_ as T,W as y,bn as ct,c9 as k,aA as H,aB as S,ca as Ue,bk as Vt,c6 as Yt,cd as Pe,bV as Gt,bS as g,ay as ge,bl as M,bO as N}from"./3SdAC2_C.js";import{i as $}from"./BhYXv0ZM.js";import{e as Ve,g as Ye}from"./CA6H1-bp.js";import{c as Qt,e as Xt,f as lt,g as Jt,s as x}from"./BRCr02in.js";import{a_ as Zt,db as ea,X as ta,aI as aa,dE as ra,a3 as sa,dI as dt}from"./cD292w1o.js";import{t as Ge}from"./DAsc1V4f.js";import{b as na,A as oa}from"./6_Ki4zfU.js";import{p as Qe}from"./DauNjtnc.js";import{aN as ia,aK as ca,aL as Xe,a1 as la}from"./BeZe2Rt-.js";import{S as le}from"./D7KhILhs.js";import"./BAtAwQ72.js";import{f as Je}from"./Beq_QLuz.js";import{l as B,n as da}from"./C7b3vXLD.js";import{sd as ut,JH as W,mP as ua,fV as pa,nM as va,v1 as ma,c as _a,wE as ga,tG as fa,rW as wa}from"./D0qhIm1r.js";import{c as ba}from"./ChTqQfQN.js";import{o as ka}from"./DBmrZ3Yk.js";import{aR as ha,aS as Ze,bC as ya,aB as xa,bB as Sa,aG as Aa,d3 as Ca,cT as Ra,F as fe,ay as et,bK as Ia}from"./ChHRVjww.js";import{selectCurrentWorkspaceTabId as Pa}from"./_IjN0Lbt.js";import{p as qa}from"./BbBEGYG_.js";import{i as Ma}from"./Chq1aw8Z.js";const Na=new Set(["failed","blocked","needs_attention","in_progress"]),Wa={failed:{visual:"icon",icon:Ra,className:"text-foreground"},blocked:{visual:"icon",icon:Ca,className:"text-danger"},needs_attention:{visual:"icon",icon:Aa,className:"text-warning-ink"},in_progress:{visual:"dot",icon:null,className:"workspace-status-color-active"},waiting:{visual:"icon",icon:Sa,className:"text-muted-foreground"},unread:{visual:"dot",icon:null,className:"workspace-status-color-unread"},not_started:{visual:"dot",icon:null,className:"text-muted-foreground/35"},idle:{visual:"dot",icon:null,className:"text-muted-foreground/35"},complete:{visual:"icon",icon:xa,className:"text-success"},pr_queued:{visual:"icon",icon:ya,className:"text-info"},pr_ready:{visual:"icon",icon:Ze,className:"text-success"},pr_open:{visual:"icon",icon:Ze,className:"text-info"},pr_merged:{visual:"icon",icon:ha,className:"text-purple-500"}};function Ta(r){switch(r){case"failed":return o.workspace_statusIcon_failed_label();case"blocked":return o.workspace_statusIcon_blocked_label();case"needs_attention":return o.workspace_statusIcon_needsAttention_label();case"in_progress":return o.workspace_statusIcon_inProgress_label();case"waiting":return o.workspace_taskStatus_waiting_label();case"unread":return o.layout_activeCard_unread_header();case"not_started":return o.workspace_statusIcon_notStarted_label();case"idle":return o.workspace_statusIcon_idle_label();case"complete":return o.workspace_statusIcon_complete_label();case"pr_queued":return o.workspace_statusIcon_prQueued_label();case"pr_ready":return o.workspace_statusIcon_prReady_label();case"pr_open":return o.workspace_statusIcon_prOpen_label();case"pr_merged":return o.workspace_statusIcon_prMerged_label()}}function Oa(r){const n=ut(r.displayStatus)?r.displayStatus:"not_started";return Na.has(n)?n:r.attention==="unread"?"unread":r.waiting===!0?"waiting":n}function pt(r){const n=r==="waiting"||r==="unread"||ut(r)?r:"not_started",b=Ta(n);return{state:n,...Wa[n],label:b,tooltip:b,accessibleName:b}}var Ea=S('<span class="workspace-status-dot svelte-14zk5l0" data-workspace-status-dot=""></span>'),Da=S("<span><!></span>");function vt(r,n){if(new.target)return st({component:vt,...r});it(n,!0);let b=K(n,"status",7),m=K(n,"size",7,14),w=K(n,"decorative",7,!1),u=K(n,"class",7);const i=k(()=>pt(b()));var a={get status(){return b()},set status(_){b(_),H()},get size(){return m()},set size(_=14){m(_),H()},get decorative(){return w()},set decorative(_=!1){w(_),H()},get class(){return u()},set class(_){u(_),H()},$set:nt,$on:(_,G)=>ot(n,_,G)},p=Da(),re=f(p);{var se=_=>{var G=Ea();y(_,G)},ne=_=>{fe(_,{get icon(){return t(i).icon},class:"size-full!"})};$(re,_=>{t(i).visual==="dot"?_(se):t(i).icon&&_(ne,1)})}return v(p),T(_=>{lt(p,1,_,"svelte-14zk5l0"),Jt(p,`width: ${m()??""}px; height: ${m()??""}px;`),x(p,"role",w()?void 0:"img"),x(p,"aria-label",w()?void 0:t(i).accessibleName),x(p,"aria-hidden",w()?"true":void 0),x(p,"title",w()?void 0:t(i).tooltip),x(p,"data-workspace-status",t(i).state),x(p,"data-workspace-status-visual",t(i).visual),x(p,"data-workspace-status-icon",t(i).icon?.iconName)},[()=>Qt(Xt("workspace-status-icon inline-flex shrink-0 items-center justify-center forced-colors:text-[CanvasText]",t(i).className,u()))]),y(r,p),ct(a)}const Me=6e4,Ne=60*Me,We=24*Ne,tt=30*We;function La(r,n=new Date){if(r==null)return null;const b=r instanceof Date?r:new Date(r),m=b.getTime(),w=n.getTime();if(!Number.isFinite(m)||!Number.isFinite(w))return null;const u=Math.max(0,w-m);let i;u<Me?i="<1m":u<Ne?i=`${B(Math.floor(u/Me))}m`:u<We?i=`${B(Math.floor(u/Ne))}h`:u<tt?i=`${B(Math.floor(u/We))}d`:i=`${B(Math.floor(u/tt))}mo`;const a=m>w?n:b,p=da(a,{now:n});return p?{compact:i,accessible:p,dateTime:b.toISOString()}:null}var $a=S('<div><div class="grid gap-0.5 px-5 pt-4"><div class="flex min-w-0 items-center justify-between gap-3"><!> <!></div> <!> <!></div> <div class="my-3 border-t border-border" data-workspace-hover-card-divider=""></div> <div class="body-grid grid min-w-0 grid-cols-1 items-stretch gap-3 px-5 pb-4" data-workspace-hover-card-columns=""><div class="grid" data-workspace-hover-card-activity=""><!></div> <div class="pull-requests grid" data-workspace-hover-card-pr-column=""><!></div></div></div>'),Ka=S('<p class="type-caption mt-1 min-w-0 line-clamp-3 text-muted-foreground" data-workspace-hover-card-summary=""> </p>'),Ha=S('<span class="shrink-0 text-muted-foreground" data-workspace-hover-card-question-meta=""><span aria-hidden="true"> </span></span>'),Ba=S('<span class="row-span-2 flex h-(--text-caption-line-height) items-center" aria-hidden="true"><!></span><span class="type-caption min-w-0 truncate text-foreground" data-workspace-hover-card-agent-name=""> </span><time class="type-caption whitespace-nowrap text-muted-foreground" data-workspace-hover-card-agent-time=""> </time> <span class="agent-detail type-caption flex min-w-0 items-start gap-1.5 text-muted-foreground svelte-1vax087" data-workspace-hover-card-agent-detail=""><span class="min-w-0 truncate" data-workspace-hover-card-agent-context=""> </span><!></span>',1),at=S('<div role="listitem"><!></div>'),za=S('<div class="type-caption mt-3 flex items-center justify-between text-muted-foreground" data-workspace-hover-card-overflow=""><span> </span> <!></div>'),ja=S('<section class="activity min-w-0" data-workspace-hover-card-activity="" data-workspace-hover-card-agent-table=""><div class="-mx-2 grid gap-2" role="list"></div> <!></section>'),Fa=S('<!> <span class="type-caption min-w-0 truncate text-foreground" data-workspace-hover-card-pr-title=""> </span> <span class="type-caption shrink-0 text-muted-foreground" data-workspace-hover-card-pr-status=""> </span> <span class="type-caption shrink-0 text-muted-foreground" data-workspace-hover-card-pr-number=""> </span>',1),Ua=S('<div class="grid w-full min-w-0 grid-cols-[1rem_minmax(0,1fr)_auto_auto] items-center gap-x-2 rounded-sm px-2 py-0 text-left" data-workspace-hover-card-pr-row=""><!></div>'),Va=S('<div class="type-caption mt-3 flex items-center justify-between text-muted-foreground" data-workspace-hover-card-pr-overflow=""><span> </span> <!></div>'),Ya=S('<section class="pull-requests min-w-0" data-workspace-hover-card-pr-column=""><div class="-mx-2 grid min-w-0 gap-2" role="list" data-workspace-hover-card-pr-list=""></div> <!></section>'),Ga=S('<div class="my-3 border-t border-border" data-workspace-hover-card-divider=""></div> <div class="body-grid grid min-w-0 grid-cols-1 items-stretch gap-3 px-5 pb-4" data-workspace-hover-card-columns=""><!> <!></div>',1),Qa=S('<header data-workspace-hover-card-header=""><div class="min-w-0" data-workspace-hover-card-identity=""><div class="flex min-w-0 items-center justify-between gap-3"><h2 class="type-body min-w-0 truncate font-medium text-foreground" data-workspace-hover-card-title=""> </h2> <span class="type-caption flex shrink-0 items-center gap-1.5 text-muted-foreground" data-workspace-hover-card-status=""><span class="truncate" data-workspace-hover-card-status-label=""> </span><!></span></div> <div class="type-caption mt-0.5 min-w-0 truncate text-muted-foreground" data-workspace-hover-card-repo=""> </div> <!></div></header> <!>',1),Xa=S('<section class="workspace-hover-card shrink-0 overflow-hidden rounded-md bg-background text-left text-foreground shadow-(--elevation-overlay) ring-1 ring-border svelte-1vax087" data-workspace-hover-card="" data-workspace-hover-card-layout="landscape"><!></section>');function Ja(r,n){if(new.target)return st({component:Ja,...r});it(n,!0);const b=()=>Fe(gt,"$workspaceAgents$",w),m=()=>Fe(ft,"$prMonitors$",w),[w,u]=Ft(),i=ba("WorkspaceHoverCard");let a=K(n,"workspace",7),p=K(n,"isLoading",7,!1),re=K(n,"activeAgentIds",23,()=>[]),se=K(n,"loadAgentSessions",7,!0),ne=K(n,"onkeydown",7),_=K(n,"staticData",7,!1);const G=Pe("");function mt(){return _()?Pe([]):Zt(G)}function _t(){return _()?Pe([]):ea(G)}const gt=mt(),ft=_t();Ue(()=>G.set(a()?.id??""));let Te=Gt(0);Vt(()=>Qe.subscribe(()=>Yt(Te)));let wt=k(()=>a()?.agentSummary?.agentIds??[]),Oe=k(()=>(t(Te),a()?Qe.getStreamingAgentIdsForWorkspace(a().id):[])),Ee=null,we=new Set;Ue(()=>{if(!a()||!se())return;const e=String(a().id);Ee!==e&&(Ee=e,we=new Set);for(const c of new Set([...t(wt).slice(0,6),...re(),...t(Oe)]))we.has(c)||(W.dispatch(ua(e,c)),we.add(c))});function bt(e){return[e.name,e.context,e.questionMeta?.accessible,e.updated.accessible].filter(Boolean).join(". ")}function kt(e){return e?e.kind==="attention"?e.attention.reason?.trim()||null:"text"in e&&e.text.trim()||null:null}function ht(e){return La(e.lastActivity||e.updatedAt||e.createdAt)??{compact:"—",accessible:o.workspace_hoverCard_noRecentActivity_label()}}function yt(e){const c=String(e.status).toLowerCase(),l=va(e),h=na(e),D=h==="question"?ia(e):null,I=kt(aa.select(W.state,String(e.id)));let P,z,q,A,O,X,j=!1;if(h==="question"){P="attention",z="question",q=D?.questions[0]?.question.trim()||I||o.workspace_hoverCard_question_label(),A="question",O=1;const de=D?.questions.length??0;de>1&&(X={compact:`${B(1)}/${B(de)}`,accessible:o.chat_questionWizard_stepCounter_label({current:1,total:de})})}else if(h==="attention-discussion")P="attention",z="discussion",q=l?.reason?.trim()||o.chat_agentCard_attentionDiscussion_label(),A="attention-discussion",O=1;else if(h==="attention-blocker"||c==="blocked")P="attention",z="blocker",q=l?.reason?.trim()||o.chat_agentCard_attentionBlocker_label(),A="attention-blocker",O=0;else if(e.hasUnread)P="attention",z="unread",q=I||o.chat_newMessagesDivider_label(),j=!!I,A="unread",O=2;else if(e.isStreaming||e.isProcessing||re().includes(String(e.id))||t(Oe).includes(String(e.id))||["active","busy","processing","responding","running","streaming","in_progress"].includes(c))P="active",q=I||o.workspace_devScripts_running_label(),j=!!I,A=e.isProcessing?"responding":"running",O=3;else if(["waiting","pending","queued","starting"].includes(c))P="waiting",q=I||o.workspace_taskStatus_waiting_label(),j=!!I,A="waiting",O=4;else return null;const ye=e.agentMetadata??e.metadata;return{id:String(e.id),name:e.name?.trim()||o.workspace_fileChanges_agent_label(),group:P,attentionKind:z,avatarState:A,specialist:ye?.specialist,context:q,questionMeta:X,contextIsPreview:j,updated:ht(e),priority:O}}let xt=k(()=>{const e=a()?.agentSummary,c=new Map;if(Array.isArray(e?.agents))for(const l of e.agents)l&&typeof l=="object"&&typeof l.id=="string"&&c.set(l.id,l.parentAgentId);return b().filter(l=>{const h=c.get(String(l.id));return!(pa(l)!=="topLevel"||typeof h=="string"&&h||l.pendingDeleteAt||l.retiredAt||String(l.status).toLowerCase()==="deleted")})}),be=k(()=>t(xt).map(yt).filter(e=>e!==null).sort((e,c)=>e.priority-c.priority)),St=k(()=>t(be).slice(0,6)),De=k(()=>Math.max(0,t(be).length-6)),At=k(()=>a()?.repositoryName?a().repositoryOwner?`${a().repositoryOwner} / ${a().repositoryName}`:a().repositoryName:o.workspace_hoverCard_localRepository_label()),Le=k(()=>Oa(a()??{})),Ct=k(()=>pt(t(Le))),ke=k(()=>a()?.statusMessage?.trim()||"");function $e(e){if(!e)return null;const c=e.activePullRequest??e.pullRequests?.[0]??null;return c||(e.prStatus?{id:`legacy-pr-${e.prNumber??"workspace"}`,number:e.prNumber??0,url:e.prUrl??"",title:o.workspace_hoverCard_pullRequest_label(),status:e.prStatus,createdAt:e.updatedAt,updatedAt:e.updatedAt}:null)}let Rt=k(()=>a()?_()?$e(a()):ra.select(W.state,a().id)??$e(a()):null),Q=k(()=>{if(!a()||ta(a()))return[];const e=a().repositoryOwner&&a().repositoryName?`${a().repositoryOwner}/${a().repositoryName}`:void 0;return Ma({workspacePRs:a().pullRequests,activePR:t(Rt),monitors:m(),workspaceRepo:e,buildPrUrl:(c,l)=>qa(c,a().repositoryOwner,a().repositoryName,l),getDisplayTitle:c=>c.title})}),It=k(()=>t(Q).slice(0,3)),Ke=k(()=>Math.max(0,t(Q).length-3)),He=k(()=>t(be).length>0),Be=k(()=>t(Q).length>0),ze=k(()=>t(He)||t(Be));function je(e){const c=e.resource?.repository.provider==="gitlab"?`${e.repo} !${e.number}`:e.repo?o.workspace_card_prBadge_repoLine_tooltip({repo:e.repo,number:e.number}):o.workspace_card_prBadge_label({number:` #${e.number}`});return[sa(c,e),e.title,e.details].filter(Boolean).join(`
|
|
3
|
-
`)}function Pt(e,c){if(e.stopPropagation(),!a()||!se())return;const l=a().id;Pa.select(W.state)!==l&&ka(l).catch(h=>{i.warn("Failed to switch workspace for hover-card agent",{agentId:c,error:h})}),W.dispatch(ma(l,{agentId:c}))}function qt(e,c){if(e.stopPropagation(),!a()||!c.url)return;const l=a().id;Ut(async()=>{const{handleLink:h}=await import("./
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["/app/immutable/chunks/Nw_03x_O.js","/app/immutable/chunks/Fcr7AvC-.js","/app/immutable/chunks/3SdAC2_C.js","/app/immutable/chunks/BdWqymET.js","/app/immutable/chunks/D0qhIm1r.js","/app/immutable/chunks/Dms_DO28.js","/app/immutable/chunks/ChTqQfQN.js","/app/immutable/chunks/BS1zON0P.js","/app/immutable/chunks/CIyUrgF0.js","/app/immutable/chunks/CWfjuhY2.js","/app/immutable/chunks/DxwfiAWm.js","/app/immutable/chunks/uXuxG9cN.js","/app/immutable/chunks/Bqd7fdCF.js","/app/immutable/chunks/Czp61MqP.js","/app/immutable/chunks/cD292w1o.js","/app/immutable/chunks/CZfU7DE3.js","/app/immutable/chunks/ChHRVjww.js","/app/immutable/chunks/2z64ELW5.js","/app/immutable/chunks/BhYXv0ZM.js","/app/immutable/chunks/BRCr02in.js","/app/immutable/assets/spinner.D_TRo5Hy.css","/app/immutable/chunks/CA6H1-bp.js","/app/immutable/chunks/BAtAwQ72.js","/app/immutable/chunks/TdGvVwuC.js","/app/immutable/assets/button.-yaUNjRS.css","/app/immutable/chunks/BwweojP5.js","/app/immutable/chunks/C7b3vXLD.js","/app/immutable/chunks/CL3a4Hm1.js","/app/immutable/chunks/BBWuirRW.js","/app/immutable/chunks/BeZe2Rt-.js","/app/immutable/chunks/_IjN0Lbt.js","/app/immutable/chunks/CH7HNVC2.js","/app/immutable/chunks/CDCAMh6o.js","/app/immutable/chunks/B5aYN90J.js","/app/immutable/chunks/Ba0ctoXN.js","/app/immutable/chunks/DKwAaLwd.js","/app/immutable/chunks/DkQdSPDN.js","/app/immutable/chunks/Beq_QLuz.js","/app/immutable/chunks/Dn334wJv.js","/app/immutable/chunks/Cc0763mU.js","/app/immutable/chunks/DRMe5Ypb.js","/app/immutable/chunks/D9tVylVS.js","/app/immutable/chunks/CxR-pcVt.js","/app/immutable/chunks/DU3vNstz.js","/app/immutable/chunks/XJv96NUg.js","/app/immutable/assets/notify.DylRFR3N.css"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{bm as o,t as st,bo as K,bw as nt,b as ot,bq as Ft,bs as Fe,_ as Ut}from"./Fcr7AvC-.js";import{bs as it,a5 as f,aD as t,bA as v,b_ as T,W as y,bn as ct,c9 as k,aA as H,aB as S,ca as Ue,bk as Vt,c6 as Yt,cd as Pe,bV as Gt,bS as g,ay as ge,bl as M,bO as N}from"./3SdAC2_C.js";import{i as $}from"./BhYXv0ZM.js";import{e as Ve,g as Ye}from"./CA6H1-bp.js";import{c as Qt,e as Xt,f as lt,g as Jt,s as x}from"./BRCr02in.js";import{a_ as Zt,db as ea,X as ta,aI as aa,dE as ra,a3 as sa,dI as dt}from"./cD292w1o.js";import{t as Ge}from"./DAsc1V4f.js";import{b as na,A as oa}from"./6_Ki4zfU.js";import{p as Qe}from"./Dxxx3b3f.js";import{aN as ia,aK as ca,aL as Xe,a1 as la}from"./BeZe2Rt-.js";import{S as le}from"./D7KhILhs.js";import"./BAtAwQ72.js";import{f as Je}from"./Beq_QLuz.js";import{l as B,n as da}from"./C7b3vXLD.js";import{sd as ut,JH as W,mP as ua,fV as pa,nM as va,v1 as ma,c as _a,wE as ga,tG as fa,rW as wa}from"./D0qhIm1r.js";import{c as ba}from"./ChTqQfQN.js";import{o as ka}from"./Bgy94TB4.js";import{aR as ha,aS as Ze,bC as ya,aB as xa,bB as Sa,aG as Aa,d3 as Ca,cT as Ra,F as fe,ay as et,bK as Ia}from"./ChHRVjww.js";import{selectCurrentWorkspaceTabId as Pa}from"./_IjN0Lbt.js";import{p as qa}from"./fjEL_jqG.js";import{i as Ma}from"./3a2EfPr3.js";const Na=new Set(["failed","blocked","needs_attention","in_progress"]),Wa={failed:{visual:"icon",icon:Ra,className:"text-foreground"},blocked:{visual:"icon",icon:Ca,className:"text-danger"},needs_attention:{visual:"icon",icon:Aa,className:"text-warning-ink"},in_progress:{visual:"dot",icon:null,className:"workspace-status-color-active"},waiting:{visual:"icon",icon:Sa,className:"text-muted-foreground"},unread:{visual:"dot",icon:null,className:"workspace-status-color-unread"},not_started:{visual:"dot",icon:null,className:"text-muted-foreground/35"},idle:{visual:"dot",icon:null,className:"text-muted-foreground/35"},complete:{visual:"icon",icon:xa,className:"text-success"},pr_queued:{visual:"icon",icon:ya,className:"text-info"},pr_ready:{visual:"icon",icon:Ze,className:"text-success"},pr_open:{visual:"icon",icon:Ze,className:"text-info"},pr_merged:{visual:"icon",icon:ha,className:"text-purple-500"}};function Ta(r){switch(r){case"failed":return o.workspace_statusIcon_failed_label();case"blocked":return o.workspace_statusIcon_blocked_label();case"needs_attention":return o.workspace_statusIcon_needsAttention_label();case"in_progress":return o.workspace_statusIcon_inProgress_label();case"waiting":return o.workspace_taskStatus_waiting_label();case"unread":return o.layout_activeCard_unread_header();case"not_started":return o.workspace_statusIcon_notStarted_label();case"idle":return o.workspace_statusIcon_idle_label();case"complete":return o.workspace_statusIcon_complete_label();case"pr_queued":return o.workspace_statusIcon_prQueued_label();case"pr_ready":return o.workspace_statusIcon_prReady_label();case"pr_open":return o.workspace_statusIcon_prOpen_label();case"pr_merged":return o.workspace_statusIcon_prMerged_label()}}function Oa(r){const n=ut(r.displayStatus)?r.displayStatus:"not_started";return Na.has(n)?n:r.attention==="unread"?"unread":r.waiting===!0?"waiting":n}function pt(r){const n=r==="waiting"||r==="unread"||ut(r)?r:"not_started",b=Ta(n);return{state:n,...Wa[n],label:b,tooltip:b,accessibleName:b}}var Ea=S('<span class="workspace-status-dot svelte-14zk5l0" data-workspace-status-dot=""></span>'),Da=S("<span><!></span>");function vt(r,n){if(new.target)return st({component:vt,...r});it(n,!0);let b=K(n,"status",7),m=K(n,"size",7,14),w=K(n,"decorative",7,!1),u=K(n,"class",7);const i=k(()=>pt(b()));var a={get status(){return b()},set status(_){b(_),H()},get size(){return m()},set size(_=14){m(_),H()},get decorative(){return w()},set decorative(_=!1){w(_),H()},get class(){return u()},set class(_){u(_),H()},$set:nt,$on:(_,G)=>ot(n,_,G)},p=Da(),re=f(p);{var se=_=>{var G=Ea();y(_,G)},ne=_=>{fe(_,{get icon(){return t(i).icon},class:"size-full!"})};$(re,_=>{t(i).visual==="dot"?_(se):t(i).icon&&_(ne,1)})}return v(p),T(_=>{lt(p,1,_,"svelte-14zk5l0"),Jt(p,`width: ${m()??""}px; height: ${m()??""}px;`),x(p,"role",w()?void 0:"img"),x(p,"aria-label",w()?void 0:t(i).accessibleName),x(p,"aria-hidden",w()?"true":void 0),x(p,"title",w()?void 0:t(i).tooltip),x(p,"data-workspace-status",t(i).state),x(p,"data-workspace-status-visual",t(i).visual),x(p,"data-workspace-status-icon",t(i).icon?.iconName)},[()=>Qt(Xt("workspace-status-icon inline-flex shrink-0 items-center justify-center forced-colors:text-[CanvasText]",t(i).className,u()))]),y(r,p),ct(a)}const Me=6e4,Ne=60*Me,We=24*Ne,tt=30*We;function La(r,n=new Date){if(r==null)return null;const b=r instanceof Date?r:new Date(r),m=b.getTime(),w=n.getTime();if(!Number.isFinite(m)||!Number.isFinite(w))return null;const u=Math.max(0,w-m);let i;u<Me?i="<1m":u<Ne?i=`${B(Math.floor(u/Me))}m`:u<We?i=`${B(Math.floor(u/Ne))}h`:u<tt?i=`${B(Math.floor(u/We))}d`:i=`${B(Math.floor(u/tt))}mo`;const a=m>w?n:b,p=da(a,{now:n});return p?{compact:i,accessible:p,dateTime:b.toISOString()}:null}var $a=S('<div><div class="grid gap-0.5 px-5 pt-4"><div class="flex min-w-0 items-center justify-between gap-3"><!> <!></div> <!> <!></div> <div class="my-3 border-t border-border" data-workspace-hover-card-divider=""></div> <div class="body-grid grid min-w-0 grid-cols-1 items-stretch gap-3 px-5 pb-4" data-workspace-hover-card-columns=""><div class="grid" data-workspace-hover-card-activity=""><!></div> <div class="pull-requests grid" data-workspace-hover-card-pr-column=""><!></div></div></div>'),Ka=S('<p class="type-caption mt-1 min-w-0 line-clamp-3 text-muted-foreground" data-workspace-hover-card-summary=""> </p>'),Ha=S('<span class="shrink-0 text-muted-foreground" data-workspace-hover-card-question-meta=""><span aria-hidden="true"> </span></span>'),Ba=S('<span class="row-span-2 flex h-(--text-caption-line-height) items-center" aria-hidden="true"><!></span><span class="type-caption min-w-0 truncate text-foreground" data-workspace-hover-card-agent-name=""> </span><time class="type-caption whitespace-nowrap text-muted-foreground" data-workspace-hover-card-agent-time=""> </time> <span class="agent-detail type-caption flex min-w-0 items-start gap-1.5 text-muted-foreground svelte-1vax087" data-workspace-hover-card-agent-detail=""><span class="min-w-0 truncate" data-workspace-hover-card-agent-context=""> </span><!></span>',1),at=S('<div role="listitem"><!></div>'),za=S('<div class="type-caption mt-3 flex items-center justify-between text-muted-foreground" data-workspace-hover-card-overflow=""><span> </span> <!></div>'),ja=S('<section class="activity min-w-0" data-workspace-hover-card-activity="" data-workspace-hover-card-agent-table=""><div class="-mx-2 grid gap-2" role="list"></div> <!></section>'),Fa=S('<!> <span class="type-caption min-w-0 truncate text-foreground" data-workspace-hover-card-pr-title=""> </span> <span class="type-caption shrink-0 text-muted-foreground" data-workspace-hover-card-pr-status=""> </span> <span class="type-caption shrink-0 text-muted-foreground" data-workspace-hover-card-pr-number=""> </span>',1),Ua=S('<div class="grid w-full min-w-0 grid-cols-[1rem_minmax(0,1fr)_auto_auto] items-center gap-x-2 rounded-sm px-2 py-0 text-left" data-workspace-hover-card-pr-row=""><!></div>'),Va=S('<div class="type-caption mt-3 flex items-center justify-between text-muted-foreground" data-workspace-hover-card-pr-overflow=""><span> </span> <!></div>'),Ya=S('<section class="pull-requests min-w-0" data-workspace-hover-card-pr-column=""><div class="-mx-2 grid min-w-0 gap-2" role="list" data-workspace-hover-card-pr-list=""></div> <!></section>'),Ga=S('<div class="my-3 border-t border-border" data-workspace-hover-card-divider=""></div> <div class="body-grid grid min-w-0 grid-cols-1 items-stretch gap-3 px-5 pb-4" data-workspace-hover-card-columns=""><!> <!></div>',1),Qa=S('<header data-workspace-hover-card-header=""><div class="min-w-0" data-workspace-hover-card-identity=""><div class="flex min-w-0 items-center justify-between gap-3"><h2 class="type-body min-w-0 truncate font-medium text-foreground" data-workspace-hover-card-title=""> </h2> <span class="type-caption flex shrink-0 items-center gap-1.5 text-muted-foreground" data-workspace-hover-card-status=""><span class="truncate" data-workspace-hover-card-status-label=""> </span><!></span></div> <div class="type-caption mt-0.5 min-w-0 truncate text-muted-foreground" data-workspace-hover-card-repo=""> </div> <!></div></header> <!>',1),Xa=S('<section class="workspace-hover-card shrink-0 overflow-hidden rounded-md bg-background text-left text-foreground shadow-(--elevation-overlay) ring-1 ring-border svelte-1vax087" data-workspace-hover-card="" data-workspace-hover-card-layout="landscape"><!></section>');function Ja(r,n){if(new.target)return st({component:Ja,...r});it(n,!0);const b=()=>Fe(gt,"$workspaceAgents$",w),m=()=>Fe(ft,"$prMonitors$",w),[w,u]=Ft(),i=ba("WorkspaceHoverCard");let a=K(n,"workspace",7),p=K(n,"isLoading",7,!1),re=K(n,"activeAgentIds",23,()=>[]),se=K(n,"loadAgentSessions",7,!0),ne=K(n,"onkeydown",7),_=K(n,"staticData",7,!1);const G=Pe("");function mt(){return _()?Pe([]):Zt(G)}function _t(){return _()?Pe([]):ea(G)}const gt=mt(),ft=_t();Ue(()=>G.set(a()?.id??""));let Te=Gt(0);Vt(()=>Qe.subscribe(()=>Yt(Te)));let wt=k(()=>a()?.agentSummary?.agentIds??[]),Oe=k(()=>(t(Te),a()?Qe.getStreamingAgentIdsForWorkspace(a().id):[])),Ee=null,we=new Set;Ue(()=>{if(!a()||!se())return;const e=String(a().id);Ee!==e&&(Ee=e,we=new Set);for(const c of new Set([...t(wt).slice(0,6),...re(),...t(Oe)]))we.has(c)||(W.dispatch(ua(e,c)),we.add(c))});function bt(e){return[e.name,e.context,e.questionMeta?.accessible,e.updated.accessible].filter(Boolean).join(". ")}function kt(e){return e?e.kind==="attention"?e.attention.reason?.trim()||null:"text"in e&&e.text.trim()||null:null}function ht(e){return La(e.lastActivity||e.updatedAt||e.createdAt)??{compact:"—",accessible:o.workspace_hoverCard_noRecentActivity_label()}}function yt(e){const c=String(e.status).toLowerCase(),l=va(e),h=na(e),D=h==="question"?ia(e):null,I=kt(aa.select(W.state,String(e.id)));let P,z,q,A,O,X,j=!1;if(h==="question"){P="attention",z="question",q=D?.questions[0]?.question.trim()||I||o.workspace_hoverCard_question_label(),A="question",O=1;const de=D?.questions.length??0;de>1&&(X={compact:`${B(1)}/${B(de)}`,accessible:o.chat_questionWizard_stepCounter_label({current:1,total:de})})}else if(h==="attention-discussion")P="attention",z="discussion",q=l?.reason?.trim()||o.chat_agentCard_attentionDiscussion_label(),A="attention-discussion",O=1;else if(h==="attention-blocker"||c==="blocked")P="attention",z="blocker",q=l?.reason?.trim()||o.chat_agentCard_attentionBlocker_label(),A="attention-blocker",O=0;else if(e.hasUnread)P="attention",z="unread",q=I||o.chat_newMessagesDivider_label(),j=!!I,A="unread",O=2;else if(e.isStreaming||e.isProcessing||re().includes(String(e.id))||t(Oe).includes(String(e.id))||["active","busy","processing","responding","running","streaming","in_progress"].includes(c))P="active",q=I||o.workspace_devScripts_running_label(),j=!!I,A=e.isProcessing?"responding":"running",O=3;else if(["waiting","pending","queued","starting"].includes(c))P="waiting",q=I||o.workspace_taskStatus_waiting_label(),j=!!I,A="waiting",O=4;else return null;const ye=e.agentMetadata??e.metadata;return{id:String(e.id),name:e.name?.trim()||o.workspace_fileChanges_agent_label(),group:P,attentionKind:z,avatarState:A,specialist:ye?.specialist,context:q,questionMeta:X,contextIsPreview:j,updated:ht(e),priority:O}}let xt=k(()=>{const e=a()?.agentSummary,c=new Map;if(Array.isArray(e?.agents))for(const l of e.agents)l&&typeof l=="object"&&typeof l.id=="string"&&c.set(l.id,l.parentAgentId);return b().filter(l=>{const h=c.get(String(l.id));return!(pa(l)!=="topLevel"||typeof h=="string"&&h||l.pendingDeleteAt||l.retiredAt||String(l.status).toLowerCase()==="deleted")})}),be=k(()=>t(xt).map(yt).filter(e=>e!==null).sort((e,c)=>e.priority-c.priority)),St=k(()=>t(be).slice(0,6)),De=k(()=>Math.max(0,t(be).length-6)),At=k(()=>a()?.repositoryName?a().repositoryOwner?`${a().repositoryOwner} / ${a().repositoryName}`:a().repositoryName:o.workspace_hoverCard_localRepository_label()),Le=k(()=>Oa(a()??{})),Ct=k(()=>pt(t(Le))),ke=k(()=>a()?.statusMessage?.trim()||"");function $e(e){if(!e)return null;const c=e.activePullRequest??e.pullRequests?.[0]??null;return c||(e.prStatus?{id:`legacy-pr-${e.prNumber??"workspace"}`,number:e.prNumber??0,url:e.prUrl??"",title:o.workspace_hoverCard_pullRequest_label(),status:e.prStatus,createdAt:e.updatedAt,updatedAt:e.updatedAt}:null)}let Rt=k(()=>a()?_()?$e(a()):ra.select(W.state,a().id)??$e(a()):null),Q=k(()=>{if(!a()||ta(a()))return[];const e=a().repositoryOwner&&a().repositoryName?`${a().repositoryOwner}/${a().repositoryName}`:void 0;return Ma({workspacePRs:a().pullRequests,activePR:t(Rt),monitors:m(),workspaceRepo:e,buildPrUrl:(c,l)=>qa(c,a().repositoryOwner,a().repositoryName,l),getDisplayTitle:c=>c.title})}),It=k(()=>t(Q).slice(0,3)),Ke=k(()=>Math.max(0,t(Q).length-3)),He=k(()=>t(be).length>0),Be=k(()=>t(Q).length>0),ze=k(()=>t(He)||t(Be));function je(e){const c=e.resource?.repository.provider==="gitlab"?`${e.repo} !${e.number}`:e.repo?o.workspace_card_prBadge_repoLine_tooltip({repo:e.repo,number:e.number}):o.workspace_card_prBadge_label({number:` #${e.number}`});return[sa(c,e),e.title,e.details].filter(Boolean).join(`
|
|
3
|
+
`)}function Pt(e,c){if(e.stopPropagation(),!a()||!se())return;const l=a().id;Pa.select(W.state)!==l&&ka(l).catch(h=>{i.warn("Failed to switch workspace for hover-card agent",{agentId:c,error:h})}),W.dispatch(ma(l,{agentId:c}))}function qt(e,c){if(e.stopPropagation(),!a()||!c.url)return;const l=a().id;Ut(async()=>{const{handleLink:h}=await import("./Nw_03x_O.js").then(D=>D.l);return{handleLink:h}},__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45]),import.meta.url).then(({handleLink:h})=>h(c.url,{workspaceId:l,event:e}))}var Mt={get workspace(){return a()},set workspace(e){a(e),H()},get isLoading(){return p()},set isLoading(e=!1){p(e),H()},get activeAgentIds(){return re()},set activeAgentIds(e=[]){re(e),H()},get loadAgentSessions(){return se()},set loadAgentSessions(e=!0){se(e),H()},get onkeydown(){return ne()},set onkeydown(e){ne(e),H()},get staticData(){return _()},set staticData(e=!1){_(e),H()},$set:nt,$on:(e,c)=>ot(n,e,c)},he=Xa(),Nt=f(he);{var Wt=e=>{var c=$a(),l=f(c),h=f(l),D=f(h);le(D,{class:"h-7 min-w-0 max-w-64 flex-1"});var I=g(D,2);le(I,{class:"h-5 w-20 shrink-0"}),v(h);var P=g(h,2);le(P,{class:"h-4 w-40"});var z=g(P,2);le(z,{class:"mt-2 h-10 w-full"}),v(l);var q=g(l,4),A=f(q),O=f(A);le(O,{class:"h-10 w-full"}),v(A);var X=g(A,2),j=f(X);le(j,{class:"h-10 w-full"}),v(X),v(q),v(c),y(e,c)},Tt=e=>{var c=Qa(),l=ge(c);let h;var D=f(l),I=f(D),P=f(I),z=M(P,!0),q=g(P,2),A=f(q),O=M(A,!0),X=g(A);vt(X,{get status(){return t(Le)},size:16,decorative:!0}),v(q),v(I);var j=g(I,2),ye=M(j,!0),de=g(j,2);{var Et=F=>{var oe=Ka(),me=M(oe,!0);Ve(oe,(_e,xe)=>Ge?.(_e,xe),()=>t(ke)),T(()=>N(me,t(ke))),y(F,oe)};$(de,F=>{t(ke)&&F(Et)})}v(D),v(l);var Dt=g(l,2);{var Lt=F=>{var oe=Ga(),me=g(ge(oe),2),_e=f(me);{var xe=J=>{var U=ja(),Y=f(U);Ye(Y,21,()=>t(St),d=>d.id,(d,s)=>{var C=at(),Z=f(C);{let ee=k(()=>bt(t(s)));Je(Z,{variant:"plain",wrapContent:!1,class:"grid h-auto! min-h-8 w-full min-w-0 cursor-pointer grid-cols-[1rem_minmax(0,1fr)_auto] items-start justify-normal gap-x-2 gap-y-0 whitespace-normal rounded-sm border-0! px-2! py-0! text-left font-normal transition-colors hover:bg-muted/50 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring",get"aria-label"(){return t(ee)},"data-workspace-hover-card-agent-row":!0,get"data-agent-group-row"(){return t(s).group},get"data-attention-kind"(){return t(s).attentionKind},get onkeydown(){return ne()},onclick:V=>Pt(V,t(s).id),children:(V,ue)=>{var E=Ba(),R=ge(E),L=f(R);{let ae=k(()=>t(s).specialist??null);oa(L,{get agentId(){return t(s).id},variant:"compact",get state(){return t(s).avatarState},get specialist(){return t(ae)}})}v(R);var ie=g(R),Ce=M(ie,!0),te=g(ie),Re=M(te,!0),pe=g(te,2),ve=f(pe),Ie=M(ve,!0);Ve(ve,(ae,ce)=>Ge?.(ae,ce),()=>t(s).context);var Ht=g(ve);{var Bt=ae=>{var ce=Ha(),zt=f(ce),jt=M(zt,!0);v(ce),T(()=>{x(ce,"aria-label",t(s).questionMeta.accessible),N(jt,t(s).questionMeta.compact)}),y(ae,ce)};$(Ht,ae=>{t(s).questionMeta&&ae(Bt)})}v(pe),T(()=>{N(Ce,t(s).name),x(te,"datetime",t(s).updated.dateTime),x(te,"aria-label",t(s).updated.accessible),N(Re,t(s).updated.compact),x(pe,"data-workspace-hover-card-agent-preview",t(s).contextIsPreview||void 0),N(Ie,t(s).context)}),y(V,E)},$$slots:{default:!0}})}v(C),y(d,C)}),v(Y);var Se=g(Y,2);{var Ae=d=>{var s=za(),C=f(s),Z=M(C,!0),ee=g(C,2);fe(ee,{get icon(){return et},size:10}),v(s),T(V=>N(Z,V),[()=>o.workspace_hoverCard_moreAgents_label({count:B(t(De))})]),y(d,s)};$(Se,d=>{t(De)&&d(Ae)})}v(U),T(d=>x(U,"aria-label",d),[()=>o.workspace_multiSelectSidebar_agentsTab_label()]),y(J,U)};$(_e,J=>{t(He)&&J(xe)})}var $t=g(_e,2);{var Kt=J=>{var U=Ya(),Y=f(U);Ye(Y,21,()=>t(It),d=>d.identity,(d,s)=>{var C=at();{const ue=E=>{var R=Fa(),L=ge(R);fe(L,{get icon(){return t(s).statusIcon},size:16,get class(){return`shrink-0 justify-self-start ${t(s).foregroundClass??""}`}});var ie=g(L,2),Ce=M(ie,!0),te=g(ie,2),Re=M(te,!0),pe=g(te,2),ve=M(pe,!0);T(Ie=>{N(Ce,Ie),N(Re,t(s).accessibleStateLabel),N(ve,t(s).numberLabel??`#${t(s).number}`)},[()=>t(s).title||(t(s).resource?.repository.provider==="gitlab"?o.workspace_hoverCard_mergeRequest_label():o.workspace_hoverCard_pullRequest_label())]),y(E,R)};var Z=f(C);{var ee=E=>{{let R=k(()=>je(t(s)));Je(E,{variant:"plain",wrapContent:!1,class:"grid h-auto! w-full min-w-0 grid-cols-[1rem_minmax(0,1fr)_auto_auto] items-center justify-normal gap-x-2 whitespace-normal rounded-sm border-0! px-2! py-0! text-left font-normal transition-colors hover:bg-muted/50 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring",get"aria-label"(){return t(R)},"data-workspace-hover-card-pr-row":!0,get"data-pr-identity"(){return t(s).identity},get"data-pr-status"(){return t(s).status},get onkeydown(){return ne()},onclick:L=>qt(L,t(s)),children:(L,ie)=>{ue(L)},$$slots:{default:!0}})}},V=E=>{var R=Ua(),L=f(R);ue(L),v(R),T(()=>{x(R,"data-pr-identity",t(s).identity),x(R,"data-pr-status",t(s).status)}),y(E,R)};$(Z,E=>{t(s).url?E(ee):E(V,-1)})}v(C)}T(ue=>x(C,"aria-label",ue),[()=>t(s).url?void 0:je(t(s))]),y(d,C)}),v(Y);var Se=g(Y,2);{var Ae=d=>{var s=Va(),C=f(s),Z=M(C,!0),ee=g(C,2);fe(ee,{get icon(){return et},size:10}),v(s),T(V=>N(Z,V),[()=>o.workspace_hoverCard_moreItems_label({count:B(t(Ke))})]),y(d,s)};$(Se,d=>{t(Ke)&&d(Ae)})}v(U),T((d,s)=>{x(U,"aria-label",d),x(Y,"aria-label",s)},[()=>t(Q).every(d=>d.resource?.repository.provider==="gitlab")?o.workspace_hoverCard_mergeRequests_label():t(Q).some(d=>d.resource?.repository.provider==="gitlab")?o.workspace_hoverCard_reviews_label():o.workspace_hoverCard_pullRequests_label(),()=>t(Q).every(d=>d.resource?.repository.provider==="gitlab")?o.workspace_hoverCard_mergeRequests_label():t(Q).some(d=>d.resource?.repository.provider==="gitlab")?o.workspace_hoverCard_reviews_label():o.workspace_hoverCard_pullRequests_label()]),y(J,U)};$($t,J=>{t(Be)&&J(Kt)})}v(me),y(F,oe)};$(Dt,F=>{t(ze)&&F(Lt)})}T(F=>{h=lt(l,1,"min-w-0 px-5 pt-4",null,h,{"pb-4":!t(ze)}),N(z,F),N(O,t(Ct).label),N(ye,t(At))},[()=>a().title||o.workspace_links_untitled_label()]),y(e,c)};$(Nt,e=>{p()||!a()?e(Wt):e(Tt,-1)})}v(he),y(r,he);var Ot=ct(Mt);return u(),Ot}const rt=800,xr=175,Za=300;function er(){let r=0,n=null;const b=new Set,m=new Set;function w(){return r>0||n!==null?0:rt}function u(){const a=w();b.forEach(p=>p(a))}function i(){n!==null&&(clearTimeout(n),n=null)}return{get currentOpenDelay(){return w()},subscribe(a){return b.add(a),a(w()),()=>b.delete(a)},notifyOpened(){const a=r===0&&n===null;i(),r+=1,a&&u()},notifyClosed(){r!==0&&(r-=1,!(r>0)&&(i(),n=setTimeout(()=>{n=null,u()},Za)))},deferClose(a){return m.add(a),()=>m.delete(a)},settleDeferredCloses(){const a=[...m];m.clear(),a.forEach(p=>p())},reset(){const a=w()!==rt;i(),r=0,m.clear(),a&&u()}}}const Sr=er();function qe(r){const n=dt.select(W.state,r);return n!==void 0&&wa(n)}function tr(r,n){if(!qe(r))return[];const b=ca.select(W.state,r),m=Xe.select(W.state,r),w=la.select(W.state),u=[];for(let i=0;i<_a;i+=1){const a=w[i],p=a&&a!==r?dt.select(W.state,a):void 0;u.push({id:`assign-micro-key-${i+1}`,label:p?o.workspace_card_assignOccupiedMicroKey_label({number:B(i+1),title:p.title}):o.workspace_card_assignMicroKeyNumber_label({number:B(i+1)}),checked:b===i,closeOnSelect:!0,onClick:()=>{qe(r)&&W.dispatch(ga(i,r)),n()}})}return m!==null&&(u.push({type:"separator"}),u.push({id:"unassign-micro-key",label:o.workspace_card_unassignMicroKey_label(),onClick:()=>{qe(r)&&Xe.select(W.state,r)===m&&W.dispatch(fa(m)),n()}})),u}function Ar(r,{connected:n,onClose:b}){if(!n)return[];const m=tr(r,b);if(m.length===0)return[];const w=m.filter(i=>"id"in i&&i.id!=="unassign-micro-key"),u=m.find(i=>"id"in i&&i.id==="unassign-micro-key");return[{id:"assign-micro-key",label:o.workspace_card_assignMicroKey_label(),icon:Ia,onClick:()=>{},selection:"single",submenu:w},...u?[u]:[]]}export{xr as W,rt as a,Ja as b,vt as c,tr as d,Ar as e,pt as g,Oa as r,Sr as w};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{D as C}from"./
|
|
1
|
+
import{D as C}from"./fjEL_jqG.js";import{t as re,bo as y,bw as se,b as ae,bm as I}from"./Fcr7AvC-.js";import{bs as ne,cb as oe,c5 as ie,bH as k,aD as b,a5 as G,bA as W,b_ as R,W as E,bn as le,bV as q,c9 as F,aA as x,ay as H,bl as N,bS as L,bO as O,a7 as ce,aB as P}from"./3SdAC2_C.js";import{i as de}from"./BhYXv0ZM.js";import{k as me}from"./Cc0763mU.js";import{s as D}from"./BRCr02in.js";import{a as ue}from"./BOi9rcQa.js";const K=C.shape.model,pe=C.shape.states.unwrap().element;function U(t){return typeof t=="object"&&t!==null&&!Array.isArray(t)}function fe(t){return/^(?:|model|model\.(?:nodes|edges|groups)|states)$/.test(t)}function ge(t){let e=0;const s=()=>{for(;/[\t\n\r ]/.test(t[e]??"\0");)e+=1},a=(l,d)=>{if(d>64)throw new Error("JSON nesting limit exceeded");s();const f=e,m=t[e];if(m===void 0)return{complete:!1};if(m==='"'){for(e+=1;e<t.length;){const r=t[e++];if(r==="\\")e+=1;else if(r==='"')return{value:JSON.parse(t.slice(f,e)),complete:!0}}return{complete:!1}}if(m==="{"||m==="["){const r=m==="{",c=r?Object.create(null):[],h=r?"}":"]";if(e+=1,s(),t[e]===h)return e+=1,{value:c,complete:!0};for(;e<t.length;){let i="";if(r){if(t[e]!=='"')throw new Error("Expected JSON property");const _=a(l,d+1);if(!_.complete)return{value:c,complete:!1};if(i=_.value,s(),e===t.length)return{value:c,complete:!1};if(t[e++]!==":")throw new Error("Expected JSON colon")}const g=r?l?`${l}.${i}`:i:`${l}[]`,v=a(g,d+1);if((v.complete||fe(g)&&v.value!==void 0)&&(Array.isArray(c)?c.push(v.value):c[i]=v.value),!v.complete)return{value:c,complete:!1};if(s(),e===t.length)return{value:c,complete:!1};if(t[e]===h)return e+=1,{value:c,complete:!0};if(t[e++]!==",")throw new Error("Expected JSON separator");s()}return{value:c,complete:!1}}for(;e<t.length&&!/[\t\n\r ,}\]]/.test(t[e]);)e+=1;return e===t.length?{complete:!1}:{value:JSON.parse(t.slice(f,e)),complete:!0}},n=a("",0);if(s(),n.complete&&e!==t.length)throw new Error("Unexpected JSON suffix");return n}function J(t){const e=new Set;return t.filter(({id:s})=>e.has(s)?!1:(e.add(s),!0))}function z(t,e,s,a){return[t.visibleNodes,t.highlightedNodes].every(n=>n?.every(l=>e.has(l))??!0)&&[t.visibleEdges,t.highlightedEdges].every(n=>n?.every(l=>s.has(l))??!0)&&(t.visibleGroups?.every(n=>a.has(n))??!0)&&(t.camera?.focus===void 0||e.has(t.camera.focus))}function ve(t){if(!U(t)||!U(t.model))return null;const e=t.model,s=(i,g)=>Array.isArray(i)?i.filter(v=>g.safeParse(v).success):[];let a=J(s(e.nodes,K.shape.nodes.element)),n=J(s(e.groups,K.shape.groups.unwrap().element)),l=!0;for(;l;){const i=new Set(a.map(({id:u})=>u)),g=n.filter(u=>u.nodeIds.every(A=>i.has(A))),v=new Set(g.map(({id:u})=>u)),_=a.filter(u=>u.group===void 0||v.has(u.group));l=_.length!==a.length||g.length!==n.length,a=_,n=g}if(!a.length)return null;const d=new Set(a.map(({id:i})=>i)),f=J(s(e.edges,K.shape.edges.element)).filter(i=>d.has(i.from)&&d.has(i.to)),m=new Set(f.map(({id:i})=>i)),r=new Set(n.map(({id:i})=>i)),c=J(s(t.states,pe)).filter(i=>z(i,d,m,r)),h={...t,model:{...e,nodes:a,edges:f,...e.groups===void 0?{}:{groups:n}},...t.states===void 0?{}:{states:c}};return c.some(i=>i.id===h.currentStateId)||delete h.currentStateId,C.safeParse(h).success?h:null}function V(t){if(!C.safeParse(t).success)return null;const e=t,{nodes:s,edges:a,groups:n=[]}=e.model,l=e.states??[],d=new Set(s.map(({id:r})=>r)),f=new Set(a.map(({id:r})=>r)),m=new Set(n.map(({id:r})=>r));return[s,a,n,l].some(r=>new Set(r.map(({id:c})=>c)).size!==r.length)||s.some(r=>r.group!==void 0&&!m.has(r.group))||a.some(r=>!d.has(r.from)||!d.has(r.to))||n.some(r=>r.nodeIds.some(c=>!d.has(c)))||l.some(r=>!z(r,d,f,m))||e.currentStateId!==void 0&&!l.some(r=>r.id===e.currentStateId)?null:e}function Oe(t,e=!1){const s=(a,n,l)=>({rawSource:t,status:a,diagram:n,...l?{error:l}:{}});try{if(e){const n=V(JSON.parse(t));return n?s("complete",n):s("invalid",null,"Invalid diagram payload")}const a=ge(t);if(a.complete){const n=V(a.value);if(n)return s("complete",n)}return s("partial",ve(a.value))}catch{return s(e?"invalid":"partial",null,e?"Invalid diagram JSON":void 0)}}var he=P('<div class="diagram-feedback svelte-p097sp" role="alert"><strong> </strong> <span> </span></div> <pre class="diagram-source svelte-p097sp"> </pre>',1),we=P('<div class="diagram-feedback svelte-p097sp" role="status"> </div>'),Se=P('<div class="streaming-diagram svelte-p097sp"><!></div>');function _e(t,e){if(new.target)return re({component:_e,...t});ne(e,!0);let s=y(e,"diagram",7),a=y(e,"isStreaming",7,!1),n=y(e,"source",7),l=y(e,"sourceError",7),d=y(e,"viewResetKey",7),f=y(e,"onBindingClick",7),m=q(null),r=q(0),c="",h,i=!1;oe(()=>{const o=s(),p=n(),w=d(),S=a(),B=!!l();ie(()=>{i&&(w!==h||!p.startsWith(c))&&(k(m,null),k(r,b(r)+1)),i=!0,c=p,h=w,B||!S&&!o?k(m,null):o&&k(m,o,!0)})});const g=F(()=>l()?null:s()??(a()?b(m):null)),v=F(()=>!!l()||!a()&&!s());var _={get diagram(){return s()},set diagram(o){s(o),x()},get isStreaming(){return a()},set isStreaming(o=!1){a(o),x()},get source(){return n()},set source(o){n(o),x()},get sourceError(){return l()},set sourceError(o){l(o),x()},get viewResetKey(){return d()},set viewResetKey(o){d(o),x()},get onBindingClick(){return f()},set onBindingClick(o){f(o),x()},$set:se,$on:(o,p)=>ae(e,o,p)},u=Se(),A=G(u);{var M=o=>{var p=he(),w=H(p),S=G(w),B=N(S,!0),X=L(S,2),Y=N(X,!0);W(w);var j=L(w,2),Z=N(j,!0);R(($,ee,te)=>{O(B,$),O(Y,ee),D(j,"aria-label",te),O(Z,n())},[()=>I.markdown_mermaid_renderFailed_error(),()=>I.diagram_renderer_error_description(),()=>I.markdown_mermaid_viewSource_label()]),E(o,p)},Q=o=>{var p=ce(),w=H(p);me(w,()=>b(r),S=>{ue(S,{get diagram(){return b(g)},editable:!1,get viewResetKey(){return d()},get onBindingClick(){return f()}})}),E(o,p)},T=o=>{var p=we(),w=N(p,!0);R(S=>O(w,S),[()=>I.ui_spinner_loading_ariaLabel()]),E(o,p)};de(A,o=>{b(v)?o(M):b(g)?o(Q,1):o(T,-1)})}return W(u),R(()=>{D(u,"aria-busy",a()),D(u,"data-diagram-streaming",a())}),E(t,u),le(_)}export{_e as S,Oe as p};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var cQ=Object.defineProperty;var NB=Q=>{throw TypeError(Q)};var LQ=(Q,A,B)=>A in Q?cQ(Q,A,{enumerable:!0,configurable:!0,writable:!0,value:B}):Q[A]=B;var x=(Q,A,B)=>LQ(Q,typeof A!="symbol"?A+"":A,B),CB=(Q,A,B)=>A.has(Q)||NB("Cannot "+B);var g=(Q,A,B)=>(CB(Q,A,"read from private field"),B?B.call(Q):A.get(Q)),c=(Q,A,B)=>A.has(Q)?NB("Cannot add the same private member more than once"):A instanceof WeakSet?A.add(Q):A.set(Q,B),M=(Q,A,B,E)=>(CB(Q,A,"write to private field"),E?E.call(Q,B):A.set(Q,B),B),D=(Q,A,B)=>(CB(Q,A,"access private method"),B);var HB=(Q,A,B,E)=>({set _(I){M(Q,A,I,B)},get _(){return g(Q,A,E)}});import{a3 as tQ,r as hQ,Q as jQ}from"./DauNjtnc.js";import{B as oQ,D as YQ}from"./C_YUZdUd.js";const T=["none","attribute","attribute.jsx","boolean","comment","comment.doc","constant","constant.builtin","constructor","diff.minus","diff.plus","embedded","emphasis","emphasis.strong","function","function.definition","function.method","keyword","keyword.control","keyword.declaration","keyword.import","keyword.operator","label","namespace","number","operator","predictive","preproc","primary","property","property.json_key","punctuation","punctuation.bracket","punctuation.bracket.html","punctuation.bracket.jsx","punctuation.delimiter","punctuation.delimiter.html","punctuation.delimiter.jsx","punctuation.list_marker","punctuation.markup","punctuation.special","selector","selector.class","selector.id","string","string.escape","string.regex","string.special","string.special.symbol","tag","tag.doctype","tag.jsx","text.jsx","text.literal","title","type","type.builtin","type.class","variable","variable.parameter","variable.special","enum","hint","keyword.jsdoc","link_text","link_uri","selector.pseudo","tag.component.jsx","type.jsdoc","variable.jsdoc","variant","background","foreground"],aQ="--hls-",NQ=new TextEncoder,HQ=/^#([a-f0-9]{3,4}|[a-f0-9]{6}|[a-f0-9]{8})$/i,nQ=/^color\(display-p3\s+[+-]?(?:\d+(?:\.\d*)?|\.\d+)\s+[+-]?(?:\d+(?:\.\d*)?|\.\d+)\s+[+-]?(?:\d+(?:\.\d*)?|\.\d+)(?:\s*\/\s*[+-]?(?:\d+(?:\.\d*)?|\.\d+))?\s*\)$/i;function ZQ(Q){return typeof Q=="string"&&(HQ.test(Q.trim())||nQ.test(Q.trim()))}function FB(Q){return Q["editor.foreground"]??Q.text??Q.foreground}function uB(Q){return Q["editor.background"]??Q.background}const YB=["black","red","green","yellow","blue","magenta","cyan","white","bright_black","bright_red","bright_green","bright_yellow","bright_blue","bright_magenta","bright_cyan","bright_white"],eQ=["#000000","#cd3131","#0dbc79","#e5e510","#2472c8","#bc3fbc","#11a8cd","#e5e5e5","#666666","#f14c4c","#23d18b","#f5f543","#3b8eea","#d670d6","#29b8db","#ffffff"];function dQ(Q){return YB.map((A,B)=>zB({foreground:Q[`terminal.ansi.${A}`]},"foreground").color??eQ[B])}function OB(Q){return Q===null?"null":Q===void 0?"undefined":typeof Q=="string"?`the string ${JSON.stringify(Q)} (theme ids are not supported; import the theme object from "@pierre/highlights/themes")`:Array.isArray(Q)?"an array":typeof Q=="object"?"themes"in Q&&Array.isArray(Q.themes)?`a ThemeFamily whose first member is ${OB(Q.themes[0])}`:"an object without a `name`":`a ${typeof Q}`}function lQ(Q){return Q!=null&&typeof Q=="object"&&"name"in Q&&typeof Q.name=="string"&&Q.name!==""}function xQ(Q){const A=Q!=null&&typeof Q=="object"&&"themes"in Q&&Q.themes!=null?Q.themes[0]:Q;if(!lQ(A))throw new TypeError(`invalid theme: expected a Theme or ThemeFamily object, received ${OB(Q)}`);return A}function vB(Q,A){let B;for(let E=A;E!=="";){const I=Q[E];if(typeof I=="string")return{...B,color:I};if(I!=null&&typeof I=="object"&&(B??=I,I.color!=null))return{...B,color:I.color};const C=E.lastIndexOf(".");E=C<0?"":E.slice(0,C)}return B}function zB(Q,A){let B,E,I;return A==="background"?B=uB(Q):A==="foreground"?B=FB(Q):({color:B,font_style:E,font_weight:I}=vB(Q.syntax??{},A)??{},(E!=null||I!=null)&&(B??=FB(Q))),ZQ(B)?(B=B.trim().toLowerCase(),B.startsWith("#")&&(B.length<=5&&(B=B.replace(/[^#]/g,"$&$&")),B.length===9&&B.endsWith("ff")&&(B=B.slice(0,7)),B==="#00000000"&&(B=void 0))):B=void 0,{color:B,italic:E==="italic",weight:I!=null&&I>=100&&I<=900?Math.round(I/100)*100:0}}function zA(Q,A){return`var(${A}${Q.replace(/[._]/g,"-")})`}function gA(Q){return Q.replaceAll("&","&").replaceAll('"',""").replaceAll("<","<").replaceAll(">",">")}function $B(Q){const A=Q.map(w=>NQ.encode(w));let B=4+8*A.length;const E=new Uint8Array(B+A.reduce((w,G)=>w+G.length,0)),I=new DataView(E.buffer);let C=32;for(let w=0;w<A.length;w++)I.setUint32(4+8*w,B,!0),I.setUint32(8+8*w,A[w].length,!0),E.set(A[w],B),B+=A[w].length,w!==0&&(C=Math.max(C,A[w].length+32));return I.setUint32(0,C,!0),E}const nB=new WeakMap;function SB(Q,A=aQ){const B=xQ(Q),E=B.cssVariables===!0?A:"";let I=nB.get(B);const C=I?.get(E);if(C!==void 0)return C;const w=B.cssVariables===!0?rQ(B.name,A):typeof B.cssVariables=="object"?bQ(B):WQ(B);return I===void 0&&(I=new Map,nB.set(B,I)),I.set(E,w),w}function bQ(Q){const A=Q.cssVariables;if(typeof A!="object")throw new Error("Expected CSS palette");const B=A.prefix??"--hls-",E=R=>{const i=A.defaults?.[R];return`var(${B}${R}${i?`, ${i}`:""})`},I=new Array(T.length).fill(null),C=Q.style.syntax??{};for(let R=1;R<T.length;R++){const i=vB(C,T[R]);I[R]={color:E(i?.color??"foreground"),italic:i?.font_style==="italic",weight:i?.font_weight===void 0?0:Math.round(i.font_weight/100)*100}}const w=E(FB(Q.style)??"foreground"),G=E(uB(Q.style)??"background");let k,S;return{name:Q.name,styles:I,fg:w,bg:G,table:void 0,get htmlOpeners(){return k??=_B(I,w,G)},get ansi(){return S??=YB.map(R=>{const i=Q.style[`terminal.ansi.${R}`];return E(typeof i=="string"?i:`terminal-ansi-${R.replace("_","-")}`)})}}}function rQ(Q,A){let B;const E=()=>B??=TQ(A);let I;return{name:Q,get styles(){return E().styles},get fg(){return E().fg},get bg(){return E().bg},table:void 0,htmlOpeners:void 0,get ansi(){return I??=YB.map(C=>zA(`terminal.ansi.${C}`,A))}}}function TQ(Q){const A=new Array(T.length).fill(null);for(let B=1;B<T.length;B++)A[B]={color:zA(T[B],Q),italic:!1,weight:0};return{styles:A,fg:zA("foreground",Q),bg:zA("background",Q)}}function WQ(Q){const A=Q.style??{},B=new Array(T.length).fill(null),E=new Uint8Array(T.length*5);let I,C,w=!1;for(let S=1;S<T.length;S++){const R=T[S],i=zB(A,R),{color:F,italic:s,weight:J}=i,t=S*5;if(F!==void 0)if(F.startsWith("#")){const a=parseInt(F.slice(1,7),16);E[t]=a>>16,E[t+1]=a>>8&255,E[t+2]=a&255,E[t+3]=F.length===9?parseInt(F.slice(7),16):255}else w=!0;E[t+4]=(s?16:0)|J/100,!(F===void 0&&!s&&J===0)&&(R==="foreground"?I=F:R==="background"?C=F:B[S]=i)}let G,k;return{name:Q.name,styles:B,fg:I,bg:C,table:w?void 0:E,get htmlOpeners(){if(w)return G??=_B(B,I,C)},get ansi(){return k??=dQ(A)}}}function _B(Q,A,B){const E=[`<pre class="highlights" style="${gA((B===void 0?"":`background-color:${B};`)+(A===void 0?"":`color:${A}`))}"><code>`];for(let I=1;I<T.length;I++){const C=Q[I],w=`color:${C?.color??"inherit"}`+(C?.italic===!0?";font-style:italic":"")+(C!=null&&C.weight!==0?`;font-weight:${C.weight}`:"");E.push(`<span style="${gA(w)}">`)}return $B(E)}const XQ=new TextEncoder,yA=new Uint8Array(T.length);for(let Q=0;Q<T.length;Q++){const A=T[Q];A==="string.regex"?yA[Q]=3:A==="comment"||A.startsWith("comment.")?yA[Q]=1:(A==="string"||A.startsWith("string."))&&(yA[Q]=2)}const ZB=new WeakMap,eB=new WeakMap;let fQ=1;const dB=new WeakMap,lB=new WeakMap,xB=new WeakMap;let KQ=0;function PQ(Q){let A=xB.get(Q);return A===void 0&&(A=KQ++,xB.set(Q,A)),A}function bB(Q,A,B){const{name:E,styles:I,fg:C,bg:w,table:G}=Q;return{color:A,role:B,name:E,styles:I,fg:C,bg:w,table:G,get ansi(){return Q.ansi}}}function lA(Q){const{cssVariablePrefix:A}=Q;if(Q.themes==null)return[bB(SB(Q.theme,A),null,"single")];const B=Object.entries(Q.themes).filter(([,R])=>R!=null).sort(([R],[i])=>R<i?-1:1);if(B.length===0)throw new TypeError("themes must not be empty");const E=Q.defaultColor??"light";let I;if(E==="light-dark()"){const R=B.find(([F])=>F==="light"),i=B.find(([F])=>F==="dark");if(R===void 0||i===void 0)throw new TypeError("`themes` must contain `light` and `dark` when defaultColor is 'light-dark()'");B.splice(0,B.length,R,i),I=["light-dark","light-dark"]}else{if(E!==!1){const R=B.findIndex(([i])=>i===E);if(R<0)throw new TypeError(`\`themes\` must contain the defaultColor key \`${E}\``);B.unshift(...B.splice(R,1))}I=B.map((R,i)=>E!==!1&&i===0?"default":"variable")}const C=B.map(([,R])=>SB(R,A)),w=JSON.stringify(B.map(([R],i)=>[PQ(C[i]),I[i],R]));let G=lB.get(C[0]);const k=G?.get(w);if(k!==void 0)return k;const S=B.map(([R],i)=>bB(C[i],R,I[i]));if(G===void 0&&(G=new Map,lB.set(C[0],G)),G.set(w,S),G.size>128){const R=G.keys().next().value;R!==void 0&&G.delete(R)}return S}function xA(Q,A,B,E,I,C,w=0){const G={content:Q.slice(A,B),offset:A+w};if(I[0].role==="single"){const{styles:S,fg:R}=I[0],i=S[E];G.color=i?.color??R;let F=0;i?.italic===!0&&(F|=1),(i?.weight??0)>=600&&(F|=2),G.fontStyle=F}else G.htmlStyle=aB(I,E,C);const k=yA[E];return k!==0&&(G.type=k),G}function AQ(Q,A){let B=ZB.get(Q);B===void 0&&(B=new Map,ZB.set(Q,B));let E=B.get(A);return E===void 0&&(E=[],B.set(A,E)),E}function aB(Q,A,B){const E=AQ(Q,B);let I=E[A];if(I===void 0){if(Q[0].role==="light-dark")I=pQ(Q,A,B);else{I={};for(const{color:C,role:w,styles:G,fg:k}of Q){const S=G[A],R=w==="default";I[R?"color":B+C]=S?.color??k??"inherit",S?.italic===!0&&(I[R?"font-style":`${B}${C}-font-style`]="italic"),S!=null&&S.weight!==0&&(I[R?"font-weight":`${B}${C}-font-weight`]=String(S.weight))}}E[A]=I}return I}function VQ(Q,A){let B=eB.get(Q);B===void 0&&(B=new Map,eB.set(Q,B));const E=B.get(A);if(E!==void 0)return E??void 0;const I=Q.length;if(!(I<=255&&Q.every(J=>J.table!==void 0))){B.set(A,null);return}const C=Q.map(J=>J.role==="default"?new Uint8Array(0):XQ.encode(gA(`${A}${J.color}`))),w=32+16*I,G=w+384*I;let k=64,S=128,R=0;for(const{length:J}of C)k+=64+3*J,S+=48+2*J,R+=J;const i=new Uint8Array(G+R),F=new DataView(i.buffer);i[0]=I,i[1]=Q[0].role==="light-dark"?1:0,F.setUint32(4,w,!0),F.setUint32(8,k,!0),F.setUint32(12,S,!0),F.setUint32(16,fQ++,!0);let s=G;for(let J=0;J<I;J++){const t=32+16*J;F.setUint32(t,s,!0),F.setUint32(t+4,C[J].length,!0),F.setUint32(t+8,Q[J].role==="default"?1:0,!0),i.set(Q[J].table,w+384*J),i.set(C[J],s),s+=C[J].length}return B.set(A,i),i}function mQ(Q,A){let B=dB.get(Q);B===void 0&&(B=new Map,dB.set(Q,B));const E=B.get(A);if(E!==void 0)return E;const{fg:I,bg:C,rootStyle:w}=kB(Q,A),G=[`<pre class="highlights" style="${gA(w??`background-color:${C};color:${I}`)}"><code>`];for(let S=1;S<T.length;S++){const R=aB(Q,S,A);let i="";for(const F in R)i+=`${i===""?"":";"}${F}:${R[F]}`;G.push(`<span style="${gA(i)}">`)}const k=$B(G);return B.set(A,k),k}function pQ(Q,A,B){const[E,I]=Q,C=E.styles[A],w=I.styles[A],G=C?.color??E.fg??"currentcolor",k=w?.color??I.fg??"currentcolor",S={color:G===k?G:`light-dark(${G}, ${k})`},R=C?.italic===!0,i=w?.italic===!0;R&&i?S["font-style"]="italic":(R&&(S[`${B}light-font-style`]="italic"),i&&(S[`${B}dark-font-style`]="italic"));const F=C?.weight??0,s=w?.weight??0;return F!==0&&F===s?S["font-weight"]=String(F):(F!==0&&(S[`${B}light-font-weight`]=String(F)),s!==0&&(S[`${B}dark-font-weight`]=String(s))),S}function BQ(Q,A,B,E,I,C=0){const w=[],G=I??0,{styles:k,fg:S,role:R}=B[0],i=R==="single"?void 0:AQ(B,E);let F=0;for(let s=0;;s+=2){const J=s;for(;s<A.length&&A[s+1]!==4294967295;)s+=2;const t=s===J?F:A[s-2];let a;if(G>0&&t-F>=G)a=[xA(Q,F,t,0,B,E,C)];else{a=new Array((s-J)/2);let o=0;for(let n=J;n<s;n+=2){const Z=A[n];if(Z>F){const h=A[n+1];let L;if(i===void 0){const H=k[h];L={content:Q.slice(F,Z),offset:F+C,color:H?.color??S,fontStyle:(H?.italic===!0?1:0)|((H?.weight??0)>=600?2:0)}}else L={content:Q.slice(F,Z),offset:F+C,htmlStyle:i[h]??aB(B,h,E)};const y=yA[h];y!==0&&(L.type=y),a[o++]=L,F=Z}}a.length=o}if(w.push(a),s===A.length)break;F=A[s]}return w}function kB(Q,A){if(Q[0].role==="single")return{fg:Q[0].fg,bg:Q[0].bg,themeName:Q[0].name};const B=`highlights-themes ${Q.map(C=>C.name).join(" ")}`;if(Q[0].role==="light-dark"){const C=(w,G,k)=>{const S=w??k,R=G??k;return S===R?S:`light-dark(${S}, ${R})`};return{fg:C(Q[0].fg,Q[1].fg,"currentcolor"),bg:C(Q[0].bg,Q[1].bg,"transparent"),themeName:B}}const E=Q.map(C=>C.role==="default"?C.fg??"inherit":`${A}${C.color}:${C.fg??"inherit"}`).join(";"),I=Q.map(C=>C.role==="default"?C.bg??"inherit":`${A}${C.color}-bg:${C.bg??"inherit"}`).join(";");return{fg:E,bg:I,themeName:B,rootStyle:Q[0].role==="default"?void 0:`${E};${I}`}}const sB=1,QQ=2,EQ=4,IQ=8,CQ=16,gQ=32,rB=[0,sB,QQ,EQ,IQ,0,0,CQ,0,gQ],gB=[0,95,135,175,215,255],wB=/\x1b(?:\[([0-?]*)[ -/]*([@-~])|\][^\x07\x1b\n]*(?:\x07|\x1b\\)|[ -/]*[0-~])/y;var wQ=class{constructor(){x(this,"fg",-1);x(this,"bg",-1);x(this,"flags",0);x(this,"styles",new Map)}};function bA(Q){return String(Q).toLowerCase()==="ansi"}function RB(Q,A){if(A<16)return Q.ansi[A];let B=A&16777215;if(A<232){const E=A-16;B=gB[E/36|0]<<16|gB[(E/6|0)%6]<<8|gB[E%6]}else A<256&&(B=(8+(A-232)*10)*65793);return`#${B.toString(16).padStart(6,"0")}`}function UB(Q,A,B,E,I=new wQ,C=0){const w=[],G=E??0;let k=[],S,R,i,F=Q.indexOf("\x1B"),s=0;for(;;){const J=Q.indexOf(`
|
|
1
|
+
var cQ=Object.defineProperty;var NB=Q=>{throw TypeError(Q)};var LQ=(Q,A,B)=>A in Q?cQ(Q,A,{enumerable:!0,configurable:!0,writable:!0,value:B}):Q[A]=B;var x=(Q,A,B)=>LQ(Q,typeof A!="symbol"?A+"":A,B),CB=(Q,A,B)=>A.has(Q)||NB("Cannot "+B);var g=(Q,A,B)=>(CB(Q,A,"read from private field"),B?B.call(Q):A.get(Q)),c=(Q,A,B)=>A.has(Q)?NB("Cannot add the same private member more than once"):A instanceof WeakSet?A.add(Q):A.set(Q,B),M=(Q,A,B,E)=>(CB(Q,A,"write to private field"),E?E.call(Q,B):A.set(Q,B),B),D=(Q,A,B)=>(CB(Q,A,"access private method"),B);var HB=(Q,A,B,E)=>({set _(I){M(Q,A,I,B)},get _(){return g(Q,A,E)}});import{a3 as tQ,r as hQ,Q as jQ}from"./Dxxx3b3f.js";import{B as oQ,D as YQ}from"./CXbNsxGs.js";const T=["none","attribute","attribute.jsx","boolean","comment","comment.doc","constant","constant.builtin","constructor","diff.minus","diff.plus","embedded","emphasis","emphasis.strong","function","function.definition","function.method","keyword","keyword.control","keyword.declaration","keyword.import","keyword.operator","label","namespace","number","operator","predictive","preproc","primary","property","property.json_key","punctuation","punctuation.bracket","punctuation.bracket.html","punctuation.bracket.jsx","punctuation.delimiter","punctuation.delimiter.html","punctuation.delimiter.jsx","punctuation.list_marker","punctuation.markup","punctuation.special","selector","selector.class","selector.id","string","string.escape","string.regex","string.special","string.special.symbol","tag","tag.doctype","tag.jsx","text.jsx","text.literal","title","type","type.builtin","type.class","variable","variable.parameter","variable.special","enum","hint","keyword.jsdoc","link_text","link_uri","selector.pseudo","tag.component.jsx","type.jsdoc","variable.jsdoc","variant","background","foreground"],aQ="--hls-",NQ=new TextEncoder,HQ=/^#([a-f0-9]{3,4}|[a-f0-9]{6}|[a-f0-9]{8})$/i,nQ=/^color\(display-p3\s+[+-]?(?:\d+(?:\.\d*)?|\.\d+)\s+[+-]?(?:\d+(?:\.\d*)?|\.\d+)\s+[+-]?(?:\d+(?:\.\d*)?|\.\d+)(?:\s*\/\s*[+-]?(?:\d+(?:\.\d*)?|\.\d+))?\s*\)$/i;function ZQ(Q){return typeof Q=="string"&&(HQ.test(Q.trim())||nQ.test(Q.trim()))}function FB(Q){return Q["editor.foreground"]??Q.text??Q.foreground}function uB(Q){return Q["editor.background"]??Q.background}const YB=["black","red","green","yellow","blue","magenta","cyan","white","bright_black","bright_red","bright_green","bright_yellow","bright_blue","bright_magenta","bright_cyan","bright_white"],eQ=["#000000","#cd3131","#0dbc79","#e5e510","#2472c8","#bc3fbc","#11a8cd","#e5e5e5","#666666","#f14c4c","#23d18b","#f5f543","#3b8eea","#d670d6","#29b8db","#ffffff"];function dQ(Q){return YB.map((A,B)=>zB({foreground:Q[`terminal.ansi.${A}`]},"foreground").color??eQ[B])}function OB(Q){return Q===null?"null":Q===void 0?"undefined":typeof Q=="string"?`the string ${JSON.stringify(Q)} (theme ids are not supported; import the theme object from "@pierre/highlights/themes")`:Array.isArray(Q)?"an array":typeof Q=="object"?"themes"in Q&&Array.isArray(Q.themes)?`a ThemeFamily whose first member is ${OB(Q.themes[0])}`:"an object without a `name`":`a ${typeof Q}`}function lQ(Q){return Q!=null&&typeof Q=="object"&&"name"in Q&&typeof Q.name=="string"&&Q.name!==""}function xQ(Q){const A=Q!=null&&typeof Q=="object"&&"themes"in Q&&Q.themes!=null?Q.themes[0]:Q;if(!lQ(A))throw new TypeError(`invalid theme: expected a Theme or ThemeFamily object, received ${OB(Q)}`);return A}function vB(Q,A){let B;for(let E=A;E!=="";){const I=Q[E];if(typeof I=="string")return{...B,color:I};if(I!=null&&typeof I=="object"&&(B??=I,I.color!=null))return{...B,color:I.color};const C=E.lastIndexOf(".");E=C<0?"":E.slice(0,C)}return B}function zB(Q,A){let B,E,I;return A==="background"?B=uB(Q):A==="foreground"?B=FB(Q):({color:B,font_style:E,font_weight:I}=vB(Q.syntax??{},A)??{},(E!=null||I!=null)&&(B??=FB(Q))),ZQ(B)?(B=B.trim().toLowerCase(),B.startsWith("#")&&(B.length<=5&&(B=B.replace(/[^#]/g,"$&$&")),B.length===9&&B.endsWith("ff")&&(B=B.slice(0,7)),B==="#00000000"&&(B=void 0))):B=void 0,{color:B,italic:E==="italic",weight:I!=null&&I>=100&&I<=900?Math.round(I/100)*100:0}}function zA(Q,A){return`var(${A}${Q.replace(/[._]/g,"-")})`}function gA(Q){return Q.replaceAll("&","&").replaceAll('"',""").replaceAll("<","<").replaceAll(">",">")}function $B(Q){const A=Q.map(w=>NQ.encode(w));let B=4+8*A.length;const E=new Uint8Array(B+A.reduce((w,G)=>w+G.length,0)),I=new DataView(E.buffer);let C=32;for(let w=0;w<A.length;w++)I.setUint32(4+8*w,B,!0),I.setUint32(8+8*w,A[w].length,!0),E.set(A[w],B),B+=A[w].length,w!==0&&(C=Math.max(C,A[w].length+32));return I.setUint32(0,C,!0),E}const nB=new WeakMap;function SB(Q,A=aQ){const B=xQ(Q),E=B.cssVariables===!0?A:"";let I=nB.get(B);const C=I?.get(E);if(C!==void 0)return C;const w=B.cssVariables===!0?rQ(B.name,A):typeof B.cssVariables=="object"?bQ(B):WQ(B);return I===void 0&&(I=new Map,nB.set(B,I)),I.set(E,w),w}function bQ(Q){const A=Q.cssVariables;if(typeof A!="object")throw new Error("Expected CSS palette");const B=A.prefix??"--hls-",E=R=>{const i=A.defaults?.[R];return`var(${B}${R}${i?`, ${i}`:""})`},I=new Array(T.length).fill(null),C=Q.style.syntax??{};for(let R=1;R<T.length;R++){const i=vB(C,T[R]);I[R]={color:E(i?.color??"foreground"),italic:i?.font_style==="italic",weight:i?.font_weight===void 0?0:Math.round(i.font_weight/100)*100}}const w=E(FB(Q.style)??"foreground"),G=E(uB(Q.style)??"background");let k,S;return{name:Q.name,styles:I,fg:w,bg:G,table:void 0,get htmlOpeners(){return k??=_B(I,w,G)},get ansi(){return S??=YB.map(R=>{const i=Q.style[`terminal.ansi.${R}`];return E(typeof i=="string"?i:`terminal-ansi-${R.replace("_","-")}`)})}}}function rQ(Q,A){let B;const E=()=>B??=TQ(A);let I;return{name:Q,get styles(){return E().styles},get fg(){return E().fg},get bg(){return E().bg},table:void 0,htmlOpeners:void 0,get ansi(){return I??=YB.map(C=>zA(`terminal.ansi.${C}`,A))}}}function TQ(Q){const A=new Array(T.length).fill(null);for(let B=1;B<T.length;B++)A[B]={color:zA(T[B],Q),italic:!1,weight:0};return{styles:A,fg:zA("foreground",Q),bg:zA("background",Q)}}function WQ(Q){const A=Q.style??{},B=new Array(T.length).fill(null),E=new Uint8Array(T.length*5);let I,C,w=!1;for(let S=1;S<T.length;S++){const R=T[S],i=zB(A,R),{color:F,italic:s,weight:J}=i,t=S*5;if(F!==void 0)if(F.startsWith("#")){const a=parseInt(F.slice(1,7),16);E[t]=a>>16,E[t+1]=a>>8&255,E[t+2]=a&255,E[t+3]=F.length===9?parseInt(F.slice(7),16):255}else w=!0;E[t+4]=(s?16:0)|J/100,!(F===void 0&&!s&&J===0)&&(R==="foreground"?I=F:R==="background"?C=F:B[S]=i)}let G,k;return{name:Q.name,styles:B,fg:I,bg:C,table:w?void 0:E,get htmlOpeners(){if(w)return G??=_B(B,I,C)},get ansi(){return k??=dQ(A)}}}function _B(Q,A,B){const E=[`<pre class="highlights" style="${gA((B===void 0?"":`background-color:${B};`)+(A===void 0?"":`color:${A}`))}"><code>`];for(let I=1;I<T.length;I++){const C=Q[I],w=`color:${C?.color??"inherit"}`+(C?.italic===!0?";font-style:italic":"")+(C!=null&&C.weight!==0?`;font-weight:${C.weight}`:"");E.push(`<span style="${gA(w)}">`)}return $B(E)}const XQ=new TextEncoder,yA=new Uint8Array(T.length);for(let Q=0;Q<T.length;Q++){const A=T[Q];A==="string.regex"?yA[Q]=3:A==="comment"||A.startsWith("comment.")?yA[Q]=1:(A==="string"||A.startsWith("string."))&&(yA[Q]=2)}const ZB=new WeakMap,eB=new WeakMap;let fQ=1;const dB=new WeakMap,lB=new WeakMap,xB=new WeakMap;let KQ=0;function PQ(Q){let A=xB.get(Q);return A===void 0&&(A=KQ++,xB.set(Q,A)),A}function bB(Q,A,B){const{name:E,styles:I,fg:C,bg:w,table:G}=Q;return{color:A,role:B,name:E,styles:I,fg:C,bg:w,table:G,get ansi(){return Q.ansi}}}function lA(Q){const{cssVariablePrefix:A}=Q;if(Q.themes==null)return[bB(SB(Q.theme,A),null,"single")];const B=Object.entries(Q.themes).filter(([,R])=>R!=null).sort(([R],[i])=>R<i?-1:1);if(B.length===0)throw new TypeError("themes must not be empty");const E=Q.defaultColor??"light";let I;if(E==="light-dark()"){const R=B.find(([F])=>F==="light"),i=B.find(([F])=>F==="dark");if(R===void 0||i===void 0)throw new TypeError("`themes` must contain `light` and `dark` when defaultColor is 'light-dark()'");B.splice(0,B.length,R,i),I=["light-dark","light-dark"]}else{if(E!==!1){const R=B.findIndex(([i])=>i===E);if(R<0)throw new TypeError(`\`themes\` must contain the defaultColor key \`${E}\``);B.unshift(...B.splice(R,1))}I=B.map((R,i)=>E!==!1&&i===0?"default":"variable")}const C=B.map(([,R])=>SB(R,A)),w=JSON.stringify(B.map(([R],i)=>[PQ(C[i]),I[i],R]));let G=lB.get(C[0]);const k=G?.get(w);if(k!==void 0)return k;const S=B.map(([R],i)=>bB(C[i],R,I[i]));if(G===void 0&&(G=new Map,lB.set(C[0],G)),G.set(w,S),G.size>128){const R=G.keys().next().value;R!==void 0&&G.delete(R)}return S}function xA(Q,A,B,E,I,C,w=0){const G={content:Q.slice(A,B),offset:A+w};if(I[0].role==="single"){const{styles:S,fg:R}=I[0],i=S[E];G.color=i?.color??R;let F=0;i?.italic===!0&&(F|=1),(i?.weight??0)>=600&&(F|=2),G.fontStyle=F}else G.htmlStyle=aB(I,E,C);const k=yA[E];return k!==0&&(G.type=k),G}function AQ(Q,A){let B=ZB.get(Q);B===void 0&&(B=new Map,ZB.set(Q,B));let E=B.get(A);return E===void 0&&(E=[],B.set(A,E)),E}function aB(Q,A,B){const E=AQ(Q,B);let I=E[A];if(I===void 0){if(Q[0].role==="light-dark")I=pQ(Q,A,B);else{I={};for(const{color:C,role:w,styles:G,fg:k}of Q){const S=G[A],R=w==="default";I[R?"color":B+C]=S?.color??k??"inherit",S?.italic===!0&&(I[R?"font-style":`${B}${C}-font-style`]="italic"),S!=null&&S.weight!==0&&(I[R?"font-weight":`${B}${C}-font-weight`]=String(S.weight))}}E[A]=I}return I}function VQ(Q,A){let B=eB.get(Q);B===void 0&&(B=new Map,eB.set(Q,B));const E=B.get(A);if(E!==void 0)return E??void 0;const I=Q.length;if(!(I<=255&&Q.every(J=>J.table!==void 0))){B.set(A,null);return}const C=Q.map(J=>J.role==="default"?new Uint8Array(0):XQ.encode(gA(`${A}${J.color}`))),w=32+16*I,G=w+384*I;let k=64,S=128,R=0;for(const{length:J}of C)k+=64+3*J,S+=48+2*J,R+=J;const i=new Uint8Array(G+R),F=new DataView(i.buffer);i[0]=I,i[1]=Q[0].role==="light-dark"?1:0,F.setUint32(4,w,!0),F.setUint32(8,k,!0),F.setUint32(12,S,!0),F.setUint32(16,fQ++,!0);let s=G;for(let J=0;J<I;J++){const t=32+16*J;F.setUint32(t,s,!0),F.setUint32(t+4,C[J].length,!0),F.setUint32(t+8,Q[J].role==="default"?1:0,!0),i.set(Q[J].table,w+384*J),i.set(C[J],s),s+=C[J].length}return B.set(A,i),i}function mQ(Q,A){let B=dB.get(Q);B===void 0&&(B=new Map,dB.set(Q,B));const E=B.get(A);if(E!==void 0)return E;const{fg:I,bg:C,rootStyle:w}=kB(Q,A),G=[`<pre class="highlights" style="${gA(w??`background-color:${C};color:${I}`)}"><code>`];for(let S=1;S<T.length;S++){const R=aB(Q,S,A);let i="";for(const F in R)i+=`${i===""?"":";"}${F}:${R[F]}`;G.push(`<span style="${gA(i)}">`)}const k=$B(G);return B.set(A,k),k}function pQ(Q,A,B){const[E,I]=Q,C=E.styles[A],w=I.styles[A],G=C?.color??E.fg??"currentcolor",k=w?.color??I.fg??"currentcolor",S={color:G===k?G:`light-dark(${G}, ${k})`},R=C?.italic===!0,i=w?.italic===!0;R&&i?S["font-style"]="italic":(R&&(S[`${B}light-font-style`]="italic"),i&&(S[`${B}dark-font-style`]="italic"));const F=C?.weight??0,s=w?.weight??0;return F!==0&&F===s?S["font-weight"]=String(F):(F!==0&&(S[`${B}light-font-weight`]=String(F)),s!==0&&(S[`${B}dark-font-weight`]=String(s))),S}function BQ(Q,A,B,E,I,C=0){const w=[],G=I??0,{styles:k,fg:S,role:R}=B[0],i=R==="single"?void 0:AQ(B,E);let F=0;for(let s=0;;s+=2){const J=s;for(;s<A.length&&A[s+1]!==4294967295;)s+=2;const t=s===J?F:A[s-2];let a;if(G>0&&t-F>=G)a=[xA(Q,F,t,0,B,E,C)];else{a=new Array((s-J)/2);let o=0;for(let n=J;n<s;n+=2){const Z=A[n];if(Z>F){const h=A[n+1];let L;if(i===void 0){const H=k[h];L={content:Q.slice(F,Z),offset:F+C,color:H?.color??S,fontStyle:(H?.italic===!0?1:0)|((H?.weight??0)>=600?2:0)}}else L={content:Q.slice(F,Z),offset:F+C,htmlStyle:i[h]??aB(B,h,E)};const y=yA[h];y!==0&&(L.type=y),a[o++]=L,F=Z}}a.length=o}if(w.push(a),s===A.length)break;F=A[s]}return w}function kB(Q,A){if(Q[0].role==="single")return{fg:Q[0].fg,bg:Q[0].bg,themeName:Q[0].name};const B=`highlights-themes ${Q.map(C=>C.name).join(" ")}`;if(Q[0].role==="light-dark"){const C=(w,G,k)=>{const S=w??k,R=G??k;return S===R?S:`light-dark(${S}, ${R})`};return{fg:C(Q[0].fg,Q[1].fg,"currentcolor"),bg:C(Q[0].bg,Q[1].bg,"transparent"),themeName:B}}const E=Q.map(C=>C.role==="default"?C.fg??"inherit":`${A}${C.color}:${C.fg??"inherit"}`).join(";"),I=Q.map(C=>C.role==="default"?C.bg??"inherit":`${A}${C.color}-bg:${C.bg??"inherit"}`).join(";");return{fg:E,bg:I,themeName:B,rootStyle:Q[0].role==="default"?void 0:`${E};${I}`}}const sB=1,QQ=2,EQ=4,IQ=8,CQ=16,gQ=32,rB=[0,sB,QQ,EQ,IQ,0,0,CQ,0,gQ],gB=[0,95,135,175,215,255],wB=/\x1b(?:\[([0-?]*)[ -/]*([@-~])|\][^\x07\x1b\n]*(?:\x07|\x1b\\)|[ -/]*[0-~])/y;var wQ=class{constructor(){x(this,"fg",-1);x(this,"bg",-1);x(this,"flags",0);x(this,"styles",new Map)}};function bA(Q){return String(Q).toLowerCase()==="ansi"}function RB(Q,A){if(A<16)return Q.ansi[A];let B=A&16777215;if(A<232){const E=A-16;B=gB[E/36|0]<<16|gB[(E/6|0)%6]<<8|gB[E%6]}else A<256&&(B=(8+(A-232)*10)*65793);return`#${B.toString(16).padStart(6,"0")}`}function UB(Q,A,B,E,I=new wQ,C=0){const w=[],G=E??0;let k=[],S,R,i,F=Q.indexOf("\x1B"),s=0;for(;;){const J=Q.indexOf(`
|
|
2
2
|
`,s);let t=J<0?Q.length:J;J>s&&Q.charCodeAt(J-1)===13&&t--;const a=G>0&&t-s>=G;for(;s<t;){F>=0&&F<s&&(F=Q.indexOf("\x1B",s));let o=F>=0&&F<t?F:t,n=o,Z;if(o<t){wB.lastIndex=o;const h=wB.exec(Q);h===null?n=++o:(n=wB.lastIndex,h[2]==="m"&&!(h[1].charCodeAt(0)>=60)&&(Z=h[1]))}if(o>s&&a)R===void 0?(R=xA(Q,s,o,0,A,B,C),k.push(R)):R.content+=Q.slice(s,o);else if(o>s){if(S===void 0){const{fg:h,bg:L,flags:y}=I,H=`${h},${L},${y}`;if(S=I.styles.get(H),S===void 0){const m=((y&EQ)!==0?1:0)|((y&sB)!==0?2:0)|((y&IQ)!==0?4:0)|((y&gQ)!==0?8:0),z=A.map(e=>{let j=h<0?e.fg:RB(e,h),$=L<0?void 0:RB(e,L);return(y&CQ)!==0&&($=j,j=L<0?e.bg:RB(e,L)),(y&QQ)!==0&&j!==void 0&&(j=j.startsWith("#")?j.length===9?j.slice(0,7)+Math.round(parseInt(j.slice(7),16)/2).toString(16).padStart(2,"0"):`${j}80`:`color-mix(in srgb, ${j} 50%, transparent)`),[j,$]});if(A[0].role==="single"){const[e,j]=z[0];S=j===void 0?{color:e,fontStyle:m}:{color:e,bgColor:j,fontStyle:m}}else{const e=[];(m&1)!==0&&e.push(["font-style","italic"]),(m&2)!==0&&e.push(["font-weight","bold"]),(m&12)!==0&&e.push(["text-decoration",(m&12)===12?"underline line-through":(m&4)!==0?"underline":"line-through"]);const j={};if(A[0].role==="light-dark"){const[[$,pA],[qA,sA]]=z,wA=$??"currentcolor",HA=qA??"currentcolor";if(j.color=wA===HA?wA:`light-dark(${wA}, ${HA})`,pA!==void 0||sA!==void 0){const RA=pA??"transparent",uA=sA??"transparent";j["background-color"]=RA===uA?RA:`light-dark(${RA}, ${uA})`}for(const[RA,uA]of e)j[RA]=uA}else for(let $=0;$<A.length;$++){const[pA,qA]=z[$],sA=A[$].role==="default",wA=`${B}${A[$].color}`;j[sA?"color":wA]=pA??"inherit",qA!==void 0&&(j[sA?"background-color":`${wA}-bg`]=qA);for(const[HA,RA]of e)j[sA?HA:`${wA}-${HA}`]=RA}S={htmlStyle:j}}I.styles.set(H,S)}}R!==void 0&&i===S?R.content+=Q.slice(s,o):(R={content:Q.slice(s,o),offset:s+C,...S},i=S,k.push(R))}if(Z!==void 0){const h=Z.split(";");for(let L=0;L<h.length;L++){const y=Number(h[L]);if(y===0)I.fg=-1,I.bg=-1,I.flags=0;else if(y<10)I.flags|=rB[y]??0;else if(y>20&&y<30)I.flags&=~((rB[y-20]??0)|(y===22?sB:0));else if(y>=30&&y<38)I.fg=y-30;else if(y===39)I.fg=-1;else if(y>=40&&y<48)I.bg=y-40;else if(y===49)I.bg=-1;else if(y>=90&&y<98)I.fg=y-82;else if(y>=100&&y<108)I.bg=y-92;else if(y===38||y===48){const H=h[++L];let m=-1;if(H==="5"){const z=Number(h[++L]);Number.isInteger(z)&&z<256&&(m=z)}else if(H==="2"){const z=Number(h[L+1]),e=Number(h[L+2]),j=Number(h[L+3]);L+=3,z>=0&&e>=0&&j>=0&&(m=16777216|Math.min(z,255)<<16|Math.min(e,255)<<8|Math.min(j,255))}m>=0&&(y===38?I.fg=m:I.bg=m)}}S=void 0}s=n}if(w.push(k),J<0)return w;s=J+1,k=[],R=void 0}}const qQ={plain:0,plaintext:0,text:0,txt:0,abap:1,ada:2,adb:2,ads:2,"angular-html":3,apache:4,apacheconf:4,htaccess:4,apex:5,applescript:6,adoc:7,asciidoc:7,asm:8,assembly:8,mips:8,mipsasm:8,riscv:8,s:8,astro:9,awk:10,bash:11,sh:11,shell:11,shellscript:11,shellsession:11,zsh:11,bat:12,batch:12,batchfile:12,cmd:12,dos:12,bib:13,bibtex:13,bicep:14,blade:15,c:16,h:16,c3:17,clj:18,cljc:18,cljs:18,clojure:18,edn:18,cmake:19,cbl:20,cob:20,cobol:20,codeowners:21,codeql:22,ql:22,coffee:23,coffeescript:23,coq:24,rocq:24,"c++":25,cc:25,cpp:25,cxx:25,hh:25,hpp:25,hxx:25,"c#":26,cs:26,csharp:26,css:27,postcss:27,qss:27,csv:28,cu:29,cuda:29,cuh:29,cql:30,cypher:30,d:31,dart:32,dax:33,diff:34,"git-commit":34,"git-rebase":34,patch:34,containerfile:35,docker:35,dockerfile:35,dotenv:36,env:36,elixir:37,ex:37,exs:37,elm:38,erb:39,erl:40,erlang:40,hrl:40,fish:41,f03:42,f08:42,f90:42,f95:42,fortran:42,"fortran-free-form":42,f:43,f77:43,for:43,"fortran-fixed-form":43,"f#":44,fs:44,fsharp:44,fsi:44,fsx:44,gdresource:45,"godot-resource":45,tres:45,tscn:45,gd:46,gdscript:46,gdshader:47,gdshaderinc:47,"godot-shader":47,cucumber:48,feature:48,gherkin:48,gleam:49,comp:50,frag:50,geom:50,glsl:50,vert:50,gnuplot:51,gp:51,go:52,golang:52,gql:53,graphql:53,groq:54,gradle:55,groovy:55,gsh:55,gvy:55,gy:55,nextflow:55,"nextflow-groovy":55,nf:55,hack:56,haml:57,handlebars:58,hbs:58,mustache:58,haskell:59,hs:59,haxe:60,hx:60,hlsl:61,htm:62,html:62,"html-derivative":62,http:63,desktop:64,ini:64,properties:64,systemd:64,java:65,j2:66,jinja:66,jinja2:66,cjs:67,javascript:67,js:67,mjs:67,json:68,jsonc:68,json5:69,jsonl:70,jsonnet:71,libsonnet:71,jsx:72,jl:73,julia:73,just:74,justfile:74,kdl:75,kotlin:76,kt:76,kts:76,latex:77,tex:77,lean:78,lean4:78,less:79,liquid:80,cl:81,el:81,elisp:81,"emacs-lisp":81,lisp:81,lsp:81,racket:81,rkt:81,scheme:81,scm:81,llvm:82,log:83,lua:84,luau:85,make:86,makefile:86,mk:86,markdown:87,md:87,mdc:87,matlab:88,octave:88,mdx:89,mermaid:90,mmd:90,mbt:91,moonbit:91,nginx:92,nim:93,nix:94,m:95,mm:95,objc:95,objcpp:95,"objective-c":95,"objective-cpp":95,objectivec:95,ml:96,mli:96,ocaml:96,odin:97,openscad:98,scad:98,delphi:99,dpk:99,dpr:99,lpr:99,"object-pascal":99,objectpascal:99,pas:99,pascal:99,pp:99,perl:100,pl:100,pm:100,php:101,plsql:102,po:103,pot:103,potx:103,powerquery:104,pq:104,powershell:105,ps:105,ps1:105,psd1:105,psm1:105,pwsh:105,prisma:106,prolog:107,promql:108,proto:109,protobuf:109,jade:110,pug:110,puppet:111,py:112,python:112,qml:113,r:114,rscript:114,cshtml:115,razor:115,reg:116,rosmsg:117,restructuredtext:118,rst:118,rb:119,ruby:119,rs:120,rust:120,sas:121,sass:122,sbt:123,sc:123,scala:123,scss:124,shader:125,shaderlab:125,sol:126,solidity:126,sparql:127,sql:128,stata:129,styl:130,stylus:130,svelte:131,swift:132,tcl:133,hcl:134,terraform:134,tf:134,tfvars:134,toml:135,"angular-ts":136,cts:136,lit:136,mts:136,ts:136,"ts-tags":136,typescript:136,tsrx:137,tsv:138,tsx:139,ttl:140,turtle:140,twig:141,typ:142,typst:142,sv:143,svh:143,"system-verilog":143,systemverilog:143,verilog:143,vhd:144,vhdl:144,vim:145,viml:145,vimscript:145,vue:146,"vue-html":146,wasm:147,wat:147,wgsl:148,mathematica:149,wl:149,wolfram:149,svg:150,xml:150,xsd:150,xsl:150,xslt:150,yaml:151,yml:151,zig:152,zon:152},OA=new TextEncoder,RQ=new TextDecoder("utf-8",{ignoreBOM:!0}),$A=65536,TB=64,iA=81920,WB=[/^\p{ID_Start}$/u,/^[\u200C\u200D\p{ID_Continue}]$/u];let iB;const iQ=qQ;function QB(Q){const A=iQ[String(Q).toLowerCase()];if(typeof A!="number")throw new RangeError(`unknown lang: ${Q}`);return A}function uQ(Q){return typeof iQ[String(Q).toLowerCase()]=="number"||bA(Q)}var rA,TA,WA,XA,fA,P,DB,UA,JB,mB,IB=(mB=class{constructor(A){c(this,P);c(this,rA);c(this,TA);c(this,WA);c(this,XA);c(this,fA,new Uint8Array(0));x(this,"wasmModule");x(this,"instance");x(this,"memory");x(this,"buffer");x(this,"dv");x(this,"pageN");this.wasmModule=A;const B=new WebAssembly.Instance(A,{env:{is_id_start:(E,I)=>D(this,P,JB).call(this,E,I,0),is_id_continue:(E,I)=>D(this,P,JB).call(this,E,I,2)}});this.instance=B,this.memory=B.exports.memory,M(this,rA,B.exports.highlight),M(this,TA,B.exports.highlightStream),this.pageN=this.memory.buffer.byteLength/$A,this.buffer=new Uint8Array(this.memory.buffer),this.dv=new DataView(this.memory.buffer)}writeInput(A,B=0){if(typeof A=="string"){D(this,P,UA).call(this,B+A.length+96);let{read:E,written:I}=OA.encodeInto(A,this.buffer.subarray(iA+B,this.buffer.length-96));if(E<A.length){const C=A.slice(E);D(this,P,UA).call(this,B+I+C.length*3+96),I+=OA.encodeInto(C,this.buffer.subarray(iA+B+I,this.buffer.length-96)).written}return I}if(A instanceof ArrayBuffer&&(A=new Uint8Array(A)),!(A instanceof Uint8Array))throw new TypeError("input must be a string, Uint8Array, or ArrayBuffer");return D(this,P,UA).call(this,B+A.length+96),this.buffer.set(A,iA+B),A.length}codeToHtml(A,B){const E=B.cssVariablePrefix??"--hls-";if(bA(B.lang)){const i=lA(B),{fg:F,bg:s,rootStyle:J}=kB(i,E),t=yB(A),a=UB(t,i[0].role==="single"?[{...i[0],role:"default"}]:i,E);let o=`<pre class="highlights" style="${gA(J??(s===void 0?"":`background-color:${s};`)+(F===void 0?"":`color:${F}`))}"><code>`;for(let n=0,Z=-1;n<a.length;n++){n>0&&(Z=t.indexOf(`
|
|
3
3
|
`,Z+1),o+=t.charCodeAt(Z-1)===13?`\r
|
|
4
4
|
`:`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{p as xt}from"./
|
|
1
|
+
import{p as xt}from"./DwHO9O_t.js";import{aZ as gt,U as $t,Y as bt,b0 as wt,V as Ct,a_ as vt,b as s,ay as O,aX as Dt,B as kt,r as Tt,q as U,W as Z,O as At,a6 as ot}from"./BOi9rcQa.js";import{p as Bt}from"./BBfR26V0.js";var rt=s(()=>({domains:new Map,transitions:[]}),"createDefaultData"),H=rt(),St=s(()=>H.domains,"getDomains"),Mt=s(()=>H.transitions,"getTransitions"),zt=s(t=>{if(t)for(const e of t){const n=e.domain,a=(e.items??[]).map(c=>({label:c.label}));H.domains.set(n,{name:n,items:a})}},"setDomains"),Lt=s(t=>{t&&(H.transitions=t.filter(e=>e.from===e.to?(O.warn(`Cynefin: self-loop transition on domain "${e.from}" is not meaningful and will be skipped.`),!1):!0).map(e=>({from:e.from,to:e.to,label:e.label||void 0})))},"setTransitions"),Nt=s(()=>U({...At.cynefin,...Z().cynefin}),"getConfig"),Pt=s(()=>{Tt(),H=rt()},"clear"),G={getDomains:St,getTransitions:Mt,setDomains:zt,setTransitions:Lt,getConfig:Nt,clear:Pt,setAccTitle:vt,getAccTitle:Ct,setDiagramTitle:wt,getDiagramTitle:bt,getAccDescription:$t,setAccDescription:gt},Wt=s(t=>{xt(t,G),G.setDomains(t.domains),G.setTransitions(t.transitions)},"populate"),It={parse:s(async t=>{const e=await Bt("cynefin",t);O.debug(e),Wt(e)},"parse")};function E(t){let e=t+1831565813|0;return e=Math.imul(e^e>>>15,e|1),e^=e+Math.imul(e^e>>>7,e|61),((e^e>>>14)>>>0)/4294967296}s(E,"seededRandom");function st(t){let e=0;for(let n=0;n<t.length;n++){const a=t.charCodeAt(n);e=(e<<5)-e+a,e|=0}return e}s(st,"hashString");function it(t,e){return typeof t=="number"&&Number.isFinite(t)&&t!==0?t:st(e)}s(it,"resolveSeed");function ct(t,e,n,a){const c=t/2,m=a??t*.015,v=7,I=e/v,d=[];for(let o=0;o<=v;o++){const p=E(n+o*17)*m*2-m;d.push({x:c+p,y:o*I})}let D=`M${d[0].x},${d[0].y}`;for(let o=0;o<d.length-1;o++){const p=d[o],i=d[o+1],f=(p.y+i.y)/2,b=o%2===0?1:-1,h=m*1.5*b*E(n+o*31+7),R=p.x+h,V=f,_=i.x-h;D+=` C${R},${V} ${_},${f} ${i.x},${i.y}`}return D}s(ct,"generateFoldPath");function lt(t,e,n,a){const c=e/2,m=a??e*.015,v=7,I=t/v,d=[];for(let o=0;o<=v;o++){const p=E(n+o*23)*m*2-m;d.push({x:o*I,y:c+p})}let D=`M${d[0].x},${d[0].y}`;for(let o=0;o<d.length-1;o++){const p=d[o],i=d[o+1],f=(p.x+i.x)/2,b=o%2===0?1:-1,h=m*1.5*b*E(n+o*37+11),R=f,V=p.y+h,_=f,z=i.y-h;D+=` C${R},${V} ${_},${z} ${i.x},${i.y}`}return D}s(lt,"generateHorizontalBoundary");function dt(t,e){const n=t/2,a=e*.5,c=e,m=t*.03;return[`M${n},${a}`,`C${n+m},${a+(c-a)*.2}`,`${n-m*1.5},${a+(c-a)*.55}`,`${n+m*.5},${a+(c-a)*.75}`,`C${n-m},${a+(c-a)*.85}`,`${n+m*.3},${a+(c-a)*.95}`,`${n},${c}`].join(" ")}s(dt,"generateCliffPath");function ft(t,e,n,a){return[`M${t-n},${e}`,`A${n},${a} 0 1,1 ${t+n},${e}`,`A${n},${a} 0 1,1 ${t-n},${e}`,"Z"].join(" ")}s(ft,"generateConfusionPath");var at={complex:{model:"Probe → Sense → Respond",practice:"Emergent Practices"},complicated:{model:"Sense → Analyse → Respond",practice:"Good Practices"},clear:{model:"Sense → Categorise → Respond",practice:"Best Practices"},chaotic:{model:"Act → Sense → Respond",practice:"Novel Practices"},confusion:{model:"",practice:"Disorder"}},Rt=s((t,e)=>{const n=t/2,a=e/2;return{complex:{cx:n/2,cy:a/2,x:0,y:0,w:n,h:a},complicated:{cx:n+n/2,cy:a/2,x:n,y:0,w:n,h:a},chaotic:{cx:n/2,cy:a+a/2,x:0,y:a,w:n,h:a},clear:{cx:n+n/2,cy:a+a/2,x:n,y:a,w:n,h:a},confusion:{cx:n,cy:a,x:n*.7,y:a*.7,w:n*.6,h:a*.6}}},"getDomainLayouts"),Vt=s(()=>{const t=ot(),e=Z();return U(t,e.themeVariables).cynefin},"getCynefinDomainColors"),q=3,_t=s((t,e,n,a)=>{const c=a.db,m=c.getDomains(),v=c.getTransitions(),I=c.getDiagramTitle(),d=c.getAccTitle(),D=c.getAccDescription(),o=c.getConfig(),p=Vt();O.debug("Rendering Cynefin diagram");const i=o.width,f=o.height,b=o.padding,h=o.showDomainDescriptions,R=o.boundaryAmplitude,V=i+b*2,_=f+b*2,z={complex:p.complexBg,complicated:p.complicatedBg,clear:p.clearBg,chaotic:p.chaoticBg,confusion:p.confusionBg},k=Dt(e);kt(k,_,V,o.useMaxWidth??!0),k.attr("viewBox",`0 0 ${V} ${_}`),d&&k.append("title").text(d),D&&k.append("desc").text(D);const T=k.append("g").attr("transform",`translate(${b}, ${b})`),F=Rt(i,f),Q=it(o.seed,e),mt=T.append("g").attr("class","cynefin-backgrounds"),X=["complex","complicated","chaotic","clear"];for(const l of X){const r=F[l];mt.append("rect").attr("class","cynefinDomain").attr("x",r.x).attr("y",r.y).attr("width",r.w).attr("height",r.h).attr("fill",z[l]).attr("fill-opacity",.4).attr("stroke","none")}const j=T.append("g").attr("class","cynefin-boundaries");j.append("path").attr("class","cynefinBoundary").attr("d",ct(i,f,Q,R)).attr("fill","none"),j.append("path").attr("class","cynefinBoundary").attr("d",lt(i,f,Q+100,R)).attr("fill","none"),j.append("path").attr("class","cynefinCliff").attr("d",dt(i,f)).attr("fill","none");const pt=i*.15,yt=f*.15;T.append("path").attr("class","cynefinConfusion").attr("d",ft(i/2,f/2,pt,yt)).attr("fill",z.confusion).attr("fill-opacity",.5);const J=T.append("g").attr("class","cynefin-labels");for(const l of X){const r=F[l];J.append("text").attr("class","cynefinDomainLabel").attr("x",r.cx).attr("y",h?r.cy-30:r.cy).attr("text-anchor","middle").attr("dominant-baseline","middle").text(l.charAt(0).toUpperCase()+l.slice(1))}if(J.append("text").attr("class","cynefinDomainLabel").attr("x",i/2).attr("y",h?f/2-10:f/2).attr("text-anchor","middle").attr("dominant-baseline","middle").text("Confusion"),h){const l=T.append("g").attr("class","cynefin-subtitles");for(const r of X){const u=F[r],y=at[r];l.append("text").attr("class","cynefinSubtitle").attr("x",u.cx).attr("y",u.cy-10).attr("text-anchor","middle").attr("dominant-baseline","middle").text(y.model),l.append("text").attr("class","cynefinSubtitle").attr("x",u.cx).attr("y",u.cy+5).attr("text-anchor","middle").attr("dominant-baseline","middle").text(y.practice)}l.append("text").attr("class","cynefinSubtitle").attr("x",i/2).attr("y",f/2+8).attr("text-anchor","middle").attr("dominant-baseline","middle").text(at.confusion.practice)}const K=T.append("g").attr("class","cynefin-items"),A=26,tt=10,ut=["complex","complicated","chaotic","clear","confusion"];for(const l of ut){const r=m.get(l);if(!r||r.items.length===0)continue;const u=F[l],y=l==="confusion";let L=r.items,N=0;y&&r.items.length>q&&(N=r.items.length-q,L=r.items.slice(0,q));let B;if(y){const g=h?22:14;B=u.cy+g}else B=u.cy+(h?25:15);if([...L].forEach((g,S)=>{const w=B+S*(A+4),M=K.append("g"),P=M.append("text").attr("class","cynefinItemText").attr("x",0).attr("y",A/2).attr("text-anchor","middle").attr("dominant-baseline","central").text(g.label);let $=g.label.length*7;const x=P.node();if(x&&typeof x.getBBox=="function"){const Y=x.getBBox();Y.width>0&&($=Y.width)}const C=$+tt*2,W=u.cx-C/2;M.attr("transform",`translate(${W}, ${w})`),M.insert("rect","text").attr("class","cynefinItem").attr("x",0).attr("y",0).attr("width",C).attr("height",A).attr("rx",4).attr("ry",4).attr("fill",z[l]).attr("fill-opacity",.95),P.attr("x",C/2).attr("y",A/2)}),N>0){const g=B+L.length*(A+4),S=`+${N} more`,w=K.append("g"),M=w.append("text").attr("class","cynefinItemText").attr("x",0).attr("y",A/2).attr("text-anchor","middle").attr("dominant-baseline","central").text(S);let P=S.length*7;const $=M.node();if($&&typeof $.getBBox=="function"){const W=$.getBBox();W.width>0&&(P=W.width)}const x=P+tt*2,C=u.cx-x/2;w.attr("transform",`translate(${C}, ${g})`),w.insert("rect","text").attr("class","cynefinItemOverflow").attr("x",0).attr("y",0).attr("width",x).attr("height",A).attr("rx",4).attr("ry",4).attr("fill",z[l]).attr("fill-opacity",.6),M.attr("x",x/2).attr("y",A/2)}}if(v.length>0){const l=k.select("defs").empty()?k.append("defs"):k.select("defs"),r=`cynefin-arrow-${e}`;l.append("marker").attr("id",r).attr("viewBox","0 0 10 10").attr("refX",9).attr("refY",5).attr("markerWidth",6).attr("markerHeight",6).attr("orient","auto-start-reverse").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","cynefinArrowHead");const u=T.append("g").attr("class","cynefin-arrows");v.forEach(y=>{const L=F[y.from],N=F[y.to];if(!L||!N)return;if(y.from===y.to){O.warn(`Cynefin renderer: skipping self-loop on domain "${y.from}"`);return}const B=L.cx,g=L.cy,S=N.cx,w=N.cy,M=(B+S)/2,P=(g+w)/2,$=S-B,x=w-g,C=Math.sqrt($*$+x*x),W=C*.15,Y=-x/C,ht=$/C,et=M+Y*W,nt=P+ht*W;u.append("path").attr("class","cynefinArrowLine").attr("d",`M${B},${g} Q${et},${nt} ${S},${w}`).attr("fill","none").attr("marker-end",`url(#${r})`),y.label&&u.append("text").attr("class","cynefinArrowLabel").attr("x",et).attr("y",nt-6).attr("text-anchor","middle").attr("dominant-baseline","auto").text(y.label)})}I&&T.append("text").attr("class","cynefinTitle").attr("x",i/2).attr("y",-b/2).attr("text-anchor","middle").attr("dominant-baseline","middle").text(I)},"draw"),Ft={draw:_t},Et=s(()=>{const t=ot(),e=Z();return U(t,e.themeVariables).cynefin},"getCynefinTheme"),Ht=s(()=>{const t=Et();return`
|
|
2
2
|
.cynefinDomain {
|
|
3
3
|
stroke: none;
|
|
4
4
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{c as t,s as r}from"./
|
|
1
|
+
import{c as t,s as r}from"./CQfllnM7.js";import{b as a}from"./BOi9rcQa.js";var s=a(e=>`${r(e)}
|
|
2
2
|
.swimlane.cluster:not([data-color-id]) rect {
|
|
3
3
|
stroke: ${e.clusterBorder} !important;
|
|
4
4
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t as W,bo as l,bm as u,bw as F,b as G,bs as re,bq as se}from"./Fcr7AvC-.js";import{bs as K,a5 as P,bl as w,bS as m,bA as $,be as z,b$ as N,b_ as k,bO as _,W as v,aD as ae,bn as L,aA as p,c9 as ne,aB as B,c5 as J,a7 as oe,ay as ie}from"./3SdAC2_C.js";import{i as q}from"./BhYXv0ZM.js";import{s as R}from"./BRCr02in.js";import{f as A}from"./Beq_QLuz.js";import"./BAtAwQ72.js";import{D as ce}from"./CdtwTpzR.js";import{a3 as de}from"./
|
|
1
|
+
import{t as W,bo as l,bm as u,bw as F,b as G,bs as re,bq as se}from"./Fcr7AvC-.js";import{bs as K,a5 as P,bl as w,bS as m,bA as $,be as z,b$ as N,b_ as k,bO as _,W as v,aD as ae,bn as L,aA as p,c9 as ne,aB as B,c5 as J,a7 as oe,ay as ie}from"./3SdAC2_C.js";import{i as q}from"./BhYXv0ZM.js";import{s as R}from"./BRCr02in.js";import{f as A}from"./Beq_QLuz.js";import"./BAtAwQ72.js";import{D as ce}from"./CdtwTpzR.js";import{a3 as de}from"./GM6GOclC.js";import{JH as ue,j2 as le}from"./D0qhIm1r.js";var pe=B('<p class="text-sm text-muted-foreground"> </p>'),T=B('<p role="status" class="text-sm"> </p>'),ge=B('<div class="flex max-h-[min(calc(100dvh-8rem),calc(var(--toast-max-height,100dvh)-2rem))] min-h-0 min-w-0 flex-col gap-3" role="group"><div class="min-h-0 space-y-3 overflow-y-auto break-words" role="region" tabindex="0"><p class="font-medium break-words"> </p> <p class="text-sm text-muted-foreground"> </p> <!> <!> <!> <!></div> <div class="flex shrink-0 flex-wrap gap-2"><!> <!> <!></div></div>');function M(y,r){if(new.target)return W({component:M,...y});K(r,!0);let a=l(r,"request",7),g=l(r,"pending",7,!1),b=l(r,"settingUp",7,!1),c=l(r,"guidance",7),d=l(r,"checklist",7),i=l(r,"onDecision",7);var C={get request(){return a()},set request(e){a(e),p()},get pending(){return g()},set pending(e=!1){g(e),p()},get settingUp(){return b()},set settingUp(e=!1){b(e),p()},get guidance(){return c()},set guidance(e){c(e),p()},get checklist(){return d()},set checklist(e){d(e),p()},get onDecision(){return i()},set onDecision(e){i(e),p()},$set:F,$on:(e,t)=>G(r,e,t)},x=ge(),f=P(x),I=P(f),U=w(I,!0),D=m(I,2),n=w(D,!0),h=m(D,2);{var Q=e=>{var t=pe(),s=w(t,!0);k(o=>_(s,o),[()=>u.desktop_consent_claimPrimary({computer:a().computerName})]),v(e,t)};q(h,e=>{a().claimsPrimary&&e(Q)})}var O=m(h,2);{var V=e=>{ce(e,{get checklist(){return d()}})};q(O,e=>{d()&&e(V)})}var S=m(O,2);{var X=e=>{var t=T(),s=w(t,!0);k(()=>_(s,c())),v(e,t)};q(S,e=>{c()&&e(X)})}var Y=m(S,2);{var Z=e=>{var t=T(),s=w(t,!0);k(o=>_(s,o),[()=>u.desktop_consent_pending()]),v(e,t)};q(Y,e=>{g()&&!b()&&e(Z)})}$(f);var j=m(f,2),E=P(j);A(E,{size:"compact",variant:"primary",get disabled(){return g()},onclick:()=>i()("allow_once"),children:(e,t)=>{z();var s=N();k(o=>_(s,o),[()=>u.desktop_consent_once()]),v(e,s)},$$slots:{default:!0}});var H=m(E,2);A(H,{size:"compact",variant:"outline",get disabled(){return g()},onclick:()=>i()("allow_future"),children:(e,t)=>{z();var s=N();k(o=>_(s,o),[()=>u.desktop_consent_future()]),v(e,s)},$$slots:{default:!0}});var ee=m(H,2);{let e=ne(()=>g()&&!b());A(ee,{size:"compact",variant:"ghost",get disabled(){return ae(e)},onclick:()=>i()("deny"),children:(t,s)=>{z();var o=N();k(te=>_(o,te),[()=>u.desktop_consent_deny()]),v(t,o)},$$slots:{default:!0}})}return $(j),$(x),k((e,t,s,o)=>{R(x,"aria-label",e),R(f,"aria-label",t),_(U,s),_(n,o)},[()=>u.desktop_consent_title(),()=>u.desktop_consent_title(),()=>u.desktop_consent_request({agent:a().agentName,computer:a().computerName}),()=>u.desktop_consent_description()]),v(y,x),L(C)}function me(y,r){if(new.target)return W({component:me,...y});K(r,!0);const a=()=>re(C,"$entry",g),[g,b]=se();let c=l(r,"workspaceId",7),d=l(r,"agentId",7),i=l(r,"requestId",7);const C=de(J(()=>c()),J(()=>d()));var x={get workspaceId(){return c()},set workspaceId(n){c(n),p()},get agentId(){return d()},set agentId(n){d(n),p()},get requestId(){return i()},set requestId(n){i(n),p()},$set:F,$on:(n,h)=>G(r,n,h)},f=oe(),I=ie(f);{var U=n=>{M(n,{get request(){return a().pending},get pending(){return a().submitting},get settingUp(){return a().settingUp},get guidance(){return a().error},get checklist(){return a().osChecklist},onDecision:h=>ue.dispatch(le(c(),d(),i(),h))})};q(I,n=>{a()?.pending?.requestId===i()&&n(U)})}v(y,f);var D=L(x);return b(),D}export{me as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t as ht,bo as U,bw as $t,bq as It,b as bt,bs as r}from"./Fcr7AvC-.js";import{bs as yt,ca as k,aD as t,c9 as s,a7 as Ct,ay as Rt,W as kt,bn as wt,bH as H,bV as K,aA as E}from"./3SdAC2_C.js";import{k as At}from"./Cc0763mU.js";import{b as St}from"./Dn334wJv.js";import{JH as a,eK as Dt,eL as Pt,ol as Ut,Ad as Et,op as _t,oq as Tt,Kf as Ft,Ku as xt,Kk as Wt,vM as qt,v1 as vt}from"./D0qhIm1r.js";import{t as Ht}from"./C-BsEdGZ.js";import{g as Kt}from"./DWGXN6Nr.js";import{dI as Lt,b$ as Nt,bQ as Ot,bU as Bt,bS as Mt}from"./cD292w1o.js";import{af as Gt}from"./
|
|
1
|
+
import{t as ht,bo as U,bw as $t,bq as It,b as bt,bs as r}from"./Fcr7AvC-.js";import{bs as yt,ca as k,aD as t,c9 as s,a7 as Ct,ay as Rt,W as kt,bn as wt,bH as H,bV as K,aA as E}from"./3SdAC2_C.js";import{k as At}from"./Cc0763mU.js";import{b as St}from"./Dn334wJv.js";import{JH as a,eK as Dt,eL as Pt,ol as Ut,Ad as Et,op as _t,oq as Tt,Kf as Ft,Ku as xt,Kk as Wt,vM as qt,v1 as vt}from"./D0qhIm1r.js";import{t as Ht}from"./C-BsEdGZ.js";import{g as Kt}from"./DWGXN6Nr.js";import{dI as Lt,b$ as Nt,bQ as Ot,bU as Bt,bS as Mt}from"./cD292w1o.js";import{af as Gt}from"./zV7CDVYO.js";import{C as Vt}from"./C9SWwe2v.js";import{V as jt}from"./CDtaIFAl.js";import{bT as Jt,bN as Qt,b8 as zt}from"./fjEL_jqG.js";import{i as Xt}from"./H2jLkRRS.js";function Yt(_,f){if(new.target)return ht({component:Yt,..._});yt(f,!0);const L=()=>r(Z,"$gitRoots$",n),T=()=>r(Y,"$workspace",n),N=()=>r(st,"$ftCommits$",n),O=()=>r(ot,"$ftOlderCommits$",n),y=()=>r(tt,"$commitRead$",n),B=()=>r(z,"$foldUnchanged",n),M=()=>r(Q,"$lineWrapping",n),G=()=>r(X,"$diffSideBySide",n),V=()=>r(at,"$ftLoading$",n),[n,j]=It(),J=e=>{jt(e,{embedded:!0,showExpand:!0,get expanded(){return t(C)},onToggleExpand:()=>{H(C,!t(C)),t(C)?t(R)?.expandAll():t(R)?.collapseAll()},get foldEnabled(){return B()},onToggleFold:()=>a.dispatch(Wt()),get wrapEnabled(){return M()},onToggleWrap:()=>a.dispatch(xt()),get splitEnabled(){return G()},onToggleSplit:()=>a.dispatch(Ft())})},Q=Jt(),z=Qt(),X=zt();let h=U(f,"tab",7),i=U(f,"workspaceId",7),$=U(f,"isActive",7);const F=Kt(),g=Ht(()=>i()),Y=Lt(g),Z=Gt(g),w=crypto.randomUUID(),tt=Nt(g,w),c=s(()=>h().data?.commitHash||""),x=s(()=>h().data?.commitMessage||"");k(()=>{const e=i();if(!(!$()||!e||t(d)))return a.dispatch(Dt(e,"history")),()=>a.dispatch(Pt(e,"history"))});const d=s(()=>h().data?.gitRootId||""),W=s(()=>t(d)&&L().find(e=>e.id===t(d))?.path||""),et=s(()=>t(W)||T()?.worktreePath||T()?.repositoryPath||""),st=Ot(g),ot=Bt(g),at=Mt(g),nt=s(()=>N()||[]),it=s(()=>O()||[]),p=s(()=>t(d)?void 0:t(nt).find(e=>e.hash===t(c))||t(it).find(e=>e.hash===t(c))),A=s(()=>t(p)?.files||[]),S=s(()=>y()?.request.kind==="commitDetails"&&y().request.commitHash===t(c)&&(y().request.gitRootId??"")===t(d)?y():void 0),l=s(()=>t(S)?.result?.kind==="commitDetails"?t(S).result.details:null),dt=s(()=>t(l)?t(l).fileDetails.length>0?t(l).fileDetails:t(l).files.map(e=>({path:e,additions:0,deletions:0})):[]),rt=s(()=>t(S)?.loading??!1);k(()=>{const e=t(c),o=i(),I=t(d);if(!e||!o||t(A).length>0)return;const u=crypto.randomUUID();return a.dispatch(Ut(o,w,u,{kind:"commitDetails",commitHash:e,gitRootId:I||void 0})),()=>a.dispatch(Et(o,w,u))});const ct=s(()=>t(A).length>0?t(A):t(dt));let C=K(!0),R=K(null);const lt=s(()=>t(ct).map(e=>{const o=typeof e=="string"?e:e.path||"",I=typeof e=="string"?0:e.additions||0,u=typeof e=="string"?0:e.deletions||0;return{filePath:Xt(o)?o:`${t(et)}/${o}`,action:"modify",additions:I,deletions:u,toolName:"local",toolCallId:`commit-${t(c)}-${o}`,staged:!1,category:"committed",commitHash:t(c),commitMessage:t(x)}}));k(()=>{!F||!$()||F.registerActions({display:J})});const q=crypto.randomUUID();k(()=>{const e=i();if(!(!($()&&t(d))||!e))return a.dispatch(_t(e,q)),()=>a.dispatch(Tt(e,q))});var mt={get tab(){return h()},set tab(e){h(e),E()},get workspaceId(){return i()},set workspaceId(e){i(e),E()},get isActive(){return $()},set isActive(e){$(e),E()},$set:$t,$on:(e,o)=>bt(f,e,o)},v=Ct(),gt=Rt(v);At(gt,()=>JSON.stringify([i(),t(d),t(c)]),e=>{{let o=s(()=>V()||t(rt)),I=s(()=>t(d)||void 0),u=s(()=>t(W)||void 0),ut=s(()=>({hash:t(c),message:t(x),author:t(p)?.author||t(l)?.author,authorEmail:t(p)?.authorEmail||t(l)?.authorEmail,date:t(p)?.date||t(l)?.date,agentId:t(p)?.agentId,linkedNoteId:t(p)?.linkedNoteId}));St(Vt(e,{get isLoading(){return t(o)},get changes(){return t(lt)},get gitRootId(){return t(I)},get gitRootPath(){return t(u)},get commitInfo(){return t(ut)},onOpenAgent:(b,m)=>{const D=m?.metaKey||m?.ctrlKey||!1,P=m?.target?.closest("[data-panel-id]")?.getAttribute("data-panel-id")??void 0;a.dispatch(vt(i(),{agentId:b,openInAdjacentPanel:D,sourcePanelId:P}))},onOpenNote:(b,m)=>{const D=m?.metaKey||m?.ctrlKey||!1,P=m?.target?.closest("[data-panel-id]")?.getAttribute("data-panel-id")??void 0;a.dispatch(qt(i(),b,{openInAdjacentPanel:D,sourcePanelId:P}))}}),b=>H(R,b,!0),()=>t(R))}}),kt(_,v);var pt=wt(mt);return j(),pt}export{Yt as default};
|