cds.connatix.com Open in urlscan Pro
104.18.33.52  Public Scan

Submitted URL: https://cd.connatix.com/connatix.player.js
Effective URL: https://cds.connatix.com/p/269000/connatix.player.dc.js?tier=1
Submission: On May 15 via manual from US — Scanned from DE

Form analysis 0 forms found in the DOM

Text Content

(()=>{var t={4537:t=>{"use strict";t.exports=function(t,i){var e=new Array(arguments.length-1),s=0,n=2,r=!0;for(;n<arguments.length;)e[s++]=arguments[n++];return new Promise((function(n,o){e[s]=function(t){if(r)if(r=!1,t)o(t);else{for(var i=new Array(arguments.length-1),e=0;e<i.length;)i[e++]=arguments[e];n.apply(null,i)}};try{t.apply(i||null,e)}catch(t){r&&(r=!1,o(t))}}))}},7419:(t,i)=>{"use strict";var e=i;e.length=function(t){var i=t.length;if(!i)return 0;for(var e=0;--i%4>1&&"="===t.charAt(i);)++e;return Math.ceil(3*t.length)/4-e};for(var s=new Array(64),n=new Array(123),r=0;r<64;)n[s[r]=r<26?r+65:r<52?r+71:r<62?r-4:r-59|43]=r++;e.encode=function(t,i,e){for(var n,r=null,o=[],h=0,a=0;i<e;){var c=t[i++];switch(a){case 0:o[h++]=s[c>>2],n=(3&c)<<4,a=1;break;case 1:o[h++]=s[n|c>>4],n=(15&c)<<2,a=2;break;case 2:o[h++]=s[n|c>>6],o[h++]=s[63&c],a=0}h>8191&&((r||(r=[])).push(String.fromCharCode.apply(String,o)),h=0)}return a&&(o[h++]=s[n],o[h++]=61,1===a&&(o[h++]=61)),r?(h&&r.push(String.fromCharCode.apply(String,o.slice(0,h))),r.join("")):String.fromCharCode.apply(String,o.slice(0,h))};var o="invalid encoding";e.decode=function(t,i,e){for(var s,r=e,h=0,a=0;a<t.length;){var c=t.charCodeAt(a++);if(61===c&&h>1)break;if(void 0===(c=n[c]))throw Error(o);switch(h){case 0:s=c,h=1;break;case 1:i[e++]=s<<2|(48&c)>>4,s=c,h=2;break;case 2:i[e++]=(15&s)<<4|(60&c)>>2,s=c,h=3;break;case 3:i[e++]=(3&s)<<6|c,h=0}}if(1===h)throw Error(o);return e-r},e.test=function(t){return/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/.test(t)}},5124:t=>{"use strict";function i(t,e){"string"==typeof t&&(e=t,t=void 0);var s=[];function n(t){if("string"!=typeof t){var e=r();if(i.verbose&&console.log("codegen: "+e),e="return "+e,t){for(var o=Object.keys(t),h=new Array(o.length+1),a=new Array(o.length),c=0;c<o.length;)h[c]=o[c],a[c]=t[o[c++]];return h[c]=e,Function.apply(null,h).apply(null,a)}return Function(e)()}for(var d=new Array(arguments.length-1),l=0;l<d.length;)d[l]=arguments[++l];if(l=0,t=t.replace(/%([%dfijs])/g,(function(t,i){var e=d[l++];switch(i){case"d":case"f":return String(Number(e));case"i":return String(Math.floor(e));case"j":return JSON.stringify(e);case"s":return String(e)}return"%"})),l!==d.length)throw Error("parameter count mismatch");return s.push(t),n}function r(i){return"function "+(i||e||"")+"("+(t&&t.join(",")||"")+"){\n  "+s.join("\n  ")+"\n}"}return n.toString=r,n}t.exports=i,i.verbose=!1},9211:t=>{"use strict";function i(){this.I={}}t.exports=i,i.prototype.on=function(t,i,e){return(this.I[t]||(this.I[t]=[])).push({fn:i,ctx:e||this}),this},i.prototype.off=function(t,i){if(void 0===t)this.I={};else if(void 0===i)this.I[t]=[];else for(var e=this.I[t],s=0;s<e.length;)e[s].fn===i?e.splice(s,1):++s;return this},i.prototype.emit=function(t){var i=this.I[t];if(i){for(var e=[],s=1;s<arguments.length;)e.push(arguments[s++]);for(s=0;s<i.length;)i[s].fn.apply(i[s++].ctx,e)}return this}},9054:(t,i,e)=>{"use strict";t.exports=r;var s=e(4537),n=e(7199)("fs");function r(t,i,e){return"function"==typeof i?(e=i,i={}):i||(i={}),e?!i.xhr&&n&&n.readFile?n.readFile(t,(function(s,n){return s&&"undefined"!=typeof XMLHttpRequest?r.xhr(t,i,e):s?e(s):e(null,i.binary?n:n.toString("utf8"))})):r.xhr(t,i,e):s(r,this,t,i)}r.xhr=function(t,i,e){var s=new XMLHttpRequest;s.onreadystatechange=function(){if(4===s.readyState){if(0!==s.status&&200!==s.status)return e(Error("status "+s.status));if(i.binary){var t=s.response;if(!t){t=[];for(var n=0;n<s.responseText.length;++n)t.push(255&s.responseText.charCodeAt(n))}return e(null,"undefined"!=typeof Uint8Array?new Uint8Array(t):t)}return e(null,s.responseText)}},i.binary&&("overrideMimeType"in s&&s.overrideMimeType("text/plain; charset=x-user-defined"),s.responseType="arraybuffer"),s.open("GET",t),s.send()}},945:t=>{"use strict";function i(t){return"undefined"!=typeof Float32Array?function(){var i=new Float32Array([-0]),e=new Uint8Array(i.buffer),s=128===e[3];function n(t,s,n){i[0]=t,s[n]=e[0],s[n+1]=e[1],s[n+2]=e[2],s[n+3]=e[3]}function r(t,s,n){i[0]=t,s[n]=e[3],s[n+1]=e[2],s[n+2]=e[1],s[n+3]=e[0]}function o(t,s){return e[0]=t[s],e[1]=t[s+1],e[2]=t[s+2],e[3]=t[s+3],i[0]}function h(t,s){return e[3]=t[s],e[2]=t[s+1],e[1]=t[s+2],e[0]=t[s+3],i[0]}t.writeFloatLE=s?n:r,t.writeFloatBE=s?r:n,t.readFloatLE=s?o:h,t.readFloatBE=s?h:o}():function(){function i(t,i,e,s){var n=i<0?1:0;if(n&&(i=-i),0===i)t(1/i>0?0:2147483648,e,s);else if(isNaN(i))t(2143289344,e,s);else if(i>34028234663852886e22)t((n<<31|2139095040)>>>0,e,s);else if(i<11754943508222875e-54)t((n<<31|Math.round(i/1401298464324817e-60))>>>0,e,s);else{var r=Math.floor(Math.log(i)/Math.LN2);t((n<<31|r+127<<23|8388607&Math.round(i*Math.pow(2,-r)*8388608))>>>0,e,s)}}function o(t,i,e){var s=t(i,e),n=2*(s>>31)+1,r=s>>>23&255,o=8388607&s;return 255===r?o?NaN:n*(1/0):0===r?1401298464324817e-60*n*o:n*Math.pow(2,r-150)*(o+8388608)}t.writeFloatLE=i.bind(null,e),t.writeFloatBE=i.bind(null,s),t.readFloatLE=o.bind(null,n),t.readFloatBE=o.bind(null,r)}(),"undefined"!=typeof Float64Array?function(){var i=new Float64Array([-0]),e=new Uint8Array(i.buffer),s=128===e[7];function n(t,s,n){i[0]=t,s[n]=e[0],s[n+1]=e[1],s[n+2]=e[2],s[n+3]=e[3],s[n+4]=e[4],s[n+5]=e[5],s[n+6]=e[6],s[n+7]=e[7]}function r(t,s,n){i[0]=t,s[n]=e[7],s[n+1]=e[6],s[n+2]=e[5],s[n+3]=e[4],s[n+4]=e[3],s[n+5]=e[2],s[n+6]=e[1],s[n+7]=e[0]}function o(t,s){return e[0]=t[s],e[1]=t[s+1],e[2]=t[s+2],e[3]=t[s+3],e[4]=t[s+4],e[5]=t[s+5],e[6]=t[s+6],e[7]=t[s+7],i[0]}function h(t,s){return e[7]=t[s],e[6]=t[s+1],e[5]=t[s+2],e[4]=t[s+3],e[3]=t[s+4],e[2]=t[s+5],e[1]=t[s+6],e[0]=t[s+7],i[0]}t.writeDoubleLE=s?n:r,t.writeDoubleBE=s?r:n,t.readDoubleLE=s?o:h,t.readDoubleBE=s?h:o}():function(){function i(t,i,e,s,n,r){var o=s<0?1:0;if(o&&(s=-s),0===s)t(0,n,r+i),t(1/s>0?0:2147483648,n,r+e);else if(isNaN(s))t(0,n,r+i),t(2146959360,n,r+e);else if(s>17976931348623157e292)t(0,n,r+i),t((o<<31|2146435072)>>>0,n,r+e);else{var h;if(s<22250738585072014e-324)t((h=s/5e-324)>>>0,n,r+i),t((o<<31|h/4294967296)>>>0,n,r+e);else{var a=Math.floor(Math.log(s)/Math.LN2);1024===a&&(a=1023),t(4503599627370496*(h=s*Math.pow(2,-a))>>>0,n,r+i),t((o<<31|a+1023<<20|1048576*h&1048575)>>>0,n,r+e)}}}function o(t,i,e,s,n){var r=t(s,n+i),o=t(s,n+e),h=2*(o>>31)+1,a=o>>>20&2047,c=4294967296*(1048575&o)+r;return 2047===a?c?NaN:h*(1/0):0===a?5e-324*h*c:h*Math.pow(2,a-1075)*(c+4503599627370496)}t.writeDoubleLE=i.bind(null,e,0,4),t.writeDoubleBE=i.bind(null,s,4,0),t.readDoubleLE=o.bind(null,n,0,4),t.readDoubleBE=o.bind(null,r,4,0)}(),t}function e(t,i,e){i[e]=255&t,i[e+1]=t>>>8&255,i[e+2]=t>>>16&255,i[e+3]=t>>>24}function s(t,i,e){i[e]=t>>>24,i[e+1]=t>>>16&255,i[e+2]=t>>>8&255,i[e+3]=255&t}function n(t,i){return(t[i]|t[i+1]<<8|t[i+2]<<16|t[i+3]<<24)>>>0}function r(t,i){return(t[i]<<24|t[i+1]<<16|t[i+2]<<8|t[i+3])>>>0}t.exports=i(i)},7199:t=>{"use strict";function i(t){try{var i=eval("quire".replace(/^/,"re"))(t);if(i&&(i.length||Object.keys(i).length))return i}catch(t){}return null}t.exports=i},8626:(t,i)=>{"use strict";var e=i,s=e.isAbsolute=function(t){return/^(?:\/|\w+:)/.test(t)},n=e.normalize=function(t){var i=(t=t.replace(/\\/g,"/").replace(/\/{2,}/g,"/")).split("/"),e=s(t),n="";e&&(n=i.shift()+"/");for(var r=0;r<i.length;)".."===i[r]?r>0&&".."!==i[r-1]?i.splice(--r,2):e?i.splice(r,1):++r:"."===i[r]?i.splice(r,1):++r;return n+i.join("/")};e.resolve=function(t,i,e){return e||(i=n(i)),s(i)?i:(e||(t=n(t)),(t=t.replace(/(?:\/|^)[^/]+$/,"")).length?n(t+"/"+i):i)}},6662:t=>{"use strict";t.exports=function(t,i,e){var s=e||8192,n=s>>>1,r=null,o=s;return function(e){if(e<1||e>n)return t(e);o+e>s&&(r=t(s),o=0);var h=i.call(r,o,o+=e);return 7&o&&(o=1+(7|o)),h}}},4997:(t,i)=>{"use strict";var e=i;e.length=function(t){for(var i=0,e=0,s=0;s<t.length;++s)(e=t.charCodeAt(s))<128?i+=1:e<2048?i+=2:55296==(64512&e)&&56320==(64512&t.charCodeAt(s+1))?(++s,i+=4):i+=3;return i},e.read=function(t,i,e){if(e-i<1)return"";for(var s,n=null,r=[],o=0;i<e;)(s=t[i++])<128?r[o++]=s:s>191&&s<224?r[o++]=(31&s)<<6|63&t[i++]:s>239&&s<365?(s=((7&s)<<18|(63&t[i++])<<12|(63&t[i++])<<6|63&t[i++])-65536,r[o++]=55296+(s>>10),r[o++]=56320+(1023&s)):r[o++]=(15&s)<<12|(63&t[i++])<<6|63&t[i++],o>8191&&((n||(n=[])).push(String.fromCharCode.apply(String,r)),o=0);return n?(o&&n.push(String.fromCharCode.apply(String,r.slice(0,o))),n.join("")):String.fromCharCode.apply(String,r.slice(0,o))},e.write=function(t,i,e){for(var s,n,r=e,o=0;o<t.length;++o)(s=t.charCodeAt(o))<128?i[e++]=s:s<2048?(i[e++]=s>>6|192,i[e++]=63&s|128):55296==(64512&s)&&56320==(64512&(n=t.charCodeAt(o+1)))?(s=65536+((1023&s)<<10)+(1023&n),++o,i[e++]=s>>18|240,i[e++]=s>>12&63|128,i[e++]=s>>6&63|128,i[e++]=63&s|128):(i[e++]=s>>12|224,i[e++]=s>>6&63|128,i[e++]=63&s|128);return e-r}},7501:function(t,i,e){var s;t=e.nmd(t),function(n){var r=i,o=(t&&t.exports,"object"==typeof e.g&&e.g);o.global!==o&&o.window;var h=function(t){this.message=t};(h.prototype=new Error).name="InvalidCharacterError";var a=function(t){throw new h(t)},c="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",d=/[\t\n\f\r ]/g,l={encode:function(t){t=String(t),/[^\0-\xFF]/.test(t)&&a("The string to be encoded contains characters outside of the Latin1 range.");for(var i,e,s,n,r=t.length%3,o="",h=-1,d=t.length-r;++h<d;)i=t.charCodeAt(h)<<16,e=t.charCodeAt(++h)<<8,s=t.charCodeAt(++h),o+=c.charAt((n=i+e+s)>>18&63)+c.charAt(n>>12&63)+c.charAt(n>>6&63)+c.charAt(63&n);return 2==r?(i=t.charCodeAt(h)<<8,e=t.charCodeAt(++h),o+=c.charAt((n=i+e)>>10)+c.charAt(n>>4&63)+c.charAt(n<<2&63)+"="):1==r&&(n=t.charCodeAt(h),o+=c.charAt(n>>2)+c.charAt(n<<4&63)+"=="),o},decode:function(t){var i=(t=String(t).replace(d,"")).length;i%4==0&&(i=(t=t.replace(/==?$/,"")).length),(i%4==1||/[^+a-zA-Z0-9/]/.test(t))&&a("Invalid character: the string to be decoded is not correctly encoded.");for(var e,s,n=0,r="",o=-1;++o<i;)s=c.indexOf(t.charAt(o)),e=n%4?64*e+s:s,n++%4&&(r+=String.fromCharCode(255&e>>(-2*n&6)));return r},version:"0.1.0"};void 0===(s=function(){return l}.call(i,e,i,t))||(t.exports=s)}()},6658:(t,i,e)=>{"use strict";var s=e(3090),n=s.decodeBitsToIds,r=s.decodeFromBase64;t.exports={decodeConsentString:function(t){var i=r(t),e=i.version,s=i.cmpId,o=i.vendorListVersion,h=i.purposeIdBitString,a=i.maxVendorId,c=i.created,d=i.lastUpdated,l=i.isRange,u=i.defaultConsent,p=i.vendorIdBitString,f=i.vendorRangeList,m=i.cmpVersion,g=i.consentScreen,v=i.consentLanguage,y={version:e,cmpId:s,vendorListVersion:o,allowedPurposeIds:n(h),maxVendorId:a,created:c,lastUpdated:d,cmpVersion:m,consentScreen:g,consentLanguage:v};if(l){var b=f.reduce((function(t,i){for(var e=i.isRange,s=i.startVendorId,n=i.endVendorId,r=e?n:s,o=s;o<=r;o+=1)t[o]=!0;return t}),{});y.allowedVendorIds=[];for(var I=1;I<=a;I+=1)(u&&!b[I]||!u&&b[I])&&-1===y.allowedVendorIds.indexOf(I)&&y.allowedVendorIds.push(I)}else y.allowedVendorIds=n(p);return y}}},8462:(t,i,e)=>{"use strict";var s=e(6658).decodeConsentString;t.exports={decodeConsentString:s}},3090:(t,i,e)=>{"use strict";var s=e(7501),n=e(3977),r=n.versionNumBits,o=n.vendorVersionMap;function h(t,i,e){return parseInt(t.substr(i,e),2)}function a(t,i,e){return new Date(100*h(t,i,e))}function c(t){var i=h(t);return String.fromCharCode(i+65).toLowerCase()}function d(t,i,e){var s=t.substr(i,e);return c(s.slice(0,e/2))+c(s.slice(e/2))}function l(t){var i=t.input,e=t.output,s=t.startPosition,n=t.field,r=n.type,o=n.numBits,c=n.decoder,l=n.validator,p=n.listCount;if("function"==typeof l&&!l(e))return{newPosition:s};if("function"==typeof c)return c(i,e,s);var f,m,g="function"==typeof o?o(e):o;switch(r){case"int":return{fieldValue:h(i,s,g)};case"bool":return{fieldValue:(f=i,m=s,1===parseInt(f.substr(m,1),2))};case"date":return{fieldValue:a(i,s,g)};case"bits":return{fieldValue:i.substr(s,g)};case"list":return function(t,i,e,s,n){var r=0;"function"==typeof n?r=n(i):"number"==typeof n&&(r=n);for(var o=e,h=[],a=0;a<r;a+=1){var c=u({input:t,fields:s.fields,startPosition:o});o=c.newPosition,h.push(c.decodedObject)}return{fieldValue:h,newPosition:o}}(i,e,s,n,p);case"language":return{fieldValue:d(i,s,g)};default:throw new Error("ConsentString - Unknown field type "+r+" for decoding")}}function u(t){var i=t.input,e=t.fields,s=t.startPosition,n=void 0===s?0:s;return{decodedObject:e.reduce((function(t,e){var s=e.name,r=e.numBits,o=l({input:i,output:t,startPosition:n,field:e}),h=o.fieldValue,a=o.newPosition;return void 0!==h&&(t[s]=h),void 0!==a?n=a:"number"==typeof r&&(n+=r),t}),{}),newPosition:n}}t.exports={decodeBitsToIds:function(t){return t.split("").reduce((function(t,i,e){return"1"===i&&-1===t.indexOf(e+1)&&t.push(e+1),t}),[])},decodeFromBase64:function(t,i){for(var e=t;e.length%4!=0;)e+="=";e=e.replace(/-/g,"+").replace(/_/g,"/");for(var n,a,c=s.decode(e),d="",l=0;l<c.length;l+=1){var p=c.charCodeAt(l).toString(2);d+=(n=p,a=8-p.length,function(t){for(var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"0",e="",s=0;s<t;s+=1)e+=i;return e}(Math.max(0,a))+n)}return function(t){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:o,e=h(t,0,r);if("number"!=typeof e)throw new Error("ConsentString - Unknown version number in the string to decode");if(!o[e])throw new Error("ConsentString - Unsupported version "+e+" in the string to decode");return u({input:t,fields:i[e].fields}).decodedObject}(d,i)}}},3977:t=>{"use strict";t.exports={versionNumBits:6,vendorVersionMap:{1:{version:1,metadataFields:["version","created","lastUpdated","cmpId","cmpVersion","consentScreen","vendorListVersion"],fields:[{name:"version",type:"int",numBits:6},{name:"created",type:"date",numBits:36},{name:"lastUpdated",type:"date",numBits:36},{name:"cmpId",type:"int",numBits:12},{name:"cmpVersion",type:"int",numBits:12},{name:"consentScreen",type:"int",numBits:6},{name:"consentLanguage",type:"language",numBits:12},{name:"vendorListVersion",type:"int",numBits:12},{name:"purposeIdBitString",type:"bits",numBits:24},{name:"maxVendorId",type:"int",numBits:16},{name:"isRange",type:"bool",numBits:1},{name:"vendorIdBitString",type:"bits",numBits:function(t){return t.maxVendorId},validator:function(t){return!t.isRange}},{name:"defaultConsent",type:"bool",numBits:1,validator:function(t){return t.isRange}},{name:"numEntries",numBits:12,type:"int",validator:function(t){return t.isRange}},{name:"vendorRangeList",type:"list",listCount:function(t){return t.numEntries},validator:function(t){return t.isRange},fields:[{name:"isRange",type:"bool",numBits:1},{name:"startVendorId",type:"int",numBits:16},{name:"endVendorId",type:"int",numBits:16,validator:function(t){return t.isRange}}]}]}}}},8908:(t,i,e)=>{var s;s="undefined"!=typeof window?window:void 0!==e.g?e.g:"undefined"!=typeof self?self:{},t.exports=s},3225:(t,i,e)=>{"use strict";e.d(i,{Z:()=>s});const s='<cnx class="cnx-icon-button cnx-ui-btn-hoverable" role="button" tabindex="0"><cnx class="cnx-btn-container"><cnx class="cnx-expand-icon"><svg markup-inline class="cnx-color-icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M4.6 3H10v2H5v5H3V4.6A1.58 1.58 0 014.6 3zM5 14v5h5v2H4.6A1.58 1.58 0 013 19.4V14h2zM19.4 3A1.58 1.58 0 0121 4.6V10h-2V5h-5V3h5.4zM19 14h2v5.4a1.58 1.58 0 01-1.6 1.6H14v-2h5v-5z" fill-rule="evenodd"/></svg></cnx><cnx class="cnx-collapse-icon"><svg markup-inline class="cnx-color-icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill-rule="evenodd"><path d="M16.6 15a1.58 1.58 0 00-1.6 1.6V22h2v-5h5v-2h-5.4zM17 2h-2v5.4A1.58 1.58 0 0016.6 9H22V7h-5V2zM7.4 15A1.58 1.58 0 019 16.6V22H7v-5H2v-2h5.4zM7 2h2v5.4A1.58 1.58 0 017.4 9H2V7h5V2z"/></svg></cnx></cnx></cnx>'},852:(t,i,e)=>{"use strict";e.d(i,{Z:()=>s});const s='<cnx class="cnx-ui-loader" role="presentation"><svg class="cnx-color-accent" version="1.1" viewBox="0 0 79 90" xmlns="http://www.w3.org/2000/svg"><polygon points="21 73.322 11 79 11 12 21 17.678" fill="none" stroke-linecap="round" stroke-linejoin="round"/><polygon points="27 70 27 21 38 27.267 38 63.733" fill="transparent" stroke-linecap="round" stroke-linejoin="round"/><polygon points="44 61 44 31 54 36.769 54 55.231" fill="none" stroke-linecap="round" stroke-linejoin="round"/><polygon points="60 51 60 40 70 45.5" fill="none" stroke-linecap="round" stroke-linejoin="round"/></svg></cnx>'},9735:(t,i,e)=>{"use strict";e.d(i,{Z:()=>s});const s='<cnx class="cnx-progress-bar cnx-video-progress"><cnx class="cnx-progress-rail-container"><cnx class="cnx-progress-rail"></cnx><cnx class="cnx-progress-fill cnx-color-accent"></cnx><cnx class="cnx-progress-follow"></cnx></cnx><cnx class="cnx-progress-handle cnx-color-accent"></cnx><cnx class="cnx-progress-hitarea"></cnx><cnx class="cnx-progress-input"><input type="range" step="5" role="slider" class="cnx-progress-range"></cnx></cnx>'},9268:(t,i,e)=>{"use strict";e.d(i,{Z:()=>s});const s='<cnx class="cnx-ui-progress-label"><cnx-span role="timer"></cnx-span></cnx>'},3093:(t,i,e)=>{"use strict";e.d(i,{Z:()=>s});const s='<cnx class="cnx-tooltip-holder cnx-color-tt-bg"><cnx class="cnx-tooltip-text cnx-color-tt-text">TEST</cnx></cnx>'},2390:(t,i,e)=>{"use strict";e.d(i,{Z:()=>s});const s='<cnx class="cnx-icon-button cnx-ui-btn-hoverable" role="button" tabindex="0"><cnx class="cnx-btn-container"><cnx class="cnx-unmute-icon"><svg markup-inline class="cnx-color-icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M0 7.913v7.913h4.946l5.935 5.045V1.978L4.946 7.913zm16.815 3.957a5.476 5.476 0 00-2.967-4.946v9.9a5.475 5.475 0 002.967-4.945zM13.848 0v2.077a10.39 10.39 0 010 19.585v2.077a12.05 12.05 0 008.9-11.87A12.05 12.05 0 0013.848 0z"/></svg></cnx><cnx class="cnx-mute-icon"><svg markup-inline class="cnx-color-icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M11 2L8.25 4.25 11 7zM0 7v9h5l6 5v-6.5L3.85 7zm17 4.5c0-1.965-1.2-3.735-3-4.5v3l2.8 2.8a3.73 3.73 0 00.2-1.3zm3.4 7.45l-1.85-1.85-2.65-2.6-1.9-1.95-3-3-4.15-4.1-4.95-5L1.45 0 0 1.45 17.15 18.6 19 20.4l3.55 3.6L24 22.55zM14 23a11.83 11.83 0 003.65-1.55l-1.25-1.3c-.747.498-1.553.902-2.4 1.2V23zm9-11.5A11.77 11.77 0 0014 0v1.6A10.53 10.53 0 0120 16l1.45 1.45A11.99 11.99 0 0023 11.5z"/></svg></cnx></cnx></cnx>'},5616:(t,i,e)=>{"use strict";e.d(i,{Z:()=>s});const s='<cnx class="cnx-progress-bar"><cnx class="cnx-progress-rail-container"><cnx class="cnx-progress-rail"></cnx><cnx class="cnx-progress-fill cnx-color-icon"></cnx></cnx><cnx class="cnx-progress-handle cnx-color-icon"></cnx></cnx>'},1682:(t,i,e)=>{"use strict";e.r(i),e.d(i,{LineStream:()=>c,ParseStream:()=>p,Parser:()=>g});var s=function(){function t(){this.listeners={}}var i=t.prototype;return i.on=function(t,i){this.listeners[t]||(this.listeners[t]=[]),this.listeners[t].push(i)},i.off=function(t,i){if(!this.listeners[t])return!1;var e=this.listeners[t].indexOf(i);return this.listeners[t]=this.listeners[t].slice(0),this.listeners[t].splice(e,1),e>-1},i.trigger=function(t){var i=this.listeners[t];if(i)if(2===arguments.length)for(var e=i.length,s=0;s<e;++s)i[s].call(this,arguments[1]);else for(var n=Array.prototype.slice.call(arguments,1),r=i.length,o=0;o<r;++o)i[o].apply(this,n)},i.dispose=function(){this.listeners={}},i.pipe=function(t){this.on("data",(function(i){t.push(i)}))},t}();function n(){return n=Object.assign?Object.assign.bind():function(t){for(var i=1;i<arguments.length;i++){var e=arguments[i];for(var s in e)Object.prototype.hasOwnProperty.call(e,s)&&(t[s]=e[s])}return t},n.apply(this,arguments)}var r=e(8908),o=e.n(r),h=function(t){return o().atob?o().atob(t):Buffer.from(t,"base64").toString("binary")};function a(t){for(var i=h(t),e=new Uint8Array(i.length),s=0;s<i.length;s++)e[s]=i.charCodeAt(s);return e}class c extends s{constructor(){super(),this.buffer=""}push(t){let i;for(this.buffer+=t,i=this.buffer.indexOf("\n");i>-1;i=this.buffer.indexOf("\n"))this.trigger("data",this.buffer.substring(0,i)),this.buffer=this.buffer.substring(i+1)}}const d=String.fromCharCode(9),l=function(t){const i=/([0-9.]*)?@?([0-9.]*)?/.exec(t||""),e={};return i[1]&&(e.length=parseInt(i[1],10)),i[2]&&(e.offset=parseInt(i[2],10)),e},u=function(t){const i={};if(!t)return i;const e=t.split(new RegExp('(?:^|,)((?:[^=]*)=(?:"[^"]*"|[^,]*))'));let s,n=e.length;for(;n--;)""!==e[n]&&(s=/([^=]*)=(.*)/.exec(e[n]).slice(1),s[0]=s[0].replace(/^\s+|\s+$/g,""),s[1]=s[1].replace(/^\s+|\s+$/g,""),s[1]=s[1].replace(/^['"](.*)['"]$/g,"$1"),i[s[0]]=s[1]);return i};class p extends s{constructor(){super(),this.customParsers=[],this.tagMappers=[]}push(t){let i,e;if(0===(t=t.trim()).length)return;if("#"!==t[0])return void this.trigger("data",{type:"uri",uri:t});this.tagMappers.reduce(((i,e)=>{const s=e(t);return s===t?i:i.concat([s])}),[t]).forEach((t=>{for(let i=0;i<this.customParsers.length;i++)if(this.customParsers[i].call(this,t))return;if(0===t.indexOf("#EXT"))if(t=t.replace("\r",""),i=/^#EXTM3U/.exec(t),i)this.trigger("data",{type:"tag",tagType:"m3u"});else{if(i=/^#EXTINF:([0-9\.]*)?,?(.*)?$/.exec(t),i)return e={type:"tag",tagType:"inf"},i[1]&&(e.duration=parseFloat(i[1])),i[2]&&(e.title=i[2]),void this.trigger("data",e);if(i=/^#EXT-X-TARGETDURATION:([0-9.]*)?/.exec(t),i)return e={type:"tag",tagType:"targetduration"},i[1]&&(e.duration=parseInt(i[1],10)),void this.trigger("data",e);if(i=/^#EXT-X-VERSION:([0-9.]*)?/.exec(t),i)return e={type:"tag",tagType:"version"},i[1]&&(e.version=parseInt(i[1],10)),void this.trigger("data",e);if(i=/^#EXT-X-MEDIA-SEQUENCE:(\-?[0-9.]*)?/.exec(t),i)return e={type:"tag",tagType:"media-sequence"},i[1]&&(e.number=parseInt(i[1],10)),void this.trigger("data",e);if(i=/^#EXT-X-DISCONTINUITY-SEQUENCE:(\-?[0-9.]*)?/.exec(t),i)return e={type:"tag",tagType:"discontinuity-sequence"},i[1]&&(e.number=parseInt(i[1],10)),void this.trigger("data",e);if(i=/^#EXT-X-PLAYLIST-TYPE:(.*)?$/.exec(t),i)return e={type:"tag",tagType:"playlist-type"},i[1]&&(e.playlistType=i[1]),void this.trigger("data",e);if(i=/^#EXT-X-BYTERANGE:(.*)?$/.exec(t),i)return e=n(l(i[1]),{type:"tag",tagType:"byterange"}),void this.trigger("data",e);if(i=/^#EXT-X-ALLOW-CACHE:(YES|NO)?/.exec(t),i)return e={type:"tag",tagType:"allow-cache"},i[1]&&(e.allowed=!/NO/.test(i[1])),void this.trigger("data",e);if(i=/^#EXT-X-MAP:(.*)$/.exec(t),i){if(e={type:"tag",tagType:"map"},i[1]){const t=u(i[1]);t.URI&&(e.uri=t.URI),t.BYTERANGE&&(e.byterange=l(t.BYTERANGE))}this.trigger("data",e)}else if(i=/^#EXT-X-STREAM-INF:(.*)$/.exec(t),i){if(e={type:"tag",tagType:"stream-inf"},i[1]){if(e.attributes=u(i[1]),e.attributes.RESOLUTION){const t=e.attributes.RESOLUTION.split("x"),i={};t[0]&&(i.width=parseInt(t[0],10)),t[1]&&(i.height=parseInt(t[1],10)),e.attributes.RESOLUTION=i}e.attributes.BANDWIDTH&&(e.attributes.BANDWIDTH=parseInt(e.attributes.BANDWIDTH,10)),e.attributes["FRAME-RATE"]&&(e.attributes["FRAME-RATE"]=parseFloat(e.attributes["FRAME-RATE"])),e.attributes["PROGRAM-ID"]&&(e.attributes["PROGRAM-ID"]=parseInt(e.attributes["PROGRAM-ID"],10))}this.trigger("data",e)}else{if(i=/^#EXT-X-MEDIA:(.*)$/.exec(t),i)return e={type:"tag",tagType:"media"},i[1]&&(e.attributes=u(i[1])),void this.trigger("data",e);if(i=/^#EXT-X-ENDLIST/.exec(t),i)this.trigger("data",{type:"tag",tagType:"endlist"});else if(i=/^#EXT-X-DISCONTINUITY/.exec(t),i)this.trigger("data",{type:"tag",tagType:"discontinuity"});else{if(i=/^#EXT-X-PROGRAM-DATE-TIME:(.*)$/.exec(t),i)return e={type:"tag",tagType:"program-date-time"},i[1]&&(e.dateTimeString=i[1],e.dateTimeObject=new Date(i[1])),void this.trigger("data",e);if(i=/^#EXT-X-KEY:(.*)$/.exec(t),i)return e={type:"tag",tagType:"key"},i[1]&&(e.attributes=u(i[1]),e.attributes.IV&&("0x"===e.attributes.IV.substring(0,2).toLowerCase()&&(e.attributes.IV=e.attributes.IV.substring(2)),e.attributes.IV=e.attributes.IV.match(/.{8}/g),e.attributes.IV[0]=parseInt(e.attributes.IV[0],16),e.attributes.IV[1]=parseInt(e.attributes.IV[1],16),e.attributes.IV[2]=parseInt(e.attributes.IV[2],16),e.attributes.IV[3]=parseInt(e.attributes.IV[3],16),e.attributes.IV=new Uint32Array(e.attributes.IV))),void this.trigger("data",e);if(i=/^#EXT-X-START:(.*)$/.exec(t),i)return e={type:"tag",tagType:"start"},i[1]&&(e.attributes=u(i[1]),e.attributes["TIME-OFFSET"]=parseFloat(e.attributes["TIME-OFFSET"]),e.attributes.PRECISE=/YES/.test(e.attributes.PRECISE)),void this.trigger("data",e);if(i=/^#EXT-X-CUE-OUT-CONT:(.*)?$/.exec(t),i)return e={type:"tag",tagType:"cue-out-cont"},i[1]?e.data=i[1]:e.data="",void this.trigger("data",e);if(i=/^#EXT-X-CUE-OUT:(.*)?$/.exec(t),i)return e={type:"tag",tagType:"cue-out"},i[1]?e.data=i[1]:e.data="",void this.trigger("data",e);if(i=/^#EXT-X-CUE-IN:(.*)?$/.exec(t),i)return e={type:"tag",tagType:"cue-in"},i[1]?e.data=i[1]:e.data="",void this.trigger("data",e);if(i=/^#EXT-X-SKIP:(.*)$/.exec(t),i&&i[1])return e={type:"tag",tagType:"skip"},e.attributes=u(i[1]),e.attributes.hasOwnProperty("SKIPPED-SEGMENTS")&&(e.attributes["SKIPPED-SEGMENTS"]=parseInt(e.attributes["SKIPPED-SEGMENTS"],10)),e.attributes.hasOwnProperty("RECENTLY-REMOVED-DATERANGES")&&(e.attributes["RECENTLY-REMOVED-DATERANGES"]=e.attributes["RECENTLY-REMOVED-DATERANGES"].split(d)),void this.trigger("data",e);if(i=/^#EXT-X-PART:(.*)$/.exec(t),i&&i[1])return e={type:"tag",tagType:"part"},e.attributes=u(i[1]),["DURATION"].forEach((function(t){e.attributes.hasOwnProperty(t)&&(e.attributes[t]=parseFloat(e.attributes[t]))})),["INDEPENDENT","GAP"].forEach((function(t){e.attributes.hasOwnProperty(t)&&(e.attributes[t]=/YES/.test(e.attributes[t]))})),e.attributes.hasOwnProperty("BYTERANGE")&&(e.attributes.byterange=l(e.attributes.BYTERANGE)),void this.trigger("data",e);if(i=/^#EXT-X-SERVER-CONTROL:(.*)$/.exec(t),i&&i[1])return e={type:"tag",tagType:"server-control"},e.attributes=u(i[1]),["CAN-SKIP-UNTIL","PART-HOLD-BACK","HOLD-BACK"].forEach((function(t){e.attributes.hasOwnProperty(t)&&(e.attributes[t]=parseFloat(e.attributes[t]))})),["CAN-SKIP-DATERANGES","CAN-BLOCK-RELOAD"].forEach((function(t){e.attributes.hasOwnProperty(t)&&(e.attributes[t]=/YES/.test(e.attributes[t]))})),void this.trigger("data",e);if(i=/^#EXT-X-PART-INF:(.*)$/.exec(t),i&&i[1])return e={type:"tag",tagType:"part-inf"},e.attributes=u(i[1]),["PART-TARGET"].forEach((function(t){e.attributes.hasOwnProperty(t)&&(e.attributes[t]=parseFloat(e.attributes[t]))})),void this.trigger("data",e);if(i=/^#EXT-X-PRELOAD-HINT:(.*)$/.exec(t),i&&i[1])return e={type:"tag",tagType:"preload-hint"},e.attributes=u(i[1]),["BYTERANGE-START","BYTERANGE-LENGTH"].forEach((function(t){if(e.attributes.hasOwnProperty(t)){e.attributes[t]=parseInt(e.attributes[t],10);const i="BYTERANGE-LENGTH"===t?"length":"offset";e.attributes.byterange=e.attributes.byterange||{},e.attributes.byterange[i]=e.attributes[t],delete e.attributes[t]}})),void this.trigger("data",e);if(i=/^#EXT-X-RENDITION-REPORT:(.*)$/.exec(t),i&&i[1])return e={type:"tag",tagType:"rendition-report"},e.attributes=u(i[1]),["LAST-MSN","LAST-PART"].forEach((function(t){e.attributes.hasOwnProperty(t)&&(e.attributes[t]=parseInt(e.attributes[t],10))})),void this.trigger("data",e);this.trigger("data",{type:"tag",data:t.slice(4)})}}}else this.trigger("data",{type:"comment",text:t.slice(1)})}))}addParser({expression:t,customType:i,dataParser:e,segment:s}){"function"!=typeof e&&(e=t=>t),this.customParsers.push((n=>{if(t.exec(n))return this.trigger("data",{type:"custom",data:e(n),customType:i,segment:s}),!0}))}addTagMapper({expression:t,map:i}){this.tagMappers.push((e=>t.test(e)?i(e):e))}}const f=function(t){const i={};return Object.keys(t).forEach((function(e){var s;i[(s=e,s.toLowerCase().replace(/-(\w)/g,(t=>t[1].toUpperCase())))]=t[e]})),i},m=function(t){const{serverControl:i,targetDuration:e,partTargetDuration:s}=t;if(!i)return;const n="#EXT-X-SERVER-CONTROL",r="holdBack",o="partHoldBack",h=e&&3*e,a=s&&2*s;e&&!i.hasOwnProperty(r)&&(i[r]=h,this.trigger("info",{message:`${n} defaulting HOLD-BACK to targetDuration * 3 (${h}).`})),h&&i[r]<h&&(this.trigger("warn",{message:`${n} clamping HOLD-BACK (${i[r]}) to targetDuration * 3 (${h})`}),i[r]=h),s&&!i.hasOwnProperty(o)&&(i[o]=3*s,this.trigger("info",{message:`${n} defaulting PART-HOLD-BACK to partTargetDuration * 3 (${i[o]}).`})),s&&i[o]<a&&(this.trigger("warn",{message:`${n} clamping PART-HOLD-BACK (${i[o]}) to partTargetDuration * 2 (${a}).`}),i[o]=a)};class g extends s{constructor(){super(),this.lineStream=new c,this.parseStream=new p,this.lineStream.pipe(this.parseStream);const t=this,i=[];let e,s,r={},o=!1;const h=function(){},d={AUDIO:{},VIDEO:{},"CLOSED-CAPTIONS":{},SUBTITLES:{}};let l=0;this.manifest={allowCache:!0,discontinuityStarts:[],segments:[]};let u=0,g=0;this.on("end",(()=>{r.uri||!r.parts&&!r.preloadHints||(!r.map&&e&&(r.map=e),!r.key&&s&&(r.key=s),r.timeline||"number"!=typeof l||(r.timeline=l),this.manifest.preloadSegment=r)})),this.parseStream.on("data",(function(c){let p,v;({tag(){({version(){c.version&&(this.manifest.version=c.version)},"allow-cache"(){this.manifest.allowCache=c.allowed,"allowed"in c||(this.trigger("info",{message:"defaulting allowCache to YES"}),this.manifest.allowCache=!0)},byterange(){const t={};"length"in c&&(r.byterange=t,t.length=c.length,"offset"in c||(c.offset=u)),"offset"in c&&(r.byterange=t,t.offset=c.offset),u=t.offset+t.length},endlist(){this.manifest.endList=!0},inf(){"mediaSequence"in this.manifest||(this.manifest.mediaSequence=0,this.trigger("info",{message:"defaulting media sequence to zero"})),"discontinuitySequence"in this.manifest||(this.manifest.discontinuitySequence=0,this.trigger("info",{message:"defaulting discontinuity sequence to zero"})),c.duration>0&&(r.duration=c.duration),0===c.duration&&(r.duration=.01,this.trigger("info",{message:"updating zero segment duration to a small value"})),this.manifest.segments=i},key(){if(c.attributes)if("NONE"!==c.attributes.METHOD)if(c.attributes.URI){if("com.apple.streamingkeydelivery"===c.attributes.KEYFORMAT)return this.manifest.contentProtection=this.manifest.contentProtection||{},void(this.manifest.contentProtection["com.apple.fps.1_0"]={attributes:c.attributes});if("com.microsoft.playready"===c.attributes.KEYFORMAT)return this.manifest.contentProtection=this.manifest.contentProtection||{},void(this.manifest.contentProtection["com.microsoft.playready"]={uri:c.attributes.URI});if("urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed"===c.attributes.KEYFORMAT){return-1===["SAMPLE-AES","SAMPLE-AES-CTR","SAMPLE-AES-CENC"].indexOf(c.attributes.METHOD)?void this.trigger("warn",{message:"invalid key method provided for Widevine"}):("SAMPLE-AES-CENC"===c.attributes.METHOD&&this.trigger("warn",{message:"SAMPLE-AES-CENC is deprecated, please use SAMPLE-AES-CTR instead"}),"data:text/plain;base64,"!==c.attributes.URI.substring(0,23)?void this.trigger("warn",{message:"invalid key URI provided for Widevine"}):c.attributes.KEYID&&"0x"===c.attributes.KEYID.substring(0,2)?(this.manifest.contentProtection=this.manifest.contentProtection||{},void(this.manifest.contentProtection["com.widevine.alpha"]={attributes:{schemeIdUri:c.attributes.KEYFORMAT,keyId:c.attributes.KEYID.substring(2)},pssh:a(c.attributes.URI.split(",")[1])})):void this.trigger("warn",{message:"invalid key ID provided for Widevine"}))}c.attributes.METHOD||this.trigger("warn",{message:"defaulting key method to AES-128"}),s={method:c.attributes.METHOD||"AES-128",uri:c.attributes.URI},void 0!==c.attributes.IV&&(s.iv=c.attributes.IV)}else this.trigger("warn",{message:"ignoring key declaration without URI"});else s=null;else this.trigger("warn",{message:"ignoring key declaration without attribute list"})},"media-sequence"(){isFinite(c.number)?this.manifest.mediaSequence=c.number:this.trigger("warn",{message:"ignoring invalid media sequence: "+c.number})},"discontinuity-sequence"(){isFinite(c.number)?(this.manifest.discontinuitySequence=c.number,l=c.number):this.trigger("warn",{message:"ignoring invalid discontinuity sequence: "+c.number})},"playlist-type"(){/VOD|EVENT/.test(c.playlistType)?this.manifest.playlistType=c.playlistType:this.trigger("warn",{message:"ignoring unknown playlist type: "+c.playlist})},map(){e={},c.uri&&(e.uri=c.uri),c.byterange&&(e.byterange=c.byterange),s&&(e.key=s)},"stream-inf"(){this.manifest.playlists=i,this.manifest.mediaGroups=this.manifest.mediaGroups||d,c.attributes?(r.attributes||(r.attributes={}),n(r.attributes,c.attributes)):this.trigger("warn",{message:"ignoring empty stream-inf attributes"})},media(){if(this.manifest.mediaGroups=this.manifest.mediaGroups||d,!(c.attributes&&c.attributes.TYPE&&c.attributes["GROUP-ID"]&&c.attributes.NAME))return void this.trigger("warn",{message:"ignoring incomplete or missing media group"});const t=this.manifest.mediaGroups[c.attributes.TYPE];t[c.attributes["GROUP-ID"]]=t[c.attributes["GROUP-ID"]]||{},p=t[c.attributes["GROUP-ID"]],v={default:/yes/i.test(c.attributes.DEFAULT)},v.default?v.autoselect=!0:v.autoselect=/yes/i.test(c.attributes.AUTOSELECT),c.attributes.LANGUAGE&&(v.language=c.attributes.LANGUAGE),c.attributes.URI&&(v.uri=c.attributes.URI),c.attributes["INSTREAM-ID"]&&(v.instreamId=c.attributes["INSTREAM-ID"]),c.attributes.CHARACTERISTICS&&(v.characteristics=c.attributes.CHARACTERISTICS),c.attributes.FORCED&&(v.forced=/yes/i.test(c.attributes.FORCED)),p[c.attributes.NAME]=v},discontinuity(){l+=1,r.discontinuity=!0,this.manifest.discontinuityStarts.push(i.length)},"program-date-time"(){void 0===this.manifest.dateTimeString&&(this.manifest.dateTimeString=c.dateTimeString,this.manifest.dateTimeObject=c.dateTimeObject),r.dateTimeString=c.dateTimeString,r.dateTimeObject=c.dateTimeObject},targetduration(){!isFinite(c.duration)||c.duration<0?this.trigger("warn",{message:"ignoring invalid target duration: "+c.duration}):(this.manifest.targetDuration=c.duration,m.call(this,this.manifest))},start(){c.attributes&&!isNaN(c.attributes["TIME-OFFSET"])?this.manifest.start={timeOffset:c.attributes["TIME-OFFSET"],precise:c.attributes.PRECISE}:this.trigger("warn",{message:"ignoring start declaration without appropriate attribute list"})},"cue-out"(){r.cueOut=c.data},"cue-out-cont"(){r.cueOutCont=c.data},"cue-in"(){r.cueIn=c.data},skip(){this.manifest.skip=f(c.attributes),this.warnOnMissingAttributes_("#EXT-X-SKIP",c.attributes,["SKIPPED-SEGMENTS"])},part(){o=!0;const t=this.manifest.segments.length,i=f(c.attributes);r.parts=r.parts||[],r.parts.push(i),i.byterange&&(i.byterange.hasOwnProperty("offset")||(i.byterange.offset=g),g=i.byterange.offset+i.byterange.length);const e=r.parts.length-1;this.warnOnMissingAttributes_(`#EXT-X-PART #${e} for segment #${t}`,c.attributes,["URI","DURATION"]),this.manifest.renditionReports&&this.manifest.renditionReports.forEach(((t,i)=>{t.hasOwnProperty("lastPart")||this.trigger("warn",{message:`#EXT-X-RENDITION-REPORT #${i} lacks required attribute(s): LAST-PART`})}))},"server-control"(){const t=this.manifest.serverControl=f(c.attributes);t.hasOwnProperty("canBlockReload")||(t.canBlockReload=!1,this.trigger("info",{message:"#EXT-X-SERVER-CONTROL defaulting CAN-BLOCK-RELOAD to false"})),m.call(this,this.manifest),t.canSkipDateranges&&!t.hasOwnProperty("canSkipUntil")&&this.trigger("warn",{message:"#EXT-X-SERVER-CONTROL lacks required attribute CAN-SKIP-UNTIL which is required when CAN-SKIP-DATERANGES is set"})},"preload-hint"(){const t=this.manifest.segments.length,i=f(c.attributes),e=i.type&&"PART"===i.type;r.preloadHints=r.preloadHints||[],r.preloadHints.push(i),i.byterange&&(i.byterange.hasOwnProperty("offset")||(i.byterange.offset=e?g:0,e&&(g=i.byterange.offset+i.byterange.length)));const s=r.preloadHints.length-1;if(this.warnOnMissingAttributes_(`#EXT-X-PRELOAD-HINT #${s} for segment #${t}`,c.attributes,["TYPE","URI"]),i.type)for(let e=0;e<r.preloadHints.length-1;e++){const n=r.preloadHints[e];n.type&&(n.type===i.type&&this.trigger("warn",{message:`#EXT-X-PRELOAD-HINT #${s} for segment #${t} has the same TYPE ${i.type} as preload hint #${e}`}))}},"rendition-report"(){const t=f(c.attributes);this.manifest.renditionReports=this.manifest.renditionReports||[],this.manifest.renditionReports.push(t);const i=this.manifest.renditionReports.length-1,e=["LAST-MSN","URI"];o&&e.push("LAST-PART"),this.warnOnMissingAttributes_(`#EXT-X-RENDITION-REPORT #${i}`,c.attributes,e)},"part-inf"(){this.manifest.partInf=f(c.attributes),this.warnOnMissingAttributes_("#EXT-X-PART-INF",c.attributes,["PART-TARGET"]),this.manifest.partInf.partTarget&&(this.manifest.partTargetDuration=this.manifest.partInf.partTarget),m.call(this,this.manifest)}}[c.tagType]||h).call(t)},uri(){r.uri=c.uri,i.push(r),this.manifest.targetDuration&&!("duration"in r)&&(this.trigger("warn",{message:"defaulting segment duration to the target duration"}),r.duration=this.manifest.targetDuration),s&&(r.key=s),r.timeline=l,e&&(r.map=e),g=0,r={}},comment(){},custom(){c.segment?(r.custom=r.custom||{},r.custom[c.customType]=c.data):(this.manifest.custom=this.manifest.custom||{},this.manifest.custom[c.customType]=c.data)}})[c.type].call(t)}))}warnOnMissingAttributes_(t,i,e){const s=[];e.forEach((function(t){i.hasOwnProperty(t)||s.push(t)})),s.length&&this.trigger("warn",{message:`${t} lacks required attribute(s): ${s.join(", ")}`})}push(t){this.lineStream.push(t)}end(){this.lineStream.push("\n"),this.trigger("end")}addParser(t){this.parseStream.addParser(t)}addTagMapper(t){this.parseStream.addTagMapper(t)}}},4467:(t,i,e)=>{"use strict";var s;e.d(i,{q:()=>s}),function(t){t[t.BottomRight=0]="BottomRight",t[t.TopLeft=1]="TopLeft"}(s||(s={}))},5919:(t,i,e)=>{"use strict";var s;e.d(i,{x:()=>s}),function(t){t[t.Playing=0]="Playing",t[t.Paused=1]="Paused",t[t.Stopped=2]="Stopped",t[t.Buffering=3]="Buffering",t[t.Preroll=4]="Preroll",t[t.Postroll=5]="Postroll"}(s||(s={}))},4492:(t,i,e)=>{"use strict";t.exports=e(8836)},3996:(t,i,e)=>{"use strict";var s=i,n=e(7025),r=e(9935);function o(t,i,e,s){var r=!1;if(i.resolvedType)if(i.resolvedType instanceof n){t("switch(d%s){",s);for(var o=i.resolvedType.values,h=Object.keys(o),a=0;a<h.length;++a)o[h[a]]!==i.typeDefault||r||(t("default:")('if(typeof(d%s)==="number"){m%s=d%s;break}',s,s,s),i.repeated||t("break"),r=!0),t("case%j:",h[a])("case %i:",o[h[a]])("m%s=%j",s,o[h[a]])("break");t("}")}else t('if(typeof d%s!=="object")',s)("throw TypeError(%j)",i.fullName+": object expected")("m%s=types[%i].fromObject(d%s)",s,e,s);else{var c=!1;switch(i.type){case"double":case"float":t("m%s=Number(d%s)",s,s);break;case"uint32":case"fixed32":t("m%s=d%s>>>0",s,s);break;case"int32":case"sint32":case"sfixed32":t("m%s=d%s|0",s,s);break;case"uint64":c=!0;case"int64":case"sint64":case"fixed64":case"sfixed64":t("if(util.Long)")("(m%s=util.Long.fromValue(d%s)).unsigned=%j",s,s,c)('else if(typeof d%s==="string")',s)("m%s=parseInt(d%s,10)",s,s)('else if(typeof d%s==="number")',s)("m%s=d%s",s,s)('else if(typeof d%s==="object")',s)("m%s=new util.LongBits(d%s.low>>>0,d%s.high>>>0).toNumber(%s)",s,s,s,c?"true":"");break;case"bytes":t('if(typeof d%s==="string")',s)("util.base64.decode(d%s,m%s=util.newBuffer(util.base64.length(d%s)),0)",s,s,s)("else if(d%s.length >= 0)",s)("m%s=d%s",s,s);break;case"string":t("m%s=String(d%s)",s,s);break;case"bool":t("m%s=Boolean(d%s)",s,s)}}return t}function h(t,i,e,s){if(i.resolvedType)i.resolvedType instanceof n?t("d%s=o.enums===String?(types[%i].values[m%s]===undefined?m%s:types[%i].values[m%s]):m%s",s,e,s,s,e,s,s):t("d%s=types[%i].toObject(m%s,o)",s,e,s);else{var r=!1;switch(i.type){case"double":case"float":t("d%s=o.json&&!isFinite(m%s)?String(m%s):m%s",s,s,s,s);break;case"uint64":r=!0;case"int64":case"sint64":case"fixed64":case"sfixed64":t('if(typeof m%s==="number")',s)("d%s=o.longs===String?String(m%s):m%s",s,s,s)("else")("d%s=o.longs===String?util.Long.prototype.toString.call(m%s):o.longs===Number?new util.LongBits(m%s.low>>>0,m%s.high>>>0).toNumber(%s):m%s",s,s,s,s,r?"true":"",s);break;case"bytes":t("d%s=o.bytes===String?util.base64.encode(m%s,0,m%s.length):o.bytes===Array?Array.prototype.slice.call(m%s):m%s",s,s,s,s,s);break;default:t("d%s=m%s",s,s)}}return t}s.fromObject=function(t){var i=t.fieldsArray,e=r.codegen(["d"],t.name+"$fromObject")("if(d instanceof this.ctor)")("return d");if(!i.length)return e("return new this.ctor");e("var m=new this.ctor");for(var s=0;s<i.length;++s){var h=i[s].resolve(),a=r.safeProp(h.name);h.map?(e("if(d%s){",a)('if(typeof d%s!=="object")',a)("throw TypeError(%j)",h.fullName+": object expected")("m%s={}",a)("for(var ks=Object.keys(d%s),i=0;i<ks.length;++i){",a),o(e,h,s,a+"[ks[i]]")("}")("}")):h.repeated?(e("if(d%s){",a)("if(!Array.isArray(d%s))",a)("throw TypeError(%j)",h.fullName+": array expected")("m%s=[]",a)("for(var i=0;i<d%s.length;++i){",a),o(e,h,s,a+"[i]")("}")("}")):(h.resolvedType instanceof n||e("if(d%s!=null){",a),o(e,h,s,a),h.resolvedType instanceof n||e("}"))}return e("return m")},s.toObject=function(t){var i=t.fieldsArray.slice().sort(r.compareFieldsById);if(!i.length)return r.codegen()("return {}");for(var e=r.codegen(["m","o"],t.name+"$toObject")("if(!o)")("o={}")("var d={}"),s=[],o=[],a=[],c=0;c<i.length;++c)i[c].partOf||(i[c].resolve().repeated?s:i[c].map?o:a).push(i[c]);if(s.length){for(e("if(o.arrays||o.defaults){"),c=0;c<s.length;++c)e("d%s=[]",r.safeProp(s[c].name));e("}")}if(o.length){for(e("if(o.objects||o.defaults){"),c=0;c<o.length;++c)e("d%s={}",r.safeProp(o[c].name));e("}")}if(a.length){for(e("if(o.defaults){"),c=0;c<a.length;++c){var d=a[c],l=r.safeProp(d.name);if(d.resolvedType instanceof n)e("d%s=o.enums===String?%j:%j",l,d.resolvedType.valuesById[d.typeDefault],d.typeDefault);else if(d.long)e("if(util.Long){")("var n=new util.Long(%i,%i,%j)",d.typeDefault.low,d.typeDefault.high,d.typeDefault.unsigned)("d%s=o.longs===String?n.toString():o.longs===Number?n.toNumber():n",l)("}else")("d%s=o.longs===String?%j:%i",l,d.typeDefault.toString(),d.typeDefault.toNumber());else if(d.bytes){var u="["+Array.prototype.slice.call(d.typeDefault).join(",")+"]";e("if(o.bytes===String)d%s=%j",l,String.fromCharCode.apply(String,d.typeDefault))("else{")("d%s=%s",l,u)("if(o.bytes!==Array)d%s=util.newBuffer(d%s)",l,l)("}")}else e("d%s=%j",l,d.typeDefault)}e("}")}var p=!1;for(c=0;c<i.length;++c){d=i[c];var f=t.R.indexOf(d);l=r.safeProp(d.name);d.map?(p||(p=!0,e("var ks2")),e("if(m%s&&(ks2=Object.keys(m%s)).length){",l,l)("d%s={}",l)("for(var j=0;j<ks2.length;++j){"),h(e,d,f,l+"[ks2[j]]")("}")):d.repeated?(e("if(m%s&&m%s.length){",l,l)("d%s=[]",l)("for(var j=0;j<m%s.length;++j){",l),h(e,d,f,l+"[j]")("}")):(e("if(m%s!=null&&m.hasOwnProperty(%j)){",l,d.name),h(e,d,f,l),d.partOf&&e("if(o.oneofs)")("d%s=%j",r.safeProp(d.partOf.name),d.name)),e("}")}return e("return d")}},5305:(t,i,e)=>{"use strict";t.exports=function(t){var i=r.codegen(["r","l"],t.name+"$decode")("if(!(r instanceof Reader))")("r=Reader.create(r)")("var c=l===undefined?r.len:r.pos+l,m=new this.ctor"+(t.fieldsArray.filter((function(t){return t.map})).length?",k,value":""))("while(r.pos<c){")("var t=r.uint32()");t.group&&i("if((t&7)===4)")("break");i("switch(t>>>3){");for(var e=0;e<t.fieldsArray.length;++e){var h=t.R[e].resolve(),a=h.resolvedType instanceof s?"int32":h.type,c="m"+r.safeProp(h.name);i("case %i: {",h.id),h.map?(i("if(%s===util.emptyObject)",c)("%s={}",c)("var c2 = r.uint32()+r.pos"),void 0!==n.defaults[h.keyType]?i("k=%j",n.defaults[h.keyType]):i("k=null"),void 0!==n.defaults[a]?i("value=%j",n.defaults[a]):i("value=null"),i("while(r.pos<c2){")("var tag2=r.uint32()")("switch(tag2>>>3){")("case 1: k=r.%s(); break",h.keyType)("case 2:"),void 0===n.basic[a]?i("value=types[%i].decode(r,r.uint32())",e):i("value=r.%s()",a),i("break")("default:")("r.skipType(tag2&7)")("break")("}")("}"),void 0!==n.long[h.keyType]?i('%s[typeof k==="object"?util.longToHash(k):k]=value',c):i("%s[k]=value",c)):h.repeated?(i("if(!(%s&&%s.length))",c,c)("%s=[]",c),void 0!==n.packed[a]&&i("if((t&7)===2){")("var c2=r.uint32()+r.pos")("while(r.pos<c2)")("%s.push(r.%s())",c,a)("}else"),void 0===n.basic[a]?i(h.resolvedType.group?"%s.push(types[%i].decode(r))":"%s.push(types[%i].decode(r,r.uint32()))",c,e):i("%s.push(r.%s())",c,a)):void 0===n.basic[a]?i(h.resolvedType.group?"%s=types[%i].decode(r)":"%s=types[%i].decode(r,r.uint32())",c,e):i("%s=r.%s()",c,a),i("break")("}")}for(i("default:")("r.skipType(t&7)")("break")("}")("}"),e=0;e<t.R.length;++e){var d=t.R[e];d.required&&i("if(!m.hasOwnProperty(%j))",d.name)("throw util.ProtocolError(%j,{instance:m})",o(d))}return i("return m")};var s=e(7025),n=e(7063),r=e(9935);function o(t){return"missing required '"+t.name+"'"}},4928:(t,i,e)=>{"use strict";t.exports=function(t){for(var i,e=r.codegen(["m","w"],t.name+"$encode")("if(!w)")("w=Writer.create()"),h=t.fieldsArray.slice().sort(r.compareFieldsById),a=0;a<h.length;++a){var c=h[a].resolve(),d=t.R.indexOf(c),l=c.resolvedType instanceof s?"int32":c.type,u=n.basic[l];i="m"+r.safeProp(c.name),c.map?(e("if(%s!=null&&Object.hasOwnProperty.call(m,%j)){",i,c.name)("for(var ks=Object.keys(%s),i=0;i<ks.length;++i){",i)("w.uint32(%i).fork().uint32(%i).%s(ks[i])",(c.id<<3|2)>>>0,8|n.mapKey[c.keyType],c.keyType),void 0===u?e("types[%i].encode(%s[ks[i]],w.uint32(18).fork()).ldelim().ldelim()",d,i):e(".uint32(%i).%s(%s[ks[i]]).ldelim()",16|u,l,i),e("}")("}")):c.repeated?(e("if(%s!=null&&%s.length){",i,i),c.packed&&void 0!==n.packed[l]?e("w.uint32(%i).fork()",(c.id<<3|2)>>>0)("for(var i=0;i<%s.length;++i)",i)("w.%s(%s[i])",l,i)("w.ldelim()"):(e("for(var i=0;i<%s.length;++i)",i),void 0===u?o(e,c,d,i+"[i]"):e("w.uint32(%i).%s(%s[i])",(c.id<<3|u)>>>0,l,i)),e("}")):(c.optional&&e("if(%s!=null&&Object.hasOwnProperty.call(m,%j))",i,c.name),void 0===u?o(e,c,d,i):e("w.uint32(%i).%s(%s)",(c.id<<3|u)>>>0,l,i))}return e("return w")};var s=e(7025),n=e(7063),r=e(9935);function o(t,i,e,s){return i.resolvedType.group?t("types[%i].encode(%s,w.uint32(%i)).uint32(%i)",e,s,(i.id<<3|3)>>>0,(i.id<<3|4)>>>0):t("types[%i].encode(%s,w.uint32(%i).fork()).ldelim()",e,s,(i.id<<3|2)>>>0)}},7025:(t,i,e)=>{"use strict";t.exports=o;var s=e(3243);((o.prototype=Object.create(s.prototype)).constructor=o).className="Enum";var n=e(9313),r=e(9935);function o(t,i,e,n,r,o){if(s.call(this,t,e),i&&"object"!=typeof i)throw TypeError("values must be an object");if(this.valuesById={},this.values=Object.create(this.valuesById),this.comment=n,this.comments=r||{},this.valuesOptions=o,this.reserved=void 0,i)for(var h=Object.keys(i),a=0;a<h.length;++a)"number"==typeof i[h[a]]&&(this.valuesById[this.values[h[a]]=i[h[a]]]=h[a])}o.fromJSON=function(t,i){var e=new o(t,i.values,i.options,i.comment,i.comments);return e.reserved=i.reserved,e},o.prototype.toJSON=function(t){var i=!!t&&Boolean(t.keepComments);return r.toObject(["options",this.options,"valuesOptions",this.valuesOptions,"values",this.values,"reserved",this.reserved&&this.reserved.length?this.reserved:void 0,"comment",i?this.comment:void 0,"comments",i?this.comments:void 0])},o.prototype.add=function(t,i,e,s){if(!r.isString(t))throw TypeError("name must be a string");if(!r.isInteger(i))throw TypeError("id must be an integer");if(void 0!==this.values[t])throw Error("duplicate name '"+t+"' in "+this);if(this.isReservedId(i))throw Error("id "+i+" is reserved in "+this);if(this.isReservedName(t))throw Error("name '"+t+"' is reserved in "+this);if(void 0!==this.valuesById[i]){if(!this.options||!this.options.allow_alias)throw Error("duplicate id "+i+" in "+this);this.values[t]=i}else this.valuesById[this.values[t]=i]=t;return s&&(void 0===this.valuesOptions&&(this.valuesOptions={}),this.valuesOptions[t]=s||null),this.comments[t]=e||null,this},o.prototype.remove=function(t){if(!r.isString(t))throw TypeError("name must be a string");var i=this.values[t];if(null==i)throw Error("name '"+t+"' does not exist in "+this);return delete this.valuesById[i],delete this.values[t],delete this.comments[t],this.valuesOptions&&delete this.valuesOptions[t],this},o.prototype.isReservedId=function(t){return n.isReservedId(this.reserved,t)},o.prototype.isReservedName=function(t){return n.isReservedName(this.reserved,t)}},3548:(t,i,e)=>{"use strict";t.exports=c;var s=e(3243);((c.prototype=Object.create(s.prototype)).constructor=c).className="Field";var n,r=e(7025),o=e(7063),h=e(9935),a=/^required|optional|repeated$/;function c(t,i,e,n,r,c,d){if(h.isObject(n)?(d=r,c=n,n=r=void 0):h.isObject(r)&&(d=c,c=r,r=void 0),s.call(this,t,c),!h.isInteger(i)||i<0)throw TypeError("id must be a non-negative integer");if(!h.isString(e))throw TypeError("type must be a string");if(void 0!==n&&!a.test(n=n.toString().toLowerCase()))throw TypeError("rule must be a string rule");if(void 0!==r&&!h.isString(r))throw TypeError("extend must be a string");"proto3_optional"===n&&(n="optional"),this.rule=n&&"optional"!==n?n:void 0,this.type=e,this.id=i,this.extend=r||void 0,this.required="required"===n,this.optional=!this.required,this.repeated="repeated"===n,this.map=!1,this.message=null,this.partOf=null,this.typeDefault=null,this.defaultValue=null,this.long=!!h.Long&&void 0!==o.long[e],this.bytes="bytes"===e,this.resolvedType=null,this.extensionField=null,this.declaringField=null,this.U=null,this.comment=d}c.fromJSON=function(t,i){return new c(t,i.id,i.type,i.rule,i.extend,i.options,i.comment)},Object.defineProperty(c.prototype,"packed",{get:function(){return null===this.U&&(this.U=!1!==this.getOption("packed")),this.U}}),c.prototype.setOption=function(t,i,e){return"packed"===t&&(this.U=null),s.prototype.setOption.call(this,t,i,e)},c.prototype.toJSON=function(t){var i=!!t&&Boolean(t.keepComments);return h.toObject(["rule","optional"!==this.rule&&this.rule||void 0,"type",this.type,"id",this.id,"extend",this.extend,"options",this.options,"comment",i?this.comment:void 0])},c.prototype.resolve=function(){if(this.resolved)return this;if(void 0===(this.typeDefault=o.defaults[this.type])?(this.resolvedType=(this.declaringField?this.declaringField.parent:this.parent).lookupTypeOrEnum(this.type),this.resolvedType instanceof n?this.typeDefault=null:this.typeDefault=this.resolvedType.values[Object.keys(this.resolvedType.values)[0]]):this.options&&this.options.proto3_optional&&(this.typeDefault=null),this.options&&null!=this.options.default&&(this.typeDefault=this.options.default,this.resolvedType instanceof r&&"string"==typeof this.typeDefault&&(this.typeDefault=this.resolvedType.values[this.typeDefault])),this.options&&(!0!==this.options.packed&&(void 0===this.options.packed||!this.resolvedType||this.resolvedType instanceof r)||delete this.options.packed,Object.keys(this.options).length||(this.options=void 0)),this.long)this.typeDefault=h.Long.fromNumber(this.typeDefault,"u"===this.type.charAt(0)),Object.freeze&&Object.freeze(this.typeDefault);else if(this.bytes&&"string"==typeof this.typeDefault){var t;h.base64.test(this.typeDefault)?h.base64.decode(this.typeDefault,t=h.newBuffer(h.base64.length(this.typeDefault)),0):h.utf8.write(this.typeDefault,t=h.newBuffer(h.utf8.length(this.typeDefault)),0),this.typeDefault=t}return this.map?this.defaultValue=h.emptyObject:this.repeated?this.defaultValue=h.emptyArray:this.defaultValue=this.typeDefault,this.parent instanceof n&&(this.parent.ctor.prototype[this.name]=this.defaultValue),s.prototype.resolve.call(this)},c.d=function(t,i,e,s){return"function"==typeof i?i=h.decorateType(i).name:i&&"object"==typeof i&&(i=h.decorateEnum(i).name),function(n,r){h.decorateType(n.constructor).add(new c(r,t,i,e,{default:s}))}},c.W=function(t){n=t}},8836:(t,i,e)=>{"use strict";var s=t.exports=e(9482);s.build="light",s.load=function(t,i,e){return"function"==typeof i?(e=i,i=new s.Root):i||(i=new s.Root),i.load(t,e)},s.loadSync=function(t,i){return i||(i=new s.Root),i.loadSync(t)},s.encoder=e(4928),s.decoder=e(5305),s.verifier=e(4497),s.converter=e(3996),s.ReflectionObject=e(3243),s.Namespace=e(9313),s.Root=e(9424),s.Enum=e(7025),s.Type=e(7645),s.Field=e(3548),s.OneOf=e(7598),s.MapField=e(6039),s.Service=e(7513),s.Method=e(4429),s.Message=e(8368),s.wrappers=e(1667),s.types=e(7063),s.util=e(9935),s.ReflectionObject.W(s.Root),s.Namespace.W(s.Type,s.Service,s.Enum),s.Root.W(s.Type),s.Field.W(s.Type)},9482:(t,i,e)=>{"use strict";var s=i;function n(){s.util.W(),s.Writer.W(s.BufferWriter),s.Reader.W(s.BufferReader)}s.build="minimal",s.Writer=e(1173),s.BufferWriter=e(3155),s.Reader=e(1408),s.BufferReader=e(593),s.util=e(9693),s.rpc=e(5994),s.roots=e(5054),s.configure=n,n()},6039:(t,i,e)=>{"use strict";t.exports=o;var s=e(3548);((o.prototype=Object.create(s.prototype)).constructor=o).className="MapField";var n=e(7063),r=e(9935);function o(t,i,e,n,o,h){if(s.call(this,t,i,n,void 0,void 0,o,h),!r.isString(e))throw TypeError("keyType must be a string");this.keyType=e,this.resolvedKeyType=null,this.map=!0}o.fromJSON=function(t,i){return new o(t,i.id,i.keyType,i.type,i.options,i.comment)},o.prototype.toJSON=function(t){var i=!!t&&Boolean(t.keepComments);return r.toObject(["keyType",this.keyType,"type",this.type,"id",this.id,"extend",this.extend,"options",this.options,"comment",i?this.comment:void 0])},o.prototype.resolve=function(){if(this.resolved)return this;if(void 0===n.mapKey[this.keyType])throw Error("invalid key type: "+this.keyType);return s.prototype.resolve.call(this)},o.d=function(t,i,e){return"function"==typeof e?e=r.decorateType(e).name:e&&"object"==typeof e&&(e=r.decorateEnum(e).name),function(s,n){r.decorateType(s.constructor).add(new o(n,t,i,e))}}},8368:(t,i,e)=>{"use strict";t.exports=n;var s=e(9693);function n(t){if(t)for(var i=Object.keys(t),e=0;e<i.length;++e)this[i[e]]=t[i[e]]}n.create=function(t){return this.$type.create(t)},n.encode=function(t,i){return this.$type.encode(t,i)},n.encodeDelimited=function(t,i){return this.$type.encodeDelimited(t,i)},n.decode=function(t){return this.$type.decode(t)},n.decodeDelimited=function(t){return this.$type.decodeDelimited(t)},n.verify=function(t){return this.$type.verify(t)},n.fromObject=function(t){return this.$type.fromObject(t)},n.toObject=function(t,i){return this.$type.toObject(t,i)},n.prototype.toJSON=function(){return this.$type.toObject(this,s.toJSONOptions)}},4429:(t,i,e)=>{"use strict";t.exports=r;var s=e(3243);((r.prototype=Object.create(s.prototype)).constructor=r).className="Method";var n=e(9935);function r(t,i,e,r,o,h,a,c,d){if(n.isObject(o)?(a=o,o=h=void 0):n.isObject(h)&&(a=h,h=void 0),void 0!==i&&!n.isString(i))throw TypeError("type must be a string");if(!n.isString(e))throw TypeError("requestType must be a string");if(!n.isString(r))throw TypeError("responseType must be a string");s.call(this,t,a),this.type=i||"rpc",this.requestType=e,this.requestStream=!!o||void 0,this.responseType=r,this.responseStream=!!h||void 0,this.resolvedRequestType=null,this.resolvedResponseType=null,this.comment=c,this.parsedOptions=d}r.fromJSON=function(t,i){return new r(t,i.type,i.requestType,i.responseType,i.requestStream,i.responseStream,i.options,i.comment,i.parsedOptions)},r.prototype.toJSON=function(t){var i=!!t&&Boolean(t.keepComments);return n.toObject(["type","rpc"!==this.type&&this.type||void 0,"requestType",this.requestType,"requestStream",this.requestStream,"responseType",this.responseType,"responseStream",this.responseStream,"options",this.options,"comment",i?this.comment:void 0,"parsedOptions",this.parsedOptions])},r.prototype.resolve=function(){return this.resolved?this:(this.resolvedRequestType=this.parent.lookupType(this.requestType),this.resolvedResponseType=this.parent.lookupType(this.responseType),s.prototype.resolve.call(this))}},9313:(t,i,e)=>{"use strict";t.exports=l;var s=e(3243);((l.prototype=Object.create(s.prototype)).constructor=l).className="Namespace";var n,r,o,h=e(3548),a=e(9935),c=e(7598);function d(t,i){if(t&&t.length){for(var e={},s=0;s<t.length;++s)e[t[s].name]=t[s].toJSON(i);return e}}function l(t,i){s.call(this,t,i),this.nested=void 0,this.G=null}function u(t){return t.G=null,t}l.fromJSON=function(t,i){return new l(t,i.options).addJSON(i.nested)},l.arrayToJSON=d,l.isReservedId=function(t,i){if(t)for(var e=0;e<t.length;++e)if("string"!=typeof t[e]&&t[e][0]<=i&&t[e][1]>i)return!0;return!1},l.isReservedName=function(t,i){if(t)for(var e=0;e<t.length;++e)if(t[e]===i)return!0;return!1},Object.defineProperty(l.prototype,"nestedArray",{get:function(){return this.G||(this.G=a.toArray(this.nested))}}),l.prototype.toJSON=function(t){return a.toObject(["options",this.options,"nested",d(this.nestedArray,t)])},l.prototype.addJSON=function(t){if(t)for(var i,e=Object.keys(t),s=0;s<e.length;++s)i=t[e[s]],this.add((void 0!==i.fields?n.fromJSON:void 0!==i.values?o.fromJSON:void 0!==i.methods?r.fromJSON:void 0!==i.id?h.fromJSON:l.fromJSON)(e[s],i));return this},l.prototype.get=function(t){return this.nested&&this.nested[t]||null},l.prototype.getEnum=function(t){if(this.nested&&this.nested[t]instanceof o)return this.nested[t].values;throw Error("no such enum: "+t)},l.prototype.add=function(t){if(!(t instanceof h&&void 0!==t.extend||t instanceof n||t instanceof c||t instanceof o||t instanceof r||t instanceof l))throw TypeError("object must be a valid nested object");if(this.nested){var i=this.get(t.name);if(i){if(!(i instanceof l&&t instanceof l)||i instanceof n||i instanceof r)throw Error("duplicate name '"+t.name+"' in "+this);for(var e=i.nestedArray,s=0;s<e.length;++s)t.add(e[s]);this.remove(i),this.nested||(this.nested={}),t.setOptions(i.options,!0)}}else this.nested={};return this.nested[t.name]=t,t.onAdd(this),u(this)},l.prototype.remove=function(t){if(!(t instanceof s))throw TypeError("object must be a ReflectionObject");if(t.parent!==this)throw Error(t+" is not a member of "+this);return delete this.nested[t.name],Object.keys(this.nested).length||(this.nested=void 0),t.onRemove(this),u(this)},l.prototype.define=function(t,i){if(a.isString(t))t=t.split(".");else if(!Array.isArray(t))throw TypeError("illegal path");if(t&&t.length&&""===t[0])throw Error("path must be relative");for(var e=this;t.length>0;){var s=t.shift();if(e.nested&&e.nested[s]){if(!((e=e.nested[s])instanceof l))throw Error("path conflicts with non-namespace objects")}else e.add(e=new l(s))}return i&&e.addJSON(i),e},l.prototype.resolveAll=function(){for(var t=this.nestedArray,i=0;i<t.length;)t[i]instanceof l?t[i++].resolveAll():t[i++].resolve();return this.resolve()},l.prototype.lookup=function(t,i,e){if("boolean"==typeof i?(e=i,i=void 0):i&&!Array.isArray(i)&&(i=[i]),a.isString(t)&&t.length){if("."===t)return this.root;t=t.split(".")}else if(!t.length)return this;if(""===t[0])return this.root.lookup(t.slice(1),i);var s=this.get(t[0]);if(s){if(1===t.length){if(!i||i.indexOf(s.constructor)>-1)return s}else if(s instanceof l&&(s=s.lookup(t.slice(1),i,!0)))return s}else for(var n=0;n<this.nestedArray.length;++n)if(this.G[n]instanceof l&&(s=this.G[n].lookup(t,i,!0)))return s;return null===this.parent||e?null:this.parent.lookup(t,i)},l.prototype.lookupType=function(t){var i=this.lookup(t,[n]);if(!i)throw Error("no such type: "+t);return i},l.prototype.lookupEnum=function(t){var i=this.lookup(t,[o]);if(!i)throw Error("no such Enum '"+t+"' in "+this);return i},l.prototype.lookupTypeOrEnum=function(t){var i=this.lookup(t,[n,o]);if(!i)throw Error("no such Type or Enum '"+t+"' in "+this);return i},l.prototype.lookupService=function(t){var i=this.lookup(t,[r]);if(!i)throw Error("no such Service '"+t+"' in "+this);return i},l.W=function(t,i,e){n=t,r=i,o=e}},3243:(t,i,e)=>{"use strict";t.exports=r,r.className="ReflectionObject";var s,n=e(9935);function r(t,i){if(!n.isString(t))throw TypeError("name must be a string");if(i&&!n.isObject(i))throw TypeError("options must be an object");this.options=i,this.parsedOptions=null,this.name=t,this.parent=null,this.resolved=!1,this.comment=null,this.filename=null}Object.defineProperties(r.prototype,{root:{get:function(){for(var t=this;null!==t.parent;)t=t.parent;return t}},fullName:{get:function(){for(var t=[this.name],i=this.parent;i;)t.unshift(i.name),i=i.parent;return t.join(".")}}}),r.prototype.toJSON=function(){throw Error()},r.prototype.onAdd=function(t){this.parent&&this.parent!==t&&this.parent.remove(this),this.parent=t,this.resolved=!1;var i=t.root;i instanceof s&&i.tt(this)},r.prototype.onRemove=function(t){var i=t.root;i instanceof s&&i.it(this),this.parent=null,this.resolved=!1},r.prototype.resolve=function(){return this.resolved||this.root instanceof s&&(this.resolved=!0),this},r.prototype.getOption=function(t){if(this.options)return this.options[t]},r.prototype.setOption=function(t,i,e){return e&&this.options&&void 0!==this.options[t]||((this.options||(this.options={}))[t]=i),this},r.prototype.setParsedOption=function(t,i,e){this.parsedOptions||(this.parsedOptions=[]);var s=this.parsedOptions;if(e){var r=s.find((function(i){return Object.prototype.hasOwnProperty.call(i,t)}));if(r){var o=r[t];n.setProperty(o,e,i)}else(r={})[t]=n.setProperty({},e,i),s.push(r)}else{var h={};h[t]=i,s.push(h)}return this},r.prototype.setOptions=function(t,i){if(t)for(var e=Object.keys(t),s=0;s<e.length;++s)this.setOption(e[s],t[e[s]],i);return this},r.prototype.toString=function(){var t=this.constructor.className,i=this.fullName;return i.length?t+" "+i:t},r.W=function(t){s=t}},7598:(t,i,e)=>{"use strict";t.exports=o;var s=e(3243);((o.prototype=Object.create(s.prototype)).constructor=o).className="OneOf";var n=e(3548),r=e(9935);function o(t,i,e,n){if(Array.isArray(i)||(e=i,i=void 0),s.call(this,t,e),void 0!==i&&!Array.isArray(i))throw TypeError("fieldNames must be an Array");this.oneof=i||[],this.fieldsArray=[],this.comment=n}function h(t){if(t.parent)for(var i=0;i<t.fieldsArray.length;++i)t.fieldsArray[i].parent||t.parent.add(t.fieldsArray[i])}o.fromJSON=function(t,i){return new o(t,i.oneof,i.options,i.comment)},o.prototype.toJSON=function(t){var i=!!t&&Boolean(t.keepComments);return r.toObject(["options",this.options,"oneof",this.oneof,"comment",i?this.comment:void 0])},o.prototype.add=function(t){if(!(t instanceof n))throw TypeError("field must be a Field");return t.parent&&t.parent!==this.parent&&t.parent.remove(t),this.oneof.push(t.name),this.fieldsArray.push(t),t.partOf=this,h(this),this},o.prototype.remove=function(t){if(!(t instanceof n))throw TypeError("field must be a Field");var i=this.fieldsArray.indexOf(t);if(i<0)throw Error(t+" is not a member of "+this);return this.fieldsArray.splice(i,1),(i=this.oneof.indexOf(t.name))>-1&&this.oneof.splice(i,1),t.partOf=null,this},o.prototype.onAdd=function(t){s.prototype.onAdd.call(this,t);for(var i=0;i<this.oneof.length;++i){var e=t.get(this.oneof[i]);e&&!e.partOf&&(e.partOf=this,this.fieldsArray.push(e))}h(this)},o.prototype.onRemove=function(t){for(var i,e=0;e<this.fieldsArray.length;++e)(i=this.fieldsArray[e]).parent&&i.parent.remove(i);s.prototype.onRemove.call(this,t)},o.d=function(){for(var t=new Array(arguments.length),i=0;i<arguments.length;)t[i]=arguments[i++];return function(i,e){r.decorateType(i.constructor).add(new o(e,t)),Object.defineProperty(i,e,{get:r.oneOfGetter(t),set:r.oneOfSetter(t)})}}},1408:(t,i,e)=>{"use strict";t.exports=a;var s,n=e(9693),r=n.LongBits,o=n.utf8;function h(t,i){return RangeError("index out of range: "+t.pos+" + "+(i||1)+" > "+t.len)}function a(t){this.buf=t,this.pos=0,this.len=t.length}var c,d="undefined"!=typeof Uint8Array?function(t){if(t instanceof Uint8Array||Array.isArray(t))return new a(t);throw Error("illegal buffer")}:function(t){if(Array.isArray(t))return new a(t);throw Error("illegal buffer")},l=function(){return n.Buffer?function(t){return(a.create=function(t){return n.Buffer.isBuffer(t)?new s(t):d(t)})(t)}:d};function u(){var t=new r(0,0),i=0;if(!(this.len-this.pos>4)){for(;i<3;++i){if(this.pos>=this.len)throw h(this);if(t.lo=(t.lo|(127&this.buf[this.pos])<<7*i)>>>0,this.buf[this.pos++]<128)return t}return t.lo=(t.lo|(127&this.buf[this.pos++])<<7*i)>>>0,t}for(;i<4;++i)if(t.lo=(t.lo|(127&this.buf[this.pos])<<7*i)>>>0,this.buf[this.pos++]<128)return t;if(t.lo=(t.lo|(127&this.buf[this.pos])<<28)>>>0,t.hi=(t.hi|(127&this.buf[this.pos])>>4)>>>0,this.buf[this.pos++]<128)return t;if(i=0,this.len-this.pos>4){for(;i<5;++i)if(t.hi=(t.hi|(127&this.buf[this.pos])<<7*i+3)>>>0,this.buf[this.pos++]<128)return t}else for(;i<5;++i){if(this.pos>=this.len)throw h(this);if(t.hi=(t.hi|(127&this.buf[this.pos])<<7*i+3)>>>0,this.buf[this.pos++]<128)return t}throw Error("invalid varint encoding")}function p(t,i){return(t[i-4]|t[i-3]<<8|t[i-2]<<16|t[i-1]<<24)>>>0}function f(){if(this.pos+8>this.len)throw h(this,8);return new r(p(this.buf,this.pos+=4),p(this.buf,this.pos+=4))}a.create=l(),a.prototype.et=n.Array.prototype.subarray||n.Array.prototype.slice,a.prototype.uint32=(c=4294967295,function(){if(c=(127&this.buf[this.pos])>>>0,this.buf[this.pos++]<128)return c;if(c=(c|(127&this.buf[this.pos])<<7)>>>0,this.buf[this.pos++]<128)return c;if(c=(c|(127&this.buf[this.pos])<<14)>>>0,this.buf[this.pos++]<128)return c;if(c=(c|(127&this.buf[this.pos])<<21)>>>0,this.buf[this.pos++]<128)return c;if(c=(c|(15&this.buf[this.pos])<<28)>>>0,this.buf[this.pos++]<128)return c;if((this.pos+=5)>this.len)throw this.pos=this.len,h(this,10);return c}),a.prototype.int32=function(){return 0|this.uint32()},a.prototype.sint32=function(){var t=this.uint32();return t>>>1^-(1&t)|0},a.prototype.bool=function(){return 0!==this.uint32()},a.prototype.fixed32=function(){if(this.pos+4>this.len)throw h(this,4);return p(this.buf,this.pos+=4)},a.prototype.sfixed32=function(){if(this.pos+4>this.len)throw h(this,4);return 0|p(this.buf,this.pos+=4)},a.prototype.float=function(){if(this.pos+4>this.len)throw h(this,4);var t=n.float.readFloatLE(this.buf,this.pos);return this.pos+=4,t},a.prototype.double=function(){if(this.pos+8>this.len)throw h(this,4);var t=n.float.readDoubleLE(this.buf,this.pos);return this.pos+=8,t},a.prototype.bytes=function(){var t=this.uint32(),i=this.pos,e=this.pos+t;if(e>this.len)throw h(this,t);return this.pos+=t,Array.isArray(this.buf)?this.buf.slice(i,e):i===e?new this.buf.constructor(0):this.et.call(this.buf,i,e)},a.prototype.string=function(){var t=this.bytes();return o.read(t,0,t.length)},a.prototype.skip=function(t){if("number"==typeof t){if(this.pos+t>this.len)throw h(this,t);this.pos+=t}else do{if(this.pos>=this.len)throw h(this)}while(128&this.buf[this.pos++]);return this},a.prototype.skipType=function(t){switch(t){case 0:this.skip();break;case 1:this.skip(8);break;case 2:this.skip(this.uint32());break;case 3:for(;4!=(t=7&this.uint32());)this.skipType(t);break;case 5:this.skip(4);break;default:throw Error("invalid wire type "+t+" at offset "+this.pos)}return this},a.W=function(t){s=t,a.create=l(),s.W();var i=n.Long?"toLong":"toNumber";n.merge(a.prototype,{int64:function(){return u.call(this)[i](!1)},uint64:function(){return u.call(this)[i](!0)},sint64:function(){return u.call(this).zzDecode()[i](!1)},fixed64:function(){return f.call(this)[i](!0)},sfixed64:function(){return f.call(this)[i](!1)}})}},593:(t,i,e)=>{"use strict";t.exports=r;var s=e(1408);(r.prototype=Object.create(s.prototype)).constructor=r;var n=e(9693);function r(t){s.call(this,t)}r.W=function(){n.Buffer&&(r.prototype.et=n.Buffer.prototype.slice)},r.prototype.string=function(){var t=this.uint32();return this.buf.utf8Slice?this.buf.utf8Slice(this.pos,this.pos=Math.min(this.pos+t,this.len)):this.buf.toString("utf-8",this.pos,this.pos=Math.min(this.pos+t,this.len))},r.W()},9424:(t,i,e)=>{"use strict";t.exports=l;var s=e(9313);((l.prototype=Object.create(s.prototype)).constructor=l).className="Root";var n,r,o,h=e(3548),a=e(7025),c=e(7598),d=e(9935);function l(t){s.call(this,"",t),this.deferred=[],this.files=[]}function u(){}l.fromJSON=function(t,i){return i||(i=new l),t.options&&i.setOptions(t.options),i.addJSON(t.nested)},l.prototype.resolvePath=d.path.resolve,l.prototype.fetch=d.fetch,l.prototype.load=function t(i,e,s){"function"==typeof e&&(s=e,e=void 0);var n=this;if(!s)return d.asPromise(t,n,i,e);var h=s===u;function a(t,i){if(s){var e=s;if(s=null,h)throw t;e(t,i)}}function c(t){var i=t.lastIndexOf("google/protobuf/");if(i>-1){var e=t.substring(i);if(e in o)return e}return null}function l(t,i){try{if(d.isString(i)&&"{"===i.charAt(0)&&(i=JSON.parse(i)),d.isString(i)){r.filename=t;var s,o=r(i,n,e),l=0;if(o.imports)for(;l<o.imports.length;++l)(s=c(o.imports[l])||n.resolvePath(t,o.imports[l]))&&p(s);if(o.weakImports)for(l=0;l<o.weakImports.length;++l)(s=c(o.weakImports[l])||n.resolvePath(t,o.weakImports[l]))&&p(s,!0)}else n.setOptions(i.options).addJSON(i.nested)}catch(t){a(t)}h||f||a(null,n)}function p(t,i){if(t=c(t)||t,!(n.files.indexOf(t)>-1))if(n.files.push(t),t in o)h?l(t,o[t]):(++f,setTimeout((function(){--f,l(t,o[t])})));else if(h){var e;try{e=d.fs.readFileSync(t).toString("utf8")}catch(t){return void(i||a(t))}l(t,e)}else++f,n.fetch(t,(function(e,r){--f,s&&(e?i?f||a(null,n):a(e):l(t,r))}))}var f=0;d.isString(i)&&(i=[i]);for(var m,g=0;g<i.length;++g)(m=n.resolvePath("",i[g]))&&p(m);if(h)return n;f||a(null,n)},l.prototype.loadSync=function(t,i){if(!d.isNode)throw Error("not supported");return this.load(t,i,u)},l.prototype.resolveAll=function(){if(this.deferred.length)throw Error("unresolvable extensions: "+this.deferred.map((function(t){return"'extend "+t.extend+"' in "+t.parent.fullName})).join(", "));return s.prototype.resolveAll.call(this)};var p=/^[A-Z]/;function f(t,i){var e=i.parent.lookup(i.extend);if(e){var s=new h(i.fullName,i.id,i.type,i.rule,void 0,i.options);return e.get(s.name)||(s.declaringField=i,i.extensionField=s,e.add(s)),!0}return!1}l.prototype.tt=function(t){if(t instanceof h)void 0===t.extend||t.extensionField||f(0,t)||this.deferred.push(t);else if(t instanceof a)p.test(t.name)&&(t.parent[t.name]=t.values);else if(!(t instanceof c)){if(t instanceof n)for(var i=0;i<this.deferred.length;)f(0,this.deferred[i])?this.deferred.splice(i,1):++i;for(var e=0;e<t.nestedArray.length;++e)this.tt(t.G[e]);p.test(t.name)&&(t.parent[t.name]=t)}},l.prototype.it=function(t){if(t instanceof h){if(void 0!==t.extend)if(t.extensionField)t.extensionField.parent.remove(t.extensionField),t.extensionField=null;else{var i=this.deferred.indexOf(t);i>-1&&this.deferred.splice(i,1)}}else if(t instanceof a)p.test(t.name)&&delete t.parent[t.name];else if(t instanceof s){for(var e=0;e<t.nestedArray.length;++e)this.it(t.G[e]);p.test(t.name)&&delete t.parent[t.name]}},l.W=function(t,i,e){n=t,r=i,o=e}},5054:t=>{"use strict";t.exports={}},5994:(t,i,e)=>{"use strict";i.Service=e(7948)},7948:(t,i,e)=>{"use strict";t.exports=n;var s=e(9693);function n(t,i,e){if("function"!=typeof t)throw TypeError("rpcImpl must be a function");s.EventEmitter.call(this),this.rpcImpl=t,this.requestDelimited=Boolean(i),this.responseDelimited=Boolean(e)}(n.prototype=Object.create(s.EventEmitter.prototype)).constructor=n,n.prototype.rpcCall=function t(i,e,n,r,o){if(!r)throw TypeError("request must be specified");var h=this;if(!o)return s.asPromise(t,h,i,e,n,r);if(h.rpcImpl)try{return h.rpcImpl(i,e[h.requestDelimited?"encodeDelimited":"encode"](r).finish(),(function(t,e){if(t)return h.emit("error",t,i),o(t);if(null!==e){if(!(e instanceof n))try{e=n[h.responseDelimited?"decodeDelimited":"decode"](e)}catch(t){return h.emit("error",t,i),o(t)}return h.emit("data",e,i),o(null,e)}h.end(!0)}))}catch(t){return h.emit("error",t,i),void setTimeout((function(){o(t)}),0)}else setTimeout((function(){o(Error("already ended"))}),0)},n.prototype.end=function(t){return this.rpcImpl&&(t||this.rpcImpl(null,null,null),this.rpcImpl=null,this.emit("end").off()),this}},7513:(t,i,e)=>{"use strict";t.exports=h;var s=e(9313);((h.prototype=Object.create(s.prototype)).constructor=h).className="Service";var n=e(4429),r=e(9935),o=e(5994);function h(t,i){s.call(this,t,i),this.methods={},this.st=null}function a(t){return t.st=null,t}h.fromJSON=function(t,i){var e=new h(t,i.options);if(i.methods)for(var s=Object.keys(i.methods),r=0;r<s.length;++r)e.add(n.fromJSON(s[r],i.methods[s[r]]));return i.nested&&e.addJSON(i.nested),e.comment=i.comment,e},h.prototype.toJSON=function(t){var i=s.prototype.toJSON.call(this,t),e=!!t&&Boolean(t.keepComments);return r.toObject(["options",i&&i.options||void 0,"methods",s.arrayToJSON(this.methodsArray,t)||{},"nested",i&&i.nested||void 0,"comment",e?this.comment:void 0])},Object.defineProperty(h.prototype,"methodsArray",{get:function(){return this.st||(this.st=r.toArray(this.methods))}}),h.prototype.get=function(t){return this.methods[t]||s.prototype.get.call(this,t)},h.prototype.resolveAll=function(){for(var t=this.methodsArray,i=0;i<t.length;++i)t[i].resolve();return s.prototype.resolve.call(this)},h.prototype.add=function(t){if(this.get(t.name))throw Error("duplicate name '"+t.name+"' in "+this);return t instanceof n?(this.methods[t.name]=t,t.parent=this,a(this)):s.prototype.add.call(this,t)},h.prototype.remove=function(t){if(t instanceof n){if(this.methods[t.name]!==t)throw Error(t+" is not a member of "+this);return delete this.methods[t.name],t.parent=null,a(this)}return s.prototype.remove.call(this,t)},h.prototype.create=function(t,i,e){for(var s,n=new o.Service(t,i,e),h=0;h<this.methodsArray.length;++h){var a=r.lcFirst((s=this.st[h]).resolve().name).replace(/[^$\w_]/g,"");n[a]=r.codegen(["r","c"],r.isReserved(a)?a+"_":a)("return this.rpcCall(m,q,s,r,c)")({m:s,q:s.resolvedRequestType.ctor,s:s.resolvedResponseType.ctor})}return n}},7645:(t,i,e)=>{"use strict";t.exports=y;var s=e(9313);((y.prototype=Object.create(s.prototype)).constructor=y).className="Type";var n=e(7025),r=e(7598),o=e(3548),h=e(6039),a=e(7513),c=e(8368),d=e(1408),l=e(1173),u=e(9935),p=e(4928),f=e(5305),m=e(4497),g=e(3996),v=e(1667);function y(t,i){s.call(this,t,i),this.fields={},this.oneofs=void 0,this.extensions=void 0,this.reserved=void 0,this.group=void 0,this.nt=null,this.R=null,this.rt=null,this.ot=null}function b(t){return t.nt=t.R=t.rt=null,delete t.encode,delete t.decode,delete t.verify,t}Object.defineProperties(y.prototype,{fieldsById:{get:function(){if(this.nt)return this.nt;this.nt={};for(var t=Object.keys(this.fields),i=0;i<t.length;++i){var e=this.fields[t[i]],s=e.id;if(this.nt[s])throw Error("duplicate id "+s+" in "+this);this.nt[s]=e}return this.nt}},fieldsArray:{get:function(){return this.R||(this.R=u.toArray(this.fields))}},oneofsArray:{get:function(){return this.rt||(this.rt=u.toArray(this.oneofs))}},ctor:{get:function(){return this.ot||(this.ctor=y.generateConstructor(this)())},set:function(t){var i=t.prototype;i instanceof c||((t.prototype=new c).constructor=t,u.merge(t.prototype,i)),t.$type=t.prototype.$type=this,u.merge(t,c,!0),this.ot=t;for(var e=0;e<this.fieldsArray.length;++e)this.R[e].resolve();var s={};for(e=0;e<this.oneofsArray.length;++e)s[this.rt[e].resolve().name]={get:u.oneOfGetter(this.rt[e].oneof),set:u.oneOfSetter(this.rt[e].oneof)};e&&Object.defineProperties(t.prototype,s)}}}),y.generateConstructor=function(t){for(var i,e=u.codegen(["p"],t.name),s=0;s<t.fieldsArray.length;++s)(i=t.R[s]).map?e("this%s={}",u.safeProp(i.name)):i.repeated&&e("this%s=[]",u.safeProp(i.name));return e("if(p)for(var ks=Object.keys(p),i=0;i<ks.length;++i)if(p[ks[i]]!=null)")("this[ks[i]]=p[ks[i]]")},y.fromJSON=function(t,i){var e=new y(t,i.options);e.extensions=i.extensions,e.reserved=i.reserved;for(var c=Object.keys(i.fields),d=0;d<c.length;++d)e.add((void 0!==i.fields[c[d]].keyType?h.fromJSON:o.fromJSON)(c[d],i.fields[c[d]]));if(i.oneofs)for(c=Object.keys(i.oneofs),d=0;d<c.length;++d)e.add(r.fromJSON(c[d],i.oneofs[c[d]]));if(i.nested)for(c=Object.keys(i.nested),d=0;d<c.length;++d){var l=i.nested[c[d]];e.add((void 0!==l.id?o.fromJSON:void 0!==l.fields?y.fromJSON:void 0!==l.values?n.fromJSON:void 0!==l.methods?a.fromJSON:s.fromJSON)(c[d],l))}return i.extensions&&i.extensions.length&&(e.extensions=i.extensions),i.reserved&&i.reserved.length&&(e.reserved=i.reserved),i.group&&(e.group=!0),i.comment&&(e.comment=i.comment),e},y.prototype.toJSON=function(t){var i=s.prototype.toJSON.call(this,t),e=!!t&&Boolean(t.keepComments);return u.toObject(["options",i&&i.options||void 0,"oneofs",s.arrayToJSON(this.oneofsArray,t),"fields",s.arrayToJSON(this.fieldsArray.filter((function(t){return!t.declaringField})),t)||{},"extensions",this.extensions&&this.extensions.length?this.extensions:void 0,"reserved",this.reserved&&this.reserved.length?this.reserved:void 0,"group",this.group||void 0,"nested",i&&i.nested||void 0,"comment",e?this.comment:void 0])},y.prototype.resolveAll=function(){for(var t=this.fieldsArray,i=0;i<t.length;)t[i++].resolve();var e=this.oneofsArray;for(i=0;i<e.length;)e[i++].resolve();return s.prototype.resolveAll.call(this)},y.prototype.get=function(t){return this.fields[t]||this.oneofs&&this.oneofs[t]||this.nested&&this.nested[t]||null},y.prototype.add=function(t){if(this.get(t.name))throw Error("duplicate name '"+t.name+"' in "+this);if(t instanceof o&&void 0===t.extend){if(this.nt?this.nt[t.id]:this.fieldsById[t.id])throw Error("duplicate id "+t.id+" in "+this);if(this.isReservedId(t.id))throw Error("id "+t.id+" is reserved in "+this);if(this.isReservedName(t.name))throw Error("name '"+t.name+"' is reserved in "+this);return t.parent&&t.parent.remove(t),this.fields[t.name]=t,t.message=this,t.onAdd(this),b(this)}return t instanceof r?(this.oneofs||(this.oneofs={}),this.oneofs[t.name]=t,t.onAdd(this),b(this)):s.prototype.add.call(this,t)},y.prototype.remove=function(t){if(t instanceof o&&void 0===t.extend){if(!this.fields||this.fields[t.name]!==t)throw Error(t+" is not a member of "+this);return delete this.fields[t.name],t.parent=null,t.onRemove(this),b(this)}if(t instanceof r){if(!this.oneofs||this.oneofs[t.name]!==t)throw Error(t+" is not a member of "+this);return delete this.oneofs[t.name],t.parent=null,t.onRemove(this),b(this)}return s.prototype.remove.call(this,t)},y.prototype.isReservedId=function(t){return s.isReservedId(this.reserved,t)},y.prototype.isReservedName=function(t){return s.isReservedName(this.reserved,t)},y.prototype.create=function(t){return new this.ctor(t)},y.prototype.setup=function(){for(var t=this.fullName,i=[],e=0;e<this.fieldsArray.length;++e)i.push(this.R[e].resolve().resolvedType);this.encode=p(this)({Writer:l,types:i,util:u}),this.decode=f(this)({Reader:d,types:i,util:u}),this.verify=m(this)({types:i,util:u}),this.fromObject=g.fromObject(this)({types:i,util:u}),this.toObject=g.toObject(this)({types:i,util:u});var s=v[t];if(s){var n=Object.create(this);n.fromObject=this.fromObject,this.fromObject=s.fromObject.bind(n),n.toObject=this.toObject,this.toObject=s.toObject.bind(n)}return this},y.prototype.encode=function(t,i){return this.setup().encode(t,i)},y.prototype.encodeDelimited=function(t,i){return this.encode(t,i&&i.len?i.fork():i).ldelim()},y.prototype.decode=function(t,i){return this.setup().decode(t,i)},y.prototype.decodeDelimited=function(t){return t instanceof d||(t=d.create(t)),this.decode(t,t.uint32())},y.prototype.verify=function(t){return this.setup().verify(t)},y.prototype.fromObject=function(t){return this.setup().fromObject(t)},y.prototype.toObject=function(t,i){return this.setup().toObject(t,i)},y.d=function(t){return function(i){u.decorateType(i,t)}}},7063:(t,i,e)=>{"use strict";var s=i,n=e(9935),r=["double","float","int32","uint32","sint32","fixed32","sfixed32","int64","uint64","sint64","fixed64","sfixed64","bool","string","bytes"];function o(t,i){var e=0,s={};for(i|=0;e<t.length;)s[r[e+i]]=t[e++];return s}s.basic=o([1,5,0,0,0,5,5,0,0,0,1,1,0,2,2]),s.defaults=o([0,0,0,0,0,0,0,0,0,0,0,0,!1,"",n.emptyArray,null]),s.long=o([0,0,0,1,1],7),s.mapKey=o([0,0,0,5,5,0,0,0,1,1,0,2],2),s.packed=o([1,5,0,0,0,5,5,0,0,0,1,1,0])},9935:(t,i,e)=>{"use strict";var s,n,r=t.exports=e(9693),o=e(5054);r.codegen=e(5124),r.fetch=e(9054),r.path=e(8626),r.fs=r.inquire("fs"),r.toArray=function(t){if(t){for(var i=Object.keys(t),e=new Array(i.length),s=0;s<i.length;)e[s]=t[i[s++]];return e}return[]},r.toObject=function(t){for(var i={},e=0;e<t.length;){var s=t[e++],n=t[e++];void 0!==n&&(i[s]=n)}return i};var h=/\\/g,a=/"/g;r.isReserved=function(t){return/^(?:do|if|in|for|let|new|try|var|case|else|enum|eval|false|null|this|true|void|with|break|catch|class|const|super|throw|while|yield|delete|export|import|public|return|static|switch|typeof|default|extends|finally|package|private|continue|debugger|function|arguments|interface|protected|implements|instanceof)$/.test(t)},r.safeProp=function(t){return!/^[$\w_]+$/.test(t)||r.isReserved(t)?'["'+t.replace(h,"\\\\").replace(a,'\\"')+'"]':"."+t},r.ucFirst=function(t){return t.charAt(0).toUpperCase()+t.substring(1)};var c=/_([a-z])/g;r.camelCase=function(t){return t.substring(0,1)+t.substring(1).replace(c,(function(t,i){return i.toUpperCase()}))},r.compareFieldsById=function(t,i){return t.id-i.id},r.decorateType=function(t,i){if(t.$type)return i&&t.$type.name!==i&&(r.decorateRoot.remove(t.$type),t.$type.name=i,r.decorateRoot.add(t.$type)),t.$type;s||(s=e(7645));var n=new s(i||t.name);return r.decorateRoot.add(n),n.ctor=t,Object.defineProperty(t,"$type",{value:n,enumerable:!1}),Object.defineProperty(t.prototype,"$type",{value:n,enumerable:!1}),n};var d=0;r.decorateEnum=function(t){if(t.$type)return t.$type;n||(n=e(7025));var i=new n("Enum"+d++,t);return r.decorateRoot.add(i),Object.defineProperty(t,"$type",{value:i,enumerable:!1}),i},r.setProperty=function(t,i,e){if("object"!=typeof t)throw TypeError("dst must be an object");if(!i)throw TypeError("path must be specified");return function t(i,e,s){var n=e.shift();if("__proto__"===n)return i;if(e.length>0)i[n]=t(i[n]||{},e,s);else{var r=i[n];r&&(s=[].concat(r).concat(s)),i[n]=s}return i}(t,i=i.split("."),e)},Object.defineProperty(r,"decorateRoot",{get:function(){return o.decorated||(o.decorated=new(e(9424)))}})},1945:(t,i,e)=>{"use strict";t.exports=n;var s=e(9693);function n(t,i){this.lo=t>>>0,this.hi=i>>>0}var r=n.zero=new n(0,0);r.toNumber=function(){return 0},r.zzEncode=r.zzDecode=function(){return this},r.length=function(){return 1};var o=n.zeroHash="\0\0\0\0\0\0\0\0";n.fromNumber=function(t){if(0===t)return r;var i=t<0;i&&(t=-t);var e=t>>>0,s=(t-e)/4294967296>>>0;return i&&(s=~s>>>0,e=~e>>>0,++e>4294967295&&(e=0,++s>4294967295&&(s=0))),new n(e,s)},n.from=function(t){if("number"==typeof t)return n.fromNumber(t);if(s.isString(t)){if(!s.Long)return n.fromNumber(parseInt(t,10));t=s.Long.fromString(t)}return t.low||t.high?new n(t.low>>>0,t.high>>>0):r},n.prototype.toNumber=function(t){if(!t&&this.hi>>>31){var i=1+~this.lo>>>0,e=~this.hi>>>0;return i||(e=e+1>>>0),-(i+4294967296*e)}return this.lo+4294967296*this.hi},n.prototype.toLong=function(t){return s.Long?new s.Long(0|this.lo,0|this.hi,Boolean(t)):{low:0|this.lo,high:0|this.hi,unsigned:Boolean(t)}};var h=String.prototype.charCodeAt;n.fromHash=function(t){return t===o?r:new n((h.call(t,0)|h.call(t,1)<<8|h.call(t,2)<<16|h.call(t,3)<<24)>>>0,(h.call(t,4)|h.call(t,5)<<8|h.call(t,6)<<16|h.call(t,7)<<24)>>>0)},n.prototype.toHash=function(){return String.fromCharCode(255&this.lo,this.lo>>>8&255,this.lo>>>16&255,this.lo>>>24,255&this.hi,this.hi>>>8&255,this.hi>>>16&255,this.hi>>>24)},n.prototype.zzEncode=function(){var t=this.hi>>31;return this.hi=((this.hi<<1|this.lo>>>31)^t)>>>0,this.lo=(this.lo<<1^t)>>>0,this},n.prototype.zzDecode=function(){var t=-(1&this.lo);return this.lo=((this.lo>>>1|this.hi<<31)^t)>>>0,this.hi=(this.hi>>>1^t)>>>0,this},n.prototype.length=function(){var t=this.lo,i=(this.lo>>>28|this.hi<<4)>>>0,e=this.hi>>>24;return 0===e?0===i?t<16384?t<128?1:2:t<2097152?3:4:i<16384?i<128?5:6:i<2097152?7:8:e<128?9:10}},9693:function(t,i,e){"use strict";var s=i;function n(t,i,e){for(var s=Object.keys(i),n=0;n<s.length;++n)void 0!==t[s[n]]&&e||(t[s[n]]=i[s[n]]);return t}function r(t){function i(t,e){if(!(this instanceof i))return new i(t,e);Object.defineProperty(this,"message",{get:function(){return t}}),Error.captureStackTrace?Error.captureStackTrace(this,i):Object.defineProperty(this,"stack",{value:(new Error).stack||""}),e&&n(this,e)}return i.prototype=Object.create(Error.prototype,{constructor:{value:i,writable:!0,enumerable:!1,configurable:!0},name:{get:function(){return t},set:void 0,enumerable:!1,configurable:!0},toString:{value:function(){return this.name+": "+this.message},writable:!0,enumerable:!1,configurable:!0}}),i}s.asPromise=e(4537),s.base64=e(7419),s.EventEmitter=e(9211),s.float=e(945),s.inquire=e(7199),s.utf8=e(4997),s.pool=e(6662),s.LongBits=e(1945),s.isNode=Boolean(void 0!==e.g&&e.g&&e.g.process&&e.g.process.versions&&e.g.process.versions.node),s.global=s.isNode&&e.g||"undefined"!=typeof window&&window||"undefined"!=typeof self&&self||this,s.emptyArray=Object.freeze?Object.freeze([]):[],s.emptyObject=Object.freeze?Object.freeze({}):{},s.isInteger=Number.isInteger||function(t){return"number"==typeof t&&isFinite(t)&&Math.floor(t)===t},s.isString=function(t){return"string"==typeof t||t instanceof String},s.isObject=function(t){return t&&"object"==typeof t},s.isset=s.isSet=function(t,i){var e=t[i];return!(null==e||!t.hasOwnProperty(i))&&("object"!=typeof e||(Array.isArray(e)?e.length:Object.keys(e).length)>0)},s.Buffer=function(){try{var t=s.inquire("buffer").Buffer;return t.prototype.utf8Write?t:null}catch(t){return null}}(),s.ht=null,s.dt=null,s.newBuffer=function(t){return"number"==typeof t?s.Buffer?s.dt(t):new s.Array(t):s.Buffer?s.ht(t):"undefined"==typeof Uint8Array?t:new Uint8Array(t)},s.Array="undefined"!=typeof Uint8Array?Uint8Array:Array,s.Long=s.global.dcodeIO&&s.global.dcodeIO.Long||s.global.Long||s.inquire("long"),s.key2Re=/^true|false|0|1$/,s.key32Re=/^-?(?:0|[1-9][0-9]*)$/,s.key64Re=/^(?:[\\x00-\\xff]{8}|-?(?:0|[1-9][0-9]*))$/,s.longToHash=function(t){return t?s.LongBits.from(t).toHash():s.LongBits.zeroHash},s.longFromHash=function(t,i){var e=s.LongBits.fromHash(t);return s.Long?s.Long.fromBits(e.lo,e.hi,i):e.toNumber(Boolean(i))},s.merge=n,s.lcFirst=function(t){return t.charAt(0).toLowerCase()+t.substring(1)},s.newError=r,s.ProtocolError=r("ProtocolError"),s.oneOfGetter=function(t){for(var i={},e=0;e<t.length;++e)i[t[e]]=1;return function(){for(var t=Object.keys(this),e=t.length-1;e>-1;--e)if(1===i[t[e]]&&void 0!==this[t[e]]&&null!==this[t[e]])return t[e]}},s.oneOfSetter=function(t){return function(i){for(var e=0;e<t.length;++e)t[e]!==i&&delete this[t[e]]}},s.toJSONOptions={longs:String,enums:String,bytes:String,json:!0},s.W=function(){var t=s.Buffer;t?(s.ht=t.from!==Uint8Array.from&&t.from||function(i,e){return new t(i,e)},s.dt=t.allocUnsafe||function(i){return new t(i)}):s.ht=s.dt=null}},4497:(t,i,e)=>{"use strict";t.exports=function(t){var i=n.codegen(["m"],t.name+"$verify")('if(typeof m!=="object"||m===null)')("return%j","object expected"),e=t.oneofsArray,s={};e.length&&i("var p={}");for(var a=0;a<t.fieldsArray.length;++a){var c=t.R[a].resolve(),d="m"+n.safeProp(c.name);if(c.optional&&i("if(%s!=null&&m.hasOwnProperty(%j)){",d,c.name),c.map)i("if(!util.isObject(%s))",d)("return%j",r(c,"object"))("var k=Object.keys(%s)",d)("for(var i=0;i<k.length;++i){"),h(i,c,"k[i]"),o(i,c,a,d+"[k[i]]")("}");else if(c.repeated)i("if(!Array.isArray(%s))",d)("return%j",r(c,"array"))("for(var i=0;i<%s.length;++i){",d),o(i,c,a,d+"[i]")("}");else{if(c.partOf){var l=n.safeProp(c.partOf.name);1===s[c.partOf.name]&&i("if(p%s===1)",l)("return%j",c.partOf.name+": multiple values"),s[c.partOf.name]=1,i("p%s=1",l)}o(i,c,a,d)}c.optional&&i("}")}return i("return null")};var s=e(7025),n=e(9935);function r(t,i){return t.name+": "+i+(t.repeated&&"array"!==i?"[]":t.map&&"object"!==i?"{k:"+t.keyType+"}":"")+" expected"}function o(t,i,e,n){if(i.resolvedType)if(i.resolvedType instanceof s){t("switch(%s){",n)("default:")("return%j",r(i,"enum value"));for(var o=Object.keys(i.resolvedType.values),h=0;h<o.length;++h)t("case %i:",i.resolvedType.values[o[h]]);t("break")("}")}else t("{")("var e=types[%i].verify(%s);",e,n)("if(e)")("return%j+e",i.name+".")("}");else switch(i.type){case"int32":case"uint32":case"sint32":case"fixed32":case"sfixed32":t("if(!util.isInteger(%s))",n)("return%j",r(i,"integer"));break;case"int64":case"uint64":case"sint64":case"fixed64":case"sfixed64":t("if(!util.isInteger(%s)&&!(%s&&util.isInteger(%s.low)&&util.isInteger(%s.high)))",n,n,n,n)("return%j",r(i,"integer|Long"));break;case"float":case"double":t('if(typeof %s!=="number")',n)("return%j",r(i,"number"));break;case"bool":t('if(typeof %s!=="boolean")',n)("return%j",r(i,"boolean"));break;case"string":t("if(!util.isString(%s))",n)("return%j",r(i,"string"));break;case"bytes":t('if(!(%s&&typeof %s.length==="number"||util.isString(%s)))',n,n,n)("return%j",r(i,"buffer"))}return t}function h(t,i,e){switch(i.keyType){case"int32":case"uint32":case"sint32":case"fixed32":case"sfixed32":t("if(!util.key32Re.test(%s))",e)("return%j",r(i,"integer key"));break;case"int64":case"uint64":case"sint64":case"fixed64":case"sfixed64":t("if(!util.key64Re.test(%s))",e)("return%j",r(i,"integer|Long key"));break;case"bool":t("if(!util.key2Re.test(%s))",e)("return%j",r(i,"boolean key"))}return t}},1667:(t,i,e)=>{"use strict";var s=i,n=e(8368);s[".google.protobuf.Any"]={fromObject:function(t){if(t&&t["@type"]){var i=t["@type"].substring(t["@type"].lastIndexOf("/")+1),e=this.lookup(i);if(e){var s="."===t["@type"].charAt(0)?t["@type"].slice(1):t["@type"];return-1===s.indexOf("/")&&(s="/"+s),this.create({type_url:s,value:e.encode(e.fromObject(t)).finish()})}}return this.fromObject(t)},toObject:function(t,i){var e="",s="";if(i&&i.json&&t.type_url&&t.value){s=t.type_url.substring(t.type_url.lastIndexOf("/")+1),e=t.type_url.substring(0,t.type_url.lastIndexOf("/")+1);var r=this.lookup(s);r&&(t=r.decode(t.value))}if(!(t instanceof this.ctor)&&t instanceof n){var o=t.$type.toObject(t,i);return""===e&&(e="type.googleapis.com/"),s=e+("."===t.$type.fullName[0]?t.$type.fullName.slice(1):t.$type.fullName),o["@type"]=s,o}return this.toObject(t,i)}}},1173:(t,i,e)=>{"use strict";t.exports=l;var s,n=e(9693),r=n.LongBits,o=n.base64,h=n.utf8;function a(t,i,e){this.fn=t,this.len=i,this.next=void 0,this.val=e}function c(){}function d(t){this.head=t.head,this.tail=t.tail,this.len=t.len,this.next=t.states}function l(){this.len=0,this.head=new a(c,0,0),this.tail=this.head,this.states=null}var u=function(){return n.Buffer?function(){return(l.create=function(){return new s})()}:function(){return new l}};function p(t,i,e){i[e]=255&t}function f(t,i){this.len=t,this.next=void 0,this.val=i}function m(t,i,e){for(;t.hi;)i[e++]=127&t.lo|128,t.lo=(t.lo>>>7|t.hi<<25)>>>0,t.hi>>>=7;for(;t.lo>127;)i[e++]=127&t.lo|128,t.lo=t.lo>>>7;i[e++]=t.lo}function g(t,i,e){i[e]=255&t,i[e+1]=t>>>8&255,i[e+2]=t>>>16&255,i[e+3]=t>>>24}l.create=u(),l.alloc=function(t){return new n.Array(t)},n.Array!==Array&&(l.alloc=n.pool(l.alloc,n.Array.prototype.subarray)),l.prototype.lt=function(t,i,e){return this.tail=this.tail.next=new a(t,i,e),this.len+=i,this},f.prototype=Object.create(a.prototype),f.prototype.fn=function(t,i,e){for(;t>127;)i[e++]=127&t|128,t>>>=7;i[e]=t},l.prototype.uint32=function(t){return this.len+=(this.tail=this.tail.next=new f((t>>>=0)<128?1:t<16384?2:t<2097152?3:t<268435456?4:5,t)).len,this},l.prototype.int32=function(t){return t<0?this.lt(m,10,r.fromNumber(t)):this.uint32(t)},l.prototype.sint32=function(t){return this.uint32((t<<1^t>>31)>>>0)},l.prototype.uint64=function(t){var i=r.from(t);return this.lt(m,i.length(),i)},l.prototype.int64=l.prototype.uint64,l.prototype.sint64=function(t){var i=r.from(t).zzEncode();return this.lt(m,i.length(),i)},l.prototype.bool=function(t){return this.lt(p,1,t?1:0)},l.prototype.fixed32=function(t){return this.lt(g,4,t>>>0)},l.prototype.sfixed32=l.prototype.fixed32,l.prototype.fixed64=function(t){var i=r.from(t);return this.lt(g,4,i.lo).lt(g,4,i.hi)},l.prototype.sfixed64=l.prototype.fixed64,l.prototype.float=function(t){return this.lt(n.float.writeFloatLE,4,t)},l.prototype.double=function(t){return this.lt(n.float.writeDoubleLE,8,t)};var v=n.Array.prototype.set?function(t,i,e){i.set(t,e)}:function(t,i,e){for(var s=0;s<t.length;++s)i[e+s]=t[s]};l.prototype.bytes=function(t){var i=t.length>>>0;if(!i)return this.lt(p,1,0);if(n.isString(t)){var e=l.alloc(i=o.length(t));o.decode(t,e,0),t=e}return this.uint32(i).lt(v,i,t)},l.prototype.string=function(t){var i=h.length(t);return i?this.uint32(i).lt(h.write,i,t):this.lt(p,1,0)},l.prototype.fork=function(){return this.states=new d(this),this.head=this.tail=new a(c,0,0),this.len=0,this},l.prototype.reset=function(){return this.states?(this.head=this.states.head,this.tail=this.states.tail,this.len=this.states.len,this.states=this.states.next):(this.head=this.tail=new a(c,0,0),this.len=0),this},l.prototype.ldelim=function(){var t=this.head,i=this.tail,e=this.len;return this.reset().uint32(e),e&&(this.tail.next=t.next,this.tail=i,this.len+=e),this},l.prototype.finish=function(){for(var t=this.head.next,i=this.constructor.alloc(this.len),e=0;t;)t.fn(t.val,i,e),e+=t.len,t=t.next;return i},l.W=function(t){s=t,l.create=u(),s.W()}},3155:(t,i,e)=>{"use strict";t.exports=r;var s=e(1173);(r.prototype=Object.create(s.prototype)).constructor=r;var n=e(9693);function r(){s.call(this)}function o(t,i,e){t.length<40?n.utf8.write(t,i,e):i.utf8Write?i.utf8Write(t,e):i.write(t,e)}r.W=function(){r.alloc=n.dt,r.writeBytesBuffer=n.Buffer&&n.Buffer.prototype instanceof Uint8Array&&"set"===n.Buffer.prototype.set.name?function(t,i,e){i.set(t,e)}:function(t,i,e){if(t.copy)t.copy(i,e,0,t.length);else for(var s=0;s<t.length;)i[e++]=t[s++]}},r.prototype.bytes=function(t){n.isString(t)&&(t=n.ht(t,"base64"));var i=t.length>>>0;return this.uint32(i),i&&this.lt(r.writeBytesBuffer,i,t),this},r.prototype.string=function(t){var i=n.Buffer.byteLength(t);return this.uint32(i),i&&this.lt(o,i,t),this},r.W()},8660:(t,i,e)=>{var s;!function(t){!function(i){var s="object"==typeof e.g?e.g:"object"==typeof self?self:"object"==typeof this?this:Function("return this;")(),n=r(t);function r(t,i){return function(e,s){"function"!=typeof t[e]&&Object.defineProperty(t,e,{configurable:!0,writable:!0,value:s}),i&&i(e,s)}}void 0===s.Reflect?s.Reflect=t:n=r(s.Reflect,n),function(t){var i=Object.prototype.hasOwnProperty,e="function"==typeof Symbol,s=e&&void 0!==Symbol.toPrimitive?Symbol.toPrimitive:"@@toPrimitive",n=e&&void 0!==Symbol.iterator?Symbol.iterator:"@@iterator",r="function"==typeof Object.create,o={__proto__:[]}instanceof Array,h=!r&&!o,a={create:r?function(){return st(Object.create(null))}:o?function(){return st({__proto__:null})}:function(){return st({})},has:h?function(t,e){return i.call(t,e)}:function(t,i){return i in t},get:h?function(t,e){return i.call(t,e)?t[e]:void 0}:function(t,i){return t[i]}},c=Object.getPrototypeOf(Function),d="object"==typeof process&&{DEBUG_MODE:!1}&&"true"==={DEBUG_MODE:!1}.REFLECT_METADATA_USE_MAP_POLYFILL,l=d||"function"!=typeof Map||"function"!=typeof Map.prototype.entries?tt():Map,u=d||"function"!=typeof Set||"function"!=typeof Set.prototype.entries?it():Set,p=new(d||"function"!=typeof WeakMap?et():WeakMap);function f(t,i,e,s){if(O(e)){if(!H(t))throw new TypeError;if(!W(i))throw new TypeError;return A(t,i)}if(!H(t))throw new TypeError;if(!F(i))throw new TypeError;if(!F(s)&&!O(s)&&!D(s))throw new TypeError;return D(s)&&(s=void 0),_(t,i,e=q(e),s)}function m(t,i){function e(e,s){if(!F(e))throw new TypeError;if(!O(s)&&!G(s))throw new TypeError;M(t,i,e,s)}return e}function g(t,i,e,s){if(!F(e))throw new TypeError;return O(s)||(s=q(s)),M(t,i,e,s)}function v(t,i,e){if(!F(i))throw new TypeError;return O(e)||(e=q(e)),T(t,i,e)}function y(t,i,e){if(!F(i))throw new TypeError;return O(e)||(e=q(e)),k(t,i,e)}function b(t,i,e){if(!F(i))throw new TypeError;return O(e)||(e=q(e)),C(t,i,e)}function I(t,i,e){if(!F(i))throw new TypeError;return O(e)||(e=q(e)),E(t,i,e)}function w(t,i){if(!F(t))throw new TypeError;return O(i)||(i=q(i)),L(t,i)}function S(t,i){if(!F(t))throw new TypeError;return O(i)||(i=q(i)),B(t,i)}function P(t,i,e){if(!F(i))throw new TypeError;O(e)||(e=q(e));var s=x(i,e,!1);if(O(s))return!1;if(!s.delete(t))return!1;if(s.size>0)return!0;var n=p.get(i);return n.delete(e),n.size>0||p.delete(i),!0}function A(t,i){for(var e=t.length-1;e>=0;--e){var s=(0,t[e])(i);if(!O(s)&&!D(s)){if(!W(s))throw new TypeError;i=s}}return i}function _(t,i,e,s){for(var n=t.length-1;n>=0;--n){var r=(0,t[n])(i,e,s);if(!O(r)&&!D(r)){if(!F(r))throw new TypeError;s=r}}return s}function x(t,i,e){var s=p.get(t);if(O(s)){if(!e)return;s=new l,p.set(t,s)}var n=s.get(i);if(O(n)){if(!e)return;n=new l,s.set(i,n)}return n}function T(t,i,e){if(k(t,i,e))return!0;var s=Z(i);return!D(s)&&T(t,s,e)}function k(t,i,e){var s=x(i,e,!1);return!O(s)&&$(s.has(t))}function C(t,i,e){if(k(t,i,e))return E(t,i,e);var s=Z(i);return D(s)?void 0:C(t,s,e)}function E(t,i,e){var s=x(i,e,!1);if(!O(s))return s.get(t)}function M(t,i,e,s){x(e,s,!0).set(t,i)}function L(t,i){var e=B(t,i),s=Z(t);if(null===s)return e;var n=L(s,i);if(n.length<=0)return e;if(e.length<=0)return n;for(var r=new u,o=[],h=0,a=e;h<a.length;h++){var c=a[h];r.has(c)||(r.add(c),o.push(c))}for(var d=0,l=n;d<l.length;d++){c=l[d];r.has(c)||(r.add(c),o.push(c))}return o}function B(t,i){var e=[],s=x(t,i,!1);if(O(s))return e;for(var n=Q(s.keys()),r=0;;){var o=Y(n);if(!o)return e.length=r,e;var h=J(o);try{e[r]=h}catch(t){try{K(n)}finally{throw t}}r++}}function R(t){if(null===t)return 1;switch(typeof t){case"undefined":return 0;case"boolean":return 2;case"string":return 3;case"symbol":return 4;case"number":return 5;case"object":return null===t?1:6;default:return 6}}function O(t){return void 0===t}function D(t){return null===t}function V(t){return"symbol"==typeof t}function F(t){return"object"==typeof t?null!==t:"function"==typeof t}function N(t,i){switch(R(t)){case 0:case 1:case 2:case 3:case 4:case 5:return t}var e=3===i?"string":5===i?"number":"default",n=X(t,s);if(void 0!==n){var r=n.call(t,e);if(F(r))throw new TypeError;return r}return j(t,"default"===e?"number":e)}function j(t,i){if("string"===i){var e=t.toString;if(z(e))if(!F(n=e.call(t)))return n;if(z(s=t.valueOf))if(!F(n=s.call(t)))return n}else{var s;if(z(s=t.valueOf))if(!F(n=s.call(t)))return n;var n,r=t.toString;if(z(r))if(!F(n=r.call(t)))return n}throw new TypeError}function $(t){return!!t}function U(t){return""+t}function q(t){var i=N(t,3);return V(i)?i:U(i)}function H(t){return Array.isArray?Array.isArray(t):t instanceof Object?t instanceof Array:"[object Array]"===Object.prototype.toString.call(t)}function z(t){return"function"==typeof t}function W(t){return"function"==typeof t}function G(t){switch(R(t)){case 3:case 4:return!0;default:return!1}}function X(t,i){var e=t[i];if(null!=e){if(!z(e))throw new TypeError;return e}}function Q(t){var i=X(t,n);if(!z(i))throw new TypeError;var e=i.call(t);if(!F(e))throw new TypeError;return e}function J(t){return t.value}function Y(t){var i=t.next();return!i.done&&i}function K(t){var i=t.return;i&&i.call(t)}function Z(t){var i=Object.getPrototypeOf(t);if("function"!=typeof t||t===c)return i;if(i!==c)return i;var e=t.prototype,s=e&&Object.getPrototypeOf(e);if(null==s||s===Object.prototype)return i;var n=s.constructor;return"function"!=typeof n||n===t?i:n}function tt(){var t={},i=[],e=function(){function t(t,i,e){this.ut=0,this.ft=t,this.gt=i,this.vt=e}return t.prototype["@@iterator"]=function(){return this},t.prototype[n]=function(){return this},t.prototype.next=function(){var t=this.ut;if(t>=0&&t<this.ft.length){var e=this.vt(this.ft[t],this.gt[t]);return t+1>=this.ft.length?(this.ut=-1,this.ft=i,this.gt=i):this.ut++,{value:e,done:!1}}return{value:void 0,done:!0}},t.prototype.throw=function(t){throw this.ut>=0&&(this.ut=-1,this.ft=i,this.gt=i),t},t.prototype.return=function(t){return this.ut>=0&&(this.ut=-1,this.ft=i,this.gt=i),{value:t,done:!0}},t}();return function(){function i(){this.ft=[],this.gt=[],this.yt=t,this.bt=-2}return Object.defineProperty(i.prototype,"size",{get:function(){return this.ft.length},enumerable:!0,configurable:!0}),i.prototype.has=function(t){return this.It(t,!1)>=0},i.prototype.get=function(t){var i=this.It(t,!1);return i>=0?this.gt[i]:void 0},i.prototype.set=function(t,i){var e=this.It(t,!0);return this.gt[e]=i,this},i.prototype.delete=function(i){var e=this.It(i,!1);if(e>=0){for(var s=this.ft.length,n=e+1;n<s;n++)this.ft[n-1]=this.ft[n],this.gt[n-1]=this.gt[n];return this.ft.length--,this.gt.length--,i===this.yt&&(this.yt=t,this.bt=-2),!0}return!1},i.prototype.clear=function(){this.ft.length=0,this.gt.length=0,this.yt=t,this.bt=-2},i.prototype.keys=function(){return new e(this.ft,this.gt,s)},i.prototype.values=function(){return new e(this.ft,this.gt,r)},i.prototype.entries=function(){return new e(this.ft,this.gt,o)},i.prototype["@@iterator"]=function(){return this.entries()},i.prototype[n]=function(){return this.entries()},i.prototype.It=function(t,i){return this.yt!==t&&(this.bt=this.ft.indexOf(this.yt=t)),this.bt<0&&i&&(this.bt=this.ft.length,this.ft.push(t),this.gt.push(void 0)),this.bt},i}();function s(t,i){return t}function r(t,i){return i}function o(t,i){return[t,i]}}function it(){return function(){function t(){this.wt=new l}return Object.defineProperty(t.prototype,"size",{get:function(){return this.wt.size},enumerable:!0,configurable:!0}),t.prototype.has=function(t){return this.wt.has(t)},t.prototype.add=function(t){return this.wt.set(t,t),this},t.prototype.delete=function(t){return this.wt.delete(t)},t.prototype.clear=function(){this.wt.clear()},t.prototype.keys=function(){return this.wt.keys()},t.prototype.values=function(){return this.wt.values()},t.prototype.entries=function(){return this.wt.entries()},t.prototype["@@iterator"]=function(){return this.keys()},t.prototype[n]=function(){return this.keys()},t}()}function et(){var t=16,e=a.create(),s=n();return function(){function t(){this.St=n()}return t.prototype.has=function(t){var i=r(t,!1);return void 0!==i&&a.has(i,this.St)},t.prototype.get=function(t){var i=r(t,!1);return void 0!==i?a.get(i,this.St):void 0},t.prototype.set=function(t,i){return r(t,!0)[this.St]=i,this},t.prototype.delete=function(t){var i=r(t,!1);return void 0!==i&&delete i[this.St]},t.prototype.clear=function(){this.St=n()},t}();function n(){var t;do{t="@@WeakMap@@"+c()}while(a.has(e,t));return e[t]=!0,t}function r(t,e){if(!i.call(t,s)){if(!e)return;Object.defineProperty(t,s,{value:a.create()})}return t[s]}function o(t,i){for(var e=0;e<i;++e)t[e]=255*Math.random()|0;return t}function h(t){return"function"==typeof Uint8Array?"undefined"!=typeof crypto?crypto.getRandomValues(new Uint8Array(t)):"undefined"!=typeof msCrypto?msCrypto.getRandomValues(new Uint8Array(t)):o(new Uint8Array(t),t):o(new Array(t),t)}function c(){var i=h(t);i[6]=79&i[6]|64,i[8]=191&i[8]|128;for(var e="",s=0;s<t;++s){var n=i[s];4!==s&&6!==s&&8!==s||(e+="-"),n<16&&(e+="0"),e+=n.toString(16).toLowerCase()}return e}}function st(t){return t.Pt=void 0,delete t.Pt,t}t("decorate",f),t("metadata",m),t("defineMetadata",g),t("hasMetadata",v),t("hasOwnMetadata",y),t("getMetadata",b),t("getOwnMetadata",I),t("getMetadataKeys",w),t("getOwnMetadataKeys",S),t("deleteMetadata",P)}(n)}()}(s||(s={}))},6515:(t,i,e)=>{"use strict";e.d(i,{X:()=>n});var s=e(655),n=function(t){function i(i){var e=t.call(this)||this;return e.At=i,e}return(0,s.ZT)(i,t),Object.defineProperty(i.prototype,"value",{get:function(){return this.getValue()},enumerable:!1,configurable:!0}),i.prototype._t=function(i){var e=t.prototype._t.call(this,i);return!e.closed&&i.next(this.At),e},i.prototype.getValue=function(){var t=this,i=t.hasError,e=t.thrownError,s=t.At;if(i)throw e;return this.xt(),s},i.prototype.next=function(i){t.prototype.next.call(this,this.At=i)},i}(e(6716).x)},1480:(t,i,e)=>{"use strict";e.d(i,{y:()=>l});var s=e(5642),n=e(5720),r=e(6766),o=e(278);function h(t){return 0===t.length?o.y:1===t.length?t[0]:function(i){return t.reduce((function(t,i){return i(t)}),i)}}var a=e(3912),c=e(8474),d=e(8846),l=function(){function t(t){t&&(this._t=t)}return t.prototype.lift=function(i){var e=new t;return e.source=this,e.operator=i,e},t.prototype.subscribe=function(t,i,e){var r,o=this,h=(r=t)&&r instanceof s.Lv||function(t){return t&&(0,c.m)(t.next)&&(0,c.m)(t.error)&&(0,c.m)(t.complete)}(r)&&(0,n.Nn)(r)?t:new s.Hp(t,i,e);return(0,d.x)((function(){var t=o,i=t.operator,e=t.source;h.add(i?i.call(h,e):e?o._t(h):o.Tt(h))})),h},t.prototype.Tt=function(t){try{return this._t(t)}catch(i){t.error(i)}},t.prototype.forEach=function(t,i){var e=this;return new(i=u(i))((function(i,n){var r=new s.Hp({next:function(i){try{t(i)}catch(t){n(t),r.unsubscribe()}},error:n,complete:i});e.subscribe(r)}))},t.prototype._t=function(t){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(t)},t.prototype[r.L]=function(){return this},t.prototype.pipe=function(){for(var t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];return h(t)(this)},t.prototype.toPromise=function(t){var i=this;return new(t=u(t))((function(t,e){var s;i.subscribe((function(t){return s=t}),(function(t){return e(t)}),(function(){return t(s)}))}))},t.create=function(i){return new t(i)},t}();function u(t){var i;return null!==(i=null!=t?t:a.v.Promise)&&void 0!==i?i:Promise}},3:(t,i,e)=>{"use strict";e.d(i,{t:()=>o});var s=e(655),n=e(6716),r=e(4318),o=function(t){function i(i,e,s){void 0===i&&(i=1/0),void 0===e&&(e=1/0),void 0===s&&(s=r.l);var n=t.call(this)||this;return n.kt=i,n.Ct=e,n.Et=s,n.Mt=[],n.Lt=!0,n.Lt=e===1/0,n.kt=Math.max(1,i),n.Ct=Math.max(1,e),n}return(0,s.ZT)(i,t),i.prototype.next=function(i){var e=this,s=e.isStopped,n=e.Mt,r=e.Lt,o=e.Et,h=e.Ct;s||(n.push(i),!r&&n.push(o.now()+h)),this.Bt(),t.prototype.next.call(this,i)},i.prototype._t=function(t){this.xt(),this.Bt();for(var i=this.Rt(t),e=this.Lt,s=this.Mt.slice(),n=0;n<s.length&&!t.closed;n+=e?1:2)t.next(s[n]);return this.Ot(t),i},i.prototype.Bt=function(){var t=this,i=t.kt,e=t.Et,s=t.Mt,n=t.Lt,r=(n?1:2)*i;if(i<1/0&&r<s.length&&s.splice(0,s.length-r),!n){for(var o=e.now(),h=0,a=1;a<s.length&&s[a]<=o;a+=2)h=a;h&&s.splice(0,h+1)}},i}(n.x)},6716:(t,i,e)=>{"use strict";e.d(i,{x:()=>c});var s=e(655),n=e(1480),r=e(5720),o=(0,e(1819).d)((function(t){return function(){t(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}})),h=e(3699),a=e(8846),c=function(t){function i(){var i=t.call(this)||this;return i.closed=!1,i.currentObservers=null,i.observers=[],i.isStopped=!1,i.hasError=!1,i.thrownError=null,i}return(0,s.ZT)(i,t),i.prototype.lift=function(t){var i=new d(this,this);return i.operator=t,i},i.prototype.xt=function(){if(this.closed)throw new o},i.prototype.next=function(t){var i=this;(0,a.x)((function(){var e,n;if(i.xt(),!i.isStopped){i.currentObservers||(i.currentObservers=Array.from(i.observers));try{for(var r=(0,s.XA)(i.currentObservers),o=r.next();!o.done;o=r.next()){o.value.next(t)}}catch(t){e={error:t}}finally{try{o&&!o.done&&(n=r.return)&&n.call(r)}finally{if(e)throw e.error}}}}))},i.prototype.error=function(t){var i=this;(0,a.x)((function(){if(i.xt(),!i.isStopped){i.hasError=i.isStopped=!0,i.thrownError=t;for(var e=i.observers;e.length;)e.shift().error(t)}}))},i.prototype.complete=function(){var t=this;(0,a.x)((function(){if(t.xt(),!t.isStopped){t.isStopped=!0;for(var i=t.observers;i.length;)i.shift().complete()}}))},i.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(i.prototype,"observed",{get:function(){var t;return(null===(t=this.observers)||void 0===t?void 0:t.length)>0},enumerable:!1,configurable:!0}),i.prototype.Tt=function(i){return this.xt(),t.prototype.Tt.call(this,i)},i.prototype._t=function(t){return this.xt(),this.Ot(t),this.Rt(t)},i.prototype.Rt=function(t){var i=this,e=this,s=e.hasError,n=e.isStopped,o=e.observers;return s||n?r.Lc:(this.currentObservers=null,o.push(t),new r.w0((function(){i.currentObservers=null,(0,h.P)(o,t)})))},i.prototype.Ot=function(t){var i=this,e=i.hasError,s=i.thrownError,n=i.isStopped;e?t.error(s):n&&t.complete()},i.prototype.asObservable=function(){var t=new n.y;return t.source=this,t},i.create=function(t,i){return new d(t,i)},i}(n.y),d=function(t){function i(i,e){var s=t.call(this)||this;return s.destination=i,s.source=e,s}return(0,s.ZT)(i,t),i.prototype.next=function(t){var i,e;null===(e=null===(i=this.destination)||void 0===i?void 0:i.next)||void 0===e||e.call(i,t)},i.prototype.error=function(t){var i,e;null===(e=null===(i=this.destination)||void 0===i?void 0:i.error)||void 0===e||e.call(i,t)},i.prototype.complete=function(){var t,i;null===(i=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===i||i.call(t)},i.prototype._t=function(t){var i,e;return null!==(e=null===(i=this.source)||void 0===i?void 0:i.subscribe(t))&&void 0!==e?e:r.Lc},i}(c)},5642:(t,i,e)=>{"use strict";e.d(i,{Hp:()=>v,Lv:()=>p});var s=e(655),n=e(8474),r=e(5720),o=e(3912),h=e(5);function a(){}var c=d("C",void 0,void 0);function d(t,i,e){return{kind:t,value:i,error:e}}var l=e(8380),u=e(8846),p=function(t){function i(i){var e=t.call(this)||this;return e.isStopped=!1,i?(e.destination=i,(0,r.Nn)(i)&&i.add(e)):e.destination=I,e}return(0,s.ZT)(i,t),i.create=function(t,i,e){return new v(t,i,e)},i.prototype.next=function(t){this.isStopped?b(function(t){return d("N",t,void 0)}(t),this):this.Dt(t)},i.prototype.error=function(t){this.isStopped?b(d("E",void 0,t),this):(this.isStopped=!0,this.Vt(t))},i.prototype.complete=function(){this.isStopped?b(c,this):(this.isStopped=!0,this.Nt())},i.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,t.prototype.unsubscribe.call(this),this.destination=null)},i.prototype.Dt=function(t){this.destination.next(t)},i.prototype.Vt=function(t){try{this.destination.error(t)}finally{this.unsubscribe()}},i.prototype.Nt=function(){try{this.destination.complete()}finally{this.unsubscribe()}},i}(r.w0),f=Function.prototype.bind;function m(t,i){return f.call(t,i)}var g=function(){function t(t){this.partialObserver=t}return t.prototype.next=function(t){var i=this.partialObserver;if(i.next)try{i.next(t)}catch(t){y(t)}},t.prototype.error=function(t){var i=this.partialObserver;if(i.error)try{i.error(t)}catch(t){y(t)}else y(t)},t.prototype.complete=function(){var t=this.partialObserver;if(t.complete)try{t.complete()}catch(t){y(t)}},t}(),v=function(t){function i(i,e,s){var r,h,a=t.call(this)||this;(0,n.m)(i)||!i?r={next:null!=i?i:void 0,error:null!=e?e:void 0,complete:null!=s?s:void 0}:a&&o.v.useDeprecatedNextContext?((h=Object.create(i)).unsubscribe=function(){return a.unsubscribe()},r={next:i.next&&m(i.next,h),error:i.error&&m(i.error,h),complete:i.complete&&m(i.complete,h)}):r=i;return a.destination=new g(r),a}return(0,s.ZT)(i,t),i}(p);function y(t){o.v.useDeprecatedSynchronousErrorHandling?(0,u.O)(t):(0,h.h)(t)}function b(t,i){var e=o.v.onStoppedNotification;e&&l.z.setTimeout((function(){return e(t,i)}))}var I={closed:!0,next:a,error:function(t){throw t},complete:a}},5720:(t,i,e)=>{"use strict";e.d(i,{Lc:()=>a,w0:()=>h,Nn:()=>c});var s=e(655),n=e(8474),r=(0,e(1819).d)((function(t){return function(i){t(this),this.message=i?i.length+" errors occurred during unsubscription:\n"+i.map((function(t,i){return i+1+") "+t.toString()})).join("\n  "):"",this.name="UnsubscriptionError",this.errors=i}})),o=e(3699),h=function(){function t(t){this.initialTeardown=t,this.closed=!1,this.jt=null,this.$t=null}var i;return t.prototype.unsubscribe=function(){var t,i,e,o,h;if(!this.closed){this.closed=!0;var a=this.jt;if(a)if(this.jt=null,Array.isArray(a))try{for(var c=(0,s.XA)(a),l=c.next();!l.done;l=c.next()){l.value.remove(this)}}catch(i){t={error:i}}finally{try{l&&!l.done&&(i=c.return)&&i.call(c)}finally{if(t)throw t.error}}else a.remove(this);var u=this.initialTeardown;if((0,n.m)(u))try{u()}catch(t){h=t instanceof r?t.errors:[t]}var p=this.$t;if(p){this.$t=null;try{for(var f=(0,s.XA)(p),m=f.next();!m.done;m=f.next()){var g=m.value;try{d(g)}catch(t){h=null!=h?h:[],t instanceof r?h=(0,s.ev)((0,s.ev)([],(0,s.CR)(h)),(0,s.CR)(t.errors)):h.push(t)}}}catch(t){e={error:t}}finally{try{m&&!m.done&&(o=f.return)&&o.call(f)}finally{if(e)throw e.error}}}if(h)throw new r(h)}},t.prototype.add=function(i){var e;if(i&&i!==this)if(this.closed)d(i);else{if(i instanceof t){if(i.closed||i.Ut(this))return;i.zt(this)}(this.$t=null!==(e=this.$t)&&void 0!==e?e:[]).push(i)}},t.prototype.Ut=function(t){var i=this.jt;return i===t||Array.isArray(i)&&i.includes(t)},t.prototype.zt=function(t){var i=this.jt;this.jt=Array.isArray(i)?(i.push(t),i):i?[i,t]:t},t.prototype.Wt=function(t){var i=this.jt;i===t?this.jt=null:Array.isArray(i)&&(0,o.P)(i,t)},t.prototype.remove=function(i){var e=this.$t;e&&(0,o.P)(e,i),i instanceof t&&i.Wt(this)},t.EMPTY=((i=new t).closed=!0,i),t}(),a=h.EMPTY;function c(t){return t instanceof h||t&&"closed"in t&&(0,n.m)(t.remove)&&(0,n.m)(t.add)&&(0,n.m)(t.unsubscribe)}function d(t){(0,n.m)(t)?t():t.unsubscribe()}},3912:(t,i,e)=>{"use strict";e.d(i,{v:()=>s});var s={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1}},7878:(t,i,e)=>{"use strict";e.d(i,{Xf:()=>m});var s=e(655),n=e(5685),r=e(3841),o=e(1480),h=e(1764),a=e(8430),c=e(8729),d=e(1837),l=e(8671),u=e(8474),p=e(5),f=e(6766);function m(t){if(t instanceof o.y)return t;if(null!=t){if((0,h.c)(t))return y=t,new o.y((function(t){var i=y[f.L]();if((0,u.m)(i.subscribe))return i.subscribe(t);throw new TypeError("Provided object does not correctly implement Symbol.observable")}));if((0,n.z)(t))return v=t,new o.y((function(t){for(var i=0;i<v.length&&!t.closed;i++)t.next(v[i]);t.complete()}));if((0,r.t)(t))return m=t,new o.y((function(t){m.then((function(i){t.closed||(t.next(i),t.complete())}),(function(i){return t.error(i)})).then(null,p.h)}));if((0,a.D)(t))return g(t);if((0,d.T)(t))return e=t,new o.y((function(t){var i,n;try{for(var r=(0,s.XA)(e),o=r.next();!o.done;o=r.next()){var h=o.value;if(t.next(h),t.closed)return}}catch(t){i={error:t}}finally{try{o&&!o.done&&(n=r.return)&&n.call(r)}finally{if(i)throw i.error}}t.complete()}));if((0,l.L)(t))return i=t,g((0,l.Q)(i))}var i,e,m,v,y;throw(0,c.z)(t)}function g(t){return new o.y((function(i){(function(t,i){var e,n,r,o;return(0,s.mG)(this,void 0,void 0,(function(){var h,a;return(0,s.Jh)(this,(function(c){switch(c.label){case 0:c.trys.push([0,5,6,11]),e=(0,s.KL)(t),c.label=1;case 1:return[4,e.next()];case 2:if((n=c.sent()).done)return[3,4];if(h=n.value,i.next(h),i.closed)return[2];c.label=3;case 3:return[3,1];case 4:return[3,11];case 5:return a=c.sent(),r={error:a},[3,11];case 6:return c.trys.push([6,,9,10]),n&&!n.done&&(o=e.return)?[4,o.call(e)]:[3,8];case 7:c.sent(),c.label=8;case 8:return[3,10];case 9:if(r)throw r.error;return[7];case 10:return[7];case 11:return i.complete(),[2]}}))}))})(t,i).catch((function(t){return i.error(t)}))}))}},6196:(t,i,e)=>{"use strict";e.d(i,{H:()=>o});var s=e(1480),n=e(8843),r=e(4865);function o(t,i,e){void 0===t&&(t=0),void 0===e&&(e=n.P);var o=-1;return null!=i&&((0,r.K)(i)?e=i:o=i),new s.y((function(i){var s,n=(s=t)instanceof Date&&!isNaN(s)?+t-e.now():t;n<0&&(n=0);var r=0;return e.schedule((function(){i.closed||(i.next(r++),0<=o?this.schedule(void 0,o):i.complete())}),n)}))}},2566:(t,i,e)=>{"use strict";e.d(i,{x:()=>n});var s=e(655);function n(t,i,e,s,n){return new r(t,i,e,s,n)}var r=function(t){function i(i,e,s,n,r,o){var h=t.call(this,i)||this;return h.onFinalize=r,h.shouldUnsubscribe=o,h.Dt=e?function(t){try{e(t)}catch(t){i.error(t)}}:t.prototype.Dt,h.Vt=n?function(t){try{n(t)}catch(t){i.error(t)}finally{this.unsubscribe()}}:t.prototype.Vt,h.Nt=s?function(){try{s()}catch(t){i.error(t)}finally{this.unsubscribe()}}:t.prototype.Nt,h}return(0,s.ZT)(i,t),i.prototype.unsubscribe=function(){var i;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){var e=this.closed;t.prototype.unsubscribe.call(this),!e&&(null===(i=this.onFinalize)||void 0===i||i.call(this))}},i}(e(5642).Lv)},4975:(t,i,e)=>{"use strict";e.d(i,{h:()=>r});var s=e(6798),n=e(2566);function r(t,i){return(0,s.e)((function(e,s){var r=0;e.subscribe((0,n.x)(s,(function(e){return t.call(i,e,r++)&&s.next(e)})))}))}},4978:(t,i,e)=>{"use strict";e.d(i,{w:()=>o});var s=e(7878),n=e(6798),r=e(2566);function o(t,i){return(0,n.e)((function(e,n){var o=null,h=0,a=!1,c=function(){return a&&!o&&n.complete()};e.subscribe((0,r.x)(n,(function(e){null==o||o.unsubscribe();var a=0,d=h++;(0,s.Xf)(t(e,d)).subscribe(o=(0,r.x)(n,(function(t){return n.next(i?i(e,t,d,a++):t)}),(function(){o=null,c()})))}),(function(){a=!0,c()})))}))}},89:(t,i,e)=>{"use strict";e.d(i,{q:()=>o});var s=new(e(1480).y)((function(t){return t.complete()}));var n=e(6798),r=e(2566);function o(t){return t<=0?function(){return s}:(0,n.e)((function(i,e){var s=0;i.subscribe((0,r.x)(e,(function(i){++s<=t&&(e.next(i),t<=s&&e.complete())})))}))}},8843:(t,i,e)=>{"use strict";e.d(i,{P:()=>l,z:()=>d});var s=e(655),n=function(t){function i(i,e){return t.call(this)||this}return(0,s.ZT)(i,t),i.prototype.schedule=function(t,i){return void 0===i&&(i=0),this},i}(e(5720).w0),r={setInterval:function(t,i){for(var e=[],n=2;n<arguments.length;n++)e[n-2]=arguments[n];var o=r.delegate;return(null==o?void 0:o.setInterval)?o.setInterval.apply(o,(0,s.ev)([t,i],(0,s.CR)(e))):setInterval.apply(void 0,(0,s.ev)([t,i],(0,s.CR)(e)))},clearInterval:function(t){var i=r.delegate;return((null==i?void 0:i.clearInterval)||clearInterval)(t)},delegate:void 0},o=e(3699),h=function(t){function i(i,e){var s=t.call(this,i,e)||this;return s.scheduler=i,s.work=e,s.pending=!1,s}return(0,s.ZT)(i,t),i.prototype.schedule=function(t,i){var e;if(void 0===i&&(i=0),this.closed)return this;this.state=t;var s=this.id,n=this.scheduler;return null!=s&&(this.id=this.recycleAsyncId(n,s,i)),this.pending=!0,this.delay=i,this.id=null!==(e=this.id)&&void 0!==e?e:this.requestAsyncId(n,this.id,i),this},i.prototype.requestAsyncId=function(t,i,e){return void 0===e&&(e=0),r.setInterval(t.flush.bind(t,this),e)},i.prototype.recycleAsyncId=function(t,i,e){if(void 0===e&&(e=0),null!=e&&this.delay===e&&!1===this.pending)return i;null!=i&&r.clearInterval(i)},i.prototype.execute=function(t,i){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;var e=this.Gt(t,i);if(e)return e;!1===this.pending&&null!=this.id&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))},i.prototype.Gt=function(t,i){var e,s=!1;try{this.work(t)}catch(t){s=!0,e=t||new Error("Scheduled action threw falsy error")}if(s)return this.unsubscribe(),e},i.prototype.unsubscribe=function(){if(!this.closed){var i=this.id,e=this.scheduler,s=e.actions;this.work=this.state=this.scheduler=null,this.pending=!1,(0,o.P)(s,this),null!=i&&(this.id=this.recycleAsyncId(e,i,null)),this.delay=null,t.prototype.unsubscribe.call(this)}},i}(n),a=e(4318),c=function(){function t(i,e){void 0===e&&(e=t.now),this.schedulerActionCtor=i,this.now=e}return t.prototype.schedule=function(t,i,e){return void 0===i&&(i=0),new this.schedulerActionCtor(this,t).schedule(e,i)},t.now=a.l.now,t}(),d=new(function(t){function i(i,e){void 0===e&&(e=c.now);var s=t.call(this,i,e)||this;return s.actions=[],s.Xt=!1,s}return(0,s.ZT)(i,t),i.prototype.flush=function(t){var i=this.actions;if(this.Xt)i.push(t);else{var e;this.Xt=!0;do{if(e=t.execute(t.state,t.delay))break}while(t=i.shift());if(this.Xt=!1,e){for(;t=i.shift();)t.unsubscribe();throw e}}},i}(c))(h),l=d},4318:(t,i,e)=>{"use strict";e.d(i,{l:()=>s});var s={now:function(){return(s.delegate||Date).now()},delegate:void 0}},8380:(t,i,e)=>{"use strict";e.d(i,{z:()=>n});var s=e(655),n={setTimeout:function(t,i){for(var e=[],r=2;r<arguments.length;r++)e[r-2]=arguments[r];var o=n.delegate;return(null==o?void 0:o.setTimeout)?o.setTimeout.apply(o,(0,s.ev)([t,i],(0,s.CR)(e))):setTimeout.apply(void 0,(0,s.ev)([t,i],(0,s.CR)(e)))},clearTimeout:function(t){var i=n.delegate;return((null==i?void 0:i.clearTimeout)||clearTimeout)(t)},delegate:void 0}},9768:(t,i,e)=>{"use strict";e.d(i,{h:()=>s});var s="function"==typeof Symbol&&Symbol.iterator?Symbol.iterator:"@@iterator"},6766:(t,i,e)=>{"use strict";e.d(i,{L:()=>s});var s="function"==typeof Symbol&&Symbol.observable||"@@observable"},3699:(t,i,e)=>{"use strict";function s(t,i){if(t){var e=t.indexOf(i);0<=e&&t.splice(e,1)}}e.d(i,{P:()=>s})},1819:(t,i,e)=>{"use strict";function s(t){var i=t((function(t){Error.call(t),t.stack=(new Error).stack}));return i.prototype=Object.create(Error.prototype),i.prototype.constructor=i,i}e.d(i,{d:()=>s})},8846:(t,i,e)=>{"use strict";e.d(i,{O:()=>o,x:()=>r});var s=e(3912),n=null;function r(t){if(s.v.useDeprecatedSynchronousErrorHandling){var i=!n;if(i&&(n={errorThrown:!1,error:null}),t(),i){var e=n,r=e.errorThrown,o=e.error;if(n=null,r)throw o}}else t()}function o(t){s.v.useDeprecatedSynchronousErrorHandling&&n&&(n.errorThrown=!0,n.error=t)}},278:(t,i,e)=>{"use strict";function s(t){return t}e.d(i,{y:()=>s})},5685:(t,i,e)=>{"use strict";e.d(i,{z:()=>s});var s=function(t){return t&&"number"==typeof t.length&&"function"!=typeof t}},8430:(t,i,e)=>{"use strict";e.d(i,{D:()=>n});var s=e(8474);function n(t){return Symbol.asyncIterator&&(0,s.m)(null==t?void 0:t[Symbol.asyncIterator])}},8474:(t,i,e)=>{"use strict";function s(t){return"function"==typeof t}e.d(i,{m:()=>s})},1764:(t,i,e)=>{"use strict";e.d(i,{c:()=>r});var s=e(6766),n=e(8474);function r(t){return(0,n.m)(t[s.L])}},1837:(t,i,e)=>{"use strict";e.d(i,{T:()=>r});var s=e(9768),n=e(8474);function r(t){return(0,n.m)(null==t?void 0:t[s.h])}},3841:(t,i,e)=>{"use strict";e.d(i,{t:()=>n});var s=e(8474);function n(t){return(0,s.m)(null==t?void 0:t.then)}},8671:(t,i,e)=>{"use strict";e.d(i,{L:()=>o,Q:()=>r});var s=e(655),n=e(8474);function r(t){return(0,s.FC)(this,arguments,(function(){var i,e,n;return(0,s.Jh)(this,(function(r){switch(r.label){case 0:i=t.getReader(),r.label=1;case 1:r.trys.push([1,,9,10]),r.label=2;case 2:return[4,(0,s.qq)(i.read())];case 3:return e=r.sent(),n=e.value,e.done?[4,(0,s.qq)(void 0)]:[3,5];case 4:return[2,r.sent()];case 5:return[4,(0,s.qq)(n)];case 6:return[4,r.sent()];case 7:return r.sent(),[3,2];case 8:return[3,10];case 9:return i.releaseLock(),[7];case 10:return[2]}}))}))}function o(t){return(0,n.m)(null==t?void 0:t.getReader)}},4865:(t,i,e)=>{"use strict";e.d(i,{K:()=>n});var s=e(8474);function n(t){return t&&(0,s.m)(t.schedule)}},6798:(t,i,e)=>{"use strict";e.d(i,{e:()=>n});var s=e(8474);function n(t){return function(i){if(function(t){return(0,s.m)(null==t?void 0:t.lift)}(i))return i.lift((function(i){try{return t(i,this)}catch(t){this.error(t)}}));throw new TypeError("Unable to lift unknown Observable type")}}},5:(t,i,e)=>{"use strict";e.d(i,{h:()=>r});var s=e(3912),n=e(8380);function r(t){n.z.setTimeout((function(){var i=s.v.onUnhandledError;if(!i)throw t;i(t)}))}},8729:(t,i,e)=>{"use strict";function s(t){return new TypeError("You provided "+(null!==t&&"object"==typeof t?"an invalid object":"'"+t+"'")+" where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.")}e.d(i,{z:()=>s})},9613:(t,i,e)=>{"use strict";var s,n,r,o;e.d(i,{Ek:()=>r,lc:()=>s,gx:()=>n,aB:()=>o}),function(t){t.ShowLinearEvent="showLinearEvent",t.HideLinearEvent="hideLinearEvent",t.PauseLinearEvent="pauseLinearEvent",t.ResumeLinearEvent="resumeLinearEvent",t.SkipLinearEvent="skipLinearEvent"}(s||(s={})),function(t){t.ShowNonLinearEvent="showNonLinearEvent",t.HideNonLinearEvent="hideNonLinearEvent"}(n||(n={})),function(t){t.InPod="cnx-ad-in-pod",t.AdMarkerInPodTextContainer="cnx-ad-marker-text",t.AdDurationLabel="cnx-ad-duration",t.AdTitleLabel="cnx-ad-title",t.AdMarkerTitleContainer="cnx-ad-marker-title",t.AdMarkerTitleText="cnx-ad-title-text",t.CardImage="cnx-ad-card-image",t.CardTitle="cnx-ad-card-title",t.AdUiContent="cnx-ui-ad-content",t.InAd="cnx-ui-ad"}(r||(r={})),function(t){t.ForceStopAdSlot="forceStopAdSlot",t.ForceStopAdPod="forceStopAdPod",t.ChangeVideo="changeVideo"}(o||(o={}))},8532:(t,i,e)=>{"use strict";e.d(i,{Km:()=>o,Zr:()=>n,jJ:()=>r,n9:()=>h,q0:()=>s});const s={Play:"play",Pause:"pause",QualityChanged:"qualityChanged",PlayError:"playError",VolumeChanged:"volumeChanged"},n={FullscreenChanged:"fullscreenChanged",PlayerFloatChanged:"playerFloatChanged",FloatingEnterStart:"floatingEnterStart",FloatingEnterStop:"floatingEnterStop",FloatingExitStart:"floatingExitStart",FloatingExitStop:"floatingExitStop",CloseButtonClicked:"closeButtonClicked"},r={OmidViewabilityThreshold:"OmidViewabilityThreshold",OmidAdSessionStart:"omidAdSessionStart",OmidAdSessionFinish:"omidAdSessionFinish"},o=Object.assign(Object.assign(Object.assign(Object.assign({Ready:"ready",Removed:"removed",SetupError:"setupError",IsViewable:"isViewable",SizeChanged:"sizeChanged",BrandingClicked:"brandingClicked",ImpressionPrice:"impressionPrice",ImpressionRevenue:"impressionRevenue",Bid:"bid",PrefetchStart:"prefetchStart"},s),n),r),{AdLoaded:"adLoaded",AdStarted:"adStarted",AdClick:"adClick",AdPlay:"adPlay",AdPause:"adPause",AdImpression:"adImpression",AdCompleted25:"adCompleted25",AdCompleted50:"adCompleted50",AdCompleted75:"adCompleted75",AdCompleted100:"adCompleted100",AdVolumeChange:"adVolumeChange",AdSkipped:"adSkipped",AdError:"adError",AdStopped:"adStopped",AdCompanion:"adCompanion"});var h;!function(t){t.SetupError="SetupError",t.NoPlayer="NoPlayer",t.RenderError="RenderError",t.InvalidGUID="InvalidGUID"}(h||(h={}))},8576:(t,i,e)=>{"use strict";var s,n,r,o,h;e.d(i,{FX:()=>r,Ht:()=>a,Oc:()=>h,_S:()=>o,bS:()=>c,do:()=>n,lI:()=>s}),function(t){t.Chrome="chrome",t.Firefox="firefox",t.Edge="edge",t.Safari="safari",t.Opera="opera",t.Samsung="samsung",t.Facebook="facebook",t.InternetExplorer="ie"}(s||(s={})),function(t){t.Standard="standard",t.Webkit="webkit",t.Moz="moz",t.Ms="ms",t.O="o"}(n||(n={})),function(t){t[t.UNKNOWN=0]="UNKNOWN",t[t.ETHERNET=1]="ETHERNET",t[t.WIFI=2]="WIFI",t[t.CELLULAR_UNKNOWN=3]="CELLULAR_UNKNOWN",t[t.CELLULAR_2G=4]="CELLULAR_2G",t[t.CELLULAR_3G=5]="CELLULAR_3G",t[t.CELLULAR_4G=6]="CELLULAR_4G",t[t.CELLULAR_5G=7]="CELLULAR_5G"}(r||(r={})),function(t){t.ETHERNET="ethernet",t.WIFI="wifi",t.CELLULAR="cellular"}(o||(o={})),function(t){t.CELLULAR_SLOW_2G="slow-2g",t.CELLULAR_2G="2g",t.CELLULAR_3G="3g",t.CELLULAR_4G="4g"}(h||(h={}));const a=[{name:n.Standard,keys:{fullscreenEnabled:"fullscreenEnabled",fullscreenElement:"fullscreenElement",requestFullscreen:"requestFullscreen",exitFullscreen:"exitFullscreen",fullscreenchange:"fullscreenchange",fullscreenerror:"fullscreenerror"}},{name:n.Webkit,keys:{fullscreenEnabled:"webkitFullscreenEnabled",fullscreenElement:"webkitFullscreenElement",requestFullscreen:"webkitRequestFullscreen",exitFullscreen:"webkitExitFullscreen",fullscreenchange:"webkitfullscreenchange",fullscreenerror:"webkitfullscreenerror"}},{name:n.Webkit,keys:{fullscreenEnabled:"webkitSupportsFullscreen",fullscreenElement:"webkitFullscreenElement",requestFullscreen:"webkitEnterFullscreen",exitFullscreen:"webkitExitFullscreen",fullscreenchange:"webkitfullscreenchange",fullscreenerror:"webkitfullscreenerror"}},{name:n.Moz,keys:{fullscreenEnabled:"mozFullScreenEnabled",fullscreenElement:"mozFullScreenElement",requestFullscreen:"mozRequestFullScreen",exitFullscreen:"mozCancelFullScreen",fullscreenchange:"mozfullscreenchange",fullscreenerror:"mozfullscreenerror"}},{name:n.Ms,keys:{fullscreenEnabled:"msFullscreenEnabled",fullscreenElement:"msFullscreenElement",requestFullscreen:"msRequestFullscreen",exitFullscreen:"msExitFullscreen",fullscreenchange:"MSFullscreenChange",fullscreenerror:"MSFullscreenError"}}];var c;!function(t){t.Self="_self",t.Blank="_blank",t.Parent="_parent",t.Top="_top"}(c||(c={}))},8983:(t,i,e)=>{"use strict";e.d(i,{Gj:()=>s,Hs:()=>P,Ig:()=>c,Ih:()=>b,Ng:()=>d,Nq:()=>a,QO:()=>p,Rp:()=>x,Rq:()=>h,Yk:()=>f,_7:()=>m,hQ:()=>y,iu:()=>l,jG:()=>g,mr:()=>A,oV:()=>w,p0:()=>_,pT:()=>S,s6:()=>n,sN:()=>I,s_:()=>r});var s,n,r,o=e(1988);!function(t){t.Invisible="cnx-mod-invisible",t.HovarableButton="cnx-ui-btn-hoverable",t.HoverStart="cnx-mod-hover-s",t.HoverEnd="cnx-mod-hover",t.HoverBoom="cnx-mod-boom",t.DisplayNone="cnx-mod-display-none",t.Active="cnx-mod-active",t.HideOnVolumeHover="cnx-hide-on-volume-hover",t.HideOnSingleVideo="cnx-hide-on-single-video",t.NoTransition="cnx-mod-no-transition",t.Collapsable="cnx-mod-collapsable",t.HasCustomScrollbar="cnx-mod-scrollbar",t.Show="cnx-mod-show",t.Hide="cnx-mod-hide",t.NoHeight="cnx-mod-no-height",t.OnHold="cnx-mod-onhold",t.ForceLineBreak="cnx-mod-force-line-break",t.HideOnAdOverlay="cnx-mod-ad-overlay-none",t.HideOnPodLoadingScreen="cnx-mod-pod-loading-none"}(s||(s={})),function(t){t.Fullscreen="cnx-in-fullscreen",t.Ad="cnx-in-ad",t.AdNonLinear="cnx-in-ad-non-linear",t.AdOverlayType="cnx-in-ad-overlay",t.AdFullSize="cnx-in-ad-full",t.AdShowCard="cnx-ad-show-card",t.ShowControls="cnx-in-show-controls",t.Mobile="cnx-in-mobile",t.Desktop="cnx-in-desktop",t.Muted="cnx-in-mute",t.Collapsed="cnx-in-collapse",t.GalleryPortrait="cnx-in-g-portrait",t.GalleryLandscape="cnx-in-g-landscape",t.ContextController="cnx-context-controller",t.HideUI="cnx-in-hide-ui",t.PodLoadingScreen="cnx-in-pod-loading",t.AdShowCountdown="cnx-ad-show-countdown",t.CloseOn="cnx-close-on",t.CloseOff="cnx-close-off",t.CloseHover="cnx-close-hover",t.CloseFloatOn="cnx-close-float-on",t.CloseFloatOff="cnx-close-float-off",t.CloseFloatHover="cnx-close-float-hover",t.UiInView="cnx-ui-in-view",t.ClickToPlayThumbnail="cnx-click-to-play-thumbnail",t.VideoWrapper="cnx-video-wrapper",t.PlayerFocused="cnx-focused",t.TabFocus="cnx-tab-focus",t.AdUserInteraction="cnx-ad-user-interaction",t.BottomButtonsContainer="cnx-ui-buttons",t.HeadButtonsContainer="cnx-ui-head-buttons",t.MuteWatermark="cnx-mute-watermark"}(n||(n={})),function(t){t.Playing="cnx-is-playing",t.Paused="cnx-is-paused",t.Stopped="cnx-is-stopped",t.Preroll="cnx-is-preroll",t.Postroll="cnx-is-postroll",t.Loading="cnx-is-loading",t.LiveEnded="cnx-live-ended"}(r||(r={}));const h={Xxl:"cnx-bp-xxl-v",Xl:"cnx-bp-xl-v",Lg:"cnx-bp-lg-v",Md:"cnx-bp-md-v",Sm:"cnx-bp-sm-v",Xs:"cnx-bp-xs-v",Xxs:"cnx-bp-xxs-v"},a={Xxl:"",Xl:o.Z.XL,Lg:o.Z.LG,Md:o.Z.MD,Sm:o.Z.SM,Xs:o.Z.XS,Xxs:""};var c,d,l,u,p,f,m;!function(t){t.Responsive="cnx-size-responsive",t.Fixed="cnx-size-fixed"}(c||(c={})),function(t){t.ClickOption="cnx-cm-item--click",t.ToggleOption="cnx-cm-item--toggle",t.SubmenuOption="cnx-cm-item--submenu",t.ItemIcon="cnx-cm-item__icon",t.ItemTitle="cnx-cm-item__title",t.ItemExtra="cnx-cm-item__extra",t.Items="cnx-cm-items",t.Container="cnx-cm-container"}(d||(d={})),function(t){t.Icons="cnx-color-icon",t.TooltipText="cnx-color-tt-text",t.TooltipBackground="cnx-color-tt-bg",t.AccentColor="cnx-color-accent",t.PrimaryColor="cnx-color-primary",t.SecondaryColor="cnx-color-secondary",t.TitleComponent="cnx-title-component",t.TitleLink="cnx-color-title-link",t.SlideProgressBar="cnx-slides-progress-bar",t.ProgressFill="cnx-progress-fill"}(l||(l={})),function(t){t.InheritTitleFontFamily="cnx-inherit-title-font-family",t.InheritBodyFontFamily="cnx-inherit-body-font-family"}(u||(u={})),function(t){t.Connatix="#0099FF",t.Icons="#FFFFFF",t.PrimaryBackground="#F1F1F1",t.PrimaryForeground="#000000",t.SecondaryBackground="#000000",t.SecondaryForeground="#F1F1F1",t.AccentForeground="#FFFFFF"}(p||(p={})),function(t){t.CaptionContainer="cnx-captions-text-holder"}(f||(f={})),function(t){t.MainClass="cnx-float",t.TransitionClass="cnx-float-transition",t.InstantTransitionClass="cnx-float-instant-transition",t.AlwaysFloating="cnx-always-floating",t.PinnedTopFloating="cnx-pinned-top-floating",t.PinnedFloating="cnx-pinned",t.PinnedBottomFloating="cnx-pinned-bottom-floating",t.PinnedWrapper="cnx-pinned-wrapper",t.ContentWrapper="cnx-content-wrapper",t.HidePinnedTitle="cnx-hide-pinned-title-in-ad"}(m||(m={}));const g={FadeOutBase:"cnx-fade-out-base",FadeOut:"cnx-fade-out",FadeInBase:"cnx-fade-in-base",FadeIn:"cnx-fade-in"};var v,y,b;!function(t){t.CurrentSlide="cnx-slide-current",t.NextSlide="cnx-slide-next",t.SlideLeft="cnx-slide-left",t.SlideRight="cnx-slide-right"}(v||(v={})),function(t){t.OpacityInTransition="cnx-tooltip-animation-in"}(y||(y={})),function(t){t.Card="cnx-g-card",t.CardSlot="cnx-g-card-slot",t.CardImage="cnx-g-card-image",t.CardText="cnx-g-card-text",t.CardTextContainer="cnx-g-card-text-container",t.CardPlaceholder="cnx-g-card-placeholder",t.CardRail="cnx-g-rail",t.StyleDetailed="cnx-g-style-detailed",t.StyleVisual="cnx-g-style-visual",t.ExploreMore="cnx-g-explore-more",t.FadeOut="cnx-g-fade-out"}(b||(b={}));const I={MainContainer:"cnx-main-container",MainContainerFlex:"cnx-main-container-flex",PlayerWrapper:"cnx-player-wrapper",ImagePlaceholder:"cnx-image-placeholder"},w="cnx-ratio",S="cnx-hide-video",P={Text:"cnx-skip-ad-text",Timer:"cnx-timer-loader",Icon:"cnx-skip-ad-icon",SkipAdButton:"cnx-skip-ad-button",InTimer:"cnx-skip-ad-in-timer"},A={Icon:"cnx-pod-open-new-icon",Button:"cnx-pod-read-more-btn",ButtonContainer:"cnx-pod-read-more-container",Wrapper:"cnx-pod-read-more-wrapper",BackgroundImg:"cnx-pod-loading-background",InfoContainer:"cnx-pod-loading-info",FallbackContainer:"cnx-pod-loading-fallback",SlotCountText:"cnx-pod-slot-count-text"},_={CloseButton:"cnx-ad-close-non-linear-button"},x={Wrapper:"cnx-a11y-status"}},3775:(t,i,e)=>{"use strict";var s;e.d(i,{b:()=>s}),function(t){t.GarbageCollector="data-cnx-gc",t.ContextMenuSettings="cnx-ui-cm-settings"}(s||(s={}))},7945:(t,i,e)=>{"use strict";e.d(i,{g:()=>s,x:()=>n});const s=JSON.parse('{"version":269000,"domainPrefix":"","logToConsole":false,"logToServer":true,"env":"production"}'),n=!0},5227:(t,i,e)=>{"use strict";var s,n;e.d(i,{Uh:()=>n,Xh:()=>s,dP:()=>r}),function(t){t.SessionRendered="rendered",t.SessionView="enter_view"}(s||(s={})),function(t){t.UserInteraction="userInteraction",t.GeneralUserInteraction="generalUserInteraction",t.CanStart="canStart",t.Destroy="destroy"}(n||(n={}));const r={StateChanged:"stateChanged"}},4581:(t,i,e)=>{"use strict";e.d(i,{x:()=>s});const s="//securepubads.g.doubleclick.net/tag/js/gpt.js"},9022:(t,i,e)=>{"use strict";e.d(i,{$b:()=>a,f3:()=>n,fJ:()=>o,kd:()=>h,xs:()=>r});var s=e(289);const n=31,r={[s.ProtoAdType.Video]:2e3,[s.ProtoAdType.Overlay]:1e3,[s.ProtoAdType.Nonlinear]:1e3},o=.5,h="connatix.com",a="Advertisement"},8211:(t,i,e)=>{"use strict";e.d(i,{M:()=>r,a:()=>n});var s=e(289);const n=[s.ProtoDeviceType.Smartphone,s.ProtoDeviceType.Tablet];var r;!function(t){t.Ios="ios",t.Android="android",t.Mac="macos",t.Windows="windows",t.Linux="linux",t.IPadOS="ipados"}(r||(r={}))},307:(t,i,e)=>{"use strict";e.d(i,{Fk:()=>n,Kp:()=>o,a8:()=>h,br:()=>s,cc:()=>r,ym:()=>a});const s="https://info.connatix.com/",n="v",r="tier",o="pid",h="sid",a="cid"},1509:(t,i,e)=>{"use strict";var s;e.d(i,{n:()=>s}),function(t){t[t.FirstQuartile=0]="FirstQuartile",t[t.SecondQuartile=1]="SecondQuartile",t[t.ThirdQuartile=2]="ThirdQuartile",t[t.FourthQuartile=3]="FourthQuartile"}(s||(s={}))},9357:(t,i,e)=>{"use strict";e.d(i,{T9:()=>s,Y0:()=>h,oG:()=>c,p7:()=>n,s_:()=>o,ti:()=>a,uD:()=>r});const s=/(\d\d):(\d\d):(\d\d)(\.(\d\d\d))?/,n=36e5,r=6e4,o=1e3,h=60,a=864e5,c=60},9490:(t,i,e)=>{"use strict";var s,n,r,o;e.d(i,{Ez:()=>r,L5:()=>o,Qg:()=>l,T$:()=>h,XQ:()=>a,ZH:()=>n,d0:()=>u,gQ:()=>d,se:()=>c,wB:()=>s}),function(t){t.Play="play",t.Playing="playing",t.Pause="pause",t.Mute="mute",t.Unmute="unmute",t.Canplay="canplay",t.Ended="ended",t.Timeupdate="timeupdate",t.Seeking="seeking",t.Seeked="seeked",t.Volumechange="volumechange",t.Durationchange="durationchange",t.Fullscreen="fullscreen",t.LoadedData="loadeddata",t.LoadedMetadata="loadedmetadata",t.Error="error",t.BufferProgress="progress"}(s||(s={})),function(t){t[t.Auto=0]="Auto",t[t.Strict=1]="Strict"}(n||(n={})),function(t){t[t.PlayingState=0]="PlayingState",t[t.PausedState=1]="PausedState",t[t.PrerollState=2]="PrerollState",t[t.PostrollState=3]="PostrollState",t[t.StoppedState=4]="StoppedState",t[t.ReplayState=5]="ReplayState",t[t.HiddenState=6]="HiddenState",t[t.BufferingState=7]="BufferingState",t[t.LiveStreamStarting=8]="LiveStreamStarting",t[t.LiveStreamEnded=9]="LiveStreamEnded",t[t.LiveStreamStopped=10]="LiveStreamStopped",t[t.LiveStreamNotSupported=11]="LiveStreamNotSupported",t[t.InCuePoint=12]="InCuePoint"}(r||(r={})),function(t){t.H264="h264",t.Hevc="hevc"}(o||(o={}));const h={PlayError:"playError",NewVideo:"newVideo",Buffering:"buffering",Buffered:"buffered",LevelSwitching:"levelSwitching",EndOfStream:"endOfStream",LiveStreamNotPlayable:"liveNotPlayable"},a={Change:"VideoQualityChanged",CurrentQuality:"CurrentQuality",Loaded:"QualityListLoaded"};var c;!function(t){t[t.Low144p=144]="Low144p",t[t.Low240p=240]="Low240p",t[t.Medium360p=360]="Medium360p",t[t.Medium480p=480]="Medium480p",t[t.High720p=720]="High720p",t[t.High1080p=1080]="High1080p"}(c||(c={}));const d=720,l=5e3,u={NewThumbnail:"NewThumbnail"}},6027:(t,i,e)=>{"use strict";e.d(i,{e:()=>h,j:()=>s});var s,n=e(9791);class r{}r.clientAb0=4,r.clientAb1=(0,n.Vm)([0,50,50]);class o{}o.clientAb0=4,o.clientAb1=(0,n.Vm)([0,50,50]),function(t){t[t.ElementsABService=0]="ElementsABService",t[t.PlayspaceABService=1]="PlayspaceABService"}(s||(s={}));class h{static get clientAb0(){return this.getABValueForKey("clientAb0")}static get clientAb1(){return this.getABValueForKey("clientAb1")}static getABValueForKey(t){return this.abServiceType===s.PlayspaceABService?o[t]:r[t]}static setClientAb0(t){if(this.abServiceType===s.PlayspaceABService)o.clientAb0=t;else r.clientAb0=t}static setClientAb1(t){if(this.abServiceType===s.PlayspaceABService)o.clientAb1=t;else r.clientAb1=t}}},2450:(t,i,e)=>{"use strict";e.d(i,{$:()=>a});const s="ats-liveramp-envelope-request";var n=e(289),r=e(9791),o=e(4798),h=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class a{static getEnvelopeFromParentAts(t){var i;return h(this,void 0,void 0,(function*(){if(!(null===(i=a.envelope)||void 0===i?void 0:i.envelope))try{const i=yield this.Qt(t);return(0,o.$K)(i)?void(a.envelope=JSON.parse(i)):void a.communicateViaPostMessage(t)}catch(t){}}))}static Qt(t){return h(this,void 0,void 0,(function*(){if(t.ats){try{return t.ats.retrieveEnvelope().then((t=>t))}catch(t){}return this.retrieveEnvelopeWithCallback(t)}}))}static retrieveEnvelopeWithCallback(t){return h(this,void 0,void 0,(function*(){try{return yield t.ats.retrieveEnvelope((t=>t))}catch(t){}}))}static communicateViaPostMessage(t){a.dispatchEnvelopeRequestEvent(t),a.addEnvelopeListener()}static dispatchEnvelopeRequestEvent(t){try{t.postMessage(s,"*")}catch(i){void 0!==t.contentWindow&&t.contentWindow.postMessage(s,"*")}}static receiveEnvelopeListener(t){t&&t.data&&"ats-liveramp-envelope-result"===t.data.message&&t.data.result&&(a.envelope=JSON.parse(t.data.result),window.removeEventListener("message",a.receiveEnvelopeListener))}static addEnvelopeListener(){window.addEventListener("message",a.receiveEnvelopeListener,!1)}static getEnvelopeWithConsent(t,i){return new Promise(((e,s)=>{i.isConsentConnatix()?a.getEnvelopeFromParentAts(t).then((()=>{var t;(null===(t=a.envelope)||void 0===t?void 0:t.envelope)?e(a.envelope.envelope):setTimeout((()=>s()),500)})):setTimeout((()=>s()),500)}))}static getEnvelope(t,i){return h(this,void 0,void 0,(function*(){yield(0,r.Up)((()=>a.getEnvelopeWithConsent(t,i))).catch((()=>{}))}))}static setEnvelopeStatus(t){a.envelopeStatus=t}static getValidEnvelope(){var t;return(null===(t=a.envelope)||void 0===t?void 0:t.envelope)&&a.envelopeStatus===n.LiveRampEnvelopeStatusEnum.Ok?a.envelope.envelope:null}static wasRequestEnhanced(t){var i;return(null===(i=a.envelope)||void 0===i?void 0:i.envelope)&&t===n.LiveRampEnvelopeStatusEnum.Ok}static destroy(){a.envelope=null}}a.envelope=null,a.envelopeStatus=n.LiveRampEnvelopeStatusEnum.Ok},9710:(t,i,e)=>{"use strict";e.d(i,{_:()=>d});var s=e(4581);const n=["adBanner","banner-search","abc_banner","Banner_Top","ad_container","pub_300x250","pub_300x250m","pub_728x90","text-ad","text_ad","textAd","text-ad-links","text_ads","text-ads","text-ad-links"],r="cnxtestadblock";var o=e(3020),h=e(9791),a=e(4798),c=e(3);class d{static get isBannerBlocked(){return this.Jt}static onAdBlockerDetected(){return this.Yt.asObservable()}static detectUsingCSS(t){try{let i=!1;t.document.body.insertAdjacentHTML("beforeend",this.Kt(t));const e=t.document.getElementById(r);return 0!==e.getBoundingClientRect().height&&0!==e.getBoundingClientRect().width||(i=!0),t.document.body.removeChild(e),this.Zt(i),i}catch(t){return this.Zt(!1),!1}}static detectUsingScript(){return new Promise((t=>{const i=(0,h.pE)(window).topFrame,e=i=>{this.Yt.next(i),this.Yt.complete(),t(i)},n=()=>(0,a.QM)(i.googletag.getVersion())?e(!1):e(!0);i.googletag&&e(!1),(0,o.dZ)({src:s.x},i.document.head,i,(()=>{var t;return i.googletag?null===(t=i.googletag.cmd)||void 0===t?void 0:t.push(n):e(!0)}),(()=>e(!0)))}))}static Zt(t){this.Jt=t,this.Jt&&(this.Yt.next(!0),this.Yt.complete())}static Kt(t){const i=t.location.hostname.toLowerCase().indexOf("aljazeera.net")>-1;let e=[...n];i&&(e=e.filter((t=>"text-ads"!==t&&"text-ad-links"!==t)));const s=e.join(" ");return`<style>.adBanner{background-color: transparent; height: 1px !important; width: 1px !important; position: absolute !important; left: -10000px !important; top: -1000px !important; display:block !important; }</style><div id="${r}" class="${s}"></div>`}}d.Jt=null,d.Yt=new c.t(1)},7129:(t,i,e)=>{"use strict";var s;!function(t){t.prebid="prebid",t.bid="bid",t.win="win",t.impression="impression",t.viewableImpression="viewableImpression",t.postbid="postbid",t.initAd="initAd",t.request="request",t.startAd="startAd",t.adVerification="adVerification"}(s||(s={}))},9741:(t,i,e)=>{"use strict";e.d(i,{S:()=>s});class s{}s.MaxLogOverflow=1e3,s.maxLogOverflowCount={},s.logCount={},s.maxLogSent={},s.sessionId="",s.playerDestroyed=!1,s.incrementLogCount=t=>{s.logCount[t]?(++s.maxLogOverflowCount[t],++s.logCount[t]):(s.logCount[t]=1,s.maxLogOverflowCount[t]=1)},s.isMaxLog=(t,i)=>!!(s.logCount[t]&&s.logCount[t]>i),s.isMaxLogOverflow=t=>s.maxLogOverflowCount[t]>s.MaxLogOverflow&&(s.maxLogOverflowCount[t]=1,!0),s.setMaxLogSent=t=>{s.maxLogSent[t]=!0},s.isMaxLogSent=t=>!!s.maxLogSent[t]},5742:(t,i,e)=>{"use strict";e.d(i,{f:()=>n});var s=e(307);class n{static getCidKeyValueObject(){return!!this.customerId&&{[s.ym]:this.customerId}}static getCidForElkTracking(){return this.customerId?this.customerId:""}}n.customerId=null},8395:(t,i,e)=>{"use strict";e.d(i,{f:()=>d});var s=e(1187),n=e(8843),r=e(6196);var o,h=e(8659),a=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o},c=function(t,i){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,i)};let d=o=class{constructor(){var t,i;this.ii=new Map,this.ei=0,this.si=(void 0===(t=o.TIME_BETWEEN_TICKS)&&(t=0),void 0===i&&(i=n.z),t<0&&(t=0),(0,r.H)(t,t,i)),this.si.subscribe((()=>this.ni()))}setTimeout(t,i=0){return this.oi(t,i,!0)}clearTimeout(t){this.ii.delete(t)}setInterval(t,i=0){return this.oi(t,i,!1)}clearInterval(t){this.ii.delete(t)}ai(t){try{t.callback()}catch(t){(0,s.n)({message:"TimerService_error",callStack:t.stack,exception:t.message,level:s.D.INFO},{throttle:1})}}ni(){const t=(new Date).getTime(),i=[];for(const[e,s]of this.ii)t-s.startTime<s.duration*(s.intervalTimesCalled+1)||(this.ai(s),s.isTimeout?i.push(e):s.intervalTimesCalled++);for(const t of i)this.ii.delete(t)}oi(t,i,e){const s=++this.ei;return this.ii.set(s,{startTime:(new Date).getTime(),isTimeout:e,callback:t,duration:i,intervalTimesCalled:0}),s}};d.TIME_BETWEEN_TICKS=100,d=o=a([(0,h.ri)(),c("design:paramtypes",[])],d)},5935:(t,i,e)=>{"use strict";e.d(i,{X:()=>c});var s=e(8211),n=e(9791),r=e(8576),o=e(51),h=e(4798),a=e(3802);class c{constructor(t){this.ci=t,this.di=100,this.li=(0,n.pE)(window).topFrame,this.ui=s.a.indexOf(this.ci.browser.device)>-1,this.pi=(0,n.dz)(),this.fi={browserType:this.mi(),browserVersion:this.ci.browser.browserVersion},this.gi=this.vi(),this.yi=a.EN.fromProtoGetDeviceType(this.ci.browser.device),this.bi=this.pageUrl.substr(0,this.di),this.Ii=(0,o.ge)(this.bi),this.wi=(0,o.FM)(this.bi)}mi(){let t;return Object.keys(r.lI).forEach((i=>{this.ci.browser.browserType.toLowerCase().includes(r.lI[i])&&(t=r.lI[i])})),t}vi(){let t,i=0;const e=this.ci.browser.osCode.split("_"),n=e[0].toLowerCase();return Object.keys(s.M).forEach((i=>{n.includes(s.M[i])&&(t=s.M[i])})),t===s.M.IPadOS&&(t=s.M.Ios),e.length>1&&(i=parseFloat(`${e[1]||0}.${e[2]||0}`)),{os:t,osVersion:i}}get device(){return this.ci.browser.device}get browser(){return this.fi}get os(){return this.gi}get deviceType(){return this.yi}get geoLocation(){return this.ci.geoLocation}get pageUrl(){return this.ci.pageUrl||""}get sessionId(){return this.ci.sessionId}get pageUrlTrunc(){return this.bi}get pageDomain(){return this.Ii}get pageDomainFullPath(){return this.wi}get isMobile(){return this.ui}get isInApp(){return(0,h.QM)(this.ci.bundleID)}get isAmp(){return this.ci.isAmp}get playerId(){return this.ci.playerId}get appId(){return this.pi}get bundleID(){return(0,h.QM)(this.ci.iOSAppID)?this.ci.iOSAppID:this.ci.bundleID}get domainURL(){return this.ci.domainURL}get storeURL(){return this.ci.storeURL}get explorationMode(){return this.ci.explorationMode}get appName(){return this.ci.appName}get appCategories(){return this.ci.appCategories}get appVersion(){return this.ci.appVersion}get sdkVersion(){return this.ci.sdkVersion}get appPrivacyPolicy(){return this.ci.appPrivacyPolicy}get appIsPaid(){return this.ci.appIsPaid}get topWindow(){return this.li}get appPageURL(){return this.ci.appPageURL}get isOVPDomain(){return this.ci.isOVPDomain}}},9098:(t,i,e)=>{"use strict";e.d(i,{M4:()=>h,_n:()=>a,nn:()=>s,nu:()=>r,qF:()=>o,wy:()=>n});const s=4,n=4,r=20,o=100,h=50;var a;!function(t){t.MainContainer="cnx-scrollbar",t.Wrapper="cnx-scrollbar-wrapper",t.Content="cnx-scrollbar-content",t.Horizontal="cnx-scrollbar-horizontal",t.Handle="cnx-scrollbar-handle",t.PreventSelect="cnx-scrollbar-prevent-select",t.ShowOnHover="cnx-scrollbar-show-on-hover"}(a||(a={}))},3310:(t,i,e)=>{"use strict";e.d(i,{$:()=>r});var s=e(9098),n=e(3020);class r{constructor(t,i={}){if(this.Si=t,this.ci=i,this.Pi=0,this.Ai=t=>{t.preventDefault(),this._i=t.pageY,this.xi=t.pageX,(0,n.cn)(this.ki,s._n.PreventSelect),(0,n.cn)(this.Ci.document.body,s._n.PreventSelect),this.Ci.document.addEventListener("mousemove",this.Ei),this.Ci.document.addEventListener("mouseup",this.Mi)},this.Ei=t=>{const i=this.ci.horizontal?t.pageX-this.xi:t.pageY-this._i;this._i=t.pageY,this.xi=t.pageX,(0,n.PM)(this.Ci,(()=>{this.ci.horizontal?this.Li.scrollLeft+=i/this.Bi:this.Li.scrollTop+=i/this.Bi}))},this.Mi=t=>{(0,n.IV)(this.ki,s._n.PreventSelect),(0,n.IV)(this.Ci.document.body,s._n.PreventSelect),this.Ci.document.removeEventListener("mousemove",this.Ei),this.Ci.document.removeEventListener("mouseup",this.Mi)},this.Ri=t=>{if(!this.ci.horizontal)return;const i=t.deltaMode?s.qF*(t.deltaY<0?-1:1):t.deltaY,e=s.nu*(Math.floor(i)/33),r=this.Pi+e;r>=-1*this.ki.clientWidth&&r<=this.Li.scrollWidth-this.ki.clientWidth&&(this.Pi=r),(0,n.PM)(this.Ci,(()=>this.Li.scrollLeft=this.Pi))},this.Oi=()=>{clearTimeout(this.Di),this.Di=setTimeout((()=>{this.Vi()}),s.M4)},this.Vi=()=>{const t=this.ci.horizontal?this.Li.scrollWidth:this.Li.scrollHeight,i=this.ci.horizontal?this.Si.clientWidth:this.Si.clientHeight;this.Bi=i/t;const e=-1*(this.Si.clientWidth-(this.ki.clientWidth||s.nn)-s.wy),r=this.Si.clientHeight-this.ki.clientHeight-s.wy;(0,n.PM)(this.Ci,(()=>{if(this.Bi>=1)(0,n.MV)(this.ki);else{if((0,n.Ho)(this.ki),this.ci.horizontal)return void(0,n.T7)(this.ki,{width:`${Math.max(100*this.Bi,10)}%`,height:"",top:`${r}px`,right:"",left:this.Li.scrollLeft/t*100+"%"});(0,n.T7)(this.ki,{width:"",height:`${Math.max(100*this.Bi,10)}%`,top:this.Li.scrollTop/t*100+"%",right:`${e}px`,left:""}),this.Fi()}}))},this.Ci=(0,n.LT)(t),!this.Ci)throw new Error("window was not found");this.Ni(),this.ki.addEventListener("mousedown",this.Ai),this.ci.overrideNativeHorizontalScroll&&this.Li.addEventListener("wheel",this.Ri,{passive:!0}),this.Ci.addEventListener("resize",this.Oi),this.Li.addEventListener("scroll",this.Vi),this.Li.addEventListener("mouseenter",this.Vi),(0,n.cn)(this.Si,s._n.MainContainer,this.ci.horizontal?s._n.Horizontal:void 0,this.ci.showOnHover?s._n.ShowOnHover:void 0),this.Vi();const e=(0,n.Dx)(this.Si,this.Ci);"0px"===e.height&&"0px"!==e.maxHeight&&(0,n.T7)(this.Si,{height:e.maxHeight})}Ni(){for(this.ki=(0,n.G$)(`<cnx class="${s._n.Handle}">`,this.Ci),this.ji=(0,n.G$)(`<cnx class="${s._n.Wrapper}">`,this.Ci),this.Li=(0,n.G$)(`<cnx class="${s._n.Content}">`,this.Ci),this.ji.appendChild(this.Li);this.Si.firstChild;)this.Li.appendChild(this.Si.firstChild);this.Si.appendChild(this.ji),this.Si.insertAdjacentElement("beforeend",this.ki)}Fi(){const t=new Event("cnx-mod-scrollbar");this.Si.dispatchEvent(t)}destroy(){for(this.removeListeners(),(0,n.bX)(this.ki);this.Li.firstChild;)this.Si.appendChild(this.Li.firstChild);(0,n.bX)(this.ji),(0,n.IV)(this.Si,s._n.MainContainer,s._n.Horizontal,s._n.ShowOnHover)}removeListeners(){this.Ci.document.removeEventListener("mousemove",this.Ei),this.Ci.document.removeEventListener("mouseup",this.Mi),this.ki.removeEventListener("mousedown",this.Ai),this.Li.removeEventListener("wheel",this.Ri),this.Ci.removeEventListener("resize",this.Oi),this.Li.removeEventListener("scroll",this.Vi),this.Li.removeEventListener("mouseenter",this.Vi)}}},7994:(t,i,e)=>{"use strict";e.d(i,{C:()=>s});class s{constructor(){this.$i=!1,this.promise=new Promise(((t,i)=>{this.Ui=t,this.qi=i}))}Hi(){this.$i||(this.$i=!0)}resolve(t){this.Hi(),this.Ui(t)}reject(t){this.Hi(),this.qi(t)}get isPending(){return!this.$i}}},6299:(t,i,e)=>{"use strict";e.d(i,{P:()=>a});var s,n=e(4798),r=e(289);!function(t){t[t.Desktop=2]="Desktop",t[t.SmartTV=3]="SmartTV",t[t.Smartphone=4]="Smartphone",t[t.Tablet=5]="Tablet",t[t.GameConsole=6]="GameConsole",t[t.Unrecognized=7]="Unrecognized"}(s||(s={}));const o={[r.ProtoDeviceType.Desktop]:s.Desktop,[r.ProtoDeviceType.Smartphone]:s.Smartphone,[r.ProtoDeviceType.Tablet]:s.Tablet,[r.ProtoDeviceType.GameConsole]:s.GameConsole,[r.ProtoDeviceType.SmartTV]:s.SmartTV,[r.ProtoDeviceType.WearableComputer]:s.Unrecognized,[r.ProtoDeviceType.PDA]:s.Unrecognized,[r.ProtoDeviceType.Unrecognized]:s.Unrecognized},h="cnx_fraud_sensor";class a{constructor(t,i,e,s){this.zi=t,this.Wi=i,this.Gi=e,this.Xi(s)}addFraudSensorScript(){if(this.Wi.getElementById(h))return;const t={id:h,src:this.zi.setupMacros("https://s.srvsynd.com/2/234175/analytics.js?dt=2341751597675869250012&di=[DOMAIN]&ui=[FS_USER_ID]&md=[FS_MEDIA_TYPE]&ap=[FS_DEVICE_IDENT]&sr=[CNX_SUPPLIER_ID]&pp=[PUBLISHER_ID]&ti=[SESSION_ID]&de=[FS_DEVICE_TYPE]&to=[MGTO]&pv=[MGID]")};this.Wi.insertScript(t,null,"FraudSensor_script_error")}Xi(t){t=(0,n.QM)(t)?t:"00000000-0000-0000-0000-000000000000";const{lookupId:i,lookupResponseCode:e,deviceIdentifier:s}=this.Gi,r=o[this.Gi.deviceType];this.zi.setUserId(t),this.zi.setFraudSensorMacros({lookupId:i,lookupResponseCode:e,deviceType:r,mediaType:2,deviceIdentifier:s})}}},8049:(t,i,e)=>{"use strict";e.d(i,{a:()=>J});var s=e(9361),n=e(8532),r=e(8983),o=e(7945),h=e(5227),a=e(307),c=e(6027),d=e(9710),l=e(9741),u=e(5935),p=e(6299),f=e(970),m=e(5701),g=e(4701),v=e(289),y=e.n(v),b=e(3326),I=e(6153),w=e(5687),S=e(6666),P=e(1992),A=e(7187),_=e(1526),x=e(5292),T=e(5421),k=e(1553),C=e(4361),E=e(5650),M=e(3020),L=e(9791),B=e(51),R=e(1187),O=e(9600),D=e(3003),V=e(4798),F=e(4975),N=e(89),j=e(5672),$=e(9005),U=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};const q=[],H=[],z="player_instance",W=",",G="google_ads_iframe",X=["googlesyndication.com","googleads.g.doubleclick"],Q=["partner.googleadservices","admanager.google"];class J extends m._{constructor(t,i,e,s,n,r){super(),this.services=t,this.GLOBAL=i,this.Qi=e,this.Yi=s,this.Ki=n,this.readyCallback=r,this.Zi={},this.te="<cnx-placeholder></cnx-placeholder>",this.ie=100,this.ne=1e3,this.PLAYER_REQUEST_RETRIES_NUMBER=2,this.isServerlessMode=!1,this.re=!1,this.oe=!1,this.he=!1,this.ae=[],this.ce="{{omidVerificationClient}}",this.de=[],this.Qi.isInApp&&!this.Qi.isInAppHybrid&&this.le(),d._.detectUsingCSS(this.GLOBAL),this.ue=(0,M.sw)(this.GLOBAL)}initUrlSuffixer(t){const i=new k.f;if(t.bandwidthLoggingState===v.ProtoBandwidthLoggingEnum.Disabled)return i;const e=this.pe(t);return i.setUrlParams({domain:I.n.bundleDomain,urlParams:[(0,D.IS)(e,t.playerId)]}),i}fe(){const t={playerId:this.externalAttributes.playerId,_appSettings:this.externalAttributes._appSettings,settings:{_connatixInternals:this.externalAttributes.settings._connatixInternals,advertising:{},customization:{},rendering:{},plugins:{}}};this.externalAttributes.customParam1&&(t.customParam1=this.externalAttributes.customParam1),this.externalAttributes.customParam2&&(t.customParam2=this.externalAttributes.customParam2),this.externalAttributes.customParam3&&(t.customParam3=this.externalAttributes.customParam3),this.externalAttributes.customParam4&&(t.customParam4=this.externalAttributes.customParam4),this.externalAttributes.customParam5&&(t.customParam5=this.externalAttributes.customParam5),this.externalAttributes.settings.useExternalViewabilityService&&(t.settings.useExternalViewabilityService=this.externalAttributes.settings.useExternalViewabilityService),this.externalAttributes=t}me(t){const i=this.GLOBAL.frameElement;if(!(0,M.GF)(i))return;let e=!0;i&&t&&(e=!1),e?(0,M.MV)(i):(0,M.Ho)(i)}ve(t,i){try{return this.ye(t,i)}catch(t){return null}}be(t){let i;try{i=eval(t)}catch(e){i=t.replace(/\[(\d+)]/g,":nth-child($1)")}return i}Ie(t,i){const e=this.ve(t,i);return null===e?new Promise((e=>{setTimeout((()=>{e(this.Ie(t,i))}),this.ie)})):Promise.resolve(e)}Se(t,i){const e=this.be(t);return Promise.resolve(this.Ie(e,i))}ye(t,i){let e;return t.split(/(\.cnxEq\(\d+\))/).filter((t=>t)).forEach((t=>{e=t.includes("cnxEq")?this.Pe(e,t):e?e.querySelectorAll(t):(0,M.Wb)(t,i)})),e?(e.hasOwnProperty("length")&&(e=e.length>0?e[0]:null),e):null}Pe(t,i){const e=/\d+/g.exec(i),s=parseInt(e[0],10);return s>t.length?(0,E.Sz)(t)[t.length-1]:(0,E.Sz)(t)[s]}_e(){return this.Yi?v.ProtoImplementationType.Amp:v.ProtoImplementationType.Web}xe(){return Q.some((t=>{var i;return null===(i=this.pageUrl)||void 0===i?void 0:i.includes(t)}))}Te(){let t=window,i=!1;try{for(;t.parent.document!==t.document&&(i=this.ke(t),!i);)t=t.parent}catch(e){i=this.Ce(t)}return i}Ee(){return this.oe||this.Te()}Ce(t){return X.some((i=>{var e;return null===(e=null==t?void 0:t.location)||void 0===e?void 0:e.href.includes(i)}))}ke(t){var i;return!!(null===(i=null==t?void 0:t.frameElement)||void 0===i?void 0:i.id.includes(G))}Me(t,i){const e=(0,L.pE)(this.GLOBAL);let s;return this.oe=this.xe(),this.he=this.Ee(),s=(0,V.$K)(this.externalAttributes.settings.rendering.forceInsertPath)?this.externalAttributes.settings.rendering.forceInsertPath:i.forceInsertPath,new Promise(((n,o)=>{let h=(0,M.G$)(this.te,this.GLOBAL);if(s||t.tag.parentNode===this.GLOBAL.document.head&&(!e.topChildFrame||i.renderInFrame)){let t,s,o;e.topChildFrame&&(0,M.IV)(e.topChildFrame.frameElement,r.Gj.DisplayNone),t=(0,V.QM)(this.externalAttributes.settings.rendering.containerSelector)?this.externalAttributes.settings.rendering.containerSelector:i.containerSelector,s=(0,V.$K)(this.externalAttributes.settings.rendering.insertPosition)?this.externalAttributes.settings.rendering.insertPosition:i.insertPosition,o=(0,V.$K)(this.externalAttributes.settings.rendering.position)?this.externalAttributes.settings.rendering.position:i.position,this.Se(t,e.topFrame).then((t=>{this.Le(t,h,s,o),n({insertContainer:h,insertWindow:e.topFrame})}))}else e.topChildFrame&&!i.renderInFrame?(h=(0,M.G$)(this.te,e.topFrame),e.topChildFrame.frameElement.parentNode.insertBefore(h,e.topChildFrame.frameElement),(0,M.cn)(e.topChildFrame.frameElement,r.Gj.DisplayNone),n({insertContainer:h,insertWindow:e.topFrame})):(t.tag.parentNode.insertBefore(h,t.tag),n({insertContainer:h}))}))}Be(t,i,e){(0,M.IS)(i,t,e)}Re(t,i,e){switch(e){case v.ProtoPlayerInsertMode.BeforeContainer:t.parentElement.insertBefore(i,t);break;case v.ProtoPlayerInsertMode.ReplaceContainer:t.parentElement.insertBefore(i,t),(0,M.bX)(t);break;case v.ProtoPlayerInsertMode.HideContainer:t.parentElement.insertBefore(i,t),(0,M.MV)(t);break;case v.ProtoPlayerInsertMode.AfterContainer:t.nextElementSibling?t.parentElement.insertBefore(i,t.nextElementSibling):t.parentElement.appendChild(i)}}Le(t,i,e,s){e===v.ProtoPlayerInsertMode.WithinContainer?this.Be(t,i,s):this.Re(t,i,e)}Oe(t,i=[]){t.lineItems=[...t.lineItems,...i];const e=t.lineItems.length;t.lineItems=(0,E.qy)("advertiserLineItemId",t.lineItems),e!==t.lineItems.length&&(0,R.n)({level:R.D.WARN,message:"Loader_duplicated_adsources",callStack:"_"})}De(t,i){var e,r,o;const a=t.players[i],{sessionId:c}=a,{playerModel:p,globalDomUtilsService:f,urlSuffixerService:m}=this.Zi[i];if(this.Ve(t.cookieSyncUrls),this.services.UserManagerService.setGeoLocation(t.geoLocation),l.S.sessionId=c,this.Fe.addPlayerSession(a.playerId,c),!p)return void this.registerApiError(n.n9.SetupError,"No playlist was provided!");const g=new u.X({iOSAppID:this.Qi.isInApp&&!this.Qi.isInAppSDK?t.iOSAppID:null,browser:t.browser,geoLocation:t.geoLocation,pageUrl:this.pageUrl,playerId:p.playerId,explorationMode:t.explorationMode,isAmp:this.Yi,bundleID:this.externalAttributes._appSettings.bundleID,domainURL:this.externalAttributes._appSettings.domainURL,storeURL:this.externalAttributes._appSettings.storeURL,appCategories:this.externalAttributes._appSettings.appCategories,appIsPaid:this.externalAttributes._appSettings.appIsPaid,appName:this.externalAttributes._appSettings.appName,appPrivacyPolicy:this.externalAttributes._appSettings.appPrivacyPolicy,appVersion:this.externalAttributes._appSettings.appVersion,sdkVersion:this.externalAttributes._appSettings.sdkVersion,appPageURL:this.externalAttributes._appSettings.appPageURL,isOVPDomain:this.Ki,sessionId:c}),y={browser:t.browser,geoLocation:t.geoLocation,playerId:p.playerId,userId:this.services.UserManagerService.getTrackableUser(),sessionId:t.players[i].sessionId,pageUrl:this.pageUrl,bundleId:this.externalAttributes._appSettings.bundleID,customParam1:this.externalAttributes.customParam1,customParam2:this.externalAttributes.customParam2,customParam3:this.externalAttributes.customParam3,customParam4:this.externalAttributes.customParam4,customParam5:this.externalAttributes.customParam5,abTestId:t.players[i].abTestId,isExplorationMode:t.explorationMode,bundleAbId:t.bundleAbId,bundlePart:t.bundlePart,lineItemAbTestInformation:t.lineItemAbTestInformation,implementationType:this._e(),iasSegmentCodes:t.IASSegmentCodes,amazonTamPubId:t.AmazonTamPubId},b={pageDomain:g.pageDomain},I={sessionId:c,omidWindow:(0,L.pE)(window).topFrame,isInAppSdk:this.Qi.isInAppSDK,isInApp:this.Qi.isInApp,isGam:this.he,sdkVersion:this.externalAttributes._appSettings.sdkVersion?this.externalAttributes._appSettings.sdkVersion:void 0,pageUrl:this.pageUrl},{sessionEvents:w,generalRepository:S,wcagService:P,mediaEvents:k,trackingService:E,adEvents:M}=j.o.boostrapSessionContainer(a.sessionId,y,this.services.UserManagerService,b,p.disableTracking,this.services.EventsStorageService,I,f,null===(r=null===(e=this.externalAttributes.settings)||void 0===e?void 0:e.advertising)||void 0===r?void 0:r.prebidPermutiveParamsConfig),B=new x.v(f),R=this.getViewabilityService(p,B,S);d._.detectUsingCSS(p.global);const O=new _.c(p,t.geoLocation,g.pageUrl,g.pageDomain,g.pageDomainFullPath,this.externalAttributes._appSettings,this.ue,t.publisherNetworkCode),D=null===(o=t.userInformation)||void 0===o?void 0:o.publisherAdsTxt;(0,V.QM)(D)&&O.setPublisherId(D);const F={services:{GlobalDomUtilsService:f,ViewabilityService:R,ResizeObserver:new T.a(p.global),UserManagerService:this.services.UserManagerService,MacrosService:O,EventsStorageService:this.services.EventsStorageService,PageFocusService:B,InteractionService:new A.k(p.global,g.isMobile),UrlSuffixerService:m},config:g};d._.isBannerBlocked&&w.sessionAdBlocked.next({adBlockDetectionType:s.ev.Banner}),F.services.UserManagerService.setPageUrl(F.config.pageUrl),S.playerEnvironment=this.Ne(),p.externalMacros&&F.services.MacrosService.addExtraMacros(p.externalMacros),F.services.UserManagerService.onEvent([C.k.CCPA_INFO_RECEIVED]).then((()=>{F.services.MacrosService.setUsPrivacyString(F.services.UserManagerService.getUsPrivacyString())})),F.services.UserManagerService.onEvent([C.k.CONSENT_DATA_UPDATE]).then((()=>{S.userId=F.services.UserManagerService.getTrackableUser();const t=F.services.UserManagerService.getConsentPayload();if(S.hasGdprConsentPayload=(0,V.QM)(t),this.services.UserManagerService.gdprConsentMode===v.ProtoGdprConsentModeEnum.NoConsent||this.Qi.isInApp){const t=p.lineItemSettings.lineItems.filter((t=>(0,V.QM)(t.vendorId))).every((t=>this.services.UserManagerService.isConsent(t.vendorId)));this.services.UserManagerService.gdprConsentMode=t?v.ProtoGdprConsentModeEnum.AllGood:v.ProtoGdprConsentModeEnum.NotAllDemandConsent}}));const N={wasPlayerReloaded:this.Fe.wasPlayerReloaded(a.playerId),wasPlayerInView:this.Fe.getSessionInView(a.playerId)};this.renderer=this.getRendererInstance(p,F,N,this.externalAttributes._appSettings,w,M,k,S,P,E),this.subscribe(h.Xh.SessionView,this.renderer,(()=>{this.Fe.addSessionInView(a.playerId)})),this.subscribe(h.Xh.SessionRendered,this.renderer,(()=>{this.je(O,f,F.config)}));const $=Object.assign({configEnums:this.getApiConfigEnums(),configEvents:this.getApiConfigEvents()},this.renderer.getApiMethods());let U=a.customJsCode;try{U=U.trim(),U="try\n            {   var trackerData;\n                const api2 = \"{{player_instance}}\";\n                api2.on('adImpression',function(data){\n                    if(data.adSourceData.adId === '56445225-357b-4728-847b-5ff007dddc2d' || data.adSourceData.adId === 'eff225cb-dc0b-40d0-82aa-c6343d2f513d'){\n                        trackerData.impressionTrackers.forEach(function(el){\n                            const img = new Image();\n                            img.src = el.url;\n                        });\n                    }\n                });\n                api2.on('bid',function(data){\n                    if(data.advertiserLineItemId === 'e021c805-a361-483c-b11c-5142342d87ef'){\n                        trackerData = data;\n                        api2.updateJsQueryTargeting({audiance:'enable'})\n                    }\n                });\n            } catch(e){}; "+U}catch(t){}if(U){const t=`${z}_${F.config.appId}`;this.GLOBAL[t]=$,U=U.cnx_replaceAll(`"{{${z}}}"`,`window.${t}`)}this.renderer.init((()=>{this.$e(U)}))?this.registerApiSuccess($):this.registerApiError(n.n9.RenderError,"Player size under supported value")}$e(t,i={useSafeMode:!0}){if(!t)return;const{global:e,useSafeMode:s}=i,n=e||this.GLOBAL;let r;r=s?`\n        (function() {\n            "use strict";\n            try {\n                ${t}\n            }catch(e){\n                console.warn('---CnxCustomApiError---');\n                console.warn(e.message);\n            }\n          })()\n        `:t,(0,M.ML)(n.document.head,n,r.trim())}le(){if(this.ce.includes("{{omidVerificationClient"))return;const t={useSafeMode:!1,global:window};this.$e(decodeURI(this.ce),t)}Ue(){const{playerId:t,parseDomain:i}=this.He;return this.ze(t,i).catch((t=>{const i=new Error(t);throw(0,R.n)({callStack:i.stack,level:R.D.CRITICAL,exception:i.message,message:"Prerender_Loader_player_id_call_get_pls"},{throttle:1e3}),this.registerApiError(n.n9.SetupError,"player data call error"),this.We(),i}))}Ge(t){return U(this,void 0,void 0,(function*(){const{browser:i,userInformation:e}=t;if(this.services.UserManagerService.setUserInformation(e),this.services.UserManagerService.setBrowserInfo(i),t.hashedPageUrl&&(yield S.k.loadPageInsights({insightsInputType:P.i.Page,id:t.hashedPageUrl})),e&&e.callFraudSensor){const{lookupId:t,lookupResponseCode:s}=e;this.Gi={lookupId:t,lookupResponseCode:s,deviceType:i.device}}c.e.serverAb0=t.serverAb0,c.e.serverAb1=t.serverAb1,(0,E.BZ)(t.players)?(t.players.length>1&&(this.fe(),this.re=!0),Object.keys(t.players).forEach((i=>{this.Xe(t,this.He,i)}))):this.registerApiError(n.n9.NoPlayer,`No player available for given player id:${this.He.playerId}`),this.We()}))}We(){this.Qe(),this.Je()}Je(){this.de.push(this.renderer.onReady().pipe((0,F.h)((t=>!!t)),(0,N.q)(1)).subscribe((()=>{setTimeout((()=>{if(!this.re){const t=this.ae[0];this.readyCallback&&this.readyCallback(t.apiErrorObj,t.apiConfigObj)}this.Ye()}))})))}Ye(){this.ae.filter((t=>t.apiErrorObj)).forEach((()=>{this.services.EventsStorageService.emitRenderError()}))}Xe(t,i,e){const s=t.players[e],{playerModel:n}=this.Zi[e];this.me(s.renderInFrame),this.De(t,e),this.Ke(n,this.renderer.playerContainer)}ze(t,i=!1){let e={parseDomain:i,referrer:this.ue,pageUrl:this.pageUrl,tokens:[t]};e.bundleId=this.externalAttributes._appSettings.bundleID,this.queryParams.cnxLineItemId&&(e.forceLineItemIds=this.queryParams.cnxLineItemId.split(W).filter((t=>(0,V.QM)(t)))),this.queryParams.cnxPlayerId?e.forcePlayerId=this.queryParams.cnxPlayerId:this.externalAttributes.settings._connatixInternals.skipServingRules&&(e.forcePlayerId=t),this.queryParams.cnxExplorationMode&&(e.forceExploration=!0);const{queryJsTargeting:s}=this.externalAttributes.settings;return(0,V.as)(s)&&Object.keys(s).length>0&&(e.queryJsTargeting=(0,L.rM)(s)),e.customParam1=this.externalAttributes.customParam1,e.customParam2=this.externalAttributes.customParam2,e.customParam3=this.externalAttributes.customParam3,e.customParam4=this.externalAttributes.customParam4,e.customParam5=this.externalAttributes.customParam5,e.disableTracking=this.externalAttributes.settings._connatixInternals.disableTracking,e.version=o.g.version,e.es6=o.x,e.userId=this.services.UserManagerService.getForcedTrackableUser(),e.isConsentConnatix=this.services.UserManagerService.isConsentConnatix(),e.clientAb0=c.e.clientAb0,e.clientAb1=c.e.clientAb1,e.implementationType=this._e(),e.reloadedPlayers=this.Fe.getCookiePlayersSession(),e.servingRuleId=this.externalAttributes.servingRuleId,e=Object.assign(Object.assign({},e),this.getSpecificRequestData()),this.He.playerId?this.getPlayerResponse(e):new Promise(((t,i)=>{this.isServerlessMode=!0,t(this.defaultInitFromProto())}))}Ze(){const t=(0,B.Ph)("cnxVideoPosition",this.pageUrl),i=parseInt((0,B.Ph)("cnxStoryPosition",this.pageUrl),10);return{cnxStoryId:(0,B.Ph)("cnxStoryId",this.pageUrl),cnxLineItemId:(0,B.Ph)("cnxLineItemId",this.pageUrl),cnxPlayerId:(0,B.Ph)("cnxPlayerId",this.pageUrl),cnxMediaId:(0,B.Ph)("cnxMediaId",this.pageUrl),cnxPlaylistId:(0,B.Ph)("cnxPlaylistId",this.pageUrl),cnxVideoPosition:t?parseInt(t,10):null,cnxExplorationMode:"true"===(0,B.Ph)("cnxExplorationMode",this.pageUrl),cnxStoryPosition:(0,V.r)(i)?i:null,cnxSkipAdsFlag:"true"===(0,B.Ph)("cnxSkipAdsFlag",this.pageUrl),cnxReloadTime:parseInt((0,B.Ph)("cnxReloadTime",this.pageUrl),10),cnxOverrideLineitems:"true"===(0,B.Ph)("cnxOverrideLineitems",this.pageUrl),cnxIsSeoTraffic:"true"===(0,B.Ph)("cnxIsSeoTraffic",this.pageUrl),cnxDebug:"true"===(0,B.Ph)("cnxDebug",this.pageUrl),cnxEnableNewUi:"true"===(0,B.Ph)("cnxEnableNewUi",this.pageUrl)}}Ke(t,i){const e=this.getDelegateHandler(),s=new g.N(this.GLOBAL,this.services.EventsStorageService,e,t,i);this.Ki?d._.isBannerBlocked||this.de.push(d._.onAdBlockerDetected().subscribe((t=>{t||s.start()}))):s.start()}je(t,i,e){if(!this.Gi)return;const s=this.services.UserManagerService.getTrackableUser();this.Gi.deviceIdentifier=e.bundleID;const n=new p.P(t,i,this.Gi,s);this.Ki?this.de.push(d._.onAdBlockerDetected().subscribe((t=>{t||n.addFraudSensorScript()}))):n.addFraudSensorScript()}Ve(t){d._.isBannerBlocked||(this.Ki?this.de.push(d._.onAdBlockerDetected().subscribe((i=>{i||this.services.UserManagerService.setThirdPartySyncUrls(t)}))):this.services.UserManagerService.setThirdPartySyncUrls(t))}ts(t){const i=()=>new Promise(((i,e)=>{const s=this.es();t.addCssStylesheetToHead(s,(()=>i()),(t=>e(t)))}));return(0,L.Up)((()=>i())).catch((t=>{throw(0,R.n)({message:"Loader_add_css_link",exception:t,level:R.D.INFO}),new Error(t)}))}pe(t){return t.bandwidthLoggingState===v.ProtoBandwidthLoggingEnum.Enabled?a.Kp:t.bandwidthLoggingState===v.ProtoBandwidthLoggingEnum.SaaS?a.a8:void 0}Ne(){return this.Qi.isInAppSDK?$.Q.InAppSdk:this.Qi.isInAppHybrid?$.Q.InAppWebview:this.Qi.isInApp?$.Q.InAppGam:this.Yi?$.Q.WebAmp:$.Q.Web}setInappPageUrl(t){(0,V.QM)(t)&&(this.pageUrl=t)}updateQueryParams(){this.queryParams=this.Ze()}loadScriptTag(t,i){if(this.externalAttributes=t,(0,V.QM)(t.playerId)&&!(0,L.er)(t.playerId))return(0,R.n)({level:R.D.WARN,message:"Invalid_Player_GUID",exception:t.playerId}),this.registerApiError(n.n9.InvalidGUID,"Invalid PlayerID was provided"),!1;let e;if(i&&(e=this.GLOBAL.document.getElementById(i)),!e)return(0,R.n)({message:"Loader_no_script_id",exception:`${t.playerId}`,level:R.D.INFO},{pacing:5}),this.registerApiError(n.n9.SetupError,"Could not locate any script tag ids in the page"),!1;const s=(0,V.as)(t.settings.plugins.adobeAnalyticsSettings);return this.He={parseDomain:s,playerId:t.playerId,tag:e},!0}insertRenderer(){try{this.Fe=new f.e(this.queryParams.cnxReloadTime),this.me();const t=()=>{try{this.Ue().then((t=>{const i=[];t.players.forEach(((e,s)=>{t.players[s].limitClientSideApiUse&&this.fe();const r=this.Me(this.He,e).then((i=>{this.Oe(e,t.lineItems);const n=this.initUrlSuffixer(e),r=this.getPlayerModel(i,t,n,s.toString()),o=new w.m(r.global);return(0,b.u)(r.lineItemSettings.lineItems),this.oe&&(r.disableAdvertising=!0,e.lineItems=[]),this.Zi[s]={playerModel:r,globalDomUtilsService:o,urlSuffixerService:n},this.ts(o)})).catch((t=>{this.registerApiError(n.n9.SetupError,"rendering error"),(0,R.n)({message:"Loader_send_data_to_renderer",exception:t.message,callStack:t.stack,level:R.D.CRITICAL})}));i.push(r)})),Promise.all(i).then((()=>this.Ge(t)))}))}catch(t){(0,R.n)({message:"Prerender_Loader_do_player_call",callStack:t.stack,exception:t.message,level:R.D.WARN},{throttle:1e3})}};this.Qe=this.services.UserManagerService.registerPlsCall(t)}catch(t){(0,R.n)({message:"Prerender_Loader_insert_renderer",exception:t.message,callStack:t.stack,level:R.D.CRITICAL})}}findPageUrl(t,i,e=!1){if(t.cnx_page_url)this.pageUrl=t.cnx_page_url;else try{t["cnxAmpAd)"]?this.pageUrl=t.context.sourceUrl||t.context.location.href:this.pageUrl=i||(0,L.lU)((0,L.pE)(this.GLOBAL),this.GLOBAL)}catch(t){}if(!this.pageUrl||0===this.pageUrl.length)return e||(0,R.n)({message:"Prerender_Loader_find_page_url",level:R.D.INFO},{throttle:1e3}),new Promise((e=>{setTimeout((()=>{this.findPageUrl(t,i,!0).then((()=>e()))}),this.ne)}));try{return this.pageUrl=(0,B.sH)(this.pageUrl),Promise.resolve()}catch(t){return(0,R.n)({message:"Loader_find_page_url",exception:t.message,callStack:t.stack,level:R.D.CRITICAL}),Promise.reject()}}registerApiError(t=n.n9.SetupError,i=""){this.ae.push({apiErrorObj:{type:t,message:i}})}registerApiSuccess(t){this.ae.push({apiConfigObj:t})}setClientAb1(){try{const t=(0,B.ge)(this.pageUrl);if(q.includes(t))c.e.setClientAb1(2);else{H.includes(t)&&c.e.setClientAb1(1)}}catch(t){}}destroy(){this.renderer&&this.renderer.destroy(),(0,O.i)(this.de)}}},970:(t,i,e)=>{"use strict";e.d(i,{e:()=>o});var s=e(9791),n=e(1187),r=e(9357);class o{constructor(t){this.RELOAD_TIME=r.ti,this.RELOAD_COOKIES="cnx_player_reload",this.SESSION_IN_VIEW_FLAG="_sessionWasViewed",this.ss={},this.ns={},this.rs={},this.li=(0,s.pE)(window).topFrame,this.hs(t);try{this.cs()}catch(t){(0,n.n)({message:"PlayerReloader_cookie_fetch_failed",level:n.D.WARN,exception:t})}}wasPlayerReloaded(t){return!!this.ss[t]}addPlayerSession(t,i){this.ns[t]=i}getCookiePlayersSession(){return this.ss}addSessionInView(t){this.ns[t]+=this.SESSION_IN_VIEW_FLAG}getSessionInView(t){return this.rs[t]}hs(t){setTimeout((()=>{this.ds(),this.li.location.reload()}),t||this.RELOAD_TIME)}cs(){decodeURIComponent(this.li.document.cookie).split(";").forEach((t=>{const i=t.split("=");i[0].includes(this.RELOAD_COOKIES)&&(this.ss=JSON.parse(i[1]))})),this.ls(),this.us()}ls(){Object.keys(this.ss).forEach((t=>{const i=this.ss[t].indexOf(this.SESSION_IN_VIEW_FLAG);i>-1&&(this.ss[t]=this.ss[t].substr(0,i),this.rs[t]=!0)}))}us(){this.li.document.cookie=`${this.RELOAD_COOKIES}=; expires = Thu, 01 Jan 1970 00:00:00 GMT; path=/`}ds(){Object.keys(this.rs).forEach((t=>{this.ns[t].includes(this.SESSION_IN_VIEW_FLAG)||this.addSessionInView(t)}));const t=new Date;let i=t.getTime();i+=r.Y0*r.s_,t.setTime(i),this.li.document.cookie=`${this.RELOAD_COOKIES}=${JSON.stringify(this.ns)}; expires=${t.toUTCString()}; path=/`}}},6224:(t,i,e)=>{"use strict";e.d(i,{t:()=>h});var s=e(9791),n=e(1187),r=e(4798),o=e(6578);class h{constructor(t,i){this.ps=t,this.gs=i,this.vs=(t,i)=>new Promise(((e,s)=>{o.n.sendProtoRequest({protoResponse:this.ps,endpoint:t,requestType:"GET",shouldLogErrors:!0,timeout:i}).then((t=>{e(t)})).catch((t=>{s(t)}))}))}fetchMetadata(t,i=5,e=!0,n){const o=t=>403===this.ys(t);return new Promise(((h,a)=>{(0,s.Up)((()=>this.vs(t,n)),i,o).then((i=>{if((0,r.as)(i))return h(i);const e=new Error("invalid metadata");return this.bs({url:t,metadata:i,e}),a(e)})).catch((i=>{e&&this.bs({url:t,e:i}),a(i)}))}))}bs(t){var i;const e=(0,r.QM)(null===(i=t.e)||void 0===i?void 0:i.message)?t.e.message:"";e.includes("XhrUtils_XMLHttpRequest_error")||(0,n.n)({message:"MediaMetadataHandler_fetchMetadata",exception:`${this.gs}_${e}:${JSON.stringify(t)}`,callStack:t.e&&t.e.stack,level:n.D.CRITICAL})}ys(t){if(t&&t.message){const i=t.message.split("status:")[1];return i?parseInt(i.slice(0,3),10):null}return null}}},5701:(t,i,e)=>{"use strict";e.d(i,{_:()=>n});var s=e(5650);class n{constructor(){this.Is={}}subscribe(t,i,e){this.Is[t]||(this.Is[t]=[]),this.Is[t].push({context:i,func:e})}unsubscribe(t,i,e){this.Is[t]&&(this.Is[t]=this.Is[t].filter((t=>!(t.context===i&&(t.func===e||!e)))))}unsubscribeAll(t){Object.keys(this.Is).forEach((i=>{this.Is[i]=this.Is[i].filter((i=>i.context!==t))}))}publish(t,i,e={payload:void 0}){Object.prototype.hasOwnProperty.call(this.Is,i)&&this.Is[i].forEach((i=>{i.context===t&&i.func(e)}))}relay(t,i,e,n){(0,s.qo)(t).forEach((t=>{this.subscribe(t,i,(i=>{n.publish(e,t,i)}))}))}relayBulk(t,i,e){t.forEach((t=>{this.relay(t.channel,t.source,i,e)}))}}},4701:(t,i,e)=>{"use strict";e.d(i,{N:()=>p});var s,n=e(3020);class r{constructor(t){this.ws=[],this.Ss=t=>{this.ws.push(t)},this.Ps=t.subscribe(this.Ss)}get cachedEvents(){return this.ws}destroy(){this.ws=null,this.Ps()}}!function(t){t.AdobeAnalytics="AdobeAnalytics",t.MoatAnalytics="MoatAnalytics"}(s||(s={}));var o=e(4798),h=e(1187),a=e(5650),c=e(9791),d=e(51),l=e(7945),u=e(6153);class p{constructor(t,i,e,s,n){this.As=i,this._s=e,this.Ts=s,this.ks=n,this.Cs=[],this.Es=t=>{try{this.Ls(t);const i=this.Cs.find((i=>i.name===t.type));let e;if(i&&!i.started){i.started=!0;const t=i.eventsCacheHandler;e=t.cachedEvents,t.destroy()}const{adobeAnalyticsSettings:s,moatAnalyticsSettings:n,_debugLogging:r}=this.Ts.apiConfig.settings.plugins,{secondLevelDomain:o,playerId:h}=this.Ts,a={cachedEvents:e,adobeAnalyticsSettings:s,moatAnalyticsSettings:n,_debugLogging:r,secondLevelDomain:o,playerId:h,pageName:this.Bs,pageUrl:this.Rs,version:l.g.version,delegateHandlers:this._s,playerContainer:this.ks,playerWindow:window};t.getInstance().start(this.As,a)}catch(t){(0,h.n)({callStack:t.stack,exception:t.message,level:h.D.CRITICAL,message:"PluginsHandler_initPlugin"})}};const r=(0,c.pE)(t);this.Ci=r.topFrame,this.Rs=(0,c.lU)(r,this.Ci),this.Rs=(0,d.sH)(this.Rs),this.Bs=(0,d.ge)(this.Rs)}start(){this.Os(),this.Ds(),this.Ci.cnxPlugins.pluginsHandlers.push(this.Es)}Os(){let t=[];Array.isArray(this.Ci.cnxPlugins)&&this.Ci.cnxPlugins.length>0&&(t=this.Ci.cnxPlugins,t.forEach((t=>this.Es(t)))),(0,o.as)(this.Ci.cnxPlugins)||this.Vs(t)}Ds(){const t=this.Ns();(0,a.BZ)(t)&&this.js(t)}$s(t){const i=this.Ci.cnxPlugins.cachedPlugins;if((0,a.BZ)(i))return i.find((i=>i.type===t))}Ls(t){this.$s(t.type)||this.Ci.cnxPlugins.cachedPlugins.push(t)}Vs(t){this.Ci.cnxPlugins={cachedPlugins:t,pluginsHandlers:[],push:function(t){this.pluginsHandlers.forEach((i=>{i(t)}))}}}js(t){t.forEach((t=>{this.$s(t)||this.Cs.push({name:t,started:!1,eventsCacheHandler:new r(this.As)})})),this.Cs.forEach((({name:t})=>this.Us(t)))}zs(t){return Object.values(t).every((t=>(0,o.QM)(t)))}Ns(){const t=[];return this.Ts.apiConfig.settings.plugins.adobeAnalyticsSettings&&this.zs(this.Ts.apiConfig.settings.plugins.adobeAnalyticsSettings)&&t.push(s.AdobeAnalytics),this.Ts.moatTrackingEnabled&&t.push(s.MoatAnalytics),t}Us(t){const i={id:`cnx-${t}`,src:""};switch(t){case s.AdobeAnalytics:i.src=u.n.endPoints.assets.plugins.adobeAnalytics;break;case s.MoatAnalytics:i.src=u.n.endPoints.assets.plugins.moatAnalytics}this.Ci.document.getElementById(i.id)||(0,n.dZ)(i,this.Ci.document.head,this.Ci,null,null,!0,"PluginsHandler_unable_to_insert_plugin_script")}}},4065:(t,i,e)=>{"use strict";e.d(i,{B:()=>h});var s=e(1509),n=e(9357),r=e(7332),o=e(6716);class h{constructor(t,i=0,e=1e3){this.Ws=t,this.timerDuration=i,this.Gs=e,this.Qs=0,this.Js=null,this.Ks=!1,this.Zs=!1,this.tn=new o.x,this.en=new o.x,this.sn=new o.x,this.rn=[{event:s.n.FirstQuartile,quartile:1},{event:s.n.SecondQuartile,quartile:2},{event:s.n.ThirdQuartile,quartile:3},{event:s.n.FourthQuartile,quartile:4}],this.hn=null,this.an=()=>{this.dn(),this.tn.next(),this.ln(this.Qs,this.timerDuration),this.un(),this.pn=(new Date).getTime()},i||this.disable()}start(){this.Zs=!0,null===this.Js&&this.mn()}stop(){this.Zs=!1,null!==this.Js&&(this.dn(),this.gn())}reset(t){t&&(this.timerDuration=t),this.Qs=0,this.Ks=!1,this.hn=null,(null!==this.Js||this.Zs)&&(this.gn(),this.mn())}get timeElapsed(){return this.Qs}get timeRemaining(){return this.timerDuration-this.Qs}disable(){this.Ks=!0,this.gn()}get onTimeUpdate(){return this.tn.asObservable()}get onTimeElapsed(){return this.en.asObservable()}get onQuartile(){return this.sn.asObservable()}get startingTime(){return this.pn}dn(){this.Qs+=(new Date).getTime()-this.pn}mn(){this.Ks||(this.un(),this.pn=(new Date).getTime(),this.Js=this.Ws.setInterval(this.an,this.Gs))}gn(){this.Ws.clearInterval(this.Js),this.Js=null}vn(){this.disable(),this.en.next(),this.Qs=0}un(){this.Qs/n.s_>=this.timerDuration/n.s_&&this.vn()}ln(t,i){const e=Math.floor((0,r.dQ)(0,i,1,4,t));this.hn<=e&&this.rn.forEach((({event:t,quartile:i})=>{i===e&&i!==this.hn&&(this.sn.next(t),this.hn=i)}))}}},2300:(t,i,e)=>{"use strict";var s;e.d(i,{r:()=>s}),function(t){t[t.PlayButton=0]="PlayButton",t[t.BigPlayButton=1]="BigPlayButton",t[t.VolumeButton=2]="VolumeButton",t[t.VolumeProgress=3]="VolumeProgress",t[t.VolumeControls=4]="VolumeControls",t[t.ExpandButton=5]="ExpandButton",t[t.SettingsButton=6]="SettingsButton",t[t.CaptionButton=7]="CaptionButton",t[t.CaptionComponent=8]="CaptionComponent",t[t.UpNextButton=9]="UpNextButton",t[t.UpNextBox=10]="UpNextBox",t[t.PreviousButton=11]="PreviousButton",t[t.LogoComponent=12]="LogoComponent",t[t.LogoOutstream=13]="LogoOutstream",t[t.MoreButton=14]="MoreButton",t[t.ElapsedTimeLabel=15]="ElapsedTimeLabel",t[t.TotalDurationLabel=16]="TotalDurationLabel",t[t.RemainingDurationLabel=17]="RemainingDurationLabel",t[t.ProgressBar=18]="ProgressBar",t[t.QualityMenu=19]="QualityMenu",t[t.QueStateOverlay=20]="QueStateOverlay",t[t.Loader=21]="Loader",t[t.ContextMenu=22]="ContextMenu",t[t.ElementsSettingsMenu=23]="ElementsSettingsMenu",t[t.CloseButton=24]="CloseButton",t[t.PinnedCloseButton=25]="PinnedCloseButton",t[t.SkipAdButton=26]="SkipAdButton",t[t.AdLoadingScreen=27]="AdLoadingScreen",t[t.CtaButton=28]="CtaButton",t[t.PlayspaceProgressBar=29]="PlayspaceProgressBar",t[t.PlayspaceSettingsMenu=30]="PlayspaceSettingsMenu",t[t.ClickToPlayButton=31]="ClickToPlayButton",t[t.OverlayComponent=32]="OverlayComponent",t[t.SlideTitle=33]="SlideTitle",t[t.TopTitle=34]="TopTitle",t[t.TopLogo=35]="TopLogo",t[t.TopSlideTitle=36]="TopSlideTitle",t[t.TopStoryTitle=37]="TopStoryTitle",t[t.TextLabel=38]="TextLabel",t[t.LivePoster=39]="LivePoster",t[t.LiveIcon=40]="LiveIcon",t[t.ElementsCaptionMenu=41]="ElementsCaptionMenu",t[t.PinnedTitle=42]="PinnedTitle"}(s||(s={}))},9762:(t,i,e)=>{"use strict";var s;e.d(i,{C:()=>s}),function(t){t[t.Play=0]="Play",t[t.Pause=1]="Pause",t[t.Replay=2]="Replay",t[t.Volume=3]="Volume",t[t.Mute=4]="Mute",t[t.Unmute=5]="Unmute",t[t.DraggingStart=6]="DraggingStart",t[t.DraggingStopped=7]="DraggingStopped",t[t.Seek=8]="Seek",t[t.SeekingStart=9]="SeekingStart",t[t.SeekingStopped=10]="SeekingStopped",t[t.Expand=11]="Expand",t[t.Collapse=12]="Collapse",t[t.Quality=13]="Quality",t[t.Close=14]="Close",t[t.Next=15]="Next",t[t.Prev=16]="Prev",t[t.Settings=17]="Settings",t[t.SettingsMenu=18]="SettingsMenu",t[t.CaptionOn=19]="CaptionOn",t[t.CaptionOff=20]="CaptionOff",t[t.CaptionUpdate=21]="CaptionUpdate",t[t.CaptionMenu=22]="CaptionMenu",t[t.VolumeHoverStart=23]="VolumeHoverStart",t[t.VolumeHoverStopped=24]="VolumeHoverStopped",t[t.UIHideStart=25]="UIHideStart",t[t.UIShowStart=26]="UIShowStart",t[t.UIEndShowHide=27]="UIEndShowHide",t[t.ContextMenuOpen=28]="ContextMenuOpen",t[t.ContextMenuClose=29]="ContextMenuClose",t[t.ContextClick=30]="ContextClick",t[t.AboutClick=31]="AboutClick",t[t.OverlayClick=32]="OverlayClick",t[t.LogoClicked=33]="LogoClicked",t[t.HoverStart=34]="HoverStart",t[t.HoverEnd=35]="HoverEnd",t[t.StateChanged=36]="StateChanged",t[t.RebindComponent=37]="RebindComponent",t[t.SkipAd=38]="SkipAd",t[t.FocusStart=39]="FocusStart"}(s||(s={}))},6203:(t,i,e)=>{"use strict";var s;e.d(i,{Z:()=>n}),function(t){t[t.HoldStart=0]="HoldStart",t[t.HoldEnd=1]="HoldEnd",t[t.TapLeft=2]="TapLeft",t[t.TapRight=3]="TapRight",t[t.SwipeEnd=4]="SwipeEnd",t[t.SwipeMove=5]="SwipeMove",t[t.Scroll=6]="Scroll",t[t.Click=7]="Click"}(s||(s={}));const n=s},7263:(t,i,e)=>{"use strict";e.d(i,{P:()=>o});var s=e(5701),n=e(3020),r=e(7405);class o extends s._{constructor(t,i,e,s,n){super(),this.mediator=t,this.yn=i,this.bn=e,this.ui=n,this.In=this.yn.createElementByString(s)}getContainer(){return this.In}getCoordinates(t){const i=this.yn.getElementCoordinates(this.In);return this.ui&&t?((t&r.C.Top)===r.C.Top&&(i.clientY-=this.In.clientHeight),(t&r.C.Right)===r.C.Right&&(i.clientX+=this.In.clientWidth)):i.clientX+=i.width/2,i}showComponent(t=!1){if(!this.In||!this.In.parentElement)return;const i=(0,n.pv)(this.In.parentElement,"cnx-ui-btn")?this.In.parentElement:this.In;t&&(0,n.GF)(i)?(0,n.Ji)(i):(0,n.Ho)(i)}hideComponent(t=!1){if(!this.In||!this.In.parentElement)return;const i=(0,n.pv)(this.In.parentElement,"cnx-ui-btn")?this.In.parentElement:this.In;t&&!(0,n.GF)(i)?(0,n.U6)(i,(()=>(0,n.MV)(i))):(0,n.MV)(i)}destroy(){this.In.innerHTML="",this.In.style.display="none",this.bn.unregisterAll(this)}}},2631:(t,i,e)=>{"use strict";e.d(i,{s:()=>r});var s=e(6019),n=e(3020);class r extends s.Y{constructor(){super(...arguments),this.onClick=t=>{this.onInteractionHandler(t),this.onClickHandler(),this.addBoomEffect()}}addBoomEffect(){(0,n.cn)(this.In,"cnx-boom"),(0,n.Tp)(this.In),(0,n.cn)(this.In,"cnx-boom-anim");const t=i=>{"transform"===i.propertyName&&((0,n.IV)(this.In,"cnx-boom"),(0,n.IV)(this.In,"cnx-boom-anim"),this.In.removeEventListener("transitionend",t))};this.In.addEventListener("transitionend",t)}initComponent(){super.initComponent(),this.In.appendChild(this.yn.createElementByString('<cnx class="cnx-boom-elem"></cnx>'))}}},6019:(t,i,e)=>{"use strict";e.d(i,{Y:()=>r});var s=e(6203),n=e(7263);class r extends n.P{constructor(){super(...arguments),this.eventList=[s.Z[s.Z.Scroll],s.Z[s.Z.Click]],this.wn=!1,this.Sn=t=>{this.onInteractionHandler(t)},this.onBeforeClick=t=>{t.stopPropagation()},this.onClick=t=>{this.onInteractionHandler(t),this.onClickHandler(t)}}onInteractionHandler(t){t.stopPropagation()}onClickHandler(t){}initComponent(){this.wn=!0;const t={interactionstart:this.onBeforeClick,interaction:this.Sn,click:this.onClick};this.bn.register(this.In,this,this.bn,t),this.ui&&(this.subscribe(s.Z[s.Z.Click],this.bn,(()=>{this.onClickHandler()})),this.relay(s.Z[s.Z.Scroll],this.bn,this,this.mediator))}destroy(){this.unsubscribeAll(this.bn),super.destroy()}get isInitialized(){return this.wn}}},9040:(t,i,e)=>{"use strict";e.d(i,{h:()=>h});var s=e(8983),n=e(3020),r=e(9762),o=e(2631);class h extends o.s{constructor(){super(...arguments),this.eventList=[r.C[r.C.HoverStart],r.C[r.C.HoverEnd],r.C[r.C.FocusStart],...this.eventList],this.onStartHover=()=>{(0,n.cn)(this.In,s.Gj.HoverStart),(0,n.cn)(this.In,s.Gj.HoverEnd),this.ui&&this.In.addEventListener("transitionend",(()=>this.onEndHoverClick())),this.mediator.publish(this,r.C[r.C.HoverStart])},this.onEndHover=()=>{(0,n.IV)(this.In,s.Gj.HoverEnd),this.mediator.publish(this,r.C[r.C.HoverEnd])},this.Pn=()=>{this.mediator.publish(this,r.C[r.C.FocusStart]),this.onStartHover()},this.An=()=>{this.onEndHover()}}initComponent(){super.initComponent(),this.ui?(this.In.addEventListener("touchstart",this.onStartHover,{passive:!0}),this.In.addEventListener("touchend",this.onEndHover),this.In.addEventListener("touchcancel",this.onEndHover)):(this.In.addEventListener("mouseenter",this.onStartHover),(0,n.Iy)(this.In)&&(this.In.addEventListener("focusin",this.Pn),this.In.addEventListener("focusout",this.An)),this.In.addEventListener("mouseleave",this.onEndHover))}destroy(){this.ui?(this.In.removeEventListener("touchstart",this.onStartHover),this.In.removeEventListener("touchend",this.onEndHover),this.In.removeEventListener("touchcancel",this.onEndHover)):(this.In.removeEventListener("mouseenter",this.onStartHover),this.In.removeEventListener("mouseleave",this.onEndHover),(0,n.Iy)(this.In)&&(this.In.removeEventListener("focusin",this.Pn),this.In.removeEventListener("focusout",this.An))),super.destroy()}onInteractionHandler(t){this.onEndHoverClick()}onEndHoverClick(){(0,n.IV)(this.In,s.Gj.HoverEnd),(0,n.IV)(this.In,s.Gj.HoverStart),this.ui&&this.In.removeEventListener("transitionend",(()=>this.onEndHoverClick()))}}},9055:(t,i,e)=>{"use strict";e.d(i,{a:()=>h});var s=e(7332),n=e(3020),r=e(9762),o=e(9901);class h extends o.N{constructor(t,i,e,s,n=!1){super(t,i,e,s,n),this.xn=0,this.Tn=null,this.kn=!1,this.eventList=[r.C[r.C.DraggingStart],r.C[r.C.DraggingStopped]],this.Cn=t=>{this.cacheWidths(),this.En(this.Mn(t)),this.ui?this.In.addEventListener(this.Ln,this.Bn):this.yn.addEventListenerOnGlobal(this.Ln,this.Bn),this.onDragStart()},this.Bn=t=>{null===this.Tn&&(this.kn||(this.kn=!0,this.disableTransition()),this.Tn=this.yn.requestAnimationFrameHelper((()=>{const i=this.Rn+(this.Mn(t)-this.Dn);this.isValidTranslation()&&this.Vn(i),this.Tn=null})))},this.Fn=t=>{t.stopPropagation(),this.ui?this.In.removeEventListener(this.Ln,this.Bn):this.yn.removeEventListenerOnGlobal(this.Ln,this.Bn),this.kn=!1,this.enableTransition(),this.onDragEnd()},this.jn=t=>{const i=100*t.target.value/this.$n.max;this.onProgressChange(i),this.onDragStart(),this.onDragEnd()},this.Ln=n?"touchmove":"mousemove"}cacheDomElements(){super.cacheDomElements(),this.Un=this.In.getElementsByClassName("cnx-progress-handle")[0],this.$n=this.In.querySelector('input[type="range"]')}cacheWidths(){super.cacheWidths(),this.xn=this.Un.getBoundingClientRect().width/2}updateUi(t){super.updateUi(t);const i=this.getComputedTranslation(t);this.Un.style.transform=`translateX(${i-this.xn}px)`}onDragEnd(){this.mediator.publish(this,r.C[r.C.DraggingStopped])}onDragStart(){this.mediator.publish(this,r.C[r.C.DraggingStart])}Mn(t){return this.ui?t.touches.item(0).clientX:t.clientX}En(t){this.Rn=t-this.qn,this.Dn=t,this.Vn(this.Rn)}Vn(t){if(this.isValidTranslation()){const i=this.getComputedTranslation(t),e=0,n=this.Hn,r=0,o=100;this.updateUi(i),this.onProgressChange((0,s.dQ)(e,n,r,o,i))}}setProgress(t){if(super.setProgress(t),!this.$n)return;const i=Math.round(t/100*this.$n.max);this.$n.value=i}setMaxRange(t){this.$n.setAttribute("max",t.toString())}hideRangeInput(){this.$n&&(0,n.MV)(this.$n)}initComponent(){super.initComponent();const t={interactionstart:this.Cn,interactionend:this.Fn};this.bn.register(this.In,this,this.bn,t),this.$n&&(this.$n.addEventListener("input",this.jn),this.$n.addEventListener("change",this.jn))}destroy(){super.destroy(),this.$n&&(this.$n.removeEventListener("input",this.jn),this.$n.removeEventListener("change",this.jn))}}},7617:(t,i,e)=>{"use strict";e.d(i,{E:()=>r});var s=e(3020),n=e(8538);class r extends n.s{constructor(t,i,e,s){super(i,e,s),this.mediator=t,this.In=this.zn.getRenderedDom()}getContainer(){return this.In}initComponent(){this.zn.initComponents()}showComponent(){(0,s.Ho)(this.In)}hideComponent(){(0,s.MV)(this.In)}}},9901:(t,i,e)=>{"use strict";e.d(i,{N:()=>h});var s=e(7332),n=e(3020),r=e(8983),o=e(7263);class h extends o.P{constructor(t,i,e,s,n=!1){super(t,i,e,s,n),this.Hn=0,this.qn=null,this.Wn=0,this.Gn=0,this.Xn=100,this.cacheDomElements()}cacheDomElements(){this.Qn=this.In.getElementsByClassName("cnx-progress-fill")[0],this.Jn=this.In.getElementsByClassName("cnx-progress-rail")[0]}cacheWidths(){this.Hn=this.fixedRailWidth?this.fixedRailWidth:this.Jn.getBoundingClientRect().width,this.qn=this.Jn.getBoundingClientRect().left}updateUi(t){const i=this.getComputedTranslation(t);this.Wn=i,this.Qn.style.transform=`translateX(${i}px)`}isValidTranslation(){return this.Wn>=0&&this.Wn<=this.Hn}getComputedTranslation(t){return t<0?0:t>this.Hn?this.Hn:t}setProgress(t){this.cacheWidths();const i=this.getComputedTranslation((0,s.dQ)(0,100,0,this.Hn,t));this.updateUi(i)}disableTransition(){(0,n.cn)(this.In,r.Gj.NoTransition)}enableTransition(){(0,n.IV)(this.In,r.Gj.NoTransition)}Kn(t){this.disableTransition(),this.setProgress(t),(0,n.Tp)(this.Qn),this.enableTransition()}forceStartState(){this.Kn(this.Gn)}forceEndState(){this.Kn(this.Xn)}initComponent(){this.cacheWidths()}destroy(){super.destroy()}}},1e3:(t,i,e)=>{"use strict";e.d(i,{V:()=>h,q:()=>s});var s,n=e(9040),r=e(8983),o=e(9762);!function(t){t[t.expand=0]="expand",t[t.collapse=1]="collapse"}(s||(s={}));class h extends n.h{constructor(){super(...arguments),this.eventList=[o.C[o.C.Expand],o.C[o.C.Collapse],...this.eventList],this.Zn="Full Screen (f)",this.tr="Exit Full Screen (f)"}initComponent(){super.initComponent(),this.In&&this.In.setAttribute("aria-label",this.tooltip)}onClickHandler(){switch(this.ir){case s.collapse:this.mediator.publish(this,o.C[o.C.Expand]);break;case s.expand:this.mediator.publish(this,o.C[o.C.Collapse]);break;default:this.mediator.publish(this,o.C[o.C.Expand])}}sr(){this.In&&(this.In.setAttribute("aria-label",this.tooltip),this.ir===s.expand?this.In.classList.add(r.Gj.Active):this.In.classList.remove(r.Gj.Active))}setState(t){this.ir!==t&&(this.ir=t,this.sr())}get tooltip(){return this.ir===s.expand?this.tr:this.Zn}}},5637:(t,i,e)=>{"use strict";e.d(i,{Z:()=>r});var s=e(6019),n=e(2300);class r extends s.Y{constructor(t,i,e,s,r,o,h){super(t,i,e,s,r),this.tooltip=h,this.eventList=[],this.nr=n.r[o],this.eventList.push(this.nr)}onClickHandler(){this.mediator.publish(this,this.nr)}}},1458:(t,i,e)=>{"use strict";e.d(i,{c:()=>r});var s=e(9040),n=e(2300);class r extends s.h{constructor(t,i,e,s,r,o,h){super(t,i,e,s,r),this.tooltip=h,this.nr=n.r[o],this.eventList.push(this.nr)}onClickHandler(){this.mediator.publish(this,this.nr)}}},3894:(t,i,e)=>{"use strict";e.d(i,{Z:()=>p});var s=e(1215),n=e(2300),r=e(7936),o=e(6263),h=e(3669),a=e(3775);const c="More",d="Close Player",l="Next (Shift + N)",u="Previous (Shift + P)",p={[n.r[n.r.MoreButton]]:{template:(0,r.Z)(n.r.MoreButton,h,"",{hasPopup:!0,expanded:!1,label:c,controls:a.b.ContextMenuSettings}),tooltip:c,isHoverable:!0},[n.r[n.r.CloseButton]]:{template:(0,r.Z)(n.r.CloseButton,s,d),tooltip:d,isHoverable:!0},[n.r[n.r.PinnedCloseButton]]:{template:(0,r.Z)(n.r.CloseButton,s,d),tooltip:d,isHoverable:!0},[n.r[n.r.UpNextButton]]:{template:(0,r.Z)(n.r.UpNextButton,o,l),tooltip:l,isHoverable:!0},[n.r[n.r.PreviousButton]]:{template:(0,r.Z)(n.r.PreviousButton,o,u),tooltip:u,isHoverable:!0}}},6805:(t,i,e)=>{"use strict";e.d(i,{Z:()=>o});var s=e(2300),n=e(1458),r=e(5637);class o{constructor(t,i,e,n){this.yn=t,this.bn=i,this.ui=e,this.rr=new Map,Object.keys(n).forEach((t=>this.hr(s.r[t],n[t])))}getButton(t,i){const{isHoverable:e,template:s,tooltip:o}=this.ar(t);return e?new n.c(i,this.yn,this.bn,s,this.ui,t,o):new r.Z(i,this.yn,this.bn,s,this.ui,t,o)}isGeneralComponent(t){return this.rr.has(t)}ar(t){return this.rr.get(t)}hr(t,i){this.rr.set(t,i)}}},7936:(t,i,e)=>{"use strict";e.d(i,{Z:()=>n});var s=e(2300);function n(t,i,e,n=null,r=!0){if(r){const{expanded:r,hasPopup:o,label:h,controls:a}=n||{};return`\n        ${n?`<cnx aria-expanded=${r} aria-haspopup=${o} aria-controls=${a} aria-label="${h}" role="button" class="cnx-icon-button cnx-button-${s.r[t].toLowerCase()} cnx-ui-btn-hoverable" tabindex="0">`:`<cnx class="cnx-icon-button cnx-button-${s.r[t].toLowerCase()} cnx-ui-btn-hoverable" aria-label="${e}" role="button" tabindex="0">`}\n                <cnx class="cnx-btn-container">\n                    ${i}\n                </cnx>\n            </cnx>\n        `.trim()}return`<cnx class="cnx-button-${s.r[t].toLowerCase()}">${i}</cnx>`}},8092:(t,i,e)=>{"use strict";e.d(i,{z:()=>o});var s=e(7263),n=e(3020),r=e(8983);class o extends s.P{constructor(){super(...arguments),this.eventList=[]}initComponent(){this.hide()}show(){(0,n.Ho)(this.In),(0,n.Tp)(this.In),(0,n.cn)(this.In,r.Gj.Active)}hide(){(0,n.IV)(this.In,r.Gj.Active),(0,n.MV)(this.In)}}},4115:(t,i,e)=>{"use strict";e.d(i,{J:()=>o,L:()=>s});var s,n=e(9040),r=e(9762);!function(t){t[t.Play=0]="Play",t[t.Pause=1]="Pause"}(s||(s={}));class o extends n.h{constructor(t,i,e,n,o,h){super(t,i,e,n,o),this.isBig=h,this.cr=!1,this.eventList=[r.C[r.C.Play],r.C[r.C.Pause],r.C[r.C.Replay],r.C[r.C.StateChanged],...this.eventList],this.dr="Play (SPACE)",this.lr="Pause (SPACE)",this.setState(s.Pause)}onClickHandler(){this.ir===s.Pause?this.mediator.publish(this,r.C[r.C.Pause]):this.cr?this.mediator.publish(this,r.C[r.C.Replay]):this.mediator.publish(this,r.C[r.C.Play]),this.In.setAttribute("aria-label",this.tooltip)}sr(){this.ir===s.Play?this.In.setAttribute("aria-hidden","false"):this.isBig&&this.In.setAttribute("aria-hidden","true")}toggleReplay(t){this.cr=t}setState(t){this.ir!==t&&(this.ir=t,this.sr(),this.In.setAttribute("aria-label",this.tooltip),this.mediator.publish(this,r.C[r.C.StateChanged]))}get tooltip(){return this.ir===s.Play?this.dr:this.lr}}},4651:(t,i,e)=>{"use strict";e.d(i,{t:()=>r});var s=e(834),n=e(1639);function r(t=!1){return`\n    <cnx class="cnx-icon-button cnx-ui-btn-hoverable ${t?"cnx-button-big-play":""}" role="button" tabindex="0">\n        <cnx class="cnx-btn-container">\n            <cnx class="cnx-play-icon">${s}</cnx>\n            <cnx class="cnx-pause-icon">${n}</cnx>\n        </cnx>\n    </cnx>\n`.trim()}},6516:(t,i,e)=>{"use strict";e.d(i,{k:()=>c});var s=e(9055),n=e(8983),r=e(3020),o=e(9762),h=e(1310),a=e(4798);class c extends s.a{constructor(t,i,e,s,h=!1){super(t,i,e,s,h),this.ur=!1,this.pr=t=>{(0,r.cn)(this.In,n.Gj.HoverEnd),this.ur=!0},this.gr=t=>{const i=this.getComputedTranslation(t.clientX-this.qn);this.vr.style.transform=`translateX(${i}px)`},this.yr=t=>{this.vr.style.transform="translateX(0)",this.ur=!1,this.Ir()},this.eventList=this.eventList.concat([o.C[o.C.Seek],o.C[o.C.SeekingStart],o.C[o.C.SeekingStopped]])}onProgressChange(t){this.mediator.publish(this,o.C[o.C.Seek],{payload:t-.1})}updateWcagAttributes(t,i){if(!(0,a.hj)(t)||!(0,a.hj)(i))return;const e=(0,h.qt)(i),s=(0,h.qt)(t),n=this.$n;n&&(n.setAttribute("aria-label","Seek"),n.setAttribute("aria-valuemin","0"),n.setAttribute("aria-valuemax",`${Math.round(i)}`),n.setAttribute("aria-valuenow",`${Math.round(t)}`),n.setAttribute("aria-valuetext",`${s} of ${e}`))}onDragEnd(){super.onDragEnd(),this.mediator.publish(this,o.C[o.C.SeekingStopped]),this.Ir()}onDragStart(){super.onDragStart(),this.mediator.publish(this,o.C[o.C.SeekingStart])}Ir(){this.ur||this.kn||(0,r.IV)(this.In,n.Gj.HoverEnd)}initComponent(){super.initComponent(),this.In.addEventListener("mousemove",this.gr),this.In.addEventListener("mouseenter",this.pr),this.In.addEventListener("mouseleave",this.yr),this.vr=this.In.getElementsByClassName("cnx-progress-follow")[0]}hide(){this.In.style.opacity="0"}show(){this.In.style.opacity="1"}destroy(){super.destroy(),this.In.removeEventListener("mousemove",this.gr),this.In.removeEventListener("mouseenter",this.pr),this.In.removeEventListener("mouseleave",this.yr)}}},8029:(t,i,e)=>{"use strict";e.d(i,{r:()=>h});var s=e(7263),n=e(1310),r=e(8983),o=e(3020);class h extends s.P{constructor(){super(...arguments),this.eventList=[]}initComponent(){this.wr=this.In.getElementsByTagName("cnx-span")[0]}setTime(t){isNaN(t)||"number"!=typeof t?(0,o.cn)(this.In,r.Gj.Invisible):(this.wr.innerHTML=(0,n.to)(t),(0,o.IV)(this.In,r.Gj.Invisible))}}},52:(t,i,e)=>{"use strict";e.d(i,{a:()=>a});var s=e(3093),n=e(7405),r=e(3020),o=e(5356),h=e(8983);class a{constructor(t,i,e){this.Sr=t,this.yn=i,this.Pr=[],this.Ar={top:12,bottom:24,margin:4},this._r=!1,e&&(this._r=!0)}Tr(){this.kr=this.yn.getElementCoordinates(this.Sr.parentElement)}Cr(t,i){t.getElementsByClassName("cnx-tooltip-text")[0].innerHTML=i}Er(t){if(!t||!t.tooltip||this._r)return;if(this.Pr.find((i=>i.component===t)))return;const i=this.yn.createElementByString(s.Z);this.Cr(i,t.tooltip),this.Tr();const e=t.getCoordinates();let a=!1;const{clientY:c,height:d}=e,{clientY:l,height:u}=this.yn.getElementCoordinates(this.Sr);!(0,r.pv)(this.Sr,h.s6.ShowControls)&&!(0,o.mb)(this.Sr)||c<=l+u/2-d?e.clientY+=this.Ar.top:(e.clientY-=this.Ar.bottom,a=!0),this.Sr.appendChild(i),(0,n.p)(i,e,this.kr,{alignMiddle:!0,alignTop:a,forceRight:!0,distanceFromMargin:this.Ar.margin}),(0,r.Tp)(i),(0,r.cn)(i,h.hQ.OpacityInTransition),this.Pr.push({component:t,domElement:i})}Mr(t){if(!t.tooltip)return;const i=this.Pr.find((i=>i.component===t));if(!i)return;const e=i.domElement;this.Sr.removeChild(e),this.Pr=this.Pr.filter((i=>i.component!==t))}Lr(t){if(!t.tooltip)return;const i=this.Pr.find((t=>t.component===this.Br));i&&this.Cr(i.domElement,t.tooltip)}Rr(){this.Br=null,this.Pr.forEach((t=>this.Mr(t.component)))}removeActiveTooltip(){this.Br&&this.Mr(this.Br)}setDistanceValues(t){this.Ar=Object.assign(Object.assign({},this.Ar),t)}hoverStart(t){this.removeActiveTooltip(),this.Br=t,this.Er(t)}hoverEnd(t){this.Br=null,this.Mr(t)}stateChanged(t){this.Br===t&&this.Lr(t)}disableTooltips(){this._r=!0,this.Rr()}enableTooltips(){this._r=!1,this.Er(this.Br)}}},1191:(t,i,e)=>{"use strict";e.d(i,{F:()=>h,u:()=>s});var s,n=e(3020),r=e(9762),o=e(9040);!function(t){t[t.Mute=0]="Mute",t[t.Unmute=1]="Unmute"}(s||(s={}));class h extends o.h{constructor(t,i,e,s,n,o){super(t,i,e,s,o),this.eventList=[r.C[r.C.Mute],r.C[r.C.Unmute],r.C[r.C.StateChanged],...this.eventList],this.Or="Mute (m)",this.Dr="Unmute (m)",this.ir=n,this.In.setAttribute("aria-label",this.tooltip)}onClickHandler(){this.ir===s.Mute?(this.mediator.publish(this,r.C[r.C.Unmute]),this.setState(s.Unmute)):(this.mediator.publish(this,r.C[r.C.Mute]),this.setState(s.Mute))}sr(){this.ir===s.Mute?(0,n.L_)(this.In,"cnx-sound-on","cnx-sound-off"):(0,n.L_)(this.In,"cnx-sound-off","cnx-sound-on")}get tooltip(){return this.ir===s.Mute?this.Dr:this.Or}initComponent(){super.initComponent(),this.sr()}setState(t){this.ir!==t&&(this.ir=t,this.sr(),this.In.setAttribute("aria-label",this.tooltip),this.mediator.publish(this,r.C[r.C.StateChanged]))}setVolume(t){t>0?this.setState(s.Unmute):this.setState(s.Mute)}}},1277:(t,i,e)=>{"use strict";e.d(i,{N:()=>c});var s=e(1191),n=e(7617),r=e(3020),o=e(9762),h=e(2300),a=e(8983);class c extends n.E{constructor(t,i,e,s){super(t,i,e,s),this.Vr=null,this.eventList=[o.C[o.C.Volume],o.C[o.C.VolumeHoverStart],o.C[o.C.VolumeHoverStopped],o.C[o.C.DraggingStopped],o.C[o.C.DraggingStart],o.C[o.C.HoverStart],o.C[o.C.HoverEnd],o.C[o.C.StateChanged],o.C[o.C.FocusStart]],this.Fr=.2,this.Nr=600,this.jr=!1,this.$r=t=>{clearTimeout(this.Vr),(0,r.cn)(this.In,"cnx-mod-hover"),this.mediator.publish(this,o.C[o.C.VolumeHoverStart])},this.Ur=()=>{this.jr||(null!==this.Vr&&clearTimeout(this.Vr),this.Vr=setTimeout((()=>{(0,r.IV)(this.In,"cnx-mod-hover"),this.mediator.publish(this,o.C[o.C.VolumeHoverStopped])}),this.Nr))},this.Pn=()=>{(0,r.cn)(this.In,"cnx-mod-hover"),this.mediator.publish(this,o.C[o.C.FocusStart]),this.mediator.publish(this,o.C[o.C.VolumeHoverStart])},this.An=()=>{(0,r.IV)(this.In,"cnx-mod-hover"),this.mediator.publish(this,o.C[o.C.VolumeHoverStopped])},this.qr=this.Fr,this.Hr=this.getComponent(h.r.VolumeButton),this.zr=this.getComponent(h.r.VolumeProgress),(0,r.IV)(this.Hr.getContainer(),a.Gj.HovarableButton)}Wr(t,i,e){let s;switch(t){case o.C[o.C.Volume]:s=i.payload/100,this.Gr(s),this.Xr(i.payload);break;case o.C[o.C.Mute]:s=0,this.setVolumeProgress(0);break;case o.C[o.C.Unmute]:s=this.qr,this.setVolumeProgress(100*this.qr);break;case o.C[o.C.DraggingStopped]:this.jr=!1,this.mediator.publish(this,o.C[o.C.DraggingStopped]),this.Ur();break;case o.C[o.C.DraggingStart]:this.jr=!0,this.mediator.publish(this,o.C[o.C.DraggingStart]);break;case o.C[o.C.HoverStart]:this.mediator.publish(this,o.C[o.C.HoverStart],{payload:{targetComponent:e}});break;case o.C[o.C.HoverEnd]:this.mediator.publish(this,o.C[o.C.HoverEnd],{payload:{targetComponent:e}});break;case o.C[o.C.StateChanged]:this.mediator.publish(this,o.C[o.C.StateChanged],{payload:{targetComponent:e}})}void 0!==s&&this.Qr(s)}Gr(t){t<this.Fr?this.qr=this.Fr:this.qr=t}Qr(t){this.mediator.publish(this,o.C[o.C.Volume],{payload:t})}Xr(t){0===t?this.Hr.setState(s.u.Mute):this.Hr.setState(s.u.Unmute)}setVolumeProgress(t){this.zr.setProgress(t)}initComponent(){super.initComponent(),this.In.addEventListener("mouseenter",this.$r),this.In.addEventListener("mouseleave",this.Ur),this.In.addEventListener("focusin",this.Pn),this.In.addEventListener("focusout",this.An)}setVolume(t){const i=100*t;this.Xr(i),this.setVolumeProgress(i)}destroy(){super.destroy(),this.In.removeEventListener("mouseenter",this.$r),this.In.removeEventListener("mouseleave",this.Ur),this.In.removeEventListener("focusin",this.Pn),this.In.removeEventListener("focusout",this.An)}}},9391:(t,i,e)=>{"use strict";e.d(i,{Z:()=>n});var s=e(2300);const n=`\n    <cnx class="cnx-volume-container">\n        <cnx class="cnx-ui-btn cnx-volume-btn">\n            [[${s.r.VolumeButton}]]\n        </cnx>\n        <cnx class="cnx-volume-bar">\n            [[${s.r.VolumeProgress}]]\n        </cnx>\n    </cnx>\n`.trim()},3356:(t,i,e)=>{"use strict";e.d(i,{J:()=>r});var s=e(9055),n=e(9762);class r extends s.a{constructor(t,i,e,s,r=!1){super(t,i,e,s,r),this.Jr=80,this.fixedRailWidth=this.Jr,this.eventList.push(n.C[n.C.Volume])}onProgressChange(t){this.mediator.publish(this,n.C[n.C.Volume],{payload:t})}setProgress(t){this.In.setAttribute("aria-valuenow",t.toString()),super.setProgress(t)}initComponent(){this.In.setAttribute("role","slider"),super.initComponent()}}},2823:(t,i,e)=>{"use strict";e.d(i,{$:()=>o});var s=e(8983),n=e(3020),r=e(8538);class o extends r.s{constructor(t,i,e,s,n){super(e,s,n),this.mediator=t,this.$container=i,this.$uiContainer=this.zn.getRenderedDom(),i.appendChild(this.$uiContainer),this.zn.initComponents()}changeState(t){const i=this.Yr[t];i!==this.currentState&&this.currentState.canTransitionToState(i)&&(this.currentState.exitState(i),i.enterState())}hide(){(0,n.cn)(this.$uiContainer,s.Gj.DisplayNone)}show(){(0,n.IV)(this.$uiContainer,s.Gj.DisplayNone)}destroy(){super.destroy(),this.$uiContainer.parentNode.removeChild(this.$uiContainer)}}},244:(t,i,e)=>{"use strict";e.d(i,{A:()=>I});var s=e(2300),n=e(4651),r=e(4115),o=e(3356),h=e(5616),a=e(1e3),c=e(3225),d=e(8092),l=e(852),u=e(6805),p=e(3894),f=e(8029),m=e(9268),g=e(6516),v=e(9735),y=e(1191),b=e(2390);class I{constructor(t,i,e,I={},w={}){this.yn=t,this.bn=i,this.In=e,this.ci=I,this.Kr={[s.r.PlayButton]:t=>this.io(!1,t),[s.r.BigPlayButton]:t=>this.io(!0,t),[s.r.VolumeProgress]:t=>new o.J(t,this.yn,this.bn,h.Z),[s.r.ExpandButton]:t=>new a.V(t,this.yn,this.bn,c.Z,this.ci.isMobile),[s.r.Loader]:t=>new d.z(t,this.yn,this.bn,l.Z),[s.r.ElapsedTimeLabel]:t=>new f.r(t,this.yn,this.bn,m.Z),[s.r.TotalDurationLabel]:t=>new f.r(t,this.yn,this.bn,m.Z),[s.r.RemainingDurationLabel]:t=>new f.r(t,this.yn,this.bn,m.Z),[s.r.ProgressBar]:t=>new g.k(t,this.yn,this.bn,v.Z,this.ci.isMobile),[s.r.VolumeButton]:t=>new y.F(t,this.yn,this.bn,b.Z,y.u.Mute,this.ci.isMobile)},this.io=(t,i)=>new r.J(i,this.yn,this.bn,(0,n.t)(t),this.ci.isMobile,t),this.eo=t=>i=>{const e=this.Kr[t];if(e)return e(i)},this.so=new u.Z(this.yn,this.bn,this.ci.isMobile,Object.assign(Object.assign({},p.Z),w))}createComponent(t,i){const e=this.eo(t)(i);return e||(this.so.isGeneralComponent(t)?this.so.getButton(t,i):void 0)}}},8538:(t,i,e)=>{"use strict";e.d(i,{s:()=>o});var s=e(5701),n=e(8364),r=e(9762);class o extends s._{constructor(t,i,e){super(),this.globalDomUtilsService=t,this.templateString=i,this.componentFactory=e,this.no={},this.zn=new n.B(i,t),this.addComponents()}addComponents(){this.zn.getComponentList().forEach((t=>{const i=this.componentFactory.createComponent(t,this);this.registerComponent(t,i)}))}registerComponent(t,i){this.zn.registerSlot(t,i),this.no[t]=i,this.ro(i)}ro(t){t.eventList.forEach((i=>{this.subscribe(i,t,(e=>{i===r.C[r.C.RebindComponent]&&this.oo(t),this.Wr(i,e,t)}))}))}oo(t){t&&(this.unsubscribeAll(t),this.ro(t))}getComponent(t){return this.no[t]}destroy(){Object.keys(this.no).forEach((t=>{this.no[t].destroy()}))}}},6664:(t,i,e)=>{"use strict";e.d(i,{q:()=>l});var s=e(2823),n=e(52),r=e(9762),o=e(3020),h=e(2300),a=e(7332),c=e(8983),d=e(1e3);class l extends s.${constructor(t,i,e,s,r={},o){super(o,t,i,e,s),this.ho=new n.a(this.$uiContainer,i,r.isMobile)}Wr(t,i,e){let s=e;switch(i.payload&&i.payload.targetComponent&&(s=i.payload.targetComponent),t){case r.C[r.C.HoverStart]:this.ho.hoverStart(s);break;case r.C[r.C.HoverEnd]:this.ho.hoverEnd(s);break;case r.C[r.C.StateChanged]:this.ho.stateChanged(s)}}updateDuration(t,i){const e=this.getComponent(h.r.ProgressBar);if(null==e||e.updateWcagAttributes(t,i),!(0,o.pv)(this.$uiContainer,c.s6.ShowControls))return;const s=this.getComponent(h.r.ElapsedTimeLabel),n=this.getComponent(h.r.TotalDurationLabel);if(s&&s.setTime(t),n&&n.setTime(i),e){const s=0,n=i,r=0,o=100;e.setMaxRange(Math.round(i)),e.setProgress((0,a.dQ)(s,n,r,o,t))}}updateVolume(t){}expand(){this.getComponent(h.r.ExpandButton).setState(d.q.expand)}collapse(){this.getComponent(h.r.ExpandButton).setState(d.q.collapse)}}},8364:(t,i,e)=>{"use strict";e.d(i,{B:()=>s});class s{constructor(t,i){this.ao=t,this.yn=i,this.co=/\[\[([0-9]+)]]/g,this.uo=[],this.po=[],this.fo=this.yn.createElementByString(this.mo(this.ao))}vo(t){return`<cnx class="pl_${t}"></cnx>`}mo(t){return t.replace(this.co,((t,i)=>(this.uo.push(parseInt(i,10)),this.vo(i))))}yo(t,i){return this.po.some((i=>i.slotName===t))||this.po.some((t=>t.component===i))?null:this.fo.getElementsByClassName(`pl_${t}`)[0]}getComponentList(){return this.uo}getRenderedDom(){return this.fo}registerSlot(t,i){const e=this.yo(t,i);if(null!==e){const s=i.getContainer();return e.parentNode.replaceChild(s,e),this.po.push({component:i,slotName:t}),!0}return!1}initComponents(){this.po.forEach((t=>t.component.initComponent()))}}},2925:(t,i,e)=>{"use strict";e.d(i,{w:()=>s});class s{constructor(t){this.bo=t}onClick(){}canTransitionToState(t){return!0}enterState(){this.initState(),this.bo.currentState=this}}},4291:(t,i,e)=>{"use strict";e.d(i,{d:()=>h});var s=e(2300),n=e(4115),r=e(8983),o=e(2925);class h extends o.w{initState(){var t;this.bo.$uiContainer.classList.add(r.s_.Paused);const i=this.bo.getComponent(s.r.PlayButton);i&&i.setState(n.L.Play);const e=this.bo.getComponent(s.r.BigPlayButton);e&&(null===(t=e.getContainer())||void 0===t||t.setAttribute("tabindex","0"),e.setState(n.L.Play))}exitState(){var t;const i=this.bo.getComponent(s.r.BigPlayButton);null===(t=null==i?void 0:i.getContainer())||void 0===t||t.removeAttribute("tabindex"),this.bo.$uiContainer.classList.remove(r.s_.Paused)}}},2246:(t,i,e)=>{"use strict";e.d(i,{_:()=>h});var s=e(2300),n=e(4115),r=e(8983),o=e(2925);class h extends o.w{initState(){this.bo.$uiContainer.classList.add(r.s_.Playing);const t=this.bo.getComponent(s.r.PlayButton);t&&t.setState(n.L.Pause);const i=this.bo.getComponent(s.r.BigPlayButton);i&&i.setState(n.L.Pause)}exitState(){this.bo.$uiContainer.classList.remove(r.s_.Playing)}}},7405:(t,i,e)=>{"use strict";var s;function n(t,i,e,s){t.style.top=`${function(t,i,e,s,n){let r=i-s.clientY;const o=s.clientY+s.height-i;n.alignTop&&r>t.offsetHeight?r-=t.offsetHeight:!n.alignTop&&o<t.offsetHeight?r-=t.offsetHeight-o:(r+=e,r+t.offsetHeight>s.height&&(r=s.height-t.offsetHeight));return r}(t,i.clientY,i.height,e,s)}px`,t.style.left=`${function(t,i,e,s){const n=s.distanceFromMargin?s.distanceFromMargin:0;let r=Math.ceil(i)-Math.ceil(e.clientX),o=i,h=o+t.offsetWidth;const a=e.clientX+e.width;if(s.alignMiddle){const i=t.offsetWidth/2;r-=Math.ceil(i),o-=i,h-=i}if(s.alignMiddle||s.forceRight)return e.clientX>o?r=0+n:a<h&&(r-=Math.ceil(h)-Math.ceil(a)+n),r;h>a&&(r-=t.offsetWidth);return r}(t,i.clientX,e,s)}px`}e.d(i,{C:()=>s,p:()=>n}),function(t){t[t.Top=1]="Top",t[t.Bottom=2]="Bottom",t[t.Right=4]="Right",t[t.Left=8]="Left",t[t.Middle=16]="Middle"}(s||(s={}))},7175:()=>{String.prototype.cnx_replaceAll=function(t,i){return this.split(t).join(i)}},3326:(t,i,e)=>{"use strict";e.d(i,{A:()=>p,u:()=>u});var s=e(6224),n=e(289),r=e(6153),o=e(4798),h=e(1187);const a=new s.t(n.ProtoAdDomainBlockingResponse,"AdDomainBlockingService"),c=2;let d;const l=new Map;function u(t){d||(d=new Promise((i=>{const e=t.find((t=>t.blockedDomainsRevisionNumber));if(!e)return void i();const{publisherLineItemId:s,blockedDomainsRevisionNumber:n}=e,o=`${r.n.endPoints.base.lineItems}${s}/blockedDomains_${n}.bin`;a.fetchMetadata(o,c).then((t=>{l.set(s,t.domains),i()})).catch((()=>{(0,h.n)({message:"AdDomainBlockingService_fetchBlockedDomains_endpoint_unavailable",level:h.D.CRITICAL},{throttle:2,shouldSendMaxLog:!1}),i()}))})))}function p(t,i){return new Promise((e=>{(0,o.QM)(i)?d.then((()=>{l.has(t)&&l.get(t).some((t=>i.includes(t)))?e(!0):e(!1)})):e(!1)}))}},9906:(t,i,e)=>{"use strict";e.d(i,{h:()=>n});var s=e(8659);class n{static getInstance(){return this.Io||(this.Io=new n),this.Io}static getGlobalContainer(){return this.getInstance().globalContainer}static getSessionChildContainer(t){const i=n.wo.get(t);return i||n.So(t)}constructor(t=s.nC){this.Po=t}get globalContainer(){return this.Po}static So(t){const i=n.getGlobalContainer().createChildContainer();return n.wo.set(t,i),i}}n.wo=new Map},6661:(t,i,e)=>{"use strict";var s;e.d(i,{c:()=>s}),function(t){t.GeneralMetadata="GeneralMetadata",t.UserManagerService="UserManagerService",t.Temp="TempDataForSS",t.OmidSettings="OmidSettings",t.EventsStorageService="EventsStorageService",t.OmsdkImplementationType="OmsdkImplementationType",t.GlobalDomUtilsService="GlobalDomUtilsService",t.ExternalPrebidJSPermutiveConfig="ExternalPrebidJSPermutiveConfig"}(s||(s={}))},6153:(t,i,e)=>{"use strict";e.d(i,{n:()=>c});var s=e(51),n=e(7945),r=e(9791),o=e(4798);class h{constructor(t){this.base=t,this.api={pls:t.core+"core/pls",story:t.core+"core/story",rtb:t.core+"rtb/g",syncUrls:t.core+"core/us",fallbackstory:t.core+"core/fallbackstory",cookie:t.core+"core/ck",tam:t.core+"core/atam"},this.tracking={session_rendered:t.tracking+"sr",session_view:t.tracking+"sv",session_time:t.tracking+"st",session_client_error:t.tracking+"e",media_quartile:t.tracking+"mq",media_click:t.tracking+"mc",ad_impression:t.tracking+"ai",bids:t.tracking+"abt",ad_impression_viewable:t.tracking+"av",ad_quartile:t.tracking+"aq",ad_click:t.tracking+"ac",playerStart:t.tracking+"ps",adOpportunity:t.tracking+"ao",sessionAdBlocker:t.tracking+"sab",heavy_ad_intervention:t.tracking+"ha",auctionInformation:t.tracking+"aucinfo"},this.assets={css:{elements:`${this.Ao(t.assets)}player.css`,playspace:`${this.Ao(t.assets)}connatix.playspace.css`},plugins:{adobeAnalytics:`${t.plugins}p/plugins/adobe.plugin.js`,moatAnalytics:`${t.plugins}p/plugins/moat.plugin.js`,prebidScript:`${t.plugins}p/plugins/prebid7.17.0-7.js`,apstagScript:`${t.plugins}p/plugins/apstag22.10.131733.js`,omsdkSessionClient:`${t.plugins}p/plugins/connatix.omsdk.session.client-1.4.2.js`,omsdkWebService:`${t.plugins}p/plugins/connatix.omsdk.service-web.js`}}}Ao(t){return`${t}p/${n.g.version}/`}}var a=e(1187);class c{static set bundleDomain(t){this._o=t}static get bundleDomain(){if(!(0,o.QM)(this._o))throw new Error("bundleDomain missing");return this._o}static get defaultVideoPosterURL(){return this.xo}static set defaultVideoPosterURL(t){this.xo=t}static get tier(){return null===this.To?((0,a.n)({message:"EndpointResolver_no_tier_specified",level:a.D.INFO},{throttle:10,shouldSendMaxLog:!1}),c.DEFAULT_TIER):this.To}static setTier(t){this.To=t,c.ko=c.Co()}static Eo(t){const i=`capi{{env}}.${t}`;return{video:`//vid.${t}/`,image:`//img.${t}/`,core:`https://${i}/`,tracking:`https://${i}/tr/`,metadata:`//vid.${t}/`,insights:`//ins.${t}/`,assets:`//cds{{env}}.${t}/`,plugins:`//cds.${t}/`,lineItems:`//lit.${t}/`}}static Co(){const t=(0,s.Ph)("cnxEnv",(0,r.pE)(window).topFrame.location.href);t&&(n.g.domainPrefix=`-${t}`);const i=this.Eo(this.bundleDomain);return Object.keys(i).forEach((t=>{i[t]=i[t].replace("{{env}}",n.g.domainPrefix)})),new h(i)}static get endPoints(){return null===c.ko&&(c.ko=c.Co()),c.ko}}c.DEFAULT_TIER=2,c.To=null,c.xo="",c.ko=null},5687:(t,i,e)=>{"use strict";e.d(i,{m:()=>d});var s=e(8211),n=e(6153),r=e(5650),o=e(3020),h=e(9791),a=e(1187),c=e(4798);class d{constructor(t){this.createElement=(t,i=this.Ci)=>i.document.createElement(t),this.Ci=t,this.addPreconnect()}get global(){return this.Ci}addCssString(t,i=""){return(0,o.uc)(t,i,this.Ci)}addPreconnect(){(0,o.tp)(n.n.endPoints.base.video,this.Ci),(0,o.tp)(n.n.endPoints.base.core,this.Ci),(0,o.tp)(n.n.endPoints.base.image,this.Ci)}getLineHeightPropertyValue(t){return(0,o.Dx)(t,this.Ci).getPropertyValue("line-height")}getFontSizePropertyValue(t){return(0,o.Dx)(t,this.Ci).getPropertyValue("font-size")}getFontWeightPropertyValue(t){return(0,o.Dx)(t,this.Ci).getPropertyValue("font-weight")}getTransformPropertyValue(t){return(0,o.Dx)(t,this.Ci).getPropertyValue("transform")}getPaddingTopPropertyValue(t){return(0,o.Dx)(t,this.Ci).getPropertyValue("padding-top")}getPaddingBottomPropertyValue(t){return(0,o.Dx)(t,this.Ci).getPropertyValue("padding-bottom")}getMarginTopPropertyValue(t){return(0,o.Dx)(t,this.Ci).getPropertyValue("margin-top")}getMarginBottomPropertyValue(t){return(0,o.Dx)(t,this.Ci).getPropertyValue("margin-bottom")}getMarginLeftPropertyValue(t){return(0,o.Dx)(t,this.Ci).getPropertyValue("margin-left")}getMarginRightPropertyValue(t){return(0,o.Dx)(t,this.Ci).getPropertyValue("margin-right")}createElementByString(t,i=this.Ci){return(0,o.G$)(t,i)}createDocumentFragment(t=this.Ci){return t.document.createDocumentFragment()}isHttpsProtocolUsed(){return(0,o.eA)(this.Ci)}isURLSameDomainToTop(t){return(0,o.uh)(t,this.Ci)}isDetachedFromDOM(t){let i=t;for(;i.parentNode;)if(i=i.parentNode,i===this.Ci.document.body)return!1;return!0}hasIosFullscreenBehaviour(t){return t&&t===s.M.Ios||!this.getFullscreenKeys()}querySelector(t,i=this.Ci){let e;try{e=i.document.querySelector(t)}catch(t){}return e}addCssStylesheetToHead(t,i,e){const s=this.Ci.document;s.getElementById(t.id)?(0,c.mf)(i)&&i():(0,o.NS)(t,s.head,this.Ci,i,e)}getFullscreenKeys(t){return(0,o.S0)(t||this.Ci.document)}exitFullscreen(t,i){(i||this.Ci.document)[t]()}getDocumentProperty(t){return this.Ci.document[t]}addEventListenerOnGlobal(t,i,e,s=!1){(e?this.Ci.document:this.Ci).addEventListener(t,i,s)}removeEventListenerOnGlobal(t,i,e,s=!1){(e?this.Ci.document:this.Ci).removeEventListener(t,i,s)}trackWithImages(t,i){(0,h.Hh)(t,this.Ci,i)}getElementCoordinates(t){let{top:i,left:e}=t.getBoundingClientRect();const{width:s,height:n}=t.getBoundingClientRect();return i+=this.Ci.pageYOffset,e+=this.Ci.pageXOffset,{clientX:e,clientY:i,width:s,height:n}}getElementDistanceToViewport(t){const{top:i,left:e}=t.getBoundingClientRect();return{top:i,left:e}}requestAnimationFrameHelper(t){return(0,o.PM)(this.Ci,t)}cancelRequestAnimationFrame(t){return(0,o.h_)(this.Ci,t)}getGlobalLocationProperties(){const t=this.Ci.location;return{hostname:t.hostname,pathname:t.pathname,href:t.href,protocol:t.protocol,host:t.host,port:t.port,search:t.search,hash:t.hash}}open(t,i){this.Ci.open(t,i)}getComputedTranslateX(t){let i=0;const e=(0,o.Dx)(t,this.Ci).getPropertyValue("transform").match(/^matrix\((.+)\)$/);return(0,r.BZ)(e)&&(i=parseFloat(e[1].split(", ")[4])),i}getBodyDimensions(){try{const t=(0,h.pE)(this.Ci).topFrame.document.body;let{offsetWidth:i,offsetHeight:e}=t;const s=(0,o.Dx)(t,this.Ci);return i+=parseInt(s.marginLeft,10)+parseInt(s.marginRight,10),e+=parseInt(s.marginTop,10)+parseInt(s.marginBottom,10),{width:i,height:e}}catch(t){return(0,a.n)({message:"DomUtils_error_getting_body_dimensions",exception:t.message,callStack:t.stack,level:a.D.CRITICAL}),{width:0,height:0}}}getViewportWidth(){return(0,h.pE)(this.Ci).topFrame.document.documentElement.clientWidth}getViewportHeight(){return(0,h.pE)(this.Ci).topFrame.innerHeight}getGlobalClosestTop(){return(0,h.pE)(this.Ci)}stripHtmlTags(t){return(0,o.ju)(t,this.Ci)}getComputedStyle(t,i){return(0,o.Dx)(t,this.Ci,i)}getElementById(t){return(0,o.rI)(t,this.Ci)}getElementsByClassName(t){return(0,o.Fs)(t,this.Ci)}insertScript(t,i,e){this.Ci.document.getElementById(t.id)?(0,c.mf)(i)&&i():(0,o.dZ)(t,this.Ci.document.head,this.Ci,i,null,!0,e)}destroy(){}}},6666:(t,i,e)=>{"use strict";e.d(i,{k:()=>u});var s=e(6224),n=e(289),r=e(6153),o=e(1187),h=e(1992),a=e(9791),c=e(4798),d=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};const l={insights:[],sentimentAnalysis:void 0};class u{static loadInsights(t){const{id:i}=t;let e=u.insightsPromiseStore.get(i);return e||(e=new Promise((i=>{const e=u.requestUrlBuilder(t);u.mediaMetadataHandler.fetchMetadata(e,2,false,1e4).then((t=>{const e=t.insights.map((t=>t.key));i({insights:e,sentimentAnalysis:t.sentimentAnalysis})})).catch((t=>{(0,a.Vm)([95,5])&&(0,o.n)({message:"LoadInsightIndexesService_endpoint_unavailable",exception:e,callStack:`${t}`,level:o.D.WARN},{shouldSendMaxLog:!1}),i(l)}))})),u.insightsPromiseStore.set(i,e)),e}static loadPageInsights(t){return d(this,void 0,void 0,(function*(){const i=yield u.loadInsights(t);return u.pageInsights={insights:i.insights},u.pageInsights}))}static requestUrlBuilder({insightsInputType:t,id:i,versionId:e}){return t===h.i.Page||(0,c.$K)(e)||(0,o.n)({message:"LoadInsightIndexesService_requestUrlBuilder_noVersionIdProvided",exception:`Type: ${t}, id: ${i}`,level:o.D.CRITICAL}),t===h.i.Page?`${r.n.endPoints.base.insights}${i}/insights.bin`:`${r.n.endPoints.base.insights}${i}/${e}/insights.bin`}static markAsUnavailable(t){u.insightsPromiseStore.get(t)||u.insightsPromiseStore.set(t,Promise.resolve(l))}}u.mediaMetadataHandler=new s.t(n.ProtoInsightsResponse,"InsightsLoaderService"),u.insightsPromiseStore=new Map},1992:(t,i,e)=>{"use strict";var s;e.d(i,{i:()=>s}),function(t){t[t.Video=0]="Video",t[t.Story=1]="Story",t[t.Page=2]="Page"}(s||(s={}))},8230:(t,i,e)=>{"use strict";var s,n,r,o;e.d(i,{Av:()=>o,HT:()=>n,WR:()=>r,qs:()=>s}),function(t){t[t.X=0]="X",t[t.Y=1]="Y"}(s||(s={})),function(t){t.Click="click",t.InteractionStart="interactionstart",t.Interaction="interaction",t.InteractionEnd="interactionend"}(n||(n={})),function(t){t[t.Swipe=0]="Swipe",t[t.Hold=1]="Hold"}(r||(r={})),function(t){t[t.Left=0]="Left",t[t.Right=1]="Right"}(o||(o={}))},7187:(t,i,e)=>{"use strict";e.d(i,{k:()=>u});var s=e(8983),n=e(6203),r=e(8230),o=e(5650),h=e(3020);const a={MAIN:0,AUXILIARY:1,SECONDARY:2,FOURTH:3,FIFTH:4};function c(t){return t.button===a.MAIN}var d=e(7332),l=e(4798);class u{constructor(t,i,e){this.Mo=t,this.ui=i,this.mediator=null,this.Lo=30,this.Bo=250,this.Ro=25,this.Oo=[],this.Do={},this.Vo=0,this.Fo=0,this.jo=!0,this.$o=null,this.Uo=!1,this.zo=!1,this.Wo=!1,this.Go=!1,this.Xo=0,this.Qo=0,this.Jo=null,this.Tn=null,this.Yo=null,this.Ko=!0,this.Zo=!1,this.th=t=>{this.ui?(t.element.addEventListener("touchstart",this.ih,{passive:!0}),t.element.addEventListener("touchmove",this.eh,{passive:!0}),t.element.addEventListener("touchend",this.sh),t.element.addEventListener("touchcancel",this.nh),t.element.addEventListener("mouseup",this.rh)):(t.element.addEventListener("mousedown",this.oh),t.element.addEventListener("mouseup",this.rh))},this.hh=t=>{this.ui?(t.element.removeEventListener("touchstart",this.ih),t.element.removeEventListener("touchmove",this.eh),t.element.removeEventListener("touchend",this.sh),t.element.removeEventListener("touchcancel",this.nh),t.element.removeEventListener("mouseup",this.rh)):(t.element.removeEventListener("mousedown",this.oh),t.element.removeEventListener("mouseup",this.rh))},this.ih=t=>{t.stopPropagation();const i=this.ah(t);this.Yo=i,this.zo=!1,this.dh(i,r.WR.Hold)&&this.lh(t);const e=this.ph(t);this.Fo=e.eventX,this.Vo=e.eventY,this.fh(t,i,r.HT.InteractionStart),this.jo=!0},this.eh=t=>{t.stopPropagation();const i=this.ah(t),e=this.ph(t);if(this.jo&&(Math.abs(e.deltaXFromStart)>this.Ro||Math.abs(e.deltaYFromStart)>this.Ro)&&(this.jo=!1),this.Uo||this.dh(i,r.WR.Swipe)){if(null===this.Jo&&this.mh(i,e),this.Jo===r.qs.Y)return;null===this.Tn&&(this.Tn=(0,h.PM)(this.Mo,(()=>{this.Tn=null,this.gh(e.deltaXFromStart),i.mediator.publish(i.context,n.Z[n.Z.SwipeMove],{payload:e.deltaXFromStart})})))}},this.sh=t=>{const i=this.ah(t);if(this.Zo=!1,this.Yo===i){const e=this.ph(t);t.cancelable&&this.dh(i,r.WR.Hold)&&Math.abs(e.deltaXFromStart)<this.Ro&&Math.abs(e.deltaYFromStart)<this.Ro&&t.preventDefault(),this.yh(t,i,e);this.bh(e)===r.qs.Y&&Math.abs(e.deltaYFromStart)>=this.Ro?this.Ko&&i.mediator.publish(i.context,n.Z[n.Z.Scroll]):!this.jo||this.Wo||this.zo||(this.Zo=!0)}this.Yo=null},this.nh=t=>{const i=this.ah(t);this.yh(t,i),this.Yo=null},this.oh=t=>{if(!c(t))return void this.wh(r.HT.InteractionStart,t);const i=this.ah(t);this.Yo=i,t.stopPropagation(),t.preventDefault(),this.dh(i,r.WR.Hold)&&this.lh(t),this.fh(t,i,r.HT.InteractionStart)},this.rh=t=>{const i=this.ah(t);return this.Zo?(i.mediator.publish(i.context,n.Z[n.Z.Click]),void(this.Zo=!1)):c(t)&&this.Yo?(t.stopPropagation(),t.preventDefault(),this.fh(t,this.Yo,r.HT.Interaction),this.fh(t,this.Yo,r.HT.InteractionEnd),(this.Uo||this.dh(i,r.WR.Hold))&&this.Sh(t),this.Yo===i&&(this.fh(t,i,r.HT.Click),i.mediator.publish(i.context,n.Z[n.Z.Click])),void(this.Yo=null)):(this.wh(r.HT.Interaction,t),void this.wh(r.HT.InteractionEnd,t))},this.Ah=t=>{if(!c(t))return this.wh(r.HT.Interaction,t),void this.wh(r.HT.InteractionEnd,t);this.Yo=null},this._h=t=>{if(!c(t)||!this.Yo)return this.wh(r.HT.Interaction,t),void this.wh(r.HT.InteractionEnd,t);this.fh(t,this.Yo,r.HT.Interaction),this.fh(t,this.Yo,r.HT.InteractionEnd),(this.Uo||this.dh(this.Yo,r.WR.Hold))&&this.Sh(t),this.Yo=null};const{leftTapSizeThreshold:s,holdTriggerDuration:o,scrollThreshold:a}=Object.assign({},e);this.Lo=s||this.Lo,this.Bo=o||this.Bo,this.Ro=a||this.Ro,this.Mo.document.addEventListener("mousedown",this.Ah),this.Mo.document.addEventListener("mouseup",this._h)}register(t,i,e,s={},n=[]){const r={element:t,mediator:i,context:e,callbacks:s||{},allowedSpecialInteractions:n,disabledSpecialInteractions:[]};this.Oo.push(r),this.th(r)}unregister(t){const i=this.Oo.find((i=>i.element===t));i&&(this.Oo=this.Oo.filter((i=>i.element!==t)),this.hh(i))}unregisterAll(t){const i=this.Oo.filter((i=>i.mediator===t));i.forEach(this.hh),this.Oo=(0,o.V7)(this.Oo,i)}addGlobalActions(t,i){Object.keys(Object.assign({},i)).forEach((e=>{this.Do[e]=this.Do[e]||[],this.Do[e].push({initiator:t,action:i[e]})}))}removeGlobalActions(t){Object.keys(this.Do).forEach((i=>{this.Do[i].some((i=>i.initiator===t))&&(this.Do[i]=this.Do[i].filter((i=>i.initiator!==t)))}))}disableSpecialInteractions(t){const i=this.xh(t);i&&(i.disabledSpecialInteractions=(0,o.gX)(i.allowedSpecialInteractions))}enableSpecialInteractions(t){const i=this.xh(t);i&&(i.disabledSpecialInteractions=[])}getNonInterruptibleInteractions(){return[n.Z.HoldStart,n.Z.HoldEnd,n.Z.SwipeMove,n.Z.SwipeEnd,n.Z.Scroll]}disableScrollEvent(){this.Ko=!1}enableScrollEvent(){this.Ko=!0}destroy(){clearTimeout(this.$o),this.Oo.forEach(this.hh),this.Mo.document.removeEventListener("mousedown",this.Ah),this.Mo.document.removeEventListener("mouseup",this._h)}Th(t){const i=this.ah(t),e=i.element.getBoundingClientRect(),s=this.kh(t),n=e.width,r=(0,d.dQ)(0,n,0,100,s);this.Ch(i,this.Lo,r)}Ch(t,i,e){e<i?t.mediator.publish(t.context,n.Z[n.Z.TapLeft]):t.mediator.publish(t.context,n.Z[n.Z.TapRight])}lh(t){clearTimeout(this.$o),this.Uo=!1,this.Wo=!1;const i=this.ah(t);(0,h.cn)(i.element,s.Gj.OnHold),this.$o=setTimeout((()=>{this.Uo=!0,this.jo&&(this.Wo=!0,i.mediator.publish(i.context,n.Z[n.Z.HoldStart]))}),this.Bo)}Sh(t){clearTimeout(this.$o);const i=this.ah(t);(0,h.IV)(i.element,s.Gj.OnHold),this.Uo?(this.Uo=!1,this.Wo&&(this.Wo=!1,i.mediator.publish(i.context,n.Z[n.Z.HoldEnd]))):(this.zo=!0,this.Th(t))}yh(t,i,e){e=e||this.ph(t),t.stopPropagation(),this.fh(t,i,r.HT.Interaction),this.fh(t,i,r.HT.InteractionEnd),(this.Uo||this.Go||this.jo&&this.dh(i,r.WR.Hold))&&this.Sh(t),(this.Go||this.dh(i,r.WR.Swipe))&&this.Eh(i,e)}mh(t,i){this.Jo=this.bh(i),this.Jo===r.qs.X&&(this.Go=!0,this.Uo||(clearTimeout(this.$o),this.$o=null,this.Uo=!0,t.mediator.publish(t.context,n.Z[n.Z.HoldStart])))}Eh(t,i){if(this.Go){const e=this.Mh(i);t.mediator.publish(t.context,n.Z[n.Z.SwipeEnd],{payload:e})}(0,h.h_)(this.Mo,this.Tn),this.Tn=null,this.Go=!1,this.Fo=null,this.Vo=null,this.Jo=null,this.Xo=0,this.Qo=0}gh(t){this.Qo<this.Ro?this.Qo++:(this.Xo=t,this.Qo=0)}bh(t){return Math.abs(t.deltaXFromStart)>=Math.abs(t.deltaYFromStart)?r.qs.X:r.qs.Y}Mh(t){return t.deltaXFromStart-this.Xo<0?r.Av.Left:r.Av.Right}ph(t){const i=t.changedTouches[0];return{deltaXFromStart:i.clientX-this.Fo,deltaYFromStart:i.clientY-this.Vo,eventX:i.clientX,eventY:i.clientY}}ah(t){return this.Yo||this.xh(t.currentTarget)}xh(t){return this.Oo.find((i=>i.element===t))}kh(t){const i=this.ah(t);if(this.ui){return t.changedTouches[0].clientX-i.element.getBoundingClientRect().left}return t.offsetX}dh(t,i){return t.allowedSpecialInteractions.includes(i)&&!t.disabledSpecialInteractions.includes(i)}fh(t,i,e){const s=i.callbacks[e];(0,l.mf)(s)&&s(t),this.wh(e,t)}wh(t,i){var e;null===(e=this.Do[t])||void 0===e||e.forEach((t=>{t.action(i)}))}}},1526:(t,i,e)=>{"use strict";e.d(i,{c:()=>u});var s,n,r=e(289),o=e(9791),h=e(3020),a=e(9022),c=e(4798),d=e(5650),l=e(1187);!function(t){t.isStringWithMacros=function(t,i){if(!(0,c.QM)(t))return!1;const e=`\\${i[0]}.*?\\${i[1]}`,s=new RegExp(e,"g");return!!t.match(s)},t.splitByFirstEqual=function(t){if(!(0,c.QM)(t))return;const i=t.indexOf("=");return-1!==i?[t.slice(0,i),t.slice(i+1)]:void 0}}(s||(s={})),function(t){t.AppUrl="APP_URL",t.AppBundle="APP_BUNDLE",t.AppName="APP_NAME",t.Uuid="UUID",t.PageUrl="PAGE_URL",t.AdPosition="AD_POSITION",t.VideoTitle="VIDEO_TITLE",t.MediaTitle="MEDIA_TITLE",t.VideoDuration="VIDEO_DURATION",t.ContentLength="CONTENT_LENGTH",t.VideoDescription="VIDEO_DESCRIPTION",t.VideoUrl="VIDEO_URL",t.VideoId="VIDEO_ID",t.VideoTime="VIDEO_TIME",t.DescriptionUrl="DESCRIPTION_URL",t.VideoKeywords="VIDEO_KEYWORDS",t.Autoplay="AUTOPLAY",t.UserAgent="UA",t.Ip="IP",t.CashBuster="CB",t.Width="WIDTH",t.Height="HEIGHT",t.Domain="DOMAIN",t.SourceReferrer="SOURCE_REFERRER",t.Gdpr="GDPR",t.GdprConsent="GDPR_CONSENT",t.Consent="CONSENT",t.Ctd="CTD",t.Publisher="PUBLISHER",t.Random="RAND",t.Site="SITE",t.SubId="SUB_ID",t.Url="URL",t.UserLat="USER_LAT",t.UserLong="USER_LONG",t.UsPrivacyString="US_PRIVACY",t.Npa="NPA",t.DoNotTrack="DNT",t.FraudSensorUserId="FS_USER_ID",t.PublisherId="PUBLISHER_ID",t.SessionId="SESSION_ID",t.FraudSensorDeviceType="FS_DEVICE_TYPE",t.FraudSensorLookupId="MGID",t.FraudSensorLookupResponseCode="MGTO",t.FraudSensorMediaType="FS_MEDIA_TYPE",t.FraudSensorDeviceIdentifier="FS_DEVICE_IDENT",t.CnxSupplierId="CNX_SUPPLIER_ID",t.AdxPublisherNetworkCode="ADX_CPNC",t.ErrorCode="ERRORCODE"}(n||(n={}));class u{constructor(t,i,e,s,o,h,d,l){this.Lh=new Map,this.Bh="[",this.Rh="]",this.Lh.set(n.Autoplay,t.playbackMode===r.ProtoPlayerPlaybackModeEnum.Autoplay),this.Lh.set(n.UserAgent,navigator.userAgent),this.Lh.set(n.UserLong,i.lon),this.Lh.set(n.UserLat,i.lat),this.Lh.set(n.Ip,i.ip),this.Oh(h),this.Dh(d),this.Vh(e,s,o),this.Fh(),this.Lh.set(n.Domain,s),this.Lh.set(n.CnxSupplierId,a.kd),this.Lh.set(n.SessionId,t.sessionId),(0,c.QM)(l)&&this.Lh.set(n.AdxPublisherNetworkCode,`,${l}`)}Oh(t){this.Lh.set(n.AppBundle,t.bundleID),this.Lh.set(n.AppName,t.appName),this.Lh.set(n.AppUrl,t.storeURL)}Dh(t){this.Lh.set(n.SourceReferrer,t)}Fh(){const t=(0,h.w6)()?1:0;this.Lh.set(n.DoNotTrack,t)}Vh(t,i,e){this.Lh.set(n.Url,t),this.Lh.set(n.PageUrl,e),this.Lh.set(n.Site,i),this.Lh.set(n.Publisher,t),this.Lh.set(n.DescriptionUrl,t)}Nh(){const t=(0,o.qs)();this.Lh.set(n.CashBuster,t),this.Lh.set(n.Random,t),this.Lh.set(n.Ctd,t)}jh(t){return t.split("?")[0]}$h(t){return t.split("?").slice(1).join("?")}qh(t,i){const e=this.jh(t),s=this.zh(this.$h(t),i);return`${e}${s?`?${s}`:""}`}zh(t,i,e=!1){let n=t;const r=n.split("&"),h=[this.Bh,this.Rh];try{r.forEach((r=>{const a=s.splitByFirstEqual(r);if((0,d.BZ)(a)&&a[1])if(s.isStringWithMacros(a[1],h))n=n.replace(a[1],this.Wh(a[1],i,e));else try{if(!a[1].includes(encodeURIComponent("="))||0===decodeURIComponent(a[1]).split("=").length)return;const t=this.zh(decodeURIComponent(a[1]),i,!0);n=n.replace(a[1],encodeURIComponent(t))}catch(i){(0,o.Vm)([95,5])&&(0,l.n)({message:"ReplaceData_handleMacros",exception:`pair:${a}, ${i.message}`,callStack:t,level:l.D.WARN},{throttle:1})}}))}catch(i){throw(0,l.n)({message:"MacrosService_handleMacros",exception:i.message,callStack:t,level:l.D.CRITICAL},{throttle:1}),i}return n=this.Gh(n,i),this.Qh(n)}Qh(t){return t.includes(this.Bh)&&(t=t.cnx_replaceAll(this.Bh,encodeURIComponent(this.Bh))),t.includes(this.Rh)&&(t=t.cnx_replaceAll(this.Rh,encodeURIComponent(this.Rh))),t}Wh(t,i,e){let s,n=t,r=t.toLowerCase();return i.forEach(((t,i)=>{const o=this.Bh+i.toLowerCase()+this.Rh;for(;r.includes(o);){const i=r.indexOf(o),h=i+o.length;s=e?t:encodeURIComponent(t),n=n.slice(0,i)+s+n.slice(h),r=n.toLowerCase()}})),n}Gh(t,i){const e=`${this.Bh}${n.AdxPublisherNetworkCode}${this.Rh}`;return t.includes(e)?i.has(n.AdxPublisherNetworkCode)?t.cnx_replaceAll(e,i.get(n.AdxPublisherNetworkCode)):t.cnx_replaceAll(e,""):t}setAdWidth(t){this.Lh.set(n.Width,Math.floor(t))}setAdHeight(t){this.Lh.set(n.Height,Math.floor(t))}setSubId(t){this.Lh.set(n.SubId,t)}setGDPR(t){this.Lh.set(n.Gdpr,t)}setUUID(t){this.Lh.set(n.Uuid,t)}setGDPRConsent(t){this.Lh.set(n.GdprConsent,t)}setConsent(t){this.Lh.set(n.Consent,t)}setVideoId(t){this.Lh.set(n.VideoId,t)}setNPA(t){this.Lh.set(n.Npa,t)}setVideoTime(t){this.Lh.set(n.VideoTime,Math.floor(t))}setVideoUrl(t){this.Lh.set(n.VideoUrl,t)}setVideoDescription(t){this.Lh.set(n.VideoDescription,t)}setVideoDuration(t){this.Lh.set(n.VideoDuration,t),this.Lh.set(n.ContentLength,t)}setVideoTitle(t){let i;this.Lh.set(n.VideoTitle,t),this.Lh.set(n.MediaTitle,t),t&&(i=t.split(" ").join(",")),this.Lh.set(n.VideoKeywords,i)}setAdPosition(t="midRoll"){this.Lh.set(n.AdPosition,t)}setupMacros(t){return this.Nh(),this.qh(t,this.Lh)}addExtraMacros(t){const i=Object.values(n);Object.keys(t).filter((t=>!i.includes(t.toUpperCase()))).forEach((i=>{this.Lh.set(i,t[i])}))}getMacroValue(t){return this.Lh.get(t)}getExtraMacros(){const t=Object.values(n),i={};return this.Lh.forEach(((e,s)=>{t.includes(s)||null==e||(i[s]=(0,c.QM)(e)?e:JSON.stringify(e))})),i}setUsPrivacyString(t){const i=t||"";this.Lh.set(n.UsPrivacyString,i)}setUserId(t){this.Lh.set(n.FraudSensorUserId,t)}setPublisherId(t){this.Lh.set(n.PublisherId,t)}setFraudSensorMacros(t){this.Lh.set(n.FraudSensorDeviceType,t.deviceType),this.Lh.set(n.FraudSensorLookupId,t.lookupId),this.Lh.set(n.FraudSensorLookupResponseCode,t.lookupResponseCode),this.Lh.set(n.FraudSensorMediaType,t.mediaType),this.Lh.set(n.FraudSensorDeviceIdentifier,t.deviceIdentifier)}setErrorCode(t){this.Lh.set(n.ErrorCode,t)}destroy(){}}},5292:(t,i,e)=>{"use strict";var s,n;e.d(i,{v:()=>r}),function(t){t.hidden="hidden",t.msHidden="msHidden",t.webkitHidden="webkitHidden"}(s||(s={})),function(t){t.visibilitychange="visibilitychange",t.msvisibilitychange="msvisibilitychange",t.webkitvisibilitychange="webkitvisibilitychange"}(n||(n={}));class r{constructor(t){this.yn=t,this.Yh=[],this.Kh(),this.Zh()}on(t){this.Yh.push(t),t(this.isDocumentVisible())}off(t){this.Yh=this.Yh.filter((i=>i!==t))}Kh(){void 0!==this.yn.getDocumentProperty(s.hidden)?(this.ta=s.hidden,this.ia=n.visibilitychange):void 0!==this.yn.getDocumentProperty(s.msHidden)?(this.ta=s.msHidden,this.ia=n.msvisibilitychange):void 0!==this.yn.getDocumentProperty(s.webkitHidden)&&(this.ta=s.webkitHidden,this.ia=n.webkitvisibilitychange)}Zh(){this.yn.addEventListenerOnGlobal(this.ia,(()=>{this.Yh.forEach((t=>{t(this.isDocumentVisible())}))}),!0,!1)}isDocumentVisible(){return!this.yn.getDocumentProperty(this.ta)}}},5421:(t,i,e)=>{"use strict";e.d(i,{a:()=>z});var s,n=e(1187),r=e(3020),o=[],h="ResizeObserver loop completed with undelivered notifications.";!function(t){t.BORDER_BOX="border-box",t.CONTENT_BOX="content-box",t.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"}(s||(s={}));var a,c=function(t){return Object.freeze(t)},d=function(t,i){this.inlineSize=t,this.blockSize=i,c(this)},l=function(){function t(t,i,e,s){return this.x=t,this.y=i,this.width=e,this.height=s,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,c(this)}return t.prototype.toJSON=function(){var t=this;return{x:t.x,y:t.y,top:t.top,right:t.right,bottom:t.bottom,left:t.left,width:t.width,height:t.height}},t.fromRect=function(i){return new t(i.x,i.y,i.width,i.height)},t}(),u=function(t){return t instanceof SVGElement&&"getBBox"in t},p=function(t){if(u(t)){var i=t.getBBox(),e=i.width,s=i.height;return!e&&!s}var n=t,r=n.offsetWidth,o=n.offsetHeight;return!(r||o||t.getClientRects().length)},f=function(t){var i;if(t instanceof Element)return!0;var e=null===(i=null==t?void 0:t.ownerDocument)||void 0===i?void 0:i.defaultView;return!!(e&&t instanceof e.Element)},m="undefined"!=typeof window?window:{},g=new WeakMap,v=/auto|scroll/,y=/^tb|vertical/,b=/msie|trident/i.test(m.navigator&&m.navigator.userAgent),I=function(t){return parseFloat(t||"0")},w=function(t,i,e){return void 0===t&&(t=0),void 0===i&&(i=0),void 0===e&&(e=!1),new d((e?i:t)||0,(e?t:i)||0)},S=c({devicePixelContentBoxSize:w(),borderBoxSize:w(),contentBoxSize:w(),contentRect:new l(0,0,0,0)}),P=function(t,i){if(void 0===i&&(i=!1),g.has(t)&&!i)return g.get(t);if(p(t))return g.set(t,S),S;var e=getComputedStyle(t),s=u(t)&&t.ownerSVGElement&&t.getBBox(),n=!b&&"border-box"===e.boxSizing,r=y.test(e.writingMode||""),o=!s&&v.test(e.overflowY||""),h=!s&&v.test(e.overflowX||""),a=s?0:I(e.paddingTop),d=s?0:I(e.paddingRight),f=s?0:I(e.paddingBottom),m=s?0:I(e.paddingLeft),P=s?0:I(e.borderTopWidth),A=s?0:I(e.borderRightWidth),_=s?0:I(e.borderBottomWidth),x=m+d,T=a+f,k=(s?0:I(e.borderLeftWidth))+A,C=P+_,E=h?t.offsetHeight-C-t.clientHeight:0,M=o?t.offsetWidth-k-t.clientWidth:0,L=n?x+k:0,B=n?T+C:0,R=s?s.width:I(e.width)-L-M,O=s?s.height:I(e.height)-B-E,D=R+x+M+k,V=O+T+E+C,F=c({devicePixelContentBoxSize:w(Math.round(R*devicePixelRatio),Math.round(O*devicePixelRatio),r),borderBoxSize:w(D,V,r),contentBoxSize:w(R,O,r),contentRect:new l(m,a,R,O)});return g.set(t,F),F},A=function(t,i,e){var n=P(t,e),r=n.borderBoxSize,o=n.contentBoxSize,h=n.devicePixelContentBoxSize;switch(i){case s.DEVICE_PIXEL_CONTENT_BOX:return h;case s.BORDER_BOX:return r;default:return o}},_=function(t){var i=P(t);this.target=t,this.contentRect=i.contentRect,this.borderBoxSize=c([i.borderBoxSize]),this.contentBoxSize=c([i.contentBoxSize]),this.devicePixelContentBoxSize=c([i.devicePixelContentBoxSize])},x=function(t){if(p(t))return 1/0;for(var i=0,e=t.parentNode;e;)i+=1,e=e.parentNode;return i},T=function(){var t=1/0,i=[];o.forEach((function(e){if(0!==e.activeTargets.length){var s=[];e.activeTargets.forEach((function(i){var e=new _(i.target),n=x(i.target);s.push(e),i.lastReportedSize=A(i.target,i.observedBox),n<t&&(t=n)})),i.push((function(){e.callback.call(e.observer,s,e.observer)})),e.activeTargets.splice(0,e.activeTargets.length)}}));for(var e=0,s=i;e<s.length;e++){(0,s[e])()}return t},k=function(t){o.forEach((function(i){i.activeTargets.splice(0,i.activeTargets.length),i.skippedTargets.splice(0,i.skippedTargets.length),i.observationTargets.forEach((function(e){e.isActive()&&(x(e.target)>t?i.activeTargets.push(e):i.skippedTargets.push(e))}))}))},C=function(){var t,i=0;for(k(i);o.some((function(t){return t.activeTargets.length>0}));)i=T(),k(i);return o.some((function(t){return t.skippedTargets.length>0}))&&("function"==typeof ErrorEvent?t=new ErrorEvent("error",{message:h}):((t=document.createEvent("Event")).initEvent("error",!1,!1),t.message=h),window.dispatchEvent(t)),i>0},E=[],M=function(t){if(!a){var i=0,e=document.createTextNode("");new MutationObserver((function(){return E.splice(0).forEach((function(t){return t()}))})).observe(e,{characterData:!0}),a=function(){e.textContent="".concat(i?i--:i++)}}E.push(t),a()},L=0,B={attributes:!0,characterData:!0,childList:!0,subtree:!0},R=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],O=function(t){return void 0===t&&(t=0),Date.now()+t},D=!1,V=new(function(){function t(){var t=this;this.stopped=!0,this.listener=function(){return t.schedule()}}return t.prototype.run=function(t){var i=this;if(void 0===t&&(t=250),!D){D=!0;var e,s=O(t);e=function(){var e=!1;try{e=C()}finally{if(D=!1,t=s-O(),!L)return;e?i.run(1e3):t>0?i.run(t):i.start()}},M((function(){requestAnimationFrame(e)}))}},t.prototype.schedule=function(){this.stop(),this.run()},t.prototype.observe=function(){var t=this,i=function(){return t.observer&&t.observer.observe(document.body,B)};document.body?i():m.addEventListener("DOMContentLoaded",i)},t.prototype.start=function(){var t=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),R.forEach((function(i){return m.addEventListener(i,t.listener,!0)})))},t.prototype.stop=function(){var t=this;this.stopped||(this.observer&&this.observer.disconnect(),R.forEach((function(i){return m.removeEventListener(i,t.listener,!0)})),this.stopped=!0)},t}()),F=function(t){!L&&t>0&&V.start(),!(L+=t)&&V.stop()},N=function(){function t(t,i){this.target=t,this.observedBox=i||s.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return t.prototype.isActive=function(){var t,i=A(this.target,this.observedBox,!0);return t=this.target,u(t)||function(t){switch(t.tagName){case"INPUT":if("image"!==t.type)break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1}(t)||"inline"!==getComputedStyle(t).display||(this.lastReportedSize=i),this.lastReportedSize.inlineSize!==i.inlineSize||this.lastReportedSize.blockSize!==i.blockSize},t}(),j=function(t,i){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=t,this.callback=i},$=new WeakMap,U=function(t,i){for(var e=0;e<t.length;e+=1)if(t[e].target===i)return e;return-1},q=function(){function t(){}return t.connect=function(t,i){var e=new j(t,i);$.set(t,e)},t.observe=function(t,i,e){var s=$.get(t),n=0===s.observationTargets.length;U(s.observationTargets,i)<0&&(n&&o.push(s),s.observationTargets.push(new N(i,e&&e.box)),F(1),V.schedule())},t.unobserve=function(t,i){var e=$.get(t),s=U(e.observationTargets,i),n=1===e.observationTargets.length;s>=0&&(n&&o.splice(o.indexOf(e),1),e.observationTargets.splice(s,1),F(-1))},t.disconnect=function(t){var i=this,e=$.get(t);e.observationTargets.slice().forEach((function(e){return i.unobserve(t,e.target)})),e.activeTargets.splice(0,e.activeTargets.length)},t}(),H=function(){function t(t){if(0===arguments.length)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if("function"!=typeof t)throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");q.connect(this,t)}return t.prototype.observe=function(t,i){if(0===arguments.length)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!f(t))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");q.observe(this,t,i)},t.prototype.unobserve=function(t){if(0===arguments.length)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!f(t))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");q.unobserve(this,t)},t.prototype.disconnect=function(){q.disconnect(this)},t.toString=function(){return"function ResizeObserver () { [polyfill code] }"},t}();class z{constructor(t){this.ea=[],this.sa=(t,i)=>{t.forEach((t=>{this.na(t.target).forEach((t=>{t&&((0,r.Tp)(t.element),t.callback(t.element))}))}))};try{const i=t.ResizeObserver||H;this.ra=new i(this.sa)}catch(t){(0,n.n)({message:"ResizeObserver_constructor",callStack:t.stack,exception:t.message,level:n.D.CRITICAL})}}on(t,i){this.oa(t,i)||(this.ea.push({element:t,callback:i}),this.ra.observe(t))}off(t,i){const e=this.oa(t,i);if(!e)return;this.ra.unobserve(e.element);const s=this.ea.indexOf(e);s>=0&&this.ea.splice(s,1)}destroy(){if(this.ea)for(;this.ea.length>0;)this.ea.pop();this.ra.disconnect()}na(t){return this.ea.filter((i=>i.element===t))}oa(t,i){return this.ea.find((e=>e.element===t&&e.callback===i))}}},1553:(t,i,e)=>{"use strict";e.d(i,{f:()=>o});var s=e(5650),n=e(51),r=e(4798);class o{constructor(){this.ha={},this.aa={domain:"",urlParams:[]},this.ignoredDomains=[]}setQueryParams(t){this.ha=t}setUrlParams(t){this.aa=t}appendParamsToUrl(t){return this.isIgnoredDomain(t)?t:this.ca(t)}appendQueryParamsToUrl(t){return this.isIgnoredDomain(t)?t:this.da(t,Object.keys(this.ha).map((t=>({paramName:t,paramValue:this.ha[t]}))))}ca(t){if(!(0,s.BZ)(Object.keys(this.aa))||!(0,s.BZ)(this.aa.urlParams)||!t.includes(this.aa.domain))return t;const i=this.aa.urlParams.reduce(((t,i)=>`${t}${i}`),"");return t.replace(this.aa.domain,this.aa.domain+"/"+i)}da(t,i){if(!(0,s.BZ)(i))return t;t+=(0,n.CK)(t);let e="";return i.forEach((t=>{(0,r.QM)(t.paramName)&&(0,r.QM)(t.paramValue)&&(e+=`${e.length>0?"&":""}${t.paramName}=${t.paramValue}`)})),t+e}isIgnoredDomain(t){return this.ignoredDomains.some((i=>t.indexOf(i)>-1))}}},3199:(t,i,e)=>{"use strict";var s;e.d(i,{Z:()=>n}),function(t){t[t.P1=1]="P1",t[t.P2=2]="P2",t[t.P3=3]="P3",t[t.P4=4]="P4",t[t.P5=5]="P5",t[t.P6=6]="P6",t[t.P7=7]="P7",t[t.P8=8]="P8",t[t.P9=9]="P9",t[t.P10=10]="P10"}(s||(s={}));const n=[s.P1,s.P2,s.P4,s.P7,s.P8]},4361:(t,i,e)=>{"use strict";e.d(i,{k:()=>Et,x:()=>Bt});var s,n=e(9791);!function(t){t.Connatix="143",t.AppNexus="32",t.DistrictM="144",t.IndexExchange="10",t.Lkqd="237",t.OneVideo="25",t.Openx="69",t.Pubmatic="76",t.RhythmOne="36",t.Rubicon="52",t.Spotx="165",t.Telaria="202",t.MediaNet="142",t.AdMan="149",t.IronSource="",t.Undertone="677",t.SynacorMedia="",t.AmxRTB="737",t.Smaato="82",t.TheMediaGrid="686",t.Rise="1043"}(s||(s={}));const r=["1YNY"];var o=e(6578),h=e(289),a=e(6153),c=e(4798),d=e(307),l=e(7945);class u{constructor(t){this.la=t,this.pa=!0,this.fa="",this.ma=!1,this.ga=[]}static getInstance(t){const i="cnx_usr_storage",e=(0,n.pE)(t).topFrame;return e[i]||(e[i]=new u(e)),e[i]}get userId(){if((0,c.QM)(this.va))return this.va.split("_")[0]}set userId(t){this.va=t}get isCcpaApplicable(){return this.pa}set isCcpaApplicable(t){this.pa=t}get usPrivacyString(){return this.fa}set usPrivacyString(t){this.fa=t}get consentPayload(){return this.ya}set consentPayload(t){this.ya||(this.ya=t)}getScope(){return this.la}syncDemandPartner(t){if(this.userId){const i={userId:this.userId,demandPartner:parseInt(t.demandPartner,10),demandPartnerUserId:t.demandPartnerUserId};o.n.sendProtoRequest({protoRequest:h.ProtoUserSyncRequest,endpoint:a.n.endPoints.api.syncUrls,requestData:i,queryParams:{[d.Fk]:l.g.version,[d.cc]:a.n.tier},shouldLogErrors:!0}).then((t=>{})).catch((t=>{}))}}registerPlsCall(t){return this.ma?(this.ga.push(t),()=>{}):this.userId?(t(),()=>{}):(this.ma=!0,t(),()=>{this.ma=!1,this.ga.forEach((t=>t())),this.ga=[]})}}var p,f,m=e(1310),g=e(1187),v=e(5650);!function(t){t.USER_ID="cnx_userId"}(p||(p={}));class y{constructor(t,i){this.ba=t,this.Ci=i,this.Ia={[p.USER_ID]:30},this.wa=["Facebook App","Google App","Flipboard App","Instagram App","Pinterest App"],this.Sa=!1}Pa({name:t,value:i}){t===p.USER_ID&&(this.ba.userId=this.Aa(i))}_a(t){let i="";const e=this.Ia[t.name];if(e){i=`; expires=${new Date((0,m.XF)(e)).toUTCString()}`}this.Ci.document.cookie=`${t.name}=${t.value}${i}; path=/`}xa(t,i){if(!(0,v.BZ)(t))return;const e={cookieList:t,secureMode:i?h.ProtoCookieSecureModeEnum.Unsecure:h.ProtoCookieSecureModeEnum.Auto,browserInfo:this.Ta};return o.n.sendProtoRequest({requestData:e,protoRequest:h.ProtoCookieSyncRequest,endpoint:a.n.endPoints.api.cookie,hasCredentials:!0,queryParams:{[d.Fk]:l.g.version,[d.cc]:a.n.tier},shouldLogErrors:!1}).catch((t=>(0,g.n)({message:"UserCookieManager_setThirdPartyCookie",exception:t.message,callStack:t.callStack,level:g.D.CRITICAL})))}Aa(t){return t.split("_")[0]}ka(t){try{const i=t+"=",e=decodeURIComponent(this.Ci.document.cookie).split(";");for(let t of e){for(;" "===t.charAt(0);)t=t.substring(1);if(t.includes(i))return this.Aa(t.substring(i.length,t.length))}}catch(t){}return""}getUserId(){return this.ba.userId}syncFirstPartyCookie(t){const i={name:t,value:"",timestamp:(0,m.XF)(this.Ia[t])};t===p.USER_ID&&(i.value=this.ba.userId),(0,c.QM)(i.value)&&this._a(i)}syncThirdPartyCookieList(t){const i=[p.USER_ID],e=[];i.forEach((t=>{t===p.USER_ID&&(0,c.QM)(this.ba.userId)&&e.push({name:p.USER_ID,value:this.ba.userId,timestamp:(0,m.XF)(this.Ia[p.USER_ID])})})),this.xa(e,t)}setBrowserInfo(t,i){this.Ta=t,this.Sa=this.wa.includes(t.browserType),this.Sa&&i&&this.syncThirdPartyCookieList(this.Sa)}setUserInformation(t){t&&this.Pa({name:p.USER_ID,value:t.userId})}fetchCookies(){[p.USER_ID].map((t=>({name:t,value:this.ka(t)}))).filter((({value:t})=>(0,c.QM)(t))).forEach((t=>this.Pa(t)))}get unsecuredCookieSync(){return this.Sa}}!function(t){t[t.CmpApi=0]="CmpApi",t[t.TcfApi=1]="TcfApi"}(f||(f={}));const b={[f.CmpApi]:{windowPropertyName:"__cmp",framePropertyName:"__cmpLocator",getVendorConsentDataMethodName:"getVendorConsents",getConsentDataMethodName:"getConsentData"},[f.TcfApi]:{windowPropertyName:"__tcfapi",framePropertyName:"__tcfapiLocator",getVendorConsentDataMethodName:"getTCData",consentUpdateMethodName:"addEventListener",removeUpdateListenerMethodName:"removeEventListener"}};class I{constructor(t,i){this.Ca=t,this.Ea=i,this.apiType=f.CmpApi,this.Ma={},this.ya=null,this.La=t=>new Promise(((i,e)=>{try{const e="string"==typeof t.data?JSON.parse(t.data):t.data;if("object"==typeof e&&e.Ba)if(e.Ba.callId===this.Ra){const t=e.Ba.returnValue&&e.Ba.returnValue.vendorConsents;this.Oa(t).then((()=>i(this.Ra)))}else if(e.Ba.callId===this.Da){const t=e.Ba.returnValue&&e.Ba.returnValue.consentData;this.Va(t).then((()=>i(this.Da)))}}catch(t){e()}}))}isApiOnPage(){return null!==this.Ca||null!==this.Ea}bindToApi(){return null!==this.Ca?new Promise(((t,i)=>{this.Fa(this.Ca).then((()=>t())).catch((t=>i(t)))})):null!==this.Ea?this.Na(this.Ea):Promise.reject()}isConsentForVendor(t){return!!this.Ma[t]}getConsentPayload(){return this.ya}setInAppConsentData(t){this.Oa(t),this.Va(t.consentString)}hasIvtConsent(){return this.isConsentForVendor(s.Connatix)}isConsentForPurposes(t){return!0}Na(t){this.Da=(0,n.qs)(),this.Ra=(0,n.qs)();const i={};return new Promise((e=>{const s=t=>{this.La(t).then((t=>{i[t]=!0,i[this.Da]&&i[this.Ra]&&(window.removeEventListener("message",s,!1),e())})).catch((t=>{}))};window.addEventListener("message",s,!1);const n=b[f.CmpApi].getVendorConsentDataMethodName,r=b[f.CmpApi].getConsentDataMethodName;t.postMessage({ja:{command:n,parameter:null,callId:this.Ra}},"*"),t.postMessage({ja:{command:r,parameter:null,callId:this.Da}},"*")}))}Fa(t){const i=b[f.CmpApi].windowPropertyName,e=b[f.CmpApi].getVendorConsentDataMethodName,s=b[f.CmpApi].getConsentDataMethodName;if(t&&t[i]){const n=new Promise((s=>{t[i](e,null,((t,i)=>{if(i){const{vendorConsents:i}=t;this.Oa(i).then((()=>s()))}}))})),r=new Promise((e=>{t[i](s,null,((t,i)=>{if(i){const{consentData:i}=t;this.Va(i).then((()=>e()))}}))}));return Promise.all([n,r])}return Promise.reject()}Oa(t){return(0,c.as)(t)?(this.Ma=t,Promise.resolve()):Promise.reject()}Va(t){return(0,c.HD)(t)?(this.ya=t,Promise.resolve()):Promise.reject()}}var w,S,P,A,_=e(3020),x=e(8462);class T extends Error{constructor(t){super(t),this.name="DecodingError"}}class k extends Error{constructor(t){super(t),this.name="EncodingError"}}class C extends Error{constructor(t){super(t),this.name="GVLError"}}class E extends Error{constructor(t,i,e=""){super(`invalid value ${i} passed for ${t} ${e}`),this.name="TCModelError"}}class M{static DICT="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_";static REVERSE_DICT=new Map([["A",0],["B",1],["C",2],["D",3],["E",4],["F",5],["G",6],["H",7],["I",8],["J",9],["K",10],["L",11],["M",12],["N",13],["O",14],["P",15],["Q",16],["R",17],["S",18],["T",19],["U",20],["V",21],["W",22],["X",23],["Y",24],["Z",25],["a",26],["b",27],["c",28],["d",29],["e",30],["f",31],["g",32],["h",33],["i",34],["j",35],["k",36],["l",37],["m",38],["n",39],["o",40],["p",41],["q",42],["r",43],["s",44],["t",45],["u",46],["v",47],["w",48],["x",49],["y",50],["z",51],["0",52],["1",53],["2",54],["3",55],["4",56],["5",57],["6",58],["7",59],["8",60],["9",61],["-",62],["_",63]]);static BASIS=6;static LCM=24;static encode(t){if(!/^[0-1]+$/.test(t))throw new k("Invalid bitField");const i=t.length%this.LCM;t+=i?"0".repeat(this.LCM-i):"";let e="";for(let i=0;i<t.length;i+=this.BASIS)e+=this.DICT[parseInt(t.substr(i,this.BASIS),2)];return e}static decode(t){if(!/^[A-Za-z0-9\-_]+$/.test(t))throw new T("Invalidly encoded Base64URL string");let i="";for(let e=0;e<t.length;e++){const s=this.REVERSE_DICT.get(t[e]).toString(2);i+="0".repeat(this.BASIS-s.length)+s}return i}}class L{static langSet=new Set(["BG","CA","CS","DA","DE","EL","EN","ES","ET","FI","FR","HR","HU","IT","JA","LT","LV","MT","NL","NO","PL","PT","RO","RU","SK","SL","SV","TR","ZH"]);has(t){return L.langSet.has(t)}forEach(t){L.langSet.forEach(t)}get size(){return L.langSet.size}}class B{static cmpId="cmpId";static cmpVersion="cmpVersion";static consentLanguage="consentLanguage";static consentScreen="consentScreen";static created="created";static supportOOB="supportOOB";static isServiceSpecific="isServiceSpecific";static lastUpdated="lastUpdated";static numCustomPurposes="numCustomPurposes";static policyVersion="policyVersion";static publisherCountryCode="publisherCountryCode";static publisherCustomConsents="publisherCustomConsents";static publisherCustomLegitimateInterests="publisherCustomLegitimateInterests";static publisherLegitimateInterests="publisherLegitimateInterests";static publisherConsents="publisherConsents";static publisherRestrictions="publisherRestrictions";static purposeConsents="purposeConsents";static purposeLegitimateInterests="purposeLegitimateInterests";static purposeOneTreatment="purposeOneTreatment";static specialFeatureOptins="specialFeatureOptins";static useNonStandardStacks="useNonStandardStacks";static vendorConsents="vendorConsents";static vendorLegitimateInterests="vendorLegitimateInterests";static vendorListVersion="vendorListVersion";static vendorsAllowed="vendorsAllowed";static vendorsDisclosed="vendorsDisclosed";static version="version"}class R{clone(){const t=new this.constructor;return Object.keys(this).forEach((i=>{const e=this.deepClone(this[i]);void 0!==e&&(t[i]=e)})),t}deepClone(t){const i=typeof t;if("number"===i||"string"===i||"boolean"===i)return t;if(null!==t&&"object"===i){if("function"==typeof t.clone)return t.clone();if(t instanceof Date)return new Date(t.getTime());if(void 0!==t[Symbol.iterator]){const i=[];for(const e of t)i.push(this.deepClone(e));return t instanceof Array?i:new t.constructor(i)}{const i={};for(const e in t)t.hasOwnProperty(e)&&(i[e]=this.deepClone(t[e]));return i}}}}!function(t){t[t.NOT_ALLOWED=0]="NOT_ALLOWED",t[t.REQUIRE_CONSENT=1]="REQUIRE_CONSENT",t[t.REQUIRE_LI=2]="REQUIRE_LI"}(w||(w={}));class O extends R{static hashSeparator="-";purposeId_;restrictionType;constructor(t,i){super(),void 0!==t&&(this.purposeId=t),void 0!==i&&(this.restrictionType=i)}static unHash(t){const i=t.split(this.hashSeparator),e=new O;if(2!==i.length)throw new E("hash",t);return e.purposeId=parseInt(i[0],10),e.restrictionType=parseInt(i[1],10),e}get hash(){if(!this.isValid())throw new Error("cannot hash invalid PurposeRestriction");return`${this.purposeId}${O.hashSeparator}${this.restrictionType}`}get purposeId(){return this.purposeId_}set purposeId(t){this.purposeId_=t}isValid(){return Number.isInteger(this.purposeId)&&this.purposeId>0&&(this.restrictionType===w.NOT_ALLOWED||this.restrictionType===w.REQUIRE_CONSENT||this.restrictionType===w.REQUIRE_LI)}isSameAs(t){return this.purposeId===t.purposeId&&this.restrictionType===t.restrictionType}}class D extends R{root=null;isEmpty(){return!this.root}add(t){const i={value:t,left:null,right:null};let e;if(this.isEmpty())this.root=i;else for(e=this.root;;)if(t<e.value){if(null===e.left){e.left=i;break}e=e.left}else{if(!(t>e.value))break;if(null===e.right){e.right=i;break}e=e.right}}get(){const t=[];let i=this.root;for(;i;)if(i.left){let e=i.left;for(;e.right&&e.right!=i;)e=e.right;e.right==i?(e.right=null,t.push(i.value),i=i.right):(e.right=i,i=i.left)}else t.push(i.value),i=i.right;return t}contains(t){let i=!1,e=this.root;for(;e;){if(e.value===t){i=!0;break}t>e.value?e=e.right:t<e.value&&(e=e.left)}return i}min(t=this.root){let i;for(;t;)t.left?t=t.left:(i=t.value,t=null);return i}max(t=this.root){let i;for(;t;)t.right?t=t.right:(i=t.value,t=null);return i}remove(t,i=this.root){let e=null,s="left";for(;i;)if(t<i.value)e=i,i=i.left,s="left";else if(t>i.value)e=i,i=i.right,s="right";else{if(i.left||i.right)if(i.left)if(i.right){const t=this.min(i.right);this.remove(t,i.right),i.value=t}else e?e[s]=i.left:this.root=i.left;else e?e[s]=i.right:this.root=i.right;else e?e[s]=null:this.root=null;i=null}}}class V extends R{bitLength=0;map=new Map;gvl_;has(t){return this.map.has(t)}isOkToHave(t,i,e){let s=!0;if(this.gvl?.vendors){const n=this.gvl.vendors[e];if(n)if(t===w.NOT_ALLOWED)s=n.legIntPurposes.includes(i)||n.purposes.includes(i);else if(n.flexiblePurposes.length)switch(t){case w.REQUIRE_CONSENT:s=n.flexiblePurposes.includes(i)&&n.legIntPurposes.includes(i);break;case w.REQUIRE_LI:s=n.flexiblePurposes.includes(i)&&n.purposes.includes(i)}else s=!1;else s=!1}return s}add(t,i){if(this.isOkToHave(i.restrictionType,i.purposeId,t)){const e=i.hash;this.has(e)||(this.map.set(e,new D),this.bitLength=0),this.map.get(e).add(t)}}restrictPurposeToLegalBasis(t){const i=this.gvl.vendorIds,e=t.hash,s=function(){let t;for(t of i);return t}();for(let t=1;t<=s;t++)this.has(e)||(this.map.set(e,new D),this.bitLength=0),this.map.get(e).add(t)}getVendors(t){let i=[];if(t){const e=t.hash;this.has(e)&&(i=this.map.get(e).get())}else{const t=new Set;this.map.forEach((i=>{i.get().forEach((i=>{t.add(i)}))})),i=Array.from(t)}return i}getRestrictionType(t,i){let e;return this.getRestrictions(t).forEach((t=>{t.purposeId===i&&(void 0===e||e>t.restrictionType)&&(e=t.restrictionType)})),e}vendorHasRestriction(t,i){let e=!1;const s=this.getRestrictions(t);for(let t=0;t<s.length&&!e;t++)e=i.isSameAs(s[t]);return e}getMaxVendorId(){let t=0;return this.map.forEach((i=>{t=Math.max(i.max(),t)})),t}getRestrictions(t){const i=[];return this.map.forEach(((e,s)=>{t?e.contains(t)&&i.push(O.unHash(s)):i.push(O.unHash(s))})),i}getPurposes(){const t=new Set;return this.map.forEach(((i,e)=>{t.add(O.unHash(e).purposeId)})),Array.from(t)}remove(t,i){const e=i.hash,s=this.map.get(e);s&&(s.remove(t),s.isEmpty()&&(this.map.delete(e),this.bitLength=0))}set gvl(t){this.gvl_||(this.gvl_=t,this.map.forEach(((t,i)=>{const e=O.unHash(i);t.get().forEach((i=>{this.isOkToHave(e.restrictionType,e.purposeId,i)||t.remove(i)}))})))}get gvl(){return this.gvl_}isEmpty(){return 0===this.map.size}get numRestrictions(){return this.map.size}}!function(t){t.COOKIE="cookie",t.WEB="web",t.APP="app"}(S||(S={})),function(t){t.CORE="core",t.VENDORS_DISCLOSED="vendorsDisclosed",t.VENDORS_ALLOWED="vendorsAllowed",t.PUBLISHER_TC="publisherTC"}(P||(P={}));class F{static ID_TO_KEY=[P.CORE,P.VENDORS_DISCLOSED,P.VENDORS_ALLOWED,P.PUBLISHER_TC];static KEY_TO_ID={[P.CORE]:0,[P.VENDORS_DISCLOSED]:1,[P.VENDORS_ALLOWED]:2,[P.PUBLISHER_TC]:3}}class N extends R{bitLength=0;maxId_=0;set_=new Set;*[Symbol.iterator](){for(let t=1;t<=this.maxId;t++)yield[t,this.has(t)]}values(){return this.set_.values()}get maxId(){return this.maxId_}has(t){return this.set_.has(t)}unset(t){Array.isArray(t)?t.forEach((t=>this.unset(t))):"object"==typeof t?this.unset(Object.keys(t).map((t=>Number(t)))):(this.set_.delete(Number(t)),this.bitLength=0,t===this.maxId&&(this.maxId_=0,this.set_.forEach((t=>{this.maxId_=Math.max(this.maxId,t)}))))}isIntMap(t){let i="object"==typeof t;return i=i&&Object.keys(t).every((i=>{let e=Number.isInteger(parseInt(i,10));return e=e&&this.isValidNumber(t[i].id),e=e&&void 0!==t[i].name,e})),i}isValidNumber(t){return parseInt(t,10)>0}isSet(t){let i=!1;return t instanceof Set&&(i=Array.from(t).every(this.isValidNumber)),i}set(t){if(Array.isArray(t))t.forEach((t=>this.set(t)));else if(this.isSet(t))this.set(Array.from(t));else if(this.isIntMap(t))this.set(Object.keys(t).map((t=>Number(t))));else{if(!this.isValidNumber(t))throw new E("set()",t,"must be positive integer array, positive integer, Set<number>, or IntMap");this.set_.add(t),this.maxId_=Math.max(this.maxId,t),this.bitLength=0}}empty(){this.set_=new Set}forEach(t){for(let i=1;i<=this.maxId;i++)t(this.has(i),i)}get size(){return this.set_.size}setAll(t){this.set(t)}}class j{static[B.cmpId]=12;static[B.cmpVersion]=12;static[B.consentLanguage]=12;static[B.consentScreen]=6;static[B.created]=36;static[B.isServiceSpecific]=1;static[B.lastUpdated]=36;static[B.policyVersion]=6;static[B.publisherCountryCode]=12;static[B.publisherLegitimateInterests]=24;static[B.publisherConsents]=24;static[B.purposeConsents]=24;static[B.purposeLegitimateInterests]=24;static[B.purposeOneTreatment]=1;static[B.specialFeatureOptins]=12;static[B.useNonStandardStacks]=1;static[B.vendorListVersion]=12;static[B.version]=6;static anyBoolean=1;static encodingType=1;static maxId=16;static numCustomPurposes=6;static numEntries=12;static numRestrictions=12;static purposeId=6;static restrictionType=2;static segmentType=3;static singleOrRange=1;static vendorId=16}class ${static encode(t,i){let e;if("string"==typeof t&&(t=parseInt(t,10)),e=t.toString(2),e.length>i||t<0)throw new k(`${t} too large to encode into ${i}`);return e.length<i&&(e="0".repeat(i-e.length)+e),e}static decode(t,i){if(i!==t.length)throw new T("invalid bit length");return parseInt(t,2)}}class U{static encode(t,i){return $.encode(Math.round(t.getTime()/100),i)}static decode(t,i){if(i!==t.length)throw new T("invalid bit length");const e=new Date;return e.setTime(100*$.decode(t,i)),e}}class q{static encode(t){return String(Number(t))}static decode(t){return"1"===t}}class H{static encode(t,i){let e="";for(let s=1;s<=i;s++)e+=q.encode(t.has(s));return e}static decode(t,i){if(t.length!==i)throw new T("bitfield encoding length mismatch");const e=new N;for(let s=1;s<=i;s++)q.decode(t[s-1])&&e.set(s);return e.bitLength=t.length,e}}class z{static encode(t,i){const e=(t=t.toUpperCase()).charCodeAt(0)-65,s=t.charCodeAt(1)-65;if(e<0||e>25||s<0||s>25)throw new k(`invalid language code: ${t}`);if(i%2==1)throw new k(`numBits must be even, ${i} is not valid`);i/=2;return $.encode(e,i)+$.encode(s,i)}static decode(t,i){let e;if(i!==t.length||t.length%2)throw new T("invalid bit length for language");{const i=65,s=t.length/2,n=$.decode(t.slice(0,s),s)+i,r=$.decode(t.slice(s),s)+i;e=String.fromCharCode(n)+String.fromCharCode(r)}return e}}class W{static encode(t){let i=$.encode(t.numRestrictions,j.numRestrictions);return t.isEmpty()||t.getRestrictions().forEach((e=>{i+=$.encode(e.purposeId,j.purposeId),i+=$.encode(e.restrictionType,j.restrictionType);const s=t.getVendors(e),n=s.length;let r=0,o=0,h="";for(let i=0;i<n;i++){const e=s[i];0===o&&(r++,o=e);const a=s[n-1],c=t.gvl.vendorIds,d=t=>{for(;++t<=a&&!c.has(t););return t};if(i===n-1||s[i+1]>d(e)){const t=!(e===o);h+=q.encode(t),h+=$.encode(o,j.vendorId),t&&(h+=$.encode(e,j.vendorId)),o=0}}i+=$.encode(r,j.numEntries),i+=h})),i}static decode(t){let i=0;const e=new V,s=$.decode(t.substr(i,j.numRestrictions),j.numRestrictions);i+=j.numRestrictions;for(let n=0;n<s;n++){const s=$.decode(t.substr(i,j.purposeId),j.purposeId);i+=j.purposeId;const n=$.decode(t.substr(i,j.restrictionType),j.restrictionType);i+=j.restrictionType;const r=new O(s,n),o=$.decode(t.substr(i,j.numEntries),j.numEntries);i+=j.numEntries;for(let s=0;s<o;s++){const s=q.decode(t.substr(i,j.anyBoolean));i+=j.anyBoolean;const n=$.decode(t.substr(i,j.vendorId),j.vendorId);if(i+=j.vendorId,s){const s=$.decode(t.substr(i,j.vendorId),j.vendorId);if(i+=j.vendorId,s<n)throw new T(`Invalid RangeEntry: endVendorId ${s} is less than ${n}`);for(let t=n;t<=s;t++)e.add(t,r)}else e.add(n,r)}}return e.bitLength=i,e}}!function(t){t[t.FIELD=0]="FIELD",t[t.RANGE=1]="RANGE"}(A||(A={}));class G{static encode(t){const i=[];let e,s=[],n=$.encode(t.maxId,j.maxId),r="";const o=j.maxId+j.encodingType,h=o+t.maxId,a=2*j.vendorId+j.singleOrRange+j.numEntries;let c=o+j.numEntries;return t.forEach(((n,o)=>{if(r+=q.encode(n),e=t.maxId>a&&c<h,e&&n){t.has(o+1)?0===s.length&&(s.push(o),c+=j.singleOrRange,c+=j.vendorId):(s.push(o),c+=j.vendorId,i.push(s),s=[])}})),e?(n+=String(A.RANGE),n+=this.buildRangeEncoding(i)):(n+=String(A.FIELD),n+=r),n}static decode(t,i){let e,s=0;const n=$.decode(t.substr(s,j.maxId),j.maxId);s+=j.maxId;const r=$.decode(t.charAt(s),j.encodingType);if(s+=j.encodingType,r===A.RANGE){if(e=new N,1===i){if("1"===t.substr(s,1))throw new T("Unable to decode default consent=1");s++}const n=$.decode(t.substr(s,j.numEntries),j.numEntries);s+=j.numEntries;for(let i=0;i<n;i++){const i=q.decode(t.charAt(s));s+=j.singleOrRange;const n=$.decode(t.substr(s,j.vendorId),j.vendorId);if(s+=j.vendorId,i){const i=$.decode(t.substr(s,j.vendorId),j.vendorId);s+=j.vendorId;for(let t=n;t<=i;t++)e.set(t)}else e.set(n)}}else{const i=t.substr(s,n);s+=n,e=H.decode(i,n)}return e.bitLength=s,e}static buildRangeEncoding(t){const i=t.length;let e=$.encode(i,j.numEntries);return t.forEach((t=>{const i=1===t.length;e+=q.encode(!i),e+=$.encode(t[0],j.vendorId),i||(e+=$.encode(t[1],j.vendorId))})),e}}function X(){return{[B.version]:$,[B.created]:U,[B.lastUpdated]:U,[B.cmpId]:$,[B.cmpVersion]:$,[B.consentScreen]:$,[B.consentLanguage]:z,[B.vendorListVersion]:$,[B.policyVersion]:$,[B.isServiceSpecific]:q,[B.useNonStandardStacks]:q,[B.specialFeatureOptins]:H,[B.purposeConsents]:H,[B.purposeLegitimateInterests]:H,[B.purposeOneTreatment]:q,[B.publisherCountryCode]:z,[B.vendorConsents]:G,[B.vendorLegitimateInterests]:G,[B.publisherRestrictions]:W,segmentType:$,[B.vendorsDisclosed]:G,[B.vendorsAllowed]:G,[B.publisherConsents]:H,[B.publisherLegitimateInterests]:H,[B.numCustomPurposes]:$,[B.publisherCustomConsents]:H,[B.publisherCustomLegitimateInterests]:H}}class Q{1={[P.CORE]:[B.version,B.created,B.lastUpdated,B.cmpId,B.cmpVersion,B.consentScreen,B.consentLanguage,B.vendorListVersion,B.purposeConsents,B.vendorConsents]};2={[P.CORE]:[B.version,B.created,B.lastUpdated,B.cmpId,B.cmpVersion,B.consentScreen,B.consentLanguage,B.vendorListVersion,B.policyVersion,B.isServiceSpecific,B.useNonStandardStacks,B.specialFeatureOptins,B.purposeConsents,B.purposeLegitimateInterests,B.purposeOneTreatment,B.publisherCountryCode,B.vendorConsents,B.vendorLegitimateInterests,B.publisherRestrictions],[P.PUBLISHER_TC]:[B.publisherConsents,B.publisherLegitimateInterests,B.numCustomPurposes,B.publisherCustomConsents,B.publisherCustomLegitimateInterests],[P.VENDORS_ALLOWED]:[B.vendorsAllowed],[P.VENDORS_DISCLOSED]:[B.vendorsDisclosed]}}class J{1=[P.CORE];2=[P.CORE];constructor(t,i){if(2===t.version)if(t.isServiceSpecific)this[2].push(P.PUBLISHER_TC);else{const e=!(!i||!i.isForVendors);e&&!0!==t[B.supportOOB]||this[2].push(P.VENDORS_DISCLOSED),e&&(t[B.supportOOB]&&t[B.vendorsAllowed].size>0&&this[2].push(P.VENDORS_ALLOWED),this[2].push(P.PUBLISHER_TC))}}}class Y{static fieldSequence=new Q;static encode(t,i){let e;try{e=this.fieldSequence[String(t.version)][i]}catch(e){throw new k(`Unable to encode version: ${t.version}, segment: ${i}`)}let s="";i!==P.CORE&&(s=$.encode(F.KEY_TO_ID[i],j.segmentType));const n=X();return e.forEach((e=>{const r=t[e],o=n[e];let h=j[e];void 0===h&&this.isPublisherCustom(e)&&(h=Number(t[B.numCustomPurposes]));try{s+=o.encode(r,h)}catch(t){throw new k(`Error encoding ${i}->${e}: ${t.message}`)}})),M.encode(s)}static decode(t,i,e){const s=M.decode(t);let n=0;e===P.CORE&&(i.version=$.decode(s.substr(n,j[B.version]),j[B.version])),e!==P.CORE&&(n+=j.segmentType);const r=this.fieldSequence[String(i.version)][e],o=X();return r.forEach((t=>{const e=o[t];let r=j[t];if(void 0===r&&this.isPublisherCustom(t)&&(r=Number(i[B.numCustomPurposes])),0!==r){const o=s.substr(n,r);if(i[t]=e===G?e.decode(o,i.version):e.decode(o,r),Number.isInteger(r))n+=r;else{if(!Number.isInteger(i[t].bitLength))throw new T(t);n+=i[t].bitLength}}})),i}static isPublisherCustom(t){return 0===t.indexOf("publisherCustom")}}class K{static processor=[t=>t,(t,i)=>{t.publisherRestrictions.gvl=i,t.purposeLegitimateInterests.unset(1);const e=new Map;return e.set("legIntPurposes",t.vendorLegitimateInterests),e.set("purposes",t.vendorConsents),e.forEach(((e,s)=>{e.forEach(((n,r)=>{if(n){const n=i.vendors[r];if(!n||n.deletedDate)e.unset(r);else if(0===n[s].length)if("legIntPurposes"===s&&0===n.purposes.length&&0===n.legIntPurposes.length&&n.specialPurposes.length>0);else if(t.isServiceSpecific)if(0===n.flexiblePurposes.length)e.unset(r);else{const i=t.publisherRestrictions.getRestrictions(r);let n=!1;for(let t=0,e=i.length;t<e&&!n;t++)n=i[t].restrictionType===w.REQUIRE_CONSENT&&"purposes"===s||i[t].restrictionType===w.REQUIRE_LI&&"legIntPurposes"===s;n||e.unset(r)}else e.unset(r)}}))})),t.vendorsDisclosed.set(i.vendors),t}];static process(t,i){const e=t.gvl;if(!e)throw new k("Unable to encode TCModel without a GVL");if(!e.isReady)throw new k("Unable to encode TCModel tcModel.gvl.readyPromise is not resolved");(t=t.clone()).consentLanguage=e.language.toUpperCase(),i?.version>0&&i?.version<=this.processor.length?t.version=i.version:t.version=this.processor.length;const s=t.version-1;if(!this.processor[s])throw new k(`Invalid version: ${t.version}`);return this.processor[s](t,e)}}class Z{static absCall(t,i,e,s){return new Promise(((n,r)=>{const o=new XMLHttpRequest;o.withCredentials=e,o.addEventListener("load",(()=>{if(o.readyState==XMLHttpRequest.DONE)if(o.status>=200&&o.status<300){let t=o.response;if("string"==typeof t)try{t=JSON.parse(t)}catch(t){}n(t)}else r(new Error(`HTTP Status: ${o.status} response type: ${o.responseType}`))})),o.addEventListener("error",(()=>{r(new Error("error"))})),o.addEventListener("abort",(()=>{r(new Error("aborted"))})),null===i?o.open("GET",t,!0):o.open("POST",t,!0),o.responseType="json",o.timeout=s,o.ontimeout=()=>{r(new Error("Timeout "+s+"ms "+t))},o.send(i)}))}static post(t,i,e=!1,s=0){return this.absCall(t,JSON.stringify(i),e,s)}static fetch(t,i=!1,e=0){return this.absCall(t,null,i,e)}}class tt extends R{static LANGUAGE_CACHE=new Map;static CACHE=new Map;static LATEST_CACHE_KEY=0;static DEFAULT_LANGUAGE="EN";static consentLanguages=new L;static baseUrl_;static set baseUrl(t){if(/^https?:\/\/vendorlist\.consensu\.org\//.test(t))throw new C("Invalid baseUrl!  You may not pull directly from vendorlist.consensu.org and must provide your own cache");t.length>0&&"/"!==t[t.length-1]&&(t+="/"),this.baseUrl_=t}static get baseUrl(){return this.baseUrl_}static latestFilename="vendor-list.json";static versionedFilename="archives/vendor-list-v[VERSION].json";static languageFilename="purposes-[LANG].json";readyPromise;gvlSpecificationVersion;vendorListVersion;tcfPolicyVersion;lastUpdated;purposes;specialPurposes;features;specialFeatures;isReady_=!1;vendors_;vendorIds;fullVendorList;byPurposeVendorMap;bySpecialPurposeVendorMap;byFeatureVendorMap;bySpecialFeatureVendorMap;stacks;lang_;isLatest=!1;constructor(t){super();let i=tt.baseUrl;if(this.lang_=tt.DEFAULT_LANGUAGE,this.isVendorList(t))this.populate(t),this.readyPromise=Promise.resolve();else{if(!i)throw new C("must specify GVL.baseUrl before loading GVL json");if(t>0){const e=t;tt.CACHE.has(e)?(this.populate(tt.CACHE.get(e)),this.readyPromise=Promise.resolve()):(i+=tt.versionedFilename.replace("[VERSION]",String(e)),this.readyPromise=this.fetchJson(i))}else tt.CACHE.has(tt.LATEST_CACHE_KEY)?(this.populate(tt.CACHE.get(tt.LATEST_CACHE_KEY)),this.readyPromise=Promise.resolve()):(this.isLatest=!0,this.readyPromise=this.fetchJson(i+tt.latestFilename))}}static emptyLanguageCache(t){let i=!1;return void 0===t&&tt.LANGUAGE_CACHE.size>0?(tt.LANGUAGE_CACHE=new Map,i=!0):"string"==typeof t&&this.consentLanguages.has(t.toUpperCase())&&(tt.LANGUAGE_CACHE.delete(t.toUpperCase()),i=!0),i}static emptyCache(t){let i=!1;return Number.isInteger(t)&&t>=0?(tt.CACHE.delete(t),i=!0):void 0===t&&(tt.CACHE=new Map,i=!0),i}cacheLanguage(){tt.LANGUAGE_CACHE.has(this.lang_)||tt.LANGUAGE_CACHE.set(this.lang_,{purposes:this.purposes,specialPurposes:this.specialPurposes,features:this.features,specialFeatures:this.specialFeatures,stacks:this.stacks})}async fetchJson(t){try{this.populate(await Z.fetch(t))}catch(t){throw new C(t.message)}}getJson(){return JSON.parse(JSON.stringify({gvlSpecificationVersion:this.gvlSpecificationVersion,vendorListVersion:this.vendorListVersion,tcfPolicyVersion:this.tcfPolicyVersion,lastUpdated:this.lastUpdated,purposes:this.purposes,specialPurposes:this.specialPurposes,features:this.features,specialFeatures:this.specialFeatures,stacks:this.stacks,vendors:this.fullVendorList}))}async changeLanguage(t){const i=t.toUpperCase();if(!tt.consentLanguages.has(i))throw new C(`unsupported language ${t}`);if(i!==this.lang_)if(this.lang_=i,tt.LANGUAGE_CACHE.has(i)){const t=tt.LANGUAGE_CACHE.get(i);for(const i in t)t.hasOwnProperty(i)&&(this[i]=t[i])}else{const i=tt.baseUrl+tt.languageFilename.replace("[LANG]",t);try{await this.fetchJson(i),this.cacheLanguage()}catch(t){throw new C("unable to load language: "+t.message)}}}get language(){return this.lang_}isVendorList(t){return void 0!==t&&void 0!==t.vendors}populate(t){this.purposes=t.purposes,this.specialPurposes=t.specialPurposes,this.features=t.features,this.specialFeatures=t.specialFeatures,this.stacks=t.stacks,this.isVendorList(t)&&(this.gvlSpecificationVersion=t.gvlSpecificationVersion,this.tcfPolicyVersion=t.tcfPolicyVersion,this.vendorListVersion=t.vendorListVersion,this.lastUpdated=t.lastUpdated,"string"==typeof this.lastUpdated&&(this.lastUpdated=new Date(this.lastUpdated)),this.vendors_=t.vendors,this.fullVendorList=t.vendors,this.mapVendors(),this.isReady_=!0,this.isLatest&&tt.CACHE.set(tt.LATEST_CACHE_KEY,this.getJson()),tt.CACHE.has(this.vendorListVersion)||tt.CACHE.set(this.vendorListVersion,this.getJson())),this.cacheLanguage()}mapVendors(t){this.byPurposeVendorMap={},this.bySpecialPurposeVendorMap={},this.byFeatureVendorMap={},this.bySpecialFeatureVendorMap={},Object.keys(this.purposes).forEach((t=>{this.byPurposeVendorMap[t]={legInt:new Set,consent:new Set,flexible:new Set}})),Object.keys(this.specialPurposes).forEach((t=>{this.bySpecialPurposeVendorMap[t]=new Set})),Object.keys(this.features).forEach((t=>{this.byFeatureVendorMap[t]=new Set})),Object.keys(this.specialFeatures).forEach((t=>{this.bySpecialFeatureVendorMap[t]=new Set})),Array.isArray(t)||(t=Object.keys(this.fullVendorList).map((t=>+t))),this.vendorIds=new Set(t),this.vendors_=t.reduce(((t,i)=>{const e=this.vendors_[String(i)];return e&&void 0===e.deletedDate&&(e.purposes.forEach((t=>{this.byPurposeVendorMap[String(t)].consent.add(i)})),e.specialPurposes.forEach((t=>{this.bySpecialPurposeVendorMap[String(t)].add(i)})),e.legIntPurposes.forEach((t=>{this.byPurposeVendorMap[String(t)].legInt.add(i)})),e.flexiblePurposes&&e.flexiblePurposes.forEach((t=>{this.byPurposeVendorMap[String(t)].flexible.add(i)})),e.features.forEach((t=>{this.byFeatureVendorMap[String(t)].add(i)})),e.specialFeatures.forEach((t=>{this.bySpecialFeatureVendorMap[String(t)].add(i)})),t[i]=e),t}),{})}getFilteredVendors(t,i,e,s){const n=t.charAt(0).toUpperCase()+t.slice(1);let r;const o={};return r="purpose"===t&&e?this["by"+n+"VendorMap"][String(i)][e]:this["by"+(s?"Special":"")+n+"VendorMap"][String(i)],r.forEach((t=>{o[String(t)]=this.vendors[String(t)]})),o}getVendorsWithConsentPurpose(t){return this.getFilteredVendors("purpose",t,"consent")}getVendorsWithLegIntPurpose(t){return this.getFilteredVendors("purpose",t,"legInt")}getVendorsWithFlexiblePurpose(t){return this.getFilteredVendors("purpose",t,"flexible")}getVendorsWithSpecialPurpose(t){return this.getFilteredVendors("purpose",t,void 0,!0)}getVendorsWithFeature(t){return this.getFilteredVendors("feature",t)}getVendorsWithSpecialFeature(t){return this.getFilteredVendors("feature",t,void 0,!0)}get vendors(){return this.vendors_}narrowVendorsTo(t){this.mapVendors(t)}get isReady(){return this.isReady_}clone(){const t=new tt(this.getJson());return this.lang_!==tt.DEFAULT_LANGUAGE&&t.changeLanguage(this.lang_),t}static isInstanceOf(t){return"object"==typeof t&&"function"==typeof t.narrowVendorsTo}}class it extends R{static consentLanguages=tt.consentLanguages;isServiceSpecific_=!1;supportOOB_=!0;useNonStandardStacks_=!1;purposeOneTreatment_=!1;publisherCountryCode_="AA";version_=2;consentScreen_=0;policyVersion_=2;consentLanguage_="EN";cmpId_=0;cmpVersion_=0;vendorListVersion_=0;numCustomPurposes_=0;gvl_;created;lastUpdated;specialFeatureOptins=new N;purposeConsents=new N;purposeLegitimateInterests=new N;publisherConsents=new N;publisherLegitimateInterests=new N;publisherCustomConsents=new N;publisherCustomLegitimateInterests=new N;customPurposes;vendorConsents=new N;vendorLegitimateInterests=new N;vendorsDisclosed=new N;vendorsAllowed=new N;publisherRestrictions=new V;constructor(t){super(),t&&(this.gvl=t),this.updated()}set gvl(t){tt.isInstanceOf(t)||(t=new tt(t)),this.gvl_=t,this.publisherRestrictions.gvl=t}get gvl(){return this.gvl_}set cmpId(t){if(t=Number(t),!(Number.isInteger(t)&&t>1))throw new E("cmpId",t);this.cmpId_=t}get cmpId(){return this.cmpId_}set cmpVersion(t){if(t=Number(t),!(Number.isInteger(t)&&t>-1))throw new E("cmpVersion",t);this.cmpVersion_=t}get cmpVersion(){return this.cmpVersion_}set consentScreen(t){if(t=Number(t),!(Number.isInteger(t)&&t>-1))throw new E("consentScreen",t);this.consentScreen_=t}get consentScreen(){return this.consentScreen_}set consentLanguage(t){this.consentLanguage_=t}get consentLanguage(){return this.consentLanguage_}set publisherCountryCode(t){if(!/^([A-z]){2}$/.test(t))throw new E("publisherCountryCode",t);this.publisherCountryCode_=t.toUpperCase()}get publisherCountryCode(){return this.publisherCountryCode_}set vendorListVersion(t){if((t=Number(t)>>0)<0)throw new E("vendorListVersion",t);this.vendorListVersion_=t}get vendorListVersion(){return this.gvl?this.gvl.vendorListVersion:this.vendorListVersion_}set policyVersion(t){if(this.policyVersion_=parseInt(t,10),this.policyVersion_<0)throw new E("policyVersion",t)}get policyVersion(){return this.gvl?this.gvl.tcfPolicyVersion:this.policyVersion_}set version(t){this.version_=parseInt(t,10)}get version(){return this.version_}set isServiceSpecific(t){this.isServiceSpecific_=t}get isServiceSpecific(){return this.isServiceSpecific_}set useNonStandardStacks(t){this.useNonStandardStacks_=t}get useNonStandardStacks(){return this.useNonStandardStacks_}set supportOOB(t){this.supportOOB_=t}get supportOOB(){return this.supportOOB_}set purposeOneTreatment(t){this.purposeOneTreatment_=t}get purposeOneTreatment(){return this.purposeOneTreatment_}setAllVendorConsents(){this.vendorConsents.set(this.gvl.vendors)}unsetAllVendorConsents(){this.vendorConsents.empty()}setAllVendorsDisclosed(){this.vendorsDisclosed.set(this.gvl.vendors)}unsetAllVendorsDisclosed(){this.vendorsDisclosed.empty()}setAllVendorsAllowed(){this.vendorsAllowed.set(this.gvl.vendors)}unsetAllVendorsAllowed(){this.vendorsAllowed.empty()}setAllVendorLegitimateInterests(){this.vendorLegitimateInterests.set(this.gvl.vendors)}unsetAllVendorLegitimateInterests(){this.vendorLegitimateInterests.empty()}setAllPurposeConsents(){this.purposeConsents.set(this.gvl.purposes)}unsetAllPurposeConsents(){this.purposeConsents.empty()}setAllPurposeLegitimateInterests(){this.purposeLegitimateInterests.set(this.gvl.purposes)}unsetAllPurposeLegitimateInterests(){this.purposeLegitimateInterests.empty()}setAllSpecialFeatureOptins(){this.specialFeatureOptins.set(this.gvl.specialFeatures)}unsetAllSpecialFeatureOptins(){this.specialFeatureOptins.empty()}setAll(){this.setAllVendorConsents(),this.setAllPurposeLegitimateInterests(),this.setAllSpecialFeatureOptins(),this.setAllPurposeConsents(),this.setAllVendorLegitimateInterests()}unsetAll(){this.unsetAllVendorConsents(),this.unsetAllPurposeLegitimateInterests(),this.unsetAllSpecialFeatureOptins(),this.unsetAllPurposeConsents(),this.unsetAllVendorLegitimateInterests()}get numCustomPurposes(){let t=this.numCustomPurposes_;if("object"==typeof this.customPurposes){const i=Object.keys(this.customPurposes).sort(((t,i)=>Number(t)-Number(i)));t=parseInt(i.pop(),10)}return t}set numCustomPurposes(t){if(this.numCustomPurposes_=parseInt(t,10),this.numCustomPurposes_<0)throw new E("numCustomPurposes",t)}updated(){const t=new Date,i=new Date(Date.UTC(t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate()));this.created=i,this.lastUpdated=i}}class et{static encode(t,i){let e,s="";return t=K.process(t,i),e=Array.isArray(i?.segments)?i.segments:new J(t,i)[""+t.version],e.forEach(((i,n)=>{let r="";n<e.length-1&&(r="."),s+=Y.encode(t,i)+r})),s}static decode(t,i){const e=t.split("."),s=e.length;i||(i=new it);for(let t=0;t<s;t++){const s=e[t],n=M.decode(s.charAt(0)).substr(0,j.segmentType),r=F.ID_TO_KEY[$.decode(n,j.segmentType).toString()];Y.decode(s,i,r)}return i}}const st=(t,i)=>{const e=b[i].windowPropertyName;return(0,_.uq)(t,e)},nt=(t,i)=>{const e=b[i].framePropertyName;return(0,_.wl)(t,e)},rt=(t,i)=>null!==st(t,i)||null!==nt(t,i),ot=t=>{const i=et.decode(t),e={},s={};return i.vendorConsents.forEach(((t,i)=>e[i]=t)),i.purposeConsents.forEach(((t,i)=>s[i]=t)),{vendorConsents:e,purposeConsents:s,tcString:t}},ht=t=>{const i=x.decodeConsentString(t);let e="";const s=i.maxVendorId;for(let t=1;t<=s;t++)e+="0";const n=e.split("");i.allowedVendorIds.forEach((t=>{n[t-1]="1"}));return(t=>{const i={consentString:t};for(let e=0;e<t.length;e++)i[e+1]="1"===t[e];return i})(n.join(""))},at=(t,i,e)=>{let s;try{s=i(t)}catch(t){}if((0,c.as)(s))return s;try{s=e(t)}catch(t){}return s},ct=t=>(0,c.QM)(null==t?void 0:t.tcString),dt=t=>(0,c.QM)(null==t?void 0:t.consentString),lt=({cmpEncodedString:t,tcfEncodedString:i})=>{if(!(0,c.QM)(t)&&!(0,c.QM)(i))return null;let e=null;return(0,c.QM)(i)&&(e=at(i,ot,ht)),(0,c.as)(e)?e:(0,c.QM)(t)?(e=at(t,ht,ot),(0,c.as)(e)?e:((0,g.n)({message:"UserManagerService_getDecodedConsentData",exception:"cmpEncodedString failed to decode",callStack:JSON.stringify({cmpEncodedString:t,tcfEncodedString:i}),level:g.D.CRITICAL}),null)):((0,g.n)({message:"UserManagerService_getDecodedConsentData",exception:"tcfEncodedString failed to decode",callStack:JSON.stringify({tcfEncodedString:i}),level:g.D.CRITICAL}),null)};class ut{constructor(t,i){this.$a=t,this.Ua=i,this.apiType=f.TcfApi,this.qa=t=>new Promise(((i,e)=>{try{let s=t.data;if("string"==typeof t.data)try{s=JSON.parse(t.data)}catch(t){s=void 0}if("object"==typeof s&&s.Ha&&s.Ha.callId===this.za){const t=s.Ha.returnValue.tcString;this.Oa(t).then((()=>i(this.za))).catch((t=>e()))}}catch(t){e()}}))}isApiOnPage(){return null!==this.$a||null!==this.Ua}bindToApi(){return null!==this.$a?new Promise(((t,i)=>{this.Fa(this.$a).then((()=>t())).catch((t=>i(t)))})):null!==this.Ua?this.Na(this.Ua):Promise.reject()}isConsentForVendor(t){var i,e;return!!(null===(i=this.Wa)||void 0===i?void 0:i.vendorConsents)&&!!(null===(e=this.Wa)||void 0===e?void 0:e.vendorConsents[t])}getConsentPayload(){var t;return null===(t=this.Wa)||void 0===t?void 0:t.tcString}setInAppConsentData(t){this.Wa=Object.assign(Object.assign({},this.Wa),t)}hasIvtConsent(){return!0}isConsentForPurposes(t){var i;return!!(null===(i=this.Wa)||void 0===i?void 0:i.purposeConsents)&&t.every((t=>!!this.Wa.purposeConsents[t]))}Na(t){this.za=(0,n.qs)();const i={};return new Promise((e=>{const s=t=>{this.qa(t).then((t=>{i[t]=!0,i[this.za]&&(window.removeEventListener("message",s,!1),e())})).catch((t=>{}))};window.addEventListener("message",s,!1);const n=b[f.TcfApi].getVendorConsentDataMethodName;t.postMessage({Ga:{command:n,parameter:null,callId:this.za}},"*")}))}Fa(t){const i=b[f.TcfApi].windowPropertyName,e=b[f.TcfApi].consentUpdateMethodName,s=b[f.TcfApi].removeUpdateListenerMethodName;return t&&t[i]?new Promise((t=>{this.$a[i](e,2,((e,n)=>{if(n&&("useractioncomplete"===e.eventStatus||"tcloaded"===e.eventStatus)){const n=e.tcString;this.Oa(n).then((()=>t())),this.$a[i](s,2,(()=>{}),e.listenerId)}}))})):Promise.reject()}Oa(t){const i=lt({tcfEncodedString:t});return ct(i)?(this.Wa=i,Promise.resolve()):Promise.reject()}}var pt=e(3199);class ft{constructor(t,i,e={}){var s,n;this.Xa=t,this.Ci=i;const r=lt({cmpEncodedString:null===(s=e.cmp)||void 0===s?void 0:s.consentString,tcfEncodedString:null===(n=e.tcf)||void 0===n?void 0:n.tcString}),o=this.Qa(r);null!==o?(this.Ja(o),(ct(r)||dt(r))&&this.Ya.setInAppConsentData(r)):(0,g.n)({message:"UserManagerService_UserConsentApiManager",exception:"failed to find the right api, no consent string and no framework on page was found",callStack:JSON.stringify({_appSettings:e}),level:g.D.CRITICAL})}setPageUrl(t){this.Rs=t}setAmpUserConsent(t){var i,e;if(!this.isConsentRequired())return;const s=t.consentStringTypeEnum.US_PRIVACY_STRING,n=null===(i=t.consentMetadata)||void 0===i?void 0:i.consentStringType,r=t.encodeConsentString||(null===(e=t.consentMetadata)||void 0===e?void 0:e.additionalConsent);let o;if(!(0,c.QM)(r))return void(0,g.n)({level:g.D.INFO,message:"AMP_no_consent_string_provided",callStack:JSON.stringify(t),exception:this.Rs});if(n===s)return void(0,g.n)({message:"UserConsentApiManager_CCPA_encoded_string_from_amp_not_used",level:g.D.WARN,callStack:r,exception:`${JSON.stringify(t)}__pageURL_${this.Rs}`},{throttle:2,shouldSendMaxLog:!1});const h=lt({tcfEncodedString:r,cmpEncodedString:r});ct(h)?o=new ut(null,null):dt(h)&&(o=new I(null,null)),o?o?(this.Ya=o,this.Ya.setInAppConsentData(h)):(0,g.n)({message:"UserConsentApiManager_amp_userConsentApi_not_found",level:g.D.WARN,callStack:r,exception:`${JSON.stringify(t)}__pageURL__${this.Rs}`},{shouldSendMaxLog:!1,throttle:2}):(0,g.n)({message:"UserConsentApiManager_encoded_string_not_tcf_and_not_cmp",level:g.D.WARN,callStack:r,exception:`${JSON.stringify(t)}__pageURL__${this.Rs}`},{throttle:2,shouldSendMaxLog:!1})}isConsentRequired(){return this.Xa}isConsent(t,i=[]){if(this.isConsentRequired()){return this.Ya.isConsentForVendor(t)&&this.Ya.isConsentForPurposes(i)}return!0}isConsentConnatix(){return this.isConsent(s.Connatix,pt.Z)}isConsentForPersonalisedAds(){return this.getConsentApiType()!==f.CmpApi&&this.Ya.isConsentForPurposes(pt.Z)}getConsentDataPayload(){return this.Ya.getConsentPayload()}bindToConsentApi(){return this.Ya.bindToApi()}isConsentApiOnPage(){return this.Ya.isApiOnPage()}hasIVTConsent(){return this.Ya.hasIvtConsent()}getConsentApiType(){return this.Ya.apiType}Ja(t){const i=st(this.Ci,t),e=nt(this.Ci,t);t===f.TcfApi?this.Ya=new ut(i,e):this.Ya=new I(i,e)}Qa(t){if(ct(t))return f.TcfApi;if(dt(t))return f.CmpApi;if(rt(this.Ci,f.TcfApi))return f.TcfApi;return rt(this.Ci,f.CmpApi)?f.CmpApi:f.TcfApi}}var mt=e(51);const gt="PUBMATIC",vt="predirect",yt="UserThirdPartySyncManager_Pubmatic",bt="CookieSync_syncScript_not_properly_loaded",It="CookieSync_param_not_parsed_properly",wt=(t,i)=>{if(!window.PubMaticSync)return Pt(bt,gt),!1;const e=Number.parseInt(t,10);return(0,c.hj)(e)?!!(0,c.QM)(i)||(Pt(It,gt,vt),!1):(Pt(It,gt,"p"),!1)},St=(t,i,e,s)=>{const n={pubId:Number.parseInt(t,10),url:i};e&&(n.delay=1e3,n.gdpr=1,n.gdprConsent=s),window.PubMaticSync.sync(n)},Pt=(t,i,e="")=>{(0,g.n)({message:t,callStack:i,exception:e,level:g.D.CRITICAL},{throttle:1,shouldSendMaxLog:!1})};class At{constructor(t,i){this.Ka=t,this.Xa=i,this.Za=[]}replaceuserIdMacros(t,i){let e=t;return e=e.replace("%5BuserId%5D",i),e=e.replace("[userId]",i),e=e.replace("%7bUSER_ID%7d",i),e}tc(t,i){try{if(this.ic(t)){const e=i.document.createElement("iframe");e.setAttribute("style","width:1px;height:1px;border:0px;margin:0px;padding:0px"),e.src=t.url,i.document.body.appendChild(e)}else(0,_.dZ)({src:t.url},i.document.head,i,null,null,1===(0,n.Vm)([99,1]),"UserManager_unable_to_insert_sync_url_script");return!0}catch(t){return!1}}ic(t){switch(t.vendorId){case s.Rubicon:case s.Pubmatic:return!0;default:return!!t.url.includes("yellowblue.io")}}syncUrls(t,i){this.Za.forEach((e=>{if(this.Ka.isConsent(e.vendorId)&&!e.synced){if(e.vendorId===s.Pubmatic)return void((t,i,e)=>new Promise(((s,n)=>{const r=(0,mt.Ph)("p",t),o=(0,mt.Ph)(vt,t);if(window.PubMaticSync){if(!wt(r,o))return void n();St(r,o,i,e),s(!0)}else(0,_.dZ)({src:"//ads.pubmatic.com/AdServer/js/userSync.js"},window.document.head,window,(()=>{wt(r,o)?(St(r,o,i,e),s(!0)):n()}),(()=>{n()}),!0,yt)})))(e.url,this.Ka.isConsentRequired(),this.Ka.getConsentDataPayload()).then((()=>{e.synced=!0}));if(e.url.includes("openx.net")||e.url.includes("sync.technoratimedia.com/services"))return o.n.trackPixel(e.url),void(e.synced=!0);if("755"===e.vendorId){const t=this.Ka.getConsentDataPayload(),i=this.Ka.isConsentRequired();return e.url=(0,mt.Bp)(e.url,"gdpr",""+(i?1:0)),i&&(e.url=(0,mt.Bp)(e.url,"gdpr_consent",t)),o.n.trackPixel(e.url),void(e.synced=!0)}if(e.url.includes("pixel.advertising.com")&&(e.url=e.url.replace("gdpr=","gdpr="+(this.Ka.isConsentRequired()?1:0)),e.url=e.url.replace("gdpr_consent=","gdpr_consent=0")),e.url=this.replaceuserIdMacros(e.url,t),this.Xa){e.url=(0,mt.Bp)(e.url,"gdpr","1");const t=this.Ka.getConsentDataPayload();e.url=(0,mt.Bp)(e.url,"gdpr_consent",t)}this.tc(e,i)&&(e.synced=!0)}}))}setSyncUrls(t={}){return!(this.Za.length>0)&&(this.Za=[],Object.keys(t).forEach((i=>{this.Za.push({vendorId:i,url:t[i],synced:!1})})),!0)}}var _t=e(7994);const xt={California:5332921,Virginia:6254928},Tt={US:6252001};var kt;!function(t){t.CCPA_Error="CCPA Error",t.CCPA_Pending="CCPA Pending",t.CCPA_Success="CCPA Success",t.CCPA_Delayed_Success="CCPA Delayed Success",t.CCPA_Delayed_Failure="CCPA Delayed Failure"}(kt||(kt={}));class Ct{constructor(t,i){this.ba=t,this.ec=1,this.sc="__uspapi",this.rc="getUSPData",this.oc={isPending:!0,isRejected:!1,isDelayed:!1,promise:new Promise((()=>{}))},this.hc(i)}getUsPrivacyString(){if(this.ba.usPrivacyString||this.ba.isCcpaApplicable)return this.ba.usPrivacyString}isCcpaApplicable(){return this.ba.isCcpaApplicable}isSellUserAllowed(){return!this.ba.isCcpaApplicable||this.ac()}setGeoLocation(t){this.dc=t,t.subdivisionId!==xt.California&&t.subdivisionId!==xt.Virginia&&(this.ba.isCcpaApplicable=!1)}fetchUsPrivacyString(){return this.fc()&&this.mc(),this.isCcpaApplicable()?new Promise((t=>{this.getUsPrivacyString()?t():t(this.gc())})):Promise.resolve()}gc(){return this.oc.promise=new Promise(((t,i)=>{const e=this.ba.getScope()[this.sc];e?(this.vc=!0,e(this.rc,this.ec,((e,s)=>{s?(this.hc(e.uspString),t()):i()}))):i()})),this.makeQuerablePromise(this.oc),this.oc.promise}ac(){return!this.ba.usPrivacyString||(0,v.d3)(this.ba.usPrivacyString,r)}hc(t){this.ba.usPrivacyString=t}fc(){if(!(0,n.Vm)([95,5]))return!1;const t=new Date(2020,10,16,12,0,0).getTime(),i=new Date(2020,10,17,12,0,0).getTime();return(0,m.k$)(t,i)}mc(){const{countryGeoId:t,subdivisionId:i}=this.dc;t===Tt.US&&(0,g.n)({message:"UserCcpaManager_logCCPA",level:g.D.INFO,callStack:JSON.stringify(i),exception:this.ba.usPrivacyString})}ccpaInfoLogging(t){this.isCcpaApplicable()&&this.vc&&(this.oc.isPending?((0,g.n)({message:kt.CCPA_Pending,exception:"CCPA_Pending_At_Start_AdRequest",level:g.D.INFO,callStack:t}),this.oc.isDelayed=!0,this.yc=t):this.oc.isRejected&&(0,g.n)({message:kt.CCPA_Error,exception:"CCPA_Error_At_Start_AdRequest",level:g.D.INFO,callStack:t}))}makeQuerablePromise(t){t.promise.then((()=>{t.isPending=!1,t.isDelayed&&(0,g.n)({message:kt.CCPA_Delayed_Success,exception:"CCPA_Success_After_Delay",level:g.D.INFO,callStack:this.yc})})).catch((i=>{throw t.isRejected=!0,t.isPending=!1,t.isDelayed&&(0,g.n)({message:kt.CCPA_Delayed_Failure,exception:"CCPA_Failed_After_Delay",level:g.D.INFO,callStack:this.yc}),i}))}}var Et,Mt,Lt=e(2450);!function(t){t.CCPA_INFO_RECEIVED="ccpaInfoReceived",t.CONSENT_DATA_UPDATE="consentDataUpdate"}(Et||(Et={})),function(t){t.SYNC_URLS_RECEIVED="thirdPartySyncUrlsReceived",t.USER_INFO_RECEIVED="userInfoReceived"}(Mt||(Mt={}));class Bt{constructor(t,i,e,s={}){this.bc=i,this.Yi=e,this._appSettings=s,this.gdprConsentMode=h.ProtoGdprConsentModeEnum.Unknown,this.Ic={},this.wc="{{isEu}}",this.Sc=!1,this.Pc=()=>{!this.Ka.isConsentRequired()||this.bc?this.resolveEvent(Et.CONSENT_DATA_UPDATE):(this.gdprConsentMode=this.Ka.isConsentApiOnPage()||this.Yi?h.ProtoGdprConsentModeEnum.NoConsent:h.ProtoGdprConsentModeEnum.NoCmp,this.Ka.bindToConsentApi().then((()=>{this.isConsentConnatix()||(this.gdprConsentMode=h.ProtoGdprConsentModeEnum.NoConnatixConsent),this.resolveEvent(Et.CONSENT_DATA_UPDATE)})).catch((t=>{})))},this.Ac=()=>{Lt.$.getEnvelope(this.li,this.Ka)},this._c=()=>{this.isConsentConnatix()&&(this.onEvent([Mt.USER_INFO_RECEIVED]).then((()=>{this.Sc&&(this.xc.syncThirdPartyCookieList(),this.xc.unsecuredCookieSync&&this.xc.syncThirdPartyCookieList(this.xc.unsecuredCookieSync),this.xc.syncFirstPartyCookie(p.USER_ID))})),this.onEvent([Mt.SYNC_URLS_RECEIVED,Et.CONSENT_DATA_UPDATE,Et.CCPA_INFO_RECEIVED]).then((()=>{if(this.isConsentConnatix()&&this.kc.isSellUserAllowed())try{this.Cc.syncUrls(this.ba.userId,this.ba.getScope())}catch(t){(0,g.n)({level:g.D.WARN,message:"UserManager_syncUrls",exception:t.message,callStack:t.stack})}})))};try{this.li=t,this.ba=u.getInstance(t),this.bc||(this.xc=new y(this.ba,t));const{cmp:i,tcf:e}=this._appSettings;this.Ka=new ft(!!this.wc,t,{cmp:i,tcf:e}),this.Cc=new At(this.Ka,this.isGDPR()),this.kc=new Ct(this.ba,this._appSettings.usPrivacyString),this.Ec()}catch(t){(0,g.n)({callStack:t.stack,exception:t.message,message:"UserManager_constructor",level:g.D.CRITICAL})}}get identityEnvelope(){return Lt.$.getValidEnvelope()}Ec(){this.xc&&this.xc.fetchCookies(),this.Pc(),this.onEvent([Et.CONSENT_DATA_UPDATE]).then((()=>{this.Ac(),setTimeout((()=>{try{if(this.bc)return;this._c()}catch(t){(0,g.n)({callStack:t.stack,exception:t.message,message:"UserManager_consent_data_received",level:g.D.CRITICAL})}}),0)}))}Mc(t){return void 0===this.Ic[t]&&(this.Ic[t]=new _t.C,this.Ic[t].promise.catch((()=>this.Ic[t].reject()))),this.Ic[t]}resolveEvent(t,i){this.Mc(t).resolve(i)}setAmpUserConsent(t){this.Ka.setAmpUserConsent(t),this.resolveEvent(Et.CONSENT_DATA_UPDATE)}setPageUrl(t){this.Ka&&this.Ka.setPageUrl(t)}onEvent(t){const i=t.map((t=>this.Mc(t).promise));return Promise.all(i)}isConsent(t,i){return this.Ka.isConsent(t,i)}isConsentConnatix(){return this.Ka.isConsentConnatix()}ccpaInfoLogging(t){this.kc.ccpaInfoLogging(t)}getConsentPayload(){return this.Ka.getConsentDataPayload()}isConsentRequired(){return this.Ka.isConsentRequired()}isPersonalisedAdsAllowed(){return this.isConsentRequired()?this.Ka.isConsentForPersonalisedAds():!this.isCcpaApplicable()||this.kc.isSellUserAllowed()}setThirdPartySyncUrls(t){this.bc||this.Cc.setSyncUrls(t)&&this.resolveEvent(Mt.SYNC_URLS_RECEIVED)}setGeoLocation(t){this.kc.setGeoLocation(t),this.kc.fetchUsPrivacyString().then((()=>{this.resolveEvent(Et.CCPA_INFO_RECEIVED)})).catch((()=>{this.resolveEvent(Et.CCPA_INFO_RECEIVED)}))}getUserId(){if(this.isConsentConnatix()&&this.xc)return this.xc.getUserId()}Bc(){return this.xc&&this.xc.getUserId()}setUserInformation(t){this.xc&&(this.xc.setUserInformation(t),this.resolveEvent(Mt.USER_INFO_RECEIVED),!this.bc&&this.isConsentConnatix()&&this.xc.syncFirstPartyCookie(p.USER_ID))}isGDPR(){return!!this.wc}getUsPrivacyString(){return this.kc.getUsPrivacyString()}isCcpaApplicable(){return this.kc.isCcpaApplicable()}isSellUserAllowed(){return this.bc||this.kc.isSellUserAllowed()}getDeviceId(){if(this.isConsentConnatix())return this._appSettings.deviceID}Rc(){return this._appSettings.deviceID}getTrackableUser(){return this.bc?this.getDeviceId():this.getUserId()}getForcedTrackableUser(){return this.bc?this.Rc():this.Bc()}registerPlsCall(t){return this.isConsentConnatix()||(this.Sc=!0),this.ba.registerPlsCall(t)}setBrowserInfo(t){this.xc&&this.xc.setBrowserInfo(t,this.isConsentConnatix())}getGdprConsentApiType(){return this.Ka.getConsentApiType()}}},5650:(t,i,e)=>{"use strict";e.d(i,{BY:()=>f,BZ:()=>l,Gg:()=>p,Sz:()=>c,V7:()=>m,d3:()=>o,ee:()=>b,fn:()=>u,gX:()=>v,qo:()=>h,qy:()=>a,sj:()=>y,tN:()=>g,ti:()=>d});var s=e(4798),n=e(7531),r=e(9791);function o(t,i){return i.indexOf(t)>-1}function h(t){return Array.isArray(t)?t:[t]}function a(t,i){const e=[],s=new Map;return i.forEach((i=>{s.has(i[t])||(s.set(i[t],!0),e.push(i))})),e}function c(t){return[].slice.call(t)}function d(t){const i=[];for(const e in t)e&&parseInt(e,10)>=0&&i.push(t[e]);return i}function l(t){return t&&t.length>0}function u(t){return t.every((t=>(0,s.hj)(t)))}function p(t){let i="[";for(let e=0;e<t.length;e++)i+=(0,n.HD)(t[e])+(e===t.length-1?"":",");return i+="]",i}function f(t,i){return!(!t||!i)&&(t.length===i.length&&(t===i||0===t.length&&0===i.length||t.every(((t,e)=>(0,r.s9)(t,i[e])))))}function m(t,i){return t.filter((t=>!i.includes(t)))}function g(t,i){return t.filter((t=>i.includes(t)))}function v(t){return t.filter(((i,e)=>t.indexOf(i)===e))}function y(t,i){const e=t.indexOf(i);-1!==e&&t.splice(e,1)}function b(t){const i=[];return t.forEach((t=>i.push(t))),i}},5356:(t,i,e)=>{"use strict";e.d(i,{AK:()=>l,Xj:()=>c,mU:()=>u,mb:()=>d,xm:()=>a});var s=e(289),n=e(3020),r=e(8983),o=e(9613),h=e(4798);function a(t,i){let e=!1;switch(t){case s.ProtoAdBreakTypeEnum.PreRoll:e=i===s.ProtoAdSlotsEnum.PreRoll;break;case s.ProtoAdBreakTypeEnum.MidRoll:e=i===s.ProtoAdSlotsEnum.MidRoll;break;case s.ProtoAdBreakTypeEnum.PostRoll:e=i===s.ProtoAdSlotsEnum.PostRoll}return e}function c(t,i){return!(i.skippability===s.ProtoPlayerSkippabilityType.AllowNonSkipAdsIfTheyAreShorterThan&&t<i.skipMin)}function d(t){return(0,n.pv)(t,r.s6.Ad)||(0,n.pv)(t,o.Ek.InAd)}function l(t,i){return(0,h.r)(i)&&[s.ProtoAdsourceTypeEnum.Vpaid,s.ProtoAdsourceTypeEnum.Ima].includes(t)}function u(t,i){if(isNaN(i)||!t)return null;const e={start:0,end:i};for(let s=0;s<t.length;s++){const n=t.start(s),r=t.end(s);if(i>=n&&i<=r){e.end=r;break}}return e}},3020:(t,i,e)=>{"use strict";e.d(i,{AX:()=>rt,Dx:()=>T,FM:()=>lt,Fs:()=>k,G$:()=>M,GF:()=>X,Ho:()=>p,IS:()=>q,IV:()=>S,Iy:()=>V,Ji:()=>G,Kk:()=>nt,LT:()=>$,L_:()=>_,ML:()=>I,MV:()=>u,NN:()=>ct,NS:()=>y,Nb:()=>it,PM:()=>O,Q1:()=>L,S0:()=>B,T7:()=>f,Tp:()=>R,U6:()=>W,UR:()=>ot,Wb:()=>Z,_w:()=>ht,aQ:()=>m,bX:()=>g,bZ:()=>at,cn:()=>w,dZ:()=>b,eA:()=>tt,fj:()=>j,h_:()=>D,jG:()=>U,ju:()=>Q,nw:()=>N,oW:()=>dt,og:()=>A,pv:()=>P,rI:()=>x,sw:()=>et,tp:()=>E,uC:()=>v,uc:()=>C,uh:()=>st,uq:()=>Y,w6:()=>J,wl:()=>K});var s=e(8576),n=e(4798),r=e(5650),o=e(8983),h=e(9791),a=e(51),c=e(307),d=e(1187);function l(t,i){t&&(t.style.display=i?"":"none")}function u(t){l(t,!1)}function p(t){l(t,!0)}function f(t,i){for(const e in i)i.hasOwnProperty(e)&&(t.style[e]=i[e])}function m(t,...i){i.forEach((i=>{t.style[i]=""}))}function g(t){t&&t.parentNode&&t.parentNode.removeChild(t)}function v(t,i=document){g(i.getElementById(t))}function y(t,i,e,s,r){if(i)try{const o=e.document.createElement("link");return o.id=t.id,o.type="text/css",o.rel="stylesheet",o.href=t.src,(0,n.mf)(s)&&(o.onload=()=>{s()}),(0,n.mf)(r)&&(o.onerror=t=>{i.removeChild(o),(0,n.HD)(t)?r(`link_stylesheet_load_error_${t}`):r(`link_stylesheet_load_error_${function(t,i){const e=t.document.createElement("div");return e.appendChild(i),e.innerHTML}(e,o)}`)}),i.appendChild(o),o}catch(t){return null}}function b(t,i,e,s,r,o=!0,h){try{const a=e.document.createElement("script");if(a.src=t.src,a.async=!0,a.type="text/javascript",t.id&&(a.id=t.id),t.attributes)for(const i of t.attributes)a.setAttribute(i.name,i.value);return(0,n.mf)(s)&&(a.onload=()=>{s()}),a.onerror=e=>{i.removeChild(a),o&&(0,d.n)({message:h,exception:"script_load_error",callStack:t.src,level:d.D.INFO},{throttle:2,shouldSendMaxLog:!1}),(0,n.mf)(r)&&r()},i.appendChild(a),a}catch(i){return o&&(0,d.n)({message:h,exception:`script_insert_error_${i.message}_${i.stack}`,callStack:t.src,level:d.D.CRITICAL},{throttle:2,shouldSendMaxLog:!1}),(0,n.mf)(r)&&r(),null}}function I(t,i,e){if(t)try{const s=i.document.createElement("script"),n=i.document.createTextNode(e);return s.appendChild(n),t.appendChild(s),s}catch(t){return null}}function w(t,...i){t&&t.classList.add(...i)}function S(t,...i){t&&t.classList.remove(...i)}function P(t,i){return t&&t.classList.contains(i)}function A(t,i,e){return!!t&&t.classList.toggle(i,e)}function _(t,i,e,s=!1){t&&(t.classList.remove(i),t.classList.add(e),s&&R(t))}const x=(t,i)=>i.document.getElementById(t),T=(t,i,e)=>i.getComputedStyle(t,e),k=(t,i)=>i.document.getElementsByClassName(t);function C(t,i="",e){const s=e.document.getElementsByTagName("head")[0],n=e.document.createElement("style");n.setAttribute("type","text/css"),n.id=i,n.appendChild(e.document.createTextNode(t)),s.appendChild(n)}function E(t,i){const e=i.document.getElementsByTagName("head")[0],s=i.document.createElement("link");s.setAttribute("rel","preconnect"),s.setAttribute("link",t),e.appendChild(s)}function M(t,i){const e=i.document.createElement("div");return e.innerHTML=t,e.firstElementChild}function L(t,i){i>0?(t.removeAttribute("muted"),t.muted=!1):(t.setAttribute("muted",""),t.muted=!0)}function B(t){return s.Ht.find((i=>{if(i.keys.fullscreenEnabled in t)return!0}))}function R(t){t.getBoundingClientRect()}function O(t,i){return(t.requestAnimationFrame||t.webkitRequestAnimationFrame||function(t){return setTimeout(t,20)})(i)}function D(t,i){return(t.cancelAnimationFrame||t.webkitCancelAnimationFrame||function(t){return clearTimeout(t)})(i)}function V(t){return!!t.closest(".cnx-el")}function F(t,i,e){const s=function(t,i){const e=function(t,i){let e=i;for(;e;){const i=e.parentNode;if(i){const e=t.reduce(((t,e)=>t||i.querySelector(e)),null);if(e)return e}e=i}return null}(t,i);return e?T(e,$(e)):null}(t,i);return s?function(t,i){return t.getPropertyValue(i)}(s,e):null}function N(t){const i=F(["h1","h2"],t,"font-family");return i||"inherit"}function j(t){const i=F(["p"],t,"font-family");return i||"inherit"}function $(t){try{return t.ownerDocument.defaultView}catch(t){return null}}function U(t,i){t&&i&&(Array.isArray(t)?t.forEach((t=>i.appendChild(t))):i.appendChild(t))}function q(t,i,e){let s=!1;const n=(0,r.Sz)(i.children);for(let i=0;i<n.length;i++)if(e-1===i||0===e){s=!0,Array.isArray(t)?H(n[i],...t):H(n[i],t);break}s||U(t,i)}function H(t,...i){if(t&&t.parentElement)for(let e=i.length;e--;)t.parentElement.insertBefore(i[e],t)}function z(t){const i=$(t);if(!i)return;const{display:e}=T(t,i);"none"===e&&(t.style.display="block")}function W(t,i=(()=>{})){const e=function(s){"opacity"===s.propertyName&&(S(t,o.jG.FadeOutBase,o.jG.FadeOut),i(),t.removeEventListener("transitionend",e))};w(t,o.jG.FadeOutBase),z(t),R(t),t.addEventListener("transitionend",e),w(t,o.jG.FadeOut)}function G(t,i=(()=>{})){const e=function(s){"opacity"===s.propertyName&&(S(t,o.jG.FadeInBase,o.jG.FadeIn),i(),t.removeEventListener("transitionend",e))};w(t,o.jG.FadeInBase),z(t),R(t),t.addEventListener("transitionend",e),w(t,o.jG.FadeIn)}function X(t){const i=$(t);if(!i)return!0;const{display:e,opacity:s}=T(t,i);return"none"===e||"0"===s}function Q(t,i){const e=i.document.createElement("div");return e.innerHTML=t||"",e.innerText}function J(){const t=window.navigator&&window.navigator.doNotTrack||window.doNotTrack;return"1"===t||"yes"===t}function Y(t,i){const e=(0,h.pE)(t).topFrame;return e[i]?e:null}function K(t,i){let e=t,s=null;try{for(;!s;){try{e.frames[i]&&(s=e)}catch(t){}if(!t.top||t.top===e)break;e=e.parent}}catch(t){}return s}function Z(t,i){let e=[];try{e=e.slice.call(i.document.querySelectorAll(t),0)}catch(t){}return e}function tt(t){return(0,h.pE)(t).topFrame.location.protocol.includes("https")}function it(t){if(!tt(t))return;[window,t].forEach((t=>{if(null===t.document.querySelector("meta[content=upgrade-insecure-requests]")){const i=t.document.createElement("meta");i.setAttribute("http-equiv","Content-Security-Policy"),i.content="upgrade-insecure-requests",t.document.head.appendChild(i)}}))}function et(t){return(0,h.pE)(t).topFrame.document.referrer}function st(t,i){const e=(0,h.pE)(i).topFrame.location.hostname,s=(0,h.bx)(t);return s&&s.hostname===e}function nt(t){t.removeAttribute("href"),t.removeAttribute("target"),t.removeAttribute("download"),t.removeAttribute("ping"),t.removeAttribute("rel"),t.removeAttribute("media"),t.removeAttribute("hreflang"),t.removeAttribute("type")}function rt(t,i){try{t.onclick=t=>{const{tagName:e,className:s}=t.target;(0,d.n)({message:`${i} - click on tag:${e} class:${s}`,level:d.D.INFO})}}catch(t){(0,d.n)({message:`${i}_Error - iframe click`,level:d.D.WARN,callStack:t.stack})}}function ot(t){setTimeout((()=>{let i=t.currentTime+.01;i>t.duration&&(i=.01),t.currentTime=i}),0)}function ht(t,i){!function(t,i,e){const s=t.document.createElement("link");s.rel="preload",s.href=i,s.as=e,t.document.head.appendChild(s)}(i,t,"script")}function at(t,i){if(!i||!ct(i))return(0,d.n)({message:"Prerender_Elements_getgetCustomerId_no_currentScript",level:d.D.CRITICAL}),null;const e=i.src;return(0,a.Ph)(c.ym,e)}function ct(t){return"SCRIPT"===t.tagName}function dt(t){const{top:i,left:e}=t.getBoundingClientRect();return{top:i,left:e}}function lt(t){return parseInt(t.replace("px",""),10)}},9791:(t,i,e)=>{"use strict";e.d(i,{Ae:()=>P,Hh:()=>p,Of:()=>y,Qq:()=>S,Up:()=>b,Vm:()=>f,W$:()=>A,bx:()=>l,dz:()=>a,er:()=>c,lU:()=>d,ld:()=>g,oC:()=>I,pE:()=>u,qs:()=>h,rM:()=>w,s9:()=>v,we:()=>m});var s=e(51),n=e(4798),r=e(7531),o=e(5650);function h(){let t=Date.now();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(i){const e=(t+16*Math.random())%16|0;return t=Math.floor(t/16),("x"===i?e:3&e|8).toString(16)}))}function a(){return h().replace(/-/g,"")}function c(t){return/^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(t.trim())}function d(t,i){let e="";if(!t.err)try{e=t.topFrame.location.href}catch(t){}if(!e||0===e.length)try{e=i.top.location.href}catch(t){}if(!e||0===e.length)try{e=t.topFrame.document.referrer}catch(t){}return e}function l(t){try{const i=t.match(/^(https?:)\/\/(([^:\/?#]*)(?::([0-9]+))?)([\/]{0,1}[^?#]*)(\?[^#]*|)(#.*|)$/);return{href:t,protocol:i[1],host:i[2],hostname:i[3],port:i[4],pathname:i[5],search:i[6],hash:i[7]}}catch(t){return null}}function u(t){let i=t,e=null,s=!1;try{for(;i.parent.document!==i.document;){if(!i.parent.document){s=!0;break}e=i,i=i.parent}}catch(t){s=!0}return{topFrame:i,topChildFrame:e,err:s}}function p(t=[],i,e={}){t.forEach((t=>{if((0,n.HD)(t)){let h=t;(0,n.Xz)(e)&&(h=`${t}${(0,s.CK)(t)}${function(t,i){const e=[];return Object.keys(t).forEach((s=>{const h=i?`${i}[${s}]`:s,a=t[s];if((0,n.as)(a))e.push(`${encodeURIComponent(h)}=${(0,r.HD)(a)}`);else if(Array.isArray(a))e.push(`${encodeURIComponent(h)}=${(0,o.Gg)(a)}`);else if(null!=a){const t=encodeURIComponent(a),i=encodeURIComponent(h);t&&i&&e.push(`${i}=${t}`)}})),e.join("&")}(e)}`),(new i.Image).src=h}}))}function f(t){const i=Math.floor(100*Math.random());let e=0,s=0;for(let n=0;n<t.length;n++)if(s+=t[n],i<s){e=n;break}return e}function m(){let t=!1;try{const i=document.createElement("audio");i.volume=1,i.muted=!1;const e=i.play();void 0!==e&&e.catch((()=>{})),t=!i.paused,i.pause()}catch(t){}return t}function g(t,i=0,...e){return setTimeout((()=>{t.apply(this,e)}),i)}function v(t,i){return(0,n.as)(t)?(0,r.Ib)(t,i):Array.isArray(t)?(0,o.BY)(t,i):t===i}function y(t,i,e){let s=0,n=t;for(;s<=e;){if(s++,n.classList.contains(i))return!0;if(n=n.parentElement,!n)return!1}return!1}function b(t,i=5,e){return new Promise(((s,r)=>{t().then(s).catch((o=>{1===i||(0,n.mf)(e)&&e(o)?r(o):b(t,i-1,e).then(s,r)}))}))}function I(){const t=!!window.MSInputMethodContext&&!!document.documentMode,i=navigator.userAgent.toLowerCase().includes("msie");return t||i}function w(t){return Object.keys(t).reduce(((i,e)=>Object.assign(Object.assign({},i),{[e]:`${t[e]}`})),{})}function S(t=navigator.userAgent){return t.includes("; wv")}function P(t){return Math.floor(Math.random()*Math.pow(10,t))}function A(t){return(0,n.VZ)(t)?t:(0,n.QM)(t)?new Error(t):new Error(String(t))}},51:(t,i,e)=>{"use strict";e.d(i,{Bp:()=>o,CK:()=>h,FM:()=>c,Ph:()=>r,ge:()=>a,jv:()=>p,sH:()=>u});var s=e(4798);const n=".cdn.ampproject.org";function r(t,i){i||(i=location.search),t=t.replace(/\[/,"\\[").replace(/]/,"\\]");const e=new RegExp(`[\\?&]${t}=([^&#]*)`,"i").exec(i);return null===e?null:decodeURIComponent(e[1])}function o(t,i,e){const s=new RegExp(`([?&])${i}=.*?(&|$)`,"i"),n=h(t);return t.match(s)?e?t.replace(s,`$1${i}=${e}$2`):t.replace(s,"$1"):`${t}${n}${i}=${e}`}function h(t){return t.includes("?")?"&":"?"}function a(t){if((0,s.QM)(t))return d(t).split("/")[0]}function c(t){if((0,s.QM)(t))return d(t)}function d(t){return t.includes("://")?t.split("://")[1]:t}function l(t,i){return`${"http"+(/(\/s\/)+/.test(t.replace(i,""))?"s":"")}://${i}`}function u(t,i=!0){return t=function(t){if(!t.includes(n))return t;const i="www.",e="amp.";if((t=(t=(t=(t=(t=(t=(t=t.replace(n,"")).replace("www-",i)).replace("amp-",e)).cnx_replaceAll("--","=")).cnx_replaceAll("-",".")).cnx_replaceAll("=","-")).replace(i,e)).includes(e))return t;const s="http://",r="https://";return(t=t.replace(s,`${s}${e}`)).replace(r,`${r}${e}`)}(t=function(t){const i=/^https:\/\/www.google\..*?\/amp\/s*\/*/.exec(t);if(null!==i){const e=t.replace(i[0],"");return l(t,e)}return t}(t=function(t){if(t.includes(n)){t=t.replace("https://","");const i=/^[^\/]+(\/[a-z]+\/)+s*\/*/,e=i.test(t)?t.replace(i.exec(t)[0],""):t;return l(t,e)}return t}(t))),i&&(t=function(t){if(!t.includes("#origin-")&&!t.includes("viewerUrl-"))return t;const i=t.split("#origin-")[1].split("viewerUrl-");return u(t=decodeURIComponent(i[1]),!1)}(t)),t}function p(t){try{return new URL(t),!0}catch(t){return!1}}},9725:(t,i,e)=>{"use strict";e.d(i,{$:()=>s});var s,n=e(4798),r=e(3731);!function(t){const i="3.0.0",e="3.2.0",s="4.3.0";t.shouldUseExternalViewabilityService=function(t){return(0,r.qu)(t,i,"<")},t.showAndroidExpandButton=function(t){return(0,r.qu)(t,e,">=")},t.shouldUseOmsdkForAds=function(t){return(0,r.qu)(t,s,">=")},t.getEnvironment=function(t){return{isInApp:(0,n.QM)(t.bundleID),isInAppSDK:(0,n.QM)(t.sdkVersion),isInAppHybrid:t.webViewability}},t.isValidWebviewInApp=function(t){return t.isInApp&&t.isInAppHybrid}}(s||(s={}))},1187:(t,i,e)=>{"use strict";e.d(i,{D:()=>E,n:()=>L});var s=e(7945),n=e(9741);const r=!0;var o,h=e(9791),a=e(6578),c=e(6153),d=e(9906),l=e(5204),u=e(1781),p=e(2239),f=e(3432);!function(t){t[t.None=0]="None",t[t.Linear=1]="Linear",t[t.NonLinear=2]="NonLinear"}(o||(o={}));var m,g,v,y=e(9005),b=e(6568),I=e(8858),w=e(6565),S=e(9600),P=e(8659),A=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o},_=function(t,i){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,i)},x=function(t,i){return function(e,s){i(e,s,t)}};let T=class{constructor(t,i,e){this.Dc=t,this.Vc=i,this.Fc=[],this.Nc=o.None,this.Fc.push(e.adBreakStart.asObservable().subscribe((({isLinear:t})=>{this.Nc=t?o.Linear:o.NonLinear})),e.adBreakEnd.asObservable().subscribe((()=>{this.Nc=o.None})))}getLoggingData(t=0){if(!this.jc(t))return;const i=this.$c();if(i.player.id=this.Dc.playerId,i.environment.isTabFocus=this.Dc.isPageInFocus,this.Dc.playerEnvironment!==y.Q.Unknown&&(i.environment.renderEnvironment=this.Dc.playerEnvironment),this.Dc.currentMediaMetadata){const t=this.Dc.currentMediaMetadata.mediaRevision;i.player.media={mediaId:this.Dc.currentMediaMetadata.mediaId,mediaRevisionNumber:t?`${this.Dc.currentMediaMetadata.mediaRevision}`:void 0,contentRevisionId:this.Dc.currentMediaMetadata.contentRevisionId,isExternal:!!this.Dc.currentMediaMetadata.isExternalMedia}}return this.Dc.playerDimensions&&(i.player.size=this.Dc.playerDimensions),i.player.isInView=this.Vc.sessionViewabilityChanged.value.isInView,i.player.type=this.Dc.playerType,this.Dc.playerType!==b.e.Outstream&&(i.player.state=this.Dc.playerState),i.player.advertising.adBreak=this.Nc,i}dispose(){(0,S.i)(this.Fc)}jc(t){return!!this.Dc.canTrackAllRequests||!!t}$c(){return{player:{media:{isExternal:!1},advertising:{adBreak:o.None},isInView:!1},environment:{}}}};T=A([(0,P.b2)(),(0,P.Yn)(P.Fw.ContainerScoped),x(0,(0,P.f3)(p.B)),x(1,(0,P.f3)(w.q)),x(2,(0,P.f3)(l.k)),_("design:paramtypes",["function"==typeof(m=void 0!==f.B&&f.B)?m:Object,"function"==typeof(g=void 0!==I.d&&I.d)?g:Object,"function"==typeof(v=void 0!==u.q&&u.q)?v:Object])],T);const k=500;let C=window.location&&window.location.href;try{C=window.top.location.href}catch(t){}var E;!function(t){t.EMERGENCY="Emergency",t.ALERT="Alert",t.CRITICAL="Critical",t.ERROR="Error",t.WARN="Warn",t.INFO="Info"}(E||(E={}));const M={throttle:30,shouldSendMaxLog:!0,pacing:0,extraLogsPercentage:0};function L(t,i={}){if(!((i=Object.assign(Object.assign({},M),i)).pacing>0)||function(t){const i=Math.min(Math.max(t,0),100);return!!(0,h.Vm)([100-i,i])}(i.pacing)){if(t.sessionId)try{const e=d.h.getSessionChildContainer(t.sessionId).resolve(T);t.extra=e.getLoggingData(i.extraLogsPercentage)}catch(t){}if(t.sessionId=t.sessionId?t.sessionId:n.S.sessionId,r&&(n.S.incrementLogCount(t.message),n.S.isMaxLogOverflow(t.message)&&L({message:"Logging_max_log_overflow_1000",exception:t.message,callStack:t.callStack,level:E.ALERT,sessionId:t.sessionId},{shouldSendMaxLog:!1,throttle:100,extraLogsPercentage:100}),n.S.isMaxLog(t.message,i.throttle)))i.shouldSendMaxLog&&!n.S.isMaxLogSent(t.message)&&(n.S.setMaxLogSent(t.message),L({message:"Logging_max_log_sent",exception:t.message,callStack:t.callStack,level:E.CRITICAL,sessionId:n.S.sessionId}));else{if(void 0===t.callStack){const i=new Error(t.message);t.callStack=i.stack}if(t.callStack=t.callStack.substring(0,k),s.g.logToServer){t.pageUrl=t.pageUrl||C,t.version=s.g.version;let e="connatix.com";try{e=c.n.bundleDomain}catch(t){}const n="https://pl."+e;t.ddsource="browser",t.service="player",t.ua=navigator.userAgent,i.sendBeacon?a.n.sendJsonBeaconRequest(t,n):a.n.fetchXhttpRequest({requestUrl:n,requestType:"POST",withCredentials:!1},JSON.stringify(t)).catch((()=>{}))}s.g.logToConsole&&function(t){let i;switch(t.level){case E.CRITICAL:i="#8B0000";break;case E.WARN:i="#FF8C00";break;case E.INFO:i="#000000"}console.log(`%cConnatix Logging:\n   message: ${t.message}\n   exception: ${t.exception}\n   level: ${t.level}\n   version: ${t.version}\n   sessionId: ${t.sessionId}\n   callStack: ${t.callStack}`,`color:${i}`)}(t)}}}},7332:(t,i,e)=>{"use strict";e.d(i,{DE:()=>r,ON:()=>a,Tc:()=>o,dO:()=>c,dQ:()=>n,mg:()=>d,oK:()=>h});var s=e(4798);function n(t,i,e,s,n){return e+(s-e)*function(t,i,e){return(e-t)/(i-t)}(t,i,n)}function r(t,i){return i.reduce(((i,e)=>Math.abs(e-t)<=Math.abs(i-t)?e:i))}function o(t,i){return i/100*t}function h(t,i){const e=Math.pow(10,i);return Math.round(t*e)/e}function a(t){return!(0,s.r)(t.width)||!(0,s.r)(t.height)}function c(t,i){for(let e=i;e>1;e--)t%e==0&&i%e==0&&(t/=e,i/=e);return{widthRatio:t,heightRatio:i}}function d(t,i,e){const s=Math.min(i,e),n=Math.max(i,e);return t>=s&&t<=n}},7531:(t,i,e)=>{"use strict";e.d(i,{G_:()=>a,HD:()=>r,Ib:()=>o,S1:()=>h});var s=e(9791),n=e(4798);function r(t){for(const i in t)t.hasOwnProperty(i)&&"string"==typeof t[i]&&(t[i]=`%22${encodeURIComponent(t[i])}%22`);return JSON.stringify(t).cnx_replaceAll('"',"")}function o(t,i){if(!(0,n.as)(t)||!(0,n.as)(i))return!1;const e=Object.getOwnPropertyNames(t),r=Object.getOwnPropertyNames(i);return e.length===r.length&&e.every((e=>(0,s.s9)(t[e],i[e])))}function h(t,i){return Object.assign(Object.assign({},t),i)}function a(t,i){const e=Object.assign({},t);return i.forEach((t=>{delete e[t]})),e}},9600:(t,i,e)=>{"use strict";function s(t=[]){t.filter((t=>!!t)).forEach((t=>t.unsubscribe()))}e.d(i,{i:()=>s})},3003:(t,i,e)=>{"use strict";e.d(i,{EQ:()=>o,Ed:()=>a,IS:()=>h,VN:()=>c,f5:()=>r});var s=e(1187),n=e(4798);function r(t,i){return t.replace(/(?:\r\n|\r|\n)/g,i)}function o(t){try{return Object.keys(t).reduce(((i,e)=>Object.assign(Object.assign({},i),{[e]:(0,n.QM)(t[e])&&t[e].includes("%%")?void 0:t[e]})),{})}catch(i){return(0,s.n)({message:"sanitizeDfpMacros_error",exception:i.message,callStack:i.stack,level:s.D.WARN}),Object.keys(t).reduce(((i,e)=>Object.assign(Object.assign({},i),{[e]:(0,n.QM)(t[e])&&t[e].includes("%%")?void 0:t[e]})),{})}}function h(t,i){return`${t}-${i}`}function a(t,i){return t.match(i)||[]}function c(t,i,e){return(0,n.QM)(t)?t.substring(i,e):""}},1310:(t,i,e)=>{"use strict";e.d(i,{H8:()=>l,QI:()=>o,XF:()=>h,k$:()=>c,kw:()=>f,pP:()=>r,qe:()=>u,qt:()=>m,to:()=>a,w4:()=>p,x8:()=>d});var s=e(9357),n=e(4798);function r(t){let i,e;return(0,n.HD)(t)&&(i=t.match(s.T9),i&&(e=parseInt(i[1],10)*s.p7+parseInt(i[2],10)*s.uD+parseInt(i[3],10)*s.s_+parseInt(i[5]||0,10))),isNaN(e)?null:e}function o(t,i){return/^\d+(\.\d+)?%$/g.test(t)?i?i*parseFloat(t.replace("%",""))/100:null:r(t)}function h(t){return Date.now()+t*s.ti}function a(t,i=":"){const e=t=>t>=10?t:`0${t}`;return`${e(Math.floor(t/60))}${i}${e(Math.floor(t%60))}`}function c(t,i){const e=Date.now();return!(e<t||e>i)}function d(){const t=new Date;return t.getTime()-1e3*t.getTimezoneOffset()*60}function l(t){return Math.floor((Date.now()-t)/s.s_)}function u(t,i){return t>=i?t/s.s_:t}function p(t){return(0,n.hj)(t)?t*s.s_:null}function f(t){return Math.round(t/s.s_)}function m(t){var i=Math.floor(t/3600),e=Math.floor(t%3600/60),s=Math.floor(t%3600%60);let n="";return n=i>0?n+`${i}`.slice(-2)+" hours ":"",n+=e>0?`${e}`.slice(-2)+" minutes ":"",n+=s>0?`${s}`.slice(-2)+" seconds":"0 seconds",n}},4798:(t,i,e)=>{"use strict";function s(t){return"string"==typeof t}function n(t){return"number"==typeof t&&isFinite(t)}function r(t){return n(t)&&t>0}function o(t){return n(t)&&t>=0}function h(t){return s(t)&&t.length>0}function a(t){return void 0!==t}function c(t){return null===t}function d(t){return t&&t.stack&&t.message||t instanceof Error}function l(t){return"function"==typeof t}function u(t){return"object"==typeof t&&null!==t&&!Array.isArray(t)}function p(t){return u(t)&&Object.keys(t).length>0}function f(t){try{if(t.contentWindow||t.contentDocument)return!0}catch(t){}return!1}function m(t,i){var e;return h(t)?!(!(null===(e=Object.values(i))||void 0===e?void 0:e.includes(t))||Object.keys(i).includes(t)):!!n(t)&&t in i}e.d(i,{$K:()=>a,Cz:()=>m,Ft:()=>c,HD:()=>s,QM:()=>h,VZ:()=>d,Xc:()=>o,Xz:()=>p,as:()=>u,cL:()=>f,hj:()=>n,mf:()=>l,r:()=>r})},6578:(t,i,e)=>{"use strict";e.d(i,{n:()=>d});var s,n=e(9791),r=e(4798),o=e(51),h=e(1187);!function(t){t.Brands="brands",t.Mobile="mobile",t.Architecture="architecture",t.Bitness="bitness",t.Model="model",t.Platform="platform",t.PlatformVersion="platformVersion",t.UaFullVersion="uaFullVersion",t.Wow64="wow64",t.FullVersionList="fullVersionList"}(s||(s={}));var a=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class c{constructor(){}static getInstance(){return this.INSTANCE||(this.INSTANCE=new c),this.INSTANCE}fetch(){var t,i;return a(this,void 0,void 0,(function*(){return(0,r.$K)(this.Uc)?this.Uc:(null===(i=null===(t=null===window||void 0===window?void 0:window.navigator)||void 0===t?void 0:t.userAgentData)||void 0===i?void 0:i.getHighEntropyValues)?(this.Uc=yield this.qc(),this.Uc):null}))}qc(){return a(this,void 0,void 0,(function*(){return(0,r.$K)(this.Hc)||(this.Hc=new Promise((t=>{window.navigator.userAgentData.getHighEntropyValues([s.FullVersionList,s.PlatformVersion,s.Architecture,s.Bitness,s.Model]).then((i=>t(i))).catch((()=>t(null)))}))),this.Hc}))}}var d,l=e(5650),u=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};!function(t){let i;!function(t){t.DumpJson="Dump Json",t.ServerError="Server Error",t.ProtobufDecode="Protobuf_decode"}(i||(i={}));const e=3e4;function s(t,i){return(0,r.as)(i)?(Object.keys(i).forEach((e=>t=(0,o.Bp)(t,e,i[e]))),t):t}function a(t,i){return u(this,void 0,void 0,(function*(){let s=null;t.shouldSetClientHintsHeaders&&(s=yield c.getInstance().fetch());const n=function({requestUrl:t,requestType:i="POST",contentType:s="",responseType:n="",withCredentials:o=!1,timeout:h=e,shouldSetClientHintsHeaders:a},c=null){const d=new XMLHttpRequest;if(d.open(i,t,!0),a&&c){const{model:t,platformVersion:i,architecture:e,bitness:s,fullVersionList:n}=c;(0,r.QM)(i)&&d.setRequestHeader("X-Sec-CH-UA-Platform-Version",i),(0,r.QM)(e)&&d.setRequestHeader("X-Sec-CH-UA-Arch",e),(0,r.QM)(s)&&d.setRequestHeader("X-Sec-CH-UA-Bitness",s),(0,r.QM)(t)&&d.setRequestHeader("X-Sec-CH-UA-Model",t),(0,l.BZ)(n)&&d.setRequestHeader("X-Sec-CH-UA-Full-Version-List",n.map((t=>`"${t.brand}";v="${t.version}"`)).join(", "))}return s.length>0&&d.setRequestHeader("Content-Type",s),n.length>0&&(d.responseType=n),d.timeout=h,d.withCredentials=o,d}(t,s),o=new Date;return new Promise(((t,e)=>{n.onreadystatechange=()=>{if(n.readyState===XMLHttpRequest.DONE)if(200===n.status)t(n.response);else{let t="";try{t=n.responseText}catch(t){}const i=(new Date).getTime()-o.getTime();e(new Error(`Request fail. status:${n.status}, readyState:${n.readyState}, response:${t}, time:${i}`))}},n.ontimeout=()=>{const t=(new Date).getTime()-o.getTime();e(new Error(`Request timeout status:${n.status}. time:${t}`))},n.send(i)}))}))}function d(t,e,s,n){return new Promise(((r,o)=>{e.then((e=>{if(t){let a=null;try{const i=e?new Uint8Array(e):new Uint8Array;a=t.toObject(t.decode(i),{defaults:!0,arrays:!0,objects:!0})}catch(t){!function(t,e,s,n){let r;try{r=JSON.parse((new TextDecoder).decode(t))}catch(t){}r?(r.ErrorMessage===i.DumpJson&&(0,h.n)({message:i.DumpJson,exception:JSON.stringify(s),callStack:e,level:h.D.INFO}),r.ErrorMessage===i.ServerError&&(0,h.n)({message:i.ServerError,exception:e,level:h.D.WARN})):(0,h.n)({exception:`${e}__${n.message}`,message:i.ProtobufDecode,callStack:n.stack,level:h.D.WARN},{throttle:10})}(e,s,n,t),o(i.ProtobufDecode)}r(a)}})).catch((t=>{o(t)}))}))}function p(t,i,e){try{const s=(0,n.Vm)([95,5]);!s||i&&0!==Object.keys(i).length||(0,h.n)({message:"empty_proto_request",callStack:"empty_function_argument",exception:e,level:h.D.INFO},{shouldSendMaxLog:!1});const r=t.fromObject(i);!s||r&&0!==Object.keys(r).length||(0,h.n)({message:"empty_proto_request",callStack:"empty_fromObject_result",exception:e,level:h.D.INFO},{shouldSendMaxLog:!1});const o=t.encode(r).finish();return!s||o&&0!==Object.keys(o).length||(0,h.n)({message:"empty_proto_request",callStack:"empty_encode_result",exception:e,level:h.D.INFO},{shouldSendMaxLog:!1}),o}catch(t){throw(0,h.n)({exception:e,level:h.D.CRITICAL,callStack:JSON.stringify(i),message:"Protobuf_encode"},{throttle:10}),Error()}}t.fetchXhttpRequest=a,t.fetchXMLRequest=function(t,i=!0){const e=a({requestUrl:t,requestType:"GET",withCredentials:i,shouldSetClientHintsHeaders:!1});return new Promise(((t,i)=>{e.then((i=>{t(i)})).catch((t=>{i(t)}))}))},t.sendProtoRequest=function({protoResponse:t,protoRequest:i,requestData:e,endpoint:r,requestType:o,hasCredentials:c,queryParams:l,shouldLogErrors:u,shouldSetClientHintsHeaders:f,timeout:m}){const g=e?p(i,e,r):null;return function(t,i,e="POST",s,n,r,o,h=!1){return d(t,a({requestUrl:i,requestType:e,withCredentials:n,shouldSetClientHintsHeaders:h,contentType:"POST"===e?"multipart/form-data":"",responseType:"arraybuffer",timeout:r},s),i,o)}(t,r=s(r,l),o,g,c,m,e,f).catch((t=>{throw u&&(0,n.Vm)([95,5])&&(0,h.n)({message:"Xhr_error",exception:r,callStack:`${t}, requestData: ${JSON.stringify(e)}`,level:h.D.INFO}),new Error(t)}))},t.sendProtoBeaconRequest=function({protoRequest:t,requestData:i,endpoint:e,queryParams:n=null}){e=s(e,n);const r=i?p(t,i,e):null;return navigator.sendBeacon(e,r)},t.sendJsonBeaconRequest=function(t,i){const e=new Blob([JSON.stringify(t)],{type:"application/json"});return navigator.sendBeacon(i,e)},t.trackPixel=function(t){try{(new Image).src=t}catch(t){(0,h.n)({message:"Xhr_trackPixel",exception:t.message,callStack:t.stack,level:h.D.CRITICAL})}}}(d||(d={}))},5204:(t,i,e)=>{"use strict";e.d(i,{k:()=>o});var s=e(6716),n=e(8659),r=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o};let o=class{constructor(){this.adClick=new s.x,this.adImpression=new s.x,this.adInView=new s.x,this.adQuartile=new s.x,this.auctionInformation=new s.x,this.heavyAd=new s.x,this.adPrebid=new s.x,this.adPostbid=new s.x,this.adBid=new s.x,this.startBidTracking=new s.x,this.missedImpressionOutOfView=new s.x,this.adBidTracking=new s.x,this.adBreakStart=new s.x,this.adBreakEnd=new s.x,this.onBidFetchStart=new s.x,this.onBidFetchEnd=new s.x}};o=r([(0,n.b2)(),(0,n.Yn)(n.Fw.ContainerScoped)],o)},1781:()=>{},5672:(t,i,e)=>{"use strict";e.d(i,{o:()=>Ni});var s={};e.r(s);var n={};e.r(n);var r={};e.r(r);var o={};e.r(o);var h={};e.r(h);var a={};e.r(a);var c={};e.r(c);var d={};e.r(d);var l={};e.r(l);var u={};e.r(u);var p={};e.r(p);class f{}f.MAX_STRING_LENGTH=99,f.TIME_BIDS_INTERVAL_FREQUENCY=5e3;var m,g,v,y=e(5204),b=e(1781),I=e(8395),w=e(8659),S=e(3003),P=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o},A=function(t,i){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,i)},_=function(t,i){return function(e,s){i(e,s,t)}};let x=m=class{constructor(t,i){this.zc=t,this.Ws=i,this.Fc=[],this.Wc=[],this.Gc=[],this.Qc=[],this.Jc=null,this.Kc()}static Zc(t){return t.map((t=>Object.assign(Object.assign({},t),{reason:(0,S.VN)(t.reason,0,f.MAX_STRING_LENGTH)})))}destroy(){this.Jc&&(this.Ws.clearInterval(this.Jc),this.Jc=null)}Kc(){this.Fc.push(this.zc.adBid.subscribe((t=>{this.td(t)})),this.zc.adPostbid.subscribe((t=>{this.ed(t)})),this.zc.adPrebid.subscribe((t=>{this.sd(t)})),this.zc.startBidTracking.subscribe((()=>{this.nd()})))}nd(){this.Jc||(this.Jc=this.Ws.setInterval((()=>{this.rd()}),f.TIME_BIDS_INTERVAL_FREQUENCY))}sd(t){this.Gc.push(t)}ed(t){this.Qc.push(t)}td(t){t.shouldTrackBid&&this.Wc.push(t)}rd(){this.od(),this.Gc=[],this.Wc=[],this.Qc=[]}od(){0===this.Gc.length&&0===this.Wc.length&&0===this.Qc.length||(this.Qc=m.Zc(this.Qc),this.zc.adBidTracking.next({prebidList:this.Gc,bidList:this.Wc,postbidList:this.Qc}))}};x=m=P([(0,w.b2)(),(0,w.Yn)(w.Fw.ContainerScoped),_(0,(0,w.f3)(y.k)),_(1,(0,w.f3)(I.f)),A("design:paramtypes",["function"==typeof(g=void 0!==b.q&&b.q)?g:Object,"function"==typeof(v=void 0!==s.ITimerService&&s.ITimerService)?v:Object])],x);var T=e(2239),k=e(6716),C=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o};let E=class{constructor(){this.mediaQuartile=new k.x,this.mediaClick=new k.x}};E=C([(0,w.b2)(),(0,w.Yn)(w.Fw.ContainerScoped)],E);var M=e(6565);class L{}L.TRACKING_POINTS=[{delay:7,timesRepeatDelay:1},{delay:8,timesRepeatDelay:1},{delay:15,timesRepeatDelay:3},{delay:30,timesRepeatDelay:2},{delay:60,timesRepeatDelay:1},{delay:120,timesRepeatDelay:1},{delay:300,timesRepeatDelay:8},{delay:600,timesRepeatDelay:13},{delay:1800,timesRepeatDelay:Number.MAX_SAFE_INTEGER}];var B=e(9357),R=e(4065),O=e(6515),D=e(4975),V=e(4978),F=e(6196),N=e(6798),j=e(2566);function $(t){return i=function(){return t},(0,N.e)((function(t,s){var n=0;t.subscribe((0,j.x)(s,(function(t){s.next(i.call(e,t,n++))})))}));var i,e}var U,q,H,z=e(89),W=e(1310),G=e(4798),X=e(8858),Q=e(9600),J=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o},Y=function(t,i){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,i)},K=function(t,i){return function(e,s){i(e,s,t)}};let Z=U=class{constructor(t,i){this.Vc=t,this.Ws=i,this.hd=!1,this.dd=!1,this.Fc=[],this.ud=new O.X(L.TRACKING_POINTS[0]),this.pd=new R.B(this.Ws,Number.MAX_SAFE_INTEGER,U.TIMER_TICK),this.fd=new R.B(this.Ws,Number.MAX_SAFE_INTEGER,U.TIMER_TICK),this.gd()}destroy(){(0,Q.i)(this.Fc)}gd(){const t=this.Vc.sessionRendered.pipe((0,z.q)(1)).subscribe((()=>{this.vd()}));this.Fc.push(this.Vc.sessionPlaybackChanged.subscribe((({isPlaying:t})=>{this.yd(t)})),this.Vc.sessionViewabilityChanged.subscribe((({isInView:t})=>{this.bd(t)})),this.Vc.sessionViewabilityChanged.subscribe((({isInView:t})=>{this.bd(t)})),t)}yd(t){this.hd!==t&&(this.hd=t,this.dd&&this.hd&&this.fd.start(),this.hd?this.pd.start():(this.pd.stop(),this.fd.stop()))}bd(t){this.dd!==t&&(this.dd=t,this.dd&&this.hd?this.fd.start():this.dd||this.fd.stop())}vd(){this.Fc.push(this.ud.pipe((0,D.h)((t=>!!t)),(0,V.w)((t=>(0,F.H)((null==t?void 0:t.delay)*B.s_).pipe($(t))))).subscribe((t=>{this.Id(t)})))}Id(t){const i=t;let e=L.TRACKING_POINTS.indexOf(i);i.timesRepeatDelay--,this.wd(i.delay),0===i.timesRepeatDelay&&e++,(0,G.$K)(L.TRACKING_POINTS[e])&&this.Sd(L.TRACKING_POINTS[e])}Sd(t){this.ud.next(t)}wd(t){const i=(0,W.kw)(this.pd.timeElapsed),e=(0,W.kw)(this.fd.timeElapsed),s={sessionTimeInSeconds:t,timePlayedInSeconds:i<0?0:i,timePlayedInViewInSeconds:e<0?0:e};this.pd.reset(),this.fd.reset(),this.Vc.sessionTimeElapsed.next(s)}};Z.TIMER_TICK=200,Z=U=J([(0,w.b2)(),(0,w.Yn)(w.Fw.ContainerScoped),K(0,(0,w.f3)(M.q)),K(1,(0,w.f3)(I.f)),Y("design:paramtypes",["function"==typeof(q=void 0!==X.d&&X.d)?q:Object,"function"==typeof(H=void 0!==s.ITimerService&&s.ITimerService)?H:Object])],Z);var tt=e(1187),it=e(289),et=e(7945),st=e(6153),nt=e(6578),rt=e(307),ot=e(3802);class ht{static getProtoPayload(t){const{dynamicElkFields:i,trackingMetadata:e,isAdBlockerUsed:s,bundleName:n,playerWidth:r,playerHeight:o,pageInsightIndexes:h}=t;return{trackingRequestMeta:ot.yz.getProtoTrackingMetadata(e),hasAdBlocker:s,bundleName:n,playerHeight:o,playerWidth:r,pageInsightIndexes:h,dynamicElkFieldsValues:i}}}class at{static getProtoPayload(t){const{dynamicElkFields:i,trackingMetadata:e,pageInsightIndexes:s}=t;return{trackingRequestMeta:ot.yz.getProtoTrackingMetadata(e),pageInsightIndexes:s,dynamicElkFieldsValues:i}}}class ct{static getProtoPayload(t){const{trackingMetadata:i,adBlockerDetectionType:e,dynamicElkFields:s}=t;return{trackingRequestMeta:ot.yz.getProtoTrackingMetadata(i),adBlockDetectionType:ot.EN.getProtoAdBlockerDetectionType(e),dynamicElkFieldsValues:s}}}class dt{static getProtoPayload(t){const{trackingMetadata:i,sessionTimePassedSinceLastTracking:e,secondsPlayedInViewSinceLastTracking:s,secondsPlayedSinceLastTracking:n,pageInsightIndexes:r}=t;return{trackingRequestMeta:ot.yz.getProtoTrackingMetadata(i),sessionTime:e,timePlayed:n,timePlayedInView:s,pageInsightIndexes:r}}}class lt{static getProtoPayload(t){const{dynamicElkFields:i,trackingMetadata:e,pageInsightIndexes:s}=t;return{trackingRequestMeta:ot.yz.getProtoTrackingMetadata(e),pageInsightIndexes:s,dynamicElkFieldsValues:i}}}class ut{static getProtoPayload(t){const{dynamicElkFields:i,trackingMetadata:e,adBreakType:s,playerWidth:n,pageInsightIndexes:r}=t;return{trackingRequestMeta:ot.yz.getProtoTrackingMetadata(e),adBreak:ot.EN.getProtoAdBreakType(s),playerWidth:n,pageInsightIndexes:r,dynamicElkFieldsValues:i}}}class pt{static getProtoPayload(t){const{trackingMetadata:i,mediaId:e,quartile:s,insightIndexes:n,sentimentAnalysis:r}=t;return{trackingRequestMeta:ot.yz.getProtoTrackingMetadata(i),quartile:ot.EN.getProtoQuartile(s),mediaGuid:e,sentimentAnalysis:r?ot.XE.getProtoSentimentAnalysis(r):void 0,insightIndexes:n}}}class ft{static getProtoPayload(t){const{trackingMetadata:i,type:e,mediaId:s,clickUrl:n,insightIndexes:r,sentimentAnalysis:o,slideTitle:h,slideNumber:a,slideMediaType:c}=t;return{trackingRequestMeta:ot.yz.getProtoTrackingMetadata(i),type:ot.EN.getProtoMediaClickType(e),mediaGuid:s,slideMediaType:c?ot.EN.getProtoMediaType(c):void 0,sentimentAnalysis:o?ot.XE.getProtoSentimentAnalysis(o):void 0,clickUrl:n,slideTitle:h,slideNumber:a,insightIndexes:r}}}var mt=e(3816),gt=e(5650);class vt{static getProtoPayload(t){const{trackingMetadata:i,hasGdprConsent:e,gdprConsentMode:s,isExplorationMode:n,mediaId:r,shouldLogEverything:o,lineItemAbTest:h,prebidList:a,bidList:c,postbidList:d}=t;return{trackingRequestMeta:ot.yz.getProtoTrackingMetadata(i),mediaGuid:r,hasGdprConsentPayload:e,gdprConsentMode:s?ot.EN.getProtoGDPRConsentMode(s):void 0,lineItemAbTestInformation:h?ot.p.getProtoLineItemAbTest(h):void 0,prebids:a&&(0,gt.BZ)(a)?a.map((t=>vt.getProtoPrebid(t))):void 0,bids:c&&(0,gt.BZ)(c)?c.map((t=>vt.getProtoBid(t))):void 0,postBids:d&&(0,gt.BZ)(d)?d.map((t=>vt.getProtoPostbid(t))):void 0,shouldLogEverything:o,isExplorationMode:n}}static getProtoPrebid(t){const{advertiserLineItemId:i,publisherLineItemId:e,playerReason:s,partnerReason:n,requestsCount:r,isUserSynced:o,timeSpentMs:h,playerWidth:a,playerHeight:c,partnerCustomHeaders:d,prebidJsBidderName:l,requestedFloorPrice:u,floorPriceInformation:p,dynamicElkFields:f}=t;return{reason:ot.EN.getProtoPrebidReason(s),partnerReason:ot.EN.getProtoPrebidPartnerReason(n),requestNumber:r,timeSpent:h,floorPriceInformation:p?ot.wE.getProtoFloorPriceInformation(p):void 0,requestedFloorPrice:u,advertiserLineItemId:i,publisherLineItemId:e,isUserSynced:o,playerWidth:a,playerHeight:c,partnerCustomHeaders:d,prebidJsBidderName:l,dynamicElkFieldsValues:f}}static getProtoBid(t){const{advertiserLineItemId:i,publisherLineItemId:e,requestsCount:s,isUserSynced:n,timeSpentMs:r,playerWidth:o,playerHeight:h,rtbCreativeId:a,rtbSeatId:c,rtbADomain:d,rtbDspId:l,cnxBidId:u,encryptedPrice:p,customClientPrice:f,prebidJsBidderName:m,requestedFloorPrice:g,floorPriceInformation:v,dynamicElkFields:y}=t;return{requestNumber:s,timeSpent:r,creativeId:a,rtbAdomain:d,dspId:l,floorPriceInformation:v?ot.wE.getProtoFloorPriceInformation(v):void 0,rtbSeatId:c,cnxBidId:u,advertiserLineItemId:i,publisherLineItemId:e,isUserSynced:n,playerWidth:o,playerHeight:h,encryptedPrice:p,customClientPrice:f,prebidJsBidderName:m,requestedFloorPrice:g,dynamicElkFieldsValues:y}}static getProtoPostbid(t){const{advertiserLineItemId:i,publisherLineItemId:e,reason:s,isBidLoaded:n,requestsCount:r,adSourceType:o,vastMediaType:h,adBreakType:a,isUserSynced:c,timeSpentMs:d,winToAdLoadedTimeMs:l,bidElapsedTimeSeconds:u,playerWidth:p,playerHeight:f,adPodSlotPosition:m,auctionInformation:g,auctionReason:v,rtbCreativeId:y,rtbSeatId:b,rtbADomain:I,rtbDspId:w,cnxBidId:S,prebidJsBidderName:P,requestedFloorPrice:A,floorPriceInformation:_,liveRampType:x,discount:T,dynamicElkFields:k}=t;return{error:s,adBreakType:ot.EN.getProtoAdBreakType(a),adsourceType:ot.EN.getProtoAdSourceType(o),auctionInformation:g?ot.Ti.getProtoAuctionInformation(g):void 0,auctionPostbidReason:v?ot.EN.getProtoAuctionPostbidReason(v):void 0,floorPriceInformation:_?ot.wE.getProtoFloorPriceInformation(_):void 0,discount:T?mt.d.getProtoDiscount(T):void 0,floorPrice:A,liveRampType:x?ot.EN.getProtoLiveRamp(x):void 0,timeSpent:d,winToAdLoadedTime:l,requestNumber:r,creativeId:y,rtbAdomain:I,dspId:w,rtbSeatId:b,cnxBidId:S,advertiserLineItemId:i,publisherLineItemId:e,isBidLoaded:n,vastMediaType:h,isUserSynced:c,bidElapsedTimeSeconds:u,playerWidth:p,playerHeight:f,adPodSlotPosition:m,prebidJsBidderName:P,dynamicElkFieldsValues:k}}}class yt{static getProtoPayload(t){const{cnxBidId:i,auctionLossReason:e,auctionInformation:s}=t;return{cnxBidId:i,auctionInformation:s?ot.Ti.getProtoAuctionInformation(s):void 0,auctionLossReason:ot.EN.getProtoAuctionLossReason(e)}}static fromProtoAuctionInformation(t){const{cnxBidId:i,auctionLossReason:e,auctionInformation:s}=t;return{cnxBidId:i,auctionInformation:s?ot.Ti.fromProtoAuctionInformation(s):void 0,auctionLossReason:ot.EN.fromProtoAuctionLossReason(e)}}}class bt{static getProtoPayload(t){const{dynamicElkFields:i,trackingMetadata:e,advertiserLineItemId:s,type:n}=t;return{trackingRequestMeta:ot.yz.getProtoTrackingMetadata(e),heavyAdBlockTypeEnum:ot.EN.getProtoHeavyAdType(n),advertiserLineItemId:s,dynamicElkFieldsValues:i}}}class It{static getProtoPayload(t){const{trackingMetadata:i,advertiserLineItemId:e,publisherLineItemId:s,adBreakType:n,adSourceType:r,vastMediaType:o,adPodSlotPosition:h,isExplorationMode:a,mediaId:c,isUserSynced:d,timeSpentMs:l,winToAdLoadedTimeMs:u,startAdToImpressionTimeMs:p,declaredDurationSeconds:f,impressionDurationSeconds:m,encryptedPrice:g,rtbADomain:v,rtbSeatId:y,rtbCreativeId:b,rtbDspId:I,cnxBidId:w,customClientPrice:S,prebidJsBidderName:P,auctionInformation:A,playerWidth:_,playerHeight:x,hasAdSkip:T,requestsCount:k,requestedFloorPrice:C,floorPriceInformation:E,bidElapsedTimeSeconds:M,insightIndexes:L,pageInsightIndexes:B,sentimentAnalysis:R,liveRampType:O,lineItemAbTest:D,internalAuctionInformation:V,iasSegmentCodes:F,discount:N,dynamicElkFields:j,serverBillingNoticeUrls:$}=t;return{trackingRequestMeta:ot.yz.getProtoTrackingMetadata(i),adBreakType:ot.EN.getProtoAdBreakType(n),adsourceType:ot.EN.getProtoAdSourceType(r),auctionInformation:A?ot.Ti.getProtoAuctionInformation(A):void 0,internalAuction:V?ot.W1.getProtoInternalAuction(V):void 0,timeSpent:l,winToAdLoadedTime:u,startAdToImpressionTime:p,declaredDuration:f,impressionDuration:m,sentimentAnalysis:R?ot.XE.getProtoSentimentAnalysis(R):void 0,lineItemAbTestInformation:D?ot.p.getProtoLineItemAbTest(D):void 0,floorPriceInformation:E?ot.wE.getProtoFloorPriceInformation(E):void 0,discount:N?mt.d.getProtoDiscount(N):void 0,mediaGuid:c,floorPrice:C,creativeId:b,rtbAdomain:v,dspId:I,requestNumber:k,liveRampType:O?ot.EN.getProtoLiveRamp(O):void 0,dynamicElkFieldsValues:j,cnxBidId:w,rtbSeatId:y,vastMediaType:o,advertiserLineItemId:e,publisherLineItemId:s,isExplorationMode:a,isUserSynced:d,playerWidth:_,playerHeight:x,hasAdSkip:T,bidElapsedTimeSeconds:M,adPodSlotPosition:h,encryptedPrice:g,customClientPrice:S,prebidJsBidderName:P,insightIndexes:L,pageInsightIndexes:B,iasSegmentCodes:F,serverBillingNoticeUrls:$}}}class wt{static getProtoPayload(t){const{trackingMetadata:i,advertiserLineItemId:e,publisherLineItemId:s,adBreakType:n,mediaId:r,hasSkipAd:o,rtbSeatId:h,rtbADomain:a,rtbDspId:c,insightIndexes:d,sentimentAnalysis:l,pageInsightIndexes:u,lineItemAbTest:p,iasSegmentCodes:f,dynamicElkFields:m,discount:g}=t;return{trackingRequestMeta:ot.yz.getProtoTrackingMetadata(i),adBreakType:ot.EN.getProtoAdBreakType(n),sentimentAnalysis:l?ot.XE.getProtoSentimentAnalysis(l):void 0,lineItemAbTestInformation:p?ot.p.getProtoLineItemAbTest(p):void 0,discount:g?mt.d.getProtoDiscount(g):void 0,mediaGuid:r,hasAdSkip:o,dynamicElkFieldsValues:m,rtbAdomain:a,advertiserLineItemId:e,publisherLineItemId:s,rtbSeatId:h,dspId:c,insightIndexes:d,pageInsightIndexes:u,iasSegmentCodes:f}}}class St{static getProtoPayload(t){const{trackingMetadata:i,advertiserLineItemId:e,publisherLineItemId:s,mediaId:n,type:r,rtbSeatId:o,dspId:h,rtbADomain:a,insightIndexes:c,hasSkipAd:d,adBreakType:l,sentimentAnalysis:u,pageInsightIndexes:p,lineItemAbTest:f,iasSegmentCodes:m}=t;return{trackingRequestMeta:ot.yz.getProtoTrackingMetadata(i),quartile:ot.EN.getProtoQuartile(r),adBreakType:ot.EN.getProtoAdBreakType(l),lineItemAbTestInformation:f?ot.p.getProtoLineItemAbTest(f):void 0,sentimentAnalysis:u?ot.XE.getProtoSentimentAnalysis(u):void 0,mediaGuid:n,hasAdSkip:d,rtbAdomain:a,rtbSeatId:o,dspId:h,advertiserLineItemId:e,publisherLineItemId:s,insightIndexes:c,pageInsightIndexes:p,iasSegmentCodes:m}}}class Pt{static getProtoPayload(t){const{trackingMetadata:i,advertiserLineItemId:e,publisherLineItemId:s,mediaId:n,type:r,adBreakType:o,insightIndexes:h,sentimentAnalysis:a,pageInsightIndexes:c,lineItemAbTest:d,iasSegmentCodes:l}=t;return{trackingRequestMeta:ot.yz.getProtoTrackingMetadata(i),mediaGuid:n,type:ot.EN.getProtoAdClickType(r),adBreakType:ot.EN.getProtoAdBreakType(o),sentimentAnalysis:a?ot.XE.getProtoSentimentAnalysis(a):void 0,lineItemAbTestInformation:d?ot.p.getProtoLineItemAbTest(d):void 0,advertiserLineItemId:e,publisherLineItemId:s,insightIndexes:h,pageInsightIndexes:c,iasSegmentCodes:l}}}class At{static getTrackingResponseFromProto(t){const{errorMessage:i,adServerLineItemName:e,impressionRevenue:s,isViewabilityRestricted:n,platformCappedLineItemIdList:r}=t;return{errorMessage:i,adServerLineItemName:e,impressionRevenue:s,isViewabilityRestricted:n,platformCappedLineItemIdList:r}}}var _t,xt,Tt=e(6286),kt=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o},Ct=function(t,i){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,i)},Et=function(t,i){return function(e,s){i(e,s,t)}},Mt=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};let Lt=_t=class{constructor(t){this.Pd=t}static bs(t,i){(0,tt.n)({message:`ProtoTrackingCallerService_error_${i}`,level:tt.D.INFO,exception:t?JSON.stringify(t):void 0},{throttle:1,pacing:1,shouldSendMaxLog:!1})}sessionRenderEvent(t){return Mt(this,void 0,void 0,(function*(){return this._d(st.n.endPoints.tracking.session_rendered,it.ProtoSessionRenderedRequest,ht.getProtoPayload(t))}))}playerStartEvent(t){return Mt(this,void 0,void 0,(function*(){return this._d(st.n.endPoints.tracking.playerStart,it.ProtoPlayerStartRequest,at.getProtoPayload(t))}))}adOpportunityEvent(t){return Mt(this,void 0,void 0,(function*(){return this._d(st.n.endPoints.tracking.adOpportunity,it.ProtoAdOpportunityRequest,ut.getProtoPayload(t))}))}sessionAdBlockerEvent(t){return Mt(this,void 0,void 0,(function*(){return this._d(st.n.endPoints.tracking.sessionAdBlocker,it.ProtoSessionAdBlockerRequest,ct.getProtoPayload(t))}))}sessionTimeEvent(t){return Mt(this,void 0,void 0,(function*(){return this._d(st.n.endPoints.tracking.session_time,it.ProtoSessionTimeTrackingRequest,dt.getProtoPayload(t))}))}sessionInViewEvent(t){return Mt(this,void 0,void 0,(function*(){return this._d(st.n.endPoints.tracking.session_view,it.ProtoSessionViewRequest,lt.getProtoPayload(t))}))}mediaClickEvent(t){return Mt(this,void 0,void 0,(function*(){return this._d(st.n.endPoints.tracking.media_click,it.ProtoMediaClickTrackingRequest,ft.getProtoPayload(t))}))}mediaQuartileEvent(t){return Mt(this,void 0,void 0,(function*(){return this._d(st.n.endPoints.tracking.media_quartile,it.ProtoMediaQuartileRequest,pt.getProtoPayload(t))}))}adBidEvent(t){return Mt(this,void 0,void 0,(function*(){return this._d(st.n.endPoints.tracking.bids,it.ProtoBidTrackingsRequest,vt.getProtoPayload(t))}))}auctionInformationEvent(t){return Mt(this,void 0,void 0,(function*(){return this._d(st.n.endPoints.tracking.auctionInformation,it.ProtoAuctionInfoRequest,yt.getProtoPayload(t))}))}adImpressionEvent(t){return Mt(this,void 0,void 0,(function*(){return this._d(st.n.endPoints.tracking.ad_impression,it.ProtoVideoAdImpressionRequest,It.getProtoPayload(t),t.advertiserLineItemId)}))}adInViewEvent(t){return Mt(this,void 0,void 0,(function*(){return this._d(st.n.endPoints.tracking.ad_impression_viewable,it.ProtoVideoAdImpressionViewableRequest,wt.getProtoPayload(t),t.advertiserLineItemId)}))}adQuartileEvent(t){return Mt(this,void 0,void 0,(function*(){return this._d(st.n.endPoints.tracking.ad_quartile,it.ProtoVideoAdQuartilesRequest,St.getProtoPayload(t),t.advertiserLineItemId)}))}adClickEvent(t){return Mt(this,void 0,void 0,(function*(){return this._d(st.n.endPoints.tracking.ad_click,it.ProtoAdClickTrackingRequest,Pt.getProtoPayload(t),t.advertiserLineItemId)}))}heavyAdEvent(t){this.xd(st.n.endPoints.tracking.heavy_ad_intervention,it.ProtoHeavyAdTrackingRequest,bt.getProtoPayload(t))}_d(t,i,e,s){return Mt(this,void 0,void 0,(function*(){try{const n=yield nt.n.sendProtoRequest({endpoint:t,requestData:e,queryParams:{[rt.Fk]:et.g.version,[rt.cc]:st.n.tier},protoRequest:i,protoResponse:it.ProtoTrackingResponse,hasCredentials:!0,shouldLogErrors:!0}),r=At.getTrackingResponseFromProto(n);this.Pd.onResponseReceived(r,s)}catch(i){_t.bs(i,t)}}))}xd(t,i,e){try{nt.n.sendProtoBeaconRequest({endpoint:t,requestData:e,queryParams:{[rt.Fk]:et.g.version,[rt.cc]:st.n.tier},protoRequest:i,shouldLogErrors:!1})}catch(i){_t.bs(i,t)}}};Lt=_t=kt([(0,w.b2)(),(0,w.Yn)(w.Fw.ContainerScoped),Et(0,(0,w.f3)(Tt.j)),Ct("design:paramtypes",["function"==typeof(xt=void 0!==n.ITrackingResponseService&&n.ITrackingResponseService)?xt:Object])],Lt);var Bt=e(3432);class Rt{}Rt.CUSTOM_TEST_PLAYER_ID="e4984e88-9ff4-45a3-8b9d-33aabcad634e",Rt.CUSTOM_SESSION_ID="x1291569711993656821050542063616";var Ot=e(6666);class Dt{static fromPayloadToTracking(t,i){var e;const{type:s,adBreakType:n,publisherLineItemId:r,advertiserLineItemId:o}=t,{currentMediaMetadata:{mediaId:h,insights:a,sentimentAnalysis:c},iasSegmentCodes:d,trackingRequestMeta:l,lineItemAbTestInformation:u}=i;return{type:s,adBreakType:n,publisherLineItemId:r,advertiserLineItemId:o,mediaId:h,iasSegmentCodes:d,insightIndexes:a,trackingMetadata:ot.yz.fromProtoGetTrackingMetadata(l),pageInsightIndexes:null===(e=Ot.k.pageInsights)||void 0===e?void 0:e.insights,sentimentAnalysis:c?ot.XE.fromProtoGetSentimentAnalysis(c):void 0,lineItemAbTest:u?ot.p.fromProtoLineItemAbTestFromProto(u):void 0}}}class Vt{static fromPayloadToTracking(t,i){var e;const{width:s,height:n}=i.playerDimensions,{currentMediaMetadata:{mediaId:r,insights:o,sentimentAnalysis:h},lineItemAbTestInformation:a}=i,{adSourceType:c,advertiserLineItemId:d,publisherLineItemId:l,customClientPrice:u,encryptedPrice:p,prebidJsBidderName:f,rtbADomain:m,rtbCreativeId:g,rtbSeatId:v,isUserSynced:y,timeSpentMs:b,vastMediaType:I,rtbDspId:w,cnxBidId:S,winToAdLoadedTimeMs:P,startAdToImpressionTimeMs:A,impressionDurationSeconds:_,declaredDurationSeconds:x,isExplorationMode:T,requestsCount:k,requestedFloorPrice:C,floorPriceInformation:E,bidElapsedTimeSeconds:M,adBreakType:L,internalAuctionInformation:B,auctionInformation:R,dynamicElkFields:O,hasAdSkip:D,discount:V,liveRampType:F,serverBillingNoticeUrls:N}=t;return{adSourceType:c,advertiserLineItemId:d,publisherLineItemId:l,customClientPrice:u,encryptedPrice:p,prebidJsBidderName:f,rtbADomain:m,rtbCreativeId:g,rtbSeatId:v,isUserSynced:y,timeSpentMs:b,vastMediaType:I,rtbDspId:w,cnxBidId:S,winToAdLoadedTimeMs:P,startAdToImpressionTimeMs:A,impressionDurationSeconds:_,declaredDurationSeconds:x,isExplorationMode:T,requestsCount:k,requestedFloorPrice:C,floorPriceInformation:E,bidElapsedTimeSeconds:M,adBreakType:L,internalAuctionInformation:B,auctionInformation:R,dynamicElkFields:O,hasAdSkip:D,mediaId:r,liveRampType:F,serverBillingNoticeUrls:N,trackingMetadata:ot.yz.fromProtoGetTrackingMetadata(i.trackingRequestMeta),lineItemAbTest:a?ot.p.fromProtoLineItemAbTestFromProto(a):void 0,iasSegmentCodes:i.iasSegmentCodes,playerWidth:s,playerHeight:n,insightIndexes:o,sentimentAnalysis:h?ot.XE.fromProtoGetSentimentAnalysis(h):void 0,pageInsightIndexes:null===(e=Ot.k.pageInsights)||void 0===e?void 0:e.insights,discount:V?mt.d.fromProtoDiscount(V):void 0}}}class Ft{static fromPayloadToTracking(t,i){var e;const{currentMediaMetadata:{mediaId:s,insights:n,sentimentAnalysis:r},lineItemAbTestInformation:o,trackingRequestMeta:h,iasSegmentCodes:a}=i,{publisherLineItemId:c,advertiserLineItemId:d,rtbSeatId:l,rtbDspId:u,adBreakType:p,hasSkipAd:f,rtbADomain:m,discount:g}=t;return{mediaId:s,publisherLineItemId:c,advertiserLineItemId:d,rtbSeatId:l,rtbDspId:u,adBreakType:p,hasSkipAd:f,rtbADomain:m,iasSegmentCodes:a,discount:g,trackingMetadata:ot.yz.fromProtoGetTrackingMetadata(h),lineItemAbTest:o?ot.p.fromProtoLineItemAbTestFromProto(o):void 0,insightIndexes:n,sentimentAnalysis:r?ot.XE.fromProtoGetSentimentAnalysis(r):void 0,pageInsightIndexes:null===(e=Ot.k.pageInsights)||void 0===e?void 0:e.insights}}}class Nt{static fromPayloadToTracking(t,i){var e;const{currentMediaMetadata:{sentimentAnalysis:s,mediaId:n,insights:r},lineItemAbTestInformation:o,iasSegmentCodes:h}=i,{advertiserLineItemId:a,publisherLineItemId:c,type:d,rtbSeatId:l,dspId:u,adBreakType:p,hasSkipAd:f,rtbADomain:m}=t;return{mediaId:n,advertiserLineItemId:a,publisherLineItemId:c,type:d,rtbSeatId:l,dspId:u,adBreakType:p,hasSkipAd:f,rtbADomain:m,iasSegmentCodes:h,insightIndexes:r,trackingMetadata:ot.yz.fromProtoGetTrackingMetadata(i.trackingRequestMeta),sentimentAnalysis:s?ot.XE.fromProtoGetSentimentAnalysis(s):void 0,pageInsightIndexes:null===(e=Ot.k.pageInsights)||void 0===e?void 0:e.insights,lineItemAbTest:o?ot.p.fromProtoLineItemAbTestFromProto(o):void 0}}}var jt=e(9361);class $t{static fromPayloadToTracking(t,i){const{mediaId:e,clickUrl:s,sentimentAnalysis:n,slideTitle:r,slideNumber:o,slideMediaType:h,insights:a}=i.currentMediaMetadata,c=t.type||jt.$u.Click;return{trackingMetadata:ot.yz.fromProtoGetTrackingMetadata(i.trackingRequestMeta),slideMediaType:h?ot.EN.fromProtoGetMediaType(h):void 0,sentimentAnalysis:n?ot.XE.fromProtoGetSentimentAnalysis(n):void 0,clickUrl:c===jt.$u.UrlClick?s:void 0,insightIndexes:a,mediaId:e,type:c,slideTitle:r,slideNumber:o}}}class Ut{static fromPayloadToTracking(t,i,e){const{currentMediaMetadata:s,isExplorationMode:n,lineItemAbTestInformation:r,canTrackAllRequests:o,hasGdprConsentPayload:h,playerDimensions:a}=i,c=t.prebidList.map((t=>zt.fromPayloadToTracking(t,a))),d=t.bidList.map((t=>qt.fromPayloadToTracking(t,a))),l=t.postbidList.map((t=>Ht.fromPayloadToTracking(t,a)));return{isExplorationMode:n,gdprConsentMode:e,trackingMetadata:ot.yz.fromProtoGetTrackingMetadata(i.trackingRequestMeta),shouldLogEverything:o,prebidList:c,bidList:d,postbidList:l,mediaId:null==s?void 0:s.mediaId,hasGdprConsent:h,lineItemAbTest:r?ot.p.fromProtoLineItemAbTestFromProto(r):void 0}}}class qt{static fromPayloadToTracking(t,i){const{width:e,height:s}=i,{encryptedPrice:n,customClientPrice:r,floorPriceFactorBypassReason:o,rtbCreativeId:h,rtbSeatId:a,rtbADomain:c,rtbDspId:d,cnxBidId:l,publisherLineItemId:u,advertiserLineItemId:p,requestsCount:f,isUserSynced:m,timeSpentMs:g,requestedFloorPrice:v,floorPriceInformation:y,prebidJsBidderName:b,dynamicElkFields:I}=t;return{playerWidth:e,playerHeight:s,encryptedPrice:n,customClientPrice:r,floorPriceFactorBypassReason:o,rtbCreativeId:h,rtbSeatId:a,rtbADomain:c,rtbDspId:d,cnxBidId:l,publisherLineItemId:u,advertiserLineItemId:p,requestsCount:f,isUserSynced:m,timeSpentMs:g,requestedFloorPrice:v,floorPriceInformation:y,prebidJsBidderName:b,dynamicElkFields:I}}}class Ht{static fromPayloadToTracking(t,i){const{width:e,height:s}=i,{reason:n,adSourceType:r,vastMediaType:o,bidElapsedTimeSeconds:h,isBidLoaded:a,winToAdLoadedTimeMs:c,adBreakType:d,auctionInformation:l,auctionReason:u,adPodSlotPosition:p,prebidJsBidderName:f,dynamicElkFields:m,publisherLineItemId:g,advertiserLineItemId:v,isUserSynced:y,rtbCreativeId:b,rtbSeatId:I,rtbADomain:w,rtbDspId:S,cnxBidId:P,timeSpentMs:A,requestsCount:_,requestedFloorPrice:x,floorPriceInformation:T,discount:k,liveRampType:C}=t;return{playerWidth:e,playerHeight:s,reason:n,adSourceType:r,vastMediaType:o,bidElapsedTimeSeconds:h,isBidLoaded:a,winToAdLoadedTimeMs:c,adBreakType:d,auctionInformation:l,auctionReason:u,adPodSlotPosition:p,prebidJsBidderName:f,dynamicElkFields:m,publisherLineItemId:g,advertiserLineItemId:v,isUserSynced:y,rtbCreativeId:b,rtbSeatId:I,rtbADomain:w,rtbDspId:S,cnxBidId:P,timeSpentMs:A,requestsCount:_,requestedFloorPrice:x,floorPriceInformation:T,discount:k,liveRampType:C}}}class zt{static fromPayloadToTracking(t,i){const{width:e,height:s}=i,{playerReason:n,partnerReason:r,partnerCustomHeaders:o,publisherLineItemId:h,advertiserLineItemId:a,requestedFloorPrice:c,requestsCount:d,isUserSynced:l,prebidJsBidderName:u,timeSpentMs:p,floorPriceInformation:f,dynamicElkFields:m}=t;return{playerWidth:e,playerHeight:s,playerReason:n,partnerReason:r,partnerCustomHeaders:o,publisherLineItemId:h,advertiserLineItemId:a,requestedFloorPrice:c,requestsCount:d,isUserSynced:l,prebidJsBidderName:u,timeSpentMs:p,floorPriceInformation:f,dynamicElkFields:m}}}e(7129);var Wt,Gt,Xt,Qt,Jt,Yt,Kt,Zt,ti=e(6661),ii=e(5742),ei=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o},si=function(t,i){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,i)},ni=function(t,i){return function(e,s){i(e,s,t)}};let ri=class{constructor(t,i,e,s,n,r,o,h){this.Dc=t,this.Vc=i,this.Td=e,this.Cd=s,this.Ld=n,this.zc=r,this.Bd=o,this.Rd=h,this.Fc=[],this.gd(),this.Kc(),this.Od()}destroy(){(0,Q.i)(this.Fc),this.Cd.destroy(),this.Ld.destroy()}Kc(){this.Fc.push(this.zc.adClick.subscribe((t=>{this.Dd(t)})),this.zc.adImpression.subscribe((t=>{this.Vd(t)})),this.zc.adInView.subscribe((t=>{this.Fd(t)})),this.zc.adQuartile.subscribe((t=>{this.Nd(t)})),this.zc.heavyAd.subscribe((t=>{this.jd(t)})),this.zc.auctionInformation.subscribe((t=>{this.$d(t)})),this.zc.missedImpressionOutOfView.subscribe((t=>{this.Ud(t)})),this.zc.adBidTracking.subscribe((t=>{this.qd(t)})))}gd(){this.Fc.push(this.Vc.sessionTimeElapsed.subscribe((t=>{this.Hd(t)})),this.Vc.sessionRendered.pipe((0,z.q)(1)).subscribe((t=>{this.zd(t)})),this.Vc.sessionView.subscribe((()=>{this.Wd()})),this.Vc.sessionAdBlocked.subscribe((t=>{this.Gd(t)})),this.Vc.adOpportunity.subscribe((t=>{this.Xd(t)})),this.Vc.contentStart.pipe((0,z.q)(1)).subscribe((()=>{this.Qd()})),this.Vc.adsEnabled.pipe((0,z.q)(1)).subscribe((()=>{this.Qd()})))}Od(){this.Fc.push(this.Td.mediaQuartile.subscribe((t=>{this.Jd(t)})),this.Td.mediaClick.subscribe((t=>{this.Yd(t)})))}Qd(){var t;this.Dc.isPlayerStartTracked||(this.Dc.isPlayerStartTracked=!0,this.Bd.playerStartEvent({trackingMetadata:ot.yz.fromProtoGetTrackingMetadata(this.Dc.trackingRequestMeta),pageInsightIndexes:null===(t=Ot.k.pageInsights)||void 0===t?void 0:t.insights,dynamicElkFields:{1:ii.f.getCidForElkTracking()}}))}jd(t){const{type:i,advertiserLineItemId:e,dynamicElkFields:s}=t,n=Object.assign(Object.assign({},s),{1:ii.f.getCidForElkTracking()});this.Bd.heavyAdEvent({trackingMetadata:ot.yz.fromProtoGetTrackingMetadata(this.Dc.trackingRequestMeta),type:i,advertiserLineItemId:e,dynamicElkFields:n})}qd(t){const i=ot.EN.fromProtoGDPRConsentMode(this.Rd.gdprConsentMode),e=Ut.fromPayloadToTracking(t,this.Dc,i);this.Bd.adBidEvent(e)}Hd(t){var i;const{sessionTimeInSeconds:e,timePlayedInSeconds:s,timePlayedInViewInSeconds:n}=t,{trackingRequestMeta:r}=this.Dc;this.Bd.sessionTimeEvent({trackingMetadata:ot.yz.fromProtoGetTrackingMetadata(r),sessionTimePassedSinceLastTracking:e,secondsPlayedSinceLastTracking:s,secondsPlayedInViewSinceLastTracking:n,pageInsightIndexes:null===(i=Ot.k.pageInsights)||void 0===i?void 0:i.insights})}zd(t){var i;if(this.Dc.isSessionRenderTracked)return;this.Dc.isSessionRenderTracked=!0;const{width:e,height:s}=this.Dc.playerDimensions,{isBannerBlocked:n,sdkVersion:r}=t,o={7:ii.f.getCidForElkTracking()};(0,G.QM)(r)&&(o[3]=`${r}`),this.Bd.sessionRenderEvent({playerHeight:s,playerWidth:e,isAdBlockerUsed:n,bundleName:"connatix.player.dc.js",dynamicElkFields:o,trackingMetadata:ot.yz.fromProtoGetTrackingMetadata(this.Dc.trackingRequestMeta),pageInsightIndexes:null===(i=Ot.k.pageInsights)||void 0===i?void 0:i.insights})}Wd(){var t;if(this.Dc.isSessionViewTracked||!this.Dc.isPlayerStartTracked)return;this.Dc.isSessionViewTracked=!0;const i={9:ii.f.getCidForElkTracking()};this.Bd.sessionInViewEvent({trackingMetadata:ot.yz.fromProtoGetTrackingMetadata(this.Dc.trackingRequestMeta),pageInsightIndexes:null===(t=Ot.k.pageInsights)||void 0===t?void 0:t.insights,dynamicElkFields:i})}Ud(t){var i;const e=Object.assign(Object.assign({},this.Dc.trackingRequestMeta),{playerId:Rt.CUSTOM_TEST_PLAYER_ID,sessionId:Rt.CUSTOM_SESSION_ID}),s={1:`${t.outOfViewAdPrice}`,2:`${t.outOfViewAdLineItemId}`,3:`${t.inViewAdPrice}`,4:`${t.outOfViewTimeRunning}`,5:`${t.distanceWhenOutOfViewStarted}`,6:`${t.timeUntilNextOpportunity}`,7:`${this.Dc.sessionId}`,8:`${this.Dc.playerId}`,9:ii.f.getCidForElkTracking()};this.Bd.sessionInViewEvent({trackingMetadata:ot.yz.fromProtoGetTrackingMetadata(e),pageInsightIndexes:null===(i=Ot.k.pageInsights)||void 0===i?void 0:i.insights,dynamicElkFields:s})}Jd(t){const{mediaId:i,insights:e,sentimentAnalysis:s}=this.Dc.currentMediaMetadata,{quartile:n}=t;this.Bd.mediaQuartileEvent({trackingMetadata:ot.yz.fromProtoGetTrackingMetadata(this.Dc.trackingRequestMeta),sentimentAnalysis:s?ot.XE.fromProtoGetSentimentAnalysis(s):void 0,mediaId:i,quartile:n,insightIndexes:e})}Yd(t){const i=$t.fromPayloadToTracking(t,this.Dc);this.Bd.mediaClickEvent(i)}$d(t){this.Bd.auctionInformationEvent(t)}Vd(t){const i=Vt.fromPayloadToTracking(t,this.Dc);this.Bd.adImpressionEvent(i)}Fd(t){const i=Ft.fromPayloadToTracking(t,this.Dc);this.Bd.adInViewEvent(i)}Nd(t){const i=Nt.fromPayloadToTracking(t,this.Dc);this.Bd.adQuartileEvent(i)}Dd(t){const i=Dt.fromPayloadToTracking(t,this.Dc);this.Bd.adClickEvent(i)}Xd(t){var i;const{trackingRequestMeta:e}=this.Dc,{playerWidth:s,opportunityId:n,adBreak:r}=t,o={1:`${n}`,2:ii.f.getCidForElkTracking()};this.Bd.adOpportunityEvent({adBreakType:r,playerWidth:s,dynamicElkFields:o,trackingMetadata:ot.yz.fromProtoGetTrackingMetadata(e),pageInsightIndexes:null===(i=Ot.k.pageInsights)||void 0===i?void 0:i.insights})}Gd(t){const{adBlockDetectionType:i}=t,e={1:ii.f.getCidForElkTracking()},s={trackingMetadata:ot.yz.fromProtoGetTrackingMetadata(this.Dc.trackingRequestMeta),adBlockerDetectionType:i,dynamicElkFields:e};this.Bd.sessionAdBlockerEvent(s)}};ri=ei([(0,w.b2)(),(0,w.Yn)(w.Fw.ContainerScoped),ni(0,(0,w.f3)(T.B)),ni(1,(0,w.f3)(M.q)),ni(2,(0,w.f3)(E)),ni(3,(0,w.f3)(x)),ni(4,(0,w.f3)(Z)),ni(5,(0,w.f3)(y.k)),ni(6,(0,w.f3)(Lt)),ni(7,(0,w.f3)(ti.c.UserManagerService)),si("design:paramtypes",["function"==typeof(Wt=void 0!==Bt.B&&Bt.B)?Wt:Object,"function"==typeof(Gt=void 0!==X.d&&X.d)?Gt:Object,"function"==typeof(Xt=void 0!==o.IMediaEvents&&o.IMediaEvents)?Xt:Object,"function"==typeof(Qt=void 0!==r.IAbtTracker&&r.IAbtTracker)?Qt:Object,"function"==typeof(Jt=void 0!==h.ISessionTime&&h.ISessionTime)?Jt:Object,"function"==typeof(Yt=void 0!==b.q&&b.q)?Yt:Object,"function"==typeof(Kt=void 0!==a.ITrackingCaller&&a.ITrackingCaller)?Kt:Object,"function"==typeof(Zt=void 0!==c.IUserManagerService&&c.IUserManagerService)?Zt:Object])],ri);var oi=e(9906),hi=e(3020),ai=e(5356),ci=e(8983),di=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o};let li=class{constructor(){this.Kd=t=>{const i=t.target.closest("[tabindex]");i&&(i.focus({preventScroll:!0}),(0,hi.IV)(i,ci.s6.TabFocus),this.Zd&&(0,ai.mb)(this.Zd)&&(0,hi.cn)(this.Zd,ci.s6.AdUserInteraction))}}start(t){this.tl(t)}processAdUserInteraction(t=!1){(t||(0,hi.pv)(this.Zd,ci.s6.AdUserInteraction))&&(this.il(),this.Zd&&((0,hi.IV)(this.Zd,ci.s6.AdUserInteraction),(0,hi.IV)(this.Zd,ci.s6.TabFocus)))}destroy(){var t;null===(t=this.Zd)||void 0===t||t.removeEventListener("click",this.Kd)}il(){var t;null===(t=this.Zd)||void 0===t||t.focus({preventScroll:!0})}tl(t){this.Zd=t,null==t||t.addEventListener("click",this.Kd)}};li=di([(0,w.b2)(),(0,w.Yn)(w.Fw.ContainerScoped)],li);var ui=e(6961),pi=e(9209),fi=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o};let mi=class{constructor(){this.el=new k.x,this.sl=[pi.Ys.Space,pi.Ys.ArrowDown,pi.Ys.ArrowUp],this.nl=t=>{const i=t.code;let e=pi.Pl[pi.Ys[i]];this.sl.includes(pi.Ys[i])&&t.preventDefault(),t.shiftKey&&t.code===pi.Ys[pi.Ys.KeyN]&&(e=pi.Pl[pi.Ys.KeyN]),t.shiftKey&&t.code===pi.Ys[pi.Ys.KeyP]&&(e=pi.Pl[pi.Ys.KeyP]),void 0!==e&&this.el.next({action:e})}}get shortcutsEventObservable(){return this.el.asObservable()}start(t){this.rl(t)}destroy(){e.g.removeEventListener("keydown",this.nl)}rl(t){t.addEventListener("keydown",this.nl)}};var gi;mi=fi([(0,w.b2)(),(0,w.Yn)(w.Fw.ContainerScoped)],mi),function(t){t.AdBreakStatus="cnx_ad_break_status"}(gi||(gi={}));var vi,yi=e(5687),bi=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o},Ii=function(t,i){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,i)},wi=function(t,i){return function(e,s){i(e,s,t)}};let Si=class{constructor(t){this.ol=t,this.Is=new Map}start(t){this.hl=this.al(t)}destroy(){(0,hi.bX)(this.hl)}openChannels(t){t.forEach((t=>{this.Is.get(t)||this.Is.set(t,this.cl())}))}closeChannels(t){t.forEach((t=>{const i=this.Is.get(t);i&&(i.innerHTML="")}))}emitMessage(t,i){const e=this.Is.get(t);e&&(e.innerHTML=i)}mute(){var t;null===(t=this.hl)||void 0===t||t.classList.add(ci.Gj.Hide),this.Is.forEach((t=>{t.innerHTML=""}))}unMute(){var t;null===(t=this.hl)||void 0===t||t.classList.remove(ci.Gj.Hide)}al(t){const i=this.ol.createElementByString(`<cnx class="${ci.Rp.Wrapper}"></cnx>`);return t.appendChild(i),i}cl(){var t;const i=this.ol.createElementByString('<cnx role="status"></cnx>');return null===(t=this.hl)||void 0===t||t.appendChild(i),i}};Si=bi([(0,w.b2)(),(0,w.Yn)(w.Fw.ContainerScoped),wi(0,(0,w.f3)(ti.c.GlobalDomUtilsService)),Ii("design:paramtypes",["function"==typeof(vi=void 0!==yi.m&&yi.m)?vi:Object])],Si);var Pi,Ai,_i,xi=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o},Ti=function(t,i){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,i)},ki=function(t,i){return function(e,s){i(e,s,t)}};let Ci=class{constructor(t,i,e){this.zc=t,this.Vc=i,this.dl=e,this.Fc=[],this.ll=!1,this.ul=!1}start(t){this.Kc(),this.dl.start(t)}destroy(){(0,Q.i)(this.Fc),this.dl.destroy()}Kc(){this.Fc.push(this.zc.adBreakStart.subscribe((({adSkippableInSeconds:t,isLinear:i})=>{i&&(this.ul=!0,this.ll&&this.pl(t))})),this.zc.adBreakEnd.subscribe((()=>{this.ul=!1,this.fl()})),this.Vc.sessionViewabilityChanged.subscribe((({isInView:t})=>{t?(this.ul&&this.pl(0),this.dl.unMute()):this.ul||this.dl.mute(),this.ll=t})))}pl(t){this.dl.openChannels([gi.AdBreakStatus]);let i="The video player is currently playing an ad.";t>0&&(i+=` You can skip the ad in ${t} sec with a mouse or keyboard`),this.dl.emitMessage(gi.AdBreakStatus,i)}fl(){this.dl.closeChannels([gi.AdBreakStatus])}};Ci=xi([(0,w.b2)(),(0,w.Yn)(w.Fw.ContainerScoped),ki(0,(0,w.f3)(y.k)),ki(1,(0,w.f3)(M.q)),ki(2,(0,w.f3)(Si)),Ti("design:paramtypes",["function"==typeof(Pi=void 0!==b.q&&b.q)?Pi:Object,"function"==typeof(Ai=void 0!==X.d&&X.d)?Ai:Object,"function"==typeof(_i=void 0!==p.IStatusMessenger&&p.IStatusMessenger)?_i:Object])],Ci);var Ei,Mi,Li,Bi,Ri=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o},Oi=function(t,i){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,i)},Di=function(t,i){return function(e,s){i(e,s,t)}};let Vi=class{constructor(t,i,e,s){this.ml=t,this.gl=i,this.vl=e,this.yl=s}start(t,i,e=!1){this.ml.start(t),e||this.gl.start(t),this.vl.start(t),i&&this.yl.start(t)}getShortcutsObservable(){return this.vl.shortcutsEventObservable}processAdUserInteraction(t=!1){var i;null===(i=this.ml)||void 0===i||i.processAdUserInteraction(t)}destroy(){this.ml.destroy(),this.gl.destroy(),this.vl.destroy(),this.yl.destroy()}};Vi=Ri([(0,w.b2)(),(0,w.Yn)(w.Fw.ContainerScoped),Di(0,(0,w.f3)(li)),Di(1,(0,w.f3)(ui.m)),Di(2,(0,w.f3)(mi)),Di(3,(0,w.f3)(Ci)),Oi("design:paramtypes",["function"==typeof(Ei=void 0!==d.IFocusService&&d.IFocusService)?Ei:Object,"function"==typeof(Mi=void 0!==ui.m&&ui.m)?Mi:Object,"function"==typeof(Li=void 0!==l.IKeyboardShortcutsService&&l.IKeyboardShortcutsService)?Li:Object,"function"==typeof(Bi=void 0!==u.IStatusBroker&&u.IStatusBroker)?Bi:Object])],Vi);var Fi=e(5885);class Ni{static boostrapSessionContainer(t,i,e,s,n,r,o,h,a){const c=oi.h.getSessionChildContainer(t);Ni.bl(c,i,e,s,r,o,h,a);return Ni.Il(c,n)}static bl(t,i,e,s,n,r,o,h){t.register(ti.c.GeneralMetadata,{useValue:Object.assign({},i)}),t.register(ti.c.UserManagerService,{useValue:e}),t.register(ti.c.EventsStorageService,{useValue:n}),t.register(ti.c.GlobalDomUtilsService,{useValue:o}),t.register(ti.c.OmidSettings,{useValue:Object.assign({},r)}),t.register(ti.c.Temp,{useValue:Object.assign({},s)}),t.register(ti.c.ExternalPrebidJSPermutiveConfig,{useValue:(0,G.$K)(h)?h:{}}),t.register(ti.c.GlobalDomUtilsService,{useValue:o})}static Il(t,i){const e=t.resolve(Tt.j),s=t.resolve(Z),n=t.resolve(M.q),r=t.resolve(E);return{trackingResponseService:e,sessionEvents:n,wcagService:t.resolve(Vi),mediaEvents:r,generalRepository:t.resolve(T.B),abtTracker:t.resolve(x),adEvents:t.resolve(y.k),sessionTime:s,protoTrackingCallerService:t.resolve(Lt),trackingService:i?void 0:t.resolve(ri),tempServiceSS:t.resolve(Fi.P)}}}},2239:(t,i,e)=>{"use strict";e.d(i,{B:()=>v});var s={};e.r(s);var n=e(9791),r=e(8659),o=e(6661),h=e(7945),a=e(6027);var c,d=e(4798),l=e(6568),u=e(9490),p=e(9005),f=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o},m=function(t,i){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,i)},g=function(t,i){return function(e,s){i(e,s,t)}};let v=class{constructor(t){this.Sl=t,this.Al={},this._l={height:0,width:0},this.Tl=!1,this.kl=!1,this.Cl=!1,this.El=!1,this.Ml=!1,this.Ll=l.e.Unknown,this.Bl=u.Ez.StoppedState,this.Rl=p.Q.Unknown,this.Ol=1===(0,n.Vm)([99,1])}get trackingRequestMeta(){return{userId:this.userId,playerId:this.playerId,geo:this.geoLocation,browser:this.browser,version:h.g.version,sessionId:this.sessionId,clientAb0:a.e.clientAb0,clientAb1:a.e.clientAb1,serverAb0:a.e.serverAb0,serverAb1:a.e.serverAb1,pageUrl:this.pageUrl,bundleId:this.bundleId,customParam1:this.customParam1,customParam2:this.customParam2,customParam3:this.customParam3,customParam4:this.customParam4,customParam5:this.customParam5,bundleAbId:this.bundleAbId,bundlePart:this.bundlePart,abTestId:this.abTestId,shouldTrackAllRequests:this.Ol,implementationType:this.implementationType,isPageInFocus:this.isPageInFocus}}get canTrackAllRequests(){return this.Ol}get implementationType(){return this.Sl.implementationType}get playerId(){return this.Sl.playerId}get geoLocation(){return this.Sl.geoLocation}get browser(){return this.Sl.browser}get sessionId(){return this.Sl.sessionId}get pageUrl(){return this.Sl.pageUrl}get bundleId(){return this.Sl.bundleId}get bundleAbId(){return this.Sl.bundleAbId}get bundlePart(){return this.Sl.bundlePart}get customParam1(){return this.Sl.customParam1}get customParam2(){return this.Sl.customParam2}get customParam3(){return this.Sl.customParam3}get customParam4(){return this.Sl.customParam4}get customParam5(){return this.Sl.customParam5}get abTestId(){return this.Sl.abTestId}get isExplorationMode(){return this.Sl.isExplorationMode}get lineItemAbTestInformation(){return this.Sl.lineItemAbTestInformation}get hasGdprConsentPayload(){return this.Tl}set hasGdprConsentPayload(t){this.Tl=t}get playerDimensions(){return this._l}set playerDimensions(t){this._l=t}get currentMediaMetadata(){return this.Al}set currentMediaMetadata(t){this.Al=t}get isSessionRenderTracked(){return this.Cl}set isSessionRenderTracked(t){this.Cl=t}get isPlayerStartTracked(){return this.kl}set isPlayerStartTracked(t){this.kl=t}get isSessionViewTracked(){return this.El}set isSessionViewTracked(t){this.El=t}get userId(){return this.Sl.userId}set userId(t){this.Sl.userId=t}get isPageInFocus(){return this.Ml}set isPageInFocus(t){this.Ml=t}get iasSegmentCodes(){return this.Sl.iasSegmentCodes}get amazonTamPubId(){return this.Sl.amazonTamPubId}get isInApp(){return(0,d.QM)(this.Sl.bundleId)}get playerType(){return this.Ll}set playerType(t){this.Ll=t}get playerState(){return this.Bl}set playerState(t){this.Bl=t}get playerEnvironment(){return this.Rl}set playerEnvironment(t){this.Rl=t}};v=f([(0,r.b2)(),(0,r.Yn)(r.Fw.ContainerScoped),g(0,(0,r.f3)(o.c.GeneralMetadata)),m("design:paramtypes",["function"==typeof(c=void 0!==s.IGeneralMetadata&&s.IGeneralMetadata)?c:Object])],v)},3432:()=>{},6961:(t,i,e)=>{"use strict";e.d(i,{m:()=>p,D:()=>u});var s=e(8659),n=e(8983),r=e(3020);function o(t){var i;const e=function(t){return t?(0,r.GF)(t)||(0,r.pv)(t,"cnx-submenu-title-option")?e(t.nextElementSibling):t:null},s=null===(i=t.getElementsByClassName("cnx-cm-item--click"))||void 0===i?void 0:i[0],o=e(s);o&&((0,r.cn)(o,n.s6.TabFocus),null==o||o.focus({preventScroll:!0}))}const h=t=>o(t.target);function a(t){t&&(t.dispatchEvent(new MouseEvent("mousedown")),t.dispatchEvent(new MouseEvent("mouseup")))}var c,d=e(5356),l=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o};const u={enter:"Enter",escape:"Escape",tab:"Tab"};let p=c=class{constructor(){this.Dl=void 0,this.Vl=t=>{const i=t.target;switch(t.code){case u.enter:this.Fl(i);break;case u.escape:this.Nl(i);break;case u.tab:this.jl(i,t.shiftKey?"firstChild":"lastChild")}}}start(t){t.classList.contains("cnx-playspace-container")||(this.Dl=t,this.$l(t))}destroy(){var t,i;null===(t=this.Dl)||void 0===t||t.removeEventListener("keydown",this.Vl),null===(i=this.Dl)||void 0===i||i.removeEventListener("keyup",c.Ul)}$l(t){t.addEventListener("keydown",this.Vl),t.addEventListener("keyup",c.Ul)}Nl(t){const i=t.closest(".cnx-menu-popup"),e=this.ql(i);null==e||e.setAttribute("aria-expanded","false"),a(e),null==e||e.focus()}Fl(t){var i;if(!t)return;const e=t.getAttribute("aria-controls");null===(i=this.Dl)||void 0===i||i.addEventListener("cnx-menu-opened",(()=>{var i;const s=null===(i=this.Dl)||void 0===i?void 0:i.querySelector(`[data-id="${e}"]`),a=function(t){return(0,r.pv)(t,n.Ng.SubmenuOption)}(t);!function(t,i=!1){if(!t)return;if(t.removeEventListener("cnx-mod-scrollbar",h),i)return t.addEventListener("cnx-mod-scrollbar",h,{once:!0}),void o(t);const e=t.querySelector(".cnx-cm-items:first-of-type");e&&o(e)}(s,a)}),{once:!0}),function(t){return(0,r.pv)(t,n.p0.CloseButton)}(t)?function(t){t&&t.dispatchEvent(new MouseEvent("click"))}(t):a(t)}jl(t,i){var e;const s=t.closest("[data-id]");if(s&&t===(null===(e=t.parentElement)||void 0===e?void 0:e[i])){const t=this.ql(s);a(t),null==t||t.focus()}this.Dl&&(0,d.mb)(this.Dl)&&(0,r.cn)(this.Dl,n.s6.AdUserInteraction)}ql(t){var i;return null===(i=this.Dl)||void 0===i?void 0:i.querySelector(`[aria-controls="${null==t?void 0:t.getAttribute("data-id")}"]`)}};p.Ul=t=>{const i=t.target;t.code===u.tab&&(0,r.cn)(i,n.s6.TabFocus)},p=c=l([(0,s.b2)(),(0,s.Yn)(s.Fw.ContainerScoped)],p)},9209:(t,i,e)=>{"use strict";var s,n;e.d(i,{Pl:()=>r,Ys:()=>s,d:()=>n}),function(t){t[t.Space=0]="Space",t[t.KeyM=1]="KeyM",t[t.KeyF=2]="KeyF",t[t.KeyC=3]="KeyC",t[t.KeyN=4]="KeyN",t[t.KeyP=5]="KeyP",t[t.ArrowUp=6]="ArrowUp",t[t.ArrowDown=7]="ArrowDown",t[t.ArrowRight=8]="ArrowRight",t[t.ArrowLeft=9]="ArrowLeft",t[t.Digit0=10]="Digit0",t[t.Digit1=11]="Digit1",t[t.Digit2=12]="Digit2",t[t.Digit3=13]="Digit3",t[t.Digit4=14]="Digit4",t[t.Digit5=15]="Digit5",t[t.Digit6=16]="Digit6",t[t.Digit7=17]="Digit7",t[t.Digit8=18]="Digit8",t[t.Digit9=19]="Digit9"}(s||(s={})),function(t){t[t.togglePlay=0]="togglePlay",t[t.toggleMute=1]="toggleMute",t[t.toggleFullscreen=2]="toggleFullscreen",t[t.toggleCaptions=3]="toggleCaptions",t[t.increaseVolume=4]="increaseVolume",t[t.decreaseVolume=5]="decreaseVolume",t[t.seekForward=6]="seekForward",t[t.seekBackward=7]="seekBackward",t[t.seek0Percent=8]="seek0Percent",t[t.seek10Percent=9]="seek10Percent",t[t.seek20Percent=10]="seek20Percent",t[t.seek30Percent=11]="seek30Percent",t[t.seek40Percent=12]="seek40Percent",t[t.seek50Percent=13]="seek50Percent",t[t.seek60Percent=14]="seek60Percent",t[t.seek70Percent=15]="seek70Percent",t[t.seek80Percent=16]="seek80Percent",t[t.seek90Percent=17]="seek90Percent",t[t.nextVideo=18]="nextVideo",t[t.previousVideo=19]="previousVideo"}(n||(n={}));const r={[s.Space]:n.togglePlay,[s.KeyM]:n.toggleMute,[s.KeyF]:n.toggleFullscreen,[s.KeyC]:n.toggleCaptions,[s.ArrowUp]:n.increaseVolume,[s.ArrowDown]:n.decreaseVolume,[s.ArrowRight]:n.seekForward,[s.ArrowLeft]:n.seekBackward,[s.Digit0]:n.seek0Percent,[s.Digit1]:n.seek10Percent,[s.Digit2]:n.seek20Percent,[s.Digit3]:n.seek30Percent,[s.Digit4]:n.seek40Percent,[s.Digit5]:n.seek50Percent,[s.Digit6]:n.seek60Percent,[s.Digit7]:n.seek70Percent,[s.Digit8]:n.seek80Percent,[s.Digit9]:n.seek90Percent,[s.KeyN]:n.nextVideo,[s.KeyP]:n.previousVideo}},9005:(t,i,e)=>{"use strict";var s;e.d(i,{Q:()=>s}),function(t){t[t.Unknown=0]="Unknown",t[t.InAppSdk=1]="InAppSdk",t[t.InAppReactNative=2]="InAppReactNative",t[t.InAppFlutter=3]="InAppFlutter",t[t.InAppGam=4]="InAppGam",t[t.InAppWebview=5]="InAppWebview",t[t.WebAmp=6]="WebAmp",t[t.Web=7]="Web"}(s||(s={}))},6568:(t,i,e)=>{"use strict";var s;e.d(i,{e:()=>s}),function(t){t[t.Unknown=0]="Unknown",t[t.Video=1]="Video",t[t.Outstream=2]="Outstream",t[t.Live=3]="Live",t[t.Story=4]="Story"}(s||(s={}))},8858:()=>{},6565:(t,i,e)=>{"use strict";e.d(i,{q:()=>h});var s=e(6515),n=e(6716),r=e(8659),o=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o};let h=class{constructor(){this.sessionPlaybackChanged=new s.X({isPlaying:!1}),this.sessionViewabilityChanged=new s.X({isInView:!1}),this.sessionTimeElapsed=new n.x,this.sessionRendered=new n.x,this.sessionView=new n.x,this.sessionAdBlocked=new n.x,this.adOpportunity=new n.x,this.adsEnabled=new n.x,this.contentStart=new n.x}};h=o([(0,r.b2)(),(0,r.Yn)(r.Fw.ContainerScoped)],h)},5885:(t,i,e)=>{"use strict";e.d(i,{P:()=>d});var s={};e.r(s);var n,r=e(6661),o=e(8659),h=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o},a=function(t,i){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,i)},c=function(t,i){return function(e,s){i(e,s,t)}};let d=class{constructor(t){this.Hl=t,this.zl=["www.selection.ca"],this.Wl=["www.dailykos.com","m.dailykos.com"],this.Gl=["www.legacy.com","legacy.com","m.legacy.com"],this.Ql=["www.rd.com"],this.Jl=["www.marriage.com"],this.Yl=["www.budgetyourtrip.com"],this.Kl=0}set adManagerSound(t){this.Kl=t}get adManagerSound(){return this.Kl}isImaTestCaseForSS(){return this.zl.includes(this.Hl.pageDomain)}isDailykosDotComDomain(){return this.Wl.includes(this.Hl.pageDomain)}isLegacyDotComDomain(){return this.Gl.includes(this.Hl.pageDomain)}isRDDotComDomain(){return this.Ql.includes(this.Hl.pageDomain)}isMarriageDotComDomain(){return this.Jl.includes(this.Hl.pageDomain)}isBudgetYourTripDotComDomain(){return this.Yl.includes(this.Hl.pageDomain)}};d=h([(0,o.b2)(),(0,o.Yn)(o.Fw.ContainerScoped),c(0,(0,o.f3)(r.c.Temp)),a("design:paramtypes",["function"==typeof(n=void 0!==s.ITempMetadata&&s.ITempMetadata)?n:Object])],d)},3816:(t,i,e)=>{"use strict";e.d(i,{d:()=>s});class s{static getProtoDiscount(t){return{id:t.id,rate:t.rate}}static fromProtoDiscount(t){return{id:t.id,rate:t.rate}}}},3802:(t,i,e)=>{"use strict";e.d(i,{Ti:()=>d,EN:()=>o,wE:()=>l,W1:()=>u,p:()=>c,yz:()=>h,XE:()=>a});var s=e(9361),n=e(202),r=e(289);class o{static getProtoImplementationType(t){return{[s.Vx.Amp]:r.ProtoImplementationType.Amp,[s.Vx.Web]:r.ProtoImplementationType.Web}[t]}static fromProtoGetImplementationType(t){return{[r.ProtoImplementationType.Amp]:s.Vx.Amp,[r.ProtoImplementationType.Web]:s.Vx.Web}[t]}static getProtoDeviceType(t){return{[s.VB.Desktop]:r.ProtoDeviceType.Desktop,[s.VB.Smartphone]:r.ProtoDeviceType.Smartphone,[s.VB.Tablet]:r.ProtoDeviceType.Tablet,[s.VB.GameConsole]:r.ProtoDeviceType.GameConsole,[s.VB.PDA]:r.ProtoDeviceType.PDA,[s.VB.SmartTV]:r.ProtoDeviceType.SmartTV,[s.VB.Unrecognized]:r.ProtoDeviceType.Unrecognized,[s.VB.WearableComputer]:r.ProtoDeviceType.WearableComputer}[t]}static fromProtoGetDeviceType(t){return{[r.ProtoDeviceType.Desktop]:s.VB.Desktop,[r.ProtoDeviceType.Smartphone]:s.VB.Smartphone,[r.ProtoDeviceType.Tablet]:s.VB.Tablet,[r.ProtoDeviceType.GameConsole]:s.VB.GameConsole,[r.ProtoDeviceType.PDA]:s.VB.PDA,[r.ProtoDeviceType.SmartTV]:s.VB.SmartTV,[r.ProtoDeviceType.Unrecognized]:s.VB.Unrecognized,[r.ProtoDeviceType.WearableComputer]:s.VB.WearableComputer}[t]}static getProtoAdBlockerDetectionType(t){return{[s.ev.Banner]:r.ProtoAdBlockDetectionTypeEnum.Banner,[s.ev.Network]:r.ProtoAdBlockDetectionTypeEnum.Network}[t]}static fromProtoAdBlockerDetectionType(t){return{[r.ProtoAdBlockDetectionTypeEnum.Banner]:s.ev.Banner,[r.ProtoAdBlockDetectionTypeEnum.Network]:s.ev.Network}[t]}static getProtoAdBreakType(t){return{[s.xX.None]:r.ProtoAdBreakTypeEnum.None,[s.xX.PreRoll]:r.ProtoAdBreakTypeEnum.PreRoll,[s.xX.MidRoll]:r.ProtoAdBreakTypeEnum.MidRoll,[s.xX.PostRoll]:r.ProtoAdBreakTypeEnum.PostRoll}[t]||r.ProtoAdBreakTypeEnum.None}static fromProtoAdBreakType(t){return{[r.ProtoAdBreakTypeEnum.None]:s.xX.None,[r.ProtoAdBreakTypeEnum.PreRoll]:s.xX.PreRoll,[r.ProtoAdBreakTypeEnum.MidRoll]:s.xX.MidRoll,[r.ProtoAdBreakTypeEnum.PostRoll]:s.xX.PostRoll}[t]||s.xX.None}static getProtoAdClickType(t){return{[s.VE.AdClick]:r.ProtoAdClickTypeEnum.AdClick,[s.VE.AdClickThrough]:r.ProtoAdClickTypeEnum.AdClickThrough,[s.VE.AdSkipClick]:r.ProtoAdClickTypeEnum.AdSkipClick,[s.VE.AdUserClose]:r.ProtoAdClickTypeEnum.AdUserClose,[s.VE.ExitFullScreenClick]:r.ProtoAdClickTypeEnum.ExitFullScreenClick,[s.VE.FullScreenClick]:r.ProtoAdClickTypeEnum.FullScreenClick,[s.VE.MuteClick]:r.ProtoAdClickTypeEnum.MuteClick,[s.VE.PauseClick]:r.ProtoAdClickTypeEnum.PauseClick,[s.VE.PlayClick]:r.ProtoAdClickTypeEnum.PlayClick,[s.VE.UnmuteClick]:r.ProtoAdClickTypeEnum.UnmuteClick,[s.VE.VolumeClick]:r.ProtoAdClickTypeEnum.VolumeClick}[t]}static fromProtoAdClickType(t){return{[r.ProtoAdClickTypeEnum.AdClick]:s.VE.AdClick,[r.ProtoAdClickTypeEnum.AdClickThrough]:s.VE.AdClickThrough,[r.ProtoAdClickTypeEnum.AdSkipClick]:s.VE.AdSkipClick,[r.ProtoAdClickTypeEnum.AdUserClose]:s.VE.AdUserClose,[r.ProtoAdClickTypeEnum.ExitFullScreenClick]:s.VE.ExitFullScreenClick,[r.ProtoAdClickTypeEnum.FullScreenClick]:s.VE.FullScreenClick,[r.ProtoAdClickTypeEnum.MuteClick]:s.VE.MuteClick,[r.ProtoAdClickTypeEnum.PauseClick]:s.VE.PauseClick,[r.ProtoAdClickTypeEnum.PlayClick]:s.VE.PlayClick,[r.ProtoAdClickTypeEnum.UnmuteClick]:s.VE.UnmuteClick,[r.ProtoAdClickTypeEnum.VolumeClick]:s.VE.VolumeClick}[t]}static getProtoAdSourceType(t){return{[s.Px.AOL]:r.ProtoAdsourceTypeEnum.AOL,[s.Px.CnxMedia]:r.ProtoAdsourceTypeEnum.CnxMedia,[s.Px.Ima]:r.ProtoAdsourceTypeEnum.Ima,[s.Px.Jw]:r.ProtoAdsourceTypeEnum.Jw,[s.Px.Unknown]:r.ProtoAdsourceTypeEnum.Unknown,[s.Px.VastMedia]:r.ProtoAdsourceTypeEnum.VastMedia,[s.Px.Vpaid]:r.ProtoAdsourceTypeEnum.Vpaid}[t]}static fromProtoAdSourceType(t){return{[r.ProtoAdsourceTypeEnum.AOL]:s.Px.AOL,[r.ProtoAdsourceTypeEnum.CnxMedia]:s.Px.CnxMedia,[r.ProtoAdsourceTypeEnum.Ima]:s.Px.Ima,[r.ProtoAdsourceTypeEnum.Jw]:s.Px.Jw,[r.ProtoAdsourceTypeEnum.Unknown]:s.Px.Unknown,[r.ProtoAdsourceTypeEnum.VastMedia]:s.Px.VastMedia,[r.ProtoAdsourceTypeEnum.Vpaid]:s.Px.Vpaid}[t]}static getProtoAuctionLossReason(t){return{[s.AT.AdOpportunityEnd]:r.ProtoAuctionLossReasonEnum.AdOpportunityEnd,[s.AT.TargetingMismatch]:r.ProtoAuctionLossReasonEnum.TargetingMismatch,[s.AT.CompetitorPriority]:r.ProtoAuctionLossReasonEnum.CompetitorPriority}[t]}static fromProtoAuctionLossReason(t){return{[r.ProtoAuctionLossReasonEnum.AdOpportunityEnd]:s.AT.AdOpportunityEnd,[r.ProtoAuctionLossReasonEnum.TargetingMismatch]:s.AT.TargetingMismatch,[r.ProtoAuctionLossReasonEnum.CompetitorPriority]:s.AT.CompetitorPriority}[t]}static getProtoAuctionPostbidReason(t){return{[s.MF.CreativeError]:r.ProtoAuctionPostbidReasonEnum.CreativeError,[s.MF.PlayerError]:r.ProtoAuctionPostbidReasonEnum.PlayerError,[s.MF.SDKFailure]:r.ProtoAuctionPostbidReasonEnum.SDKFailure,[s.MF.TargetingMismatch]:r.ProtoAuctionPostbidReasonEnum.TargetingMismatch,[s.MF.UnsupportedMedia]:r.ProtoAuctionPostbidReasonEnum.UnsupportedMedia}[t]}static fromProtoAuctionPostbidReason(t){return{[r.ProtoAuctionPostbidReasonEnum.CreativeError]:s.MF.CreativeError,[r.ProtoAuctionPostbidReasonEnum.PlayerError]:s.MF.PlayerError,[r.ProtoAuctionPostbidReasonEnum.SDKFailure]:s.MF.SDKFailure,[r.ProtoAuctionPostbidReasonEnum.TargetingMismatch]:s.MF.TargetingMismatch,[r.ProtoAuctionPostbidReasonEnum.UnsupportedMedia]:s.MF.UnsupportedMedia}[t]}static getProtoFloorPriceBypassReason(t){return{[s.N0.BidInHand]:s.N0.BidInHand,[s.N0.FixedCpm]:s.N0.FixedCpm,[s.N0.MaxBidPrice]:s.N0.MaxBidPrice,[s.N0.MinCpm]:s.N0.MinCpm,[s.N0.NoPredictionFound]:s.N0.NoPredictionFound,[s.N0.StaticFactorUsed]:s.N0.StaticFactorUsed,[s.N0.VideoOrBannerMin]:s.N0.VideoOrBannerMin}[t]}static fromProtoFloorPriceBypassReason(t){return{[s.N0.BidInHand]:s.N0.BidInHand,[s.N0.FixedCpm]:s.N0.FixedCpm,[s.N0.MaxBidPrice]:s.N0.MaxBidPrice,[s.N0.MinCpm]:s.N0.MinCpm,[s.N0.NoPredictionFound]:s.N0.NoPredictionFound,[s.N0.StaticFactorUsed]:s.N0.StaticFactorUsed,[s.N0.VideoOrBannerMin]:s.N0.VideoOrBannerMin}[t]}static getProtoGDPRConsentMode(t){return{[s.q1.Unknown]:r.ProtoGdprConsentModeEnum.Unknown,[s.q1.NoCmp]:r.ProtoGdprConsentModeEnum.NoCmp,[s.q1.NoConsent]:r.ProtoGdprConsentModeEnum.NoConsent,[s.q1.NotAllDemandConsent]:r.ProtoGdprConsentModeEnum.NotAllDemandConsent,[s.q1.NoConnatixConsent]:r.ProtoGdprConsentModeEnum.NoConnatixConsent,[s.q1.AllGood]:r.ProtoGdprConsentModeEnum.AllGood}[t]}static fromProtoGDPRConsentMode(t){return{[r.ProtoGdprConsentModeEnum.Unknown]:s.q1.Unknown,[r.ProtoGdprConsentModeEnum.NoCmp]:s.q1.NoCmp,[r.ProtoGdprConsentModeEnum.NoConsent]:s.q1.NoConsent,[r.ProtoGdprConsentModeEnum.NotAllDemandConsent]:s.q1.NotAllDemandConsent,[r.ProtoGdprConsentModeEnum.NoConnatixConsent]:s.q1.NoConnatixConsent,[r.ProtoGdprConsentModeEnum.AllGood]:s.q1.AllGood}[t]}static getProtoHeavyAdType(t){return{[s.Yc.Global]:r.ProtoHeavyAdBlockTypeEnum.Global,[s.Yc.OverlayIframe]:r.ProtoHeavyAdBlockTypeEnum.OverlayIframe,[s.Yc.Script]:r.ProtoHeavyAdBlockTypeEnum.Script,[s.Yc.VPAIDIframe]:r.ProtoHeavyAdBlockTypeEnum.VpaidIframe}[t]}static fromProtoHeavyAdType(t){return{[r.ProtoHeavyAdBlockTypeEnum.Global]:s.Yc.Global,[r.ProtoHeavyAdBlockTypeEnum.OverlayIframe]:s.Yc.OverlayIframe,[r.ProtoHeavyAdBlockTypeEnum.Script]:s.Yc.Script,[r.ProtoHeavyAdBlockTypeEnum.VpaidIframe]:s.Yc.VPAIDIframe}[t]}static getProtoInternalAuctionDemandType(t){return{[s.AM.None]:r.ProtoDemandTypeEnum.None,[s.AM.PMP]:r.ProtoDemandTypeEnum.PMP,[s.AM.OpenMarket]:r.ProtoDemandTypeEnum.OpenMarket,[s.AM.SelfServed]:r.ProtoDemandTypeEnum.SelfServed}[t]}static fromProtoInternalAuctionDemandType(t){return{[r.ProtoDemandTypeEnum.None]:s.AM.None,[r.ProtoDemandTypeEnum.PMP]:s.AM.PMP,[r.ProtoDemandTypeEnum.OpenMarket]:s.AM.OpenMarket,[r.ProtoDemandTypeEnum.SelfServed]:s.AM.SelfServed}[t]}static getProtoLineItemAbTest(t){return{[s.KY.CaseA]:r.ProtoLineItemAbTestCase.CaseA,[s.KY.CaseB]:r.ProtoLineItemAbTestCase.CaseB}[t]}static fromProtoLineItemAbTest(t){return{[r.ProtoLineItemAbTestCase.CaseA]:s.KY.CaseA,[r.ProtoLineItemAbTestCase.CaseB]:s.KY.CaseB}[t]}static getProtoMediaClickType(t){return{[s.$u.Click]:r.ProtoMediaClickTypeEnum.Click,[s.$u.CloseClick]:r.ProtoMediaClickTypeEnum.CloseClick,[s.$u.FullScreenClick]:r.ProtoMediaClickTypeEnum.FullScreenClick,[s.$u.ExitFullScreenClick]:r.ProtoMediaClickTypeEnum.ExitFullScreenClick,[s.$u.GalleryClick]:r.ProtoMediaClickTypeEnum.GalleryClick,[s.$u.MuteClick]:r.ProtoMediaClickTypeEnum.MuteClick,[s.$u.NextClick]:r.ProtoMediaClickTypeEnum.NextClick,[s.$u.PauseClick]:r.ProtoMediaClickTypeEnum.PauseClick,[s.$u.PlayClick]:r.ProtoMediaClickTypeEnum.PlayClick,[s.$u.PreviousClick]:r.ProtoMediaClickTypeEnum.PreviousClick,[s.$u.SubtitleClick]:r.ProtoMediaClickTypeEnum.SubtitleClick,[s.$u.UnmuteClick]:r.ProtoMediaClickTypeEnum.UnmuteClick,[s.$u.UrlClick]:r.ProtoMediaClickTypeEnum.UrlClick,[s.$u.VolumeClick]:r.ProtoMediaClickTypeEnum.VolumeClick}[t]}static fromProtoGetMediaClickType(t){return{[r.ProtoMediaClickTypeEnum.Click]:s.$u.Click,[r.ProtoMediaClickTypeEnum.CloseClick]:s.$u.CloseClick,[r.ProtoMediaClickTypeEnum.FullScreenClick]:s.$u.FullScreenClick,[r.ProtoMediaClickTypeEnum.ExitFullScreenClick]:s.$u.ExitFullScreenClick,[r.ProtoMediaClickTypeEnum.GalleryClick]:s.$u.GalleryClick,[r.ProtoMediaClickTypeEnum.MuteClick]:s.$u.MuteClick,[r.ProtoMediaClickTypeEnum.NextClick]:s.$u.NextClick,[r.ProtoMediaClickTypeEnum.PauseClick]:s.$u.PauseClick,[r.ProtoMediaClickTypeEnum.PlayClick]:s.$u.PlayClick,[r.ProtoMediaClickTypeEnum.PreviousClick]:s.$u.PreviousClick,[r.ProtoMediaClickTypeEnum.SubtitleClick]:s.$u.SubtitleClick,[r.ProtoMediaClickTypeEnum.UnmuteClick]:s.$u.UnmuteClick,[r.ProtoMediaClickTypeEnum.UrlClick]:s.$u.UrlClick,[r.ProtoMediaClickTypeEnum.VolumeClick]:s.$u.VolumeClick}[t]}static getProtoMediaType(t){return{[s.L5.Image]:r.ProtoMediaTypeEnum.Image,[s.L5.Video]:r.ProtoMediaTypeEnum.Video}[t]}static fromProtoGetMediaType(t){return{[r.ProtoMediaTypeEnum.Image]:s.L5.Image,[r.ProtoMediaTypeEnum.Video]:s.L5.Video}[t]}static getProtoPrebidReason(t){return{[s._Z.RequestException]:r.ConnatixNoBidReasonEnum.RequestException,[s._Z.Timeout]:r.ConnatixNoBidReasonEnum.Timeout,[s._Z.EmptyResponse]:r.ConnatixNoBidReasonEnum.EmptyResponse,[s._Z.InvalidResponse]:r.ConnatixNoBidReasonEnum.InvalidResponse,[s._Z.NoBid]:r.ConnatixNoBidReasonEnum.NoBid,[s._Z.BidBelowFloor]:r.ConnatixNoBidReasonEnum.BidBelowFloor,[s._Z.DealIdMismatch]:r.ConnatixNoBidReasonEnum.DealIdMismatch,[s._Z.CsInvalidResponse]:r.ConnatixNoBidReasonEnum.CsInvalidResponse,[s._Z.CsRequestException]:r.ConnatixNoBidReasonEnum.CsRequestException,[s._Z.CsEmptyResponse]:r.ConnatixNoBidReasonEnum.CsEmptyResponse,[s._Z.NoLibInPage]:r.ConnatixNoBidReasonEnum.NoLibInPage,[s._Z.BidIsNotTargetingAllowedEver]:r.ConnatixNoBidReasonEnum.BidIsNotTargetingAllowedEver,[s._Z.VastVersionNotSupported]:r.ConnatixNoBidReasonEnum.VastVersionNotSupported}[t]}static fromProtoPrebidReason(t){return{[r.ConnatixNoBidReasonEnum.RequestException]:s._Z.RequestException,[r.ConnatixNoBidReasonEnum.Timeout]:s._Z.Timeout,[r.ConnatixNoBidReasonEnum.EmptyResponse]:s._Z.EmptyResponse,[r.ConnatixNoBidReasonEnum.InvalidResponse]:s._Z.InvalidResponse,[r.ConnatixNoBidReasonEnum.NoBid]:s._Z.NoBid,[r.ConnatixNoBidReasonEnum.BidBelowFloor]:s._Z.BidBelowFloor,[r.ConnatixNoBidReasonEnum.DealIdMismatch]:s._Z.DealIdMismatch,[r.ConnatixNoBidReasonEnum.CsInvalidResponse]:s._Z.CsInvalidResponse,[r.ConnatixNoBidReasonEnum.CsRequestException]:s._Z.CsRequestException,[r.ConnatixNoBidReasonEnum.CsEmptyResponse]:s._Z.CsEmptyResponse,[r.ConnatixNoBidReasonEnum.NoLibInPage]:s._Z.NoLibInPage,[r.ConnatixNoBidReasonEnum.BidIsNotTargetingAllowedEver]:s._Z.BidIsNotTargetingAllowedEver,[r.ConnatixNoBidReasonEnum.VastVersionNotSupported]:s._Z.VastVersionNotSupported}[t]}static getProtoPrebidPartnerReason(t){return{[s.XD.Unknown]:r.PartnerNoBidReasonEnum.Unknown,[s.XD.TechnicalError]:r.PartnerNoBidReasonEnum.TechnicalError,[s.XD.InvalidRequest]:r.PartnerNoBidReasonEnum.InvalidRequest,[s.XD.KnownWebSpider]:r.PartnerNoBidReasonEnum.KnownWebSpider,[s.XD.SuspectedNonHumanTraffic]:r.PartnerNoBidReasonEnum.SuspectedNonHumanTraffic,[s.XD.CloudIP]:r.PartnerNoBidReasonEnum.CloudIP,[s.XD.UnsupportedDevice]:r.PartnerNoBidReasonEnum.UnsupportedDevice,[s.XD.BlockedPublisher]:r.PartnerNoBidReasonEnum.BlockedPublisher,[s.XD.UnmatchedUser]:r.PartnerNoBidReasonEnum.UnmatchedUser,[s.XD.DailyDomainCapMet]:r.PartnerNoBidReasonEnum.DailyDomainCapMet,[s.XD.DailyReaderCapMet]:r.PartnerNoBidReasonEnum.DailyReaderCapMet}[t]}static fromProtoPrebidPartnerReason(t){return{[r.PartnerNoBidReasonEnum.Unknown]:s.XD.Unknown,[r.PartnerNoBidReasonEnum.TechnicalError]:s.XD.TechnicalError,[r.PartnerNoBidReasonEnum.InvalidRequest]:s.XD.InvalidRequest,[r.PartnerNoBidReasonEnum.KnownWebSpider]:s.XD.KnownWebSpider,[r.PartnerNoBidReasonEnum.SuspectedNonHumanTraffic]:s.XD.SuspectedNonHumanTraffic,[r.PartnerNoBidReasonEnum.CloudIP]:s.XD.CloudIP,[r.PartnerNoBidReasonEnum.UnsupportedDevice]:s.XD.UnsupportedDevice,[r.PartnerNoBidReasonEnum.BlockedPublisher]:s.XD.BlockedPublisher,[r.PartnerNoBidReasonEnum.UnmatchedUser]:s.XD.UnmatchedUser,[r.PartnerNoBidReasonEnum.DailyDomainCapMet]:s.XD.DailyDomainCapMet,[r.PartnerNoBidReasonEnum.DailyReaderCapMet]:s.XD.DailyReaderCapMet}[t]}static getProtoQuartile(t){return{[s.yU.Start]:r.ProtoQuartilesEnum.Start,[s.yU.First]:r.ProtoQuartilesEnum.First,[s.yU.Second]:r.ProtoQuartilesEnum.Second,[s.yU.Third]:r.ProtoQuartilesEnum.Third,[s.yU.Fourth]:r.ProtoQuartilesEnum.Fourth}[t]}static fromProtoGetQuartile(t){return{[r.ProtoQuartilesEnum.Start]:s.yU.Start,[r.ProtoQuartilesEnum.First]:s.yU.First,[r.ProtoQuartilesEnum.Second]:s.yU.Second,[r.ProtoQuartilesEnum.Third]:s.yU.Third,[r.ProtoQuartilesEnum.Fourth]:s.yU.Fourth}[t]}static getProtoLiveRamp(t){return{[n.f.None]:r.ProtoLiveRampEnum.None,[n.f.ATS]:r.ProtoLiveRampEnum.ATS,[n.f.NonATS]:r.ProtoLiveRampEnum.NonATS}[t]}static fromProtoLiveRamp(t){return{[r.ProtoLiveRampEnum.None]:n.f.None,[r.ProtoLiveRampEnum.ATS]:n.f.ATS,[r.ProtoLiveRampEnum.NonATS]:n.f.NonATS}[t]}}class h{static getProtoTrackingMetadata(t){const{buildNumber:i,buildAbPart:e,buildAbId:s,customParam1:n,customParam2:r,customParam3:a,customParam4:c,customParam5:d,clientAb0:l,clientAb1:u,serverAb0:p,serverAb1:f,playerId:m,sessionId:g,pageUrl:v,userId:y,shouldTrackAllRequests:b,isPageInFocus:I,bundleId:w,abTestId:S,implementationType:P,browser:A,geo:_}=t;return{geo:_?h.Zl(_):void 0,browser:A?h.tu(A):void 0,implementationType:P?o.getProtoImplementationType(P):void 0,customParam1:n,customParam2:r,customParam3:a,customParam4:c,customParam5:d,clientAb0:l,clientAb1:u,serverAb0:p,serverAb1:f,playerId:m,sessionId:g,pageUrl:v,userId:y,isPageInFocus:I,version:i,bundleId:w,bundleAbId:s,bundlePart:e,abTestId:S,shouldTrackAllRequests:b}}static fromProtoGetTrackingMetadata(t){const{bundleAbId:i,version:e,bundlePart:s,customParam1:n,customParam2:r,customParam3:a,customParam4:c,customParam5:d,clientAb0:l,clientAb1:u,serverAb0:p,serverAb1:f,playerId:m,sessionId:g,pageUrl:v,userId:y,shouldTrackAllRequests:b,isPageInFocus:I,bundleId:w,abTestId:S,implementationType:P,browser:A,geo:_}=t;return{geo:_?h.eu(_):void 0,browser:A?h.su(A):void 0,implementationType:o.fromProtoGetImplementationType(P),customParam1:n,customParam2:r,customParam3:a,customParam4:c,customParam5:d,clientAb0:l,clientAb1:u,serverAb0:p,serverAb1:f,playerId:m,sessionId:g,pageUrl:v,userId:y,isPageInFocus:I,buildNumber:e,bundleId:w,buildAbId:i,buildAbPart:s,abTestId:S,shouldTrackAllRequests:b}}static tu(t){const{osCode:i,browserVersion:e,browserType:s,deviceType:n}=t;return{osCode:i,browserVersion:e,browserType:s,device:o.getProtoDeviceType(n)}}static su(t){const{osCode:i,browserVersion:e,browserType:s,device:n}=t;return{osCode:i,browserVersion:e,browserType:s,deviceType:o.fromProtoGetDeviceType(n)}}static Zl(t){const{latitude:i,longitude:e,zipCode:s,cityId:n,countryGeoId:r,ip:o,subdivisionId:h,dmaId:a}=t;return{cityId:n,countryGeoId:r,ip:o,lat:i,lon:e,subdivisionId:h,zipcode:s,dmaId:a}}static eu(t){const{lat:i,lon:e,zipcode:s,cityId:n,countryGeoId:r,ip:o,subdivisionId:h,dmaId:a}=t;return{cityId:n,countryGeoId:r,ip:o,latitude:i,longitude:e,subdivisionId:h,zipCode:s,dmaId:a}}}class a{static getProtoSentimentAnalysis(t){return{negative:t.negative,neutral:t.neutral,positive:t.positive}}static fromProtoGetSentimentAnalysis(t){return{negative:t.negative,neutral:t.neutral,positive:t.positive}}}class c{static getProtoLineItemAbTest(t){return{guid:t.id,lineItemAbTestCase:o.getProtoLineItemAbTest(t.lineItemAbTestCase)}}static fromProtoLineItemAbTestFromProto(t){return{id:t.guid,lineItemAbTestCase:o.fromProtoLineItemAbTest(t.lineItemAbTestCase)}}}class d{static getProtoAuctionInformation(t){const{bidDensity:i,highestObfuscatedBidPrice:e,secondHighestObfuscatedBidPrice:s}=t;return{bidDensity:i,highestObfuscatedBidPrice:e,secondHighestObfuscatedBidPrice:s}}static fromProtoAuctionInformation(t){const{bidDensity:i,highestObfuscatedBidPrice:e,secondHighestObfuscatedBidPrice:s}=t;return{bidDensity:i,highestObfuscatedBidPrice:e,secondHighestObfuscatedBidPrice:s}}}class l{static getProtoFloorPriceInformation(t){const{floorPrices:i,floorPriceIndexUsed:e,floorPriceFactorBypassReason:s,adxPredictedFloorPrice:n}=t;return{adxPredictedFloorPrice:n,floorPrices:i,floorPriceIndexUsed:e,floorPriceBypassReason:s?o.getProtoFloorPriceBypassReason(s):void 0}}static fromProtoFloorPriceInformation(t){const{floorPrices:i,floorPriceIndexUsed:e,floorPriceBypassReason:s,adxPredictedFloorPrice:n}=t;return{adxPredictedFloorPrice:n,floorPrices:i,floorPriceIndexUsed:e,floorPriceFactorBypassReason:s?o.fromProtoFloorPriceBypassReason(s):void 0}}}class u{static getProtoInternalAuction(t){const{winnerDemandType:i,firstLoser:e,firstOpenMarketLoser:s}=t;return{winnerDemandType:o.getProtoInternalAuctionDemandType(i),firstLoser:e?u.getProtoInternalAuctionBid(e):void 0,firstOpenMarketLoser:s?u.getProtoInternalAuctionBid(s):void 0}}static fromProtoInternalAuction(t){const{winnerDemandType:i,firstLoser:e,firstOpenMarketLoser:s}=t;return{winnerDemandType:o.fromProtoInternalAuctionDemandType(i),firstLoser:e?u.fromProtoInternalAuctionBid(e):void 0,firstOpenMarketLoser:s?u.fromProtoInternalAuctionBid(s):void 0}}static getProtoInternalAuctionBid(t){const{advertiserLineItemId:i,customClientPrice:e,encryptedPrice:s,demandType:n,adDuration:r}=t;return{demandType:o.getProtoInternalAuctionDemandType(n),advertiserLineItemId:i,customClientPrice:e,encryptedPrice:s,adDuration:r}}static fromProtoInternalAuctionBid(t){const{advertiserLineItemId:i,customClientPrice:e,encryptedPrice:s,demandType:n,adDuration:r}=t;return{demandType:o.fromProtoInternalAuctionDemandType(n),advertiserLineItemId:i,customClientPrice:e,encryptedPrice:s,adDuration:r}}}},6286:(t,i,e)=>{"use strict";e.d(i,{j:()=>a});var s=e(5650),n=e(4798),r=e(6716),o=e(8659),h=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o};let a=class{constructor(){this.ru=new r.x,this.ou=new r.x,this.hu=new r.x}get onLineItemPlatformCapped(){return this.ru.asObservable()}get onImpressionRevenue(){return this.ou.asObservable()}get onLineItemViewabilityChange(){return this.hu.asObservable()}onResponseReceived(t,i){const{platformCappedLineItemIdList:e,adServerLineItemName:s,impressionRevenue:n,isViewabilityRestricted:r}=t;this.au(e),this.cu(n,s),this.du(i,r)}au(t){(0,n.$K)(t)&&(0,s.BZ)(t)&&this.ru.next(t)}cu(t,i){(0,n.r)(t)&&(0,n.QM)(i)&&this.ou.next({impressionRevenue:t,adServerLineItemName:i})}du(t,i){(0,n.QM)(t)&&(0,n.$K)(i)&&this.hu.next([t,i])}};a=h([(0,o.b2)(),(0,o.Yn)(o.Fw.ContainerScoped)],a)},202:(t,i,e)=>{"use strict";var s;e.d(i,{f:()=>s}),function(t){t[t.None=0]="None",t[t.ATS=1]="ATS",t[t.NonATS=2]="NonATS"}(s||(s={}))},4967:(t,i,e)=>{"use strict";var s;e.d(i,{$:()=>s}),function(t){t[t.Click=0]="Click",t[t.UrlClick=1]="UrlClick",t[t.VolumeClick=2]="VolumeClick",t[t.PlayClick=3]="PlayClick",t[t.PauseClick=4]="PauseClick",t[t.NextClick=5]="NextClick",t[t.PreviousClick=6]="PreviousClick",t[t.MuteClick=7]="MuteClick",t[t.UnmuteClick=8]="UnmuteClick",t[t.CloseClick=9]="CloseClick",t[t.GalleryClick=11]="GalleryClick",t[t.SubtitleClick=12]="SubtitleClick",t[t.FullScreenClick=13]="FullScreenClick",t[t.ExitFullScreenClick=14]="ExitFullScreenClick"}(s||(s={}))},5692:(t,i,e)=>{"use strict";var s;e.d(i,{y:()=>s}),function(t){t[t.Start=0]="Start",t[t.First=1]="First",t[t.Second=2]="Second",t[t.Third=3]="Third",t[t.Fourth=4]="Fourth"}(s||(s={}))},9361:(t,i,e)=>{"use strict";var s,n,r,o;e.d(i,{ev:()=>r,xX:()=>c,VE:()=>y,Px:()=>a,AT:()=>g,MF:()=>m,VB:()=>s,N0:()=>f,q1:()=>d,Yc:()=>o,Vx:()=>n,AM:()=>v,KY:()=>l,$u:()=>I.$,L5:()=>h,XD:()=>p,_Z:()=>u,yU:()=>b.y}),function(t){t[t.Desktop=0]="Desktop",t[t.Smartphone=1]="Smartphone",t[t.Tablet=2]="Tablet",t[t.GameConsole=3]="GameConsole",t[t.SmartTV=4]="SmartTV",t[t.WearableComputer=5]="WearableComputer",t[t.PDA=6]="PDA",t[t.Unrecognized=7]="Unrecognized"}(s||(s={})),function(t){t[t.Web=0]="Web",t[t.Amp=1]="Amp"}(n||(n={})),function(t){t[t.Banner=0]="Banner",t[t.Network=1]="Network"}(r||(r={})),function(t){t[t.Global=0]="Global",t[t.Script=1]="Script",t[t.VPAIDIframe=2]="VPAIDIframe",t[t.OverlayIframe=3]="OverlayIframe"}(o||(o={}));var h,a,c,d,l,u,p,f,m,g,v,y,b=e(5692),I=e(4967);!function(t){t[t.Image=0]="Image",t[t.Video=1]="Video"}(h||(h={})),function(t){t[t.Unknown=0]="Unknown",t[t.Vpaid=1]="Vpaid",t[t.VastMedia=2]="VastMedia",t[t.CnxMedia=3]="CnxMedia",t[t.Jw=4]="Jw",t[t.Ima=5]="Ima",t[t.AOL=6]="AOL"}(a||(a={})),function(t){t[t.None=0]="None",t[t.PreRoll=1]="PreRoll",t[t.MidRoll=2]="MidRoll",t[t.PostRoll=3]="PostRoll"}(c||(c={})),function(t){t[t.Unknown=0]="Unknown",t[t.NoCmp=1]="NoCmp",t[t.NoConsent=2]="NoConsent",t[t.NoConnatixConsent=3]="NoConnatixConsent",t[t.NotAllDemandConsent=4]="NotAllDemandConsent",t[t.AllGood=5]="AllGood"}(d||(d={})),function(t){t[t.CaseA=0]="CaseA",t[t.CaseB=1]="CaseB"}(l||(l={})),function(t){t[t.RequestException=0]="RequestException",t[t.Timeout=1]="Timeout",t[t.EmptyResponse=2]="EmptyResponse",t[t.InvalidResponse=3]="InvalidResponse",t[t.NoBid=4]="NoBid",t[t.BidBelowFloor=5]="BidBelowFloor",t[t.DealIdMismatch=6]="DealIdMismatch",t[t.CsInvalidResponse=7]="CsInvalidResponse",t[t.CsRequestException=8]="CsRequestException",t[t.CsEmptyResponse=9]="CsEmptyResponse",t[t.NoLibInPage=11]="NoLibInPage",t[t.BidIsNotTargetingAllowedEver=12]="BidIsNotTargetingAllowedEver",t[t.VastVersionNotSupported=13]="VastVersionNotSupported"}(u||(u={})),function(t){t[t.Unknown=0]="Unknown",t[t.TechnicalError=1]="TechnicalError",t[t.InvalidRequest=2]="InvalidRequest",t[t.KnownWebSpider=3]="KnownWebSpider",t[t.SuspectedNonHumanTraffic=4]="SuspectedNonHumanTraffic",t[t.CloudIP=5]="CloudIP",t[t.UnsupportedDevice=6]="UnsupportedDevice",t[t.BlockedPublisher=7]="BlockedPublisher",t[t.UnmatchedUser=8]="UnmatchedUser",t[t.DailyReaderCapMet=9]="DailyReaderCapMet",t[t.DailyDomainCapMet=10]="DailyDomainCapMet"}(p||(p={})),function(t){t[t.MinCpm=0]="MinCpm",t[t.FixedCpm=1]="FixedCpm",t[t.MaxBidPrice=2]="MaxBidPrice",t[t.VideoOrBannerMin=3]="VideoOrBannerMin",t[t.BidInHand=6]="BidInHand",t[t.NoPredictionFound=7]="NoPredictionFound",t[t.StaticFactorUsed=8]="StaticFactorUsed"}(f||(f={})),function(t){t[t.CreativeError=0]="CreativeError",t[t.SDKFailure=1]="SDKFailure",t[t.UnsupportedMedia=2]="UnsupportedMedia",t[t.TargetingMismatch=3]="TargetingMismatch",t[t.PlayerError=4]="PlayerError"}(m||(m={})),function(t){t[t.TargetingMismatch=0]="TargetingMismatch",t[t.CompetitorPriority=1]="CompetitorPriority",t[t.AdOpportunityEnd=2]="AdOpportunityEnd"}(g||(g={})),function(t){t[t.None=0]="None",t[t.PMP=1]="PMP",t[t.OpenMarket=2]="OpenMarket",t[t.SelfServed=3]="SelfServed"}(v||(v={})),function(t){t[t.AdClick=1]="AdClick",t[t.AdClickThrough=2]="AdClickThrough",t[t.AdSkipClick=3]="AdSkipClick",t[t.VolumeClick=4]="VolumeClick",t[t.PauseClick=5]="PauseClick",t[t.PlayClick=6]="PlayClick",t[t.FullScreenClick=7]="FullScreenClick",t[t.MuteClick=8]="MuteClick",t[t.UnmuteClick=9]="UnmuteClick",t[t.ExitFullScreenClick=10]="ExitFullScreenClick",t[t.AdUserClose=11]="AdUserClose"}(y||(y={}));e(202)},1988:(t,i,e)=>{"use strict";var s;e.d(i,{Z:()=>n}),function(t){t.XL="cnx-bp-xl-lit",t.LG="cnx-bp-lg-lit",t.MD="cnx-bp-md-lit",t.SM="cnx-bp-sm-lit",t.XS="cnx-bp-xs-lit"}(s||(s={}));const n=s},4524:(t,i,e)=>{"use strict";var s;e.d(i,{t:()=>s}),function(t){t.Expand="expand",t.Collapse="collapse",t.Close="close",t.OverlayClick="overlayclick",t.GeneralUserInteraction="generaluserinteraction"}(s||(s={}))},6404:(t,i,e)=>{"use strict";var s;e.d(i,{N:()=>s}),function(t){t[t.Off=0]="Off",t[t.OnHover=1]="OnHover",t[t.AlwaysOn=2]="AlwaysOn"}(s||(s={}))},655:(t,i,e)=>{"use strict";e.d(i,{CR:()=>a,FC:()=>l,Jh:()=>o,KL:()=>u,XA:()=>h,ZT:()=>n,ev:()=>c,mG:()=>r,qq:()=>d});var s=function(t,i){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,i){t.__proto__=i}||function(t,i){for(var e in i)Object.prototype.hasOwnProperty.call(i,e)&&(t[e]=i[e])},s(t,i)};function n(t,i){if("function"!=typeof i&&null!==i)throw new TypeError("Class extends value "+String(i)+" is not a constructor or null");function e(){this.constructor=t}s(t,i),t.prototype=null===i?Object.create(i):(e.prototype=i.prototype,new e)}function r(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))}function o(t,i){var e,s,n,r,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return r={next:h(0),throw:h(1),return:h(2)},"function"==typeof Symbol&&(r[Symbol.iterator]=function(){return this}),r;function h(h){return function(a){return function(h){if(e)throw new TypeError("Generator is already executing.");for(;r&&(r=0,h[0]&&(o=0)),o;)try{if(e=1,s&&(n=2&h[0]?s.return:h[0]?s.throw||((n=s.return)&&n.call(s),0):s.next)&&!(n=n.call(s,h[1])).done)return n;switch(s=0,n&&(h=[2&h[0],n.value]),h[0]){case 0:case 1:n=h;break;case 4:return o.label++,{value:h[1],done:!1};case 5:o.label++,s=h[1],h=[0];continue;case 7:h=o.ops.pop(),o.trys.pop();continue;default:if(!(n=o.trys,(n=n.length>0&&n[n.length-1])||6!==h[0]&&2!==h[0])){o=0;continue}if(3===h[0]&&(!n||h[1]>n[0]&&h[1]<n[3])){o.label=h[1];break}if(6===h[0]&&o.label<n[1]){o.label=n[1],n=h;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(h);break}n[2]&&o.ops.pop(),o.trys.pop();continue}h=i.call(t,o)}catch(t){h=[6,t],s=0}finally{e=n=0}if(5&h[0])throw h[1];return{value:h[0]?h[1]:void 0,done:!0}}([h,a])}}}Object.create;function h(t){var i="function"==typeof Symbol&&Symbol.iterator,e=i&&t[i],s=0;if(e)return e.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&s>=t.length&&(t=void 0),{value:t&&t[s++],done:!t}}};throw new TypeError(i?"Object is not iterable.":"Symbol.iterator is not defined.")}function a(t,i){var e="function"==typeof Symbol&&t[Symbol.iterator];if(!e)return t;var s,n,r=e.call(t),o=[];try{for(;(void 0===i||i-- >0)&&!(s=r.next()).done;)o.push(s.value)}catch(t){n={error:t}}finally{try{s&&!s.done&&(e=r.return)&&e.call(r)}finally{if(n)throw n.error}}return o}function c(t,i,e){if(e||2===arguments.length)for(var s,n=0,r=i.length;n<r;n++)!s&&n in i||(s||(s=Array.prototype.slice.call(i,0,n)),s[n]=i[n]);return t.concat(s||Array.prototype.slice.call(i))}function d(t){return this instanceof d?(this.v=t,this):new d(t)}function l(t,i,e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var s,n=e.apply(t,i||[]),r=[];return s={},o("next"),o("throw"),o("return"),s[Symbol.asyncIterator]=function(){return this},s;function o(t){n[t]&&(s[t]=function(i){return new Promise((function(e,s){r.push([t,i,e,s])>1||h(t,i)}))})}function h(t,i){try{(e=n[t](i)).value instanceof d?Promise.resolve(e.value.v).then(a,c):l(r[0][2],e)}catch(t){l(r[0][3],t)}var e}function a(t){h("next",t)}function c(t){h("throw",t)}function l(t,i){t(i),r.shift(),r.length&&h(r[0][0],r[0][1])}}function u(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var i,e=t[Symbol.asyncIterator];return e?e.call(t):(t=h(t),i={},s("next"),s("throw"),s("return"),i[Symbol.asyncIterator]=function(){return this},i);function s(e){i[e]=t[e]&&function(i){return new Promise((function(s,n){(function(t,i,e,s){Promise.resolve(s).then((function(i){t({value:i,done:e})}),i)})(s,n,(i=t[e](i)).done,i.value)}))}}}Object.create},8659:(t,i,e)=>{"use strict";var s;e.d(i,{Fw:()=>n,nC:()=>k,f3:()=>E,b2:()=>M,Yn:()=>B,ri:()=>L}),function(t){t[t.Transient=0]="Transient",t[t.Singleton=1]="Singleton",t[t.ResolutionScoped=2]="ResolutionScoped",t[t.ContainerScoped=3]="ContainerScoped"}(s||(s={}));const n=s;var r=function(t,i){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,i){t.__proto__=i}||function(t,i){for(var e in i)i.hasOwnProperty(e)&&(t[e]=i[e])},r(t,i)};function o(t,i){function e(){this.constructor=t}r(t,i),t.prototype=null===i?Object.create(i):(e.prototype=i.prototype,new e)}function h(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))}function a(t,i){var e,s,n,r,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return r={next:h(0),throw:h(1),return:h(2)},"function"==typeof Symbol&&(r[Symbol.iterator]=function(){return this}),r;function h(r){return function(h){return function(r){if(e)throw new TypeError("Generator is already executing.");for(;o;)try{if(e=1,s&&(n=2&r[0]?s.return:r[0]?s.throw||((n=s.return)&&n.call(s),0):s.next)&&!(n=n.call(s,r[1])).done)return n;switch(s=0,n&&(r=[2&r[0],n.value]),r[0]){case 0:case 1:n=r;break;case 4:return o.label++,{value:r[1],done:!1};case 5:o.label++,s=r[1],r=[0];continue;case 7:r=o.ops.pop(),o.trys.pop();continue;default:if(!(n=o.trys,(n=n.length>0&&n[n.length-1])||6!==r[0]&&2!==r[0])){o=0;continue}if(3===r[0]&&(!n||r[1]>n[0]&&r[1]<n[3])){o.label=r[1];break}if(6===r[0]&&o.label<n[1]){o.label=n[1],n=r;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(r);break}n[2]&&o.ops.pop(),o.trys.pop();continue}r=i.call(t,o)}catch(t){r=[6,t],s=0}finally{e=n=0}if(5&r[0])throw r[1];return{value:r[0]?r[1]:void 0,done:!0}}([r,h])}}}function c(t){var i="function"==typeof Symbol&&Symbol.iterator,e=i&&t[i],s=0;if(e)return e.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&s>=t.length&&(t=void 0),{value:t&&t[s++],done:!t}}};throw new TypeError(i?"Object is not iterable.":"Symbol.iterator is not defined.")}function d(t,i){var e="function"==typeof Symbol&&t[Symbol.iterator];if(!e)return t;var s,n,r=e.call(t),o=[];try{for(;(void 0===i||i-- >0)&&!(s=r.next()).done;)o.push(s.value)}catch(t){n={error:t}}finally{try{s&&!s.done&&(e=r.return)&&e.call(r)}finally{if(n)throw n.error}}return o}function l(){for(var t=[],i=0;i<arguments.length;i++)t=t.concat(d(arguments[i]));return t}function u(t){return!!t.useClass}function p(t){return!!t.useFactory}var f=function(){function t(t){this.wrap=t,this.reflectMethods=["get","getPrototypeOf","setPrototypeOf","getOwnPropertyDescriptor","defineProperty","has","set","deleteProperty","apply","construct","ownKeys"]}return t.prototype.createProxy=function(t){var i,e=this,s=!1;return new Proxy({},this.createHandler((function(){return s||(i=t(e.wrap()),s=!0),i})))},t.prototype.createHandler=function(t){var i={};return this.reflectMethods.forEach((function(e){i[e]=function(){for(var i=[],s=0;s<arguments.length;s++)i[s]=arguments[s];return i[0]=t(),Reflect[e].apply(void 0,l(i))}})),i},t}();function m(t){return"string"==typeof t||"symbol"==typeof t}function g(t){return"object"==typeof t&&"token"in t&&"transform"in t}function v(t){return!!t.useToken}function y(t){return null!=t.useValue}const b=function(){function t(){this.lu=new Map}return t.prototype.entries=function(){return this.lu.entries()},t.prototype.getAll=function(t){return this.ensure(t),this.lu.get(t)},t.prototype.get=function(t){this.ensure(t);var i=this.lu.get(t);return i[i.length-1]||null},t.prototype.set=function(t,i){this.ensure(t),this.lu.get(t).push(i)},t.prototype.setAll=function(t,i){this.lu.set(t,i)},t.prototype.has=function(t){return this.ensure(t),this.lu.get(t).length>0},t.prototype.clear=function(){this.lu.clear()},t.prototype.ensure=function(t){this.lu.has(t)||this.lu.set(t,[])},t}();const I=function(t){function i(){return null!==t&&t.apply(this,arguments)||this}return o(i,t),i}(b);const w=function(){this.scopedResolutions=new Map};function S(t,i,e){var s,n,r=d(t.toString().match(/constructor\(([\w, ]+)\)/)||[],2)[1],o=function(t,i){return null===t?"at position #"+i:'"'+t.split(",")[i].trim()+'" at position #'+i}(void 0===r?null:r,i);return s="Cannot inject the dependency "+o+' of "'+t.name+'" constructor. Reason:',void 0===n&&(n="    "),l([s],e.message.split("\n").map((function(t){return n+t}))).join("\n")}var P=function(t){function i(){return null!==t&&t.apply(this,arguments)||this}return o(i,t),i}(b),A=function(t){function i(){return null!==t&&t.apply(this,arguments)||this}return o(i,t),i}(b);const _=function(){this.preResolution=new P,this.postResolution=new A};var x=new Map,T=function(){function t(t){this.parent=t,this.uu=new I,this.interceptors=new _,this.disposed=!1,this.disposables=new Set}return t.prototype.register=function(t,i,e){var s;if(void 0===e&&(e={lifecycle:n.Transient}),this.ensureNotDisposed(),s=function(t){return u(t)||y(t)||v(t)||p(t)}(i)?i:{useClass:i},v(s))for(var r=[t],o=s;null!=o;){var h=o.useToken;if(r.includes(h))throw new Error("Token registration cycle detected! "+l(r,[h]).join(" -> "));r.push(h);var a=this.uu.get(h);o=a&&v(a.provider)?a.provider:null}if((e.lifecycle===n.Singleton||e.lifecycle==n.ContainerScoped||e.lifecycle==n.ResolutionScoped)&&(y(s)||p(s)))throw new Error('Cannot use lifecycle "'+n[e.lifecycle]+'" with ValueProviders or FactoryProviders');return this.uu.set(t,{provider:s,options:e}),this},t.prototype.registerType=function(t,i){return this.ensureNotDisposed(),m(i)?this.register(t,{useToken:i}):this.register(t,{useClass:i})},t.prototype.registerInstance=function(t,i){return this.ensureNotDisposed(),this.register(t,{useValue:i})},t.prototype.registerSingleton=function(t,i){if(this.ensureNotDisposed(),m(t)){if(m(i))return this.register(t,{useToken:i},{lifecycle:n.Singleton});if(i)return this.register(t,{useClass:i},{lifecycle:n.Singleton});throw new Error('Cannot register a type name as a singleton without a "to" token')}var e=t;return i&&!m(i)&&(e=i),this.register(t,{useClass:e},{lifecycle:n.Singleton})},t.prototype.resolve=function(t,i){void 0===i&&(i=new w),this.ensureNotDisposed();var e=this.getRegistration(t);if(!e&&m(t))throw new Error('Attempted to resolve unregistered dependency token: "'+t.toString()+'"');if(this.executePreResolutionInterceptor(t,"Single"),e){var s=this.resolveRegistration(e,i);return this.executePostResolutionInterceptor(t,s,"Single"),s}if(function(t){return"function"==typeof t||t instanceof f}(t)){s=this.construct(t,i);return this.executePostResolutionInterceptor(t,s,"Single"),s}throw new Error("Attempted to construct an undefined constructor. Could mean a circular dependency problem. Try using `delay` function.")},t.prototype.executePreResolutionInterceptor=function(t,i){var e,s;if(this.interceptors.preResolution.has(t)){var n=[];try{for(var r=c(this.interceptors.preResolution.getAll(t)),o=r.next();!o.done;o=r.next()){var h=o.value;"Once"!=h.options.frequency&&n.push(h),h.callback(t,i)}}catch(t){e={error:t}}finally{try{o&&!o.done&&(s=r.return)&&s.call(r)}finally{if(e)throw e.error}}this.interceptors.preResolution.setAll(t,n)}},t.prototype.executePostResolutionInterceptor=function(t,i,e){var s,n;if(this.interceptors.postResolution.has(t)){var r=[];try{for(var o=c(this.interceptors.postResolution.getAll(t)),h=o.next();!h.done;h=o.next()){var a=h.value;"Once"!=a.options.frequency&&r.push(a),a.callback(t,i,e)}}catch(t){s={error:t}}finally{try{h&&!h.done&&(n=o.return)&&n.call(o)}finally{if(s)throw s.error}}this.interceptors.postResolution.setAll(t,r)}},t.prototype.resolveRegistration=function(t,i){if(this.ensureNotDisposed(),t.options.lifecycle===n.ResolutionScoped&&i.scopedResolutions.has(t))return i.scopedResolutions.get(t);var e,s=t.options.lifecycle===n.Singleton,r=t.options.lifecycle===n.ContainerScoped,o=s||r;return e=y(t.provider)?t.provider.useValue:v(t.provider)?o?t.instance||(t.instance=this.resolve(t.provider.useToken,i)):this.resolve(t.provider.useToken,i):u(t.provider)?o?t.instance||(t.instance=this.construct(t.provider.useClass,i)):this.construct(t.provider.useClass,i):p(t.provider)?t.provider.useFactory(this):this.construct(t.provider,i),t.options.lifecycle===n.ResolutionScoped&&i.scopedResolutions.set(t,e),e},t.prototype.resolveAll=function(t,i){var e=this;void 0===i&&(i=new w),this.ensureNotDisposed();var s=this.getAllRegistrations(t);if(!s&&m(t))throw new Error('Attempted to resolve unregistered dependency token: "'+t.toString()+'"');if(this.executePreResolutionInterceptor(t,"All"),s){var n=s.map((function(t){return e.resolveRegistration(t,i)}));return this.executePostResolutionInterceptor(t,n,"All"),n}var r=[this.construct(t,i)];return this.executePostResolutionInterceptor(t,r,"All"),r},t.prototype.isRegistered=function(t,i){return void 0===i&&(i=!1),this.ensureNotDisposed(),this.uu.has(t)||i&&(this.parent||!1)&&this.parent.isRegistered(t,!0)},t.prototype.reset=function(){this.ensureNotDisposed(),this.uu.clear(),this.interceptors.preResolution.clear(),this.interceptors.postResolution.clear()},t.prototype.clearInstances=function(){var t,i;this.ensureNotDisposed();try{for(var e=c(this.uu.entries()),s=e.next();!s.done;s=e.next()){var n=d(s.value,2),r=n[0],o=n[1];this.uu.setAll(r,o.filter((function(t){return!y(t.provider)})).map((function(t){return t.instance=void 0,t})))}}catch(i){t={error:i}}finally{try{s&&!s.done&&(i=e.return)&&i.call(e)}finally{if(t)throw t.error}}},t.prototype.createChildContainer=function(){var i,e;this.ensureNotDisposed();var s=new t(this);try{for(var r=c(this.uu.entries()),o=r.next();!o.done;o=r.next()){var h=d(o.value,2),a=h[0],l=h[1];l.some((function(t){return t.options.lifecycle===n.ContainerScoped}))&&s.uu.setAll(a,l.map((function(t){return t.options.lifecycle===n.ContainerScoped?{provider:t.provider,options:t.options}:t})))}}catch(t){i={error:t}}finally{try{o&&!o.done&&(e=r.return)&&e.call(r)}finally{if(i)throw i.error}}return s},t.prototype.beforeResolution=function(t,i,e){void 0===e&&(e={frequency:"Always"}),this.interceptors.preResolution.set(t,{callback:i,options:e})},t.prototype.afterResolution=function(t,i,e){void 0===e&&(e={frequency:"Always"}),this.interceptors.postResolution.set(t,{callback:i,options:e})},t.prototype.dispose=function(){return h(this,void 0,void 0,(function(){var t;return a(this,(function(i){switch(i.label){case 0:return this.disposed=!0,t=[],this.disposables.forEach((function(i){var e=i.dispose();e&&t.push(e)})),[4,Promise.all(t)];case 1:return i.sent(),[2]}}))}))},t.prototype.getRegistration=function(t){return this.isRegistered(t)?this.uu.get(t):this.parent?this.parent.getRegistration(t):null},t.prototype.getAllRegistrations=function(t){return this.isRegistered(t)?this.uu.getAll(t):this.parent?this.parent.getAllRegistrations(t):null},t.prototype.construct=function(t,i){var e=this;if(t instanceof f)return t.createProxy((function(t){return e.resolve(t,i)}));var s,n=function(){var s=x.get(t);if(!s||0===s.length){if(0===t.length)return new t;throw new Error('TypeInfo not known for "'+t.name+'"')}var n=s.map(e.resolveParams(i,t));return new(t.bind.apply(t,l([void 0],n)))}();return"function"!=typeof(s=n).dispose||s.dispose.length>0||this.disposables.add(n),n},t.prototype.resolveParams=function(t,i){var e=this;return function(s,n){var r,o,h,a;try{return"object"==typeof(a=s)&&"token"in a&&"multiple"in a?g(s)?s.multiple?(r=e.resolve(s.transform)).transform.apply(r,l([e.resolveAll(s.token)],s.transformArgs)):(o=e.resolve(s.transform)).transform.apply(o,l([e.resolve(s.token,t)],s.transformArgs)):s.multiple?e.resolveAll(s.token):e.resolve(s.token,t):g(s)?(h=e.resolve(s.transform,t)).transform.apply(h,l([e.resolve(s.token,t)],s.transformArgs)):e.resolve(s,t)}catch(t){throw new Error(S(i,n,t))}}},t.prototype.ensureNotDisposed=function(){if(this.disposed)throw new Error("This container has been disposed, you cannot interact with a disposed container")},t}(),k=new T;var C="injectionTokens";const E=function(t){return i=t,function(t,s,n){var r=Reflect.getOwnMetadata(C,t)||{};r[n]=e?{token:i,transform:e.transformToken,transformArgs:e.args||[]}:i,Reflect.defineMetadata(C,r,t)};var i,e};const M=function(){return function(t){x.set(t,function(t){var i=Reflect.getMetadata("design:paramtypes",t)||[],e=Reflect.getOwnMetadata(C,t)||{};return Object.keys(e).forEach((function(t){i[+t]=e[t]})),i}(t))}};const L=function(){return function(t){M()(t),k.registerSingleton(t)}};function B(t,i){return function(e){M()(e),k.register(i||e,e,{lifecycle:t})}}if("undefined"==typeof Reflect||!Reflect.getMetadata)throw new Error("tsyringe requires a reflect polyfill. Please add 'import \"reflect-metadata\"' to the top of your entry point.")},289:function(t,i,e){var s,n,r;n=[e(4492)],void 0===(r="function"==typeof(s=function(t){"use strict";return(t.roots.common||(t.roots.common=new t.Root)).addJSON({ProtoAdBreak:{fields:{types:{rule:"repeated",type:"ProtoAdBreakTypeEnum",id:1,options:{packed:!1}},maxAdPodDuration:{type:"int32",id:2},maxAdSlotDuration:{type:"int32",id:3,options:{default:180}},numberOfAdSlots:{type:"int32",id:4,options:{default:1}}}},ProtoAdDomainBlockingResponse:{fields:{domains:{rule:"repeated",type:"string",id:1}}},ProtoCoreTamBidRequest:{fields:{lineItemId:{type:"string",id:1},code:{type:"string",id:2},metadata:{type:"MetadataModel",id:3},exploration:{type:"bool",id:4}}},MetadataModel:{fields:{version:{type:"int32",id:1},sessionId:{type:"string",id:2},playerId:{type:"string",id:3},userId:{type:"string",id:4},browser:{type:"Browser",id:5},geo:{type:"GeoLocation",id:6},clientAb0:{type:"int32",id:7},clientAb1:{type:"int32",id:8},serverAb0:{type:"int32",id:9},serverAb1:{type:"int32",id:10},pageUrl:{type:"string",id:15},bundleId:{type:"string",id:17},implementationType:{type:"ProtoImplementationType",id:18},shouldTrackAllRequests:{type:"bool",id:19},customParam1:{type:"string",id:20},customParam2:{type:"string",id:21},customParam3:{type:"string",id:22},abTestId:{type:"string",id:24},isPageInFocus:{type:"bool",id:25},customParam4:{type:"string",id:26},customParam5:{type:"string",id:27},bundleAbId:{type:"string",id:28},bundlePart:{type:"string",id:29}}},Browser:{fields:{browserVersion:{type:"string",id:1},browserType:{type:"string",id:2},osCode:{type:"string",id:3},device:{type:"ProtoDeviceType",id:4}}},GeoLocation:{fields:{countryGeoId:{type:"int32",id:1},cityId:{type:"int32",id:2},subdivisionId:{type:"int32",id:3},dmaId:{type:"int32",id:4},ip:{type:"string",id:5},lat:{type:"double",id:6},lon:{type:"double",id:7},zipcode:{type:"string",id:8}}},ProtoCoreTamBidResponse:{fields:{errorMessage:{type:"string",id:1},encryptedBidPrice:{type:"string",id:10},ofskp:{type:"double",id:12},impressionTimeSpent:{type:"int32",id:13},bidRate:{type:"double",id:14},successRate:{type:"double",id:15}}},ProtoCookieSettings:{fields:{name:{type:"string",id:1},value:{type:"string",id:2},timestamp:{type:"int64",id:3}}},ProtoCookieSyncRequest:{fields:{cookieList:{rule:"repeated",type:"ProtoCookieSettings",id:1},secureMode:{type:"ProtoCookieSecureModeEnum",id:2},browserInfo:{type:"Browser",id:3}}},ProtoUserInformation:{fields:{userId:{type:"string",id:1},lookupId:{type:"string",id:3},lookupResponseCode:{type:"int32",id:4},callFraudSensor:{type:"bool",id:5},publisherAdsTxt:{type:"string",id:6}}},CreativeTrackerViewModel:{fields:{type:{type:"ProtoTrackerType",id:1},trigger:{type:"ProtoTrackerTriggerType",id:2},url:{type:"string",id:3}}},ProtoDiscount:{oneofs:{pu:{oneof:["rate"]}},fields:{rate:{type:"double",id:2,options:{proto3_optional:!0}},id:{type:"string",id:1}}},Insights:{fields:{key:{type:"string",id:1}}},ProtoSentimentAnalysis:{fields:{positive:{type:"double",id:1},neutral:{type:"double",id:2},negative:{type:"double",id:3}}},ProtoInsightsResponse:{fields:{insights:{rule:"repeated",type:"Insights",id:1},sentimentAnalysis:{type:"ProtoSentimentAnalysis",id:2}}},ProtoLineItemAdBreakTargeting:{fields:{adRollType:{type:"ProtoAdBreakTypeEnum",id:1},adBreakTypeEnum:{type:"ProtoLineItemAdBreakTypeEnum",id:2}}},ProtoLineItemAdPodTargeting:{fields:{targetingType:{type:"ProtoLineItemTargetingTypeEnum",id:1},adSlotTargetingType:{type:"ProtoLineItemAdSlotTargetingTypeEnum",id:2},adSlotPositions:{rule:"repeated",type:"int32",id:3,options:{packed:!1}}}},ProtoLineItemAdBreakSettings:{fields:{adBreakTargeting:{rule:"repeated",type:"ProtoLineItemAdBreakTargeting",id:1},adPodTargeting:{type:"ProtoLineItemAdPodTargeting",id:2}}},ProtoLineItemQueryStringTargeting:{fields:{rule:{type:"ProtoLineItemQueryTargetingRuleEnum",id:1},keyValue:{keyType:"string",type:"string",id:2}}},ProtoAdxFloorPricePrediction:{fields:{predictedPriceObfuscated:{type:"double",id:1},floorPriceObfuscated:{type:"double",id:2},uprQueryName:{type:"string",id:3},uprQueryValue:{type:"string",id:4}}},ProtoLineItem:{oneofs:{fu:{oneof:["floorPricesNew"]}},fields:{floorPricesNew:{type:"ProtoFloorPricesNewModel",id:57,options:{proto3_optional:!0}},publisherLineItemId:{type:"string",id:1},advertiserLineItemId:{type:"string",id:2},adTag:{type:"string",id:3},creativeType:{type:"ProtoCreativeTypeEnum",id:4},sound:{type:"bool",id:6},viewability:{type:"bool",id:7},removeOutOfFocus:{type:"bool",id:8},impressionTimeSpent:{type:"int32",id:9},vendorId:{type:"string",id:10},trackers:{rule:"repeated",type:"CreativeTrackerViewModel",id:12},duration:{type:"int32",id:13},renditions:{rule:"repeated",type:"ProtoRendition",id:14},mediaCreativeId:{type:"string",id:15},ignoreFilledRequests:{type:"bool",id:16},requestCap:{type:"int32",id:17,options:{default:3}},impressionCap:{type:"int32",id:18},successRate:{type:"double",id:19},lineItemPriority:{type:"ProtoLineItemPriority",id:20},headerBidderTimeout:{type:"int32",id:22},mediaCreativeClickUrl:{type:"string",id:23},resetRequestsCapTime:{type:"int32",id:24,options:{default:60}},resetImpressionsCapTime:{type:"int32",id:25,options:{default:60}},resetCapType:{type:"ProtoResetCapTypeEnum",id:26},creativeHlsFileName:{type:"string",id:27},timeBetweenRequests:{type:"int32",id:28},skipMode:{type:"ProtoAdSkipMode",id:29},mediaIdTargeting:{type:"ProtoTargetingChoiceModel",id:30},mediaKeywordsTargeting:{type:"ProtoTargetingChoiceModel",id:31},mediaLanguageTargeting:{type:"ProtoTargetingChoiceModel",id:32},adType:{type:"ProtoAdType",id:33},overlayTime:{type:"int32",id:34,options:{default:30}},floorPrice:{type:"double",id:35},adBreakSettings:{type:"ProtoLineItemAdBreakSettings",id:36},bidRate:{type:"double",id:39},pauseAdOutOfView:{type:"ProtoLineItemPauseAdOutOfViewEnum",id:40},moatTrackingEnabled:{type:"bool",id:41},cnxCreativeId:{type:"string",id:42},blockedDomainsRevisionNumber:{type:"int32",id:44},advertiserContextualTargeting:{rule:"repeated",type:"ProtoContextualTargetingCaseModel",id:45},publisherContextualTargeting:{rule:"repeated",type:"ProtoContextualTargetingCaseModel",id:46},playerSizeTargetings:{type:"ProtoPlayerSizeTargetings",id:47},amazonDealId:{type:"string",id:48},playerOrientationTargeting:{type:"ProtoPlayerOrientationTargetingEnum",id:50},skipMin:{type:"int32",id:51,options:{default:6}},skippability:{type:"ProtoLineItemSkippabilityType",id:52},forceCallingInEveryAO:{type:"bool",id:53},networkExpiryTimeSeconds:{type:"int32",id:54,options:{default:21600}},nonlinearLineItemSettings:{type:"ProtoNonlinearLineItemSettings",id:55},prebidJsBidParamsJSONString:{type:"string",id:58},isPMP:{type:"bool",id:59},queryTargeting:{rule:"repeated",type:"ProtoLineItemQueryStringTargeting",id:61},adxFloorPricePredictionList:{rule:"repeated",type:"ProtoAdxFloorPricePrediction",id:62},playerSize:{type:"string",id:101}}},ProtoTargetingChoiceModel:{fields:{choiceCriteria:{type:"ProtoChoiceCriteriaEnum",id:1},items:{rule:"repeated",type:"string",id:2}}},ProtoContextualTargetingCaseModel:{fields:{filters:{rule:"repeated",type:"ProtoContextualTargetingFilterModel",id:1}}},ProtoContextualTargetingFilterModel:{fields:{type:{type:"ProtoLineItemContextualTargetingEnum",id:1},level:{type:"ProtoContextualTargetingLevelEnum",id:3},hashedItemsIds:{rule:"repeated",type:"string",id:4}}},ProtoPlayerSizeTargetings:{fields:{sizeChoiceCriteria:{type:"ProtoSizeChoiceCriteriaEnum",id:1},minWidth:{type:"int32",id:2},maxWidth:{type:"int32",id:3}}},ProtoFloorPricesData:{oneofs:{mu:{oneof:["floorPriceBypassReason"]}},fields:{floorPriceBypassReason:{type:"FloorPriceBypassReasonEnum",id:2,options:{proto3_optional:!0}},price:{type:"double",id:1}}},ProtoFloorPricesNewModel:{fields:{floorPrices:{rule:"repeated",type:"ProtoFloorPricesData",id:1},recommended:{type:"int32",id:2}}},ProtoRendition:{fields:{height:{type:"int32",id:1},codec:{type:"string",id:2},file:{type:"string",id:3}}},ProtoNonlinearLineItemSettings:{fields:{nonLinearRequestType:{type:"ProtoNonlinearRequestType",id:1},nonLinearAdTimeSeconds:{type:"int32",id:2,options:{default:15}}}},ProtoLineItemAbTestInformation:{fields:{guid:{type:"string",id:1},lineItemAbTestCase:{type:"ProtoLineItemAbTestCase",id:2}}},ProtoLiveMediaMetadataResponse:{fields:{startDate:{type:"string",id:1},outputUrl:{type:"string",id:2},thumbnailUrl:{type:"string",id:3},altText:{type:"string",id:4},name:{type:"string",id:5}}},ProtoSpriteSheet:{fields:{file:{type:"string",id:1},height:{type:"int32",id:2},count:{type:"int32",id:3}}},ProtoTrack:{fields:{file:{type:"string",id:1},type:{type:"ProtoTrackType",id:2},code:{type:"string",id:3},title:{type:"string",id:4}}},ProtoCuePoint:{fields:{timeStamp:{type:"int32",id:1}}},ProtoMediaMetadataResponse:{fields:{title:{type:"string",id:1},description:{type:"string",id:2},duration:{type:"int32",id:3},clickUrl:{type:"string",id:4},keywordList:{rule:"repeated",type:"string",id:5},trackList:{rule:"repeated",type:"ProtoTrack",id:6},spriteSheet:{type:"ProtoSpriteSheet",id:7},thumbnail:{type:"string",id:8},renditionList:{rule:"repeated",type:"ProtoRendition",id:9},hlsFilePath:{type:"string",id:11},languageId:{type:"string",id:12},sourceItemId:{type:"string",id:13},altText:{type:"string",id:14},cuePoints:{rule:"repeated",type:"ProtoCuePoint",id:16},multimediaId:{type:"string",id:17},publishDate:{type:"uint32",id:18},endDate:{type:"uint32",id:19},contentStudio:{type:"string",id:20},customMetadata:{type:"string",id:21}}},ProtoNonlinearPlayerSettings:{fields:{numberOfNonlinearAds:{type:"int32",id:1},timeSecondsBetweenNonlinear:{type:"int32",id:2,options:{default:5}},timeSecondsBetweenLinearAndNonlinear:{type:"int32",id:3}}},ProtoRtbRequest:{oneofs:{gu:{oneof:["lineItemAbTestInformation"]}},fields:{lineItemAbTestInformation:{type:"ProtoLineItemAbTestInformation",id:46,options:{proto3_optional:!0}},metadata:{type:"MetadataModel",id:1},coppa:{type:"bool",id:4},refererUrl:{type:"string",id:5},testMode:{type:"bool",id:6},videoWidth:{type:"int32",id:7},videoHeight:{type:"int32",id:8},gdprCompliant:{type:"bool",id:9},soundOn:{type:"bool",id:10},gdprConsentData:{type:"string",id:11},explorationMode:{type:"bool",id:12},viewability:{type:"bool",id:13},outstream:{type:"bool",id:14},domainURL:{type:"string",id:16},isClickToPlay:{type:"bool",id:18},appVersion:{type:"string",id:21},deviceID:{type:"string",id:24},lineItems:{keyType:"string",type:"ProtoRtbRequestLineItemEntry",id:25},isCcpaBlockingUserInfo:{type:"bool",id:26},usPrivacyString:{type:"string",id:27},gdprConsentMode:{type:"ProtoGdprConsentModeEnum",id:36},maxAdDuration:{type:"int32",id:37,options:{default:180}},customMacros:{keyType:"string",type:"string",id:38},maxBidPrice:{type:"double",id:39},playerWidth:{type:"int32",id:43},playerHeight:{type:"int32",id:44},useNewSkippability:{type:"bool",id:42},liveRampAtsEnvelope:{type:"string",id:45},connectionType:{type:"int32",id:47},OMSDKSupport:{type:"bool",id:48},OMSDKVersion:{type:"string",id:51}}},ProtoRtbRequestLineItemEntry:{oneofs:{vu:{oneof:["cachedFloorPrice"]}},fields:{cachedFloorPrice:{type:"ProtoCacheFloorPrice",id:16,options:{proto3_optional:!0}},availableRequests:{type:"int32",id:1},gdprConsent:{type:"bool",id:4},publisherLineItemId:{type:"string",id:5},slotWidth:{type:"int32",id:6},slotHeight:{type:"int32",id:7},requestNumber:{type:"int32",id:8},skip:{type:"ProtoSkipEnabledEnum",id:12},skipmin:{type:"int32",id:13},skipafter:{type:"int32",id:14},minDuration:{type:"int32",id:15}}},ProtoCacheFloorPrice:{fields:{floorPrices:{rule:"repeated",type:"double",id:1,options:{packed:!1}},recommended:{type:"int32",id:2}}},ProtoRtbResponse:{fields:{lineItemResponses:{rule:"repeated",type:"ProtoRtbLineItem",id:3},liveRampEnvelopeStatus:{type:"LiveRampEnvelopeStatusEnum",id:4}}},ProtoRtbBid:{oneofs:{yu:{oneof:["floorPriceInformation"]},bu:{oneof:["discount"]}},fields:{floorPriceInformation:{type:"ProtoFloorPriceInformation",id:30,options:{proto3_optional:!0}},discount:{type:"ProtoDiscount",id:31,options:{proto3_optional:!0}},winNoticeUrl:{type:"string",id:2},adQualityCheckUrl:{type:"string",id:3},vastTag:{type:"string",id:4},encryptedPrice:{type:"string",id:6},creativeId:{type:"string",id:7},seatId:{type:"string",id:8},adomain:{type:"string",id:9},syncedUser:{type:"bool",id:10},requestedFloorPrice:{type:"double",id:11},campaignId:{type:"string",id:13},width:{type:"int32",id:14},height:{type:"int32",id:15},billingNoticeUrlList:{rule:"repeated",type:"string",id:16},mime:{type:"string",id:17,options:{default:"text/html"}},gtkpbp:{type:"double",id:18},successRate:{type:"double",id:19},impressionTimeSpent:{type:"int32",id:20},bidRate:{type:"double",id:21},dspId:{type:"string",id:22},cnxBidId:{type:"string",id:23},logAuctionInformation:{type:"bool",id:24},auctionBidId:{type:"string",id:25},rtbRequestId:{type:"string",id:26},liveRampType:{type:"ProtoLiveRampEnum",id:32},serverBillingNoticeUrls:{rule:"repeated",type:"string",id:33}}},ProtoRtbLineItem:{oneofs:{vu:{oneof:["cachedFloorPrice"]}},fields:{cachedFloorPrice:{type:"ProtoCacheFloorPrice",id:6,options:{proto3_optional:!0}},id:{type:"string",id:1},bids:{rule:"repeated",type:"ProtoRtbBid",id:3},noBidsCount:{type:"int32",id:5}}},ProtoSupplyChain:{fields:{businessDomain:{type:"string",id:1},supplyChainId:{type:"string",id:3}}},ProtoAdClickTrackingRequest:{oneofs:{gu:{oneof:["lineItemAbTestInformation"]}},fields:{lineItemAbTestInformation:{type:"ProtoLineItemAbTestInformation",id:14,options:{proto3_optional:!0}},trackingRequestMeta:{type:"MetadataModel",id:1},mediaGuid:{type:"string",id:2},publisherLineItemId:{type:"string",id:3},advertiserLineItemId:{type:"string",id:4},type:{type:"ProtoAdClickTypeEnum",id:5},insightIndexes:{rule:"repeated",type:"string",id:10},adBreakType:{type:"ProtoAdBreakTypeEnum",id:11},sentimentAnalysis:{type:"ProtoSentimentAnalysis",id:12},pageInsightIndexes:{rule:"repeated",type:"string",id:13},iasSegmentCodes:{rule:"repeated",type:"string",id:15}}},ProtoAdOpportunityRequest:{fields:{trackingRequestMeta:{type:"MetadataModel",id:2},adBreak:{type:"ProtoAdBreakTypeEnum",id:3},playerWidth:{type:"int32",id:4},pageInsightIndexes:{rule:"repeated",type:"string",id:5},dynamicElkFieldsValues:{keyType:"string",type:"string",id:100}}},ProtoAuctionInfoRequest:{fields:{cnxBidId:{type:"string",id:1},auctionInformation:{type:"ProtoAuctionInformation",id:2},auctionLossReason:{type:"ProtoAuctionLossReasonEnum",id:3}}},ProtoAuctionInformation:{fields:{highestObfuscatedBidPrice:{type:"double",id:1},secondHighestObfuscatedBidPrice:{type:"double",id:2},bidDensity:{type:"int32",id:3}}},ProtoFloorPriceInformation:{oneofs:{Iu:{oneof:["floorPriceIndexUsed"]},mu:{oneof:["floorPriceBypassReason"]},wu:{oneof:["adxPredictedFloorPrice"]}},fields:{floorPriceIndexUsed:{type:"int32",id:2,options:{proto3_optional:!0}},floorPriceBypassReason:{type:"FloorPriceBypassReasonEnum",id:3,options:{proto3_optional:!0}},adxPredictedFloorPrice:{type:"double",id:4,options:{proto3_optional:!0}},floorPrices:{rule:"repeated",type:"double",id:1,options:{packed:!1}}}},ProtoPrebid:{oneofs:{yu:{oneof:["floorPriceInformation"]}},fields:{floorPriceInformation:{type:"ProtoFloorPriceInformation",id:16,options:{proto3_optional:!0}},publisherLineItemId:{type:"string",id:1},advertiserLineItemId:{type:"string",id:2},isUserSynced:{type:"bool",id:3},timeSpent:{type:"int32",id:4},reason:{type:"ConnatixNoBidReasonEnum",id:5},requestNumber:{type:"int32",id:6},partnerReason:{type:"PartnerNoBidReasonEnum",id:7},requestedFloorPrice:{type:"double",id:8},partnerCustomHeaders:{type:"string",id:9},prebidJsBidderName:{type:"string",id:12},playerWidth:{type:"int32",id:14},playerHeight:{type:"int32",id:15},dynamicElkFieldsValues:{keyType:"string",type:"string",id:100}}},ProtoBid:{oneofs:{yu:{oneof:["floorPriceInformation"]}},fields:{floorPriceInformation:{type:"ProtoFloorPriceInformation",id:22,options:{proto3_optional:!0}},publisherLineItemId:{type:"string",id:1},advertiserLineItemId:{type:"string",id:2},isUserSynced:{type:"bool",id:3},timeSpent:{type:"int32",id:4},requestNumber:{type:"int32",id:5},creativeId:{type:"string",id:6},rtbSeatId:{type:"string",id:7},rtbAdomain:{type:"string",id:8},encryptedPrice:{type:"string",id:9},requestedFloorPrice:{type:"double",id:10},prebidJsBidderName:{type:"string",id:13},customClientPrice:{type:"double",id:14},dspId:{type:"string",id:15},cnxBidId:{type:"string",id:16},playerWidth:{type:"int32",id:18},playerHeight:{type:"int32",id:19},dynamicElkFieldsValues:{keyType:"string",type:"string",id:100}}},ProtoPostBid:{oneofs:{yu:{oneof:["floorPriceInformation"]},bu:{oneof:["discount"]}},fields:{floorPriceInformation:{type:"ProtoFloorPriceInformation",id:28,options:{proto3_optional:!0}},discount:{type:"ProtoDiscount",id:30,options:{proto3_optional:!0}},publisherLineItemId:{type:"string",id:1},advertiserLineItemId:{type:"string",id:2},isUserSynced:{type:"bool",id:3},timeSpent:{type:"int32",id:4},error:{type:"string",id:5},isBidLoaded:{type:"bool",id:6},creativeId:{type:"string",id:7},rtbSeatId:{type:"string",id:8},rtbAdomain:{type:"string",id:9},adsourceType:{type:"ProtoAdsourceTypeEnum",id:10},vastMediaType:{type:"string",id:11},adPodSlotPosition:{type:"int32",id:12},prebidJsBidderName:{type:"string",id:13},dspId:{type:"string",id:14},cnxBidId:{type:"string",id:15},winToAdLoadedTime:{type:"int32",id:16},auctionInformation:{type:"ProtoAuctionInformation",id:18},auctionPostbidReason:{type:"ProtoAuctionPostbidReasonEnum",id:19},requestNumber:{type:"int32",id:20},floorPrice:{type:"double",id:22},playerWidth:{type:"int32",id:23},playerHeight:{type:"int32",id:24},bidElapsedTimeSeconds:{type:"int32",id:25},adBreakType:{type:"ProtoAdBreakTypeEnum",id:26},liveRampType:{type:"ProtoLiveRampEnum",id:32},dynamicElkFieldsValues:{keyType:"string",type:"string",id:100}}},ProtoBidTrackingsRequest:{oneofs:{gu:{oneof:["lineItemAbTestInformation"]}},fields:{lineItemAbTestInformation:{type:"ProtoLineItemAbTestInformation",id:13,options:{proto3_optional:!0}},trackingRequestMeta:{type:"MetadataModel",id:1},mediaGuid:{type:"string",id:2},prebids:{rule:"repeated",type:"ProtoPrebid",id:4},bids:{rule:"repeated",type:"ProtoBid",id:5},postBids:{rule:"repeated",type:"ProtoPostBid",id:6},shouldLogEverything:{type:"bool",id:7},hasGdprConsentPayload:{type:"bool",id:10},gdprConsentMode:{type:"ProtoGdprConsentModeEnum",id:11},isExplorationMode:{type:"bool",id:12}}},ProtoHeavyAdTrackingRequest:{fields:{trackingRequestMeta:{type:"MetadataModel",id:1},advertiserLineItemId:{type:"string",id:2},heavyAdBlockTypeEnum:{type:"ProtoHeavyAdBlockTypeEnum",id:3},dynamicElkFieldsValues:{keyType:"string",type:"string",id:100}}},ProtoInternalAuction:{oneofs:{Su:{oneof:["firstLoser"]},Pu:{oneof:["firstOpenMarketLoser"]}},fields:{firstLoser:{type:"ProtoInternalAuctionBid",id:2,options:{proto3_optional:!0}},firstOpenMarketLoser:{type:"ProtoInternalAuctionBid",id:3,options:{proto3_optional:!0}},winnerDemandType:{type:"ProtoDemandTypeEnum",id:1}}},ProtoInternalAuctionBid:{oneofs:{Au:{oneof:["customClientPrice"]},_u:{oneof:["encryptedPrice"]},xu:{oneof:["adDuration"]}},fields:{customClientPrice:{type:"double",id:2,options:{proto3_optional:!0}},encryptedPrice:{type:"string",id:3,options:{proto3_optional:!0}},adDuration:{type:"double",id:5,options:{proto3_optional:!0}},demandType:{type:"ProtoDemandTypeEnum",id:1},advertiserLineItemId:{type:"string",id:4}}},ProtoMediaClickTrackingRequest:{fields:{trackingRequestMeta:{type:"MetadataModel",id:1},mediaGuid:{type:"string",id:2},type:{type:"ProtoMediaClickTypeEnum",id:3},clickUrl:{type:"string",id:4},slideTitle:{type:"string",id:5},slideNumber:{type:"int32",id:6},slideMediaType:{type:"ProtoMediaTypeEnum",id:7},insightIndexes:{rule:"repeated",type:"string",id:12},sentimentAnalysis:{type:"ProtoSentimentAnalysis",id:13}}},ProtoMediaQuartileRequest:{fields:{trackingRequestMeta:{type:"MetadataModel",id:1},mediaGuid:{type:"string",id:2},quartile:{type:"ProtoQuartilesEnum",id:4},insightIndexes:{rule:"repeated",type:"string",id:9},sentimentAnalysis:{type:"ProtoSentimentAnalysis",id:10}}},ProtoPlayerStartRequest:{fields:{trackingRequestMeta:{type:"MetadataModel",id:1},pageInsightIndexes:{rule:"repeated",type:"string",id:2},dynamicElkFieldsValues:{keyType:"string",type:"string",id:100}}},ProtoSessionAdBlockerRequest:{fields:{trackingRequestMeta:{type:"MetadataModel",id:1},adBlockDetectionType:{type:"ProtoAdBlockDetectionTypeEnum",id:2},dynamicElkFieldsValues:{keyType:"string",type:"string",id:100}}},ProtoSessionRenderedRequest:{fields:{trackingRequestMeta:{type:"MetadataModel",id:1},hasAdBlocker:{type:"bool",id:4},bundleName:{type:"string",id:5},playerWidth:{type:"int32",id:6},playerHeight:{type:"int32",id:7},pageInsightIndexes:{rule:"repeated",type:"string",id:8},dynamicElkFieldsValues:{keyType:"string",type:"string",id:100}}},ProtoSessionTimeTrackingRequest:{fields:{trackingRequestMeta:{type:"MetadataModel",id:1},timePlayed:{type:"int32",id:2},timePlayedInView:{type:"int32",id:3},sessionTime:{type:"int32",id:4},pageInsightIndexes:{rule:"repeated",type:"string",id:5}}},ProtoSessionViewRequest:{fields:{trackingRequestMeta:{type:"MetadataModel",id:1},pageInsightIndexes:{rule:"repeated",type:"string",id:2},dynamicElkFieldsValues:{keyType:"string",type:"string",id:100}}},ProtoTrackingResponse:{oneofs:{Tu:{oneof:["isViewabilityRestricted"]}},fields:{isViewabilityRestricted:{type:"bool",id:5,options:{proto3_optional:!0}},errorMessage:{type:"string",id:1},platformCappedLineItemIdList:{rule:"repeated",type:"string",id:2},impressionRevenue:{type:"double",id:3},adServerLineItemName:{type:"string",id:4}}},ProtoVideoAdImpressionRequest:{oneofs:{yu:{oneof:["floorPriceInformation"]},gu:{oneof:["lineItemAbTestInformation"]},ku:{oneof:["internalAuction"]},bu:{oneof:["discount"]}},fields:{floorPriceInformation:{type:"ProtoFloorPriceInformation",id:46,options:{proto3_optional:!0}},lineItemAbTestInformation:{type:"ProtoLineItemAbTestInformation",id:47,options:{proto3_optional:!0}},internalAuction:{type:"ProtoInternalAuction",id:48,options:{proto3_optional:!0}},discount:{type:"ProtoDiscount",id:50,options:{proto3_optional:!0}},trackingRequestMeta:{type:"MetadataModel",id:1},mediaGuid:{type:"string",id:3},publisherLineItemId:{type:"string",id:5},advertiserLineItemId:{type:"string",id:6},isUserSynced:{type:"bool",id:7},timeSpent:{type:"int32",id:8},encryptedPrice:{type:"string",id:9},creativeId:{type:"string",id:10},rtbSeatId:{type:"string",id:11},rtbAdomain:{type:"string",id:12},customClientPrice:{type:"double",id:13},adsourceType:{type:"ProtoAdsourceTypeEnum",id:14},vastMediaType:{type:"string",id:15},adPodSlotPosition:{type:"int32",id:18},prebidJsBidderName:{type:"string",id:19},dspId:{type:"string",id:20},cnxBidId:{type:"string",id:21},winToAdLoadedTime:{type:"int32",id:22},startAdToImpressionTime:{type:"int32",id:23},declaredDuration:{type:"double",id:24},impressionDuration:{type:"double",id:25},isExplorationMode:{type:"bool",id:26},auctionInformation:{type:"ProtoAuctionInformation",id:27},playerWidth:{type:"int32",id:28},requestNumber:{type:"int32",id:29},floorPrice:{type:"double",id:31},playerHeight:{type:"int32",id:36},bidElapsedTimeSeconds:{type:"int32",id:37},insightIndexes:{rule:"repeated",type:"string",id:38},adBreakType:{type:"ProtoAdBreakTypeEnum",id:40},sentimentAnalysis:{type:"ProtoSentimentAnalysis",id:41},hasAdSkip:{type:"bool",id:39},pageInsightIndexes:{rule:"repeated",type:"string",id:42},iasSegmentCodes:{rule:"repeated",type:"string",id:49},liveRampType:{type:"ProtoLiveRampEnum",id:51},serverBillingNoticeUrls:{rule:"repeated",type:"string",id:53},dynamicElkFieldsValues:{keyType:"string",type:"string",id:100}}},ProtoVideoAdImpressionViewableRequest:{oneofs:{gu:{oneof:["lineItemAbTestInformation"]},bu:{oneof:["discount"]}},fields:{lineItemAbTestInformation:{type:"ProtoLineItemAbTestInformation",id:19,options:{proto3_optional:!0}},discount:{type:"ProtoDiscount",id:21,options:{proto3_optional:!0}},trackingRequestMeta:{type:"MetadataModel",id:1},mediaGuid:{type:"string",id:3},publisherLineItemId:{type:"string",id:5},advertiserLineItemId:{type:"string",id:6},rtbSeatId:{type:"string",id:7},dspId:{type:"string",id:8},insightIndexes:{rule:"repeated",type:"string",id:13},hasAdSkip:{type:"bool",id:14},adBreakType:{type:"ProtoAdBreakTypeEnum",id:15},sentimentAnalysis:{type:"ProtoSentimentAnalysis",id:16},pageInsightIndexes:{rule:"repeated",type:"string",id:17},rtbAdomain:{type:"string",id:18},iasSegmentCodes:{rule:"repeated",type:"string",id:20},dynamicElkFieldsValues:{keyType:"string",type:"string",id:100}}},ProtoVideoAdQuartilesRequest:{oneofs:{gu:{oneof:["lineItemAbTestInformation"]}},fields:{lineItemAbTestInformation:{type:"ProtoLineItemAbTestInformation",id:20,options:{proto3_optional:!0}},trackingRequestMeta:{type:"MetadataModel",id:1},mediaGuid:{type:"string",id:3},publisherLineItemId:{type:"string",id:5},advertiserLineItemId:{type:"string",id:6},quartile:{type:"ProtoQuartilesEnum",id:7},rtbSeatId:{type:"string",id:8},dspId:{type:"string",id:9},insightIndexes:{rule:"repeated",type:"string",id:14},hasAdSkip:{type:"bool",id:15},adBreakType:{type:"ProtoAdBreakTypeEnum",id:16},sentimentAnalysis:{type:"ProtoSentimentAnalysis",id:17},pageInsightIndexes:{rule:"repeated",type:"string",id:18},rtbAdomain:{type:"string",id:19},iasSegmentCodes:{rule:"repeated",type:"string",id:21}}},ProtoUserSyncRequest:{fields:{userId:{type:"string",id:1},demandPartner:{type:"int32",id:2},demandPartnerUserId:{type:"string",id:3}}},ProtoPlayerPlaybackModeEnum:{values:{Autoplay:0,ScrollToPlay:1,ClickToPlay:2}},ProtoPlayerCloseButtonMode:{values:{Off:0,OnHover:1,OnHoverAfterFirstAd:2,AlwaysOn:3}},ProtoPlayerFloatingMode:{values:{Off:0,OnPageLoad:1,AfterInView:2,Always:3}},ProtoPlayerSoundMode:{values:{Mute:0,On:1,Hover:2}},ProtoPlayerInsertMode:{values:{WithinContainer:0,BeforeContainer:1,AfterContainer:2,ReplaceContainer:3,HideContainer:4}},ProtoAdViewabilityPolicy:{values:{Default:0,Strict:1}},ProtoSharingDestination:{values:{Facebook:0,Twitter:1,LinkedIn:2}},ProtoFloatingFixedPositionMode:{values:{Page:0,Element:1}},ProtoPositionMode:{values:{BottomRight:0,BottomLeft:1,TopRight:2,TopLeft:3,PinnedTop:4,PinnedBottom:5}},ProtoAdPlaybackMode:{values:{Autoplay:0,ScrollToPlay:1}},ProtoFloatingAppendLocationEnum:{values:{Above:0,Below:1,Within:2}},ProtoPlayerAdSkippability:{values:{IfLongerThan:0,Always:1,NoRestrictions:2}},ProtoVideoQuality:{values:{Auto:0,High1080p:1,High720p:2,Medium360p:3}},ProtoImplementationType:{values:{Web:0,Amp:1}},ProtoAdBreakTypeEnum:{values:{None:0,PreRoll:1,MidRoll:2,PostRoll:3}},ProtoAdSlotAdTypeEnum:{values:{SingleAd:0,AdPod:1}},ProtoPlayerSkippabilityType:{values:{AllowNonSkipAdsIfTheyAreShorterThan:0,RequireAdsToBeSkippable:1}},ProtoBandwidthLoggingEnum:{values:{Disabled:0,Enabled:1,SaaS:2}},ProtoDeviceType:{values:{Desktop:0,Smartphone:1,Tablet:2,GameConsole:3,SmartTV:4,WearableComputer:5,PDA:6,Unrecognized:7}},ProtoCookieSecureModeEnum:{values:{Secure:0,Unsecure:1,Auto:2}},ProtoTrackerType:{values:{Image:0,Javascript:1,IAS:2}},ProtoTrackerTriggerType:{values:{Impression:0,Complete25Pc:1,Complete50Pc:2,Complete75Pc:3,ViewCompletion:4,VideoClick:5,Pause:6,Resume:7,Mute:8,Unmute:9}},ProtoCreativeTypeEnum:{values:{ThirdParty:0,MediaFile:1,Rtb:2,External:3,HeaderBidder:4,Tam:7,TamDeal:8,TamPrivateAuction:9}},ProtoResetCapTypeEnum:{values:{TimeCapping:0,ContentCapping:1,OpportunityCapping:2}},ProtoAdSlotsEnum:{values:{PreRoll:0,MidRoll:1,PostRoll:2}},ProtoLineItemPriority:{values:{House:0,Default:1,Preferred:2,Top:3}},ProtoAdSkipMode:{values:{IfLongerThan31Sec:0,Always:1,Never:2,NotAplicable:3}},ProtoAdType:{values:{Video:0,Overlay:1,Nonlinear:2}},ProtoChoiceCriteriaEnum:{values:{Only:0,Except:1}},ProtoLineItemAdBreakTypeEnum:{values:{All:1,SingleAd:2,AdPod:3}},ProtoLineItemTargetingTypeEnum:{values:{Only:0,Except:1}},ProtoLineItemAdSlotTargetingTypeEnum:{values:{SpecificSlots:1,Interval:2}},ProtoLineItemPauseAdOutOfViewEnum:{values:{Default:0,Strict:1}},ProtoLineItemContextualTargetingEnum:{values:{IncludeAny:0,IncludeAll:1,ExcludeAny:2,ExcludeAll:3}},ProtoSizeChoiceCriteriaEnum:{values:{GreaterThan:0,SmallerThan:1,Between:2}},ProtoPlayerOrientationTargetingEnum:{values:{Both:0,Portrait:1,Landscape:2}},ProtoLineItemSkippabilityType:{values:{AllowPublisherToDetermineSkippability:0,RequirePublisherToAllowNonSkipAdsShorterThan:1,NotApplicable:2}},ProtoContextualTargetingLevelEnum:{values:{Media:0,Page:1,Both:2}},FloorPriceBypassReasonEnum:{values:{MinCpm:0,FixedCpm:1,MaxBidPrice:2,VideoOrBannerMin:3,BidInHand:6,NoPredictionFound:7,StaticFactorUsed:8}},ProtoLineItemQueryTargetingRuleEnum:{values:{Only:0,Except:1}},ProtoNonlinearRequestType:{values:{Banner:0,Video:1}},ProtoLineItemAbTestCase:{values:{CaseA:0,CaseB:1}},ProtoTrackType:{values:{ManualSubtitle:0,AutoGeneratedSubtitle:1,ClosedCaptions:2}},ProtoMediaTypeEnum:{values:{Image:0,Video:1}},ProtoSkipEnabledEnum:{values:{No:0,Yes:1}},LiveRampEnvelopeStatusEnum:{values:{Ok:0,EnvelopeExpired:1,Unauthorized:2}},ConnatixNoBidReasonEnum:{values:{RequestException:0,Timeout:1,EmptyResponse:2,InvalidResponse:3,NoBid:4,BidBelowFloor:5,DealIdMismatch:6,CsInvalidResponse:7,CsRequestException:8,CsEmptyResponse:9,NoLibInPage:11,BidIsNotTargetingAllowedEver:12,VastVersionNotSupported:13}},PartnerNoBidReasonEnum:{values:{Unknown:0,TechnicalError:1,InvalidRequest:2,KnownWebSpider:3,SuspectedNonHumanTraffic:4,CloudIP:5,UnsupportedDevice:6,BlockedPublisher:7,UnmatchedUser:8,DailyReaderCapMet:9,DailyDomainCapMet:10}},ProtoAdBlockDetectionTypeEnum:{values:{Banner:0,Network:1}},ProtoAdClickTypeEnum:{values:{AdClick:1,AdClickThrough:2,AdSkipClick:3,VolumeClick:4,PauseClick:5,PlayClick:6,FullScreenClick:7,MuteClick:8,UnmuteClick:9,ExitFullScreenClick:10,AdUserClose:11}},ProtoAdsourceTypeEnum:{values:{Unknown:0,Vpaid:1,VastMedia:2,CnxMedia:3,Jw:4,Ima:5,AOL:6}},ProtoAuctionLossReasonEnum:{values:{TargetingMismatch:0,CompetitorPriority:1,AdOpportunityEnd:2}},ProtoGdprConsentModeEnum:{values:{Unknown:0,NoCmp:1,NoConsent:2,NoConnatixConsent:3,NotAllDemandConsent:4,AllGood:5}},ProtoAuctionPostbidReasonEnum:{values:{CreativeError:0,SDKFailure:1,UnsupportedMedia:2,TargetingMismatch:3,PlayerError:4}},ProtoHeavyAdBlockTypeEnum:{values:{Global:0,Script:1,VpaidIframe:2,OverlayIframe:3}},ProtoDemandTypeEnum:{values:{None:0,PMP:1,OpenMarket:2,SelfServed:3}},ProtoLiveRampEnum:{values:{None:0,ATS:1,NonATS:2}},ProtoMediaClickTypeEnum:{values:{Click:0,UrlClick:1,VolumeClick:2,PlayClick:3,PauseClick:4,NextClick:5,PreviousClick:6,MuteClick:7,UnmuteClick:8,CloseClick:9,GalleryClick:11,SubtitleClick:12,FullScreenClick:13,ExitFullScreenClick:14}},ProtoQuartilesEnum:{values:{Start:0,First:1,Second:2,Third:3,Fourth:4}}})})?s.apply(i,n):s)||(t.exports=r)},7953:function(t,i,e){var s,n,r;n=[e(4492)],void 0===(r="function"==typeof(s=function(t){"use strict";return(t.roots.elements||(t.roots.elements=new t.Root)).addJSON({ProtoElementsRequest:{fields:{tokens:{rule:"repeated",type:"string",id:1},pageUrl:{type:"string",id:3},userId:{type:"string",id:5},forcePlayerId:{type:"string",id:7},forcePlaylistId:{type:"string",id:9},version:{type:"int32",id:10},forceLineItemIds:{rule:"repeated",type:"string",id:11},clientAb0:{type:"int32",id:12},clientAb1:{type:"int32",id:13},customParam1:{type:"string",id:16},customParam2:{type:"string",id:17},customParam3:{type:"string",id:18},forceExploration:{type:"bool",id:20},es6:{type:"bool",id:21},bundleId:{type:"string",id:22},forceSourceItemId:{type:"string",id:23},parseDomain:{type:"bool",id:24},implementationType:{type:"ProtoImplementationType",id:25},queryJsTargeting:{keyType:"string",type:"string",id:26},isConsentConnatix:{type:"bool",id:27,options:{default:!0}},reloadedPlayers:{keyType:"string",type:"string",id:29},disableTracking:{type:"bool",id:31},referrer:{type:"string",id:32},localTimestamp:{type:"int64",id:33},customParam4:{type:"string",id:34},customParam5:{type:"string",id:35},forceMediaIdList:{rule:"repeated",type:"string",id:36},servingRuleId:{type:"string",id:37},cnxDebug:{type:"bool",id:38},useMediaIdListAsPlaylist:{type:"bool",id:39}}},ProtoPlaylistItem:{oneofs:{Cu:{oneof:["mediaContentVersionId"]},Eu:{oneof:["insightsRevisionNumber"]},Mu:{oneof:["disableAdvertising"]}},fields:{mediaContentVersionId:{type:"string",id:3,options:{proto3_optional:!0}},insightsRevisionNumber:{type:"int32",id:4,options:{proto3_optional:!0}},disableAdvertising:{type:"bool",id:5,options:{proto3_optional:!0}},mediaId:{type:"string",id:1},revisionNumber:{type:"int32",id:2}}},ProtoElements:{fields:{playerId:{type:"string",id:1},playbackMode:{type:"ProtoPlayerPlaybackModeEnum",id:2},soundMode:{type:"ProtoPlayerSoundMode",id:3},upNextMode:{type:"ProtoPlayerUpNextMode",id:4,options:{default:1}},containerSelector:{type:"string",id:5},position:{type:"int32",id:6},insertPosition:{type:"ProtoPlayerInsertMode",id:7},forceInsertPath:{type:"bool",id:8},renderInFrame:{type:"bool",id:9},scrollHijackingProtection:{type:"bool",id:10},preRollBreak:{type:"int32",id:11},postRollBreak:{type:"int32",id:12},midRollNumber:{type:"int32",id:13,options:{default:-1}},timeBetweenAds:{type:"int32",id:14},minTimeBeforeFirstAd:{type:"int32",id:15},adViewabilityPolicy:{type:"ProtoAdViewabilityPolicy",id:16},responsive:{type:"bool",id:18},ratioWidth:{type:"int32",id:19},ratioHeight:{type:"int32",id:20},fixedWidth:{type:"int32",id:21},fixedHeight:{type:"int32",id:22},casting:{type:"bool",id:23},sharingDestinations:{rule:"repeated",type:"ProtoSharingDestination",id:24,options:{packed:!1}},closedCaption:{type:"bool",id:25},muteWatermark:{type:"bool",id:26},expandButton:{type:"bool",id:27},closeButtonMode:{type:"ProtoPlayerCloseButtonMode",id:28},floatingMode:{type:"ProtoPlayerFloatingMode",id:29},floatingDeviceMode:{rule:"repeated",type:"ProtoDeviceType",id:30,options:{packed:!1}},floatingCloseButtonMode:{type:"ProtoPlayerCloseButtonMode",id:31},floatingFixedPosition:{type:"ProtoFloatingFixedPositionMode",id:32},floatingPageElement:{type:"string",id:33},floatingUseElementWidth:{type:"bool",id:34},floatingScrollPosition:{type:"ProtoPositionMode",id:35},floatingGutterX:{type:"int32",id:36},floatingGutterY:{type:"int32",id:37},floatingWidth:{type:"int32",id:38},iconsColor:{type:"string",id:39},accentColor:{type:"string",id:40},tooltipTextColor:{type:"string",id:41},tooltipBackgroundColor:{type:"string",id:42},html:{type:"string",id:43},galleryStyle:{type:"ProtoGalleryStyleMode",id:45},logoPosition:{type:"ProtoLogoPositionMode",id:46},lineItems:{rule:"repeated",type:"ProtoLineItem",id:49},adPlaybackMode:{type:"ProtoAdPlaybackMode",id:50},css:{type:"string",id:51},sessionId:{type:"string",id:52},playlistId:{type:"string",id:53},playerType:{type:"ProtoElementsTypeEnum",id:54},outstreamInitialRendering:{type:"ProtoOutstreamInitialRenderingEnum",id:55},outstreamHouseBackgroundColor:{type:"string",id:56},outstreamTotalAdBreakLength:{type:"int32",id:57},outstreamEndAdBreakPolicy:{type:"ProtoOutstreamEndAdBreakPolicyEnum",id:58},galleryOrientation:{type:"ProtoGalleryOrientationEnum",id:59},playlist:{rule:"repeated",type:"ProtoPlaylistItem",id:60},floatingAppendLocation:{type:"ProtoFloatingAppendLocationEnum",id:61},floatingYAxisPadding:{type:"int32",id:62},customJsCode:{type:"string",id:63},videoQuality:{type:"ProtoVideoQuality",id:64},initializationSettingsJson:{type:"string",id:65},skipAdAfter:{type:"int32",id:67,options:{default:5}},adBreaks:{rule:"repeated",type:"ProtoAdBreak",id:68},amazonTamSlotId:{type:"string",id:69},midRollOnlyOnLongContent:{type:"bool",id:70,options:{default:!0}},limitClientSideApiUse:{type:"bool",id:71},abTestId:{type:"string",id:72},skipMin:{type:"int32",id:73,options:{default:31}},skippability:{type:"ProtoPlayerSkippabilityType",id:74},logoResource:{type:"string",id:76},nonlinearPlayerSettings:{type:"ProtoNonlinearPlayerSettings",id:77},displayAdCountdown:{type:"bool",id:78},bandwidthLoggingState:{type:"ProtoBandwidthLoggingEnum",id:79},prefetchOnPreroll:{type:"bool",id:80,options:{default:!0}},playlistThumbnail:{type:"string",id:81},playlistName:{type:"string",id:82},playlistDescription:{type:"string",id:83},hasFloatingTransition:{type:"bool",id:84,options:{default:!0}},symbolResource:{type:"string",id:85}}},ProtoElementsResponse:{oneofs:{gu:{oneof:["lineItemAbTestInformation"]}},fields:{lineItemAbTestInformation:{type:"ProtoLineItemAbTestInformation",id:31,options:{proto3_optional:!0}},errorMessage:{type:"string",id:1},players:{rule:"repeated",type:"ProtoElements",id:10},browser:{type:"Browser",id:11},geoLocation:{type:"GeoLocation",id:12},lineItems:{rule:"repeated",type:"ProtoLineItem",id:13},cookieSyncUrls:{keyType:"int32",type:"string",id:14},explorationMode:{type:"bool",id:15},supplyChain:{type:"ProtoSupplyChain",id:17},secondLevelDomain:{type:"string",id:18},userInformation:{type:"ProtoUserInformation",id:20},serverAb0:{type:"int32",id:21},serverAb1:{type:"int32",id:22},isSeoTraffic:{type:"bool",id:23},publisherNetworkCode:{type:"string",id:26},iOSAppID:{type:"string",id:27},hashedPageUrl:{type:"string",id:28},bundleAbId:{type:"string",id:29},bundlePart:{type:"string",id:30},IASSegmentCodes:{rule:"repeated",type:"string",id:32},AmazonTamPubId:{type:"string",id:33},tier:{type:"int32",id:34,options:{default:2}}}},ProtoLineItemAdBreakTargeting:{fields:{adRollType:{type:"ProtoAdBreakTypeEnum",id:1},adBreakTypeEnum:{type:"ProtoLineItemAdBreakTypeEnum",id:2}}},ProtoLineItemAdPodTargeting:{fields:{targetingType:{type:"ProtoLineItemTargetingTypeEnum",id:1},adSlotTargetingType:{type:"ProtoLineItemAdSlotTargetingTypeEnum",id:2},adSlotPositions:{rule:"repeated",type:"int32",id:3,options:{packed:!1}}}},ProtoLineItemAdBreakSettings:{fields:{adBreakTargeting:{rule:"repeated",type:"ProtoLineItemAdBreakTargeting",id:1},adPodTargeting:{type:"ProtoLineItemAdPodTargeting",id:2}}},ProtoLineItemQueryStringTargeting:{fields:{rule:{type:"ProtoLineItemQueryTargetingRuleEnum",id:1},keyValue:{keyType:"string",type:"string",id:2}}},ProtoAdxFloorPricePrediction:{fields:{predictedPriceObfuscated:{type:"double",id:1},floorPriceObfuscated:{type:"double",id:2},uprQueryName:{type:"string",id:3},uprQueryValue:{type:"string",id:4}}},ProtoLineItem:{oneofs:{fu:{oneof:["floorPricesNew"]}},fields:{floorPricesNew:{type:"ProtoFloorPricesNewModel",id:57,options:{proto3_optional:!0}},publisherLineItemId:{type:"string",id:1},advertiserLineItemId:{type:"string",id:2},adTag:{type:"string",id:3},creativeType:{type:"ProtoCreativeTypeEnum",id:4},sound:{type:"bool",id:6},viewability:{type:"bool",id:7},removeOutOfFocus:{type:"bool",id:8},impressionTimeSpent:{type:"int32",id:9},vendorId:{type:"string",id:10},trackers:{rule:"repeated",type:"CreativeTrackerViewModel",id:12},duration:{type:"int32",id:13},renditions:{rule:"repeated",type:"ProtoRendition",id:14},mediaCreativeId:{type:"string",id:15},ignoreFilledRequests:{type:"bool",id:16},requestCap:{type:"int32",id:17,options:{default:3}},impressionCap:{type:"int32",id:18},successRate:{type:"double",id:19},lineItemPriority:{type:"ProtoLineItemPriority",id:20},headerBidderTimeout:{type:"int32",id:22},mediaCreativeClickUrl:{type:"string",id:23},resetRequestsCapTime:{type:"int32",id:24,options:{default:60}},resetImpressionsCapTime:{type:"int32",id:25,options:{default:60}},resetCapType:{type:"ProtoResetCapTypeEnum",id:26},creativeHlsFileName:{type:"string",id:27},timeBetweenRequests:{type:"int32",id:28},skipMode:{type:"ProtoAdSkipMode",id:29},mediaIdTargeting:{type:"ProtoTargetingChoiceModel",id:30},mediaKeywordsTargeting:{type:"ProtoTargetingChoiceModel",id:31},mediaLanguageTargeting:{type:"ProtoTargetingChoiceModel",id:32},adType:{type:"ProtoAdType",id:33},overlayTime:{type:"int32",id:34,options:{default:30}},floorPrice:{type:"double",id:35},adBreakSettings:{type:"ProtoLineItemAdBreakSettings",id:36},bidRate:{type:"double",id:39},pauseAdOutOfView:{type:"ProtoLineItemPauseAdOutOfViewEnum",id:40},moatTrackingEnabled:{type:"bool",id:41},cnxCreativeId:{type:"string",id:42},blockedDomainsRevisionNumber:{type:"int32",id:44},advertiserContextualTargeting:{rule:"repeated",type:"ProtoContextualTargetingCaseModel",id:45},publisherContextualTargeting:{rule:"repeated",type:"ProtoContextualTargetingCaseModel",id:46},playerSizeTargetings:{type:"ProtoPlayerSizeTargetings",id:47},amazonDealId:{type:"string",id:48},playerOrientationTargeting:{type:"ProtoPlayerOrientationTargetingEnum",id:50},skipMin:{type:"int32",id:51,options:{default:6}},skippability:{type:"ProtoLineItemSkippabilityType",id:52},forceCallingInEveryAO:{type:"bool",id:53},networkExpiryTimeSeconds:{type:"int32",id:54,options:{default:21600}},nonlinearLineItemSettings:{type:"ProtoNonlinearLineItemSettings",id:55},prebidJsBidParamsJSONString:{type:"string",id:58},isPMP:{type:"bool",id:59},queryTargeting:{rule:"repeated",type:"ProtoLineItemQueryStringTargeting",id:61},adxFloorPricePredictionList:{rule:"repeated",type:"ProtoAdxFloorPricePrediction",id:62},playerSize:{type:"string",id:101}}},ProtoTargetingChoiceModel:{fields:{choiceCriteria:{type:"ProtoChoiceCriteriaEnum",id:1},items:{rule:"repeated",type:"string",id:2}}},ProtoContextualTargetingCaseModel:{fields:{filters:{rule:"repeated",type:"ProtoContextualTargetingFilterModel",id:1}}},ProtoContextualTargetingFilterModel:{fields:{type:{type:"ProtoLineItemContextualTargetingEnum",id:1},level:{type:"ProtoContextualTargetingLevelEnum",id:3},hashedItemsIds:{rule:"repeated",type:"string",id:4}}},ProtoPlayerSizeTargetings:{fields:{sizeChoiceCriteria:{type:"ProtoSizeChoiceCriteriaEnum",id:1},minWidth:{type:"int32",id:2},maxWidth:{type:"int32",id:3}}},ProtoFloorPricesData:{oneofs:{mu:{oneof:["floorPriceBypassReason"]}},fields:{floorPriceBypassReason:{type:"FloorPriceBypassReasonEnum",id:2,options:{proto3_optional:!0}},price:{type:"double",id:1}}},ProtoFloorPricesNewModel:{fields:{floorPrices:{rule:"repeated",type:"ProtoFloorPricesData",id:1},recommended:{type:"int32",id:2}}},CreativeTrackerViewModel:{fields:{type:{type:"ProtoTrackerType",id:1},trigger:{type:"ProtoTrackerTriggerType",id:2},url:{type:"string",id:3}}},ProtoRendition:{fields:{height:{type:"int32",id:1},codec:{type:"string",id:2},file:{type:"string",id:3}}},ProtoNonlinearLineItemSettings:{fields:{nonLinearRequestType:{type:"ProtoNonlinearRequestType",id:1},nonLinearAdTimeSeconds:{type:"int32",id:2,options:{default:15}}}},Browser:{fields:{browserVersion:{type:"string",id:1},browserType:{type:"string",id:2},osCode:{type:"string",id:3},device:{type:"ProtoDeviceType",id:4}}},GeoLocation:{fields:{countryGeoId:{type:"int32",id:1},cityId:{type:"int32",id:2},subdivisionId:{type:"int32",id:3},dmaId:{type:"int32",id:4},ip:{type:"string",id:5},lat:{type:"double",id:6},lon:{type:"double",id:7},zipcode:{type:"string",id:8}}},ProtoSupplyChain:{fields:{businessDomain:{type:"string",id:1},supplyChainId:{type:"string",id:3}}},ProtoUserInformation:{fields:{userId:{type:"string",id:1},lookupId:{type:"string",id:3},lookupResponseCode:{type:"int32",id:4},callFraudSensor:{type:"bool",id:5},publisherAdsTxt:{type:"string",id:6}}},ProtoAdBreak:{fields:{types:{rule:"repeated",type:"ProtoAdBreakTypeEnum",id:1,options:{packed:!1}},maxAdPodDuration:{type:"int32",id:2},maxAdSlotDuration:{type:"int32",id:3,options:{default:180}},numberOfAdSlots:{type:"int32",id:4,options:{default:1}}}},ProtoNonlinearPlayerSettings:{fields:{numberOfNonlinearAds:{type:"int32",id:1},timeSecondsBetweenNonlinear:{type:"int32",id:2,options:{default:5}},timeSecondsBetweenLinearAndNonlinear:{type:"int32",id:3}}},ProtoLineItemAbTestInformation:{fields:{guid:{type:"string",id:1},lineItemAbTestCase:{type:"ProtoLineItemAbTestCase",id:2}}},ProtoOutstreamInitialRenderingEnum:{values:{ExpandWithAd:0,FullyRendered:1}},ProtoOutstreamEndAdBreakPolicyEnum:{values:{Hide:0,HouseScreen:1,Loop:2}},ProtoGalleryStyleMode:{values:{None:0,Detailed:1,Visual:2}},ProtoLogoPositionMode:{values:{None:0,ControlBar:1,BottomRight:2,BottomLeft:3,TopRight:4,TopLeft:5,Center:6}},ProtoGalleryOrientationEnum:{values:{Landscape:0,Portrait:1}},ProtoElementsTypeEnum:{values:{InStream:0,OutStream:1,InStreamInApp:2,Live:3}},ProtoPlayerUpNextMode:{values:{Loop:0,Next:1,Stop:2}},ProtoCreativeTypeEnum:{values:{ThirdParty:0,MediaFile:1,Rtb:2,External:3,HeaderBidder:4,Tam:7,TamDeal:8,TamPrivateAuction:9}},ProtoResetCapTypeEnum:{values:{TimeCapping:0,ContentCapping:1,OpportunityCapping:2}},ProtoAdSlotsEnum:{values:{PreRoll:0,MidRoll:1,PostRoll:2}},ProtoLineItemPriority:{values:{House:0,Default:1,Preferred:2,Top:3}},ProtoAdSkipMode:{values:{IfLongerThan31Sec:0,Always:1,Never:2,NotAplicable:3}},ProtoAdType:{values:{Video:0,Overlay:1,Nonlinear:2}},ProtoChoiceCriteriaEnum:{values:{Only:0,Except:1}},ProtoLineItemAdBreakTypeEnum:{values:{All:1,SingleAd:2,AdPod:3}},ProtoLineItemTargetingTypeEnum:{values:{Only:0,Except:1}},ProtoLineItemAdSlotTargetingTypeEnum:{values:{SpecificSlots:1,Interval:2}},ProtoLineItemPauseAdOutOfViewEnum:{values:{Default:0,Strict:1}},ProtoLineItemContextualTargetingEnum:{values:{IncludeAny:0,IncludeAll:1,ExcludeAny:2,ExcludeAll:3}},ProtoSizeChoiceCriteriaEnum:{values:{GreaterThan:0,SmallerThan:1,Between:2}},ProtoPlayerOrientationTargetingEnum:{values:{Both:0,Portrait:1,Landscape:2}},ProtoLineItemSkippabilityType:{values:{AllowPublisherToDetermineSkippability:0,RequirePublisherToAllowNonSkipAdsShorterThan:1,NotApplicable:2}},ProtoContextualTargetingLevelEnum:{values:{Media:0,Page:1,Both:2}},FloorPriceBypassReasonEnum:{values:{MinCpm:0,FixedCpm:1,MaxBidPrice:2,VideoOrBannerMin:3,BidInHand:6,NoPredictionFound:7,StaticFactorUsed:8}},ProtoLineItemQueryTargetingRuleEnum:{values:{Only:0,Except:1}},ProtoTrackerType:{values:{Image:0,Javascript:1,IAS:2}},ProtoTrackerTriggerType:{values:{Impression:0,Complete25Pc:1,Complete50Pc:2,Complete75Pc:3,ViewCompletion:4,VideoClick:5,Pause:6,Resume:7,Mute:8,Unmute:9}},ProtoPlayerPlaybackModeEnum:{values:{Autoplay:0,ScrollToPlay:1,ClickToPlay:2}},ProtoPlayerCloseButtonMode:{values:{Off:0,OnHover:1,OnHoverAfterFirstAd:2,AlwaysOn:3}},ProtoPlayerFloatingMode:{values:{Off:0,OnPageLoad:1,AfterInView:2,Always:3}},ProtoPlayerSoundMode:{values:{Mute:0,On:1,Hover:2}},ProtoPlayerInsertMode:{values:{WithinContainer:0,BeforeContainer:1,AfterContainer:2,ReplaceContainer:3,HideContainer:4}},ProtoAdViewabilityPolicy:{values:{Default:0,Strict:1}},ProtoSharingDestination:{values:{Facebook:0,Twitter:1,LinkedIn:2}},ProtoFloatingFixedPositionMode:{values:{Page:0,Element:1}},ProtoPositionMode:{values:{BottomRight:0,BottomLeft:1,TopRight:2,TopLeft:3,PinnedTop:4,PinnedBottom:5}},ProtoAdPlaybackMode:{values:{Autoplay:0,ScrollToPlay:1}},ProtoFloatingAppendLocationEnum:{values:{Above:0,Below:1,Within:2}},ProtoPlayerAdSkippability:{values:{IfLongerThan:0,Always:1,NoRestrictions:2}},ProtoVideoQuality:{values:{Auto:0,High1080p:1,High720p:2,Medium360p:3}},ProtoImplementationType:{values:{Web:0,Amp:1}},ProtoAdBreakTypeEnum:{values:{None:0,PreRoll:1,MidRoll:2,PostRoll:3}},ProtoAdSlotAdTypeEnum:{values:{SingleAd:0,AdPod:1}},ProtoPlayerSkippabilityType:{values:{AllowNonSkipAdsIfTheyAreShorterThan:0,RequireAdsToBeSkippable:1}},ProtoBandwidthLoggingEnum:{values:{Disabled:0,Enabled:1,SaaS:2}},ProtoNonlinearRequestType:{values:{Banner:0,Video:1}},ProtoDeviceType:{values:{Desktop:0,Smartphone:1,Tablet:2,GameConsole:3,SmartTV:4,WearableComputer:5,PDA:6,Unrecognized:7}},ProtoLineItemAbTestCase:{values:{CaseA:0,CaseB:1}}})})?s.apply(i,n):s)||(t.exports=r)},1418:(t,i,e)=>{const{Parser:s}=e(1682);t.exports=s},1215:t=>{"use strict";t.exports='<svg viewBox = "0 0 22 22" class="cnx-color-icon" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" ><path d="M18 5.4L16.6 4 11 9.6 5.4 4 4 5.4 9.6 11 4 16.6 5.4 18l5.6-5.6 5.6 5.6 1.4-1.4-5.6-5.6z"/></svg>\n'},3669:t=>{"use strict";t.exports='<svg class="cnx-color-icon" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 22 22"><path d="M11 7c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z" /></svg>\n'},1639:t=>{"use strict";t.exports='<svg class="cnx-color-icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M9 21H3V3h6v18zm12 0h-6V3h6v18z" fill-rule="evenodd"/></svg>\n'},834:t=>{"use strict";t.exports='<svg class="cnx-color-icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M5 4v16l16-8z" fill-rule="evenodd"/></svg>\n'},6263:t=>{"use strict";t.exports='<svg class="cnx-color-icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M18 21h3V3h-3v18zM3 21l14-9L3 3v18z" fill-rule="evenodd"/></svg>'},3731:(t,i,e)=>{"use strict";function s(t,i){const e=o(t),s=o(i),n=e.pop(),r=s.pop(),h=d(e,s);return 0!==h?h:n&&r?d(n.split("."),r.split(".")):n||r?n?-1:1:0}e.d(i,{qu:()=>n});const n=(t,i,e)=>{p(e);const n=s(t,i);return l[e].includes(n)};s.validate=t=>"string"==typeof t&&/^[v\d]/.test(t)&&r.test(t),s.compare=n,s.satisfies=(t,i)=>{const e=i.match(/^([<>=~^]+)/),s=e?e[1]:"=";if("^"!==s&&"~"!==s)return n(t,i,s);const[r,h,a]=o(t),[l,u,p]=o(i);return 0===c(r,l)&&("^"===s?d([h,a],[u,p])>=0:0===c(h,u)&&c(a,p)>=0)};const r=/^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i,o=t=>{if("string"!=typeof t)throw new TypeError("Invalid argument expected string");const i=t.match(r);if(!i)throw new Error(`Invalid argument not valid semver ('${t}' received)`);return i.shift(),i},h=t=>"*"===t||"x"===t||"X"===t,a=t=>{const i=parseInt(t,10);return isNaN(i)?t:i},c=(t,i)=>{if(h(t)||h(i))return 0;const[e,s]=((t,i)=>typeof t!=typeof i?[String(t),String(i)]:[t,i])(a(t),a(i));return e>s?1:e<s?-1:0},d=(t,i)=>{for(let e=0;e<Math.max(t.length,i.length);e++){const s=c(t[e]||0,i[e]||0);if(0!==s)return s}return 0},l={">":[1],">=":[0,1],"=":[0],"<=":[-1,0],"<":[-1]},u=Object.keys(l),p=t=>{if("string"!=typeof t)throw new TypeError("Invalid operator type, expected string but got "+typeof t);if(-1===u.indexOf(t))throw new Error(`Invalid operator, expected one of ${u.join("|")}`)}}},i={},e,s,n;function r(e){var s=i[e];if(void 0!==s)return s.exports;var n=i[e]={id:e,loaded:!1,exports:{}};return t[e].call(n.exports,n,n.exports,r),n.loaded=!0,n.exports}r.m=t,e=[],r.O=(t,i,s,n)=>{if(!i){var o=1/0;for(d=0;d<e.length;d++){for(var[i,s,n]=e[d],h=!0,a=0;a<i.length;a++)(!1&n||o>=n)&&Object.keys(r.O).every((t=>r.O[t](i[a])))?i.splice(a--,1):(h=!1,n<o&&(o=n));if(h){e.splice(d--,1);var c=s();void 0!==c&&(t=c)}}return t}n=n||0;for(var d=e.length;d>0&&e[d-1][2]>n;d--)e[d]=e[d-1];e[d]=[i,s,n]},r.n=t=>{var i=t&&t.Lu?()=>t.default:()=>t;return r.d(i,{a:i}),i},r.d=(t,i)=>{for(var e in i)r.o(i,e)&&!r.o(t,e)&&Object.defineProperty(t,e,{enumerable:!0,get:i[e]})},r.f={},r.e=t=>Promise.all(Object.keys(r.f).reduce(((i,e)=>(r.f[e](t,i),i)),[])),r.u=t=>{if("elements.ui"===t)return t+".5c9685a29db4b3c950db.js"},r.miniCssF=t=>{},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),r.o=(t,i)=>Object.prototype.hasOwnProperty.call(t,i),s={},n="Connatix.Player:",r.l=(t,i,e,o)=>{if(s[t])s[t].push(i);else{var h,a;if(void 0!==e)for(var c=document.getElementsByTagName("script"),d=0;d<c.length;d++){var l=c[d];if(l.getAttribute("src")==t||l.getAttribute("data-webpack")==n+e){h=l;break}}h||(a=!0,(h=document.createElement("script")).charset="utf-8",h.timeout=120,r.nc&&h.setAttribute("nonce",r.nc),h.setAttribute("data-webpack",n+e),h.src=t),s[t]=[i];var u=(i,e)=>{h.onerror=h.onload=null,clearTimeout(p);var n=s[t];if(delete s[t],h.parentNode&&h.parentNode.removeChild(h),n&&n.forEach((t=>t(e))),i)return i(e)},p=setTimeout(u.bind(null,void 0,{type:"timeout",target:h}),12e4);h.onerror=u.bind(null,h.onerror),h.onload=u.bind(null,h.onload),a&&document.head.appendChild(h)}},r.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"Lu",{value:!0})},r.nmd=t=>(t.paths=[],t.children||(t.children=[]),t),(()=>{var t;r.g.importScripts&&(t=r.g.location+"");var i=r.g.document;if(!t&&i&&(i.currentScript&&(t=i.currentScript.src),!t)){var e=i.getElementsByTagName("script");e.length&&(t=e[e.length-1].src)}if(!t)throw new Error("Automatic publicPath is not supported in this browser");t=t.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),r.p=t})(),(()=>{var t={"connatix.player":0,player:0};r.f.j=(i,e)=>{var s=r.o(t,i)?t[i]:void 0;if(0!==s)if(s)e.push(s[2]);else{var n=new Promise(((e,n)=>s=t[i]=[e,n]));e.push(s[2]=n);var o=r.p+r.u(i),h=new Error;r.l(o,(e=>{if(r.o(t,i)&&(0!==(s=t[i])&&(t[i]=void 0),s)){var n=e&&("load"===e.type?"missing":e.type),o=e&&e.target&&e.target.src;h.message="Loading chunk "+i+" failed.\n("+n+": "+o+")",h.name="ChunkLoadError",h.type=n,h.request=o,s[1](h)}}),"chunk-"+i,i)}},r.O.j=i=>0===t[i];var i=(i,e)=>{var s,n,[o,h,a]=e,c=0;if(o.some((i=>0!==t[i]))){for(s in h)r.o(h,s)&&(r.m[s]=h[s]);if(a)var d=a(r)}for(i&&i(e);c<o.length;c++)n=o[c],r.o(t,n)&&t[n]&&t[n][0](),t[n]=0;return r.O(d)},e=self.cnx_webpack_global=self.cnx_webpack_global||[];e.forEach(i.bind(null,0)),e.push=i.bind(null,e.push.bind(e))})();var o={};(()=>{"use strict";var t={};r.r(t);var i=r(9361),e=r(8576),s=r(4798);class n{static getConnectionType(t){if((0,s.$K)(this.CONNECTION_TYPE))return this.CONNECTION_TYPE;const{connection:n}=window.navigator;if(!n)return e.FX.UNKNOWN;const{type:r,effectiveType:o}=n;return r===e._S.ETHERNET?e.FX.ETHERNET:r===e._S.WIFI?e.FX.WIFI:r===e._S.CELLULAR?this.Bu(o):(0,s.$K)(r)||t!==i.VB.Desktop?e.FX.UNKNOWN:e.FX.WIFI}static Bu(t){switch(t){case e.Oc.CELLULAR_2G:case e.Oc.CELLULAR_SLOW_2G:return e.FX.CELLULAR_2G;case e.Oc.CELLULAR_3G:return e.FX.CELLULAR_3G;case e.Oc.CELLULAR_4G:return e.FX.CELLULAR_4G;default:return e.FX.CELLULAR_UNKNOWN}}}r(8660);var o=r(7945),h=r(9791),a=r(51);function c(t){const i=(0,a.Ph)("cnxEnv",(0,h.pE)(window).topFrame.location.href);return(0,s.QM)(i)?`//cd-${i}.${t}`:`//cds.${t}`}function d(t){return`${c(t)}/p/${o.g.version}/`}var l,u=r(3020),p=r(1187);!function(t){t.connatix="connatix.com",t.elements="elements.video"}(l||(l={}));const f=function(t){if(!t||!(0,u.NN)(t))return(0,p.n)({message:"Prerender_Elements_getBundleDomain_no_currentScript",level:p.D.CRITICAL}),null;const i=t.src;return i.includes(l.elements)?l.elements:i.includes(l.connatix)?l.connatix:((0,p.n)({message:"Prerender_Elements_getBundleDomain_unkown_src",level:p.D.CRITICAL}),null)}(window.document.currentScript);r.p=d(f);var m,g=r(4361),v=(r(7175),r(289)),y=r(8049),b=r(6568),I=r(5701),w=r(5227),S=r(5650),P=r(8983),A=r(3802);!function(t){t.Deprecation="deprecation",t.Intervention="intervention",t.Crash="crash"}(m||(m={}));class _{constructor(t,i,e){this.Ci=t,this.Ru=i,this.zc=e,this.Ou=!1,this.wn=!1,this.Du=()=>{"hidden"===this.Ci.document.visibilityState&&this.Vu()},this.Vu=()=>{if(this.Ou||!this.Fu)return;const t=this.Fu.takeRecords();this.Nu(t),this.Ou=!0},this.Nu=t=>{t.filter((({body:t})=>"HeavyAdIntervention"===(null==t?void 0:t.id))).forEach((()=>{const{heavyAdBlockTypeEnum:t,advertiserLineItemId:i}=this.Ru;this.zc.heavyAd.next({type:A.EN.fromProtoHeavyAdType(t),advertiserLineItemId:i})}))},this.Ec()}destroy(){this.wn&&(this.Ci.removeEventListener("pagehide",this.Vu),this.Ci.removeEventListener("visibilitychange",this.Du))}Uu(){return!!this.Ci.ReportingObserver}Ec(){this.Uu()&&(this.wn=!0,this.Fu=new this.Ci.ReportingObserver((t=>{this.Nu(t)}),{buffered:!0,types:[m.Intervention]}),this.Fu.observe(),this.Ci.addEventListener("pagehide",this.Vu),this.Ci.addEventListener("visibilitychange",this.Du))}}var x,T,k,C=r(9710),E=r(9741),M=r(8532),L=r(9906);class B{constructor(){this.Fc={}}on(t,i){if(this.Fc[t]=this.Fc[t]||[],!(0,s.mf)(i))throw new Error(`${t} event callback is not a function`);return this.Fc[t].push(i),()=>this.Fc[t]=this.Fc[t].filter((t=>t!==i))}once(t,i){const e=this.on(t,(t=>{try{i(t)}catch(t){}e()}))}remove(t,i){this.Fc[t]&&(this.Fc[t]=this.Fc[t].filter((t=>t!==i)))}removeAll(){this.Fc={}}trigger(t,i){this.Fc[t]&&this.Fc[t].forEach((t=>{try{t(i)}catch(t){}}))}}!function(t){t.Fullscreen="fullscreen",t.Normal="normal",t.Thumbnail="thumbnail"}(x||(x={})),function(t){t.AdLoaded="AdLoaded",t.AdStarted="AdStarted",t.AdStopped="AdStopped",t.AdSkipped="AdSkipped",t.AdSkippableStateChange="AdSkippableStateChange",t.AdSizeChange="AdSizeChange",t.AdLinearChange="AdLinearChange",t.AdDurationChange="AdDurationChange",t.AdExpandedChange="AdExpandedChange",t.AdRemainingTimeChange="AdRemainingTimeChange",t.AdVolumeChange="AdVolumeChange",t.AdImpression="AdImpression",t.AdVideoStart="AdVideoStart",t.AdVideoFirstQuartile="AdVideoFirstQuartile",t.AdVideoMidpoint="AdVideoMidpoint",t.AdVideoThirdQuartile="AdVideoThirdQuartile",t.AdVideoComplete="AdVideoComplete",t.AdClickThru="AdClickThru",t.AdInteraction="AdInteraction",t.AdUserAcceptInvitation="AdUserAcceptInvitation",t.AdUserMinimize="AdUserMinimize",t.AdUserClose="AdUserClose",t.AdPaused="AdPaused",t.AdPlaying="AdPlaying",t.AdLog="AdLog",t.AdError="AdError"}(T||(T={})),function(t){t.Timeout="timeout",t.TimeoutLoaded="timeout_loaded",t.ImaError="imaError",t.ImaScriptFailure="imaScriptFailure",t.ImaObjectNotFound="imaObjectNotFound",t.ImaManagerInit="imaManagerInit",t.ImaInitSdkError="initImasdkError",t.ImaLoadInitError="imaLoadInitError",t.ImaCreateWrapperError="imaCreateWrapperError",t.ImaInitWrapperError="imaInitWrapperError",t.VastVideoTagEventError="vastVideoTagEventError",t.VastUnsupportedMedia="vastUnsupportedMedia",t.VastPlayPromiseReject="playPromiseReject",t.VastNonLinearImageLoadFailure="nonLinearVastImageLoadFailure",t.AdStopped="adStopped",t.MuteEnforce="muteEnforce",t.VpaidOnLoad="vpaidOnLoad",t.VpaidInvalid="vpaidInvalid",t.VpaidGetVpaidAdError="vpaidGetVpaidAdError",t.CnxMediaNoRenditions="noRenditions",t.CnxMediaSrcNotSupported="srcNotSupported",t.InvalidVpaidEvent="invalidVpaidEvent",t.AdxOverlayNoFill="adxOverlayNoFill",t.AdxOverlayGptScriptLoad="adxOverlayGptScriptLoad",t.DisplayIntegratorIframeLoad="displayIntegratorIframeLoad",t.EnforcementMalware="malwareDetected",t.EnforcementVolume="volumeDetected",t.Cancelled="adManagerRemoved",t.DomainBlocked="domainBlocked",t.AdaptorStartAdError="adaptorStartAdError",t.AdaptorInitAdError="adaptorInitAdError",t.WrapperStartAdError="wrapperStartAdError",t.WrapperInitAdError="wrapperInitAdError",t.NonLinearZeroDimensions="nonLinearzeroDimensions",t.NonLinearImageToLarge="nonLinearImageToLarge",t.NonLinearUnsupportedMedia="nonLinearUnsupportedMedia"}(k||(k={}));const R=T,O=Object.assign(Object.assign({},R),{AdBreakStart:"adBreakStart",AdComplete:"adComplete",AdBreakComplete:"adBreakComplete",Pause:"pause",AdPause:"adPause",Play:"play",AdPlay:"adPlay",ContentComplete:"contentComplete",SessionStart:"sessionStart",SessionEnd:"sessionEnd",PlayerResized:"playerStateResize",OnEnterFullscreen:"onEnterFullscreen",OnExitFullscreen:"onExitFullscreen",PlayerCollapsed:"playerCollapsed",PlayerExpanded:"playerExpanded",PlayError:"playError",RenderError:"renderError",AdStateChange:"adStateChange",VolumeChange:"volumeChange",Destroy:"destroy"});class D{constructor(t=!1){this._debugLogging=t,this.Hu="eventEmitted",this.Fu=new B}subscribe(t){return this.Fu.on(this.Hu,t)}unsubscribe(t){this.Fu.remove(this.Hu,t)}emitSessionStart(t){const i={videoMetadata:t};this.zu({metadata:i,name:O.SessionStart})}emitContentComplete(){this.zu({name:O.ContentComplete})}emitSessionEnd(){this.zu({name:O.SessionEnd})}emitPlay(){this.zu({name:O.Play})}emitPause(){this.zu({name:O.Pause})}emitAdPlay(){this.zu({name:O.AdPlay})}emitAdPause(){this.zu({name:O.AdPause})}emitAdPlaying(t){const i={adType:t};this.zu({name:O.AdPlaying,metadata:i})}emitAdPaused(t){const i={adType:t};this.zu({name:O.AdPaused,metadata:i})}emitAdImpression(t,i,e){const s={adMetadata:t,customAdMetadata:i,adType:e};this.zu({metadata:s,name:O.AdImpression})}emitAdComplete(t){const i={adType:t};this.zu({name:O.AdComplete,metadata:i})}emitAdStopped(t){const i={adType:t};this.zu({name:O.AdStopped,metadata:i})}emitAdBreakStart(t){const i={adBreakMetadata:t};this.zu({metadata:i,name:O.AdBreakStart})}emitAdBreakComplete(t){const i={adType:t};this.zu({name:O.AdBreakComplete,metadata:i})}emitPlayerResized(t){const i={playerDimensionsMetadata:t};this.zu({metadata:i,name:O.PlayerResized})}emitOnEnterFullscreen(){this.zu({name:O.OnEnterFullscreen})}emitOnExitFullscreen(){this.zu({name:O.OnExitFullscreen})}emitOnPlayerCollapsed(){this.zu({name:O.PlayerCollapsed})}emitOnPlayerExpanded(t){const i={playerDimensionsMetadata:t};this.zu({name:O.PlayerExpanded,metadata:i})}emitAdExpandedChange(t){const i={adType:t};this.zu({name:O.AdExpandedChange,metadata:i})}emitAdError(t){const i={adType:t};this.zu({name:O.AdError,metadata:i})}emitPlayError(){this.zu({name:O.PlayError})}emitRenderError(){this.zu({name:O.RenderError})}emitAdClickThru(t){const i={adType:t};this.zu({name:O.AdClickThru,metadata:i})}emitAdInteraction(t){const i={adType:t};this.zu({name:O.AdInteraction,metadata:i})}emitAdVideoStart(t,i){const e={adVideoStartMetadata:t,adType:i};this.zu({metadata:e,name:O.AdVideoStart})}emitAdLoaded(t,i){const e={adLoadedMetadata:t,adType:i};this.Wu=t,this.zu({metadata:e,name:O.AdLoaded})}emitAdStateChange(t,i){const e={adStateChangedMetadata:t,adType:i};this.Gu=t,this.zu({metadata:e,name:O.AdStateChange})}emitAdVideoFirstQuartile(t){const i={adType:t};this.zu({name:O.AdVideoFirstQuartile,metadata:i})}emitAdVideoMidpoint(t){const i={adType:t};this.zu({name:O.AdVideoMidpoint,metadata:i})}emitAdVideoThirdQuartile(t){const i={adType:t};this.zu({name:O.AdVideoThirdQuartile,metadata:i})}emitAdVideoComplete(t){const i={adType:t};this.zu({name:O.AdVideoComplete,metadata:i})}emitVolumeChange(t){this.zu({name:O.VolumeChange,metadata:{volume:t}})}emitAdVolumeChange(t){const i={adType:t};this.zu({name:O.AdVolumeChange,metadata:i})}emitAdSkipped(t){const i={adType:t};this.zu({name:O.AdSkipped,metadata:i})}zu(t){var i;(null===(i=null==t?void 0:t.metadata)||void 0===i?void 0:i.adType)!==v.ProtoAdType.Nonlinear&&(this._debugLogging&&console.log("Connatix Player Elements debugging: ",t),this.Fu.trigger(this.Hu,t))}get adLoadedMetadata(){return this.Wu}get adStateMetadata(){return this.Gu}destroy(){this.zu({name:O.Destroy}),this.Fu.removeAll()}}var V;!function(t){t[t.OnAdLoaded=0]="OnAdLoaded",t[t.OnAdSessionStart=1]="OnAdSessionStart"}(V||(V={}));const F="Connatix",N="1.4.2";var j,$,U,q,H,z,W,G,X;!function(t){t.Generic="generic",t.Video="video"}(j||(j={})),function(t){t.Click="click",t.InvitationAccept="invitationAccept"}($||($={})),function(t){t.PreRoll="preroll",t.MidRoll="midroll",t.PostRoll="postroll",t.Standalone="standalone"}(U||(U={})),function(t){t.SessionStart="sessionStart",t.SessionError="sessionError",t.SessionFinish="sessionFinish"}(q||(q={})),function(t){t.DefinedByJavascript="definedByJavaScript",t.BeginToRender="beginToRender"}(H||(H={})),function(t){t.DefinedByJavascript="definedByJavaScript",t.Video="video"}(z||(z={})),function(t){t.sessionError="sessionError",t.geometryChange="geometryChange"}(W||(W={})),function(t){t.notFound="notFound",t.hidden="hidden",t.viewport="viewport",t.backgrounded="backgrounded",t.obstructed="obstructed",t.clipped="clipped"}(G||(G={})),function(t){t.Minimized="minimized",t.Collapsed="collapsed",t.Normal="normal",t.Expanded="expanded",t.Fullscreen="fullscreen"}(X||(X={}));var Q,J=r(6716);class Y{constructor(){this.Xu=new J.x}computeState(t){const i=this.Qu(t);this.Ju&&this.Ju!==i&&this.Ju!==X.Fullscreen&&this.Xu.next(i),this.Ju=i,this.Yu||i!==X.Normal||(this.Yu={name:i,dimensions:t,area:t.height*t.width})}setPlayerState(t,i){this.Ju&&this.Ju!==t&&!i&&this.Xu.next(t),this.Ju=t}get playerStateChanged(){return this.Xu.asObservable()}get currentState(){return this.Ju}Qu(t){if(!this.Yu)return X.Normal;const{area:i}=this.Yu,e=t.width*t.height;switch(!0){case e===i:return X.Normal;case 0===e:return X.Minimized;case i<e:return X.Expanded;case i>e:return X.Collapsed;default:return this.Ju}}}!function(t){t[t.PreRoll=0]="PreRoll",t[t.MidRoll=1]="MidRoll",t[t.PostRoll=2]="PostRoll",t[t.Standalone=3]="Standalone"}(Q||(Q={}));const K={[v.ProtoAdSlotsEnum.PreRoll]:Q.PreRoll,[v.ProtoAdSlotsEnum.MidRoll]:Q.MidRoll,[v.ProtoAdSlotsEnum.PostRoll]:Q.PostRoll};var Z,tt,it=r(9600),et=r(3);class st{constructor(t,i,e,s,n,r){this.Ku=t,this.As=i,this.Zu=e,this.zc=s,this.Td=n,this.ep=r,this.sp=new J.x,this.np=new et.t,this.Fc=[],this.rp=!0,this.op={[O.AdError]:()=>this.ap(),[O.AdImpression]:()=>this.dp(),[O.AdVideoStart]:t=>this.lp(null==t?void 0:t.adVideoStartMetadata),[O.AdVideoFirstQuartile]:()=>this.up(),[O.AdVideoMidpoint]:()=>this.pp(),[O.AdVideoThirdQuartile]:()=>this.fp(),[O.AdVideoComplete]:()=>this.mp(),[O.VolumeChange]:t=>this.gp(null==t?void 0:t.volume),[O.AdPause]:()=>this.vp(),[O.AdPlay]:()=>this.yp(),[O.AdSkipped]:()=>this.bp(),[O.AdClickThru]:()=>this.wp(),[O.AdInteraction]:()=>this.Sp(),[O.AdExpandedChange]:()=>this.Pp(),[O.AdLoaded]:t=>this.Ap(null==t?void 0:t.adLoadedMetadata),[O.PlayerResized]:t=>this._p(null==t?void 0:t.playerDimensionsMetadata),[O.OnEnterFullscreen]:()=>this.xp(),[O.OnExitFullscreen]:()=>this.kp(),[O.PlayerCollapsed]:()=>this.Cp(),[O.PlayerExpanded]:t=>this._p(null==t?void 0:t.playerDimensionsMetadata),[O.AdStopped]:()=>this.Ep(),[O.Destroy]:()=>this.destroy()},this.Mp=t=>{try{const i=this.op[t.name];if(!i)return;i(t.metadata)}catch(t){(0,p.n)({message:"SessionClientWrapper_omsdk__onEventStorageEvent",exception:t?JSON.stringify(t):void 0,level:p.D.WARN})}},this.Lp=new Y,this.Op(),this.As.subscribe(this.Mp),this.Fc.push(this.Lp.playerStateChanged.subscribe((t=>{this.Dp(t)}))),this.Ap(this.As.adLoadedMetadata)}get adSessionFinished(){return this.sp.asObservable()}get adSessionStart(){return this.np.asObservable()}destroy(){this.zc=null,this.Td=null,this.Zu=null,this.As.unsubscribe(this.Mp),(0,it.i)(this.Fc)}Dp(t){var i;t&&(null===(i=this.Td)||void 0===i||i.playerStateChange(t))}Ep(){this.sp.next()}ap(){var t;null===(t=this.Zu)||void 0===t||t.error(j.Video,O.AdError),this.sp.next()}dp(){var t;null===(t=this.zc)||void 0===t||t.impressionOccurred();const i=this.Lp.currentState;i!==X.Normal&&this.Dp(i)}lp(t){var i;t&&(0,s.hj)(null==t?void 0:t.duration)&&(0,s.hj)(null==t?void 0:t.mediaPlayerVolume)?(this.Vp(t.mediaPlayerDimensions),null===(i=this.Td)||void 0===i||i.start(t.duration,t.mediaPlayerVolume)):(0,p.n)({message:"OmidVideoHandler_mediaEvent_start",level:p.D.WARN})}up(){var t;null===(t=this.Td)||void 0===t||t.firstQuartile()}pp(){var t;null===(t=this.Td)||void 0===t||t.midpoint()}fp(){var t;null===(t=this.Td)||void 0===t||t.thirdQuartile()}mp(){var t;null===(t=this.Td)||void 0===t||t.complete()}gp(t){var i;(0,s.hj)(t)?null===(i=this.Td)||void 0===i||i.volumeChange(t):(0,p.n)({message:"OmidVideoHandler_mediaEvent_volume",level:p.D.WARN})}vp(){var t;null===(t=this.Td)||void 0===t||t.pause()}yp(){var t;null===(t=this.Td)||void 0===t||t.resume()}bp(){var t;null===(t=this.Td)||void 0===t||t.skipped(),this.sp.next()}wp(){var t;null===(t=this.Td)||void 0===t||t.adUserInteraction($.Click)}Sp(){var t;null===(t=this.Td)||void 0===t||t.adUserInteraction($.InvitationAccept)}Pp(){var t;null===(t=this.Td)||void 0===t||t.adUserInteraction($.InvitationAccept)}Ap(t){var i;if(!this.As.adStateMetadata)return void(0,p.n)({message:"OmidVideoHandler_adStateChangedMetadata.state",level:p.D.WARN});const e=new Map([[Q.MidRoll,U.MidRoll],[Q.PostRoll,U.PostRoll],[Q.PreRoll,U.PreRoll],[Q.Standalone,U.Standalone]]);this.Fp=new this.Ku.VastProperties(null==t?void 0:t.isSkippable,null==t?void 0:t.skipOffset,null==t?void 0:t.isAutoPlay,e.get(this.As.adStateMetadata.state)),this.ep===V.OnAdLoaded&&(null===(i=this.zc)||void 0===i||i.loaded(this.Fp))}_p(t){t?this.Vp({height:t.height,width:t.width}):(0,p.n)({message:"OmidVideoHandler_playerDimensionsMetadata",level:p.D.WARN})}xp(){this.Np(X.Fullscreen)}kp(){this.Np(X.Fullscreen,this.rp)}Cp(){this.Np(X.Minimized)}Vp(t){(0,s.hj)(t.width)&&(0,s.hj)(t.height)&&t&&this.Lp.computeState(t)}Np(t,i=!1){this.Lp.setPlayerState(t,i)}Op(){var t;null===(t=this.Zu)||void 0===t||t.registerSessionObserver((t=>{t.type===q.SessionStart?this.jp(t):t.type===q.SessionError&&(0,p.n)({message:"SessionClientWrapper_omsdk_session_error",exception:t.type,callStack:JSON.stringify(t),level:p.D.WARN},{throttle:1,shouldSendMaxLog:!1})}))}jp(t){var i,e,s;t.data.impressionType===H.DefinedByJavascript&&(null===(i=this.Zu)||void 0===i||i.setImpressionType(H.BeginToRender)),t.data.creativeType===z.DefinedByJavascript&&(null===(e=this.Zu)||void 0===e||e.setCreativeType(z.Video)),this.Fp&&this.ep===V.OnAdSessionStart&&(null===(s=this.zc)||void 0===s||s.loaded(this.Fp)),this.np.next()}}!function(t){t.Full="full"}(Z||(Z={})),function(t){const i={sessionClient:["1.4.2-iab3703","1.3.25-iab3167","1.3.13-iab2343"],verificationClient:["1.4.2-iab3703","1.3.25-iab3167","1.3.13-iab2343"]};function e(t,i){if(!t)return;let e=null;for(let s=0;s<i.length&&(e=t[i[s]],!e);s++);return e}t.getSessionClient=function(t){if(t)return e(t.OmidSessionClient,i.sessionClient)},t.getVerificationClient=function(t){return e(t.OmidVerificationClient,i.verificationClient)},t.getVerificationScriptResources=function(t,i){return t.map((t=>{const{javaScriptResource:e,vendor:s,verificationParameters:n}=t;return new i.VerificationScriptResource(e,s,n,Z.Full)}))}}(tt||(tt={}));var nt=r(9725);class rt{constructor(t){this.$p=t,this.qp=window,this.zp=!1,this.Wp=new J.x,this.Gp=new J.x,this.zp=nt.$.shouldUseOmsdkForAds(this.$p)}get omidAdSessionStart(){return this.Wp.asObservable()}get omidAdSessionFinish(){return this.Gp.asObservable()}isSupported(){return this.zp}getOMSDKVersion(){return this.$p}getLoadingStrategy(){return V.OnAdSessionStart}getServiceWindow(){return this.qp}startSession(){this.Wp.next()}finishSession(){this.Gp.next()}resetSession(){this.Wp.next()}finishPlayerSession(){return new Promise((t=>{this.Gp.next(),setTimeout((()=>{t()}),1e3)}))}createPartner(t){this.Xp=new t.Partner(F,this.$p)}createNewContext(t,i){if(this.Xp)return new t.Context(this.Xp,i);(0,p.n)({message:"OmsdkInAppImplementation_no_partner",level:p.D.WARN})}}var ot=r(8659),ht=r(6661),at=r(6515),ct=(0,r(1819).d)((function(t){return function(){t(this),this.name="EmptyError",this.message="no elements in sequence"}})),dt=r(4975),lt=r(89),ut=r(6798),pt=r(2566);function ft(){return new ct}var mt=r(278);function gt(t,i){var e=arguments.length>=2;return function(s){return s.pipe(t?(0,dt.h)((function(i,e){return t(i,e,s)})):mt.y,(0,lt.q)(1),e?function(t){return(0,ut.e)((function(i,e){var s=!1;i.subscribe((0,pt.x)(e,(function(t){s=!0,e.next(t)}),(function(){s||e.next(t),e.complete()})))}))}(i):(void 0===(n=function(){return new ct})&&(n=ft),(0,ut.e)((function(t,i){var e=!1;t.subscribe((0,pt.x)(i,(function(t){e=!0,i.next(t)}),(function(){return e?i.complete():i.error(n())})))}))));var n}}var vt=r(5204);const yt="cnxProxyTask",bt=`\n    window.${yt} = function(task) {\n        setTimeout(function(){\n            task();\n        }, 0);\n    }\n`;class It{static executeAsync(t,i){this.Qp(t)(i)}static Jp(t){return!!t[yt]}static Qp(t){return this.Jp(t)||this.Yp(t),t[yt]}static Yp(t){const i=t.document.head;(0,u.ML)(i,t,bt)}}var wt,St,Pt;!function(t){t.absolute="absolute",t.relative="relative"}(wt||(wt={})),function(t){t.auto="auto",t.all="all"}(St||(St={})),function(t){t.errorIframe="Error creating iframe"}(Pt||(Pt={}));class At{constructor(t,i,e){this.yn=t,this.Zp=i,this.Mo=e}tf(t,i,e){let s=!1;return n=>{n.contentWindow&&!s&&(s=!0,this.if(n,this.ef(t,i),e))}}sf(t,i,e,s,n,r,o,h,a,c,d=!0,l=""){return this.nf(t,this.tf(i,e,s),n,r,o,h,a,c,d,l)}nf(t,i,e=wt.absolute,n=St.auto,r,o,h,a,c=!0,d=""){const l=this.yn.createElement("iframe",h);let p="100%",f="100%";return(null==a?void 0:a.scalable)?(p=a.scalable.maxHeightPercent+"%",f=a.scalable.maxWidthPercent+"%"):(null==a?void 0:a.width)&&(null==a?void 0:a.height)&&(p=a.height+"px",f=a.width+"px"),(0,s.QM)(d)&&(0,u.cn)(l,d),r&&(l.title=r),l.allow="autoplay",l.src="javascript:false",l.srcdoc="",l.width=f,l.height=p,l.style.position=e,l.style.left="0",l.style.top="0",l.style.margin="0px",l.style.padding="0px",l.style.border="0px",l.style.width=f,l.style.height=p,l.style.pointerEvents=n,c||(l.style.display="none"),l.setAttribute("SCROLLING","NO"),null==o||o.forEach((t=>{l.setAttribute(t.key,t.value)})),l.onload=()=>{i(l)},t.appendChild(l),i(l),l}if(t,i,e){const s=(0,u.LT)(t);It.executeAsync(s,(()=>{try{const e=t.contentWindow&&t.contentWindow.document;e.open(),e.write(i)}catch(i){this.rf(t,i),t=null}e(t)}))}ef(t,i){return Object.keys(i).forEach((function(e){const s="object"==typeof i[e]?JSON.stringify(i[e]):i[e];t=t.replace(new RegExp(`{{${e}}}`,"g"),s)})),t}loadIframe(t){const i='<!DOCTYPE html><html lang="en"><head>'+(t.customHead?t.customHead:"")+'<meta charset="UTF-8"></head><body style="margin:0;padding:0">'+(t.customHtml?t.customHtml:"")+'<script type="text/javascript">window.postMessage(\'{"event": "ready", "id": "{{iframeID}}"}\', \'*\');<\/script></body></html>',e="cnx-iframe_"+(0,h.qs)();return new Promise(((s,n)=>{const r=i=>{if(null===i)return void n(Pt.errorIframe);const r=t=>{let o;try{o=JSON.parse(t.data)}catch(t){return}o.id===e&&(i.contentWindow?(i.contentWindow.document.close(),i.contentWindow.removeEventListener("message",r),s({iframe:i})):n("The Iframe is no longer in the DOM"))};try{if(i.contentWindow.addEventListener("message",r),!t.customReportingLog)return;const{advertiserLineItemId:e,heavyAdBlockTypeEnum:s}=t.customReportingLog,n=L.h.getSessionChildContainer(this.Zp).resolve(vt.k);this.hf=new _(this.af.contentWindow,{advertiserLineItemId:e,heavyAdBlockTypeEnum:s},n)}catch(t){this.rf(i,t),n("Iframe callback error")}};try{this.af=this.sf(t.container,i,{iframeID:e},r,t.iframePosition,t.iframePointerEvents,t.title,t.customIframeAttributes,this.Mo,t.iframeCustomDimensions,t.visible,t.iframeClass)}catch(t){(0,p.n)({message:"IframeLoader_error_creating_iframe",level:p.D.WARN,exception:t.message,callStack:t.stack})}}))}get iframe(){return this.af}destroy(){var t;null===(t=this.hf)||void 0===t||t.destroy(),this.af=null}rf(t,i){this.yn.isDetachedFromDOM(t)?(0,p.n)({message:"iframeLoader_(inDom_false)",exception:i.message,callStack:i.stack,level:p.D.WARN},{shouldSendMaxLog:!1,throttle:1}):(0,p.n)({message:"iframeLoader_(inDom_true)",exception:i.message,callStack:i.stack,level:p.D.WARN},{shouldSendMaxLog:!1,throttle:1}),(0,u.bX)(t)}}var _t=r(6153);class xt{constructor(t,i,e,s,n){this.Rs=t,this.Zp=i,this.cf=e,this.df=s,this.ol=n,this.isSupported()&&this.lf()}getOMSDKVersion(){return N}isSupported(){return!this.cf&&!this.df}getServiceWindow(){return this.qp}getLoadingStrategy(){return V.OnAdLoaded}startSession(t){null==t||t.setCreativeType(z.Video),null==t||t.setImpressionType(H.BeginToRender),null==t||t.start()}finishSession(t){null==t||t.finish()}finishPlayerSession(){return Promise.resolve()}createPartner(t){this.Xp=new t.Partner(F,N)}createNewContext(t,i){if(this.Xp)return new t.Context(this.Xp,i,this.Rs);(0,p.n)({message:"OmsdkWebImplementation_no_partner",level:p.D.WARN})}lf(){const t=`<script id='omsdk-connatix-webservice-script' type='text/javascript'\n            src='${_t.n.endPoints.assets.plugins.omsdkWebService}'><\/script>`;this.uf=new At(this.ol,this.Zp);const i={container:window.document.body,customHtml:t,customIframeAttributes:[{key:"style",value:"display: none;"}]};this.uf.loadIframe(i).then((()=>{var t,i;this.qp=null===(i=null===(t=this.uf)||void 0===t?void 0:t.iframe.contentWindow)||void 0===i?void 0:i.window})).catch((()=>{(0,p.n)({message:"OMSDKService_error_loading_WebServiceIframe",level:p.D.WARN})}))}}r(7129);var Tt,kt,Ct,Et,Mt=r(5687),Lt=r(9357),Bt=r(6578),Rt=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o},Ot=function(t,i){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,i)},Dt=function(t,i){return function(e,s){i(e,s,t)}},Vt=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};let Ft=Tt=class{constructor(t,i,e){var s,n;this.As=t,this.ol=i,this.pf=e,this.Wp=new J.x,this.Gp=new J.x,this.ff=new at.X(!1),this.gf=new at.X(!1),this.vf=new J.x,this.Fc=[],this.pf.isInAppSdk?(this.yf=new rt(this.pf.sdkVersion),null===(s=this.yf.omidAdSessionStart)||void 0===s||s.subscribe((()=>{this.Wp.next()})),null===(n=this.yf.omidAdSessionFinish)||void 0===n||n.subscribe((()=>{this.Gp.next()}))):this.yf=new xt(this.pf.pageUrl,this.pf.sessionId,this.pf.isInApp,this.pf.isGam,this.ol),this.isOmsdkFullSupport&&this.bf()}get isOmsdkFullSupport(){return this.yf.isSupported()}get omsdkVersion(){return this.yf.getOMSDKVersion()}get omidAdSessionStart(){return this.Wp.asObservable()}get omidAdSessionFinish(){return this.Gp.asObservable()}get omidResourcesReady(){return this.ff.asObservable()}get verificationNotExecuted(){return this.vf.asObservable()}get qp(){return this.yf.getServiceWindow()}static If(t){const i=t.replace(/\[reason\]/i,"1");Bt.n.trackPixel(i)}clearPendingProcesses(){(0,it.i)(this.Fc),this.Fc=[],this.ff.next(!1)}addVerificationNode(t,i){this.clearPendingProcesses();const e=this.gf.asObservable().pipe(gt((t=>t))).subscribe((()=>{this.gf.next(!1),this.wf().then((()=>this.Sf(t,i))).then((()=>{this.ff.next(!0)})).catch((()=>{this.Pf(t)}))}));this.Fc.push(e)}Pf(t){t.forEach((t=>{(0,s.$K)(t.trackingEvents)&&(0,S.BZ)(t.trackingEvents)&&t.trackingEvents.filter((t=>"verificationNotExecuted"===t.name)).forEach((t=>{Tt.If(t.uri),this.vf.next()}))})),(0,p.n)({message:"OMSDKService_verification_not_executed",level:p.D.INFO},{throttle:1,shouldSendMaxLog:!1}),this.ff.next(!0)}Sf(t,i){return Vt(this,void 0,void 0,(function*(){if(!(0,s.$K)(this.Ku))throw(0,p.n)({message:"OMSDKService_no_client",level:p.D.WARN}),new Error("noOmidClient");this.yf.createPartner(this.Ku);const e=tt.getVerificationScriptResources(t,this.Ku);if(this.bo=this.yf.createNewContext(this.Ku,e),!this.bo)throw(0,p.n)({message:"OMSDKService_no_context",level:p.D.WARN}),new Error("noOmidContext");if(this.bo.setVideoElement(i.videoSlot),this.bo.setSlotElement(i.slot),!this.qp)throw(0,p.n)({message:"OMSDKService_no_service_window",level:p.D.WARN}),new Error("noServiceWindow");this.bo.setServiceWindow(this.qp);const n=new this.Ku.AdSession(this.bo),r=new this.Ku.AdEvents(n),o=new this.Ku.MediaEvents(n);if(!n||!r||!o)throw(0,p.n)({message:"OMSDKService_cant_start_omid_events",exception:`adSession:${!!n}_adEvents:${!!r}_mediaEvents:${!!o}`,level:p.D.WARN}),new Error("noOmidEvents");this.yf.startSession(n),this.Af=new st(this.Ku,this.As,n,r,o,this.yf.getLoadingStrategy()),this.Af.adSessionFinished.subscribe((()=>{var t;this.ff.next(!1),this.gf.next(!1),this.yf.finishSession(n),null===(t=this.Af)||void 0===t||t.destroy(),this.Af=null,this._f()}));const h=new Promise((t=>{var i;null===(i=this.Af)||void 0===i||i.adSessionStart.subscribe((()=>{t()}))}));return h}))}wf(){return this.yf.finishPlayerSession()}_f(){setTimeout((()=>{var t,i;this.xf(),this.bf(),null===(i=(t=this.yf).resetSession)||void 0===i||i.call(t)}),Lt.s_)}Tf(){var t,i;this.Ku=tt.getSessionClient(null===(i=null===(t=this.kf)||void 0===t?void 0:t.iframe.contentWindow)||void 0===i?void 0:i.window),this.Ku||(0,p.n)({message:"OMSDKService_no_session_client",level:p.D.INFO})}bf(){const t=`<script id='omsdk-connatix-client-script' type='text/javascript' src='${_t.n.endPoints.assets.plugins.omsdkSessionClient}'><\/script>`;this.gf.next(!1),this.kf=new At(this.ol,this.pf.sessionId);const i={container:window.document.body,customHtml:t,customIframeAttributes:[{key:"style",value:"display: none;"}]};this.kf.loadIframe(i).then((()=>{this.Tf(),this.gf.next(!0)})).catch((()=>{(0,p.n)({message:"OMSDKService_error_loading_SessionClientIframe",level:p.D.WARN})}))}xf(){var t,i,e,s;null===(i=null===(t=this.kf)||void 0===t?void 0:t.iframe.parentElement)||void 0===i||i.removeChild(null===(e=this.kf)||void 0===e?void 0:e.iframe),null===(s=this.kf)||void 0===s||s.destroy(),this.kf=null}};Ft=Tt=Rt([(0,ot.b2)(),(0,ot.Yn)(ot.Fw.ContainerScoped),Dt(0,(0,ot.f3)(ht.c.EventsStorageService)),Dt(1,(0,ot.f3)(ht.c.GlobalDomUtilsService)),Dt(2,(0,ot.f3)(ht.c.OmidSettings)),Ot("design:paramtypes",["function"==typeof(kt=void 0!==D&&D)?kt:Object,"function"==typeof(Ct=void 0!==Mt.m&&Mt.m)?Ct:Object,"function"==typeof(Et=void 0!==t.IOmsdkSettings&&t.IOmsdkSettings)?Et:Object])],Ft);class Nt extends I._{constructor(t,i,e,s,n,r,o,h,a,c,d){super(),this.mediator=t,this.playerModel=i,this.app=e,this.Cf=s,this._appSettings=n,this.Vc=r,this.zc=o,this.Td=h,this.Dc=a,this.Ef=c,this.Mf=d,this.macroElements={player:[]},this.Lf=!1,this.Bf={description:"{{description}}",title:"{{title}}",player:"{{player}}"},this.Rf=null,this.Df=500,this.Fc=[],this.createExperience(i,n),this.Vf=new _(i.global,{heavyAdBlockTypeEnum:v.ProtoHeavyAdBlockTypeEnum.Global},this.zc),this.Ff=new _(window,{heavyAdBlockTypeEnum:v.ProtoHeavyAdBlockTypeEnum.Script},this.zc)}subscribeToEvents(){this.subscribe(w.Uh.Destroy,this.experience,(()=>{this.destroy()})),this.subscribe(w.Uh.CanStart,this.experience,(()=>{this.experience.start()})),this.subscribe(w.Xh.SessionRendered,this.experience,(()=>{this.Cf.wasPlayerReloaded||this.Vc.sessionRendered.next({isBannerBlocked:C._.isBannerBlocked,sdkVersion:this._appSettings.sdkVersion}),this.mediator.publish(this,w.Xh.SessionRendered)})),this.subscribe(w.Xh.SessionView,this.experience,(()=>{this.Cf.wasPlayerInView||(this.Vc.sessionView.next(),this.mediator.publish(this,w.Xh.SessionView))}));const t=L.h.getSessionChildContainer(this.Dc.sessionId).resolve(Ft);this.Fc.push(t.omidAdSessionStart.subscribe((()=>{this.experienceApi.trigger(M.jJ.OmidAdSessionStart)})),t.omidAdSessionFinish.subscribe((()=>{this.experienceApi.trigger(M.jJ.OmidAdSessionFinish)}))),Object.values(this.experience.events).forEach((t=>{this.subscribe(t,this.experience,(i=>{this.experienceApi.trigger(t,i.payload)}))}))}updateMacroContent(t,i){t&&t.forEach((t=>{t.textContent=i}))}ts(){this.playerModel.css&&this.app.services.GlobalDomUtilsService.addCssString(this.playerModel.css,`cnx-custom-css-${this.app.config.appId}`)}Nf(t){return`<cnx>${t}</cnx>`.replace(/{\{([^}]+)}}/g,"<cnx-span>$&</cnx-span>")}jf(){if(this.experienceContainer=this.$f(),this.playerModel.html){const t=this.app.services.GlobalDomUtilsService.createElementByString(this.Nf(this.playerModel.html));this.Uf(t);const i=this.macroElements.player[0];if(!i)throw Error("player macro was not found");i.innerHTML="",i.parentNode.insertBefore(this.experienceContainer,i),i.parentNode.removeChild(i);(0,S.Sz)(t.children).forEach((t=>{this.playerModel.targetContainer.parentNode.insertBefore(t,this.playerModel.targetContainer)}))}else this.playerModel.targetContainer.parentNode.insertBefore(this.experienceContainer,this.playerModel.targetContainer);this.playerModel.targetContainer.parentElement.removeChild(this.playerModel.targetContainer)}$f(){const t=this.app.config.isMobile?P.s6.Mobile:P.s6.Desktop;return this.app.services.GlobalDomUtilsService.createElementByString(`<cnx class="${P.sN.MainContainer} ${t} ${this.qf}" id="${this.app.config.appId}"></cnx>`)}Uf(t){(0,S.Sz)(t.children).forEach((t=>{t.children.length>0&&this.Uf(t),Object.keys(this.Bf).forEach((i=>{const e=this.Bf[i];t.textContent.includes(e)&&this.Hf(i,t)}))}))}Hf(t,i){this.macroElements[t]||(this.macroElements[t]=[]),this.macroElements[t].push(i),i.textContent=""}zf(){null!==this.Rf&&(clearInterval(this.Rf),this.Rf=null)}init(t){this.ts(),this.jf();const i=this.app.config.device;return this.isSupportedBreakpoint(i)?(this.subscribeToEvents(),this.experience.renderExperience(this.playerModel,this.app,this.experienceContainer,(()=>{t()})),this.Rf=setInterval((()=>{this.Lf?this.zf():this.app.services.GlobalDomUtilsService.isDetachedFromDOM(this.experienceContainer)&&(this.destroy(),(0,p.n)({message:"player_removed_from_DOM",level:p.D.INFO}))}),this.Df),!0):(this.destroy(),!1)}getApiMethods(){return this.experienceApi.getApiMethods()}get playerContainer(){return this.experienceContainer}onReady(){return this.experience.onReady()}destroy(){var t;try{E.S.playerDestroyed=!0,this.Lf=!0,this.zf(),null===(t=this.Mf)||void 0===t||t.destroy(),this.app.services.ResizeObserver.destroy(),this.app.services.ViewabilityService.destroy(),this.app.services.InteractionService.destroy(),(0,it.i)(this.Fc),this.Fc=[],this.experienceApi.setDestroyed(),this.unsubscribeAll(this.experience),this.experience&&(this.experience.destroy(),this.experience=null),this.experienceContainer.parentNode&&this.experienceContainer.parentNode.removeChild(this.experienceContainer),this.Vf.destroy(),this.Ff.destroy()}catch(t){(0,p.n)({callStack:t.stack,level:p.D.WARN,message:"Renderer_destroy",exception:t.message})}}}var jt=r(9490);const $t={imageMaxHeight:160,ratioWidth:16,ratioHeight:9};class Ut{constructor(t,i,e,s,n=1200){this.Wf=t,this.Gf=i,this.Qf=e,this.Jf=s,this.Yf=n,this.Kf=null,this.Zf=!1,this.tm=()=>{if(this.im(),!this.Zf&&this.Gf&&this.Gf.linearAdInWin)return this.Zf=!0,void this.nm(this.Yf);this.Wf.startContent()}}destroy(){this.im()}changeState(t){switch(t){case jt.Ez.PrerollState:this.Zf=!1,this.nm(this.Qf);break;case jt.Ez.PostrollState:this.Zf=!1,this.nm(this.Jf);break;default:this.Kf&&this.im()}}setPreRollBreak(t){this.Qf=t}setPostRollBreak(t){this.Jf=t}im(){clearTimeout(this.Kf),this.Kf=null}nm(t){this.im(),this.Kf=setTimeout(this.tm,t)}}var qt,Ht,zt=r(8211),Wt=r(7994);!function(t){t.enter="enterFullscreen",t.exit="exitFullscreen"}(qt||(qt={}));class Gt{constructor(t,i,e){if(this.ol=t,this.gi=e,this.rm=!1,this.om=1e3,this.hm=!0,this.am=new J.x,this.dm=new J.x,this.lm=!1,this.um=()=>{this.rm&&this.pm()},this.fm=t=>{this.rm?null!==this.fullscreenElement?this.pm():this.gm():this.am.next(qt.exit)},this.gm=()=>{this.lm=!1,this.vm.reject(),this.rm=!1,clearTimeout(this.bm)},this.Im=this.ol.hasIosFullscreenBehaviour(e)?i.getElementsByTagName("video")[0]:i,!this.Im)throw new Error("element is missing");try{const t=this.wm();if(null==t)return void(this.hm=!1);this.Pm=t.keys,this.Am=t.name,this._m()}catch(t){this.hm=!1,(0,p.n)({message:"Fullscreen init failed",exception:t.message,callStack:t.stack,level:p.D.CRITICAL})}}wm(){let t;return t=this.ol.hasIosFullscreenBehaviour(this.gi)?this.ol.getFullscreenKeys(this.Im):this.ol.getFullscreenKeys(),t}get fullscreenElement(){return this.ol.getDocumentProperty(this.Pm.fullscreenElement)}get fullscreenEnabled(){return this.ol.getDocumentProperty(this.Pm.fullscreenEnabled)}enterFullScreen(){if(this.hm){this.vm=new Wt.C,this.rm=!0,clearTimeout(this.bm),this.bm=setTimeout(this.gm,this.om);try{this.Im[this.Pm.requestFullscreen]()}catch(t){this.gm()}return this.vm.promise}}exitFullScreen(){try{this.ol.exitFullscreen(this.Pm.exitFullscreen,this.gi===zt.M.Ios?this.Im:void 0)}catch(t){(0,p.n)({message:"fullscreen_exit",exception:t.message,callStack:t.stack,level:p.D.WARN})}this.lm=!1}_m(){this.Am===e.do.Moz||this.Am===e.do.Ms?(this.ol.addEventListenerOnGlobal(this.Pm.fullscreenchange,this.fm),this.ol.addEventListenerOnGlobal(this.Pm.fullscreenerror,this.gm)):(this.Im.addEventListener(this.Pm.fullscreenchange,this.fm),this.Im.addEventListener(this.Pm.fullscreenerror,this.gm)),this.ol.hasIosFullscreenBehaviour(this.gi)&&(this.Im.addEventListener("webkitbeginfullscreen",this.um),this.Im.addEventListener("webkitendfullscreen",this.fm))}Tm(){this.Am===e.do.Moz||this.Am===e.do.Ms?(this.ol.removeEventListenerOnGlobal(this.Pm.fullscreenchange,this.fm),this.ol.removeEventListenerOnGlobal(this.Pm.fullscreenerror,this.gm)):(this.Im.removeEventListener(this.Pm.fullscreenchange,this.fm),this.Im.removeEventListener(this.Pm.fullscreenerror,this.gm)),this.gi===zt.M.Ios&&(this.Im.removeEventListener("webkitbeginfullscreen",this.um),this.Im.removeEventListener("webkitendfullscreen",this.fm))}pm(){this.lm=!0,this.dm.next(qt.enter),this.vm.resolve(),this.rm=!1,clearTimeout(this.bm)}get isFullscreen(){return this.lm}get onFullScreenExit(){return this.am.asObservable()}get onFullScreenEnter(){return this.dm.asObservable()}destroy(){this.isFullscreen&&this.exitFullScreen(),this.Tm(),this.vm&&this.vm.isPending&&this.vm.reject()}}!function(t){t[t.Play=0]="Play",t[t.Pause=1]="Pause"}(Ht||(Ht={}));class Xt{constructor(t,i){switch(this.mediator=t,this.inView=!1,this.km=!1,this.Cm=!1,this.Em=!1,this.Mm=()=>{},i){case v.ProtoPlayerPlaybackModeEnum.Autoplay:this.Lm(this.Bm);break;case v.ProtoPlayerPlaybackModeEnum.ClickToPlay:this.Lm(this.Rm);break;case v.ProtoPlayerPlaybackModeEnum.ScrollToPlay:this.Lm(this.Om)}}Lm(t){this.Mm=()=>{this.km||t.call(this)}}Bm(){this.Em&&!this.Cm&&this.inView&&(this.Cm=!0,this.mediator.publish(this,Ht[Ht.Play]))}Om(){this.Em&&(this.Dm&&(this.Fm=this.volume),this.inView||this.lm&&!this.inView?(this.mediator.publish(this,Ht[Ht.Play],{payload:{volume:this.Fm}}),this.Fm=null):(this.Fm=this.volume,this.mediator.publish(this,Ht[Ht.Pause],{payload:{volume:0}})))}Rm(){}setViewability(t){this.inView=t,this.Mm()}setIsAppBackgrounded(t){this.Dm=t}setSoundVolume(t){this.volume=t}setUserPlayback(t){!this.Cm&&t&&(this.Cm=t),this.km=!t}setCanPlay(t){this.Em=t,this.km||!this.inView&&!this.Cm||this.Mm()}setIsFullscreen(t){this.lm=t}}var Qt,Jt=r(9762),Yt=r(4967);!function(t){t.PreRoll="pre-roll",t.MidRoll="mid-roll",t.PostRoll="post-roll"}(Qt||(Qt={}));const Kt=Qt;var Zt,ti,ii=r(9209);!function(t){t[t.DirectionIn=0]="DirectionIn",t[t.DirectionOut=1]="DirectionOut",t[t.FadeIn=2]="FadeIn"}(Zt||(Zt={})),function(t){t.Float="float",t.Embed="embed"}(ti||(ti={}));const ei=.5;var si,ni,ri;!function(t){t.NoLineItem="No line item",t.MetadataInvalid="Metadata invalid",t.AdAlreadyStarted="Ad already started",t.NoSupportForCreativeType="Only js api defined creatives can be updated",t.AdManagerNotInitialized="Ad manager not initialized",t.Unknown="The line item could not be updated"}(si||(si={})),function(t){t[t.Normal=0]="Normal",t[t.Buzzfeed=1]="Buzzfeed"}(ni||(ni={})),function(t){t[t.None=0]="None",t[t.Portrait=1]="Portrait",t[t.Landscape=2]="Landscape"}(ri||(ri={}));var oi,hi=r(5356);!function(t){t.PARALLEL_CALLS_DEFAULT=5,t.PARALLEL_WINS_DEFAULT=10,t.MAX_WINS_DEFAULT=-1,t.DEFAULT_DESIRED_BITRATE=1,t.REMOVE_BIDS_DEFAULT=!1,t.MID_SESSION_PREFETCH_MINIMUM_TIME=1e4,t.NON_LINEAR_MAX_HEIGHT_PERCENT=20,t.NON_LINEAR_MAX_WIDTH_PERCENT=80,t.DEFAULT_MAX_AD_DURATION=180}(oi||(oi={}));class ai{constructor(t){this.Nm=t,this.jm={breakType:v.ProtoAdBreakTypeEnum.None,currentPodNumber:0,maxAdSlotDuration:0,maxAdPodDuration:0,totalNumberOfAdSlots:0},this.$m=null,this.Um=!1}get adBreaks(){return this.Nm}setNewBreak(t){this.Nm.forEach((i=>{i.types.forEach((e=>{(0,hi.xm)(e,t)&&(this.Um=!(i.numberOfAdSlots<=1),this.jm.currentPodNumber=i.numberOfAdSlots,this.jm.maxAdSlotDuration=i.maxAdSlotDuration,this.jm.maxAdPodDuration=i.maxAdPodDuration,this.jm.totalNumberOfAdSlots=i.numberOfAdSlots)}))}))}adStarted(){this.qm(),0===this.jm.currentPodNumber&&(this.jm.currentPodNumber=this.jm.totalNumberOfAdSlots),this.jm.currentPodNumber--,this.jm.currentPodNumber<=0&&(this.Um=!1)}endPod(){this.qm(),this.jm.currentPodNumber=0,this.Um=!1}enterPodTimeout(t){this.qm(),this.$m=setTimeout((()=>{this.qm(),t()}),jt.Qg)}isInAdPod(){return this.Um}isCurrentBreakInPod(){return this.jm.totalNumberOfAdSlots>1}getMaxAdSlotDuration(){return this.jm.maxAdSlotDuration}getMaxAdPodDuration(){return this.jm.maxAdPodDuration}getMaxAdSlotPossibleDuration(){let t=0;for(let i=0;i<this.Nm.length;i++){if(0===this.Nm[i].maxAdSlotDuration)return 0;t=Math.max(t,this.Nm[i].maxAdSlotDuration)}return t}getCurrentSlotIndex(){return this.jm.totalNumberOfAdSlots-this.jm.currentPodNumber}getNextSlotIndex(){const t=this.getCurrentSlotIndex();return this.jm.totalNumberOfAdSlots>t?t+1:1}getTotalNumberOfSlots(){return this.jm.totalNumberOfAdSlots}isInPodTimeout(){return!!this.$m}getAdBreakState(t){if(!(0,s.$K)(t))return this.Hm();const{adSlotDuration:i,adBreakType:e}=t;return{isAdPodBreak:this.isCurrentBreakInPod(),adPodSlotIndex:this.isCurrentBreakInPod()?this.getNextSlotIndex():0,maxAdDuration:Math.round(this.getMaxAdSlotDuration()/Lt.s_||oi.DEFAULT_MAX_AD_DURATION),remainingAdDuration:Math.round(i/Lt.s_),sessionMaxAdDuration:Math.round(this.getMaxAdSlotPossibleDuration()/Lt.s_),adBreakType:e}}Hm(){let t=v.ProtoAdBreakTypeEnum.MidRoll;this.adBreaks.forEach((i=>{i.types.some((t=>t===v.ProtoAdBreakTypeEnum.PreRoll))&&(t=v.ProtoAdBreakTypeEnum.PreRoll)}));const i=this.getMaxAdSlotDuration();return this.getAdBreakState({adSlotDuration:i,adBreakType:t})}qm(){clearTimeout(this.$m),this.$m=null}}const ci="midRollCapped",di="totalAdBreakDurationExpired",li="enableLinearAds",ui="disableLinearAds",pi="ForceStopAdSlot",fi="ForceStopAdPod",mi="linearAdOpportunity",gi="AdPodRemainingTime",vi="disableNonLinearAds",yi="enableNonLinearAds",bi="disableAdvertising",Ii="enableAdvertising",wi="enterCuePoint",Si="exitCuePoint",Pi="canPrefetchAds";class Ai{constructor(t,i,e,s){this.zm=t,this.Wm=e,this.Gm=this.Xm(i,s)}Xm(t,i){return(0,s.$K)(i)?Object.assign({},t[i]||t[v.ProtoDeviceType.Smartphone]):t}updateWidth(t){const i=this.Qm(t);i!==this.currentBreakpointClass&&((0,u.IV)(this.zm,this.currentBreakpointClass),(0,u.cn)(this.zm,i),this.currentBreakpointClass=i)}Qm(t){switch(!0){case t>=this.Gm.xxl:return this.Wm.Xxl;case t>=this.Gm.xl:return this.Wm.Xl;case t>=this.Gm.lg:return this.Wm.Lg;case t>=this.Gm.md:return this.Wm.Md;case t>=this.Gm.sm:return this.Wm.Sm;case t>=this.Gm.xs:return this.Wm.Xs;default:return this.Wm.Xxs}}}class _i{constructor(t,i,e,s,n,r=0){this.Jm=t,this.ci=i,this.zm=e,this.Ym=s,this.yn=n,this.Zm=r,this.tg=void 0,this.ig=null,this.eg=!1,this.sg=()=>{if(!this.tg||!this.ng)return;const t=this.rg(),i=!!this.ng;this.hg(t,i)},this.ag=()=>{var t;if(this.cg()&&(this.ci.width=null===(t=this.ng)||void 0===t?void 0:t.clientWidth),this.dg(),this.tg){const t=!1,i=this.rg();this.hg(i,t)}},this.dg=()=>{this.ug()?!this.pg||this.tg||this.eg?this.fg():this.gg():this.tg&&this.vg()},this.yg=t=>{if(this.bg(t.propertyName))switch(this.transitionState){case Zt.DirectionIn:this.transitionState=void 0,this.wg();break;case Zt.DirectionOut:this.transitionState=void 0,this.Sg();break;case Zt.FadeIn:this.transitionState=void 0,this.Pg()}},this.Ag=i.floatingScrollPosition}get transitionState(){return this._g}set transitionState(t){this._g===Zt.FadeIn&&this.xg(P.jG.FadeInBase,P.jG.FadeIn),this._g=t}Tg(...t){(0,u.cn)(this.zm,...t)}xg(...t){(0,u.IV)(this.zm,...t)}fg(){this.Ym!==v.ProtoDeviceType.Smartphone&&(this.zm.style.width=`${this.ci.width}px`);let t=this.zm.getBoundingClientRect().width;if(this.ci.isPinnedFloating){const i=.65*t;t=Math.min(i,435)}this.zm.style.height=this.ci.getHeight(t)}kg(){return(0,S.d3)(this.Ym,this.ci.floatingDeviceMode)}Cg(){this.yn.addEventListenerOnGlobal("scroll",this.sg)}Eg(){this.yn.removeEventListenerOnGlobal("scroll",this.sg)}Mg(){this.ng=this.yn.querySelector(this.ci.pageElement),this.ng&&(clearInterval(this.ig),this.ci.width=this.ng.clientWidth,this.dg(),this.Jm.on(this.ng,this.ag))}Bg(){var t,i;const e=null===(t=this.ng)||void 0===t?void 0:t.getBoundingClientRect().top;return this.ci.appendLocation===v.ProtoFloatingAppendLocationEnum.Above?e-this.zm.offsetHeight-this.ci.floatingYAxisPadding:this.ci.appendLocation===v.ProtoFloatingAppendLocationEnum.Below?e+(null===(i=this.ng)||void 0===i?void 0:i.offsetHeight)+this.ci.floatingYAxisPadding:e}Rg(){this.ig=setInterval((()=>{this.Mg()}),500),this.Mg()}cg(){return this.ci.floatingPosition===v.ProtoFloatingFixedPositionMode.Element}bg(t){switch(this.transitionState){case Zt.DirectionIn:case Zt.DirectionOut:if("transform"===t)return!0;break;case Zt.FadeIn:if("opacity"===t)return!0}return!1}Og(){this.zm.style.top="",this.zm.style.bottom="",this.zm.style.left="",this.zm.style.right="",this.zm.style.width="",this.zm.style.height="",this.zm.style.transform="",this.yn.cancelRequestAnimationFrame(this.Dg)}Sg(){this.tg=!1,this.xg(P._7.MainClass,P._7.TransitionClass),this.Og(),this.Vg()}hg({x:t,y:i},e){this.Fg(e);const s=()=>this.zm.style.transform=`translate(${t}px, ${i}px)`;e?(this.yn.cancelRequestAnimationFrame(this.Dg),this.Dg=null,this.Dg=this.yn.requestAnimationFrameHelper((()=>{s()}))):s()}Fg(t){this.ci.hasFloatingTransition&&(t?this.Tg(P._7.TransitionClass):this.xg(P._7.TransitionClass))}rg(){let t,i;if(this.cg()&&this.ng){this.jg();const e=this.ci.isPositionedLeft?this.ci.floatingGutterX:-this.ci.floatingGutterX;t=this.yn.getElementCoordinates(this.ng).clientX+e;const s=this.Bg();return i=s<this.ci.floatingGutterY?this.ci.floatingGutterY:s,{x:t,y:i}}if(this.ci.isPinnedFloating)t=0,i=this.ci.isPositionedPinnedTop?this.ci.floatingGutterY:-this.ci.floatingGutterY;else{if(this.ci.isPositionedLeft)t=this.ci.floatingGutterX;else{t=this.yn.getViewportWidth()-this.zm.offsetWidth-this.ci.floatingGutterX}if(this.ci.isPositionedTop)i=this.ci.floatingGutterY;else{i=this.yn.getViewportHeight()-this.zm.offsetHeight-this.ci.floatingGutterY}}return{x:t,y:i}}$g(){const t=(this.ci.floatingWidth||1e3)+20,i=this.yn.getViewportWidth();return this.ci.isPositionedLeft?-t:i+t}ug(){return(0,u.LT)(this.zm).document.body.getBoundingClientRect().width>=this.Zm}gg(){if(!this.Ug())return;this.cg()&&this.Cg(),this.tg=!0,this.transitionState=Zt.DirectionIn,this.Tg(P._7.MainClass),this.fg(),this.addPinnedCssClasses();const t=this.rg(),i=this.$g();this.qg(),this.hg({x:i,y:t.y},!1),(0,u.Tp)(this.zm);this.hg(t,!0)}addPinnedCssClasses(){this.xg(P._7.PinnedFloating),this.xg(P._7.PinnedTopFloating),this.xg(P._7.PinnedBottomFloating),this.ci.isPinnedFloating&&(this.Tg(P._7.PinnedFloating),this.Tg(this.Ag===v.ProtoPositionMode.PinnedTop?P._7.PinnedTopFloating:P._7.PinnedBottomFloating))}Ug(){return!!this.ug()&&!(this.cg()&&(!this.ng||this.ng&&0===this.ng.clientWidth))}jg(){this.ng&&(this.yn.getElementCoordinates(this.ng).clientX<this.yn.getBodyDimensions().width/2?(this.ci.isPositionedLeft=!0,this.ci.isPositionedRight=!1):(this.ci.isPositionedLeft=!1,this.ci.isPositionedRight=!0))}vg(t=!0){t&&(this.transitionState=Zt.DirectionOut),this.cg()&&this.Eg(),this.Hg();const{y:i}=this.rg(),e=this.$g();this.hg({y:i,x:e},t),t||this.Sg()}zg(){this.zm.addEventListener("transitionend",this.yg),this.ci.hasFloatingTransition||this.Tg(P._7.InstantTransitionClass);const t=this.yn.getGlobalClosestTop().topFrame;this.Jm.on(this.zm,this.dg),this.Jm.on(t.document.body,this.ag),t.addEventListener("resize",this.ag),this.cg()&&this.Rg()}Wg(){this.Jm.off(this.zm,this.dg),this.zm.removeEventListener("transitionend",this.yg);const t=this.yn.getGlobalClosestTop().topFrame;this.Jm.off(t.document.body,this.ag),t.removeEventListener("resize",this.ag),this.ng&&(this.Jm.off(this.ng,this.ag),this.Eg(),clearInterval(this.ig))}Xg(t){this.Ag=t.scrollPosition,this.addPinnedCssClasses(),void 0!==t.scrollPosition&&(this.ci.setScrollPosition(t.scrollPosition),this.ci.isPositionedPinnedBottom||this.ci.isPositionedPinnedTop?this.ci.setExtraHeight(0):this.ci.setExtraHeight(this.ci.cachedExtraHeight)),(null==t?void 0:t.floatingWidth)&&(this.ci.width=t.floatingWidth),(null==t?void 0:t.floatingGutterX)&&(this.ci.gutterX=t.floatingGutterX),(null==t?void 0:t.floatingGutterY)&&(this.ci.gutterY=t.floatingGutterY)}getFloatingSettings(){return this.ci.getFloatingSettings()}get isInFloating(){return this.tg}get scrollPosition(){return this.Ag}}class xi extends _i{constructor(t,i,e,s,n,r=0){super(t,e,i,s,n,r),this.pg=!0,this.Jg=new J.x}get onFloatingEnterStop(){return this.Jg.asObservable()}qg(){}wg(){this.Jg.next()}Hg(){}Vg(){}Pg(){}start(){this.kg()&&(this.Tg(P._7.AlwaysFloating),super.zg(),super.gg())}setFloatingSettings(t){this.Xg(t),this.start()}getFloatingSettings(){return super.getFloatingSettings()}}class Ti extends _i{constructor(t,i,e,s,n,r,o,h=0){super(e,n,s,r,o,h),this.Yg=t,this.Dc=i,this.Kg=!0,this.Zg=!0,this.tv=!0,this.sv=!1,this.nv=!1,this.pg=!1,this.rv=new J.x,this.Jg=new J.x,this.ov=new J.x,this.hv=new J.x,this.av=t=>{const i=this.Dc.isPageInFocus;t&&this.isInFloating&&(this.pg=!1,this.vg()),this.Kg&&this.ci.floatingMode===v.ProtoPlayerFloatingMode.AfterInView&&t&&(this.Kg=!1),!t&&!this.Kg&&this.Zg&&i&&(this.pg=!0,super.gg())},this.fg=()=>{this.isInFloating&&super.fg()}}get onFloatingEnterStart(){return this.rv.asObservable()}get onFloatingEnterStop(){return this.Jg.asObservable()}get onFloatingExitStart(){return this.ov.asObservable()}get onFloatingExitStop(){return this.hv.asObservable()}isFloatingModeEnabled(){return this.Kg&&(this.enabled=!1),this.enabled}enableFloatingMode(){this.tv=!0,this.nv=!1,this.forceEnableFloatingMode()}disableFloatingMode(){this.tv=!1,this.forceDisableFloatingMode()}forceEnableFloatingMode(){this.nv||(this.Kg=!1,this.Zg=!0,this.start())}forceDisableFloatingMode(){this.Zg=!1,this.destroy()}setFloatingSettings(t){this.Xg(t),this.start()}getFloatingSettings(){return super.getFloatingSettings()}vg(){const t=!this.sv;super.vg(t)}Hg(){this.ov.next()}Vg(){this.cv()}qg(){this.rv.next()}cv(){this.transitionState=Zt.FadeIn,this.xg(P.jG.FadeIn),this.Tg(P.jG.FadeInBase),(0,u.Tp)(this.zm),this.Tg(P.jG.FadeIn)}wg(){this.Jg.next()}Pg(){this.xg(P.jG.FadeInBase,P.jG.FadeIn),this.hv.next(),this.eg&&super.Wg()}dv(){this.Yg.on(this.zm.parentElement,this.av,{threshold:ei})}lv(){this.Yg.off(this.zm.parentElement,this.av)}start(){this.kg()&&(super.zg(),this.ci.floatingMode===v.ProtoPlayerFloatingMode.OnPageLoad&&(this.Kg=!1),this.dv(),this.av(this.Yg.check({element:this.zm.parentElement,threshold:ei})))}canFloat(){return this.kg()&&this.ci.floatingMode!==v.ProtoPlayerFloatingMode.Off}destroy(t=!1){t&&(this.nv=t),this.isInFloating?(this.Sg(),this.eg=!0):super.Wg(),this.lv()}get enabled(){return this.Zg}set enabled(t){this.Zg=t}get forceEnabled(){return this.tv}set forceEnabled(t){this.tv=t}fullscreenStateChange(t){this.sv=t,t?this.lv():this.dv(),this.av(t)}}var ki,Ci;!function(t){t[t.EmbededState=0]="EmbededState",t[t.FloatingState=1]="FloatingState"}(ki||(ki={}));class Ei{constructor(t,i){this.uv=t,this.fv=i,this.mv=!1,this.gv(),this.vv()}gv(){this.fv!==v.ProtoPlayerFloatingMode.Off&&this.fv!==v.ProtoPlayerFloatingMode.AfterInView||(this.yv=ki.EmbededState),this.fv===v.ProtoPlayerFloatingMode.OnPageLoad&&this.uv.isInFloating&&(this.yv=ki.FloatingState),this.fv!==v.ProtoPlayerFloatingMode.OnPageLoad||this.uv.isInFloating||(this.yv=ki.EmbededState),(this.bv&&!this.Iv||this.wv)&&this.fv!==v.ProtoPlayerFloatingMode.Off&&(this.yv=ki.EmbededState),this.Sv=this.yv}Pv(){(this._v||this.xv)&&this.uv.isInFloating&&this.fv!==v.ProtoPlayerFloatingMode.Off&&(this.yv=ki.FloatingState),(this.bv&&!this.Iv||this.wv)&&this.fv!==v.ProtoPlayerFloatingMode.Off&&(this.uv.isInFloating&&(this.yv=ki.FloatingState),(!this.uv.forceEnabled||!this.uv.isInFloating&&this.Tv)&&(this.yv=ki.EmbededState)),(this.kv||this.Iv||this.Cv)&&this.fv!==v.ProtoPlayerFloatingMode.Off&&(this.yv=ki.FloatingState),this.Ev()&&(this.yv=ki.EmbededState),this.Ev()&&this.uv.isInFloating&&(this.yv=ki.FloatingState),this.yv!==this.Sv&&(this.Sv=this.yv,this.vv())}vv(){this.uv.forceEnabled||this.uv.forceDisableFloatingMode(),this.uv.forceEnabled&&(this.yv===ki.EmbededState&&this.uv.forceDisableFloatingMode(),this.yv===ki.FloatingState&&this.uv.forceEnableFloatingMode())}Ev(){return this.fv===v.ProtoPlayerFloatingMode.AfterInView&&!this.mv}setViewabilityFlag(t){t&&(this.mv=t),this.Tv!==t&&this.uv.forceEnabled&&(this.Tv=t,this.Pv())}setAdPlay(t){this.Iv!==t&&this.uv.forceEnabled&&(this.Iv=t,this.wv=!1,this.Cv=!1,this.kv=!1,this.bv=!0,this.Pv())}setAdResumed(t){this.Cv!==t&&this.uv.forceEnabled&&(this.Cv=t,this.Iv=!1,this.wv=!1,this.kv=!1,this.bv=!0,this.Pv())}setAdPaused(t){this.wv!==t&&this.uv.forceEnabled&&(this.wv=t,this.Iv=!1,this.Cv=!1,this.bv=!1,this.kv=!1,this.Pv())}setPlayerPlay(t){this.kv!==t&&this.uv.forceEnabled&&(this.kv=t,this.bv=!1,this.wv=!1,this.Iv=!1,this.Cv=!1,this.Pv())}setPlayerPause(t){this.bv!==t&&this.uv.forceEnabled&&(this.bv=t,this.kv=!1,this.wv=!1,this.Iv=!1,this.Cv=!1,this.Pv())}setNonlinearEnable(t){this._v!==t&&this.uv.forceEnabled&&(this._v=t,this.xv=!1,this.Pv())}setNonlinearDisable(t){this.xv!==t&&this.uv.forceEnabled&&(this.xv=t,this._v=!1,this.Pv())}}!function(t){t[t.Portrait=0]="Portrait",t[t.Landscape=1]="Landscape"}(Ci||(Ci={}));const Mi=Ci;class Li{constructor(t){this.urlSuffixerService=t,this.Mv={},this.Bv=[]}getImage(t,i,e,n,r="",o=!1){return this.Rv=t,this.Ov=(0,s.QM)(i)?i:"",this.Dv=e,this.Vv=n,this.Fv=r,this.Nv=o,this.$v()}$v(){const t=this.Uv();if(t)return t;const i=this.Rv+this.Fv,e=new Image;return e.src=this.urlSuffixerService.appendParamsToUrl(i),e.alt=this.Ov,this.Mv[this.Rv]=this.Mv[this.Rv]||{},this.Mv[this.Rv][this.Dv]=this.Mv[this.Rv][this.Dv]||{},this.Mv[this.Rv][this.Dv][this.Vv]=this.Mv[this.Rv][this.Dv][this.Vv]||{},this.Mv[this.Rv][this.Dv][this.Vv][this.Fv]=e,e}Uv(){const t=this.qv();if(t)return t;if(!this.Nv)return;this.Hv();const i=this.zv();if(i)return i;const e=this.Wv();return e||void 0}Hv(){const t=[];if(!this.Mv[this.Rv])return void(this.Bv=[]);const i=this.Mv[this.Rv],e=this.Dv>this.Vv?Mi.Landscape:Mi.Portrait;Object.keys(i).forEach((s=>{const n=parseInt(s,10);Object.keys(i[s]).filter((t=>!!i[s][t])).forEach((i=>{const s=parseInt(i,10);if((n>s?Mi.Landscape:Mi.Portrait)!==e)return;const r={area:n*s,img:this.Gv(this.Rv,n,s)};t.push(r)}))})),this.Bv=[...t]}Gv(t,i,e){if(this.Mv[t]&&this.Mv[t][i]&&this.Mv[t][i][e])return this.Mv[t][i][e][Object.keys(this.Mv[t][i][e])[0]]}qv(){return this.Mv[this.Rv]&&this.Mv[this.Rv][this.Dv]&&this.Mv[this.Rv][this.Dv][this.Vv]&&this.Mv[this.Rv][this.Dv][this.Vv][this.Fv]}zv(){if(0===this.Bv.length)return;const t=this.Dv*this.Vv,i=this.Bv.filter((({area:i})=>i>t)).sort(((t,i)=>t.area-i.area));return 0!==i.length?i[0].img:void 0}Wv(){if(0===this.Bv.length)return;const t=this.Dv*this.Vv,i=this.Bv.filter((({area:i})=>i<t&&t/i<=1.3)).sort(((t,i)=>i.area-t.area));return 0!==i.length?i[0].img:void 0}}var Bi;!function(t){t.LINEAR="LINEAR",t.NONLINEAR="NONLINEAR"}(Bi||(Bi={}));class Ri{static getBidDemandType(t){const i=Object.keys(Ri.bidDemandTypeMap).filter((i=>(0,Ri.bidDemandTypeMap[i])(t.settings.adManagerLineItem.protoLineItem)))[0];if(!(0,s.$K)(i))return v.ProtoDemandTypeEnum.None;const e=Number.parseInt(i,10);return v.ProtoDemandTypeEnum[v.ProtoDemandTypeEnum[e]]}static isPrivateMarketplaceBid(t){return t.isPMP}static isOpenMarketBid(t){const{advertiserLineItemId:i,publisherLineItemId:e}=t;return!Ri.isPrivateMarketplaceBid(t)&&i!==e}static isSelfServedBid(t){const{advertiserLineItemId:i,publisherLineItemId:e}=t;return!Ri.isPrivateMarketplaceBid(t)&&i===e}}Ri.bidDemandTypeMap={[v.ProtoDemandTypeEnum.PMP]:t=>Ri.isPrivateMarketplaceBid(t),[v.ProtoDemandTypeEnum.OpenMarket]:t=>Ri.isOpenMarketBid(t),[v.ProtoDemandTypeEnum.SelfServed]:t=>Ri.isSelfServedBid(t)};const Oi={[Bi.LINEAR]:[v.ProtoAdType.Video,v.ProtoAdType.Overlay],[Bi.NONLINEAR]:[v.ProtoAdType.Nonlinear]};function Di(t,i){return t.filter((t=>Oi[i].includes(t.adType)))}function Vi(t,i){return t.find((t=>t.adManagerLineItem.protoLineItem.advertiserLineItemId===i)).adManagerLineItem}const Fi=({playerSkippability:t,playerSkipMin:i,playerSkipAfter:e,lineItemSkippability:s,lineItemSkipMin:n})=>{let r={skippable:!0,skipafter:e};switch(t){case v.ProtoPlayerSkippabilityType.AllowNonSkipAdsIfTheyAreShorterThan:r=function({skippabitySettings:t,playerSkipMin:i,lineItemSkippability:e,lineItemSkipMin:s}){if(e===v.ProtoLineItemSkippabilityType.RequirePublisherToAllowNonSkipAdsShorterThan)s<i?t.skipmin=i:(t.skipmin=s,t.minDuration=s);else t.skipmin=i;return t}({skippabitySettings:r,playerSkipMin:i,lineItemSkippability:s,lineItemSkipMin:n});break;case v.ProtoPlayerSkippabilityType.RequireAdsToBeSkippable:s===v.ProtoLineItemSkippabilityType.RequirePublisherToAllowNonSkipAdsShorterThan&&(r.skipmin=n,r.minDuration=n)}return r};function Ni(t,i){return t===v.ProtoAdType.Nonlinear&&i===v.ProtoNonlinearRequestType.Banner}function ji(t,i){return{adTag:(0,s.$K)(t.url)?t.url:i.adTag,requestCap:(0,s.$K)(t.contentRequestCap)?t.contentRequestCap:i.requestCap,impressionCap:(0,s.$K)(t.contentImpressionCap)?t.contentImpressionCap:i.impressionCap,resetRequestsCapTime:(0,s.$K)(t.resetRequestsCapTime)?t.resetRequestsCapTime:i.resetRequestsCapTime,resetImpressionsCapTime:(0,s.$K)(t.resetImpressionsCapTime)?t.resetImpressionsCapTime:i.resetImpressionsCapTime,resetCapType:(0,s.$K)(t.resetCapType)?t.resetCapType:i.resetCapType}}var $i=r(7332),Ui=r(8474);function qi(t,i,e){var s=(0,Ui.m)(t)||i||e?{next:t,error:i,complete:e}:t;return s?(0,ut.e)((function(t,i){var e;null===(e=s.subscribe)||void 0===e||e.call(s);var n=!0;t.subscribe((0,pt.x)(i,(function(t){var e;null===(e=s.next)||void 0===e||e.call(s,t),i.next(t)}),(function(){var t;n=!1,null===(t=s.complete)||void 0===t||t.call(s),i.complete()}),(function(t){var e;n=!1,null===(e=s.error)||void 0===e||e.call(s,t),i.error(t)}),(function(){var t,i;n&&(null===(t=s.unsubscribe)||void 0===t||t.call(s)),null===(i=s.finalize)||void 0===i||i.call(s)})))})):mt.y}var Hi=r(4978),zi=r(4865);function Wi(t){return t[t.length-1]}function Gi(t){return(0,zi.K)(Wi(t))?t.pop():void 0}var Xi=r(7878);function Qi(t,i,e,s,n){void 0===s&&(s=0),void 0===n&&(n=!1);var r=i.schedule((function(){e(),n?t.add(this.schedule(null,s)):this.unsubscribe()}),s);if(t.add(r),!n)return r}function Ji(t,i){return void 0===i&&(i=0),(0,ut.e)((function(e,s){e.subscribe((0,pt.x)(s,(function(e){return Qi(s,t,(function(){return s.next(e)}),i)}),(function(){return Qi(s,t,(function(){return s.complete()}),i)}),(function(e){return Qi(s,t,(function(){return s.error(e)}),i)})))}))}function Yi(t,i){return void 0===i&&(i=0),(0,ut.e)((function(e,s){s.add(t.schedule((function(){return e.subscribe(s)}),i))}))}var Ki=r(1480);var Zi=r(9768);function te(t,i){if(!t)throw new Error("Iterable cannot be null");return new Ki.y((function(e){Qi(e,i,(function(){var s=t[Symbol.asyncIterator]();Qi(e,i,(function(){s.next().then((function(t){t.done?e.complete():e.next(t.value)}))}),0,!0)}))}))}var ie=r(1764),ee=r(3841),se=r(5685),ne=r(1837),re=r(8430),oe=r(8729),he=r(8671);function ae(t,i){if(null!=t){if((0,ie.c)(t))return function(t,i){return(0,Xi.Xf)(t).pipe(Yi(i),Ji(i))}(t,i);if((0,se.z)(t))return function(t,i){return new Ki.y((function(e){var s=0;return i.schedule((function(){s===t.length?e.complete():(e.next(t[s++]),e.closed||this.schedule())}))}))}(t,i);if((0,ee.t)(t))return function(t,i){return(0,Xi.Xf)(t).pipe(Yi(i),Ji(i))}(t,i);if((0,re.D)(t))return te(t,i);if((0,ne.T)(t))return function(t,i){return new Ki.y((function(e){var s;return Qi(e,i,(function(){s=t[Zi.h](),Qi(e,i,(function(){var t,i,n;try{i=(t=s.next()).value,n=t.done}catch(t){return void e.error(t)}n?e.complete():e.next(i)}),0,!0)})),function(){return(0,Ui.m)(null==s?void 0:s.return)&&s.return()}}))}(t,i);if((0,he.L)(t))return function(t,i){return te((0,he.Q)(t),i)}(t,i)}throw(0,oe.z)(t)}function ce(){for(var t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];return function(t,i){return i?ae(t,i):(0,Xi.Xf)(t)}(t,Gi(t))}class de{get id(){return this.Xv}get timestamp(){return this.Qv}set timestamp(t){this.Qv=t}constructor(){this.Xv=(0,h.qs)()}}const le=Object.assign({},M.Km);var ue=r(7531),pe=r(9613),fe=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};const me=["com.accuweather.android"],ge=.05*Lt.s_;class ve extends I._{constructor(t,i,e,n,r,o,h,a){super(),this.mediator=t,this._appSettings=i,this.Jv=e,this.Vc=n,this.zc=r,this.Td=o,this.Dc=h,this.Ef=a,this.Yv=.01,this.Kv=.5,this.Zv=.5,this.ty=2e3,this.iy=0,this.ey=!1,this.sy=!1,this.ny=!1,this.oy=!1,this.hy=!1,this.ly=!1,this.Tv=!1,this.uy=v.ProtoAdSlotsEnum.PreRoll,this.lm=!1,this.py=!1,this.my=!1,this.gy=!1,this.vy=!0,this.yy=[],this.by=[],this.Sy=[],this.Py=[],this.Ay=[],this._y=0,this.xy={[ii.d.togglePlay]:()=>{var t;return null===(t=this.adHandler)||void 0===t?void 0:t.togglePlay(this.vy)},[ii.d.toggleMute]:()=>{var t;return null===(t=this.adHandler)||void 0===t?void 0:t.toggleMute(this.vy)},[ii.d.increaseVolume]:()=>{var t;return null===(t=this.adHandler)||void 0===t?void 0:t.increaseVolume(.1,this.vy)},[ii.d.decreaseVolume]:()=>{var t;return null===(t=this.adHandler)||void 0===t?void 0:t.decreaseVolume(.1,this.vy)}},this.Ty=t=>{this.py=t,t&&(this.app.services.ViewabilityService.off(this.$playerContainer,this.Ty),this.ky())},this.Cy=t=>{t&&this.adHandler&&!this.gy&&setTimeout((()=>{this.adHandler.resumeWithoutUserInteraction(this.uy)}),ge)},this.Ey=()=>{this.isBelowSmBreakpoint(this.$experienceContainer.clientWidth)?(0,u.cn)(this.$experienceContainer,P.Gj.NoHeight):(0,u.IV)(this.$experienceContainer,P.Gj.NoHeight),!this.sy&&this.My()&&(this.mediator.publish(this,w.Uh.CanStart),this.app.services.ResizeObserver.off(this.$experienceContainer,this.Ey))},this.Ly=t=>{const{playback:i,isFullscreenClose:e}=t;this.floatingModule&&(0,s.$K)(i)&&!e&&(this.floatingModule.enabled=i)},this.By=()=>{this.Ry(1)},this.Oy=()=>{this.Ry(0)},this.Dy=t=>{this.Ly(t);const{playback:i}=t;(0,s.$K)(i)&&(i?(this.app.services.EventsStorageService.emitAdPlay(),this.gy=!1):(this.app.services.EventsStorageService.emitAdPause(),this.gy=!0))},this.Vy=new Li(e)}Fy(){}Ny(t,i,e){this.app.services.EventsStorageService.emitAdImpression(t,i,e)}jy(t){this.app.services.EventsStorageService.emitAdComplete(t)}$y(){}Uy(){}Hy(){}zy(){}Wy(){}Gy(){}Xy(){}Qy(t){const i={state:t};this.app.services.EventsStorageService.emitAdStateChange(i)}Jy(){const{clientWidth:t,clientHeight:i}=this.$playerContainer,e={width:t,height:i};this.app.services.EventsStorageService.emitPlayerResized(e)}Yy(){this.app.services.EventsStorageService.emitOnEnterFullscreen()}Ky(){this.app.services.EventsStorageService.emitOnExitFullscreen()}Zy(){this.app.services.EventsStorageService.emitOnPlayerCollapsed()}tb(t){this.app.services.EventsStorageService.emitOnPlayerExpanded(t)}ib(t){this.eb(t),this.sb(t),this.nb(t),this.uy=t,this.rb(t)}sb(t){this.adHandler&&this.adHandler.adStateChange(t,this.ob.getMaxAdSlotDuration())}nb(t){this.hb.onAdStateChange(t,{maxAdPodDuration:this.ob.getMaxAdPodDuration(),maxAdSlotDuration:this.ob.getMaxAdSlotDuration()})}eb(t){this.ob.setNewBreak(t)}rb(t){this.Qy(K[t])}ab(){var t;null===(t=this.adHandler)||void 0===t||t.contentChanged(),this.hb.contentChanged()}cb(){var t;null===(t=this.adHandler)||void 0===t||t.contentEnded()}lb(){var t,i,e,s,n,r;this.adHandler=this.ub(),this.pb(),null===(t=this.adHandler)||void 0===t||t.onLinearImpressionPrice.subscribe((t=>{this.mediator.publish(this,M.Km.ImpressionPrice,{payload:t})})),null===(i=this.adHandler)||void 0===i||i.onNonLinearImpressionPrice.subscribe((t=>{this.mediator.publish(this,M.Km.ImpressionPrice,{payload:t})})),null===(e=this.adHandler)||void 0===e||e.onLinearImpressionRevenue.subscribe((t=>{this.mediator.publish(this,M.Km.ImpressionRevenue,{payload:t})})),null===(s=this.adHandler)||void 0===s||s.onNonLinearImpressionRevenue.subscribe((t=>{this.mediator.publish(this,M.Km.ImpressionRevenue,{payload:t})})),null===(n=this.adHandler)||void 0===n||n.onLinearExperienceEvent.subscribe((t=>{w.Uh.UserInteraction===t.type&&this.Dy(t.payload)}));const o=()=>{this.Vc.adsEnabled.next(),this.my=!0,this.gy=!1,this.ky(),this.fb.unsubscribe()};this.fb=null===(r=this.adHandler)||void 0===r?void 0:r.onAdsEnable.subscribe((()=>{o()})),this.hb.setAdHandler(this.adHandler),this.gb()}dp(t){this.mediator.publish(this,M.Km.AdImpression,t.payload);const{adSourceData:i,customAdData:e,adType:s}=t.payload.payload;this.Ny(i,e,s)}gb(){this.by.push(this.zc.adBid.subscribe((t=>{const{publisherLineItemId:i,advertiserLineItemId:e,impressionTrackers:s}=t;setTimeout((()=>{this.mediator.publish(this,M.Km.Bid,{payload:{publisherLineItemId:i,advertiserLineItemId:e,impressionTrackers:s}})}),0)})))}pb(){this.vb(),this.yb(),this.bb()}vb(){this.Ay.push(this.adHandler.onVpaidEvent.subscribe((t=>{switch(t.type){case T.AdStarted:this.mediator.publish(this,M.Km.AdStarted,t.payload);break;case T.AdImpression:this.dp(t);break;case T.AdStopped:{if(this.mediator.publish(this,M.Km.AdStopped,t.payload),this.Tv&&this.Uy(),!t.payload)return;const{adType:i}=t.payload.payload;this.jy(i),this.app.services.EventsStorageService.emitAdStopped(i);break}case T.AdError:{const{adType:i}=t.payload;this.mediator.publish(this,M.Km.AdError,t),this.app.services.EventsStorageService.emitAdError(i);break}case T.AdSkipped:{const{adType:i}=t.payload.payload;this.mediator.publish(this,M.Km.AdSkipped,t.payload),this.app.services.EventsStorageService.emitAdSkipped(i),this.jy(i),this.Tv&&this.Uy();break}case T.AdPaused:{const{adType:i}=t.payload.payload;this.Vc.sessionPlaybackChanged.next({isPlaying:!1}),this.app.services.EventsStorageService.emitAdPaused(i),this.mediator.publish(this,M.Km.AdPause,t.payload);break}case T.AdPlaying:{const{adType:i}=t.payload.payload;this.Vc.sessionPlaybackChanged.next({isPlaying:!0}),this.app.services.EventsStorageService.emitAdPlaying(i),this.mediator.publish(this,M.Km.AdPlay,t.payload);break}case T.AdVideoFirstQuartile:{const{adType:i}=t.payload.payload;this.mediator.publish(this,M.Km.AdCompleted25,t.payload),this.app.services.EventsStorageService.emitAdVideoFirstQuartile(i);break}case T.AdVideoMidpoint:{const{adType:i}=t.payload.payload;this.mediator.publish(this,M.Km.AdCompleted50,t.payload),this.app.services.EventsStorageService.emitAdVideoMidpoint(i);break}case T.AdVideoThirdQuartile:{const{adType:i}=t.payload.payload;this.mediator.publish(this,M.Km.AdCompleted75,t.payload),this.app.services.EventsStorageService.emitAdVideoThirdQuartile(i);break}case T.AdVideoComplete:{const{adType:i}=t.payload.payload;this.mediator.publish(this,M.Km.AdCompleted100,t.payload),this.app.services.EventsStorageService.emitAdVideoComplete(i);break}case T.AdClickThru:{const{adType:i}=t.payload.payload;this.mediator.publish(this,M.Km.AdClick,t.payload),this.app.services.EventsStorageService.emitAdClickThru(i);break}case T.AdInteraction:{const{adType:i}=t.payload.payload;this.app.services.EventsStorageService.emitAdInteraction(i);break}case T.AdUserAcceptInvitation:{const{adType:i}=t.payload.payload;this.app.services.EventsStorageService.emitAdInteraction(i);break}case T.AdExpandedChange:{const{adType:i}=t.payload.payload;this.app.services.EventsStorageService.emitAdExpandedChange(i);break}case T.AdUserClose:{const{adType:i}=t.payload.payload;this.app.services.EventsStorageService.emitAdInteraction(i);break}case T.AdUserMinimize:{const{adType:i}=t.payload.payload;this.app.services.EventsStorageService.emitAdInteraction(i);break}case T.AdVideoStart:{const{adSourceData:i,adType:e}=t.payload,{clientWidth:s,clientHeight:n}=this.$playerContainer,r={duration:i&&i.length,mediaPlayerVolume:this.getVolume(),mediaPlayerDimensions:{width:s,height:n}};this.app.services.EventsStorageService.emitAdVideoStart(r,e);break}case T.AdLoaded:{const{payload:i}=t.payload,{adType:e,adLoadedData:s}=i;this.mediator.publish(this,M.Km.AdLoaded,t.payload),(null==s?void 0:s.skipOffset)<0&&(s.skipOffset=void 0);const n=this.Ib(s);this.app.services.EventsStorageService.emitAdLoaded(n,e);break}case T.AdVolumeChange:{const{adType:i}=t.payload.payload;this.mediator.publish(this,M.Km.AdVolumeChange,t.payload),this.app.services.EventsStorageService.emitAdVolumeChange(i);break}case T.AdLog:}})),this.adHandler.onPrefetchStart.subscribe((()=>{this.mediator.publish(this,M.Km.PrefetchStart)})))}yb(){this.Ay.push(this.adHandler.onMissedImpression.subscribe((t=>{const i=Math.round(this.hb.getTheoreticalDurationUntilNextOpportuinity()*Lt.s_);t.setTimeUntilNextOpportunity(i),this.zc.missedImpressionOutOfView.next(t.missedImpressionsLogs)})),this.adHandler.onLinearEvent.subscribe((t=>{var i,e,s;switch(t.type){case pe.lc.ShowLinearEvent:this.hb.onAdImpression(t.payload,Bi.LINEAR),this.wb(),null===(i=this.floatingStateMachine)||void 0===i||i.setAdPlay(!0);break;case pe.lc.HideLinearEvent:this.Sb(t.forced);break;case pe.lc.PauseLinearEvent:this.hb.onLinearAdPause(),null===(e=this.floatingStateMachine)||void 0===e||e.setAdPaused(!0);break;case pe.lc.ResumeLinearEvent:this.hb.onLinearAdPlay(),null===(s=this.floatingStateMachine)||void 0===s||s.setAdResumed(!0);break;case pe.lc.SkipLinearEvent:const n=!0;this.floatingModule&&(this.floatingModule.enabled=!0),this.Sb(n)}})))}bb(){this.Ay.push(this.adHandler.onNonLinearEvent.subscribe((t=>{switch(t.type){case pe.gx.ShowNonLinearEvent:this.hb.onAdImpression(t.payload,Bi.NONLINEAR);break;case pe.gx.HideNonLinearEvent:const i=!1;this.hb.onAdFinished(this.adHandler.nonLinearInImpression,Bi.NONLINEAR,i)}})))}wb(){this.ob.adStarted(),this.adHandler.showLinear(),(0,u.cn)(this.$playerWrapper,P._7.HidePinnedTitle)}Pb(){this.adHandler.hideLinear(),(0,u.IV)(this.$playerWrapper,P._7.HidePinnedTitle)}Sb(t=!1,i=this.$playerContainer){var e,s,n,r;this.Ef.processAdUserInteraction(t);let o=this.ob.isInAdPod();t&&(o=!1,this.ob.endPod()),this.hb.onAdFinished(this.adHandler.linearInImpression,Bi.LINEAR,o),this.Pb(),this.Ab.isCloseButton&&this.adHandler&&this.adHandler.firstLinearAdShown&&(this.Ab.closeButtonMode!==v.ProtoPlayerCloseButtonMode.OnHoverAfterFirstAd||(0,u.pv)(i,P.s6.CloseHover)||((0,u.cn)(i,P.s6.CloseHover),null===(s=null===(e=this.Wf)||void 0===e?void 0:e.updateCloseButtonMode)||void 0===s||s.call(e,!1,v.ProtoPlayerCloseButtonMode.OnHover)),this.Ab.floatingSettings.floatingCloseButtonMode!==v.ProtoPlayerCloseButtonMode.OnHoverAfterFirstAd||(0,u.pv)(i,P.s6.CloseFloatHover)||((0,u.cn)(i,P.s6.CloseFloatHover),null===(r=null===(n=this.Wf)||void 0===n?void 0:n.updateCloseButtonMode)||void 0===r||r.call(n,!0,v.ProtoPlayerCloseButtonMode.OnHover)))}_b(t){this.adHandler.enterAdPodLoadingState(),this.ob.enterPodTimeout((()=>{this.ob.endPod(),t()}))}xb(){(0,S.BZ)(Di(this.Ab.lineItemSettings.lineItems,Bi.LINEAR))||this.hb.onLinearNoDemand(),this.subscribe(yi,this.hb,(()=>{var t,i;null===(t=this.adHandler)||void 0===t||t.enableAds(Bi.NONLINEAR),null===(i=this.floatingStateMachine)||void 0===i||i.setNonlinearEnable(!0)})),this.subscribe(vi,this.hb,(t=>{var i,e;const s=t.payload;null===(i=this.adHandler)||void 0===i||i.disableAds(Bi.NONLINEAR,s),null===(e=this.floatingStateMachine)||void 0===e||e.setNonlinearDisable(!0)})),this.subscribe(li,this.hb,(()=>{var t;null===(t=this.adHandler)||void 0===t||t.enableAds(Bi.LINEAR)})),this.subscribe(ui,this.hb,(t=>{var i;const e=t.payload;null===(i=this.adHandler)||void 0===i||i.disableAds(Bi.LINEAR,e)})),this.subscribe(pi,this.hb,(()=>{var t;null===(t=this.adHandler)||void 0===t||t.stopAd(pe.aB.ForceStopAdSlot)})),this.subscribe(fi,this.hb,(()=>{if(this.adHandler)if(this.adHandler.linearInImpression)this.ob.endPod(),this.adHandler.stopAd(pe.aB.ForceStopAdPod);else{const t=!0;this.Sb(t)}})),this.subscribe(bi,this.hb,(()=>{var t;null===(t=this.adHandler)||void 0===t||t.disableAdvertising()})),this.subscribe(Ii,this.hb,(()=>{var t;null===(t=this.adHandler)||void 0===t||t.enableAdvertising()})),this.subscribe(gi,this.hb,(t=>{var i;null===(i=this.adHandler)||void 0===i||i.updateLinearPodRemainingTime(t.payload.remainingTime)})),this.subscribe(Pi,this.hb,(t=>{var i;const e=t.payload.linearity;null===(i=this.adHandler)||void 0===i||i.canPrefetchAds(e)})),this.subscribe(mi,this.hb,(t=>{var i,e;const n=t.payload.adBreakType,r=null===(i=this.adHandler)||void 0===i?void 0:i.getLinearAdContainerWidth(),o=this.Tb(),h=(0,s.$K)(r)?r:this.$playerContainer.clientWidth;this.Vc.adOpportunity.next({adBreak:A.EN.fromProtoAdBreakType(n),playerWidth:h,opportunityId:o.id}),null===(e=this.adHandler)||void 0===e||e.newLinearAdOpportunity(o)}))}Tb(){return(0,s.$K)(this.adHandler)?this.adHandler.getNewLinearAdOpportunity():new de}kb(){this.app.services.ViewabilityService.on(this.$playerContainer,this.Ty,{threshold:this.Kv,callbackDelay:this.ty}),this.app.services.ViewabilityService.on(this.$playerContainer,((t,i)=>this.av(t,i)),{threshold:this.Yv}),this.app.services.ViewabilityService.on(this.$playerContainer,(t=>{var i;null===(i=this.floatingStateMachine)||void 0===i||i.setViewabilityFlag(t)}),{threshold:this.Zv}),this.app.services.ViewabilityService.subscribe(M.jJ.OmidViewabilityThreshold,(t=>{this.mediator.publish(this,M.jJ.OmidViewabilityThreshold,{payload:{threshold:t}})})),this.app.config.os.os===zt.M.Ios&&this.app.services.PageFocusService.on(this.Cy)}ky(){this.py&&this.my&&this.mediator.publish(this,w.Xh.SessionView)}av(t,i=!1){this.hb.setToggleAdsReason({isAppBackgrounded:i}),this.app.config.isInApp&&(this.Dc.isPageInFocus=!i,i?(this.Fm=this.getVolume(),this.setVolume(0)):this.Fm&&(this.setVolume(this.Fm),this.Fm=null)),this.Tv=t,this.mediator.publish(this,M.Km.IsViewable,{payload:t}),this.hb.viewabilityStateChanged(this.checkFloatingViewability(t),this.ob.isInAdPod(),this.ob.isInPodTimeout()),this.Vc.sessionViewabilityChanged.next({isInView:t})}checkFloatingViewability(t){const i=this.Dc.isPageInFocus;return!(t||!this.floatingModule||!this.floatingModule.isInFloating||!i)||t}_p(){var t,i,e;const s=this.$playerContainer.clientWidth,n=this.$playerContainer.clientHeight;this.Dc.playerDimensions={height:n,width:s};const r=this.lm?x.Fullscreen:x.Normal;null===(t=this.adHandler)||void 0===t||t.resizeAd(s,n,r,this.uy);try{null===(i=this.hb)||void 0===i||i.onResize(s,n)}catch(t){(0,p.n)({message:"BaseExperience_onResize_player",callStack:t.stack,exception:t.message,level:p.D.WARN})}null===(e=this.adHandler)||void 0===e||e.setPlayerOrientation(this.Cb(s,n)),this.Eb(),setTimeout((()=>{this.mediator.publish(this,M.Km.SizeChanged,{payload:{width:s,height:n}}),this.Mb()}))}isBelowSmBreakpoint(t){return t<this._y}Cb(t,i){return t<i?ri.Portrait:t>i?ri.Landscape:ri.None}Mb(){this.lm||this.Jy()}Lb(){this.app.services.ResizeObserver.on(this.$playerContainer,(()=>{this._p()}))}Bb(){var t;this.lm=!0,this.app.services.InteractionService.disableScrollEvent(),this.Yy(),null===(t=this.adHandler)||void 0===t||t.setVastViewMode(x.Fullscreen)}Rb(){var t;this.lm=!1,this.app.services.InteractionService.enableScrollEvent(),this.Ky(),null===(t=this.adHandler)||void 0===t||t.setVastViewMode(x.Normal)}Ob(){const t=`<cnx class='${P.oV}'></cnx>`,i=this.app.services.GlobalDomUtilsService.createElementByString(t);return this.Db(i),i}Db(t){(0,u.T7)(t,{"padding-bottom":`${this.Vb()}%`})}Vb(){return this.Ab.playerSize.ratioHeight/this.Ab.playerSize.ratioWidth*100}Fb(t){var i;(null===(i=this.adHandler)||void 0===i?void 0:i.linearInImpression)?this.jb(t.action):this.Ub(t.action)}Ub(t){}jb(t){const i=this.xy[t];i&&i()}qb(){this.Sy.push(this.floatingModule.onFloatingEnterStart.subscribe((()=>{var t,i,e;this.mediator.publish(this,M.Zr.PlayerFloatChanged,{payload:ti.Float}),this.mediator.publish(this,M.Zr.FloatingEnterStart,{payload:!0}),null===(t=this.adHandler)||void 0===t||t.inFloatingChanged(!0),null===(e=null===(i=this.Wf)||void 0===i?void 0:i.updateFloatingState)||void 0===e||e.call(i,!0)})),this.floatingModule.onFloatingExitStart.subscribe((()=>{this.mediator.publish(this,M.Zr.FloatingExitStart,{payload:!0})})),this.floatingModule.onFloatingExitStop.subscribe((()=>{var t,i,e;this.mediator.publish(this,M.Zr.PlayerFloatChanged,{payload:ti.Embed}),this.mediator.publish(this,M.Zr.FloatingExitStop,{payload:!0}),null===(t=this.adHandler)||void 0===t||t.inFloatingChanged(!1),null===(e=null===(i=this.Wf)||void 0===i?void 0:i.updateFloatingState)||void 0===e||e.call(i,!1)})),this.floatingModule.onFloatingEnterStop.subscribe((()=>{this.mediator.publish(this,M.Zr.FloatingEnterStop,{payload:!0}),this.av(!0)})))}Hb(){this.floatingModule=new Ti(this.app.services.ViewabilityService,this.Dc,this.app.services.ResizeObserver,this.$playerContainer,this.Ab.floatingSettings,this.app.config.device,this.app.services.GlobalDomUtilsService,this.zb),this.qb(),this.floatingModule.start(),this.floatingStateMachine=new Ei(this.floatingModule,this.Ab.floatingSettings.floatingMode)}Gb(){this.alwaysFloatingModule=new xi(this.app.services.ResizeObserver,this.$experienceContainer,this.Ab.floatingSettings,this.app.config.device,this.app.services.GlobalDomUtilsService),this.Sy.push(this.alwaysFloatingModule.onFloatingEnterStop.subscribe((()=>{var t;null===(t=this.adHandler)||void 0===t||t.inFloatingChanged(!0),this.app.services.ViewabilityService.triggerRecheck(this.$playerContainer)}))),this.alwaysFloatingModule.start()}setNewVolume(t){var i;null===(i=this.adHandler)||void 0===i||i.setLinearVolume(t)}Xb(){var t;this.Qb(),null===(t=this.adHandler)||void 0===t||t.onLinearExperienceEvent.subscribe((t=>{var i;t.type===w.Uh.UserInteraction&&(null===(i=t.payload)||void 0===i?void 0:i.volume)&&this.Jb()}))}Yb(t){this.subscribe(w.Uh.UserInteraction,t,(({payload:{volume:t}})=>{t&&this.Jb()}))}gp(t){this.mediator.publish(this,M.Km.VolumeChanged,{payload:t}),this.app.services.EventsStorageService.emitVolumeChange(t)}Ry(t){this.getVolume()!==t&&this.setNewVolume(t)}Qb(){this.ey=!0,this.$playerContainer.addEventListener("mouseover",this.By),this.$playerContainer.addEventListener("mouseout",this.Oy)}Jb(){this.ey&&(this.ey=!1,this.$playerContainer.removeEventListener("mouseover",this.By),this.$playerContainer.removeEventListener("mouseout",this.Oy))}Kb(){this.breakPointsHandler=new Ai(this.$playerContainer,this.Zb,this.tI,this.app.config.device),this.Eb()}iI(t=this.$playerContainer){if(this.Ab.isCloseButton){switch(this.adHandler&&this.Py.push(this.adHandler.onLinearUiComponentEvent.subscribe((t=>{t.type===Jt.C.Close&&(this.mediator.publish(this,le.CloseButtonClicked),this.handleClose())}))),this.Ab.closeButtonMode){case v.ProtoPlayerCloseButtonMode.AlwaysOn:(0,u.cn)(t,P.s6.CloseOn);break;case v.ProtoPlayerCloseButtonMode.Off:(0,u.cn)(t,P.s6.CloseOff);break;case v.ProtoPlayerCloseButtonMode.OnHover:(0,u.cn)(t,P.s6.CloseHover)}switch(this.Ab.floatingSettings.floatingCloseButtonMode){case v.ProtoPlayerCloseButtonMode.AlwaysOn:(0,u.cn)(t,P.s6.CloseFloatOn);break;case v.ProtoPlayerCloseButtonMode.Off:(0,u.cn)(t,P.s6.CloseFloatOff);break;case v.ProtoPlayerCloseButtonMode.OnHover:(0,u.cn)(t,P.s6.CloseFloatHover)}}}Ib(t){const{skipOffset:i}=t;return{isAutoPlay:this.Ab.playbackMode===v.ProtoPlayerPlaybackModeEnum.Autoplay,skipOffset:i,isSkippable:(0,s.hj)(i)}}eI(){this.my=!0,this.Vc.contentStart.next(),this.ky()}Eb(){this.breakPointsHandler.updateWidth(this.$playerContainer.clientWidth)}My(){const{clientWidth:t,clientHeight:i}=this.$experienceContainer;return!(0,$i.ON)({width:t,height:i})&&!this.isBelowSmBreakpoint(t)||((0,u.cn)(this.$experienceContainer,P.Gj.NoHeight),this.sI())}sI(){return me.includes(this.app.config.bundleID)}nI(t){try{const{display:i,width:e,height:s,flex:n,maxWidth:r,minWidth:o}=this.app.services.GlobalDomUtilsService.getComputedStyle(t),{width:h,height:a}=t.getBoundingClientRect(),c={display:i,compWidth:e,boundWidth:h,compHeight:s,boundHeight:a,flex:n,maxWidth:r,minWidth:o};return{type:t.nodeName,styles:JSON.stringify(c)}}catch(t){return{err:"BaseExperience_getElementInfo_error"}}}oI(){if(!(0,h.Vm)([95,5]))return;const t={parent:this.nI(this.$experienceContainer.parentElement),main:this.nI(this.$experienceContainer)};(0,p.n)({message:"BaseExperience_invalid_dimensions",level:p.D.INFO,exception:JSON.stringify(t)})}hI(){this.ob=new ai(this.Ab.adBreaks)}aI(){(0,u.cn)(this.$experienceContainer,P.s6.ClickToPlayThumbnail)}cI(){}renderExperience(t,i,e,s){this.Ab=t,this.app=i,this.$experienceContainer=e,s&&s(),this.Fy(),this.app.services.ViewabilityService.setViewableThreshold(this.iy),this.generateHTML(),this.hI(),this.app.services.ResizeObserver.on(this.$experienceContainer,this.Ey),this.My()?this.mediator.publish(this,w.Uh.CanStart):this.oI()}start(){return fe(this,void 0,void 0,(function*(){this.sy=!0,this.Dc.playerDimensions={height:this.$playerContainer.clientHeight,width:this.$playerContainer.clientWidth},(0,u.cn)(this.$experienceContainer,P.sN.MainContainerFlex),this.mediator.publish(this,w.Xh.SessionRendered),this.Kb(),this.Lb(),this.Ab.floatingSettings.floatingMode===v.ProtoPlayerFloatingMode.Always?this.Gb():(this.Jy(),this.Hb()),(0,u.Tp)(this.$playerContainer),this.hb=this.dI(),(0,S.BZ)(this.Ab.lineItemSettings.lineItems)&&this.lb(),this.Ab.disableAdvertising||C._.isBannerBlocked?this.hb.adBlockerStatusChange(C._.isBannerBlocked):this.app.config.isOVPDomain?this.Py.push(C._.onAdBlockerDetected().subscribe((t=>{this.hb.adBlockerStatusChange(t)}))):this.hb.adBlockerStatusChange(C._.isBannerBlocked),this.app.config.isMobile||this.Ab.soundMode!==v.ProtoPlayerSoundMode.Hover||this.Xb(),this.Ab.isCloseButton&&this.iI(),this.Ab.displayAdCountdown&&(0,u.cn)(this.$playerContainer,P.s6.AdShowCountdown),this.Ab.playbackMode===v.ProtoPlayerPlaybackModeEnum.ClickToPlay&&this.aI();try{this.xb()}catch(t){(0,p.n)({message:"BaseExperience_initAdsController",exception:t.message,callStack:t.stack,level:p.D.INFO})}C._.isBannerBlocked||C._.detectUsingScript().then((t=>{t&&(this.Vc.sessionAdBlocked.next({adBlockDetectionType:i.ev.Network}),this.hb.disableAdvertising())})),this.app.config.isMobile||this.yy.push(this.onReady().pipe((0,dt.h)((t=>!!t)),qi((()=>{this.cI()})),(0,Hi.w)((()=>{var t;return null===(t=this.Ef)||void 0===t?void 0:t.getShortcutsObservable()}))).subscribe((t=>this.Fb(t))))}))}play(){var t;null===(t=this.adHandler)||void 0===t||t.play()}pause(){var t;null===(t=this.adHandler)||void 0===t||t.pause()}setVolume(t){this.setNewVolume(t),this.Jb()}getSize(){return{width:this.$experienceContainer.clientWidth,height:this.$experienceContainer.clientHeight}}setSize(t,i){(0,$i.ON)({width:t,height:i})||(0,u.T7)(this.$experienceContainer,{width:`${t}px`,height:`${i}px`})}setCustomMacros(t){var i;this.app.services.MacrosService.addExtraMacros(t),null===(i=this.adHandler)||void 0===i||i.setCustomMacros(t)}isViewable(){return this.app.services.ViewabilityService.check({element:this.$playerContainer,threshold:this.Yv})}setViewableThreshold(t){(0,p.n)({message:"setViewableThreshold_usage",level:p.D.INFO,exception:this.app.config.sdkVersion},{throttle:1,shouldSendMaxLog:!1}),this.app?this.app.services.ViewabilityService.setViewableThreshold(t):this.iy=t}setAmpUserConsent(t){this.app.services.UserManagerService.setAmpUserConsent(t)}triggerDestroy(){this.app.services.EventsStorageService.destroy(),this.mediator.publish(this,w.Uh.Destroy)}updateJsQueryTargeting(t){(0,s.$K)(this.adHandler)?this.adHandler.updateJsQueryTargeting(t):this.Ab.queryJsTargeting=(0,ue.S1)(this.Ab.queryJsTargeting,t)}removeJsQueryTargeting(t){(0,s.$K)(this.adHandler)?this.adHandler.removeJsQueryTargeting(t):this.Ab.queryJsTargeting=(0,ue.G_)(this.Ab.queryJsTargeting,t)}disableAdvertising(){this.hb.disableAdvertising()}enableAdvertising(){this.hb.enableAdvertising()}enableFloatingMode(){var t;null===(t=this.floatingModule)||void 0===t||t.enableFloatingMode()}disableFloatingMode(){var t;null===(t=this.floatingModule)||void 0===t||t.disableFloatingMode()}isFloatingModeEnabled(){return this.floatingModule?this.floatingModule.isFloatingModeEnabled():!!this.alwaysFloatingModule}setFloatingSettings(t){this.floatingModule?this.floatingModule.setFloatingSettings(t):this.alwaysFloatingModule.setFloatingSettings(t)}getFloatingSettings(){var t;return this.floatingModule?this.floatingModule.getFloatingSettings():null===(t=this.alwaysFloatingModule)||void 0===t?void 0:t.getFloatingSettings()}setLineItemMetadata(t,i){(0,s.$K)(this.adHandler)?this.adHandler.setLineItemMetadata(t,i):i({success:!1,errorReason:si.AdManagerNotInitialized})}onReady(){return this.Wf?this.Wf.onReady():ce(!0)}getApiConfig(){const t=JSON.parse(JSON.stringify(this.Ab.apiConfig));return delete t.settings._connatixInternals,t}getSessionDataConfig(){return{playerInstanceID:this.app.config.appId}}destroy(){var t;(0,it.i)(this.yy),(0,it.i)(this.Py),(0,it.i)(this.by),this.adHandler&&((0,it.i)(this.Ay),this.fb.unsubscribe(),this.adHandler.destroy()),this.hb&&this.hb.destroy(),this.floatingModule&&(this.floatingModule.destroy(!0),this.floatingModule=null,(0,it.i)(this.Sy)),null===(t=this.Ef)||void 0===t||t.destroy()}}var ye,be,Ie;!function(t){t[t.Unknown=0]="Unknown",t[t.TimeoutBetweenAds=1]="TimeoutBetweenAds",t[t.InImpression=2]="InImpression",t[t.LinearDemandMissing=3]="LinearDemandMissing",t[t.ForceDisable=4]="ForceDisable"}(ye||(ye={}));class we{constructor(t,i,e,s,n,r,o,h,a,c,d){this.uI=t,this.pI=i,this.Ts=e,this.Dc=s,this.fI=n,this.mI=r,this.gI=o,this.vI=h,this._appSettings=a,this.Jv=c,this.yI=d,this.bI=x.Normal,this.Fc=[],this.II=new J.x,this.wI=new J.x,this.SI=new J.x,this.AI=new J.x,this._I=new J.x,this.xI=new J.x,this.TI=new J.x,this.kI=new J.x,this.CI=new J.x,this.EI=new J.x,this.MI=new J.x,this.LI=new J.x,this.BI=new J.x,this.RI=new J.x,this.OI=this.DI(),this.VI();const l=L.h.getSessionChildContainer(this.vI.config.sessionId).resolve(vt.k);this.FI=this.NI(l),this.jI(),this.$I=this.UI(l),this.$I&&this.qI(),this.pI&&this.disableAdvertising()}get onMissedImpression(){return this.EI.asObservable()}inFloatingChanged(t){this.uI=t,this.OI.inFloatingChanged(t)}canPrefetchAds(t){this.OI.canPrefetchAds(t)}hasAdsEligibleForFill(){return this.OI.hasAdsEligibleForFill()}HI(t,i){const e=[{container:this.zI,width:t,height:i,type:v.ProtoAdType.Overlay},{container:this.zI,width:t,height:i,type:v.ProtoAdType.Video},{container:this.WI,width:t,height:i,type:v.ProtoAdType.Nonlinear}];return this.WI||e.pop(),e}VI(){this.Fc.push(this.OI.onAdsEnable.subscribe((t=>{this.II.next(t)})),this.OI.onPrefetchStart.subscribe((()=>{this.SI.next()})))}qI(){var t,i,e;this.Fc.push(null===(t=this.$I)||void 0===t?void 0:t.onVpaidEvent.subscribe((t=>{this.wI.next(t)})),null===(i=this.$I)||void 0===i?void 0:i.onNonLinearEvent.subscribe((t=>{t.type===pe.gx.ShowNonLinearEvent&&this.linearInImpression&&this.$I.pause(),this.MI.next(t)})),null===(e=this.$I)||void 0===e?void 0:e.onExperienceEvent.subscribe((t=>{this.LI.next({type:t.type,payload:t.payload})})),this.OI.onNonlinearImpressionPrice.subscribe((t=>{this.BI.next(t)})),this.OI.onNonlinearImpressionRevenue.subscribe((t=>{this.RI.next(t)})))}jI(){this.Fc.push(this.FI.onVpaidEvent.subscribe((t=>{this.wI.next(t)})),this.FI.onUiComponentEvent.subscribe((t=>{this._I.next(t)})),this.FI.onExperienceEvent.subscribe((t=>{this.xI.next({type:t.type,payload:t.payload})})),this.FI.onLinearEvent.subscribe((t=>{var i;t.type===pe.lc.ShowLinearEvent&&(null===(i=this.$I)||void 0===i||i.pause()),this.AI.next(t)})),this.OI.onLinearImpressionPrice.subscribe((t=>{this.TI.next(t)})),this.OI.onMissedImpression.subscribe((t=>{this.EI.next(t)})),this.OI.onLinearImpressionRevenue.subscribe((t=>{this.kI.next(t)})),this.OI.onLinearNoFill.subscribe((()=>{this.CI.next()})))}GI(t,i,e){this.OI.initAd(t,i,this.bI,1,e,this.HI(t,i),this.vI)}setLineItemMetadata(t,i){this.OI.setLineItemMetadata(t,i)}adStateChange(t,i){var e;this.FI.adStateChange(t,i),null===(e=this.$I)||void 0===e||e.adStateChange(t,i)}contentPlaybackStateChanged(t){var i;null===(i=this.$I)||void 0===i||i.contentPlaybackStateChanged(t)}disableAds(t,i){this.OI.disableAds(t,i)}enableAds(t){this.OI.enableAds(t)}disableAdvertising(){this.OI.disableAdvertising()}enableAdvertising(){this.OI.enableAdvertising()}start(t,i,e,s=!1,n=!1){n&&this.startNonLinear(),this.startLinear(e,s),this.GI(t,i,e)}stopAd(t){var i;this.FI.stopAd(t),null===(i=this.$I)||void 0===i||i.stopAd(t)}play(){this.FI.play()}pause(){var t;this.FI.pause(),null===(t=this.$I)||void 0===t||t.pause()}togglePlay(t=!1){this.FI.togglePlay(t)}resumeWithoutUserInteraction(t){var i;this.FI.resumeWithoutUserInteraction(),null===(i=this.$I)||void 0===i||i.resumeWithoutUserInteraction(t)}resizeAd(t,i,e,s){var n;this.setVastViewMode(e),this.FI.resizeAd(t,i),null===(n=this.$I)||void 0===n||n.resizeAd(t,i,s)}setPlayerOrientation(t){this.OI.setPlayerOrientation(t)}updateJsQueryTargeting(t){this.OI.updateJsQueryTargeting(t)}removeJsQueryTargeting(t){this.OI.removeJsQueryTargeting(t)}setVastViewMode(t){this.bI=t,this.OI.setVastViewMode(t)}contentChanged(){this.OI.onContentChange()}newLinearAdOpportunity(t){this.OI.newLinearAdOpportunity(t)}destroy(){var t,i,e;(0,it.i)(this.Fc),this.FI.destroy(),null===(t=this.$I)||void 0===t||t.destroy(),null===(i=this.OI)||void 0===i||i.disableAds(Bi.LINEAR,{disableReason:ye.Unknown}),null===(e=this.OI)||void 0===e||e.disableAds(Bi.NONLINEAR,{disableReason:ye.Unknown}),this.OI.destroy()}get onAdsEnable(){return this.II.asObservable()}get onVpaidEvent(){return this.wI.asObservable()}get onPrefetchStart(){return this.SI.asObservable()}startNonLinear(){var t;null===(t=this.$I)||void 0===t||t.start()}contentEnded(){var t;null===(t=this.$I)||void 0===t||t.pause()}get onNonLinearEvent(){return this.MI.asObservable()}get onNonLinearExperienceEvent(){return this.LI.asObservable()}get onNonLinearImpressionPrice(){return this.BI.asObservable()}get onNonLinearImpressionRevenue(){return this.RI.asObservable()}get nonLinearInImpression(){return!!this.$I&&this.$I.inImpression}get WI(){var t;return null===(t=this.$I)||void 0===t?void 0:t.adContainer}startLinear(t,i=!1){this.FI.start(t,i)}setMediaRestrictions(t){this.OI.setMediaRestrictions(t)}getNewLinearAdOpportunity(){return this.OI.getNewLinearAdOpportunity()}getLinearVolume(){return this.FI.getVolume()}setLinearVolume(t){this.FI.setVolume(t)}increaseVolume(t,i=!1){this.FI.increaseVolume(t,i)}decreaseVolume(t,i=!1){this.FI.decreaseVolume(t,i)}toggleMute(t=!1){this.FI.toggleMute(t)}hideLinear(){this.FI.hide()}showLinear(){this.FI.show()}updateContinueReadingCard(){this.FI.updateContinueReadingCard()}setContinueReadingCard(t){this.FI.setContinueReadingCard(t)}hideContinueReadingCard(){this.FI.hideContinueReadingCard()}setAdMarkerTitle(t){this.FI.setAdMarkerTitle(t)}hideAdMarkerTitle(){this.FI.hideAdMarkerTitle()}enterAdPodLoadingState(){this.FI.enterAdPodLoadingState()}setAdLoadingBackgroundUrl(t){this.FI.setAdLoadingBackgroundUrl(t)}updateLinearPodRemainingTime(t){this.OI.updateLinearPodRemainingTime(t)}setCustomMacros(t){this.OI.setCustomMacros(t)}enablePrefetchForLinearity(t){this.OI.enablePrefetchForLinearity(t)}get onLinearEvent(){return this.AI.asObservable()}get onLinearUiComponentEvent(){return this._I.asObservable()}get onLinearExperienceEvent(){return this.xI.asObservable()}get onLinearImpressionPrice(){return this.TI.asObservable()}get onLinearImpressionRevenue(){return this.kI.asObservable()}get onLinearNoFill(){return this.CI.asObservable()}get linearInImpression(){return this.FI.inImpression}get zI(){return this.FI.adContainer}get XI(){return this.FI.secondaryAdContainer}get linearAdUserInterface(){return this.FI.adUserInterface}get onFullcreenChange(){return this.FI.onFullcreenChange}get linearAdInWin(){return this.FI.adInWin}get firstLinearAdShown(){return this.FI.firstAdShown}get inAdPodLoadingState(){return this.FI.inAdPodLoadingState}getLinearAdContainerWidth(){return this.FI.getMainAdContainerWidth()}userInteraction(t){this.OI.userInteraction(t)}}!function(t){t[t.NoPrefetch=0]="NoPrefetch",t[t.StartSessionPrefetch=1]="StartSessionPrefetch",t[t.MidSessionPrefetch=2]="MidSessionPrefetch"}(be||(be={})),function(t){t[t.ON_BID=0]="ON_BID",t[t.ON_BID_LOADING=1]="ON_BID_LOADING",t[t.ON_BID_LOADING_CONSUMED=2]="ON_BID_LOADING_CONSUMED",t[t.ON_BID_LOADED=3]="ON_BID_LOADED",t[t.ON_BID_STARTING=4]="ON_BID_STARTING",t[t.ON_BID_IN_IMPRESSION=5]="ON_BID_IN_IMPRESSION",t[t.ON_BID_LOADED_CONSUMED=6]="ON_BID_LOADED_CONSUMED"}(Ie||(Ie={}));const Se=2,Pe=41;function Ae(t){return(t+Pe)*Se}function _e(t){return t/Se-Pe}class xe{constructor(){this.JI=Date.now(),this.YI={advertiser:{}}}addPrebid(t){(0,s.$K)(this.YI.advertiser[t])||this.KI(t),this.YI.advertiser[t].prebidData.push({timestamp:Date.now()})}addBid(t,i){(0,s.$K)(this.YI.advertiser[t])||this.KI(t),this.YI.advertiser[t].bidsFloorPriceList.push({timestamp:Date.now(),floorPrice:i})}addImpression(t,i){(0,s.$K)(this.YI.advertiser[t])||this.KI(t),this.YI.advertiser[t].impressionRevenueList.push({timestamp:Date.now(),obfuscatedPrice:i})}shouldRequestLineItem(t){const i=Date.now();return!(this.ZI(i,3)&&this.tw(t,i,5)<-.5&&this.iw(t,i,3)>=11.5&&this.ew(t,i,10,.1)<.35)}ZI(t,i){return t-this.JI>=i*Lt.uD}tw(t,i,e){const n=this.YI.advertiser[t];if(!(0,s.$K)(n))return-1;const r=this.rw(n.impressionRevenueList,i,e).map((t=>t.obfuscatedPrice));let o=0;return(0,S.BZ)(r)&&(o=r.reduce(((t,i)=>t+Ae(i)))),this.ow(o)}iw(t,i,e){const n=this.YI.advertiser[t];if(!(0,s.$K)(n))return-1;const r=this.rw(n.prebidData,i,e).length;return this.ow(r)}ew(t,i,e,n){const r=this.YI.advertiser[t];if(!(0,s.$K)(r))return-1;const o=this.rw(r.impressionRevenueList,i,e).map((t=>t.floorPrice)),h=this.hw(o,n);return this.ow(h)}rw(t,i,e){const s=i-Lt.s_,n=i-e*Lt.uD,r=[];for(let i=t.length-1;i>=0&&t[i].timestamp>=n;i--)t[i].timestamp<=s&&r.push(t[i]);return r}ow(t){return 0===t?-1:t}KI(t){this.YI.advertiser[t]={prebidData:[],bidsFloorPriceList:[],impressionRevenueList:[]}}hw(t,i){if(0===t.length)return 0;if(i<=0)return t[0];if(i>=1)return t[t.length-1];const e=((t=t.sort(((t,i)=>t-i))).length-1)*i,s=Math.floor(e),n=s+1,r=e%1;return n>=t.length?t[s]:t[s]*(1-r)+t[n]*r}}var Te,ke=r(3775);!function(t){t[t.XmlParsingError=100]="XmlParsingError",t[t.VastSchemaError=101]="VastSchemaError",t[t.InvalidVastVersionError=102]="InvalidVastVersionError",t[t.ExpectingDifferentLinearity=201]="ExpectingDifferentLinearity",t[t.GeneralLinearError=400]="GeneralLinearError",t[t.MediaFileNotFound=401]="MediaFileNotFound",t[t.MediaFileUriTimeout=402]="MediaFileUriTimeout",t[t.MediaFileNotSupported=403]="MediaFileNotSupported",t[t.VerificationUnitNotExecuted=410]="VerificationUnitNotExecuted",t[t.WrapperVastUriTimeout=301]="WrapperVastUriTimeout",t[t.WrapperLimitReached=302]="WrapperLimitReached",t[t.NoVastResponseAfterWrapper=303]="NoVastResponseAfterWrapper",t[t.ImpressionTimeout=304]="ImpressionTimeout",t[t.NonlinearGeneralError=500]="NonlinearGeneralError",t[t.NonlinearExpectingDifferentSize=501]="NonlinearExpectingDifferentSize",t[t.NonlinearUnableToFetchResource=502]="NonlinearUnableToFetchResource",t[t.NonlinearSupportedTypeNotFound=503]="NonlinearSupportedTypeNotFound",t[t.GeneralError=900]="GeneralError"}(Te||(Te={}));class Ce{constructor(){this.creativeView=[],this.start=[],this.firstQuartile=[],this.midpoint=[],this.thirdQuartile=[],this.impression=[],this.viewable_impression=[],this.complete=[],this.mute=[],this.unmute=[],this.pause=[],this.rewind=[],this.resume=[],this.fullscreen=[],this.exitFullscreen=[],this.expand=[],this.collapse=[],this.close=[],this.closeLinear=[],this.acceptInvitationLinear=[],this.acceptInvitation=[],this.skip=[],this.progress=[],this.playerExpand=[],this.playerCollapse=[],this.adExpand=[],this.adCollapse=[],this.fullScreen=[],this.canPlayThrough=[],this.stalled=[],this.waiting=[],this.otherAdInteraction=[]}}class Ee{constructor(t){this.clickTrackings=[],this.customClicks=[],this.errorUrls=[],this.impressions=[],this.trackingEvents=new Ce,t.inLine?this.aw(t.inLine):this.cw(t.wrapper)}aw(t){this.dw(t.errors),this.lw(t.impressions),this.uw(t.creatives)}cw(t){this.dw(t.errors),this.lw(t.impressions),this.uw(t.creatives)}pw(t){this.fw(t.trackingEvents),this.mw(t.videoClicks)}mw(t){t&&(this.gw(t.clickTrackings),this.yw(t.customClicks))}gw(t){this.clickTrackings.push(...t)}yw(t){this.customClicks.push(...t)}fw(t){t.forEach((t=>{try{this.trackingEvents[t.name].push(t.uri)}catch(i){(0,p.n)({message:"AdManager_VastResponse_tracker",exception:`${t.name}`,callStack:i.stack,level:p.D.INFO})}}))}uw(t){t.forEach((t=>{t.linear?this.pw(t.linear):t.nonLinear&&this.fw(t.nonLinear.trackingEvents)}))}dw(t){this.errorUrls.push(...t)}lw(t){this.impressions.push(...t)}}const Me={[v.ProtoTrackerTriggerType.Impression]:"adImpression",[v.ProtoTrackerTriggerType.Complete25Pc]:"adQuartileFirst",[v.ProtoTrackerTriggerType.Complete50Pc]:"adQuartileSecond",[v.ProtoTrackerTriggerType.Complete75Pc]:"adQuartileThird",[v.ProtoTrackerTriggerType.ViewCompletion]:"adQuartileFourth",[v.ProtoTrackerTriggerType.VideoClick]:"adClick",[v.ProtoTrackerTriggerType.Pause]:"adPause",[v.ProtoTrackerTriggerType.Resume]:"adResume",[v.ProtoTrackerTriggerType.Mute]:"adMute",[v.ProtoTrackerTriggerType.Unmute]:"adUnmute"};class Le{constructor(){this.adError=[],this.adWin=[],this.adImpression=[],this.adViewableImpression=[],this.adStarted=[],this.adVideoStart=[],this.adQuartileFirst=[],this.adQuartileSecond=[],this.adQuartileThird=[],this.adQuartileFourth=[],this.adClick=[],this.adPause=[],this.adResume=[],this.adSkip=[],this.adMute=[],this.adUnmute=[],this.adUserClose=[],this.adUserAcceptInvitation=[],this.adUserMinimize=[]}static trackError(t,i,e,s,n=Te.GeneralError,r=window.document.head){this.track(t,i,e,s,r,n)}static track(t,i,e,s,n=window.document.head,r){if(!Array.isArray(t))return;const{width:o,height:a}=s.adContainerState.get(e.adType),{adBreakType:c}=s.adBreakState,{mediaDescription:d,mediaDuration:l,mediaId:p,mediaUrl:f,mediaTitle:m}=s.media;t.forEach((t=>{if(t.url)try{const s=i.replace(t.url,e.vendorId,{adMacros:{adWidth:o,adHeight:a,adPostion:c,errorCode:r},mediaMacros:{mediaDescription:d,mediaDuration:l,mediaId:p,mediaUrl:f,mediaTitle:m}});switch(t.type){case v.ProtoTrackerType.Image:(0,h.Hh)([s],window);break;case v.ProtoTrackerType.Javascript:(0,u.dZ)({src:s},window.document.head,window);break;case v.ProtoTrackerType.IAS:(0,u.dZ)({src:s,attributes:[{name:ke.b.GarbageCollector,value:""}]},n,window)}}catch(t){}}))}}function Be(t,i){t.forEach((t=>function(t,i){(function(t,i){return i[Me[t]]})(t.trigger,i).push({type:t.type,url:t.url})}(t,i)))}function Re(t){return{type:v.ProtoTrackerType.Image,url:t}}function Oe(t){return t.map((t=>Re(t)))}var De;!function(t){t.HandlingSdkUrl="HandlingSdkUrl",t.NetworkRequestUrl="NetworkRequestUrl",t.InvalidCreativeType="InvalidCreativeType",t.XmlInvalidString="XmlInvalidString",t.XmlParseGeneral="XmlParseGeneral",t.XmlInvalidTree="XmlInvalidTree",t.XmlInvalidAd="XmlInvalidAd",t.XmlAdaptorWrapperLimit="XmlAdaptorWrapperLimit",t.VastVersionNotSupported="VastVersionNotSupported",t.VastMediaFilesNotSupported="VastMediaFilesNotSupported",t.HTMLUnknownMimeType="HTMLUnknownMimeType",t.HTMLNotEnoughData="HTMLNotEnoughData",t.ImaAdsManagerInit="ImaAdsManagerInit",t.ImaVastEmptyResponse="ImaVastEmptyResponse",t.ImaRequestException="ImaRequestException",t.ImaTimeout="ImaTimeout",t.ImaInvalidResponse="ImaInvalidResponse",t.InvalidCreativeUrl="InvalidCreativeUrl",t.BidIsNotTargetingAllowedEver="BidIsNotTargetingAllowedEver"}(De||(De={}));const Ve={[De.HandlingSdkUrl]:v.ConnatixNoBidReasonEnum.CsRequestException,[De.NetworkRequestUrl]:v.ConnatixNoBidReasonEnum.CsRequestException,[De.InvalidCreativeType]:v.ConnatixNoBidReasonEnum.CsInvalidResponse,[De.XmlInvalidString]:v.ConnatixNoBidReasonEnum.CsEmptyResponse,[De.XmlParseGeneral]:v.ConnatixNoBidReasonEnum.CsInvalidResponse,[De.XmlInvalidTree]:v.ConnatixNoBidReasonEnum.CsInvalidResponse,[De.XmlInvalidAd]:v.ConnatixNoBidReasonEnum.CsInvalidResponse,[De.XmlAdaptorWrapperLimit]:v.ConnatixNoBidReasonEnum.CsInvalidResponse,[De.VastVersionNotSupported]:v.ConnatixNoBidReasonEnum.VastVersionNotSupported,[De.HTMLUnknownMimeType]:v.ConnatixNoBidReasonEnum.CsInvalidResponse,[De.HTMLNotEnoughData]:v.ConnatixNoBidReasonEnum.CsInvalidResponse,[De.ImaAdsManagerInit]:v.ConnatixNoBidReasonEnum.CsRequestException,[De.ImaVastEmptyResponse]:v.ConnatixNoBidReasonEnum.CsInvalidResponse,[De.ImaRequestException]:v.ConnatixNoBidReasonEnum.CsRequestException,[De.ImaTimeout]:v.ConnatixNoBidReasonEnum.Timeout,[De.ImaInvalidResponse]:v.ConnatixNoBidReasonEnum.CsInvalidResponse,[De.InvalidCreativeUrl]:v.ConnatixNoBidReasonEnum.CsRequestException,[De.BidIsNotTargetingAllowedEver]:v.ConnatixNoBidReasonEnum.BidIsNotTargetingAllowedEver,[De.VastMediaFilesNotSupported]:v.ConnatixNoBidReasonEnum.CsInvalidResponse};class Fe{constructor(t){this.data=t,(0,s.QM)(this.data.cnxBidId)||(this.data.cnxBidId=(0,h.qs)())}}var Ne;!function(t){t[t.Rtb=1]="Rtb",t[t.HeaderBidder=2]="HeaderBidder",t[t.Tam=3]="Tam"}(Ne||(Ne={}));const je={[v.ProtoCreativeTypeEnum.Rtb]:Ne.Rtb,[v.ProtoCreativeTypeEnum.HeaderBidder]:Ne.HeaderBidder,[v.ProtoCreativeTypeEnum.Tam]:Ne.Tam,[v.ProtoCreativeTypeEnum.TamDeal]:Ne.Tam,[v.ProtoCreativeTypeEnum.TamPrivateAuction]:Ne.Tam};var $e,Ue,qe,He,ze=r(5742),We=r(3199);!function(t){t.AppNexus="appnexus",t.IndexExchange="ix",t.OpenX="openx",t.Pubmatic="pubmatic",t.RhythmOne="rhythmone",t.Rubicon="rubicon",t.SpotX="spotx",t.Telaria="telaria",t.MediaNet="medianet",t.Adman="adman",t.SynacorMedia="synacormedia",t.Undertone="undertone",t.AmxRTB="amx",t.Smaato="smaato",t.SmartAdServer="smartadserver",t.TheMediaGrid="grid",t.Rise="rise",t.YahooSSP="yahoossp",t.Unruly="unruly",t.Kargo="kargo",t.SmileWanted="smilewanted",t.TrustX="trustx",t.EmxDigital="emx_digital",t.KrushMedia="krushmedia",t.Conversant="conversant",t.Criteo="criteo",t.TripleLift="triplelift",t.PulsePoint="pulsepoint",t.Adtelligent="adtelligent",t.Yieldmo="yieldmo",t.PgamMedia="pgammedia",t.NextMillennium="nextMillennium",t.AdYouLike="adyoulike",t.FreeWheelSSP="freewheel-ssp",t.ColossusSSP="colossusssp",t.ResetDigital="resetdigital",t.MediaFuse="mediafuse",t.Sharethrough="sharethrough"}($e||($e={}));class Ge{static logMissingRequireParam(t,i,e){(0,p.n)({level:p.D.CRITICAL,message:`PrebidJS_${t}_adapter_missing_${i}_li_${e}`})}static logMissingRequireIntegrationsParams(t,i,e){const s=i.map((t=>t.join("_and_"))).join("_or_");(0,p.n)({level:p.D.CRITICAL,message:`PrebidJS_${t}_adapter_needs_${s}_li_${e}`})}get config(){return this.bw}}!function(t){t.NATIVE="native",t.VIDEO="video",t.BANNER="banner"}(Ue||(Ue={}));!function(t){t.Instream="instream",t.Outstream="outstream"}(qe||(qe={}));!function(t){t[t.Nonsecure=0]="Nonsecure",t[t.Secure=1]="Secure"}(He||(He={}));const Xe={[$e.AppNexus]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:32,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.hj)(e.placementId))return void Ge.logMissingRequireParam("appnexus","placementId",i.lineItemId);const{floorPrice:n}=i;(0,s.r)(n)&&(e.reserve=n);const{deviceId:r,os:o}=i;if((0,s.QM)(r))switch(e.app=Object.assign({},e.app),o){case zt.M.Android:e.app.device_id={aaid:r};break;case zt.M.Ios:e.app.device_id={idfa:r}}return e.video=Object.assign(Object.assign({},e.video),{skippable:!!i.skippabilitySettings.skip,skipoffset:i.skippabilitySettings.skipafter}),e}},[$e.IndexExchange]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:10,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.QM)(e.siteId))return void Ge.logMissingRequireParam("ix","siteId",i.lineItemId);const{floorPrice:n,isOutstream:r}=i;if((0,s.r)(n)&&(e.bidFloor=n,e.bidFloorCur="USD"),r){const{inFloating:t,hasFloatingCapability:s,playerWidth:n,playerHeight:r}=i;e.video.playerConfig={floatOnScroll:s,floatSize:t?[n,r]:void 0}}return e}},[$e.OpenX]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:69,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t),{lineItemId:n}=i;if(!(0,s.QM)(e.unit))return void Ge.logMissingRequireParam("openx","unit",n);if(!(0,s.QM)(e.delDomain))return void Ge.logMissingRequireParam("openx","delDomain",n);const{floorPrice:r}=i;return(0,s.r)(r)&&(e.customFloor=r),e}},[$e.Pubmatic]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:76,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.QM)(e.publisherId))return void Ge.logMissingRequireParam("pubmatic","publisherId",i.lineItemId);const n=i.floorPrice;return(0,s.r)(n)&&(e.kadfloor=String(n)),i.isOutstream&&(e.outstreamAU=i.adUnitCode),e.kadpageurl=i.pageUrl,e}},[$e.RhythmOne]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:36,gdprSupport:!0,ccpaSupport:!1}}getBidParams(t,i){if((0,s.QM)(t.placementId))return t;Ge.logMissingRequireParam("rhythmone","placementId",i.lineItemId)}},[$e.Rubicon]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:52,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t),{lineItemId:n}=i;if(!(0,s.hj)(e.accountId))return void Ge.logMissingRequireParam("rubicon","accountId",n);if(!(0,s.hj)(e.siteId))return void Ge.logMissingRequireParam("rubicon","siteId",n);if(!(0,s.hj)(e.zoneId))return void Ge.logMissingRequireParam("rubicon","zoneId",n);const r=i.floorPrice;return(0,s.r)(r)&&(e.floor=r),e}},[$e.SpotX]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:165,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.QM)(e.channel_id))return void Ge.logMissingRequireParam("spotx","channel_id",i.lineItemId);(0,s.QM)(e.ad_unit)||(e.ad_unit=i.isOutstream?qe.Outstream:qe.Instream);const{floorPrice:n,isOutstream:r,bidSlotId:o}=i;return(0,s.r)(n)&&(e.price_floor=n),r&&(e.outstream_options={slot:o}),e.page=i.pageUrl,e}},[$e.Telaria]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:52,gdprSupport:!0,ccpaSupport:!1}}getBidParams(t,i){const e=Object.assign({},t),{lineItemId:n,pageUrl:r}=i;if((0,s.QM)(t.adCode)){if((0,s.QM)(t.supplyCode))return e.srcPageUrl=r,t;Ge.logMissingRequireParam("telaria","supplyCode",n)}else Ge.logMissingRequireParam("telaria","adCode",n)}},[$e.MediaNet]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:142,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t),{lineItemId:n}=i;if(!(0,s.QM)(e.cid))return void Ge.logMissingRequireParam("medianet","cid",n);if(!(0,s.QM)(e.crid))return void Ge.logMissingRequireParam("medianet","crid",n);const{floorPrice:r}=i;return(0,s.r)(r)&&(e.bidFloor=r),e.site=Object.assign(Object.assign({},e.site||{}),{page:i.pageUrl}),e}},[$e.Adman]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:149,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.QM)(e.placementId))return void Ge.logMissingRequireParam("adman","placementId",i.lineItemId);const{floorPrice:n}=i;return(0,s.r)(n)&&(e.bidfloor=n),e.traffic=Ue.VIDEO,e}},[$e.SynacorMedia]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:void 0,gdprSupport:!1,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t),{lineItemId:n}=i;if(!(0,s.QM)(e.seatId))return void Ge.logMissingRequireParam("synacormedia","seatId",n);if(!(0,s.QM)(e.tagId))return void Ge.logMissingRequireParam("synacormedia","tagId",n);const{floorPrice:r}=i;return(0,s.r)(r)&&(e.bidfloor=r),e}},[$e.Undertone]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:677,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t),{lineItemId:n}=i;if((0,s.hj)(e.publisherId)){if((0,s.QM)(e.placementId))return e.video=Object.assign(Object.assign({},e.video||{}),{skippable:!!i.skippabilitySettings.skip}),e;Ge.logMissingRequireParam("undertone","placementId",n)}else Ge.logMissingRequireParam("undertone","publisherId",n)}},[$e.AmxRTB]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:737,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.QM)(e.tagId))return void Ge.logMissingRequireParam("amx","tagId",i.lineItemId);const{floorPrice:n}=i;return(0,s.r)(n)&&(e.floor=n),e}},[$e.Smaato]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:82,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const{lineItemId:e}=i;if((0,s.QM)(t.publisherId)){if((0,s.QM)(t.adspaceId))return t;Ge.logMissingRequireParam("smaato","adspaceId",e)}else Ge.logMissingRequireParam("smaato","publisherId",e)}},[$e.SmartAdServer]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:18,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t),{lineItemId:n}=i;if(!(0,s.hj)(e.siteId))return void Ge.logMissingRequireParam("smartadserver","siteId",n);if(!(0,s.hj)(e.pageId))return void Ge.logMissingRequireParam("smartadserver","pageId",n);if(!(0,s.hj)(e.formatId))return void Ge.logMissingRequireParam("smartadserver","formatId",n);const{floorPrice:r}=i;return(0,s.r)(r)&&(e.bidfloor=r),e}},[$e.TheMediaGrid]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:686,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.r)(e.uid))return void Ge.logMissingRequireParam("grid","uid",i.lineItemId);const{floorPrice:n}=i;return(0,s.r)(n)&&(e.bidFloor=n),e}},[$e.Rise]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:1043,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.QM)(e.org))return void Ge.logMissingRequireParam("rise","org",i.lineItemId);const{floorPrice:n}=i;return(0,s.r)(n)&&(e.floorPrice=n),e}},[$e.YahooSSP]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:25,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t),n=(0,s.QM)(e.pos)&&(0,s.QM)(e.dcn),r=(0,s.QM)(e.pubId);if(!n&&!r)return void Ge.logMissingRequireParam("yahoossp","required",i.lineItemId);const{floorPrice:o}=i;return(0,s.r)(o)&&(e.bidOverride={imp:{bidfloor:o}}),e}},[$e.Unruly]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:36,gdprSupport:!1,ccpaSupport:!1}}getBidParams(t,i){const e=Object.assign({},t);if((0,s.hj)(e.siteId))return i.isOutstream&&(e.featureOverrides={canRunUnmissable:!0}),(0,s.r)(i.floorPrice)&&(e.floor=i.floorPrice),e;Ge.logMissingRequireParam("unruly","siteId",i.lineItemId)}},[$e.Kargo]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:972,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){if((0,s.QM)(t.placementId))return t;Ge.logMissingRequireParam("kargo","placementId",i.lineItemId)}},[$e.SmileWanted]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:639,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.QM)(e.zoneId))return void Ge.logMissingRequireParam("smilewanted","zoneId",i.lineItemId);const{floorPrice:n}=i;return(0,s.r)(n)&&(e.bidfloor=n),e}},[$e.TrustX]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:void 0,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.hj)(e.uid))return void Ge.logMissingRequireParam("trustx","uid",i.lineItemId);const{floorPrice:n}=i;return(0,s.r)(n)&&(e.bidFloor=n),e}},[$e.EmxDigital]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:183,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.QM)(e.tagid))return void Ge.logMissingRequireParam("emx_digital","tagid",i.lineItemId);const{floorPrice:n}=i;return(0,s.r)(n)&&(e.bidfloor=n.toString()),e}},[$e.KrushMedia]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:void 0,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.QM)(e.key))return void Ge.logMissingRequireParam("krushmedia","key",i.lineItemId);const{floorPrice:n}=i;return(0,s.r)(n)&&(e.bidfloor=n),e.traffic=Ue.VIDEO,e}},[$e.Conversant]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:24,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.QM)(e.site_id))return void Ge.logMissingRequireParam("conversant","site_id",i.lineItemId);e.secure=He.Secure;const{floorPrice:n}=i;return(0,s.r)(n)&&(e.bidfloor=n),e}},[$e.Criteo]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:91,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if((0,s.hj)(e.networkId))return e;Ge.logMissingRequireParam("criteo","networkId",i.lineItemId)}},[$e.TripleLift]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:28,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.QM)(e.inventoryCode))return void Ge.logMissingRequireParam("triplelift","inventoryCode",i.lineItemId);const{floorPrice:n}=i;return(0,s.r)(n)&&(e.floor=n),e}},[$e.PulsePoint]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:81,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.hj)(e.cp))return void Ge.logMissingRequireParam("pulsepoint","cp",i.lineItemId);if(!(0,s.hj)(e.ct))return void Ge.logMissingRequireParam("pulsepoint","ct",i.lineItemId);const{floorPrice:n}=i;return(0,s.r)(n)&&(e.bidfloor=n),e}},[$e.Adtelligent]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:410,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if((0,s.hj)(e.aid))return e;Ge.logMissingRequireParam("adtelligent","aid",i.lineItemId)}},[$e.Yieldmo]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:173,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.QM)(e.placementId))return void Ge.logMissingRequireParam("yieldmo","placementId",i.lineItemId);const{floorPrice:n,isOutstream:r,adBreakType:o}=i;if((0,s.r)(n)&&(e.bidFloor=n),r)e.video.startdelay=0;else switch(o){case v.ProtoAdBreakTypeEnum.PreRoll:e.video.startdelay=0;break;case v.ProtoAdBreakTypeEnum.MidRoll:e.video.startdelay=1;break;case v.ProtoAdBreakTypeEnum.PostRoll:e.video.startdelay=-2;break;default:e.video.startdelay=0}return e}},[$e.PgamMedia]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:void 0,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if((0,s.QM)(e.AV_PUBLISHERID)){if((0,s.QM)(e.AV_CHANNELID))return e;Ge.logMissingRequireParam("pgammedia","AV_CHANNELID",i.lineItemId)}else Ge.logMissingRequireParam("pgammedia","AV_PUBLISHERID",i.lineItemId)}},[$e.NextMillennium]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:1060,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if((0,s.QM)(e.placement_id)||(0,s.QM)(e.group_id))return e;Ge.logMissingRequireIntegrationsParams("nextMillennium",[["placement_id"],["group_id"]],i.lineItemId)}},[$e.AdYouLike]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:259,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if((0,s.QM)(e.placement))return e;Ge.logMissingRequireParam("adyoulike","placement",i.lineItemId)}},[$e.FreeWheelSSP]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:285,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if((0,s.QM)(t.zoneId))return e;Ge.logMissingRequireParam("freewheel-ssp","zoneId",i.lineItemId)}},[$e.ColossusSSP]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:void 0,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t),n=(0,s.hj)(e.placement_id),r=(0,s.hj)(e.group_id);if(n||r)return e;Ge.logMissingRequireIntegrationsParams("colossusssp",[["placement_id"],["group_id"]],i.lineItemId)}},[$e.ResetDigital]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:void 0,gdprSupport:!0,ccpaSupport:!1}}getBidParams(t,i){const e=Object.assign({},t),n=(0,s.QM)(e.pubId),r=(0,s.QM)(e.zoneId);if(n||r)return e;Ge.logMissingRequireIntegrationsParams("resetdigital",[["pubId"],["zoneId"]],i.lineItemId)}},[$e.MediaFuse]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:void 0,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t),{placementId:n}=e;if(!(0,s.hj)(n))return void Ge.logMissingRequireParam("mediafuse","placementId",i.lineItemId);const{floorPrice:r}=i;(0,s.r)(r)&&(e.reserve=r);const{deviceId:o,os:h}=i;if((0,s.QM)(o))switch(e.app=Object.assign({},e.app),h){case zt.M.Android:e.app.device_id={aaid:o};break;case zt.M.Ios:e.app.device_id={idfa:o}}return e.video=Object.assign(Object.assign({},e.video),{skippable:!!i.skippabilitySettings.skip,skipoffset:i.skippabilitySettings.skipafter}),e}},[$e.Sharethrough]:new class extends Ge{constructor(){super(...arguments),this.bw={vendorId:80,gdprSupport:!0,ccpaSupport:!0}}getBidParams(t,i){const e=Object.assign({},t);if(!(0,s.QM)(e.pkey))return void Ge.logMissingRequireParam("sharethrough","pkey",i.lineItemId);const{floorPrice:n}=i;return(0,s.r)(n)&&(e.floor=n),e}}};var Qe;!function(t){t[t.AutoplaySoundOn=1]="AutoplaySoundOn",t[t.AutoPlaySoundOff=2]="AutoPlaySoundOff",t[t.ClickToPlay=3]="ClickToPlay",t[t.MouseOver=4]="MouseOver",t[t.ScrollToPlaySoundOn=5]="ScrollToPlaySoundOn",t[t.ScrollToPlaySoundOff=6]="ScrollToPlaySoundOff"}(Qe||(Qe={}));const Je=(t,i)=>({[v.ProtoPlayerPlaybackModeEnum.Autoplay]:i!==v.ProtoPlayerSoundMode.Mute?Qe.AutoplaySoundOn:Qe.AutoPlaySoundOff,[v.ProtoPlayerPlaybackModeEnum.ClickToPlay]:Qe.ClickToPlay,[v.ProtoPlayerPlaybackModeEnum.ScrollToPlay]:i!==v.ProtoPlayerSoundMode.Mute?Qe.ScrollToPlaySoundOn:Qe.ScrollToPlaySoundOff}[t]);class Ye{constructor(t){this.Rd=t}isAdapterCallable(t){const i=(t=>{const i=Object.keys($e).find((i=>$e[i]===t));if(i)return $e[i]})(t);return!!i&&(this.Rd.isGDPR()?this.Iw(i):!this.Rd.isCcpaApplicable()||this.ww(i))}Sw(t){return Xe[t].config.gdprSupport}Iw(t){if(this.Sw(t))return!0;const i=Xe[t].config.vendorId,e=(0,s.hj)(i)?`${i}`:"";return this.Rd.isConsent(e,We.Z)}ww(t){return!!Xe[t].config.ccpaSupport||!!this.Rd.isSellUserAllowed()}}var Ke,Ze=r(3003);class ts{constructor(t,i={}){this.Pw=t,this.Aw=i,this.xw="{{",this.Tw="}}",this.Cw=new RegExp(`${this.xw}(.*?)${this.Tw}`,"g")}replaceMacros(t,i){const e=(0,Ze.Ed)(t,this.Cw);if(!(0,S.BZ)(e))return t;const s=this.qh(t,e,i);return this.replaceMacros(s,i)}setMacros(t){this.Aw=Object.assign(Object.assign({},this.Aw),t)}qh(t,i,e){const s=t;return i.reduce(((t,i)=>this.Ew(t,i,e)),s)}Ew(t,i,e){const n=this.Mw(i);if(!this.Lw(n,e))return t.replace(i,null);let r=null,o=!1;this.Bw(n,e)?r=this.Pw.getMacroValue(n,e):this.Rw(n)&&(r=this.Aw[n],(0,s.HD)(r)||(o=!0));const h=this.Ow(r);if(o){return t.replace(`"${i}"`,h).replace(i,h)}return t.replace(i,h)}Lw(t,i){return this.Bw(t,i)||this.Rw(t)}Bw(t,i){return this.Pw.hasMacroValue(t,i)}Rw(t){return(0,s.$K)(this.Aw[t])}Mw(t){return t.replace(this.xw,"").replace(this.Tw,"")}Ow(t){return[null,void 0,NaN].includes(t)?null:Array.isArray(t)||(0,s.as)(t)?JSON.stringify(t):t.toString()}}!function(t){t[t.Instream=1]="Instream",t[t.InBanner=2]="InBanner",t[t.Outstream=3]="Outstream",t[t.InFeed=4]="InFeed",t[t.Floating=5]="Floating"}(Ke||(Ke={}));const is=["video/mp4","video/webm","application/javascript","video/ogg","video/mpeg"],es=[2,3,5,6],ss={VPAID_1:1,VPAID_2:2},ns=[ss.VPAID_1,ss.VPAID_2],rs=[ss.VPAID_1,ss.VPAID_2],os=(t,i)=>{const{skip:e,skippable:s,skipmin:n,skipafter:r}=i,{width:o,height:h,isOutstreamContext:a,maxAdDuration:c,inFloating:d,initialSoundMode:l,playbackMode:u}=t;let p=Ke.Instream;return a&&(p=Ke.Floating),d&&(p=Ke.Outstream),{video:{w:Math.floor(o),h:Math.floor(h),playerSize:[Math.floor(o),Math.floor(h)],context:a?"outstream":"instream",mimes:is,protocols:es,linearity:1,api:ns,frameworks:rs,maxduration:c,minduration:0,skip:e,skippable:s,skipmin:n,skipafter:r,placement:p,playbackmethod:[Je(u,l)]}}};var hs,as,cs,ds,ls;!function(t){t.InApp="mobile_app",t.MobileWeb="mobile_web",t.Web="web"}(hs||(hs={})),function(t){t.Outstream="outstream",t.PreRoll="pre_roll",t.MidRoll="mid_roll",t.PostRoll="post_roll"}(as||(as={})),function(t){t.AutoPlaySoundOn="auto_play_sound_on",t.AutoPlaySoundOff="auto_play_sound_off",t.AutoPlaySoundUnknown="auto_play_sound_unknown",t.ClickToPlay="click_to_play",t.MouseOver="mouse_over"}(cs||(cs={})),function(t){t[t.Instream=201]="Instream",t[t.Outstream=203]="Outstream"}(ds||(ds={})),function(t){t.CnxSupplyType="CNX_SUPPLY_TYPE",t.CnxAdUnit="CNX_AD_UNIT",t.CnxVideoMimes="CNX_VIDEO_MIMES",t.CnxVideoApi="CNX_VIDEO_API",t.CnxVideoId="CNX_VIDEO_ID",t.CnxAtsEnvelope="CNX_ATS_ENVELOPE",t.CnxSupplyChain="CNX_SUPPLY_CHAIN",t.CnxIntegrationMode="CNX_INTEGRATION_MODE",t.CnxVideoFrameworks="CNX_VIDEO_FRAMEWORKS",t.CnxVideoSkippable="CNX_VIDEO_SKIPPABLE",t.CnxVideoSkipOffset="CNX_VIDEO_SKIP_OFFSET",t.CnxVideoMaxDuration="CNX_VIDEO_MAX_DURATION",t.CnxVideoStartDelay="CNX_VIDEO_START_DELAY",t.CnxVideoPlaybackMethodInteger="CNX_VIDEO_PLAYBACK_METHOD_INTEGER",t.CnxVideoPlaybackMethodsString="CNX_VIDEO_PLAYBACK_METHOD_STRING",t.CnxVideoProtocols="CNX_VIDEO_PROTOCOLS",t.CnxVideoLinearity="CNX_VIDEO_LINEARITY",t.CnxVideoPlacement="CNX_VIDEO_PLACEMENT",t.CnxVideoContext="CNX_VIDEO_CONTEXT",t.CnxVideoSizeId="CNX_VIDEO_SIZE_ID",t.CnxVideoLanguage="CNX_VIDEO_LANGUAGE",t.CnxVideoVolume="CNX_VIDEO_VOLUME",t.UserLanguage="USER_LANGUAGE",t.AppDeviceId="APP_DEVICE_ID",t.Width="WIDTH",t.Height="HEIGHT",t.UserLat="USER_LAT",t.UserLong="USER_LONG",t.DoNotTrack="DNT",t.AppBundle="APP_BUNDLE",t.AppName="APP_NAME",t.PageUrl="PAGE_URL"}(ls||(ls={}));class us{constructor(t,i,e,s,n){this._appSettings=t,this.Dw=i,this.Rd=e,this.Vw=s,this.Nw=n,this.jw={[ls.PageUrl]:()=>this.Dw.pageUrl,[ls.AppBundle]:()=>this._appSettings.bundleID,[ls.AppName]:()=>this._appSettings.appName,[ls.AppDeviceId]:t=>this.$w(t),[ls.CnxAdUnit]:()=>this.Uw(),[ls.CnxSupplyType]:()=>this.qw(),[ls.CnxVideoContext]:t=>this.Hw(t),[ls.CnxIntegrationMode]:()=>this.Dw.isAmp?"AMP":void 0,[ls.Width]:t=>Math.floor(t.videoWidth),[ls.Height]:t=>Math.floor(t.videoHeight),[ls.CnxSupplyChain]:t=>t.supplyChain,[ls.CnxVideoApi]:()=>Object.values(ss),[ls.CnxVideoFrameworks]:()=>rs,[ls.CnxVideoMimes]:()=>is,[ls.CnxVideoProtocols]:()=>es,[ls.CnxVideoLinearity]:()=>1,[ls.CnxVideoMaxDuration]:t=>t.videoMaxAdDuration,[ls.CnxVideoLanguage]:()=>"en",[ls.CnxVideoId]:t=>t.mediaId,[ls.CnxAtsEnvelope]:t=>t.liveRampEnvelope,[ls.CnxVideoSkippable]:t=>t.skippabilitySettings.skippable,[ls.CnxVideoSkipOffset]:t=>t.skippabilitySettings.skipafter,[ls.CnxVideoPlaybackMethodInteger]:()=>this.zw(),[ls.CnxVideoPlaybackMethodsString]:()=>this.Ww(),[ls.CnxVideoPlacement]:t=>this.Gw(t),[ls.CnxVideoSizeId]:()=>this.Xw(),[ls.CnxVideoStartDelay]:()=>this.Nw,[ls.CnxVideoVolume]:t=>t.videoVolume,[ls.DoNotTrack]:()=>{},[ls.UserLanguage]:()=>this.Qw(),[ls.UserLat]:()=>this.Dw.geoLocation.lat,[ls.UserLong]:()=>this.Dw.geoLocation.lon}}getMacroValue(t,i){const e=this.jw[t];if(e)return e(i)}hasMacroValue(t,i){return(0,s.$K)(this.getMacroValue(t,i))}$w(t){const i=this.Rd.isConsent(t.vendorId);return this.Rd.isConsentConnatix()&&i?this.Rd.getTrackableUser():void 0}Uw(){return this.Vw.isOutstream?qe.Outstream:qe.Instream}qw(){return this.Dw.isInApp?hs.InApp:this.Dw.isMobile?hs.MobileWeb:hs.Web}Hw(t){if(this.Vw.isOutstream)return as.Outstream;return{[v.ProtoAdBreakTypeEnum.None]:as.PreRoll,[v.ProtoAdBreakTypeEnum.PreRoll]:as.PreRoll,[v.ProtoAdBreakTypeEnum.MidRoll]:as.MidRoll,[v.ProtoAdBreakTypeEnum.PostRoll]:as.PostRoll}[t.adBreakType]}zw(){return Je(this.Vw.playbackMode,this.Vw.initialSoundMode)}Ww(){const t=this.Vw.playbackMode,i=this.Vw.initialSoundMode;return t===v.ProtoPlayerPlaybackModeEnum.Autoplay?i===v.ProtoPlayerSoundMode.On?cs.AutoPlaySoundOn:i===v.ProtoPlayerSoundMode.Mute?cs.AutoPlaySoundOff:cs.AutoPlaySoundUnknown:t===v.ProtoPlayerPlaybackModeEnum.ClickToPlay?cs.ClickToPlay:void 0}Xw(){return this.Vw.isOutstream?ds.Outstream:ds.Instream}Qw(){const t=navigator.language;if((0,s.QM)(t))return t.split("-")[0].toUpperCase()}Gw(t){return t.inFloating?Ke.Floating:this.Vw.isOutstream?Ke.Outstream:Ke.Instream}}function ps(t,i){t.sort(((t,i)=>t.width===i.width?t.bitrate-i.bitrate:t.width-i.width));for(let e=0;e<t.length;e++)if(t[e].width>=i)return t[e-1]||t[e];return t[t.length-1]}const fs=()=>`cnx_bid_slot_${(0,h.qs)()}`,ms="https://prebid.adnxs.com/pbc/v1/cache",gs=()=>({cmpApi:"iab",timeout:2e3,defaultGdprScope:!0,allowAuctionWithoutConsent:!1,rules:[{purpose:"storage",enforcePurpose:!0,enforceVendor:!0,vendorExceptions:["permutive"]},{purpose:"basicAds",enforcePurpose:!0,enforceVendor:!0},{purpose:"measurement",enforcePurpose:!0,enforceVendor:!0}]}),vs=()=>({cmpApi:"iab",timeout:2e3}),ys=t=>{if(!(0,s.as)(t))return null;return`1.0,1!${(0,s.QM)(t.businessDomain)?encodeURI(t.businessDomain):""},${(0,s.QM)(t.supplyChainId)?encodeURI(t.supplyChainId):""},1`};var bs;!function(t){t.CACHE_ID="CACHE_ID"}(bs||(bs={}));var Is;!function(t){t.Banner="banner",t.Video="video",t.All="all"}(Is||(Is={}));const ws=t=>({id:t.appId,name:t.appName,bundle:t.bundleID,domain:t.domainURL,storeurl:t.storeURL,cat:t.appCategories,ver:t.appVersion,privacypolicy:t.appPrivacyPolicy,paid:t.appIsPaid}),Ss=(t,i,e,n,r,o)=>{const h=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({usePrebidCache:!0},{userSync:{syncEnabled:!0,iframeEnabled:!0,pixelEnabled:!0,filterSettings:{iframe:{bidders:"*",filter:"include"},image:{bidders:"*",filter:"include"}},syncsPerBidder:0,syncDelay:3e3,auctionDelay:0,aliasSyncEnabled:!0,userIds:[{name:"criteo"},{name:"pubCommonId",params:{enableSharedId:!0},storage:{type:"cookie",name:"_pubcid",expires:180}},{name:"uid2"}]}}),{ix:{timeout:900}}),{targetingControls:{addTargetingKeys:[bs.CACHE_ID]}}),{yahoossp:{mode:Is.Video}}),(t=>({realTimeData:{dataProviders:[{name:"permutive",params:(0,s.as)(t)?t:{}}]}}))(o));return h.floors={},(0,s.QM)(r)&&(h.pageUrl=r),h.usePrebidCache&&(h.cache={url:ms}),n&&(h.schain=(t=>({validation:"strict",config:{ver:"1.0",complete:1,nodes:[{asi:t.businessDomain,hp:1,sid:(0,s.QM)(t.supplyChainId)?t.supplyChainId:null}]}}))(n)),(t||i)&&(h.consentManagement=((t,i)=>t?{gdpr:gs()}:i?{usp:vs()}:{})(t,i)),e.isInApp&&(h.app=ws(e),h.ortb2={app:ws(e)}),h},Ps="pbjs";class As{constructor(t,i){this.yn=t,this.Zp=i,this.Yw=!0,this.Kw=new At(this.yn,this.Zp)}loadPrebidJs(t){return new Promise(((i,e)=>{if(this.Zw)return i(this.Zw);this.insertPrebidJs().then((e=>{this.Zw=e,this.Zw.setConfig(t),this.Zw.setBidderConfig({bidders:[$e.TrustX,$e.TripleLift,$e.Conversant,$e.Criteo,$e.Kargo],config:{localStorageWriteAllowed:!0}},this.Yw),i(e)})).catch((t=>e(t)))}))}insertPrebidJs(){return new Promise(((t,i)=>{this.Kw.loadIframe({customHead:"<style> html, body {display: none}</style>",customHtml:`<script id='cnx-prebid-loader' type='text/javascript' src='${_t.n.endPoints.assets.plugins.prebidScript}'><\/script>`,customIframeAttributes:[{key:"class",value:"cnx-prebid-loader"}],container:this.yn.querySelector("head"),visible:!1}).then((e=>{if(e.iframe.contentWindow[Ps])return this.tS(e.iframe),t(e.iframe.contentWindow[Ps]);i(new Error("pbjs could not be found on the iframe window"))})).catch((t=>{i(t)}))}))}tS(t){const i=this.yn.global.permutive;(0,s.$K)(i)&&(t.contentWindow.permutive=i)}}class _s{constructor(t,i,e,s,n,r,o){this.iS=t,this.eS=i,this.yn=e,this.sS=s,this.Rd=n,this.bw=r,this.nS=o,this.Rs=this.bw.pageUrl,this.Zp=this.bw.sessionId,this.gi=this.bw.os.os,this.rS=new As(this.yn,this.Zp)}requestHeaderBidder(t,i){return new Promise(((e,s)=>{this.oS().then((s=>{const n=t.map((t=>this.hS(s,t,i).then((t=>t))));Promise.all(n).then((t=>{e(t)}))})).catch((t=>{s(v.ConnatixNoBidReasonEnum.NoBid)}))}))}setMacros(t){this.iS.setMacros(t)}aS(t,i){const e={lineItemSkippability:t,lineItemSkipMin:i,playerSkippability:this.sS.skippability,playerSkipMin:this.sS.skipMin,playerSkipAfter:this.sS.skipAdAfter},s=Fi(e),n=s.skippable?1:0;return Object.assign({skip:n},s)}hS(t,i,e){return new Promise((n=>{let r=[];if(i.availableRequests>0)if((0,s.$K)(i.lineItem.floorPricesNew)&&(0,S.BZ)(i.lineItem.floorPricesNew.floorPrices)){const s=i.lineItem.floorPricesNew.floorPrices.map((t=>t.price));r=this.cS(i.lineItem.floorPricesNew,i.availableRequests,i.maxBidPrice).map((n=>this.dS(t,i.lineItem,i.bidderName,i.bidderParams,s,n,e)))}else{const s={requestedFloorPrice:i.lineItem.floorPrice,floorPriceInformation:{floorPrices:[],floorPriceIndexUsed:-1,floorPriceFactorBypassReason:v.FloorPriceBypassReasonEnum.FixedCpm}},n=this.dS(t,i.lineItem,i.bidderName,i.bidderParams,[],s,e);r.push(n)}Promise.all(r).then((t=>{const e=[],s=[],r=i.lineItem.advertiserLineItemId;t.forEach((t=>{t.reason?s.push(t):e.push(t)}));n({bids:e,noBids:s,lineItemId:r})}))}))}dS(t,i,e,s,n,r,o){return new Promise((h=>{this.lS(t,i,e,s,n,r,o).then((t=>{h(t)})).catch((t=>{h(t)}))}))}oS(){const t=Ss(this.Rd.isGDPR(),this.Rd.isCcpaApplicable(),this.bw,this.eS,this.Rs,this.nS);return new Promise(((i,e)=>{this.rS.loadPrebidJs(t).then((t=>{i(t)})).catch((t=>{(0,p.n)({message:"AdManager_HeaderBidder_unable_to_load_prebidJs_script",exception:t.message,callStack:t.stack,level:p.D.CRITICAL,sessionId:this.Zp}),e(t)}))}))}uS(t){const i=Object.keys(t),e=i.filter((i=>!(0,s.as)(t[i]))),n=i.filter((i=>(0,s.as)(t[i])));return e.forEach((i=>{null!==t[i]&&"null"!==t[i]||delete t[i]})),n.forEach((i=>{this.uS(t[i])})),t}lS(t,i,e,n,r,o,a){return new Promise(((c,d)=>{const l=this.aS(i.skippability,i.skipMin),u=((t,i,e,n)=>{const r={code:(0,h.qs)(),mediaTypes:os(t,e),bids:[]},o=[$e.Smaato,$e.Yieldmo];return!t.isOutstreamContext&&o.includes(n)&&(r.mediaTypes.video.startdelay=0),(0,s.r)(i)&&(r.floors=(t=>({currency:"USD",schema:{fields:["mediaType"]},values:{video:t}}))(i)),r})(a,o.requestedFloorPrice,l,e);try{const{width:t,height:e,maxAdDuration:s,videoVolume:r,inFloating:o,adBreakType:h,mediaLanguage:c,mediaId:d,liveRampEnvelope:p}=a,f=this.iS.replaceMacros(n,{videoWidth:t,videoHeight:e,videoMaxAdDuration:s,vendorId:i.vendorId,skippabilitySettings:l,videoVolume:r,inFloating:o,adBreakType:h,mediaLanguage:c,mediaId:d,supplyChain:ys(this.eS),liveRampEnvelope:p}),m=JSON.parse(f),g=this.uS(m);u.bids=[g]}catch(t){(0,p.n)({message:"AdManager_HeaderBidder_unable_to_parse_header_bidder",exception:t.message,callStack:t.stack,level:p.D.WARN,sessionId:this.Zp});const i=Object.assign({bidderName:e,reason:v.ConnatixNoBidReasonEnum.NoBid},o);return void d(i)}const f=fs();u.bids.forEach((t=>this.pS(t,o.requestedFloorPrice,i.advertiserLineItemId,f,l,a,u.code,this.Rd.getDeviceId(),this.gi))),t.que.push((()=>{t.addAdUnits(u);const n={timeout:i.headerBidderTimeout,adUnits:[u],bidsBackHandler:()=>{var n;try{const h=t.getHighestCpmBids(u.code)[0];if(!h){const t=Object.assign({bidderName:e,reason:v.ConnatixNoBidReasonEnum.CsEmptyResponse},o);return void d(t)}let a,l;if(this.fS(h))a=(t=>`${ms}?uuid=${t.adserverTargeting.hb_cache_id}`)(h);else if(a=h.vastUrl,l=h.vastXml,!a&&!l){(0,p.n)({level:p.D.WARN,message:"AdManager_HeaderBidder_no_content",exception:JSON.stringify(h),sessionId:this.Zp});const t=Object.assign({bidderName:e,reason:v.ConnatixNoBidReasonEnum.CsEmptyResponse},o);return void d(t)}const m=h.cpm||h.adResponse.ad.cpm,{advertiserLineItemId:g}=i,y=Object.assign(Object.assign({},o),{bidderName:e,adTagUrl:a,adTagXml:l,lineItemId:g,cpm:m,slotId:f,bidId:u.code});(0,s.r)(o.requestedFloorPrice)&&m<o.requestedFloorPrice&&(0,p.n)({message:"AdManager_HeaderBidderRequester_cpm_lower_than_floorprice",level:p.D.WARN,exception:`floorPrices_${r}_floorPrice_${o.requestedFloorPrice}_index_${null===(n=o.floorPriceInformation)||void 0===n?void 0:n.floorPriceIndexUsed}_cpm_${m}_li_${i.advertiserLineItemId}`,callStack:e,sessionId:this.Zp},{shouldSendMaxLog:!1,throttle:5}),c(y)}catch(t){(0,p.n)({level:p.D.WARN,message:"AdManager_HeaderBidder_Prebidjs_error",exception:t.message,callStack:t.stack,sessionId:this.Zp});const i=Object.assign({bidderName:e,reason:v.ConnatixNoBidReasonEnum.NoBid},o);d(i)}}};t.requestBids(n)}))}))}pS(t,i,e,s,n,r,o,h,a){var c;const d=null===(c=Xe[t.bidder])||void 0===c?void 0:c.getBidParams;if(!d)return;const{width:l,height:u,isOutstreamContext:p,maxAdDuration:f,adBreakType:m,inFloating:g,hasFloatingCapability:v}=r;t.params=d(t.params,{playerWidth:l,playerHeight:u,maxDuration:f,pageUrl:this.Rs,floorPrice:i,lineItemId:e,isOutstream:p,bidSlotId:s,skippabilitySettings:n,adBreakType:m,adUnitCode:o,inFloating:g,hasFloatingCapability:v,deviceId:h,os:a})}fS(t){return t.adserverTargeting&&(0,s.QM)(t.adserverTargeting.hb_cache_id)}cS(t,i,e){if(0===i)return[];const{floorPrices:n,recommended:r}=t,o=n.map(((i,e)=>{if(e<r)return{requestedFloorPrice:i.price,floorPriceInformation:{floorPrices:t.floorPrices.map((({price:t})=>t)),floorPriceIndexUsed:e,floorPriceFactorBypassReason:i.floorPriceBypassReason}}})).filter((t=>(0,s.$K)(t)));return this.mS(o,i,e)}mS(t,i,e){let s=i;const n=t.filter((({requestedFloorPrice:t})=>t>=e&&s>0&&(s--,!0)));if((0,S.BZ)(n))return n;return[{requestedFloorPrice:e,floorPriceInformation:{floorPrices:t.map((({requestedFloorPrice:t})=>t)),floorPriceIndexUsed:-1,floorPriceFactorBypassReason:v.FloorPriceBypassReasonEnum.BidInHand}}]}}class xs{constructor(t,i,e,s,n){this.Vw=t,this.eS=i,this.vI=e,this._appSettings=s,this.sS=n,this.gS=new Map,this.vS=t=>t.replace(/\s/g,"").match(/"bidder":.+?(?=",)/).toString().split('bidder":"')[1];const r=new us(this._appSettings,this.vI.config,this.vI.services.UserManagerService,this.Vw,null),o=this._appSettings.customJsTargetingObject,h=new ts(r,o),a=L.h.getSessionChildContainer(this.vI.config.sessionId).resolve(ht.c.ExternalPrebidJSPermutiveConfig);this.yS=new _s(h,this.eS,this.vI.services.GlobalDomUtilsService,this.sS,this.vI.services.UserManagerService,this.vI.config,a),this.wS=new Ye(this.vI.services.UserManagerService)}request(t){const{width:i,height:e}=t.callingState,s=this.SS(i,e);this.PS(t.lineItemRequestDataList);const n=this.AS(t.lineItemRequestDataList);return(0,S.BZ)(n)&&s?(t.lineItemRequestDataList=n,this.xS(t).then((i=>Promise.resolve(this.TS(i,t)))).catch((()=>Promise.resolve({bids:[],noBids:[]})))):Promise.resolve({bids:[],noBids:[]})}setMacros(t){this.yS.setMacros(t)}TS(t,i){const e={bids:[],noBids:[]};return t.forEach((t=>{const n=Vi(i.lineItemRequestDataList,t.lineItemId);t.bids.forEach((t=>{const r=t.bidId,o=new Le,h=new Fe({requestedFloorPrice:t.requestedFloorPrice,prebidJsBidderName:t.bidderName,requestNumber:n.historicalMetrics.requestNumber,floorPriceInformation:t.floorPriceInformation});Be(n.protoLineItem.trackers,o),((0,s.QM)(t.adTagUrl)||(0,s.QM)(t.adTagXml))&&e.bids.push({bidId:r,lineItem:n,requestMetadata:h,state:i.callingState,vastTracker:o,shouldRequestWithCredentials:!1,vastTag:t.adTagXml,url:t.adTagUrl,prebidjsCPM:t.cpm,slotId:t.slotId})})),t.noBids.forEach((t=>{const i=new Fe({requestedFloorPrice:t.requestedFloorPrice,requestNumber:n.historicalMetrics.requestNumber,prebidJsBidderName:t.bidderName,floorPriceInformation:t.floorPriceInformation});e.noBids.push({lineItem:n,requestMetadata:i,reason:t.reason})}))})),e}xS(t){const{width:i,height:e,media:s,soundValue:n}=t.callingState,r={width:i,height:e,maxAdDuration:t.maxAdDuration,videoVolume:n,hasFloatingCapability:this.Vw.hasFloatingCapability,inFloating:t.callingState.inFloating,adBreakType:t.callingState.adBreakState.adBreakType,mediaLanguage:s.mediaLanguage,mediaId:s.mediaId,isOutstreamContext:this.Vw.isOutstream,initialSoundMode:this.Vw.initialSoundMode,playbackMode:this.Vw.playbackMode,liveRampEnvelope:this.Vw.liveRampEnvelope},o=t.lineItemRequestDataList.map((i=>this.kS(i,t.maxBidPrice)));return this.yS.requestHeaderBidder(o,r)}kS(t,i){const e=t.adManagerLineItem;return{availableRequests:t.maxAvailableRequests,lineItem:e.protoLineItem,maxBidPrice:i,bidderName:this.gS.get(t.adManagerLineItem).bidderName,bidderParams:this.gS.get(t.adManagerLineItem).bidderParamsJSONStringWithMacros}}AS(t){return t.filter((t=>{var i;const e=(null===(i=this.gS.get(t.adManagerLineItem))||void 0===i?void 0:i.bidderName)||"";return this.CS(e)}))}PS(t){t.map((t=>t.adManagerLineItem)).filter((t=>!this.gS.has(t))).forEach((t=>{try{const i=t.protoLineItem.prebidJsBidParamsJSONString,e=this.vS(i);this.gS.set(t,{bidderName:e,bidderParamsJSONStringWithMacros:i})}catch(i){this.ES(i,t.protoLineItem.advertiserLineItemId)}}))}ES(t,i){(0,p.n)({message:"PrebidJS_cannot_parse_bidderParams_"+i,level:p.D.WARN,exception:`${t}`,sessionId:this.vI.config.sessionId},{throttle:1,shouldSendMaxLog:!1})}SS(t,i){return 0!==t&&0!==i||((0,p.n)({message:"AdManager_PrebidAggregator_dimensions",exception:`width:${t}_height:${i}_destroyed:${E.S.playerDestroyed}`,level:p.D.CRITICAL,sessionId:this.vI.config.sessionId},{throttle:5}),!1)}CS(t){return this.wS.isAdapterCallable(t)}}var Ts=r(307),ks=r(2450),Cs=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class Es{constructor(t,i,e,s,n,r){this.MS=t,this.LS=i,this.vI=e,this.Dc=s,this.BS=n,this.gu=r,this.RS=new Map,this.OS=!1,this.DS=L.h.getSessionChildContainer(this.vI.config.sessionId).resolve(Ft),this.OS=this.DS.isOmsdkFullSupport}request(t){return Cs(this,void 0,void 0,(function*(){const{width:i,height:e}=t.callingState,n=this.SS(i,e),r=this.VS(t);return!n||Object.keys(r.lineItems).length<=0?{bids:[],noBids:[]}:this.FS(r).then((i=>((0,s.$K)(r.liveRampAtsEnvelope)&&ks.$.setEnvelopeStatus(i.liveRampEnvelopeStatus),this.jS(i,t)))).catch((t=>((0,p.n)({message:"RtbCallAggregator",exception:t.message,level:p.D.CRITICAL},{pacing:1}),{bids:[],noBids:[]})))}))}jS(t,i){const e={bids:[],noBids:[]};return t.lineItemResponses.forEach((t=>{const n=Vi(i.lineItemRequestDataList,t.id);(0,s.$K)(t.cachedFloorPrice)&&this.RS.set(t.id,t.cachedFloorPrice),t.bids.forEach((t=>{const s=n.protoLineItem;if(t=Object.assign(Object.assign({},t),this.$S(s)),this.qS(s,t))return(0,p.n)({level:p.D.WARN,message:"RtbCallAggregator_nonLinear_banner_0_dimensions",exception:`lineItemId:${n.protoLineItem.advertiserLineItemId}`},{throttle:5}),void e.noBids.push(this.HS(n));const r=this.zS(t,n,i.callingState);e.bids.push(r)}));const r=t.noBidsCount;for(let t=0;t<r;t++)e.noBids.push(this.HS(n))})),e}zS(t,i,e){return{lineItem:i,vastTracker:this.WS(t,i),state:e,requestMetadata:new Fe({requestedFloorPrice:t.requestedFloorPrice,isUserSynced:t.syncedUser,requestNumber:i.historicalMetrics.requestNumber,encryptedPrice:t.encryptedPrice,dspId:t.dspId,rtbAdomain:t.adomain,rtbSeatId:t.seatId,rtbCampainId:t.campaignId,cnxBidId:t.cnxBidId,requestTrackingHandledByServer:!0,logAuctionInformation:t.logAuctionInformation,auctionBidId:t.auctionBidId,rtbRequestId:t.rtbRequestId,liveRampType:t.liveRampType,floorPriceInformation:t.floorPriceInformation,discount:t.discount,serverBillingNoticeUrls:t.serverBillingNoticeUrls}),creativeId:t.creativeId,dimensions:{width:t.width,height:t.height},html:t.vastTag,mime:t.mime,obfuscatedPrice:t.gtkpbp,successRate:t.successRate,vastTag:t.vastTag}}$S(t){return{}}qS(t,i){var e;return Ni(t.adType,null===(e=t.nonlinearLineItemSettings)||void 0===e?void 0:e.nonLinearRequestType)&&(!i.height||!i.width)}HS(t){return{lineItem:t,requestMetadata:new Fe({requestNumber:t.historicalMetrics.requestNumber,partnerReason:v.PartnerNoBidReasonEnum.Unknown,requestTrackingHandledByServer:!0}),reason:v.ConnatixNoBidReasonEnum.NoBid}}WS(t,i){const e=new Le;Be(i.protoLineItem.trackers,e);const n=[...t.billingNoticeUrlList,t.adQualityCheckUrl].filter((t=>(0,s.QM)(t))).map((t=>Re(t)));return e.adImpression.push(...n),(0,s.QM)(t.winNoticeUrl)&&e.adWin.push(Re(t.winNoticeUrl)),e}GS(t,i){if(t.protoLineItem.adType!==v.ProtoAdType.Overlay)return null;const e=i.adContainerState.get(v.ProtoAdType.Video),s=i.adContainerState.get(v.ProtoAdType.Overlay);return e.height!==s.height||e.width!==s.width?{width:s.width,height:s.height}:void 0}QS(t,i){const e={};return t.filter((t=>this.JS(t))).forEach((t=>{const s=t.adManagerLineItem,n=this.GS(s,i);let r;this.RS.has(s.protoLineItem.advertiserLineItemId)&&(r=this.RS.get(s.protoLineItem.advertiserLineItemId));const o=this.YS(s);e[s.protoLineItem.advertiserLineItemId]=Object.assign({availableRequests:t.maxAvailableRequests,gdprConsent:this.vI.services.UserManagerService.isConsent(s.protoLineItem.vendorId),cachedFloorPrice:r,publisherLineItemId:s.protoLineItem.publisherLineItemId,slotHeight:null==n?void 0:n.height,slotWidth:null==n?void 0:n.width,requestNumber:s.historicalMetrics.requestNumber},o)})),e}YS(t){const i=Fi({playerSkippability:this.LS.skippability,playerSkipMin:this.LS.skipMin,playerSkipAfter:this.LS.skipAdAfter,lineItemSkippability:t.protoLineItem.skippability,lineItemSkipMin:t.protoLineItem.skipMin}),e=i.skippable?v.ProtoSkipEnabledEnum.Yes:v.ProtoSkipEnabledEnum.No;return Object.assign(Object.assign({},i),{skip:e})}JS(t){return!!t.adManagerLineItem.protoLineItem.forceCallingInEveryAO||this.BS.shouldRequestLineItem(t.adManagerLineItem.protoLineItem.advertiserLineItemId)}VS(t){const{width:i,height:e,viewability:s}=t.callingState,{width:r,height:o}=this.Dc.playerDimensions;return{metadata:this.Dc.trackingRequestMeta,gdprCompliant:this.vI.services.UserManagerService.isGDPR(),gdprConsentData:this.vI.services.UserManagerService.getConsentPayload(),soundOn:t.callingState.sound,videoHeight:e,videoWidth:i,testMode:"true"===(0,a.Ph)("cnxRtbTest",this.vI.config.pageUrl),explorationMode:this.vI.config.explorationMode,viewability:s,outstream:this.MS,domainURL:this.vI.config.domainURL,isClickToPlay:t.callingState.clickToPlay,appVersion:this.vI.config.appVersion,deviceID:this.vI.services.UserManagerService.getDeviceId(),isCcpaBlockingUserInfo:!this.vI.services.UserManagerService.isSellUserAllowed(),usPrivacyString:this.vI.services.UserManagerService.getUsPrivacyString(),gdprConsentMode:this.vI.services.UserManagerService.gdprConsentMode,customMacros:this.vI.services.MacrosService.getExtraMacros(),maxAdDuration:t.maxAdDuration,lineItems:this.QS(t.lineItemRequestDataList,t.callingState),maxBidPrice:t.maxBidPrice,playerWidth:r,playerHeight:o,useNewSkippability:!0,liveRampAtsEnvelope:this.vI.services.UserManagerService.identityEnvelope,lineItemAbTestInformation:this.gu,connectionType:n.getConnectionType(this.vI.config.deviceType),OMSDKSupport:this.OS,OMSDKVersion:this.DS.omsdkVersion}}FS(t){return Bt.n.sendProtoRequest({endpoint:_t.n.endPoints.api.rtb,protoRequest:v.ProtoRtbRequest,protoResponse:v.ProtoRtbResponse,requestData:t,queryParams:{[Ts.Fk]:o.g.version,[Ts.cc]:_t.n.tier},shouldLogErrors:!1,shouldSetClientHintsHeaders:!0})}SS(t,i){return 0!==t&&0!==i||((0,p.n)({message:"AdManager_BidderCaller_dimensions",exception:`width:${t}_height:${i}_destroyed:${E.S.playerDestroyed}`,level:p.D.CRITICAL,sessionId:this.vI.config.sessionId},{throttle:5}),!1)}}var Ms,Ls=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class Bs{constructor(t,i){this.vI=t,this.Dc=i}callCoreTam(t){return Ls(this,void 0,void 0,(function*(){const i=t.map((t=>{const i={lineItemId:t.lineItemId,code:t.coreTamCode,metadata:this.Dc.trackingRequestMeta,exploration:this.vI.config.explorationMode};return this.KS(i)}));return Promise.all(i)}))}KS(t){return Ls(this,void 0,void 0,(function*(){try{const i=yield Bt.n.sendProtoRequest({endpoint:_t.n.endPoints.api.tam,protoRequest:v.ProtoCoreTamBidRequest,protoResponse:v.ProtoCoreTamBidResponse,requestData:t,queryParams:{[Ts.Fk]:o.g.version,[Ts.cc]:_t.n.tier},shouldLogErrors:!0});return(0,s.QM)(i.errorMessage)?{lineItemId:t.lineItemId,coreTamCode:t.code,coreTamBidResponse:null,rejectReason:v.ConnatixNoBidReasonEnum.RequestException}:(0,s.QM)(i.encryptedBidPrice)?{lineItemId:t.lineItemId,coreTamCode:t.code,coreTamBidResponse:i,rejectReason:null}:{lineItemId:t.lineItemId,coreTamCode:t.code,coreTamBidResponse:null,rejectReason:v.ConnatixNoBidReasonEnum.InvalidResponse}}catch(i){return{lineItemId:t.lineItemId,coreTamCode:t.code,coreTamBidResponse:null,rejectReason:v.ConnatixNoBidReasonEnum.RequestException}}}))}}!function(t){t.SDK_NAME_ON_PUB_WINDOW="apstag",t.MEDIA_TYPE="video",t.VAST_TAG_BASE_URL="https://aax.amazon-adsystem.com/e/dtb/vast"}(Ms||(Ms={}));class Rs{static getTargetingFromBid(t){var i,e;return{amzniid:t.amzniid||(null===(i=t.targeting)||void 0===i?void 0:i.amzniid),amznbid:t.amznbid||(null===(e=t.targeting)||void 0===e?void 0:e.amznbid)}}static hasTargeting(t){const i=Rs.getTargetingFromBid(t);return(0,s.QM)(i.amzniid)&&(0,s.QM)(i.amznbid)}constructor(t){this.ZS=t.amznbid,this.tP=t.amzniid}get amazonBidCode(){return this.ZS}getVast(){return`${Ms.VAST_TAG_BASE_URL}?b=${this.tP}&pp=${this.ZS}&rnd=${(0,h.qs)()}`}}class Os{static hasTargetings(t){const i=Os.getTargetingsFromBid(t);return(0,S.BZ)(i)}static getTargetingsFromBid(t){const i=Os.getDeals(t);return(0,S.BZ)(i)?i.map((i=>{const e=`${i}amzniid`;return{targetingDeal:i,targetingKey:e,targetingValue:t.targeting[e]}})).filter((t=>(0,s.QM)(t.targetingValue))):[]}static getDeals(t){var i;return t.amzndeals||(null===(i=t.targeting)||void 0===i?void 0:i.amzndeals)}constructor(t){this.iP=t.targetingDeal,this.eP=t.targetingKey,this.sP=t.targetingValue}get targetingDeal(){return this.iP}get targetingKey(){return this.eP}get targetingValue(){return this.sP}getVast(){return`${Ms.VAST_TAG_BASE_URL}?b=${this.sP}&rnd=${(0,h.qs)()}`}}class Ds{static getTargetingFromBid(t){var i,e;return{amzniid_sp:t.amzniid_sp||(null===(i=t.targeting)||void 0===i?void 0:i.amzniid_sp),amznbid_sp:t.amznbid_sp||(null===(e=t.targeting)||void 0===e?void 0:e.amznbid_sp)}}static hasTargeting(t){const i=Ds.getTargetingFromBid(t);return(0,s.QM)(i.amzniid_sp)&&(0,s.QM)(i.amznbid_sp)}constructor(t){this.ZS=t.amznbid_sp,this.tP=t.amzniid_sp}get amazonBidCode(){return this.ZS}getVast(){return`${Ms.VAST_TAG_BASE_URL}?b=${this.tP}&rnd=${(0,h.qs)()}`}}class Vs{static createObjects(t,i){const e=[];switch(t.creativeType){case v.ProtoCreativeTypeEnum.Tam:if(Rs.hasTargeting(i)){const t=Rs.getTargetingFromBid(i);e.push(new Rs(t))}break;case v.ProtoCreativeTypeEnum.TamDeal:if(Os.hasTargetings(i)){const s=Os.getTargetingsFromBid(i).filter((i=>i.targetingDeal===t.amazonDealId)).map((t=>new Os(t)));e.push(...s)}break;case v.ProtoCreativeTypeEnum.TamPrivateAuction:if(Ds.hasTargeting(i)){const t=Ds.getTargetingFromBid(i);e.push(new Ds(t))}}return e}}class Fs{constructor(t,i){this.nP=t,this.rP=[],i.forEach((t=>{const i=Vs.createObjects(this.nP,t);this.rP.push(...i)}))}get amazonBidList(){return this.rP}get lineItem(){return this.nP}get hasCoreTamDependency(){return this.rP.every((t=>(0,s.QM)(t.amazonBidCode)))}}var Ns,js=r(9022),$s=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class Us{constructor(t,i,e,s,n,r){this.vI=t,this.oP=i,this.hP=e,this.yn=s,this.Zp=n,this.Dc=r;const o=this.vI.config.topWindow;this.aP=(0,h.pE)(o).topFrame}requestBids(t){return this.cP(t)}cP(t){return $s(this,void 0,void 0,(function*(){try{yield this.lP();const i=yield this.uP(),e=this.fP(t,i),s=yield this.mP(e);return this.gP(e,s)}catch(i){return this.vP(t,i)}}))}vP(t,i){return i.message?t.map((t=>({bids:[],lineItemId:t.advertiserLineItemId,noBids:[{reason:v.ConnatixNoBidReasonEnum.CsRequestException}]}))):t.map((t=>({bids:[],lineItemId:t.advertiserLineItemId,noBids:[{reason:i}]})))}gP(t,i){return t.map((t=>{const e=i.filter((i=>t.lineItem.advertiserLineItemId===i.lineItemId));return this.yP(t,e)}))}yP(t,i){return t.hasCoreTamDependency?this.bP(t,i):this.IP(t)}IP(t){const i=t.amazonBidList.map((i=>({encryptedPrice:null,vastTag:i.getVast(),ofskp:_e(t.lineItem.floorPrice),successRate:t.lineItem.successRate,slotId:fs()})));return(0,S.BZ)(i)?{bids:i,lineItemId:t.lineItem.advertiserLineItemId,noBids:[]}:{bids:[],lineItemId:t.lineItem.advertiserLineItemId,noBids:[{reason:v.ConnatixNoBidReasonEnum.NoBid}]}}bP(t,i){const e=i.map((i=>this.wP(t,i))).filter((t=>t.amazonBid&&!(0,s.Cz)(t.coreTamRequestOutput.rejectReason,v.ConnatixNoBidReasonEnum))).map((t=>({encryptedPrice:t.coreTamRequestOutput.coreTamBidResponse.encryptedBidPrice,vastTag:t.amazonBid.getVast(),ofskp:t.coreTamRequestOutput.coreTamBidResponse.ofskp,successRate:t.coreTamRequestOutput.coreTamBidResponse.successRate,slotId:fs()}))),n=i.filter((t=>t.rejectReason)).map((t=>({reason:t.rejectReason})));return(0,S.BZ)(e)||(0,S.BZ)(n)?{bids:e,noBids:n,lineItemId:t.lineItem.advertiserLineItemId}:{bids:[],lineItemId:t.lineItem.advertiserLineItemId,noBids:[{reason:v.ConnatixNoBidReasonEnum.NoBid}]}}wP(t,i){return{coreTamRequestOutput:i,amazonBid:t.amazonBidList.find((t=>t.amazonBidCode===i.coreTamCode))}}mP(t){return $s(this,void 0,void 0,(function*(){const i=t.reduce(this.SP,[]);return this.PP(i)}))}SP(t,i){return[...t,...i.amazonBidList.filter((t=>t.amazonBidCode)).map((t=>({lineItemId:i.lineItem.advertiserLineItemId,coreTamCode:t.amazonBidCode})))]}fP(t,i){return t.map((t=>new Fs(t,i)))}PP(t){return this.hP.callCoreTam(t)}uP(){return new Promise(((t,i)=>{(0,s.$K)(this.AP)?this.AP.fetchBids({slots:[{slotID:this.oP,mediaType:Ms.MEDIA_TYPE}]},(e=>{(0,S.BZ)(e)?t(e):i(v.ConnatixNoBidReasonEnum.EmptyResponse)})):i(v.ConnatixNoBidReasonEnum.NoLibInPage)}))}lP(){return $s(this,void 0,void 0,(function*(){if(!(0,s.$K)(this.AP)){if((0,s.QM)(this.Dc.amazonTamPubId)){const t=yield this._P();return this.AP=t,void this.AP.init({pubID:this.Dc.amazonTamPubId,deals:!0})}this.AP=this.aP[Ms.SDK_NAME_ON_PUB_WINDOW]}}))}_P(){const t=new At(this.yn,this.Zp);return new Promise(((i,e)=>{t.loadIframe({customHead:"<style> html, body {display: none}</style>",customHtml:`<script id='cnx-apstag-loader' type='text/javascript' src='${_t.n.endPoints.assets.plugins.apstagScript}'><\/script>`,customIframeAttributes:[{key:"class",value:"cnx-apstag-loader"}],container:this.yn.querySelector("head"),visible:!1,title:js.$b}).then((t=>{if(t.iframe.contentWindow[Ms.SDK_NAME_ON_PUB_WINDOW])return i(t.iframe.contentWindow[Ms.SDK_NAME_ON_PUB_WINDOW]);e(new Error("Amazon TAM not found"))})).catch((t=>{e(t)}))}))}}class qs{constructor(t,i,e){this.vI=t,this.xP=i,this.Dc=e,this.TP=new Us(this.vI,this.xP,new Bs(this.vI,this.Dc),this.vI.services.GlobalDomUtilsService,this.vI.config.sessionId,this.Dc)}request(t){const{width:i,height:e}=t.callingState;return this.SS(i,e)?this.kP(t).then((i=>Promise.resolve(this.CP(i,t)))).catch((()=>Promise.resolve({bids:[],noBids:[]}))):Promise.resolve({bids:[],noBids:[]})}kP(t){const i=t.lineItemRequestDataList.map((t=>t.adManagerLineItem.protoLineItem));return this.TP.requestBids(i)}CP(t,i){const e={bids:[],noBids:[]};return t.forEach((t=>{const s=Vi(i.lineItemRequestDataList,t.lineItemId);t.bids.forEach((t=>{const n=new Le,r=new Fe({encryptedPrice:t.encryptedPrice,requestNumber:s.historicalMetrics.requestNumber});Be(s.protoLineItem.trackers,n),e.bids.push({requestMetadata:r,vastTracker:n,lineItem:s,url:t.vastTag,state:i.callingState,successRate:t.successRate,obfuscatedPrice:t.ofskp,shouldRequestWithCredentials:!1,slotId:t.slotId})})),t.noBids.forEach((t=>{e.noBids.push({lineItem:s,requestMetadata:new Fe({requestNumber:s.historicalMetrics.requestNumber}),reason:t.reason})}))})),e}SS(t,i){return 0!==t&&0!==i||((0,p.n)({message:"AdManager_PrebidAggregator_dimensions",exception:`width:${t}_height:${i}_destroyed:${E.S.playerDestroyed}`,level:p.D.CRITICAL,sessionId:this.vI.config.sessionId},{throttle:5}),!1)}}class Hs{static getSelectionScore(t){return t.yoScore}}class zs{static sortDescBySelectionScore(t){return[...t].sort(((t,i)=>Hs.getSelectionScore(i)-Hs.getSelectionScore(t)))}static getBestBySelectionScore(t){return zs.sortDescBySelectionScore(t)[0]}}class Ws{constructor(){this.EP=new Set}static getInstance(){return this.INSTANCE||(this.INSTANCE=new Ws),this.INSTANCE}static MP(t,i){const e=t.lineItems.find((t=>{const{advertiserLineItemId:e,publisherLineItemId:s}=t.protoLineItem;return[e,s].includes(i)}));(0,s.$K)(e)&&t.remove(e)}static LP(t,i){t.getBidsByLineItemId(i).forEach((t=>t.invalidate()))}add(t,i,e){t.filter((t=>!this.EP.has(t))).forEach((t=>{this.EP.add(t),Ws.MP(i,t),Ws.LP(e,t)}))}hasLineItemById(t,i){return this.EP.has(t)||this.EP.has(i)}clear(){this.EP.clear()}}!function(t){t[t.IDLE=0]="IDLE",t[t.LOADING=1]="LOADING",t[t.CONSUMED_LOADING=2]="CONSUMED_LOADING",t[t.LOADED=3]="LOADED",t[t.STARTING=4]="STARTING",t[t.IMPRESSION=5]="IMPRESSION",t[t.CONSUMED_LOADED=6]="CONSUMED_LOADED",t[t.INVALIDATED=7]="INVALIDATED"}(Ns||(Ns={}));class Gs{static isLineItemTargetingAllowed(t,i){return Gs.isAllowedByViewability(t,i)&&Gs.isAllowedBySound(t,i)&&Gs.isAllowedByAdBreakType(t,i)&&Gs.isAllowedByMediaTargeting(t,i)&&Gs.isAllowedByPodTargeting(t,i)&&Gs.isAllowedByContextualTargeting(t,i)&&Gs.isAllowedByPlayerSizeTargeting(t,i)&&Gs.isAllowedByPlayerOrientationTargeting(t,i)&&Gs.isAllowedByJsQueryTargeting(t,i)&&Gs.isAllowedByAdTagInCaseOfExternal(t)}static isBidTargetingAllowed(t,i){const e=t.getAdDuration(),{sessionMaxAdDuration:s,remainingAdDuration:n}=i.adBreakState,{adManagerLineItem:r,dimensions:o}=t.settings,{adType:h,nonlinearLineItemSettings:a}=r.protoLineItem;return Gs.isLineItemTargetingAllowed(r,i)&&Gs.isAllowedRegardingDuration(e,s)&&Gs.isAllowedRegardingDuration(e,n)&&Gs.isDimensionsAllowedForNonLinearBanner(h,a,o,i)&&Gs.isAllowedByPageFocus(r,i)}static isAllowedByJsQueryTargeting(t,i){let e=!0;return t.protoLineItem.queryTargeting.filter((t=>t.rule===v.ProtoLineItemQueryTargetingRuleEnum.Only)).forEach((t=>{this.BP(t.keyValue,i.queryJsTargeting)||(e=!1)})),t.protoLineItem.queryTargeting.filter((t=>t.rule===v.ProtoLineItemQueryTargetingRuleEnum.Except)).forEach((t=>{this.BP(t.keyValue,i.queryJsTargeting)&&(e=!1)})),e}static BP(t,i){let e=!1;return Object.keys(i).forEach((s=>{i[s]===t[s]&&(e=!0)})),e}static isAllowedByAdTagInCaseOfExternal(t){return!t.protoLineItem.isExternal||((0,s.QM)(t.protoLineItem.adTag)||(0,s.QM)(t.protoLineItem.prebidJsBidParamsJSONString)||(0,s.QM)(t.protoLineItem.externalMediaFile)||(0,s.QM)(t.protoLineItem.externalHlsFile))}static isAllowedBySound(t,i){return!t.protoLineItem.sound||i.sound}static isAllowedByViewability(t,i){const e=i.adContainerState.get(t.protoLineItem.adType).viewability;return!t.protoLineItem.viewability||e}static isAllowedByAdBreakType(t,i){return!t.protoLineItem.adBreakSettings||t.protoLineItem.adBreakSettings.adBreakTargeting.some((t=>{if(t.adRollType===i.adBreakState.adBreakType)return Gs.isAdBreakTypeAllowed(t.adBreakTypeEnum,i.adBreakState.isAdPodBreak)}))}static isAllowedByPageFocus(t,i){return!(t.protoLineItem.removeOutOfFocus&&!i.isPageInFocus)}static isAllowedByMediaTargeting(t,i){return!(t.protoLineItem.mediaIdTargeting&&!Gs.stringTargetingFiltering(i.media.mediaId,t.protoLineItem.mediaIdTargeting))&&(!(t.protoLineItem.mediaKeywordsTargeting&&!Gs.stringTargetingFiltering(i.media.mediaKeywords,t.protoLineItem.mediaKeywordsTargeting))&&!(t.protoLineItem.mediaLanguageTargeting&&!Gs.stringTargetingFiltering(i.media.mediaLanguage,t.protoLineItem.mediaLanguageTargeting)))}static isAllowedByContextualTargeting(t,i){var e,s;const{advertiserContextualTargeting:n,publisherContextualTargeting:r}=t.protoLineItem,o=(null===(e=i.media.mediaInsights)||void 0===e?void 0:e.insights)||[],h=(null===(s=i.page.insights)||void 0===s?void 0:s.insights)||[];return!((0,S.BZ)(n)&&!Gs.isContextualTargetingValid(n,o,h))&&!((0,S.BZ)(r)&&!Gs.isContextualTargetingValid(r,o,h))}static isAllowedByPlayerSizeTargeting(t,i){const{playerSizeTargetings:e}=t.protoLineItem,{width:n}=i.adContainerState.get(t.protoLineItem.adType);return!(0,s.as)(e)||!(0,s.hj)(n)||(e.sizeChoiceCriteria===v.ProtoSizeChoiceCriteriaEnum.GreaterThan?!(0,s.hj)(e.minWidth)||n>=e.minWidth:e.sizeChoiceCriteria===v.ProtoSizeChoiceCriteriaEnum.SmallerThan?!(0,s.hj)(e.maxWidth)||n<=e.maxWidth:e.sizeChoiceCriteria!==v.ProtoSizeChoiceCriteriaEnum.Between||(!(0,s.hj)(e.maxWidth)||!(0,s.hj)(e.minWidth)||n>=e.minWidth&&n<=e.maxWidth))}static isAllowedByPlayerOrientationTargeting(t,i){const{playerOrientationTargeting:e}=t.protoLineItem;switch(e){case v.ProtoPlayerOrientationTargetingEnum.Landscape:if(i.playerOrientation===ri.Portrait)return!1;break;case v.ProtoPlayerOrientationTargetingEnum.Portrait:if(i.playerOrientation===ri.Landscape)return!1}return!0}static isAllowedByPodTargeting(t,i){var e;const s=null===(e=t.protoLineItem.adBreakSettings)||void 0===e?void 0:e.adPodTargeting;if(!s)return!0;if(!i.adBreakState.isAdPodBreak)return!0;const n=i.adBreakState.adPodSlotIndex;let r=!0;switch(s.adSlotTargetingType){case v.ProtoLineItemAdSlotTargetingTypeEnum.Interval:(n<s.adSlotPositions[0]||n>s.adSlotPositions[1])&&(r=!1);break;case v.ProtoLineItemAdSlotTargetingTypeEnum.SpecificSlots:-1===s.adSlotPositions.indexOf(n)&&(r=!1)}return s.targetingType===v.ProtoLineItemTargetingTypeEnum.Except&&(r=!r),r}static isAllowedRegardingDuration(t,i){return!t||0===i||t<=i}static isDimensionsAllowedForNonLinearBanner(t,i,e,s){if(!Ni(t,null==i?void 0:i.nonLinearRequestType))return!0;const n=Math.ceil((0,$i.Tc)(s.height,oi.NON_LINEAR_MAX_HEIGHT_PERCENT));return!(!e||(null==e?void 0:e.width)>s.width||(null==e?void 0:e.height)>n)}static stringTargetingFiltering(t,i){if((0,S.BZ)(i.items)&&Array.isArray(t)){const e=(0,S.tN)(t,i.items).length;return i.choiceCriteria===v.ProtoChoiceCriteriaEnum.Only?e>0:0===e}const e=(0,S.d3)(t,i.items);return i.choiceCriteria===v.ProtoChoiceCriteriaEnum.Only?e:!e}static isAdBreakTypeAllowed(t,i){switch(t){case v.ProtoLineItemAdBreakTypeEnum.All:return!0;case v.ProtoLineItemAdBreakTypeEnum.AdPod:return i;case v.ProtoLineItemAdBreakTypeEnum.SingleAd:return!i}}static isContextualTargetingValid(t,i,e){return t.some((t=>Gs.isContextualTargetingCaseValid(t,i,e)))}static isContextualTargetingCaseValid(t,i,e){for(let s=0;s<t.filters.length;s++){const n=t.filters[s],r=n.hashedItemsIds,o=i.filter((t=>r.includes(t))).length,h=e.filter((t=>r.includes(t))).length,a=Gs.isContextualTargetingFilterValid(n.type,o,r),c=Gs.isContextualTargetingFilterValid(n.type,h,r);switch(n.level){case v.ProtoContextualTargetingLevelEnum.Media:if(!a)return!1;break;case v.ProtoContextualTargetingLevelEnum.Page:if(!c)return!1;break;case v.ProtoContextualTargetingLevelEnum.Both:if(!a||!c)return!1}}return!0}static isContextualTargetingFilterValid(t,i,e){switch(t){case v.ProtoLineItemContextualTargetingEnum.IncludeAny:if(0===i)return!1;break;case v.ProtoLineItemContextualTargetingEnum.IncludeAll:if(i!==e.length)return!1;break;case v.ProtoLineItemContextualTargetingEnum.ExcludeAny:if(i>0)return!1;break;case v.ProtoLineItemContextualTargetingEnum.ExcludeAll:if(i===e.length)return!1}return!0}}class Xs{constructor(t,i,e,s){this.RP=t,this.OP=i,this.DP=e,this.VP=s}getRequestEvents(t){return this.OP.getEvents(t)}hasAggregatorType(t){return this.RP.hasAggregatorType(t)}getAll(){return this.RP.lineItems}getAllByAggregator(t){return this.RP.getByAggregation(t)}getAllByRequest(t){return t?this.OP.lineItems:(0,S.V7)(this.RP.lineItems,this.OP.lineItems)}getAllCallable(t){return this.RP.lineItems.filter((t=>!Ws.getInstance().hasLineItemById(t.protoLineItem.advertiserLineItemId,t.protoLineItem.publisherLineItemId))).filter((i=>this.FP(i,t))).filter((i=>Gs.isLineItemTargetingAllowed(i,t))).filter((i=>this.NP(i,t)))}getBestCallable(t,i){if(!i)return;const e=this.jP(t);return e?{state:i,lineItemList:this.$P(e,t)}:void 0}NP(t,i){const{hasAggregator:e,protoLineItem:s}=t;return!(!e&&!s.forceCallingInEveryAO)||this.UP(t,i)}UP(t,i){const e=Hs.getSelectionScore(t),s=this.getAllByRequest(!0),n=this.DP.getBidsByStatus([Ns.IDLE,Ns.LOADING,Ns.LOADED]).filter((t=>this.qP(t,i))).some((t=>e<Hs.getSelectionScore(t))),r=s.some((t=>e<Hs.getSelectionScore(t)));return!n&&!r}FP(t,i){if(t.aggregators.size>0)return!1;const{advertiserLineItemId:e,forceCallingInEveryAO:s}=t.protoLineItem,n=this.DP.getBidsByLineItemId(e).filter((t=>t.status!==Ns.IMPRESSION));return!(!t.hasAggregator&&(n.length>0||t.bidsInFetch.size>0)&&!s)&&this.VP.callingValidationAggregator.canCall(t,i.adOpportunity.id)}jP(t){let i=t;return t.some((t=>t.hasAggregator))&&(i=i.filter((t=>t.hasAggregator))),zs.getBestBySelectionScore(i)}$P(t,i){if(t.hasAggregator){const{creativeType:e}=t.protoLineItem,s=i.filter((t=>e===t.protoLineItem.creativeType));return zs.sortDescBySelectionScore(s)}return[t]}qP(t,i){return this.VP.impressionCapsValidationService.canCall(t.settings.adManagerLineItem,i.adOpportunity.id)&&Gs.isBidTargetingAllowed(t,i)}}var Qs=r(5885);class Js{constructor(t,i,e,s,n){this.HP=t,this.DP=i,this.VP=e,this.ci=s,this.Zp=n,this.zP=(t,i)=>{const e=[],s=[];for(const n of t){this.qP(n,i)?e.push(n):s.push(n)}return{allowedBidList:e,notAllowedBidList:s}}}static isBidTargetingAllowedEverInSession(t,i){const{protoLineItem:e}=t.settings.adManagerLineItem,{advertiserLineItemId:s,publisherLineItemId:n}=e,{sessionMaxAdDuration:r}=i.adBreakState,o=t.getAdDuration();return Gs.isAllowedRegardingDuration(o,r)&&!Ws.getInstance().hasLineItemById(s,n)}getBidEvents(t){return this.DP.getEvents(t)}hasReachTheMaxNumberOfReadyBids(){const{maxNumberOfWins:t}=this.ci;if(-1===t)return!1;return this.DP.getBidsByStatus([Ns.LOADING,Ns.LOADED,Ns.STARTING,Ns.IMPRESSION]).length>=t}hasLoadingBids(){const t=this.DP.getBidsByStatus([Ns.LOADING]);return(0,S.BZ)(t)}hasLoadedBids(){const t=this.DP.getBidsByStatus([Ns.LOADED]);return(0,S.BZ)(t)}hasAdsEligibleForFill(t){const i=this.HP.bidInFetchList.filter((i=>this.WP(i.adManagerLineItem,t))),e=this.DP.getBidsByStatus([Ns.IDLE,Ns.LOADING,Ns.LOADED]).filter((i=>this.qP(i,t)));return(0,S.BZ)(e)||(0,S.BZ)(i)}getEligibleBidsInFetchInAuctionSortedDescBySelectionScore(t){return zs.sortDescBySelectionScore(this.HP.bidInFetchList.filter((i=>this.GP(i.adManagerLineItem,t))))}getEligibleBidsInAuctionSortedBySelectionScore(t){return zs.sortDescBySelectionScore(this.DP.getBidsByStatus([Ns.IDLE,Ns.LOADING,Ns.LOADED]).filter((i=>this.qP(i,t))))}isBestBidLoaded(t){const i=this.getBestLoadedBid();if(!i)return!1;const e=this.DP.getBidsByStatus([Ns.IDLE]),s=this.selectBestBid(e,t),n=[...this.DP.getBidsByStatus([Ns.LOADING])];s.selectedBid&&n.push(s.selectedBid);const r=zs.getBestBySelectionScore(n);return!r||i.yoScore>=r.yoScore}getBestLoadedBid(){const t=this.DP.getBidsByStatus([Ns.LOADED]);return zs.getBestBySelectionScore(t)}getAllBidPricesSortedDesc(){return this.DP.getAllBids().map((t=>t.price)).sort(((t,i)=>i-t))}getBestAllowedBidPrice(t){return[...this.DP.getBidsByStatus([Ns.IDLE,Ns.LOADING,Ns.LOADED])].filter((i=>this.qP(i,t))).sort(((t,i)=>i.price-t.price)).map((t=>t.price))[0]||0}getWinnableBidPricesSortedDesc(){return this.DP.getBidsByStatus([Ns.LOADING,Ns.LOADED]).sort(((t,i)=>i.price-t.price)).map((t=>t.price))}getBestBidAllowedByStatus(t,i){const e=this.DP.getBidsByStatus(t);return this.XP(e,i)}getBestBidAllowed(t){const i=this.DP.getAllBids();return this.XP(i,t)}selectBestBid(t,i){let e=t;const s=L.h.getSessionChildContainer(this.Zp).resolve(Qs.P);if(s.isImaTestCaseForSS()||s.isMarriageDotComDomain()||s.isDailykosDotComDomain()){this.DP.getBidsByStatus([Ns.IMPRESSION,Ns.LOADING,Ns.LOADED,Ns.STARTING]).find((t=>"ima"===t.adMediaType))&&(e=e.filter((t=>"ima"!==t.adMediaType)))}const n=this.zP(e,i),{allowedBidList:r,notAllowedBidList:o}=n,h=(0,S.BZ)(r)&&zs.getBestBySelectionScore(r)||null,a=o.map((t=>({bid:t,lossReason:this.QP(t,i)}))),c=r.filter((t=>t!==h)).map((t=>({bid:t,lossReason:v.ProtoAuctionLossReasonEnum.CompetitorPriority})));return{state:i,selectedBid:h,unselectedBidList:[...a,...c]}}selectBestBidForWin(t,i){const e=this.JP(i),s=this.YP(t,i);return this.KP(e,s)}JP(t){const i=this.DP.getBidsByStatus([Ns.IDLE]);return this.selectBestBid(i,t)}YP(t,i){const e=[...t,...this.DP.getBidsByStatus([Ns.LOADED])];return this.selectBestBid(e,i)}KP(t,i){const e=Object.assign({},t);return t.selectedBid&&i.selectedBid?(Hs.getSelectionScore(i.selectedBid)>Hs.getSelectionScore(t.selectedBid)&&(e.selectedBid=null,e.unselectedBidList.push({bid:t.selectedBid,lossReason:v.ProtoAuctionLossReasonEnum.CompetitorPriority})),e):e}QP(t,i){const e=t.getAdDuration(),s=i.adBreakState.remainingAdDuration;return Gs.isAllowedRegardingDuration(e,s)?v.ProtoAuctionLossReasonEnum.AdOpportunityEnd:v.ProtoAuctionLossReasonEnum.TargetingMismatch}GP(t,i){const e=[v.ProtoCreativeTypeEnum.ThirdParty,v.ProtoCreativeTypeEnum.External],s=t.protoLineItem.creativeType,n=e.includes(s),r=this.WP(t,i);return!n&&r}qP(t,i){return this.VP.impressionCapsValidationService.canCall(t.settings.adManagerLineItem,i.adOpportunity.id)&&Gs.isBidTargetingAllowed(t,i)}WP(t,i){return this.VP.impressionCapsValidationService.canCall(t,i.adOpportunity.id)&&Gs.isLineItemTargetingAllowed(t,i)}XP(t,i){const e=t.filter((t=>this.qP(t,i)));return zs.getBestBySelectionScore(e)}}class Ys{constructor(t,i,e,s,n,r,o){this.RP=t,this.OP=i,this.HP=e,this.DP=s,this.VP=n,this.ci=r,this.ZP=new Xs(this.RP,this.OP,this.DP,{callingValidationAggregator:this.VP.callingValidationAggregator,impressionCapsValidationService:this.VP.impressionCapService}),this.tA=new Js(this.HP,this.DP,{impressionCapsValidationService:this.VP.impressionCapService},{maxNumberOfWins:this.ci.maxNumberOfWins},o)}static isBidTargetingAllowedEverInSession(t,i){return Js.isBidTargetingAllowedEverInSession(t,i)}getLineItemRequestEvents(t){return this.ZP.getRequestEvents(t)}getBidEvents(t){return this.tA.getBidEvents(t)}hasAggregatorType(t){return this.ZP.hasAggregatorType(t)}getAllLineItems(){return this.ZP.getAll()}getLineItemsByAggregation(t){return this.ZP.getAllByAggregator(t)}getLineItemsByRequest(t){return this.ZP.getAllByRequest(t)}getAllCallableLineItems(t){return this.ZP.getAllCallable(t)}getBestCallableLineItem(t,i){return this.ZP.getBestCallable(t,i)}hasLoadingBids(){return this.tA.hasLoadingBids()}hasLoadedBids(){return this.tA.hasLoadedBids()}isBestBidLoaded(t){return this.tA.isBestBidLoaded(t)}getBestLoadedBid(){return this.tA.getBestLoadedBid()}hasReachTheMaxNumberOfReadyBids(){return this.tA.hasReachTheMaxNumberOfReadyBids()}hasAdsEligibleForFill(t){return this.tA.hasAdsEligibleForFill(t)}getEligibleBidsInFetchInAuctionSortedDescBySelectionScore(t){return this.tA.getEligibleBidsInFetchInAuctionSortedDescBySelectionScore(t)}getEligibleBidsInAuctionSortedDescBySelectionScore(t){return this.tA.getEligibleBidsInAuctionSortedBySelectionScore(t)}getAllBidPricesSortedDesc(){return this.tA.getAllBidPricesSortedDesc()}getBestAllowedBidPrice(t){return this.tA.getBestAllowedBidPrice(t)}getWinnableBidPricesSortedDesc(){return this.tA.getWinnableBidPricesSortedDesc()}getBestBidAllowedByStatus(t,i){return this.tA.getBestBidAllowedByStatus(t,i)}getBestBidAllowed(t){return this.tA.getBestBidAllowed(t)}selectBestBid(t,i){return this.tA.selectBestBid(t,i)}selectBestBidForWin(t){const i=this.DP.getBidsByStatus([Ns.LOADING]);return this.tA.selectBestBidForWin(i,t)}}var Ks=r(4065);const Zs=[[88,31],[120,20],[120,30],[120,60],[120,90],[125,125],[168,28],[168,42],[180,150],[200,200],[200,446],[216,36],[216,54],[220,90],[234,60],[240,133],[250,250],[250,360],[292,30],[300,31],[300,50],[300,75],[300,100],[300,250],[320,50],[320,100],[320,240],[336,280],[400,350],[468,60],[480,320]];class tn{constructor(t,i,e){this.iA=t,this.sA=i,this.nA=e,this.rA=`div-gpt-ad-1589549806211-${(0,h.qs)()}`,this.oA=new J.x,this.hA=new J.x,this.aA=new J.x}get onCreativeReceived(){return this.aA.asObservable()}get onDisplayAd(){return this.oA.asObservable()}get onError(){return this.hA.asObservable()}getAdMediaHeight(){return this.cA?this.cA.clientHeight:0}getAdMediaWidth(){return this.cA?this.cA.clientWidth:0}initializeAd(t,i){try{this.dA=t,this.lA(t);const e=this.uA(i.width,i.height);this.iA.cmd.push((()=>{this.pA=this.iA.defineSlot(this.nA,e,this.rA).addService(this.iA.pubads()).setTargeting("domains",this.sA),this.iA.enableServices(),this.fA(this.pA),this.iA.pubads().isInitialLoadDisabled()&&this.iA.pubads().refresh([this.pA]),this.iA.display(this.rA)}))}catch(t){this.hA.next(k.WrapperInitAdError)}}destroy(){this.iA.cmd.push((()=>{this.iA.destroySlots&&this.pA&&this.iA.destroySlots([this.pA])}))}fA(t){this.iA.pubads().addEventListener("slotOnload",(i=>{var e,s;if(i.slot===t){try{const t=null===(s=null===(e=null==i?void 0:i.slot)||void 0===e?void 0:e.getResponseInformation())||void 0===s?void 0:s.creativeId;t&&this.aA.next(t.toString())}catch(t){(0,p.n)({message:"AdManager_GptWrapper_creativeId",level:p.D.WARN,exception:t.message,callStack:t.stack})}this.oA.next()}})),this.iA.pubads().addEventListener("slotRenderEnded",(t=>{var i;if(t.slot===this.pA){try{this.cA=null===(i=this.dA)||void 0===i?void 0:i.getElementsByTagName("iframe")[0],(0,s.$K)(this.pA)&&(0,u.AX)(this.cA.contentWindow,"GPTWrapper")}catch(t){}t.isEmpty&&this.hA.next(k.AdxOverlayNoFill)}}))}lA(t){t.id=this.rA}uA(t,i){return Zs.filter((e=>!Array.isArray(e)||!(0,S.fn)(e)||(0,S.BZ)(e)&&e[0]<=t&&e[1]<=i))}}var en,sn,nn=r(1509);!function(t){t.VOLUME_DETECTED="volume_detected",t.MALWARE_DETECTED="malware_detected",t.BADURI_DETECTED="baduri_detected"}(en||(en={})),function(t){t[t.None=0]="None",t[t.Mute=1]="Mute",t[t.ScrollHijack=2]="ScrollHijack",t[t.MemoryLeak=4]="MemoryLeak",t[t.Malware=8]="Malware",t[t.All=15]="All"}(sn||(sn={}));class rn{constructor(){this.wI=new J.x}get onVpaidEvent(){return this.wI.asObservable()}handshakeVersion(t="2.0"){return"2.0"}}var on;!function(t){t[t.Win=0]="Win",t[t.AdLoaded=1]="AdLoaded",t[t.AdStarted=2]="AdStarted",t[t.AdImpression=3]="AdImpression"}(on||(on={}));class hn{constructor(t){this.mA=t,this.gA=new Map,(0,s.$K)(this.mA.settings.bidLifecycle)||(this.mA.settings.bidLifecycle={})}onTrackingLifecycleEvent(t){switch(this.gA.set(t,Date.now()),t){case on.AdLoaded:this.vA();break;case on.AdImpression:this.yA()}}vA(){this.mA.settings.bidLifecycle.winToAdLoadedTime=this.bA}yA(){this.mA.settings.bidLifecycle.startAdToImpressionTime=this.IA}get IA(){return this.gA.get(on.AdImpression)&&this.gA.get(on.AdStarted)?this.gA.get(on.AdImpression)-this.gA.get(on.AdStarted):0}get bA(){return this.gA.get(on.AdLoaded)&&this.gA.get(on.Win)?this.gA.get(on.AdLoaded)-this.gA.get(on.Win):0}}var an,cn=r(2239);!function(t){t.IMPRESSION_TIMEOUT="IMPRESSION_TIMEOUT",t.VIEWABLE_IMPRESSION_TIMEOUT="VIEWABLE_IMPRESSION_TIMEOUT",t.SKIP_AD_TIMEOUT="SKIP_AD_TIMEOUT",t.STOP_AD_TIMEOUT="STOP_AD_TIMEOUT",t.AD_LOADED_TIMEOUT="AD_LOADED_TIMEOUT"}(an||(an={}));const dn=[T.AdImpression,T.AdSkipped,T.AdStopped,T.AdError,T.AdVideoFirstQuartile,T.AdVideoMidpoint,T.AdVideoThirdQuartile,T.AdVideoComplete],ln="cnx-ad-bid-slot-selected",un="Connatix Ad";class pn extends rn{constructor(t,i){super(),this.Ws=t,this.settings=i,this.bidStatusHistory=[],this.wA=null,this.SA=null,this.PA=null,this.AA=null,this._A=void 0,this.xA=!1,this.TA=!1,this.kA=!1,this.eg=!1,this.CA=!1,this.EA=!1,this.MA=!1,this.LA=[],this.BA=null,this.RA=new J.x,this.OA=new J.x,this.DA=new J.x,this.Fc=[],this.VA=!1,this.FA=()=>{this.NA({type:T.AdError,payload:{errorMessage:k.Timeout,errorCode:Te.ImpressionTimeout}}),this.LA.length&&(0,p.n)({message:"BidAdaptor_ImpressionTimeout",exception:`advertiserLineItemId:${this.settings.adManagerLineItem.protoLineItem.advertiserLineItemId}_creativeId:${this.creativeId}_bidid:${this.settings.bidId}`,callStack:JSON.stringify(this.LA),level:p.D.WARN}),this.jA()},this.$A=()=>{this.UA(),this.qA(an.VIEWABLE_IMPRESSION_TIMEOUT).clearTimeout(),this.settings.viewabilityService.off(this.wA,this.HA)},this.HA=t=>{const i=this.qA(an.VIEWABLE_IMPRESSION_TIMEOUT);this.DA.next(t),t?i.timeoutHandle.timeoutId||i.setTimeout():i.clearTimeout()},this.zA=()=>{this.NA({type:T.AdSkipped}),this.jA()},this.WA=()=>{this.NA({type:T.AdStopped,payload:{shouldTrackPostBid:!0}}),this.jA()},this.GA=()=>{const t=Te.MediaFileUriTimeout;this.QA=t,this.NA({type:T.AdError,payload:{errorCode:t,errorMessage:k.TimeoutLoaded}}),this.jA()},this.qA=t=>{const i=this.JA[t];return{timeoutHandle:i,setTimeout:()=>{i.timeoutId=this.Ws.setTimeout((()=>{i.callback()}),i.timeout)},clearTimeout:()=>{null!==i.timeoutId&&(this.Ws.clearTimeout(i.timeoutId),i.timeoutId=null)}}},this.status=Ns.IDLE,this.price=this.settings.price,this.yoScore=this.settings.yoScore,this.YA=L.h.getSessionChildContainer(this.settings.sessionId).resolve(Qs.P),this.KA=Date.now(),this.creativeId=this.settings.externalCreativeId,this.ZA=`cnx-ad-bid-slot-id-${this.settings.requestMetadata.data.cnxBidId}`,this.t_=`cnx-ad-slot-${this.settings.bidId}`;const{adType:e}=this.settings.adManagerLineItem.protoLineItem;this.JA={[an.IMPRESSION_TIMEOUT]:{callback:this.FA,timeout:25e3,timeoutId:null},[an.VIEWABLE_IMPRESSION_TIMEOUT]:{callback:this.$A,timeout:js.xs[e],timeoutId:null},[an.SKIP_AD_TIMEOUT]:{callback:this.zA,timeout:500,timeoutId:null},[an.STOP_AD_TIMEOUT]:{callback:this.WA,timeout:500,timeoutId:null},[an.AD_LOADED_TIMEOUT]:{callback:this.GA,timeout:25e3,timeoutId:null}},this.Jv=i.urlSuffixerService}set status(t){this.i_=t,this.bidStatusHistory.push(Ns[t]),this.RA.next(t)}get status(){return this.i_}get onStatusChanged(){return this.RA.asObservable()}get createdTimestamp(){return this.KA}get loadingTimeMs(){return this.e_}get startingTimeMs(){return this.n_}get started(){return this.kA}get errorReason(){return this.r_}get vastErrorCode(){return this.QA}get shouldTrackPostbid(){return this.VA}get onAdSlotViewabilityChanged(){return this.DA.asObservable()}invalidate(){this.kA||(this.status=Ns.INVALIDATED)}skipAd(){this.qA(an.SKIP_AD_TIMEOUT).setTimeout()}stopAd(t){if((0,h.Vm)([95,5])){const i=L.h.getSessionChildContainer(this.settings.sessionId).resolve(cn.B);(0,p.n)({message:"META_LOW_VCR_"+(i.implementationType===v.ProtoImplementationType.Amp?"AMP":"NOT_AMP"),level:p.D.INFO,callStack:this.settings.adManagerLineItem.protoLineItem.advertiserLineItemId,exception:t})}this.qA(an.STOP_AD_TIMEOUT).setTimeout()}startAd(){const{adManagerLineItem:t,bidId:i,requestMetadata:e}=this.settings;this.o_=Date.now(),this.kA=!0,this.status=Ns.STARTING,this.EA&&(0,p.n)({message:"AdManager_ABaseBidAdaptor_samebid",exception:"startAd",callStack:`adv:${this.settings.adManagerLineItem.protoLineItem.advertiserLineItemId} bidid: ${this.t_}`,level:p.D.CRITICAL}),this.EA=!0,this.qA(an.IMPRESSION_TIMEOUT).setTimeout()}initAd(t,i,e,s,n,r,o){this.a_=Date.now(),this.status=Ns.LOADING,this.CA&&(0,p.n)({message:"AdManager_ABaseBidAdaptor_samebid",exception:"initAd",callStack:`adv:${this.settings.adManagerLineItem.protoLineItem.advertiserLineItemId} bidid: ${this.t_}`,level:p.D.CRITICAL}),this.CA=!0,this.qA(an.AD_LOADED_TIMEOUT).setTimeout(),this.lA(o),this.c_=new hn(this),this.c_.onTrackingLifecycleEvent(on.Win)}setAdVolume(t){this.SA.volume=t,(0,u.Q1)(this.SA,t),this.YA.isImaTestCaseForSS()||(t<=0?this.settings.adEnforcer.start(sn.Mute):this.settings.adEnforcer.stop(sn.Mute))}getTrackerSlot(){return this.PA}get impressionStarted(){return this.xA}get creativeId(){return this._A}set creativeId(t){(0,s.QM)(this.creativeId)||(this._A=t)}get onAdViewableImpression(){return this.OA.asObservable()}d_(t){let i;(0,s.hj)(t.payload.skipOffset)&&(i=t.payload.skipOffset);const e={type:T.AdLoaded,payload:{adType:this.settings.adManagerLineItem.protoLineItem.adType,adLoadedData:{skipOffset:i},adSkipMode:this.settings.adManagerLineItem.protoLineItem.skipMode,vastVerifications:t.payload.verificationScriptResources,containers:t.payload.containers}};return this.settings.adLoadedPayload=e,e}l_(){if(this.PA){const t=this.PA.getAttribute("aria-hidden");this.PA.setAttribute("aria-hidden","true"===t?"false":"true")}}u_(t){return{type:T.AdImpression,payload:{adType:this.settings.adManagerLineItem.protoLineItem.adType,adSkipMode:this.settings.adManagerLineItem.protoLineItem.skipMode,adSourceData:{moatTrackingEnabled:this.settings.adManagerLineItem.protoLineItem.moatTrackingEnabled,creativeId:this.settings.adManagerLineItem.protoLineItem.cnxCreativeId,adId:this.settings.adManagerLineItem.protoLineItem.advertiserLineItemId,length:this.getAdDuration(),adVideoUrl:this.adVideoUrl,name:un,skipOffset:this.skipOffset},customAdData:{ADVERTISER:this.settings.requestMetadata.data.rtbAdomain,CREATIVE_ID:this.creativeId,CAMPAIGN_ID:this.settings.requestMetadata.data.rtbCampainId}}}}get skipOffset(){var t,i,e;return null===(e=null===(i=null===(t=this.settings.adLoadedPayload)||void 0===t?void 0:t.payload)||void 0===i?void 0:i.adLoadedData)||void 0===e?void 0:e.skipOffset}p_(t){return{type:T.AdVideoStart,payload:{adType:this.settings.adManagerLineItem.protoLineItem.adType,adSkipMode:this.settings.adManagerLineItem.protoLineItem.skipMode,adSourceData:{moatTrackingEnabled:this.settings.adManagerLineItem.protoLineItem.moatTrackingEnabled,creativeId:this.settings.adManagerLineItem.protoLineItem.cnxCreativeId,adId:this.settings.adManagerLineItem.protoLineItem.advertiserLineItemId,length:this.getAdDuration(),name:un},customAdData:{ADVERTISER:this.settings.requestMetadata.data.rtbAdomain,CREATIVE_ID:this.creativeId,CAMPAIGN_ID:this.settings.requestMetadata.data.rtbCampainId},logInMobiInfo:t.payload.logInMobiInfo}}}NA(t){if(t.payload||(t.payload={}),this.f_(t.type),t.payload.adType=this.settings.adManagerLineItem.protoLineItem.adType,!this.m_(t))return void this.NA({type:T.AdError,payload:{errorMessage:k.InvalidVpaidEvent}});const{adManagerLineItem:i,bidId:e,requestMetadata:n}=this.settings,{cnxBidId:r}=n.data;switch(t.type){case T.AdLoaded:0,this.c_.onTrackingLifecycleEvent(on.AdLoaded),this.qA(an.AD_LOADED_TIMEOUT).clearTimeout(),this.wI.next(this.d_(t)),this.TA=!0,this.e_=(0,s.hj)(this.a_)?Date.now()-this.a_:0,this.status=Ns.LOADED;break;case T.AdImpression:this.n_=(0,s.hj)(this.o_)?Date.now()-this.o_:0,this.c_.onTrackingLifecycleEvent(on.AdImpression),this.qA(an.IMPRESSION_TIMEOUT).clearTimeout(),this.g_(),(0,u.cn)(this.PA,ln),this.l_(),this.wI.next(this.u_(t)),this.xA=!0,this.status=Ns.IMPRESSION;break;case T.AdVideoStart:this.c_.onTrackingLifecycleEvent(on.AdStarted),this.wI.next(this.p_(t));break;case T.AdStopped:case T.AdSkipped:case T.AdError:this.v_(t);break;default:this.wI.next(t)}}v_(t){var i;this.eg?(0,p.n)({message:"AdManager_ABaseBidAdaptor_double_destroy",exception:this.settings.adManagerLineItem.protoLineItem.advertiserLineItemId,level:p.D.WARN}):((0,s.hj)(this.e_)||((0,s.hj)(this.a_)?this.e_=Date.now()-this.a_:this.e_=0),(0,s.hj)(this.n_)||((0,s.hj)(this.o_)?this.n_=Date.now()-this.o_:this.n_=0),T.AdError===t.type&&(this.r_=t.payload.errorMessage,this.VA=!0),T.AdStopped===t.type&&(this.r_=k.AdStopped,this.VA=!!(null===(i=t.payload)||void 0===i?void 0:i.shouldTrackPostBid)),T.AdSkipped===t.type&&(this.r_=k.AdStopped,this.VA=!1),this.Wg(),this.wI.next(t),this.i_!==Ns.INVALIDATED&&(this.TA?this.status=Ns.CONSUMED_LOADED:(this.i_!==Ns.LOADING&&(0,p.n)({message:"Bid_idle_consumed",level:p.D.WARN},{throttle:1,shouldSendMaxLog:!1}),this.status=Ns.CONSUMED_LOADING)))}lA(t){this.AA=this.y_(),this.PA=this.AA.slotsContainer,(0,u.cn)(this.PA,this.ZA),this.wA=this.AA.adSlot,this.wA.id=this.t_,this.PA.id=this.settings.bidSlotId,this.SA=this.AA.videoSlot,this.SA.volume=t,(0,u.Q1)(this.SA,t),this.YA.isImaTestCaseForSS()||(this.settings.adEnforcer.registerContainer(this.PA,this.t_),this.Fc.push(this.settings.adEnforcer.onEnforcerEvent.subscribe((t=>{this.b_(t)}))),this.settings.adEnforcer.start(sn.All))}y_(){return this.settings.adSlotContainerRecycler.requestAdSlot(this.settings.adContainer)}Wg(){this.eg=!0,(0,u.IV)(this.PA,ln),(0,u.IV)(this.PA,this.ZA),this.wA.removeAttribute("id"),this.PA.removeAttribute("id"),this.l_(),(0,it.i)(this.Fc),this.jA(),this.settings.adEnforcer.deregisterContainer(this.PA),this.settings.viewabilityService.off(this.wA,this.HA),null!==this.BA&&this.Ws.clearTimeout(this.BA),this.I_()}I_(){this.BA=this.Ws.setTimeout((()=>{this.settings.adSlotContainerRecycler.destroyAdSlot(this.AA)}),500)}UA(){const{advertiserLineItemId:t,publisherLineItemId:i}=this.settings.adManagerLineItem.protoLineItem;this.OA.next({advertiserLineItemId:t,publisherLineItemId:i,rtbSeatId:this.settings.requestMetadata.data.rtbSeatId,dspId:this.settings.requestMetadata.data.dspId,rtbAdomain:this.settings.requestMetadata.data.rtbAdomain})}g_(){const t=js.fJ,i=this.wA;this.settings.viewabilityService.on(i,this.HA,{threshold:t}),this.HA(this.settings.viewabilityService.check({threshold:t,element:i}))}jA(){Object.keys(this.JA).forEach((t=>{this.qA(t).clearTimeout()}))}m_(t){return!(!this.xA&&(t.type===T.AdStopped||t.type===T.AdSkipped))}b_(t){if(t.detectedContainer!==this.PA)return;let i;switch(t.type){case en.BADURI_DETECTED:i="AdManager_enforcer_BadUri";break;case en.MALWARE_DETECTED:i="AdManager_enforcer_malware",this.NA({type:T.AdError,payload:{errorMessage:k.EnforcementMalware}});break;case en.VOLUME_DETECTED:i="AdManager_enforcer_soundBlock",this.NA({type:T.AdError,payload:{errorMessage:k.EnforcementVolume}})}(0,p.n)({message:i,exception:t.message,level:p.D.WARN})}f_(t){if(!this.CA&&(dn.includes(t)||t===T.AdLoaded)){if(this.LA.push(t),this.MA)return;this.MA=!0,(0,p.n)({message:`${this.adMediaType?this.adMediaType:""}BidAdaptor_AdIdle_${t}BeforeInitAd`,exception:`advertiserLineItemId:${this.settings.adManagerLineItem.protoLineItem.advertiserLineItemId}_creativeId:${this.creativeId}_bidid:${this.settings.bidId}`,callStack:"PostBidInitAd",level:p.D.WARN})}if(this.TA&&!this.EA&&dn.includes(t)){if(this.LA.push(t),this.MA)return;this.MA=!0,(0,p.n)({message:`${this.adMediaType?this.adMediaType:""}BidAdaptor_AdLoaded_${t}WithoutStartAd`,exception:`advertiserLineItemId:${this.settings.adManagerLineItem.protoLineItem.advertiserLineItemId}_creativeId:${this.creativeId}_bidid:${this.settings.bidId}`,callStack:"PostBidStartAd",level:p.D.WARN})}}w_(t,i,e){const s=this.settings.adManagerLineItem.protoLineItem.advertiserLineItemId,n=this.creativeId;(0,p.n)({message:`AdManager_${t}_${i}`,exception:`advertiserLineItemId:${s}_creativeId:${n}_errorMessage:${null==e?void 0:e.message}`,callStack:null==e?void 0:e.stack,level:p.D.WARN},{throttle:5})}}var fn=r(4581);class mn extends pn{constructor(t,i){super(t,i),this.Ws=t,this.settings=i,this.adMediaType="displayAdx",this.adSourceType=v.ProtoAdsourceTypeEnum.Unknown,this.S_="adx",this.P_={[nn.n.FirstQuartile]:T.AdVideoFirstQuartile,[nn.n.SecondQuartile]:T.AdVideoMidpoint,[nn.n.ThirdQuartile]:T.AdVideoThirdQuartile,[nn.n.FourthQuartile]:T.AdVideoComplete},this.A_=[];const e=this.settings.adManagerLineItem.protoLineItem.overlayTime*Lt.s_;this.__=new Ks.B(this.Ws,e,500),this.A_.push(this.__.onTimeUpdate.subscribe((()=>{this.NA({type:T.AdRemainingTimeChange})})),this.__.onTimeElapsed.subscribe((()=>{this.stopAd("adxTimerElapsed")})),this.__.onQuartile.subscribe((t=>{this.NA({type:this.P_[t],payload:{}})})))}initAd(t,i,e,s,n,r,o){try{super.initAd(t,i,e,s,n,r,o),this.x_={width:t,height:i},this.T_().then((t=>{this.k_=new tn(t,this.settings.domain,this.settings.adxAdUnitPath),this.A_.push(this.k_.onCreativeReceived.subscribe((t=>{this.creativeId=t}))),this.NA({type:T.AdLoaded,payload:{skipOffset:0}})})).catch((t=>{this.NA({type:T.AdError,payload:{errorMessage:k.AdxOverlayGptScriptLoad+`_${t.message}`}})}))}catch(t){this.NA({type:T.AdError,payload:{errorMessage:k.AdaptorInitAdError+`_${t.message}`}})}}startAd(){try{super.startAd(),this.A_.push(this.k_.onDisplayAd.subscribe((()=>{this.NA({type:T.AdStarted}),this.NA({type:T.AdVideoStart}),this.NA({type:T.AdImpression,payload:{}}),this.__.start()})),this.k_.onError.subscribe((t=>{this.NA({type:T.AdError,payload:{errorMessage:t}}),this.__.stop()}))),this.k_.initializeAd(this.wA,this.x_)}catch(t){this.NA({type:T.AdError,payload:{errorMessage:k.AdaptorStartAdError+`_${t.exception}`}})}}stopAd(t){try{super.stopAd(t),this.__.stop(),this.NA({type:T.AdStopped,payload:{shouldTrackPostBid:!0}})}catch(t){this.w_("AdxBidAdaptor","stopAd",t)}}resizeAd(t,i,e){this.x_&&(this.x_.width=t,this.x_.height=i)}pauseAd(){try{this.__.stop(),this.NA({type:T.AdPaused})}catch(t){this.w_("AdxBidAdaptor","pauseAd",t)}}resumeAd(){try{this.__.start(),this.NA({type:T.AdPlaying})}catch(t){this.w_("AdxBidAdaptor","resumeAd",t)}}expandAd(){}collapseAd(){}skipAd(){try{super.skipAd(),this.NA({type:T.AdSkipped})}catch(t){this.w_("AdxBidAdaptor","skipAd",t)}}getAdRemainingTime(){return this.__.timeRemaining/Lt.s_}getAdDuration(){return this.__.timerDuration/Lt.s_}getAdVolume(){return 0}getAdMediaSize(){return{width:this.k_.getAdMediaWidth(),height:this.k_.getAdMediaHeight()}}setAdVolume(t){}get adVideoUrl(){return this.S_}get declaredDurationInSeconds(){return this.settings.adManagerLineItem.protoLineItem.duration}T_(){const t=(0,h.pE)(window).topFrame;if(t.googletag)return Promise.resolve(t.googletag);{const i={cmd:[]};return t.googletag=window.googletag||i,new Promise(((i,e)=>{(0,u.dZ)({src:fn.x},t.document.head,t,(()=>{i(t.googletag)}),(()=>{e()}))}))}}Wg(){var t;try{super.Wg(),this.__.stop(),(0,it.i)(this.A_),null===(t=this.k_)||void 0===t||t.destroy()}catch(t){this.w_("AdxBidAdaptor","_destroy",t)}}}const gn="nonLinearCloseClick",vn=["ddb2f21f-97a6-4efe-b8d3-29187a109f26","6faf989f-40de-4754-ac8e-359574e4b357","a28964ae-afa3-45d3-9f00-fa228cf89d74","5ee7c0e2-db41-417d-a2f2-4d91037b85bd","885d6a6e-3989-4b92-b39d-f27bf95585f6","fb24d42c-879a-4d98-8bc6-037f99e971ed","17db3dde-36f2-4c05-9e37-0c6d6cd2d2b8","3ebdd57e-b5b8-4fd8-8887-6ae94a978a12","4b724681-b6ed-4206-af76-91558dd7ae97","6aef9fe6-a3f3-48a0-ae28-b068a96f45e1","90857b8e-560f-42c0-b0d1-5c4527da610c","14f5a754-5e79-42ff-a5a3-0cbe2300f428","8b29f95e-7663-4825-97c5-85e4b427df2a","3de724ff-efea-4f24-b1a4-5520a0530ee1","fe9242a7-7f5a-40f0-84ad-0d1cb921dbbe","b51de0ac-a3f1-4618-89dc-89111ff5ec62","11d8c7dd-ba90-4bae-9148-e32a7b2fecef","a35dcb98-5f9a-472e-98bf-8fe48d66c86d","5863ca7a-9fea-40e4-a207-0f1e82d07ed7","c8916590-a8b2-4c1c-9616-e251f70bb88b","0ab96a0d-2794-4727-81e7-ca9b1935de68","1bc398f8-c04c-4d33-89c8-af4932b4365c","de0d3790-6d2f-4de3-a99f-c57e4ff48315","fa930c65-1cfa-492a-b774-c32f657d05c3","be8b2598-a065-4d14-8865-4e077b92c65c","98abb9bd-c4dd-413a-bfaf-f79615250a5a","9a4005b0-473d-40be-81d0-ff5d4739b27c","41524015-c77a-4aad-88c8-327e8a55118d","07b3f552-8cd1-4af6-845c-bbc9956d1565","8cd4291c-d6fb-407f-adee-22547cf3d545","66ef0899-eaf6-4bd7-8993-e4d17d730dad","e8ee883f-4058-454c-b198-ebe07884fd42","08d77337-01a3-6602-77df-0366fd684428","dea7fe60-f902-42d0-9aca-9732e064e44e","442ef13a-dec7-4c67-858e-8ae8112c2818","e25ff406-83a4-480f-9632-d687a8f060b9","24a0faa2-a178-41f9-a37b-22c8f01cb26b","75b73df5-e303-47f8-8383-4093b1aef937","0acc1292-75a0-4578-8110-a5de236c4676","ca99043c-edc0-4451-adf3-a6803de76c8e","79669999-34e8-4b9e-aa03-320a318ebf31","a475e8a0-9824-4027-b35f-3d039902afe5"];var yn;!function(t){t.Html="text/html",t.Javascript="application/javascript"}(yn||(yn={}));const bn=`\n            <div class=${P.p0.CloseButton} role='button' aria-label='Close ad' tabindex='0'>\n                <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 73 18"><path d="M32.266 8.293c-.105.902-.439 1.6-1.002 2.092s-1.303.732-2.233.732c-1.008 0-1.816-.361-2.426-1.084s-.908-1.689-.908-2.9v-.82c0-.793.141-1.49.422-2.092s.688-1.062 1.207-1.383 1.121-.486 1.805-.486c.906 0 1.633.254 2.18.762s.865 1.203.955 2.098h-1.131c-.098-.68-.311-1.172-.639-1.477s-.779-.457-1.365-.457c-.719 0-1.283.266-1.693.797s-.609 1.287-.609 2.268v.826c0 .926.193 1.662.58 2.209s.928.82 1.623.82c.625 0 1.104-.141 1.436-.422s.559-.779.668-1.482h1.131zM34.815 11h-1.084V2h1.084v9zm1.453-3.229c0-.621.121-1.18.363-1.676s.586-.879 1.02-1.148a2.79 2.79 0 0 1 1.494-.404c.863 0 1.561.299 2.092.897s.803 1.393.803 2.385V7.9c0 .617-.119 1.172-.357 1.664a2.67 2.67 0 0 1-1.014 1.143c-.437.273-.941.41-1.512.41-.859 0-1.557-.299-2.092-.896s-.797-1.389-.797-2.373v-.076zm1.09.129c0 .703.162 1.268.486 1.693a1.57 1.57 0 0 0 1.312.639c.551 0 .988-.215 1.313-.645s.486-1.039.486-1.816c0-.695-.166-1.258-.498-1.687a1.56 1.56 0 0 0-1.312-.65c-.535 0-.967.213-1.295.639s-.492 1.035-.492 1.828zm9.732 1.418c0-.293-.111-.52-.334-.68s-.604-.305-1.154-.422-.982-.258-1.307-.422-.559-.359-.715-.586-.229-.496-.229-.809c0-.52.219-.959.656-1.318s1.004-.539 1.688-.539c.719 0 1.301.186 1.746.557s.674.846.674 1.424h-1.09c0-.297-.127-.553-.381-.768s-.566-.322-.949-.322c-.395 0-.703.086-.926.258a.81.81 0 0 0-.334.674c0 .262.104.459.311.592s.58.26 1.119.381.983.266 1.318.434.584.371.744.609a1.5 1.5 0 0 1 .246.861 1.63 1.63 0 0 1-.68 1.365c-.453.34-1.041.51-1.764.51-.508 0-.957-.09-1.348-.27s-.697-.43-.92-.75a1.84 1.84 0 0 1-.328-1.049h1.084c.02.363.164.652.433.867s.633.316 1.078.316c.41 0 .738-.082.984-.246a.77.77 0 0 0 .375-.668zm5.127 1.799c-.859 0-1.559-.281-2.098-.844s-.809-1.322-.809-2.267v-.199c0-.629.119-1.189.358-1.682s.578-.883 1.008-1.16a2.56 2.56 0 0 1 1.406-.422c.824 0 1.465.271 1.922.814s.686 1.32.686 2.332v.451h-4.295c.016.625.197 1.131.545 1.518s.797.574 1.336.574c.383 0 .707-.078.973-.234a2.44 2.44 0 0 0 .697-.621l.662.516c-.531.816-1.328 1.225-2.391 1.225zm-.135-5.684a1.44 1.44 0 0 0-1.102.481c-.297.316-.48.762-.551 1.336h3.176v-.082c-.031-.551-.18-.977-.445-1.277s-.625-.457-1.078-.457zM62.84 11c-.062-.125-.113-.348-.152-.668-.504.523-1.105.785-1.805.785-.625 0-1.139-.176-1.541-.527a1.71 1.71 0 0 1-.598-1.348c0-.66.25-1.172.75-1.535s1.211-.551 2.121-.551h1.055v-.498c0-.379-.113-.68-.34-.902s-.561-.34-1.002-.34c-.387 0-.711.098-.973.293s-.393.432-.393.709h-1.09c0-.316.111-.621.334-.914s.531-.531.914-.703.811-.258 1.272-.258c.73 0 1.303.184 1.717.551s.629.865.645 1.506v2.918c0 .582.074 1.045.223 1.389V11H62.84zm-1.799-.826c.34 0 .662-.088.967-.264s.525-.404.662-.686v-1.3h-.85c-1.328 0-1.992.389-1.992 1.166 0 .34.113.605.34.797s.517.287.873.287zm4.148-2.396c0-.973.23-1.754.691-2.344a2.18 2.18 0 0 1 1.811-.891c.742 0 1.33.254 1.764.762V2h1.084v9h-.996l-.053-.68c-.434.531-1.037.797-1.811.797a2.17 2.17 0 0 1-1.799-.902c-.461-.601-.691-1.387-.691-2.355v-.082zm1.084.123c0 .719.148 1.281.445 1.687s.707.609 1.23.609c.688 0 1.189-.309 1.506-.926V6.359a1.59 1.59 0 0 0-1.494-.896c-.531 0-.945.205-1.242.615s-.445 1.018-.445 1.822zM16 1.41L14.59 0 9 5.59 3.41 0 2 1.41 7.59 7 2 12.59 3.41 14 9 8.41 14.59 14 16 12.59 10.41 7 16 1.41z"/></svg>\n            </div>`.trim();class In{constructor(t,i,e,s,n,r,o,h){this.C_=t,this.E_=i,this.M_=e,this.wA=s,this.yn=n,this.Zp=r,this.B_=o,this.R_=h,this.rA="div-cnx-display",this.oA=new J.x,this.O_=new J.x,this.hA=new J.x,this.D_=new J.x,this.V_=t=>{this.O_.next()},this.F_=t=>{this.D_.next()}}get onDisplayAd(){return this.oA.asObservable()}get onError(){return this.hA.asObservable()}get onClickClose(){return this.O_.asObservable()}get onClickAd(){return this.D_.asObservable()}createBanner(t){this.Kw=new At(this.yn,this.Zp),this.N_=t?this.j_(this.wA,t):this.wA;let i="";this.M_===yn.Html&&(i=this.E_);let e="",s="";switch(this.C_){case v.ProtoAdType.Overlay:e=`#${this.rA}{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%)}`,s=`#${this.rA}{border:3px solid white}`;break;case v.ProtoAdType.Nonlinear:e=`#${this.rA}{width: 100%; height: 100%}`}const n="<style>html, body {position:relative;width:100%;height:100%}"+e+s+"#"+this.rA+" iframe{display:block}</style>";this.Kw.loadIframe({customHead:n,customHtml:'<div id="'+this.rA+'">'+i+"</div>",container:this.N_,customReportingLog:{heavyAdBlockTypeEnum:v.ProtoHeavyAdBlockTypeEnum.OverlayIframe,advertiserLineItemId:this.B_},iframePosition:this.C_===v.ProtoAdType.Nonlinear?wt.relative:wt.absolute,iframeCustomDimensions:this.R_?this.R_:void 0,iframePointerEvents:St.all,title:js.$b}).then((t=>{this.U_=t.iframe;const i=this.U_.contentWindow;if(this.q_=i.document.getElementById(this.rA),this.M_===yn.Javascript&&(0,u.ML)(this.q_,i,this.E_),""===this.U_.contentWindow.document.head.innerHTML){const t=n;this.H_(t)}(0,u.AX)(this.U_.contentWindow,"AdHtmlWrapper"),this.C_===v.ProtoAdType.Nonlinear&&this.z_(),this.oA.next()})).catch((t=>{this.hA.next()}))}getAdMediaDimensions(){return{width:this.q_.clientWidth||this.U_.contentWindow.document.body.clientWidth,height:this.q_.clientHeight||this.U_.contentWindow.document.body.clientHeight}}destroy(){var t;null===(t=this.q_)||void 0===t||t.removeEventListener("click",this.F_),this.W_&&(this.W_.removeEventListener("click",this.V_),this.N_.removeChild(this.W_)),this.U_&&this.wA&&(0,u.bX)(this.U_),this.Kw&&(this.Kw.destroy(),this.Kw=null)}z_(){var t;this.W_=this.yn.createElementByString(bn),this.N_.appendChild(this.W_),this.W_.addEventListener("click",this.V_),null===(t=this.q_)||void 0===t||t.addEventListener("click",this.F_)}H_(t){const i=this.U_.contentWindow.document.createElement("style"),e=this.U_.contentWindow.document.createTextNode(t);i.appendChild(e),this.U_.contentWindow.document.head.appendChild(i)}j_(t,i){if(!i.width||!i.height)return t;let e,s;if(this.C_===v.ProtoAdType.Nonlinear)e=s="100%";else e=i.width+"px",s=i.height+"px";const n=this.yn.createElementByString(`<div class="cnx-iframe-container" style="width: ${e}; height: ${s}"></div>`);return t.appendChild(n),n}}class wn{constructor(t,i,e,s,n,r,o){this.X_=t,this.Q_=i,this.B_=e,this.yn=s,this.Zp=n,this.C_=r,this.J_=o,this.oA=new J.x,this.O_=new J.x,this.hA=new J.x,this.Fc=[]}get onDisplayAd(){return this.oA.asObservable()}get onError(){return this.hA.asObservable()}get onClickClose(){return this.O_.asObservable()}initializeAd(t,i){try{let e;if(this.C_===v.ProtoAdType.Nonlinear){const{width:t,height:i}=this.J_;e={width:t,height:i}}this.Y_=new In(this.C_,this.Q_,this.X_,t,this.yn,this.Zp,this.B_,e),this.Fc.push(this.Y_.onDisplayAd.subscribe((()=>{this.oA.next()})),this.Y_.onError.subscribe((()=>{this.hA.next(k.DisplayIntegratorIframeLoad)})),this.Y_.onClickClose.subscribe((()=>{this.O_.next()}))),this.Y_.createBanner(i)}catch(t){this.hA.next(k.WrapperInitAdError)}}getAdMediaDimensions(){var t;return null===(t=this.Y_)||void 0===t?void 0:t.getAdMediaDimensions()}destroy(){var t;(0,it.i)(this.Fc),null===(t=this.Y_)||void 0===t||t.destroy()}}const Sn={[nn.n.FirstQuartile]:T.AdVideoFirstQuartile,[nn.n.SecondQuartile]:T.AdVideoMidpoint,[nn.n.ThirdQuartile]:T.AdVideoThirdQuartile,[nn.n.FourthQuartile]:T.AdVideoComplete};class Pn extends pn{constructor(t,i){var e;let s;super(t,i),this.Ws=t,this.settings=i,this.adSourceType=v.ProtoAdsourceTypeEnum.Unknown,this.Gs=500,this.K_=[],this.settings.adManagerLineItem.protoLineItem.adType===v.ProtoAdType.Nonlinear?(this.adMediaType="displayHtmlNonLinear",this.S_="htmlNonLinear",s=null===(e=this.settings.adManagerLineItem.protoLineItem.nonlinearLineItemSettings)||void 0===e?void 0:e.nonLinearAdTimeSeconds):(this.adMediaType="displayHtml",this.S_="html",s=this.settings.adManagerLineItem.protoLineItem.overlayTime);const n=s*Lt.s_;this.__=new Ks.B(this.Ws,n,this.Gs),this.K_.push(this.__.onTimeUpdate.subscribe((()=>{this.NA({type:T.AdRemainingTimeChange})})),this.__.onTimeElapsed.subscribe((()=>{this.stopAd("htmlTimerElapsed")})),this.__.onQuartile.subscribe((t=>{this.NA({type:Sn[t],payload:{}})})))}get adVideoUrl(){return this.S_}get declaredDurationInSeconds(){return this.settings.adManagerLineItem.protoLineItem.overlayTime}initAd(t,i,e,s,n,r,o){try{super.initAd(t,i,e,s,n,r,o),this.Dv=t,this.Vv=i,this.NA({type:T.AdLoaded,payload:{}})}catch(t){this.NA({type:T.AdError,payload:{errorMessage:k.AdaptorInitAdError+`_${t.message}`}})}}startAd(){try{super.startAd(),this.__.start(),this.Z_=new wn(this.settings.mime,this.settings.html,this.settings.adManagerLineItem.protoLineItem.advertiserLineItemId,this.settings.globalDomUtilsService,this.settings.sessionId,this.settings.adManagerLineItem.protoLineItem.adType,this.settings.dimensions),this.K_.push(this.Z_.onDisplayAd.subscribe((()=>{this.NA({type:T.AdStarted}),this.NA({type:T.AdVideoStart}),this.NA({type:T.AdImpression,payload:{}})})),this.Z_.onError.subscribe((t=>{this.NA({type:T.AdError,payload:{errorMessage:t}}),this.__.stop()})),this.Z_.onClickClose.subscribe((()=>{this.NA({type:T.AdUserClose,payload:{}}),this.stopAd(gn)}))),this.Z_.initializeAd(this.wA,{width:this.Dv,height:this.Vv})}catch(t){this.NA({type:T.AdError,payload:{errorMessage:k.AdaptorStartAdError+`_${t.message}`}})}}stopAd(t){try{super.stopAd(t),this.__.stop(),this.NA({type:T.AdStopped,payload:{shouldTrackPostBid:!0}})}catch(t){this.w_("HtmlBidAdaptor","stopAd",t)}}skipAd(){try{super.skipAd(),this.NA({type:T.AdSkipped})}catch(t){this.w_("HtmlBidAdaptor","skipAd",t)}}pauseAd(){try{this.__.stop(),this.NA({type:T.AdPaused})}catch(t){this.w_("HtmlBidAdaptor","pauseAd",t)}}resumeAd(){try{this.__.start(),this.NA({type:T.AdPlaying})}catch(t){this.w_("HtmlBidAdaptor","resumeAd",t)}}collapseAd(){}expandAd(){}getAdDuration(){return this.__.timerDuration/Lt.s_}getAdRemainingTime(){return this.__.timeRemaining/Lt.s_}getAdVolume(){return 0}getAdMediaSize(){var t;return null===(t=this.Z_)||void 0===t?void 0:t.getAdMediaDimensions()}setAdVolume(t){}resizeAd(t,i,e){this.Dv=t,this.Vv=i}Wg(){var t;try{super.Wg(),this.__.stop(),(0,it.i)(this.K_),null===(t=this.Z_)||void 0===t||t.destroy()}catch(t){this.w_("HtmlBidAdaptor","_destroy",t)}}}var An;!function(t){t.BANNED_IMA_ADS_ID=["9026814","9053547"],t.KEYWORDS_FOR_BANNED_VAST=[]}(An||(An={}));var _n=r(3326);class xn extends rn{constructor(t,i,e,s,n,r,o,h){super(),this.tx=t,this.gi=i,this.sx=e,this.nx=s,this.ox=n,this.hx=r,this.lx=o,this.Zp=h,this.aA=new J.x,this.ux=!1,this.mx=t=>{if(!this.vx(t))return;let i="";try{i=t.getError().getMessage()+"_"+t.getError().getErrorCode()+"_"+t.getError().getVastErrorCode()}catch(t){}this.wI.next({type:T.AdError,payload:{errorMessage:k.ImaError+"_"+i}})},this.yx=t=>{const i=this.tx.AdEvent.Type;switch(t.type){case i.CLICK:this.wI.next({type:T.AdClickThru,payload:{}});break;case i.LOADED:this.Ap(t);break;case i.IMPRESSION:const e={adsManager:this.ox,adContainer:this.Ix,viewMode:this.wx(this.Sx),adTag:this.nx};this.wI.next({type:T.AdVideoStart}),this.wI.next({type:T.AdImpression,payload:{imaMetadata:e}});break;case i.STARTED:this.wI.next({type:T.AdStarted});break;case i.FIRST_QUARTILE:this.wI.next({type:T.AdVideoFirstQuartile});break;case i.MIDPOINT:this.wI.next({type:T.AdVideoMidpoint});break;case i.THIRD_QUARTILE:this.wI.next({type:T.AdVideoThirdQuartile});break;case i.COMPLETE:this.wI.next({type:T.AdVideoComplete}),this.wI.next({type:T.AdStopped,payload:{shouldTrackPostBid:!0}});break;case i.ALL_ADS_COMPLETED:break;case i.DURATION_CHANGE:this.wI.next({type:T.AdDurationChange});break;case i.PAUSED:this.wI.next({type:T.AdPaused});break;case i.RESUMED:this.wI.next({type:T.AdPlaying});break;case i.LINEAR_CHANGED:this.wI.next({type:T.AdLinearChange});break;case i.SKIPPABLE_STATE_CHANGED:this.wI.next({type:T.AdSkippableStateChange});break;case i.SKIPPED:this.wI.next({type:T.AdSkipped});break;case i.VOLUME_CHANGED:this.wI.next({type:T.AdVolumeChange});break;case i.USER_CLOSE:this.wI.next({type:T.AdUserClose});break;case i.LOG:this.wI.next({type:T.AdLog})}},this.YA=L.h.getSessionChildContainer(this.Zp).resolve(Qs.P),this.Ax()}get onCreativeReceived(){return this.aA.asObservable()}initAd(t,i,e,s,n,r){this.Ix=r.slot,this._x=r.videoSlot,this.Sx=e||x.Normal;try{this.YA.isImaTestCaseForSS()||this.YA.isLegacyDotComDomain()||this.ox.setVolume(0),this.ox.init(t,i,this.wx(this.Sx))}catch(t){this.wI.next({type:T.AdError,payload:{errorMessage:k.ImaManagerInit}})}}startAd(){try{this.ox.start()}catch(t){this.wI.next({type:T.AdError,payload:{errorMessage:k.WrapperStartAdError+`_${t.message}`}})}}stopAd(t){this.ox.stop(),this.wI.next({type:T.AdStopped,payload:{shouldTrackPostBid:!0}})}resizeAd(t,i,e){this.ox.resize(t,i,this.wx(e))}pauseAd(){this.ox.pause()}resumeAd(){this.ox.resume(),this.gi===zt.M.Ios&&(0,u.UR)(this._x)}expandAd(){this.ox.expand()}collapseAd(){this.ox.collapse()}skipAd(){this.ox.skip()}getAdRemainingTime(){return this.ox.getRemainingTime()||0}getAdDuration(){return this.xx?this.xx.getDuration():0}getAdVolume(){return this.YA.isImaTestCaseForSS()||this.YA.isLegacyDotComDomain()?this.YA.adManagerSound:this.ox.getVolume()}getAdMediaWidth(){return this.xx?this.xx.getVastMediaWidth():0}getAdMediaHeight(){return this.xx?this.xx.getVastMediaHeight():0}setAdVolume(t){(!this.YA.isImaTestCaseForSS()&&!this.YA.isLegacyDotComDomain()||t!==this.YA.adManagerSound||!this.ux&&0!==t)&&(this.ux=!0,this.ox.setVolume(t))}getMediaFile(){return this.xx?this.xx.getMediaUrl():void 0}Ax(){this.sx.addEventListener(this.tx.AdErrorEvent.Type.AD_ERROR,this.mx),this.ox.addEventListener(this.tx.AdErrorEvent.Type.AD_ERROR,this.mx),Object.keys(this.tx.AdEvent.Type).forEach((t=>{this.ox.addEventListener(this.tx.AdEvent.Type[t],this.yx,!1)}))}Tx(){this.sx.removeEventListener(this.tx.AdErrorEvent.Type.AD_ERROR,this.mx),this.ox.removeEventListener(this.tx.AdErrorEvent.Type.AD_ERROR,this.mx),Object.keys(this.tx.AdEvent.Type).forEach((t=>{this.ox.removeEventListener(this.tx.AdEvent.Type[t],this.yx,!1)}))}wx(t){return t===x.Fullscreen?this.tx.ViewMode.FULLSCREEN:this.tx.ViewMode.NORMAL}kx(t){return An.BANNED_IMA_ADS_ID.some((i=>i===t))}vx(t){const i=t.getUserRequestContext();return!i||i.id===this.hx.id}Ap(t){if(this.xx=t.getAd(),this.kx(this.xx.getAdId()))return void this.wI.next({type:T.AdError,payload:{errorMessage:k.VpaidInvalid}});this.aA.next(this.xx.getCreativeId());let i=-1,e="";try{i=this.xx.getSkipTimeOffset();const n=t.getAdData().clickThroughUrl;e=(0,s.QM)(n)?n:void 0}catch(t){}(0,_n.A)(this.lx,e).then((t=>{t?this.wI.next({type:T.AdError,payload:{errorMessage:k.DomainBlocked}}):this.wI.next({type:T.AdLoaded,payload:{skipOffset:i}})}))}destroy(){try{this.Tx(),setTimeout((()=>{this.ox.destroy()}))}catch(t){}}}const Tn={ImaObjectNotFound:k.ImaObjectNotFound,ImaScriptFailure:k.ImaScriptFailure},kn="//imasdk.googleapis.com/js/sdkloader/ima3.js";class Cn{static preloadImaSdk(t){(0,u._w)(kn,t)}static fetchImaSdk(t,i){return new Promise(((e,s)=>{const n=Cn.Cx(t);if(n)return void e(n);const r=i&&1===(0,h.Vm)([99,1]);(0,u.dZ)({src:kn},t.document.head,t,(()=>{const i=Cn.Cx(t);i?e(i):(r&&(0,p.n)({message:"AdManager_ImaIntegrator_no_image_object_found_after_loading_script",level:p.D.CRITICAL},{throttle:2,shouldSendMaxLog:!1}),s(Tn.ImaObjectNotFound))}),(()=>{s(Tn.ImaScriptFailure)}),r,"AdManager_ImaIntegrator_unable_to_insert_ima_sdk_script")}))}static Cx(t){return t.google&&t.google.ima}}class En extends pn{constructor(t,i){super(t,i),this.Ws=t,this.settings=i,this.AA=null,this.adMediaType="ima",this.adSourceType=v.ProtoAdsourceTypeEnum.Ima,this.Ex=[],this.AA=this.settings.imaAdSlotContainer,this.Mx=new xn(this.settings.imaSdk,this.settings.os,this.settings.imaAdsLoader,this.settings.url,this.settings.imaAdsManager,this.settings.requestAdsContext,this.settings.adManagerLineItem.protoLineItem.publisherLineItemId,this.settings.sessionId)}initAd(t,i,e,s,n,r,o){try{super.initAd(t,i,e,s,n,r,o),this.settings.adManagerLineItem.protoLineItem.moatTrackingEnabled&&this.Lx(),this.Ex.push(this.Mx.onVpaidEvent.subscribe((t=>{this.NA(t)})),this.Mx.onCreativeReceived.subscribe((t=>{this.creativeId=t}))),this.Mx.initAd(t,i,e,s,n,{slot:this.wA,videoSlot:this.SA})}catch(t){this.NA({type:T.AdError,payload:{errorMessage:k.AdaptorInitAdError+`_${t.message}`}})}}startAd(){try{super.startAd(),this.Mx.startAd()}catch(t){this.NA({type:T.AdError,payload:{errorMessage:k.AdaptorStartAdError+`_${t.message}`}})}}stopAd(t){try{super.stopAd(t),this.Mx.stopAd(t)}catch(t){this.w_("ImaBidAdaptor","stopAd",t)}}resizeAd(t,i,e){try{this.Mx.resizeAd(t,i,e)}catch(t){this.w_("ImaBidAdaptor","resizeAd",t)}}pauseAd(){try{this.Mx.pauseAd()}catch(t){this.w_("ImaBidAdaptor","pauseAd",t)}}resumeAd(){try{this.Mx.resumeAd()}catch(t){this.w_("ImaBidAdaptor","resumeAd",t)}}expandAd(){try{this.Mx.expandAd()}catch(t){this.w_("ImaBidAdaptor","expandAd",t)}}collapseAd(){try{this.Mx.collapseAd()}catch(t){this.w_("ImaBidAdaptor","collapseAd",t)}}skipAd(){try{super.skipAd(),this.Mx.skipAd()}catch(t){this.w_("ImaBidAdaptor","skipAd",t)}}getAdRemainingTime(){try{return this.Mx.getAdRemainingTime()}catch(t){return this.w_("ImaBidAdaptor","getAdRemainingTime",t),0}}getAdDuration(){try{return this.Mx&&this.Mx.getAdDuration()||this.settings.adManagerLineItem.protoLineItem.duration}catch(t){return this.w_("ImaBidAdaptor","getAdDuration",t),0}}getAdVolume(){try{return this.Mx.getAdVolume()}catch(t){return this.w_("ImaBidAdaptor","getAdVolume",t),0}}getAdMediaSize(){return{width:this.Mx.getAdMediaWidth(),height:this.Mx.getAdMediaHeight()}}setAdVolume(t){try{super.setAdVolume(t),this.Mx.setAdVolume(t)}catch(t){this.w_("ImaBidAdaptor","setAdVolume",t)}}get adVideoUrl(){return this.Mx.getMediaFile()}get declaredDurationInSeconds(){return this.Mx.getAdDuration()}u_(t){const i=super.u_(t);return i.payload.adSourceData.imaMetadata=t.payload.imaMetadata,i}y_(){return this.AA}I_(){this.settings.adSlotContainerRecycler.recycleAdSlot(this.AA)}Lx(){Cn.fetchImaSdk(this.settings.globalDomUtilsService.getGlobalClosestTop().topFrame,!1)}Wg(){try{super.Wg(),(0,it.i)(this.Ex),this.Mx.destroy()}catch(t){this.w_("ImaBidAdaptor","_destroy",t)}}}function Mn(t,i,e){const s=`cnx-async-bundle-${(0,h.dz)()}`,n={id:s,src:t};return new Promise(((t,o)=>{(0,u.dZ)(n,e.document.head,e,(()=>{try{i.cnx_webpack_global&&(0,S.BZ)(e.cnx_webpack_global)&&e.cnx_webpack_global.forEach((t=>{i.cnx_webpack_global.push(t)}))}catch(t){o(t)}t(),(0,u.uC)(s,e.document)}),(()=>{(0,u.uC)(s,r.g.document),o(new Error("script load error"))}),!1)}))}var Ln=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};const Bn={enableWorker:!0,capLevelToPlayerSize:!0,maxBufferSize:5e6,maxBufferLength:5,maxMaxBufferLength:10,liveBackBufferLength:90,backBufferLength:1/0,lowLatencyMode:!0,ignoreDevicePixelRatio:!0,debug:"true"===(0,a.Ph)("cnxHlsDebug",(0,h.pE)(window).topFrame.location.href)};function Rn(t){var i;return Ln(this,void 0,void 0,(function*(){const e=function(t){return`${c(t)}/a/`}(f);if(yield Mn(`${e}hls.1.3.4.js`,window,t),!(null===(i=t.cnxAsyncChunks)||void 0===i?void 0:i.Hls))throw new Error("hls bundle not found");return t.cnxAsyncChunks.Hls}))}function On(t){return Ln(this,void 0,void 0,(function*(){try{const i=yield(0,h.Up)((()=>Ln(this,void 0,void 0,(function*(){return yield Rn(t)}))));if(!i)throw new Error("no_hls_module");return i}catch(t){return(0,p.n)({callStack:t.stack,exception:t.message,level:p.D.WARN,message:"HLS_dynamicImport"}),null}}))}function Dn(){const t=self.MediaSource||self.WebKitMediaSource;if(!t)return!1;const i=self.SourceBuffer||self.WebKitSourceBuffer,e="function"==typeof t.isTypeSupported&&t.isTypeSupported('video/mp4; codecs="avc1.42E01E,mp4a.40.2"'),s=!i||i.prototype&&"function"==typeof i.prototype.appendBuffer&&"function"==typeof i.prototype.remove;return!!e&&!!s}class Vn{constructor(t,i,e,s){this.Bx=t,this.Rx=i,this.Ox=e,this.Fx=s,this.Nx=[],this.jx=(t,i)=>{if(i.fatal)switch(i.type){case this.Bx.ErrorTypes.NETWORK_ERROR:if(i.details===this.Bx.ErrorDetails.MANIFEST_PARSING_ERROR||i.details===this.Bx.ErrorDetails.MANIFEST_LOAD_ERROR)return void this.$x();this.Ux.startLoad();break;case this.Bx.ErrorTypes.MEDIA_ERROR:this.Ux.recoverMediaError();break;default:this.$x()}},this.qx=()=>{this.Ux.off(this.Bx.Events.MEDIA_ATTACHED,this.qx),this.Ux.loadSource(this.Rx),this.Ux.once(this.Bx.Events.MANIFEST_PARSED,this.Hx)},this.Hx=()=>{this.Ux.off(this.Bx.Events.MANIFEST_PARSED,this.Hx),this.zx(),this.Fx.forceMaxLevel&&this.Wx(),this.Fx.forceResolutionHeight&&this.Gx(this.Fx.forceResolutionHeight),this.Xx()},(this.Fx.forceMaxLevel||this.Fx.forceResolutionHeight)&&(Bn.capLevelToPlayerSize=!1)}start(t,i){this.Xx=t,this.$x=i,this.Bx&&Dn()?(this.Ux=new this.Bx(Object.assign({},Bn)),this.Qx()):this.$x()}destroy(){this.Ux&&(this.Ux.destroy(),this.Ux=null)}Qx(){this.Ux.on(this.Bx.Events.ERROR,this.jx),this.Ux.attachMedia(this.Ox),this.Ux.once(this.Bx.Events.MEDIA_ATTACHED,this.qx)}Wx(){const t=this.Ux.levels.length-1;this.Jx(t)}Gx(t){const i=this.Nx.find((i=>i.height===t));i&&this.Jx(i.level)}Jx(t){this.Ux.currentLevel=t,this.Ux.startLevel=t,this.Ux.nextLevel=t}zx(){this.Ux.levels.forEach(((t,i)=>{this.Nx.push({level:i,height:t.height})}))}}var Fn=r(5292);const Nn="huffpost",jn=540,$n=["d426a992-f367-434b-827b-d3561b6af50c","e3bcb71c-7486-4955-a5fe-c94bade4948d"];class Un extends rn{constructor(t,i,e,s,n,r,o,h,a,c,d=!1,l){super(),this.yn=t,this.Yx=i,this._x=e,this.gi=s,this.B_=n,this.Kx=r,this.Zx=o,this.tT=h,this.iT=a,this.Bx=c,this.eT=d,this.Ii=l,this.sT=!1,this.pageFocus=new Fn.v(this.yn),this.nT=Object.values(jt.wB),this.rT=!1,this.oT=!1,this.hT=!0,this.aT=!1,this.cT=[{event:T.AdVideoStart,position:0},{event:T.AdVideoFirstQuartile,position:25},{event:T.AdVideoMidpoint,position:50},{event:T.AdVideoThirdQuartile,position:75},{event:T.AdVideoComplete,position:100}],this.dT=this.cT[0],this.lT=t=>{try{switch(t.type){case jt.wB.Pause:if(this.Zx&&!this.hT)return this.hT=!0,void this.uT("pause_event_loopAd");this.oT=!1;break;case jt.wB.Play:if(!this.oT&&this.eT)return void this._x.pause();break;case jt.wB.Canplay:case jt.wB.Durationchange:this.fT();break;case jt.wB.Timeupdate:this.mT();break;case jt.wB.Error:const t=this._x.networkState===HTMLMediaElement.NETWORK_NO_SOURCE?Te.MediaFileNotFound:Te.GeneralLinearError;this.wI.next({type:T.AdError,payload:{errorCode:t,errorMessage:k.VastVideoTagEventError}});break;case"click":this.wI.next({type:T.AdClickThru,payload:{}})}}catch(t){(0,p.n)({level:p.D.CRITICAL,callStack:t.stack,message:"AdManager_VastIntegrator_onVideoEvent",exception:t.message},{throttle:10,shouldSendMaxLog:!1})}}}initAd(t,i,e,s,n,r){try{this._x=r.videoSlot,this.width=t,this.height=i,this.gT(this.Kx,this._x.parentElement),this.resizeAd(t,i,e),this.addVideoEvents(this._x),this.iT&&Dn()?this.vT(this.Bx):(this._x.setAttribute("src",this.Yx),this._x.setAttribute("preload","metadata"),this._x.load()),this.pageFocus.isDocumentVisible()||this.fT()}catch(t){this.wI.next({type:T.AdError,payload:{errorMessage:k.WrapperInitAdError+`_${t.message}`}})}}yT(t){if(this.rT){const i=t?"INMOBI_IMPRESSION_EVENT_DOCUMENT_VISIBLE":"INMOBI_IMPRESSION_EVENT_DOCUMENT_NOT_VISIBLE";(0,p.n)({level:p.D.INFO,exception:`advLineItemId: ${this.B_}`,message:i},{throttle:1e3})}}startAd(){try{(0,u.cn)(this._x,"cnx-ad-video-slot"),this.oT=!0,this.B_&&$n.includes(this.B_)&&(this.rT=!0),this.pageFocus.isDocumentVisible()?this._x.play().then((()=>{this.wI.next({type:T.AdStarted}),this.bT(),this.yT(!0)})).catch((t=>{this.wI.next({type:T.AdError,payload:{errorMessage:k.VastPlayPromiseReject}}),this.rT&&(0,p.n)({level:p.D.INFO,message:"INMOBI_DOCUMENT_VISIBLE_REJECTED_PLAY_EVENT",exception:`advLineItemId: ${this.B_}, promiseError: ${t.message}`,callStack:t.stack},{throttle:1e3})})):(this.wI.next({type:T.AdStarted}),this.bT(),this.yT(!1),this._x.play().then((()=>{this.IT(),this.rT&&(0,p.n)({level:p.D.INFO,message:"INMOBI_DOCUMENT_NOT_VISIBLE_RESOLVED_PLAY_EVENT",exception:`advLineItemId: ${this.B_}`},{throttle:1e3})})).catch((t=>{this.rT&&(0,p.n)({level:p.D.INFO,message:"INMOBI_DOCUMENT_NOT_VISIBLE_REJECTED_PLAY_EVENT",exception:`advLineItemId: ${this.B_}, promiseError: ${t.message}`,callStack:t.stack},{throttle:1e3})})))}catch(t){this.wI.next({type:T.AdError,payload:{errorMessage:k.WrapperStartAdError+`_${t.message}`}})}}stopAd(t){this.eT&&this._x.pause(),"videoComplete"===t&&this.Zx?this.wI.next({type:T.AdStopped,payload:{shouldTrackPostBid:!1}}):this.wI.next({type:T.AdStopped,payload:{shouldTrackPostBid:!0}})}resizeAd(t,i,e){(0,u.T7)(this._x,{width:`${t}px`,height:`${i}px`}),this.wI.next({type:T.AdSizeChange})}pauseAd(){this.oT=!1,this.tT&&void 0===this.dT&&(this.dT=this.cT[0]),this._x.pause(),this.wI.next({type:T.AdPaused})}resumeAd(){this.Zx&&void 0===this.dT&&(this.dT=this.cT[0]),this.oT=!0,this.uT("resumeAd"),this.IT(),this.wI.next({type:T.AdPlaying})}expandAd(){}collapseAd(){}skipAd(){this.wI.next({type:T.AdSkipped})}getAdRemainingTime(){return this._x.duration-this._x.currentTime}getAdDuration(){return this._x.duration?this._x.duration:0}getAdVolume(){return this._x.volume}setAdVolume(t){this._x.volume=t}getAdMediaWidth(){return this._x.videoWidth}getAdMediaHeight(){return this._x.videoHeight}destroy(){if(!this.tT&&!this.Zx)try{(0,u.IV)(this._x,"cnx-ad-video-slot"),this.wT(this._x),this._x.removeAttribute("src"),this.ST&&(this.ST.destroy(),this.ST=null)}catch(t){(0,p.n)({level:p.D.WARN,message:"AdManager_VastIntegrator_destroyAd",exception:t.message,callStack:t.stack})}}IT(){this.gi===zt.M.Ios&&(0,u.UR)(this._x)}vT(t){let i={forceMaxLevel:!0};this.Ii&&this.Ii.includes(Nn)&&(i={forceMaxLevel:!1,forceResolutionHeight:jn}),this.ST=new Vn(t,this.Yx,this._x,i),this.ST.start((()=>{this.fT()}),(()=>{this.wI.next({type:T.AdError,payload:{errorMessage:k.CnxMediaSrcNotSupported}})}))}gT(t,i){this.PT=this.yn.createElement("a"),t&&(this.PT.href=t,this.PT.target="_blank"),(0,u.cn)(this.PT,"cnx-ad-slot"),this.PT.setAttribute("title","Advertisement link"),this.PT.setAttribute("role","link"),this.PT.setAttribute("tabindex","-1"),this.PT.setAttribute("aria-disabled","true"),i.appendChild(this.PT),this.PT.addEventListener("click",this.lT)}addVideoEvents(t){this.nT.forEach((i=>{t.addEventListener(i,this.lT)})),this.PT&&this.PT.addEventListener("click",this.lT)}wT(t){this.nT.forEach((i=>{t.removeEventListener(i,this.lT)})),this.PT&&this.PT.removeEventListener("click",this.lT)}fT(){this.sT||(this.sT=!0,this.wI.next({type:T.AdLoaded,payload:{}}))}mT(){this.wI.next({type:T.AdRemainingTimeChange});const t=(0,$i.dQ)(0,this._x.duration,0,100,this._x.currentTime);if(this.dT&&t>=this.dT.position){this.dT.event===T.AdVideoStart&&this.rT&&(0,p.n)({level:p.D.INFO,message:"INMOBI_AD_VIDEO_START_EVENT_FIRED",exception:`advLineItemId: ${this.B_}`},{throttle:1e3}),this.aT||(this.dT.event===T.AdVideoStart&&this.rT?this.wI.next({type:T.AdVideoStart,payload:{logInMobiInfo:this.rT}}):this.wI.next({type:this.dT.event}));const t=this.dT;this.dT=this.cT[this.cT.indexOf(this.dT)+1],t.event===T.AdVideoComplete&&(this.Zx&&(this._x.currentTime=.01),this.hT=!1,this.stopAd("videoComplete"),this.aT=!0)}}uT(t){try{this._x.play().catch((i=>(0,p.n)({level:p.D.WARN,message:`AdManager_VastIntegrator_play_${t}`,exception:`playError: ${i.message}`,callStack:i.stack})))}catch(i){(0,p.n)({level:p.D.WARN,message:`AdManager_VastIntegrator__play_${t}`,exception:`promiseError: ${i.message}`,callStack:i.stack})}}bT(){this.PT&&(this.PT.removeAttribute("tabindex"),this.PT.removeAttribute("aria-disabled")),this.wI.next({type:T.AdImpression,payload:{}})}}class qn extends pn{constructor(t,i){super(t,i),this.Ws=t,this.settings=i,this.adMediaType="cnxMedia",this.adSourceType=v.ProtoAdsourceTypeEnum.CnxMedia,this._T=[]}initAd(t,i,e,n,r,o,h){try{let a;super.initAd(t,i,e,n,r,o,h);let c=!1;if((0,s.QM)(this.settings.externalMediaFile))a=this.xT(this.settings.externalMediaFile);else if((0,s.QM)(this.settings.externalHlsFile))a=this.xT(this.settings.externalHlsFile),c=!0;else{if(!(0,S.BZ)(this.settings.renditions))return void this.NA({type:T.AdError,payload:{errorMessage:k.CnxMediaNoRenditions}});a=this.TT(this.settings.renditions,i,this.settings.mediaId)}this.kT=a,this.CT=new Un(this.settings.globalDomUtilsService,this.kT,this.SA,this.settings.os,this.settings.adManagerLineItem.protoLineItem.advertiserLineItemId,this.settings.clickUrl,this.settings.shouldLoopAdWhenFinished,this.settings.shouldPauseAdWhenFinished,c,this.settings.hlsModule,this.settings.isInApp,this.settings.pageDomain),this._T.push(this.CT.onVpaidEvent.subscribe((t=>{this.NA(t)}))),this.CT.initAd(t,i,e,n,r,{slot:this.wA,videoSlot:this.SA})}catch(t){this.NA({type:T.AdError,payload:{errorMessage:k.AdaptorInitAdError+`_${t.message}`}})}}startAd(){try{super.startAd(),this.CT.startAd()}catch(t){this.NA({type:T.AdError,payload:{errorMessage:k.AdaptorStartAdError+`_${t.message}`}})}}stopAd(t){super.stopAd(t),this.CT?this.CT.stopAd(t):(0,p.n)({message:"stopAd",exception:t,level:p.D.WARN})}resizeAd(t,i,e){try{this.CT.resizeAd(t,i,e)}catch(t){this.w_("CnxMediaBidAdaptor","resizeAd",t)}}pauseAd(){try{this.CT.pauseAd()}catch(t){this.w_("CnxMediaBidAdaptor","pauseAd",t)}}resumeAd(){try{this.CT.resumeAd()}catch(t){this.w_("CnxMediaBidAdaptor","resumeAd",t)}}expandAd(){try{this.CT.expandAd()}catch(t){this.w_("CnxMediaBidAdaptor","expandAd",t)}}collapseAd(){try{this.CT.collapseAd()}catch(t){this.w_("CnxMediaBidAdaptor","collapseAd",t)}}skipAd(){try{super.skipAd(),this.CT.skipAd()}catch(t){this.w_("CnxMediaBidAdaptor","skipAd",t)}}getAdRemainingTime(){try{return this.CT.getAdRemainingTime()}catch(t){return this.w_("CnxMediaBidAdaptor","getAdRemainingTime",t),0}}getAdDuration(){try{return this.CT?this.CT.getAdDuration():this.settings.adManagerLineItem.protoLineItem.duration}catch(t){return this.w_("CnxMediaBidAdaptor","getAdDuration",t),0}}getAdVolume(){try{return this.CT.getAdVolume()}catch(t){return this.w_("CnxMediaBidAdaptor","getAdVolume",t),0}}getAdMediaSize(){return{width:this.CT.getAdMediaWidth(),height:this.CT.getAdMediaHeight()}}setAdVolume(t){try{super.setAdVolume(t),this.CT.setAdVolume(t)}catch(t){this.w_("CnxMediaBidAdaptor","setAdVolume",t)}}get adVideoUrl(){return this.kT}get declaredDurationInSeconds(){return this.settings.adManagerLineItem.protoLineItem.duration}Wg(){var t;if(!this.settings.shouldPauseAdWhenFinished&&!this.settings.shouldLoopAdWhenFinished)try{super.Wg(),(0,it.i)(this._T),null===(t=this.CT)||void 0===t||t.destroy()}catch(t){this.w_("CnxMediaBidAdaptor","_destroy",t)}}xT(t){return(null==t?void 0:t.includes(_t.n.endPoints.base.video))?this.Jv.appendParamsToUrl(t):t}TT(t,i,e){let s;s=t.filter((t=>t.codec===jt.L5.H264));const n=(0,$i.DE)(i,s.map((t=>t.height)));return s=s.filter((t=>t.height===n)),s.length>0?this.Jv.appendParamsToUrl(`${_t.n.endPoints.base.video}${e}/${s[0].file}`):null}}class Hn{constructor(t,i,e,s){this.imageUrl=t,this.ol=i,this.Zp=e,this.B_=s,this.oA=new J.x,this.hA=new J.x,this.D_=new J.x,this.O_=new J.x,this.Fc=[]}get onDisplayAd(){return this.oA.asObservable()}get onError(){return this.hA.asObservable()}get onClickAd(){return this.D_.asObservable()}get onClickClose(){return this.O_.asObservable()}destroy(){var t;null===(t=this.Y_)||void 0===t||t.destroy()}initializeAd(t,i,e,s){this.ET=t,this.MT(s,i,e)}getAdMediaDimensions(){var t;return null===(t=this.Y_)||void 0===t?void 0:t.getAdMediaDimensions()}MT(t,i,e){this.BT=this.ol.createElement("img"),this.BT.onload=()=>{this.RT(t,i,e)},this.BT.onerror=()=>{this.hA.next(k.VastNonLinearImageLoadFailure)},this.BT.src=this.imageUrl}RT(t,i,e){const s=this.OT(t,i,e);this.DT(s,t,i)}OT(t,i,e){let s;return s=t?this.VT(i,e):`height:${i.height}px; width: ${i.width}px;`,`<img alt='' src="${this.imageUrl}" style="${s} display: block; pointer-events: all; cursor: pointer">`}DT(t,i,e){this.Y_=new In(v.ProtoAdType.Nonlinear,t,yn.Html,this.ET,this.ol,this.Zp,this.B_,{height:e.height,width:e.width,scalable:i?{maxHeightPercent:oi.NON_LINEAR_MAX_HEIGHT_PERCENT,maxWidthPercent:oi.NON_LINEAR_MAX_WIDTH_PERCENT}:null}),this.Fc.push(this.Y_.onDisplayAd.subscribe((()=>{this.oA.next()})),this.Y_.onClickClose.subscribe((()=>{this.O_.next()})),this.Y_.onClickAd.subscribe((()=>{this.D_.next()})),this.Y_.onError.subscribe((()=>{this.hA.next(k.DisplayIntegratorIframeLoad)}))),this.Y_.createBanner(e)}VT(t,i){const e=(0,$i.Tc)(i.height,oi.NON_LINEAR_MAX_HEIGHT_PERCENT),s=(0,$i.Tc)(i.width,oi.NON_LINEAR_MAX_WIDTH_PERCENT),n=t.height/e;return t.width/s>n?"width: 100%;":"height: 100%;"}}const zn={[nn.n.FirstQuartile]:T.AdVideoFirstQuartile,[nn.n.SecondQuartile]:T.AdVideoMidpoint,[nn.n.ThirdQuartile]:T.AdVideoThirdQuartile,[nn.n.FourthQuartile]:T.AdVideoComplete};class Wn extends pn{constructor(t,i){super(t,i),this.Ws=t,this.settings=i,this.adMediaType="nonLinearVast",this.adSourceType=v.ProtoAdsourceTypeEnum.VastMedia,this.FT=[],this.Gs=500,this.NT=0,this.nonLinearOnClick=()=>{this.jT.nonLinearClickTracking.uri&&this.settings.globalDomUtilsService.trackWithImages([this.jT.nonLinearClickTracking.uri]),this.jT.nonLinearClickThrough&&this.settings.globalDomUtilsService.open(this.jT.nonLinearClickThrough,e.bS.Blank),this.NA({type:T.AdClickThru,payload:{}})}}initAd(t,i,e,n,r,o,h){try{if(super.initAd(t,i,e,n,r,o,h),!(0,S.BZ)(this.settings.vastResponse.nonLinearFiles))return this.QA=Te.NonlinearSupportedTypeNotFound,void this.NA({type:T.AdError,payload:{errorMessage:k.NonLinearUnsupportedMedia,errorCode:this.QA}});if(this.jT=this.$T(),!this.jT)return this.QA=Te.NonlinearExpectingDifferentSize,void this.NA({type:T.AdError,payload:{errorMessage:k.NonLinearUnsupportedMedia,errorCode:this.QA}});this.UT(),this.qT(),this.NA({type:T.AdLoaded,payload:{}})}catch(t){(0,s.$K)(this.QA)||(this.QA=Te.NonlinearGeneralError),this.NA({type:T.AdError,payload:{errorMessage:k.AdaptorInitAdError+`_${t.message}`,errorCode:this.QA}})}}startAd(){super.startAd(),this.__.start(),this.FT.push(this.zT.onDisplayAd.subscribe((()=>{this.NA({type:T.AdStarted}),this.NA({type:T.AdVideoStart}),this.NA({type:T.AdImpression,payload:{}})})),this.zT.onError.subscribe((t=>{this.QA=Te.NonlinearUnableToFetchResource,this.NA({type:T.AdError,payload:{errorMessage:t,errorCode:this.QA}})})),this.zT.onClickAd.subscribe((()=>this.nonLinearOnClick())),this.zT.onClickClose.subscribe((()=>{this.NA({type:T.AdUserClose,payload:{}}),this.stopAd(gn)})));const t={height:this.jT.height,width:this.jT.width},i={height:this.SA.clientHeight,width:this.SA.clientWidth};this.zT.initializeAd(this.wA,t,i,this.jT.scalable)}get adVideoUrl(){return this.S_}get declaredDurationInSeconds(){return this.NT/Lt.s_}getAdMediaSize(){var t;return null===(t=this.zT)||void 0===t?void 0:t.getAdMediaDimensions()}resizeAd(t,i,e){}pauseAd(){try{this.__.stop(),this.NA({type:T.AdPaused}),this.l_()}catch(t){this.w_("NonLinearVastBidAdaptor","pauseAd",t)}}resumeAd(){this.__.start(),this.l_()}expandAd(){}collapseAd(){}getAdRemainingTime(){return this.__.timeRemaining}getAdDuration(){return this.NT/Lt.s_}getAdVolume(){return 0}UT(){this.jT.staticResource&&(this.zT=new Hn(this.jT.staticResource.uri,this.settings.globalDomUtilsService,this.settings.sessionId,this.settings.adManagerLineItem.protoLineItem.advertiserLineItemId),this.S_=this.jT.staticResource.creativeType,this.WT())}WT(){this.SA.style.visibility="hidden"}qT(){var t;this.NT=(null===(t=this.settings.adManagerLineItem.protoLineItem.nonlinearLineItemSettings)||void 0===t?void 0:t.nonLinearAdTimeSeconds)*Lt.s_,this.__=new Ks.B(this.Ws,this.NT,this.Gs),this.FT.push(this.__.onTimeUpdate.subscribe((()=>{this.NA({type:T.AdRemainingTimeChange})})),this.__.onTimeElapsed.subscribe((()=>{this.stopAd("nonLinearTimerElapsed")})),this.__.onQuartile.subscribe((t=>{this.NA({type:zn[t],payload:{}})})))}Wg(){var t,i;try{super.Wg(),null===(t=this.__)||void 0===t||t.stop(),(0,it.i)(this.FT),null===(i=this.zT)||void 0===i||i.destroy()}catch(t){this.w_("NonLinearBidAdaptor","_destroy",t)}}$T(){let t;if(t=this.settings.vastResponse.nonLinearFiles.find((t=>!0===t.scalable)),!t){const i=(0,$i.Tc)(this.SA.clientHeight,oi.NON_LINEAR_MAX_HEIGHT_PERCENT);t=this.settings.vastResponse.nonLinearFiles.find((t=>t.height<=i&&t.width<=this.SA.clientWidth))}return t}}class Gn{constructor(t,i,e,s,n,r,o,a,c,d=!1,l=null,u=null){this.tx=t,this.sx=i,this.Dv=e,this.Vv=s,this.nx=n,this._x=r,this.Rs=o,this.Zp=a,this.GT=c,this.XT=d,this.QT=l,this.JT=u,this.YT=new J.x,this.hA=new J.x,this.KT={id:(0,h.qs)()},this.ox=null,this.mx=t=>{if(!this.vx(t))return;const i=t.getError().getErrorCode();switch(this.XT&&(0,p.n)({message:"Ima_Error_Code",exception:t.getError().getMessage(),level:p.D.INFO},{throttle:5}),i){case this.tx.AdError.ErrorCode.VAST_EMPTY_RESPONSE:this.tk(De.ImaVastEmptyResponse);break;case this.tx.AdError.ErrorCode.VAST_WRAPPER_ERROR:case this.tx.AdError.ErrorCode.VAST_MALFORMED_RESPONSE:this.tk(De.ImaInvalidResponse);break;default:this.tk(De.ImaRequestException)}},this.ik=t=>{this.vx(t)&&(this.ox=t.getAdsManager(this._x,{loadVideoTimeout:25*Lt.s_}),this.ek(),this.YT.next({imaAdsManager:this.ox,requestAdsContext:this.KT}))},this.sx.addEventListener(this.tx.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,this.ik),this.sx.addEventListener(this.tx.AdErrorEvent.Type.AD_ERROR,this.mx)}get onSuccess(){return this.YT.asObservable()}get onError(){return this.hA.asObservable()}loadAd(){const t=new this.tx.AdsRequest;["3ebdd57e-b5b8-4fd8-8887-6ae94a978a12","fe9242a7-7f5a-40f0-84ad-0d1cb921dbbe","5ee7c0e2-db41-417d-a2f2-4d91037b85bd","a28964ae-afa3-45d3-9f00-fa228cf89d74"].includes(this.GT)&&(t.omidAccessModeRules={},t.omidAccessModeRules[google.ima.OmidVerificationVendor.OTHER]=google.ima.OmidAccessMode.DOMAIN,t.omidAccessModeRules[google.ima.OmidVerificationVendor.INTEGRAL_AD_SCIENCE]=google.ima.OmidAccessMode.DOMAIN,t.omidAccessModeRules[google.ima.OmidVerificationVendor.MOAT]=google.ima.OmidAccessMode.DOMAIN,t.omidAccessModeRules[google.ima.OmidVerificationVendor.DOUBLEVERIFY]=google.ima.OmidAccessMode.DOMAIN,t.omidAccessModeRules[google.ima.OmidVerificationVendor.PIXELATE]=google.ima.OmidAccessMode.DOMAIN,t.omidAccessModeRules[google.ima.OmidVerificationVendor.NIELSEN]=google.ima.OmidAccessMode.DOMAIN,t.omidAccessModeRules[google.ima.OmidVerificationVendor.COMSCORE]=google.ima.OmidAccessMode.DOMAIN,t.omidAccessModeRules[google.ima.OmidVerificationVendor.MEETRICS]=google.ima.OmidAccessMode.DOMAIN,t.omidAccessModeRules[google.ima.OmidVerificationVendor.GOOGLE]=google.ima.OmidAccessMode.FULL);const i=L.h.getSessionChildContainer(this.Zp).resolve(Qs.P);if((0,s.QM)(this.QT))t.adsResponse=this.QT;else if(this.JT&&(0,S.BZ)(this.JT)){const i=this.JT[0],{uprQueryName:e,uprQueryValue:s}=i;t.adTagUrl=(0,a.Bp)(this.nx,e,s)}else t.adTagUrl=this.nx;if(i.isImaTestCaseForSS()||i.isLegacyDotComDomain()){const e=i.adManagerSound<=0;t.setAdWillPlayMuted(e)}t.linearAdSlotWidth=t.nonLinearAdSlotWidth=this.Dv,t.linearAdSlotHeight=t.nonLinearAdSlotHeight=this.Vv,t.pageUrl=this.Rs,this.sx.requestAds(t,this.KT)}destroy(){var t;try{this.ek(),null===(t=this.ox)||void 0===t||t.destroy()}catch(t){}}tk(t){this.hA.next(t)}ek(){this.sx.removeEventListener(this.tx.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,this.ik),this.sx.removeEventListener(this.tx.AdErrorEvent.Type.AD_ERROR,this.mx)}vx(t){const i=t.getUserRequestContext();return!i||i.id===this.KT.id}}class Xn extends pn{constructor(t,i){super(t,i),this.Ws=t,this.settings=i,this.AA=null,this.adMediaType="ima",this.adSourceType=v.ProtoAdsourceTypeEnum.Ima,this.Ex=[],this.sk=!1,this.nk=[]}initAd(t,i,e,s,n,r,o){try{super.initAd(t,i,e,s,n,r,o),this.settings.adManagerLineItem.protoLineItem.moatTrackingEnabled&&this.Lx(),this.rk().then((r=>{try{this.hk(r)}catch(t){return void this.NA({type:T.AdError,payload:{errorMessage:k.ImaCreateWrapperError+`_${t.message}`}})}this.Ex.push(this.Mx.onVpaidEvent.subscribe((t=>{this.NA(t)})),this.Mx.onCreativeReceived.subscribe((t=>{this.creativeId=t})));try{this.Mx.initAd(t,i,e,s,n,{slot:this.wA,videoSlot:this.SA})}catch(t){return void this.NA({type:T.AdError,payload:{errorMessage:k.ImaInitWrapperError+`_${t.message}`}})}})).catch((t=>{this.NA({type:T.AdError,payload:{errorMessage:k.ImaLoadInitError+`_${t}`}})}))}catch(t){this.NA({type:T.AdError,payload:{errorMessage:k.AdaptorInitAdError+`_${t.message}`}})}}startAd(){try{super.startAd(),this.Mx.startAd()}catch(t){this.NA({type:T.AdError,payload:{errorMessage:k.AdaptorStartAdError+`_${t.message}`}})}}stopAd(t){try{super.stopAd(t),this.Mx.stopAd(t)}catch(t){this.w_("ImaBidAdaptor","stopAd",t)}}resizeAd(t,i,e){try{this.Mx.resizeAd(t,i,e)}catch(t){this.w_("ImaBidAdaptor","resizeAd",t)}}pauseAd(){try{this.Mx.pauseAd()}catch(t){this.w_("ImaBidAdaptor","pauseAd",t)}}resumeAd(){try{this.Mx.resumeAd()}catch(t){this.w_("ImaBidAdaptor","resumeAd",t)}}expandAd(){try{this.Mx.expandAd()}catch(t){this.w_("ImaBidAdaptor","expandAd",t)}}collapseAd(){try{this.Mx.collapseAd()}catch(t){this.w_("ImaBidAdaptor","collapseAd",t)}}skipAd(){try{super.skipAd(),this.Mx.skipAd()}catch(t){this.w_("ImaBidAdaptor","skipAd",t)}}getAdRemainingTime(){try{return this.Mx.getAdRemainingTime()}catch(t){return this.w_("ImaBidAdaptor","getAdRemainingTime",t),0}}getAdDuration(){try{return this.Mx&&this.Mx.getAdDuration()||this.settings.adManagerLineItem.protoLineItem.duration}catch(t){return this.w_("ImaBidAdaptor","getAdDuration",t),0}}getAdVolume(){try{return this.Mx.getAdVolume()}catch(t){return this.w_("ImaBidAdaptor","getAdVolume",t),0}}getAdMediaSize(){return{width:this.Mx.getAdMediaWidth(),height:this.Mx.getAdMediaHeight()}}setAdVolume(t){try{super.setAdVolume(t),this.Mx.setAdVolume(t)}catch(t){this.w_("ImaBidAdaptor","setAdVolume",t)}}get adVideoUrl(){return this.Mx.getMediaFile()}get declaredDurationInSeconds(){return this.Mx.getAdDuration()}u_(t){const i=super.u_(t);return i.payload.adSourceData.imaMetadata=t.payload.imaMetadata,i}y_(){return this.settings.adSlotContainerRecycler.requestAdSlotIma(this.settings.adContainer)}hk(t){this.Mx=new xn(this.ak.imaSdk,this.settings.os,this.ak.imaAdsLoader,this.settings.url,t.imaAdsManager,t.requestAdsContext,this.settings.adManagerLineItem.protoLineItem.publisherLineItemId,this.settings.sessionId)}rk(){return this.ck(this.AA).then((t=>(this.sk=!0,this.dk&&(0,it.i)(this.nk),Promise.resolve(t)))).catch((t=>(this.sk=!0,this.dk&&((0,it.i)(this.nk),this.dk.destroy()),Promise.reject(t))))}ck(t){return t.fetchImaDependencies().then((t=>(this.ak=t,this.lk(t)))).then((t=>Promise.resolve(t))).catch((t=>(0,s.$K)(t)?Promise.reject(t):Promise.reject(De.ImaRequestException)))}lk(t){return this.sk?Promise.reject():new Promise(((i,e)=>{const s=this.uk(),{advertiserLineItemId:n,adxFloorPricePredictionList:r}=this.settings.adManagerLineItem.protoLineItem;this.dk=new Gn(t.imaSdk,t.imaAdsLoader,s.width,s.height,this.settings.url,this.AA.videoSlot,this.settings.pageUrl,this.settings.sessionId,n,!0,this.settings.xml,r),this.nk.push(this.dk.onSuccess.subscribe((t=>{i(t)})),this.dk.onError.subscribe((t=>{e(t)}))),this.dk.loadAd()}))}uk(){return this.settings.callingState.adContainerState.get(this.settings.adManagerLineItem.protoLineItem.adType)}Lx(){Cn.fetchImaSdk(this.settings.globalDomUtilsService.getGlobalClosestTop().topFrame,!1)}Wg(){var t;try{super.Wg(),(0,it.i)(this.Ex),null===(t=this.Mx)||void 0===t||t.destroy()}catch(t){this.w_("ImaBidAdaptor","_destroy",t)}}}class Qn{constructor(t,i,e,s,n){this.pk=t,this.yn=i,this.Zp=e,this.pi=s,this.B_=n,this.fk={bodyTamplate:`<div class="ad-element" id="cnx-ad-element"></div><script type="text/javascript" src="${this.pk}"><\/script>'\n        <script type="text/javascript">\n            window.Object.defineProperty(Object.prototype, 'cnxInnerTag', { enumerable: !1, writable: !0, value: '${this.pi}' });\n            window.Object.defineProperty(Function.prototype, 'cnxInnerTag',\n            { enumerable: !1, writable: !0, value: '${this.pi}' });\n            cnxtimeouts = [];\n            cnxintervals = [];\n            oldSetTimeout = setTimeout;\n            setTimeout = function (e, t) { var n = oldSetTimeout.apply(null, arguments); return cnxtimeouts.push(n), n };\n            oldSetInterval = setInterval;\n            setInterval = function (e, t) { var n = oldSetInterval.apply(null, arguments); return cnxintervals.push(n), n };\n            clearAll = function () {\n                setTimeout = function () { };\n                setInterval = function () { };\n                for (var e = 0; e < cnxtimeouts.length; e++) {\n                    clearTimeout(cnxtimeouts[e]);\n                }\n                for (e = 0; e < cnxintervals.length; e++) {\n                    clearInterval(cnxintervals[e]);\n                }\n            };\n        <\/script>`,headTamplate:" <style>\n            html,\n            body,\n            .ad-element {\n                width: 100%;\n                height: 100%;\n            }\n            </style>"},this.Kw=new At(this.yn,this.Zp)}mk(t){return this.Kw.loadIframe({customHead:this.fk.headTamplate,customHtml:this.fk.bodyTamplate,container:t,customReportingLog:{heavyAdBlockTypeEnum:v.ProtoHeavyAdBlockTypeEnum.VpaidIframe,advertiserLineItemId:this.B_},iframeClass:"omid-elem",title:js.$b})}loadAdUnitIframe(t){return new Promise(((i,e)=>{this.mk(t).then((t=>{t.adContainer=t.iframe.contentWindow.document.querySelector(".ad-element"),i(t)})).catch((t=>{e(t)}))}))}destroyAdUnit(){try{const t=this.Kw.iframe.contentWindow.clearAll;t&&t()}catch(t){(0,p.n)({message:"AdManager_VPAIClient_destroyAdUnit",exception:null==t?void 0:t.message,callStack:null==t?void 0:t.stack,level:p.D.WARN,sessionId:this.Zp},{throttle:2,shouldSendMaxLog:!0})}this.Kw.destroy(),this.Kw=null}}var Jn,Yn,Kn,Zn;!function(t){t[t.handshakeVersion=0]="handshakeVersion",t[t.initAd=1]="initAd",t[t.startAd=2]="startAd",t[t.stopAd=3]="stopAd",t[t.skipAd=4]="skipAd",t[t.resizeAd=5]="resizeAd",t[t.pauseAd=6]="pauseAd",t[t.resumeAd=7]="resumeAd",t[t.expandAd=8]="expandAd",t[t.collapseAd=9]="collapseAd",t[t.subscribe=10]="subscribe",t[t.unsubscribe=11]="unsubscribe"}(Jn||(Jn={}));class tr extends rn{constructor(t,i,e,n,r,o,h){super(),this.Yx=t,this.yn=i,this.Zp=e,this.gk=n,this.B_=r,this._A=o,this.gi=h,this.vk=[],this.yk=new Set,this.bk=new Set,this.Ik=(t,i,e)=>{const s={url:t,playerHandles:e};this.wk(T.AdClickThru,s)},this.wk=(t,i)=>{if(this.bk.add(t),!this.yk.has(t))return t!==T.AdImpression||this.bk.has(T.AdLoaded)?void this.Sk(t,i):((0,p.n)({message:"AdManager_AdVpaidWrapper_ImpressionBeforeAdLoaded",exception:`advertiserLineItemId:${this.B_}_creativeId:${this._A}_vpaidSrc:${this.Yx}`,callStack:JSON.stringify((0,S.ee)(this.bk)),level:p.D.WARN},{throttle:1e3}),this.yk.add(T.AdLoaded),void this.Sk(T.AdLoaded,i))},this.Sk=(t,i)=>{switch(t){case T.AdError:this.wI.next({type:T.AdError,payload:{errorMessage:(0,s.HD)(i)?i:JSON.stringify(i)}});break;case T.AdLoaded:this.wI.next({type:T.AdLoaded,payload:{skipOffset:(0,s.as)(i)?i.skipOffset:void 0}});break;case T.AdImpression:this.wI.next({type:T.AdImpression,payload:{}});break;case T.AdClickThru:this.wI.next({type:T.AdClickThru,payload:(0,s.as)(i)?i:{}});break;default:this.wI.next({type:T[t]})}}}initAd(t,i,e,s,n,r){try{this.Dv=t,this.Vv=i,this.Sx=e,this.Pk=s,this.Ak=n,this._k=r,this.xk=new Qn(this.Yx,this.yn,this.Zp,this.gk,this.B_),this.Tk=this.xk.loadAdUnitIframe(r.slot).then((t=>{this.kk(t)})).catch((t=>{this.wI.next({type:T.AdError,payload:{errorMessage:k.VpaidOnLoad}})}))}catch(t){this.wI.next({type:T.AdError,payload:{errorMessage:k.VpaidOnLoad}})}}startAd(){try{this.bk.has(T.AdImpression)&&!this.yk.has(T.AdImpression)&&((0,p.n)({message:"AdManager_AdVpaidWrapper_brokenImpressionHandle",exception:`advertiserLineItemId:${this.B_}_creativeId:${this._A}_vpaidSrc:${this.Yx}`,callStack:JSON.stringify((0,S.ee)(this.bk)),level:p.D.WARN},{throttle:1e3}),this.yk.add(T.AdImpression),this.wI.next({type:T.AdImpression,payload:{}})),this.Ck.startAd()}catch(t){this.wI.next({type:T.AdError,payload:{errorMessage:k.WrapperStartAdError}})}}stopAd(t){var i;null===(i=this.Tk)||void 0===i||i.then((()=>{this.Ck?this.Ck.stopAd(t):(0,p.n)({message:"stopAd",exception:t,level:p.D.WARN})}))}resizeAd(t,i,e){this.Ck.resizeAd(t,i,e)}pauseAd(){this.Ck.pauseAd()}resumeAd(){this.Ck.resumeAd(),this.gi===zt.M.Ios&&(0,u.UR)(this._k.videoSlot)}expandAd(){this.Ck.expandAd()}collapseAd(){this.Ck.collapseAd()}skipAd(){this.Ck.skipAd()}getAdRemainingTime(){return this.Ck.getAdRemainingTime()}getAdDuration(){var t;return null===(t=this.Ck)||void 0===t?void 0:t.getAdDuration()}getAdVolume(){return this.Ck.getAdVolume()}setAdVolume(t){this.Ck.setAdVolume(t)}destroy(){var t;this.Mk(),this.vk.length=0,this.Ck=null,null===(t=this.xk)||void 0===t||t.destroyAdUnit()}kk(t){const i=t.iframe.contentWindow.getVPAIDAd;if("function"==typeof i){const e=i();this.Ck=e,this.Lk(),this.Bk(e)?e.initAd(this.Dv,this.Vv,this.Sx,this.Pk,this.Ak,{slot:t.adContainer,videoSlot:this._k.videoSlot}):this.wI.next({type:T.AdError,payload:{errorMessage:k.VpaidInvalid}})}else this.wI.next({type:T.AdError,payload:{errorMessage:k.VpaidGetVpaidAdError,errorCode:Te.MediaFileNotFound}})}Lk(){Object.keys(T).forEach((t=>{let i=this.wk.bind(this,T[t]);T[t]===T.AdClickThru&&(i=this.Ik),this.vk.push({handler:i,event:t}),this.Ck.subscribe(i,t)}))}Mk(){this.vk.forEach((t=>{this.Ck.unsubscribe(t.handler,t.event)}))}Bk(t){return Object.keys((0,S.ti)(Jn)).every((i=>(0,s.mf)(t[Jn[i]])))}}!function(t){t.AdVerifications="AdVerifications"}(Yn||(Yn={})),function(t){t[t.Javascript=0]="Javascript",t[t.Video=1]="Video"}(Kn||(Kn={})),function(t){t.VastIconsContainer="cnx-vast-icons",t.VastIcon="cnx-vast-icon"}(Zn||(Zn={}));class ir{constructor(t,i,e){this.Ws=t,this.wI=i,this.ci=e,this.Rk=[],this.Dk=[],this.Gs=500,this.Dk.push(this.wI.subscribe((t=>{t.type===T.AdPaused&&this.gn(),t.type===T.AdPlaying&&this.mn()})))}init(){(0,s.$K)(this.ci.offset)?this.Vk(this.ci.offset,(()=>this.Nk())):this.Nk()}destroy(){this.jk(),this.$k.removeEventListener("click",this.Uk.bind(this)),this.__.disable(),(0,it.i)(this.Rk),(0,it.i)(this.Dk),this.Rk=[],this.Dk=[]}Nk(){this.$k=this.qk(),this.$k.addEventListener("click",this.Uk.bind(this)),this.ci.$container.appendChild(this.$k),(0,s.$K)(this.ci.duration)&&this.Vk(this.ci.duration,(()=>this.destroy())),(0,s.$K)(this.ci.iconViewTracking)&&this.ci.globalDomUtilsService.trackWithImages([this.ci.iconViewTracking])}Vk(t,i){this.__=new Ks.B(this.Ws,t,this.Gs),this.Rk.push(this.__.onTimeElapsed.subscribe((()=>{i()}))),this.__.start()}jk(){this.$k.remove()}gn(){this.__.stop()}mn(){this.__.start()}qk(){return this.ci.globalDomUtilsService.createElementByString(`\n            <cnx\n                class="${Zn.VastIcon}"\n                style="\n                        position: absolute;\n                        ${this.Hk(this.ci.xPosition)}\n                        ${this.zk(this.ci.yPosition)}\n                        ${this.Wk(this.ci.width)}\n                        ${this.Gk(this.ci.height)}\n                    "\n                >\n                ${this.Xk()}\n            </cnx>\n        `)}Hk(t){if(!(0,s.QM)(t)&&!(0,s.hj)(t))return"left: 0;";switch(t){case"left":return"left: 0;";case"right":return"right: 0;";default:return`left: ${t}px;`}}zk(t){if(!(0,s.QM)(t)&&!(0,s.hj)(t))return"top: 0;";switch(t){case"top":return"top: 0;";case"bottom":return"bottom: 0;";default:return`top: ${t}px;`}}Wk(t){return(0,s.QM)(t)||(0,s.hj)(t)?"auto"===t?`width: ${t};`:`width: ${t}px;`:"width: auto;"}Gk(t){return(0,s.QM)(t)||(0,s.hj)(t)?"auto"===t?`height: ${t};`:`height: ${t}px;`:"height: auto;"}Uk(){if(!(0,s.$K)(this.ci.iconClicks))return;const{iconClickTracking:t,iconClickThrough:i}=this.ci.iconClicks;(0,S.BZ)(t)&&this.ci.globalDomUtilsService.trackWithImages(t),(0,s.QM)(i)&&this.ci.globalDomUtilsService.open(i,e.bS.Blank)}}class er extends ir{Xk(){return this.ci.resource}}class sr extends ir{Xk(){return`<img src="${this.ci.resource}"/>`}}class nr extends ir{Xk(){return`<iframe src="${this.ci.resource}"/>`}}const rr=["AdChoices"];class or{constructor(t,i,e,s,n){this.dA=t,this.Qk=i,this.ol=e,this.Ws=s,this.wI=n,this.Jk=[]}initIcons(){if(!(0,S.BZ)(this.Qk))return;const t=this.Zk(this.Qk);(0,S.BZ)(t)&&(this.In=this.tC(),this.dA.appendChild(this.In),t.forEach((t=>{const i=this.iC(t);i.init(),this.Jk.push(i)})))}destroy(){for(;0!==this.Jk.length;){const t=this.Jk.length-1;this.Jk[t].destroy(),this.Jk.pop()}}tC(){return this.ol.createElementByString(`<cnx class="${Zn.VastIconsContainer}"></cnx>`)}Zk(t){let i=[...t].filter((t=>rr.includes(t.program))).filter((t=>(0,s.QM)(t.staticResource)||(0,s.QM)(t.htmlResource)||(0,s.QM)(t.iframeResource)));return i=(0,S.qy)("program",i.reverse()),i}iC(t){const{width:i,height:e,xPosition:s,yPosition:n,staticResource:r,htmlResource:o,iframeResource:h,iconViewTracking:a,iconClicks:c,duration:d,offset:l}=t,u={globalDomUtilsService:this.ol,$container:this.In,resource:r||o||h,iconClicks:c,width:i,height:e,xPosition:s,yPosition:n,iconViewTracking:a,duration:d,offset:l};switch(u.resource){case r:return new sr(this.Ws,this.wI,u);case o:return new er(this.Ws,this.wI,u);case h:return new nr(this.Ws,this.wI,u)}}}const hr=["fb1bdb1d-9743-4237-94e3-35d254e13564","e9d12322-f412-4a4a-aacc-a0d36f91544c","cbee7f7d-b0ba-453b-a28f-a23bc304481e"],ar=["omid"];class cr extends pn{constructor(t,i){super(t,i),this.Ws=t,this.settings=i,this.adSourceType=v.ProtoAdsourceTypeEnum.Unknown,this.Dk=[],this.creativeId=i.vastResponse.creativeId,this.DS=L.h.getSessionChildContainer(this.settings.sessionId).resolve(Ft)}initAd(t,i,s,n,r,o,h){try{super.initAd(t,i,s,n,r,o,h),(0,_n.A)(this.settings.adManagerLineItem.protoLineItem.publisherLineItemId,this.settings.vastResponse.linearClickThrough).then((r=>{var o;if(r)return void this.NA({type:T.AdError,payload:{errorMessage:k.DomainBlocked}});if(this.eC=this.sC(t,this.SA),null===this.eC)return void this.NA({type:T.AdError,payload:{errorMessage:k.VastUnsupportedMedia}});(null===(o=this.eC.src)||void 0===o?void 0:o.includes(_t.n.endPoints.base.video))&&(this.eC.src=this.Jv.appendParamsToUrl(this.eC.src)),this.adMediaType=this.eC.type,this.eC.getMediaFileType()===Kn.Video?(this.rC=new Un(this.settings.globalDomUtilsService,this.eC.src,this.SA,this.settings.os,this.settings.adManagerLineItem.protoLineItem.advertiserLineItemId,this.settings.vastResponse.linearClickThrough,this.settings.shouldLoopAdWhenFinished),this.adSourceType=v.ProtoAdsourceTypeEnum.VastMedia):(this.rC=new tr(this.eC.src,this.settings.globalDomUtilsService,this.settings.sessionId,this.t_,this.settings.adManagerLineItem.protoLineItem.advertiserLineItemId,this.creativeId,this.settings.os),this.adSourceType=v.ProtoAdsourceTypeEnum.Vpaid),(0,S.BZ)(this.settings.vastResponse.icons)&&(this.hC=new or(this.PA,this.settings.vastResponse.icons,this.settings.globalDomUtilsService,this.Ws,this.rC.onVpaidEvent)),this.Dk.push(this.rC.onVpaidEvent.subscribe((t=>{var i;if(t.type===T.AdLoaded&&(t.payload.skipOffset=this.settings.vastResponse.skipoffset,t.payload.containers={slot:this.wA,videoSlot:this.SA},t.payload.verificationScriptResources=this.settings.vastResponse.verifications.filter((t=>{var i;return(0,S.d3)(null===(i=t.javaScriptResource)||void 0===i?void 0:i.apiFramework,ar)})).map((t=>({javaScriptResource:t.javaScriptResource.url,vendor:t.vendor,verificationParameters:t.verificationParameters,trackingEvents:t.trackingEvents})))),t.type===T.AdClickThru){this.aC=t.payload.url;const i=t.payload.url||this.settings.vastResponse.linearClickThrough;i&&t.payload.playerHandles&&this.settings.globalDomUtilsService.open(i,e.bS.Blank)}t.type===T.AdStarted&&(null===(i=this.hC)||void 0===i||i.initIcons()),t.type===T.AdError&&(this.QA=t.payload.errorCode),this.NA(t)})));const h={AdParameters:this.settings.vastResponse.adParameters,adParameters:this.settings.vastResponse.adParameters};this.rC.initAd(t,i,s,n,h,{slot:this.wA,videoSlot:this.SA})})).catch((t=>{this.cC(t)}))}catch(t){this.cC(t)}}startAd(){try{super.startAd();const t=this.settings.adLoadedPayload.payload.vastVerifications;if(!(0,S.BZ)(t))return void this.rC.startAd();this.DS.isOmsdkFullSupport?this.Dk.push(this.DS.omidResourcesReady.pipe(gt((t=>t))).subscribe((()=>{this.rC.startAd()})),this.DS.verificationNotExecuted.subscribe((()=>{this.If()}))):(this.If(),this.rC.startAd())}catch(t){const i=this.QA||Te.GeneralLinearError;this.QA=i,this.NA({type:T.AdError,payload:{errorCode:i,errorMessage:k.AdaptorStartAdError+`_${t.message}`}})}}stopAd(t){super.stopAd(t),this.rC?this.rC.stopAd(t):(0,p.n)({message:"stopAd",exception:t,level:p.D.WARN})}resizeAd(t,i,e){try{this.rC.resizeAd(t,i,e)}catch(t){this.w_("VastBidAdaptor","resizeAd",t)}}pauseAd(){try{this.rC.pauseAd()}catch(t){this.w_("VastBidAdaptor","pauseAd",t)}}resumeAd(){try{this.rC.resumeAd()}catch(t){this.w_("VastBidAdaptor","resumeAd",t)}}expandAd(){try{this.rC.expandAd()}catch(t){this.w_("VastBidAdaptor","expandAd",t)}}collapseAd(){try{this.rC.collapseAd()}catch(t){this.w_("VastBidAdaptor","collapseAd",t)}}skipAd(){try{super.skipAd(),this.rC.skipAd()}catch(t){this.w_("VastBidAdaptor","skipAd",t)}}getAdRemainingTime(){try{return this.rC.getAdRemainingTime()}catch(t){return this.w_("VastBidAdaptor","getAdRemainingTime",t),0}}getAdDuration(){try{return this.rC&&this.rC.getAdDuration()||Math.round(this.settings.vastResponse.duration/Lt.s_)}catch(t){return this.w_("VastBidAdaptor","getAdDuration",t),0}}getAdVolume(){try{return this.rC.getAdVolume()}catch(t){return this.w_("VastBidAdaptor","getAdVolume",t),0}}getAdMediaSize(){let t=0,i=0;return this.rC instanceof Un?(t=this.rC.getAdMediaWidth(),i=this.rC.getAdMediaHeight()):(t=this.eC.width,i=this.eC.height),{width:t,height:i}}setAdVolume(t){try{super.setAdVolume(t),this.rC.setAdVolume(t)}catch(t){this.w_("VastBidAdaptor","setAdVolume",t)}}get adVideoUrl(){var t;return null===(t=this.eC)||void 0===t?void 0:t.src}get declaredDurationInSeconds(){return this.settings.vastResponse.duration/Lt.s_}p_(t){const i=super.p_(t);return this.dC(i)}u_(t){const i=super.u_(t);return this.dC(i)}Wg(){var t,i;if(!this.settings.shouldLoopAdWhenFinished)try{super.Wg(),(0,it.i)(this.Dk),null===(t=this.rC)||void 0===t||t.destroy(),null===(i=this.hC)||void 0===i||i.destroy()}catch(t){this.w_("VastBidAdaptor","_destroy",t)}}dC(t){var i;return t.payload.adSourceData.name=null===(i=this.settings.vastResponse)||void 0===i?void 0:i.adTitle,t.payload.clickThroughUrl=this.aC||this.settings.vastResponse.linearClickThrough,t}lC(t,i){return t.filter((t=>t.getMediaFileType()===Kn.Video))}sC(t,i){const e=this.lC(this.settings.vastResponse.mediaFiles,i),s=e.filter((t=>"video/mp4"===t.type)),n=this.settings.vastResponse.mediaFiles.filter((t=>t.getMediaFileType()===Kn.Javascript));return this.pC()&&this.fC()&&n.length?ps(n,t):s.length?ps(s,t):e.length?ps(e,t):n.length?ps(n,t):null}fC(){const{advertiserLineItemId:t}=this.settings.adManagerLineItem.protoLineItem;return hr.includes(t)}pC(){const t=this.settings.vastResponse.extensions.filter((t=>t.type===Yn.AdVerifications));return(0,S.BZ)(t)||(0,S.BZ)(this.settings.vastResponse.verifications)}cC(t){const i=this.QA||Te.GeneralLinearError;this.QA=i,this.NA({type:T.AdError,payload:{errorCode:i,errorMessage:k.AdaptorInitAdError+`_${t.message}`}})}If(){Le.trackError(this.settings.vastTracker.adError,this.settings.adMacroReplacer,this.settings.adManagerLineItem.protoLineItem,this.settings.callingState,Te.VerificationUnitNotExecuted)}}class dr{}dr.SHOULD_CALL_WITH_CREDENTIALS_DEFAULT=!0,dr.MIN_VAST_VERSION=2,dr.DEFAULT_MAX_WRAPPER_LIMIT=10;class lr{}lr.AD_TAG_DUMMY_PREFIX="https://adx.connatix.com",lr.IMA_URL_PART=".g.doubleclick.net";class ur{constructor(t){this.mediaFiles=[],this.nonLinearFiles=[],this.adTitle=void 0,this.adParameters=void 0,this.linearClickThrough=void 0,this.creativeId=void 0,this.extensions=[],this.verifications=[],this.icons=[],t.forEach((t=>{t.inLine?(this.adTitle=t.inLine.adTitle,this.extensions=t.inLine.extensions,this.mC(t.inLine.extensions),this.gC(t.inLine.adVerifications),this.uw(t.inLine.creatives)):t.wrapper&&(this.uw(t.wrapper.creatives),this.gC(t.wrapper.adVerifications),this.mC(t.wrapper.extensions))}))}mC(t){(0,S.BZ)(t)&&t.forEach((t=>{(0,S.BZ)(t.adVerifications)&&this.gC(t.adVerifications)}))}gC(t){this.verifications=[...this.verifications,...t]}pw(t){this.duration=t.duration,this.vC(t.mediaFiles),this.yC(t.skipoffset),this.bC(t.adParameters),t.videoClicks&&t.videoClicks.clickThrough&&this.gT(t.videoClicks.clickThrough),(0,S.BZ)(t.icons)&&this.IC(t.icons)}wC(t){this.SC(t.nonLinearAdList),this.bC(t.adParameters)}SC(t){this.nonLinearFiles=[...this.nonLinearFiles,...t]}IC(t){this.icons.push(...t)}bC(t){this.adParameters=t}yC(t){this.skipoffset=t}vC(t){this.mediaFiles=[...this.mediaFiles,...t]}gT(t){this.linearClickThrough=t}uw(t){t.forEach((t=>{this.creativeId=t.id,t.linear&&this.pw(t.linear),t.nonLinear&&this.wC(t.nonLinear)}))}}var pr=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class fr{static getHlsModule(t,i){return pr(this,void 0,void 0,(function*(){let e=null;if((0,s.QM)(i)&&(e=yield On(t),!e))throw new Error(De.NetworkRequestUrl);return e}))}static getAdUnitPath(t){return t.slice(lr.AD_TAG_DUMMY_PREFIX.length)}static isImaLineItem(t){if(vn.includes(t.protoLineItem.advertiserLineItemId))return!0;const i=t.protoLineItem.adTag;return!(!(0,s.$K)(i)||(0,s.Ft)(i))&&fr.isImaUrl(i)}static isImaUrl(t){return t.includes(lr.IMA_URL_PART)}static getFinalUrl(t,i,e,n){let r=t;try{const t=i.callingState.adContainerState.get(i.adManagerLineItem.protoLineItem.adType);(0,s.$K)(t)&&(r=fr.PC(r,e,t,i),r=n.appendParams(r,t))}catch(t){throw new Error(De.InvalidCreativeUrl)}return r}static setVastInfo(t,i,e){!function(t,i){const e=new Ee(t);i.adError.push(...Oe(e.errorUrls)),i.adImpression.push(...Oe(e.impressions)),i.adViewableImpression.push(...Oe(e.trackingEvents.viewable_impression)),i.adClick.push(...Oe(e.clickTrackings)),i.adMute.push(...Oe(e.trackingEvents.mute)),i.adPause.push(...Oe(e.trackingEvents.pause)),i.adQuartileFirst.push(...Oe(e.trackingEvents.firstQuartile)),i.adQuartileSecond.push(...Oe(e.trackingEvents.midpoint)),i.adQuartileThird.push(...Oe(e.trackingEvents.thirdQuartile)),i.adQuartileFourth.push(...Oe(e.trackingEvents.complete)),i.adResume.push(...Oe(e.trackingEvents.resume)),i.adSkip.push(...Oe(e.trackingEvents.skip)),i.adStarted.push(...Oe(e.trackingEvents.creativeView)),i.adVideoStart.push(...Oe([...e.trackingEvents.start])),i.adUnmute.push(...i.adUnmute,...Oe(e.trackingEvents.unmute)),i.adUserAcceptInvitation.push(...Oe([...e.trackingEvents.acceptInvitation,...e.trackingEvents.acceptInvitationLinear])),i.adUserClose.push(...Oe(e.trackingEvents.close)),i.adUserMinimize.push(...i.adUserMinimize,...Oe([...e.trackingEvents.collapse,...e.trackingEvents.playerCollapse,...e.trackingEvents.adCollapse]))}(t,i.vastTracker),e.push(t)}static isValidHtmlMimeType(t){return Object.values(yn).some((i=>i===t))}static isVideoAd(t){const{protoLineItem:i}=t.adManagerLineItem;return i.adType===v.ProtoAdType.Video}static isNonlinearVideoAd(t){var i;const{protoLineItem:e}=t.adManagerLineItem;return e.adType===v.ProtoAdType.Nonlinear&&(null===(i=e.nonlinearLineItemSettings)||void 0===i?void 0:i.nonLinearRequestType)===v.ProtoNonlinearRequestType.Video}static haveExpectedAdType(t,i){const e=new ur(t),{mediaFiles:s,nonLinearFiles:n}=e;return i===v.ProtoAdType.Video&&(0,S.BZ)(s)||i===v.ProtoAdType.Nonlinear&&(0,S.BZ)(n)}static notifyBidFetchStart(t,i){t.onBidFetchStart.next(i),i.adManagerLineItem.bidsInFetch.add(i.bidId)}static notifyBidFetchEnd(t,i){t.onBidFetchEnd.next(i),i.adManagerLineItem.bidsInFetch.delete(i.bidId)}static PC(t,i,e,s){const n={adHeight:e.height,adWidth:e.width,adPostion:s.callingState.adBreakState.adBreakType},r={mediaDescription:s.callingState.media.mediaDescription,mediaDuration:s.callingState.media.mediaDuration,mediaId:s.callingState.media.mediaId,mediaTitle:s.callingState.media.mediaTitle,mediaUrl:s.callingState.media.mediaUrl};return i.replace(t,s.adManagerLineItem.protoLineItem.vendorId,{adMacros:n,mediaMacros:r})}}class mr{}mr.FETCH_BID_TIMEOUT=25e3;var gr=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class vr{constructor(t,i){this.imaAdSlot=t,this.imaDependencies=i,this.dk=null,this.AC=!1,this.nk=[]}static _C(){return gr(this,void 0,void 0,(function*(){return new Promise((t=>{setTimeout((()=>{t(null)}),mr.FETCH_BID_TIMEOUT)}))}))}getImaAdModule(){return gr(this,void 0,void 0,(function*(){try{const t=yield Promise.race([this.xC(),vr._C()]);if(!t)throw new Error(De.ImaTimeout);return this.AC=!0,this.dk&&(0,it.i)(this.nk),t}catch(t){throw this.AC=!0,this.dk&&((0,it.i)(this.nk),this.dk.destroy(),this.imaDependencies.adSlotContainerRecycler.recycleAdSlot(this.imaAdSlot)),(0,h.W$)(t)}}))}uk(){return this.imaDependencies.adContainerState.get(this.imaDependencies.adType)}xC(){return gr(this,void 0,void 0,(function*(){try{const t=yield this.imaAdSlot.fetchImaDependencies();return yield this.lk(t)}catch(t){throw(0,h.W$)(t)}}))}lk(t){if(this.AC)throw new Error(De.ImaRequestException);return new Promise(((i,e)=>{const n=this.uk();if(!(0,s.$K)(n)||!(0,s.$K)(this.imaDependencies.url))throw new Error(De.ImaRequestException);this.dk=new Gn(t.imaSdk,t.imaAdsLoader,n.width,n.height,this.imaDependencies.url,this.imaAdSlot.videoSlot,this.imaDependencies.pageUrl,this.imaDependencies.sessionId,this.imaDependencies.advertiserLineItemId,!1,this.imaDependencies.xml,this.imaDependencies.adxFloorPricePredictionList),this.nk.push(this.dk.onSuccess.subscribe((e=>{i(Object.assign(Object.assign({},e),t))})),this.dk.onError.subscribe((t=>{e(new Error(t))}))),this.dk.loadAd()}))}}class yr extends Error{constructor(t){super(t.errorReason),this.vastErrorTrackers=[],this.vastErrorCode=t.vastErrorCode||Te.GeneralError,this.vastErrorTrackers=t.errorUrlTrackers||[]}}class br{constructor(t){var i;this.adVerifications=void 0,this.type=t.keyAttributes.type,this.adVerifications=(null===(i=null==t?void 0:t.adverifications)||void 0===i?void 0:i.verification)?wr.parseVerifications((0,S.qo)(t.adverifications.verification)):[]}}var Ir,wr,Sr,Pr=r(1310);!function(t){function i(t){return/^\s*$/.test(t)?null:/^(?:true|false)$/i.test(t)?"true"===t.toLowerCase():(0,a.jv)(t)?t:isFinite(Number(t))?parseFloat(t):isFinite(Date.parse(t))?new Date(t):"string"==typeof t?t.trim():t}t.JXONTree=function t(e){let s=0,n="";if(this.keyAttributes||(this.keyAttributes={}),e.hasChildNodes()){for(let i,s,r,o=0;o<e.childNodes.length;o++)i=e.childNodes.item(o),(i.nodeType-1|1)===Node.TEXT_NODE?n+=i.nodeType===Node.TEXT_NODE?i.nodeValue.trim():i.nodeValue:1!==i.nodeType||i.prefix||(s=i.nodeName.toLowerCase(),r=new t(i),this.hasOwnProperty(s)?(this[s].constructor!==Array&&(this[s]=[this[s]]),this[s].push(r)):this[s]=r);this.keyValue=n?i(n):null}if(void 0===e.hasAttributes?e.attributes.length>0:e.hasAttributes()){let t;for(;s<e.attributes.length;s++)t=e.attributes.item(s),this.keyAttributes[t.name.toLowerCase()]=i(t.value.trim())}},t.getKeyValue=function(t){if(t&&t.keyValue)return t.keyValue},t.decodeXMLText=function(t){if("string"==typeof t)return t.replace(/&apos;/g,"'").replace(/&quot;/g,'"').replace(/&gt;/g,">").replace(/&lt;/g,"<").replace(/&amp;/g,"&")},t.isValidXMLString=function(t){const i=(new DOMParser).parseFromString(t,"text/xml").documentElement.querySelector("parsererror");return(0,s.Ft)(i)},t.parseText=i}(Ir||(Ir={}));class Ar{constructor(t){this.TC=["text/javascript","text/javascript1.0","text/javascript1.2","text/javascript1.4","text/jscript","application/javascript","application/x-javascript","text/ecmascript","text/ecmascript1.0","text/ecmascript1.2","text/ecmascript1.4","text/livescript","application/ecmascript","application/x-ecmascript"],this.kC="VPAID",this.delivery=void 0,this.type=void 0,this.width=0,this.height=0,this.codec=void 0,this.id=void 0,this.bitrate=void 0,this.minBitrate=void 0,this.maxBitrate=void 0,this.scalable=void 0,this.maintainAspectRatio=void 0,this.apiFramework=void 0,this.src=void 0,this.isSupported=!0,this.delivery=t.keyAttributes.delivery,this.type=t.keyAttributes.type,this.width=t.keyAttributes.width,this.height=t.keyAttributes.height,this.codec=t.keyAttributes.codec,this.id=t.keyAttributes.id,this.bitrate=t.keyAttributes.bitrate,this.minBitrate=t.keyAttributes.minbitrate,this.maxBitrate=t.keyAttributes.maxbitrate,this.scalable=t.keyAttributes.scalable,this.maintainAspectRatio=t.keyAttributes.maintainaspectratio,this.apiFramework=t.keyAttributes.apiframework,this.src=Ir.getKeyValue(t),this.isSupported=this.CC()}getMediaFileType(){return this.apiFramework===this.kC||(0,S.d3)(this.type,this.TC)?Kn.Javascript:Kn.Video}CC(){if("VPAID"===this.apiFramework||(0,S.d3)(this.type,this.TC))return!0;if("application/x-shockwave-flash"===this.type||"video/x-flv"===this.type)return!1;if(!(0,s.QM)(this.type))return(0,p.n)({message:"MediaFile_type_not_provided",level:p.D.WARN}),!0;const t=document.createElement("video").canPlayType(this.type);return!!(0,s.QM)(t)}}class _r{constructor(t){this.clickThrough=void 0,this.clickTrackings=[],this.customClicks=[],this.clickThrough=Ir.getKeyValue(t.clickthrough),this.clickTrackings=this.EC((0,S.qo)(t.clicktracking)),this.customClicks=this.EC((0,S.qo)(t.customclick))}EC(t){const i=[];return void 0!==t[0]&&t.forEach((t=>{i.push(Ir.getKeyValue(t))})),i}}class xr{constructor(t){this.iconClickTracking=[],this.iconClickThrough=Ir.getKeyValue(t.iconclickthrough),(0,s.$K)(t.iconclicktracking)&&(this.iconClickTracking=this.MC((0,S.qo)(t.iconclicktracking)))}MC(t){return(0,S.BZ)(t)?t.map((t=>Ir.getKeyValue(t))):[]}}class Tr{constructor(t){var i,e,n,r,o,h,a;this.program=null===(i=t.keyAttributes)||void 0===i?void 0:i.program,this.width=null===(e=t.keyAttributes)||void 0===e?void 0:e.width,this.height=null===(n=t.keyAttributes)||void 0===n?void 0:n.height,this.pxRatio=null===(r=t.keyAttributes)||void 0===r?void 0:r.pxratio,this.xPosition=null===(o=t.keyAttributes)||void 0===o?void 0:o.xposition,this.yPosition=null===(h=t.keyAttributes)||void 0===h?void 0:h.yposition,this.apiFramework=null===(a=t.keyAttributes)||void 0===a?void 0:a.apiframework,this.offset=(0,s.$K)(t.keyAttributes.offset)?(0,Pr.pP)(t.keyAttributes.offset):void 0,this.duration=(0,s.$K)(t.keyAttributes.duration)?(0,Pr.pP)(t.keyAttributes.duration):void 0,this.staticResource=Ir.getKeyValue(t.staticresource),this.iframeResource=Ir.getKeyValue(t.iframeresource),this.htmlResource=Ir.getKeyValue(t.htmlresource),this.iconViewTracking=Ir.getKeyValue(t.iconviewtracking),(0,s.$K)(t.iconclicks)&&(this.iconClicks=new xr(t.iconclicks))}}class kr{constructor(t){this.duration=void 0,this.mediaFiles=[],this.icons=[],this.trackingEvents=[],this.skipoffset=void 0,this.videoClicks=void 0,this.duration=(0,Pr.pP)(Ir.getKeyValue(t.duration)),this.skipoffset=(0,Pr.QI)(t.keyAttributes.skipoffset,this.duration),t.mediafiles&&(this.mediaFiles=this.LC((0,S.qo)(t.mediafiles.mediafile))),t.trackingevents&&(this.trackingEvents=wr.parseTrackingEvents((0,S.qo)(t.trackingevents.tracking),this.duration)),t.videoclicks&&(this.videoClicks=new _r(t.videoclicks)),t.adparameters&&(this.adParameters=Ir.getKeyValue(t.adparameters),t.adparameters["@xmlEncoded"]&&(this.adParameters=Ir.decodeXMLText(this.adParameters))),t.icons&&t.icons.icon&&(this.icons=this.BC((0,S.qo)(t.icons.icon)))}LC(t){const i=[];return void 0!==t[0]&&t.forEach((t=>{const e=new Ar(t);i.push(e)})),i}BC(t){return(0,S.BZ)(t)?t.map((t=>new Tr(t))):[]}isSupported(){return!0}}class Cr{constructor(t){var i;this.minSuggestedDuration=void 0,this.staticResource={},this.htmlResource={},this.iframeResource={},this.nonLinearClickTracking={},this.id=t.keyAttributes.id,this.width=t.keyAttributes.width,this.height=t.keyAttributes.height,this.expandedWidth=t.keyAttributes.expandedheight,this.expandedHeight=t.keyAttributes.expandedwidth,this.scalable=t.keyAttributes.scalable,this.maintainAspectRatio=t.keyAttributes.maintainaspectratio,this.apiFramework=t.keyAttributes.apiframework,this.minSuggestedDuration=(0,Pr.pP)(t.keyAttributes.minsuggestedduration),this.nonLinearClickThrough=null===(i=t.nonlinearclickthrough)||void 0===i?void 0:i.keyValue,t.nonlinearclicktracking&&(this.nonLinearClickTracking.id=t.nonlinearclicktracking.keyAttributes.id,this.nonLinearClickTracking.uri=t.nonlinearclicktracking.keyValue),t.staticresource&&(this.staticResource.creativeType=t.staticresource.keyAttributes.creativetype,this.staticResource.uri=t.staticresource.keyValue),t.iframeresource&&(this.iframeResource.uri=t.iframeresource.keyValue),t.htmlresource&&(this.htmlResource.uri=t.htmlresource.keyValue)}isSupported(){return"VPAID"===this.apiFramework?((0,p.n)({message:"AdManager_NonLinearAd_VPAID_found",level:p.D.INFO},{pacing:10,shouldSendMaxLog:!1}),!1):this.width&&this.height?!(!this.staticResource.creativeType||!this.staticResource.uri)||(this.htmlResource.uri&&(0,p.n)({message:"AdManager_NonLinearAd_htmlResource_found",level:p.D.INFO},{pacing:10,shouldSendMaxLog:!1}),this.iframeResource.uri&&(0,p.n)({message:"AdManager_NonLinearAd_iframeResource_found",level:p.D.INFO},{pacing:10,shouldSendMaxLog:!1}),!1):((0,p.n)({message:"AdManager_NonLinearAd_no_dimensions",level:p.D.INFO},{pacing:10,shouldSendMaxLog:!1}),!1)}}class Er{constructor(t){if(this.nonLinearAdList=[],this.trackingEvents=[],this.RC=!1,t.nonlinear){const i=(0,S.qo)(t.nonlinear);this.nonLinearAdList=this.OC(i),this.RC=(0,S.BZ)(i)&&0===this.nonLinearAdList.length}t.trackingevents&&(this.trackingEvents=wr.parseTrackingEvents((0,S.qo)(t.trackingevents.tracking))),t.adparameters&&(this.adParameters=Ir.getKeyValue(t.adparameters),t.adparameters["@xmlEncoded"]&&(this.adParameters=Ir.decodeXMLText(this.adParameters)))}isSupported(){return!0}get hasInvalidResource(){return this.RC}OC(t){return t.map((t=>new Cr(t))).filter((t=>t.isSupported()))}}class Mr{constructor(t){if(this.id=void 0,this.sequence=void 0,this.adId=void 0,this.linear=void 0,this.nonLinear=void 0,this.id=t.keyAttributes.id,this.sequence=t.keyAttributes.sequence,this.adId=t.keyAttributes.adid,t.linear)try{this.linear=new kr(t.linear)}catch(t){(0,p.n)({callStack:t.stack,level:p.D.WARN,exception:t.message,message:"Creative_Linear"})}if(t.nonlinearads)try{this.nonLinear=new Er(t.nonlinearads)}catch(t){(0,p.n)({callStack:t.stack,level:p.D.WARN,exception:t.message,message:"Creative_NonLinear"})}}isSupported(){return!0}}class Lr{constructor(t,i){this.name=t.keyAttributes.event,this.uri=Ir.getKeyValue(t),"progress"===this.name&&(this.offset=(0,Pr.QI)(t.keyAttributes.offset,i))}}class Br{constructor(t){var i,e;this.url=t.keyValue,this.apiFramework=null===(i=t.keyAttributes)||void 0===i?void 0:i.apiframework,this.browserOptional=null===(e=t.keyAttributes)||void 0===e?void 0:e.browseroptional}}class Rr{constructor(t){var i,e;try{this.vendor=t.keyAttributes.vendor,t.javascriptresource&&(this.javaScriptResource=new Br(t.javascriptresource)),this.verificationParameters=null===(i=t.verificationparameters)||void 0===i?void 0:i.keyValue,this.trackingEvents=(null===(e=t.trackingevents)||void 0===e?void 0:e.tracking)?wr.parseTrackingEvents((0,S.qo)(null==t?void 0:t.trackingevents.tracking)):[]}catch(t){(0,p.n)({message:"OMID_Verification_parse_error",level:p.D.WARN,callStack:t.stack,exception:t.message})}}}!function(t){function i(t){const i=[];return void 0!==t[0]&&t.forEach((t=>{i.push(Ir.getKeyValue(t))})),i}t.parseImpressions=function(t){return i(t)},t.parseCretives=function(t){const i=[];return t.forEach((t=>{i.push(new Mr(t))})),i},t.parseExtensions=function(t){return t.map((t=>new br(t)))},t.parseVerifications=function(t){return t.map((t=>new Rr(t)))},t.parseErrors=function(t){return i(t)},t.parseTrackingEvents=function(t,i){const e=[];return void 0!==t[0]&&t.forEach((t=>{e.push(new Lr(t,i))})),e}}(wr||(wr={}));class Or{constructor(t){var i,e,s;this.description=void 0,this.advertiser=void 0,this.surveys=void 0,this.errors=void 0,this.pricing=void 0,this.extensions=void 0,this.adVerifications=void 0,this.adTitle=Ir.getKeyValue(t.adtitle),this.adSystem=Ir.getKeyValue(t.adsystem),this.impressions=wr.parseImpressions((0,S.qo)(t.impression)),this.creatives=(null===(i=t.creatives)||void 0===i?void 0:i.creative)?wr.parseCretives((0,S.qo)(t.creatives.creative)):[],this.description=Ir.getKeyValue(t.description),this.advertiser=Ir.getKeyValue(t.advertiser),this.surveys=Ir.getKeyValue(t.survey),this.errors=wr.parseErrors((0,S.qo)(t.error)),this.pricing=Ir.getKeyValue(t.pricing),this.extensions=(null===(e=t.extensions)||void 0===e?void 0:e.extension)?wr.parseExtensions((0,S.qo)(t.extensions.extension)):[],this.adVerifications=(null===(s=t.adverifications)||void 0===s?void 0:s.verification)?wr.parseVerifications((0,S.qo)(t.adverifications.verification)):[]}isSupported(){return!0}}class Dr{constructor(t){var i,e,s;this.adSystem=void 0,this.impressions=[],this.VASTAdTagURI=void 0,this.creatives=[],this.errors=void 0,this.fallowAdditionalWrappers=void 0,this.allowMultipleAds=void 0,this.fallbackOnNoAd=void 0,this.adVerifications=void 0,this.extensions=void 0,this.adSystem=Ir.getKeyValue(t.adsystem),this.impressions=wr.parseImpressions((0,S.qo)(t.impression)),this.VASTAdTagURI=Ir.getKeyValue(t.vastadtaguri),this.creatives=(null===(i=t.creatives)||void 0===i?void 0:i.creative)?wr.parseCretives((0,S.qo)(t.creatives.creative)):[],this.errors=wr.parseErrors((0,S.qo)(t.error)),this.fallowAdditionalWrappers=!t.keyAttributes.followadditionalwrappers||t.keyAttributes.followadditionalwrappers,this.allowMultipleAds=t.keyAttributes.allowmultipleads,this.fallbackOnNoAd=t.keyAttributes.fallbackonnoad,this.adVerifications=(null===(e=null==t?void 0:t.adverifications)||void 0===e?void 0:e.verification)?wr.parseVerifications((0,S.qo)(t.adverifications.verification)):[],this.extensions=(null===(s=null==t?void 0:t.extensions)||void 0===s?void 0:s.extension)?wr.parseExtensions((0,S.qo)(t.extensions.extension)):[]}}class Vr{constructor(t){Array.isArray(t)?this.DC(t):this.VC(t)}isSupported(){return!0}VC(t){this.id=t.keyAttributes.id,this.sequence=t.keyAttributes.sequence,t.inline?this.inLine=new Or(t.inline):t.wrapper&&(this.wrapper=new Dr(t.wrapper))}DC(t){const i=t.filter((t=>{const i=this.NC(t).filter((t=>t.linear));return!!(0,S.BZ)(i)}));(0,S.BZ)(i)&&this.VC(i[0])}NC(t){return t.inline?(0,S.qo)(t.inline.creatives.creative):t.wrapper?(0,S.qo)(t.wrapper.creatives.creative):[]}}!function(t){t[t.Empty=0]="Empty",t[t.BadWrapper=1]="BadWrapper",t[t.MediaNotFound=2]="MediaNotFound"}(Sr||(Sr={}));class Fr{constructor(t=2){this.jC=t}parseVastXml(t){var i,e;try{if(!Ir.isValidXMLString(t))return{hasError:!0,vastErrorCode:Te.XmlParsingError,errorReason:De.XmlInvalidString};if(this.$C(t))return{hasError:!0,vastErrorCode:Te.GeneralError,errorReason:De.XmlInvalidAd};const s=(new DOMParser).parseFromString(t,"application/xml"),n=new Ir.JXONTree(s.documentElement);if(!this.UC(n))return{hasError:!0,vastErrorCode:Te.VastSchemaError,errorReason:De.XmlInvalidTree};if(!this.qC(n,this.jC))return{hasError:!0,vastErrorCode:Te.InvalidVastVersionError,errorReason:De.VastVersionNotSupported};const r=new Vr(n.ad);let o=[],h=[];(0,S.BZ)(null===(i=null==r?void 0:r.inLine)||void 0===i?void 0:i.creatives)&&(o=r.inLine.creatives.filter((t=>{var i;return(0,S.BZ)(null===(i=null==t?void 0:t.linear)||void 0===i?void 0:i.mediaFiles)})),h=null===(e=null==r?void 0:r.inLine)||void 0===e?void 0:e.creatives.filter((t=>{var i;return(0,S.BZ)(null===(i=null==t?void 0:t.nonLinear)||void 0===i?void 0:i.nonLinearAdList)})));const a=this.HC(r,o,h);return a.isValid?this.zC(r,h)?{hasError:!1,result:r}:{hasError:!0,vastErrorCode:Te.MediaFileNotSupported,errorReason:De.VastMediaFilesNotSupported,errorUrlTrackers:this.WC(r)}:a.reason===Sr.MediaNotFound&&this.GC(r)?{hasError:!0,vastErrorCode:Te.NonlinearSupportedTypeNotFound,errorReason:De.XmlInvalidAd,errorUrlTrackers:this.WC(r)}:{hasError:!0,vastErrorCode:Te.VastSchemaError,errorReason:De.XmlInvalidAd}}catch(t){return{hasError:!0,vastErrorCode:Te.GeneralError,errorReason:De.XmlParseGeneral}}}WC(t){var i;const e=[];return null===(i=null==t?void 0:t.inLine)||void 0===i||i.errors.forEach((t=>{e.push({url:t,type:v.ProtoTrackerType.Image})})),e}GC(t){var i,e;return null===(e=null===(i=t.inLine)||void 0===i?void 0:i.creatives)||void 0===e?void 0:e.some((t=>{var i;return null===(i=t.nonLinear)||void 0===i?void 0:i.hasInvalidResource}))}zC(t,i){var e,n;if((0,s.$K)(t.wrapper))return!0;null===(e=null==t?void 0:t.inLine)||void 0===e||e.creatives.forEach((t=>{var i;(0,S.BZ)(null===(i=null==t?void 0:t.linear)||void 0===i?void 0:i.mediaFiles)&&(t.linear.mediaFiles=this.XC(t.linear.mediaFiles))}));const r=null===(n=null==t?void 0:t.inLine)||void 0===n?void 0:n.creatives.reduce(((t,i)=>{var e;return(0,S.BZ)(null===(e=null==i?void 0:i.linear)||void 0===e?void 0:e.mediaFiles)?[...t,...i.linear.mediaFiles]:t}),[]);return!(!(0,S.BZ)(r)&&!(0,S.BZ)(i))}XC(t){return t.filter((t=>t.isSupported))}$C(t){return An.KEYWORDS_FOR_BANNED_VAST.some((i=>t.includes(i)))}qC(t,i){const e=parseInt(t.keyAttributes.version,10);return!(e&&e<i)}UC(t){return!!t.ad}HC(t,i,e){const s=t.wrapper;return t.inLine||s?s&&!s.VASTAdTagURI?{isValid:!1,reason:Sr.BadWrapper}:s||(0,S.BZ)(i)||(0,S.BZ)(e)?{isValid:!0}:{isValid:!1,reason:Sr.MediaNotFound}:{isValid:!1,reason:Sr.Empty}}}const Nr={[v.ProtoCreativeTypeEnum.External]:t=>t.floorPrice||t.customCpm,[v.ProtoCreativeTypeEnum.MediaFile]:t=>t.floorPrice||t.customCpm,[v.ProtoCreativeTypeEnum.ThirdParty]:t=>t.floorPrice||t.customCpm||t.adxFloorPrice,[v.ProtoCreativeTypeEnum.HeaderBidder]:t=>t.prebidjsCPM,[v.ProtoCreativeTypeEnum.Rtb]:t=>Ae(t.obfuscatedPrice),[v.ProtoCreativeTypeEnum.Tam]:t=>Ae(t.obfuscatedPrice),[v.ProtoCreativeTypeEnum.TamDeal]:t=>Ae(t.obfuscatedPrice),[v.ProtoCreativeTypeEnum.TamPrivateAuction]:t=>Ae(t.obfuscatedPrice)};class jr{static getBidPriceByCreative(t,i){return(0,Nr[t])(i)}}var $r,Ur,qr,Hr=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class zr{constructor(t){this.QC=t}fetchBid(t){return Hr(this,void 0,void 0,(function*(){const i=this.JC(t),e={bidPrice:i.price,bidId:i.bidId,yoScore:i.yoScore,isIma:i.isIma,encryptedPrice:t.requestMetadata.data.encryptedPrice,adManagerLineItem:t.lineItem};let s;try{fr.notifyBidFetchStart(this.QC.adEvents,e),s=yield this.YC(t,i)}catch(t){throw(0,h.W$)(t)}finally{fr.notifyBidFetchEnd(this.QC.adEvents,e)}return s.shouldBeDiscarded=e.shouldBeDiscarded,s}))}YC(t,i){return Hr(this,void 0,void 0,(function*(){const e=t.url||i.adManagerLineItem.protoLineItem.adTag||"",n=t.vastTag;switch(t.lineItem.protoLineItem.creativeType){case v.ProtoCreativeTypeEnum.External:case v.ProtoCreativeTypeEnum.ThirdParty:return t.lineItem.protoLineItem.adType===v.ProtoAdType.Overlay?this.KC(i):this.ZC(e,i,t);case v.ProtoCreativeTypeEnum.MediaFile:return this.tE(i);case v.ProtoCreativeTypeEnum.Rtb:return this.iE(i,t);case v.ProtoCreativeTypeEnum.HeaderBidder:return(0,s.QM)(n)?this.eE(n,i,t):this.ZC(e,i,t);case v.ProtoCreativeTypeEnum.Tam:case v.ProtoCreativeTypeEnum.TamDeal:case v.ProtoCreativeTypeEnum.TamPrivateAuction:return this.ZC(e,i,t);default:throw new Error(De.InvalidCreativeType)}}))}JC(t){const{lineItem:i,obfuscatedPrice:e,vastTracker:n,state:r,requestMetadata:o,prebidjsCPM:a,slotId:c,bidId:d,creativeId:l}=t,{globalDomUtilsService:u,viewabilityService:f,adEnforcer:m,os:g,adSlotContainerRecycler:v,urlSuffixerService:y,sessionId:b}=this.QC,{creativeType:I,advertiserLineItemId:w,floorPrice:P,customCpm:A,adxFloorPricePredictionList:_,adType:x,lineItemPriority:T}=i.protoLineItem,k=(0,S.BZ)(_)?Ae(_[0].floorPriceObfuscated):0;let C=jr.getBidPriceByCreative(I,{floorPrice:P,adxFloorPrice:k,customCpm:A,obfuscatedPrice:e,prebidjsCPM:a});(0,s.r)(C)||((0,p.n)({message:"AdManager_BidFactory_no_cpm_on_bid",level:p.D.ERROR},{throttle:1,shouldSendMaxLog:!1}),C=0);const E=this.QC.yoScoreCalculator.calculateBidYoScore(w,{priority:T,cpm:C}),M=this.QC.adContainerMap.get(x);if(!(0,s.$K)(M))throw new Error("AdManager_BidFactory_adContainer_is_undefined");return{adxFloorPricePredictionList:_,adContainer:M,requestMetadata:o,globalDomUtilsService:u,viewabilityService:f,adEnforcer:m,os:g,adSlotContainerRecycler:v,urlSuffixerService:y,sessionId:b,yoScore:E,price:C,vastTracker:n,cpm:a||P||A,adManagerLineItem:i,callingState:r,externalCreativeId:l,bidId:d||(0,h.qs)(),bidSlotId:c||fs(),isIma:fr.isImaLineItem(i)}}sE(t,i){const{mime:e,html:n,dimensions:r}=i;if(!(0,s.$K)(e)||!(0,s.$K)(n)||!(0,s.$K)(r))throw new Error(De.HTMLNotEnoughData);if(!fr.isValidHtmlMimeType(e))throw new Error(De.HTMLUnknownMimeType);return new Pn(this.QC.timerService,Object.assign(Object.assign({},t),{html:n,mime:e,dimensions:r}))}tE(t){return Hr(this,void 0,void 0,(function*(){return new qn(this.QC.timerService,Object.assign(Object.assign({},t),{hlsModule:yield fr.getHlsModule(this.QC.globalDomUtilsService.global,t.adManagerLineItem.protoLineItem.externalHlsFile),mediaId:t.adManagerLineItem.protoLineItem.mediaCreativeId,renditions:t.adManagerLineItem.protoLineItem.renditions,clickUrl:t.adManagerLineItem.protoLineItem.mediaCreativeClickUrl,externalMediaFile:t.adManagerLineItem.protoLineItem.externalMediaFile,externalHlsFile:t.adManagerLineItem.protoLineItem.externalHlsFile,shouldPauseAdWhenFinished:this.QC.shouldPauseAdWhenFinished,shouldLoopAdWhenFinished:this.QC.shouldLoopAdWhenFinished,isInApp:this.QC.isInApp,pageDomain:this.QC.pageDomain}))}))}KC(t){return new mn(this.QC.timerService,Object.assign(Object.assign({},t),{adxAdUnitPath:fr.getAdUnitPath(t.adManagerLineItem.protoLineItem.adTag),domain:this.QC.pageDomain}))}ZC(t,i,e,s){return Hr(this,void 0,void 0,(function*(){const n=fr.getFinalUrl(t,i,this.QC.adMacroReplacer,this.QC.imaVastUrlBuilderService),r=fr.isImaUrl(n);if(i.isIma||r){if(i.adManagerLineItem.protoLineItem.adType!==v.ProtoAdType.Nonlinear)return this.nE(i,{url:n});(0,p.n)({message:"AdManager_BidFactory_found_ima_in_nonLinear",level:p.D.INFO,sessionId:i.sessionId})}return this.rE(n,i,e,s)}))}nE(t,i){return Hr(this,void 0,void 0,(function*(){const e=(0,s.$K)(i.url)?i.url:"",n=(0,s.$K)(i.xml)?i.xml:"",r=L.h.getSessionChildContainer(t.sessionId).resolve(Qs.P);return r.isImaTestCaseForSS()||r.isMarriageDotComDomain()||r.isDailykosDotComDomain()?this.oE(e,n,t):this.hE(e,n,t)}))}oE(t,i,e){return new Xn(this.QC.timerService,Object.assign(Object.assign({},e),{pageUrl:this.QC.pageUrl,url:t,xml:i,vastAd:i}))}hE(t,i,e){return Hr(this,void 0,void 0,(function*(){const s=this.QC.adSlotContainerRecycler.requestAdSlotIma(e.adContainer),n={url:t,xml:i,pageUrl:this.QC.pageUrl,sessionId:e.sessionId,adContainerState:e.callingState.adContainerState,advertiserLineItemId:e.adManagerLineItem.protoLineItem.advertiserLineItemId,adType:e.adManagerLineItem.protoLineItem.adType,adSlotContainerRecycler:e.adSlotContainerRecycler,adxFloorPricePredictionList:e.adxFloorPricePredictionList};let r;const o=new vr(s,n);try{r=yield o.getImaAdModule()}catch(t){throw(0,h.W$)(t)}return new En(this.QC.timerService,Object.assign(Object.assign({},e),{imaSdk:r.imaSdk,imaAdsLoader:r.imaAdsLoader,imaAdsManager:r.imaAdsManager,requestAdsContext:r.requestAdsContext,pageUrl:this.QC.pageUrl,imaAdSlotContainer:s,url:t,vastAd:i||t}))}))}rE(t,i,e,n){return Hr(this,void 0,void 0,(function*(){const r=(0,s.$K)(e.shouldRequestWithCredentials)?e.shouldRequestWithCredentials:dr.SHOULD_CALL_WITH_CREDENTIALS_DEFAULT;let o="";try{o=yield Bt.n.fetchXMLRequest(t,r)}catch(t){if(!1===r)throw new yr({hasError:!0,errorReason:De.NetworkRequestUrl,vastErrorCode:Te.WrapperVastUriTimeout})}if(!(0,s.QM)(o)){try{o=yield Bt.n.fetchXMLRequest(t,!1)}catch(t){throw new yr({hasError:!0,errorReason:De.NetworkRequestUrl,vastErrorCode:Te.WrapperVastUriTimeout})}if(!(0,s.QM)(o))throw new yr({hasError:!0,errorReason:De.XmlInvalidString,vastErrorCode:Te.NoVastResponseAfterWrapper})}return this.eE(o,i,e,n)}))}eE(t,i,e,n){return Hr(this,void 0,void 0,(function*(){const r=new Fr(dr.MIN_VAST_VERSION).parseVastXml(t);if(!0===r.hasError){const{errorReason:t,vastErrorCode:i,errorUrlTrackers:e}=r;throw new yr({hasError:!0,errorUrlTrackers:e,errorReason:t,vastErrorCode:i})}const o=(0,s.$K)(n)?n.vastAdsChain:[];if(fr.setVastInfo(r.result,i,o),r.result.wrapper){const t=(0,s.$K)(n)?n.maxWrapperLimit:dr.DEFAULT_MAX_WRAPPER_LIMIT;if(t<=0)throw new yr({hasError:!0,errorReason:De.XmlAdaptorWrapperLimit,vastErrorCode:Te.WrapperLimitReached});return this.ZC(r.result.wrapper.VASTAdTagURI,i,e,{vastAdsChain:o,maxWrapperLimit:t-1})}const{adType:h}=i.adManagerLineItem.protoLineItem;if(!fr.haveExpectedAdType(o,h))throw new yr({hasError:!0,errorReason:De.InvalidCreativeType,vastErrorCode:Te.ExpectingDifferentLinearity});return h===v.ProtoAdType.Nonlinear?new Wn(this.QC.timerService,Object.assign(Object.assign({},i),{vastResponse:new ur(o)})):new cr(this.QC.timerService,Object.assign(Object.assign({},i),{vastResponse:new ur(o),shouldLoopAdWhenFinished:this.QC.shouldLoopAdWhenFinished,adMacroReplacer:this.QC.adMacroReplacer,vastAd:t}))}))}iE(t,i){return Hr(this,void 0,void 0,(function*(){const e=fr.isVideoAd(t),n=fr.isNonlinearVideoAd(t),r=t.isIma;if(e||n){if(!(0,s.$K)(i.vastTag))throw new Error(De.InvalidCreativeUrl);return r?this.nE(t,{xml:i.vastTag}):this.eE(i.vastTag,t,i)}return this.sE(t,i)}))}}!function(t){t[t.IDLE=0]="IDLE",t[t.RUNNING=1]="RUNNING",t[t.STOPPING=2]="STOPPING"}($r||($r={}));class Wr{constructor(t){this.aE=t,this.ir=$r.IDLE,this.cE=Promise.resolve()}start(){(this.ir===$r.IDLE||this.ir===$r.STOPPING)&&(this.ir=$r.RUNNING,this.dE())}stop(){this.ir=$r.STOPPING}setPromiseNotifier(t){return this.lE=t,this}setIdleNotifier(t){return this.uE=t,this}getState(){return this.ir}fE(){const t=this.aE();void 0!==t?this.cE=t.then((t=>{this.lE&&this.lE(t)})).then((()=>{this.ir===$r.STOPPING&&(this.ir=$r.IDLE)})):this.ir=$r.IDLE}dE(){this.ir===$r.IDLE?this.uE&&this.uE():this.ir===$r.RUNNING&&(this.fE(),this.cE.then((()=>{this.dE()})))}}class Gr{constructor(t,i=1){this.aE=t,this.mE=i,this.gE=[],this.vE(i)}start(){return this.gE.forEach((t=>{t.start()})),this}stop(){return this.gE.forEach((t=>{t.stop()})),this}setPromiseNotifier(t){return this.gE.forEach((i=>{i.setPromiseNotifier(t)})),this}setAllThreadsIdleNotifier(t){return this.yE=t,this.bE(),this}setNumberOfThreads(t){if(t<=0)return;this.mE=t;const i=t-this.mE;i>0?this.vE(i):i<0&&this.IE(i)}getState(){return this.gE.reduce(((t,i)=>(t[i.getState()]++,t)),{[$r.IDLE]:0,[$r.RUNNING]:0,[$r.STOPPING]:0})}vE(t){for(let i=0;i<t;i++){const t=new Wr(this.aE).setPromiseNotifier(this.lE);this.gE.push(t)}}IE(t){t=Math.min(t,this.gE.length);for(let i=0;i<t;i++)this.gE.pop().stop()}bE(){const t=()=>{this.getState()[$r.IDLE]===this.gE.length&&this.yE()};this.gE.forEach((i=>{i.setIdleNotifier(t)}))}}class Xr{}Xr.IMA_CORRELATOR_LENGTH=10,Xr.IMA_SCOR_LENGTH=10,function(t){t.DoesNotApply="0",t.Applies="1"}(Ur||(Ur={})),function(t){t.PersonalizedAds="0",t.NonPersonalizedAds="1"}(qr||(qr={}));class Qr{constructor(t,i){this.Dc=t,this.Rd=i}static uk(t){return`${t.width}x${t.height}`}appendParams(t,i){if(!this.SE()||this.Dc.isInApp)return t;const e=new URL(t);return e.searchParams.set("tfcd","0"),e.searchParams.set("gdfp_req","1"),e.searchParams.set("unviewed_position_start","1"),e.searchParams.set("env","vp"),e.searchParams.set("hl","en"),e.searchParams.set("sdk_apis","1,2"),e.searchParams.set("output","vast"),e.searchParams.set("correlator",String((0,h.Ae)(Xr.IMA_CORRELATOR_LENGTH))),e.searchParams.set("sid",(0,h.qs)()),e.searchParams.set("scor",String((0,h.Ae)(Xr.IMA_SCOR_LENGTH))),e.searchParams.set("url",this.PE()),e.searchParams.set("description_url",this.PE()),e.searchParams.set("sz",Qr.uk(i)),e.searchParams.set("gdpr",this.AE()),e.searchParams.set("npa",this._E()),this.Rd.isPersonalisedAdsAllowed()&&e.searchParams.set("gdpr_consent",this.xE()),e.href}SE(){return(0,s.QM)(this.Dc.pageUrl)&&"true"===(0,a.Ph)("cnxImaTest",this.Dc.pageUrl)}PE(){return(0,s.QM)(this.Dc.pageUrl)?encodeURIComponent(this.Dc.pageUrl):""}AE(){return this.Rd.isConsentRequired()?Ur.Applies:Ur.DoesNotApply}xE(){return(0,s.QM)(this.Rd.getConsentPayload())?this.Rd.getConsentPayload():""}_E(){return this.Rd.isPersonalisedAdsAllowed()?qr.PersonalizedAds:qr.NonPersonalizedAds}}var Jr=r(8395),Yr=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class Kr{constructor(t,i){this.settings=t,this.zc=i,this.TE=new Map,this.Fc=[],this.kE=!1,this.CE=new J.x,this.EE=new J.x,this.ME=new J.x,this.LE=new J.x,this.BE=()=>{const t=this.RE();if(t)return this.CE.next(t.lineItemList),this.OE(t.lineItemList,t.state).then((()=>{this.EE.next(t.lineItemList),this.FE()})).catch((()=>{this.EE.next(t.lineItemList),this.FE()}));this.settings.auctionManager.onNothingToCall()},this.settings.adSelector.getAllLineItems().forEach((t=>{t.hasAggregator?t.protoLineItem.timeBetweenRequests=10:t.protoLineItem.timeBetweenRequests=6})),this.Fc.push(this.settings.lineItemServices.lineItemServicesTimer.onTimer().subscribe((()=>{this.NE()})),this.settings.adSelector.getBidEvents(Ie.ON_BID_LOADING).subscribe((()=>{this.NE()})),this.settings.adSelector.getBidEvents(Ie.ON_BID_LOADING_CONSUMED).subscribe((()=>{this.NE()})),this.settings.adSelector.getBidEvents(Ie.ON_BID_LOADED_CONSUMED).subscribe((()=>{this.NE()}))),this.jE=new Gr(this.BE,5),this.$E=new Qr(this.settings.generalRepository,this.settings.app.services.UserManagerService);const e=L.h.getGlobalContainer().resolve(Jr.f);this.UE=new zr({globalDomUtilsService:this.settings.app.services.GlobalDomUtilsService,viewabilityService:this.settings.app.services.ViewabilityService,timerService:e,adEnforcer:this.settings.adEnforcer,os:this.settings.os,adSlotContainerRecycler:this.settings.adSlotContainerRecycler,yoScoreCalculator:this.settings.yoScoreCalculator,urlSuffixerService:this.settings.app.services.UrlSuffixerService,interactionService:this.settings.app.services.InteractionService,sessionId:this.settings.app.config.sessionId,pageUrl:this.settings.app.config.pageUrl,pageDomain:this.settings.app.config.pageDomain,adContainerMap:this.settings.adContainerMap,shouldPauseAdWhenFinished:this.settings.pauseAdWhenFinished,shouldLoopAdWhenFinished:this.settings.loopAdWhenFinished,isInApp:this.settings.app.config.isInApp,adEvents:this.zc,adMacroReplacer:this.settings.adMacroReplacer,imaVastUrlBuilderService:this.$E}),this.settings.adSelector.hasAggregatorType(Ne.Rtb)&&this.TE.set(Ne.Rtb,{auctionPending:!1,caller:new Es(this.settings.playerData.isOutstream,this.settings.skipAdSettings,this.settings.app,this.settings.generalRepository,this.settings.adRequestGatekeeper,this.settings.lineItemAbTestInformation)}),this.settings.adSelector.hasAggregatorType(Ne.HeaderBidder)&&this.TE.set(Ne.HeaderBidder,{auctionPending:!1,caller:new xs(this.settings.playerData,this.settings.schainSettings,this.settings.app,this.settings.appSettings,this.settings.skipAdSettings)}),this.settings.adSelector.hasAggregatorType(Ne.Tam)&&this.TE.set(Ne.Tam,{auctionPending:!1,caller:new qs(this.settings.app,this.settings.amazonSlotId,this.settings.generalRepository)}),this.jE.setAllThreadsIdleNotifier((()=>{this.settings.lineItemServices.lineItemServicesTimer.start()}))}get onLineItemsRequestStart(){return this.CE.asObservable()}get onLineItemsRequestEnd(){return this.EE.asObservable()}get onBid(){return this.ME.asObservable()}get onFirstAggregatedBatchFinished(){return this.LE.asObservable()}call(t){this.jE.setNumberOfThreads(t.maxParallelCalls),this.qE=t,this.kE=!0,this.NE()}stop(){this.kE=!1,this.jE.stop()}setMacros(t){const i=this.TE.get(Ne.HeaderBidder);i&&i.caller.setMacros(t)}destroy(){this.stop(),this.settings.callingValidationAggregator.destroy(),(0,it.i)(this.Fc)}FE(){let t=!0;this.TE.forEach((i=>{i.auctionPending&&(t=!1)})),t&&this.LE.next()}NE(){this.kE&&this.jE.start()}RE(){const t=this.qE.stateSettings.currentState||this.qE.stateSettings.predictedState;if(!t)return void(0,p.n)({message:"AdCallerController_no_state",level:p.D.INFO},{throttle:10,shouldSendMaxLog:!1});const i=this.settings.adSelector.getAllCallableLineItems(t),e=this.settings.adSelector.getBestCallableLineItem(i,t);return e||void 0}OE(t,i){return t[0].hasAggregator?this.HE(t,i):this.zE(t[0],i)}WE(t,i,e){if((0,s.$K)(e))return e;const n=this.GE(t),r=new Fe(n),o=new Le,h={lineItem:t,vastTracker:o,requestMetadata:r,state:i};return Be(t.protoLineItem.trackers,o),h}zE(t,i,e){return Yr(this,void 0,void 0,(function*(){const n=Date.now(),r=this.WE(t,i,e);(0,s.$K)(e)||this.QE(t);let o=null;try{o=yield this.UE.fetchBid(r),this.JE(o,n)}catch(e){const s=null==e?void 0:e.vastErrorCode,o=null==e?void 0:e.vastErrorTrackers,h=Ve[e.message]?Ve[e.message]:v.ConnatixNoBidReasonEnum.RequestException;this.YE(i,t,h,r.requestMetadata,r.vastTracker,Date.now()-n,De[e.message],s,o)}}))}GE(t){let i={requestNumber:t.historicalMetrics.requestNumber};const{adxFloorPricePredictionList:e}=t.protoLineItem;if(e&&(0,S.BZ)(e)){const t=e[0],{predictedPriceObfuscated:s,floorPriceObfuscated:n}=t,r=Ae(s),o=Ae(n);i=Object.assign(Object.assign({},i),{floorPriceInformation:{adxPredictedFloorPrice:r},requestedFloorPrice:o})}return i}QE(t){this.settings.callingValidationAggregator.registerRequestForLineItem(t,this.KE()),t.historicalMetrics.requestNumber++}JE(t,i){try{this.ZE(t,Date.now()-i)}catch(t){(0,p.n)({message:"AdManager_AdCallerController_handleBidFactoryRequestSuccess",exception:t.message,callStack:t.stack,level:p.D.CRITICAL},{throttle:5})}}HE(t,i){const e=this.TE.get(je[t[0].protoLineItem.creativeType]);t.forEach((t=>t.aggregators.add(e.caller))),e.auctionPending=!0;const s={lineItemRequestDataList:t.map((t=>({adManagerLineItem:t,maxAvailableRequests:this.settings.lineItemServices.requestCapsService.getAvailableRequestsForLineItem(t,this.KE())}))),callingState:i,maxAdDuration:i.adBreakState.maxAdDuration,maxBidPrice:this.settings.adSelector.getBestAllowedBidPrice(i)};return this.tM(e,s,t,i)}tM(t,i,e,s){return t.caller.request(i).then((i=>{i.bids.length||i.noBids.length||e.forEach((t=>{this.QE(t)})),e.forEach((i=>{i.aggregators.delete(t.caller),i.historicalMetrics.requestNumber++})),i.noBids.forEach((t=>{this.settings.callingValidationAggregator.registerRequestForLineItem(t.lineItem,this.KE()),this.YE(s,t.lineItem,t.reason,t.requestMetadata)}));const n=i.bids.map((t=>(this.settings.callingValidationAggregator.registerRequestForLineItem(t.lineItem,this.KE()),this.zE(t.lineItem,t.state,t))));return Promise.all(n)})).finally((()=>{t.auctionPending=!1}))}ZE(t,i){if(t.shouldBeDiscarded)return;const e=t.settings.adManagerLineItem,s=t.settings.requestMetadata,r=t.settings.requestMetadata.data.floorPriceInformation;let o={shouldTrackBid:!t.settings.requestMetadata.data.requestTrackingHandledByServer,advertiserLineItemId:e.protoLineItem.advertiserLineItemId,publisherLineItemId:e.protoLineItem.publisherLineItemId,impressionTrackers:t.settings.vastTracker.adImpression};o.shouldTrackBid&&(o=Object.assign(Object.assign({},o),{requestedFloorPrice:s.data.requestedFloorPrice,requestsCount:s.data.requestNumber,isUserSynced:s.data.isUserSynced,prebidJsBidderName:s.data.prebidJsBidderName,customClientPrice:t.settings.cpm,timeSpentMs:i,rtbDspId:s.data.dspId,encryptedPrice:s.data.encryptedPrice,rtbADomain:s.data.rtbAdomain,rtbCreativeId:t.creativeId,rtbSeatId:s.data.rtbSeatId,cnxBidId:t.settings.requestMetadata.data.cnxBidId,floorPriceInformation:r?A.wE.fromProtoFloorPriceInformation(r):void 0,dynamicElkFields:{1:`${n.getConnectionType(this.settings.app.config.deviceType)}`,2:ze.f.getCidForElkTracking()}})),this.zc.adBid.next(o),this.settings.adRequestGatekeeper.addBid(e.protoLineItem.advertiserLineItemId,s.data.requestedFloorPrice),Ys.isBidTargetingAllowedEverInSession(t,t.settings.callingState)?this.ME.next(t):this.settings.auctionInfoLogging.bidIsNotWinnableEverInSession(t)}YE(t,i,e,s,r,o,h,a,c=[]){const d=[...(null==r?void 0:r.adError)||[],...c];if((0,S.BZ)(d)&&Le.trackError(d,this.settings.adMacroReplacer,i.protoLineItem,t,a),!s.data.requestTrackingHandledByServer){const t=s.data.floorPriceInformation,r={advertiserLineItemId:i.protoLineItem.advertiserLineItemId,publisherLineItemId:i.protoLineItem.publisherLineItemId,partnerCustomHeaders:s.data.partnerCustomHeaders,partnerReason:A.EN.fromProtoPrebidPartnerReason(s.data.partnerReason),requestedFloorPrice:s.data.requestedFloorPrice,requestsCount:s.data.requestNumber,isUserSynced:s.data.isUserSynced,prebidJsBidderName:s.data.prebidJsBidderName,playerReason:A.EN.fromProtoPrebidReason(e),timeSpentMs:o,floorPriceInformation:t?A.wE.fromProtoFloorPriceInformation(t):void 0,dynamicElkFields:{1:`${n.getConnectionType(this.settings.app.config.deviceType)}`,2:ze.f.getCidForElkTracking()}};this.zc.adPrebid.next(r)}this.settings.adRequestGatekeeper.addPrebid(i.protoLineItem.advertiserLineItemId)}KE(){return(this.qE.stateSettings.currentState||this.qE.stateSettings.predictedState).adOpportunity.id}}const Zr="uncategorized";class to{resetCapsBasedOnExternalEvent(t){const i=this.wt.keys();for(const e of i)this.iM(e,t)&&this.eM(e,Zr)}resetCapsOnLineItemMetadataUpdate(t){this.eM(t,Zr)}iM(t,i){return t.protoLineItem.resetCapType===i}sM(t){return this.iM(t,v.ProtoResetCapTypeEnum.TimeCapping)&&this.nM(t)>0}}class io{constructor(t){this.oM=t,this.hM=new Map}setNumberOfImpressions({value:t,categoryId:i}){(0,s.$K)(i)&&this.oM===v.ProtoResetCapTypeEnum.OpportunityCapping||(i=Zr),this.hM.set(i,t)}getNumberOfImpressions({categoryId:t}){return(0,s.$K)(t)&&this.oM===v.ProtoResetCapTypeEnum.OpportunityCapping||(t=Zr),this.hM.get(t)||0}}class eo extends to{constructor(t=Date.now()){super(),this.aM=t,this.wt=new Map}canCall(t,i){this.cM(t);const e=this.wt.get(t);return void 0===e||(0===t.protoLineItem.impressionCap||e.getNumberOfImpressions({categoryId:i})<t.protoLineItem.impressionCap)}registerImpressionForLineItem(t,i){let e=this.wt.get(t);return void 0===e&&(this.wt.set(t,new io(t.protoLineItem.resetCapType)),e=this.wt.get(t),this.sM(t)&&(e.nextImpressionCapResetTimestamp=this.dM(this.nM(t)))),e.setNumberOfImpressions({value:e.getNumberOfImpressions({categoryId:i})+1,categoryId:i}),this}registerRequestForLineItem(t,i){return this}destroy(){this.wt.clear()}eM(t,i){var e;null===(e=this.wt.get(t))||void 0===e||e.setNumberOfImpressions({value:0,categoryId:i})}nM(t){return t.protoLineItem.resetImpressionsCapTime*Lt.s_}cM(t,i=Date.now()){if(!this.sM(t))return;const e=this.wt.get(t);void 0!==e&&this.lM(t,i)&&(e.setNumberOfImpressions({value:0}),e.nextImpressionCapResetTimestamp=this.dM(this.nM(t),i))}lM(t,i){return i>=this.wt.get(t).nextImpressionCapResetTimestamp}dM(t,i=Date.now()){const e=Math.ceil((i-this.aM)/t)*t;return this.aM+e}}class so{constructor(t){this.oM=t,this.uM=new Map}setNumberOfRequests({value:t,categoryId:i}){(0,s.$K)(i)&&this.oM===v.ProtoResetCapTypeEnum.OpportunityCapping||(i=Zr),this.uM.set(i,t)}getNumberOfRequests({categoryId:t}){return(0,s.$K)(t)&&this.oM===v.ProtoResetCapTypeEnum.OpportunityCapping||(t=Zr),this.uM.get(t)||0}}class no extends to{constructor(t=Date.now()){super(),this.aM=t,this.allowResetOnTime=!0,this.wt=new Map}canCall(t,i){this.cM(t);const e=this.wt.get(t);return void 0===e||(0===t.protoLineItem.requestCap||e.getNumberOfRequests({categoryId:i})<t.protoLineItem.requestCap)}registerRequestForLineItem(t,i,e=Date.now()){let s=this.wt.get(t);return void 0===s&&(this.wt.set(t,new so(t.protoLineItem.resetCapType)),s=this.wt.get(t),this.sM(t)&&(s.nextRequestCapResetTimestamp=this.dM(this.nM(t)))),s.setNumberOfRequests({value:s.getNumberOfRequests({categoryId:i})+1,categoryId:i}),this}registerImpressionForLineItem(t){return this}getAvailableRequestsForLineItem(t,i){const e=this.wt.get(t);return void 0===e?t.protoLineItem.requestCap:t.protoLineItem.requestCap-e.getNumberOfRequests({categoryId:i})}restoreOneCapForLineItem(t,i){if(t.protoLineItem.ignoreFilledRequests){const e=this.wt.get(t);if(void 0===e)return;const s=e.getNumberOfRequests({categoryId:i});s>0&&e.setNumberOfRequests({value:s-1,categoryId:i})}}destroy(){this.wt.clear()}eM(t,i){var e;null===(e=this.wt.get(t))||void 0===e||e.setNumberOfRequests({value:0,categoryId:i})}nM(t){return t.protoLineItem.resetRequestsCapTime*Lt.s_}cM(t,i=Date.now()){if(!this.sM(t))return;const e=this.wt.get(t);void 0!==e&&this.lM(t,i)&&(e.setNumberOfRequests({value:0}),e.nextRequestCapResetTimestamp=this.dM(this.nM(t),i))}lM(t,i){return i>=this.wt.get(t).nextRequestCapResetTimestamp&&this.allowResetOnTime}dM(t,i=Date.now()){const e=Math.ceil((i-this.aM)/t)*t;return this.aM+e}}class ro{constructor(){this.wt=new Map}registerRequestForLineItem(t,i,e=Date.now()){let s=this.wt.get(t);return void 0===s&&(this.wt.set(t,{}),s=this.wt.get(t)),s.lastRequestTimestamp=e,s.categoryId=i,this}registerImpressionForLineItem(t){return this}canCall(t,i,e=Date.now()){const s=this.wt.get(t);if(void 0===s)return!0;if(0===t.protoLineItem.timeBetweenRequests)return!0;if(e>=s.lastRequestTimestamp+t.protoLineItem.timeBetweenRequests*Lt.s_)return!0;return!(s.categoryId===i||t.protoLineItem.resetCapType!==v.ProtoResetCapTypeEnum.OpportunityCapping)}destroy(){this.wt.clear()}}class oo{constructor(t){this.Ws=t,this.pM=null,this.fM=new J.x}start(){return this.mM(),this}stop(){return this.gM(),this}onTimer(){return this.fM.asObservable()}destroy(){this.gM()}mM(){null===this.pM&&(this.pM=this.Ws.setInterval((()=>{this.fM.next()}),500))}gM(){this.Ws.clearInterval(this.pM),this.pM=null}}class ho{constructor(t,i,e,s){this.vM=t,this.yM=i,this.bM=e,this.Yg=s,this.IM=new J.x,this.wM=new Map,this._M=[],this.forceTriggerUpdateState=()=>{this._M.forEach((t=>this.xM(t)))},this.xM=(t,i)=>{this.wM.set(t,this.TM(this.yM.get(t),i))},this.kM=t=>{this.CM([v.ProtoAdType.Video],t)},this.EM=t=>{this.CM([v.ProtoAdType.Overlay],t)},this.MM=t=>{this.CM([v.ProtoAdType.Nonlinear],t)},this.sa=()=>{this.CM(this._M)},this.CM=(t,i)=>{t.forEach((t=>this.xM(t,i))),this.IM.next()},this.LM={[v.ProtoAdType.Video]:this.kM,[v.ProtoAdType.Overlay]:this.EM,[v.ProtoAdType.Nonlinear]:this.MM},this._M=[...this.yM.keys()],this._M.forEach((t=>this.xM(t))),this.BM()}get onContainerStateUpdate(){return this.IM.asObservable()}getContainerMap(){return this.yM}getContainerStateMap(){return this.wM}getMainContainer(){return this.yM.get(this.vM)}getMainContainerState(){return this.getContainerStateMap().get(this.vM)}destroy(){this.yM.forEach(((t,i)=>{this.bM.off(t,this.sa),this.Yg.off(t,this.LM[i])}))}BM(){this.yM.forEach(((t,i)=>{this.bM.on(t,this.sa),this.Yg.on(t,this.LM[i],{threshold:ei})}))}TM(t,i){let e=i;return void 0===e&&(e=this.Yg.check({element:t,threshold:ei})),{width:t.clientWidth,height:t.clientHeight,viewability:e}}}const ao="cnxpl-vl",co="cnxpl-rf";class lo{constructor(){this.RM=!0,this.OM=new J.x,this.DM=[],this.VM=t=>{if(this.RM)return;const i=t.target;if(i.volume>0&&(i.volume=0,!i.paused)){const t=i.getAttribute(co);this.OM.next(t)}t.preventDefault?t.preventDefault():t.returnValue=!1}}get onVolumeDetected(){return this.OM.asObservable()}enforce(t,i){let e=t;(0,s.cL)(t)&&(e=t.contentDocument||t.contentWindow.document),this.RM=!1;(0,S.Sz)(e.getElementsByTagName("video")).forEach((t=>{this.NM(t,i)}))}stopEnforce(){this.RM=!0}clearEnforce(t){try{const i=[];this.DM=this.DM.filter((e=>e.getAttribute(co)!==t||(i.push(e),!1))),i.forEach((t=>{t.removeAttribute(ao),t.removeAttribute(co),t.removeEventListener("volumechange",this.VM)}))}catch(t){}}NM(t,i){t&&!t.getAttribute("cnxpl-vl")&&(t.volume=0,t.setAttribute(ao,"true"),t.setAttribute(co,i),t.addEventListener("volumechange",this.VM),this.DM.push(t))}}class uo{jM(t){const i=function(){};t.Element.prototype.scrollIntoView=i,t.Element.prototype.scrollIntoViewIfNeeded=i,t.scroll=i,t.scrollTo=i,t.scrollBy=i}enforce(t){(0,s.cL)(t)&&this.jM(t.contentWindow)}stopEnforce(){}clearEnforce(){}}class po{constructor(t){this.$M=t=>t.cnxEnfStorage?t.cnxEnfStorage:null,this.Ci=t;try{this.$M(this.Ci)||this.UM(this.Ci)}catch(t){(0,p.n)({message:"AdManager_EnforcerMemory_bind_enforcement",exception:t.message,callStack:t.stack,level:p.D.CRITICAL})}}UM(t){(0,u.ML)(t.document.head,t,'!function(){function n(n){window["cnx"+n]||(window["cnx"+n]=window[n],window[n]=function(e){var t="";try{e&&(t=function n(e,t){try{if(!e)return"";if(e.cnxInnerTag)return e.cnxInnerTag;if(t<2){var r=t+1;return n(e.caller,r)}}catch(n){return""}return""}(e))}catch(n){}var r=window["cnx"+n].apply(null,arguments);if(t){var i=window.cnxEnfStorage;i[n][t]=i[n][t]||[],i[n][t].push(r)}return r})}window.cnxEnfStorage={setTimeout:{},setInterval:{},eventListeners:{},errors:[]};var e=window.location.hostname.split("."),t=window.btoa(e[e.length-2]+"."+e[e.length-1]);-1===["dG16LmNvbQ==","YmlsbGJvYXJkLmNvbQ==","aG9sbHl3b29kcmVwb3J0ZXIuY29t","dmliZS5jb20=","aG9yb3Njb3BlLmNvbQ==","YXN0cm9sb2d5LmNvbQ==","YWhvcmFtaXNtby5jb20="].indexOf(t)&&(!function(){const n=window.EventTarget?window.EventTarget.prototype:window.document;n.cnxAddEventListener||(n.cnxAddEventListener=n.addEventListener,n.addEventListener=function(n,e,t){var r=this||window;if(e&&e.cnxInnerTag){var i=window.cnxEnfStorage;i.eventListeners[e.cnxInnerTag]=i.eventListeners[e.cnxInnerTag]||[],i.eventListeners[e.cnxInnerTag].push({element:r,type:n,handler:e,options:t})}try{r.cnxAddEventListener(n,e,t)}catch(n){n.message="adlstn_"+n.message,i.errors.push(n)}})}(),n("setTimeout"),n("setInterval"))}();')}enforce(t,i){if((0,s.cL)(t))try{t.contentWindow.self===top||t.contentWindow.Function.prototype.cnxInnerTag||t.contentWindow.Object.defineProperty(t.contentWindow.Function.prototype,"cnxInnerTag",{enumerable:!1,writable:!0,value:i}),t.contentWindow.self===top||t.contentWindow.Object.prototype.cnxInnerTag||t.contentWindow.Object.defineProperty(t.contentWindow.Object.prototype,"cnxInnerTag",{enumerable:!1,writable:!0,value:i})}catch(t){}}stopEnforce(){}clearEnforce(t){try{const i=this.$M(this.Ci);i.eventListeners[t]&&(i.eventListeners[t].forEach((t=>{t.element.removeEventListener(t.type,t.handler,t.options)})),i.eventListeners[t]=[]),i.setInterval[t]&&(i.setInterval[t].forEach((t=>this.Ci.clearInterval(t))),i.setInterval[t]=[]),i.setTimeout[t]&&(i.setTimeout[t].forEach((t=>this.Ci.clearTimeout(t))),i.setTimeout[t]=[])}catch(t){}}}class fo{constructor(){this.qM=["viralgains","serving-sys.com","commercialadsdistributor"],this.HM=["beachfrontmedia","commercialadsdistributor"],this.zM=["commercialadsdistributor"],this.WM=["pixel.clearstream.tv","pixel.clrstm.com"],this.GM=new J.x,this.XM=new J.x}get onMalwareDetected(){return this.GM.asObservable()}get onBadUriDetected(){return this.XM.asObservable()}enforce(t,i){if((0,s.cL)(t)){this.JM=i;try{this.YM(t),this.KM(t),this.ZM(t),this.tL(t)}catch(t){}}}stopEnforce(){}clearEnforce(){}iL(t,i,e,s){t.every((t=>!e.includes(t)))&&!i.getAttribute("cnx")&&(i.setAttribute("cnx","true"),this.XM.next({referenceId:this.JM,enforcementMessage:`${s}-${i}`}))}YM(t){const i=t.getAttribute("src");i&&(this.qM.forEach((t=>{i.includes(t)&&this.GM.next({referenceId:this.JM,enforcementMessage:`malware-${t}`})})),this.iL(["//","about:blank","about:self","javascript:"],t,i,"iframe"))}KM(t){(0,S.Sz)(t.contentDocument.getElementsByTagName("script")).forEach((t=>{const i=t.getAttribute("src");i&&(this.HM.forEach((t=>{i.includes(t)&&this.GM.next({referenceId:this.JM,enforcementMessage:`malware-${t}`})})),this.iL(["//"],t,i,"script"))}))}ZM(t){(0,S.Sz)(t.contentDocument.getElementsByTagName("a")).forEach((t=>{const i=t.getAttribute("href");i&&this.zM.forEach((t=>{i.includes(t)&&this.GM.next({referenceId:this.JM,enforcementMessage:`malware-${t}`})}))}))}tL(t){(0,S.Sz)(t.contentDocument.getElementsByTagName("img")).forEach((t=>{const i=t.getAttribute("src");i&&this.WM.forEach((t=>{i.includes(t)&&this.GM.next({referenceId:this.JM,enforcementMessage:`malware-${t}`})}))}))}}class mo{constructor(t,i,e){if(this.eL=e,this.sL=null,this.nL=new Map,this.rL=sn.None,this.oL=300,this.Fc=[],this.hL=new Map,this.b_=new J.x,this.nL.set(sn.MemoryLeak,new po(i)),e||this.nL.set(sn.ScrollHijack,new uo),!t){const t=new lo;this.nL.set(sn.Mute,t),this.Fc.push(t.onVolumeDetected.subscribe((t=>{this.aL(en.VOLUME_DETECTED,t,"")})))}const s=new fo;this.Fc.push(s.onBadUriDetected.subscribe((t=>{this.aL(en.BADURI_DETECTED,t.referenceId,t.enforcementMessage)})),s.onMalwareDetected.subscribe((t=>{this.aL(en.MALWARE_DETECTED,t.referenceId,t.enforcementMessage)}))),this.nL.set(sn.Malware,s)}get onEnforcerEvent(){return this.b_.asObservable()}registerContainer(t,i){this.hL.get(t)||this.hL.set(t,i)}deregisterContainer(t){this.hL.get(t)&&(this.nL.forEach((i=>{i.clearEnforce(this.hL.get(t))})),this.hL.delete(t),this.hL.size||this.stop(sn.All))}start(t){this.eL&&(t^=sn.ScrollHijack),this.rL|=t,null===this.sL&&(this.sL=setInterval((()=>{try{this.hL.forEach(((t,i)=>{this.dL(i,t)}))}catch(t){}}),this.oL))}stop(t){this.rL&=~t,this.rL===sn.None&&(clearInterval(this.sL),this.sL=null),this.nL.forEach(((i,e)=>{t&e&&i.stopEnforce()}))}destroy(){this.stop(sn.All),(0,it.i)(this.Fc),this.hL.forEach(((t,i)=>{this.deregisterContainer(i)}))}dL(t,i){(0,S.Sz)(t.getElementsByTagName("iframe")).forEach((t=>{try{this.dL(t,i)}catch(t){}})),this.nL.forEach(((e,s)=>{this.rL&s&&e.enforce(t,i)}))}aL(t,i,e){let s;this.hL.forEach(((t,e)=>{t===i&&(s=e)})),this.b_.next({message:e,type:t,detectedContainer:s})}}var go=r(3816);class vo{constructor(){this.lL={},this.uL=Date.now()}setOutOfViewAdPrice(t){this.lL.outOfViewAdPrice=t>0?Math.round(1e3*t):t}setOutOfViewAdLineItemId(t){this.lL.outOfViewAdLineItemId=t}setInViewAdPrice(t){this.lL.inViewAdPrice=t>0?Math.round(1e3*t):t}setDistanceWhenOutOfViewStarted(t){this.lL.distanceWhenOutOfViewStarted=Math.round(t)}setTimeUntilNextOpportunity(t){this.lL.timeUntilNextOpportunity=t}get missedImpressionsLogs(){return this.lL.outOfViewTimeRunning=Date.now()-this.uL,this.lL}}class yo{static createRecord(t){const i=new vo;return yo.pL.set(t,i),i}static getPlayerRecord(t){return yo.pL.get(t)}}yo.pL=new Map;class bo{constructor(t,i){this.ci=t,this.zc=i,this.fL=!1,this.mL=void 0,this.gL=!1,this.vL=[],this.Fc=[],this.yL=!1,this.bL=new J.x,this.IL=new J.x,this.EI=new J.x,this.wL=!1,this.SL=-1,this.Fc.push(this.ci.adSelector.getBidEvents(Ie.ON_BID_LOADED).subscribe((()=>{this.PL()})),this.ci.adSelector.getBidEvents(Ie.ON_BID_IN_IMPRESSION).subscribe((t=>{this.AL(t)})),this.ci.adSelector.getBidEvents(Ie.ON_BID_LOADED_CONSUMED).subscribe((t=>{t.started&&t.status!==Ns.INVALIDATED&&this._L(t)})),this.ci.impressionCapsTimer.onTimer().subscribe((()=>{this.PL()})))}get onAdSelected(){return this.bL.asObservable()}get onAdFinished(){return this.IL.asObservable()}start(t){this.xL=t,this.fL=!0,this.PL()}stop(){this.fL=!1}destroy(){this.stop(),(0,it.i)(this.Fc),this.mL&&this.TL()}get onMissedImpression(){return this.EI.asObservable()}PL(){var t;if(!this.fL||this.gL)return;const i=this.ci.adSelector.getBestBidAllowedByStatus([Ns.LOADED],this.xL);if(!i)return;const e=this.mL&&Hs.getSelectionScore(this.mL)<Hs.getSelectionScore(i);this.mL&&this.ci.removeBidIfHigherYoScore&&e?(this.TL(),null===(t=this.mL)||void 0===t||t.stopAd("removeStartedBid"),this.kL(i)):this.mL||this.kL(i)}kL(t){this.mL=t,this.ci.internalAuctionSnapshot.takeSnapshot(this.mL,this.xL,this.xL.adOpportunity.timestamp),this.bL.next(t),this.CL(),this.EL(t),t.startAd()}TL(){this.mL&&(this.mL=void 0,(0,it.i)(this.vL),this.vL=[])}CL(){const t=this.xL.adOpportunity;if(this.LL!==t)return this.LL=t,void(this.SL=0);this.SL++}AL(t){this.gL&&((0,p.n)({message:"AdManager_ABaseBidAdaptor_multipleImpressions",exception:`advertiserLineItemId:${t.settings.adManagerLineItem.protoLineItem.advertiserLineItemId}_creativeId:${t.creativeId}`,callStack:`${t.adMediaType}`,level:p.D.CRITICAL,sessionId:this.ci.sessionId},{throttle:1e3,extraLogsPercentage:5}),(0,p.n)({message:"StartedBidInImpression_bidStatusHistory",exception:`${t.adMediaType}_advertiserLineItemId:${t.settings.adManagerLineItem.protoLineItem.advertiserLineItemId}_creativeId:${t.creativeId}_vastAd:${JSON.stringify(t.settings.vastAd)}`,callStack:`${JSON.stringify(t.bidStatusHistory)}`,level:p.D.INFO,sessionId:this.ci.sessionId},{throttle:1e3})),this.gL=!0,this.yL=this.BL(t.skipOffset,t.getAdDuration()),this.ci.adRequestGatekeeper.addImpression(t.settings.adManagerLineItem.protoLineItem.advertiserLineItemId,t.settings.obfuscatedPrice),this.ci.impressionCapsService.registerImpressionForLineItem(t.settings.adManagerLineItem,this.xL.adOpportunity.id),this.ci.requestCapsService.restoreOneCapForLineItem(t.settings.adManagerLineItem,this.xL.adOpportunity.id);const i=this.ci.auctionInfoLogging.onImpression(t);this.RL(t,i)}_L(t){this.OL(t),this.ci.loopAdWhenFinished?t.resumeAd():this.ci.pauseAdWhenFinished?t.pauseAd():(this.IL.next(t),this.TL(),this.PL())}OL(t){if(this.gL)return this.wL=!1,void(this.gL=!1);if(!t.shouldTrackPostbid)return;const i=this.ci.auctionInfoLogging.onPostBid(t);this.DL(t,i)}VL(t,i){this.wL=!0,t.setOutOfViewAdLineItemId(i.settings.adManagerLineItem.protoLineItem.advertiserLineItemId),t.setOutOfViewAdPrice(i.price);const e=this.FL();t.setInViewAdPrice(e);const s=(0,u.oW)(i.settings.adContainer);t.setDistanceWhenOutOfViewStarted(s.top)}FL(){return this.ci.adSelector.getWinnableBidPricesSortedDesc()[0]||-1}NL(){const t=this.ci.internalAuctionSnapshot.lastSnapshot,i=null==t?void 0:t.firstLoser,e=null==t?void 0:t.allLoserStatusInfo;let n,r,o;return(0,s.$K)(i)&&(n=i.lineItem,o=i.isIma,r=i.status),{firstLoser:i,bidStatus:r,highestLosingBidLineItem:n,allLoserStatusInfo:e,firstLoserIsIma:o}}RL(t,i){var e,r,o,h,a,c,d,l,u;const{adBreakState:f}=this.xL,m=(0,s.hj)((0,$i.oK)(t.getAdDuration(),2))?(0,$i.oK)(t.getAdDuration(),2):0,g=(0,s.hj)((0,$i.oK)(t.declaredDurationInSeconds,2))?(0,$i.oK)(t.declaredDurationInSeconds,2):0,v=m-g,y=(0,Pr.H8)(t.createdTimestamp),b=this.xL.adContainerState.get(t.settings.adManagerLineItem.protoLineItem.adType).viewability;let I;if(b||this.VL(yo.createRecord(this.ci.playerId),t),(0,s.$K)(this.ci.internalAuctionSnapshot.lastSnapshot)){const{winnerDemandType:t,firstLoser:i,firstOpenMarketLoser:e}=this.ci.internalAuctionSnapshot.lastSnapshot;I={winnerDemandType:t,firstLoser:i,firstOpenMarketLoser:e}}else(0,p.n)({message:"AdImpressionerController: No internal auction snapshot found",level:p.D.WARN},{throttle:1,shouldSendMaxLog:!1});const{floorPriceInformation:w,discount:S,liveRampType:P,serverBillingNoticeUrls:_}=t.settings.requestMetadata.data,x=this.NL(),T=(0,s.$K)(x.firstLoser)?100*(t.price-x.firstLoser.customClientPrice):null,k=x.allLoserStatusInfo;let C,E;(0,s.$K)(this.ci.internalAuctionSnapshot.lastSnapshot)&&(C=this.ci.internalAuctionSnapshot.lastSnapshot.auctionEndType,E=this.ci.internalAuctionSnapshot.lastSnapshot.deltaTimestampAdStartAdOpportunity);const M={adPodSlotPosition:f.adPodSlotIndex,adSourceType:A.EN.fromProtoAdSourceType(t.adSourceType),advertiserLineItemId:t.settings.adManagerLineItem.protoLineItem.advertiserLineItemId,publisherLineItemId:t.settings.adManagerLineItem.protoLineItem.publisherLineItemId,customClientPrice:t.settings.cpm,encryptedPrice:t.settings.requestMetadata.data.encryptedPrice,prebidJsBidderName:t.settings.requestMetadata.data.prebidJsBidderName,rtbADomain:t.settings.requestMetadata.data.rtbAdomain,rtbCreativeId:t.creativeId,rtbSeatId:t.settings.requestMetadata.data.rtbSeatId,isUserSynced:t.settings.requestMetadata.data.isUserSynced,timeSpentMs:t.startingTimeMs,vastMediaType:t.adMediaType,rtbDspId:t.settings.requestMetadata.data.dspId,cnxBidId:t.settings.requestMetadata.data.cnxBidId,winToAdLoadedTimeMs:null===(e=t.settings.bidLifecycle)||void 0===e?void 0:e.winToAdLoadedTime,startAdToImpressionTimeMs:null===(r=t.settings.bidLifecycle)||void 0===r?void 0:r.startAdToImpressionTime,impressionDurationSeconds:v,declaredDurationSeconds:g,isExplorationMode:this.ci.explorationMode,requestsCount:t.settings.requestMetadata.data.requestNumber,requestedFloorPrice:t.settings.requestMetadata.data.requestedFloorPrice,floorPriceInformation:w?A.wE.fromProtoFloorPriceInformation(w):void 0,bidElapsedTimeSeconds:y,adBreakType:A.EN.fromProtoAdBreakType(f.adBreakType),liveRampType:P?A.EN.fromProtoLiveRamp(P):void 0,internalAuctionInformation:I?A.W1.fromProtoInternalAuction(I):void 0,auctionInformation:i?A.Ti.fromProtoAuctionInformation(i):void 0,dynamicElkFields:{1:t.settings.requestMetadata.data.rtbRequestId,2:t.settings.requestMetadata.data.auctionBidId,4:`${b}`,5:`${t.settings.adManagerLineItem.protoLineItem.viewability}`,6:`${(0,s.$K)(null===(o=x.highestLosingBidLineItem)||void 0===o?void 0:o.lineItemPriority)?null===(h=x.highestLosingBidLineItem)||void 0===h?void 0:h.lineItemPriority:0}`,7:`${(0,s.$K)(x.bidStatus)?x.bidStatus:null}`,8:`${(0,s.$K)(t.price)?t.price:0}`,9:`${(0,s.$K)(null===(a=x.firstLoser)||void 0===a?void 0:a.customClientPrice)?x.firstLoser.customClientPrice:0}`,11:`${C}`,10:`${(0,s.$K)(null===(c=x.firstLoser)||void 0===c?void 0:c.demandType)?null===(d=x.firstLoser)||void 0===d?void 0:d.demandType:0}`,12:(0,s.hj)(E)?`${E}`:"0",13:`${(0,s.$K)(k)?k.verifyingBidsInAuction:0}`,14:`${(0,s.$K)(k)?k.idleBidsInAuction:0}`,15:`${(0,s.$K)(k)?k.loadingBidsInAuction:0}`,16:`${(0,s.$K)(k)?k.loadedBidsInAuction:0}`,17:`${(0,s.$K)(this.LL.id)?this.LL.id:""}`,18:`${(0,s.$K)(null===(l=x.highestLosingBidLineItem)||void 0===l?void 0:l.creativeType)?null===(u=x.highestLosingBidLineItem)||void 0===u?void 0:u.creativeType:null}`,19:`${(0,s.$K)(x.firstLoserIsIma)?x.firstLoserIsIma:null}`,20:`${T}`,21:`${this.SL}`,22:`${n.getConnectionType(this.ci.deviceType)}`,23:ze.f.getCidForElkTracking()},hasAdSkip:this.yL,discount:S?go.d.fromProtoDiscount(S):void 0,serverBillingNoticeUrls:_};this.zc.adImpression.next(M)}DL(t,i){var e;const{adBreakState:r}=this.xL,o=(0,Pr.H8)(t.createdTimestamp),h=(0,s.$K)(i)?A.EN.fromProtoAuctionPostbidReason(this.ci.auctionInfoLogging.getGeneralPostbidReason(t.errorReason)):void 0,{discount:a,liveRampType:c}=t.settings.requestMetadata.data,d=t.settings.requestMetadata.data.floorPriceInformation;let l,u;(0,s.$K)(this.ci.internalAuctionSnapshot.lastSnapshot)&&(l=this.ci.internalAuctionSnapshot.lastSnapshot.auctionEndType,u=this.ci.internalAuctionSnapshot.lastSnapshot.deltaTimestampAdStartAdOpportunity);const p={adPodSlotPosition:r.adPodSlotIndex,adSourceType:A.EN.fromProtoAdSourceType(t.adSourceType),advertiserLineItemId:t.settings.adManagerLineItem.protoLineItem.advertiserLineItemId,publisherLineItemId:t.settings.adManagerLineItem.protoLineItem.publisherLineItemId,reason:t.errorReason,isBidLoaded:!0,prebidJsBidderName:t.settings.requestMetadata.data.prebidJsBidderName,vastMediaType:t.adMediaType,isUserSynced:t.settings.requestMetadata.data.isUserSynced,rtbSeatId:t.settings.requestMetadata.data.rtbSeatId,rtbADomain:t.settings.requestMetadata.data.rtbAdomain,rtbCreativeId:t.creativeId,timeSpentMs:t.startingTimeMs,rtbDspId:t.settings.requestMetadata.data.dspId,cnxBidId:t.settings.requestMetadata.data.cnxBidId,winToAdLoadedTimeMs:null===(e=t.settings.bidLifecycle)||void 0===e?void 0:e.winToAdLoadedTime,requestsCount:t.settings.requestMetadata.data.requestNumber,requestedFloorPrice:t.settings.requestMetadata.data.requestedFloorPrice,floorPriceInformation:d?A.wE.fromProtoFloorPriceInformation(d):void 0,liveRampType:c?A.EN.fromProtoLiveRamp(c):void 0,bidElapsedTimeSeconds:o,adBreakType:A.EN.fromProtoAdBreakType(r.adBreakType),auctionInformation:i?A.Ti.fromProtoAuctionInformation(i):void 0,auctionReason:h,discount:a?go.d.fromProtoDiscount(a):void 0,dynamicElkFields:{1:`${l}`,2:(0,s.hj)(u)?`${u}`:"0",7:`${(0,s.$K)(this.LL.id)?this.LL.id:""}`,8:`${this.SL}`,9:`${n.getConnectionType(this.ci.deviceType)}`,10:ze.f.getCidForElkTracking()}};this.zc.adPostbid.next(p)}EL(t){this.vL.push(t.onAdSlotViewabilityChanged.subscribe((t=>{if(t&&this.wL){const t=yo.getPlayerRecord(this.ci.playerId);this.EI.next(t),this.wL=!1}})),t.onVpaidEvent.subscribe((i=>{const e=function(t,i){switch(t){case T.AdImpression:return i.adImpression;case T.AdClickThru:return i.adClick;case T.AdStarted:return i.adStarted;case T.AdVideoStart:return i.adVideoStart;case T.AdVideoFirstQuartile:return i.adQuartileFirst;case T.AdVideoMidpoint:return i.adQuartileSecond;case T.AdVideoThirdQuartile:return i.adQuartileThird;case T.AdVideoComplete:return i.adQuartileFourth;case T.AdPaused:return i.adPause;case T.AdPlaying:return i.adResume;case T.AdSkipped:return i.adSkip;case T.AdUserClose:return i.adUserClose;case T.AdUserAcceptInvitation:return i.adUserAcceptInvitation;case T.AdUserMinimize:return i.adUserMinimize;case T.AdError:return i.adError}}(i.type,t.settings.vastTracker);!(0,S.BZ)(e)&&i.type===T.AdImpression&&(t.adSourceType===v.ProtoAdsourceTypeEnum.Vpaid||t.adSourceType===v.ProtoAdsourceTypeEnum.VastMedia)&&(0,p.n)({message:"AdManager_AdImpressionController_tracker_impression_not_found",exception:`creativeId: ${t.creativeId}, advertiserLineItemId: ${t.settings.adManagerLineItem.protoLineItem.advertiserLineItemId}`,level:p.D.CRITICAL},{shouldSendMaxLog:!1});let s;i.type===T.AdError&&(s=i.payload.errorCode||Te.GeneralError),Le.track(e,this.ci.adMacroReplacer,t.settings.adManagerLineItem.protoLineItem,t.settings.callingState,t.getTrackerSlot(),s)}))),this.vL.push(t.onAdViewableImpression.subscribe((i=>{const{publisherLineItemId:e,advertiserLineItemId:s,rtbSeatId:n,dspId:r,rtbAdomain:o}=i,h=t.settings.requestMetadata.data.discount;this.zc.adInView.next({publisherLineItemId:e,advertiserLineItemId:s,rtbSeatId:n,rtbDspId:r,adBreakType:A.EN.fromProtoAdBreakType(this.xL.adBreakState.adBreakType),discount:h?go.d.fromProtoDiscount(h):void 0,hasSkipAd:this.yL,rtbADomain:o}),Le.track(t.settings.vastTracker.adViewableImpression,this.ci.adMacroReplacer,t.settings.adManagerLineItem.protoLineItem,t.settings.callingState)})))}BL(t,i){if((0,s.hj)(t)&&t>=0)return!0;return(0,hi.Xj)(i,this.ci.skipAdSettings)}}const Io={[v.ProtoAdBreakTypeEnum.PreRoll]:"preRoll",[v.ProtoAdBreakTypeEnum.MidRoll]:"midRoll",[v.ProtoAdBreakTypeEnum.PostRoll]:"postRoll"};class wo{constructor(t,i){this.jL=t,this.Rd=i}replace(t,i,e){this.jL.setAdWidth(e.adMacros.adWidth),this.jL.setAdHeight(e.adMacros.adHeight),this.jL.setAdPosition(Io[e.adMacros.adPostion]),this.jL.setErrorCode(e.adMacros.errorCode),e.mediaMacros.mediaDescription&&this.jL.setVideoDescription(e.mediaMacros.mediaDescription),e.mediaMacros.mediaDuration&&this.jL.setVideoDuration(e.mediaMacros.mediaDuration),e.mediaMacros.mediaId&&this.jL.setVideoId(e.mediaMacros.mediaId),e.mediaMacros.mediaTitle&&this.jL.setVideoTitle(e.mediaMacros.mediaTitle),e.mediaMacros.mediaUrl&&this.jL.setVideoUrl(e.mediaMacros.mediaUrl);const s=this.Rd.isConsent(i);this.jL.setGDPR(this.Rd.isConsentRequired()?1:0),this.jL.setConsent(s?1:0),this.jL.setGDPRConsent(this.Rd.getConsentPayload()),this.jL.setNPA(this.Rd.isPersonalisedAdsAllowed()?0:1);const n=this.Rd.getTrackableUser(),r=this.Rd.isConsentConnatix()&&s?n:void 0;return this.jL.setUUID(r),this.jL.setupMacros(t)}}class So{constructor(t,i){this.ci=t,this.$L=i,this.Fc=[],this.Zg=!1,this.UL=()=>{if(this.ci.adSelector.hasReachTheMaxNumberOfReadyBids())return void this.ci.auctionManager.onNothingToWin();const t=this.qL(),{selectedBid:i,state:e}=t;if(!i)return;this.ci.auctionInfoLogging.winBid(i);const{width:s,height:n}=e.adContainerState.get(i.settings.adManagerLineItem.protoLineItem.adType);i.initAd(s,n,this.HL.vastViewMode,this.ci.desiredBitRateForWins,void 0,void 0,e.soundValue);const{vastTracker:r,adManagerLineItem:o}=i.settings;return Le.track(r.adWin,this.ci.adMacroReplacer,o.protoLineItem,e),Promise.resolve()},this.jE=new Gr(this.UL,10),this.Fc.push(this.ci.adSelector.getBidEvents(Ie.ON_BID).subscribe((t=>{const i=this.qL();this.ci.auctionInfoLogging.newBidAdded(t,i),this.zL()})),this.ci.adSelector.getBidEvents(Ie.ON_BID_STARTING).subscribe((()=>{this.zL()})),this.ci.adSelector.getBidEvents(Ie.ON_BID_LOADED_CONSUMED).subscribe((t=>{if(!t.started&&t.status!==Ns.INVALIDATED){const i=this.ci.auctionInfoLogging.onPostBid(t),e=!0;this.WL(t,i,e)}this.zL()})),this.ci.adSelector.getBidEvents(Ie.ON_BID_LOADING_CONSUMED).subscribe((t=>{if(t.status!==Ns.INVALIDATED){const i=this.ci.auctionInfoLogging.onPostBid(t);this.WL(t,i)}this.zL()})),this.ci.impressionCapsTimer.onTimer().subscribe((()=>{this.zL()})))}win(t){this.HL=t,this.jE.setNumberOfThreads(t.maxParallelWins),this.Zg=!0,this.zL()}stop(){this.Zg=!1,this.jE.stop()}destroy(){this.stop(),(0,it.i)(this.Fc)}zL(){this.Zg&&this.jE.start()}qL(){const t=this.HL.stateSettings.currentState||this.HL.stateSettings.predictedState;return this.ci.adSelector.selectBestBidForWin(t)}WL(t,i,e=!1){var n,r,o,h,a;Le.trackError(t.settings.vastTracker.adError,this.ci.adMacroReplacer,t.settings.adManagerLineItem.protoLineItem,t.settings.callingState,t.vastErrorCode);const c=(null===(r=null===(n=this.HL.stateSettings)||void 0===n?void 0:n.currentState)||void 0===r?void 0:r.adBreakState)||(null===(h=null===(o=this.HL.stateSettings)||void 0===o?void 0:o.predictedState)||void 0===h?void 0:h.adBreakState),d=(0,Pr.H8)(t.createdTimestamp),l=(0,s.$K)(i)?A.EN.fromProtoAuctionPostbidReason(this.ci.auctionInfoLogging.getGeneralPostbidReason(t.errorReason)):void 0,{discount:u,liveRampType:p}=t.settings.requestMetadata.data,f=t.settings.requestMetadata.data.floorPriceInformation,m={adPodSlotPosition:c.adPodSlotIndex,adSourceType:A.EN.fromProtoAdSourceType(t.adSourceType),advertiserLineItemId:t.settings.adManagerLineItem.protoLineItem.advertiserLineItemId,publisherLineItemId:t.settings.adManagerLineItem.protoLineItem.publisherLineItemId,reason:t.errorReason,isBidLoaded:e,prebidJsBidderName:t.settings.requestMetadata.data.prebidJsBidderName,vastMediaType:t.adMediaType,isUserSynced:t.settings.requestMetadata.data.isUserSynced,rtbSeatId:t.settings.requestMetadata.data.rtbSeatId,rtbADomain:t.settings.requestMetadata.data.rtbAdomain,rtbCreativeId:t.creativeId,timeSpentMs:t.loadingTimeMs,rtbDspId:t.settings.requestMetadata.data.dspId,cnxBidId:t.settings.requestMetadata.data.cnxBidId,winToAdLoadedTimeMs:null===(a=t.settings.bidLifecycle)||void 0===a?void 0:a.winToAdLoadedTime,requestsCount:t.settings.requestMetadata.data.requestNumber,requestedFloorPrice:t.settings.requestMetadata.data.requestedFloorPrice,floorPriceInformation:f?A.wE.fromProtoFloorPriceInformation(f):void 0,liveRampType:p?A.EN.fromProtoLiveRamp(p):void 0,bidElapsedTimeSeconds:d,auctionInformation:i?A.Ti.fromProtoAuctionInformation(i):void 0,auctionReason:l,discount:u?go.d.fromProtoDiscount(u):void 0,dynamicElkFields:{10:ze.f.getCidForElkTracking()}};this.$L.adPostbid.next(m)}}var Po,Ao;!function(t){t[t.ON_STARTED=0]="ON_STARTED",t[t.ON_END=1]="ON_END"}(Po||(Po={}));class _o{constructor(t){this.ci=t,this.GL=new J.x,this.QL=[],this.JL=!1,this.YL=!1,this.Fc=[]}get onAuctionMechanismEnded(){return this.GL.asObservable()}startNewAuction(t){this.ZL=t.callingState,this.YL=t.waitForNewReadyBid,this.tB(),this.iB(),this.eB(),this.sB()}cancelAuction(){this.tB()}updateState(t){if(this.ZL=t,0===this.QL.length)return;const i=this.ZL.stateSettings.currentState||this.ZL.stateSettings.currentState;if(!i)return;const e=this.ci.adSelector.getLineItemsByRequest(!0).map((t=>t.protoLineItem.advertiserLineItemId)),s=this.ci.adSelector.getAllCallableLineItems(i).map((t=>t.protoLineItem.advertiserLineItemId));this.QL=this.QL.filter((t=>t.isAdCalled||(0,S.d3)(t.lineItemId,s)||(0,S.d3)(t.lineItemId,e))),this.sB()}onNothingToWin(){0!==this.QL.length&&this.QL.every((t=>!0===t.isAdCalled))&&this.sB()}onNothingToCall(){0!==this.QL.length&&(this.nB(),this.sB())}nB(){const t=this.ci.adSelector.getLineItemsByRequest(!0).map((t=>t.protoLineItem.advertiserLineItemId));this.QL=this.QL.filter((i=>!0===i.isAdCalled||!1===i.isAdCalled&&(0,S.d3)(i.lineItemId,t)))}rB(){this.tB(),this.GL.next()}eB(){this.Fc.push(this.ci.adSelector.getLineItemRequestEvents(Po.ON_END).subscribe((t=>{this.oB(t),this.sB()})),this.ci.adSelector.getBidEvents(Ie.ON_BID_LOADED).subscribe((t=>{this.JL=!0,this.sB()})),this.ci.adSelector.getBidEvents(Ie.ON_BID_LOADING_CONSUMED).subscribe((t=>{this.sB()})))}oB(t){this.QL.forEach((i=>{t.some((t=>t.protoLineItem.advertiserLineItemId===i.lineItemId))&&(i.isAdCalled=!0)}))}hB(){(0,it.i)(this.Fc)}sB(){if(0!==this.QL.length){if((!this.YL||this.JL)&&this.QL.every((t=>!0===t.isAdCalled))){const t=this.ZL.stateSettings.currentState||this.ZL.stateSettings.predictedState;this.ci.adSelector.isBestBidLoaded(t)&&this.rB()}}else this.rB()}tB(){this.QL=[],this.JL=!1,this.hB()}iB(){this.cB(),this.dB(),this.lB()}lB(){this.ci.adSelector.getLineItemsByRequest(!0).forEach((t=>{this.uB(t)}))}dB(){const t=this.ZL.stateSettings.currentState||this.ZL.stateSettings.predictedState;if(!t)return void(0,p.n)({message:"ShortCircuitMechanism_registerClientSideLineItem_no_state",level:p.D.INFO},{throttle:10,shouldSendMaxLog:!1});const i=this.ci.adSelector.getAllCallableLineItems(t).filter((t=>!t.hasAggregator)),e=i.filter((t=>t.protoLineItem.forceCallingInEveryAO)),s=this.pB(i,t);if(!s)return void this.fB(e);const n=this.ci.adSelector.getBestLoadedBid();(n?Hs.getSelectionScore(n):0)>Hs.getSelectionScore(s)?this.fB(e):(this.uB(s),e.filter((t=>t!==s)).forEach((t=>{this.uB(t)})))}cB(){const t=this.ZL.stateSettings.currentState||this.ZL.stateSettings.predictedState;if(!t)return void(0,p.n)({message:"ShortCircuitMechanism_registerAggregatedLineItems_no_state",level:p.D.INFO},{throttle:1,shouldSendMaxLog:!1});this.ci.adSelector.getAllCallableLineItems(t).filter((t=>t.hasAggregator)).forEach((t=>{this.uB(t)}))}pB(t,i){const e=this.ci.adSelector.getBestCallableLineItem(t,i);if(e&&(0,S.BZ)(e.lineItemList))return e.lineItemList[0]}uB(t){this.QL.some((i=>i.lineItemId===t.protoLineItem.advertiserLineItemId))||this.QL.push({isAdCalled:!1,lineItemId:t.protoLineItem.advertiserLineItemId})}fB(t){t.forEach((t=>{this.uB(t)}))}}!function(t){t.ShortCircuitEnd="short",t.TimeoutEnd="timeout",t.Prefetch="prefetched"}(Ao||(Ao={}));class xo{constructor(t,i){this.Ws=t,this.mB=null,this.gB=new J.x,this.GL=new J.x,this.vB=null,this.yB={inPrefetchMode:!1,startTime:0,prefetchEnded:!1},this.bB={id:"",auctionEnded:!1},this.IB=new _o({adSelector:i.adSelector,sessionId:i.sessionId}),this.SB()}get onAuctionStopCalling(){return this.GL.asObservable()}get onAuctionEnd(){return this.gB.asObservable()}updateState(t){this.IB.updateState(t)}cancelAuction(){this.yB.inPrefetchMode=!1,this.IB.cancelAuction(),this.im()}startPrefetch(t){this.im(),this.yB={inPrefetchMode:!0,startTime:Date.now(),prefetchEnded:!1},this.IB.startNewAuction({callingState:t,waitForNewReadyBid:!0})}startAuction(t,i,e=3e3){if(this.bB.id===i)return void(this.bB.auctionEnded&&(0,s.$K)(this.bB.auctionEndedType)&&this.rB(this.bB.auctionEndedType));this.mB=Date.now(),this.bB={auctionEnded:!1,id:i},this.im();let n=e;this.yB.inPrefetchMode?(n-=Date.now()-this.yB.startTime,n<0||this.yB.prefetchEnded?this.rB(Ao.Prefetch):this.PB(n)):(this.IB.startNewAuction({callingState:t,waitForNewReadyBid:!1}),this.PB(n)),this.yB.inPrefetchMode=!1}onNothingToWin(){this.IB.onNothingToWin()}onNothingToCall(){this.IB.onNothingToCall()}destroy(){this.AB.unsubscribe(),this.AB=null}SB(){this.AB=this.IB.onAuctionMechanismEnded.subscribe((()=>{this._B()}))}_B(){this.yB.prefetchEnded=!0,this.GL.next(),this.yB.inPrefetchMode||this.rB(Ao.ShortCircuitEnd)}PB(t){this.vB=this.Ws.setTimeout((()=>{this.rB(Ao.TimeoutEnd)}),t)}rB(t){null!==this.mB&&(0,s.$K)(t)&&(this.xB(t,Date.now()-this.mB),this.mB=null),this.bB.auctionEnded=!0,this.bB.auctionEndedType=t,this.cancelAuction(),this.gB.next(t)}im(){this.Ws.clearTimeout(this.vB),this.vB=null}xB(t,i){(0,h.Vm)([99,1])&&(0,p.n)({message:"AuctionManager_end_auction",exception:t,callStack:this.TB(i),level:p.D.INFO},{shouldSendMaxLog:!1,throttle:1e4})}TB(t,i=0){const e=[0,.25,.5,.75,1,1.25,1.5,1.75,2,2.25,2.5,2.75,3,4,5][i];return void 0===e?"over_5s":t<=1e3*e?`${e}`:this.TB(t,i+1)}}function To(t){return(0,s.as)(t)&&"[object RegExp]"!==Object.prototype.toString.call(t)&&"[object Date]"!==Object.prototype.toString.call(t)}function ko(t){return To(t)?Co({},t):t}function Co(t,i){return function(t,i){const e={};return To(t)&&Object.keys(t).forEach((i=>{e[i]=ko(t[i])})),Object.keys(i).forEach((s=>{To(i[s])&&t[s]?e[s]=Co(t[s],i[s]):e[s]=ko(i[s])})),e}(t,i)}class Eo{constructor(){this.requestNumber=0}}class Mo{constructor(t,i){this.protoLineItem=t,this.historicalMetrics=new Eo,this.bidsInFetch=new Set,this.aggregators=new Set,this.hasAggregator=this.kB(t.creativeType),this.price=this.CB(),this.yoScore=this.EB(i)}updateMetadata(t){const i=ji(t,this.protoLineItem);this.protoLineItem=Co(this.protoLineItem,i)}kB(t){return(0,s.$K)(je[t])}CB(){const{floorPrice:t,customCpm:i,adxFloorPricePredictionList:e}=this.protoLineItem;return(0,s.r)(t)?t:(0,s.r)(i)?i:(0,S.BZ)(e)?Ae(e[0].floorPriceObfuscated):0}EB(t){const{advertiserLineItemId:i,lineItemPriority:e}=this.protoLineItem;return t.calculateLineItemYoScore(i,{cpm:this.price,priority:e},this.hasAggregator)}}const Lo="cnx-ad-slot";class Bo{constructor(t,i,e){this.parentContainer=t,this.ol=i,this.Zp=e,this.isImaSlot=!1,this.slotsContainer=this.ol.createElementByString('<div class= "cnx-ad-bid-slot"></div>');const n=this.ol.createElementByString(`<div class="${Lo}"></div>`);this.adSlot=this.ol.createElementByString(`<div class="${Lo}"></div>`),this.videoSlot=this.ol.createElementByString(`<video class="${Lo} cnx-ad-video-slot"></video>`);const r=_t.n.defaultVideoPosterURL;(0,s.QM)(r)&&this.videoSlot.setAttribute("poster",r),this.videoSlot.setAttribute("playsinline",""),this.videoSlot.setAttribute("webkit-playsinline",""),this.videoSlot.setAttribute("aria-label","Advertisement"),this.slotsContainer.setAttribute("aria-hidden","true"),n.appendChild(this.videoSlot),n.appendChild(this.adSlot),this.slotsContainer.appendChild(n),this.parentContainer.appendChild(this.slotsContainer)}destroy(){this.parentContainer.removeChild(this.slotsContainer)}MB(){this.parentContainer.querySelectorAll(`[${ke.b.GarbageCollector}]`).forEach((t=>{(0,u.bX)(t)}))}sanitize(){this.MB()}}class Ro extends Bo{constructor(){super(...arguments),this.isImaSlot=!0,this.LB=!1,this.BB={imaAdDisplayContainer:void 0,imaAdsLoader:void 0,imaSdk:void 0}}fetchImaDependencies(){return Cn.fetchImaSdk(window,!0).then((t=>this.RB(t)))}destroy(){this.BB.imaAdsLoader&&this.BB.imaAdsLoader.destroy(),this.BB.imaAdDisplayContainer&&this.BB.imaAdDisplayContainer.destroy(),super.destroy()}sanitize(){this.BB.imaAdsLoader.contentComplete(),super.sanitize()}RB(t){if(this.LB)return this.BB;t.settings.setDisableCustomPlaybackForIOS10Plus(!0);const i=this.OB(t),e=this.DB(t,i);return this.BB={imaSdk:t,imaAdDisplayContainer:i,imaAdsLoader:e},this.LB=!0,this.BB}OB(t){const i=new t.AdDisplayContainer(this.adSlot,this.videoSlot);return i.initialize(),i}DB(t,i){const e=new t.AdsLoader(i),s=L.h.getSessionChildContainer(this.Zp).resolve(Qs.P);return e.getSettings().setVpaidMode(t.ImaSdkSettings.VpaidMode.INSECURE),s.isImaTestCaseForSS()||s.isRDDotComDomain()||s.isBudgetYourTripDotComDomain()||e.getSettings().setAutoPlayAdBreaks(!1),e}}class Oo{constructor(t){this.settings=t,this.FB=new Set,this.NB=new Set}preloadImaSdkSlots(t){Cn.preloadImaSdk(window);const i=L.h.getSessionChildContainer(this.settings.sessionId).resolve(Qs.P);if(!i.isImaTestCaseForSS()&&!i.isMarriageDotComDomain()&&!i.isDailykosDotComDomain())for(let i=1;i<=3;i++){const i=new Ro(t,this.settings.globalDomUtilsService,this.settings.sessionId);i.fetchImaDependencies(),this.FB.add(i)}}requestAdSlot(t){const i=new Bo(t,this.settings.globalDomUtilsService,this.settings.sessionId);return this.jB(i),i}requestAdSlotIma(t){let i=this.$B();return i||(i=new Ro(t,this.settings.globalDomUtilsService,this.settings.sessionId)),this.jB(i),i}destroyAdSlot(t){this.NB.delete(t),t.destroy()}recycleAdSlot(t){this.NB.delete(t),this.UB(t)?(t.sanitize(),this.FB.add(t)):this.destroyAdSlot(t)}UB(t){return t.isImaSlot}$B(){let t=null;return this.FB.forEach((i=>{this.UB(i)&&null===t&&(t=i)})),t}jB(t){this.FB.delete(t),this.NB.add(t)}}class Do{constructor(t,i){this.qB=t,this.zc=i,this.HB=new Map}bidIsNotWinnableEverInSession(t){if(!this.zB(t))return;const i=[...this.qB.getAllBidPricesSortedDesc(),t.price].sort(((t,i)=>i-t)),e=this.WB(i);this.$d(t.settings.requestMetadata.data.cnxBidId,e,v.ProtoAuctionLossReasonEnum.TargetingMismatch)}newBidAdded(t,i){this.zB(t)&&(i.selectedBid?i.selectedBid!==t?this.GB(t,i):this.XB(t):this.GB(t,i))}winBid(t){if(!this.zB(t))return;const i=this.qB.getAllBidPricesSortedDesc(),e=this.WB(i);this.HB.set(t,e)}onPostBid(t){return this.QB(t)}onImpression(t){return this.QB(t)}zB(t){return t.settings.requestMetadata.data.logAuctionInformation}XB(t){const{cnxBidId:i}=t.settings.requestMetadata.data,e=this.qB.getAllBidPricesSortedDesc(),s=this.WB(e);this.$d(i,s,v.ProtoAuctionLossReasonEnum.CompetitorPriority)}QB(t){const i=this.JB(t);return this.YB(t),i}GB(t,i){var e,n,r,o;const h=this.KB(t,i);if(!(0,s.$K)(h))return void this.ZB("AdManager_AuctionInfoLogging_lossReason_cannot_be_found",t.settings.requestMetadata.data.cnxBidId,null===(o=null===(r=null===(n=null===(e=i.selectedBid)||void 0===e?void 0:e.settings)||void 0===n?void 0:n.requestMetadata)||void 0===r?void 0:r.data)||void 0===o?void 0:o.cnxBidId);const{cnxBidId:a}=t.settings.requestMetadata.data,c=this.qB.getAllBidPricesSortedDesc(),d=this.WB(c);this.$d(a,d,h)}JB(t){if(this.HB.has(t))return this.HB.get(t);this.zB(t)&&this.ZB("AdManager_AuctionInfoLogging_cannot_find_win_bid_snapshot",t.settings.requestMetadata.data.cnxBidId)}YB(t){this.HB.has(t)&&this.HB.delete(t)}KB(t,i){var e;return null===(e=i.unselectedBidList.find((i=>i.bid===t)))||void 0===e?void 0:e.lossReason}getGeneralPostbidReason(t){switch(t){case k.ImaScriptFailure:case k.ImaObjectNotFound:case k.ImaManagerInit:case k.ImaInitSdkError:case k.AdxOverlayGptScriptLoad:case k.DisplayIntegratorIframeLoad:return v.ProtoAuctionPostbidReasonEnum.SDKFailure;case k.VastUnsupportedMedia:case k.CnxMediaSrcNotSupported:return v.ProtoAuctionPostbidReasonEnum.UnsupportedMedia;case k.DomainBlocked:case k.AdaptorInitAdError:case k.AdaptorStartAdError:case k.WrapperInitAdError:case k.WrapperStartAdError:return v.ProtoAuctionPostbidReasonEnum.TargetingMismatch;default:return v.ProtoAuctionPostbidReasonEnum.CreativeError}}WB(t){const i=t[0]?_e(t[0]):void 0,e=t[1]?_e(t[1]):void 0;return i||this.ZB("AdManager_AuctionInfoLogging_highestBidPrice_missing",`${i}`),{bidDensity:t.length,highestObfuscatedBidPrice:i,secondHighestObfuscatedBidPrice:e}}$d(t,i,e){this.zc.auctionInformation.next({cnxBidId:t,auctionInformation:i?A.Ti.fromProtoAuctionInformation(i):void 0,auctionLossReason:A.EN.fromProtoAuctionLossReason(e)})}ZB(t,i="",e=""){(0,p.n)({message:t,level:p.D.CRITICAL,callStack:i,exception:e},{throttle:5})}}class Vo{constructor(){this.tR=[]}canCall(t,i){return this.tR.every((e=>e.canCall(t,i)))}registerRequestForLineItem(t,i){return this.tR.forEach((e=>{e.registerRequestForLineItem(t,i)})),this}registerImpressionForLineItem(t,i){return this.tR.forEach((e=>{e.registerImpressionForLineItem(t,i)})),this}registerCallingValidator(t){return this.tR.push(t),this}registerCallingValidators(t){return t.forEach((t=>{this.registerCallingValidator(t)})),this}destroy(){this.tR.forEach((t=>{t.destroy()}))}}class Fo{constructor(){this.iR=new J.x,this.eR=new J.x,this.sR={[Po.ON_STARTED]:this.iR,[Po.ON_END]:this.eR},this.nR={[Po.ON_STARTED]:t=>this.iR.next(t),[Po.ON_END]:t=>this.eR.next(t)}}getCallingObservable(t){return this.sR[t].asObservable()}triggerEvent(t,i){(0,this.nR[t])(i)}}var No=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o};let jo=class{constructor(){this.rR=new Fo,this.oR=[]}get lineItems(){return this.oR}add(t){this.oR=[...this.lineItems,...t],this.rR.triggerEvent(Po.ON_STARTED,t)}remove(t){this.oR=this.lineItems.filter((i=>!(0,S.d3)(i,t))),this.rR.triggerEvent(Po.ON_END,t)}getEvents(t){return this.rR.getCallingObservable(t)}};jo=No([(0,ot.b2)(),(0,ot.Yn)(ot.Fw.ContainerScoped)],jo);class $o{constructor(){this.ME=new J.x,this.hR=new J.x,this.aR=new J.x,this.cR=new J.x,this.dR=new J.x,this.lR=new J.x,this.uR=new J.x,this.pR={[Ie.ON_BID]:this.ME,[Ie.ON_BID_LOADING]:this.hR,[Ie.ON_BID_LOADING_CONSUMED]:this.lR,[Ie.ON_BID_LOADED]:this.aR,[Ie.ON_BID_STARTING]:this.cR,[Ie.ON_BID_IN_IMPRESSION]:this.dR,[Ie.ON_BID_LOADED_CONSUMED]:this.uR},this.fR={[Ns.IDLE]:t=>{this.ME.next(t)},[Ns.LOADING]:t=>{this.hR.next(t)},[Ns.LOADED]:t=>{this.aR.next(t)},[Ns.STARTING]:t=>{this.cR.next(t)},[Ns.IMPRESSION]:t=>{this.dR.next(t)},[Ns.CONSUMED_LOADING]:t=>{this.lR.next(t)},[Ns.CONSUMED_LOADED]:t=>{this.uR.next(t)},[Ns.INVALIDATED]:t=>{[Ns.IDLE,Ns.LOADING].includes(t.status)?this.lR.next(t):this.uR.next(t)}}}bidStatusChanged(t,i){(0,this.fR[i])(t)}getBidObservable(t){return this.pR[t].asObservable()}}var Uo=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o};let qo=class{constructor(){this.rP=[],this.mR=new $o,this.gR=new Map}getEvents(t){return this.mR.getBidObservable(t)}addBid(t){this.vR(t),this.rP.push(t),this.mR.bidStatusChanged(t,Ns.IDLE)}getAllBids(){return this.yR(),this.rP}getBidsByLineItemId(t){return this.getAllBids().filter((i=>{const{advertiserLineItemId:e,publisherLineItemId:s}=i.settings.adManagerLineItem.protoLineItem;return[e,s].includes(t)}))}getBidsByStatus(t){return this.getAllBids().filter((i=>t.includes(i.status)))}bR(t,i){[Ns.CONSUMED_LOADING,Ns.CONSUMED_LOADED,Ns.INVALIDATED].includes(i)&&this.IR(t),this.mR.bidStatusChanged(t,i)}IR(t){this.wR(t),(0,S.sj)(this.rP,t)}SR(){return this.rP.filter((t=>{const i=t.createdTimestamp,e=t.settings.adManagerLineItem.protoLineItem.networkExpiryTimeSeconds;return(0,s.r)(e)&&(0,Pr.H8)(i)>=e}))}yR(){this.SR().forEach((t=>t.invalidate()))}vR(t){const i=t.onStatusChanged.subscribe((i=>{this.bR(t,i)}));this.gR.set(t.settings.bidId,i)}wR(t){const{bidId:i}=t.settings,e=this.gR.get(i);null==e||e.unsubscribe(),this.gR.delete(i)}};qo=Uo([(0,ot.b2)(),(0,ot.Yn)(ot.Fw.ContainerScoped)],qo);var Ho=r(6666);class zo{constructor(t,i){this.PR=t,this.Dc=i,this.AR=!1,this._R=!1,this.xR=!1}get predictMode(){return this.AR}get adFetchingAllowed(){return this._R}get impressionsAllowed(){return this.xR}get currentAdPlayerState(){return this.TR}get predictedAdPlayerState(){return this.kR}partialStateUpdate(t){this.TR&&(this.TR=Object.assign(Object.assign({},this.TR),t)),this.kR&&(this.kR=Object.assign(Object.assign({},this.kR),t))}getCurrentAdManagerState(t=!1){let i=this.TR;!this.currentAdPlayerState&&t&&(i=this.kR);const e=this.PR.getContainerStateMap();return this.getAdManagerState(i,e)}getPredictedAdManagerState(){const t=this.kR,i=this.ER();return this.getAdManagerState(t,i)}getAdManagerState(t,i){if(!t)return;const{width:e,height:s,viewability:n}=this.PR.getMainContainerState(),{clickToPlay:r,mediaMetadata:o,sound:h,adBreakState:a,linearAdOpportunity:c,playerOrientation:d,inFloating:l,queryJsTargeting:u}=t;return{width:e,height:s,viewability:n,clickToPlay:r,media:o,sound:!!h,soundValue:h,adContainerState:i,adBreakState:a,adOpportunity:c,playerOrientation:d,page:{insights:Ho.k.pageInsights},inFloating:l,auctionEndType:this.MR,isPageInFocus:this.Dc.isPageInFocus,queryJsTargeting:u}}ER(){let t;return this.kR.prefetchStateType===be.StartSessionPrefetch?(t=new Map,this.PR.getContainerStateMap().forEach(((i,e)=>{t.set(e,Object.assign(Object.assign({},i),{viewability:!0}))}))):t=this.PR.getContainerStateMap(),t}getCallSettings(){return{maxParallelCalls:oi.PARALLEL_CALLS_DEFAULT,stateSettings:{currentState:this.getCurrentAdManagerState(),predictedState:this.getPredictedAdManagerState()}}}getWinSettings(){return{desiredBitRate:oi.DEFAULT_DESIRED_BITRATE,maxParallelWins:oi.PARALLEL_WINS_DEFAULT,vastViewMode:this.currentAdPlayerState?this.currentAdPlayerState.vastViewMode:this.predictedAdPlayerState.vastViewMode,stateSettings:{currentState:this.getCurrentAdManagerState(),predictedState:this.getPredictedAdManagerState()}}}enableImpression(t){this.AR=!1,this.TR=t,this.kR||(this.kR=this.TR),this._R=!0}disableImpression(){this.xR=!1,this._R=!1}enablePredict(t,i){this.TR=null,this.AR=!0,this.kR=t,this.kR.prefetchStateType=i,this._R=!0}auctionEnd(t){this.MR=t,this.xR=!0}auctionStopCalling(){this.predictMode&&(this._R=!1)}}const Wo=["11d44b9b-1330-432c-bcd7-4a095b47cdbd"];class Go{constructor(t,i){this.LR=t,this.BR=i,this.RR=3e3,this.xu=null,this.OR=!1,Wo.includes(this.LR.settings.adManagerLineItem.protoLineItem.advertiserLineItemId)||this.gb()}gb(){this.DR=this.LR.onVpaidEvent.subscribe((t=>{var i,e,s,n,r,o,h,a,c;switch(t.type){case T.AdImpression:this.VR();break;case T.AdVideoFirstQuartile:this.FR();break;case T.AdVideoMidpoint:null===(i=this.NR)||void 0===i||i.reset();break;case T.AdVideoThirdQuartile:null===(e=this.NR)||void 0===e||e.reset();break;case T.AdVideoComplete:null===(s=this.NR)||void 0===s||s.stop();break;case T.AdStopped:null===(n=this.NR)||void 0===n||n.stop();break;case T.AdError:null===(r=this.NR)||void 0===r||r.stop();break;case T.AdPaused:null===(o=this.NR)||void 0===o||o.stop();break;case T.AdSkipped:null===(h=this.NR)||void 0===h||h.stop();break;case T.AdPlaying:null===(a=this.NR)||void 0===a||a.start();break;case T.AdUserClose:null===(c=this.NR)||void 0===c||c.stop();break;case T.AdExpandedChange:case T.AdClickThru:case T.AdInteraction:case T.AdUserAcceptInvitation:case T.AdLinearChange:case T.AdUserMinimize:this.destroy()}}))}VR(){const t=L.h.getGlobalContainer().resolve(Jr.f);let i=this.LR.getAdDuration();(0,s.r)(i)?(i*=1e3,this.OR=!0):i=1e3*this.BR,this.xu=i;const e=this.jR();this.NR=new Ks.B(t,e),this.NR.onTimeElapsed.subscribe((()=>{this.DR.unsubscribe(),this.DR=null,this.LR.stopAd("adNotLoading")})),this.NR.start()}FR(){if(this.OR)this.NR.reset();else{this.xu=4*this.NR.timeElapsed;const t=this.jR();this.NR.reset(t)}}jR(){return this.xu/4+this.RR}destroy(){var t;this.DR&&(this.DR.unsubscribe(),this.DR=null),null===(t=this.NR)||void 0===t||t.stop()}}const Xo=30*Lt.s_;class Qo{constructor(){this.$R=null}onAdRemoved(){this.$R=null,this.qR()}pauseViaUserInteraction(){this.$R&&(this.$R.pausedWithUserInteraction=!0)}resumeViaUserInteraction(){this.$R&&(this.$R.pausedWithUserInteraction=!1,this.qR())}HR(t){this.$R={currentAd:t,isPaused:!1,pausedWithUserInteraction:!1,remainingTimeForAdToBePaused:Xo,lastAdPausedStartedTimestamp:void 0},this.qR()}checkPauseAd(t,i){t&&(null===this.$R&&this.HR(t),i?this.zR(t):this.GR(t))}GR(t){this.XR(t)&&(this.$R.isPaused=!0,this.$R.lastAdPausedStartedTimestamp=Date.now(),t.pauseAd(),this.qR(),this.QR=setTimeout((()=>{t.stopAd("pauseOutOfView"),this.$R=null,this.qR()}),this.$R.remainingTimeForAdToBePaused))}zR(t){t.settings.adManagerLineItem.protoLineItem.pauseAdOutOfView&&t.impressionStarted&&this.$R.isPaused&&!this.$R.pausedWithUserInteraction&&(this.qR(),this.$R.isPaused=!1,this.$R.remainingTimeForAdToBePaused=this.$R.remainingTimeForAdToBePaused-(Date.now()-this.$R.lastAdPausedStartedTimestamp),t.resumeAd())}qR(){clearTimeout(this.QR),this.QR=void 0}XR(t){return t.settings.adManagerLineItem.protoLineItem.pauseAdOutOfView&&t.impressionStarted&&!this.$R.isPaused&&!this.$R.pausedWithUserInteraction}}class Jo{constructor(t,i,e,s,n){this.LR=t,this.PR=i,this.zc=e,this.JR=s,this.ci=n,this.YR=!1,this.yL=!1,this.KR=[],this.ZR=new Qo,this.wI=new J.x,this.gb(),this.tO=new Go(this.LR,this.ci.maxAdDuration),this.resizeAd()}get onVpaidEvent(){return this.wI.asObservable()}get inImpression(){return this.YR}setVastViewMode(t){this.ci.adViewMode=t;const{width:i,height:e}=this.PR.getContainerStateMap().get(this.LR.settings.adManagerLineItem.protoLineItem.adType);this.LR.resizeAd(i,e,this.ci.adViewMode)}getAdVolume(){return this.LR.getAdVolume()}setAdVolume(t,i){if(i){const{adMacroReplacer:e,adManagerState:s}=i;this.iO(t,s,e)}this.LR.setAdVolume(t)}resizeAd(){const{width:t,height:i,viewability:e}=this.PR.getContainerStateMap().get(this.LR.settings.adManagerLineItem.protoLineItem.adType);this.ZR.checkPauseAd(this.LR,e),this.LR.resizeAd(t,i,this.ci.adViewMode)}skipAd(){this.LR.setAdVolume(0),this.LR.skipAd()}stopAd(t){this.LR.stopAd(t)}pauseAd(t){this.LR.pauseAd(),t&&this.ZR.pauseViaUserInteraction()}resumeAd(t){this.LR.resumeAd(),t&&this.ZR.resumeViaUserInteraction()}getMediaSize(){const t=this.LR.getAdMediaSize().width,i=this.LR.getAdMediaSize().height,{widthRatio:e,heightRatio:s}=(0,$i.dO)(t,i);return{width:t,height:i,widthRatio:e,heightRatio:s,adType:this.LR.settings.adManagerLineItem.protoLineItem.adType}}getMetadata(){return{advertiserLineItemId:this.LR.settings.adManagerLineItem.protoLineItem.advertiserLineItemId,publisherLineItemId:this.LR.settings.adManagerLineItem.protoLineItem.publisherLineItemId,adType:this.LR.settings.adManagerLineItem.protoLineItem.adType,duration:this.LR.getAdDuration(),adSkipMode:this.LR.settings.adManagerLineItem.protoLineItem.skipMode,moatTrackingEnabled:this.LR.settings.adManagerLineItem.protoLineItem.moatTrackingEnabled,adSourceType:this.LR.adSourceType}}destroy(){this.YR=!1,this.ZR.onAdRemoved(),this.DR.unsubscribe(),this.DR=null,this.tO.destroy()}gb(){this.DR=this.LR.onVpaidEvent.subscribe((t=>{switch(t.type){case T.AdImpression:this.eO();break;case T.AdVideoFirstQuartile:this.sO(v.ProtoQuartilesEnum.First);break;case T.AdVideoMidpoint:this.sO(v.ProtoQuartilesEnum.Second);break;case T.AdVideoThirdQuartile:this.sO(v.ProtoQuartilesEnum.Third);break;case T.AdVideoComplete:this.sO(v.ProtoQuartilesEnum.Fourth)}this.wI.next(t)}))}eO(){this.yL=this.BL(this.LR.skipOffset,this.LR.getAdDuration()),this.YR=!0;const{viewability:t}=this.PR.getContainerStateMap().get(this.LR.settings.adManagerLineItem.protoLineItem.adType);this.ZR.checkPauseAd(this.LR,t)}sO(t){const i=this.KR.indexOf(t)>=0&&!(this.ci.pauseAdWhenFinished||this.ci.loopAdWhenFinished),e=this.JR.adBreakState,{adManagerLineItem:s}=this.LR.settings;if(i)return void(1===(0,h.Vm)([99,1])&&(0,p.n)({message:"AdManager_AdImpressionerController_handleQuartilesTracking_track_same_quartile_twice",level:p.D.WARN,exception:s.protoLineItem.advertiserLineItemId,callStack:this.LR.adMediaType}));this.KR.push(t);const{requestMetadata:n}=this.LR.settings,{advertiserLineItemId:r,publisherLineItemId:o}=s.protoLineItem,{rtbSeatId:a,rtbAdomain:c,dspId:d}=n.data;this.zc.adQuartile.next({advertiserLineItemId:r,publisherLineItemId:o,rtbSeatId:a,dspId:d,rtbADomain:c,type:A.EN.fromProtoGetQuartile(t),adBreakType:A.EN.fromProtoAdBreakType(e.adBreakType),hasSkipAd:this.yL})}BL(t,i){if((0,s.hj)(t)&&t>=0)return!0;return(0,hi.Xj)(i,this.ci.skipAdSettings)}iO(t,i,e){const s=this.LR.getAdVolume();let n=null;0===s&&t>0?n=this.LR.settings.vastTracker.adUnmute:s>0&&0===t&&(n=this.LR.settings.vastTracker.adMute);const r=this.LR.settings.adManagerLineItem.protoLineItem;n&&Le.track(n,e,r,i)}}var Yo,Ko,Zo;!function(t){t[t.IsIma=-1]="IsIma",t[t.IsBidCall=-2]="IsBidCall"}(Yo||(Yo={})),function(t){t.BID="bid",t.BID_IN_FETCH="bid_in_fetch"}(Ko||(Ko={})),function(t){t[t.VERIFYING=-1]="VERIFYING"}(Zo||(Zo={}));class th{constructor(t,i,e,s){this.qB=t,this.mL=i,this.adManagerState=e,this.nO=[],this.rO=[],this.deltaTimestampAdStartAdOpportunity=Date.now()-s,this.nO=this.qB.getEligibleBidsInAuctionSortedDescBySelectionScore(this.adManagerState).filter((t=>t!==this.mL)),this.rO=this.qB.getEligibleBidsInFetchInAuctionSortedDescBySelectionScore(this.adManagerState),this.winnerDemandType=this.oO(),this.firstLoser=this.hO(),this.allLoserStatusInfo=this.aO(),this.firstOpenMarketLoser=this.cO(),this.auctionEndType=this.adManagerState.auctionEndType}oO(){return this.mL?Ri.getBidDemandType(this.mL):(this.lO("ImpressionAuctionSnapshot: No winner bid found"),v.ProtoDemandTypeEnum.None)}aO(){const t=this.rO.length;let i=0,e=0,s=0;return this.nO.forEach((t=>{switch(t.status){case Ns.IDLE:i++;break;case Ns.LOADING:e++;break;case Ns.LOADED:s++}})),{verifyingBidsInAuction:t,idleBidsInAuction:i,loadingBidsInAuction:e,loadedBidsInAuction:s}}hO(){const t=this.nO[0],i=this.rO[0];if(!(0,s.$K)(t)&&!(0,s.$K)(i))return;let e=0;(0,s.$K)(t)&&(e=Hs.getSelectionScore(t));let n,r,o,h,a,c,d,l,u,p=0;return(0,s.$K)(i)&&(p=Hs.getSelectionScore(i)),e>p?(n=Ri.getBidDemandType(t),r=t.price,o=Ko.BID,h=t.settings.requestMetadata.data.encryptedPrice,a=t.settings.adManagerLineItem.protoLineItem.advertiserLineItemId,c=t.settings.adManagerLineItem.protoLineItem,d=t.settings.isIma,l=t.status,u=t.settings.isIma?Yo.IsIma:t.getAdDuration()):(n=function(t){const i=Object.keys(Ri.bidDemandTypeMap).filter((i=>(0,Ri.bidDemandTypeMap[i])(t.protoLineItem)))[0];if(!(0,s.$K)(i))return v.ProtoDemandTypeEnum.None;const e=Number.parseInt(i,10);return v.ProtoDemandTypeEnum[v.ProtoDemandTypeEnum[e]]}(i.adManagerLineItem),r=i.bidPrice,o=Ko.BID_IN_FETCH,h=i.encryptedPrice,a=i.adManagerLineItem.protoLineItem.advertiserLineItemId,c=i.adManagerLineItem.protoLineItem,d=i.isIma,l=Zo.VERIFYING,u=Yo.IsBidCall),{loserType:o,demandType:n,encryptedPrice:h,customClientPrice:r,advertiserLineItemId:a,lineItem:c,isIma:d,status:l,adDuration:u}}cO(){const t=this.uO();if((0,s.$K)(t))return{demandType:v.ProtoDemandTypeEnum.OpenMarket,encryptedPrice:t.settings.requestMetadata.data.encryptedPrice,customClientPrice:t.settings.cpm,advertiserLineItemId:t.settings.adManagerLineItem.protoLineItem.advertiserLineItemId}}uO(){return this.nO.find((t=>Ri.getBidDemandType(t)===v.ProtoDemandTypeEnum.OpenMarket))}lO(t){(0,p.n)({level:p.D.WARN,message:t},{throttle:1,shouldSendMaxLog:!1})}}class ih{constructor(t){this.qB=t,this.pO=null}get lastSnapshot(){return this.pO}takeSnapshot(t,i,e){return this.pO=new th(this.qB,t,i,e),this.pO}}var eh=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o};let sh=class{constructor(){this.bidInFetchList=[]}add(t){this.bidInFetchList.push(t)}remove(t){(0,S.sj)(this.bidInFetchList,t)}getById(t){return this.bidInFetchList.find((i=>i.bidId===t))}};var nh;sh=eh([(0,ot.b2)(),(0,ot.Yn)(ot.Fw.ContainerScoped)],sh),function(t){t[t.TimeoutWithReadyBid=0]="TimeoutWithReadyBid",t[t.TimeoutWithoutReadyBid=1]="TimeoutWithoutReadyBid",t[t.Shorted=2]="Shorted",t[t.Prefetched=3]="Prefetched"}(nh||(nh={}));class rh{calculateLineItemYoScore(t,i,e){return e?Math.random():this.fO(i)}calculateBidYoScore(t,i){return this.fO(i)}fO(t){const{cpm:i,priority:e}=t;return i+200*e}}class oh{constructor(){this.mO=new Map}calculateLineItemYoScore(t){return this.gO(t)}calculateBidYoScore(t){return this.gO(t)}gO(t){const i=this.mO.get(t);if((0,s.$K)(i))return i;const e=Math.random();return this.mO.set(t,e),e}}class hh{constructor(t){this.vO=t?new oh:new rh}calculateLineItemYoScore(t,i,e){return this.vO.calculateLineItemYoScore(t,i,e)}calculateBidYoScore(t,i){return this.vO.calculateBidYoScore(t,i)}}var ah=function(t,i,e,s){var n,r=arguments.length,o=r<3?i:null===s?s=Object.getOwnPropertyDescriptor(i,e):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,e,s);else for(var h=t.length-1;h>=0;h--)(n=t[h])&&(o=(r<3?n(o):r>3?n(i,e,o):n(i,e))||o);return r>3&&o&&Object.defineProperty(i,e,o),o};let ch=class{constructor(){this.yO=[]}get lineItems(){return[...this.yO]}add(t){this.yO.push(...t)}remove(t){this.yO.indexOf(t)<0||(0,S.sj)(this.yO,t)}getByAggregation(t){return this.lineItems.filter((i=>i.hasAggregator===t))}getByPublisherLineItemId(t){return this.lineItems.find((i=>i.protoLineItem.publisherLineItemId===t))}hasAggregatorType(t){return this.lineItems.some((i=>{const e=i.protoLineItem.creativeType;return e&&je[e]===t}))}};ch=ah([(0,ot.b2)(),(0,ot.Yn)(ot.Fw.ContainerScoped)],ch);class dh{constructor(t,i,e){this.ci=t,this.Pd=i,this.zc=e,this.bO=!1,this.wI=new J.x,this.IO=new J.x,this.EI=new J.x,this.wO=new J.x,this.Fc=[],this.ru=t=>{Ws.getInstance().add(t,this.RP,this.SO)},this.ou=t=>{this.IO.next(t)},this.PO=(t,i)=>{const e=this.RP.lineItems.find((i=>i.protoLineItem.advertiserLineItemId===t));e&&(e.protoLineItem.viewability=i)},this.IM=()=>{var t;null===(t=this.AO)||void 0===t||t.resizeAd(),this._O()},this.YA=L.h.getSessionChildContainer(this.ci.app.config.sessionId).resolve(Qs.P),this.DS=L.h.getSessionChildContainer(this.ci.app.config.sessionId).resolve(Ft);const s=this.ci.adContainerMap.get(this.xO());this.TO=(0,u.LT)(s),this.zc.startBidTracking.next(),this.kO(),this.CO(),this.EO(),this.MO()}get onVpaidEvent(){return this.wI.asObservable()}get onImpressionRevenueEvent(){return this.IO.asObservable()}get onNoFill(){return this.wO.asObservable()}setAdVolume(t){var i;this.JR.partialStateUpdate({sound:t});const e={adManagerState:this.JR.getCurrentAdManagerState(!0),adMacroReplacer:this.LO};null===(i=this.AO)||void 0===i||i.setAdVolume(t,e),this.YA.adManagerSound=t}setAdViewMode(t){var i;this.JR.partialStateUpdate({vastViewMode:t}),null===(i=this.AO)||void 0===i||i.setVastViewMode(t)}getCurrentAdMetadata(){var t;return null===(t=this.AO)||void 0===t?void 0:t.getMetadata()}getCurrentAdMediaSize(){var t;return null===(t=this.AO)||void 0===t?void 0:t.getMediaSize()}pauseAd(t){var i;null===(i=this.AO)||void 0===i||i.pauseAd(t)}resumeAd(t){var i;null===(i=this.AO)||void 0===i||i.resumeAd(t)}skipAd(){var t;null===(t=this.AO)||void 0===t||t.skipAd()}stopAd(t){var i;null===(i=this.AO)||void 0===i||i.stopAd(t)}setPlayerOrientation(t){this.JR.partialStateUpdate({playerOrientation:t}),this._O()}setQueryJsTargeting(t){this.JR.partialStateUpdate({queryJsTargeting:t}),this._O()}enableImpressions(t){this.JR.enableImpression(t),this.PR.forceTriggerUpdateState(),this.BO.allowResetOnTime=!0,this.RO(t),this.OO()}disableImpressions(t=!1){(this.JR.impressionsAllowed||t)&&(this.DO.stop(),this.VO.stop(),this.JR.disableImpression(),this.AO&&!this.AO.inImpression&&this.ci.app.config.isInApp&&this.AO.stopAd("inApp_disable"))}enablePredict(t,i){switch(this.JR.enablePredict(t,i),i){case be.StartSessionPrefetch:this.BO.allowResetOnTime=!1;break;case be.MidSessionPrefetch:this.BO.allowResetOnTime=!0}this.OO();const e=this.JR.getCallSettings();this.FO.startPrefetch(e)}isLoadingAds(){return!!this.AO||this.qB.hasLoadingBids()}getMainContainerState(){return this.PR.getMainContainerState()}getMainContainer(){return this.PR.getMainContainer()}setCustomMacros(t){this.VO.setMacros(t)}destroy(){var t;this.disableImpressions(),(0,it.i)(this.Fc),this.VO.destroy(),this.NO.destroy(),this.DO.destroy(),this.jO.destroy(),this.$O(),null===(t=this.AO)||void 0===t||t.stopAd("adManagerDestroy"),this.UO()}kO(){const t=L.h.getGlobalContainer().resolve(Jr.f);this.jO=new oo(t),this.qO=new eo,this.BO=new no,this.HO=new ro,this.zO=(new Vo).registerCallingValidators([this.BO,this.qO,this.HO]),this.BS=new xe,this.LO=new wo(this.ci.app.services.MacrosService,this.ci.app.services.UserManagerService)}CO(){this.vO=new hh(this.ci.app.config.explorationMode);const t=this.ci.lineItemList.map((t=>new Mo(t,this.vO)));this.RP=new ch,this.RP.add(t),this.OP=new jo,this.HP=new sh,this.SO=new qo,this.PR=new ho(this.xO(),this.ci.adContainerMap,this.ci.app.services.ResizeObserver,this.ci.app.services.ViewabilityService),this.WO=new Oo({globalDomUtilsService:this.ci.app.services.GlobalDomUtilsService,recycleAdSlots:!0,sessionId:this.ci.app.config.sessionId}),this.JR=new zo(this.PR,this.ci.generalRepository),this.qB=new Ys(this.RP,this.OP,this.HP,this.SO,{callingValidationAggregator:this.zO,impressionCapService:this.qO},{maxNumberOfWins:oi.MAX_WINS_DEFAULT},this.ci.app.config.sessionId);const i=L.h.getGlobalContainer().resolve(Jr.f);this.FO=new xo(i,{sessionId:this.ci.app.config.sessionId,adSelector:this.qB});const e=L.h.getSessionChildContainer(this.ci.app.config.sessionId).resolve(vt.k),s=new Do(this.qB,e);this.VO=new Kr({yoScoreCalculator:this.vO,playerData:this.ci.playerData,generalRepository:this.ci.generalRepository,auctionInfoLogging:s,adSelector:this.qB,adContainerMap:this.ci.adContainerMap,amazonSlotId:this.ci.amazonTamSlotId,app:this.ci.app,appSettings:this.ci.appSettings,schainSettings:this.ci.pbjsSchainSettings,skipAdSettings:this.ci.skipPlayerSettings,sessionId:this.ci.app.config.sessionId,adMacroReplacer:this.LO,lineItemServices:{lineItemServicesTimer:this.jO,requestCapsService:this.BO},adRequestGatekeeper:this.BS,adEnforcer:new mo(this.ci.app.config.isMobile,this.TO,this.ci.disableScrollHijackEnforcement),pauseAdWhenFinished:this.ci.pauseAdWhenFinished,loopAdWhenFinished:this.ci.loopAdWhenFinished,os:this.ci.app.config.os.os,adSlotContainerRecycler:this.WO,callingValidationAggregator:this.zO,auctionManager:this.FO,lineItemAbTestInformation:this.ci.lineItemAbTestInformation},e),this.NO=new So({desiredBitRateForWins:oi.DEFAULT_DESIRED_BITRATE,playerId:this.ci.app.config.playerId,sessionId:this.ci.app.config.sessionId,adSelector:this.qB,auctionManager:this.FO,auctionInfoLogging:s,impressionCapsTimer:this.jO,adMacroReplacer:this.LO},e),this.DO=new bo({adContainer:this.PR,adSelector:this.qB,auctionInfoLogging:s,internalAuctionSnapshot:new ih(this.qB),impressionCapsService:this.qO,impressionCapsTimer:this.jO,requestCapsService:this.BO,removeBidIfHigherYoScore:oi.REMOVE_BIDS_DEFAULT,adRequestGatekeeper:this.BS,pauseAdWhenFinished:this.ci.pauseAdWhenFinished,loopAdWhenFinished:this.ci.loopAdWhenFinished,adMacroReplacer:this.LO,explorationMode:this.ci.app.config.explorationMode,playerId:this.ci.app.config.playerId,skipAdSettings:this.ci.skipPlayerSettings,fullSessionLog:this.ci.generalRepository.canTrackAllRequests,deviceType:this.ci.app.config.deviceType,sessionId:this.ci.app.config.sessionId},e)}EO(){this.Fc.push(this.Pd.onLineItemPlatformCapped.subscribe((t=>{this.ru(t)})),this.Pd.onImpressionRevenue.subscribe((t=>{this.ou(t)})),this.Pd.onLineItemViewabilityChange.subscribe((([t,i])=>{this.PO(t,i)})))}MO(){this.Fc.push(this.VO.onLineItemsRequestStart.subscribe((t=>{this.OP.add(t)})),this.VO.onLineItemsRequestEnd.subscribe((t=>{this.OP.remove(t)})),this.zc.onBidFetchStart.subscribe((t=>{this.HP.add(t)})),this.zc.onBidFetchEnd.subscribe((t=>{this.HP.remove(t)})),this.VO.onBid.subscribe((t=>{this.SO.addBid(t)})),this.FO.onAuctionEnd.subscribe((t=>{this.gB(t)})),this.FO.onAuctionStopCalling.subscribe((()=>{this.GO()})),this.PR.onContainerStateUpdate.subscribe((()=>{this.IM()})),this.DO.onAdSelected.subscribe((t=>{this.bL(t)})),this.DO.onAdFinished.subscribe((t=>{this.IL()})),this.DO.onMissedImpression.subscribe((t=>{this.EI.next(t)})))}get onMissedImpression(){return this.EI.asObservable()}gB(t){this.JR.auctionEnd(this.XO(t)),this.JR.impressionsAllowed&&this.JO()}XO(t){switch(t){case Ao.Prefetch:return nh.Prefetched;case Ao.ShortCircuitEnd:return nh.Shorted;case Ao.TimeoutEnd:return this.qB.hasLoadedBids()?nh.TimeoutWithReadyBid:nh.TimeoutWithoutReadyBid;default:return}}hasAdsEligibleForFill(t){const i=this.JR.getAdManagerState(t,this.PR.getContainerStateMap());return this.qB.hasAdsEligibleForFill(i)}GO(){this.JR.predictMode&&this.VO.stop(),this.JR.auctionStopCalling()}bL(t){const{currentAdPlayerState:i,predictedAdPlayerState:e}=this.JR,s=(i||e).vastViewMode,n=this.JR.getCurrentAdManagerState().adBreakState.maxAdDuration,r=this.JR.getCurrentAdManagerState()||this.JR.getPredictedAdManagerState();this.AO=new Jo(t,this.PR,this.zc,r,{adViewMode:s,maxAdDuration:n,skipAdSettings:this.ci.skipPlayerSettings,loopAdWhenFinished:this.ci.loopAdWhenFinished,pauseAdWhenFinished:this.ci.pauseAdWhenFinished}),this.YO(),this.AO.setAdVolume(this.JR.currentAdPlayerState.sound);const o=t.settings.adLoadedPayload.payload.vastVerifications;(0,S.BZ)(o)&&this.DS.isOmsdkFullSupport&&this.DS.addVerificationNode(o,t.settings.adLoadedPayload.payload.containers),this.KO(t)}KO(t){var i;this.wI.next({type:T.AdLoaded,payload:null===(i=t.settings.adLoadedPayload)||void 0===i?void 0:i.payload})}IL(){this.DS.clearPendingProcesses(),this.UO()}_O(){this.JR.adFetchingAllowed&&this.OO(),this.JR.impressionsAllowed&&this.JO()}OO(){this.bO||(this.bO=!0,this.ci.app.services.UserManagerService.ccpaInfoLogging(this.ci.app.config.playerId));const t=this.JR.getCallSettings();this.VO.call(t);const i=this.JR.getWinSettings();this.NO.win(i)}JO(){(this.JR.currentAdPlayerState||this.JR.predictedAdPlayerState)&&this.JR.currentAdPlayerState&&this.DO.start(this.JR.getCurrentAdManagerState())}YO(){this.ZO=this.AO.onVpaidEvent.subscribe((t=>{var i;if(t.type===T.AdImpression)try{const t=(null===(i=this.JR.getCurrentAdManagerState())||void 0===i?void 0:i.soundValue)||0;this.AO.setAdVolume(t)}catch(t){(0,p.n)({level:p.D.WARN,message:"AdManager_current_sound",exception:t.message,callStack:t.stack})}this.wI.next(t)}))}UO(){var t;null===(t=this.AO)||void 0===t||t.destroy(),this.AO=null,this.$O()}$O(){var t;null===(t=this.ZO)||void 0===t||t.unsubscribe(),this.ZO=null}RO(t){const i=[this.qO,this.BO];t.newContent&&i.forEach((t=>{t.resetCapsBasedOnExternalEvent(v.ProtoResetCapTypeEnum.ContentCapping)}))}}class lh extends dh{constructor(t,i,e){super(t,i,e),this.gB=t=>{this.tD()||this.wO.next(),super.gB(t)};const s=this.PR.getMainContainer();this.WO.preloadImaSdkSlots(s),this.qB.getBidEvents(Ie.ON_BID_LOADED_CONSUMED).subscribe((()=>{this.tD()||this.wO.next()}))}enableImpressions(t){super.enableImpressions(t);const i=this.JR.getCallSettings();this.FO.startAuction(i,t.linearAdOpportunity.id)}disableImpressions(t=!1){(this.JR.impressionsAllowed||t)&&(this.FO.cancelAuction(),super.disableImpressions(t))}OO(){const t=this.JR.getCallSettings();this.FO.updateState(t),super.OO()}xO(){return v.ProtoAdType.Video}setLineItemMetadata(t,i){const e=this.iD(t);(0,s.mf)(i)&&i(e)}iD(t){try{const i=this.RP.getByPublisherLineItemId(t.id);if(!(0,s.$K)(i))return{success:!1,errorReason:si.NoLineItem};if(!i.protoLineItem.isExternal)return{success:!1,errorReason:si.NoSupportForCreativeType};if(!this.eD(t,i))return{success:!1,errorReason:si.MetadataInvalid};return this.SO.getBidsByStatus([Ns.STARTING,Ns.IMPRESSION]).find((t=>t.settings.adManagerLineItem===i))?{success:!1,errorReason:si.AdAlreadyStarted}:(i.updateMetadata(t),this.sD(t.id),this.nD(i),this.rD(i),{success:!0})}catch(t){return{success:!1,errorReason:si.Unknown}}}rD(t){this.HP.bidInFetchList.filter((i=>i.adManagerLineItem===t)).forEach((t=>t.shouldBeDiscarded=!0))}eD(t,i){const{adTag:e,resetCapType:n,requestCap:r,impressionCap:o,resetRequestsCapTime:h,resetImpressionsCapTime:a}=ji(t,i.protoLineItem);return!(!(0,s.QM)(e)||!(0,s.$K)(n))&&(!(n===v.ProtoResetCapTypeEnum.OpportunityCapping&&!(0,s.Xc)(r))&&(!(n!==v.ProtoResetCapTypeEnum.OpportunityCapping&&!(0,s.r)(r)&&!(0,s.r)(o))&&!!this.oD(n,r,o,h,a)))}oD(t,i,e,n,r){return t!==v.ProtoResetCapTypeEnum.TimeCapping||!((0,s.r)(i)&&!(0,s.Xc)(n))&&!((0,s.r)(e)&&!(0,s.Xc)(r))}nD(t){[this.qO,this.BO].forEach((i=>{i.resetCapsOnLineItemMetadataUpdate(t)}))}sD(t){this.SO.getBidsByLineItemId(t).forEach((t=>{t.invalidate()}))}tD(){const t=this.JR.getCurrentAdManagerState()||this.JR.getPredictedAdManagerState(),i=this.qB.getBestBidAllowed(t);return(0,s.$K)(i)}}class uh extends dh{xO(){return v.ProtoAdType.Nonlinear}enableImpressions(t){super.enableImpressions(t),this.gB()}}const ph={[v.ProtoAdSlotsEnum.PreRoll]:v.ProtoAdBreakTypeEnum.PreRoll,[v.ProtoAdSlotsEnum.MidRoll]:v.ProtoAdBreakTypeEnum.MidRoll,[v.ProtoAdSlotsEnum.PostRoll]:v.ProtoAdBreakTypeEnum.PostRoll};var fh;!function(t){t.adLoadedPayload=t=>({payload:{adType:t.payload.adType,adSkipMode:t.payload.adSkipMode,adLoadedData:{skipOffset:t.payload.adLoadedData.skipOffset}}}),t.impressionPayload=(t,i,e)=>{const{adId:s,adVideoUrl:n,creativeId:r,name:o,length:h,imaMetadata:a,moatTrackingEnabled:c}=t.payload.adSourceData,{adType:d,adSkipMode:l,clickThroughUrl:u,customAdData:p,adSourceData:f}=t.payload;return{payload:{adType:d,adBreakType:e,adSkipMode:l,adSourceData:{moatTrackingEnabled:c,adId:s,length:h,imaMetadata:a,adVideoUrl:n,creativeId:r,name:o},clickThroughUrl:u,customAdData:{ADVERTISER:null==p?void 0:p.ADVERTISER,CAMPAIGN_ID:null==p?void 0:p.CAMPAIGN_ID,CREATIVE_ID:p.CREATIVE_ID},adDuration:f.length,selectedAdSlot:i}}},t.defaultPayload=t=>({payload:{adType:t.payload.adType}})}(fh||(fh={}));class mh{get onAdLifeEnding(){return this.hD.asObservable()}constructor(t,i){this.aD=t,this.cD=i,this.hD=new J.x,this.Fc=[],this.dD=!1;const e=L.h.getGlobalContainer().resolve(Jr.f);this.__=new Ks.B(e),this.lD(),this.Lk(),this.pD()}isDurationExpired(){return this.dD}destroy(){this.__.disable(),this.Fc.forEach((t=>t.unsubscribe()))}lD(){this.Fc.push(this.__.onTimeElapsed.subscribe((()=>{this.__.stop(),this.dD=!0,this.hD.next()})))}Lk(){this.Fc.push(this.aD.subscribe((t=>{switch(t.type){case T.AdImpression:this.fD(t.payload.adSourceData.length);break;case T.AdPlaying:this.pD();break;case T.AdPaused:this.vp();break;case T.AdStopped:case T.AdSkipped:case T.AdError:this.mD();break;case T.AdVideoFirstQuartile:this.gD()}})))}vp(){this.__.stop()}pD(){this.__.start()}fD(t){if(this.vD=Date.now(),t){this.xu=t*Lt.s_;const i=this.xu-this.cD;this.yD(i),this.__.start()}}mD(){this.__.stop(),this.dD=!1}gD(){if(this.xu)return;const t=Date.now()-this.vD;this.xu=4*t;const i=this.xu-t-this.cD;this.yD(i)}yD(t){const i=t<0?0:t;this.__.reset(i)}}class gh{constructor(t,i){this.Zx=t,this.bD=new J.x,this.SI=new J.x,this.ID=be.NoPrefetch,this.wD=i===v.ProtoAdPlaybackMode.ScrollToPlay}get prefetchType(){return this.ID}get startSessionPrefetch(){return this.wD}set startSessionPrefetch(t){this.wD=t}get onMidSessionPrefetchReady(){return this.bD.asObservable()}get onPrefetchStart(){return this.SI.asObservable()}enablePrefetch(t,i,e){this.wD=!1,this.ID=t,this.SI.next(),null==e||e.enablePredict(i,t)}disablePrefetch(){this.ID=be.NoPrefetch}tryPreparingMidSessionPrefetch(t,i){if(!this.SD(t))return;const e=null==t?void 0:t.disableReason;e===ye.TimeoutBetweenAds&&this.bD.next(be.MidSessionPrefetch),e===ye.InImpression&&this.PD(t,i)&&this.bD.next(be.MidSessionPrefetch)}SD(t){return this.ID===be.NoPrefetch&&null!==t&&t.adBreakLength!==Number.POSITIVE_INFINITY}PD(t,i){return i&&t.adBreakLength<=oi.MID_SESSION_PREFETCH_MINIMUM_TIME&&!this.Zx}}class vh{constructor(t,i){this.ci={[Bi.LINEAR]:{enable:!1,disablePayload:null,usePrefetch:!0},[Bi.NONLINEAR]:{enable:!1,disablePayload:null,usePrefetch:!1}},this.bD=new J.x,this.SI=new J.x,this.Fc=[],this.AD(t,i)}get onMidSessionPrefetchReady(){return this.bD.asObservable()}get onPrefetchStart(){return this.SI.asObservable()}getAllLinearityKeys(){return Object.keys(this.ci)}enable(t){this.ci[t].enable=!0,this.ci[t].disablePayload=null}disable(t,i){this.ci[t].enable=!1,this.ci[t].disablePayload=i}getDisablePayload(t){return this.ci[t].disablePayload}setAdManager(t,i){this.ci[t].adManager=i,this.ci[t].usePrefetch&&(this.ci[t].adLifecycleObserver=new mh(i.onVpaidEvent,oi.MID_SESSION_PREFETCH_MINIMUM_TIME),this.Fc.push(this.ci[t].adLifecycleObserver.onAdLifeEnding.subscribe((()=>{const i=this.getDisablePayload(t),e=this.ci[t].adLifecycleObserver.isDurationExpired();this.ci[t].adPrefetch.tryPreparingMidSessionPrefetch(i,e)}))))}isAdManagerEnable(t){return this.ci[t].enable}getAllAdManagers(){return this.getAllLinearityKeys().map((t=>this.ci[t].adManager))}getAllAvailableAdManagers(){return this.getAllAdManagers().filter((t=>(0,s.$K)(t)))}getAdManagerByLinearity(t){return this.ci[t].adManager}usePrefetch(t){return this.ci[t].usePrefetch}enablePrefetch(t,i,e,s){this.usePrefetch(t)&&this.ci[t].adPrefetch.enablePrefetch(i,e,s)}startSessionPrefetch(t,i){this.ci[t].adPrefetch.startSessionPrefetch=i}disablePrefetch(t){this.usePrefetch(t)&&this.ci[t].adPrefetch.disablePrefetch()}getPrefetchType(t){if(this.usePrefetch(t))return this.ci[t].adPrefetch.prefetchType}hasStartSessionPrefetch(t){return!!this.usePrefetch(t)&&this.ci[t].adPrefetch.startSessionPrefetch}tryPreparingMidSessionPrefetch(t,i){var e;if(!this.usePrefetch(t))return;const s=(null===(e=this.ci[t].adLifecycleObserver)||void 0===e?void 0:e.isDurationExpired())||!1;this.ci[t].adPrefetch.tryPreparingMidSessionPrefetch(i,s)}destroy(){(0,it.i)(this.Fc),this.getAllAvailableAdManagers().forEach((t=>t.destroy()))}AD(t,i){this.getAllLinearityKeys().forEach((e=>{this.ci[e].usePrefetch&&(this.ci[e].adPrefetch=new gh(t,i),this._D(e))}))}_D(t){const i=this.ci[t].adPrefetch;this.Fc.push(i.onMidSessionPrefetchReady.subscribe((i=>{this.bD.next({prefetchType:i,linearity:Bi[t]})})),i.onPrefetchStart.subscribe((()=>{this.SI.next()})))}}var yh=r(6286);class bh{constructor(t,i,e){this.Ts=t,this.yI=i,this.gI=e,this.Fc=[],this.II=new J.x,this.xD=new J.x,this.TD=new J.x,this.kI=new J.x,this.kD=new J.x,this.TI=new J.x,this.BI=new J.x,this.CI=new J.x,this.EI=new J.x,this.SI=new J.x,this.CD=new Map,this.ED=!0,this.LD=!0,this.BD={[Bi.LINEAR]:(t,i)=>{const e=new lh(t,t.trackingResponseService,i);this.ci.setAdManager(Bi.LINEAR,e)},[Bi.NONLINEAR]:(t,i)=>{const e=new uh(t,t.trackingResponseService,i);this.ci.setAdManager(Bi.NONLINEAR,e)}},this.Bl={mediaMetadata:{},clickToPlay:!1,linearAdOpportunity:new de,newContent:!1,sound:0,vastViewMode:x.Normal,adBreakState:this.gI.getAdBreakState(),playerOrientation:this.yI,inFloating:this.Ts.playerData.inFloating,queryJsTargeting:this.Ts.queryJsTargeting},this.ci=new vh(this.Ts.loopAdWhenFinished,this.Ts.adPlaybackMode),this.ED=this.Ts.canPrefetch}get onMissedImpression(){return this.EI.asObservable()}get onLinearNoFill(){return this.CI.asObservable()}get onAdsEnable(){return this.II.asObservable()}get onLinearVpaidEvent(){return this.xD.asObservable()}get onNonlinearVpaidEvent(){return this.TD.asObservable()}get onLinearImpressionRevenue(){return this.kI.asObservable()}get onNonlinearImpressionRevenue(){return this.kD.asObservable()}get onLinearImpressionPrice(){return this.TI.asObservable()}get onNonlinearImpressionPrice(){return this.BI.asObservable()}get onPrefetchStart(){return this.SI.asObservable()}hasAdsEligibleForFill(){var t;return Boolean(null===(t=this.ci.getAdManagerByLinearity(Bi.LINEAR))||void 0===t?void 0:t.hasAdsEligibleForFill(this.Bl))}getCurrentAdBreakType(){return this.Bl.adBreakState.adBreakType}canPrefetchAds(t){const i=this.ci.getAdManagerByLinearity(t);this.RD(t,be.StartSessionPrefetch,i)}initAd(t,i,e,s,n,r,o){this.OD(r),this.GI(o),this.ci.getAllLinearityKeys().forEach((t=>{this.DD(Bi[t],{sound:n})}))}getNewLinearAdOpportunity(){return this.ci.getPrefetchType(Bi.LINEAR)===be.NoPrefetch?new de:this.Bl.linearAdOpportunity}getAdContainerSize(t){const i=this.CD.get(t);return{height:(null==i?void 0:i.clientHeight)||0,width:(null==i?void 0:i.clientWidth)||0}}getMainAdContainerWidth(t){var i;return null===(i=this.ci.getAdManagerByLinearity(t))||void 0===i?void 0:i.getMainContainerState().width}getCurrentAdMetadata(t){var i;return null===(i=this.ci.getAdManagerByLinearity(t))||void 0===i?void 0:i.getCurrentAdMetadata()}getCurrentAdMediaSize(t){var i;return null===(i=this.ci.getAdManagerByLinearity(t))||void 0===i?void 0:i.getCurrentAdMediaSize()}isAdInWin(t){const i=this.ci.getAdManagerByLinearity(t);return(null==i?void 0:i.isLoadingAds())||!1}enableAds(t){this.ci.enable(t),this.DD(t),this.II.next(t)}disableAds(t,i){this.ci.disable(t,i);const e=this.ci.getAdManagerByLinearity(t);if(!e)return;const s=(null==i?void 0:i.disableReason)===ye.ForceDisable;e.disableImpressions(s),(null==i?void 0:i.disableReason)!==ye.ForceDisable&&this.ci.usePrefetch(t)&&this.ci.tryPreparingMidSessionPrefetch(t,i)}disableAdvertising(){this.LD=!1}enableAdvertising(){this.LD=!0,this.ci.getAllLinearityKeys().forEach((t=>{const i=Bi[t];this.enablePrefetchForLinearity(i)}))}setAdVolume(t,i){var e;null===(e=this.ci.getAdManagerByLinearity(t))||void 0===e||e.setAdVolume(i),this.DD(t,{sound:i})}pauseAd(t,i){var e;null===(e=this.ci.getAdManagerByLinearity(t))||void 0===e||e.pauseAd(i)}resumeAd(t,i){var e;null===(e=this.ci.getAdManagerByLinearity(t))||void 0===e||e.resumeAd(i)}skipAd(t){var i;null===(i=this.ci.getAdManagerByLinearity(t))||void 0===i||i.skipAd()}stopAd(t,i){var e;null===(e=this.ci.getAdManagerByLinearity(t))||void 0===e||e.stopAd(i)}onAdStateChange(t,i,e){const s=ph[i];this.VD(t,e,s),s===v.ProtoAdBreakTypeEnum.PreRoll&&(this.ED=!0)}onContentChange(){this.ci.getAllLinearityKeys().forEach((t=>{this.DD(Bi[t],{newContent:!0})}))}setMediaRestrictions(t){const i=Object.assign(this.Bl.mediaMetadata,t);this.ci.getAllLinearityKeys().forEach((t=>{const e=Bi[t];this.DD(e,{mediaMetadata:i}),this.enablePrefetchForLinearity(e)}))}userInteraction(t){this.ci.getAllLinearityKeys().forEach((t=>{this.DD(Bi[t],{clickToPlay:!0})}))}setPlayerOrientation(t){this.Bl.playerOrientation=t,this.ci.getAllAvailableAdManagers().forEach((i=>i.setPlayerOrientation(t)))}updateJsQueryTargeting(t){this.Bl.queryJsTargeting=(0,ue.S1)(this.Bl.queryJsTargeting,t),this.FD()}removeJsQueryTargeting(t){this.Bl.queryJsTargeting=(0,ue.G_)(this.Bl.queryJsTargeting,t),this.FD()}setVastViewMode(t){this.ND({vastViewMode:t})}newLinearAdOpportunity(t){const i=Bi.LINEAR;this.ci.usePrefetch(i)&&(this.Bl.linearAdOpportunity=t,this.Bl.linearAdOpportunity.timestamp=Date.now(),this.DD(i,{linearAdOpportunity:this.Bl.linearAdOpportunity}),this.ci.disablePrefetch(i))}updateLinearPodRemainingTime(t){const i=this.Bl.adBreakState;this.jD(t)&&this.VD(Bi.LINEAR,t,i.adBreakType)}inFloatingChanged(t){this.Bl.inFloating=t}setCustomMacros(t){this.ci.getAllAvailableAdManagers().forEach((i=>i.setCustomMacros(t)))}setLineItemMetadata(t,i){const e=this.ci.getAdManagerByLinearity(Bi.LINEAR);(0,s.$K)(e)?e.setLineItemMetadata(t,i):i({success:!1,errorReason:si.AdManagerNotInitialized})}destroy(){try{(0,it.i)(this.Fc),this.ci.destroy()}catch(t){(0,p.n)({message:"AdManagerBridge_destroy",level:p.D.WARN,exception:t.message,callStack:t.stack})}}jD(t){const i=this.Bl.adBreakState;return!(t<=0)&&!(Math.round(t/Lt.s_)>i.remainingAdDuration)}FD(){this.ci.getAllAvailableAdManagers().forEach((t=>t.setQueryJsTargeting(this.Bl.queryJsTargeting)))}OD(t){t.forEach((t=>{this.CD.set(t.type,t.container)}))}VD(t,i,e){this.DD(t,{adBreakState:this.gI.getAdBreakState({adSlotDuration:i,adBreakType:e})})}DD(t,i){this.ND(i);const e=this.ci.getAdManagerByLinearity(t);if(e&&this.ci.isAdManagerEnable(t)){if(this.ci.usePrefetch(t)){const i=!1;this.ci.startSessionPrefetch(t,i)}e.enableImpressions(this.Bl),this.$D()}}ND(t){Object.assign(this.Bl,t),this.Bl.adBreakState=this.gI.getAdBreakState({adSlotDuration:this.Bl.adBreakState.remainingAdDuration,adBreakType:this.Bl.adBreakState.adBreakType})}$D(){this.ND({clickToPlay:!1,newContent:!1})}enablePrefetchForLinearity(t){if(this.ci.usePrefetch(t)&&this.ci.hasStartSessionPrefetch(t)){const i=this.ci.getAdManagerByLinearity(t);this.RD(t,be.StartSessionPrefetch,i)}}RD(t,i,e){this.ED&&this.LD&&(this.Bl.linearAdOpportunity=new de,this.ci.enablePrefetch(t,i,this.Bl,e))}GI(t){const i=Di(this.Ts.adSourceSettings.lineItems,Bi.NONLINEAR),e=Di(this.Ts.adSourceSettings.lineItems,Bi.LINEAR);(0,S.BZ)(i)&&this.UD(Bi.NONLINEAR,i,t),(0,S.BZ)(e)&&this.UD(Bi.LINEAR,e,t),this.qD(),this.zD(),this.WD()}WD(){const t=this.ci.getAdManagerByLinearity(Bi.LINEAR);this.Fc.push(null==t?void 0:t.onMissedImpression.subscribe((t=>{this.EI.next(t)})))}UD(t,i,e){const s=L.h.getSessionChildContainer(e.config.sessionId).resolve(yh.j),n=L.h.getSessionChildContainer(e.config.sessionId).resolve(vt.k),r={playerData:this.Ts.playerData,generalRepository:this.Ts.generalRepository,trackingResponseService:s,lineItemList:i,adBreakHelper:this.gI,adContainerMap:this.CD,amazonTamSlotId:this.Ts.amazonTamSlotId,pbjsSchainSettings:this.Ts.prebidJsSupplyChain,skipPlayerSettings:this.Ts.skipPlayerSettings,disableScrollHijackEnforcement:!this.Ts.adSourceSettings.disableScrollHijackEnforcement,pauseAdWhenFinished:this.Ts.pauseAdWhenFinished,loopAdWhenFinished:this.Ts.loopAdWhenFinished,app:e,lineItemAbTestInformation:this.Ts.lineItemAbTestInformation,appSettings:this.Ts.appSettings};(0,this.BD[t])(r,n),this.Fc.push(this.ci.onMidSessionPrefetchReady.subscribe((i=>{const{linearity:e,prefetchType:s}=i,n=this.ci.getAdManagerByLinearity(e);this.RD(t,s,n)})),this.ci.onPrefetchStart.subscribe((()=>{this.SI.next()})))}qD(){const t={[Bi.LINEAR]:this.xD,[Bi.NONLINEAR]:this.TD};Object.keys(t).forEach((i=>{const e=Bi[i];this.GD(e,t[e])}))}GD(t,i){const e=this.ci.getAdManagerByLinearity(t);e&&this.Fc.push(e.onVpaidEvent.subscribe((e=>{var s,n;switch(e.type){case T.AdLoaded:i.next({type:T.AdLoaded,payload:fh.adLoadedPayload(e)});break;case T.AdImpression:{const r=null===(n=null===(s=this.ci.getAdManagerByLinearity(t))||void 0===s?void 0:s.getCurrentAdMetadata())||void 0===n?void 0:n.adType,o=this.CD.get(r),h=this.getCurrentAdBreakType();i.next({type:T.AdImpression,payload:fh.impressionPayload(e,o,h)});break}case T.AdVideoStart:case T.AdError:i.next(e);break;default:i.next({type:e.type,payload:fh.defaultPayload(e)})}})))}zD(){const t=this.ci.getAdManagerByLinearity(Bi.LINEAR),i=this.ci.getAdManagerByLinearity(Bi.NONLINEAR);t&&this.Fc.push(t.onImpressionRevenueEvent.subscribe((t=>{this.kI.next(t),this.TI.next(t.impressionRevenue)})),t.onNoFill.subscribe((()=>{this.CI.next()}))),i&&this.Fc.push(i.onImpressionRevenueEvent.subscribe((t=>{this.kD.next(t),this.BI.next(t.impressionRevenue)})))}}var Ih=r(2300),wh=r(2246);class Sh extends wh._{constructor(){super(...arguments),this.QD=100}JD(){if(this.elapsedTimeoutId||!this.bo.duration)return;const t=Date.now();this.elapsedTimeoutId=setTimeout((()=>{this.bo.elapsedTime+=(Date.now()-t)/1e3;const i=this.bo.getComponent(Ih.r.ProgressBar);i&&i.setProgress((0,$i.dQ)(0,this.bo.duration,0,100,this.bo.elapsedTime)),this.elapsedTimeoutId=null,this.JD()}),this.QD)}initState(){super.initState(),this.bo.duration&&this.JD()}exitState(){super.exitState(),this.bo.duration&&(clearTimeout(this.elapsedTimeoutId),this.elapsedTimeoutId=null)}}var Ph=r(4291);class Ah extends Ph.d{initState(){super.initState()}exitState(){super.exitState()}}var _h=r(6664),xh=r(1277),Th=r(244),kh=r(9391),Ch=r(7263);class Eh extends Ch.P{constructor(){super(...arguments),this.eventList=[]}initComponent(){this.YD=this.In.getElementsByClassName(P.mr.BackgroundImg)[0],this.KD=this.In.getElementsByClassName(P.mr.Icon)[0],this.KD.innerHTML='<svg xmlns="http://www.w3.org/2000/svg" viewBox="2 2 20 20"><path d="M14 3v2h3.59l-9.83 9.83 1.41 1.41L19 6.41V10h2V3m-2 16H5V5h7V3H5a2 2 0 00-2 2v14a2 2 0 002 2h14a2 2 0 002-2v-7h-2v7z"/></svg>',this.ZD=this.In.getElementsByClassName(P.mr.ButtonContainer)[0];const t=this.In.getElementsByClassName(P.mr.Button)[0];this.tV=this.yn.createElementByString(`<a class="${P.mr.Wrapper}" href="#">`),this.tV.target=e.bS.Blank,this.tV.appendChild(t),this.ZD.innerHTML="",this.ZD.appendChild(this.tV),this.iV=this.In.getElementsByClassName(P.mr.InfoContainer)[0],this.eV=this.In.getElementsByClassName(P.mr.FallbackContainer)[0],this.sV=this.In.getElementsByClassName(P.mr.SlotCountText)[0]}setBackgroundImg(t){(0,s.QM)(t)?((0,u.IV)(this.YD,P.Gj.DisplayNone),this.YD.src=t):(0,u.cn)(this.YD,P.Gj.DisplayNone)}setClickUrl(t){if(!(0,s.QM)(t))return(0,u.Ho)(this.eV),void(0,u.MV)(this.iV);(0,u.Ho)(this.iV),(0,u.MV)(this.eV),this.tV.href=t}setFallbackText(t,i){const e=t||1,s=i||1;this.sV.innerHTML=`Loading ad ${e}/${s}`}}var Mh=r(9040);class Lh extends Mh.h{constructor(){super(...arguments),this.eventList=[Jt.C[Jt.C.SkipAd],...this.eventList],this.nV=-1,this.rV=-1}initComponent(){super.initComponent(),this.hideComponent(),this.hV=this.In.getElementsByTagName("cnx-span")[0],this.hV.innerHTML="Ad",this.aV=this.In.querySelectorAll(`.${P.Hs.Timer} svg`)[0],this.In.setAttribute("aria-label","Skip Ad")}setSecondsUntilSkip(t){this.nV=Math.ceil(t),this.rV=-1,this.nV>0&&(0,u.T7)(this.aV,{"animation-duration":this.nV+"s"})}tickDown(t){const i=this.nV-Math.floor(t);if(i<0||0===this.rV)return;const e=(0,u.pv)(this.In,P.Hs.InTimer);this.rV=i,0===this.rV?(e&&(0,u.IV)(this.In,P.Hs.InTimer),this.hV.innerHTML="Ad"):(e||(0,u.cn)(this.In,P.Hs.InTimer),this.hV.innerHTML=`in ${this.rV}s`)}get tooltip(){}onClickHandler(){0===this.rV&&this.mediator.publish(this,Jt.C[Jt.C.SkipAd])}}class Bh extends Th.A{constructor(){super(...arguments),this.cV={[Ih.r.VolumeControls]:t=>new xh.N(t,this.yn,kh.Z,this),[Ih.r.AdLoadingScreen]:t=>new Eh(t,this.yn,this.bn,'<cnx class="cnx-pod-loading-screen-container"><img alt="Loading Pods" class="cnx-pod-loading-background"><cnx class="cnx-pod-loading-info"><cnx class="cnx-pod-open-new-icon"></cnx><cnx class="cnx-pod-visit-website-text"><cnx-span>Visit Advertiser website</cnx-span></cnx><cnx class="cnx-pod-read-more-container"><cnx-span class="cnx-pod-read-more-btn">GO TO PAGE</cnx-span></cnx></cnx><cnx class="cnx-pod-loading-fallback"><cnx class="cnx-pod-loading-spinner"></cnx><cnx-span class="cnx-pod-slot-count-text"></cnx-span></cnx></cnx>'),[Ih.r.SkipAdButton]:t=>new Lh(t,this.yn,this.bn,'<cnx class="cnx-ad-skip-button cnx-ui-btn" role="button" tabindex="0"><cnx class="cnx-icon-button"><cnx class="cnx-skip-ad-text">Skip&nbsp;<cnx-span></cnx-span></cnx><cnx class="cnx-skip-ad-icon"><svg markup-inline viewBox="0 0 24 24" class="cnx-color-icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M18 21h3V3h-3v18zM3 21l14-9L3 3v18z" fill-rule="evenodd"/></svg></cnx></cnx><cnx class="cnx-timer-loader"><svg markup-inline xmlns="http://www.w3.org/2000/svg" width="36" height="36"><circle class="cnx-svg-circle-stroke" cx="18" cy="18" r="17"/></svg></cnx></cnx>',this.ci.isMobile)},this.dV=t=>i=>{var e,s;return null===(s=(e=this.cV)[t])||void 0===s?void 0:s.call(e,i)}}createComponent(t,i){return this.dV(t)(i)||super.createComponent(t,i)}}var Rh=r(1e3);class Oh extends _h.q{constructor(t,i,e,s,n,r={}){super(s,t,n,new Bh(t,e,s,r),r),this.Yg=i,this.$container=s,this.settings=r,this.lV=new J.x,this.Yr={[jt.Ez.PlayingState]:new Sh(this),[jt.Ez.PausedState]:new Ah(this)},this.uV=0,this.Tn=null,this.pV=t=>{(0,u.og)(this.$uiContainer,P.s6.UiInView,t)},this.ho.setDistanceValues({top:4,bottom:4}),this.Yr[jt.Ez.PausedState].enterState(),this.fV=this.$container.querySelector(`.${pe.Ek.CardImage}`),this.mV=this.$container.querySelector(`.${pe.Ek.CardTitle}`),this.gV=this.$container.querySelector(`.${pe.Ek.AdMarkerTitleText}`),this.vV=this.$container.querySelector(`.${pe.Ek.AdUiContent}`),this.Ws=L.h.getGlobalContainer().resolve(Jr.f)}get onUiEvent(){return this.lV.asObservable()}Wr(t,i,e){var s,n,r;switch(super.Wr(t,i,e),t){case Jt.C[Jt.C.Volume]:{const t=i.payload;this.lV.next({type:Jt.C.Volume,payload:{volume:t}});break}case Jt.C[Jt.C.Seek]:{const t=i.payload;this.lV.next({type:Jt.C.Seek,payload:{seek:t}});break}case Jt.C[Jt.C.Quality]:{const t=i.payload;this.lV.next({type:Jt.C.Quality,payload:{quality:t}});break}case Jt.C[Jt.C.HoverStart]:{const t=null===(s=null==i?void 0:i.payload)||void 0===s?void 0:s.targetComponent;this.lV.next({type:Jt.C.HoverStart,payload:t?{targetComponent:t}:void 0});break}case Jt.C[Jt.C.FocusStart]:this.yV();break;case Jt.C[Jt.C.HoverEnd]:{const t=null===(n=null==i?void 0:i.payload)||void 0===n?void 0:n.targetComponent;this.lV.next({type:Jt.C.HoverEnd,payload:t?{targetComponent:t}:void 0});break}case Jt.C[Jt.C.StateChanged]:{const t=null===(r=null==i?void 0:i.payload)||void 0===r?void 0:r.targetComponent;this.lV.next({type:Jt.C.StateChanged,payload:t?{targetComponent:t}:void 0});break}case Jt.C[Jt.C.RebindComponent]:{const t=i.payload;this.lV.next({type:Jt.C.RebindComponent,payload:{uiComponentEnum:t}});break}case Ih.r[Ih.r.CloseButton]:this.lV.next({type:Jt.C.Close});break;default:this.lV.next({type:Jt.C[t]})}}yV(){this.Ws.clearTimeout(this.bV),(0,u.cn)(this.$container,P.s6.PlayerFocused),this.bV=this.Ws.setTimeout((()=>{(0,u.IV)(this.$container,P.s6.PlayerFocused),this.ho.removeActiveTooltip()}),3e3)}updateDuration(t){const i=this.getComponent(Ih.r.ProgressBar),e=this.getComponent(Ih.r.TotalDurationLabel),s=this.getComponent(Ih.r.SkipAdButton);if(!t&&s&&(s.setSecondsUntilSkip(0),s.tickDown(0)),!t&&i)return i.setProgress(100),void i.updateWcagAttributes(0,0);this.elapsedTime=0,this.duration=t,i&&i.setProgress((0,$i.dQ)(0,t,0,100,0)),e&&e.setTime(t),this.wV(this.uV)}updateVolume(t){const i=this.getComponent(Ih.r.VolumeControls),e=this.getComponent(Ih.r.VolumeButton);i&&i.setVolume(t),e&&e.setVolume(t)}get elapsedTime(){return this.uV}set elapsedTime(t){this.uV=t,this.wV(this.uV)}showSkipAdButton(t){const i=this.getComponent(Ih.r.SkipAdButton);i&&(i.showComponent(),i.setSecondsUntilSkip(t))}hideSkipAdButton(){const t=this.getComponent(Ih.r.SkipAdButton);t&&t.hideComponent()}addPodAdMarker(t,i){(0,u.cn)(this.$uiContainer,pe.Ek.InPod);(0,S.Sz)(this.$uiContainer.getElementsByClassName(pe.Ek.AdMarkerInPodTextContainer)).forEach((e=>{e.innerHTML=`${t+1}/${i}`}))}removeAddPodAdMarker(){(0,u.IV)(this.$uiContainer,pe.Ek.InPod)}addDurationAdMarker(){(0,u.cn)(this.$uiContainer,pe.Ek.AdDurationLabel)}removeDurationAdMarker(){(0,u.IV)(this.$uiContainer,pe.Ek.AdDurationLabel)}wV(t){const i=this.getComponent(Ih.r.ElapsedTimeLabel);i&&i.setTime(t);const e=this.getComponent(Ih.r.SkipAdButton);e&&e.tickDown(t);const s=this.getComponent(Ih.r.ProgressBar);null==s||s.updateWcagAttributes(this.uV,this.duration);const n=this.getComponent(Ih.r.RemainingDurationLabel);if(n&&this.duration){const i=this.duration-t;i>=0&&n.setTime(i)}}hideAdLoadingScreen(){const t=this.getComponent(Ih.r.AdLoadingScreen);t&&t.hideComponent(),(0,u.IV)(this.$container,P.s6.PodLoadingScreen)}showAdLoadingScreen(t,i,e,s){const n=this.getComponent(Ih.r.AdLoadingScreen);n&&(n.showComponent(),n.setBackgroundImg(t),n.setClickUrl(i),n.setFallbackText(e,s),(0,u.cn)(this.$container,P.s6.PodLoadingScreen))}hideAdMarker(){const t=this.$container.querySelector(".cnx-ad-marker");(0,u.MV)(t)}hideProgressBar(){this.getComponent(Ih.r.ProgressBar).hideComponent()}setContinueReadingCard(t){this.fV.style.backgroundImage=`url("${t.imageSrc}")`,this.mV.innerText=t.title?t.title:""}addAdMarkerTitle(t){this.gV.innerHTML=t}cardHasData(){return(0,s.QM)(this.fV.style.backgroundImage)&&(0,s.QM)(this.mV.innerHTML)}showContinueReadingCard(t){(0,u.cn)(this.$container,P.s6.AdShowCard),null===this.Tn&&(this.Tn=this.globalDomUtilsService.requestAnimationFrameHelper((()=>{this.Tn=null,(0,u.T7)(t,{height:`${this.vV.clientHeight}px`})})))}hideContinueReadingCard(t){(0,u.IV)(this.$container,P.s6.AdShowCard),(0,u.aQ)(t,"height")}showAdMarkerTitle(){(0,u.cn)(this.$uiContainer,pe.Ek.AdTitleLabel)}hideAdMarkerTitle(){(0,u.IV)(this.$uiContainer,pe.Ek.AdTitleLabel)}show(){super.show(),this.Yg.on(this.$uiContainer,this.pV,{threshold:.5})}hide(){super.hide();(0,u.og)(this.$uiContainer,P.s6.UiInView,!1),this.Yg.off(this.$uiContainer,this.pV)}expand(){this.getComponent(Ih.r.ExpandButton).setState(Rh.q.expand)}collapse(){this.getComponent(Ih.r.ExpandButton).setState(Rh.q.collapse)}getComponent(t){return super.getComponent(t)}}class Dh{constructor(t){this.showExpandButton=t}get template(){return`\n            <cnx class="cnx-ui cnx-ui-ad">\n                <cnx class="cnx-ui-ad-content ${this.showExpandButton?"cnx-ad-fs":""}">\n                    <cnx class="cnx-ad-marker" aria-label="Ad" role="img">\n                        <cnx class="cnx-marker-cnt-first">\n                            <cnx class="cnx-marker-cnt-second">\n                                <cnx class="cnx-ad-marker-svg"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 22"><path d="M26,22H0V0H31.93L32,16A6,6,0,0,1,26,22Z" style="fill:#ffc800;fill-rule:evenodd"/><path d="M12,5.29h0L16.45,16.7H14.83l-1.06-2.85H8.86l-1,2.85H6.21L10.6,5.31h0Zm5.89,11.42V5.29h3.63A5.52,5.52,0,0,1,26.65,11a5.33,5.33,0,0,1-4.93,5.7H17.89Zm1.46-1.36h2.17c1.77,0,3.7-1.49,3.7-4.35s-1.93-4.28-3.7-4.28H19.35Zm-8-8.16-2,5.24h3.86Z" style="fill-rule:evenodd"/></svg>\n</cnx>\n                                <cnx class="cnx-ad-marker-text">1/1</cnx>\n                            </cnx>\n                            <cnx class="cnx-ad-marker-duration">[[${Ih.r.RemainingDurationLabel}]]</cnx>\n                        </cnx>\n                        <cnx class="cnx-ad-marker-title"><cnx-span class="cnx-ad-title-text"></cnx-span></cnx>\n                    </cnx>\n                    <cnx class="cnx-ad-buttons">\n                        <cnx class="cnx-ad-play-button cnx-ui-btn">[[${Ih.r.PlayButton}]]</cnx>\n                        <cnx class="cnx-ad-volume-controls">[[${Ih.r.VolumeControls}]]</cnx>\n                        <cnx class="cnx-ad-volume-button cnx-ui-btn">[[${Ih.r.VolumeButton}]]</cnx>\n                    </cnx>\n                    [[${Ih.r.SkipAdButton}]]\n                    <cnx class="cnx-ad-close-button cnx-ui-btn">[[${Ih.r.CloseButton}]]</cnx>\n                    ${this.getExpandTemplate()}\n                    <cnx class="cnx-ad-progress-bar">[[${Ih.r.ProgressBar}]]</cnx>\n                </cnx>\n                <cnx class="cnx-ad-card">\n                    <svg class="${pe.Ek.CardImage}" viewBox="0 0 16 9" />\n                    <cnx class="cnx-ad-card-text">\n                        <cnx>Continue watching</cnx>\n                        <cnx class="${pe.Ek.CardTitle}"></cnx>\n                        <cnx>after the ad</cnx>\n                    </cnx>\n                </cnx>\n                [[${Ih.r.AdLoadingScreen}]]\n            </cnx>\n        `.trim()}getExpandTemplate(){return this.showExpandButton?`<cnx class="cnx-ad-expand-button cnx-ui-btn cnx-hide-on-volume-hover cnx-d-sm-none">[[${Ih.r.ExpandButton}]]</cnx>`:""}}class Vh{static getScaledImageUrl(t,i,e,n,r){if(t&&!(0,$i.ON)({width:i,height:e}))return(0,s.r)(r)&&(i=(0,$i.Tc)(i,r),e=(0,$i.Tc)(e,r)),n.appendParamsToUrl(`${t}${Vh.getScaledImageQueryParams(i,e)}`.trim())}static getScaledImageQueryParams(t,i){return(0,$i.ON)({width:t,height:i})?"":`?width=${t}&height=${i}&fit=bounds`}static getSmartCroppedImageUrl(t,i,e,n){return(0,s.QM)(t)||(t=_t.n.endPoints.base.image),(0,$i.ON)({width:i,height:e})&&(i=140,e=80),n.appendParamsToUrl(`${t}${Vh.getSmartCroppedImageQueryParams(i,e)}`)}static getSmartCroppedImageQueryParams(t,i){return(0,$i.ON)({width:t,height:i})?"":`?crop=${t}:${i},smart&width=${t}&height=${i}&format=jpeg&quality=60&fit=crop`}static getDefaultPoster(t){const i=`${_t.n.endPoints.base.image}default_video_poster.svg`;return t.appendParamsToUrl(i)}}class Fh{constructor(t,i,e,s,n,r,o,h,a){this.Ts=t,this.fI=i,this.mI=e,this.gI=s,this.vI=n,this.Jv=r,this.yI=o,this.OI=h,this.zc=a,this.SV=[],this.PV=!1,this.AV=!1,this.YR=!1,this._V=0,this.Fm=0,this.xV=!0,this.TV=!1,this.kV=!1,this.CV=!1,this.Fc=[],this.AI=new J.x,this.wI=new J.x,this.EV=new J.x,this.LV=new J.x,this.BV=new J.x}rl(){this.Fc.push(this.RV(),this.OV())}DV(t){switch(t.type){case T.AdPaused:this.AI.next({type:pe.lc.PauseLinearEvent});break;case T.AdPlaying:this.AI.next({type:pe.lc.ResumeLinearEvent});break;case T.AdImpression:this.AI.next({type:pe.lc.ShowLinearEvent,payload:t.payload});break;case T.AdSkipped:this.AI.next({type:pe.lc.SkipLinearEvent});break;case T.AdStopped:this.AI.next({type:pe.lc.HideLinearEvent});break;case T.AdError:this.inImpression&&this.AI.next({type:pe.lc.HideLinearEvent})}}VV(t){var i;this.FV(),this.updateContinueReadingCard(),t.payload.adDuration=null===(i=this.OI.getCurrentAdMetadata(Bi.LINEAR))||void 0===i?void 0:i.duration,t.payload.adDuration||this.PV||this.show(),this.PV=!0,this.YR=!0,this.TV&&this.NV(),t.payload.adDuration?this.jV.addDurationAdMarker():this.jV.removeDurationAdMarker(),this.jV.updateDuration(t.payload.adDuration),this.jV.changeState(jt.Ez.PlayingState),this.$V=t.payload.clickThroughUrl,this.UV(t.payload.selectedAdSlot),this.gI.getTotalNumberOfSlots()>1?this.jV.addPodAdMarker(this.gI.getCurrentSlotIndex(),this.gI.getTotalNumberOfSlots()):this.jV.removeAddPodAdMarker()}qV(t=!1){const i=(e=this.Ts,s=this.vI.config,{logoUrl:e.logoUrl,isMobile:s.isMobile,closeButtonMode:e.closeButtonMode,floatingCloseButtonMode:e.floatingSettings.floatingCloseButtonMode,isCloseButton:e.isCloseButton,sharingDestinations:e.sharingDestinations});var e,s;this.jV=new Oh(this.vI.services.GlobalDomUtilsService,this.vI.services.ViewabilityService,this.vI.services.InteractionService,this.fI,new Dh(t).template,i),this.vI.config.isMobile&&(0,u.cn)(this.fI,P.s6.Mobile),this.jV.hide()}HV(){this.PR=this.zV(),this.WV(this.PR),this.SV.push(this.PR)}zV(t=""){return this.vI.services.GlobalDomUtilsService.createElementByString(`<div class= "cnx-ad-container cnx-full-height ${t}"></div>`)}WV(t){this.fI.appendChild(t)}RV(){return this.OI.onLinearVpaidEvent.subscribe((t=>{let i=!1;switch(t.type){case T.AdLoaded:this.TV=this.GV(t.payload),this.TV&&(t.payload.payload.adLoadedData.skipOffset=this.Ts.skipAdAfter);break;case T.AdPaused:this.CV=!1,this.jV.changeState(jt.Ez.PausedState);break;case T.AdPlaying:this.CV=!0,this.jV.changeState(jt.Ez.PlayingState);break;case T.AdImpression:this.CV=!0,this.VV(t.payload);break;case T.AdSkipped:this.XV(v.ProtoAdClickTypeEnum.AdSkipClick),this.QV(),i=!0;break;case T.AdStopped:case T.AdError:if(this.JV())return;this.QV(),i=!0;break;case T.AdClickThru:this.XV(v.ProtoAdClickTypeEnum.AdClickThrough)}this.xV&&(this.wI.next(t),this.DV(t)),this.xV=!0,i&&(this.YR=!1,this.CV=!1,this.jV.changeState(jt.Ez.PausedState))}))}OV(){return this.jV.onUiEvent.subscribe((t=>{switch(t.type){case Jt.C.Volume:this.setVolume(t.payload.volume),this.XV(v.ProtoAdClickTypeEnum.VolumeClick);break;case Jt.C.Play:this.XV(v.ProtoAdClickTypeEnum.PlayClick),this.play();break;case Jt.C.Pause:this.XV(v.ProtoAdClickTypeEnum.PauseClick),this.pause();break;case Jt.C.Expand:this.XV(v.ProtoAdClickTypeEnum.FullScreenClick),this.BV.next(Jt.C.Expand);break;case Jt.C.Collapse:this.XV(v.ProtoAdClickTypeEnum.ExitFullScreenClick),this.BV.next(Jt.C.Collapse);break;case Jt.C.Close:this.LV.next({type:w.Uh.UserInteraction,payload:{playback:!1}}),this.EV.next({type:Jt.C.Close});break;case Jt.C.Mute:this.setVolume(0),this.XV(v.ProtoAdClickTypeEnum.MuteClick);break;case Jt.C.Unmute:this.setVolume(1),this.XV(v.ProtoAdClickTypeEnum.UnmuteClick);break;case Jt.C.SkipAd:this.YV()}}))}NV(){this.jV.showSkipAdButton(this.Ts.skipAdAfter)}XV(t){var i;const e=null===(i=this.OI)||void 0===i?void 0:i.getCurrentAdMetadata(Bi.LINEAR);if(!e)return;const{advertiserLineItemId:s,publisherLineItemId:n}=e,r=this.OI.getCurrentAdBreakType();this.zc.adClick.next({advertiserLineItemId:s,publisherLineItemId:n,adBreakType:A.EN.fromProtoAdBreakType(r),type:A.EN.fromProtoAdClickType(t)})}GV(t){var i;const e=null===(i=this.OI)||void 0===i?void 0:i.getCurrentAdMetadata(Bi.LINEAR);if(!e)return!1;const{adSourceType:s}=e,{skipOffset:n}=t.payload.adLoadedData;return!(0,hi.AK)(s,n)&&(0,hi.Xj)(e.duration,this.Ts)}UV(t){this.SV.filter((i=>i!==t)).forEach((t=>{(0,u.cn)(t,P.Gj.Hide)}))}QV(){this.SV.forEach((t=>{(0,u.IV)(t,P.Gj.Hide)}))}KV(){this.kV=!1,this.jV.hideAdLoadingScreen()}FV(){this.jV.hideSkipAdButton()}start(t,i=!1){try{this.qV(i),this.HV(),this.setVolume(t),this.rl()}catch(t){(0,p.n)({callStack:t.stack,level:p.D.CRITICAL,exception:t.message,message:"linearAdhandler_start"})}}getVolume(){return this._V}increaseVolume(t,i=!1){if(i&&this.XV(v.ProtoAdClickTypeEnum.VolumeClick),this._V+t>1)return void this.setVolume(1);const e=this._V+t;this.setVolume(e)}decreaseVolume(t,i=!1){if(i&&this.XV(v.ProtoAdClickTypeEnum.VolumeClick),this.getVolume()-t<0)return void this.setVolume(0);const e=this.getVolume()-t;this.setVolume(e)}toggleMute(t=!1){if(t&&this.XV(0===this._V?v.ProtoAdClickTypeEnum.UnmuteClick:v.ProtoAdClickTypeEnum.MuteClick),0===this._V)return this.Fm=this.Fm>0?this.Fm:.2,void this.setVolume(this.Fm);this.Fm=this._V,this.setVolume(0)}hide(){(0,u.IV)(this.fI,P.s6.Ad,P.s6.AdOverlayType),this.jV.hide(),this.zc.adBreakEnd.next()}show(){var t,i;const e=[P.s6.Ad],s=null===(i=null===(t=this.OI)||void 0===t?void 0:t.getCurrentAdMetadata(Bi.LINEAR))||void 0===i?void 0:i.adType;s===v.ProtoAdType.Overlay&&e.push(P.s6.AdOverlayType),this.ZV=s,(0,u.cn)(this.fI,...e),this.jV.show(),this.jV.updateVolume(this._V),this.KV(),this.zc.adBreakStart.next({adSkippableInSeconds:this.NV?this.Ts.skipAdAfter:0,isLinear:!0})}setVolume(t){this._V=t,this.OI.setAdVolume(Bi.LINEAR,t),this.jV&&this.jV.updateVolume(t),this.LV.next({type:w.Uh.UserInteraction,payload:{volume:!0}}),this.EV.next({type:Jt.C.Volume,payload:{volume:t}})}resizeAd(t,i){this.inImpression&&(this.updateContinueReadingCard(),this.updateShowAdMarkerTitle())}adStateChange(t,i){this.OI.onAdStateChange(Bi.LINEAR,t,i)}getMainAdContainerWidth(){return this.OI.getMainAdContainerWidth(Bi.LINEAR)}resumeWithoutUserInteraction(){this.inImpression&&this.OI.resumeAd(Bi.LINEAR,!1)}play(){if(!this.inImpression)return;this.OI.resumeAd(Bi.LINEAR,!0),this.LV.next({type:w.Uh.UserInteraction,payload:{playback:!0}}),this.CV=!0}tF(t){if((0,a.Ph)("cnxShowAdCard",this.vI.config.pageUrl))return!0;let i=!1;if(t.adType===v.ProtoAdType.Video){const e=this.fI.clientWidth*(t.heightRatio/t.widthRatio);i=this.fI.clientHeight-e>=76}return t.adType===v.ProtoAdType.Overlay&&(i=this.fI.clientHeight-t.height>=76),i}updateContinueReadingCard(){const t=this.OI.getCurrentAdMediaSize(Bi.LINEAR);(0,s.$K)(t)&&(this.tF(t)?this.jV.showContinueReadingCard(this.PR):this.jV.hideContinueReadingCard(this.PR))}updateShowAdMarkerTitle(){this.AV&&this.fI.clientWidth>=320?this.jV.showAdMarkerTitle():this.jV.hideAdMarkerTitle()}setContinueReadingCard(t){this.jV.setContinueReadingCard({imageSrc:Vh.getSmartCroppedImageUrl(t.imageSrc,270,150,this.Jv),title:t.title})}hideContinueReadingCard(){this.jV.hideContinueReadingCard(this.PR)}setAdMarkerTitle(t){this.jV.addAdMarkerTitle(t),this.AV=!0,this.fI.clientWidth>=320&&this.jV.showAdMarkerTitle()}hideAdMarkerTitle(){this.jV.hideAdMarkerTitle()}pause(){if(!this.inImpression)return;this.OI.pauseAd(Bi.LINEAR,!0),this.LV.next({type:w.Uh.UserInteraction,payload:{playback:!1}}),this.CV=!1}togglePlay(t=!1){t&&this.XV(this.CV?v.ProtoAdClickTypeEnum.PauseClick:v.ProtoAdClickTypeEnum.PlayClick),this.CV?this.pause():this.play()}stopAd(t){const i=()=>{this.wI.next({type:T.AdStopped,payload:{payload:{adType:v.ProtoAdType.Video}}});const i=t===pe.aB.ForceStopAdSlot;this.AI.next({type:pe.lc.HideLinearEvent,forced:i}),this.xV=!1};this.OI?(i(),this.OI.stopAd(Bi.LINEAR,t)):this.inAdPodLoadingState&&i()}YV(){this.OI&&this.inImpression?this.OI.skipAd(Bi.LINEAR):this.kV&&(this.wI.next({type:T.AdSkipped}),this.KV())}enterAdPodLoadingState(){this.kV=!0;const{width:t,height:i}=this.OI.getAdContainerSize(this.ZV);this.jV.showAdLoadingScreen(Vh.getSmartCroppedImageUrl(this.iF,t,i,this.Jv),this.$V,this.gI.getNextSlotIndex(),this.gI.getTotalNumberOfSlots())}setAdLoadingBackgroundUrl(t){this.iF=t}destroy(){var t;(0,it.i)(this.Fc),null===(t=this.jV)||void 0===t||t.destroy()}get onVpaidEvent(){return this.wI.asObservable()}get onUiComponentEvent(){return this.EV.asObservable()}get onExperienceEvent(){return this.LV.asObservable()}get onLinearEvent(){return this.AI.asObservable()}get adUserInterface(){return this.jV}get adContainer(){return this.PR}get secondaryAdContainer(){return this.XI}get firstAdShown(){return this.PV}get inImpression(){return this.YR}get adInWin(){return this.OI.isAdInWin(Bi.LINEAR)}get inAdPodLoadingState(){return this.kV}get onFullcreenChange(){return this.BV.asObservable()}}class Nh extends Fh{VV(t){super.VV(t),this.Ts.outstreamAdAsContent&&this.eF()}JV(){return this.Ts.outstreamAdAsContent}eF(){this.jV.hideProgressBar(),this.jV.hideAdMarker(),this.FV()}}class jh{constructor(t,i,e,s,n,r,o,h,a){this.Ts=t,this.fI=i,this.mI=e,this.gI=s,this.vI=n,this.Jv=r,this.yI=o,this.OI=h,this.zc=a,this.Fc=[],this.MI=new J.x,this.wI=new J.x,this.LV=new J.x,this.SV=[],this.YR=!1,this.bI=x.Normal,this.sF=!1}rl(){this.Fc.push(this.OI.onNonlinearVpaidEvent.subscribe((t=>{switch(t.type){case T.AdImpression:this.VV(t.payload);break;case T.AdUserClose:this.XV(v.ProtoAdClickTypeEnum.AdUserClose);break;case T.AdError:this.QV();break;case T.AdClickThru:this.XV(v.ProtoAdClickTypeEnum.AdClickThrough)}this.wI.next(t),this.nF(t)})))}nF(t){switch(t.type){case T.AdImpression:this.show(),this.MI.next({type:pe.gx.ShowNonLinearEvent,payload:t.payload});break;case T.AdUserClose:this.hide();break;case T.AdStopped:this.hide(),this.MI.next({type:pe.gx.HideNonLinearEvent});break;case T.AdError:this.inImpression&&this.MI.next({type:pe.gx.HideNonLinearEvent})}}VV(t){this.YR=!0,this.UV(t.payload.selectedAdSlot)}HV(){this.PR=this.zV(),this.WV(this.PR),this.SV.push(this.PR)}zV(t=""){return this.vI.services.GlobalDomUtilsService.createElementByString(`<div class= "cnx-non-linear-ad-container cnx-full-height ${t}"></div>`)}WV(t){this.fI.appendChild(t)}XV(t){var i;const e=null===(i=this.OI)||void 0===i?void 0:i.getCurrentAdMetadata(Bi.NONLINEAR);if(!e)return;const{advertiserLineItemId:s,publisherLineItemId:n}=e,r=this.OI.getCurrentAdBreakType();this.zc.adClick.next({advertiserLineItemId:s,publisherLineItemId:n,adBreakType:A.EN.fromProtoAdBreakType(r),type:A.EN.fromProtoAdClickType(t)})}UV(t){this.SV.filter((i=>i!==t)).forEach((t=>{(0,u.cn)(t,P.Gj.Hide)}))}QV(){this.SV.forEach((t=>{(0,u.IV)(t,P.Gj.Hide)}))}rF(){var t;const i=null===(t=this.OI.getCurrentAdMediaSize(Bi.NONLINEAR))||void 0===t?void 0:t.height;if(!(0,s.r)(i))return!0;const e=this.adContainer.clientHeight,n=(0,$i.Tc)(e,oi.NON_LINEAR_MAX_HEIGHT_PERCENT);return Math.ceil(n)<i}start(){try{this.HV(),this.rl()}catch(t){(0,p.n)({callStack:t.stack,level:p.D.CRITICAL,exception:t.message,message:"nonLinearAdhandler_start"})}}hide(){(0,u.IV)(this.fI,P.s6.AdNonLinear),this.zc.adBreakEnd.next()}show(){(0,u.cn)(this.fI,P.s6.AdNonLinear),this.zc.adBreakStart.next({adSkippableInSeconds:0,isLinear:!1})}adStateChange(t,i){this.inImpression&&(t===v.ProtoAdSlotsEnum.PreRoll||t===v.ProtoAdSlotsEnum.PostRoll?this.pause():this.resumeWithoutUserInteraction(t),this.OI.onAdStateChange(Bi.NONLINEAR,t,i))}contentPlaybackStateChanged(t){this.sF=t,this.sF||this.pause()}resizeAd(t,i,e){this.inImpression&&this.sF&&(this.rF()?this.pause():this.resumeWithoutUserInteraction(e))}resumeWithoutUserInteraction(t){this.inImpression&&t!==v.ProtoAdSlotsEnum.PreRoll&&t!==v.ProtoAdSlotsEnum.PostRoll&&(this.rF()||(this.show(),this.OI.resumeAd(Bi.NONLINEAR,!1)))}pause(){if(!this.inImpression)return;this.hide();this.OI.pauseAd(Bi.NONLINEAR,!0),this.LV.next({type:w.Uh.UserInteraction,payload:{playback:!1}})}stopAd(t){if(!this.inImpression)return;const i=()=>{this.wI.next({type:T.AdStopped,payload:{payload:{adType:v.ProtoAdType.Nonlinear}}}),this.MI.next({type:pe.gx.HideNonLinearEvent})};this.OI&&(i(),this.OI.stopAd(Bi.NONLINEAR,t))}destroy(){(0,it.i)(this.Fc)}get onExperienceEvent(){return this.LV.asObservable()}get onNonLinearEvent(){return this.MI.asObservable()}get onVpaidEvent(){return this.wI.asObservable()}get adContainer(){return this.PR}get inImpression(){return this.YR}get adInWin(){return this.OI.isAdInWin(Bi.NONLINEAR)}}class $h extends jh{}class Uh extends we{DI(){const t={playerData:{isOutstream:this.Ts.isOutStreamType(),playbackMode:this.Ts.playbackMode,initialSoundMode:this.Ts.soundMode,hasFloatingCapability:this.Ts.floatingSettings.hasFloatingCapability,inFloating:this.uI,liveRampEnvelope:this.vI.services.UserManagerService.identityEnvelope},appSettings:this._appSettings,generalRepository:this.Dc,adSourceSettings:this.Ts.lineItemSettings,pauseAdWhenFinished:this.Ts.pauseAdWhenFinished,loopAdWhenFinished:this.Ts.loopAdWhenFinished,skipPlayerSettings:{skipAdAfter:this.Ts.skipAdAfter,skipMin:this.Ts.skipMin,skippability:this.Ts.skippability},adPlaybackMode:this.Ts.adPlaybackMode,amazonTamSlotId:this.Ts.amazonTamSlotId,prebidJsSupplyChain:this.Ts.supplyChainSettings,lineItemAbTestInformation:this.Ts.lineItemAbTestInformation,canPrefetch:this.Ts.prefetchOnPreroll,queryJsTargeting:this.Ts.queryJsTargeting};return new bh(t,this.yI,this.gI)}NI(t){return new Nh(this.Ts,this.fI,this.mI,this.gI,this.vI,this.Jv,this.yI,this.OI,t)}UI(t){return new $h(this.Ts,this.fI,this.mI,this.gI,this.vI,this.Jv,this.yI,this.OI,t)}}class qh{constructor(t,i){this.oF=t,this.hF=i,this.aF=null,this.cF=null,this.dF=0,this.lF=0,this.uF=!1,this.pF=!1,this.fF=!1,this.Rk=new Map,this.mF=new J.x,this.gF=new J.x,this.vF=new J.x,this.yF=new J.x,this.bF=new J.x,this.IF=new J.x,this.wF=new J.x,this.SF=new J.x,this.PF=new J.x,this.AF=new J.x,this.Fc=[],this._F={inImpression:!1};const{adBreaks:e}=this.oF.linearAdsControllerData;this.xF=e.some((t=>t.types.includes(v.ProtoAdBreakTypeEnum.PostRoll)))}start(){this.TF();const{totalAdBreakLength:t}=this.oF.linearAdsControllerData;if(t){const i=L.h.getGlobalContainer().resolve(Jr.f);this.kF=new Ks.B(i,t),this.Rk.set(this.kF,[this.kF.onTimeElapsed.subscribe((()=>{this.gF.next()}))])}}get currentPlayerAdSlot(){return this.aF}get onExperienceControllerStateChange(){return this.AF.asObservable()}get onCanPrefetchAds(){return this.PF.asObservable()}get onAdSlotDurationElapsed(){return this.mF.asObservable()}get onAdPodDurationElapsed(){return this.vF.asObservable()}get onAdPodTimeUpdate(){return this.yF.asObservable()}get onAdOpportunity(){return this.bF.asObservable()}get onAdsDisabled(){return this.IF.asObservable()}get onAdsEnabled(){return this.wF.asObservable()}get onTotalAdBreakDurationExpired(){return this.gF.asObservable()}get onMidRollCapped(){return this.SF.asObservable()}contentPlaybackStateChanged(t){var i,e;null===(e=(i=this.hF).contentPlaybackStateChanged)||void 0===e||e.call(i,t)}contentTimeUpdate(t){var i,e;null===(e=(i=this.hF).contentTimeUpdate)||void 0===e||e.call(i,t)}slideChanged(t){var i,e;null===(e=(i=this.hF).slideChanged)||void 0===e||e.call(i,t)}updateStoryTimeline(t){var i,e;null===(e=(i=this.hF).updateStoryTimeline)||void 0===e||e.call(i,t)}onAdImpression(t,i){this.hF.onAdImpression(this.aF,i),this.aF===v.ProtoAdSlotsEnum.MidRoll&&(this.fF=!0),this._F.inImpression=!0,this.CF(),this.EF()}contentChanged(t){this.hF.contentChanged(this.aF,t),this.lF=0}onAdFinished(t,i,e){this.hF.onAdFinished(this.aF,i,e),this.LF=this.BF(this.LF),this.fF=!1,i||(this.RF=this.BF(this.RF),this.aF===v.ProtoAdSlotsEnum.MidRoll?this.uF||this.lF++:this.dF++),this.OF()&&!i&&this.SF.next(),t&&(this.pF=!0),this._F.inImpression=!1}viewabilityStateChanged(t,i){var e,s;null===(s=(e=this.hF).viewabilityStateChanged)||void 0===s||s.call(e,this.aF,t,i)}onStop(){this.aF=null}onAdStateChange(t,i,e,s){this.hF.onAdStateChange(t,e,s),this.oF.linearAdsControllerData.maxAdSlotDuration=i.maxAdSlotDuration,this.oF.linearAdsControllerData.maxAdPodDuration=i.maxAdPodDuration,s||(t!==v.ProtoAdSlotsEnum.MidRoll&&(this.dF=0),null===t&&this.cF===v.ProtoAdSlotsEnum.MidRoll||(this.pF=!0),this.cF=t,this.aF=t)}canEnableAds(t){const i=this.hF.canEnableAds(this.aF,t);return i.enableAds?this._F.inImpression?{enableAds:!1,disableReason:ye.InImpression}:this.aF===v.ProtoAdSlotsEnum.MidRoll&&this.OF()||null===this.aF||this.aF!==v.ProtoAdSlotsEnum.MidRoll&&this.dF>0?{enableAds:!1,disableReason:ye.Unknown}:{enableAds:!0,disableReason:ye.Unknown}:i}enableAds(){this.wF.next(),this.kF&&this.kF.start()}disableAds(t,i){const e={disableReason:t,adBreakLength:this.DF(i)};this.IF.next({payload:e}),this.kF&&!this._F.inImpression&&this.kF.stop()}getTheoreticalDurationUntilNextOpportuinity(t){return this.aF===v.ProtoAdSlotsEnum.MidRoll&&this.OF()?-1:this.hF.getDurationUntilNextOpportunity(t)}onAdPlay(){this.RF&&this.RF.start(),this.LF&&this.LF.start(),this.kF&&this.kF.start()}onAdPause(){this.RF&&this.RF.stop(),this.LF&&this.LF.stop(),this.kF&&this.kF.stop()}triggerAdOpportunity(){this.pF&&(this.pF=!1,this.bF.next({payload:{adBreakType:ph[this.aF]}}))}startAds(t){var i,e;null===(e=(i=this.hF).startAds)||void 0===e||e.call(i,this.aF,t)}onNewMediaVideo(t){var i,e;this.uF=(0,S.BZ)(t),this.aF=null,null===(e=(i=this.hF).onNewMediaVideo)||void 0===e||e.call(i,t)}setAdHandler(t){this.hF&&this.hF.setAdHandler&&this.hF.setAdHandler(t)}destroy(){(0,it.i)(this.Fc),this.kF&&this.kF.disable(),this.LF=this.BF(this.LF),this.RF=this.BF(this.RF),this.hF.destroy()}TF(){var t;this.Fc.push(this.hF.onExperienceControllerStateChange.subscribe((t=>{this.AF.next(t)})),null===(t=this.hF.onCanPrefetchAds)||void 0===t?void 0:t.subscribe((()=>{this.PF.next()}))),this.hF.start()}VF(){const t=this.fF?1:0,{numberOfMidRolls:i}=this.oF.linearAdsControllerData;return this.lF===i-t}DF(t){return this.VF()&&!this.xF?Number.POSITIVE_INFINITY:this.hF.getAdBreakDuration(t)}OF(){if(this.uF)return!1;const{numberOfMidRolls:t}=this.oF.linearAdsControllerData;return this.lF>=t&&-1!==t}BF(t){if(t)return t.stop(),(0,it.i)(this.Rk.get(t)),this.Rk.delete(t),null}CF(){const{maxAdSlotDuration:t}=this.oF.linearAdsControllerData;if(!t||this.LF)return;const i=L.h.getGlobalContainer().resolve(Jr.f);this.LF=new Ks.B(i,t),this.LF.start(),this.Rk.set(this.LF,[this.LF.onTimeElapsed.subscribe((()=>{this.mF.next()}))])}EF(){const{maxAdPodDuration:t}=this.oF.linearAdsControllerData;if(!t||this.RF)return;const i=L.h.getGlobalContainer().resolve(Jr.f);this.RF=new Ks.B(i,t),this.RF.start(),this.Rk.set(this.RF,[this.RF.onTimeElapsed.subscribe((()=>{this.vF.next()})),this.RF.onTimeUpdate.subscribe((()=>{const t=this.RF.timeRemaining;this.yF.next(t)}))])}}class Hh{constructor(t,i){this.oF=t,this.FF=i,this.IF=new J.x,this.wF=new J.x,this.NF=0,this.AF=new J.x,this.Rk=new Map,this.Fc=[],this._F={inImpression:!1,linearInImpression:!1,inPrePostRoll:!1,contentPaused:!0,linearInOpportunity:!1},this.jF=!1,this.$F=!0}start(){this.TF(),this.initTimer()}get onExperienceControllerStateChange(){return this.AF.asObservable()}initTimer(){const t=L.h.getGlobalContainer().resolve(Jr.f);this.UF=new Ks.B(t,this.oF.resetNumberOfNonLinearAdsAfter),this.Rk.set(this.UF,[this.UF.onTimeElapsed.subscribe((()=>{this.NF=0,this.AF.next()}))])}TF(){this.Fc.push(this.FF.onExperienceControllerStateChange.subscribe((()=>{this.AF.next()}))),this.FF.start()}get onAdsDisabled(){return this.IF.asObservable()}get onAdsEnabled(){return this.wF.asObservable()}onLinearImpressionStateChange(t){this._F.linearInImpression=t,t?(this.UF.stop(),this.NF=0):(this.UF.reset(),this.UF.start(),this.FF.onLinearAdFinished())}onLinearOpportunityChange(t){this._F.linearInOpportunity=t}onAdStateChange(t){this._F.inPrePostRoll=!(t===v.ProtoAdSlotsEnum.MidRoll)}onAdFinished(){this.FF.onAdFinished(),this._F.inImpression=!1,this.NF++}onAdImpression(){this._F.inImpression=!0,0===this.NF&&(this.UF.reset(),this.UF.start())}canEnableAds(){return!!this.FF.canEnableAds()&&(!(this._F.inImpression||this._F.inPrePostRoll||this._F.linearInImpression||this._F.linearInOpportunity&&this.$F||this._F.contentPaused&&this.jF)&&!(this.NF>=this.oF.numberOfNonlinearAds&&this.oF.numberOfNonlinearAds>0))}viewabilityStateChanged(t){this.jF=t}onLinearNoDemand(){this.$F=!1}enableAds(){this.wF.next()}disableAds(){this.IF.next()}contentPlaybackStateChanged(t){this._F.contentPaused=!t,this.AF.next()}destroy(){var t;(0,it.i)(this.Fc),null===(t=this.FF)||void 0===t||t.destroy()}}class zh{constructor(t,i,e,n,r,o){var h;this.mediator=t,this.oF=n,this.Fc=[],this._F={stopped:!1,viewability:!1,forceDisable:!1,zeroDimension:!1,isAppBackgrounded:!1,restrictedOnCurrentMedia:!1,adBlockerActive:!0},this.HF=new qh(n,r),this.zF(r),this.viewabilityStateChanged(i),this.onResize(this.oF.playerDimensions.width,this.oF.playerDimensions.height),this.HF.start(),(0,s.hj)(null===(h=n.nonLinearAdsControllerData)||void 0===h?void 0:h.numberOfNonlinearAds)&&o&&this.WF(n.nonLinearAdsControllerData,o),e&&this.disableAdvertising(),this.onContentStop()}zF(t){this.Fc.push(this.HF.onAdSlotDurationElapsed.subscribe((()=>{this.mediator.publish(this,pi)})),this.HF.onAdPodDurationElapsed.subscribe((()=>{this.mediator.publish(this,fi)})),this.HF.onAdPodTimeUpdate.subscribe((t=>{this.mediator.publish(this,gi,{payload:{remainingTime:t}})})),this.HF.onAdOpportunity.subscribe((t=>{var i;null===(i=this.QF)||void 0===i||i.onLinearOpportunityChange(!0),this.mediator.publish(this,mi,t)})),this.HF.onAdsDisabled.subscribe((t=>{this.mediator.publish(this,ui,t)})),this.HF.onAdsEnabled.subscribe((()=>{this.mediator.publish(this,li)})),this.HF.onTotalAdBreakDurationExpired.subscribe((()=>{this.mediator.publish(this,di)})),this.HF.onMidRollCapped.subscribe((()=>{this.mediator.publish(this,ci)})),this.HF.onExperienceControllerStateChange.subscribe((t=>{(0,s.$K)(t)&&(t.inCuePoint?this.mediator.publish(this,wi):(t.cuePointTimedOut&&this.mediator.publish(this,pi),this.mediator.publish(this,Si))),this.JF()})),this.HF.onCanPrefetchAds.subscribe((()=>{this.mediator.publish(this,Pi,{payload:{linearity:Bi.LINEAR}})})))}WF(t,i){this.QF=new Hh(t,i),this.Fc.push(this.QF.onAdsDisabled.subscribe((()=>{this.mediator.publish(this,vi)})),this.QF.onAdsEnabled.subscribe((()=>{this.mediator.publish(this,yi)})),this.QF.onExperienceControllerStateChange.subscribe((()=>{this.JF()}))),this.QF.start()}slideChanged(t){this.HF.slideChanged(t)}updateStoryTimeline(t){this.HF.updateStoryTimeline(t)}contentPlaybackStateChanged(t){var i;this.HF.contentPlaybackStateChanged(t),null===(i=this.QF)||void 0===i||i.contentPlaybackStateChanged(t)}contentTimeUpdate(t){this.HF.contentTimeUpdate(t)}forceRecheck(){this.JF()}onAdImpression(t,i){var e;switch(i){case Bi.LINEAR:this.HF.onAdImpression(t,this.Tv);const i=!0;null===(e=this.QF)||void 0===e||e.onLinearImpressionStateChange(i);break;case Bi.NONLINEAR:this.QF.onAdImpression()}this.JF()}getTheoreticalDurationUntilNextOpportuinity(){return this.HF.canEnableAds(this.Tv).enableAds?0:this.HF.getTheoreticalDurationUntilNextOpportuinity(this.Tv)}onAdFinished(t,i,e=!1){var s,n;switch(i){case Bi.LINEAR:if(this.HF.onAdFinished(t,e,this.Tv),e)this.YF();else{const t=!1;null===(s=this.QF)||void 0===s||s.onLinearImpressionStateChange(t)}break;case Bi.NONLINEAR:null===(n=this.QF)||void 0===n||n.onAdFinished()}e||this.JF()}onLinearAdPause(){this.HF.onAdPause()}onLinearAdPlay(){this.HF.onAdPlay()}onContentStop(){this.HF.onStop(),this._F.stopped=!0,this.JF()}onAdStateChange(t,i,e){var s;null===(s=this.QF)||void 0===s||s.onAdStateChange(t);const n=t===this.HF.currentPlayerAdSlot&&t===v.ProtoAdSlotsEnum.MidRoll;n?this.HF.onAdStateChange(t,i,e,n):(this.HF.onAdStateChange(t,i,e,n),this.KF())}adBlockerStatusChange(t){this._F.adBlockerActive=t,this.JF()}KF(){this.HF.startAds(this.Tv),this._F.stopped=!1,this.JF()}contentChanged(){this.HF.contentChanged(this.Tv),this.JF()}viewabilityStateChanged(t,i=!1,e=!1){var s;this.HF.viewabilityStateChanged(t,i),null===(s=this.QF)||void 0===s||s.viewabilityStateChanged(t),this.Tv=t,this.oF.viewabilityPolicy===v.ProtoAdViewabilityPolicy.Strict&&(this._F.viewability=!t),e||this.JF()}setToggleAdsReason({isAppBackgrounded:t}){this._F.isAppBackgrounded=t,this.JF()}onLinearNoFill(){var t;null===(t=this.QF)||void 0===t||t.onLinearOpportunityChange(!1),this.ZF()}onLinearNoDemand(){var t;null===(t=this.QF)||void 0===t||t.onLinearNoDemand(),this.ZF()}disableAdvertising(){this.mediator.publish(this,bi),this._F.forceDisable=!0,this.JF()}enableAdvertising(){this.mediator.publish(this,Ii),this._F.forceDisable=!1,this.JF()}get isAdvertisingDisabled(){return this._F.forceDisable}get inView(){return this.Tv}onResize(t,i){this._F.zeroDimension=0===t||0===i,this.JF()}onNewMediaVideo(t,i=!1){this.HF.onNewMediaVideo(t),this._F.restrictedOnCurrentMedia=i,this.JF()}destroy(){(0,it.i)(this.Fc),this.HF.destroy()}JF(){const t=this.iN();t.enableAds?(this.eN(),this.ZF()):(this.nN(t.disableReason),this.rN())}eN(){const t=this.HF.canEnableAds(this.Tv);t.enableAds?this.YF():this.nN(t.disableReason)}ZF(){var t;(null===(t=this.QF)||void 0===t?void 0:t.canEnableAds())?this.oN():this.rN()}rN(){var t;null===(t=this.QF)||void 0===t||t.disableAds()}oN(){var t;null===(t=this.QF)||void 0===t||t.enableAds()}nN(t){this.HF.disableAds(t,this.Tv)}iN(){return this._F.forceDisable?{enableAds:!1,disableReason:ye.ForceDisable}:Object.keys(this._F).some((t=>this._F[t]))?{enableAds:!1,disableReason:ye.Unknown}:{enableAds:!0,disableReason:ye.Unknown}}setAdHandler(t){this.HF.setAdHandler(t)}YF(){this.HF.triggerAdOpportunity(),this.HF.enableAds()}}var Wh,Gh=r(7953);!function(t){t[t.None=0]="None",t[t.MinTimeBeforeFirstAd=1]="MinTimeBeforeFirstAd",t[t.TimeBetweenAds=2]="TimeBetweenAds"}(Wh||(Wh={}));class Xh{constructor(t,i){this.hN=t,this.aN=i,this.cN=!1,this._F={inTimeout:!1},this.dN=!1,this.lN=new J.x,this.Fc=[]}get onExperienceTimeoutControllerStateChange(){return this.lN.asObservable()}init(){const t=L.h.getGlobalContainer().resolve(Jr.f);this.uN=new Ks.B(t,this.hN),this.Fc.push(this.uN.onTimeElapsed.subscribe((()=>{this.cN||(this.cN=!0),this._F.inTimeout=!1,this.dN=!0,this.lN.next()})))}canEnableAds(t,i){return t===v.ProtoAdSlotsEnum.MidRoll&&this._F.inTimeout&&i?{enableAds:!1,disableReason:ye.TimeoutBetweenAds}:{enableAds:!0,disableReason:ye.Unknown}}startAds(t,i){this.pN(t,i)}getAdBreakDuration(t){const i=this.fN(t);return i===Wh.MinTimeBeforeFirstAd?this.hN:i===Wh.TimeBetweenAds?this.aN:0}getDurationUntilNextOpportunity(){return this.uN.timeRemaining/Lt.s_}onAdImpression(t,i){t===v.ProtoAdSlotsEnum.MidRoll&&(this.cN||(this.cN=!0)),this.mN=!i}onAdFinished(t,i,e){this.dN=!1,this.cN&&!this.mN&&e&&!i&&this.pN(t,e)}viewabilityStateChanged(t,i,e){e||this.pN(t,i)}onAdStateChange(t){t!==v.ProtoAdSlotsEnum.MidRoll&&(this.cN=!1),this.dN=!1}contentPlaybackStateChanged(t){t?this.uN.start():this.uN.stop()}contentChanged(t,i){this._F.inTimeout=!1,this.uN.stop(),this.cN=!1,this.dN=!1,this.pN(t,i)}disable(){this.uN.reset(),this.uN.disable()}destroy(){(0,it.i)(this.Fc),this.uN.disable()}pN(t,i){if(t===v.ProtoAdSlotsEnum.MidRoll&&!this._F.inTimeout&&!this.dN){const t=this.fN(i);t===Wh.MinTimeBeforeFirstAd?this.gN():t===Wh.TimeBetweenAds&&this.vN(),this.lN.next()}}vN(){this._F.inTimeout=!0,this.uN.reset(this.aN)}gN(){this._F.inTimeout=!0,this.uN.reset(this.hN)}fN(t){return!this.cN&&this.hN?Wh.MinTimeBeforeFirstAd:this.cN&&this.aN&&t?Wh.TimeBetweenAds:Wh.None}}class Qh{constructor(){this.yN=!1,this.bN=[],this.IN=0,this.wN=new J.x,this.PF=new J.x,this.Rk=new Map;const t=L.h.getGlobalContainer().resolve(Jr.f);this.SN=new Ks.B(t,2*Lt.s_),this.Rk.set(this.SN,[this.SN.onTimeElapsed.subscribe((()=>{this.PN()}))])}get onExperienceCuePointsControllerStateChange(){return this.wN.asObservable()}get onCanPrefetchAds(){return this.PF.asObservable()}canEnableAds(t){return this.yN||t!==v.ProtoAdSlotsEnum.MidRoll?{enableAds:!0,disableReason:ye.Unknown}:{enableAds:!1,disableReason:ye.Unknown}}getDurationUntilNextOpportunity(){let t;return this.bN.some((i=>{if(this.IN<=i)return t=i,!0})),t?t-this.IN:0}contentTimeUpdate(t){t&&(this.IN=t,this.AN(),this._N())}onAdImpression(){this.yN=!1,this.xN()}onAdFinished(t,i){i||(this.TN=void 0,this.wN.next({inCuePoint:!1}))}onNewMediaVideo(t){this.TN=void 0,this.kN=void 0,this.yN=!1,(0,S.BZ)(t)&&(this.bN=t.map((t=>t.timeStamp)).sort(((t,i)=>t-i)))}setAdHandler(t){this.Gf=t}_N(){this.bN.forEach(((t,i)=>{let e=t-10;i-1>=0&&this.bN[i]-this.bN[i-1]<=10&&(e=this.bN[i-1]),(0,$i.mg)(this.IN,e,t)&&this.TN!==i&&(this.TN=i,this.PF.next())}))}PN(){this.TN=void 0,this.yN=!1,this.wN.next({inCuePoint:!1,cuePointTimedOut:!0}),this.xN()}xN(){this.SN.reset(),this.SN.stop()}AN(){var t;let i,e=!1;if(!(this.bN.length<=0)&&(this.bN.forEach(((t,s)=>{if((0,$i.mg)(this.IN,t,t+2))return e=!0,void(i=s)})),e&&void 0!==i&&this.kN!==i)){if(this.kN=i,!(null===(t=this.Gf)||void 0===t?void 0:t.hasAdsEligibleForFill()))return void(0,p.n)({message:"ElementsCuePointsController_cuepoint_not_filled",level:p.D.INFO},{pacing:100});this.yN=!0,this.wN.next({inCuePoint:!0}),this.SN.start()}}}class Jh{constructor(t){this.oF=t,this._F={limitAdsOnMidRoll:!1},this.AF=new J.x,this.PF=new J.x,this.Fc=[],this.CN(),this.MN(),this.LN=this.BN}start(){this._F.limitAdsOnMidRoll=!0,this.BN.init()}get onExperienceControllerStateChange(){return this.AF.asObservable()}get onCanPrefetchAds(){return this.PF.asObservable()}canEnableAds(t,i){const e=this.LN.canEnableAds(t,i);return e.enableAds?t===Gh.ProtoAdSlotsEnum.MidRoll&&this._F.limitAdsOnMidRoll?{enableAds:!1,disableReason:ye.Unknown}:{enableAds:!0,disableReason:ye.Unknown}:e}startAds(t,i){var e,s;null===(s=(e=this.LN).startAds)||void 0===s||s.call(e,t,i)}getAdBreakDuration(t){var i,e;return null===(e=(i=this.LN).getAdBreakDuration)||void 0===e?void 0:e.call(i,t)}getDurationUntilNextOpportunity(){return this.LN.getDurationUntilNextOpportunity()}onAdImpression(t,i){this.LN.onAdImpression(t,i)}onAdFinished(t,i,e){var s,n;null===(n=(s=this.LN).onAdFinished)||void 0===n||n.call(s,t,i,e)}viewabilityStateChanged(t,i,e){var s,n;null===(n=(s=this.LN).viewabilityStateChanged)||void 0===n||n.call(s,t,i,e)}onAdStateChange(t,i,e){var s,n;const r=this._F.limitAdsOnMidRoll;this.RN(t,i),r!==this._F.limitAdsOnMidRoll&&this.AF.next(),e||null===(n=(s=this.LN).onAdStateChange)||void 0===n||n.call(s,t)}contentPlaybackStateChanged(t){var i,e;null===(e=(i=this.LN).contentPlaybackStateChanged)||void 0===e||e.call(i,t)}contentChanged(t,i){var e,s;this._F.limitAdsOnMidRoll=!0,null===(s=(e=this.LN).contentChanged)||void 0===s||s.call(e,t,i)}onNewMediaVideo(t){var i,e;(0,S.BZ)(t)?(this.LN=this.DN,null===(e=(i=this.LN).onNewMediaVideo)||void 0===e||e.call(i,t),this.BN.disable()):this.LN=this.BN}contentTimeUpdate(t){var i,e;null===(e=(i=this.LN).contentTimeUpdate)||void 0===e||e.call(i,t)}destroy(){var t,i;(0,it.i)(this.Fc),null===(i=(t=this.LN).destroy)||void 0===i||i.call(t)}setAdHandler(t){this.DN.setAdHandler(t)}CN(){this.BN=new Xh(this.oF.minTimeBeforeAdBreak,this.oF.timeBetweenAds),this.Fc.push(this.BN.onExperienceTimeoutControllerStateChange.subscribe((()=>{this.AF.next()})))}MN(){this.DN=new Qh,this.Fc.push(this.DN.onExperienceCuePointsControllerStateChange.subscribe((t=>{this.AF.next(t)})),this.DN.onCanPrefetchAds.subscribe((()=>{this.PF.next()})))}RN(t,i){this._F.limitAdsOnMidRoll=this.oF.midRollOnlyOnLongContent&&t===Gh.ProtoAdSlotsEnum.MidRoll&&(!i||i<480)}}class Yh{constructor(t){this.FN=t,this._F={inTimeoutBetweenNonLinears:!1,inTimeoutBetweenLinearAndNonLinear:!1},this.AF=new J.x,this.Fc=[]}start(){const t=L.h.getGlobalContainer().resolve(Jr.f);this.jN=new Ks.B(t,this.FN.timeSecondsBetweenNonlinear*Lt.s_),this.$N=new Ks.B(t,this.FN.timeSecondsBetweenLinearAndNonlinear*Lt.s_),this.Fc.push(this.jN.onTimeElapsed.subscribe((()=>{this._F.inTimeoutBetweenNonLinears=!1,this.AF.next()})),this.$N.onTimeElapsed.subscribe((()=>{this._F.inTimeoutBetweenLinearAndNonLinear=!1,this.AF.next()})))}get onExperienceControllerStateChange(){return this.AF.asObservable()}canEnableAds(){return!Object.keys(this._F).some((t=>this._F[t]))}onAdFinished(){this.FN.timeSecondsBetweenNonlinear&&(this._F.inTimeoutBetweenNonLinears=!0,this.jN.reset(),this.jN.start())}onLinearAdFinished(){this.FN.timeSecondsBetweenLinearAndNonlinear&&(this._F.inTimeoutBetweenLinearAndNonLinear=!0,this.$N.reset(),this.$N.start())}destroy(){var t,i;(0,it.i)(this.Fc),null===(t=this.jN)||void 0===t||t.disable(),null===(i=this.$N)||void 0===i||i.disable()}}const Kh={xl:720,lg:320,md:204,sm:142,xs:0},Zh={[v.ProtoDeviceType.Desktop]:{xl:468,lg:388,md:248,sm:142,xs:0},[v.ProtoDeviceType.Tablet]:Object.assign({},Kh),[v.ProtoDeviceType.Smartphone]:Object.assign({},Kh)},ta={xl:500,lg:288,md:212,sm:143,xs:80},ia={xl:720,lg:320,md:204,sm:142,xs:0},ea={[v.ProtoDeviceType.Desktop]:{xl:468,lg:388,md:248,sm:142,xs:0},[v.ProtoDeviceType.Tablet]:Object.assign({},ia),[v.ProtoDeviceType.Smartphone]:Object.assign({},ia)},sa=176,na=160,ra=144,oa=112,ha={xl:ia.xl+sa,lg:ia.lg+na,md:ia.md+ra,sm:ia.sm+oa},aa={[v.ProtoDeviceType.Desktop]:{xl:468+sa,lg:388+na,md:248+ra,sm:142+oa,xs:0},[v.ProtoDeviceType.Tablet]:Object.assign({},ha),[v.ProtoDeviceType.Smartphone]:Object.assign({},ha)},ca={lg:320,md:204,sm:0},da={[v.ProtoDeviceType.Desktop]:{xl:468,lg:388,md:248,sm:0},[v.ProtoDeviceType.Tablet]:Object.assign({},ca),[v.ProtoDeviceType.Smartphone]:Object.assign({},ca)},la={xxl:1080,xl:0},ua={[v.ProtoDeviceType.Desktop]:{xxl:720,xl:0},[v.ProtoDeviceType.Tablet]:Object.assign({},la),[v.ProtoDeviceType.Smartphone]:Object.assign({},la)},pa={[Gh.ProtoGalleryOrientationEnum.Landscape]:{[Gh.ProtoGalleryStyleMode.Detailed]:ua,[Gh.ProtoGalleryStyleMode.Visual]:aa},[Gh.ProtoGalleryOrientationEnum.Portrait]:{[Gh.ProtoGalleryStyleMode.Detailed]:da,[Gh.ProtoGalleryStyleMode.Visual]:ea}};class fa extends ve{constructor(){super(...arguments),this.Zb=Zh,this.tI=P.Rq,this.zb=0,this.UN=9e4}get type(){return this.Ab.playerType}Hb(){this.$playerContentWrapper=this.app.services.GlobalDomUtilsService.createElementByString(`<cnx class="${this.Ab.floatingSettings.isPinnedFloating?P._7.PinnedWrapper:P._7.ContentWrapper}"></cnx>`),this.$playerContentWrapper.appendChild(this.$playerContainer),this.$playerWrapper.appendChild(this.$playerContentWrapper),this.floatingModule=new Ti(this.app.services.ViewabilityService,this.Dc,this.app.services.ResizeObserver,this.$playerContainer.parentElement,this.Ab.floatingSettings,this.app.config.device,this.app.services.GlobalDomUtilsService,this.zb),this.qb(),this.floatingModule.start(),this.floatingStateMachine=new Ei(this.floatingModule,this.Ab.floatingSettings.floatingMode)}iI(){super.iI(this.$playerContainer.parentElement)}Sb(t=!1){super.Sb(t,this.$playerContainer.parentElement)}ub(){var t,i;const e=!(!(null===(t=this.floatingModule)||void 0===t?void 0:t.isInFloating)&&!(null===(i=this.alwaysFloatingModule)||void 0===i?void 0:i.isInFloating));return new Uh(e,this.hb.isAdvertisingDisabled,this.Ab,this.Dc,this.$playerContainer,this.checkFloatingViewability(this.isViewable()),this.ob,this.app,this._appSettings,this.Jv,this.Cb(this.$playerContainer.clientWidth,this.$playerContainer.clientHeight))}generateHTML(){this.$playerWrapper=this.app.services.GlobalDomUtilsService.createElementByString(`<cnx class="${P.sN.PlayerWrapper}"></cnx>`),this.$playerContainer=this.app.services.GlobalDomUtilsService.createElementByString("<cnx class='cnx-video-container'></cnx>"),this.addPlayerSize(),this.$experienceContainer.appendChild(this.$playerWrapper),this.$playerWrapper.appendChild(this.$playerContainer)}setFloatingSettings(t){super.setFloatingSettings(t),this.Ab.floatingSettings.isPinnedFloating?((0,u.IV)(this.$playerContentWrapper,P._7.ContentWrapper),(0,u.cn)(this.$playerContentWrapper,P._7.PinnedWrapper)):((0,u.IV)(this.$playerContentWrapper,P._7.PinnedWrapper),(0,u.cn)(this.$playerContentWrapper,P._7.ContentWrapper)),this.Wf.floatingChanged(this.Ab.floatingSettings.isPinnedFloating)}getFloatingSettings(){return super.getFloatingSettings()}addPlayerSize(){this.Ab.playerSize.responsive?(this.$playerWrapper.appendChild(this.Ob()),(0,u.cn)(this.$playerWrapper,P.Ig.Responsive)):(this.setFixedSize(this.$experienceContainer),(0,u.cn)(this.$playerWrapper,P.Ig.Fixed))}setFixedSize(t){(0,u.T7)(t,{width:`${this.Ab.playerSize.fixedWidth}px`,height:`${this.Ab.playerSize.fixedHeight}px`})}dI(){var t,i;let e;if(this.Ab.nonlinearPlayerSettings){const{timeSecondsBetweenNonlinear:t,timeSecondsBetweenLinearAndNonlinear:i}=this.Ab.nonlinearPlayerSettings;e=new Yh({timeSecondsBetweenLinearAndNonlinear:i,timeSecondsBetweenNonlinear:t})}const s=new Jh({midRollOnlyOnLongContent:this.Ab.midRollOnlyOnLongContent,minTimeBeforeAdBreak:this.Ab.minTimeBeforeFirstAd,timeBetweenAds:this.Ab.timeBetweenAds});return new zh(this,this.isViewable(),this.Ab.disableAdvertising,{linearAdsControllerData:{numberOfMidRolls:this.Ab.midRollNumber,adBreaks:this.Ab.adBreaks,maxAdSlotDuration:this.ob.getMaxAdSlotDuration(),maxAdPodDuration:this.ob.getMaxAdPodDuration(),totalAdBreakLength:this.Ab.outstreamSettings?this.Ab.outstreamSettings.totalAdBreakLength:void 0},nonLinearAdsControllerData:{resetNumberOfNonLinearAdsAfter:0!==this.Ab.midRollNumber?this.Ab.timeBetweenAds:this.UN,numberOfNonlinearAds:null===(i=null===(t=this.Ab)||void 0===t?void 0:t.nonlinearPlayerSettings)||void 0===i?void 0:i.numberOfNonlinearAds},viewabilityPolicy:this.Ab.adViewabilityPolicy,playerDimensions:{width:this.$playerContainer.offsetWidth,height:this.$playerContainer.offsetHeight}},s,e)}cI(){var t;null===(t=this.Ef)||void 0===t||t.start(this.$playerContainer,!0,this.Ab.enableNewUI)}}const ma=Object.assign(Object.assign(Object.assign(Object.assign({},{VideoStarted:"videoStarted",VideoCompleted25:"videoCompleted25",VideoCompleted50:"videoCompleted50",VideoCompleted75:"videoCompleted75",VideoCompleted100:"videoCompleted100",NewVideo:"newVideo"}),{SubtitlesVisibilityChanged:"subtitlesVisibilityChanged"}),{PlayerClicked:"playerClicked"}),{GalleryCardClicked:"galleryCardClicked"}),ga={Collapsed:"collapsed",AdCycleComplete:"adCycleComplete"},va=Object.assign(Object.assign({},w.dP),{FirstFramePlayed:"firstFramePlayed",ContentQuartiles:"contentQuartiles",MediaMetaUpdate:"mediaMetaUpdate",ChangeVideo:"changeVideo",VideoQueued:"videoQueued"}),ya=Object.assign(Object.assign(Object.assign({},M.Km),ma),ga);var ba=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class Ia extends fa{constructor(){super(...arguments),this.events=Object.assign(Object.assign({},M.Km),ma),this.qN=new at.X(!1),this.HN=!1,this.zN=!0,this.WN=[],this.GN=new at.X(!1),this.XN={[jt.Ez.PlayingState]:()=>{var t;this.ib(v.ProtoAdSlotsEnum.MidRoll);null===(t=this.adHandler)||void 0===t||t.contentPlaybackStateChanged(true),this.hb.contentPlaybackStateChanged(true)},[jt.Ez.PrerollState]:()=>{this.ib(v.ProtoAdSlotsEnum.PreRoll)},[jt.Ez.PostrollState]:()=>{this.ib(v.ProtoAdSlotsEnum.PostRoll)},[jt.Ez.PausedState]:()=>{this.uy===v.ProtoAdSlotsEnum.PreRoll&&this.ib(v.ProtoAdSlotsEnum.MidRoll)},[jt.Ez.StoppedState]:()=>{this.uy===v.ProtoAdSlotsEnum.PostRoll&&this.Ab.upNextMode!==Gh.ProtoPlayerUpNextMode.Stop?(this.ib(v.ProtoAdSlotsEnum.MidRoll),this.Gy()):(this.cb(),this.hb.onContentStop(),this.Gy())}},this.QN=({payload:t})=>{t===jt.Ez.PlayingState&&(this.unsubscribe(va.StateChanged,this.Wf,this.QN),this.mediator.publish(this,ma.VideoStarted,{payload:this.getVideoDetails()}))},this.JN=t=>{const i=this.XN[t];return()=>{var e;if(t!==jt.Ez.PlayingState){const t=!1;null===(e=this.adHandler)||void 0===e||e.contentPlaybackStateChanged(t),this.hb.contentPlaybackStateChanged(t)}i&&i()}},this.YN=()=>{this.qN.next(!0),this.KN.enterFullScreen().then((()=>{this.Wf.enterFullscreen(),this.floatingModule&&this.floatingModule.fullscreenStateChange(!0)})).catch((t=>{(0,p.n)({level:p.D.WARN,message:"BaseVideoExperience_enterFullscreen"})}))},this.Rb=()=>{this.qN.next(!1),this.Wf.exitFullscreen(),this.floatingModule&&this.floatingModule.fullscreenStateChange(!1),this.app.services.GlobalDomUtilsService.hasIosFullscreenBehaviour(this.app.config.os.os)&&(this.HN=this.Wf.isIosFullscreen=!1,this.ib(this.uy)),this.mediator.publish(this,M.Zr.FullscreenChanged,{payload:!1}),super.Rb()},this.Bb=()=>{this.app.services.GlobalDomUtilsService.hasIosFullscreenBehaviour(this.app.config.os.os)&&(this.HN=this.Wf.isIosFullscreen=!0,this.hb.onContentStop()),this.mediator.publish(this,M.Zr.FullscreenChanged,{payload:!0}),super.Bb()}}start(){const t=Object.create(null,{start:{get:()=>super.start}});return ba(this,void 0,void 0,(function*(){try{t.start.call(this),this.ZN(),this.GN.next(!0),this.app.config.isOVPDomain?this.Py.push(C._.onAdBlockerDetected().subscribe((t=>{t||this.tj(),this.hb.adBlockerStatusChange(t)}))):this.tj(),this.ij(this.Wf,this.adHandler),this.ej();const i=!!this.alwaysFloatingModule||this.floatingModule.isInFloating;yield this.Wf.start(i),this.kb(),this.Yb(this.Wf),this.nj(),this.rj(),this.oj()}catch(t){(0,p.n)({message:"BaseVideoExperience_Start",exception:t.message,callStack:t.stack,level:p.D.CRITICAL})}}))}oj(){if(this.Ab.playbackMode===v.ProtoPlayerPlaybackModeEnum.ClickToPlay&&this.isFloatingModeEnabled()){this.aj=this.cj.cloneNode();this.$playerContentWrapper.querySelector(`.${P.s6.VideoWrapper}`).appendChild(this.aj)}}dj(){const t=this.KN.onFullScreenEnter.subscribe((()=>this.Bb())),i=this.KN.onFullScreenExit.subscribe((()=>this.Rb()));this.WN.push(i,t)}changeVideo(t,i=!1){if(this.adHandler){if(this.adHandler.linearInImpression)this.adHandler.stopAd(pe.aB.ChangeVideo);else{const t=!0;this.Sb(t)}this.adHandler.userInteraction(i)}this.Wf.setVideo(t)}play(t=!0){this.adHandler&&this.adHandler.linearInImpression?this.adHandler.play():this.Wf.play(t)}pause(t=!0){var i,e;null===(i=this.adHandler)||void 0===i||i.pause(),(null===(e=this.adHandler)||void 0===e?void 0:e.linearInImpression)||this.Wf.pause(t)}setNewVolume(t){super.setNewVolume(t),this.Wf.volume=t}getVolume(){return this.Wf.volume}get currentTime(){return this.Wf.currentTime}set currentTime(t){this.Wf.currentTime=t}get duration(){return this.Wf.duration}getVideoDetails(){let t;return this.Wf.getCurrentVideoData((i=>{t=this.lj(i)})),t}getUpNextVideoDetails(){let t;return this.Wf.getUpNextVideoData((i=>{t=this.lj(i)})),t}toggleFullscreen(t=!this.KN.isFullscreen){return this.KN.isFullscreen===t||(t?this.YN():this.KN.exitFullScreen()),t}toggleCaptions(t=!this.Wf.areCaptionsEnabled){t?this.showCaptions():this.hideCaptions()}togglePlay(){return this.Wf.togglePlay()}toggleMute(){this.Wf.toggleMute()}increaseVolume(t){this.Wf.increaseVolume(t)}decreaseVolume(t){this.Wf.decreaseVolume(t)}showCaptions(t){this.Wf.showCaptions(t);const i=this.Wf.getSelectedCaption();this.Wf.updateCaptionsMenuUI(null==i?void 0:i.file)}getSubtitles(){return this.Wf.getSubtitles()}hideCaptions(){this.Wf.hideCaptions(),this.Wf.updateCaptionsMenuUI()}toggleExpandButton(t){this.Wf.toggleExpandButton(t)}getPlaylistId(){return this.Ab.playlistId}getPlaylistDetails(){return Object.assign(Object.assign({},this.Ab.getPlaylistDetails()),this.uj)}pj(t){return new Promise(((i,e)=>{const s=()=>this.Wf.getVideoData(t,(t=>i(this.lj(t))),(t=>e(t)));this.GN.value?s():this.GN.pipe((0,dt.h)((t=>!!t)),(0,lt.q)(1)).subscribe((t=>t&&s()))}))}getAllMetadata(){const t=this.Ab.playlist.length;return Promise.all([...Array(t)].map(((t,i)=>this.pj(i))))}setPlaylistDetails(t){(0,s.$K)(t)&&((0,s.QM)(t.name)||(0,s.QM)(t.description))&&(this.uj=Object.assign(Object.assign({},this.uj),t))}getQuality(){return this.Wf.getQuality()}setQuality(t){this.Wf.setQuality(t)}setAutoQuality(){this.Wf.setAutoQuality()}getAvailableQualities(){return this.Wf.getAvailableQualities()}destroy(){super.destroy(),this.mj.destroy(),this.Wf&&(this.Wf.destroy(),this.unsubscribeAll(this.Wf)),(0,it.i)(this.WN),(0,it.i)(this.Ay)}setPreRollBreak(t){var i;this.Ab.setPreRollBreak(t),null===(i=this.mj)||void 0===i||i.setPreRollBreak(this.Ab.preRollBreak),this.Wf.hasPreroll=(0,s.r)(this.Ab.preRollBreak)}setPostRollBreak(t){var i;this.Ab.setPostRollBreak(t),null===(i=this.mj)||void 0===i||i.setPostRollBreak(this.Ab.postRollBreak),this.Wf.hasPostroll=(0,s.r)(this.Ab.postRollBreak)}lj(t){const{imageMaxHeight:i,ratioHeight:e,ratioWidth:n}=$t,r=i/e*n;return{id:t.id,title:t.title,description:t.description,duration:(0,s.hj)(t.duration)?t.duration:this.Wf.duration,keywords:t.keywords,url:t.clickUrl?this.app.services.MacrosService.setupMacros(t.clickUrl):"",customFields:t.customFields,thumbnail:t.getThumbnailUrl(r,i),publishDate:t.publishDate,sourceItemId:t.sourceItemId,languageId:t.languageId,altText:t.altText,disableAdvertising:t.disableAdvertising,cuePoints:t.cuePoints,subtitles:t.subtitles,endDate:t.endDate,contentStudio:t.contentStudio}}$y(){if(this.ny)return;this.hy||this.Hy();const t=Kt[v.ProtoAdSlotsEnum[this.uy]];this.ny=!0,this.oy=!1;const i={adBreakPosition:t};this.uy===v.ProtoAdSlotsEnum.PostRoll&&(this.ly=!0),this.app.services.EventsStorageService.emitAdBreakStart(i)}Uy(){this.ny&&(this.ny=!1,this.app.services.EventsStorageService.emitAdBreakComplete(),this.ly&&(this.ly=!1,this.Gy()))}zy(){this.oy||(this.ny&&this.Uy(),this.hy||this.Hy(),this.oy=!0,this.app.services.EventsStorageService.emitPlay())}Wy(){this.oy&&(this.oy=!1,this.app.services.EventsStorageService.emitPause())}Hy(){this.hy||(this.hy=!0,this.Wf.getCurrentVideoData((({title:t,id:i,sourceItemId:e,keywords:s,duration:n,customFields:r})=>{const o=this.Wf.streamFormat,h=e||i;this.app.services.EventsStorageService.emitSessionStart({name:t,keywords:s,mediaId:h,length:n,streamFormat:o,customFieldList:r,feed:"Video"})})))}Gy(){this.hy&&(this.hy=!1,this.oy=!1,this.ny&&this.Uy(),this.app.services.EventsStorageService.emitSessionEnd())}Xy(){this.hy&&(this.app.services.EventsStorageService.emitContentComplete(),this.Ab.postRollBreak||this.Gy())}wb(){const t=this.uy===v.ProtoAdSlotsEnum.PostRoll?this.getUpNextVideoDetails():this.getVideoDetails();t?(this.adHandler.setContinueReadingCard({imageSrc:t.thumbnail,title:t.title}),this.adHandler.setAdMarkerTitle(t.title)):(this.adHandler.hideContinueReadingCard(),this.adHandler.hideAdMarkerTitle()),super.wb(),this.Wf.blurVideoTag(),this.Wf.hide()}av(t,i=!1){super.av(t,i),this.gj&&(this.gj.setSoundVolume(this.Wf.volume),this.gj.setViewability(t),this.gj.setIsAppBackgrounded(i))}_p(){super._p(),this.Wf&&this.Wf.resize(this.breakPointsHandler.currentBreakpointClass)}handleClose(){this.floatingModule&&this.floatingModule.isInFloating?(this.floatingModule.destroy(!0),0!==this.Wf.volume&&this.setVolume(0)):this.KN.isFullscreen?this.KN.exitFullScreen():this.triggerDestroy()}generateHTML(){super.generateHTML(),this.setPlayerMinDimension(),this.cj=this.app.services.GlobalDomUtilsService.createElementByString(`<img class="${P.sN.ImagePlaceholder}">`),this.$playerWrapper.appendChild(this.cj)}setPlayerMinDimension(){this._y=this.Ab.enableNewUI?80:142}dp(t){super.dp(t),this.Wf.getCurrentVideoData((t=>{var i,e;t.disableAdvertising&&((null===(i=this.adHandler)||void 0===i?void 0:i.linearInImpression)||(null===(e=this.adHandler)||void 0===e?void 0:e.nonLinearInImpression))&&(0,p.n)({level:p.D.WARN,message:"BaseVideoExperience_adImpression_onDisableAdvertising"})}))}vj(t){this.adHandler&&this.adHandler.setMediaRestrictions(t)}ej(){this.subscribe(Jt.C[Jt.C.Volume],this.Wf,(({payload:{volume:t}})=>{this.adHandler?this.adHandler.setLinearVolume(t):this.gp(t)})),this.subscribe(jt.wB.Timeupdate,this.Wf,(({payload:{currentTime:t}})=>{this.hb.contentTimeUpdate(t)})),this.subscribe(jt.T$.NewVideo,this.Wf,(()=>{this.mediator.publish(this,ma.NewVideo),this.subscribe(va.StateChanged,this.Wf,this.QN),this.Wf.getCurrentVideoData((t=>{var i;this.hb.onNewMediaVideo(t.cuePoints,t.disableAdvertising);const e={mediaId:t.id,mediaKeywords:t.keywords,mediaLanguage:t.languageId,mediaInsights:t.insights};let n;this.vj(e),this.Dc.currentMediaMetadata={mediaId:t.id,clickUrl:t.clickUrl,insights:(null===(i=t.insights)||void 0===i?void 0:i.insights)||[],sentimentAnalysis:t.sentimentAnalysis,contentRevisionId:t.contentVersionId,mediaRevision:t.revisionNumber,isExternalMedia:t.isExternalSource},n=(0,s.QM)(this.Ab.playlistThumbnail)?this.Ab.playlistThumbnail:t.getThumbnailUrl(this.$playerContainer.clientWidth,this.$playerContainer.clientHeight),this.adHandler&&this.adHandler.setAdLoadingBackgroundUrl(n),this.yj(n,t.altText),this.mediator.publish(this,va.MediaMetaUpdate,{payload:{title:t.title,description:t.description}})}))})),this.subscribe(va.FirstFramePlayed,this.Wf,(()=>{this.Td.mediaQuartile.next({quartile:i.yU.Start}),this.eI(),this.Hy()})),this.subscribe(va.StateChanged,this.Wf,(({payload:t})=>{var i,e,s,n;switch(this.Dc.playerState=t,this.mj.changeState(t),this.bj(t),t){case jt.Ez.PlayingState:this.mediator.publish(this,M.q0.Play,{payload:this.getVideoDetails()}),this.zy(),(0,u.pv)(this.$experienceContainer,P.s6.ClickToPlayThumbnail)&&((0,u.IV)(this.$experienceContainer,P.s6.ClickToPlayThumbnail),null===(e=null===(i=this.aj)||void 0===i?void 0:i.parentElement)||void 0===e||e.removeChild(this.aj)),null===(s=this.floatingStateMachine)||void 0===s||s.setPlayerPlay(!0);break;case jt.Ez.PausedState:this.mediator.publish(this,M.q0.Pause,{payload:this.getVideoDetails()}),this.Vc.sessionPlaybackChanged.next({isPlaying:!1}),this.Wy(),null===(n=this.floatingStateMachine)||void 0===n||n.setPlayerPause(!0);break;case jt.Ez.StoppedState:this.Vc.sessionPlaybackChanged.next({isPlaying:!1});break;case jt.Ez.PrerollState:case jt.Ez.PostrollState:this.Vc.sessionPlaybackChanged.next({isPlaying:!0}),this.$y();break;case jt.Ez.HiddenState:this.Vc.sessionPlaybackChanged.next({isPlaying:!0}),this.Wy(),this.$y();break;default:this.Vc.sessionPlaybackChanged.next({isPlaying:!0})}})),this.floatingModule&&this.subscribe(w.Uh.UserInteraction,this.Wf,this.Ly),this.adHandler&&this.subscribe(w.Uh.UserInteraction,this.Wf,(({payload:{playback:t}})=>{!1===t&&(this.adHandler.pause(),this.hb.onContentStop()),this.adHandler.userInteraction(t)})),this.subscribe(w.Uh.UserInteraction,this.Wf,(({payload:{clickedNext:t,clickedPrev:i}})=>{(t||i)&&this.Gy()})),this.subscribe(va.ContentQuartiles,this.Wf,(({payload:t})=>{let i;switch(this.Td.mediaQuartile.next({quartile:A.EN.fromProtoGetQuartile(t)}),t){case v.ProtoQuartilesEnum.First:i=ma.VideoCompleted25;break;case v.ProtoQuartilesEnum.Second:i=ma.VideoCompleted50;break;case v.ProtoQuartilesEnum.Third:i=ma.VideoCompleted75;break;case v.ProtoQuartilesEnum.Fourth:i=ma.VideoCompleted100}i&&this.mediator.publish(this,i,{payload:this.getVideoDetails()})})),this.subscribe(va.ContentQuartiles,this.Wf,(({payload:t})=>{t===v.ProtoQuartilesEnum.Fourth&&this.Xy()})),this.subscribe(Jt.C[Jt.C.OverlayClick],this.Wf,(()=>{this.mediator.publish(this,ma.PlayerClicked,{payload:this.getVideoDetails()}),this.Td.mediaClick.next({type:Yt.$.PauseClick})})),this.subscribe(jt.XQ.Change,this.Wf,(t=>this.mediator.publish(this,M.q0.QualityChanged,t))),this.subscribe(jt.T$.PlayError,this.Wf,(t=>{this.mediator.publish(this,M.q0.PlayError,t),this.app.services.EventsStorageService.emitPlayError()})),this.subscribe(Jt.C[Jt.C.CaptionOn],this.Wf,(()=>this.mediator.publish(this,ma.SubtitlesVisibilityChanged,{payload:!0}))),this.subscribe(Jt.C[Jt.C.CaptionOff],this.Wf,(()=>this.mediator.publish(this,ma.SubtitlesVisibilityChanged,{payload:!1}))),this.adHandler&&this.WN.push(this.adHandler.onLinearUiComponentEvent.subscribe((t=>{if(t.type===Jt.C.Volume){const{volume:i}=t.payload;this.gp(i),this.Wf.volume=i}})),this.adHandler.onLinearNoFill.subscribe((()=>{var t;null===(t=this.hb)||void 0===t||t.onLinearNoFill()}))),this.subscribe(jt.T$.NewVideo,this.Wf,(()=>{this.zN?(this.zN=!1,this.Ab.adPlaybackMode===v.ProtoAdPlaybackMode.Autoplay&&this.Ab.playbackMode!==v.ProtoPlayerPlaybackModeEnum.ClickToPlay&&0===this.Ab.preRollBreak&&this.ib(v.ProtoAdSlotsEnum.MidRoll)):this.ab()})),this.Ab.isCloseButton&&this.subscribe(Jt.C[Jt.C.Close],this.Wf,(()=>{this.mediator.publish(this,ya.CloseButtonClicked),this.handleClose()})),this.subscribe(w.Uh.GeneralUserInteraction,this.Wf,(({payload:{type:t}})=>{this.Td.mediaClick.next({type:t})}))}tj(){this.adHandler&&(this.adHandler.start(this.Wf.width,this.Wf.height,this.Ab.soundMode===Gh.ProtoPlayerSoundMode.On?1:0,!1,!0),this.hb.forceRecheck())}bj(t){this.JN(t)()}sb(t){!this.HN&&this.adHandler&&this.adHandler.adStateChange(t,this.ob.getMaxAdSlotDuration())}nb(t){const{duration:i}=this.Wf;this.hb.onAdStateChange(t,{maxAdPodDuration:this.ob.getMaxAdPodDuration(),maxAdSlotDuration:this.ob.getMaxAdSlotDuration()},i)}nj(){this.KN=new Gt(this.app.services.GlobalDomUtilsService,this.$playerContainer,this.app.config.os.os),this.Ij()}Ij(){this.dj(),this.subscribe(Jt.C[Jt.C.Expand],this.Wf,this.YN),this.subscribe(Jt.C[Jt.C.Collapse],this.Wf,(()=>this.KN.exitFullScreen()))}yj(t,i){this.cj.style.display="none",this.cj.onload=()=>{this.cj.style.display=null},(0,s.QM)(t)&&this.cj.setAttribute("src",t),this.cj.setAttribute("alt",i||""),this.cj.setAttribute("id",`cnx-thumbnail-id-${this.app.config.sessionId}`)}ij(t,i){const{preRollBreak:e,postRollBreak:s}=this.Ab;this.mj=new Ut(t,i,e,s)}rj(){this.gj=new Xt(this,this.Ab.playbackMode),this.subscribe(Ht[Ht.Play],this.gj,(t=>{var i,e;this.Wf.play(),(null===(i=this.adHandler)||void 0===i?void 0:i.nonLinearInImpression)&&(null===(e=this.adHandler)||void 0===e||e.play()),t.payload&&(0,s.hj)(t.payload.volume)&&super.setNewVolume(t.payload.volume)})),this.subscribe(Ht[Ht.Pause],this.gj,(t=>{var i,e;this.Wf.pause(),(null===(i=this.adHandler)||void 0===i?void 0:i.nonLinearInImpression)&&(null===(e=this.adHandler)||void 0===e||e.pause()),t.payload&&(0,s.hj)(t.payload.volume)&&super.setNewVolume(t.payload.volume)})),this.subscribe(w.Uh.UserInteraction,this.Wf,(({payload:{playback:t}})=>{(0,s.$K)(t)&&this.gj.setUserPlayback(t)}));const t=this.Wf.canPlay().subscribe((t=>{this.gj.setCanPlay(t)})),i=this.qN.subscribe((t=>{this.gj.setIsFullscreen(t)}));this.WN.push(t,i)}}var wa=r(8843);var Sa,Pa,Aa;!function(t){t[t.StateChanged=0]="StateChanged",t[t.ContentEnd=1]="ContentEnd",t[t.VideoQueued=2]="VideoQueued"}(Sa||(Sa={}));class _a{constructor(t,i,e,s,n,r=!1,o){this.mediator=t,this.wj=i,this.Sj=e,this.Pj=s,this.Aj=n,this._j=r,this.xj=o,this.Tj=!1,this.kj=!1,this.Cj=!1,this.Ej=!1,this.Mj=500,this.Lj=new J.x,this.Bj=0,this.gv(),this.initListeners()}gv(){this.yv=jt.Ez.StoppedState,this.Rj=jt.Ez.StoppedState,this.xj&&(this.Tj=!0)}Oj(){this.Dj=this.Sj.onVideoEvents.subscribe((t=>{switch(t){case jt.wB.Playing:this.Vj();break;case jt.wB.Error:this.Fj();break;case jt.wB.Pause:this.Nj()}}))}Vj(){switch(this.yv){case jt.Ez.PlayingState:return;case jt.Ez.PausedState:case jt.Ez.StoppedState:case jt.Ez.BufferingState:this.jj(jt.Ez.PlayingState);break;case jt.Ez.HiddenState:case jt.Ez.PrerollState:this.$j()}}Fj(){switch(this.yv){case jt.Ez.BufferingState:case jt.Ez.PlayingState:this.jj(jt.Ez.PausedState)}}Nj(){switch(this.yv){case jt.Ez.BufferingState:case jt.Ez.PlayingState:this.jj(jt.Ez.PausedState)}}initListeners(){var t,i;this.Lj.pipe((t=400,void 0===i&&(i=wa.z),(0,ut.e)((function(e,s){var n=null,r=null,o=null,h=function(){if(n){n.unsubscribe(),n=null;var t=r;r=null,s.next(t)}};function a(){var e=o+t,r=i.now();if(r<e)return n=this.schedule(void 0,e-r),void s.add(n);h()}e.subscribe((0,pt.x)(s,(function(e){r=e,o=i.now(),n||(n=i.schedule(a,t),s.add(n))}),(function(){h(),s.complete()}),void 0,(function(){r=n=null})))}))),(0,lt.q)(1)).subscribe((t=>{this.Uj(t),this.Bj=0})),this.Oj()}jj(t){this.yv!==t&&(this.Rj=this.yv,this.yv=t,this.mediator.publish(this,Sa[Sa.StateChanged],{payload:this.yv}))}qj(t){return this.yv===t}Hj(){this.jj(jt.Ez.PrerollState),this.Tj=!0}zj(){this.Wj===jt.Ez.PlayingState?this.Qj():this.$j()}Jj(){this.jj(jt.Ez.PostrollState)}Yj(){this.Wj===jt.Ez.PausedState?(this.Cj=!0,this.stop()):(this.Cj=!1,this.mediator.publish(this,Sa[Sa.ContentEnd]))}$j(){this.Sj.pause(),this.jj(jt.Ez.PausedState)}Qj(){this.jj(jt.Ez.BufferingState),this.wj.getCurrentVideoData((()=>{this.qj(jt.Ez.HiddenState)||this.Wj===jt.Ez.PausedState||this.Sj.play()}))}Kj(){this.yv!==jt.Ez.PostrollState&&(this.Tj=!1)}resume(){this.Rj&&this.jj(this.Rj)}play(){this.Wj=jt.Ez.PlayingState,this.qj(jt.Ez.PlayingState)||this.qj(jt.Ez.PrerollState)||this.qj(jt.Ez.PostrollState)||this.qj(jt.Ez.HiddenState)||this.qj(jt.Ez.InCuePoint)||(!this.Pj||this.Tj||this.kj?this.qj(jt.Ez.StoppedState)&&this.Cj?this.Yj():this.Qj():this.Hj())}isInPlayingState(){return this.qj(jt.Ez.PlayingState)}setVideoQueue(t,i){0===this.Lj.observers.length&&this.initListeners(),i?this.Bj--:this.Bj++;const e=this.wj.getAdjustedVideoIndex(t,this.Bj);this.Lj.next(e),this.mediator.publish(this,Sa[Sa.VideoQueued],{payload:e})}onEnterCuePoint(){this.Sj.pause(),this.jj(jt.Ez.InCuePoint)}onExitCuePoint(){this.qj(jt.Ez.HiddenState)||(this.Wj===jt.Ez.PlayingState?this.Qj():this.$j())}Uj(t){if(this.Sj.pause(),this.Kj(),this.jj(jt.Ez.BufferingState),this.Zj&&this.Zj.isPending)try{this.Zj.reject(),this.Zj=null}catch(t){this.Zj=null}const i=this.wj.setVideo(t);this.Zj=new Wt.C,this.Zj.resolve(i),this.Zj.promise.then((t=>{this.Zj=null,this.Sj.setSource(t).then((()=>this.play()))}))}set hasPreroll(t){this.Pj=t,this.Tj=!0}set hasPostroll(t){this.Aj=t}pause(t=!1){this.Wj=jt.Ez.PausedState,this.qj(jt.Ez.PrerollState)||this.qj(jt.Ez.PostrollState)||this.qj(jt.Ez.HiddenState)||this.qj(jt.Ez.InCuePoint)||this.$j()}pauseToggle(){if(this.qj(jt.Ez.PausedState)||this.qj(jt.Ez.PlayingState))return this.qj(jt.Ez.PausedState)&&this.Ej?(this.Ej=!1,void this.play()):this.qj(jt.Ez.PlayingState)?(this.Ej=!0,void this.pause()):void 0}stop(){this.Sj.pause(),this.jj(jt.Ez.StoppedState)}hide(){this.Sj.hide(),this.Sj.pause(),this.jj(jt.Ez.HiddenState)}show(t=!0){this.qj(jt.Ez.HiddenState)&&(this.Sj.show(),this.Rj!==jt.Ez.PostrollState?t&&(this.Wj===jt.Ez.PlayingState?this.Qj():this.$j()):this.Yj())}handleVideoEnd(){this.Aj&&!this.kj?this.Jj():this.Yj()}onEnterBuffering(){this.qj(jt.Ez.PlayingState)&&this.jj(jt.Ez.BufferingState)}onExitBuffering(){this.qj(jt.Ez.BufferingState)&&(this.Wj===jt.Ez.PlayingState?this.Qj():this.$j())}getCurrentState(){return this.yv}replay(){this.Sj.currentTime=0,!this.Pj||this.kj?this.Qj():this.Hj()}exitRollBreak(){this.yv!==jt.Ez.PostrollState?this.zj():this.Yj()}onFullScreenChange(t){this._j&&(this.kj=t,t||setTimeout((()=>{this.Wj===jt.Ez.PlayingState?(this.pause(),this.play()):this.pause()}),this.Mj))}destroy(){this.Dj.unsubscribe()}}!function(t){t.Autoplay="autoplay",t.Autochain="autochain",t.UserInitiated="user initiated"}(Pa||(Pa={}));class xa{constructor(t){this.streamFormat=Pa.Autoplay,this.isMuted=!0,t===v.ProtoPlayerPlaybackModeEnum.ClickToPlay&&(this.streamFormat=Pa.UserInitiated)}get streamFormatValue(){return`${this.streamFormat}${this.isMuted?" muted":""}`}}class Ta{constructor(t){this.t$=[],this.t$=t,this.i$(0)}e$(){this.s$(this.n$).getMetadata()}i$(t){this.n$=t,this.e$()}s$(t){return this.t$[t]}setAvailableQualitiesForSourceMeta(t,i){t.setAvailableQualities(i)}get nextVideoIndex(){return this.n$===this.t$.length-1?0:this.n$+1}get prevVideoIndex(){return 0===this.n$?this.t$.length-1:this.n$-1}get currentVideoIndex(){return this.n$}getCurrentVideoData(t,i){this.s$(this.n$).getMetadata(t,i)}getVideoData(t,i,e=null){this.s$(t).getMetadata(i,e)}getAdjustedVideoIndex(t,i){return 1===i||-1===i?t:i>0?t+i<this.length?t+i:this.length-1:t+i<0?0:t+i}setVideo(t){return new Promise((i=>{this.s$(t).getMetadata((e=>{this.i$(t),i(e)}))}))}get length(){return this.t$.length}isNextVideoCurrentVideo(){return this.currentVideoIndex===this.nextVideoIndex}destroy(){this.t$=[]}}!function(t){t.Play="play",t.Pause="pause",t.Volume="volume",t.Seek="seek",t.SeekingStart="seekstart",t.SeekingStop="seekstop",t.Quality="quality",t.CaptionOn="captionon",t.CaptionOff="captionoff"}(Aa||(Aa={}));var ka=r(4524),Ca=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};const Ea={[v.ProtoVideoQuality.High1080p]:{quality:jt.ZH.Strict,height:1080},[v.ProtoVideoQuality.High720p]:{quality:jt.ZH.Strict,height:720},[v.ProtoVideoQuality.Medium360p]:{quality:jt.ZH.Strict,height:360}};class Ma extends I._{constructor(t,i,e,s,n){super(),this.mediator=t,this.Ab=i,this.vI=e,this.fI=s,this.r$=n,this.o$=!1,this.h$=!0,this.a$=new at.X(!1),this.c$=new at.X(!1),this.subscriptions=[],this.d$(),this.l$(),this.u$=new xa(this.Ab.playbackMode)}set hasPostroll(t){this.p$.hasPostroll=t}set hasPreroll(t){this.p$.hasPreroll=t}start(t){return Ca(this,void 0,void 0,(function*(){yield this.f$(),this.updateFloatingState(!!t),this.rl()}))}get streamFormat(){return this.u$.streamFormatValue}play(t=!1){t&&(this.mediator.publish(this,w.Uh.UserInteraction,{payload:{playback:!0}}),this.u$.streamFormat=Pa.UserInitiated),this.p$.play()}pause(t=!1){t&&this.mediator.publish(this,w.Uh.UserInteraction,{payload:{playback:!1}}),this.p$.pause(t)}setVideo(t,i=!1){this.p$.setVideoQueue(t,i)}show(t=!0){this.p$.show(t)}hide(){this.p$.hide()}blurVideoTag(){this.Sj.blurVideoTag()}get isHidden(){return this.p$.getCurrentState()===jt.Ez.HiddenState}enterFullscreen(){this.lm=!0,this.m$.enterFullscreen(),this.p$.onFullScreenChange(!0)}exitFullscreen(){this.lm=!1,this.m$.exitFullscreen(),this.p$.onFullScreenChange(!1)}resize(t){var i,e,s;null===(e=(i=this.m$).onResize)||void 0===e||e.call(i,t),null===(s=this.g$)||void 0===s||s.onResize(t)}get width(){return this.Sj.width}get height(){return this.Sj.height}get volume(){return this.Sj.volume}set volume(t){var i;this.Sj.volume=t,null===(i=this.m$)||void 0===i||i.updateVolume(t),this.u$.isMuted=t<=0}getCurrentVideoData(t){return this.wj.getCurrentVideoData(t)}getVideoData(t,i,e=null){return this.wj.getVideoData(t,i,e)}getUpNextVideoData(t){return this.wj.getVideoData(this.wj.nextVideoIndex,t)}get isIosFullscreen(){return this.Sj.isIosFullscreen}set isIosFullscreen(t){this.Sj.isIosFullscreen=t}get currentTime(){return this.Sj.currentTime}set currentTime(t){this.p$.pauseToggle(),this.Sj.currentTime=t,setTimeout((()=>this.p$.pauseToggle()),0)}get duration(){return this.Sj.duration}toggleCaptions(){this.Sj.hasSubtitles()&&(this.Sj.toggleCaptions(),this.m$.toggleCaptionButton(!0),this.mediator.publish(this,Jt.C[Jt.C.CaptionOn]))}togglePlay(){return this.Sj.togglePlay()}toggleMute(){this.Sj.toggleMute(),this.m$.updateVolume(this.Sj.volume)}increaseVolume(t){this.Sj.increaseVolume(t),this.m$.updateVolume(this.Sj.volume)}decreaseVolume(t){this.Sj.decreaseVolume(t),this.m$.updateVolume(this.Sj.volume)}showCaptions(t){this.Sj.hasSubtitles()&&(this.Sj.showCaptions(t),this.m$.toggleCaptionButton(!0),this.mediator.publish(this,Jt.C[Jt.C.CaptionOn]))}get areCaptionsEnabled(){return this.Sj.areCaptionsEnabled}getSelectedCaption(){return this.Sj.getSelectedCaption()}updateCaptionsMenuUI(t){this.m$.updateDefaultCaption(t)}getSubtitles(){return this.Sj.getSubtitles()}hideCaptions(){this.Sj.hideCaptions(),this.m$.toggleCaptionButton(!1),this.mediator.publish(this,Jt.C[Jt.C.CaptionOff])}toggleExpandButton(t){this.m$.toggleExpandButton(t)}getQuality(){let t;return this.wj.getCurrentVideoData((i=>{t=i.getClosestSourceQuality(this.Sj.currentQualitySettings.height).videoHeight})),t}setQuality(t){this.wj.getCurrentVideoData((i=>{const e=i.getClosestSourceQuality(t);this.Sj.setQuality({height:e.videoHeight,quality:jt.ZH.Strict})}))}setAutoQuality(){this.Sj.setQuality({height:this.Sj.height,quality:jt.ZH.Auto})}getAvailableQualities(){let t=[];return this.wj.getCurrentVideoData((i=>{t=i.getAvailableQualities().map((t=>t.videoHeight))})),t}stop(){this.p$&&this.p$.stop()}resume(){this.p$&&this.p$.resume()}startContent(){this.p$.exitRollBreak()}destroy(){var t;null===(t=this.m$)||void 0===t||t.destroy(),this.wj.destroy(),this.Sj.destroy(),this.p$.destroy(),(0,it.i)(this.subscriptions)}canPlay(){return this.a$.asObservable()}onReady(){return this.c$.asObservable()}updateFloatingState(t){var i,e;this.m$&&(null===(e=(i=this.m$).updateFloatingState)||void 0===e||e.call(i,t))}v$(){return new Promise(((t,i)=>{try{this.wj.getCurrentVideoData((i=>Ca(this,void 0,void 0,(function*(){yield this.Sj.setSource(i),this.m$.updateCurrentVideo(i),this.y$(i),this.b$(i,this.Sj.currentQualitySettings),t()}))),(()=>i(new Error("getCurrentVideoData fail callback"))))}catch(t){i(t)}}))}I$(){this.subscribe(Sa[Sa.StateChanged],this.p$,(({payload:t})=>{this.m$.changeState(t),this.mediator.publish(this,va.StateChanged,{payload:t})})),this.subscribe(Sa[Sa.ContentEnd],this.p$,(()=>{this.w$()})),this.subscribe(Sa[Sa.VideoQueued],this.p$,(({payload:t})=>{this.mediator.publish(this,va.VideoQueued,{payload:{videoIndex:t}})}))}S$(){this.subscriptions.push(this.m$.onUIEvent.subscribe((t=>{switch(t.type){case Aa.Play:if(this.h$&&this.Ab.playbackMode===v.ProtoPlayerPlaybackModeEnum.ClickToPlay){const t=this.Ab.soundMode===v.ProtoPlayerSoundMode.On?1:0;this.volume=t,this.mediator.publish(this,Jt.C[Jt.C.Volume],{payload:{volume:t}})}this.h$=!1,this.mediator.publish(this,w.Uh.UserInteraction,{payload:{playback:!0}}),this.play();break;case Aa.Volume:const{volume:n}=t.payload;this.Sj.volume=n,this.u$.isMuted=n<=0,this.mediator.publish(this,w.Uh.UserInteraction,{payload:{volume:!0}}),this.mediator.publish(this,Jt.C[Jt.C.Volume],{payload:{volume:n}});break;case Aa.Pause:this.mediator.publish(this,w.Uh.UserInteraction,{payload:{playback:!1}});const r=!0;this.pause(r);break;case Aa.Seek:const{seekedTime:o}=t.payload;this.P$=o;break;case Aa.SeekingStart:this.p$.pauseToggle();break;case Aa.SeekingStop:this.Sj.forceCurrentTime(this.P$),this.p$.pauseToggle();break;case ka.t.OverlayClick:this.wj.getCurrentVideoData((t=>{(0,s.QM)(t.clickUrl)?(this.Ab.disableClickUrl||(this.vI.services.MacrosService.setVideoTime(this.Sj.currentTime),this.vI.services.GlobalDomUtilsService.open(this.vI.services.MacrosService.setupMacros(t.clickUrl),e.bS.Blank)),this.mediator.publish(this,w.Uh.GeneralUserInteraction,{payload:{type:i.$u.UrlClick}})):this.pause(!0),this.mediator.publish(this,Jt.C[Jt.C.OverlayClick])}));break;case ka.t.Expand:this.mediator.publish(this,Jt.C[Jt.C.Expand]);break;case ka.t.Collapse:this.mediator.publish(this,Jt.C[Jt.C.Collapse]);break;case Aa.Quality:const{quality:h}=t.payload;this.Sj.setQuality(h);break;case ka.t.Close:this.A$();break;case Aa.CaptionOn:const{captionUrl:a}=t.payload;this.showCaptions(a);break;case Aa.CaptionOff:this.hideCaptions();break;case ka.t.GeneralUserInteraction:const{payload:c}=t;this.mediator.publish(this,w.Uh.GeneralUserInteraction,{payload:c})}}))),this.subscribe(ka.t.Close,this.g$,(()=>{this.A$()})),this.subscribe(Jt.C[Jt.C.CaptionOn],this.Sj,(()=>{this.m$.toggleCaptionButton(!0)})),this.subscribe(Jt.C[Jt.C.CaptionOff],this.Sj,(()=>{this.m$.toggleCaptionButton(!1)})),this.subscribe(Jt.C[Jt.C.CaptionUpdate],this.Sj,(({payload:t})=>{this.m$.updateActiveCue(t)}))}Kj(t=!0){t&&(this.wj.getCurrentVideoData((t=>{var i,e;if(this._$(t),this.m$.updateCurrentVideo(t),this.y$(t),null===(i=this.g$)||void 0===i||i.updateCurrentVideo(t),this.b$(t,this.Sj.currentQualitySettings),this.Ab.closedCaptionDefault&&t.subtitles){const i=null===(e=t.getDefaultSubtitle())||void 0===e?void 0:e.file;setTimeout((()=>{this.showCaptions(i),this.m$.updateDefaultCaption(i)}),0)}else this.hideCaptions(),this.m$.updateDefaultCaption()})),this.m$.updateActiveCue()),this.mediator.publish(this,jt.T$.NewVideo,{payload:{videoIndex:this.wj.currentVideoIndex}}),this.o$=!1,this.x$()}rl(){this.C$(),this.E$(),this.M$()}L$(){return{logoPosition:this.Ab.logoPosition,logoUrl:this.Ab.logoUrl,isMobile:this.vI.config.isMobile,hasUpNext:this.Ab.upNextMode===Gh.ProtoPlayerUpNextMode.Next,accentColor:this.Ab.accentColor||P.QO.Connatix,iconsColor:this.Ab.iconsColor||P.QO.Icons,tooltipBackgroundColor:this.Ab.tooltipBackgroundColor||P.QO.SecondaryBackground,tooltipTextColor:this.Ab.tooltipTextColor||P.QO.Icons,closeButtonMode:this.Ab.closeButtonMode,floatingCloseButtonMode:this.Ab.floatingSettings.floatingCloseButtonMode,isCloseButton:this.Ab.isCloseButton,uiComponentsVisibility:this.Ab.uiComponentsVisibility,sharingDestinations:this.Ab.sharingDestinations,closedCaptionDefault:this.Ab.closedCaptionDefault,alwaysDisplayControls:this.Ab.alwaysDisplayControls,os:this.vI.config.os.os,sdkVersion:this.vI.config.sdkVersion,isPinned:this.Ab.floatingSettings.isPinnedFloating,enableNewUI:this.Ab.enableNewUI}}l$(){const t={browser:this.vI.config.browser.browserType,os:this.vI.config.os.os,osVersion:this.vI.config.os.osVersion},i=this.Ab.soundMode===v.ProtoPlayerSoundMode.On&&this.Ab.playbackMode!==v.ProtoPlayerPlaybackModeEnum.ClickToPlay?1:0;this.B$=Ea[this.Ab.videoQuality],this.R$(t,i),this.subscribe(jt.XQ.Loaded,this.Sj,(({payload:{qualityList:t,videoMeta:i}})=>{this.wj.setAvailableQualitiesForSourceMeta(i,t),this.m$&&this.m$.updateCurrentVideo(i)})),this.subscribe(jt.T$.Buffering,this.Sj,(()=>{this.p$.onEnterBuffering()})),this.subscribe(jt.T$.Buffered,this.Sj,(()=>{this.p$.onExitBuffering()}))}b$(t,i){const e=t.getAvailableQualities();if((0,S.BZ)(e)){const e=t.getClosestSourceQuality(i.height).isHD;this.m$.updateQuality(i,e)}}_$(t){this.vI.services.MacrosService.setVideoDuration(t.duration),this.vI.services.MacrosService.setVideoTitle(t.title),this.vI.services.MacrosService.setVideoDescription(t.description),this.vI.services.MacrosService.setVideoUrl(t.clickUrl),this.vI.services.MacrosService.setVideoId(t.id)}d$(){this.wj=new Ta(this.Ab.playlist)}f$(){return Ca(this,void 0,void 0,(function*(){const t=this.L$();yield this.O$(t),1===this.wj.length&&this.m$.togglePlaylistControls(!1),this.m$.updateVolume(this.Ab.soundMode===v.ProtoPlayerSoundMode.On?1:0)}))}C$(){this.relay(jt.T$.PlayError,this.Sj,this,this.mediator),this.subscribe(jt.T$.NewVideo,this.Sj,(()=>{this.Kj()}))}E$(){this.subscribe(jt.wB.LoadedData,this.Sj,(t=>{this.m$.updateCurrentTime(this.Sj.currentTime,this.Sj.duration)})),this.subscribe(jt.wB.Timeupdate,this.Sj,(({payload:{isPlaying:t}})=>{this.m$.updateCurrentTime(this.Sj.currentTime,this.Sj.duration),this.vI.services.MacrosService.setVideoTime(this.Sj.currentTime),!this.o$&&t&&(this.o$=!0,this.mediator.publish(this,va.FirstFramePlayed)),this.Sj.currentTime!==this.D$&&this.V$(t),this.D$=this.Sj.currentTime,this.mediator.publish(this,jt.wB.Timeupdate,{payload:{currentTime:this.Sj.currentTime}})})),this.subscribe(jt.wB.Volumechange,this.Sj,(({payload:{isMuted:t}})=>{this.isIosFullscreen&&(this.volume=t?0:1)})),this.subscribe(jt.wB.Ended,this.Sj,(()=>{this.p$.handleVideoEnd()})),this.subscribe(jt.wB.BufferProgress,this.Sj,(({payload:{bufferRanges:t}})=>{const i=t||null;this.m$.updateBufferedState(i)}))}M$(){this.subscribe(jt.XQ.CurrentQuality,this.Sj,(({payload:t})=>{this.wj.getCurrentVideoData((i=>{this.b$(i,t)}))})),this.subscribe(jt.XQ.Change,this.Sj,(({payload:t})=>{this.wj.getCurrentVideoData((i=>{const e=i.getAvailableQualities();if((0,S.BZ)(e)){const e=i.getClosestSourceQuality(t);this.B$={quality:jt.ZH.Strict,height:e.videoHeight},this.mediator.publish(this,jt.XQ.Change,{payload:e.videoHeight})}}))}))}y$(t){const i=t.getThumbnailUrl(this.fI.clientWidth,this.fI.clientHeight);this.mediator.publish(this,jt.d0.NewThumbnail,{payload:{thumbnailUrl:i}})}A$(){this.mediator.publish(this,w.Uh.UserInteraction,{payload:{playback:!1,isFullscreenClose:this.lm}}),this.mediator.publish(this,Jt.C[Jt.C.Close])}}class La extends _a{play(){if(this.F$)return this.Wj=jt.Ez.PlayingState,this.F$=!1,void this.Hj();super.play()}pause(t=!1){this.qj(jt.Ez.LiveStreamEnded)||this.qj(jt.Ez.LiveStreamStarting)||this.qj(jt.Ez.LiveStreamStopped)||(t&&(this.F$=!0),super.pause())}endOfStream(){this.pause(),this.handleVideoEnd()}enterLiveNotSupported(){this.jj(jt.Ez.LiveStreamNotSupported)}enterLiveStreamStopped(){this.jj(jt.Ez.LiveStreamStopped)}gv(){this.yv=jt.Ez.LiveStreamStarting,this.Rj=jt.Ez.LiveStreamStarting}Yj(){this.jj(jt.Ez.LiveStreamEnded)}$j(){this.Sj.pause(),this.jj(jt.Ez.LiveStreamStopped)}}class Ba{constructor(t){this.N$=[{id:jt.L5.H264,extension:"mp4",type:"video/mp4"},{id:jt.L5.Hevc,extension:"mp4",type:"video/mp4"}],this.j$=this.N$.find((i=>i.id===t))}get type(){const t=this.j$.codecs?`codecs=${this.j$.codecs}`:"";return`${this.j$.type}; ${t}`}get id(){return this.j$.id}}class Ra{constructor(t,i){this.Jm=t,this.Im=i,this.$$={quality:jt.ZH.Auto,height:360},this.resizeObserverBinded=!1,this.U$=new J.x,this.q$=new at.X(this.$$),this.H$=30,this.dg=()=>{const t=this.Im.clientHeight;if(this.z$(t)&&this.currentQualitySettings.quality===jt.ZH.Auto){const i={height:t,quality:jt.ZH.Auto};this.setCurrentQualitySettings(i),this.q$.next(i)}}}setCurrentQualitySettings(t){this.$$.quality=t.quality,this.$$.height!==t.height&&(this.$$.height=t.height,this.U$.next())}z$(t){return!this.$$.height||t/this.$$.height*100-100>this.H$}addResizeObserver(){this.resizeObserverBinded=!0,this.Jm.on(this.Im,this.dg)}removeResizeObserver(){this.resizeObserverBinded=!1,this.Jm.off(this.Im,this.dg)}setQuality(t){t.quality===jt.ZH.Auto?this.resizeObserverBinded||(this.setCurrentQualitySettings({height:t.height,quality:t.quality}),this.addResizeObserver(),this.dg()):(this.resizeObserverBinded&&this.removeResizeObserver(),this.setCurrentQualitySettings(t)),this.q$.next(this.$$)}get currentQualitySettings(){return this.$$}get onQualityChange(){return this.U$.asObservable()}get onCurrentQuality(){return this.q$.asObservable()}destroy(){this.removeResizeObserver()}}var Oa=r(1418),Da=r.n(Oa);function Va(t){const i=new(Da());return i.push(t),i.end(),i.manifest}var Fa=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class Na{constructor(t,i){this.ol=t,this.Ox=i,this.X$=new J.x,this.U$=new J.x,this.q$=new J.x,this.onTrackLoaded=this.X$.asObservable(),this.onQualityChange=this.U$.asObservable(),this.onCurrentQuality=this.q$.asObservable(),this.Q$=()=>{this.X$.next()}}J$(t){this.Y$=t}K$(t){this.Ox.innerHTML="",t.forEach((t=>{this.Ox.appendChild(t)}))}Z$(){return this.tU}iU(t){var i;null===(i=this.tU)||void 0===i||i.remove(),this.tU=null,this.eU=t,this.Y$&&this.Y$.subtitles&&t&&(this.Ox.childNodes.forEach((t=>{"track"===t.nodeName.toLowerCase()&&t.remove()})),t.isHLSTrack?this.sU(t.file).then((i=>{this.nU(t,i)})):this.nU(t))}nU(t,i){const e=this.ol.createElement("track");e.src=(0,s.QM)(i)?i:t.file,e.srclang=t.code,e.label=t.title,e.kind="subtitle",e.default=!0,e.addEventListener("load",this.Q$,!1),e.addEventListener("loaded",this.Q$,!1),this.Ox.appendChild(e),this.tU=e}sU(t){return Fa(this,void 0,void 0,(function*(){try{const i=yield Bt.n.fetchXhttpRequest({requestUrl:t,requestType:"GET"});if(!(0,s.QM)(i))return;const e=Va(i);if(!(0,S.BZ)(e.segments)||!(0,a.jv)(e.segments[0].uri))return;return e.segments[0].uri}catch(t){return}}))}}var ja,$a,Ua;!function(t){t[t.MP4=0]="MP4",t[t.HLS=1]="HLS"}(ja||(ja={}));class qa extends Na{constructor(t,i,e,s,n={},r,o){super(t,s),this.Jm=i,this.fI=e,this.B$=r,this.Zp=o,this.WN=[],this.rU=null,this.oU=10.13,this.handlerType=ja.MP4,this.hU=this.aU(n)}start(){try{this.cU=new Ra(this.Jm,this.fI),this._m(),this.setQuality(this.B$)}catch(t){(0,p.n)({message:"Mp4SourceHandler_start",exception:t.message,callStack:t.stack,level:p.D.CRITICAL,sessionId:this.Zp},{extraLogsPercentage:5})}}onQualityChanged(){return this.attachMedia()}setSource(t,i=!1){this.J$(t),this.dU(this.uU(),i)}setQuality(t){this.cU.setQuality(t)}get currentQualitySettings(){return this.cU.currentQualitySettings}attachMedia(){return new Promise((t=>{this.pU(),t()}))}detachMedia(){this.Ox.removeAttribute("src"),this.dU(null)}destroy(){this.cU.destroy(),(0,it.i)(this.WN)}updateSubtitleTrackSource(t){this.iU(t)}getSelectedCaptionTrack(){return this.eU}_m(){const t=this.cU.onCurrentQuality.subscribe((t=>this.q$.next(t))),i=this.cU.onQualityChange.subscribe((()=>this.fU(this.cU.currentQualitySettings.height)));this.WN.push(t,i)}fU(t){this.dU(this.uU()),this.U$.next(t)}mU(t){this.K$(t),this.Ox.load()}uU(){return[...this.gU(),...this.Z$()?[this.Z$()]:[]]}gU(){if(!this.Ox||!this.Y$)return[];const t=[];return this.Y$.getSources(this.cU.currentQualitySettings.height,this.hU).forEach((i=>{const e=this.ol.createElement("source");e.src=i.src,e.type=i.type,t.push(e)})),t}pU(){this.rU&&(this.mU(this.rU),this.rU=null)}dU(t,i=!1){this.rU=t,i&&this.pU()}aU(t){let i;switch(t.os){case zt.M.Ios:i=[jt.L5.Hevc,jt.L5.H264];break;case zt.M.Mac:i=t.osVersion>this.oU&&t.browser===e.lI.Safari?[jt.L5.Hevc,jt.L5.H264]:[jt.L5.H264];break;default:i=[jt.L5.H264]}return i.map((t=>new Ba(t)))}}!function(t){t.UnexpectedError="unexpectedError",t.BufferingError="bufferingError",t.FragBuffered="fragBuffered",t.ManifestLoaded="manifestLoaded",t.LevelSwitching="levelSwitching",t.StreamEnded="streamEnded"}($a||($a={})),function(t){t.Http="http",t.Https="https"}(Ua||(Ua={}));var Ha=r(655),za=r(5720),Wa=r(3699);class Ga extends Na{constructor(t,i,e,s,n,r,o,h,a){super(t,i),this.Bx=e,this.vU=s,this.B$=n,this.cf=r,this.Jv=o,this.Zp=h,this.bU=a,this.IU=new J.x,this.onHlsEvent=this.IU.asObservable(),this.Nx=[],this.wU=jt.ZH.Auto,this.SU=320,this.PU=!1,this.AU=!1,this._U=!1,this.handlerType=ja.HLS,this.xU=new at.X(0),this.TU=!1,this.kU=!1,this.CU=!1,this.qx=()=>{this.Ux.off(this.Bx.Events.MEDIA_ATTACHED,this.qx);const t=this.EU(this.MU);this.Ux.loadSource(t),this.Ux.once(this.Bx.Events.MANIFEST_PARSED,this.Hx)},this.Hx=()=>{this.Ux.off(this.Bx.Events.MANIFEST_PARSED,this.Hx),this.Ux.on(this.Bx.Events.LEVEL_SWITCHING,this.LU),this.Ux.on(this.Bx.Events.LEVEL_SWITCHED,this.BU),this.Ux.on(this.Bx.Events.FRAG_BUFFERED,this.RU),this.Ux.on(this.Bx.Events.FRAG_LOADING,this.OU),this.Ux.on(this.Bx.Events.FRAG_LOADED,this.DU),this.Ux.on(this.Bx.Events.BUFFER_APPENDING,this.VU),this.Ux.on(this.Bx.Events.BUFFER_APPENDED,this.FU),this.Ux.on(this.Bx.Events.BUFFER_EOS,this.NU),this.MU=null,this.zx(),this.jU(),this.$U(),this.UU.resolve()},this.qU=()=>{this.MU=null,this.Ox.removeEventListener(jt.wB.LoadedMetadata,this.qU),this.HU.resolve()},this.jU=()=>{const t=function(t){const i=[];return t.forEach((t=>{i.some((i=>i.height===t.height))||i.push(t)})),i}(this.Nx),i=t.map((t=>({videoHeight:t.height,isHD:t.height>=jt.gQ,label:t.level.toString()})));this.IU.next({type:$a.ManifestLoaded,payload:{qualityList:i}})},this.RU=()=>{this.IU.next({type:$a.FragBuffered})},this.OU=()=>{this.PU=!0},this.DU=()=>{this.PU=!1},this.VU=()=>{this.AU=!0},this.FU=()=>{this.AU=!1},this.NU=()=>{this.IU.next({type:$a.StreamEnded})},this.jx=(t,i)=>{if(i.details===this.Bx.ErrorDetails.BUFFER_STALLED_ERROR&&(this.PU||this.AU?this.IU.next({type:$a.BufferingError}):(this._U||(this.shouldRecoverMediaError()&&this.Ux.recoverMediaError(),this.Ox.play().then((()=>{this._U=!1})).catch((()=>{this._U=!1}))),this._U=!0)),i.fatal)switch(i.type){case this.Bx.ErrorTypes.NETWORK_ERROR:if(i.details===this.Bx.ErrorDetails.MANIFEST_PARSING_ERROR)return void this.zU("hls_network_error_manifest_parsing_error_FATAL");if(i.details===this.Bx.ErrorDetails.MANIFEST_LOAD_ERROR)return void this.IU.next({type:$a.UnexpectedError});if(i.details===this.Bx.ErrorDetails.LEVEL_LOAD_ERROR&&this.xU.next(this.xU.value+1),this.TU)return this.NU(),void(this.TU=!1);this.Ux.startLoad();break;case this.Bx.ErrorTypes.MEDIA_ERROR:this.Ux.recoverMediaError();break;default:this.zU("hls_unexpected_error_FATAL",`type_${i.type}_details_${i.details}`)}else i.type===this.Bx.ErrorTypes.MEDIA_ERROR&&i.details===this.Bx.ErrorDetails.BUFFER_APPENDING_ERROR&&this.zU("hls_media_error_buffer_appending_error"),i.type===this.Bx.ErrorTypes.NETWORK_ERROR&&i.details===this.Bx.ErrorDetails.MANIFEST_PARSING_ERROR&&this.zU("hls_network_error_manifest_parsing_error")},this.WU=()=>{this.zU("hls_video_tag_error",`code_${this.Ox.error.code}_message_${this.Ox.error.message}`)},this.BU=(t,i)=>{this.SU=this.Nx.find((t=>t.level===i.level)).height,this.U$.next(this.currentQualitySettings.height),this.q$.next(this.currentQualitySettings)},this.LU=()=>{this.IU.next({type:$a.LevelSwitching})},Dn()&&(this.Ux=this.GU()),this.SU=this.B$.height,this.wU=this.B$.quality}start(){}get liveSyncPosition(){if(this.Ux)return this.Ux.liveSyncPosition}setSource(t,i=!1){this.kU=this.cf&&!t.isExternalSource,this.Ux&&this.kU&&(this.CU||(this.CU=!0,this.Ux.autoLevelCapping=1)),this.XU=t.id,this.J$(t),this.MU=t,i&&this.attachMedia()}attachMedia(){return this.UU?this.UU.promise:this.HU?this.HU.promise:(!this.Ux&&Dn()&&(this.Ux=this.GU()),new Promise((t=>{if(this.Ux?this.Ux.on(this.Bx.Events.ERROR,this.jx):this.Ox.addEventListener(jt.wB.Error,this.WU),this.initLiveStreamRetry(),this.MU){const i=this.Z$()?[this.Z$()]:[];this.K$(i),this.Ux?this.QU().then((()=>{t()})):this.JU().then((()=>{t()}))}else t()})))}detachMedia(){this.Nx=[],this.UU=void 0,this.HU=void 0,this.Ux?(this.Ux.detachMedia(),this.destroy()):(this.Ox.removeAttribute("src"),this.Ox.removeEventListener(jt.wB.LoadedMetadata,this.qU),this.Ox.removeEventListener(jt.wB.Error,this.WU))}setQuality(t){this.wU=t.quality,this.SU=t.height,this.Ux&&this.$U(),this.U$.next(this.currentQualitySettings.height),this.q$.next(this.currentQualitySettings)}get currentQualitySettings(){return{quality:this.wU,height:this.SU}}onQualityChanged(){return new Promise((()=>{}))}shouldRecoverMediaError(){return!this.bU}destroy(){this.Ux?(this.YU(),this.Ux.destroy(),this.Ux=null):(this.Ox.removeEventListener(jt.wB.LoadedMetadata,this.qU),this.Ox.removeEventListener(jt.wB.Error,this.WU))}updateSubtitleTrackSource(t){this.iU(t)}getSelectedCaptionTrack(){return this.eU}QU(){return this.UU=new Wt.C,this.Ux.attachMedia(this.Ox),this.Ux.once(this.Bx.Events.MEDIA_ATTACHED,this.qx),this.UU.promise}JU(){return this.HU=new Wt.C,this.Ox.src=this.EU(this.MU),this.Ox.addEventListener(jt.wB.LoadedMetadata,this.qU),this.HU.promise}YU(){this.Ux.off(this.Bx.Events.MEDIA_ATTACHED,this.qx),this.Ux.off(this.Bx.Events.MANIFEST_PARSED,this.Hx),this.Ux.off(this.Bx.Events.ERROR,this.jx),this.Ux.off(this.Bx.Events.LEVEL_SWITCHING,this.LU),this.Ux.off(this.Bx.Events.LEVEL_SWITCHED,this.BU),this.Ux.off(this.Bx.Events.FRAG_BUFFERED,this.RU),this.Ux.off(this.Bx.Events.FRAG_LOADING,this.OU),this.Ux.off(this.Bx.Events.FRAG_LOADED,this.DU),this.Ux.off(this.Bx.Events.BUFFER_APPENDING,this.VU),this.Ux.off(this.Bx.Events.BUFFER_APPENDED,this.FU),this.Ux.off(this.Bx.Events.BUFFER_EOS,this.NU)}zx(){this.Ux.levels.forEach(((t,i)=>{this.kU&&i>1||this.Nx.push({level:i,height:t.height})}))}zU(t,i){(0,p.n)({message:t,exception:this.XU,level:p.D.WARN,callStack:i,sessionId:this.Zp},{extraLogsPercentage:5}),this.IU.next({type:$a.UnexpectedError})}$U(){if(this.wU===jt.ZH.Auto)this.Ux.currentLevel=-1;else try{const e=(t=this.Nx,i=this.SU,t.reduce(((t,e)=>{if(!t)return e;const s=Math.abs(t.height-i);return Math.abs(e.height-i)<s?e:t}),void 0));this.Ux.currentLevel=e.level}catch(t){(0,p.n)({message:"HlsSourceHandler_set_quality",exception:t.message,callStack:t.stack,level:p.D.CRITICAL,sessionId:this.Zp},{extraLogsPercentage:5})}var t,i}EU(t){try{const i=t.getHlsSource(),e=(0,h.bx)(i);return e&&e.protocol?this.Jv.appendParamsToUrl(i):this.Jv.appendParamsToUrl(`${this.vU}:${i}`)}catch(t){(0,p.n)({exception:t.message,message:"HlsSourceHandler_undefined_sourceMeta",level:p.D.CRITICAL,callStack:t.stack,sessionId:this.Zp},{throttle:5,shouldSendMaxLog:!1,extraLogsPercentage:5})}}GU(){return new this.Bx(Object.assign({},Bn))}initLiveStreamRetry(){var t;null===(t=this.KU)||void 0===t||t.unsubscribe(),this.KU=this.xU.pipe(function(t){for(var i,e,s=[],n=1;n<arguments.length;n++)s[n-1]=arguments[n];var r=null!==(i=Gi(s))&&void 0!==i?i:wa.z,o=null!==(e=s[0])&&void 0!==e?e:null,h=s[1]||1/0;return(0,ut.e)((function(i,e){var s=[],n=!1,a=function(t){var i=t.buffer;t.subs.unsubscribe(),(0,Wa.P)(s,t),e.next(i),n&&c()},c=function(){if(s){var i=new za.w0;e.add(i);var n={buffer:[],subs:i};s.push(n),Qi(i,r,(function(){return a(n)}),t)}};null!==o&&o>=0?Qi(e,r,c,o,!0):n=!0,c();var d=(0,pt.x)(e,(function(t){var i,e,n=s.slice();try{for(var r=(0,Ha.XA)(n),o=r.next();!o.done;o=r.next()){var c=o.value,d=c.buffer;d.push(t),h<=d.length&&a(c)}}catch(t){i={error:t}}finally{try{o&&!o.done&&(e=r.return)&&e.call(r)}finally{if(i)throw i.error}}}),(function(){for(;null==s?void 0:s.length;)e.next(s.shift().buffer);null==d||d.unsubscribe(),e.complete(),e.unsubscribe()}),void 0,(function(){return s=null}));i.subscribe(d)}))}(5e3),(0,dt.h)((t=>t.length<3))).subscribe((()=>{this.TU=!0,this.xU.next(0)}))}}var Xa,Qa;!function(t){t.Disabled="disabled",t.Hidden="hidden",t.Showing="showing"}(Xa||(Xa={})),function(t){t.Video="VIDEO",t.Audio="AUDIO"}(Qa||(Qa={}));class Ja{constructor(t,i,e){this.ZU=t,this.bw=e,this.CV=!1,this.tq=!1,this.iq=Xa.Hidden,this.eq=!1,this.sq=new J.x,this.nq=!1,this.rq=new Map([[jt.wB.Play,()=>this.oq()],[jt.wB.Playing,()=>this.hq()],[jt.wB.Timeupdate,t=>this.aq(t)],[jt.wB.Ended,t=>this.cq(t)],[jt.wB.Seeked,t=>this.dq(t)],[jt.wB.Error,()=>this.lq()],[jt.wB.LoadedMetadata,()=>this.pq()],[jt.wB.Pause,()=>this.fq()],[jt.wB.Volumechange,()=>this.mq()],[jt.wB.BufferProgress,()=>this.gq()]]),this.vq=t=>{let i=!1;(t.type===jt.wB.Timeupdate&&this.yq()||t.type===jt.wB.Seeked)&&(i=this.bq(jt.wB.Timeupdate));const e=this.rq.get(t.type);(0,s.$K)(e)?e(i):this.sq.next({type:t.type})},this.nT=Object.values(jt.wB),this.volume=i,this._m()}get currentTime(){return this.ZU.currentTime}set currentTime(t){this.tq?this.ZU.currentTime=t:this.Iq=t}get duration(){return this.ZU.duration}get isPlaying(){return this.CV}get videoEvents(){return this.sq.asObservable()}get volume(){return this.Fm}set volume(t){const i=t?t<=1?t:t/100:t;i!==this.Fm&&(this.Fm=i,void 0!==this.Fm&&(this.ZU.volume=this.Fm,(0,u.Q1)(this.ZU,this.Fm)))}setUnfreeze(){this.nq=!0}play(){this.eq=!0,this.wq&&clearTimeout(this.wq),this.wq=setTimeout((()=>{this.sq.next({type:jt.wB.Error,payload:{errorMessage:"play_timeout"}})}),25e3),this.ZU.play().catch((t=>{(0,p.n)({message:"ContentPlayer_play_promise_catch",exception:t,level:p.D.INFO,sessionId:this.bw.sessionId},{shouldSendMaxLog:!1,pacing:1})}))}pause(){this.wq&&clearTimeout(this.wq),this.ZU.pause(),this.CV=!1,this.eq=!1}destroy(){this.nT.forEach((t=>{this.ZU.removeEventListener(t,this.vq)}))}setTrackModes(t){this.iq=t,this.Sq()}setMetaLoaded(t){this.tq=t}setCrossOriginAttribute(){this.ZU.getAttribute("crossorigin")||this.ZU.setAttribute("crossorigin","anonymous")}setPoster(t){if(this.ZU.nodeName!==Qa.Video)return;const i=t.getThumbnailUrl(this.ZU.clientWidth,this.ZU.clientHeight);(0,s.QM)(i)&&(this.ZU.poster=i)}getCurrentTrack(){return this.ZU.textTracks&&0!==this.ZU.textTracks.length?this.ZU.textTracks[0]:null}_m(){this.nT.forEach((t=>{this.ZU.addEventListener(t,this.vq)}))}oq(){this.eq||!this.bw.isInApp||this.bw.os!==zt.M.Android?this.CV=!0:this.pause()}hq(){this.wq&&clearTimeout(this.wq),this.bw.os===zt.M.Ios&&this.nq&&((0,u.UR)(this.ZU),this.nq=!1),this.Sq(),this.sq.next({type:jt.wB.Playing})}mq(){this.sq.next({type:jt.wB.Volumechange,payload:{isMuted:this.ZU.muted}})}aq(t){this.sq.next({type:jt.wB.Timeupdate,payload:{isPlaying:this.CV,isCorruptedCurrentTime:t}})}gq(){this.sq.next({type:jt.wB.BufferProgress,payload:{bufferRanges:this.ZU.buffered}})}fq(){this.wq&&clearTimeout(this.wq),this.sq.next({type:jt.wB.Pause})}lq(){this.wq&&clearTimeout(this.wq),this.sq.next({type:jt.wB.Error,payload:{errorMessage:this.ZU.error?this.ZU.error.message:""}})}pq(){this.tq=!0,(0,s.hj)(this.Iq)&&(this.currentTime=this.Iq,this.Iq=null),this.sq.next({type:jt.wB.LoadedMetadata})}dq(t){this.sq.next({type:jt.wB.Seeked,payload:{isCorruptedCurrentTime:t}})}cq(t){this.sq.next({type:jt.wB.Ended,payload:{isCorruptedCurrentTime:t}})}bq(t){return this.bw.os===zt.M.Ios&&this.ZU.currentTime>this.ZU.duration&&((0,u.UR)(this.ZU),(0,p.n)({message:"ContentPlayer__CorruptedCurrentTime",callStack:`Event type: ${t}`,level:p.D.WARN},{throttle:10}),!0)}yq(){return this.ZU.currentTime-this.ZU.duration>.1}Sq(){this.ZU.textTracks&&0!==this.ZU.textTracks.length&&Object.keys(this.ZU.textTracks).forEach((t=>{this.iq===this.ZU.textTracks[t].mode&&(this.ZU.textTracks[t].mode=this.iq===Xa.Hidden?Xa.Disabled:Xa.Hidden),this.ZU.textTracks[t].mode=this.iq}))}}const Ya={height:0,quality:jt.ZH.Auto};var Ka,Za=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class tc extends I._{constructor(t,i,e,n,r,o,h={},a,c,d){super(),this.mediator=t,this.vI=i,this.ol=e,this.fI=n,this.Jm=r,this.Pq=o,this.j$=h,this.Aq=a,this.xj=c,this.B$=d,this._q=!0,this.HN=!1,this.xq=!1,this.lT=new J.x,this.Yv=.01,this.WN=[],this.Tq=t=>{var i;const e={[$a.LevelSwitching]:jt.T$.LevelSwitching,[$a.StreamEnded]:jt.T$.EndOfStream,[$a.FragBuffered]:jt.T$.Buffered,[$a.BufferingError]:jt.T$.Buffering}[t.type];if((0,s.QM)(e))this.mediator.publish(this,e);else{if(t.type===$a.UnexpectedError)return this.xq=!0,void this.kq();if(t.type===$a.ManifestLoaded){const e=null===(i=t.payload)||void 0===i?void 0:i.qualityList;this.mediator.publish(this,jt.XQ.Loaded,{payload:{qualityList:e,videoMeta:this.Cq}}),this.Eq.setMetaLoaded(!0)}}},this.Mq=()=>{let t;this.currentTrack.activeCues&&this.currentTrack.activeCues.length>0&&(t=this.currentTrack.activeCues[0]),this.playing&&this.mediator.publish(this,Jt.C[Jt.C.CaptionUpdate],{payload:t})},this.Q$=()=>{this.currentTrack&&(this.currentTrack.mode=this.Lq?Xa.Hidden:Xa.Disabled,this.currentTrack.oncuechange=this.Mq)},this.Bq(),this.Oq.appendChild(this.Ox),this.fI.appendChild(this.Oq),this.B$=this.B$||Ya,this.Dq=new qa(e,this.Jm,this.fI,this.Ox,this.j$,this.B$,this.vI.config.sessionId),this.vI.config.os.os===zt.M.Ios&&this.vI.services.ViewabilityService.on(this.Ox,((t,i)=>{!i&&t||this.Eq.setUnfreeze()}),{threshold:this.Yv})}initHlsSourceHandler(t){const i=this.ol.isHttpsProtocolUsed()?Ua.Https:Ua.Http,n=(0,s.QM)(this.vI.config.bundleID);this.ST=new Ga(this.ol,this.Ox,t,i,this.B$,n,this.vI.services.UrlSuffixerService,this.vI.config.sessionId,this.vI.config.browser.browserType===e.lI.Safari)}blurVideoTag(){this.Ox.blur()}Vq(){return Za(this,void 0,void 0,(function*(){if(this.ST)return!0;const t=yield On(this.ol.global);return Dn()||(i=this.Ox,(0,s.QM)(i.canPlayType("application/vnd.apple.mpegurl")))?(this.initHlsSourceHandler(t),this.Fq(),this.jq(),!0):(this._q=!1,(0,p.n)({message:"Hls_not_supported",level:p.D.INFO,sessionId:this.vI.config.sessionId},{extraLogsPercentage:5}),!1);var i}))}get onVideoEvents(){return this.lT.asObservable()}start(){try{this.Eq=new Ja(this.Ox,this.Pq,{isInApp:this.vI.config.isInApp,os:this.vI.config.os.os,sessionId:this.vI.config.sessionId}),this.Fm=this.Eq.volume,this.$q(),this.Fq(),this.Uq()}catch(t){(0,p.n)({message:"VideoHandler_start",exception:t.message,callStack:t.stack,level:p.D.CRITICAL,sessionId:this.vI.config.sessionId},{extraLogsPercentage:5})}}kq(){this.Hq=this.currentTime,this.setSource(this.Cq,!0,!0),this.zq.attachMedia().then((()=>{this.Eq.play()})).catch((t=>{this.xq=!1,this.lT.next(jt.wB.Error),(0,p.n)({message:"VideoHandler_hls_error_attach_media",exception:t.message,callStack:t.callStack,level:p.D.CRITICAL,sessionId:this.vI.config.sessionId},{extraLogsPercentage:5})}))}jq(){this.WN.push(this.ST.onHlsEvent.subscribe((t=>this.Tq(t))))}$q(){this.Wq(this.Dq)}Fq(){this.ST&&this.Wq(this.ST)}Wq(t){t.start(),this.Gq(t)}Uq(){this.Eq.videoEvents.subscribe((t=>{var i;if(t.payload&&t.payload.isCorruptedCurrentTime)this.zq.handlerType===ja.HLS&&this.kq();else{if(t.type===jt.wB.Canplay&&this.xj&&(this.currentTime=this.xj,this.xj=null),this.lT.next(t.type),this.xq&&(this.xq=!1,t.type===jt.wB.Playing&&(this.Eq.currentTime=this.Hq)),t.type===jt.wB.Error)return(0,p.n)({message:"VideoHandler_play_error_event",exception:t.payload.errorMessage,level:p.D.WARN,sessionId:this.vI.config.sessionId},{extraLogsPercentage:5}),void this.mediator.publish(this,jt.T$.PlayError,{payload:null===(i=t.payload)||void 0===i?void 0:i.errorMessage});this.mediator.publish(this,t.type,{payload:t.payload})}}))}Gq(t){this.WN.push(t.onTrackLoaded.subscribe((()=>this.Q$())),t.onQualityChange.subscribe((t=>this.onQualityChanged(t))),t.onCurrentQuality.subscribe((t=>{this.mediator.publish(this,jt.XQ.CurrentQuality,{payload:t})})))}Xq(t,i=!1){return Za(this,void 0,void 0,(function*(){if(i)this.Jq();else{if(t){if(yield this.Vq())return void(this.zq=this.ST)}this.Jq()}}))}get width(){return this.Oq.getBoundingClientRect().width}get height(){return this.Oq.getBoundingClientRect().height}get currentTime(){return this.Eq.currentTime}set currentTime(t){this.Eq.currentTime=t}forceCurrentTime(t){this.Eq.currentTime=t,this.xj=t}get duration(){return this.Eq.duration}get volume(){return this.Eq.volume}set volume(t){this.Eq.volume=t}toggleMute(){if(0===this.Eq.volume)return this.Fm=this.Fm>0?this.Fm:.2,void(this.Eq.volume=this.Fm);this.Fm=this.Eq.volume,this.Eq.volume=0}increaseVolume(t){this.Eq.volume+t>1?this.Eq.volume=1:this.Eq.volume+=t}decreaseVolume(t){this.Eq.volume-t<0?this.Eq.volume=0:this.Eq.volume-=t}get playing(){return this.Eq.isPlaying}get isIosFullscreen(){return this.HN}set isIosFullscreen(t){this.HN=t,this.HN&&this.Lq?this.Yq():this.Kq()}get currentQualitySettings(){var t;return null===(t=this.zq)||void 0===t?void 0:t.currentQualitySettings}hide(){(0,u.cn)(this.Oq,P.pT)}show(){(0,u.IV)(this.Oq,P.pT)}setSource(t,i=!1,e=!1){return Za(this,void 0,void 0,(function*(){try{this.Cq=t,this.zq&&this.zq.detachMedia();const n=(0,s.QM)(t.hlsFilePath);return yield this.Xq(n,e),t&&t.subtitles&&this.Eq.setCrossOriginAttribute(),this.Ox.setAttribute("title",t.altText),this.Eq.setPoster(t),this.Eq.setTrackModes(this.Lq?Xa.Hidden:Xa.Disabled),i&&this.Eq.setMetaLoaded(!1),this.zq.setSource(t,!0),void this.mediator.publish(this,jt.T$.NewVideo)}catch(t){return void(0,p.n)({message:"VideoHandler_set_video_source",exception:t.message,callStack:t.stack,level:p.D.CRITICAL,sessionId:this.vI.config.sessionId},{extraLogsPercentage:5})}}))}setQuality(t){this.zq.setQuality(t)}pause(){this.Eq.pause(),this.lT.next(jt.wB.Pause)}play(){var t;return this.Zq=new Wt.C,null===(t=this.zq)||void 0===t||t.attachMedia().then((()=>{this.Eq.play()})).catch((t=>{this.lT.next(jt.wB.Error),(0,p.n)({message:"VideoHandler_public_play_attach_media_error",exception:t.message,callStack:t.callStack,level:p.D.CRITICAL,sessionId:this.vI.config.sessionId},{extraLogsPercentage:5})})),this.Zq.promise}hasSubtitles(){return(0,S.BZ)(this.Cq.subtitles)}getSubtitles(){return this.Cq.subtitles}toggleCaptions(){this.zq.updateSubtitleTrackSource(this.Cq.getDefaultSubtitle()),this.Lq=!0,this.Eq.setTrackModes(Xa.Hidden)}togglePlay(){return this.playing?(this.pause(),!1):(this.play(),!0)}showCaptions(t){var i;void 0===t&&(t=null===(i=this.Cq.getDefaultSubtitle())||void 0===i?void 0:i.file);const e=this.Cq.subtitles.find((i=>i.file===t));this.zq.updateSubtitleTrackSource(e),this.Lq=!0,this.Eq.setTrackModes(Xa.Hidden)}hideCaptions(){this.zq.updateSubtitleTrackSource(),this.Lq=!1,this.Eq.setTrackModes(Xa.Disabled),this.mediator.publish(this,Jt.C[Jt.C.CaptionUpdate])}get areCaptionsEnabled(){return this.Lq}getSelectedCaption(){return this.zq.getSelectedCaptionTrack()}destroy(){this.zq.destroy(),this.Oq.parentNode.removeChild(this.Oq),this.Eq.destroy()}Bq(){if(this.Oq=this.ol.createElementByString(`<cnx class="${P.s6.VideoWrapper}"></cnx>`),this.Ox=this.ol.createElementByString('<video class="cnx-video-tag"></video>'),this.j$.os===zt.M.Ios&&(this.Ox.setAttribute("playsinline",""),this.Ox.setAttribute("webkit-playsinline","")),this.vI.config.isMobile)_t.n.defaultVideoPosterURL=Vh.getDefaultPoster(this.vI.services.UrlSuffixerService),this.Ox.poster=_t.n.defaultVideoPosterURL;else{this.Aq&&(this.Ox.tabIndex=0,this.Ox.setAttribute("aria-label","Connatix video player"));const t=this.vI.services.GlobalDomUtilsService.createElementByString("<cnx class='cnx-border'></cnx>");this.Oq.appendChild(t)}if(this.j$.os===zt.M.Android&&((0,s.QM)(this.vI.config.bundleID)||(0,h.Qq)())){const t=this.ol.createElementByString('<cnx class="cnx_gpu_fix"></cnx>');this.Oq.appendChild(t)}}Jq(){this.zq=this.Dq,this.zq.setQuality({quality:jt.ZH.Auto,height:0})}onQualityChanged(t){const i=this.Eq.isPlaying;this.zq.handlerType===ja.MP4&&(this.xj=this.currentTime),i&&this.zq.onQualityChanged&&this.zq.onQualityChanged().then((()=>{this.Eq.setMetaLoaded(!1),this.Eq.play()})),this.mediator.publish(this,jt.XQ.Change,{payload:t})}get currentTrack(){return this.Eq.getCurrentTrack()}Yq(){this.currentTrack&&(this.currentTrack.oncuechange=null,this.mediator.publish(this,Jt.C[Jt.C.CaptionUpdate]),this.currentTrack.mode=Xa.Showing)}Kq(){if(this.currentTrack){switch(this.currentTrack.mode){case Xa.Showing:case Xa.Hidden:this.Lq=!0;break;case Xa.Disabled:this.Lq=!1}this.mediator.publish(this,this.Lq?Jt.C[Jt.C.CaptionOn]:Jt.C[Jt.C.CaptionOff])}this.Q$()}}class ic extends tc{play(){const t=this.zq.liveSyncPosition;return t&&(this.Eq.currentTime=t),super.play()}endOfStream(){this.zq.detachMedia()}get hlsSupported(){return this._q}kq(){this.Zq&&this.Zq.isPending&&this.Zq.reject(),this.zq.detachMedia(),this.mediator.publish(this,jt.T$.LiveStreamNotPlayable)}initHlsSourceHandler(t){super.initHlsSourceHandler(t)}}!function(t){t.Replay="replay",t.Next="next",t.Prev="prev"}(Ka||(Ka={}));var ec=r(6404),sc=r(4467);const nc=new Map([[Jt.C[Jt.C.Replay],Ka.Replay],[Jt.C[Jt.C.Next],Ka.Next],[Jt.C[Jt.C.Prev],Ka.Prev],[Jt.C[Jt.C.Play],Aa.Play],[Jt.C[Jt.C.Volume],Aa.Volume],[Jt.C[Jt.C.Pause],Aa.Pause],[Jt.C[Jt.C.Seek],Aa.Seek],[Jt.C[Jt.C.SeekingStart],Aa.SeekingStart],[Jt.C[Jt.C.SeekingStopped],Aa.SeekingStop],[Jt.C[Jt.C.Quality],Aa.Quality],[Jt.C[Jt.C.CaptionOn],Aa.CaptionOn],[Jt.C[Jt.C.CaptionOff],Aa.CaptionOff],[Jt.C[Jt.C.Expand],ka.t.Expand],[Jt.C[Jt.C.Collapse],ka.t.Collapse],[Jt.C[Jt.C.Close],ka.t.Close],[Jt.C[Jt.C.OverlayClick],ka.t.OverlayClick],[ka.t.GeneralUserInteraction,ka.t.GeneralUserInteraction]]),rc=new Map([[Aa.Play,i.$u.PlayClick],[Aa.Pause,i.$u.PauseClick],[Ka.Next,i.$u.NextClick],[Ka.Prev,i.$u.PreviousClick],[Aa.Volume,i.$u.VolumeClick],[ka.t.Expand,i.$u.FullScreenClick],[ka.t.Collapse,i.$u.ExitFullScreenClick],[Aa.CaptionOn,i.$u.SubtitleClick],[Aa.CaptionOff,i.$u.SubtitleClick],[ka.t.Close,i.$u.CloseClick]]),oc=new Map([[v.ProtoPlayerCloseButtonMode.Off,ec.N.Off],[v.ProtoPlayerCloseButtonMode.OnHover,ec.N.OnHover],[v.ProtoPlayerCloseButtonMode.OnHoverAfterFirstAd,ec.N.Off],[v.ProtoPlayerCloseButtonMode.AlwaysOn,ec.N.AlwaysOn]]),hc={[Gh.ProtoLogoPositionMode.BottomRight]:sc.q.BottomRight,[Gh.ProtoLogoPositionMode.TopLeft]:sc.q.TopLeft};var ac=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};function cc(){return ac(this,void 0,void 0,(function*(){return yield(0,h.Up)((()=>ac(this,void 0,void 0,(function*(){return yield r.e("elements.ui").then(r.bind(r,7841))}))))}))}var dc=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class lc extends I._{constructor(t,i,e,s,n){super(),this.ol=t,this.bn=i,this.ra=e,this.tH=s,this.iH=n,this.eH=new J.x}get onUIEvent(){return this.eH.asObservable()}destroy(){this.m$.destroy()}onResize(t){var i;null===(i=this.m$)||void 0===i||i.onResize(t)}enterFullscreen(){this.m$.expand()}exitFullscreen(){this.m$.collapse()}toggleCaptionButton(t){this.m$.toggleCaptionState(t)}togglePlaylistControls(t){this.m$.togglePlaylistControls(t)}toggleExpandButton(t){this.m$.toggleExpandButtonDisplay(t)}changeState(t){this.m$.changeState(t)}updateUpNextBox(t,i){this.m$.updateUpNextBox(t,i)}updateActiveCue(t){this.m$.updateCaptions(t)}updateDefaultCaption(t){this.m$.updateDefaultCaptions(t)}updateCurrentVideo(t){this.m$.updateCurrentVideo(t)}updateCurrentTime(t,i){this.m$.updateDuration(t,i)}updateBufferedState(){}updateVolume(t){this.m$.updateVolume(t)}updateQuality(t,i){this.m$.updateQuality(t,i)}start(t,i,e){return dc(this,void 0,void 0,(function*(){const s=yield cc(),n=i?s.LiveUiContent:s.VideoUiContent,{template:r}=new s.VideoTemplate(t,i);this.m$=new n(this,this.ol,this.bn,this.ra,this.tH,r,t,this.iH,e),this.S$(),this.m$.start()}))}S$(){nc.forEach(((t,i)=>{this.subscribe(i,this.m$,(i=>{const e={type:t,payload:i.payload};this.eH.next(e)}))}))}}var uc=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class pc extends Ma{constructor(){super(...arguments),this.nH=!1,this.rH=()=>{this.wj.getCurrentVideoData((()=>{this.Sj.onVideoEvents.pipe((0,dt.h)((t=>t===jt.wB.Playing&&!this.nH)),(0,lt.q)(1),qi((()=>this.nH=!0))).subscribe((()=>{this.p$.enterLiveStreamStopped(),this.Sj.pause(),this.a$.next(!0)})),this.Sj.play().catch((()=>{}))})),this.Sj.play()},this.oH=()=>{this.p$.endOfStream(),this.Sj.endOfStream()}}start(){const t=Object.create(null,{start:{get:()=>super.start}});return uc(this,void 0,void 0,(function*(){yield t.start.call(this),this.hH(),this.I$(),this.Sj.hlsSupported?(this.Sj.start(),this.v$().then((()=>{this.rH(),this.c$.next(!0)}))):this.p$.enterLiveNotSupported()}))}destroy(){this.aH(),this.cH(),super.destroy()}hH(){this.subscribe(jt.T$.EndOfStream,this.Sj,this.oH),this.subscribe(jt.T$.LevelSwitching,this.Sj,(()=>{this.p$.onEnterBuffering()}))}O$(t){return uc(this,void 0,void 0,(function*(){this.m$=new lc(this.vI.services.GlobalDomUtilsService,this.vI.services.InteractionService,this.vI.services.ResizeObserver,this.fI,this.vI.config.appId),this.S$(),yield this.m$.start(t,!0,this.r$)}))}V$(t){this.dH(t)}x$(){}w$(){}I$(){const{preRollBreak:t,postRollBreak:i}=this.Ab,e=(0,s.r)(t),n=(0,s.r)(i);this.p$=new La(this,this.wj,this.Sj,e,n,this.vI.config.os.os===zt.M.Ios,this.Ab.videoPosition),super.I$()}l$(){super.l$(),this.subscribe(jt.T$.LiveStreamNotPlayable,this.Sj,(()=>{clearTimeout(this.lH),this.lH=setTimeout(this.rH,10*Lt.s_)}))}R$(t,i){this.Sj=new ic(this,this.vI,this.vI.services.GlobalDomUtilsService,this.fI,this.vI.services.ResizeObserver,i,t,!0,this.Ab.videoPosition)}dH(t){this.aH(),t&&(this.uH=setInterval((()=>{this.p$.isInPlayingState()&&(this.oH(),this.aH())}),10*Lt.s_))}aH(){this.uH&&(clearInterval(this.uH),this.uH=null)}cH(){this.lH&&(clearInterval(this.lH),this.lH=null)}}var fc=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class mc extends Ia{start(){const t=Object.create(null,{start:{get:()=>super.start}});return fc(this,void 0,void 0,(function*(){try{t.start.call(this)}catch(t){(0,p.n)({message:"LiveExperience_start",exception:t.message,callStack:t.stack,level:p.D.CRITICAL})}}))}ZN(){this.Wf=new pc(this,this.Ab,this.app,this.$playerContainer,this.breakPointsHandler.currentBreakpointClass)}Pb(){this.ob.isInAdPod()?this._b((()=>{super.Pb(),this.hb.onAdFinished(this.adHandler.linearInImpression,Bi.LINEAR,this.ob.isInAdPod()),this.Wf.show(true)})):(super.Pb(),this.Wf.show(true))}ej(){super.ej(),this.subscribe(jt.d0.NewThumbnail,this.Wf,(({payload:{thumbnailUrl:t}})=>{this.adHandler&&this.adHandler.setAdLoadingBackgroundUrl(t)}))}}class gc{constructor(t){this.experience=t,this.pH=(t,i)=>this.Fu.on(t,i),this.fH=(t,i)=>{this.Fu.remove(t,i)},this.mH=()=>{this.Fu.removeAll()},this.gH=(t,i)=>{this.Fu.once(t,i)},this.vH=()=>this.experience.isViewable(),this.yH=t=>{this.experience.setViewableThreshold(t)},this.bH=()=>{this.experience.play()},this.IH=()=>{this.experience.pause()},this.wH=()=>this.experience.getVolume(),this.SH=t=>{this.experience.setVolume(t)},this.Wg=()=>{this.experience.triggerDestroy()},this.Mu=()=>{this.experience.disableAdvertising()},this.PH=()=>{this.experience.enableAdvertising()},this.AH=()=>{this.experience.enableFloatingMode()},this._H=()=>{this.experience.disableFloatingMode()},this.xH=()=>this.experience.isFloatingModeEnabled(),this.Xg=t=>{this.experience.setFloatingSettings(t)},this.TH=(t,i)=>this.experience.setLineItemMetadata(t,i),this.getFloatingSettings=()=>this.experience.getFloatingSettings(),this.kH=t=>{this.experience.setCustomMacros(t)},this.CH=t=>{this.experience.setAmpUserConsent(t)},this.EH=t=>{n.CONNECTION_TYPE=t},this.MH=t=>{this.experience.updateJsQueryTargeting(t)},this.LH=t=>{this.experience.removeJsQueryTargeting(t)},this.BH=()=>n.CONNECTION_TYPE,this.RH=()=>this.experience.getApiConfig(),this.OH=()=>this.experience.getSessionDataConfig(),this.Fu=new B}trigger(t,i){this.Fu.trigger(t,i)}setDestroyed(){this.trigger(M.Km.Removed)}getApiMethods(){return{on:this.pH,remove:this.fH,removeAll:this.mH,once:this.gH,isViewable:this.vH,setViewableThreshold:this.yH,play:this.bH,pause:this.IH,getVolume:this.wH,setVolume:this.SH,disableAdvertising:this.Mu,enableAdvertising:this.PH,enableFloatingMode:this.AH,disableFloatingMode:this._H,isFloatingModeEnabled:this.xH,setFloatingSettings:this.Xg,getFloatingSettings:this.getFloatingSettings,setMacros:this.kH,setAmpUserConsent:this.CH,destroy:this.Wg,updateConnectionType:this.EH,getConnectionType:this.BH,updateJsQueryTargeting:this.MH,removeJsQueryTargeting:this.LH,setLineItemMetadata:this.TH,getApiConfig:this.RH,getSessionDataConfig:this.OH}}}class vc extends gc{constructor(){super(...arguments),this.DH=()=>this.experience.type,this.uk=()=>this.experience.getSize(),this.VH=(t,i)=>{this.experience.setSize(t,i)}}getApiMethods(){return Object.assign(Object.assign({},super.getApiMethods()),{getPlayerType:this.DH,getSize:this.uk,setSize:this.VH})}}class yc extends vc{}class bc extends Uh{constructor(){super(...arguments),this.FH=[],this.enterFullScreen=()=>{this.KN.enterFullScreen().then().catch((t=>{(0,p.n)({level:p.D.WARN,message:"OutstreamAdHandler_enterFullscreen"})}))},this.exitFullscreen=()=>{this.KN.exitFullScreen()},this.Rb=()=>{this.vI.services.InteractionService.enableScrollEvent(),this.vI.services.EventsStorageService.emitOnExitFullscreen(),this.linearAdUserInterface.collapse(),this.setVastViewMode(x.Normal)},this.Bb=()=>{this.vI.services.InteractionService.disableScrollEvent(),this.vI.services.EventsStorageService.emitOnEnterFullscreen(),this.linearAdUserInterface.expand(),this.setVastViewMode(x.Fullscreen)}}initFullScreen(){this.KN=new Gt(this.vI.services.GlobalDomUtilsService,this.zI.parentElement,this.vI.config.os.os),this.Ij()}Ij(){this.FH.push(this.onFullcreenChange.subscribe((t=>{t===Jt.C.Expand?this.enterFullScreen():this.exitFullscreen()}))),this.dj()}dj(){const t=this.KN.onFullScreenEnter.subscribe((()=>this.Bb())),i=this.KN.onFullScreenExit.subscribe((()=>this.Rb()));this.FH.push(i,t)}destroy(){super.destroy(),(0,it.i)(this.FH)}tF(){return!1}}var Ic=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class wc extends fa{constructor(){super(...arguments),this.events=Object.assign(Object.assign({},M.Km),ga),this.NH=!1,this.jH=!1,this.$H=!1,this.UH=t=>{"max-height"===t.propertyName&&(this.$experienceContainer.removeEventListener("transitionend",this.UH),this.handleClose())}}ub(){var t,i;const e=!(!(null===(t=this.floatingModule)||void 0===t?void 0:t.isInFloating)&&!(null===(i=this.alwaysFloatingModule)||void 0===i?void 0:i.isInFloating));return new bc(e,this.hb.isAdvertisingDisabled,this.Ab,this.Dc,this.$playerContainer,this.checkFloatingViewability(this.isViewable()),this.ob,this.app,this._appSettings,this.Jv,ri.None)}qH(){this.adHandler&&this.adHandler.linearInImpression?this.NH=!0:this.HH()}HH(){this.hb.onContentStop(),this.Ab.outstreamSettings.endAdBreakPolicy===Gh.ProtoOutstreamEndAdBreakPolicyEnum.Hide&&this.zH(!0),this.mediator.publish(this,ga.AdCycleComplete)}WH(){return{logoPosition:this.Ab.logoPosition,logoUrl:this.Ab.logoUrl,isCloseButton:this.Ab.isCloseButton,closeButtonMode:this.Ab.closeButtonMode,backgroundColor:this.Ab.outstreamSettings.houseScreenBackgroundColor,uiComponentsVisibility:{expandButton:this.Ab.uiComponentsVisibility.expandButton&&this.app.config.os.os!==zt.M.Ios}}}GH(){return Ic(this,void 0,void 0,(function*(){let t;try{t=yield cc()}catch(t){throw t}const{UiOutstream:i,OutstreamTemplate:e}=t,s=this.WH(),n=new e(s).template;this.XH=new i(this,this.$playerContainer,this.app.services.GlobalDomUtilsService,this.app.services.InteractionService,s,n),this.subscribe(Jt.C[Jt.C.Close],this.XH,(()=>{this.mediator.publish(this,ya.CloseButtonClicked),this.handleClose()})),this.subscribe(Jt.C[Jt.C.Expand],this.XH,(()=>{this.adHandler.enterFullScreen()})),this.subscribe(Jt.C[Jt.C.Collapse],this.XH,(()=>{this.adHandler.exitFullscreen()}))}))}QH(t){this.$H&&((0,u.IV)(this.$experienceContainer,P.s6.Collapsed),this.mediator.publish(this,ga.Collapsed,{payload:!1}),this.$H=!1,this.tb(t))}zH(t=!1){if(!this.$H){if(t){const t=setTimeout((()=>{this.$experienceContainer.removeEventListener("transitionend",this.UH),this.handleClose()}),1e3);this.$experienceContainer.addEventListener("transitionend",(i=>{clearTimeout(t),this.UH(i)}))}(0,u.cn)(this.$experienceContainer,P.s6.Collapsed),this.mediator.publish(this,ga.Collapsed,{payload:!0}),this.$H=!0,this.Zy()}}JH(){this.$experienceContainer.style.maxHeight=`${this.$playerContainer.clientHeight}px`}YH(){this.XH&&this.XH.hide()}KH(){this.XH&&this.XH.show()}handleClose(){this.triggerDestroy()}_p(){super._p(),this.JH()}Sb(t=!1){super.Sb(t),this.NH&&this.HH()}av(t,i=!1){super.av(t,i),!this.jH&&t&&(this.jH=!0,this.tz())}Pb(){this.ob.isInAdPod()?this._b((()=>{this.hb.onAdFinished(this.adHandler.linearInImpression,Bi.LINEAR,this.ob.isInAdPod()),super.Pb(),this.KH(),this.ob.setNewBreak(Gh.ProtoAdSlotsEnum.MidRoll)})):(super.Pb(),this.ob.setNewBreak(Gh.ProtoAdSlotsEnum.MidRoll),this.KH())}wb(){super.wb(),this.YH()}addPlayerSize(){super.addPlayerSize(),this.Ab.playerSize.responsive?this.$playerWrapper.appendChild(this.Ob()):this.setFixedSize(this.$playerWrapper)}Mb(){super.Mb()}tz(){var t;if(this.Ab.adPlaybackMode===Gh.ProtoAdPlaybackMode.ScrollToPlay&&!this.jH)return;this.ib(Gh.ProtoAdSlotsEnum.MidRoll);null===(t=this.adHandler)||void 0===t||t.contentPlaybackStateChanged(true),this.hb.contentPlaybackStateChanged(true)}rb(){this.Qy(Q.Standalone)}iz(){}start(){const t=Object.create(null,{start:{get:()=>super.start}});var i,e;return Ic(this,void 0,void 0,(function*(){try{t.start.call(this),this.kb(),this.adHandler?(this.adHandler.start(this.$playerContainer.clientWidth,this.$playerContainer.clientHeight,this.Ab.soundMode===Gh.ProtoPlayerSoundMode.On?1:0,this.Ab.uiComponentsVisibility.expandButton&&this.app.config.os.os!==zt.M.Ios,!1),this.adHandler.enablePrefetchForLinearity(Bi.LINEAR),this.adHandler.initFullScreen(),this.hb.forceRecheck(),null===(i=this.adHandler)||void 0===i||i.onVpaidEvent.subscribe((t=>{if(t.type===T.AdImpression){const{clientWidth:i,clientHeight:e}=t.payload.payload.selectedAdSlot;this.QH({width:i,height:e})}})),null===(e=this.adHandler)||void 0===e||e.onLinearUiComponentEvent.subscribe((t=>{switch(t.type){case Jt.C.Volume:const{volume:i}=t.payload;this.gp(i);break;case Jt.C.Expand:this.expand();break;case Jt.C.Collapse:this.collapse()}}))):this.zH(),this.tz(),this.subscribe(ci,this.hb,(()=>{this.qH()})),this.subscribe(di,this.hb,(()=>{this.qH()})),this.Ab.outstreamSettings.initialRendering===Gh.ProtoOutstreamInitialRenderingEnum.ExpandWithAd&&(this.zH(),(0,u.Tp)(this.$playerContainer)),(0,u.cn)(this.$experienceContainer,P.Gj.Collapsable),this.JH(),this.Ab.outstreamAdAsContent||(yield this.GH())}catch(t){(0,p.n)({message:"Outsream_start",exception:t.message,callStack:t.stack,level:p.D.CRITICAL})}}))}getVolume(){if(this.adHandler)return this.adHandler.getLinearVolume()}get currentTime(){return 0}get duration(){return 0}destroy(){super.destroy(),this.XH&&this.XH.destroy()}expand(){var t;null===(t=this.XH)||void 0===t||t.getComponent(Ih.r.ExpandButton).setState(Rh.q.expand)}collapse(){var t;null===(t=this.XH)||void 0===t||t.getComponent(Ih.r.ExpandButton).setState(Rh.q.collapse)}}class Sc extends vc{constructor(t){super(t),this.experience=t,this.ez=()=>this.experience.getVideoDetails(),this.sz=()=>this.experience.getPlaylistId(),this.nz=()=>this.experience.getPlaylistDetails(),this.rz=()=>this.experience.getAllMetadata(),this.oz=t=>this.experience.setPlaylistDetails(t),this.hz=()=>this.experience.currentTime,this.az=t=>{this.experience.setVideoPosition(t)},this.cz=()=>this.experience.duration,this.lz=t=>{this.experience.toggleFullscreen(t)},this.uz=t=>{this.experience.toggleCaptions(t)},this.pz=()=>this.experience.getSubtitles(),this.fz=t=>{t&&t.file?this.experience.showCaptions(t.file):this.experience.hideCaptions()},this.mz=t=>{this.experience.toggleExpandButton(t)},this.gz=()=>this.experience.getQuality(),this.vz=t=>{this.experience.setQuality(t)},this.bz=()=>{this.experience.setAutoQuality()},this.Iz=()=>this.experience.getAvailableQualities(),this.wz=()=>{this.experience.nextVideo()},this.Pz=()=>{this.experience.prevVideo()},this.Az=t=>{this.experience.setPreRollBreak(t)},this._z=t=>{this.experience.setPostRollBreak(t)},this.xz=()=>this.experience.getVideoIndex(),this.Tz=t=>{this.experience.setVideoIndex(t)}}getApiMethods(){return Object.assign(Object.assign({},super.getApiMethods()),{getVideoDetails:this.ez,getVideoCurrentPosition:this.hz,setVideoPosition:this.az,getVideoDuration:this.cz,toggleFullscreen:this.lz,toggleSubtitles:this.uz,getSubtitles:this.pz,setSubtitle:this.fz,toggleFullscreenButton:this.mz,getPlaylistId:this.sz,getPlaylistDetails:this.nz,getAllMetadata:this.rz,setPlaylistDetails:this.oz,getQuality:this.gz,setQuality:this.vz,setAutoQuality:this.bz,getAvailableQualities:this.Iz,nextVideo:this.wz,prevVideo:this.Pz,setPreRollBreak:this.Az,setPostRollBreak:this._z,getVideoIndex:this.xz,setVideoIndex:this.Tz})}}var Pc=r(3310);const Ac=t=>t.clientHeight||t.getBoundingClientRect().height||0,_c=t=>t.clientWidth||t.getBoundingClientRect().width||0,xc=(t,i,e=!1)=>{const s=t.offsetTop,n=((t,i)=>(parseInt(i.getMarginTopPropertyValue(t),10)||0)+(parseInt(i.getMarginBottomPropertyValue(t),10)||0))(t,i),r=Ac(t),o=Ac(t.parentElement);let h=s;if(e){const t=Math.floor(o/(r+n)),i=Math.floor(t/2);h=Math.max(s-i*(r+n),0)}t.parentElement.scrollTop=h},Tc=(t,i,e=!1)=>{const s=t.offsetLeft,n=((t,i)=>(parseInt(i.getMarginLeftPropertyValue(t),10)||0)+(parseInt(i.getMarginRightPropertyValue(t),10)||0))(t,i),r=_c(t),o=_c(t.parentElement);let h=s;if(e){const t=Math.floor(o/(r+n)),i=Math.floor(t/2);h=Math.max(s-i*(r+n),0)}t.parentElement.scrollLeft=h};var kc,Cc=r(6203);class Ec{constructor(t,i,e={}){this.ZU=t,this.yn=i,this.kz=1.2,this.Mz=16,this.Lz="normal",this.j$={lines:0,useNativeClamping:!0},this.Bz=!1,this.j$=Object.assign(Object.assign({},this.j$),e),this.Bz=this.Rz()}setLines(t){this.j$.lines=t}getClampedText(t){this.Oz=t.trim(),this.Dz=this.yn.createElementByString(`<cnx-span style="display:inline-block;width:100%;line-height:inherit;font-family:inherit;font-size:inherit;">${this.Oz}</cnx-span>`),this.ZU.appendChild(this.Dz);let i=0;try{i=this.Vz()}catch(t){(0,p.n)({message:"LineClamp_getMaxLines",exception:t.message,callStack:t.stack,level:p.D.CRITICAL})}const e=this.Fz(this.j$.lines,i),s=this.Nz(e);return Math.ceil(this.Dz.getBoundingClientRect().height)-1<=s?(this.jz(),this.Oz):this.Bz?void(0,u.T7)(this.ZU,{overflow:"hidden",textOverflow:"ellipsis",webkitBoxOrient:"vertical",display:"-webkit-box",webkitLineClamp:e}):this.$z(this.Dz.firstChild,s)}Rz(){return!!this.j$.useNativeClamping&&void 0!==this.ZU.style.webkitLineClamp}Nz(t){return this.Uz(this.ZU)*t+(this.qz(this.Dz)+this.qz(this.ZU))+(this.zz(this.Dz)+this.zz(this.ZU))}Wz(t){if(t.getBoundingClientRect){const{height:i}=t.getBoundingClientRect();if(i>0)return Math.ceil(i)}const i=t.clientHeight;return i&&i>0?Math.ceil(i):t.parentNode?this.Wz(t.parentNode):0}Vz(){const t=this.Wz(this.ZU),i=this.Uz(this.ZU),e=this.qz(this.Dz)+this.qz(this.ZU),s=this.zz(this.Dz)+this.zz(this.ZU),n=Math.floor((t-e-s)/i+.05);return Math.max(n,0)}Gz(t){const i=this.yn.getFontSizePropertyValue(t);return i?parseInt(i,10):this.Mz}Uz(t){let i=this.yn.getLineHeightPropertyValue(t);return i&&i!==this.Lz||(i=""+this.kz*this.Gz(t)),parseInt(i,10)}qz(t){if(!t)return 0;const i=this.yn.getPaddingTopPropertyValue(t);return parseInt(i,10)||0}zz(t){if(!t)return 0;const i=this.yn.getPaddingBottomPropertyValue(t);return parseInt(i,10)||0}Fz(t,i){return t>0?0===i?t:Math.min(this.j$.lines,i):i}$z(t,i,e){if(!i)return;void 0===e&&(e=t.nodeValue.split(" "));const s=[...e];if(s.length>1){s.pop(),this.Qz(t,`${s.join(" ")}...`);return t.parentNode.offsetHeight>i?this.$z(t,i,s):(this.jz(),`${s.join(" ")}...`)}}Qz(t,i){t.nodeValue=i}jz(){this.ZU.innerHTML="",this.Dz=null}}!function(t){t[t.CardClicked=0]="CardClicked"}(kc||(kc={}));const Mc={width:160,height:90},Lc={width:80,height:80};const Bc='<cnx class="cnx-g-card"><cnx class="cnx-g-card-image-container"><cnx class="cnx-g-triangle"></cnx><cnx class="cnx-g-card-image"><cnx class="cnx-g-card-icon"><cnx class="cnx-ui-btn"><cnx class="cnx-icon-button cnx-ui-btn-hoverable cnx-mod-hover"><cnx class="cnx-btn-container"><cnx class="cnx-play-icon"><svg markup-inline class="cnx-color-icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M5 4v16l16-8z" fill-rule="evenodd"/></svg></cnx></cnx></cnx></cnx></cnx></cnx></cnx><cnx class="cnx-g-card-text-container"><cnx class="cnx-g-card-text"><cnx-span></cnx-span></cnx></cnx></cnx>';class Rc extends I._{constructor(t,i,e,n,r){super(),this.mediator=t,this.ra=i,this.ol=e,this.bn=n,this.ci=r,this.sa=()=>{this.ci.metadata.title&&this.Jz()},this.Yz=()=>{this.mediator.publish(this,kc[kc.CardClicked],{payload:this.ci.id})},this.Kz=this.ol.createElementByString(this.Zz()),this.Kz.setAttribute("role","button"),this.Kz.setAttribute("aria-label",`Video - ${this.ci.metadata.title}`),this.tW=this.Kz.getElementsByClassName(P.Ih.CardImage)[0],this.iW=this.Kz.getElementsByClassName(P.Ih.CardText)[0],this.eW=this.Kz.getElementsByClassName(P.Ih.CardTextContainer)[0],this.ci.titleFont&&(0,u.T7)(this.eW,{"font-family":this.ci.titleFont});const o=this.ol.createElement("img");o.onload=()=>{this.tW.appendChild(o)};const h=this.ci.metadata.getThumbnailUrl(this.sW().width,this.sW().height);if((0,s.QM)(h)&&(o.src=h),o.alt=(0,s.$K)(this.ci.metadata.altText)?this.ci.metadata.altText:"",this.ci.style===Gh.ProtoGalleryStyleMode.Detailed&&this.ci.metadata.duration){const t=this.ol.createElementByString(`<cnx class="cnx-g-card-text-info">${(0,Pr.to)(this.ci.metadata.duration)}</cnx>`);this.ci.bodyFont&&(0,u.T7)(t,{"font-family":this.ci.bodyFont}),this.eW.appendChild(t)}this.bn.register(this.Kz,this,this.bn),this.subscribe(Cc.Z[Cc.Z.Click],this.bn,(()=>{this.Yz()})),this.relay(Cc.Z[Cc.Z.Scroll],this.bn,this,this.mediator),this.nW=new Ec(this.iW,this.ol,{lines:3,useNativeClamping:!1}),this.ra.on(this.Kz,this.sa)}Zz(){return this.ci.style===Gh.ProtoGalleryStyleMode.Visual?'<cnx class="cnx-g-card"><cnx class="cnx-g-triangle"></cnx><cnx class="cnx-g-card-image"></cnx><cnx class="cnx-g-card-text-container"><cnx class="cnx-g-card-text"></cnx></cnx><cnx class="cnx-g-card-icon"><cnx class="cnx-ui-btn"><cnx class="cnx-icon-button cnx-ui-btn-hoverable cnx-mod-hover"><cnx class="cnx-btn-container"><cnx class="cnx-play-icon"><svg markup-inline class="cnx-color-icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M5 4v16l16-8z" fill-rule="evenodd"/></svg></cnx></cnx></cnx></cnx></cnx></cnx>':Bc}sW(){return this.ci.style===Gh.ProtoGalleryStyleMode.Visual?Mc:Lc}Jz(){const t=this.nW.getClampedText(this.ci.metadata.title),i=this.ol.createElementByString(`<cnx-span>${t}</cnx-span>`);(0,u.jG)(i,this.iW)}get $element(){return this.Kz}setActiveState(t){t?(this.Kz.setAttribute("aria-current","true"),(0,u.cn)(this.Kz,P.Gj.Active)):(this.Kz.removeAttribute("aria-current"),(0,u.IV)(this.Kz,P.Gj.Active))}destroy(){this.Kz.removeEventListener("click",this.Yz),this.ra.off(this.Kz,this.sa)}clampLines(){this.Jz()}}const Oc=Rc;class Dc extends I._{constructor(t,i,e,s,n){if(super(),this.mediator=t,this.ra=i,this.ol=e,this.bn=s,this.ci=n,this.rW=!1,this.ci.$slot.innerHTML=`<cnx class="${P.Ih.CardPlaceholder}"></cnx>`,this.ci.style===Gh.ProtoGalleryStyleMode.Detailed){const t=e.createElementByString(this.hW(Bc));this.ci.$slot.firstChild.appendChild(t)}this.bn.register(this.ci.$slot,this.mediator,this),this.relay(Cc.Z[Cc.Z.Scroll],this.bn,this,this.mediator)}hW(t){const i=[...Array(12)].map((()=>`<cnx-span style='width: ${10+Math.floor(40*Math.random())}%'></cnx-span> `)).reduce(((t,i)=>t+i),"");return t.replace("<cnx-span></cnx-span>",i)}setCardData(t){this.aW=new Oc(this,this.ra,this.ol,this.bn,{id:this.ci.id,style:this.ci.style,metadata:t,titleFont:this.ci.titleFont,bodyFont:this.ci.bodyFont}),this.subscribe(kc[kc.CardClicked],this.aW,(({payload:t})=>{this.mediator.publish(this,kc[kc.CardClicked],{payload:t})})),this.unsubscribeAll(this.bn),this.relay(Cc.Z[Cc.Z.Scroll],this.aW,this,this.mediator),this.aW.setActiveState(this.rW),this.ci.$slot.innerHTML="",this.ci.$slot.appendChild(this.aW.$element)}setActiveState(t){this.rW=t,this.aW&&this.aW.setActiveState(this.rW)}getContainer(){return this.ci.$slot}clampLines(){this.aW.clampLines()}}const Vc=Dc;class Fc extends I._{constructor(t,i,e,s,n,r,o,h,a){super(),this.mediator=t,this.ra=i,this.ol=e,this.bn=s,this.In=n,this.Ym=r,this.cW=o,this.dW=h,this.lW=[],this.uW=[],this.pW=null,this.fW=0,this.mW=(0,u.nw)(this.In),this.gW=(0,u.fj)(this.In);const c=this.cW===Gh.ProtoGalleryStyleMode.Detailed?P.Ih.StyleDetailed:P.Ih.StyleVisual;if((0,u.cn)(this.In,c),this.cW===Gh.ProtoGalleryStyleMode.Detailed&&(this.In.innerHTML=`<cnx class="${P.Ih.ExploreMore}">EXPLORE MORE</cnx>`),this.Jn=e.createElementByString(`<cnx class="${P.Ih.CardRail}"></cnx>`),this.In.appendChild(this.Jn),this.cW===Gh.ProtoGalleryStyleMode.Detailed){const t=e.createElementByString(`<cnx class="${P.Ih.FadeOut}"></cnx>`);this.In.appendChild(t)}this.vW(a)}start(){this.yW(),this.bW()}onResize(t){this.IW&&(this.IW.updateWidth(t),this.wW(),this.SW())}setCurrentIndex(t){this.fW=t,this.lW.forEach(((i,e)=>i.card.setActiveState(t===e))),this.SW()}vW(t){t.forEach(((t,i)=>{const e=this.PW(i);this.Jn.appendChild(e.getContainer()),this.lW.push({card:e,videoSource:t}),this.subscribe(kc[kc.CardClicked],e,(({payload:t})=>this.AW(t))),this.relay(Cc.Z[Cc.Z.Scroll],e,this,this.mediator)}))}SW(){if((0,S.BZ)(this.uW))return;const t=this.lW[this.fW].card.getContainer();this.dW===Gh.ProtoGalleryOrientationEnum.Landscape?xc(t,this.ol,true):Tc(t,this.ol,true)}PW(t){const i=this.ol.createElementByString(`<cnx class="${P.Ih.CardSlot}"></cnx>`);return new Vc(this,this.ra,this.ol,this.bn,{id:t,style:this.cW,$slot:i,titleFont:this.mW,bodyFont:this.gW})}AW(t){this.mediator.publish(this,va.ChangeVideo,{payload:{videoIndex:t}})}yW(){this.lW.forEach((t=>{t.videoSource.getMetadata((i=>{t.card.setCardData(i),t.card.clampLines()}))}))}_W(){this.uW.forEach((t=>{this.unsubscribeAll(t),this.Jn.removeChild(t.getContainer())})),this.uW=[]}xW(){const t=this.dW===Gh.ProtoGalleryOrientationEnum.Portrait?this.Jn.clientWidth:this.Jn.clientHeight,i=this.lW[0].card.getContainer(),e=this.dW===Gh.ProtoGalleryOrientationEnum.Portrait?i.clientWidth:i.clientHeight,s=Math.ceil(t/e)+1-(this.lW.length-1);if(s>this.uW.length-1)for(let t=0;t<=s;t++){const i=this.PW(t);this.uW.push(i),this.relay(Cc.Z[Cc.Z.Scroll],i,this,this.mediator),this.Jn.appendChild(i.getContainer())}}wW(){this.TW()?(this._W(),this.kW()):(this.EW(),this.xW())}kW(){null===this.pW&&(this.pW=new Pc.$(this.Jn,{horizontal:this.dW===Gh.ProtoGalleryOrientationEnum.Portrait}),(0,u.cn)(this.Jn,P.Gj.HasCustomScrollbar))}EW(){null!==this.pW&&(this.pW.destroy(),this.pW=null,(0,u.IV)(this.Jn,P.Gj.HasCustomScrollbar))}TW(){const t=this.lW[this.lW.length-1].card.getContainer();return this.dW===Gh.ProtoGalleryOrientationEnum.Landscape?t.offsetTop+t.clientHeight>this.Jn.clientHeight:t.offsetLeft+t.clientWidth>this.Jn.clientWidth}bW(){const t=this.MW();this.IW=new Ai(this.In,t,P.Rq,this.Ym)}MW(){return pa[this.dW][this.cW]}}class Nc{get template(){return`<cnx class="cnx-video-title">\n                <cnx class="cnx-ui-btn cnx-d-sm-none cnx-pinned-close-button">[[${Ih.r.PinnedCloseButton}]]</cnx>\n                [[${Ih.r.PinnedTitle}]]\n            </cnx>`.trim()}}var jc=r(2823);class $c extends jc.${constructor(){super(...arguments),this.isAttachedToDom=()=>!!this.$uiContainer.parentNode}Wr(t,i,e){if(t===Ih.r[Ih.r.PinnedCloseButton])this.mediator.publish(this,nc.get(Jt.C[Jt.C.Close]))}updateCurrentVideo(t){const i=this.getComponent(Ih.r.PinnedTitle);i&&i.updateTitle(t)}getComponent(t){return super.getComponent(t)}onResize(t){(0,u.IV)(this.$uiContainer,this.r$),(0,u.cn)(this.$uiContainer,t),this.r$=t}destroy(){this.isAttachedToDom()&&super.destroy()}}var Uc=r(6019);class qc extends Uc.Y{constructor(t,i,e,s,n){super(t,i,e,s.template,n),this.LW=s}updateTitle(t){const{clickUrl:i,title:n}=t;if(i){(0,u.Kk)(this.In),this.In.href=i;const t=this.yn.isURLSameDomainToTop(i);this.In.target=t?e.bS.Top:e.bS.Blank,this.In.setAttribute("title",i)}else this.In.removeAttribute("title");(0,s.QM)(n)&&(0,u.jG)(this.BW(n),this.In)}BW(t){(0,u.bX)(this.In.children[0]);const i=this.LW.textTemplate(t);return this.yn.createElementByString(i)}}class Hc{get template(){return'<a class="cnx-pinned-title">\n        </a>'.trim()}textTemplate(t){return`<cnx class="pinned-title-text">\n            <cnx class="close-button-slot"></cnx>\n            ${t}\n        </cnx>`.trim()}}class zc extends Th.A{constructor(){super(...arguments),this.cV={[Ih.r.PinnedTitle]:t=>new qc(t,this.yn,this.bn,new Hc,this.ci.isMobile)},this.dV=t=>i=>{const e=this.cV[t];if(e)return e(i)}}createComponent(t,i){return this.dV(t)(i)||super.createComponent(t,i)}}const Wc=[{browserType:e.lI.Chrome,browserVersion:"67",versionOperator:"<"},{browserType:e.lI.Safari,browserVersion:"10",versionOperator:"<"},{browserType:e.lI.Firefox,browserVersion:"63",versionOperator:"<"},{browserType:e.lI.Edge,browserVersion:"18",versionOperator:"<="}];var Gc=r(3731);function Xc(t){try{return"customElements"in t?t.CustomElementRegistry.toString().indexOf("[native code]")>-1?"native_method":"polyfill":"not_supported"}catch(t){return"error"}}function Qc(t){try{return t.document.head.attachShadow?t.document.head.attachShadow.toString().indexOf("[native code]")>-1?"native_method":"polyfill":t.document.head.createShadowRoot?"deprecated_method":"not_supported"}catch(t){return"error"}}var Jc=r(5919),Yc=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class Kc{constructor(t,i,e,s,n){this.tH=t,this.Ci=i,this.bw=e,this.ra=s,this.Yg=n,this.WN=[],this.eH=new J.x,this.sa=()=>{var t;this.RW.updateWidth(this.tH.clientWidth),null===(t=this.OW)||void 0===t||t.onResize(this.RW.currentBreakpointClass)},this.pV=t=>{var i;null===(i=this.OW)||void 0===i||i.onViewabilityCallback(t)},this.RW=new Ai(this.tH,ta,P.Nq)}get onUIEvent(){return this.eH.asObservable()}destroy(){(0,it.i)(this.WN),this.DW()}enterFullscreen(){var t;null===(t=this.OW)||void 0===t||t.expand()}exitFullscreen(){var t;null===(t=this.OW)||void 0===t||t.collapse()}toggleCaptionButton(t){}togglePlaylistControls(t){var i;null===(i=this.OW)||void 0===i||i.togglePlaylistControls(t)}toggleExpandButton(t){}changeState(t){var i;const e={[jt.Ez.PlayingState]:Jc.x.Playing,[jt.Ez.PausedState]:Jc.x.Paused,[jt.Ez.StoppedState]:Jc.x.Stopped,[jt.Ez.BufferingState]:Jc.x.Buffering,[jt.Ez.PrerollState]:Jc.x.Preroll,[jt.Ez.PostrollState]:Jc.x.Postroll}[t];(0,s.$K)(e)&&(null===(i=this.OW)||void 0===i||i.changeState(e))}updateUpNextBox(t,i){var e;null===(e=this.OW)||void 0===e||e.updateUpNextBox(t,i)}updateActiveCue(t){var i;null===(i=this.OW)||void 0===i||i.updateActiveCaptions(t)}updateDefaultCaption(t){var i;null===(i=this.OW)||void 0===i||i.updateDefaultCaption(t)}updateCurrentVideo(t){var i;null===(i=this.OW)||void 0===i||i.updateCurrentVideoMetadata(t)}updateCurrentTime(t,i){var e;null===(e=this.OW)||void 0===e||e.updateDuration(t,i)}updateBufferedState(t){var i;null===(i=this.OW)||void 0===i||i.updateBufferedState(t)}updateVolume(t){var i;null===(i=this.OW)||void 0===i||i.changeVolume(100*t)}updateQuality(t,i){var e;null===(e=this.OW)||void 0===e||e.setCurrentQuality(t,i)}updateFloatingState(t){var i;null===(i=this.OW)||void 0===i||i.updateFloatingState(t)}updateCloseButtonMode(t,i){var e;null===(e=this.OW)||void 0===e||e.updateCloseButtonMode(t,i)}start(){return Yc(this,void 0,void 0,(function*(){try{const t=yield this.VW();this.OW=new t(this.tH,this.bw,this.ra),this.OW.render()}catch(i){let e="";if((0,s.VZ)(i)){const{message:t,stack:s}=i;e=JSON.stringify({message:t,stack:s})}const n=JSON.stringify(Object.assign(Object.assign({},{canUseCustomElements:Xc(t=this.Ci),canUseShadowDOM:Qc(t)}),{error:e}));throw new Error("LIT_UI_ERROR:"+n)}var t;this.FW(),this.RW.updateWidth(this.tH.clientWidth),this.OW.onResize(this.RW.currentBreakpointClass),this.NW()}))}FW(){this.OW&&(this.WN.push(this.OW.onPause().subscribe((()=>this.zu({type:Aa.Pause}))),this.OW.onPlay().subscribe((()=>this.zu({type:Aa.Play}))),this.OW.onNext().subscribe((()=>this.zu({type:Ka.Next}))),this.OW.onPrev().subscribe((()=>this.zu({type:Ka.Prev}))),this.OW.onOverlayClick().subscribe((()=>this.zu({type:ka.t.OverlayClick}))),this.OW.onVolumeChange().subscribe((t=>{(0,s.$K)(t.isUiTriggered)&&!t.isUiTriggered||this.zu({type:Aa.Volume,payload:{volume:t.payload,isFinal:t.isFinal}})})),this.OW.onFullScreenToggle().subscribe((t=>t.isUiTriggered&&this.zu({type:t.payload?ka.t.Expand:ka.t.Collapse}))),this.OW.onSeek().subscribe((t=>{this.zu({type:Aa.Seek,payload:{seekedTime:t}})})),this.OW.onSeekingStart().subscribe((()=>{this.zu({type:Aa.SeekingStart})})),this.OW.onSeekingEnd().subscribe((()=>{this.zu({type:Aa.SeekingStop})})),this.OW.onCaptionUpdate().subscribe((t=>{if(!(0,s.$K)(t.isUiTriggered)||t.isUiTriggered){if(t.payload)return void this.eH.next({type:Aa.CaptionOn,payload:{captionUrl:t.payload}});this.eH.next({type:Aa.CaptionOff})}})),this.OW.onCloseClick().subscribe((()=>{this.zu({type:ka.t.Close})})),this.OW.onQualityChange().subscribe((t=>{this.eH.next({type:Aa.Quality,payload:{quality:{height:t,quality:t>0?jt.ZH.Strict:jt.ZH.Auto}}})}))),this.RW.updateWidth(this.tH.clientWidth),this.OW.onResize(this.RW.currentBreakpointClass),this.NW())}jW(t){const i=rc.get(t.type);i&&(t.type!==Aa.Volume||t.payload.isFinal)&&this.$W({type:ka.t.GeneralUserInteraction,payload:{type:i}})}VW(){var t;return Yc(this,void 0,void 0,(function*(){if(yield(0,h.Up)((()=>Yc(this,void 0,void 0,(function*(){return Mn(this.UW(),window,this.Ci)})))),!(null===(t=this.Ci.cnxAsyncChunks)||void 0===t?void 0:t.litUI))throw new Error("lit bundle not found");return this.Ci.cnxAsyncChunks.litUI}))}UW(){return function({browserType:t,browserVersion:i}){const e=d(null!=f?f:l.connatix);try{if((0,a.Ph)("cnxForceLitES5",(0,h.pE)(window).topFrame.location.href))return`${e}lit.ui.es5.js`}catch(t){}if(!(0,s.$K)(i))return`${e}lit.ui.es5.js`;const n=Wc.find((i=>i.browserType===t));return n&&(0,s.QM)(n.browserVersion)&&!(0,Gc.qu)(i,n.browserVersion,n.versionOperator)?`${e}lit.ui.js`:`${e}lit.ui.es5.js`}(this.bw.browserInfo)}NW(){this.ra.on(this.tH,this.sa),this.Yg.on(this.tH,this.pV,{threshold:.01})}DW(){var t;null===(t=this.ra)||void 0===t||t.off(this.tH,this.sa),this.Yg.off(this.tH,this.pV)}zu(t){this.jW(t),this.eH.next(t)}$W(t){this.eH.next(t)}}var Zc=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};const td=168,id=91;class ed extends Ma{constructor(){super(...arguments),this.qW=!1,this.hn=v.ProtoQuartilesEnum.Start,this.HW=new Map}start(t){const i=Object.create(null,{start:{get:()=>super.start}});return Zc(this,void 0,void 0,(function*(){yield i.start.call(this,t),this.a$.next(!0),this.Sj.start();try{yield this.v$()}catch(t){}finally{this.I$()}this.c$.next(!0)}))}getCurrentVideoIndex(){return this.wj.currentVideoIndex}getPlaylistLength(){return this.wj.length}O$(t){return Zc(this,void 0,void 0,(function*(){t=Object.assign(Object.assign({},t),{isInApp:(0,s.QM)(this.vI.config.bundleID)});const i=`template_${this.vI.config.appId}`;if(t.enableNewUI){const e={browserInfo:this.vI.config.browser,isMobile:this.vI.config.isMobile,isAlwaysDisplayControls:this.Ab.alwaysDisplayControls,templateUniqueID:i,isFullScreenButtonEnabled:t.uiComponentsVisibility.expandButton,isPinned:t.isPinned,closeButtonMode:oc.get(t.closeButtonMode),floatingCloseButtonMode:oc.get(t.floatingCloseButtonMode),iconsColor:this.Ab.iconsColor,tooltipTextColor:this.Ab.tooltipTextColor,tooltipBackgroundColor:this.Ab.tooltipBackgroundColor,accentColor:this.Ab.accentColor,hasUpNext:t.hasUpNext,logoUrl:this.Ab.logoUrl,symbolUrl:this.Ab.symbolUrl,logoPosition:hc[this.Ab.logoPosition],isAutoplay:this.Ab.playbackMode===v.ProtoPlayerPlaybackModeEnum.Autoplay,isScrollToPlay:this.Ab.playbackMode===v.ProtoPlayerPlaybackModeEnum.ScrollToPlay,isClickToPlay:this.Ab.playbackMode===v.ProtoPlayerPlaybackModeEnum.ClickToPlay,playlistLength:this.wj.length,shouldShowCaptions:this.Ab.closedCaptionDefault};this.m$=new Kc(this.fI,this.Ab.global,e,this.vI.services.ResizeObserver,this.vI.services.ViewabilityService)}else this.m$=new lc(this.vI.services.GlobalDomUtilsService,this.vI.services.InteractionService,this.vI.services.ResizeObserver,this.fI,i);t.isPinned&&this.zW(t),this.S$(),yield this.m$.start(t,!1,this.r$)}))}zW(t){t=Object.assign(Object.assign({},t),{isInApp:(0,s.QM)(this.vI.config.bundleID)});const i=new Nc;this.g$=new $c(this,this.fI.parentElement,this.vI.services.GlobalDomUtilsService,i.template,new zc(this.vI.services.GlobalDomUtilsService,this.vI.services.InteractionService,this.fI,t))}floatingChanged(t){var i;null===(i=this.g$)||void 0===i||i.destroy(),t&&(this.zW(super.L$()),this.wj.getCurrentVideoData((t=>{var i;null===(i=this.g$)||void 0===i||i.updateCurrentVideo(t)})))}updateFloatingState(t){var i,e;this.m$&&(null===(e=(i=this.m$).updateFloatingState)||void 0===e||e.call(i,t))}updateCloseButtonMode(t,i){var e,s;null===(s=null===(e=this.m$)||void 0===e?void 0:e.updateCloseButtonMode)||void 0===s||s.call(e,t,oc.get(i))}onEnterCuePoint(){this.p$.onEnterCuePoint()}onExitCuePoint(){this.p$.onExitCuePoint()}V$(t){this.Ab.upNextMode===Gh.ProtoPlayerUpNextMode.Next&&this.Sj.duration-this.Sj.currentTime<=6&&!this.qW&&(this.qW=!0,this.wj.getVideoData(this.wj.nextVideoIndex,(t=>{const i=t.getThumbnailUrl(td,id);this.m$.updateUpNextBox(i,t.title)}))),this.WW(this.Sj.currentTime,this.Sj.duration)}x$(){this.qW=!1,this.hn=v.ProtoQuartilesEnum.Start}w$(){switch(this.Ab.upNextMode){case Gh.ProtoPlayerUpNextMode.Loop:this.GW();break;case Gh.ProtoPlayerUpNextMode.Next:this.wj.isNextVideoCurrentVideo()?this.GW():(this.u$.streamFormat=Pa.Autochain,this.XW());break;case Gh.ProtoPlayerUpNextMode.Stop:this.p$.stop(),this.m$.changeState(jt.Ez.ReplayState)}}I$(){const{preRollBreak:t,postRollBreak:i}=this.Ab,e=(0,s.r)(t),n=(0,s.r)(i);this.p$=new _a(this,this.wj,this.Sj,e,n,this.vI.config.os.os===zt.M.Ios,this.Ab.videoPosition),super.I$()}S$(){super.S$(),this.subscriptions.push(this.m$.onUIEvent.subscribe((t=>{switch(t.type){case Ka.Next:this.mediator.publish(this,w.Uh.UserInteraction,{payload:{playback:!0,clickedNext:!0}}),this.XW(),this.u$.streamFormat=Pa.UserInitiated;break;case Ka.Replay:this.mediator.publish(this,w.Uh.UserInteraction,{payload:{playback:!0}}),this.GW();break;case Ka.Prev:this.mediator.publish(this,w.Uh.UserInteraction,{payload:{playback:!0,clickedPrev:!0}}),this.QW()}})))}R$(t,i){this.Sj=new tc(this,this.vI,this.vI.services.GlobalDomUtilsService,this.fI,this.vI.services.ResizeObserver,i,t,!0,this.Ab.videoPosition,this.B$)}JW(t,i){return i&&t?Math.floor((0,$i.dQ)(0,i,0,4,t)):v.ProtoQuartilesEnum.Start}WW(t,i){const e=this.JW(t,i);e>v.ProtoQuartilesEnum.Start&&e!==this.hn&&(this.HW.get(e)||(this.mediator.publish(this,va.ContentQuartiles,{payload:e}),this.HW.set(e,!0)),this.hn=e)}QW(){this.setVideo(this.wj.prevVideoIndex,!0),this.u$.streamFormat=Pa.UserInitiated,this.Sj.forceCurrentTime(0)}XW(){this.setVideo(this.wj.nextVideoIndex),this.Sj.forceCurrentTime(0)}Kj(t=!0){var i;super.Kj(t),t&&(null===(i=this.m$)||void 0===i||i.updateBufferedState(null)),this.HW.clear()}GW(){this.p$.replay(),this.Kj(!1)}}var sd,nd=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class rd extends Ia{constructor(){super(...arguments),this.YW=!0,this.KW={[ii.d.nextVideo]:()=>{this.Td.mediaClick.next({type:Yt.$.NextClick}),this.nextVideo()},[ii.d.previousVideo]:()=>{this.Td.mediaClick.next({type:Yt.$.PreviousClick}),this.prevVideo()},[ii.d.toggleFullscreen]:()=>{this.toggleFullscreen()?this.Td.mediaClick.next({type:Yt.$.FullScreenClick}):this.Td.mediaClick.next({type:Yt.$.ExitFullScreenClick})},[ii.d.toggleCaptions]:()=>{this.Td.mediaClick.next({type:Yt.$.SubtitleClick}),this.toggleCaptions()},[ii.d.togglePlay]:()=>{this.togglePlay()?this.Td.mediaClick.next({type:Yt.$.PlayClick}):this.Td.mediaClick.next({type:Yt.$.PauseClick})},[ii.d.toggleMute]:()=>{0===this.Wf.volume?this.Td.mediaClick.next({type:Yt.$.UnmuteClick}):this.Td.mediaClick.next({type:Yt.$.MuteClick}),this.toggleMute()},[ii.d.increaseVolume]:()=>{this.Td.mediaClick.next({type:Yt.$.VolumeClick}),this.increaseVolume(.1)},[ii.d.decreaseVolume]:()=>{this.Td.mediaClick.next({type:Yt.$.VolumeClick}),this.decreaseVolume(.1)},[ii.d.seekForward]:()=>this.seekForward(5),[ii.d.seekBackward]:()=>this.seekBackward(5),[ii.d.seek0Percent]:()=>this.seekPercentage(0),[ii.d.seek10Percent]:()=>this.seekPercentage(10),[ii.d.seek20Percent]:()=>this.seekPercentage(20),[ii.d.seek30Percent]:()=>this.seekPercentage(30),[ii.d.seek40Percent]:()=>this.seekPercentage(40),[ii.d.seek50Percent]:()=>this.seekPercentage(50),[ii.d.seek60Percent]:()=>this.seekPercentage(60),[ii.d.seek70Percent]:()=>this.seekPercentage(70),[ii.d.seek80Percent]:()=>this.seekPercentage(80),[ii.d.seek90Percent]:()=>this.seekPercentage(90)}}start(){const t=Object.create(null,{start:{get:()=>super.start}});return nd(this,void 0,void 0,(function*(){try{t.start.call(this),this.ZW()}catch(t){(0,p.n)({message:"VideoExperience_start",exception:t.message,callStack:t.stack,level:p.D.CRITICAL})}}))}nextVideo(){let t=this.Wf.getCurrentVideoIndex();t+1>=this.Wf.getPlaylistLength()?this.changeVideo(0,!1):this.changeVideo(++t,!1)}prevVideo(){let t=this.Wf.getCurrentVideoIndex();0!==t?this.changeVideo(--t,!1):this.changeVideo(this.Wf.getPlaylistLength()-1,!1)}getVideoIndex(){return this.Wf.getCurrentVideoIndex()}setVideoIndex(t){const i=this.Wf.getPlaylistLength();if(t>=i||!(0,s.r)(t+1))throw new Error(`ELEMENTS JS API: Index [${t}] is out of bounds! Please provide a valid video index [0 - ${i}]!`);this.changeVideo(t)}destroy(){this.unsubscribeAll(this.tG),super.destroy()}setVideoPosition(t){if(t>this.duration||!(0,s.r)(t)&&0!==t)throw new Error(`ELEMENTS JS API: The timestamp provided [${t}] is out of bounds! Please provide a valid timestamp [0 - ${this.duration}]!`);this.currentTime=t}seekForward(t){this.currentTime+t>this.duration?this.currentTime=this.duration:this.currentTime+=t}seekBackward(t){this.currentTime-t<0?this.currentTime=0:this.currentTime-=t}seekPercentage(t){this.currentTime=this.duration/100*t}Ub(t){const i=this.KW[t];i&&i()}Pb(){this.ob.isInAdPod()?this._b((()=>{super.Pb(),this.hb.onAdFinished(this.adHandler.linearInImpression,Bi.LINEAR,this.ob.isInAdPod());this.Wf.show(!0)})):(super.Pb(),this.Wf.show(this.YW),this.YW=!0)}_p(){super._p(),this.iG&&this.eG(),this.tG&&this.tG.onResize(this.$experienceContainer.clientWidth)}generateHTML(){super.generateHTML(),this.Ab.gallery&&this.sG()}ZN(){this.Wf=new ed(this,this.Ab,this.app,this.$playerContainer,this.breakPointsHandler.currentBreakpointClass)}xb(){super.xb(),this.subscribe(wi,this.hb,(()=>{this.Wf.onEnterCuePoint()})),this.subscribe(Si,this.hb,(()=>{this.Wf.onExitCuePoint()}))}eG(){this.Ab.gallery.orientation===Gh.ProtoGalleryOrientationEnum.Landscape&&(0,u.T7)(this.iG,{height:`${this.$playerWrapper.clientHeight}px`})}sG(){this.iG=this.app.services.GlobalDomUtilsService.createElementByString('<cnx class="cnx-g-container" role="group" aria-label="Video playlist"></cnx>'),this.$experienceContainer.appendChild(this.iG);const t=this.Ab.gallery.orientation===Gh.ProtoGalleryOrientationEnum.Landscape?P.s6.GalleryLandscape:P.s6.GalleryPortrait;(0,u.cn)(this.$experienceContainer,t)}ZW(){this.Ab.gallery&&(this.tG=new Fc(this,this.app.services.ResizeObserver,this.app.services.GlobalDomUtilsService,this.app.services.InteractionService,this.iG,this.app.config.device,this.Ab.gallery.style,this.Ab.gallery.orientation,this.Ab.playlist),this.subscribe(va.ChangeVideo,this.tG,(({payload:{videoIndex:t}})=>{this.YW=!this.Wf.isHidden,this.ob.endPod(),this.changeVideo(t,!0),this.Wf.getVideoData(t,(t=>{this.mediator.publish(this,ma.GalleryCardClicked,{payload:this.lj(t)}),this.Td.mediaClick.next({type:Yt.$.GalleryClick})})),this.Gy()})),this.subscribe(jt.T$.NewVideo,this.Wf,(({payload:{videoIndex:t}})=>{this.tG.setCurrentIndex(t)})),this.subscribe(va.VideoQueued,this.Wf,(({payload:{videoIndex:t}})=>{this.tG.setCurrentIndex(t)})),this.tG.start(),this.tG.onResize(this.$experienceContainer.clientWidth))}}class od extends Nt{constructor(){super(...arguments),this.qf="cnx-el"}createExperience(t,i){t.isInStreamType()?(this.experience=new rd(this,i,this.app.services.UrlSuffixerService,this.Vc,this.zc,this.Td,this.Dc,this.Ef),this.experienceApi=new Sc(this.experience),this.Dc.playerType=b.e.Video):t.isLiveType()?(this.experience=new mc(this,i,this.app.services.UrlSuffixerService,this.Vc,this.zc,this.Td,this.Dc,this.Ef),this.experienceApi=new Sc(this.experience),this.Dc.playerType=b.e.Live):(this.experience=new wc(this,i,this.app.services.UrlSuffixerService,this.Vc,this.zc,this.Td,this.Dc,this.Ef),this.experienceApi=new yc(this.experience),this.Dc.playerType=b.e.Outstream)}isSupportedBreakpoint(t){return!0}subscribeToEvents(){super.subscribeToEvents(),this.playerModel.html&&this.subscribe(va.MediaMetaUpdate,this.experience,(({payload:{title:t,description:i}})=>{this.updateMacroContent(this.macroElements.title,t),this.updateMacroContent(this.macroElements.description,i)}))}getApiMethods(){return this.experienceApi.getApiMethods()}}class hd{constructor(){this.nG=[],this.rG=0,this.hG=!1,this.aG=t=>{this.nG.forEach((i=>{t&&t!==i.element||this.cG(i,this.rG)}))}}dG(t){let i=this.nG.find((i=>i.element===t));return i||(i={element:t,list:[],cachedPercentInView:0},this.nG.push(i)),i.list}cG(t,i){t.list.forEach((t=>{!t.callbackSent&&t.threshold<=i?(t.callbackSent=!0,t.timeout=(0,h.ld)(t.callback,t.callbackDelay,!0,this.hG)):t.callbackSent&&t.threshold>i&&(t.callbackSent=!1,clearTimeout(t.timeout),t.timeout=(0,h.ld)(t.callback,0,!1,this.hG))}))}on(t,i,e){this.dG(t).push({threshold:e.threshold,callbackSent:!1,callbackDelay:e.callbackDelay,timeout:null,callback:i}),this.aG()}off(t,i){const e=this.nG.find((i=>i.element===t));if(e){for(let t=e.list.length;t--;)e.list[t].callback===i&&e.list.splice(t,1);0===e.list.length&&this.nG.splice(this.nG.indexOf(e))}}check(t={threshold:.1}){return this.rG>=t.threshold}triggerRecheck(t){this.aG(t)}lG(t){this.hG=t}setViewableThreshold(t){this.rG=t,this.triggerRecheck()}subscribe(t,i){}destroy(){for(let t=this.nG.length;t--;){const i=this.nG[t];for(let t=i.list.length;t--;)clearTimeout(i.list[t].timeout),this.off(i.element,i.list[t].callback)}}}!function(t){t[t.none=0]="none",t[t.friendly=1]="friendly",t[t.safe=2]="safe"}(sd||(sd={}));class ad{constructor(t,i,e,s=!1){this.Ci=t,this.uG=i,this.Dc=e,this.nG=[],this.pG=sd.none,this.fG={intersectionObserver:!1,fallbackImplementation:!1},this.gG=null,this.vG=[0,.01,.1,.2,.5],this.yG=250,this.bG=t=>{this.Dc.isPageInFocus=t,this.aG()},this.aG=()=>{this.nG.forEach((t=>{const i=this.rG(t.element);this.onViewHandle(t,i)}))},this.IG=()=>{null===this.gG&&(this.gG=setTimeout((()=>{this.aG(),clearTimeout(this.gG),this.gG=null}),this.yG))},this.wG=(0,h.pE)(this.Ci).topFrame,this.SG(s),this.PG(),this.AG()}AG(){this.uG.on(this.bG),this.Dc.isPageInFocus=this.uG.isDocumentVisible()}SG(t){this.Ci.IntersectionObserver&&!t?this.fG.intersectionObserver=!0:this.fG.fallbackImplementation=!0,this.Ci.self!==this.Ci.top?(this._G=this.xG(this.Ci),null!==this._G?this.pG=sd.friendly:this.pG=sd.safe):this._G=this.Ci.frameElement}xG(t){let i;try{if(i=t.parent,i===this.Ci.top)return t.frameElement}catch(t){return null}return this.xG(i)}PG(){this.fG.intersectionObserver?this.TG=new this.Ci.IntersectionObserver(this.onObserverEnter.bind(this),{root:null,rootMargin:"0px",threshold:this.vG}):(this.wG.addEventListener("scroll",this.IG),this.wG.addEventListener("load",this.aG),this.wG.addEventListener("resize",this.aG))}kG(t){return this.nG.find((i=>i.element===t))}rG(t){if(this.pG===sd.safe){const i=this.kG(t);return i?i.cachedPercentInView:0}let i=1;const e=t.getBoundingClientRect(),s={bottomRatio:e.bottom/e.height,topRatio:(this.Ci.top.innerHeight-e.top)/e.height,leftRatio:(this.Ci.top.innerWidth-e.left)/e.width,rightRatio:e.right/e.width};return Object.keys(s).forEach((t=>{s[t]<=0&&(i=0),s[t]>0&&s[t]<1&&(i*=s[t])})),i}onObserverEnter(t){t.forEach((t=>{this.nG.filter((i=>i.element===t.target)).forEach((i=>{this.onViewHandle(i,t.intersectionRatio)}))}))}onViewHandle(t,i){t.cachedPercentInView=i;const e=this.Dc.isPageInFocus;t.list.forEach((t=>{!t.callbackSent&&t.threshold<=i&&e?(t.callbackSent=!0,t.timeout=(0,h.ld)(t.callback,t.callbackDelay,!0)):t.callbackSent&&(t.threshold>i||!e)&&(t.callbackSent=!1,clearTimeout(t.timeout),t.timeout=(0,h.ld)(t.callback,0,!1))}))}on(t,i,e={}){let s=!1;if(this.fG.fallbackImplementation)if(this.pG===sd.friendly&&t.ownerDocument.defaultView!==this.Ci.top)t=this._G;else if(this.pG===sd.safe)return void(0,h.ld)(i,0,!1);let n=this.nG.find((i=>i.element===t));n?s=!0:(n={element:t,list:[],cachedPercentInView:0},this.nG.push(n)),n.list.push({threshold:e.threshold,callbackSent:!1,callbackDelay:e.callbackDelay,timeout:null,callback:i}),this.fG.intersectionObserver?(s&&this.TG.unobserve(t),this.TG.observe(t)):this.fG.fallbackImplementation&&this.aG()}off(t,i){const e=this.nG.find((i=>i.element===t));if(e){let s=e.list.length;for(;s;)s--,e.list[s].callback===i&&e.list.splice(s,1);0===e.list.length&&(this.TG&&this.TG.unobserve(t),this.nG.splice(this.nG.indexOf(e),1))}}check(t={threshold:.1}){if(!t.element)return!1;let i=t.element;this.pG===sd.friendly&&(i=this._G);const e=this.Dc.isPageInFocus;return this.rG(i)>=t.threshold&&e}triggerRecheck(t){this.fG.fallbackImplementation&&t&&this.nG.forEach((i=>{if(i.element===t){const t=this.rG(i.element);this.onViewHandle(i,t)}}))}setViewableThreshold(t){}subscribe(t,i){}destroy(){this.wG.removeEventListener("scroll",this.IG),this.wG.removeEventListener("load",this.aG),this.wG.removeEventListener("resize",this.aG);[].slice.call(this.nG).forEach((t=>{[].slice.call(t.list).forEach((i=>{this.off(t.element,i.callback),this.Ci.clearTimeout(i.timeout)}))})),this.uG.off(this.bG),clearTimeout(this.gG)}}class cd{constructor(t=0){this.CG=t,this.EG=16,this.MG=9}getHeightByRatio(t){return Math.round(t/this.EG*this.MG)+this.CG}setExtraHeight(t){this.CG=t}}const dd=[v.ProtoDeviceType.Smartphone];function ld(t,i){return function(t){return dd.indexOf(t)>-1}(i)&&(t===v.ProtoPositionMode.PinnedBottom||t===v.ProtoPositionMode.PinnedTop)}class ud{constructor(t,i,e={},n){this.extraHeight=i,this.device=n,this.cachedExtraHeight=0,this.isPinnedFloating=ld(t.floatingScrollPosition,n),this.floatingMode=(0,s.$K)(e.mode)?e.mode:t.floatingMode,(0,S.BZ)(e.devices)?this.floatingDeviceMode=e.devices:this.floatingDeviceMode=(0,S.BZ)(t.floatingDeviceMode)?t.floatingDeviceMode:[v.ProtoDeviceType.Desktop],(0,s.$K)(e.closeButton)?this.floatingCloseButtonMode=e.closeButton:(0,s.$K)(t.floatingCloseButtonMode)?this.floatingCloseButtonMode=t.floatingCloseButtonMode:this.floatingCloseButtonMode=v.ProtoPlayerCloseButtonMode.OnHover,this.floatingPosition=(0,s.$K)(e.fixedPosition)?e.fixedPosition:t.floatingFixedPosition,this.floatingScrollPosition=(0,s.$K)(e.scrollPosition)?e.scrollPosition:t.floatingScrollPosition,this.floatingWidth=(0,s.$K)(e.floatingWidth)?e.floatingWidth:t.floatingWidth||400,this.floatingGutterX=(0,s.$K)(e.floatingGutterX)?e.floatingGutterX:t.floatingGutterX,this.floatingGutterY=(0,s.$K)(e.floatingGutterY)?e.floatingGutterY:t.floatingGutterY,this.hasFloatingTransition=(0,s.$K)(e.hasFloatingTransition)?e.hasFloatingTransition:t.hasFloatingTransition,this.pageElement=(0,s.$K)(e.floatingPageElement)?e.floatingPageElement:t.floatingPageElement,this.appendLocation=(0,s.$K)(e.floatingAppendLocation)?e.floatingAppendLocation:t.floatingAppendLocation,this.floatingYAxisPadding=(0,s.$K)(e.floatingYAxisPadding)?e.floatingYAxisPadding:t.floatingYAxisPadding,this.setScrollPosition(this.floatingScrollPosition),(this.isPositionedPinnedBottom||this.isPositionedPinnedTop)&&(this.cachedExtraHeight=i,i=0),this.BG=new cd(i),this.OG=this.floatingMode!==v.ProtoPlayerFloatingMode.Off}setScrollPosition(t){this.floatingScrollPosition=t,this.isPinnedFloating=ld(t,this.device),this.DG=t===v.ProtoPositionMode.BottomLeft||t===v.ProtoPositionMode.TopLeft,this.VG=t===v.ProtoPositionMode.BottomRight||t===v.ProtoPositionMode.TopRight,this.FG=t===v.ProtoPositionMode.TopLeft||t===v.ProtoPositionMode.TopRight,this.NG=t===v.ProtoPositionMode.BottomRight||t===v.ProtoPositionMode.BottomLeft,this.$G=t===v.ProtoPositionMode.PinnedTop,this.UG=t===v.ProtoPositionMode.PinnedBottom}get isPositionedLeft(){return this.DG}get isPinnedPlayerFloating(){return this.isPinnedFloating}get isPositionedRight(){return this.VG}get isPositionedTop(){return this.FG}get isPositionedBottom(){return this.NG}get isPositionedPinnedTop(){return this.$G}get isPositionedPinnedBottom(){return this.UG}get hasFloatingCapability(){return this.OG}set isPositionedLeft(t){this.DG=t}set isPinnedPlayerFloating(t){this.isPinnedFloating=t}set isPositionedRight(t){this.VG=t}set isPositionedBottom(t){this.NG=t}set isPositionedTop(t){this.FG=t}set isPositionedPinnedTop(t){this.$G=t}set isPositionedPinnedBottom(t){this.UG=t}set width(t){this.floatingWidth=t}set gutterX(t){this.floatingGutterX=t}set gutterY(t){this.floatingGutterY=t}get width(){return this.floatingWidth}getHeight(t){return`${this.BG.getHeightByRatio(t)}px`}setExtraHeight(t){this.BG.setExtraHeight(t)}getFloatingSettings(){return{scrollPosition:this.floatingScrollPosition,floatingGutterX:this.floatingGutterX,floatingGutterY:this.floatingGutterY,floatingWidth:this.floatingWidth}}}var pd=r(6027);const fd=["8d9f31fa-3d9f-4881-acb0-be61b22c308c","1bde0dfc-ccf4-491a-b8e7-d374d8aa834d","964374ff-abea-408f-ad8c-56dab4dd09dc","e2b6a2d9-9002-4e50-9295-23f548839e94","6bf24d17-9835-495f-b418-7267e4654524","6ae90847-bf58-4c3c-ba38-b38d515f9e00","44905f01-174e-4a9d-95dc-638a80ab513e","c2eecca1-0ace-4777-9c46-ca44e6c16218","d9d0e8b1-4021-427d-b8b1-9917e4b193ad","efea731a-0a08-4260-9217-2658e693aff9","f3a07a0d-9f63-4529-80cc-554e7c5244c9","8165ca68-a89e-405f-b3ab-1faa3985cf71","a78e3915-0fc3-4823-866b-0436b2adf8fa","fb989292-e75a-4ece-b596-189245b3227c","236b9724-47b0-4dc7-9ed6-446294b2ed4a","5f3abd4e-fbb4-4b0f-9258-b90740fac819","5328235f-9716-4c81-9073-7cb713e3d9ff","c9d1bce6-44d7-4c30-80d1-9b70d6038cde","f412904c-ad7e-48e7-bc5d-9e69187c9bb5","9949914f-a41e-4928-90b1-34715b0b6cac","ad75e1b4-dfb0-4ade-be4f-2fcc3047c370","cd3a0179-bab3-4fb2-9bf7-a49c2ca3f9f6","88f1ab64-1df5-4d49-9451-19f65f6126a5","c4eb1199-cdf0-4a28-afb0-e7c5fb629e5e","a2859a75-4272-4146-b149-3d0acc19764e","6cc513ee-c58c-4a85-af23-82075a8ce1ca","22e7bc20-b8ed-4ece-b2cf-5ebb9bdfe96c","ec7241e8-c6b8-493a-84d0-8566fa5edf94","aa0d9500-be44-4de4-a1b2-cbadae87eb17","d04150a7-7314-42a9-94a6-0db2beab90dc","9a78696e-7141-4ff3-96d3-0cd7a410961f","771ac607-a9e9-49a9-8326-d9aa9452f6bf","ca6810c0-854e-4de3-a8ca-99a238d99c14","fa2af9a7-9b1e-45cf-80a7-7d04a79cef6d","220d954e-01b2-4d45-a22e-83d169715b8f","32573572-b864-473a-8965-00b118ae1c65","0ff42799-7daf-4fc4-8e06-d31ab857da88","5b5213e5-5630-481e-86fd-3c2317a48621","19094074-5528-412c-a8e4-4af0096d4efe","37ae61ec-e782-43c1-bcdd-ef5452b7e4b0","c6881d74-879f-42ce-9cfa-1df3c396df6d","db55fa41-71d4-4157-a4e2-126e7476ca79","9d0165a8-b040-42d2-94b0-f967fc3aaaae","9a8f7a2f-a84d-4631-9e46-fa0e97729c25","b19062e1-6e95-4dc4-a797-c2e130adbe80","e03797d5-4818-417a-b3d1-7ea3466b7eb3","fdb3acf0-9026-4ff7-86e7-308eae78a6c3","bc93e252-fac0-4f55-b254-c7547fca6d08","bd526af5-bc04-490b-8ed6-42b576c947a7","7317b65f-dd2a-4211-8ea1-16a05e4fa524","6821b1e4-092d-481b-a86d-efc4908eb223","52d94522-9581-4b7d-aa9b-70d282981677","5646da0c-10cc-4694-95d0-d6ac982e03f6","282b1ed6-0881-4912-bec8-1d9a86a56aa0","28bdbcf1-3694-4408-aacf-28ec7e135c2b","51289577-3bac-4e72-a443-9cb25de8b4b6","04fb251c-43dd-4587-a4e6-05235c26be6b","003f8b06-519a-44be-98d5-8e0600dc5874","da490d28-3f90-4206-98bd-2e4782e1263e","adc00530-320d-42e3-a7ca-f42e11dff182","d5e0ba20-b410-49fd-907f-db6fd299dce1","8d5624c4-d1cd-498c-8397-121dce9e1770","9b77c9f1-a765-445c-aa41-c7be8bd4f47c","c96983e7-de60-4124-bb8c-896c5343e34d","fbe3b439-f67e-4fb1-9c06-e7b30a2310fc","fdc1bffb-eed3-4eaf-ac5c-07a87dbb68a0","a97697ee-6b28-4020-8a7c-c8a8de7fbb76","8fbe3953-b436-49c5-a6aa-831d5f5d2a32","ff5ad3fd-bdd5-40d2-b9f3-690133ff23a5","b9d7c6bc-c18c-4786-a561-1fe846f8b17d","d8fdbfb0-4d80-4983-bc86-4c7e0ed191f5","913d0b07-08f0-47b8-96ef-112e2a9a1869","cb9f241e-e384-4b17-97e3-680950e084bc","df45ca5f-eff3-42ce-80ad-540c5f34bc6f","bbd45d33-362f-4fde-89e6-47d4d8bc8524","3ac3c265-1174-45b8-9bd7-c17e7be2adf7","07861d14-f54b-4ce1-8472-7584ac22f2f3","2447e7d2-51ab-4c7b-b06c-f3c2e171639f","1e1d0274-7cc8-4616-b188-9f870b54d8b3","1ca848db-2436-4156-a152-da533cd2a63d","19dd93e0-66da-4a83-b075-61fe08a8e507","11b23f3d-742c-443a-a0c0-06461531315f","587f169e-25ca-496f-adf8-38d9201b9ebc","95c2cf81-fadb-469e-b4f9-882fe6b0bdd7","8eeab91a-662a-46de-a56c-a317f7e939c0","b6b64ebf-3553-43fd-8001-44079b240233","d0d22aed-7a0f-4543-8d64-acafab9f3b5a","bc9a48ea-ab31-46b8-9bc8-25886953776b","d14ea633-6776-4582-827b-b074fc32b0c9","787dd229-9ce3-4ef9-93f8-ca2d3b585974","aec58545-fa50-49c9-a7ab-b77ba172f6f3","afaa167a-c1ff-4abf-b36b-e0e8cb052817","da0ee58c-14e4-4f6c-9105-4309e906d0a2","ce4624ad-5adc-4934-ba1b-3e833b22ab0f","06d21b00-b24c-44d7-9a0a-3992d1361181","19803f55-856e-48a3-bc28-3d07ef9d3d39","1fe96055-e20f-46e3-afe8-a2a0905822ff","9c6baa06-2bc0-47f6-9f16-eddba1fef9bf","53eb0be7-ea1a-47ae-aab6-8657d4f4b447","c49f94e9-045e-4364-a59b-a62d0cf22316","d9cae709-60c7-4450-9074-0549c0f30f4e","e47c5407-4a34-471e-b6fc-66423ca5eae1","ca866151-ce5c-4b54-a059-d36be90ff421","be78cb40-5d0d-4c1d-b1fe-6508a9ff1942","43b90e6e-940f-4bf1-8772-81caf1142f6a","61db0b36-2ff9-4d36-b370-0fe98e425656","04355f10-4b0f-4499-bf37-b3a8ce317b5f","3c1a78aa-2861-4485-9017-e39b5337c94f","5db65e80-25ae-4bf1-9417-38860a8133d0","3d2bdb1b-070f-4cd5-94c5-2f8d33aec732","815ca8ab-a39f-453e-ad84-441a9822cf49","d8add381-8aa3-4806-87ad-59e0bd5bddea","33c6193e-99db-4490-8e29-e4cd01ff0a9c","0b0af83d-99cb-4470-8dfe-39e66d7d83ca","7985c512-85bf-4dc4-88e1-a785d82bb971","ba4405dc-61a1-4426-b27e-ff98f5b685a7","a866d0c4-a446-4af7-8d45-f5d3990154f6","9e5150a8-81da-4f7f-a280-85c66fce57b5","9ae79f69-e08f-4e69-9d95-faa80c786bda","48dd1597-4688-4b24-8400-740eded438af","39bd2c4d-bb9c-4d8e-83b6-9d33016e3709","2828d05e-5050-45ae-a883-404444e80996","01874d00-dd82-4cd6-be54-cc2b6bf72b8f","6b7b2a9a-ee65-48fb-aab7-9ca4e00785f7","7d6f41ed-308f-484e-879d-980fe12334b5","14232d41-52b5-4778-8c1b-02c7bf4fa14e","ad0a9cc6-0ad5-4a8e-93c1-f4d163b41397","be7b144f-8fab-46b6-b9f1-fa6b53799afe","e49c37f1-685d-4601-ac0a-54edcccba2bb","e8b8b7f0-b875-4a8b-9e74-891df946450b","feda3daa-774f-4eaa-88b4-3d1084e63695","eb21cee1-0ffa-4c62-be46-042b3157768f","da54a40c-23aa-4854-ae3a-1b5e85770f8d","d43f1740-e3ed-44af-b6e4-ecdb606bdd25","15920368-8fa4-49b9-a896-84b4875f8ecd","4d2e7439-2ea4-4376-8b0b-34b1ae1ba89d","145dcc1e-43d3-4847-94d3-facad324bb13","3d412551-7b13-4826-8f53-5bb6f02f5955","3f9629e4-25d4-4e0d-8173-ff2fc2a4ea55","54704091-08d7-4272-8a85-dc8bb47d2c7e","9b9d75d4-f35b-46b8-903f-db4b21f8865e","e05f1337-8585-4619-b355-d105005b032e","702baa8a-c5e9-4d05-9f96-adcd363fb214","6cd25651-9944-45f2-831c-ccddc40f0d0e","6ce3a726-1a41-4151-a178-5b778ffaefc3","5c045ada-0454-4ba3-b919-05b22120f506","0cd0e2e7-2915-479e-9cb2-4c9df2ed08d8","629805fe-09c4-4c00-a034-83027b907ac9","43b180a0-3942-4776-b128-705cf6e7c3ee","c51a230a-192e-4ef3-bd62-795c5df0cdde","b364fbc3-6ad0-413b-850b-c537c3d1f046","c0557107-1673-4563-ad6e-6367ef7ade29","d7842b4a-8061-4334-aee6-5bd7eb0c90de","4375e905-b076-4c00-80e9-bae95feb1a0e","08298ede-80fc-4e38-a3ff-ec50af4f44aa","2d884066-814a-4014-9a86-3acf8f6235b2","2baa2007-e180-4602-a140-8db4f08dccbc","ae65a433-2886-4a16-9558-4c5d990807c8","73abbad9-0dbc-4f93-ba23-9162d6bd1658","89e6ce19-d6ab-4dcc-bfc1-a6e0911dffb3","cc19dbfa-0e46-4e82-ac0d-045e6fd525a7","94fa8c8d-f0d6-41be-baf5-8d47a72f0e83","999988ac-4ddf-461f-8ca8-7118b41c5d20","923970f0-872e-46e8-9141-6263ad49fe80","3acab97c-7130-4a22-b9ce-a12e3c2902a8","5e43a078-c3b7-43fc-a408-cfe3f8175014","24ae775e-1007-44a1-9cd2-73674908585a","2d5dfd8c-4ab1-4799-9054-fe68a1917928","0eee105d-700b-4c5f-885e-817315133439","13361c32-72b6-4cae-9612-50874d29d4b5","509ed06f-ce6e-4a8b-9e3d-48498fff7738","03d21666-b00a-49f3-8b61-be768fc56456","691e3b63-0242-4c25-ab23-badc89e71673","f59e0953-6ac3-4219-94d3-866ea29a19b6","d3539689-76c0-4bd0-8af7-d9c45e505c54","42002489-35d3-4a75-971d-9932126ff752","48751401-e2da-4eb6-80bc-360b138737b0","06c1f579-5243-471b-af0b-ede543d524aa","337ec1c5-1b4f-4c2f-ac77-54bba7ff3c02","6046c81b-8bba-47d1-b299-4e6c302288ae","62749d7f-e3c1-44a0-a7b1-788f3b8b90ae","7c8ed035-b483-41ba-9a7b-b0d9615f360c","a0417b2d-d481-45e7-ac84-b81b55d490e1","3c3a526c-ca60-41db-8ded-4bd41f38548f","a20326de-1073-4b43-9ffb-ee6a87a940cf","79626cf5-dad8-4d36-98b9-6817fe411e5f","04d6a543-1f80-4519-8518-d636c82986cc"];class md{constructor(t,i,e,n,r,o,a,c,d,l,u,f,m=0){if(this.global=t,this.targetContainer=i,this.qG=e,this.Ym=n,this.secondLevelDomain=r,this.apiConfig=o,this.isServerlessMode=a,this.supplyChainSettings=c,this.isSeoTraffic=d,this.Jv=l,this.lineItemAbTestInformation=u,this.videoPosition=f,this.sharingDestinations=[],this.disableAdvertising=!1,this.adBreaks=[],this.disableClickUrl=!1,this.moatTrackingEnabled=!1,this.pauseAdWhenFinished=!1,this.loopAdWhenFinished=!1,this.adsMustBeSkippableIfLongerThan=js.f3,this.HG(),(0,s.QM)(e.initializationSettingsJson))try{const t=JSON.parse(e.initializationSettingsJson);this.apiConfig=Co(this.apiConfig,t)}catch(t){(0,p.n)({message:"invalid_init_json",exception:t.message,callStack:t.callStack,level:p.D.CRITICAL})}if((this.apiConfig.playerMode===ni.Buzzfeed||this.apiConfig.settings.pauseAdWhenFinished)&&(this.pauseAdWhenFinished=!0),this.queryJsTargeting=this.apiConfig.settings.queryJsTargeting||{},this.zG(this.qG.lineItems),this.soundMode=(0,s.$K)(this.apiConfig.settings.defaultSoundMode)?this.apiConfig.settings.defaultSoundMode:e.soundMode,this.playbackMode=(0,s.$K)(this.apiConfig.settings.playbackMode)?this.apiConfig.settings.playbackMode:e.playbackMode,this.playbackMode===v.ProtoPlayerPlaybackModeEnum.ClickToPlay||this.soundMode===v.ProtoPlayerSoundMode.Mute||(0,h.we)()||(this.soundMode=v.ProtoPlayerSoundMode.Mute),this.html=e.html,this.css=e.css,this.floatingSettings=new ud(e,m,this.apiConfig.settings.customization.floating,this.Ym),e.logoResource||(0,s.QM)(this.apiConfig.settings.customization.logoUrl)){let t=`${_t.n.endPoints.base.image}${e.playerId}/${e.logoResource}`;t=this.Jv.appendParamsToUrl(t),this.logoUrl=(0,s.QM)(this.apiConfig.settings.customization.logoUrl)?this.apiConfig.settings.customization.logoUrl:t}const g=e.amazonTamSlotId;(0,s.QM)(g)&&(this.amazonTamSlotId=g),(0,s.$K)(this.apiConfig.settings.advertising.macros)&&(this.externalMacros=this.apiConfig.settings.advertising.macros),(0,s.$K)(this.apiConfig.settings.disableAdvertising)&&(this.disableAdvertising=this.apiConfig.settings.disableAdvertising),this.midRollNumber=(0,s.$K)(this.apiConfig.settings.advertising.maxNumberOfMidRolls)?this.apiConfig.settings.advertising.maxNumberOfMidRolls:e.midRollNumber,this.adViewabilityPolicy=e.adViewabilityPolicy,this.preRollBreak=((0,s.$K)(this.apiConfig.settings.advertising.preRollBreak)?(0,Pr.qe)(this.apiConfig.settings.advertising.preRollBreak,500):e.preRollBreak)*Lt.s_,this.postRollBreak=((0,s.$K)(this.apiConfig.settings.advertising.postRollBreak)?(0,Pr.qe)(this.apiConfig.settings.advertising.postRollBreak,500):e.postRollBreak)*Lt.s_,this.playerId=e.playerId,this.floatingSettings.floatingMode===v.ProtoPlayerFloatingMode.Always?this.closeButtonMode=this.floatingSettings.floatingCloseButtonMode:this.closeButtonMode=(0,s.$K)(this.apiConfig.settings.customization.closeButtonMode)?this.apiConfig.settings.customization.closeButtonMode:e.closeButtonMode,this.isCloseButton=!!this.closeButtonMode||!!this.floatingSettings.floatingCloseButtonMode,this.uiComponentsVisibility={casting:!1,expandButton:(0,s.$K)(this.apiConfig.settings.customization.showExpandButton)?this.apiConfig.settings.customization.showExpandButton:e.expandButton},this.sharingDestinations=void 0,this.adPlaybackMode=e.adPlaybackMode,(0,s.$K)(this.apiConfig.settings.disableClickUrl)&&(this.disableClickUrl=this.apiConfig.settings.disableClickUrl);const{skippability:y,skipAdAfter:b,skipMin:I}=o.settings.advertising.skipAdSettings||{};this.skipAdAfter=(0,s.$K)(b)?b:e.skipAdAfter,this.skippability=(0,s.$K)(y)?y:e.skippability,this.skipMin=(0,s.$K)(I)?I:e.skipMin;const{disableTracking:w}=o.settings._connatixInternals;(w||a||this.isSeoTraffic)&&(this.disableTracking=!0),this.sessionId=this.qG.sessionId}setPreRollBreak(t){this.preRollBreak=this.WG(this.preRollBreak,t)}setPostRollBreak(t){this.postRollBreak=this.WG(this.postRollBreak,t)}HG(){if(4===pd.e.clientAb0)this.GG();else if(5===pd.e.clientAb0){const t=this.qG.lineItems.length;this.XG(),t===this.qG.lineItems.length&&this.GG()}}GG(){this.qG.lineItems=this.qG.lineItems.filter((t=>"50b75cc2-f1ae-45c1-ac8c-19cf61de0133"!==t.advertiserLineItemId))}XG(){this.qG.lineItems=this.qG.lineItems.filter((t=>!fd.includes(t.advertiserLineItemId)))}WG(t,i){const e=(0,Pr.w4)(i);return null===e?t:e}QG(t=!1){this.JG(),this.YG();let i=[...this.KG(),...this.ZG()];i=this.tX(i),i=this.iX(i,t),t&&(i=this.eX(i));const e=(0,s.$K)(this.apiConfig.settings.rendering.scrollHijackingProtection)?this.apiConfig.settings.rendering.scrollHijackingProtection:this.qG.scrollHijackingProtection;this.lineItemSettings={lineItems:i,disableScrollHijackEnforcement:e},this.sX(this.lineItemSettings)}nX(t){return t*Lt.s_}rX(t,i){i.adTag=(0,s.$K)(t.url)?t.url:i.adTag,i.requestCap=(0,s.$K)(t.contentRequestCap)?t.contentRequestCap:i.requestCap,i.impressionCap=(0,s.$K)(t.contentImpressionCap)?t.contentImpressionCap:i.impressionCap,i.viewability=(0,s.$K)(t.viewability)?t.viewability:i.viewability,i.sound=(0,s.$K)(t.sound)?t.sound:i.sound,i.ignoreFilledRequests=(0,s.$K)(t.ignoreFilledRequests)?t.ignoreFilledRequests:i.ignoreFilledRequests,i.prebidJsBidParamsJSONString=(0,s.$K)(t.prebidJsBidParamsJSONString)?t.prebidJsBidParamsJSONString:i.prebidJsBidParamsJSONString,i.headerBidderTimeout=(0,s.$K)(t.headerBidderTimeout)?t.headerBidderTimeout:i.headerBidderTimeout,i.resetRequestsCapTime=(0,s.$K)(t.resetRequestsCapTime)?t.resetRequestsCapTime:i.resetRequestsCapTime,i.resetImpressionsCapTime=(0,s.$K)(t.resetImpressionsCapTime)?t.resetImpressionsCapTime:i.resetImpressionsCapTime,i.resetCapType=(0,s.$K)(t.resetCapType)?t.resetCapType:i.resetCapType,i.timeBetweenRequests=(0,s.$K)(t.timeBetweenRequests)?t.timeBetweenRequests:i.timeBetweenRequests,i.skipMode=(0,s.$K)(t.skipMode)?t.skipMode:i.skipMode,i.floorPrice=(0,s.$K)(t.floorPrice)?t.floorPrice:i.floorPrice,i.adBreakSettings=(0,s.$K)(t.adBreakSettings)?t.adBreakSettings:i.adBreakSettings,i.pauseAdOutOfView=(0,s.$K)(t.pauseAdOutOfView)?t.pauseAdOutOfView:i.pauseAdOutOfView,i.nonlinearLineItemSettings=(0,s.$K)(t.nonlinearLineItemSettings)?this.oX(t.nonlinearLineItemSettings):i.nonlinearLineItemSettings,i.adType=(0,s.$K)(t.nonlinearLineItemSettings)?v.ProtoAdType.Nonlinear:i.adType}oX(t){const i={nonLinearRequestType:t.nonLinearRequestType?t.nonLinearRequestType:v.ProtoNonlinearRequestType.Banner,nonLinearAdTimeSeconds:t.nonLinearAdTimeSeconds?t.nonLinearAdTimeSeconds:15};return i.nonLinearAdTimeSeconds<15&&(i.nonLinearAdTimeSeconds=15),i.nonLinearAdTimeSeconds>180&&(i.nonLinearAdTimeSeconds=180),i}JG(){this.hX(this.apiConfig.settings.advertising.preRollBreak,v.ProtoAdBreakTypeEnum.PreRoll),this.hX(this.apiConfig.settings.advertising.postRollBreak,v.ProtoAdBreakTypeEnum.PostRoll),this.hX(this.apiConfig.settings.advertising.maxNumberOfMidRolls,v.ProtoAdBreakTypeEnum.MidRoll)}hX(t,i){const e=this.aX(this.apiConfig.settings.advertising.adBreaks,i),n=this.aX(this.qG.adBreaks,i),r={maxAdPodDuration:0,maxAdSlotDuration:0,numberOfAdSlots:1,types:[i]};e?this.adBreaks.push(e):!(0,s.$K)(t)||e||n?!e&&n&&this.adBreaks.push(n):this.adBreaks.push(r)}aX(t,i){if(!t)return;let e;return t.forEach((t=>{t.types.includes(i)&&(e=Object.assign({},t),e.types=[i])})),e}eX(t){return Di(t,Bi.LINEAR)}iX(t,i=!1){const{adBreaks:e}=this;let s=[];(0,S.BZ)(e)||i||t.forEach((t=>{const i=t.adBreakSettings.adBreakTargeting.find((t=>t.adRollType===v.ProtoAdBreakTypeEnum.MidRoll));i||t.adType===v.ProtoAdType.Nonlinear||s.push(t)}));const n=[];return e.forEach((t=>{t.types.forEach((i=>n.push(Object.assign(Object.assign({},t),{types:[i]}))))})),n.forEach((t=>{s=this.removeCompatibleLineItems(t,s)})),t.filter((t=>!s.includes(t)))}removeCompatibleLineItems(t,i){const e=t.types[0],s=t.numberOfAdSlots>1?v.ProtoLineItemAdBreakTypeEnum.AdPod:v.ProtoLineItemAdBreakTypeEnum.SingleAd;return i.filter((t=>!t.adBreakSettings.adBreakTargeting.some((t=>t.adRollType===e&&(t.adBreakTypeEnum===v.ProtoLineItemAdBreakTypeEnum.All||t.adBreakTypeEnum===s)))))}zG(t){t.forEach((t=>{t.adBreakSettings||this.cX(t),this.dX(t)}))}cX(t){t.adBreakSettings={adBreakTargeting:[{adRollType:v.ProtoAdBreakTypeEnum.PreRoll,adBreakTypeEnum:v.ProtoLineItemAdBreakTypeEnum.All},{adRollType:v.ProtoAdBreakTypeEnum.MidRoll,adBreakTypeEnum:v.ProtoLineItemAdBreakTypeEnum.All},{adRollType:v.ProtoAdBreakTypeEnum.PostRoll,adBreakTypeEnum:v.ProtoLineItemAdBreakTypeEnum.All}]}}dX(t){0===t.requestCap&&(t.requestCap=20)}YG(){this.adBreaks.forEach((t=>{t.maxAdSlotDuration=this.nX(t.maxAdSlotDuration),t.maxAdPodDuration=this.nX(t.maxAdPodDuration),t.numberOfAdSlots<=1?t.maxAdPodDuration=0:t.maxAdSlotDuration>t.maxAdPodDuration&&(t.maxAdSlotDuration=t.maxAdPodDuration)}))}lX(t,i){const e=Object.assign({},i);return this.rX(t,e),(0,s.$K)(t.externalMediaFile)&&(e.externalMediaFile=t.externalMediaFile),(0,s.$K)(t.externalHlsFile)&&(e.externalHlsFile=t.externalHlsFile),e.customCpm=t.cpm,e}KG(){const t=[];if(!(0,S.BZ)(this.apiConfig.settings.advertising.lineItems))return[];const i=this.qG.lineItems.filter((t=>t.creativeType===v.ProtoCreativeTypeEnum.External));return this.apiConfig.settings.advertising.lineItems.forEach((e=>{if(this.dX(e),this.isServerlessMode){const i=this.uX(),s=this.lX(e,i);t.push(s)}else i.forEach((i=>{if(e.id===i.advertiserLineItemId){const s=this.lX(e,i);t.push(s)}}))})),t}ZG(){return!0===this.apiConfig.settings.advertising.blockConnatixDemand?[]:this.qG.lineItems.filter((t=>t.creativeType!==v.ProtoCreativeTypeEnum.External))}tX(t){return t.forEach((t=>{t.creativeType===v.ProtoCreativeTypeEnum.External&&((0,s.QM)(t.prebidJsBidParamsJSONString)?t.creativeType=v.ProtoCreativeTypeEnum.HeaderBidder:t.externalMediaFile||t.externalHlsFile?t.creativeType=v.ProtoCreativeTypeEnum.MediaFile:t.creativeType=v.ProtoCreativeTypeEnum.ThirdParty,t.isExternal=!0)})),t}uX(){return v.ProtoLineItem.toObject(v.ProtoLineItem.fromObject({}),{defaults:!0,arrays:!0,objects:!0})}sX(t){this.moatTrackingEnabled=t.lineItems.some((t=>t.moatTrackingEnabled))}}var gd=r(1992),vd=function(t,i,e,s){return new(e||(e=Promise))((function(n,r){function o(t){try{a(s.next(t))}catch(t){r(t)}}function h(t){try{a(s.throw(t))}catch(t){r(t)}}function a(t){var i;t.done?n(t.value):(i=t.value,i instanceof e?i:new e((function(t){t(i)}))).then(o,h)}a((s=s.apply(t,i||[])).next())}))};class yd{constructor(t,i,e){this.pX=!1,this.fX=[],this.mX=[],this.vX=!1,this.Xv=t,this.yX=i,this.Cu=e}getMetadata(t,i){this.pX?t&&t(this.IX):this.wX(t,i)}setAvailableQualities(t){this.IX.setAvailableQualities(t)}wX(t,i){t&&this.fX.push(t),i&&this.mX.push(i),this.vX||(this.vX=!0,this.SX().then((t=>vd(this,void 0,void 0,(function*(){const i=yield Ho.k.loadInsights({id:this.Xv,versionId:this.yX,insightsInputType:gd.i.Video});this.vX=!1,this.pX=!0,this.IX=this.PX(t,i),this.fX.forEach((t=>t(this.IX))),this.fX=[]})))).catch((()=>{this.vX=!1,this.mX.forEach((t=>t()))})))}}class bd{constructor(t,i){this._X=[],this.Xv=t,this.Ov=i.altText,this.TX=i.outputUrl,this.kX=i.thumbnailUrl,this.CX=i.name,this.EX=i.startDate}getSources(t,i){return null}setAvailableQualities(t){this._X=t}get hlsFilePath(){return this.TX}getAvailableQualities(){return this._X}getClosestSourceQuality(t){let i;const e=(0,$i.DE)(t,this._X.map((t=>t.videoHeight)));return this._X.forEach((t=>{t.videoHeight===e&&(i=t)})),i}getHlsSource(){return this.TX}getThumbnailUrl(t,i){return this.kX}get id(){return this.Xv}get altText(){return(0,s.$K)(this.Ov)?this.Ov:""}get title(){return this.CX}get liveStreamStartDate(){return this.EX}getDefaultSubtitle(){return null}get isExternalSource(){return!1}}var Id=r(6224);class wd extends yd{constructor(){super(...arguments),this.MX=new Id.t(v.ProtoLiveMediaMetadataResponse,"LiveVideoSourceWrapper")}SX(){const t=`${_t.n.endPoints.base.metadata}${this.Xv}/${this.yX}_liveStream.bin`;return this.MX.fetchMetadata(t)}PX(t){return new bd(this.Xv,t)}}class Sd{constructor(t,i=[]){this.LX=i,this._X=[],this.Xv=t.id,this.BX=t.title,this.Ov=t.altText,this.RX=t.description,this.OX=t.imageUrl,this.rU=t.sources,this.Kx=t.clickUrl||"",this.TX=t.hlsFilePath||"",this.DX=t.liveStreamFilePath||"",this.VX=t.liveStramStartDate||"",this.Mu=t.disableAdvertising,this.rU&&this.rU.forEach((t=>{this._X.push({label:jt.se[t.quality],videoHeight:t.quality,isHD:t.quality>=jt.gQ})}))}get id(){return this.Xv}get title(){return this.BX}get altText(){return(0,s.$K)(this.Ov)?this.Ov:""}get description(){return this.RX}get clickUrl(){return this.Kx}getSources(t){return[{src:this.rU.find((i=>i.quality===this.getClosestSourceQuality(t).videoHeight)).file,type:new Ba(jt.L5.H264).type}]}getHlsSource(){return this.DX||this.TX}getAvailableQualities(){return this._X.sort(((t,i)=>t.videoHeight-i.videoHeight))}getThumbnailUrl(){return this.OX}get hlsFilePath(){return this.DX||this.TX}getClosestSourceQuality(t){let i;const e=(0,$i.DE)(t,this._X.map((t=>t.videoHeight)));return this._X.forEach((t=>{t.videoHeight===e&&(i=t)})),i}setAvailableQualities(t){this._X=t}get liveStreamStartDate(){return this.VX}getDefaultSubtitle(){const t=this.LX.find((t=>t.title.indexOf("English")>-1));return t||this.LX[0]}get subtitles(){return(0,S.BZ)(this.LX)?this.LX:void 0}get disableAdvertising(){return this.Mu}get isExternalSource(){return!0}}class Pd{constructor(t){this.NX=t,this.pX=!1,this.vX=!1,this.jX=(0,s.QM)(t.hlsFilePath),this.jX||(this.pX=!0,this.IX=new Sd(t))}getMetadata(t){t&&(this.pX?t(this.IX):this.$X(this.NX.hlsFilePath,t))}setAvailableQualities(t){this.IX.setAvailableQualities(t)}$X(t,i){if(!this.vX){this.vX=!0;try{Bt.n.fetchXhttpRequest({requestUrl:t,requestType:"GET"}).then((t=>{const e=Va(t);this.pX=!0;const s=this.UX(e);this.IX=new Sd(this.NX,s),i(this.IX)}))}catch(t){this.pX=!0,this.IX=new Sd(this.NX),i(this.IX)}}}UX(t){var i;if(!t||!(0,s.Xz)(null===(i=t.mediaGroups)||void 0===i?void 0:i.SUBTITLES))return;const e=Object.values(t.mediaGroups.SUBTITLES);let n=[];for(let t=0;t<e.length;t++){const i=e[t],s=Object.keys(i);for(let t=0;t<s.length;t++){const e=s[t];n.push({title:e,code:i[e].language||"en",file:i[e].uri,type:v.ProtoTrackType.ManualSubtitle,isHLSTrack:!0})}}return n=n.filter((t=>(0,a.jv)(t.file))),(0,S.BZ)(n)?n:void 0}}class Ad{constructor(t,i,e,s,n,r,o){var h;if(this.Xv=t,this.Jv=e,this.yX=s,this.Mu=n,this.qX=r,this.Cu=o,this.HX=[],this.LX=[],this.zX=[],this.WX=[],this.GX={insights:[]},this._X=[],this.BX=i.title,this.Ov=i.altText,this.RX=i.description,this.Kx=i.clickUrl,this.HX=i.keywordList,this.XX=i.languageId,this.LX=i.trackList,this.QX=i.cuePoints,this.JX=i.multimediaId,this.YX=i.publishDate,this.KX=i.endDate,this.ZX=i.contentStudio,this.LX&&this.LX.length>0){this.LX.forEach((t=>{t.file=this.Jv.appendParamsToUrl(this.tQ(_t.n.endPoints.base.video,t.file))}));const t=this.LX.findIndex((t=>t.title.indexOf("English")>-1));if(t>-1){const i=this.LX.splice(t,1);this.LX.unshift(...i)}}this.kX=i.thumbnail,this.iQ=i.duration,this.WX=i.customFields,this.TX=i.hlsFilePath,this.eQ=i.sourceItemId,this.GX.insights=null===(h=this.qX)||void 0===h?void 0:h.insights,(0,S.BZ)(i.renditionList)&&(this.zX=this.sQ(i.renditionList),this.nQ(i.renditionList))}sQ(t){return t.sort(((t,i)=>t.height-i.height))}setAvailableQualities(t){this._X=t}nQ(t){(0,S.qy)("height",t).forEach(((t,i)=>{this._X.push({videoHeight:t.height,label:`${t.height}p`,isHD:t.height>=jt.gQ})}))}rQ(t,i){return this.zX.find((e=>e.codec===t&&e.height===i))}tQ(t,i,e=!1){let n=`${t}${this.Xv}/`;return(0,s.QM)(this.Cu)&&(n+=`${this.Cu}/`),e&&(0,s.QM)(this.JX)&&(n+=`mmid-${this.JX}/`),n+=i,n}oQ(t,i){const e=(0,$i.DE)(t,this._X.map((t=>t.videoHeight)));return this.rQ(i,e)}get hlsFilePath(){return this.TX}getAvailableQualities(){return this._X}getClosestSourceQuality(t){let i;const e=(0,$i.DE)(t,this._X.map((t=>t.videoHeight)));return this._X.forEach((t=>{t.videoHeight===e&&(i=t)})),i}getSources(t,i){const e=[];return i.forEach((i=>{const s=this.oQ(t,i.id);(0,S.BZ)(e)||s&&e.push({src:this.Jv.appendParamsToUrl(this.tQ(_t.n.endPoints.base.video,s.file,true)),type:i.type})})),e}getHlsSource(){return this.tQ(_t.n.endPoints.base.video,this.TX,!0)}getThumbnailUrl(t,i){const e=this.tQ(_t.n.endPoints.base.image,this.kX);return Vh.getSmartCroppedImageUrl(e,t,i,this.Jv)}getDefaultSubtitle(){const t=this.LX.find((t=>t.title.indexOf("English")>-1));return t||this.LX[0]}get title(){return this.BX}get altText(){return(0,s.$K)(this.Ov)?this.Ov:""}get description(){return this.RX}get clickUrl(){return this.Kx}get keywords(){return this.HX}get languageId(){return this.XX}get sourceItemId(){return this.eQ}get subtitles(){return(0,S.BZ)(this.LX)?this.LX:void 0}get spriteSheet(){return this.cQ}get duration(){return this.iQ}get id(){return this.Xv}get customFields(){return this.WX}get insights(){return this.GX}get cuePoints(){return this.QX}get publishDate(){return this.YX}get endDate(){return this.KX}get contentStudio(){return this.ZX}get sentimentAnalysis(){var t;return null===(t=this.qX)||void 0===t?void 0:t.sentimentAnalysis}get disableAdvertising(){return this.Mu}get isExternalSource(){return!1}get multimediaId(){return this.JX}get revisionNumber(){return this.yX}get contentVersionId(){return this.Cu}}class _d extends yd{constructor(t,i,e,s,n,r){super(t,i,s),this.Jv=e,this.lQ=n,this.Mu=r,this.MX=new Id.t(v.ProtoMediaMetadataResponse,"VideoSourceWrapper")}SX(){let t=`${_t.n.endPoints.base.metadata}${this.Xv}/`;return(0,s.QM)(this.Cu)?t+=`${this.Cu}/${this.yX}_media.bin`:t+=`${this.yX}_media.bin`,this.MX.fetchMetadata(this.Jv.appendParamsToUrl(t))}PX(t,i){let e={};const s=this.uQ(t.customMetadata);if(this.lQ){const{title:t,description:i,clickUrl:s,keywordList:n,customFields:r}=this.lQ;e={title:t,description:i,clickUrl:s,keywordList:n,customFields:r}}const n=Object.assign(Object.assign({customFields:s},t),e);return new Ad(this.Xv,n,this.Jv,this.yX,this.Mu,i,this.Cu)}uQ(t){let i={};if(!(0,s.QM)(t))return[];try{i=JSON.parse(t)}catch(i){return(0,p.n)({message:"VideoSourceMeta_parse_customMetadata",exception:this.Xv,callStack:t,level:p.D.CRITICAL},{shouldSendMaxLog:!1,throttle:10}),[]}const e=[];return Object.keys(i).forEach((t=>{e.push({name:t,value:i[t]})})),e}}class xd{constructor(t,i,e,s){this.Jv=t,this.pQ=i,this.j$=e,this.fQ=s,this.j$.shouldUseMediaIdListAsPlaylist&&(0,S.BZ)(this.j$.mediaIdList)&&(this.pQ=this.pQ.filter((({mediaId:t})=>{var i;return null===(i=this.j$.mediaIdList)||void 0===i?void 0:i.includes(t)}))),this.mQ=this.vQ()}get playlist(){return this.mQ}hasExternalLivestream(){var t;return null===(t=this.fQ)||void 0===t?void 0:t.some((({liveStreamFilePath:t})=>(0,s.QM)(t)))}vQ(){return this.yQ(this.fQ)?this.fQ.map((t=>new Pd(t))):this.pQ.map((t=>{this.bQ(t);const{mediaId:i,revisionNumber:e,mediaContentVersionId:s,shouldDisableAdvertising:n}=t;if(this.j$.playerType===Gh.ProtoElementsTypeEnum.Live)return new wd(i,e,s);const r=this.IQ(i);return new _d(i,e,this.Jv,s,r,n)}))}wQ(){var t;return null===(t=this.fQ)||void 0===t?void 0:t.some((({id:t})=>this.pQ.find((({mediaId:i})=>i===t))))}IQ(t){var i;return null===(i=this.fQ)||void 0===i?void 0:i.find((({id:i})=>i===t))}yQ(t){return!this.wQ()&&(!(0,s.QM)(this.j$.mediaId)&&!(0,S.BZ)(this.j$.mediaIdList)&&!!(0,S.BZ)(t))}bQ({mediaId:t,revisionNumber:i,insightsRevisionNumber:e}){if(this.j$.playerType===Gh.ProtoElementsTypeEnum.Live)return void Ho.k.markAsUnavailable(t);i===e?Ho.k.loadInsights({id:t,versionId:i,insightsInputType:gd.i.Video}).catch((()=>null)):(Ho.k.markAsUnavailable(t),(0,s.hj)(i)&&(0,s.hj)(e)&&(0,p.n)({message:"ElementsPlayerModel_InsightsRevisionNumberMismatch",exception:`media:${t}, revisionNumber:${i}, insightsRevisionNumber:${e}`,level:p.D.WARN},{shouldSendMaxLog:!1}))}}class Td extends md{constructor(t,i,e,n,r,o,h,a,c,d,l,u,f){var m;super(t,i,e,n,r,o,h,a,u,c,d,l),this.global=t,this.targetContainer=i,this.qG=e,this.SQ=o,this.Jv=c,this.lineItemAbTestInformation=d,this.videoPosition=l,this.playlist=[],this.outstreamAdAsContent=!1,this.enableNewUI=!1,this.alwaysDisplayControls=this.apiConfig.settings.customization.alwaysDisplayControls,e.playerType===Gh.ProtoElementsTypeEnum.Live&&ld(this.floatingSettings.floatingScrollPosition,n)&&(this.floatingSettings.floatingMode=Gh.ProtoPlayerFloatingMode.Off),this.playerSize=this.PQ(),this.midRollOnlyOnLongContent=(0,s.$K)(this.apiConfig.settings.advertising.midRollOnlyOnLongContent)?this.apiConfig.settings.advertising.midRollOnlyOnLongContent:e.midRollOnlyOnLongContent,this.uiComponentsVisibility.muteWatermark=(0,s.$K)(this.apiConfig.settings.customization.showMuteWatermark)?this.apiConfig.settings.customization.showMuteWatermark:e.muteWatermark,this.displayAdCountdown=(0,s.$K)(this.apiConfig.settings.customization.displayAdCountdown)?this.apiConfig.settings.customization.displayAdCountdown:e.displayAdCountdown,this.playlistId=e.playlistId,this.playlistThumbnail=(0,s.QM)(this.apiConfig.settings.customization.playlistThumbnail)?this.apiConfig.settings.customization.playlistThumbnail:e.playlistThumbnail,this.accentColor=(0,s.QM)(this.apiConfig.settings.customization.accentColor)?this.apiConfig.settings.customization.accentColor:e.accentColor,this.iconsColor=(0,s.QM)(this.apiConfig.settings.customization.iconsColor)?this.apiConfig.settings.customization.iconsColor:e.iconsColor,this.tooltipTextColor=(0,s.QM)(this.apiConfig.settings.customization.tooltipTextColor)?this.apiConfig.settings.customization.tooltipTextColor:e.tooltipTextColor,this.tooltipBackgroundColor=(0,s.QM)(this.apiConfig.settings.customization.tooltipBackgroundColor)?this.apiConfig.settings.customization.tooltipBackgroundColor:e.tooltipBackgroundColor,this.prefetchOnPreroll=(0,s.$K)(this.apiConfig.settings.advertising.prefetchOnPreroll)?this.apiConfig.settings.advertising.prefetchOnPreroll:e.prefetchOnPreroll,this.minTimeBeforeFirstAd=((0,s.$K)(this.apiConfig.settings.advertising.timeBeforeFirstAd)?this.apiConfig.settings.advertising.timeBeforeFirstAd:e.minTimeBeforeFirstAd)*Lt.s_,this.timeBetweenAds=((0,s.$K)(this.apiConfig.settings.advertising.timeBetweenAds)?this.apiConfig.settings.advertising.timeBetweenAds:e.timeBetweenAds)*Lt.s_,this.upNextMode=(0,s.$K)(this.apiConfig.settings.nextVideoMode)?this.apiConfig.settings.nextVideoMode:e.upNextMode,this.closedCaptionDefault=(0,s.$K)(this.apiConfig.settings.customization.closedCaptionDefault)?this.apiConfig.settings.customization.closedCaptionDefault:e.closedCaption,this.logoPosition=(0,s.$K)(this.apiConfig.settings.customization.logoPosition)?this.apiConfig.settings.customization.logoPosition:e.logoPosition,(e.symbolResource||(0,s.QM)(this.apiConfig.settings.customization.symbolUrl))&&(this.symbolUrl=(0,s.QM)(this.apiConfig.settings.customization.symbolUrl)?this.apiConfig.settings.customization.symbolUrl:this.Jv.appendParamsToUrl(`${_t.n.endPoints.base.image}${e.playerId}/${e.symbolResource}`)),this.playerType=e.playerType,this.playerType!==Gh.ProtoElementsTypeEnum.OutStream||!this.apiConfig.settings.outstreamAdAsContent&&this.apiConfig.playerMode!==ni.Buzzfeed||(this.outstreamAdAsContent=!0);((0,s.$K)(this.apiConfig.settings.outstreamSettings.endAdBreakPolicy)?this.apiConfig.settings.outstreamSettings.endAdBreakPolicy===Gh.ProtoOutstreamEndAdBreakPolicyEnum.Loop:e.outstreamEndAdBreakPolicy===Gh.ProtoOutstreamEndAdBreakPolicyEnum.Loop)&&(this.outstreamAdAsContent=!0,this.loopAdWhenFinished=!0),(0,s.r)(this.minTimeBeforeFirstAd)||this.apiConfig.playerMode===ni.Buzzfeed||this.outstreamAdAsContent||(this.minTimeBeforeFirstAd=10),(0,s.QM)(this.apiConfig._appSettings.bundleID)&&!this.isInApp()&&(0,p.n)({message:"Elements_PlayerModel_bundle_id_for_non_in_app",level:p.D.CRITICAL}),!(0,s.QM)(this.apiConfig._appSettings.bundleID)&&this.isInApp()&&(0,p.n)({message:"Elements_PlayerModel_bundle_id_missing_for_in_app",level:p.D.CRITICAL}),this.videoQuality=(0,s.$K)(this.qG.videoQuality)?this.qG.videoQuality:Gh.ProtoVideoQuality.Auto;const g=e.playlist.map((({mediaId:t,revisionNumber:i,insightsRevisionNumber:e,mediaContentVersionId:n,disableAdvertising:r})=>(0,s.QM)(t)&&(0,s.hj)(i)?{mediaId:t,revisionNumber:i,insightsRevisionNumber:e,mediaContentVersionId:n,shouldDisableAdvertising:r}:null)).filter((t=>!!t)),y=new xd(this.Jv,g,{playerType:this.playerType,mediaId:this.apiConfig.mediaId,mediaIdList:this.apiConfig.mediaIdList,shouldUseMediaIdListAsPlaylist:this.apiConfig.useMediaIdListAsPlaylist},this.apiConfig.settings.playlist);if(y.hasExternalLivestream()&&(this.playerType=Gh.ProtoElementsTypeEnum.Live,this.playbackMode=v.ProtoPlayerPlaybackModeEnum.ClickToPlay),this.playlist=y.playlist,this.isOutStreamType()){const t=(0,s.$K)(this.apiConfig.settings.outstreamSettings.initialRendering)?this.apiConfig.settings.outstreamSettings.initialRendering:e.outstreamInitialRendering,i=(0,s.QM)(this.apiConfig.settings.outstreamSettings.houseScreenColor)?this.apiConfig.settings.outstreamSettings.houseScreenColor:e.outstreamHouseBackgroundColor,n=((0,s.$K)(this.apiConfig.settings.outstreamSettings.totalAdBreakLength)?this.apiConfig.settings.outstreamSettings.totalAdBreakLength:e.outstreamTotalAdBreakLength)*Lt.s_,r=(0,s.$K)(this.apiConfig.settings.outstreamSettings.endAdBreakPolicy)?this.apiConfig.settings.outstreamSettings.endAdBreakPolicy:e.outstreamEndAdBreakPolicy;this.outstreamSettings={initialRendering:t,houseScreenBackgroundColor:i,totalAdBreakLength:n,endAdBreakPolicy:r}}((0,s.$K)(this.apiConfig.settings.gallery.style)&&this.apiConfig.settings.gallery.style!==Gh.ProtoGalleryStyleMode.None||!(0,s.$K)(this.apiConfig.settings.gallery.style)&&e.galleryStyle!==Gh.ProtoGalleryStyleMode.None)&&this.floatingSettings.floatingMode!==Gh.ProtoPlayerFloatingMode.Always&&(this.gallery={style:(0,s.$K)(this.apiConfig.settings.gallery.style)?this.apiConfig.settings.gallery.style:e.galleryStyle,orientation:this.AQ()}),this.nonlinearPlayerSettings=(null===(m=this.apiConfig.settings.advertising)||void 0===m?void 0:m.nonlinearPlayerSettings)?this._Q(this.apiConfig.settings.advertising.nonlinearPlayerSettings):this.qG.nonlinearPlayerSettings,this.QG(this.isOutStreamType()),this.nonlinearPlayerSettings||(this.lineItemSettings.lineItems=this.lineItemSettings.lineItems.filter((t=>t.adType!==v.ProtoAdType.Nonlinear))),this.enableNewUI=f||this.apiConfig.settings.customization.enableNewUI}_Q(t){const i={numberOfNonlinearAds:t.numberOfNonlinearAds?t.numberOfNonlinearAds:0,timeSecondsBetweenNonlinear:t.timeSecondsBetweenNonlinear?t.timeSecondsBetweenNonlinear:5,timeSecondsBetweenLinearAndNonlinear:t.timeSecondsBetweenLinearAndNonlinear?t.timeSecondsBetweenLinearAndNonlinear:0};i.numberOfNonlinearAds<0&&(i.numberOfNonlinearAds=0),i.numberOfNonlinearAds>10&&(i.numberOfNonlinearAds=10);i.timeSecondsBetweenNonlinear<1&&(i.timeSecondsBetweenNonlinear=1),i.timeSecondsBetweenNonlinear>180&&(i.timeSecondsBetweenNonlinear=180);return i.timeSecondsBetweenLinearAndNonlinear<0&&(i.timeSecondsBetweenLinearAndNonlinear=0),i.timeSecondsBetweenLinearAndNonlinear>180&&(i.timeSecondsBetweenLinearAndNonlinear=180),i}getPlaylistDetails(){const{playlistName:t,playlistDescription:i,playlistThumbnail:e}=this.SQ.settings.customization;return{id:this.qG.playlistId,name:(0,s.QM)(t)?t:this.qG.playlistName,description:(0,s.QM)(i)?i:this.qG.playlistDescription,thumbnail:(0,s.QM)(e)?e:this.qG.playlistThumbnail}}get urlSuffixerService(){return this.Jv}isInApp(){return(0,S.d3)(this.playerType,[Gh.ProtoElementsTypeEnum.InStreamInApp])}isInStreamType(){return(0,S.d3)(this.playerType,[Gh.ProtoElementsTypeEnum.InStream,Gh.ProtoElementsTypeEnum.InStreamInApp])}isOutStreamType(){return(0,S.d3)(this.playerType,[Gh.ProtoElementsTypeEnum.OutStream])}isLiveType(){return(0,S.d3)(this.playerType,[Gh.ProtoElementsTypeEnum.Live])}nX(t){return this.outstreamAdAsContent?0:super.nX(t)}eX(t){return t.filter((t=>this.playerType===Gh.ProtoElementsTypeEnum.InStream||this.playerType===Gh.ProtoElementsTypeEnum.InStreamInApp||t.adType!==v.ProtoAdType.Nonlinear))}PQ(){return{responsive:(0,s.$K)(this.apiConfig.settings.customization.responsive)?this.apiConfig.settings.customization.responsive:this.qG.responsive,ratioWidth:(0,s.$K)(this.apiConfig.settings.customization.ratioWidth)?this.apiConfig.settings.customization.ratioWidth:this.qG.ratioWidth,ratioHeight:(0,s.$K)(this.apiConfig.settings.customization.ratioHeight)?this.apiConfig.settings.customization.ratioHeight:this.qG.ratioHeight,fixedWidth:(0,s.$K)(this.apiConfig.settings.customization.fixedWidth)?this.apiConfig.settings.customization.fixedWidth:this.qG.fixedWidth,fixedHeight:(0,s.$K)(this.apiConfig.settings.customization.fixedHeight)?this.apiConfig.settings.customization.fixedHeight:this.qG.fixedHeight}}AQ(){return this.Ym===v.ProtoDeviceType.Smartphone||this.Ym===v.ProtoDeviceType.Tablet?Gh.ProtoGalleryOrientationEnum.Portrait:this.apiConfig.settings.gallery.orientation?this.apiConfig.settings.gallery.orientation:this.qG.galleryOrientation}}const kd={PlaybackModeEnum:{AutoPlay:v.ProtoPlayerPlaybackModeEnum.Autoplay,ScrollToPlay:v.ProtoPlayerPlaybackModeEnum.ScrollToPlay,ClickToPlay:v.ProtoPlayerPlaybackModeEnum.ClickToPlay},DefaultSoundModeEnum:{On:v.ProtoPlayerSoundMode.On,Off:v.ProtoPlayerSoundMode.Mute,OnHover:v.ProtoPlayerSoundMode.Hover},InsertPositionEnum:{WithinContainer:v.ProtoPlayerInsertMode.WithinContainer,BeforeContainer:v.ProtoPlayerInsertMode.BeforeContainer,AfterContainer:v.ProtoPlayerInsertMode.AfterContainer,ReplaceContainer:v.ProtoPlayerInsertMode.ReplaceContainer,HideContainer:v.ProtoPlayerInsertMode.HideContainer},CloseButtonModeEnum:{Off:v.ProtoPlayerCloseButtonMode.Off,On:v.ProtoPlayerCloseButtonMode.OnHover,OnAfterFirstAd:v.ProtoPlayerCloseButtonMode.OnHoverAfterFirstAd,OnHover:v.ProtoPlayerCloseButtonMode.OnHover,OnHoverAfterFirstAd:v.ProtoPlayerCloseButtonMode.OnHoverAfterFirstAd,AlwaysOn:v.ProtoPlayerCloseButtonMode.AlwaysOn},QualityEnum:jt.se,LineItemExcludedSlotsEnum:{PreRoll:v.ProtoAdSlotsEnum.PreRoll,MidRoll:v.ProtoAdSlotsEnum.MidRoll,PostRoll:v.ProtoAdSlotsEnum.PostRoll},ErrorTypesEnum:{SetupError:M.n9.SetupError,NoPlayer:M.n9.NoPlayer},FloatingModeEnum:{Off:v.ProtoPlayerFloatingMode.Off,OnPageLoad:v.ProtoPlayerFloatingMode.OnPageLoad,AfterInView:v.ProtoPlayerFloatingMode.AfterInView,Always:v.ProtoPlayerFloatingMode.Always},FloatingDevicesEnum:{Desktop:v.ProtoDeviceType.Desktop,Smartphone:v.ProtoDeviceType.Smartphone,Tablet:v.ProtoDeviceType.Tablet,Other:v.ProtoDeviceType.GameConsole},FloatingFixedPositionModeEnum:{Page:v.ProtoFloatingFixedPositionMode.Page,Element:v.ProtoFloatingFixedPositionMode.Element},FloatingScrollPositionEnum:{BottomRight:v.ProtoPositionMode.BottomRight,BottomLeft:v.ProtoPositionMode.BottomLeft,TopRight:v.ProtoPositionMode.TopRight,TopLeft:v.ProtoPositionMode.TopLeft,PinnedTop:v.ProtoPositionMode.PinnedTop,PinnedBottom:v.ProtoPositionMode.PinnedBottom},FloatingStatesEnum:{Float:ti.Float,Embed:ti.Embed},FloatingAppendLocationEnum:{Above:v.ProtoFloatingAppendLocationEnum.Above,Below:v.ProtoFloatingAppendLocationEnum.Below,Within:v.ProtoFloatingAppendLocationEnum.Within},ImplementationTypeEnum:{Amp:v.ProtoImplementationType.Amp,Web:v.ProtoImplementationType.Web},ImpressionTrackerTypeEnum:{Image:v.ProtoTrackerType.Image,Javascript:v.ProtoTrackerType.Javascript,IAS:v.ProtoTrackerType.IAS}},Cd=Object.assign(Object.assign({},kd),{NextVideoModeEnum:{Next:Gh.ProtoPlayerUpNextMode.Next,Loop:Gh.ProtoPlayerUpNextMode.Loop,Stop:Gh.ProtoPlayerUpNextMode.Stop},LogoPositionEnum:{None:Gh.ProtoLogoPositionMode.None,ControlBar:Gh.ProtoLogoPositionMode.ControlBar,BottomRight:Gh.ProtoLogoPositionMode.BottomRight,BottomLeft:Gh.ProtoLogoPositionMode.BottomLeft,TopRight:Gh.ProtoLogoPositionMode.TopRight,TopLeft:Gh.ProtoLogoPositionMode.TopLeft},PlayerTypesEnum:{InStream:Gh.ProtoElementsTypeEnum.InStream,OutStream:Gh.ProtoElementsTypeEnum.OutStream,InStreamInApp:Gh.ProtoElementsTypeEnum.InStream,Live:Gh.ProtoElementsTypeEnum.Live},GalleryStyleModeEnum:{None:Gh.ProtoGalleryStyleMode.None,Detailed:Gh.ProtoGalleryStyleMode.Detailed,Visual:Gh.ProtoGalleryStyleMode.Visual},GalleryOrientationEnum:{Landscape:Gh.ProtoGalleryOrientationEnum.Landscape,Portrait:Gh.ProtoGalleryOrientationEnum.Portrait},InitialRenderingEnum:{ExpandWithAd:Gh.ProtoOutstreamInitialRenderingEnum.ExpandWithAd,FullyRendered:Gh.ProtoOutstreamInitialRenderingEnum.FullyRendered},EndAdBreakPolicyEnum:{Hide:Gh.ProtoOutstreamEndAdBreakPolicyEnum.Hide,HouseScreen:Gh.ProtoOutstreamEndAdBreakPolicyEnum.HouseScreen,Loop:Gh.ProtoOutstreamEndAdBreakPolicyEnum.Loop}});function Ed(t,i){const e=t.toObject({},{defaults:!0,arrays:!0,objects:!0}),s=function(t){return t.toObject({},{defaults:!0,arrays:!0,objects:!0})}(i);return e.players.push(s),e.browser=v.Browser.toObject(v.Browser.fromObject({}),{defaults:!0,arrays:!0,objects:!0}),e.geoLocation=v.GeoLocation.toObject(v.GeoLocation.fromObject({}),{defaults:!0,arrays:!0,objects:!0}),e}class Md extends hd{constructor(t,i,e){super(),this.Ci=t,this.DS=i,this.xQ=[G.backgrounded,G.notFound,G.hidden];try{this.Fu=new B,this.Ec(),this.DS.isOmsdkFullSupport&&this.DS.omidAdSessionStart.subscribe((t=>{this.Ec()}))}catch(t){(0,p.n)({message:"omid_verification_client_error",exception:t.message,callStack:t.callStack,level:e?p.D.CRITICAL:p.D.INFO})}}subscribe(t,i){return this.Fu.on(t,i)}setViewableThreshold(t){}TQ(t){super.setViewableThreshold(t)}Ec(){const t=tt.getVerificationClient(this.Ci);if(!t)throw new Error("omid_verification_client_not_found");if(this.kQ=new t,!this.kQ.isSupported())throw new Error("omid_not_implemented");this.CQ(),this.rl()}CQ(){this.kQ.registerSessionObserver((t=>{t&&t.type===W.sessionError&&(0,p.n)({message:"omid_verification_client_session_error",exception:t.data.message,level:p.D.WARN})}))}MQ(t,i){return!(!this.hG||0!==i)||0!==t.length&&this.xQ.some((i=>t.includes(i)))}rl(){this.kQ.addEventListener(W.geometryChange,(t=>{try{const{percentageInView:i,reasons:e}=t.data.adView;this.lG(this.MQ(e,i));const s=i/100;this.TQ(s),this.Fu.trigger(M.jJ.OmidViewabilityThreshold,s)}catch(t){(0,p.n)({message:"omid_verification_client_geometry_change_error",exception:t.message,callStack:t.callStack,level:p.D.CRITICAL},{throttle:1})}}))}}const Ld=`cnx-player-css-${o.g.version}`;class Bd extends y.a{es(){return{id:Ld,src:_t.n.endPoints.assets.css.elements}}getDelegateHandler(){return{getCurrentPlaybackTime:()=>{if(!this.renderer)return 0;const t=this.renderer.getApiMethods();return t.getPlayerType()===Gh.ProtoElementsTypeEnum.OutStream?0:t.getVideoCurrentPosition()},getCurrentVolume:()=>this.renderer.getApiMethods().getVolume()}}getRendererInstance(t,i,e,s,n,r,o,h,a,c){return new od(this,t,i,e,s,n,r,o,h,a,c)}getViewabilityService(t,i,e){if(this.externalAttributes.settings.useExternalViewabilityService)return new hd;if(this.Qi.isInApp&&!this.Qi.isInAppHybrid){const t=L.h.getSessionChildContainer(e.sessionId).resolve(Ft);return new Md(window,t,this.Qi.isInAppSDK)}return new ad(t.global,i,e,t.isOutStreamType())}getPlayerRequest(t){return(0,h.Up)((()=>Bt.n.sendProtoRequest({protoResponse:Gh.ProtoElementsResponse,protoRequest:Gh.ProtoElementsRequest,requestData:t,endpoint:_t.n.endPoints.api.pls,hasCredentials:!0,queryParams:Object.assign({[Ts.Fk]:o.g.version},ze.f.getCidKeyValueObject()),shouldLogErrors:!0})),this.PLAYER_REQUEST_RETRIES_NUMBER)}getPlayerResponse(t){return new Promise(((i,e)=>{this.getPlayerRequest(t).then((t=>{_t.n.setTier(t.tier),window.parent.connatixDummy&&(0,a.Ph)("connatixDummy",this.pageUrl)&&(t.players[0]=Object.assign(Object.assign({},t.players[0]),window.parent.connatixDummy)),i(t)})).catch((t=>{e(t)}))}))}getPlayerModel(t,i,e,s){const n=new Td(t.insertWindow?t.insertWindow:this.GLOBAL,t.insertContainer,i.players[s],i.browser.device,i.secondLevelDomain,this.externalAttributes,this.isServerlessMode,i.supplyChain,e,i.lineItemAbTestInformation,this.queryParams.cnxVideoPosition,i.isSeoTraffic||this.queryParams.cnxIsSeoTraffic,this.queryParams.cnxEnableNewUi);return 0===n.playlist.length?((0,p.n)({message:"ElementsLoader_no_playlist_items",level:p.D.CRITICAL}),null):n}getApiConfigEnums(){return Cd}getApiConfigEvents(){return ya}getSpecificRequestData(){const t={localTimestamp:(0,Pr.x8)()};(0,S.BZ)(this.externalAttributes.mediaIdList)&&(t.useMediaIdListAsPlaylist=this.externalAttributes.useMediaIdListAsPlaylist),this.queryParams.cnxMediaId?t.forceMediaIdList=[this.queryParams.cnxMediaId]:this.externalAttributes.mediaIdList?t.forceMediaIdList=this.externalAttributes.mediaIdList:this.externalAttributes.mediaId&&(t.forceMediaIdList=[this.externalAttributes.mediaId]),this.queryParams.cnxPlaylistId?t.forcePlaylistId=this.queryParams.cnxPlaylistId:this.externalAttributes.playlistId&&!(0,S.BZ)(this.externalAttributes.settings.playlist)&&(t.forcePlaylistId=this.externalAttributes.playlistId),this.queryParams.cnxDebug&&(t.cnxDebug=this.queryParams.cnxDebug);const i=this.externalAttributes.settings.forceSourceItemId;return(0,s.QM)(i)&&(t.forceSourceItemId=i),t}fe(){super.fe(),this.externalAttributes.settings.gallery={},this.externalAttributes.settings.outstreamSettings={}}LQ(t){t.forEach((t=>{t.ratioWidth=16,t.ratioHeight=9}))}defaultInitFromProto(){const t=Ed(Gh.ProtoElementsResponse,Gh.ProtoElements);return this.LQ(t.players),t}}const Rd={[l.connatix]:"cnx",[l.elements]:"cnxel"},Od=window.parent,Dd=[],Vd=(0,u.bZ)(Ts.ym,window.document.currentScript);ze.f.customerId=Vd,window.addEventListener("unload",(function(t){Dd.forEach((t=>t.destroy()))}));const Fd=(0,h.pE)(Od).topFrame;pd.e.abServiceType=pd.j.ElementsABService;const Nd=(t,i)=>i.AMP_CONTEXT_DATA||t.settings.implementationType===v.ProtoImplementationType.Amp,jd=function(t,i,e,s,r,o){var a,c,d;const l=Nd(t,Od),f=new Bd(e,Od,s,l,r,o);Dd.push(f);const m=function(){const e={id:Ld,src:_t.n.endPoints.assets.css.elements};(0,h.Up)((()=>function(t){return new Promise(((i,e)=>{if((0,u.rI)(t.id,Fd))return i();(0,u.NS)(t,Fd.document.head,Fd,(()=>i()),(t=>e(t)))}))}(e))).catch((t=>{throw(0,p.n)({message:"Prerender_Elements_Loader_add_css_link",exception:t.message,callStack:t.stack,level:p.D.INFO},{throttle:1e3}),t})).then((()=>{try{(0,u.Nb)(Od),f.updateQueryParams(),f.loadScriptTag(t,i)&&f.insertRenderer()}catch(t){(0,p.n)({message:"Prerender_Elements_main_insertRenderer",exception:t.message,callStack:t.stack,level:p.D.INFO},{throttle:1e3})}})).catch((()=>{}))};s.isInApp?(n.CONNECTION_TYPE=null===(a=null==t?void 0:t._appSettings)||void 0===a?void 0:a.connectionType,f.setInappPageUrl(null===(c=null==t?void 0:t._appSettings)||void 0===c?void 0:c.appPageURL),m()):f.findPageUrl(Od,null===(d=null==t?void 0:t.settings)||void 0===d?void 0:d.ampUrl).then((()=>{m(),f.setClientAb1()})).catch((t=>{(0,p.n)({message:"Prerender_Elements_main_init",exception:t.message,callStack:t.stack,level:p.D.INFO},{throttle:1e3}),f.registerApiError()}))};try{!function(){if((0,h.oC)())return;if(!f)return;_t.n.bundleDomain=f;const t=Rd[f],i=f===l.elements;let e=[];Od[t]&&(e=Od[t].cmd),Od[t]=function(){const e={};return e[t]=function(t){var e;t.settings=t.settings||{},t._appSettings=t._appSettings||{},t._appSettings.cmp=t._appSettings.cmp||{},t._appSettings.tcf=t._appSettings.tcf||{},t._appSettings.customJsTargetingObject=t.settings.queryJsTargeting||{},t.settings.customization=t.settings.customization||{},t.settings.rendering=t.settings.rendering||{},t.settings.advertising=t.settings.advertising||{},t.settings.outstreamSettings=t.settings.outstreamSettings||{},t.settings.gallery=t.settings.gallery||{},t.settings._connatixInternals=t.settings._connatixInternals||{},t.settings.plugins=t.settings.plugins||{},t.settings.advertising.skipAdSettings=t.settings.advertising.skipAdSettings||{},t.settings.useExternalViewabilityService=!1;return[].includes(null===(e=null==t?void 0:t._appSettings)||void 0===e?void 0:e.bundleID)&&(0,p.n)({level:p.D.INFO,message:"CNX_INAPP_SETTINGS",exception:JSON.stringify(t._appSettings)}),t=(t=>{var i,e,n;const r=Object.assign({},t),o=null===(i=r._appSettings)||void 0===i?void 0:i.cmp;((0,s.QM)(null===(e=r._appSettings)||void 0===e?void 0:e.gdprConsentString)||(0,s.QM)(null===(n=r._appSettings)||void 0===n?void 0:n.gdprParsedVendorString))&&(r._appSettings.cmp={consentString:(0,s.QM)(null==o?void 0:o.consentString)?o.consentString:r._appSettings.gdprConsentString,parsedVendorConsents:(0,s.QM)(null==o?void 0:o.parsedVendorConsents)?o.parsedVendorConsents:r._appSettings.gdprParsedVendorString});const h=Object.assign({},(0,Ze.EQ)(Object.assign({},r._appSettings.cmp))),a=Object.assign({},(0,Ze.EQ)(Object.assign({},r._appSettings.tcf))),{usPrivacyString:c,deviceID:d,appPageURL:l}=(0,Ze.EQ)({usPrivacyString:r._appSettings.usPrivacyString,deviceID:r._appSettings.deviceID,appPageURL:r._appSettings.appPageURL});return r._appSettings=Object.assign(Object.assign({},r._appSettings),{cmp:h,tcf:a,usPrivacyString:c,deviceID:d,appPageURL:l}),r})(t),{render:function(e,s){try{const n=nt.$.getEnvironment(t._appSettings);if(n.isInAppHybrid&&!nt.$.isValidWebviewInApp(n))throw new Error("not a valid in app webview implementation. Missing bundle id or webViewability setting");n.isInAppSDK&&(t.settings.useExternalViewabilityService=nt.$.shouldUseExternalViewabilityService(t._appSettings.sdkVersion));const r=((t,i)=>{const{settings:{plugins:e}}=t,{cmp:s,tcf:n,usPrivacyString:r,deviceID:o}=t._appSettings,h=Nd(t,Od);return{UserManagerService:new g.x(Fd,i,h,{cmp:s,tcf:n,usPrivacyString:r,deviceID:o}),EventsStorageService:new D(e._debugLogging)}})(t,n.isInApp);jd(t,e,r,n,i,s)}catch(t){(0,p.n)({message:"Prerender_Elements_main_initPlayer",exception:t.message,callStack:t.stack,level:p.D.INFO},{throttle:1e3})}}}},e[t].cmd={push:function(t){try{t()}catch(t){(0,p.n)({message:"Prerender_Elements_main_push_callback",level:p.D.INFO,callStack:t.stack,exception:t.message},{throttle:1e3})}}},e[t].configEnums=Cd,e[t].configEvents=ya,e[t]}(),e.forEach((t=>{try{t()}catch(t){(0,p.n)({message:"Prerender_Elements_main_commands_callback",exception:t.message,callStack:t.stack,level:p.D.INFO},{throttle:1e3})}}))}()}catch(t){(0,p.n)({message:"Prerender_Elements_main",exception:t.message,callStack:t.stack,level:p.D.INFO},{throttle:1e3})}})(),o=r.O(o)})();