@playkit-js/unisphere 0.0.19-canary.0-7e412b7 → 0.0.19-canary.0-963a4ad

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -1 +1,5 @@
1
+ export declare enum PlayerEvent {
2
+ UNISPHERE_CHAPTERS_ADDED = "unisphere_chapters_added"
3
+ }
4
+
1
5
  export { }
@@ -1,3 +1,3 @@
1
1
  /*! For license information please see playkit-unisphere.js.LICENSE.txt */
2
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("KalturaPlayer",[],t):"object"==typeof exports?exports.KalturaPlayer=t():(e.KalturaPlayer=e.KalturaPlayer||{},e.KalturaPlayer.plugins=e.KalturaPlayer.plugins||{},e.KalturaPlayer.plugins.unisphere=t())}(self,(()=>(()=>{var e={51:(e,t,r)=>{var n=r(564).default;function o(){"use strict";e.exports=o=function(){return r},e.exports.__esModule=!0,e.exports.default=e.exports;var t,r={},i=Object.prototype,a=i.hasOwnProperty,u=Object.defineProperty||function(e,t,r){e[t]=r.value},c="function"==typeof Symbol?Symbol:{},s=c.iterator||"@@iterator",l=c.asyncIterator||"@@asyncIterator",f=c.toStringTag||"@@toStringTag";function p(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{p({},"")}catch(t){p=function(e,t,r){return e[t]=r}}function d(e,t,r,n){var o=t&&t.prototype instanceof w?t:w,i=Object.create(o.prototype),a=new R(n||[]);return u(i,"_invoke",{value:k(e,r,a)}),i}function h(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}r.wrap=d;var v="suspendedStart",y="suspendedYield",g="executing",m="completed",b={};function w(){}function E(){}function S(){}var P={};p(P,s,(function(){return this}));var O=Object.getPrototypeOf,I=O&&O(O(L([])));I&&I!==i&&a.call(I,s)&&(P=I);var x=S.prototype=w.prototype=Object.create(P);function _(e){["next","throw","return"].forEach((function(t){p(e,t,(function(e){return this._invoke(t,e)}))}))}function j(e,t){function r(o,i,u,c){var s=h(e[o],e,i);if("throw"!==s.type){var l=s.arg,f=l.value;return f&&"object"==n(f)&&a.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,u,c)}),(function(e){r("throw",e,u,c)})):t.resolve(f).then((function(e){l.value=e,u(l)}),(function(e){return r("throw",e,u,c)}))}c(s.arg)}var o;u(this,"_invoke",{value:function(e,n){function i(){return new t((function(t,o){r(e,n,t,o)}))}return o=o?o.then(i,i):i()}})}function k(e,r,n){var o=v;return function(i,a){if(o===g)throw Error("Generator is already running");if(o===m){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var u=n.delegate;if(u){var c=T(u,n);if(c){if(c===b)continue;return c}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===v)throw o=m,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=g;var s=h(e,r,n);if("normal"===s.type){if(o=n.done?m:y,s.arg===b)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(o=m,n.method="throw",n.arg=s.arg)}}}function T(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,T(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),b;var i=h(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,b;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,b):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,b)}function A(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function M(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function R(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(A,this),this.reset(!0)}function L(e){if(e||""===e){var r=e[s];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o<e.length;)if(a.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return i.next=i}}throw new TypeError(n(e)+" is not iterable")}return E.prototype=S,u(x,"constructor",{value:S,configurable:!0}),u(S,"constructor",{value:E,configurable:!0}),E.displayName=p(S,f,"GeneratorFunction"),r.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===E||"GeneratorFunction"===(t.displayName||t.name))},r.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,S):(e.__proto__=S,p(e,f,"GeneratorFunction")),e.prototype=Object.create(x),e},r.awrap=function(e){return{__await:e}},_(j.prototype),p(j.prototype,l,(function(){return this})),r.AsyncIterator=j,r.async=function(e,t,n,o,i){void 0===i&&(i=Promise);var a=new j(d(e,t,n,o),i);return r.isGeneratorFunction(t)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},_(x),p(x,f,"Generator"),p(x,s,(function(){return this})),p(x,"toString",(function(){return"[object Generator]"})),r.keys=function(e){var t=Object(e),r=[];for(var n in t)r.push(n);return r.reverse(),function e(){for(;r.length;){var n=r.pop();if(n in t)return e.value=n,e.done=!1,e}return e.done=!0,e}},r.values=L,R.prototype={constructor:R,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(M),!e)for(var r in this)"t"===r.charAt(0)&&a.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function n(n,o){return u.type="throw",u.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],u=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var c=a.call(i,"catchLoc"),s=a.call(i,"finallyLoc");if(c&&s){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!s)throw Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.tryLoc<=this.prev&&a.call(n,"finallyLoc")&&this.prev<n.finallyLoc){var o=n;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=e,i.arg=t,o?(this.method="next",this.next=o.finallyLoc,b):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),b},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),M(r),b}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var o=n.arg;M(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:L(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),b}},r}e.exports=o,e.exports.__esModule=!0,e.exports.default=e.exports},564:e=>{function t(r){return e.exports=t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.__esModule=!0,e.exports.default=e.exports,t(r)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},790:(e,t,r)=>{var n=r(51)();e.exports=n;try{regeneratorRuntime=n}catch(e){"object"==typeof globalThis?globalThis.regeneratorRuntime=n:Function("r","regeneratorRuntime = r")(n)}}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var i=t[n]={exports:{}};return e[n](i,i.exports,r),i.exports}return r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";const e=KalturaPlayer;function t(e,t,r,n,o,i,a){try{var u=e[i](a),c=u.value}catch(e){return void r(e)}u.done?t(c):Promise.resolve(c).then(n,o)}function n(e){return function(){var r=this,n=arguments;return new Promise((function(o,i){var a=e.apply(r,n);function u(e){t(a,o,i,u,c,"next",e)}function c(e){t(a,o,i,u,c,"throw",e)}u(void 0)}))}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function a(e){var t=function(e){if("object"!=i(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=i(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==i(t)?t:t+""}function u(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,a(n.key),n)}}function c(e,t,r){return t&&u(e.prototype,t),r&&u(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function s(e,t){if(t&&("object"==i(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}function l(e){return l=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},l(e)}function f(e,t){return f=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},f(e,t)}function p(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&f(e,t)}function d(e,t,r){return(t=a(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var h=r(790),v=r.n(h);const y=KalturaPlayer.ui.preact,g=KalturaPlayer.core;var m=function(e){return e.UPPER_BAR_ICON_SHOW="unisphere.event.player.upper-bar-icon.show",e.UPPER_BAR_ICON_CLICK="unisphere.event.player.upper-bar-icon.click",e.SIDE_PANEL_OPEN="unisphere.event.player.side-panel.open",e.SIDE_PANEL_CLOSE="unisphere.event.player.side-panel.close",e.SIDE_PANEL_TOGGLE="unisphere.event.player.side-panel.toggle",e.SET_VALUE_CURRENT_TIME="unisphere.event.player.set-value.current-time",e.CHAPTERS_ADD="unisphere.event.player.chapters.add",e.PLAYER_RESIZE="unisphere.event.player.resize",e.DISPATCH_EVENT="unisphere.event.player.dispatch-event",e.SIDE_PANEL_CLOSED="unisphere.event.player.side-panel.closed",e.SIDE_PANEL_OPENED="unisphere.event.player.side-panel.opened",e}({}),b=function(e){return e.SELECTED_CHAPTER="selectedChapter",e.CURRENT_TIME="currentTime",e.IS_PAUSED="isPaused",e.PLAYER_SESSION="player-session",e.IS_SMALL_SIZE="isSmallSize",e}(b||{}),w=function(e){var t;return(0,y.h)("div",{style:null!==(t=e.style)&&void 0!==t?t:{},id:e.id})},E=e.ui.components,S=E.Tooltip,P=E.Icon,O=function(t){var r=t.id,n=t.label,o=t.iconPath;return(0,y.h)(S,{label:n,type:"bottom"},(0,y.h)("button",{type:"button","data-testid":"playlist_pluginButton","aria-label":n,className:e.ui.style.upperBarIcon},(0,y.h)(P,{id:"unisphere-icon-".concat(r),height:32,width:32,viewBox:"0 0 32 32",path:o})))},I=function(){function e(){o(this,e)}return c(e,null,[{key:"set",value:function(t){e.workspaceInstance=t}},{key:"get",value:function(){return e.workspaceInstance}},{key:"destroy",value:function(){try{this.workspaceInstance.kill()}catch(e){}e.workspaceInstance=null}}])}();function x(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function _(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,o,i,a,u=[],c=!0,s=!1;try{if(i=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;c=!1}else for(;!(c=(n=i.call(r)).done)&&(u.push(n.value),u.length!==t);c=!0);}catch(e){s=!0,o=e}finally{try{if(!c&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(s)throw o}}return u}}(e,t)||function(e,t){if(e){if("string"==typeof e)return x(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?x(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function j(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}d(I,"workspaceInstance",null);var k=function(){function e(){o(this,e)}return c(e,null,[{key:"addToUnsubscribeMap",value:function(t){return e.unsubscribeMap.set(e.sequence,t),++e.sequence,e.sequence}},{key:"unsubscribeAll",value:function(){var t,r=function(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return j(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?j(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,o=function(){};return{s:o,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){u=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(u)throw i}}}}(e.unsubscribeMap);try{for(r.s();!(t=r.n()).done;){var n=_(t.value,2),o=n[0];(0,n[1])(),e.unsubscribeMap.delete(o)}}catch(e){r.e(e)}finally{r.f()}}},{key:"unsubscribe",value:function(t){var r=e.unsubscribeMap.get(t);r&&(r(),e.unsubscribeMap.delete(t))}}])}();function T(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(T=function(){return!!e})()}d(k,"unsubscribeMap",new Map),d(k,"sequence",-1);var A,M=function(e){function t(){return o(this,t),e=this,n=arguments,r=l(r=t),s(e,T()?Reflect.construct(r,n||[],l(e).constructor):r.apply(e,n));var e,r,n}return p(t,e),c(t)}(k);function R(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(R=function(){return!!e})()}d(M,"get",function(){var e=n(v().mark((function e(t){var r,n,o,i,a;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=t.widgetId,n=t.context,o=t.settings,i=I.get(),e.prev=2,e.next=5,null==i?void 0:i.loadRuntime(r,n,o||{});case 5:return a=e.sent,e.abrupt("return",a?null==a?void 0:a.runtime:null);case 9:return e.prev=9,e.t0=e.catch(2),e.abrupt("return",Promise.reject(e.t0));case 12:case"end":return e.stop()}}),e,null,[[2,9]])})));return function(t){return e.apply(this,arguments)}}());var L,C="unisphere.service.pub-sub",N=function(e){function t(){return o(this,t),e=this,n=arguments,r=l(r=t),s(e,R()?Reflect.construct(r,n||[],l(e).constructor):r.apply(e,n));var e,r,n}return p(t,e),c(t,null,[{key:"destroy",value:function(){t.unsubscribeAll()}}])}(k);function D(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(D=function(){return!!e})()}A=N,d(N,"subscribe",(function(e,t){var r=I.get(),n=null==r?void 0:r.getService(C);if(n){var o=n.subscribe(e,t);return A.addToUnsubscribeMap(o)}return-1})),d(N,"emit",(function(e,t){var r=I.get(),n=null==r?void 0:r.getService(C);null==n||n.emit({id:e,version:"1.0.0",payload:t})}));var U="player",$="unisphere.service.storage",B=function(e){function t(){return o(this,t),e=this,n=arguments,r=l(r=t),s(e,D()?Reflect.construct(r,n||[],l(e).constructor):r.apply(e,n));var e,r,n}return p(t,e),c(t,null,[{key:"destroy",value:function(){t.unsubscribeAll()}}])}(k);function F(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=0;t<5;++t)e+=g.Utils.Generator.uniqueId();return e}function W(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}L=B,d(B,"update",(function(e,t){var r=I.get(),n=null==r?void 0:r.getService($);null==n||n.update(U,e,t)})),d(B,"get",(function(e){var t=I.get(),r=null==t?void 0:t.getService($);return r?r.get(U,e):null})),d(B,"subscribe",(function(e,t){var r=I.get(),n=null==r?void 0:r.getService($);if(n){var o=n.subscribe(t,{namespace:U,property:e,emitLastValue:!0});L.addToUnsubscribeMap(o)}}));var G=function(){return c((function e(){o(this,e),d(this,"_disposers",new Map)}),[{key:"generateId",value:function(e){return F("".concat(e.containerType,"_container_"))}},{key:"getSidePanelsManager",value:function(e){return e.getService("sidePanelsManager")}},{key:"addDisposer",value:function(e,t){this._disposers.set(e,t)}},{key:"dispose",value:function(e){var t=this._disposers.get(e);t&&(t(),this._disposers.delete(e))}},{key:"destroy",value:function(){var e,t=function(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return W(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?W(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,o=function(){};return{s:o,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){u=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(u)throw i}}}}(this._disposers);try{for(t.s();!(e=t.n()).done;){var r=_(e.value,1)[0];this.dispose(r)}}catch(e){t.e(e)}finally{t.f()}}}])}();function K(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(K=function(){return!!e})()}var z=function(e){function t(){return o(this,t),e=this,n=arguments,r=l(r=t),s(e,K()?Reflect.construct(r,n||[],l(e).constructor):r.apply(e,n));var e,r,n}return p(t,e),c(t,[{key:"createContainer",value:function(e,t){var r,n=this,o=this.generateId(t),i=t.unisphereArea,a=t.position,u=t.expandMode,c=t.presets,s=null===(r=this.getSidePanelsManager(e))||void 0===r?void 0:r.add({label:o,panelComponent:function(){return(0,y.h)(w,{style:{height:"100%"},id:o})},presets:c,position:a,expandMode:u});return"number"==typeof s?(this.addDisposer(o,(function(){var t;null===(t=n.getSidePanelsManager(e))||void 0===t||t.remove(s)})),B.update(i,{upperBarIcon:{panelId:s}}),o):null}}])}(G);function V(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(V=function(){return!!e})()}var H=function(e){function t(){return o(this,t),e=this,n=arguments,r=l(r=t),s(e,V()?Reflect.construct(r,n||[],l(e).constructor):r.apply(e,n));var e,r,n}return p(t,e),c(t,[{key:"createContainer",value:function(e,t){var r=this.generateId(t),n=t.playerArea,o=t.presets,i=e.ui.addComponent({label:r,presets:o,area:n,get:function(){return(0,y.h)(w,{style:{width:"inherit"},id:r})}});return this.addDisposer(r,i),r}}])}(G);function q(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var Y=function(){return c((function e(t){o(this,e),d(this,"containerProducers",new Map([["sidepanel",new z],["simple",new H]])),this.player=t}),[{key:"createContainer",value:function(e){var t=this.containerProducers.get(e.containerType);return t?t.createContainer(this.player,e):null}},{key:"destroy",value:function(){var e,t=function(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return q(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?q(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,o=function(){};return{s:o,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){u=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(u)throw i}}}}(this.containerProducers);try{for(t.s();!(e=t.n()).done;){var r,n=_(e.value,1)[0];null===(r=this.containerProducers.get(n))||void 0===r||r.destroy()}}catch(e){t.e(e)}finally{t.f()}}}])}();function Z(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return J(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?J(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,o=function(){};return{s:o,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){u=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(u)throw i}}}}function J(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var X=e.ui.reducers.shell,Q=function(){return c((function e(t,r,n){o(this,e),d(this,"iconIds",new Map),d(this,"panelIds",new Set),d(this,"persistentIconIds",new Map),this.player=t,this.eventManager=r,this.logger=n,this.containerManager=new Y(t),this.currentIsSmallSize=void 0}),[{key:"upperBarManager",get:function(){return this.player.getService("upperBarManager")}},{key:"sidePanelsManager",get:function(){return this.player.getService("sidePanelsManager")}},{key:"timelineManager",get:function(){return this.player.getService("timeline")}},{key:"cuePointManager",get:function(){return this.player.getService("kalturaCuepoints")}},{key:"addEventHandlers",value:function(){var t=this,r=e.ui.redux.useStore();this.unsubscribeStore=r.subscribe((function(){var e=r.getState().shell.isSmallSize;e!==t.currentIsSmallSize&&(t.currentIsSmallSize=e,B.update(b.IS_SMALL_SIZE,e))})),N.subscribe(m.UPPER_BAR_ICON_SHOW,(function(e){var r=e.payload,n=r.id,o=r.label,i=r.order,a=r.iconPath,u=r.panelId,c=r.isPersistent;t.addUpperBarIcon(n,o,i,a,u,c)})),N.subscribe(m.SIDE_PANEL_OPEN,(function(e){var r,n=e.payload,o=n.panelId;null===(r=t.sidePanelsManager)||void 0===r||r.activateItem(o),N.emit(m.SIDE_PANEL_OPENED,n)})),N.subscribe(m.SIDE_PANEL_CLOSE,(function(e){var r,n=e.payload,o=n.panelId;null===(r=t.sidePanelsManager)||void 0===r||r.deactivateItem(o),N.emit(m.SIDE_PANEL_CLOSED,n)})),N.subscribe(m.SIDE_PANEL_TOGGLE,(function(e){var r,n,o,i=e.payload,a=i.panelId;null!==(r=t.sidePanelsManager)&&void 0!==r&&r.isItemActive(a)?(null===(n=t.sidePanelsManager)||void 0===n||n.deactivateItem(a),N.emit(m.SIDE_PANEL_CLOSED,i)):(null===(o=t.sidePanelsManager)||void 0===o||o.activateItem(a),N.emit(m.SIDE_PANEL_OPENED,i))})),N.subscribe(m.SET_VALUE_CURRENT_TIME,(function(e){var r=e.payload.currentTime;r>=0&&(t.player.currentTime=r)})),N.subscribe(m.CHAPTERS_ADD,(function(e){var r=e.payload,n=r.chapters;if(n&&n.length){var o;null===(o=t.timelineManager)||void 0===o||o.disableChapters();for(var i=0;i<n.length;++i){var a,u=n[i],c=u.title,s=+u.time;null===(a=t.timelineManager)||void 0===a||a.addKalturaCuePoint(s,"SummaryAndChapters",i,c,{onClick:function(e){var t=e.cuePoint;B.update(b.SELECTED_CHAPTER,t.id)}})}t.player.ui.store.dispatch(X.actions.updateTimeDisplayIsMinimized(!0)),t.player.dispatchEvent(new g.FakeEvent("UNISPHERE_CHAPTERS_ADDED",r))}})),N.subscribe(m.DISPATCH_EVENT,(function(e){var r=e.payload,n=r.eventName,o=r.data;t.player.dispatchEvent(new g.FakeEvent(n,o))})),this.eventManager.listen(this.player,e.core.EventType.TIME_UPDATE,(function(){B.update(b.CURRENT_TIME,"".concat(t.player.currentTime))})),this.eventManager.listen(this.player,e.ui.EventType.GUI_RESIZE,(function(){N.emit(m.PLAYER_RESIZE,{}),setTimeout((function(){N.emit(m.PLAYER_RESIZE,{})}),1e3)})),this.eventManager.listen(this.player,e.core.EventType.PAUSE,(function(){B.update(b.IS_PAUSED,!0)})),this.eventManager.listen(this.player,e.core.EventType.PLAY,(function(){B.update(b.IS_PAUSED,!1)}))}},{key:"addUpperBarIcon",value:function(e,t,r,n,o,i){var a;if(!this.iconIds.has(e)&&!this.persistentIconIds.has(e)){this.panelIds.add(o);var u=null===(a=this.upperBarManager)||void 0===a?void 0:a.add({displayName:t,ariaLabel:t,order:r,component:function(){return(0,y.h)(O,{id:e,label:t,iconPath:n})},svgIcon:{path:n},onClick:function(){N.emit(m.UPPER_BAR_ICON_CLICK,{id:e,panelId:o})}});i?this.persistentIconIds.set(e,u):this.iconIds.set(e,u)}}},{key:"isVideoClipped",value:function(){var e=this.player.config.sources,t=e.seekFrom,r=e.clipTo,n=e.duration;return"number"==typeof t&&t>0||"number"==typeof r&&r<n}},{key:"shouldLoadWidget",value:function(e){var t=e.widgetId,r=e.context;return!(t.includes("video-summary")&&"kaltura-player-list"===r&&this.isVideoClipped())}},{key:"loadWidgets",value:function(e){var t,r=this,n=Z(e);try{var o=function(){var e=t.value,n=e.widgetId,o=e.context;if(!n||!o||!r.shouldLoadWidget(e))return 1;var i,a=Z(e.containers);try{var u=function(){var t=i.value;if(!t.unisphereArea)return 1;var a=r.containerManager.createContainer(t);a&&M.get(e).then((function(e){null==e||e.assignAreaByName(t.unisphereArea,a)})).catch((function(e){r.logger.warn("Failed to load unisphere widget ".concat(n," with context ").concat(o," "),e)}))};for(a.s();!(i=a.n()).done;)u()}catch(e){a.e(e)}finally{a.f()}};for(n.s();!(t=n.n()).done;)o()}catch(e){n.e(e)}finally{n.f()}}},{key:"init",value:function(e,t){I.set(e),this.addEventHandlers(),this.loadWidgets(t)}},{key:"updateSessionData",value:function(){var e,t;B.update(b.PLAYER_SESSION,{entryId:this.player.sources.id,ks:null===(e=this.player.config.session)||void 0===e?void 0:e.ks,entryName:null===(t=this.player.sources.metadata)||void 0===t?void 0:t.name})}},{key:"reset",value:function(){var e,t=Z(this.panelIds);try{for(t.s();!(e=t.n()).done;){var r,n=e.value;if(null!==(r=this.sidePanelsManager)&&void 0!==r&&r.isItemActive(n)){this.sidePanelsManager.deactivateItem(n);break}}}catch(e){t.e(e)}finally{t.f()}var o,i=Z(this.iconIds.values());try{for(i.s();!(o=i.n()).done;){var a,u=o.value;null===(a=this.upperBarManager)||void 0===a||a.remove(u)}}catch(e){i.e(e)}finally{i.f()}this.iconIds.clear(),this.containerManager.destroy(),this.player.ui.store.dispatch(X.actions.updateTimeDisplayIsMinimized(!1))}},{key:"destroy",value:function(){this.reset(),this.containerManager.destroy();var e,t=Z(this.persistentIconIds.values());try{for(t.s();!(e=t.n()).done;){var r,n=e.value;null===(r=this.upperBarManager)||void 0===r||r.remove(n)}}catch(e){t.e(e)}finally{t.f()}N.destroy(),B.destroy(),I.destroy(),this.unsubscribeStore&&this.unsubscribeStore()}}])}(),ee="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},te=function(e){return e&&e.Math===Math&&e},re=te("object"==typeof globalThis&&globalThis)||te("object"==typeof window&&window)||te("object"==typeof self&&self)||te("object"==typeof ee&&ee)||te("object"==typeof ee&&ee)||function(){return this}()||Function("return this")(),ne={},oe=function(e){try{return!!e()}catch(e){return!0}},ie=!oe((function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]})),ae=!oe((function(){var e=function(){}.bind();return"function"!=typeof e||e.hasOwnProperty("prototype")})),ue=ae,ce=Function.prototype.call,se=ue?ce.bind(ce):function(){return ce.apply(ce,arguments)},le={},fe={}.propertyIsEnumerable,pe=Object.getOwnPropertyDescriptor,de=pe&&!fe.call({1:2},1);le.f=de?function(e){var t=pe(this,e);return!!t&&t.enumerable}:fe;var he,ve,ye=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}},ge=ae,me=Function.prototype,be=me.call,we=ge&&me.bind.bind(be,be),Ee=ge?we:function(e){return function(){return be.apply(e,arguments)}},Se=Ee,Pe=Se({}.toString),Oe=Se("".slice),Ie=function(e){return Oe(Pe(e),8,-1)},xe=oe,_e=Ie,je=Object,ke=Ee("".split),Te=xe((function(){return!je("z").propertyIsEnumerable(0)}))?function(e){return"String"===_e(e)?ke(e,""):je(e)}:je,Ae=function(e){return null==e},Me=Ae,Re=TypeError,Le=function(e){if(Me(e))throw new Re("Can't call method on "+e);return e},Ce=Te,Ne=Le,De=function(e){return Ce(Ne(e))},Ue="object"==typeof document&&document.all,$e=void 0===Ue&&void 0!==Ue?function(e){return"function"==typeof e||e===Ue}:function(e){return"function"==typeof e},Be=$e,Fe=function(e){return"object"==typeof e?null!==e:Be(e)},We=re,Ge=$e,Ke=function(e,t){return arguments.length<2?(r=We[e],Ge(r)?r:void 0):We[e]&&We[e][t];var r},ze=Ee({}.isPrototypeOf),Ve="undefined"!=typeof navigator&&String(navigator.userAgent)||"",He=re,qe=Ve,Ye=He.process,Ze=He.Deno,Je=Ye&&Ye.versions||Ze&&Ze.version,Xe=Je&&Je.v8;Xe&&(ve=(he=Xe.split("."))[0]>0&&he[0]<4?1:+(he[0]+he[1])),!ve&&qe&&(!(he=qe.match(/Edge\/(\d+)/))||he[1]>=74)&&(he=qe.match(/Chrome\/(\d+)/))&&(ve=+he[1]);var Qe=ve,et=Qe,tt=oe,rt=re.String,nt=!!Object.getOwnPropertySymbols&&!tt((function(){var e=Symbol("symbol detection");return!rt(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&et&&et<41})),ot=nt&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,it=Ke,at=$e,ut=ze,ct=Object,st=ot?function(e){return"symbol"==typeof e}:function(e){var t=it("Symbol");return at(t)&&ut(t.prototype,ct(e))},lt=String,ft=function(e){try{return lt(e)}catch(e){return"Object"}},pt=$e,dt=ft,ht=TypeError,vt=function(e){if(pt(e))return e;throw new ht(dt(e)+" is not a function")},yt=vt,gt=Ae,mt=function(e,t){var r=e[t];return gt(r)?void 0:yt(r)},bt=se,wt=$e,Et=Fe,St=TypeError,Pt={exports:{}},Ot=re,It=Object.defineProperty,xt=function(e,t){try{It(Ot,e,{value:t,configurable:!0,writable:!0})}catch(r){Ot[e]=t}return t},_t=re,jt=xt,kt="__core-js_shared__",Tt=Pt.exports=_t[kt]||jt(kt,{});(Tt.versions||(Tt.versions=[])).push({version:"3.36.1",mode:"global",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.36.1/LICENSE",source:"https://github.com/zloirock/core-js"});var At=Pt.exports,Mt=At,Rt=function(e,t){return Mt[e]||(Mt[e]=t||{})},Lt=Le,Ct=Object,Nt=function(e){return Ct(Lt(e))},Dt=Nt,Ut=Ee({}.hasOwnProperty),$t=Object.hasOwn||function(e,t){return Ut(Dt(e),t)},Bt=Ee,Ft=0,Wt=Math.random(),Gt=Bt(1..toString),Kt=function(e){return"Symbol("+(void 0===e?"":e)+")_"+Gt(++Ft+Wt,36)},zt=Rt,Vt=$t,Ht=Kt,qt=nt,Yt=ot,Zt=re.Symbol,Jt=zt("wks"),Xt=Yt?Zt.for||Zt:Zt&&Zt.withoutSetter||Ht,Qt=function(e){return Vt(Jt,e)||(Jt[e]=qt&&Vt(Zt,e)?Zt[e]:Xt("Symbol."+e)),Jt[e]},er=se,tr=Fe,rr=st,nr=mt,or=TypeError,ir=Qt("toPrimitive"),ar=function(e,t){if(!tr(e)||rr(e))return e;var r,n=nr(e,ir);if(n){if(void 0===t&&(t="default"),r=er(n,e,t),!tr(r)||rr(r))return r;throw new or("Can't convert object to primitive value")}return void 0===t&&(t="number"),function(e,t){var r,n;if("string"===t&&wt(r=e.toString)&&!Et(n=bt(r,e)))return n;if(wt(r=e.valueOf)&&!Et(n=bt(r,e)))return n;if("string"!==t&&wt(r=e.toString)&&!Et(n=bt(r,e)))return n;throw new St("Can't convert object to primitive value")}(e,t)},ur=st,cr=function(e){var t=ar(e,"string");return ur(t)?t:t+""},sr=Fe,lr=re.document,fr=sr(lr)&&sr(lr.createElement),pr=function(e){return fr?lr.createElement(e):{}},dr=pr,hr=!ie&&!oe((function(){return 7!==Object.defineProperty(dr("div"),"a",{get:function(){return 7}}).a})),vr=ie,yr=se,gr=le,mr=ye,br=De,wr=cr,Er=$t,Sr=hr,Pr=Object.getOwnPropertyDescriptor;ne.f=vr?Pr:function(e,t){if(e=br(e),t=wr(t),Sr)try{return Pr(e,t)}catch(e){}if(Er(e,t))return mr(!yr(gr.f,e,t),e[t])};var Or={},Ir=ie&&oe((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype})),xr=Fe,_r=String,jr=TypeError,kr=function(e){if(xr(e))return e;throw new jr(_r(e)+" is not an object")},Tr=ie,Ar=hr,Mr=Ir,Rr=kr,Lr=cr,Cr=TypeError,Nr=Object.defineProperty,Dr=Object.getOwnPropertyDescriptor,Ur="enumerable",$r="configurable",Br="writable";Or.f=Tr?Mr?function(e,t,r){if(Rr(e),t=Lr(t),Rr(r),"function"==typeof e&&"prototype"===t&&"value"in r&&Br in r&&!r[Br]){var n=Dr(e,t);n&&n[Br]&&(e[t]=r.value,r={configurable:$r in r?r[$r]:n[$r],enumerable:Ur in r?r[Ur]:n[Ur],writable:!1})}return Nr(e,t,r)}:Nr:function(e,t,r){if(Rr(e),t=Lr(t),Rr(r),Ar)try{return Nr(e,t,r)}catch(e){}if("get"in r||"set"in r)throw new Cr("Accessors not supported");return"value"in r&&(e[t]=r.value),e};var Fr=Or,Wr=ye,Gr=ie?function(e,t,r){return Fr.f(e,t,Wr(1,r))}:function(e,t,r){return e[t]=r,e},Kr={exports:{}},zr=ie,Vr=$t,Hr=Function.prototype,qr=zr&&Object.getOwnPropertyDescriptor,Yr=Vr(Hr,"name"),Zr={EXISTS:Yr,PROPER:Yr&&"something"===function(){}.name,CONFIGURABLE:Yr&&(!zr||zr&&qr(Hr,"name").configurable)},Jr=$e,Xr=At,Qr=Ee(Function.toString);Jr(Xr.inspectSource)||(Xr.inspectSource=function(e){return Qr(e)});var en,tn,rn,nn=Xr.inspectSource,on=$e,an=re.WeakMap,un=on(an)&&/native code/.test(String(an)),cn=Kt,sn=Rt("keys"),ln=function(e){return sn[e]||(sn[e]=cn(e))},fn={},pn=un,dn=re,hn=Fe,vn=Gr,yn=$t,gn=At,mn=ln,bn=fn,wn="Object already initialized",En=dn.TypeError,Sn=dn.WeakMap;if(pn||gn.state){var Pn=gn.state||(gn.state=new Sn);Pn.get=Pn.get,Pn.has=Pn.has,Pn.set=Pn.set,en=function(e,t){if(Pn.has(e))throw new En(wn);return t.facade=e,Pn.set(e,t),t},tn=function(e){return Pn.get(e)||{}},rn=function(e){return Pn.has(e)}}else{var On=mn("state");bn[On]=!0,en=function(e,t){if(yn(e,On))throw new En(wn);return t.facade=e,vn(e,On,t),t},tn=function(e){return yn(e,On)?e[On]:{}},rn=function(e){return yn(e,On)}}var In={set:en,get:tn,has:rn,enforce:function(e){return rn(e)?tn(e):en(e,{})},getterFor:function(e){return function(t){var r;if(!hn(t)||(r=tn(t)).type!==e)throw new En("Incompatible receiver, "+e+" required");return r}}},xn=Ee,_n=oe,jn=$e,kn=$t,Tn=ie,An=Zr.CONFIGURABLE,Mn=nn,Rn=In.enforce,Ln=In.get,Cn=String,Nn=Object.defineProperty,Dn=xn("".slice),Un=xn("".replace),$n=xn([].join),Bn=Tn&&!_n((function(){return 8!==Nn((function(){}),"length",{value:8}).length})),Fn=String(String).split("String"),Wn=Kr.exports=function(e,t,r){"Symbol("===Dn(Cn(t),0,7)&&(t="["+Un(Cn(t),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),r&&r.getter&&(t="get "+t),r&&r.setter&&(t="set "+t),(!kn(e,"name")||An&&e.name!==t)&&(Tn?Nn(e,"name",{value:t,configurable:!0}):e.name=t),Bn&&r&&kn(r,"arity")&&e.length!==r.arity&&Nn(e,"length",{value:r.arity});try{r&&kn(r,"constructor")&&r.constructor?Tn&&Nn(e,"prototype",{writable:!1}):e.prototype&&(e.prototype=void 0)}catch(e){}var n=Rn(e);return kn(n,"source")||(n.source=$n(Fn,"string"==typeof t?t:"")),e};Function.prototype.toString=Wn((function(){return jn(this)&&Ln(this).source||Mn(this)}),"toString");var Gn=Kr.exports,Kn=$e,zn=Or,Vn=Gn,Hn=xt,qn=function(e,t,r,n){n||(n={});var o=n.enumerable,i=void 0!==n.name?n.name:t;if(Kn(r)&&Vn(r,i,n),n.global)o?e[t]=r:Hn(t,r);else{try{n.unsafe?e[t]&&(o=!0):delete e[t]}catch(e){}o?e[t]=r:zn.f(e,t,{value:r,enumerable:!1,configurable:!n.nonConfigurable,writable:!n.nonWritable})}return e},Yn={},Zn=Math.ceil,Jn=Math.floor,Xn=Math.trunc||function(e){var t=+e;return(t>0?Jn:Zn)(t)},Qn=function(e){var t=+e;return t!=t||0===t?0:Xn(t)},eo=Qn,to=Math.max,ro=Math.min,no=Qn,oo=Math.min,io=function(e){var t=no(e);return t>0?oo(t,9007199254740991):0},ao=io,uo=function(e){return ao(e.length)},co=De,so=uo,lo=function(e){return function(t,r,n){var o=co(t),i=so(o);if(0===i)return!e&&-1;var a,u=function(e,t){var r=eo(e);return r<0?to(r+t,0):ro(r,t)}(n,i);if(e&&r!=r){for(;i>u;)if((a=o[u++])!=a)return!0}else for(;i>u;u++)if((e||u in o)&&o[u]===r)return e||u||0;return!e&&-1}},fo={includes:lo(!0),indexOf:lo(!1)},po=$t,ho=De,vo=fo.indexOf,yo=fn,go=Ee([].push),mo=function(e,t){var r,n=ho(e),o=0,i=[];for(r in n)!po(yo,r)&&po(n,r)&&go(i,r);for(;t.length>o;)po(n,r=t[o++])&&(~vo(i,r)||go(i,r));return i},bo=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],wo=mo,Eo=bo.concat("length","prototype");Yn.f=Object.getOwnPropertyNames||function(e){return wo(e,Eo)};var So={};So.f=Object.getOwnPropertySymbols;var Po=Ke,Oo=Yn,Io=So,xo=kr,_o=Ee([].concat),jo=Po("Reflect","ownKeys")||function(e){var t=Oo.f(xo(e)),r=Io.f;return r?_o(t,r(e)):t},ko=$t,To=jo,Ao=ne,Mo=Or,Ro=function(e,t,r){for(var n=To(t),o=Mo.f,i=Ao.f,a=0;a<n.length;a++){var u=n[a];ko(e,u)||r&&ko(r,u)||o(e,u,i(t,u))}},Lo=oe,Co=$e,No=/#|\.prototype\./,Do=function(e,t){var r=$o[Uo(e)];return r===Fo||r!==Bo&&(Co(t)?Lo(t):!!t)},Uo=Do.normalize=function(e){return String(e).replace(No,".").toLowerCase()},$o=Do.data={},Bo=Do.NATIVE="N",Fo=Do.POLYFILL="P",Wo=Do,Go=re,Ko=ne.f,zo=Gr,Vo=qn,Ho=xt,qo=Ro,Yo=Wo,Zo=function(e,t){var r,n,o,i,a,u=e.target,c=e.global,s=e.stat;if(r=c?Go:s?Go[u]||Ho(u,{}):Go[u]&&Go[u].prototype)for(n in t){if(i=t[n],o=e.dontCallGetSet?(a=Ko(r,n))&&a.value:r[n],!Yo(c?n:u+(s?".":"#")+n,e.forced)&&void 0!==o){if(typeof i==typeof o)continue;qo(i,o)}(e.sham||o&&o.sham)&&zo(i,"sham",!0),Vo(r,n,i,e)}},Jo=ae,Xo=Function.prototype,Qo=Xo.apply,ei=Xo.call,ti="object"==typeof Reflect&&Reflect.apply||(Jo?ei.bind(Qo):function(){return ei.apply(Qo,arguments)}),ri=Ee,ni=vt,oi=Fe,ii=String,ai=TypeError,ui=Fe,ci=Le,si=function(e){if(function(e){return oi(e)||null===e}(e))return e;throw new ai("Can't set "+ii(e)+" as a prototype")},li=Object.setPrototypeOf||("__proto__"in{}?function(){var e,t=!1,r={};try{(e=function(e,t,r){try{return ri(ni(Object.getOwnPropertyDescriptor(e,t)[r]))}catch(e){}}(Object.prototype,"__proto__","set"))(r,[]),t=r instanceof Array}catch(e){}return function(r,n){return ci(r),si(n),ui(r)?(t?e(r,n):r.__proto__=n,r):r}}():void 0),fi=Or.f,pi=$e,di=Fe,hi=li,vi={};vi[Qt("toStringTag")]="z";var yi="[object z]"===String(vi),gi=$e,mi=Ie,bi=Qt("toStringTag"),wi=Object,Ei="Arguments"===mi(function(){return arguments}()),Si=yi?mi:function(e){var t,r,n;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(r=function(e,t){try{return e[t]}catch(e){}}(t=wi(e),bi))?r:Ei?mi(t):"Object"===(n=mi(t))&&gi(t.callee)?"Arguments":n},Pi=Si,Oi=String,Ii=function(e){if("Symbol"===Pi(e))throw new TypeError("Cannot convert a Symbol value to a string");return Oi(e)},xi=Ii,_i=Fe,ji=Gr,ki=Error,Ti=Ee("".replace),Ai=String(new ki("zxcasd").stack),Mi=/\n\s*at [^:]*:[^\n]*/,Ri=Mi.test(Ai),Li=ye,Ci=!oe((function(){var e=new Error("a");return!("stack"in e)||(Object.defineProperty(e,"stack",Li(1,7)),7!==e.stack)})),Ni=Gr,Di=Ci,Ui=Error.captureStackTrace,$i=Ke,Bi=$t,Fi=Gr,Wi=ze,Gi=li,Ki=Ro,zi=function(e,t,r){r in e||fi(e,r,{configurable:!0,get:function(){return t[r]},set:function(e){t[r]=e}})},Vi=function(e,t,r,n){Di&&(Ui?Ui(e,t):Ni(e,"stack",function(e,t){if(Ri&&"string"==typeof e&&!ki.prepareStackTrace)for(;t--;)e=Ti(e,Mi,"");return e}(r,n)))},Hi=ie,qi=Zo,Yi=ti,Zi=function(e,t,r,n){var o="stackTraceLimit",i=n?2:1,a=e.split("."),u=a[a.length-1],c=$i.apply(null,a);if(c){var s=c.prototype;if(Bi(s,"cause")&&delete s.cause,!r)return c;var l=$i("Error"),f=t((function(e,t){var r,o,a,u,l,p,d,h=function(e,t){return void 0===e?arguments.length<2?"":t:xi(e)}(n?t:e,void 0),v=n?new c(e):new c;return void 0!==h&&Fi(v,"message",h),Vi(v,f,v.stack,2),this&&Wi(s,this)&&(a=v,u=this,l=f,hi&&pi(p=u.constructor)&&p!==l&&di(d=p.prototype)&&d!==l.prototype&&hi(a,d)),arguments.length>i&&(r=v,_i(o=arguments[i])&&"cause"in o&&ji(r,"cause",o.cause)),v}));f.prototype=s,"Error"!==u?Gi?Gi(f,l):Ki(f,l,{name:!0}):Hi&&o in c&&(zi(f,c,o),zi(f,c,"prepareStackTrace")),Ki(f,c);try{s.name!==u&&Fi(s,"name",u),s.constructor=f}catch(e){}return f}},Ji="WebAssembly",Xi=re[Ji],Qi=7!==new Error("e",{cause:7}).cause,ea=function(e,t){var r={};r[e]=Zi(e,t,Qi),qi({global:!0,constructor:!0,arity:1,forced:Qi},r)},ta=function(e,t){if(Xi&&Xi[e]){var r={};r[e]=Zi(Ji+"."+e,t,Qi),qi({target:Ji,stat:!0,constructor:!0,arity:1,forced:Qi},r)}};ea("Error",(function(e){return function(t){return Yi(e,this,arguments)}})),ea("EvalError",(function(e){return function(t){return Yi(e,this,arguments)}})),ea("RangeError",(function(e){return function(t){return Yi(e,this,arguments)}})),ea("ReferenceError",(function(e){return function(t){return Yi(e,this,arguments)}})),ea("SyntaxError",(function(e){return function(t){return Yi(e,this,arguments)}})),ea("TypeError",(function(e){return function(t){return Yi(e,this,arguments)}})),ea("URIError",(function(e){return function(t){return Yi(e,this,arguments)}})),ta("CompileError",(function(e){return function(t){return Yi(e,this,arguments)}})),ta("LinkError",(function(e){return function(t){return Yi(e,this,arguments)}})),ta("RuntimeError",(function(e){return function(t){return Yi(e,this,arguments)}})),Error;var ra=Ie,na=ie,oa=Array.isArray||function(e){return"Array"===ra(e)},ia=TypeError,aa=Object.getOwnPropertyDescriptor,ua=na&&!function(){if(void 0!==this)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(e){return e instanceof TypeError}}(),ca=TypeError,sa=Nt,la=uo,fa=ua?function(e,t){if(oa(e)&&!aa(e,"length").writable)throw new ia("Cannot set read only .length");return e.length=t}:function(e,t){return e.length=t};Zo({target:"Array",proto:!0,arity:1,forced:oe((function(){return 4294967297!==[].push.call({length:4294967296},1)}))||!function(){try{Object.defineProperty([],"length",{writable:!1}).push()}catch(e){return e instanceof TypeError}}()},{push:function(e){var t=sa(this),r=la(t),n=arguments.length;!function(e){if(e>9007199254740991)throw ca("Maximum allowed index exceeded")}(r+n);for(var o=0;o<n;o++)t[r]=arguments[o],r++;return fa(t,r),r}});var pa=mo,da=bo,ha=Object.keys||function(e){return pa(e,da)},va=ie,ya=Ee,ga=se,ma=oe,ba=ha,wa=So,Ea=le,Sa=Nt,Pa=Te,Oa=Object.assign,Ia=Object.defineProperty,xa=ya([].concat),_a=!Oa||ma((function(){if(va&&1!==Oa({b:1},Oa(Ia({},"a",{enumerable:!0,get:function(){Ia(this,"b",{value:3,enumerable:!1})}}),{b:2})).b)return!0;var e={},t={},r=Symbol("assign detection"),n="abcdefghijklmnopqrst";return e[r]=7,n.split("").forEach((function(e){t[e]=e})),7!==Oa({},e)[r]||ba(Oa({},t)).join("")!==n}))?function(e,t){for(var r=Sa(e),n=arguments.length,o=1,i=wa.f,a=Ea.f;n>o;)for(var u,c=Pa(arguments[o++]),s=i?xa(ba(c),i(c)):ba(c),l=s.length,f=0;l>f;)u=s[f++],va&&!ga(a,c,u)||(r[u]=c[u]);return r}:Oa,ja=_a;Zo({target:"Object",stat:!0,arity:2,forced:Object.assign!==ja},{assign:ja});var ka={},Ta=ie,Aa=Ir,Ma=Or,Ra=kr,La=De,Ca=ha;ka.f=Ta&&!Aa?Object.defineProperties:function(e,t){Ra(e);for(var r,n=La(t),o=Ca(t),i=o.length,a=0;i>a;)Ma.f(e,r=o[a++],n[r]);return e};var Na,Da=Ke("document","documentElement"),Ua=kr,$a=ka,Ba=bo,Fa=fn,Wa=Da,Ga=pr,Ka="prototype",za="script",Va=ln("IE_PROTO"),Ha=function(){},qa=function(e){return"<"+za+">"+e+"</"+za+">"},Ya=function(e){e.write(qa("")),e.close();var t=e.parentWindow.Object;return e=null,t},Za=function(){try{Na=new ActiveXObject("htmlfile")}catch(e){}var e,t,r;Za="undefined"!=typeof document?document.domain&&Na?Ya(Na):(t=Ga("iframe"),r="java"+za+":",t.style.display="none",Wa.appendChild(t),t.src=String(r),(e=t.contentWindow.document).open(),e.write(qa("document.F=Object")),e.close(),e.F):Ya(Na);for(var n=Ba.length;n--;)delete Za[Ka][Ba[n]];return Za()};Fa[Va]=!0;var Ja=Object.create||function(e,t){var r;return null!==e?(Ha[Ka]=Ua(e),r=new Ha,Ha[Ka]=null,r[Va]=e):r=Za(),void 0===t?r:$a.f(r,t)},Xa=Qt,Qa=Ja,eu=Or.f,tu=Xa("unscopables"),ru=Array.prototype;void 0===ru[tu]&&eu(ru,tu,{configurable:!0,value:Qa(null)});var nu,ou=fo.includes;Zo({target:"Array",proto:!0,forced:oe((function(){return!Array(1).includes()}))},{includes:function(e){return ou(this,e,arguments.length>1?arguments[1]:void 0)}}),nu="includes",ru[tu][nu]=!0;var iu,au="\t\n\v\f\r                 \u2028\u2029\ufeff",uu=Le,cu=Ii,su=au,lu=Ee("".replace),fu=RegExp("^["+su+"]+"),pu=RegExp("(^|[^"+su+"])["+su+"]+$"),du=function(e){return function(t){var r=cu(uu(t));return 1&e&&(r=lu(r,fu,"")),2&e&&(r=lu(r,pu,"$1")),r}},hu={start:du(1),end:du(2),trim:du(3)},vu=Zr.PROPER,yu=au,gu=hu.trim;Zo({target:"String",proto:!0,forced:(iu="trim",oe((function(){return!!yu[iu]()||"​…᠎"!=="​…᠎"[iu]()||vu&&yu[iu].name!==iu})))},{trim:function(){return gu(this)}});var mu,bu,wu=kr,Eu=oe,Su=re.RegExp,Pu=Eu((function(){var e=Su("a","y");return e.lastIndex=2,null!==e.exec("abcd")})),Ou=Pu||Eu((function(){return!Su("a","y").sticky})),Iu={BROKEN_CARET:Pu||Eu((function(){var e=Su("^r","gy");return e.lastIndex=2,null!==e.exec("str")})),MISSED_STICKY:Ou,UNSUPPORTED_Y:Pu},xu=oe,_u=re.RegExp,ju=xu((function(){var e=_u(".","s");return!(e.dotAll&&e.test("\n")&&"s"===e.flags)})),ku=oe,Tu=re.RegExp,Au=ku((function(){var e=Tu("(?<a>b)","g");return"b"!==e.exec("b").groups.a||"bc"!=="b".replace(e,"$<a>c")})),Mu=se,Ru=Ee,Lu=Ii,Cu=function(){var e=wu(this),t="";return e.hasIndices&&(t+="d"),e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.dotAll&&(t+="s"),e.unicode&&(t+="u"),e.unicodeSets&&(t+="v"),e.sticky&&(t+="y"),t},Nu=Iu,Du=Ja,Uu=In.get,$u=ju,Bu=Au,Fu=Rt("native-string-replace",String.prototype.replace),Wu=RegExp.prototype.exec,Gu=Wu,Ku=Ru("".charAt),zu=Ru("".indexOf),Vu=Ru("".replace),Hu=Ru("".slice),qu=(bu=/b*/g,Mu(Wu,mu=/a/,"a"),Mu(Wu,bu,"a"),0!==mu.lastIndex||0!==bu.lastIndex),Yu=Nu.BROKEN_CARET,Zu=void 0!==/()??/.exec("")[1];(qu||Zu||Yu||$u||Bu)&&(Gu=function(e){var t,r,n,o,i,a,u,c=this,s=Uu(c),l=Lu(e),f=s.raw;if(f)return f.lastIndex=c.lastIndex,t=Mu(Gu,f,l),c.lastIndex=f.lastIndex,t;var p=s.groups,d=Yu&&c.sticky,h=Mu(Cu,c),v=c.source,y=0,g=l;if(d&&(h=Vu(h,"y",""),-1===zu(h,"g")&&(h+="g"),g=Hu(l,c.lastIndex),c.lastIndex>0&&(!c.multiline||c.multiline&&"\n"!==Ku(l,c.lastIndex-1))&&(v="(?: "+v+")",g=" "+g,y++),r=new RegExp("^(?:"+v+")",h)),Zu&&(r=new RegExp("^"+v+"$(?!\\s)",h)),qu&&(n=c.lastIndex),o=Mu(Wu,d?r:c,g),d?o?(o.input=Hu(o.input,y),o[0]=Hu(o[0],y),o.index=c.lastIndex,c.lastIndex+=o[0].length):c.lastIndex=0:qu&&o&&(c.lastIndex=c.global?o.index+o[0].length:n),Zu&&o&&o.length>1&&Mu(Fu,o[0],r,(function(){for(i=1;i<arguments.length-2;i++)void 0===arguments[i]&&(o[i]=void 0)})),o&&p)for(o.groups=a=Du(null),i=0;i<p.length;i++)a[(u=p[i])[0]]=o[u[1]];return o});var Ju=Gu;Zo({target:"RegExp",proto:!0,forced:/./.exec!==Ju},{exec:Ju});var Xu=se,Qu=qn,ec=Ju,tc=oe,rc=Qt,nc=Gr,oc=rc("species"),ic=RegExp.prototype,ac=function(e,t,r,n){var o=rc(e),i=!tc((function(){var t={};return t[o]=function(){return 7},7!==""[e](t)})),a=i&&!tc((function(){var t=!1,r=/a/;return"split"===e&&((r={}).constructor={},r.constructor[oc]=function(){return r},r.flags="",r[o]=/./[o]),r.exec=function(){return t=!0,null},r[o](""),!t}));if(!i||!a||r){var u=/./[o],c=t(o,""[e],(function(e,t,r,n,o){var a=t.exec;return a===ec||a===ic.exec?i&&!o?{done:!0,value:Xu(u,t,r,n)}:{done:!0,value:Xu(e,r,t,n)}:{done:!1}}));Qu(String.prototype,e,c[0]),Qu(ic,o,c[1])}n&&nc(ic[o],"sham",!0)},uc=Object.is||function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t},cc=se,sc=kr,lc=$e,fc=Ie,pc=Ju,dc=TypeError,hc=function(e,t){var r=e.exec;if(lc(r)){var n=cc(r,e,t);return null!==n&&sc(n),n}if("RegExp"===fc(e))return cc(pc,e,t);throw new dc("RegExp#exec called on incompatible receiver")},vc=se,yc=kr,gc=Ae,mc=Le,bc=uc,wc=Ii,Ec=mt,Sc=hc;ac("search",(function(e,t,r){return[function(t){var r=mc(this),n=gc(t)?void 0:Ec(t,e);return n?vc(n,t,r):new RegExp(t)[e](wc(r))},function(e){var n=yc(this),o=wc(e),i=r(t,n,o);if(i.done)return i.value;var a=n.lastIndex;bc(a,0)||(n.lastIndex=0);var u=Sc(n,o);return bc(n.lastIndex,a)||(n.lastIndex=a),null===u?-1:u.index}]}));const Pc=e=>{const t=window.location.search.substr(1).split("&"),r=`${e}=`,n=t.filter((e=>e.search(r)>=0));return n.length>0?n[0].substring(n[0].search(r)+r.length):""};let Oc="true"===Pc("unisphereVerbose")?"log":Pc("unisphereVerbose")||"";const Ic=["log","debug"].includes(Oc)?Oc:"warn",xc=Pc("unisphereEnvironment")||"prod";let _c=localStorage.getItem("unisphereDevLoader")||null;const jc=Pc("unispherePresets")||null,kc={logLevel:Ic,loaderUrl:_c,verbose:Oc,environment:"dev"===xc?"dev":"prod",presets:jc?jc.split(",").map((e=>e.trim())):null},Tc=()=>kc;let Ac=window.unisphere;function Mc(e,t,r){return e in Ac?{value:Ac[e],isNew:!1}:(null==t||t.debug(`${e} not found on 'window.unisphere', creating with default value`,{data:{defaultValue:r}}),Ac[e]=r,{value:r,isNew:!0})}"unisphere"in window||(Ac=window.unisphere={});const Rc={logToConsole:!0,logLevel:Tc().logLevel};class Lc{static createWorkspaceLogger(e){return new Lc(e)}kill(){this._killed=!0}constructor(e){this.workspaceName=e,this._killed=!1,this._settings=Object.assign({},Rc)}getLogger(e){return this._killed&&console.warn("Logger factory is killed, returning a new logger anyway"),new Cc(this.workspaceName,e,this.getSettings.bind(this))}getSettings(){return this._settings}updateSettings(e){this._settings=Object.assign(Object.assign({},this._settings),e)}}class Cc{constructor(e,t,r){this.workspaceName=e,this.runtime=t,this._getSettings=r;const n=function(){const{value:e}=Mc("loggers",null,{interceptors:[],logMessages:[]});return e}();this._globalLoggers=n}logMessage(e,t,r,n){const o={workspaceName:this.workspaceName,runtime:this.runtime,time:(new Date).toISOString(),message:t,data:r,error:n,level:e},i=this._getSettings();if(this._globalLoggers.logMessages.push(o),this._globalLoggers.interceptors.forEach((e=>{e(o)})),i.logToConsole&&this.shouldLog(e,i.logLevel)){const t=`${o.time} [Unisphere.${o.runtime}] ${o.message}`;switch(e){case"debug":console.debug(t,o.data);break;case"log":console.log(t,o.data);break;case"warn":console.warn(t,o.data);break;case"error":console.error(t,{data:o.data,error:o.error})}}}shouldLog(e,t){const r=["debug","log","warn","error"];return r.indexOf(e)>=r.indexOf(t)}log(e,t){this.logMessage("log",e,null==t?void 0:t.data)}debug(e,t){this.logMessage("debug",e,null==t?void 0:t.data)}warn(e,t){this.logMessage("warn",e,null==t?void 0:t.data)}error(e,t){this.logMessage("error",e,null==t?void 0:t.data,null==t?void 0:t.error)}}var Nc,Dc=Ie,Uc=Ee,$c=function(e){if("Function"===Dc(e))return Uc(e)},Bc=Fe,Fc=Ie,Wc=Qt("match"),Gc=TypeError,Kc=function(e){if(function(e){var t;return Bc(e)&&(void 0!==(t=e[Wc])?!!t:"RegExp"===Fc(e))}(e))throw new Gc("The method doesn't accept regular expressions");return e},zc=Qt("match"),Vc=function(e){var t=/./;try{"/./"[e](t)}catch(r){try{return t[zc]=!1,"/./"[e](t)}catch(e){}}return!1},Hc=Zo,qc=$c,Yc=ne.f,Zc=io,Jc=Ii,Xc=Kc,Qc=Le,es=Vc,ts=qc("".slice),rs=Math.min,ns=es("startsWith");function os(e,t,r,n){return new(r||(r=Promise))((function(o,i){function a(e){try{c(n.next(e))}catch(e){i(e)}}function u(e){try{c(n.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,u)}c((n=n.apply(e,t||[])).next())}))}Hc({target:"String",proto:!0,forced:!(!ns&&(Nc=Yc(String.prototype,"startsWith"),Nc&&!Nc.writable)||ns)},{startsWith:function(e){var t=Jc(Qc(this));Xc(e);var r=Zc(rs(arguments.length>1?arguments[1]:void 0,t.length)),n=Jc(e);return ts(t,r,r+n.length)===n}}),"function"==typeof SuppressedError&&SuppressedError;var is="process"===Ie(re.process),as=Or.f,us=$t,cs=Qt("toStringTag"),ss=Gn,ls=Or,fs=Ke,ps=ie,ds=Qt("species"),hs=ze,vs=TypeError,ys=Ee,gs=oe,ms=$e,bs=Si,ws=nn,Es=function(){},Ss=Ke("Reflect","construct"),Ps=/^\s*(?:class|function)\b/,Os=ys(Ps.exec),Is=!Ps.test(Es),xs=function(e){if(!ms(e))return!1;try{return Ss(Es,[],e),!0}catch(e){return!1}},_s=function(e){if(!ms(e))return!1;switch(bs(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return Is||!!Os(Ps,ws(e))}catch(e){return!0}};_s.sham=!0;var js,ks,Ts,As,Ms=!Ss||gs((function(){var e;return xs(xs.call)||!xs(Object)||!xs((function(){e=!0}))||e}))?_s:xs,Rs=Ms,Ls=ft,Cs=TypeError,Ns=kr,Ds=Ae,Us=Qt("species"),$s=vt,Bs=ae,Fs=$c($c.bind),Ws=function(e,t){return $s(e),void 0===t?e:Bs?Fs(e,t):function(){return e.apply(t,arguments)}},Gs=Ee([].slice),Ks=TypeError,zs=/(?:ipad|iphone|ipod).*applewebkit/i.test(Ve),Vs=re,Hs=ti,qs=Ws,Ys=$e,Zs=$t,Js=oe,Xs=Da,Qs=Gs,el=pr,tl=zs,rl=is,nl=Vs.setImmediate,ol=Vs.clearImmediate,il=Vs.process,al=Vs.Dispatch,ul=Vs.Function,cl=Vs.MessageChannel,sl=Vs.String,ll=0,fl={},pl="onreadystatechange";Js((function(){js=Vs.location}));var dl=function(e){if(Zs(fl,e)){var t=fl[e];delete fl[e],t()}},hl=function(e){return function(){dl(e)}},vl=function(e){dl(e.data)},yl=function(e){Vs.postMessage(sl(e),js.protocol+"//"+js.host)};nl&&ol||(nl=function(e){!function(e,t){if(e<t)throw new Ks("Not enough arguments")}(arguments.length,1);var t=Ys(e)?e:ul(e),r=Qs(arguments,1);return fl[++ll]=function(){Hs(t,void 0,r)},ks(ll),ll},ol=function(e){delete fl[e]},rl?ks=function(e){il.nextTick(hl(e))}:al&&al.now?ks=function(e){al.now(hl(e))}:cl&&!tl?(As=(Ts=new cl).port2,Ts.port1.onmessage=vl,ks=qs(As.postMessage,As)):Vs.addEventListener&&Ys(Vs.postMessage)&&!Vs.importScripts&&js&&"file:"!==js.protocol&&!Js(yl)?(ks=yl,Vs.addEventListener("message",vl,!1)):ks=pl in el("script")?function(e){Xs.appendChild(el("script"))[pl]=function(){Xs.removeChild(this),dl(e)}}:function(e){setTimeout(hl(e),0)});var gl={set:nl,clear:ol},ml=re,bl=ie,wl=Object.getOwnPropertyDescriptor,El=function(){this.head=null,this.tail=null};El.prototype={add:function(e){var t={item:e,next:null},r=this.tail;r?r.next=t:this.head=t,this.tail=t},get:function(){var e=this.head;if(e)return null===(this.head=e.next)&&(this.tail=null),e.item}};var Sl,Pl,Ol,Il,xl,_l=El,jl=/ipad|iphone|ipod/i.test(Ve)&&"undefined"!=typeof Pebble,kl=/web0s(?!.*chrome)/i.test(Ve),Tl=re,Al=Ws,Ml=gl.set,Rl=_l,Ll=zs,Cl=jl,Nl=kl,Dl=is,Ul=Tl.MutationObserver||Tl.WebKitMutationObserver,$l=Tl.document,Bl=Tl.process,Fl=Tl.Promise,Wl=function(e){if(!bl)return ml[e];var t=wl(ml,e);return t&&t.value}("queueMicrotask");if(!Wl){var Gl=new Rl,Kl=function(){var e,t;for(Dl&&(e=Bl.domain)&&e.exit();t=Gl.get();)try{t()}catch(e){throw Gl.head&&Sl(),e}e&&e.enter()};Ll||Dl||Nl||!Ul||!$l?!Cl&&Fl&&Fl.resolve?((Il=Fl.resolve(void 0)).constructor=Fl,xl=Al(Il.then,Il),Sl=function(){xl(Kl)}):Dl?Sl=function(){Bl.nextTick(Kl)}:(Ml=Al(Ml,Tl),Sl=function(){Ml(Kl)}):(Pl=!0,Ol=$l.createTextNode(""),new Ul(Kl).observe(Ol,{characterData:!0}),Sl=function(){Ol.data=Pl=!Pl}),Wl=function(e){Gl.head||Sl(),Gl.add(e)}}var zl=Wl,Vl=function(e){try{return{error:!1,value:e()}}catch(e){return{error:!0,value:e}}},Hl=re.Promise,ql="object"==typeof Deno&&Deno&&"object"==typeof Deno.version,Yl=!ql&&!is&&"object"==typeof window&&"object"==typeof document,Zl=re,Jl=Hl,Xl=$e,Ql=Wo,ef=nn,tf=Qt,rf=Yl,nf=ql,of=Qe;Jl&&Jl.prototype;var af=tf("species"),uf=!1,cf=Xl(Zl.PromiseRejectionEvent),sf=Ql("Promise",(function(){var e=ef(Jl),t=e!==String(Jl);if(!t&&66===of)return!0;if(!of||of<51||!/native code/.test(e)){var r=new Jl((function(e){e(1)})),n=function(e){e((function(){}),(function(){}))};if((r.constructor={})[af]=n,!(uf=r.then((function(){}))instanceof n))return!0}return!t&&(rf||nf)&&!cf})),lf={CONSTRUCTOR:sf,REJECTION_EVENT:cf,SUBCLASSING:uf},ff={},pf=vt,df=TypeError,hf=function(e){var t,r;this.promise=new e((function(e,n){if(void 0!==t||void 0!==r)throw new df("Bad Promise constructor");t=e,r=n})),this.resolve=pf(t),this.reject=pf(r)};ff.f=function(e){return new hf(e)};var vf,yf,gf,mf,bf,wf,Ef,Sf=Zo,Pf=is,Of=re,If=se,xf=qn,_f=li,jf=vt,kf=$e,Tf=Fe,Af=function(e,t){var r,n=Ns(e).constructor;return void 0===n||Ds(r=Ns(n)[Us])?t:function(e){if(Rs(e))return e;throw new Cs(Ls(e)+" is not a constructor")}(r)},Mf=gl.set,Rf=zl,Lf=Vl,Cf=_l,Nf=In,Df=Hl,Uf=ff,$f="Promise",Bf=lf.CONSTRUCTOR,Ff=lf.REJECTION_EVENT,Wf=lf.SUBCLASSING,Gf=Nf.getterFor($f),Kf=Nf.set,zf=Df&&Df.prototype,Vf=Df,Hf=zf,qf=Of.TypeError,Yf=Of.document,Zf=Of.process,Jf=Uf.f,Xf=Jf,Qf=!!(Yf&&Yf.createEvent&&Of.dispatchEvent),ep="unhandledrejection",tp=function(e){var t;return!(!Tf(e)||!kf(t=e.then))&&t},rp=function(e,t){var r,n,o,i=t.value,a=1===t.state,u=a?e.ok:e.fail,c=e.resolve,s=e.reject,l=e.domain;try{u?(a||(2===t.rejection&&up(t),t.rejection=1),!0===u?r=i:(l&&l.enter(),r=u(i),l&&(l.exit(),o=!0)),r===e.promise?s(new qf("Promise-chain cycle")):(n=tp(r))?If(n,r,c,s):c(r)):s(i)}catch(e){l&&!o&&l.exit(),s(e)}},np=function(e,t){e.notified||(e.notified=!0,Rf((function(){for(var r,n=e.reactions;r=n.get();)rp(r,e);e.notified=!1,t&&!e.rejection&&ip(e)})))},op=function(e,t,r){var n,o;Qf?((n=Yf.createEvent("Event")).promise=t,n.reason=r,n.initEvent(e,!1,!0),Of.dispatchEvent(n)):n={promise:t,reason:r},!Ff&&(o=Of["on"+e])?o(n):e===ep&&function(e,t){try{1===arguments.length?console.error(e):console.error(e,t)}catch(e){}}("Unhandled promise rejection",r)},ip=function(e){If(Mf,Of,(function(){var t,r=e.facade,n=e.value;if(ap(e)&&(t=Lf((function(){Pf?Zf.emit("unhandledRejection",n,r):op(ep,r,n)})),e.rejection=Pf||ap(e)?2:1,t.error))throw t.value}))},ap=function(e){return 1!==e.rejection&&!e.parent},up=function(e){If(Mf,Of,(function(){var t=e.facade;Pf?Zf.emit("rejectionHandled",t):op("rejectionhandled",t,e.value)}))},cp=function(e,t,r){return function(n){e(t,n,r)}},sp=function(e,t,r){e.done||(e.done=!0,r&&(e=r),e.value=t,e.state=2,np(e,!0))},lp=function(e,t,r){if(!e.done){e.done=!0,r&&(e=r);try{if(e.facade===t)throw new qf("Promise can't be resolved itself");var n=tp(t);n?Rf((function(){var r={done:!1};try{If(n,t,cp(lp,r,e),cp(sp,r,e))}catch(t){sp(r,t,e)}})):(e.value=t,e.state=1,np(e,!1))}catch(t){sp({done:!1},t,e)}}};if(Bf&&(Hf=(Vf=function(e){(function(e,t){if(hs(t,e))return e;throw new vs("Incorrect invocation")})(this,Hf),jf(e),If(vf,this);var t=Gf(this);try{e(cp(lp,t),cp(sp,t))}catch(e){sp(t,e)}}).prototype,(vf=function(e){Kf(this,{type:$f,done:!1,notified:!1,parent:!1,reactions:new Cf,rejection:!1,state:0,value:void 0})}).prototype=xf(Hf,"then",(function(e,t){var r=Gf(this),n=Jf(Af(this,Vf));return r.parent=!0,n.ok=!kf(e)||e,n.fail=kf(t)&&t,n.domain=Pf?Zf.domain:void 0,0===r.state?r.reactions.add(n):Rf((function(){rp(n,r)})),n.promise})),yf=function(){var e=new vf,t=Gf(e);this.promise=e,this.resolve=cp(lp,t),this.reject=cp(sp,t)},Uf.f=Jf=function(e){return e===Vf||void 0===e?new yf(e):Xf(e)},kf(Df)&&zf!==Object.prototype)){gf=zf.then,Wf||xf(zf,"then",(function(e,t){var r=this;return new Vf((function(e,t){If(gf,r,e,t)})).then(e,t)}),{unsafe:!0});try{delete zf.constructor}catch(e){}_f&&_f(zf,Hf)}Sf({global:!0,constructor:!0,wrap:!0,forced:Bf},{Promise:Vf}),wf=$f,Ef=!1,(bf=Vf)&&!Ef&&(bf=bf.prototype),bf&&!us(bf,cs)&&as(bf,cs,{configurable:!0,value:wf}),mf=fs($f),ps&&mf&&!mf[ds]&&function(e,t,r){r.get&&ss(r.get,t,{getter:!0}),r.set&&ss(r.set,t,{setter:!0}),ls.f(e,t,r)}(mf,ds,{configurable:!0,get:function(){return this}});var fp={},pp=fp,dp=Qt("iterator"),hp=Array.prototype,vp=Si,yp=mt,gp=Ae,mp=fp,bp=Qt("iterator"),wp=function(e){if(!gp(e))return yp(e,bp)||yp(e,"@@iterator")||mp[vp(e)]},Ep=se,Sp=vt,Pp=kr,Op=ft,Ip=wp,xp=TypeError,_p=se,jp=kr,kp=mt,Tp=Ws,Ap=se,Mp=kr,Rp=ft,Lp=uo,Cp=ze,Np=wp,Dp=function(e,t,r){var n,o;jp(e);try{if(!(n=kp(e,"return"))){if("throw"===t)throw r;return r}n=_p(n,e)}catch(e){o=!0,n=e}if("throw"===t)throw r;if(o)throw n;return jp(n),r},Up=TypeError,$p=function(e,t){this.stopped=e,this.result=t},Bp=$p.prototype,Fp=function(e,t,r){var n,o,i,a,u,c,s,l,f=r&&r.that,p=!(!r||!r.AS_ENTRIES),d=!(!r||!r.IS_RECORD),h=!(!r||!r.IS_ITERATOR),v=!(!r||!r.INTERRUPTED),y=Tp(t,f),g=function(e){return n&&Dp(n,"normal",e),new $p(!0,e)},m=function(e){return p?(Mp(e),v?y(e[0],e[1],g):y(e[0],e[1])):v?y(e,g):y(e)};if(d)n=e.iterator;else if(h)n=e;else{if(!(o=Np(e)))throw new Up(Rp(e)+" is not iterable");if(void 0!==(l=o)&&(pp.Array===l||hp[dp]===l)){for(i=0,a=Lp(e);a>i;i++)if((u=m(e[i]))&&Cp(Bp,u))return u;return new $p(!1)}n=function(e,t){var r=arguments.length<2?Ip(e):t;if(Sp(r))return Pp(Ep(r,e));throw new xp(Op(e)+" is not iterable")}(e,o)}for(c=d?e.next:n.next;!(s=Ap(c,n)).done;){try{u=m(s.value)}catch(e){Dp(n,"throw",e)}if("object"==typeof u&&u&&Cp(Bp,u))return u}return new $p(!1)},Wp=Qt("iterator"),Gp=!1;try{var Kp=0,zp={next:function(){return{done:!!Kp++}},return:function(){Gp=!0}};zp[Wp]=function(){return this},Array.from(zp,(function(){throw 2}))}catch(e){}var Vp=Hl,Hp=lf.CONSTRUCTOR||!function(e,t){try{if(!t&&!Gp)return!1}catch(e){return!1}var r=!1;try{var n={};n[Wp]=function(){return{next:function(){return{done:r=!0}}}},e(n)}catch(e){}return r}((function(e){Vp.all(e).then(void 0,(function(){}))})),qp=se,Yp=vt,Zp=ff,Jp=Vl,Xp=Fp;Zo({target:"Promise",stat:!0,forced:Hp},{all:function(e){var t=this,r=Zp.f(t),n=r.resolve,o=r.reject,i=Jp((function(){var r=Yp(t.resolve),i=[],a=0,u=1;Xp(e,(function(e){var c=a++,s=!1;u++,qp(r,t,e).then((function(e){s||(s=!0,i[c]=e,--u||n(i))}),o)})),--u||n(i)}));return i.error&&o(i.value),r.promise}});var Qp=Zo,ed=lf.CONSTRUCTOR,td=Hl,rd=Ke,nd=$e,od=qn,id=td&&td.prototype;if(Qp({target:"Promise",proto:!0,forced:ed,real:!0},{catch:function(e){return this.then(void 0,e)}}),nd(td)){var ad=rd("Promise").prototype.catch;id.catch!==ad&&od(id,"catch",ad,{unsafe:!0})}var ud=se,cd=vt,sd=ff,ld=Vl,fd=Fp;Zo({target:"Promise",stat:!0,forced:Hp},{race:function(e){var t=this,r=sd.f(t),n=r.reject,o=ld((function(){var o=cd(t.resolve);fd(e,(function(e){ud(o,t,e).then(r.resolve,n)}))}));return o.error&&n(o.value),r.promise}});var pd=ff;Zo({target:"Promise",stat:!0,forced:lf.CONSTRUCTOR},{reject:function(e){var t=pd.f(this);return(0,t.reject)(e),t.promise}});var dd=kr,hd=Fe,vd=ff,yd=Zo,gd=lf.CONSTRUCTOR;Ke("Promise"),yd({target:"Promise",stat:!0,forced:gd},{resolve:function(e){return function(e,t){if(dd(e),hd(t)&&t.constructor===e)return t;var r=vd.f(e);return(0,r.resolve)(t),r.promise}(this,e)}});const md=Lc.createWorkspaceLogger("window").getLogger("fetchers"),{value:{factoriesByOwner:bd}}=Mc("factoriesByOwner",md,{factoriesByOwner:{}});function wd(e){return os(this,arguments,void 0,(function*({owner:e,url:t}){let r=bd[e];r||(md.log(`no factories found for ${e}, creating new list`),r=[],bd[e]=r);const n=r.find((e=>e.url===t));if(null==n?void 0:n.factoryModule)return md.log(`using cached factory module for ${t}`),{factoryModule:n.factoryModule,error:null};const o=r.find((e=>e.url===t));if(o)return md.log(`a request to fetch factory already in progress for ${t}, waiting for it to finish`),new Promise(((e,t)=>{o.onFetched.push(e),o.onError.push(t)}));md.log(`fetching factory module for ${t}`);const i={url:t,factoryModule:null,error:null,onFetched:[],onError:[]};r.push(i);try{const e=yield import(t);md.log(`fetched factory module for ${t}, caching it`),i.factoryModule=e,i.onFetched&&(md.log(`calling onFetched callbacks for ${t} (${i.onFetched.length} queued)`),i.onFetched.forEach((r=>{try{r(e)}catch(e){md.error(`error calling onFetched callback for ${t}`,{error:e})}}))),i.onFetched=[],i.onError=[]}catch(e){md.log(`failed to fetch factory module for ${t}, removing from list`),i.onError&&(md.log(`calling onError callbacks for ${t} (${i.onError.length} queued)`),i.onError.forEach((r=>{try{r(e)}catch(e){md.error(`error calling onError callback for ${t}`,{error:e})}}))),i.onError=[],i.onFetched=[],r.splice(r.indexOf(i),1)}return{factoryModule:i.factoryModule,error:i.error}}))}const Ed=Tc(),Sd=e=>os(void 0,void 0,void 0,(function*(){const t=Lc.createWorkspaceLogger(e.workspaceName||"").getLogger("fetch-loader");let r="",n="";if(Ed.loaderUrl?(t.log(`using custom loader url from query params '${Ed.loaderUrl}'`),n=Ed.loaderUrl):e.devLoaderUrl&&(t.log(`using custom loader url from options '${e.devLoaderUrl}'`),n=e.devLoaderUrl),n){t.log(`verifying custom loader url '${n}' url against environment runtime json. fetching runtime json...`);const o=yield((e,t)=>os(void 0,void 0,void 0,(function*(){let r,n=`${e}/runtime.json`;try{t.log(`loading runtime versions for env from '${n}'`),r=yield fetch(n).then((e=>e.json()))}catch(e){throw t.error(`error loading runtime versions for env from '${n}'`,{error:e}),new Error(`failed to load runtime versions for env from '${n}'`)}if(!r||!("domains"in r))throw new Error("invalid runtime json, 'domains' is missing in the runtime json");return r.domains})))(e.serverUrl,t),i=n.startsWith(e.serverUrl),a=o.some((e=>n.startsWith(e)));if(t.log("ensuring custom loader url is in environment artifacts or from an allowed domain",{data:{customLoaderUrl:n,serverUrl:e.serverUrl,isInEnvironmentArtifacts:i,isInAllowedDomains:a}}),!i&&!a)throw new Error(`the custom loader url '${n}' is not in the environment artifacts or from an allowed domain`);t.log(`using custom loader url '${n}'`),r=n}else t.log("using environment loader"),r=`${e.serverUrl}/loader/index.esm.js`;t.log("fetching environment unisphere loader",{data:{environmentLoaderUrl:r,options:e}});const{factoryModule:{loader:o}}=yield wd({owner:"runtime-js",url:r});if(!o)throw new Error(`failed to load dev loader from '${r}'`);return t.log("executing environment unisphere loader"),o(Object.assign({},e))}));var Pd=Zo,Od=$c,Id=ne.f,xd=io,_d=Ii,jd=Kc,kd=Le,Td=Vc,Ad=Od("".slice),Md=Math.min,Rd=Td("endsWith"),Ld=!Rd&&!!function(){var e=Id(String.prototype,"endsWith");return e&&!e.writable}();Pd({target:"String",proto:!0,forced:!Ld&&!Rd},{endsWith:function(e){var t=_d(kd(this));jd(e);var r=arguments.length>1?arguments[1]:void 0,n=t.length,o=void 0===r?n:Md(xd(r),n),i=_d(e);return Ad(t,o-i.length,o)===i}});var Cd=Ee,Nd=Qn,Dd=Ii,Ud=Le,$d=Cd("".charAt),Bd=Cd("".charCodeAt),Fd=Cd("".slice),Wd=function(e){return function(t,r){var n,o,i=Dd(Ud(t)),a=Nd(r),u=i.length;return a<0||a>=u?e?"":void 0:(n=Bd(i,a))<55296||n>56319||a+1===u||(o=Bd(i,a+1))<56320||o>57343?e?$d(i,a):n:e?Fd(i,a,a+2):o-56320+(n-55296<<10)+65536}},Gd=(Wd(!1),Wd(!0)),Kd=Ee,zd=Nt,Vd=Math.floor,Hd=Kd("".charAt),qd=Kd("".replace),Yd=Kd("".slice),Zd=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,Jd=/\$([$&'`]|\d{1,2})/g,Xd=ti,Qd=se,eh=Ee,th=ac,rh=oe,nh=kr,oh=$e,ih=Ae,ah=Qn,uh=io,ch=Ii,sh=Le,lh=function(e,t,r){return t+(r?Gd(e,t).length:1)},fh=mt,ph=function(e,t,r,n,o,i){var a=r+e.length,u=n.length,c=Jd;return void 0!==o&&(o=zd(o),c=Zd),qd(i,c,(function(i,c){var s;switch(Hd(c,0)){case"$":return"$";case"&":return e;case"`":return Yd(t,0,r);case"'":return Yd(t,a);case"<":s=o[Yd(c,1,-1)];break;default:var l=+c;if(0===l)return i;if(l>u){var f=Vd(l/10);return 0===f?i:f<=u?void 0===n[f-1]?Hd(c,1):n[f-1]+Hd(c,1):i}s=n[l-1]}return void 0===s?"":s}))},dh=hc,hh=Qt("replace"),vh=Math.max,yh=Math.min,gh=eh([].concat),mh=eh([].push),bh=eh("".indexOf),wh=eh("".slice),Eh="$0"==="a".replace(/./,"$0"),Sh=!!/./[hh]&&""===/./[hh]("a","$0");function Ph(e){return os(this,void 0,void 0,(function*(){return(yield function(){const e=window;return new Promise((t=>{var r,n;if(null===(n=null===(r=e.unisphere)||void 0===r?void 0:r.instancesManager)||void 0===n?void 0:n.get)t(e.unisphere.instancesManager.get);else{const r=()=>{document.removeEventListener("unisphere-ready",r),t(e.unisphere.instancesManager.get)};document.addEventListener("unisphere-ready",r)}}))}())(e)}))}function Oh(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(Oh=function(){return!!e})()}th("replace",(function(e,t,r){var n=Sh?"$":"$0";return[function(e,r){var n=sh(this),o=ih(e)?void 0:fh(e,hh);return o?Qd(o,e,n,r):Qd(t,ch(n),e,r)},function(e,o){var i=nh(this),a=ch(e);if("string"==typeof o&&-1===bh(o,n)&&-1===bh(o,"$<")){var u=r(t,i,a,o);if(u.done)return u.value}var c=oh(o);c||(o=ch(o));var s,l=i.global;l&&(s=i.unicode,i.lastIndex=0);for(var f,p=[];null!==(f=dh(i,a))&&(mh(p,f),l);)""===ch(f[0])&&(i.lastIndex=lh(a,uh(i.lastIndex),s));for(var d,h="",v=0,y=0;y<p.length;y++){for(var g,m=ch((f=p[y])[0]),b=vh(yh(ah(f.index),a.length),0),w=[],E=1;E<f.length;E++)mh(w,void 0===(d=f[E])?d:String(d));var S=f.groups;if(c){var P=gh([m],w,b,a);void 0!==S&&mh(P,S),g=ch(Xd(o,void 0,P))}else g=ph(m,a,b,w,S,o);b>=v&&(h+=wh(a,v,b)+g,v=b+m.length)}return h+wh(a,v)}]}),!!rh((function(){var e=/./;return e.exec=function(){var e=[];return e.groups={a:"7"},e},"7"!=="".replace(e,"$<a>")}))||!Eh||Sh),Tc();var Ih=function(e){function t(e,r,n){var i,a,u,c;return o(this,t),a=this,c=[e,r,n],u=l(u=t),d(i=s(a,Oh()?Reflect.construct(u,c||[],l(a).constructor):u.apply(a,c)),"isReady",!1),d(i,"workspaceName",""),d(i,"shouldCreateWorkspace",!1),i.unispherePluginManager=new Q(r,i.eventManager,i.logger),i.player.config.provider.unisphereLoaderUrl&&"string"==typeof i.config.workspaceName?i.workspaceName=i.config.workspaceName:(i.workspaceName=F("kaltura_player_workspace_"),i.shouldCreateWorkspace=!0),i}return p(t,e),c(t,[{key:"getWorkspace",value:(r=n(v().mark((function e(){return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this.shouldCreateWorkspace){e.next=2;break}return e.abrupt("return",Sd({serverUrl:this.player.config.provider.unisphereLoaderUrl,workspaceName:this.workspaceName,ui:{theme:"light",language:"en"}}));case 2:return e.abrupt("return",Ph(this.config.workspaceName));case 3:case"end":return e.stop()}}),e,this)}))),function(){return r.apply(this,arguments)})},{key:"loadMedia",value:function(){var e=this;this.isReady?(this.unispherePluginManager.updateSessionData(),this.unispherePluginManager.loadWidgets(this.config.widgets)):this.getWorkspace().then((function(t){e.unispherePluginManager.init(t,e.config.widgets),e.unispherePluginManager.updateSessionData(),e.isReady=!0})).catch((function(){e.logger.warn("Failed to load unisphere workspace",e.workspaceName)}))}},{key:"reset",value:function(){this.unispherePluginManager.reset()}},{key:"destroy",value:function(){this.eventManager.destroy(),this.unispherePluginManager.destroy()}}],[{key:"isValid",value:function(){return!0}}]);var r}(e.BasePlugin);d(Ih,"defaultConfig",{widgets:[]}),(0,e.registerPlugin)("unisphere",Ih)})(),{}})()));
2
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("KalturaPlayer",[],t):"object"==typeof exports?exports.KalturaPlayer=t():(e.KalturaPlayer=e.KalturaPlayer||{},e.KalturaPlayer.plugins=e.KalturaPlayer.plugins||{},e.KalturaPlayer.plugins.unisphere=t())}(self,(()=>(()=>{var e={51:(e,t,r)=>{var n=r(564).default;function o(){"use strict";e.exports=o=function(){return r},e.exports.__esModule=!0,e.exports.default=e.exports;var t,r={},i=Object.prototype,a=i.hasOwnProperty,u=Object.defineProperty||function(e,t,r){e[t]=r.value},c="function"==typeof Symbol?Symbol:{},s=c.iterator||"@@iterator",l=c.asyncIterator||"@@asyncIterator",f=c.toStringTag||"@@toStringTag";function p(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{p({},"")}catch(t){p=function(e,t,r){return e[t]=r}}function d(e,t,r,n){var o=t&&t.prototype instanceof w?t:w,i=Object.create(o.prototype),a=new R(n||[]);return u(i,"_invoke",{value:k(e,r,a)}),i}function h(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}r.wrap=d;var v="suspendedStart",y="suspendedYield",g="executing",m="completed",b={};function w(){}function E(){}function S(){}var P={};p(P,s,(function(){return this}));var O=Object.getPrototypeOf,I=O&&O(O(L([])));I&&I!==i&&a.call(I,s)&&(P=I);var x=S.prototype=w.prototype=Object.create(P);function _(e){["next","throw","return"].forEach((function(t){p(e,t,(function(e){return this._invoke(t,e)}))}))}function j(e,t){function r(o,i,u,c){var s=h(e[o],e,i);if("throw"!==s.type){var l=s.arg,f=l.value;return f&&"object"==n(f)&&a.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,u,c)}),(function(e){r("throw",e,u,c)})):t.resolve(f).then((function(e){l.value=e,u(l)}),(function(e){return r("throw",e,u,c)}))}c(s.arg)}var o;u(this,"_invoke",{value:function(e,n){function i(){return new t((function(t,o){r(e,n,t,o)}))}return o=o?o.then(i,i):i()}})}function k(e,r,n){var o=v;return function(i,a){if(o===g)throw Error("Generator is already running");if(o===m){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var u=n.delegate;if(u){var c=T(u,n);if(c){if(c===b)continue;return c}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===v)throw o=m,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=g;var s=h(e,r,n);if("normal"===s.type){if(o=n.done?m:y,s.arg===b)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(o=m,n.method="throw",n.arg=s.arg)}}}function T(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,T(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),b;var i=h(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,b;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,b):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,b)}function A(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function M(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function R(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(A,this),this.reset(!0)}function L(e){if(e||""===e){var r=e[s];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o<e.length;)if(a.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return i.next=i}}throw new TypeError(n(e)+" is not iterable")}return E.prototype=S,u(x,"constructor",{value:S,configurable:!0}),u(S,"constructor",{value:E,configurable:!0}),E.displayName=p(S,f,"GeneratorFunction"),r.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===E||"GeneratorFunction"===(t.displayName||t.name))},r.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,S):(e.__proto__=S,p(e,f,"GeneratorFunction")),e.prototype=Object.create(x),e},r.awrap=function(e){return{__await:e}},_(j.prototype),p(j.prototype,l,(function(){return this})),r.AsyncIterator=j,r.async=function(e,t,n,o,i){void 0===i&&(i=Promise);var a=new j(d(e,t,n,o),i);return r.isGeneratorFunction(t)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},_(x),p(x,f,"Generator"),p(x,s,(function(){return this})),p(x,"toString",(function(){return"[object Generator]"})),r.keys=function(e){var t=Object(e),r=[];for(var n in t)r.push(n);return r.reverse(),function e(){for(;r.length;){var n=r.pop();if(n in t)return e.value=n,e.done=!1,e}return e.done=!0,e}},r.values=L,R.prototype={constructor:R,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(M),!e)for(var r in this)"t"===r.charAt(0)&&a.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function n(n,o){return u.type="throw",u.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],u=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var c=a.call(i,"catchLoc"),s=a.call(i,"finallyLoc");if(c&&s){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!s)throw Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.tryLoc<=this.prev&&a.call(n,"finallyLoc")&&this.prev<n.finallyLoc){var o=n;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=e,i.arg=t,o?(this.method="next",this.next=o.finallyLoc,b):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),b},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),M(r),b}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var o=n.arg;M(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:L(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),b}},r}e.exports=o,e.exports.__esModule=!0,e.exports.default=e.exports},564:e=>{function t(r){return e.exports=t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.__esModule=!0,e.exports.default=e.exports,t(r)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},790:(e,t,r)=>{var n=r(51)();e.exports=n;try{regeneratorRuntime=n}catch(e){"object"==typeof globalThis?globalThis.regeneratorRuntime=n:Function("r","regeneratorRuntime = r")(n)}}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var i=t[n]={exports:{}};return e[n](i,i.exports,r),i.exports}return r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";const e=KalturaPlayer;function t(e,t,r,n,o,i,a){try{var u=e[i](a),c=u.value}catch(e){return void r(e)}u.done?t(c):Promise.resolve(c).then(n,o)}function n(e){return function(){var r=this,n=arguments;return new Promise((function(o,i){var a=e.apply(r,n);function u(e){t(a,o,i,u,c,"next",e)}function c(e){t(a,o,i,u,c,"throw",e)}u(void 0)}))}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function a(e){var t=function(e){if("object"!=i(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=i(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==i(t)?t:t+""}function u(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,a(n.key),n)}}function c(e,t,r){return t&&u(e.prototype,t),r&&u(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function s(e,t){if(t&&("object"==i(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}function l(e){return l=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},l(e)}function f(e,t){return f=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},f(e,t)}function p(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&f(e,t)}function d(e,t,r){return(t=a(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var h=r(790),v=r.n(h);const y=KalturaPlayer.ui.preact,g=KalturaPlayer.core;var m=function(e){return e.UPPER_BAR_ICON_SHOW="unisphere.event.player.upper-bar-icon.show",e.UPPER_BAR_ICON_CLICK="unisphere.event.player.upper-bar-icon.click",e.SIDE_PANEL_OPEN="unisphere.event.player.side-panel.open",e.SIDE_PANEL_CLOSE="unisphere.event.player.side-panel.close",e.SIDE_PANEL_TOGGLE="unisphere.event.player.side-panel.toggle",e.SET_VALUE_CURRENT_TIME="unisphere.event.player.set-value.current-time",e.CHAPTERS_ADD="unisphere.event.player.chapters.add",e.PLAYER_RESIZE="unisphere.event.player.resize",e.DISPATCH_EVENT="unisphere.event.player.dispatch-event",e.SIDE_PANEL_CLOSED="unisphere.event.player.side-panel.closed",e.SIDE_PANEL_OPENED="unisphere.event.player.side-panel.opened",e}({}),b=function(e){return e.UNISPHERE_CHAPTERS_ADDED="unisphere_chapters_added",e}({}),w=function(e){return e.SELECTED_CHAPTER="selectedChapter",e.CURRENT_TIME="currentTime",e.IS_PAUSED="isPaused",e.PLAYER_SESSION="player-session",e.IS_SMALL_SIZE="isSmallSize",e}(w||{}),E=function(e){var t;return(0,y.h)("div",{style:null!==(t=e.style)&&void 0!==t?t:{},id:e.id})},S=e.ui.components,P=S.Tooltip,O=S.Icon,I=function(t){var r=t.id,n=t.label,o=t.iconPath;return(0,y.h)(P,{label:n,type:"bottom"},(0,y.h)("button",{type:"button","data-testid":"playlist_pluginButton","aria-label":n,className:e.ui.style.upperBarIcon},(0,y.h)(O,{id:"unisphere-icon-".concat(r),height:32,width:32,viewBox:"0 0 32 32",path:o})))},x=function(){function e(){o(this,e)}return c(e,null,[{key:"set",value:function(t){e.workspaceInstance=t}},{key:"get",value:function(){return e.workspaceInstance}},{key:"destroy",value:function(){try{this.workspaceInstance.kill()}catch(e){}e.workspaceInstance=null}}])}();function _(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function j(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,o,i,a,u=[],c=!0,s=!1;try{if(i=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;c=!1}else for(;!(c=(n=i.call(r)).done)&&(u.push(n.value),u.length!==t);c=!0);}catch(e){s=!0,o=e}finally{try{if(!c&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(s)throw o}}return u}}(e,t)||function(e,t){if(e){if("string"==typeof e)return _(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?_(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function k(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}d(x,"workspaceInstance",null);var T=function(){function e(){o(this,e)}return c(e,null,[{key:"addToUnsubscribeMap",value:function(t){return e.unsubscribeMap.set(e.sequence,t),++e.sequence,e.sequence}},{key:"unsubscribeAll",value:function(){var t,r=function(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return k(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?k(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,o=function(){};return{s:o,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){u=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(u)throw i}}}}(e.unsubscribeMap);try{for(r.s();!(t=r.n()).done;){var n=j(t.value,2),o=n[0];(0,n[1])(),e.unsubscribeMap.delete(o)}}catch(e){r.e(e)}finally{r.f()}}},{key:"unsubscribe",value:function(t){var r=e.unsubscribeMap.get(t);r&&(r(),e.unsubscribeMap.delete(t))}}])}();function A(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(A=function(){return!!e})()}d(T,"unsubscribeMap",new Map),d(T,"sequence",-1);var M,R=function(e){function t(){return o(this,t),e=this,n=arguments,r=l(r=t),s(e,A()?Reflect.construct(r,n||[],l(e).constructor):r.apply(e,n));var e,r,n}return p(t,e),c(t)}(T);function L(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(L=function(){return!!e})()}d(R,"get",function(){var e=n(v().mark((function e(t){var r,n,o,i,a;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=t.widgetId,n=t.context,o=t.settings,i=x.get(),e.prev=2,e.next=5,null==i?void 0:i.loadRuntime(r,n,o||{});case 5:return a=e.sent,e.abrupt("return",a?null==a?void 0:a.runtime:null);case 9:return e.prev=9,e.t0=e.catch(2),e.abrupt("return",Promise.reject(e.t0));case 12:case"end":return e.stop()}}),e,null,[[2,9]])})));return function(t){return e.apply(this,arguments)}}());var C,N="unisphere.service.pub-sub",D=function(e){function t(){return o(this,t),e=this,n=arguments,r=l(r=t),s(e,L()?Reflect.construct(r,n||[],l(e).constructor):r.apply(e,n));var e,r,n}return p(t,e),c(t,null,[{key:"destroy",value:function(){t.unsubscribeAll()}}])}(T);function U(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(U=function(){return!!e})()}M=D,d(D,"subscribe",(function(e,t){var r=x.get(),n=null==r?void 0:r.getService(N);if(n){var o=n.subscribe(e,t);return M.addToUnsubscribeMap(o)}return-1})),d(D,"emit",(function(e,t){var r=x.get(),n=null==r?void 0:r.getService(N);null==n||n.emit({id:e,version:"1.0.0",payload:t})}));var $="player",B="unisphere.service.storage",F=function(e){function t(){return o(this,t),e=this,n=arguments,r=l(r=t),s(e,U()?Reflect.construct(r,n||[],l(e).constructor):r.apply(e,n));var e,r,n}return p(t,e),c(t,null,[{key:"destroy",value:function(){t.unsubscribeAll()}}])}(T);function W(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=0;t<5;++t)e+=g.Utils.Generator.uniqueId();return e}function G(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}C=F,d(F,"update",(function(e,t){var r=x.get(),n=null==r?void 0:r.getService(B);null==n||n.update($,e,t)})),d(F,"get",(function(e){var t=x.get(),r=null==t?void 0:t.getService(B);return r?r.get($,e):null})),d(F,"subscribe",(function(e,t){var r=x.get(),n=null==r?void 0:r.getService(B);if(n){var o=n.subscribe(t,{namespace:$,property:e,emitLastValue:!0});C.addToUnsubscribeMap(o)}}));var K=function(){return c((function e(){o(this,e),d(this,"_disposers",new Map)}),[{key:"generateId",value:function(e){return W("".concat(e.containerType,"_container_"))}},{key:"getSidePanelsManager",value:function(e){return e.getService("sidePanelsManager")}},{key:"addDisposer",value:function(e,t){this._disposers.set(e,t)}},{key:"dispose",value:function(e){var t=this._disposers.get(e);t&&(t(),this._disposers.delete(e))}},{key:"destroy",value:function(){var e,t=function(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return G(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?G(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,o=function(){};return{s:o,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){u=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(u)throw i}}}}(this._disposers);try{for(t.s();!(e=t.n()).done;){var r=j(e.value,1)[0];this.dispose(r)}}catch(e){t.e(e)}finally{t.f()}}}])}();function z(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(z=function(){return!!e})()}var H=function(e){function t(){return o(this,t),e=this,n=arguments,r=l(r=t),s(e,z()?Reflect.construct(r,n||[],l(e).constructor):r.apply(e,n));var e,r,n}return p(t,e),c(t,[{key:"createContainer",value:function(e,t){var r,n=this,o=this.generateId(t),i=t.unisphereArea,a=t.position,u=t.expandMode,c=t.presets,s=null===(r=this.getSidePanelsManager(e))||void 0===r?void 0:r.add({label:o,panelComponent:function(){return(0,y.h)(E,{style:{height:"100%"},id:o})},presets:c,position:a,expandMode:u});return"number"==typeof s?(this.addDisposer(o,(function(){var t;null===(t=n.getSidePanelsManager(e))||void 0===t||t.remove(s)})),F.update(i,{upperBarIcon:{panelId:s}}),o):null}}])}(K);function V(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(V=function(){return!!e})()}var q=function(e){function t(){return o(this,t),e=this,n=arguments,r=l(r=t),s(e,V()?Reflect.construct(r,n||[],l(e).constructor):r.apply(e,n));var e,r,n}return p(t,e),c(t,[{key:"createContainer",value:function(e,t){var r=this.generateId(t),n=t.playerArea,o=t.presets,i=e.ui.addComponent({label:r,presets:o,area:n,get:function(){return(0,y.h)(E,{style:{width:"inherit"},id:r})}});return this.addDisposer(r,i),r}}])}(K);function Y(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var Z=function(){return c((function e(t){o(this,e),d(this,"containerProducers",new Map([["sidepanel",new H],["simple",new q]])),this.player=t}),[{key:"createContainer",value:function(e){var t=this.containerProducers.get(e.containerType);return t?t.createContainer(this.player,e):null}},{key:"destroy",value:function(){var e,t=function(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return Y(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Y(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,o=function(){};return{s:o,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){u=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(u)throw i}}}}(this.containerProducers);try{for(t.s();!(e=t.n()).done;){var r,n=j(e.value,1)[0];null===(r=this.containerProducers.get(n))||void 0===r||r.destroy()}}catch(e){t.e(e)}finally{t.f()}}}])}();function J(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return X(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?X(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,o=function(){};return{s:o,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){u=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(u)throw i}}}}function X(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var Q=e.ui.reducers.shell,ee=function(){return c((function e(t,r,n){o(this,e),d(this,"iconIds",new Map),d(this,"panelIds",new Set),d(this,"persistentIconIds",new Map),this.player=t,this.eventManager=r,this.logger=n,this.containerManager=new Z(t),this.currentIsSmallSize=void 0}),[{key:"upperBarManager",get:function(){return this.player.getService("upperBarManager")}},{key:"sidePanelsManager",get:function(){return this.player.getService("sidePanelsManager")}},{key:"timelineManager",get:function(){return this.player.getService("timeline")}},{key:"cuePointManager",get:function(){return this.player.getService("kalturaCuepoints")}},{key:"addEventHandlers",value:function(){var t=this,r=e.ui.redux.useStore();this.unsubscribeStore=r.subscribe((function(){var e=r.getState().shell.isSmallSize;e!==t.currentIsSmallSize&&(t.currentIsSmallSize=e,F.update(w.IS_SMALL_SIZE,e))})),D.subscribe(m.UPPER_BAR_ICON_SHOW,(function(e){var r=e.payload,n=r.id,o=r.label,i=r.order,a=r.iconPath,u=r.panelId,c=r.isPersistent;t.addUpperBarIcon(n,o,i,a,u,c)})),D.subscribe(m.SIDE_PANEL_OPEN,(function(e){var r,n=e.payload,o=n.panelId;null===(r=t.sidePanelsManager)||void 0===r||r.activateItem(o),D.emit(m.SIDE_PANEL_OPENED,n)})),D.subscribe(m.SIDE_PANEL_CLOSE,(function(e){var r,n=e.payload,o=n.panelId;null===(r=t.sidePanelsManager)||void 0===r||r.deactivateItem(o),D.emit(m.SIDE_PANEL_CLOSED,n)})),D.subscribe(m.SIDE_PANEL_TOGGLE,(function(e){var r,n,o,i=e.payload,a=i.panelId;null!==(r=t.sidePanelsManager)&&void 0!==r&&r.isItemActive(a)?(null===(n=t.sidePanelsManager)||void 0===n||n.deactivateItem(a),D.emit(m.SIDE_PANEL_CLOSED,i)):(null===(o=t.sidePanelsManager)||void 0===o||o.activateItem(a),D.emit(m.SIDE_PANEL_OPENED,i))})),D.subscribe(m.SET_VALUE_CURRENT_TIME,(function(e){var r=e.payload.currentTime;r>=0&&(t.player.currentTime=r)})),D.subscribe(m.CHAPTERS_ADD,(function(e){var r=e.payload,n=r.chapters;if(n&&n.length){var o;null===(o=t.timelineManager)||void 0===o||o.disableChapters();for(var i=0;i<n.length;++i){var a,u=n[i],c=u.title,s=+u.time;null===(a=t.timelineManager)||void 0===a||a.addKalturaCuePoint(s,"SummaryAndChapters",i,c,{onClick:function(e){var t=e.cuePoint;F.update(w.SELECTED_CHAPTER,t.id)}})}t.player.dispatchEvent(new g.FakeEvent(b.UNISPHERE_CHAPTERS_ADDED,r))}})),D.subscribe(m.DISPATCH_EVENT,(function(e){var r=e.payload,n=r.eventName,o=r.data;t.player.dispatchEvent(new g.FakeEvent(n,o))})),this.eventManager.listen(this.player,e.core.EventType.TIME_UPDATE,(function(){F.update(w.CURRENT_TIME,"".concat(t.player.currentTime))})),this.eventManager.listen(this.player,e.ui.EventType.GUI_RESIZE,(function(){D.emit(m.PLAYER_RESIZE,{}),setTimeout((function(){D.emit(m.PLAYER_RESIZE,{})}),1e3)})),this.eventManager.listen(this.player,e.core.EventType.PAUSE,(function(){F.update(w.IS_PAUSED,!0)})),this.eventManager.listen(this.player,e.core.EventType.PLAY,(function(){F.update(w.IS_PAUSED,!1)}))}},{key:"addUpperBarIcon",value:function(e,t,r,n,o,i){var a;if(!this.iconIds.has(e)&&!this.persistentIconIds.has(e)){this.panelIds.add(o);var u=null===(a=this.upperBarManager)||void 0===a?void 0:a.add({displayName:t,ariaLabel:t,order:r,component:function(){return(0,y.h)(I,{id:e,label:t,iconPath:n})},svgIcon:{path:n},onClick:function(){D.emit(m.UPPER_BAR_ICON_CLICK,{id:e,panelId:o})}});i?this.persistentIconIds.set(e,u):this.iconIds.set(e,u)}}},{key:"isVideoClipped",value:function(){var e=this.player.config.sources,t=e.seekFrom,r=e.clipTo,n=e.duration;return"number"==typeof t&&t>0||"number"==typeof r&&r<n}},{key:"shouldLoadWidget",value:function(e){var t=e.widgetId,r=e.context;return!(t.includes("video-summary")&&"kaltura-player-list"===r&&this.isVideoClipped())}},{key:"loadWidgets",value:function(e){var t,r=this,n=J(e);try{var o=function(){var e=t.value,n=e.widgetId,o=e.context;if(!n||!o||!r.shouldLoadWidget(e))return 1;var i,a=J(e.containers);try{var u=function(){var t=i.value;if(!t.unisphereArea)return 1;var a=r.containerManager.createContainer(t);a&&R.get(e).then((function(e){null==e||e.assignAreaByName(t.unisphereArea,a)})).catch((function(e){r.logger.warn("Failed to load unisphere widget ".concat(n," with context ").concat(o," "),e)}))};for(a.s();!(i=a.n()).done;)u()}catch(e){a.e(e)}finally{a.f()}};for(n.s();!(t=n.n()).done;)o()}catch(e){n.e(e)}finally{n.f()}}},{key:"init",value:function(e,t){x.set(e),this.addEventHandlers(),this.loadWidgets(t)}},{key:"updateSessionData",value:function(){var e,t;F.update(w.PLAYER_SESSION,{entryId:this.player.sources.id,ks:null===(e=this.player.config.session)||void 0===e?void 0:e.ks,entryName:null===(t=this.player.sources.metadata)||void 0===t?void 0:t.name})}},{key:"reset",value:function(){var e,t=J(this.panelIds);try{for(t.s();!(e=t.n()).done;){var r,n=e.value;if(null!==(r=this.sidePanelsManager)&&void 0!==r&&r.isItemActive(n)){this.sidePanelsManager.deactivateItem(n);break}}}catch(e){t.e(e)}finally{t.f()}var o,i=J(this.iconIds.values());try{for(i.s();!(o=i.n()).done;){var a,u=o.value;null===(a=this.upperBarManager)||void 0===a||a.remove(u)}}catch(e){i.e(e)}finally{i.f()}this.iconIds.clear(),this.containerManager.destroy(),this.player.ui.store.dispatch(Q.actions.updateTimeDisplayIsMinimized(!1))}},{key:"destroy",value:function(){this.reset(),this.containerManager.destroy();var e,t=J(this.persistentIconIds.values());try{for(t.s();!(e=t.n()).done;){var r,n=e.value;null===(r=this.upperBarManager)||void 0===r||r.remove(n)}}catch(e){t.e(e)}finally{t.f()}D.destroy(),F.destroy(),x.destroy(),this.unsubscribeStore&&this.unsubscribeStore()}}])}(),te="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},re=function(e){return e&&e.Math===Math&&e},ne=re("object"==typeof globalThis&&globalThis)||re("object"==typeof window&&window)||re("object"==typeof self&&self)||re("object"==typeof te&&te)||re("object"==typeof te&&te)||function(){return this}()||Function("return this")(),oe={},ie=function(e){try{return!!e()}catch(e){return!0}},ae=!ie((function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]})),ue=!ie((function(){var e=function(){}.bind();return"function"!=typeof e||e.hasOwnProperty("prototype")})),ce=ue,se=Function.prototype.call,le=ce?se.bind(se):function(){return se.apply(se,arguments)},fe={},pe={}.propertyIsEnumerable,de=Object.getOwnPropertyDescriptor,he=de&&!pe.call({1:2},1);fe.f=he?function(e){var t=de(this,e);return!!t&&t.enumerable}:pe;var ve,ye,ge=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}},me=ue,be=Function.prototype,we=be.call,Ee=me&&be.bind.bind(we,we),Se=me?Ee:function(e){return function(){return we.apply(e,arguments)}},Pe=Se,Oe=Pe({}.toString),Ie=Pe("".slice),xe=function(e){return Ie(Oe(e),8,-1)},_e=ie,je=xe,ke=Object,Te=Se("".split),Ae=_e((function(){return!ke("z").propertyIsEnumerable(0)}))?function(e){return"String"===je(e)?Te(e,""):ke(e)}:ke,Me=function(e){return null==e},Re=Me,Le=TypeError,Ce=function(e){if(Re(e))throw new Le("Can't call method on "+e);return e},Ne=Ae,De=Ce,Ue=function(e){return Ne(De(e))},$e="object"==typeof document&&document.all,Be=void 0===$e&&void 0!==$e?function(e){return"function"==typeof e||e===$e}:function(e){return"function"==typeof e},Fe=Be,We=function(e){return"object"==typeof e?null!==e:Fe(e)},Ge=ne,Ke=Be,ze=function(e,t){return arguments.length<2?(r=Ge[e],Ke(r)?r:void 0):Ge[e]&&Ge[e][t];var r},He=Se({}.isPrototypeOf),Ve="undefined"!=typeof navigator&&String(navigator.userAgent)||"",qe=ne,Ye=Ve,Ze=qe.process,Je=qe.Deno,Xe=Ze&&Ze.versions||Je&&Je.version,Qe=Xe&&Xe.v8;Qe&&(ye=(ve=Qe.split("."))[0]>0&&ve[0]<4?1:+(ve[0]+ve[1])),!ye&&Ye&&(!(ve=Ye.match(/Edge\/(\d+)/))||ve[1]>=74)&&(ve=Ye.match(/Chrome\/(\d+)/))&&(ye=+ve[1]);var et=ye,tt=et,rt=ie,nt=ne.String,ot=!!Object.getOwnPropertySymbols&&!rt((function(){var e=Symbol("symbol detection");return!nt(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&tt&&tt<41})),it=ot&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,at=ze,ut=Be,ct=He,st=Object,lt=it?function(e){return"symbol"==typeof e}:function(e){var t=at("Symbol");return ut(t)&&ct(t.prototype,st(e))},ft=String,pt=function(e){try{return ft(e)}catch(e){return"Object"}},dt=Be,ht=pt,vt=TypeError,yt=function(e){if(dt(e))return e;throw new vt(ht(e)+" is not a function")},gt=yt,mt=Me,bt=function(e,t){var r=e[t];return mt(r)?void 0:gt(r)},wt=le,Et=Be,St=We,Pt=TypeError,Ot={exports:{}},It=ne,xt=Object.defineProperty,_t=function(e,t){try{xt(It,e,{value:t,configurable:!0,writable:!0})}catch(r){It[e]=t}return t},jt=ne,kt=_t,Tt="__core-js_shared__",At=Ot.exports=jt[Tt]||kt(Tt,{});(At.versions||(At.versions=[])).push({version:"3.36.1",mode:"global",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.36.1/LICENSE",source:"https://github.com/zloirock/core-js"});var Mt=Ot.exports,Rt=Mt,Lt=function(e,t){return Rt[e]||(Rt[e]=t||{})},Ct=Ce,Nt=Object,Dt=function(e){return Nt(Ct(e))},Ut=Dt,$t=Se({}.hasOwnProperty),Bt=Object.hasOwn||function(e,t){return $t(Ut(e),t)},Ft=Se,Wt=0,Gt=Math.random(),Kt=Ft(1..toString),zt=function(e){return"Symbol("+(void 0===e?"":e)+")_"+Kt(++Wt+Gt,36)},Ht=Lt,Vt=Bt,qt=zt,Yt=ot,Zt=it,Jt=ne.Symbol,Xt=Ht("wks"),Qt=Zt?Jt.for||Jt:Jt&&Jt.withoutSetter||qt,er=function(e){return Vt(Xt,e)||(Xt[e]=Yt&&Vt(Jt,e)?Jt[e]:Qt("Symbol."+e)),Xt[e]},tr=le,rr=We,nr=lt,or=bt,ir=TypeError,ar=er("toPrimitive"),ur=function(e,t){if(!rr(e)||nr(e))return e;var r,n=or(e,ar);if(n){if(void 0===t&&(t="default"),r=tr(n,e,t),!rr(r)||nr(r))return r;throw new ir("Can't convert object to primitive value")}return void 0===t&&(t="number"),function(e,t){var r,n;if("string"===t&&Et(r=e.toString)&&!St(n=wt(r,e)))return n;if(Et(r=e.valueOf)&&!St(n=wt(r,e)))return n;if("string"!==t&&Et(r=e.toString)&&!St(n=wt(r,e)))return n;throw new Pt("Can't convert object to primitive value")}(e,t)},cr=lt,sr=function(e){var t=ur(e,"string");return cr(t)?t:t+""},lr=We,fr=ne.document,pr=lr(fr)&&lr(fr.createElement),dr=function(e){return pr?fr.createElement(e):{}},hr=dr,vr=!ae&&!ie((function(){return 7!==Object.defineProperty(hr("div"),"a",{get:function(){return 7}}).a})),yr=ae,gr=le,mr=fe,br=ge,wr=Ue,Er=sr,Sr=Bt,Pr=vr,Or=Object.getOwnPropertyDescriptor;oe.f=yr?Or:function(e,t){if(e=wr(e),t=Er(t),Pr)try{return Or(e,t)}catch(e){}if(Sr(e,t))return br(!gr(mr.f,e,t),e[t])};var Ir={},xr=ae&&ie((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype})),_r=We,jr=String,kr=TypeError,Tr=function(e){if(_r(e))return e;throw new kr(jr(e)+" is not an object")},Ar=ae,Mr=vr,Rr=xr,Lr=Tr,Cr=sr,Nr=TypeError,Dr=Object.defineProperty,Ur=Object.getOwnPropertyDescriptor,$r="enumerable",Br="configurable",Fr="writable";Ir.f=Ar?Rr?function(e,t,r){if(Lr(e),t=Cr(t),Lr(r),"function"==typeof e&&"prototype"===t&&"value"in r&&Fr in r&&!r[Fr]){var n=Ur(e,t);n&&n[Fr]&&(e[t]=r.value,r={configurable:Br in r?r[Br]:n[Br],enumerable:$r in r?r[$r]:n[$r],writable:!1})}return Dr(e,t,r)}:Dr:function(e,t,r){if(Lr(e),t=Cr(t),Lr(r),Mr)try{return Dr(e,t,r)}catch(e){}if("get"in r||"set"in r)throw new Nr("Accessors not supported");return"value"in r&&(e[t]=r.value),e};var Wr=Ir,Gr=ge,Kr=ae?function(e,t,r){return Wr.f(e,t,Gr(1,r))}:function(e,t,r){return e[t]=r,e},zr={exports:{}},Hr=ae,Vr=Bt,qr=Function.prototype,Yr=Hr&&Object.getOwnPropertyDescriptor,Zr=Vr(qr,"name"),Jr={EXISTS:Zr,PROPER:Zr&&"something"===function(){}.name,CONFIGURABLE:Zr&&(!Hr||Hr&&Yr(qr,"name").configurable)},Xr=Be,Qr=Mt,en=Se(Function.toString);Xr(Qr.inspectSource)||(Qr.inspectSource=function(e){return en(e)});var tn,rn,nn,on=Qr.inspectSource,an=Be,un=ne.WeakMap,cn=an(un)&&/native code/.test(String(un)),sn=zt,ln=Lt("keys"),fn=function(e){return ln[e]||(ln[e]=sn(e))},pn={},dn=cn,hn=ne,vn=We,yn=Kr,gn=Bt,mn=Mt,bn=fn,wn=pn,En="Object already initialized",Sn=hn.TypeError,Pn=hn.WeakMap;if(dn||mn.state){var On=mn.state||(mn.state=new Pn);On.get=On.get,On.has=On.has,On.set=On.set,tn=function(e,t){if(On.has(e))throw new Sn(En);return t.facade=e,On.set(e,t),t},rn=function(e){return On.get(e)||{}},nn=function(e){return On.has(e)}}else{var In=bn("state");wn[In]=!0,tn=function(e,t){if(gn(e,In))throw new Sn(En);return t.facade=e,yn(e,In,t),t},rn=function(e){return gn(e,In)?e[In]:{}},nn=function(e){return gn(e,In)}}var xn={set:tn,get:rn,has:nn,enforce:function(e){return nn(e)?rn(e):tn(e,{})},getterFor:function(e){return function(t){var r;if(!vn(t)||(r=rn(t)).type!==e)throw new Sn("Incompatible receiver, "+e+" required");return r}}},_n=Se,jn=ie,kn=Be,Tn=Bt,An=ae,Mn=Jr.CONFIGURABLE,Rn=on,Ln=xn.enforce,Cn=xn.get,Nn=String,Dn=Object.defineProperty,Un=_n("".slice),$n=_n("".replace),Bn=_n([].join),Fn=An&&!jn((function(){return 8!==Dn((function(){}),"length",{value:8}).length})),Wn=String(String).split("String"),Gn=zr.exports=function(e,t,r){"Symbol("===Un(Nn(t),0,7)&&(t="["+$n(Nn(t),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),r&&r.getter&&(t="get "+t),r&&r.setter&&(t="set "+t),(!Tn(e,"name")||Mn&&e.name!==t)&&(An?Dn(e,"name",{value:t,configurable:!0}):e.name=t),Fn&&r&&Tn(r,"arity")&&e.length!==r.arity&&Dn(e,"length",{value:r.arity});try{r&&Tn(r,"constructor")&&r.constructor?An&&Dn(e,"prototype",{writable:!1}):e.prototype&&(e.prototype=void 0)}catch(e){}var n=Ln(e);return Tn(n,"source")||(n.source=Bn(Wn,"string"==typeof t?t:"")),e};Function.prototype.toString=Gn((function(){return kn(this)&&Cn(this).source||Rn(this)}),"toString");var Kn=zr.exports,zn=Be,Hn=Ir,Vn=Kn,qn=_t,Yn=function(e,t,r,n){n||(n={});var o=n.enumerable,i=void 0!==n.name?n.name:t;if(zn(r)&&Vn(r,i,n),n.global)o?e[t]=r:qn(t,r);else{try{n.unsafe?e[t]&&(o=!0):delete e[t]}catch(e){}o?e[t]=r:Hn.f(e,t,{value:r,enumerable:!1,configurable:!n.nonConfigurable,writable:!n.nonWritable})}return e},Zn={},Jn=Math.ceil,Xn=Math.floor,Qn=Math.trunc||function(e){var t=+e;return(t>0?Xn:Jn)(t)},eo=function(e){var t=+e;return t!=t||0===t?0:Qn(t)},to=eo,ro=Math.max,no=Math.min,oo=eo,io=Math.min,ao=function(e){var t=oo(e);return t>0?io(t,9007199254740991):0},uo=ao,co=function(e){return uo(e.length)},so=Ue,lo=co,fo=function(e){return function(t,r,n){var o=so(t),i=lo(o);if(0===i)return!e&&-1;var a,u=function(e,t){var r=to(e);return r<0?ro(r+t,0):no(r,t)}(n,i);if(e&&r!=r){for(;i>u;)if((a=o[u++])!=a)return!0}else for(;i>u;u++)if((e||u in o)&&o[u]===r)return e||u||0;return!e&&-1}},po={includes:fo(!0),indexOf:fo(!1)},ho=Bt,vo=Ue,yo=po.indexOf,go=pn,mo=Se([].push),bo=function(e,t){var r,n=vo(e),o=0,i=[];for(r in n)!ho(go,r)&&ho(n,r)&&mo(i,r);for(;t.length>o;)ho(n,r=t[o++])&&(~yo(i,r)||mo(i,r));return i},wo=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],Eo=bo,So=wo.concat("length","prototype");Zn.f=Object.getOwnPropertyNames||function(e){return Eo(e,So)};var Po={};Po.f=Object.getOwnPropertySymbols;var Oo=ze,Io=Zn,xo=Po,_o=Tr,jo=Se([].concat),ko=Oo("Reflect","ownKeys")||function(e){var t=Io.f(_o(e)),r=xo.f;return r?jo(t,r(e)):t},To=Bt,Ao=ko,Mo=oe,Ro=Ir,Lo=function(e,t,r){for(var n=Ao(t),o=Ro.f,i=Mo.f,a=0;a<n.length;a++){var u=n[a];To(e,u)||r&&To(r,u)||o(e,u,i(t,u))}},Co=ie,No=Be,Do=/#|\.prototype\./,Uo=function(e,t){var r=Bo[$o(e)];return r===Wo||r!==Fo&&(No(t)?Co(t):!!t)},$o=Uo.normalize=function(e){return String(e).replace(Do,".").toLowerCase()},Bo=Uo.data={},Fo=Uo.NATIVE="N",Wo=Uo.POLYFILL="P",Go=Uo,Ko=ne,zo=oe.f,Ho=Kr,Vo=Yn,qo=_t,Yo=Lo,Zo=Go,Jo=function(e,t){var r,n,o,i,a,u=e.target,c=e.global,s=e.stat;if(r=c?Ko:s?Ko[u]||qo(u,{}):Ko[u]&&Ko[u].prototype)for(n in t){if(i=t[n],o=e.dontCallGetSet?(a=zo(r,n))&&a.value:r[n],!Zo(c?n:u+(s?".":"#")+n,e.forced)&&void 0!==o){if(typeof i==typeof o)continue;Yo(i,o)}(e.sham||o&&o.sham)&&Ho(i,"sham",!0),Vo(r,n,i,e)}},Xo=ue,Qo=Function.prototype,ei=Qo.apply,ti=Qo.call,ri="object"==typeof Reflect&&Reflect.apply||(Xo?ti.bind(ei):function(){return ti.apply(ei,arguments)}),ni=Se,oi=yt,ii=We,ai=String,ui=TypeError,ci=We,si=Ce,li=function(e){if(function(e){return ii(e)||null===e}(e))return e;throw new ui("Can't set "+ai(e)+" as a prototype")},fi=Object.setPrototypeOf||("__proto__"in{}?function(){var e,t=!1,r={};try{(e=function(e,t,r){try{return ni(oi(Object.getOwnPropertyDescriptor(e,t)[r]))}catch(e){}}(Object.prototype,"__proto__","set"))(r,[]),t=r instanceof Array}catch(e){}return function(r,n){return si(r),li(n),ci(r)?(t?e(r,n):r.__proto__=n,r):r}}():void 0),pi=Ir.f,di=Be,hi=We,vi=fi,yi={};yi[er("toStringTag")]="z";var gi="[object z]"===String(yi),mi=Be,bi=xe,wi=er("toStringTag"),Ei=Object,Si="Arguments"===bi(function(){return arguments}()),Pi=gi?bi:function(e){var t,r,n;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(r=function(e,t){try{return e[t]}catch(e){}}(t=Ei(e),wi))?r:Si?bi(t):"Object"===(n=bi(t))&&mi(t.callee)?"Arguments":n},Oi=Pi,Ii=String,xi=function(e){if("Symbol"===Oi(e))throw new TypeError("Cannot convert a Symbol value to a string");return Ii(e)},_i=xi,ji=We,ki=Kr,Ti=Error,Ai=Se("".replace),Mi=String(new Ti("zxcasd").stack),Ri=/\n\s*at [^:]*:[^\n]*/,Li=Ri.test(Mi),Ci=ge,Ni=!ie((function(){var e=new Error("a");return!("stack"in e)||(Object.defineProperty(e,"stack",Ci(1,7)),7!==e.stack)})),Di=Kr,Ui=Ni,$i=Error.captureStackTrace,Bi=ze,Fi=Bt,Wi=Kr,Gi=He,Ki=fi,zi=Lo,Hi=function(e,t,r){r in e||pi(e,r,{configurable:!0,get:function(){return t[r]},set:function(e){t[r]=e}})},Vi=function(e,t,r,n){Ui&&($i?$i(e,t):Di(e,"stack",function(e,t){if(Li&&"string"==typeof e&&!Ti.prepareStackTrace)for(;t--;)e=Ai(e,Ri,"");return e}(r,n)))},qi=ae,Yi=Jo,Zi=ri,Ji=function(e,t,r,n){var o="stackTraceLimit",i=n?2:1,a=e.split("."),u=a[a.length-1],c=Bi.apply(null,a);if(c){var s=c.prototype;if(Fi(s,"cause")&&delete s.cause,!r)return c;var l=Bi("Error"),f=t((function(e,t){var r,o,a,u,l,p,d,h=function(e,t){return void 0===e?arguments.length<2?"":t:_i(e)}(n?t:e,void 0),v=n?new c(e):new c;return void 0!==h&&Wi(v,"message",h),Vi(v,f,v.stack,2),this&&Gi(s,this)&&(a=v,u=this,l=f,vi&&di(p=u.constructor)&&p!==l&&hi(d=p.prototype)&&d!==l.prototype&&vi(a,d)),arguments.length>i&&(r=v,ji(o=arguments[i])&&"cause"in o&&ki(r,"cause",o.cause)),v}));f.prototype=s,"Error"!==u?Ki?Ki(f,l):zi(f,l,{name:!0}):qi&&o in c&&(Hi(f,c,o),Hi(f,c,"prepareStackTrace")),zi(f,c);try{s.name!==u&&Wi(s,"name",u),s.constructor=f}catch(e){}return f}},Xi="WebAssembly",Qi=ne[Xi],ea=7!==new Error("e",{cause:7}).cause,ta=function(e,t){var r={};r[e]=Ji(e,t,ea),Yi({global:!0,constructor:!0,arity:1,forced:ea},r)},ra=function(e,t){if(Qi&&Qi[e]){var r={};r[e]=Ji(Xi+"."+e,t,ea),Yi({target:Xi,stat:!0,constructor:!0,arity:1,forced:ea},r)}};ta("Error",(function(e){return function(t){return Zi(e,this,arguments)}})),ta("EvalError",(function(e){return function(t){return Zi(e,this,arguments)}})),ta("RangeError",(function(e){return function(t){return Zi(e,this,arguments)}})),ta("ReferenceError",(function(e){return function(t){return Zi(e,this,arguments)}})),ta("SyntaxError",(function(e){return function(t){return Zi(e,this,arguments)}})),ta("TypeError",(function(e){return function(t){return Zi(e,this,arguments)}})),ta("URIError",(function(e){return function(t){return Zi(e,this,arguments)}})),ra("CompileError",(function(e){return function(t){return Zi(e,this,arguments)}})),ra("LinkError",(function(e){return function(t){return Zi(e,this,arguments)}})),ra("RuntimeError",(function(e){return function(t){return Zi(e,this,arguments)}})),Error;var na=xe,oa=ae,ia=Array.isArray||function(e){return"Array"===na(e)},aa=TypeError,ua=Object.getOwnPropertyDescriptor,ca=oa&&!function(){if(void 0!==this)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(e){return e instanceof TypeError}}(),sa=TypeError,la=Dt,fa=co,pa=ca?function(e,t){if(ia(e)&&!ua(e,"length").writable)throw new aa("Cannot set read only .length");return e.length=t}:function(e,t){return e.length=t};Jo({target:"Array",proto:!0,arity:1,forced:ie((function(){return 4294967297!==[].push.call({length:4294967296},1)}))||!function(){try{Object.defineProperty([],"length",{writable:!1}).push()}catch(e){return e instanceof TypeError}}()},{push:function(e){var t=la(this),r=fa(t),n=arguments.length;!function(e){if(e>9007199254740991)throw sa("Maximum allowed index exceeded")}(r+n);for(var o=0;o<n;o++)t[r]=arguments[o],r++;return pa(t,r),r}});var da=bo,ha=wo,va=Object.keys||function(e){return da(e,ha)},ya=ae,ga=Se,ma=le,ba=ie,wa=va,Ea=Po,Sa=fe,Pa=Dt,Oa=Ae,Ia=Object.assign,xa=Object.defineProperty,_a=ga([].concat),ja=!Ia||ba((function(){if(ya&&1!==Ia({b:1},Ia(xa({},"a",{enumerable:!0,get:function(){xa(this,"b",{value:3,enumerable:!1})}}),{b:2})).b)return!0;var e={},t={},r=Symbol("assign detection"),n="abcdefghijklmnopqrst";return e[r]=7,n.split("").forEach((function(e){t[e]=e})),7!==Ia({},e)[r]||wa(Ia({},t)).join("")!==n}))?function(e,t){for(var r=Pa(e),n=arguments.length,o=1,i=Ea.f,a=Sa.f;n>o;)for(var u,c=Oa(arguments[o++]),s=i?_a(wa(c),i(c)):wa(c),l=s.length,f=0;l>f;)u=s[f++],ya&&!ma(a,c,u)||(r[u]=c[u]);return r}:Ia,ka=ja;Jo({target:"Object",stat:!0,arity:2,forced:Object.assign!==ka},{assign:ka});var Ta={},Aa=ae,Ma=xr,Ra=Ir,La=Tr,Ca=Ue,Na=va;Ta.f=Aa&&!Ma?Object.defineProperties:function(e,t){La(e);for(var r,n=Ca(t),o=Na(t),i=o.length,a=0;i>a;)Ra.f(e,r=o[a++],n[r]);return e};var Da,Ua=ze("document","documentElement"),$a=Tr,Ba=Ta,Fa=wo,Wa=pn,Ga=Ua,Ka=dr,za="prototype",Ha="script",Va=fn("IE_PROTO"),qa=function(){},Ya=function(e){return"<"+Ha+">"+e+"</"+Ha+">"},Za=function(e){e.write(Ya("")),e.close();var t=e.parentWindow.Object;return e=null,t},Ja=function(){try{Da=new ActiveXObject("htmlfile")}catch(e){}var e,t,r;Ja="undefined"!=typeof document?document.domain&&Da?Za(Da):(t=Ka("iframe"),r="java"+Ha+":",t.style.display="none",Ga.appendChild(t),t.src=String(r),(e=t.contentWindow.document).open(),e.write(Ya("document.F=Object")),e.close(),e.F):Za(Da);for(var n=Fa.length;n--;)delete Ja[za][Fa[n]];return Ja()};Wa[Va]=!0;var Xa=Object.create||function(e,t){var r;return null!==e?(qa[za]=$a(e),r=new qa,qa[za]=null,r[Va]=e):r=Ja(),void 0===t?r:Ba.f(r,t)},Qa=er,eu=Xa,tu=Ir.f,ru=Qa("unscopables"),nu=Array.prototype;void 0===nu[ru]&&tu(nu,ru,{configurable:!0,value:eu(null)});var ou,iu=po.includes;Jo({target:"Array",proto:!0,forced:ie((function(){return!Array(1).includes()}))},{includes:function(e){return iu(this,e,arguments.length>1?arguments[1]:void 0)}}),ou="includes",nu[ru][ou]=!0;var au,uu="\t\n\v\f\r                 \u2028\u2029\ufeff",cu=Ce,su=xi,lu=uu,fu=Se("".replace),pu=RegExp("^["+lu+"]+"),du=RegExp("(^|[^"+lu+"])["+lu+"]+$"),hu=function(e){return function(t){var r=su(cu(t));return 1&e&&(r=fu(r,pu,"")),2&e&&(r=fu(r,du,"$1")),r}},vu={start:hu(1),end:hu(2),trim:hu(3)},yu=Jr.PROPER,gu=uu,mu=vu.trim;Jo({target:"String",proto:!0,forced:(au="trim",ie((function(){return!!gu[au]()||"​…᠎"!=="​…᠎"[au]()||yu&&gu[au].name!==au})))},{trim:function(){return mu(this)}});var bu,wu,Eu=Tr,Su=ie,Pu=ne.RegExp,Ou=Su((function(){var e=Pu("a","y");return e.lastIndex=2,null!==e.exec("abcd")})),Iu=Ou||Su((function(){return!Pu("a","y").sticky})),xu={BROKEN_CARET:Ou||Su((function(){var e=Pu("^r","gy");return e.lastIndex=2,null!==e.exec("str")})),MISSED_STICKY:Iu,UNSUPPORTED_Y:Ou},_u=ie,ju=ne.RegExp,ku=_u((function(){var e=ju(".","s");return!(e.dotAll&&e.test("\n")&&"s"===e.flags)})),Tu=ie,Au=ne.RegExp,Mu=Tu((function(){var e=Au("(?<a>b)","g");return"b"!==e.exec("b").groups.a||"bc"!=="b".replace(e,"$<a>c")})),Ru=le,Lu=Se,Cu=xi,Nu=function(){var e=Eu(this),t="";return e.hasIndices&&(t+="d"),e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.dotAll&&(t+="s"),e.unicode&&(t+="u"),e.unicodeSets&&(t+="v"),e.sticky&&(t+="y"),t},Du=xu,Uu=Xa,$u=xn.get,Bu=ku,Fu=Mu,Wu=Lt("native-string-replace",String.prototype.replace),Gu=RegExp.prototype.exec,Ku=Gu,zu=Lu("".charAt),Hu=Lu("".indexOf),Vu=Lu("".replace),qu=Lu("".slice),Yu=(wu=/b*/g,Ru(Gu,bu=/a/,"a"),Ru(Gu,wu,"a"),0!==bu.lastIndex||0!==wu.lastIndex),Zu=Du.BROKEN_CARET,Ju=void 0!==/()??/.exec("")[1];(Yu||Ju||Zu||Bu||Fu)&&(Ku=function(e){var t,r,n,o,i,a,u,c=this,s=$u(c),l=Cu(e),f=s.raw;if(f)return f.lastIndex=c.lastIndex,t=Ru(Ku,f,l),c.lastIndex=f.lastIndex,t;var p=s.groups,d=Zu&&c.sticky,h=Ru(Nu,c),v=c.source,y=0,g=l;if(d&&(h=Vu(h,"y",""),-1===Hu(h,"g")&&(h+="g"),g=qu(l,c.lastIndex),c.lastIndex>0&&(!c.multiline||c.multiline&&"\n"!==zu(l,c.lastIndex-1))&&(v="(?: "+v+")",g=" "+g,y++),r=new RegExp("^(?:"+v+")",h)),Ju&&(r=new RegExp("^"+v+"$(?!\\s)",h)),Yu&&(n=c.lastIndex),o=Ru(Gu,d?r:c,g),d?o?(o.input=qu(o.input,y),o[0]=qu(o[0],y),o.index=c.lastIndex,c.lastIndex+=o[0].length):c.lastIndex=0:Yu&&o&&(c.lastIndex=c.global?o.index+o[0].length:n),Ju&&o&&o.length>1&&Ru(Wu,o[0],r,(function(){for(i=1;i<arguments.length-2;i++)void 0===arguments[i]&&(o[i]=void 0)})),o&&p)for(o.groups=a=Uu(null),i=0;i<p.length;i++)a[(u=p[i])[0]]=o[u[1]];return o});var Xu=Ku;Jo({target:"RegExp",proto:!0,forced:/./.exec!==Xu},{exec:Xu});var Qu=le,ec=Yn,tc=Xu,rc=ie,nc=er,oc=Kr,ic=nc("species"),ac=RegExp.prototype,uc=function(e,t,r,n){var o=nc(e),i=!rc((function(){var t={};return t[o]=function(){return 7},7!==""[e](t)})),a=i&&!rc((function(){var t=!1,r=/a/;return"split"===e&&((r={}).constructor={},r.constructor[ic]=function(){return r},r.flags="",r[o]=/./[o]),r.exec=function(){return t=!0,null},r[o](""),!t}));if(!i||!a||r){var u=/./[o],c=t(o,""[e],(function(e,t,r,n,o){var a=t.exec;return a===tc||a===ac.exec?i&&!o?{done:!0,value:Qu(u,t,r,n)}:{done:!0,value:Qu(e,r,t,n)}:{done:!1}}));ec(String.prototype,e,c[0]),ec(ac,o,c[1])}n&&oc(ac[o],"sham",!0)},cc=Object.is||function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t},sc=le,lc=Tr,fc=Be,pc=xe,dc=Xu,hc=TypeError,vc=function(e,t){var r=e.exec;if(fc(r)){var n=sc(r,e,t);return null!==n&&lc(n),n}if("RegExp"===pc(e))return sc(dc,e,t);throw new hc("RegExp#exec called on incompatible receiver")},yc=le,gc=Tr,mc=Me,bc=Ce,wc=cc,Ec=xi,Sc=bt,Pc=vc;uc("search",(function(e,t,r){return[function(t){var r=bc(this),n=mc(t)?void 0:Sc(t,e);return n?yc(n,t,r):new RegExp(t)[e](Ec(r))},function(e){var n=gc(this),o=Ec(e),i=r(t,n,o);if(i.done)return i.value;var a=n.lastIndex;wc(a,0)||(n.lastIndex=0);var u=Pc(n,o);return wc(n.lastIndex,a)||(n.lastIndex=a),null===u?-1:u.index}]}));const Oc=e=>{const t=window.location.search.substr(1).split("&"),r=`${e}=`,n=t.filter((e=>e.search(r)>=0));return n.length>0?n[0].substring(n[0].search(r)+r.length):""};let Ic="true"===Oc("unisphereVerbose")?"log":Oc("unisphereVerbose")||"";const xc=["log","debug"].includes(Ic)?Ic:"warn",_c=Oc("unisphereEnvironment")||"prod";let jc=localStorage.getItem("unisphereDevLoader")||null;const kc=Oc("unispherePresets")||null,Tc={logLevel:xc,loaderUrl:jc,verbose:Ic,environment:"dev"===_c?"dev":"prod",presets:kc?kc.split(",").map((e=>e.trim())):null},Ac=()=>Tc;let Mc=window.unisphere;function Rc(e,t,r){return e in Mc?{value:Mc[e],isNew:!1}:(null==t||t.debug(`${e} not found on 'window.unisphere', creating with default value`,{data:{defaultValue:r}}),Mc[e]=r,{value:r,isNew:!0})}"unisphere"in window||(Mc=window.unisphere={});const Lc={logToConsole:!0,logLevel:Ac().logLevel};class Cc{static createWorkspaceLogger(e){return new Cc(e)}kill(){this._killed=!0}constructor(e){this.workspaceName=e,this._killed=!1,this._settings=Object.assign({},Lc)}getLogger(e){return this._killed&&console.warn("Logger factory is killed, returning a new logger anyway"),new Nc(this.workspaceName,e,this.getSettings.bind(this))}getSettings(){return this._settings}updateSettings(e){this._settings=Object.assign(Object.assign({},this._settings),e)}}class Nc{constructor(e,t,r){this.workspaceName=e,this.runtime=t,this._getSettings=r;const n=function(){const{value:e}=Rc("loggers",null,{interceptors:[],logMessages:[]});return e}();this._globalLoggers=n}logMessage(e,t,r,n){const o={workspaceName:this.workspaceName,runtime:this.runtime,time:(new Date).toISOString(),message:t,data:r,error:n,level:e},i=this._getSettings();if(this._globalLoggers.logMessages.push(o),this._globalLoggers.interceptors.forEach((e=>{e(o)})),i.logToConsole&&this.shouldLog(e,i.logLevel)){const t=`${o.time} [Unisphere.${o.runtime}] ${o.message}`;switch(e){case"debug":console.debug(t,o.data);break;case"log":console.log(t,o.data);break;case"warn":console.warn(t,o.data);break;case"error":console.error(t,{data:o.data,error:o.error})}}}shouldLog(e,t){const r=["debug","log","warn","error"];return r.indexOf(e)>=r.indexOf(t)}log(e,t){this.logMessage("log",e,null==t?void 0:t.data)}debug(e,t){this.logMessage("debug",e,null==t?void 0:t.data)}warn(e,t){this.logMessage("warn",e,null==t?void 0:t.data)}error(e,t){this.logMessage("error",e,null==t?void 0:t.data,null==t?void 0:t.error)}}var Dc,Uc=xe,$c=Se,Bc=function(e){if("Function"===Uc(e))return $c(e)},Fc=We,Wc=xe,Gc=er("match"),Kc=TypeError,zc=function(e){if(function(e){var t;return Fc(e)&&(void 0!==(t=e[Gc])?!!t:"RegExp"===Wc(e))}(e))throw new Kc("The method doesn't accept regular expressions");return e},Hc=er("match"),Vc=function(e){var t=/./;try{"/./"[e](t)}catch(r){try{return t[Hc]=!1,"/./"[e](t)}catch(e){}}return!1},qc=Jo,Yc=Bc,Zc=oe.f,Jc=ao,Xc=xi,Qc=zc,es=Ce,ts=Vc,rs=Yc("".slice),ns=Math.min,os=ts("startsWith");function is(e,t,r,n){return new(r||(r=Promise))((function(o,i){function a(e){try{c(n.next(e))}catch(e){i(e)}}function u(e){try{c(n.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,u)}c((n=n.apply(e,t||[])).next())}))}qc({target:"String",proto:!0,forced:!(!os&&(Dc=Zc(String.prototype,"startsWith"),Dc&&!Dc.writable)||os)},{startsWith:function(e){var t=Xc(es(this));Qc(e);var r=Jc(ns(arguments.length>1?arguments[1]:void 0,t.length)),n=Xc(e);return rs(t,r,r+n.length)===n}}),"function"==typeof SuppressedError&&SuppressedError;var as="process"===xe(ne.process),us=Ir.f,cs=Bt,ss=er("toStringTag"),ls=Kn,fs=Ir,ps=ze,ds=ae,hs=er("species"),vs=He,ys=TypeError,gs=Se,ms=ie,bs=Be,ws=Pi,Es=on,Ss=function(){},Ps=ze("Reflect","construct"),Os=/^\s*(?:class|function)\b/,Is=gs(Os.exec),xs=!Os.test(Ss),_s=function(e){if(!bs(e))return!1;try{return Ps(Ss,[],e),!0}catch(e){return!1}},js=function(e){if(!bs(e))return!1;switch(ws(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return xs||!!Is(Os,Es(e))}catch(e){return!0}};js.sham=!0;var ks,Ts,As,Ms,Rs=!Ps||ms((function(){var e;return _s(_s.call)||!_s(Object)||!_s((function(){e=!0}))||e}))?js:_s,Ls=Rs,Cs=pt,Ns=TypeError,Ds=Tr,Us=Me,$s=er("species"),Bs=yt,Fs=ue,Ws=Bc(Bc.bind),Gs=function(e,t){return Bs(e),void 0===t?e:Fs?Ws(e,t):function(){return e.apply(t,arguments)}},Ks=Se([].slice),zs=TypeError,Hs=/(?:ipad|iphone|ipod).*applewebkit/i.test(Ve),Vs=ne,qs=ri,Ys=Gs,Zs=Be,Js=Bt,Xs=ie,Qs=Ua,el=Ks,tl=dr,rl=Hs,nl=as,ol=Vs.setImmediate,il=Vs.clearImmediate,al=Vs.process,ul=Vs.Dispatch,cl=Vs.Function,sl=Vs.MessageChannel,ll=Vs.String,fl=0,pl={},dl="onreadystatechange";Xs((function(){ks=Vs.location}));var hl=function(e){if(Js(pl,e)){var t=pl[e];delete pl[e],t()}},vl=function(e){return function(){hl(e)}},yl=function(e){hl(e.data)},gl=function(e){Vs.postMessage(ll(e),ks.protocol+"//"+ks.host)};ol&&il||(ol=function(e){!function(e,t){if(e<t)throw new zs("Not enough arguments")}(arguments.length,1);var t=Zs(e)?e:cl(e),r=el(arguments,1);return pl[++fl]=function(){qs(t,void 0,r)},Ts(fl),fl},il=function(e){delete pl[e]},nl?Ts=function(e){al.nextTick(vl(e))}:ul&&ul.now?Ts=function(e){ul.now(vl(e))}:sl&&!rl?(Ms=(As=new sl).port2,As.port1.onmessage=yl,Ts=Ys(Ms.postMessage,Ms)):Vs.addEventListener&&Zs(Vs.postMessage)&&!Vs.importScripts&&ks&&"file:"!==ks.protocol&&!Xs(gl)?(Ts=gl,Vs.addEventListener("message",yl,!1)):Ts=dl in tl("script")?function(e){Qs.appendChild(tl("script"))[dl]=function(){Qs.removeChild(this),hl(e)}}:function(e){setTimeout(vl(e),0)});var ml={set:ol,clear:il},bl=ne,wl=ae,El=Object.getOwnPropertyDescriptor,Sl=function(){this.head=null,this.tail=null};Sl.prototype={add:function(e){var t={item:e,next:null},r=this.tail;r?r.next=t:this.head=t,this.tail=t},get:function(){var e=this.head;if(e)return null===(this.head=e.next)&&(this.tail=null),e.item}};var Pl,Ol,Il,xl,_l,jl=Sl,kl=/ipad|iphone|ipod/i.test(Ve)&&"undefined"!=typeof Pebble,Tl=/web0s(?!.*chrome)/i.test(Ve),Al=ne,Ml=Gs,Rl=ml.set,Ll=jl,Cl=Hs,Nl=kl,Dl=Tl,Ul=as,$l=Al.MutationObserver||Al.WebKitMutationObserver,Bl=Al.document,Fl=Al.process,Wl=Al.Promise,Gl=function(e){if(!wl)return bl[e];var t=El(bl,e);return t&&t.value}("queueMicrotask");if(!Gl){var Kl=new Ll,zl=function(){var e,t;for(Ul&&(e=Fl.domain)&&e.exit();t=Kl.get();)try{t()}catch(e){throw Kl.head&&Pl(),e}e&&e.enter()};Cl||Ul||Dl||!$l||!Bl?!Nl&&Wl&&Wl.resolve?((xl=Wl.resolve(void 0)).constructor=Wl,_l=Ml(xl.then,xl),Pl=function(){_l(zl)}):Ul?Pl=function(){Fl.nextTick(zl)}:(Rl=Ml(Rl,Al),Pl=function(){Rl(zl)}):(Ol=!0,Il=Bl.createTextNode(""),new $l(zl).observe(Il,{characterData:!0}),Pl=function(){Il.data=Ol=!Ol}),Gl=function(e){Kl.head||Pl(),Kl.add(e)}}var Hl=Gl,Vl=function(e){try{return{error:!1,value:e()}}catch(e){return{error:!0,value:e}}},ql=ne.Promise,Yl="object"==typeof Deno&&Deno&&"object"==typeof Deno.version,Zl=!Yl&&!as&&"object"==typeof window&&"object"==typeof document,Jl=ne,Xl=ql,Ql=Be,ef=Go,tf=on,rf=er,nf=Zl,of=Yl,af=et;Xl&&Xl.prototype;var uf=rf("species"),cf=!1,sf=Ql(Jl.PromiseRejectionEvent),lf=ef("Promise",(function(){var e=tf(Xl),t=e!==String(Xl);if(!t&&66===af)return!0;if(!af||af<51||!/native code/.test(e)){var r=new Xl((function(e){e(1)})),n=function(e){e((function(){}),(function(){}))};if((r.constructor={})[uf]=n,!(cf=r.then((function(){}))instanceof n))return!0}return!t&&(nf||of)&&!sf})),ff={CONSTRUCTOR:lf,REJECTION_EVENT:sf,SUBCLASSING:cf},pf={},df=yt,hf=TypeError,vf=function(e){var t,r;this.promise=new e((function(e,n){if(void 0!==t||void 0!==r)throw new hf("Bad Promise constructor");t=e,r=n})),this.resolve=df(t),this.reject=df(r)};pf.f=function(e){return new vf(e)};var yf,gf,mf,bf,wf,Ef,Sf,Pf=Jo,Of=as,If=ne,xf=le,_f=Yn,jf=fi,kf=yt,Tf=Be,Af=We,Mf=function(e,t){var r,n=Ds(e).constructor;return void 0===n||Us(r=Ds(n)[$s])?t:function(e){if(Ls(e))return e;throw new Ns(Cs(e)+" is not a constructor")}(r)},Rf=ml.set,Lf=Hl,Cf=Vl,Nf=jl,Df=xn,Uf=ql,$f=pf,Bf="Promise",Ff=ff.CONSTRUCTOR,Wf=ff.REJECTION_EVENT,Gf=ff.SUBCLASSING,Kf=Df.getterFor(Bf),zf=Df.set,Hf=Uf&&Uf.prototype,Vf=Uf,qf=Hf,Yf=If.TypeError,Zf=If.document,Jf=If.process,Xf=$f.f,Qf=Xf,ep=!!(Zf&&Zf.createEvent&&If.dispatchEvent),tp="unhandledrejection",rp=function(e){var t;return!(!Af(e)||!Tf(t=e.then))&&t},np=function(e,t){var r,n,o,i=t.value,a=1===t.state,u=a?e.ok:e.fail,c=e.resolve,s=e.reject,l=e.domain;try{u?(a||(2===t.rejection&&cp(t),t.rejection=1),!0===u?r=i:(l&&l.enter(),r=u(i),l&&(l.exit(),o=!0)),r===e.promise?s(new Yf("Promise-chain cycle")):(n=rp(r))?xf(n,r,c,s):c(r)):s(i)}catch(e){l&&!o&&l.exit(),s(e)}},op=function(e,t){e.notified||(e.notified=!0,Lf((function(){for(var r,n=e.reactions;r=n.get();)np(r,e);e.notified=!1,t&&!e.rejection&&ap(e)})))},ip=function(e,t,r){var n,o;ep?((n=Zf.createEvent("Event")).promise=t,n.reason=r,n.initEvent(e,!1,!0),If.dispatchEvent(n)):n={promise:t,reason:r},!Wf&&(o=If["on"+e])?o(n):e===tp&&function(e,t){try{1===arguments.length?console.error(e):console.error(e,t)}catch(e){}}("Unhandled promise rejection",r)},ap=function(e){xf(Rf,If,(function(){var t,r=e.facade,n=e.value;if(up(e)&&(t=Cf((function(){Of?Jf.emit("unhandledRejection",n,r):ip(tp,r,n)})),e.rejection=Of||up(e)?2:1,t.error))throw t.value}))},up=function(e){return 1!==e.rejection&&!e.parent},cp=function(e){xf(Rf,If,(function(){var t=e.facade;Of?Jf.emit("rejectionHandled",t):ip("rejectionhandled",t,e.value)}))},sp=function(e,t,r){return function(n){e(t,n,r)}},lp=function(e,t,r){e.done||(e.done=!0,r&&(e=r),e.value=t,e.state=2,op(e,!0))},fp=function(e,t,r){if(!e.done){e.done=!0,r&&(e=r);try{if(e.facade===t)throw new Yf("Promise can't be resolved itself");var n=rp(t);n?Lf((function(){var r={done:!1};try{xf(n,t,sp(fp,r,e),sp(lp,r,e))}catch(t){lp(r,t,e)}})):(e.value=t,e.state=1,op(e,!1))}catch(t){lp({done:!1},t,e)}}};if(Ff&&(qf=(Vf=function(e){(function(e,t){if(vs(t,e))return e;throw new ys("Incorrect invocation")})(this,qf),kf(e),xf(yf,this);var t=Kf(this);try{e(sp(fp,t),sp(lp,t))}catch(e){lp(t,e)}}).prototype,(yf=function(e){zf(this,{type:Bf,done:!1,notified:!1,parent:!1,reactions:new Nf,rejection:!1,state:0,value:void 0})}).prototype=_f(qf,"then",(function(e,t){var r=Kf(this),n=Xf(Mf(this,Vf));return r.parent=!0,n.ok=!Tf(e)||e,n.fail=Tf(t)&&t,n.domain=Of?Jf.domain:void 0,0===r.state?r.reactions.add(n):Lf((function(){np(n,r)})),n.promise})),gf=function(){var e=new yf,t=Kf(e);this.promise=e,this.resolve=sp(fp,t),this.reject=sp(lp,t)},$f.f=Xf=function(e){return e===Vf||void 0===e?new gf(e):Qf(e)},Tf(Uf)&&Hf!==Object.prototype)){mf=Hf.then,Gf||_f(Hf,"then",(function(e,t){var r=this;return new Vf((function(e,t){xf(mf,r,e,t)})).then(e,t)}),{unsafe:!0});try{delete Hf.constructor}catch(e){}jf&&jf(Hf,qf)}Pf({global:!0,constructor:!0,wrap:!0,forced:Ff},{Promise:Vf}),Ef=Bf,Sf=!1,(wf=Vf)&&!Sf&&(wf=wf.prototype),wf&&!cs(wf,ss)&&us(wf,ss,{configurable:!0,value:Ef}),bf=ps(Bf),ds&&bf&&!bf[hs]&&function(e,t,r){r.get&&ls(r.get,t,{getter:!0}),r.set&&ls(r.set,t,{setter:!0}),fs.f(e,t,r)}(bf,hs,{configurable:!0,get:function(){return this}});var pp={},dp=pp,hp=er("iterator"),vp=Array.prototype,yp=Pi,gp=bt,mp=Me,bp=pp,wp=er("iterator"),Ep=function(e){if(!mp(e))return gp(e,wp)||gp(e,"@@iterator")||bp[yp(e)]},Sp=le,Pp=yt,Op=Tr,Ip=pt,xp=Ep,_p=TypeError,jp=le,kp=Tr,Tp=bt,Ap=Gs,Mp=le,Rp=Tr,Lp=pt,Cp=co,Np=He,Dp=Ep,Up=function(e,t,r){var n,o;kp(e);try{if(!(n=Tp(e,"return"))){if("throw"===t)throw r;return r}n=jp(n,e)}catch(e){o=!0,n=e}if("throw"===t)throw r;if(o)throw n;return kp(n),r},$p=TypeError,Bp=function(e,t){this.stopped=e,this.result=t},Fp=Bp.prototype,Wp=function(e,t,r){var n,o,i,a,u,c,s,l,f=r&&r.that,p=!(!r||!r.AS_ENTRIES),d=!(!r||!r.IS_RECORD),h=!(!r||!r.IS_ITERATOR),v=!(!r||!r.INTERRUPTED),y=Ap(t,f),g=function(e){return n&&Up(n,"normal",e),new Bp(!0,e)},m=function(e){return p?(Rp(e),v?y(e[0],e[1],g):y(e[0],e[1])):v?y(e,g):y(e)};if(d)n=e.iterator;else if(h)n=e;else{if(!(o=Dp(e)))throw new $p(Lp(e)+" is not iterable");if(void 0!==(l=o)&&(dp.Array===l||vp[hp]===l)){for(i=0,a=Cp(e);a>i;i++)if((u=m(e[i]))&&Np(Fp,u))return u;return new Bp(!1)}n=function(e,t){var r=arguments.length<2?xp(e):t;if(Pp(r))return Op(Sp(r,e));throw new _p(Ip(e)+" is not iterable")}(e,o)}for(c=d?e.next:n.next;!(s=Mp(c,n)).done;){try{u=m(s.value)}catch(e){Up(n,"throw",e)}if("object"==typeof u&&u&&Np(Fp,u))return u}return new Bp(!1)},Gp=er("iterator"),Kp=!1;try{var zp=0,Hp={next:function(){return{done:!!zp++}},return:function(){Kp=!0}};Hp[Gp]=function(){return this},Array.from(Hp,(function(){throw 2}))}catch(e){}var Vp=ql,qp=ff.CONSTRUCTOR||!function(e,t){try{if(!t&&!Kp)return!1}catch(e){return!1}var r=!1;try{var n={};n[Gp]=function(){return{next:function(){return{done:r=!0}}}},e(n)}catch(e){}return r}((function(e){Vp.all(e).then(void 0,(function(){}))})),Yp=le,Zp=yt,Jp=pf,Xp=Vl,Qp=Wp;Jo({target:"Promise",stat:!0,forced:qp},{all:function(e){var t=this,r=Jp.f(t),n=r.resolve,o=r.reject,i=Xp((function(){var r=Zp(t.resolve),i=[],a=0,u=1;Qp(e,(function(e){var c=a++,s=!1;u++,Yp(r,t,e).then((function(e){s||(s=!0,i[c]=e,--u||n(i))}),o)})),--u||n(i)}));return i.error&&o(i.value),r.promise}});var ed=Jo,td=ff.CONSTRUCTOR,rd=ql,nd=ze,od=Be,id=Yn,ad=rd&&rd.prototype;if(ed({target:"Promise",proto:!0,forced:td,real:!0},{catch:function(e){return this.then(void 0,e)}}),od(rd)){var ud=nd("Promise").prototype.catch;ad.catch!==ud&&id(ad,"catch",ud,{unsafe:!0})}var cd=le,sd=yt,ld=pf,fd=Vl,pd=Wp;Jo({target:"Promise",stat:!0,forced:qp},{race:function(e){var t=this,r=ld.f(t),n=r.reject,o=fd((function(){var o=sd(t.resolve);pd(e,(function(e){cd(o,t,e).then(r.resolve,n)}))}));return o.error&&n(o.value),r.promise}});var dd=pf;Jo({target:"Promise",stat:!0,forced:ff.CONSTRUCTOR},{reject:function(e){var t=dd.f(this);return(0,t.reject)(e),t.promise}});var hd=Tr,vd=We,yd=pf,gd=Jo,md=ff.CONSTRUCTOR;ze("Promise"),gd({target:"Promise",stat:!0,forced:md},{resolve:function(e){return function(e,t){if(hd(e),vd(t)&&t.constructor===e)return t;var r=yd.f(e);return(0,r.resolve)(t),r.promise}(this,e)}});const bd=Cc.createWorkspaceLogger("window").getLogger("fetchers"),{value:{factoriesByOwner:wd}}=Rc("factoriesByOwner",bd,{factoriesByOwner:{}});function Ed(e){return is(this,arguments,void 0,(function*({owner:e,url:t}){let r=wd[e];r||(bd.log(`no factories found for ${e}, creating new list`),r=[],wd[e]=r);const n=r.find((e=>e.url===t));if(null==n?void 0:n.factoryModule)return bd.log(`using cached factory module for ${t}`),{factoryModule:n.factoryModule,error:null};const o=r.find((e=>e.url===t));if(o)return bd.log(`a request to fetch factory already in progress for ${t}, waiting for it to finish`),new Promise(((e,t)=>{o.onFetched.push(e),o.onError.push(t)}));bd.log(`fetching factory module for ${t}`);const i={url:t,factoryModule:null,error:null,onFetched:[],onError:[]};r.push(i);try{const e=yield import(t);bd.log(`fetched factory module for ${t}, caching it`),i.factoryModule=e,i.onFetched&&(bd.log(`calling onFetched callbacks for ${t} (${i.onFetched.length} queued)`),i.onFetched.forEach((r=>{try{r(e)}catch(e){bd.error(`error calling onFetched callback for ${t}`,{error:e})}}))),i.onFetched=[],i.onError=[]}catch(e){bd.log(`failed to fetch factory module for ${t}, removing from list`),i.onError&&(bd.log(`calling onError callbacks for ${t} (${i.onError.length} queued)`),i.onError.forEach((r=>{try{r(e)}catch(e){bd.error(`error calling onError callback for ${t}`,{error:e})}}))),i.onError=[],i.onFetched=[],r.splice(r.indexOf(i),1)}return{factoryModule:i.factoryModule,error:i.error}}))}const Sd=Ac(),Pd=e=>is(void 0,void 0,void 0,(function*(){const t=Cc.createWorkspaceLogger(e.workspaceName||"").getLogger("fetch-loader");let r="",n="";if(Sd.loaderUrl?(t.log(`using custom loader url from query params '${Sd.loaderUrl}'`),n=Sd.loaderUrl):e.devLoaderUrl&&(t.log(`using custom loader url from options '${e.devLoaderUrl}'`),n=e.devLoaderUrl),n){t.log(`verifying custom loader url '${n}' url against environment runtime json. fetching runtime json...`);const o=yield((e,t)=>is(void 0,void 0,void 0,(function*(){let r,n=`${e}/runtime.json`;try{t.log(`loading runtime versions for env from '${n}'`),r=yield fetch(n).then((e=>e.json()))}catch(e){throw t.error(`error loading runtime versions for env from '${n}'`,{error:e}),new Error(`failed to load runtime versions for env from '${n}'`)}if(!r||!("domains"in r))throw new Error("invalid runtime json, 'domains' is missing in the runtime json");return r.domains})))(e.serverUrl,t),i=n.startsWith(e.serverUrl),a=o.some((e=>n.startsWith(e)));if(t.log("ensuring custom loader url is in environment artifacts or from an allowed domain",{data:{customLoaderUrl:n,serverUrl:e.serverUrl,isInEnvironmentArtifacts:i,isInAllowedDomains:a}}),!i&&!a)throw new Error(`the custom loader url '${n}' is not in the environment artifacts or from an allowed domain`);t.log(`using custom loader url '${n}'`),r=n}else t.log("using environment loader"),r=`${e.serverUrl}/loader/index.esm.js`;t.log("fetching environment unisphere loader",{data:{environmentLoaderUrl:r,options:e}});const{factoryModule:{loader:o}}=yield Ed({owner:"runtime-js",url:r});if(!o)throw new Error(`failed to load dev loader from '${r}'`);return t.log("executing environment unisphere loader"),o(Object.assign({},e))}));var Od=Jo,Id=Bc,xd=oe.f,_d=ao,jd=xi,kd=zc,Td=Ce,Ad=Vc,Md=Id("".slice),Rd=Math.min,Ld=Ad("endsWith"),Cd=!Ld&&!!function(){var e=xd(String.prototype,"endsWith");return e&&!e.writable}();Od({target:"String",proto:!0,forced:!Cd&&!Ld},{endsWith:function(e){var t=jd(Td(this));kd(e);var r=arguments.length>1?arguments[1]:void 0,n=t.length,o=void 0===r?n:Rd(_d(r),n),i=jd(e);return Md(t,o-i.length,o)===i}});var Nd=Se,Dd=eo,Ud=xi,$d=Ce,Bd=Nd("".charAt),Fd=Nd("".charCodeAt),Wd=Nd("".slice),Gd=function(e){return function(t,r){var n,o,i=Ud($d(t)),a=Dd(r),u=i.length;return a<0||a>=u?e?"":void 0:(n=Fd(i,a))<55296||n>56319||a+1===u||(o=Fd(i,a+1))<56320||o>57343?e?Bd(i,a):n:e?Wd(i,a,a+2):o-56320+(n-55296<<10)+65536}},Kd=(Gd(!1),Gd(!0)),zd=Se,Hd=Dt,Vd=Math.floor,qd=zd("".charAt),Yd=zd("".replace),Zd=zd("".slice),Jd=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,Xd=/\$([$&'`]|\d{1,2})/g,Qd=ri,eh=le,th=Se,rh=uc,nh=ie,oh=Tr,ih=Be,ah=Me,uh=eo,ch=ao,sh=xi,lh=Ce,fh=function(e,t,r){return t+(r?Kd(e,t).length:1)},ph=bt,dh=function(e,t,r,n,o,i){var a=r+e.length,u=n.length,c=Xd;return void 0!==o&&(o=Hd(o),c=Jd),Yd(i,c,(function(i,c){var s;switch(qd(c,0)){case"$":return"$";case"&":return e;case"`":return Zd(t,0,r);case"'":return Zd(t,a);case"<":s=o[Zd(c,1,-1)];break;default:var l=+c;if(0===l)return i;if(l>u){var f=Vd(l/10);return 0===f?i:f<=u?void 0===n[f-1]?qd(c,1):n[f-1]+qd(c,1):i}s=n[l-1]}return void 0===s?"":s}))},hh=vc,vh=er("replace"),yh=Math.max,gh=Math.min,mh=th([].concat),bh=th([].push),wh=th("".indexOf),Eh=th("".slice),Sh="$0"==="a".replace(/./,"$0"),Ph=!!/./[vh]&&""===/./[vh]("a","$0");function Oh(e){return is(this,void 0,void 0,(function*(){return(yield function(){const e=window;return new Promise((t=>{var r,n;if(null===(n=null===(r=e.unisphere)||void 0===r?void 0:r.instancesManager)||void 0===n?void 0:n.get)t(e.unisphere.instancesManager.get);else{const r=()=>{document.removeEventListener("unisphere-ready",r),t(e.unisphere.instancesManager.get)};document.addEventListener("unisphere-ready",r)}}))}())(e)}))}function Ih(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(Ih=function(){return!!e})()}rh("replace",(function(e,t,r){var n=Ph?"$":"$0";return[function(e,r){var n=lh(this),o=ah(e)?void 0:ph(e,vh);return o?eh(o,e,n,r):eh(t,sh(n),e,r)},function(e,o){var i=oh(this),a=sh(e);if("string"==typeof o&&-1===wh(o,n)&&-1===wh(o,"$<")){var u=r(t,i,a,o);if(u.done)return u.value}var c=ih(o);c||(o=sh(o));var s,l=i.global;l&&(s=i.unicode,i.lastIndex=0);for(var f,p=[];null!==(f=hh(i,a))&&(bh(p,f),l);)""===sh(f[0])&&(i.lastIndex=fh(a,ch(i.lastIndex),s));for(var d,h="",v=0,y=0;y<p.length;y++){for(var g,m=sh((f=p[y])[0]),b=yh(gh(uh(f.index),a.length),0),w=[],E=1;E<f.length;E++)bh(w,void 0===(d=f[E])?d:String(d));var S=f.groups;if(c){var P=mh([m],w,b,a);void 0!==S&&bh(P,S),g=sh(Qd(o,void 0,P))}else g=dh(m,a,b,w,S,o);b>=v&&(h+=Eh(a,v,b)+g,v=b+m.length)}return h+Eh(a,v)}]}),!!nh((function(){var e=/./;return e.exec=function(){var e=[];return e.groups={a:"7"},e},"7"!=="".replace(e,"$<a>")}))||!Sh||Ph),Ac();var xh=function(e){function t(e,r,n){var i,a,u,c;return o(this,t),a=this,c=[e,r,n],u=l(u=t),d(i=s(a,Ih()?Reflect.construct(u,c||[],l(a).constructor):u.apply(a,c)),"isReady",!1),d(i,"workspaceName",""),d(i,"shouldCreateWorkspace",!1),i.unispherePluginManager=new ee(r,i.eventManager,i.logger),i.player.config.provider.unisphereLoaderUrl&&"string"==typeof i.config.workspaceName?i.workspaceName=i.config.workspaceName:(i.workspaceName=W("kaltura_player_workspace_"),i.shouldCreateWorkspace=!0),i}return p(t,e),c(t,[{key:"getWorkspace",value:(r=n(v().mark((function e(){return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this.shouldCreateWorkspace){e.next=2;break}return e.abrupt("return",Pd({serverUrl:this.player.config.provider.unisphereLoaderUrl,workspaceName:this.workspaceName,ui:{theme:"light",language:"en"}}));case 2:return e.abrupt("return",Oh(this.config.workspaceName));case 3:case"end":return e.stop()}}),e,this)}))),function(){return r.apply(this,arguments)})},{key:"loadMedia",value:function(){var e=this;this.isReady?(this.unispherePluginManager.updateSessionData(),this.unispherePluginManager.loadWidgets(this.config.widgets)):this.getWorkspace().then((function(t){e.unispherePluginManager.init(t,e.config.widgets),e.unispherePluginManager.updateSessionData(),e.isReady=!0})).catch((function(){e.logger.warn("Failed to load unisphere workspace",e.workspaceName)}))}},{key:"reset",value:function(){this.unispherePluginManager.reset()}},{key:"destroy",value:function(){this.eventManager.destroy(),this.unispherePluginManager.destroy()}}],[{key:"isValid",value:function(){return!0}}]);var r}(e.BasePlugin);d(xh,"defaultConfig",{widgets:[]}),(0,e.registerPlugin)("unisphere",xh)})(),{}})()));
3
3
  //# sourceMappingURL=playkit-unisphere.js.map