@preventive/triage 1.0.0-alpha.42 → 1.0.0-alpha.44
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/common/bundle-compare-diff.js +2 -167
- package/common/bundle-compare-versions.js +172 -0
- package/common/bundle-comparison.d.ts +8 -0
- package/common/bundle-comparison.js +62 -0
- package/common/managed/report-filter.ts +2 -1
- package/common/managed/routes.js +3 -3
- package/common/security-links.d.ts +5 -0
- package/common/security-links.js +33 -0
- package/common/server-info.ts +8 -0
- package/common/workspace-app.js +14 -1
- package/out/chunk-2ABLKCOY.js +46 -0
- package/out/chunk-5LSXOLUS.js +1 -0
- package/out/chunk-5RCM2J63.js +1 -0
- package/out/chunk-7B6HB4D7.js +1 -0
- package/out/{chunk-4F6JSF57.js → chunk-AJ4GTATZ.js} +1 -1
- package/out/chunk-CH4UN6WK.js +225 -0
- package/out/chunk-EDKLBQQN.js +17 -0
- package/out/{chunk-UXNUAIIC.js → chunk-F47DXCEV.js} +1 -1
- package/out/chunk-FK3DZEKL.js +1 -0
- package/out/chunk-G6AJWENO.js +1 -0
- package/out/chunk-GZWM7UQM.js +2 -0
- package/out/chunk-JCIIBLKR.js +1 -0
- package/out/chunk-LPCTJYNA.js +7 -0
- package/out/{chunk-DGVQPIYB.js → chunk-O4RJY5TP.js} +1 -1
- package/out/chunk-OD4LPN3H.js +1 -0
- package/out/{chunk-D7AF2JXL.js → chunk-QWDWTBM7.js} +1 -1
- package/out/chunk-QYWKC557.js +1 -0
- package/out/chunk-R75XOKUP.js +1 -0
- package/out/{chunk-RSHMVYNS.js → chunk-SWTLADW5.js} +1 -1
- package/out/chunk-T7OKH4VW.js +1 -0
- package/out/{chunk-ZMQQCGF6.js → chunk-UTR2LVME.js} +1 -1
- package/out/chunk-ZESLQCTF.js +6 -0
- package/out/client-managed-import.js +1 -1
- package/out/client-managed.js +21 -21
- package/out/client-sync.js +1 -1
- package/out/graph.js +1 -1
- package/out/index.html +14 -10
- package/out/terminal.js +1 -1
- package/out/view.css +1 -1
- package/out/view.js +58 -58
- package/package.json +13 -3
- package/risk/index.d.ts +26 -0
- package/risk/index.js +1 -1
- package/risk/npm/assess.js +66 -15
- package/risk/npm/dependencies.js +22 -3
- package/risk/npm/new-dependency.js +42 -12
- package/risk/npm/registry.js +122 -21
- package/server-managed/comparison.ts +41 -0
- package/server-managed/http.ts +161 -56
- package/server-managed/locked-packages.ts +29 -6
- package/server-managed/npm-kept.ts +38 -14
- package/server-managed/npm-packages.ts +27 -13
- package/server-managed/npm-risk.ts +69 -11
- package/server-managed/pretty-print.ts +14 -9
- package/server-managed/public-workspace.ts +26 -8
- package/server-managed/queue.ts +23 -0
- package/server-managed/report-sources.ts +1 -1
- package/server-managed/repository-risk-assess.ts +105 -0
- package/server-managed/repository-risk-audit.ts +66 -0
- package/server-managed/repository-risk.ts +265 -209
- package/server-managed/scan-downloads.ts +87 -0
- package/server-managed/sql.ts +1 -1
- package/server-managed/team-app.ts +38 -14
- package/server-managed/team-reports.ts +6 -11
- package/server-managed/upstream-cache.ts +16 -0
- package/out/chunk-CLPKNNC7.js +0 -51
- package/out/chunk-Q7ZSIEHP.js +0 -1
- package/out/chunk-RFZQQXSG.js +0 -17
- package/out/chunk-VQJCXGIY.js +0 -7
- package/out/chunk-WOTMRDM3.js +0 -226
- package/out/chunk-WZDTZE64.js +0 -1
- package/out/chunk-YP2537WX.js +0 -1
- package/out/chunk-YQRVLRDH.js +0 -1
- package/out/chunk-YVZH5SHP.js +0 -1
- package/out/chunk-ZBBOBQ43.js +0 -1
package/out/client-sync.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as sr,b as ar,c as cr,d as lr,e as ur,f as fr,g as he,p as dr,u as Xt,v as gr}from"./chunk-VQJCXGIY.js";import{a as De,b as Oe,d as tr,e as je,f as ge,g as nr,h as rr}from"./chunk-W4J3MGLB.js";import{a as Yt}from"./chunk-GJ4IUCNS.js";import{a as or,b as ir}from"./chunk-PNHBZGDD.js";import{a as oe,c as We}from"./chunk-TUII34K2.js";import"./chunk-OOJM4CTU.js";function Zt(e){return e instanceof Uint8Array||ArrayBuffer.isView(e)&&e.constructor.name==="Uint8Array"&&"BYTES_PER_ELEMENT"in e&&e.BYTES_PER_ELEMENT===1}var bt=e=>e?`"${e}" `:"";function vt(e,t=""){if(typeof e!="boolean")throw new TypeError(bt(t)+"expected boolean, got type="+typeof e);return e}function Ce(e,t=""){if(typeof e!="number")throw new TypeError(bt(t)+"expected number, got "+typeof e);if(!Number.isSafeInteger(e)||e<0)throw new RangeError(bt(t)+"expected integer >= 0, got "+e);return e}function X(e,t,n=""){if(Zt(e)&&(t===void 0||e.length===t))return e;t!==void 0&&Ce(t,"length");let r=Zt(e),o=t!==void 0?` of length ${t}`:"",i=r?`length=${e.length}`:`type=${typeof e}`,s=bt(n)+"expected Uint8Array"+o+", got "+i;throw r?new RangeError(s):new TypeError(s)}var pr=(e,t)=>{if(e===null||typeof e!="object"||Array.isArray(e))throw new TypeError(t==="object"?"expected valid options object":`"${t}" expected object, got type=${typeof e}`)};function Qt(e,t=!0){if(e.destroyed)throw new Error("hash was destroyed");if(t&&e.finished)throw new Error("digest() was already called")}function yr(e,t){X(e,void 0,"output");let n=t.outputLen;if(!(e.length>=n))throw new RangeError('"output" expected length >= '+n)}function be(e){return new Uint32Array(e.buffer,e.byteOffset,Math.floor(e.byteLength/4))}function me(...e){for(let t=0;t<e.length;t++)e[t].fill(0)}function Mo(e){return new DataView(e.buffer,e.byteOffset,e.byteLength)}var Ae=new Uint8Array(new Uint32Array([287454020]).buffer)[0]===68;function Uo(e){return e<<24&4278190080|e<<8&16711680|e>>>8&65280|e>>>24&255}function Ko(e){for(let t=0;t<e.length;t++)e[t]=Uo(e[t]);return e}var ke=Ae?e=>e:Ko;function No(e,t){return!e.byteLength||!t.byteLength?!1:e.buffer===t.buffer&&e.byteOffset<t.byteOffset+t.byteLength&&t.byteOffset<e.byteOffset+e.byteLength}function hr(e,t){if(No(e,t)&&e.byteOffset<t.byteOffset)throw new Error("complex overlap of input and output is not supported")}function mr(e,t){return pr(e,"defaults"),pr(t,"opts"),Object.assign(e,t)}function wr(e,t){if(e=X(e),t=X(t),e.length!==t.length)return!1;let n=0;for(let r=0;r<e.length;r++)n|=e[r]^t[r];return n===0}function br(e,t,n){let r=t,o=n||(()=>[]),i=(a,u)=>r(u,...o(a)).update(a).digest(),s=r(new Uint8Array(e),...o(new Uint8Array(0)));return i.outputLen=s.outputLen,i.blockLen=s.blockLen,i.create=(a,...u)=>r(a,...u),i}var vr=(e,t)=>{function n(r,...o){if(X(r,void 0,"key"),e.nonceLength!==void 0){let h=o[0];X(h,e.varSizeNonce?void 0:e.nonceLength,"nonce")}let i=e.tagLength,s=e.nonceLength!==void 0?1:0;if(!e.withAAD){for(let h=s;h<o.length;h++)if(Zt(o[h]))throw new Error("AAD not supported")}e.withAAD&&o[s]!==void 0&&X(o[s],void 0,"AAD");let a=t(r,...o),u=(h,b)=>{if(b!==void 0){if(h!==2)throw new Error("cipher output not supported");X(b,void 0,"output")}},d=!1;return{encrypt(h,b){if(d)throw new Error("cannot encrypt() twice with same key + nonce");return d=!0,X(h,void 0,"data"),u(a.encrypt.length,b),a.encrypt(h,b)},decrypt(h,b){if(X(h,void 0,"data"),i&&h.length<i)throw new Error('"ciphertext" expected length >= tagLength='+i);return u(a.decrypt.length,b),a.decrypt(h,b)}}}return Object.assign(n,e),n};function Xe(e,t,n=!0){if(t===void 0)return new Uint8Array(e);if(X(t,e,"output"),n&&!Ze(t))throw new Error("invalid output, must be aligned");return t}function Sr(e,t,n){Ce(e),Ce(t),vt(n);let r=new Uint8Array(16),o=Mo(r);return o.setBigUint64(0,BigInt(t),n),o.setBigUint64(8,BigInt(e),n),r}function Ze(e){return e.byteOffset%4===0}function $e(e){return Uint8Array.from(X(e))}var Tr=e=>Uint8Array.from(e.split(""),t=>t.charCodeAt(0)),Io=ke(be(Tr("expand 16-byte k"))),Do=ke(be(Tr("expand 32-byte k")));function C(e,t){return e<<t|e>>>32-t}var Qe=64,Wo=16,en=2**32-1,kr=Uint32Array.of();function $o(e,t,n,r,o,i,s,a){let u=o.length,d=new Uint8Array(Qe),p=be(d),h=Ae&&Ze(o)&&Ze(i),b=h?be(o):kr,A=h?be(i):kr;if(!Ae){for(let y=0;y<u;s++){if(e(t,n,r,p,s,a),ke(p),s>=en)throw new Error("arx: counter overflow");let x=Math.min(Qe,u-y);for(let k=0,B;k<x;k++)B=y+k,i[B]=o[B]^d[k];y+=x}return}for(let y=0;y<u;s++){if(e(t,n,r,p,s,a),s>=en)throw new Error("arx: counter overflow");let x=Math.min(Qe,u-y);if(h&&x===Qe){let k=y/4;if(y%4!==0)throw new Error("arx: invalid block position");for(let B=0,P;B<Wo;B++)P=k+B,A[P]=b[P]^p[B];y+=Qe;continue}for(let k=0,B;k<x;k++)B=y+k,i[B]=o[B]^d[k];y+=x}}function xr(e,t){let{allowShortKeys:n,extendNonceFn:r,counterLength:o,counterRight:i,rounds:s}=mr({allowShortKeys:!1,counterLength:8,counterRight:!1,rounds:20},t);if(typeof e!="function")throw new Error("core must be a function");return Ce(o),Ce(s),vt(i),vt(n),(a,u,d,p,h=0)=>{X(a,void 0,"key"),X(u,void 0,"nonce"),X(d,void 0,"data");let b=d.length,A=p!==void 0;if(p=Xe(b,p,!1),A&&hr(d,p),Ce(h),h<0||h>=en)throw new Error("arx: counter overflow");let y=[],x=a.length,k,B;if(x===32)y.push(k=$e(a)),B=Do;else if(x===16&&n)k=new Uint8Array(32),k.set(a),k.set(a,16),B=Io,y.push(k);else throw X(a,32,"arx key"),new Error("invalid key size");(!Ae||!Ze(u))&&y.push(u=$e(u));let P=be(k);if(r){if(u.length!==24)throw new Error("arx: extended nonce must be 24 bytes");let Q=u.subarray(0,16);if(Ae)r(B,P,be(Q),P);else{let J=ke(Uint32Array.from(B));r(J,P,be(Q),P),me(J),ke(P)}u=u.subarray(16)}else Ae||ke(P);let Z=16-o;if(Z!==u.length)throw new Error(`arx: nonce must be ${Z} or 16 bytes`);if(Z!==12){let Q=new Uint8Array(12);Q.set(u,i?0:12-u.length),u=Q,y.push(u)}let ce=ke(be(u));try{return $o(e,B,P,ce,d,p,h,s),p}finally{me(...y)}}}function ne(e,t){return e[t++]&255|(e[t++]&255)<<8}var tn=class{blockLen=16;outputLen=16;buffer=new Uint8Array(16);r=new Uint16Array(10);h=new Uint16Array(10);pad=new Uint16Array(8);pos=0;finished=!1;destroyed=!1;constructor(t){t=$e(X(t,32,"key"));let n=ne(t,0),r=ne(t,2),o=ne(t,4),i=ne(t,6),s=ne(t,8),a=ne(t,10),u=ne(t,12),d=ne(t,14);this.r[0]=n&8191,this.r[1]=(n>>>13|r<<3)&8191,this.r[2]=(r>>>10|o<<6)&7939,this.r[3]=(o>>>7|i<<9)&8191,this.r[4]=(i>>>4|s<<12)&255,this.r[5]=s>>>1&8190,this.r[6]=(s>>>14|a<<2)&8191,this.r[7]=(a>>>11|u<<5)&8065,this.r[8]=(u>>>8|d<<8)&8191,this.r[9]=d>>>5&127;for(let p=0;p<8;p++)this.pad[p]=ne(t,16+2*p)}process(t,n,r=!1){let o=r?0:2048,{h:i,r:s}=this,a=s[0],u=s[1],d=s[2],p=s[3],h=s[4],b=s[5],A=s[6],y=s[7],x=s[8],k=s[9],B=ne(t,n+0),P=ne(t,n+2),Z=ne(t,n+4),ce=ne(t,n+6),Q=ne(t,n+8),J=ne(t,n+10),Y=ne(t,n+12),q=ne(t,n+14),$=i[0]+(B&8191),F=i[1]+((B>>>13|P<<3)&8191),I=i[2]+((P>>>10|Z<<6)&8191),U=i[3]+((Z>>>7|ce<<9)&8191),D=i[4]+((ce>>>4|Q<<12)&8191),W=i[5]+(Q>>>1&8191),_=i[6]+((Q>>>14|J<<2)&8191),j=i[7]+((J>>>11|Y<<5)&8191),K=i[8]+((Y>>>8|q<<8)&8191),N=i[9]+(q>>>5|o),T=0,z=T+$*a+F*(5*k)+I*(5*x)+U*(5*y)+D*(5*A);T=z>>>13,z&=8191,z+=W*(5*b)+_*(5*h)+j*(5*p)+K*(5*d)+N*(5*u),T+=z>>>13,z&=8191;let G=T+$*u+F*a+I*(5*k)+U*(5*x)+D*(5*y);T=G>>>13,G&=8191,G+=W*(5*A)+_*(5*b)+j*(5*h)+K*(5*p)+N*(5*d),T+=G>>>13,G&=8191;let H=T+$*d+F*u+I*a+U*(5*k)+D*(5*x);T=H>>>13,H&=8191,H+=W*(5*y)+_*(5*A)+j*(5*b)+K*(5*h)+N*(5*p),T+=H>>>13,H&=8191;let le=T+$*p+F*d+I*u+U*a+D*(5*k);T=le>>>13,le&=8191,le+=W*(5*x)+_*(5*y)+j*(5*A)+K*(5*b)+N*(5*h),T+=le>>>13,le&=8191;let we=T+$*h+F*p+I*d+U*u+D*a;T=we>>>13,we&=8191,we+=W*(5*k)+_*(5*x)+j*(5*y)+K*(5*A)+N*(5*b),T+=we>>>13,we&=8191;let g=T+$*b+F*h+I*p+U*d+D*u;T=g>>>13,g&=8191,g+=W*a+_*(5*k)+j*(5*x)+K*(5*y)+N*(5*A),T+=g>>>13,g&=8191;let f=T+$*A+F*b+I*h+U*p+D*d;T=f>>>13,f&=8191,f+=W*u+_*a+j*(5*k)+K*(5*x)+N*(5*y),T+=f>>>13,f&=8191;let l=T+$*y+F*A+I*b+U*h+D*p;T=l>>>13,l&=8191,l+=W*d+_*u+j*a+K*(5*k)+N*(5*x),T+=l>>>13,l&=8191;let w=T+$*x+F*y+I*A+U*b+D*h;T=w>>>13,w&=8191,w+=W*p+_*d+j*u+K*a+N*(5*k),T+=w>>>13,w&=8191;let c=T+$*k+F*x+I*y+U*A+D*b;T=c>>>13,c&=8191,c+=W*h+_*p+j*d+K*u+N*a,T+=c>>>13,c&=8191,T=(T<<2)+T|0,T=T+z|0,z=T&8191,T=T>>>13,G+=T,i[0]=z,i[1]=G,i[2]=H,i[3]=le,i[4]=we,i[5]=g,i[6]=f,i[7]=l,i[8]=w,i[9]=c}finalize(){let{h:t,pad:n}=this,r=new Uint16Array(10),o=t[1]>>>13;t[1]&=8191;for(let a=2;a<10;a++)t[a]+=o,o=t[a]>>>13,t[a]&=8191;t[0]+=o*5,o=t[0]>>>13,t[0]&=8191,t[1]+=o,o=t[1]>>>13,t[1]&=8191,t[2]+=o,r[0]=t[0]+5,o=r[0]>>>13,r[0]&=8191;for(let a=1;a<10;a++)r[a]=t[a]+o,o=r[a]>>>13,r[a]&=8191;r[9]-=8192;let i=(o^1)-1;for(let a=0;a<10;a++)r[a]&=i;i=~i;for(let a=0;a<10;a++)t[a]=t[a]&i|r[a];t[0]=(t[0]|t[1]<<13)&65535,t[1]=(t[1]>>>3|t[2]<<10)&65535,t[2]=(t[2]>>>6|t[3]<<7)&65535,t[3]=(t[3]>>>9|t[4]<<4)&65535,t[4]=(t[4]>>>12|t[5]<<1|t[6]<<14)&65535,t[5]=(t[6]>>>2|t[7]<<11)&65535,t[6]=(t[7]>>>5|t[8]<<8)&65535,t[7]=(t[8]>>>8|t[9]<<5)&65535;let s=t[0]+n[0];t[0]=s&65535;for(let a=1;a<8;a++)s=(t[a]+n[a]|0)+(s>>>16)|0,t[a]=s&65535;me(r)}update(t){Qt(this),X(t),t=$e(t);let{buffer:n,blockLen:r}=this,o=t.length;for(let i=0;i<o;){let s=Math.min(r-this.pos,o-i);if(s===r){for(;r<=o-i;i+=r)this.process(t,i);continue}n.set(t.subarray(i,i+s),this.pos),this.pos+=s,i+=s,this.pos===r&&(this.process(n,0,!1),this.pos=0)}return this}destroy(){this.destroyed=!0,me(this.h,this.r,this.buffer,this.pad)}digestInto(t){Qt(this),yr(t,this),this.finished=!0;let{buffer:n,h:r}=this,{pos:o}=this;if(o){for(n[o++]=1;o<16;o++)n[o]=0;this.process(n,0,!0)}this.finalize();let i=0;for(let s=0;s<8;s++)t[i++]=r[s]>>>0,t[i++]=r[s]>>>8}digest(){let{buffer:t,outputLen:n}=this;this.digestInto(t);let r=t.slice(0,n);return this.destroy(),r}},Ar=br(32,e=>new tn(e));function Fo(e,t,n,r,o,i=20){let s=e[0],a=e[1],u=e[2],d=e[3],p=t[0],h=t[1],b=t[2],A=t[3],y=t[4],x=t[5],k=t[6],B=t[7],P=o,Z=n[0],ce=n[1],Q=n[2],J=s,Y=a,q=u,$=d,F=p,I=h,U=b,D=A,W=y,_=x,j=k,K=B,N=P,T=Z,z=ce,G=Q;for(let le=0;le<i;le+=2)J=J+F|0,N=C(N^J,16),W=W+N|0,F=C(F^W,12),J=J+F|0,N=C(N^J,8),W=W+N|0,F=C(F^W,7),Y=Y+I|0,T=C(T^Y,16),_=_+T|0,I=C(I^_,12),Y=Y+I|0,T=C(T^Y,8),_=_+T|0,I=C(I^_,7),q=q+U|0,z=C(z^q,16),j=j+z|0,U=C(U^j,12),q=q+U|0,z=C(z^q,8),j=j+z|0,U=C(U^j,7),$=$+D|0,G=C(G^$,16),K=K+G|0,D=C(D^K,12),$=$+D|0,G=C(G^$,8),K=K+G|0,D=C(D^K,7),J=J+I|0,G=C(G^J,16),j=j+G|0,I=C(I^j,12),J=J+I|0,G=C(G^J,8),j=j+G|0,I=C(I^j,7),Y=Y+U|0,N=C(N^Y,16),K=K+N|0,U=C(U^K,12),Y=Y+U|0,N=C(N^Y,8),K=K+N|0,U=C(U^K,7),q=q+D|0,T=C(T^q,16),W=W+T|0,D=C(D^W,12),q=q+D|0,T=C(T^q,8),W=W+T|0,D=C(D^W,7),$=$+F|0,z=C(z^$,16),_=_+z|0,F=C(F^_,12),$=$+F|0,z=C(z^$,8),_=_+z|0,F=C(F^_,7);let H=0;r[H++]=s+J|0,r[H++]=a+Y|0,r[H++]=u+q|0,r[H++]=d+$|0,r[H++]=p+F|0,r[H++]=h+I|0,r[H++]=b+U|0,r[H++]=A+D|0,r[H++]=y+W|0,r[H++]=x+_|0,r[H++]=k+j|0,r[H++]=B+K|0,r[H++]=P+N|0,r[H++]=Z+T|0,r[H++]=ce+z|0,r[H++]=Q+G|0}var Ho=xr(Fo,{counterRight:!1,counterLength:4,allowShortKeys:!1});var _o=new Uint8Array(16),Er=(e,t)=>{e.update(t);let n=t.length%16;n&&e.update(_o.subarray(n))},zo=new Uint8Array(32);function Rr(e,t,n,r,o){o!==void 0&&X(o,void 0,"AAD");let i=e(t,n,zo),s=Sr(r.length,o?o.length:0,!0),a=Ar.create(i);o&&Er(a,o),Er(a,r),a.update(s);let u=a.digest();return me(i,s),u}var Vo=e=>(t,n,r)=>({encrypt(i,s){let a=i.length;s=Xe(a+16,s,!1),s.set(i);let u=s.subarray(0,-16);e(t,n,u,u,1);let d=Rr(e,t,n,u,r);return s.set(d,a),me(d),s},decrypt(i,s){s=Xe(i.length-16,s,!1);let a=i.subarray(0,-16),u=i.subarray(-16),d=Rr(e,t,n,a,r);if(!wr(u,d))throw me(d),new Error("invalid tag");return s.set(i.subarray(0,-16)),e(t,n,s,s,1),me(d),s}}),Fe=vr({blockSize:64,nonceLength:12,tagLength:16,withAAD:!0},Vo(Ho));var qo="deepview-triage-sync.v1.content-key",Go="deepview-triage-sync.v1.sign-key",Jo="deepview-triage-sync.v1.save",Yo="deepview-triage-sync.v1.subscribe",Xo=12,nn=new Uint8Array([48,46,2,1,0,48,5,6,3,43,101,112,4,34,4,32]),St=null;function Pr(){return St||(St=(async()=>{try{return await crypto.subtle.importKey("raw",new Uint8Array(32),{name:"ChaCha20-Poly1305"},!1,["encrypt","decrypt"]),!0}catch{return!1}})(),St)}async function Br(e,t){let n=Uint8Array.fromBase64(e);if(n.length!==32)throw new Error(`workspace private key must be 32 bytes (got ${n.length})`);let r=await crypto.subtle.importKey("raw",n,"HKDF",!1,["deriveBits"]),o=await crypto.subtle.deriveBits({name:"HKDF",hash:"SHA-256",salt:new Uint8Array,info:oe(t)},r,256);return new Uint8Array(o)}async function Or(e){return await Br(e,qo)}async function kt(e,t){let n=await Br(e,`${Go}|${t}`),r=new Uint8Array(nn.length+32);r.set(nn,0),r.set(n,nn.length);let o=await crypto.subtle.importKey("pkcs8",r,{name:"Ed25519"},!0,["sign"]),i=await crypto.subtle.exportKey("jwk",o),s=i.x;if(delete i.d,s==null)throw new Error("Ed25519 JWK export returned no public key");let a=Uint8Array.fromBase64(s,{alphabet:"base64url"}),u=await crypto.subtle.importKey("pkcs8",r,{name:"Ed25519"},!1,["sign"]);return n.fill(0),r.fill(0),{privateKey:u,publicKey:a,publicKeyB64:s}}function rn({publicKeyB64:e,base:t,keyframe:n,nonceB64:r,ciphertextB64:o}){return oe([Jo,e,t==null?"":String(t),n===!0?"1":"",r,o].join(`
|
|
1
|
+
import{a as sr,b as ar,c as cr,d as lr,e as ur,f as fr,g as he,p as dr,u as Xt,v as gr}from"./chunk-LPCTJYNA.js";import{a as De,b as Oe,d as tr,e as je,f as ge,g as nr,h as rr}from"./chunk-W4J3MGLB.js";import{a as Yt}from"./chunk-GJ4IUCNS.js";import{a as or,b as ir}from"./chunk-PNHBZGDD.js";import{a as oe,c as We}from"./chunk-TUII34K2.js";import"./chunk-OOJM4CTU.js";function Zt(e){return e instanceof Uint8Array||ArrayBuffer.isView(e)&&e.constructor.name==="Uint8Array"&&"BYTES_PER_ELEMENT"in e&&e.BYTES_PER_ELEMENT===1}var bt=e=>e?`"${e}" `:"";function vt(e,t=""){if(typeof e!="boolean")throw new TypeError(bt(t)+"expected boolean, got type="+typeof e);return e}function Ce(e,t=""){if(typeof e!="number")throw new TypeError(bt(t)+"expected number, got "+typeof e);if(!Number.isSafeInteger(e)||e<0)throw new RangeError(bt(t)+"expected integer >= 0, got "+e);return e}function X(e,t,n=""){if(Zt(e)&&(t===void 0||e.length===t))return e;t!==void 0&&Ce(t,"length");let r=Zt(e),o=t!==void 0?` of length ${t}`:"",i=r?`length=${e.length}`:`type=${typeof e}`,s=bt(n)+"expected Uint8Array"+o+", got "+i;throw r?new RangeError(s):new TypeError(s)}var pr=(e,t)=>{if(e===null||typeof e!="object"||Array.isArray(e))throw new TypeError(t==="object"?"expected valid options object":`"${t}" expected object, got type=${typeof e}`)};function Qt(e,t=!0){if(e.destroyed)throw new Error("hash was destroyed");if(t&&e.finished)throw new Error("digest() was already called")}function yr(e,t){X(e,void 0,"output");let n=t.outputLen;if(!(e.length>=n))throw new RangeError('"output" expected length >= '+n)}function be(e){return new Uint32Array(e.buffer,e.byteOffset,Math.floor(e.byteLength/4))}function me(...e){for(let t=0;t<e.length;t++)e[t].fill(0)}function Mo(e){return new DataView(e.buffer,e.byteOffset,e.byteLength)}var Ae=new Uint8Array(new Uint32Array([287454020]).buffer)[0]===68;function Uo(e){return e<<24&4278190080|e<<8&16711680|e>>>8&65280|e>>>24&255}function Ko(e){for(let t=0;t<e.length;t++)e[t]=Uo(e[t]);return e}var ke=Ae?e=>e:Ko;function No(e,t){return!e.byteLength||!t.byteLength?!1:e.buffer===t.buffer&&e.byteOffset<t.byteOffset+t.byteLength&&t.byteOffset<e.byteOffset+e.byteLength}function hr(e,t){if(No(e,t)&&e.byteOffset<t.byteOffset)throw new Error("complex overlap of input and output is not supported")}function mr(e,t){return pr(e,"defaults"),pr(t,"opts"),Object.assign(e,t)}function wr(e,t){if(e=X(e),t=X(t),e.length!==t.length)return!1;let n=0;for(let r=0;r<e.length;r++)n|=e[r]^t[r];return n===0}function br(e,t,n){let r=t,o=n||(()=>[]),i=(a,u)=>r(u,...o(a)).update(a).digest(),s=r(new Uint8Array(e),...o(new Uint8Array(0)));return i.outputLen=s.outputLen,i.blockLen=s.blockLen,i.create=(a,...u)=>r(a,...u),i}var vr=(e,t)=>{function n(r,...o){if(X(r,void 0,"key"),e.nonceLength!==void 0){let h=o[0];X(h,e.varSizeNonce?void 0:e.nonceLength,"nonce")}let i=e.tagLength,s=e.nonceLength!==void 0?1:0;if(!e.withAAD){for(let h=s;h<o.length;h++)if(Zt(o[h]))throw new Error("AAD not supported")}e.withAAD&&o[s]!==void 0&&X(o[s],void 0,"AAD");let a=t(r,...o),u=(h,b)=>{if(b!==void 0){if(h!==2)throw new Error("cipher output not supported");X(b,void 0,"output")}},d=!1;return{encrypt(h,b){if(d)throw new Error("cannot encrypt() twice with same key + nonce");return d=!0,X(h,void 0,"data"),u(a.encrypt.length,b),a.encrypt(h,b)},decrypt(h,b){if(X(h,void 0,"data"),i&&h.length<i)throw new Error('"ciphertext" expected length >= tagLength='+i);return u(a.decrypt.length,b),a.decrypt(h,b)}}}return Object.assign(n,e),n};function Xe(e,t,n=!0){if(t===void 0)return new Uint8Array(e);if(X(t,e,"output"),n&&!Ze(t))throw new Error("invalid output, must be aligned");return t}function Sr(e,t,n){Ce(e),Ce(t),vt(n);let r=new Uint8Array(16),o=Mo(r);return o.setBigUint64(0,BigInt(t),n),o.setBigUint64(8,BigInt(e),n),r}function Ze(e){return e.byteOffset%4===0}function $e(e){return Uint8Array.from(X(e))}var Tr=e=>Uint8Array.from(e.split(""),t=>t.charCodeAt(0)),Io=ke(be(Tr("expand 16-byte k"))),Do=ke(be(Tr("expand 32-byte k")));function C(e,t){return e<<t|e>>>32-t}var Qe=64,Wo=16,en=2**32-1,kr=Uint32Array.of();function $o(e,t,n,r,o,i,s,a){let u=o.length,d=new Uint8Array(Qe),p=be(d),h=Ae&&Ze(o)&&Ze(i),b=h?be(o):kr,A=h?be(i):kr;if(!Ae){for(let y=0;y<u;s++){if(e(t,n,r,p,s,a),ke(p),s>=en)throw new Error("arx: counter overflow");let x=Math.min(Qe,u-y);for(let k=0,B;k<x;k++)B=y+k,i[B]=o[B]^d[k];y+=x}return}for(let y=0;y<u;s++){if(e(t,n,r,p,s,a),s>=en)throw new Error("arx: counter overflow");let x=Math.min(Qe,u-y);if(h&&x===Qe){let k=y/4;if(y%4!==0)throw new Error("arx: invalid block position");for(let B=0,P;B<Wo;B++)P=k+B,A[P]=b[P]^p[B];y+=Qe;continue}for(let k=0,B;k<x;k++)B=y+k,i[B]=o[B]^d[k];y+=x}}function xr(e,t){let{allowShortKeys:n,extendNonceFn:r,counterLength:o,counterRight:i,rounds:s}=mr({allowShortKeys:!1,counterLength:8,counterRight:!1,rounds:20},t);if(typeof e!="function")throw new Error("core must be a function");return Ce(o),Ce(s),vt(i),vt(n),(a,u,d,p,h=0)=>{X(a,void 0,"key"),X(u,void 0,"nonce"),X(d,void 0,"data");let b=d.length,A=p!==void 0;if(p=Xe(b,p,!1),A&&hr(d,p),Ce(h),h<0||h>=en)throw new Error("arx: counter overflow");let y=[],x=a.length,k,B;if(x===32)y.push(k=$e(a)),B=Do;else if(x===16&&n)k=new Uint8Array(32),k.set(a),k.set(a,16),B=Io,y.push(k);else throw X(a,32,"arx key"),new Error("invalid key size");(!Ae||!Ze(u))&&y.push(u=$e(u));let P=be(k);if(r){if(u.length!==24)throw new Error("arx: extended nonce must be 24 bytes");let Q=u.subarray(0,16);if(Ae)r(B,P,be(Q),P);else{let J=ke(Uint32Array.from(B));r(J,P,be(Q),P),me(J),ke(P)}u=u.subarray(16)}else Ae||ke(P);let Z=16-o;if(Z!==u.length)throw new Error(`arx: nonce must be ${Z} or 16 bytes`);if(Z!==12){let Q=new Uint8Array(12);Q.set(u,i?0:12-u.length),u=Q,y.push(u)}let ce=ke(be(u));try{return $o(e,B,P,ce,d,p,h,s),p}finally{me(...y)}}}function ne(e,t){return e[t++]&255|(e[t++]&255)<<8}var tn=class{blockLen=16;outputLen=16;buffer=new Uint8Array(16);r=new Uint16Array(10);h=new Uint16Array(10);pad=new Uint16Array(8);pos=0;finished=!1;destroyed=!1;constructor(t){t=$e(X(t,32,"key"));let n=ne(t,0),r=ne(t,2),o=ne(t,4),i=ne(t,6),s=ne(t,8),a=ne(t,10),u=ne(t,12),d=ne(t,14);this.r[0]=n&8191,this.r[1]=(n>>>13|r<<3)&8191,this.r[2]=(r>>>10|o<<6)&7939,this.r[3]=(o>>>7|i<<9)&8191,this.r[4]=(i>>>4|s<<12)&255,this.r[5]=s>>>1&8190,this.r[6]=(s>>>14|a<<2)&8191,this.r[7]=(a>>>11|u<<5)&8065,this.r[8]=(u>>>8|d<<8)&8191,this.r[9]=d>>>5&127;for(let p=0;p<8;p++)this.pad[p]=ne(t,16+2*p)}process(t,n,r=!1){let o=r?0:2048,{h:i,r:s}=this,a=s[0],u=s[1],d=s[2],p=s[3],h=s[4],b=s[5],A=s[6],y=s[7],x=s[8],k=s[9],B=ne(t,n+0),P=ne(t,n+2),Z=ne(t,n+4),ce=ne(t,n+6),Q=ne(t,n+8),J=ne(t,n+10),Y=ne(t,n+12),q=ne(t,n+14),$=i[0]+(B&8191),F=i[1]+((B>>>13|P<<3)&8191),I=i[2]+((P>>>10|Z<<6)&8191),U=i[3]+((Z>>>7|ce<<9)&8191),D=i[4]+((ce>>>4|Q<<12)&8191),W=i[5]+(Q>>>1&8191),_=i[6]+((Q>>>14|J<<2)&8191),j=i[7]+((J>>>11|Y<<5)&8191),K=i[8]+((Y>>>8|q<<8)&8191),N=i[9]+(q>>>5|o),T=0,z=T+$*a+F*(5*k)+I*(5*x)+U*(5*y)+D*(5*A);T=z>>>13,z&=8191,z+=W*(5*b)+_*(5*h)+j*(5*p)+K*(5*d)+N*(5*u),T+=z>>>13,z&=8191;let G=T+$*u+F*a+I*(5*k)+U*(5*x)+D*(5*y);T=G>>>13,G&=8191,G+=W*(5*A)+_*(5*b)+j*(5*h)+K*(5*p)+N*(5*d),T+=G>>>13,G&=8191;let H=T+$*d+F*u+I*a+U*(5*k)+D*(5*x);T=H>>>13,H&=8191,H+=W*(5*y)+_*(5*A)+j*(5*b)+K*(5*h)+N*(5*p),T+=H>>>13,H&=8191;let le=T+$*p+F*d+I*u+U*a+D*(5*k);T=le>>>13,le&=8191,le+=W*(5*x)+_*(5*y)+j*(5*A)+K*(5*b)+N*(5*h),T+=le>>>13,le&=8191;let we=T+$*h+F*p+I*d+U*u+D*a;T=we>>>13,we&=8191,we+=W*(5*k)+_*(5*x)+j*(5*y)+K*(5*A)+N*(5*b),T+=we>>>13,we&=8191;let g=T+$*b+F*h+I*p+U*d+D*u;T=g>>>13,g&=8191,g+=W*a+_*(5*k)+j*(5*x)+K*(5*y)+N*(5*A),T+=g>>>13,g&=8191;let f=T+$*A+F*b+I*h+U*p+D*d;T=f>>>13,f&=8191,f+=W*u+_*a+j*(5*k)+K*(5*x)+N*(5*y),T+=f>>>13,f&=8191;let l=T+$*y+F*A+I*b+U*h+D*p;T=l>>>13,l&=8191,l+=W*d+_*u+j*a+K*(5*k)+N*(5*x),T+=l>>>13,l&=8191;let w=T+$*x+F*y+I*A+U*b+D*h;T=w>>>13,w&=8191,w+=W*p+_*d+j*u+K*a+N*(5*k),T+=w>>>13,w&=8191;let c=T+$*k+F*x+I*y+U*A+D*b;T=c>>>13,c&=8191,c+=W*h+_*p+j*d+K*u+N*a,T+=c>>>13,c&=8191,T=(T<<2)+T|0,T=T+z|0,z=T&8191,T=T>>>13,G+=T,i[0]=z,i[1]=G,i[2]=H,i[3]=le,i[4]=we,i[5]=g,i[6]=f,i[7]=l,i[8]=w,i[9]=c}finalize(){let{h:t,pad:n}=this,r=new Uint16Array(10),o=t[1]>>>13;t[1]&=8191;for(let a=2;a<10;a++)t[a]+=o,o=t[a]>>>13,t[a]&=8191;t[0]+=o*5,o=t[0]>>>13,t[0]&=8191,t[1]+=o,o=t[1]>>>13,t[1]&=8191,t[2]+=o,r[0]=t[0]+5,o=r[0]>>>13,r[0]&=8191;for(let a=1;a<10;a++)r[a]=t[a]+o,o=r[a]>>>13,r[a]&=8191;r[9]-=8192;let i=(o^1)-1;for(let a=0;a<10;a++)r[a]&=i;i=~i;for(let a=0;a<10;a++)t[a]=t[a]&i|r[a];t[0]=(t[0]|t[1]<<13)&65535,t[1]=(t[1]>>>3|t[2]<<10)&65535,t[2]=(t[2]>>>6|t[3]<<7)&65535,t[3]=(t[3]>>>9|t[4]<<4)&65535,t[4]=(t[4]>>>12|t[5]<<1|t[6]<<14)&65535,t[5]=(t[6]>>>2|t[7]<<11)&65535,t[6]=(t[7]>>>5|t[8]<<8)&65535,t[7]=(t[8]>>>8|t[9]<<5)&65535;let s=t[0]+n[0];t[0]=s&65535;for(let a=1;a<8;a++)s=(t[a]+n[a]|0)+(s>>>16)|0,t[a]=s&65535;me(r)}update(t){Qt(this),X(t),t=$e(t);let{buffer:n,blockLen:r}=this,o=t.length;for(let i=0;i<o;){let s=Math.min(r-this.pos,o-i);if(s===r){for(;r<=o-i;i+=r)this.process(t,i);continue}n.set(t.subarray(i,i+s),this.pos),this.pos+=s,i+=s,this.pos===r&&(this.process(n,0,!1),this.pos=0)}return this}destroy(){this.destroyed=!0,me(this.h,this.r,this.buffer,this.pad)}digestInto(t){Qt(this),yr(t,this),this.finished=!0;let{buffer:n,h:r}=this,{pos:o}=this;if(o){for(n[o++]=1;o<16;o++)n[o]=0;this.process(n,0,!0)}this.finalize();let i=0;for(let s=0;s<8;s++)t[i++]=r[s]>>>0,t[i++]=r[s]>>>8}digest(){let{buffer:t,outputLen:n}=this;this.digestInto(t);let r=t.slice(0,n);return this.destroy(),r}},Ar=br(32,e=>new tn(e));function Fo(e,t,n,r,o,i=20){let s=e[0],a=e[1],u=e[2],d=e[3],p=t[0],h=t[1],b=t[2],A=t[3],y=t[4],x=t[5],k=t[6],B=t[7],P=o,Z=n[0],ce=n[1],Q=n[2],J=s,Y=a,q=u,$=d,F=p,I=h,U=b,D=A,W=y,_=x,j=k,K=B,N=P,T=Z,z=ce,G=Q;for(let le=0;le<i;le+=2)J=J+F|0,N=C(N^J,16),W=W+N|0,F=C(F^W,12),J=J+F|0,N=C(N^J,8),W=W+N|0,F=C(F^W,7),Y=Y+I|0,T=C(T^Y,16),_=_+T|0,I=C(I^_,12),Y=Y+I|0,T=C(T^Y,8),_=_+T|0,I=C(I^_,7),q=q+U|0,z=C(z^q,16),j=j+z|0,U=C(U^j,12),q=q+U|0,z=C(z^q,8),j=j+z|0,U=C(U^j,7),$=$+D|0,G=C(G^$,16),K=K+G|0,D=C(D^K,12),$=$+D|0,G=C(G^$,8),K=K+G|0,D=C(D^K,7),J=J+I|0,G=C(G^J,16),j=j+G|0,I=C(I^j,12),J=J+I|0,G=C(G^J,8),j=j+G|0,I=C(I^j,7),Y=Y+U|0,N=C(N^Y,16),K=K+N|0,U=C(U^K,12),Y=Y+U|0,N=C(N^Y,8),K=K+N|0,U=C(U^K,7),q=q+D|0,T=C(T^q,16),W=W+T|0,D=C(D^W,12),q=q+D|0,T=C(T^q,8),W=W+T|0,D=C(D^W,7),$=$+F|0,z=C(z^$,16),_=_+z|0,F=C(F^_,12),$=$+F|0,z=C(z^$,8),_=_+z|0,F=C(F^_,7);let H=0;r[H++]=s+J|0,r[H++]=a+Y|0,r[H++]=u+q|0,r[H++]=d+$|0,r[H++]=p+F|0,r[H++]=h+I|0,r[H++]=b+U|0,r[H++]=A+D|0,r[H++]=y+W|0,r[H++]=x+_|0,r[H++]=k+j|0,r[H++]=B+K|0,r[H++]=P+N|0,r[H++]=Z+T|0,r[H++]=ce+z|0,r[H++]=Q+G|0}var Ho=xr(Fo,{counterRight:!1,counterLength:4,allowShortKeys:!1});var _o=new Uint8Array(16),Er=(e,t)=>{e.update(t);let n=t.length%16;n&&e.update(_o.subarray(n))},zo=new Uint8Array(32);function Rr(e,t,n,r,o){o!==void 0&&X(o,void 0,"AAD");let i=e(t,n,zo),s=Sr(r.length,o?o.length:0,!0),a=Ar.create(i);o&&Er(a,o),Er(a,r),a.update(s);let u=a.digest();return me(i,s),u}var Vo=e=>(t,n,r)=>({encrypt(i,s){let a=i.length;s=Xe(a+16,s,!1),s.set(i);let u=s.subarray(0,-16);e(t,n,u,u,1);let d=Rr(e,t,n,u,r);return s.set(d,a),me(d),s},decrypt(i,s){s=Xe(i.length-16,s,!1);let a=i.subarray(0,-16),u=i.subarray(-16),d=Rr(e,t,n,a,r);if(!wr(u,d))throw me(d),new Error("invalid tag");return s.set(i.subarray(0,-16)),e(t,n,s,s,1),me(d),s}}),Fe=vr({blockSize:64,nonceLength:12,tagLength:16,withAAD:!0},Vo(Ho));var qo="deepview-triage-sync.v1.content-key",Go="deepview-triage-sync.v1.sign-key",Jo="deepview-triage-sync.v1.save",Yo="deepview-triage-sync.v1.subscribe",Xo=12,nn=new Uint8Array([48,46,2,1,0,48,5,6,3,43,101,112,4,34,4,32]),St=null;function Pr(){return St||(St=(async()=>{try{return await crypto.subtle.importKey("raw",new Uint8Array(32),{name:"ChaCha20-Poly1305"},!1,["encrypt","decrypt"]),!0}catch{return!1}})(),St)}async function Br(e,t){let n=Uint8Array.fromBase64(e);if(n.length!==32)throw new Error(`workspace private key must be 32 bytes (got ${n.length})`);let r=await crypto.subtle.importKey("raw",n,"HKDF",!1,["deriveBits"]),o=await crypto.subtle.deriveBits({name:"HKDF",hash:"SHA-256",salt:new Uint8Array,info:oe(t)},r,256);return new Uint8Array(o)}async function Or(e){return await Br(e,qo)}async function kt(e,t){let n=await Br(e,`${Go}|${t}`),r=new Uint8Array(nn.length+32);r.set(nn,0),r.set(n,nn.length);let o=await crypto.subtle.importKey("pkcs8",r,{name:"Ed25519"},!0,["sign"]),i=await crypto.subtle.exportKey("jwk",o),s=i.x;if(delete i.d,s==null)throw new Error("Ed25519 JWK export returned no public key");let a=Uint8Array.fromBase64(s,{alphabet:"base64url"}),u=await crypto.subtle.importKey("pkcs8",r,{name:"Ed25519"},!1,["sign"]);return n.fill(0),r.fill(0),{privateKey:u,publicKey:a,publicKeyB64:s}}function rn({publicKeyB64:e,base:t,keyframe:n,nonceB64:r,ciphertextB64:o}){return oe([Jo,e,t==null?"":String(t),n===!0?"1":"",r,o].join(`
|
|
2
2
|
`))}async function jr(e,t){let n=await crypto.subtle.sign({name:"Ed25519"},e,t);return new Uint8Array(n).toBase64({alphabet:"base64url",omitPadding:!0})}async function Cr(e,t){return await jr(e,rn(t))}async function on(e){let t=rn(e),n=await crypto.subtle.digest("SHA-256",t);return new Uint8Array(n).toBase64({alphabet:"base64url",omitPadding:!0})}function Zo(e,t,n){let r=t==null?"":String(t);return oe([Yo,e,r,n].join(`
|
|
3
3
|
`))}async function Lr(e,t,n,r){return await jr(e,Zo(t,n,r))}async function Mr(e,t,n){try{let r=await crypto.subtle.importKey("raw",e,{name:"Ed25519"},!1,["verify"]),o=Uint8Array.fromBase64(n,{alphabet:"base64url"}),i=rn(t);return await crypto.subtle.verify({name:"Ed25519"},r,o,i)}catch{return!1}}function Qo(){let e=new Uint8Array(Xo);return crypto.getRandomValues(e),e}function sn(e,t){let n=t==null?"":String(t);return oe(`${e}|${n}`)}async function ei(e,t,n){let r=Qo();if(await Pr()){let i=await crypto.subtle.importKey("raw",e,{name:"ChaCha20-Poly1305"},!1,["encrypt"]),s=new Uint8Array(await crypto.subtle.encrypt({name:"ChaCha20-Poly1305",iv:r,additionalData:n},i,t));return{nonce:r,ciphertext:s}}let o=Fe(e,r,n);return{nonce:r,ciphertext:o.encrypt(t)}}async function ti(e,t,n,r){if(await Pr()){let i=await crypto.subtle.importKey("raw",e,{name:"ChaCha20-Poly1305"},!1,["decrypt"]);return new Uint8Array(await crypto.subtle.decrypt({name:"ChaCha20-Poly1305",iv:t,additionalData:r},i,n))}return Fe(e,t,r).decrypt(n)}var ni=64;function ri(e,t){return e<=t?t:2**(32-Math.clz32(e-1))}async function oi(e){let t=oe(JSON.stringify(e)),n=await or(t);if(n.length>1073741820)throw new Error("payload too large");let r=ri(4+n.length,ni),o=new Uint8Array(r);return new DataView(o.buffer,o.byteOffset,o.byteLength).setUint32(0,n.length,!1),o.set(n,4),o}var ii=64*1024*1024;async function si(e){if(e.length<4)throw new Error("plaintext too short");let n=new DataView(e.buffer,e.byteOffset,e.byteLength).getUint32(0,!1);if(n+4>e.length)throw new Error("length prefix exceeds buffer");let r=e.subarray(4,4+n),o=await ir(r,{maxBytes:ii});return JSON.parse(We(o))}async function Ur(e,t,n){let r=await oi(t),{nonce:o,ciphertext:i}=await ei(e,r,n);return{nonce:o.toBase64(),ciphertext:i.toBase64()}}async function Kr(e,t,n,r){let o=Uint8Array.fromBase64(t),i=Uint8Array.fromBase64(n),s=await ti(e,o,i,r);return si(s)}var ai="deepview-objstore.v1.content",ci="deepview-objstore.v1.tag",li=`objstore-tag
|
|
4
4
|
`,ui=`objstore-bundle-tag
|
package/out/graph.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{$ as z,C as Ct,a as de,aa as Eo,b as Qt,ba as Pe,fa as ht,la as Bo,ma as Ce,na as Ke,pa as se,qa as Ze,z as Oo}from"./chunk-UXNUAIIC.js";import{a as Ie}from"./chunk-R5O6FAW4.js";import{b as ie,c as Ao,d as ze}from"./chunk-CMQA4DM6.js";import"./chunk-4F6JSF57.js";import"./chunk-V3ME6FI5.js";import{h as $e}from"./chunk-YVZH5SHP.js";import{a as Lo}from"./chunk-4XCDFGDP.js";import"./chunk-3BZ7JERB.js";import{a as Ye}from"./chunk-TZ5KB2Y5.js";import"./chunk-XYFXXB2G.js";import{a as ve}from"./chunk-DIJJNTRH.js";import"./chunk-WZDTZE64.js";import{j as Yt}from"./chunk-GNXOKIGP.js";import"./chunk-C4Z6ZBXV.js";import{a as Pt,c as I,i as oe,j as ce}from"./chunk-2XUEZHIP.js";import"./chunk-TUII34K2.js";import{f as Ro,g as _o,h as To,i as Fo}from"./chunk-V5O7M2YT.js";import"./chunk-OOJM4CTU.js";var qo=`*,*:before,*:after{box-sizing:border-box;margin:0;padding:0}:host{display:grid;grid-template-columns:1fr 300px;grid-template-rows:auto 1fr;grid-template-areas:"topbar right" "stage right";min-height:0;border:1px solid var(--border);border-radius:var(--ui-radius, 8px);overflow:hidden;background:var(--graph-canvas-bg);color:var(--text);font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,sans-serif;font-size:12px}.graph2-layout{display:contents}:host([matrix]){grid-template-columns:minmax(0,1fr) 300px}.graph2-topbar{grid-area:topbar;display:flex;flex-direction:column;gap:.5rem;padding:var(--graph-topbar-padding, .6rem .75rem .6rem var(--graph-topbar-left-padding, .75rem));font-size:.825rem;background:var(--surface);backdrop-filter:var(--glass-blur);border-bottom:1px solid var(--graph-divider)}.graph2-topbar-row{display:flex;flex-wrap:wrap;align-items:center;gap:.75rem;padding:0}.graph2-topbar .g2-spacer{flex:1}.graph2-topbar-row-pinned{flex-wrap:nowrap;align-items:flex-start}.graph2-topbar-row-pinned>#g2-fullscreen{margin-top:2px}.g2-topbar-controls{display:flex;flex:1;flex-wrap:wrap;align-items:center;gap:.75rem;min-width:0}.g2-topbar-controls>.g2-reason-scope,.g2-topbar-controls>.g2-issues-switch{margin-left:auto}.g2-topbar-controls>.g2-reason-scope+.g2-issues-switch{margin-left:0}.g2-topbar-controls .g2-path-filter-wrap{flex:1 1 8rem;min-width:0;max-width:12rem}.g2-matrix-controls{display:flex;align-items:center;flex-wrap:wrap;gap:8px;font-size:11px;& button{height:30px;padding:4px 7px;border:1px solid var(--border);border-radius:var(--ui-radius, 4px);background:var(--surface);color:var(--text);font:inherit}& button:hover,button[aria-pressed=true]{background:var(--graph-hover-bg);border-color:var(--muted)}}.graph2-topbar triage-selector{margin-left:auto}.g2-icon-btn{width:28px;height:28px;border-radius:var(--ui-radius, 5px);background:var(--graph-hover-bg);border:1px solid var(--border);color:var(--muted);display:grid;place-items:center;font-family:inherit;&:hover{color:var(--accent);border-color:var(--accent)}}.g2-path-filter-wrap{position:relative;flex:0 0 12rem;padding-right:22px}.g2-path-filter-wrap .g2-path-filter-clear{position:absolute;right:4px;top:50%;transform:translateY(-50%);display:grid;place-items:center;width:18px;height:18px;background:transparent;border:0;border-radius:var(--ui-radius, 50%);color:var(--muted);font:400 10px/1 inherit;font-family:inherit;&:hover{color:var(--text);background:var(--surface-active)}}.g2-path-filter:placeholder-shown~.g2-path-filter-clear{display:none}.g2-layout-tabs{display:inline-flex;flex-shrink:0;border:1px solid var(--border);border-radius:var(--ui-radius, 6px);padding:2px;gap:2px;& button{position:relative;display:inline-flex;align-items:center;justify-content:center;border:0;border-radius:var(--ui-radius, 4px);background:transparent;color:var(--muted);font:inherit;font-size:11px;padding:5px 7px}& button[aria-pressed=true]{background:var(--graph-hover-bg);color:var(--text);box-shadow:var(--graph-layout-active-shadow, inset 0 0 0 1px var(--border))}}.g2-reason-scope{--scope-height: 30px}.graph2-right{grid-area:right;border-left:1px solid var(--graph-divider);background:var(--surface);backdrop-filter:var(--glass-blur);display:flex;flex-direction:column;overflow:hidden;padding:14px}.g2-panel-title{font-family:inherit;font-weight:600;font-size:11px;line-height:1;letter-spacing:.14em;text-transform:uppercase;color:var(--muted);opacity:.85;margin:14px 0 8px;display:flex;align-items:baseline;gap:6px;&:first-child{margin-top:0}}.g2-panel-title-row{justify-content:space-between;gap:8px}#g2-top-pkgs-block{margin-top:14px;flex:1 1 0;min-height:0;display:flex;flex-direction:column}.g2-mini-tabs{display:flex;gap:1px;background:var(--graph-mini-tabs-bg, var(--graph-divider));border-radius:var(--ui-radius, 4px);overflow:hidden}.g2-mini-tab{background:transparent;border:0;color:var(--muted);font-family:inherit;font-weight:500;font-size:11px;line-height:1.4;text-transform:none;letter-spacing:0;padding:2px 7px;&:hover{color:var(--text);background:var(--graph-hover-bg)}&.on{background:var(--surface-active);color:var(--accent);text-decoration:var(--graph-mini-tab-active-decoration, none);text-underline-offset:.2em}}.graph2-stage{grid-area:stage;position:relative;background:var(--graph-canvas-bg);overflow:hidden;cursor:default;&:active{cursor:default}& canvas{position:absolute;inset:0;width:100%;height:100%;display:block}}.g2-stage-overlay{position:absolute;top:12px;left:12px;z-index:3;display:flex;flex-direction:column;gap:4px;pointer-events:none;max-width:calc(100% - 60px)}.g2-stage-overlay>*{pointer-events:auto}.g2-stage-stats{position:absolute;bottom:10px;left:12px;z-index:2;display:flex;flex-wrap:wrap;gap:2px 14px;font:500 10px/1.4 ui-monospace,SFMono-Regular,Menlo,Monaco,monospace;color:var(--muted);opacity:.7;text-transform:uppercase;letter-spacing:.06em;pointer-events:none;max-width:calc(100% - 80px);& b{font-weight:600;color:var(--text);opacity:1}}.g2-stage-overlay-tr{position:absolute;top:12px;right:12px;z-index:3;pointer-events:auto}.g2-focus-pkg-btn{width:28px;height:28px;display:grid;place-items:center;background:var(--surface);backdrop-filter:var(--glass-blur);border:1px solid var(--border);border-radius:var(--ui-radius, 6px);color:var(--accent);box-shadow:var(--shadow-glass);&:hover{border-color:var(--accent);background:var(--surface-active)}& svg{display:block}}.g2-back-btn{display:inline-flex;align-items:center;gap:4px;padding:6px 11px;background:var(--surface);backdrop-filter:var(--glass-blur);border:1px solid var(--border);border-radius:var(--ui-radius, 6px);color:var(--accent);font:500 11px/1 inherit;font-family:inherit;box-shadow:var(--shadow-glass);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;align-self:flex-start;&:hover{border-color:var(--accent);background:var(--surface-active)}}.g2-tooltip{position:absolute;background:var(--surface);backdrop-filter:var(--glass-blur);border:1px solid var(--border);border-radius:var(--ui-radius, 7px);padding:9px 11px;pointer-events:none;min-width:170px;max-width:260px;opacity:0;transition:opacity .12s;z-index:10;box-shadow:var(--shadow-glass);&.show{opacity:1}}.g2-tt-path{font:500 11px/1.3 ui-monospace,monospace;color:var(--text);word-break:break-all;margin-bottom:4px}.g2-tt-head{display:flex;align-items:center;gap:6px;margin-bottom:6px;flex-wrap:wrap}.g2-tt-dot{width:8px;height:8px;border-radius:50%;flex-shrink:0}.g2-tt-pkg{font-size:10px;color:var(--muted);word-break:break-all}.g2-tooltip .tree-count-chips{margin-top:6px}:host-context(body.theme-light) .graph2-right .tree-count-chip.medium,:host-context(body.theme-light) .g2-tooltip .tree-count-chip.medium{color:#fff}.g2-selection-card{background:var(--graph-hover-bg);border:1px solid var(--border);border-radius:var(--ui-radius, 8px);overflow:hidden}.g2-sel-head{padding:11px 13px;border-bottom:1px solid var(--graph-divider);display:flex;align-items:center;gap:8px}.g2-sel-file-head{padding:11px 13px;border-bottom:1px solid var(--graph-divider);display:flex;flex-direction:column;gap:6px}.g2-sel-path{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,monospace;font-weight:600;font-size:12px;line-height:1.3;color:var(--text);word-break:break-all}.g2-sel-pkg-row{display:flex;align-items:center;gap:6px;min-width:0}.g2-sel-pkg{font-size:11px;color:var(--muted);word-break:break-all;min-width:0}.g2-sel-fullpath{padding:7px 13px;border-bottom:1px solid var(--graph-divider);font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,monospace;font-size:10px;line-height:1.3;color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.g2-sel-size{padding:5px 13px 7px;border-bottom:1px solid var(--graph-divider);font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,monospace;font-size:10px;line-height:1.3;color:var(--muted);font-variant-numeric:tabular-nums}.g2-sel-dot{width:11px;height:11px;border-radius:50%;box-shadow:0 0 0 3px color-mix(in srgb,var(--dot) 22%,transparent);flex-shrink:0}.g2-sel-id{font:600 12px/1 ui-monospace,monospace;color:var(--text);word-break:break-all;flex:1;min-width:0}.g2-sel-grp{font:500 9px/1 ui-monospace,monospace;color:var(--muted);text-transform:uppercase;letter-spacing:.08em;flex-shrink:0}.g2-sel-body{padding:11px 13px}.g2-sel-row{display:flex;justify-content:space-between;gap:12px;font-size:11px;padding:5px 0;border-bottom:1px solid var(--graph-divider);&:last-child{border-bottom:0}.k{color:var(--muted);flex-shrink:0}.v{color:var(--text);font-family:ui-monospace,monospace;word-break:break-all;text-align:right;min-width:0}}.g2-sel-section{padding:9px 13px;border-top:1px solid var(--graph-divider)}.g2-sel-section-label{font-family:inherit;font-weight:600;font-size:11px;line-height:1;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);opacity:.85;margin-bottom:5px}.g2-sel-section-empty{color:var(--muted);opacity:.55;font-size:11px;font-style:italic}.g2-sel-jumps{padding:11px 13px;display:flex;gap:5px;flex-wrap:wrap;border-top:1px solid var(--graph-divider)}.g2-sel-jump{background:var(--surface-active);border:1px solid var(--border);color:var(--accent);border-radius:var(--ui-radius, 4px);padding:2px 8px;font-family:inherit;font-weight:500;font-size:11px;line-height:1.3;&:hover{border-color:var(--accent)}}.g2-sel-file-list{list-style:none;margin:0;padding:0;max-height:110px;overflow:hidden auto;-webkit-app-region:no-drag;app-region:no-drag;&::-webkit-scrollbar{width:4px}&::-webkit-scrollbar-thumb{background:var(--border);border-radius:2px}& li{padding:0}}.g2-sel-file-link{display:flex;align-items:center;gap:6px;width:100%;background:transparent;border:0;border-radius:var(--ui-radius, 3px);padding:2px 6px;min-height:20.5px;font:400 11px/1.4 ui-monospace,SFMono-Regular,Menlo,Monaco,monospace;color:var(--accent);text-align:left;&:hover{background:var(--graph-hover-bg)}.g2-sel-file-dot{width:7px;height:7px;border-radius:50%;flex-shrink:0}.g2-sel-file-path{flex:1;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}}.g2-empty-state,.g2-sel-section-empty,.g2-dist-empty{cursor:default;user-select:none;-webkit-user-select:none}.g2-empty-state{background:var(--graph-hover-bg);border:1px dashed var(--border);border-radius:var(--ui-radius, 8px);padding:18px 14px;text-align:center;color:var(--muted);font-size:11px;line-height:1.5;& strong{color:var(--text);display:block;margin-bottom:4px;font-weight:500}}.g2-dist-bar{width:100%;height:5px;border-radius:3px;overflow:hidden;display:flex;background:var(--surface-active);margin-bottom:8px;>span{display:block;height:100%}}.g2-dist-list{display:flex;flex-direction:column;gap:0;flex:1 1 0;min-height:0;overflow-y:auto;overscroll-behavior:none;-webkit-app-region:no-drag;app-region:no-drag;scrollbar-gutter:stable;scrollbar-width:thin;scrollbar-color:var(--border) transparent;&::-webkit-scrollbar{width:5px}&::-webkit-scrollbar-thumb{background:var(--border);border-radius:3px}}.g2-dist-empty{color:var(--muted);opacity:.55;font-size:10px;font-style:italic;padding:6px 0;text-align:center}@media print{:host{display:none!important}}
|
|
1
|
+
import{$ as z,C as Ct,a as de,aa as Eo,b as Qt,ba as Pe,fa as ht,la as Bo,ma as Ce,na as Ke,pa as se,qa as Ze,z as Oo}from"./chunk-F47DXCEV.js";import{a as Ie}from"./chunk-R5O6FAW4.js";import{b as ie,c as Ao,d as ze}from"./chunk-CMQA4DM6.js";import"./chunk-AJ4GTATZ.js";import"./chunk-V3ME6FI5.js";import"./chunk-R75XOKUP.js";import{d as $e}from"./chunk-OD4LPN3H.js";import{a as Lo}from"./chunk-4XCDFGDP.js";import"./chunk-3BZ7JERB.js";import{a as Ye}from"./chunk-TZ5KB2Y5.js";import"./chunk-XYFXXB2G.js";import{a as ve}from"./chunk-DIJJNTRH.js";import"./chunk-QYWKC557.js";import{j as Yt}from"./chunk-GNXOKIGP.js";import"./chunk-C4Z6ZBXV.js";import{a as Pt,c as I,i as oe,j as ce}from"./chunk-2XUEZHIP.js";import"./chunk-TUII34K2.js";import{f as Ro,g as _o,h as To,i as Fo}from"./chunk-V5O7M2YT.js";import"./chunk-OOJM4CTU.js";var qo=`*,*:before,*:after{box-sizing:border-box;margin:0;padding:0}:host{display:grid;grid-template-columns:1fr 300px;grid-template-rows:auto 1fr;grid-template-areas:"topbar right" "stage right";min-height:0;border:1px solid var(--border);border-radius:var(--ui-radius, 8px);overflow:hidden;background:var(--graph-canvas-bg);color:var(--text);font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,sans-serif;font-size:12px}.graph2-layout{display:contents}:host([matrix]){grid-template-columns:minmax(0,1fr) 300px}.graph2-topbar{grid-area:topbar;display:flex;flex-direction:column;gap:.5rem;padding:var(--graph-topbar-padding, .6rem .75rem .6rem var(--graph-topbar-left-padding, .75rem));font-size:.825rem;background:var(--surface);backdrop-filter:var(--glass-blur);border-bottom:1px solid var(--graph-divider)}.graph2-topbar-row{display:flex;flex-wrap:wrap;align-items:center;gap:.75rem;padding:0}.graph2-topbar .g2-spacer{flex:1}.graph2-topbar-row-pinned{flex-wrap:nowrap;align-items:flex-start}.graph2-topbar-row-pinned>#g2-fullscreen{margin-top:2px}.g2-topbar-controls{display:flex;flex:1;flex-wrap:wrap;align-items:center;gap:.75rem;min-width:0}.g2-topbar-controls>.g2-reason-scope,.g2-topbar-controls>.g2-issues-switch{margin-left:auto}.g2-topbar-controls>.g2-reason-scope+.g2-issues-switch{margin-left:0}.g2-topbar-controls .g2-path-filter-wrap{flex:1 1 8rem;min-width:0;max-width:12rem}.g2-matrix-controls{display:flex;align-items:center;flex-wrap:wrap;gap:8px;font-size:11px;& button{height:30px;padding:4px 7px;border:1px solid var(--border);border-radius:var(--ui-radius, 4px);background:var(--surface);color:var(--text);font:inherit}& button:hover,button[aria-pressed=true]{background:var(--graph-hover-bg);border-color:var(--muted)}}.graph2-topbar triage-selector{margin-left:auto}.g2-icon-btn{width:28px;height:28px;border-radius:var(--ui-radius, 5px);background:var(--graph-hover-bg);border:1px solid var(--border);color:var(--muted);display:grid;place-items:center;font-family:inherit;&:hover{color:var(--accent);border-color:var(--accent)}}.g2-path-filter-wrap{position:relative;flex:0 0 12rem;padding-right:22px}.g2-path-filter-wrap .g2-path-filter-clear{position:absolute;right:4px;top:50%;transform:translateY(-50%);display:grid;place-items:center;width:18px;height:18px;background:transparent;border:0;border-radius:var(--ui-radius, 50%);color:var(--muted);font:400 10px/1 inherit;font-family:inherit;&:hover{color:var(--text);background:var(--surface-active)}}.g2-path-filter:placeholder-shown~.g2-path-filter-clear{display:none}.g2-layout-tabs{display:inline-flex;flex-shrink:0;border:1px solid var(--border);border-radius:var(--ui-radius, 6px);padding:2px;gap:2px;& button{position:relative;display:inline-flex;align-items:center;justify-content:center;border:0;border-radius:var(--ui-radius, 4px);background:transparent;color:var(--muted);font:inherit;font-size:11px;padding:5px 7px}& button[aria-pressed=true]{background:var(--graph-hover-bg);color:var(--text);box-shadow:var(--graph-layout-active-shadow, inset 0 0 0 1px var(--border))}}.g2-reason-scope{--scope-height: 30px}.graph2-right{grid-area:right;border-left:1px solid var(--graph-divider);background:var(--surface);backdrop-filter:var(--glass-blur);display:flex;flex-direction:column;overflow:hidden;padding:14px}.g2-panel-title{font-family:inherit;font-weight:600;font-size:11px;line-height:1;letter-spacing:.14em;text-transform:uppercase;color:var(--muted);opacity:.85;margin:14px 0 8px;display:flex;align-items:baseline;gap:6px;&:first-child{margin-top:0}}.g2-panel-title-row{justify-content:space-between;gap:8px}#g2-top-pkgs-block{margin-top:14px;flex:1 1 0;min-height:0;display:flex;flex-direction:column}.g2-mini-tabs{display:flex;gap:1px;background:var(--graph-mini-tabs-bg, var(--graph-divider));border-radius:var(--ui-radius, 4px);overflow:hidden}.g2-mini-tab{background:transparent;border:0;color:var(--muted);font-family:inherit;font-weight:500;font-size:11px;line-height:1.4;text-transform:none;letter-spacing:0;padding:2px 7px;&:hover{color:var(--text);background:var(--graph-hover-bg)}&.on{background:var(--surface-active);color:var(--accent);text-decoration:var(--graph-mini-tab-active-decoration, none);text-underline-offset:.2em}}.graph2-stage{grid-area:stage;position:relative;background:var(--graph-canvas-bg);overflow:hidden;cursor:default;&:active{cursor:default}& canvas{position:absolute;inset:0;width:100%;height:100%;display:block}}.g2-stage-overlay{position:absolute;top:12px;left:12px;z-index:3;display:flex;flex-direction:column;gap:4px;pointer-events:none;max-width:calc(100% - 60px)}.g2-stage-overlay>*{pointer-events:auto}.g2-stage-stats{position:absolute;bottom:10px;left:12px;z-index:2;display:flex;flex-wrap:wrap;gap:2px 14px;font:500 10px/1.4 ui-monospace,SFMono-Regular,Menlo,Monaco,monospace;color:var(--muted);opacity:.7;text-transform:uppercase;letter-spacing:.06em;pointer-events:none;max-width:calc(100% - 80px);& b{font-weight:600;color:var(--text);opacity:1}}.g2-stage-overlay-tr{position:absolute;top:12px;right:12px;z-index:3;pointer-events:auto}.g2-focus-pkg-btn{width:28px;height:28px;display:grid;place-items:center;background:var(--surface);backdrop-filter:var(--glass-blur);border:1px solid var(--border);border-radius:var(--ui-radius, 6px);color:var(--accent);box-shadow:var(--shadow-glass);&:hover{border-color:var(--accent);background:var(--surface-active)}& svg{display:block}}.g2-back-btn{display:inline-flex;align-items:center;gap:4px;padding:6px 11px;background:var(--surface);backdrop-filter:var(--glass-blur);border:1px solid var(--border);border-radius:var(--ui-radius, 6px);color:var(--accent);font:500 11px/1 inherit;font-family:inherit;box-shadow:var(--shadow-glass);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;align-self:flex-start;&:hover{border-color:var(--accent);background:var(--surface-active)}}.g2-tooltip{position:absolute;background:var(--surface);backdrop-filter:var(--glass-blur);border:1px solid var(--border);border-radius:var(--ui-radius, 7px);padding:9px 11px;pointer-events:none;min-width:170px;max-width:260px;opacity:0;transition:opacity .12s;z-index:10;box-shadow:var(--shadow-glass);&.show{opacity:1}}.g2-tt-path{font:500 11px/1.3 ui-monospace,monospace;color:var(--text);word-break:break-all;margin-bottom:4px}.g2-tt-head{display:flex;align-items:center;gap:6px;margin-bottom:6px;flex-wrap:wrap}.g2-tt-dot{width:8px;height:8px;border-radius:50%;flex-shrink:0}.g2-tt-pkg{font-size:10px;color:var(--muted);word-break:break-all}.g2-tooltip .tree-count-chips{margin-top:6px}:host-context(body.theme-light) .graph2-right .tree-count-chip.medium,:host-context(body.theme-light) .g2-tooltip .tree-count-chip.medium{color:#fff}.g2-selection-card{background:var(--graph-hover-bg);border:1px solid var(--border);border-radius:var(--ui-radius, 8px);overflow:hidden}.g2-sel-head{padding:11px 13px;border-bottom:1px solid var(--graph-divider);display:flex;align-items:center;gap:8px}.g2-sel-file-head{padding:11px 13px;border-bottom:1px solid var(--graph-divider);display:flex;flex-direction:column;gap:6px}.g2-sel-path{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,monospace;font-weight:600;font-size:12px;line-height:1.3;color:var(--text);word-break:break-all}.g2-sel-pkg-row{display:flex;align-items:center;gap:6px;min-width:0}.g2-sel-pkg{font-size:11px;color:var(--muted);word-break:break-all;min-width:0}.g2-sel-fullpath{padding:7px 13px;border-bottom:1px solid var(--graph-divider);font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,monospace;font-size:10px;line-height:1.3;color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.g2-sel-size{padding:5px 13px 7px;border-bottom:1px solid var(--graph-divider);font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,monospace;font-size:10px;line-height:1.3;color:var(--muted);font-variant-numeric:tabular-nums}.g2-sel-dot{width:11px;height:11px;border-radius:50%;box-shadow:0 0 0 3px color-mix(in srgb,var(--dot) 22%,transparent);flex-shrink:0}.g2-sel-id{font:600 12px/1 ui-monospace,monospace;color:var(--text);word-break:break-all;flex:1;min-width:0}.g2-sel-grp{font:500 9px/1 ui-monospace,monospace;color:var(--muted);text-transform:uppercase;letter-spacing:.08em;flex-shrink:0}.g2-sel-body{padding:11px 13px}.g2-sel-row{display:flex;justify-content:space-between;gap:12px;font-size:11px;padding:5px 0;border-bottom:1px solid var(--graph-divider);&:last-child{border-bottom:0}.k{color:var(--muted);flex-shrink:0}.v{color:var(--text);font-family:ui-monospace,monospace;word-break:break-all;text-align:right;min-width:0}}.g2-sel-section{padding:9px 13px;border-top:1px solid var(--graph-divider)}.g2-sel-section-label{font-family:inherit;font-weight:600;font-size:11px;line-height:1;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);opacity:.85;margin-bottom:5px}.g2-sel-section-empty{color:var(--muted);opacity:.55;font-size:11px;font-style:italic}.g2-sel-jumps{padding:11px 13px;display:flex;gap:5px;flex-wrap:wrap;border-top:1px solid var(--graph-divider)}.g2-sel-jump{background:var(--surface-active);border:1px solid var(--border);color:var(--accent);border-radius:var(--ui-radius, 4px);padding:2px 8px;font-family:inherit;font-weight:500;font-size:11px;line-height:1.3;&:hover{border-color:var(--accent)}}.g2-sel-file-list{list-style:none;margin:0;padding:0;max-height:110px;overflow:hidden auto;-webkit-app-region:no-drag;app-region:no-drag;&::-webkit-scrollbar{width:4px}&::-webkit-scrollbar-thumb{background:var(--border);border-radius:2px}& li{padding:0}}.g2-sel-file-link{display:flex;align-items:center;gap:6px;width:100%;background:transparent;border:0;border-radius:var(--ui-radius, 3px);padding:2px 6px;min-height:20.5px;font:400 11px/1.4 ui-monospace,SFMono-Regular,Menlo,Monaco,monospace;color:var(--accent);text-align:left;&:hover{background:var(--graph-hover-bg)}.g2-sel-file-dot{width:7px;height:7px;border-radius:50%;flex-shrink:0}.g2-sel-file-path{flex:1;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}}.g2-empty-state,.g2-sel-section-empty,.g2-dist-empty{cursor:default;user-select:none;-webkit-user-select:none}.g2-empty-state{background:var(--graph-hover-bg);border:1px dashed var(--border);border-radius:var(--ui-radius, 8px);padding:18px 14px;text-align:center;color:var(--muted);font-size:11px;line-height:1.5;& strong{color:var(--text);display:block;margin-bottom:4px;font-weight:500}}.g2-dist-bar{width:100%;height:5px;border-radius:3px;overflow:hidden;display:flex;background:var(--surface-active);margin-bottom:8px;>span{display:block;height:100%}}.g2-dist-list{display:flex;flex-direction:column;gap:0;flex:1 1 0;min-height:0;overflow-y:auto;overscroll-behavior:none;-webkit-app-region:no-drag;app-region:no-drag;scrollbar-gutter:stable;scrollbar-width:thin;scrollbar-color:var(--border) transparent;&::-webkit-scrollbar{width:5px}&::-webkit-scrollbar-thumb{background:var(--border);border-radius:3px}}.g2-dist-empty{color:var(--muted);opacity:.55;font-size:10px;font-style:italic;padding:6px 0;text-align:center}@media print{:host{display:none!important}}
|
|
2
2
|
`;var he=`.g2-dist-item{display:grid;grid-template-columns:8px 1fr auto auto;gap:8px;align-items:center;font-size:10px;padding:2px 6px;min-height:20.5px;margin:0 -6px;background:transparent;border:0;border-radius:var(--ui-radius, 4px);font-family:inherit;text-align:left;width:calc(100% + 12px);&:hover{background:var(--graph-hover-bg)}&.on{background:var(--surface-active);.g2-dist-name{color:var(--accent)}}.g2-dist-dot{width:8px;height:8px;border-radius:50%;flex-shrink:0}.g2-dist-name{color:var(--muted);font-family:ui-monospace,monospace;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.g2-dist-count{font-family:ui-monospace,monospace;color:var(--text)}.g2-dist-pct{font-family:ui-monospace,monospace;color:var(--muted);width:36px;text-align:right;opacity:.85}}
|
|
3
3
|
`;var fe=`.g2-zoom-ctrl{position:absolute;right:12px;bottom:12px;display:flex;flex-direction:column;background:var(--surface);backdrop-filter:var(--glass-blur);border:1px solid var(--border);border-radius:var(--ui-radius, 6px);overflow:hidden;z-index:3;box-shadow:var(--shadow-glass);& button{width:28px;height:28px;margin:0;padding:0;background:transparent;border:0;border-radius:0;color:var(--muted);border-bottom:1px solid var(--graph-divider);display:grid;place-items:center;font-family:inherit;font-size:13px;&:last-child{border-bottom:0}&:hover:not(:disabled){color:var(--accent);background:var(--surface-active)}&:disabled{opacity:.35}}}.g2-zoom-pct{font:500 9px/1 ui-monospace,monospace;color:var(--muted);padding:5px 0;text-align:center;border-bottom:1px solid var(--graph-divider)}.g2-zoom-ctrl .g2-zoom-fit-btn{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,monospace;font-weight:600;font-size:9px;line-height:1;letter-spacing:-.02em;text-transform:lowercase}
|
|
4
4
|
`;var Ho=`.tree-count-chips{display:inline-flex;gap:.25rem;flex-wrap:wrap}.tree-count-chip{display:inline-block;font-size:.65rem;font-weight:600;text-transform:uppercase;letter-spacing:.03em;padding:.1rem .4rem;border-radius:3px;line-height:1.3;&.critical{background:var(--critical);color:#fff}&.high{background:var(--high);color:#fff}&.medium{background:var(--medium);color:#000}&.low{background:var(--low);color:var(--badge-low-text)}&.high_bug{background:var(--high-bug);color:#fff}&.bug{background:var(--bug);color:#fff}&.informational{background:var(--info);color:#fff}}
|
package/out/index.html
CHANGED
|
@@ -21,34 +21,38 @@
|
|
|
21
21
|
<meta name="apple-mobile-web-app-title" content="DeepView" />
|
|
22
22
|
<link rel="preload" href="./view.css" as="style" />
|
|
23
23
|
<link rel="modulepreload" href="./view.js" />
|
|
24
|
-
<link rel="modulepreload" href="./chunk-
|
|
24
|
+
<link rel="modulepreload" href="./chunk-QWDWTBM7.js" />
|
|
25
25
|
<link rel="modulepreload" href="./chunk-KEX2ATEW.js" />
|
|
26
|
-
<link rel="modulepreload" href="./chunk-
|
|
26
|
+
<link rel="modulepreload" href="./chunk-CH4UN6WK.js" />
|
|
27
|
+
<link rel="modulepreload" href="./chunk-GZWM7UQM.js" />
|
|
28
|
+
<link rel="modulepreload" href="./chunk-JCIIBLKR.js" />
|
|
27
29
|
<link rel="modulepreload" href="./chunk-2KBF5TZ7.js" />
|
|
28
30
|
<link rel="modulepreload" href="./chunk-K3X5EJBQ.js" />
|
|
29
31
|
<link rel="modulepreload" href="./chunk-CVVJAXVY.js" />
|
|
30
32
|
<link rel="modulepreload" href="./chunk-VIHGO77Y.js" />
|
|
31
|
-
<link rel="modulepreload" href="./chunk-
|
|
32
|
-
<link rel="modulepreload" href="./chunk-
|
|
33
|
-
<link rel="modulepreload" href="./chunk-
|
|
33
|
+
<link rel="modulepreload" href="./chunk-EDKLBQQN.js" />
|
|
34
|
+
<link rel="modulepreload" href="./chunk-SWTLADW5.js" />
|
|
35
|
+
<link rel="modulepreload" href="./chunk-2ABLKCOY.js" />
|
|
36
|
+
<link rel="modulepreload" href="./chunk-ZESLQCTF.js" />
|
|
34
37
|
<link rel="modulepreload" href="./chunk-UYAXVRVL.js" />
|
|
35
38
|
<link rel="modulepreload" href="./chunk-NRPC74AM.js" />
|
|
36
|
-
<link rel="modulepreload" href="./chunk-
|
|
39
|
+
<link rel="modulepreload" href="./chunk-LPCTJYNA.js" />
|
|
37
40
|
<link rel="modulepreload" href="./chunk-W4J3MGLB.js" />
|
|
38
41
|
<link rel="modulepreload" href="./chunk-GJ4IUCNS.js" />
|
|
39
42
|
<link rel="modulepreload" href="./chunk-PNHBZGDD.js" />
|
|
40
|
-
<link rel="modulepreload" href="./chunk-
|
|
43
|
+
<link rel="modulepreload" href="./chunk-F47DXCEV.js" />
|
|
41
44
|
<link rel="modulepreload" href="./chunk-R5O6FAW4.js" />
|
|
42
45
|
<link rel="modulepreload" href="./chunk-CMQA4DM6.js" />
|
|
43
|
-
<link rel="modulepreload" href="./chunk-
|
|
46
|
+
<link rel="modulepreload" href="./chunk-AJ4GTATZ.js" />
|
|
44
47
|
<link rel="modulepreload" href="./chunk-V3ME6FI5.js" />
|
|
45
|
-
<link rel="modulepreload" href="./chunk-
|
|
48
|
+
<link rel="modulepreload" href="./chunk-R75XOKUP.js" />
|
|
49
|
+
<link rel="modulepreload" href="./chunk-OD4LPN3H.js" />
|
|
46
50
|
<link rel="modulepreload" href="./chunk-4XCDFGDP.js" />
|
|
47
51
|
<link rel="modulepreload" href="./chunk-3BZ7JERB.js" />
|
|
48
52
|
<link rel="modulepreload" href="./chunk-TZ5KB2Y5.js" />
|
|
49
53
|
<link rel="modulepreload" href="./chunk-XYFXXB2G.js" />
|
|
50
54
|
<link rel="modulepreload" href="./chunk-DIJJNTRH.js" />
|
|
51
|
-
<link rel="modulepreload" href="./chunk-
|
|
55
|
+
<link rel="modulepreload" href="./chunk-QYWKC557.js" />
|
|
52
56
|
<link rel="modulepreload" href="./chunk-GNXOKIGP.js" />
|
|
53
57
|
<link rel="modulepreload" href="./chunk-C4Z6ZBXV.js" />
|
|
54
58
|
<link rel="modulepreload" href="./chunk-2XUEZHIP.js" />
|
package/out/terminal.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as fc,b as hr,c as Kt,d as dc,e as Xe,f as et,g as Fs,h as pc,i as On,j as Co,k as Jt,l as hc,m as Qt,n as T,o as mr,p as mc,q as _o,r as Rs,s as Ms,t as Ds,v as gc,w as Us,z as Lo}from"./chunk-RFZQQXSG.js";import{a as cc}from"./chunk-TZ5KB2Y5.js";import"./chunk-XYFXXB2G.js";import"./chunk-C4Z6ZBXV.js";import{a as uc,c as Ge,g as Ls,j as lc}from"./chunk-2XUEZHIP.js";import{b as nx}from"./chunk-OOJM4CTU.js";var rx={__proto__:null,ENOENT:"No such file or directory",ENOTDIR:"Not a directory",EISDIR:"Is a directory",EEXIST:"File exists",ENOTEMPTY:"Directory not empty",ELOOP:"Too many levels of symbolic links",EINVAL:"Invalid argument",EPERM:"Operation not permitted",EBUSY:"Device or resource busy",EILSEQ:"Invalid or incomplete multibyte or wide character",ENAMETOOLONG:"File name too long"},ox=/[\p{Cc}\p{Zl}\p{Zp}\p{Bidi_Control}]/gu,ix=e=>`${e}`.replaceAll(ox,t=>`\\u${t.codePointAt(0).toString(16).padStart(4,"0")}`),Ue=(e,t,n="a string")=>new TypeError(`${e} must be ${n}, not ${t===null?"null":typeof t}`),F=class extends Error{constructor(t,n){super(`${ix(n)}: ${rx[t]??t}`),this.name="VfsError",this.code=t,this.path=n}};var wc=(e,t="path")=>{if(typeof e!="string")throw Ue(t,e);return e};function yc(e,t){let n=Math.min(wc(e).length,wc(t).length);for(let r=0;r<n;r++)if(e[r]!==t[r])return e.codePointAt(r)-t.codePointAt(r);return e.length-t.length}var gr=e=>[...e.entries.keys()].sort(yc),Fo=(e,t)=>t===""?e:e==="/"?`/${t}`:`${e}/${t}`;function*en(e,t=r=>r,n=()=>!0){let r=[{name:"",node:e,depth:0}];for(;r.length>0;){let o=r.pop();if(yield t(o),o.node.type!=="directory"||!n(o))continue;let i=gr(o.node);for(let s=i.length-1;s>=0;s--){let a=o.name===""?i[s]:`${o.name}/${i[s]}`;r.push({name:a,leaf:i[s],parent:o.node,node:o.node.entries.get(i[s]),depth:o.depth+1})}}}var sx=new Set(["error","keep","replace"]);function xc(e,t,n="'error', 'keep' or 'replace'"){if(typeof e!="string")throw Ue(t,e,n);if(!sx.has(e))throw new RangeError(`${t} must be ${n}, not ${JSON.stringify(e)}`);return e}function bc({clash:e="error",fold:t}){if(typeof e!="function"&&xc(e,"clash","'error', 'keep', 'replace' or a function"),t!==void 0&&typeof t!="function")throw Ue("fold",t,"a function");return{fold:t,settle:typeof e=="function"?(n,r)=>xc(e(n,r),"what clash returns"):()=>e}}function kc(e,t,n,{settle:r,fold:o},i){let s=ax(t,i.copy),a=new Map([[s,{into:e}]]),u=[];for(let{name:l,leaf:c,parent:f,node:d}of en(s,void 0,p=>a.has(p.node))){if(f===void 0)continue;let p=a.get(f),h=p.into.entries.get(c);if(h?.type==="directory"&&d.type==="directory"){a.set(d,{into:h});continue}let m=h===void 0?ux(p,f,c,o):[c];if(m.length>0){let g=Fo(n,l),w=r(g,m.map(y=>g.slice(0,-c.length)+y));if(w==="error")throw new F("EEXIST",g);if(w==="keep")continue}u.push({dir:p.into,name:c,node:d,taken:m})}for(let{dir:l,name:c,node:f,taken:d}of u){for(let p of en(f))i.number(p.node);for(let p of d)l.entries.delete(p);l.entries.set(c,f)}}function*vc(e,t,n){for(let{name:r,node:o}of en(e))if(o.type==="directory")for(let i of Map.groupBy(gr(o),s=>n(s)).values())i.length>1&&(yield{path:Fo(t,r),names:i})}function ax(e,t){let n=new Map;for(let{node:r,parent:o,leaf:i}of en(e))n.has(r)||n.set(r,t(r)),o!==void 0&&n.get(o).entries.set(i,n.get(r));return n.get(e)}function ux(e,t,n,r){return r===void 0?[]:(e.keys??=Map.groupBy(gr(e.into).filter(o=>!t.entries.has(o)),o=>r(o)),e.keys.get(r(n))??[])}var lx=40,cx=255,Sc=4096,fx=new Uint8Array,Ac={file:420,directory:493,symlink:511},dx=new TextEncoder,px=new TextDecoder("utf-8",{fatal:!0,ignoreBOM:!0}),Ro=e=>typeof e=="string"&&e.endsWith("/"),In=class{#t;#s=0;constructor(){this.#t=this.#e()}#n(t,n,r=Ac[t],o=0){return{ino:++this.#s,type:t,mode:Uo(r),mtime:Po(o),...n}}#e(t,n){return this.#n("directory",{entries:new Map},t,n)}#i(t,{follow:n=!0,mkdirs:r=!1,create:o=!1}={}){if(typeof t!="string")throw Ue("a path",t);if(t.includes("\0"))throw new F("EINVAL",t);if(t==="")throw new F("ENOENT",t);let i=t.endsWith("/"),s=[Ec(t)],a=[{name:"",node:this.#t}],u=lx,l,c,f,d;for(;;){for(;s.length>1&&Ps(s.at(-1));)s.pop();if(Ps(s.at(-1))){({name:f,node:d}=a.pop()),l=void 0;break}if(c=s.length>1,f=hx(s.at(-1)),f===".")continue;if(f===".."){a.length>1&&a.pop();continue}l=a.at(-1).node;let p=s.every(Ps);if(d=l.entries.get(f),o&&!p&&s.every(zs)){i=!0;break}if(d===void 0){if(p)break;if(!r||c)throw new F("ENOENT",t);Do(f,t),d=this.#e(),l.entries.set(f,d)}if(d.type==="symlink"&&(!p||n)){if(u--===0)throw new F("ELOOP",t);d.target.startsWith("/")&&(a.length=1),s.push(Ec(d.target,!0));continue}if(p){if(i&&!o&&d.type!=="directory")throw new F("ENOTDIR",t);break}if(d.type!=="directory")throw new F("ENOTDIR",t);a.push({name:f,node:d})}return{dir:l,name:f,node:d,trailing:i,chain:a,linked:c}}#r(t,n=!0){let r=this.#i(t,{follow:n});if(r.node===void 0)throw new F("ENOENT",t);return r}#o(t,n){return this.#r(t,n).node}#u(t,n,r){Do(t.name,r),t.dir.entries.set(t.name,n)}#a(t,n){if(t.dir!==void 0)return t.dir;throw new F(Bs(n,0)===n.length?"EBUSY":"EINVAL",n)}#l(t,n,r){try{return this.#o(t,r).type===n}catch(o){if(o instanceof F)return!1;throw o}}stat(t){return $c(this.#o(t,!0))}lstat(t){return $c(this.#o(t,Ro(t)))}isFile(t){return this.#l(t,"file",!0)}isDirectory(t){return this.#l(t,"directory",!0)}isSymlink(t){return this.#l(t,"symlink",!1)}realpath(t){return Mo(this.#r(t))}readFile(t){let n=this.#o(t,!0);if(n.type==="directory")throw new F("EISDIR",t);return n.bytes}readText(t){let n=this.readFile(t);try{return px.decode(n)}catch{throw new F("EILSEQ",t)}}readlink(t){let n=this.#o(t,Ro(t));if(n.type!=="symlink")throw new F("EINVAL",t);return n.target}readdir(t){let n=this.#o(t,!0);if(n.type!=="directory")throw new F("ENOTDIR",t);return gr(n)}#c(t,n,r,o,i){let s=Ic(n,t),a=this.#i(t,{follow:!Ro(t),create:!0});if(a.trailing||a.node?.type==="directory")throw new F("EISDIR",t);a.node===void 0?this.#u(a,this.#n("file",{bytes:s},o,i),t):r(a.node,s)}writeFile(t,n,{mode:r,mtime:o}={}){this.#c(t,n,(i,s)=>Object.assign(i,{bytes:s,...mx(i,r,o)}),r,o)}appendFile(t,n){this.#c(t,n,(r,o)=>{r.bytes=wx(r.bytes,o)})}mkdir(t,{recursive:n=!1,mode:r,mtime:o}={}){let i=this.#i(t,{follow:n,mkdirs:n,create:!n});if(i.node===void 0){if(i.linked)throw new F("ENOENT",t);this.#u(i,this.#e(r,o),t)}else if(!n||i.node.type!=="directory")throw new F("EEXIST",t)}symlink(t,n,{mode:r,mtime:o}={}){if(typeof t!="string")throw Ue("a link target",t);if(t===""||t.includes("\0"))throw new F("EINVAL",n);Do(t,n,Sc),this.#u(this.#f(n),this.#n("symlink",{target:t,size:Nc(t)},r,o),n)}hardlink(t,n){let r=this.#o(t,Ro(t)),o=this.#f(n);if(r.type==="directory")throw new F("EPERM",t);this.#u(o,r,n)}#f(t){let n=this.#i(t,{follow:!1,create:!0});if(n.node!==void 0)throw new F("EEXIST",t);if(n.trailing)throw new F("ENOENT",t);return n}unlink(t){this.rm(t)}rmdir(t){let n=this.#r(t,!1);if(n.node.type!=="directory")throw new F("ENOTDIR",t);let r=this.#a(n,t);if(n.node.entries.size>0)throw new F("ENOTEMPTY",t);r.entries.delete(n.name)}rm(t,{recursive:n=!1}={}){let r=this.#r(t,!1);if(r.node.type==="directory"&&!n)throw new F("EISDIR",t);this.#a(r,t).entries.delete(r.name)}rename(t,n){let r=this.#i(t,{follow:!1,create:!0}),o=this.#i(n,{follow:!1,create:!0}),i=this.#a(r,t),s=this.#a(o,n);if(r.node===void 0)throw new F("ENOENT",t);Do(o.name,n);let a=r.node.type==="directory";if(!a&&(r.trailing||o.trailing))throw new F("ENOTDIR",r.trailing?t:n);if(o.chain.some(u=>u.node===r.node))throw new F("EINVAL",n);if(r.chain.some(u=>u.node===o.node))throw new F("ENOTEMPTY",n);if(o.node!==r.node){if(o.node!==void 0&&o.node.type==="directory"!==a)throw new F(a?"ENOTDIR":"EISDIR",n);if(o.node?.type==="directory"&&o.node.entries.size>0)throw new F("ENOTEMPTY",n);i.entries.delete(r.name),s.entries.set(o.name,r.node)}}chmod(t,n){this.#o(t,!0).mode=Uo(n)}utimes(t,n){this.#o(t,!0).mtime=Po(n)}mount(t,n="/",r={}){if(t===null||typeof t!="object"||!(#t in t))throw Ue("a tree",t,"a Vfs");let o=bc(r),i=this.#r(n);if(i.node.type!=="directory")throw new F("ENOTDIR",n);kc(i.node,t.#t,Mo(i),o,{copy:gx,number:s=>{s.ino||=++this.#s}})}walk(t="/"){let n=this.#r(t),r=Mo(n);return en(n.node,({name:o,node:i,depth:s})=>({path:Fo(r,o),type:i.type,depth:s}))}collisions(t,n="/"){if(typeof t!="function")throw Ue("fold",t,"a function");let r=this.#r(n);return vc(r.node,Mo(r),t)}entries(t="/"){let n=this.#r(t),r=n.node.type==="directory"?".":n.name,o=new Map;return en(n.node,({name:i,node:s})=>{let a=i===""?r:i,u={name:a,type:s.type,mode:s.mode,mtime:s.mtime,linkname:"",data:fx},l=o.get(s);return l!==void 0?(u.type="hardlink",u.linkname=l):s.type==="symlink"?(o.set(s,a),u.linkname=s.target):s.type==="file"&&(o.set(s,a),u.data=s.bytes),u})}},Ec=(e,t=!1)=>({text:e,at:Bs(e,0),dot:t&&e.endsWith("/")}),zs=e=>e.at===e.text.length,Ps=e=>zs(e)&&!e.dot,Bs=(e,t)=>{let n=t;for(;e[n]==="/";)n++;return n};function hx(e){if(zs(e))return e.dot=!1,".";let t=e.text.indexOf("/",e.at),n=t===-1?e.text.length:t,r=e.text.slice(e.at,n);return e.at=Bs(e.text,n),r}var Mo=({chain:e,name:t})=>`/${[...e.slice(1).map(n=>n.name),t].filter(Boolean).join("/")}`,$c=e=>({type:e.type,ino:e.ino,mode:e.mode,mtime:e.mtime,size:e.bytes?.length??e.size??0}),mx=(e,t=e.mode,n=e.mtime)=>({mode:Uo(t),mtime:Po(n)});function Do(e,t,n=cx){if(!e.isWellFormed())throw new F("EILSEQ",t);if(Oc(e,n))throw new F("ENAMETOOLONG",t)}function Nc(e){let t=0;for(let n of e){let r=n.codePointAt(0);t+=r<128?1:r<2048?2:r<65536?3:4}return t}var Oc=(e,t)=>e.length>t||e.length*3>t&&Nc(e)>t;function Uo(e){if(!Number.isInteger(e)||e<0||e>4095)throw new RangeError(`a mode must be an integer from 0 to 0o7777, not ${e}`);return e}function Po(e){if(!Number.isSafeInteger(e))throw new RangeError(`an mtime must be an integer of whole seconds, not ${e}`);return e}function Ic(e,t){if(typeof e=="string"){if(!e.isWellFormed())throw new F("EILSEQ",t);return dx.encode(e)}if(e instanceof Uint8Array)return new Uint8Array(e);throw Ue("file contents",e,"a string or a Uint8Array")}function gx({type:e,mode:t,mtime:n,bytes:r,target:o,size:i}){let s={ino:0,type:e,mode:t,mtime:n};return e==="directory"?s.entries=new Map:e==="symlink"?Object.assign(s,{target:o,size:i}):s.bytes=r.byteOffset+r.length===r.buffer.byteLength?r:r.slice(),s}function wx(e,t){let n=e.length+t.length,r=e.byteOffset+n<=e.buffer.byteLength,o=r?new Uint8Array(e.buffer,e.byteOffset,n):new Uint8Array(Math.max(n,e.length*2)).subarray(0,n);return r||o.set(e),o.set(t,e.length),o}function zo(e){if(Object.keys(e).length>0)throw new TypeError("Unexpected extra options")}var p4=Object.getPrototypeOf(Uint8Array);var Cc=globalThis.atob,_c=Uint8Array.prototype.toBase64,Tc=8192,yx=_c&&Cc;function js(e,t=0,n=e.length){t|=0,n|=0;let r=n-t;if(r===0)return"";if(yx&&r>=256&&r<1e8&&e.toBase64===_c&&e.BYTES_PER_ELEMENT===1){let i=t===0&&n===e.length?e:e.subarray(t,n);return Cc(i.toBase64())}if(r>Tc){let i="";for(let s=t;s<n;){let a=Math.min(n,s+Tc);i+=String.fromCharCode.apply(String,e.subarray(s,a)),s=a}return i}let o=t===0&&n===e.length?e:e.subarray(t,n);return String.fromCharCode.apply(String,o)}var Tn=hr?e=>e.byteLength>=768&&!dc?hr.from(e.buffer,e.byteOffset,e.byteLength).latin1Slice(0,e.byteLength):et.decode(e):Fs?e=>Fs.decode(e):e=>js(e instanceof Uint8Array?e:new Uint8Array(e.buffer,e.byteOffset,e.byteLength));var Lc=e=>fc(e,new Uint8Array(e.length)),xx=Kt&&Xe?.encodeInto,wr=xx?(e,t)=>{let n=new Uint8Array(e.length+4),r=Xe.encodeInto(e,n);if(r.read!==e.length||r.written!==e.length)throw new SyntaxError(t);return n.subarray(0,e.length)}:hr?(e,t)=>{let n=hr.from(e,"utf8");if(n.length!==e.length)throw new SyntaxError(t);return new Uint8Array(n.buffer,n.byteOffset,n.byteLength)}:(e,t)=>{let n=Xe.encode(e);if(n.length!==e.length)throw new SyntaxError(t);return n};var Gs={};nx(Gs,{E_CHAR:()=>Cn,E_LAST:()=>Ws,E_LENGTH:()=>Pc,E_PADDING:()=>Uc,fromBase64:()=>Hs,toBase64:()=>qs});var Fc=[..."ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"],Rc=[..."ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"],Mc={},Dc={},Cn="Invalid character in base64 input",Uc="Invalid base64 padding",Pc="Invalid base64 length",Ws="Invalid last chunk";function qs(e,t,n){let r=e.length/3|0,o=r*3,i="",s=0,a=t?Rc:Fc,u=t?Dc:Mc;if(!u.pairs)if(u.pairs=[],et){u.codepairs=new Uint16Array(4096);let h=u.codepairs,m=new Uint8Array(h.buffer,h.byteOffset,h.byteLength);for(let g=0;g<64;g++){let w=a[g].charCodeAt(0);for(let y=0;y<64;y++)m[g<<7|y<<1]=m[y<<7|(g<<1)+1]=w}}else{let h=u.pairs;for(let m=0;m<64;m++)for(let g=0;g<64;g++)h.push(`${a[m]}${a[g]}`)}let{pairs:l,codepairs:c}=u;if(et){let h=new Uint16Array(r*2),m=0;for(let g=e.length-11;s<g;s+=12,m+=8){let w=e[s],y=e[s+1],$=e[s+2],S=e[s+3],_=e[s+4],W=e[s+5],H=e[s+6],re=e[s+7],le=e[s+8],ce=e[s+9],An=e[s+10],Nn=e[s+11];h[m]=c[w<<4|y>>4],h[m+1]=c[(y&15)<<8|$],h[m+2]=c[S<<4|_>>4],h[m+3]=c[(_&15)<<8|W],h[m+4]=c[H<<4|re>>4],h[m+5]=c[(re&15)<<8|le],h[m+6]=c[ce<<4|An>>4],h[m+7]=c[(An&15)<<8|Nn]}for(let g=e.length-2;s<g;s+=3,m+=2){let w=e[s],y=e[s+1],$=e[s+2];h[m]=c[w<<4|y>>4],h[m+1]=c[(y&15)<<8|$]}i=Tn(h)}else for(;s<o;s+=3){let h=e[s],m=e[s+1],g=e[s+2];i+=l[h<<4|m>>4],i+=l[(m&15)<<8|g]}let f=0,d=2,p=e.length;for(;s<p;s++){let h=e[s];i+=a[f|h>>d],d===6&&(d=0,i+=a[h&63]),f=h<<6-d&63,d+=2}return d!==2&&(i+=a[f]),n&&(i+=["","==","="][p-o]),i}var bx=Xe?128:65536;function Hs(e,t){let n=e.length;for(;e[n-1]==="=";)n--;let r=e.length-n,o=n%4,i=n-o;if(o===1)throw new SyntaxError(Pc);if(r>3||r!==0&&e.length%4!==0)throw new SyntaxError(Uc);let s=t?Rc:Fc,a=t?Dc:Mc;a.fromMap||(a.fromMap=new Int8Array(bx).fill(-1),s.forEach((h,m)=>a.fromMap[h.charCodeAt(0)]=m));let u=a.fromMap,l=new Uint8Array(Math.floor(n*3/4)),c=0,f=0;if(Xe){let h=wr(e,Cn);for(;f<i;f+=4){let m=h[f],g=h[f+1],w=h[f+2],y=h[f+3],$=u[m]<<18|u[g]<<12|u[w]<<6|u[y];if($<0)throw new SyntaxError(Cn);l[c]=$>>16,l[c+1]=$>>8&255,l[c+2]=$&255,c+=3}}else for(;f<i;f+=4){let h=e.charCodeAt(f),m=e.charCodeAt(f+1),g=e.charCodeAt(f+2),w=e.charCodeAt(f+3),y=u[h]<<18|u[m]<<12|u[g]<<6|u[w];if(y<0)throw new SyntaxError(Cn);l[c]=y>>16,l[c+1]=y>>8&255,l[c+2]=y&255,c+=3}if(o<2)return l;let d=u[e.charCodeAt(f++)]<<6|u[e.charCodeAt(f++)];if(d<0)throw new SyntaxError(Cn);if(l[c++]=d>>4,o<3){if(d&15)throw new SyntaxError(Ws);return l}let p=u[e.charCodeAt(f++)];if(p<0)throw new SyntaxError(Cn);if(l[c++]=d<<4&255|p>>2,p&3)throw new SyntaxError(Ws);return l}var{Buffer:tn,atob:Hc,btoa:Gc}=globalThis,Xc=tn&&!tn.TYPED_ARRAY_SUPPORT,{toBase64:zc}=Uint8Array.prototype,{E_CHAR:yr,E_PADDING:br,E_LENGTH:kx,E_LAST:vx}=Gs,Ex=Gc&&Kt,$x=Hc&&Kt,Sx=e=>e.constructor===tn&&tn.isBuffer(e),Ax=e=>Sx(e)?e:tn.from(e.buffer,e.byteOffset,e.byteLength);function Bc(e,t){if(t)return e;let n=e.indexOf("=",e.length-3);return n===-1?e:e.slice(0,n)}function jc(e,t){return t&&e.length%4!==0?e+"=".repeat(4-e.length%4):e}var Nx=e=>zc&&e.toBase64===zc;function kr(e,{padding:t=!0}={}){return On(e),Nx(e)?t?e.toBase64():e.toBase64({omitPadding:!t}):Xc?Bc(Ax(e).base64Slice(0,e.byteLength),t):Ex?Bc(Gc(js(e)),t):qs(e,!1,t)}function vr(e,t){if(typeof t=="string"&&(t={format:t}),!t)return Wc(e,!1,"both","uint8",null);let{format:n="uint8",padding:r="both",...o}=t;return Wc(e,!1,r,n,o)}function Wc(e,t,n,r,o){if(typeof e!="string")throw new TypeError(Co);o!==null&&zo(o);let i=n==="both"?e.endsWith("="):void 0;if(n===!0||i===!0){if(e.length%4!==0)throw new SyntaxError(br);if(e[e.length-3]==="=")throw new SyntaxError(br)}else if(n===!1||i===!1){if(e.length%4===1)throw new SyntaxError(kx);if(n===!1&&e.endsWith("="))throw new SyntaxError("Did not expect padding in base64 input")}else throw new TypeError("Invalid padding option");return xr(e,t,n,r)}var Ox=/[\t\n\f\r ]/;function qc(e,t){let n=e.indexOf("=",e.length-3),r=n>=0?e.length-n:0,o=e.length-r,i=o%4,s=t.length-(o-i)/4*3;return i===0&&s===0||i===2&&s===1||i===3&&s===2}var xr;Uint8Array.fromBase64?xr=(e,t,n,r)=>{let o=t?"base64url":"base64",i;if(n===!0)i=Uint8Array.fromBase64(e,{alphabet:o,lastChunkHandling:"strict"});else try{let s=e.length%4>0?`${e}${"=".repeat(4-e.length%4)}`:e;i=Uint8Array.fromBase64(s,{alphabet:o,lastChunkHandling:"strict"})}catch(s){throw Ox.test(e)?new SyntaxError(yr):s}if(!qc(e,i))throw new SyntaxError(yr);return Jt(i,r)}:Xc?xr=(e,t,n,r)=>{let o=tn.byteLength(e,"base64"),i=tn.allocUnsafeSlow(o);if(i.base64Write(e)!==o)throw new SyntaxError(br);let s=t?i.base64urlSlice(0,i.length):i.base64Slice(0,i.length);if(e!==s){if(n===!t)throw new SyntaxError(br);if(jc(e,!0)!==jc(s,t))throw new SyntaxError(br)}return hc(i,r)}:$x?xr=(e,t,n,r)=>{let o;if(t){if(/[\t\n\f\r +/]/.test(e))throw new SyntaxError(yr);e=e.replaceAll("-","+").replaceAll("_","/")}try{o=Lc(Hc(e))}catch{throw new SyntaxError(yr)}if(!t&&!qc(e,o))throw new SyntaxError(yr);if(o.length%3!==0){let i=kr(o.subarray(-(o.length%3))),s=e.length%4===0?e.slice(-4):e.slice(-(e.length%4)).padEnd(4,"=");if(i!==s)throw new SyntaxError(vx)}return Jt(o,r)}:xr=(e,t,n,r)=>Jt(Hs(e,t),r);var R=(e="")=>({stdout:e,stderr:"",exitCode:0}),b=(e,t=1)=>({stdout:"",stderr:e.endsWith(`
|
|
1
|
+
import{a as _o}from"./chunk-FK3DZEKL.js";import{b as fc,c as hr,d as Kt,e as dc,f as Xe,g as et,h as Fs,i as pc,j as On,k as Co,l as Jt,m as hc,n as Qt,o as T,p as mr,q as mc,r as Rs,s as Ms,t as Ds,v as gc,w as Us,z as Lo}from"./chunk-EDKLBQQN.js";import{a as cc}from"./chunk-TZ5KB2Y5.js";import"./chunk-XYFXXB2G.js";import"./chunk-C4Z6ZBXV.js";import{a as uc,c as Ge,g as Ls,j as lc}from"./chunk-2XUEZHIP.js";import{b as nx}from"./chunk-OOJM4CTU.js";var rx={__proto__:null,ENOENT:"No such file or directory",ENOTDIR:"Not a directory",EISDIR:"Is a directory",EEXIST:"File exists",ENOTEMPTY:"Directory not empty",ELOOP:"Too many levels of symbolic links",EINVAL:"Invalid argument",EPERM:"Operation not permitted",EBUSY:"Device or resource busy",EILSEQ:"Invalid or incomplete multibyte or wide character",ENAMETOOLONG:"File name too long"},ox=/[\p{Cc}\p{Zl}\p{Zp}\p{Bidi_Control}]/gu,ix=e=>`${e}`.replaceAll(ox,t=>`\\u${t.codePointAt(0).toString(16).padStart(4,"0")}`),Ue=(e,t,n="a string")=>new TypeError(`${e} must be ${n}, not ${t===null?"null":typeof t}`),F=class extends Error{constructor(t,n){super(`${ix(n)}: ${rx[t]??t}`),this.name="VfsError",this.code=t,this.path=n}};var wc=(e,t="path")=>{if(typeof e!="string")throw Ue(t,e);return e};function yc(e,t){let n=Math.min(wc(e).length,wc(t).length);for(let r=0;r<n;r++)if(e[r]!==t[r])return e.codePointAt(r)-t.codePointAt(r);return e.length-t.length}var gr=e=>[...e.entries.keys()].sort(yc),Fo=(e,t)=>t===""?e:e==="/"?`/${t}`:`${e}/${t}`;function*en(e,t=r=>r,n=()=>!0){let r=[{name:"",node:e,depth:0}];for(;r.length>0;){let o=r.pop();if(yield t(o),o.node.type!=="directory"||!n(o))continue;let i=gr(o.node);for(let s=i.length-1;s>=0;s--){let a=o.name===""?i[s]:`${o.name}/${i[s]}`;r.push({name:a,leaf:i[s],parent:o.node,node:o.node.entries.get(i[s]),depth:o.depth+1})}}}var sx=new Set(["error","keep","replace"]);function xc(e,t,n="'error', 'keep' or 'replace'"){if(typeof e!="string")throw Ue(t,e,n);if(!sx.has(e))throw new RangeError(`${t} must be ${n}, not ${JSON.stringify(e)}`);return e}function bc({clash:e="error",fold:t}){if(typeof e!="function"&&xc(e,"clash","'error', 'keep', 'replace' or a function"),t!==void 0&&typeof t!="function")throw Ue("fold",t,"a function");return{fold:t,settle:typeof e=="function"?(n,r)=>xc(e(n,r),"what clash returns"):()=>e}}function kc(e,t,n,{settle:r,fold:o},i){let s=ax(t,i.copy),a=new Map([[s,{into:e}]]),u=[];for(let{name:l,leaf:c,parent:f,node:d}of en(s,void 0,p=>a.has(p.node))){if(f===void 0)continue;let p=a.get(f),h=p.into.entries.get(c);if(h?.type==="directory"&&d.type==="directory"){a.set(d,{into:h});continue}let m=h===void 0?ux(p,f,c,o):[c];if(m.length>0){let g=Fo(n,l),w=r(g,m.map(y=>g.slice(0,-c.length)+y));if(w==="error")throw new F("EEXIST",g);if(w==="keep")continue}u.push({dir:p.into,name:c,node:d,taken:m})}for(let{dir:l,name:c,node:f,taken:d}of u){for(let p of en(f))i.number(p.node);for(let p of d)l.entries.delete(p);l.entries.set(c,f)}}function*vc(e,t,n){for(let{name:r,node:o}of en(e))if(o.type==="directory")for(let i of Map.groupBy(gr(o),s=>n(s)).values())i.length>1&&(yield{path:Fo(t,r),names:i})}function ax(e,t){let n=new Map;for(let{node:r,parent:o,leaf:i}of en(e))n.has(r)||n.set(r,t(r)),o!==void 0&&n.get(o).entries.set(i,n.get(r));return n.get(e)}function ux(e,t,n,r){return r===void 0?[]:(e.keys??=Map.groupBy(gr(e.into).filter(o=>!t.entries.has(o)),o=>r(o)),e.keys.get(r(n))??[])}var lx=40,cx=255,Sc=4096,fx=new Uint8Array,Ac={file:420,directory:493,symlink:511},dx=new TextEncoder,px=new TextDecoder("utf-8",{fatal:!0,ignoreBOM:!0}),Ro=e=>typeof e=="string"&&e.endsWith("/"),In=class{#t;#s=0;constructor(){this.#t=this.#e()}#n(t,n,r=Ac[t],o=0){return{ino:++this.#s,type:t,mode:Uo(r),mtime:Po(o),...n}}#e(t,n){return this.#n("directory",{entries:new Map},t,n)}#i(t,{follow:n=!0,mkdirs:r=!1,create:o=!1}={}){if(typeof t!="string")throw Ue("a path",t);if(t.includes("\0"))throw new F("EINVAL",t);if(t==="")throw new F("ENOENT",t);let i=t.endsWith("/"),s=[Ec(t)],a=[{name:"",node:this.#t}],u=lx,l,c,f,d;for(;;){for(;s.length>1&&Ps(s.at(-1));)s.pop();if(Ps(s.at(-1))){({name:f,node:d}=a.pop()),l=void 0;break}if(c=s.length>1,f=hx(s.at(-1)),f===".")continue;if(f===".."){a.length>1&&a.pop();continue}l=a.at(-1).node;let p=s.every(Ps);if(d=l.entries.get(f),o&&!p&&s.every(zs)){i=!0;break}if(d===void 0){if(p)break;if(!r||c)throw new F("ENOENT",t);Do(f,t),d=this.#e(),l.entries.set(f,d)}if(d.type==="symlink"&&(!p||n)){if(u--===0)throw new F("ELOOP",t);d.target.startsWith("/")&&(a.length=1),s.push(Ec(d.target,!0));continue}if(p){if(i&&!o&&d.type!=="directory")throw new F("ENOTDIR",t);break}if(d.type!=="directory")throw new F("ENOTDIR",t);a.push({name:f,node:d})}return{dir:l,name:f,node:d,trailing:i,chain:a,linked:c}}#r(t,n=!0){let r=this.#i(t,{follow:n});if(r.node===void 0)throw new F("ENOENT",t);return r}#o(t,n){return this.#r(t,n).node}#u(t,n,r){Do(t.name,r),t.dir.entries.set(t.name,n)}#a(t,n){if(t.dir!==void 0)return t.dir;throw new F(Bs(n,0)===n.length?"EBUSY":"EINVAL",n)}#l(t,n,r){try{return this.#o(t,r).type===n}catch(o){if(o instanceof F)return!1;throw o}}stat(t){return $c(this.#o(t,!0))}lstat(t){return $c(this.#o(t,Ro(t)))}isFile(t){return this.#l(t,"file",!0)}isDirectory(t){return this.#l(t,"directory",!0)}isSymlink(t){return this.#l(t,"symlink",!1)}realpath(t){return Mo(this.#r(t))}readFile(t){let n=this.#o(t,!0);if(n.type==="directory")throw new F("EISDIR",t);return n.bytes}readText(t){let n=this.readFile(t);try{return px.decode(n)}catch{throw new F("EILSEQ",t)}}readlink(t){let n=this.#o(t,Ro(t));if(n.type!=="symlink")throw new F("EINVAL",t);return n.target}readdir(t){let n=this.#o(t,!0);if(n.type!=="directory")throw new F("ENOTDIR",t);return gr(n)}#c(t,n,r,o,i){let s=Ic(n,t),a=this.#i(t,{follow:!Ro(t),create:!0});if(a.trailing||a.node?.type==="directory")throw new F("EISDIR",t);a.node===void 0?this.#u(a,this.#n("file",{bytes:s},o,i),t):r(a.node,s)}writeFile(t,n,{mode:r,mtime:o}={}){this.#c(t,n,(i,s)=>Object.assign(i,{bytes:s,...mx(i,r,o)}),r,o)}appendFile(t,n){this.#c(t,n,(r,o)=>{r.bytes=wx(r.bytes,o)})}mkdir(t,{recursive:n=!1,mode:r,mtime:o}={}){let i=this.#i(t,{follow:n,mkdirs:n,create:!n});if(i.node===void 0){if(i.linked)throw new F("ENOENT",t);this.#u(i,this.#e(r,o),t)}else if(!n||i.node.type!=="directory")throw new F("EEXIST",t)}symlink(t,n,{mode:r,mtime:o}={}){if(typeof t!="string")throw Ue("a link target",t);if(t===""||t.includes("\0"))throw new F("EINVAL",n);Do(t,n,Sc),this.#u(this.#f(n),this.#n("symlink",{target:t,size:Nc(t)},r,o),n)}hardlink(t,n){let r=this.#o(t,Ro(t)),o=this.#f(n);if(r.type==="directory")throw new F("EPERM",t);this.#u(o,r,n)}#f(t){let n=this.#i(t,{follow:!1,create:!0});if(n.node!==void 0)throw new F("EEXIST",t);if(n.trailing)throw new F("ENOENT",t);return n}unlink(t){this.rm(t)}rmdir(t){let n=this.#r(t,!1);if(n.node.type!=="directory")throw new F("ENOTDIR",t);let r=this.#a(n,t);if(n.node.entries.size>0)throw new F("ENOTEMPTY",t);r.entries.delete(n.name)}rm(t,{recursive:n=!1}={}){let r=this.#r(t,!1);if(r.node.type==="directory"&&!n)throw new F("EISDIR",t);this.#a(r,t).entries.delete(r.name)}rename(t,n){let r=this.#i(t,{follow:!1,create:!0}),o=this.#i(n,{follow:!1,create:!0}),i=this.#a(r,t),s=this.#a(o,n);if(r.node===void 0)throw new F("ENOENT",t);Do(o.name,n);let a=r.node.type==="directory";if(!a&&(r.trailing||o.trailing))throw new F("ENOTDIR",r.trailing?t:n);if(o.chain.some(u=>u.node===r.node))throw new F("EINVAL",n);if(r.chain.some(u=>u.node===o.node))throw new F("ENOTEMPTY",n);if(o.node!==r.node){if(o.node!==void 0&&o.node.type==="directory"!==a)throw new F(a?"ENOTDIR":"EISDIR",n);if(o.node?.type==="directory"&&o.node.entries.size>0)throw new F("ENOTEMPTY",n);i.entries.delete(r.name),s.entries.set(o.name,r.node)}}chmod(t,n){this.#o(t,!0).mode=Uo(n)}utimes(t,n){this.#o(t,!0).mtime=Po(n)}mount(t,n="/",r={}){if(t===null||typeof t!="object"||!(#t in t))throw Ue("a tree",t,"a Vfs");let o=bc(r),i=this.#r(n);if(i.node.type!=="directory")throw new F("ENOTDIR",n);kc(i.node,t.#t,Mo(i),o,{copy:gx,number:s=>{s.ino||=++this.#s}})}walk(t="/"){let n=this.#r(t),r=Mo(n);return en(n.node,({name:o,node:i,depth:s})=>({path:Fo(r,o),type:i.type,depth:s}))}collisions(t,n="/"){if(typeof t!="function")throw Ue("fold",t,"a function");let r=this.#r(n);return vc(r.node,Mo(r),t)}entries(t="/"){let n=this.#r(t),r=n.node.type==="directory"?".":n.name,o=new Map;return en(n.node,({name:i,node:s})=>{let a=i===""?r:i,u={name:a,type:s.type,mode:s.mode,mtime:s.mtime,linkname:"",data:fx},l=o.get(s);return l!==void 0?(u.type="hardlink",u.linkname=l):s.type==="symlink"?(o.set(s,a),u.linkname=s.target):s.type==="file"&&(o.set(s,a),u.data=s.bytes),u})}},Ec=(e,t=!1)=>({text:e,at:Bs(e,0),dot:t&&e.endsWith("/")}),zs=e=>e.at===e.text.length,Ps=e=>zs(e)&&!e.dot,Bs=(e,t)=>{let n=t;for(;e[n]==="/";)n++;return n};function hx(e){if(zs(e))return e.dot=!1,".";let t=e.text.indexOf("/",e.at),n=t===-1?e.text.length:t,r=e.text.slice(e.at,n);return e.at=Bs(e.text,n),r}var Mo=({chain:e,name:t})=>`/${[...e.slice(1).map(n=>n.name),t].filter(Boolean).join("/")}`,$c=e=>({type:e.type,ino:e.ino,mode:e.mode,mtime:e.mtime,size:e.bytes?.length??e.size??0}),mx=(e,t=e.mode,n=e.mtime)=>({mode:Uo(t),mtime:Po(n)});function Do(e,t,n=cx){if(!e.isWellFormed())throw new F("EILSEQ",t);if(Oc(e,n))throw new F("ENAMETOOLONG",t)}function Nc(e){let t=0;for(let n of e){let r=n.codePointAt(0);t+=r<128?1:r<2048?2:r<65536?3:4}return t}var Oc=(e,t)=>e.length>t||e.length*3>t&&Nc(e)>t;function Uo(e){if(!Number.isInteger(e)||e<0||e>4095)throw new RangeError(`a mode must be an integer from 0 to 0o7777, not ${e}`);return e}function Po(e){if(!Number.isSafeInteger(e))throw new RangeError(`an mtime must be an integer of whole seconds, not ${e}`);return e}function Ic(e,t){if(typeof e=="string"){if(!e.isWellFormed())throw new F("EILSEQ",t);return dx.encode(e)}if(e instanceof Uint8Array)return new Uint8Array(e);throw Ue("file contents",e,"a string or a Uint8Array")}function gx({type:e,mode:t,mtime:n,bytes:r,target:o,size:i}){let s={ino:0,type:e,mode:t,mtime:n};return e==="directory"?s.entries=new Map:e==="symlink"?Object.assign(s,{target:o,size:i}):s.bytes=r.byteOffset+r.length===r.buffer.byteLength?r:r.slice(),s}function wx(e,t){let n=e.length+t.length,r=e.byteOffset+n<=e.buffer.byteLength,o=r?new Uint8Array(e.buffer,e.byteOffset,n):new Uint8Array(Math.max(n,e.length*2)).subarray(0,n);return r||o.set(e),o.set(t,e.length),o}function zo(e){if(Object.keys(e).length>0)throw new TypeError("Unexpected extra options")}var p4=Object.getPrototypeOf(Uint8Array);var Cc=globalThis.atob,_c=Uint8Array.prototype.toBase64,Tc=8192,yx=_c&&Cc;function js(e,t=0,n=e.length){t|=0,n|=0;let r=n-t;if(r===0)return"";if(yx&&r>=256&&r<1e8&&e.toBase64===_c&&e.BYTES_PER_ELEMENT===1){let i=t===0&&n===e.length?e:e.subarray(t,n);return Cc(i.toBase64())}if(r>Tc){let i="";for(let s=t;s<n;){let a=Math.min(n,s+Tc);i+=String.fromCharCode.apply(String,e.subarray(s,a)),s=a}return i}let o=t===0&&n===e.length?e:e.subarray(t,n);return String.fromCharCode.apply(String,o)}var Tn=hr?e=>e.byteLength>=768&&!dc?hr.from(e.buffer,e.byteOffset,e.byteLength).latin1Slice(0,e.byteLength):et.decode(e):Fs?e=>Fs.decode(e):e=>js(e instanceof Uint8Array?e:new Uint8Array(e.buffer,e.byteOffset,e.byteLength));var Lc=e=>fc(e,new Uint8Array(e.length)),xx=Kt&&Xe?.encodeInto,wr=xx?(e,t)=>{let n=new Uint8Array(e.length+4),r=Xe.encodeInto(e,n);if(r.read!==e.length||r.written!==e.length)throw new SyntaxError(t);return n.subarray(0,e.length)}:hr?(e,t)=>{let n=hr.from(e,"utf8");if(n.length!==e.length)throw new SyntaxError(t);return new Uint8Array(n.buffer,n.byteOffset,n.byteLength)}:(e,t)=>{let n=Xe.encode(e);if(n.length!==e.length)throw new SyntaxError(t);return n};var Gs={};nx(Gs,{E_CHAR:()=>Cn,E_LAST:()=>Ws,E_LENGTH:()=>Pc,E_PADDING:()=>Uc,fromBase64:()=>Hs,toBase64:()=>qs});var Fc=[..."ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"],Rc=[..."ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"],Mc={},Dc={},Cn="Invalid character in base64 input",Uc="Invalid base64 padding",Pc="Invalid base64 length",Ws="Invalid last chunk";function qs(e,t,n){let r=e.length/3|0,o=r*3,i="",s=0,a=t?Rc:Fc,u=t?Dc:Mc;if(!u.pairs)if(u.pairs=[],et){u.codepairs=new Uint16Array(4096);let h=u.codepairs,m=new Uint8Array(h.buffer,h.byteOffset,h.byteLength);for(let g=0;g<64;g++){let w=a[g].charCodeAt(0);for(let y=0;y<64;y++)m[g<<7|y<<1]=m[y<<7|(g<<1)+1]=w}}else{let h=u.pairs;for(let m=0;m<64;m++)for(let g=0;g<64;g++)h.push(`${a[m]}${a[g]}`)}let{pairs:l,codepairs:c}=u;if(et){let h=new Uint16Array(r*2),m=0;for(let g=e.length-11;s<g;s+=12,m+=8){let w=e[s],y=e[s+1],$=e[s+2],S=e[s+3],_=e[s+4],W=e[s+5],H=e[s+6],re=e[s+7],le=e[s+8],ce=e[s+9],An=e[s+10],Nn=e[s+11];h[m]=c[w<<4|y>>4],h[m+1]=c[(y&15)<<8|$],h[m+2]=c[S<<4|_>>4],h[m+3]=c[(_&15)<<8|W],h[m+4]=c[H<<4|re>>4],h[m+5]=c[(re&15)<<8|le],h[m+6]=c[ce<<4|An>>4],h[m+7]=c[(An&15)<<8|Nn]}for(let g=e.length-2;s<g;s+=3,m+=2){let w=e[s],y=e[s+1],$=e[s+2];h[m]=c[w<<4|y>>4],h[m+1]=c[(y&15)<<8|$]}i=Tn(h)}else for(;s<o;s+=3){let h=e[s],m=e[s+1],g=e[s+2];i+=l[h<<4|m>>4],i+=l[(m&15)<<8|g]}let f=0,d=2,p=e.length;for(;s<p;s++){let h=e[s];i+=a[f|h>>d],d===6&&(d=0,i+=a[h&63]),f=h<<6-d&63,d+=2}return d!==2&&(i+=a[f]),n&&(i+=["","==","="][p-o]),i}var bx=Xe?128:65536;function Hs(e,t){let n=e.length;for(;e[n-1]==="=";)n--;let r=e.length-n,o=n%4,i=n-o;if(o===1)throw new SyntaxError(Pc);if(r>3||r!==0&&e.length%4!==0)throw new SyntaxError(Uc);let s=t?Rc:Fc,a=t?Dc:Mc;a.fromMap||(a.fromMap=new Int8Array(bx).fill(-1),s.forEach((h,m)=>a.fromMap[h.charCodeAt(0)]=m));let u=a.fromMap,l=new Uint8Array(Math.floor(n*3/4)),c=0,f=0;if(Xe){let h=wr(e,Cn);for(;f<i;f+=4){let m=h[f],g=h[f+1],w=h[f+2],y=h[f+3],$=u[m]<<18|u[g]<<12|u[w]<<6|u[y];if($<0)throw new SyntaxError(Cn);l[c]=$>>16,l[c+1]=$>>8&255,l[c+2]=$&255,c+=3}}else for(;f<i;f+=4){let h=e.charCodeAt(f),m=e.charCodeAt(f+1),g=e.charCodeAt(f+2),w=e.charCodeAt(f+3),y=u[h]<<18|u[m]<<12|u[g]<<6|u[w];if(y<0)throw new SyntaxError(Cn);l[c]=y>>16,l[c+1]=y>>8&255,l[c+2]=y&255,c+=3}if(o<2)return l;let d=u[e.charCodeAt(f++)]<<6|u[e.charCodeAt(f++)];if(d<0)throw new SyntaxError(Cn);if(l[c++]=d>>4,o<3){if(d&15)throw new SyntaxError(Ws);return l}let p=u[e.charCodeAt(f++)];if(p<0)throw new SyntaxError(Cn);if(l[c++]=d<<4&255|p>>2,p&3)throw new SyntaxError(Ws);return l}var{Buffer:tn,atob:Hc,btoa:Gc}=globalThis,Xc=tn&&!tn.TYPED_ARRAY_SUPPORT,{toBase64:zc}=Uint8Array.prototype,{E_CHAR:yr,E_PADDING:br,E_LENGTH:kx,E_LAST:vx}=Gs,Ex=Gc&&Kt,$x=Hc&&Kt,Sx=e=>e.constructor===tn&&tn.isBuffer(e),Ax=e=>Sx(e)?e:tn.from(e.buffer,e.byteOffset,e.byteLength);function Bc(e,t){if(t)return e;let n=e.indexOf("=",e.length-3);return n===-1?e:e.slice(0,n)}function jc(e,t){return t&&e.length%4!==0?e+"=".repeat(4-e.length%4):e}var Nx=e=>zc&&e.toBase64===zc;function kr(e,{padding:t=!0}={}){return On(e),Nx(e)?t?e.toBase64():e.toBase64({omitPadding:!t}):Xc?Bc(Ax(e).base64Slice(0,e.byteLength),t):Ex?Bc(Gc(js(e)),t):qs(e,!1,t)}function vr(e,t){if(typeof t=="string"&&(t={format:t}),!t)return Wc(e,!1,"both","uint8",null);let{format:n="uint8",padding:r="both",...o}=t;return Wc(e,!1,r,n,o)}function Wc(e,t,n,r,o){if(typeof e!="string")throw new TypeError(Co);o!==null&&zo(o);let i=n==="both"?e.endsWith("="):void 0;if(n===!0||i===!0){if(e.length%4!==0)throw new SyntaxError(br);if(e[e.length-3]==="=")throw new SyntaxError(br)}else if(n===!1||i===!1){if(e.length%4===1)throw new SyntaxError(kx);if(n===!1&&e.endsWith("="))throw new SyntaxError("Did not expect padding in base64 input")}else throw new TypeError("Invalid padding option");return xr(e,t,n,r)}var Ox=/[\t\n\f\r ]/;function qc(e,t){let n=e.indexOf("=",e.length-3),r=n>=0?e.length-n:0,o=e.length-r,i=o%4,s=t.length-(o-i)/4*3;return i===0&&s===0||i===2&&s===1||i===3&&s===2}var xr;Uint8Array.fromBase64?xr=(e,t,n,r)=>{let o=t?"base64url":"base64",i;if(n===!0)i=Uint8Array.fromBase64(e,{alphabet:o,lastChunkHandling:"strict"});else try{let s=e.length%4>0?`${e}${"=".repeat(4-e.length%4)}`:e;i=Uint8Array.fromBase64(s,{alphabet:o,lastChunkHandling:"strict"})}catch(s){throw Ox.test(e)?new SyntaxError(yr):s}if(!qc(e,i))throw new SyntaxError(yr);return Jt(i,r)}:Xc?xr=(e,t,n,r)=>{let o=tn.byteLength(e,"base64"),i=tn.allocUnsafeSlow(o);if(i.base64Write(e)!==o)throw new SyntaxError(br);let s=t?i.base64urlSlice(0,i.length):i.base64Slice(0,i.length);if(e!==s){if(n===!t)throw new SyntaxError(br);if(jc(e,!0)!==jc(s,t))throw new SyntaxError(br)}return hc(i,r)}:$x?xr=(e,t,n,r)=>{let o;if(t){if(/[\t\n\f\r +/]/.test(e))throw new SyntaxError(yr);e=e.replaceAll("-","+").replaceAll("_","/")}try{o=Lc(Hc(e))}catch{throw new SyntaxError(yr)}if(!t&&!qc(e,o))throw new SyntaxError(yr);if(o.length%3!==0){let i=kr(o.subarray(-(o.length%3))),s=e.length%4===0?e.slice(-4):e.slice(-(e.length%4)).padEnd(4,"=");if(i!==s)throw new SyntaxError(vx)}return Jt(o,r)}:xr=(e,t,n,r)=>Jt(Hs(e,t),r);var R=(e="")=>({stdout:e,stderr:"",exitCode:0}),b=(e,t=1)=>({stdout:"",stderr:e.endsWith(`
|
|
2
2
|
`)?e:e+`
|
|
3
3
|
`,exitCode:t}),xe=(e,t=1)=>b(`usage: ${e}`,t);var Zc=Symbol("unsupported");function C(e){if(e==null)return null;try{return e[Zc]??null}catch{return null}}function v(e,t,n,r,o=1){return X(b(r,o),e,t,n,r)}function X(e,t,n,r,o){return Object.defineProperty(e,Zc,{value:{kind:t,command:n,detail:r,message:o},enumerable:!1,configurable:!0}),e}function Q(e,t,n,r){let o=C(e);return o?v(o.kind,t,o.detail,n,r):b(n,r)}var x=class extends Error{constructor(t,n,r){super(r),this.name="UnsupportedError",X(this,t,null,n,r)}};function Xs(){let e=new Set,t=[];return{entries:t,add(n,r=n.command){let o=JSON.stringify([n.kind,r,n.detail]);e.has(o)||(e.add(o),t.push(Object.freeze(n)))}}}function I(e){try{return Qt(e)}catch(t){throw t instanceof TypeError?new x("feature","unpaired surrogate","unpaired UTF-16 surrogates cannot be encoded as UTF-8"):t}}var Ix=e=>e<128?1:e>=194&&e<=223?2:e>=224&&e<=239?3:e>=240&&e<=244?4:0;function*Bo(e){for(let t=0;t<e.length;){let n=Kc[e[t]],r=n===1?e[t]:n===0?-1:Vc(e,t,n);yield r,t+=r<0?1:n}}var Tx=[0,0,128,2048,65536];function Vc(e,t,n){if(t+n>e.length)return-1;let r=e[t]&127>>n;for(let o=1;o<n;o++){if((e[t+o]&192)!==128)return-1;r=r<<6|e[t+o]&63}return r<Tx[n]||r>1114111||r>=55296&&r<=57343?-1:r}var Ys=e=>mc(e);function ve(e){let t;try{t=mr(e)}catch{}return t}function Vs(e){let t=ve(e);if(t!==void 0)return t;let n=new Uint16Array(e.length),r=0;for(let i=0;i<e.length;){let s=Kc[e[i]],a=s===1?e[i]:s===0?-1:Vc(e,i,s);if(a<0){n[r++]=56320+e[i++];continue}a>65535?(n[r++]=55232+(a>>10),n[r++]=56320+(a&1023)):n[r++]=a,i+=s}let o="";for(let i=0;i<r;i+=Yc)o+=String.fromCharCode.apply(null,n.subarray(i,Math.min(r,i+Yc)));return o}var Yc=4096,Kc=Uint8Array.from({length:256},(e,t)=>Ix(t)),nn="\\uDC80-\\uDCFF",_n=new RegExp(`[${nn}]`,"u"),_t=e=>e>=56448&&e<=56575;function Ks(e){if(!_n.test(e))return I(e);let t=new Uint8Array(e.length*3),n=0;for(let r=0;r<e.length;r++){let o=e.codePointAt(r);if(o<128)t[n++]=o;else if(_t(o))t[n++]=o-56320;else if(o<2048)n=Zs(t,n,192|o>>6,o,1);else if(o<65536){if(o>=55296&&o<=57343)return I(e);n=Zs(t,n,224|o>>12,o,2)}else n=Zs(t,n,240|o>>18,o,3),r++}return t.slice(0,n)}function Zs(e,t,n,r,o){e[t++]=n;for(let i=o-1;i>=0;i--)e[t++]=128|r>>6*i&63;return t}function Ze(e){if(e.length===1)return e[0];let t=new Uint8Array(e.reduce((r,o)=>r+o.length,0)),n=0;for(let r of e)t.set(r,n),n+=r.length;return t}function G(e){try{return mr(e)}catch{throw new x("feature","partial UTF-8 byte sequence","byte output that is not valid UTF-8 cannot be represented by this string-based terminal")}}function Ln(e){let t=e.startsWith("/"),n=e.split("/").filter(Boolean),r=[];for(let o of n)if(o!=="."){if(o===".."){r.length>0&&r.at(-1)!==".."?r.pop():t||r.push("..");continue}r.push(o)}return t?"/"+r.join("/"):r.length===0?".":r.join("/")}function j(e,t){return t.startsWith("/")?Ln(t):Ln(e+"/"+t)}var Cx=40,jo=(e,t)=>e.isLink?.(t)===!0;function E(e,t,n,{follow:r=!0}={}){let o=tt(e,t,n,{follow:r});return o.error?{path:null,error:o.error}:t.endsWith("/")&&!n.isDir(o.path)?{path:null,error:"Not a directory"}:{path:o.path,error:null}}function tt(e,t,n,{follow:r=!0,lenient:o=!1}={}){if(t===""||t.includes("\0"))return{path:"/",error:"No such file or directory",rest:[]};let i=(t.startsWith("/")?t:e+"/"+t).split("/").filter(Boolean),s=r||t.endsWith("/"),a=Cx,u="/";for(;i.length>0;){let c=i.shift();if(!n.isDir(u)){if(!o){let d=n.isFile(u)||jo(n,u)?"Not a directory":"No such file or directory";return{path:u,error:d,rest:[c,...i]}}c===".."?u=oe(u):c!=="."&&(u=he(u,c));continue}if(c===".."){u=oe(u);continue}if(c!=="."&&(u=he(u,c)),!jo(n,u)||i.length===0&&!s)continue;if(a--===0)return{path:u,error:"Too many levels of symbolic links",rest:[...i]};let f=n.readLink(u);u=f.startsWith("/")?"/":oe(u),i.unshift(...f.split("/").filter(Boolean),...f.endsWith("/")?["."]:[])}let l=!n.isDir(u)&&!n.isFile(u)&&!jo(n,u);return{path:u,error:l?"No such file or directory":null,rest:[]}}var me=(e,t,n,r=!0)=>n===""||n.includes("\0")?j(t,n):tt(t,n,e,{follow:r,lenient:!0}).path;function gt(e,t,n,r=E(e,t,n)){if(r.path!==null)return null;if(t===""||t.includes("\0")||t.endsWith("/")||r.error!=="No such file or directory")return r.error;let o=tt(e,t,n);return o.rest.length>0?o.error:n.isDir(oe(o.path))?null:"Not a directory"}function oe(e){let t=Ln(e);if(t==="/")return"/";let n=t.lastIndexOf("/");return n<0?".":n===0?"/":t.slice(0,n)}function Ne(e){let t=Ln(e);if(t==="/")return"/";let n=t.lastIndexOf("/");return t.slice(n+1)}function q(e,t){for(let n=0;n<Math.min(e.length,t.length);n++)if(e[n]!==t[n])return e.codePointAt(n)-t.codePointAt(n);return e.length-t.length}function he(e,t){return e==="/"?"/"+t:e+"/"+t}function nt(e,t){return e==="/"?t.slice(1):t.slice(e.length+1)}function Lt(e,t,n="reading them as text"){let r=ve(e);if(r===void 0)throw new x("feature","binary file",`${t} holds bytes that spell no text, and ${n} is not supported`);return r}var Er=(e,t)=>e!==void 0&&t!==void 0&&e.length===t.length&&e.every((n,r)=>n===t[r]);function*rt(e,t,n=Number.POSITIVE_INFINITY,r=()=>!0){if(e.isFile(t)){yield{path:t,kind:"file",depth:0};return}if(!e.isDir(t)){jo(e,t)&&(yield{path:t,kind:"link",depth:0});return}let o=[{path:t,kind:"dir",depth:0}];for(;o.length;){let i=o.pop();if(yield i,i.kind!=="dir"||i.depth>=n||!r(i.path))continue;let{dirs:s,files:a,links:u=[]}=e.listDir(i.path),l=s.length-1,c=a.length-1,f=u.length-1;for(;l>=0||c>=0||f>=0;){let d=l>=0?"dir":null,p=l>=0?s[l]:null;c>=0&&(p===null||q(a[c],p)>=0)&&(d="file",p=a[c]),f>=0&&(p===null||q(u[f],p)>=0)&&(d="link",p=u[f]),d==="dir"?l--:d==="file"?c--:f--,o.push({path:he(i.path,p),kind:d,depth:i.depth+1})}}}function*Jc(e,t){for(let n of rt(e,t))n.kind==="file"&&(yield n.path)}function rf(e,t="/"){let n=new In;try{n.mkdir(t,{recursive:!0})}catch(o){throw Js(o,`mount ${JSON.stringify(t)}`)}let r={declared:new Map,made:new Set(["/",t])};for(let[o,i]of Mx(e)){let s=String(o);if(s.includes("\0"))throw new TypeError("createTerminal: source paths must not contain NUL characters");let a=Ux(i,s),u=Ln("/"+s);_x(n,r,t==="/"?u:u==="/"?t:t+u,a,s)}return Fx(n)}function _x(e,t,n,r,o){let i=t.declared.get(n);if(i!==void 0){if(i===r.type&&Lx(e,n,r))return;throw new TypeError(`createTerminal: source ${JSON.stringify(o)} names the same path as an earlier source, which declared something else there`)}t.declared.set(n,r.type);let s=n.slice(0,n.lastIndexOf("/"))||"/";if(!t.made.has(s)){try{e.mkdir(s,{recursive:!0})}catch(a){throw a?.code==="ENOENT"?Qc(o):Js(a?.code==="EEXIST"?new F("ENOTDIR",s):a,`source ${JSON.stringify(o)}`)}if(e.realpath(s)!==s)throw Qc(o);t.made.add(s)}try{if(r.type==="file")e.writeFile(n,r.data);else if(r.type==="symlink")e.symlink(r.target,n);else{try{e.mkdir(n)}catch(a){if(a?.code!=="EEXIST"||e.lstat(n).type!=="directory")throw a}t.made.add(n)}}catch(a){throw Js(a,`source ${JSON.stringify(o)}`)}}var Qc=e=>new TypeError(`createTerminal: source ${JSON.stringify(e)} is declared through a symbolic link; declare it where the link leads`);function Js(e,t){return e instanceof F?new TypeError(`createTerminal: ${t}: ${e.message}`,{cause:e}):e}function Lx(e,t,n){return n.type==="directory"?!0:n.type==="symlink"?e.readlink(t)===n.target:Er(e.readFile(t),typeof n.data=="string"?I(n.data):n.data)}var of={directory:"dirs",file:"files",symlink:"links"},Wo=e=>e.slice(0,e.lastIndexOf("/"))||"/",Qs=()=>({dirs:[],files:[],links:[]});function Fx(e){let t=null,n=null,r={children:new Map,types:new Map},o=()=>n??=Rx(e,s),i=new WeakMap,s=d=>t!==null&&(d===t||d.startsWith(t+"/")),a=d=>{let p=r.children.get(d);if(p!==void 0)return p;p={listing:Qs(),types:new Map};for(let h of e.readdir(d)){let{type:m}=e.lstat(he(d,h));p.types.set(h,m),p.listing[of[m]].push(h)}return r.children.set(d,p),p},u=d=>{if(typeof d!="string"||!d.startsWith("/"))return;if(d==="/")return"directory";let p=[],h=d;for(;s(Wo(h))&&!r.types.has(h);)p.push(h),h=Wo(h);let m=s(Wo(h))?r.types.get(h):o().types.get(h)??"";for(let g=p.length-1;g>=0;g--){let w=p[g];m=m==="directory"?a(Wo(w)).types.get(w.slice(w.lastIndexOf("/")+1))??"":"",r.types.set(w,m)}return m||void 0},l=d=>u(d)===void 0?void 0:e.lstat(d),c=d=>u(d)==="file"?e.readFile(d):void 0,f={vfs:e,writableAt:d=>{t=d,n=null,r={children:new Map,types:new Map}},reshaped:()=>{r={children:new Map,types:new Map}},isFile:d=>u(d)==="file",isDir:d=>u(d)==="directory",isLink:d=>u(d)==="symlink",readLink:d=>u(d)==="symlink"?e.readlink(d):void 0,readFile:d=>{let p=c(d),h=p&&i.get(p);return p&&h===void 0&&i.set(p,h=Lt(p,JSON.stringify(d))),h},readBytes:d=>c(d),fileSize:d=>{let p=l(d);return p===void 0||p.type==="directory"?void 0:p.size},sameFileContents:(d,p)=>Er(c(d),c(p)),exactBytes:c,isBytes:d=>u(d)==="file",isEmptyFile:d=>{let p=l(d);return p?.type==="file"&&p.size===0},listDir:d=>{if(u(d)!=="directory")throw new Error(`not a directory: ${d}`);return s(d)?a(d).listing:o().children.get(d)},walkFiles:d=>Jc(f,d)};return f}function Rx(e,t){let n=new Map([["/",Qs()]]),r=new Map([["/","directory"]]),o=["/"];for(let{path:i,type:s,depth:a}of e.walk("/")){if(a===0)continue;let u=o[a-1];s==="directory"&&(o[a]=i),!t(u)&&(s==="directory"&&n.set(i,Qs()),n.get(u)[of[s]].push(i.slice(u.length+(u==="/"?0:1))),r.set(i,s))}return{children:n,types:r}}function Mx(e){try{return Map.prototype.entries.call(e)}catch{return Object.entries(e??{})}}var ef={file:["data"],directory:[],symlink:["target"]},Dx=new Set(["mode","mtime"]);function Ux(e,t){let n=JSON.stringify(t);if(typeof e=="string")return{type:"file",data:tf(e,t)};if(ArrayBuffer.isView(e))return{type:"file",data:nf(e,t)};if(e instanceof ArrayBuffer)throw new TypeError(`createTerminal: source ${n} is an ArrayBuffer; declare a file's bytes as a Uint8Array over it`);if(e===null||typeof e!="object"||Array.isArray(e)){let i=e===null?"null":Array.isArray(e)?"an array":e===void 0?"undefined":`a ${typeof e}`;throw new TypeError(`createTerminal: source ${n} is ${i}; a source is text, a Uint8Array, or an object declaring its type`)}if(e.format!==void 0)return{type:"file",data:Px(e,t)};let{type:r}=e;if(r==="link")throw new TypeError(`createTerminal: source ${n} declares type "link"; a symbolic link is declared as { type: 'symlink', target }`);if(r==="hardlink")throw new TypeError(`createTerminal: source ${n} declares a hard link, which is not supported: each file here has the one name`);if(r===void 0)throw new TypeError(`createTerminal: source ${n} declares no type; an object declares { type: 'file' | 'directory' | 'symlink' } or { format: 'base64', data }`);if(!Object.hasOwn(ef,r))throw new TypeError(`createTerminal: source ${n} declares type ${JSON.stringify(r)}; the types are 'file', 'directory' and 'symlink'`);for(let i of Object.keys(e))if(!(i==="type"||ef[r].includes(i)))throw new TypeError(Dx.has(i)?`createTerminal: source ${n} declares \`${i}\`, which this terminal does not keep yet`:`createTerminal: source ${n} declares \`${i}\`, which a ${r} does not have`);if(r==="directory")return{type:r};if(r==="symlink"){let{target:i}=e;if(typeof i!="string"||i===""||i.includes("\0"))throw new TypeError(`createTerminal: link ${n} must declare a non-empty target without NUL characters`);return{type:r,target:i}}let{data:o=""}=e;if(typeof o=="string")return{type:r,data:tf(o,t)};if(ArrayBuffer.isView(o))return{type:r,data:nf(o,t)};throw new TypeError(`createTerminal: source ${n} declares \`data\` that is neither text nor a Uint8Array`)}function tf(e,t){if(!e.isWellFormed())throw new TypeError(`createTerminal: source ${JSON.stringify(t)} holds a lone surrogate, which no UTF-8 spells; declare the file's bytes as a Uint8Array`);return e}function Px(e,t){let n=JSON.stringify(t);if(e.format!=="base64")throw new TypeError(`createTerminal: source ${n} declares format ${JSON.stringify(e.format)}; the only format is { format: 'base64', data }`);let r=Object.keys(e).find(o=>o!=="format"&&o!=="data");if(r!==void 0)throw new TypeError(`createTerminal: source ${n} declares \`${r}\`, which base64 contents do not have`);if(typeof e.data!="string")throw new TypeError(`createTerminal: source ${n} must declare its base64 as a string in \`data\``);try{return vr(e.data)}catch(o){throw o instanceof SyntaxError?new TypeError(`createTerminal: source ${n} declares base64 that does not decode`,{cause:o}):o}}function nf(e,t){if(e.BYTES_PER_ELEMENT!==1)throw new TypeError(`createTerminal: source ${JSON.stringify(t)} is a ${e[Symbol.toStringTag]??"view"}; declare a file's bytes as a Uint8Array`);return new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}var rn={__proto__:null,alpha:"A-Za-z",digit:"0-9",alnum:"0-9A-Za-z",upper:"A-Z",lower:"a-z",space:" \\t\\n\\v\\f\\r",blank:" \\t",punct:"!-\\/:-@\\[-`{-~",xdigit:"0-9A-Fa-f",cntrl:"\\x00-\\x1F\\x7F",print:"\\x20-\\x7E",graph:"\\x21-\\x7E",word:"0-9A-Za-z_"},$r={__proto__:null};for(let[e,t]of Object.entries(rn)){let n=new RegExp(`[${t}]`,"u"),r=[];for(let o=0;o<128;o++){if(!n.test(String.fromCodePoint(o)))continue;let i=r.at(-1);i&&i[1]===o-1?i[1]=o:r.push([o,o])}$r[e]=r}var qo=32767;function sf(e,t){if(e>qo||t!==void 0&&t>qo)throw new Error("Regular expression too big")}function Ho(e,t,n=!1){let r=t+1;e[r]==="^"&&r++;let o=!0,i=!1;for(;r<e.length;){let s=e[r];if(s==="]"&&!o)return r;if(o=!1,s==="["&&":.=".includes(e[r+1]??"")){let l=e[r+1],c=e.indexOf(l+"]",r+2);if(c===-1)throw new Error("Unmatched [, [^, [:, [., or [=");if(l===":"&&!(e.slice(r+2,c)in rn))throw new Error("Invalid character class name");if(l!==":"&&n&&/\P{ASCII}/u.test(e.slice(r+2,c)))throw new Error("Invalid collation character");r=c+2,i=l!==".";continue}if(s==="-"&&i&&r+1<e.length&&e[r+1]!=="]")throw new Error("Invalid range end");let a=s==="\\"&&r+1<e.length?2:1;if(e[r+a]==="-"&&e[r+a+1]!==void 0&&e[r+a+1]!=="]"){let l=r+a+1,c=e[l]==="["?e[l+1]:void 0;if(c===":"||c==="=")throw new Error("Invalid range end");let f=c==="."?e.indexOf(".]",l+2):-1;if(c==="."&&f===-1)throw new Error("Unmatched [, [^, [:, [., or [=");let d=c==="."?l+2:l+(e[l]==="\\"?1:0);if(n&&(e.codePointAt(r+a-1)>127||e.codePointAt(d)>127))throw new Error("Invalid collation character");r=f===-1?l+(e[l]==="\\"?2:1):f+2,i=!0;continue}r+=a,i=!1}throw new Error("Unmatched [, [^, [:, [., or [=")}function Fn(e,t,n={}){let r=/^\[:([a-z]+):\]/u.exec(e.slice(t));if(!r)return null;let o=n.classes?n.classes.body(r[1]):rn[r[1]];if(o===void 0){if(n?.unknown!=="empty")throw new Error(`invalid character class \`[:${r[1]}:]\``);return{body:"",end:t+r[0].length}}return{body:o,end:t+r[0].length}}var Go={alpha:"1t:p,6:p,1b:0,a:0,4:0,5:m,1:u,1:cp,4:b,e:4,7:0,1:0,2e:0,16:4,1:1,2:3,1:0,6:0,1:2,1:0,1:j,1:2a,1:3u,8:4l,1:11,2:0,6:14,13:d,1:0,1:1,1:1,1:0,8:q,4:3,t:a,5:1j,1:g,4:2t,1:7,4:7,4:f,2:0,g:1b,d:2s,e:16,9:1,4:0,5:n,2:i,j:o,7:a,5:n,1:5,h:15,a:b,3:6,6:23,1:f,1:2,4:e,2:9,1:i,1:7,2:1,2:l,1:6,1:0,3:3,3:7,2:1,2:1,1:0,8:0,4:1,1:4,2:b,a:0,4:2,1:5,4:1,2:l,1:6,1:1,1:1,1:1,4:4,4:1,2:1,4:0,7:3,1:0,7:f,b:2,1:8,1:2,1:l,1:6,1:1,1:4,3:8,1:2,1:1,3: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:1,x5i:2:1:2,x6d:1:1:1,1ee9:q:w:1,1fcw:14:14:1,1fhs:10:14:1,1fn4:b:13:1,1fng:f:13:1,1fnw:7:13:1,1fo4:2:13:1,1h1c:1f:1s:1,1jfk:w:w:1,20cg:w:w:1,2olc:y:y:1";var ie="C.UTF-8",Xo="only the C.UTF-8 locale is supported",ta=e=>typeof e=="string"&&/^C\.UTF-?8$/iu.test(e),zx=new Set(["LANG","LC_ALL","LC_CTYPE"]);function ff(e){if(e.locale===void 0||ta(e.locale))return ie;throw new TypeError(`createTerminal: ${Xo} (got ${JSON.stringify(e.locale)})`)}function df(e,t){if(!(zx.has(e)?ta(t)||e!=="LANG"&&t==="":ta(t)||t==="C"||t==="POSIX"||t===""))throw new x("feature",e,`${e}: ${Xo}`)}var Zo=e=>e==="C"||e==="POSIX",ee=e=>Zo(e.locale);function lf(e){let t=[],n=-1;for(let r of e.split(",")){let[o,i]=r.split(":").map(a=>parseInt(a,36)),s=n+1+o;t.push([s,s+i]),n=s+i}return t}function Bx(e){let t=e.findIndex(([n])=>n>95);return[...e.slice(0,t),[95,95],...e.slice(t)]}function ea(e){return e>=48&&e<=57||e>=65&&e<=90||e>=97&&e<=122?String.fromCodePoint(e):e<128?"\\x"+e.toString(16).padStart(2,"0"):String.fromCodePoint(e)}var jx=e=>e.map(([t,n])=>t===n?ea(t):`${ea(t)}-${ea(n)}`).join("");function Wx(e,t){let n=e.length-1,r=0;for(;r<=n;){let o=r+n>>1;if(t<e[o][0])n=o-1;else if(t>e[o][1])r=o+1;else return!0}return!1}var Yo=e=>e==="upper"||e==="lower"?"alpha":e,qx=[181,305,383,453,456,459,498,837,962,976,977,981,982,1008,1009,1010,1013,7835,8126],on=/[\u1C80-\u1C88]/u;function cf(e){let t=new Map;for(let n of e.split(",")){let[r,o,i,s]=n.split(":").map(a=>parseInt(a,36));for(let a=0;a<o;a++)t.set(r+a*s,r+a*s+i)}return t}var pf=(e,t)=>({up:e,low:t,folds:new Map});function Hx(){let e=new Map,t=new Map;for(let n=97;n<=122;n++)e.set(n,n-32),t.set(n-32,n);return pf(e,t)}function Gx(e){let t=[];for(let[n,r]of e.sort((o,i)=>o[0]-i[0])){let o=t.at(-1);o&&n<=o[1]+1?o[1]=Math.max(o[1],r):t.push([n,r])}return t}function na(e){let t=`[${e}]`;return{"<":`(?<!${t})(?=${t})`,">":`(?<=${t})(?!${t})`,boundary:`(?:(?<!${t})(?=${t})|(?<=${t})(?!${t}))`,inside:`(?:(?<=${t})(?=${t})|(?<!${t})(?!${t}))`}}function hf(e,t,n,r,o){let i=new Map,s=new Map,a=null,u=f=>(s.has(f)||s.set(f,n(f)),s.get(f)),l=()=>a??=o(),c={name:e,multibyte:t,ranges:u,body(f){return i.has(f)||i.set(f,r(f,u(f))),i.get(f)},has(f,d){let p=u(f);return p!==void 0&&Wx(p,d)},assertions(){if(c.js)return c.js;let f=c.body("space");return c.js={__proto__:null,...na(c.body("word")),word:`[${c.body("word")}]`,nonWord:`[^${c.body("word")}]`,space:`[${f}]`,nonSpace:`[^${f}]`},c.js},up:f=>l().up.get(f)??f,low:f=>l().low.get(f)??f,fold(f){let{folds:d}=l(),p=d.get(f);if(p===void 0){let h=c.up(f),m=c.low(h),g=new Set([f,h]);m!==h&&c.up(m)===h&&g.add(m);for(let w of qx)c.up(w)===h&&g.add(w);p=[...g].sort((w,y)=>w-y),d.set(f,p)}return p},foldRange(f,d){let{up:p}=l(),h=p.get(f)??f,m=p.get(d)??d;if(h>m)return null;let g=[],w=[];for(let[S,_]of p){let W=S>=h&&S<=m;W!==(_>=h&&_<=m)&&(W?g:w).push(S)}let y=[],$=h;for(let S of g.sort((_,W)=>_-W))S>$&&y.push([$,S-1]),$=S+1;return $<=m&&y.push([$,m]),Gx([...y,...w.map(S=>[S,S])])}};return c}var Xx=hf("C",!1,e=>$r[e],e=>rn[e],Hx),Zx=hf(ie,!0,e=>e==="word"?Bx(lf(Go.alnum)):Object.hasOwn(Go,e)?lf(Go[e]):void 0,(e,t)=>t===void 0?void 0:jx(t),()=>pf(cf(af),cf(uf)));function se(e){if(e===ie)return Zx;if(Zo(e))return Xx;throw new x("feature","locale",`matching in the ${e} locale is not supported`)}var ge=(1n<<63n)-1n,wt=-ge-1n,yt=(1n<<64n)-1n;function D(e,t,n,r){let o=E(e.cwd,n,e.fs,r);return P(e,t,n,o.error),o}function P(e,t,n,r){if(r!=="No such file or directory"||typeof n!="string")return;let o=n.startsWith("/"),i=o?"/":e.cwd,s=n.replace(/^\/+/u,""),a=new Set;for(let c of new Set(["/",e.mount??"/",e.home??"/"])){if(c===i)continue;let f=E(c,s,e.fs);f.error||a.add(f.path)}if(!a.size)return;let u=o?"":` from cwd ${JSON.stringify(e.cwd)}`,l=`${o?"absolute":"relative"} path ${JSON.stringify(n)} was not found${u}`;e.notes?.add(`${t}: ${l}. ${Yx(e,a)}`)}function Yx(e,t){let n=[...t].sort(q),r=n.map(a=>JSON.stringify(a));if(n.length===1)return`A ${e.fs.isDir(n[0])?"dir":"file"} exists at ${r[0]}.`;let i=n.every(a=>!e.fs.isDir(a)&&e.fs.isFile(a))&&n.some(a=>!e.fs.sameFileContents(n[0],a)),s=`${r.slice(0,-1).join(", ")} and ${r.at(-1)}`;return`${n.length===2?"Both":"All"} of ${s} exist${i?", and they differ in contents":""}.`}function Rn(){let e=new Set;return{add:t=>e.add(t),collect(t,n){for(let r of n)r.startsWith(".")&&e.add(j(t,r))},emit(t,n,r,o=""){Ft(t,{command:n,action:"omitted",noun:["hidden entry","hidden entries"],explanation:r,context:o,paths:e})}}}var mf=/^(?<command>[^:]+): (?<operand>.+): (?<reason>no such file or directory|not a directory|is a directory)$/iu;function gf(e,t){for(let n of t.split(`
|
|
4
4
|
`))mf.test(n)&&e.discarded?.add(n)}function ra(e,t,n){let r=new Map;for(let o of e){if(t.includes(o))continue;let{command:i,operand:s,reason:a}=mf.exec(o).groups,u=/'([^']*)'$/u.exec(s)?.[1]??s;if([...n].some(c=>c.includes(JSON.stringify(u))))continue;let l=`${i}: ${a}`;r.has(l)||r.set(l,new Set),r.get(l).add(u)}return[...r].map(([o,i])=>`${o}: ${[...i].map(s=>JSON.stringify(s)).join(", ")}.`)}function wf(e,t){return e==="status"?null:{name:t,search:e==="search"}}function yf(){let e=null,t=0;return{skip(n,r){!t&&n&&(e={...n,exitCode:r}),t++},flush(n){if(t&&e){let r=t===1?"the command":`the ${t} commands`,o=e.search&&e.exitCode===1?" A search that selects no lines exits 1, which is not a failure.":"";n.add(`${e.name}: exited ${e.exitCode}, so ${r} after && did not run.${o}`)}e=null,t=0}}}function Ft(e,t){Vx(e,t,t.paths.size,t.paths)}function Vx(e,{command:t,action:n,noun:r,explanation:o="",context:i=""},s,a){if(!s)return;let u=s<10?": "+[...a].sort(q).map(c=>JSON.stringify(c)).join(", "):"",l=Array.isArray(r)?r[s===1?0:1]:r;e.add(`${t}: ${n} ${s} ${l}${i}${u}.${o?" "+o:""}`)}function we(e,t=`
|