@beyonk/embedded
Advanced tools
Comparing version 2.1.0 to 3.0.0
@@ -1,1 +0,1 @@ | ||
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).BeyonkEmbedded={})}(this,(function(t){var e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function n(t,e,n){return t(n={path:e,exports:{},require:function(t,e){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==e&&n.path)}},n.exports),n.exports}var r=function(t){return t&&t.Math==Math&&t},o=r("object"==typeof globalThis&&globalThis)||r("object"==typeof window&&window)||r("object"==typeof self&&self)||r("object"==typeof e&&e)||Function("return this")(),i=function(t){try{return!!t()}catch(t){return!0}},u=!i((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]})),c={}.propertyIsEnumerable,a=Object.getOwnPropertyDescriptor,f={f:a&&!c.call({1:2},1)?function(t){var e=a(this,t);return!!e&&e.enumerable}:c},l=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},s={}.toString,p=function(t){return s.call(t).slice(8,-1)},y="".split,d=i((function(){return!Object("z").propertyIsEnumerable(0)}))?function(t){return"String"==p(t)?y.call(t,""):Object(t)}:Object,h=function(t){if(null==t)throw TypeError("Can't call method on "+t);return t},v=function(t){return d(h(t))},g=function(t){return"object"==typeof t?null!==t:"function"==typeof t},b=function(t,e){if(!g(t))return t;var n,r;if(e&&"function"==typeof(n=t.toString)&&!g(r=n.call(t)))return r;if("function"==typeof(n=t.valueOf)&&!g(r=n.call(t)))return r;if(!e&&"function"==typeof(n=t.toString)&&!g(r=n.call(t)))return r;throw TypeError("Can't convert object to primitive value")},m={}.hasOwnProperty,S=function(t,e){return m.call(t,e)},w=o.document,O=g(w)&&g(w.createElement),E=function(t){return O?w.createElement(t):{}},j=!u&&!i((function(){return 7!=Object.defineProperty(E("div"),"a",{get:function(){return 7}}).a})),x=Object.getOwnPropertyDescriptor,P={f:u?x:function(t,e){if(t=v(t),e=b(e,!0),j)try{return x(t,e)}catch(t){}if(S(t,e))return l(!f.f.call(t,e),t[e])}},N=function(t){if(!g(t))throw TypeError(String(t)+" is not an object");return t},I=Object.defineProperty,_={f:u?I:function(t,e,n){if(N(t),e=b(e,!0),N(n),j)try{return I(t,e,n)}catch(t){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(t[e]=n.value),t}},T=u?function(t,e,n){return _.f(t,e,l(1,n))}:function(t,e,n){return t[e]=n,t},R=function(t,e){try{T(o,t,e)}catch(n){o[t]=e}return e},k="__core-js_shared__",A=o[k]||R(k,{}),F=Function.toString;"function"!=typeof A.inspectSource&&(A.inspectSource=function(t){return F.call(t)});var C,M,D,L=A.inspectSource,U=o.WeakMap,z="function"==typeof U&&/native code/.test(L(U)),$=n((function(t){(t.exports=function(t,e){return A[t]||(A[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.6.5",mode:"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"})})),B=0,G=Math.random(),V=function(t){return"Symbol("+String(void 0===t?"":t)+")_"+(++B+G).toString(36)},W=$("keys"),Y=function(t){return W[t]||(W[t]=V(t))},q={},J=o.WeakMap;if(z){var K=new J,X=K.get,Q=K.has,H=K.set;C=function(t,e){return H.call(K,t,e),e},M=function(t){return X.call(K,t)||{}},D=function(t){return Q.call(K,t)}}else{var Z=Y("state");q[Z]=!0,C=function(t,e){return T(t,Z,e),e},M=function(t){return S(t,Z)?t[Z]:{}},D=function(t){return S(t,Z)}}var tt,et={set:C,get:M,has:D,enforce:function(t){return D(t)?M(t):C(t,{})},getterFor:function(t){return function(e){var n;if(!g(e)||(n=M(e)).type!==t)throw TypeError("Incompatible receiver, "+t+" required");return n}}},nt=n((function(t){var e=et.get,n=et.enforce,r=String(String).split("String");(t.exports=function(t,e,i,u){var c=!!u&&!!u.unsafe,a=!!u&&!!u.enumerable,f=!!u&&!!u.noTargetGet;"function"==typeof i&&("string"!=typeof e||S(i,"name")||T(i,"name",e),n(i).source=r.join("string"==typeof e?e:"")),t!==o?(c?!f&&t[e]&&(a=!0):delete t[e],a?t[e]=i:T(t,e,i)):a?t[e]=i:R(e,i)})(Function.prototype,"toString",(function(){return"function"==typeof this&&e(this).source||L(this)}))})),rt=o,ot=function(t){return"function"==typeof t?t:void 0},it=function(t,e){return arguments.length<2?ot(rt[t])||ot(o[t]):rt[t]&&rt[t][e]||o[t]&&o[t][e]},ut=Math.ceil,ct=Math.floor,at=function(t){return isNaN(t=+t)?0:(t>0?ct:ut)(t)},ft=Math.min,lt=function(t){return t>0?ft(at(t),9007199254740991):0},st=Math.max,pt=Math.min,yt=function(t){return function(e,n,r){var o,i=v(e),u=lt(i.length),c=function(t,e){var n=at(t);return n<0?st(n+e,0):pt(n,e)}(r,u);if(t&&n!=n){for(;u>c;)if((o=i[c++])!=o)return!0}else for(;u>c;c++)if((t||c in i)&&i[c]===n)return t||c||0;return!t&&-1}},dt={includes:yt(!0),indexOf:yt(!1)}.indexOf,ht=function(t,e){var n,r=v(t),o=0,i=[];for(n in r)!S(q,n)&&S(r,n)&&i.push(n);for(;e.length>o;)S(r,n=e[o++])&&(~dt(i,n)||i.push(n));return i},vt=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],gt=vt.concat("length","prototype"),bt={f:Object.getOwnPropertyNames||function(t){return ht(t,gt)}},mt={f:Object.getOwnPropertySymbols},St=it("Reflect","ownKeys")||function(t){var e=bt.f(N(t)),n=mt.f;return n?e.concat(n(t)):e},wt=function(t,e){for(var n=St(e),r=_.f,o=P.f,i=0;i<n.length;i++){var u=n[i];S(t,u)||r(t,u,o(e,u))}},Ot=/#|\.prototype\./,Et=function(t,e){var n=xt[jt(t)];return n==Nt||n!=Pt&&("function"==typeof e?i(e):!!e)},jt=Et.normalize=function(t){return String(t).replace(Ot,".").toLowerCase()},xt=Et.data={},Pt=Et.NATIVE="N",Nt=Et.POLYFILL="P",It=Et,_t=P.f,Tt=function(t,e){var n,r,i,u,c,a=t.target,f=t.global,l=t.stat;if(n=f?o:l?o[a]||R(a,{}):(o[a]||{}).prototype)for(r in e){if(u=e[r],i=t.noTargetGet?(c=_t(n,r))&&c.value:n[r],!It(f?r:a+(l?".":"#")+r,t.forced)&&void 0!==i){if(typeof u==typeof i)continue;wt(u,i)}(t.sham||i&&i.sham)&&T(u,"sham",!0),nt(n,r,u,t)}},Rt=!!Object.getOwnPropertySymbols&&!i((function(){return!String(Symbol())})),kt=Rt&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,At=Array.isArray||function(t){return"Array"==p(t)},Ft=function(t){return Object(h(t))},Ct=Object.keys||function(t){return ht(t,vt)},Mt=u?Object.defineProperties:function(t,e){N(t);for(var n,r=Ct(e),o=r.length,i=0;o>i;)_.f(t,n=r[i++],e[n]);return t},Dt=it("document","documentElement"),Lt="prototype",Ut="script",zt=Y("IE_PROTO"),$t=function(){},Bt=function(t){return"<"+Ut+">"+t+"</"+Ut+">"},Gt=function(){try{tt=document.domain&&new ActiveXObject("htmlfile")}catch(t){}var t,e,n;Gt=tt?function(t){t.write(Bt("")),t.close();var e=t.parentWindow.Object;return t=null,e}(tt):(e=E("iframe"),n="java"+Ut+":",e.style.display="none",Dt.appendChild(e),e.src=String(n),(t=e.contentWindow.document).open(),t.write(Bt("document.F=Object")),t.close(),t.F);for(var r=vt.length;r--;)delete Gt[Lt][vt[r]];return Gt()};q[zt]=!0;var Vt,Wt,Yt,qt=Object.create||function(t,e){var n;return null!==t?($t[Lt]=N(t),n=new $t,$t[Lt]=null,n[zt]=t):n=Gt(),void 0===e?n:Mt(n,e)},Jt=bt.f,Kt={}.toString,Xt="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],Qt={f:function(t){return Xt&&"[object Window]"==Kt.call(t)?function(t){try{return Jt(t)}catch(t){return Xt.slice()}}(t):Jt(v(t))}},Ht=$("wks"),Zt=o.Symbol,te=kt?Zt:Zt&&Zt.withoutSetter||V,ee=function(t){return S(Ht,t)||(Rt&&S(Zt,t)?Ht[t]=Zt[t]:Ht[t]=te("Symbol."+t)),Ht[t]},ne={f:ee},re=_.f,oe=function(t){var e=rt.Symbol||(rt.Symbol={});S(e,t)||re(e,t,{value:ne.f(t)})},ie=_.f,ue=ee("toStringTag"),ce=function(t){if("function"!=typeof t)throw TypeError(String(t)+" is not a function");return t},ae=ee("species"),fe=function(t,e){var n;return At(t)&&("function"!=typeof(n=t.constructor)||n!==Array&&!At(n.prototype)?g(n)&&null===(n=n[ae])&&(n=void 0):n=void 0),new(void 0===n?Array:n)(0===e?0:e)},le=[].push,se=function(t){var e=1==t,n=2==t,r=3==t,o=4==t,i=6==t,u=5==t||i;return function(c,a,f,l){for(var s,p,y=Ft(c),h=d(y),v=function(t,e,n){if(ce(t),void 0===e)return t;switch(n){case 0:return function(){return t.call(e)};case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,o){return t.call(e,n,r,o)}}return function(){return t.apply(e,arguments)}}(a,f,3),g=lt(h.length),b=0,m=l||fe,S=e?m(c,g):n?m(c,0):void 0;g>b;b++)if((u||b in h)&&(p=v(s=h[b],b,y),t))if(e)S[b]=p;else if(p)switch(t){case 3:return!0;case 5:return s;case 6:return b;case 2:le.call(S,s)}else if(o)return!1;return i?-1:r||o?o:S}},pe={forEach:se(0),map:se(1),filter:se(2),some:se(3),every:se(4),find:se(5),findIndex:se(6)}.forEach,ye=Y("hidden"),de="Symbol",he="prototype",ve=ee("toPrimitive"),ge=et.set,be=et.getterFor(de),me=Object[he],Se=o.Symbol,we=it("JSON","stringify"),Oe=P.f,Ee=_.f,je=Qt.f,xe=f.f,Pe=$("symbols"),Ne=$("op-symbols"),Ie=$("string-to-symbol-registry"),_e=$("symbol-to-string-registry"),Te=$("wks"),Re=o.QObject,ke=!Re||!Re[he]||!Re[he].findChild,Ae=u&&i((function(){return 7!=qt(Ee({},"a",{get:function(){return Ee(this,"a",{value:7}).a}})).a}))?function(t,e,n){var r=Oe(me,e);r&&delete me[e],Ee(t,e,n),r&&t!==me&&Ee(me,e,r)}:Ee,Fe=function(t,e){var n=Pe[t]=qt(Se[he]);return ge(n,{type:de,tag:t,description:e}),u||(n.description=e),n},Ce=kt?function(t){return"symbol"==typeof t}:function(t){return Object(t)instanceof Se},Me=function(t,e,n){t===me&&Me(Ne,e,n),N(t);var r=b(e,!0);return N(n),S(Pe,r)?(n.enumerable?(S(t,ye)&&t[ye][r]&&(t[ye][r]=!1),n=qt(n,{enumerable:l(0,!1)})):(S(t,ye)||Ee(t,ye,l(1,{})),t[ye][r]=!0),Ae(t,r,n)):Ee(t,r,n)},De=function(t,e){N(t);var n=v(e),r=Ct(n).concat($e(n));return pe(r,(function(e){u&&!Le.call(n,e)||Me(t,e,n[e])})),t},Le=function(t){var e=b(t,!0),n=xe.call(this,e);return!(this===me&&S(Pe,e)&&!S(Ne,e))&&(!(n||!S(this,e)||!S(Pe,e)||S(this,ye)&&this[ye][e])||n)},Ue=function(t,e){var n=v(t),r=b(e,!0);if(n!==me||!S(Pe,r)||S(Ne,r)){var o=Oe(n,r);return!o||!S(Pe,r)||S(n,ye)&&n[ye][r]||(o.enumerable=!0),o}},ze=function(t){var e=je(v(t)),n=[];return pe(e,(function(t){S(Pe,t)||S(q,t)||n.push(t)})),n},$e=function(t){var e=t===me,n=je(e?Ne:v(t)),r=[];return pe(n,(function(t){!S(Pe,t)||e&&!S(me,t)||r.push(Pe[t])})),r};(Rt||(Se=function(){if(this instanceof Se)throw TypeError("Symbol is not a constructor");var t=arguments.length&&void 0!==arguments[0]?String(arguments[0]):void 0,e=V(t),n=function(t){this===me&&n.call(Ne,t),S(this,ye)&&S(this[ye],e)&&(this[ye][e]=!1),Ae(this,e,l(1,t))};return u&&ke&&Ae(me,e,{configurable:!0,set:n}),Fe(e,t)},nt(Se[he],"toString",(function(){return be(this).tag})),nt(Se,"withoutSetter",(function(t){return Fe(V(t),t)})),f.f=Le,_.f=Me,P.f=Ue,bt.f=Qt.f=ze,mt.f=$e,ne.f=function(t){return Fe(ee(t),t)},u&&(Ee(Se[he],"description",{configurable:!0,get:function(){return be(this).description}}),nt(me,"propertyIsEnumerable",Le,{unsafe:!0}))),Tt({global:!0,wrap:!0,forced:!Rt,sham:!Rt},{Symbol:Se}),pe(Ct(Te),(function(t){oe(t)})),Tt({target:de,stat:!0,forced:!Rt},{for:function(t){var e=String(t);if(S(Ie,e))return Ie[e];var n=Se(e);return Ie[e]=n,_e[n]=e,n},keyFor:function(t){if(!Ce(t))throw TypeError(t+" is not a symbol");if(S(_e,t))return _e[t]},useSetter:function(){ke=!0},useSimple:function(){ke=!1}}),Tt({target:"Object",stat:!0,forced:!Rt,sham:!u},{create:function(t,e){return void 0===e?qt(t):De(qt(t),e)},defineProperty:Me,defineProperties:De,getOwnPropertyDescriptor:Ue}),Tt({target:"Object",stat:!0,forced:!Rt},{getOwnPropertyNames:ze,getOwnPropertySymbols:$e}),Tt({target:"Object",stat:!0,forced:i((function(){mt.f(1)}))},{getOwnPropertySymbols:function(t){return mt.f(Ft(t))}}),we)&&Tt({target:"JSON",stat:!0,forced:!Rt||i((function(){var t=Se();return"[null]"!=we([t])||"{}"!=we({a:t})||"{}"!=we(Object(t))}))},{stringify:function(t,e,n){for(var r,o=[t],i=1;arguments.length>i;)o.push(arguments[i++]);if(r=e,(g(e)||void 0!==t)&&!Ce(t))return At(e)||(e=function(t,e){if("function"==typeof r&&(e=r.call(this,t,e)),!Ce(e))return e}),o[1]=e,we.apply(null,o)}});Se[he][ve]||T(Se[he],ve,Se[he].valueOf),Wt=de,(Vt=Se)&&!S(Vt=Yt?Vt:Vt.prototype,ue)&&ie(Vt,ue,{configurable:!0,value:Wt}),q[ye]=!0;var Be=_.f,Ge=o.Symbol;if(u&&"function"==typeof Ge&&(!("description"in Ge.prototype)||void 0!==Ge().description)){var Ve={},We=function(){var t=arguments.length<1||void 0===arguments[0]?void 0:String(arguments[0]),e=this instanceof We?new Ge(t):void 0===t?Ge():Ge(t);return""===t&&(Ve[e]=!0),e};wt(We,Ge);var Ye=We.prototype=Ge.prototype;Ye.constructor=We;var qe=Ye.toString,Je="Symbol(test)"==String(Ge("test")),Ke=/^Symbol\((.*)\)[^)]+$/;Be(Ye,"description",{configurable:!0,get:function(){var t=g(this)?this.valueOf():this,e=qe.call(t);if(S(Ve,t))return"";var n=Je?e.slice(7,-1):e.replace(Ke,"$1");return""===n?void 0:n}}),Tt({global:!0,forced:!0},{Symbol:We})}oe("toPrimitive");var Xe=ee("toPrimitive"),Qe=Date.prototype;Xe in Qe||T(Qe,Xe,(function(t){if("string"!==t&&"number"!==t&&"default"!==t)throw TypeError("Incorrect hint");return b(N(this),"number"!==t)}));var He=[].slice,Ze={},tn=Function.bind||function(t){var e=ce(this),n=He.call(arguments,1),r=function(){var o=n.concat(He.call(arguments));return this instanceof r?function(t,e,n){if(!(e in Ze)){for(var r=[],o=0;o<e;o++)r[o]="a["+o+"]";Ze[e]=Function("C,a","return new C("+r.join(",")+")")}return Ze[e](t,n)}(e,o.length,o):e.apply(t,o)};return g(e.prototype)&&(r.prototype=e.prototype),r};Tt({target:"Function",proto:!0},{bind:tn});var en=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,n={};try{(t=Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set).call(n,[]),e=n instanceof Array}catch(t){}return function(n,r){return N(n),function(t){if(!g(t)&&null!==t)throw TypeError("Can't set "+String(t)+" as a prototype")}(r),e?t.call(n,r):n.__proto__=r,n}}():void 0),nn="[\t\n\v\f\r \u2028\u2029\ufeff]",rn=RegExp("^"+nn+nn+"*"),on=RegExp(nn+nn+"*$"),un=function(t){return function(e){var n=String(h(e));return 1&t&&(n=n.replace(rn,"")),2&t&&(n=n.replace(on,"")),n}},cn={start:un(1),end:un(2),trim:un(3)},an=bt.f,fn=P.f,ln=_.f,sn=cn.trim,pn="Number",yn=o[pn],dn=yn.prototype,hn=p(qt(dn))==pn,vn=function(t){var e,n,r,o,i,u,c,a,f=b(t,!1);if("string"==typeof f&&f.length>2)if(43===(e=(f=sn(f)).charCodeAt(0))||45===e){if(88===(n=f.charCodeAt(2))||120===n)return NaN}else if(48===e){switch(f.charCodeAt(1)){case 66:case 98:r=2,o=49;break;case 79:case 111:r=8,o=55;break;default:return+f}for(u=(i=f.slice(2)).length,c=0;c<u;c++)if((a=i.charCodeAt(c))<48||a>o)return NaN;return parseInt(i,r)}return+f};if(It(pn,!yn(" 0o1")||!yn("0b1")||yn("+0x1"))){for(var gn,bn=function(t){var e=arguments.length<1?0:t,n=this;return n instanceof bn&&(hn?i((function(){dn.valueOf.call(n)})):p(n)!=pn)?function(t,e,n){var r,o;return en&&"function"==typeof(r=e.constructor)&&r!==n&&g(o=r.prototype)&&o!==n.prototype&&en(t,o),t}(new yn(vn(e)),n,bn):vn(e)},mn=u?an(yn):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger".split(","),Sn=0;mn.length>Sn;Sn++)S(yn,gn=mn[Sn])&&!S(bn,gn)&&ln(bn,gn,fn(yn,gn));bn.prototype=dn,dn.constructor=bn,nt(o,pn,bn)}var wn={};wn[ee("toStringTag")]="z";var On="[object z]"===String(wn),En=ee("toStringTag"),jn="Arguments"==p(function(){return arguments}()),xn=On?p:function(t){var e,n,r;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=function(t,e){try{return t[e]}catch(t){}}(e=Object(t),En))?n:jn?p(e):"Object"==(r=p(e))&&"function"==typeof e.callee?"Arguments":r},Pn=On?{}.toString:function(){return"[object "+xn(this)+"]"};On||nt(Object.prototype,"toString",Pn,{unsafe:!0});var Nn=function(){var t=N(this),e="";return t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),t.dotAll&&(e+="s"),t.unicode&&(e+="u"),t.sticky&&(e+="y"),e};function In(t,e){return RegExp(t,e)}var _n,Tn,Rn={UNSUPPORTED_Y:i((function(){var t=In("a","y");return t.lastIndex=2,null!=t.exec("abcd")})),BROKEN_CARET:i((function(){var t=In("^r","gy");return t.lastIndex=2,null!=t.exec("str")}))},kn=RegExp.prototype.exec,An=String.prototype.replace,Fn=kn,Cn=(_n=/a/,Tn=/b*/g,kn.call(_n,"a"),kn.call(Tn,"a"),0!==_n.lastIndex||0!==Tn.lastIndex),Mn=Rn.UNSUPPORTED_Y||Rn.BROKEN_CARET,Dn=void 0!==/()??/.exec("")[1];(Cn||Dn||Mn)&&(Fn=function(t){var e,n,r,o,i=this,u=Mn&&i.sticky,c=Nn.call(i),a=i.source,f=0,l=t;return u&&(-1===(c=c.replace("y","")).indexOf("g")&&(c+="g"),l=String(t).slice(i.lastIndex),i.lastIndex>0&&(!i.multiline||i.multiline&&"\n"!==t[i.lastIndex-1])&&(a="(?: "+a+")",l=" "+l,f++),n=new RegExp("^(?:"+a+")",c)),Dn&&(n=new RegExp("^"+a+"$(?!\\s)",c)),Cn&&(e=i.lastIndex),r=kn.call(u?n:i,l),u?r?(r.input=r.input.slice(f),r[0]=r[0].slice(f),r.index=i.lastIndex,i.lastIndex+=r[0].length):i.lastIndex=0:Cn&&r&&(i.lastIndex=i.global?r.index+r[0].length:e),Dn&&r&&r.length>1&&An.call(r[0],n,(function(){for(o=1;o<arguments.length-2;o++)void 0===arguments[o]&&(r[o]=void 0)})),r});var Ln=Fn;Tt({target:"RegExp",proto:!0,forced:/./.exec!==Ln},{exec:Ln});var Un=ee("species"),zn=!i((function(){var t=/./;return t.exec=function(){var t=[];return t.groups={a:"7"},t},"7"!=="".replace(t,"$<a>")})),$n="$0"==="a".replace(/./,"$0"),Bn=ee("replace"),Gn=!!/./[Bn]&&""===/./[Bn]("a","$0"),Vn=!i((function(){var t=/(?:)/,e=t.exec;t.exec=function(){return e.apply(this,arguments)};var n="ab".split(t);return 2!==n.length||"a"!==n[0]||"b"!==n[1]})),Wn=function(t){return function(e,n){var r,o,i=String(h(e)),u=at(n),c=i.length;return u<0||u>=c?t?"":void 0:(r=i.charCodeAt(u))<55296||r>56319||u+1===c||(o=i.charCodeAt(u+1))<56320||o>57343?t?i.charAt(u):r:t?i.slice(u,u+2):o-56320+(r-55296<<10)+65536}},Yn={codeAt:Wn(!1),charAt:Wn(!0)}.charAt,qn=function(t,e,n){return e+(n?Yn(t,e).length:1)},Jn=function(t,e){var n=t.exec;if("function"==typeof n){var r=n.call(t,e);if("object"!=typeof r)throw TypeError("RegExp exec method returned something other than an Object or null");return r}if("RegExp"!==p(t))throw TypeError("RegExp#exec called on incompatible receiver");return Ln.call(t,e)};function Kn(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Xn(t,e)}function Xn(t,e){return Xn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},Xn(t,e)}function Qn(t){var e=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}();return function(){var n,r=Hn(t);if(e){var o=Hn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return function(t,e){if(e&&("object"===Zn(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(this,n)}}function Hn(t){return Hn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},Hn(t)}function Zn(t){return Zn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Zn(t)}function tr(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function er(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,rr(r.key),r)}}function nr(t,e,n){return e&&er(t.prototype,e),n&&er(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function rr(t){var e=function(t,e){if("object"!==Zn(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,e||"default");if("object"!==Zn(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"===Zn(e)?e:String(e)}!function(t,e,n,r){var o=ee(t),u=!i((function(){var e={};return e[o]=function(){return 7},7!=""[t](e)})),c=u&&!i((function(){var e=!1,n=/a/;return"split"===t&&((n={}).constructor={},n.constructor[Un]=function(){return n},n.flags="",n[o]=/./[o]),n.exec=function(){return e=!0,null},n[o](""),!e}));if(!u||!c||"replace"===t&&(!zn||!$n||Gn)||"split"===t&&!Vn){var a=/./[o],f=n(o,""[t],(function(t,e,n,r,o){return e.exec===Ln?u&&!o?{done:!0,value:a.call(e,n,r)}:{done:!0,value:t.call(n,e,r)}:{done:!1}}),{REPLACE_KEEPS_$0:$n,REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE:Gn}),l=f[0],s=f[1];nt(String.prototype,t,l),nt(RegExp.prototype,o,2==e?function(t,e){return s.call(t,this,e)}:function(t){return s.call(t,this)})}r&&T(RegExp.prototype[o],"sham",!0)}("match",1,(function(t,e,n){return[function(e){var n=h(this),r=null==e?void 0:e[t];return void 0!==r?r.call(e,n):new RegExp(e)[t](String(n))},function(t){var r=n(e,t,this);if(r.done)return r.value;var o=N(t),i=String(this);if(!o.global)return Jn(o,i);var u=o.unicode;o.lastIndex=0;for(var c,a=[],f=0;null!==(c=Jn(o,i));){var l=String(c[0]);a[f]=l,""===l&&(o.lastIndex=qn(i,lt(o.lastIndex),u)),f++}return 0===f?null:a}]}));var or=function(){function t(e){tr(this,t),this.w=e}return nr(t,[{key:"dispatch",value:function(t,e){var n=JSON.stringify({version:1,eventName:t,meta:e});this.w.parent.postMessage(n,"*")}}]),t}(),ir=function(){function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};tr(this,t),this.w=e,this.originFilter=n.originFilter||/.*/,this.callbacks={},this.debug=n.debug||!1,this.debug&&console.debug("Debugging is enabled")}return nr(t,[{key:"handle",value:function(t,e){if(this.debug&&console.debug("Received",t?"legacy ".concat(t):"","event",e),e.origin.match(this.originFilter))try{var n=JSON.parse(e.data),r=n.version,o=n.eventName,i=n.meta;r&&1!==r&&this.debug&&console.debug("Received event from incompatible script version");var u=this.callbacks[null!=o?o:t];return u?t===ur?u.callback(i.height):u.callback(i):void(this.debug&&console.debug("No registered handlers for ".concat(t)))}catch(t){this.debug&&console.debug("Recieved unparseable event",e.data)}else this.debug&&console.debug("Ignoring event from untrusted origin",e.origin)}},{key:"listen",value:function(t,e){this.debug&&console.debug("Registered listener for",t);var n=this.handle.bind(this,t);this.callbacks[t]={callback:e,binding:n},this.w.addEventListener("message",n,!1)}},{key:"ignore",value:function(t){var e=this.callbacks[t];e&&(this.w.removeEventListener("message",e.binding,!1),delete this.callbacks[t])}}]),t}(),ur="whitelabel:header:resize",cr="beyonk:resize-portal",ar=function(t){Kn(n,t);var e=Qn(n);function n(){return tr(this,n),e.apply(this,arguments)}return nr(n,[{key:"subscribe",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:ur;if("beyonk:portal:resize"===e)return this.debug&&console.debug("Received a request to subscribe to a legacy event,",e,"but subscribing to",cr,"instead"),void this.listen(cr,(function(e){var n=e.height;return t(n)}));this.eventName=e;var n=this.handle.bind(this,e);this.callbacks[e]={callback:t,binding:n},this.w.addEventListener("message",n,!1)}},{key:"unsubscribe",value:function(){if(this.eventName!==cr){var t=this.callbacks[this.eventName];t&&(this.w.removeEventListener("message",t.binding,!1),delete this.callbacks[this.eventName])}else this.ignore(cr)}}]),n}(ir),fr=function(t){Kn(n,t);var e=Qn(n);function n(t){var r,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:ur;return tr(this,n),(r=e.call(this,t)).eventName=o,r}return nr(n,[{key:"update",value:function(t){this.dispatch(this.eventName,{height:t})}}]),n}(or);t.RemoteEventDispatcher=or,t.RemoteEventObserver=ir,t.ResizableElementDispatcher=fr,t.ResizableElementObserver=ar,Object.defineProperty(t,"__esModule",{value:!0})})); | ||
var e,t;e=this,t=function(e){class t{constructor(e){this.w=e,this.version=1}dispatch(e,t){const s=JSON.stringify({version:this.version,eventName:e,meta:t});this.w.parent.postMessage(s,"*")}}class s{constructor(e,t={}){this.w=e,this.originFilter=t.originFilter||/.*/,this.callbacks={},this.debug=this._hasRuntimeDebuggingEnabled||t.debug||!1,this.debug&&console.debug("Debugging is enabled"),this.listening=!1,this.version=1}get _hasRuntimeDebuggingEnabled(){try{return!!localStorage.getItem("_byk_embedded_debug")}catch(e){return!1}}handle(e){if(e.origin.match(this.originFilter))try{const{version:t,eventName:s,meta:n}=JSON.parse(e.data);if(t&&t!==this.version)return void(this.debug&&console.debug(`Received v${t} event in v${this.version} observer. Ignoring.`));const o=this.callbacks[s];return o?o(s===i?n.height:n):void(this.debug&&console.debug(`No registered handlers for ${s}`))}catch(t){this.debug&&console.debug("Recieved unparseable event",e.data)}else this.debug&&console.debug("Ignoring event from untrusted origin",e.origin)}listen(e,t){this.debug&&console.debug("Registered listener for",e),this.callbacks[e]=t,this.listening||(this.binding=this.handle.bind(this),this.w.addEventListener("message",this.binding,!1),this.listening=!0,this.debug&&console.debug("Now listening for events"))}ignore(e){this.callbacks[e]&&delete this.callbacks[e],this.callbacks.length||(this.w.removeEventListener("message",this.binding,!1),this.listening=!1,this.debug&&console.debug("No more listeners, stopped listening for events"))}}const i="whitelabel:header:resize";e.RemoteEventDispatcher=t,e.RemoteEventObserver=s,e.ResizableElementDispatcher=class extends t{constructor(e){super(e),this.legacyEventName="whitelabel:header:resize"}update(e){this.dispatch(this.legacyEventName,{height:e})}},e.ResizableElementObserver=class extends s{constructor(e,t){super(e,t),this.eventName="beyonk:resize-portal"}subscribe(e){this.debug&&console.debug("Bridging","beyonk:portal:resize","to",this.eventName,"instead"),this.listen(this.eventName,(({height:t})=>e(t)))}unsubscribe(){this.ignore(this.eventName)}},Object.defineProperty(e,"__esModule",{value:!0})},"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).BeyonkEmbedded={}); |
14
index.js
@@ -1,13 +0,9 @@ | ||
import { | ||
ResizableElementDispatcher, | ||
ResizableElementObserver, | ||
RemoteEventDispatcher, | ||
RemoteEventObserver | ||
} from './lib/observers.js' | ||
import { RemoteEventDispatcher, RemoteEventObserver } from './lib/remote-events.js' | ||
import { LegacyResizableElementDispatcher, LegacyResizableElementObserver } from './lib/legacy-resize.js' | ||
export { | ||
ResizableElementDispatcher, | ||
ResizableElementObserver, | ||
RemoteEventDispatcher, | ||
RemoteEventObserver | ||
RemoteEventObserver, | ||
LegacyResizableElementObserver as ResizableElementObserver, | ||
LegacyResizableElementDispatcher as ResizableElementDispatcher | ||
} |
{ | ||
"name": "@beyonk/embedded", | ||
"version": "2.1.0", | ||
"version": "3.0.0", | ||
"description": "Embedded Beyonk Libraries", | ||
"files": [ | ||
"index.js", | ||
"lib/observers.js", | ||
"dist/observers.min.js" | ||
"lib", | ||
"dist" | ||
], | ||
@@ -17,12 +17,11 @@ "author": "Antony Jones", | ||
"@babel/runtime": "~7.12.5", | ||
"@hapi/code": "^8.0.6", | ||
"@rollup/plugin-babel": "^5.2.1", | ||
"@rollup/plugin-commonjs": "^15.1.0", | ||
"@rollup/plugin-node-resolve": "^9.0.0", | ||
"@vitest/browser": "2.1.4", | ||
"core-js": "^3.6.5", | ||
"jsdom": "^16.4.0", | ||
"mocha": "^9.2.0", | ||
"rollup": "^2.66.1", | ||
"rollup-plugin-terser": "^7.0.2", | ||
"sinon": "^12.0.1" | ||
"vite": "^5.0.0", | ||
"vitest": "^2.1.4" | ||
}, | ||
@@ -38,5 +37,5 @@ "type": "module", | ||
"scripts": { | ||
"test": "NODE_ENV=test mocha './!(node_modules)/**/**.+(spec).js'", | ||
"test": "vitest run", | ||
"build": "rollup -c 2>&1" | ||
} | ||
} |
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
No README
QualityPackage does not have a README. This may indicate a failed publish or a low quality package.
Found 1 instance in 1 package
13
8
238
1
5
11114