@viewlift/player-backup 1.0.30-backup → 1.0.31

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.
Files changed (90) hide show
  1. package/cjs/{autoNextVideo-543e9141.js → autoNextVideo-86ec33b5.js} +1 -1
  2. package/cjs/bundle.css +2 -2
  3. package/cjs/caption-settings-d197a857.js +1 -0
  4. package/cjs/features-ad62299c.js +1 -0
  5. package/cjs/generic-0f02a1e1.js +1 -0
  6. package/cjs/index.js +1 -1
  7. package/cjs/{keyboardShortcuts-f99b5202.js → keyboardShortcuts-8506bc80.js} +1 -1
  8. package/cjs/localisation-56e0a999.js +1 -0
  9. package/cjs/multicam-46521da5.js +1 -0
  10. package/cjs/multicamv2-d1c9bec3.js +1 -0
  11. package/cjs/mwebPotraitTray-b9262895.js +1 -0
  12. package/cjs/nextEpisodeButton-e7f64f81.js +1 -0
  13. package/cjs/playlist-8ce91afa.js +1 -0
  14. package/cjs/{renditions-5033b068.js → renditions-07d76d50.js} +1 -1
  15. package/cjs/resolution-0c41f25d.js +1 -0
  16. package/cjs/series-d264a581.js +1 -0
  17. package/cjs/series-v2-66e26946.js +1 -0
  18. package/cjs/settings-icon-d6e9d654.js +1 -0
  19. package/cjs/{skin-244a42a2.js → skin-0a46d854.js} +1 -1
  20. package/cjs/skin-28b65210.js +1 -0
  21. package/cjs/{skin-4700173b.js → skin-30fe9c23.js} +1 -1
  22. package/cjs/skin-75a9b47e.js +1 -0
  23. package/cjs/skin-84765477.js +1 -0
  24. package/cjs/{skin-435d6d05.js → skin-921d35a8.js} +1 -1
  25. package/cjs/skin-fc1e7e52.js +1 -0
  26. package/cjs/{util-ff6df01a.js → util-05c0ddf6.js} +1 -1
  27. package/cjs/videoSelector-3d55993a.js +1 -0
  28. package/esm/{autoNextVideo-89048b93.js → autoNextVideo-758f8478.js} +1 -1
  29. package/esm/bundle.css +2 -2
  30. package/esm/caption-settings-906d90eb.js +1 -0
  31. package/esm/features-31f4c503.js +1 -0
  32. package/esm/generic-78f15d58.js +1 -0
  33. package/esm/index.js +1 -1
  34. package/esm/{keyboardShortcuts-8c1a0dbc.js → keyboardShortcuts-836ad4e2.js} +1 -1
  35. package/esm/localisation-0bf399a1.js +1 -0
  36. package/esm/multicam-ab8a7bc4.js +1 -0
  37. package/esm/multicamv2-763a5c3f.js +1 -0
  38. package/esm/mwebPotraitTray-bc35f355.js +1 -0
  39. package/esm/nextEpisodeButton-3ceba542.js +1 -0
  40. package/esm/playlist-d6daf02f.js +1 -0
  41. package/esm/{renditions-b3362d30.js → renditions-14c8f7a0.js} +1 -1
  42. package/esm/resolution-48b5f25a.js +1 -0
  43. package/esm/series-896bfe98.js +1 -0
  44. package/esm/series-v2-aee09abf.js +1 -0
  45. package/esm/settings-icon-f70de44c.js +1 -0
  46. package/esm/skin-12718597.js +1 -0
  47. package/esm/skin-1fe54747.js +1 -0
  48. package/esm/{skin-44a94852.js → skin-201855fe.js} +1 -1
  49. package/esm/skin-271fa63f.js +1 -0
  50. package/esm/{skin-3c74ae3b.js → skin-3470b8fa.js} +1 -1
  51. package/esm/skin-3f752395.js +1 -0
  52. package/esm/skin-a45baef9.js +1 -0
  53. package/esm/{util-7e34b31f.js → util-48409f97.js} +1 -1
  54. package/esm/videoSelector-b89a64b7.js +1 -0
  55. package/package.json +2 -2
  56. package/cjs/caption-settings-3ad0d2a8.js +0 -1
  57. package/cjs/features-f217e274.js +0 -1
  58. package/cjs/generic-846ad3ba.js +0 -1
  59. package/cjs/multicam-d2c52635.js +0 -1
  60. package/cjs/multicamv2-febd099c.js +0 -1
  61. package/cjs/mwebPotraitTray-e6c21ece.js +0 -1
  62. package/cjs/nextEpisodeButton-1189baf5.js +0 -1
  63. package/cjs/playlist-7294c2b8.js +0 -1
  64. package/cjs/resolution-4740ab4a.js +0 -1
  65. package/cjs/series-302f3a20.js +0 -1
  66. package/cjs/series-v2-9a4fb5e3.js +0 -1
  67. package/cjs/settings-icon-2905ef0b.js +0 -1
  68. package/cjs/skin-8b207698.js +0 -1
  69. package/cjs/skin-c3916a8d.js +0 -1
  70. package/cjs/skin-e905431b.js +0 -1
  71. package/cjs/skin-f225a42e.js +0 -1
  72. package/cjs/videoSelector-ed65f88a.js +0 -1
  73. package/esm/caption-settings-4d38fa5d.js +0 -1
  74. package/esm/features-9929a187.js +0 -1
  75. package/esm/generic-45a6340d.js +0 -1
  76. package/esm/multicam-0bb89aa3.js +0 -1
  77. package/esm/multicamv2-0292ae20.js +0 -1
  78. package/esm/mwebPotraitTray-89852c04.js +0 -1
  79. package/esm/nextEpisodeButton-b25d3548.js +0 -1
  80. package/esm/playlist-dd64830e.js +0 -1
  81. package/esm/resolution-51153c38.js +0 -1
  82. package/esm/series-40ca12f9.js +0 -1
  83. package/esm/series-v2-bd94e204.js +0 -1
  84. package/esm/settings-icon-365de399.js +0 -1
  85. package/esm/skin-1b4ba7f5.js +0 -1
  86. package/esm/skin-2a788da7.js +0 -1
  87. package/esm/skin-60f13ca4.js +0 -1
  88. package/esm/skin-d5510f70.js +0 -1
  89. package/esm/skin-ff55e529.js +0 -1
  90. package/esm/videoSelector-f7eb4d4e.js +0 -1
@@ -1 +1 @@
1
- "use strict";var e,t=require("./generic-846ad3ba.js"),i=require("./util-ff6df01a.js"),o=0,n=0,d=function e(i,o,d,c,r){n=i,i>d.length-1||t.load(o,d[i].id,c).then((function(e){t.highlightVideo(n),n++,t.setVideoIdx(n),u(e)})).catch((function(i){u(i),setTimeout((function(){t.highlightVideo(n),n++,t.setVideoIdx(n),e(n,o,d,c)}),5e3)}))},u=function(t){e&&e(t)};exports.autoPlayNext=function(c){clearTimeout(o);var r=null==c?void 0:c.content;e=null==c?void 0:c.cb;var s=c.playerId,h=sessionStorage.getItem("token");i.onVideoEnded(s,(function(){var e=t.getPlayer(s);0!==(null==e?void 0:e.currentTime())&&((n=t.getVideoIdx())>r.length-1||t.load(s,r[n].id,h).then((function(e){t.highlightVideo(n),t.setCurrentVideo(e.response),n++,t.setVideoIdx(n),u(e)})).catch((function(e){u(e),t.highlightVideo(n),n++,t.setVideoIdx(n),o=setTimeout((function(){t.isPaused(s)&&d(n,s,r,h)}),5e3)})))}))},exports.switchToNext=d;
1
+ "use strict";var e,t=require("./generic-0f02a1e1.js"),i=require("./util-05c0ddf6.js"),o=0,n=0,d=function e(i,o,d,c,r){n=i,i>d.length-1||t.load(o,d[i].id,c).then((function(e){t.highlightVideo(n),n++,t.setVideoIdx(n),u(e)})).catch((function(i){u(i),setTimeout((function(){t.highlightVideo(n),n++,t.setVideoIdx(n),e(n,o,d,c)}),5e3)}))},u=function(t){e&&e(t)};exports.autoPlayNext=function(c){clearTimeout(o);var r=null==c?void 0:c.content;e=null==c?void 0:c.cb;var s=c.playerId,h=sessionStorage.getItem("token");i.onVideoEnded(s,(function(){var e=t.getPlayer(s);0!==(null==e?void 0:e.currentTime())&&((n=t.getVideoIdx())>r.length-1||t.load(s,r[n].id,h).then((function(e){t.highlightVideo(n),t.setCurrentVideo(e.response),n++,t.setVideoIdx(n),u(e)})).catch((function(e){u(e),t.highlightVideo(n),n++,t.setVideoIdx(n),o=setTimeout((function(){t.isPaused(s)&&d(n,s,r,h)}),5e3)})))}))},exports.switchToNext=d;
package/cjs/bundle.css CHANGED
@@ -14,6 +14,8 @@
14
14
 
15
15
 
16
16
 
17
+
18
+
17
19
  .widget-selection{
18
20
  display: flex;
19
21
  align-items: center;
@@ -134,8 +136,6 @@
134
136
  .widget-selector-content #sr-widget{
135
137
  padding: 0 18px;
136
138
  }
