vendor: 4,697 bytes, line 1
1import{d as e,m as t}from"./Rur1wp30.js";import{t as o}from"./rb7HJZNs.js";import{t as s}from"./BY8r6c05.js";var r=class extends Error{constructor(e,t){super(e,t),this.name="FetchError",t?.cause&&!this.cause&&(this.cause=t.cause)}},n=new Set(Object.freeze(["PATCH","POST","PUT","DELETE"]));function a(e="GET"){return n.has(e.toUpperCase())}var i=new Set(["image/svg","application/xml","application/xhtml","application/html"]),p=/^application\/(?:[\w!#$%&*.^`~-]*\+)?json(;.+)?$/i;function u(e,t,o,s){const r=function(e,t,o){if(!t)return new o(e);const s=new o(t);if(e)for(const[r,n]of Symbol.iterator in e||Array.isArray(e)?e:new o(e))s.set(r,n);return s}(t?.headers??e?.headers,o?.headers,s);let n;return(o?.query||o?.params||t?.params||t?.query)&&(n={...o?.params,...o?.query,...t?.params,...t?.query}),{...o,...t,query:n,params:n,headers:r}}async function c(e,t){if(t)if(Array.isArray(t))for(const o of t)await o(e);else await t(e)}var f=new Set([408,409,425,429,500,502,503,504]),d=new Set([101,204,205,304]),l=function(){if("undefined"!=typeof globalThis)return globalThis;if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;if("undefined"!=typeof global)return global;throw new Error("unable to locate global object")}(),y=function s(n={}){const{fetch:l=globalThis.fetch,Headers:y=globalThis.Headers,AbortController:h=globalThis.AbortController}=n;async function b(e){const t=e.error&&"AbortError"===e.error.name&&!e.options.timeout||!1;if(!1!==e.options.retry&&!t){let t;t="number"==typeof e.options.retry?e.options.retry:a(e.options.method)?0:1;const o=e.response&&e.response.status||500;if(t>0&&(Array.isArray(e.options.retryStatusCodes)?e.options.retryStatusCodes.includes(o):f.has(o))){const o="function"==typeof e.options.retryDelay?e.options.retryDelay(e):e.options.retryDelay||0;return o>0&&await new Promise(e=>setTimeout(e,o)),m(e.request,{...e.options,retry:t-1})}}const o=function(e){const t=e.error?.message||e.error?.toString()||"",o=e.request?.method||e.options?.method||"GET",s=e.request?.url||String(e.request)||"/",n=`[${o}] ${JSON.stringify(s)}: ${e.response?`${e.response.status} ${e.response.statusText}`:"<no response>"}${t?` ${t}`:""}`,a=new r(n,e.error?{cause:e.error}:void 0);for(const r of["request","options","response"])Object.defineProperty(a,r,{get:()=>e[r]});for(const[r,i]of[["data","_data"],["status","status"],["statusCode","status"],["statusText","statusText"],["statusMessage","statusText"]])Object.defineProperty(a,r,{get:()=>e.response&&e.response[i]});return a}(e);throw Error.captureStackTrace&&Error.captureStackTrace(o,m),o}const m=async function(s,r={}){const f={request:s,options:u(s,r,n.defaults,y),response:void 0,error:void 0};if(f.options.method&&(f.options.method=f.options.method.toUpperCase()),f.options.onRequest&&(await c(f,f.options.onRequest),f.options.headers instanceof y||(f.options.headers=new y(f.options.headers||{}))),"string"==typeof f.request&&(f.options.baseURL&&(f.request=e(f.request,f.options.baseURL)),f.options.query&&(f.request=t(f.request,f.options.query),delete f.options.query),"query"in f.options&&delete f.options.query,"params"in f.options&&delete f.options.params),f.options.body&&a(f.options.method))if(function(e){if(void 0===e)return!1;const t=typeof e;return"string"===t||"number"===t||"boolean"===t||null===t||"object"===t&&(!!Array.isArray(e)||!e.buffer&&!(e instanceof FormData||e instanceof URLSearchParams)&&(e.constructor&&"Object"===e.constructor.name||"function"==typeof e.toJSON))}(f.options.body)){const e=f.options.headers.get("content-type");"string"!=typeof f.options.body&&(f.options.body="application/x-www-form-urlencoded"===e?new URLSearchParams(f.options.body).toString():JSON.stringify(f.options.body)),e||f.options.headers.set("content-type","application/json"),f.options.headers.has("accept")||f.options.headers.set("accept","application/json")}else("pipeTo"in f.options.body&&"function"==typeof f.options.body.pipeTo||"function"==typeof f.options.body.pipe)&&("duplex"in f.options||(f.options.duplex="half"));let m;if(!f.options.signal&&f.options.timeout){const e=new h;m=setTimeout(()=>{const t=new Error("[TimeoutError]: The operation was aborted due to timeout");t.name="TimeoutError",t.code=23,e.abort(t)},f.options.timeout),f.options.signal=e.signal}try{f.response=await l(f.request,f.options)}catch(w){return f.error=w,f.options.onRequestError&&await c(f,f.options.onRequestError),await b(f)}finally{m&&clearTimeout(m)}if((f.response.body||f.response._bodyInit)&&!d.has(f.response.status)&&"HEAD"!==f.options.method){const e=(f.options.parseResponse?"json":f.options.responseType)||function(e=""){if(!e)return"json";const t=e.split(";").shift()||"";
1return p.test(t)?"json":"text/event-stream"===t?"stream":i.has(t)||t.startsWith("text/")?"text":"blob"}(f.response.headers.get("content-type")||"");switch(e){case"json":{const e=await f.response.text(),t=f.options.parseResponse||o;f.response._data=t(e);break}case"stream":f.response._data=f.response.body||f.response._bodyInit;break;default:f.response._data=await f.response[e]()}}return f.options.onResponse&&await c(f,f.options.onResponse),!f.options.ignoreResponseError&&f.response.status>=400&&f.response.status<600?(f.options.onResponseError&&await c(f,f.options.onResponseError),await b(f)):f.response},w=async function(e,t){return(await m(e,t))._data};return w.raw=m,w.native=(...e)=>l(...e),w.create=(e={},t={})=>s({...n,...t,defaults:{...n.defaults,...t.defaults,...e}}),w}({fetch:l.fetch?(...e)=>l.fetch(...e):()=>Promise.reject(new Error("[ofetch] global.fetch is not supported!")),Headers:l.Headers,AbortController:l.AbortController}),h=y;globalThis.$fetch||(globalThis.$fetch=h.create({baseURL:s()}));var b=globalThis.$fetch;export{b as t};
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.