var x,b=()=>new DecompressionStream("deflate-raw");try{b(),x=async e=>{let a=b(),t=a.writable.getWriter(),l=a.readable.getReader(),n,s=[],o=0,c=0,i;for(t.write(e),t.close();!(i=await l.read()).done;)n=i.value,s.push(n),o+=n.length;return!s[1]&&n||(n=new Uint8Array(o),s.map(d=>(n.set(d,c),c+=d.length))),n}}catch{}var L=new TextDecoder,E=e=>{throw new Error("but-unzip~"+e)},h=e=>L.decode(e),C=(...e)=>[..._(...e)];function*_(e,a=x){let t=e.length-20,l=Math.max(t-65516,2);for(;(t=e.lastIndexOf(80,t-1))!==-1&&!(e[t+1]===75&&e[t+2]===5&&e[t+3]===6)&&t>l;);t===-1&&E(2);let n=(r,u)=>e.subarray(t+=r,t+=u),s=new DataView(e.buffer,e.byteOffset),o=r=>s.getUint16(r+t,!0),c=r=>s.getUint32(r+t,!0),i=o(10);for(i!==o(8)&&E(3),t=c(16);i--;){let r=o(10),u=o(30),m=o(32),y=c(20),g=c(42),p=h(n(46,o(28))),w=h(n(u,m)),D=t,f;t=g,f=n(30+o(26)+o(28),y),yield{filename:p,comment:w,read:()=>r&8?a(f):r?E(1):f},t=D}}export{x as inflateRaw,_ as iter,C as unzip};