UNPKG

@aurigma/ui-framework

Version:

A platform which allows building print product personalization editors based on Aurigma's Customer's Canvas.

1 lines 80.7 kB
(window.multistep_editor_jsonpFunction=window.multistep_editor_jsonpFunction||[]).push([[4],{415:function(e,D,_){!function(e,t,r){var o=_(816);let n=Object.prototype.toString,l=Object.getPrototypeOf,a=(t=>e=>{e=n.call(e);return t[e]||(t[e]=e.slice(8,-1).toLowerCase())})(Object.create(null));var s=t=>(t=t.toLowerCase(),e=>a(e)===t),i=t=>e=>typeof e===t;let d=Array.isArray,c=i("undefined");let u=s("ArrayBuffer");var p=i("string");let h=i("function"),f=i("number"),m=e=>null!==e&&"object"==typeof e;let b=e=>{var t;return"object"===a(e)&&!(null!==(t=l(e))&&t!==Object.prototype&&null!==Object.getPrototypeOf(t)||Symbol.toStringTag in e||Symbol.iterator in e)};var i=s("Date"),v=s("File"),w=s("Blob"),y=s("FileList"),R=s("URLSearchParams"),[O,U,G,L]=["ReadableStream","Request","Response","Headers"].map(s);function I(t,r,{allOwnKeys:n=!1}={}){if(null!=t){let e;var o;if("object"!=typeof t&&(t=[t]),d(t))for(e=0,o=t.length;e<o;e++)r.call(null,t[e],e,t);else{var a,s=n?Object.getOwnPropertyNames(t):Object.keys(t),i=s.length;for(e=0;e<i;e++)a=s[e],r.call(null,t[a],a,t)}}}function P(e,t){t=t.toLowerCase();var r,n=Object.keys(e);let o=n.length;for(;0<o--;)if(t===(r=n[o]).toLowerCase())return r;return null}let g="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:e,C=e=>!c(e)&&e!==g;var E,e=(t=>e=>t&&e instanceof t)("undefined"!=typeof Uint8Array&&l(Uint8Array)),z=s("HTMLFormElement"),T=(E=[Object.prototype.hasOwnProperty][0],(e,t)=>E.call(e,t)),q=s("RegExp");let S=(n,o)=>{var e=Object.getOwnPropertyDescriptors(n);let a={};I(e,(e,t)=>{var r;!1!==(r=o(e,t,n))&&(a[t]=r||e)}),Object.defineProperties(n,a)};var A="abcdefghijklmnopqrstuvwxyz",k="0123456789";let x={DIGIT:k,ALPHA:A,ALPHA_DIGIT:A+A.toUpperCase()+k};var N,F,j,A=s("AsyncFunction"),k=(k="function"==typeof t,N=h(g.postMessage),k?t:N?(F="axios@"+Math.random(),j=[],g.addEventListener("message",({source:e,data:t})=>{e===g&&t===F&&j.length&&j.shift()()},!1),e=>{j.push(e),g.postMessage(F,"*")}):e=>setTimeout(e)),t="undefined"!=typeof queueMicrotask?queueMicrotask.bind(g):void 0!==r&&r.nextTick||k;D.a={isArray:d,isArrayBuffer:u,isBuffer:function(e){return null!==e&&!c(e)&&null!==e.constructor&&!c(e.constructor)&&h(e.constructor.isBuffer)&&e.constructor.isBuffer(e)},isFormData:e=>{var t;return e&&("function"==typeof FormData&&e instanceof FormData||h(e.append)&&("formdata"===(t=a(e))||"object"===t&&h(e.toString)&&"[object FormData]"===e.toString()))},isArrayBufferView:function(e){let t;return t="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&u(e.buffer)},isString:p,isNumber:f,isBoolean:e=>!0===e||!1===e,isObject:m,isPlainObject:b,isReadableStream:O,isRequest:U,isResponse:G,isHeaders:L,isUndefined:c,isDate:i,isFile:v,isBlob:w,isRegExp:q,isFunction:h,isStream:e=>m(e)&&h(e.pipe),isURLSearchParams:R,isTypedArray:e,isFileList:y,forEach:I,merge:function r(){let n=(C(this)&&this||{}).caseless,o={};var a=(e,t)=>{t=n&&P(o,t)||t,b(o[t])&&b(e)?o[t]=r(o[t],e):b(e)?o[t]=r({},e):d(e)?o[t]=e.slice():o[t]=e};for(let e=0,t=arguments.length;e<t;e++)arguments[e]&&I(arguments[e],a);return o},extend:(r,e,n,{allOwnKeys:t}={})=>(I(e,(e,t)=>{n&&h(e)?r[t]=Object(o.a)(e,n):r[t]=e},{allOwnKeys:t}),r),trim:e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""),stripBOM:e=>e=65279===e.charCodeAt(0)?e.slice(1):e,inherits:(e,t,r,n)=>{e.prototype=Object.create(t.prototype,n),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),r&&Object.assign(e.prototype,r)},toFlatObject:(e,t,r,n)=>{var o,a;let s;var i={};if(t=t||{},null!=e)do{for(o=Object.getOwnPropertyNames(e),s=o.length;0<s--;)a=o[s],n&&!n(a,e,t)||i[a]||(t[a]=e[a],i[a]=!0)}while((e=!1!==r&&l(e))&&(!r||r(e,t))&&e!==Object.prototype);return t},kindOf:a,kindOfTest:s,endsWith:(e,t,r)=>{e=String(e),(void 0===r||r>e.length)&&(r=e.length),r-=t.length;e=e.indexOf(t,r);return-1!==e&&e===r},toArray:e=>{if(!e)return null;if(d(e))return e;let t=e.length;if(!f(t))return null;for(var r=new Array(t);0<t--;)r[t]=e[t];return r},forEachEntry:(e,t)=>{for(var r=(e&&e[Symbol.iterator]).call(e);(n=r.next())&&!n.done;){var n=n.value;t.call(e,n[0],n[1])}},matchAll:(e,t)=>{for(var r,n=[];null!==(r=e.exec(t));)n.push(r);return n},isHTMLForm:z,hasOwnProperty:T,hasOwnProp:T,reduceDescriptors:S,freezeMethods:n=>{S(n,(e,t)=>{if(h(n)&&-1!==["arguments","caller","callee"].indexOf(t))return!1;var r=n[t];h(r)&&(e.enumerable=!1,"writable"in e?e.writable=!1:e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+t+"'")}))})},toObjectSet:(e,t)=>{let r={};var n=e=>{e.forEach(e=>{r[e]=!0})};return d(e)?n(e):n(String(e).split(t)),r},toCamelCase:e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(e,t,r){return t.toUpperCase()+r}),noop:()=>{},toFiniteNumber:(e,t)=>null!=e&&Number.isFinite(e=+e)?e:t,findKey:P,global:g,isContextDefined:C,ALPHABET:x,generateString:(e=16,t=x.ALPHA_DIGIT)=>{let r="";for(var n=t.length;e--;)r+=t[Math.random()*n|0];return r},isSpecCompliantForm:function(e){return!!(e&&h(e.append)&&"FormData"===e[Symbol.toStringTag]&&e[Symbol.iterator])},toJSONObject:e=>{let t=new Array(10),o=(e,n)=>{if(m(e)){if(0<=t.indexOf(e))return;if(!("toJSON"in e)){t[n]=e;let r=d(e)?[]:{};return I(e,(e,t)=>{e=o(e,n+1);c(e)||(r[t]=e)}),t[n]=void 0,r}}return e};return o(e,0)},isAsyncFn:A,isThenable:e=>e&&(m(e)||h(e))&&h(e.then)&&h(e.catch),setImmediate:k,asap:t}}.call(this,_(53),_(200).setImmediate,_(124))},442:function(e,t,r){var i=r(415);function l(e,t,r,n,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=(new Error).stack,this.message=e,this.name="AxiosError",t&&(this.code=t),r&&(this.config=r),n&&(this.request=n),o&&(this.response=o,this.status=o.status||null)}i.a.inherits(l,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:i.a.toJSONObject(this.config),code:this.code,status:this.status}}});let d=l.prototype,n={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{n[e]={value:e}}),Object.defineProperties(l,n),Object.defineProperty(d,"isAxiosError",{value:!0}),l.from=(e,t,r,n,o,a)=>{var s=Object.create(d);return i.a.toFlatObject(e,s,function(e){return e!==Error.prototype},e=>"isAxiosError"!==e),l.call(s,e.message,t,r,n,o),s.cause=e,s.name=e.name,a&&Object.assign(s,a),s},t.a=l},533:function(e,t,r){!function(p){var h=r(415),f=r(442),m=r(817);function b(e){return h.a.isPlainObject(e)||h.a.isArray(e)}function v(e){return h.a.endsWith(e,"[]")?e.slice(0,-2):e}function w(e,t,r){return e?e.concat(t).map(function(e,t){return e=v(e),!r&&t?"["+e+"]":e}).join(r?".":""):t}let y=h.a.toFlatObject(h.a,{},null,function(e){return/^is[A-Z]/.test(e)});t.a=function(e,a,t){if(!h.a.isObject(e))throw new TypeError("target must be an object");a=a||new(m.a||FormData);let s=(t=h.a.toFlatObject(t,{metaTokens:!0,dots:!1,indexes:!1},!1,function(e,t){return!h.a.isUndefined(t[e])})).metaTokens,o=t.visitor||n,i=t.dots,l=t.indexes,r=(t.Blob||"undefined"!=typeof Blob&&Blob)&&h.a.isSpecCompliantForm(a);if(!h.a.isFunction(o))throw new TypeError("visitor must be a function");function d(e){if(null===e)return"";if(h.a.isDate(e))return e.toISOString();if(!r&&h.a.isBlob(e))throw new f.a("Blob is not supported. Use a Buffer instead.");return h.a.isArrayBuffer(e)||h.a.isTypedArray(e)?r&&"function"==typeof Blob?new Blob([e]):p.from(e):e}function n(e,r,t){let n=e;if(e&&!t&&"object"==typeof e)if(h.a.endsWith(r,"{}"))r=s?r:r.slice(0,-2),e=JSON.stringify(e);else if(h.a.isArray(e)&&(o=e,h.a.isArray(o))&&!o.some(b)||(h.a.isFileList(e)||h.a.endsWith(r,"[]"))&&(n=h.a.toArray(e)))return r=v(r),n.forEach(function(e,t){h.a.isUndefined(e)||null===e||a.append(!0===l?w([r],t,i):null===l?r:r+"[]",d(e))}),!1;var o;return!!b(e)||(a.append(w(t,r,i),d(e)),!1)}let c=[],u=Object.assign(y,{defaultVisitor:n,convertValue:d,isVisitable:b});if(h.a.isObject(e))return function r(e,n){if(!h.a.isUndefined(e)){if(-1!==c.indexOf(e))throw Error("Circular reference detected in "+n.join("."));c.push(e),h.a.forEach(e,function(e,t){!0===(!(h.a.isUndefined(e)||null===e)&&o.call(a,e,h.a.isString(t)?t.trim():t,n,u))&&r(e,n?n.concat(t):[t])}),c.pop()}}(e),a;throw new TypeError("data must be an object")}}.call(this,r(197).Buffer)},535:function(G,e,t){t.d(e,"a",function(){return at}),t.d(e,"c",function(){return it}),t.d(e,"e",function(){return lt}),t.d(e,"b",function(){return Me}),t.d(e,"d",function(){return We});var e={},g=(t.r(e),t.d(e,"hasBrowserEnv",function(){return n}),t.d(e,"hasStandardBrowserWebWorkerEnv",function(){return M}),t.d(e,"hasStandardBrowserEnv",function(){return $}),t.d(e,"navigator",function(){return o}),t.d(e,"origin",function(){return W}),t(415)),L=t(816),i=t(533);function z(e){let t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(e){return t[e]})}function q(e,t){this._pairs=[],e&&Object(i.a)(e,this,t)}var r=q.prototype,D=(r.append=function(e,t){this._pairs.push([e,t])},r.toString=function(t){let r=t?function(e){return t.call(this,e,z)}:z;return this._pairs.map(function(e){return r(e[0])+"="+r(e[1])},"").join("&")},q);function _(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function B(t,r,n){if(r){var o=n&&n.encode||_,a=(n=g.a.isFunction(n)?{serialize:n}:n)&&n.serialize;let e;(e=a?a(r,n):g.a.isURLSearchParams(r)?r.toString():new D(r,n).toString(o))&&(-1!==(a=t.indexOf("#"))&&(t=t.slice(0,a)),t+=(-1===t.indexOf("?")?"?":"&")+e)}return t}var J=class{constructor(){this.handlers=[]}use(e,t,r){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!r&&r.synchronous,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){g.a.forEach(this.handlers,function(e){null!==e&&t(e)})}},C=t(442),V={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},r={isBrowser:!0,classes:{URLSearchParams:"undefined"!=typeof URLSearchParams?URLSearchParams:D,FormData:"undefined"!=typeof FormData?FormData:null,Blob:"undefined"!=typeof Blob?Blob:null},protocols:["http","https","file","blob","url","data"]};let n="undefined"!=typeof window&&"undefined"!=typeof document,o="object"==typeof navigator&&navigator||void 0,$=n&&(!o||["ReactNative","NativeScript","NS"].indexOf(o.product)<0),M="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts,W=n&&window.location.href||"http://localhost";var H=Object.defineProperty,K=Object.getOwnPropertySymbols,X=Object.prototype.hasOwnProperty,Q=Object.prototype.propertyIsEnumerable,Z=(e,t,r)=>t in e?H(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,a=(e,t)=>{for(var r in t=t||{})X.call(t,r)&&Z(e,r,t[r]);if(K)for(var r of K(t))Q.call(t,r)&&Z(e,r,t[r]);return e},m=a(a({},e),r);var Y=function(e){function i(e,t,r,n){var o,a,s;return"__proto__"===(s=e[n++])||(o=Number.isFinite(+s),a=n>=e.length,s=!s&&g.a.isArray(r)?r.length:s,a?g.a.hasOwnProp(r,s)?r[s]=[r[s],t]:r[s]=t:(r[s]&&g.a.isObject(r[s])||(r[s]=[]),i(e,t,r[s],n)&&g.a.isArray(r[s])&&(r[s]=(e=>{var t={},r=Object.keys(e);let n;var o,a=r.length;for(n=0;n<a;n++)t[o=r[n]]=e[o];return t})(r[s]))),!o)}if(g.a.isFormData(e)&&g.a.isFunction(e.entries)){let r={};return g.a.forEachEntry(e,(e,t)=>{i(g.a.matchAll(/\w+|\[(\w*)]/g,e).map(e=>"[]"===e[0]?"":e[1]||e[0]),t,r,0)}),r}return null};let s={transitional:V,adapter:["xhr","http","fetch"],transformRequest:[function(e,t){var r,n=t.getContentType()||"",o=-1<n.indexOf("application/json"),a=g.a.isObject(e),s=(a&&g.a.isHTMLForm(e)&&(e=new FormData(e)),g.a.isFormData(e));if(s)return o?JSON.stringify(Y(e)):e;if(!(g.a.isArrayBuffer(e)||g.a.isBuffer(e)||g.a.isStream(e)||g.a.isFile(e)||g.a.isBlob(e)||g.a.isReadableStream(e))){if(g.a.isArrayBufferView(e))return e.buffer;if(g.a.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();if(a){if(-1<n.indexOf("application/x-www-form-urlencoded"))return s=e,r=this.formSerializer,Object(i.a)(s,new m.classes.URLSearchParams,Object.assign({visitor:function(e,t,r,n){return m.isNode&&g.a.isBuffer(e)?(this.append(t,e.toString("base64")),!1):n.defaultVisitor.apply(this,arguments)}},r)).toString();if((s=g.a.isFileList(e))||-1<n.indexOf("multipart/form-data"))return r=this.env&&this.env.FormData,Object(i.a)(s?{"files[]":e}:e,r&&new r,this.formSerializer)}if(a||o){t.setContentType("application/json",!1);n=e,s=void 0,a=void 0;if(g.a.isString(n))try{return(s||JSON.parse)(n),g.a.trim(n)}catch(e){if("SyntaxError"!==e.name)throw e}return(a||JSON.stringify)(n)}}return e}],transformResponse:[function(e){var t=this.transitional||s.transitional,r=t&&t.forcedJSONParsing,n="json"===this.responseType;if(!g.a.isResponse(e)&&!g.a.isReadableStream(e)&&e&&g.a.isString(e)&&(r&&!this.responseType||n)){r=!(t&&t.silentJSONParsing)&&n;try{return JSON.parse(e)}catch(e){if(r){if("SyntaxError"===e.name)throw C.a.from(e,C.a.ERR_BAD_RESPONSE,this,null,this.response);throw e}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:m.classes.FormData,Blob:m.classes.Blob},validateStatus:function(e){return 200<=e&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};g.a.forEach(["delete","get","head","post","put","patch"],e=>{s.headers[e]={}});var l=s;let ee=g.a.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]);let te=Symbol("internals");function d(e){return e&&String(e).trim().toLowerCase()}function c(e){return!1===e||null==e?e:g.a.isArray(e)?e.map(c):String(e)}function u(e,t,r,n,o){return g.a.isFunction(n)?n.call(this,t,r):g.a.isString(t=o?r:t)&&(g.a.isString(n)?-1!==t.indexOf(n):g.a.isRegExp(n)&&n.test(t))}class p{constructor(e){e&&this.set(e)}set(e,t,r){let o=this;function n(e,t,r){var n=d(t);if(!n)throw new Error("header name must be a non-empty string");n=g.a.findKey(o,n);n&&void 0!==o[n]&&!0!==r&&(void 0!==r||!1===o[n])||(o[n||t]=c(e))}var a=(e,r)=>g.a.forEach(e,(e,t)=>n(e,t,r));if(g.a.isPlainObject(e)||e instanceof this.constructor)a(e,t);else if(g.a.isString(e)&&(e=e.trim())&&!/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim()))a((e=>{let t={},r,n,o;return e&&e.split("\n").forEach(function(e){o=e.indexOf(":"),r=e.substring(0,o).trim().toLowerCase(),n=e.substring(o+1).trim(),!r||t[r]&&ee[r]||("set-cookie"===r?t[r]?t[r].push(n):t[r]=[n]:t[r]=t[r]?t[r]+", "+n:n)}),t})(e),t);else if(g.a.isHeaders(e))for(var[s,i]of e.entries())n(i,s,r);else null!=e&&n(t,e,r);return this}get(e,t){if(e=d(e)){e=g.a.findKey(this,e);if(e){var r=this[e];if(!t)return r;if(!0===t){for(var n,o=r,a=Object.create(null),s=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;n=s.exec(o);)a[n[1]]=n[2];return a}if(g.a.isFunction(t))return t.call(this,r,e);if(g.a.isRegExp(t))return t.exec(r);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){return!!(e=d(e))&&!(!(e=g.a.findKey(this,e))||void 0===this[e]||t&&!u(0,this[e],e,t))}delete(e,t){let r=this,n=!1;function o(e){(e=d(e))&&(e=g.a.findKey(r,e))&&(!t||u(r,r[e],e,t))&&(delete r[e],n=!0)}return g.a.isArray(e)?e.forEach(o):o(e),n}clear(e){var t=Object.keys(this);let r=t.length,n=!1;for(;r--;){var o=t[r];e&&!u(0,this[o],o,e,!0)||(delete this[o],n=!0)}return n}normalize(n){let o=this,a={};return g.a.forEach(this,(e,t)=>{var r=g.a.findKey(a,t);r?(o[r]=c(e),delete o[t]):((r=n?t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,r)=>t.toUpperCase()+r):String(t).trim())!==t&&delete o[t],o[r]=c(e),a[r]=!0)}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(r){let n=Object.create(null);return g.a.forEach(this,(e,t)=>{null!=e&&!1!==e&&(n[t]=r&&g.a.isArray(e)?e.join(", "):e)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,t])=>e+": "+t).join("\n")}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){let r=new this(e);return t.forEach(e=>r.set(e)),r}static accessor(e){let n=(this[te]=this[te]={accessors:{}}).accessors,a=this.prototype;function t(t){var e=d(t);if(!n[e]){{var r=a;var o=t;let e=g.a.toCamelCase(" "+o);["get","set","has"].forEach(n=>{Object.defineProperty(r,n+e,{value:function(e,t,r){return this[n].call(this,o,e,t,r)},configurable:!0})})}n[e]=!0}}return g.a.isArray(e)?e.forEach(t):t(e),this}}p.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),g.a.reduceDescriptors(p.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(e){this[r]=e}}}),g.a.freezeMethods(p);var E=p;function h(e,t){let r=this||l;var n=t||r;let o=E.from(n.headers),a=n.data;return g.a.forEach(e,function(e){a=e.call(r,a,o.normalize(),t?t.status:void 0)}),o.normalize(),a}function re(e){return!(!e||!e.__CANCEL__)}function ne(e,t,r){C.a.call(this,null==e?"canceled":e,C.a.ERR_CANCELED,t,r),this.name="CanceledError"}g.a.inherits(ne,C.a,{__CANCEL__:!0});var b=ne,a=t(817);function oe(e,t,r){var n=r.config.validateStatus;r.status&&n&&!n(r.status)?t(new C.a("Request failed with status code "+r.status,[C.a.ERR_BAD_REQUEST,C.a.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r)):e(r)}var ae=function(a,s){a=a||10;let i=new Array(a),l=new Array(a),d=0,c=0,u;return s=void 0!==s?s:1e3,function(e){var t=Date.now(),r=l[c];u=u||t,i[d]=e,l[d]=t;let n=c,o=0;for(;n!==d;)o+=i[n++],n%=a;return(d=(d+1)%a)===c&&(c=(c+1)%a),!(t-u<s)&&(e=r&&t-r)?Math.round(1e3*o/e):void 0}};var se=function(r,e){let n=0,o=1e3/e,a,s,i=(e,t=Date.now())=>{n=t,a=null,s&&(clearTimeout(s),s=null),r.apply(null,e)};return[(...e)=>{var t=Date.now(),r=t-n;r>=o?i(e,t):(a=e,s=s||setTimeout(()=>{s=null,i(a)},o-r))},()=>a&&i(a)]};let T=(s,i,e=3)=>{let l=0,d=ae(50,250);return se(e=>{var t=e.loaded,r=e.lengthComputable?e.total:void 0,n=t-l,o=d(n),a=t<=r,n={loaded:l=t,total:r,progress:r?t/r:void 0,bytes:n,rate:o||void 0,estimated:o&&r&&a?(r-t)/o:void 0,event:e,lengthComputable:null!=r,[i?"download":"upload"]:!0};s(n)},e)},ie=(t,r)=>{let n=null!=t;return[e=>r[0]({lengthComputable:n,total:t,loaded:e}),r[1]]},le=t=>(...e)=>g.a.asap(()=>t(...e));var de=m.hasStandardBrowserEnv?((t,r)=>e=>(e=new URL(e,m.origin),t.protocol===e.protocol&&t.host===e.host&&(r||t.port===e.port)))(new URL(m.origin),m.navigator&&/(msie|trident)/i.test(m.navigator.userAgent)):()=>!0,ce=m.hasStandardBrowserEnv?{write(e,t,r,n,o,a){e=[e+"="+encodeURIComponent(t)];g.a.isNumber(r)&&e.push("expires="+new Date(r).toGMTString()),g.a.isString(n)&&e.push("path="+n),g.a.isString(o)&&e.push("domain="+o),!0===a&&e.push("secure"),document.cookie=e.join("; ")},read(e){e=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function ue(e,t){var r;return e&&!/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)?(e=e,(r=t)?e.replace(/\/?\/$/,"")+"/"+r.replace(/^\/+/,""):e):t}var pe=Object.defineProperty,he=Object.getOwnPropertySymbols,fe=Object.prototype.hasOwnProperty,me=Object.prototype.propertyIsEnumerable,be=(e,t,r)=>t in e?pe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,ve=(e,t)=>{for(var r in t=t||{})fe.call(t,r)&&be(e,r,t[r]);if(he)for(var r of he(t))me.call(t,r)&&be(e,r,t[r]);return e};let we=e=>e instanceof E?ve({},e):e;function f(n,o){o=o||{};let a={};function s(e,t,r,n){return g.a.isPlainObject(e)&&g.a.isPlainObject(t)?g.a.merge.call({caseless:n},e,t):g.a.isPlainObject(t)?g.a.merge({},t):g.a.isArray(t)?t.slice():t}function i(e,t,r,n){return g.a.isUndefined(t)?g.a.isUndefined(e)?void 0:s(void 0,e,0,n):s(e,t,0,n)}function e(e,t){if(!g.a.isUndefined(t))return s(void 0,t)}function t(e,t){return g.a.isUndefined(t)?g.a.isUndefined(e)?void 0:s(void 0,e):s(void 0,t)}function l(e,t,r){return r in o?s(e,t):r in n?s(void 0,e):void 0}let d={url:e,method:e,data:e,baseURL:t,transformRequest:t,transformResponse:t,paramsSerializer:t,timeout:t,timeoutMessage:t,withCredentials:t,withXSRFToken:t,adapter:t,responseType:t,xsrfCookieName:t,xsrfHeaderName:t,onUploadProgress:t,onDownloadProgress:t,decompress:t,maxContentLength:t,maxBodyLength:t,beforeRedirect:t,transport:t,httpAgent:t,httpsAgent:t,cancelToken:t,socketPath:t,responseEncoding:t,validateStatus:l,headers:(e,t,r)=>i(we(e),we(t),0,!0)};return g.a.forEach(Object.keys(Object.assign({},n,o)),function(e){var t=d[e]||i,r=t(n[e],o[e],e);g.a.isUndefined(r)&&t!==l||(a[e]=r)}),a}var ye=e=>{var t,r=f({},e);let{data:n,withXSRFToken:o,xsrfHeaderName:a,xsrfCookieName:s,headers:i,auth:l}=r;return r.headers=i=E.from(i),r.url=B(ue(r.baseURL,r.url),e.params,e.paramsSerializer),l&&i.set("Authorization","Basic "+btoa((l.username||"")+":"+(l.password?unescape(encodeURIComponent(l.password)):""))),g.a.isFormData(n)&&(m.hasStandardBrowserEnv||m.hasStandardBrowserWebWorkerEnv?i.setContentType(void 0):!1!==(e=i.getContentType())&&([e,...t]=e?e.split(";").map(e=>e.trim()).filter(Boolean):[],i.setContentType([e||"multipart/form-data",...t].join("; ")))),m.hasStandardBrowserEnv&&((o=o&&g.a.isFunction(o)?o(r):o)||!1!==o&&de(r.url))&&(e=a&&s&&ce.read(s))&&i.set(a,e),r},e="undefined"!=typeof XMLHttpRequest&&function(f){return new Promise(function(t,r){let n=ye(f);var e=n.data,o=E.from(n.headers).normalize();let{responseType:a,onUploadProgress:s,onDownloadProgress:i}=n,l,d,c;function u(){d&&d(),c&&c(),n.cancelToken&&n.cancelToken.unsubscribe(l),n.signal&&n.signal.removeEventListener("abort",l)}let p=new XMLHttpRequest;function h(){var e;p&&(e=E.from("getAllResponseHeaders"in p&&p.getAllResponseHeaders()),oe(function(e){t(e),u()},function(e){r(e),u()},{data:a&&"text"!==a&&"json"!==a?p.response:p.responseText,status:p.status,statusText:p.statusText,headers:e,config:f,request:p}),p=null)}p.open(n.method.toUpperCase(),n.url,!0),p.timeout=n.timeout,"onloadend"in p?p.onloadend=h:p.onreadystatechange=function(){p&&4===p.readyState&&(0!==p.status||p.responseURL&&0===p.responseURL.indexOf("file:"))&&setTimeout(h)},p.onabort=function(){p&&(r(new C.a("Request aborted",C.a.ECONNABORTED,f,p)),p=null)},p.onerror=function(){r(new C.a("Network Error",C.a.ERR_NETWORK,f,p)),p=null},p.ontimeout=function(){let e=n.timeout?"timeout of "+n.timeout+"ms exceeded":"timeout exceeded";var t=n.transitional||V;n.timeoutErrorMessage&&(e=n.timeoutErrorMessage),r(new C.a(e,t.clarifyTimeoutError?C.a.ETIMEDOUT:C.a.ECONNABORTED,f,p)),p=null},void 0===e&&o.setContentType(null),"setRequestHeader"in p&&g.a.forEach(o.toJSON(),function(e,t){p.setRequestHeader(t,e)}),g.a.isUndefined(n.withCredentials)||(p.withCredentials=!!n.withCredentials),a&&"json"!==a&&(p.responseType=n.responseType),i&&([o,c]=T(i,!0),p.addEventListener("progress",o)),s&&p.upload&&([o,d]=T(s),p.upload.addEventListener("progress",o),p.upload.addEventListener("loadend",d)),(n.cancelToken||n.signal)&&(l=e=>{p&&(r(!e||e.type?new b(null,f,p):e),p.abort(),p=null)},n.cancelToken&&n.cancelToken.subscribe(l),n.signal)&&(n.signal.aborted?l():n.signal.addEventListener("abort",l));o=n.url;o=(o=/^([-+\w]{1,25})(:?\/\/|:)/.exec(o))&&o[1]||"";o&&-1===m.protocols.indexOf(o)?r(new C.a("Unsupported protocol "+o+":",C.a.ERR_BAD_REQUEST,f)):p.send(e||null)})},Re=(a,s)=>{var i=(a=a?a.filter(Boolean):[]).length;if(s||i){let t=new AbortController,r,n=function(e){r||(r=!0,o(),e=e instanceof Error?e:this.reason,t.abort(e instanceof C.a?e:new b(e instanceof Error?e.message:e)))},e=s&&setTimeout(()=>{e=null,n(new C.a(`timeout ${s} of ms exceeded`,C.a.ETIMEDOUT))},s),o=()=>{a&&(e&&clearTimeout(e),e=null,a.forEach(e=>{e.unsubscribe?e.unsubscribe(n):e.removeEventListener("abort",n)}),a=null)};a.forEach(e=>e.addEventListener("abort",n));i=t.signal;return i.unsubscribe=()=>g.a.asap(o),i}},v=(e,t)=>Symbol[e]||Symbol.for("Symbol."+e),Oe=e=>{throw TypeError(e)},w=function(e,t){this[0]=e,this[1]=t},Ue=(e,t,i)=>{var l=(t,r,n,o)=>{try{var e=i[t](r),a=(r=e.value)instanceof w,s=e.done;Promise.resolve(a?r[0]:r).then(e=>a?l("return"===t?t:"next",r[1]?{done:e.done,value:e.value}:e,n,o):n({value:e,done:s})).catch(e=>l("throw",e,n,o))}catch(e){o(e)}},r=n=>o[n]=r=>new Promise((e,t)=>l(n,r,e,t)),o={};return i=i.apply(e,t),o[v("asyncIterator")]=()=>o,r("next"),r("throw"),r("return"),o},Ie=e=>{var o=e[v("asyncIterator")],t=!1,r={},e=null==o?(o=e[v("iterator")](),t=>r[t]=e=>o[t](e)):(o=o.call(e),n=>r[n]=r=>{if(t){if(t=!1,"throw"===n)throw r;return r}return{done:!(t=!0),value:new w(new Promise(e=>{var t=o[n](r);t instanceof Object||Oe("Object expected"),e(t)}),1)}});return r[v("iterator")]=()=>r,e("next"),"throw"in o?e("throw"):r.throw=e=>{throw e},"return"in o&&e("return"),r},Pe=(a,t,e)=>(t=a[v("asyncIterator")])?t.call(a):(a=a[v("iterator")](),t={},(e=(e,o)=>(o=a[e])&&(t[e]=n=>new Promise((t,e,r)=>(n=o.call(a,n),r=n.done,Promise.resolve(n.value).then(e=>t({value:e,done:r}),e)))))("next"),e("return"),t);let ge=function*(t,r){var n,o=t.byteLength;if(!r||o<r)yield t;else{let e=0;for(;e<o;)n=e+r,yield t.slice(e,n),e=n}},Ce=function(n){return Ue(this,null,function*(){if(n[Symbol.asyncIterator])yield*Ie(n);else{var e=n.getReader();try{for(;;){var{done:t,value:r}=yield new w(e.read());if(t)break;yield r}}finally{yield new w(e.cancel())}}})},Ee=(e,t,a,r)=>{let l=function(a,s){return Ue(this,null,function*(){try{for(var e,t,r,n=Pe(Ce(a));e=!(t=yield new w(n.next())).done;e=!1){var o=t.value;yield*Ie(ge(o,s))}}catch(t){r=[t]}finally{try{e&&(t=n.return)&&(yield new w(t.call(n)))}finally{if(r)throw r[0]}}})}(e,t),d=0,n,c=e=>{n||(n=!0,r&&r(e))};return new ReadableStream({pull(o){return e=this,s=null,i=function*(){try{var e,t,{done:r,value:n}=yield l.next();r?(c(),o.close()):(e=n.byteLength,a&&(t=d+=e,a(t)),o.enqueue(new Uint8Array(n)))}catch(e){throw c(e),e}},new Promise((t,r)=>{var n=e=>{try{a(i.next(e))}catch(e){r(e)}},o=e=>{try{a(i.throw(e))}catch(e){r(e)}},a=e=>e.done?t(e.value):Promise.resolve(e.value).then(n,o);a((i=i.apply(e,s)).next())});var e,s,i},cancel(e){return c(e),l.return()}},{highWaterMark:2})};var Te=Object.defineProperty,Se=Object.defineProperties,Ae=Object.getOwnPropertyDescriptors,ke=Object.getOwnPropertySymbols,xe=Object.prototype.hasOwnProperty,Ne=Object.prototype.propertyIsEnumerable,Fe=(e,t,r)=>t in e?Te(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,y=(e,s,i)=>new Promise((t,r)=>{var n=e=>{try{a(i.next(e))}catch(e){r(e)}},o=e=>{try{a(i.throw(e))}catch(e){r(e)}},a=e=>e.done?t(e.value):Promise.resolve(e.value).then(n,o);a((i=i.apply(e,s)).next())}),r="function"==typeof fetch&&"function"==typeof Request&&"function"==typeof Response,t=r&&"function"==typeof ReadableStream;let je=r&&("function"==typeof TextEncoder?(t=>e=>t.encode(e))(new TextEncoder):e=>y(void 0,null,function*(){return new Uint8Array(yield new Response(e).arrayBuffer())}));var Ge,R=(e,...t)=>{try{return!!e(...t)}catch(e){return!1}};let Le=t&&R(()=>{let e=!1;var t=new Request(m.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),S=t&&R(()=>g.a.isReadableStream(new Response("").body)),A={stream:S&&(e=>e.body)},ze=(r&&(Ge=new Response,["text","arrayBuffer","blob","formData","stream"].forEach(r=>{A[r]||(A[r]=g.a.isFunction(Ge[r])?e=>e[r]():(e,t)=>{throw new C.a(`Response type '${r}' is not supported`,C.a.ERR_NOT_SUPPORT,t)})})),(r,n)=>y(void 0,null,function*(){var e,t=g.a.toFiniteNumber(r.getContentLength());return null==t?(e=n,y(void 0,null,function*(){return null==e?0:g.a.isBlob(e)?e.size:g.a.isSpecCompliantForm(e)?(yield new Request(m.origin,{method:"POST",body:e}).arrayBuffer()).byteLength:g.a.isArrayBufferView(e)||g.a.isArrayBuffer(e)?e.byteLength:(g.a.isURLSearchParams(e)&&(e+=""),g.a.isString(e)?(yield je(e)).byteLength:void 0)})):t})),qe=r&&(P=>y(void 0,null,function*(){let{url:t,method:e,data:o,signal:r,cancelToken:n,timeout:a,onDownloadProgress:s,onUploadProgress:i,responseType:l,headers:d,withCredentials:c="same-origin",fetchOptions:u}=ye(P),p=(l=l?(l+"").toLowerCase():"text",Re([r,n&&n.toAbortSignal()],a)),h,f=p&&p.unsubscribe&&(()=>{p.unsubscribe()}),m;try{if(i&&Le&&"get"!==e&&"head"!==e&&0!==(m=yield ze(d,o))){var b,v,w=new Request(t,{method:"POST",body:o,duplex:"half"});let e;g.a.isFormData(o)&&(e=w.headers.get("content-type"))&&d.setContentType(e),w.body&&([b,v]=ie(m,T(le(i))),o=Ee(w.body,65536,b,v))}g.a.isString(c)||(c=c?"include":"omit");var y="credentials"in Request.prototype;h=new Request(t,(U=((e,t)=>{for(var r in t=t||{})xe.call(t,r)&&Fe(e,r,t[r]);if(ke)for(var r of ke(t))Ne.call(t,r)&&Fe(e,r,t[r]);return e})({},u),I={signal:p,method:e.toUpperCase(),headers:d.normalize().toJSON(),body:o,duplex:"half",credentials:y?c:void 0},Se(U,Ae(I))));let n=yield fetch(h);var R=S&&("stream"===l||"response"===l);if(S&&(s||R&&f)){let t={};["status","statusText","headers"].forEach(e=>{t[e]=n[e]});var O=g.a.toFiniteNumber(n.headers.get("content-length"));let[e,r]=s&&ie(O,T(le(s),!0))||[];n=new Response(Ee(n.body,65536,e,()=>{r&&r(),f&&f()}),t)}l=l||"text";let r=yield A[g.a.findKey(A,l)||"text"](n,P);return!R&&f&&f(),yield new Promise((e,t)=>{oe(e,t,{data:r,headers:E.from(n.headers),status:n.status,statusText:n.statusText,config:P,request:h})})}catch(e){if(f&&f(),e&&"TypeError"===e.name&&/fetch/i.test(e.message))throw Object.assign(new C.a("Network Error",C.a.ERR_NETWORK,P,h),{cause:e.cause||e});throw C.a.from(e,e&&e.code,P,h)}var U,I})),O={http:a.a,xhr:e,fetch:qe},De=(g.a.forEach(O,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch(e){}Object.defineProperty(e,"adapterName",{value:t})}}),e=>"- "+e);var _e=r=>{var n,e=(r=g.a.isArray(r)?r:[r]).length;let o;var a,t,s={};for(let t=0;t<e;t++){n=r[t];let e;if(o=n,a=n,!g.a.isFunction(a)&&null!==a&&!1!==a&&void 0===(o=O[(e=String(n)).toLowerCase()]))throw new C.a(`Unknown adapter '${e}'`);if(o)break;s[e||"#"+t]=o}if(o)return o;throw t=Object.entries(s).map(([e,t])=>`adapter ${e} `+(!1===t?"is not supported by the environment":"is not available in the build")),t=e?1<t.length?"since :\n"+t.map(De).join("\n"):" "+De(t[0]):"as no adapter specified",new C.a("There is no suitable adapter to dispatch the request "+t,"ERR_NOT_SUPPORT")};O;function Be(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new b(null,e)}function Je(t){return Be(t),t.headers=E.from(t.headers),t.data=h.call(t,t.transformRequest),-1!==["post","put","patch"].indexOf(t.method)&&t.headers.setContentType("application/x-www-form-urlencoded",!1),_e(t.adapter||l.adapter)(t).then(function(e){return Be(t),e.data=h.call(t,t.transformResponse,e),e.headers=E.from(e.headers),e},function(e){return re(e)||(Be(t),e&&e.response&&(e.response.data=h.call(t,t.transformResponse,e.response),e.response.headers=E.from(e.response.headers))),Promise.reject(e)})}let U={},Ve=(["object","boolean","number","function","string","symbol"].forEach((t,r)=>{U[t]=function(e){return typeof e===t||"a"+(r<1?"n ":" ")+t}}),{});U.transitional=function(n,o,r){function a(e,t){return"[Axios v1.7.8] Transitional option '"+e+"'"+t+(r?". "+r:"")}return(e,t,r)=>{if(!1===n)throw new C.a(a(t," has been removed"+(o?" in "+o:"")),C.a.ERR_DEPRECATED);return o&&!Ve[t]&&(Ve[t]=!0,console.warn(a(t," has been deprecated since v"+o+" and will be removed in the near future"))),!n||n(e,t,r)}},U.spelling=function(r){return(e,t)=>(console.warn(t+" is likely a misspelling of "+r),!0)};var I={assertOptions:function(e,t,r){if("object"!=typeof e)throw new C.a("options must be an object",C.a.ERR_BAD_OPTION_VALUE);var n=Object.keys(e);let o=n.length;for(;0<o--;){var a=n[o],s=t[a];if(s){var i=e[a],s=void 0===i||s(i,a,e);if(!0!==s)throw new C.a("option "+a+" must be "+s,C.a.ERR_BAD_OPTION_VALUE)}else if(!0!==r)throw new C.a("Unknown option "+a,C.a.ERR_BAD_OPTION)}},validators:U};let P=I.validators;class k{constructor(e){this.defaults=e,this.interceptors={request:new J,response:new J}}request(e,t){return s=this,i=null,l=function*(){try{return yield this._request(e,t)}catch(t){if(t instanceof Error){let e={};Error.captureStackTrace?Error.captureStackTrace(e):e=new Error;var r=e.stack?e.stack.replace(/^.+\n/,""):"";try{t.stack?r&&!String(t.stack).endsWith(r.replace(/^.+\n.+\n/,""))&&(t.stack+="\n"+r):t.stack=r}catch(e){}}throw t}},new Promise((t,r)=>{var n=e=>{try{a(l.next(e))}catch(e){r(e)}},o=e=>{try{a(l.throw(e))}catch(e){r(e)}},a=e=>e.done?t(e.value):Promise.resolve(e.value).then(n,o);a((l=l.apply(s,i)).next())});var s,i,l}_request(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{};let{transitional:r,paramsSerializer:n,headers:o}=t=f(this.defaults,t);void 0!==r&&I.assertOptions(r,{silentJSONParsing:P.transitional(P.boolean),forcedJSONParsing:P.transitional(P.boolean),clarifyTimeoutError:P.transitional(P.boolean)},!1),null!=n&&(g.a.isFunction(n)?t.paramsSerializer={serialize:n}:I.assertOptions(n,{encode:P.function,serialize:P.function},!0)),I.assertOptions(t,{baseUrl:P.spelling("baseURL"),withXsrfToken:P.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();e=o&&g.a.merge(o.common,o[t.method]);o&&g.a.forEach(["delete","get","head","post","put","patch","common"],e=>{delete o[e]}),t.headers=E.concat(e,o);let a=[],s=!0,i=(this.interceptors.request.forEach(function(e){"function"==typeof e.runWhen&&!1===e.runWhen(t)||(s=s&&e.synchronous,a.unshift(e.fulfilled,e.rejected))}),[]);this.interceptors.response.forEach(function(e){i.push(e.fulfilled,e.rejected)});let l,d=0,c;if(s){c=a.length;let e=t;for(d=0;d<c;){var u=a[d++],p=a[d++];try{e=u(e)}catch(e){p.call(this,e);break}}try{l=Je.call(this,e)}catch(e){return Promise.reject(e)}for(d=0,c=i.length;d<c;)l=l.then(i[d++],i[d++])}else{var h=[Je.bind(this),void 0];for(h.unshift.apply(h,a),h.push.apply(h,i),c=h.length,l=Promise.resolve(t);d<c;)l=l.then(h[d++],h[d++])}return l}getUri(e){return B(ue((e=f(this.defaults,e)).baseURL,e.url),e.params,e.paramsSerializer)}}g.a.forEach(["delete","get","head","options"],function(r){k.prototype[r]=function(e,t){return this.request(f(t||{},{method:r,url:e,data:(t||{}).data}))}}),g.a.forEach(["post","put","patch"],function(o){function e(n){return function(e,t,r){return this.request(f(r||{},{method:o,headers:n?{"Content-Type":"multipart/form-data"}:{},url:e,data:t}))}}k.prototype[o]=e(),k.prototype[o+"Form"]=e(!0)});var x=k;t=class ct{constructor(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");let n,o=(this.promise=new Promise(function(e){n=e}),this);this.promise.then(t=>{if(o._listeners){let e=o._listeners.length;for(;0<e--;)o._listeners[e](t);o._listeners=null}}),this.promise.then=e=>{let t;return(e=new Promise(e=>{o.subscribe(e),t=e}).then(e)).cancel=function(){o.unsubscribe(t)},e},e(function(e,t,r){o.reason||(o.reason=new b(e,t,r),n(o.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){this._listeners&&-1!==(e=this._listeners.indexOf(e))&&this._listeners.splice(e,1)}toAbortSignal(){let t=new AbortController,e=e=>{t.abort(e)};return this.subscribe(e),t.signal.unsubscribe=()=>this.unsubscribe(e),t.signal}static source(){let t;return{token:new ct(function(e){t=e}),cancel:t}}};let $e={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries($e).forEach(([e,t])=>{$e[t]=e});R=$e;var Me,We,r=function t(r){var e=new x(r),n=Object(L.a)(x.prototype.request,e);return g.a.extend(n,x.prototype,e,{allOwnKeys:!0}),g.a.extend(n,e,null,{allOwnKeys:!0}),n.create=function(e){return t(f(r,e))},n}(l),He=(r.Axios=x,r.CanceledError=b,r.CancelToken=t,r.isCancel=re,r.VERSION="1.7.8",r.toFormData=i.a,r.AxiosError=C.a,r.Cancel=r.CanceledError,r.all=function(e){return Promise.all(e)},r.spread=function(t){return function(e){return t.apply(null,e)}},r.isAxiosError=function(e){return g.a.isObject(e)&&!0===e.isAxiosError},r.mergeConfig=f,r.AxiosHeaders=E,r.formToJSON=e=>Y(g.a.isHTMLForm(e)?new FormData(e):e),r.getAdapter=_e,r.HttpStatusCode=R,r.default=r),Ke=Object.defineProperty,Xe=Object.defineProperties,Qe=Object.getOwnPropertyDescriptors,Ze=Object.getOwnPropertySymbols,Ye=Object.prototype.hasOwnProperty,et=Object.prototype.propertyIsEnumerable,tt=(e,t,r)=>t in e?Ke(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,rt=(e,t)=>{for(var r in t=t||{})Ye.call(t,r)&&tt(e,r,t[r]);if(Ze)for(var r of Ze(t))et.call(t,r)&&tt(e,r,t[r]);return e},nt=(e,t)=>Xe(e,Qe(t)),N=(e,t,r)=>tt(e,"symbol"!=typeof t?t+"":t,r),ot=(e,s,i)=>new Promise((t,r)=>{var n=e=>{try{a(i.next(e))}catch(e){r(e)}},o=e=>{try{a(i.throw(e))}catch(e){r(e)}},a=e=>e.done?t(e.value):Promise.resolve(e.value).then(n,o);a((i=i.apply(e,s)).next())});class at{constructor(){N(this,"apiUrl"),N(this,"apiKey",""),N(this,"authorizationToken",null)}getAuthorizationToken(){return ot(this,null,function*(){return this.authorizationToken})}setAuthorizationToken(e){this.authorizationToken=e}}class st{constructor(e){N(this,"configuration"),this.configuration=e}transformOptions(t){return ot(this,null,function*(){var e=yield this.configuration.getAuthorizationToken();return t.headers=nt(rt({},t.headers),null!=e?{authorization:" Bearer "+e}:{"X-API-Key":this.configuration.apiKey}),(t=nt(rt({},t),{transformResponse:e=>e})).responseType||(t.responseType="json"),"blob"==t.responseType&&(t.responseType="arraybuffer"),t})}getBaseUrl(e){return this.configuration.apiUrl.endsWith("/")?this.configuration.apiUrl.slice(0,-1):this.configuration.apiUrl}transformResult(e,t,r){return r(t)}}class it extends st{constructor(e,t,r){super(e),N(this,"instance"),N(this,"baseUrl"),N(this,"jsonParseReviver"),this.instance=r||He.create(),this.baseUrl=null!=t?t:this.getBaseUrl("")}getAll(e,t,r,n,o,a,s,i,l,d,c,u,p,h){let f=this.baseUrl+"/api/storefront/v1/product-references/ext?";if(null==e)throw new Error("The parameter 'storefrontId' must be defined and cannot be null.");f+="storefrontId="+encodeURIComponent(""+e)+"&",null!=t&&(f+="productReference="+encodeURIComponent(""+t)+"&"),null!=r&&(f+="productId="+encodeURIComponent(""+r)+"&"),null!=n&&(f+="productVersionId="+encodeURIComponent(""+n)+"&"),null!=o&&(f+="productLinkId="+encodeURIComponent(""+o)+"&"),null!=a&&(f+="skip="+encodeURIComponent(""+a)+"&"),null!=s&&(f+="take="+encodeURIComponent(""+s)+"&"),null!=i&&(f+="sorting="+encodeURIComponent(""+i)+"&"),null!=l&&(f+="search="+encodeURIComponent(""+l)+"&"),null!=d&&(f+="sku="+encodeURIComponent(""+d)+"&"),null!=c&&c&&c.forEach(e=>{f+="tags="+encodeURIComponent(""+e)+"&"}),null!=u&&(f+="customFields="+encodeURIComponent(""+u)+"&"),null!=p&&(f+="tenantId="+encodeURIComponent(""+p)+"&");e={method:"GET",url:f=f.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:h};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(f,e,e=>this.processGetAll(e)))}processGetAll(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(t=e.data,r=null,r=JSON.parse(t),Promise.resolve(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}get(e,t,r,n){let o=this.baseUrl+"/api/storefront/v1/product-references/ext/{reference}?";if(null==e)throw new Error("The parameter 'reference' must be defined.");if(o=o.replace("{reference}",encodeURIComponent(""+e)),null==t)throw new Error("The parameter 'storefrontId' must be defined and cannot be null.");o+="storefrontId="+encodeURIComponent(""+t)+"&",null!=r&&(o+="tenantId="+encodeURIComponent(""+r)+"&");e={method:"GET",url:o=o.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:n};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(o,e,e=>this.processGet(e)))}processGet(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getAllProductLinks(e,t,r,n,o,a,s,i,l,d,c,u,p,h){let f=this.baseUrl+"/api/storefront/v1/product-references/ext/product-links?";if(null==e)throw new Error("The parameter 'storefrontId' must be defined and cannot be null.");f+="storefrontId="+encodeURIComponent(""+e)+"&",null!=t&&(f+="productReference="+encodeURIComponent(""+t)+"&"),null!=r&&(f+="productId="+encodeURIComponent(""+r)+"&"),null!=n&&(f+="productVersionId="+encodeURIComponent(""+n)+"&"),null!=o&&(f+="productLinkId="+encodeURIComponent(""+o)+"&"),null!=a&&(f+="skip="+encodeURIComponent(""+a)+"&"),null!=s&&(f+="take="+encodeURIComponent(""+s)+"&"),null!=i&&(f+="sorting="+encodeURIComponent(""+i)+"&"),null!=l&&(f+="search="+encodeURIComponent(""+l)+"&"),null!=d&&(f+="sku="+encodeURIComponent(""+d)+"&"),null!=c&&c&&c.forEach(e=>{f+="tags="+encodeURIComponent(""+e)+"&"}),null!=u&&(f+="customFields="+encodeURIComponent(""+u)+"&"),null!=p&&(f+="tenantId="+encodeURIComponent(""+p)+"&");e={method:"GET",url:f=f.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:h};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(f,e,e=>this.processGetAllProductLinks(e)))}processGetAllProductLinks(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(t=e.data,r=null,r=JSON.parse(t),Promise.resolve(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProduct(e,t,r,n){let o=this.baseUrl+"/api/storefront/v1/product-references/ext/{reference}/product?";if(null==e)throw new Error("The parameter 'reference' must be defined.");if(o=o.replace("{reference}",encodeURIComponent(""+e)),null==t)throw new Error("The parameter 'storefrontId' must be defined and cannot be null.");o+="storefrontId="+encodeURIComponent(""+t)+"&",null!=r&&(o+="tenantId="+encodeURIComponent(""+r)+"&");e={method:"GET",url:o=o.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:n};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(o,e,e=>this.processGetProduct(e)))}processGetProduct(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProductSummary(e,t,r,n,o,a){let s=this.baseUrl+"/api/storefront/v1/product-references/ext/{reference}/product-summary?";if(null==e)throw new Error("The parameter 'reference' must be defined.");if(s=s.replace("{reference}",encodeURIComponent(""+e)),null==t)throw new Error("The parameter 'storefrontId' must be defined and cannot be null.");s+="storefrontId="+encodeURIComponent(""+t)+"&",null!=r&&(s+="productVariantId="+encodeURIComponent(""+r)+"&"),null!=n&&(s+="sku="+encodeURIComponent(""+n)+"&"),null!=o&&(s+="tenantId="+encodeURIComponent(""+o)+"&");e={method:"GET",url:s=s.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:a};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(s,e,e=>this.processGetProductSummary(e)))}processGetProductSummary(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProductLink(e,t,r,n){let o=this.baseUrl+"/api/storefront/v1/product-references/ext/{reference}/product-link?";if(null==e)throw new Error("The parameter 'reference' must be defined.");if(o=o.replace("{reference}",encodeURIComponent(""+e)),null==t)throw new Error("The parameter 'storefrontId' must be defined and cannot be null.");o+="storefrontId="+encodeURIComponent(""+t)+"&",null!=r&&(o+="tenantId="+encodeURIComponent(""+r)+"&");e={method:"GET",url:o=o.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:n};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(o,e,e=>this.processGetProductLink(e)))}processGetProductLink(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProductFilter(e,t,r,n){let o=this.baseUrl+"/api/storefront/v1/product-references/ext/{reference}/product-filter?";if(null==e)throw new Error("The parameter 'reference' must be defined.");if(o=o.replace("{reference}",encodeURIComponent(""+e)),null==t)throw new Error("The parameter 'storefrontId' must be defined and cannot be null.");o+="storefrontId="+encodeURIComponent(""+t)+"&",null!=r&&(o+="tenantId="+encodeURIComponent(""+r)+"&");e={method:"GET",url:o=o.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:n};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(o,e,e=>this.processGetProductFilter(e)))}processGetProductFilter(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProductCostDetails(e,t,r,n,o,a,s,i){let l=this.baseUrl+"/api/storefront/v1/product-references/ext/{reference}/product-cost-details?";if(null==e)throw new Error("The parameter 'reference' must be defined.");if(l=l.replace("{reference}",encodeURIComponent(""+e)),null==t)throw new Error("The parameter 'sku' must be defined and cannot be null.");if(l+="sku="+encodeURIComponent(""+t)+"&",null==r)throw new Error("The parameter 'storefrontId' must be defined and cannot be null.");if(l+="storefrontId="+encodeURIComponent(""+r)+"&",null!=n&&(l+="storefrontUserId="+encodeURIComponent(""+n)+"&"),null!=o&&(l+="currencyCode="+encodeURIComponent(""+o)+"&"),null===a)throw new Error("The parameter 'quantity' cannot be null.");void 0!==a&&(l+="quantity="+encodeURIComponent(""+a)+"&"),null!=s&&(l+="tenantId="+encodeURIComponent(""+s)+"&");e={method:"GET",url:l=l.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:i};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(l,e,e=>this.processGetProductCostDetails(e)))}processGetProductCostDetails(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getPersonalizationWorkflow(e,t,r,n){let o=this.baseUrl+"/api/storefront/v1/product-references/ext/{reference}/personalization-workflow?";if(null==e)throw new Error("The parameter 'reference' must be defined.");if(o=o.replace("{reference}",encodeURIComponent(""+e)),null==t)throw new Error("The parameter 'storefrontId' must be defined and cannot be null.");o+="storefrontId="+encodeURIComponent(""+t)+"&",null!=r&&(o+="tenantId="+encodeURIComponent(""+r)+"&");e={method:"GET",url:o=o.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:n};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(o,e,e=>this.processGetPersonalizationWorkflow(e)))}processGetPersonalizationWorkflow(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProductPersonalizationWorkflow(e,t,r,n){let o=this.baseUrl+"/api/storefront/v1/product-references/ext/{reference}/product-personalization-workflow?";if(null==e)throw new Error("The parameter 'reference' must be defined.");if(o=o.replace("{reference}",encodeURIComponent(""+e)),null==t)throw new Error("The parameter 'storefrontId' must be defined and cannot be null.");o+="storefrontId="+encodeURIComponent(""+t)+"&",null!=r&&(o+="tenantId="+encodeURIComponent(""+r)+"&");e={method:"GET",url:o=o.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:n};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(o,e,e=>this.processGetProductPersonalizationWorkflow(e)))}processGetProductPersonalizationWorkflow(e){var t,r=e.status,n={};if(e.headers&&"object"==typeof e.headers)for(var o in e.headers)e.headers.hasOwnProperty(o)&&(n[o]=e.headers[o]);return 200===r?(t=e.data,Promise.resolve(t)):404===r?F("Not Found",r,t=e.data,n,t):401===r?F("Unauthorized",r,e.data,n):403===r?F("Forbidden",r,e.data,n):200!==r&&204!==r?F("An unexpected server error occurred.",r,e.data,n):Promise.resolve(null)}obsoleteGetProduct(e,t,r,n){let o=this.baseUrl+"/api/storefront/v1/product-references/{reference}/product?";if(null==e)throw new Error("The parameter 'reference' must be defined.");if(o=o.replace("{reference}",encodeURIComponent(""+e)),null==t)throw new Error("The parameter 'storefrontId' must be defined and cannot be null.");o+="storefrontId="+encodeURIComponent(""+t)+"&",null!=r&&(o+="tenantId="+encodeURIComponent(""+r)+"&");e={method:"GET",url:o=o.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:n};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(o,e,e=>this.processObsoleteGetProduct(e)))}processObsoleteGetProduct(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}obsoleteGetProductLink(e,t,r,n){let o=this.baseUrl+"/api/storefront/v1/product-references/{reference}/product-link?";if(null==e)throw new Error("The parameter 'reference' must be defined.");if(o=o.replace("{reference}",encodeURIComponent(""+e)),null==t)throw new Error("The parameter 'storefrontId' must be defined and cannot be null.");o+="storefrontId="+encodeURIComponent(""+t)+"&",null!=r&&(o+="tenantId="+encodeURIComponent(""+r)+"&");e={method:"GET",url:o=o.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:n};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(o,e,e=>this.processObsoleteGetProductLink(e)))}processObsoleteGetProductLink(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}obsoleteGetProductFilter(e,t,r,n){let o=this.baseUrl+"/api/storefront/v1/product-references/{reference}/product-filter?";if(null==e)throw new Error("The parameter 'reference' must be defined.");if(o=o.replace("{reference}",encodeURIComponent(""+e)),null==t)throw new Error("The parameter 'storefrontId' must be defined and cannot be null.");o+="storefrontId="+encodeURIComponent(""+t)+"&",null!=r&&(o+="tenantId="+encodeURIComponent(""+r)+"&");e={method:"GET",url:o=o.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:n};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(o,e,e=>this.processObsoleteGetProductFilter(e)))}processObsoleteGetProductFilter(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}obsoleteGetProductPersonalizationWorkflow(e,t,r,n){let o=this.baseUrl+"/api/storefront/v1/product-references/{reference}/product-personalization-workflow?";if(null==e)throw new Error("The parameter 'reference' must be defined.");if(o=o.replace("{reference}",encodeURIComponent(""+e)),null==t)throw new Error("The parameter 'storefrontId' must be defined and cannot be null.");o+="storefrontId="+encodeURIComponent(""+t)+"&",null!=r&&(o+="tenantId="+encodeURIComponent(""+r)+"&");e={method:"GET",url:o=o.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:n};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(o,e,e=>this.processObsoleteGetProductPersonalizationWorkflow(e)))}processObsoleteGetProductPersonalizationWorkflow(e){var t,r=e.status,n={};if(e.headers&&"object"==typeof e.headers)for(var o in e.headers)e.headers.hasOwnProperty(o)&&(n[o]=e.headers[o]);return 200===r?(t=e.data,Promise.resolve(t)):404===r?F("Not Found",r,t=e.data,n,t):401===r?F("Unauthorized",r,e.data,n):403===r?F("Forbidden",r,e.data,n):200!==r&&204!==r?F("An unexpected server error occurred.",r,e.data,n):Promise.resolve(null)}}class lt extends st{constructor(e,t,r){super(e),N(this,"instance"),N(this,"baseUrl"),N(this,"jsonParseReviver"),this.instance=r||He.create(),this.baseUrl=null!=t?t:this.getBaseUrl("")}getAllProducts(e,t,r,n,o,a,s,i,l){let d=this.baseUrl+"/api/storefront/v1/products?";null!=e&&(d+="skip="+encodeURIComponent(""+e)+"&"),null!=t&&(d+="take="+encodeURIComponent(""+t)+"&"),null!=r&&(d+="sorting="+encodeURIComponent(""+r)+"&"),null!=n&&(d+="search="+encodeURIComponent(""+n)+"&"),null!=o&&(d+="sku="+encodeURIComponent(""+o)+"&"),null!=a&&a&&a.forEach(e=>{d+="tags="+encodeURIComponent(""+e)+"&"}),null!=s&&(d+="customFields="+encodeURIComponent(""+s)+"&"),null!=i&&(d+="tenantId="+encodeURIComponent(""+i)+"&");e={method:"GET",url:d=d.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:l};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(d,e,e=>this.processGetAllProducts(e)))}processGetAllProducts(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(t=e.data,r=null,r=JSON.parse(t),Promise.resolve(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProduct(e,t,r,n){let o=this.baseUrl+"/api/storefront/v1/products/{id}?";if(null==e)throw new Error("The parameter 'id' must be defined.");o=o.replace("{id}",encodeURIComponent(""+e)),null!=t&&(o+="productVersionId="+encodeURIComponent(""+t)+"&"),null!=r&&(o+="tenantId="+encodeURIComponent(""+r)+"&");e={method:"GET",url:o=o.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:n};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(o,e,e=>this.processGetProduct(e)))}processGetProduct(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProductSummary(e,t,r,n,o,a,s){let i=this.baseUrl+"/api/storefront/v1/products/{id}/summary?";if(null==e)throw new Error("The parameter 'id' must be defined.");i=i.replace("{id}",encodeURIComponent(""+e)),null!=t&&(i+="productVersionId="+encodeURIComponent(""+t)+"&"),null!=r&&(i+="productLinkId="+encodeURIComponent(""+r)+"&"),null!=n&&(i+="productVariantId="+encodeURIComponent(""+n)+"&"),null!=o&&(i+="sku="+encodeURIComponent(""+o)+"&"),null!=a&&(i+="tenantId="+encodeURIComponent(""+a)+"&");e={method:"GET",url:i=i.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:s};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(i,e,e=>this.processGetProductSummary(e)))}processGetProductSummary(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProductOptions(e,t,r,n){let o=this.baseUrl+"/api/storefront/v1/products/{id}/options?";if(null==e)throw new Error("The parameter 'id' must be defined.");o=o.replace("{id}",encodeURIComponent(""+e)),null!=t&&(o+="productVersionId="+encodeURIComponent(""+t)+"&"),null!=r&&(o+="tenantId="+encodeURIComponent(""+r)+"&");e={method:"GET",url:o=o.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:n};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(o,e,e=>this.processGetProductOptions(e)))}processGetProductOptions(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getAllProductOptions(e,t){let r=this.baseUrl+"/api/storefront/v1/products/options?";null!=e&&(r+="tenantId="+encodeURIComponent(""+e)+"&");e={method:"GET",url:r=r.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:t};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(r,e,e=>this.processGetAllProductOptions(e)))}processGetAllProductOptions(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(t=e.data,r=null,r=JSON.parse(t),Promise.resolve(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProductLinks(e,t,r,n,o,a,s,i){let l=this.baseUrl+"/api/storefront/v1/products/{id}/links?";if(null==e)throw new Error("The parameter 'id' must be defined.");l=l.replace("{id}",encodeURIComponent(""+e)),null!=t&&(l+="productVersionId="+encodeURIComponent(""+t)+"&"),null!=r&&(l+="skip="+encodeURIComponent(""+r)+"&"),null!=n&&(l+="take="+encodeURIComponent(""+n)+"&"),null!=o&&(l+="sorting="+encodeURIComponent(""+o)+"&"),null!=a&&(l+="search="+encodeURIComponent(""+a)+"&"),null!=s&&(l+="tenantId="+encodeURIComponent(""+s)+"&");e={method:"GET",url:l=l.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:i};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(l,e,e=>this.processGetProductLinks(e)))}processGetProductLinks(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProductLink(e,t,r,n,o){let a=this.baseUrl+"/api/storefront/v1/products/{id}/links/{productLinkId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(a=a.replace("{id}",encodeURIComponent(""+e)),null==t)throw new Error("The parameter 'productLinkId' must be defined.");a=a.replace("{productLinkId}",encodeURIComponent(""+t)),null!=r&&(a+="productVersionId="+encodeURIComponent(""+r)+"&"),null!=n&&(a+="tenantId="+encodeURIComponent(""+n)+"&");e={method:"GET",url:a=a.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:o};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(a,e,e=>this.processGetProductLink(e)))}processGetProductLink(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProductFilters(e,t,r,n,o,a,s,i,l){let d=this.baseUrl+"/api/storefront/v1/products/{id}/filters?";if(null==e)throw new Error("The parameter 'id' must be defined.");d=d.replace("{id}",encodeURIComponent(""+e)),null!=t&&(d+="productVersionId="+encodeURIComponent(""+t)+"&"),null!=r&&(d+="filterType="+encodeURIComponent(""+r)+"&"),null!=n&&(d+="skip="+encodeURIComponent(""+n)+"&"),null!=o&&(d+="take="+encodeURIComponent(""+o)+"&"),null!=a&&(d+="sorting="+encodeURIComponent(""+a)+"&"),null!=s&&(d+="search="+encodeURIComponent(""+s)+"&"),null!=i&&(d+="tenantId="+encodeURIComponent(""+i)+"&");e={method:"GET",url:d=d.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:l};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(d,e,e=>this.processGetProductFilters(e)))}processGetProductFilters(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProductFilter(e,t,r,n,o){let a=this.baseUrl+"/api/storefront/v1/products/{id}/filters/{productFilterId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(a=a.replace("{id}",encodeURIComponent(""+e)),null==t)throw new Error("The parameter 'productFilterId' must be defined.");a=a.replace("{productFilterId}",encodeURIComponent(""+t)),null!=r&&(a+="productVersionId="+encodeURIComponent(""+r)+"&"),null!=n&&(a+="tenantId="+encodeURIComponent(""+n)+"&");e={method:"GET",url:a=a.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:o};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(a,e,e=>this.processGetProductFilter(e)))}processGetProductFilter(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProductVariants(e,t,r,n,o,a,s,i,l,d){let c=this.baseUrl+"/api/storefront/v1/products/{id}/variants?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(c=c.replace("{id}",encodeURIComponent(""+e)),null!=t&&(c+="productVersionId="+encodeURIComponent(""+t)+"&"),null!=r&&(c+="skip="+encodeURIComponent(""+r)+"&"),null!=n&&(c+="take="+encodeURIComponent(""+n)+"&"),null!=o&&(c+="options="+encodeURIComponent(""+o)+"&"),null!=a&&(c+="productFilterId="+encodeURIComponent(""+a)+"&"),null===s)throw new Error("The parameter 'takeAvailableOnly' cannot be null.");void 0!==s&&(c+="takeAvailableOnly="+encodeURIComponent(""+s)+"&"),null!=i&&(c+="sku="+encodeURIComponent(""+i)+"&"),null!=l&&(c+="tenantId="+encodeURIComponent(""+l)+"&");e={method:"GET",url:c=c.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:d};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(c,e,e=>this.processGetProductVariants(e)))}processGetProductVariants(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProductVariant(e,t,r,n,o){let a=this.baseUrl+"/api/storefront/v1/products/{id}/variants/{productVariantId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(a=a.replace("{id}",encodeURIComponent(""+e)),null==t)throw new Error("The parameter 'productVariantId' must be defined.");a=a.replace("{productVariantId}",encodeURIComponent(""+t)),null!=r&&(a+="productVersionId="+encodeURIComponent(""+r)+"&"),null!=n&&(a+="tenantId="+encodeURIComponent(""+n)+"&");e={method:"GET",url:a=a.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:o};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(a,e,e=>this.processGetProductVariant(e)))}processGetProductVariant(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProductVariantDesigns(e,t,r,n,o,a,s,i,l,d,c,u,p,h){let f=this.baseUrl+"/api/storefront/v1/products/{id}/variant-designs?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(f=f.replace("{id}",encodeURIComponent(""+e)),null!=t&&(f+="productVersionId="+encodeURIComponent(""+t)+"&"),null!=r&&(f+="productVariantId="+encodeURIComponent(""+r)+"&"),null!=n&&(f+="search="+encodeURIComponent(""+n)+"&"),null!=o&&(f+="designCustomFields="+encodeURIComponent(""+o)+"&"),null!=a&&(f+="designPath="+encodeURIComponent(""+a)+"&"),null!=s&&(f+="skip="+encodeURIComponent(""+s)+"&"),null!=i&&(f+="take="+encodeURIComponent(""+i)+"&"),null!=l&&(f+="options="+encodeURIComponent(""+l)+"&"),null!=d&&(f+="productFilterId="+encodeURIComponent(""+d)+"&"),null===c)throw new Error("The parameter 'takeAvailableOnly' cannot be null.");void 0!==c&&(f+="takeAvailableOnly="+encodeURIComponent(""+c)+"&"),null!=u&&(f+="sku="+encodeURIComponent(""+u)+"&"),null!=p&&(f+="tenantId="+encodeURIComponent(""+p)+"&");e={method:"GET",url:f=f.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:h};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(f,e,e=>this.processGetProductVariantDesigns(e)))}processGetProductVariantDesigns(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProductVariantMockups(e,t,r,n,o,a,s,i,l,d,c,u,p,h){let f=this.baseUrl+"/api/storefront/v1/products/{id}/variant-mockups?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(f=f.replace("{id}",encodeURIComponent(""+e)),null!=t&&(f+="productVersionId="+encodeURIComponent(""+t)+"&"),null!=r&&(f+="productVariantId="+encodeURIComponent(""+r)+"&"),null!=n&&(f+="search="+encodeURIComponent(""+n)+"&"),null!=o&&(f+="mockupCustomFields="+encodeURIComponent(""+o)+"&"),null!=a&&(f+="mockupPath="+encodeURIComponent(""+a)+"&"),null!=s&&(f+="skip="+encodeURIComponent(""+s)+"&"),null!=i&&(f+="take="+encodeURIComponent(""+i)+"&"),null!=l&&(f+="options="+encodeURIComponent(""+l)+"&"),null!=d&&(f+="productFilterId="+encodeURIComponent(""+d)+"&"),null===c)throw new Error("The parameter 'takeAvailableOnly' cannot be null.");void 0!==c&&(f+="takeAvailableOnly="+encodeURIComponent(""+c)+"&"),null!=u&&(f+="sku="+encodeURIComponent(""+u)+"&"),null!=p&&(f+="tenantId="+encodeURIComponent(""+p)+"&");e={method:"GET",url:f=f.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:h};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(f,e,e=>this.processGetProductVariantMockups(e)))}processGetProductVariantMockups(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getProductVariantDocuments(e,t,r,n,o,a,s,i,l,d,c,u,p,h){let f=this.baseUrl+"/api/storefront/v1/products/{id}/variant-documents?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(f=f.replace("{id}",encodeURIComponent(""+e)),null!=t&&(f+="productVersionId="+encodeURIComponent(""+t)+"&"),null!=r&&(f+="productVariantId="+encodeURIComponent(""+r)+"&"),null!=n&&(f+="search="+encodeURIComponent(""+n)+"&"),null!=o&&(f+="documentCustomFields="+encodeURIComponent(""+o)+"&"),null!=a&&(f+="documentPath="+encodeURIComponent(""+a)+"&"),null!=s&&(f+="skip="+encodeURIComponent(""+s)+"&"),null!=i&&(f+="take="+encodeURIComponent(""+i)+"&"),null!=l&&(f+="options="+encodeURIComponent(""+l)+"&"),null!=d&&(f+="productFilterId="+encodeURIComponent(""+d)+"&"),null===c)throw new Error("The parameter 'takeAvailableOnly' cannot be null.");void 0!==c&&(f+="takeAvailableOnly="+encodeURIComponent(""+c)+"&"),null!=u&&(f+="sku="+encodeURIComponent(""+u)+"&"),null!=p&&(f+="tenantId="+encodeURIComponent(""+p)+"&");e={method:"GET",url:f=f.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:h};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(f,e,e=>this.processGetProductVariantDocuments(e)))}processGetProductVariantDocuments(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}updateProductVariantResources(e,t,r,n){let o=this.baseUrl+"/api/storefront/v1/products/{id}/update-variant-resources?";if(null==e)throw new Error("The parameter 'id' must be defined.");o=o.replace("{id}",encodeURIComponent(""+e)),null!=t&&(o+="productVersionId="+encodeURIComponent(""+t)+"&"),null!=r&&(o+="tenantId="+encodeURIComponent(""+r)+"&");e={method:"POST",url:o=o.replace(/[?&]$/,""),headers:{},cancelToken:n};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(o,e,e=>this.processUpdateProductVariantResources(e)))}processUpdateProductVariantResources(e){var t,r=e.status,n={};if(e.headers&&"object"==typeof e.headers)for(var o in e.headers)e.headers.hasOwnProperty(o)&&(n[o]=e.headers[o]);return 200===r?(e.data,Promise.resolve(null)):404===r?F("Not Found",r,t=e.data,n,JSON.parse(t)):401===r?F("Unauthorized",r,e.data,n):403===r?F("Forbidden",r,e.data,n):200!==r&&204!==r?F("An unexpected server error occurred.",r,e.data,n):Promise.resolve(null)}setProductVariantPrice(e,t,r,n,o){let a=this.baseUrl+"/api/storefront/v1/products/{id}/set-variant-price?";if(null==e)throw new Error("The parameter 'id' must be defined.");a=a.replace("{id}",encodeURIComponent(""+e)),null!=t&&(a+="productVersionId="+encodeURIComponent(""+t)+"&"),null!=r&&(a+="tenantId="+encodeURIComponent(""+r)+"&"),a=a.replace(/[?&]$/,"");e={data:JSON.stringify(n),method:"POST",url:a,headers:{"Content-Type":"application/json-patch+json"},cancelToken:o};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(a,e,e=>this.processSetProductVariantPrice(e)))}processSetProductVariantPrice(e){var t,r=e.status,n={};if(e.headers&&"object"==typeof e.headers)for(var o in e.headers)e.headers.hasOwnProperty(o)&&(n[o]=e.headers[o]);return 200===r?(e.data,Promise.resolve(null)):404===r?F("Not Found",r,t=e.data,n,JSON.parse(t)):401===r?F("Unauthorized",r,e.data,n):403===r?F("Forbidden",r,e.data,n):200!==r&&204!==r?F("An unexpected server error occurred.",r,e.data,n):Promise.resolve(null)}getAvailableProductTags(e,t,r){let n=this.baseUrl+"/api/storefront/v1/products/available-tags?";null!=e&&(n+="search="+encodeURIComponent(""+e)+"&"),null!=t&&(n+="tenantId="+encodeURIComponent(""+t)+"&");e={method:"GET",url:n=n.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:r};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(n,e,e=>this.processGetAvailableProductTags(e)))}processGetAvailableProductTags(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(t=e.data,r=null,r=JSON.parse(t),Promise.resolve(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}getPersonalizationWorkflow(e,t,r,n,o,a){let s=this.baseUrl+"/api/storefront/v1/products/{id}/personalization-workflow?";if(null==e)throw new Error("The parameter 'id' must be defined.");s=s.replace("{id}",encodeURIComponent(""+e)),null!=t&&(s+="productVersionId="+encodeURIComponent(""+t)+"&"),null!=r&&(s+="productLinkId="+encodeURIComponent(""+r)+"&"),null!=n&&(s+="productFilterId="+encodeURIComponent(""+n)+"&"),null!=o&&(s+="tenantId="+encodeURIComponent(""+o)+"&");e={method:"GET",url:s=s.replace(/[?&]$/,""),headers:{Accept:"text/plain"},cancelToken:a};return this.transformOptions(e).then(e=>this.instance.request(e)).catch(e=>{if(j(e)&&e.response)return e.response;throw e}).then(e=>this.transformResult(s,e,e=>this.processGetPersonalizationWorkflow(e)))}processGetPersonalizationWorkflow(e){var t,r,n=e.status,o={};if(e.headers&&"object"==typeof e.headers)for(var a in e.headers)e.headers.hasOwnProperty(a)&&(o[a]=e.headers[a]);return 200===n?(r=e.data,t=null,t=JSON.parse(r),Promise.resolve(t)):404===n?F("Not Found",n,r=e.data,o,JSON.parse(r)):401===n?F("Unauthorized",n,e.data,o):403===n?F("Forbidden",n,e.data,o):200!==n&&204!==n?F("An unexpected server error occurred.",n,e.data,o):Promise.resolve(null)}}(a=Me=Me||{}).Radio="Radio",a.Dropdown="Dropdown",a.Chips="Chips",a.ColorGrid="ColorGrid",a.ColorList="ColorList",a.ImageGrid="ImageGrid",a.ImageList="ImageList",(e=We=We||{}).Preview="Preview",e.EditorModel="EditorModel",e.Custom="Custom";class dt extends Error{constructor(e,t,r,n,o){super(),N(this,"message"),N(this,"status"),N(this,"response"),N(this,"headers"),N(this,"result"),N(this,"isApiException",!0),this.message=e,this.status=t,this.response=r,this.headers=n,this.result=o}static isApiException(e){return!0===e.isApiException}}function F(e,t,r,n,o){throw null!=o?o:new dt(e,t,r,n,null)}function j(e){return e&&!0===e.isAxiosError}},816:function(e,t,r){function n(e,t){return function(){return e.apply(t,arguments)}}r.d(t,"a",function(){return n})},817:function(e,t,r){t.a=null}}]);