@viewlift/player-backup 1.0.2 → 1.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cjs/{autoNextVideo-815419cb.js → autoNextVideo-823821e8.js} +1 -1
- package/cjs/bundle.css +266 -186
- package/cjs/{caption-settings-6e301004.js → caption-settings-d42c056e.js} +1 -1
- package/cjs/debugSelection-cbfdabb7.js +1 -0
- package/cjs/features-164c3cc6.js +1 -0
- package/cjs/generic-8b99b151.js +1 -0
- package/cjs/icons-7afb9c13.js +1 -0
- package/cjs/index-3dfe6459.js +1 -0
- package/cjs/index.js +1 -1
- package/cjs/{keyboardShortcuts-1afbf18c.js → keyboardShortcuts-cfd998c2.js} +1 -1
- package/cjs/{multicam-1647c428.js → multicam-21c9a90b.js} +1 -1
- package/cjs/{multicamv2-f48d95fe.js → multicamv2-c148fa24.js} +1 -1
- package/cjs/{mwebPotraitTray-a3a2715b.js → mwebPotraitTray-b9d5d45a.js} +1 -1
- package/cjs/{nextEpisodeButton-cc80609a.js → nextEpisodeButton-300afadc.js} +1 -1
- package/cjs/{playlist-a550a735.js → playlist-925f808b.js} +1 -1
- package/cjs/{renditions-c3ea26e8.js → renditions-bc841552.js} +1 -1
- package/cjs/{resolution-51b38a3e.js → resolution-6a9adf54.js} +1 -1
- package/cjs/{series-6178964e.js → series-82ec79d3.js} +1 -1
- package/cjs/{series-v2-a265ff17.js → series-v2-24855152.js} +1 -1
- package/cjs/{settings-icon-b350b587.js → settings-icon-a63f46fc.js} +1 -1
- package/cjs/skin-095cc078.js +1 -0
- package/cjs/{skin-b703ef26.js → skin-39ab30e2.js} +1 -1
- package/cjs/{skin-9eba464b.js → skin-93a3e5ae.js} +1 -1
- package/cjs/{skin-638aecc2.js → skin-afbec6d7.js} +1 -1
- package/cjs/skin-ec49b877.js +1 -0
- package/cjs/{skin-14da56f6.js → skin-fb394911.js} +1 -1
- package/cjs/{util-ce8a4138.js → util-fa21734a.js} +1 -1
- package/cjs/{videoSelector-a4c00f50.js → videoSelector-01a9ef43.js} +1 -1
- package/esm/{autoNextVideo-89ede579.js → autoNextVideo-1672740e.js} +1 -1
- package/esm/bundle.css +266 -186
- package/esm/{caption-settings-3f6b6163.js → caption-settings-3eacf3a0.js} +1 -1
- package/esm/debugSelection-2601b8b3.js +1 -0
- package/esm/features-f86404ce.js +1 -0
- package/esm/generic-7c43020f.js +1 -0
- package/esm/{icons-f5378bf3.js → icons-c18c70b7.js} +1 -1
- package/esm/index-9f022e82.js +1 -0
- package/esm/index.js +1 -1
- package/esm/{keyboardShortcuts-7fa108ec.js → keyboardShortcuts-c06f3c7b.js} +1 -1
- package/esm/{multicam-bc0aea8a.js → multicam-94da3759.js} +1 -1
- package/esm/{multicamv2-fb91fa98.js → multicamv2-0105c40f.js} +1 -1
- package/esm/{mwebPotraitTray-0ff12233.js → mwebPotraitTray-5ab39989.js} +1 -1
- package/esm/{nextEpisodeButton-ec95417f.js → nextEpisodeButton-2ea69b56.js} +1 -1
- package/esm/{playlist-5d3f4436.js → playlist-032fbbf3.js} +1 -1
- package/esm/{renditions-0fdb57ed.js → renditions-97276745.js} +1 -1
- package/esm/{resolution-57e7767a.js → resolution-38cd4f5c.js} +1 -1
- package/esm/{series-998e2084.js → series-977edced.js} +1 -1
- package/esm/{series-v2-9bcd5d54.js → series-v2-516c91c2.js} +1 -1
- package/esm/{settings-icon-9bac9ef3.js → settings-icon-2b713fbf.js} +1 -1
- package/esm/{skin-851ea2fb.js → skin-42c2f81d.js} +1 -1
- package/esm/{skin-0aea7a56.js → skin-5e2fa9d4.js} +1 -1
- package/esm/{skin-fba79111.js → skin-6093bfb3.js} +1 -1
- package/esm/skin-60a41d44.js +1 -0
- package/esm/{skin-5a02ebe6.js → skin-93e320fc.js} +1 -1
- package/esm/{skin-bb73c15b.js → skin-b939c35e.js} +1 -1
- package/esm/{util-9c9ee6b3.js → util-d9f5a7be.js} +1 -1
- package/esm/{videoSelector-8da87dd3.js → videoSelector-8889c58e.js} +1 -1
- package/package.json +1 -1
- package/cjs/features-fd1e9785.js +0 -1
- package/cjs/generic-81b1be69.js +0 -1
- package/cjs/icons-51594f89.js +0 -1
- package/cjs/skin-286f52db.js +0 -1
- package/cjs/skin-534810ae.js +0 -1
- package/esm/features-05101ce6.js +0 -1
- package/esm/generic-4a3c0d6b.js +0 -1
- package/esm/skin-80957fd8.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("@babel/runtime/helpers/typeof"),t=require("@babel/runtime/helpers/classCallCheck"),n=require("@babel/runtime/helpers/createClass"),a=require("@babel/runtime/helpers/inherits"),o=require("@babel/runtime/helpers/possibleConstructorReturn"),r=require("@babel/runtime/helpers/getPrototypeOf"),i=require("video.js"),c=require("./icons-
|
|
1
|
+
"use strict";var e=require("@babel/runtime/helpers/typeof"),t=require("@babel/runtime/helpers/classCallCheck"),n=require("@babel/runtime/helpers/createClass"),a=require("@babel/runtime/helpers/inherits"),o=require("@babel/runtime/helpers/possibleConstructorReturn"),r=require("@babel/runtime/helpers/getPrototypeOf"),i=require("video.js"),c=require("./icons-7afb9c13.js"),s=require("./generic-8b99b151.js"),l=require("./skin-84083352.js");function d(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,a=r(e);if(t){var i=r(this).constructor;n=Reflect.construct(a,arguments,i)}else n=a.apply(this,arguments);return o(this,n)}}require("@babel/runtime/helpers/defineProperty"),require("axios"),require("js-cookie"),require("ua-parser-js"),require("@babel/runtime/helpers/toConsumableArray");var u=i.getComponent("Component"),p=function(o){a(p,u);var r=d(p);function p(e){var n,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t(this,p),(n=r.call(this,e,a)).playerId=a.playerId,n.seriesData=a.sres,n.currentVideoData=a.res,n.initialiseStructure(),n.loadCSS(),n}return n(p,[{key:"createEl",value:function(){var e=i.dom.createEl("div",{className:"caption-selection vjs-control vjs-button"});e.style.position="unset";var t=i.dom.createEl("div",{className:"caption-selector-icon",innerHTML:"".concat(c.CaptionsSvgV2())});return i.dom.appendContent(e,t),e}},{key:"loadCSS",value:function(){Promise.resolve().then((function(){return require("./caption-settings-67212c17.js")})).then((function(e){var t=document.createElement("style");t.id="video-captions",t.append("".concat(e.default)),document.head.appendChild(t)}))}},{key:"initialiseStructure",value:function(){var e=this,t=s.getCaptions(this.playerId);null==t||t.map((function(t){return s.disableCaptions(e.playerId,t.id)}));var n=this.el(),a=i.dom.createEl("div",{className:"caption-selection-container hidden"});i.dom.$(".caption-selector-icon",this.el()).onclick=function(){var e;null!==(e=a.classList)&&void 0!==e&&e.contains("hidden")?(l.closeOpenDrawers(),a.classList.remove("hidden"),n.classList.add("open"),a.style.right="0px"):(a.classList.add("hidden"),n.classList.remove("open"),a.style.right="-350px")};var o=window.getComputedStyle(document.getElementById(this.playerId),null).getPropertyValue("height").slice(0,-2);a.style.height="".concat(o,"px"),i.dom.appendContent(n,a),document.getElementById(this.playerId).style.overflow="hidden",this.addFunctionality(a)}},{key:"addFunctionality",value:function(e){var t=this,n=this.el(),a=i.dom.createEl("div",{className:"caption-selector-head"}),o=i.dom.createEl("div",{className:"caption-selector-cross-icon",innerHTML:"".concat(c.crossIconSvg())});o.onclick=function(){e.classList.add("hidden"),n.classList.remove("open"),e.style.right="-350px"};var r=i.dom.createEl("div",{className:"caption-selector-title",innerHTML:"Captions"}),l=i.dom.createEl("div",{className:"caption-selector-content"}),d=i.dom.createEl("div",{className:"caption-container"}),u=this.createLanguageContanier();i.dom.appendContent(d,u);var p=this.createFontSizeContainer();i.dom.appendContent(d,p),i.dom.appendContent(a,o),i.dom.appendContent(a,r),i.dom.appendContent(e,a),i.dom.appendContent(e,l),i.dom.appendContent(l,d),s.getPlayer(this.playerId).on("fullscreenchange",(function(){var n=window.getComputedStyle(document.getElementById(t.playerId),null).getPropertyValue("height").slice(0,-2);e.style.height="".concat(n,"px")}))}},{key:"createLanguageContanier",value:function(){var t=this,n=i.dom.createEl("div",{className:"caption-language-container"}),a=i.dom.createEl("div",{className:"caption-language-container-title",innerHTML:"Language"});i.dom.appendContent(n,a);var o=document.createElement("label");o.setAttribute("for","radio-off"),o.className="caption-language-holder";var r=document.createElement("div");r.className="caption",r.innerHTML="Off";var c=i.dom.createEl("input",{className:"radio - off",id:"radio-off",name:"language-radio",checked:"true"});c.setAttribute("type","radio"),c.onchange=function(e){s.getCaptions(t.playerId).map((function(e){return s.disableCaptions(t.playerId,e.id)}))},i.dom.appendContent(o,c),i.dom.appendContent(o,r),i.dom.appendContent(n,o);for(var l=s.getCaptions(this.playerId),d=function(e){var a=document.createElement("label");a.className="caption-language-holder",a.setAttribute("for","language-radio-".concat(e));var o=document.createElement("div");o.className="caption - ".concat(e),o.innerHTML=l[e].label;var r=i.dom.createEl("input",{className:"radio - ".concat(e),id:"language-radio-".concat(e),name:"language-radio"});return r.onchange=function(n){s.enableCaptions(t.playerId,l[e].id)},r.setAttribute("type","radio"),i.dom.appendContent(a,r),i.dom.appendContent(a,o),i.dom.appendContent(n,a),{v:n}},u=0;u<l.length;u++){var p=d(u);if("object"===e(p))return p.v}}},{key:"createFontSizeContainer",value:function(){var e=i.dom.createEl("div",{className:"caption-font-container"}),t=i.dom.createEl("div",{className:"caption-font-container-title",innerHTML:"Font Size"});i.dom.appendContent(e,t);for(var n=[{size:14},{size:18},{size:24}],a=0;a<n.length;a++){var o=document.createElement("label");o.className="caption-font-holder",o.setAttribute("for","font".concat(a));var r=document.createElement("div");r.className="fontsize - ".concat(a),r.innerHTML=n[a].size+"pt";var c=i.dom.createEl("input",{className:"radio - ".concat(a),id:"font".concat(a),name:"font-size-radio",size:"".concat(n[a].size),checked:"".concat(a==n.length-1)});c.setAttribute("type","radio"),c.onchange=function(e){var t=e.target.size;if(document.getElementById("caption-size")){document.getElementById("caption-size").textContent=".vjs-text-track-cue{font-size:".concat(t,"px !important}")}else{var n=document.createElement("style");n.textContent=".vjs-text-track-cue{font-size:".concat(t,"px !important}"),n.id="caption-size",document.head.append(n)}},i.dom.appendContent(o,c),i.dom.appendContent(o,r),i.dom.appendContent(e,o)}return e}}]),p}();exports.default=p;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";exports.default=".debug-selection {\n display: flex;\n align-items: center;\n justify-content: center;\n}\n.debug-selection-icon>svg{\n cursor: pointer;\n}\n.debug-item {\n width: 100%;\n display: flex;\n justify-content: space-between;\n padding: 0.5rem 1.4rem;\n font-size: 0.7rem;\n}\n.debug-item-wrapper {\n width: 100%;\n} \n.debug-title-item {\n font-weight: bold;\n}\n\n.debug-selector-icon {\n cursor: pointer;\n}\n\n.debug-selection-container {\n position: absolute;\n width: 320px;\n bottom: 0px;\n right: -320px;\n background: #00000080 !important;\n z-index: -1;\n transition: right 300ms ease-out;\n}\n\n.debug-container {\n display: flex;\n justify-content: center;\n align-items: center;\n flex-direction: column;\n}\n\n.debug-selection.open {\n background: rgba(255, 255, 255, 0.20) !important;\n}\n\n.debug-selector-head {\n display: flex;\n align-items: center;\n padding-top: 18px;\n padding-left: 20px;\n margin-bottom: 20px;\n}\n\n.debug-selector-title {\n font-size: 18px;\n font-weight: 600;\n margin-left: 25px;\n user-select: none;\n}\n\n.debug-selector-cross-icon {\n cursor: pointer;\n}\n\n.debug-selector-content {\n height: 74%;\n overflow: scroll;\n}\n\n.debug-selector-content::-webkit-scrollbar {\n display: none;\n}\n\n/* Hide scrollbar for IE, Edge and Firefox */\n.debug-selector-content {\n -ms-overflow-style: none;\n /* IE and Edge */\n scrollbar-width: none;\n /* Firefox */\n}\n\n.debug-selector-content-video {\n height: 300px;\n margin-bottom: 30px;\n}\n\n.recommended {\n height: 175px;\n width: 309px;\n background-repeat: no-repeat;\n background-size: contain;\n}\n.related-thumbnail-image{\n width: 100%;\n height: 100%;\n}\n.video {\n display: flex;\n flex-direction: column;\n align-items: center;\n margin-bottom: 12px;\n}\n\n.parent {\n margin: 21px 52px 23px 34px;\n\n}\n\n.recommended:hover {\n cursor: pointer;\n}\n\n.info {\n font-size: 13px;\n padding: 7px 22px;\n}\n\n@media (max-width:600px){\n .debug-selector-cross-icon>svg{\n height: 12px;\n }\n .debug-selector-title{\n font-size: 14px;\n }\n .debug-selector-content{\n height: 52%;\n }\n .debug-selection-container{\n width: 200px;\n }\n .recommended{\n height: 90px !important;\n width: 154px !important;\n }\n .info {\n font-size: 9px !important;\n }\n .debug-selector-title{\n margin-left: 13px;\n }\n}";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";var e=require("@babel/runtime/helpers/defineProperty"),t=require("@babel/runtime/helpers/classCallCheck"),r=require("@babel/runtime/helpers/createClass"),n=require("@babel/runtime/helpers/inherits"),o=require("@babel/runtime/helpers/possibleConstructorReturn"),l=require("@babel/runtime/helpers/getPrototypeOf"),i=require("video.js"),a=require("./generic-8b99b151.js"),s=require("./renditions-bc841552.js");function u(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}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 r,n=l(e);if(t){var i=l(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return o(this,r)}}exports.addCaptionButton=function(e,t){Promise.resolve().then((function(){return require("./caption-settings-d42c056e.js")})).then((function(r){var n,o,l,s,u=r.default,c=a.getPlayer(e);i.registerComponent("captionSelector",u),null===(n=document)||void 0===n||null===(o=n.getElementById(e))||void 0===o||null===(l=o.getElementsByClassName("caption-selection vjs-control vjs-button"))||void 0===l||null===(s=l[0])||void 0===s||s.remove(),c.getChild("controlBar").addChild("captionSelector",{playerId:e,options:t},c.controlBar.children().length-3)}))},exports.addDebugSelector=function(e,t){Promise.resolve().then((function(){return require("./index-3dfe6459.js")})).then((function(r){var n=r.default,o=a.getPlayer(e);i.registerComponent("debugSelector",n),o.getChild("controlBar").addChild("debugSelector",{playerId:e,options:t},o.controlBar.children().length-4)}))},exports.addMulticamSelector=function(e,t){Promise.resolve().then((function(){return require("./multicamv2-c148fa24.js")})).then((function(r){var n=r.default,o=a.getPlayer(e);i.registerComponent("streamSelector",n),o.getChild("controlBar").addChild("streamSelector",{playerId:e,streams:t},o.controlBar.children().length-4)}))},exports.addMulticamView=function(e,t){Promise.resolve().then((function(){return require("./multicam-21c9a90b.js")})).then((function(r){var n=r.default,o=t.streams,l=a.getPlayer(e);i.registerComponent("multicamModule",n),l.getChild("controlBar").addChild("multicamModule",{playerId:e,streams:o,config:t},l.controlBar.children().length)}));var r=document.querySelector(".vjs-control-bar");r&&"live"==(null==t?void 0:t.skin)&&(r.style.background="transparent")},exports.addMwebPotraitTrayModule=function(e,t){Promise.resolve().then((function(){return require("./mwebPotraitTray-b9d5d45a.js")})).then((function(r){var n=r.default,o=a.getPlayer(e);i.registerComponent("mwebPotraitTray",n),o.getChild("controlBar").addChild("mwebPotraitTray",{playerId:e,config:t},0)}))},exports.addNextEpisodeButton=function(e,t,r){Promise.resolve().then((function(){return require("./nextEpisodeButton-300afadc.js")})).then((function(n){var o=n.default,l=a.getPlayer(r);i.registerComponent("nextEpisodeButtonModule",o),l.getChild("controlBar").addChild("nextEpisodeButtonModule",{playerId:r,sres:e,res:t},l.controlBar.children().length-5)}))},exports.addOutputtingOverlay=function(e,t){var r=a.getPlayer(e).el(),n=i.dom.createEl("div",{className:"output-overlay",innerHTML:'<iframe frameBorder="0" src='.concat(t,"></iframe>")});r.append(n)},exports.addPlaylistSelector=function(e,t){Promise.resolve().then((function(){return require("./playlist-925f808b.js")})).then((function(r){var n=r.default,o=a.getPlayer(e);i.registerComponent("playlistSelector",n),o.getChild("controlBar").addChild("playlistSelector",{playerId:e,playlist:t},o.controlBar.children().length-3)}))},exports.addResolutionModule=function(e,t,r){Promise.resolve().then((function(){return require("./resolution-6a9adf54.js")})).then((function(n){var o=n.default;document.getElementById(e).getElementsByClassName("container")[0]&&document.getElementById(e).getElementsByClassName("container")[0].remove();var l=a.getPlayer(e),u=s.getRenditions(e);(null==u?void 0:u.length)>0&&(i.registerComponent("resolutionModule",o),l.getChild("controlBar").addChild("resolutionModule",{playerId:e,skin:t,icon:r,renditions:u},l.controlBar.children().length-4))}))},exports.addRewindButton=function(e,o,l){var s=function(o){n(s,o);var i=c(s);function s(e,r){var n;t(this,s);var o=(n=i.call(this,e,r)).el_;return o.classList.add("vjs-rewind-button"),o.innerHTML=l,n}return r(s,[{key:"handleClick",value:function(){a.rewind(e,10)}}]),s}(i.getComponent("Button"));i.registerComponent("MyButton",s),i(e).getChild("controlBar").addChild("myButton",{},1)},exports.addSeriesModule=function(e,t,r){Promise.resolve().then((function(){return require("./series-82ec79d3.js")})).then((function(n){var o=n.seriesModule,l=a.getPlayer(e);i.registerComponent("seriesModule",o),l.getChild("controlBar").addChild("seriesModule",{playerId:e,seriesData:t},l.controlBar.children().length-4);for(var s=document.querySelectorAll(".season-title-sdk"),u=function(e){s[e].addEventListener("click",(function(){t[e]&&n.handleSeasonChange(t[e],e,l,r)}))},c=0;c<s.length;c++)u(c)}))},exports.addSeriesSelectorV2=function(t,r){Promise.resolve().then((function(){return require("./series-v2-24855152.js")})).then((function(n){var o=n.default,l=a.getPlayer(t);i.registerComponent("seriesV2",o),l.getChild("controlBar").addChild("seriesV2",function(t){for(var r=1;r<arguments.length;r++){var n=null!=arguments[r]?arguments[r]:{};r%2?u(Object(n),!0).forEach((function(r){e(t,r,n[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):u(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}({playerId:t},r),l.controlBar.children().length-3)}))},exports.addSettingsButtonV2=function(e,t){Promise.resolve().then((function(){return require("./settings-icon-a63f46fc.js")})).then((function(r){var n,o,l,s,u=r.default,c=a.getPlayer(e);i.registerComponent("settingsSelector",u),null===(n=document)||void 0===n||null===(o=n.getElementById(e))||void 0===o||null===(l=o.getElementsByClassName("settings-selection vjs-control vjs-button"))||void 0===l||null===(s=l[0])||void 0===s||s.remove(),c.getChild("controlBar").addChild("settingsSelector",{playerId:e,options:t},c.controlBar.children().length-3)}))},exports.addSkipButton=function(e,o,l){var s=function(o){n(s,o);var i=c(s);function s(e,r){var n;t(this,s);var o=(n=i.call(this,e,r)).el_;return o.classList.add("vjs-skip-button"),o.innerHTML=l,n}return r(s,[{key:"handleClick",value:function(){a.skip(e,10)}}]),s}(i.getComponent("Button"));i.registerComponent("MyButton",s),i(e).getChild("controlBar").addChild("myButton",{},1)},exports.addSlowMotion=function(e){var o=function(e){n(i,e);var o=c(i);function i(e,r){var n;t(this,i);var l=(n=o.call(this,e,r)).el_;return l.classList.add("vjs-slowmo-button"),l.innerHTML="Slow Mo",n}return r(i,[{key:"handleClick",value:function(){1==l.playbackRate()?(l.playbackRate(.5),this.el().style.background="darkgray"):(l.playbackRate(1),this.el().style.background="none")}}]),i}(i.getComponent("Button"));i.registerComponent("MyButton",o);var l=i(e);l.getChild("controlBar").addChild("myButton",{},2)},exports.addVideoSelector=function(e,t){Promise.resolve().then((function(){return require("./videoSelector-01a9ef43.js")})).then((function(r){var n=r.default,o=a.getPlayer(e);i.registerComponent("videoSelector",n),o.getChild("controlBar").addChild("videoSelector",{playerId:e,related:t},o.controlBar.children().length-3)}))};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";var e=require("@babel/runtime/helpers/defineProperty"),t=require("video.js"),n=require("axios");require("js-cookie");var o=require("ua-parser-js"),i={apiBaseUrl:"https://prod-api.viewlift.com",getVideoDetails:"/entitlement/video/status",getSeriesDetails:"/entitlement/series/status",saveWatchHistoryV1:"/user/userId/history/video",saveWatchHistoryV2:"/v2/user/history",getVideoInfoV1:"/user/info/video",getVideoInfoV2:"/v2/user/info",getSeriesWatchHistoryV1:"/user/userId/history/video",getSeriesWatchHistoryV2:"/v2/user/history/series"};function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,o)}return n}function a(t){for(var n=1;n<arguments.length;n++){var o=null!=arguments[n]?arguments[n]:{};n%2?r(Object(o),!0).forEach((function(n){e(t,n,o[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):r(Object(o)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(o,e))}))}return t}var l=function(e,t){var o,i;return n({url:I(),params:a({id:e,deviceType:"web_browser",contentConsumption:"web"},null===(o=window)||void 0===o||null===(i=o.customData)||void 0===i?void 0:i.entitlement),method:"GET",headers:{Authorization:t},withCredentials:!0})},s=function(e,t){var o,i,r=(null===(o=window)||void 0===o||null===(i=o.watchHistory)||void 0===i?void 0:i.apiVersion)||"v1";if("v1"==r){var a,l,s=JSON.parse(atob(t.split(".")[1])),d=(null==s?void 0:s.site)||null;return n({method:"GET",url:c(e),params:{site:d},headers:{Authorization:t,"x-api-key":null===(a=window)||void 0===a||null===(l=a.watchHistory)||void 0===l?void 0:l.xApiKey}})}if("v2"==r){var u,m;JSON.parse(atob(t.split(".")[1]));var p=window.contentType;return n({method:"GET",url:v(e,p),headers:{Authorization:t,"x-api-key":null===(u=window)||void 0===u||null===(m=u.watchHistory)||void 0===m?void 0:m.xApiKey}})}},d=function(e){return g()+"".concat(null==i?void 0:i.getSeriesWatchHistoryV2,"/").concat(e)},u=function(){return g()+"".concat(null==i?void 0:i.getSeriesWatchHistoryV1)},c=function(e){return g()+"".concat(null==i?void 0:i.getVideoInfoV1,"/").concat(e)},v=function(e,t){return g()+"".concat(null==i?void 0:i.getVideoInfoV2,"/").concat(t,"/").concat(e)},m=function(){return g()+"".concat(null==i?void 0:i.saveWatchHistoryV1)},p=function(){return g()+"".concat(null==i?void 0:i.saveWatchHistoryV2)},I=function(){return g()+"".concat(null==i?void 0:i.getVideoDetails)},g=function(){var e;return(null===(e=window)||void 0===e?void 0:e.playerEntitlementUrl)||(null==i?void 0:i.apiBaseUrl)},f=function(e,t){if(Promise.resolve().then((function(){return require("./error-26d5a3c3.js")})).then((function(e){var t=document.createElement("style");t.id="errorblock",t.append("".concat(e.default)),document.head.appendChild(t)})),document.getElementsByClassName("error-container")[0]){var n=document.getElementsByClassName("error-message")[0];n&&(n.innerHTML="".concat(t))}else{var o=document.getElementById(e),i=document.createElement("div");i.className="error-container";var r=document.createElement("div");r.className="error-message",r.innerHTML="".concat(t),i.appendChild(r),o.append(i)}},E=function(){document.getElementsByClassName("error-container")[0]&&document.getElementsByClassName("error-container")[0].remove()};var T=function(){var e,t,n,o;return null!==(e=window)&&void 0!==e&&null!==(t=e.customData)&&void 0!==t&&t.onlyPlayReadyDRM||navigator.userAgent.indexOf("Edg")>-1&&"macOS"!=(null===(n=window.navigator)||void 0===n||null===(o=n.userAgentData)||void 0===o?void 0:o.platform)?"IE":-1!=(navigator.userAgent.indexOf("Opera")||navigator.userAgent.indexOf("OPR"))?"Opera":-1!=navigator.userAgent.indexOf("Chrome")?"Chrome":-1!=navigator.userAgent.indexOf("Safari")?"Safari":-1!=navigator.userAgent.indexOf("Firefox")?"Firefox":"Unknown"};function y(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,o)}return n}function w(t){for(var n=1;n<arguments.length;n++){var o=null!=arguments[n]?arguments[n]:{};n%2?y(Object(o),!0).forEach((function(n){e(t,n,o[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):y(Object(o)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(o,e))}))}return t}window._deviceInfo=o(navigator.userAgent);var h=function(e,t){return e&&t?"".concat(e,"x").concat(t):e>1024?"L":e>768?"M":"S"},O=function(e){var t=_(e,"video.tags",[]),n=_(e,"video.gist.primaryCategory.title","VIEWLIFT_CONTENT_GENRE");return t.length>0?t.map((function(e){return e.title})).join(","):n},_=function(e,t,n){for(var o=0,i=(t=t.split(".")).length;o<i;o++){var r;e=null===(r=e)||void 0===r?void 0:r[t[o]]}return e||n},D=function(){return!!/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)},b=function(){var e,t,n,o,i,r,a,l,s,d,u,c,v=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",m=arguments.length>1?arguments[1]:void 0,p=arguments.length>2?arguments[2]:void 0,I=null==p||null===(e=p.video)||void 0===e?void 0:e.metadata,g=J(m);if(!v.includes("VIEWLIFT_"))return v;var f=window.getComputedStyle(document.getElementById(m),null),E=Math.trunc(f.getPropertyValue("height").slice(0,-2)),T=Math.trunc(f.getPropertyValue("width").slice(0,-2)),y=_(p,"video.gist.id",""),D=w(w({},V(I)),{},{VIEWLIFT_WIDTH:T,VIEWLIFT_HEIGHT:E,VIEWLIFT_SIZE:h(T,E),VIEWLIFT_DOMAIN:window.location.hostname,VIEWLIFT_URL:window.location.href,VIEWLIFT_ENCODED_URL:encodeURIComponent(window.location.href),VIEWLIFT_DOUBLE_ENCODED_URL:encodeURIComponent(encodeURIComponent(window.location.href)),VIEWLIFT_CACHEBUSTER:"3708662946268",VIEWLIFT_TIMESTAMP:Date.now().toString().substring(0,10),VIEWLIFT_TIMESTAMP_MS:Date.now().toString(),VIEWLIFT_IP:(null===(t=window)||void 0===t?void 0:t.ip)||"VIEWLIFT_IP",VIEWLIFT_USER_AGENT:navigator.userAgent,VIEWLIFT_DNT:"1"===navigator.doNotTrack?"1":"0",VIEWLIFT_DESCRIPTION:_(p,"video.gist.description","VIEWLIFT_DESCRIPTION"),VIEWLIFT_DURATION:_(p,"video.gist.runtime","VIEWLIFT_DURATION"),VIEWLIFT_MIN_DURATION:0,VIEWLIFT_MAX_DURATION:_(p,"video.gist.runtime","VIEWLIFT_DURATION"),VIEWLIFT_AUTOPLAY:(null==g||null===(n=g.options_)||void 0===n?void 0:n.autoplay)||1,VIEWLIFT_MUTE:(null==g||null===(o=g.options_)||void 0===o?void 0:o.autoplay)||0,VIEWLIFT_DEVICE_ID:localStorage.getItem("deviceId")||"VIEWLIFT_DEVICE_ID",VIEWLIFT_KEYWORDS:O(p),VIEWLIFT_MEDIA_ID:y,VIEWLIFT_ENCODED_VIDEO_TITLE:encodeURI(_(p,"video.gist.title","VIEWLIFT_ENCODED_VIDEO_TITLE")),VIEWLIFT_VIDEO_ID:y,VIEWLIFT_VIDEO_URL:encodeURI(window.location.host+_(p,"video.gist.permalink","")),VIEWLIFT_COPPA:_(null===(i=window)||void 0===i||null===(r=i.app_data)||void 0===r||null===(a=r.site)||void 0===a?void 0:a.settings,"compliance.coppa")?1:0,VIEWLIFT_GDPR:_(null===(l=window)||void 0===l||null===(s=l.app_data)||void 0===s||null===(d=s.site)||void 0===d?void 0:d.settings,"compliance.gdpr")?1:0,VIEWLIFT_CONTENT_DURATION_MS:1e3*_(p,"video.gist.runtime","VIEWLIFT_DURATION"),VIEWLIFT_CONTENT_DURATION:_(p,"video.gist.runtime","VIEWLIFT_DURATION"),VIEWLIFT_CONTENT_ID:y,VIEWLIFT_CONTENT_TITLE:_(p,"video.gist.title","VIEWLIFT_ENCODED_VIDEO_TITLE"),VIEWLIFT_CONTENT_SERIES_TITLE:_(p,"video.series[0].gist.title",_(p,"seriesInfo.title","VIEWLIFT_CONTENT_SERIES_TITLE")),VIEWLIFT_CONTENT_EPISODE:_(p,"video.currentEpisode","VIEWLIFT_CONTENT_EPISODE"),VIEWLIFT_CONTENT_SEASON:_(p,"video.currentSeason","VIEWLIFT_CONTENT_SEASON"),VIEWLIFT_CONTENT_GENRE:_(p,"video.gist.primaryCategory.title","VIEWLIFT_CONTENT_GENRE"),VIEWLIFT_USER:sessionStorage.getItem("uid")||"VIEWLIFT_USER"},null===(u=window)||void 0===u||null===(c=u.customData)||void 0===c?void 0:c.macros);for(var b in D){var S=new RegExp("\\b("+b+")\\b","g");v=v.replace(S,D[b])}return v},V=function(e){var t,n,o,i,r,a,l={},s=new Map;(null==e?void 0:e.length)>0&&(null==e||e.map((function(e){s.set(e.name,e.value)})));var d=(null===(t=window)||void 0===t||null===(n=t.customData)||void 0===n||null===(o=n.subscription)||void 0===o?void 0:o.SVOD)||!1,u=(null===(i=window)||void 0===i||null===(r=i.customData)||void 0===r||null===(a=r.subscription)||void 0===a?void 0:a.TVE)||!1;return d||u?(D()?d?l=w(w({},l),{},{VIEWLIFT_CSID:s.get("csid.mweb.dtc")||""}):u&&(l=w(w({},l),{},{VIEWLIFT_CSID:s.get("csid.mweb.tve")||""})):d?l=w(w({},l),{},{VIEWLIFT_CSID:s.get("csid.web.dtc")||""}):u&&(l=w(w({},l),{},{VIEWLIFT_CSID:s.get("csid.web.tve")||""})),d?l=w(w({},l),{},{VIEWLIFT_SFID:s.get("sfid.dtc")||""}):u&&(l=w(w({},l),{},{VIEWLIFT_SFID:s.get("sfid.tve")||""})),l=D()?w(w({},l),{},{VIEWLIFT_PROF:s.get("prof.mweb")||""}):w(w({},l),{},{VIEWLIFT_PROF:s.get("prof.web")||""})):(l=w(w({},l),{},{VIEWLIFT_SFID:s.get("sfid.dtc")||""}),l=D()?w(w({},l),{},{VIEWLIFT_CSID:s.get("csid.mweb.dtc")||""}):w(w({},l),{},{VIEWLIFT_CSID:s.get("csid.web.dtc")||""})),l};function S(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,o)}return n}function L(t){for(var n=1;n<arguments.length;n++){var o=null!=arguments[n]?arguments[n]:{};n%2?S(Object(o),!0).forEach((function(n){e(t,n,o[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):S(Object(o)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(o,e))}))}return t}var C,W,x,P,A,F=function(e,t){var n,o,i,r,a,l,s,d,u,c,v,m=null==e||null===(n=e.video)||void 0===n?void 0:n.drmEnabled,p=null==e||null===(o=e.video)||void 0===o||null===(i=o.streamingInfo)||void 0===i?void 0:i.videoAssets,I=(null==e||null===(r=e.video)||void 0===r||null===(a=r.streamingInfo)||void 0===a||null===(l=a.videoAssets)||void 0===l?void 0:l.hls)||!1,g=(null==e||null===(s=e.video)||void 0===s||null===(d=s.streamingInfo)||void 0===d||null===(u=d.videoAssets)||void 0===u?void 0:u.dash)||!1,f=(null==e||null===(c=e.video)||void 0===c||null===(v=c.liveDetails)||void 0===v?void 0:v.isDvrEnabled)||!1;if(m){var E=k(p,t);return E.src=b(E.src,t,e),f&&(E=L(L({},E),{},{src:N(L(L({},e.video),{},{src:"".concat(E.src)}))})),E}if("Safari"!==T()&&g)return R(p);if(I){var y=j(p);return y.src=b(y.src,t,e),f&&(y=L(L({},y),{},{src:N(L(L({},e.video),{},{src:"".concat(y.src)}))})),y}if(null!=p&&p.mpeg){var w=function(e){var t=null==e?void 0:e.mpeg;return{src:t[t.length-1].url,type:"video/mp4"}}(p);return w.src=b(w.src,t,e),w}return null},R=function(e){var t=null==e?void 0:e.dash;return t?{src:t,type:"application/dash+xml"}:null},N=function(e){var t=e.src;if(e.liveDetails.startOverTime){var n=e.liveDetails.startOverTime,o=e.gist.scheduleStartDate,i=e.gist.scheduleEndDate,r=new Date,a=0,l=r.getTime();a=l-o<1e3*n?l-o:1e3*n;var s=null;i<=l&&null!=i&&(s=new Date(i)),r.setMilliseconds(r.getMilliseconds()-a),t=t.includes("?")?i&&s?"".concat(e.src,"&start=").concat(r.toISOString(),"&end=").concat(s.toISOString()):"".concat(e.src,"&start=").concat(r.toISOString()):i&&s?"".concat(e.src,"?start=").concat(r.toISOString(),"&end=").concat(s.toISOString()):"".concat(e.src,"?start=").concat(r.toISOString())}return t},j=function(e){var t=null==e?void 0:e.hls;return t?{src:t,type:"application/x-mpegURL"}:null},k=function(e,n){var o=e.fairPlay,i=e.widevine,r=e.playReady,a=T(),l=J(n);if("Safari"===a){var s=function(e){var n=e.url;return{src:n,type:"application/x-mpegURL",keySystems:{"com.apple.fps.1_0":{getCertificate:function(n,o){var i={uri:e.certificateUrl,method:"GET",responseType:"arraybuffer"};t.xhr(i,(function(e,t,n){console.log(e),e&&o(e),o(null,new Uint8Array(n))}))},getContentId:function(e,t){if(t)return new TextDecoder("utf-16").decode(t.slice(16))},getLicense:function(n,o,i,r){var a={uri:e.licenseUrl,method:"POST",responseType:"arraybuffer",body:i,headers:{"Content-type":"application/octet-stream","X-AxDRM-Message":e&&e.licenseToken}};t.xhr(a,(function(e,t,n){console.log(e),e&&r(e),r(null,n)}))}}}}}(o);try{l.eme()}catch(e){}return s}if("Chrome"===a||"Firefox"===a){var d={src:i.url,type:"application/dash+xml",keySystemOptions:[]};return d.keySystemOptions.push({name:"com.widevine.alpha",options:{serverURL:i.licenseUrl,httpRequestHeaders:{"X-AxDRM-Message":i.licenseToken},videoRobustness:"SW_SECURE_CRYPTO",audioRobustness:"SW_SECURE_CRYPTO"}}),d}if("IE"===a){var u={src:r.url,type:"application/dash+xml",keySystemOptions:[]};return u.keySystemOptions.push({name:"com.microsoft.playready",options:{serverURL:r.licenseUrl,httpRequestHeaders:{"X-AxDRM-Message":r.licenseToken},videoRobustness:"SW_SECURE_CRYPTO",audioRobustness:"SW_SECURE_CRYPTO"}}),u}};var B=function(e){W=e},U=function(e){x=e},M=function(e){if(P){var t=P.get(e);U(t+1)}},H=function(e,t){var n=J(e);n.remoteTextTracks().tracks_.map((function(e){n.removeRemoteTextTrack(e)})),t.map((function(e){n.addRemoteTextTrack({src:e.url,srcLang:e.language,label:e.language})}))},z=!1,G=function(e,t,n){var o=b(t,e,n),i=J(e);t&&window.google&&(i.ima.initializeAdDisplayContainer&&i.ima.initializeAdDisplayContainer(),function(e,t){var n,o,i,r=J(e);if(null!==r.el_){z=!0;var a={id:e,adTagUrl:"".concat(t,"&vid=").concat(window.videoId,"&url=").concat(window.location.href,"&correlator=").concat((new Date).getTime(),"&cust_params=sd%3D60000%26site%3D").concat(window.location.origin,"%26autostart%3D%26mute%3D%26user_agent%3D%26keyword%3D%26category%3D").concat(window.category,"%26vid%3D").concat(window.videoId),adLabel:"Your video will resume after this sponsor message"};r.ima.initializeAdDisplayContainer&&r.ima.initializeAdDisplayContainer(),z&&null!==r.el_&&("function"==typeof r.ima?r.ima(a):setTimeout((function(){r.ima.setContentWithAdTag(null,t,!0),r.ima.requestAds()}),1e3));var l=document.getElementById("".concat(e));(navigator.userAgent.match(/iPad/i)||navigator.userAgent.match(/Android/i))&&l.hasAttribute("controls")&&l.removeAttribute("controls");var s="click",d=!1;(navigator.userAgent.match(/iPhone/i)||navigator.userAgent.match(/iPad/i)||navigator.userAgent.match(/Android/i))&&(d=!0,s="touchend"),r.one(s,(function(){d&&r.ima.initializeAdDisplayContainer()}));var u=(null===(n=window)||void 0===n||null===(o=n.customData)||void 0===o||null===(i=o.ads)||void 0===i?void 0:i.adEventHandler)||null;r.one("ads-ad-started",(function(){u&&u({status:"STARTED",msg:"Advertisement Started"})})),r.one("ads-manager",(function(e){e.adsManager.addEventListener(google.ima.AdEvent.Type.COMPLETE,(function(){u&&u({status:"ENDED",msg:"Advertisement Ended"})}))})),r.on("adserror",(function(e){u&&u({status:"ERROR",msg:"Advertisement Error"})}))}}(e,o))};function q(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,o)}return n}var Y=function(e){return!!t.getPlayer("".concat(e))},J=function(e){return!!t.getPlayer("".concat(e))&&t.getPlayer("".concat(e))},K=function(){document.getElementById("carousel_homepage")&&document.getElementById("carousel_homepage").remove(),document.getElementById("dvr_skin")&&document.getElementById("dvr_skin").remove(),document.getElementById("nondvr_skin")&&document.getElementById("nondvr_skin").remove(),document.getElementById("multicam")&&document.getElementById("multicam").remove(),document.getElementById("errorblock")&&document.getElementById("errorblock").remove(),document.getElementById("def_skin")&&document.getElementById("def_skin").remove(),document.getElementById("video-selection")&&document.getElementById("video-selection").remove(),document.getElementById("multicam-v2")&&document.getElementById("multicam-v2").remove(),document.getElementById("default_v2")&&document.getElementById("default_v2").remove(),document.getElementById("video-captions")&&document.getElementById("video-captions").remove(),document.getElementById("playlist-selection")&&document.getElementById("playlist-selection").remove(),document.getElementById("multiplayer_css")&&document.getElementById("multiplayer_css").remove()},X=function(e,t){J(e).src(t)},Z=function(t,n,o,i){var r,a,l,s,d,u,c=null==t||null===(r=t.response)||void 0===r||null===(a=r.data)||void 0===a?void 0:a.errorCode,v=(null==t||null===(l=t.response)||void 0===l||null===(s=l.data)||void 0===s?void 0:s.errorMessage)||(null==t?void 0:t.message);Y(n)&&f(n,(null===(d=window)||void 0===d?void 0:d.customErrors)&&(null===(u=window)||void 0===u?void 0:u.customErrors[c])||"".concat(v)),o&&o(function(t){for(var n=1;n<arguments.length;n++){var o=null!=arguments[n]?arguments[n]:{};n%2?q(Object(o),!0).forEach((function(n){e(t,n,o[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):q(Object(o)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(o,e))}))}return t}({status:!1,response:t,msg:"".concat(v)},i&&{videoId:i}))};exports.addCaptions=H,exports.clearError=E,exports.createIdxMapping=function(e){P=new Map,e.map((function(e,t){P.set(e.id,t)}))},exports.detectBrowser=T,exports.disableCaptions=function(e,t){for(var n=J(e).textTracks(),o=0;o<n.length;o++){var i=n[o];"subtitles"===i.kind&&i.id===t&&(i.mode="hidden")}},exports.disableControls=function(e){var t=document.getElementById(e),n=t.getElementsByClassName("vjs-control-bar")[0];n&&(n.style.visibility="hidden");var o=t.getElementsByClassName("vjs-big-play-button")[0];o&&(o.style.display="none");var i=t.getElementsByClassName("vjs-fullscreen-control")[0];i&&(i.style.display="none")},exports.dispose=function(e){var t=J(e);if(K(),window.onresize=null,t)t.dispose();else{var n=document.getElementById(e);n&&n.remove()}},exports.enableCaptions=function(e,t){for(var n=J(e).textTracks(),o=0;o<n.length;o++){var i=n[o];"subtitles"===i.kind&&i.id==t&&(i.mode="showing")}},exports.getCaptions=function(e){var t,n=J(e);return(null==n||null===(t=n.textTracks())||void 0===t?void 0:t.tracks_.filter((function(e){return"subtitles"==e.kind})))||[]},exports.getCurrentSeries=function(){return C},exports.getCurrentVideo=function(){return W},exports.getPlayer=J,exports.getSeriesDetails=function(e,t){var o,i,r=JSON.parse(atob(t.split(".")[1])),a=(null==r?void 0:r.site)||null;return r&&r.countryCode,null!==(o=window)&&void 0!==o&&null!==(i=o.customData)&&void 0!==i&&i.seriesData?new Promise((function(e,t){var n,o;return e({data:null===(n=window)||void 0===n||null===(o=n.customData)||void 0===o?void 0:o.seriesData})})):n({url:g()+"/v3/content/series/".concat(e),params:{site:a},method:"GET",headers:{Authorization:t}})},exports.getSeriesWatchHistory=function(e){var t,o;if("v1"==((null===(t=window)||void 0===t||null===(o=t.watchHistory)||void 0===o?void 0:o.apiVersion)||"v1"))return n({method:"GET",url:u(),params:{site:null==e?void 0:e.siteOwner,version:"v2",seriesId:e.videoId},headers:{Authorization:e.token}});var i=e.videoId;return n({method:"GET",url:d(i),headers:{Authorization:e.token}})},exports.getSeriesWatchMap=function(){return A},exports.getSource=F,exports.getVideoDetails=l,exports.getVideoIdx=function(){return x},exports.getVideoInfo=s,exports.handleError=f,exports.initialiseAdvertisement=G,exports.initiateErrorHandling=Z,exports.isPaused=function(e){return t(e).paused()},exports.isPlayerInitialised=Y,exports.isTokenExpired=function(e){var t=JSON.parse(atob(null==e?void 0:e.split(".")[1])),n=null==t?void 0:t.exp;if(new Date(1e3*n).getTime()<(new Date).getTime())return!0},exports.load=function(e,t,n){var o,i,r;M(t);var a=0,d=0;return null!==(o=window)&&void 0!==o&&o.watchHistory&&null!==(i=window)&&void 0!==i&&null!==(r=i.watchHistory)&&void 0!==r&&r.enable&&s(t,n).then((function(e){var t,n,o,i,r,l;null!==(t=window)&&void 0!==t&&null!==(n=t.watchHistory)&&void 0!==n&&n.cb&&(null===(o=window)||void 0===o||null===(i=o.watchHistory)||void 0===i||i.cb(null==e?void 0:e.data)),a=(null==e||null===(r=e.data)||void 0===r?void 0:r.watchedTime)||null,d=(null==e||null===(l=e.data)||void 0===l?void 0:l.watchedPercentage)||null})).catch((function(e){var t,n,o,i;null!==(t=window)&&void 0!==t&&null!==(n=t.watchHistory)&&void 0!==n&&n.cb&&(null===(o=window)||void 0===o||null===(i=o.watchHistory)||void 0===i||i.cb(e))})),new Promise((function(o,i){l(t,n).then((function(t){var n,r,l,s,u,c,v,m,p,I,g=null==t?void 0:t.data,T=(null==g||null===(n=g.video)||void 0===n||null===(r=n.streamingInfo)||void 0===r?void 0:r.isLiveStream)||!1;B(t.data);var y=(null==g||null===(l=g.ads)||void 0===l||null===(s=l.preRoll)||void 0===s||null===(u=s.adTags)||void 0===u||null===(c=u.web)||void 0===c?void 0:c.active)&&(null==g||null===(v=g.ads)||void 0===v||null===(m=v.preRoll)||void 0===m||null===(p=m.adTags)||void 0===p||null===(I=p.web)||void 0===I?void 0:I.url);y&&G(e,y,g);var w=F(g,e);if(w){var h,O,_,D,b,V,S,L,C,W,x,P=null==g||null===(h=g.video)||void 0===h||null===(O=h.gist)||void 0===O?void 0:O.videoImageUrl,A=J(e);if(A.poster(P),X(e,w),A.on("loadstart",(function(){T&&o({status:!0,msg:"Video Loaded",response:g})})),A.on("loadeddata",(function(){E(),o({status:!0,msg:"Video Loaded",response:g})})),A.one("play",(function(){a&&d<95&&setTimeout((function(){A.currentTime(a)}),0)})),A.one("error",(function(){var e;i({status:!1,msg:(null==A||null===(e=A.error())||void 0===e?void 0:e.message)||"Some error occured"})})),(null==g||null===(_=g.video)||void 0===_||null===(D=_.contentDetails)||void 0===D||null===(b=D.closedCaptions)||void 0===b?void 0:b.length)>0||(null==g||null===(V=g.video)||void 0===V||null===(S=V.closedCaptions)||void 0===S?void 0:S.length)>0)L=((null==g||null===(C=g.video)||void 0===C||null===(W=C.contentDetails)||void 0===W?void 0:W.closedCaptions)||(null==g||null===(x=g.video)||void 0===x?void 0:x.closedCaptions)).filter((function(e){return"VTT"===e.format})),H(e,L);else!function(e){var t=J(e);t.remoteTextTracks().tracks_.map((function(e){null==e||e.kind,t.removeRemoteTextTrack(e)}))}(e)}else f(e,"Incompatible Source, only hls,mp4,drm content is allowed"),i("Incompatible Source, only hls,mp4,drm content is allowed")})).catch((function(n){Z(n,e,i,t)}))}))},exports.loadVideo=X,exports.loadVideoInstantly=function(e,t,n){var o=J(e);return o.src(t),new Promise((function(e,t){var i=0;o.on("loadedmetadata",(function(){clearTimeout(i),e({status:!0,msg:"video loaded"})})),o.on("loadstart",(function(e){i=setTimeout((function(){t("FAILED: Took too long to load")}),n)}))}))},exports.pause=function(e){t(e).pause()},exports.play=function(e){t(e).play()},exports.rewind=function(e,n){var o=t(e),i=o.currentTime(),r=i<=n?0:i-n;o.currentTime(r)},exports.saveWatchHistory=function(e,t,o){if("v1"==o){var i={siteOwner:null==e?void 0:e.siteOwner,userId:null==e?void 0:e.userId,videoId:null==e?void 0:e.videoId,watchedPercentage:null==e?void 0:e.watchedPercentage,watchedTime:null==e?void 0:e.watchedTime};return n({url:m(),method:"POST",headers:{Authorization:t,"x-api-key":e.xApiKey},params:{version:"v2"},data:JSON.stringify(i),withCredentials:!0})}if("v2"==o){var r=a({doneWatching:null==e?void 0:e.doneWatching,videoId:null==e?void 0:e.videoId,watchedPercentage:null==e?void 0:e.watchedPercentage,watchedTime:null==e?void 0:e.watchedTime},(null==e?void 0:e.seriesId)&&{seriesId:e.seriesId});return n({url:p(),method:"POST",headers:{Authorization:t},data:r,params:a({},(null==e?void 0:e.profileId)&&{profileId:null==e?void 0:e.profileId})})}},exports.setCurrentSeries=function(e){C=e},exports.setCurrentVideo=B,exports.setSeriesWatchMap=function(e){A=e},exports.setVideoIdx=U,exports.setVideoIdxById=M,exports.skip=function(e,n){var o=t(e),i=o.currentTime()+n;o.currentTime(i)};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";exports.BackIcon=function(){return'<svg width="11" height="20" viewBox="0 0 11 20" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path fill-rule="evenodd" clip-rule="evenodd" d="M10.6169 0.418212C11.0883 0.933084 11.1247 1.74341 10.726 2.30391L10.6173 2.43852L3.69866 10.0029L10.6169 17.5611C11.0883 18.0759 11.1247 18.8863 10.726 19.4468L10.6173 19.5814C10.1461 20.0965 9.40458 20.1362 8.89165 19.7006L8.76847 19.5818L0 10.0039L8.76809 0.418626C9.27852 -0.13938 10.1063 -0.139565 10.6169 0.418212Z" fill="white"/>\n </svg>\n '},exports.BroadcastIcon=function(){return'<svg width="22" height="20" viewBox="0 0 22 20" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path fill-rule="evenodd" clip-rule="evenodd" d="M3.01316 12.1667L0.25 10.5V15.5L3.01316 14.25V18H15.25V8H3.01316V12.1667ZM7.67057 10.7216C7.53806 10.6283 7.35547 10.7231 7.35547 10.8852V15.1146C7.35547 15.2766 7.53806 15.3714 7.67057 15.2781L10.6757 13.1634C10.7889 13.0838 10.7889 12.916 10.6757 12.8363L7.67057 10.7216Z" fill="white"/>\n <path fill-rule="evenodd" clip-rule="evenodd" d="M7.25 2H20.25H21.25V3V10H20.25V3H7.25V2ZM17.25 5H4.25V6H17.25V13H18.25V6V5H17.25Z" fill="white"/>\n </svg>\n '},exports.CaptionsSvgV2=function(){return'<svg width="21" height="18" viewBox="0 0 21 18" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path fill-rule="evenodd" clip-rule="evenodd" d="M20.4541 15.8369V2H0.454102V15.8369H11.992L17.7874 18V15.8369H20.4541ZM2.4541 4H18.4541V13.8614H15.9182L15.9179 15L11.9664 13.8614H2.4541V4Z" fill="white"/>\n <rect x="3.4541" y="6" width="9" height="2" fill="white"/>\n <rect x="14.4541" y="6" width="3" height="2" fill="white"/>\n <rect x="8.4541" y="10" width="9" height="2" fill="white"/>\n <rect x="3.4541" y="10" width="3" height="2" fill="white"/>\n </svg>\n '},exports.DebugSvg=function(){return'<svg width="20" height="20" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" fill="#ffffff"><path d="M3.463 12.86l-.005-.07.005.07zm7.264.69l-3.034-3.049 1.014-1.014 3.209 3.225 3.163-3.163 1.014 1.014-3.034 3.034 3.034 3.05-1.014 1.014-3.209-3.225L8.707 17.6l-1.014-1.014 3.034-3.034z"/><path fill-rule="evenodd" clip-rule="evenodd" d="M16.933 5.003V6h1.345l2.843-2.842 1.014 1.014-2.692 2.691.033.085a13.75 13.75 0 0 1 .885 4.912c0 .335-.011.667-.034.995l-.005.075h3.54v1.434h-3.72l-.01.058c-.303 1.653-.891 3.16-1.692 4.429l-.06.094 3.423 3.44-1.017 1.012-3.274-3.29-.099.11c-1.479 1.654-3.395 2.646-5.483 2.646-2.12 0-4.063-1.023-5.552-2.723l-.098-.113-3.209 3.208-1.014-1.014 3.366-3.365-.059-.095c-.772-1.25-1.34-2.725-1.636-4.34l-.01-.057H0V12.93h3.538l-.005-.075a14.23 14.23 0 0 1-.034-.995c0-1.743.31-3.39.863-4.854l.032-.084-2.762-2.776L2.65 3.135 5.5 6h1.427v-.997a5.003 5.003 0 0 1 10.006 0zm-8.572 0V6H15.5v-.997a3.569 3.569 0 0 0-7.138 0zm9.8 2.522l-.034-.09H5.733l-.034.09a12.328 12.328 0 0 0-.766 4.335c0 2.76.862 5.201 2.184 6.92 1.32 1.716 3.036 2.649 4.813 2.649 1.777 0 3.492-.933 4.813-2.65 1.322-1.718 2.184-4.16 2.184-6.919 0-1.574-.28-3.044-.766-4.335z"/></svg>'},exports.EpisodesSvg=function(){return'<svg class=\'icon icon-episodes\' width="20" height="20" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path d="M1 11.7368C1 11.3299 1.32989 11 1.73684 11H16.2632C16.6701 11 17 11.3299 17 11.7368V21.2632C17 21.6701 16.6701 22 16.2632 22H1.73684C1.3299 22 1 21.6701 1 21.2632V11.7368Z" fill="white"/>\n <path d="M5 8H19.2632C19.6701 8 20 8.3299 20 8.73684V18" stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>\n <path d="M8 4H22.2632C22.6701 4 23 4.3299 23 4.73684V13" stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>\n </svg>'},exports.MaximizeSvg=function(e){return"<svg fill=".concat(e||"white","\n class='icon icon-maximize'\n viewBox=\"0 0 70 70\"\n >\n <path fill=").concat(e||"white",' d="M43.369 45.938h-6.971l3.16 3.146h9.593v-9.714l-3.146-3.077v6.648l-8.823-8.823-2.817 2.817 9.004 9.004z" />\n <path fill=').concat(e||"white",' d="M21.969 18.834h6.971l-3.16-3.146h-9.593v9.714l3.146 3.077v-6.648l8.823 8.823 2.817-2.817-9.003-9.003z" />\n </svg>')},exports.MinimizeSvg=function(e){return"<svg fill=".concat(e||"white","\n class='icon icon-minimize'\n viewBox=\"0 0 70 70\"\n >\n <path fill=").concat(e||"white",' d="M40.397 37.511h6.971l-3.16-3.146h-9.593v9.714l3.146 3.077v-6.648l8.823 8.823 2.817-2.817-9.004-9.004z" />\n <path fill=').concat(e||"white",' d="M24.443 26.763h-6.971l3.16 3.146h9.593v-9.714l-3.146-3.077v6.648l-8.823-8.823-2.817 2.817 9.003 9.004z" />\n </svg>')},exports.NewCaptionsSvg=function(){return'<svg width="18" height="16" viewBox="0 0 20 21" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path d="M5 6.5H10M5 10H13M7.68375 16H14.2C15.8802 16 16.7202 16 17.362 15.673C17.9265 15.3854 18.3854 14.9265 18.673 14.362C19 13.7202 19 12.8802 19 11.2V5.8C19 4.11984 19 3.27976 18.673 2.63803C18.3854 2.07354 17.9265 1.6146 17.362 1.32698C16.7202 1 15.8802 1 14.2 1H5.8C4.11984 1 3.27976 1 2.63803 1.32698C2.07354 1.6146 1.6146 2.07354 1.32698 2.63803C1 3.27976 1 4.11984 1 5.8V18.3355C1 18.8684 1 19.1348 1.10923 19.2716C1.20422 19.3906 1.34827 19.4599 1.50054 19.4597C1.67563 19.4595 1.88367 19.2931 2.29976 18.9602L4.68521 17.0518C5.17252 16.662 5.41617 16.4671 5.68749 16.3285C5.9282 16.2055 6.18443 16.1156 6.44921 16.0613C6.74767 16 7.0597 16 7.68375 16Z" stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>\n </svg>'},exports.PlayNextEpisodeSvg=function(e){return'<svg className=\'icon-play-next\' width="16" height="16" viewBox="0 0 25 25" fill='.concat(e,' xmlns="http://www.w3.org/2000/svg">\n <path d="M14.8837 9.99984L0 0V20L14.8837 9.99984Z" fill=').concat(e,' />\n <rect x="18" width="2" height="20" fill=').concat(e," />\n </svg>")},exports.RewindSvg=function(e){return'<svg style="width:16px" class=\'rewindbtn\' viewBox="0 0 18 19" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path fill-rule="evenodd" clip-rule="evenodd" d="M7.88817 16.9913L7.72176 18.5762C9.58746 18.8613 11.4677 18.5376 13.1023 17.6161C17.1941 15.3094 18.4803 9.98978 15.9732 5.74243C13.47 1.50156 8.13865 -0.0590307 4.03665 2.25351C3.35173 2.64307 2.7379 3.12124 2.20384 3.67698L3.34087 4.82569C3.77642 4.37247 4.27773 3.98196 4.83679 3.66398C8.20452 1.76539 12.5901 3.04913 14.644 6.5288C16.6894 9.99402 15.6429 14.3223 12.3046 16.2043C10.9636 16.9602 9.42195 17.2257 7.88817 16.9913Z" fill='.concat(window.color||"white",' />\n <path fill-rule="evenodd" clip-rule="evenodd" d="M3.10742 0.462205L0.56205 5.24366L6.06202 5.79492L3.10742 0.462205Z" fill=').concat(window.color||"white",' />\n <path fill-rule="evenodd" clip-rule="evenodd" d="M9.80172 14.1769C10.1682 14.1769 10.5096 14.1082 10.8258 13.9708C11.142 13.8333 11.416 13.6241 11.6479 13.343C11.8798 13.0619 12.0615 12.7059 12.1928 12.275C12.3242 11.8441 12.3898 11.3368 12.3898 10.753C12.3898 10.1661 12.3242 9.65803 12.1928 9.22868C12.0615 8.79934 11.8798 8.44413 11.6479 8.16305C11.416 7.88197 11.142 7.6727 10.8258 7.53525C10.5096 7.3978 10.1682 7.32907 9.80172 7.32907C9.43524 7.32907 9.09551 7.3978 8.78254 7.53525C8.46956 7.6727 8.19794 7.88197 7.96767 8.16305C7.7374 8.44413 7.5574 8.79934 7.42767 9.22868C7.29794 9.65803 7.23308 10.1661 7.23308 10.753C7.23308 11.3368 7.29794 11.8441 7.42767 12.275C7.5574 12.7059 7.7374 13.0619 7.96767 13.343C8.19794 13.6241 8.46956 13.8333 8.78254 13.9708C9.09551 14.1082 9.43524 14.1769 9.80172 14.1769ZM6.54713 14.1028V13.2457H5.28226V7.39394H4.2947L2.14929 9.13139L2.52875 9.62714C2.5547 9.66112 2.59443 9.69123 2.64794 9.71749C2.70145 9.74374 2.76064 9.75687 2.82551 9.75687C2.86767 9.75687 2.91064 9.75069 2.95443 9.73834C2.99821 9.72598 3.04118 9.70282 3.08335 9.66884L4.09524 8.86266C4.08551 9.02946 4.08064 9.18853 4.08064 9.33988V13.2457H2.65524V14.1028H6.54713ZM9.30308 13.1136C9.46362 13.1893 9.62983 13.2271 9.80172 13.2271C9.97686 13.2271 10.1455 13.1893 10.3077 13.1136C10.4698 13.038 10.6133 12.9059 10.7382 12.7175C10.8631 12.5291 10.9628 12.2758 11.0374 11.9576C11.112 11.6395 11.1493 11.238 11.1493 10.753C11.1493 10.2681 11.112 9.86652 11.0374 9.54838C10.9628 9.23023 10.8631 8.97695 10.7382 8.78853C10.6133 8.60011 10.4698 8.46807 10.3077 8.39239C10.1455 8.31672 9.97686 8.27888 9.80172 8.27888C9.62983 8.27888 9.46362 8.31672 9.30308 8.39239C9.14254 8.46807 9.00064 8.60011 8.8774 8.78853C8.75416 8.97695 8.65605 9.23023 8.58308 9.54838C8.5101 9.86652 8.47362 10.2681 8.47362 10.753C8.47362 11.238 8.5101 11.6395 8.58308 11.9576C8.65605 12.2758 8.75416 12.5291 8.8774 12.7175C9.00064 12.9059 9.14254 13.038 9.30308 13.1136Z" fill=').concat(window.color||"white"," />\n </svg>")},exports.RewindSvgV2=function(){return'<svg class=\'rewindbtn\' width="21" height="20" viewBox="0 0 21 20" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path d="M1.22363 9.43675L3.152 11.3434L5.08151 9.43675M2.91616 10.8667C2.88115 10.5537 2.86319 10.2356 2.86319 9.91341C2.86319 5.17486 6.74945 1.3335 11.5434 1.3335C16.3374 1.3335 20.2236 5.17486 20.2236 9.91341C20.2236 14.652 16.3374 18.4933 11.5434 18.4933C8.8166 18.4933 6.38346 17.2505 4.79212 15.3067" stroke="white" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.3"/>\n <path d="M9.92694 13.0831V6.80067H8.94318C8.58633 7.20106 7.97871 7.53473 7.37109 7.64912V8.66918C7.68937 8.64058 8.22947 8.52618 8.51881 8.39272V13.0831H9.92694Z" fill="white"/>\n <path d="M13.6545 6.6958C11.8316 6.6958 11.1951 8.23065 11.1951 9.94664C11.1951 11.6817 11.7641 13.1975 13.6255 13.1975C15.5159 13.1975 16.0656 11.634 16.0656 9.9085C16.0656 8.12579 15.4291 6.6958 13.6545 6.6958ZM13.6545 7.78259C14.4839 7.78259 14.6382 8.69778 14.6382 9.91804C14.6382 11.1478 14.5225 12.1107 13.6448 12.1107C12.7479 12.1107 12.6128 11.0811 12.6128 9.92757C12.6128 8.57385 12.8443 7.78259 13.6545 7.78259Z" fill="white"/>\n </svg>'},exports.SelectedStream=function(){return'<svg class=\'selected-stream\' width="35" height="33" viewBox="0 0 35 33" fill="none" xmlns="http://www.w3.org/2000/svg">\n <g clip-path="url(#clip0_319_60943)">\n <path d="M0 0H35V33H0V0Z" fill="#D2393B"/>\n <path fill-rule="evenodd" clip-rule="evenodd" d="M15.8689 17.6541L22.3039 11.2898C22.6966 10.9014 23.3372 10.9054 23.7299 11.2937C24.1225 11.6821 24.1265 12.3157 23.7338 12.704L16.6345 19.7253C16.6189 19.743 16.6026 19.7604 16.5856 19.7772C16.5158 19.8463 16.4381 19.9032 16.3554 19.9479C15.9716 20.1587 15.4758 20.1009 15.1503 19.779C15.126 19.755 15.1032 19.73 15.0819 19.7042L12.2919 16.9449C11.8992 16.5565 11.9032 15.9229 12.2958 15.5346C12.6885 15.1462 13.3291 15.1423 13.7218 15.5306L15.8689 17.6541Z" fill="white"/>\n </g>\n <defs>\n <clipPath id="clip0_319_60943">\n <path d="M0 0H35V33H8C3.58172 33 0 29.4183 0 25V0Z" fill="white"/>\n </clipPath>\n </defs>\n </svg>\n '},exports.SettingsSvg=function(){return'<svg width="16" height="16" viewBox="0 0 22 22" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path d="M11 14C12.6569 14 14 12.6569 14 11C14 9.34315 12.6569 8 11 8C9.34315 8 8 9.34315 8 11C8 12.6569 9.34315 14 11 14Z" stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>\n <path d="M17.7273 13.7273C17.6063 14.0015 17.5702 14.3056 17.6236 14.6005C17.6771 14.8954 17.8177 15.1676 18.0273 15.3818L18.0818 15.4364C18.2509 15.6052 18.385 15.8057 18.4765 16.0265C18.568 16.2472 18.6151 16.4838 18.6151 16.7227C18.6151 16.9617 18.568 17.1983 18.4765 17.419C18.385 17.6397 18.2509 17.8402 18.0818 18.0091C17.913 18.1781 17.7124 18.3122 17.4917 18.4037C17.271 18.4952 17.0344 18.5423 16.7955 18.5423C16.5565 18.5423 16.3199 18.4952 16.0992 18.4037C15.8785 18.3122 15.678 18.1781 15.5091 18.0091L15.4545 17.9545C15.2403 17.745 14.9682 17.6044 14.6733 17.5509C14.3784 17.4974 14.0742 17.5335 13.8 17.6545C13.5311 17.7698 13.3018 17.9611 13.1403 18.205C12.9788 18.4489 12.8921 18.7347 12.8909 19.0273V19.1818C12.8909 19.664 12.6994 20.1265 12.3584 20.4675C12.0174 20.8084 11.5549 21 11.0727 21C10.5905 21 10.1281 20.8084 9.78708 20.4675C9.4461 20.1265 9.25455 19.664 9.25455 19.1818V19.1C9.24751 18.7991 9.15011 18.5073 8.97501 18.2625C8.79991 18.0176 8.55521 17.8312 8.27273 17.7273C7.99853 17.6063 7.69437 17.5702 7.39947 17.6236C7.10456 17.6771 6.83244 17.8177 6.61818 18.0273L6.56364 18.0818C6.39478 18.2509 6.19425 18.385 5.97353 18.4765C5.7528 18.568 5.51621 18.6151 5.27727 18.6151C5.03834 18.6151 4.80174 18.568 4.58102 18.4765C4.36029 18.385 4.15977 18.2509 3.99091 18.0818C3.82186 17.913 3.68775 17.7124 3.59626 17.4917C3.50476 17.271 3.45766 17.0344 3.45766 16.7955C3.45766 16.5565 3.50476 16.3199 3.59626 16.0992C3.68775 15.8785 3.82186 15.678 3.99091 15.5091L4.04545 15.4545C4.25503 15.2403 4.39562 14.9682 4.4491 14.6733C4.50257 14.3784 4.46647 14.0742 4.34545 13.8C4.23022 13.5311 4.03887 13.3018 3.79497 13.1403C3.55107 12.9788 3.26526 12.8921 2.97273 12.8909H2.81818C2.33597 12.8909 1.87351 12.6994 1.53253 12.3584C1.19156 12.0174 1 11.5549 1 11.0727C1 10.5905 1.19156 10.1281 1.53253 9.78708C1.87351 9.4461 2.33597 9.25455 2.81818 9.25455H2.9C3.2009 9.24751 3.49273 9.15011 3.73754 8.97501C3.98236 8.79991 4.16883 8.55521 4.27273 8.27273C4.39374 7.99853 4.42984 7.69437 4.37637 7.39947C4.3229 7.10456 4.18231 6.83244 3.97273 6.61818L3.91818 6.56364C3.74913 6.39478 3.61503 6.19425 3.52353 5.97353C3.43203 5.7528 3.38493 5.51621 3.38493 5.27727C3.38493 5.03834 3.43203 4.80174 3.52353 4.58102C3.61503 4.36029 3.74913 4.15977 3.91818 3.99091C4.08704 3.82186 4.28757 3.68775 4.50829 3.59626C4.72901 3.50476 4.96561 3.45766 5.20455 3.45766C5.44348 3.45766 5.68008 3.50476 5.9008 3.59626C6.12152 3.68775 6.32205 3.82186 6.49091 3.99091L6.54545 4.04545C6.75971 4.25503 7.03183 4.39562 7.32674 4.4491C7.62164 4.50257 7.9258 4.46647 8.2 4.34545H8.27273C8.54161 4.23022 8.77093 4.03887 8.93245 3.79497C9.09397 3.55107 9.18065 3.26526 9.18182 2.97273V2.81818C9.18182 2.33597 9.37338 1.87351 9.71435 1.53253C10.0553 1.19156 10.5178 1 11 1C11.4822 1 11.9447 1.19156 12.2856 1.53253C12.6266 1.87351 12.8182 2.33597 12.8182 2.81818V2.9C12.8193 3.19253 12.906 3.47834 13.0676 3.72224C13.2291 3.96614 13.4584 4.15749 13.7273 4.27273C14.0015 4.39374 14.3056 4.42984 14.6005 4.37637C14.8954 4.3229 15.1676 4.18231 15.3818 3.97273L15.4364 3.91818C15.6052 3.74913 15.8057 3.61503 16.0265 3.52353C16.2472 3.43203 16.4838 3.38493 16.7227 3.38493C16.9617 3.38493 17.1983 3.43203 17.419 3.52353C17.6397 3.61503 17.8402 3.74913 18.0091 3.91818C18.1781 4.08704 18.3122 4.28757 18.4037 4.50829C18.4952 4.72901 18.5423 4.96561 18.5423 5.20455C18.5423 5.44348 18.4952 5.68008 18.4037 5.9008C18.3122 6.12152 18.1781 6.32205 18.0091 6.49091L17.9545 6.54545C17.745 6.75971 17.6044 7.03183 17.5509 7.32674C17.4974 7.62164 17.5335 7.9258 17.6545 8.2V8.27273C17.7698 8.54161 17.9611 8.77093 18.205 8.93245C18.4489 9.09397 18.7347 9.18065 19.0273 9.18182H19.1818C19.664 9.18182 20.1265 9.37338 20.4675 9.71435C20.8084 10.0553 21 10.5178 21 11C21 11.4822 20.8084 11.9447 20.4675 12.2856C20.1265 12.6266 19.664 12.8182 19.1818 12.8182H19.1C18.8075 12.8193 18.5217 12.906 18.2778 13.0676C18.0339 13.2291 17.8425 13.4584 17.7273 13.7273Z" stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>\n </svg>'},exports.SettingsSvgV2=function(){return'<svg width="21" height="20" viewBox="0 0 21 20" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path fill-rule="evenodd" clip-rule="evenodd" d="M20.7275 8.7189V11.2811L18.0174 11.7913C17.8497 12.5312 17.558 13.2374 17.1546 13.88L18.71 16.1626L16.8874 17.9721L14.6149 16.43C13.9694 16.8283 13.2636 17.1194 12.5249 17.2919L12.0143 20H9.43828L8.92846 17.2919C8.18971 17.1194 7.48385 16.8284 6.8384 16.43L4.56591 17.9721L2.74302 16.1626L4.28649 13.88C3.88787 13.2349 3.5965 12.5296 3.42371 11.7913L0.727539 11.2811V8.7189L3.42371 8.1968C3.59774 7.4568 3.89356 6.75083 4.29909 6.10771L2.74337 3.837L4.56626 2.02785L6.83875 3.57C7.48173 3.16673 8.18841 2.8752 8.92881 2.70777L9.43863 0H12.0147L12.5252 2.70777C13.2656 2.87529 13.9723 3.16682 14.6153 3.57L16.8878 2.02785L18.7103 3.837L17.1549 6.11996C17.5582 6.75838 17.85 7.46066 18.0177 8.1968L20.7275 8.7189ZM5.19864 10.0057C5.2018 13.0538 7.67684 15.5222 10.7268 15.5191C12.1916 15.5176 13.5957 14.9347 14.6304 13.8985C15.665 12.8624 16.2454 11.4579 16.2438 9.99405C16.2405 6.94597 13.7654 4.47766 10.7154 4.48088C7.6654 4.4841 5.19548 6.95764 5.19864 10.0057Z" fill="white"/>\n </svg>'},exports.SkipSvg=function(e){return'<svg style="width:16px" class=\'skipbtn\' viewBox="0 0 18 20" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path fill-rule="evenodd" clip-rule="evenodd" d="M9.99586 16.9937L10.1623 18.5786C8.29657 18.8638 6.41631 18.54 4.78178 17.6185C0.689955 15.3118 -0.596286 9.9922 1.9108 5.74486C4.41407 1.50398 9.74539 -0.0566045 13.8474 2.25594C14.5323 2.64549 15.1461 3.12366 15.6802 3.6794L14.5432 4.82812C14.1076 4.3749 13.6063 3.98438 13.0472 3.66641C9.67952 1.76782 5.29397 3.05156 3.24002 6.53123C1.1946 9.99645 2.24115 14.3247 5.57947 16.2067C6.92039 16.9626 8.46208 17.2281 9.99586 16.9937Z" fill='.concat(window.color||"white",' />\n <path fill-rule="evenodd" clip-rule="evenodd" d="M14.7766 0.464616L17.322 5.24607L11.822 5.79733L14.7766 0.464616Z" fill=').concat(window.color||"white",' />\n <path fill-rule="evenodd" clip-rule="evenodd" d="M13.0245 14.115C13.391 14.115 13.7323 14.0463 14.0486 13.9088C14.3648 13.7714 14.6388 13.5621 14.8707 13.281C15.1026 13 15.2842 12.644 15.4156 12.2131C15.5469 11.7822 15.6126 11.2749 15.6126 10.6911C15.6126 10.1042 15.5469 9.59609 15.4156 9.16675C15.2842 8.73741 15.1026 8.38219 14.8707 8.10111C14.6388 7.82003 14.3648 7.61076 14.0486 7.47331C13.7323 7.33586 13.391 7.26714 13.0245 7.26714C12.658 7.26714 12.3183 7.33586 12.0053 7.47331C11.6923 7.61076 11.4207 7.82003 11.1904 8.10111C10.9602 8.38219 10.7802 8.73741 10.6504 9.16675C10.5207 9.59609 10.4559 10.1042 10.4559 10.6911C10.4559 11.2749 10.5207 11.7822 10.6504 12.2131C10.7802 12.644 10.9602 13 11.1904 13.281C11.4207 13.5621 11.6923 13.7714 12.0053 13.9088C12.3183 14.0463 12.658 14.115 13.0245 14.115ZM9.76991 14.0409V13.1837H8.50504V7.332H7.51748L5.37207 9.06945L5.75153 9.56521C5.77748 9.59918 5.81721 9.6293 5.87072 9.65555C5.92423 9.68181 5.98342 9.69493 6.04829 9.69493C6.09045 9.69493 6.13342 9.68876 6.17721 9.6764C6.22099 9.66405 6.26396 9.64088 6.30612 9.6069L7.31802 8.80073C7.30829 8.96752 7.30342 9.1266 7.30342 9.27795V13.1837H5.87802V14.0409H9.76991ZM12.5259 13.0517C12.6864 13.1274 12.8526 13.1652 13.0245 13.1652C13.1996 13.1652 13.3683 13.1274 13.5304 13.0517C13.6926 12.976 13.8361 12.844 13.961 12.6556C14.0859 12.4671 14.1856 12.2139 14.2602 11.8957C14.3348 11.5776 14.3721 11.176 14.3721 10.6911C14.3721 10.2061 14.3348 9.80459 14.2602 9.48644C14.1856 9.16829 14.0859 8.91501 13.961 8.7266C13.8361 8.53818 13.6926 8.40613 13.5304 8.33046C13.3683 8.25478 13.1996 8.21694 13.0245 8.21694C12.8526 8.21694 12.6864 8.25478 12.5259 8.33046C12.3653 8.40613 12.2234 8.53818 12.1002 8.7266C11.9769 8.91501 11.8788 9.16829 11.8059 9.48644C11.7329 9.80459 11.6964 10.2061 11.6964 10.6911C11.6964 11.176 11.7329 11.5776 11.8059 11.8957C11.8788 12.2139 11.9769 12.4671 12.1002 12.6556C12.2234 12.844 12.3653 12.976 12.5259 13.0517Z" fill=').concat(window.color||"white"," />\n </svg>")},exports.SkipSvgV2=function(){return'<svg class=\'skipbtn\' width="21" height="20" viewBox="0 0 21 20" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path d="M19.7236 9.43675L17.7953 11.3434L15.8658 9.43675M18.0311 10.8667C18.0661 10.5537 18.0841 10.2356 18.0841 9.91341C18.0841 5.17486 14.1978 1.3335 9.40386 1.3335C4.6099 1.3335 0.723633 5.17486 0.723633 9.91341C0.723633 14.652 4.6099 18.4933 9.40386 18.4933C12.1307 18.4933 14.5638 17.2505 16.1551 15.3067" stroke="white" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.3"/>\n <path d="M7.80584 13.0831V6.80067H6.82209C6.46523 7.20106 5.85762 7.53473 5.25 7.64912V8.66918C5.56828 8.64058 6.10838 8.52618 6.39772 8.39272V13.0831H7.80584Z" fill="white"/>\n <path d="M11.5334 6.6958C9.71052 6.6958 9.07397 8.23065 9.07397 9.94664C9.07397 11.6817 9.64301 13.1975 11.5044 13.1975C13.3948 13.1975 13.9445 11.634 13.9445 9.9085C13.9445 8.12579 13.308 6.6958 11.5334 6.6958ZM11.5334 7.78259C12.3628 7.78259 12.5171 8.69778 12.5171 9.91804C12.5171 11.1478 12.4014 12.1107 11.5237 12.1107C10.6268 12.1107 10.4917 11.0811 10.4917 9.92757C10.4917 8.57385 10.7232 7.78259 11.5334 7.78259Z" fill="white"/>\n </svg>'},exports.crossIconSvg=function(){return'<svg width="19" height="20" viewBox="0 0 19 20" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path fill-rule="evenodd" clip-rule="evenodd" d="M0.273985 2.30391C-0.124672 1.74341 -0.0882695 0.933084 0.383092 0.418212C0.893733 -0.139565 1.72148 -0.13938 2.23191 0.418626L9.25 8.09082L16.2681 0.418626C16.7785 -0.13938 17.6063 -0.139565 18.1169 0.418212C18.5883 0.933084 18.6247 1.74341 18.226 2.30391L18.1173 2.43852L11.1987 10.0029L18.1169 17.5611C18.5883 18.0759 18.6247 18.8863 18.226 19.4468L18.1173 19.5814C17.6461 20.0965 16.9046 20.1362 16.3916 19.7006L16.2685 19.5818L9.25 11.9155L2.23153 19.5818L2.10835 19.7006C1.59542 20.1362 0.853882 20.0965 0.382714 19.5814L0.273985 19.4468C-0.124672 18.8863 -0.0882694 18.0759 0.383092 17.5611L7.30134 10.0029L0.382714 2.43852L0.273985 2.30391Z" fill="white"/>\n </svg>\n \n '};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";var e=require("@babel/runtime/helpers/classCallCheck"),t=require("@babel/runtime/helpers/createClass"),i=require("@babel/runtime/helpers/inherits"),n=require("@babel/runtime/helpers/possibleConstructorReturn"),r=require("@babel/runtime/helpers/getPrototypeOf"),o=require("video.js"),a=require("./icons-7afb9c13.js"),d=require("./generic-8b99b151.js"),l=require("./skin-84083352.js");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 i,o=r(e);if(t){var a=r(this).constructor;i=Reflect.construct(o,arguments,a)}else i=o.apply(this,arguments);return n(this,i)}}require("@babel/runtime/helpers/defineProperty"),require("axios"),require("js-cookie"),require("ua-parser-js"),require("@babel/runtime/helpers/toConsumableArray");var c=o.getComponent("Component"),u=function(n){i(u,c);var r=s(u);function u(t){var i,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e(this,u),(i=r.call(this,t,n)).playerId=n.playerId,i.player=t,i.videoDetails=null==n?void 0:n.options,i.initialiseStructure(),i.loadCSS(),i}return t(u,[{key:"createEl",value:function(){var e=o.dom.createEl("div",{className:"debug-selection vjs-control vjs-button"});e.style.position="unset";var t=o.dom.createEl("div",{className:"debug-selection-icon",innerHTML:"".concat(a.DebugSvg())});return o.dom.appendContent(e,t),e}},{key:"loadCSS",value:function(){Promise.resolve().then((function(){return require("./debugSelection-cbfdabb7.js")})).then((function(e){var t=document.createElement("style");t.id="debug-selection",t.append("".concat(e.default)),document.head.appendChild(t)}))}},{key:"initialiseStructure",value:function(){var e=this.el(),t=o.dom.createEl("div",{className:"debug-selection-container hidden"});t.style.right="0px",o.dom.$(".debug-selection-icon",this.el()).onclick=function(){var i;null!==(i=t.classList)&&void 0!==i&&i.contains("hidden")?(l.closeOpenDrawers(),t.classList.remove("hidden"),e.classList.add("open"),t.style.right="0px"):(t.classList.add("hidden"),e.classList.remove("open"),t.style.right="-350px")};var i=window.getComputedStyle(document.getElementById(this.playerId),null).getPropertyValue("height").slice(0,-2);t.style.height="".concat(i,"px"),o.dom.appendContent(e,t),document.getElementById(this.playerId).style.overflow="hidden",this.addFunctionality(t)}},{key:"toggleOpenClose",value:function(){}},{key:"addFunctionality",value:function(e){var t,i,n=this,r=this.el(),l=o.dom.createEl("div",{className:"debug-selector-head"}),s=o.dom.createEl("div",{className:"debug-selector-cross-icon",innerHTML:"".concat(a.crossIconSvg())});s.onclick=function(){e.classList.add("hidden"),r.classList.remove("open"),e.style.right="-350px"};var c=o.dom.createEl("div",{className:"debug-selector-title",innerHTML:"Debug Statistics"}),u=o.dom.createEl("div",{className:"debug-selector-content"}),p=o.dom.createEl("div",{className:"debug-container"}),m=100*d.getPlayer(this.playerId).volume().toFixed(2),v=o.dom.createEl("div",{className:"video-id-container debug-item-wrapper",innerHTML:'<div class="debug-item"><div class="debug-title-item">Video Id </div><div class="debug-value-item">'.concat(null===(t=this.videoDetails)||void 0===t?void 0:t.videoId,"</div></div>")}),g=o.dom.createEl("div",{className:"volume-container debug-item-wrapper",innerHTML:'<div class="debug-item"><div class="debug-title-item">Volume </div><div class="debug-value-item">'.concat(m,"</div></div>")}),h=o.dom.createEl("div",{className:"bandwidth-container debug-item-wrapper"}),b=o.dom.createEl("div",{className:"buffer-container debug-item-wrapper"}),y=o.dom.createEl("div",{className:"drop-frames-container debug-item-wrapper"}),f=o.dom.createEl("div",{className:"live-mode-container debug-item-wrapper",innerHTML:'<div class="debug-item"><div class="debug-title-item">Live Mode </div><div class="debug-value-item">'.concat(null===(i=this.videoDetails)||void 0===i?void 0:i.liveVideo,"</div></div>")}),C=o.dom.createEl("div",{className:"viewport-container debug-item-wrapper"});o.dom.appendContent(p,v),o.dom.appendContent(p,g),o.dom.appendContent(p,h),o.dom.appendContent(p,b),o.dom.appendContent(p,y),o.dom.appendContent(p,f),o.dom.appendContent(p,C),o.dom.appendContent(u,p),o.dom.appendContent(l,s),o.dom.appendContent(l,c),o.dom.appendContent(e,l),o.dom.appendContent(e,u),d.getPlayer(this.playerId).on("fullscreenchange",(function(){var t=window.getComputedStyle(document.getElementById(n.playerId),null).getPropertyValue("height").slice(0,-2);e.style.height="".concat(t,"px")}))}}]),u}();exports.default=u;
|
package/cjs/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("@silvermine/videojs-chromecast"),t=require("@silvermine/videojs-airplay");require("videojs-contrib-eme"),require("videojs-contrib-dash"),require("videojs-contrib-ads"),require("videojs-ima");var n=require("@babel/runtime/helpers/defineProperty"),i=require("video.js");require("video.js/dist/video-js.min.css");var o=require("axios"),a=require("@babel/runtime/helpers/toConsumableArray"),r=require("@babel/runtime/helpers/classCallCheck"),l=require("@babel/runtime/helpers/createClass"),d=require("@babel/runtime/helpers/assertThisInitialized"),s=require("@babel/runtime/helpers/inherits"),c=require("@babel/runtime/helpers/possibleConstructorReturn"),u=require("@babel/runtime/helpers/getPrototypeOf"),v=function(e){return'<svg width="14" height="14" viewBox="0 0 18 19" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path fill-rule="evenodd" clip-rule="evenodd" d="M7.88817 16.9913L7.72176 18.5762C9.58746 18.8613 11.4677 18.5376 13.1023 17.6161C17.1941 15.3094 18.4803 9.98978 15.9732 5.74243C13.47 1.50156 8.13865 -0.0590307 4.03665 2.25351C3.35173 2.64307 2.7379 3.12124 2.20384 3.67698L3.34087 4.82569C3.77642 4.37247 4.27773 3.98196 4.83679 3.66398C8.20452 1.76539 12.5901 3.04913 14.644 6.5288C16.6894 9.99402 15.6429 14.3223 12.3046 16.2043C10.9636 16.9602 9.42195 17.2257 7.88817 16.9913Z" fill='.concat(e,' />\n <path fill-rule="evenodd" clip-rule="evenodd" d="M3.10742 0.462205L0.56205 5.24366L6.06202 5.79492L3.10742 0.462205Z" fill=').concat(e,' />\n <path fill-rule="evenodd" clip-rule="evenodd" d="M9.80172 14.1769C10.1682 14.1769 10.5096 14.1082 10.8258 13.9708C11.142 13.8333 11.416 13.6241 11.6479 13.343C11.8798 13.0619 12.0615 12.7059 12.1928 12.275C12.3242 11.8441 12.3898 11.3368 12.3898 10.753C12.3898 10.1661 12.3242 9.65803 12.1928 9.22868C12.0615 8.79934 11.8798 8.44413 11.6479 8.16305C11.416 7.88197 11.142 7.6727 10.8258 7.53525C10.5096 7.3978 10.1682 7.32907 9.80172 7.32907C9.43524 7.32907 9.09551 7.3978 8.78254 7.53525C8.46956 7.6727 8.19794 7.88197 7.96767 8.16305C7.7374 8.44413 7.5574 8.79934 7.42767 9.22868C7.29794 9.65803 7.23308 10.1661 7.23308 10.753C7.23308 11.3368 7.29794 11.8441 7.42767 12.275C7.5574 12.7059 7.7374 13.0619 7.96767 13.343C8.19794 13.6241 8.46956 13.8333 8.78254 13.9708C9.09551 14.1082 9.43524 14.1769 9.80172 14.1769ZM6.54713 14.1028V13.2457H5.28226V7.39394H4.2947L2.14929 9.13139L2.52875 9.62714C2.5547 9.66112 2.59443 9.69123 2.64794 9.71749C2.70145 9.74374 2.76064 9.75687 2.82551 9.75687C2.86767 9.75687 2.91064 9.75069 2.95443 9.73834C2.99821 9.72598 3.04118 9.70282 3.08335 9.66884L4.09524 8.86266C4.08551 9.02946 4.08064 9.18853 4.08064 9.33988V13.2457H2.65524V14.1028H6.54713ZM9.30308 13.1136C9.46362 13.1893 9.62983 13.2271 9.80172 13.2271C9.97686 13.2271 10.1455 13.1893 10.3077 13.1136C10.4698 13.038 10.6133 12.9059 10.7382 12.7175C10.8631 12.5291 10.9628 12.2758 11.0374 11.9576C11.112 11.6395 11.1493 11.238 11.1493 10.753C11.1493 10.2681 11.112 9.86652 11.0374 9.54838C10.9628 9.23023 10.8631 8.97695 10.7382 8.78853C10.6133 8.60011 10.4698 8.46807 10.3077 8.39239C10.1455 8.31672 9.97686 8.27888 9.80172 8.27888C9.62983 8.27888 9.46362 8.31672 9.30308 8.39239C9.14254 8.46807 9.00064 8.60011 8.8774 8.78853C8.75416 8.97695 8.65605 9.23023 8.58308 9.54838C8.5101 9.86652 8.47362 10.2681 8.47362 10.753C8.47362 11.238 8.5101 11.6395 8.58308 11.9576C8.65605 12.2758 8.75416 12.5291 8.8774 12.7175C9.00064 12.9059 9.14254 13.038 9.30308 13.1136Z" fill=').concat(e," />\n </svg>")},m=function(e){return'<svg width="14" height="14" viewBox="0 0 18 20" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path fill-rule="evenodd" clip-rule="evenodd" d="M9.99586 16.9937L10.1623 18.5786C8.29657 18.8638 6.41631 18.54 4.78178 17.6185C0.689955 15.3118 -0.596286 9.9922 1.9108 5.74486C4.41407 1.50398 9.74539 -0.0566045 13.8474 2.25594C14.5323 2.64549 15.1461 3.12366 15.6802 3.6794L14.5432 4.82812C14.1076 4.3749 13.6063 3.98438 13.0472 3.66641C9.67952 1.76782 5.29397 3.05156 3.24002 6.53123C1.1946 9.99645 2.24115 14.3247 5.57947 16.2067C6.92039 16.9626 8.46208 17.2281 9.99586 16.9937Z" fill='.concat(e,' />\n <path fill-rule="evenodd" clip-rule="evenodd" d="M14.7766 0.464616L17.322 5.24607L11.822 5.79733L14.7766 0.464616Z" fill=').concat(e,' />\n <path fill-rule="evenodd" clip-rule="evenodd" d="M13.0245 14.115C13.391 14.115 13.7323 14.0463 14.0486 13.9088C14.3648 13.7714 14.6388 13.5621 14.8707 13.281C15.1026 13 15.2842 12.644 15.4156 12.2131C15.5469 11.7822 15.6126 11.2749 15.6126 10.6911C15.6126 10.1042 15.5469 9.59609 15.4156 9.16675C15.2842 8.73741 15.1026 8.38219 14.8707 8.10111C14.6388 7.82003 14.3648 7.61076 14.0486 7.47331C13.7323 7.33586 13.391 7.26714 13.0245 7.26714C12.658 7.26714 12.3183 7.33586 12.0053 7.47331C11.6923 7.61076 11.4207 7.82003 11.1904 8.10111C10.9602 8.38219 10.7802 8.73741 10.6504 9.16675C10.5207 9.59609 10.4559 10.1042 10.4559 10.6911C10.4559 11.2749 10.5207 11.7822 10.6504 12.2131C10.7802 12.644 10.9602 13 11.1904 13.281C11.4207 13.5621 11.6923 13.7714 12.0053 13.9088C12.3183 14.0463 12.658 14.115 13.0245 14.115ZM9.76991 14.0409V13.1837H8.50504V7.332H7.51748L5.37207 9.06945L5.75153 9.56521C5.77748 9.59918 5.81721 9.6293 5.87072 9.65555C5.92423 9.68181 5.98342 9.69493 6.04829 9.69493C6.09045 9.69493 6.13342 9.68876 6.17721 9.6764C6.22099 9.66405 6.26396 9.64088 6.30612 9.6069L7.31802 8.80073C7.30829 8.96752 7.30342 9.1266 7.30342 9.27795V13.1837H5.87802V14.0409H9.76991ZM12.5259 13.0517C12.6864 13.1274 12.8526 13.1652 13.0245 13.1652C13.1996 13.1652 13.3683 13.1274 13.5304 13.0517C13.6926 12.976 13.8361 12.844 13.961 12.6556C14.0859 12.4671 14.1856 12.2139 14.2602 11.8957C14.3348 11.5776 14.3721 11.176 14.3721 10.6911C14.3721 10.2061 14.3348 9.80459 14.2602 9.48644C14.1856 9.16829 14.0859 8.91501 13.961 8.7266C13.8361 8.53818 13.6926 8.40613 13.5304 8.33046C13.3683 8.25478 13.1996 8.21694 13.0245 8.21694C12.8526 8.21694 12.6864 8.25478 12.5259 8.33046C12.3653 8.40613 12.2234 8.53818 12.1002 8.7266C11.9769 8.91501 11.8788 9.16829 11.8059 9.48644C11.7329 9.80459 11.6964 10.2061 11.6964 10.6911C11.6964 11.176 11.7329 11.5776 11.8059 11.8957C11.8788 12.2139 11.9769 12.4671 12.1002 12.6556C12.2234 12.844 12.3653 12.976 12.5259 13.0517Z" fill=').concat(e," />\n </svg>")},p="https://prod-api.viewlift.com",h="/entitlement/video/status";function f(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,i=u(e);if(t){var o=u(this).constructor;n=Reflect.construct(i,arguments,o)}else n=i.apply(this,arguments);return c(this,n)}}var g=i.getComponent("Component"),C=function(e){s(o,g);var t=f(o);function o(e){var l,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return r(this,o),l=t.call(this,e,s),n(d(l),"masterRenditions",[]),n(d(l),"addCustomFont",(function(e){var t=i.dom.createEl("div",{className:"font hideCustomFonts"}),n=i.dom.createEl("p",{className:"customFontHeading",innerHTML:"Font Size"});i.dom.appendContent(t,n);var o=i.dom.createEl("div",{className:"font-options"});o.style.fontSize="12px",l.fontSizeOptions.map((function(e,t){var n=i.dom.createEl("div",{className:"options",innerHTML:'<div class="radio-item" >\n <input class=opt'.concat(t,' type="radio" id=').concat(e,' name="item" />\n <label class="radio-btn-lable" for=').concat(e,">").concat(e,"pt</label>\n </div>")});n.addEventListener("click",(function(e){var t=e.target.id;l.changeFontSize(t)})),i.dom.appendContent(o,n)})),i.dom.appendContent(t,o),i.dom.appendContent(e,t)})),n(d(l),"resetRenditions",(function(){a(document.getElementsByClassName("rendition")).map((function(e){i.dom.removeClass(e,"selected")}))})),n(d(l),"playSelectedResolutionNondrm",(function(e,t,n){e.tech_.vhs.representations().forEach((function(i){n||i.bandwidth===t?(e.tech_.vhs.playlists.media(e.tech_.vhs.playlists.master.playlists[window.selectedVideo]),i.enabled(!0)):i.enabled(!1)})),e.handleTechPlaying_();var o=e.currentTime();e.currentTime(0),setTimeout((function(){e.currentTime(o),e.play()}),100);var a=i.dom.$(".content",this.contentEl());i.dom.addClass(a,"hidden")})),n(d(l),"playSelectedResolutionDRM",(function(e,t){if("auto"!==t){console.log(e.dash),e&&e.dash&&e.dash.mediaPlayer&&e.dash.mediaPlayer.updateSettings({streaming:{abr:{autoSwitchBitrate:!1}}}),e.dash.mediaPlayer.setQualityFor("video",t,!0);var n=e.currentTime();e.currentTime(0),setTimeout((function(){e.currentTime(n),e.play()}),100);var o=i.dom.$(".content",this.contentEl());i.dom.addClass(o,"hidden")}else e.dash.mediaPlayer.resetSettings()})),l.playerId=null==s?void 0:s.playerId,l.masterRenditions=[],l.fontSizeOptions=[10,12,14],l.createRenditions(E().getRenditions(l.playerId)),l}return l(o,[{key:"toggleContentOnHover",value:function(e,t){e.addEventListener("mouseover",(function(){i.dom.removeClass(t,"hidden")})),t.addEventListener("mouseover",(function(){i.dom.removeClass(t,"hidden")})),e.addEventListener("mouseout",(function(){i.dom.addClass(t,"hidden")})),t.addEventListener("mouseout",(function(){i.dom.addClass(t,"hidden")}))}},{key:"changeFontSize",value:function(e){var t=i.dom.$(".renditions",this.contentEl()),n=i.dom.$(".font-options",this.contentEl());t.style.fontSize="".concat(e,"px"),n.style.fontSize="".concat(e,"px")}},{key:"createRenditions",value:function(e){var t=this,n=this.el(),o=i.dom.createEl("div",{className:"content hidden"});this.addCustomFont(o);var a=i.dom.createEl("p",{innerHTML:"Quality",className:"title"}),r=i.dom.createEl("div",{className:"resolution"});i.dom.appendContent(r,a),this.toggleContentOnHover(n,o);var l=i.dom.createEl("div",{className:"renditions"});this.player_.vhs?(e.map((function(e,n){var o=i.dom.createEl("div",{className:"relative"}),a=(e.bandwidth/1048576).toFixed(1),r="".concat(e.height,"p ").concat(e.height>719&&e.height<1081?"<span>HD</span>":e.height>1081&&e.height<1500?"<span>2K (HD)</span>":e.height>1501?"<span>4K (HD)</span>":"");r="".concat(e.height,"p @ ").concat(a,"mbps ").concat(e.height>719&&e.height<1081?"<span>HD</span>":e.height>1081&&e.height<1500?"<span>2K (HD)</span>":e.height>1501?"<span>4K (HD)</span>":"");var d=i.dom.createEl("p",{innerHTML:r,className:"rendition",res:e.height,bandwidth:e.bandwidth});i.dom.appendContent(o,d),i.dom.appendContent(l,o),d.addEventListener("click",(function(e){window.height!==e.target.res&&(t.resetRenditions(),window.height=e.target.res,window.bandwidth=parseInt(e.target.bandwidth),window.selectedVideo=e.target.video,t.playSelectedResolutionNondrm(t.player_,window.bandwidth,!1),i.dom.addClass(d,"selected"))}))})),this.addAutoRendition("nondrm",l),this.addDynamicSwitchIfAuto()):(e.map((function(e,n){var o=i.dom.createEl("div",{className:"relative"}),a=(e.bitrate/1e6).toFixed(1),r="".concat(e.height,"p ").concat(e.height>719&&e.height<1081?"<span>HD</span>":e.height>1081&&e.height<1500?"<span>2K (HD)</span>":e.height>1501?"<span>4K (HD)</span>":"");window.enableResolutionsBitrate&&(r="".concat(e.height,"p @ ").concat(a,"mbps ").concat(e.height>719&&e.height<1081?"<span>HD</span>":e.height>1081&&e.height<1500?"<span>2K (HD)</span>":e.height>1501?"<span>4K (HD)</span>":""));var d=i.dom.createEl("p",{innerHTML:r,className:"rendition",res:e.height,qualityindex:e.qualityIndex});i.dom.appendContent(o,d),i.dom.appendContent(l,o),d.addEventListener("click",(function(e){window.height!==e.target.res&&(t.resetRenditions(),window.height=e.target.res,window.selectedVideo=e.target.video,window.qualityindex=e.target.qualityindex,t.playSelectedResolutionDRM(t.player_,window.qualityindex),i.dom.addClass(d,"selected"))}))})),this.addAutoRendition("drm",l)),i.dom.appendContent(r,l),i.dom.appendContent(o,r),i.dom.appendContent(n,o),i.dom.$(".opt0",this.contentEl()).checked=!0}},{key:"addDynamicSwitchIfAuto",value:function(){for(var e,t,n=this.player_.textTracks(),i=0;i<n.length;i++)"segment-metadata"===n[i].label&&(e=n[i]);e&&e.on("cuechange",(function(){var n=e.activeCues[0];if(n&&document.querySelector(".auto.selected")){if(t!==n.value.resolution.height)console.log(n.value.resolution.height),document.querySelector(".auto.selected").innerHTML="Auto ".concat(n.value.resolution.height,"p");t=n.value.resolution.height}}))}},{key:"createEl",value:function(){var e,t=i.dom.createEl("div",{className:"container"}),n=i.dom.createEl("div",{className:"setting-icon",innerHTML:"".concat((e=window.controlsColor?window.controlsColor:"white",'<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" class="bi bi-gear-fill" viewBox="0 0 16 16 fill='.concat(e,'">\n <path fill=').concat(e,' d="M9.405 1.05c-.413-1.4-2.397-1.4-2.81 0l-.1.34a1.464 1.464 0 0 1-2.105.872l-.31-.17c-1.283-.698-2.686.705-1.987 1.987l.169.311c.446.82.023 1.841-.872 2.105l-.34.1c-1.4.413-1.4 2.397 0 2.81l.34.1a1.464 1.464 0 0 1 .872 2.105l-.17.31c-.698 1.283.705 2.686 1.987 1.987l.311-.169a1.464 1.464 0 0 1 2.105.872l.1.34c.413 1.4 2.397 1.4 2.81 0l.1-.34a1.464 1.464 0 0 1 2.105-.872l.31.17c1.283.698 2.686-.705 1.987-1.987l-.169-.311a1.464 1.464 0 0 1 .872-2.105l.34-.1c1.4-.413 1.4-2.397 0-2.81l-.34-.1a1.464 1.464 0 0 1-.872-2.105l.17-.31c.698-1.283-.705-2.686-1.987-1.987l-.311.169a1.464 1.464 0 0 1-2.105-.872l-.1-.34zM8 10.93a2.929 2.929 0 1 1 0-5.86 2.929 2.929 0 0 1 0 5.858z"/>\n </svg>')))});return i.dom.appendContent(t,n),t}},{key:"addAutoRendition",value:function(e,t){var n=this;if("nondrm"==e){var o,a,r,l,d=null===(o=this.player_)||void 0===o||null===(a=o.tech_)||void 0===a?void 0:a.vhs.selectPlaylist().attributes.RESOLUTION.height,s=null===(r=this.player_)||void 0===r||null===(l=r.tech_)||void 0===l?void 0:l.vhs.selectPlaylist().attributes.BANDWIDTH,c=i.dom.createEl("div",{className:"relative"}),u=i.dom.createEl("p",{innerHTML:"Auto ".concat(d,"p"),className:"rendition auto selected",bandwidth:s,res:d});u.addEventListener("click",(function(e){window.height!==e.target.res&&(n.resetRenditions(),i.dom.addClass(u,"selected"),window.height=e.target.res,window.bandwidth=parseInt(e.target.bandwidth),window.selectedVideo=e.target.video,n.playSelectedResolutionNondrm(n.player_,window.bandwidth,!0))})),i.dom.appendContent(c,u),i.dom.appendContent(t,c)}else{var v=i.dom.createEl("div",{className:"relative"}),m=i.dom.createEl("p",{innerHTML:"Auto",className:"rendition selected",qualityindex:"auto"});m.addEventListener("click",(function(e){n.resetRenditions(),i.dom.addClass(m,"selected"),window.qualityindex=e.target.qualityindex,window.selectedVideo=e.target.video,n.playSelectedResolutionDRM(n.player_,window.qualityindex)})),i.dom.appendContent(v,m),i.dom.appendContent(t,v)}}}]),o}(),y=function(e){return new Promise((function(t,n){if(w(e))n("Alread initialised");else{var i=document.createElement("script");i.async=!1,i.src=e,document.head.appendChild(i),t()}}))},w=function(e){return document.querySelectorAll('script[src="'.concat(e,'"]')).length>0},b=function(e){var t,n=e.fairPlay,i=e.widevine,o=e.playReady,a=T();if("Safari"===a){console.log("safari");var r={src:(t=n).url,type:"application/x-mpegURL",keySystems:{"com.apple.fps.1_0":{getCertificate:function(e,n){var i={uri:t.certificateUrl,method:"GET",responseType:"arraybuffer"};videojs.xhr(i,(function(e,t,i){console.log(e),e&&n(e),n(null,new Uint8Array(i))}))},getContentId:function(e,t){if(t)return new TextDecoder("utf-16").decode(t.slice(16))},getLicense:function(e,n,i,o){var a={uri:t.licenseUrl,method:"POST",responseType:"arraybuffer",body:i,headers:{"Content-type":"application/octet-stream","X-AxDRM-Message":t&&t.licenseToken}};videojs.xhr(a,(function(e,t,n){console.log(e),e&&o(e),o(null,n)}))}}}};try{player.eme()}catch(e){}return r}if("Chrome"===a||"Firefox"===a){var l={src:i.url,type:"application/dash+xml",keySystemOptions:[]};return l.keySystemOptions.push({name:"com.widevine.alpha",options:{serverURL:i.licenseUrl,httpRequestHeaders:{"X-AxDRM-Message":i.licenseToken}}}),console.log(l),l}if("IE"===a)return src={src:o.url,type:"application/dash+xml"},src.keySystemOptions=[],src.keySystemOptions.push({name:"com.microsoft.playready",options:{serverURL:o.licenseUrl,httpRequestHeaders:{"X-AxDRM-Message":o.licenseToken}}}),src},T=function(){return-1!=(navigator.userAgent.indexOf("Opera")||navigator.userAgent.indexOf("OPR"))?"Opera":-1!=navigator.userAgent.indexOf("Chrome")?"Chrome":-1!=navigator.userAgent.indexOf("Safari")?"Safari":-1!=navigator.userAgent.indexOf("Firefox")?"Firefox":-1!=navigator.userAgent.indexOf("MSIE")||1==!!document.documentMode?"IE":"Unknown"};e(i),t(i);var k=!1,D=["https://www.gstatic.com/cv/js/sender/v1/cast_sender.js?loadCastFramework=1","https://imasdk.googleapis.com/js/sdkloader/ima3.js"];function E(){var e=function(e){i(e).reset(),i(e).controls(!1)},t=function(e,t){var n=i(e),o=n.currentTime()+t;n.currentTime(o)},a=function(e){var t=i.getComponent("Button"),n=i.extend(t,{constructor:function(){t.apply(this,arguments);var e=this.el_;e.classList.add("vjs-rewind-button"),e.innerHTML=v("white")},handleClick:function(){!function(e,t){var n=i(e),o=n.currentTime(),a=o<=t?0:o-t;n.currentTime(a)}(e,10)}});i.registerComponent("MyButton",n),i(e).getChild("controlBar").addChild("myButton",{},1)},r=function(e){return!!i.getPlayer("".concat(e))&&i.getPlayer("".concat(e))},l=function(e,n,o){var r,l,c,v,p,h,C,y,T,k=(null===(r=window)||void 0===r||null===(l=r.cast)||void 0===l||null===(c=l.framework)||void 0===c||null===(v=c.CastContext)||void 0===v||null===(p=v.getInstance())||void 0===p?void 0:p.S)||void 0,D="NO_DEVICES_AVAILABLE"!==k&&"NOT_CONNECTED"!==k?["html5","chromecast"]:["chromecast","html5"],E=null==n||null===(h=n.video)||void 0===h||null===(C=h.gist)||void 0===C?void 0:C.videoImageUrl,R=(null==n||null===(y=n.video)||void 0===y||null===(T=y.liveDetails)||void 0===T?void 0:T.isDvrEnabled)||!1,x=i(e,{controls:!0,fluid:!0,controlBar:{volumePanel:{inline:!1}},liveui:R,poster:E,playbackRates:[.5,1,1.5,2],techOrder:D,chromecast:{requestCustomDataFn:function(e){return f(n,e)}},plugins:{chromecast:{receiverAppID:"764F169F",addButtonToControlBar:!0,buttonPositionIndex:-1,addCastLabelToButton:!0},airPlay:{buttonPositionIndex:-1}}},(function(){var r,l,c,v,p,h,f,C,y,T,k,D,E,L;o("Player Initialised");var A,S=n.video.drmEnabled,M=n.video.streamingInfo.videoAssets,P=(null===(r=n.video.streamingInfo.videoAssets)||void 0===r?void 0:r.hls)||!1,H=(null==n||null===(l=n.ads)||void 0===l||null===(c=l.preRoll)||void 0===c||null===(v=c.adTags)||void 0===v||null===(p=v.web)||void 0===p?void 0:p.active)&&(null==n||null===(h=n.ads)||void 0===h||null===(f=h.preRoll)||void 0===f||null===(C=f.adTags)||void 0===C||null===(y=C.web)||void 0===y?void 0:y.url),O=null==n||null===(T=n.video)||void 0===T||null===(k=T.liveDetails)||void 0===k?void 0:k.startOverTime;if(R&&w(e,O),H&&g(e,H),S){var q=b(M);d(x,q)}else if(P){var I=function(e){var t=null==e?void 0:e.hls;return t?{src:t,type:"application/x-mpegURL"}:null}(M);d(x,I)}else{var B=function(e){var t=e.mpeg;return{src:t[t.length-1].url,type:"video/mp4"}}(M);d(x,B)}x.airPlay(),(null==n||null===(D=n.video)||void 0===D||null===(E=D.contentDetails)||void 0===E||null===(L=E.closedCaptions)||void 0===L?void 0:L.length)>0&&(A=n.video.contentDetails.closedCaptions.filter((function(e){return"VTT"===e.format})),u(e,A)),function(e){var n=i.getComponent("Button"),o=i.extend(n,{constructor:function(){n.apply(this,arguments);var e=this.el_;e.classList.add("vjs-skip-button"),e.innerHTML=m("white")},handleClick:function(){t(e,10)}});i.registerComponent("MyButton",o),i(e).getChild("controlBar").addChild("myButton",{},1)}(e),a(e),s(e)}))},d=function(e,t){e.src(t)},s=function(e){r(e).one("loadedmetadata",(function(){c(e),function(e){var t,n,i,o,a,r,l,d=E().getPlayer(e),s=null==d||null===(t=d.controlBar)||void 0===t||null===(n=t.playToggle)||void 0===n?void 0:n.el_,c=null==d||null===(i=d.controlBar)||void 0===i||null===(o=i.volumePanel)||void 0===o||null===(a=o.muteToggle)||void 0===a?void 0:a.el_,u=null==d||null===(r=d.controlBar)||void 0===r||null===(l=r.fullscreenToggle)||void 0===l?void 0:l.el_,v=document.querySelector(".vjs-skip-button"),m=document.querySelector(".vjs-rewind-button"),p=document.getElementsByTagName("video")[0];window&&window.addEventListener("keydown",(function(e){switch(e.key){case" ":return e.preventDefault(),p&&p.focus(),void(s&&s.click());case"m":case"M":return e.preventDefault(),p&&p.focus(),void(c&&c.click());case"f":case"F":return e.preventDefault(),p&&p.focus(),void(u&&u.click());case"ArrowLeft":return e.preventDefault(),p&&p.focus(),void(m&&m.click());case"ArrowRight":return e.preventDefault(),p&&p.focus(),void(v&&v.click());default:return}}))}(e)}))},c=function(e){var t=r(e);i.registerComponent("resolutionModule",C),t.getChild("controlBar").addChild("resolutionModule",{playerId:e},t.controlBar.children().length-6)},u=function(e,t){var n=r(e);n.remoteTextTracks().tracks_.map((function(e){n.removeRemoteTextTrack(e)})),t.map((function(e){n.addRemoteTextTrack({src:e.url,srcLang:e.language,label:e.language})}))},f=function(e,t){var n,i,o,a,r,l,d,s,c,u,v,m,p,h={};if(e&&e.video&&e.video.drmEnabled){h.isDrmEnabled=!0;var f=t.keySystemOptions&&t.keySystemOptions[0]&&t.keySystemOptions[0].options&&t.keySystemOptions[0].options.serverURL;h.licenseUrl=f;var g=t.keySystemOptions&&t.keySystemOptions[0]&&t.keySystemOptions[0].options&&t.keySystemOptions[0].options.httpRequestHeaders["X-AxDRM-Message"];h.licenseToken=g}var C=(null==e||null===(n=e.video)||void 0===n||null===(i=n.gist)||void 0===i?void 0:i.contentType)||"VIDEO";h.contentType=C;var y=null==e||null===(o=e.video)||void 0===o||null===(a=o.gist)||void 0===a?void 0:a.runtime;h.duration=y;var w=null==e||null===(r=e.video)||void 0===r||null===(l=r.gist)||void 0===l?void 0:l.title;h.mediaTitle=w;var b=null==e||null===(d=e.video)||void 0===d||null===(s=d.gist)||void 0===s?void 0:s.videoImageUrl;h.mediaImage=b;var T=[];return(null==e||null===(c=e.video)||void 0===c||null===(u=c.contentDetails)||void 0===u||null===(v=u.closedCaptions)||void 0===v?void 0:v.length)>0&&(T=e.video.contentDetails.closedCaptions.filter((function(e){return"VTT"===e.format}))),T.length>0&&(T[0].subtitleUrl=T[0].url,h.subTitles=T),h.DVR=(null==e||null===(m=e.video)||void 0===m||null===(p=m.liveDetails)||void 0===p?void 0:p.isDvrEnabled)||!1,console.log(h),h},g=function(e,t){var n=r(e);t&&window.google&&(n.ima.initializeAdDisplayContainer&&n.ima.initializeAdDisplayContainer(),k?(n.ima.setContentWithAdTag(null,t,!0),n.ima.requestAds()):function(e,t){var n=r(e);if(null!==n.el_){k=!0;var i={id:e,adTagUrl:"".concat(t,"&vid=").concat(window.videoId,"&url=").concat(window.location.href,"&correlator=").concat((new Date).getTime(),"&cust_params=sd%3D60000%26site%3D").concat(window.location.origin,"%26autostart%3D%26mute%3D%26user_agent%3D%26keyword%3D%26category%3D").concat(window.category,"%26vid%3D").concat(window.videoId),adLabel:"Your video will resume after this sponsor message"};n.ima.initializeAdDisplayContainer&&n.ima.initializeAdDisplayContainer(),k&&null!==n.el_&&("function"==typeof n.ima?n.ima(i):setTimeout((function(){n.ima.setContentWithAdTag(null,t,!0),n.ima.requestAds()}),1e3));var o=document.getElementById("".concat(e));(navigator.userAgent.match(/iPad/i)||navigator.userAgent.match(/Android/i))&&o.hasAttribute("controls")&&o.removeAttribute("controls");var a="click",l=!1;(navigator.userAgent.match(/iPhone/i)||navigator.userAgent.match(/iPad/i)||navigator.userAgent.match(/Android/i))&&(l=!0,a="touchend"),n.one(a,(function(){l&&n.ima.initializeAdDisplayContainer()}))}}(e,t))},w=function(e,t){var n=r(e);n&&t&&n.controlBar&&n.controlBar.progressControl.seekBar.on("click",(function(t){var n,o,a,r,l,d=this.el(),s=i.dom.getPointerPosition(d,t).x;i.getPlayer(e).controlBar.durationDisplay.options_.playerOptions.disableRemotePlayback=!1;var c=window.cast&&window.cast.framework&&window.cast.framework.CastSession,u=null===(n=window)||void 0===n||null===(o=n.cast)||void 0===o||null===(a=o.framework)||void 0===a||null===(r=a.CastContext)||void 0===r||null===(l=r.getInstance())||void 0===l?void 0:l.S;if(console.log(c),c&&"CONNECTED"===u){window.cast.framework.RemotePlayer.canSeek=!0;var v=new window.cast.framework.RemotePlayerController(window.cast.framework.RemotePlayer),m=v.b.media[0].liveSeekableRange.end;v.getSeekPosition(),window.cast.framework.RemotePlayer.currentTime=m*s,v.seek()}}))};return n({init:function(e){return new Promise((function(t,n){console.log(e);var i=null==e?void 0:e.videoId,a=null==e?void 0:e.token,r=null==e?void 0:e.playerId;!function(e){for(var t=0;t<e.length;t++){var n=e[t];y(n)}}(D),function(e,t){return o({url:"".concat(p).concat(h),params:{id:e,deviceType:"web_browser",contentConsumption:"web"},method:"GET",headers:{Authorization:t},withCredentials:!0}).then((function(e){return e.data})).catch((function(e){return e.response.data}))}(i,a).then((function(e){l(r,e,t)}))}))},getRenditions:function(e){var t,n=r(e),i=[];(null==n||null===(t=n.tech_)||void 0===t?void 0:t.vhs)||!1?i=n.tech_.vhs.representations().sort((function(e,t){return t.height-e.height})):i=n.dash.mediaPlayer.getBitrateInfoListFor("video").sort((function(e,t){return t.height-e.height}));return i},skip:t,reset:e,getPlayer:r,play:function(e){i(e).play()},pause:function(e){i(e).pause()}},"reset",e)}module.exports=E;
|
|
1
|
+
"use strict";require("video.js/dist/video-js.min.css");var e=require("@babel/runtime/helpers/asyncToGenerator"),t=require("@babel/runtime/helpers/defineProperty"),n=require("@babel/runtime/regenerator"),o=require("video.js"),i=require("./generic-8b99b151.js"),r=require("./util-fa21734a.js"),l=require("./renditions-bc841552.js"),a=require("./resolution-6a9adf54.js"),s=require("./skin-84083352.js");function u(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,o)}return n}function d(e){for(var n=1;n<arguments.length;n++){var o=null!=arguments[n]?arguments[n]:{};n%2?u(Object(o),!0).forEach((function(n){t(e,n,o[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):u(Object(o)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(o,t))}))}return e}require("axios"),require("js-cookie"),require("ua-parser-js"),require("@babel/runtime/helpers/toConsumableArray"),require("@babel/runtime/helpers/classCallCheck"),require("@babel/runtime/helpers/createClass"),require("@babel/runtime/helpers/assertThisInitialized"),require("@babel/runtime/helpers/inherits"),require("@babel/runtime/helpers/possibleConstructorReturn"),require("@babel/runtime/helpers/getPrototypeOf");var c,v,p=function(e,t){var n=i.getPlayer(e);n&&t&&n.controlBar&&n.controlBar.progressControl.seekBar.on("click",(function(t){var n,i,r,l,a,s=this.el(),u=o.dom.getPointerPosition(s,t).x;o.getPlayer(e).controlBar.durationDisplay.options_.playerOptions.disableRemotePlayback=!1;var d=window.cast&&window.cast.framework&&window.cast.framework.CastSession,c=null===(n=window)||void 0===n||null===(i=n.cast)||void 0===i||null===(r=i.framework)||void 0===r||null===(l=r.CastContext)||void 0===l||null===(a=l.getInstance())||void 0===a?void 0:a.S;if(console.log(d),d&&"CONNECTED"===c){window.cast.framework.RemotePlayer.canSeek=!0;var v=new window.cast.framework.RemotePlayerController(window.cast.framework.RemotePlayer),p=v.h.media[0].liveSeekableRange.end;v.getSeekPosition(),window.cast.framework.RemotePlayer.currentTime=p*u,v.seek()}}))};function m(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,o)}return n}var f=[],y=0,w=null;function h(e,n,o){var r,l,a,s=arguments.length>3&&void 0!==arguments[3]&&arguments[3];v=(null==n||null===(r=n.watchHistory)||void 0===r?void 0:r.apiVersion)||"v1";var u=null==n||null===(l=n.watchHistory)||void 0===l?void 0:l.profileId,d=Math.floor(e.currentTime()),p=Math.floor(e.duration()),f=null==n||null===(a=n.watchHistory)||void 0===a?void 0:a.xapiKey,h={};"v1"==v?h={videoId:c,watchedTime:Math.floor(e.currentTime()),watchedPercentage:Math.floor(d/p*100),siteOwner:n.siteOwner,userId:n.userId,xApiKey:f}:"v2"==v&&(h=function(e){for(var n=1;n<arguments.length;n++){var o=null!=arguments[n]?arguments[n]:{};n%2?m(Object(o),!0).forEach((function(n){t(e,n,o[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):m(Object(o)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(o,t))}))}return e}({videoId:c,watchedTime:Math.floor(e.currentTime()),watchedPercentage:s?100:Math.floor(d/p*100),doneWatching:s,profileId:u},w&&{seriesId:w})),i.saveWatchHistory(h,n.token,v).then((function(e){})).catch((function(e){})),y=d+o}var g=function(e,t,n){var o=i.getPlayer(e);if(o)if(t>=0&&t<=100){o.muted()&&o.muted(!1);var r=parseFloat(t)/100;o.volume(r),n&&n({status:!0,msg:"Volume set to ".concat(t,"%")})}else n&&n({status:!1,msg:"Please enter a valid volume percentage (0 ≥ V ≤ 100)"});else n({status:!1,msg:"Cannot find player with id: '".concat(e,"'")})},b=function(e){var t=i.getPlayer(e);return t?parseInt(100*t.volume())+"%":"Cannot find player with id: '".concat(e,"'")};function k(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,o)}return n}var O=function(e,n,o,r){var l,a,s=r.res,u=r.sres,d=i.getPlayer(e),v=(null==s||null===(l=s.video)||void 0===l||null===(a=l.streamingInfo)||void 0===a?void 0:a.isLiveStream)||!1;i.setCurrentVideo(s),d.on("timeupdate",(function(){var e,t;console.log("LIVE LATENCY : ",null==d||null===(e=d.dash)||void 0===e||null===(t=e.mediaPlayer)||void 0===t?void 0:t.getCurrentLiveLatency())})),d.on("loadstart",(function(){v&&o.resolve({status:!0,msg:"Video Loaded",response:s})})),d.on("loadeddata",(function(){var r;(null==d||!d.muted())&&g(e,sessionStorage.getItem("volume")||"100");var l,a,v=i.getCurrentVideo();(i.clearError(),o.resolve(function(e){for(var n=1;n<arguments.length;n++){var o=null!=arguments[n]?arguments[n]:{};n%2?k(Object(o),!0).forEach((function(n){t(e,n,o[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):k(Object(o)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(o,t))}))}return e}({status:!0,msg:"Player Initialised"},u?{seriesResponse:u,response:s}:{response:s})),null!=n&&n.watchHistory&&null!=n&&null!==(r=n.watchHistory)&&void 0!==r&&r.enable&&!n.isAnonymousUser)&&function(e,t,n){var o,r;null!=t&&t.series&&(w=null==t||null===(o=t.series)||void 0===o?void 0:o.id),f=[],y=0,c=n;var l=(null==t||null===(r=t.watchHistory)||void 0===r?void 0:r.interval)||30,a=i.getPlayer(e);a&&(a.on("timeupdate",(function(){var e=Math.floor(a.currentTime());f.includes(y)||(e==y?(f.push(e),h(a,t,l)):e>y&&(y=e+l))})),a.on("ended",(function(){h(a,t,l,!0)})))}(e,n,null==v||null===(l=v.video)||void 0===l||null===(a=l.gist)||void 0===a?void 0:a.id)})),d.textTracks().on("change",(function(e){var t=this.tracks_.filter((function(e){if("subtitles"===e.kind&&"showing"===e.mode)return!0}))[0];d.trigger("subtitlechanged",t)})),d.on("subtitlechanged",(function(e,t){var n,o,i,r,l,a,s,u,d,c,v=window.cast&&window.cast.framework&&window.cast.framework.CastSession,p=null===(n=window)||void 0===n||null===(o=n.cast)||void 0===o||null===(i=o.framework)||void 0===i||null===(r=i.CastContext)||void 0===r||null===(l=r.getInstance())||void 0===l?void 0:l.S,m=null===(a=window)||void 0===a||null===(s=a.cast)||void 0===s||null===(u=s.framework)||void 0===u||null===(d=u.CastContext)||void 0===d||null===(c=d.getInstance())||void 0===c?void 0:c.getCurrentSession();if(v&&"CONNECTED"===p){var f,y=m.getMediaSession(),w=y.media.tracks.filter((function(e){return"TEXT"==e.type}));f=t?new chrome.cast.media.EditTracksInfoRequest([w[0].trackId]):new chrome.cast.media.EditTracksInfoRequest([]),y.editTracksInfo(f)}})),d.on("loadedmetadata",(function(){})),d.one("error",(function(){var t,n;i.handleError(e,(null==d||null===(t=d.error())||void 0===t?void 0:t.message)||"Some error occured"),o.reject({status:!1,msg:(null==d||null===(n=d.error())||void 0===n?void 0:n.message)||"Some error occured"})})),d.one("play",(function(){var e;if(null!=n&&null!==(e=n.series)&&void 0!==e&&e.enable){var t,o,r,l=null===(t=i.getCurrentVideo())||void 0===t||null===(o=t.video)||void 0===o||null===(r=o.gist)||void 0===r?void 0:r.id,a=i.getSeriesWatchMap().get(l)||{t:0,p:0},s=a.t,u=a.p;s&&u<95&&setTimeout((function(){d.currentTime(s)}),0)}else null!=n&&n.watchHistoryResumeTime&&(null==n?void 0:n.watchedPercentage)<95&&d.currentTime(null==n?void 0:n.watchHistoryResumeTime)})),d.on("volumechange",(function(){var e=100*d.volume().toFixed(2);d.muted()?sessionStorage.setItem("volume",0):sessionStorage.setItem("volume",e)}))},P=function(e,t){var n=null==t?void 0:t.skin;"live"==n?Promise.resolve().then((function(){return require("./skin-93a3e5ae.js")})).then((function(n){n.initialiseSkin(e,t)})):"default"==n?Promise.resolve().then((function(){return require("./skin-39ab30e2.js")})).then((function(n){n.initialiseSkin(e,t)})):"carousel"==n?Promise.resolve().then((function(){return require("./skin-ec49b877.js")})).then((function(t){t.initaliseSkin(e)})):"defaultV2"==n?Promise.resolve().then((function(){return require("./skin-095cc078.js")})).then((function(n){n.initialiseSkin(e,t)})):"multiplayer"==n&&Promise.resolve().then((function(){return require("./skin-fb394911.js")})).then((function(n){n.initialiseSkin(e,t)}))},j=function(e){return new Promise((function(t,n){if(I(e))n("".concat(e," is alread initialised"));else{var o=document.createElement("script");o.async=!1,o.src=e,o.onload=function(){t()},o.onerror=function(t){n("Error while loading script ".concat(e," : ").concat(t))},document.head.appendChild(o)}}))},I=function(e){return document.querySelectorAll('script[src="'.concat(e,'"]')).length>0};function S(){var e,t;null===(e=window)||void 0===e||null===(t=e.dataLayer)||void 0===t||t.push(arguments)}var C=function(e,t){t.controlBar.el_.style.color=e,t.controlBar.el_.querySelector(".vjs-play-progress")&&(t.controlBar.el_.querySelector(".vjs-play-progress").style.backgroundColor=e),t.controlBar.el_.querySelector(".vjs-volume-level")&&(t.controlBar.el_.querySelector(".vjs-volume-level").style.backgroundColor=e)};var T,D=function(){var t=e(n.mark((function e(){return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,import("videojs-contrib-dash");case 2:j("https://cdn.dashjs.org/v4.7.3/dash.all.min.js").then((function(){})).catch((function(e){return console.log(e)}));case 3:case"end":return e.stop()}}),e)})));return function(){return t.apply(this,arguments)}}(),E=function(){var t=e(n.mark((function e(){return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,import("videojs-contrib-eme");case 2:case"end":return e.stop()}}),e)})));return function(){return t.apply(this,arguments)}}(),V=Object.freeze({__proto__:null,importChromecast:function(){import("@silvermine/videojs-chromecast").then((function(e){j("https://www.gstatic.com/cv/js/sender/v1/cast_sender.js?loadCastFramework=1").then((function(){e.default(o)})).catch((function(e){console.log(e)}))}))},importAirplay:function(){import("@silvermine/videojs-airplay").then((function(e){e.default(o)}))},importIMA:function(){import("videojs-contrib-ads"),import("videojs-ima"),j("https://imasdk.googleapis.com/js/sdkloader/ima3.js").then((function(){})).catch((function(e){return console.log(e)}))},loadDashLibrary:D,loadEMELibrary:E});function R(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,o)}return n}function x(e){for(var n=1;n<arguments.length;n++){var o=null!=arguments[n]?arguments[n]:{};n%2?R(Object(o),!0).forEach((function(n){t(e,n,o[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):R(Object(o)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(o,t))}))}return e}var q=function(r,l,a,s){var u,c,v,m,f,y,w,h,g,b,k,j,I,S,T,V,R,q,B,A,L,H,N,M=l.res,_=void 0===M?null:M,U=l.sres,F=void 0===U?null:U;localStorage.setItem("LATENCY",3);var W=(null===(u=window)||void 0===u||null===(c=u.cast)||void 0===c||null===(v=c.framework)||void 0===v||null===(m=v.CastContext)||void 0===m||null===(f=m.getInstance())||void 0===f?void 0:f.S)||void 0,z=null!=a&&a.chromecastReceiverId?"NO_DEVICES_AVAILABLE"!==W&&"NOT_CONNECTED"!==W?["html5","chromecast"]:["chromecast","html5"]:["html5"],J=null==_||null===(y=_.video)||void 0===y||null===(w=y.gist)||void 0===w?void 0:w.videoImageUrl,Y=(null==_||null===(h=_.video)||void 0===h||null===(g=h.liveDetails)||void 0===g?void 0:g.isDvrEnabled)||!1,K=function(e){var t,n={};return null!=e&&e.series||null!=e&&e.chromecastReceiverId&&null!==(t=window)&&void 0!==t&&t.cast&&(n={chromecast:{receiverAppID:null==e?void 0:e.chromecastReceiverId,addButtonToControlBar:"default"==e.skin||"defaultV2"==e.skin,buttonPositionIndex:-5,addCastLabelToButton:!0}}),null!=e&&e.airplay&&"Safari"==i.detectBrowser()&&(n=d(d({},n),{},{airPlay:{addButtonToControlBar:"default"==e.skin,buttonPositionIndex:-6}})),n}(a),X=(null==_||null===(b=_.video)||void 0===b||null===(k=b.streamingInfo)||void 0===k?void 0:k.isLiveStream)||!1,G=(null==a?void 0:a.drmLibrary)||!1,Q=(null==_||null===(j=_.ads)||void 0===j||null===(I=j.preRoll)||void 0===I||null===(S=I.adTags)||void 0===S||null===(T=S.web)||void 0===T?void 0:T.active)&&(null==_||null===(V=_.ads)||void 0===V||null===(R=V.preRoll)||void 0===R||null===(q=R.adTags)||void 0===q||null===(B=q.web)||void 0===B?void 0:B.url),Z=(N={controls:0!=(null==a?void 0:a.controls),playsinline:!0,fluid:!0,muted:(null==a?void 0:a.muted)||!1,autoplay:(null==a?void 0:a.autoplay)||!1,controlBar:{volumePanel:("default"==a.skin||"defaultV2"==a.skin||"live"==(null==a?void 0:a.skin))&&{inline:!1},fullscreenToggle:"default"==a.skin||"defaultV2"==a.skin,audioTrackButton:!1,pictureInPictureToggle:(a.skin,!1)},muteToggle:"multiplayer"==a.skin,liveui:Y},t(N,"autoplay",null==a?void 0:a.autoplay),t(N,"normalizeAutoplay",(null==a?void 0:a.autoplay)&&!Q),t(N,"loop",(null==a?void 0:a.loop)||!1),t(N,"html5",x(x({dash:{updateSettings:{lowLatencyEnabled:!0,streaming:{delay:{liveDelay:localStorage.getItem("LATENCY")||3},liveCatchup:{maxDrift:0,playbackRate:{min:-.1,max:.1}},abr:{additionalAbrRules:{insufficientBufferRule:!0,switchHistoryRule:!0,droppedFramesRule:!0}}}}},vhs:x(x({experimentalLLHLS:(null==a?void 0:a.lowLatency)||!1,limitRenditionByPlayerDimensions:!0,useDevicePixelRatio:!0,useNetworkInformationApi:!0},(null==a||null===(A=a.customData)||void 0===A?void 0:A.overrideNative)&&{overrideNative:!0}),{},{enableLowInitialPlaylist:(null==a?void 0:a.enableLowInitialPlaylist)||!1,experimentalBufferBasedABR:(null==a?void 0:a.experimentalBufferBasedABR)||!1})},0==(null==a||null===(L=a.customData)||void 0===L?void 0:L.nativeAudioTracks)&&{nativeAudioTracks:!1}),0==(null==a||null===(H=a.customData)||void 0===H?void 0:H.nativeVideoTracks)&&{nativeVideoTracks:!1})),t(N,"poster",J),t(N,"techOrder",z),t(N,"chromecast",{requestCustomDataFn:function(e){var t=i.getPlayer(r);console.log(t.textTracksJson_);var n=t.textTracksJson_.filter((function(e){return"subtitles"==e.kind}));return function(e,t,n){var o,i,r,l,a,s,u,d,c,v,p={};if(e&&e.video&&e.video.drmEnabled){p.isDrmEnabled=!0;var m=t.keySystemOptions&&t.keySystemOptions[0]&&t.keySystemOptions[0].options&&t.keySystemOptions[0].options.serverURL;p.licenseUrl=m;var f=t.keySystemOptions&&t.keySystemOptions[0]&&t.keySystemOptions[0].options&&t.keySystemOptions[0].options.httpRequestHeaders["X-AxDRM-Message"];p.licenseToken=f}var y=(null==e||null===(o=e.video)||void 0===o||null===(i=o.gist)||void 0===i?void 0:i.contentType)||"VIDEO";p.contentType=y;var w=null==e||null===(r=e.video)||void 0===r||null===(l=r.gist)||void 0===l?void 0:l.runtime;p.duration=w;var h=null==e||null===(a=e.video)||void 0===a||null===(s=a.gist)||void 0===s?void 0:s.title;p.mediaTitle=h;var g=null==e||null===(u=e.video)||void 0===u||null===(d=u.gist)||void 0===d?void 0:d.videoImageUrl;return p.mediaImage=g,p.subTitles=n,p.DVR=(null==e||null===(c=e.video)||void 0===c||null===(v=c.liveDetails)||void 0===v?void 0:v.isDvrEnabled)||!1,console.log(p),p}(_,e,n)}}),t(N,"plugins",K),N),$=o(r,Z,function(){var t=e(n.mark((function e(){var t,l,u,d,c,v,m,f,y,w,h,g,b,k,j,I,S;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(X&&s.resolve(x({status:!0,msg:"Player Initialised"},F?{seriesResponse:F,response:_}:{response:_})),"white"!==window.controlsColor&&C(window.controlsColor,$),/Android/i.test(navigator.userAgent)&&(o.options.vhs.overrideNative=!0),w=null==_||null===(t=_.video)||void 0===t?void 0:t.drmEnabled,h=null==_||null===(l=_.video)||void 0===l||null===(u=l.liveDetails)||void 0===u?void 0:u.startOverTime,!w&&!G){e.next=13;break}if("Safari"!==i.detectBrowser()){e.next=11;break}return e.next=9,E();case 9:e.next=13;break;case 11:return e.next=13,Promise.all([E(),D()]);case 13:Y&&p(r,h),!Q||null!=a&&null!==(d=a.customData)&&void 0!==d&&d.disableAds||i.initialiseAdvertisement(r,Q,_),g=i.getSource(_,r),"IN"==a.countryCode&&(o.Vhs.xhr.beforeRequest=function(e){e.uri=e.uri.replace("us-e","a-m")}),g?i.loadVideo(r,g):(s.reject({status:!1,msg:"Incompatible Source, only hls,mp4,drm content is allowed",response:_}),i.handleError(r,"Incompatible Source, only hls,mp4,drm content is allowed")),((null==_||null===(c=_.video)||void 0===c||null===(v=c.contentDetails)||void 0===v||null===(m=v.closedCaptions)||void 0===m?void 0:m.length)>0||(null==_||null===(f=_.video)||void 0===f||null===(y=f.closedCaptions)||void 0===y?void 0:y.length)>0)&&(S=(null==_||null===(k=_.video)||void 0===k||null===(j=k.contentDetails)||void 0===j?void 0:j.closedCaptions)||(null==_||null===(I=_.video)||void 0===I?void 0:I.closedCaptions),b=S.filter((function(e){return"VTT"===e.format})),i.addCaptions(r,b)),null!=a&&a.disableControls?i.disableControls(r):P(r,x(x(x({},a),Z),{},{liveVideo:X,isDvrEnabled:Y,res:_,sres:F})),O(r,x(x(x({},a),Z),{},{liveVideo:X}),s,{res:_,sres:F});case 21:case"end":return e.stop()}}),e)})));return function(){return t.apply(this,arguments)}}())};module.exports=function(){return{loadVideoInstantly:i.loadVideoInstantly,onTimeUpdate:r.onTimeUpdate,getVideoDuration:r.getVideoDuration,onVideoEnded:r.onVideoEnded,init:function(e){return new Promise((function(t,n){var o,r,l,a,u,d,c,v,p;if(!i.isPlayerInitialised(null==e?void 0:e.playerId)){var m=null==e?void 0:e.videoId,f=(null==e||null===(o=e.series)||void 0===o?void 0:o.enable)||!1;window.videoId=m;var y=null==e?void 0:e.token;if(y&&!i.isTokenExpired(y)){T=JSON.parse(atob(y.split(".")[1])),window.siteId=null===(r=T)||void 0===r?void 0:r.siteId,window.siteName=null===(l=T)||void 0===l?void 0:l.site,e.isAnonymousUser=!(null===(a=T)||void 0===a||!a.anonymousId),e.siteOwner=(null===(u=T)||void 0===u?void 0:u.site)||null,e.userId=(null===(d=T)||void 0===d?void 0:d.userId)||null,window.sessionStorage.setItem("uid",null===(c=T)||void 0===c?void 0:c.userId),window.watchHistory=e.watchHistory||null,sessionStorage.setItem("token",y);var w=null==e?void 0:e.playerId,h=e.chromecastReceiverId=null!=e&&e.series?null:null==e?void 0:e.chromecastReceiverId,g=null==e?void 0:e.airplay,b=null==e?void 0:e.apiBaseUrl,k=(null==e||null===(v=e.analytics)||void 0===v?void 0:v.gaId)||null,O=null==e?void 0:e.errors;O&&(window.customErrors=O),window.customData=null==e?void 0:e.customData,b&&(window.playerEntitlementUrl=b),window.controlsColor=(null==e?void 0:e.controlsColor)||"white",null!=e&&e.skin&&!s.isNotAValidSkin(e.skin)||(e.skin="defaultV2"),Promise.resolve().then((function(){return V})).then((function(e){e.importIMA()})),!h||null!=e&&e.series||Promise.resolve().then((function(){return V})).then((function(e){e.importChromecast()})),g&&"Safari"==i.detectBrowser()&&Promise.resolve().then((function(){return V})).then((function(e){e.importAirplay()})),k&&j("https://www.googletagmanager.com/gtag/js?id=".concat(k)).then((function(){return e=k,window.dataLayer=window.dataLayer||[],S("js",new Date),void S("config",e);var e})).catch((function(e){}));var P=null===(p=document)||void 0===p?void 0:p.getElementById("".concat(w));if(P&&P.addEventListener("contextmenu",(function(e){return e.preventDefault()})),f){var I,C=null==e||null===(I=e.series)||void 0===I?void 0:I.id;i.getSeriesDetails(C,y).then((function(o){var r,l,a,s=o.data,u=o.data.seasons;i.setCurrentSeries(u);var d=m||(null==u||null===(r=u[0])||void 0===r||null===(l=r.episodes)||void 0===l||null===(a=l[0])||void 0===a?void 0:a.id);!function(e,t){var n=new Map;i.getSeriesWatchHistory({videoId:e,token:t}).then((function(e){e.data.map((function(e){n.set(e.videoId,{t:e.watchedTime,p:e.watchedPercentage})})),i.setSeriesWatchMap(n)})).catch((function(e){return console.log(e)}))}(C,y),i.getVideoDetails(d,y).then((function(o){var r,l,a;window.contentType=null==o||null===(r=o.data)||void 0===r||null===(l=r.video)||void 0===l||null===(a=l.gist)||void 0===a?void 0:a.contentType,i.setCurrentVideo(o.data),q(w,{res:null==o?void 0:o.data,sres:s},e,{resolve:t,reject:n})})).catch((function(e){i.initiateErrorHandling(e,w,n,m)}))})).catch((function(e){i.initiateErrorHandling(e,w,n)}))}else i.getVideoDetails(m,y).then((function(o){var r,l,a,s;window.contentType=null==o||null===(r=o.data)||void 0===r||null===(l=r.video)||void 0===l||null===(a=l.gist)||void 0===a?void 0:a.contentType,i.setCurrentVideo(null==o?void 0:o.data);var u=null==o?void 0:o.data;null!=e&&e.watchHistory&&null!=e&&null!==(s=e.watchHistory)&&void 0!==s&&s.enable?i.getVideoInfo(m,y).then((function(o){var i,r,l,a,s,d;null!==(i=window)&&void 0!==i&&null!==(r=i.watchHistory)&&void 0!==r&&r.cb&&(null===(l=window)||void 0===l||null===(a=l.watchHistory)||void 0===a||a.cb(null==o?void 0:o.data)),e.watchHistoryResumeTime=(null==o||null===(s=o.data)||void 0===s?void 0:s.watchedTime)||null,e.watchedPercentage=(null==o||null===(d=o.data)||void 0===d?void 0:d.watchedPercentage)||null,q(w,{res:u},e,{resolve:t,reject:n})})).catch((function(o){var i,r,l,a;null!==(i=window)&&void 0!==i&&null!==(r=i.watchHistory)&&void 0!==r&&r.cb&&(null===(l=window)||void 0===l||null===(a=l.watchHistory)||void 0===a||a.cb(o)),q(w,{res:u},e,{resolve:t,reject:n})})):q(w,{res:u},e,{resolve:t,reject:n})})).catch((function(e){i.initiateErrorHandling(e,w,n,m)}))}else n({status:!1,msg:"".concat(y?"Token is expired !":"Missing Authorization Token"),response:{token:y}})}}))},getRenditions:l.getRenditions,skip:i.skip,getPlayer:i.getPlayer,play:i.play,pause:i.pause,detectBrowser:i.detectBrowser,rewind:i.rewind,loadVideo:i.loadVideo,seekToTimeStamp:r.seekToTimeStamp,isPlayerInitialised:i.isPlayerInitialised,load:i.load,dispose:i.dispose,enableCaptions:i.enableCaptions,disableCaptions:i.disableCaptions,getCaptions:i.getCaptions,playSelectedResolution:a.playSelectedResolution,getSource:i.getSource,setVolume:g,getVolume:b,disableControls:i.disableControls,setPlaybackSpeed:r.setPlaybackSpeed}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("./generic-
|
|
1
|
+
"use strict";var e=require("./generic-8b99b151.js");exports.initialiseKeyboardEvents=function(r,t){var i,u,l=e.getPlayer(r),n=null==l||null===(i=l.controlBar)||void 0===i||null===(u=i.playToggle)||void 0===u?void 0:u.el_,o=document.getElementsByTagName("video")[0];o&&o.addEventListener("keydown",(function(i){switch(i.key){case" ":return i.preventDefault(),o&&o.focus(),void(n&&n.click());case"m":case"M":return i.preventDefault(),o&&o.focus(),void(l.muted()?l.muted(!1):l.muted(!0));case"f":i.preventDefault(),o&&o.focus();var u=document.querySelector(".vjs-fullscreen-control");return void(u&&u.click());case"F":i.preventDefault();var c=document.querySelector(".vjs-fullscreen-control");return void(c&&c.click());case"ArrowLeft":if((1==t.liveVideo||1==t.liveui)&&0==t.liveui)break;return i.preventDefault(),o&&o.focus(),void e.rewind(r,10);case"ArrowRight":if(1==t.liveVideo||1==t.liveui)break;return i.preventDefault(),o&&o.focus(),void e.skip(r,10);default:return}}))};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("@babel/runtime/helpers/classCallCheck"),t=require("@babel/runtime/helpers/createClass"),i=require("@babel/runtime/helpers/assertThisInitialized"),l=require("@babel/runtime/helpers/inherits"),n=require("@babel/runtime/helpers/possibleConstructorReturn"),r=require("@babel/runtime/helpers/getPrototypeOf"),o=require("@babel/runtime/helpers/defineProperty"),s=require("video.js"),u=require("./loader-393b838a.js"),a=require("./generic-
|
|
1
|
+
"use strict";var e=require("@babel/runtime/helpers/classCallCheck"),t=require("@babel/runtime/helpers/createClass"),i=require("@babel/runtime/helpers/assertThisInitialized"),l=require("@babel/runtime/helpers/inherits"),n=require("@babel/runtime/helpers/possibleConstructorReturn"),r=require("@babel/runtime/helpers/getPrototypeOf"),o=require("@babel/runtime/helpers/defineProperty"),s=require("video.js"),u=require("./loader-393b838a.js"),a=require("./generic-8b99b151.js");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 i,l=r(e);if(t){var o=r(this).constructor;i=Reflect.construct(l,arguments,o)}else i=l.apply(this,arguments);return n(this,i)}}require("axios"),require("js-cookie"),require("ua-parser-js");var d=s.getComponent("Component"),v=function(n){l(v,d);var r=c(v);function v(t){var l,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e(this,v),l=r.call(this,t,n),o(i(l),"multicamCssPositioning",(function(e,t){var n,r,o,s,u,a,c,d,v=window.getComputedStyle(document.getElementById(t),null),f=v.getPropertyValue("height"),m=v.getPropertyValue("width"),h=f.slice(0,-2);m.slice(0,-2)-135<=135?(e.style.bottom="290px",e.style.height="352px"):"live"==l.config.skin&&(null===(n=i(l))||void 0===n||null===(r=n.config)||void 0===r||!r.liveui)&&(null===(o=i(l))||void 0===o||null===(s=o.config)||void 0===s||!s.liveVideo)||null!==(u=i(l))&&void 0!==u&&null!==(a=u.config)&&void 0!==a&&a.liveui&&null!==(c=i(l))&&void 0!==c&&null!==(d=c.config)&&void 0!==d&&d.liveVideo?(e.style.bottom="".concat(h-135,"px"),e.style.height="".concat(h-85,"px")):(e.style.bottom="3rem",e.style.height="".concat(h-105,"px"))})),l.playerId=n.playerId,l.streams=null==n?void 0:n.streams,l.config=null==n?void 0:n.config,l.createUI(null==n?void 0:n.streams),l}return t(v,[{key:"createEl",value:function(){return s.dom.createEl("div",{className:"multicamera-parent"})}},{key:"createUI",value:function(e){var t,i,l,n,r,o,s=this,u=this.el();null!=this&&null!==(t=this.config)&&void 0!==t&&t.liveui&&null!=this&&null!==(i=this.config)&&void 0!==i&&i.liveVideo||0==(null==this||null===(l=this.config)||void 0===l?void 0:l.liveui)&&0==(null==this||null===(n=this.config)||void 0===n?void 0:n.liveVideo)?null==u||null===(r=u.classList)||void 0===r||r.add("".concat(this.config.skin)):null==u||null===(o=u.classList)||void 0===o||o.add("default"),this.loadCSS();for(var a=0;a<e.length;a++)this.createTile(e[a],a);this.multicamCssPositioning(u,this.playerId),window.onresize=function(){s.multicamCssPositioning(u,s.playerId)}}},{key:"getOffset",value:function(e){var t=e.getBoundingClientRect();return{left:t.left+window.scrollX,top:t.top+window.scrollY}}},{key:"createTile",value:function(e,t){var i=this,l=this.el(),n=s.dom.createEl("div",{className:"tile ".concat(t)});0==t&&(n.style.border="2px solid red"),n.style.backgroundImage="url(".concat(e.img,")"),s.dom.appendContent(l,n);var r=sessionStorage.getItem("token");return n.addEventListener("click",(function(t){u.showLoader(i.playerId),i.removeSelectedTile();var l=document.getElementsByClassName("".concat(t.srcElement.className))[0];l&&(l.style.border="2px solid red"),a.load(i.playerId,e.id,r).then((function(e){a.play(i.playerId)}))})),l}},{key:"removeSelectedTile",value:function(){for(var e=document.getElementsByClassName("tile"),t=0;t<e.length;t++)e[t].style.border=0}},{key:"loadCSS",value:function(){Promise.resolve().then((function(){return require("./multicam-a41fe4a6.js")})).then((function(e){var t=document.createElement("style");t.id="multicam",t.append("".concat(e.default)),document.head.appendChild(t)}))}}]),v}();exports.default=v;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("@babel/runtime/helpers/classCallCheck"),t=require("@babel/runtime/helpers/createClass"),r=require("@babel/runtime/helpers/inherits"),n=require("@babel/runtime/helpers/possibleConstructorReturn"),a=require("@babel/runtime/helpers/getPrototypeOf"),s=require("video.js"),o=require("./icons-
|
|
1
|
+
"use strict";var e=require("@babel/runtime/helpers/classCallCheck"),t=require("@babel/runtime/helpers/createClass"),r=require("@babel/runtime/helpers/inherits"),n=require("@babel/runtime/helpers/possibleConstructorReturn"),a=require("@babel/runtime/helpers/getPrototypeOf"),s=require("video.js"),o=require("./icons-7afb9c13.js"),l=require("./generic-8b99b151.js"),i=require("./skin-84083352.js");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 r,s=a(e);if(t){var o=a(this).constructor;r=Reflect.construct(s,arguments,o)}else r=s.apply(this,arguments);return n(this,r)}}require("@babel/runtime/helpers/defineProperty"),require("axios"),require("js-cookie"),require("ua-parser-js"),require("@babel/runtime/helpers/toConsumableArray");var d=s.getComponent("Component"),u=function(n){r(u,d);var a=c(u);function u(t){var r,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e(this,u),(r=a.call(this,t,n)).playerId=n.playerId,r.seriesData=n.sres,r.streams=n.streams,r.currentVideoData=n.res,r.initialiseStructure(),r.loadCSS(),r}return t(u,[{key:"createEl",value:function(){var e=s.dom.createEl("div",{className:"stream-selection vjs-control vjs-button"});e.style.position="unset";var t=s.dom.createEl("div",{className:"stream-selector-icon",innerHTML:"".concat(o.BroadcastIcon())});return s.dom.appendContent(e,t),e}},{key:"loadCSS",value:function(){Promise.resolve().then((function(){return require("./multicamv2-76d8530b.js")})).then((function(e){var t=document.createElement("style");t.id="multicam-v2",t.append("".concat(e.default)),document.head.appendChild(t)}))}},{key:"initialiseStructure",value:function(){var e=this.el(),t=s.dom.createEl("div",{className:"stream-container hidden"});s.dom.$(".stream-selector-icon",this.el()).onclick=function(){var r;null!==(r=t.classList)&&void 0!==r&&r.contains("hidden")?(i.closeOpenDrawers(),t.classList.remove("hidden"),e.classList.add("open"),t.style.right="0px"):(t.classList.add("hidden"),e.classList.remove("open"),t.style.right="-350px")};var r=window.getComputedStyle(document.getElementById(this.playerId),null).getPropertyValue("height").slice(0,-2);t.style.height="".concat(r,"px"),document.getElementById(this.playerId).style.overflow="hidden",s.dom.appendContent(e,t),this.addFunctionality(t)}},{key:"addFunctionality",value:function(e){var t=this,r=this.el(),n=s.dom.createEl("div",{className:"stream-selector-head"}),a=s.dom.createEl("div",{className:"stream-selector-cross-icon",innerHTML:"".concat(o.crossIconSvg())});a.onclick=function(){e.classList.add("hidden"),r.classList.remove("open"),e.style.right="-350px"};for(var i=s.dom.createEl("div",{className:"stream-selector-title",innerHTML:"Streams"}),c=s.dom.createEl("div",{className:"stream-selector-content"}),d=s.dom.createEl("div",{className:"stream-tray"}),u=function(e){var r,n=s.dom.createEl("div",{className:"stream -".concat(e),innerHTML:"".concat(o.SelectedStream())});0==e&&(n.classList.add("selected"),n.style.border="4px solid #D2393B"),n.onclick=function(){for(var r=s.dom.$$(".stream"),a=0;a<r.length;a++)r[a].style.border="none",r[a].classList.remove("selected");n.classList.add("selected"),n.style.border="4px solid #D2393B",l.load(t.playerId,t.streams[e].id,sessionStorage.getItem("token")).then((function(e){l.play(t.playerId),console.log(e)})).catch((function(e){console.log(e)}))},n.style.backgroundImage="url(".concat(t.streams[e].img,")");var a=document.createElement("img");a.className="stream-thumbnail-image",a.src="".concat(null==t||null===(r=t.streams[e])||void 0===r?void 0:r.img),a.alt="No Thumbnail Available",n.append(a),s.dom.appendContent(d,n),s.dom.appendContent(c,d)},m=0;m<this.streams.length;m++)u(m);s.dom.appendContent(n,a),s.dom.appendContent(n,i),s.dom.appendContent(e,n),s.dom.appendContent(e,c),l.getPlayer(this.playerId).on("fullscreenchange",(function(){var r=window.getComputedStyle(document.getElementById(t.playerId),null).getPropertyValue("height").slice(0,-2);e.style.height="".concat(r,"px")}))}}]),u}();exports.default=u;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("@babel/runtime/helpers/classCallCheck"),t=require("@babel/runtime/helpers/createClass"),l=require("@babel/runtime/helpers/inherits"),r=require("@babel/runtime/helpers/possibleConstructorReturn"),n=require("@babel/runtime/helpers/getPrototypeOf"),o=require("video.js"),s=require("./loader-393b838a.js"),i=require("./generic-
|
|
1
|
+
"use strict";var e=require("@babel/runtime/helpers/classCallCheck"),t=require("@babel/runtime/helpers/createClass"),l=require("@babel/runtime/helpers/inherits"),r=require("@babel/runtime/helpers/possibleConstructorReturn"),n=require("@babel/runtime/helpers/getPrototypeOf"),o=require("video.js"),s=require("./loader-393b838a.js"),i=require("./generic-8b99b151.js");function a(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 l,o=n(e);if(t){var s=n(this).constructor;l=Reflect.construct(o,arguments,s)}else l=o.apply(this,arguments);return r(this,l)}}require("@babel/runtime/helpers/defineProperty"),require("axios"),require("js-cookie"),require("ua-parser-js");var c=o.getComponent("Component"),d=function(r){l(d,c);var n=a(d);function d(t){var l,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e(this,d),(l=n.call(this,t,r)).playerId=r.playerId,l.config=r.config,l.createUI(null==r?void 0:r.config.streams),l}return t(d,[{key:"createEl",value:function(){return o.dom.createEl("div",{className:"mweb-potrait-parent"})}},{key:"createUI",value:function(e){var t,l,r,n,s,i,a,c,d=this.el(),u=1==(null==this||null===(t=this.config)||void 0===t?void 0:t.liveui)&&1==(null==this||null===(l=this.config)||void 0===l?void 0:l.liveVideo)||!(null!=this&&null!==(r=this.config)&&void 0!==r&&r.liveui)&&!(null!=this&&null!==(n=this.config)&&void 0!==n&&n.liveVideo)||!1;u?null==d||null===(s=d.classList)||void 0===s||s.add("dvr"):null==d||null===(i=d.classList)||void 0===i||i.add("nondvr");var v=o.dom.createEl("div",{className:"broadcast"});v.innerHTML="Broadcasts";var m=o.dom.createEl("div",{className:"potraittray hideMWebTray"});u?null==m||null===(a=m.classList)||void 0===a||a.add("dvr"):null==m||null===(c=m.classList)||void 0===c||c.add("nondvr"),m.style.width="".concat(window.innerWidth-50,"px");var h=o.dom.createEl("div",{className:"tilecontainer-potrait"});o.dom.appendContent(d,v),o.dom.appendContent(d,m),o.dom.appendContent(m,h),v.addEventListener("click",(function(){null!=m&&m.classList.contains("hideMWebTray")?(m.classList.remove("hideMWebTray"),d.style.background="darkgray"):(null==m||m.classList.add("hideMWebTray"),d.style.background="gray")})),this.loadCSS();for(var p=0;p<e.length;p++)this.createTile(e[p],p)}},{key:"createTile",value:function(e,t){var l=this,r=this.el(),n=o.dom.createEl("div",{className:"tile-potrait-mweb ".concat(t)});0==t&&(n.style.border="2px solid red"),n.style.backgroundImage="url(".concat(e.img,")");var a=o.dom.$(".tilecontainer-potrait",this.contentEl());o.dom.appendContent(a,n);var c=sessionStorage.getItem("token");return n.addEventListener("click",(function(t){s.showLoader(l.playerId),l.removeSelectedTile();var r=document.getElementsByClassName("".concat(t.srcElement.className))[0];r&&(r.style.border="2px solid red"),i.load(l.playerId,e.id,c).then((function(e){i.play(l.playerId)}))})),r}},{key:"removeSelectedTile",value:function(){for(var e=document.getElementsByClassName("tile-potrait-mweb"),t=0;t<e.length;t++)e[t].style.border=0}},{key:"loadCSS",value:function(){Promise.resolve().then((function(){return require("./mwebPotrait-3c11d7cf.js")})).then((function(e){var t=document.createElement("style");t.className="mweb",t.append("".concat(e.default)),document.head.appendChild(t)}))}},{key:"toggleProgressControls",value:function(e){var t=document.querySelector(".vjs-progress-control.vjs-control"),l=document.querySelector(".vjs-play-control.vjs-control.vjs-button"),r=document.querySelector(".vjs-remaining-time.vjs-time-control.vjs-control"),n=document.querySelector(".vjs-seek-to-live-control.vjs-control");e?(null==t||t.classList.add("hide-controls"),null==l||l.classList.add("hide-controls"),null==r||r.classList.add("hide-controls"),null==n||n.classList.add("hide-controls")):(null!=t&&t.classList.contains("hide-controls")&&(null==t||t.classList.remove("hide-controls")),null!=l&&l.classList.contains("hide-controls")&&(null==l||l.classList.remove("hide-controls")),null!=r&&r.classList.contains("hide-controls")&&(null==r||r.classList.remove("hide-controls")),null!=n&&n.classList.contains("hide-controls")&&(null==n||n.classList.remove("hide-controls")))}}]),d}();exports.default=d;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("@babel/runtime/helpers/classCallCheck"),t=require("@babel/runtime/helpers/createClass"),n=require("@babel/runtime/helpers/inherits"),i=require("@babel/runtime/helpers/possibleConstructorReturn"),r=require("@babel/runtime/helpers/getPrototypeOf"),o=require("video.js"),s=require("./icons-
|
|
1
|
+
"use strict";var e=require("@babel/runtime/helpers/classCallCheck"),t=require("@babel/runtime/helpers/createClass"),n=require("@babel/runtime/helpers/inherits"),i=require("@babel/runtime/helpers/possibleConstructorReturn"),r=require("@babel/runtime/helpers/getPrototypeOf"),o=require("video.js"),s=require("./icons-7afb9c13.js"),a=require("./generic-8b99b151.js");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,o=r(e);if(t){var s=r(this).constructor;n=Reflect.construct(o,arguments,s)}else n=o.apply(this,arguments);return i(this,n)}}require("@babel/runtime/helpers/defineProperty"),require("axios"),require("js-cookie"),require("ua-parser-js");var d=o.getComponent("Component"),u=function(i){n(a,d);var r=l(a);function a(t){var n,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e(this,a),(n=r.call(this,t,i)).playerId=i.playerId,n.seriesData=i.sres,n.currentVideoData=i.res,n.initialiseStructure(),n.loadCSS(),n}return t(a,[{key:"createEl",value:function(){var e=o.dom.createEl("div",{className:"play-next"}),t=o.dom.createEl("div",{className:"play-next-icon",innerHTML:"".concat(s.PlayNextEpisodeSvg(window.controlsColor?window.controlsColor:"white"))});return o.dom.appendContent(e,t),e}},{key:"loadCSS",value:function(){Promise.resolve().then((function(){return require("./nextEpisodeButton-b6e6586f.js")})).then((function(e){var t=document.createElement("style");t.id="multicam",t.append("".concat(e.default)),document.head.appendChild(t)}))}},{key:"initialiseStructure",value:function(){var e=this.el(),t=o.dom.createEl("div",{className:"next-eps nextepisode-hidden"}),n=o.dom.createEl("div",{className:"next",innerHTML:"Next Episode"}),i=o.dom.createEl("div",{className:"nextep-meta-details next-margin"}),r=o.dom.createEl("div",{className:"next-eps-image"}),s=o.dom.createEl("div",{className:"next-eps-description"});o.dom.appendContent(i,r),o.dom.appendContent(i,s),o.dom.appendContent(t,n),o.dom.appendContent(t,i),this.toggleContentOnHover(e,t),o.dom.appendContent(e,t)}},{key:"toggleContentOnHover",value:function(e,t){e.addEventListener("mouseover",(function(){o.dom.removeClass(t,"nextepisode-hidden")})),t.addEventListener("mouseover",(function(){o.dom.removeClass(t,"nextepisode-hidden")})),e.addEventListener("mouseout",(function(){o.dom.addClass(t,"nextepisode-hidden")})),t.addEventListener("mouseout",(function(){o.dom.addClass(t,"nextepisode-hidden")}))}}]),a}(),c=function(e,t){for(var n=-1,i=0;i<e.length;i++)for(var r=0;r<e[i].episodes.length;r++)if(e[i].episodes[r].id===t){n=i;break}return n},p=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1?arguments[1]:void 0;if(!(e&&t>=0))return{prevEp:null,nextEp:null};var n=e.episodes.length,i=t-1>=0?t-1:n-1,r=(t+1)%n,o=n>1?e.episodes[i]:null,s=n>1?e.episodes[r]:null;return i===r&&(0===i?s=null:o=null),{prevEp:o,nextEp:s,prevEpIdx:i,nextEpIdx:r}},m=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1?arguments[1]:void 0,n=null;return e?(e.episodes.forEach((function(e,i){e.gist.id===t&&(n=i)})),n):null},v=function(e){o.dom.$(".next-eps"),o.dom.$(".play-next").onclick=function(){var t=sessionStorage.getItem("token");a.load("my-player",e.gist.id,t).then((function(e){a.setCurrentVideo(e.response)}))},o.dom.$(".next-eps-image").innerHTML="<img src=".concat(e.gist.videoImageUrl,"/>"),o.dom.$(".next-eps-description").innerHTML="<div class='next-eps-title'>".concat(e.title,"</div>\n <div class='next-eps-description-details'>").concat(e.gist.description,"</div>")};exports.default=u,exports.initaliseFunctionality=function(e,t){var n=c(e,t.video.gist.id),i=m(e[n],t.video.gist.id),r=p(e[n],i);v(r.nextEp)};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("@babel/runtime/helpers/toConsumableArray"),t=require("@babel/runtime/helpers/classCallCheck"),n=require("@babel/runtime/helpers/createClass"),l=require("@babel/runtime/helpers/inherits"),i=require("@babel/runtime/helpers/possibleConstructorReturn"),o=require("@babel/runtime/helpers/getPrototypeOf"),a=require("video.js"),s=require("./icons-
|
|
1
|
+
"use strict";var e=require("@babel/runtime/helpers/toConsumableArray"),t=require("@babel/runtime/helpers/classCallCheck"),n=require("@babel/runtime/helpers/createClass"),l=require("@babel/runtime/helpers/inherits"),i=require("@babel/runtime/helpers/possibleConstructorReturn"),o=require("@babel/runtime/helpers/getPrototypeOf"),a=require("video.js"),s=require("./icons-7afb9c13.js"),r=require("./generic-8b99b151.js"),c=require("./autoNextVideo-823821e8.js"),d=require("./skin-84083352.js");function u(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,l=o(e);if(t){var a=o(this).constructor;n=Reflect.construct(l,arguments,a)}else n=l.apply(this,arguments);return i(this,n)}}require("@babel/runtime/helpers/defineProperty"),require("axios"),require("js-cookie"),require("ua-parser-js"),require("./util-fa21734a.js");var p=a.getComponent("Component"),m=function(i){l(m,p);var o=u(m);function m(e){var n,l,i,a,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t(this,m),(a=o.call(this,e,s)).playerId=s.playerId,a.seriesData=s.sres,a.videos=null==s||null===(n=s.playlist)||void 0===n?void 0:n.content,a.cb=(null==s||null===(l=s.playlist)||void 0===l?void 0:l.cb)||null,a.autoNext=(null==s||null===(i=s.playlist)||void 0===i?void 0:i.autoNext)||!1,a.currentVideoData=s.res,a.initialiseStructure(),a.loadCSS(),a.autoNext&&c.autoPlayNext({playerId:a.playerId,content:a.videos,cb:a.cb}),a}return n(m,[{key:"createEl",value:function(){var e=a.dom.createEl("div",{className:"playlist-selection vjs-control vjs-button"});e.style.position="unset";var t=a.dom.createEl("div",{className:"playlist-selector-icon",innerHTML:"".concat(s.EpisodesSvg())});return a.dom.appendContent(e,t),e}},{key:"loadCSS",value:function(){Promise.resolve().then((function(){return require("./playlist-df87ca90.js")})).then((function(e){var t=document.createElement("style");t.id="playlist-selection",t.append("".concat(e.default)),document.head.appendChild(t)}))}},{key:"initialiseStructure",value:function(){var e=this.el(),t=a.dom.createEl("div",{className:"selection-container hidden"});a.dom.$(".playlist-selector-icon",this.el()).onclick=function(){var n;null!==(n=t.classList)&&void 0!==n&&n.contains("hidden")?(d.closeOpenDrawers(),t.classList.remove("hidden"),e.classList.add("open"),t.style.right="0px"):(t.classList.add("hidden"),e.classList.remove("open"),t.style.right="-350px")};var n=window.getComputedStyle(document.getElementById(this.playerId),null).getPropertyValue("height").slice(0,-2);t.style.height="".concat(n,"px"),a.dom.appendContent(e,t),document.getElementById(this.playerId).style.overflow="hidden",this.addFunctionality(t)}},{key:"addFunctionality",value:function(t){var n=this,l=this.el(),i=a.dom.createEl("div",{className:"playlist-selector-head"}),o=a.dom.createEl("div",{className:"playlist-selector-cross-icon",innerHTML:"".concat(s.crossIconSvg())});o.onclick=function(){t.classList.add("hidden"),l.classList.remove("open"),t.style.right="-350px"};for(var c=a.dom.createEl("div",{className:"playlist-selector-title",innerHTML:"Playlist"}),d=a.dom.createEl("div",{className:"playlist-selector-content"}),u=function(t){var l,i,o=a.dom.createEl("div",{className:"playlist-container"}),s=a.dom.createEl("div",{className:"playlist-section",index:t}),c=a.dom.createEl("div",{className:"playlist-title",innerHTML:"".concat((null===(l=n.videos[t])||void 0===l?void 0:l.title)||"")}),u=a.dom.createEl("div",{className:"playlist-progress-bar",innerHTML:"<div style='width:".concat(n.videos[t].watchedPercentage,"%' class='playlist-progress-bar-value'></div>")});a.dom.appendContent(s,c),a.dom.appendContent(s,u),a.dom.appendContent(o,s),a.dom.appendContent(d,o);var p=a.dom.createEl("div",{className:"playlist-section-expanded hidden"}),m=a.dom.createEl("div",{className:"playlist-description",innerHTML:"".concat((null===(i=n.videos[t])||void 0===i?void 0:i.description)||"")}),v=a.dom.createEl("div",{className:"playlist-image"});v.style.backgroundImage="url(".concat(n.videos[t].img,")"),a.dom.appendContent(p,v),a.dom.appendContent(p,m),a.dom.appendContent(o,p),a.dom.appendContent(d,o),p.onclick=function(e){e.stopPropagation(),r.setVideoIdx(t+1),r.load(n.playerId,n.videos[t].id,sessionStorage.getItem("token")).then((function(e){null!=n&&n.cb&&n.cb(e)})).catch((function(e){null!=n&&n.cb&&n.cb(e)}))},s.onclick=function(t){var n,l,i,a=document.getElementsByClassName("playlist-selector-content")[0].childNodes,s=(a=e(a))[t.target.index].getElementsByClassName("playlist-section-expanded")[0];null!=s&&null!==(n=s.classList)&&void 0!==n&&n.contains("hidden")?(o.style.backgroundColor="#0000007d",null==s||null===(l=s.classList)||void 0===l||l.remove("hidden")):(null==s||null===(i=s.classList)||void 0===i||i.add("hidden"),o.style.backgroundColor="unset")}},p=0;p<this.videos.length;p++)u(p);a.dom.appendContent(i,o),a.dom.appendContent(i,c),a.dom.appendContent(t,i),a.dom.appendContent(t,d),r.getPlayer(this.playerId).on("fullscreenchange",(function(){var e=window.getComputedStyle(document.getElementById(n.playerId),null).getPropertyValue("height").slice(0,-2);t.style.height="".concat(e,"px")}))}}]),m}();exports.default=m;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var l=require("./generic-
|
|
1
|
+
"use strict";var l=require("./generic-8b99b151.js");exports.getRenditions=function(i){var n,e=l.getPlayer(i),t=[];if((null==e||null===(n=e.tech_)||void 0===n?void 0:n.vhs)||!1){var o,d,u=null==e||null===(o=e.tech_)||void 0===o||null===(d=o.vhs)||void 0===d?void 0:d.representations();(null==u?void 0:u.length)>0&&(t=null==u?void 0:u.sort((function(l,i){return(null==l?void 0:l.height)==(null==i?void 0:i.height)?(null==i?void 0:i.bandwidth)-(null==l?void 0:l.bandwidth):(null==i?void 0:i.height)-(null==l?void 0:l.height)})))}else{var v,r,h=null==e||null===(v=e.dash)||void 0===v||null===(r=v.mediaPlayer)||void 0===r?void 0:r.getBitrateInfoListFor("video");(null==h?void 0:h.length)>0&&(t=null==h?void 0:h.sort((function(l,i){return i.height-l.height})))}return t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("@babel/runtime/helpers/toConsumableArray"),t=require("@babel/runtime/helpers/classCallCheck"),n=require("@babel/runtime/helpers/createClass"),i=require("@babel/runtime/helpers/assertThisInitialized"),a=require("@babel/runtime/helpers/inherits"),o=require("@babel/runtime/helpers/possibleConstructorReturn"),d=require("@babel/runtime/helpers/getPrototypeOf"),l=require("@babel/runtime/helpers/defineProperty"),r=require("video.js"),s=require("./generic-
|
|
1
|
+
"use strict";var e=require("@babel/runtime/helpers/toConsumableArray"),t=require("@babel/runtime/helpers/classCallCheck"),n=require("@babel/runtime/helpers/createClass"),i=require("@babel/runtime/helpers/assertThisInitialized"),a=require("@babel/runtime/helpers/inherits"),o=require("@babel/runtime/helpers/possibleConstructorReturn"),d=require("@babel/runtime/helpers/getPrototypeOf"),l=require("@babel/runtime/helpers/defineProperty"),r=require("video.js"),s=require("./generic-8b99b151.js");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,i=d(e);if(t){var a=d(this).constructor;n=Reflect.construct(i,arguments,a)}else n=i.apply(this,arguments);return o(this,n)}}require("axios"),require("js-cookie"),require("ua-parser-js");var u=r.getComponent("Component"),h=function(o){a(h,u);var d=c(h);function h(n){var a,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t(this,h),a=d.call(this,n,o),l(i(a),"masterRenditions",[]),l(i(a),"addCustomFont",(function(e){var t=r.dom.createEl("div",{className:"font hideCustomFonts"}),n=r.dom.createEl("p",{className:"customFontHeading",innerHTML:"Font Size"});r.dom.appendContent(t,n);var i=r.dom.createEl("div",{className:"font-options"});i.style.fontSize="12px",a.fontSizeOptions.map((function(e,t){var n=r.dom.createEl("div",{className:"options",innerHTML:'<div class="radio-item" >\n <input class=opt'.concat(t,' type="radio" id=').concat(e,' name="item" />\n <label class="radio-btn-lable" for=').concat(e,">").concat(e,"pt</label>\n </div>")});n.addEventListener("click",(function(e){var t=e.target.id;a.changeFontSize(t)})),r.dom.appendContent(i,n)})),r.dom.appendContent(t,i),r.dom.appendContent(e,t)})),l(i(a),"resetRenditions",(function(){e(document.getElementsByClassName("rendition")).map((function(e){r.dom.removeClass(e,"selected")}))})),a.playerId=null==o?void 0:o.playerId,a.skin=null==o?void 0:o.skin,a.icon=null==o?void 0:o.icon,a.masterRenditions=[],a.fontSizeOptions=[10,12,14],a.createRenditions(o.renditions),window.height=null,a}return n(h,[{key:"toggleContentOnHover",value:function(e,t){var n=r.dom.$(".setting-icon",e);n.addEventListener("mouseover",(function(){r.dom.removeClass(t,"hidden")})),t.addEventListener("mouseover",(function(){r.dom.removeClass(t,"hidden")})),n.addEventListener("mouseout",(function(){r.dom.addClass(t,"hidden")})),t.addEventListener("mouseout",(function(){r.dom.addClass(t,"hidden")}))}},{key:"changeFontSize",value:function(e){var t=r.dom.$(".renditions",this.contentEl()),n=r.dom.$(".font-options",this.contentEl());t.style.fontSize="".concat(e,"px"),n.style.fontSize="".concat(e,"px")}},{key:"createRenditions",value:function(e){var t=this,n=this.el();r.dom.$(".setting-icon",this.el()).innerHTML="".concat(this.icon," ").concat("live"===this.skin?"  Settings":""," ");var i=r.dom.createEl("div",{className:"content hidden"}),a=r.dom.createEl("div",{innerHTML:"Quality",className:"title"}),o=r.dom.createEl("div",{className:"resolution"});r.dom.appendContent(o,a),this.toggleContentOnHover(n,i);var d=r.dom.createEl("div",{className:"renditions"});this.player_.tech_.vhs?(e.map((function(e,n){var i,a,o=r.dom.createEl("div",{className:"relative"}),l=(((null==e||null===(i=e.playlist)||void 0===i?void 0:i.attributes["AVERAGE-BANDWIDTH"])||(null==e||null===(a=e.playlist)||void 0===a?void 0:a.attributes.BANDWIDTH))/1048576).toFixed(1),s="".concat(e.height,"p ").concat(e.height>719&&e.height<1081?"<span>HD</span>":e.height>1081&&e.height<1500?"<span>2K (HD)</span>":e.height>1501?"<span>4K (HD)</span>":"");s="".concat(e.height,"p @ ").concat(l,"mbps ").concat(e.height>719&&e.height<1081?"<span>HD</span>":e.height>1081&&e.height<1500?"<span>2K (HD)</span>":e.height>1501?"<span>4K (HD)</span>":"");var c=r.dom.createEl("p",{innerHTML:s,className:"rendition",res:e.height,bandwidth:e.bandwidth});r.dom.appendContent(o,c),r.dom.appendContent(d,o),c.addEventListener("click",(function(e){window.height===e.target.res&&e.target.bandwidth==window.bandwidth||(t.resetRenditions(),window.height=e.target.res,window.bandwidth=parseInt(e.target.bandwidth),window.selectedVideo=e.target.video,v(t.playerId,e.target),r.dom.addClass(c,"selected"))}))})),this.addAutoRendition("nondrm",d),"Safari"!=s.detectBrowser()&&this.addDynamicSwitchIfAuto()):(e.map((function(e,n){var i=r.dom.createEl("div",{className:"relative"}),a=(e.bitrate/1e6).toFixed(1),o="".concat(e.height,"p ").concat(e.height>719&&e.height<1081?"<span>HD</span>":e.height>1081&&e.height<1500?"<span>2K (HD)</span>":e.height>1501?"<span>4K (HD)</span>":"");window.enableResolutionsBitrate&&(o="".concat(e.height,"p @ ").concat(a,"mbps ").concat(e.height>719&&e.height<1081?"<span>HD</span>":e.height>1081&&e.height<1500?"<span>2K (HD)</span>":e.height>1501?"<span>4K (HD)</span>":""));var l=r.dom.createEl("p",{innerHTML:o,className:"rendition",res:e.height,qualityIndex:e.qualityIndex});r.dom.appendContent(i,l),r.dom.appendContent(d,i),l.addEventListener("click",(function(e){window.height===e.target.res&&e.target.bandwidth==window.bandwidth||(t.resetRenditions(),window.height=e.target.res,window.selectedVideo=e.target.video,window.qualityIndex=e.target.qualityIndex,v(t.playerId,e.target),r.dom.addClass(l,"selected"))}))})),this.addAutoRendition("drm",d)),r.dom.appendContent(o,d),r.dom.appendContent(i,o),r.dom.appendContent(n,i)}},{key:"addDynamicSwitchIfAuto",value:function(){for(var e,t=this.player_.textTracks(),n=0;n<t.length;n++)"segment-metadata"===t[n].label&&(e=t[n]);var i=null;e&&e.on("cuechange",(function(){var t,n,a=e.activeCues[0];if(console.log((null==a||null===(t=a.value)||void 0===t||null===(n=t.resolution)||void 0===n?void 0:n.height)+"p"),a&&document.querySelector(".auto.selected")){var o,d,l,r,s,c,u,h;if(null!=a&&null!==(o=a.value)&&void 0!==o&&null!==(d=o.resolution)&&void 0!==d&&d.height&&i!==(null==a||null===(l=a.value)||void 0===l||null===(r=l.resolution)||void 0===r?void 0:r.height))document.querySelector(".auto.selected").innerHTML="Auto ".concat(null==a||null===(u=a.value)||void 0===u||null===(h=u.resolution)||void 0===h?void 0:h.height,"p");i=null==a||null===(s=a.value)||void 0===s||null===(c=s.resolution)||void 0===c?void 0:c.height}}))}},{key:"createEl",value:function(){var e=r.dom.createEl("div",{className:"container"}),t=r.dom.createEl("div",{className:"setting-icon"});return r.dom.appendContent(e,t),e}},{key:"addAutoRendition",value:function(e,t){var n=this;if("nondrm"==e){var i,a,o,d,l=null===(i=this.player_)||void 0===i||null===(a=i.tech_)||void 0===a?void 0:a.vhs.selectPlaylist().attributes.RESOLUTION.height,s=null===(o=this.player_)||void 0===o||null===(d=o.tech_)||void 0===d?void 0:d.vhs.selectPlaylist().attributes.BANDWIDTH,c=r.dom.createEl("div",{className:"relative"}),u=r.dom.createEl("p",{innerHTML:"Auto ".concat(l,"p"),className:"rendition auto selected",bandwidth:s,res:l});u.addEventListener("click",(function(e){window.height!==e.target.res&&(n.resetRenditions(),r.dom.addClass(u,"selected"),window.height=e.target.res,window.bandwidth=parseInt(e.target.bandwidth),window.selectedVideo=e.target.video,v(n.playerId,null,!0))})),r.dom.appendContent(c,u),r.dom.appendContent(t,c)}else{var h=r.dom.createEl("div",{className:"relative"}),p=r.dom.createEl("p",{innerHTML:"Auto",className:"rendition selected",qualityIndex:"auto"});p.addEventListener("click",(function(e){n.resetRenditions(),r.dom.addClass(p,"selected"),window.qualityIndex=e.target.qualityIndex,window.selectedVideo=e.target.video,v(n.playerId,null,!0)})),r.dom.appendContent(h,p),r.dom.appendContent(t,h)}}}]),h}(),v=function(e,t,n){var i,a=s.getPlayer(e),o=null==t?void 0:t.bandwidth;if((null==a||null===(i=a.tech_)||void 0===i?void 0:i.vhs)||!1){a.tech_.vhs.representations().forEach((function(e){n||e.bandwidth===o?e.enabled(!0):e.enabled(!1)})),a.handleTechPlaying_();var d=a.currentTime();a.currentTime(0),setTimeout((function(){a.currentTime(d)}),100);var l=r.dom.$(".content");l&&r.dom.addClass(l,"hidden")}else{var c=null==t?void 0:t.qualityIndex;if(n){var u,h;null==a||null===(u=a.dash)||void 0===u||null===(h=u.mediaPlayer)||void 0===h||h.resetSettings()}else{var v,p,m,g;null==a||null===(v=a.dash)||void 0===v||null===(p=v.mediaPlayer)||void 0===p||p.updateSettings({streaming:{abr:{autoSwitchBitrate:!1}}}),null==a||null===(m=a.dash)||void 0===m||null===(g=m.mediaPlayer)||void 0===g||g.setQualityFor("video",c,!0);var f=a.currentTime();a.currentTime(0),setTimeout((function(){a.currentTime(f)}),100);var y=r.dom.$(".content");y&&r.dom.addClass(y,"hidden")}}};exports.default=h,exports.playSelectedResolution=v;
|