@shopware-ag/admin-extension-sdk
Advanced tools
Comparing version 2.1.0 to 2.2.0
@@ -1,1 +0,1 @@ | ||
var Ng=Object.defineProperty;var Ke=Object.getOwnPropertySymbols;var Rg=Object.prototype.hasOwnProperty,Gg=Object.prototype.propertyIsEnumerable;var Pt=(b,h,v)=>h in b?Ng(b,h,{enumerable:!0,configurable:!0,writable:!0,value:v}):b[h]=v,Et=(b,h)=>{for(var v in h||(h={}))Rg.call(h,v)&&Pt(b,v,h[v]);if(Ke)for(var v of Ke(h))Gg.call(h,v)&&Pt(b,v,h[v]);return b};var g=(b,h,v)=>(Pt(b,typeof h!="symbol"?h+"":h,v),v);(function(b,h){typeof exports=="object"&&typeof module!="undefined"?h(exports):typeof define=="function"&&define.amd?define(["exports"],h):(b=typeof globalThis!="undefined"?globalThis:b||self,h(b.sw={}))})(this,function(b){var ke;"use strict";var h=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{},v=Object.prototype,qe=v.hasOwnProperty;function Ve(t,e){return t!=null&&qe.call(t,e)}var We=Ve,Je=Array.isArray,O=Je,Ye=typeof h=="object"&&h&&h.Object===Object&&h,Mt=Ye,Xe=Mt,Ze=typeof self=="object"&&self&&self.Object===Object&&self,Qe=Xe||Ze||Function("return this")(),w=Qe,tr=w,er=tr.Symbol,J=er,xt=J,Dt=Object.prototype,rr=Dt.hasOwnProperty,nr=Dt.toString,G=xt?xt.toStringTag:void 0;function ir(t){var e=rr.call(t,G),r=t[G];try{t[G]=void 0;var n=!0}catch{}var i=nr.call(t);return n&&(e?t[G]=r:delete t[G]),i}var ar=ir,sr=Object.prototype,or=sr.toString;function cr(t){return or.call(t)}var ur=cr,zt=J,lr=ar,fr=ur,gr="[object Null]",dr="[object Undefined]",Ft=zt?zt.toStringTag:void 0;function _r(t){return t==null?t===void 0?dr:gr:Ft&&Ft in Object(t)?lr(t):fr(t)}var U=_r;function pr(t){return t!=null&&typeof t=="object"}var I=pr,hr=U,yr=I,br="[object Symbol]";function vr(t){return typeof t=="symbol"||yr(t)&&hr(t)==br}var at=vr,$r=O,mr=at,Sr=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,wr=/^\w*$/;function Tr(t,e){if($r(t))return!1;var r=typeof t;return r=="number"||r=="symbol"||r=="boolean"||t==null||mr(t)?!0:wr.test(t)||!Sr.test(t)||e!=null&&t in Object(e)}var Ar=Tr;function Or(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}var H=Or,Cr=U,jr=H,Ir="[object AsyncFunction]",Pr="[object Function]",Er="[object GeneratorFunction]",Mr="[object Proxy]";function xr(t){if(!jr(t))return!1;var e=Cr(t);return e==Pr||e==Er||e==Ir||e==Mr}var Lt=xr,Dr=w,zr=Dr["__core-js_shared__"],Fr=zr,st=Fr,Nt=function(){var t=/[^.]+$/.exec(st&&st.keys&&st.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function Lr(t){return!!Nt&&Nt in t}var Nr=Lr,Rr=Function.prototype,Gr=Rr.toString;function Ur(t){if(t!=null){try{return Gr.call(t)}catch{}try{return t+""}catch{}}return""}var Rt=Ur,Hr=Lt,Br=Nr,kr=H,Kr=Rt,qr=/[\\^$.*+?()[\]{}|]/g,Vr=/^\[object .+?Constructor\]$/,Wr=Function.prototype,Jr=Object.prototype,Yr=Wr.toString,Xr=Jr.hasOwnProperty,Zr=RegExp("^"+Yr.call(Xr).replace(qr,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Qr(t){if(!kr(t)||Br(t))return!1;var e=Hr(t)?Zr:Vr;return e.test(Kr(t))}var tn=Qr;function en(t,e){return t==null?void 0:t[e]}var rn=en,nn=tn,an=rn;function sn(t,e){var r=an(t,e);return nn(r)?r:void 0}var C=sn,on=C,cn=on(Object,"create"),Y=cn,Gt=Y;function un(){this.__data__=Gt?Gt(null):{},this.size=0}var ln=un;function fn(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var gn=fn,dn=Y,_n="__lodash_hash_undefined__",pn=Object.prototype,hn=pn.hasOwnProperty;function yn(t){var e=this.__data__;if(dn){var r=e[t];return r===_n?void 0:r}return hn.call(e,t)?e[t]:void 0}var bn=yn,vn=Y,$n=Object.prototype,mn=$n.hasOwnProperty;function Sn(t){var e=this.__data__;return vn?e[t]!==void 0:mn.call(e,t)}var wn=Sn,Tn=Y,An="__lodash_hash_undefined__";function On(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=Tn&&e===void 0?An:e,this}var Cn=On,jn=ln,In=gn,Pn=bn,En=wn,Mn=Cn;function P(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}P.prototype.clear=jn,P.prototype.delete=In,P.prototype.get=Pn,P.prototype.has=En,P.prototype.set=Mn;var xn=P;function Dn(){this.__data__=[],this.size=0}var zn=Dn;function Fn(t,e){return t===e||t!==t&&e!==e}var Ut=Fn,Ln=Ut;function Nn(t,e){for(var r=t.length;r--;)if(Ln(t[r][0],e))return r;return-1}var X=Nn,Rn=X,Gn=Array.prototype,Un=Gn.splice;function Hn(t){var e=this.__data__,r=Rn(e,t);if(r<0)return!1;var n=e.length-1;return r==n?e.pop():Un.call(e,r,1),--this.size,!0}var Bn=Hn,kn=X;function Kn(t){var e=this.__data__,r=kn(e,t);return r<0?void 0:e[r][1]}var qn=Kn,Vn=X;function Wn(t){return Vn(this.__data__,t)>-1}var Jn=Wn,Yn=X;function Xn(t,e){var r=this.__data__,n=Yn(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this}var Zn=Xn,Qn=zn,ti=Bn,ei=qn,ri=Jn,ni=Zn;function E(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}E.prototype.clear=Qn,E.prototype.delete=ti,E.prototype.get=ei,E.prototype.has=ri,E.prototype.set=ni;var Z=E,ii=C,ai=w,si=ii(ai,"Map"),ot=si,Ht=xn,oi=Z,ci=ot;function ui(){this.size=0,this.__data__={hash:new Ht,map:new(ci||oi),string:new Ht}}var li=ui;function fi(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}var gi=fi,di=gi;function _i(t,e){var r=t.__data__;return di(e)?r[typeof e=="string"?"string":"hash"]:r.map}var Q=_i,pi=Q;function hi(t){var e=pi(this,t).delete(t);return this.size-=e?1:0,e}var yi=hi,bi=Q;function vi(t){return bi(this,t).get(t)}var $i=vi,mi=Q;function Si(t){return mi(this,t).has(t)}var wi=Si,Ti=Q;function Ai(t,e){var r=Ti(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this}var Oi=Ai,Ci=li,ji=yi,Ii=$i,Pi=wi,Ei=Oi;function M(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}M.prototype.clear=Ci,M.prototype.delete=ji,M.prototype.get=Ii,M.prototype.has=Pi,M.prototype.set=Ei;var Bt=M,kt=Bt,Mi="Expected a function";function ct(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(Mi);var r=function(){var n=arguments,i=e?e.apply(this,n):n[0],a=r.cache;if(a.has(i))return a.get(i);var s=t.apply(this,n);return r.cache=a.set(i,s)||a,s};return r.cache=new(ct.Cache||kt),r}ct.Cache=kt;var xi=ct,Di=xi,zi=500;function Fi(t){var e=Di(t,function(n){return r.size===zi&&r.clear(),n}),r=e.cache;return e}var Li=Fi,Ni=Li,Ri=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Gi=/\\(\\)?/g,Ui=Ni(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(Ri,function(r,n,i,a){e.push(i?a.replace(Gi,"$1"):n||r)}),e}),Hi=Ui;function Bi(t,e){for(var r=-1,n=t==null?0:t.length,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i}var ki=Bi,Kt=J,Ki=ki,qi=O,Vi=at,Wi=1/0,qt=Kt?Kt.prototype:void 0,Vt=qt?qt.toString:void 0;function Wt(t){if(typeof t=="string")return t;if(qi(t))return Ki(t,Wt)+"";if(Vi(t))return Vt?Vt.call(t):"";var e=t+"";return e=="0"&&1/t==-Wi?"-0":e}var Ji=Wt,Yi=Ji;function Xi(t){return t==null?"":Yi(t)}var Zi=Xi,Qi=O,ta=Ar,ea=Hi,ra=Zi;function na(t,e){return Qi(t)?t:ta(t,e)?[t]:ea(ra(t))}var ia=na,aa=U,sa=I,oa="[object Arguments]";function ca(t){return sa(t)&&aa(t)==oa}var ua=ca,Jt=ua,la=I,Yt=Object.prototype,fa=Yt.hasOwnProperty,ga=Yt.propertyIsEnumerable,da=Jt(function(){return arguments}())?Jt:function(t){return la(t)&&fa.call(t,"callee")&&!ga.call(t,"callee")},Xt=da,_a=9007199254740991,pa=/^(?:0|[1-9]\d*)$/;function ha(t,e){var r=typeof t;return e=e==null?_a:e,!!e&&(r=="number"||r!="symbol"&&pa.test(t))&&t>-1&&t%1==0&&t<e}var Zt=ha,ya=9007199254740991;function ba(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=ya}var ut=ba,va=at,$a=1/0;function ma(t){if(typeof t=="string"||va(t))return t;var e=t+"";return e=="0"&&1/t==-$a?"-0":e}var Sa=ma,wa=ia,Ta=Xt,Aa=O,Oa=Zt,Ca=ut,ja=Sa;function Ia(t,e,r){e=wa(e,t);for(var n=-1,i=e.length,a=!1;++n<i;){var s=ja(e[n]);if(!(a=t!=null&&r(t,s)))break;t=t[s]}return a||++n!=i?a:(i=t==null?0:t.length,!!i&&Ca(i)&&Oa(s,i)&&(Aa(t)||Ta(t)))}var Pa=Ia,Ea=We,Ma=Pa;function xa(t,e){return t!=null&&Ma(t,e,Ea)}var Da=xa;function Qt(){return String(Date.now().toString(36)+Math.random().toString(36).substr(2))}function tt(t){return t!==null&&typeof t=="object"}function lt(){return new URLSearchParams(window.location.search).get("location-id")}function za(){const t=window.location;return new URL(t.pathname,t.origin).toString()}function B(t,e){return tt(e)&&e.__type__&&e.__type__===t}function Fa(t,e){return Da(t,e)}function te(t,e){for(let r in t){const n=t[r];e.apply(this,[t,r,n]),tt(n)&&te(n,e)}}const ft={notificationDispatch:{},windowRedirect:{},windowReload:{},contextLanguage:{},contextEnvironment:{},contextLocale:{},contextCurrency:{},contextShopwareVersion:{},contextAppInformation:{},getPageTitle:{},uiComponentSectionRenderer:{},uiTabsAddTabItem:{},locationUpdateHeight:{},menuItemAdd:{},settingsItemAdd:{},mainModuleAdd:{},uiModalOpen:{},uiModalClose:{},actionButtonAdd:{},actionExecute:{},datasetRegistration:{},datasetSubscribe:{},datasetUpdate:{},__function__:{},__registerWindow__:{},_criteriaTest:{},_collectionTest:{},_multiply:{},_subtract:{},_privileges:{create:["user"],read:["user"],update:["user"],delete:["user"]}};function La(t){const e=ee(t),r=Ra(window.location);return!e||Object.keys(e).length<=0?null:re(e,r)}function Na(t,e){const r=ee(t),n=ne(e);return n?re(r,n.permissions):null}function ee(t){var e;return(e=ft[t])!=null?e:{}}function Ra(t){const r=new URLSearchParams(t.search).get("privileges");return r?JSON.parse(r):{}}function re(t,e){const r=Object.keys(t),n=[];return r.forEach(i=>{var a;(a=t[i])==null||a.forEach(s=>{var u;(u=e[i])!=null&&u.includes(s)||n.push(`${i}:${s}`)})}),n.length>=1?n:null}function ne(t){return Object.values(Ge).find(e=>e.baseUrl===t)}class x extends Error{constructor(e,r){super(`Your app is missing the privileges ${r.join(", ")} for action "${e}".`);g(this,"missingPrivileges");g(this,"messageType");this.missingPrivileges=r,this.messageType=e,Object.setPrototypeOf(this,x.prototype)}toJSON(){return{__type__:"__MissingPrivilegesError__",__messageType__:this.messageType,__data__:this.missingPrivileges}}}const Ga=({send:t,handle:e})=>{const r={};let n=!1;function i(){n||(n=!0,e("__function__",async({args:a,id:s})=>await Promise.resolve(r[s](...a))))}return{name:"function",serialize:({value:a})=>{if(typeof a=="function"){const s=Qt();return r[s]=a,i(),{__type__:"__function__",id:s,origin:window.origin}}},deserialize:({value:a,event:s})=>{var c;const u=(c=s==null?void 0:s.source)!=null?c:window;if(tt(a)&&a.__type__&&a.__type__==="__function__"&&typeof a.id=="string"){const o=a.id,l=a.origin;return(...f)=>t("__function__",{args:f,id:o},u,l)}}}};var Ua=Z;function Ha(){this.__data__=new Ua,this.size=0}var Ba=Ha;function ka(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}var Ka=ka;function qa(t){return this.__data__.get(t)}var Va=qa;function Wa(t){return this.__data__.has(t)}var Ja=Wa,Ya=Z,Xa=ot,Za=Bt,Qa=200;function ts(t,e){var r=this.__data__;if(r instanceof Ya){var n=r.__data__;if(!Xa||n.length<Qa-1)return n.push([t,e]),this.size=++r.size,this;r=this.__data__=new Za(n)}return r.set(t,e),this.size=r.size,this}var es=ts,rs=Z,ns=Ba,is=Ka,as=Va,ss=Ja,os=es;function D(t){var e=this.__data__=new rs(t);this.size=e.size}D.prototype.clear=ns,D.prototype.delete=is,D.prototype.get=as,D.prototype.has=ss,D.prototype.set=os;var cs=D;function us(t,e){for(var r=-1,n=t==null?0:t.length;++r<n&&e(t[r],r,t)!==!1;);return t}var ls=us,fs=C,gs=function(){try{var t=fs(Object,"defineProperty");return t({},"",{}),t}catch{}}(),ds=gs,ie=ds;function _s(t,e,r){e=="__proto__"&&ie?ie(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}var ae=_s,ps=ae,hs=Ut,ys=Object.prototype,bs=ys.hasOwnProperty;function vs(t,e,r){var n=t[e];(!(bs.call(t,e)&&hs(n,r))||r===void 0&&!(e in t))&&ps(t,e,r)}var se=vs,$s=se,ms=ae;function Ss(t,e,r,n){var i=!r;r||(r={});for(var a=-1,s=e.length;++a<s;){var u=e[a],c=n?n(r[u],t[u],u,r,t):void 0;c===void 0&&(c=t[u]),i?ms(r,u,c):$s(r,u,c)}return r}var et=Ss;function ws(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}var Ts=ws,rt={exports:{}};function As(){return!1}var Os=As;(function(t,e){var r=w,n=Os,i=e&&!e.nodeType&&e,a=i&&!0&&t&&!t.nodeType&&t,s=a&&a.exports===i,u=s?r.Buffer:void 0,c=u?u.isBuffer:void 0,o=c||n;t.exports=o})(rt,rt.exports);var Cs=U,js=ut,Is=I,Ps="[object Arguments]",Es="[object Array]",Ms="[object Boolean]",xs="[object Date]",Ds="[object Error]",zs="[object Function]",Fs="[object Map]",Ls="[object Number]",Ns="[object Object]",Rs="[object RegExp]",Gs="[object Set]",Us="[object String]",Hs="[object WeakMap]",Bs="[object ArrayBuffer]",ks="[object DataView]",Ks="[object Float32Array]",qs="[object Float64Array]",Vs="[object Int8Array]",Ws="[object Int16Array]",Js="[object Int32Array]",Ys="[object Uint8Array]",Xs="[object Uint8ClampedArray]",Zs="[object Uint16Array]",Qs="[object Uint32Array]",_={};_[Ks]=_[qs]=_[Vs]=_[Ws]=_[Js]=_[Ys]=_[Xs]=_[Zs]=_[Qs]=!0,_[Ps]=_[Es]=_[Bs]=_[Ms]=_[ks]=_[xs]=_[Ds]=_[zs]=_[Fs]=_[Ls]=_[Ns]=_[Rs]=_[Gs]=_[Us]=_[Hs]=!1;function to(t){return Is(t)&&js(t.length)&&!!_[Cs(t)]}var eo=to;function ro(t){return function(e){return t(e)}}var gt=ro,k={exports:{}};(function(t,e){var r=Mt,n=e&&!e.nodeType&&e,i=n&&!0&&t&&!t.nodeType&&t,a=i&&i.exports===n,s=a&&r.process,u=function(){try{var c=i&&i.require&&i.require("util").types;return c||s&&s.binding&&s.binding("util")}catch{}}();t.exports=u})(k,k.exports);var no=eo,io=gt,oe=k.exports,ce=oe&&oe.isTypedArray,ao=ce?io(ce):no,so=ao,oo=Ts,co=Xt,uo=O,lo=rt.exports,fo=Zt,go=so,_o=Object.prototype,po=_o.hasOwnProperty;function ho(t,e){var r=uo(t),n=!r&&co(t),i=!r&&!n&&lo(t),a=!r&&!n&&!i&&go(t),s=r||n||i||a,u=s?oo(t.length,String):[],c=u.length;for(var o in t)(e||po.call(t,o))&&!(s&&(o=="length"||i&&(o=="offset"||o=="parent")||a&&(o=="buffer"||o=="byteLength"||o=="byteOffset")||fo(o,c)))&&u.push(o);return u}var ue=ho,yo=Object.prototype;function bo(t){var e=t&&t.constructor,r=typeof e=="function"&&e.prototype||yo;return t===r}var dt=bo;function vo(t,e){return function(r){return t(e(r))}}var le=vo,$o=le,mo=$o(Object.keys,Object),So=mo,wo=dt,To=So,Ao=Object.prototype,Oo=Ao.hasOwnProperty;function Co(t){if(!wo(t))return To(t);var e=[];for(var r in Object(t))Oo.call(t,r)&&r!="constructor"&&e.push(r);return e}var jo=Co,Io=Lt,Po=ut;function Eo(t){return t!=null&&Po(t.length)&&!Io(t)}var fe=Eo,Mo=ue,xo=jo,Do=fe;function zo(t){return Do(t)?Mo(t):xo(t)}var _t=zo,Fo=et,Lo=_t;function No(t,e){return t&&Fo(e,Lo(e),t)}var Ro=No;function Go(t){var e=[];if(t!=null)for(var r in Object(t))e.push(r);return e}var Uo=Go,Ho=H,Bo=dt,ko=Uo,Ko=Object.prototype,qo=Ko.hasOwnProperty;function Vo(t){if(!Ho(t))return ko(t);var e=Bo(t),r=[];for(var n in t)n=="constructor"&&(e||!qo.call(t,n))||r.push(n);return r}var Wo=Vo,Jo=ue,Yo=Wo,Xo=fe;function Zo(t){return Xo(t)?Jo(t,!0):Yo(t)}var pt=Zo,Qo=et,tc=pt;function ec(t,e){return t&&Qo(e,tc(e),t)}var rc=ec,ht={exports:{}};(function(t,e){var r=w,n=e&&!e.nodeType&&e,i=n&&!0&&t&&!t.nodeType&&t,a=i&&i.exports===n,s=a?r.Buffer:void 0,u=s?s.allocUnsafe:void 0;function c(o,l){if(l)return o.slice();var f=o.length,p=u?u(f):new o.constructor(f);return o.copy(p),p}t.exports=c})(ht,ht.exports);function nc(t,e){var r=-1,n=t.length;for(e||(e=Array(n));++r<n;)e[r]=t[r];return e}var ic=nc;function ac(t,e){for(var r=-1,n=t==null?0:t.length,i=0,a=[];++r<n;){var s=t[r];e(s,r,t)&&(a[i++]=s)}return a}var sc=ac;function oc(){return[]}var ge=oc,cc=sc,uc=ge,lc=Object.prototype,fc=lc.propertyIsEnumerable,de=Object.getOwnPropertySymbols,gc=de?function(t){return t==null?[]:(t=Object(t),cc(de(t),function(e){return fc.call(t,e)}))}:uc,yt=gc,dc=et,_c=yt;function pc(t,e){return dc(t,_c(t),e)}var hc=pc;function yc(t,e){for(var r=-1,n=e.length,i=t.length;++r<n;)t[i+r]=e[r];return t}var _e=yc,bc=le,vc=bc(Object.getPrototypeOf,Object),pe=vc,$c=_e,mc=pe,Sc=yt,wc=ge,Tc=Object.getOwnPropertySymbols,Ac=Tc?function(t){for(var e=[];t;)$c(e,Sc(t)),t=mc(t);return e}:wc,he=Ac,Oc=et,Cc=he;function jc(t,e){return Oc(t,Cc(t),e)}var Ic=jc,Pc=_e,Ec=O;function Mc(t,e,r){var n=e(t);return Ec(t)?n:Pc(n,r(t))}var ye=Mc,xc=ye,Dc=yt,zc=_t;function Fc(t){return xc(t,zc,Dc)}var Lc=Fc,Nc=ye,Rc=he,Gc=pt;function Uc(t){return Nc(t,Gc,Rc)}var Hc=Uc,Bc=C,kc=w,Kc=Bc(kc,"DataView"),qc=Kc,Vc=C,Wc=w,Jc=Vc(Wc,"Promise"),Yc=Jc,Xc=C,Zc=w,Qc=Xc(Zc,"Set"),tu=Qc,eu=C,ru=w,nu=eu(ru,"WeakMap"),iu=nu,bt=qc,vt=ot,$t=Yc,mt=tu,St=iu,be=U,z=Rt,ve="[object Map]",au="[object Object]",$e="[object Promise]",me="[object Set]",Se="[object WeakMap]",we="[object DataView]",su=z(bt),ou=z(vt),cu=z($t),uu=z(mt),lu=z(St),j=be;(bt&&j(new bt(new ArrayBuffer(1)))!=we||vt&&j(new vt)!=ve||$t&&j($t.resolve())!=$e||mt&&j(new mt)!=me||St&&j(new St)!=Se)&&(j=function(t){var e=be(t),r=e==au?t.constructor:void 0,n=r?z(r):"";if(n)switch(n){case su:return we;case ou:return ve;case cu:return $e;case uu:return me;case lu:return Se}return e});var wt=j,fu=Object.prototype,gu=fu.hasOwnProperty;function du(t){var e=t.length,r=new t.constructor(e);return e&&typeof t[0]=="string"&&gu.call(t,"index")&&(r.index=t.index,r.input=t.input),r}var _u=du,pu=w,hu=pu.Uint8Array,yu=hu,Te=yu;function bu(t){var e=new t.constructor(t.byteLength);return new Te(e).set(new Te(t)),e}var Tt=bu,vu=Tt;function $u(t,e){var r=e?vu(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)}var mu=$u,Su=/\w*$/;function wu(t){var e=new t.constructor(t.source,Su.exec(t));return e.lastIndex=t.lastIndex,e}var Tu=wu,Ae=J,Oe=Ae?Ae.prototype:void 0,Ce=Oe?Oe.valueOf:void 0;function Au(t){return Ce?Object(Ce.call(t)):{}}var Ou=Au,Cu=Tt;function ju(t,e){var r=e?Cu(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}var Iu=ju,Pu=Tt,Eu=mu,Mu=Tu,xu=Ou,Du=Iu,zu="[object Boolean]",Fu="[object Date]",Lu="[object Map]",Nu="[object Number]",Ru="[object RegExp]",Gu="[object Set]",Uu="[object String]",Hu="[object Symbol]",Bu="[object ArrayBuffer]",ku="[object DataView]",Ku="[object Float32Array]",qu="[object Float64Array]",Vu="[object Int8Array]",Wu="[object Int16Array]",Ju="[object Int32Array]",Yu="[object Uint8Array]",Xu="[object Uint8ClampedArray]",Zu="[object Uint16Array]",Qu="[object Uint32Array]";function tl(t,e,r){var n=t.constructor;switch(e){case Bu:return Pu(t);case zu:case Fu:return new n(+t);case ku:return Eu(t,r);case Ku:case qu:case Vu:case Wu:case Ju:case Yu:case Xu:case Zu:case Qu:return Du(t,r);case Lu:return new n;case Nu:case Uu:return new n(t);case Ru:return Mu(t);case Gu:return new n;case Hu:return xu(t)}}var el=tl,rl=H,je=Object.create,nl=function(){function t(){}return function(e){if(!rl(e))return{};if(je)return je(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}}(),il=nl,al=il,sl=pe,ol=dt;function cl(t){return typeof t.constructor=="function"&&!ol(t)?al(sl(t)):{}}var ul=cl,ll=wt,fl=I,gl="[object Map]";function dl(t){return fl(t)&&ll(t)==gl}var _l=dl,pl=_l,hl=gt,Ie=k.exports,Pe=Ie&&Ie.isMap,yl=Pe?hl(Pe):pl,bl=yl,vl=wt,$l=I,ml="[object Set]";function Sl(t){return $l(t)&&vl(t)==ml}var wl=Sl,Tl=wl,Al=gt,Ee=k.exports,Me=Ee&&Ee.isSet,Ol=Me?Al(Me):Tl,Cl=Ol,jl=cs,Il=ls,Pl=se,El=Ro,Ml=rc,xl=ht.exports,Dl=ic,zl=hc,Fl=Ic,Ll=Lc,Nl=Hc,Rl=wt,Gl=_u,Ul=el,Hl=ul,Bl=O,kl=rt.exports,Kl=bl,ql=H,Vl=Cl,Wl=_t,Jl=pt,Yl=1,Xl=2,Zl=4,xe="[object Arguments]",Ql="[object Array]",tf="[object Boolean]",ef="[object Date]",rf="[object Error]",De="[object Function]",nf="[object GeneratorFunction]",af="[object Map]",sf="[object Number]",ze="[object Object]",of="[object RegExp]",cf="[object Set]",uf="[object String]",lf="[object Symbol]",ff="[object WeakMap]",gf="[object ArrayBuffer]",df="[object DataView]",_f="[object Float32Array]",pf="[object Float64Array]",hf="[object Int8Array]",yf="[object Int16Array]",bf="[object Int32Array]",vf="[object Uint8Array]",$f="[object Uint8ClampedArray]",mf="[object Uint16Array]",Sf="[object Uint32Array]",d={};d[xe]=d[Ql]=d[gf]=d[df]=d[tf]=d[ef]=d[_f]=d[pf]=d[hf]=d[yf]=d[bf]=d[af]=d[sf]=d[ze]=d[of]=d[cf]=d[uf]=d[lf]=d[vf]=d[$f]=d[mf]=d[Sf]=!0,d[rf]=d[De]=d[ff]=!1;function nt(t,e,r,n,i,a){var s,u=e&Yl,c=e&Xl,o=e&Zl;if(r&&(s=i?r(t,n,i,a):r(t)),s!==void 0)return s;if(!ql(t))return t;var l=Bl(t);if(l){if(s=Gl(t),!u)return Dl(t,s)}else{var f=Rl(t),p=f==De||f==nf;if(kl(t))return xl(t,u);if(f==ze||f==xe||p&&!i){if(s=c||p?{}:Hl(t),!u)return c?Fl(t,Ml(s,t)):zl(t,El(s,t))}else{if(!d[f])return i?t:{};s=Ul(t,f,u)}}a||(a=new jl);var T=a.get(t);if(T)return T;a.set(t,s),Vl(t)?t.forEach(function(m){s.add(nt(m,e,r,m,t,a))}):Kl(t)&&t.forEach(function(m,S){s.set(S,nt(m,e,r,S,t,a))});var R=o?c?Nl:Ll:c?Jl:Wl,A=l?void 0:R(t);return Il(A||t,function(m,S){A&&(S=m,m=t[S]),Pl(s,S,nt(m,e,r,S,t,a))}),s}var Fe=nt,wf=Fe,Tf=1,Af=4;function Of(t){return wf(t,Tf|Af)}var At=Of;let Cf=1,jf=null;class F{constructor(e=Cf,r=jf){g(this,"page");g(this,"limit");g(this,"term");g(this,"filters");g(this,"ids");g(this,"queries");g(this,"associations");g(this,"postFilter");g(this,"sortings");g(this,"aggregations");g(this,"grouping");g(this,"fields");g(this,"groupFields");g(this,"totalCountMode");g(this,"includes");this.page=e,this.limit=r,this.term=null,this.filters=[],this.includes=null,this.ids=[],this.queries=[],this.associations=[],this.postFilter=[],this.sortings=[],this.aggregations=[],this.grouping=[],this.groupFields=[],this.fields=[],this.totalCountMode=1}static fromCriteria(e){return At(e)}parse(){const e={};return this.ids.length>0&&(e.ids=this.ids.join("|")),this.page!==null&&(e.page=this.page),this.limit!==null&&(e.limit=this.limit),this.term!==null&&(e.term=this.term),this.queries.length>0&&(e.query=this.queries),this.filters.length>0&&(e.filter=this.filters),this.postFilter.length>0&&(e["post-filter"]=this.postFilter),this.sortings.length>0&&(e.sort=this.sortings),this.aggregations.length>0&&(e.aggregations=this.aggregations),this.groupFields.length>0&&(e.groupFields=this.groupFields),this.grouping.length>0&&(e.grouping=this.grouping),this.fields.length>0&&(e.fields=this.fields),this.associations.length>0&&(e.associations={},this.associations.forEach(r=>{!e.associations||(e.associations[r.association]=r.criteria.parse())})),this.includes!==null&&(e.includes=this.includes),this.totalCountMode!==null&&(e["total-count-mode"]=this.totalCountMode),e}setIds(e){return this.ids=e,this}setTotalCountMode(e){return typeof e!="number"&&(this.totalCountMode=null),this.totalCountMode=e<0||e>2?null:e,this}setPage(e){return this.page=e,this}setLimit(e){return this.limit=e,this}setTerm(e){return this.term=e,this}addFilter(e){return this.filters.push(e),this}addIncludes(e){return Object.entries(e).forEach(([r,n])=>{this.includes===null&&(this.includes={}),this.includes[r]||(this.includes[r]=[]),this.includes[r].push(...n)}),this}addPostFilter(e){return this.postFilter.push(e),this}addSorting(e){return this.sortings.push(e),this}addQuery(e,r,n=null){const i={score:r,query:e};return n&&(i[n]=n),this.queries.push(i),this}addGroupField(e){return this.groupFields.push(e),this}addGrouping(e){return this.grouping.push(e),this}addFields(...e){return this.fields.push(...e),this}addAggregation(e){return this.aggregations.push(e),this}addAssociation(e){const r=e.split(".");let n=this;return r.forEach(i=>{n=n.getAssociation(i)}),this}getAssociation(e){const r=e.split(".");let n=this;return r.forEach(i=>{n.hasAssociation(i)||n.associations.push({association:i,criteria:new F(null,null)}),n=n.getAssociationCriteria(i)}),n}getAssociationCriteria(e){let r=null;return this.associations.forEach(n=>{n.association===e&&(r=n.criteria)}),r}getLimit(){var e;return(e=this.limit)!=null?e:0}getPage(){var e;return(e=this.page)!=null?e:0}getCriteriaData(){return{page:this.page,limit:this.limit,term:this.term,filters:this.filters,ids:this.ids,queries:this.queries,associations:this.associations,postFilter:this.postFilter,sortings:this.sortings,aggregations:this.aggregations,grouping:this.grouping,fields:this.fields,groupFields:this.groupFields,totalCountMode:this.totalCountMode,includes:this.includes}}hasAssociation(e){return this.associations.some(r=>r.association===e)}resetSorting(){this.sortings=[]}static avg(e,r){return{type:"avg",name:e,field:r}}static count(e,r){return{type:"count",name:e,field:r}}static max(e,r){return{type:"max",name:e,field:r}}static min(e,r){return{type:"min",name:e,field:r}}static stats(e,r){return{type:"stats",name:e,field:r}}static sum(e,r){return{type:"sum",name:e,field:r}}static terms(e,r,n=null,i=null,a=null){return{type:"terms",name:e,field:r,limit:n,sort:i,aggregation:a}}static filter(e,r,n){return{type:"filter",name:e,filter:r,aggregation:n}}static histogram(e,r,n,i,a,s){return{type:"histogram",name:e,field:r,interval:n,format:i,aggregation:a,timeZone:s}}static sort(e,r="ASC",n=!1){return{field:e,order:r,naturalSorting:n}}static naturalSorting(e,r="ASC"){return{field:e,order:r,naturalSorting:!0}}static contains(e,r){return{type:"contains",field:e,value:r}}static prefix(e,r){return{type:"prefix",field:e,value:r}}static suffix(e,r){return{type:"suffix",field:e,value:r}}static equalsAny(e,r){return{type:"equalsAny",field:e,value:r.join("|")}}static range(e,r){return{type:"range",field:e,parameters:r}}static equals(e,r){return{type:"equals",field:e,value:r}}static not(e,r=[]){return{type:"not",operator:e,queries:r}}static multi(e,r=[]){return{type:"multi",operator:e,queries:r}}}const If=()=>({name:"criteria",serialize:({value:t,customizerMethod:e})=>{if(t instanceof F)return{__type__:"__Criteria__",data:e(t.getCriteriaData())}},deserialize:({value:t,customizerMethod:e})=>{if(B("__Criteria__",t)&&typeof t.data=="object"){const r=t.data,n=new F;return n.setPage(r.page),n.setLimit(r.limit),n.setTerm(r.term),r.filters.forEach(i=>{n.addFilter(i)}),n.setIds(r.ids),r.queries.forEach(({query:i,score:a})=>{n.addQuery(i,a)}),r.associations.forEach(i=>{n.associations.push(e(i))}),r.postFilter.forEach(i=>{n.addPostFilter(i)}),r.sortings.forEach(i=>{n.addSorting(i)}),r.aggregations.forEach(i=>{n.addAggregation(i)}),r.grouping.forEach(i=>{n.addGrouping(i)}),r.fields.forEach(i=>{n.addFields(i)}),r.groupFields.forEach(i=>{n.addGroupField(i)}),r.includes&&n.addIncludes(r.includes),n.setTotalCountMode(r.totalCountMode),n}}});let Pf=(t,e,r)=>{t[e]=r};class Ef{constructor(e,r,n,i={}){g(this,"id");g(this,"_origin");g(this,"_entityName");g(this,"_draft");g(this,"_isDirty");g(this,"_isNew");var s,u;this.id=e,this._origin=i.originData?At(i.originData):At(n),this._entityName=r,this._draft=n,this._isDirty=(s=i.isDirty)!=null?s:!1,this._isNew=(u=i.isNew)!=null?u:!1;const a=this;return new Proxy(this._draft,{get(c,o){return o in a._draft?a._draft[o]:a[o]},set(c,o,l){return Pf(a._draft,o,l),a._isDirty=!0,!0}})}markAsNew(){this._isNew=!0}isNew(){return this._isNew}getIsDirty(){return this._isDirty}getOrigin(){return this._origin}getDraft(){return this._draft}getEntityName(){return this._entityName}}const Le=function(e,r,n,i){return new Ef(e,r,n,i)},Mf=()=>({name:"entity",serialize:({value:t,customizerMethod:e})=>{if(!(!tt(t)||typeof t.getDraft!="function"))return{__type__:"__Entity__",__id__:t.id,__entityName__:t._entityName,__isDirty__:t._isDirty,__isNew__:t._isNew,__origin__:e(t._origin),__draft__:e(t._draft)}},deserialize:({value:t,customizerMethod:e})=>{if(B("__Entity__",t)&&typeof t.__origin__=="object")return new Le(t.__id__,t.__entityName__,e(t.__draft__),{originData:e(t.__origin__),isDirty:t.__isDirty__,isNew:t.__isNew__})}});class L extends Array{constructor(e,r,n,i=null,a=[],s=null,u=null){super();g(this,"entity");g(this,"source");g(this,"context");g(this,"criteria");g(this,"aggregations");g(this,"total");g(this,"first");g(this,"last");g(this,"remove");g(this,"has");g(this,"get");g(this,"getAt");g(this,"getIds");g(this,"add");g(this,"addAt");g(this,"moveItem");this.entity=r,this.source=e,this.context=n,this.criteria=i,this.aggregations=u,this.total=s,this.push(...a),this.first=function(){return this.length<=0?null:this[0]},this.last=function(){return this.length<=0?null:this[this.length-1]},this.remove=function(o){const l=this.findIndex(f=>f.id===o);return l<0?!1:(this.splice(l,1),!0)},this.has=function(o){return this.some(l=>l.id===o)},this.get=function(o){const l=this.find(f=>f.id===o);return typeof l!="undefined"?l:null},this.getAt=function(o){const l=this[o];return typeof l!="undefined"?l:null},this.getIds=function(){return this.map(o=>o.id)},this.add=function(o){this.push(o)},this.addAt=function(o,l){if(typeof l=="undefined"){this.add(o);return}this.splice(l,0,o)},this.moveItem=function(o,l=null){if(l===null&&(l=this.length),o<0||o>=this.length)return null;if(l===o)return this.getAt(o);const f=this.find((R,A)=>A===o);if(typeof f=="undefined")return null;const p=this.filter((R,A)=>A!==o),T=[...p.slice(0,l),f,...p.slice(l)];return this.splice(0,this.length,...T),f},this.filter=function(o,l){const f=Object.getPrototypeOf(this).filter.call(this,o,l);return new L(this.source,this.entity,this.context,this.criteria,f,this.total,this.aggregations)}}static fromCollection(e){return new L(e.source,e.entity,e.context,e.criteria===null?e.criteria:F.fromCriteria(e.criteria),e,e.total,e.aggregations)}}const xf=()=>({name:"entity-collection",serialize:({value:t,customizerMethod:e})=>{if(t instanceof L)return e({__type__:"__EntityCollection__",__source__:t.source,__entityName__:t.entity,__context__:t.context,__criteria__:t.criteria,__entities__:Array.from(t),__total__:t.total,__aggregations__:t.aggregations})},deserialize:({value:t,customizerMethod:e})=>{if(B("__EntityCollection__",t))return new L(t.__source__,t.__entityName__,t.__context__,e(t.__criteria__),e(t.__entities__),t.__total__,t.__aggregations__)}});class K extends Error{constructor(e,r){super(e);g(this,"code",500);!r||(this.code=r)}toJSON(){return{__type__:"__HandleError__",__code__:this.code,__message__:this.message}}}const Df=()=>({name:"handle-error",serialize:()=>{},deserialize:({value:t})=>{if(B("__HandleError__",t))return new K(t.__message__,t.__code__)}});var zf=Fe,Ff=1,Lf=4;function Nf(t,e){return e=typeof e=="function"?e:void 0,zf(t,Ff|Lf,e)}var Ne=Nf;const Rf=[If,xf,Mf,Ga,Df,()=>({name:"handle-error",serialize:()=>{},deserialize:({value:t})=>{if(B("__MissingPrivilegesError__",t))return new x(t.__messageType__,t.__data__)}})];function Gf(t){const e=Rf.map(s=>s(t));function r(){return e}function n(s){var u;return(u=e.find(c=>c.name===s))!=null?u:null}function i(s){return Ne(s,(u,c,o,l)=>{for(const f of e){const p=f.serialize({value:u,key:c,object:o,stack:l,customizerMethod:i});if(p)return p}})}function a(s,u){return Ne(s,(c,o,l,f)=>{for(const p of e){const T=p.deserialize({value:c,key:o,object:l,stack:f,event:u,customizerMethod:a});if(T)return T}})}return{getSerializers:r,getSerializerByName:n,serialize:i,deserialize:a}}function Uf(t,e){if(typeof e=="string")return new K(e);if(!(e instanceof Error))return new K("An unknown error occurred.");if(Fa(e,"response.data.errors.0.code")&&e.response.data.errors.length){const r=e.response.data.errors.filter(i=>i.code==="FRAMEWORK__MISSING_PRIVILEGE_ERROR"),n=[];return r.forEach(i=>{const a=JSON.parse(i.detail);n.push(...a.missingPrivileges)}),n.length?new x(t,n):new K(e.response.data.errors[0].code,e.response.data.errors[0].status)}return new K(e.message)}function Ot({serializedData:t,origin:e,type:r,privilegesToCheck:n=[]}){const i=ne(e);if(!i)return null;const a=[];return te(t,(s,u,c)=>{if(u==="__type__"&&["__EntityCollection__","__Entity__"].includes(c)){const o=s.__entityName__;[...n].sort().forEach(l=>{const f=i.permissions[l];(!f||!f.includes(o))&&a.push(`${l}:${o}`)})}}),a.length>0?new x(r,a):null}const{serialize:q,deserialize:Re}=Gf({handle:N,send:$});let Ge={};const Ct=new Set;function $(t,e,r,n){const i=La(t);if(i!==null){const p=new x(t,i);return Promise.reject(p)}const a=Qt(),s=e!=null?e:{};let c=q({_type:t,_data:s,_callbackId:a});if(n){const p=Ot({serializedData:c,origin:n,privilegesToCheck:["read"],type:t});p&&(["datasetSubscribe","datasetUpdate","datasetRegistration","datasetGet"].includes(c._type)?c=q({_type:c._type,_callbackId:c._callbackId,_data:{id:c._data.id,data:p}}):c=q({_type:c._type,_callbackId:c._callbackId,_data:p}))}const o=JSON.stringify(c);let l=!1;const f=7e3;return new Promise((p,T)=>{const R=function(S){if(typeof S.data!="string")return;let W;try{W=JSON.parse(S.data)}catch{return}if(!Kf(W)||W._callbackId!==a||!W.hasOwnProperty("_response"))return;const Lg=Re(W,S);if(window.removeEventListener("message",R),!l){l=!0;const It=Lg._response;if(It instanceof Error){T(It);return}p(It)}};window.addEventListener("message",R);let A=!0;try{A=!window.parent.origin}catch{}let m=A?document.referrer:window.parent.origin;n&&(m=n),r?r.postMessage(o,m):window.parent.postMessage(o,m),setTimeout(()=>{l||T("Send timeout expired. It could be possible that no handler for the postMessage request exists or that the handler freezed.")},f)})}function N(t,e){const r=async function(n){var l;if(ft[t]&&Object.keys(ft[t]).length&&(!Ge||Na(t,n.origin)!==null)||typeof n.data!="string")return;let i;try{i=JSON.parse(n.data)}catch{return}if(!kf(i)||i._type!==t)return;const a=Re(i,n),s=await Promise.resolve((()=>{const f=Ot({serializedData:i,origin:n.origin,type:t,privilegesToCheck:["create","delete","update","read"]});return f||e(a._data,{_event_:n})})()).catch(f=>Uf(t,f)),u={_callbackId:a._callbackId,_type:a._type,_response:s!=null?s:null},c=(()=>{let f=q(u);const p=Ot({serializedData:f,origin:n.origin,privilegesToCheck:["read"],type:t});return p&&(f._response=p,f=q(f)),f})(),o=JSON.stringify(c);n.source?n.source.postMessage(o,{targetOrigin:(l=n.origin)!=null?l:"*"}):window.postMessage(o,window.origin)};return window.addEventListener("message",r),()=>window.removeEventListener("message",r)}function Hf(t,e){[...Ct].forEach(({source:r,origin:n})=>$(t,e,r,n).catch(()=>{}))}function jt(t,e){return N(t,e)}function y(t,e){return r=>$(t,Et(Et({},e),r))}function Bf(t){return e=>N(t,e)}function Ue(t){return(e,r)=>r?jt(t,i=>{i.id===r&&e(i)}):jt(t,e)}const it=new Map;(async()=>{N("__registerWindow__",(t,e)=>{let r,n;e._event_.source?(r=e._event_.source,n=e._event_.origin):(r=window,n=window.origin),Ct.add({source:r,origin:n}),it.forEach((i,a)=>{$("datasetSubscribe",{id:a,data:i},r,n).catch(()=>{})})}),N("datasetRegistration",t=>(it.set(t.id,t.data),Hf("datasetSubscribe",t),{id:t.id,data:t.data})),N("datasetSubscribe",t=>{var e;return(e=it.get(t.id))!=null?e:null}),await $("__registerWindow__",{})})().catch(t=>console.error(t)),window._swsdk={sourceRegistry:Ct,datasets:it};function kf(t){const e=t;return!!e._type&&!!e._data&&!!e._callbackId}function Kf(t){const e=t;return!!e._type&&!!e.hasOwnProperty("_response")&&!!e._callbackId}const qf=y("windowRedirect"),Vf=y("windowRouterPush"),Wf=y("windowReload",{});var Jf=Object.freeze(Object.defineProperty({__proto__:null,redirect:qf,routerPush:Vf,reload:Wf},Symbol.toStringTag,{value:"Module"}));const Yf=y("notificationDispatch");var Xf=Object.freeze(Object.defineProperty({__proto__:null,dispatch:Yf},Symbol.toStringTag,{value:"Module"}));const Zf=y("contextLanguage",{}),Qf=Ue("contextLanguage"),tg=y("contextEnvironment",{}),eg=y("contextLocale",{}),rg=Ue("contextLocale"),ng=y("contextCurrency",{}),ig=y("contextShopwareVersion",{}),ag=y("contextAppInformation",{}),sg=y("contextModuleInformation",{});var og=Object.freeze(Object.defineProperty({__proto__:null,getLanguage:Zf,subscribeLanguage:Qf,getEnvironment:tg,getLocale:eg,subscribeLocale:rg,getCurrency:ng,getShopwareVersion:ig,getAppInformation:ag,getModuleInformation:sg},Symbol.toStringTag,{value:"Module"}));const cg=y("uiComponentSectionRenderer",{src:(ke=za())!=null?ke:void 0});var ug=Object.freeze(Object.defineProperty({__proto__:null,add:cg},Symbol.toStringTag,{value:"Module"})),lg=t=>({addTabItem:y("uiTabsAddTabItem",{positionId:t})});const fg=t=>lt()===t,gg=()=>window!==window.parent,He=t=>{if(t)return $("locationUpdateHeight",{height:t,locationId:lt()});const e=document.documentElement.offsetHeight;return $("locationUpdateHeight",{height:e,locationId:lt()})};let V=null;var dg=Object.freeze(Object.defineProperty({__proto__:null,is:fg,isIframe:gg,updateHeight:He,startAutoResizer:()=>{V=new ResizeObserver(()=>{He()}),V.observe(document.body)},stopAutoResizer:()=>{V&&(V.unobserve(document.body),V.disconnect())},MAIN_HIDDEN:"sw-main-hidden"},Symbol.toStringTag,{value:"Module"}));const _g=y("menuItemAdd");var pg=Object.freeze(Object.defineProperty({__proto__:null,addMenuItem:_g},Symbol.toStringTag,{value:"Module"}));const hg=y("settingsItemAdd");var yg=Object.freeze(Object.defineProperty({__proto__:null,addSettingsItem:hg},Symbol.toStringTag,{value:"Module"}));const bg=y("mainModuleAdd");var vg=Object.freeze(Object.defineProperty({__proto__:null,addMainModule:bg},Symbol.toStringTag,{value:"Module"}));const $g=y("uiModalOpen"),mg=y("uiModalClose");var Sg=Object.freeze(Object.defineProperty({__proto__:null,open:$g,close:mg},Symbol.toStringTag,{value:"Module"}));const wg=y("actionButtonAdd");var Tg=Object.freeze(Object.defineProperty({__proto__:null,add:wg},Symbol.toStringTag,{value:"Module"}));const Ag=y("actionExecute");var Og=Object.freeze(Object.defineProperty({__proto__:null,actionExecute:Ag},Symbol.toStringTag,{value:"Module"})),Cg=t=>({search:(e,r)=>$("repositorySearch",{entityName:t,context:r,criteria:e}),get:(e,r,n)=>$("repositoryGet",{entityName:t,id:e,context:r,criteria:n}),save:(e,r)=>$("repositorySave",{entityName:t,entity:e,context:r}),clone:(e,r,n)=>$("repositoryClone",{entityName:t,entityId:e,context:r,behavior:n}),hasChanges:e=>$("repositoryHasChanges",{entityName:t,entity:e}),saveAll:(e,r)=>$("repositorySaveAll",{entityName:t,entities:e,context:r}),delete:(e,r)=>$("repositoryDelete",{entityName:t,entityId:e,context:r}),create:(e,r)=>$("repositoryCreate",{entityName:t,entityId:r,context:e})});function Be(t){return(e,r)=>jt(t,i=>{if(i&&i.id===e){const a=r(i);a&&a.catch(()=>{})}})}const jg=Be("datasetSubscribe"),Ig=y("datasetGet"),Pg=y("datasetUpdate"),Eg=y("datasetRegistration"),Mg=Be("datasetUpdate"),xg=Bf("datasetGet");var Dg=Object.freeze(Object.defineProperty({__proto__:null,subscribe:jg,get:Ig,update:Pg,register:Eg,updateSubscriber:Mg,handleGet:xg,repository:Cg,Classes:{Criteria:F,Entity:Le,EntityCollection:L}},Symbol.toStringTag,{value:"Module"}));const zg={webhook:Og},Fg={componentSection:ug,tabs:lg,menu:pg,settings:yg,mainModule:vg,modal:Sg,actionButton:Tg};b.app=zg,b.context=og,b.data=Dg,b.location=dg,b.notification=Xf,b.ui=Fg,b.window=Jf,Object.defineProperties(b,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}); | ||
var Gg=Object.defineProperty;var Ke=Object.getOwnPropertySymbols;var Ug=Object.prototype.hasOwnProperty,Hg=Object.prototype.propertyIsEnumerable;var Et=(y,b,v)=>b in y?Gg(y,b,{enumerable:!0,configurable:!0,writable:!0,value:v}):y[b]=v,Pt=(y,b)=>{for(var v in b||(b={}))Ug.call(b,v)&&Et(y,v,b[v]);if(Ke)for(var v of Ke(b))Hg.call(b,v)&&Et(y,v,b[v]);return y};var g=(y,b,v)=>(Et(y,typeof b!="symbol"?b+"":b,v),v);(function(y,b){typeof exports=="object"&&typeof module!="undefined"?b(exports):typeof define=="function"&&define.amd?define(["exports"],b):(y=typeof globalThis!="undefined"?globalThis:y||self,b(y.sw={}))})(this,function(y){var ke;"use strict";var b=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{},v=Object.prototype,qe=v.hasOwnProperty;function Ve(t,e){return t!=null&&qe.call(t,e)}var We=Ve,Je=Array.isArray,O=Je,Ye=typeof b=="object"&&b&&b.Object===Object&&b,Mt=Ye,Xe=Mt,Ze=typeof self=="object"&&self&&self.Object===Object&&self,Qe=Xe||Ze||Function("return this")(),w=Qe,tr=w,er=tr.Symbol,J=er,xt=J,Dt=Object.prototype,rr=Dt.hasOwnProperty,nr=Dt.toString,G=xt?xt.toStringTag:void 0;function ir(t){var e=rr.call(t,G),r=t[G];try{t[G]=void 0;var n=!0}catch{}var i=nr.call(t);return n&&(e?t[G]=r:delete t[G]),i}var ar=ir,sr=Object.prototype,or=sr.toString;function cr(t){return or.call(t)}var ur=cr,zt=J,lr=ar,fr=ur,gr="[object Null]",dr="[object Undefined]",Ft=zt?zt.toStringTag:void 0;function _r(t){return t==null?t===void 0?dr:gr:Ft&&Ft in Object(t)?lr(t):fr(t)}var U=_r;function pr(t){return t!=null&&typeof t=="object"}var I=pr,hr=U,yr=I,br="[object Symbol]";function vr(t){return typeof t=="symbol"||yr(t)&&hr(t)==br}var at=vr,$r=O,mr=at,Sr=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,wr=/^\w*$/;function Tr(t,e){if($r(t))return!1;var r=typeof t;return r=="number"||r=="symbol"||r=="boolean"||t==null||mr(t)?!0:wr.test(t)||!Sr.test(t)||e!=null&&t in Object(e)}var Ar=Tr;function Or(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}var H=Or,Cr=U,jr=H,Ir="[object AsyncFunction]",Er="[object Function]",Pr="[object GeneratorFunction]",Mr="[object Proxy]";function xr(t){if(!jr(t))return!1;var e=Cr(t);return e==Er||e==Pr||e==Ir||e==Mr}var Lt=xr,Dr=w,zr=Dr["__core-js_shared__"],Fr=zr,st=Fr,Nt=function(){var t=/[^.]+$/.exec(st&&st.keys&&st.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function Lr(t){return!!Nt&&Nt in t}var Nr=Lr,Rr=Function.prototype,Gr=Rr.toString;function Ur(t){if(t!=null){try{return Gr.call(t)}catch{}try{return t+""}catch{}}return""}var Rt=Ur,Hr=Lt,Br=Nr,kr=H,Kr=Rt,qr=/[\\^$.*+?()[\]{}|]/g,Vr=/^\[object .+?Constructor\]$/,Wr=Function.prototype,Jr=Object.prototype,Yr=Wr.toString,Xr=Jr.hasOwnProperty,Zr=RegExp("^"+Yr.call(Xr).replace(qr,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Qr(t){if(!kr(t)||Br(t))return!1;var e=Hr(t)?Zr:Vr;return e.test(Kr(t))}var tn=Qr;function en(t,e){return t==null?void 0:t[e]}var rn=en,nn=tn,an=rn;function sn(t,e){var r=an(t,e);return nn(r)?r:void 0}var C=sn,on=C,cn=on(Object,"create"),Y=cn,Gt=Y;function un(){this.__data__=Gt?Gt(null):{},this.size=0}var ln=un;function fn(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var gn=fn,dn=Y,_n="__lodash_hash_undefined__",pn=Object.prototype,hn=pn.hasOwnProperty;function yn(t){var e=this.__data__;if(dn){var r=e[t];return r===_n?void 0:r}return hn.call(e,t)?e[t]:void 0}var bn=yn,vn=Y,$n=Object.prototype,mn=$n.hasOwnProperty;function Sn(t){var e=this.__data__;return vn?e[t]!==void 0:mn.call(e,t)}var wn=Sn,Tn=Y,An="__lodash_hash_undefined__";function On(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=Tn&&e===void 0?An:e,this}var Cn=On,jn=ln,In=gn,En=bn,Pn=wn,Mn=Cn;function E(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}E.prototype.clear=jn,E.prototype.delete=In,E.prototype.get=En,E.prototype.has=Pn,E.prototype.set=Mn;var xn=E;function Dn(){this.__data__=[],this.size=0}var zn=Dn;function Fn(t,e){return t===e||t!==t&&e!==e}var Ut=Fn,Ln=Ut;function Nn(t,e){for(var r=t.length;r--;)if(Ln(t[r][0],e))return r;return-1}var X=Nn,Rn=X,Gn=Array.prototype,Un=Gn.splice;function Hn(t){var e=this.__data__,r=Rn(e,t);if(r<0)return!1;var n=e.length-1;return r==n?e.pop():Un.call(e,r,1),--this.size,!0}var Bn=Hn,kn=X;function Kn(t){var e=this.__data__,r=kn(e,t);return r<0?void 0:e[r][1]}var qn=Kn,Vn=X;function Wn(t){return Vn(this.__data__,t)>-1}var Jn=Wn,Yn=X;function Xn(t,e){var r=this.__data__,n=Yn(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this}var Zn=Xn,Qn=zn,ti=Bn,ei=qn,ri=Jn,ni=Zn;function P(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}P.prototype.clear=Qn,P.prototype.delete=ti,P.prototype.get=ei,P.prototype.has=ri,P.prototype.set=ni;var Z=P,ii=C,ai=w,si=ii(ai,"Map"),ot=si,Ht=xn,oi=Z,ci=ot;function ui(){this.size=0,this.__data__={hash:new Ht,map:new(ci||oi),string:new Ht}}var li=ui;function fi(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}var gi=fi,di=gi;function _i(t,e){var r=t.__data__;return di(e)?r[typeof e=="string"?"string":"hash"]:r.map}var Q=_i,pi=Q;function hi(t){var e=pi(this,t).delete(t);return this.size-=e?1:0,e}var yi=hi,bi=Q;function vi(t){return bi(this,t).get(t)}var $i=vi,mi=Q;function Si(t){return mi(this,t).has(t)}var wi=Si,Ti=Q;function Ai(t,e){var r=Ti(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this}var Oi=Ai,Ci=li,ji=yi,Ii=$i,Ei=wi,Pi=Oi;function M(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}M.prototype.clear=Ci,M.prototype.delete=ji,M.prototype.get=Ii,M.prototype.has=Ei,M.prototype.set=Pi;var Bt=M,kt=Bt,Mi="Expected a function";function ct(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(Mi);var r=function(){var n=arguments,i=e?e.apply(this,n):n[0],a=r.cache;if(a.has(i))return a.get(i);var s=t.apply(this,n);return r.cache=a.set(i,s)||a,s};return r.cache=new(ct.Cache||kt),r}ct.Cache=kt;var xi=ct,Di=xi,zi=500;function Fi(t){var e=Di(t,function(n){return r.size===zi&&r.clear(),n}),r=e.cache;return e}var Li=Fi,Ni=Li,Ri=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Gi=/\\(\\)?/g,Ui=Ni(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(Ri,function(r,n,i,a){e.push(i?a.replace(Gi,"$1"):n||r)}),e}),Hi=Ui;function Bi(t,e){for(var r=-1,n=t==null?0:t.length,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i}var ki=Bi,Kt=J,Ki=ki,qi=O,Vi=at,Wi=1/0,qt=Kt?Kt.prototype:void 0,Vt=qt?qt.toString:void 0;function Wt(t){if(typeof t=="string")return t;if(qi(t))return Ki(t,Wt)+"";if(Vi(t))return Vt?Vt.call(t):"";var e=t+"";return e=="0"&&1/t==-Wi?"-0":e}var Ji=Wt,Yi=Ji;function Xi(t){return t==null?"":Yi(t)}var Zi=Xi,Qi=O,ta=Ar,ea=Hi,ra=Zi;function na(t,e){return Qi(t)?t:ta(t,e)?[t]:ea(ra(t))}var ia=na,aa=U,sa=I,oa="[object Arguments]";function ca(t){return sa(t)&&aa(t)==oa}var ua=ca,Jt=ua,la=I,Yt=Object.prototype,fa=Yt.hasOwnProperty,ga=Yt.propertyIsEnumerable,da=Jt(function(){return arguments}())?Jt:function(t){return la(t)&&fa.call(t,"callee")&&!ga.call(t,"callee")},Xt=da,_a=9007199254740991,pa=/^(?:0|[1-9]\d*)$/;function ha(t,e){var r=typeof t;return e=e==null?_a:e,!!e&&(r=="number"||r!="symbol"&&pa.test(t))&&t>-1&&t%1==0&&t<e}var Zt=ha,ya=9007199254740991;function ba(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=ya}var ut=ba,va=at,$a=1/0;function ma(t){if(typeof t=="string"||va(t))return t;var e=t+"";return e=="0"&&1/t==-$a?"-0":e}var Sa=ma,wa=ia,Ta=Xt,Aa=O,Oa=Zt,Ca=ut,ja=Sa;function Ia(t,e,r){e=wa(e,t);for(var n=-1,i=e.length,a=!1;++n<i;){var s=ja(e[n]);if(!(a=t!=null&&r(t,s)))break;t=t[s]}return a||++n!=i?a:(i=t==null?0:t.length,!!i&&Ca(i)&&Oa(s,i)&&(Aa(t)||Ta(t)))}var Ea=Ia,Pa=We,Ma=Ea;function xa(t,e){return t!=null&&Ma(t,e,Pa)}var Da=xa;function Qt(){return String(Date.now().toString(36)+Math.random().toString(36).substr(2))}function tt(t){return t!==null&&typeof t=="object"}function lt(){return new URLSearchParams(window.location.search).get("location-id")}function za(){const t=window.location;return new URL(t.pathname,t.origin).toString()}function B(t,e){return tt(e)&&e.__type__&&e.__type__===t}function Fa(t,e){return Da(t,e)}function te(t,e){for(let r in t){const n=t[r];e.apply(this,[t,r,n]),tt(n)&&te(n,e)}}const ft={notificationDispatch:{},windowRedirect:{},windowReload:{},contextLanguage:{},contextEnvironment:{},contextLocale:{},contextCurrency:{},contextShopwareVersion:{},contextAppInformation:{},getPageTitle:{},uiComponentSectionRenderer:{},uiTabsAddTabItem:{},cmsRegisterElement:{},locationUpdateHeight:{},menuItemAdd:{},settingsItemAdd:{},mainModuleAdd:{},uiModalOpen:{},uiModalClose:{},actionButtonAdd:{},actionExecute:{},datasetRegistration:{},datasetSubscribe:{},datasetUpdate:{},__function__:{},__registerWindow__:{},_criteriaTest:{},_collectionTest:{},_multiply:{},_subtract:{},_privileges:{create:["user"],read:["user"],update:["user"],delete:["user"]}};function La(t){const e=ee(t),r=Ra(window.location);return!e||Object.keys(e).length<=0?null:re(e,r)}function Na(t,e){const r=ee(t),n=ne(e);return n?re(r,n.permissions):null}function ee(t){var e;return(e=ft[t])!=null?e:{}}function Ra(t){const r=new URLSearchParams(t.search).get("privileges");return r?JSON.parse(r):{}}function re(t,e){const r=Object.keys(t),n=[];return r.forEach(i=>{var a;(a=t[i])==null||a.forEach(s=>{var u;(u=e[i])!=null&&u.includes(s)||n.push(`${i}:${s}`)})}),n.length>=1?n:null}function ne(t){return Object.values(Ge).find(e=>e.baseUrl===t)}class x extends Error{constructor(e,r){super(`Your app is missing the privileges ${r.join(", ")} for action "${e}".`);g(this,"missingPrivileges");g(this,"messageType");this.missingPrivileges=r,this.messageType=e,Object.setPrototypeOf(this,x.prototype)}toJSON(){return{__type__:"__MissingPrivilegesError__",__messageType__:this.messageType,__data__:this.missingPrivileges}}}const Ga=({send:t,handle:e})=>{const r={};let n=!1;function i(){n||(n=!0,e("__function__",async({args:a,id:s})=>await Promise.resolve(r[s](...a))))}return{name:"function",serialize:({value:a})=>{if(typeof a=="function"){const s=Qt();return r[s]=a,i(),{__type__:"__function__",id:s,origin:window.origin}}},deserialize:({value:a,event:s})=>{var c;const u=(c=s==null?void 0:s.source)!=null?c:window;if(tt(a)&&a.__type__&&a.__type__==="__function__"&&typeof a.id=="string"){const o=a.id,l=a.origin;return(...f)=>t("__function__",{args:f,id:o},u,l)}}}};var Ua=Z;function Ha(){this.__data__=new Ua,this.size=0}var Ba=Ha;function ka(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}var Ka=ka;function qa(t){return this.__data__.get(t)}var Va=qa;function Wa(t){return this.__data__.has(t)}var Ja=Wa,Ya=Z,Xa=ot,Za=Bt,Qa=200;function ts(t,e){var r=this.__data__;if(r instanceof Ya){var n=r.__data__;if(!Xa||n.length<Qa-1)return n.push([t,e]),this.size=++r.size,this;r=this.__data__=new Za(n)}return r.set(t,e),this.size=r.size,this}var es=ts,rs=Z,ns=Ba,is=Ka,as=Va,ss=Ja,os=es;function D(t){var e=this.__data__=new rs(t);this.size=e.size}D.prototype.clear=ns,D.prototype.delete=is,D.prototype.get=as,D.prototype.has=ss,D.prototype.set=os;var cs=D;function us(t,e){for(var r=-1,n=t==null?0:t.length;++r<n&&e(t[r],r,t)!==!1;);return t}var ls=us,fs=C,gs=function(){try{var t=fs(Object,"defineProperty");return t({},"",{}),t}catch{}}(),ds=gs,ie=ds;function _s(t,e,r){e=="__proto__"&&ie?ie(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}var ae=_s,ps=ae,hs=Ut,ys=Object.prototype,bs=ys.hasOwnProperty;function vs(t,e,r){var n=t[e];(!(bs.call(t,e)&&hs(n,r))||r===void 0&&!(e in t))&&ps(t,e,r)}var se=vs,$s=se,ms=ae;function Ss(t,e,r,n){var i=!r;r||(r={});for(var a=-1,s=e.length;++a<s;){var u=e[a],c=n?n(r[u],t[u],u,r,t):void 0;c===void 0&&(c=t[u]),i?ms(r,u,c):$s(r,u,c)}return r}var et=Ss;function ws(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}var Ts=ws,rt={exports:{}};function As(){return!1}var Os=As;(function(t,e){var r=w,n=Os,i=e&&!e.nodeType&&e,a=i&&!0&&t&&!t.nodeType&&t,s=a&&a.exports===i,u=s?r.Buffer:void 0,c=u?u.isBuffer:void 0,o=c||n;t.exports=o})(rt,rt.exports);var Cs=U,js=ut,Is=I,Es="[object Arguments]",Ps="[object Array]",Ms="[object Boolean]",xs="[object Date]",Ds="[object Error]",zs="[object Function]",Fs="[object Map]",Ls="[object Number]",Ns="[object Object]",Rs="[object RegExp]",Gs="[object Set]",Us="[object String]",Hs="[object WeakMap]",Bs="[object ArrayBuffer]",ks="[object DataView]",Ks="[object Float32Array]",qs="[object Float64Array]",Vs="[object Int8Array]",Ws="[object Int16Array]",Js="[object Int32Array]",Ys="[object Uint8Array]",Xs="[object Uint8ClampedArray]",Zs="[object Uint16Array]",Qs="[object Uint32Array]",_={};_[Ks]=_[qs]=_[Vs]=_[Ws]=_[Js]=_[Ys]=_[Xs]=_[Zs]=_[Qs]=!0,_[Es]=_[Ps]=_[Bs]=_[Ms]=_[ks]=_[xs]=_[Ds]=_[zs]=_[Fs]=_[Ls]=_[Ns]=_[Rs]=_[Gs]=_[Us]=_[Hs]=!1;function to(t){return Is(t)&&js(t.length)&&!!_[Cs(t)]}var eo=to;function ro(t){return function(e){return t(e)}}var gt=ro,k={exports:{}};(function(t,e){var r=Mt,n=e&&!e.nodeType&&e,i=n&&!0&&t&&!t.nodeType&&t,a=i&&i.exports===n,s=a&&r.process,u=function(){try{var c=i&&i.require&&i.require("util").types;return c||s&&s.binding&&s.binding("util")}catch{}}();t.exports=u})(k,k.exports);var no=eo,io=gt,oe=k.exports,ce=oe&&oe.isTypedArray,ao=ce?io(ce):no,so=ao,oo=Ts,co=Xt,uo=O,lo=rt.exports,fo=Zt,go=so,_o=Object.prototype,po=_o.hasOwnProperty;function ho(t,e){var r=uo(t),n=!r&&co(t),i=!r&&!n&&lo(t),a=!r&&!n&&!i&&go(t),s=r||n||i||a,u=s?oo(t.length,String):[],c=u.length;for(var o in t)(e||po.call(t,o))&&!(s&&(o=="length"||i&&(o=="offset"||o=="parent")||a&&(o=="buffer"||o=="byteLength"||o=="byteOffset")||fo(o,c)))&&u.push(o);return u}var ue=ho,yo=Object.prototype;function bo(t){var e=t&&t.constructor,r=typeof e=="function"&&e.prototype||yo;return t===r}var dt=bo;function vo(t,e){return function(r){return t(e(r))}}var le=vo,$o=le,mo=$o(Object.keys,Object),So=mo,wo=dt,To=So,Ao=Object.prototype,Oo=Ao.hasOwnProperty;function Co(t){if(!wo(t))return To(t);var e=[];for(var r in Object(t))Oo.call(t,r)&&r!="constructor"&&e.push(r);return e}var jo=Co,Io=Lt,Eo=ut;function Po(t){return t!=null&&Eo(t.length)&&!Io(t)}var fe=Po,Mo=ue,xo=jo,Do=fe;function zo(t){return Do(t)?Mo(t):xo(t)}var _t=zo,Fo=et,Lo=_t;function No(t,e){return t&&Fo(e,Lo(e),t)}var Ro=No;function Go(t){var e=[];if(t!=null)for(var r in Object(t))e.push(r);return e}var Uo=Go,Ho=H,Bo=dt,ko=Uo,Ko=Object.prototype,qo=Ko.hasOwnProperty;function Vo(t){if(!Ho(t))return ko(t);var e=Bo(t),r=[];for(var n in t)n=="constructor"&&(e||!qo.call(t,n))||r.push(n);return r}var Wo=Vo,Jo=ue,Yo=Wo,Xo=fe;function Zo(t){return Xo(t)?Jo(t,!0):Yo(t)}var pt=Zo,Qo=et,tc=pt;function ec(t,e){return t&&Qo(e,tc(e),t)}var rc=ec,ht={exports:{}};(function(t,e){var r=w,n=e&&!e.nodeType&&e,i=n&&!0&&t&&!t.nodeType&&t,a=i&&i.exports===n,s=a?r.Buffer:void 0,u=s?s.allocUnsafe:void 0;function c(o,l){if(l)return o.slice();var f=o.length,h=u?u(f):new o.constructor(f);return o.copy(h),h}t.exports=c})(ht,ht.exports);function nc(t,e){var r=-1,n=t.length;for(e||(e=Array(n));++r<n;)e[r]=t[r];return e}var ic=nc;function ac(t,e){for(var r=-1,n=t==null?0:t.length,i=0,a=[];++r<n;){var s=t[r];e(s,r,t)&&(a[i++]=s)}return a}var sc=ac;function oc(){return[]}var ge=oc,cc=sc,uc=ge,lc=Object.prototype,fc=lc.propertyIsEnumerable,de=Object.getOwnPropertySymbols,gc=de?function(t){return t==null?[]:(t=Object(t),cc(de(t),function(e){return fc.call(t,e)}))}:uc,yt=gc,dc=et,_c=yt;function pc(t,e){return dc(t,_c(t),e)}var hc=pc;function yc(t,e){for(var r=-1,n=e.length,i=t.length;++r<n;)t[i+r]=e[r];return t}var _e=yc,bc=le,vc=bc(Object.getPrototypeOf,Object),pe=vc,$c=_e,mc=pe,Sc=yt,wc=ge,Tc=Object.getOwnPropertySymbols,Ac=Tc?function(t){for(var e=[];t;)$c(e,Sc(t)),t=mc(t);return e}:wc,he=Ac,Oc=et,Cc=he;function jc(t,e){return Oc(t,Cc(t),e)}var Ic=jc,Ec=_e,Pc=O;function Mc(t,e,r){var n=e(t);return Pc(t)?n:Ec(n,r(t))}var ye=Mc,xc=ye,Dc=yt,zc=_t;function Fc(t){return xc(t,zc,Dc)}var Lc=Fc,Nc=ye,Rc=he,Gc=pt;function Uc(t){return Nc(t,Gc,Rc)}var Hc=Uc,Bc=C,kc=w,Kc=Bc(kc,"DataView"),qc=Kc,Vc=C,Wc=w,Jc=Vc(Wc,"Promise"),Yc=Jc,Xc=C,Zc=w,Qc=Xc(Zc,"Set"),tu=Qc,eu=C,ru=w,nu=eu(ru,"WeakMap"),iu=nu,bt=qc,vt=ot,$t=Yc,mt=tu,St=iu,be=U,z=Rt,ve="[object Map]",au="[object Object]",$e="[object Promise]",me="[object Set]",Se="[object WeakMap]",we="[object DataView]",su=z(bt),ou=z(vt),cu=z($t),uu=z(mt),lu=z(St),j=be;(bt&&j(new bt(new ArrayBuffer(1)))!=we||vt&&j(new vt)!=ve||$t&&j($t.resolve())!=$e||mt&&j(new mt)!=me||St&&j(new St)!=Se)&&(j=function(t){var e=be(t),r=e==au?t.constructor:void 0,n=r?z(r):"";if(n)switch(n){case su:return we;case ou:return ve;case cu:return $e;case uu:return me;case lu:return Se}return e});var wt=j,fu=Object.prototype,gu=fu.hasOwnProperty;function du(t){var e=t.length,r=new t.constructor(e);return e&&typeof t[0]=="string"&&gu.call(t,"index")&&(r.index=t.index,r.input=t.input),r}var _u=du,pu=w,hu=pu.Uint8Array,yu=hu,Te=yu;function bu(t){var e=new t.constructor(t.byteLength);return new Te(e).set(new Te(t)),e}var Tt=bu,vu=Tt;function $u(t,e){var r=e?vu(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)}var mu=$u,Su=/\w*$/;function wu(t){var e=new t.constructor(t.source,Su.exec(t));return e.lastIndex=t.lastIndex,e}var Tu=wu,Ae=J,Oe=Ae?Ae.prototype:void 0,Ce=Oe?Oe.valueOf:void 0;function Au(t){return Ce?Object(Ce.call(t)):{}}var Ou=Au,Cu=Tt;function ju(t,e){var r=e?Cu(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}var Iu=ju,Eu=Tt,Pu=mu,Mu=Tu,xu=Ou,Du=Iu,zu="[object Boolean]",Fu="[object Date]",Lu="[object Map]",Nu="[object Number]",Ru="[object RegExp]",Gu="[object Set]",Uu="[object String]",Hu="[object Symbol]",Bu="[object ArrayBuffer]",ku="[object DataView]",Ku="[object Float32Array]",qu="[object Float64Array]",Vu="[object Int8Array]",Wu="[object Int16Array]",Ju="[object Int32Array]",Yu="[object Uint8Array]",Xu="[object Uint8ClampedArray]",Zu="[object Uint16Array]",Qu="[object Uint32Array]";function tl(t,e,r){var n=t.constructor;switch(e){case Bu:return Eu(t);case zu:case Fu:return new n(+t);case ku:return Pu(t,r);case Ku:case qu:case Vu:case Wu:case Ju:case Yu:case Xu:case Zu:case Qu:return Du(t,r);case Lu:return new n;case Nu:case Uu:return new n(t);case Ru:return Mu(t);case Gu:return new n;case Hu:return xu(t)}}var el=tl,rl=H,je=Object.create,nl=function(){function t(){}return function(e){if(!rl(e))return{};if(je)return je(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}}(),il=nl,al=il,sl=pe,ol=dt;function cl(t){return typeof t.constructor=="function"&&!ol(t)?al(sl(t)):{}}var ul=cl,ll=wt,fl=I,gl="[object Map]";function dl(t){return fl(t)&&ll(t)==gl}var _l=dl,pl=_l,hl=gt,Ie=k.exports,Ee=Ie&&Ie.isMap,yl=Ee?hl(Ee):pl,bl=yl,vl=wt,$l=I,ml="[object Set]";function Sl(t){return $l(t)&&vl(t)==ml}var wl=Sl,Tl=wl,Al=gt,Pe=k.exports,Me=Pe&&Pe.isSet,Ol=Me?Al(Me):Tl,Cl=Ol,jl=cs,Il=ls,El=se,Pl=Ro,Ml=rc,xl=ht.exports,Dl=ic,zl=hc,Fl=Ic,Ll=Lc,Nl=Hc,Rl=wt,Gl=_u,Ul=el,Hl=ul,Bl=O,kl=rt.exports,Kl=bl,ql=H,Vl=Cl,Wl=_t,Jl=pt,Yl=1,Xl=2,Zl=4,xe="[object Arguments]",Ql="[object Array]",tf="[object Boolean]",ef="[object Date]",rf="[object Error]",De="[object Function]",nf="[object GeneratorFunction]",af="[object Map]",sf="[object Number]",ze="[object Object]",of="[object RegExp]",cf="[object Set]",uf="[object String]",lf="[object Symbol]",ff="[object WeakMap]",gf="[object ArrayBuffer]",df="[object DataView]",_f="[object Float32Array]",pf="[object Float64Array]",hf="[object Int8Array]",yf="[object Int16Array]",bf="[object Int32Array]",vf="[object Uint8Array]",$f="[object Uint8ClampedArray]",mf="[object Uint16Array]",Sf="[object Uint32Array]",d={};d[xe]=d[Ql]=d[gf]=d[df]=d[tf]=d[ef]=d[_f]=d[pf]=d[hf]=d[yf]=d[bf]=d[af]=d[sf]=d[ze]=d[of]=d[cf]=d[uf]=d[lf]=d[vf]=d[$f]=d[mf]=d[Sf]=!0,d[rf]=d[De]=d[ff]=!1;function nt(t,e,r,n,i,a){var s,u=e&Yl,c=e&Xl,o=e&Zl;if(r&&(s=i?r(t,n,i,a):r(t)),s!==void 0)return s;if(!ql(t))return t;var l=Bl(t);if(l){if(s=Gl(t),!u)return Dl(t,s)}else{var f=Rl(t),h=f==De||f==nf;if(kl(t))return xl(t,u);if(f==ze||f==xe||h&&!i){if(s=c||h?{}:Hl(t),!u)return c?Fl(t,Ml(s,t)):zl(t,Pl(s,t))}else{if(!d[f])return i?t:{};s=Ul(t,f,u)}}a||(a=new jl);var T=a.get(t);if(T)return T;a.set(t,s),Vl(t)?t.forEach(function(m){s.add(nt(m,e,r,m,t,a))}):Kl(t)&&t.forEach(function(m,S){s.set(S,nt(m,e,r,S,t,a))});var R=o?c?Nl:Ll:c?Jl:Wl,A=l?void 0:R(t);return Il(A||t,function(m,S){A&&(S=m,m=t[S]),El(s,S,nt(m,e,r,S,t,a))}),s}var Fe=nt,wf=Fe,Tf=1,Af=4;function Of(t){return wf(t,Tf|Af)}var At=Of;let Cf=1,jf=null;class F{constructor(e=Cf,r=jf){g(this,"page");g(this,"limit");g(this,"term");g(this,"filters");g(this,"ids");g(this,"queries");g(this,"associations");g(this,"postFilter");g(this,"sortings");g(this,"aggregations");g(this,"grouping");g(this,"fields");g(this,"groupFields");g(this,"totalCountMode");g(this,"includes");this.page=e,this.limit=r,this.term=null,this.filters=[],this.includes=null,this.ids=[],this.queries=[],this.associations=[],this.postFilter=[],this.sortings=[],this.aggregations=[],this.grouping=[],this.groupFields=[],this.fields=[],this.totalCountMode=1}static fromCriteria(e){return At(e)}parse(){const e={};return this.ids.length>0&&(e.ids=this.ids.join("|")),this.page!==null&&(e.page=this.page),this.limit!==null&&(e.limit=this.limit),this.term!==null&&(e.term=this.term),this.queries.length>0&&(e.query=this.queries),this.filters.length>0&&(e.filter=this.filters),this.postFilter.length>0&&(e["post-filter"]=this.postFilter),this.sortings.length>0&&(e.sort=this.sortings),this.aggregations.length>0&&(e.aggregations=this.aggregations),this.groupFields.length>0&&(e.groupFields=this.groupFields),this.grouping.length>0&&(e.grouping=this.grouping),this.fields.length>0&&(e.fields=this.fields),this.associations.length>0&&(e.associations={},this.associations.forEach(r=>{!e.associations||(e.associations[r.association]=r.criteria.parse())})),this.includes!==null&&(e.includes=this.includes),this.totalCountMode!==null&&(e["total-count-mode"]=this.totalCountMode),e}setIds(e){return this.ids=e,this}setTotalCountMode(e){return typeof e!="number"&&(this.totalCountMode=null),this.totalCountMode=e<0||e>2?null:e,this}setPage(e){return this.page=e,this}setLimit(e){return this.limit=e,this}setTerm(e){return this.term=e,this}addFilter(e){return this.filters.push(e),this}addIncludes(e){return Object.entries(e).forEach(([r,n])=>{this.includes===null&&(this.includes={}),this.includes[r]||(this.includes[r]=[]),this.includes[r].push(...n)}),this}addPostFilter(e){return this.postFilter.push(e),this}addSorting(e){return this.sortings.push(e),this}addQuery(e,r,n=null){const i={score:r,query:e};return n&&(i[n]=n),this.queries.push(i),this}addGroupField(e){return this.groupFields.push(e),this}addGrouping(e){return this.grouping.push(e),this}addFields(...e){return this.fields.push(...e),this}addAggregation(e){return this.aggregations.push(e),this}addAssociation(e){const r=e.split(".");let n=this;return r.forEach(i=>{n=n.getAssociation(i)}),this}getAssociation(e){const r=e.split(".");let n=this;return r.forEach(i=>{n.hasAssociation(i)||n.associations.push({association:i,criteria:new F(null,null)}),n=n.getAssociationCriteria(i)}),n}getAssociationCriteria(e){let r=null;return this.associations.forEach(n=>{n.association===e&&(r=n.criteria)}),r}getLimit(){var e;return(e=this.limit)!=null?e:0}getPage(){var e;return(e=this.page)!=null?e:0}getCriteriaData(){return{page:this.page,limit:this.limit,term:this.term,filters:this.filters,ids:this.ids,queries:this.queries,associations:this.associations,postFilter:this.postFilter,sortings:this.sortings,aggregations:this.aggregations,grouping:this.grouping,fields:this.fields,groupFields:this.groupFields,totalCountMode:this.totalCountMode,includes:this.includes}}hasAssociation(e){return this.associations.some(r=>r.association===e)}resetSorting(){this.sortings=[]}static avg(e,r){return{type:"avg",name:e,field:r}}static count(e,r){return{type:"count",name:e,field:r}}static max(e,r){return{type:"max",name:e,field:r}}static min(e,r){return{type:"min",name:e,field:r}}static stats(e,r){return{type:"stats",name:e,field:r}}static sum(e,r){return{type:"sum",name:e,field:r}}static terms(e,r,n=null,i=null,a=null){return{type:"terms",name:e,field:r,limit:n,sort:i,aggregation:a}}static filter(e,r,n){return{type:"filter",name:e,filter:r,aggregation:n}}static histogram(e,r,n,i,a,s){return{type:"histogram",name:e,field:r,interval:n,format:i,aggregation:a,timeZone:s}}static sort(e,r="ASC",n=!1){return{field:e,order:r,naturalSorting:n}}static naturalSorting(e,r="ASC"){return{field:e,order:r,naturalSorting:!0}}static contains(e,r){return{type:"contains",field:e,value:r}}static prefix(e,r){return{type:"prefix",field:e,value:r}}static suffix(e,r){return{type:"suffix",field:e,value:r}}static equalsAny(e,r){return{type:"equalsAny",field:e,value:r.join("|")}}static range(e,r){return{type:"range",field:e,parameters:r}}static equals(e,r){return{type:"equals",field:e,value:r}}static not(e,r=[]){return{type:"not",operator:e,queries:r}}static multi(e,r=[]){return{type:"multi",operator:e,queries:r}}}const If=()=>({name:"criteria",serialize:({value:t,customizerMethod:e})=>{if(t instanceof F)return{__type__:"__Criteria__",data:e(t.getCriteriaData())}},deserialize:({value:t,customizerMethod:e})=>{if(B("__Criteria__",t)&&typeof t.data=="object"){const r=t.data,n=new F;return n.setPage(r.page),n.setLimit(r.limit),n.setTerm(r.term),r.filters.forEach(i=>{n.addFilter(i)}),n.setIds(r.ids),r.queries.forEach(({query:i,score:a})=>{n.addQuery(i,a)}),r.associations.forEach(i=>{n.associations.push(e(i))}),r.postFilter.forEach(i=>{n.addPostFilter(i)}),r.sortings.forEach(i=>{n.addSorting(i)}),r.aggregations.forEach(i=>{n.addAggregation(i)}),r.grouping.forEach(i=>{n.addGrouping(i)}),r.fields.forEach(i=>{n.addFields(i)}),r.groupFields.forEach(i=>{n.addGroupField(i)}),r.includes&&n.addIncludes(r.includes),n.setTotalCountMode(r.totalCountMode),n}}});let Ef=(t,e,r)=>{t[e]=r};class Pf{constructor(e,r,n,i={}){g(this,"id");g(this,"_origin");g(this,"_entityName");g(this,"_draft");g(this,"_isDirty");g(this,"_isNew");var s,u;this.id=e,this._origin=i.originData?At(i.originData):At(n),this._entityName=r,this._draft=n,this._isDirty=(s=i.isDirty)!=null?s:!1,this._isNew=(u=i.isNew)!=null?u:!1;const a=this;return new Proxy(this._draft,{get(c,o){return o in a._draft?a._draft[o]:a[o]},set(c,o,l){return Ef(a._draft,o,l),a._isDirty=!0,!0}})}markAsNew(){this._isNew=!0}isNew(){return this._isNew}getIsDirty(){return this._isDirty}getOrigin(){return this._origin}getDraft(){return this._draft}getEntityName(){return this._entityName}}const Le=function(e,r,n,i){return new Pf(e,r,n,i)},Mf=()=>({name:"entity",serialize:({value:t,customizerMethod:e})=>{if(!(!tt(t)||typeof t.getDraft!="function"))return{__type__:"__Entity__",__id__:t.id,__entityName__:t._entityName,__isDirty__:t._isDirty,__isNew__:t._isNew,__origin__:e(t._origin),__draft__:e(t._draft)}},deserialize:({value:t,customizerMethod:e})=>{if(B("__Entity__",t)&&typeof t.__origin__=="object")return new Le(t.__id__,t.__entityName__,e(t.__draft__),{originData:e(t.__origin__),isDirty:t.__isDirty__,isNew:t.__isNew__})}});class L extends Array{constructor(e,r,n,i=null,a=[],s=null,u=null){super();g(this,"entity");g(this,"source");g(this,"context");g(this,"criteria");g(this,"aggregations");g(this,"total");g(this,"first");g(this,"last");g(this,"remove");g(this,"has");g(this,"get");g(this,"getAt");g(this,"getIds");g(this,"add");g(this,"addAt");g(this,"moveItem");this.entity=r,this.source=e,this.context=n,this.criteria=i,this.aggregations=u,this.total=s,this.push(...a),this.first=function(){return this.length<=0?null:this[0]},this.last=function(){return this.length<=0?null:this[this.length-1]},this.remove=function(o){const l=this.findIndex(f=>f.id===o);return l<0?!1:(this.splice(l,1),!0)},this.has=function(o){return this.some(l=>l.id===o)},this.get=function(o){const l=this.find(f=>f.id===o);return typeof l!="undefined"?l:null},this.getAt=function(o){const l=this[o];return typeof l!="undefined"?l:null},this.getIds=function(){return this.map(o=>o.id)},this.add=function(o){this.push(o)},this.addAt=function(o,l){if(typeof l=="undefined"){this.add(o);return}this.splice(l,0,o)},this.moveItem=function(o,l=null){if(l===null&&(l=this.length),o<0||o>=this.length)return null;if(l===o)return this.getAt(o);const f=this.find((R,A)=>A===o);if(typeof f=="undefined")return null;const h=this.filter((R,A)=>A!==o),T=[...h.slice(0,l),f,...h.slice(l)];return this.splice(0,this.length,...T),f},this.filter=function(o,l){const f=Object.getPrototypeOf(this).filter.call(this,o,l);return new L(this.source,this.entity,this.context,this.criteria,f,this.total,this.aggregations)}}static fromCollection(e){return new L(e.source,e.entity,e.context,e.criteria===null?e.criteria:F.fromCriteria(e.criteria),e,e.total,e.aggregations)}}const xf=()=>({name:"entity-collection",serialize:({value:t,customizerMethod:e})=>{if(t instanceof L)return e({__type__:"__EntityCollection__",__source__:t.source,__entityName__:t.entity,__context__:t.context,__criteria__:t.criteria,__entities__:Array.from(t),__total__:t.total,__aggregations__:t.aggregations})},deserialize:({value:t,customizerMethod:e})=>{if(B("__EntityCollection__",t))return new L(t.__source__,t.__entityName__,t.__context__,e(t.__criteria__),e(t.__entities__),t.__total__,t.__aggregations__)}});class K extends Error{constructor(e,r){super(e);g(this,"code",500);!r||(this.code=r)}toJSON(){return{__type__:"__HandleError__",__code__:this.code,__message__:this.message}}}const Df=()=>({name:"handle-error",serialize:()=>{},deserialize:({value:t})=>{if(B("__HandleError__",t))return new K(t.__message__,t.__code__)}});var zf=Fe,Ff=1,Lf=4;function Nf(t,e){return e=typeof e=="function"?e:void 0,zf(t,Ff|Lf,e)}var Ne=Nf;const Rf=[If,xf,Mf,Ga,Df,()=>({name:"handle-error",serialize:()=>{},deserialize:({value:t})=>{if(B("__MissingPrivilegesError__",t))return new x(t.__messageType__,t.__data__)}})];function Gf(t){const e=Rf.map(s=>s(t));function r(){return e}function n(s){var u;return(u=e.find(c=>c.name===s))!=null?u:null}function i(s){return Ne(s,(u,c,o,l)=>{for(const f of e){const h=f.serialize({value:u,key:c,object:o,stack:l,customizerMethod:i});if(h)return h}})}function a(s,u){return Ne(s,(c,o,l,f)=>{for(const h of e){const T=h.deserialize({value:c,key:o,object:l,stack:f,event:u,customizerMethod:a});if(T)return T}})}return{getSerializers:r,getSerializerByName:n,serialize:i,deserialize:a}}function Uf(t,e){if(typeof e=="string")return new K(e);if(!(e instanceof Error))return new K("An unknown error occurred.");if(Fa(e,"response.data.errors.0.code")&&e.response.data.errors.length){const r=e.response.data.errors.filter(i=>i.code==="FRAMEWORK__MISSING_PRIVILEGE_ERROR"),n=[];return r.forEach(i=>{const a=JSON.parse(i.detail);n.push(...a.missingPrivileges)}),n.length?new x(t,n):new K(e.response.data.errors[0].code,e.response.data.errors[0].status)}return new K(e.message)}function Ot({serializedData:t,origin:e,type:r,privilegesToCheck:n=[]}){const i=ne(e);if(!i)return null;const a=[];return te(t,(s,u,c)=>{if(u==="__type__"&&["__EntityCollection__","__Entity__"].includes(c)){const o=s.__entityName__;[...n].sort().forEach(l=>{const f=i.permissions[l];(!f||!f.includes(o))&&a.push(`${l}:${o}`)})}}),a.length>0?new x(r,a):null}const{serialize:q,deserialize:Re}=Gf({handle:N,send:$});let Ge={};const Ct=new Set;function $(t,e,r,n){const i=La(t);if(i!==null){const h=new x(t,i);return Promise.reject(h)}const a=Qt(),s=e!=null?e:{};let c=q({_type:t,_data:s,_callbackId:a});if(n){const h=Ot({serializedData:c,origin:n,privilegesToCheck:["read"],type:t});h&&(["datasetSubscribe","datasetUpdate","datasetRegistration","datasetGet"].includes(c._type)?c=q({_type:c._type,_callbackId:c._callbackId,_data:{id:c._data.id,data:h}}):c=q({_type:c._type,_callbackId:c._callbackId,_data:h}))}const o=JSON.stringify(c);let l=!1;const f=7e3;return new Promise((h,T)=>{const R=function(S){if(typeof S.data!="string")return;let W;try{W=JSON.parse(S.data)}catch{return}if(!Kf(W)||W._callbackId!==a||!W.hasOwnProperty("_response"))return;const Rg=Re(W,S);if(window.removeEventListener("message",R),!l){l=!0;const It=Rg._response;if(It instanceof Error){T(It);return}h(It)}};window.addEventListener("message",R);let A=!0;try{A=!window.parent.origin}catch{}let m=A?document.referrer:window.parent.origin;n&&(m=n),r?r.postMessage(o,m):window.parent.postMessage(o,m),setTimeout(()=>{l||T("Send timeout expired. It could be possible that no handler for the postMessage request exists or that the handler freezed.")},f)})}function N(t,e){const r=async function(n){var l;if(ft[t]&&Object.keys(ft[t]).length&&(!Ge||Na(t,n.origin)!==null)||typeof n.data!="string")return;let i;try{i=JSON.parse(n.data)}catch{return}if(!kf(i)||i._type!==t)return;const a=Re(i,n),s=await Promise.resolve((()=>{const f=Ot({serializedData:i,origin:n.origin,type:t,privilegesToCheck:["create","delete","update","read"]});return f||e(a._data,{_event_:n})})()).catch(f=>Uf(t,f)),u={_callbackId:a._callbackId,_type:a._type,_response:s!=null?s:null},c=(()=>{let f=q(u);const h=Ot({serializedData:f,origin:n.origin,privilegesToCheck:["read"],type:t});return h&&(f._response=h,f=q(f)),f})(),o=JSON.stringify(c);n.source?n.source.postMessage(o,{targetOrigin:(l=n.origin)!=null?l:"*"}):window.postMessage(o,window.origin)};return window.addEventListener("message",r),()=>window.removeEventListener("message",r)}function Hf(t,e){[...Ct].forEach(({source:r,origin:n})=>$(t,e,r,n).catch(()=>{}))}function jt(t,e){return N(t,e)}function p(t,e){return r=>$(t,Pt(Pt({},e),r))}function Bf(t){return e=>N(t,e)}function Ue(t){return(e,r)=>r?jt(t,i=>{i.id===r&&e(i)}):jt(t,e)}const it=new Map;(async()=>{N("__registerWindow__",(t,e)=>{let r,n;e._event_.source?(r=e._event_.source,n=e._event_.origin):(r=window,n=window.origin),Ct.add({source:r,origin:n}),it.forEach((i,a)=>{$("datasetSubscribe",{id:a,data:i},r,n).catch(()=>{})})}),N("datasetRegistration",t=>(it.set(t.id,t.data),Hf("datasetSubscribe",t),{id:t.id,data:t.data})),N("datasetSubscribe",t=>{var e;return(e=it.get(t.id))!=null?e:null}),await $("__registerWindow__",{})})().catch(t=>console.error(t)),window._swsdk={sourceRegistry:Ct,datasets:it};function kf(t){const e=t;return!!e._type&&!!e._data&&!!e._callbackId}function Kf(t){const e=t;return!!e._type&&!!e.hasOwnProperty("_response")&&!!e._callbackId}const qf=p("windowRedirect"),Vf=p("windowRouterPush"),Wf=p("windowReload",{});var Jf=Object.freeze(Object.defineProperty({__proto__:null,redirect:qf,routerPush:Vf,reload:Wf},Symbol.toStringTag,{value:"Module"}));const Yf=p("notificationDispatch");var Xf=Object.freeze(Object.defineProperty({__proto__:null,dispatch:Yf},Symbol.toStringTag,{value:"Module"}));const Zf=p("contextLanguage",{}),Qf=Ue("contextLanguage"),tg=p("contextEnvironment",{}),eg=p("contextLocale",{}),rg=Ue("contextLocale"),ng=p("contextCurrency",{}),ig=p("contextShopwareVersion",{}),ag=p("contextAppInformation",{}),sg=p("contextModuleInformation",{});var og=Object.freeze(Object.defineProperty({__proto__:null,getLanguage:Zf,subscribeLanguage:Qf,getEnvironment:tg,getLocale:eg,subscribeLocale:rg,getCurrency:ng,getShopwareVersion:ig,getAppInformation:ag,getModuleInformation:sg},Symbol.toStringTag,{value:"Module"}));const cg=p("uiComponentSectionRenderer",{src:(ke=za())!=null?ke:void 0});var ug=Object.freeze(Object.defineProperty({__proto__:null,add:cg},Symbol.toStringTag,{value:"Module"})),lg=t=>({addTabItem:p("uiTabsAddTabItem",{positionId:t})});const fg=p("cmsRegisterElement");var gg=Object.freeze(Object.defineProperty({__proto__:null,registerCmsElement:fg},Symbol.toStringTag,{value:"Module"}));const dg=t=>lt()===t,_g=()=>window!==window.parent,He=t=>{if(t)return $("locationUpdateHeight",{height:t,locationId:lt()});const e=document.documentElement.offsetHeight;return $("locationUpdateHeight",{height:e,locationId:lt()})};let V=null;var pg=Object.freeze(Object.defineProperty({__proto__:null,is:dg,isIframe:_g,updateHeight:He,startAutoResizer:()=>{V=new ResizeObserver(()=>{He()}),V.observe(document.body)},stopAutoResizer:()=>{V&&(V.unobserve(document.body),V.disconnect())},MAIN_HIDDEN:"sw-main-hidden"},Symbol.toStringTag,{value:"Module"}));const hg=p("menuItemAdd");var yg=Object.freeze(Object.defineProperty({__proto__:null,addMenuItem:hg},Symbol.toStringTag,{value:"Module"}));const bg=p("settingsItemAdd");var vg=Object.freeze(Object.defineProperty({__proto__:null,addSettingsItem:bg},Symbol.toStringTag,{value:"Module"}));const $g=p("mainModuleAdd");var mg=Object.freeze(Object.defineProperty({__proto__:null,addMainModule:$g},Symbol.toStringTag,{value:"Module"}));const Sg=p("uiModalOpen"),wg=p("uiModalClose");var Tg=Object.freeze(Object.defineProperty({__proto__:null,open:Sg,close:wg},Symbol.toStringTag,{value:"Module"}));const Ag=p("actionButtonAdd");var Og=Object.freeze(Object.defineProperty({__proto__:null,add:Ag},Symbol.toStringTag,{value:"Module"}));const Cg=p("actionExecute");var jg=Object.freeze(Object.defineProperty({__proto__:null,actionExecute:Cg},Symbol.toStringTag,{value:"Module"})),Ig=t=>({search:(e,r)=>$("repositorySearch",{entityName:t,context:r,criteria:e}),get:(e,r,n)=>$("repositoryGet",{entityName:t,id:e,context:r,criteria:n}),save:(e,r)=>$("repositorySave",{entityName:t,entity:e,context:r}),clone:(e,r,n)=>$("repositoryClone",{entityName:t,entityId:e,context:r,behavior:n}),hasChanges:e=>$("repositoryHasChanges",{entityName:t,entity:e}),saveAll:(e,r)=>$("repositorySaveAll",{entityName:t,entities:e,context:r}),delete:(e,r)=>$("repositoryDelete",{entityName:t,entityId:e,context:r}),create:(e,r)=>$("repositoryCreate",{entityName:t,entityId:r,context:e})});function Be(t){return(e,r)=>jt(t,i=>{if(i&&i.id===e){const a=r(i);a&&a.catch(()=>{})}})}const Eg=Be("datasetSubscribe"),Pg=p("datasetGet"),Mg=p("datasetUpdate"),xg=p("datasetRegistration"),Dg=Be("datasetUpdate"),zg=Bf("datasetGet");var Fg=Object.freeze(Object.defineProperty({__proto__:null,subscribe:Eg,get:Pg,update:Mg,register:xg,updateSubscriber:Dg,handleGet:zg,repository:Ig,Classes:{Criteria:F,Entity:Le,EntityCollection:L}},Symbol.toStringTag,{value:"Module"}));const Lg={webhook:jg},Ng={componentSection:ug,tabs:lg,menu:yg,settings:vg,mainModule:mg,modal:Tg,actionButton:Og};y.app=Lg,y.cms=gg,y.context=og,y.data=Fg,y.location=pg,y.notification=Xf,y.ui=Ng,y.window=Jf,Object.defineProperties(y,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}); |
@@ -47,3 +47,3 @@ import Criteria from './Criteria'; | ||
id: string; | ||
data: unknown; | ||
data?: unknown; | ||
}; | ||
@@ -50,0 +50,0 @@ declare const Classes: { |
@@ -5,2 +5,3 @@ import * as window from './window'; | ||
import * as componentSection from './ui/componentSection'; | ||
import * as cms from './ui/cms'; | ||
import * as location from './location'; | ||
@@ -31,2 +32,2 @@ import * as menu from './ui/menu'; | ||
*/ | ||
export { window, notification, context, ui, location, app, data, }; | ||
export { window, notification, context, ui, cms, location, app, data, }; |
@@ -6,2 +6,3 @@ import * as window from './window'; | ||
import tabs from './ui/tabs'; | ||
import * as cms from './ui/cms'; | ||
import * as location from './location'; | ||
@@ -30,3 +31,3 @@ import * as menu from './ui/menu'; | ||
*/ | ||
export { window, notification, context, ui, location, app, data, }; | ||
export { window, notification, context, ui, cms, location, app, data, }; | ||
//# sourceMappingURL=index.js.map |
@@ -6,2 +6,3 @@ import type { notificationDispatch } from './notification/index'; | ||
import type { uiTabsAddTabItem } from './ui/tabs'; | ||
import type { cmsRegisterElement } from './ui/cms'; | ||
import type { locationUpdateHeight } from './location/index'; | ||
@@ -38,2 +39,3 @@ import type { menuItemAdd } from './ui/menu'; | ||
uiTabsAddTabItem: uiTabsAddTabItem; | ||
cmsRegisterElement: cmsRegisterElement; | ||
locationUpdateHeight: locationUpdateHeight; | ||
@@ -40,0 +42,0 @@ menuItemAdd: menuItemAdd; |
@@ -19,2 +19,3 @@ import { _privileges } from './messages/_privileges'; | ||
uiTabsAddTabItem: {}, | ||
cmsRegisterElement: {}, | ||
locationUpdateHeight: {}, | ||
@@ -21,0 +22,0 @@ menuItemAdd: {}, |
@@ -18,3 +18,3 @@ export default class MissingPrivilegesError extends Error { | ||
this.messageType = messageType; | ||
// Set prototype excplicitly | ||
// Set prototype explicitly | ||
Object.setPrototypeOf(this, MissingPrivilegesError.prototype); | ||
@@ -21,0 +21,0 @@ } |
{ | ||
"name": "@shopware-ag/admin-extension-sdk", | ||
"license": "MIT", | ||
"version": "2.1.0", | ||
"version": "2.2.0", | ||
"repository": "git://github.com/shopware/admin-extension-sdk.git", | ||
@@ -6,0 +6,0 @@ "description": "The SDK for App iframes to communicate with the Shopware Adminstration", |
@@ -47,3 +47,3 @@ import Criteria from './Criteria'; | ||
id: string; | ||
data: unknown; | ||
data?: unknown; | ||
}; | ||
@@ -50,0 +50,0 @@ declare const Classes: { |
@@ -5,2 +5,3 @@ import * as window from './window'; | ||
import * as componentSection from './ui/componentSection'; | ||
import * as cms from './ui/cms'; | ||
import * as location from './location'; | ||
@@ -31,2 +32,2 @@ import * as menu from './ui/menu'; | ||
*/ | ||
export { window, notification, context, ui, location, app, data, }; | ||
export { window, notification, context, ui, cms, location, app, data, }; |
@@ -33,3 +33,3 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { | ||
else if (typeof define === "function" && define.amd) { | ||
define(["require", "exports", "./window", "./notification", "./context", "./ui/componentSection", "./ui/tabs", "./location", "./ui/menu", "./ui/settings", "./ui/mainModule", "./ui/modal", "./ui/actionButton", "./app/action", "./data"], factory); | ||
define(["require", "exports", "./window", "./notification", "./context", "./ui/componentSection", "./ui/tabs", "./ui/cms", "./location", "./ui/menu", "./ui/settings", "./ui/mainModule", "./ui/modal", "./ui/actionButton", "./app/action", "./data"], factory); | ||
} | ||
@@ -39,3 +39,3 @@ })(function (require, exports) { | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.data = exports.app = exports.location = exports.ui = exports.context = exports.notification = exports.window = void 0; | ||
exports.data = exports.app = exports.location = exports.cms = exports.ui = exports.context = exports.notification = exports.window = void 0; | ||
const window = __importStar(require("./window")); | ||
@@ -49,2 +49,4 @@ exports.window = window; | ||
const tabs_1 = __importDefault(require("./ui/tabs")); | ||
const cms = __importStar(require("./ui/cms")); | ||
exports.cms = cms; | ||
const location = __importStar(require("./location")); | ||
@@ -51,0 +53,0 @@ exports.location = location; |
@@ -6,2 +6,3 @@ import type { notificationDispatch } from './notification/index'; | ||
import type { uiTabsAddTabItem } from './ui/tabs'; | ||
import type { cmsRegisterElement } from './ui/cms'; | ||
import type { locationUpdateHeight } from './location/index'; | ||
@@ -38,2 +39,3 @@ import type { menuItemAdd } from './ui/menu'; | ||
uiTabsAddTabItem: uiTabsAddTabItem; | ||
cmsRegisterElement: cmsRegisterElement; | ||
locationUpdateHeight: locationUpdateHeight; | ||
@@ -40,0 +42,0 @@ menuItemAdd: menuItemAdd; |
@@ -31,2 +31,3 @@ (function (factory) { | ||
uiTabsAddTabItem: {}, | ||
cmsRegisterElement: {}, | ||
locationUpdateHeight: {}, | ||
@@ -33,0 +34,0 @@ menuItemAdd: {}, |
@@ -29,3 +29,3 @@ (function (factory) { | ||
this.messageType = messageType; | ||
// Set prototype excplicitly | ||
// Set prototype explicitly | ||
Object.setPrototypeOf(this, MissingPrivilegesError.prototype); | ||
@@ -32,0 +32,0 @@ } |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
566450
255
8780