@clickview/lite 0.0.52-dev.0 → 0.0.52-dev.1
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.
|
@@ -43,6 +43,6 @@ var r=n(788),i=n(789),o=n(790);function a(){return c.TYPED_ARRAY_SUPPORT?2147483
|
|
|
43
43
|
*
|
|
44
44
|
* Date: 2019-10-04T04:33:48.372Z
|
|
45
45
|
*/
|
|
46
|
-
e.exports=function(){"use strict";function e(t){return(e="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})(t)}function t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?i(n,!0).forEach((function(t){r(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(n).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function a(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t<e.length;t++)n[t]=e[t];return n}}(e)||function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}var s="undefined"!=typeof window&&void 0!==window.document,c=s?window:{},u=!!s&&"ontouchstart"in c.document.documentElement,l=!!s&&"PointerEvent"in c,f="".concat("cropper","-crop"),p="".concat("cropper","-disabled"),d="".concat("cropper","-hidden"),h="".concat("cropper","-hide"),y="".concat("cropper","-invisible"),m="".concat("cropper","-modal"),v="".concat("cropper","-move"),g="".concat("cropper","Action"),b="".concat("cropper","Preview"),w=u?"touchstart":"mousedown",_=u?"touchmove":"mousemove",S=u?"touchend touchcancel":"mouseup",T=l?"pointerdown":w,C=l?"pointermove":_,E=l?"pointerup pointercancel":S,k=/^e|w|s|n|se|sw|ne|nw|all|crop|move|zoom$/,O=/^data:/,P=/^data:image\/jpeg;base64,/,A=/^img|canvas$/i,I={viewMode:0,dragMode:"crop",initialAspectRatio:NaN,aspectRatio:NaN,data:null,preview:"",responsive:!0,restore:!0,checkCrossOrigin:!0,checkOrientation:!0,modal:!0,guides:!0,center:!0,highlight:!0,background:!0,autoCrop:!0,autoCropArea:.8,movable:!0,rotatable:!0,scalable:!0,zoomable:!0,zoomOnTouch:!0,zoomOnWheel:!0,wheelZoomRatio:.1,cropBoxMovable:!0,cropBoxResizable:!0,toggleDragModeOnDblclick:!0,minCanvasWidth:0,minCanvasHeight:0,minCropBoxWidth:0,minCropBoxHeight:0,minContainerWidth:200,minContainerHeight:100,ready:null,cropstart:null,cropmove:null,cropend:null,crop:null,zoom:null},x=Number.isNaN||c.isNaN;function R(e){return"number"==typeof e&&!x(e)}var L=function(e){return e>0&&e<1/0};function j(e){return void 0===e}function N(t){return"object"===e(t)&&null!==t}var D=Object.prototype.hasOwnProperty;function B(e){if(!N(e))return!1;try{var t=e.constructor,n=t.prototype;return t&&n&&D.call(n,"isPrototypeOf")}catch(e){return!1}}function U(e){return"function"==typeof e}var M=Array.prototype.slice;function V(e){return Array.from?Array.from(e):M.call(e)}function F(e,t){return e&&U(t)&&(Array.isArray(e)||R(e.length)?V(e).forEach((function(n,r){t.call(e,n,r,e)})):N(e)&&Object.keys(e).forEach((function(n){t.call(e,e[n],n,e)}))),e}var H=Object.assign||function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return N(e)&&n.length>0&&n.forEach((function(t){N(t)&&Object.keys(t).forEach((function(n){e[n]=t[n]}))})),e},z=/\.\d*(?:0|9){12}\d*$/;function W(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1e11;return z.test(e)?Math.round(e*t)/t:e}var q=/^width|height|left|top|marginLeft|marginTop$/;function G(e,t){var n=e.style;F(t,(function(e,t){q.test(t)&&R(e)&&(e="".concat(e,"px")),n[t]=e}))}function K(e,t){if(t)if(R(e.length))F(e,(function(e){K(e,t)}));else if(e.classList)e.classList.add(t);else{var n=e.className.trim();n?n.indexOf(t)<0&&(e.className="".concat(n," ").concat(t)):e.className=t}}function Y(e,t){t&&(R(e.length)?F(e,(function(e){Y(e,t)})):e.classList?e.classList.remove(t):e.className.indexOf(t)>=0&&(e.className=e.className.replace(t,"")))}function X(e,t,n){t&&(R(e.length)?F(e,(function(e){X(e,t,n)})):n?K(e,t):Y(e,t))}var Q=/([a-z\d])([A-Z])/g;function $(e){return e.replace(Q,"$1-$2").toLowerCase()}function Z(e,t){return N(e[t])?e[t]:e.dataset?e.dataset[t]:e.getAttribute("data-".concat($(t)))}function J(e,t,n){N(n)?e[t]=n:e.dataset?e.dataset[t]=n:e.setAttribute("data-".concat($(t)),n)}var ee=/\s\s*/,te=function(){var e=!1;if(s){var t=!1,n=function(){},r=Object.defineProperty({},"once",{get:function(){return e=!0,t},set:function(e){t=e}});c.addEventListener("test",n,r),c.removeEventListener("test",n,r)}return e}();function ne(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=n;t.trim().split(ee).forEach((function(t){if(!te){var o=e.listeners;o&&o[t]&&o[t][n]&&(i=o[t][n],delete o[t][n],0===Object.keys(o[t]).length&&delete o[t],0===Object.keys(o).length&&delete e.listeners)}e.removeEventListener(t,i,r)}))}function re(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=n;t.trim().split(ee).forEach((function(t){if(r.once&&!te){var o=e.listeners,a=void 0===o?{}:o;i=function(){delete a[t][n],e.removeEventListener(t,i,r);for(var o=arguments.length,s=new Array(o),c=0;c<o;c++)s[c]=arguments[c];n.apply(e,s)},a[t]||(a[t]={}),a[t][n]&&e.removeEventListener(t,a[t][n],r),a[t][n]=i,e.listeners=a}e.addEventListener(t,i,r)}))}function ie(e,t,n){var r;return U(Event)&&U(CustomEvent)?r=new CustomEvent(t,{detail:n,bubbles:!0,cancelable:!0}):(r=document.createEvent("CustomEvent")).initCustomEvent(t,!0,!0,n),e.dispatchEvent(r)}function oe(e){var t=e.getBoundingClientRect();return{left:t.left+(window.pageXOffset-document.documentElement.clientLeft),top:t.top+(window.pageYOffset-document.documentElement.clientTop)}}var ae=c.location,se=/^(\w+:)\/\/([^:/?#]*):?(\d*)/i;function ce(e){var t=e.match(se);return null!==t&&(t[1]!==ae.protocol||t[2]!==ae.hostname||t[3]!==ae.port)}function ue(e){var t="timestamp=".concat((new Date).getTime());return e+(-1===e.indexOf("?")?"?":"&")+t}function le(e){var t=e.rotate,n=e.scaleX,r=e.scaleY,i=e.translateX,o=e.translateY,a=[];R(i)&&0!==i&&a.push("translateX(".concat(i,"px)")),R(o)&&0!==o&&a.push("translateY(".concat(o,"px)")),R(t)&&0!==t&&a.push("rotate(".concat(t,"deg)")),R(n)&&1!==n&&a.push("scaleX(".concat(n,")")),R(r)&&1!==r&&a.push("scaleY(".concat(r,")"));var s=a.length?a.join(" "):"none";return{WebkitTransform:s,msTransform:s,transform:s}}function fe(e,t){var n=e.pageX,r=e.pageY,i={endX:n,endY:r};return t?i:o({startX:n,startY:r},i)}function pe(e){var t=e.aspectRatio,n=e.height,r=e.width,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"contain",o=L(r),a=L(n);if(o&&a){var s=n*t;"contain"===i&&s>r||"cover"===i&&s<r?n=r/t:r=n*t}else o?n=r/t:a&&(r=n*t);return{width:r,height:n}}function de(e,t,n,r){var i=t.aspectRatio,o=t.naturalWidth,s=t.naturalHeight,c=t.rotate,u=void 0===c?0:c,l=t.scaleX,f=void 0===l?1:l,p=t.scaleY,d=void 0===p?1:p,h=n.aspectRatio,y=n.naturalWidth,m=n.naturalHeight,v=r.fillColor,g=void 0===v?"transparent":v,b=r.imageSmoothingEnabled,w=void 0===b||b,_=r.imageSmoothingQuality,S=void 0===_?"low":_,T=r.maxWidth,C=void 0===T?1/0:T,E=r.maxHeight,k=void 0===E?1/0:E,O=r.minWidth,P=void 0===O?0:O,A=r.minHeight,I=void 0===A?0:A,x=document.createElement("canvas"),R=x.getContext("2d"),L=pe({aspectRatio:h,width:C,height:k}),j=pe({aspectRatio:h,width:P,height:I},"cover"),N=Math.min(L.width,Math.max(j.width,y)),D=Math.min(L.height,Math.max(j.height,m)),B=pe({aspectRatio:i,width:C,height:k}),U=pe({aspectRatio:i,width:P,height:I},"cover"),M=Math.min(B.width,Math.max(U.width,o)),V=Math.min(B.height,Math.max(U.height,s)),F=[-M/2,-V/2,M,V];return x.width=W(N),x.height=W(D),R.fillStyle=g,R.fillRect(0,0,N,D),R.save(),R.translate(N/2,D/2),R.rotate(u*Math.PI/180),R.scale(f,d),R.imageSmoothingEnabled=w,R.imageSmoothingQuality=S,R.drawImage.apply(R,[e].concat(a(F.map((function(e){return Math.floor(W(e))}))))),R.restore(),x}var he=String.fromCharCode,ye=/^data:.*,/;function me(e){var t,n=new DataView(e);try{var r,i,o;if(255===n.getUint8(0)&&216===n.getUint8(1))for(var a=n.byteLength,s=2;s+1<a;){if(255===n.getUint8(s)&&225===n.getUint8(s+1)){i=s;break}s+=1}if(i){var c=i+10;if("Exif"===function(e,t,n){var r="";n+=t;for(var i=t;i<n;i+=1)r+=he(e.getUint8(i));return r}(n,i+4,4)){var u=n.getUint16(c);if(((r=18761===u)||19789===u)&&42===n.getUint16(c+2,r)){var l=n.getUint32(c+4,r);l>=8&&(o=c+l)}}}if(o){var f,p,d=n.getUint16(o,r);for(p=0;p<d;p+=1)if(f=o+12*p+2,274===n.getUint16(f,r)){f+=8,t=n.getUint16(f,r),n.setUint16(f,1,r);break}}}catch(e){t=1}return t}var ve={render:function(){this.initContainer(),this.initCanvas(),this.initCropBox(),this.renderCanvas(),this.cropped&&this.renderCropBox()},initContainer:function(){var e=this.element,t=this.options,n=this.container,r=this.cropper;K(r,d),Y(e,d);var i={width:Math.max(n.offsetWidth,Number(t.minContainerWidth)||200),height:Math.max(n.offsetHeight,Number(t.minContainerHeight)||100)};this.containerData=i,G(r,{width:i.width,height:i.height}),K(e,d),Y(r,d)},initCanvas:function(){var e=this.containerData,t=this.imageData,n=this.options.viewMode,r=Math.abs(t.rotate)%180==90,i=r?t.naturalHeight:t.naturalWidth,o=r?t.naturalWidth:t.naturalHeight,a=i/o,s=e.width,c=e.height;e.height*a>e.width?3===n?s=e.height*a:c=e.width/a:3===n?c=e.width/a:s=e.height*a;var u={aspectRatio:a,naturalWidth:i,naturalHeight:o,width:s,height:c};u.left=(e.width-s)/2,u.top=(e.height-c)/2,u.oldLeft=u.left,u.oldTop=u.top,this.canvasData=u,this.limited=1===n||2===n,this.limitCanvas(!0,!0),this.initialImageData=H({},t),this.initialCanvasData=H({},u)},limitCanvas:function(e,t){var n=this.options,r=this.containerData,i=this.canvasData,o=this.cropBoxData,a=n.viewMode,s=i.aspectRatio,c=this.cropped&&o;if(e){var u=Number(n.minCanvasWidth)||0,l=Number(n.minCanvasHeight)||0;a>1?(u=Math.max(u,r.width),l=Math.max(l,r.height),3===a&&(l*s>u?u=l*s:l=u/s)):a>0&&(u?u=Math.max(u,c?o.width:0):l?l=Math.max(l,c?o.height:0):c&&(u=o.width,(l=o.height)*s>u?u=l*s:l=u/s));var f=pe({aspectRatio:s,width:u,height:l});u=f.width,l=f.height,i.minWidth=u,i.minHeight=l,i.maxWidth=1/0,i.maxHeight=1/0}if(t)if(a>(c?0:1)){var p=r.width-i.width,d=r.height-i.height;i.minLeft=Math.min(0,p),i.minTop=Math.min(0,d),i.maxLeft=Math.max(0,p),i.maxTop=Math.max(0,d),c&&this.limited&&(i.minLeft=Math.min(o.left,o.left+(o.width-i.width)),i.minTop=Math.min(o.top,o.top+(o.height-i.height)),i.maxLeft=o.left,i.maxTop=o.top,2===a&&(i.width>=r.width&&(i.minLeft=Math.min(0,p),i.maxLeft=Math.max(0,p)),i.height>=r.height&&(i.minTop=Math.min(0,d),i.maxTop=Math.max(0,d))))}else i.minLeft=-i.width,i.minTop=-i.height,i.maxLeft=r.width,i.maxTop=r.height},renderCanvas:function(e,t){var n=this.canvasData,r=this.imageData;if(t){var i=function(e){var t=e.width,n=e.height,r=e.degree;if(90==(r=Math.abs(r)%180))return{width:n,height:t};var i=r%90*Math.PI/180,o=Math.sin(i),a=Math.cos(i),s=t*a+n*o,c=t*o+n*a;return r>90?{width:c,height:s}:{width:s,height:c}}({width:r.naturalWidth*Math.abs(r.scaleX||1),height:r.naturalHeight*Math.abs(r.scaleY||1),degree:r.rotate||0}),o=i.width,a=i.height,s=n.width*(o/n.naturalWidth),c=n.height*(a/n.naturalHeight);n.left-=(s-n.width)/2,n.top-=(c-n.height)/2,n.width=s,n.height=c,n.aspectRatio=o/a,n.naturalWidth=o,n.naturalHeight=a,this.limitCanvas(!0,!1)}(n.width>n.maxWidth||n.width<n.minWidth)&&(n.left=n.oldLeft),(n.height>n.maxHeight||n.height<n.minHeight)&&(n.top=n.oldTop),n.width=Math.min(Math.max(n.width,n.minWidth),n.maxWidth),n.height=Math.min(Math.max(n.height,n.minHeight),n.maxHeight),this.limitCanvas(!1,!0),n.left=Math.min(Math.max(n.left,n.minLeft),n.maxLeft),n.top=Math.min(Math.max(n.top,n.minTop),n.maxTop),n.oldLeft=n.left,n.oldTop=n.top,G(this.canvas,H({width:n.width,height:n.height},le({translateX:n.left,translateY:n.top}))),this.renderImage(e),this.cropped&&this.limited&&this.limitCropBox(!0,!0)},renderImage:function(e){var t=this.canvasData,n=this.imageData,r=n.naturalWidth*(t.width/t.naturalWidth),i=n.naturalHeight*(t.height/t.naturalHeight);H(n,{width:r,height:i,left:(t.width-r)/2,top:(t.height-i)/2}),G(this.image,H({width:n.width,height:n.height},le(H({translateX:n.left,translateY:n.top},n)))),e&&this.output()},initCropBox:function(){var e=this.options,t=this.canvasData,n=e.aspectRatio||e.initialAspectRatio,r=Number(e.autoCropArea)||.8,i={width:t.width,height:t.height};n&&(t.height*n>t.width?i.height=i.width/n:i.width=i.height*n),this.cropBoxData=i,this.limitCropBox(!0,!0),i.width=Math.min(Math.max(i.width,i.minWidth),i.maxWidth),i.height=Math.min(Math.max(i.height,i.minHeight),i.maxHeight),i.width=Math.max(i.minWidth,i.width*r),i.height=Math.max(i.minHeight,i.height*r),i.left=t.left+(t.width-i.width)/2,i.top=t.top+(t.height-i.height)/2,i.oldLeft=i.left,i.oldTop=i.top,this.initialCropBoxData=H({},i)},limitCropBox:function(e,t){var n=this.options,r=this.containerData,i=this.canvasData,o=this.cropBoxData,a=this.limited,s=n.aspectRatio;if(e){var c=Number(n.minCropBoxWidth)||0,u=Number(n.minCropBoxHeight)||0,l=a?Math.min(r.width,i.width,i.width+i.left,r.width-i.left):r.width,f=a?Math.min(r.height,i.height,i.height+i.top,r.height-i.top):r.height;c=Math.min(c,r.width),u=Math.min(u,r.height),s&&(c&&u?u*s>c?u=c/s:c=u*s:c?u=c/s:u&&(c=u*s),f*s>l?f=l/s:l=f*s),o.minWidth=Math.min(c,l),o.minHeight=Math.min(u,f),o.maxWidth=l,o.maxHeight=f}t&&(a?(o.minLeft=Math.max(0,i.left),o.minTop=Math.max(0,i.top),o.maxLeft=Math.min(r.width,i.left+i.width)-o.width,o.maxTop=Math.min(r.height,i.top+i.height)-o.height):(o.minLeft=0,o.minTop=0,o.maxLeft=r.width-o.width,o.maxTop=r.height-o.height))},renderCropBox:function(){var e=this.options,t=this.containerData,n=this.cropBoxData;(n.width>n.maxWidth||n.width<n.minWidth)&&(n.left=n.oldLeft),(n.height>n.maxHeight||n.height<n.minHeight)&&(n.top=n.oldTop),n.width=Math.min(Math.max(n.width,n.minWidth),n.maxWidth),n.height=Math.min(Math.max(n.height,n.minHeight),n.maxHeight),this.limitCropBox(!1,!0),n.left=Math.min(Math.max(n.left,n.minLeft),n.maxLeft),n.top=Math.min(Math.max(n.top,n.minTop),n.maxTop),n.oldLeft=n.left,n.oldTop=n.top,e.movable&&e.cropBoxMovable&&J(this.face,g,n.width>=t.width&&n.height>=t.height?"move":"all"),G(this.cropBox,H({width:n.width,height:n.height},le({translateX:n.left,translateY:n.top}))),this.cropped&&this.limited&&this.limitCanvas(!0,!0),this.disabled||this.output()},output:function(){this.preview(),ie(this.element,"crop",this.getData())}},ge={initPreview:function(){var e=this.element,t=this.crossOrigin,n=this.options.preview,r=t?this.crossOriginUrl:this.url,i=e.alt||"The image to preview",o=document.createElement("img");if(t&&(o.crossOrigin=t),o.src=r,o.alt=i,this.viewBox.appendChild(o),this.viewBoxImage=o,n){var a=n;"string"==typeof n?a=e.ownerDocument.querySelectorAll(n):n.querySelector&&(a=[n]),this.previews=a,F(a,(function(e){var n=document.createElement("img");J(e,b,{width:e.offsetWidth,height:e.offsetHeight,html:e.innerHTML}),t&&(n.crossOrigin=t),n.src=r,n.alt=i,n.style.cssText='display:block;width:100%;height:auto;min-width:0!important;min-height:0!important;max-width:none!important;max-height:none!important;image-orientation:0deg!important;"',e.innerHTML="",e.appendChild(n)}))}},resetPreview:function(){F(this.previews,(function(e){var t=Z(e,b);G(e,{width:t.width,height:t.height}),e.innerHTML=t.html,function(e,t){if(N(e[t]))try{delete e[t]}catch(n){e[t]=void 0}else if(e.dataset)try{delete e.dataset[t]}catch(n){e.dataset[t]=void 0}else e.removeAttribute("data-".concat($(t)))}(e,b)}))},preview:function(){var e=this.imageData,t=this.canvasData,n=this.cropBoxData,r=n.width,i=n.height,o=e.width,a=e.height,s=n.left-t.left-e.left,c=n.top-t.top-e.top;this.cropped&&!this.disabled&&(G(this.viewBoxImage,H({width:o,height:a},le(H({translateX:-s,translateY:-c},e)))),F(this.previews,(function(t){var n=Z(t,b),u=n.width,l=n.height,f=u,p=l,d=1;r&&(p=i*(d=u/r)),i&&p>l&&(f=r*(d=l/i),p=l),G(t,{width:f,height:p}),G(t.getElementsByTagName("img")[0],H({width:o*d,height:a*d},le(H({translateX:-s*d,translateY:-c*d},e))))})))}},be={bind:function(){var e=this.element,t=this.options,n=this.cropper;U(t.cropstart)&&re(e,"cropstart",t.cropstart),U(t.cropmove)&&re(e,"cropmove",t.cropmove),U(t.cropend)&&re(e,"cropend",t.cropend),U(t.crop)&&re(e,"crop",t.crop),U(t.zoom)&&re(e,"zoom",t.zoom),re(n,T,this.onCropStart=this.cropStart.bind(this)),t.zoomable&&t.zoomOnWheel&&re(n,"wheel",this.onWheel=this.wheel.bind(this),{passive:!1,capture:!0}),t.toggleDragModeOnDblclick&&re(n,"dblclick",this.onDblclick=this.dblclick.bind(this)),re(e.ownerDocument,C,this.onCropMove=this.cropMove.bind(this)),re(e.ownerDocument,E,this.onCropEnd=this.cropEnd.bind(this)),t.responsive&&re(window,"resize",this.onResize=this.resize.bind(this))},unbind:function(){var e=this.element,t=this.options,n=this.cropper;U(t.cropstart)&&ne(e,"cropstart",t.cropstart),U(t.cropmove)&&ne(e,"cropmove",t.cropmove),U(t.cropend)&&ne(e,"cropend",t.cropend),U(t.crop)&&ne(e,"crop",t.crop),U(t.zoom)&&ne(e,"zoom",t.zoom),ne(n,T,this.onCropStart),t.zoomable&&t.zoomOnWheel&&ne(n,"wheel",this.onWheel,{passive:!1,capture:!0}),t.toggleDragModeOnDblclick&&ne(n,"dblclick",this.onDblclick),ne(e.ownerDocument,C,this.onCropMove),ne(e.ownerDocument,E,this.onCropEnd),t.responsive&&ne(window,"resize",this.onResize)}},we={resize:function(){var e=this.options,t=this.container,n=this.containerData,r=Number(e.minContainerWidth)||200,i=Number(e.minContainerHeight)||100;if(!(this.disabled||n.width<=r||n.height<=i)){var o,a,s=t.offsetWidth/n.width;1===s&&t.offsetHeight===n.height||(e.restore&&(o=this.getCanvasData(),a=this.getCropBoxData()),this.render(),e.restore&&(this.setCanvasData(F(o,(function(e,t){o[t]=e*s}))),this.setCropBoxData(F(a,(function(e,t){a[t]=e*s})))))}},dblclick:function(){var e,t;this.disabled||"none"===this.options.dragMode||this.setDragMode((e=this.dragBox,t=f,(e.classList?e.classList.contains(t):e.className.indexOf(t)>-1)?"move":"crop"))},wheel:function(e){var t=this,n=Number(this.options.wheelZoomRatio)||.1,r=1;this.disabled||(e.preventDefault(),this.wheeling||(this.wheeling=!0,setTimeout((function(){t.wheeling=!1}),50),e.deltaY?r=e.deltaY>0?1:-1:e.wheelDelta?r=-e.wheelDelta/120:e.detail&&(r=e.detail>0?1:-1),this.zoom(-r*n,e)))},cropStart:function(e){var t=e.buttons,n=e.button;if(!(this.disabled||("mousedown"===e.type||"pointerdown"===e.type&&"mouse"===e.pointerType)&&(R(t)&&1!==t||R(n)&&0!==n||e.ctrlKey))){var r,i=this.options,o=this.pointers;e.changedTouches?F(e.changedTouches,(function(e){o[e.identifier]=fe(e)})):o[e.pointerId||0]=fe(e),r=Object.keys(o).length>1&&i.zoomable&&i.zoomOnTouch?"zoom":Z(e.target,g),k.test(r)&&!1!==ie(this.element,"cropstart",{originalEvent:e,action:r})&&(e.preventDefault(),this.action=r,this.cropping=!1,"crop"===r&&(this.cropping=!0,K(this.dragBox,m)))}},cropMove:function(e){var t=this.action;if(!this.disabled&&t){var n=this.pointers;e.preventDefault(),!1!==ie(this.element,"cropmove",{originalEvent:e,action:t})&&(e.changedTouches?F(e.changedTouches,(function(e){H(n[e.identifier]||{},fe(e,!0))})):H(n[e.pointerId||0]||{},fe(e,!0)),this.change(e))}},cropEnd:function(e){if(!this.disabled){var t=this.action,n=this.pointers;e.changedTouches?F(e.changedTouches,(function(e){delete n[e.identifier]})):delete n[e.pointerId||0],t&&(e.preventDefault(),Object.keys(n).length||(this.action=""),this.cropping&&(this.cropping=!1,X(this.dragBox,m,this.cropped&&this.options.modal)),ie(this.element,"cropend",{originalEvent:e,action:t}))}}},_e={change:function(e){var t,n=this.options,r=this.canvasData,i=this.containerData,a=this.cropBoxData,s=this.pointers,c=this.action,u=n.aspectRatio,l=a.left,f=a.top,p=a.width,h=a.height,y=l+p,m=f+h,v=0,g=0,b=i.width,w=i.height,_=!0;!u&&e.shiftKey&&(u=p&&h?p/h:1),this.limited&&(v=a.minLeft,g=a.minTop,b=v+Math.min(i.width,r.width,r.left+r.width),w=g+Math.min(i.height,r.height,r.top+r.height));var S=s[Object.keys(s)[0]],T={x:S.endX-S.startX,y:S.endY-S.startY},C=function(e){switch(e){case"e":y+T.x>b&&(T.x=b-y);break;case"w":l+T.x<v&&(T.x=v-l);break;case"n":f+T.y<g&&(T.y=g-f);break;case"s":m+T.y>w&&(T.y=w-m)}};switch(c){case"all":l+=T.x,f+=T.y;break;case"e":if(T.x>=0&&(y>=b||u&&(f<=g||m>=w))){_=!1;break}C("e"),(p+=T.x)<0&&(c="w",l-=p=-p),u&&(h=p/u,f+=(a.height-h)/2);break;case"n":if(T.y<=0&&(f<=g||u&&(l<=v||y>=b))){_=!1;break}C("n"),h-=T.y,f+=T.y,h<0&&(c="s",f-=h=-h),u&&(p=h*u,l+=(a.width-p)/2);break;case"w":if(T.x<=0&&(l<=v||u&&(f<=g||m>=w))){_=!1;break}C("w"),p-=T.x,l+=T.x,p<0&&(c="e",l-=p=-p),u&&(h=p/u,f+=(a.height-h)/2);break;case"s":if(T.y>=0&&(m>=w||u&&(l<=v||y>=b))){_=!1;break}C("s"),(h+=T.y)<0&&(c="n",f-=h=-h),u&&(p=h*u,l+=(a.width-p)/2);break;case"ne":if(u){if(T.y<=0&&(f<=g||y>=b)){_=!1;break}C("n"),h-=T.y,f+=T.y,p=h*u}else C("n"),C("e"),T.x>=0?y<b?p+=T.x:T.y<=0&&f<=g&&(_=!1):p+=T.x,T.y<=0?f>g&&(h-=T.y,f+=T.y):(h-=T.y,f+=T.y);p<0&&h<0?(c="sw",f-=h=-h,l-=p=-p):p<0?(c="nw",l-=p=-p):h<0&&(c="se",f-=h=-h);break;case"nw":if(u){if(T.y<=0&&(f<=g||l<=v)){_=!1;break}C("n"),h-=T.y,f+=T.y,p=h*u,l+=a.width-p}else C("n"),C("w"),T.x<=0?l>v?(p-=T.x,l+=T.x):T.y<=0&&f<=g&&(_=!1):(p-=T.x,l+=T.x),T.y<=0?f>g&&(h-=T.y,f+=T.y):(h-=T.y,f+=T.y);p<0&&h<0?(c="se",f-=h=-h,l-=p=-p):p<0?(c="ne",l-=p=-p):h<0&&(c="sw",f-=h=-h);break;case"sw":if(u){if(T.x<=0&&(l<=v||m>=w)){_=!1;break}C("w"),p-=T.x,l+=T.x,h=p/u}else C("s"),C("w"),T.x<=0?l>v?(p-=T.x,l+=T.x):T.y>=0&&m>=w&&(_=!1):(p-=T.x,l+=T.x),T.y>=0?m<w&&(h+=T.y):h+=T.y;p<0&&h<0?(c="ne",f-=h=-h,l-=p=-p):p<0?(c="se",l-=p=-p):h<0&&(c="nw",f-=h=-h);break;case"se":if(u){if(T.x>=0&&(y>=b||m>=w)){_=!1;break}C("e"),h=(p+=T.x)/u}else C("s"),C("e"),T.x>=0?y<b?p+=T.x:T.y>=0&&m>=w&&(_=!1):p+=T.x,T.y>=0?m<w&&(h+=T.y):h+=T.y;p<0&&h<0?(c="nw",f-=h=-h,l-=p=-p):p<0?(c="sw",l-=p=-p):h<0&&(c="ne",f-=h=-h);break;case"move":this.move(T.x,T.y),_=!1;break;case"zoom":this.zoom(function(e){var t=o({},e),n=[];return F(e,(function(e,r){delete t[r],F(t,(function(t){var r=Math.abs(e.startX-t.startX),i=Math.abs(e.startY-t.startY),o=Math.abs(e.endX-t.endX),a=Math.abs(e.endY-t.endY),s=Math.sqrt(r*r+i*i),c=(Math.sqrt(o*o+a*a)-s)/s;n.push(c)}))})),n.sort((function(e,t){return Math.abs(e)<Math.abs(t)})),n[0]}(s),e),_=!1;break;case"crop":if(!T.x||!T.y){_=!1;break}t=oe(this.cropper),l=S.startX-t.left,f=S.startY-t.top,p=a.minWidth,h=a.minHeight,T.x>0?c=T.y>0?"se":"ne":T.x<0&&(l-=p,c=T.y>0?"sw":"nw"),T.y<0&&(f-=h),this.cropped||(Y(this.cropBox,d),this.cropped=!0,this.limited&&this.limitCropBox(!0,!0))}_&&(a.width=p,a.height=h,a.left=l,a.top=f,this.action=c,this.renderCropBox()),F(s,(function(e){e.startX=e.endX,e.startY=e.endY}))}},Se={crop:function(){return!this.ready||this.cropped||this.disabled||(this.cropped=!0,this.limitCropBox(!0,!0),this.options.modal&&K(this.dragBox,m),Y(this.cropBox,d),this.setCropBoxData(this.initialCropBoxData)),this},reset:function(){return this.ready&&!this.disabled&&(this.imageData=H({},this.initialImageData),this.canvasData=H({},this.initialCanvasData),this.cropBoxData=H({},this.initialCropBoxData),this.renderCanvas(),this.cropped&&this.renderCropBox()),this},clear:function(){return this.cropped&&!this.disabled&&(H(this.cropBoxData,{left:0,top:0,width:0,height:0}),this.cropped=!1,this.renderCropBox(),this.limitCanvas(!0,!0),this.renderCanvas(),Y(this.dragBox,m),K(this.cropBox,d)),this},replace:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return!this.disabled&&e&&(this.isImg&&(this.element.src=e),t?(this.url=e,this.image.src=e,this.ready&&(this.viewBoxImage.src=e,F(this.previews,(function(t){t.getElementsByTagName("img")[0].src=e})))):(this.isImg&&(this.replaced=!0),this.options.data=null,this.uncreate(),this.load(e))),this},enable:function(){return this.ready&&this.disabled&&(this.disabled=!1,Y(this.cropper,p)),this},disable:function(){return this.ready&&!this.disabled&&(this.disabled=!0,K(this.cropper,p)),this},destroy:function(){var e=this.element;return e.cropper?(e.cropper=void 0,this.isImg&&this.replaced&&(e.src=this.originalUrl),this.uncreate(),this):this},move:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e,n=this.canvasData,r=n.left,i=n.top;return this.moveTo(j(e)?e:r+Number(e),j(t)?t:i+Number(t))},moveTo:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e,n=this.canvasData,r=!1;return e=Number(e),t=Number(t),this.ready&&!this.disabled&&this.options.movable&&(R(e)&&(n.left=e,r=!0),R(t)&&(n.top=t,r=!0),r&&this.renderCanvas(!0)),this},zoom:function(e,t){var n=this.canvasData;return e=(e=Number(e))<0?1/(1-e):1+e,this.zoomTo(n.width*e/n.naturalWidth,null,t)},zoomTo:function(e,t,n){var r=this.options,i=this.canvasData,o=i.width,a=i.height,s=i.naturalWidth,c=i.naturalHeight;if((e=Number(e))>=0&&this.ready&&!this.disabled&&r.zoomable){var u=s*e,l=c*e;if(!1===ie(this.element,"zoom",{ratio:e,oldRatio:o/s,originalEvent:n}))return this;if(n){var f=this.pointers,p=oe(this.cropper),d=f&&Object.keys(f).length?function(e){var t=0,n=0,r=0;return F(e,(function(e){var i=e.startX,o=e.startY;t+=i,n+=o,r+=1})),{pageX:t/=r,pageY:n/=r}}(f):{pageX:n.pageX,pageY:n.pageY};i.left-=(u-o)*((d.pageX-p.left-i.left)/o),i.top-=(l-a)*((d.pageY-p.top-i.top)/a)}else B(t)&&R(t.x)&&R(t.y)?(i.left-=(u-o)*((t.x-i.left)/o),i.top-=(l-a)*((t.y-i.top)/a)):(i.left-=(u-o)/2,i.top-=(l-a)/2);i.width=u,i.height=l,this.renderCanvas(!0)}return this},rotate:function(e){return this.rotateTo((this.imageData.rotate||0)+Number(e))},rotateTo:function(e){return R(e=Number(e))&&this.ready&&!this.disabled&&this.options.rotatable&&(this.imageData.rotate=e%360,this.renderCanvas(!0,!0)),this},scaleX:function(e){var t=this.imageData.scaleY;return this.scale(e,R(t)?t:1)},scaleY:function(e){var t=this.imageData.scaleX;return this.scale(R(t)?t:1,e)},scale:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e,n=this.imageData,r=!1;return e=Number(e),t=Number(t),this.ready&&!this.disabled&&this.options.scalable&&(R(e)&&(n.scaleX=e,r=!0),R(t)&&(n.scaleY=t,r=!0),r&&this.renderCanvas(!0,!0)),this},getData:function(){var e,t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],n=this.options,r=this.imageData,i=this.canvasData,o=this.cropBoxData;if(this.ready&&this.cropped){e={x:o.left-i.left,y:o.top-i.top,width:o.width,height:o.height};var a=r.width/r.naturalWidth;if(F(e,(function(t,n){e[n]=t/a})),t){var s=Math.round(e.y+e.height),c=Math.round(e.x+e.width);e.x=Math.round(e.x),e.y=Math.round(e.y),e.width=c-e.x,e.height=s-e.y}}else e={x:0,y:0,width:0,height:0};return n.rotatable&&(e.rotate=r.rotate||0),n.scalable&&(e.scaleX=r.scaleX||1,e.scaleY=r.scaleY||1),e},setData:function(e){var t=this.options,n=this.imageData,r=this.canvasData,i={};if(this.ready&&!this.disabled&&B(e)){var o=!1;t.rotatable&&R(e.rotate)&&e.rotate!==n.rotate&&(n.rotate=e.rotate,o=!0),t.scalable&&(R(e.scaleX)&&e.scaleX!==n.scaleX&&(n.scaleX=e.scaleX,o=!0),R(e.scaleY)&&e.scaleY!==n.scaleY&&(n.scaleY=e.scaleY,o=!0)),o&&this.renderCanvas(!0,!0);var a=n.width/n.naturalWidth;R(e.x)&&(i.left=e.x*a+r.left),R(e.y)&&(i.top=e.y*a+r.top),R(e.width)&&(i.width=e.width*a),R(e.height)&&(i.height=e.height*a),this.setCropBoxData(i)}return this},getContainerData:function(){return this.ready?H({},this.containerData):{}},getImageData:function(){return this.sized?H({},this.imageData):{}},getCanvasData:function(){var e=this.canvasData,t={};return this.ready&&F(["left","top","width","height","naturalWidth","naturalHeight"],(function(n){t[n]=e[n]})),t},setCanvasData:function(e){var t=this.canvasData,n=t.aspectRatio;return this.ready&&!this.disabled&&B(e)&&(R(e.left)&&(t.left=e.left),R(e.top)&&(t.top=e.top),R(e.width)?(t.width=e.width,t.height=e.width/n):R(e.height)&&(t.height=e.height,t.width=e.height*n),this.renderCanvas(!0)),this},getCropBoxData:function(){var e,t=this.cropBoxData;return this.ready&&this.cropped&&(e={left:t.left,top:t.top,width:t.width,height:t.height}),e||{}},setCropBoxData:function(e){var t,n,r=this.cropBoxData,i=this.options.aspectRatio;return this.ready&&this.cropped&&!this.disabled&&B(e)&&(R(e.left)&&(r.left=e.left),R(e.top)&&(r.top=e.top),R(e.width)&&e.width!==r.width&&(t=!0,r.width=e.width),R(e.height)&&e.height!==r.height&&(n=!0,r.height=e.height),i&&(t?r.height=r.width/i:n&&(r.width=r.height*i)),this.renderCropBox()),this},getCroppedCanvas:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(!this.ready||!window.HTMLCanvasElement)return null;var t=this.canvasData,n=de(this.image,this.imageData,t,e);if(!this.cropped)return n;var r=this.getData(),i=r.x,o=r.y,s=r.width,c=r.height,u=n.width/Math.floor(t.naturalWidth);1!==u&&(i*=u,o*=u,s*=u,c*=u);var l=s/c,f=pe({aspectRatio:l,width:e.maxWidth||1/0,height:e.maxHeight||1/0}),p=pe({aspectRatio:l,width:e.minWidth||0,height:e.minHeight||0},"cover"),d=pe({aspectRatio:l,width:e.width||(1!==u?n.width:s),height:e.height||(1!==u?n.height:c)}),h=d.width,y=d.height;h=Math.min(f.width,Math.max(p.width,h)),y=Math.min(f.height,Math.max(p.height,y));var m=document.createElement("canvas"),v=m.getContext("2d");m.width=W(h),m.height=W(y),v.fillStyle=e.fillColor||"transparent",v.fillRect(0,0,h,y);var g=e.imageSmoothingEnabled,b=void 0===g||g,w=e.imageSmoothingQuality;v.imageSmoothingEnabled=b,w&&(v.imageSmoothingQuality=w);var _,S,T,C,E,k,O=n.width,P=n.height,A=i,I=o;A<=-s||A>O?(A=0,_=0,T=0,E=0):A<=0?(T=-A,A=0,E=_=Math.min(O,s+A)):A<=O&&(T=0,E=_=Math.min(s,O-A)),_<=0||I<=-c||I>P?(I=0,S=0,C=0,k=0):I<=0?(C=-I,I=0,k=S=Math.min(P,c+I)):I<=P&&(C=0,k=S=Math.min(c,P-I));var x=[A,I,_,S];if(E>0&&k>0){var R=h/s;x.push(T*R,C*R,E*R,k*R)}return v.drawImage.apply(v,[n].concat(a(x.map((function(e){return Math.floor(W(e))}))))),m},setAspectRatio:function(e){var t=this.options;return this.disabled||j(e)||(t.aspectRatio=Math.max(0,e)||NaN,this.ready&&(this.initCropBox(),this.cropped&&this.renderCropBox())),this},setDragMode:function(e){var t=this.options,n=this.dragBox,r=this.face;if(this.ready&&!this.disabled){var i="crop"===e,o=t.movable&&"move"===e;e=i||o?e:"none",t.dragMode=e,J(n,g,e),X(n,f,i),X(n,v,o),t.cropBoxMovable||(J(r,g,e),X(r,f,i),X(r,v,o))}return this}},Te=c.Cropper,Ce=function(){function e(n){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(t(this,e),!n||!A.test(n.tagName))throw new Error("The first argument is required and must be an <img> or <canvas> element.");this.element=n,this.options=H({},I,B(r)&&r),this.cropped=!1,this.disabled=!1,this.pointers={},this.ready=!1,this.reloading=!1,this.replaced=!1,this.sized=!1,this.sizing=!1,this.init()}var r,i,o;return r=e,o=[{key:"noConflict",value:function(){return window.Cropper=Te,e}},{key:"setDefaults",value:function(e){H(I,B(e)&&e)}}],(i=[{key:"init",value:function(){var e,t=this.element,n=t.tagName.toLowerCase();if(!t.cropper){if(t.cropper=this,"img"===n){if(this.isImg=!0,e=t.getAttribute("src")||"",this.originalUrl=e,!e)return;e=t.src}else"canvas"===n&&window.HTMLCanvasElement&&(e=t.toDataURL());this.load(e)}}},{key:"load",value:function(e){var t=this;if(e){this.url=e,this.imageData={};var n=this.element,r=this.options;if(r.rotatable||r.scalable||(r.checkOrientation=!1),r.checkOrientation&&window.ArrayBuffer)if(O.test(e))P.test(e)?this.read((i=e.replace(ye,""),o=atob(i),a=new ArrayBuffer(o.length),F(s=new Uint8Array(a),(function(e,t){s[t]=o.charCodeAt(t)})),a)):this.clone();else{var i,o,a,s,c=new XMLHttpRequest,u=this.clone.bind(this);this.reloading=!0,this.xhr=c,c.onabort=u,c.onerror=u,c.ontimeout=u,c.onprogress=function(){"image/jpeg"!==c.getResponseHeader("content-type")&&c.abort()},c.onload=function(){t.read(c.response)},c.onloadend=function(){t.reloading=!1,t.xhr=null},r.checkCrossOrigin&&ce(e)&&n.crossOrigin&&(e=ue(e)),c.open("GET",e),c.responseType="arraybuffer",c.withCredentials="use-credentials"===n.crossOrigin,c.send()}else this.clone()}}},{key:"read",value:function(e){var t=this.options,n=this.imageData,r=me(e),i=0,o=1,a=1;if(r>1){this.url=function(e,t){for(var n=[],r=new Uint8Array(e);r.length>0;)n.push(he.apply(null,V(r.subarray(0,8192)))),r=r.subarray(8192);return"data:".concat(t,";base64,").concat(btoa(n.join("")))}(e,"image/jpeg");var s=function(e){var t=0,n=1,r=1;switch(e){case 2:n=-1;break;case 3:t=-180;break;case 4:r=-1;break;case 5:t=90,r=-1;break;case 6:t=90;break;case 7:t=90,n=-1;break;case 8:t=-90}return{rotate:t,scaleX:n,scaleY:r}}(r);i=s.rotate,o=s.scaleX,a=s.scaleY}t.rotatable&&(n.rotate=i),t.scalable&&(n.scaleX=o,n.scaleY=a),this.clone()}},{key:"clone",value:function(){var e=this.element,t=this.url,n=e.crossOrigin,r=t;this.options.checkCrossOrigin&&ce(t)&&(n||(n="anonymous"),r=ue(t)),this.crossOrigin=n,this.crossOriginUrl=r;var i=document.createElement("img");n&&(i.crossOrigin=n),i.src=r||t,i.alt=e.alt||"The image to crop",this.image=i,i.onload=this.start.bind(this),i.onerror=this.stop.bind(this),K(i,h),e.parentNode.insertBefore(i,e.nextSibling)}},{key:"start",value:function(){var e=this,t=this.image;t.onload=null,t.onerror=null,this.sizing=!0;var n=c.navigator&&/(?:iPad|iPhone|iPod).*?AppleWebKit/i.test(c.navigator.userAgent),r=function(t,n){H(e.imageData,{naturalWidth:t,naturalHeight:n,aspectRatio:t/n}),e.sizing=!1,e.sized=!0,e.build()};if(!t.naturalWidth||n){var i=document.createElement("img"),o=document.body||document.documentElement;this.sizingImage=i,i.onload=function(){r(i.width,i.height),n||o.removeChild(i)},i.src=t.src,n||(i.style.cssText="left:0;max-height:none!important;max-width:none!important;min-height:0!important;min-width:0!important;opacity:0;position:absolute;top:0;z-index:-1;",o.appendChild(i))}else r(t.naturalWidth,t.naturalHeight)}},{key:"stop",value:function(){var e=this.image;e.onload=null,e.onerror=null,e.parentNode.removeChild(e),this.image=null}},{key:"build",value:function(){if(this.sized&&!this.ready){var e=this.element,t=this.options,n=this.image,r=e.parentNode,i=document.createElement("div");i.innerHTML='<div class="cropper-container" touch-action="none"><div class="cropper-wrap-box"><div class="cropper-canvas"></div></div><div class="cropper-drag-box"></div><div class="cropper-crop-box"><span class="cropper-view-box"></span><span class="cropper-dashed dashed-h"></span><span class="cropper-dashed dashed-v"></span><span class="cropper-center"></span><span class="cropper-face"></span><span class="cropper-line line-e" data-cropper-action="e"></span><span class="cropper-line line-n" data-cropper-action="n"></span><span class="cropper-line line-w" data-cropper-action="w"></span><span class="cropper-line line-s" data-cropper-action="s"></span><span class="cropper-point point-e" data-cropper-action="e"></span><span class="cropper-point point-n" data-cropper-action="n"></span><span class="cropper-point point-w" data-cropper-action="w"></span><span class="cropper-point point-s" data-cropper-action="s"></span><span class="cropper-point point-ne" data-cropper-action="ne"></span><span class="cropper-point point-nw" data-cropper-action="nw"></span><span class="cropper-point point-sw" data-cropper-action="sw"></span><span class="cropper-point point-se" data-cropper-action="se"></span></div></div>';var o=i.querySelector(".".concat("cropper","-container")),a=o.querySelector(".".concat("cropper","-canvas")),s=o.querySelector(".".concat("cropper","-drag-box")),c=o.querySelector(".".concat("cropper","-crop-box")),u=c.querySelector(".".concat("cropper","-face"));this.container=r,this.cropper=o,this.canvas=a,this.dragBox=s,this.cropBox=c,this.viewBox=o.querySelector(".".concat("cropper","-view-box")),this.face=u,a.appendChild(n),K(e,d),r.insertBefore(o,e.nextSibling),this.isImg||Y(n,h),this.initPreview(),this.bind(),t.initialAspectRatio=Math.max(0,t.initialAspectRatio)||NaN,t.aspectRatio=Math.max(0,t.aspectRatio)||NaN,t.viewMode=Math.max(0,Math.min(3,Math.round(t.viewMode)))||0,K(c,d),t.guides||K(c.getElementsByClassName("".concat("cropper","-dashed")),d),t.center||K(c.getElementsByClassName("".concat("cropper","-center")),d),t.background&&K(o,"".concat("cropper","-bg")),t.highlight||K(u,y),t.cropBoxMovable&&(K(u,v),J(u,g,"all")),t.cropBoxResizable||(K(c.getElementsByClassName("".concat("cropper","-line")),d),K(c.getElementsByClassName("".concat("cropper","-point")),d)),this.render(),this.ready=!0,this.setDragMode(t.dragMode),t.autoCrop&&this.crop(),this.setData(t.data),U(t.ready)&&re(e,"ready",t.ready,{once:!0}),ie(e,"ready")}}},{key:"unbuild",value:function(){this.ready&&(this.ready=!1,this.unbind(),this.resetPreview(),this.cropper.parentNode.removeChild(this.cropper),Y(this.element,d))}},{key:"uncreate",value:function(){this.ready?(this.unbuild(),this.ready=!1,this.cropped=!1):this.sizing?(this.sizingImage.onload=null,this.sizing=!1,this.sized=!1):this.reloading?(this.xhr.onabort=null,this.xhr.abort()):this.image&&this.stop()}}])&&n(r.prototype,i),o&&n(r,o),e}();return H(Ce.prototype,ve,ge,be,we,_e,Se),Ce}()},function(e,t,n){var r=n(121);e.exports=(r.default||r).template({1:function(e,t,n,r,i){e.propertyIsEnumerable;var o,a=e.lambda,s=e.escapeExpression;return'<span class="badge badge-danger badge-pill '+s(a(null!=(o=null!=(o=null!=t?t.options:t)?o.styles:o)?o.unreadCount:o,t))+'">'+s(a(null!=(o=null!=t?t.options:t)?o.unreadCount:o,t))+"</span>\r\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){var o;e.propertyIsEnumerable;return(null!=(o=e.lambda(null!=(o=null!=t?t.options:t)?o.svg:o,t))?o:"")+"\r\n"+(null!=(o=n.if.call(null!=t?t:e.nullContext||{},null!=(o=null!=t?t.options:t)?o.unreadCount:o,{name:"if",hash:{},fn:e.program(1,i,0),inverse:e.noop,data:i}))?o:"")},useData:!0})},function(e,t,n){var r=n(121);e.exports=(r.default||r).template({1:function(e,t,n,r,i){var o;e.propertyIsEnumerable;return'<h4 class="mt-3 text-muted">'+e.escapeExpression(e.lambda(null!=(o=null!=t?t.options:t)?o.heading:o,t))+"</h4>\r\n"},3:function(e,t,n,r,i){var o;e.propertyIsEnumerable;return"<p>"+(null!=(o=e.lambda(null!=(o=null!=t?t.options:t)?o.description:o,t))?o:"")+"</p>\r\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){e.propertyIsEnumerable;var o,a=e.lambda,s=e.escapeExpression,c=null!=t?t:e.nullContext||{};return'<img src="'+s(a(null!=(o=null!=t?t.options:t)?o.imageUrl:o,t))+'" class="'+s(a(null!=(o=null!=t?t.options:t)?o.imageClass:o,t))+'"/>\r\n'+(null!=(o=n.if.call(c,null!=(o=null!=t?t.options:t)?o.heading:o,{name:"if",hash:{},fn:e.program(1,i,0),inverse:e.noop,data:i}))?o:"")+(null!=(o=n.if.call(c,null!=(o=null!=t?t.options:t)?o.description:o,{name:"if",hash:{},fn:e.program(3,i,0),inverse:e.noop,data:i}))?o:"")},useData:!0})},function(e,t,n){var r=n(121);e.exports=(r.default||r).template({1:function(e,t,n,r,i){e.propertyIsEnumerable;var o,a=e.lambda,s=e.escapeExpression;return' <span class="text-right pl-2 '+s(a(null!=(o=null!=(o=null!=t?t.options:t)?o.styles:o)?o.actionText:o,t))+'">'+s(a(null!=(o=null!=t?t.options:t)?o.actionText:o,t))+"</span>\r\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){e.propertyIsEnumerable;var o,a=e.lambda,s=e.escapeExpression;return'<div class="'+s(a(null!=(o=null!=(o=null!=t?t.options:t)?o.styles:o)?o.icon:o,t))+" "+s(a(null!=(o=null!=t?t.options:t)?o.iconClass:o,t))+'">'+(null!=(o=a(null!=(o=null!=t?t.options:t)?o.icon:o,t))?o:"")+'</div><div class="'+s(a(null!=(o=null!=(o=null!=t?t.options:t)?o.styles:o)?o.contentContainer:o,t))+'">\r\n <div class="clamp-2 pl-1">'+s(a(null!=(o=null!=t?t.options:t)?o.content:o,t))+"</div>\r\n"+(null!=(o=n.if.call(null!=t?t:e.nullContext||{},null!=(o=null!=t?t.options:t)?o.showActionText:o,{name:"if",hash:{},fn:e.program(1,i,0),inverse:e.noop,data:i}))?o:"")+' <div class="'+s(a(null!=(o=null!=(o=null!=t?t.options:t)?o.styles:o)?o.notificationTime:o,t))+' pl-1">'+s(a(null!=(o=null!=t?t.options:t)?o.notificationTime:o,t))+"</div>\r\n</div>"},useData:!0})},function(e,t,n){var r=n(121);e.exports=(r.default||r).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){return'<div class="notifications-region"></div>'},useData:!0})},function(e,t,n){var r=n(121);e.exports=(r.default||r).template({1:function(e,t,n,r,i){e.propertyIsEnumerable;return'<div class="py-2 border-top text-right px-2">\r\n <a class="see-all">'+e.escapeExpression((n.lang||t&&t.lang||e.hooks.helperMissing).call(null!=t?t:e.nullContext||{},"seeAll",{name:"lang",hash:{},data:i}))+"</div>\r\n</div>\r\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){e.propertyIsEnumerable;var o,a=null!=t?t:e.nullContext||{};return'<h5 class="header p-2 m-0 border-bottom">'+e.escapeExpression((n.lang||t&&t.lang||e.hooks.helperMissing).call(a,"notifications",{name:"lang",hash:{},data:i}))+'</h5>\r\n<div class="list-region"></div>\r\n'+(null!=(o=n.if.call(a,null!=(o=null!=t?t.options:t)?o.hasNotifications:o,{name:"if",hash:{},fn:e.program(1,i,0),inverse:e.noop,data:i}))?o:"")},useData:!0})},function(e,t,n){var r=n(121);e.exports=(r.default||r).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){var o;e.propertyIsEnumerable;return'<div id="notificationsDropdown" class="notifications-status-region" data-toggle="dropdown"></div>\r\n<div aria-labelledby="notificationsDropdown" class="notifications-region dropdown-menu dropdown-menu-right dropdown-arrow p-0 '+e.escapeExpression(e.lambda(null!=(o=null!=t?t.options:t)?o.notificationsContainer:o,t))+'"></div>'},useData:!0})},function(e,t,n){e.exports={avatar:"_1XSQR"}},function(e,t,n){"use strict";var r=n(542);n.o(r,"PlaylistVideoCollectionIdentifier")&&n.d(t,"PlaylistVideoCollectionIdentifier",(function(){return r.PlaylistVideoCollectionIdentifier}));var i=n(728);n.d(t,"PlaylistVideoCollectionIdentifier",(function(){return i.a}))},function(e,t,n){"use strict";var r=n(546);n.o(r,"MicrosoftTeamsProduct")&&n.d(t,"MicrosoftTeamsProduct",(function(){return r.MicrosoftTeamsProduct}));var i=n(547);n.d(t,"MicrosoftTeamsProduct",(function(){return i.a}));n(548)},function(e,t,n){e.exports={radioFilter:"vo-iA"}},function(e,t){e.exports=function(e,t){var n,r=null;try{n=JSON.parse(e,t)}catch(e){r=e}return[r,n]}},function(e,t,n){var r=n(329),i=n(786);function o(t,n,a){return i()?(e.exports=o=Reflect.construct,e.exports.default=e.exports,e.exports.__esModule=!0):(e.exports=o=function(e,t,n){var i=[null];i.push.apply(i,t);var o=new(Function.bind.apply(e,i));return n&&r(o,n.prototype),o},e.exports.default=e.exports,e.exports.__esModule=!0),o.apply(null,arguments)}e.exports=o,e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){var r=n(329);e.exports=function(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}}),t&&r(e,t)},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){function r(e){this.options=e||{locator:{}}}function i(){this.cdata=!1}function o(e,t){t.lineNumber=e.lineNumber,t.columnNumber=e.columnNumber}function a(e){if(e)return"\n@"+(e.systemId||"")+"#[line:"+e.lineNumber+",col:"+e.columnNumber+"]"}function s(e,t,n){return"string"==typeof e?e.substr(t,n):e.length>=t+n||t?new java.lang.String(e,t,n)+"":e}function c(e,t){e.currentElement?e.currentElement.appendChild(t):e.doc.appendChild(t)}r.prototype.parseFromString=function(e,t){var n=this.options,r=new u,o=n.domBuilder||new i,s=n.errorHandler,c=n.locator,l=n.xmlns||{},f={lt:"<",gt:">",amp:"&",quot:'"',apos:"'"};return c&&o.setDocumentLocator(c),r.errorHandler=function(e,t,n){if(!e){if(t instanceof i)return t;e=t}var r={},o=e instanceof Function;function s(t){var i=e[t];!i&&o&&(i=2==e.length?function(n){e(t,n)}:e),r[t]=i&&function(e){i("[xmldom "+t+"]\t"+e+a(n))}||function(){}}return n=n||{},s("warning"),s("error"),s("fatalError"),r}(s,o,c),r.domBuilder=n.domBuilder||o,/\/x?html?$/.test(t)&&(f.nbsp=" ",f.copy="©",l[""]="http://www.w3.org/1999/xhtml"),l.xml=l.xml||"http://www.w3.org/XML/1998/namespace",e?r.parse(e,l,f):r.errorHandler.error("invalid doc source"),o.doc},i.prototype={startDocument:function(){this.doc=(new l).createDocument(null,null,null),this.locator&&(this.doc.documentURI=this.locator.systemId)},startElement:function(e,t,n,r){var i=this.doc,a=i.createElementNS(e,n||t),s=r.length;c(this,a),this.currentElement=a,this.locator&&o(this.locator,a);for(var u=0;u<s;u++){e=r.getURI(u);var l=r.getValue(u),f=(n=r.getQName(u),i.createAttributeNS(e,n));this.locator&&o(r.getLocator(u),f),f.value=f.nodeValue=l,a.setAttributeNode(f)}},endElement:function(e,t,n){var r=this.currentElement;r.tagName;this.currentElement=r.parentNode},startPrefixMapping:function(e,t){},endPrefixMapping:function(e){},processingInstruction:function(e,t){var n=this.doc.createProcessingInstruction(e,t);this.locator&&o(this.locator,n),c(this,n)},ignorableWhitespace:function(e,t,n){},characters:function(e,t,n){if(e=s.apply(this,arguments)){if(this.cdata)var r=this.doc.createCDATASection(e);else r=this.doc.createTextNode(e);this.currentElement?this.currentElement.appendChild(r):/^\s*$/.test(e)&&this.doc.appendChild(r),this.locator&&o(this.locator,r)}},skippedEntity:function(e){},endDocument:function(){this.doc.normalize()},setDocumentLocator:function(e){(this.locator=e)&&(e.lineNumber=0)},comment:function(e,t,n){e=s.apply(this,arguments);var r=this.doc.createComment(e);this.locator&&o(this.locator,r),c(this,r)},startCDATA:function(){this.cdata=!0},endCDATA:function(){this.cdata=!1},startDTD:function(e,t,n){var r=this.doc.implementation;if(r&&r.createDocumentType){var i=r.createDocumentType(e,t,n);this.locator&&o(this.locator,i),c(this,i)}},warning:function(e){console.warn("[xmldom warning]\t"+e,a(this.locator))},error:function(e){console.error("[xmldom error]\t"+e,a(this.locator))},fatalError:function(e){throw console.error("[xmldom fatalError]\t"+e,a(this.locator)),e}},"endDTD,startEntity,endEntity,attributeDecl,elementDecl,externalEntityDecl,internalEntityDecl,resolveEntity,getExternalSubset,notationDecl,unparsedEntityDecl".replace(/\w+/g,(function(e){i.prototype[e]=function(){return null}}));var u=n(791).XMLReader,l=t.DOMImplementation=n(551).DOMImplementation;t.XMLSerializer=n(551).XMLSerializer,t.DOMParser=r},function(e,t){var n=Math.pow(2,32);e.exports=function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength),r={version:e[0],flags:new Uint8Array(e.subarray(1,4)),references:[],referenceId:t.getUint32(4),timescale:t.getUint32(8)},i=12;0===r.version?(r.earliestPresentationTime=t.getUint32(i),r.firstOffset=t.getUint32(i+4),i+=8):(r.earliestPresentationTime=t.getUint32(i)*n+t.getUint32(i+4),r.firstOffset=t.getUint32(i+8)*n+t.getUint32(i+12),i+=16),i+=2;var o=t.getUint16(i);for(i+=2;o>0;i+=12,o--)r.references.push({referenceType:(128&e[i])>>>7,referencedSize:2147483647&t.getUint32(i),subsegmentDuration:t.getUint32(i+4),startsWithSap:!!(128&e[i+8]),sapType:(112&e[i+8])>>>4,sapDeltaTime:268435455&t.getUint32(i+8)});return r}},function(e,t,n){"use strict";var r=n(552),i=n(792).handleRollover,o={};o.ts=n(794),o.aac=n(795);var a=n(186).ONE_SECOND_IN_TS,s=function(e,t,n){for(var r,i,a,s,c=0,u=188,l=!1;u<=e.byteLength;)if(71!==e[c]||71!==e[u]&&u!==e.byteLength)c++,u++;else{switch(r=e.subarray(c,u),o.ts.parseType(r,t.pid)){case"pes":i=o.ts.parsePesType(r,t.table),a=o.ts.parsePayloadUnitStartIndicator(r),"audio"===i&&a&&(s=o.ts.parsePesTime(r))&&(s.type="audio",n.audio.push(s),l=!0)}if(l)break;c+=188,u+=188}for(c=(u=e.byteLength)-188,l=!1;c>=0;)if(71!==e[c]||71!==e[u]&&u!==e.byteLength)c--,u--;else{switch(r=e.subarray(c,u),o.ts.parseType(r,t.pid)){case"pes":i=o.ts.parsePesType(r,t.table),a=o.ts.parsePayloadUnitStartIndicator(r),"audio"===i&&a&&(s=o.ts.parsePesTime(r))&&(s.type="audio",n.audio.push(s),l=!0)}if(l)break;c-=188,u-=188}},c=function(e,t,n){for(var r,i,a,s,c,u,l,f=0,p=188,d=!1,h={data:[],size:0};p<e.byteLength;)if(71!==e[f]||71!==e[p])f++,p++;else{switch(r=e.subarray(f,p),o.ts.parseType(r,t.pid)){case"pes":if(i=o.ts.parsePesType(r,t.table),a=o.ts.parsePayloadUnitStartIndicator(r),"video"===i&&(a&&!d&&(s=o.ts.parsePesTime(r))&&(s.type="video",n.video.push(s),d=!0),!n.firstKeyFrame)){if(a&&0!==h.size){for(c=new Uint8Array(h.size),u=0;h.data.length;)l=h.data.shift(),c.set(l,u),u+=l.byteLength;if(o.ts.videoPacketContainsKeyFrame(c)){var y=o.ts.parsePesTime(c);y?(n.firstKeyFrame=y,n.firstKeyFrame.type="video"):console.warn("Failed to extract PTS/DTS from PES at first keyframe. This could be an unusual TS segment, or else mux.js did not parse your TS segment correctly. If you know your TS segments do contain PTS/DTS on keyframes please file a bug report! You can try ffprobe to double check for yourself.")}h.size=0}h.data.push(r),h.size+=r.byteLength}}if(d&&n.firstKeyFrame)break;f+=188,p+=188}for(f=(p=e.byteLength)-188,d=!1;f>=0;)if(71!==e[f]||71!==e[p])f--,p--;else{switch(r=e.subarray(f,p),o.ts.parseType(r,t.pid)){case"pes":i=o.ts.parsePesType(r,t.table),a=o.ts.parsePayloadUnitStartIndicator(r),"video"===i&&a&&(s=o.ts.parsePesTime(r))&&(s.type="video",n.video.push(s),d=!0)}if(d)break;f-=188,p-=188}},u=function(e){var t={pid:null,table:null},n={};for(var i in function(e,t){for(var n,r=0,i=188;i<e.byteLength;)if(71!==e[r]||71!==e[i])r++,i++;else{switch(n=e.subarray(r,i),o.ts.parseType(n,t.pid)){case"pat":t.pid||(t.pid=o.ts.parsePat(n));break;case"pmt":t.table||(t.table=o.ts.parsePmt(n))}if(t.pid&&t.table)return;r+=188,i+=188}}(e,t),t.table){if(t.table.hasOwnProperty(i))switch(t.table[i]){case r.H264_STREAM_TYPE:n.video=[],c(e,t,n),0===n.video.length&&delete n.video;break;case r.ADTS_STREAM_TYPE:n.audio=[],s(e,t,n),0===n.audio.length&&delete n.audio}}return n};e.exports={inspect:function(e,t){var n;return(n=o.aac.isLikelyAacData(e)?function(e){for(var t,n=!1,r=0,i=null,s=null,c=0,u=0;e.length-u>=3;){switch(o.aac.parseType(e,u)){case"timed-metadata":if(e.length-u<10){n=!0;break}if((c=o.aac.parseId3TagSize(e,u))>e.length){n=!0;break}null===s&&(t=e.subarray(u,u+c),s=o.aac.parseAacTimestamp(t)),u+=c;break;case"audio":if(e.length-u<7){n=!0;break}if((c=o.aac.parseAdtsSize(e,u))>e.length){n=!0;break}null===i&&(t=e.subarray(u,u+c),i=o.aac.parseSampleRate(t)),r++,u+=c;break;default:u++}if(n)return null}if(null===i||null===s)return null;var l=a/i;return{audio:[{type:"audio",dts:s,pts:s},{type:"audio",dts:s+1024*r*l,pts:s+1024*r*l}]}}(e):u(e))&&(n.audio||n.video)?(function(e,t){if(e.audio&&e.audio.length){var n=t;void 0===n&&(n=e.audio[0].dts),e.audio.forEach((function(e){e.dts=i(e.dts,n),e.pts=i(e.pts,n),e.dtsTime=e.dts/a,e.ptsTime=e.pts/a}))}if(e.video&&e.video.length){var r=t;if(void 0===r&&(r=e.video[0].dts),e.video.forEach((function(e){e.dts=i(e.dts,r),e.pts=i(e.pts,r),e.dtsTime=e.dts/a,e.ptsTime=e.pts/a})),e.firstKeyFrame){var o=e.firstKeyFrame;o.dts=i(o.dts,r),o.pts=i(o.pts,r),o.dtsTime=o.dts/a,o.ptsTime=o.dts/a}}}(n,t),n):null},parseAudioPes_:s}},function(e){e.exports=JSON.parse('{"a":"0.0.20-dev.0"}')},function(e,t,n){e.exports=function(){"use strict";var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(t,n)},t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";function n(e,t,n,r){var i,o,a,s=t||[0],c=(n=n||0)>>>3,u=-1===r?3:0;for(i=0;i<e.length;i+=1)o=(a=i+c)>>>2,s.length<=o&&s.push(0),s[o]|=e[i]<<8*(u+r*(a%4));return{value:s,binLen:8*e.length+n}}function r(e,r,i){switch(r){case"UTF8":case"UTF16BE":case"UTF16LE":break;default:throw new Error("encoding must be UTF8, UTF16BE, or UTF16LE")}switch(e){case"HEX":return function(e,t,n){return function(e,t,n,r){var i,o,a,s;if(0!=e.length%2)throw new Error("String of HEX type must be in byte increments");var c=t||[0],u=(n=n||0)>>>3,l=-1===r?3:0;for(i=0;i<e.length;i+=2){if(o=parseInt(e.substr(i,2),16),isNaN(o))throw new Error("String of HEX type contains invalid characters");for(a=(s=(i>>>1)+u)>>>2;c.length<=a;)c.push(0);c[a]|=o<<8*(l+r*(s%4))}return{value:c,binLen:4*e.length+n}}(e,t,n,i)};case"TEXT":return function(e,t,n){return function(e,t,n,r,i){var o,a,s,c,u,l,f,p,d=0,h=n||[0],y=(r=r||0)>>>3;if("UTF8"===t)for(f=-1===i?3:0,s=0;s<e.length;s+=1)for(a=[],128>(o=e.charCodeAt(s))?a.push(o):2048>o?(a.push(192|o>>>6),a.push(128|63&o)):55296>o||57344<=o?a.push(224|o>>>12,128|o>>>6&63,128|63&o):(s+=1,o=65536+((1023&o)<<10|1023&e.charCodeAt(s)),a.push(240|o>>>18,128|o>>>12&63,128|o>>>6&63,128|63&o)),c=0;c<a.length;c+=1){for(u=(l=d+y)>>>2;h.length<=u;)h.push(0);h[u]|=a[c]<<8*(f+i*(l%4)),d+=1}else for(f=-1===i?2:0,p="UTF16LE"===t&&1!==i||"UTF16LE"!==t&&1===i,s=0;s<e.length;s+=1){for(o=e.charCodeAt(s),!0===p&&(o=(c=255&o)<<8|o>>>8),u=(l=d+y)>>>2;h.length<=u;)h.push(0);h[u]|=o<<8*(f+i*(l%4)),d+=2}return{value:h,binLen:8*d+r}}(e,r,t,n,i)};case"B64":return function(e,n,r){return function(e,n,r,i){var o,a,s,c,u,l,f=0,p=n||[0],d=(r=r||0)>>>3,h=-1===i?3:0,y=e.indexOf("=");if(-1===e.search(/^[a-zA-Z0-9=+/]+$/))throw new Error("Invalid character in base-64 string");if(e=e.replace(/=/g,""),-1!==y&&y<e.length)throw new Error("Invalid '=' found in base-64 string");for(o=0;o<e.length;o+=4){for(c=e.substr(o,4),s=0,a=0;a<c.length;a+=1)s|=t.indexOf(c.charAt(a))<<18-6*a;for(a=0;a<c.length-1;a+=1){for(u=(l=f+d)>>>2;p.length<=u;)p.push(0);p[u]|=(s>>>16-8*a&255)<<8*(h+i*(l%4)),f+=1}}return{value:p,binLen:8*f+r}}(e,n,r,i)};case"BYTES":return function(e,t,n){return function(e,t,n,r){var i,o,a,s,c=t||[0],u=(n=n||0)>>>3,l=-1===r?3:0;for(o=0;o<e.length;o+=1)i=e.charCodeAt(o),a=(s=o+u)>>>2,c.length<=a&&c.push(0),c[a]|=i<<8*(l+r*(s%4));return{value:c,binLen:8*e.length+n}}(e,t,n,i)};case"ARRAYBUFFER":try{new ArrayBuffer(0)}catch(e){throw new Error("ARRAYBUFFER not supported by this environment")}return function(e,t,r){return function(e,t,r,i){return n(new Uint8Array(e),t,r,i)}(e,t,r,i)};case"UINT8ARRAY":try{new Uint8Array(0)}catch(e){throw new Error("UINT8ARRAY not supported by this environment")}return function(e,t,r){return n(e,t,r,i)};default:throw new Error("format must be HEX, TEXT, B64, BYTES, ARRAYBUFFER, or UINT8ARRAY")}}function i(e,n,r,i){switch(e){case"HEX":return function(e){return function(e,t,n,r){var i,o,a="",s=t/8,c=-1===n?3:0;for(i=0;i<s;i+=1)o=e[i>>>2]>>>8*(c+n*(i%4)),a+="0123456789abcdef".charAt(o>>>4&15)+"0123456789abcdef".charAt(15&o);return r.outputUpper?a.toUpperCase():a}(e,n,r,i)};case"B64":return function(e){return function(e,n,r,i){var o,a,s,c,u,l="",f=n/8,p=-1===r?3:0;for(o=0;o<f;o+=3)for(c=o+1<f?e[o+1>>>2]:0,u=o+2<f?e[o+2>>>2]:0,s=(e[o>>>2]>>>8*(p+r*(o%4))&255)<<16|(c>>>8*(p+r*((o+1)%4))&255)<<8|u>>>8*(p+r*((o+2)%4))&255,a=0;a<4;a+=1)l+=8*o+6*a<=n?t.charAt(s>>>6*(3-a)&63):i.b64Pad;return l}(e,n,r,i)};case"BYTES":return function(e){return function(e,t,n){var r,i,o="",a=t/8,s=-1===n?3:0;for(r=0;r<a;r+=1)i=e[r>>>2]>>>8*(s+n*(r%4))&255,o+=String.fromCharCode(i);return o}(e,n,r)};case"ARRAYBUFFER":try{new ArrayBuffer(0)}catch(e){throw new Error("ARRAYBUFFER not supported by this environment")}return function(e){return function(e,t,n){var r,i=t/8,o=new ArrayBuffer(i),a=new Uint8Array(o),s=-1===n?3:0;for(r=0;r<i;r+=1)a[r]=e[r>>>2]>>>8*(s+n*(r%4))&255;return o}(e,n,r)};case"UINT8ARRAY":try{new Uint8Array(0)}catch(e){throw new Error("UINT8ARRAY not supported by this environment")}return function(e){return function(e,t,n){var r,i=t/8,o=-1===n?3:0,a=new Uint8Array(i);for(r=0;r<i;r+=1)a[r]=e[r>>>2]>>>8*(o+n*(r%4))&255;return a}(e,n,r)};default:throw new Error("format must be HEX, B64, BYTES, ARRAYBUFFER, or UINT8ARRAY")}}function o(e){var t={outputUpper:!1,b64Pad:"=",outputLen:-1},n=e||{},r="Output length must be a multiple of 8";if(t.outputUpper=n.outputUpper||!1,n.b64Pad&&(t.b64Pad=n.b64Pad),n.outputLen){if(n.outputLen%8!=0)throw new Error(r);t.outputLen=n.outputLen}else if(n.shakeLen){if(n.shakeLen%8!=0)throw new Error(r);t.outputLen=n.shakeLen}if("boolean"!=typeof t.outputUpper)throw new Error("Invalid outputUpper formatting option");if("string"!=typeof t.b64Pad)throw new Error("Invalid b64Pad formatting option");return t}function a(e,t){return e<<t|e>>>32-t}function s(e,t,n){return e^t^n}function c(e,t,n){return e&t^e&n^t&n}function u(e,t){var n=(65535&e)+(65535&t);return(65535&(e>>>16)+(t>>>16)+(n>>>16))<<16|65535&n}function l(e,t,n,r,i){var o=(65535&e)+(65535&t)+(65535&n)+(65535&r)+(65535&i);return(65535&(e>>>16)+(t>>>16)+(n>>>16)+(r>>>16)+(i>>>16)+(o>>>16))<<16|65535&o}function f(e){return[1732584193,4023233417,2562383102,271733878,3285377520]}function p(e,t){var n,r,i,o,f,p,d,h,y=[];for(n=t[0],r=t[1],i=t[2],o=t[3],f=t[4],d=0;d<80;d+=1)y[d]=d<16?e[d]:a(y[d-3]^y[d-8]^y[d-14]^y[d-16],1),p=d<20?l(a(n,5),(h=r)&i^~h&o,f,1518500249,y[d]):d<40?l(a(n,5),s(r,i,o),f,1859775393,y[d]):d<60?l(a(n,5),c(r,i,o),f,2400959708,y[d]):l(a(n,5),s(r,i,o),f,3395469782,y[d]),f=o,o=i,i=a(r,30),r=n,n=p;return t[0]=u(n,t[0]),t[1]=u(r,t[1]),t[2]=u(i,t[2]),t[3]=u(o,t[3]),t[4]=u(f,t[4]),t}function d(e,t,n,r){for(var i,o=15+(t+65>>>9<<4),a=t+n;e.length<=o;)e.push(0);for(e[t>>>5]|=128<<24-t%32,e[o]=4294967295&a,e[o-1]=a/4294967296|0,i=0;i<e.length;i+=16)r=p(e.slice(i,i+16),r);return r}return function(t){function n(e,n,i){var o=this;if("SHA-1"!==e)throw new Error("Chosen SHA variant is not supported");var a=i||{};return(o=t.call(this,e,n,i)||this).t=!0,o.i=o.o,o.u=-1,o.s=r(o.h,o.v,o.u),o.A=p,o.p=function(e){return e.slice()},o.l=f,o.R=d,o.U=[1732584193,4023233417,2562383102,271733878,3285377520],o.T=512,o.m=160,o.F=!1,a.hmacKey&&o.B(function(e,t,n,i){var o="hmacKey must include a value and format";if(!t)throw new Error(o);if(void 0===t.value||!t.format)throw new Error(o);return r(t.format,t.encoding||"UTF8",n)(t.value)}(0,a.hmacKey,o.u)),o}return function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}(n,t),n}(function(){function e(e,t,n){var r=n||{};if(this.h=t,this.v=r.encoding||"UTF8",this.numRounds=r.numRounds||1,isNaN(this.numRounds)||this.numRounds!==parseInt(this.numRounds,10)||1>this.numRounds)throw new Error("numRounds must a integer >= 1");this.g=e,this.Y=[],this.I=0,this.C=!1,this.H=0,this.L=!1,this.N=[],this.S=[]}return e.prototype.update=function(e){var t,n=0,r=this.T>>>5,i=this.s(e,this.Y,this.I),o=i.binLen,a=i.value,s=o>>>5;for(t=0;t<s;t+=r)n+this.T<=o&&(this.U=this.A(a.slice(t,t+r),this.U),n+=this.T);this.H+=n,this.Y=a.slice(n>>>5),this.I=o%this.T,this.C=!0},e.prototype.getHash=function(e,t){var n,r,a=this.m,s=o(t);if(!0===this.F){if(-1===s.outputLen)throw new Error("Output length must be specified in options");a=s.outputLen}var c=i(e,a,this.u,s);if(!0===this.L&&this.i)return c(this.i(s));for(r=this.R(this.Y.slice(),this.I,this.H,this.p(this.U),a),n=1;n<this.numRounds;n+=1)!0===this.F&&a%32!=0&&(r[r.length-1]&=16777215>>>24-a%32),r=this.R(r,a,0,this.l(this.g),a);return c(r)},e.prototype.setHMACKey=function(e,t,n){if(!0!==this.t)throw new Error("Variant does not support HMAC");if(!0===this.C)throw new Error("Cannot set MAC key after calling update");var i=r(t,(n||{}).encoding||"UTF8",this.u);this.B(i(e))},e.prototype.B=function(e){var t,n=this.T>>>3,r=n/4-1;if(1!==this.numRounds)throw new Error("Cannot set numRounds with MAC");if(!0===this.L)throw new Error("MAC key already set");for(n<e.binLen/8&&(e.value=this.R(e.value,e.binLen,0,this.l(this.g),this.m));e.value.length<=r;)e.value.push(0);for(t=0;t<=r;t+=1)this.N[t]=909522486^e.value[t],this.S[t]=1549556828^e.value[t];this.U=this.A(this.N,this.U),this.H=this.T,this.L=!0},e.prototype.getHMAC=function(e,t){var n=o(t);return i(e,this.m,this.u,n)(this.o())},e.prototype.o=function(){var e;if(!1===this.L)throw new Error("Cannot call getHMAC without first setting MAC key");var t=this.R(this.Y.slice(),this.I,this.H,this.p(this.U),this.m);return e=this.A(this.S,this.l(this.g)),this.R(t,this.m,this.T,e,this.m)},e}())}()},function(e){e.exports=JSON.parse('{"a":"1.0.36-dev.0"}')},function(e,t){e.exports=m},function(e,t,n){e.exports={embeddedPlayer:"dgjVs"}},function(e,t,n){e.exports={image:"_3T3Ux"}},function(e,t,n){var r=n(121);e.exports=(r.default||r).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){return'<div class="layout-region position-relative"></div>\r\n<div id="dialog-region"></div>\r\n<div id="print-region"></div>'},useData:!0})},function(e,t,n){"use strict";n.r(t),n.d(t,"EmbedErrorView",(function(){return c}));var r=n(0),i=n.n(r),o=n(217),a=n(189),s=n.n(a);function c(e){var t=e.error;return i.a.createElement("div",{className:"text-white ".concat(s.a.embedError)},i.a.createElement("div",{className:s.a.logo},i.a.createElement(o.b,null)),i.a.createElement("div",{className:"".concat(s.a.content," d-flex flex-column align-items-center")},i.a.createElement("div",{className:"".concat(s.a.imgContainer," mb-3")},i.a.createElement("img",{src:t.imageUrl,className:s.a.img,role:"presentation",alt:""})),i.a.createElement("h1",{className:"".concat(s.a.heading," font-weight-500 mb-0")},t.heading),!!t.description&&i.a.createElement("p",{className:"mb-0"},t.description)))}},function(e,t,n){var r=n(121);e.exports=(r.default||r).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){return'<div class="layout-region"></div>'},useData:!0})},function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return o}));var r=n(161),i=n(22),o=function(){function t(){}return t.prototype.writeHandshakeRequest=function(e){return r.a.write(JSON.stringify(e))},t.prototype.parseHandshakeResponse=function(t){var n,o;if(Object(i.h)(t)||void 0!==e&&t instanceof e){var a=new Uint8Array(t);if(-1===(c=a.indexOf(r.a.RecordSeparatorCode)))throw new Error("Message is incomplete.");var s=c+1;n=String.fromCharCode.apply(null,a.slice(0,s)),o=a.byteLength>s?a.slice(s).buffer:null}else{var c,u=t;if(-1===(c=u.indexOf(r.a.RecordSeparator)))throw new Error("Message is incomplete.");s=c+1;n=u.substring(0,s),o=u.length>s?u.substring(s):null}var l=r.a.parse(n),f=JSON.parse(l[0]);if(f.type)throw new Error("Expected a handshake response from the server.");return[o,f]},t}()}).call(this,n(391).Buffer)},function(e,t,n){e.exports={notificationsView:"_3UtcL"}},function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t,n){"use strict";var r=n(1);n(838);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})(e)}function o(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function a(e,t){return(a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function s(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=u(e);if(t){var i=u(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return c(this,n)}}function c(e,t){return!t||"object"!==i(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function u(e){return(u=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var l=function(e){!function(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}}),t&&a(e,t)}(c,e);var t,n,r,i=s(c);function c(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,c),(n=i.call(this,e,t)).update(),n}return t=c,(n=[{key:"update",value:function(){this.options_.isFavourited?this.addClass("cv-favourited"):this.removeClass("cv-favourited")}},{key:"handleClick",value:function(){if(this.options_.isFavourited=!this.options_.isFavourited,this.update(),this.options_.clickHandler){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.options_.clickHandler.call(this,t)}}},{key:"buildCSSClass",value:function(){return"cv-favourite-button"}}])&&o(t.prototype,n),r&&o(t,r),c}(r.a.getComponent("Button"));function f(e){return(f="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)}function p(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function d(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function h(e,t){return(h=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=v(e);if(t){var i=v(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return m(this,n)}}function m(e,t){return!t||"object"!==f(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function v(e){return(v=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}l.prototype.controlText_="Favourite";var g=function(e){!function(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}}),t&&h(e,t)}(o,e);var t,n,r,i=y(o);function o(){return p(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"setFavourite",value:function(e,t){var n=this;e!==this.isFavourite&&(this.isFavourite=e,this.onClickFavourite=t,this.player.ready((function(){n.renderFavouriteButton()})))}},{key:"renderFavouriteButton",value:function(){this.player.isDisposed()||(this.button&&this.player.removeChild(this.button),this.button=new l(this.player,{isFavourited:this.isFavourite,clickHandler:this.onClickFavourite}),this.player.addChild(this.button))}}])&&d(t.prototype,n),r&&d(t,r),o}(r.a.getPlugin("plugin"));r.a.registerPlugin("favouritePlugin",g)},function(e,t,n){"use strict";var r=n(1),i=n(126);n(840);function o(e){return(o="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)}function a(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function s(e,t){return(s=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=l(e);if(t){var i=l(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u(this,n)}}function u(e,t){return!t||"object"!==o(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function l(e){return(l=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var f=function(e){!function(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}}),t&&s(e,t)}(u,e);var t,n,r,o=c(u);function u(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,u),(n=o.call(this,e,t)).update(),n}return t=u,(n=[{key:"update",value:function(){this.options_.activityStatus===i.a.Complete?this.addClass("cv-activity-completed"):this.removeClass("cv-activity-completed")}},{key:"handleClick",value:function(){if(this.options_.activityStatus=this.options_.activityStatus===i.a.Complete?i.a.Incomplete:i.a.Complete,this.update(),this.options_.clickHandler){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.options_.clickHandler.call(this,t)}}},{key:"buildCSSClass",value:function(){return"cv-activity-status-button"}}])&&a(t.prototype,n),r&&a(t,r),u}(r.a.getComponent("Button"));function p(e){return(p="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)}function d(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function h(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function y(e,t){return(y=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=g(e);if(t){var i=g(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return v(this,n)}}function v(e,t){return!t||"object"!==p(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function g(e){return(g=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}f.prototype.controlText_="ActivityStatus";var b=function(e){!function(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}}),t&&y(e,t)}(o,e);var t,n,r,i=m(o);function o(){return d(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"setActivityStatus",value:function(e,t){var n=this;e!==this.activityStatus&&(this.activityStatus=e,this.onToggleStatus=t,this.player.ready((function(){n.renderActivityStatusButton()})))}},{key:"renderActivityStatusButton",value:function(){this.player.isDisposed()||(this.button&&this.player.removeChild(this.button),this.button=new f(this.player,{activityStatus:this.activityStatus,clickHandler:this.onToggleStatus}),this.player.addChild(this.button))}}])&&h(t.prototype,n),r&&h(t,r),o}(r.a.getPlugin("plugin"));r.a.registerPlugin("activityStatusPlugin",b)},function(e,t){function n(t){return"function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?(e.exports=n=function(e){return typeof e},e.exports.default=e.exports,e.exports.__esModule=!0):(e.exports=n=function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.default=e.exports,e.exports.__esModule=!0),n(t)}e.exports=n,e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){var n,r,i=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function s(e){if(n===setTimeout)return setTimeout(e,0);if((n===o||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:o}catch(e){n=o}try{r="function"==typeof clearTimeout?clearTimeout:a}catch(e){r=a}}();var c,u=[],l=!1,f=-1;function p(){l&&c&&(l=!1,c.length?u=c.concat(u):f=-1,u.length&&d())}function d(){if(!l){var e=s(p);l=!0;for(var t=u.length;t;){for(c=u,u=[];++f<t;)c&&c[f].run();f=-1,t=u.length}c=null,l=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function h(e,t){this.fun=e,this.array=t}function y(){}i.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];u.push(new h(e,t)),1!==u.length||l||s(d)},h.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=y,i.addListener=y,i.once=y,i.off=y,i.removeListener=y,i.removeAllListeners=y,i.emit=y,i.prependListener=y,i.prependOnceListener=y,i.listeners=function(e){return[]},i.binding=function(e){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(e){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},,function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){"use strict";t.__esModule=!0;var r=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(n(772));var i=r.tokenize,o=r.options.Options;function a(e){return e.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">")}function s(e){return e.replace(/"/g,""")}function c(e){if(!e)return"";var t=[];for(var n in e){var r=e[n]+"";t.push(n+'="'+s(r)+'"')}return t.join(" ")}function u(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};t=new o(t);for(var n=i(e),r=[],u=0;u<n.length;u++){var l=n[u];if("nl"===l.type&&t.nl2br)r.push("<br>\n");else if(l.isLink&&t.check(l)){var f=t.resolve(l),p=f.formatted,d=f.formattedHref,h=f.tagName,y=f.className,m=f.target,v=f.attributes,g="<"+h+' href="'+s(d)+'"';y&&(g+=' class="'+s(y)+'"'),m&&(g+=' target="'+s(m)+'"'),v&&(g+=" "+c(v)),g+=">"+a(p)+"</"+h+">",r.push(g)}else r.push(a(l.toString()))}return r.join("")}if(!String.prototype.linkify)try{Object.defineProperty(String.prototype,"linkify",{set:function(){},get:function(){return function(e){return u(this,e)}}})}catch(e){String.prototype.linkify||(String.prototype.linkify=function(e){return u(this,e)})}t.default=u},function(e,t,n){"use strict";t.__esModule=!0,t.tokenize=t.test=t.scanner=t.parser=t.options=t.inherits=t.find=void 0;var r=n(265),i=s(n(773)),o=s(n(774)),a=s(n(775));function s(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)});var c=function(e){return a.run(o.run(e))};t.find=function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=c(e),r=[],i=0;i<n.length;i++){var o=n[i];!o.isLink||t&&o.type!==t||r.push(o.toObject())}return r},t.inherits=r.inherits,t.options=i,t.parser=a,t.scanner=o,t.test=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=c(e);return 1===n.length&&n[0].isLink&&(!t||n[0].type===t)},t.tokenize=c},function(e,t,n){"use strict";t.__esModule=!0;var r="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={defaultProtocol:"http",events:null,format:a,formatHref:a,nl2br:!1,tagName:"a",target:function(e,t){return"url"===t?"_blank":null},validate:!0,ignoreTags:[],attributes:null,className:"linkified"};function o(e){e=e||{},this.defaultProtocol=e.hasOwnProperty("defaultProtocol")?e.defaultProtocol:i.defaultProtocol,this.events=e.hasOwnProperty("events")?e.events:i.events,this.format=e.hasOwnProperty("format")?e.format:i.format,this.formatHref=e.hasOwnProperty("formatHref")?e.formatHref:i.formatHref,this.nl2br=e.hasOwnProperty("nl2br")?e.nl2br:i.nl2br,this.tagName=e.hasOwnProperty("tagName")?e.tagName:i.tagName,this.target=e.hasOwnProperty("target")?e.target:i.target,this.validate=e.hasOwnProperty("validate")?e.validate:i.validate,this.ignoreTags=[],this.attributes=e.attributes||e.linkAttributes||i.attributes,this.className=e.hasOwnProperty("className")?e.className:e.linkClass||i.className;for(var t=e.hasOwnProperty("ignoreTags")?e.ignoreTags:i.ignoreTags,n=0;n<t.length;n++)this.ignoreTags.push(t[n].toUpperCase())}function a(e){return e}t.defaults=i,t.Options=o,t.contains=function(e,t){for(var n=0;n<e.length;n++)if(e[n]===t)return!0;return!1},o.prototype={resolve:function(e){var t=e.toHref(this.defaultProtocol);return{formatted:this.get("format",e.toString(),e),formattedHref:this.get("formatHref",t,e),tagName:this.get("tagName",t,e),className:this.get("className",t,e),target:this.get("target",t,e),events:this.getObject("events",t,e),attributes:this.getObject("attributes",t,e)}},check:function(e){return this.get("validate",e.toString(),e)},get:function(e,t,n){var o=void 0,a=this[e];if(!a)return a;switch(void 0===a?"undefined":r(a)){case"function":return a(t,n.type);case"object":return"function"==typeof(o=a.hasOwnProperty(n.type)?a[n.type]:i[e])?o(t,n.type):o}return a},getObject:function(e,t,n){var r=this[e];return"function"==typeof r?r(t,n.type):r}}},function(e,t,n){"use strict";t.__esModule=!0,t.start=t.run=t.TOKENS=t.State=void 0;var r=n(428),i=n(326),o=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(i);var a="aaa|aarp|abarth|abb|abbott|abbvie|abc|able|abogado|abudhabi|ac|academy|accenture|accountant|accountants|aco|active|actor|ad|adac|ads|adult|ae|aeg|aero|aetna|af|afamilycompany|afl|africa|ag|agakhan|agency|ai|aig|aigo|airbus|airforce|airtel|akdn|al|alfaromeo|alibaba|alipay|allfinanz|allstate|ally|alsace|alstom|am|americanexpress|americanfamily|amex|amfam|amica|amsterdam|analytics|android|anquan|anz|ao|aol|apartments|app|apple|aq|aquarelle|ar|arab|aramco|archi|army|arpa|art|arte|as|asda|asia|associates|at|athleta|attorney|au|auction|audi|audible|audio|auspost|author|auto|autos|avianca|aw|aws|ax|axa|az|azure|ba|baby|baidu|banamex|bananarepublic|band|bank|bar|barcelona|barclaycard|barclays|barefoot|bargains|baseball|basketball|bauhaus|bayern|bb|bbc|bbt|bbva|bcg|bcn|bd|be|beats|beauty|beer|bentley|berlin|best|bestbuy|bet|bf|bg|bh|bharti|bi|bible|bid|bike|bing|bingo|bio|biz|bj|black|blackfriday|blanco|blockbuster|blog|bloomberg|blue|bm|bms|bmw|bn|bnl|bnpparibas|bo|boats|boehringer|bofa|bom|bond|boo|book|booking|boots|bosch|bostik|boston|bot|boutique|box|br|bradesco|bridgestone|broadway|broker|brother|brussels|bs|bt|budapest|bugatti|build|builders|business|buy|buzz|bv|bw|by|bz|bzh|ca|cab|cafe|cal|call|calvinklein|cam|camera|camp|cancerresearch|canon|capetown|capital|capitalone|car|caravan|cards|care|career|careers|cars|cartier|casa|case|caseih|cash|casino|cat|catering|catholic|cba|cbn|cbre|cbs|cc|cd|ceb|center|ceo|cern|cf|cfa|cfd|cg|ch|chanel|channel|chase|chat|cheap|chintai|chloe|christmas|chrome|chrysler|church|ci|cipriani|circle|cisco|citadel|citi|citic|city|cityeats|ck|cl|claims|cleaning|click|clinic|clinique|clothing|cloud|club|clubmed|cm|cn|co|coach|codes|coffee|college|cologne|com|comcast|commbank|community|company|compare|computer|comsec|condos|construction|consulting|contact|contractors|cooking|cookingchannel|cool|coop|corsica|country|coupon|coupons|courses|cr|credit|creditcard|creditunion|cricket|crown|crs|cruise|cruises|csc|cu|cuisinella|cv|cw|cx|cy|cymru|cyou|cz|dabur|dad|dance|data|date|dating|datsun|day|dclk|dds|de|deal|dealer|deals|degree|delivery|dell|deloitte|delta|democrat|dental|dentist|desi|design|dev|dhl|diamonds|diet|digital|direct|directory|discount|discover|dish|diy|dj|dk|dm|dnp|do|docs|doctor|dodge|dog|doha|domains|dot|download|drive|dtv|dubai|duck|dunlop|duns|dupont|durban|dvag|dvr|dz|earth|eat|ec|eco|edeka|edu|education|ee|eg|email|emerck|energy|engineer|engineering|enterprises|epost|epson|equipment|er|ericsson|erni|es|esq|estate|esurance|et|etisalat|eu|eurovision|eus|events|everbank|exchange|expert|exposed|express|extraspace|fage|fail|fairwinds|faith|family|fan|fans|farm|farmers|fashion|fast|fedex|feedback|ferrari|ferrero|fi|fiat|fidelity|fido|film|final|finance|financial|fire|firestone|firmdale|fish|fishing|fit|fitness|fj|fk|flickr|flights|flir|florist|flowers|fly|fm|fo|foo|food|foodnetwork|football|ford|forex|forsale|forum|foundation|fox|fr|free|fresenius|frl|frogans|frontdoor|frontier|ftr|fujitsu|fujixerox|fun|fund|furniture|futbol|fyi|ga|gal|gallery|gallo|gallup|game|games|gap|garden|gb|gbiz|gd|gdn|ge|gea|gent|genting|george|gf|gg|ggee|gh|gi|gift|gifts|gives|giving|gl|glade|glass|gle|global|globo|gm|gmail|gmbh|gmo|gmx|gn|godaddy|gold|goldpoint|golf|goo|goodhands|goodyear|goog|google|gop|got|gov|gp|gq|gr|grainger|graphics|gratis|green|gripe|grocery|group|gs|gt|gu|guardian|gucci|guge|guide|guitars|guru|gw|gy|hair|hamburg|hangout|haus|hbo|hdfc|hdfcbank|health|healthcare|help|helsinki|here|hermes|hgtv|hiphop|hisamitsu|hitachi|hiv|hk|hkt|hm|hn|hockey|holdings|holiday|homedepot|homegoods|homes|homesense|honda|honeywell|horse|hospital|host|hosting|hot|hoteles|hotels|hotmail|house|how|hr|hsbc|ht|htc|hu|hughes|hyatt|hyundai|ibm|icbc|ice|icu|id|ie|ieee|ifm|ikano|il|im|imamat|imdb|immo|immobilien|in|industries|infiniti|info|ing|ink|institute|insurance|insure|int|intel|international|intuit|investments|io|ipiranga|iq|ir|irish|is|iselect|ismaili|ist|istanbul|it|itau|itv|iveco|iwc|jaguar|java|jcb|jcp|je|jeep|jetzt|jewelry|jio|jlc|jll|jm|jmp|jnj|jo|jobs|joburg|jot|joy|jp|jpmorgan|jprs|juegos|juniper|kaufen|kddi|ke|kerryhotels|kerrylogistics|kerryproperties|kfh|kg|kh|ki|kia|kim|kinder|kindle|kitchen|kiwi|km|kn|koeln|komatsu|kosher|kp|kpmg|kpn|kr|krd|kred|kuokgroup|kw|ky|kyoto|kz|la|lacaixa|ladbrokes|lamborghini|lamer|lancaster|lancia|lancome|land|landrover|lanxess|lasalle|lat|latino|latrobe|law|lawyer|lb|lc|lds|lease|leclerc|lefrak|legal|lego|lexus|lgbt|li|liaison|lidl|life|lifeinsurance|lifestyle|lighting|like|lilly|limited|limo|lincoln|linde|link|lipsy|live|living|lixil|lk|loan|loans|locker|locus|loft|lol|london|lotte|lotto|love|lpl|lplfinancial|lr|ls|lt|ltd|ltda|lu|lundbeck|lupin|luxe|luxury|lv|ly|ma|macys|madrid|maif|maison|makeup|man|management|mango|map|market|marketing|markets|marriott|marshalls|maserati|mattel|mba|mc|mckinsey|md|me|med|media|meet|melbourne|meme|memorial|men|menu|meo|merckmsd|metlife|mg|mh|miami|microsoft|mil|mini|mint|mit|mitsubishi|mk|ml|mlb|mls|mm|mma|mn|mo|mobi|mobile|mobily|moda|moe|moi|mom|monash|money|monster|mopar|mormon|mortgage|moscow|moto|motorcycles|mov|movie|movistar|mp|mq|mr|ms|msd|mt|mtn|mtr|mu|museum|mutual|mv|mw|mx|my|mz|na|nab|nadex|nagoya|name|nationwide|natura|navy|nba|nc|ne|nec|net|netbank|netflix|network|neustar|new|newholland|news|next|nextdirect|nexus|nf|nfl|ng|ngo|nhk|ni|nico|nike|nikon|ninja|nissan|nissay|nl|no|nokia|northwesternmutual|norton|now|nowruz|nowtv|np|nr|nra|nrw|ntt|nu|nyc|nz|obi|observer|off|office|okinawa|olayan|olayangroup|oldnavy|ollo|om|omega|one|ong|onl|online|onyourside|ooo|open|oracle|orange|org|organic|origins|osaka|otsuka|ott|ovh|pa|page|panasonic|panerai|paris|pars|partners|parts|party|passagens|pay|pccw|pe|pet|pf|pfizer|pg|ph|pharmacy|phd|philips|phone|photo|photography|photos|physio|piaget|pics|pictet|pictures|pid|pin|ping|pink|pioneer|pizza|pk|pl|place|play|playstation|plumbing|plus|pm|pn|pnc|pohl|poker|politie|porn|post|pr|pramerica|praxi|press|prime|pro|prod|productions|prof|progressive|promo|properties|property|protection|pru|prudential|ps|pt|pub|pw|pwc|py|qa|qpon|quebec|quest|qvc|racing|radio|raid|re|read|realestate|realtor|realty|recipes|red|redstone|redumbrella|rehab|reise|reisen|reit|reliance|ren|rent|rentals|repair|report|republican|rest|restaurant|review|reviews|rexroth|rich|richardli|ricoh|rightathome|ril|rio|rip|rmit|ro|rocher|rocks|rodeo|rogers|room|rs|rsvp|ru|rugby|ruhr|run|rw|rwe|ryukyu|sa|saarland|safe|safety|sakura|sale|salon|samsclub|samsung|sandvik|sandvikcoromant|sanofi|sap|sapo|sarl|sas|save|saxo|sb|sbi|sbs|sc|sca|scb|schaeffler|schmidt|scholarships|school|schule|schwarz|science|scjohnson|scor|scot|sd|se|search|seat|secure|security|seek|select|sener|services|ses|seven|sew|sex|sexy|sfr|sg|sh|shangrila|sharp|shaw|shell|shia|shiksha|shoes|shop|shopping|shouji|show|showtime|shriram|si|silk|sina|singles|site|sj|sk|ski|skin|sky|skype|sl|sling|sm|smart|smile|sn|sncf|so|soccer|social|softbank|software|sohu|solar|solutions|song|sony|soy|space|spiegel|spot|spreadbetting|sr|srl|srt|st|stada|staples|star|starhub|statebank|statefarm|statoil|stc|stcgroup|stockholm|storage|store|stream|studio|study|style|su|sucks|supplies|supply|support|surf|surgery|suzuki|sv|swatch|swiftcover|swiss|sx|sy|sydney|symantec|systems|sz|tab|taipei|talk|taobao|target|tatamotors|tatar|tattoo|tax|taxi|tc|tci|td|tdk|team|tech|technology|tel|telecity|telefonica|temasek|tennis|teva|tf|tg|th|thd|theater|theatre|tiaa|tickets|tienda|tiffany|tips|tires|tirol|tj|tjmaxx|tjx|tk|tkmaxx|tl|tm|tmall|tn|to|today|tokyo|tools|top|toray|toshiba|total|tours|town|toyota|toys|tr|trade|trading|training|travel|travelchannel|travelers|travelersinsurance|trust|trv|tt|tube|tui|tunes|tushu|tv|tvs|tw|tz|ua|ubank|ubs|uconnect|ug|uk|unicom|university|uno|uol|ups|us|uy|uz|va|vacations|vana|vanguard|vc|ve|vegas|ventures|verisign|versicherung|vet|vg|vi|viajes|video|vig|viking|villas|vin|vip|virgin|visa|vision|vista|vistaprint|viva|vivo|vlaanderen|vn|vodka|volkswagen|volvo|vote|voting|voto|voyage|vu|vuelos|wales|walmart|walter|wang|wanggou|warman|watch|watches|weather|weatherchannel|webcam|weber|website|wed|wedding|weibo|weir|wf|whoswho|wien|wiki|williamhill|win|windows|wine|winners|wme|wolterskluwer|woodside|work|works|world|wow|ws|wtc|wtf|xbox|xerox|xfinity|xihuan|xin|xn--11b4c3d|xn--1ck2e1b|xn--1qqw23a|xn--2scrj9c|xn--30rr7y|xn--3bst00m|xn--3ds443g|xn--3e0b707e|xn--3hcrj9c|xn--3oq18vl8pn36a|xn--3pxu8k|xn--42c2d9a|xn--45br5cyl|xn--45brj9c|xn--45q11c|xn--4gbrim|xn--54b7fta0cc|xn--55qw42g|xn--55qx5d|xn--5su34j936bgsg|xn--5tzm5g|xn--6frz82g|xn--6qq986b3xl|xn--80adxhks|xn--80ao21a|xn--80aqecdr1a|xn--80asehdb|xn--80aswg|xn--8y0a063a|xn--90a3ac|xn--90ae|xn--90ais|xn--9dbq2a|xn--9et52u|xn--9krt00a|xn--b4w605ferd|xn--bck1b9a5dre4c|xn--c1avg|xn--c2br7g|xn--cck2b3b|xn--cg4bki|xn--clchc0ea0b2g2a9gcd|xn--czr694b|xn--czrs0t|xn--czru2d|xn--d1acj3b|xn--d1alf|xn--e1a4c|xn--eckvdtc9d|xn--efvy88h|xn--estv75g|xn--fct429k|xn--fhbei|xn--fiq228c5hs|xn--fiq64b|xn--fiqs8s|xn--fiqz9s|xn--fjq720a|xn--flw351e|xn--fpcrj9c3d|xn--fzc2c9e2c|xn--fzys8d69uvgm|xn--g2xx48c|xn--gckr3f0f|xn--gecrj9c|xn--gk3at1e|xn--h2breg3eve|xn--h2brj9c|xn--h2brj9c8c|xn--hxt814e|xn--i1b6b1a6a2e|xn--imr513n|xn--io0a7i|xn--j1aef|xn--j1amh|xn--j6w193g|xn--jlq61u9w7b|xn--jvr189m|xn--kcrx77d1x4a|xn--kprw13d|xn--kpry57d|xn--kpu716f|xn--kput3i|xn--l1acc|xn--lgbbat1ad8j|xn--mgb9awbf|xn--mgba3a3ejt|xn--mgba3a4f16a|xn--mgba7c0bbn0a|xn--mgbaakc7dvf|xn--mgbaam7a8h|xn--mgbab2bd|xn--mgbai9azgqp6j|xn--mgbayh7gpa|xn--mgbb9fbpob|xn--mgbbh1a|xn--mgbbh1a71e|xn--mgbc0a9azcg|xn--mgbca7dzdo|xn--mgberp4a5d4ar|xn--mgbgu82a|xn--mgbi4ecexp|xn--mgbpl2fh|xn--mgbt3dhd|xn--mgbtx2b|xn--mgbx4cd0ab|xn--mix891f|xn--mk1bu44c|xn--mxtq1m|xn--ngbc5azd|xn--ngbe9e0a|xn--ngbrx|xn--node|xn--nqv7f|xn--nqv7fs00ema|xn--nyqy26a|xn--o3cw4h|xn--ogbpf8fl|xn--p1acf|xn--p1ai|xn--pbt977c|xn--pgbs0dh|xn--pssy2u|xn--q9jyb4c|xn--qcka1pmc|xn--qxam|xn--rhqv96g|xn--rovu88b|xn--rvc1e0am3e|xn--s9brj9c|xn--ses554g|xn--t60b56a|xn--tckwe|xn--tiq49xqyj|xn--unup4y|xn--vermgensberater-ctb|xn--vermgensberatung-pwb|xn--vhquv|xn--vuq861b|xn--w4r85el8fhu5dnra|xn--w4rs40l|xn--wgbh1c|xn--wgbl6a|xn--xhq521b|xn--xkc2al3hye2a|xn--xkc2dl3a5ee0h|xn--y9a3aq|xn--yfro4i67o|xn--ygbi2ammx|xn--zfr164b|xperia|xxx|xyz|yachts|yahoo|yamaxun|yandex|ye|yodobashi|yoga|yokohama|you|youtube|yt|yun|za|zappos|zara|zero|zip|zippo|zm|zone|zuerich|zw".split("|"),s="0123456789".split(""),c="0123456789abcdefghijklmnopqrstuvwxyz".split(""),u=[" ","\f","\r","\t","\v"," "," ",""],l=[],f=function(e){return new r.CharacterState(e)},p=f(),d=f(i.NUM),h=f(i.DOMAIN),y=f(),m=f(i.WS);p.on("@",f(i.AT)).on(".",f(i.DOT)).on("+",f(i.PLUS)).on("#",f(i.POUND)).on("?",f(i.QUERY)).on("/",f(i.SLASH)).on("_",f(i.UNDERSCORE)).on(":",f(i.COLON)).on("{",f(i.OPENBRACE)).on("[",f(i.OPENBRACKET)).on("<",f(i.OPENANGLEBRACKET)).on("(",f(i.OPENPAREN)).on("}",f(i.CLOSEBRACE)).on("]",f(i.CLOSEBRACKET)).on(">",f(i.CLOSEANGLEBRACKET)).on(")",f(i.CLOSEPAREN)).on("&",f(i.AMPERSAND)).on([",",";","!",'"',"'"],f(i.PUNCTUATION)),p.on("\n",f(i.NL)).on(u,m),m.on(u,m);for(var v=0;v<a.length;v++){var g=(0,r.stateify)(a[v],p,i.TLD,i.DOMAIN);l.push.apply(l,g)}var b=(0,r.stateify)("file",p,i.DOMAIN,i.DOMAIN),w=(0,r.stateify)("ftp",p,i.DOMAIN,i.DOMAIN),_=(0,r.stateify)("http",p,i.DOMAIN,i.DOMAIN),S=(0,r.stateify)("mailto",p,i.DOMAIN,i.DOMAIN);l.push.apply(l,b),l.push.apply(l,w),l.push.apply(l,_),l.push.apply(l,S);var T=b.pop(),C=w.pop(),E=_.pop(),k=S.pop(),O=f(i.DOMAIN),P=f(i.PROTOCOL),A=f(i.MAILTO);C.on("s",O).on(":",P),E.on("s",O).on(":",P),l.push(O),T.on(":",P),O.on(":",P),k.on(":",A);var I=(0,r.stateify)("localhost",p,i.LOCALHOST,i.DOMAIN);l.push.apply(l,I),p.on(s,d),d.on("-",y).on(s,d).on(c,h),h.on("-",y).on(c,h);for(var x=0;x<l.length;x++)l[x].on("-",y).on(c,h);y.on("-",y).on(s,h).on(c,h),p.defaultTransition=f(i.SYM);var R=p;t.State=r.CharacterState,t.TOKENS=o,t.run=function(e){for(var t=e.replace(/[A-Z]/g,(function(e){return e.toLowerCase()})),n=e.length,r=[],i=0;i<n;){for(var o=p,a=null,s=0,c=null,u=-1;i<n&&(a=o.next(t[i]));)(o=a).accepts()?(u=0,c=o):u>=0&&u++,s++,i++;if(!(u<0)){i-=u,s-=u;var l=c.emit();r.push(new l(e.substr(i-s,s)))}}return r},t.start=R},function(e,t,n){"use strict";t.__esModule=!0,t.start=t.run=t.TOKENS=t.State=void 0;var r=n(428),i=n(776),o=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(i),a=n(326);var s=function(e){return new r.TokenState(e)},c=s(),u=s(),l=s(),f=s(),p=s(),d=s(),h=s(),y=s(i.URL),m=s(),v=s(i.URL),g=s(i.URL),b=s(),w=s(),_=s(),S=s(),T=s(),C=s(i.URL),E=s(i.URL),k=s(i.URL),O=s(i.URL),P=s(),A=s(),I=s(),x=s(),R=s(),L=s(),j=s(i.EMAIL),N=s(),D=s(i.EMAIL),B=s(i.MAILTOEMAIL),U=s(),M=s(),V=s(),F=s(),H=s(i.NL);c.on(a.NL,H).on(a.PROTOCOL,u).on(a.MAILTO,l).on(a.SLASH,f),u.on(a.SLASH,f),f.on(a.SLASH,p),c.on(a.TLD,d).on(a.DOMAIN,d).on(a.LOCALHOST,y).on(a.NUM,d),p.on(a.TLD,g).on(a.DOMAIN,g).on(a.NUM,g).on(a.LOCALHOST,g),d.on(a.DOT,h),R.on(a.DOT,L),h.on(a.TLD,y).on(a.DOMAIN,d).on(a.NUM,d).on(a.LOCALHOST,d),L.on(a.TLD,j).on(a.DOMAIN,R).on(a.NUM,R).on(a.LOCALHOST,R),y.on(a.DOT,h),j.on(a.DOT,L),y.on(a.COLON,m).on(a.SLASH,g),m.on(a.NUM,v),v.on(a.SLASH,g),j.on(a.COLON,N),N.on(a.NUM,D);var z=[a.DOMAIN,a.AT,a.LOCALHOST,a.NUM,a.PLUS,a.POUND,a.PROTOCOL,a.SLASH,a.TLD,a.UNDERSCORE,a.SYM,a.AMPERSAND],W=[a.COLON,a.DOT,a.QUERY,a.PUNCTUATION,a.CLOSEBRACE,a.CLOSEBRACKET,a.CLOSEANGLEBRACKET,a.CLOSEPAREN,a.OPENBRACE,a.OPENBRACKET,a.OPENANGLEBRACKET,a.OPENPAREN];g.on(a.OPENBRACE,w).on(a.OPENBRACKET,_).on(a.OPENANGLEBRACKET,S).on(a.OPENPAREN,T),b.on(a.OPENBRACE,w).on(a.OPENBRACKET,_).on(a.OPENANGLEBRACKET,S).on(a.OPENPAREN,T),w.on(a.CLOSEBRACE,g),_.on(a.CLOSEBRACKET,g),S.on(a.CLOSEANGLEBRACKET,g),T.on(a.CLOSEPAREN,g),C.on(a.CLOSEBRACE,g),E.on(a.CLOSEBRACKET,g),k.on(a.CLOSEANGLEBRACKET,g),O.on(a.CLOSEPAREN,g),P.on(a.CLOSEBRACE,g),A.on(a.CLOSEBRACKET,g),I.on(a.CLOSEANGLEBRACKET,g),x.on(a.CLOSEPAREN,g),w.on(z,C),_.on(z,E),S.on(z,k),T.on(z,O),w.on(W,P),_.on(W,A),S.on(W,I),T.on(W,x),C.on(z,C),E.on(z,E),k.on(z,k),O.on(z,O),C.on(W,C),E.on(W,E),k.on(W,k),O.on(W,O),P.on(z,C),A.on(z,E),I.on(z,k),x.on(z,O),P.on(W,P),A.on(W,A),I.on(W,I),x.on(W,x),g.on(z,g),b.on(z,g),g.on(W,b),b.on(W,b),l.on(a.TLD,B).on(a.DOMAIN,B).on(a.NUM,B).on(a.LOCALHOST,B),B.on(z,B).on(W,U),U.on(z,B).on(W,U);var q=[a.DOMAIN,a.NUM,a.PLUS,a.POUND,a.QUERY,a.UNDERSCORE,a.SYM,a.AMPERSAND,a.TLD];d.on(q,M).on(a.AT,V),y.on(q,M).on(a.AT,V),h.on(q,M),M.on(q,M).on(a.AT,V).on(a.DOT,F),F.on(q,M),V.on(a.TLD,R).on(a.DOMAIN,R).on(a.LOCALHOST,j);t.State=r.TokenState,t.TOKENS=o,t.run=function(e){for(var t=e.length,n=0,r=[],o=[];n<t;){for(var a=c,s=null,u=null,l=0,f=null,p=-1;n<t&&!(s=a.next(e[n]));)o.push(e[n++]);for(;n<t&&(u=s||a.next(e[n]));)s=null,(a=u).accepts()?(p=0,f=a):p>=0&&p++,n++,l++;if(p<0)for(var d=n-l;d<n;d++)o.push(e[d]);else{o.length>0&&(r.push(new i.TEXT(o)),o=[]),n-=p,l-=p;var h=f.emit();r.push(new h(e.slice(n-l,n)))}}return o.length>0&&r.push(new i.TEXT(o)),r},t.start=c},function(e,t,n){"use strict";t.__esModule=!0,t.URL=t.TEXT=t.NL=t.EMAIL=t.MAILTOEMAIL=t.Base=void 0;var r=n(429),i=n(265),o=n(326);function a(e){return e instanceof o.DOMAIN||e instanceof o.TLD}var s=(0,r.createTokenClass)();s.prototype={type:"token",isLink:!1,toString:function(){for(var e=[],t=0;t<this.v.length;t++)e.push(this.v[t].toString());return e.join("")},toHref:function(){return this.toString()},toObject:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"http";return{type:this.type,value:this.toString(),href:this.toHref(e)}}};var c=(0,i.inherits)(s,(0,r.createTokenClass)(),{type:"email",isLink:!0}),u=(0,i.inherits)(s,(0,r.createTokenClass)(),{type:"email",isLink:!0,toHref:function(){return"mailto:"+this.toString()}}),l=(0,i.inherits)(s,(0,r.createTokenClass)(),{type:"text"}),f=(0,i.inherits)(s,(0,r.createTokenClass)(),{type:"nl"}),p=(0,i.inherits)(s,(0,r.createTokenClass)(),{type:"url",isLink:!0,toHref:function(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"http",t=!1,n=!1,r=this.v,i=[],s=0;r[s]instanceof o.PROTOCOL;)t=!0,i.push(r[s].toString().toLowerCase()),s++;for(;r[s]instanceof o.SLASH;)n=!0,i.push(r[s].toString()),s++;for(;a(r[s]);)i.push(r[s].toString().toLowerCase()),s++;for(;s<r.length;s++)i.push(r[s].toString());return i=i.join(""),t||n||(i=e+"://"+i),i},hasProtocol:function(){return this.v[0]instanceof o.PROTOCOL}});t.Base=s,t.MAILTOEMAIL=c,t.EMAIL=u,t.NL=f,t.TEXT=l,t.URL=p},function(e,t,n){},function(e,t){},function(e,t,n){var r=n(765).default,i=n(23);e.exports=function(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?i(e):t},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){function n(t){return e.exports=n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},e.exports.default=e.exports,e.exports.__esModule=!0,n(t)}e.exports=n,e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){e.exports=function(e){if(!e)return!1;var t=n.call(e);return"[object Function]"===t||"function"==typeof e&&"[object RegExp]"!==t||"undefined"!=typeof window&&(e===window.setTimeout||e===window.alert||e===window.confirm||e===window.prompt)};var n=Object.prototype.toString},function(e,t,n){var r=n(296),i=Object.create||function(){function e(){}return function(t){if(1!==arguments.length)throw new Error("Object.create shim only accepts one parameter.");return e.prototype=t,new e}}();function o(e,t){this.name="ParsingError",this.code=e.code,this.message=t||e.message}function a(e){function t(e,t,n,r){return 3600*(0|e)+60*(0|t)+(0|n)+(0|r)/1e3}var n=e.match(/^(\d+):(\d{1,2})(:\d{1,2})?\.(\d{3})/);return n?n[3]?t(n[1],n[2],n[3].replace(":",""),n[4]):n[1]>59?t(n[1],n[2],0,n[4]):t(0,n[1],n[2],n[4]):null}function s(){this.values=i(null)}function c(e,t,n,r){var i=r?e.split(r):[e];for(var o in i)if("string"==typeof i[o]){var a=i[o].split(n);if(2===a.length)t(a[0],a[1])}}function u(e,t,n){var r=e;function i(){var t=a(e);if(null===t)throw new o(o.Errors.BadTimeStamp,"Malformed timestamp: "+r);return e=e.replace(/^[^\sa-zA-Z-]+/,""),t}function u(){e=e.replace(/^\s+/,"")}if(u(),t.startTime=i(),u(),"--\x3e"!==e.substr(0,3))throw new o(o.Errors.BadTimeStamp,"Malformed time stamp (time stamps must be separated by '--\x3e'): "+r);e=e.substr(3),u(),t.endTime=i(),u(),function(e,t){var r=new s;c(e,(function(e,t){switch(e){case"region":for(var i=n.length-1;i>=0;i--)if(n[i].id===t){r.set(e,n[i].region);break}break;case"vertical":r.alt(e,t,["rl","lr"]);break;case"line":var o=t.split(","),a=o[0];r.integer(e,a),r.percent(e,a)&&r.set("snapToLines",!1),r.alt(e,a,["auto"]),2===o.length&&r.alt("lineAlign",o[1],["start","center","end"]);break;case"position":o=t.split(","),r.percent(e,o[0]),2===o.length&&r.alt("positionAlign",o[1],["start","center","end"]);break;case"size":r.percent(e,t);break;case"align":r.alt(e,t,["start","center","end","left","right"])}}),/:/,/\s/),t.region=r.get("region",null),t.vertical=r.get("vertical","");try{t.line=r.get("line","auto")}catch(e){}t.lineAlign=r.get("lineAlign","start"),t.snapToLines=r.get("snapToLines",!0),t.size=r.get("size",100);try{t.align=r.get("align","center")}catch(e){t.align=r.get("align","middle")}try{t.position=r.get("position","auto")}catch(e){t.position=r.get("position",{start:0,left:0,center:50,middle:50,end:100,right:100},t.align)}t.positionAlign=r.get("positionAlign",{start:"start",left:"start",center:"center",middle:"center",end:"end",right:"end"},t.align)}(e,t)}o.prototype=i(Error.prototype),o.prototype.constructor=o,o.Errors={BadSignature:{code:0,message:"Malformed WebVTT signature."},BadTimeStamp:{code:1,message:"Malformed time stamp."}},s.prototype={set:function(e,t){this.get(e)||""===t||(this.values[e]=t)},get:function(e,t,n){return n?this.has(e)?this.values[e]:t[n]:this.has(e)?this.values[e]:t},has:function(e){return e in this.values},alt:function(e,t,n){for(var r=0;r<n.length;++r)if(t===n[r]){this.set(e,t);break}},integer:function(e,t){/^-?\d+$/.test(t)&&this.set(e,parseInt(t,10))},percent:function(e,t){return!!(t.match(/^([\d]{1,3})(\.[\d]*)?%$/)&&(t=parseFloat(t))>=0&&t<=100)&&(this.set(e,t),!0)}};var l=r.createElement("textarea"),f={c:"span",i:"i",b:"b",u:"u",ruby:"ruby",rt:"rt",v:"span",lang:"span"},p={white:"rgba(255,255,255,1)",lime:"rgba(0,255,0,1)",cyan:"rgba(0,255,255,1)",red:"rgba(255,0,0,1)",yellow:"rgba(255,255,0,1)",magenta:"rgba(255,0,255,1)",blue:"rgba(0,0,255,1)",black:"rgba(0,0,0,1)"},d={v:"title",lang:"lang"},h={rt:"ruby"};function y(e,t){function n(){if(!t)return null;var e,n=t.match(/^([^<]*)(<[^>]*>?)?/);return e=n[1]?n[1]:n[2],t=t.substr(e.length),e}function r(e,t){return!h[t.localName]||h[t.localName]===e.localName}function i(t,n){var r=f[t];if(!r)return null;var i=e.document.createElement(r),o=d[t];return o&&n&&(i[o]=n.trim()),i}for(var o,s,c=e.document.createElement("div"),u=c,y=[];null!==(o=n());)if("<"!==o[0])u.appendChild(e.document.createTextNode((s=o,l.innerHTML=s,s=l.textContent,l.textContent="",s)));else{if("/"===o[1]){y.length&&y[y.length-1]===o.substr(2).replace(">","")&&(y.pop(),u=u.parentNode);continue}var m,v=a(o.substr(1,o.length-2));if(v){m=e.document.createProcessingInstruction("timestamp",v),u.appendChild(m);continue}var g=o.match(/^<([^.\s/0-9>]+)(\.[^\s\\>]+)?([^>\\]+)?(\\?)>?$/);if(!g)continue;if(!(m=i(g[1],g[3])))continue;if(!r(u,m))continue;if(g[2]){var b=g[2].split(".");b.forEach((function(e){var t=/^bg_/.test(e),n=t?e.slice(3):e;if(p.hasOwnProperty(n)){var r=t?"background-color":"color",i=p[n];m.style[r]=i}})),m.className=b.join(" ")}y.push(g[1]),u.appendChild(m),u=m}return c}var m=[[1470,1470],[1472,1472],[1475,1475],[1478,1478],[1488,1514],[1520,1524],[1544,1544],[1547,1547],[1549,1549],[1563,1563],[1566,1610],[1645,1647],[1649,1749],[1765,1766],[1774,1775],[1786,1805],[1807,1808],[1810,1839],[1869,1957],[1969,1969],[1984,2026],[2036,2037],[2042,2042],[2048,2069],[2074,2074],[2084,2084],[2088,2088],[2096,2110],[2112,2136],[2142,2142],[2208,2208],[2210,2220],[8207,8207],[64285,64285],[64287,64296],[64298,64310],[64312,64316],[64318,64318],[64320,64321],[64323,64324],[64326,64449],[64467,64829],[64848,64911],[64914,64967],[65008,65020],[65136,65140],[65142,65276],[67584,67589],[67592,67592],[67594,67637],[67639,67640],[67644,67644],[67647,67669],[67671,67679],[67840,67867],[67872,67897],[67903,67903],[67968,68023],[68030,68031],[68096,68096],[68112,68115],[68117,68119],[68121,68147],[68160,68167],[68176,68184],[68192,68223],[68352,68405],[68416,68437],[68440,68466],[68472,68479],[68608,68680],[126464,126467],[126469,126495],[126497,126498],[126500,126500],[126503,126503],[126505,126514],[126516,126519],[126521,126521],[126523,126523],[126530,126530],[126535,126535],[126537,126537],[126539,126539],[126541,126543],[126545,126546],[126548,126548],[126551,126551],[126553,126553],[126555,126555],[126557,126557],[126559,126559],[126561,126562],[126564,126564],[126567,126570],[126572,126578],[126580,126583],[126585,126588],[126590,126590],[126592,126601],[126603,126619],[126625,126627],[126629,126633],[126635,126651],[1114109,1114109]];function v(e){for(var t=0;t<m.length;t++){var n=m[t];if(e>=n[0]&&e<=n[1])return!0}return!1}function g(e){var t=[],n="";if(!e||!e.childNodes)return"ltr";function r(e,t){for(var n=t.childNodes.length-1;n>=0;n--)e.push(t.childNodes[n])}function i(e){if(!e||!e.length)return null;var t=e.pop(),n=t.textContent||t.innerText;if(n){var o=n.match(/^.*(\n|\r)/);return o?(e.length=0,o[0]):n}return"ruby"===t.tagName?i(e):t.childNodes?(r(e,t),i(e)):void 0}for(r(t,e);n=i(t);)for(var o=0;o<n.length;o++)if(v(n.charCodeAt(o)))return"rtl";return"ltr"}function b(){}function w(e,t,n){b.call(this),this.cue=t,this.cueDiv=y(e,t.text);var r={color:"rgba(255, 255, 255, 1)",backgroundColor:"rgba(0, 0, 0, 0.8)",position:"relative",left:0,right:0,top:0,bottom:0,display:"inline",writingMode:""===t.vertical?"horizontal-tb":"lr"===t.vertical?"vertical-lr":"vertical-rl",unicodeBidi:"plaintext"};this.applyStyles(r,this.cueDiv),this.div=e.document.createElement("div"),r={direction:g(this.cueDiv),writingMode:""===t.vertical?"horizontal-tb":"lr"===t.vertical?"vertical-lr":"vertical-rl",unicodeBidi:"plaintext",textAlign:"middle"===t.align?"center":t.align,font:n.font,whiteSpace:"pre-line",position:"absolute"},this.applyStyles(r),this.div.appendChild(this.cueDiv);var i=0;switch(t.positionAlign){case"start":i=t.position;break;case"center":i=t.position-t.size/2;break;case"end":i=t.position-t.size}""===t.vertical?this.applyStyles({left:this.formatStyle(i,"%"),width:this.formatStyle(t.size,"%")}):this.applyStyles({top:this.formatStyle(i,"%"),height:this.formatStyle(t.size,"%")}),this.move=function(e){this.applyStyles({top:this.formatStyle(e.top,"px"),bottom:this.formatStyle(e.bottom,"px"),left:this.formatStyle(e.left,"px"),right:this.formatStyle(e.right,"px"),height:this.formatStyle(e.height,"px"),width:this.formatStyle(e.width,"px")})}}function _(e){var t,n,r,i;if(e.div){n=e.div.offsetHeight,r=e.div.offsetWidth,i=e.div.offsetTop;var o=(o=e.div.childNodes)&&(o=o[0])&&o.getClientRects&&o.getClientRects();e=e.div.getBoundingClientRect(),t=o?Math.max(o[0]&&o[0].height||0,e.height/o.length):0}this.left=e.left,this.right=e.right,this.top=e.top||i,this.height=e.height||n,this.bottom=e.bottom||i+(e.height||n),this.width=e.width||r,this.lineHeight=void 0!==t?t:e.lineHeight}function S(e,t,n,r){var i=new _(t),o=t.cue,a=function(e){if("number"==typeof e.line&&(e.snapToLines||e.line>=0&&e.line<=100))return e.line;if(!e.track||!e.track.textTrackList||!e.track.textTrackList.mediaElement)return-1;for(var t=e.track,n=t.textTrackList,r=0,i=0;i<n.length&&n[i]!==t;i++)"showing"===n[i].mode&&r++;return-1*++r}(o),s=[];if(o.snapToLines){var c;switch(o.vertical){case"":s=["+y","-y"],c="height";break;case"rl":s=["+x","-x"],c="width";break;case"lr":s=["-x","+x"],c="width"}var u=i.lineHeight,l=u*Math.round(a),f=n[c]+u,p=s[0];Math.abs(l)>f&&(l=l<0?-1:1,l*=Math.ceil(f/u)*u),a<0&&(l+=""===o.vertical?n.height:n.width,s=s.reverse()),i.move(p,l)}else{var d=i.lineHeight/n.height*100;switch(o.lineAlign){case"center":a-=d/2;break;case"end":a-=d}switch(o.vertical){case"":t.applyStyles({top:t.formatStyle(a,"%")});break;case"rl":t.applyStyles({left:t.formatStyle(a,"%")});break;case"lr":t.applyStyles({right:t.formatStyle(a,"%")})}s=["+y","-x","+x","-y"],i=new _(t)}var h=function(e,t){for(var i,o=new _(e),a=1,s=0;s<t.length;s++){for(;e.overlapsOppositeAxis(n,t[s])||e.within(n)&&e.overlapsAny(r);)e.move(t[s]);if(e.within(n))return e;var c=e.intersectPercentage(n);a>c&&(i=new _(e),a=c),e=new _(o)}return i||o}(i,s);t.move(h.toCSSCompatValues(n))}function T(){}b.prototype.applyStyles=function(e,t){for(var n in t=t||this.div,e)e.hasOwnProperty(n)&&(t.style[n]=e[n])},b.prototype.formatStyle=function(e,t){return 0===e?0:e+t},w.prototype=i(b.prototype),w.prototype.constructor=w,_.prototype.move=function(e,t){switch(t=void 0!==t?t:this.lineHeight,e){case"+x":this.left+=t,this.right+=t;break;case"-x":this.left-=t,this.right-=t;break;case"+y":this.top+=t,this.bottom+=t;break;case"-y":this.top-=t,this.bottom-=t}},_.prototype.overlaps=function(e){return this.left<e.right&&this.right>e.left&&this.top<e.bottom&&this.bottom>e.top},_.prototype.overlapsAny=function(e){for(var t=0;t<e.length;t++)if(this.overlaps(e[t]))return!0;return!1},_.prototype.within=function(e){return this.top>=e.top&&this.bottom<=e.bottom&&this.left>=e.left&&this.right<=e.right},_.prototype.overlapsOppositeAxis=function(e,t){switch(t){case"+x":return this.left<e.left;case"-x":return this.right>e.right;case"+y":return this.top<e.top;case"-y":return this.bottom>e.bottom}},_.prototype.intersectPercentage=function(e){return Math.max(0,Math.min(this.right,e.right)-Math.max(this.left,e.left))*Math.max(0,Math.min(this.bottom,e.bottom)-Math.max(this.top,e.top))/(this.height*this.width)},_.prototype.toCSSCompatValues=function(e){return{top:this.top-e.top,bottom:e.bottom-this.bottom,left:this.left-e.left,right:e.right-this.right,height:this.height,width:this.width}},_.getSimpleBoxPosition=function(e){var t=e.div?e.div.offsetHeight:e.tagName?e.offsetHeight:0,n=e.div?e.div.offsetWidth:e.tagName?e.offsetWidth:0,r=e.div?e.div.offsetTop:e.tagName?e.offsetTop:0;return{left:(e=e.div?e.div.getBoundingClientRect():e.tagName?e.getBoundingClientRect():e).left,right:e.right,top:e.top||r,height:e.height||t,bottom:e.bottom||r+(e.height||t),width:e.width||n}},T.StringDecoder=function(){return{decode:function(e){if(!e)return"";if("string"!=typeof e)throw new Error("Error - expected string data.");return decodeURIComponent(encodeURIComponent(e))}}},T.convertCueToDOMTree=function(e,t){return e&&t?y(e,t):null};T.processCues=function(e,t,n){if(!e||!t||!n)return null;for(;n.firstChild;)n.removeChild(n.firstChild);var r=e.document.createElement("div");if(r.style.position="absolute",r.style.left="0",r.style.right="0",r.style.top="0",r.style.bottom="0",r.style.margin="1.5%",n.appendChild(r),function(e){for(var t=0;t<e.length;t++)if(e[t].hasBeenReset||!e[t].displayState)return!0;return!1}(t)){var i=[],o=_.getSimpleBoxPosition(r),a={font:Math.round(.05*o.height*100)/100+"px sans-serif"};!function(){for(var n,s,c=0;c<t.length;c++)s=t[c],n=new w(e,s,a),r.appendChild(n.div),S(0,n,o,i),s.displayState=n.div,i.push(_.getSimpleBoxPosition(n))}()}else for(var s=0;s<t.length;s++)r.appendChild(t[s].displayState)},T.Parser=function(e,t,n){n||(n=t,t={}),t||(t={}),this.window=e,this.vttjs=t,this.state="INITIAL",this.buffer="",this.decoder=n||new TextDecoder("utf8"),this.regionList=[]},T.Parser.prototype={reportOrThrowError:function(e){if(!(e instanceof o))throw e;this.onparsingerror&&this.onparsingerror(e)},parse:function(e){var t=this;function n(){for(var e=t.buffer,n=0;n<e.length&&"\r"!==e[n]&&"\n"!==e[n];)++n;var r=e.substr(0,n);return"\r"===e[n]&&++n,"\n"===e[n]&&++n,t.buffer=e.substr(n),r}function r(e){e.match(/X-TIMESTAMP-MAP/)?c(e,(function(e,n){switch(e){case"X-TIMESTAMP-MAP":!function(e){var n=new s;c(e,(function(e,t){switch(e){case"MPEGT":n.integer(e+"S",t);break;case"LOCA":n.set(e+"L",a(t))}}),/[^\d]:/,/,/),t.ontimestampmap&&t.ontimestampmap({MPEGTS:n.get("MPEGTS"),LOCAL:n.get("LOCAL")})}(n)}}),/=/):c(e,(function(e,n){switch(e){case"Region":!function(e){var n=new s;if(c(e,(function(e,t){switch(e){case"id":n.set(e,t);break;case"width":n.percent(e,t);break;case"lines":n.integer(e,t);break;case"regionanchor":case"viewportanchor":var r=t.split(",");if(2!==r.length)break;var i=new s;if(i.percent("x",r[0]),i.percent("y",r[1]),!i.has("x")||!i.has("y"))break;n.set(e+"X",i.get("x")),n.set(e+"Y",i.get("y"));break;case"scroll":n.alt(e,t,["up"])}}),/=/,/\s/),n.has("id")){var r=new(t.vttjs.VTTRegion||t.window.VTTRegion);r.width=n.get("width",100),r.lines=n.get("lines",3),r.regionAnchorX=n.get("regionanchorX",0),r.regionAnchorY=n.get("regionanchorY",100),r.viewportAnchorX=n.get("viewportanchorX",0),r.viewportAnchorY=n.get("viewportanchorY",100),r.scroll=n.get("scroll",""),t.onregion&&t.onregion(r),t.regionList.push({id:n.get("id"),region:r})}}(n)}}),/:/)}e&&(t.buffer+=t.decoder.decode(e,{stream:!0}));try{var i;if("INITIAL"===t.state){if(!/\r\n|\n/.test(t.buffer))return this;var l=(i=n()).match(/^WEBVTT([ \t].*)?$/);if(!l||!l[0])throw new o(o.Errors.BadSignature);t.state="HEADER"}for(var f=!1;t.buffer;){if(!/\r\n|\n/.test(t.buffer))return this;switch(f?f=!1:i=n(),t.state){case"HEADER":/:/.test(i)?r(i):i||(t.state="ID");continue;case"NOTE":i||(t.state="ID");continue;case"ID":if(/^NOTE($|[ \t])/.test(i)){t.state="NOTE";break}if(!i)continue;t.cue=new(t.vttjs.VTTCue||t.window.VTTCue)(0,0,"");try{t.cue.align="center"}catch(e){t.cue.align="middle"}if(t.state="CUE",-1===i.indexOf("--\x3e")){t.cue.id=i;continue}case"CUE":try{u(i,t.cue,t.regionList)}catch(e){t.reportOrThrowError(e),t.cue=null,t.state="BADCUE";continue}t.state="CUETEXT";continue;case"CUETEXT":var p=-1!==i.indexOf("--\x3e");if(!i||p&&(f=!0)){t.oncue&&t.oncue(t.cue),t.cue=null,t.state="ID";continue}t.cue.text&&(t.cue.text+="\n"),t.cue.text+=i.replace(/\u2028/g,"\n").replace(/u2029/g,"\n");continue;case"BADCUE":i||(t.state="ID");continue}}}catch(e){t.reportOrThrowError(e),"CUETEXT"===t.state&&t.cue&&t.oncue&&t.oncue(t.cue),t.cue=null,t.state="INITIAL"===t.state?"BADWEBVTT":"BADCUE"}return this},flush:function(){try{if(this.buffer+=this.decoder.decode(),(this.cue||"HEADER"===this.state)&&(this.buffer+="\n\n",this.parse()),"INITIAL"===this.state)throw new o(o.Errors.BadSignature)}catch(e){this.reportOrThrowError(e)}return this.onflush&&this.onflush(),this}},e.exports=T},function(e,t){},function(e,t){var n={"":1,lr:1,rl:1},r={start:1,center:1,end:1,left:1,right:1,auto:1,"line-left":1,"line-right":1};function i(e){return"string"==typeof e&&(!!r[e.toLowerCase()]&&e.toLowerCase())}function o(e,t,r){this.hasBeenReset=!1;var o="",a=!1,s=e,c=t,u=r,l=null,f="",p=!0,d="auto",h="start",y="auto",m="auto",v=100,g="center";Object.defineProperties(this,{id:{enumerable:!0,get:function(){return o},set:function(e){o=""+e}},pauseOnExit:{enumerable:!0,get:function(){return a},set:function(e){a=!!e}},startTime:{enumerable:!0,get:function(){return s},set:function(e){if("number"!=typeof e)throw new TypeError("Start time must be set to a number.");s=e,this.hasBeenReset=!0}},endTime:{enumerable:!0,get:function(){return c},set:function(e){if("number"!=typeof e)throw new TypeError("End time must be set to a number.");c=e,this.hasBeenReset=!0}},text:{enumerable:!0,get:function(){return u},set:function(e){u=""+e,this.hasBeenReset=!0}},region:{enumerable:!0,get:function(){return l},set:function(e){l=e,this.hasBeenReset=!0}},vertical:{enumerable:!0,get:function(){return f},set:function(e){var t=function(e){return"string"==typeof e&&(!!n[e.toLowerCase()]&&e.toLowerCase())}(e);if(!1===t)throw new SyntaxError("Vertical: an invalid or illegal direction string was specified.");f=t,this.hasBeenReset=!0}},snapToLines:{enumerable:!0,get:function(){return p},set:function(e){p=!!e,this.hasBeenReset=!0}},line:{enumerable:!0,get:function(){return d},set:function(e){if("number"!=typeof e&&"auto"!==e)throw new SyntaxError("Line: an invalid number or illegal string was specified.");d=e,this.hasBeenReset=!0}},lineAlign:{enumerable:!0,get:function(){return h},set:function(e){var t=i(e);t?(h=t,this.hasBeenReset=!0):console.warn("lineAlign: an invalid or illegal string was specified.")}},position:{enumerable:!0,get:function(){return y},set:function(e){if(e<0||e>100)throw new Error("Position must be between 0 and 100.");y=e,this.hasBeenReset=!0}},positionAlign:{enumerable:!0,get:function(){return m},set:function(e){var t=i(e);t?(m=t,this.hasBeenReset=!0):console.warn("positionAlign: an invalid or illegal string was specified.")}},size:{enumerable:!0,get:function(){return v},set:function(e){if(e<0||e>100)throw new Error("Size must be between 0 and 100.");v=e,this.hasBeenReset=!0}},align:{enumerable:!0,get:function(){return g},set:function(e){var t=i(e);if(!t)throw new SyntaxError("align: an invalid or illegal alignment string was specified.");g=t,this.hasBeenReset=!0}}}),this.displayState=void 0}o.prototype.getCueAsHTML=function(){return WebVTT.convertCueToDOMTree(window,this.text)},e.exports=o},function(e,t){var n={"":!0,up:!0};function r(e){return"number"==typeof e&&e>=0&&e<=100}e.exports=function(){var e=100,t=3,i=0,o=100,a=0,s=100,c="";Object.defineProperties(this,{width:{enumerable:!0,get:function(){return e},set:function(t){if(!r(t))throw new Error("Width must be between 0 and 100.");e=t}},lines:{enumerable:!0,get:function(){return t},set:function(e){if("number"!=typeof e)throw new TypeError("Lines must be set to a number.");t=e}},regionAnchorY:{enumerable:!0,get:function(){return o},set:function(e){if(!r(e))throw new Error("RegionAnchorX must be between 0 and 100.");o=e}},regionAnchorX:{enumerable:!0,get:function(){return i},set:function(e){if(!r(e))throw new Error("RegionAnchorY must be between 0 and 100.");i=e}},viewportAnchorY:{enumerable:!0,get:function(){return s},set:function(e){if(!r(e))throw new Error("ViewportAnchorY must be between 0 and 100.");s=e}},viewportAnchorX:{enumerable:!0,get:function(){return a},set:function(e){if(!r(e))throw new Error("ViewportAnchorX must be between 0 and 100.");a=e}},scroll:{enumerable:!0,get:function(){return c},set:function(e){var t=function(e){return"string"==typeof e&&(!!n[e.toLowerCase()]&&e.toLowerCase())}(e);!1===t?console.warn("Scroll: an invalid or illegal string was specified."):c=t}}})}},function(e,t){e.exports=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){var r,i,o,a,s;r=/^((?:[a-zA-Z0-9+\-.]+:)?)(\/\/[^\/?#]*)?((?:[^\/?#]*\/)*[^;?#]*)?(;[^?#]*)?(\?[^#]*)?(#.*)?$/,i=/^([^\/?#]*)(.*)$/,o=/(?:\/|^)\.(?=\/)/g,a=/(?:\/|^)\.\.\/(?!\.\.\/)[^\/]*(?=\/)/g,s={buildAbsoluteURL:function(e,t,n){if(n=n||{},e=e.trim(),!(t=t.trim())){if(!n.alwaysNormalize)return e;var r=s.parseURL(e);if(!r)throw new Error("Error trying to parse base URL.");return r.path=s.normalizePath(r.path),s.buildURLFromParts(r)}var o=s.parseURL(t);if(!o)throw new Error("Error trying to parse relative URL.");if(o.scheme)return n.alwaysNormalize?(o.path=s.normalizePath(o.path),s.buildURLFromParts(o)):t;var a=s.parseURL(e);if(!a)throw new Error("Error trying to parse base URL.");if(!a.netLoc&&a.path&&"/"!==a.path[0]){var c=i.exec(a.path);a.netLoc=c[1],a.path=c[2]}a.netLoc&&!a.path&&(a.path="/");var u={scheme:a.scheme,netLoc:o.netLoc,path:null,params:o.params,query:o.query,fragment:o.fragment};if(!o.netLoc&&(u.netLoc=a.netLoc,"/"!==o.path[0]))if(o.path){var l=a.path,f=l.substring(0,l.lastIndexOf("/")+1)+o.path;u.path=s.normalizePath(f)}else u.path=a.path,o.params||(u.params=a.params,o.query||(u.query=a.query));return null===u.path&&(u.path=n.alwaysNormalize?s.normalizePath(o.path):o.path),s.buildURLFromParts(u)},parseURL:function(e){var t=r.exec(e);return t?{scheme:t[1]||"",netLoc:t[2]||"",path:t[3]||"",params:t[4]||"",query:t[5]||"",fragment:t[6]||""}:null},normalizePath:function(e){for(e=e.split("").reverse().join("").replace(o,"");e.length!==(e=e.replace(a,"")).length;);return e.split("").reverse().join("")},buildURLFromParts:function(e){return e.scheme+e.netLoc+e.path+e.params+e.query+e.fragment}},e.exports=s},function(e,t,n){"use strict";t.byteLength=function(e){var t=u(e),n=t[0],r=t[1];return 3*(n+r)/4-r},t.toByteArray=function(e){var t,n,r=u(e),a=r[0],s=r[1],c=new o(function(e,t,n){return 3*(t+n)/4-n}(0,a,s)),l=0,f=s>0?a-4:a;for(n=0;n<f;n+=4)t=i[e.charCodeAt(n)]<<18|i[e.charCodeAt(n+1)]<<12|i[e.charCodeAt(n+2)]<<6|i[e.charCodeAt(n+3)],c[l++]=t>>16&255,c[l++]=t>>8&255,c[l++]=255&t;2===s&&(t=i[e.charCodeAt(n)]<<2|i[e.charCodeAt(n+1)]>>4,c[l++]=255&t);1===s&&(t=i[e.charCodeAt(n)]<<10|i[e.charCodeAt(n+1)]<<4|i[e.charCodeAt(n+2)]>>2,c[l++]=t>>8&255,c[l++]=255&t);return c},t.fromByteArray=function(e){for(var t,n=e.length,i=n%3,o=[],a=0,s=n-i;a<s;a+=16383)o.push(l(e,a,a+16383>s?s:a+16383));1===i?(t=e[n-1],o.push(r[t>>2]+r[t<<4&63]+"==")):2===i&&(t=(e[n-2]<<8)+e[n-1],o.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return o.join("")};for(var r=[],i=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,c=a.length;s<c;++s)r[s]=a[s],i[a.charCodeAt(s)]=s;function u(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function l(e,t,n){for(var i,o,a=[],s=t;s<n;s+=3)i=(e[s]<<16&16711680)+(e[s+1]<<8&65280)+(255&e[s+2]),a.push(r[(o=i)>>18&63]+r[o>>12&63]+r[o>>6&63]+r[63&o]);return a.join("")}i["-".charCodeAt(0)]=62,i["_".charCodeAt(0)]=63},function(e,t){
|
|
46
|
+
e.exports=function(){"use strict";function e(t){return(e="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})(t)}function t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?i(n,!0).forEach((function(t){r(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(n).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function a(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t<e.length;t++)n[t]=e[t];return n}}(e)||function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}var s="undefined"!=typeof window&&void 0!==window.document,c=s?window:{},u=!!s&&"ontouchstart"in c.document.documentElement,l=!!s&&"PointerEvent"in c,f="".concat("cropper","-crop"),p="".concat("cropper","-disabled"),d="".concat("cropper","-hidden"),h="".concat("cropper","-hide"),y="".concat("cropper","-invisible"),m="".concat("cropper","-modal"),v="".concat("cropper","-move"),g="".concat("cropper","Action"),b="".concat("cropper","Preview"),w=u?"touchstart":"mousedown",_=u?"touchmove":"mousemove",S=u?"touchend touchcancel":"mouseup",T=l?"pointerdown":w,C=l?"pointermove":_,E=l?"pointerup pointercancel":S,k=/^e|w|s|n|se|sw|ne|nw|all|crop|move|zoom$/,O=/^data:/,P=/^data:image\/jpeg;base64,/,A=/^img|canvas$/i,I={viewMode:0,dragMode:"crop",initialAspectRatio:NaN,aspectRatio:NaN,data:null,preview:"",responsive:!0,restore:!0,checkCrossOrigin:!0,checkOrientation:!0,modal:!0,guides:!0,center:!0,highlight:!0,background:!0,autoCrop:!0,autoCropArea:.8,movable:!0,rotatable:!0,scalable:!0,zoomable:!0,zoomOnTouch:!0,zoomOnWheel:!0,wheelZoomRatio:.1,cropBoxMovable:!0,cropBoxResizable:!0,toggleDragModeOnDblclick:!0,minCanvasWidth:0,minCanvasHeight:0,minCropBoxWidth:0,minCropBoxHeight:0,minContainerWidth:200,minContainerHeight:100,ready:null,cropstart:null,cropmove:null,cropend:null,crop:null,zoom:null},x=Number.isNaN||c.isNaN;function R(e){return"number"==typeof e&&!x(e)}var L=function(e){return e>0&&e<1/0};function j(e){return void 0===e}function N(t){return"object"===e(t)&&null!==t}var D=Object.prototype.hasOwnProperty;function B(e){if(!N(e))return!1;try{var t=e.constructor,n=t.prototype;return t&&n&&D.call(n,"isPrototypeOf")}catch(e){return!1}}function U(e){return"function"==typeof e}var M=Array.prototype.slice;function V(e){return Array.from?Array.from(e):M.call(e)}function F(e,t){return e&&U(t)&&(Array.isArray(e)||R(e.length)?V(e).forEach((function(n,r){t.call(e,n,r,e)})):N(e)&&Object.keys(e).forEach((function(n){t.call(e,e[n],n,e)}))),e}var H=Object.assign||function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return N(e)&&n.length>0&&n.forEach((function(t){N(t)&&Object.keys(t).forEach((function(n){e[n]=t[n]}))})),e},z=/\.\d*(?:0|9){12}\d*$/;function W(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1e11;return z.test(e)?Math.round(e*t)/t:e}var q=/^width|height|left|top|marginLeft|marginTop$/;function G(e,t){var n=e.style;F(t,(function(e,t){q.test(t)&&R(e)&&(e="".concat(e,"px")),n[t]=e}))}function K(e,t){if(t)if(R(e.length))F(e,(function(e){K(e,t)}));else if(e.classList)e.classList.add(t);else{var n=e.className.trim();n?n.indexOf(t)<0&&(e.className="".concat(n," ").concat(t)):e.className=t}}function Y(e,t){t&&(R(e.length)?F(e,(function(e){Y(e,t)})):e.classList?e.classList.remove(t):e.className.indexOf(t)>=0&&(e.className=e.className.replace(t,"")))}function X(e,t,n){t&&(R(e.length)?F(e,(function(e){X(e,t,n)})):n?K(e,t):Y(e,t))}var Q=/([a-z\d])([A-Z])/g;function $(e){return e.replace(Q,"$1-$2").toLowerCase()}function Z(e,t){return N(e[t])?e[t]:e.dataset?e.dataset[t]:e.getAttribute("data-".concat($(t)))}function J(e,t,n){N(n)?e[t]=n:e.dataset?e.dataset[t]=n:e.setAttribute("data-".concat($(t)),n)}var ee=/\s\s*/,te=function(){var e=!1;if(s){var t=!1,n=function(){},r=Object.defineProperty({},"once",{get:function(){return e=!0,t},set:function(e){t=e}});c.addEventListener("test",n,r),c.removeEventListener("test",n,r)}return e}();function ne(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=n;t.trim().split(ee).forEach((function(t){if(!te){var o=e.listeners;o&&o[t]&&o[t][n]&&(i=o[t][n],delete o[t][n],0===Object.keys(o[t]).length&&delete o[t],0===Object.keys(o).length&&delete e.listeners)}e.removeEventListener(t,i,r)}))}function re(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=n;t.trim().split(ee).forEach((function(t){if(r.once&&!te){var o=e.listeners,a=void 0===o?{}:o;i=function(){delete a[t][n],e.removeEventListener(t,i,r);for(var o=arguments.length,s=new Array(o),c=0;c<o;c++)s[c]=arguments[c];n.apply(e,s)},a[t]||(a[t]={}),a[t][n]&&e.removeEventListener(t,a[t][n],r),a[t][n]=i,e.listeners=a}e.addEventListener(t,i,r)}))}function ie(e,t,n){var r;return U(Event)&&U(CustomEvent)?r=new CustomEvent(t,{detail:n,bubbles:!0,cancelable:!0}):(r=document.createEvent("CustomEvent")).initCustomEvent(t,!0,!0,n),e.dispatchEvent(r)}function oe(e){var t=e.getBoundingClientRect();return{left:t.left+(window.pageXOffset-document.documentElement.clientLeft),top:t.top+(window.pageYOffset-document.documentElement.clientTop)}}var ae=c.location,se=/^(\w+:)\/\/([^:/?#]*):?(\d*)/i;function ce(e){var t=e.match(se);return null!==t&&(t[1]!==ae.protocol||t[2]!==ae.hostname||t[3]!==ae.port)}function ue(e){var t="timestamp=".concat((new Date).getTime());return e+(-1===e.indexOf("?")?"?":"&")+t}function le(e){var t=e.rotate,n=e.scaleX,r=e.scaleY,i=e.translateX,o=e.translateY,a=[];R(i)&&0!==i&&a.push("translateX(".concat(i,"px)")),R(o)&&0!==o&&a.push("translateY(".concat(o,"px)")),R(t)&&0!==t&&a.push("rotate(".concat(t,"deg)")),R(n)&&1!==n&&a.push("scaleX(".concat(n,")")),R(r)&&1!==r&&a.push("scaleY(".concat(r,")"));var s=a.length?a.join(" "):"none";return{WebkitTransform:s,msTransform:s,transform:s}}function fe(e,t){var n=e.pageX,r=e.pageY,i={endX:n,endY:r};return t?i:o({startX:n,startY:r},i)}function pe(e){var t=e.aspectRatio,n=e.height,r=e.width,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"contain",o=L(r),a=L(n);if(o&&a){var s=n*t;"contain"===i&&s>r||"cover"===i&&s<r?n=r/t:r=n*t}else o?n=r/t:a&&(r=n*t);return{width:r,height:n}}function de(e,t,n,r){var i=t.aspectRatio,o=t.naturalWidth,s=t.naturalHeight,c=t.rotate,u=void 0===c?0:c,l=t.scaleX,f=void 0===l?1:l,p=t.scaleY,d=void 0===p?1:p,h=n.aspectRatio,y=n.naturalWidth,m=n.naturalHeight,v=r.fillColor,g=void 0===v?"transparent":v,b=r.imageSmoothingEnabled,w=void 0===b||b,_=r.imageSmoothingQuality,S=void 0===_?"low":_,T=r.maxWidth,C=void 0===T?1/0:T,E=r.maxHeight,k=void 0===E?1/0:E,O=r.minWidth,P=void 0===O?0:O,A=r.minHeight,I=void 0===A?0:A,x=document.createElement("canvas"),R=x.getContext("2d"),L=pe({aspectRatio:h,width:C,height:k}),j=pe({aspectRatio:h,width:P,height:I},"cover"),N=Math.min(L.width,Math.max(j.width,y)),D=Math.min(L.height,Math.max(j.height,m)),B=pe({aspectRatio:i,width:C,height:k}),U=pe({aspectRatio:i,width:P,height:I},"cover"),M=Math.min(B.width,Math.max(U.width,o)),V=Math.min(B.height,Math.max(U.height,s)),F=[-M/2,-V/2,M,V];return x.width=W(N),x.height=W(D),R.fillStyle=g,R.fillRect(0,0,N,D),R.save(),R.translate(N/2,D/2),R.rotate(u*Math.PI/180),R.scale(f,d),R.imageSmoothingEnabled=w,R.imageSmoothingQuality=S,R.drawImage.apply(R,[e].concat(a(F.map((function(e){return Math.floor(W(e))}))))),R.restore(),x}var he=String.fromCharCode,ye=/^data:.*,/;function me(e){var t,n=new DataView(e);try{var r,i,o;if(255===n.getUint8(0)&&216===n.getUint8(1))for(var a=n.byteLength,s=2;s+1<a;){if(255===n.getUint8(s)&&225===n.getUint8(s+1)){i=s;break}s+=1}if(i){var c=i+10;if("Exif"===function(e,t,n){var r="";n+=t;for(var i=t;i<n;i+=1)r+=he(e.getUint8(i));return r}(n,i+4,4)){var u=n.getUint16(c);if(((r=18761===u)||19789===u)&&42===n.getUint16(c+2,r)){var l=n.getUint32(c+4,r);l>=8&&(o=c+l)}}}if(o){var f,p,d=n.getUint16(o,r);for(p=0;p<d;p+=1)if(f=o+12*p+2,274===n.getUint16(f,r)){f+=8,t=n.getUint16(f,r),n.setUint16(f,1,r);break}}}catch(e){t=1}return t}var ve={render:function(){this.initContainer(),this.initCanvas(),this.initCropBox(),this.renderCanvas(),this.cropped&&this.renderCropBox()},initContainer:function(){var e=this.element,t=this.options,n=this.container,r=this.cropper;K(r,d),Y(e,d);var i={width:Math.max(n.offsetWidth,Number(t.minContainerWidth)||200),height:Math.max(n.offsetHeight,Number(t.minContainerHeight)||100)};this.containerData=i,G(r,{width:i.width,height:i.height}),K(e,d),Y(r,d)},initCanvas:function(){var e=this.containerData,t=this.imageData,n=this.options.viewMode,r=Math.abs(t.rotate)%180==90,i=r?t.naturalHeight:t.naturalWidth,o=r?t.naturalWidth:t.naturalHeight,a=i/o,s=e.width,c=e.height;e.height*a>e.width?3===n?s=e.height*a:c=e.width/a:3===n?c=e.width/a:s=e.height*a;var u={aspectRatio:a,naturalWidth:i,naturalHeight:o,width:s,height:c};u.left=(e.width-s)/2,u.top=(e.height-c)/2,u.oldLeft=u.left,u.oldTop=u.top,this.canvasData=u,this.limited=1===n||2===n,this.limitCanvas(!0,!0),this.initialImageData=H({},t),this.initialCanvasData=H({},u)},limitCanvas:function(e,t){var n=this.options,r=this.containerData,i=this.canvasData,o=this.cropBoxData,a=n.viewMode,s=i.aspectRatio,c=this.cropped&&o;if(e){var u=Number(n.minCanvasWidth)||0,l=Number(n.minCanvasHeight)||0;a>1?(u=Math.max(u,r.width),l=Math.max(l,r.height),3===a&&(l*s>u?u=l*s:l=u/s)):a>0&&(u?u=Math.max(u,c?o.width:0):l?l=Math.max(l,c?o.height:0):c&&(u=o.width,(l=o.height)*s>u?u=l*s:l=u/s));var f=pe({aspectRatio:s,width:u,height:l});u=f.width,l=f.height,i.minWidth=u,i.minHeight=l,i.maxWidth=1/0,i.maxHeight=1/0}if(t)if(a>(c?0:1)){var p=r.width-i.width,d=r.height-i.height;i.minLeft=Math.min(0,p),i.minTop=Math.min(0,d),i.maxLeft=Math.max(0,p),i.maxTop=Math.max(0,d),c&&this.limited&&(i.minLeft=Math.min(o.left,o.left+(o.width-i.width)),i.minTop=Math.min(o.top,o.top+(o.height-i.height)),i.maxLeft=o.left,i.maxTop=o.top,2===a&&(i.width>=r.width&&(i.minLeft=Math.min(0,p),i.maxLeft=Math.max(0,p)),i.height>=r.height&&(i.minTop=Math.min(0,d),i.maxTop=Math.max(0,d))))}else i.minLeft=-i.width,i.minTop=-i.height,i.maxLeft=r.width,i.maxTop=r.height},renderCanvas:function(e,t){var n=this.canvasData,r=this.imageData;if(t){var i=function(e){var t=e.width,n=e.height,r=e.degree;if(90==(r=Math.abs(r)%180))return{width:n,height:t};var i=r%90*Math.PI/180,o=Math.sin(i),a=Math.cos(i),s=t*a+n*o,c=t*o+n*a;return r>90?{width:c,height:s}:{width:s,height:c}}({width:r.naturalWidth*Math.abs(r.scaleX||1),height:r.naturalHeight*Math.abs(r.scaleY||1),degree:r.rotate||0}),o=i.width,a=i.height,s=n.width*(o/n.naturalWidth),c=n.height*(a/n.naturalHeight);n.left-=(s-n.width)/2,n.top-=(c-n.height)/2,n.width=s,n.height=c,n.aspectRatio=o/a,n.naturalWidth=o,n.naturalHeight=a,this.limitCanvas(!0,!1)}(n.width>n.maxWidth||n.width<n.minWidth)&&(n.left=n.oldLeft),(n.height>n.maxHeight||n.height<n.minHeight)&&(n.top=n.oldTop),n.width=Math.min(Math.max(n.width,n.minWidth),n.maxWidth),n.height=Math.min(Math.max(n.height,n.minHeight),n.maxHeight),this.limitCanvas(!1,!0),n.left=Math.min(Math.max(n.left,n.minLeft),n.maxLeft),n.top=Math.min(Math.max(n.top,n.minTop),n.maxTop),n.oldLeft=n.left,n.oldTop=n.top,G(this.canvas,H({width:n.width,height:n.height},le({translateX:n.left,translateY:n.top}))),this.renderImage(e),this.cropped&&this.limited&&this.limitCropBox(!0,!0)},renderImage:function(e){var t=this.canvasData,n=this.imageData,r=n.naturalWidth*(t.width/t.naturalWidth),i=n.naturalHeight*(t.height/t.naturalHeight);H(n,{width:r,height:i,left:(t.width-r)/2,top:(t.height-i)/2}),G(this.image,H({width:n.width,height:n.height},le(H({translateX:n.left,translateY:n.top},n)))),e&&this.output()},initCropBox:function(){var e=this.options,t=this.canvasData,n=e.aspectRatio||e.initialAspectRatio,r=Number(e.autoCropArea)||.8,i={width:t.width,height:t.height};n&&(t.height*n>t.width?i.height=i.width/n:i.width=i.height*n),this.cropBoxData=i,this.limitCropBox(!0,!0),i.width=Math.min(Math.max(i.width,i.minWidth),i.maxWidth),i.height=Math.min(Math.max(i.height,i.minHeight),i.maxHeight),i.width=Math.max(i.minWidth,i.width*r),i.height=Math.max(i.minHeight,i.height*r),i.left=t.left+(t.width-i.width)/2,i.top=t.top+(t.height-i.height)/2,i.oldLeft=i.left,i.oldTop=i.top,this.initialCropBoxData=H({},i)},limitCropBox:function(e,t){var n=this.options,r=this.containerData,i=this.canvasData,o=this.cropBoxData,a=this.limited,s=n.aspectRatio;if(e){var c=Number(n.minCropBoxWidth)||0,u=Number(n.minCropBoxHeight)||0,l=a?Math.min(r.width,i.width,i.width+i.left,r.width-i.left):r.width,f=a?Math.min(r.height,i.height,i.height+i.top,r.height-i.top):r.height;c=Math.min(c,r.width),u=Math.min(u,r.height),s&&(c&&u?u*s>c?u=c/s:c=u*s:c?u=c/s:u&&(c=u*s),f*s>l?f=l/s:l=f*s),o.minWidth=Math.min(c,l),o.minHeight=Math.min(u,f),o.maxWidth=l,o.maxHeight=f}t&&(a?(o.minLeft=Math.max(0,i.left),o.minTop=Math.max(0,i.top),o.maxLeft=Math.min(r.width,i.left+i.width)-o.width,o.maxTop=Math.min(r.height,i.top+i.height)-o.height):(o.minLeft=0,o.minTop=0,o.maxLeft=r.width-o.width,o.maxTop=r.height-o.height))},renderCropBox:function(){var e=this.options,t=this.containerData,n=this.cropBoxData;(n.width>n.maxWidth||n.width<n.minWidth)&&(n.left=n.oldLeft),(n.height>n.maxHeight||n.height<n.minHeight)&&(n.top=n.oldTop),n.width=Math.min(Math.max(n.width,n.minWidth),n.maxWidth),n.height=Math.min(Math.max(n.height,n.minHeight),n.maxHeight),this.limitCropBox(!1,!0),n.left=Math.min(Math.max(n.left,n.minLeft),n.maxLeft),n.top=Math.min(Math.max(n.top,n.minTop),n.maxTop),n.oldLeft=n.left,n.oldTop=n.top,e.movable&&e.cropBoxMovable&&J(this.face,g,n.width>=t.width&&n.height>=t.height?"move":"all"),G(this.cropBox,H({width:n.width,height:n.height},le({translateX:n.left,translateY:n.top}))),this.cropped&&this.limited&&this.limitCanvas(!0,!0),this.disabled||this.output()},output:function(){this.preview(),ie(this.element,"crop",this.getData())}},ge={initPreview:function(){var e=this.element,t=this.crossOrigin,n=this.options.preview,r=t?this.crossOriginUrl:this.url,i=e.alt||"The image to preview",o=document.createElement("img");if(t&&(o.crossOrigin=t),o.src=r,o.alt=i,this.viewBox.appendChild(o),this.viewBoxImage=o,n){var a=n;"string"==typeof n?a=e.ownerDocument.querySelectorAll(n):n.querySelector&&(a=[n]),this.previews=a,F(a,(function(e){var n=document.createElement("img");J(e,b,{width:e.offsetWidth,height:e.offsetHeight,html:e.innerHTML}),t&&(n.crossOrigin=t),n.src=r,n.alt=i,n.style.cssText='display:block;width:100%;height:auto;min-width:0!important;min-height:0!important;max-width:none!important;max-height:none!important;image-orientation:0deg!important;"',e.innerHTML="",e.appendChild(n)}))}},resetPreview:function(){F(this.previews,(function(e){var t=Z(e,b);G(e,{width:t.width,height:t.height}),e.innerHTML=t.html,function(e,t){if(N(e[t]))try{delete e[t]}catch(n){e[t]=void 0}else if(e.dataset)try{delete e.dataset[t]}catch(n){e.dataset[t]=void 0}else e.removeAttribute("data-".concat($(t)))}(e,b)}))},preview:function(){var e=this.imageData,t=this.canvasData,n=this.cropBoxData,r=n.width,i=n.height,o=e.width,a=e.height,s=n.left-t.left-e.left,c=n.top-t.top-e.top;this.cropped&&!this.disabled&&(G(this.viewBoxImage,H({width:o,height:a},le(H({translateX:-s,translateY:-c},e)))),F(this.previews,(function(t){var n=Z(t,b),u=n.width,l=n.height,f=u,p=l,d=1;r&&(p=i*(d=u/r)),i&&p>l&&(f=r*(d=l/i),p=l),G(t,{width:f,height:p}),G(t.getElementsByTagName("img")[0],H({width:o*d,height:a*d},le(H({translateX:-s*d,translateY:-c*d},e))))})))}},be={bind:function(){var e=this.element,t=this.options,n=this.cropper;U(t.cropstart)&&re(e,"cropstart",t.cropstart),U(t.cropmove)&&re(e,"cropmove",t.cropmove),U(t.cropend)&&re(e,"cropend",t.cropend),U(t.crop)&&re(e,"crop",t.crop),U(t.zoom)&&re(e,"zoom",t.zoom),re(n,T,this.onCropStart=this.cropStart.bind(this)),t.zoomable&&t.zoomOnWheel&&re(n,"wheel",this.onWheel=this.wheel.bind(this),{passive:!1,capture:!0}),t.toggleDragModeOnDblclick&&re(n,"dblclick",this.onDblclick=this.dblclick.bind(this)),re(e.ownerDocument,C,this.onCropMove=this.cropMove.bind(this)),re(e.ownerDocument,E,this.onCropEnd=this.cropEnd.bind(this)),t.responsive&&re(window,"resize",this.onResize=this.resize.bind(this))},unbind:function(){var e=this.element,t=this.options,n=this.cropper;U(t.cropstart)&&ne(e,"cropstart",t.cropstart),U(t.cropmove)&&ne(e,"cropmove",t.cropmove),U(t.cropend)&&ne(e,"cropend",t.cropend),U(t.crop)&&ne(e,"crop",t.crop),U(t.zoom)&&ne(e,"zoom",t.zoom),ne(n,T,this.onCropStart),t.zoomable&&t.zoomOnWheel&&ne(n,"wheel",this.onWheel,{passive:!1,capture:!0}),t.toggleDragModeOnDblclick&&ne(n,"dblclick",this.onDblclick),ne(e.ownerDocument,C,this.onCropMove),ne(e.ownerDocument,E,this.onCropEnd),t.responsive&&ne(window,"resize",this.onResize)}},we={resize:function(){var e=this.options,t=this.container,n=this.containerData,r=Number(e.minContainerWidth)||200,i=Number(e.minContainerHeight)||100;if(!(this.disabled||n.width<=r||n.height<=i)){var o,a,s=t.offsetWidth/n.width;1===s&&t.offsetHeight===n.height||(e.restore&&(o=this.getCanvasData(),a=this.getCropBoxData()),this.render(),e.restore&&(this.setCanvasData(F(o,(function(e,t){o[t]=e*s}))),this.setCropBoxData(F(a,(function(e,t){a[t]=e*s})))))}},dblclick:function(){var e,t;this.disabled||"none"===this.options.dragMode||this.setDragMode((e=this.dragBox,t=f,(e.classList?e.classList.contains(t):e.className.indexOf(t)>-1)?"move":"crop"))},wheel:function(e){var t=this,n=Number(this.options.wheelZoomRatio)||.1,r=1;this.disabled||(e.preventDefault(),this.wheeling||(this.wheeling=!0,setTimeout((function(){t.wheeling=!1}),50),e.deltaY?r=e.deltaY>0?1:-1:e.wheelDelta?r=-e.wheelDelta/120:e.detail&&(r=e.detail>0?1:-1),this.zoom(-r*n,e)))},cropStart:function(e){var t=e.buttons,n=e.button;if(!(this.disabled||("mousedown"===e.type||"pointerdown"===e.type&&"mouse"===e.pointerType)&&(R(t)&&1!==t||R(n)&&0!==n||e.ctrlKey))){var r,i=this.options,o=this.pointers;e.changedTouches?F(e.changedTouches,(function(e){o[e.identifier]=fe(e)})):o[e.pointerId||0]=fe(e),r=Object.keys(o).length>1&&i.zoomable&&i.zoomOnTouch?"zoom":Z(e.target,g),k.test(r)&&!1!==ie(this.element,"cropstart",{originalEvent:e,action:r})&&(e.preventDefault(),this.action=r,this.cropping=!1,"crop"===r&&(this.cropping=!0,K(this.dragBox,m)))}},cropMove:function(e){var t=this.action;if(!this.disabled&&t){var n=this.pointers;e.preventDefault(),!1!==ie(this.element,"cropmove",{originalEvent:e,action:t})&&(e.changedTouches?F(e.changedTouches,(function(e){H(n[e.identifier]||{},fe(e,!0))})):H(n[e.pointerId||0]||{},fe(e,!0)),this.change(e))}},cropEnd:function(e){if(!this.disabled){var t=this.action,n=this.pointers;e.changedTouches?F(e.changedTouches,(function(e){delete n[e.identifier]})):delete n[e.pointerId||0],t&&(e.preventDefault(),Object.keys(n).length||(this.action=""),this.cropping&&(this.cropping=!1,X(this.dragBox,m,this.cropped&&this.options.modal)),ie(this.element,"cropend",{originalEvent:e,action:t}))}}},_e={change:function(e){var t,n=this.options,r=this.canvasData,i=this.containerData,a=this.cropBoxData,s=this.pointers,c=this.action,u=n.aspectRatio,l=a.left,f=a.top,p=a.width,h=a.height,y=l+p,m=f+h,v=0,g=0,b=i.width,w=i.height,_=!0;!u&&e.shiftKey&&(u=p&&h?p/h:1),this.limited&&(v=a.minLeft,g=a.minTop,b=v+Math.min(i.width,r.width,r.left+r.width),w=g+Math.min(i.height,r.height,r.top+r.height));var S=s[Object.keys(s)[0]],T={x:S.endX-S.startX,y:S.endY-S.startY},C=function(e){switch(e){case"e":y+T.x>b&&(T.x=b-y);break;case"w":l+T.x<v&&(T.x=v-l);break;case"n":f+T.y<g&&(T.y=g-f);break;case"s":m+T.y>w&&(T.y=w-m)}};switch(c){case"all":l+=T.x,f+=T.y;break;case"e":if(T.x>=0&&(y>=b||u&&(f<=g||m>=w))){_=!1;break}C("e"),(p+=T.x)<0&&(c="w",l-=p=-p),u&&(h=p/u,f+=(a.height-h)/2);break;case"n":if(T.y<=0&&(f<=g||u&&(l<=v||y>=b))){_=!1;break}C("n"),h-=T.y,f+=T.y,h<0&&(c="s",f-=h=-h),u&&(p=h*u,l+=(a.width-p)/2);break;case"w":if(T.x<=0&&(l<=v||u&&(f<=g||m>=w))){_=!1;break}C("w"),p-=T.x,l+=T.x,p<0&&(c="e",l-=p=-p),u&&(h=p/u,f+=(a.height-h)/2);break;case"s":if(T.y>=0&&(m>=w||u&&(l<=v||y>=b))){_=!1;break}C("s"),(h+=T.y)<0&&(c="n",f-=h=-h),u&&(p=h*u,l+=(a.width-p)/2);break;case"ne":if(u){if(T.y<=0&&(f<=g||y>=b)){_=!1;break}C("n"),h-=T.y,f+=T.y,p=h*u}else C("n"),C("e"),T.x>=0?y<b?p+=T.x:T.y<=0&&f<=g&&(_=!1):p+=T.x,T.y<=0?f>g&&(h-=T.y,f+=T.y):(h-=T.y,f+=T.y);p<0&&h<0?(c="sw",f-=h=-h,l-=p=-p):p<0?(c="nw",l-=p=-p):h<0&&(c="se",f-=h=-h);break;case"nw":if(u){if(T.y<=0&&(f<=g||l<=v)){_=!1;break}C("n"),h-=T.y,f+=T.y,p=h*u,l+=a.width-p}else C("n"),C("w"),T.x<=0?l>v?(p-=T.x,l+=T.x):T.y<=0&&f<=g&&(_=!1):(p-=T.x,l+=T.x),T.y<=0?f>g&&(h-=T.y,f+=T.y):(h-=T.y,f+=T.y);p<0&&h<0?(c="se",f-=h=-h,l-=p=-p):p<0?(c="ne",l-=p=-p):h<0&&(c="sw",f-=h=-h);break;case"sw":if(u){if(T.x<=0&&(l<=v||m>=w)){_=!1;break}C("w"),p-=T.x,l+=T.x,h=p/u}else C("s"),C("w"),T.x<=0?l>v?(p-=T.x,l+=T.x):T.y>=0&&m>=w&&(_=!1):(p-=T.x,l+=T.x),T.y>=0?m<w&&(h+=T.y):h+=T.y;p<0&&h<0?(c="ne",f-=h=-h,l-=p=-p):p<0?(c="se",l-=p=-p):h<0&&(c="nw",f-=h=-h);break;case"se":if(u){if(T.x>=0&&(y>=b||m>=w)){_=!1;break}C("e"),h=(p+=T.x)/u}else C("s"),C("e"),T.x>=0?y<b?p+=T.x:T.y>=0&&m>=w&&(_=!1):p+=T.x,T.y>=0?m<w&&(h+=T.y):h+=T.y;p<0&&h<0?(c="nw",f-=h=-h,l-=p=-p):p<0?(c="sw",l-=p=-p):h<0&&(c="ne",f-=h=-h);break;case"move":this.move(T.x,T.y),_=!1;break;case"zoom":this.zoom(function(e){var t=o({},e),n=[];return F(e,(function(e,r){delete t[r],F(t,(function(t){var r=Math.abs(e.startX-t.startX),i=Math.abs(e.startY-t.startY),o=Math.abs(e.endX-t.endX),a=Math.abs(e.endY-t.endY),s=Math.sqrt(r*r+i*i),c=(Math.sqrt(o*o+a*a)-s)/s;n.push(c)}))})),n.sort((function(e,t){return Math.abs(e)<Math.abs(t)})),n[0]}(s),e),_=!1;break;case"crop":if(!T.x||!T.y){_=!1;break}t=oe(this.cropper),l=S.startX-t.left,f=S.startY-t.top,p=a.minWidth,h=a.minHeight,T.x>0?c=T.y>0?"se":"ne":T.x<0&&(l-=p,c=T.y>0?"sw":"nw"),T.y<0&&(f-=h),this.cropped||(Y(this.cropBox,d),this.cropped=!0,this.limited&&this.limitCropBox(!0,!0))}_&&(a.width=p,a.height=h,a.left=l,a.top=f,this.action=c,this.renderCropBox()),F(s,(function(e){e.startX=e.endX,e.startY=e.endY}))}},Se={crop:function(){return!this.ready||this.cropped||this.disabled||(this.cropped=!0,this.limitCropBox(!0,!0),this.options.modal&&K(this.dragBox,m),Y(this.cropBox,d),this.setCropBoxData(this.initialCropBoxData)),this},reset:function(){return this.ready&&!this.disabled&&(this.imageData=H({},this.initialImageData),this.canvasData=H({},this.initialCanvasData),this.cropBoxData=H({},this.initialCropBoxData),this.renderCanvas(),this.cropped&&this.renderCropBox()),this},clear:function(){return this.cropped&&!this.disabled&&(H(this.cropBoxData,{left:0,top:0,width:0,height:0}),this.cropped=!1,this.renderCropBox(),this.limitCanvas(!0,!0),this.renderCanvas(),Y(this.dragBox,m),K(this.cropBox,d)),this},replace:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return!this.disabled&&e&&(this.isImg&&(this.element.src=e),t?(this.url=e,this.image.src=e,this.ready&&(this.viewBoxImage.src=e,F(this.previews,(function(t){t.getElementsByTagName("img")[0].src=e})))):(this.isImg&&(this.replaced=!0),this.options.data=null,this.uncreate(),this.load(e))),this},enable:function(){return this.ready&&this.disabled&&(this.disabled=!1,Y(this.cropper,p)),this},disable:function(){return this.ready&&!this.disabled&&(this.disabled=!0,K(this.cropper,p)),this},destroy:function(){var e=this.element;return e.cropper?(e.cropper=void 0,this.isImg&&this.replaced&&(e.src=this.originalUrl),this.uncreate(),this):this},move:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e,n=this.canvasData,r=n.left,i=n.top;return this.moveTo(j(e)?e:r+Number(e),j(t)?t:i+Number(t))},moveTo:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e,n=this.canvasData,r=!1;return e=Number(e),t=Number(t),this.ready&&!this.disabled&&this.options.movable&&(R(e)&&(n.left=e,r=!0),R(t)&&(n.top=t,r=!0),r&&this.renderCanvas(!0)),this},zoom:function(e,t){var n=this.canvasData;return e=(e=Number(e))<0?1/(1-e):1+e,this.zoomTo(n.width*e/n.naturalWidth,null,t)},zoomTo:function(e,t,n){var r=this.options,i=this.canvasData,o=i.width,a=i.height,s=i.naturalWidth,c=i.naturalHeight;if((e=Number(e))>=0&&this.ready&&!this.disabled&&r.zoomable){var u=s*e,l=c*e;if(!1===ie(this.element,"zoom",{ratio:e,oldRatio:o/s,originalEvent:n}))return this;if(n){var f=this.pointers,p=oe(this.cropper),d=f&&Object.keys(f).length?function(e){var t=0,n=0,r=0;return F(e,(function(e){var i=e.startX,o=e.startY;t+=i,n+=o,r+=1})),{pageX:t/=r,pageY:n/=r}}(f):{pageX:n.pageX,pageY:n.pageY};i.left-=(u-o)*((d.pageX-p.left-i.left)/o),i.top-=(l-a)*((d.pageY-p.top-i.top)/a)}else B(t)&&R(t.x)&&R(t.y)?(i.left-=(u-o)*((t.x-i.left)/o),i.top-=(l-a)*((t.y-i.top)/a)):(i.left-=(u-o)/2,i.top-=(l-a)/2);i.width=u,i.height=l,this.renderCanvas(!0)}return this},rotate:function(e){return this.rotateTo((this.imageData.rotate||0)+Number(e))},rotateTo:function(e){return R(e=Number(e))&&this.ready&&!this.disabled&&this.options.rotatable&&(this.imageData.rotate=e%360,this.renderCanvas(!0,!0)),this},scaleX:function(e){var t=this.imageData.scaleY;return this.scale(e,R(t)?t:1)},scaleY:function(e){var t=this.imageData.scaleX;return this.scale(R(t)?t:1,e)},scale:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e,n=this.imageData,r=!1;return e=Number(e),t=Number(t),this.ready&&!this.disabled&&this.options.scalable&&(R(e)&&(n.scaleX=e,r=!0),R(t)&&(n.scaleY=t,r=!0),r&&this.renderCanvas(!0,!0)),this},getData:function(){var e,t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],n=this.options,r=this.imageData,i=this.canvasData,o=this.cropBoxData;if(this.ready&&this.cropped){e={x:o.left-i.left,y:o.top-i.top,width:o.width,height:o.height};var a=r.width/r.naturalWidth;if(F(e,(function(t,n){e[n]=t/a})),t){var s=Math.round(e.y+e.height),c=Math.round(e.x+e.width);e.x=Math.round(e.x),e.y=Math.round(e.y),e.width=c-e.x,e.height=s-e.y}}else e={x:0,y:0,width:0,height:0};return n.rotatable&&(e.rotate=r.rotate||0),n.scalable&&(e.scaleX=r.scaleX||1,e.scaleY=r.scaleY||1),e},setData:function(e){var t=this.options,n=this.imageData,r=this.canvasData,i={};if(this.ready&&!this.disabled&&B(e)){var o=!1;t.rotatable&&R(e.rotate)&&e.rotate!==n.rotate&&(n.rotate=e.rotate,o=!0),t.scalable&&(R(e.scaleX)&&e.scaleX!==n.scaleX&&(n.scaleX=e.scaleX,o=!0),R(e.scaleY)&&e.scaleY!==n.scaleY&&(n.scaleY=e.scaleY,o=!0)),o&&this.renderCanvas(!0,!0);var a=n.width/n.naturalWidth;R(e.x)&&(i.left=e.x*a+r.left),R(e.y)&&(i.top=e.y*a+r.top),R(e.width)&&(i.width=e.width*a),R(e.height)&&(i.height=e.height*a),this.setCropBoxData(i)}return this},getContainerData:function(){return this.ready?H({},this.containerData):{}},getImageData:function(){return this.sized?H({},this.imageData):{}},getCanvasData:function(){var e=this.canvasData,t={};return this.ready&&F(["left","top","width","height","naturalWidth","naturalHeight"],(function(n){t[n]=e[n]})),t},setCanvasData:function(e){var t=this.canvasData,n=t.aspectRatio;return this.ready&&!this.disabled&&B(e)&&(R(e.left)&&(t.left=e.left),R(e.top)&&(t.top=e.top),R(e.width)?(t.width=e.width,t.height=e.width/n):R(e.height)&&(t.height=e.height,t.width=e.height*n),this.renderCanvas(!0)),this},getCropBoxData:function(){var e,t=this.cropBoxData;return this.ready&&this.cropped&&(e={left:t.left,top:t.top,width:t.width,height:t.height}),e||{}},setCropBoxData:function(e){var t,n,r=this.cropBoxData,i=this.options.aspectRatio;return this.ready&&this.cropped&&!this.disabled&&B(e)&&(R(e.left)&&(r.left=e.left),R(e.top)&&(r.top=e.top),R(e.width)&&e.width!==r.width&&(t=!0,r.width=e.width),R(e.height)&&e.height!==r.height&&(n=!0,r.height=e.height),i&&(t?r.height=r.width/i:n&&(r.width=r.height*i)),this.renderCropBox()),this},getCroppedCanvas:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(!this.ready||!window.HTMLCanvasElement)return null;var t=this.canvasData,n=de(this.image,this.imageData,t,e);if(!this.cropped)return n;var r=this.getData(),i=r.x,o=r.y,s=r.width,c=r.height,u=n.width/Math.floor(t.naturalWidth);1!==u&&(i*=u,o*=u,s*=u,c*=u);var l=s/c,f=pe({aspectRatio:l,width:e.maxWidth||1/0,height:e.maxHeight||1/0}),p=pe({aspectRatio:l,width:e.minWidth||0,height:e.minHeight||0},"cover"),d=pe({aspectRatio:l,width:e.width||(1!==u?n.width:s),height:e.height||(1!==u?n.height:c)}),h=d.width,y=d.height;h=Math.min(f.width,Math.max(p.width,h)),y=Math.min(f.height,Math.max(p.height,y));var m=document.createElement("canvas"),v=m.getContext("2d");m.width=W(h),m.height=W(y),v.fillStyle=e.fillColor||"transparent",v.fillRect(0,0,h,y);var g=e.imageSmoothingEnabled,b=void 0===g||g,w=e.imageSmoothingQuality;v.imageSmoothingEnabled=b,w&&(v.imageSmoothingQuality=w);var _,S,T,C,E,k,O=n.width,P=n.height,A=i,I=o;A<=-s||A>O?(A=0,_=0,T=0,E=0):A<=0?(T=-A,A=0,E=_=Math.min(O,s+A)):A<=O&&(T=0,E=_=Math.min(s,O-A)),_<=0||I<=-c||I>P?(I=0,S=0,C=0,k=0):I<=0?(C=-I,I=0,k=S=Math.min(P,c+I)):I<=P&&(C=0,k=S=Math.min(c,P-I));var x=[A,I,_,S];if(E>0&&k>0){var R=h/s;x.push(T*R,C*R,E*R,k*R)}return v.drawImage.apply(v,[n].concat(a(x.map((function(e){return Math.floor(W(e))}))))),m},setAspectRatio:function(e){var t=this.options;return this.disabled||j(e)||(t.aspectRatio=Math.max(0,e)||NaN,this.ready&&(this.initCropBox(),this.cropped&&this.renderCropBox())),this},setDragMode:function(e){var t=this.options,n=this.dragBox,r=this.face;if(this.ready&&!this.disabled){var i="crop"===e,o=t.movable&&"move"===e;e=i||o?e:"none",t.dragMode=e,J(n,g,e),X(n,f,i),X(n,v,o),t.cropBoxMovable||(J(r,g,e),X(r,f,i),X(r,v,o))}return this}},Te=c.Cropper,Ce=function(){function e(n){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(t(this,e),!n||!A.test(n.tagName))throw new Error("The first argument is required and must be an <img> or <canvas> element.");this.element=n,this.options=H({},I,B(r)&&r),this.cropped=!1,this.disabled=!1,this.pointers={},this.ready=!1,this.reloading=!1,this.replaced=!1,this.sized=!1,this.sizing=!1,this.init()}var r,i,o;return r=e,o=[{key:"noConflict",value:function(){return window.Cropper=Te,e}},{key:"setDefaults",value:function(e){H(I,B(e)&&e)}}],(i=[{key:"init",value:function(){var e,t=this.element,n=t.tagName.toLowerCase();if(!t.cropper){if(t.cropper=this,"img"===n){if(this.isImg=!0,e=t.getAttribute("src")||"",this.originalUrl=e,!e)return;e=t.src}else"canvas"===n&&window.HTMLCanvasElement&&(e=t.toDataURL());this.load(e)}}},{key:"load",value:function(e){var t=this;if(e){this.url=e,this.imageData={};var n=this.element,r=this.options;if(r.rotatable||r.scalable||(r.checkOrientation=!1),r.checkOrientation&&window.ArrayBuffer)if(O.test(e))P.test(e)?this.read((i=e.replace(ye,""),o=atob(i),a=new ArrayBuffer(o.length),F(s=new Uint8Array(a),(function(e,t){s[t]=o.charCodeAt(t)})),a)):this.clone();else{var i,o,a,s,c=new XMLHttpRequest,u=this.clone.bind(this);this.reloading=!0,this.xhr=c,c.onabort=u,c.onerror=u,c.ontimeout=u,c.onprogress=function(){"image/jpeg"!==c.getResponseHeader("content-type")&&c.abort()},c.onload=function(){t.read(c.response)},c.onloadend=function(){t.reloading=!1,t.xhr=null},r.checkCrossOrigin&&ce(e)&&n.crossOrigin&&(e=ue(e)),c.open("GET",e),c.responseType="arraybuffer",c.withCredentials="use-credentials"===n.crossOrigin,c.send()}else this.clone()}}},{key:"read",value:function(e){var t=this.options,n=this.imageData,r=me(e),i=0,o=1,a=1;if(r>1){this.url=function(e,t){for(var n=[],r=new Uint8Array(e);r.length>0;)n.push(he.apply(null,V(r.subarray(0,8192)))),r=r.subarray(8192);return"data:".concat(t,";base64,").concat(btoa(n.join("")))}(e,"image/jpeg");var s=function(e){var t=0,n=1,r=1;switch(e){case 2:n=-1;break;case 3:t=-180;break;case 4:r=-1;break;case 5:t=90,r=-1;break;case 6:t=90;break;case 7:t=90,n=-1;break;case 8:t=-90}return{rotate:t,scaleX:n,scaleY:r}}(r);i=s.rotate,o=s.scaleX,a=s.scaleY}t.rotatable&&(n.rotate=i),t.scalable&&(n.scaleX=o,n.scaleY=a),this.clone()}},{key:"clone",value:function(){var e=this.element,t=this.url,n=e.crossOrigin,r=t;this.options.checkCrossOrigin&&ce(t)&&(n||(n="anonymous"),r=ue(t)),this.crossOrigin=n,this.crossOriginUrl=r;var i=document.createElement("img");n&&(i.crossOrigin=n),i.src=r||t,i.alt=e.alt||"The image to crop",this.image=i,i.onload=this.start.bind(this),i.onerror=this.stop.bind(this),K(i,h),e.parentNode.insertBefore(i,e.nextSibling)}},{key:"start",value:function(){var e=this,t=this.image;t.onload=null,t.onerror=null,this.sizing=!0;var n=c.navigator&&/(?:iPad|iPhone|iPod).*?AppleWebKit/i.test(c.navigator.userAgent),r=function(t,n){H(e.imageData,{naturalWidth:t,naturalHeight:n,aspectRatio:t/n}),e.sizing=!1,e.sized=!0,e.build()};if(!t.naturalWidth||n){var i=document.createElement("img"),o=document.body||document.documentElement;this.sizingImage=i,i.onload=function(){r(i.width,i.height),n||o.removeChild(i)},i.src=t.src,n||(i.style.cssText="left:0;max-height:none!important;max-width:none!important;min-height:0!important;min-width:0!important;opacity:0;position:absolute;top:0;z-index:-1;",o.appendChild(i))}else r(t.naturalWidth,t.naturalHeight)}},{key:"stop",value:function(){var e=this.image;e.onload=null,e.onerror=null,e.parentNode.removeChild(e),this.image=null}},{key:"build",value:function(){if(this.sized&&!this.ready){var e=this.element,t=this.options,n=this.image,r=e.parentNode,i=document.createElement("div");i.innerHTML='<div class="cropper-container" touch-action="none"><div class="cropper-wrap-box"><div class="cropper-canvas"></div></div><div class="cropper-drag-box"></div><div class="cropper-crop-box"><span class="cropper-view-box"></span><span class="cropper-dashed dashed-h"></span><span class="cropper-dashed dashed-v"></span><span class="cropper-center"></span><span class="cropper-face"></span><span class="cropper-line line-e" data-cropper-action="e"></span><span class="cropper-line line-n" data-cropper-action="n"></span><span class="cropper-line line-w" data-cropper-action="w"></span><span class="cropper-line line-s" data-cropper-action="s"></span><span class="cropper-point point-e" data-cropper-action="e"></span><span class="cropper-point point-n" data-cropper-action="n"></span><span class="cropper-point point-w" data-cropper-action="w"></span><span class="cropper-point point-s" data-cropper-action="s"></span><span class="cropper-point point-ne" data-cropper-action="ne"></span><span class="cropper-point point-nw" data-cropper-action="nw"></span><span class="cropper-point point-sw" data-cropper-action="sw"></span><span class="cropper-point point-se" data-cropper-action="se"></span></div></div>';var o=i.querySelector(".".concat("cropper","-container")),a=o.querySelector(".".concat("cropper","-canvas")),s=o.querySelector(".".concat("cropper","-drag-box")),c=o.querySelector(".".concat("cropper","-crop-box")),u=c.querySelector(".".concat("cropper","-face"));this.container=r,this.cropper=o,this.canvas=a,this.dragBox=s,this.cropBox=c,this.viewBox=o.querySelector(".".concat("cropper","-view-box")),this.face=u,a.appendChild(n),K(e,d),r.insertBefore(o,e.nextSibling),this.isImg||Y(n,h),this.initPreview(),this.bind(),t.initialAspectRatio=Math.max(0,t.initialAspectRatio)||NaN,t.aspectRatio=Math.max(0,t.aspectRatio)||NaN,t.viewMode=Math.max(0,Math.min(3,Math.round(t.viewMode)))||0,K(c,d),t.guides||K(c.getElementsByClassName("".concat("cropper","-dashed")),d),t.center||K(c.getElementsByClassName("".concat("cropper","-center")),d),t.background&&K(o,"".concat("cropper","-bg")),t.highlight||K(u,y),t.cropBoxMovable&&(K(u,v),J(u,g,"all")),t.cropBoxResizable||(K(c.getElementsByClassName("".concat("cropper","-line")),d),K(c.getElementsByClassName("".concat("cropper","-point")),d)),this.render(),this.ready=!0,this.setDragMode(t.dragMode),t.autoCrop&&this.crop(),this.setData(t.data),U(t.ready)&&re(e,"ready",t.ready,{once:!0}),ie(e,"ready")}}},{key:"unbuild",value:function(){this.ready&&(this.ready=!1,this.unbind(),this.resetPreview(),this.cropper.parentNode.removeChild(this.cropper),Y(this.element,d))}},{key:"uncreate",value:function(){this.ready?(this.unbuild(),this.ready=!1,this.cropped=!1):this.sizing?(this.sizingImage.onload=null,this.sizing=!1,this.sized=!1):this.reloading?(this.xhr.onabort=null,this.xhr.abort()):this.image&&this.stop()}}])&&n(r.prototype,i),o&&n(r,o),e}();return H(Ce.prototype,ve,ge,be,we,_e,Se),Ce}()},function(e,t,n){var r=n(121);e.exports=(r.default||r).template({1:function(e,t,n,r,i){e.propertyIsEnumerable;var o,a=e.lambda,s=e.escapeExpression;return'<span class="badge badge-danger badge-pill '+s(a(null!=(o=null!=(o=null!=t?t.options:t)?o.styles:o)?o.unreadCount:o,t))+'">'+s(a(null!=(o=null!=t?t.options:t)?o.unreadCount:o,t))+"</span>\r\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){var o;e.propertyIsEnumerable;return(null!=(o=e.lambda(null!=(o=null!=t?t.options:t)?o.svg:o,t))?o:"")+"\r\n"+(null!=(o=n.if.call(null!=t?t:e.nullContext||{},null!=(o=null!=t?t.options:t)?o.unreadCount:o,{name:"if",hash:{},fn:e.program(1,i,0),inverse:e.noop,data:i}))?o:"")},useData:!0})},function(e,t,n){var r=n(121);e.exports=(r.default||r).template({1:function(e,t,n,r,i){var o;e.propertyIsEnumerable;return'<h4 class="mt-3 text-muted">'+e.escapeExpression(e.lambda(null!=(o=null!=t?t.options:t)?o.heading:o,t))+"</h4>\r\n"},3:function(e,t,n,r,i){var o;e.propertyIsEnumerable;return"<p>"+(null!=(o=e.lambda(null!=(o=null!=t?t.options:t)?o.description:o,t))?o:"")+"</p>\r\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){e.propertyIsEnumerable;var o,a=e.lambda,s=e.escapeExpression,c=null!=t?t:e.nullContext||{};return'<img src="'+s(a(null!=(o=null!=t?t.options:t)?o.imageUrl:o,t))+'" class="'+s(a(null!=(o=null!=t?t.options:t)?o.imageClass:o,t))+'"/>\r\n'+(null!=(o=n.if.call(c,null!=(o=null!=t?t.options:t)?o.heading:o,{name:"if",hash:{},fn:e.program(1,i,0),inverse:e.noop,data:i}))?o:"")+(null!=(o=n.if.call(c,null!=(o=null!=t?t.options:t)?o.description:o,{name:"if",hash:{},fn:e.program(3,i,0),inverse:e.noop,data:i}))?o:"")},useData:!0})},function(e,t,n){var r=n(121);e.exports=(r.default||r).template({1:function(e,t,n,r,i){e.propertyIsEnumerable;var o,a=e.lambda,s=e.escapeExpression;return' <span class="text-right pl-2 '+s(a(null!=(o=null!=(o=null!=t?t.options:t)?o.styles:o)?o.actionText:o,t))+'">'+s(a(null!=(o=null!=t?t.options:t)?o.actionText:o,t))+"</span>\r\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){e.propertyIsEnumerable;var o,a=e.lambda,s=e.escapeExpression;return'<div class="'+s(a(null!=(o=null!=(o=null!=t?t.options:t)?o.styles:o)?o.icon:o,t))+" "+s(a(null!=(o=null!=t?t.options:t)?o.iconClass:o,t))+'">'+(null!=(o=a(null!=(o=null!=t?t.options:t)?o.icon:o,t))?o:"")+'</div><div class="'+s(a(null!=(o=null!=(o=null!=t?t.options:t)?o.styles:o)?o.contentContainer:o,t))+'">\r\n <div class="clamp-2 pl-1">'+s(a(null!=(o=null!=t?t.options:t)?o.content:o,t))+"</div>\r\n"+(null!=(o=n.if.call(null!=t?t:e.nullContext||{},null!=(o=null!=t?t.options:t)?o.showActionText:o,{name:"if",hash:{},fn:e.program(1,i,0),inverse:e.noop,data:i}))?o:"")+' <div class="'+s(a(null!=(o=null!=(o=null!=t?t.options:t)?o.styles:o)?o.notificationTime:o,t))+' pl-1">'+s(a(null!=(o=null!=t?t.options:t)?o.notificationTime:o,t))+"</div>\r\n</div>"},useData:!0})},function(e,t,n){var r=n(121);e.exports=(r.default||r).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){return'<div class="notifications-region"></div>'},useData:!0})},function(e,t,n){var r=n(121);e.exports=(r.default||r).template({1:function(e,t,n,r,i){e.propertyIsEnumerable;return'<div class="py-2 border-top text-right px-2">\r\n <a class="see-all">'+e.escapeExpression((n.lang||t&&t.lang||e.hooks.helperMissing).call(null!=t?t:e.nullContext||{},"seeAll",{name:"lang",hash:{},data:i}))+"</div>\r\n</div>\r\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){e.propertyIsEnumerable;var o,a=null!=t?t:e.nullContext||{};return'<h5 class="header p-2 m-0 border-bottom">'+e.escapeExpression((n.lang||t&&t.lang||e.hooks.helperMissing).call(a,"notifications",{name:"lang",hash:{},data:i}))+'</h5>\r\n<div class="list-region"></div>\r\n'+(null!=(o=n.if.call(a,null!=(o=null!=t?t.options:t)?o.hasNotifications:o,{name:"if",hash:{},fn:e.program(1,i,0),inverse:e.noop,data:i}))?o:"")},useData:!0})},function(e,t,n){var r=n(121);e.exports=(r.default||r).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){var o;e.propertyIsEnumerable;return'<div id="notificationsDropdown" class="notifications-status-region" data-toggle="dropdown"></div>\r\n<div aria-labelledby="notificationsDropdown" class="notifications-region dropdown-menu dropdown-menu-right dropdown-arrow p-0 '+e.escapeExpression(e.lambda(null!=(o=null!=t?t.options:t)?o.notificationsContainer:o,t))+'"></div>'},useData:!0})},function(e,t,n){e.exports={avatar:"_1XSQR"}},function(e,t,n){"use strict";var r=n(542);n.o(r,"PlaylistVideoCollectionIdentifier")&&n.d(t,"PlaylistVideoCollectionIdentifier",(function(){return r.PlaylistVideoCollectionIdentifier}));var i=n(728);n.d(t,"PlaylistVideoCollectionIdentifier",(function(){return i.a}))},function(e,t,n){"use strict";var r=n(546);n.o(r,"MicrosoftTeamsProduct")&&n.d(t,"MicrosoftTeamsProduct",(function(){return r.MicrosoftTeamsProduct}));var i=n(547);n.d(t,"MicrosoftTeamsProduct",(function(){return i.a}));n(548)},function(e,t,n){e.exports={radioFilter:"vo-iA"}},function(e,t){e.exports=function(e,t){var n,r=null;try{n=JSON.parse(e,t)}catch(e){r=e}return[r,n]}},function(e,t,n){var r=n(329),i=n(786);function o(t,n,a){return i()?(e.exports=o=Reflect.construct,e.exports.default=e.exports,e.exports.__esModule=!0):(e.exports=o=function(e,t,n){var i=[null];i.push.apply(i,t);var o=new(Function.bind.apply(e,i));return n&&r(o,n.prototype),o},e.exports.default=e.exports,e.exports.__esModule=!0),o.apply(null,arguments)}e.exports=o,e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){var r=n(329);e.exports=function(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}}),t&&r(e,t)},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){function r(e){this.options=e||{locator:{}}}function i(){this.cdata=!1}function o(e,t){t.lineNumber=e.lineNumber,t.columnNumber=e.columnNumber}function a(e){if(e)return"\n@"+(e.systemId||"")+"#[line:"+e.lineNumber+",col:"+e.columnNumber+"]"}function s(e,t,n){return"string"==typeof e?e.substr(t,n):e.length>=t+n||t?new java.lang.String(e,t,n)+"":e}function c(e,t){e.currentElement?e.currentElement.appendChild(t):e.doc.appendChild(t)}r.prototype.parseFromString=function(e,t){var n=this.options,r=new u,o=n.domBuilder||new i,s=n.errorHandler,c=n.locator,l=n.xmlns||{},f={lt:"<",gt:">",amp:"&",quot:'"',apos:"'"};return c&&o.setDocumentLocator(c),r.errorHandler=function(e,t,n){if(!e){if(t instanceof i)return t;e=t}var r={},o=e instanceof Function;function s(t){var i=e[t];!i&&o&&(i=2==e.length?function(n){e(t,n)}:e),r[t]=i&&function(e){i("[xmldom "+t+"]\t"+e+a(n))}||function(){}}return n=n||{},s("warning"),s("error"),s("fatalError"),r}(s,o,c),r.domBuilder=n.domBuilder||o,/\/x?html?$/.test(t)&&(f.nbsp=" ",f.copy="©",l[""]="http://www.w3.org/1999/xhtml"),l.xml=l.xml||"http://www.w3.org/XML/1998/namespace",e?r.parse(e,l,f):r.errorHandler.error("invalid doc source"),o.doc},i.prototype={startDocument:function(){this.doc=(new l).createDocument(null,null,null),this.locator&&(this.doc.documentURI=this.locator.systemId)},startElement:function(e,t,n,r){var i=this.doc,a=i.createElementNS(e,n||t),s=r.length;c(this,a),this.currentElement=a,this.locator&&o(this.locator,a);for(var u=0;u<s;u++){e=r.getURI(u);var l=r.getValue(u),f=(n=r.getQName(u),i.createAttributeNS(e,n));this.locator&&o(r.getLocator(u),f),f.value=f.nodeValue=l,a.setAttributeNode(f)}},endElement:function(e,t,n){var r=this.currentElement;r.tagName;this.currentElement=r.parentNode},startPrefixMapping:function(e,t){},endPrefixMapping:function(e){},processingInstruction:function(e,t){var n=this.doc.createProcessingInstruction(e,t);this.locator&&o(this.locator,n),c(this,n)},ignorableWhitespace:function(e,t,n){},characters:function(e,t,n){if(e=s.apply(this,arguments)){if(this.cdata)var r=this.doc.createCDATASection(e);else r=this.doc.createTextNode(e);this.currentElement?this.currentElement.appendChild(r):/^\s*$/.test(e)&&this.doc.appendChild(r),this.locator&&o(this.locator,r)}},skippedEntity:function(e){},endDocument:function(){this.doc.normalize()},setDocumentLocator:function(e){(this.locator=e)&&(e.lineNumber=0)},comment:function(e,t,n){e=s.apply(this,arguments);var r=this.doc.createComment(e);this.locator&&o(this.locator,r),c(this,r)},startCDATA:function(){this.cdata=!0},endCDATA:function(){this.cdata=!1},startDTD:function(e,t,n){var r=this.doc.implementation;if(r&&r.createDocumentType){var i=r.createDocumentType(e,t,n);this.locator&&o(this.locator,i),c(this,i)}},warning:function(e){console.warn("[xmldom warning]\t"+e,a(this.locator))},error:function(e){console.error("[xmldom error]\t"+e,a(this.locator))},fatalError:function(e){throw console.error("[xmldom fatalError]\t"+e,a(this.locator)),e}},"endDTD,startEntity,endEntity,attributeDecl,elementDecl,externalEntityDecl,internalEntityDecl,resolveEntity,getExternalSubset,notationDecl,unparsedEntityDecl".replace(/\w+/g,(function(e){i.prototype[e]=function(){return null}}));var u=n(791).XMLReader,l=t.DOMImplementation=n(551).DOMImplementation;t.XMLSerializer=n(551).XMLSerializer,t.DOMParser=r},function(e,t){var n=Math.pow(2,32);e.exports=function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength),r={version:e[0],flags:new Uint8Array(e.subarray(1,4)),references:[],referenceId:t.getUint32(4),timescale:t.getUint32(8)},i=12;0===r.version?(r.earliestPresentationTime=t.getUint32(i),r.firstOffset=t.getUint32(i+4),i+=8):(r.earliestPresentationTime=t.getUint32(i)*n+t.getUint32(i+4),r.firstOffset=t.getUint32(i+8)*n+t.getUint32(i+12),i+=16),i+=2;var o=t.getUint16(i);for(i+=2;o>0;i+=12,o--)r.references.push({referenceType:(128&e[i])>>>7,referencedSize:2147483647&t.getUint32(i),subsegmentDuration:t.getUint32(i+4),startsWithSap:!!(128&e[i+8]),sapType:(112&e[i+8])>>>4,sapDeltaTime:268435455&t.getUint32(i+8)});return r}},function(e,t,n){"use strict";var r=n(552),i=n(792).handleRollover,o={};o.ts=n(794),o.aac=n(795);var a=n(186).ONE_SECOND_IN_TS,s=function(e,t,n){for(var r,i,a,s,c=0,u=188,l=!1;u<=e.byteLength;)if(71!==e[c]||71!==e[u]&&u!==e.byteLength)c++,u++;else{switch(r=e.subarray(c,u),o.ts.parseType(r,t.pid)){case"pes":i=o.ts.parsePesType(r,t.table),a=o.ts.parsePayloadUnitStartIndicator(r),"audio"===i&&a&&(s=o.ts.parsePesTime(r))&&(s.type="audio",n.audio.push(s),l=!0)}if(l)break;c+=188,u+=188}for(c=(u=e.byteLength)-188,l=!1;c>=0;)if(71!==e[c]||71!==e[u]&&u!==e.byteLength)c--,u--;else{switch(r=e.subarray(c,u),o.ts.parseType(r,t.pid)){case"pes":i=o.ts.parsePesType(r,t.table),a=o.ts.parsePayloadUnitStartIndicator(r),"audio"===i&&a&&(s=o.ts.parsePesTime(r))&&(s.type="audio",n.audio.push(s),l=!0)}if(l)break;c-=188,u-=188}},c=function(e,t,n){for(var r,i,a,s,c,u,l,f=0,p=188,d=!1,h={data:[],size:0};p<e.byteLength;)if(71!==e[f]||71!==e[p])f++,p++;else{switch(r=e.subarray(f,p),o.ts.parseType(r,t.pid)){case"pes":if(i=o.ts.parsePesType(r,t.table),a=o.ts.parsePayloadUnitStartIndicator(r),"video"===i&&(a&&!d&&(s=o.ts.parsePesTime(r))&&(s.type="video",n.video.push(s),d=!0),!n.firstKeyFrame)){if(a&&0!==h.size){for(c=new Uint8Array(h.size),u=0;h.data.length;)l=h.data.shift(),c.set(l,u),u+=l.byteLength;if(o.ts.videoPacketContainsKeyFrame(c)){var y=o.ts.parsePesTime(c);y?(n.firstKeyFrame=y,n.firstKeyFrame.type="video"):console.warn("Failed to extract PTS/DTS from PES at first keyframe. This could be an unusual TS segment, or else mux.js did not parse your TS segment correctly. If you know your TS segments do contain PTS/DTS on keyframes please file a bug report! You can try ffprobe to double check for yourself.")}h.size=0}h.data.push(r),h.size+=r.byteLength}}if(d&&n.firstKeyFrame)break;f+=188,p+=188}for(f=(p=e.byteLength)-188,d=!1;f>=0;)if(71!==e[f]||71!==e[p])f--,p--;else{switch(r=e.subarray(f,p),o.ts.parseType(r,t.pid)){case"pes":i=o.ts.parsePesType(r,t.table),a=o.ts.parsePayloadUnitStartIndicator(r),"video"===i&&a&&(s=o.ts.parsePesTime(r))&&(s.type="video",n.video.push(s),d=!0)}if(d)break;f-=188,p-=188}},u=function(e){var t={pid:null,table:null},n={};for(var i in function(e,t){for(var n,r=0,i=188;i<e.byteLength;)if(71!==e[r]||71!==e[i])r++,i++;else{switch(n=e.subarray(r,i),o.ts.parseType(n,t.pid)){case"pat":t.pid||(t.pid=o.ts.parsePat(n));break;case"pmt":t.table||(t.table=o.ts.parsePmt(n))}if(t.pid&&t.table)return;r+=188,i+=188}}(e,t),t.table){if(t.table.hasOwnProperty(i))switch(t.table[i]){case r.H264_STREAM_TYPE:n.video=[],c(e,t,n),0===n.video.length&&delete n.video;break;case r.ADTS_STREAM_TYPE:n.audio=[],s(e,t,n),0===n.audio.length&&delete n.audio}}return n};e.exports={inspect:function(e,t){var n;return(n=o.aac.isLikelyAacData(e)?function(e){for(var t,n=!1,r=0,i=null,s=null,c=0,u=0;e.length-u>=3;){switch(o.aac.parseType(e,u)){case"timed-metadata":if(e.length-u<10){n=!0;break}if((c=o.aac.parseId3TagSize(e,u))>e.length){n=!0;break}null===s&&(t=e.subarray(u,u+c),s=o.aac.parseAacTimestamp(t)),u+=c;break;case"audio":if(e.length-u<7){n=!0;break}if((c=o.aac.parseAdtsSize(e,u))>e.length){n=!0;break}null===i&&(t=e.subarray(u,u+c),i=o.aac.parseSampleRate(t)),r++,u+=c;break;default:u++}if(n)return null}if(null===i||null===s)return null;var l=a/i;return{audio:[{type:"audio",dts:s,pts:s},{type:"audio",dts:s+1024*r*l,pts:s+1024*r*l}]}}(e):u(e))&&(n.audio||n.video)?(function(e,t){if(e.audio&&e.audio.length){var n=t;void 0===n&&(n=e.audio[0].dts),e.audio.forEach((function(e){e.dts=i(e.dts,n),e.pts=i(e.pts,n),e.dtsTime=e.dts/a,e.ptsTime=e.pts/a}))}if(e.video&&e.video.length){var r=t;if(void 0===r&&(r=e.video[0].dts),e.video.forEach((function(e){e.dts=i(e.dts,r),e.pts=i(e.pts,r),e.dtsTime=e.dts/a,e.ptsTime=e.pts/a})),e.firstKeyFrame){var o=e.firstKeyFrame;o.dts=i(o.dts,r),o.pts=i(o.pts,r),o.dtsTime=o.dts/a,o.ptsTime=o.dts/a}}}(n,t),n):null},parseAudioPes_:s}},function(e){e.exports=JSON.parse('{"a":"0.0.20-dev.1"}')},function(e,t,n){e.exports=function(){"use strict";var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(t,n)},t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";function n(e,t,n,r){var i,o,a,s=t||[0],c=(n=n||0)>>>3,u=-1===r?3:0;for(i=0;i<e.length;i+=1)o=(a=i+c)>>>2,s.length<=o&&s.push(0),s[o]|=e[i]<<8*(u+r*(a%4));return{value:s,binLen:8*e.length+n}}function r(e,r,i){switch(r){case"UTF8":case"UTF16BE":case"UTF16LE":break;default:throw new Error("encoding must be UTF8, UTF16BE, or UTF16LE")}switch(e){case"HEX":return function(e,t,n){return function(e,t,n,r){var i,o,a,s;if(0!=e.length%2)throw new Error("String of HEX type must be in byte increments");var c=t||[0],u=(n=n||0)>>>3,l=-1===r?3:0;for(i=0;i<e.length;i+=2){if(o=parseInt(e.substr(i,2),16),isNaN(o))throw new Error("String of HEX type contains invalid characters");for(a=(s=(i>>>1)+u)>>>2;c.length<=a;)c.push(0);c[a]|=o<<8*(l+r*(s%4))}return{value:c,binLen:4*e.length+n}}(e,t,n,i)};case"TEXT":return function(e,t,n){return function(e,t,n,r,i){var o,a,s,c,u,l,f,p,d=0,h=n||[0],y=(r=r||0)>>>3;if("UTF8"===t)for(f=-1===i?3:0,s=0;s<e.length;s+=1)for(a=[],128>(o=e.charCodeAt(s))?a.push(o):2048>o?(a.push(192|o>>>6),a.push(128|63&o)):55296>o||57344<=o?a.push(224|o>>>12,128|o>>>6&63,128|63&o):(s+=1,o=65536+((1023&o)<<10|1023&e.charCodeAt(s)),a.push(240|o>>>18,128|o>>>12&63,128|o>>>6&63,128|63&o)),c=0;c<a.length;c+=1){for(u=(l=d+y)>>>2;h.length<=u;)h.push(0);h[u]|=a[c]<<8*(f+i*(l%4)),d+=1}else for(f=-1===i?2:0,p="UTF16LE"===t&&1!==i||"UTF16LE"!==t&&1===i,s=0;s<e.length;s+=1){for(o=e.charCodeAt(s),!0===p&&(o=(c=255&o)<<8|o>>>8),u=(l=d+y)>>>2;h.length<=u;)h.push(0);h[u]|=o<<8*(f+i*(l%4)),d+=2}return{value:h,binLen:8*d+r}}(e,r,t,n,i)};case"B64":return function(e,n,r){return function(e,n,r,i){var o,a,s,c,u,l,f=0,p=n||[0],d=(r=r||0)>>>3,h=-1===i?3:0,y=e.indexOf("=");if(-1===e.search(/^[a-zA-Z0-9=+/]+$/))throw new Error("Invalid character in base-64 string");if(e=e.replace(/=/g,""),-1!==y&&y<e.length)throw new Error("Invalid '=' found in base-64 string");for(o=0;o<e.length;o+=4){for(c=e.substr(o,4),s=0,a=0;a<c.length;a+=1)s|=t.indexOf(c.charAt(a))<<18-6*a;for(a=0;a<c.length-1;a+=1){for(u=(l=f+d)>>>2;p.length<=u;)p.push(0);p[u]|=(s>>>16-8*a&255)<<8*(h+i*(l%4)),f+=1}}return{value:p,binLen:8*f+r}}(e,n,r,i)};case"BYTES":return function(e,t,n){return function(e,t,n,r){var i,o,a,s,c=t||[0],u=(n=n||0)>>>3,l=-1===r?3:0;for(o=0;o<e.length;o+=1)i=e.charCodeAt(o),a=(s=o+u)>>>2,c.length<=a&&c.push(0),c[a]|=i<<8*(l+r*(s%4));return{value:c,binLen:8*e.length+n}}(e,t,n,i)};case"ARRAYBUFFER":try{new ArrayBuffer(0)}catch(e){throw new Error("ARRAYBUFFER not supported by this environment")}return function(e,t,r){return function(e,t,r,i){return n(new Uint8Array(e),t,r,i)}(e,t,r,i)};case"UINT8ARRAY":try{new Uint8Array(0)}catch(e){throw new Error("UINT8ARRAY not supported by this environment")}return function(e,t,r){return n(e,t,r,i)};default:throw new Error("format must be HEX, TEXT, B64, BYTES, ARRAYBUFFER, or UINT8ARRAY")}}function i(e,n,r,i){switch(e){case"HEX":return function(e){return function(e,t,n,r){var i,o,a="",s=t/8,c=-1===n?3:0;for(i=0;i<s;i+=1)o=e[i>>>2]>>>8*(c+n*(i%4)),a+="0123456789abcdef".charAt(o>>>4&15)+"0123456789abcdef".charAt(15&o);return r.outputUpper?a.toUpperCase():a}(e,n,r,i)};case"B64":return function(e){return function(e,n,r,i){var o,a,s,c,u,l="",f=n/8,p=-1===r?3:0;for(o=0;o<f;o+=3)for(c=o+1<f?e[o+1>>>2]:0,u=o+2<f?e[o+2>>>2]:0,s=(e[o>>>2]>>>8*(p+r*(o%4))&255)<<16|(c>>>8*(p+r*((o+1)%4))&255)<<8|u>>>8*(p+r*((o+2)%4))&255,a=0;a<4;a+=1)l+=8*o+6*a<=n?t.charAt(s>>>6*(3-a)&63):i.b64Pad;return l}(e,n,r,i)};case"BYTES":return function(e){return function(e,t,n){var r,i,o="",a=t/8,s=-1===n?3:0;for(r=0;r<a;r+=1)i=e[r>>>2]>>>8*(s+n*(r%4))&255,o+=String.fromCharCode(i);return o}(e,n,r)};case"ARRAYBUFFER":try{new ArrayBuffer(0)}catch(e){throw new Error("ARRAYBUFFER not supported by this environment")}return function(e){return function(e,t,n){var r,i=t/8,o=new ArrayBuffer(i),a=new Uint8Array(o),s=-1===n?3:0;for(r=0;r<i;r+=1)a[r]=e[r>>>2]>>>8*(s+n*(r%4))&255;return o}(e,n,r)};case"UINT8ARRAY":try{new Uint8Array(0)}catch(e){throw new Error("UINT8ARRAY not supported by this environment")}return function(e){return function(e,t,n){var r,i=t/8,o=-1===n?3:0,a=new Uint8Array(i);for(r=0;r<i;r+=1)a[r]=e[r>>>2]>>>8*(o+n*(r%4))&255;return a}(e,n,r)};default:throw new Error("format must be HEX, B64, BYTES, ARRAYBUFFER, or UINT8ARRAY")}}function o(e){var t={outputUpper:!1,b64Pad:"=",outputLen:-1},n=e||{},r="Output length must be a multiple of 8";if(t.outputUpper=n.outputUpper||!1,n.b64Pad&&(t.b64Pad=n.b64Pad),n.outputLen){if(n.outputLen%8!=0)throw new Error(r);t.outputLen=n.outputLen}else if(n.shakeLen){if(n.shakeLen%8!=0)throw new Error(r);t.outputLen=n.shakeLen}if("boolean"!=typeof t.outputUpper)throw new Error("Invalid outputUpper formatting option");if("string"!=typeof t.b64Pad)throw new Error("Invalid b64Pad formatting option");return t}function a(e,t){return e<<t|e>>>32-t}function s(e,t,n){return e^t^n}function c(e,t,n){return e&t^e&n^t&n}function u(e,t){var n=(65535&e)+(65535&t);return(65535&(e>>>16)+(t>>>16)+(n>>>16))<<16|65535&n}function l(e,t,n,r,i){var o=(65535&e)+(65535&t)+(65535&n)+(65535&r)+(65535&i);return(65535&(e>>>16)+(t>>>16)+(n>>>16)+(r>>>16)+(i>>>16)+(o>>>16))<<16|65535&o}function f(e){return[1732584193,4023233417,2562383102,271733878,3285377520]}function p(e,t){var n,r,i,o,f,p,d,h,y=[];for(n=t[0],r=t[1],i=t[2],o=t[3],f=t[4],d=0;d<80;d+=1)y[d]=d<16?e[d]:a(y[d-3]^y[d-8]^y[d-14]^y[d-16],1),p=d<20?l(a(n,5),(h=r)&i^~h&o,f,1518500249,y[d]):d<40?l(a(n,5),s(r,i,o),f,1859775393,y[d]):d<60?l(a(n,5),c(r,i,o),f,2400959708,y[d]):l(a(n,5),s(r,i,o),f,3395469782,y[d]),f=o,o=i,i=a(r,30),r=n,n=p;return t[0]=u(n,t[0]),t[1]=u(r,t[1]),t[2]=u(i,t[2]),t[3]=u(o,t[3]),t[4]=u(f,t[4]),t}function d(e,t,n,r){for(var i,o=15+(t+65>>>9<<4),a=t+n;e.length<=o;)e.push(0);for(e[t>>>5]|=128<<24-t%32,e[o]=4294967295&a,e[o-1]=a/4294967296|0,i=0;i<e.length;i+=16)r=p(e.slice(i,i+16),r);return r}return function(t){function n(e,n,i){var o=this;if("SHA-1"!==e)throw new Error("Chosen SHA variant is not supported");var a=i||{};return(o=t.call(this,e,n,i)||this).t=!0,o.i=o.o,o.u=-1,o.s=r(o.h,o.v,o.u),o.A=p,o.p=function(e){return e.slice()},o.l=f,o.R=d,o.U=[1732584193,4023233417,2562383102,271733878,3285377520],o.T=512,o.m=160,o.F=!1,a.hmacKey&&o.B(function(e,t,n,i){var o="hmacKey must include a value and format";if(!t)throw new Error(o);if(void 0===t.value||!t.format)throw new Error(o);return r(t.format,t.encoding||"UTF8",n)(t.value)}(0,a.hmacKey,o.u)),o}return function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}(n,t),n}(function(){function e(e,t,n){var r=n||{};if(this.h=t,this.v=r.encoding||"UTF8",this.numRounds=r.numRounds||1,isNaN(this.numRounds)||this.numRounds!==parseInt(this.numRounds,10)||1>this.numRounds)throw new Error("numRounds must a integer >= 1");this.g=e,this.Y=[],this.I=0,this.C=!1,this.H=0,this.L=!1,this.N=[],this.S=[]}return e.prototype.update=function(e){var t,n=0,r=this.T>>>5,i=this.s(e,this.Y,this.I),o=i.binLen,a=i.value,s=o>>>5;for(t=0;t<s;t+=r)n+this.T<=o&&(this.U=this.A(a.slice(t,t+r),this.U),n+=this.T);this.H+=n,this.Y=a.slice(n>>>5),this.I=o%this.T,this.C=!0},e.prototype.getHash=function(e,t){var n,r,a=this.m,s=o(t);if(!0===this.F){if(-1===s.outputLen)throw new Error("Output length must be specified in options");a=s.outputLen}var c=i(e,a,this.u,s);if(!0===this.L&&this.i)return c(this.i(s));for(r=this.R(this.Y.slice(),this.I,this.H,this.p(this.U),a),n=1;n<this.numRounds;n+=1)!0===this.F&&a%32!=0&&(r[r.length-1]&=16777215>>>24-a%32),r=this.R(r,a,0,this.l(this.g),a);return c(r)},e.prototype.setHMACKey=function(e,t,n){if(!0!==this.t)throw new Error("Variant does not support HMAC");if(!0===this.C)throw new Error("Cannot set MAC key after calling update");var i=r(t,(n||{}).encoding||"UTF8",this.u);this.B(i(e))},e.prototype.B=function(e){var t,n=this.T>>>3,r=n/4-1;if(1!==this.numRounds)throw new Error("Cannot set numRounds with MAC");if(!0===this.L)throw new Error("MAC key already set");for(n<e.binLen/8&&(e.value=this.R(e.value,e.binLen,0,this.l(this.g),this.m));e.value.length<=r;)e.value.push(0);for(t=0;t<=r;t+=1)this.N[t]=909522486^e.value[t],this.S[t]=1549556828^e.value[t];this.U=this.A(this.N,this.U),this.H=this.T,this.L=!0},e.prototype.getHMAC=function(e,t){var n=o(t);return i(e,this.m,this.u,n)(this.o())},e.prototype.o=function(){var e;if(!1===this.L)throw new Error("Cannot call getHMAC without first setting MAC key");var t=this.R(this.Y.slice(),this.I,this.H,this.p(this.U),this.m);return e=this.A(this.S,this.l(this.g)),this.R(t,this.m,this.T,e,this.m)},e}())}()},function(e){e.exports=JSON.parse('{"a":"1.0.36-dev.1"}')},function(e,t){e.exports=m},function(e,t,n){e.exports={embeddedPlayer:"dgjVs"}},function(e,t,n){e.exports={image:"_3T3Ux"}},function(e,t,n){var r=n(121);e.exports=(r.default||r).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){return'<div class="layout-region position-relative"></div>\r\n<div id="dialog-region"></div>\r\n<div id="print-region"></div>'},useData:!0})},function(e,t,n){"use strict";n.r(t),n.d(t,"EmbedErrorView",(function(){return c}));var r=n(0),i=n.n(r),o=n(217),a=n(189),s=n.n(a);function c(e){var t=e.error;return i.a.createElement("div",{className:"text-white ".concat(s.a.embedError)},i.a.createElement("div",{className:s.a.logo},i.a.createElement(o.b,null)),i.a.createElement("div",{className:"".concat(s.a.content," d-flex flex-column align-items-center")},i.a.createElement("div",{className:"".concat(s.a.imgContainer," mb-3")},i.a.createElement("img",{src:t.imageUrl,className:s.a.img,role:"presentation",alt:""})),i.a.createElement("h1",{className:"".concat(s.a.heading," font-weight-500 mb-0")},t.heading),!!t.description&&i.a.createElement("p",{className:"mb-0"},t.description)))}},function(e,t,n){var r=n(121);e.exports=(r.default||r).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){return'<div class="layout-region"></div>'},useData:!0})},function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return o}));var r=n(161),i=n(22),o=function(){function t(){}return t.prototype.writeHandshakeRequest=function(e){return r.a.write(JSON.stringify(e))},t.prototype.parseHandshakeResponse=function(t){var n,o;if(Object(i.h)(t)||void 0!==e&&t instanceof e){var a=new Uint8Array(t);if(-1===(c=a.indexOf(r.a.RecordSeparatorCode)))throw new Error("Message is incomplete.");var s=c+1;n=String.fromCharCode.apply(null,a.slice(0,s)),o=a.byteLength>s?a.slice(s).buffer:null}else{var c,u=t;if(-1===(c=u.indexOf(r.a.RecordSeparator)))throw new Error("Message is incomplete.");s=c+1;n=u.substring(0,s),o=u.length>s?u.substring(s):null}var l=r.a.parse(n),f=JSON.parse(l[0]);if(f.type)throw new Error("Expected a handshake response from the server.");return[o,f]},t}()}).call(this,n(391).Buffer)},function(e,t,n){e.exports={notificationsView:"_3UtcL"}},function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t,n){"use strict";var r=n(1);n(838);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})(e)}function o(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function a(e,t){return(a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function s(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=u(e);if(t){var i=u(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return c(this,n)}}function c(e,t){return!t||"object"!==i(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function u(e){return(u=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var l=function(e){!function(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}}),t&&a(e,t)}(c,e);var t,n,r,i=s(c);function c(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,c),(n=i.call(this,e,t)).update(),n}return t=c,(n=[{key:"update",value:function(){this.options_.isFavourited?this.addClass("cv-favourited"):this.removeClass("cv-favourited")}},{key:"handleClick",value:function(){if(this.options_.isFavourited=!this.options_.isFavourited,this.update(),this.options_.clickHandler){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.options_.clickHandler.call(this,t)}}},{key:"buildCSSClass",value:function(){return"cv-favourite-button"}}])&&o(t.prototype,n),r&&o(t,r),c}(r.a.getComponent("Button"));function f(e){return(f="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)}function p(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function d(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function h(e,t){return(h=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=v(e);if(t){var i=v(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return m(this,n)}}function m(e,t){return!t||"object"!==f(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function v(e){return(v=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}l.prototype.controlText_="Favourite";var g=function(e){!function(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}}),t&&h(e,t)}(o,e);var t,n,r,i=y(o);function o(){return p(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"setFavourite",value:function(e,t){var n=this;e!==this.isFavourite&&(this.isFavourite=e,this.onClickFavourite=t,this.player.ready((function(){n.renderFavouriteButton()})))}},{key:"renderFavouriteButton",value:function(){this.player.isDisposed()||(this.button&&this.player.removeChild(this.button),this.button=new l(this.player,{isFavourited:this.isFavourite,clickHandler:this.onClickFavourite}),this.player.addChild(this.button))}}])&&d(t.prototype,n),r&&d(t,r),o}(r.a.getPlugin("plugin"));r.a.registerPlugin("favouritePlugin",g)},function(e,t,n){"use strict";var r=n(1),i=n(126);n(840);function o(e){return(o="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)}function a(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function s(e,t){return(s=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=l(e);if(t){var i=l(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u(this,n)}}function u(e,t){return!t||"object"!==o(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function l(e){return(l=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var f=function(e){!function(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}}),t&&s(e,t)}(u,e);var t,n,r,o=c(u);function u(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,u),(n=o.call(this,e,t)).update(),n}return t=u,(n=[{key:"update",value:function(){this.options_.activityStatus===i.a.Complete?this.addClass("cv-activity-completed"):this.removeClass("cv-activity-completed")}},{key:"handleClick",value:function(){if(this.options_.activityStatus=this.options_.activityStatus===i.a.Complete?i.a.Incomplete:i.a.Complete,this.update(),this.options_.clickHandler){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.options_.clickHandler.call(this,t)}}},{key:"buildCSSClass",value:function(){return"cv-activity-status-button"}}])&&a(t.prototype,n),r&&a(t,r),u}(r.a.getComponent("Button"));function p(e){return(p="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)}function d(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function h(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function y(e,t){return(y=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=g(e);if(t){var i=g(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return v(this,n)}}function v(e,t){return!t||"object"!==p(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function g(e){return(g=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}f.prototype.controlText_="ActivityStatus";var b=function(e){!function(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}}),t&&y(e,t)}(o,e);var t,n,r,i=m(o);function o(){return d(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"setActivityStatus",value:function(e,t){var n=this;e!==this.activityStatus&&(this.activityStatus=e,this.onToggleStatus=t,this.player.ready((function(){n.renderActivityStatusButton()})))}},{key:"renderActivityStatusButton",value:function(){this.player.isDisposed()||(this.button&&this.player.removeChild(this.button),this.button=new f(this.player,{activityStatus:this.activityStatus,clickHandler:this.onToggleStatus}),this.player.addChild(this.button))}}])&&h(t.prototype,n),r&&h(t,r),o}(r.a.getPlugin("plugin"));r.a.registerPlugin("activityStatusPlugin",b)},function(e,t){function n(t){return"function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?(e.exports=n=function(e){return typeof e},e.exports.default=e.exports,e.exports.__esModule=!0):(e.exports=n=function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.default=e.exports,e.exports.__esModule=!0),n(t)}e.exports=n,e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){var n,r,i=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function s(e){if(n===setTimeout)return setTimeout(e,0);if((n===o||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:o}catch(e){n=o}try{r="function"==typeof clearTimeout?clearTimeout:a}catch(e){r=a}}();var c,u=[],l=!1,f=-1;function p(){l&&c&&(l=!1,c.length?u=c.concat(u):f=-1,u.length&&d())}function d(){if(!l){var e=s(p);l=!0;for(var t=u.length;t;){for(c=u,u=[];++f<t;)c&&c[f].run();f=-1,t=u.length}c=null,l=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function h(e,t){this.fun=e,this.array=t}function y(){}i.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];u.push(new h(e,t)),1!==u.length||l||s(d)},h.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=y,i.addListener=y,i.once=y,i.off=y,i.removeListener=y,i.removeAllListeners=y,i.emit=y,i.prependListener=y,i.prependOnceListener=y,i.listeners=function(e){return[]},i.binding=function(e){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(e){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},,function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){"use strict";t.__esModule=!0;var r=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(n(772));var i=r.tokenize,o=r.options.Options;function a(e){return e.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">")}function s(e){return e.replace(/"/g,""")}function c(e){if(!e)return"";var t=[];for(var n in e){var r=e[n]+"";t.push(n+'="'+s(r)+'"')}return t.join(" ")}function u(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};t=new o(t);for(var n=i(e),r=[],u=0;u<n.length;u++){var l=n[u];if("nl"===l.type&&t.nl2br)r.push("<br>\n");else if(l.isLink&&t.check(l)){var f=t.resolve(l),p=f.formatted,d=f.formattedHref,h=f.tagName,y=f.className,m=f.target,v=f.attributes,g="<"+h+' href="'+s(d)+'"';y&&(g+=' class="'+s(y)+'"'),m&&(g+=' target="'+s(m)+'"'),v&&(g+=" "+c(v)),g+=">"+a(p)+"</"+h+">",r.push(g)}else r.push(a(l.toString()))}return r.join("")}if(!String.prototype.linkify)try{Object.defineProperty(String.prototype,"linkify",{set:function(){},get:function(){return function(e){return u(this,e)}}})}catch(e){String.prototype.linkify||(String.prototype.linkify=function(e){return u(this,e)})}t.default=u},function(e,t,n){"use strict";t.__esModule=!0,t.tokenize=t.test=t.scanner=t.parser=t.options=t.inherits=t.find=void 0;var r=n(265),i=s(n(773)),o=s(n(774)),a=s(n(775));function s(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)});var c=function(e){return a.run(o.run(e))};t.find=function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=c(e),r=[],i=0;i<n.length;i++){var o=n[i];!o.isLink||t&&o.type!==t||r.push(o.toObject())}return r},t.inherits=r.inherits,t.options=i,t.parser=a,t.scanner=o,t.test=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=c(e);return 1===n.length&&n[0].isLink&&(!t||n[0].type===t)},t.tokenize=c},function(e,t,n){"use strict";t.__esModule=!0;var r="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={defaultProtocol:"http",events:null,format:a,formatHref:a,nl2br:!1,tagName:"a",target:function(e,t){return"url"===t?"_blank":null},validate:!0,ignoreTags:[],attributes:null,className:"linkified"};function o(e){e=e||{},this.defaultProtocol=e.hasOwnProperty("defaultProtocol")?e.defaultProtocol:i.defaultProtocol,this.events=e.hasOwnProperty("events")?e.events:i.events,this.format=e.hasOwnProperty("format")?e.format:i.format,this.formatHref=e.hasOwnProperty("formatHref")?e.formatHref:i.formatHref,this.nl2br=e.hasOwnProperty("nl2br")?e.nl2br:i.nl2br,this.tagName=e.hasOwnProperty("tagName")?e.tagName:i.tagName,this.target=e.hasOwnProperty("target")?e.target:i.target,this.validate=e.hasOwnProperty("validate")?e.validate:i.validate,this.ignoreTags=[],this.attributes=e.attributes||e.linkAttributes||i.attributes,this.className=e.hasOwnProperty("className")?e.className:e.linkClass||i.className;for(var t=e.hasOwnProperty("ignoreTags")?e.ignoreTags:i.ignoreTags,n=0;n<t.length;n++)this.ignoreTags.push(t[n].toUpperCase())}function a(e){return e}t.defaults=i,t.Options=o,t.contains=function(e,t){for(var n=0;n<e.length;n++)if(e[n]===t)return!0;return!1},o.prototype={resolve:function(e){var t=e.toHref(this.defaultProtocol);return{formatted:this.get("format",e.toString(),e),formattedHref:this.get("formatHref",t,e),tagName:this.get("tagName",t,e),className:this.get("className",t,e),target:this.get("target",t,e),events:this.getObject("events",t,e),attributes:this.getObject("attributes",t,e)}},check:function(e){return this.get("validate",e.toString(),e)},get:function(e,t,n){var o=void 0,a=this[e];if(!a)return a;switch(void 0===a?"undefined":r(a)){case"function":return a(t,n.type);case"object":return"function"==typeof(o=a.hasOwnProperty(n.type)?a[n.type]:i[e])?o(t,n.type):o}return a},getObject:function(e,t,n){var r=this[e];return"function"==typeof r?r(t,n.type):r}}},function(e,t,n){"use strict";t.__esModule=!0,t.start=t.run=t.TOKENS=t.State=void 0;var r=n(428),i=n(326),o=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(i);var a="aaa|aarp|abarth|abb|abbott|abbvie|abc|able|abogado|abudhabi|ac|academy|accenture|accountant|accountants|aco|active|actor|ad|adac|ads|adult|ae|aeg|aero|aetna|af|afamilycompany|afl|africa|ag|agakhan|agency|ai|aig|aigo|airbus|airforce|airtel|akdn|al|alfaromeo|alibaba|alipay|allfinanz|allstate|ally|alsace|alstom|am|americanexpress|americanfamily|amex|amfam|amica|amsterdam|analytics|android|anquan|anz|ao|aol|apartments|app|apple|aq|aquarelle|ar|arab|aramco|archi|army|arpa|art|arte|as|asda|asia|associates|at|athleta|attorney|au|auction|audi|audible|audio|auspost|author|auto|autos|avianca|aw|aws|ax|axa|az|azure|ba|baby|baidu|banamex|bananarepublic|band|bank|bar|barcelona|barclaycard|barclays|barefoot|bargains|baseball|basketball|bauhaus|bayern|bb|bbc|bbt|bbva|bcg|bcn|bd|be|beats|beauty|beer|bentley|berlin|best|bestbuy|bet|bf|bg|bh|bharti|bi|bible|bid|bike|bing|bingo|bio|biz|bj|black|blackfriday|blanco|blockbuster|blog|bloomberg|blue|bm|bms|bmw|bn|bnl|bnpparibas|bo|boats|boehringer|bofa|bom|bond|boo|book|booking|boots|bosch|bostik|boston|bot|boutique|box|br|bradesco|bridgestone|broadway|broker|brother|brussels|bs|bt|budapest|bugatti|build|builders|business|buy|buzz|bv|bw|by|bz|bzh|ca|cab|cafe|cal|call|calvinklein|cam|camera|camp|cancerresearch|canon|capetown|capital|capitalone|car|caravan|cards|care|career|careers|cars|cartier|casa|case|caseih|cash|casino|cat|catering|catholic|cba|cbn|cbre|cbs|cc|cd|ceb|center|ceo|cern|cf|cfa|cfd|cg|ch|chanel|channel|chase|chat|cheap|chintai|chloe|christmas|chrome|chrysler|church|ci|cipriani|circle|cisco|citadel|citi|citic|city|cityeats|ck|cl|claims|cleaning|click|clinic|clinique|clothing|cloud|club|clubmed|cm|cn|co|coach|codes|coffee|college|cologne|com|comcast|commbank|community|company|compare|computer|comsec|condos|construction|consulting|contact|contractors|cooking|cookingchannel|cool|coop|corsica|country|coupon|coupons|courses|cr|credit|creditcard|creditunion|cricket|crown|crs|cruise|cruises|csc|cu|cuisinella|cv|cw|cx|cy|cymru|cyou|cz|dabur|dad|dance|data|date|dating|datsun|day|dclk|dds|de|deal|dealer|deals|degree|delivery|dell|deloitte|delta|democrat|dental|dentist|desi|design|dev|dhl|diamonds|diet|digital|direct|directory|discount|discover|dish|diy|dj|dk|dm|dnp|do|docs|doctor|dodge|dog|doha|domains|dot|download|drive|dtv|dubai|duck|dunlop|duns|dupont|durban|dvag|dvr|dz|earth|eat|ec|eco|edeka|edu|education|ee|eg|email|emerck|energy|engineer|engineering|enterprises|epost|epson|equipment|er|ericsson|erni|es|esq|estate|esurance|et|etisalat|eu|eurovision|eus|events|everbank|exchange|expert|exposed|express|extraspace|fage|fail|fairwinds|faith|family|fan|fans|farm|farmers|fashion|fast|fedex|feedback|ferrari|ferrero|fi|fiat|fidelity|fido|film|final|finance|financial|fire|firestone|firmdale|fish|fishing|fit|fitness|fj|fk|flickr|flights|flir|florist|flowers|fly|fm|fo|foo|food|foodnetwork|football|ford|forex|forsale|forum|foundation|fox|fr|free|fresenius|frl|frogans|frontdoor|frontier|ftr|fujitsu|fujixerox|fun|fund|furniture|futbol|fyi|ga|gal|gallery|gallo|gallup|game|games|gap|garden|gb|gbiz|gd|gdn|ge|gea|gent|genting|george|gf|gg|ggee|gh|gi|gift|gifts|gives|giving|gl|glade|glass|gle|global|globo|gm|gmail|gmbh|gmo|gmx|gn|godaddy|gold|goldpoint|golf|goo|goodhands|goodyear|goog|google|gop|got|gov|gp|gq|gr|grainger|graphics|gratis|green|gripe|grocery|group|gs|gt|gu|guardian|gucci|guge|guide|guitars|guru|gw|gy|hair|hamburg|hangout|haus|hbo|hdfc|hdfcbank|health|healthcare|help|helsinki|here|hermes|hgtv|hiphop|hisamitsu|hitachi|hiv|hk|hkt|hm|hn|hockey|holdings|holiday|homedepot|homegoods|homes|homesense|honda|honeywell|horse|hospital|host|hosting|hot|hoteles|hotels|hotmail|house|how|hr|hsbc|ht|htc|hu|hughes|hyatt|hyundai|ibm|icbc|ice|icu|id|ie|ieee|ifm|ikano|il|im|imamat|imdb|immo|immobilien|in|industries|infiniti|info|ing|ink|institute|insurance|insure|int|intel|international|intuit|investments|io|ipiranga|iq|ir|irish|is|iselect|ismaili|ist|istanbul|it|itau|itv|iveco|iwc|jaguar|java|jcb|jcp|je|jeep|jetzt|jewelry|jio|jlc|jll|jm|jmp|jnj|jo|jobs|joburg|jot|joy|jp|jpmorgan|jprs|juegos|juniper|kaufen|kddi|ke|kerryhotels|kerrylogistics|kerryproperties|kfh|kg|kh|ki|kia|kim|kinder|kindle|kitchen|kiwi|km|kn|koeln|komatsu|kosher|kp|kpmg|kpn|kr|krd|kred|kuokgroup|kw|ky|kyoto|kz|la|lacaixa|ladbrokes|lamborghini|lamer|lancaster|lancia|lancome|land|landrover|lanxess|lasalle|lat|latino|latrobe|law|lawyer|lb|lc|lds|lease|leclerc|lefrak|legal|lego|lexus|lgbt|li|liaison|lidl|life|lifeinsurance|lifestyle|lighting|like|lilly|limited|limo|lincoln|linde|link|lipsy|live|living|lixil|lk|loan|loans|locker|locus|loft|lol|london|lotte|lotto|love|lpl|lplfinancial|lr|ls|lt|ltd|ltda|lu|lundbeck|lupin|luxe|luxury|lv|ly|ma|macys|madrid|maif|maison|makeup|man|management|mango|map|market|marketing|markets|marriott|marshalls|maserati|mattel|mba|mc|mckinsey|md|me|med|media|meet|melbourne|meme|memorial|men|menu|meo|merckmsd|metlife|mg|mh|miami|microsoft|mil|mini|mint|mit|mitsubishi|mk|ml|mlb|mls|mm|mma|mn|mo|mobi|mobile|mobily|moda|moe|moi|mom|monash|money|monster|mopar|mormon|mortgage|moscow|moto|motorcycles|mov|movie|movistar|mp|mq|mr|ms|msd|mt|mtn|mtr|mu|museum|mutual|mv|mw|mx|my|mz|na|nab|nadex|nagoya|name|nationwide|natura|navy|nba|nc|ne|nec|net|netbank|netflix|network|neustar|new|newholland|news|next|nextdirect|nexus|nf|nfl|ng|ngo|nhk|ni|nico|nike|nikon|ninja|nissan|nissay|nl|no|nokia|northwesternmutual|norton|now|nowruz|nowtv|np|nr|nra|nrw|ntt|nu|nyc|nz|obi|observer|off|office|okinawa|olayan|olayangroup|oldnavy|ollo|om|omega|one|ong|onl|online|onyourside|ooo|open|oracle|orange|org|organic|origins|osaka|otsuka|ott|ovh|pa|page|panasonic|panerai|paris|pars|partners|parts|party|passagens|pay|pccw|pe|pet|pf|pfizer|pg|ph|pharmacy|phd|philips|phone|photo|photography|photos|physio|piaget|pics|pictet|pictures|pid|pin|ping|pink|pioneer|pizza|pk|pl|place|play|playstation|plumbing|plus|pm|pn|pnc|pohl|poker|politie|porn|post|pr|pramerica|praxi|press|prime|pro|prod|productions|prof|progressive|promo|properties|property|protection|pru|prudential|ps|pt|pub|pw|pwc|py|qa|qpon|quebec|quest|qvc|racing|radio|raid|re|read|realestate|realtor|realty|recipes|red|redstone|redumbrella|rehab|reise|reisen|reit|reliance|ren|rent|rentals|repair|report|republican|rest|restaurant|review|reviews|rexroth|rich|richardli|ricoh|rightathome|ril|rio|rip|rmit|ro|rocher|rocks|rodeo|rogers|room|rs|rsvp|ru|rugby|ruhr|run|rw|rwe|ryukyu|sa|saarland|safe|safety|sakura|sale|salon|samsclub|samsung|sandvik|sandvikcoromant|sanofi|sap|sapo|sarl|sas|save|saxo|sb|sbi|sbs|sc|sca|scb|schaeffler|schmidt|scholarships|school|schule|schwarz|science|scjohnson|scor|scot|sd|se|search|seat|secure|security|seek|select|sener|services|ses|seven|sew|sex|sexy|sfr|sg|sh|shangrila|sharp|shaw|shell|shia|shiksha|shoes|shop|shopping|shouji|show|showtime|shriram|si|silk|sina|singles|site|sj|sk|ski|skin|sky|skype|sl|sling|sm|smart|smile|sn|sncf|so|soccer|social|softbank|software|sohu|solar|solutions|song|sony|soy|space|spiegel|spot|spreadbetting|sr|srl|srt|st|stada|staples|star|starhub|statebank|statefarm|statoil|stc|stcgroup|stockholm|storage|store|stream|studio|study|style|su|sucks|supplies|supply|support|surf|surgery|suzuki|sv|swatch|swiftcover|swiss|sx|sy|sydney|symantec|systems|sz|tab|taipei|talk|taobao|target|tatamotors|tatar|tattoo|tax|taxi|tc|tci|td|tdk|team|tech|technology|tel|telecity|telefonica|temasek|tennis|teva|tf|tg|th|thd|theater|theatre|tiaa|tickets|tienda|tiffany|tips|tires|tirol|tj|tjmaxx|tjx|tk|tkmaxx|tl|tm|tmall|tn|to|today|tokyo|tools|top|toray|toshiba|total|tours|town|toyota|toys|tr|trade|trading|training|travel|travelchannel|travelers|travelersinsurance|trust|trv|tt|tube|tui|tunes|tushu|tv|tvs|tw|tz|ua|ubank|ubs|uconnect|ug|uk|unicom|university|uno|uol|ups|us|uy|uz|va|vacations|vana|vanguard|vc|ve|vegas|ventures|verisign|versicherung|vet|vg|vi|viajes|video|vig|viking|villas|vin|vip|virgin|visa|vision|vista|vistaprint|viva|vivo|vlaanderen|vn|vodka|volkswagen|volvo|vote|voting|voto|voyage|vu|vuelos|wales|walmart|walter|wang|wanggou|warman|watch|watches|weather|weatherchannel|webcam|weber|website|wed|wedding|weibo|weir|wf|whoswho|wien|wiki|williamhill|win|windows|wine|winners|wme|wolterskluwer|woodside|work|works|world|wow|ws|wtc|wtf|xbox|xerox|xfinity|xihuan|xin|xn--11b4c3d|xn--1ck2e1b|xn--1qqw23a|xn--2scrj9c|xn--30rr7y|xn--3bst00m|xn--3ds443g|xn--3e0b707e|xn--3hcrj9c|xn--3oq18vl8pn36a|xn--3pxu8k|xn--42c2d9a|xn--45br5cyl|xn--45brj9c|xn--45q11c|xn--4gbrim|xn--54b7fta0cc|xn--55qw42g|xn--55qx5d|xn--5su34j936bgsg|xn--5tzm5g|xn--6frz82g|xn--6qq986b3xl|xn--80adxhks|xn--80ao21a|xn--80aqecdr1a|xn--80asehdb|xn--80aswg|xn--8y0a063a|xn--90a3ac|xn--90ae|xn--90ais|xn--9dbq2a|xn--9et52u|xn--9krt00a|xn--b4w605ferd|xn--bck1b9a5dre4c|xn--c1avg|xn--c2br7g|xn--cck2b3b|xn--cg4bki|xn--clchc0ea0b2g2a9gcd|xn--czr694b|xn--czrs0t|xn--czru2d|xn--d1acj3b|xn--d1alf|xn--e1a4c|xn--eckvdtc9d|xn--efvy88h|xn--estv75g|xn--fct429k|xn--fhbei|xn--fiq228c5hs|xn--fiq64b|xn--fiqs8s|xn--fiqz9s|xn--fjq720a|xn--flw351e|xn--fpcrj9c3d|xn--fzc2c9e2c|xn--fzys8d69uvgm|xn--g2xx48c|xn--gckr3f0f|xn--gecrj9c|xn--gk3at1e|xn--h2breg3eve|xn--h2brj9c|xn--h2brj9c8c|xn--hxt814e|xn--i1b6b1a6a2e|xn--imr513n|xn--io0a7i|xn--j1aef|xn--j1amh|xn--j6w193g|xn--jlq61u9w7b|xn--jvr189m|xn--kcrx77d1x4a|xn--kprw13d|xn--kpry57d|xn--kpu716f|xn--kput3i|xn--l1acc|xn--lgbbat1ad8j|xn--mgb9awbf|xn--mgba3a3ejt|xn--mgba3a4f16a|xn--mgba7c0bbn0a|xn--mgbaakc7dvf|xn--mgbaam7a8h|xn--mgbab2bd|xn--mgbai9azgqp6j|xn--mgbayh7gpa|xn--mgbb9fbpob|xn--mgbbh1a|xn--mgbbh1a71e|xn--mgbc0a9azcg|xn--mgbca7dzdo|xn--mgberp4a5d4ar|xn--mgbgu82a|xn--mgbi4ecexp|xn--mgbpl2fh|xn--mgbt3dhd|xn--mgbtx2b|xn--mgbx4cd0ab|xn--mix891f|xn--mk1bu44c|xn--mxtq1m|xn--ngbc5azd|xn--ngbe9e0a|xn--ngbrx|xn--node|xn--nqv7f|xn--nqv7fs00ema|xn--nyqy26a|xn--o3cw4h|xn--ogbpf8fl|xn--p1acf|xn--p1ai|xn--pbt977c|xn--pgbs0dh|xn--pssy2u|xn--q9jyb4c|xn--qcka1pmc|xn--qxam|xn--rhqv96g|xn--rovu88b|xn--rvc1e0am3e|xn--s9brj9c|xn--ses554g|xn--t60b56a|xn--tckwe|xn--tiq49xqyj|xn--unup4y|xn--vermgensberater-ctb|xn--vermgensberatung-pwb|xn--vhquv|xn--vuq861b|xn--w4r85el8fhu5dnra|xn--w4rs40l|xn--wgbh1c|xn--wgbl6a|xn--xhq521b|xn--xkc2al3hye2a|xn--xkc2dl3a5ee0h|xn--y9a3aq|xn--yfro4i67o|xn--ygbi2ammx|xn--zfr164b|xperia|xxx|xyz|yachts|yahoo|yamaxun|yandex|ye|yodobashi|yoga|yokohama|you|youtube|yt|yun|za|zappos|zara|zero|zip|zippo|zm|zone|zuerich|zw".split("|"),s="0123456789".split(""),c="0123456789abcdefghijklmnopqrstuvwxyz".split(""),u=[" ","\f","\r","\t","\v"," "," ",""],l=[],f=function(e){return new r.CharacterState(e)},p=f(),d=f(i.NUM),h=f(i.DOMAIN),y=f(),m=f(i.WS);p.on("@",f(i.AT)).on(".",f(i.DOT)).on("+",f(i.PLUS)).on("#",f(i.POUND)).on("?",f(i.QUERY)).on("/",f(i.SLASH)).on("_",f(i.UNDERSCORE)).on(":",f(i.COLON)).on("{",f(i.OPENBRACE)).on("[",f(i.OPENBRACKET)).on("<",f(i.OPENANGLEBRACKET)).on("(",f(i.OPENPAREN)).on("}",f(i.CLOSEBRACE)).on("]",f(i.CLOSEBRACKET)).on(">",f(i.CLOSEANGLEBRACKET)).on(")",f(i.CLOSEPAREN)).on("&",f(i.AMPERSAND)).on([",",";","!",'"',"'"],f(i.PUNCTUATION)),p.on("\n",f(i.NL)).on(u,m),m.on(u,m);for(var v=0;v<a.length;v++){var g=(0,r.stateify)(a[v],p,i.TLD,i.DOMAIN);l.push.apply(l,g)}var b=(0,r.stateify)("file",p,i.DOMAIN,i.DOMAIN),w=(0,r.stateify)("ftp",p,i.DOMAIN,i.DOMAIN),_=(0,r.stateify)("http",p,i.DOMAIN,i.DOMAIN),S=(0,r.stateify)("mailto",p,i.DOMAIN,i.DOMAIN);l.push.apply(l,b),l.push.apply(l,w),l.push.apply(l,_),l.push.apply(l,S);var T=b.pop(),C=w.pop(),E=_.pop(),k=S.pop(),O=f(i.DOMAIN),P=f(i.PROTOCOL),A=f(i.MAILTO);C.on("s",O).on(":",P),E.on("s",O).on(":",P),l.push(O),T.on(":",P),O.on(":",P),k.on(":",A);var I=(0,r.stateify)("localhost",p,i.LOCALHOST,i.DOMAIN);l.push.apply(l,I),p.on(s,d),d.on("-",y).on(s,d).on(c,h),h.on("-",y).on(c,h);for(var x=0;x<l.length;x++)l[x].on("-",y).on(c,h);y.on("-",y).on(s,h).on(c,h),p.defaultTransition=f(i.SYM);var R=p;t.State=r.CharacterState,t.TOKENS=o,t.run=function(e){for(var t=e.replace(/[A-Z]/g,(function(e){return e.toLowerCase()})),n=e.length,r=[],i=0;i<n;){for(var o=p,a=null,s=0,c=null,u=-1;i<n&&(a=o.next(t[i]));)(o=a).accepts()?(u=0,c=o):u>=0&&u++,s++,i++;if(!(u<0)){i-=u,s-=u;var l=c.emit();r.push(new l(e.substr(i-s,s)))}}return r},t.start=R},function(e,t,n){"use strict";t.__esModule=!0,t.start=t.run=t.TOKENS=t.State=void 0;var r=n(428),i=n(776),o=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(i),a=n(326);var s=function(e){return new r.TokenState(e)},c=s(),u=s(),l=s(),f=s(),p=s(),d=s(),h=s(),y=s(i.URL),m=s(),v=s(i.URL),g=s(i.URL),b=s(),w=s(),_=s(),S=s(),T=s(),C=s(i.URL),E=s(i.URL),k=s(i.URL),O=s(i.URL),P=s(),A=s(),I=s(),x=s(),R=s(),L=s(),j=s(i.EMAIL),N=s(),D=s(i.EMAIL),B=s(i.MAILTOEMAIL),U=s(),M=s(),V=s(),F=s(),H=s(i.NL);c.on(a.NL,H).on(a.PROTOCOL,u).on(a.MAILTO,l).on(a.SLASH,f),u.on(a.SLASH,f),f.on(a.SLASH,p),c.on(a.TLD,d).on(a.DOMAIN,d).on(a.LOCALHOST,y).on(a.NUM,d),p.on(a.TLD,g).on(a.DOMAIN,g).on(a.NUM,g).on(a.LOCALHOST,g),d.on(a.DOT,h),R.on(a.DOT,L),h.on(a.TLD,y).on(a.DOMAIN,d).on(a.NUM,d).on(a.LOCALHOST,d),L.on(a.TLD,j).on(a.DOMAIN,R).on(a.NUM,R).on(a.LOCALHOST,R),y.on(a.DOT,h),j.on(a.DOT,L),y.on(a.COLON,m).on(a.SLASH,g),m.on(a.NUM,v),v.on(a.SLASH,g),j.on(a.COLON,N),N.on(a.NUM,D);var z=[a.DOMAIN,a.AT,a.LOCALHOST,a.NUM,a.PLUS,a.POUND,a.PROTOCOL,a.SLASH,a.TLD,a.UNDERSCORE,a.SYM,a.AMPERSAND],W=[a.COLON,a.DOT,a.QUERY,a.PUNCTUATION,a.CLOSEBRACE,a.CLOSEBRACKET,a.CLOSEANGLEBRACKET,a.CLOSEPAREN,a.OPENBRACE,a.OPENBRACKET,a.OPENANGLEBRACKET,a.OPENPAREN];g.on(a.OPENBRACE,w).on(a.OPENBRACKET,_).on(a.OPENANGLEBRACKET,S).on(a.OPENPAREN,T),b.on(a.OPENBRACE,w).on(a.OPENBRACKET,_).on(a.OPENANGLEBRACKET,S).on(a.OPENPAREN,T),w.on(a.CLOSEBRACE,g),_.on(a.CLOSEBRACKET,g),S.on(a.CLOSEANGLEBRACKET,g),T.on(a.CLOSEPAREN,g),C.on(a.CLOSEBRACE,g),E.on(a.CLOSEBRACKET,g),k.on(a.CLOSEANGLEBRACKET,g),O.on(a.CLOSEPAREN,g),P.on(a.CLOSEBRACE,g),A.on(a.CLOSEBRACKET,g),I.on(a.CLOSEANGLEBRACKET,g),x.on(a.CLOSEPAREN,g),w.on(z,C),_.on(z,E),S.on(z,k),T.on(z,O),w.on(W,P),_.on(W,A),S.on(W,I),T.on(W,x),C.on(z,C),E.on(z,E),k.on(z,k),O.on(z,O),C.on(W,C),E.on(W,E),k.on(W,k),O.on(W,O),P.on(z,C),A.on(z,E),I.on(z,k),x.on(z,O),P.on(W,P),A.on(W,A),I.on(W,I),x.on(W,x),g.on(z,g),b.on(z,g),g.on(W,b),b.on(W,b),l.on(a.TLD,B).on(a.DOMAIN,B).on(a.NUM,B).on(a.LOCALHOST,B),B.on(z,B).on(W,U),U.on(z,B).on(W,U);var q=[a.DOMAIN,a.NUM,a.PLUS,a.POUND,a.QUERY,a.UNDERSCORE,a.SYM,a.AMPERSAND,a.TLD];d.on(q,M).on(a.AT,V),y.on(q,M).on(a.AT,V),h.on(q,M),M.on(q,M).on(a.AT,V).on(a.DOT,F),F.on(q,M),V.on(a.TLD,R).on(a.DOMAIN,R).on(a.LOCALHOST,j);t.State=r.TokenState,t.TOKENS=o,t.run=function(e){for(var t=e.length,n=0,r=[],o=[];n<t;){for(var a=c,s=null,u=null,l=0,f=null,p=-1;n<t&&!(s=a.next(e[n]));)o.push(e[n++]);for(;n<t&&(u=s||a.next(e[n]));)s=null,(a=u).accepts()?(p=0,f=a):p>=0&&p++,n++,l++;if(p<0)for(var d=n-l;d<n;d++)o.push(e[d]);else{o.length>0&&(r.push(new i.TEXT(o)),o=[]),n-=p,l-=p;var h=f.emit();r.push(new h(e.slice(n-l,n)))}}return o.length>0&&r.push(new i.TEXT(o)),r},t.start=c},function(e,t,n){"use strict";t.__esModule=!0,t.URL=t.TEXT=t.NL=t.EMAIL=t.MAILTOEMAIL=t.Base=void 0;var r=n(429),i=n(265),o=n(326);function a(e){return e instanceof o.DOMAIN||e instanceof o.TLD}var s=(0,r.createTokenClass)();s.prototype={type:"token",isLink:!1,toString:function(){for(var e=[],t=0;t<this.v.length;t++)e.push(this.v[t].toString());return e.join("")},toHref:function(){return this.toString()},toObject:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"http";return{type:this.type,value:this.toString(),href:this.toHref(e)}}};var c=(0,i.inherits)(s,(0,r.createTokenClass)(),{type:"email",isLink:!0}),u=(0,i.inherits)(s,(0,r.createTokenClass)(),{type:"email",isLink:!0,toHref:function(){return"mailto:"+this.toString()}}),l=(0,i.inherits)(s,(0,r.createTokenClass)(),{type:"text"}),f=(0,i.inherits)(s,(0,r.createTokenClass)(),{type:"nl"}),p=(0,i.inherits)(s,(0,r.createTokenClass)(),{type:"url",isLink:!0,toHref:function(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"http",t=!1,n=!1,r=this.v,i=[],s=0;r[s]instanceof o.PROTOCOL;)t=!0,i.push(r[s].toString().toLowerCase()),s++;for(;r[s]instanceof o.SLASH;)n=!0,i.push(r[s].toString()),s++;for(;a(r[s]);)i.push(r[s].toString().toLowerCase()),s++;for(;s<r.length;s++)i.push(r[s].toString());return i=i.join(""),t||n||(i=e+"://"+i),i},hasProtocol:function(){return this.v[0]instanceof o.PROTOCOL}});t.Base=s,t.MAILTOEMAIL=c,t.EMAIL=u,t.NL=f,t.TEXT=l,t.URL=p},function(e,t,n){},function(e,t){},function(e,t,n){var r=n(765).default,i=n(23);e.exports=function(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?i(e):t},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){function n(t){return e.exports=n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},e.exports.default=e.exports,e.exports.__esModule=!0,n(t)}e.exports=n,e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){e.exports=function(e){if(!e)return!1;var t=n.call(e);return"[object Function]"===t||"function"==typeof e&&"[object RegExp]"!==t||"undefined"!=typeof window&&(e===window.setTimeout||e===window.alert||e===window.confirm||e===window.prompt)};var n=Object.prototype.toString},function(e,t,n){var r=n(296),i=Object.create||function(){function e(){}return function(t){if(1!==arguments.length)throw new Error("Object.create shim only accepts one parameter.");return e.prototype=t,new e}}();function o(e,t){this.name="ParsingError",this.code=e.code,this.message=t||e.message}function a(e){function t(e,t,n,r){return 3600*(0|e)+60*(0|t)+(0|n)+(0|r)/1e3}var n=e.match(/^(\d+):(\d{1,2})(:\d{1,2})?\.(\d{3})/);return n?n[3]?t(n[1],n[2],n[3].replace(":",""),n[4]):n[1]>59?t(n[1],n[2],0,n[4]):t(0,n[1],n[2],n[4]):null}function s(){this.values=i(null)}function c(e,t,n,r){var i=r?e.split(r):[e];for(var o in i)if("string"==typeof i[o]){var a=i[o].split(n);if(2===a.length)t(a[0],a[1])}}function u(e,t,n){var r=e;function i(){var t=a(e);if(null===t)throw new o(o.Errors.BadTimeStamp,"Malformed timestamp: "+r);return e=e.replace(/^[^\sa-zA-Z-]+/,""),t}function u(){e=e.replace(/^\s+/,"")}if(u(),t.startTime=i(),u(),"--\x3e"!==e.substr(0,3))throw new o(o.Errors.BadTimeStamp,"Malformed time stamp (time stamps must be separated by '--\x3e'): "+r);e=e.substr(3),u(),t.endTime=i(),u(),function(e,t){var r=new s;c(e,(function(e,t){switch(e){case"region":for(var i=n.length-1;i>=0;i--)if(n[i].id===t){r.set(e,n[i].region);break}break;case"vertical":r.alt(e,t,["rl","lr"]);break;case"line":var o=t.split(","),a=o[0];r.integer(e,a),r.percent(e,a)&&r.set("snapToLines",!1),r.alt(e,a,["auto"]),2===o.length&&r.alt("lineAlign",o[1],["start","center","end"]);break;case"position":o=t.split(","),r.percent(e,o[0]),2===o.length&&r.alt("positionAlign",o[1],["start","center","end"]);break;case"size":r.percent(e,t);break;case"align":r.alt(e,t,["start","center","end","left","right"])}}),/:/,/\s/),t.region=r.get("region",null),t.vertical=r.get("vertical","");try{t.line=r.get("line","auto")}catch(e){}t.lineAlign=r.get("lineAlign","start"),t.snapToLines=r.get("snapToLines",!0),t.size=r.get("size",100);try{t.align=r.get("align","center")}catch(e){t.align=r.get("align","middle")}try{t.position=r.get("position","auto")}catch(e){t.position=r.get("position",{start:0,left:0,center:50,middle:50,end:100,right:100},t.align)}t.positionAlign=r.get("positionAlign",{start:"start",left:"start",center:"center",middle:"center",end:"end",right:"end"},t.align)}(e,t)}o.prototype=i(Error.prototype),o.prototype.constructor=o,o.Errors={BadSignature:{code:0,message:"Malformed WebVTT signature."},BadTimeStamp:{code:1,message:"Malformed time stamp."}},s.prototype={set:function(e,t){this.get(e)||""===t||(this.values[e]=t)},get:function(e,t,n){return n?this.has(e)?this.values[e]:t[n]:this.has(e)?this.values[e]:t},has:function(e){return e in this.values},alt:function(e,t,n){for(var r=0;r<n.length;++r)if(t===n[r]){this.set(e,t);break}},integer:function(e,t){/^-?\d+$/.test(t)&&this.set(e,parseInt(t,10))},percent:function(e,t){return!!(t.match(/^([\d]{1,3})(\.[\d]*)?%$/)&&(t=parseFloat(t))>=0&&t<=100)&&(this.set(e,t),!0)}};var l=r.createElement("textarea"),f={c:"span",i:"i",b:"b",u:"u",ruby:"ruby",rt:"rt",v:"span",lang:"span"},p={white:"rgba(255,255,255,1)",lime:"rgba(0,255,0,1)",cyan:"rgba(0,255,255,1)",red:"rgba(255,0,0,1)",yellow:"rgba(255,255,0,1)",magenta:"rgba(255,0,255,1)",blue:"rgba(0,0,255,1)",black:"rgba(0,0,0,1)"},d={v:"title",lang:"lang"},h={rt:"ruby"};function y(e,t){function n(){if(!t)return null;var e,n=t.match(/^([^<]*)(<[^>]*>?)?/);return e=n[1]?n[1]:n[2],t=t.substr(e.length),e}function r(e,t){return!h[t.localName]||h[t.localName]===e.localName}function i(t,n){var r=f[t];if(!r)return null;var i=e.document.createElement(r),o=d[t];return o&&n&&(i[o]=n.trim()),i}for(var o,s,c=e.document.createElement("div"),u=c,y=[];null!==(o=n());)if("<"!==o[0])u.appendChild(e.document.createTextNode((s=o,l.innerHTML=s,s=l.textContent,l.textContent="",s)));else{if("/"===o[1]){y.length&&y[y.length-1]===o.substr(2).replace(">","")&&(y.pop(),u=u.parentNode);continue}var m,v=a(o.substr(1,o.length-2));if(v){m=e.document.createProcessingInstruction("timestamp",v),u.appendChild(m);continue}var g=o.match(/^<([^.\s/0-9>]+)(\.[^\s\\>]+)?([^>\\]+)?(\\?)>?$/);if(!g)continue;if(!(m=i(g[1],g[3])))continue;if(!r(u,m))continue;if(g[2]){var b=g[2].split(".");b.forEach((function(e){var t=/^bg_/.test(e),n=t?e.slice(3):e;if(p.hasOwnProperty(n)){var r=t?"background-color":"color",i=p[n];m.style[r]=i}})),m.className=b.join(" ")}y.push(g[1]),u.appendChild(m),u=m}return c}var m=[[1470,1470],[1472,1472],[1475,1475],[1478,1478],[1488,1514],[1520,1524],[1544,1544],[1547,1547],[1549,1549],[1563,1563],[1566,1610],[1645,1647],[1649,1749],[1765,1766],[1774,1775],[1786,1805],[1807,1808],[1810,1839],[1869,1957],[1969,1969],[1984,2026],[2036,2037],[2042,2042],[2048,2069],[2074,2074],[2084,2084],[2088,2088],[2096,2110],[2112,2136],[2142,2142],[2208,2208],[2210,2220],[8207,8207],[64285,64285],[64287,64296],[64298,64310],[64312,64316],[64318,64318],[64320,64321],[64323,64324],[64326,64449],[64467,64829],[64848,64911],[64914,64967],[65008,65020],[65136,65140],[65142,65276],[67584,67589],[67592,67592],[67594,67637],[67639,67640],[67644,67644],[67647,67669],[67671,67679],[67840,67867],[67872,67897],[67903,67903],[67968,68023],[68030,68031],[68096,68096],[68112,68115],[68117,68119],[68121,68147],[68160,68167],[68176,68184],[68192,68223],[68352,68405],[68416,68437],[68440,68466],[68472,68479],[68608,68680],[126464,126467],[126469,126495],[126497,126498],[126500,126500],[126503,126503],[126505,126514],[126516,126519],[126521,126521],[126523,126523],[126530,126530],[126535,126535],[126537,126537],[126539,126539],[126541,126543],[126545,126546],[126548,126548],[126551,126551],[126553,126553],[126555,126555],[126557,126557],[126559,126559],[126561,126562],[126564,126564],[126567,126570],[126572,126578],[126580,126583],[126585,126588],[126590,126590],[126592,126601],[126603,126619],[126625,126627],[126629,126633],[126635,126651],[1114109,1114109]];function v(e){for(var t=0;t<m.length;t++){var n=m[t];if(e>=n[0]&&e<=n[1])return!0}return!1}function g(e){var t=[],n="";if(!e||!e.childNodes)return"ltr";function r(e,t){for(var n=t.childNodes.length-1;n>=0;n--)e.push(t.childNodes[n])}function i(e){if(!e||!e.length)return null;var t=e.pop(),n=t.textContent||t.innerText;if(n){var o=n.match(/^.*(\n|\r)/);return o?(e.length=0,o[0]):n}return"ruby"===t.tagName?i(e):t.childNodes?(r(e,t),i(e)):void 0}for(r(t,e);n=i(t);)for(var o=0;o<n.length;o++)if(v(n.charCodeAt(o)))return"rtl";return"ltr"}function b(){}function w(e,t,n){b.call(this),this.cue=t,this.cueDiv=y(e,t.text);var r={color:"rgba(255, 255, 255, 1)",backgroundColor:"rgba(0, 0, 0, 0.8)",position:"relative",left:0,right:0,top:0,bottom:0,display:"inline",writingMode:""===t.vertical?"horizontal-tb":"lr"===t.vertical?"vertical-lr":"vertical-rl",unicodeBidi:"plaintext"};this.applyStyles(r,this.cueDiv),this.div=e.document.createElement("div"),r={direction:g(this.cueDiv),writingMode:""===t.vertical?"horizontal-tb":"lr"===t.vertical?"vertical-lr":"vertical-rl",unicodeBidi:"plaintext",textAlign:"middle"===t.align?"center":t.align,font:n.font,whiteSpace:"pre-line",position:"absolute"},this.applyStyles(r),this.div.appendChild(this.cueDiv);var i=0;switch(t.positionAlign){case"start":i=t.position;break;case"center":i=t.position-t.size/2;break;case"end":i=t.position-t.size}""===t.vertical?this.applyStyles({left:this.formatStyle(i,"%"),width:this.formatStyle(t.size,"%")}):this.applyStyles({top:this.formatStyle(i,"%"),height:this.formatStyle(t.size,"%")}),this.move=function(e){this.applyStyles({top:this.formatStyle(e.top,"px"),bottom:this.formatStyle(e.bottom,"px"),left:this.formatStyle(e.left,"px"),right:this.formatStyle(e.right,"px"),height:this.formatStyle(e.height,"px"),width:this.formatStyle(e.width,"px")})}}function _(e){var t,n,r,i;if(e.div){n=e.div.offsetHeight,r=e.div.offsetWidth,i=e.div.offsetTop;var o=(o=e.div.childNodes)&&(o=o[0])&&o.getClientRects&&o.getClientRects();e=e.div.getBoundingClientRect(),t=o?Math.max(o[0]&&o[0].height||0,e.height/o.length):0}this.left=e.left,this.right=e.right,this.top=e.top||i,this.height=e.height||n,this.bottom=e.bottom||i+(e.height||n),this.width=e.width||r,this.lineHeight=void 0!==t?t:e.lineHeight}function S(e,t,n,r){var i=new _(t),o=t.cue,a=function(e){if("number"==typeof e.line&&(e.snapToLines||e.line>=0&&e.line<=100))return e.line;if(!e.track||!e.track.textTrackList||!e.track.textTrackList.mediaElement)return-1;for(var t=e.track,n=t.textTrackList,r=0,i=0;i<n.length&&n[i]!==t;i++)"showing"===n[i].mode&&r++;return-1*++r}(o),s=[];if(o.snapToLines){var c;switch(o.vertical){case"":s=["+y","-y"],c="height";break;case"rl":s=["+x","-x"],c="width";break;case"lr":s=["-x","+x"],c="width"}var u=i.lineHeight,l=u*Math.round(a),f=n[c]+u,p=s[0];Math.abs(l)>f&&(l=l<0?-1:1,l*=Math.ceil(f/u)*u),a<0&&(l+=""===o.vertical?n.height:n.width,s=s.reverse()),i.move(p,l)}else{var d=i.lineHeight/n.height*100;switch(o.lineAlign){case"center":a-=d/2;break;case"end":a-=d}switch(o.vertical){case"":t.applyStyles({top:t.formatStyle(a,"%")});break;case"rl":t.applyStyles({left:t.formatStyle(a,"%")});break;case"lr":t.applyStyles({right:t.formatStyle(a,"%")})}s=["+y","-x","+x","-y"],i=new _(t)}var h=function(e,t){for(var i,o=new _(e),a=1,s=0;s<t.length;s++){for(;e.overlapsOppositeAxis(n,t[s])||e.within(n)&&e.overlapsAny(r);)e.move(t[s]);if(e.within(n))return e;var c=e.intersectPercentage(n);a>c&&(i=new _(e),a=c),e=new _(o)}return i||o}(i,s);t.move(h.toCSSCompatValues(n))}function T(){}b.prototype.applyStyles=function(e,t){for(var n in t=t||this.div,e)e.hasOwnProperty(n)&&(t.style[n]=e[n])},b.prototype.formatStyle=function(e,t){return 0===e?0:e+t},w.prototype=i(b.prototype),w.prototype.constructor=w,_.prototype.move=function(e,t){switch(t=void 0!==t?t:this.lineHeight,e){case"+x":this.left+=t,this.right+=t;break;case"-x":this.left-=t,this.right-=t;break;case"+y":this.top+=t,this.bottom+=t;break;case"-y":this.top-=t,this.bottom-=t}},_.prototype.overlaps=function(e){return this.left<e.right&&this.right>e.left&&this.top<e.bottom&&this.bottom>e.top},_.prototype.overlapsAny=function(e){for(var t=0;t<e.length;t++)if(this.overlaps(e[t]))return!0;return!1},_.prototype.within=function(e){return this.top>=e.top&&this.bottom<=e.bottom&&this.left>=e.left&&this.right<=e.right},_.prototype.overlapsOppositeAxis=function(e,t){switch(t){case"+x":return this.left<e.left;case"-x":return this.right>e.right;case"+y":return this.top<e.top;case"-y":return this.bottom>e.bottom}},_.prototype.intersectPercentage=function(e){return Math.max(0,Math.min(this.right,e.right)-Math.max(this.left,e.left))*Math.max(0,Math.min(this.bottom,e.bottom)-Math.max(this.top,e.top))/(this.height*this.width)},_.prototype.toCSSCompatValues=function(e){return{top:this.top-e.top,bottom:e.bottom-this.bottom,left:this.left-e.left,right:e.right-this.right,height:this.height,width:this.width}},_.getSimpleBoxPosition=function(e){var t=e.div?e.div.offsetHeight:e.tagName?e.offsetHeight:0,n=e.div?e.div.offsetWidth:e.tagName?e.offsetWidth:0,r=e.div?e.div.offsetTop:e.tagName?e.offsetTop:0;return{left:(e=e.div?e.div.getBoundingClientRect():e.tagName?e.getBoundingClientRect():e).left,right:e.right,top:e.top||r,height:e.height||t,bottom:e.bottom||r+(e.height||t),width:e.width||n}},T.StringDecoder=function(){return{decode:function(e){if(!e)return"";if("string"!=typeof e)throw new Error("Error - expected string data.");return decodeURIComponent(encodeURIComponent(e))}}},T.convertCueToDOMTree=function(e,t){return e&&t?y(e,t):null};T.processCues=function(e,t,n){if(!e||!t||!n)return null;for(;n.firstChild;)n.removeChild(n.firstChild);var r=e.document.createElement("div");if(r.style.position="absolute",r.style.left="0",r.style.right="0",r.style.top="0",r.style.bottom="0",r.style.margin="1.5%",n.appendChild(r),function(e){for(var t=0;t<e.length;t++)if(e[t].hasBeenReset||!e[t].displayState)return!0;return!1}(t)){var i=[],o=_.getSimpleBoxPosition(r),a={font:Math.round(.05*o.height*100)/100+"px sans-serif"};!function(){for(var n,s,c=0;c<t.length;c++)s=t[c],n=new w(e,s,a),r.appendChild(n.div),S(0,n,o,i),s.displayState=n.div,i.push(_.getSimpleBoxPosition(n))}()}else for(var s=0;s<t.length;s++)r.appendChild(t[s].displayState)},T.Parser=function(e,t,n){n||(n=t,t={}),t||(t={}),this.window=e,this.vttjs=t,this.state="INITIAL",this.buffer="",this.decoder=n||new TextDecoder("utf8"),this.regionList=[]},T.Parser.prototype={reportOrThrowError:function(e){if(!(e instanceof o))throw e;this.onparsingerror&&this.onparsingerror(e)},parse:function(e){var t=this;function n(){for(var e=t.buffer,n=0;n<e.length&&"\r"!==e[n]&&"\n"!==e[n];)++n;var r=e.substr(0,n);return"\r"===e[n]&&++n,"\n"===e[n]&&++n,t.buffer=e.substr(n),r}function r(e){e.match(/X-TIMESTAMP-MAP/)?c(e,(function(e,n){switch(e){case"X-TIMESTAMP-MAP":!function(e){var n=new s;c(e,(function(e,t){switch(e){case"MPEGT":n.integer(e+"S",t);break;case"LOCA":n.set(e+"L",a(t))}}),/[^\d]:/,/,/),t.ontimestampmap&&t.ontimestampmap({MPEGTS:n.get("MPEGTS"),LOCAL:n.get("LOCAL")})}(n)}}),/=/):c(e,(function(e,n){switch(e){case"Region":!function(e){var n=new s;if(c(e,(function(e,t){switch(e){case"id":n.set(e,t);break;case"width":n.percent(e,t);break;case"lines":n.integer(e,t);break;case"regionanchor":case"viewportanchor":var r=t.split(",");if(2!==r.length)break;var i=new s;if(i.percent("x",r[0]),i.percent("y",r[1]),!i.has("x")||!i.has("y"))break;n.set(e+"X",i.get("x")),n.set(e+"Y",i.get("y"));break;case"scroll":n.alt(e,t,["up"])}}),/=/,/\s/),n.has("id")){var r=new(t.vttjs.VTTRegion||t.window.VTTRegion);r.width=n.get("width",100),r.lines=n.get("lines",3),r.regionAnchorX=n.get("regionanchorX",0),r.regionAnchorY=n.get("regionanchorY",100),r.viewportAnchorX=n.get("viewportanchorX",0),r.viewportAnchorY=n.get("viewportanchorY",100),r.scroll=n.get("scroll",""),t.onregion&&t.onregion(r),t.regionList.push({id:n.get("id"),region:r})}}(n)}}),/:/)}e&&(t.buffer+=t.decoder.decode(e,{stream:!0}));try{var i;if("INITIAL"===t.state){if(!/\r\n|\n/.test(t.buffer))return this;var l=(i=n()).match(/^WEBVTT([ \t].*)?$/);if(!l||!l[0])throw new o(o.Errors.BadSignature);t.state="HEADER"}for(var f=!1;t.buffer;){if(!/\r\n|\n/.test(t.buffer))return this;switch(f?f=!1:i=n(),t.state){case"HEADER":/:/.test(i)?r(i):i||(t.state="ID");continue;case"NOTE":i||(t.state="ID");continue;case"ID":if(/^NOTE($|[ \t])/.test(i)){t.state="NOTE";break}if(!i)continue;t.cue=new(t.vttjs.VTTCue||t.window.VTTCue)(0,0,"");try{t.cue.align="center"}catch(e){t.cue.align="middle"}if(t.state="CUE",-1===i.indexOf("--\x3e")){t.cue.id=i;continue}case"CUE":try{u(i,t.cue,t.regionList)}catch(e){t.reportOrThrowError(e),t.cue=null,t.state="BADCUE";continue}t.state="CUETEXT";continue;case"CUETEXT":var p=-1!==i.indexOf("--\x3e");if(!i||p&&(f=!0)){t.oncue&&t.oncue(t.cue),t.cue=null,t.state="ID";continue}t.cue.text&&(t.cue.text+="\n"),t.cue.text+=i.replace(/\u2028/g,"\n").replace(/u2029/g,"\n");continue;case"BADCUE":i||(t.state="ID");continue}}}catch(e){t.reportOrThrowError(e),"CUETEXT"===t.state&&t.cue&&t.oncue&&t.oncue(t.cue),t.cue=null,t.state="INITIAL"===t.state?"BADWEBVTT":"BADCUE"}return this},flush:function(){try{if(this.buffer+=this.decoder.decode(),(this.cue||"HEADER"===this.state)&&(this.buffer+="\n\n",this.parse()),"INITIAL"===this.state)throw new o(o.Errors.BadSignature)}catch(e){this.reportOrThrowError(e)}return this.onflush&&this.onflush(),this}},e.exports=T},function(e,t){},function(e,t){var n={"":1,lr:1,rl:1},r={start:1,center:1,end:1,left:1,right:1,auto:1,"line-left":1,"line-right":1};function i(e){return"string"==typeof e&&(!!r[e.toLowerCase()]&&e.toLowerCase())}function o(e,t,r){this.hasBeenReset=!1;var o="",a=!1,s=e,c=t,u=r,l=null,f="",p=!0,d="auto",h="start",y="auto",m="auto",v=100,g="center";Object.defineProperties(this,{id:{enumerable:!0,get:function(){return o},set:function(e){o=""+e}},pauseOnExit:{enumerable:!0,get:function(){return a},set:function(e){a=!!e}},startTime:{enumerable:!0,get:function(){return s},set:function(e){if("number"!=typeof e)throw new TypeError("Start time must be set to a number.");s=e,this.hasBeenReset=!0}},endTime:{enumerable:!0,get:function(){return c},set:function(e){if("number"!=typeof e)throw new TypeError("End time must be set to a number.");c=e,this.hasBeenReset=!0}},text:{enumerable:!0,get:function(){return u},set:function(e){u=""+e,this.hasBeenReset=!0}},region:{enumerable:!0,get:function(){return l},set:function(e){l=e,this.hasBeenReset=!0}},vertical:{enumerable:!0,get:function(){return f},set:function(e){var t=function(e){return"string"==typeof e&&(!!n[e.toLowerCase()]&&e.toLowerCase())}(e);if(!1===t)throw new SyntaxError("Vertical: an invalid or illegal direction string was specified.");f=t,this.hasBeenReset=!0}},snapToLines:{enumerable:!0,get:function(){return p},set:function(e){p=!!e,this.hasBeenReset=!0}},line:{enumerable:!0,get:function(){return d},set:function(e){if("number"!=typeof e&&"auto"!==e)throw new SyntaxError("Line: an invalid number or illegal string was specified.");d=e,this.hasBeenReset=!0}},lineAlign:{enumerable:!0,get:function(){return h},set:function(e){var t=i(e);t?(h=t,this.hasBeenReset=!0):console.warn("lineAlign: an invalid or illegal string was specified.")}},position:{enumerable:!0,get:function(){return y},set:function(e){if(e<0||e>100)throw new Error("Position must be between 0 and 100.");y=e,this.hasBeenReset=!0}},positionAlign:{enumerable:!0,get:function(){return m},set:function(e){var t=i(e);t?(m=t,this.hasBeenReset=!0):console.warn("positionAlign: an invalid or illegal string was specified.")}},size:{enumerable:!0,get:function(){return v},set:function(e){if(e<0||e>100)throw new Error("Size must be between 0 and 100.");v=e,this.hasBeenReset=!0}},align:{enumerable:!0,get:function(){return g},set:function(e){var t=i(e);if(!t)throw new SyntaxError("align: an invalid or illegal alignment string was specified.");g=t,this.hasBeenReset=!0}}}),this.displayState=void 0}o.prototype.getCueAsHTML=function(){return WebVTT.convertCueToDOMTree(window,this.text)},e.exports=o},function(e,t){var n={"":!0,up:!0};function r(e){return"number"==typeof e&&e>=0&&e<=100}e.exports=function(){var e=100,t=3,i=0,o=100,a=0,s=100,c="";Object.defineProperties(this,{width:{enumerable:!0,get:function(){return e},set:function(t){if(!r(t))throw new Error("Width must be between 0 and 100.");e=t}},lines:{enumerable:!0,get:function(){return t},set:function(e){if("number"!=typeof e)throw new TypeError("Lines must be set to a number.");t=e}},regionAnchorY:{enumerable:!0,get:function(){return o},set:function(e){if(!r(e))throw new Error("RegionAnchorX must be between 0 and 100.");o=e}},regionAnchorX:{enumerable:!0,get:function(){return i},set:function(e){if(!r(e))throw new Error("RegionAnchorY must be between 0 and 100.");i=e}},viewportAnchorY:{enumerable:!0,get:function(){return s},set:function(e){if(!r(e))throw new Error("ViewportAnchorY must be between 0 and 100.");s=e}},viewportAnchorX:{enumerable:!0,get:function(){return a},set:function(e){if(!r(e))throw new Error("ViewportAnchorX must be between 0 and 100.");a=e}},scroll:{enumerable:!0,get:function(){return c},set:function(e){var t=function(e){return"string"==typeof e&&(!!n[e.toLowerCase()]&&e.toLowerCase())}(e);!1===t?console.warn("Scroll: an invalid or illegal string was specified."):c=t}}})}},function(e,t){e.exports=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){var r,i,o,a,s;r=/^((?:[a-zA-Z0-9+\-.]+:)?)(\/\/[^\/?#]*)?((?:[^\/?#]*\/)*[^;?#]*)?(;[^?#]*)?(\?[^#]*)?(#.*)?$/,i=/^([^\/?#]*)(.*)$/,o=/(?:\/|^)\.(?=\/)/g,a=/(?:\/|^)\.\.\/(?!\.\.\/)[^\/]*(?=\/)/g,s={buildAbsoluteURL:function(e,t,n){if(n=n||{},e=e.trim(),!(t=t.trim())){if(!n.alwaysNormalize)return e;var r=s.parseURL(e);if(!r)throw new Error("Error trying to parse base URL.");return r.path=s.normalizePath(r.path),s.buildURLFromParts(r)}var o=s.parseURL(t);if(!o)throw new Error("Error trying to parse relative URL.");if(o.scheme)return n.alwaysNormalize?(o.path=s.normalizePath(o.path),s.buildURLFromParts(o)):t;var a=s.parseURL(e);if(!a)throw new Error("Error trying to parse base URL.");if(!a.netLoc&&a.path&&"/"!==a.path[0]){var c=i.exec(a.path);a.netLoc=c[1],a.path=c[2]}a.netLoc&&!a.path&&(a.path="/");var u={scheme:a.scheme,netLoc:o.netLoc,path:null,params:o.params,query:o.query,fragment:o.fragment};if(!o.netLoc&&(u.netLoc=a.netLoc,"/"!==o.path[0]))if(o.path){var l=a.path,f=l.substring(0,l.lastIndexOf("/")+1)+o.path;u.path=s.normalizePath(f)}else u.path=a.path,o.params||(u.params=a.params,o.query||(u.query=a.query));return null===u.path&&(u.path=n.alwaysNormalize?s.normalizePath(o.path):o.path),s.buildURLFromParts(u)},parseURL:function(e){var t=r.exec(e);return t?{scheme:t[1]||"",netLoc:t[2]||"",path:t[3]||"",params:t[4]||"",query:t[5]||"",fragment:t[6]||""}:null},normalizePath:function(e){for(e=e.split("").reverse().join("").replace(o,"");e.length!==(e=e.replace(a,"")).length;);return e.split("").reverse().join("")},buildURLFromParts:function(e){return e.scheme+e.netLoc+e.path+e.params+e.query+e.fragment}},e.exports=s},function(e,t,n){"use strict";t.byteLength=function(e){var t=u(e),n=t[0],r=t[1];return 3*(n+r)/4-r},t.toByteArray=function(e){var t,n,r=u(e),a=r[0],s=r[1],c=new o(function(e,t,n){return 3*(t+n)/4-n}(0,a,s)),l=0,f=s>0?a-4:a;for(n=0;n<f;n+=4)t=i[e.charCodeAt(n)]<<18|i[e.charCodeAt(n+1)]<<12|i[e.charCodeAt(n+2)]<<6|i[e.charCodeAt(n+3)],c[l++]=t>>16&255,c[l++]=t>>8&255,c[l++]=255&t;2===s&&(t=i[e.charCodeAt(n)]<<2|i[e.charCodeAt(n+1)]>>4,c[l++]=255&t);1===s&&(t=i[e.charCodeAt(n)]<<10|i[e.charCodeAt(n+1)]<<4|i[e.charCodeAt(n+2)]>>2,c[l++]=t>>8&255,c[l++]=255&t);return c},t.fromByteArray=function(e){for(var t,n=e.length,i=n%3,o=[],a=0,s=n-i;a<s;a+=16383)o.push(l(e,a,a+16383>s?s:a+16383));1===i?(t=e[n-1],o.push(r[t>>2]+r[t<<4&63]+"==")):2===i&&(t=(e[n-2]<<8)+e[n-1],o.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return o.join("")};for(var r=[],i=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,c=a.length;s<c;++s)r[s]=a[s],i[a.charCodeAt(s)]=s;function u(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function l(e,t,n){for(var i,o,a=[],s=t;s<n;s+=3)i=(e[s]<<16&16711680)+(e[s+1]<<8&65280)+(255&e[s+2]),a.push(r[(o=i)>>18&63]+r[o>>12&63]+r[o>>6&63]+r[63&o]);return a.join("")}i["-".charCodeAt(0)]=62,i["_".charCodeAt(0)]=63},function(e,t){
|
|
47
47
|
/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
48
48
|
t.read=function(e,t,n,r,i){var o,a,s=8*i-r-1,c=(1<<s)-1,u=c>>1,l=-7,f=n?i-1:0,p=n?-1:1,d=e[t+f];for(f+=p,o=d&(1<<-l)-1,d>>=-l,l+=s;l>0;o=256*o+e[t+f],f+=p,l-=8);for(a=o&(1<<-l)-1,o>>=-l,l+=r;l>0;a=256*a+e[t+f],f+=p,l-=8);if(0===o)o=1-u;else{if(o===c)return a?NaN:1/0*(d?-1:1);a+=Math.pow(2,r),o-=u}return(d?-1:1)*a*Math.pow(2,o-r)},t.write=function(e,t,n,r,i,o){var a,s,c,u=8*o-i-1,l=(1<<u)-1,f=l>>1,p=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,d=r?0:o-1,h=r?1:-1,y=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=l):(a=Math.floor(Math.log(t)/Math.LN2),t*(c=Math.pow(2,-a))<1&&(a--,c*=2),(t+=a+f>=1?p/c:p*Math.pow(2,1-f))*c>=2&&(a++,c/=2),a+f>=l?(s=0,a=l):a+f>=1?(s=(t*c-1)*Math.pow(2,i),a+=f):(s=t*Math.pow(2,f-1)*Math.pow(2,i),a=0));i>=8;e[n+d]=255&s,d+=h,s/=256,i-=8);for(a=a<<i|s,u+=i;u>0;e[n+d]=255&a,d+=h,a/=256,u-=8);e[n+d-h]|=128*y}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t){var n=/[A-Z_a-z\xC0-\xD6\xD8-\xF6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,r=new RegExp("[\\-\\.0-9"+n.source.slice(1,-1)+"\\u00B7\\u0300-\\u036F\\u203F-\\u2040]"),i=new RegExp("^"+n.source+r.source+"*(?::"+n.source+r.source+"*)?$");function o(){}function a(e,t){return t.lineNumber=e.lineNumber,t.columnNumber=e.columnNumber,t}function s(e,t,n,r,i,o){for(var a,s=++t,c=0;;){var u=e.charAt(s);switch(u){case"=":if(1===c)a=e.slice(t,s),c=3;else{if(2!==c)throw new Error("attribute equal must after attrName");c=3}break;case"'":case'"':if(3===c||1===c){if(1===c&&(o.warning('attribute value must after "="'),a=e.slice(t,s)),t=s+1,!((s=e.indexOf(u,t))>0))throw new Error("attribute value no end '"+u+"' match");l=e.slice(t,s).replace(/&#?\w+;/g,i),n.add(a,l,t-1),c=5}else{if(4!=c)throw new Error('attribute value must after "="');l=e.slice(t,s).replace(/&#?\w+;/g,i),n.add(a,l,t),o.warning('attribute "'+a+'" missed start quot('+u+")!!"),t=s+1,c=5}break;case"/":switch(c){case 0:n.setTagName(e.slice(t,s));case 5:case 6:case 7:c=7,n.closed=!0;case 4:case 1:case 2:break;default:throw new Error("attribute invalid close char('/')")}break;case"":return o.error("unexpected end of input"),0==c&&n.setTagName(e.slice(t,s)),s;case">":switch(c){case 0:n.setTagName(e.slice(t,s));case 5:case 6:case 7:break;case 4:case 1:"/"===(l=e.slice(t,s)).slice(-1)&&(n.closed=!0,l=l.slice(0,-1));case 2:2===c&&(l=a),4==c?(o.warning('attribute "'+l+'" missed quot(")!!'),n.add(a,l.replace(/&#?\w+;/g,i),t)):("http://www.w3.org/1999/xhtml"===r[""]&&l.match(/^(?:disabled|checked|selected)$/i)||o.warning('attribute "'+l+'" missed value!! "'+l+'" instead!!'),n.add(l,l,t));break;case 3:throw new Error("attribute value missed!!")}return s;case"":u=" ";default:if(u<=" ")switch(c){case 0:n.setTagName(e.slice(t,s)),c=6;break;case 1:a=e.slice(t,s),c=2;break;case 4:var l=e.slice(t,s).replace(/&#?\w+;/g,i);o.warning('attribute "'+l+'" missed quot(")!!'),n.add(a,l,t);case 5:c=6}else switch(c){case 2:n.tagName;"http://www.w3.org/1999/xhtml"===r[""]&&a.match(/^(?:disabled|checked|selected)$/i)||o.warning('attribute "'+a+'" missed value!! "'+a+'" instead2!!'),n.add(a,a,t),t=s,c=1;break;case 5:o.warning('attribute space is required"'+a+'"!!');case 6:c=1,t=s;break;case 3:c=4,t=s;break;case 7:throw new Error("elements closed character '/' and '>' must be connected to")}}s++}}function c(e,t,n){for(var r=e.tagName,i=null,o=e.length;o--;){var a=e[o],s=a.qName,c=a.value;if((d=s.indexOf(":"))>0)var u=a.prefix=s.slice(0,d),l=s.slice(d+1),p="xmlns"===u&&l;else l=s,u=null,p="xmlns"===s&&"";a.localName=l,!1!==p&&(null==i&&(i={},f(n,n={})),n[p]=i[p]=c,a.uri="http://www.w3.org/2000/xmlns/",t.startPrefixMapping(p,c))}for(o=e.length;o--;){(u=(a=e[o]).prefix)&&("xml"===u&&(a.uri="http://www.w3.org/XML/1998/namespace"),"xmlns"!==u&&(a.uri=n[u||""]))}var d;(d=r.indexOf(":"))>0?(u=e.prefix=r.slice(0,d),l=e.localName=r.slice(d+1)):(u=null,l=e.localName=r);var h=e.uri=n[u||""];if(t.startElement(h,l,r,e),!e.closed)return e.currentNSMap=n,e.localNSMap=i,!0;if(t.endElement(h,l,r),i)for(u in i)t.endPrefixMapping(u)}function u(e,t,n,r,i){if(/^(?:script|textarea)$/i.test(n)){var o=e.indexOf("</"+n+">",t),a=e.substring(t+1,o);if(/[&<]/.test(a))return/^script$/i.test(n)?(i.characters(a,0,a.length),o):(a=a.replace(/&#?\w+;/g,r),i.characters(a,0,a.length),o)}return t+1}function l(e,t,n,r){var i=r[n];return null==i&&((i=e.lastIndexOf("</"+n+">"))<t&&(i=e.lastIndexOf("</"+n)),r[n]=i),i<t}function f(e,t){for(var n in e)t[n]=e[n]}function p(e,t,n,r){switch(e.charAt(t+2)){case"-":return"-"===e.charAt(t+3)?(i=e.indexOf("--\x3e",t+4))>t?(n.comment(e,t+4,i-t-4),i+3):(r.error("Unclosed comment"),-1):-1;default:if("CDATA["==e.substr(t+3,6)){var i=e.indexOf("]]>",t+9);return n.startCDATA(),n.characters(e,t+9,i-t-9),n.endCDATA(),i+3}var o=function(e,t){var n,r=[],i=/'[^']+'|"[^"]+"|[^\s<>\/=]+=?|(\/?\s*>|<)/g;i.lastIndex=t,i.exec(e);for(;n=i.exec(e);)if(r.push(n),n[1])return r}(e,t),a=o.length;if(a>1&&/!doctype/i.test(o[0][0])){var s=o[1][0],c=a>3&&/^public$/i.test(o[2][0])&&o[3][0],u=a>4&&o[4][0],l=o[a-1];return n.startDTD(s,c&&c.replace(/^(['"])(.*?)\1$/,"$2"),u&&u.replace(/^(['"])(.*?)\1$/,"$2")),n.endDTD(),l.index+l[0].length}}return-1}function d(e,t,n){var r=e.indexOf("?>",t);if(r){var i=e.substring(t,r).match(/^<\?(\S*)\s*([\s\S]*?)\s*$/);if(i){i[0].length;return n.processingInstruction(i[1],i[2]),r+2}return-1}return-1}function h(e){}function y(e,t){return e.__proto__=t,e}o.prototype={parse:function(e,t,n){var r=this.domBuilder;r.startDocument(),f(t,t={}),function(e,t,n,r,i){function o(e){var t=e.slice(1,-1);return t in n?n[t]:"#"===t.charAt(0)?function(e){if(e>65535){var t=55296+((e-=65536)>>10),n=56320+(1023&e);return String.fromCharCode(t,n)}return String.fromCharCode(e)}(parseInt(t.substr(1).replace("x","0x"))):(i.error("entity not found:"+e),e)}function f(t){if(t>S){var n=e.substring(S,t).replace(/&#?\w+;/g,o);b&&y(S),r.characters(n,0,t-S),S=t}}function y(t,n){for(;t>=v&&(n=g.exec(e));)m=n.index,v=m+n[0].length,b.lineNumber++;b.columnNumber=t-m+1}var m=0,v=0,g=/.*(?:\r\n?|\n)|.*$/g,b=r.locator,w=[{currentNSMap:t}],_={},S=0;for(;;){try{var T=e.indexOf("<",S);if(T<0){if(!e.substr(S).match(/^\s*$/)){var C=r.doc,E=C.createTextNode(e.substr(S));C.appendChild(E),r.currentElement=E}return}switch(T>S&&f(T),e.charAt(T+1)){case"/":var k=e.indexOf(">",T+3),O=e.substring(T+2,k),P=w.pop();k<0?(O=e.substring(T+2).replace(/[\s<].*/,""),i.error("end tag name: "+O+" is not complete:"+P.tagName),k=T+1+O.length):O.match(/\s</)&&(O=O.replace(/[\s<].*/,""),i.error("end tag name: "+O+" maybe not complete"),k=T+1+O.length);var A=P.localNSMap,I=P.tagName==O;if(I||P.tagName&&P.tagName.toLowerCase()==O.toLowerCase()){if(r.endElement(P.uri,P.localName,O),A)for(var x in A)r.endPrefixMapping(x);I||i.fatalError("end tag name: "+O+" is not match the current start tagName:"+P.tagName)}else w.push(P);k++;break;case"?":b&&y(T),k=d(e,T,r);break;case"!":b&&y(T),k=p(e,T,r,i);break;default:b&&y(T);var R=new h,L=w[w.length-1].currentNSMap,j=(k=s(e,T,R,L,o,i),R.length);if(!R.closed&&l(e,k,R.tagName,_)&&(R.closed=!0,n.nbsp||i.warning("unclosed xml attribute")),b&&j){for(var N=a(b,{}),D=0;D<j;D++){var B=R[D];y(B.offset),B.locator=a(b,{})}r.locator=N,c(R,r,L)&&w.push(R),r.locator=b}else c(R,r,L)&&w.push(R);"http://www.w3.org/1999/xhtml"!==R.uri||R.closed?k++:k=u(e,k,R.tagName,o,r)}}catch(e){i.error("element parse error: "+e),k=-1}k>S?S=k:f(Math.max(T,S)+1)}}(e,t,n,r,this.errorHandler),r.endDocument()}},h.prototype={setTagName:function(e){if(!i.test(e))throw new Error("invalid tagName:"+e);this.tagName=e},add:function(e,t,n){if(!i.test(e))throw new Error("invalid attribute:"+e);this[this.length++]={qName:e,value:t,offset:n}},length:0,getLocalName:function(e){return this[e].localName},getLocator:function(e){return this[e].locator},getQName:function(e){return this[e].qName},getURI:function(e){return this[e].uri},getValue:function(e){return this[e].value}},y({},y.prototype)instanceof y||(y=function(e,t){function n(){}for(t in n.prototype=t,n=new n,e)n[t]=e[t];return n}),t.XMLReader=o},function(e,t,n){"use strict";var r=n(793),i=function(e,t){var n=1;for(e>t&&(n=-1);Math.abs(t-e)>4294967296;)e+=8589934592*n;return e},o=function(e){var t,n;o.prototype.init.call(this),this.type_=e||"shared",this.push=function(e){"shared"!==this.type_&&e.type!==this.type_||(void 0===n&&(n=e.dts),e.dts=i(e.dts,n),e.pts=i(e.pts,n),t=e.dts,this.trigger("data",e))},this.flush=function(){n=t,this.trigger("done")},this.endTimeline=function(){this.flush(),this.trigger("endedtimeline")},this.discontinuity=function(){n=void 0,t=void 0},this.reset=function(){this.discontinuity(),this.trigger("reset")}};o.prototype=new r,e.exports={TimestampRolloverStream:o,handleRollover:i}},function(e,t,n){"use strict";var r=function(){this.init=function(){var e={};this.on=function(t,n){e[t]||(e[t]=[]),e[t]=e[t].concat(n)},this.off=function(t,n){var r;return!!e[t]&&(r=e[t].indexOf(n),e[t]=e[t].slice(),e[t].splice(r,1),r>-1)},this.trigger=function(t){var n,r,i,o;if(n=e[t])if(2===arguments.length)for(i=n.length,r=0;r<i;++r)n[r].call(this,arguments[1]);else{for(o=[],r=arguments.length,r=1;r<arguments.length;++r)o.push(arguments[r]);for(i=n.length,r=0;r<i;++r)n[r].apply(this,o)}},this.dispose=function(){e={}}}};r.prototype.pipe=function(e){return this.on("data",(function(t){e.push(t)})),this.on("done",(function(t){e.flush(t)})),this.on("partialdone",(function(t){e.partialFlush(t)})),this.on("endedtimeline",(function(t){e.endTimeline(t)})),this.on("reset",(function(t){e.reset(t)})),e},r.prototype.push=function(e){this.trigger("data",e)},r.prototype.flush=function(e){this.trigger("done",e)},r.prototype.partialFlush=function(e){this.trigger("partialdone",e)},r.prototype.endTimeline=function(e){this.trigger("endedtimeline",e)},r.prototype.reset=function(e){this.trigger("reset",e)},e.exports=r},function(e,t,n){"use strict";var r=n(552),i=function(e){var t=31&e[1];return t<<=8,t|=e[2]},o=function(e){return!!(64&e[1])},a=function(e){var t=0;return(48&e[3])>>>4>1&&(t+=e[4]+1),t},s=function(e){switch(e){case 5:return"slice_layer_without_partitioning_rbsp_idr";case 6:return"sei_rbsp";case 7:return"seq_parameter_set_rbsp";case 8:return"pic_parameter_set_rbsp";case 9:return"access_unit_delimiter_rbsp";default:return null}};e.exports={parseType:function(e,t){var n=i(e);return 0===n?"pat":n===t?"pmt":t?"pes":null},parsePat:function(e){var t=o(e),n=4+a(e);return t&&(n+=e[n]+1),(31&e[n+10])<<8|e[n+11]},parsePmt:function(e){var t={},n=o(e),r=4+a(e);if(n&&(r+=e[r]+1),1&e[r+5]){var i;i=3+((15&e[r+1])<<8|e[r+2])-4;for(var s=12+((15&e[r+10])<<8|e[r+11]);s<i;){var c=r+s;t[(31&e[c+1])<<8|e[c+2]]=e[c],s+=5+((15&e[c+3])<<8|e[c+4])}return t}},parsePayloadUnitStartIndicator:o,parsePesType:function(e,t){switch(t[i(e)]){case r.H264_STREAM_TYPE:return"video";case r.ADTS_STREAM_TYPE:return"audio";case r.METADATA_STREAM_TYPE:return"timed-metadata";default:return null}},parsePesTime:function(e){if(!o(e))return null;var t=4+a(e);if(t>=e.byteLength)return null;var n,r=null;return 192&(n=e[t+7])&&((r={}).pts=(14&e[t+9])<<27|(255&e[t+10])<<20|(254&e[t+11])<<12|(255&e[t+12])<<5|(254&e[t+13])>>>3,r.pts*=4,r.pts+=(6&e[t+13])>>>1,r.dts=r.pts,64&n&&(r.dts=(14&e[t+14])<<27|(255&e[t+15])<<20|(254&e[t+16])<<12|(255&e[t+17])<<5|(254&e[t+18])>>>3,r.dts*=4,r.dts+=(6&e[t+18])>>>1)),r},videoPacketContainsKeyFrame:function(e){for(var t=4+a(e),n=e.subarray(t),r=0,i=0,o=!1;i<n.byteLength-3;i++)if(1===n[i+2]){r=i+5;break}for(;r<n.byteLength;)switch(n[r]){case 0:if(0!==n[r-1]){r+=2;break}if(0!==n[r-2]){r++;break}i+3!==r-2&&"slice_layer_without_partitioning_rbsp_idr"===s(31&n[i+3])&&(o=!0);do{r++}while(1!==n[r]&&r<n.length);i=r-2,r+=3;break;case 1:if(0!==n[r-1]||0!==n[r-2]){r+=3;break}"slice_layer_without_partitioning_rbsp_idr"===s(31&n[i+3])&&(o=!0),i=r-2,r+=3;break;default:r+=3}return n=n.subarray(i),r-=i,i=0,n&&n.byteLength>3&&"slice_layer_without_partitioning_rbsp_idr"===s(31&n[i+3])&&(o=!0),o}}},function(e,t,n){"use strict";var r=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350],i=function(e,t){var n=e[t+6]<<21|e[t+7]<<14|e[t+8]<<7|e[t+9];return n=n>=0?n:0,(16&e[t+5])>>4?n+20:n+10},o=function(e,t){return e.length-t<10||e[t]!=="I".charCodeAt(0)||e[t+1]!=="D".charCodeAt(0)||e[t+2]!=="3".charCodeAt(0)?t:(t+=i(e,t),o(e,t))},a=function(e){return e[0]<<21|e[1]<<14|e[2]<<7|e[3]};e.exports={isLikelyAacData:function(e){var t=o(e,0);return e.length>=t+2&&255==(255&e[t])&&240==(240&e[t+1])&&16==(22&e[t+1])},parseId3TagSize:i,parseAdtsSize:function(e,t){var n=(224&e[t+5])>>5,r=e[t+4]<<3;return 6144&e[t+3]|r|n},parseType:function(e,t){return e[t]==="I".charCodeAt(0)&&e[t+1]==="D".charCodeAt(0)&&e[t+2]==="3".charCodeAt(0)?"timed-metadata":!0&e[t]&&240==(240&e[t+1])?"audio":null},parseSampleRate:function(e){for(var t=0;t+5<e.length;){if(255===e[t]&&240==(246&e[t+1]))return r[(60&e[t+2])>>>2];t++}return null},parseAacTimestamp:function(e){var t,n,r;t=10,64&e[5]&&(t+=4,t+=a(e.subarray(10,14)));do{if((n=a(e.subarray(t+4,t+8)))<1)return null;if("PRIV"===String.fromCharCode(e[t],e[t+1],e[t+2],e[t+3])){r=e.subarray(t+10,t+n+10);for(var i=0;i<r.byteLength;i++)if(0===r[i]){if("com.apple.streaming.transportStreamTimestamp"===unescape(function(e,t,n){var r,i="";for(r=t;r<n;r++)i+="%"+("00"+e[r].toString(16)).slice(-2);return i}(r,0,i))){var o=r.subarray(i+1),s=(1&o[3])<<30|o[4]<<22|o[5]<<14|o[6]<<6|o[7]>>>2;return s*=4,s+=3&o[7]}break}}t+=10,t+=n}while(t<e.byteLength);return null}}},function(e,t,n){var r=n(268).toUnsigned,i=n(553),o=function(e,t){var n,a,s,c,u,l=[];if(!t.length)return null;for(n=0;n<e.byteLength;)a=r(e[n]<<24|e[n+1]<<16|e[n+2]<<8|e[n+3]),s=i(e.subarray(n+4,n+8)),c=a>1?n+a:e.byteLength,s===t[0]&&(1===t.length?l.push(e.subarray(n+8,c)):(u=o(e.subarray(n+8,c),t.slice(1))).length&&(l=l.concat(u))),n=c;return l};e.exports=o},function(e,t){e.exports=function(e){var t,n=new DataView(e.buffer,e.byteOffset,e.byteLength),r={version:e[0],flags:new Uint8Array(e.subarray(1,4)),trackId:n.getUint32(4)},i=1&r.flags[2],o=2&r.flags[2],a=8&r.flags[2],s=16&r.flags[2],c=32&r.flags[2],u=65536&r.flags[0],l=131072&r.flags[0];return t=8,i&&(t+=4,r.baseDataOffset=n.getUint32(12),t+=4),o&&(r.sampleDescriptionIndex=n.getUint32(t),t+=4),a&&(r.defaultSampleDuration=n.getUint32(t),t+=4),s&&(r.defaultSampleSize=n.getUint32(t),t+=4),c&&(r.defaultSampleFlags=n.getUint32(t)),u&&(r.durationIsEmpty=!0),!i&&l&&(r.baseDataOffsetIsMoof=!0),r}},function(e,t,n){var r=n(799);e.exports=function(e){var t,n={version:e[0],flags:new Uint8Array(e.subarray(1,4)),samples:[]},i=new DataView(e.buffer,e.byteOffset,e.byteLength),o=1&n.flags[2],a=4&n.flags[2],s=1&n.flags[1],c=2&n.flags[1],u=4&n.flags[1],l=8&n.flags[1],f=i.getUint32(4),p=8;for(o&&(n.dataOffset=i.getInt32(p),p+=4),a&&f&&(t={flags:r(e.subarray(p,p+4))},p+=4,s&&(t.duration=i.getUint32(p),p+=4),c&&(t.size=i.getUint32(p),p+=4),l&&(1===n.version?t.compositionTimeOffset=i.getInt32(p):t.compositionTimeOffset=i.getUint32(p),p+=4),n.samples.push(t),f--);f--;)t={},s&&(t.duration=i.getUint32(p),p+=4),c&&(t.size=i.getUint32(p),p+=4),u&&(t.flags=r(e.subarray(p,p+4)),p+=4),l&&(1===n.version?t.compositionTimeOffset=i.getInt32(p):t.compositionTimeOffset=i.getUint32(p),p+=4),n.samples.push(t);return n}},function(e,t){e.exports=function(e){return{isLeading:(12&e[0])>>>2,dependsOn:3&e[0],isDependedOn:(192&e[1])>>>6,hasRedundancy:(48&e[1])>>>4,paddingValue:(14&e[1])>>>1,isNonSyncSample:1&e[1],degradationPriority:e[2]<<8|e[3]}}},function(e,t,n){var r=n(268).toUnsigned;e.exports=function(e){var t={version:e[0],flags:new Uint8Array(e.subarray(1,4)),baseMediaDecodeTime:r(e[4]<<24|e[5]<<16|e[6]<<8|e[7])};return 1===t.version&&(t.baseMediaDecodeTime*=Math.pow(2,32),t.baseMediaDecodeTime+=r(e[8]<<24|e[9]<<16|e[10]<<8|e[11])),t}},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,n){"use strict";n.r(t);n(768),n(769),n(770);var r=n(3),i=n(11),o=n(26),a=n(65),s=n(0),c=n.n(s),u=n(12),l=n.n(u),f=n(287),p=n(30);function d(e){return(d="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)}function h(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function y(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function m(e,t){return(m=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=b(e);if(t){var i=b(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return g(this,n)}}function g(e,t){return!t||"object"!==d(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function b(e){return(b=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var w=function(e){!function(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}}),t&&m(e,t)}(o,e);var t,n,r,i=v(o);function o(){return h(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"onShowAlert",value:function(e){if(this.layoutOptions.options.alertRegion){var t=e.ctor,n=e.collection,r=n?n.toJSON():[];this.layout.showChildView(this.layoutOptions.options.alertRegion,s.createElement(t,{alerts:r,removeAlert:function(e){return u.Radio.channel(p.a.ALERT).trigger("remove:alert",e)}}))}}}])&&y(t.prototype,n),r&&y(t,r),o}(f.a),_="content",S="popup",T="alert",C="hidden",E=n(2),k="TeacherLayout",O="SimpleLayout",P=n(5),A=n(343),I=n.n(A),x=n(359),R=n(7),L=n(362),j=!0,N=function(){return j},D=function(){j=!1},B=[{application:P.a.SUBJECT,action:R.a.Subjects.ONBOARDING},{application:P.a.SUBJECT,action:R.a.Subjects.ONBOARDING_WELCOME},{application:P.a.SUBJECT,action:R.a.Subjects.ONBOARDING_TOPIC_PRESENTATION},{application:P.a.SUBJECT,action:R.a.Subjects.ONBOARDING_CURRICULUM_PRESENTATION},{application:P.a.SUBJECT,action:R.a.Subjects.ONBOARDING_LEVELS},{application:P.a.SUBJECT,action:R.a.Subjects.ONBOARDING_TOPICS},{application:P.a.SUBJECT,action:R.a.Subjects.ONBOARDING_SUMMARY}],U=[{application:P.a.DEFAULT,action:R.a.Default.NOT_FOUND},{application:P.a.DEFAULT,action:R.a.Default.ERROR}];function M(e,t){!function(e,t){var n=e.appLink,r=e.shell;if(U.find((function(e){return e.application===(null==n?void 0:n.application)&&e.action===(null==n?void 0:n.action)})))return void t(!1);i.a.hooklessFetch(r.store,o.a.currentUser((function(e){e.isAuthenticated?i.a.hooklessFetch(r.store,o.a.permissions((function(n){n[a.a.ManageSubjectPreferences]&&I.a.get("_onboardingComplete")!==e.id.toString()?i.a.hooklessFetch(r.store,L.a.setting(e.id,x.a.HasCompletedOnboarding,(function(n){if(n.value)return I.a.set("_onboardingComplete",e.id,{expires:30}),void t(!1);t(!0)}),(function(){t(!1)}))):t(!1)}),(function(){t(!1)}))):t(!1)}),(function(){t(!1)})))}(e,(function(n){return n?(D(),B.find((function(t){var n,r;return t.application,null===(n=e.appLink)||void 0===n||n.application,t.action===(null===(r=e.appLink)||void 0===r?void 0:r.action)}))?t(e):(r.a.AppLinkHelper.trigger({application:P.a.SUBJECT,action:R.a.Subjects.ONBOARDING_WELCOME}),void r.a.AppLinkUtility.routingEnded())):B.find((function(t){var n,r;return t.application,null===(n=e.appLink)||void 0===n||n.application,t.action===(null===(r=e.appLink)||void 0===r?void 0:r.action)}))?(r.a.AppLinkHelper.trigger({application:P.a.SETTINGS,action:R.a.Settings.TOPIC_PREFERENCES}),void r.a.AppLinkUtility.routingEnded()):void t(e)}))}var V,F=n(112),H=n(91),z=function(e,t){return{url:"{gateway}/v1/users/me/products",key:"user:products",normalizeOptions:{namespace:"product"},success:e,error:t}},W=n(73);!function(e){e.Analytics="analytics",e.LibraryEditor="manage",e.Online="online",e.OnlineAnalytics="online_analytics",e.Primary="lite"}(V||(V={}));var q=n(74),G=n(8);function K(e){return(K="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)}function Y(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function X(e,t){return(X=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Q(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=J(e);if(t){var i=J(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Z(this,n)}}function Z(e,t){return!t||"object"!==K(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function J(e){return(J=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var ee="liteShared.noAccess",te=function(e){!function(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}}),t&&X(e,t)}(o,e);var t,n,r,i=Q(o);function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,"Current user's school does not have access to the primary product")}return t=o,(n=[{key:"name",get:function(){return"NoAccessError"}},{key:"heading",get:function(){return G.a.getPhrase(ee,"heading")}},{key:"description",get:function(){return G.a.getPhrase(ee,"body")}},{key:"cta",get:function(){return!1}}])&&Y(t.prototype,n),r&&Y(t,r),o}(q.a),ne=[{application:P.a.DEFAULT,action:R.a.Default.ERROR},{application:P.a.DEFAULT,action:R.a.Default.DEV_ERROR}];function re(e,t){W.a._forcePushContext(e),D(),r.a.AppLinkUtility.routingEnded(),r.a.ErrorHelper.throw(null!=t?t:new H.a)}function ie(e,t){var n=e.appLink,r=e.shell;F.a.isDevelopment||ne.find((function(e){return e.application===(null==n?void 0:n.application)&&e.action===(null==n?void 0:n.action)}))?t(e):i.a.hooklessFetch(r.store,z((function(r){r.find((function(e){return e.id===V.Primary}))?t(e):re(n,new te)}),(function(){return re(n)})))}var oe=n(28),ae=n(207),se=n(38),ce=n(61),ue=n(51),le=n(17),fe=n(183);function pe(e){return(pe="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)}function de(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function he(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ye(e,t){return(ye=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function me(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ge(e);if(t){var i=ge(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ve(this,n)}}function ve(e,t){return!t||"object"!==pe(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function ge(e){return(ge=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var be=function(e){!function(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}}),t&&ye(e,t)}(o,e);var t,n,r,i=me(o);function o(){return de(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"enrich",value:function(e,t){}},{key:"isType",value:function(e){return e===o.type}}])&&he(t.prototype,n),r&&he(t,r),o}(r.a.Service);function we(e){return(we="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)}function _e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Se(e,t){return(Se=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Te(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Ee(e);if(t){var i=Ee(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ce(this,n)}}function Ce(e,t){return!t||"object"!==we(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Ee(e){return(Ee=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}be.type="BaseAnalyticsEnricher";var ke=function(e){!function(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}}),t&&Se(e,t)}(o,e);var t,n,r,i=Te(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=i.call(this,e)).consumerKey=e.consumerKey,t}return t=o,(n=[{key:"name",get:function(){return"PluginEnricher"}},{key:"enrich",value:function(e,t){e.enrich("plugin",this.getPluginData()),t(e)}},{key:"getPluginData",value:function(){return{isPlugin:!0,consumerKey:this.consumerKey}}}])&&_e(t.prototype,n),r&&_e(t,r),o}(be);function Oe(e){return(Oe="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)}var Pe={application:P.a.DEFAULT,action:R.a.Default.PLUGIN},Ae={application:P.a.DEFAULT,action:R.a.Default.PLAY_VIDEO},Ie={application:P.a.DEFAULT,action:R.a.Default.PLAY_CLIP},xe={application:P.a.INTERACTIVES,action:R.a.Interactives.VIEW_INTERACTIVE},Re={application:P.a.DEFAULT,action:R.a.Default.SHARE},Le=[Ae,Ie,xe,Re],je=[P.a.CLASSROOMS,P.a.USER_MANAGER,P.a.SETTINGS];function Ne(e,t){return e.application===(null==t?void 0:t.application)&&e.action===(null==t?void 0:t.action)}function De(e){if(Ne(e,Ae))return E.EntityType.Video;if(Ne(e,Ie))return E.EntityType.Clip;if(Ne(e,xe))return E.EntityType.Interactive;if(Ne(e,Re)){var t=Be(e.params);return null==t?void 0:t.entityType}r.a.ErrorHelper.throw(new oe.a("No derived share entity type found"))}function Be(e){return"object"===Oe(e)?e:ce.LocationUtils.DeserializeQueryParams(e)}function Ue(e){W.a._forcePushContext(e),r.a.AppLinkUtility.routingEnded(),r.a.AppLinkHelper.trigger(e,{replace:!0})}function Me(e,t){var n,r,i=e.appLink,o=e.shell,a=se.b.get(ue.a.PLUGIN);if(a&&Le.find((function(e){return Ne(e,i)})))Ue({application:P.a.DEFAULT,action:R.a.Default.PLUGIN_SHARE,args:[i.args[0]],params:{entityType:De(i)}});else if(a&&je.find((function(e){return e===i.application})))Ue({application:P.a.DEFAULT,action:R.a.Default.PLUGIN_NEW_WINDOW,params:{url:ce.AppLinkHelper.getHref(i)}});else{if(Ne(i,Pe)){var s=Be(i.params),c={isPlugin:!0,consumerKey:s.consumerKey,ltiReturnUrl:s.ltiReturnUrl,submitUrl:s.submitUrl,lmsType:s.lmsType,sizeSelector:!("false"==(null===(n=s.sizeSelector)||void 0===n?void 0:n.toLowerCase())),singleSelectMode:"true"==(null===(r=s.singleSelectMode)||void 0===r?void 0:r.toLowerCase())};return o.store.dispatch({type:ae.a.UPDATE,payload:{viewModelKey:ue.a.PLUGIN,dataOrKey:c}}),se.b.set(ue.a.PLUGIN,c),function(e){if(e){var t=le.a.getInstance(fe.a.Analytics);t.hasEnricher(ke)||t.registerEnricher(ke,{consumerKey:e}),le.a.releaseInstance(fe.a.Analytics)}}(s.consumerKey),void Ue({application:P.a.DASHBOARD,action:R.a.Dashboard.HOME})}t(e)}}var Ve=[{application:P.a.LAUNCHPAD,action:R.a.Launchpad.LOGIN_LANDING},{application:P.a.DEFAULT,action:R.a.Default.ERROR},{application:P.a.EMBED,action:R.a.Embed.EMBED_ERROR},{application:P.a.SHARE,action:R.a.Share.VIEW_SHARE_LINK},{application:P.a.SHARE,action:R.a.Share.SHARE_LINK_ERROR},{application:P.a.EMBED,action:R.a.Embed.VIEW_EMBEDDED_RESOURCE},{application:P.a.LAUNCHPAD,action:R.a.Launchpad.PASSWORD_PROTECTED_SHARE_LINK},{application:P.a.LAUNCHPAD,action:R.a.Launchpad.SHARE_LINK_SIGN_IN},{application:P.a.EMBED,action:R.a.Embed.EMBED_LOGIN},{application:P.a.EMBED,action:R.a.Embed.PLUGIN_LOGIN},{application:P.a.LAUNCHPAD,action:R.a.Launchpad.JOIN_CLASSROOM_PROMPT},{application:P.a.LAUNCHPAD,action:R.a.Launchpad.JOIN_CLASSROOM}].reduce((function(e,t){return e[Fe(t)]=!0,e}),{});function Fe(e){return e.application+e.action}function He(e,t){Ve[Fe(e.appLink)]?t(e):i.a.hooklessFetch(e.shell.store,o.a.currentUser((function(n){if(n.isAuthenticated)t(e);else{var i=e.appLink.params,o={};(null==i?void 0:i.customerId)&&(o.customerId=i.customerId),(null==i?void 0:i.skipPrompt)&&(o.skipPrompt=i.skipPrompt),"/"===ce.LocationUtils.GetCurrentPath()&&(o.showJoinCode=!0),r.a.AppLinkUtility.routingEnded(),r.a.AppLinkHelper.trigger({application:P.a.LAUNCHPAD,action:R.a.Launchpad.LOGIN_LANDING,params:o},{replace:!0})}}),(function(){return t=e.appLink,W.a._forcePushContext(t),D(),r.a.AppLinkUtility.routingEnded(),void r.a.ErrorHelper.throw(new H.a);var t})))}function ze(e){return(ze="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)}function We(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function qe(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ge(e,t,n){return t&&qe(e.prototype,t),n&&qe(e,n),e}function Ke(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}}),t&&Ye(e,t)}function Ye(e,t){return(Ye=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Xe(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=$e(e);if(t){var i=$e(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Qe(this,n)}}function Qe(e,t){return!t||"object"!==ze(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function $e(e){return($e=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Ze=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{c(r.next(e))}catch(e){o(e)}}function s(e){try{c(r.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}c((r=r.apply(e,t||[])).next())}))},Je=function(e){Ke(n,e);var t=Xe(n);function n(){return We(this,n),t.apply(this,arguments)}return Ge(n,[{key:"channelName",get:function(){return P.a.CLASSROOMS}},{key:"appRoutes",get:function(){return{"classrooms(/)":"index","classrooms/:id":"classroom","classrooms/:id/manage":"manageClassroom","classrooms/:id/classroom-link":"generateJoinLink"}}},{key:"appLinks",get:function(){return["newClassroom","editClassroom","deleteClassroom","addStudents","removeStudents","newGroup","editGroup","deleteGroup","addStudentsChoices","addStudentsChoicesMethod","contactSchoolAdmin"]}},{key:"filters",get:function(){return[He,ie,M,Me]}}]),n}(r.a.AppRouter),et=function(e){Ke(r,e);var t=Xe(r);function r(){return We(this,r),t.apply(this,arguments)}return Ge(r,[{key:"name",get:function(){return"Classrooms Application"}},{key:"channelName",get:function(){return P.a.CLASSROOMS}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:!0,alertRegion:T}}}},{key:"index",value:function(){var e=this;Promise.all([n.e(5),n.e(46)]).then(n.bind(null,1977)).then((function(t){var n=t.ClassroomsView;e.layout.showChildView(_,c.a.createElement(n,null))}))}},{key:"classroom",value:function(e){var t=this;n.e(58).then(n.bind(null,1984)).then((function(n){var r=n.ClassroomView;t.layout.showChildView(_,c.a.createElement(r,{id:e}))}))}},{key:"manageClassroom",value:function(e,t){var r=this,i=t.tab;["students","groups"].includes(i)||(i="students"),n.e(38).then(n.bind(null,1970)).then((function(t){var n=t.ManageClassroomView;r.layout.showChildView(_,c.a.createElement(n,{id:e,activeTab:i}))}))}},{key:"newClassroom",value:function(){var e=this;Promise.all([n.e(1),n.e(2),n.e(89)]).then(n.bind(null,1898)).then((function(t){var n=t.CreateClassroomView,r={actionType:E.UserAction.Create,entity:E.EntityType.Classroom,workflowPhase:E.WorkflowPhase.Complete,location:E.LocationContext.Popup};e.layout.showChildView(S,c.a.createElement(n,{analyticsOptions:r,closePopup:function(){return e.layout.closePopup()}}))}))}},{key:"editClassroom",value:function(e){var t=this;Promise.all([n.e(1),n.e(2),n.e(90)]).then(n.bind(null,1899)).then((function(n){var r=n.EditClassroomView,i={actionType:E.UserAction.Edit,entity:E.EntityType.Classroom,workflowPhase:E.WorkflowPhase.Complete,location:E.LocationContext.Popup};t.layout.showChildView(S,c.a.createElement(r,{id:e,analyticsOptions:i,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"deleteClassroom",value:function(e){var t=this;n.e(131).then(n.bind(null,1900)).then((function(n){var r=n.DeleteClassroomView,i={actionType:E.UserAction.Delete,entity:E.EntityType.Classroom,workflowPhase:E.WorkflowPhase.Complete,location:E.LocationContext.Popup};t.layout.showChildView(S,c.a.createElement(r,{id:e,analyticsOptions:i,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"addStudents",value:function(e){var t=this;Promise.all([n.e(16),n.e(129)]).then(n.bind(null,1901)).then((function(n){var r=n.AddStudentsToClassroomView,i={actionType:E.UserAction.Associate,entity:E.EntityType.Classroom,location:E.LocationContext.Popup,descriptor:E.AssocDescriptor.User,workflowPhase:E.WorkflowPhase.Complete};t.layout.showChildView(S,c.a.createElement(r,{classroomId:e,closePopup:function(){return t.layout.closePopup()},analyticsOptions:i}))}))}},{key:"removeStudents",value:function(e,t){var r=this,i=t.studentIds;n.e(132).then(n.bind(null,1902)).then((function(t){var n=t.RemoveStudentsFromClassroomView,o={actionType:E.UserAction.Dissociate,entity:E.EntityType.Classroom,location:E.LocationContext.Popup,descriptor:E.AssocDescriptor.User,workflowPhase:E.WorkflowPhase.Complete};r.layout.showChildView(S,c.a.createElement(n,{classroomId:e,studentIds:i,closePopup:function(){return r.layout.closePopup()},analyticsOptions:o}))}))}},{key:"newGroup",value:function(e,t){var r=this,i=t.addStudents,o=void 0===i?[]:i;Promise.all([n.e(1),n.e(2),n.e(72)]).then(n.bind(null,1903)).then((function(t){var n=t.CreateClassroomGroupView,i={entity:E.EntityType.ClassroomGroup,location:E.LocationContext.Popup,workflowPhase:E.WorkflowPhase.Complete};r.layout.showChildView(S,c.a.createElement(n,{classroomId:e,studentIds:o,closePopup:function(){return r.layout.closePopup()},analyticsOptions:i}))}))}},{key:"editGroup",value:function(e,t){var r=this;Promise.all([n.e(1),n.e(2),n.e(73)]).then(n.bind(null,1904)).then((function(n){var i=n.EditClassroomGroupView,o={entity:E.EntityType.ClassroomGroup,actionType:E.UserAction.Edit,location:E.LocationContext.Popup,workflowPhase:E.WorkflowPhase.Complete};r.layout.showChildView(S,c.a.createElement(i,{classroomId:e,groupId:t,closePopup:function(){return r.layout.closePopup()},analyticsOptions:o}))}))}},{key:"deleteGroup",value:function(e,t){var r=this;n.e(130).then(n.bind(null,1905)).then((function(n){var i=n.DeleteClassroomGroupView,o={entity:E.EntityType.ClassroomGroup,actionType:E.UserAction.Delete,location:E.LocationContext.Popup,workflowPhase:E.WorkflowPhase.Complete};r.layout.showChildView(S,c.a.createElement(i,{classroomId:e,groupId:t,closePopup:function(){return r.layout.closePopup()},analyticsOptions:o}))}))}},{key:"generateJoinLink",value:function(e){return Ze(this,void 0,void 0,regeneratorRuntime.mark((function t(){var r,i;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,n.e(71).then(n.bind(null,1991));case 2:r=t.sent,i=r.GenerateJoinLinkView,this.layout.showChildView(_,c.a.createElement(i,{classroomId:e}));case 5:case"end":return t.stop()}}),t,this)})))}},{key:"addStudentsChoices",value:function(e){return Ze(this,void 0,void 0,regeneratorRuntime.mark((function t(){var r,i,o=this;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,n.e(111).then(n.bind(null,1906));case 2:r=t.sent,i=r.AddStudentsChoicesView,this.layout.showChildView(S,c.a.createElement(i,{classroomId:e,closePopup:function(){return o.layout.closePopup()}}));case 5:case"end":return t.stop()}}),t,this)})))}},{key:"addStudentsChoicesMethod",value:function(e){return Ze(this,void 0,void 0,regeneratorRuntime.mark((function t(){var r,i,o=this;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,n.e(110).then(n.bind(null,1907));case 2:r=t.sent,i=r.AddStudentsChoicesMethodView,this.layout.showChildView(S,c.a.createElement(i,{classroomId:e,closePopup:function(){return o.layout.closePopup()}}));case 5:case"end":return t.stop()}}),t,this)})))}},{key:"contactSchoolAdmin",value:function(e){return Ze(this,void 0,void 0,regeneratorRuntime.mark((function t(){var r,i,o=this;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,n.e(122).then(n.bind(null,1908));case 2:r=t.sent,i=r.ContactSchoolAdminView,this.layout.showChildView(S,c.a.createElement(i,{classroomId:e,closePopup:function(){return o.layout.closePopup()}}));case 5:case"end":return t.stop()}}),t,this)})))}}],[{key:"router",get:function(){return Je}}]),r}(w),tt="content",nt="popup",rt="alert",it="hidden",ot=n(56),at={getVideoAppLink:function(e){return{application:P.a.DEFAULT,action:R.a.Default.PLAY_VIDEO,args:[e.id,ot.a.slugify(e.name)]}},getSeriesAppLink:function(e){return{application:P.a.DEFAULT,action:R.a.Default.SERIES,args:[e.id,ot.a.slugify(e.name)]}},getClassificationUpdateAppLink:function(e){return{application:P.a.CONTENT_UPDATES,action:R.a.ContentUpdates.CLASSIFICATION_UPDATE,args:[e.id,ot.a.slugify(e.name)]}},getClassificationAppLink:function(e){return{application:P.a.SUBJECT,action:R.a.Subjects.CLASSIFICATION,args:[e.id,ot.a.slugify(e.name)]}},getShareAppLink:function(e){return{application:P.a.DEFAULT,action:R.a.Default.SHARE,args:[e.id],params:{entityType:"video"}}},getAddToPlaylistAppLink:function(e){return{application:P.a.PLAYLISTS,action:R.a.Playlists.ADD_TO_PLAYLIST,args:[e.id]}},dashboardAppLink:{application:P.a.DASHBOARD,action:R.a.Dashboard.HOME},contentUpdatesAppLink:{application:P.a.CONTENT_UPDATES,action:R.a.ContentUpdates.CONTENT_UPDATES}};function st(e){return(st="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)}function ct(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ut(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function lt(e,t,n){return t&&ut(e.prototype,t),n&&ut(e,n),e}function ft(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}}),t&&pt(e,t)}function pt(e,t){return(pt=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function dt(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=yt(e);if(t){var i=yt(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ht(this,n)}}function ht(e,t){return!t||"object"!==st(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function yt(e){return(yt=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var mt=function(e){ft(n,e);var t=dt(n);function n(){return ct(this,n),t.apply(this,arguments)}return lt(n,[{key:"channelName",get:function(){return P.a.CONTENT_UPDATES}},{key:"appRoutes",get:function(){return{"latest-releases":"contentUpdates","latest-releases/:id(/:slug)":"classificationUpdate"}}},{key:"filters",get:function(){return[He,ie,M]}}]),n}(r.a.AppRouter),vt=function(e){ft(r,e);var t=dt(r);function r(){return ct(this,r),t.apply(this,arguments)}return lt(r,[{key:"name",get:function(){return"Content Updates Application"}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:!0,alertRegion:rt}}}},{key:"channelName",get:function(){return P.a.CONTENT_UPDATES}},{key:"contentUpdates",value:function(){var e=this;Promise.all([n.e(0),n.e(3),n.e(4),n.e(23),n.e(113)]).then(n.bind(null,1992)).then((function(t){var n=t.ContentUpdatesView;e.layout.showChildView(tt,s.createElement(n,{appLinks:at}))}))}},{key:"classificationUpdate",value:function(e){var t=this;Promise.all([n.e(0),n.e(3),n.e(4),n.e(23),n.e(119)]).then(n.bind(null,1993)).then((function(n){var r=n.ClassificationUpdateView;t.layout.showChildView(tt,s.createElement(r,{classificationId:e,appLinks:at}))}))}}],[{key:"router",get:function(){return mt}}]),r}(w);function gt(e){return(gt="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)}function bt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function wt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function _t(e,t,n){return t&&wt(e.prototype,t),n&&wt(e,n),e}function St(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}}),t&&Tt(e,t)}function Tt(e,t){return(Tt=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Ct(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=kt(e);if(t){var i=kt(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Et(this,n)}}function Et(e,t){return!t||"object"!==gt(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function kt(e){return(kt=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Ot=function(e){St(n,e);var t=Ct(n);function n(){return bt(this,n),t.apply(this,arguments)}return _t(n,[{key:"channelName",get:function(){return P.a.DASHBOARD}},{key:"appRoutes",get:function(){return{"(/)":"index","discover(/)":"discover","discover/:id/:name":"dashboard"}}},{key:"filters",get:function(){return[He,ie,M]}}]),n}(r.a.AppRouter),Pt=function(e){St(r,e);var t=Ct(r);function r(){return bt(this,r),t.apply(this,arguments)}return _t(r,[{key:"name",get:function(){return"Dashboard Application"}},{key:"channelName",get:function(){return P.a.DASHBOARD}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:!0,alertRegion:rt}}}},{key:"index",value:function(){this.discover()}},{key:"discover",value:function(){var e=this;Promise.all([n.e(0),n.e(6),n.e(21)]).then(n.bind(null,1971)).then((function(t){var n=t.DashboardView;e.layout.showChildView(tt,s.createElement(n,null))}))}},{key:"dashboard",value:function(e){var t=this;Promise.all([n.e(0),n.e(3),n.e(4),n.e(20)]).then(n.bind(null,2004)).then((function(n){var r=n.DashboardWidgetView;t.layout.showChildView(tt,s.createElement(r,{widgetId:e}))}))}}],[{key:"router",get:function(){return Ot}}]),r}(w),At=n(252),It=n(258),xt=n(57);function Rt(e){return(Rt="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)}function Lt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function jt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Nt(e,t,n){return t&&jt(e.prototype,t),n&&jt(e,n),e}function Dt(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}}),t&&Bt(e,t)}function Bt(e,t){return(Bt=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Ut(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Vt(e);if(t){var i=Vt(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Mt(this,n)}}function Mt(e,t){return!t||"object"!==Rt(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Vt(e){return(Vt=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Ft=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{c(r.next(e))}catch(e){o(e)}}function s(e){try{c(r.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}c((r=r.apply(e,t||[])).next())}))},Ht=function(e){Dt(n,e);var t=Ut(n);function n(){return Lt(this,n),t.apply(this,arguments)}return Nt(n,[{key:"channelName",get:function(){return P.a.DEFAULT}},{key:"appRoutes",get:function(){return{"videos/:id(/:slug)":"playVideo","videos/:id/clips/new(/)":"createClip","clips/:id/edit(/)":"editClip","clips/:id(/:slug)":"playClip","series/:id(/:slug)":"series","favourites(/)":"favourites","my-videos(/)":"myVideos","shared-by-me(/)":"sharedByMe","shared-with-me(/)":"sharedWithMe","plugin(/)":"plugin","*path":"catchAllRoutes"}}},{key:"appLinks",get:function(){return["devError","dialogError","error","notFound","editVideo","previewPdf","previewQuestions","createClipDetails","editClipDetails","deleteClip","viewCurriculumLinks","downloadVideo","deleteVideo","share","pluginShare","pluginNewWindow"]}},{key:"externalRoutes",get:function(){return{"logout(/)":"logOut","login(/)":"logIn"}}},{key:"filters",get:function(){return[He,ie,M,Me]}}]),n}(r.a.AppRouter),zt=function(e){Dt(i,e);var t=Ut(i);function i(){return Lt(this,i),t.apply(this,arguments)}return Nt(i,[{key:"name",get:function(){return"Default Application"}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:N(),alertRegion:rt}}}},{key:"channelName",get:function(){return P.a.DEFAULT}},{key:"myVideos",value:function(){var e=this;Promise.all([n.e(0),n.e(3),n.e(4),n.e(64)]).then(n.bind(null,1978)).then((function(t){var n=t.MyVideosView;e.layout.showChildView(tt,s.createElement(n,null))}))}},{key:"playVideo",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return Ft(this,void 0,void 0,regeneratorRuntime.mark((function i(){var o,a=this;return regeneratorRuntime.wrap((function(i){for(;;)switch(i.prev=i.next){case 0:o=("string"==typeof t?r:t)||{},Promise.all([n.e(0),n.e(3),n.e(4),n.e(6),n.e(33)]).then(n.bind(null,2005)).then((function(t){var n=t.PlayView;a.layout.showChildView(tt,s.createElement(n,{id:e,queryParams:o}))}));case 2:case"end":return i.stop()}}),i)})))}},{key:"editVideo",value:function(e){var t=this;Promise.all([n.e(1),n.e(2),n.e(88)]).then(n.bind(null,1909)).then((function(n){var r=n.EditVideoView;t.layout.showChildView(nt,s.createElement(r,{id:e,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"series",value:function(e,t,r){var i=this,o=function(t){return{application:P.a.DEFAULT,action:R.a.Default.PLAY_VIDEO,args:[t.id,ot.a.slugify(t.name)],params:{context:It.a.Series,contextId:e}}};Promise.all([n.e(0),n.e(3),n.e(4),n.e(18)]).then(n.bind(null,1897)).then((function(t){var n=t.SeriesView;i.layout.showChildView(tt,s.createElement(n,{id:e,classificationId:r.classificationId,getVideoAppLink:o}))}))}},{key:"favourites",value:function(){var e=this;Promise.all([n.e(0),n.e(3),n.e(4),n.e(70)]).then(n.bind(null,2006)).then((function(t){var n=t.FavouritesView;e.layout.showChildView(tt,s.createElement(n,null))}))}},{key:"previewPdf",value:function(e){var t=this;Promise.all([n.e(12),n.e(57),n.e(77)]).then(n.bind(null,2007)).then((function(n){var r=n.PreviewPdfView;t.layout.showChildView(nt,s.createElement(r,{closePopup:function(){return t.layout.closePopup()},id:e}))}))}},{key:"createClip",value:function(e,t){var r=this;n.e(24).then(n.bind(null,1972)).then((function(n){var i=n.EditClipTimepointsView;r.layout.showChildView(tt,s.createElement(i,{videoId:e,startTime:t.startTime}))}))}},{key:"editClip",value:function(e){var t=this;n.e(24).then(n.bind(null,1972)).then((function(n){var r=n.EditClipTimepointsView;t.layout.showChildView(tt,s.createElement(r,{id:e}))}))}},{key:"createClipDetails",value:function(e,t){var r=this;Promise.all([n.e(1),n.e(2),n.e(0),n.e(26)]).then(n.bind(null,2008)).then((function(n){var i=n.EditClipDetailsView;r.layout.showChildView(nt,s.createElement(i,{videoId:e,startTime:t.startTime,endTime:t.endTime,closePopup:function(){return r.layout.closePopup()}}))}))}},{key:"editClipDetails",value:function(e,t){var r=this;Promise.all([n.e(1),n.e(2),n.e(0),n.e(26)]).then(n.bind(null,2008)).then((function(n){var i=n.EditClipDetailsView;r.layout.showChildView(nt,s.createElement(i,{id:e,startTime:t.startTime,endTime:t.endTime,closePopup:function(){return r.layout.closePopup()}}))}))}},{key:"deleteClip",value:function(e){var t=this;n.e(147).then(n.bind(null,1910)).then((function(n){var r=n.DeleteClipView;t.layout.showChildView(nt,s.createElement(r,{id:e,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"playClip",value:function(e,t){var r=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Promise.all([n.e(0),n.e(3),n.e(4),n.e(6),n.e(37)]).then(n.bind(null,1911)).then((function(n){var o=n.PlayClipView,a=("string"==typeof t?i:t)||{};r.layout.showChildView(tt,s.createElement(o,{id:e,queryParams:a}))}))}},{key:"viewCurriculumLinks",value:function(e){var t=this;n.e(102).then(n.bind(null,1912)).then((function(n){var r=n.ViewCurriculumLinksView;t.layout.showChildView(nt,s.createElement(r,{id:e,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"downloadVideo",value:function(e){var t=this;n.e(149).then(n.bind(null,1994)).then((function(n){var r=n.DownloadVideoView;t.layout.showChildView(it,s.createElement(r,{id:e}))}))}},{key:"deleteVideo",value:function(e){var t=this;n.e(148).then(n.bind(null,1913)).then((function(n){var r=n.DeleteVideoView;t.layout.showChildView(nt,s.createElement(r,{id:e,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"share",value:function(e,t){var r=this;Promise.all([n.e(1),n.e(2),n.e(16),n.e(40)]).then(n.bind(null,1973)).then((function(n){var i=n.ShareView;r.layout.showChildView(nt,s.createElement(i,{entityId:e,entityType:t.entityType,closePopup:function(){return r.layout.closePopup()},emptyStateImageUrl:xt.a.EmptyStates.TYPEAHEAD_RESULTS,errorStateImageUrl:xt.a.TYPEAHEAD_ERROR}))}))}},{key:"sharedByMe",value:function(){var e=this;Promise.all([n.e(11),n.e(0),n.e(17),n.e(59)]).then(n.bind(null,1975)).then((function(t){var n=t.SharedByMeView;e.layout.showChildView(tt,s.createElement(n,null))}))}},{key:"sharedWithMe",value:function(){var e=this;Promise.all([n.e(11),n.e(0),n.e(17),n.e(120)]).then(n.bind(null,1982)).then((function(t){var n=t.SharedWithMeView;e.layout.showChildView(tt,s.createElement(n,null))}))}},{key:"pluginShare",value:function(e,t){return Ft(this,void 0,void 0,regeneratorRuntime.mark((function r(){var i,o,a=this;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,Promise.all([n.e(1),n.e(2),n.e(74)]).then(n.bind(null,1985));case 2:i=r.sent,o=i.PluginShareView,this.layout.showChildView(nt,s.createElement(o,{entityId:e,entityType:t.entityType,closePopup:function(){return a.layout.closePopup()}}));case 5:case"end":return r.stop()}}),r,this)})))}},{key:"pluginNewWindow",value:function(e){return Ft(this,void 0,void 0,regeneratorRuntime.mark((function t(){var r,i,o=this;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,n.e(150).then(n.bind(null,1914));case 2:r=t.sent,i=r.PluginNewWindowView,this.layout.showChildView(nt,s.createElement(i,{url:e.url,closePopup:function(){return o.layout.closePopup()}}));case 5:case"end":return t.stop()}}),t,this)})))}},{key:"catchAllRoutes",value:function(){r.a.ErrorHelper.throw(new At.a)}},{key:"notFound",value:function(){var e=this,t=u.Radio.channel("error:view").request("current:error");n.e(133).then(n.bind(null,1915)).then((function(n){var r=n.NotFoundView;e.layout.showChildView(tt,s.createElement(r,{error:t}))}))}},{key:"error",value:function(){var e=this,t=u.Radio.channel("error:view").request("current:error");Promise.resolve().then(n.bind(null,556)).then((function(n){var r=n.ErrorView;e.layout.showChildView(tt,s.createElement(r,{error:t}))}))}},{key:"dialogError",value:function(){var e=this,t=u.Radio.channel("error:view").request("current:error");if(t){var r=t.dialogOptions;n.e(128).then(n.bind(null,1916)).then((function(n){var i=n.DialogView;e.layout.showChildView(nt,s.createElement(i,{title:r.title,text:r.text,buttons:r.buttons,onDone:t.onDone,onFail:t.onFail,closePopup:function(){return e.layout.closePopup()}}))}))}}},{key:"devError",value:function(){var e=this,t=u.Radio.channel("error:view").request("current:error");n.e(127).then(n.bind(null,1917)).then((function(n){var r=n.DevErrorView;e.layout.showChildView(tt,s.createElement(r,{error:t}))}))}}],[{key:"router",get:function(){return Ht}}]),i}(w),Wt=n(36),qt=n(24),Gt=n(266),Kt=n(80),Yt=n(95),Xt=n(389),Qt=n(191),$t=n(259),Zt=n(254);function Jt(e){return(Jt="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)}function en(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function tn(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function nn(e,t){return(nn=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function rn(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=an(e);if(t){var i=an(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return on(this,n)}}function on(e,t){return!t||"object"!==Jt(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function an(e){return(an=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var sn=function(e){!function(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}}),t&&nn(e,t)}(o,e);var t,n,r,i=rn(o);function o(){return en(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"name",get:function(){return"ShareLinkError"}}])&&tn(t.prototype,n),r&&tn(t,r),o}(r.a.SilentError);function cn(e){return(cn="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)}function un(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ln(e,t){return(ln=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function fn(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=dn(e);if(t){var i=dn(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return pn(this,n)}}function pn(e,t){return!t||"object"!==cn(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function dn(e){return(dn=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var hn=function(e){!function(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}}),t&&ln(e,t)}(o,e);var t,n,r,i=fn(o);function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,"Share link has been deleted")}return t=o,(n=[{key:"name",get:function(){return"ShareLinkDeletedError"}},{key:"heading",get:function(){return G.a.getPhrase("share.shareLinkDeletedError","heading")}},{key:"description",get:function(){return G.a.getPhrase("share.shareLinkDeletedError","description")}},{key:"imageUrl",get:function(){return xt.a.EmptyStates.Share.DELETED}}])&&un(t.prototype,n),r&&un(t,r),o}(sn);function yn(e){return(yn="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)}function mn(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function vn(e,t){return(vn=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function gn(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=wn(e);if(t){var i=wn(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return bn(this,n)}}function bn(e,t){return!t||"object"!==yn(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function wn(e){return(wn=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var _n=function(e){!function(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}}),t&&vn(e,t)}(o,e);var t,n,r,i=gn(o);function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,"Share link has expired")}return t=o,(n=[{key:"name",get:function(){return"ShareLinkExpiredError"}},{key:"heading",get:function(){return G.a.getPhrase("share.shareLinkExpiredError","heading")}},{key:"imageUrl",get:function(){return xt.a.EmptyStates.Share.EXPIRED}}])&&mn(t.prototype,n),r&&mn(t,r),o}(sn);function Sn(e){return(Sn="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)}function Tn(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Cn(e,t){return(Cn=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function En(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=On(e);if(t){var i=On(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return kn(this,n)}}function kn(e,t){return!t||"object"!==Sn(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function On(e){return(On=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Pn=function(e){!function(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}}),t&&Cn(e,t)}(o,e);var t,n,r,i=En(o);function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,"Share link doesn't exist")}return t=o,(n=[{key:"name",get:function(){return"ShareLinkNotFoundError"}},{key:"heading",get:function(){return G.a.getPhrase("share.shareLinkNotFoundError","heading")}},{key:"imageUrl",get:function(){return xt.a.EmptyStates.Share.NOT_FOUND}}])&&Tn(t.prototype,n),r&&Tn(t,r),o}(sn);function An(e){return(An="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)}function In(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function xn(e,t){return(xn=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Rn(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=jn(e);if(t){var i=jn(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ln(this,n)}}function Ln(e,t){return!t||"object"!==An(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function jn(e){return(jn=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Nn=function(e){!function(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}}),t&&xn(e,t)}(o,e);var t,n,r,i=Rn(o);function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,"Access to this share link is forbidden")}return t=o,(n=[{key:"name",get:function(){return"ShareLinkPrivateError"}},{key:"heading",get:function(){return G.a.getPhrase("share.shareLinkPrivateError","heading")}},{key:"description",get:function(){return G.a.getPhrase("share.shareLinkPrivateError","description")}},{key:"imageUrl",get:function(){return xt.a.EmptyStates.Share.PRIVATE}}])&&In(t.prototype,n),r&&In(t,r),o}(sn);function Dn(e){return(Dn="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)}function Bn(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Un(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Mn(e,t){return(Mn=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Vn(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Hn(e);if(t){var i=Hn(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Fn(this,n)}}function Fn(e,t){return!t||"object"!==Dn(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Hn(e){return(Hn=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var zn=function(e){!function(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}}),t&&Mn(e,t)}(o,e);var t,n,r,i=Vn(o);function o(){return Bn(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"name",get:function(){return"EmbedError"}}])&&Un(t.prototype,n),r&&Un(t,r),o}(r.a.SilentError);function Wn(e){return(Wn="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)}function qn(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Gn(e,t){return(Gn=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Kn(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Xn(e);if(t){var i=Xn(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Yn(this,n)}}function Yn(e,t){return!t||"object"!==Wn(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Xn(e){return(Xn=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Qn=function(e){!function(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}}),t&&Gn(e,t)}(o,e);var t,n,r,i=Kn(o);function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,"Embed link not found error")}return t=o,(n=[{key:"name",get:function(){return"EmbedNotFoundError"}},{key:"heading",get:function(){return G.a.getPhrase("embed.embedNotFoundError","heading")}},{key:"imageUrl",get:function(){return xt.a.EmptyStates.Share.NOT_FOUND}}])&&qn(t.prototype,n),r&&qn(t,r),o}(zn);function $n(e){return($n="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)}function Zn(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Jn(e,t){return(Jn=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function er(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=nr(e);if(t){var i=nr(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return tr(this,n)}}function tr(e,t){return!t||"object"!==$n(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function nr(e){return(nr=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var rr=function(e){!function(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}}),t&&Jn(e,t)}(o,e);var t,n,r,i=er(o);function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,"Embed link deleted error")}return t=o,(n=[{key:"name",get:function(){return"EmbedLinkDeletedError"}},{key:"heading",get:function(){return G.a.getPhrase("embed.embedLinkDeletedError","heading")}},{key:"description",get:function(){return G.a.getPhrase("embed.embedLinkDeletedError","description")}},{key:"imageUrl",get:function(){return xt.a.EmptyStates.Share.DELETED}}])&&Zn(t.prototype,n),r&&Zn(t,r),o}(zn);function ir(e){return(ir="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)}function or(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ar(e,t){return(ar=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function sr(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ur(e);if(t){var i=ur(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return cr(this,n)}}function cr(e,t){return!t||"object"!==ir(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function ur(e){return(ur=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var lr=function(e){!function(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}}),t&&ar(e,t)}(o,e);var t,n,r,i=sr(o);function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,"Embed link expired error")}return t=o,(n=[{key:"name",get:function(){return"EmbedLinkExpiredError"}},{key:"heading",get:function(){return G.a.getPhrase("embed.embedLinkExpiredError","heading")}},{key:"imageUrl",get:function(){return xt.a.EmptyStates.Share.EXPIRED}}])&&or(t.prototype,n),r&&or(t,r),o}(zn);function fr(e){return(fr="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)}function pr(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function dr(e,t){return(dr=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function hr(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=mr(e);if(t){var i=mr(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return yr(this,n)}}function yr(e,t){return!t||"object"!==fr(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function mr(e){return(mr=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var vr=function(e){!function(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}}),t&&dr(e,t)}(o,e);var t,n,r,i=hr(o);function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,"Unspecified embed error")}return t=o,(n=[{key:"name",get:function(){return"UnspecifiedEmbedError"}},{key:"heading",get:function(){return G.a.getPhrase("embed.unspecifiedEmbedError","heading")}},{key:"description",get:function(){return G.a.getPhrase("embed.unspecifiedEmbedError","description")}},{key:"imageUrl",get:function(){return xt.a.EmptyStates.Share.NOT_FOUND}}])&&pr(t.prototype,n),r&&pr(t,r),o}(zn);function gr(e){return(gr="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)}function br(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function wr(e,t){return(wr=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function _r(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Tr(e);if(t){var i=Tr(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Sr(this,n)}}function Sr(e,t){return!t||"object"!==gr(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Tr(e){return(Tr=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Cr,Er=function(e){!function(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}}),t&&wr(e,t)}(o,e);var t,n,r,i=_r(o);function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,"Embed link private error")}return t=o,(n=[{key:"name",get:function(){return"PrivateEmbedError"}},{key:"heading",get:function(){return G.a.getPhrase("embed.privateEmbedError","heading")}},{key:"description",get:function(){return G.a.getPhrase("embed.privateEmbedError","description")}},{key:"imageUrl",get:function(){return xt.a.EmptyStates.Share.PRIVATE}}])&&br(t.prototype,n),r&&br(t,r),o}(zn);function kr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Or,Pr=(kr(Cr={},qt.a.Video,!0),kr(Cr,qt.a.Interactive,!0),kr(Cr,qt.a.Clip,!0),kr(Cr,qt.a.Playlist,!0),kr(Cr,qt.a.Series,!0),Cr),Ar={getErrors:function(e){return e===R.a.Share.VIEW_SHARE_LINK?{notFound:Pn,deleted:hn,private:Nn,unspecified:H.a,expired:_n}:{notFound:Qn,deleted:rr,private:Er,unspecified:vr,expired:lr}},throwError:function(e,t){W.a._forcePushContext(t),r.a.AppLinkUtility.routingEnded(),r.a.ErrorHelper.throw(e)},validateShareLink:function(e,t,n){return Pr[e.objectTypeId]?e.type!==Gt.a.ShareLink||e.status!==Xt.a.Expired||(Ar.throwError(new n.expired,t),!1):(Ar.throwError(new n.unspecified,t),!1)},onShareLinkError:function(e,t,n){if(r.a.AppLinkUtility.hasActiveRoute())return e.status===Yt.a.Forbidden?"share-link-deleted"===e.responseJSON.type?Ar.throwError(new n.deleted,t):Ar.throwError(new n.private,t):e.status===Yt.a.NotFound?Ar.throwError(new n.notFound,t):Ar.throwError(new n.unspecified,t)},onFetchVideoError:function(e,t,n){if(r.a.AppLinkUtility.hasActiveRoute())return e.status===Yt.a.Forbidden?Ar.throwError(new n.private,t):e.status===Yt.a.NotFound?Ar.throwError(new n.notFound,t):Ar.throwError(new n.unspecified,t)},goToPortal:function(e,t){r.a.AppLinkUtility.routingEnded(),t.action!==R.a.Share.VIEW_SHARE_LINK?r.a.AppLinkHelper.trigger({application:P.a.EMBED,action:R.a.Embed.EMBED_LOGIN,args:[e]}):r.a.AppLinkHelper.trigger({application:P.a.LAUNCHPAD,action:R.a.Launchpad.PASSWORD_PROTECTED_SHARE_LINK,args:[e],params:{appLink:t}})},goToSignIn:function(e,t){r.a.AppLinkUtility.routingEnded();var n=e.ownerCustomerId;if(t.action!==R.a.Embed.VIEW_EMBEDDED_RESOURCE){var i=r.a.AppLinkHelper.getHref(t),o=t.params||{},a=o.videoId,s=o.clipId,c=o.interactiveId;e.objectTypeId===qt.a.Playlist&&(a||s||c)?r.a.AppLinkHelper.trigger({application:P.a.DEFAULT,action:R.a.Default.LOG_IN,params:{redirectUrl:i,customerId:n}}):r.a.AppLinkHelper.trigger({application:P.a.LAUNCHPAD,action:R.a.Launchpad.SHARE_LINK_SIGN_IN,args:[e.id],params:{redirectUrl:i,customerId:n}})}else r.a.AppLinkHelper.trigger({application:P.a.EMBED,action:R.a.Embed.EMBED_LOGIN,args:[e.id],params:{customerId:n}})},getVideo:function(e,t,n,r,o,a){var s=r.objectId,c=r.objectTypeId,u=e.params;if((null==u?void 0:u.videoId)?(s=u.videoId,c=qt.a.Video):(null==u?void 0:u.clipId)?(s=u.clipId,c=qt.a.Clip):(null==u?void 0:u.interactiveId)&&(s=u.interactiveId,c=qt.a.Interactive),c!==qt.a.Video)if(c!==qt.a.Clip)if(c!==qt.a.Interactive);else{i.a.hooklessFetch(t,Zt.a.sharedInteractiveMetadata(s,n,(function(e){e.clip?o(e.clip.video):o(e.video)}),a))}else{i.a.hooklessFetch(t,$t.a.sharedClip(s,n,(function(e){return o(e.video)}),a))}else i.a.hooklessFetch(t,Qt.a.sharedVideo(s,n,o,a))}};function Ir(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var xr=(Ir(Or={},qt.a.Video,!0),Ir(Or,qt.a.Interactive,!0),Ir(Or,qt.a.Clip,!0),Or);function Rr(e,t){var n=e.appLink.action===R.a.Share.VIEW_SHARE_LINK,r=e.appLink.action===R.a.Embed.VIEW_EMBEDDED_RESOURCE;if(n||r){var a=Ar.getErrors(e.appLink.action),s=Wt.a.first(e.appLink.args);if(!s)return Ar.throwError(new a.notFound,e.appLink);i.a.hooklessFetch(e.shell.store,Kt.a.getShareObject(s,(function(n){if(Ar.validateShareLink(n,e.appLink,a))return n.type===Gt.a.DirectShare?t(e):void function(t){if(!t.isPasswordProtected)return void c(t);var n=se.b.get(s);if(n)return void i.a.hooklessFetch(e.shell.store,Kt.a.checkPassword(s,n,(function(n){n.success?c(t):Ar.goToPortal(s,e.appLink)}),(function(){return Ar.goToPortal(s,e.appLink)})));Ar.goToPortal(s,e.appLink)}(n)}),(function(t){Ar.onShareLinkError(t,e.appLink,a)})))}else t(e);function c(n){var r,c,l=xr[n.objectTypeId],f=null!==(c=null===(r=e.appLink)||void 0===r?void 0:r.params)&&void 0!==c?c:{},p=f.videoId,d=f.clipId,h=f.interactiveId;if((p||d||h)&&(l=!0),!l)return n.objectTypeId===qt.a.Playlist?void t(e):void i.a.hooklessFetch(e.shell.store,o.a.currentUser((function(e){return u(n,e,!1)}),(function(){return Ar.throwError(new a.unspecified,e.appLink)})));Ar.getVideo(e.appLink,e.shell.store,s,n,(function(r){return function(n,r){if(r._canBeConsumed.value)return void t(e);i.a.hooklessFetch(e.shell.store,o.a.currentUser((function(e){return u(n,e,!0)}),(function(){return Ar.throwError(new a.unspecified,e.appLink)})))}(n,r)}),(function(t){return Ar.onFetchVideoError(t,e.appLink,a)}))}function u(n,r,i){r.isAuthenticated?i?Ar.throwError(new a.private,e.appLink):t(e):Ar.goToSignIn(n,e.appLink)}}function Lr(e){return(Lr="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)}function jr(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Nr(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Dr(e,t,n){return t&&Nr(e.prototype,t),n&&Nr(e,n),e}function Br(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}}),t&&Ur(e,t)}function Ur(e,t){return(Ur=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Mr(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Fr(e);if(t){var i=Fr(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Vr(this,n)}}function Vr(e,t){return!t||"object"!==Lr(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Fr(e){return(Fr=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Hr=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{c(r.next(e))}catch(e){o(e)}}function s(e){try{c(r.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}c((r=r.apply(e,t||[])).next())}))},zr=function(e){Br(n,e);var t=Mr(n);function n(){return jr(this,n),t.apply(this,arguments)}return Dr(n,[{key:"channelName",get:function(){return P.a.EMBED}},{key:"appRoutes",get:function(){return{"share/embed/:shareId":"viewEmbeddedResource","embed-login-success":"embedLoginSuccess","plugin-login-success":"pluginLoginSuccess","plugin/login(/)":"pluginLogin"}}},{key:"appLinks",get:function(){return["embedLogin","embedError"]}},{key:"filters",get:function(){return[He,Rr]}}]),n}(r.a.AppRouter),Wr=function(e){Br(r,e);var t=Mr(r);function r(){return jr(this,r),t.apply(this,arguments)}return Dr(r,[{key:"name",get:function(){return"Embed Application"}},{key:"layoutOptions",get:function(){return{name:O}}},{key:"channelName",get:function(){return P.a.EMBED}},{key:"viewEmbeddedResource",value:function(e,t){var r=this;n.e(134).then(n.bind(null,2009)).then((function(n){var i=n.BaseEmbedView;r.layout.showChildView(tt,c.a.createElement(i,{shareId:e,queryParams:t}))}))}},{key:"embedLogin",value:function(e,t){return Hr(this,void 0,void 0,regeneratorRuntime.mark((function r(){var i,o;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,n.e(107).then(n.bind(null,1918));case 2:i=r.sent,o=i.EmbedLoginView,this.layout.showChildView(tt,c.a.createElement(o,{shareId:e,consumerKey:t.consumerKey,customerId:t.customerId}));case 5:case"end":return r.stop()}}),r,this)})))}},{key:"embedLoginSuccess",value:function(){return Hr(this,void 0,void 0,regeneratorRuntime.mark((function e(){var t,r;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,n.e(105).then(n.bind(null,1919));case 2:t=e.sent,r=t.EmbedLoginSuccessView,this.layout.showChildView(tt,c.a.createElement(r,null));case 5:case"end":return e.stop()}}),e,this)})))}},{key:"embedError",value:function(){return Hr(this,void 0,void 0,regeneratorRuntime.mark((function e(){var t,r,i;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=u.Radio.channel("error:view").request("current:error"),e.next=3,Promise.resolve().then(n.bind(null,758));case 3:r=e.sent,i=r.EmbedErrorView,this.layout.showChildView(tt,c.a.createElement(i,{error:t}));case 6:case"end":return e.stop()}}),e,this)})))}},{key:"pluginLogin",value:function(e){return Hr(this,void 0,void 0,regeneratorRuntime.mark((function t(){var r,i;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,n.e(114).then(n.bind(null,1920));case 2:r=t.sent,i=r.PluginLoginView,this.layout.showChildView(tt,c.a.createElement(i,{returnUrl:e.returnUrl}));case 5:case"end":return t.stop()}}),t,this)})))}},{key:"pluginLoginSuccess",value:function(){return Hr(this,void 0,void 0,regeneratorRuntime.mark((function e(){var t,r;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,n.e(106).then(n.bind(null,1921));case 2:t=e.sent,r=t.PluginLoginSuccessView,this.layout.showChildView(tt,c.a.createElement(r,null));case 5:case"end":return e.stop()}}),e,this)})))}}],[{key:"router",get:function(){return zr}}]),r}(w),qr=n(39);function Gr(e){return function(e){if(Array.isArray(e))return Kr(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return Kr(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Kr(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Kr(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var Yr=n(250);function Xr(e){var t=e.view,n=e.options,r=void 0===n?{}:n,i=e.className,o=void 0===i?"":i,a=s.useMemo((function(){return new t(r)}),[r]);Object(Yr.a)(a.title);var c=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=s.useRef(null);return s.useEffect((function(){if(e){var t=n.current;return e.render(),t.hasChildNodes()?t.replaceChild(e.el,t.firstChild):t.appendChild(e.el),e.trigger("rendered"),function(){qr.a.isFunction(e.close)?e.close():qr.a.isFunction(e.destroy)&&e.destroy()}}}),Gr(t)),n}(a,[a]);return t?s.createElement("div",{ref:c,className:o}):s.createElement(s.Fragment,null)}function Qr(e){return(Qr="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)}function $r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Zr(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Jr(e,t,n){return t&&Zr(e.prototype,t),n&&Zr(e,n),e}function ei(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}}),t&&ti(e,t)}function ti(e,t){return(ti=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function ni(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ii(e);if(t){var i=ii(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ri(this,n)}}function ri(e,t){return!t||"object"!==Qr(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function ii(e){return(ii=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var oi=function(e){ei(n,e);var t=ni(n);function n(){return $r(this,n),t.apply(this,arguments)}return Jr(n,[{key:"channelName",get:function(){return P.a.NOTIFICATIONS}},{key:"appRoutes",get:function(){return{"notifications(/)":"index"}}},{key:"filters",get:function(){return[He,ie,M]}}]),n}(r.a.AppRouter),ai=function(e){ei(r,e);var t=ni(r);function r(){return $r(this,r),t.apply(this,arguments)}return Jr(r,[{key:"name",get:function(){return"Notifications Application"}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:!0,alertRegion:T}}}},{key:"channelName",get:function(){return P.a.NOTIFICATIONS}},{key:"index",value:function(e){var t=this;n.e(115).then(n.bind(null,2010)).then((function(n){var r=n.NotificationsView;t.layout.showChildView(_,s.createElement(Xr,{view:r,options:{params:e}}))}))}}],[{key:"router",get:function(){return oi}}]),r}(w),si=n(430);function ci(e){return(ci="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)}function ui(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function li(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function fi(e,t,n){return t&&li(e.prototype,t),n&&li(e,n),e}function pi(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}}),t&&di(e,t)}function di(e,t){return(di=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function hi(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=mi(e);if(t){var i=mi(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return yi(this,n)}}function yi(e,t){return!t||"object"!==ci(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function mi(e){return(mi=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var vi=function(e){pi(n,e);var t=hi(n);function n(){return ui(this,n),t.apply(this,arguments)}return fi(n,[{key:"channelName",get:function(){return P.a.PLAYLISTS}},{key:"appRoutes",get:function(){return{"playlists(/)":"index","playlists/:id(/:slug)":"playlist"}}},{key:"appLinks",get:function(){return["newPlaylist","editPlaylist","deletePlaylist","addToPlaylist","removeVideoFromPlaylist","copyPlaylist"]}},{key:"filters",get:function(){return[He,ie,M]}}]),n}(r.a.AppRouter),gi=function(e){pi(r,e);var t=hi(r);function r(){return ui(this,r),t.apply(this,arguments)}return fi(r,[{key:"name",get:function(){return"Playlists Application"}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:!0,alertRegion:rt}}}},{key:"channelName",get:function(){return P.a.PLAYLISTS}},{key:"getPopupProps",value:function(){var e=this;return{closePopup:function(){return e.layout.closePopup()},analyticsOptions:{location:E.LocationContext.Popup}}}},{key:"index",value:function(e){var t=this,r=function(e){return{application:P.a.PLAYLISTS,action:R.a.Playlists.PLAYLIST,args:[e.id,ot.a.slugify(e.name)]}},i=e.sort&&si.a.getSortTypeFromName(e.sort);n.e(39).then(n.bind(null,1995)).then((function(e){var n=e.PlaylistsView;t.layout.showChildView(tt,s.createElement(n,{getPlaylistAppLink:r,sort:i}))}))}},{key:"playlist",value:function(e,t,r){var i=this,o="string"==typeof t?null==r?void 0:r.classificationId:null==t?void 0:t.classificationId,a=function(e){return{application:P.a.DEFAULT,action:R.a.Default.SERIES,args:[e.id,ot.a.slugify(e.name)]}};Promise.all([n.e(0),n.e(3),n.e(4),n.e(15)]).then(n.bind(null,1896)).then((function(t){var n=t.PlaylistView;i.layout.showChildView(tt,s.createElement(n,{key:e,playlistId:e,application:P.a.PLAYLISTS,getSeriesAppLink:a,allowEdit:!0,classificationId:o}))}))}},{key:"newPlaylist",value:function(){var e=this;Promise.all([n.e(1),n.e(2),n.e(83)]).then(n.bind(null,1922)).then((function(t){var n=t.NewPlaylistView;e.layout.showChildView(nt,s.createElement(n,Object.assign({application:P.a.PLAYLISTS},e.getPopupProps())))}))}},{key:"editPlaylist",value:function(e){var t=this;Promise.all([n.e(1),n.e(2),n.e(82)]).then(n.bind(null,1923)).then((function(n){var r=n.EditPlaylistView;t.layout.showChildView(nt,s.createElement(r,Object.assign({key:e,playlistId:e},t.getPopupProps())))}))}},{key:"deletePlaylist",value:function(e){var t=this;n.e(121).then(n.bind(null,1924)).then((function(n){var r=n.DeletePlaylistView;t.layout.showChildView(nt,s.createElement(r,Object.assign({key:e,playlistId:e,routeToOnDelete:{application:P.a.PLAYLISTS,action:R.a.Playlists.HOME}},t.getPopupProps())))}))}},{key:"addToPlaylist",value:function(e){var t=this;Promise.all([n.e(1),n.e(2),n.e(44)]).then(n.bind(null,1996)).then((function(n){var r=n.AddToPlaylistView;t.layout.showChildView(nt,s.createElement(r,{key:e,videoId:e,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"removeVideoFromPlaylist",value:function(e,t){var r=this;n.e(136).then(n.bind(null,1925)).then((function(n){var i=n.RemoveVideoFromPlaylistView;r.layout.showChildView(nt,s.createElement(i,Object.assign({key:"".concat(e,":").concat(t),videoId:e,playlistId:t},r.getPopupProps())))}))}},{key:"copyPlaylist",value:function(e){var t=this;n.e(135).then(n.bind(null,1926)).then((function(n){var r=n.CopyPlaylistView;t.layout.showChildView(nt,s.createElement(r,{id:e,closePopup:function(){return t.layout.closePopup()}}))}))}}],[{key:"router",get:function(){return vi}}]),r}(w);function bi(e){return(bi="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)}function wi(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _i(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Si(e,t,n){return t&&_i(e.prototype,t),n&&_i(e,n),e}function Ti(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}}),t&&Ci(e,t)}function Ci(e,t){return(Ci=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Ei(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Oi(e);if(t){var i=Oi(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ki(this,n)}}function ki(e,t){return!t||"object"!==bi(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Oi(e){return(Oi=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Pi=function(e){Ti(n,e);var t=Ei(n);function n(){return wi(this,n),t.apply(this,arguments)}return Si(n,[{key:"channelName",get:function(){return P.a.SEARCH}},{key:"appRoutes",get:function(){return{"search(/)":"index"}}},{key:"filters",get:function(){return[He,ie,M]}}]),n}(r.a.AppRouter),Ai=function(e){Ti(r,e);var t=Ei(r);function r(){return wi(this,r),t.apply(this,arguments)}return Si(r,[{key:"name",get:function(){return"Search Application"}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:!0,alertRegion:rt}}}},{key:"channelName",get:function(){return P.a.SEARCH}},{key:"index",value:function(e){var t=this;Promise.all([n.e(0),n.e(3),n.e(4),n.e(6),n.e(32)]).then(n.bind(null,1968)).then((function(n){var r=n.SearchResultsView;t.layout.showChildView(tt,s.createElement(r,{queryParams:e}),{preventScrollTop:!0})}))}}],[{key:"router",get:function(){return Pi}}]),r}(w);function Ii(e){return(Ii="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)}function xi(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ri(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Li(e,t,n){return t&&Ri(e.prototype,t),n&&Ri(e,n),e}function ji(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}}),t&&Ni(e,t)}function Ni(e,t){return(Ni=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Di(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Ui(e);if(t){var i=Ui(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Bi(this,n)}}function Bi(e,t){return!t||"object"!==Ii(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Ui(e){return(Ui=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Mi=function(e){ji(n,e);var t=Di(n);function n(){return xi(this,n),t.apply(this,arguments)}return Li(n,[{key:"channelName",get:function(){return P.a.SUBJECT}},{key:"appRoutes",get:function(){return{"topics(/)":"classificationAll","topics/onboarding(/)":"onboarding","topics/onboarding/welcome(/)":"onboardingWelcome","topics/onboarding/school-level(/)":"onboardingTopicPresentation","topics/onboarding/curriculum(/)":"onboardingCurriculumPresentation","topics/onboarding/levels(/)":"onboardingLevels","topics/onboarding/topics(/)":"onboardingTopics","topics/onboarding/summary(/)":"onboardingSummary","topics/onboarding/*path":"onboardingCatchAll","topics/:id/topics":"classificationTopics","topics/:id(/:slug)":"classification"}}},{key:"filters",get:function(){return[He,ie,M]}}]),n}(r.a.AppRouter),Vi=function(e){ji(i,e);var t=Di(i);function i(){return xi(this,i),t.apply(this,arguments)}return Li(i,[{key:"name",get:function(){return"Subject Application"}},{key:"channelName",get:function(){return P.a.SUBJECT}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:N(),alertRegion:T}}}},{key:"classificationAll",value:function(){var e=this;Promise.all([n.e(10),n.e(22)]).then(n.bind(null,1927)).then((function(t){var n=t.ClassificationsView;e.layout.showChildView(_,s.createElement(n,null))}))}},{key:"classificationTopics",value:function(e){var t=this;Promise.all([n.e(10),n.e(22)]).then(n.bind(null,1927)).then((function(n){var r=n.ClassificationsView;t.layout.showChildView(_,s.createElement(r,{id:e}))}))}},{key:"classification",value:function(e,t,r){var i=this;Promise.all([n.e(0),n.e(6),n.e(10),n.e(35)]).then(n.bind(null,1976)).then((function(t){var n=t.ClassificationView;i.layout.showChildView(_,s.createElement(n,{key:e,id:e,queryParams:r}))}))}},{key:"onboarding",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};n.e(86).then(n.bind(null,1928)).then((function(n){var r=n.BaseOnboardingView;e.layout.showChildView(_,s.createElement(r,{redirectUrl:t.redirectUrl||""}))}))}},{key:"onboardingWelcome",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};n.e(75).then(n.bind(null,1929)).then((function(n){var r=n.OnboardingWelcomeView;e.layout.showChildView(_,s.createElement(r,{redirectUrl:t.redirectUrl||""}))}))}},{key:"onboardingTopicPresentation",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};Promise.all([n.e(7),n.e(55)]).then(n.bind(null,1930)).then((function(n){var r=n.OnboardingTopicPresentationSelectorView;e.layout.showChildView(_,s.createElement(r,{redirectUrl:t.redirectUrl||""}))}))}},{key:"onboardingCurriculumPresentation",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};Promise.all([n.e(7),n.e(54)]).then(n.bind(null,1931)).then((function(n){var r=n.OnboardingCurriculumPresentationSelectorView;e.layout.showChildView(_,s.createElement(r,{redirectUrl:t.redirectUrl||""}))}))}},{key:"onboardingLevels",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};Promise.all([n.e(7),n.e(53)]).then(n.bind(null,1932)).then((function(n){var r=n.OnboardingAudiencePreferencesView;e.layout.showChildView(_,s.createElement(r,{redirectUrl:t.redirectUrl||""}))}))}},{key:"onboardingTopics",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};Promise.all([n.e(7),n.e(47)]).then(n.bind(null,1933)).then((function(n){var r=n.OnboardingTopicPreferencesView;e.layout.showChildView(_,s.createElement(r,{redirectUrl:t.redirectUrl||""}))}))}},{key:"onboardingSummary",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};Promise.all([n.e(7),n.e(41)]).then(n.bind(null,1997)).then((function(n){var r=n.OnboardingSummaryView;e.layout.showChildView(_,s.createElement(r,{redirectUrl:t.redirectUrl||""}))}))}},{key:"onboardingCatchAll",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};r.a.AppLinkHelper.trigger({application:P.a.SUBJECT,action:R.a.Subjects.ONBOARDING,params:e},{replace:!0})}}],[{key:"router",get:function(){return Mi}}]),i}(w);function Fi(e){return(Fi="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)}function Hi(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function zi(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Wi(e,t,n){return t&&zi(e.prototype,t),n&&zi(e,n),e}function qi(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}}),t&&Gi(e,t)}function Gi(e,t){return(Gi=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Ki(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Xi(e);if(t){var i=Xi(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Yi(this,n)}}function Yi(e,t){return!t||"object"!==Fi(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Xi(e){return(Xi=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Qi=function(e){qi(n,e);var t=Ki(n);function n(){return Hi(this,n),t.apply(this,arguments)}return Wi(n,[{key:"channelName",get:function(){return P.a.UPLOAD}},{key:"appLinks",get:function(){return["editUpload","cancelUpload"]}},{key:"filters",get:function(){return[He,ie,M]}}]),n}(r.a.AppRouter),$i=function(e){qi(r,e);var t=Ki(r);function r(){return Hi(this,r),t.apply(this,arguments)}return Wi(r,[{key:"name",get:function(){return"Upload Application"}},{key:"channelName",get:function(){return P.a.UPLOAD}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:!0,alertRegion:T}}}},{key:"editUpload",value:function(e){var t=this;Promise.all([n.e(1),n.e(2),n.e(87)]).then(n.bind(null,1934)).then((function(n){var r=n.EditUploadView;t.layout.showChildView(S,s.createElement(r,{uploadId:e,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"cancelUpload",value:function(e,t){var r=this;n.e(141).then(n.bind(null,1935)).then((function(n){var i=n.CancelUploadView;r.layout.showChildView(S,s.createElement(i,{id:e,name:t.name,status:t.status,closePopup:function(){return r.layout.closePopup()}}))}))}}],[{key:"router",get:function(){return Qi}}]),r}(w);function Zi(e){return(Zi="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)}function Ji(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function eo(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function to(e,t,n){return t&&eo(e.prototype,t),n&&eo(e,n),e}function no(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}}),t&&ro(e,t)}function ro(e,t){return(ro=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function io(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ao(e);if(t){var i=ao(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return oo(this,n)}}function oo(e,t){return!t||"object"!==Zi(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function ao(e){return(ao=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var so=function(e){no(n,e);var t=io(n);function n(){return Ji(this,n),t.apply(this,arguments)}return to(n,[{key:"channelName",get:function(){return P.a.USER_MANAGER}},{key:"appRoutes",get:function(){return{"user-manager/students(/)":"studentManager","user-manager/staff(/)":"staffManager","user-manager/users/upload/edit":"bulkUserUploadEdit","user-manager/users/upload/duplicates":"bulkUserUploadDuplicates","user-manager/users/upload/review":"bulkUserUploadReview"}}},{key:"appLinks",get:function(){return["createUser","editUser","bulkRemoveUsers","toggleUserStatus","bulkUserUploadPopup","bulkUserUploadSuccess","changeStudentPassword","exportUserList"]}},{key:"filters",get:function(){return[He,ie,M,Me]}}]),n}(r.a.AppRouter),co=function(e){no(r,e);var t=io(r);function r(){return Ji(this,r),t.apply(this,arguments)}return to(r,[{key:"name",get:function(){return"User Manager Application"}},{key:"channelName",get:function(){return P.a.USER_MANAGER}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:!0,alertRegion:T}}}},{key:"studentManager",value:function(e){var t=this;Promise.all([n.e(5),n.e(14),n.e(145)]).then(n.bind(null,2011)).then((function(n){var r=n.StudentManagerView;t.layout.showChildView(_,s.createElement(r,{queryParams:e}))}))}},{key:"staffManager",value:function(e){var t=this;Promise.all([n.e(5),n.e(14),n.e(144)]).then(n.bind(null,2012)).then((function(n){var r=n.StaffManagerView;t.layout.showChildView(_,s.createElement(r,{queryParams:e}))}))}},{key:"createUser",value:function(e){var t=this;Promise.all([n.e(1),n.e(5),n.e(9),n.e(94)]).then(n.bind(null,1936)).then((function(n){var r=n.CreateUserView,i={actionType:E.UserAction.Create,entity:E.EntityType.User,workflowPhase:E.WorkflowPhase.Complete,descriptor:E.OperationDescriptor.Single,location:E.LocationContext.Popup};t.layout.showChildView(S,s.createElement(r,{userType:e.userType,analyticsOptions:i,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"editUser",value:function(e,t){var r=this;Promise.all([n.e(1),n.e(5),n.e(9),n.e(95)]).then(n.bind(null,1937)).then((function(n){var i=n.EditUserView,o={actionType:E.UserAction.Edit,entity:E.EntityType.User,workflowPhase:E.WorkflowPhase.Complete,location:E.LocationContext.Popup};r.layout.showChildView(S,s.createElement(i,{id:e,userType:t.userType,analyticsOptions:o,closePopup:function(){return r.layout.closePopup()}}))}))}},{key:"bulkRemoveUsers",value:function(e){var t=this,r=e.userType;Promise.all([n.e(5),n.e(116)]).then(n.bind(null,2013)).then((function(e){var n=e.BulkRemoveUsersView;t.layout.showChildView(S,s.createElement(n,{userType:r,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"toggleUserStatus",value:function(e){var t=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Promise.all([n.e(5),n.e(117)]).then(n.bind(null,2014)).then((function(n){var i=n.ToggleUserStatusView;t.layout.showChildView(S,s.createElement(i,{id:e,userType:r.userType,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"changeStudentPassword",value:function(e){var t=this;Promise.all([n.e(1),n.e(2),n.e(5),n.e(84)]).then(n.bind(null,2015)).then((function(n){var r=n.ChangeStudentPasswordView;t.layout.showChildView(S,s.createElement(r,{studentId:e,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"exportUserList",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=t.userType;Promise.all([n.e(5),n.e(143)]).then(n.bind(null,2016)).then((function(t){var n=t.ExportUserListView;e.layout.showChildView(C,s.createElement(n,{userType:r,onDone:function(){return e.layout.unsetRegion(C)}}))}))}},{key:"bulkUserUploadPopup",value:function(e){var t=this,r=e.userType;Promise.all([n.e(1),n.e(2),n.e(5),n.e(65)]).then(n.bind(null,1969)).then((function(e){var n=e.BulkUserUploadPopupView;t.layout.showChildView(S,s.createElement(n,{userType:r,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"bulkUserUploadEdit",value:function(){var e=this,t=se.a.get(ue.a.BULK_USER_UPLOAD);Promise.all([n.e(1),n.e(5),n.e(9),n.e(25),n.e(96)]).then(n.bind(null,1998)).then((function(n){var r=n.BulkUserUploadEditView;e.layout.showChildView(_,s.createElement(r,{key:"bulk-user-upload-edit-".concat((new Date).toString()),userType:t,closePopup:function(){return e.layout.closePopup()}}))}))}},{key:"bulkUserUploadDuplicates",value:function(){var e=this,t=se.a.get(ue.a.BULK_USER_UPLOAD);Promise.all([n.e(1),n.e(5),n.e(9),n.e(25),n.e(142)]).then(n.bind(null,1983)).then((function(n){var r=n.BulkUserUploadDuplicatesView;e.layout.showChildView(_,s.createElement(r,{userType:t,closePopup:function(){return e.layout.closePopup()}}))}))}},{key:"bulkUserUploadReview",value:function(){var e=this,t=se.a.get(ue.a.BULK_USER_UPLOAD);Promise.all([n.e(5),n.e(68)]).then(n.bind(null,1999)).then((function(n){var r=n.BulkUserUploadReviewView;e.layout.showChildView(_,s.createElement(r,{userType:t,closePopup:function(){return e.layout.closePopup()}}))}))}},{key:"bulkUserUploadSuccess",value:function(){var e=this,t=se.a.get(ue.a.BULK_USER_UPLOAD);Promise.all([n.e(5),n.e(80)]).then(n.bind(null,1938)).then((function(n){var r=n.BulkUserUploadSuccessView;e.layout.showChildView(_,s.createElement(r,{closePopup:function(){return e.layout.closePopup()},userType:t}))}))}}],[{key:"router",get:function(){return so}}]),r}(w);function uo(e){return(uo="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)}function lo(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function fo(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function po(e,t,n){return t&&fo(e.prototype,t),n&&fo(e,n),e}function ho(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}}),t&&yo(e,t)}function yo(e,t){return(yo=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function mo(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=go(e);if(t){var i=go(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return vo(this,n)}}function vo(e,t){return!t||"object"!==uo(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function go(e){return(go=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var bo=function(e){ho(n,e);var t=mo(n);function n(){return lo(this,n),t.apply(this,arguments)}return po(n,[{key:"channelName",get:function(){return P.a.SETTINGS}},{key:"appRoutes",get:function(){return{"settings(/)":"index","settings/profile(/)":"profileDetails","settings/account(/)":"account","settings/integrations(/)":"integrations","settings/lti(/)":"ltiPlatforms","settings/lti/consumer/:key(/)":"editLtiConsumer","settings/lti/platform/:key(/)":"editLtiPlatform","settings/video-playback(/)":"videoPlayback","settings/preferences/topics(/)":"topicPreferences","settings/preferences/year-groups(/)":"audiencePreferences","settings/preferences/curriculum(/)":"curriculum","settings/preferences/school-level(/)":"schoolLevel","settings/access(/)":"access","settings/content-permissions(/)":"contentPermissions"}}},{key:"appLinks",get:function(){return["createLtiPlatform","deleteLtiPlatform"]}},{key:"filters",get:function(){return[He,ie,M,Me]}}]),n}(r.a.AppRouter),wo=function(e){ho(i,e);var t=mo(i);function i(){return lo(this,i),t.apply(this,arguments)}return po(i,[{key:"name",get:function(){return"Settings Application"}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:!0,alertRegion:rt}}}},{key:"channelName",get:function(){return P.a.SETTINGS}},{key:"index",value:function(){var e=this;n.e(101).then(n.bind(null,2e3)).then((function(t){var n=t.SettingsView;e.layout.showChildView(tt,c.a.createElement(n,null))}))}},{key:"profileDetails",value:function(){var e=this;Promise.all([n.e(1),n.e(2),n.e(5),n.e(66)]).then(n.bind(null,1979)).then((function(t){var n=t.ProfileDetailsView;e.layout.showChildView(tt,c.a.createElement(n,null))}))}},{key:"account",value:function(){var e=this;Promise.all([n.e(1),n.e(2),n.e(5),n.e(69)]).then(n.bind(null,1974)).then((function(t){var n=t.AccountSettingsView;e.layout.showChildView(tt,c.a.createElement(n,null))}))}},{key:"integrations",value:function(){var e=this;n.e(67).then(n.bind(null,2001)).then((function(t){var n=t.IntegrationSettingsView;e.layout.showChildView(tt,c.a.createElement(n,null))}))}},{key:"videoPlayback",value:function(){var e=this;Promise.all([n.e(1),n.e(62)]).then(n.bind(null,1980)).then((function(t){var n=t.VideoPlaybackSettingsView;e.layout.showChildView(tt,c.a.createElement(n,null))}))}},{key:"contentPermissions",value:function(){var e=this;Promise.all([n.e(11),n.e(63)]).then(n.bind(null,2002)).then((function(t){var n=t.ContentPermissionsView;e.layout.showChildView(tt,c.a.createElement(n,null))}))}},{key:"ltiPlatforms",value:function(){var e=this;n.e(76).then(n.bind(null,1981)).then((function(t){var n=t.LtiPlatformsView;e.layout.showChildView(tt,c.a.createElement(n,null))}))}},{key:"editLtiPlatform",value:function(e){var t=this;Promise.all([n.e(1),n.e(2),n.e(19),n.e(109)]).then(n.bind(null,1986)).then((function(n){var r=n.EditLtiPlatformView;t.layout.showChildView(tt,c.a.createElement(r,{platformId:e}))}))}},{key:"editLtiConsumer",value:function(e){var t=this;Promise.all([n.e(1),n.e(2),n.e(19),n.e(108)]).then(n.bind(null,1987)).then((function(n){var r=n.EditLtiConsumerView;t.layout.showChildView(tt,c.a.createElement(r,{consumerKey:e}))}))}},{key:"createLtiPlatform",value:function(){var e=this;Promise.all([n.e(1),n.e(2),n.e(91)]).then(n.bind(null,2017)).then((function(t){var n=t.CreateLtiPlatformView;e.layout.showChildView(nt,c.a.createElement(n,{closePopup:function(){return e.layout.closePopup()}}))}))}},{key:"deleteLtiPlatform",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},i=t.consumerKey,o=t.platformId;i||o?i&&o?r.a.ErrorHelper.throw(new oe.a("AppLink for deleting LTI platforms cannot accept both a consumerKey and platformId")):n.e(126).then(n.bind(null,1939)).then((function(t){var n=t.DeleteLtiPlatformView;e.layout.showChildView(nt,c.a.createElement(n,{closePopup:function(){return e.layout.closePopup()},consumerKey:i,platformId:o}))})):r.a.ErrorHelper.throw(new oe.a("AppLink for deleting LTI platforms requires either a consumerKey or platformId query params"))}},{key:"topicPreferences",value:function(){var e=this;Promise.all([n.e(7),n.e(42)]).then(n.bind(null,1940)).then((function(t){var n=t.TopicPreferencesView;e.layout.showChildView(tt,c.a.createElement(n,null))}))}},{key:"audiencePreferences",value:function(){var e=this;Promise.all([n.e(7),n.e(50)]).then(n.bind(null,1941)).then((function(t){var n=t.AudiencePreferencesView;e.layout.showChildView(tt,c.a.createElement(n,null))}))}},{key:"curriculum",value:function(){var e=this;Promise.all([n.e(7),n.e(51)]).then(n.bind(null,1942)).then((function(t){var n=t.CurriculumSelectorView;e.layout.showChildView(tt,c.a.createElement(n,null))}))}},{key:"schoolLevel",value:function(){var e=this;Promise.all([n.e(7),n.e(52)]).then(n.bind(null,1943)).then((function(t){var n=t.SchoolLevelSelectorView;e.layout.showChildView(tt,c.a.createElement(n,null))}))}},{key:"access",value:function(){var e=this;Promise.all([n.e(1),n.e(2),n.e(78)]).then(n.bind(null,1988)).then((function(t){var n=t.AccessSettingsView;e.layout.showChildView(tt,c.a.createElement(n,null))}))}}],[{key:"router",get:function(){return bo}}]),i}(w);function _o(e){return(_o="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)}function So(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function To(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Co(e,t,n){return t&&To(e.prototype,t),n&&To(e,n),e}function Eo(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}}),t&&ko(e,t)}function ko(e,t){return(ko=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Oo(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Ao(e);if(t){var i=Ao(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Po(this,n)}}function Po(e,t){return!t||"object"!==_o(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Ao(e){return(Ao=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Io=function(e){Eo(n,e);var t=Oo(n);function n(){return So(this,n),t.apply(this,arguments)}return Co(n,[{key:"channelName",get:function(){return P.a.WATCH_HISTORY}},{key:"appRoutes",get:function(){return{"watch-history(/)":"index"}}},{key:"filters",get:function(){return[He,ie,M]}}]),n}(r.a.AppRouter),xo=function(e){Eo(r,e);var t=Oo(r);function r(){return So(this,r),t.apply(this,arguments)}return Co(r,[{key:"name",get:function(){return"Watch History Application"}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:!0,alertRegion:rt}}}},{key:"channelName",get:function(){return P.a.WATCH_HISTORY}},{key:"index",value:function(){var e=this;Promise.all([n.e(0),n.e(3),n.e(4),n.e(60)]).then(n.bind(null,1989)).then((function(t){var n=t.WatchHistoryView;e.layout.showChildView(tt,c.a.createElement(n,null))}))}}],[{key:"router",get:function(){return Io}}]),r}(w);function Ro(e){return(Ro="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)}function Lo(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function jo(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function No(e,t,n){return t&&jo(e.prototype,t),n&&jo(e,n),e}function Do(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}}),t&&Bo(e,t)}function Bo(e,t){return(Bo=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Uo(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Vo(e);if(t){var i=Vo(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Mo(this,n)}}function Mo(e,t){return!t||"object"!==Ro(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Vo(e){return(Vo=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Fo=function(e){Do(n,e);var t=Uo(n);function n(){return Lo(this,n),t.apply(this,arguments)}return No(n,[{key:"channelName",get:function(){return P.a.SHARE}},{key:"appRoutes",get:function(){return{"share/:id(/)":"viewShareLink"}}},{key:"appLinks",get:function(){return["shareLinkError"]}},{key:"filters",get:function(){return[He,Rr]}}]),n}(r.a.AppRouter),Ho=function(e){Do(r,e);var t=Uo(r);function r(){return Lo(this,r),t.apply(this,arguments)}return No(r,[{key:"name",get:function(){return"Share Application"}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:!0,alertRegion:rt}}}},{key:"channelName",get:function(){return P.a.SHARE}},{key:"viewShareLink",value:function(e,t){var r=this;n.e(137).then(n.bind(null,2018)).then((function(n){var i=n.BaseShareLinkView;r.layout.showChildView(tt,s.createElement(i,{key:"".concat(e,":").concat(ce.LocationUtils.SerializeQueryParams(t)),shareId:e,queryParams:t}))}))}},{key:"shareLinkError",value:function(){var e=this,t=u.Radio.channel("error:view").request("current:error");n.e(138).then(n.bind(null,1944)).then((function(n){var r=n.ShareLinkErrorView;e.layout.showChildView(tt,s.createElement(r,{error:t}))}))}}],[{key:"router",get:function(){return Fo}}]),r}(w);function zo(e){return(zo="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)}function Wo(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function qo(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Go(e,t,n){return t&&qo(e.prototype,t),n&&qo(e,n),e}function Ko(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}}),t&&Yo(e,t)}function Yo(e,t){return(Yo=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Xo(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=$o(e);if(t){var i=$o(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Qo(this,n)}}function Qo(e,t){return!t||"object"!==zo(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function $o(e){return($o=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Zo=function(e){Ko(n,e);var t=Xo(n);function n(){return Wo(this,n),t.apply(this,arguments)}return Go(n,[{key:"channelName",get:function(){return P.a.INTERACTIVES}},{key:"appRoutes",get:function(){return{"interactive/:id/edit":"editInteractive","interactive/:id(/:slug)":"interactive"}}},{key:"appLinks",get:function(){return["editInteractiveDetails","previewQuestions","printQuestions","copyInteractive","newInteractive","newClipInteractive","unpublishInteractive","shareInteractive","deleteInteractive"]}},{key:"filters",get:function(){return[He,ie,M,Me]}}]),n}(r.a.AppRouter),Jo=function(e){Ko(r,e);var t=Xo(r);function r(){return Wo(this,r),t.apply(this,arguments)}return Go(r,[{key:"name",get:function(){return"Interactives Application"}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:!0,alertRegion:rt}}}},{key:"channelName",get:function(){return P.a.INTERACTIVES}},{key:"interactive",value:function(e,t){var r=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=("string"==typeof t?i:t)||{};Promise.all([n.e(8),n.e(0),n.e(3),n.e(4),n.e(30)]).then(n.bind(null,1945)).then((function(t){var n=t.InteractiveView;r.layout.showChildView(tt,s.createElement(n,{id:e,queryParams:o}))}))}},{key:"newInteractive",value:function(e){var t=this;n.e(97).then(n.bind(null,1946)).then((function(n){var r=n.NewInteractiveView;t.layout.showChildView(nt,s.createElement(r,{videoId:e,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"newClipInteractive",value:function(e){var t=this;n.e(103).then(n.bind(null,2019)).then((function(n){var r=n.NewClipInteractiveView;t.layout.showChildView(nt,s.createElement(r,{clipId:e,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"editInteractive",value:function(e){var t=this;Promise.all([n.e(8),n.e(13),n.e(61)]).then(n.bind(null,1990)).then((function(n){var r=n.EditInteractiveView;t.layout.showChildView(tt,s.createElement(r,{id:e}))}))}},{key:"editInteractiveDetails",value:function(e,t){var r=this;Promise.all([n.e(1),n.e(2),n.e(0),n.e(81)]).then(n.bind(null,2020)).then((function(n){var i=n.EditInteractiveDetailsView;r.layout.showChildView(nt,s.createElement(i,{interactiveMetadataId:e,publish:!!t.publish,closePopup:function(){return r.layout.closePopup()}}))}))}},{key:"previewQuestions",value:function(e){var t=this;Promise.all([n.e(12),n.e(56)]).then(n.bind(null,1947)).then((function(n){var r=n.PreviewQuestionsView;t.layout.showChildView(nt,s.createElement(r,{id:e,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"printQuestions",value:function(e){var t=this;Promise.all([n.e(12),n.e(104)]).then(n.bind(null,1948)).then((function(n){var r=n.PrintInteractiveView;t.layout.showChildView(nt,s.createElement(r,{id:e,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"copyInteractive",value:function(e,t){var r=this;n.e(112).then(n.bind(null,1949)).then((function(n){var i=n.CopyInteractiveView;r.layout.showChildView(nt,s.createElement(i,{interactiveMetadataId:e,closePopup:function(){return r.layout.closePopup()},fromEdit:t.fromEdit}))}))}},{key:"shareInteractive",value:function(e){var t=this;n.e(124).then(n.bind(null,1950)).then((function(n){var r=n.ShareInteractiveView;t.layout.showChildView(nt,s.createElement(r,{interactiveMetadataId:e,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"unpublishInteractive",value:function(e){var t=this;n.e(125).then(n.bind(null,1951)).then((function(n){var r=n.UnpublishInteractiveView;t.layout.showChildView(nt,s.createElement(r,{interactiveMetadataId:e,closePopup:function(){return t.layout.closePopup()}}))}))}},{key:"deleteInteractive",value:function(e){var t=this;n.e(123).then(n.bind(null,1952)).then((function(n){var r=n.DeleteInteractiveView;t.layout.showChildView(nt,s.createElement(r,{interactiveMetadataId:e,closePopup:function(){return t.layout.closePopup()}}))}))}}],[{key:"router",get:function(){return Zo}}]),r}(w);function ea(e){return(ea="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)}function ta(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function na(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ra(e,t,n){return t&&na(e.prototype,t),n&&na(e,n),e}function ia(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}}),t&&oa(e,t)}function oa(e,t){return(oa=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function aa(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ca(e);if(t){var i=ca(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return sa(this,n)}}function sa(e,t){return!t||"object"!==ea(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function ca(e){return(ca=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var ua=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{c(r.next(e))}catch(e){o(e)}}function s(e){try{c(r.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}c((r=r.apply(e,t||[])).next())}))},la=function(e){ia(n,e);var t=aa(n);function n(){return ta(this,n),t.apply(this,arguments)}return ra(n,[{key:"channelName",get:function(){return P.a.LAUNCHPAD}},{key:"appRoutes",get:function(){return{join:"joinClassroomPrompt","join/:code(/)":"joinClassroom"}}},{key:"appLinks",get:function(){return["passwordProtectedShareLink","shareLinkSignIn","loginLanding"]}},{key:"filters",get:function(){return[He]}}]),n}(r.a.AppRouter),fa=function(e){ia(i,e);var t=aa(i);function i(){return ta(this,i),t.apply(this,arguments)}return ra(i,[{key:"name",get:function(){return"Launchpad Application"}},{key:"layoutOptions",get:function(){return{name:O}}},{key:"channelName",get:function(){return P.a.LAUNCHPAD}},{key:"passwordProtectedShareLink",value:function(e,t){return ua(this,void 0,void 0,regeneratorRuntime.mark((function i(){var o,a;return regeneratorRuntime.wrap((function(i){for(;;)switch(i.prev=i.next){case 0:return i.next=2,n.e(93).then(n.bind(null,1953));case 2:if(o=i.sent,a=o.PasswordProtectedShareLinkView,null==t?void 0:t.appLink){i.next=7;break}return r.a.ErrorHelper.throw(new oe.a("PasswordProtectedShareLinkView must be passed an appLink as a param")),i.abrupt("return");case 7:this.layout.showChildView(tt,s.createElement(a,{shareId:e,appLink:t.appLink}));case 8:case"end":return i.stop()}}),i,this)})))}},{key:"shareLinkSignIn",value:function(e,t){return ua(this,void 0,void 0,regeneratorRuntime.mark((function r(){var i,o;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,n.e(92).then(n.bind(null,1954));case 2:i=r.sent,o=i.ShareLinkSignIn,this.layout.showChildView(tt,s.createElement(o,{shareId:e,redirectUrl:t.redirectUrl,customerId:t.customerId}));case 5:case"end":return r.stop()}}),r,this)})))}},{key:"joinClassroomPrompt",value:function(){return ua(this,void 0,void 0,regeneratorRuntime.mark((function e(){var t,r;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,n.e(85).then(n.bind(null,2021));case 2:t=e.sent,r=t.JoinClassroomPromptView,this.layout.showChildView(tt,s.createElement(r,null));case 5:case"end":return e.stop()}}),e,this)})))}},{key:"joinClassroom",value:function(e){return ua(this,void 0,void 0,regeneratorRuntime.mark((function t(){var r,i;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,n.e(99).then(n.bind(null,2022));case 2:r=t.sent,i=r.JoinClassroomView,this.layout.showChildView(tt,s.createElement(i,{joinCode:e}));case 5:case"end":return t.stop()}}),t,this)})))}},{key:"loginLanding",value:function(e){return ua(this,void 0,void 0,regeneratorRuntime.mark((function t(){var r,i;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,n.e(100).then(n.bind(null,1955));case 2:r=t.sent,i=r.LoginLandingView,this.layout.showChildView(tt,s.createElement(i,{skipPrompt:e.skipPrompt,showJoinCode:e.showJoinCode}));case 5:case"end":return t.stop()}}),t,this)})))}}],[{key:"router",get:function(){return la}}]),i}(w),pa=n(390);function da(e){return(da="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)}function ha(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ya(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ma(e,t,n){return t&&ya(e.prototype,t),n&&ya(e,n),e}function va(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}}),t&&ga(e,t)}function ga(e,t){return(ga=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function ba(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=_a(e);if(t){var i=_a(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return wa(this,n)}}function wa(e,t){return!t||"object"!==da(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function _a(e){return(_a=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Sa=function(e){va(n,e);var t=ba(n);function n(){return ha(this,n),t.apply(this,arguments)}return ma(n,[{key:"channelName",get:function(){return P.a.LIBRARIES}},{key:"appRoutes",get:function(){return{"libraries/:id/recently-added":"recentlyAdded","libraries/:id(/:slug)":"library","libraries/:id/folders/:id(/:slug)":"folder"}}},{key:"filters",get:function(){return[He,ie,M]}}]),n}(r.a.AppRouter),Ta=function(e){va(r,e);var t=ba(r);function r(){return ha(this,r),t.apply(this,arguments)}return ma(r,[{key:"name",get:function(){return"Libraries Application"}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:!0,alertRegion:T}}}},{key:"channelName",get:function(){return P.a.LIBRARIES}},{key:"library",value:function(e){var t=this;Promise.all([n.e(0),n.e(6),n.e(48)]).then(n.bind(null,1956)).then((function(n){var r=n.LibraryView;t.layout.showChildView(_,c.a.createElement(r,{id:e}))}))}},{key:"recentlyAdded",value:function(e){var t=this;Promise.all([n.e(0),n.e(3),n.e(4),n.e(49)]).then(n.bind(null,1957)).then((function(n){var r=n.RecentlyAddedView;t.layout.showChildView(_,c.a.createElement(r,{id:e}))}))}},{key:"folder",value:function(e,t,r,i){var o=this,a="string"==typeof r?null==i?void 0:i.sort:null==r?void 0:r.sort,s=a&&pa.a.getValidSortTypeFromParam(a);Promise.all([n.e(0),n.e(3),n.e(4),n.e(43)]).then(n.bind(null,2003)).then((function(n){var r=n.LibraryFolderView;o.layout.showChildView(_,c.a.createElement(r,{libraryId:e,folderId:t,sort:s}))}))}}],[{key:"router",get:function(){return Sa}}]),r}(w);function Ca(e){return(Ca="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)}function Ea(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ka(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Oa(e,t,n){return t&&ka(e.prototype,t),n&&ka(e,n),e}function Pa(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}}),t&&Aa(e,t)}function Aa(e,t){return(Aa=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Ia(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Ra(e);if(t){var i=Ra(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return xa(this,n)}}function xa(e,t){return!t||"object"!==Ca(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Ra(e){return(Ra=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var La=function(e){Pa(n,e);var t=Ia(n);function n(){return Ea(this,n),t.apply(this,arguments)}return Oa(n,[{key:"channelName",get:function(){return P.a.DASHBOARD}},{key:"appRoutes",get:function(){return{"discover(/)":"index","discover/:id/:name":"dashboard"}}},{key:"filters",get:function(){return[He,ie,M]}}]),n}(r.a.AppRouter),ja=function(e){Pa(r,e);var t=Ia(r);function r(){return Ea(this,r),t.apply(this,arguments)}return Oa(r,[{key:"name",get:function(){return"Student Discover Application"}},{key:"channelName",get:function(){return P.a.DASHBOARD}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:!0,alertRegion:rt}}}},{key:"index",value:function(){var e=this;Promise.all([n.e(0),n.e(6),n.e(21)]).then(n.bind(null,1971)).then((function(t){var n=t.DashboardView;e.layout.showChildView(tt,s.createElement(n,null))}))}},{key:"dashboard",value:function(e){var t=this;Promise.all([n.e(0),n.e(3),n.e(4),n.e(20)]).then(n.bind(null,2004)).then((function(n){var r=n.DashboardWidgetView;t.layout.showChildView(tt,s.createElement(r,{widgetId:e}))}))}}],[{key:"router",get:function(){return La}}]),r}(w);function Na(e){return(Na="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)}function Da(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ba(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ua(e,t,n){return t&&Ba(e.prototype,t),n&&Ba(e,n),e}function Ma(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}}),t&&Va(e,t)}function Va(e,t){return(Va=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Fa(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=za(e);if(t){var i=za(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ha(this,n)}}function Ha(e,t){return!t||"object"!==Na(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function za(e){return(za=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Wa=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{c(r.next(e))}catch(e){o(e)}}function s(e){try{c(r.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}c((r=r.apply(e,t||[])).next())}))},qa=function(e){Ma(n,e);var t=Fa(n);function n(){return Da(this,n),t.apply(this,arguments)}return Ua(n,[{key:"channelName",get:function(){return P.a.STUDENT_FEED}},{key:"appRoutes",get:function(){return{"(/)":"index"}}},{key:"filters",get:function(){return[He,ie,M]}}]),n}(r.a.AppRouter),Ga=function(e){Ma(r,e);var t=Fa(r);function r(){return Da(this,r),t.apply(this,arguments)}return Ua(r,[{key:"name",get:function(){return"Student Feed Application"}},{key:"channelName",get:function(){return P.a.STUDENT_FEED}},{key:"layoutOptions",get:function(){return{name:k,options:{showNav:!0,alertRegion:rt}}}},{key:"index",value:function(e){return Wa(this,void 0,void 0,regeneratorRuntime.mark((function t(){var r,i;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,Promise.all([n.e(0),n.e(3),n.e(6),n.e(45)]).then(n.bind(null,1967));case 2:r=t.sent,i=r.StudentFeedView,this.layout.showChildView(tt,s.createElement(i,{date:e.date,key:e.date}));case 5:case"end":return t.stop()}}),t,this)})))}}],[{key:"router",get:function(){return qa}}]),r}(w);var Ka,Ya=n(4);!function(e){e.Fifo="FifoMemoryCache"}(Ka||(Ka={}));var Xa=n(100),Qa=n(18);function $a(e){return($a="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)}function Za(e){return function(e){if(Array.isArray(e))return Ja(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return Ja(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Ja(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ja(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function es(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ts(e,t){return(ts=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function ns(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=is(e);if(t){var i=is(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return rs(this,n)}}function rs(e,t){return!t||"object"!==$a(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function is(e){return(is=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var os=function(e){!function(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}}),t&&ts(e,t)}(o,e);var t,n,r,i=ns(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=i.call(this)).size=e.size,t.cache={},t.cachedkeys=[],t}return t=o,(n=[{key:"name",get:function(){return Ka.Fifo}},{key:"removeCacheKey",value:function(e){this.cachedkeys=Ya.without(this.cachedkeys,e)}},{key:"has",value:function(e){return!!this.cache[e]}},{key:"get",value:function(e){return this.cache[e]}},{key:"set",value:function(e,t){e&&t||Qa.c.throw(new oe.a("Must provide a cache key and a value to cache in FifoMemoryCache.")),this.has(e)&&this.removeCacheKey(e),this.cachedkeys.push(e),this.cache[e]=t,this.cachedkeys.length>this.size&&delete this.cache[this.cachedkeys.shift()]}},{key:"getOrSet",value:function(e,t){if(this.has(e))return this.get(e);var n=t();return this.set(e,n),n}},{key:"remove",value:function(e){return!!this.has(e)&&(delete this.cache[e],this.removeCacheKey(e),!0)}},{key:"invalidate",value:function(e,t){var n=this,r=Ya.object(this.cachedkeys,this.cachedkeys),i=[];Ya.each(e,(function(e){var t;r[e]&&i.push(e);var n=new RegExp(e,"i"),o=Ya.filter(r,(function(e){return n.test(e)}));(t=i).push.apply(t,Za(o))})),i.length&&(i=Ya.uniq(i),Ya.each(i,(function(e){delete n.cache[e],Ya.isFunction(t)&&t(e)})),this.cachedkeys=Ya.without.apply(Ya,[this.cachedkeys].concat(Za(i))))}}])&&es(t.prototype,n),r&&es(t,r),o}(Xa.a);var as,ss=n(69),cs=n(206),us=n(16),ls=n(158);!function(e){e.Ajax="AjaxDataProvider",e.Notifications="NotificationsSignalRDataProvider"}(as||(as={}));var fs=function(e,t,n){if(!n||!n.errorCode)return e[t];var r="".concat(n.errorCode);return n.errorSubCode&&(r+=".".concat(n.errorSubCode)),e[r]||e[t]};function ps(e){return(ps="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)}function ds(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function hs(e,t){return(hs=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function ys(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=vs(e);if(t){var i=vs(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ms(this,n)}}function ms(e,t){return!t||"object"!==ps(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function vs(e){return(vs=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var gs=function(e){!function(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}}),t&&hs(e,t)}(o,e);var t,n,r,i=ys(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),t=i.call(this,e),$.ajaxSetup({cache:!1,contentType:"application/json; charset=utf-8"}),t.successMiddleware={},t.errorMiddleware={},t.dataServiceErrorMessageMappings=e.dataServiceErrorMessageMappings,t.defaultErrorMessageKey=e.defaultErrorMessageKey,t}return t=o,(n=[{key:"name",get:function(){return as.Ajax}},{key:"parseUrl",value:function(e){var t=document.createElement("a");return t.href=e,""===t.host&&(t.href=t.href),t}},{key:"makeHttps",value:function(e){var t=this.parseUrl(e);return"http:"===t.protocol&&(t.protocol="https:"),t.href}},{key:"base",value:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};n||(n=us.a.GET);var i=Ya.defaults(r,{forceHttps:!1}),o={url:e,method:n,type:n};t&&(o.data=n===us.a.POST||n===us.a.PUT?JSON.stringify(t):t),i.forceHttps&&(o.url=this.makeHttps(o.url)),i.traditional&&(o.traditional=i.traditional);var a=$.ajax(o);return Ya.keys(this.successMiddleware).length&&a.done(Ya.values(this.successMiddleware)),Ya.keys(this.errorMiddleware).length&&a.fail(Ya.values(this.errorMiddleware)),a}},{key:"create",value:function(e,t,n){var r=n.channel,i=n.successEvent,o=n.errorEvent;this.base(e,t,us.a.POST).done((function(e,t,n){return r.trigger(i,e,t,n)})).fail((function(e,t,n){return r.trigger(o,e,t,n)}))}},{key:"read",value:function(e,t){var n=t.channel,r=t.successEvent,i=t.errorEvent;this.base(e,null,us.a.GET).done((function(e,t,i){n.trigger(r,e,t,i)})).fail((function(e,t,r){n.trigger(i,e,t,r)}))}},{key:"update",value:function(e,t,n){var r=n.channel,i=n.successEvent,o=n.errorEvent;this.base(e,t,us.a.PUT).done((function(e,t,n){return r.trigger(i,e,t,n)})).fail((function(e,t,n){return r.trigger(o,e,t,n)}))}},{key:"delete",value:function(e,t){var n=t.channel,r=t.successEvent,i=t.errorEvent;this.base(e,null,us.a.DELETE).done((function(e,t,i){return n.trigger(r,e,t,i)})).fail((function(e,t,r){return n.trigger(i,e,t,r)}))}},{key:"useMiddleware",value:function(e,t){this.successMiddleware[e]||(this.successMiddleware[e]=t)}},{key:"useErrorMiddleware",value:function(e,t){this.errorMiddleware[e]||(this.errorMiddleware[e]=t)}},{key:"parseError",value:function(e){var t=e.responseJSON,n=cs.a;switch(n.code=e.status,n.message=fs(this.dataServiceErrorMessageMappings,this.defaultErrorMessageKey,t),e.status){case 400:n.type=ls.a.BadRequest;break;case 401:n.type=ls.a.Unauthorized;break;case 403:n.type=ls.a.Forbidden;break;case 404:n.type=ls.a.NotFound;break;case 500:n.type=ls.a.InternalServer}return n}}])&&ds(t.prototype,n),r&&ds(t,r),o}(ss.Object);var bs=n(76),ws=n(88);function _s(e){return(_s="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)}function Ss(e){return function(e){if(Array.isArray(e))return Ts(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return Ts(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Ts(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ts(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Cs(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Es(e,t){return(Es=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function ks(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=As(e);if(t){var i=As(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Os(this,n)}}function Os(e,t){return!t||"object"!==_s(t)&&"function"!=typeof t?Ps(e):t}function Ps(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function As(e){return(As=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Is=function(e){!function(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}}),t&&Es(e,t)}(o,e);var t,n,r,i=ks(o);function o(e){var t;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),t=i.call(this,e),Ya.result(Ps(t),"name")||Qa.c.throw(new oe.a("Must provide a name when extending BaseDataService")),Ya.result(Ps(t),"channelName")||Qa.c.throw(new oe.a("Must provide a channelName for ".concat(Ya.result(Ps(t),"name"))));var n=[].concat(Ss(t.defaultProps),Ss(t.props||[]));return t.dataRequestSignatures={},t.mergeOptions(e,n),t}return t=o,(n=[{key:"defaultProps",get:function(){return["dataProvider","cache","bootstrapData","defaultErrorHandler","alertService"]}},{key:"getCursors",value:function(e){var t=this.cache.get(e);return t?t.cursors:{}}},{key:"clearCacheAndGet",value:function(e){var t=this,n=e.callback,r=e.errorCallback,i=e.eventPrefix,o=this.getEventNames(i),a=o.syncEvent,s=o.errorEvent,c=this.cache.get(i);if(c&&c.openRequest)return this.listenToOnce(this.getChannel(),a,(function(e){Ya.isFunction(r)&&t.stopListening(t.getChannel(),s,r),Ya.isFunction(n)&&n(e)})),void this.listenToOnce(this.getChannel(),s,(function(){Ya.isFunction(n)&&t.stopListening(t.getChannel(),a,n),Ya.isFunction(r)&&r()}));this.cache.remove(e.eventPrefix),this.get(e)}},{key:"get",value:function(e){var t=this,n=e.callback,r=e.errorCallback,i=e.eventPrefix,o=e.resource,a=e.formatData,s=e.expiryTime,c=e.successHandler,u=e.errorHandler,l=e.bootstrapName,f=this.getEventNames(i),p=f.syncEvent,d=f.requestEvent,h=f.successEvent,y=f.errorEvent,m=this.getChannel(),v=this.currentTimestamp();this.bootstrapData&&this.bootstrapData[l]&&(this.cacheData(i,this.bootstrapData[l],a,{openRequest:!1,timestamp:v}),delete this.bootstrapData[l]);var g,b=this.cache.get(i);b&&(g=b.data);var w=b&&b.openRequest,_=this.isExpired(i,s);if(w&&(this.listenToOnce(m,p,(function(e){Ya.isFunction(r)&&t.stopListening(t.getChannel(),y,r),Ya.isFunction(n)&&n(e)})),this.listenToOnce(m,y,(function(){Ya.isFunction(n)&&t.stopListening(t.getChannel(),p,n),Ya.isFunction(r)&&r()}))),this.cache.has(i)&&!_||(m.trigger(d),this.listenToResponse({eventPrefix:i,formatData:a,cacheOptions:{timestamp:v},callback:n,errorCallback:r,successHandler:c,errorHandler:u}),this.cacheData(i,null,null,{openRequest:!0,timestamp:v}),this.dataProvider.read(o,{channel:this.getTransportChannel(),successEvent:h,errorEvent:y})),g&&Ya.isFunction(n)&&!_&&n(g),g)return g}},{key:"create",value:function(e){var t=e.eventPrefix,n=e.resource,r=e.data,i=e.formatData,o=e.callback,a=e.errorCallback,s=e.invalidationKeys,c=e.successHandler,u=e.errorHandler,l=this.getEventNames(e.eventPrefix),f=l.requestEvent,p=l.successEvent,d=l.errorEvent,h=this.getChannel(),y=this.getTransportChannel();h.trigger(f),this.listenToResponse({eventPrefix:t,formatData:i,invalidationKeys:s,callback:o,errorCallback:a,successHandler:c,errorHandler:u}),this.dataProvider.create(n,r,{channel:y,successEvent:p,errorEvent:d})}},{key:"update",value:function(e){var t=e.data,n=e.callback,r=e.errorCallback,i=e.resource,o=e.formatData,a=e.eventPrefix,s=e.invalidationKeys,c=e.errorHandler,u=e.successHandler,l=this.getEventNames(e.eventPrefix),f=l.requestEvent,p=l.successEvent,d=l.errorEvent,h=this.getChannel(),y=this.getTransportChannel();h.trigger(f),this.listenToResponse({eventPrefix:a,formatData:o,invalidationKeys:s,callback:n,errorCallback:r,successHandler:u,errorHandler:c}),this.dataProvider.update(i,t,{channel:y,successEvent:p,errorEvent:d})}},{key:"delete",value:function(e){var t=e.eventPrefix,n=e.resource,r=e.callback,i=e.errorCallback,o=e.invalidationKeys,a=e.successHandler,s=e.errorHandler,c=this.getEventNames(t),u=c.successEvent,l=c.errorEvent,f=this.getTransportChannel();this.listenToResponse({eventPrefix:t,invalidationKeys:o,callback:r,errorCallback:i,cacheOptions:{noCache:!0,clearCacheKey:!0},successHandler:a,errorHandler:s}),this.dataProvider.delete(n,{channel:f,successEvent:u,errorEvent:l})}},{key:"listenToResponse",value:function(e){var t=this,n=e.eventPrefix,r=e.formatData,i=e.callback,o=e.errorCallback,a=e.successHandler,s=e.errorHandler,c=e.invalidationKeys,u=e.cacheOptions,l=void 0===u?{}:u,f=this.getEventNames(n),p=f.syncEvent,d=f.successEvent,h=f.errorEvent,y=f.successAlertEvent,m=f.errorAlertEvent,v=this.getChannel(),g=this.getTransportChannel(),b=this.getAlertChannel();Ya.isFunction(i)&&this.listenToOnce(v,p,i),Ya.isFunction(o)&&this.listenToOnce(v,h,o),this.stopListening(b,y),this.stopListening(b,m),Ya.isFunction(a)&&this.listenToOnce(b,y,a),Ya.isFunction(s)&&this.listenToOnce(b,m,s),!Ya.isFunction(s)&&!1!==s&&Ya.isFunction(this.defaultErrorHandler)&&this.listenToOnce(b,m,this.defaultErrorHandler),this.hasRequestSignature(n)||(this.setRequestSignature(n),this.listenTo(g,d,(function(e){t.stopListening(v,h,o);for(var i=arguments.length,a=new Array(i>1?i-1:0),s=1;s<i;s++)a[s-1]=arguments[s];b.trigger.apply(b,[y,e].concat(a));var u=l.noCache?t.formatData(e,r):t.cacheData(n,e,r);l.clearCacheKey&&t.cache.remove(n),v.trigger(p,u),c&&c.length&&t.cache.invalidate(c,(function(e){return v.trigger("".concat(e,":invalidate"))}))})),this.listenTo(g,h,(function(){var e;t.stopListening(v,p,i);var r=(e=t.dataProvider).parseError.apply(e,arguments);b.trigger(m,r),v.trigger(h,r),l.noCache||t.cacheData(n,null,null)})))}},{key:"cacheData",value:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=r.openRequest,o=void 0!==i&&i,a=r.timestamp;a||(a=this.currentTimestamp());var s=this.processPagination(t),c=this.formatData(t,n);return this.cache.set(e,{data:c,timestamp:a,cursors:s,openRequest:o}),c}},{key:"processPagination",value:function(e){if(e){var t=e.pagination;if(t)return t.cursors?t.cursors:Ya.isUndefined(t.offset)||Ya.isUndefined(t.pageSize)?t.page?this.convertLegacyPaginationToCursors(t):void 0:this.convertOffsetPaginationToCursors(t)}}},{key:"formatData",value:function(e,t){return Ya.isFunction(t)?t(e):e}},{key:"chain",value:function(){var e=this,t=[],n=function(e,t){Ya.isFunction(e)&&e(t)},r=function(r,o){return t.push((function(){var i=r.callback;r.callback=function(e){n(i,e),n(t.shift())},e[o](r)})),i},i={func:function(e){return t.push((function(){e(t.shift()||function(){})})),i},get:function(e){return r(e,"get")},create:function(e){return r(e,"create")},update:function(e){return r(e,"update")},delete:function(e){return r(e,"delete")},run:function(){n(t.shift())}};return i}},{key:"invalidateCache",value:function(e){e&&e.length&&this.cache.invalidate(e)}},{key:"currentTimestamp",value:function(){return(new Date).valueOf()}},{key:"isExpired",value:function(e,t){if(!t)return!1;var n=this.cache.get(e);if(!n||!n.timestamp)return!0;var r=1e3*t;return n.timestamp<this.currentTimestamp()-r}},{key:"getEventNames",value:function(e){return{syncEvent:"".concat(e,":sync"),requestEvent:"".concat(e,":request"),successEvent:"".concat(e,":success"),errorEvent:"".concat(e,":error"),successAlertEvent:"".concat(e,":success:alert"),errorAlertEvent:"".concat(e,":error:alert")}}},{key:"getTransportChannel",value:function(){return u.Radio.channel("".concat(this.channelName,":transport"))}},{key:"getAlertChannel",value:function(){return u.Radio.channel("".concat(this.channelName,":alert"))}},{key:"setRequestSignature",value:function(e){this.dataRequestSignatures[e]=e}},{key:"hasRequestSignature",value:function(e){return!!this.dataRequestSignatures[e]}},{key:"convertOffsetPaginationToCursors",value:function(e){var t=e.offset,n=e.pageSize,r=e.totalItems,i=r>0&&t<r&&t+n,o=r>0&&t>0&&Math.max(t-n,0),a={};if(i&&i<r&&(a.next=i.toString()),Ya.isNumber(o)&&(a.previous=o.toString()),!Ya.isEmpty(a))return a}},{key:"convertLegacyPaginationToCursors",value:function(e){var t=e.page,n=e.totalPages,r=Ya.isNumber(t)&&t>0&&t<n&&t+1,i=Ya.isNumber(t)&&t>1&&t-1,o={};if(r&&r<=n&&(o.next=r.toString()),i&&(o.previous=i.toString()),!Ya.isEmpty(o))return o}}])&&Cs(t.prototype,n),r&&Cs(t,r),o}(Xa.a),xs=n(37),Rs=n(107),Ls=n(70),js=n(49),Ns=n(209);function Ds(e){return(Ds="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)}function Bs(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Us(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ms(e,t){return(Ms=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Vs(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Hs(e);if(t){var i=Hs(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Fs(this,n)}}function Fs(e,t){return!t||"object"!==Ds(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Hs(e){return(Hs=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var zs=function(e){!function(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}}),t&&Ms(e,t)}(o,e);var t,n,r,i=Vs(o);function o(){return Bs(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"name",get:function(){return xs.a.Language}},{key:"channelName",get:function(){return js.b.LANGUAGE}},{key:"getLanguageConfig",value:function(e){var t={locale:"",phrases:null};this.get({resource:"/api/locale",eventPrefix:Ls.a.LOCALE,expiryTime:Rs.a.STANDARD,bootstrapName:Ns.a.LOCALE,callback:function(n){t.locale=n,t.phrases&&Ya.isFunction(e)&&e(t)}}),this.get({resource:"/api/phrases",eventPrefix:Ls.a.PHRASES,expiryTime:Rs.a.STANDARD,bootstrapName:Ns.a.PHRASES,callback:function(n){t.phrases=n,t.locale&&Ya.isFunction(e)&&e(t)}})}}])&&Us(t.prototype,n),r&&Us(t,r),o}(Is);function Ws(e){return(Ws="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)}function qs(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Gs(e,t){return(Gs=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Ks(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Xs(e);if(t){var i=Xs(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ys(this,n)}}function Ys(e,t){return!t||"object"!==Ws(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Xs(e){return(Xs=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Qs=function(e){!function(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}}),t&&Gs(e,t)}(n,e);var t=Ks(n);function n(){return qs(this,n),t.apply(this,arguments)}return n}(r.a.Model);function $s(e){return($s="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)}function Zs(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Js(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ec(e,t){return(ec=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function tc(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=rc(e);if(t){var i=rc(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return nc(this,n)}}function nc(e,t){return!t||"object"!==$s(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function rc(e){return(rc=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var ic=function(e){!function(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}}),t&&ec(e,t)}(o,e);var t,n,r,i=tc(o);function o(){return Zs(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"name",get:function(){return xs.a.NotificationSocket}},{key:"channelName",get:function(){return js.b.NOTIFICATIONS_SOCKET}},{key:"receiveLatestNotifications",value:function(e){return this.get({callback:e,formatData:function(e){return new Qs(e)},resource:"notify",eventPrefix:"".concat(Ls.a.NOTIFICATIONS,":new")})}},{key:"receiveUnreadNotificationCount",value:function(e){return this.get({callback:e,resource:"notifyCount",eventPrefix:"".concat(Ls.a.NOTIFICATIONS,":count")})}}])&&Js(t.prototype,n),r&&Js(t,r),o}(Is),oc=n(63),ac=n(27),sc=n(159);function cc(e){return(cc="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)}function uc(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function lc(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function fc(e,t){return(fc=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function pc(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=hc(e);if(t){var i=hc(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return dc(this,n)}}function dc(e,t){return!t||"object"!==cc(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function hc(e){return(hc=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var yc=function(e){!function(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}}),t&&fc(e,t)}(o,e);var t,n,r,i=pc(o);function o(){return uc(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"model",get:function(){return Qs}},{key:"parse",value:function(e){return e.data||e}}])&&lc(t.prototype,n),r&&lc(t,r),o}(r.a.Collection);function mc(e){return(mc="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)}function vc(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function gc(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function bc(e,t){return(bc=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function wc(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Sc(e);if(t){var i=Sc(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return _c(this,n)}}function _c(e,t){return!t||"object"!==mc(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Sc(e){return(Sc=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Tc=function(e,t){var n="/api/domain/v2/objects/".concat(e,"/notifications?query={orderbydesc:datecreated}");if(!t)return n;var r=t.limit,i=t.cursor,o=t.before,a=[],s=ac.a.buildFilter({limit:r,before:o});return s&&a.push("filter=".concat(s)),i&&a.push("cursor=".concat(i)),a.length?"".concat(n,"&").concat(a.join("&")):n},Cc=function(e){return"/api/notifications/v1/notifications/".concat(e)},Ec="/api/notifications/v1/notifications",kc="/api/domain/v1/notifications",Oc=function(e){!function(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}}),t&&bc(e,t)}(o,e);var t,n,r,i=wc(o);function o(){return vc(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"name",get:function(){return xs.a.Notification}},{key:"channelName",get:function(){return js.b.NOTIFICATIONS}},{key:"lang",get:function(){return"notifications.services"}},{key:"getNotifications",value:function(e,t,n,r){return this.get({resource:Tc(e,t),expiryTime:Rs.a.STANDARD,eventPrefix:n,formatData:function(e){return new yc(e,{parse:!0})},callback:r})}},{key:"markRead",value:function(e,t){return this.update({callback:t,data:{notificationStatus:sc.a.Read},resource:Cc(e),eventPrefix:"".concat(Ls.a.NOTIFICATIONS,":read")})}},{key:"markSeen",value:function(e){var t=oc().utc().toISOString();return this.update({callback:e,data:{notificationStatus:sc.a.Seen},resource:"".concat(Ec,"?to=").concat(t,"¬ificationStatus=").concat(sc.a.Received),eventPrefix:"".concat(Ls.a.NOTIFICATIONS,":seen")})}},{key:"getNotificationsCursors",value:function(e){return this.getCursors(e)}},{key:"suggestEdit",value:function(e,t){return this.create({resource:"".concat(kc),eventPrefix:"".concat(Ls.a.SUGGEST_EDIT),callback:t,data:e,successHandler:this.alertService.success(G.a.getPhrase(this.lang,"suggestEditSubmit")),errorHandler:this.alertService.error({useXHR:!0})})}}])&&gc(t.prototype,n),r&&gc(t,r),o}(Is),Pc=n(240),Ac=n(25),Ic=n(68),xc=n(59),Rc=n(136),Lc=n.n(Rc);function jc(e){var t=e.alert,n=e.svgName,r=e.svgClassName,i=e.closeAlert,o=t.message,a=t.heading,c=t.appLink,u=t.appLinkText,l=t.appLinkClassName,f=void 0===l?"":l;return s.createElement(s.Fragment,null,s.createElement("div",{className:"d-inline-block ".concat(Lc.a.icon)},s.createElement(Ic.a,{svgName:n,className:"svg-container ".concat(r)})),s.createElement("div",{className:"pl-2 d-inline-block ".concat(Lc.a.alertContent)},s.createElement("p",{className:"p-0 m-0 pb-1 ".concat(Lc.a.heading)},a),s.createElement("p",{className:"p-0 text-break clamp-4 ".concat(Lc.a.message),dangerouslySetInnerHTML:{__html:o}}),!!c&&s.createElement(xc.a,{className:f,appLink:c},u)),s.createElement("div",{className:"close d-inline-block cursor-pointer",role:"button",onClick:i},"×"))}function Nc(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return Dc(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Dc(e,t)}(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 Dc(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var Bc=function(e){switch(e.type){case bs.a.Success:return Ac.b.CheckCircleOutline;case bs.a.Fail:case bs.a.Warning:return Ac.b.Warning;case bs.a.Info:default:return Ac.b.Info}};function Uc(e){var t=e.alert,n=e.closeAlert,r=Nc(s.useState(!0),2),i=r[0],o=r[1],a=s.useRef();s.useEffect((function(){i?a.current=window.setTimeout(n,3e3):clearTimeout(a.current)}),[i]);var c="text-".concat(t.type.toLowerCase());return s.createElement("li",{className:"bg-white mt-2 p-2 show clearfix ".concat(Lc.a.alertItem),onMouseEnter:function(){return o(!1)},onMouseLeave:function(){return o(!0)}},s.createElement(jc,{alert:t,svgName:Bc(t),svgClassName:c,closeAlert:n}))}function Mc(e){var t=e.alerts,n=e.removeAlert;return s.createElement("div",{className:Lc.a.alertBox},s.createElement(Pc.TransitionGroup,{component:"ul",className:"".concat(Lc.a.alertList," list-unstyled")},t&&t.map((function(e,t){return s.createElement(Pc.CSSTransition,{key:t,timeout:200,classNames:"alert"},s.createElement(Uc,{alert:e,closeAlert:function(){return n(e.id)}}))}))))}function Vc(e){return(Vc="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)}function Fc(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Hc(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function zc(e,t){return(zc=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Wc(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Gc(e);if(t){var i=Gc(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return qc(this,n)}}function qc(e,t){return!t||"object"!==Vc(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Gc(e){return(Gc=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Kc=function(e){!function(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}}),t&&zc(e,t)}(o,e);var t,n,r,i=Wc(o);function o(){return Fc(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"name",get:function(){return xs.a.User}},{key:"channelName",get:function(){return js.b.USER}},{key:"getCurrentUser",value:function(e,t){return this.get({resource:"/api/currentuser",eventPrefix:Ls.a.CURRENT_USER,expiryTime:Rs.a.STANDARD,callback:e,errorCallback:t})}},{key:"getWorkspace",value:function(e,t){return this.get({resource:"/api/domain/v2/me/workspace?query=categorytree",eventPrefix:Ls.a.WORKSPACE,expiryTime:Rs.a.STANDARD,callback:e,errorCallback:t})}}])&&Hc(t.prototype,n),r&&Hc(t,r),o}(Is),Yc=(xs.a.User,js.b.USER,xs.a.User,"".concat(Ls.a.CURRENT_USER,":sync"),n(222)),Xc=n(19);function Qc(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var $c=function(e,t){return{url:"/api/domain/v2/objects/".concat(e,"?query=").concat(Xc.b.SERIES),key:"series:".concat(e),success:t}},Zc=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.store=t.store}var t,n,o;return t=e,(n=[{key:"name",get:function(){return xs.a.Series}},{key:"channelName",get:function(){return js.b.SERIES}},{key:"getSeries",value:function(e,t){var n=$c(e,(function(e){return t&&t(new r.a.Model(e))})),o=i.a.getResponse(this.store.getState(),n.key);o.shouldFetch&&i.a.fetch(this.store.dispatch,n);var a=o.data?new r.a.Model(o.data):null;return t&&a&&t(a),a}}])&&Qc(t.prototype,n),o&&Qc(t,o),e}(),Jc=n(42);function eu(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var tu=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.store=t.store}var t,n,r;return t=e,(n=[{key:"name",get:function(){return Jc.a.FlightUser}},{key:"getCurrentUser",value:function(e,t){i.a.hooklessFetch(this.store,o.a.currentUser(e,t))}},{key:"getToken",value:function(e,t){i.a.hooklessFetch(this.store,o.a.token(e,t))}},{key:"getWorkspace",value:function(e,t){i.a.hooklessFetch(this.store,o.a.workspace(e,t))}},{key:"getPermissions",value:function(e,t){i.a.hooklessFetch(this.store,o.a.permissions(e,t))}}])&&eu(t.prototype,n),r&&eu(t,r),e}(),nu=n(120);function ru(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var iu=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.store=t.store}var t,n,r;return t=e,(n=[{key:"name",get:function(){return Jc.a.FlightConfig}},{key:"getConfig",value:function(e,t){i.a.hooklessFetch(this.store,nu.a.config(e,t))}},{key:"getVersion",value:function(e,t){i.a.hooklessFetch(this.store,nu.a.version(e,t))}}])&&ru(t.prototype,n),r&&ru(t,r),e}();function ou(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var au=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.store=t.store}var t,n,r;return t=e,(n=[{key:"name",get:function(){return Jc.a.FlightShare}},{key:"getShareLink",value:function(e,t,n){i.a.hooklessFetch(this.store,Kt.a.getShareObject(e,t,n))}}])&&ou(t.prototype,n),r&&ou(t,r),e}();function su(e){return("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)}function cu(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function uu(e,t){return(Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function lu(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=pu(e);if(t){var i=pu(this).constructor;Reflect.construct(r,arguments,i)}else r.apply(this,arguments);return fu(this,n)}}function fu(e,t){return!t||"object"!==su(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function pu(e){return(Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Qa.a;function du(e){return(du="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)}function hu(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function yu(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function mu(e,t){return(mu=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function vu(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=bu(e);if(t){var i=bu(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return gu(this,n)}}function gu(e,t){return!t||"object"!==du(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function bu(e){return(bu=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var wu=function(e){!function(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}}),t&&mu(e,t)}(o,e);var t,n,r,i=vu(o);function o(){return hu(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"name",get:function(){return"AlertError"}}])&&yu(t.prototype,n),r&&yu(t,r),o}(r.a.SilentError),_u=n(110),Su=n(360),Tu=n(361),Cu=n(381),Eu=n(382),ku=n(528),Ou=n(529);function Pu(e){le.a.getInstance(ws.a.ALERT).createAlert({heading:Yc.a.Fail,type:bs.a.Fail,message:e.message})}function Au(e){u.Radio.channel("error:view").replyOnce("current:error",(function(){return e})),r.a.AppLinkHelper.trigger({application:P.a.DEFAULT,action:R.a.Default.NOT_FOUND})}function Iu(e){u.Radio.channel("error:view").replyOnce("current:error",(function(){return e})),r.a.AppLinkHelper.trigger({application:P.a.DEFAULT,action:R.a.Default.ERROR})}function xu(e){u.Radio.channel("error:view").replyOnce("current:error",(function(){return e})),r.a.AppLinkHelper.trigger({application:P.a.DEFAULT,action:R.a.Default.DIALOG_ERROR})}function Ru(e){u.Radio.channel("error:view").replyOnce("current:error",(function(){return e})),r.a.AppLinkHelper.trigger({application:P.a.SHARE,action:R.a.Share.SHARE_LINK_ERROR})}function Lu(e){u.Radio.channel("error:view").replyOnce("current:error",(function(){return e})),r.a.AppLinkHelper.trigger({application:P.a.EMBED,action:R.a.Embed.EMBED_ERROR})}var ju=n(94),Nu=n(79);function Du(e){return(Du="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)}function Bu(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Uu(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Mu(e,t){return(Mu=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Vu(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Hu(e);if(t){var i=Hu(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Fu(this,n)}}function Fu(e,t){return!t||"object"!==Du(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Hu(e){return(Hu=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var zu=function(e){!function(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}}),t&&Mu(e,t)}(o,e);var t,n,r,i=Vu(o);function o(){return Bu(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"isReactComponent",value:function(e){return s&&s.isValidElement(e)}},{key:"showChildView",value:function(e,t){this.isReactComponent(t)&&this.showChildReactComponent(e,t)}},{key:"showChildReactComponent",value:function(e,t){var n=this;this.isAttached()?this.renderChildReactComponent(e,t):this.listenToOnce(this,"attach",(function(){return n.renderChildReactComponent(e,t)}))}},{key:"renderChildReactComponent",value:function(e,t){var n=this.getRegion(e),r=this.$el.find(n.el);r&&r.length&&(n.trigger("before:show"),ju.render(t,r[0],(function(){return n.trigger("show")})),this.listenToOnce(this,"unmount:".concat(e),(function(){return ju.unmountComponentAtNode(r[0])})),this.listenToOnce(this,"before:destroy",(function(){return ju.unmountComponentAtNode(r[0])})))}},{key:"wrapWithStore",value:function(e){return s.createElement(Nu.Provider,{store:this.options.store},e)}}])&&Uu(t.prototype,n),r&&Uu(t,r),o}(n(289).a),Wu=n(733),qu=n(147),Gu=n(78),Ku=n(185),Yu=n(292),Xu=n(29);var Qu=n(190),$u=n(40),Zu=n(386),Ju=n(376),el=n(311);function tl(e){return(tl="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)}function nl(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function rl(e,t){return(rl=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function il(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=al(e);if(t){var i=al(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ol(this,n)}}function ol(e,t){return!t||"object"!==tl(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function al(e){return(al=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var sl=function(e){!function(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}}),t&&rl(e,t)}(a,e);var t,n,i,o=il(a);function a(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),(t=o.call(this,e)).currentErrorHandled=!1,t.state={error:null},t}return t=a,i=[{key:"getDerivedStateFromError",value:function(e){return{error:e}}}],(n=[{key:"componentDidCatch",value:function(e,t){var n=this;this.currentErrorHandled||(this.currentErrorHandled=!0,window.trackJs&&window.trackJs.console.error(e.message,{errorInfo:t}),this.props.throwError&&(r.a.ErrorHelper.throw(new this.props.throwError(e.message)),window.setTimeout((function(){n.currentErrorHandled=!1,n.setState({error:null})}),500)))}},{key:"render",value:function(){var e=this.state.error;if(e&&this.props.renderError){var t=this.props.renderError;return c.a.createElement(t,null)}return e||!this.props.children?c.a.createElement(c.a.Fragment,null):this.props.children}}])&&nl(t.prototype,n),i&&nl(t,i),a}(c.a.Component);function cl(e){return(cl="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)}function ul(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ll(e,t){return(ll=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function fl(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=dl(e);if(t){var i=dl(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return pl(this,n)}}function pl(e,t){return!t||"object"!==cl(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function dl(e){return(dl=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var hl=function(e){!function(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}}),t&&ll(e,t)}(o,e);var t,n,r,i=fl(o);function o(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(e=i.call(this,"Unspecified dialog error")).btnVariant="dark",e}return t=o,(n=[{key:"name",get:function(){return"UnspecifiedDialogError"}},{key:"dialogOptions",get:function(){return{title:G.a.getPhrase("shared.unspecifiedDialogError","title"),text:G.a.getPhrase("shared.unspecifiedDialogError","body"),buttons:[{text:G.a.getPhrase("shared.unspecifiedDialogError","close"),className:"btn btn-".concat(this.btnVariant),success:!0}]}}}])&&ul(t.prototype,n),r&&ul(t,r),o}(_u.a),yl=n(106),ml=n(735),vl=n.n(ml),gl=n(301),bl=n.n(gl);function wl(e){return(wl="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)}function _l(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Sl(e,t){return(Sl=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Tl(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=El(e);if(t){var i=El(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Cl(this,n)}}function Cl(e,t){return!t||"object"!==wl(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function El(e){return(El=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var kl=function(e){!function(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}}),t&&Sl(e,t)}(o,e);var t,n,r,i=Tl(o);function o(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e)}return t=o,(n=[{key:"name",get:function(){return"NotificationStatusComponent"}},{key:"className",get:function(){return"notification-status mx-2 ".concat(bl.a.notificationIcon," ").concat(bl.a[this.options.color])}},{key:"template",get:function(){return vl.a}},{key:"initialize",value:function(){this.listenTo(this.model,"change:unreadCount",this.render)}},{key:"viewOptions",value:function(){return{styles:bl.a,svg:Ac.a.getSvg(Ac.b.Bell),unreadCount:this.model.get("unreadCount")}}}])&&_l(t.prototype,n),r&&_l(t,r),o}(r.a.Component),Ol=n(293),Pl=n(530),Al=n(724),Il=n(739),xl=n.n(Il),Rl=n(539),Ll=n.n(Rl),jl=n(540),Nl=n.n(jl);function Dl(e){return(Dl="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)}function Bl(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ul(e,t){return(Ul=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Ml(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Fl(e);if(t){var i=Fl(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Vl(this,n)}}function Vl(e,t){return!t||"object"!==Dl(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Fl(e){return(Fl=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Hl=function(e){!function(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}}),t&&Ul(e,t)}(o,e);var t,n,r,i=Ml(o);function o(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e)}return t=o,(n=[{key:"name",get:function(){return"NotificationPopoverView"}},{key:"title",get:function(){return!1}},{key:"lang",get:function(){return"notifications.notificationsPopover"}},{key:"className",get:function(){return"notifications-container"}},{key:"template",get:function(){return xl.a}},{key:"regions",value:function(){return{notifications:{replaceElement:!0,el:".list-region",partialLoading:{component:Pl.a.ComponentCollection,options:{collectionLength:5,childOptions:{template:Ll.a,className:"px-1 py-2",viewOptions:{styles:Nl.a}}}}}}}},{key:"elements",get:function(){return{anchor:".see-all"}}},{key:"appLinks",get:function(){return{"@ui.anchor":this.appVariables.appLinks.notifications}}},{key:"initialize",value:function(){this.notificationService=le.a.getInstance(xs.b.Notification,this),this.appVariables=le.a.getInstance(yl.a.NOTIFICATIONS,this)}},{key:"onData",value:function(e){this.collection=e,this.render()}},{key:"getCollectionIdentifier",value:function(){return this.collectionIdentifier?this.collectionIdentifier:this.collectionIdentifier=new Al.a({collectionPrefix:Ls.a.NOTIFICATIONS})}},{key:"renderNotificationList",value:function(){var e=new Ol.b({collection:this.collection,childType:this.options.childType,isPopover:!0});this.showChildView("notifications",e)}},{key:"triggerSeen",value:function(){this.notificationService.markNotificationsSeen()}},{key:"onBeforeRender",value:function(){var e=this;return this.collection||this.notificationService.getNotifications(null,this.getCollectionIdentifier(),(function(t){return e.onData(t)})),!!this.collection}},{key:"viewOptions",value:function(){return{hasNotifications:this.collection&&this.collection.length}}},{key:"onRender",value:function(){this.renderNotificationList(),this.triggerSeen()}}])&&Bl(t.prototype,n),r&&Bl(t,r),o}(r.a.View),zl=n(740),Wl=n.n(zl),ql=n(347),Gl=n.n(ql);function Kl(e){return(Kl="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)}function Yl(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Xl(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ql(e,t){return(Ql=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function $l(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Jl(e);if(t){var i=Jl(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Zl(this,n)}}function Zl(e,t){return!t||"object"!==Kl(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Jl(e){return(Jl=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var ef=function(e){!function(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}}),t&&Ql(e,t)}(o,e);var t,n,r,i=$l(o);function o(){return Yl(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"initialize",value:function(){this.appVariables=le.a.getInstance(yl.a.NOTIFICATIONS)}},{key:"name",get:function(){return"NotificationHeaderView"}},{key:"title",get:function(){return!1}},{key:"className",get:function(){return"d-flex align-items-center position-relative ".concat(Gl.a.noPopoverArrow)}},{key:"template",get:function(){return Wl.a}},{key:"regions",value:function(){return{status:{el:".notifications-status-region",replaceElement:!1},notifications:{el:".notifications-region",replaceElement:!1}}}},{key:"events",value:function(){return{"click .notifications-status-region":"renderNotificationList"}}},{key:"renderNotificationList",value:function(){var e=new Hl({childType:Ol.a.Popover});this.showChildView("notifications",e)}},{key:"renderNotificationStatus",value:function(){var e=le.a.getInstance(xs.b.Notification),t=new kl({model:e.getNotificationsMetadata(),color:this.appVariables.bellIconColor});this.showChildView("status",t)}},{key:"viewOptions",value:function(){return Gl.a}},{key:"onRender",value:function(){this.renderNotificationStatus()}}])&&Xl(t.prototype,n),r&&Xl(t,r),o}(r.a.View),tf=n(217),nf=n(97),rf=n(163),of=n(96),af=n(32),sf=n(363),cf=n(251),uf=n(395);function lf(e){return function(e){if(Array.isArray(e))return ff(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return ff(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ff(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ff(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var pf=G.a.encloseNamespace("shared.userOptions");var df=n(162);function hf(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return yf(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return yf(e,t)}(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 yf(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function mf(e){var t,n=hf(s.useState(!1),2),r=n[0],i=n[1];function o(e){e.stopPropagation(),i(!r)}function a(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;o(t),n!==e.currentCustomerId&&ce.LocationUtils.PageLoad(c(n))}function c(e){return e?"/change-customer?customerId=".concat(e):"/change-customer"}return s.useEffect((function(){e.isParentOpen||i(!1)}),[e.isParentOpen]),(null===(t=e.customers)||void 0===t?void 0:t.length)&&e.currentCustomerId?e.customers.length<=1?s.createElement(s.Fragment,null):e.customers.length>4?s.createElement(af.Dropdown.Item,{as:"li",onClick:function(e){return a(e)}},s.createElement("div",{className:"d-flex justify-content-between"},s.createElement(df.b,{namespace:"shared.customerSelectorItem",phrase:"title"}),s.createElement(Ic.a,{svgName:Ac.b.House,className:"svg-container text-muted"}))):s.createElement("li",{className:"dropdown-item dropleft",onClick:o},s.createElement("div",{className:"d-flex justify-content-between"},s.createElement(df.b,{namespace:"shared.customerSelectorItem",phrase:"title"}),s.createElement(Ic.a,{svgName:Ac.b.House,className:"svg-container text-muted"})),s.createElement("ul",{className:"dropdown-menu ".concat(r?"show":"")},e.customers.map((function(t,n){var r=t.id===e.currentCustomerId;return s.createElement(af.Dropdown.Item,{key:n,as:"li",onClick:function(e){return a(e,t.id)},disabled:r},t.name)})))):s.createElement(s.Fragment,null)}var vf=n(348),gf=n.n(vf);function bf(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return wf(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return wf(e,t)}(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 wf(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var _f=G.a.encloseNamespace("shared.userOptions");function Sf(e){var t=e.item;if(t.appLink)return s.createElement(af.Dropdown.Item,{as:xc.a,appLink:t.appLink,openInNewTab:t.openInNewTab,className:"d-flex justify-content-between",analyticsData:t.analyticsData,analyticsOptions:t.analyticsOptions},t.label,!!t.openInNewTab&&s.createElement(Ic.a,{svgName:Ac.b.NewWindow,className:"svg-container text-muted"}));if(t.url){return s.createElement(af.Dropdown.Item,{as:"a",href:t.url,target:!1===t.openInNewTab?null:"_blank",className:"d-flex justify-content-between",onClick:function(e){e.preventDefault(),t.analyticsData&&t.analyticsOptions&&Xu.a.logUserAction(Object.assign({href:t.url},t.analyticsData),t.analyticsOptions),ce.LocationUtils.PageLoad(t.url,!0)}},t.label,!1!==t.openInNewTab&&s.createElement(Ic.a,{svgName:Ac.b.NewWindow,className:"svg-container text-muted"}))}return s.createElement(s.Fragment,null)}function Tf(e){var t,n,r,c=bf(s.useState(!1),2),u=c[0],l=c[1],f=i.a.useBasicFetch(o.a.currentUser(),{optimize:!0}),p=i.a.useBasicFetch(nu.a.config(),{optimize:!0}),d=i.a.useBasicFetch(f.data&&o.a.customers(f.data.id)),h=function(e,t,n){var r=Object(of.a)().hasPermissions,i=Wt.a.sortBy(n,"order");e&&t&&(i.push({label:pf("helpCentre"),order:0,url:uf.a.getArticle(t.supportSiteUrl,null,null==e?void 0:e.countryCode)}),r(a.a.ViewProductBoard)&&i.push({label:pf("featureRequests"),order:0,url:t.productBoardUrl}));var o={main:[],logOut:[]};return i.forEach((function(e){"logOut"===e.section?o.logOut.push(e):o.main.push(e)})),o}(f.data,p.data,e.additionalItems),y=function(e,t){var n,r=i.a.useBasicFetch(o.a.currentUser()),a=i.a.useBasicFetch((null===(n=r.data)||void 0===n?void 0:n.isAuthenticated)&&z());if(!t&&a.data){var s=lf(a.data),c=Array.isArray(e)?e:[e];return Wt.a.sortBy(s.filter((function(e){return!c.includes(e.id)}),"order"))}}(e.productId,e.hideProductList);return f.hasCompleted&&p.data?(null===(t=f.data)||void 0===t?void 0:t.isAuthenticated)?s.createElement(af.Dropdown,{className:"cursor-pointer position-relative",onToggle:function(e){return l(e)}},s.createElement(af.Dropdown.Toggle,{as:"div",id:"userOptions",className:"".concat(gf.a.avatarContainer," no-caret")},s.createElement(sf.a,{imageUrl:f.data.avatar,imageCdnUrl:p.data.imageCdnUrl,initials:cf.a.getInitials(f.data.givenName,f.data.familyName)})),s.createElement(af.Dropdown.Menu,{as:"ul",align:"right"},s.createElement(af.Dropdown.Item,{as:"div"},s.createElement("div",{className:"m-0 d-flex flex-wrap"},s.createElement("strong",null,f.data.displayName)," ",s.createElement("span",{className:"text-muted"},"(",f.data.username,")")),s.createElement("div",{className:"m-0 text-muted"},f.data.customerName)),s.createElement(mf,{isParentOpen:u,currentCustomerId:null===(n=f.data)||void 0===n?void 0:n.customerId,customers:null===(r=d.data)||void 0===r?void 0:r.data}),s.createElement(af.Dropdown.Divider,null),h.main.map((function(e,t){return s.createElement(Sf,{key:t,item:e})})),s.createElement(af.Dropdown.Divider,null),null==y?void 0:y.map((function(e,t){return s.createElement(af.Dropdown.Item,{key:t,as:"a",href:e.url,target:"_blank",className:"d-flex align-items-center py-1"},s.createElement("img",{src:e.imageUrl,className:"".concat(gf.a.productLogo," mr-2")}),e.name)})),!!(null==y?void 0:y.length)&&s.createElement(af.Dropdown.Divider,null),h.logOut.map((function(e,t){return s.createElement(Sf,{key:t,item:e})})),s.createElement(af.Dropdown.Item,{as:xc.a,appLink:e.appLinks.logOut},_f("signOut")))):s.createElement(xc.a,{appLink:e.appLinks.logIn,className:"btn btn-dark mr-2"},_f("logIn")):s.createElement(s.Fragment,null)}var Cf=n(129),Ef=n(139);function kf(e){var t=s.useRef(null),n=s.useCallback((function(e){e&&(t.current=e)}),[]),r=function(){t.current.value=null,t.current.click(null)};return s.createElement(s.Fragment,null,e.svgName?s.createElement(Ef.a,{svgName:e.svgName,className:e.className,onClick:r},e.children):s.createElement("button",{type:"button",className:e.className,onClick:r},e.children),s.createElement("input",{type:"file",autoComplete:"off",className:"file-select d-none",multiple:!!e.acceptMultiple,accept:e.mimeType,ref:n,onChange:function(t){return e.onFileSelect(t.target.files)}}))}kf.defaultProps={className:"btn btn-primary"};var Of=n(257),Pf=function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[];s.useEffect((function(){return e.on(t,n),function(){e.off(t,n)}}),r)},Af=n(62),If=n(264);function xf(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return Rf(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Rf(e,t)}(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 Rf(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Lf(){var e=xf(c.a.useState(0),2),t=e[0],n=e[1],r=Object(qu.a)(Jc.b.CombineUploads),i=function(){var e=r.getCollection().filter((function(e){return e.get("status")!==If.b.Errored}));n(e.length)};return c.a.useEffect(i,[]),Pf(u.Radio.channel(js.c.VIDEO_UPLOAD),Af.a.FILES_ADDED,i),Pf(u.Radio.channel(P.b.COMBINE_UPLOADS),Af.a.PROCESSING_CANCELLED,i),Pf(u.Radio.channel(js.c.VIDEO_UPLOAD),Af.a.UPLOAD_CANCELLED,i),Pf(u.Radio.channel(P.b.COMBINE_UPLOADS),Af.a.PROCESSING_FAILED,i),t}var jf=n(349),Nf=n.n(jf);function Df(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return Bf(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Bf(e,t)}(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 Bf(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var Uf=s.memo((function(e){var t,n=e.hideButtonText,r=void 0!==n&&n,i=Df(Object(Of.a)(),2),o=i[0],a=i[1],c=Object(qu.a)(Jc.b.VideoUpload),u=Lf(),l=!!u&&!a;return s.createElement(kf,{svgName:l?null:Ac.b.Upload,className:(t="btn btn-outline-dark",r&&!l&&(t+=" pl-3"),l&&(t+=" pr-2"),t),mimeType:"video/*",onFileSelect:function(e){return c.addFiles(e,{entity:E.EntityType.Video,actionType:E.UserAction.Upload,workflowPhase:E.WorkflowPhase.Start,descriptor:Xu.a.mapInteractionType(E.InteractionType.FileSelect),location:E.LocationContext.TopNav})}},s.createElement("div",{className:"d-flex align-items-center w-100",ref:o},l&&s.createElement("span",{className:"position-relative"},s.createElement(af.Spinner,{animation:"border",size:"sm",className:"mr-2 ".concat(Nf.a.spinner)}),s.createElement("span",{className:"badge badge-danger badge-pill ".concat(Nf.a.totalUploading)},u)),r?s.createElement("span",{className:"invisible"}," "):s.createElement(df.b,{phrase:"uploadVideo",namespace:"shared.uploadFileSelect"})))})),Mf=n(64),Vf=n(267),Ff=n(307),Hf=n(729),zf=n(204),Wf=n(350),qf=n.n(Wf);function Gf(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return Kf(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Kf(e,t)}(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 Kf(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Yf(){var e,t,n=W.a.getCurrentRoute().appLink;return zf.a.isSearchAppLink(n)&&null!==(t=null===(e=n.params)||void 0===e?void 0:e.query)&&void 0!==t?t:""}var Xf=c.a.memo((function(e){var t,n=c.a.useMemo(Yf,[]),i=Gf(c.a.useState(n),2),o=i[0],a=i[1],s=Gf(c.a.useState(!1),2),l=s[0],f=s[1],d=Gf(Object(Gu.a)(ue.a.SHOW_SEARCH_MASK,!1),2),h=d[0],y=d[1],m=Object(Vf.a)(o,300),v=W.a.getCurrentRoute(),g=v.appLink,b=zf.a.isSearchAppLink(g),w=zf.a.useReferrerAppLink();function _(e){var t;if(null==o?void 0:o.trim())return!0;var n=null===(t=e)||void 0===t?void 0:t.tagOrClassification;return Array.isArray(n)?!!n.length:!!n}function S(){y(!0),window.setTimeout((function(){y(!1),r.a.AppLinkHelper.trigger(w,{replace:!0})}),200)}c.a.useEffect((function(){(b||o)&&(l?window.setTimeout((function(){return f(!1)}),0):b||!o||h||y(!0))}),[null==o?void 0:o.trim(),l]),c.a.useEffect((function(){!_(g.params)&&b&&S()}),[null===(t=g.params)||void 0===t?void 0:t.tagOrClassification]),c.a.useEffect((function(){var e=Object.assign({},g.params);m.trim()&&(null==e?void 0:e.tagOrClassification)&&!v.pageLoad&&delete e.tagOrClassification;var t=_(e);if(!t&&b)return S();t&&(Xu.a.logUserAction({query:o,indices:Ff.a.getIndices(g.params)},{actionType:E.UserAction.InstantSearch,entity:E.EntityType.SearchResults,location:E.LocationContext.SearchBar,workflowPhase:E.WorkflowPhase.Complete}),function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0,i={};t=n?Mf.a.omit(t,["query"]):{},e&&(i.query=e.trimLeft()),Object.keys(t).length&&(i=Object.assign(Object.assign({},i),t)),r.a.AppLinkHelper.trigger({application:P.a.SEARCH,action:R.a.Search.HOME,params:i},{replace:n})}(o,e,b))}),[m]),Pf(u.Radio.channel(p.a.SHELL),r.a.EventNames.URL_CHANGE,(function(e){var t,n;e||(e=W.a.getCurrentRoute().appLink),o&&!zf.a.isSearchAppLink(e)&&(f(!0),a("")),zf.a.isSearchAppLink(e)&&(null===(t=e.params)||void 0===t?void 0:t.query)!==!o&&a(null!==(n=e.params.query)&&void 0!==n?n:"")}),[o,a]);var T=Object(Hf.a)(o,Ff.a.getIndices(g.params),{entity:E.EntityType.SearchResults,location:E.LocationContext.SearchBar}).onBlur;return c.a.createElement("form",{className:"form-control p-0 pl-1 d-flex align-items-center ".concat(qf.a.invisibleBorder),onSubmit:function(e){return e.preventDefault()}},c.a.createElement(Ic.a,{svgName:Ac.b.Search}),c.a.createElement("input",{type:"text",className:"".concat(qf.a.invisibleBorder," w-100 h-100 outline-none"),placeholder:G.a.getPhrase("search.liteSearchBar","placeholder"),onChange:function(e){var t,n=null!==(t=e.target.value)&&void 0!==t?t:"";a(n)},onBlur:function(e){var t;return T(null!==(t=e.target.value)&&void 0!==t?t:"")},value:o,autoComplete:"off",spellCheck:!1,"aria-label":"Search"}),e.showCloseButton&&c.a.createElement(Ef.a,{svgName:Ac.b.Close,onClick:e.onClickClose,className:"btn btn-link"}))})),Qf=G.a.encloseNamespace("liteShared.header");var $f=n(137),Zf=n.n($f);function Jf(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return ep(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ep(e,t)}(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 ep(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function tp(e){var t=Object(of.a)().hasPermissions,n=Object(nf.a)($u.a.SMDown),r=n?Zf.a.logoContainerSm:Zf.a.logoContainerLg,i=null;return e.isLink&&(i=t(a.a.StudentExperience)?{application:P.a.STUDENT_FEED,action:R.a.StudentFeed.HOME}:{application:P.a.DASHBOARD,action:R.a.Dashboard.HOME}),s.createElement(xc.a,{appLink:i,className:"navbar-brand text-hide align-top ".concat(r," d-inline-block'")},n?s.createElement(tf.d,null):s.createElement(tf.a,null))}function np(e){var t=Jf(s.useState(!1),2),n=t[0],c=t[1],u=i.a.useBasicFetch(o.a.currentUser(),{optimize:!0}).data,l=i.a.useBasicFetch(nu.a.config(),{optimize:!0}),f=Object(Qu.a)(),p=Object(nf.a)($u.a.SMDown),d=Object(nf.a)($u.a.MDDown),h=Object(nf.a)($u.a.LGDown),y=function(){var e=Object(Cf.b)().isPlugin,t={application:P.a.DEFAULT,action:R.a.Default.LOG_IN},n=r.a.AppLinkHelper.getHref(r.a.AppLinkHelper.getCurrentAppLink());return"/"!==n&&(t.params={redirectUrl:n}),{logIn:t,logOut:{application:P.a.DEFAULT,action:R.a.Default.LOG_OUT,params:e?{redirectUrl:"/plugin"}:null}}}(),m=function(e,t,n){var r=Object(of.a)().hasPermissions;if(!e||!t||!n)return[];var i=[{label:Qf("settings"),order:5,appLink:{application:P.a.SETTINGS,action:R.a.Settings.HOME}}];return r(a.a.StudentExperience)||i.push.apply(i,[{label:Qf("shares"),order:0,appLink:{application:P.a.DEFAULT,action:R.a.Default.SHARED_BY_ME}}]),r(a.a.StudentExperience)&&i.push.apply(i,[{label:Qf("joinClassroom"),order:1,appLink:{application:P.a.LAUNCHPAD,action:R.a.Launchpad.JOIN_CLASSROOM_PROMPT}}]),i}(u,l.data,e.showNav),v=Object(Cf.b)().isPlugin;s.useEffect((function(){!d&&n&&c(!1)}),[d,f,n]);var g=e.showNav&&!v,b=e.showNav&&!v&&!p;return s.createElement("nav",{className:"navbar navbar-expanded w-100 ".concat(Zf.a.nav)},!n&&s.createElement("div",{className:"d-flex align-items-center justify-content-start ".concat(Zf.a.headerLeft)},e.showNav&&s.createElement(Ic.a,{svgName:Ac.b.Hamburger,className:"".concat(Zf.a.hamburger," ml-1 mr-3"),onClick:e.toggleLeftNav}),s.createElement(tp,{isLink:e.showNav})),e.showNav?d&&!n?s.createElement(rf.a,{className:"ml-auto mr-3",onClick:function(){return c(!0)}},s.createElement(Ic.a,{svgName:Ac.b.Search})):s.createElement("div",{className:"".concat(Zf.a.searchBarContainer," ").concat(n?"px-3 pl-0":"")},s.createElement("div",{className:"container ".concat(Zf.a.searchBarPadding," ").concat(n?"px-0":"")},s.createElement("div",{className:"".concat(Zf.a.searchBar," border border-dark")},s.createElement(Xf,{showCloseButton:n,onClickClose:function(){return c(!1)}})))):s.createElement(s.Fragment,null),!n&&s.createElement("div",{className:"d-flex align-items-center justify-content-end ".concat(Zf.a.actionButtons)},b&&s.createElement("div",{className:"mr-3"},s.createElement(Uf,{hideButtonText:h})),g&&s.createElement(Xr,{view:ef,className:"mx-n2 pr-3"}),!!l.data&&s.createElement("span",{className:"mr-3"},s.createElement(Tf,{productId:V.Primary,appLinks:y,additionalItems:m,hideProductList:v}))))}var rp,ip=n(89),op=n(13),ap=n(310),sp=n(367),cp=n(255),up=n(90),lp=n(50),fp=n(44),pp=n.n(fp);function dp(e){var t=Object(Cf.b)().isPlugin,n=e.collapsed&&e.active,r="".concat(pp.a.leftNavAnchor," ").concat(e.className," ");return r+=e.active?pp.a.active:pp.a.iconGrey,!e.collapsed&&e.active&&(r+=" "+pp.a.bgGrey),c.a.createElement(xc.a,{className:r,appLink:e.appLink,analyticsData:{id:ip.a.mapIdToAnalyticsId(e.id),label:e.name,icon:e.svgName},analyticsOptions:{actionType:E.UserAction.Click,entity:E.EntityType.Url,location:E.LocationContext.LeftNav}},c.a.createElement("span",{className:"".concat(pp.a.leftNavIcon," position-relative")},!!e.svgName&&c.a.createElement(Ic.a,{svgName:e.svgName,size:t?Ic.b.Medium:Ic.b.ExtraLarge}),!!e.imageUrl&&c.a.createElement("span",{className:pp.a.imageContainer},c.a.createElement("img",{src:up.a.createUrl(e.imageUrl,{size:lp.b.Small}),className:"img-fluid rounded-circle"})),e.showRedDot),c.a.createElement("span",{className:"".concat(pp.a.leftNavText," ").concat(n?pp.a.highlightText:"")},e.name),e.showRedDot&&c.a.createElement("span",{className:"".concat(pp.a.redDot," bg-danger rounded-circle ").concat(e.collapsed?pp.a.collapsed:pp.a.expanded)}))}function hp(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var yp,mp=G.a.encloseNamespace("shared.leftNav"),vp=(hp(rp={},op.a.Discover,{application:P.a.DASHBOARD,action:R.a.Dashboard.HOME}),hp(rp,op.a.Playlists,{application:P.a.PLAYLISTS,action:R.a.Playlists.HOME}),hp(rp,op.a.MyVideos,{application:P.a.DEFAULT,action:R.a.Default.MY_VIDEOS}),hp(rp,op.a.Favourites,{application:P.a.DEFAULT,action:R.a.Default.FAVOURITES}),hp(rp,op.a.Classrooms,{application:P.a.CLASSROOMS,action:R.a.Classrooms.HOME}),hp(rp,op.a.Classroom,{application:P.a.CLASSROOMS,action:R.a.Classrooms.CLASSROOM}),hp(rp,op.a.WatchHistory,{application:P.a.WATCH_HISTORY,action:R.a.WatchHistory.HOME}),hp(rp,op.a.Libraries,{application:P.a.LIBRARIES,action:R.a.Libraries.LIBRARY}),hp(rp,op.a.StudentFeed,{application:P.a.STUDENT_FEED,action:R.a.StudentFeed.HOME}),rp);function gp(e){var t=e.activeItem,n=e.dynamicActiveId,r=e.favouritedClassrooms,i=e.hideClassrooms,o=Object(of.a)().hasPermissions,s=!!Lf();return c.a.createElement("nav",{className:"".concat(pp.a.leftNav," ").concat(pp.a.leftNavExpanded)},c.a.createElement(cp.Scrollbars,{className:"h-100"},c.a.createElement("div",{className:"pt-3"},o(a.a.StudentExperience)&&c.a.createElement(dp,{key:op.a.StudentFeed,id:op.a.StudentFeed,name:mp("home"),appLink:vp[op.a.StudentFeed],className:pp.a.studentFeed,svgName:Ac.b.House,active:t===op.a.StudentFeed}),c.a.createElement(dp,{key:op.a.Discover,id:op.a.Discover,name:mp("discover"),appLink:vp[op.a.Discover],className:pp.a.discover,svgName:Ac.b.Compass,active:t===op.a.Discover}),c.a.createElement(dp,{key:op.a.Playlists,id:op.a.Playlists,name:mp("playlists"),appLink:vp[op.a.Playlists],className:pp.a.playlists,svgName:Ac.b.Playlist,active:t===op.a.Playlists}),c.a.createElement(dp,{key:op.a.MyVideos,id:op.a.MyVideos,name:mp("myVideos"),appLink:vp[op.a.MyVideos],className:pp.a.myVideos,svgName:Ac.b.Video,active:t===op.a.MyVideos,showRedDot:s}),c.a.createElement(dp,{key:op.a.Favourites,id:op.a.Favourites,name:mp("favourites"),appLink:vp[op.a.Favourites],className:pp.a.favourites,svgName:Ac.b.HeartOutline,active:t===op.a.Favourites}),!o(a.a.StudentExperience)&&c.a.createElement(dp,{key:op.a.WatchHistory,id:op.a.WatchHistory,name:mp("watchHistory"),appLink:vp[op.a.WatchHistory],className:pp.a.watchHistory,svgName:Ac.b.History,active:t===op.a.WatchHistory}),!o(a.a.StudentExperience)&&c.a.createElement("hr",{className:"my-2"}),!o(a.a.StudentExperience)&&!!e.libraries.length&&c.a.createElement(c.a.Fragment,null,e.libraries.length>1&&c.a.createElement("h6",{className:"m-b-2 pl-3"},mp("libraries")),e.libraries.map((function(e){var r,i,o,a,s;return c.a.createElement(dp,{key:e.id,id:op.a.Libraries,name:e.name,appLink:Object.assign(Object.assign({},vp[op.a.Libraries]),{args:[e.id,ot.a.slugify(e.name)]}),className:pp.a.library,imageUrl:null===(i=null===(r=e.owner)||void 0===r?void 0:r.logo)||void 0===i?void 0:i.url,svgName:!(null===(a=null===(o=e.owner)||void 0===o?void 0:o.logo)||void 0===a?void 0:a.url)&&Ac.b.Library,active:t===op.a.Libraries&&(null===(s=e.id)||void 0===s?void 0:s.toString())===(null==n?void 0:n.toString())})})),c.a.createElement("hr",{className:"my-2"})),!i&&c.a.createElement(c.a.Fragment,null,c.a.createElement(dp,{key:op.a.Classrooms,id:op.a.Classrooms,name:mp("classrooms"),appLink:vp[op.a.Classrooms],className:pp.a.classrooms,svgName:Ac.b.Classrooms,active:t===op.a.Classrooms}),(null==r?void 0:r.length)?r.map((function(e){var r;return c.a.createElement(dp,{key:e.id,id:op.a.Classroom,name:e.name,appLink:Object.assign(Object.assign({},vp[op.a.Classroom]),{args:[e.id]}),className:pp.a.classroom,svgName:Ac.b.StarOutline,active:t===op.a.Classroom&&(null===(r=e.id)||void 0===r?void 0:r.toString())===(null==n?void 0:n.toString())})})):c.a.createElement(c.a.Fragment,null)))))}function bp(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var wp,_p,Sp=G.a.encloseNamespace("shared.leftNav"),Tp=(bp(yp={},op.a.Discover,{application:P.a.DASHBOARD,action:R.a.Dashboard.HOME}),bp(yp,op.a.Playlists,{application:P.a.PLAYLISTS,action:R.a.Playlists.HOME}),bp(yp,op.a.MyVideos,{application:P.a.DEFAULT,action:R.a.Default.MY_VIDEOS}),bp(yp,op.a.Favourites,{application:P.a.DEFAULT,action:R.a.Default.FAVOURITES}),bp(yp,op.a.WatchHistory,{application:P.a.WATCH_HISTORY,action:R.a.WatchHistory.HOME}),bp(yp,op.a.StudentFeed,{application:P.a.STUDENT_FEED,action:R.a.StudentFeed.HOME}),yp);function Cp(e){var t=e.activeItem,n=Object(of.a)().hasPermissions,r=Object(Cf.b)().isPlugin,i=!!Lf(),o="".concat(pp.a.leftNav," ").concat(pp.a.leftNavCollapsed);return r&&(o+=" ".concat(pp.a.pluginLeftNav)),c.a.createElement("nav",{className:o},c.a.createElement(cp.Scrollbars,{height:"100%"},c.a.createElement("div",{className:r?"pt-1":"pt-3"},n(a.a.StudentExperience)&&c.a.createElement(dp,{key:op.a.StudentFeed,id:op.a.StudentFeed,name:Sp("home"),appLink:Tp[op.a.StudentFeed],className:pp.a.studentFeed,svgName:Ac.b.House,active:t===op.a.StudentFeed,collapsed:!0}),c.a.createElement(dp,{key:op.a.Discover,id:op.a.Discover,name:Sp("discover"),appLink:Tp[op.a.Discover],className:pp.a.discover,svgName:Ac.b.Compass,active:t===op.a.Discover,collapsed:!0}),c.a.createElement(dp,{key:op.a.Playlists,id:op.a.Playlists,name:Sp("playlists"),appLink:Tp[op.a.Playlists],className:pp.a.playlists,svgName:Ac.b.Playlist,active:t===op.a.Playlists,collapsed:!0}),c.a.createElement(dp,{key:op.a.MyVideos,id:op.a.MyVideos,name:Sp("myVideos"),appLink:Tp[op.a.MyVideos],className:pp.a.myVideos,svgName:Ac.b.Video,active:t===op.a.MyVideos,collapsed:!0,showRedDot:i}),c.a.createElement(dp,{key:op.a.Favourites,id:op.a.Favourites,name:Sp("favourites"),appLink:Tp[op.a.Favourites],className:pp.a.favourites,svgName:Ac.b.HeartOutline,active:t===op.a.Favourites,collapsed:!0}),!n(a.a.StudentExperience)&&c.a.createElement(dp,{key:op.a.WatchHistory,id:op.a.WatchHistory,name:Sp("watchHistory"),appLink:Tp[op.a.WatchHistory],className:pp.a.watchHistory,svgName:Ac.b.History,active:t===op.a.WatchHistory,collapsed:!0}))))}function Ep(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return kp(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return kp(e,t)}(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 kp(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Op(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}!function(e){e[e.Open=0]="Open",e[e.Collapsed=1]="Collapsed",e[e.Hidden=2]="Hidden"}(_p||(_p={}));var Pp=(Op(wp={},op.a.Discover,ip.a.getDiscoverAppLinks()),Op(wp,op.a.Playlists,ip.a.getPlaylistAppLinks()),Op(wp,op.a.MyVideos,ip.a.getMyVideosAppLinks()),Op(wp,op.a.Favourites,ip.a.getFavouritesAppLinks()),Op(wp,op.a.WatchHistory,ip.a.getWatchHistoryAppLinks()),Op(wp,op.a.Classrooms,ip.a.getClassroomsAppLinks()),Op(wp,op.a.Classroom,ip.a.getClassroomAppLinks()),Op(wp,op.a.Libraries,ip.a.getLibrariesAppLinks()),Op(wp,op.a.StudentFeed,ip.a.getStudentFeedAppLinks()),wp);function Ap(e){var t,n,r,s,u,l=Ep(c.a.useState(null),2),f=l[0],p=l[1],d=i.a.useBasicFetch(o.a.currentUser()),h=i.a.useBasicFetch(d.data&&sp.a.getPinnedClassrooms(d.data.id)),y=i.a.useBasicFetch(ap.a.sharedLibraries());i.a.useBasicFetch(!!(null===(t=y.data)||void 0===t?void 0:t.length)&&ap.a.librariesWithOwnerLogos(y.data.map((function(e){return e.id}))));var m=Object(of.a)().hasPermissions;if(c.a.useEffect((function(){if(e.appLinkIsRoute){var t=null;Object.keys(Pp).find((function(n){t||Pp[n].find((function(t){return t.application===e.activeAppLink.application&&t.action===e.activeAppLink.action}))&&(t=op.a[n])})),p(t)}}),[e.activeAppLink]),e.navState===_p.Hidden)return c.a.createElement(c.a.Fragment,null);var v=(null===(n=e.activeAppLink)||void 0===n?void 0:n.args)&&e.activeAppLink.args[0];return e.navState===_p.Collapsed?c.a.createElement(Cp,{activeItem:f}):c.a.createElement(gp,{activeItem:f,dynamicActiveId:v,favouritedClassrooms:null!==(s=null===(r=h.data)||void 0===r?void 0:r.data)&&void 0!==s?s:[],libraries:null!==(u=y.data)&&void 0!==u?u:[],hideClassrooms:!m(a.a.ViewClassrooms)})}var Ip=n(216),xp=n(45),Rp=n(126),Lp=n(372),jp=n(220),Np=n(550),Dp=n(394),Bp=n(218),Up=n(357),Mp=n(388),Vp=n(365),Fp=n(245),Hp=n.n(Fp);function zp(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return Wp(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Wp(e,t)}(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 Wp(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function qp(e){if(e.shareId)return{application:P.a.SHARE,action:R.a.Share.VIEW_SHARE_LINK,args:[e.shareId]};var t={};return e.contextId&&e.context&&(t.contextId=e.contextId,t.context=e.context),Vp.a.getAppLink(e.video,t)}function Gp(){var e,t=zp(Object(Gu.a)(ue.a.WEB_PLAYER_DATA),1)[0];return s.createElement("h2",{className:"mb-0 h6 w-100 ".concat(Hp.a.title)},xp.a.isVideo(t.video)&&xp.a.hasSeries(t.video)&&s.createElement(Lp.b,{className:"d-block",video:t.video,appLink:(e=t.video.series,{application:P.a.DEFAULT,action:R.a.Default.SERIES,args:[e.id,ot.a.slugify(e.name)]}),analyticsOptions:{location:E.LocationContext.FloatingPlayer}}),s.createElement(xc.a,{appLink:!t.isOnPlayPage&&qp(t)},t.video.name))}function Kp(){var e,t,n;Object(Np.a)();var a=zp(Object(Gu.a)(ue.a.WEB_PLAYER_DATA),2),c=a[0],u=a[1],l=Object(Up.a)(E.LocationContext.FloatingPlayer),f=Object(Mp.a)(E.LocationContext.FloatingPlayer),p=i.a.useBasicFetch(o.a.currentUser());i.a.useBasicFetch((null===(e=p.data)||void 0===e?void 0:e.isAuthenticated)&&(null==c?void 0:c.video)?Bp.a.isFavourited(p.data.id,[c.video.id]):null);var d=jp.a.canFavourite(c.video),h=jp.a.isFavouritedByCurrentUser(c.video),y=(null===(t=p.data)||void 0===t?void 0:t.isAuthenticated)&&xp.a.isVideo(c.video);return(null==c?void 0:c.video)&&(null==c?void 0:c.viewKey)?s.createElement(s.Fragment,null,s.createElement(Ip.a,{node:c.portalNode},(c.isOnPlayPage||c.showFloatingPlayer)&&s.createElement(Dp.a,{viewKey:c.viewKey,startTime:c.startTime,playerApiUrl:c.playerApiUrl,webPlayerUrl:c.webPlayerUrl,videoId:c.video.id,onExitPictureInPicture:function(){r.a.AppLinkHelper.trigger(qp(c))},onClickCreateClip:y&&function(){y&&r.a.AppLinkHelper.trigger({application:P.a.DEFAULT,action:R.a.Default.CREATE_CLIP,args:[c.video.id]})},autoplay:!0,canFavourite:d,favourited:h,onClickFavourite:function(){var e=!h;l(c.video,e,(function(){u("video",e?Object.assign(Object.assign({},c.video),{favouritedBy:{data:[p.data]}}):Object.assign(Object.assign({},c.video),{favouritedBy:{data:[]}}))}))},activityStatus:c.activityStatus,onSetActivityStatus:function(){var e=c.activityStatus===Rp.a.Complete?Rp.a.Incomplete:Rp.a.Complete;f(c.shareId,c.video,e),u("activityStatus",e)},allowPip:null===(n=p.data)||void 0===n?void 0:n.isAuthenticated,onError:function(){r.a.ErrorHelper.throw(new H.a)}})),s.createElement("div",{className:Hp.a.floatingPlayer},s.createElement(Pc.CSSTransition,{timeout:400,in:c.showFloatingPlayer,classNames:"floating-player"},s.createElement("div",{className:"d-none shadow"},c.showFloatingPlayer&&s.createElement(Ip.b,{node:c.portalNode}),s.createElement("div",{className:"p-2 bg-white d-flex justify-content-between align-items-center"},s.createElement(Gp,null),s.createElement("span",{className:"".concat(Hp.a.buttons)},s.createElement("span",{className:"cursor-pointer ml-1 float-right",role:"button",tabIndex:0,onClick:function(){Xu.a.logUserAction({id:c.video.id},{location:E.LocationContext.FloatingPlayer,entity:xp.a.getAnalyticsEntity(c.video),actionType:E.UserAction.Click,descriptor:E.ClickDescriptor.Close}),u("showFloatingPlayer",!1)}},s.createElement(Ic.a,{svgName:Ac.b.Close})),s.createElement(xc.a,{appLink:qp(c),onClick:function(){u("isOnPlayPage",!0),u("showFloatingPlayer",!1),Xu.a.logUserAction({id:c.video.id},{location:E.LocationContext.FloatingPlayer,entity:xp.a.getAnalyticsEntity(c.video),actionType:E.UserAction.Click,descriptor:E.ClickDescriptor.Open})}},!c.isOnPlayPage&&s.createElement(Ic.a,{svgName:Ac.b.NewWindow,className:"".concat(Hp.a.flippedIcon," d-inline-block svg-container float-right")})))))))):s.createElement(s.Fragment,null)}var Yp=n(556),Xp=n(246),Qp=n.n(Xp);function $p(){return s.createElement(s.Fragment,null,s.createElement("div",{className:Qp.a.dropMask}),s.createElement("div",{className:Qp.a.dropContent},s.createElement("div",{className:Qp.a.border},s.createElement("h1",null,s.createElement(df.b,{namespace:"shared.dragMask",phrase:"message"})))),s.createElement("div",{className:Qp.a.dropArea}))}var Zp=n(119),Jp=n.n(Zp);function ed(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return td(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return td(e,t)}(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 td(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var nd=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n};function rd(e){return e!==$u.a.XL&&e!==$u.a.XXL}var id=function(e){var t,n=e.showNav,r=e.contentChild,a=e.popupChild,c=e.alertChild,u=e.hiddenChild,l=e.activeAppLink,f=e.appLinkIsRoute,p=ed(s.useState(!1),2),d=p[0],h=p[1];Object(Ju.a)(),function(){function e(n){"Tab"===n.key&&(document.body.classList.add("user-is-tabbing"),window.removeEventListener("keydown",e),window.addEventListener("mousedown",t))}function t(){document.body.classList.remove("user-is-tabbing"),window.removeEventListener("mousedown",t),window.addEventListener("keydown",e)}Object(s.useEffect)((function(){return window.addEventListener("keydown",e),function(){return window.removeEventListener("keydown",e)}}),[])}();var y=i.a.useBasicFetch(o.a.currentUser());y.data&&!y.data.isAuthenticated&&(n=!1),Object(Yu.b)((null===(t=y.data)||void 0===t?void 0:t.isAuthenticated)?Jc.b.CombineUploads:null);var m=Object(Qu.a)(),v=m===$u.a.XS,g=m===$u.a.SM,b=m===$u.a.XXL,w=ed(Object(Gu.a)(ue.a.WEB_PLAYER_DATA),1)[0],_=ed(Object(Gu.a)(ue.a.SHOW_SEARCH_MASK),1)[0],S=ed(Object(Gu.a)(ue.a.LAYOUT_CONTAINER_FLUID,rd(m)),2),T=S[0],C=S[1],k=Object(Zu.b)().enabled;s.useEffect((function(){h(!b)}),[b]),s.useEffect((function(){C(rd(m))}),[m]);var O=Object(Cf.b)().isPlugin,P=function(e,t,n,r,i){var o=i?Jp.a.pluginCollapsedNavContent:Jp.a.collapsedNavContent;return r?t?{state:e?_p.Hidden:_p.Open,showMask:!e,contentClass:Jp.a.hiddenNavContent}:n?{state:e?_p.Collapsed:_p.Open,showMask:!e,contentClass:o}:{state:e?_p.Collapsed:_p.Open,showMask:!1,contentClass:e?o:Jp.a.openNavContent}:{state:_p.Hidden,showMask:!1,contentClass:Jp.a.hiddenNavContent}}(d,v,g,n,O),A=Object(qu.a)(Jc.b.VideoUpload),I=s.useCallback((function(e){k&&A.addFiles(e,{entity:E.EntityType.Video,actionType:E.UserAction.Upload,workflowPhase:E.WorkflowPhase.Start,descriptor:Xu.a.mapInteractionType(E.InteractionType.DragDrop),location:E.LocationContext.VideoUpload})}),[k]),x=Object(Wu.useDropzone)({onDrop:I,noClick:!0,noKeyboard:!0,disabled:O}),R=x.getRootProps,L=x.getInputProps,j=x.isDragActive,N="d-flex flex-column align-items-end",D="";return(null==w?void 0:w.showFloatingPlayer)?N+=" ".concat(Jp.a.fixedBottomRightContainer):D=Jp.a.fixedBottomRightContainer,s.createElement(sl,{renderError:function(){return Object(Yp.ErrorView)({error:new H.a})}},s.createElement("div",Object.assign({},R()),s.createElement(np,{toggleLeftNav:function(){h(!d)},showNav:n}),n&&s.createElement(Ap,{navState:P.state,activeAppLink:l,appLinkIsRoute:f}),s.createElement("div",{className:"".concat(Jp.a.content," ").concat(P.contentClass)},s.createElement("div",{className:"container-fluid ".concat("banner-portal-container")}),s.createElement("div",{className:"".concat(T?"container-fluid":"container")},s.createElement(sl,{throwError:H.a},r))),s.createElement(sl,{throwError:hl},a),P.showMask&&s.createElement("div",{className:"modal-backdrop show ".concat(Jp.a.mask)}),s.createElement("div",{className:"".concat(Jp.a.searchMask," ").concat(_?Jp.a.show:""," modal-backdrop")}),s.createElement("div",{className:N},!!c&&s.createElement("div",{className:D},c),s.createElement(Kp,null)),j&&k&&s.createElement($p,null),s.createElement("input",Object.assign({},L())),s.createElement("div",{style:{display:"none"}},u)))};function od(e){var t=e.provider,n=nd(e,["provider"]);return t?s.createElement(Nu.Provider,{store:e.store},s.createElement(Ku.b,{defaultTitle:""},s.createElement(el.b,{containerClassName:"banner-portal-container"},s.createElement(t,null,s.createElement(id,Object.assign({},n)))))):s.createElement(Nu.Provider,{store:e.store},s.createElement(Ku.b,{defaultTitle:""},s.createElement(el.b,{containerClassName:"banner-portal-container"},s.createElement(id,Object.assign({},n)))))}var ad=n(757),sd=n.n(ad);function cd(e){return(cd="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)}function ud(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ld(e,t,n){return(ld="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=hd(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function fd(e,t){return(fd=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function pd(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=hd(e);if(t){var i=hd(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return dd(this,n)}}function dd(e,t){return!t||"object"!==cd(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function hd(e){return(hd=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var yd=function(e){!function(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}}),t&&fd(e,t)}(a,e);var t,n,i,o=pd(a);function a(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),(t=o.call(this,e)).childComponents={},t.preventScrollTop=!1,t}return t=a,i=[{key:"getCacheKey",value:function(e){var t;return"".concat(k,":").concat(e.showNav,":").concat(null===(t=e.provider)||void 0===t?void 0:t.name)}}],(n=[{key:"initialize",value:function(){var e,t=this;this.activeAppLink=null===(e=W.a.getCurrentContext())||void 0===e?void 0:e.appLink,this.appLinkIsRoute=!0,this.listenTo(p.a.SHELL,r.a.EventNames.ROUTE,this.onRouteChange),this.listenTo(p.a.SHELL,"prevent:scroll:top",(function(){return t.preventScrollTop=!0}))}},{key:"title",get:function(){return!1}},{key:"name",get:function(){return"TeacherLayoutView"}},{key:"template",get:function(){return sd.a}},{key:"regions",value:function(){return{layout:{el:".layout-region",replaceEl:!0}}}},{key:"getChildComponents",value:function(){return{showNav:this.options.showNav,contentChild:this.childComponents[tt],popupChild:this.childComponents[nt],alertChild:this.childComponents[rt],hiddenChild:this.childComponents[it],store:this.options.store,activeAppLink:this.activeAppLink,appLinkIsRoute:this.appLinkIsRoute,provider:this.options.provider}}},{key:"onRouteChange",value:function(e,t){this.activeAppLink=e,this.appLinkIsRoute=t.isAppRoute}},{key:"unsetRegion",value:function(e){delete this.childComponents[e],this.renderLayout()}},{key:"closePopup",value:function(){this.unsetRegion(nt)}},{key:"showChildView",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};this.childComponents[e]=t,e===tt&&(this.preventScrollTop||n.preventScrollTop||$(window).scrollTop(0),this.preventScrollTop=!1),this.renderLayout()}},{key:"renderLayout",value:function(){var e=Object.assign({provider:this.options.provider},this.getChildComponents());ld(hd(a.prototype),"showChildView",this).call(this,"layout",s.createElement(od,Object.assign({},e)))}}])&&ud(t.prototype,n),i&&ud(t,i),a}(zu),md=n(758);function vd(e){var t=e.contentChild;return s.createElement(s.Fragment,null,t)}function gd(e){var t=e.store;return s.createElement(sl,{renderError:function(){return Object(md.EmbedErrorView)({error:new vr})}},s.createElement(Nu.Provider,{store:t},s.createElement(Ku.b,{defaultTitle:""},s.createElement(vd,Object.assign({},e)))))}var bd=n(759),wd=n.n(bd);function _d(e){return(_d="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)}function Sd(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Td(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Cd(e,t,n){return(Cd="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Pd(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Ed(e,t){return(Ed=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function kd(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Pd(e);if(t){var i=Pd(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Od(this,n)}}function Od(e,t){return!t||"object"!==_d(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Pd(e){return(Pd=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Ad=function(e){!function(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}}),t&&Ed(e,t)}(o,e);var t,n,r,i=kd(o);function o(){var e;return Sd(this,o),(e=i.apply(this,arguments)).childComponents={},e}return t=o,r=[{key:"getCacheKey",value:function(){return O}}],(n=[{key:"title",get:function(){return!1}},{key:"name",get:function(){return"SimpleLayoutView"}},{key:"template",get:function(){return wd.a}},{key:"regions",value:function(){return{layout:{el:".layout-region",replaceEl:!0}}}},{key:"getChildComponents",value:function(){return{contentChild:this.childComponents[tt],store:this.options.store}}},{key:"unsetRegion",value:function(e){delete this.childComponents[e],this.renderLayout()}},{key:"closePopup",value:function(){this.unsetRegion(nt)}},{key:"showChildView",value:function(e,t){this.childComponents[e]=t,this.renderLayout()}},{key:"renderLayout",value:function(){Cd(Pd(o.prototype),"showChildView",this).call(this,"layout",s.createElement(gd,Object.assign({},this.getChildComponents())))}}])&&Td(t.prototype,n),r&&Td(t,r),o}(zu);function Id(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var xd=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.value=t}var t,n,r;return t=e,(n=[{key:"increment",value:function(){this.value+=1}},{key:"decrement",value:function(){this.value-=1}},{key:"getValue",value:function(){return this.value}}])&&Id(t.prototype,n),r&&Id(t,r),e}(),Rd=n(117),Ld=n(239);function jd(e){return(jd="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)}function Nd(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Dd(e,t){return(Dd=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Bd(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Md(e);if(t){var i=Md(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ud(this,n)}}function Ud(e,t){return!t||"object"!==jd(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Md(e){return(Md=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Vd=function(e){!function(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}}),t&&Dd(e,t)}(o,e);var t,n,r,i=Bd(o);function o(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(e=i.call(this)).viewObjects={},e}return t=o,r=[{key:"Instance",get:function(){return this.instance||(this.instance=new this)}}],(n=[{key:"name",get:function(){return"ViewModelService"}},{key:"updateViewModel",value:function(e,t){var n=this.mergeData(t,e.toJSON());return e instanceof Ld.a&&e.set(n,{silent:!0}),e instanceof Rd.a&&!(e instanceof Ld.a)&&e.set(n,{silent:!0}),e}},{key:"get",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.update,i=void 0!==r&&r,o=this.viewObjects[e];if(o&&i)return this.updateViewModel(o,t);if(o)return o;var a=this.getLocalData(e,n);return this.set(e,t,a,n)}},{key:"set",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0,i=r.ctor,o=r.storage,a=this.mergeData(t,n),s=i?new i(a):new Rd.a(a);return this.viewObjects[e]=s,o&&!n?(this.setLocalData(e,s,null,r),this.setupChangeListeners(e,s,r)):o&&n&&this.setupChangeListeners(e,s,r),s}},{key:"clear",value:function(e){var t=this.viewObjects[e];return!!t&&(this.stopListening(t),t.trigger("destroy"),delete this.viewObjects[e],!0)}},{key:"getLocalData",value:function(e,t){var n=t.storage;if(n)return this.getStorageHelper(n.type).get(e)}},{key:"setLocalData",value:function(e,t,n,r){var i,o=r.storage;!o||o&&!o.persistProps||("string"==typeof o.persistProps&&(o.persistProps=[o.persistProps]),t instanceof Rd.a&&(i=t.pick(o.persistProps)),this.getStorageHelper(o.type).set(e,i))}},{key:"setupChangeListeners",value:function(e,t,n){var r=this,i=n.storage;!i||i&&!i.persistProps||("string"==typeof i.persistProps&&(i.persistProps=[i.persistProps]),Ya.each(i.persistProps,(function(i){r.listenTo(t,"change:".concat(i),Ya.partial(r.setLocalData,e,Ya,Ya,n))})))}},{key:"mergeData",value:function(e,t){return t?Ya.isObject(e)&&Ya.isObject(t)?Ya.extend(e,t):void Qa.c.throw(new oe.a("defaultValues and existingData are not of the same datatype and cannot be merged")):e}},{key:"getStorageHelper",value:function(e){switch(e){case se.c.LocalStorage:return se.a;case se.c.SessionStorage:return se.b}}}])&&Nd(t.prototype,n),r&&Nd(t,r),o}(Xa.a).Instance;function Fd(e){return(Fd="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)}function Hd(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function zd(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Wd(e,t,n){return t&&zd(e.prototype,t),n&&zd(e,n),e}function qd(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}}),t&&Gd(e,t)}function Gd(e,t){return(Gd=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Kd(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Xd(e);if(t){var i=Xd(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Yd(this,n)}}function Yd(e,t){return!t||"object"!==Fd(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Xd(e){return(Xd=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Qd,$d=function(e){qd(n,e);var t=Kd(n);function n(){return Hd(this,n),t.apply(this,arguments)}return Wd(n,[{key:"idAttribute",get:function(){return"masterVideoId"}}]),n}(r.a.Model),Zd=function(e){qd(n,e);var t=Kd(n);function n(){return Hd(this,n),t.apply(this,arguments)}return Wd(n,[{key:"model",get:function(){return $d}}]),n}(r.a.Collection),Jd=n(160),eh=n(193);function th(e){return(th="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)}function nh(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function rh(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ih(e,t){return(ih=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function oh(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=sh(e);if(t){var i=sh(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ah(this,n)}}function ah(e,t){return!t||"object"!==th(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function sh(e){return(sh=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var ch=function(e){!function(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}}),t&&ih(e,t)}(a,e);var t,n,i,o=oh(a);function a(){return nh(this,a),o.apply(this,arguments)}return t=a,(n=[{key:"name",get:function(){return xs.b.PendingItems}},{key:"channelName",get:function(){return js.c.PENDING_ITEMS}},{key:"initialize",value:function(){this.videoDataService=le.a.getInstance(xs.a.Video,this),this.videoUploadDataService=le.a.getInstance(xs.a.VideoUpload,this)}},{key:"clearPendingItem",value:function(e,t){var n=this;switch(e.get("pendingProcessStatus")){case Jd.a.Completed:case Jd.a.Error:this.videoUploadDataService.clearPendingItems([e.get("pendingProcessId")],(function(){e.set("clearing",!0),e.collection.remove(e),n.updateViewModel(),n.videoDataService.clearVideoCache(),Ya.isFunction(t)&&t()}));break;case Jd.a.Processing:this.videoUploadDataService.cancelPendingItems([e.get("pendingProcessId")],(function(){e.set("clearing",!0),e.collection.remove(e),n.videoDataService.clearVideoCache(),n.updateViewModel(),Ya.isFunction(t)&&t()}))}}},{key:"forceFetchPendingItems",value:function(e){this.fetchPendingItems(e)}},{key:"retryPendingItem",value:function(e,t){var n=this;this.videoUploadDataService.retryPendingItems([e.get("pendingProcessId")],(function(){n.fetchPendingItems({resetTimeout:!1,callback:t})}))}},{key:"itemStatusChanged",value:function(){u.Radio.channel(this.channelName).trigger(Af.a.PENDING_ITEM_STATUS_CHANGE),this.videoDataService.clearVideoCache()}},{key:"getPendingItems",value:function(){var e=this;return this.pendingItems||(this.pendingItems=new Zd,this.listenTo(this.pendingItems,"change:foregroundComplete",(function(t){t.get("foregroundComplete")&&(e.itemStatusChanged(),t.get("video")&&u.Radio.channel(e.channelName).trigger(Af.a.PENDING_ITEM_READY_TO_WATCH,t))})),this.listenTo(this.pendingItems,"remove",(function(t){t.get("clearing")||e.videoUploadDataService.getPendingItem(t.get("pendingProcessId"),(function(t){t.get("status")===Jd.a.Completed&&e.itemStatusChanged()}))})),window.setTimeout((function(){e.fetchPendingItems()}),200)),this.pendingItems}},{key:"fetchPendingItems",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{resetTimeout:!0};this.isDestroyed()||this.videoUploadDataService.getPendingItems((function(n){var i=Ya.map(n,(function(e){return e.masterVideoId.toString()})),o=function(r){Ya.each(n,(function(e){var t=r.get(e.masterVideoId);t&&(e.video=t,e.foregroundProgress>=100&&t.get("status")===eh.a.Processing&&t.set("status",eh.a.Published))})),e.pendingItems.set(n),e.updateViewModel(),t.resetTimeout&&(window.clearTimeout(Qd),Qd=window.setTimeout((function(){return e.fetchPendingItems()}),e.getTimeoutLength())),Ya.isFunction(t.callback)&&t.callback()};i.length?e.videoDataService.getVideos(i,o):o(new r.a.Collection)}))}},{key:"updateViewModel",value:function(){var e=Vd.get("process:progress");if(this.pendingItems&&this.pendingItems.length){var t=this.pendingItems.where((function(e){return e.get("pendingProcessStatus")>=0})),n=0;Ya.each(t,(function(e){return n+=e.get("foregroundProgress")}));var r=100*t.length;e.set({progress:Math.round(n/r*100),items:this.pendingItems.length,hasErrors:this.pendingItems.length!==t.length})}else e.set({progress:0,items:0})}},{key:"getTimeoutLength",value:function(){return this.pendingItems.any((function(e){return e.get("pendingProcessStatus")===Jd.a.Processing}))?5e3:3e4}}])&&rh(t.prototype,n),i&&rh(t,i),a}(r.a.Service),uh=n(295);function lh(e){return(lh="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)}function fh(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ph(e,t){return(ph=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function dh(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=yh(e);if(t){var i=yh(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return hh(this,n)}}function hh(e,t){return!t||"object"!==lh(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function yh(e){return(yh=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var mh=function(e){!function(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}}),t&&ph(e,t)}(o,e);var t,n,r,i=dh(o);function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this)}return t=o,(n=[{key:"name",get:function(){return xs.b.Notification}},{key:"initDataServices",value:function(){this.notificationDataService=le.a.getInstance(xs.a.Notification,this),this.notificationSocketService=le.a.getInstance(xs.a.NotificationSocket,this),this.userDataService=le.a.getInstance(xs.a.User,this),this.bindSocketListeners(),this.bindAppListeners()}},{key:"bindSocketListeners",value:function(){var e=Ls.a.NOTIFICATIONS;this.listenTo(js.b.NOTIFICATIONS_SOCKET,"".concat(e,":new:sync"),this.addNewNotification),this.listenTo(js.b.NOTIFICATIONS_SOCKET,"".concat(e,":count:sync"),this.updateUnreadCount),this.listenTo(js.b.NOTIFICATIONS,"".concat(e,":seen"),this.updateUnreadCount)}},{key:"bindAppListeners",value:function(){this.listenTo(js.a.NOTIFICATIONS,uh.a.Read,this.markNotificationRead)}},{key:"getDataServices",value:function(){this.dataServicesExist()||this.initDataServices()}},{key:"dataServicesExist",value:function(){return!!this.notificationSocketService&&!!this.notificationDataService}},{key:"addNewNotification",value:function(e){var t=this;this.userDataService.getCurrentUser((function(n){t.notificationDataService.getNotifications(n.id,null,Ls.a.NOTIFICATIONS,(function(t){t.add(e,{at:0})}))}))}},{key:"updateUnreadCount",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=Vd.get(Ls.a.NOTIFICATIONS);t.set("unreadCount",e)}},{key:"getNotifications",value:function(e,t,n){var r=this;this.getDataServices(),this.notificationSocketService.receiveLatestNotifications(),this.userDataService.getCurrentUser((function(i){r.notificationDataService.getNotifications(i.id,e,t.toString(),n)}))}},{key:"getNotificationsMetadata",value:function(){return this.getDataServices(),this.notificationSocketService.receiveUnreadNotificationCount(),Vd.get(Ls.a.NOTIFICATIONS)}},{key:"markNotificationsSeen",value:function(){this.notificationDataService.markSeen()}},{key:"markNotificationRead",value:function(e){this.notificationDataService.markRead(e)}},{key:"getNotificationsCursors",value:function(e){return this.notificationDataService.getNotificationsCursors(e.toString())}}])&&fh(t.prototype,n),r&&fh(t,r),o}(r.a.Service),vh=n(118);function gh(e){return(gh="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)}function bh(e){return function(e){if(Array.isArray(e))return wh(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return wh(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return wh(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function wh(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function _h(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Sh(e,t){return(Sh=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Th(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Eh(e);if(t){var i=Eh(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ch(this,n)}}function Ch(e,t){return!t||"object"!==gh(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Eh(e){return(Eh=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function kh(e){return(kh="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)}function Oh(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ph(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ah(e,t){return(Ah=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Ih(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Rh(e);if(t){var i=Rh(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return xh(this,n)}}function xh(e,t){return!t||"object"!==kh(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Rh(e){return(Rh=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Lh=function(e){!function(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}}),t&&Ah(e,t)}(o,e);var t,n,r,i=Ih(o);function o(){return Oh(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"name",get:function(){return as.Notifications}}])&&Ph(t.prototype,n),r&&Ph(t,r),o}(function(e){!function(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}}),t&&Sh(e,t)}(o,e);var t,n,r,i=Th(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=i.call(this)).subscribeEvent="subscribe",t.reconnectTimeout=5e3,t.reconnectAttempts=100,t.reconnectTries=0,t.connection=t.createConnection(e),t.authEndpoint=e.authEndpoint,t.setProviderOptions(e),t.attachSocketEvents(),!1===e.lazy&&t.openConnection(),t}return t=o,(n=[{key:"setProviderOptions",value:function(e){e.subscribeEvent&&(this.subscribeEvent=e.subscribeEvent),e.reconnectTimeout&&(this.reconnectTimeout=e.reconnectTimeout),e.reconnectAttempts&&(this.reconnectAttempts=e.reconnectAttempts)}},{key:"openConnection",value:function(){if(!this.isConnectedOrConnecting())return this.setConnectionState(vh.b.Connecting),this.connect()}},{key:"connect",value:function(){var e=this;return $.when(this.getConnectionToken(),this.connection.start()).then((function(t){return e.start.apply(e,t)}),(function(t){return e.onConnectionError.apply(e,t)}))}},{key:"start",value:function(e){var t=this;return this.connection.invoke(this.subscribeEvent,e.token).then((function(){return t.setConnectionState(vh.b.Connected)})).catch((function(e){return t.onConnectionError(e)}))}},{key:"stop",value:function(){if(this.isConnectedOrConnecting())return this.connection.stop()}},{key:"attachSocketEvents",value:function(){var e=this;this.connection.onclose((function(){return e.onConnectionError})),this.connection.onreconnected((function(){return e.onReconnect}))}},{key:"onReconnect",value:function(){this.reconnectTries=0}},{key:"onConnectionError",value:function(e){var t=this;e?console.log("Connection Error. Reason: ".concat(e)):console.log("Connection Error."),this.setConnectionState(vh.b.Disconnected),!this.reconnectAttempts||this.reconnectTries>=this.reconnectAttempts||setTimeout((function(){return t.reconnectTries++,t.openConnection()}),this.reconnectTimeout||5e3)}},{key:"createConnection",value:function(e){var t=new vh.a,n=ac.a.removeTrailingSlash(e.endpoint),r="".concat(n,"/hubs/").concat(e.hubName),i={logger:vh.c.Error};return e.logging&&(i.logger=vh.c.Debug),t.withUrl(r,i).build()}},{key:"getConnectionToken",value:function(){var e={url:this.authEndpoint,method:"POST",type:"POST"};return $.ajax(e)}},{key:"setConnectionState",value:function(e){e===vh.b.Connected&&console.log("Connected!"),e===vh.b.Disconnected&&console.log("Disconnected!"),this.connectionState=e}},{key:"isConnectedOrConnecting",value:function(){return this.connectionState===vh.b.Connecting||this.connectionState===vh.b.Connected||this.connectionState===vh.b.Reconnecting}},{key:"create",value:function(e,t,n){this.openConnection(),this.rpc(e,t,n)}},{key:"read",value:function(e,t){this.openConnection(),this.subscribe(e,t)}},{key:"update",value:function(e,t,n){this.openConnection(),this.rpc(e,t,n)}},{key:"delete",value:function(e,t){this.openConnection(),this.rpc(e,null,t)}},{key:"parseError",value:function(){return cs.a}},{key:"rpc",value:function(e,t,n){var r=n.channel,i=n.successEvent,o=n.errorEvent;this.connection.invoke(e,t).then((function(e){return r.trigger.apply(r,[i].concat(bh(e)))})).catch((function(e){return r.trigger.apply(r,[o].concat(bh(e)))}))}},{key:"subscribe",value:function(e,t){var n=t.channel,r=t.successEvent;this.connection.on(e,(function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];n.trigger.apply(n,[r].concat(t))}))}}])&&_h(t.prototype,n),r&&_h(t,r),o}(ss.Object));function jh(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var Nh=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.store=t.store}var t,n,o;return t=e,(n=[{key:"name",get:function(){return Jc.a.Video}},{key:"clearVideoCache",value:function(){this.store.dispatch({type:i.a.Actions.INVALIDATE,keys:["video"],request:null})}},{key:"getVideos",value:function(e,t){var n=Qt.a.videos(e,(function(e){qr.a.isFunction(t)&&t(new r.a.Collection(e))}));return i.a.hooklessFetch(this.store,n),null}}])&&jh(t.prototype,n),o&&jh(t,o),e}();function Dh(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var Bh,Uh,Mh=function(e,t){return{url:"/api/domain/v2/process?".concat(e.map((function(e){return"pendingProcessId=".concat(e)}))),key:"pending:clear:".concat(e.join(",")),success:t,normalize:!1,type:us.a.DELETE}},Vh=function(e,t){return{url:"/api/domain/v2/process/cancel?".concat(e.map((function(e){return"pendingProcessId=".concat(e)}))),key:"pending:cancel:".concat(e.join(",")),success:t,normalize:!1,type:us.a.DELETE}},Fh=function(e,t){return{url:"/api/domain/v2/process/retry?".concat(e.map((function(e){return"pendingProcessId=".concat(e)}))),key:"pending:retry:".concat(e.join(",")),success:t,normalize:!1,type:us.a.POST}},Hh=function(e,t){return{url:"/api/domain/v2/process/".concat(e),key:"pending:item:".concat(e),success:t,normalize:!1}},zh=function(e){return{url:"/api/domain/v2/process?destination=2&status=1&status=-1",key:"pending",success:e,normalize:!1}},Wh=function(e,t){return{url:"/api/upload/complete",key:"complete:upload:".concat(e.id),type:us.a.POST,success:t,data:e}},qh=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.store=t.store}var t,n,o;return t=e,(n=[{key:"name",get:function(){return Jc.a.VideoUpload}},{key:"clearPendingItems",value:function(e,t){i.a.fetch(this.store.dispatch,Mh(e,t))}},{key:"cancelPendingItems",value:function(e,t){i.a.fetch(this.store.dispatch,Vh(e,t))}},{key:"retryPendingItems",value:function(e,t){i.a.fetch(this.store.dispatch,Fh(e,t))}},{key:"getPendingItem",value:function(e,t){i.a.fetch(this.store.dispatch,Hh(e,(function(e){t(new r.a.Model(e))})))}},{key:"getPendingItems",value:function(e){var t=zh(e);i.a.ajaxRequest({resource:t.url,type:us.a.GET,success:e,error:function(){}})}},{key:"completeVideoUpload",value:function(e,t){i.a.fetch(this.store.dispatch,Wh(e,t))}}])&&Dh(t.prototype,n),o&&Dh(t,o),e}();!function(e){e[e.Upload=1]="Upload",e[e.Tv=2]="Tv"}(Bh||(Bh={})),function(e){e[e.Permanent=0]="Permanent",e[e.Temporary=1]="Temporary"}(Uh||(Uh={}));var Gh=["pdf"],Kh=["doc","docx","dotx","dot","rtf","docm","odt"],Yh=["csv","txt"],Xh=["xls","xlt","xlsx"],Qh=["jpg","tif","png","bmp","gif","jpeg"],$h=["zip","rar"],Zh=["ppt","pot","pps","pptx"],Jh=["srt"],ey={IMAGES:".".concat(Qh.join(",.")),RESOURCES:".".concat([].concat(Kh,Xh,Zh,Gh,Yh,Qh,$h).join(",.")),SUBTITLES:".".concat(Jh.join(",."))};function ty(e){return(ty="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)}function ny(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ry(e,t){return(ry=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function iy(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ay(e);if(t){var i=ay(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return oy(this,n)}}function oy(e,t){return!t||"object"!==ty(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function ay(e){return(ay=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var sy=function(e){!function(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}}),t&&ry(e,t)}(o,e);var t,n,r,i=iy(o);function o(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e)}return t=o,(n=[{key:"name",get:function(){return"FileTypeError"}},{key:"lang",get:function(){return"upload.fileType"}},{key:"dialogOptions",get:function(){return{title:G.a.getPhrase(this.lang,"heading"),text:G.a.getPhrase(this.lang,"body"),buttons:[{text:G.a.getPhrase(this.lang,"okay"),className:"btn btn-primary",success:!0},{text:G.a.getPhrase(this.lang,"close"),className:"btn btn-link",close:!0}]}}}])&&ny(t.prototype,n),r&&ny(t,r),o}(_u.a),cy=n(356);function uy(e){return(uy="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)}function ly(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function fy(e,t){return(fy=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function py(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=hy(e);if(t){var i=hy(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return dy(this,n)}}function dy(e,t){return!t||"object"!==uy(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function hy(e){return(hy=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var yy=function(e){!function(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}}),t&&fy(e,t)}(o,e);var t,n,r,i=py(o);function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,G.a.getPhrase("upload.internetConnectivityError","title"))}return t=o,(n=[{key:"name",get:function(){return"InternetConnectivityError"}},{key:"dialogOptions",get:function(){return{title:G.a.getPhrase("upload.internetConnectivityError","heading"),text:G.a.getPhrase("upload.internetConnectivityError","body"),buttons:[{text:G.a.getPhrase("upload.internetConnectivityError","okay"),className:"btn",success:!0}]}}}])&&ly(t.prototype,n),r&&ly(t,r),o}(_u.a);function my(e){return(my="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)}function vy(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function gy(e,t){return(gy=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function by(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=_y(e);if(t){var i=_y(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return wy(this,n)}}function wy(e,t){return!t||"object"!==my(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function _y(e){return(_y=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Sy,Ty,Cy=[],Ey=function(e){!function(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}}),t&&gy(e,t)}(a,e);var t,n,i,o=by(a);function a(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),o.call(this,e)}return t=a,i=[{key:"isValidFile",value:function(e,t){return cy.isValidFile(e,t)}}],(n=[{key:"name",get:function(){return"DropzoneWrapper"}},{key:"initialize",value:function(e){var t=this.options.loggingEnabled,n=u.Radio.channel(e.channelName),i=this;this.dropzone=new cy(document.createElement("div"),{url:function(e){return e[0].cvUpload.ingestUrl},chunking:this.options.chunkingEnabled,chunkSize:this.options.chunkSize,forceChunking:!0,autoProcessQueue:!0,maxFilesize:this.options.maxFileSize,acceptedFiles:this.options.acceptedFiles,paramName:"content",init:function(){var e=this;t&&(Ya.each(Cy,(function(t){e.on(t,(function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];var i=n[0]instanceof File?n[0].name:n[0];console.info(t,i,n)}))})),this.on("uploadprogress",(function(e,t,r){var o=r/e.size*100;n.trigger("progress",i.getId(e),o,r)})),this.on("success",(function(e){var t=e.upload.chunks,r=Ya.last(t),i=r.xhr;i||(i=r.file.xhr);var o=JSON.parse(i.response);e.cvUpload.fileId=o.id,n.trigger("upload:success",e,o)})),this.on("error",(function(e,t,n){n&&0===n.status?r.a.ErrorHelper.throw(new yy):"canceled"!==e.status&&r.a.ErrorHelper.throw(new wu(G.a.getPhrase("upload.services","uploadError",{fileName:e.name,message:t.message})))})))},params:function(e,t,n){if(n)return{chunk_index:n.index,upload_length:n.file.size}},addedfile:function(){},thumbnail:function(){},uploadprogress:function(){}})}},{key:"getId",value:function(e){return e.upload.uuid}},{key:"addFile",value:function(e){this.dropzone.addFile(e)}},{key:"removeFile",value:function(e){this.dropzone.removeFile(e)}},{key:"start",value:function(){this.dropzone.processQueue()}},{key:"destroy",value:function(){this.dropzone.destroy()}}])&&vy(t.prototype,n),i&&vy(t,i),a}(r.a.Service);function ky(e){return(ky="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)}function Oy(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Py(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ay(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Iy(e,t,n){return t&&Ay(e.prototype,t),n&&Ay(e,n),e}function xy(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}}),t&&Ry(e,t)}function Ry(e,t){return(Ry=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Ly(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Ny(e);if(t){var i=Ny(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return jy(this,n)}}function jy(e,t){return!t||"object"!==ky(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Ny(e){return(Ny=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Dy,By=function(e){xy(n,e);var t=Ly(n);function n(){return Py(this,n),t.call(this,{dataProvider:le.a.getInstance(as.Ajax),cache:le.a.getInstance(Ka.Fifo),alertService:le.a.getInstance(ws.a.ALERT)})}return Iy(n,[{key:"name",get:function(){return"UploadDataService"}},{key:"channelName",get:function(){return"private:upload:data:service"}},{key:"requestUploads",value:function(e,t,n,r){var i=this,o=this.chain();Ya.each(e,(function(e){o.create({resource:"/api/upload",eventPrefix:"request:upload",data:i.getFileUploadRequest(e,t),callback:function(t){n(e,t)}})})),o.func((function(){r()})).run()}},{key:"cancelUpload",value:function(e,t,n){this.create({resource:"/api/upload/cancel",eventPrefix:"cancel:upload",data:{uploadId:e,ingestUrl:t},callback:n})}},{key:"getFileUploadRequest",value:function(e,t){var n=e.name.split(".");return{name:n.join("."),extension:n.length>1?n.pop():"",fileSize:e.size,fileLifestyle:t}}},{key:"onDestroy",value:function(){le.a.releaseInstance(as.Ajax).releaseInstance(Ka.Fifo)}}]),n}(Is);!function(e){e[e.Video=0]="Video",e[e.LearningResource=1]="LearningResource",e[e.Subtitle=2]="Subtitle"}(Dy||(Dy={}));var Uy,My,Vy=(Oy(Sy={},Dy.Video,"video/*"),Oy(Sy,Dy.LearningResource,ey.RESOURCES),Oy(Sy,Dy.Subtitle,ey.SUBTITLES),Sy),Fy=(Oy(Ty={},Dy.Video,js.c.VIDEO_UPLOAD),Oy(Ty,Dy.LearningResource,js.c.RESOURCE_UPLOAD),Oy(Ty,Dy.Subtitle,js.c.SUBTITLE_UPLOAD),Ty),Hy=function(e){xy(n,e);var t=Ly(n);function n(){return Py(this,n),t.apply(this,arguments)}return Iy(n,[{key:"initialize",value:function(){this.uploadDataService=new By,this.progressViewModel=Vd.get("upload:progress:".concat(this.uploadType)),this.bindListeners()}},{key:"channelName",get:function(){return Fy[this.uploadType]}},{key:"lang",get:function(){return"upload.services"}},{key:"initUploader",value:function(e,t){if(!this.uploader){var n=4194304;e&&n<e&&(n=e),t&&n>t&&(n=t),this.uploader=new Ey({chunkingEnabled:!0,loggingEnabled:!0,chunkSize:n,maxFileSize:53687091200,acceptedFiles:this.getAcceptedFiles(),channelName:this.channelName})}}},{key:"bindListeners",value:function(){this.listenTo(this.channelName,"progress",this.onProgress),this.listenTo(this.channelName,"upload:success",this.onSuccess)}},{key:"onProgress",value:function(e,t,n){var r=this.collection.get(e);r&&(r.set({progress:t>100?100:t,totalUploaded:n}),this.setOverallProgress())}},{key:"isUploading",value:function(){return!!this.getCollection().length}},{key:"getCollection",value:function(){return this.collection||(this.collection=new r.a.Collection),this.collection}},{key:"setOverallProgress",value:function(){var e=0,t=0,n=this.getCollection();if(n.length){n.each((function(n){e+=n.get("totalUploaded")||0,t+=n.get("file").size||0}));var r=e/t*100,i=r>100;this.progressViewModel.set({progress:i?100:r,done:i})}else this.progressViewModel.set({progress:0})}},{key:"isValidFile",value:function(e){return Ey.isValidFile(e,this.getAcceptedFiles())}},{key:"addFiles",value:function(e,t){var n=this;Ya.any(e,(function(e){return!n.isValidFile(e)}))?r.a.ErrorHelper.throw(new sy(G.a.getPhrase(this.lang,"invalidFileType"))):this.requestUploads(e,t)}},{key:"requestUploads",value:function(e,t){var n=this,r=this.isUploading(),i=this.getCollection();this.uploadDataService.requestUploads(e,this.fileLifestyle,(function(e,t){n.initUploader(1024*t.minChunkSize,1024*t.maxChunkSize),e.cvUpload={uploadId:t.uploadId,ingestUrl:t.ingestUrl},n.uploader.addFile(e);var r=e.name;n.uploadType===Dy.Video&&(r=r.replace(/\.[^/.]+$/,"")),i.add({id:n.uploader.getId(e),file:e,name:r},{at:i.length-1})}),(function(){t&&Xu.a.logUserAction({uploadCount:e.length},t),u.Radio.channel(n.channelName).trigger(Af.a.FILES_ADDED,e,r)}))}},{key:"addFile",value:function(e,t){this.addFiles([e],t)}},{key:"cancelUpload",value:function(e){var t=this,n=this.getCollection(),r=n.get(e);if(r){var i=r.get("file");this.uploader.removeFile(i),n.remove(r),this.uploadDataService.cancelUpload(i.cvUpload.uploadId,i.cvUpload.ingestUrl,(function(){Xu.a.logUserAction({id:i.cvUpload.uploadId},{entity:E.EntityType.Video,actionType:E.UserAction.Upload,workflowPhase:E.WorkflowPhase.Discard,descriptor:E.OperationDescriptor.Single,location:E.LocationContext.MyUploads}),u.Radio.channel(t.channelName).trigger(Af.a.UPLOAD_CANCELLED)})),this.setOverallProgress()}}},{key:"onSuccess",value:function(e,t){var n=this.uploader.getId(e),r=this.getCollection().get(n);r.set("fileInfo",t),Xu.a.logUserAction({id:e.cvUpload.uploadId},{entity:E.EntityType.Video,actionType:E.UserAction.Upload,workflowPhase:E.WorkflowPhase.Complete,descriptor:E.OperationDescriptor.Single,location:E.LocationContext.VideoUpload}),u.Radio.channel(this.channelName).trigger(Af.a.UPLOAD_COMPLETE,r)}},{key:"cancelAllUploads",value:function(){var e=this,t=this.getCollection().map((function(e){return e.get("id")}));Ya.each(t,(function(t){return e.cancelUpload(t)}))}},{key:"getAcceptedFiles",value:function(){return Vy[this.uploadType]}}]),n}(r.a.Service),zy=function(e){xy(n,e);var t=Ly(n);function n(){return Py(this,n),t.apply(this,arguments)}return Iy(n,[{key:"uploadType",get:function(){return Dy.Video}},{key:"name",get:function(){return xs.b.VideoUpload}},{key:"fileLifestyle",get:function(){return Uh.Temporary}}]),n}(Hy);function Wy(e){return(Wy="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)}function qy(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Gy(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ky(e,t,n){return(Ky="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=$y(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Yy(e,t){return(Yy=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Xy(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=$y(e);if(t){var i=$y(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Qy(this,n)}}function Qy(e,t){return!t||"object"!==Wy(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function $y(e){return($y=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}!function(e){e[e.IosApp=1]="IosApp",e[e.AndroidApp=2]="AndroidApp",e[e.WinApp=3]="WinApp",e[e.LibraryPublisher=4]="LibraryPublisher",e[e.ExchangeClient=5]="ExchangeClient",e[e.Online=6]="Online",e[e.Tinder=7]="Tinder",e[e.Cloud247=8]="Cloud247",e[e.Livestream=9]="Livestream",e[e.Curator=10]="Curator",e[e.LibraryEditor=11]="LibraryEditor",e[e.Lite=12]="Lite"}(Uy||(Uy={})),function(e){e[e.ExternalOnly=0]="ExternalOnly",e[e.EmbeddedOnly=1]="EmbeddedOnly"}(My||(My={}));var Zy=G.a.encloseNamespace("upload.services"),Jy=function(e){!function(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}}),t&&Yy(e,t)}(o,e);var t,n,r,i=Xy(o);function o(){return qy(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"initialize",value:function(){Ky($y(o.prototype),"initialize",this).call(this),this.videoUploadDataService=le.a.getInstance(Jc.a.VideoUpload,this),this.pendingItemsService=le.a.getInstance(Jc.b.PendingItems,this),this.userDataService=le.a.getInstance(Jc.a.FlightUser,this),this.alertService=le.a.getInstance(ws.a.ALERT,this),this.listenTo(this.channelName,Af.a.FILES_ADDED,this.onUploadStart),this.listenTo(this.channelName,Af.a.UPLOAD_COMPLETE,this.unlockNav),this.listenTo(this.channelName,Af.a.UPLOAD_CANCELLED,this.unlockNav)}},{key:"onUploadStart",value:function(e){var t={type:bs.a.Success,heading:Zy("startUploadAlertHeading"),message:1===e.length?Zy("startUploadSingleAlertBody",{videoName:e[0].name}):Zy("startUploadMultipleAlertBody",{uploadCount:e.length})},n=W.a.getCurrentContext().appLink;!!ip.a.getMyVideosAppLinks().find((function(e){return n.application===e.application&&n.action===e.action}))||(t.appLinkText=Zy("startUploadAlertAppLinkText",{smartCount:e.length}),t.appLink={application:P.a.DEFAULT,action:R.a.Default.MY_VIDEOS},t.appLinkClassName="info-link"),this.alertService.createAlert(t)}},{key:"unlockNav",value:function(){this.getCollection().some((function(e){return e.get("progress")<100}))||u.Radio.channel(this.channelName).trigger(Af.a.UNLOCK_NAV)}},{key:"getUpload",value:function(e){var t=this.uploader.getId(e);return this.getCollection().get(t)}},{key:"completeUpload",value:function(e,t){var n=this;e.set("sending",!0),this.userDataService.getCurrentUser((function(r){n.userDataService.getWorkspace((function(i){n.videoUploadDataService.completeVideoUpload({id:e.get("id"),userId:r.id,customerId:r.customerId,libraryId:i.id,categoryId:null,pendingProcessOrigin:Bh.Upload,origin:Uy.Lite,fileId:t.id,subtitleOptions:{subtitleExtractOptions:My.EmbeddedOnly},video:{name:e.get("name"),description:e.get("description")}},(function(t){e.set("pendingProcessId",t.pendingProcessId),n.pendingItemsService.forceFetchPendingItems({resetTimeout:!0})}))}))}))}},{key:"onSuccess",value:function(e,t){var n=this;Ky($y(o.prototype),"onSuccess",this).call(this,e,t);var r=this.getUpload(e);r.get("editingMetadata")?this.listenToOnce(r,"change:editingMetadata",(function(){n.completeUpload(r,t)})):this.completeUpload(r,t)}}])&&Gy(t.prototype,n),r&&Gy(t,r),o}(zy);function em(e){return(em="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)}function tm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function nm(e,t){return(nm=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function rm(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=om(e);if(t){var i=om(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return im(this,n)}}function im(e,t){return!t||"object"!==em(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function om(e){return(om=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var am=function(e){!function(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}}),t&&nm(e,t)}(o,e);var t,n,r,i=rm(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=i.call(this,e)).imageUrls=e.imageUrls,t}return t=o,(n=[{key:"name",get:function(){return xs.b.ImageUrl}},{key:"getImageUrls",value:function(){return this.imageUrls}}])&&tm(t.prototype,n),r&&tm(t,r),o}(r.a.Service);var sm=n(305),cm=n(290);function um(e,t){return Mf.a.isObject(t.xhr)?Object.assign(Object.assign({},e),{version:t.xhr.getResponseHeader("X-App-Version")}):e}var lm={version:null};function fm(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:lm,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case cm.a.API_RESPONSE:return um(e,t)}return e}function pm(e){return(pm="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)}function dm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function hm(e,t){return"string"==typeof t.payload.dataOrKey&&void 0!==t.payload.keyData?Object.assign(Object.assign({},e),dm({},t.payload.viewModelKey,Object.assign(Object.assign({},e[t.payload.viewModelKey]),dm({},t.payload.dataOrKey,t.payload.keyData)))):("object"===pm(t.payload.dataOrKey)&&Array.isArray(t.payload.dataOrKey),Object.assign(Object.assign({},e),dm({},t.payload.viewModelKey,t.payload.dataOrKey)))}function ym(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case ae.a.UPDATE:return hm(e,t)}return e}var mm=n(221);function vm(e){return(vm="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)}function gm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function bm(e,t){return(bm=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function wm(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Sm(e);if(t){var i=Sm(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return _m(this,n)}}function _m(e,t){return!t||"object"!==vm(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Sm(e){return(Sm=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Tm=function(e){!function(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}}),t&&bm(e,t)}(a,e);var t,n,i,o=wm(a);function a(e,t,n){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),(r=o.call(this,G.a.getPhrase("shared.oldVersion","title",{oldVersion:e,newVersion:t}))).btnVariant=n,r}return t=a,(n=[{key:"name",get:function(){return"OldVersionError"}},{key:"dialogOptions",get:function(){return{title:G.a.getPhrase("shared.oldVersion","heading"),text:G.a.getPhrase("shared.oldVersion","body"),buttons:[{text:G.a.getPhrase("shared.oldVersion","reload"),className:"btn btn-".concat(this.btnVariant),success:!0}]}}},{key:"onDone",value:function(){r.a.LocationUtils.Reload()}}])&&gm(t.prototype,n),i&&gm(t,i),a}(_u.a);function Cm(e){return(Cm="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)}function Em(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function km(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Om(e,t,n){return t&&km(e.prototype,t),n&&km(e,n),e}function Pm(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}}),t&&Am(e,t)}function Am(e,t){return(Am=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Im(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Rm(e);if(t){var i=Rm(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return xm(this,n)}}function xm(e,t){return!t||"object"!==Cm(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Rm(e){return(Rm=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Lm=function(e){Pm(n,e);var t=Im(n);function n(){return Em(this,n),t.apply(this,arguments)}return Om(n,[{key:"onDone",value:function(){r.a.LocationUtils.PageLoad("/login?returnUrl=".concat(encodeURIComponent(r.a.LocationUtils.GetCurrentUrl())))}}]),n}(function(e){Pm(n,e);var t=Im(n);function n(e){var r;return Em(this,n),(r=t.call(this,G.a.getPhrase("shared.authentication","title"))).btnVariant=e,r}return Om(n,[{key:"name",get:function(){return"AuthenticationError"}},{key:"dialogOptions",get:function(){return{title:G.a.getPhrase("shared.authentication","heading"),text:G.a.getPhrase("shared.authentication","body"),buttons:[{text:G.a.getPhrase("shared.authentication","reload"),className:"btn btn-".concat(this.btnVariant),success:!0}]}}},{key:"onDone",value:function(){r.a.LocationUtils.Reload()}}]),n}(_u.a)),jm=n(242),Nm={"{gateway}":"gatewayApiUrl","{image}":"imageCdnUrl"};function Dm(e){return function(t,n){var r=Object.keys(Nm).find((function(e){return t.resource.startsWith(e)}));if(!r)return n(t);function a(){n(t)}function s(e,i){var o=e[Nm[r]],a=Object.assign(Object.assign({},t),{resource:jm.a.safeUrlConcat(o,t.resource.split("".concat(r,"/"))[1])});(null==i?void 0:i.value)&&(a.headers={authorization:"Bearer ".concat(i.value)}),n(a)}i.a.hooklessFetch(e,nu.a.config((function(t){i.a.hooklessFetch(e,o.a.currentUser((function(n){return function(t,n){if(!n.isAuthenticated)return void s(t);i.a.hooklessFetch(e,o.a.token((function(e){return s(t,e)}),a))}(t,n)}),a))}),a))}}var Bm,Um=/\(([^()]*)\)/g;function Mm(e,t){return function(n,i){var o=new r.a.Middleware;decodeURIComponent(n.resource).replace(Um,(function(e){var n=t[e];if("string"!=typeof n)return n?void o.use(n):e;o.use(function(e,t){return function(n,r){r(Object.assign(Object.assign({},n),{resource:n.resource.replace(e,t)}))}}(e,n))}));var a={resource:n.resource,store:e};o.go(a,(function(e){i(Object.assign(Object.assign({},n),{resource:e.resource}))}))}}function Vm(e,t){return function(n){var o=new r.a.Middleware;o.use(Dm(e.store)),o.use(Mm(e.store,t)),o.go(n,(function(e){i.a.ajaxRequest(e)}))}}function Fm(e){return function(t){return function(r){if(r.type===i.a.Actions.API_RESPONSE){var a=function(e){var t,n=e.getState().flightData,r=o.a.currentUser().key,i=null===(t=null==n?void 0:n.resources)||void 0===t?void 0:t[r];if(i){var a=Wt.a.first(i.entityIds);if(a)return n.entities[a]}}(e);if(!a||a.contentRegion!==Bm.US)return t(r);n.e(146).then(n.bind(null,2023)).then((function(e){for(var n=e.TranslateTermsHelper,i=Object.keys(r.entities),o=0;o<i.length;o++){var a=i[o],s=r.entities[a];s.typeId===qt.a.Series&&"series"===s.type&&(s.name=n.translate(s.name),s.description=n.translate(s.description))}t(r)}))}else t(r)}}}!function(e){e.AU="content-ap-southeast-1",e.NZ="content-ap-southeast-2",e.UK="content-eu-west-1",e.SCOT="content-eu-west-2",e.US="content-na-central-1",e.GLOBAL="content-global"}(Bm||(Bm={}));var Hm=n(238);function zm(e){return function(t,n){i.a.hooklessFetch(t.store,o.a.currentUser((function(r){var i="".concat("video[thumbnail,_canBeConsumed],_canUpdate,_videoProgress,owner");r.isAuthenticated&&(i+=",favouritedby{id:".concat(r.id,"}")),e===Xc.b.CLIP&&(i+=",interactives[thumbnail,clip[video[thumbnail]],video[thumbnail]]");var o=t.resource.replace(e,i);n(Object.assign(Object.assign({},t),{resource:o}))}),(function(){return n(t)})))}}var Wm;function qm(e){return function(t,n){i.a.hooklessFetch(t.store,o.a.currentUser((function(r){var i="".concat("thumbnail,rating,series,season,_videoProgress");r.isAuthenticated&&(i+=",favouritedby{id:".concat(r.id,"}")),e===Xc.b.VIDEO_COLLECTION&&(i+=",_canUpdate,subtitles{limit:1},_canBeConsumed");var o=t.resource.replace(e,i);n(Object.assign(Object.assign({},t),{resource:o}))}),(function(){return n(t)})))}}function Gm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Km=(Gm(Wm={},Xc.b.VIDEO_COLLECTION,qm(Xc.b.VIDEO_COLLECTION)),Gm(Wm,Hm.a.WIDGET_VIDEO_COLLECTION,qm(Hm.a.WIDGET_VIDEO_COLLECTION)),Gm(Wm,Xc.b.CLIP,zm(Xc.b.CLIP)),Gm(Wm,Xc.b.CLIP_COLLECTION,zm(Xc.b.CLIP_COLLECTION)),Gm(Wm,Xc.b.INTERACTIVE,(function(e,t){i.a.hooklessFetch(e.store,o.a.currentUser((function(n){var r="video[thumbnail,_canBeConsumed],thumbnail,clip[video[thumbnail,_canBeConsumed]],_canUpdate,_isClickViewContent,_timepoints";n.isAuthenticated&&(r+=",favouritedby{id:".concat(n.id,"}"));var i=e.resource.replace(Xc.b.INTERACTIVE,r);t(Object.assign(Object.assign({},e),{resource:i}))}),(function(){return t(e)})))})),Wm);var Ym=n(248);function Xm(e){return(Xm="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)}function Qm(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function $m(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Zm(e,t){return(Zm=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Jm(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=tv(e);if(t){var i=tv(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ev(this,n)}}function ev(e,t){return!t||"object"!==Xm(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function tv(e){return(tv=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var nv=function(e){!function(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}}),t&&Zm(e,t)}(o,e);var t,n,r,i=Jm(o);function o(){return Qm(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"appLinks",get:function(){return{searchResults:{application:P.a.SEARCH,action:R.a.Search.HOME},series:{application:P.a.DEFAULT,action:R.a.Default.SERIES},videoDetails:{application:P.a.DEFAULT,action:R.a.Default.PLAY_VIDEO},tagSearch:{application:P.a.SEARCH,action:R.a.Search.HOME},classification:{application:P.a.SUBJECT,action:R.a.Subjects.CLASSIFICATION}}}},{key:"addSlugs",get:function(){return!0}},{key:"searchBarPlaceholder",get:function(){return G.a.getPhrase("search.searchAppVariables","searchBarPlaceholder")}},{key:"showSearchTips",get:function(){return!1}},{key:"useContextualSearch",get:function(){return!1}}])&&$m(t.prototype,n),r&&$m(t,r),o}(Ym.BaseSearchAppVariables),rv=n(55),iv=n(761),ov=n.n(iv);function av(e){return(av="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)}function sv(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function cv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function uv(e,t){return(uv=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function lv(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=pv(e);if(t){var i=pv(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return fv(this,n)}}function fv(e,t){return!t||"object"!==av(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function pv(e){return(pv=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var dv=function(e){!function(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}}),t&&uv(e,t)}(o,e);var t,n,r,i=lv(o);function o(){return sv(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"appLinks",get:function(){return{videoDetails:{application:P.a.DEFAULT,action:R.a.Default.PLAY_VIDEO},notifications:{application:P.a.NOTIFICATIONS,action:R.a.Notifications.HOME},shareLink:{application:P.a.SHARE,action:R.a.Share.VIEW_SHARE_LINK}}}},{key:"notificationTypesWithAppLinks",get:function(){return[rv.a.VideoReviewReminder,rv.a.VideoReviewAddedToLibrary,rv.a.CustomLibraryVideoAvailable,rv.a.WorkspaceVideoAvailable,rv.a.ExchangeVideoAvailable,rv.a.NewDirectShare,rv.a.MyVideosVideoAvailable]}},{key:"unsupportedNotificationLinks",get:function(){return[rv.a.EditedVideoAvailable,rv.a.VideoReviewAddedToLibrary,rv.a.VideoReviewReminder,rv.a.StaffRequest,rv.a.StaffRequestFulfilled,rv.a.SuggestEdit,rv.a.VideoRequestAvailable,rv.a.VideoRequestDenied,rv.a.ChapterMergeSuccess]}},{key:"notificationsEmptyStateUrl",get:function(){return xt.a.EmptyStates.NOTIFICATIONS}},{key:"bellIconColor",get:function(){return"dark"}},{key:"notificationsViewClassNames",get:function(){return"px-3 ".concat(ov.a.notificationsView)}}])&&cv(t.prototype,n),r&&cv(t,r),o}(Ym.BaseNotificationsAppVariables);var hv=n(121);function yv(e){return(yv="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)}var mv={register:function(){var e=this;hv.registerHelper("lang",(function(t,n){if(e.isValid(t,n)){var r=n.data.root.languageNamespace;return G.a.getPhrase(r,t,n.hash)}}))},isValid:function(e,t){return"string"!=typeof e?(r.a.ErrorHelper.throw(new oe.a("No language key provided.")),!1):"object"!==yv(t)?(r.a.ErrorHelper.throw(new oe.a("All options must be key-value pairs, e.g. `smartCount=options.videoCount`")),!1):!Ya.isUndefined(t.data.root.languageNamespace)||(r.a.ErrorHelper.throw(new oe.a("No `lang` property provided.")),!1)}};var vv,gv=n(256);function bv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}!function(e){e[e.Unclassified=0]="Unclassified",e[e.Primary=1]="Primary",e[e.Secondary=2]="Secondary",e[e.K12=3]="K12",e[e.Tertiary=4]="Tertiary",e[e.NonEducational=5]="NonEducational",e[e.Partners=6]="Partners",e[e.Internal=7]="Internal",e[e.Other=8]="Other",e[e.ClickView=254]="ClickView",e[e.System=255]="System"}(vv||(vv={}));var wv={curriculum:!1},_v=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.options=Object.assign({onlineModules:wv},t)}var t,n,r;return t=e,(n=[{key:"name",get:function(){return xs.b.AppOptions}},{key:"hasCurriculum",get:function(){return this.options.onlineModules.curriculum}},{key:"isTeacher",get:function(){return this.options.onlineRole===gv.a.Staff}},{key:"onlineRole",get:function(){return this.options.onlineRole}},{key:"onlineCustomerType",get:function(){return this.options.customerType}}])&&bv(t.prototype,n),r&&bv(t,r),e}();var Sv=n(157),Tv=n(294);function Cv(e){return(Cv="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)}function Ev(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function kv(e,t){return(kv=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Ov(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Av(e);if(t){var i=Av(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Pv(this,n)}}function Pv(e,t){return!t||"object"!==Cv(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Av(e){return(Av=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Iv=function(e){!function(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}}),t&&kv(e,t)}(a,e);var t,n,i,o=Ov(a);function a(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),(t=o.call(this)).clients={},t.enrichers={},Vd.get("application:options").set(null!=e?e:{}),t.bindNavigationListener(),t}return t=a,(n=[{key:"name",get:function(){return fe.a.Analytics}},{key:"registerTransport",value:function(e,t){return this.transport=new e(t),this.bindTransportListeners(),this}},{key:"bindTransportListeners",value:function(){this.listenTo(Tv.a.ANALYTICS,Sv.a.Inlet,this.onEvent)}},{key:"registerClient",value:function(e,t){return this.validateConstructor(e),this.clients[e.prototype.name]=e.prototype.name,this.transport.subscribe(new e(t)),this}},{key:"registerEnricher",value:function(e,t){this.validateConstructor(e);var n=new e(t);return this.enrichers[e.name]=n,this.registerMiddleware(Ya.bind(n.enrich,n)),this}},{key:"hasEnricher",value:function(e){return!!this.enrichers[e.prototype.name]}},{key:"onEvent",value:function(e){var t=this;this.executeMiddleware(e,(function(e){t.transport.publish(e)}))}},{key:"validateConstructor",value:function(e){var t=e.prototype.name;t||r.a.ErrorHelper.throw(new oe.a("Classes registered with ".concat(this.name," must have a unique name property.")));var n=function(t){return qr.a.isFunction(e.prototype.isType)&&e.prototype.isType(t)};(n("BaseAnalyticsClient")||"CollectionApiClient"===t)&&this.clients[t]&&r.a.ErrorHelper.throw(new oe.a("A client class with the name: ".concat(t," has already been registered with ").concat(this.name))),n("BaseAnalyticsEnricher")&&this.enrichers[t]&&r.a.ErrorHelper.throw(new oe.a("An enricher class named: ".concat(t," has already been registered with ").concat(this.name)))}},{key:"registerMiddleware",value:function(e){var t;this.executeMiddleware=(t=this.executeMiddleware,function(n,r){return t(n,(function(){return e(n,r)}))})}},{key:"executeMiddleware",value:function(e,t){t(e)}},{key:"bindNavigationListener",value:function(){this.listenTo(p.a.SHELL,r.a.EventNames.URL_CHANGE,this.logNavigate)}},{key:"logNavigate",value:function(e,t){Xu.a.logNavigate(e,t)}}])&&Ev(t.prototype,n),i&&Ev(t,i),a}(r.a.Service);function xv(e){return(xv="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)}function Rv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Lv(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function jv(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}}),t&&Nv(e,t)}function Nv(e,t){return(Nv=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Dv(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uv(e);if(t){var i=Uv(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Bv(this,n)}}function Bv(e,t){return!t||"object"!==xv(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Uv(e){return(Uv=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Mv=function(e){jv(o,e);var t,n,r,i=Dv(o);function o(){return Lv(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"name",get:function(){return"EventTransport"}},{key:"channelName",get:function(){return"event:transport"}},{key:"publish",value:function(e){this.getChannel().trigger(Sv.a.Outlet,e)}},{key:"subscribe",value:function(e){var t=e,n=function(n){qr.a.isFunction(t.shouldLog)&&!t.shouldLog(n)||e.log(n)};Ya.isFunction(t.listenTo)?t.listenTo(this.getChannel(),Sv.a.Outlet,n):this.listenTo(this.getChannel(),Sv.a.Outlet,n)}}])&&Rv(t.prototype,n),r&&Rv(t,r),o}(function(e){jv(n,e);var t=Dv(n);function n(){return Lv(this,n),t.apply(this,arguments)}return n}(ss.Object));function Vv(e){return(Vv="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)}function Fv(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Hv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function zv(e,t){return(zv=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Wv(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Gv(e);if(t){var i=Gv(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return qv(this,n)}}function qv(e,t){return!t||"object"!==Vv(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Gv(e){return(Gv=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Kv=function(e){!function(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}}),t&&zv(e,t)}(o,e);var t,n,r,i=Wv(o);function o(){return Fv(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"name",get:function(){return"UserDataEnricher"}},{key:"initialize",value:function(){this.user=Vd.get("application:options").get("user")}},{key:"shouldEnrich",value:function(e){return!0}},{key:"enrich",value:function(e,t){this.shouldEnrich(e)||t(e),e.enrich("user",this.getUser(this.user)),t(e)}},{key:"getUser",value:function(e){return{country:e.countryCode,customerId:e.customerId,id:e.id,role:e.role}}}])&&Hv(t.prototype,n),r&&Hv(t,r),o}(be),Yv=n(308);function Xv(e){return(Xv="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)}function Qv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function $v(e,t){return($v=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Zv(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=eg(e);if(t){var i=eg(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Jv(this,n)}}function Jv(e,t){return!t||"object"!==Xv(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function eg(e){return(eg=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var tg=function(e){!function(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}}),t&&$v(e,t)}(a,e);var t,n,i,o=Zv(a);function a(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),(t=o.call(this,e)).productName=e.productName,t.productVersion=e.productVersion,t}return t=a,(n=[{key:"name",get:function(){return"CoreContextEnricher"}},{key:"shouldEnrich",value:function(e){return!0}},{key:"enrich",value:function(e,t){this.shouldEnrich(e)||t(e),e.enrich("coreContext",this.getCoreContext()),t(e)}},{key:"getCoreContext",value:function(){return{timestamp:this.getTimestamp(),product:this.getProductInfo(),request:this.getRequestInfo(),client:this.getClientInfo()}}},{key:"getTimestamp",value:function(){return oc.utc().toISOString()}},{key:"getProductInfo",value:function(){return{name:this.productName,version:this.productVersion}}},{key:"getRequestInfo",value:function(){return{referrer:r.a.LocationUtils.GetCurrentReferrer(),requestUrl:r.a.LocationUtils.GetCurrentUrl()}}},{key:"getClientInfo",value:function(){var e=Yv.a.getOperatingSystem(),t=Yv.a.getBrowser();return{os:e.os,osVersion:e.version,browser:t.browser,browserVersion:t.version,screenResolution:"".concat(window.screen.width,"x").concat(window.screen.height)}}}])&&Qv(t.prototype,n),i&&Qv(t,i),a}(be),ng=n(300);function rg(e){return(rg="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)}function ig(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function og(e,t){return(og=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function ag(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=cg(e);if(t){var i=cg(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return sg(this,n)}}function sg(e,t){return!t||"object"!==rg(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function cg(e){return(cg=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var ug=function(e){!function(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}}),t&&og(e,t)}(o,e);var t,n,r,i=ag(o);function o(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e)}return t=o,(n=[{key:"shouldLog",value:function(e){return!0}},{key:"log",value:function(e){}},{key:"isType",value:function(e){return e===o.type}}])&&ig(t.prototype,n),r&&ig(t,r),o}(r.a.Service);function lg(e){return(lg="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)}function fg(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function pg(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function dg(e,t){return(dg=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function hg(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=mg(e);if(t){var i=mg(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return yg(this,n)}}function yg(e,t){return!t||"object"!==lg(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function mg(e){return(mg=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}ug.type="BaseAnalyticsClient";var vg=function(e){!function(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}}),t&&dg(e,t)}(a,e);var t,n,i,o=hg(a);function a(){return fg(this,a),o.apply(this,arguments)}return t=a,(n=[{key:"name",get:function(){return"DebuggerClient"}},{key:"shouldLog",value:function(){return F.a.isDevelopment}},{key:"log",value:function(e){var t=Ya.clone(e);for(var n in e){var i=t[n];(i instanceof r.a.Model||i instanceof r.a.Collection)&&(t[n]=i.toJSON())}console.log("Event Debugger: ",t)}}])&&pg(t.prototype,n),i&&pg(t,i),a}(ug),gg=n(184),bg=n(215),wg=n(699),_g={getUser:function(e){return new Promise((function(t){i.a.hooklessFetch(e.store,o.a.currentUser((function(n){var r,a;if(n.isAuthenticated){var s=new xd(2),c=function(){s.decrement(),s.getValue()>0||t(_g.mapCurrentUserToAnalyticsUser(n,r,a))};i.a.hooklessFetch(e.store,o.a.user(n.id,(function(e){r=e,c()}))),i.a.hooklessFetch(e.store,wg.a.customer(n.customerId,(function(e){a=e,c()})))}else t(null)})))}))},mapCurrentUserToAnalyticsUser:function(e,t,n){var r,i=cf.a.getUserTypeString(t);return{id:null==e?void 0:e.id,countryCode:null==e?void 0:e.countryCode,contentRegion:null==e?void 0:e.contentRegion,instanceRegion:null==e?void 0:e.instanceRegion,customerId:null==e?void 0:e.customerId,customerGuid:null==n?void 0:n.customerGuid,customerName:null==e?void 0:e.customerName,crmId:null==n?void 0:n.crmId,role:null==e?void 0:e.role,userGroup:i,yearGroup:i===bg.a.Staff?"staff":null===(r=null==t?void 0:t.masterYearGroup)||void 0===r?void 0:r.name}}},Sg={logError:function(e){qr.a.isFunction(null===trackJs||void 0===trackJs?void 0:trackJs.track)&&trackJs.track(e)}},Tg={formatData:function(e){var t=gg.a.formatData(e),n={};return e.plugin&&(n.plugin=e.plugin),Object.assign(Object.assign({},n),t)}},Cg=l.a.Router.prototype._routeToRegExp("share/:id(/)"),Eg=l.a.Router.prototype._routeToRegExp("share/embed/:id(/)");var kg=new r.a.Shell({region:"#app",layoutService:new r.a.LayoutService({})});kg.addInitializationStep((function(e,t){e.registerLayout(k,yd).registerLayout(O,Ad),t(e)})).addInitializationStep((function(e,t){le.a.registerInstance(os,{size:100}),t(e)})).addInitializationStep((function(e,t){le.a.registerInstance(gs,{dataServiceErrorMessageMappings:{temp:"Error"},defaultErrorMessageKey:"temp"}),t(e)})).addInitializationStep((function(e,t){var n,o,a,s,c=Object(sm.combineReducers)({flightData:i.a.FlightReducer,applicationData:fm,viewModelData:ym}),u=i.a.createMiddleware({fetchData:Vm(e,Km),bootstrappedData:window.bootstrapData||{},defaultExpiryTime:Rs.a.STANDARD}),l=(o=(n={oldVersionError:Tm,authenticationError:Lm}).oldVersionError,a=n.authenticationError,function(e){return function(t){return function(n){var i,s,c=n;if(n.type===mm.Actions.API_ERROR&&a&&(null===(i=null==c?void 0:c.xhr)||void 0===i?void 0:i.status)===Yt.a.Unauthorized)return Qa.c.throw(new a("dark"));if(n.type===mm.Actions.API_RESPONSE){var u=e.getState().applicationData.version,l=null===(s=null==c?void 0:c.xhr)||void 0===s?void 0:s.getResponseHeader("X-App-Version");o&&u&&l&&l!==u&&r.a.ErrorHelper.delayedThrow("old-version-error",new o(u,l,"dark"),18e4),t(n)}else t(n)}}}),f=Object(sm.createStore)(c,Object(sm.applyMiddleware)(u,Fm,l));s=f,e.registerStore(s),t(),delete window.bootstrapData})).addInitializationStep((function(e,t){var n={maxAlerts:3,defaultSuccessAlert:{heading:Yc.a.Success,type:bs.a.Success},defaultErrorAlert:{heading:Yc.a.Fail,type:bs.a.Fail},alertViewCtor:Mc};le.a.registerSingleton(new bs.b(n));var r=le.a.getInstance(ws.a.ALERT),i={cache:Ka.Fifo,dataProvider:as.Ajax,bootstrapData:window.bootstrapData,defaultErrorHandler:r.error({useXHR:!0}),alertService:r};le.a.registerDataService(Kc,i).registerDataService(zs,i).registerDataService(Oc,i);var o={store:e.store};le.a.registerInstance(Zc,o).registerInstance(tu,o).registerInstance(iu,o).registerInstance(au,o);var a={cache:Ka.Fifo,dataProvider:as.Notifications,alertService:r};le.a.registerDataService(ic,a),t(e),delete window.bootstrapData})).addInitializationStep((function(e,t){le.a.registerInstance(am,{imageUrls:xt.a}).registerInstance(Jy).registerInstance(Nh,{store:e.store}).registerInstance(qh,{store:e.store}).registerInstance(ch).registerInstance(If.a).registerInstance(mh);var n=new xd(2),r=function(){n.decrement(),n.getValue()>0||(le.a.releaseInstance(xs.a.Language),le.a.releaseInstance(Jc.a.FlightConfig),t(e))};le.a.getInstance(xs.a.Language).getLanguageConfig((function(e){G.a.setConfig(e),r()})),le.a.getInstance(Jc.a.FlightConfig).getConfig((function(e){le.a.registerInstance(Lh,{endpoint:e.notificationServiceUrl,authEndpoint:"/api/notifications/v1/tokens",hubName:"notification",logging:!0}),r()}))})).addInitializationStep((function(e,t){var n,r,o,a=le.a.getInstance(Jc.a.FlightConfig),s=le.a.getInstance(Jc.a.FlightUser),c=new xd(3),u=function(){c.decrement(),c.getValue()>0||(r.isAuthenticated?p(n.instanceRegion):f())},f=function(){var t=l.a.history.getFragment(ce.LocationUtils.GetCurrentPath()),r=Cg.test(t),o=Eg.test(t);if(r||o){var a="";r?a=l.a.Router.prototype._extractParameters(Cg,t)[0]:o&&(a=l.a.Router.prototype._extractParameters(Eg,t)[0]),a?i.a.hooklessFetch(e.store,Kt.a.getShareObject(a,(function(e){return p(e.ownerInstanceRegion)}),(function(){return p(n.instanceRegion)}))):p(n.instanceRegion)}else p(n.instanceRegion)},p=function(i){var a=new Iv({user:r,config:n});le.a.registerSingleton(a),a.registerTransport(Mv),a.registerClient(vg),a.registerClient(ng.a,{productName:"lite.web",productVersion:o,regionName:i,collectionApiUrls:n.collectionApiUrls,collectionApiClientId:n.collectionApiClientId,getUser:function(){return _g.getUser(e)},shouldLog:gg.a.shouldLog,formatData:Tg.formatData,logError:Sg.logError}),a.registerEnricher(tg,{productName:"ClickView Primary",productVersion:o}),a.registerEnricher(Kv);var s=se.b.get(ue.a.PLUGIN);(null==s?void 0:s.consumerKey)&&a.registerEnricher(ke,{consumerKey:s.consumerKey}),le.a.releaseInstance(Jc.a.FlightConfig),le.a.releaseInstance(Jc.a.FlightUser),t(e)};a.getVersion((function(e){o=e,u()})),a.getConfig((function(e){n=e,u()})),s.getCurrentUser((function(e){r=e,u()}),(function(){u()}))})).addInitializationStep((function(e,t){t(e)})).addInitializationStep((function(e,t){r.a.View.AddViewDataExtension((function(e){return{languageNamespace:Ya.result(e,"lang")}})),t(e)})).addInitializationStep((function(e,t){le.a.registerInstance(nv).registerInstance(dv),t(e)})).addInitializationStep((function(e,t){e.registerErrorHandler(q.a,Iu).registerErrorHandler(_u.a,xu).registerErrorHandler(wu,Pu).registerErrorHandler(At.a,Au).registerErrorHandler(H.a,Iu).registerErrorHandler(Su.a,Iu).registerErrorHandler(Tu.a,Iu).registerErrorHandler(Cu.a,Au).registerErrorHandler(Eu.a,Iu).registerErrorHandler(ku.a,Au).registerErrorHandler(Ou.a,Iu).registerErrorHandler(sn,Ru).registerErrorHandler(zn,Lu),t()})).addInitializationStep((function(e,t){function n(){r.a.ErrorHelper.throw(new H.a)}e.registerApplication(zt).registerApplication(Ho).registerApplication(gi).registerApplication(Vi).registerApplication(Wr).registerApplication(ai).registerApplication(Ai).registerApplication($i).registerApplication(wo).registerApplication(Jo).registerApplication(fa),i.a.hooklessFetch(e.store,o.a.currentUser((function(r){r.isAuthenticated?i.a.hooklessFetch(e.store,o.a.permissions((function(n){if(n[a.a.StudentExperience])return e.registerApplication(ja).registerApplication(Ga),void t(e);e.registerApplication(Pt).registerApplication(co).registerApplication(et).registerApplication(xo).registerApplication(vt).registerApplication(Ta),t(e)}),n)):t(e)}),n))})).addInitializationStep((function(e,t){mv.register(),t(e)})).addInitializationStep((function(e,t){le.a.registerSingleton(new _v({onlineRole:gv.a.Staff,customerType:vv.Primary})),t(e)})),kg.addStartUpStep((function(e,t,n){le.a.getInstance(Jc.a.FlightConfig).getConfig((function(){F.a.setUpVariables({isDevelopment:!1}),n(e,t),le.a.releaseInstance(Jc.a.FlightConfig)}))})),kg.start()},function(e,t){e.exports=v},function(e,t){e.exports=g},function(e,t){e.exports=b},function(e,t){e.exports=w}])}));
|