1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3058],{23058:(e,t,r)=>{r.d(t,{uploadWithProgress:()=>s});var o=r(25164),n=r(65132);function s(e){return new n.c(t=>{let r=new XMLHttpRequest,{url:n,method:s,headers:a,body:l,withCredentials:p,timeout:d,signal:u}=e;for(let[e,t]of(r.open(s,n),r.withCredentials=p,"number"==typeof d&&d>0&&(r.timeout=d),Object.entries(a)))r.setRequestHeader(e,t);r.upload.onprogress=e=>{t.next({type:"progress",stage:"upload",percent:e.lengthComputable?Math.round(e.loaded/e.total*100):0,total:e.total||void 0,loaded:e.loaded,lengthComputable:e.lengthComputable})},r.onload=()=>{let e;if(r.status>=400){let e=function(e){let t=new Headers;for(let r of e.split("\r\n")){let e=r.indexOf(":");if(!(e<=0))try{t.append(r.slice(0,e).trim(),r.slice(e+1).trim())}catch{}}return t}(r.getAllResponseHeaders()),a=(0,o.s)({status:r.status,statusText:r.statusText,headers:e,body:(0,o.n)(r.responseText,e),url:r.responseURL},n,s);t.error(r.status>=500?new o.a(a):new o.r(a));return}try{e=JSON.parse(r.responseText)}catch{t.error(Error("Failed to parse upload response as JSON"));return}t.next({type:"response",body:e}),t.complete()},r.onerror=()=>{t.error(Error("XHR upload network error"))},r.ontimeout=()=>{t.error(new DOMException(`The operation timed out after ${d}ms while attempting to reach ${n}`,"TimeoutError"))},r.onabort=()=>{t.error(new DOMException("Upload aborted","AbortError"))};let i=()=>r.abort();if(u){if(u.aborted)return void t.error(new DOMException("Upload aborted","AbortError"));u.addEventListener("abort",i,{once:!0})}return r.send(l),()=>{u?.removeEventListener("abort",i),r.abort()}})}}}]); 2//# sourceMappingURL=3058.2fa6e6a154d47e57.js.map
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.