137
-
138
-
139
139
  .vjs-poster {
140
140
  display: inline-block;
141
141
  vertical-align: middle;
@@ -0,0 +1 @@
1
+ "use strict";var e=require("@babel/runtime/helpers/classCallCheck"),t=require("@babel/runtime/helpers/createClass"),n=require("@babel/runtime/helpers/inherits"),a=require("@babel/runtime/helpers/possibleConstructorReturn"),o=require("@babel/runtime/helpers/getPrototypeOf"),i=require("video.js"),r=require("./icons-0f7b3404.js"),c=require("./generic-0f02a1e1.js");function l(e){var t=s();return function(){var n,i=o(e);if(t){var r=o(this).constructor;n=Reflect.construct(i,arguments,r)}else n=i.apply(this,arguments);return a(this,n)}}function s(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(s=function(){return!!e})()}require("@babel/runtime/helpers/defineProperty"),require("axios"),require("js-cookie"),require("ua-parser-js"),require("@babel/runtime/helpers/toConsumableArray");var d=i.getComponent("Component"),p=function(){n(o,d);var a=l(o);function o(t){var n,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e(this,o),(n=a.call(this,t,i)).playerId=i.playerId,n.seriesData=i.sres,n.currentVideoData=i.res,n.initialiseStructure(),n.loadCSS(),n}return t(o,[{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(r.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=c.getCaptions(this.playerId);null==t||t.map((function(t){return c.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")?(c.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");a.style.height="".concat(o),i.dom.appendContent(n,a),document.getElementById(this.playerId).style.overflow="hidden",this.addFunctionality(a),c.detectOrientationChange(this.playerId,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(r.crossIconSvg())});o.onclick=function(){e.classList.add("hidden"),n.classList.remove("open"),e.style.right="-350px"};var l=i.dom.createEl("div",{className:"caption-selector-title",innerHTML:"Captions"}),s=i.dom.createEl("div",{className:"caption-selector-content"}),d=i.dom.createEl("div",{className:"caption-container"}),p=this.createLanguageContanier();i.dom.appendContent(d,p);var u=this.createFontSizeContainer();i.dom.appendContent(d,u),i.dom.appendContent(a,o),i.dom.appendContent(a,l),i.dom.appendContent(e,a),i.dom.appendContent(e,s),i.dom.appendContent(s,d),c.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 e=this,t=i.dom.createEl("div",{className:"caption-language-container"}),n=i.dom.createEl("div",{className:"caption-language-container-title",innerHTML:"Language"});i.dom.appendContent(t,n);var a=document.createElement("label");a.setAttribute("for","radio-off"),a.className="caption-language-holder";var o=document.createElement("div");o.className="caption",o.innerHTML="Off";var r=i.dom.createEl("input",{className:"radio - off",id:"radio-off",name:"language-radio",checked:"true"});r.setAttribute("type","radio"),r.onchange=function(t){c.getCaptions(e.playerId).map((function(t){return c.disableCaptions(e.playerId,t.id)}))},i.dom.appendContent(a,r),i.dom.appendContent(a,o),i.dom.appendContent(t,a);for(var l=c.getCaptions(this.playerId),s=function(n){var a,o=document.createElement("label");o.className="caption-language-holder",o.setAttribute("for","language-radio-".concat(n));var r=document.createElement("div");r.className="caption - ".concat(n),r.textContent=null==l||null===(a=l[n])||void 0===a?void 0:a.label;var s=i.dom.createEl("input",{className:"radio - ".concat(n),id:"language-radio-".concat(n),name:"language-radio"});s.onchange=function(t){c.enableCaptions(e.playerId,l[n].id)},s.setAttribute("type","radio"),i.dom.appendContent(o,s),i.dom.appendContent(o,r),i.dom.appendContent(t,o)},d=0;d<l.length;d++)s(d);return t}},{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,r=document.createElement("label");r.className="caption-font-holder",r.setAttribute("for","font".concat(a));var c=document.createElement("div");c.className="fontsize - ".concat(a),c.textContent=(null==n||null===(o=n[a])||void 0===o?void 0:o.size)+"pt";var l=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)});l.setAttribute("type","radio"),l.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(r,l),i.dom.appendContent(r,c),i.dom.appendContent(e,r)}return e}}]),o}();exports.default=p;
@@ -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-0f02a1e1.js"),s=require("./renditions-07d76d50.js"),u=require("./localisation-56e0a999.js");function c(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 d(e){var t=p();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)}}function p(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(p=function(){return!!e})()}exports.addCaptionButton=function(e,t){Promise.resolve().then((function(){return require("./caption-settings-d197a857.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.addDBClickFullScreen=function(e){var t=a.getPlayer(e).el(),r=0,n=a.getPlayer(e);n.addChild("fullscreenToggle");var o=function(){var e,r=null==t||null===(e=t.getElementsByClassName("vjs-fullscreen-control"))||void 0===e?void 0:e[0];r&&r.click()};n.el().addEventListener("dblclick",o),window._multiplayer_dbClickHandler=o;n.el().addEventListener("touchend",(function(){var e=(new Date).getTime(),n=e-r;if(n<300&&n>0){var o,l=null==t||null===(o=t.getElementsByClassName("vjs-fullscreen-control"))||void 0===o?void 0:o[0];l&&l.click()}r=e})),window._multiplayer_dbTapHandler=o},exports.addMulticamSelector=function(e,t){Promise.resolve().then((function(){return require("./multicamv2-d1c9bec3.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-46521da5.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-b9262895.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-e7f64f81.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-8ce91afa.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-0c41f25d.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=d(s);function s(e,r){var n;t(this,s);var o=(n=i.call(this,e,r)).el_;o.classList.add("vjs-rewind-button");var u=a.parseSvgString(l);return o.append(u),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-d264a581.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-66e26946.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?c(Object(n),!0).forEach((function(r){e(t,r,n[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):c(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-d6e9d654.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=d(s);function s(e,r){var n;t(this,s);var o=(n=i.call(this,e,r)).el_;o.classList.add("vjs-skip-button");var u=a.parseSvgString(l);return o.append(u),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=d(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.textContent=u.getLocalisation("slowMoText")||"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-3d55993a.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=require("@babel/runtime/helpers/toConsumableArray"),r={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",getLinearChannelDetails:"/v3/entitlement/linearchannel"};function l(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?l(Object(o),!0).forEach((function(n){e(t,n,o[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):l(Object(o)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(o,e))}))}return t}var d={name:"@viewlift/player-backup",version:"1.0.59",main:"dist/bundle.cjs.js",amdName:"_playerCore",dependencies:{"@silvermine/videojs-airplay":"^1.2.0","@silvermine/videojs-chromecast":"^1.4.1",axios:"^1.2.3","js-cookie":"^3.0.5","video.js":"^7.20.3","videojs-contrib-ads":"^6.9.0","videojs-contrib-dash":"^5.1.1","videojs-contrib-eme":"^3.11.1","videojs-ima":"^2.1.0"}},s=function(e,t){var o,i,r,l;return null!==(o=window)&&void 0!==o&&null!==(i=o.customData)&&void 0!==i&&i.overrideEntitlementResponse?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.overrideEntitlementResponse})})):n({url:f(),params:a({id:e,deviceType:"web_browser",contentConsumption:"web"},null===(r=window)||void 0===r||null===(l=r.customData)||void 0===l?void 0:l.entitlement),method:"GET",headers:{Authorization:t,"Sdk-Version":d.version},withCredentials:!0})},u=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 l,a,d=JSON.parse(atob(t.split(".")[1])),s=(null==d?void 0:d.site)||null;return n({method:"GET",url:m(e),params:{site:s},headers:{Authorization:t,"x-api-key":null===(l=window)||void 0===l||null===(a=l.watchHistory)||void 0===a?void 0:a.xApiKey}})}if("v2"==r){var u,c;JSON.parse(atob(t.split(".")[1]));var v=window.contentType;return n({method:"GET",url:p(e,v),headers:{Authorization:t,"x-api-key":null===(u=window)||void 0===u||null===(c=u.watchHistory)||void 0===c?void 0:c.xApiKey}})}},c=function(e){return E()+"".concat(null==r?void 0:r.getSeriesWatchHistoryV2,"/").concat(e)},v=function(){return E()+"".concat(null==r?void 0:r.getSeriesWatchHistoryV1)},m=function(e){return E()+"".concat(null==r?void 0:r.getVideoInfoV1,"/").concat(e)},p=function(e,t){return E()+"".concat(null==r?void 0:r.getVideoInfoV2,"/").concat(t,"/").concat(e)},g=function(){return E()+"".concat(null==r?void 0:r.saveWatchHistoryV1)},I=function(){return E()+"".concat(null==r?void 0:r.saveWatchHistoryV2)},f=function(){return E()+"".concat(null==r?void 0:r.getVideoDetails)},E=function(){var e;return(null===(e=window)||void 0===e?void 0:e.playerEntitlementUrl)||(null==r?void 0:r.apiBaseUrl)},w=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},T=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)}},y=function(){document.getElementsByClassName("error-container")[0]&&document.getElementsByClassName("error-container")[0].remove()};var h=function(){var e,t;return navigator.userAgent.indexOf("Edg")>-1&&"macOS"!=(null===(e=window.navigator)||void 0===e||null===(t=e.userAgentData)||void 0===t?void 0:t.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 _(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 O(t){for(var n=1;n<arguments.length;n++){var o=null!=arguments[n]?arguments[n]:{};n%2?_(Object(o),!0).forEach((function(n){e(t,n,o[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):_(Object(o)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(o,e))}))}return t}window._deviceInfo=o(navigator.userAgent);var b,D,V,S,C,L=function(e,t){return e&&t?"".concat(e,"x").concat(t):e>1024?"L":e>768?"M":"S"},x=function(e){var t=W(e,"video.tags",[]),n=W(e,"video.gist.primaryCategory.title","VIEWLIFT_CONTENT_GENRE");return t.length>0?t.map((function(e){return e.title})).join(","):n},W=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},A=function(){return!!/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)},P=function(){var e,t,n,o,i,r,l,a,d,s,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,g=null==p||null===(e=p.video)||void 0===e?void 0:e.metadata,I=Z(m);if(!v.includes("VIEWLIFT_"))return v;var f=window.getComputedStyle(document.getElementById(m),null),E=Math.trunc(f.getPropertyValue("height").slice(0,-2)),w=Math.trunc(f.getPropertyValue("width").slice(0,-2)),T=W(p,"video.gist.id",""),y=O(O({},F(g)),{},{VIEWLIFT_WIDTH:w,VIEWLIFT_HEIGHT:E,VIEWLIFT_SIZE:L(w,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:W(p,"video.gist.description","VIEWLIFT_DESCRIPTION"),VIEWLIFT_DURATION:W(p,"video.gist.runtime","VIEWLIFT_DURATION"),VIEWLIFT_MIN_DURATION:0,VIEWLIFT_MAX_DURATION:W(p,"video.gist.runtime","VIEWLIFT_DURATION"),VIEWLIFT_AUTOPLAY:(null==I||null===(n=I.options_)||void 0===n?void 0:n.autoplay)||1,VIEWLIFT_MUTE:(null==I||null===(o=I.options_)||void 0===o?void 0:o.autoplay)||0,VIEWLIFT_DEVICE_ID:localStorage.getItem("deviceId")||"VIEWLIFT_DEVICE_ID",VIEWLIFT_KEYWORDS:x(p),VIEWLIFT_MEDIA_ID:T,VIEWLIFT_ENCODED_VIDEO_TITLE:encodeURI(W(p,"video.gist.title","VIEWLIFT_ENCODED_VIDEO_TITLE")),VIEWLIFT_VIDEO_ID:T,VIEWLIFT_VIDEO_URL:encodeURI(window.location.host+W(p,"video.gist.permalink","")),VIEWLIFT_COPPA:W(null===(i=window)||void 0===i||null===(r=i.app_data)||void 0===r||null===(l=r.site)||void 0===l?void 0:l.settings,"compliance.coppa")?1:0,VIEWLIFT_GDPR:W(null===(a=window)||void 0===a||null===(d=a.app_data)||void 0===d||null===(s=d.site)||void 0===s?void 0:s.settings,"compliance.gdpr")?1:0,VIEWLIFT_CONTENT_DURATION_MS:1e3*W(p,"video.gist.runtime","VIEWLIFT_DURATION"),VIEWLIFT_CONTENT_DURATION:W(p,"video.gist.runtime","VIEWLIFT_DURATION"),VIEWLIFT_CONTENT_ID:T,VIEWLIFT_CONTENT_TITLE:W(p,"video.gist.title","VIEWLIFT_ENCODED_VIDEO_TITLE"),VIEWLIFT_CONTENT_SERIES_TITLE:W(p,"video.series[0].gist.title",W(p,"seriesInfo.title","VIEWLIFT_CONTENT_SERIES_TITLE")),VIEWLIFT_CONTENT_EPISODE:W(p,"video.currentEpisode","VIEWLIFT_CONTENT_EPISODE"),VIEWLIFT_CONTENT_SEASON:W(p,"video.currentSeason","VIEWLIFT_CONTENT_SEASON"),VIEWLIFT_CONTENT_GENRE:W(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 h in y){var _=new RegExp("\\b("+h+")\\b","g");v=v.replace(_,y[h])}return v},F=function(e){var t,n,o,i,r,l,a={},d=new Map;(null==e?void 0:e.length)>0&&(null==e||e.map((function(e){d.set(e.name,e.value)})));var s=(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===(l=r.subscription)||void 0===l?void 0:l.TVE)||!1;return s||u?(A()?s?a=O(O({},a),{},{VIEWLIFT_CSID:d.get("csid.mweb.dtc")||""}):u&&(a=O(O({},a),{},{VIEWLIFT_CSID:d.get("csid.mweb.tve")||""})):s?a=O(O({},a),{},{VIEWLIFT_CSID:d.get("csid.web.dtc")||""}):u&&(a=O(O({},a),{},{VIEWLIFT_CSID:d.get("csid.web.tve")||""})),s?a=O(O({},a),{},{VIEWLIFT_SFID:d.get("sfid.dtc")||""}):u&&(a=O(O({},a),{},{VIEWLIFT_SFID:d.get("sfid.tve")||""})),a=A()?O(O({},a),{},{VIEWLIFT_PROF:d.get("prof.mweb")||""}):O(O({},a),{},{VIEWLIFT_PROF:d.get("prof.web")||""})):(a=O(O({},a),{},{VIEWLIFT_SFID:d.get("sfid.dtc")||""}),a=A()?O(O({},a),{},{VIEWLIFT_CSID:d.get("csid.mweb.dtc")||"",VIEWLIFT_PROF:d.get("prof.mweb")||""}):O(O({},a),{},{VIEWLIFT_CSID:d.get("csid.web.dtc")||"",VIEWLIFT_PROF:d.get("prof.web")||""})),a},R=function(e,t){var n,o,i,r,l,a,d,s,u,c,v,m,p,g=(null==e?void 0:e.contentType)||"video",I=null==e||null===(n=e[g])||void 0===n?void 0:n.drmEnabled,f=null==e||null===(o=e[g])||void 0===o||null===(i=o.streamingInfo)||void 0===i?void 0:i.videoAssets,E=null==e||null===(r=e[g])||void 0===r||null===(l=r.streamingInfo)||void 0===l?void 0:l.audioAssets,w=(null==e||null===(a=e[g])||void 0===a||null===(d=a.streamingInfo)||void 0===d||null===(s=d.videoAssets)||void 0===s?void 0:s.hls)||!1;null==e||null===(u=e[g])||void 0===u||null===(c=u.liveDetails)||void 0===c||c.isDvrEnabled;var T=(null==e||null===(v=e[g])||void 0===v||null===(m=v.streamingInfo)||void 0===m||null===(p=m.videoAssets)||void 0===p?void 0:p.dash)||!1;if(null!=e&&e.audioAssetSource&&null!=E&&E.hls)return k(E);if(I){var y=j(f,t);return y.src=P(y.src,t,e),y}if("Safari"!==h()&&T)return N(f);if(w){var _=k(f);return _.src=P(_.src,t,e),_}if(null!=f&&f.mpeg){var O=function(e){var t=null==e?void 0:e.mpeg;return{src:t[t.length-1].url,type:"video/mp4"}}(f);return O.src=P(O.src,t,e),O}return null},N=function(e){var t=null==e?void 0:e.dash;return t?{src:t,type:"application/dash+xml"}:null},k=function(e){var t=null==e?void 0:e.hls;return t?{src:t,type:"application/x-mpegURL"}:null},j=function(e,n){var o=e.fairPlay,i=e.widevine,r=e.playReady,l=h(),a=Z(n);if("Safari"===l){var d=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 l={uri:e.licenseUrl,method:"POST",responseType:"arraybuffer",body:i,headers:{"Content-type":"application/octet-stream","X-AxDRM-Message":e&&e.licenseToken}};t.xhr(l,(function(e,t,n){console.log(e),e&&r(e),r(null,n)}))}}}}}(o);try{a.eme()}catch(e){console.log("EME ERROR :",e)}return d}var s,u={src:i.url,type:"application/dash+xml"};return"caliente"==(null===(s=window)||void 0===s?void 0:s.siteName)?(a.eme(),u.keySystems={"com.widevine.alpha":{url:i.licenseUrl,licenseHeaders:{"X-AxDRM-Message":i.licenseToken}},"com.microsoft.playready":{url:r.licenseUrl,licenseHeaders:{"X-AxDRM-Message":r.licenseToken}}}):(u.keySystemOptions=[],u.keySystemOptions.push({name:"com.widevine.alpha",options:{serverURL:i.licenseUrl,httpRequestHeaders:{"X-AxDRM-Message":i.licenseToken},videoRobustness:"SW_SECURE_CRYPTO",audioRobustness:"SW_SECURE_CRYPTO"}}),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){D=e},U=function(e){V=e},H=function(e){if(S){var t=S.get(e);U(t+1)}},M=function(e,t){var n=Z(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=P(t,e,n),i=Z(e);t&&window.google&&(i.ima.initializeAdDisplayContainer&&i.ima.initializeAdDisplayContainer(),function(e,t){var n,o,i,r=Z(e);if(null!==r.el_){z=!0;var l={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(l):setTimeout((function(){r.ima.setContentWithAdTag(null,t,!0),r.ima.requestAds()}),1e3));var a=document.getElementById("".concat(e));(navigator.userAgent.match(/iPad/i)||navigator.userAgent.match(/Android/i))&&a.hasAttribute("controls")&&a.removeAttribute("controls");var d="click",s=!1;(navigator.userAgent.match(/iPhone/i)||navigator.userAgent.match(/iPad/i)||navigator.userAgent.match(/Android/i))&&(s=!0,d="touchend"),r.one(d,(function(){s&&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))},q=function(e){var t=(new DOMParser).parseFromString(e,"image/svg+xml");return null==t?void 0:t.querySelector("svg")},Y="";function X(){var e=null;return{set:function(t){t&&(e=t)},get:function(){return e}}}function J(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 K=function(e){return!!t.getPlayer("".concat(e))},Z=function(e){return!!t.getPlayer("".concat(e))&&t.getPlayer("".concat(e))},Q=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(),document.getElementById("chromett")&&document.getElementById("chromett").remove()},$=function(e,t){Z(e).src(t)},ee=function(t,n,o,i){var r,l,a,d,s,u,c=null==t||null===(r=t.response)||void 0===r||null===(l=r.data)||void 0===l?void 0:l.errorCode,v=(null==t||null===(a=t.response)||void 0===a||null===(d=a.data)||void 0===d?void 0:d.errorMessage)||(null==t?void 0:t.message);K(n)&&T(n,(null===(s=window)||void 0===s?void 0:s.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?J(Object(o),!0).forEach((function(n){e(t,n,o[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):J(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=M,exports.clearError=y,exports.closeOpenDrawers=function(){var e=i(document.getElementsByClassName("vjs-control vjs-button open"));null==e||e.map((function(e){var t,n;null==e||null===(t=e.childNodes)||void 0===t||null===(n=t[0])||void 0===n||n.click()}))},exports.createIconMarkup=function(e){return q(e)},exports.createIdxMapping=function(e){S=new Map,e.map((function(e,t){S.set(e.id,t)}))},exports.detectBrowser=h,exports.detectOrientationChange=function(e,t){var n,o=function(){return function(e,t){var n=window.matchMedia("(orientation: portrait)").matches?"potrait":"landscape";if(Y!==n){var o=window.getComputedStyle(document.getElementById(e),null).getPropertyValue("height");t&&(t.style.height="".concat(o)),Y=n}}(e,t)};window._orientationChangeHandler=o;window.addEventListener("resize",(function(){clearTimeout(n),n=setTimeout((function(){o()}),100)}))},exports.disableCaptions=function(e,t){for(var n=Z(e).textTracks(),o=0;o<n.length;o++){var i=n[o];"subtitles"!==i.kind&&"captions"!==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=Z(e);if(Q(),window._orientationChangeHandler&&(window.removeEventListener("resize",window._orientationChangeHandler),delete window._orientationChangeHandler),window._multiplayer_dbClickHandler&&(window.removeEventListener("dblclick",window._multiplayer_dbClickHandler),delete window._multiplayer_dbClickHandler),window._multiplayer_dbTapHandler&&(window.removeEventListener("touchend",window._multiplayer_dbTapHandler),delete window._multiplayer_dbTapHandler),window.onresize=null,t)t.dispose();else{var n=document.getElementById(e);n&&n.remove()}},exports.enableCaptions=function(e,t){for(var n=Z(e).textTracks(),o=0;o<n.length;o++){var i=n[o];"subtitles"!==i.kind&&"captions"!==i.kind||i.id!=t||(i.mode="showing")}},exports.getCaptions=function(e){var t,n=Z(e);return(null==n||null===(t=n.textTracks())||void 0===t?void 0:t.tracks_.filter((function(e){return"subtitles"==e.kind||"captions"===e.kind})))||[]},exports.getCurrentSeries=function(){return b},exports.getCurrentVideo=function(){return D},exports.getLinearChannelDetails=function(e,t){var o,i;return n({url:E()+r.getLinearChannelDetails,params:a(a(a(a(a({id:null==e?void 0:e.id,deviceType:"web_browser",contentConsumption:"web"},(null==e?void 0:e.channelId)&&{channelId:null==e?void 0:e.channelId}),(null==e?void 0:e.programId)&&{programId:null==e?void 0:e.programId}),(null==e?void 0:e.programTitle)&&{programTitle:null==e?void 0:e.programTitle}),(null==e?void 0:e.programSubType)&&{programSubType:null==e?void 0:e.programSubType}),null===(o=window)||void 0===o||null===(i=o.customData)||void 0===i?void 0:i.entitlement),method:"GET",headers:{Authorization:t}})},exports.getPlayer=Z,exports.getSeriesDetails=function(e,t){var o,i,r=JSON.parse(atob(t.split(".")[1])),l=(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:E()+"/v3/content/series/".concat(e),params:{site:l},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:v(),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:c(i),headers:{Authorization:e.token}})},exports.getSeriesWatchMap=function(){return C},exports.getSource=R,exports.getVideoDetails=s,exports.getVideoIdx=function(){return V},exports.getVideoInfo=u,exports.handleError=T,exports.highlightVideo=function(e){i(document.querySelectorAll("[video-idx]")).map((function(t){var n=t.getAttribute("video-idx");t.style.border=n==e?"2px solid white":"none"}))},exports.impolicy16x9=function(e){return e?e+"?impolicy=resize&w=1920&h=1080":null},exports.initialiseAdvertisement=G,exports.initiateErrorHandling=ee,exports.isNotAValidSkin=function(e){return"live"!==e&&"carousel"!==e&&"V2"!==e&&"defaultV2"!==e&&"multiplayer"!==e},exports.isPaused=function(e){return t(e).paused()},exports.isPlayerInitialised=K,exports.isTokenExpired=w,exports.load=function(e,t,n){var o,i,r;n!==X().get()&&w(n)&&(n=X().get()),H(t);var l=0,a=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&&u(t,n).then((function(e){var t,n,o,i,r,d;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)),l=(null==e||null===(r=e.data)||void 0===r?void 0:r.watchedTime)||null,a=(null==e||null===(d=e.data)||void 0===d?void 0:d.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){s(t,n).then((function(t){var n,r,d,s,u,c,v,m,p,g,I=null==t?void 0:t.data,f=(null==I||null===(n=I.video)||void 0===n||null===(r=n.streamingInfo)||void 0===r?void 0:r.isLiveStream)||!1;B(t.data);var E=(null==I||null===(d=I.ads)||void 0===d||null===(s=d.preRoll)||void 0===s||null===(u=s.adTags)||void 0===u||null===(c=u.web)||void 0===c?void 0:c.active)&&(null==I||null===(v=I.ads)||void 0===v||null===(m=v.preRoll)||void 0===m||null===(p=m.adTags)||void 0===p||null===(g=p.web)||void 0===g?void 0:g.url);E&&G(e,E,I);var w=R(I,e);if(w){var h,_,O,b,D,V,S,C,L,x,W,A,P,F,N=(null==I||null===(h=I.video)||void 0===h||null===(_=h.gist)||void 0===_?void 0:_.videoImageUrl)||(null==I||null===(O=I.video)||void 0===O||null===(b=O.gist)||void 0===b||null===(D=b.imageGist)||void 0===D?void 0:D.r16x9),k=Z(e);if(k.poster(N),$(e,w),k.on("loadstart",(function(){f&&o({status:!0,msg:"Video Loaded",response:I})})),k.on("loadeddata",(function(){y(),o({status:!0,msg:"Video Loaded",response:I})})),k.one("play",(function(){l&&a<95&&setTimeout((function(){k.currentTime(l)}),0)})),k.one("error",(function(){var e;i({status:!1,msg:(null==k||null===(e=k.error())||void 0===e?void 0:e.message)||"Some error occured"})})),(null==I||null===(V=I.video)||void 0===V||null===(S=V.contentDetails)||void 0===S||null===(C=S.closedCaptions)||void 0===C?void 0:C.length)>0||(null==I||null===(L=I.video)||void 0===L||null===(x=L.closedCaptions)||void 0===x?void 0:x.length)>0)W=((null==I||null===(A=I.video)||void 0===A||null===(P=A.contentDetails)||void 0===P?void 0:P.closedCaptions)||(null==I||null===(F=I.video)||void 0===F?void 0:F.closedCaptions)).filter((function(e){return"VTT"===e.format})),M(e,W);else!function(e){var t=Z(e);t.remoteTextTracks().tracks_.map((function(e){"subtitles"==(null==e?void 0:e.kind)||null==e||e.kind,t.removeRemoteTextTrack(e)}))}(e)}else T(e,"Incompatible Source, only hls,mp4,drm content is allowed"),i("Incompatible Source, only hls,mp4,drm content is allowed")})).catch((function(n){ee(n,e,i,t)}))}))},exports.loadVideo=$,exports.loadVideoInstantly=function(e,t,n){var o=Z(e);return o.src(t),new Promise((function(e,t){var i=0;o.one("loadedmetadata",(function(){clearTimeout(i),e({status:!0,msg:"video loaded"})})),o.one("loadstart",(function(e){i=setTimeout((function(){t("FAILED: Took too long to load")}),n)}))}))},exports.parseHtmlString=function(e){var t=(new DOMParser).parseFromString(e,"text/html");return null==t?void 0:t.querySelector("body")},exports.parseSvgString=q,exports.pause=function(e){t(e).pause()},exports.play=function(e){t(e).play()},exports.refreshTokenManager=X,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:g(),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:I(),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){b=e},exports.setCurrentVideo=B,exports.setSeriesWatchMap=function(e){C=e},exports.setVideoIdx=U,exports.setVideoIdxById=H,exports.skip=function(e,n){var o=t(e),i=o.currentTime()+n;o.currentTime(i)};
package/cjs/index.js CHANGED
@@ -1 +1 @@
1
- "use strict";require("video.js/dist/video-js.min.css");var e=require("@babel/runtime/helpers/defineProperty"),t=require("axios"),i=require("@babel/runtime/helpers/asyncToGenerator"),n=require("@babel/runtime/regenerator"),o=require("video.js"),r=require("./generic-846ad3ba.js"),l=require("./util-ff6df01a.js"),a=require("./renditions-5033b068.js"),s=require("./resolution-4740ab4a.js");function d(){var e,t;null===(e=window)||void 0===e||null===(t=e.dataLayer)||void 0===t||t.push(arguments)}function u(e,t){d("event",e,t)}function c(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function v(t){for(var i=1;i<arguments.length;i++){var n=null!=arguments[i]?arguments[i]:{};i%2?c(Object(n),!0).forEach((function(i){e(t,i,n[i])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):c(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}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");function m(){var e=function(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)};return e()+e()+"-"+e()+"-"+e()+"-"+e()+"-"+e()+e()+e()}function f(){var e=window.sessionStorage.getItem("uid");return e||(e=m(),window.sessionStorage.setItem("uid",e),e)}function w(){var e=sessionStorage.getItem("token"),t=JSON.parse(atob(e.split(".")[1]));return null!=t&&t.anonymousId?"guest-user":null==t?void 0:t.userId}window.initialise=function(e){window.sid=m(),window.environment="production",window.platform="WEBSITE",streamFailures(e),buffering(e),ads(e),ping(e)},window.streamFailures=function(e){var t=Math.floor(e.currentTime());e.on("error",(function(){var i,n,o,r=Math.floor(e.currentTime());u(r?"FAILED_TO_START":"DROPPED_STREAM",v({pfm:window.platform,uid:f(),vid:window.videoId,videoPosition:Math.floor(e.currentTime())},null===(i=window)||void 0===i||null===(n=i.customData)||void 0===n||null===(o=n.beacon)||void 0===o?void 0:o.params)),fireEvent({eventName:t===r?"FAILED_TO_START":"DROPPED_STREAM",videoPosition:Math.floor(e.currentTime()),isAdEvent:!1})}))},window.firstFrame=function(e){e.one("play",tryCatch((function(){var t,i,n;window.ttFirstFrame=0,window.ttFirstFrameTimer=setInterval((function(){window.ttFirstFrame=window.handleBufferTimer(window.ttFirstFrame,e)}),100),u("PLAY",v({pfm:window.platform,uid:f(),vid:window.videoId,videoPosition:Math.floor(e.currentTime())},null===(t=window)||void 0===t||null===(i=t.customData)||void 0===i||null===(n=i.beacon)||void 0===n?void 0:n.params)),fireEvent({eventName:"PLAY",videoPosition:Math.floor(e.currentTime()),isAdEvent:!1})})))},window.buffering=function(e){e.on("waiting",tryCatch((function(){window.ttFirstFrameTimer||(e.currentTime(),clearInterval(window.bufferingTimer),window.bufferingTimer=setInterval((function(){e.el_.className.includes("vjs-waiting")&&!e.paused()?window.totalBufferTime=handleBufferTimer(window.totalBufferTime,e):clearInterval(window.bufferingTimer)}),100))})))},window.handleBufferTimer=function(e,t){var i,n;if(t.el_){var o,r,l,a=e+.1;if(+a.toFixed(2)%5==0&&null!=t&&null!==(i=t.el_)&&void 0!==i&&null!==(n=i.className)&&void 0!==n&&n.includes("vjs-waiting"))u("BUFFERING",v({pfm:window.platform,uid:f(),vid:window.videoId,videoPosition:t.el_&&Math.floor(t.currentTime())},null===(o=window)||void 0===o||null===(r=o.customData)||void 0===r||null===(l=r.beacon)||void 0===l?void 0:l.params)),fireEvent({eventName:"BUFFERING",videoPosition:t.el_&&Math.floor(t.currentTime()),isAdEvent:!1});return a}clearInterval(window.ttFirstFrameTimer)},window.endFirstFrame=function(e){e.one("timeupdate",(function(){var t,i,n;clearInterval(window.ttFirstFrameTimer),clearInterval(window.bufferingTimer),window.ttFirstFrameTimer=null,window.totalBufferTime=window.ttFirstFrame||0,u("FIRST_FRAME",v({eventName:"FIRST_FRAME",videoPosition:Math.floor(e.currentTime()),isAdEvent:!1,ttFirstFrame:window.ttFirstFrame,bufferHealth:window.getRemainingBufferTime(e),pfm:window.platform,uid:f(),vid:window.videoId},null===(t=window)||void 0===t||null===(i=t.customData)||void 0===i||null===(n=i.beacon)||void 0===n?void 0:n.params)),fireEvent({eventName:"FIRST_FRAME",videoPosition:Math.floor(e.currentTime()),isAdEvent:!1,ttFirstFrame:window.ttFirstFrame,bufferHealth:window.getRemainingBufferTime(e)})}))},window.ads=function(e){e.on("adsready",(function(){e.ima.addEventListener(window.google.ima.AdEvent.Type.STARTED,(function(){var t,i,n,o,r,l;u("AD_REQUEST",v({eventName:"AD_REQUEST",videoPosition:Math.floor(e.currentTime()),isAdEvent:!0,bufferHealth:window.getRemainingBufferTime(e),pfm:window.platform,uid:f(),vid:window.videoId,resHeight:e.videoHeight(),resWidth:e.videoWidth()},null===(t=window)||void 0===t||null===(i=t.customData)||void 0===i||null===(n=i.beacon)||void 0===n?void 0:n.params)),fireEvent({eventName:"AD_REQUEST",videoPosition:Math.ceil(e.currentTime()),isAdEvent:!0,resHeight:e.videoHeight(),resWidth:e.videoWidth(),adPosition:1}),u("AD_IMPRESSION",v({eventName:"AD_IMPRESSION",videoPosition:Math.floor(e.currentTime()),isAdEvent:!0,bufferHealth:window.getRemainingBufferTime(e),pfm:window.platform,uid:f(),resHeight:e.videoHeight(),resWidth:e.videoWidth(),vid:window.videoId},null===(o=window)||void 0===o||null===(r=o.customData)||void 0===r||null===(l=r.beacon)||void 0===l?void 0:l.params)),fireEvent({eventName:"AD_IMPRESSION",videoPosition:Math.ceil(e.currentTime()),resHeight:e.videoHeight(),resWidth:e.videoWidth(),isAdEvent:!0,adPosition:1})})),e.ima.addEventListener(window.google.ima.AdEvent.Type.SKIPPED,(function(){window.ttFirstFrame=0})),e.ima.addEventListener(window.google.ima.AdEvent.Type.COMPLETE,(function(){window.ttFirstFrame=0}))}))},window.ping=function(e){var t=[];e.on("timeupdate",(function(){var i=Math.floor(e.currentTime());i>=30&&i%30==0&&!t.includes(i)&&(t.push(i),fireEvent({eventName:"PING",videoPosition:i,isAdEvent:!1,duration:30,resHeight:e.videoHeight(),resWidth:e.videoWidth(),bufferHealth:window.getRemainingBufferTime(e),bitrate:e.tech_.vhs&&window.getBitrate(e)}))}))},window.getBitrate=function(e){return Math.round(e.tech_.vhs.selectPlaylist().attributes.BANDWIDTH/1e3)},window.getRemainingBufferTime=function(e){return tryCatch((function(){for(var t=e.currentTime(),i=e.duration(),n=e.buffered(),o=0;o<n.length;o++){var r=n.start(o),l=n.end(o);if(p(t,r,l)){var a=Math.round(i-l);if(isFinite(a))return a}}}))()};var p=function(e,t,i){return e>=t&&e<=i};function h(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function g(t){for(var i=1;i<arguments.length;i++){var n=null!=arguments[i]?arguments[i]:{};i%2?h(Object(n),!0).forEach((function(i){e(t,i,n[i])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):h(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}window.fireEvent=function(e){var i,n,o,r,l,a,s,d,u,c,m=[v(v(v({aid:window.siteName,cid:window.siteId,pfm:window.platform},null===(i=window)||void 0===i||null===(n=i.customData)||void 0===n||null===(o=n.beacon)||void 0===o?void 0:o.params),{},{uid:f(),vid:window.videoId,url:e.url||document.location.href,ref:e.ref||document.referrer,pa:e.eventName,vpos:e.videoPosition,environment:window.environment,dp1:e.dp1||null,dp2:e.dp2||null,dp3:e.dp3||null,dp4:e.dp4||null,dp5:e.dp5||null,apos:!0===e.isAdEvent?e.videoPosition:null,apod:!0===e.isAdEvent?(c=e.adPosition,c?String(c):""):null,profid:w(),player:e.playerType||"native",media_type:e.mediaType||"VIDEO",stream_id:window.sid,embedurl:null,ttfirstframe:e.ttFirstFrame,bitrate:e.bitrate,connectionspeed:null,resolutionheight:e.resHeight,resolutionwidth:e.resWidth,bufferhealth:e.bufferHealth},(null==e?void 0:e.duration)&&{duration:e.duration}),null===(r=window)||void 0===r||null===(l=r.customData)||void 0===l||null===(a=l.beacon)||void 0===a?void 0:a.params)];t({url:(null===(s=window)||void 0===s||null===(d=s.customData)||void 0===d||null===(u=d.beacon)||void 0===u?void 0:u.url)||"https://1a7ahu122g.execute-api.us-east-1.amazonaws.com/production_beacon/firehouse-proxy",method:"post",headers:{Authorization:sessionStorage.getItem("token")},contentType:"application/x-www-form-urlencoded",dataType:"text",data:m}).catch((function(e){console.error(e)}))},window.tryCatch=function(e){return function(){try{return e.apply(window,arguments)}catch(e){return console.error(e),null}}};var y,b,T=function(e,t){var i=r.getPlayer(e);i&&t&&i.controlBar&&i.controlBar.progressControl.seekBar.on("click",(function(t){var i,n,r,l,a,s=this.el(),d=o.dom.getPointerPosition(s,t).x;o.getPlayer(e).controlBar.durationDisplay.options_.playerOptions.disableRemotePlayback=!1;var u=window.cast&&window.cast.framework&&window.cast.framework.CastSession,c=null===(i=window)||void 0===i||null===(n=i.cast)||void 0===n||null===(r=n.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(u),u&&"CONNECTED"===c){window.cast.framework.RemotePlayer.canSeek=!0;var v=new window.cast.framework.RemotePlayerController(window.cast.framework.RemotePlayer),m=v.h.media[0].liveSeekableRange.end;v.getSeekPosition(),window.cast.framework.RemotePlayer.currentTime=m*d,v.seek()}}))};function P(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}var O=[],I=0,k=null;function E(t,i,n){var o,l,a,s=arguments.length>3&&void 0!==arguments[3]&&arguments[3];b=(null==i||null===(o=i.watchHistory)||void 0===o?void 0:o.apiVersion)||"v1";var d=null==i||null===(l=i.watchHistory)||void 0===l?void 0:l.profileId,u=Math.floor(t.currentTime()),c=Math.floor(t.duration()),v=null==i||null===(a=i.watchHistory)||void 0===a?void 0:a.xapiKey,m={};"v1"==b?m={videoId:y,watchedTime:Math.floor(t.currentTime()),watchedPercentage:Math.floor(u/c*100),siteOwner:i.siteOwner,userId:i.userId,xApiKey:v}:"v2"==b&&(m=function(t){for(var i=1;i<arguments.length;i++){var n=null!=arguments[i]?arguments[i]:{};i%2?P(Object(n),!0).forEach((function(i){e(t,i,n[i])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):P(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}({videoId:y,watchedTime:Math.floor(t.currentTime()),watchedPercentage:s?100:Math.floor(u/c*100),doneWatching:s,profileId:d},k&&{seriesId:k})),r.saveWatchHistory(m,i.token,b).then((function(e){})).catch((function(e){})),I=u+n}var S=function(e,t,i){var n=r.getPlayer(e);if(n)if(t>=0&&t<=100){n.muted()&&n.muted(!1);var o=parseFloat(t)/100;n.volume(o),i&&i({status:!0,msg:"Volume set to ".concat(t,"%")})}else i&&i({status:!1,msg:"Please enter a valid volume percentage (0 ≥ V ≤ 100)"});else i({status:!1,msg:"Cannot find player with id: '".concat(e,"'")})},j=function(e){var t=r.getPlayer(e);return t?parseInt(100*t.volume())+"%":"Cannot find player with id: '".concat(e,"'")};function D(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}var C=function(t,i,n,o){var l,a,s=o.res,d=o.sres,u=r.getPlayer(t),c=(null==s||null===(l=s.video)||void 0===l||null===(a=l.streamingInfo)||void 0===a?void 0:a.isLiveStream)||!1;r.setCurrentVideo(s),u.on("loadstart",(function(){c&&n.resolve({status:!0,msg:"Video Loaded",response:s})})),u.on("loadeddata",(function(){var o;(null==u||!u.muted())&&S(t,sessionStorage.getItem("volume")||"100");var l,a,c=r.getCurrentVideo();(r.clearError(),n.resolve(function(t){for(var i=1;i<arguments.length;i++){var n=null!=arguments[i]?arguments[i]:{};i%2?D(Object(n),!0).forEach((function(i){e(t,i,n[i])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):D(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}({status:!0,msg:"Player Initialised"},d?{seriesResponse:d,response:s}:{response:s})),null!=i&&i.watchHistory&&null!=i&&null!==(o=i.watchHistory)&&void 0!==o&&o.enable&&!i.isAnonymousUser)&&function(e,t,i){var n,o;null!=t&&t.series&&(k=null==t||null===(n=t.series)||void 0===n?void 0:n.id),O=[],I=0,y=i;var l=(null==t||null===(o=t.watchHistory)||void 0===o?void 0:o.interval)||30,a=r.getPlayer(e);a&&(a.on("timeupdate",(function(){var e=Math.floor(a.currentTime());O.includes(I)||(e==I?(O.push(e),E(a,t,l)):e>I&&(I=e+l))})),a.on("ended",(function(){E(a,t,l,!0)})))}(t,i,null==c||null===(l=c.video)||void 0===l||null===(a=l.gist)||void 0===a?void 0:a.id)})),c&&(window.onfocus=function(){try{var e;null==u||null===(e=u.liveTracker)||void 0===e||e.seekToLiveEdge()}catch(e){console.log(e,"Cannot seek to LE")}}),u.textTracks().on("change",(function(e){var t=this.tracks_.filter((function(e){if("subtitles"===e.kind&&"showing"===e.mode)return!0}))[0];u.trigger("subtitlechanged",t)})),u.on("subtitlechanged",(function(e,t){var i,n,o,r,l,a,s,d,u,c,v=window.cast&&window.cast.framework&&window.cast.framework.CastSession,m=null===(i=window)||void 0===i||null===(n=i.cast)||void 0===n||null===(o=n.framework)||void 0===o||null===(r=o.CastContext)||void 0===r||null===(l=r.getInstance())||void 0===l?void 0:l.S,f=null===(a=window)||void 0===a||null===(s=a.cast)||void 0===s||null===(d=s.framework)||void 0===d||null===(u=d.CastContext)||void 0===u||null===(c=u.getInstance())||void 0===c?void 0:c.getCurrentSession();if(v&&"CONNECTED"===m){var w,p=f.getMediaSession(),h=p.media.tracks.filter((function(e){return"TEXT"==e.type}));w=t?new chrome.cast.media.EditTracksInfoRequest([h[0].trackId]):new chrome.cast.media.EditTracksInfoRequest([]),p.editTracksInfo(w)}})),u.on("loadedmetadata",(function(){window.endFirstFrame(u)})),u.one("error",(function(){var e,i;r.handleError(t,(null==u||null===(e=u.error())||void 0===e?void 0:e.message)||"Some error occured"),n.reject({status:!1,msg:(null==u||null===(i=u.error())||void 0===i?void 0:i.message)||"Some error occured"})})),u.one("play",(function(){var e;if(null!=i&&null!==(e=i.series)&&void 0!==e&&e.enable){var t,n,o,l=null===(t=r.getCurrentVideo())||void 0===t||null===(n=t.video)||void 0===n||null===(o=n.gist)||void 0===o?void 0:o.id,a=r.getSeriesWatchMap().get(l)||{t:0,p:0},s=a.t,d=a.p;s&&d<95&&setTimeout((function(){u.currentTime(s)}),0)}else null!=i&&i.watchHistoryResumeTime&&(null==i?void 0:i.watchedPercentage)<95&&setTimeout((function(){u.currentTime(null==i?void 0:i.watchHistoryResumeTime)}),0)})),u.on("volumechange",(function(){var e=100*u.volume().toFixed(2);u.muted()?sessionStorage.setItem("volume",0):sessionStorage.setItem("volume",e)}))},A=function(e,t){var i=null==t?void 0:t.skin;"live"==i?Promise.resolve().then((function(){return require("./skin-4700173b.js")})).then((function(i){i.initialiseSkin(e,t)})):"default"==i?Promise.resolve().then((function(){return require("./skin-c3916a8d.js")})).then((function(i){i.initialiseSkin(e,t)})):"carousel"==i?Promise.resolve().then((function(){return require("./skin-244a42a2.js")})).then((function(t){t.initaliseSkin(e)})):"defaultV2"==i?Promise.resolve().then((function(){return require("./skin-8b207698.js")})).then((function(i){i.initialiseSkin(e,t)})):"multiplayer"==i&&Promise.resolve().then((function(){return require("./skin-e905431b.js")})).then((function(i){i.initialiseSkin(e,t)}))},R=function(e){return new Promise((function(t,i){if(F(e))i("".concat(e," is alread initialised"));else{var n=document.createElement("script");n.async=!1,n.src=e,n.onload=function(){t()},n.onerror=function(t){i("Error while loading script ".concat(e," : ").concat(t))},document.head.appendChild(n)}}))},F=function(e){return document.querySelectorAll('script[src="'.concat(e,'"]')).length>0},B=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 M,x=function(){var e=i(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:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),H=function(){var e=i(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 e.apply(this,arguments)}}(),_=Object.freeze({__proto__:null,importChromecast:function(){import("@silvermine/videojs-chromecast").then((function(e){R("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"),R("https://imasdk.googleapis.com/js/sdkloader/ima3.js").then((function(){})).catch((function(e){return console.log(e)}))},loadDashLibrary:x,loadEMELibrary:H});function V(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function N(t){for(var i=1;i<arguments.length;i++){var n=null!=arguments[i]?arguments[i]:{};i%2?V(Object(n),!0).forEach((function(i){e(t,i,n[i])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):V(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}var q=function(t,l,a,s){var d,u,c,v,m,f,w,p,h,y,b,P,O,I,k,E,S,j,D,R,F,M,_,V,q,L,W=l.res,U=void 0===W?null:W,z=l.sres,G=void 0===z?null:z,J=(null===(d=window)||void 0===d||null===(u=d.cast)||void 0===u||null===(c=u.framework)||void 0===c||null===(v=c.CastContext)||void 0===v||null===(m=v.getInstance())||void 0===m?void 0:m.S)||void 0,K=null!=a&&a.chromecastReceiverId?"NO_DEVICES_AVAILABLE"!==J&&"NOT_CONNECTED"!==J?["html5","chromecast"]:["chromecast","html5"]:["html5"],Q=r.impolicy16x9(null==U||null===(f=U.video)||void 0===f||null===(w=f.gist)||void 0===w?void 0:w.videoImageUrl)||r.impolicy16x9(null==U||null===(p=U.video)||void 0===p||null===(h=p.gist)||void 0===h||null===(y=h.imageGist)||void 0===y?void 0:y.r16x9),Y=(null==U||null===(b=U.video)||void 0===b||null===(P=b.liveDetails)||void 0===P?void 0:P.isDvrEnabled)||!1,X=function(e){var t,i={};return null!=e&&e.series||null!=e&&e.chromecastReceiverId&&null!==(t=window)&&void 0!==t&&t.cast&&(i={chromecast:{receiverAppID:null==e?void 0:e.chromecastReceiverId,addButtonToControlBar:"default"==e.skin||"defaultV2"==e.skin,buttonPositionIndex:-5,addCastLabelToButton:!0}}),null!=e&&e.airplay&&"Safari"==r.detectBrowser()&&(i=g(g({},i),{},{airPlay:{addButtonToControlBar:"default"==e.skin||"defaultV2"==e.skin,buttonPositionIndex:-5}})),i}(a),Z=(null==U||null===(O=U.video)||void 0===O||null===(I=O.streamingInfo)||void 0===I?void 0:I.isLiveStream)||!1,$=(null==a?void 0:a.drmLibrary)||!1,ee=(null==U||null===(k=U.ads)||void 0===k||null===(E=k.preRoll)||void 0===E||null===(S=E.adTags)||void 0===S||null===(j=S.web)||void 0===j?void 0:j.active)&&(null==U||null===(D=U.ads)||void 0===D||null===(R=D.preRoll)||void 0===R||null===(F=R.adTags)||void 0===F||null===(M=F.web)||void 0===M?void 0:M.url),te=(L={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},e(L,"autoplay",null==a?void 0:a.autoplay),e(L,"normalizeAutoplay",(null==a?void 0:a.autoplay)&&!ee),e(L,"loop",(null==a?void 0:a.loop)||!1),e(L,"audioPosterMode",null==a?void 0:a.audioPosterMode),e(L,"html5",N(N({dash:N(N({},!o.browser.IS_SAFARI&&{useTTML:!0}),{},{updateSettings:{streaming:{delay:{liveDelay:localStorage.getItem("LATENCY")||3},liveCatchup:{maxDrift:0,playbackRate:{min:-.1,max:.1}},abr:{additionalAbrRules:{insufficientBufferRule:!0,switchHistoryRule:!0,droppedFramesRule:!0}}}}}),vhs:N(N({experimentalLLHLS:(null==a?void 0:a.lowLatency)||!1,limitRenditionByPlayerDimensions:!0,useDevicePixelRatio:!0,useNetworkInformationApi:!0},(null==a||null===(_=a.customData)||void 0===_?void 0:_.overrideNative)&&{overrideNative:!0}),{},{enableLowInitialPlaylist:(null==a?void 0:a.enableLowInitialPlaylist)||!1,experimentalBufferBasedABR:(null==a?void 0:a.experimentalBufferBasedABR)||!1})},0==(null==a||null===(V=a.customData)||void 0===V?void 0:V.nativeAudioTracks)&&{nativeAudioTracks:!1}),0==(null==a||null===(q=a.customData)||void 0===q?void 0:q.nativeVideoTracks)&&{nativeVideoTracks:!1})),e(L,"poster",Q),e(L,"techOrder",K),e(L,"chromecast",{requestCustomDataFn:function(e){var i=r.getPlayer(t);console.log(i.textTracksJson_);var n=i.textTracksJson_.filter((function(e){return"subtitles"==e.kind}));return function(e,t,i){var n,o,r,l,a,s,d,u,c,v,m={};if(e&&e.video&&e.video.drmEnabled){m.isDrmEnabled=!0;var f=t.keySystemOptions&&t.keySystemOptions[0]&&t.keySystemOptions[0].options&&t.keySystemOptions[0].options.serverURL;m.licenseUrl=f;var w=t.keySystemOptions&&t.keySystemOptions[0]&&t.keySystemOptions[0].options&&t.keySystemOptions[0].options.httpRequestHeaders["X-AxDRM-Message"];m.licenseToken=w}var p=(null==e||null===(n=e.video)||void 0===n||null===(o=n.gist)||void 0===o?void 0:o.contentType)||"VIDEO";m.contentType=p;var h=null==e||null===(r=e.video)||void 0===r||null===(l=r.gist)||void 0===l?void 0:l.runtime;m.duration=h;var g=null==e||null===(a=e.video)||void 0===a||null===(s=a.gist)||void 0===s?void 0:s.title;m.mediaTitle=g;var y=null==e||null===(d=e.video)||void 0===d||null===(u=d.gist)||void 0===u?void 0:u.videoImageUrl;return m.mediaImage=y,m.subTitles=i,m.DVR=(null==e||null===(c=e.video)||void 0===c||null===(v=c.liveDetails)||void 0===v?void 0:v.isDvrEnabled)||!1,console.log(m),m}(U,e,n)}}),e(L,"plugins",X),L),ie=o(t,te,function(){var e=i(n.mark((function e(){var i,l,d,u,c,v,m,f,w,p,h,g,y,b,P,O,I;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(Z&&s.resolve(N({status:!0,msg:"Player Initialised"},G?{seriesResponse:G,response:U}:{response:U})),window.initialise(ie),window.firstFrame(ie),"white"!==window.controlsColor&&B(window.controlsColor,ie),/Android/i.test(navigator.userAgent)&&(o.options.vhs.overrideNative=!0),p=null==U||null===(i=U.video)||void 0===i?void 0:i.drmEnabled,h=null==U||null===(l=U.video)||void 0===l||null===(d=l.liveDetails)||void 0===d?void 0:d.startOverTime,!p&&!$){e.next=15;break}if("Safari"!==r.detectBrowser()){e.next=13;break}return e.next=11,H();case 11:e.next=15;break;case 13:return e.next=15,Promise.all([H(),x()]);case 15:Y&&T(t,h),!ee||null!=a&&null!==(u=a.customData)&&void 0!==u&&u.disableAds||r.initialiseAdvertisement(t,ee,U),(g=r.getSource(N(N({},U),{},{audioAssetSource:null==a?void 0:a.audioAssetSource}),t))?r.loadVideo(t,g):(s.reject({status:!1,msg:"Incompatible Source, only hls,mp4,drm content is allowed",response:U}),r.handleError(t,"Incompatible Source, only hls,mp4,drm content is allowed")),((null==U||null===(c=U.video)||void 0===c||null===(v=c.contentDetails)||void 0===v||null===(m=v.closedCaptions)||void 0===m?void 0:m.length)>0||(null==U||null===(f=U.video)||void 0===f||null===(w=f.closedCaptions)||void 0===w?void 0:w.length)>0)&&(I=(null==U||null===(b=U.video)||void 0===b||null===(P=b.contentDetails)||void 0===P?void 0:P.closedCaptions)||(null==U||null===(O=U.video)||void 0===O?void 0:O.closedCaptions),y=I.filter((function(e){return"VTT"===e.format})),r.addCaptions(t,y)),null!=a&&a.disableControls?r.disableControls(t):A(t,N(N(N({},a),te),{},{liveVideo:Z,isDvrEnabled:Y,res:U,sres:G})),C(t,N(N(N({},a),te),{},{liveVideo:Z}),s,{res:U,sres:G});case 22:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}())};module.exports=function(){return{loadVideoInstantly:r.loadVideoInstantly,onTimeUpdate:l.onTimeUpdate,getVideoDuration:l.getVideoDuration,onVideoEnded:l.onVideoEnded,init:function(e){return new Promise((function(t,i){var n,o,l,a,s,u,c,v,m;if(!r.isPlayerInitialised(null==e?void 0:e.playerId)){var f=null==e?void 0:e.videoId,w=(null==e||null===(n=e.series)||void 0===n?void 0:n.enable)||!1;window.videoId=f;var p=null==e?void 0:e.token;if(p&&!r.isTokenExpired(p)){M=JSON.parse(atob(p.split(".")[1])),window.siteId=null===(o=M)||void 0===o?void 0:o.siteId,window.siteName=null===(l=M)||void 0===l?void 0:l.site,e.isAnonymousUser=!(null===(a=M)||void 0===a||!a.anonymousId),e.siteOwner=(null===(s=M)||void 0===s?void 0:s.site)||null,e.userId=(null===(u=M)||void 0===u?void 0:u.userId)||null,window.sessionStorage.setItem("uid",null===(c=M)||void 0===c?void 0:c.userId),window.watchHistory=e.watchHistory||null,sessionStorage.setItem("token",p);var h=null==e?void 0:e.playerId,g=e.chromecastReceiverId=null!=e&&e.series?null:null==e?void 0:e.chromecastReceiverId,y=null==e?void 0:e.airplay,b=null==e?void 0:e.apiBaseUrl,T=(null==e||null===(v=e.analytics)||void 0===v?void 0:v.gaId)||null,P=null==e?void 0:e.errors;P&&(window.customErrors=P),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&&!r.isNotAValidSkin(e.skin)||(e.skin="defaultV2"),Promise.resolve().then((function(){return _})).then((function(e){e.importIMA()})),!g||null!=e&&e.series||Promise.resolve().then((function(){return _})).then((function(e){e.importChromecast()})),y&&"Safari"==r.detectBrowser()&&Promise.resolve().then((function(){return _})).then((function(e){e.importAirplay()})),T&&R("https://www.googletagmanager.com/gtag/js?id=".concat(T)).then((function(){return e=T,window.dataLayer=window.dataLayer||[],d("js",new Date),void d("config",e);var e})).catch((function(e){}));var O=null===(m=document)||void 0===m?void 0:m.getElementById("".concat(h));if(O&&O.addEventListener("contextmenu",(function(e){return e.preventDefault()})),w){var I,k=null==e||null===(I=e.series)||void 0===I?void 0:I.id;r.getSeriesDetails(k,p).then((function(n){var o,l,a,s=n.data,d=n.data.seasons;r.setCurrentSeries(d);var u=f||(null==d||null===(o=d[0])||void 0===o||null===(l=o.episodes)||void 0===l||null===(a=l[0])||void 0===a?void 0:a.id);!function(e,t){var i=new Map;r.getSeriesWatchHistory({videoId:e,token:t}).then((function(e){e.data.map((function(e){i.set(e.videoId,{t:e.watchedTime,p:e.watchedPercentage})})),r.setSeriesWatchMap(i)})).catch((function(e){return console.log(e)}))}(k,p),r.getVideoDetails(u,p).then((function(n){var o,l,a;window.contentType=null==n||null===(o=n.data)||void 0===o||null===(l=o.video)||void 0===l||null===(a=l.gist)||void 0===a?void 0:a.contentType,r.setCurrentVideo(n.data),q(h,{res:null==n?void 0:n.data,sres:s},e,{resolve:t,reject:i})})).catch((function(e){r.initiateErrorHandling(e,h,i,f)}))})).catch((function(e){r.initiateErrorHandling(e,h,i)}))}else r.getVideoDetails(f,p).then((function(n){var o,l,a,s;window.contentType=null==n||null===(o=n.data)||void 0===o||null===(l=o.video)||void 0===l||null===(a=l.gist)||void 0===a?void 0:a.contentType,r.setCurrentVideo(null==n?void 0:n.data);var d=null==n?void 0:n.data;null!=e&&e.watchHistory&&null!=e&&null!==(s=e.watchHistory)&&void 0!==s&&s.enable?r.getVideoInfo(f,p).then((function(n){var o,r,l,a,s,u;null!==(o=window)&&void 0!==o&&null!==(r=o.watchHistory)&&void 0!==r&&r.cb&&(null===(l=window)||void 0===l||null===(a=l.watchHistory)||void 0===a||a.cb(null==n?void 0:n.data)),e.watchHistoryResumeTime=(null==n||null===(s=n.data)||void 0===s?void 0:s.watchedTime)||null,e.watchedPercentage=(null==n||null===(u=n.data)||void 0===u?void 0:u.watchedPercentage)||null,q(h,{res:d},e,{resolve:t,reject:i})})).catch((function(n){var o,r,l,a;null!==(o=window)&&void 0!==o&&null!==(r=o.watchHistory)&&void 0!==r&&r.cb&&(null===(l=window)||void 0===l||null===(a=l.watchHistory)||void 0===a||a.cb(n)),q(h,{res:d},e,{resolve:t,reject:i})})):q(h,{res:d},e,{resolve:t,reject:i})})).catch((function(e){r.initiateErrorHandling(e,h,i,f)}))}else i({status:!1,msg:"".concat(p?"Token is expired !":"Missing Authorization Token"),response:{token:p}})}}))},getRenditions:a.getRenditions,skip:r.skip,getPlayer:r.getPlayer,play:r.play,pause:r.pause,detectBrowser:r.detectBrowser,rewind:r.rewind,loadVideo:r.loadVideo,seekToTimeStamp:l.seekToTimeStamp,isPlayerInitialised:r.isPlayerInitialised,load:r.load,dispose:r.dispose,enableCaptions:r.enableCaptions,disableCaptions:r.disableCaptions,getCaptions:r.getCaptions,playSelectedResolution:s.playSelectedResolution,getSource:r.getSource,setVolume:S,getVolume:j,disableControls:r.disableControls,setPlaybackSpeed:l.setPlaybackSpeed}};
1
+ "use strict";require("video.js/dist/video-js.min.css");var e=require("@babel/runtime/helpers/defineProperty"),i=require("axios"),n=require("@babel/runtime/helpers/asyncToGenerator"),t=require("@babel/runtime/regenerator"),o=require("video.js"),r=require("./generic-0f02a1e1.js"),l=require("./util-05c0ddf6.js"),a=require("./renditions-07d76d50.js"),d=require("./resolution-0c41f25d.js"),s=require("./localisation-56e0a999.js");function u(){var e,i;null===(e=window)||void 0===e||null===(i=e.dataLayer)||void 0===i||i.push(arguments)}function c(e,i){u("event",e,i)}function v(e,i){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);i&&(t=t.filter((function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable}))),n.push.apply(n,t)}return n}function m(i){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?v(Object(t),!0).forEach((function(n){e(i,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(i,Object.getOwnPropertyDescriptors(t)):v(Object(t)).forEach((function(e){Object.defineProperty(i,e,Object.getOwnPropertyDescriptor(t,e))}))}return i}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");function f(){var e=function(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)};return e()+e()+"-"+e()+"-"+e()+"-"+e()+"-"+e()+e()+e()}function w(){var e=window.sessionStorage.getItem("uid");return e||(e=f(),window.sessionStorage.setItem("uid",e),e)}function p(){var e=sessionStorage.getItem("token"),i=JSON.parse(atob(e.split(".")[1]));return null!=i&&i.anonymousId?"guest-user":null==i?void 0:i.userId}window.initialise=function(e){window.sid=f(),window.environment="production",window.platform="WEBSITE",streamFailures(e),buffering(e),ads(e),ping(e)},window.streamFailures=function(e){var i=Math.floor(e.currentTime());e.on("error",(function(){var n,t,o,r=Math.floor(e.currentTime());c(r?"FAILED_TO_START":"DROPPED_STREAM",m({pfm:window.platform,uid:w(),vid:window.videoId,videoPosition:Math.floor(e.currentTime())},null===(n=window)||void 0===n||null===(t=n.customData)||void 0===t||null===(o=t.beacon)||void 0===o?void 0:o.params)),fireEvent({eventName:i===r?"FAILED_TO_START":"DROPPED_STREAM",videoPosition:Math.floor(e.currentTime()),isAdEvent:!1})}))},window.firstFrame=function(e){e.one("play",tryCatch((function(){var i,n,t;window.ttFirstFrame=0,window.ttFirstFrameTimer=setInterval((function(){window.ttFirstFrame=window.handleBufferTimer(window.ttFirstFrame,e)}),100),c("PLAY",m({pfm:window.platform,uid:w(),vid:window.videoId,videoPosition:Math.floor(e.currentTime())},null===(i=window)||void 0===i||null===(n=i.customData)||void 0===n||null===(t=n.beacon)||void 0===t?void 0:t.params)),fireEvent({eventName:"PLAY",videoPosition:Math.floor(e.currentTime()),isAdEvent:!1})})))},window.buffering=function(e){e.on("waiting",tryCatch((function(){window.ttFirstFrameTimer||(e.currentTime(),clearInterval(window.bufferingTimer),window.bufferingTimer=setInterval((function(){e.el_.className.includes("vjs-waiting")&&!e.paused()?window.totalBufferTime=handleBufferTimer(window.totalBufferTime,e):clearInterval(window.bufferingTimer)}),100))})))},window.handleBufferTimer=function(e,i){var n,t;if(i.el_){var o,r,l,a=e+.1;if(+a.toFixed(2)%5==0&&null!=i&&null!==(n=i.el_)&&void 0!==n&&null!==(t=n.className)&&void 0!==t&&t.includes("vjs-waiting"))c("BUFFERING",m({pfm:window.platform,uid:w(),vid:window.videoId,videoPosition:i.el_&&Math.floor(i.currentTime())},null===(o=window)||void 0===o||null===(r=o.customData)||void 0===r||null===(l=r.beacon)||void 0===l?void 0:l.params)),fireEvent({eventName:"BUFFERING",videoPosition:i.el_&&Math.floor(i.currentTime()),isAdEvent:!1});return a}clearInterval(window.ttFirstFrameTimer)},window.endFirstFrame=function(e){e.one("timeupdate",(function(){var i,n,t;clearInterval(window.ttFirstFrameTimer),clearInterval(window.bufferingTimer),window.ttFirstFrameTimer=null,window.totalBufferTime=window.ttFirstFrame||0,c("FIRST_FRAME",m({eventName:"FIRST_FRAME",videoPosition:Math.floor(e.currentTime()),isAdEvent:!1,ttFirstFrame:window.ttFirstFrame,bufferHealth:window.getRemainingBufferTime(e),pfm:window.platform,uid:w(),vid:window.videoId},null===(i=window)||void 0===i||null===(n=i.customData)||void 0===n||null===(t=n.beacon)||void 0===t?void 0:t.params)),fireEvent({eventName:"FIRST_FRAME",videoPosition:Math.floor(e.currentTime()),isAdEvent:!1,ttFirstFrame:window.ttFirstFrame,bufferHealth:window.getRemainingBufferTime(e)})}))},window.ads=function(e){e.on("adsready",(function(){e.ima.addEventListener(window.google.ima.AdEvent.Type.STARTED,(function(){var i,n,t,o,r,l;c("AD_REQUEST",m({eventName:"AD_REQUEST",videoPosition:Math.floor(e.currentTime()),isAdEvent:!0,bufferHealth:window.getRemainingBufferTime(e),pfm:window.platform,uid:w(),vid:window.videoId,resHeight:e.videoHeight(),resWidth:e.videoWidth()},null===(i=window)||void 0===i||null===(n=i.customData)||void 0===n||null===(t=n.beacon)||void 0===t?void 0:t.params)),fireEvent({eventName:"AD_REQUEST",videoPosition:Math.ceil(e.currentTime()),isAdEvent:!0,resHeight:e.videoHeight(),resWidth:e.videoWidth(),adPosition:1}),c("AD_IMPRESSION",m({eventName:"AD_IMPRESSION",videoPosition:Math.floor(e.currentTime()),isAdEvent:!0,bufferHealth:window.getRemainingBufferTime(e),pfm:window.platform,uid:w(),resHeight:e.videoHeight(),resWidth:e.videoWidth(),vid:window.videoId},null===(o=window)||void 0===o||null===(r=o.customData)||void 0===r||null===(l=r.beacon)||void 0===l?void 0:l.params)),fireEvent({eventName:"AD_IMPRESSION",videoPosition:Math.ceil(e.currentTime()),resHeight:e.videoHeight(),resWidth:e.videoWidth(),isAdEvent:!0,adPosition:1})})),e.ima.addEventListener(window.google.ima.AdEvent.Type.SKIPPED,(function(){window.ttFirstFrame=0})),e.ima.addEventListener(window.google.ima.AdEvent.Type.COMPLETE,(function(){window.ttFirstFrame=0}))}))},window.ping=function(e){var i=[];e.on("timeupdate",(function(){var n=Math.floor(e.currentTime());n>=30&&n%30==0&&!i.includes(n)&&(i.push(n),fireEvent({eventName:"PING",videoPosition:n,isAdEvent:!1,duration:30,resHeight:e.videoHeight(),resWidth:e.videoWidth(),bufferHealth:window.getRemainingBufferTime(e),bitrate:e.tech_.vhs&&window.getBitrate(e)}))}))},window.getBitrate=function(e){return Math.round(e.tech_.vhs.selectPlaylist().attributes.BANDWIDTH/1e3)},window.getRemainingBufferTime=function(e){return tryCatch((function(){for(var i=e.currentTime(),n=e.duration(),t=e.buffered(),o=0;o<t.length;o++){var r=t.start(o),l=t.end(o);if(h(i,r,l)){var a=Math.round(n-l);if(isFinite(a))return a}}}))()};var h=function(e,i,n){return e>=i&&e<=n};window.fireEvent=function(e){var n,t,o,r,l,a,d,s,u,c,v=[m(m(m({aid:window.siteName,cid:window.siteId,pfm:window.platform},null===(n=window)||void 0===n||null===(t=n.customData)||void 0===t||null===(o=t.beacon)||void 0===o?void 0:o.params),{},{uid:w(),vid:window.videoId,url:e.url||document.location.href,ref:e.ref||document.referrer,pa:e.eventName,vpos:e.videoPosition,environment:window.environment,dp1:e.dp1||null,dp2:e.dp2||null,dp3:e.dp3||null,dp4:e.dp4||null,dp5:e.dp5||null,apos:!0===e.isAdEvent?e.videoPosition:null,apod:!0===e.isAdEvent?(c=e.adPosition,c?String(c):""):null,profid:p(),player:e.playerType||"native",media_type:e.mediaType||"VIDEO",stream_id:window.sid,embedurl:null,ttfirstframe:e.ttFirstFrame,bitrate:e.bitrate,connectionspeed:null,resolutionheight:e.resHeight,resolutionwidth:e.resWidth,bufferhealth:e.bufferHealth},(null==e?void 0:e.duration)&&{duration:e.duration}),null===(r=window)||void 0===r||null===(l=r.customData)||void 0===l||null===(a=l.beacon)||void 0===a?void 0:a.params)];i({url:(null===(d=window)||void 0===d||null===(s=d.customData)||void 0===s||null===(u=s.beacon)||void 0===u?void 0:u.url)||"https://1a7ahu122g.execute-api.us-east-1.amazonaws.com/production_beacon/firehouse-proxy",method:"post",headers:{Authorization:sessionStorage.getItem("token")},contentType:"application/x-www-form-urlencoded",dataType:"text",data:v}).catch((function(e){console.error(e)}))},window.tryCatch=function(e){return function(){try{return e.apply(window,arguments)}catch(e){return console.error(e),null}}};var g,y,b=function(e){var i,n,t=r.getPlayer(null==e?void 0:e.playerId);null!=e&&null!==(i=e.series)&&void 0!==i&&i.enable||null==e||!e.chromecastReceiverId||null===(n=window)||void 0===n||!n.cast?console.log("Chromecast plugin is not available"):null==t||t.chromecast({receiverAppID:null==e?void 0:e.chromecastReceiverId,addButtonToControlBar:"default"==e.skin||"defaultV2"==e.skin,buttonPositionIndex:-5,addCastLabelToButton:!0}),null!=e&&e.airplay&&"Safari"==r.detectBrowser()?null==t||t.airPlay({addButtonToControlBar:"default"==e.skin||"defaultV2"==e.skin,buttonPositionIndex:-5}):console.log("AirPlay plugin is not available")},T=function(e,i){var n=r.getPlayer(e);n&&i&&n.controlBar&&n.controlBar.progressControl.seekBar.on("click",(function(i){var n,t,r,l,a,d=this.el(),s=o.dom.getPointerPosition(d,i).x;o.getPlayer(e).controlBar.durationDisplay.options_.playerOptions.disableRemotePlayback=!1;var u=window.cast&&window.cast.framework&&window.cast.framework.CastSession,c=null===(n=window)||void 0===n||null===(t=n.cast)||void 0===t||null===(r=t.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(u),u&&"CONNECTED"===c){window.cast.framework.RemotePlayer.canSeek=!0;var v=new window.cast.framework.RemotePlayerController(window.cast.framework.RemotePlayer),m=v.h.media[0].liveSeekableRange.end;v.getSeekPosition(),window.cast.framework.RemotePlayer.currentTime=m*s,v.seek()}}))};function P(e,i){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);i&&(t=t.filter((function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable}))),n.push.apply(n,t)}return n}var I=[],k=0,O=null;function S(i,n,t){var o,l,a,d=arguments.length>3&&void 0!==arguments[3]&&arguments[3];y=(null==n||null===(o=n.watchHistory)||void 0===o?void 0:o.apiVersion)||"v1";var s=null==n||null===(l=n.watchHistory)||void 0===l?void 0:l.profileId,u=Math.floor(i.currentTime()),c=Math.floor(i.duration()),v=null==n||null===(a=n.watchHistory)||void 0===a?void 0:a.xapiKey,m={};"v1"==y?m={videoId:g,watchedTime:Math.floor(i.currentTime()),watchedPercentage:Math.floor(u/c*100),siteOwner:n.siteOwner,userId:n.userId,xApiKey:v}:"v2"==y&&(m=function(i){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?P(Object(t),!0).forEach((function(n){e(i,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(i,Object.getOwnPropertyDescriptors(t)):P(Object(t)).forEach((function(e){Object.defineProperty(i,e,Object.getOwnPropertyDescriptor(t,e))}))}return i}({videoId:g,watchedTime:Math.floor(i.currentTime()),watchedPercentage:d?100:Math.floor(u/c*100),doneWatching:d,profileId:s},O&&{seriesId:O})),r.saveWatchHistory(m,n.token,y).then((function(e){})).catch((function(e){})),k=u+t}var E=function(e,i,n){var t=r.getPlayer(e);if(t)if(i>=0&&i<=100){t.muted()&&t.muted(!1);var o=parseFloat(i)/100;t.volume(o),n&&n({status:!0,msg:"Volume set to ".concat(i,"%")})}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,"'")})},j=function(e){var i=r.getPlayer(e);return i?parseInt(100*i.volume())+"%":"Cannot find player with id: '".concat(e,"'")};function D(e,i){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);i&&(t=t.filter((function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable}))),n.push.apply(n,t)}return n}var C=function(i,n,t,o){var l,a,d=o.res,s=o.sres,u=r.getPlayer(i),c=(null==d||null===(l=d.video)||void 0===l||null===(a=l.streamingInfo)||void 0===a?void 0:a.isLiveStream)||!1;r.setCurrentVideo(d),u.on("loadstart",(function(){c&&t.resolve({status:!0,msg:"Video Loaded",response:d})})),u.on("loadeddata",(function(){var o;(null==u||!u.muted())&&E(i,sessionStorage.getItem("volume")||"100");var l,a,c=r.getCurrentVideo();(r.clearError(),t.resolve(function(i){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?D(Object(t),!0).forEach((function(n){e(i,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(i,Object.getOwnPropertyDescriptors(t)):D(Object(t)).forEach((function(e){Object.defineProperty(i,e,Object.getOwnPropertyDescriptor(t,e))}))}return i}({status:!0,msg:"Player Initialised"},s?{seriesResponse:s,response:d}:{response:d})),null!=n&&n.watchHistory&&null!=n&&null!==(o=n.watchHistory)&&void 0!==o&&o.enable&&!n.isAnonymousUser)&&function(e,i,n){var t,o;null!=i&&i.series&&(O=null==i||null===(t=i.series)||void 0===t?void 0:t.id),I=[],k=0,g=n;var l=(null==i||null===(o=i.watchHistory)||void 0===o?void 0:o.interval)||30,a=r.getPlayer(e);a&&(a.on("timeupdate",(function(){var e=Math.floor(a.currentTime());I.includes(k)||(e==k?(I.push(e),S(a,i,l)):e>k&&(k=e+l))})),a.on("ended",(function(){S(a,i,l,!0)})))}(i,n,null==c||null===(l=c.video)||void 0===l||null===(a=l.gist)||void 0===a?void 0:a.id)})),u.textTracks().on("change",(function(e){var i=this.tracks_.filter((function(e){if("subtitles"===e.kind&&"showing"===e.mode)return!0}))[0];u.trigger("subtitlechanged",i)})),u.on("subtitlechanged",(function(e,i){var n,t,o,r,l,a,d,s,u,c,v=window.cast&&window.cast.framework&&window.cast.framework.CastSession,m=null===(n=window)||void 0===n||null===(t=n.cast)||void 0===t||null===(o=t.framework)||void 0===o||null===(r=o.CastContext)||void 0===r||null===(l=r.getInstance())||void 0===l?void 0:l.S,f=null===(a=window)||void 0===a||null===(d=a.cast)||void 0===d||null===(s=d.framework)||void 0===s||null===(u=s.CastContext)||void 0===u||null===(c=u.getInstance())||void 0===c?void 0:c.getCurrentSession();if(v&&"CONNECTED"===m){var w,p=f.getMediaSession(),h=p.media.tracks.filter((function(e){return"TEXT"==e.type}));w=i?new chrome.cast.media.EditTracksInfoRequest([h[0].trackId]):new chrome.cast.media.EditTracksInfoRequest([]),p.editTracksInfo(w)}})),u.on("loadedmetadata",(function(){window.endFirstFrame(u)})),u.one("error",(function(){var e,n;r.handleError(i,(null==u||null===(e=u.error())||void 0===e?void 0:e.message)||"Some error occured"),t.reject({status:!1,msg:(null==u||null===(n=u.error())||void 0===n?void 0:n.message)||"Some error occured"})})),u.one("play",(function(){var e;if(null!=n&&null!==(e=n.series)&&void 0!==e&&e.enable){var i,t,o,l=null===(i=r.getCurrentVideo())||void 0===i||null===(t=i.video)||void 0===t||null===(o=t.gist)||void 0===o?void 0:o.id,a=r.getSeriesWatchMap().get(l)||{t:0,p:0},d=a.t,s=a.p;d&&s<95&&setTimeout((function(){u.currentTime(d)}),0)}else null!=n&&n.watchHistoryResumeTime&&(null==n?void 0:n.watchedPercentage)<95&&setTimeout((function(){u.currentTime(null==n?void 0:n.watchHistoryResumeTime)}),0)})),u.on("volumechange",(function(){var e=100*u.volume().toFixed(2);u.muted()?sessionStorage.setItem("volume",0):sessionStorage.setItem("volume",e)}))},A=function(e,i){var n=null==i?void 0:i.skin;"live"==n?Promise.resolve().then((function(){return require("./skin-30fe9c23.js")})).then((function(n){n.initialiseSkin(e,i)})):"default"==n?Promise.resolve().then((function(){return require("./skin-75a9b47e.js")})).then((function(n){n.initialiseSkin(e,i)})):"carousel"==n?Promise.resolve().then((function(){return require("./skin-0a46d854.js")})).then((function(i){i.initaliseSkin(e)})):"defaultV2"==n?Promise.resolve().then((function(){return require("./skin-84765477.js")})).then((function(n){n.initialiseSkin(e,i)})):"multiplayer"==n&&Promise.resolve().then((function(){return require("./skin-28b65210.js")})).then((function(n){n.initialiseSkin(e,i)}))},R=function(e){return new Promise((function(i,n){if(F(e))n("".concat(e," is alread initialised"));else{var t=document.createElement("script");t.async=!1,t.src=e,t.onload=function(){i()},t.onerror=function(i){n("Error while loading script ".concat(e," : ").concat(i))},document.head.appendChild(t)}}))},F=function(e){return document.querySelectorAll('script[src="'.concat(e,'"]')).length>0},B=function(e,i){i.controlBar.el_.style.color=e,i.controlBar.el_.querySelector(".vjs-play-progress")&&(i.controlBar.el_.querySelector(".vjs-play-progress").style.backgroundColor=e),i.controlBar.el_.querySelector(".vjs-volume-level")&&(i.controlBar.el_.querySelector(".vjs-volume-level").style.backgroundColor=e)};var M,x=function(){var e=n(t.mark((function e(){return t.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,import("videojs-contrib-dash");case 2:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),H=function(){var e=n(t.mark((function e(){return t.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 e.apply(this,arguments)}}(),_=Object.freeze({__proto__:null,importChromecast:function(){import("@silvermine/videojs-chromecast").then((function(e){R("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"),R("https://imasdk.googleapis.com/js/sdkloader/ima3.js").then((function(){})).catch((function(e){return console.log(e)}))},loadDashLibrary:x,loadEMELibrary:H});function V(e,i){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);i&&(t=t.filter((function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable}))),n.push.apply(n,t)}return n}function N(i){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?V(Object(t),!0).forEach((function(n){e(i,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(i,Object.getOwnPropertyDescriptors(t)):V(Object(t)).forEach((function(e){Object.defineProperty(i,e,Object.getOwnPropertyDescriptor(t,e))}))}return i}var q=function(i,l,a,d){var s,u,c,v,m,f,w,p,h,g,y,P,I,k,O,S,E,j,D,R,F,M,_,V,q,L,W,U,z,G,J,K,Q=l.res,Y=void 0===Q?null:Q,X=l.sres,Z=void 0===X?null:X,$=(null===(s=window)||void 0===s||null===(u=s.cast)||void 0===u||null===(c=u.framework)||void 0===c||null===(v=c.CastContext)||void 0===v||null===(m=v.getInstance())||void 0===m?void 0:m.S)||void 0,ee=null!=a&&a.chromecastReceiverId?"NO_DEVICES_AVAILABLE"!==$&&"NOT_CONNECTED"!==$?["html5","chromecast"]:["chromecast","html5"]:["html5"],ie=r.impolicy16x9(null===(f=Y)||void 0===f||null===(w=f.video)||void 0===w||null===(p=w.gist)||void 0===p?void 0:p.videoImageUrl)||r.impolicy16x9(null===(h=Y)||void 0===h||null===(g=h.video)||void 0===g||null===(y=g.gist)||void 0===y||null===(P=y.imageGist)||void 0===P?void 0:P.r16x9),ne=(null===(I=Y)||void 0===I||null===(k=I.video)||void 0===k||null===(O=k.liveDetails)||void 0===O?void 0:O.isDvrEnabled)||!1,te=(null===(S=Y)||void 0===S||null===(E=S.video)||void 0===E||null===(j=E.streamingInfo)||void 0===j?void 0:j.isLiveStream)||!1,oe=(null==a?void 0:a.drmLibrary)||!1,re=(null===(D=Y)||void 0===D||null===(R=D.ads)||void 0===R||null===(F=R.preRoll)||void 0===F||null===(M=F.adTags)||void 0===M||null===(_=M.web)||void 0===_?void 0:_.active)&&(null===(V=Y)||void 0===V||null===(q=V.ads)||void 0===q||null===(L=q.preRoll)||void 0===L||null===(W=L.adTags)||void 0===W||null===(U=W.web)||void 0===U?void 0:U.url);Y=N(N({},Y),{},{audioAssetSource:null==a?void 0:a.audioAssetSource});var le=(K={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:ne},e(K,"autoplay",null==a?void 0:a.autoplay),e(K,"normalizeAutoplay",(null==a?void 0:a.autoplay)&&!re),e(K,"loop",(null==a?void 0:a.loop)||!1),e(K,"audioPosterMode",null==a?void 0:a.audioPosterMode),e(K,"html5",N(N({dash:N(N({},!o.browser.IS_SAFARI&&{useTTML:!0}),{},{updateSettings:{streaming:{delay:{liveDelay:localStorage.getItem("LATENCY")||5},liveCatchup:{maxDrift:0,playbackRate:{min:-.1,max:.1}},abr:{additionalAbrRules:{insufficientBufferRule:!0,switchHistoryRule:!0,droppedFramesRule:!0}}}}}),vhs:N(N({experimentalLLHLS:(null==a?void 0:a.lowLatency)||!1,limitRenditionByPlayerDimensions:!0,useDevicePixelRatio:!0,useNetworkInformationApi:!0},(null==a||null===(z=a.customData)||void 0===z?void 0:z.overrideNative)&&{overrideNative:!0}),{},{enableLowInitialPlaylist:(null==a?void 0:a.enableLowInitialPlaylist)||!1,experimentalBufferBasedABR:(null==a?void 0:a.experimentalBufferBasedABR)||!1})},0==(null==a||null===(G=a.customData)||void 0===G?void 0:G.nativeAudioTracks)&&{nativeAudioTracks:!1}),0==(null==a||null===(J=a.customData)||void 0===J?void 0:J.nativeVideoTracks)&&{nativeVideoTracks:!1})),e(K,"poster",ie),e(K,"techOrder",ee),e(K,"chromecast",{requestCustomDataFn:function(e){var n=r.getPlayer(i);console.log(n.textTracksJson_);var t=n.textTracksJson_.filter((function(e){return"subtitles"==e.kind}));return function(e,i,n){var t,o,r,l,a,d,s,u,c,v,m={};if(e&&e.video&&e.video.drmEnabled){m.isDrmEnabled=!0;var f=i.keySystemOptions&&i.keySystemOptions[0]&&i.keySystemOptions[0].options&&i.keySystemOptions[0].options.serverURL;m.licenseUrl=f;var w=i.keySystemOptions&&i.keySystemOptions[0]&&i.keySystemOptions[0].options&&i.keySystemOptions[0].options.httpRequestHeaders["X-AxDRM-Message"];m.licenseToken=w}var p=(null==e||null===(t=e.video)||void 0===t||null===(o=t.gist)||void 0===o?void 0:o.contentType)||"VIDEO";m.contentType=p;var h=null==e||null===(r=e.video)||void 0===r||null===(l=r.gist)||void 0===l?void 0:l.runtime;m.duration=h;var g=null==e||null===(a=e.video)||void 0===a||null===(d=a.gist)||void 0===d?void 0:d.title;m.mediaTitle=g;var y=null==e||null===(s=e.video)||void 0===s||null===(u=s.gist)||void 0===u?void 0:u.videoImageUrl;return m.mediaImage=y,m.subTitles=n,m.DVR=(null==e||null===(c=e.video)||void 0===c||null===(v=c.liveDetails)||void 0===v?void 0:v.isDvrEnabled)||!1,console.log(m),m}(Y,e,t)}}),K),ae=o(i,le,function(){var e=n(t.mark((function e(){var n,l,s,u,c,v,m,f,w,p,h,g,y,P,I,k,O,S,E,j,D,R,F,M;return t.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(b(a),te&&d.resolve(N({status:!0,msg:"Player Initialised"},Z?{seriesResponse:Z,response:Y}:{response:Y})),window.initialise(ae),window.firstFrame(ae),"white"!==window.controlsColor&&B(window.controlsColor,ae),/Android/i.test(navigator.userAgent)&&(o.options.vhs.overrideNative=!0),P=null===(n=Y)||void 0===n||null===(l=n.video)||void 0===l?void 0:l.drmEnabled,I=null===(s=Y)||void 0===s||null===(u=s.video)||void 0===u||null===(c=u.liveDetails)||void 0===c?void 0:c.startOverTime,!P&&!oe){e.next=21;break}if("Safari"!==r.detectBrowser()){e.next=14;break}return e.next=12,H();case 12:e.next=21;break;case 14:if("caliente"!=(null===(k=window)||void 0===k?void 0:k.siteName)){e.next=19;break}return e.next=17,H();case 17:e.next=21;break;case 19:return e.next=21,x();case 21:ne&&T(i,I),!re||null!=a&&null!==(v=a.customData)&&void 0!==v&&v.disableAds||r.initialiseAdvertisement(i,re,Y),(O=r.getSource(Y,i))?r.loadVideo(i,O):(d.reject({status:!1,msg:"Incompatible Source, only hls,mp4,drm content is allowed",response:Y}),r.handleError(i,"Incompatible Source, only hls,mp4,drm content is allowed")),((null===(m=Y)||void 0===m||null===(f=m.video)||void 0===f||null===(w=f.contentDetails)||void 0===w||null===(p=w.closedCaptions)||void 0===p?void 0:p.length)>0||(null===(h=Y)||void 0===h||null===(g=h.video)||void 0===g||null===(y=g.closedCaptions)||void 0===y?void 0:y.length)>0)&&(M=(null===(E=Y)||void 0===E||null===(j=E.video)||void 0===j||null===(D=j.contentDetails)||void 0===D?void 0:D.closedCaptions)||(null===(R=Y)||void 0===R||null===(F=R.video)||void 0===F?void 0:F.closedCaptions),S=M.filter((function(e){return"VTT"===e.format})),r.addCaptions(i,S)),null!=a&&a.disableControls?r.disableControls(i):A(i,N(N(N({},a),le),{},{liveVideo:te,isDvrEnabled:ne,res:Y,sres:Z})),C(i,N(N(N({},a),le),{},{liveVideo:te}),d,{res:Y,sres:Z});case 28:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}())};module.exports=function(){return{loadVideoInstantly:r.loadVideoInstantly,onTimeUpdate:l.onTimeUpdate,getVideoDuration:l.getVideoDuration,onVideoEnded:l.onVideoEnded,init:function(e){return new Promise((function(i,n){var t,o,l,a,d,c,v,m,f,w,p;if(!r.isPlayerInitialised(null==e?void 0:e.playerId)){var h=(null==e||null===(t=e.epg)||void 0===t?void 0:t.enable)||!1,g=null==e?void 0:e.videoId,y=(null==e||null===(o=e.series)||void 0===o?void 0:o.enable)||!1;window.videoId=g;var b=null==e?void 0:e.token;if(r.refreshTokenManager().set(null==e?void 0:e.refreshToken),b&&!r.isTokenExpired(b)){M=JSON.parse(atob(b.split(".")[1])),window.siteId=null===(l=M)||void 0===l?void 0:l.siteId,window.siteName=null===(a=M)||void 0===a?void 0:a.site,e.isAnonymousUser=!(null===(d=M)||void 0===d||!d.anonymousId),e.siteOwner=(null===(c=M)||void 0===c?void 0:c.site)||null,e.userId=(null===(v=M)||void 0===v?void 0:v.userId)||null,window.sessionStorage.setItem("uid",null===(m=M)||void 0===m?void 0:m.userId),window.watchHistory=e.watchHistory||null,sessionStorage.setItem("token",b);var T=null==e?void 0:e.playerId,P=e.chromecastReceiverId=null!=e&&e.series?null:null==e?void 0:e.chromecastReceiverId,I=null==e?void 0:e.airplay,k=null==e?void 0:e.apiBaseUrl,O=(null==e||null===(f=e.analytics)||void 0===f?void 0:f.gaId)||null,S=null==e?void 0:e.errors;S&&(window.customErrors=S),window.customData=null==e?void 0:e.customData,s.setLocalisation(null==e||null===(w=e.customData)||void 0===w?void 0:w.localisation),k&&(window.playerEntitlementUrl=k),window.controlsColor=(null==e?void 0:e.controlsColor)||"white",null!=e&&e.skin&&!r.isNotAValidSkin(e.skin)||(e.skin="defaultV2"),Promise.resolve().then((function(){return _})).then((function(e){e.importIMA()})),!P||null!=e&&e.series||Promise.resolve().then((function(){return _})).then((function(e){e.importChromecast()})),I&&"Safari"==r.detectBrowser()&&Promise.resolve().then((function(){return _})).then((function(e){e.importAirplay()})),O&&R("https://www.googletagmanager.com/gtag/js?id=".concat(O)).then((function(){return e=O,window.dataLayer=window.dataLayer||[],u("js",new Date),void u("config",e);var e})).catch((function(e){}));var E=null===(p=document)||void 0===p?void 0:p.getElementById("".concat(T));if(E&&E.addEventListener("contextmenu",(function(e){return e.preventDefault()})),y){var j,D=null==e||null===(j=e.series)||void 0===j?void 0:j.id;r.getSeriesDetails(D,b).then((function(t){var o,l,a,d=t.data,s=t.data.seasons;r.setCurrentSeries(s);var u=g||(null==s||null===(o=s[0])||void 0===o||null===(l=o.episodes)||void 0===l||null===(a=l[0])||void 0===a?void 0:a.id);!function(e,i){var n=new Map;r.getSeriesWatchHistory({videoId:e,token:i}).then((function(e){e.data.map((function(e){n.set(e.videoId,{t:e.watchedTime,p:e.watchedPercentage})})),r.setSeriesWatchMap(n)})).catch((function(e){return console.log(e)}))}(D,b),r.getVideoDetails(u,b).then((function(t){var o,l,a;window.contentType=null==t||null===(o=t.data)||void 0===o||null===(l=o.video)||void 0===l||null===(a=l.gist)||void 0===a?void 0:a.contentType,r.setCurrentVideo(t.data),q(T,{res:null==t?void 0:t.data,sres:d},e,{resolve:i,reject:n})})).catch((function(e){r.initiateErrorHandling(e,T,n,g)}))})).catch((function(e){r.initiateErrorHandling(e,T,n)}))}else if(h){var C=null==e?void 0:e.epg;r.getLinearChannelDetails(C,b).then((function(t){var o=null==t?void 0:t.data;o.contentType="linearchannel",q(T,{res:o},e,{resolve:i,reject:n})})).catch((function(e){r.initiateErrorHandling(e,T,n,g)}))}else r.getVideoDetails(g,b).then((function(t){var o,l,a,d;window.contentType=null==t||null===(o=t.data)||void 0===o||null===(l=o.video)||void 0===l||null===(a=l.gist)||void 0===a?void 0:a.contentType,r.setCurrentVideo(null==t?void 0:t.data);var s=null==t?void 0:t.data;null!=e&&e.watchHistory&&null!=e&&null!==(d=e.watchHistory)&&void 0!==d&&d.enable?r.getVideoInfo(g,b).then((function(t){var o,r,l,a,d,u;null!==(o=window)&&void 0!==o&&null!==(r=o.watchHistory)&&void 0!==r&&r.cb&&(null===(l=window)||void 0===l||null===(a=l.watchHistory)||void 0===a||a.cb(null==t?void 0:t.data)),e.watchHistoryResumeTime=(null==t||null===(d=t.data)||void 0===d?void 0:d.watchedTime)||null,e.watchedPercentage=(null==t||null===(u=t.data)||void 0===u?void 0:u.watchedPercentage)||null,s.contentType="video",q(T,{res:s},e,{resolve:i,reject:n})})).catch((function(t){var o,r,l,a;null!==(o=window)&&void 0!==o&&null!==(r=o.watchHistory)&&void 0!==r&&r.cb&&(null===(l=window)||void 0===l||null===(a=l.watchHistory)||void 0===a||a.cb(t)),q(T,{res:s},e,{resolve:i,reject:n})})):q(T,{res:s},e,{resolve:i,reject:n})})).catch((function(e){r.initiateErrorHandling(e,T,n,g)}))}else n({status:!1,msg:"".concat(b?"Token is expired !":"Missing Authorization Token"),response:{token:b}})}}))},getRenditions:a.getRenditions,skip:r.skip,getPlayer:r.getPlayer,play:r.play,pause:r.pause,detectBrowser:r.detectBrowser,rewind:r.rewind,loadVideo:r.loadVideo,seekToTimeStamp:l.seekToTimeStamp,isPlayerInitialised:r.isPlayerInitialised,load:r.load,dispose:r.dispose,enableCaptions:r.enableCaptions,disableCaptions:r.disableCaptions,getCaptions:r.getCaptions,playSelectedResolution:d.playSelectedResolution,getSource:r.getSource,setVolume:E,getVolume:j,disableControls:r.disableControls,setPlaybackSpeed:l.setPlaybackSpeed}};
@@ -1 +1 @@
1
- "use strict";var e=require("./generic-846ad3ba.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
+ "use strict";var e=require("./generic-0f02a1e1.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}}))};
@@ -0,0 +1 @@
1
+ "use strict";var t={};exports.getLocalisation=function(o){var i;return(null===(i=t)||void 0===i?void 0:i[o])||""},exports.setLocalisation=function(o){t=o};
@@ -0,0 +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"),a=require("./loader-393b838a.js"),u=require("./generic-0f02a1e1.js");function c(e){var t=d();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)}}function d(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(d=function(){return!!e})()}require("axios"),require("js-cookie"),require("ua-parser-js"),require("@babel/runtime/helpers/toConsumableArray");var v=s.getComponent("Component"),m=function(){l(r,v);var n=c(r);function r(t){var l,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e(this,r),l=n.call(this,t,s),o(i(l),"multicamCssPositioning",(function(e,t){var n,r,o,s,a,u,c,d,v=window.getComputedStyle(document.getElementById(t),null),m=v.getPropertyValue("height"),h=v.getPropertyValue("width"),f=m.slice(0,-2);h.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!==(a=i(l))&&void 0!==a&&null!==(u=a.config)&&void 0!==u&&u.liveui&&null!==(c=i(l))&&void 0!==c&&null!==(d=c.config)&&void 0!==d&&d.liveVideo?(e.style.bottom="".concat(f-135,"px"),e.style.height="".concat(f-85,"px")):(e.style.bottom="3rem",e.style.height="".concat(f-105,"px"))})),l.playerId=s.playerId,l.streams=null==s?void 0:s.streams,l.config=null==s?void 0:s.config,l.createUI(null==s?void 0:s.streams),l}return t(r,[{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,a=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==a||null===(r=a.classList)||void 0===r||r.add("".concat(this.config.skin)):null==a||null===(o=a.classList)||void 0===o||o.add("default"),this.loadCSS();for(var u=0;u<e.length;u++)this.createTile(e[u],u);this.multicamCssPositioning(a,this.playerId),window.onresize=function(){s.multicamCssPositioning(a,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){a.showLoader(i.playerId),i.removeSelectedTile();var l=document.getElementsByClassName("".concat(t.srcElement.className))[0];l&&(l.style.border="2px solid red"),u.load(i.playerId,e.id,r).then((function(e){u.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)}))}}]),r}();exports.default=m;
@@ -0,0 +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-0f7b3404.js"),l=require("./generic-0f02a1e1.js");function i(e){var t=c();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)}}function c(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(c=function(){return!!e})()}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(){r(a,d);var n=i(a);function a(t){var r,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e(this,a),(r=n.call(this,t,s)).playerId=s.playerId,r.seriesData=s.sres,r.streams=s.streams,r.currentVideoData=s.res,r.initialiseStructure(),r.loadCSS(),r}return t(a,[{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")?(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 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")}))}}]),a}();exports.default=u;
@@ -0,0 +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-0f02a1e1.js");function a(e){var t=c();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)}}function c(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(c=function(){return!!e})()}require("@babel/runtime/helpers/defineProperty"),require("axios"),require("js-cookie"),require("ua-parser-js"),require("@babel/runtime/helpers/toConsumableArray");var d=o.getComponent("Component"),u=function(){l(n,d);var r=a(n);function n(t){var l,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e(this,n),(l=r.call(this,t,o)).playerId=o.playerId,l.config=o.config,l.createUI(null==o?void 0:o.config.streams),l}return t(n,[{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")))}}]),n}();exports.default=u;
@@ -0,0 +1 @@
1
+ "use strict";var e=require("@babel/runtime/helpers/classCallCheck"),n=require("@babel/runtime/helpers/createClass"),t=require("@babel/runtime/helpers/inherits"),i=require("@babel/runtime/helpers/possibleConstructorReturn"),r=require("@babel/runtime/helpers/getPrototypeOf"),o=require("video.js"),l=require("./icons-0f7b3404.js"),s=require("./generic-0f02a1e1.js");function a(e){var n=d();return function(){var t,o=r(e);if(n){var l=r(this).constructor;t=Reflect.construct(o,arguments,l)}else t=o.apply(this,arguments);return i(this,t)}}function d(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(d=function(){return!!e})()}require("@babel/runtime/helpers/defineProperty"),require("axios"),require("js-cookie"),require("ua-parser-js"),require("@babel/runtime/helpers/toConsumableArray");var u=o.getComponent("Component"),c=function(){t(r,u);var i=a(r);function r(n){var t,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e(this,r),(t=i.call(this,n,o)).playerId=o.playerId,t.seriesData=o.sres,t.currentVideoData=o.res,t.initialiseStructure(),t.loadCSS(),t}return n(r,[{key:"createEl",value:function(){var e=o.dom.createEl("div",{className:"play-next"}),n=o.dom.createEl("div",{className:"play-next-icon",innerHTML:"".concat(l.PlayNextEpisodeSvg(window.controlsColor?window.controlsColor:"white"))});return o.dom.appendContent(e,n),e}},{key:"loadCSS",value:function(){Promise.resolve().then((function(){return require("./nextEpisodeButton-b6e6586f.js")})).then((function(e){var n=document.createElement("style");n.id="multicam",n.append("".concat(e.default)),document.head.appendChild(n)}))}},{key:"initialiseStructure",value:function(){var e=this.el(),n=o.dom.createEl("div",{className:"next-eps nextepisode-hidden"}),t=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"}),l=o.dom.createEl("div",{className:"next-eps-description"});o.dom.appendContent(i,r),o.dom.appendContent(i,l),o.dom.appendContent(n,t),o.dom.appendContent(n,i),this.toggleContentOnHover(e,n),o.dom.appendContent(e,n)}},{key:"toggleContentOnHover",value:function(e,n){e.addEventListener("mouseover",(function(){o.dom.removeClass(n,"nextepisode-hidden")})),n.addEventListener("mouseover",(function(){o.dom.removeClass(n,"nextepisode-hidden")})),e.addEventListener("mouseout",(function(){o.dom.addClass(n,"nextepisode-hidden")})),n.addEventListener("mouseout",(function(){o.dom.addClass(n,"nextepisode-hidden")}))}}]),r}(),p=function(e,n){for(var t=-1,i=0;i<e.length;i++)for(var r=0;r<e[i].episodes.length;r++)if(e[i].episodes[r].id===n){t=i;break}return t},v=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,n=arguments.length>1?arguments[1]:void 0;if(!(e&&n>=0))return{prevEp:null,nextEp:null};var t=e.episodes.length,i=n-1>=0?n-1:t-1,r=(n+1)%t,o=t>1?e.episodes[i]:null,l=t>1?e.episodes[r]:null;return i===r&&(0===i?l=null:o=null),{prevEp:o,nextEp:l,prevEpIdx:i,nextEpIdx:r}},m=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,n=arguments.length>1?arguments[1]:void 0,t=null;return e?(e.episodes.forEach((function(e,i){e.gist.id===n&&(t=i)})),t):null},f=function(e){var n,t;o.dom.$(".next-eps"),o.dom.$(".play-next").onclick=function(){var n,t=sessionStorage.getItem("token");s.load("my-player",null==e||null===(n=e.gist)||void 0===n?void 0:n.id,t).then((function(e){s.setCurrentVideo(e.response)}))};var i=o.dom.$(".next-eps-image"),r=s.parseHtmlString("<img src=".concat(null==e||null===(n=e.gist)||void 0===n?void 0:n.videoImageUrl," />")),l=null==r?void 0:r.firstChild;null==i||i.append(l);for(var a=o.dom.$(".next-eps-description"),d=s.parseHtmlString("<div class='next-eps-title'>".concat(null==e?void 0:e.title,"</div>\n <div class='next-eps-description-details'>").concat(null==e||null===(t=e.gist)||void 0===t?void 0:t.description,"</div>"));null!=d&&d.firstChild;)null==a||a.appendChild(d.firstChild)};exports.default=c,exports.initaliseFunctionality=function(e,n){var t=p(e,n.video.gist.id),i=m(e[t],n.video.gist.id),r=v(e[t],i);f(r.nextEp)};
@@ -0,0 +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-0f7b3404.js"),r=require("./generic-0f02a1e1.js"),d=require("./autoNextVideo-86ec33b5.js");function c(e){var t=u();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)}}function u(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(u=function(){return!!e})()}require("@babel/runtime/helpers/defineProperty"),require("axios"),require("js-cookie"),require("ua-parser-js"),require("./util-05c0ddf6.js");var p=a.getComponent("Component"),m=function(){l(o,p);var i=c(o);function o(e){var n,l,a,s,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t(this,o),(s=i.call(this,e,r)).playerId=r.playerId,s.seriesData=r.sres,s.videos=null==r||null===(n=r.playlist)||void 0===n?void 0:n.content,s.cb=(null==r||null===(l=r.playlist)||void 0===l?void 0:l.cb)||null,s.autoNext=(null==r||null===(a=r.playlist)||void 0===a?void 0:a.autoNext)||!1,s.currentVideoData=r.res,s.initialiseStructure(),s.loadCSS(),s.autoNext&&d.autoPlayNext({playerId:s.playerId,content:s.videos,cb:s.cb}),s}return n(o,[{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")?(r.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 d=a.dom.createEl("div",{className:"playlist-selector-title",innerHTML:"Playlist"}),c=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}),d=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,d),a.dom.appendContent(s,u),a.dom.appendContent(o,s),a.dom.appendContent(c,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(c,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,d),a.dom.appendContent(t,i),a.dom.appendContent(t,c),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")}))}}]),o}();exports.default=m;
@@ -1 +1 @@
1
- "use strict";var l=require("./generic-846ad3ba.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
+ "use strict";var l=require("./generic-0f02a1e1.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};
@@ -0,0 +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-0f02a1e1.js");function c(e){var t=u();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)}}function u(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(u=function(){return!!e})()}require("axios"),require("js-cookie"),require("ua-parser-js");var h=r.getComponent("Component"),v=function(){a(d,h);var o=c(d);function d(n){var a,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t(this,d),a=o.call(this,n,s),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==s?void 0:s.playerId,a.skin=null==s?void 0:s.skin,a.icon=null==s?void 0:s.icon,a.masterRenditions=[],a.fontSizeOptions=[10,12,14],a.createRenditions(s.renditions),window.height=null,a}return n(d,[{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(),i=r.dom.$(".setting-icon",this.el()),a=s.parseSvgString(this.icon);if(i.append(a),"live"===this.skin){var o=document.createTextNode(" Settings");i.appendChild(o)}var d=r.dom.createEl("div",{className:"content hidden"}),l=r.dom.createEl("div",{innerHTML:"Quality",className:"title"}),c=r.dom.createEl("div",{className:"resolution"});r.dom.appendContent(c,l),this.toggleContentOnHover(n,d);var u=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"}),d=(((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),l="".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>":"");l="".concat(e.height,"p @ ").concat(d,"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 s=r.dom.createEl("p",{innerHTML:l,className:"rendition",res:e.height,bandwidth:e.bandwidth});r.dom.appendContent(o,s),r.dom.appendContent(u,o),s.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,p(t.playerId,e.target),r.dom.addClass(s,"selected"))}))})),this.addAutoRendition("nondrm",u),"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 d=r.dom.createEl("p",{innerHTML:o,className:"rendition",res:e.height,qualityIndex:e.qualityIndex});r.dom.appendContent(i,d),r.dom.appendContent(u,i),d.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,p(t.playerId,e.target),r.dom.addClass(d,"selected"))}))})),this.addAutoRendition("drm",u)),r.dom.appendContent(c,u),r.dom.appendContent(d,c),r.dom.appendContent(n,d)}},{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").textContent="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,p(n.playerId,null,!0))})),r.dom.appendContent(c,u),r.dom.appendContent(t,c)}else{var h=r.dom.createEl("div",{className:"relative"}),v=r.dom.createEl("p",{innerHTML:"Auto",className:"rendition selected",qualityIndex:"auto"});v.addEventListener("click",(function(e){n.resetRenditions(),r.dom.addClass(v,"selected"),window.qualityIndex=e.target.qualityIndex,window.selectedVideo=e.target.video,p(n.playerId,null,!0)})),r.dom.appendContent(h,v),r.dom.appendContent(t,h)}}}]),d}(),p=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 w=r.dom.$(".content");w&&r.dom.addClass(w,"hidden")}}};exports.default=v,exports.playSelectedResolution=p;
@@ -0,0 +1 @@
1
+ "use strict";var e=require("@babel/runtime/helpers/asyncToGenerator"),i=require("@babel/runtime/helpers/classCallCheck"),t=require("@babel/runtime/helpers/createClass"),s=require("@babel/runtime/helpers/assertThisInitialized"),n=require("@babel/runtime/helpers/inherits"),r=require("@babel/runtime/helpers/possibleConstructorReturn"),a=require("@babel/runtime/helpers/getPrototypeOf"),o=require("@babel/runtime/helpers/defineProperty"),l=require("@babel/runtime/regenerator"),c=require("video.js"),d=require("./generic-0f02a1e1.js"),u=require("./loader-393b838a.js"),p=require("./icons-0f7b3404.js");function v(e){var i=h();return function(){var t,s=a(e);if(i){var n=a(this).constructor;t=Reflect.construct(s,arguments,n)}else t=s.apply(this,arguments);return r(this,t)}}function h(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(h=function(){return!!e})()}require("axios"),require("js-cookie"),require("ua-parser-js"),require("@babel/runtime/helpers/toConsumableArray");var f,m=c.getComponent("Component"),g=function(){n(r,m);var e=v(r);function r(t){var n,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return i(this,r),n=e.call(this,t,a),o(s(n),"seriesData",[]),n.seriesData=a.seriesData,f=a.playerId,b(n.el(),n.seriesData),n.loadCSS(),n}return t(r,[{key:"createEl",value:function(){var e=document.createElement("div");return e.classList.add("vjs-season-list"),e}},{key:"loadCSS",value:function(){Promise.resolve().then((function(){return require("./series-9c237975.js")})).then((function(e){var i=document.createElement("style");i.id="series",i.append("".concat(e.default)),document.head.appendChild(i)}))}}]),r}();function y(){return(y=e(l.mark((function e(i,t,s,n){var r;return l.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:r=sessionStorage.getItem("token"),d.pause(f),u.showLoader(f),d.load(f,t,r).then((function(e){d.setCurrentVideo(e.response),d.play(f)}));case 4:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function b(e,i){for(var t='<div class="hover-div"></div>\n '.concat(p.EpisodesSvg(),'\n <div class="player-season-list-container on-click-toggle">\n <div id="season-list" class="season-list">\n <div class="season-list-head">seasons</div>\n <div class="season-name-container">\n ').concat(function(e){return e.map((function(e,i){return'<div\n class="season-title-sdk"\n key='.concat("title-".concat(e.title),'\n > <div class="season-container">\n ',e.title,"\n </div>\n </div>\n ")})).join("")}(i),'\n </div>\n </div>\n <div id="episode-list" class="episode-list hide-container"><div id="episodes-back-btn" class="episodes-back-btn" >\n <svg class=\'icon icon-backward\' height="22px" width="22px" viewBox="0 0 18 18" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path fill-rule="evenodd" clip-rule="evenodd" d="M0.383092 19.5818C-0.0882695 19.0669 -0.124672 18.2566 0.273985 17.6961L0.382714 17.5615L7.30134 9.99714L0.383092 2.43893C-0.0882694 1.92406 -0.124672 1.11374 0.273985 0.553232L0.382714 0.418625C0.853882 -0.0964584 1.59542 -0.136236 2.10835 0.299398L2.23153 0.418213L11 9.99608L2.23191 19.5814C1.72148 20.1394 0.893733 20.1396 0.383092 19.5818Z" fill="white"/>\n </svg>\n <span>Episodes<span></div> <div id="episode-container" class="episode-container"> </div></div>\n </div>');null!=e&&e.firstChild;)e.removeChild(e.firstChild);for(var s=d.parseHtmlString(t);null!=s&&s.firstChild;)e.appendChild(s.firstChild)}exports.customSeasonList=b,exports.handleSeasonChange=function(e,i,t,s){var n=document.getElementById("season-list"),r=document.getElementById("episode-list"),a=document.getElementById("episode-container");e.id;for(var o=e.episodes.map((function(e,i){return'\n <div id="episode-wrapper" class="episode-wrapper">\n <div class="episode-title" id="episode-title">\n <div class="details-wrapper">\n <div id="title-wrapper" class="title-wrapper">'.concat(i+1," ").concat(e.title,' </div>\n <div class="progress-bar-div">\n <div id="progress-div" class="progress-div"></div>\n </div>\n </div>\n <div class="meta-details">\n <div class="episode-image lazy" style="width:124px; height: 70px;">\n <img src=').concat(e.gist.videoImageUrl,' alt="').concat(e.title,'\'s cover"></img>\n </div>\n <div class="description-wrapper">').concat(e.gist.description,"</div>\n </div>\n </div>\n </div>")})).join("");null!=a&&a.firstChild;)a.removeChild(a.firstChild);for(var l=d.parseHtmlString(o);null!=l&&l.firstChild;)a.appendChild(l.firstChild);!function(e){d.getSeriesWatchHistory(e).then((function(e){var i=e.data,t=document.querySelectorAll("#progress-div");t&&i.map((function(e,i){e&&e.watchedPercentage&&t[i]&&(t[i].style.width=e.watchedPercentage+"px")}))})).catch((function(e){}))}(s),n.classList.toggle("hide-container"),r.classList.toggle("hide-container");var c=document.querySelectorAll(".details-wrapper"),u=document.querySelectorAll("#episode-title"),p=document.querySelectorAll(".meta-details"),v=document.querySelector("#episodes-back-btn"),h=e.id,f=e.episodes;v.addEventListener("click",(function(){return function(e,i){e.classList.remove("hide-container"),i.classList.add("hide-container")}(n,r)}));for(var m=function(i){c[i].addEventListener("click",(function(){return function(e,i,t){var s=i.querySelector(".meta-details");i.classList.toggle("episode-active"),s.classList.toggle("metadetails-active"),t.forEach((function(i,s){s!==e&&(t[s].classList.remove("episode-active"),t[s].querySelector(".meta-details").classList.remove("metadetails-active"))}))}(i,u[i],u)})),p[i].addEventListener("click",(function(){return function(e,i,t,s){return y.apply(this,arguments)}(i,f[i].id,t,u)})),e.episodes[i].id==h&&u[i].classList.add("highlight-active-eps")},g=0;g<c.length;g++)m(g)},exports.seriesModule=g;
@@ -0,0 +1 @@
1
+ "use strict";var e=require("@babel/runtime/helpers/toConsumableArray"),t=require("@babel/runtime/helpers/classCallCheck"),n=require("@babel/runtime/helpers/createClass"),s=require("@babel/runtime/helpers/assertThisInitialized"),i=require("@babel/runtime/helpers/inherits"),o=require("@babel/runtime/helpers/possibleConstructorReturn"),l=require("@babel/runtime/helpers/getPrototypeOf"),r=require("video.js"),a=require("./icons-0f7b3404.js"),d=require("./generic-0f02a1e1.js");require("@babel/runtime/helpers/defineProperty"),require("axios");var c=require("./autoNextVideo-86ec33b5.js");function u(e){var t=v();return function(){var n,s=l(e);if(t){var i=l(this).constructor;n=Reflect.construct(s,arguments,i)}else n=s.apply(this,arguments);return o(this,n)}}function v(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(v=function(){return!!e})()}require("js-cookie"),require("ua-parser-js"),require("./util-05c0ddf6.js");var p=r.getComponent("Component"),m=function(){i(l,p);var o=u(l);function l(n){var i,r,a,u,v,p,m=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(t(this,l),(p=o.call(this,n,m)).playerId=m.playerId,p.seriesData=m.sres,p.videos=null==m||null===(i=m.sres)||void 0===i?void 0:i.seasons,p.currentVideoData=m.res,p.initialiseStructure(),p.loadCSS(),p.selectedSeason=0,p.cb=null==m||null===(r=m.series)||void 0===r?void 0:r.cb,p.autoPlayNext=(null==m||null===(a=m.series)||void 0===a?void 0:a.autoPlayNext)||!1,sessionStorage.getItem("token"),p.watchMap=d.getSeriesWatchMap(),null!==(u=s(p))&&void 0!==u&&u.autoPlayNext&&null!=m&&null!==(v=m.series)&&void 0!==v&&v.enable){var h,g,f,C,y=null==m||null===(h=m.sres)||void 0===h?void 0:h.seasons,b=[];y.map((function(t){b.push.apply(b,e(t.episodes))})),d.createIdxMapping(b),d.setVideoIdxById(null===(g=p.options_)||void 0===g||null===(f=g.res)||void 0===f||null===(C=f.video)||void 0===C?void 0:C.id),c.autoPlayNext({playerId:p.playerId,content:b,cb:p.cb,series:null==m?void 0:m.sres})}return p}return n(l,[{key:"createEl",value:function(){var e=r.dom.createEl("div",{className:"series-selection vjs-control vjs-button"});e.style.position="unset";var t=r.dom.createEl("div",{className:"series-selector-icon",innerHTML:"".concat(a.EpisodesSvg())});return r.dom.appendContent(e,t),e}},{key:"loadCSS",value:function(){Promise.resolve().then((function(){return require("./series-v2-70137d8c.js")})).then((function(e){var t=document.createElement("style");t.id="series-v2",t.append("".concat(e.default)),document.head.appendChild(t)}))}},{key:"toggleOpenClose",value:function(e){var t,n=this.el();null!=e&&null!==(t=e.classList)&&void 0!==t&&t.contains("hidden")?(d.closeOpenDrawers(),e.classList.remove("hidden"),n.classList.add("open"),e.style.right="0px"):(e.classList.add("hidden"),n.classList.remove("open"),e.style.right="-350px")}},{key:"initialiseStructure",value:function(){var e=this,t=this.el(),n=r.dom.createEl("div",{className:"series-selection-container hidden"});r.dom.$(".series-selector-icon",this.el()).onclick=function(){return e.toggleOpenClose(n)};var s=window.getComputedStyle(document.getElementById(this.playerId),null).getPropertyValue("height").slice(0,-2);n.style.height="".concat(s,"px"),r.dom.appendContent(t,n),document.getElementById(this.playerId).style.overflow="hidden",this.addFunctionality(n)}},{key:"addFunctionality",value:function(e){var t=this,n=this.el(),s=r.dom.createEl("div",{className:"series-selector-head"}),i=r.dom.createEl("div",{className:"series-selector-cross-icon",innerHTML:"".concat(a.crossIconSvg())});i.onclick=function(){if("series-selector-cross-icon"===i.className)e.classList.add("hidden"),n.classList.remove("open"),e.style.right="-350px";else if("series-selector-back-icon"===i.className){var s=r.dom.$(".series-selector-content",t.el());for(r.dom.$(".series-selector-cross-icon",t.el()),i.className="series-selector-cross-icon";null!=s&&s.firstChild;)s.removeChild(s.firstChild);var o=t.createSeasonLister();for(r.dom.appendContent(s,o),r.dom.$(".series-selector-title",t.el()).textContent="Seasons";null!=i&&i.firstChild;)i.removeChild(i.firstChild);var l=d.parseSvgString(a.crossIconSvg());i.appendChild(l)}};var o=r.dom.createEl("div",{className:"series-selector-title",innerHTML:"Seasons"}),l=r.dom.createEl("div",{className:"series-selector-content"}),c=this.createSeasonLister();r.dom.appendContent(l,c),r.dom.appendContent(s,i),r.dom.appendContent(s,o),r.dom.appendContent(e,s),r.dom.appendContent(e,l),d.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:"createSeasonLister",value:function(){var e=this;d.getPlayer(this.playerId);for(var t=d.getCurrentSeries(),n=r.dom.createEl("div",{className:"season-container"}),s=function(s){var i,o=document.createElement("label");o.className="season-holder",o.setAttribute("for","season-".concat(s));var l=document.createElement("div");l.className="season - ".concat(s),l.textContent=null===(i=t[s])||void 0===i?void 0:i.title;var a=r.dom.createEl("input",{className:"radio - ".concat(s),id:"season-".concat(s),name:"season-radio"});a.setAttribute("type","radio"),e.selectedSeason==s&&(a.checked=!0),a.onclick=function(t){e.showSeasonDetails(s)},r.dom.appendContent(o,a),r.dom.appendContent(o,l),r.dom.appendContent(n,o)},i=0;i<t.length;i++)s(i);return n}},{key:"getSeasonDetailsContainer",value:function(t,n){var s=this;t=t.map((function(e){var t,n,i,o,l;return{id:null==e?void 0:e.id,title:null==e?void 0:e.title,description:null==e||null===(t=e.gist)||void 0===t?void 0:t.description,img:null==e||null===(n=e.gist)||void 0===n||null===(i=n.imageGist)||void 0===i?void 0:i.r16x9,watchedPercentage:(null==s||null===(o=s.watchMap)||void 0===o||null===(l=o.get(null==e?void 0:e.id))||void 0===l?void 0:l.p)||0}}));for(var i=function(i){var o,l,a,c,u,v,p,m=r.dom.createEl("div",{className:"series-container"}),h=r.dom.createEl("div",{className:"series-section",index:i}),g=r.dom.createEl("div",{className:"series-title",innerHTML:"".concat((null===(o=t[i])||void 0===o?void 0:o.title)||"")}),f=r.dom.createEl("div",{className:"series-progress-bar",innerHTML:"<div style='width:".concat(t[i].watchedPercentage,"%' class='series-progress-bar-value'></div>")});r.dom.appendContent(h,g),r.dom.appendContent(h,f),r.dom.appendContent(m,h),r.dom.appendContent(n,m);var C=r.dom.createEl("div",{className:"series-section-expanded hidden"}),y=(null===(l=t[i])||void 0===l?void 0:l.description)||"";(null===(a=y)||void 0===a?void 0:a.length)>170&&(y=y.substr(0,170)+"...");var b=r.dom.createEl("div",{className:"series-description",innerHTML:"".concat(y||"")}),S=r.dom.createEl("img",{className:"series-image"});S.src="".concat((null===(c=t[i])||void 0===c?void 0:c.img)||(null===(u=window)||void 0===u||null===(v=u.customData)||void 0===v?void 0:v.fallbackImage)),S.alt="".concat(null===(p=t[i])||void 0===p?void 0:p.title),r.dom.appendContent(C,S),r.dom.appendContent(C,b),r.dom.appendContent(m,C),r.dom.appendContent(n,m),C.onclick=function(e){var n;e.stopPropagation(),d.setVideoIdxById(null===(n=t[i])||void 0===n?void 0:n.id),d.load(s.playerId,t[i].id,sessionStorage.getItem("token")).then((function(e){null!=s&&s.cb&&s.cb(e)})).catch((function(e){null!=s&&s.cb&&s.cb(e)}))},h.onclick=function(t){var n,s,i,o=document.getElementsByClassName("series-selector-content")[0].childNodes,l=(o=e(o))[t.target.index].getElementsByClassName("series-section-expanded")[0];null!=l&&null!==(n=l.classList)&&void 0!==n&&n.contains("hidden")?(m.style.backgroundColor="#0000007d",null==l||null===(s=l.classList)||void 0===s||s.remove("hidden")):(null==l||null===(i=l.classList)||void 0===i||i.add("hidden"),m.style.backgroundColor="unset")}},o=0;o<t.length;o++)i(o);return parent}},{key:"showSeasonDetails",value:function(e){this.selectedSeason=e;for(var t=r.dom.$(".series-selector-content",this.el());null!=t&&t.firstChild;)t.removeChild(t.firstChild);var n=d.getCurrentSeries()[e].episodes;this.getSeasonDetailsContainer(n,t);var s=r.dom.$(".series-selector-cross-icon",this.el());for(s.className="series-selector-back-icon";null!=s&&s.firstChild;)s.removeChild(s.firstChild);var i=d.parseSvgString(a.BackIcon());s.appendChild(i),r.dom.$(".series-selector-title",this.el()).textContent="Season ".concat(e+1)}}]),l}();exports.default=m;
@@ -0,0 +1 @@
1
+ "use strict";var e=require("@babel/runtime/helpers/toConsumableArray"),t=require("@babel/runtime/helpers/classCallCheck"),n=require("@babel/runtime/helpers/createClass"),a=require("@babel/runtime/helpers/inherits"),i=require("@babel/runtime/helpers/possibleConstructorReturn"),o=require("@babel/runtime/helpers/getPrototypeOf"),r=require("video.js"),l=require("./icons-0f7b3404.js"),s=require("./generic-0f02a1e1.js"),c=require("./renditions-07d76d50.js"),d=require("./resolution-0c41f25d.js"),u=require("./localisation-56e0a999.js");function p(e){var t=m();return function(){var n,a=o(e);if(t){var r=o(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return i(this,n)}}function m(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(m=function(){return!!e})()}require("@babel/runtime/helpers/defineProperty"),require("axios"),require("js-cookie"),require("ua-parser-js"),require("@babel/runtime/helpers/assertThisInitialized");var h=r.getComponent("Component"),v=function(){a(o,h);var i=p(o);function o(e){var n,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t(this,o),(n=i.call(this,e,a)).playerId=a.playerId,n.seriesData=a.sres,n.currentVideoData=a.res,n.initialiseStructure(),n.loadCSS(),n}return n(o,[{key:"createEl",value:function(){var e=r.dom.createEl("div",{className:"settings-selection vjs-control vjs-button"});e.style.position="unset";var t=r.dom.createEl("div",{className:"settings-selector-icon",innerHTML:"".concat(l.SettingsSvgV2())});return r.dom.appendContent(e,t),e}},{key:"loadCSS",value:function(){Promise.resolve().then((function(){return require("./settings-icon-e6a8feee.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.el(),t=r.dom.createEl("div",{className:"selection-container hidden"});r.dom.$(".settings-selector-icon",this.el()).onclick=function(){var n;null!==(n=t.classList)&&void 0!==n&&n.contains("hidden")?(s.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");t.style.height="".concat(n),r.dom.appendContent(e,t),document.getElementById(this.playerId).style.overflow="hidden",this.addFunctionality(t),s.detectOrientationChange(this.playerId,t)}},{key:"addFunctionality",value:function(e){var t=this,n=this.el(),a=r.dom.createEl("div",{className:"settings-selector-head"}),i=r.dom.createEl("div",{className:"settings-selector-cross-icon",innerHTML:"".concat(l.crossIconSvg())});i.onclick=function(){e.classList.add("hidden"),n.classList.remove("open"),e.style.right="-350px"};var o=r.dom.createEl("div",{className:"settings-selector-title",innerHTML:u.getLocalisation("settingsTitle")||"Settings"}),c=r.dom.createEl("div",{className:"settings-selector-content"}),d=r.dom.createEl("div",{className:"settings-container"}),p=this.createVideoQualityContainer();r.dom.appendContent(d,p);var m=this.createAudioQualityContainer();r.dom.appendContent(d,m),r.dom.appendContent(a,i),r.dom.appendContent(a,o),r.dom.appendContent(e,a),r.dom.appendContent(e,c),r.dom.appendContent(c,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:"createAudioQualityContainer",value:function(){var e=s.getPlayer(this.playerId),t=null==e?void 0:e.audioTracks().tracks_;if(!((null==t?void 0:t.length)<=1)){var n=r.dom.createEl("div",{className:"audio-language-container"}),a=r.dom.createEl("div",{className:"audio-language-container-title",innerHTML:u.getLocalisation("audioLanguageText")||"Audio Language"});r.dom.appendContent(n,a);for(var i=function(e){var a,i=document.createElement("label");i.className="audio-language-holder",i.setAttribute("for","language-radio-".concat(e));var o=document.createElement("div");o.className="audio - ".concat(e),o.textContent=null==t||null===(a=t[e])||void 0===a?void 0:a.label;var l=r.dom.createEl("input",{className:"radio - ".concat(e),id:"language-radio-".concat(e),name:"audio-language-radio"});l.setAttribute("type","radio"),1==t[e].enabled&&(l.checked=!0),l.onchange=function(n){t.map((function(e){e.enabled=!1})),t[e].enabled=!0},r.dom.appendContent(i,l),r.dom.appendContent(i,o),r.dom.appendContent(n,i)},o=0;o<t.length;o++)i(o);return n}}},{key:"createVideoQualityContainer",value:function(){var t=this,n=r.dom.createEl("div",{className:"video-quality-container"}),a=r.dom.createEl("div",{className:"video-quality-container-title",innerHTML:u.getLocalisation("videoQualityText")||"Video Quality"});r.dom.appendContent(n,a);var i=[].concat(e(c.getRenditions(this.playerId)),[{height:"Auto"}]);d.playSelectedResolution(this.playerId,"raw",!0);for(var o=function(e){var a,o,l,c=document.createElement("label");c.className="video-quality-holder",c.setAttribute("for","quality".concat(e));var u=document.createElement("div");u.className="video-quality - ".concat(e);var p=(null==i||null===(a=i[e])||void 0===a?void 0:a.height)+"".concat("Auto"==(null==i||null===(o=i[e])||void 0===o?void 0:o.height)?"":"p"),m=document.createTextNode(p);if(u.appendChild(m),(null==i||null===(l=i[e])||void 0===l?void 0:l.height)>=720)for(var h=s.parseHtmlString("<span class='hd-rendition'> HD </span>");null!=h&&h.firstChild;)u.appendChild(h.firstChild);var v=r.dom.createEl("input",{className:"radio - ".concat(e),id:"quality".concat(e),name:"quality-radio",rendata:"".concat(i[e]),checked:"".concat(e==i.length-1)});v.setAttribute("type","radio"),v.onchange=function(n){var a=i[e];"true"=="".concat("Auto"==i[e].height)?d.playSelectedResolution(t.playerId,a,!0):d.playSelectedResolution(t.playerId,a)},r.dom.appendContent(c,v),r.dom.appendContent(c,u),r.dom.appendContent(n,c)},l=0;l<i.length;l++)o(l);return n}}]),o}();exports.default=v;
@@ -1 +1 @@
1
- "use strict";var e=require("./generic-846ad3ba.js");require("@babel/runtime/helpers/defineProperty"),require("video.js"),require("axios"),require("js-cookie"),require("ua-parser-js"),require("@babel/runtime/helpers/toConsumableArray");var r=function(){document.getElementsByClassName("vjs-control-bar")[0].style.visibility="hidden"};exports.initaliseSkin=function(t){Promise.resolve().then((function(){return require("./skin-225252ff.js")})).then((function(e){var r=document.createElement("style");r.id="carousel_homepage",r.append("".concat(e.default)),document.head.appendChild(r)})),r(),function(r){var t=document.getElementById("".concat(r)),n=e.getPlayer(r);t&&t.addEventListener("touchstart",(function(){n.paused()?e.play(r):e.pause(r)}))}(t)};
1
+ "use strict";var e=require("./generic-0f02a1e1.js");require("@babel/runtime/helpers/defineProperty"),require("video.js"),require("axios"),require("js-cookie"),require("ua-parser-js"),require("@babel/runtime/helpers/toConsumableArray");var r=function(){document.getElementsByClassName("vjs-control-bar")[0].style.visibility="hidden"};exports.initaliseSkin=function(t){Promise.resolve().then((function(){return require("./skin-225252ff.js")})).then((function(e){var r=document.createElement("style");r.id="carousel_homepage",r.append("".concat(e.default)),document.head.appendChild(r)})),r(),function(r){var t=document.getElementById("".concat(r)),n=e.getPlayer(r);t&&t.addEventListener("touchstart",(function(){n.paused()?e.play(r):e.pause(r)}))}(t)};
@@ -0,0 +1 @@
1
+ "use strict";var e=require("./generic-0f02a1e1.js"),r=require("./features-ad62299c.js"),i=require("./renditions-07d76d50.js");require("@babel/runtime/helpers/defineProperty"),require("video.js"),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/inherits"),require("@babel/runtime/helpers/possibleConstructorReturn"),require("@babel/runtime/helpers/getPrototypeOf"),require("./localisation-56e0a999.js"),exports.initialiseSkin=function(t,n){Promise.resolve().then((function(){return require("./skin-fc1e7e52.js")})).then((function(e){var r=document.createElement("style");r.id="multiplayer_css",r.append("".concat(e.default)),document.head.appendChild(r)})),function(t,n){e.getPlayer(t).on("loadeddata",(function(){var e;(null===(e=i.getRenditions(t))||void 0===e?void 0:e.length)>0&&r.addSettingsButtonV2(t,n)}))}(t,n),function(i){var t=e.getPlayer(i);t.controls(!1),r.addDBClickFullScreen(i)}(t)};
@@ -1 +1 @@
1
- "use strict";var e,t=require("./features-f217e274.js"),n=require("./icons-0f7b3404.js"),r=require("./generic-846ad3ba.js"),s=require("@babel/runtime/helpers/defineProperty"),o=require("./keyboardShortcuts-f99b5202.js");function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function l(e,o){var l=r.getPlayer(e);l.one("play",(function(){null!=o&&o.streams&&t.addMulticamView(e,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?i(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},o)),null!=o&&o.airplay&&"Safari"==r.detectBrowser()&&l.addChild("airPlayButton"),null!=o&&o.chromecastReceiverId&&l.addChild("chromecastButton"),l.addChild("FullscreenToggle"),l.getChild("FullscreenToggle").el().appendChild(r.createIconMarkup(n.MinimizeSvg(window.controlsColor))),l.getChild("FullscreenToggle").el().appendChild(r.createIconMarkup(n.MaximizeSvg(window.controlsColor))),a(e)})),l.on("loadedmetadata",(function(){window.endFirstFrame(l),"Safari"!==r.detectBrowser()&&t.addResolutionModule(e,"live",n.SettingsSvg())})),l.one("loadedmetadata",(function(){var n;null!=o&&o.streams&&(null==o||null===(n=o.streams)||void 0===n?void 0:n.length)>=2&&t.addMwebPotraitTrayModule(e,o)}))}function a(t){var n=r.getPlayer(t);c(),n.on("pause",(function(){clearTimeout(e),u()})),n.on("play",(function(){c()}));var s=document.getElementById("".concat(t));s.addEventListener("mouseenter",(function(){u(),n.paused()||c()})),s.addEventListener("touchstart",(function(){u(),c()})),s.addEventListener("mousemove",(function(){u(),n.paused()||c()}))}function u(){var e=document.getElementsByClassName("vjs-chromecast-button")[0],t=document.getElementsByClassName("vjs-airplay-button")[0],n=document.getElementsByClassName("vjs-fullscreen-control")[0];null!=e&&e.classList.contains("hideoutsidecontrols")&&(null==e||e.classList.remove("hideoutsidecontrols")),n.classList.contains("hideoutsidecontrols")&&n.classList.remove("hideoutsidecontrols"),null!=t&&t.classList.contains("hideoutsidecontrols")&&t.classList.remove("hideoutsidecontrols")}function c(){var t=document.getElementsByClassName("vjs-chromecast-button")[0],n=document.getElementsByClassName("vjs-fullscreen-control")[0],r=document.getElementsByClassName("vjs-airplay-button")[0];clearTimeout(e),e=setTimeout((function(){null==t||t.classList.add("hideoutsidecontrols"),null==n||n.classList.add("hideoutsidecontrols"),null==r||r.classList.add("hideoutsidecontrols")}),2200)}require("@babel/runtime/helpers/classCallCheck"),require("@babel/runtime/helpers/createClass"),require("@babel/runtime/helpers/inherits"),require("@babel/runtime/helpers/possibleConstructorReturn"),require("@babel/runtime/helpers/getPrototypeOf"),require("video.js"),require("./renditions-5033b068.js"),require("axios"),require("js-cookie"),require("ua-parser-js"),require("@babel/runtime/helpers/toConsumableArray"),exports.hideControls=a,exports.initialiseSkin=function(e,s){var i;o.initialiseKeyboardEvents(e,s),(null==(i=s)||!i.liveui)&&(null==i||!i.liveVideo)||null!=i&&i.liveui&&null!=i&&i.liveVideo?Promise.resolve().then((function(){return require("./dvr_skin-f7f770ae.js")})).then((function(e){var t=document.createElement("style");t.id="dvr_skin",t.append("".concat(e.default)),document.head.appendChild(t)})):Promise.resolve().then((function(){return require("./nondvr_skin-ef2cb3b2.js")})).then((function(e){var t=document.createElement("style");t.id="nondvr_skin",t.append("".concat(e.default)),document.head.appendChild(t)})),function(e,n){t.addSlowMotion(e)}(e),function(e,t){var s=r.getPlayer(e),o=s.controlBar.getChild("SubsCapsButton").el();document.getElementsByClassName("vjs-subs-caps-button")[1].appendChild(r.createIconMarkup(n.NewCaptionsSvg()));var i=document.createElement("div");i.classList.add("caption-header"),o.querySelector(".vjs-menu-content").insertBefore(i,o.querySelector(".vjs-menu-item"));var l=document.createElement("div");if(l.innerText="Captions",l.className="fs14",document.getElementsByClassName("vjs-subs-caps-button")[0].appendChild(l),"Safari"==r.detectBrowser()){document.getElementsByClassName("vjs-subs-caps-button")[0].style.left="9.5rem"}null!=t&&t.liveui||null==t||!t.liveVideo||(document.getElementsByClassName("vjs-progress-control")[0].style.display="none")}(e,s),l(e,s)};
1
+ "use strict";var e,t=require("./features-ad62299c.js"),n=require("./icons-0f7b3404.js"),r=require("./generic-0f02a1e1.js"),s=require("@babel/runtime/helpers/defineProperty"),o=require("./keyboardShortcuts-8506bc80.js");function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function l(e,o){var l=r.getPlayer(e);l.one("play",(function(){null!=o&&o.streams&&t.addMulticamView(e,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?i(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},o)),null!=o&&o.airplay&&"Safari"==r.detectBrowser()&&l.addChild("airPlayButton"),null!=o&&o.chromecastReceiverId&&l.addChild("chromecastButton"),l.addChild("FullscreenToggle"),l.getChild("FullscreenToggle").el().appendChild(r.createIconMarkup(n.MinimizeSvg(window.controlsColor))),l.getChild("FullscreenToggle").el().appendChild(r.createIconMarkup(n.MaximizeSvg(window.controlsColor))),a(e)})),l.on("loadedmetadata",(function(){window.endFirstFrame(l),"Safari"!==r.detectBrowser()&&t.addResolutionModule(e,"live",n.SettingsSvg())})),l.one("loadedmetadata",(function(){var n;null!=o&&o.streams&&(null==o||null===(n=o.streams)||void 0===n?void 0:n.length)>=2&&t.addMwebPotraitTrayModule(e,o)}))}function a(t){var n=r.getPlayer(t);c(),n.on("pause",(function(){clearTimeout(e),u()})),n.on("play",(function(){c()}));var s=document.getElementById("".concat(t));s.addEventListener("mouseenter",(function(){u(),n.paused()||c()})),s.addEventListener("touchstart",(function(){u(),c()})),s.addEventListener("mousemove",(function(){u(),n.paused()||c()}))}function u(){var e=document.getElementsByClassName("vjs-chromecast-button")[0],t=document.getElementsByClassName("vjs-airplay-button")[0],n=document.getElementsByClassName("vjs-fullscreen-control")[0];null!=e&&e.classList.contains("hideoutsidecontrols")&&(null==e||e.classList.remove("hideoutsidecontrols")),n.classList.contains("hideoutsidecontrols")&&n.classList.remove("hideoutsidecontrols"),null!=t&&t.classList.contains("hideoutsidecontrols")&&t.classList.remove("hideoutsidecontrols")}function c(){var t=document.getElementsByClassName("vjs-chromecast-button")[0],n=document.getElementsByClassName("vjs-fullscreen-control")[0],r=document.getElementsByClassName("vjs-airplay-button")[0];clearTimeout(e),e=setTimeout((function(){null==t||t.classList.add("hideoutsidecontrols"),null==n||n.classList.add("hideoutsidecontrols"),null==r||r.classList.add("hideoutsidecontrols")}),2200)}require("@babel/runtime/helpers/classCallCheck"),require("@babel/runtime/helpers/createClass"),require("@babel/runtime/helpers/inherits"),require("@babel/runtime/helpers/possibleConstructorReturn"),require("@babel/runtime/helpers/getPrototypeOf"),require("video.js"),require("./renditions-07d76d50.js"),require("./localisation-56e0a999.js"),require("axios"),require("js-cookie"),require("ua-parser-js"),require("@babel/runtime/helpers/toConsumableArray"),exports.hideControls=a,exports.initialiseSkin=function(e,s){var i;o.initialiseKeyboardEvents(e,s),(null==(i=s)||!i.liveui)&&(null==i||!i.liveVideo)||null!=i&&i.liveui&&null!=i&&i.liveVideo?Promise.resolve().then((function(){return require("./dvr_skin-f7f770ae.js")})).then((function(e){var t=document.createElement("style");t.id="dvr_skin",t.append("".concat(e.default)),document.head.appendChild(t)})):Promise.resolve().then((function(){return require("./nondvr_skin-ef2cb3b2.js")})).then((function(e){var t=document.createElement("style");t.id="nondvr_skin",t.append("".concat(e.default)),document.head.appendChild(t)})),function(e){t.addSlowMotion(e)}(e),function(e,t){var s=r.getPlayer(e),o=s.controlBar.getChild("SubsCapsButton").el();document.getElementsByClassName("vjs-subs-caps-button")[1].appendChild(r.createIconMarkup(n.NewCaptionsSvg()));var i=document.createElement("div");i.classList.add("caption-header"),o.querySelector(".vjs-menu-content").insertBefore(i,o.querySelector(".vjs-menu-item"));var l=document.createElement("div");if(l.innerText="Captions",l.className="fs14",document.getElementsByClassName("vjs-subs-caps-button")[0].appendChild(l),"Safari"==r.detectBrowser()){document.getElementsByClassName("vjs-subs-caps-button")[0].style.left="9.5rem"}null!=t&&t.liveui||null==t||!t.liveVideo||(document.getElementsByClassName("vjs-progress-control")[0].style.display="none")}(e,s),l(e,s)};
@@ -0,0 +1 @@
1
+ "use strict";var e=require("./features-ad62299c.js"),r=require("./keyboardShortcuts-8506bc80.js"),t=require("./icons-0f7b3404.js"),i=require("./generic-0f02a1e1.js");require("@babel/runtime/helpers/defineProperty"),require("@babel/runtime/helpers/classCallCheck"),require("@babel/runtime/helpers/createClass"),require("@babel/runtime/helpers/inherits"),require("@babel/runtime/helpers/possibleConstructorReturn"),require("@babel/runtime/helpers/getPrototypeOf"),require("video.js"),require("./renditions-07d76d50.js"),require("./localisation-56e0a999.js"),require("axios"),require("js-cookie"),require("ua-parser-js"),require("@babel/runtime/helpers/toConsumableArray"),exports.initialiseSkin=function(n,s){r.initialiseKeyboardEvents(n,s),Promise.resolve().then((function(){return require("./skin-983a2ea7.js")})).then((function(e){var r=document.createElement("style");r.id="def_skin",r.append("".concat(e.default)),document.head.appendChild(r)})),function(r,i){0==i.liveVideo&&0==i.liveui&&e.addSkipButton(r,"default",t.SkipSvg());(0==i.liveVideo&&0==i.liveui||1==i.liveui)&&e.addRewindButton(r,"default",t.RewindSvg())}(n,s),function(r,n){var s=i.getPlayer(r),o=(null==n?void 0:n.sres)||null;s.on("loadeddata",(function(){e.addResolutionModule(r,"default",t.SettingsSvg()),o&&Promise.resolve().then((function(){return require("./nextEpisodeButton-e7f64f81.js")})).then((function(e){e.initaliseFunctionality(n.sres.seasons,i.getCurrentVideo())}))})),s.one("loadedmetadata",(function(){var t;o&&(e.addSeriesModule(r,null==n||null===(t=n.sres)||void 0===t?void 0:t.seasons,n),e.addNextEpisodeButton(n.sres,n.res,r))}))}(n,s),function(e,r){var n=i.getPlayer(e),s=document.getElementsByClassName("vjs-current-time")[0],o=document.getElementsByClassName("vjs-duration")[0],l=document.getElementsByClassName("vjs-time-divider")[0];r.liveVideo&&(s&&(s.style.display="none"),o&&(o.style.display="none"),l&&(l.style.display="none"));n.controlBar.getChild("FullscreenToggle").el().appendChild(i.createIconMarkup(t.MinimizeSvg(window.controlsColor))),n.controlBar.getChild("FullscreenToggle").el().appendChild(i.createIconMarkup(t.MaximizeSvg(window.controlsColor)));var a=n.controlBar.getChild("SubsCapsButton").el();document.getElementById(e).getElementsByClassName("vjs-subs-caps-button")[1].appendChild(i.createIconMarkup(t.NewCaptionsSvg()));var u=document.createElement("div");u.classList.add("caption-header"),a.querySelector(".vjs-menu-content").insertBefore(u,a.querySelector(".vjs-menu-item"))}(n,s)};
@@ -0,0 +1 @@
1
+ "use strict";var e=require("./features-ad62299c.js"),t=require("./icons-0f7b3404.js"),l=require("./generic-0f02a1e1.js"),i=require("./renditions-07d76d50.js"),n=require("@babel/runtime/helpers/toConsumableArray"),o=require("./autoNextVideo-86ec33b5.js");require("@babel/runtime/helpers/defineProperty"),require("@babel/runtime/helpers/classCallCheck"),require("@babel/runtime/helpers/createClass"),require("@babel/runtime/helpers/inherits"),require("@babel/runtime/helpers/possibleConstructorReturn"),require("@babel/runtime/helpers/getPrototypeOf"),require("video.js"),require("./localisation-56e0a999.js"),require("axios"),require("js-cookie"),require("ua-parser-js"),require("./util-05c0ddf6.js");var r=l.getCurrentSeries(),a=[];null==r||r.map((function(e){return a.push.apply(a,n(e.episodes))}));var d=function(e,t){var i;null==t||null===(i=t.series)||void 0===i||i.cb;var n=l.getPlayer(e);n.on("timeupdate",(function(){var e,t=Math.floor(n.currentTime()),i=n.duration(),o=null===(e=document.getElementsByClassName("next-ep-preview"))||void 0===e?void 0:e[0];i-t<=10&&l.getVideoIdx()<=(null==a?void 0:a.length)-1?o&&(o.style.visibility="visible"):o&&(o.style.visibility="hidden")}));var o,r=a.filter((function(e,t){return t==l.getVideoIdx()}));if((null==r?void 0:r.length)>0)if(null!==(o=document.getElementsByClassName("next-ep-preview"))&&void 0!==o&&o[0]){var d,s,v,c,m,p,g,h,f,y,C;(null===(d=document.getElementsByClassName("next-ep-preview"))||void 0===d?void 0:d[0]).style.visibility="hidden";var b=null===(s=document.getElementsByClassName("next-ep-title"))||void 0===s?void 0:s[0],x=null===(v=document.getElementsByClassName("next-ep-img"))||void 0===v?void 0:v[0],j=null===(c=document.getElementsByClassName("next-ep-content"))||void 0===c?void 0:c[0],w=null===(m=r[0])||void 0===m?void 0:m.title;(null===(p=w)||void 0===p?void 0:p.length)>60&&(w=w.substr(0,60)+"..."),b.textContent="".concat(w),x.src=(null===(g=r[0])||void 0===g||null===(h=g.gist)||void 0===h||null===(f=h.imageGist)||void 0===f?void 0:f.r16x9)||(null===(y=window)||void 0===y||null===(C=y.customData)||void 0===C?void 0:C.fallbackImage),j.onclick=function(){return u(e)}}else{var q,E,N,B,V,S,k,P=document.createElement("div");P.className="next-ep-preview",P.style.visibility="hidden",document.getElementById(e).append(P);var I=document.createElement("div");I.className="next-ep-header",I.textContent="Next up";var M=null===(q=r[0])||void 0===q?void 0:q.title,R=document.createElement("img");R.className="next-ep-img",R.src=(null===(E=r[0])||void 0===E||null===(N=E.gist)||void 0===N||null===(B=N.imageGist)||void 0===B?void 0:B.r16x9)||(null===(V=window)||void 0===V||null===(S=V.customData)||void 0===S?void 0:S.fallbackImage);var O=document.createElement("div");O.className="next-ep-title",(null===(k=M)||void 0===k?void 0:k.length)>60&&(M=M.substr(0,60)+"..."),O.textContent="".concat(M);var T=document.createElement("div");T.className="next-ep-content",T.append(R),T.append(O),T.onclick=function(){return u(e)},P.append(I),P.append(T)}},u=function(e,t){var i=l.getPlayer(e),n=Math.floor(i.currentTime());if(Math.floor(i.duration())!=n){i.pause(e);var r=l.getVideoIdx();o.switchToNext(r,e,a,sessionStorage.getItem("token"))}};function s(t,n){var o=l.getPlayer(t);o.on("loadeddata",(function(){var r,a,u;(null===(r=i.getRenditions(t))||void 0===r?void 0:r.length)>0&&e.addSettingsButtonV2(t,n),(null===(a=l.getCaptions(t))||void 0===a?void 0:a.length)>0&&e.addCaptionButton(t,n),null!=n&&null!==(u=n.series)&&void 0!==u&&u.enable&&d(t,n),function(e,t){var l,i=Math.floor(e/60),n=null===(l=document.getElementsByClassName("vjs-progress-holder vjs-slider vjs-slider-horizontal"))||void 0===l?void 0:l[0];n&&(n.style.marginRight=i>60?"56px":"41px");var o=document.getElementsByClassName("vjs-live-control")[0],r=document.getElementsByClassName("vjs-time-control");t&&o.classList.value.includes("vjs-hidden")&&(r[0].style.display="block",n&&(n.style.marginRight="56px"))}(o.duration(),(null==n?void 0:n.liveVideo)||!1)})),o.one("play",(function(){var l,i,n,o;null!==(l=window)&&void 0!==l&&null!==(i=l.customData)&&void 0!==i&&i.iframeOverlayUrl&&e.addOutputtingOverlay(t,null===(n=window)||void 0===n||null===(o=n.customData)||void 0===o?void 0:o.iframeOverlayUrl)}))}exports.initialiseSkin=function(i,n){!function(){"Chrome"==l.detectBrowser()&&Promise.resolve().then((function(){return require("./chromett-f925fb6c.js")})).then((function(e){var t=document.createElement("style");t.id="chromett",t.append("".concat(e.default)),document.head.appendChild(t)}));Promise.resolve().then((function(){return require("./skin-921d35a8.js")})).then((function(e){var t=document.createElement("style");t.id="default_v2",t.append("".concat(e.default)),document.head.appendChild(t)}))}(),s(i,n),function(e,i){var n=l.getPlayer(e);n.controlBar.getChild("FullscreenToggle").el().appendChild(l.createIconMarkup(t.MinimizeSvg(window.controlsColor))),n.controlBar.getChild("FullscreenToggle").el().appendChild(l.createIconMarkup(t.MaximizeSvg(window.controlsColor)));var o=document.getElementsByClassName("vjs-time-control");i.liveVideo&&(o[0].style.display="none")}(i,n),function(l,i){var n,o,r,a,d,u;0==(null==i?void 0:i.liveVideo)&&0==(null==i?void 0:i.liveui)&&e.addSkipButton(l,"defaultV2",t.SkipSvgV2());(0==(null==i?void 0:i.liveVideo)&&0==(null==i?void 0:i.liveui)||1==(null==i?void 0:i.liveui))&&e.addRewindButton(l,"defaultV2",t.RewindSvgV2());i.liveVideo||e.addSlowMotion(l);(null==i||null===(n=i.relatedVideos)||void 0===n||null===(o=n.content)||void 0===o?void 0:o.length)>0&&e.addVideoSelector(l,null==i?void 0:i.relatedVideos);(null==i||null===(r=i.streams)||void 0===r?void 0:r.length)>1&&e.addMulticamSelector(l,null==i?void 0:i.streams);(null==i||null===(a=i.playlist)||void 0===a||null===(d=a.content)||void 0===d?void 0:d.length)>0&&e.addPlaylistSelector(l,null==i?void 0:i.playlist);null!=i&&null!==(u=i.series)&&void 0!==u&&u.enable&&e.addSeriesSelectorV2(l,i)}(i,n),function(e,t){var i=l.getPlayer(e),n=null==t?void 0:t.tvProviderLogoUrl;if(!n)return;var o=document.createElement("div");o.className="tvProviderImage";var r=document.createElement("img");r.src="".concat(n),r.alt="Provider Image",o.append(r),i.el().appendChild(o),i.on("useractive",(function(){o.classList.remove("vjs-fade")})),i.on("userinactive",(function(){i.paused()||o.classList.add("vjs-fade")})),i.on("fullscreenchange",(function(){i.isFullscreen_?o.style.top="3.2rem":o.style.top="1rem"}))}(i,n)};