c.amazon-adsystem.com Open in urlscan Pro
13.32.21.201  Public Scan

URL: http://c.amazon-adsystem.com/aax2/apstag.js
Submission: On October 09 via manual from US — Scanned from DE

Form analysis 0 forms found in the DOM

Text Content

/*! amazon-dtb-javascript-api - apstag - v7.69.01 - 2021-09-21 16:07:17 */
!function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=22)}([function(t,e,n){"use strict";function r(t){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function i(t){try{var e=parseInt(t,10);if(!isNaN(e))return!(e<=0)&&(100<=e||100*Math.random()<=e)}catch(t){}return!1}function o(t,e){var n=parseInt(e,10),r=[],i=0;if(!u(t))return r;if(isNaN(n)||n<1)return[t];for(var o=t.length;i<o;){var c=i;i+=n,r.push(t.slice(c,i))}return r}function c(){return"".concat(Math.round(1e12*Math.random())).concat(Date.now())}function a(t){for(var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",n=new Array(t),r=0;r<t;r++)n[r]=e[Math.floor(Math.random()*e.length)];return n.join("")}function s(t){return"object"===r(t)&&null!==t}function u(t){return"[object Array]"===Object.prototype.toString.call(t)}function d(t,e){return s(t)&&void 0!==t[e]&&""!==t[e]}function l(){var t="amzn_lsTest";try{return window.localStorage.setItem(t,t),window.localStorage.removeItem(t),!0}catch(t){return!1}}function f(t,e){return-1!==t.indexOf(e)}function b(){return document.cookie.split("; ").map((function(t){return t.split("=")}))}function p(t){var e=new Date;return e.setDate(e.getDate()+t),e.toUTCString()}function m(t){try{var e=t.innerWidth||t.document.documentElement.clientWidth||t.document.body.clientWidth,n=t.innerHeight||t.document.documentElement.clientHeight||t.document.body.clientHeight;return"".concat(e,"x").concat(n)}catch(t){}return"x"}function g(t,e){return decodeURIComponent(t).split("?")[0].split("#")[0]===decodeURIComponent(e).split("?")[0].split("#")[0]}function h(t){var e=Object.keys(t);return e.filter((function(e){return t[e]})).length===e.length}n.d(e,"n",(function(){return i})),n.d(e,"c",(function(){return o})),n.d(e,"e",(function(){return c})),n.d(e,"f",(function(){return a})),n.d(e,"l",(function(){return s})),n.d(e,"k",(function(){return u})),n.d(e,"m",(function(){return d})),n.d(e,"i",(function(){return l})),n.d(e,"j",(function(){return f})),n.d(e,"d",(function(){return b})),n.d(e,"g",(function(){return p})),n.d(e,"h",(function(){return m})),n.d(e,"b",(function(){return g})),n.d(e,"a",(function(){return h}))},function(t,e,n){"use strict";n.d(e,"b",(function(){return d})),n.d(e,"c",(function(){return l})),n.d(e,"d",(function(){return f})),n.d(e,"a",(function(){return b}));var r=n(0),i=n(3),o=n(2),c=n(5),a=n(7),s=Object(r.n)(10),u=[];function d(t,e){var n=2<arguments.length&&void 0!==arguments[2]&&arguments[2];try{(n||Object(c.d)("errors"))&&console.error(t);var r={ts:Date.now(),url:encodeURIComponent(Object(a.g)(window)),r:encodeURIComponent(Object(a.h)(window)),_type:"apsLibraryError",e:{et:t.name,el:e,msg:t.message}};return u.push(r),o.a.dispatch({type:"LOG_ERROR",error:r}),!!s&&(Object(i.b)(r),!0)}catch(t){console.error(t)}return!1}function l(t,e,n){var r=!(3<arguments.length&&void 0!==arguments[3])||arguments[3];return d({name:e,message:"".concat(t," was of type '").concat(e,"' instead of '").concat(n,"'")},"TypeError-".concat(t),r)}function f(t,e){return function(){try{return t.apply(null,arguments)}catch(t){return d(t,e,!0),null}}}function b(t){(1<arguments.length&&void 0!==arguments[1]&&arguments[1]||Object(c.d)("errors"))&&console.warn(t)}!0===Object(c.c)("exposeErrors")&&(window.apstagErrors=u)},function(t,e,n){"use strict";n.d(e,"a",(function(){return b}));var r,i=n(4),o=n(0),c=n(5);function a(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function s(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?a(Object(n),!0).forEach((function(e){u(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function u(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function d(t){return function(t){if(Array.isArray(t))return l(t)}(t)||function(t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(t))return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return l(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?l(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function l(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function f(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{AAXReqs:[],aaxViewabilityEnabled:!1,bidConfigs:{},bidReqs:{},bsPixels:{},cfg:{v:-1,CSM_JS:"//c.amazon-adsystem.com/aax2/csm.js.gz",CSM_RTB_COMMUNICATOR_JS:"//c.amazon-adsystem.com/bao-csm/aps-comm/aps_csm.js",DEBUG_APP_HTML:"//c.amazon-adsystem.com/aax2/debugApp.html",DEBUG_APP_HTML_V2:"//c.amazon-adsystem.com/aax2/debug_app_v2.html",DEFAULT_TIMEOUT:2e3,DTB_PATH:"/e/dtb",TEST_PATH_FREQUENCY:0,TEST_BID_ENDPOINT:null,TEST_PATH_LATENCY_SAMPLE_RATE:null,PIXEL_PATH:"/x/px/",LATENCY_SAMPLING_RATE:1,COOKIE_MATCH_DELAY:0,MAX_SLOTS_PER_REQUEST:1,CF_ROUTING_RATE:100,SLOT_RENDER_SAMPLING_RATE:1,FEATURE_SAMPLING_RATE:1,CONFIG_CALL_ENABLED:!1,LIB_CONFIG_PATH:"/cdn/prod/config"},cmpFired:!1,config:{pubID:""},displayAdServer:{noBidSlotIDs:[],shouldSampleRender:!1,slotRenderEndedSet:!1},errors:[],eventLog:[],experiments:{},gamSlotFetchLog:[],gamSlotRenderPixel:{aaxReqOffset:0,gamSlotFetchLogOffset:0},hosts:{DEFAULT_AAX_BID_HOST:"aax.amazon-adsystem.com",DEFAULT_AAX_PIXEL_HOST:"aax.amazon-adsystem.com"},identityState:{},libraryLoadCallLatency:0,Q:[],slotBids:{},slotIdMap:[],sync917:!1,targetingKeys:{},tcfParseTime:0},e=1<arguments.length?arguments[1]:void 0;return{AAXReqs:function(t,e){switch(e.type){case"RECORD_AAX_REQUEST":return[].concat(d(t),[e.data]);case"RECORD_AAX_REQ_PROP":return t.map((function(t){return(t=s({},t)).bidReqID===e.bidReqID&&(t[e.key]=e.value),t}));default:return d(t)}}(t.AAXReqs,e),aaxViewabilityEnabled:function(t,e){switch(e.type){case"SET_VIEWABILITY":return e.viewability;default:return t}}(t.aaxViewabilityEnabled,e),bidConfigs:function(t,e){switch(e.type){case"RECORD_ORIGINAL_BID_CONFIG":return s(s({},t),{},u({},e.bidConfig.bidReqID,e.bidConfig));default:return s({},t)}}(t.bidConfigs,e),bidReqs:function(t,e){var n;switch(e.type){case"ADD_CHUNKED_REQUESTS":return s(s({},t),{},u({},e.fid,s(s({},t[e.fid]),{},{networkReqs:new Array(e.numChunks)})));case"NEW_FETCH_BID_REQUEST":return s(s({},t),{},u({},e.fid,{pto:e.pto,hasCallbackExecuted:!1,networkReqs:[]}));case"RECORD_CALLBACK":return s(s({},t),{},u({},e.fid,s(s({},t[e.fid]),{},{hasCallbackExecuted:!0})));case"RECORD_NETWORK_EXCHANGE":var r=t[e.fid].networkReqs;return r[e.networkID]=s(s({},r[e.networkID]),{},(u(n={},"".concat(e.exchangeType,"Time"),e.timestamp),u(n,"inFlight","request"===e.exchangeType),n)),s(s({},t),{},u({},e.fid,s(s({},t[e.fid]),{},{networkReqs:r})));case"RECORD_TIMEOUT":return s(s({},t),{},u({},e.fid,s(s({},t[e.fid]),{},{networkReqs:t[e.fid].networkReqs.map((function(t){return t.inFlight?s(s({},t),{},{timeOut:e.timeOut}):t}))})));default:return s({},t)}}(t.bidReqs,e),bsPixels:function(t,e){switch(e.type){case"RECORD_BID_INFO_SENT":return s(s({},t),{},u({},e.bidInfo.iid,e.bidInfo.state));default:return s({},t)}}(t.bsPixels,e),cfg:function(t,e){switch(e.type){case"SET_CFG":return s(s({},t),e.cfg);default:return s({},t)}}(t.cfg,e),cmpFired:function(t,e){switch(e.type){case"CMP_FIRED":return!0;default:return t}}(t.cmpFired,e),config:function(t,e){switch(e.type){case"SET_CONFIG":return s(s({},e.config),{},{gdpr:s({cmpTimeout:e.defaultCmpTimeout},e.config.gdpr),isSelfServePub:void 0!==e.config.pubID&&5<=e.config.pubID.length});default:return s({},t)}}(t.config,e),displayAdServer:function(t,e){switch(e.type){case"SLOT_RENDER_ENDED_SET":return s(s({},t),{},{slotRenderEndedSet:!0});case"NO_BID_ON_ADSERVER_SLOTS":return s(s({},t),{},{noBidSlotIDs:t.noBidSlotIDs.concat(e.slotIDs)});case"REQUESTED_BID_FOR_ADSERVER_SLOTS":return s(s({},t),{},{noBidSlotIDs:t.noBidSlotIDs.filter((function(t){return!Object(o.j)(e.slotIDs,t)}))});case"SHOULD_SAMPLE_SLOT_RENDER":return s(s({},t),{},{shouldSampleRender:e.value});default:return s(s({},t),{},{noBidSlotIDs:d(t.noBidSlotIDs)})}}(t.displayAdServer,e),errors:function(t,e){switch(e.type){case"LOG_ERROR":return[].concat(d(t),[s({},e.error)]);default:return d(t)}}(t.errors,e),eventLog:function(t,e){switch(e.type){case"LOG_EVENT":return[].concat(d(t),[s({},e.event)]);default:return d(t)}}(t.eventLog,e),experiments:function(t,e){switch(e.type){case"SHOULD_CHUNK_REQUESTS":return s({chunkRequests:!0===t.shouldSampleLatency&&e.value},t);case"SHOULD_CF_ROUTE":return s(s({},t),{},{shouldCFRoute:e.value});case"SHOULD_SAMPLE_LATENCY":return s(s({},t),{},{shouldSampleLatency:e.value});case"SHOULD_SAMPLE_FEATURES":return s(s({},t),{},{shouldSampleFeatures:e.value});case"SHOULD_USE_TEST_BID_ENDPOINT":return s(s({},t),{},{shouldUseTestBidEndpoint:e.value});default:return s({},t)}}(t.experiments,e),gamSlotFetchLog:function(t,e){switch(e.type){case"LOG_GAM_EVENT":return[].concat(d(t),[s({},e.event)]);default:return d(t)}}(t.gamSlotFetchLog,e),gamSlotRenderPixel:function(t,e){switch(e.type){case"UPDATE_RENDER_OFFSETS":return s(s({},t),e.offsets);default:return s({},t)}}(t.gamSlotRenderPixel,e),hosts:function(t,e){switch(e.type){case"SET_HOST":return s(s({},t),{},u({},e.hostName,e.hostValue));default:return s({},t)}}(t.hosts,e),identityState:function(t,e){switch(e.type){case"RECORD_IDENTITY_STATE":return s(s({},t),{},u({},e.vendor,Object(o.m)(t,e.vendor)?t[e.vendor]:e.identityState));default:return t}}(t.identityState,e),libraryLoadCallLatency:function(t,e){switch(e.type){case"RECORD_LIBRARY_LOAD_CALL_LATENCY":return e.latency;default:return t}}(t.libraryLoadCallLatency,e),Q:function(t,e){switch(e.type){case"SET_Q":return d(e.Q);default:return d(t)}}(t.Q,e),slotBids:function(t,e){switch(e.type){case"BID_STATE_CHANGE":return s(s({},t),{},u({},e.slotID,t[e.slotID].map((function(t){return t._targetingSetID===e._targetingSetID&&(t.bidState=e.bidState,e.bidState===i.c.rendered?t.timing.renderTime=e.ts:e.bidState===i.c.set&&t.timing.setAtTimes.push(e.ts)),t}))));case"UPDATE_BID_INFO_PROP":return void 0===t[e.slotID]||t[e.slotID].filter((function(t){return t.matchesBidCacheId(e.iid)})).length<1?s({},t):s(s({},t),{},u({},e.slotID,t[e.slotID].map((function(t){return t.matchesBidCacheId(e.iid)&&(t[e.key]=e.value),t}))));case"UPDATE_SLOT_BIDS":return s(s({},t),e.bids.reduce((function(e,n){return Object(o.m)(e,n.slotID)?e[n.slotID]=[].concat(d(e[n.slotID]),[n]):Object(o.m)(t,n.slotID)?e[n.slotID]=[].concat(d(t[n.slotID]),[n]):e[n.slotID]=[n],e}),{}));default:return s({},t)}}(t.slotBids,e),slotIdMap:function(t,e){switch(e.type){case"ADD_SLOT_ID":return-1===t.indexOf(e.slotID)?[].concat(d(t),[e.slotID]):t;default:return t}}(t.slotIdMap,e),sync917:function(t,e){switch(e.type){case"SET_SYNC_917":return e.value;default:return t}}(t.sync917,e),targetingKeys:function(t,e){switch(e.type){case"UPDATE_SLOT_BIDS":return s(s({},t),e.bids.reduce((function(e,n){return Object(o.m)(t,n.slotID)?e[n.slotID]=[].concat(d(t[n.slotID]),d((n.bidConfig.targeting?n.bidConfig.targeting:i.i).filter((function(e){return-1===t[n.slotID].indexOf(e)})))):e[n.slotID]=n.bidConfig.targeting?n.bidConfig.targeting:i.i,e}),{}));default:return s({},t)}}(t.targetingKeys,e),tcfParseTime:function(t,e){switch(e.type){case"RECORD_TCF_PARSE_TIME":return e.time;default:return t}}(t.tcfParseTime,e)}}var b={getState:function(){return r},dispatch:function(t){r=f(r,t)}};Object(c.d)("redux")&&Object(o.i)()&&Object(o.m)(window,"__REDUX_DEVTOOLS_EXTENSION__")&&(b=window.__REDUX_DEVTOOLS_EXTENSION__(f)),b.dispatch({type:"NOOP"})},function(t,e,n){"use strict";n.d(e,"e",(function(){return p})),n.d(e,"c",(function(){return v})),n.d(e,"d",(function(){return S})),n.d(e,"b",(function(){return _})),n.d(e,"a",(function(){return E})),n.d(e,"f",(function(){return D}));var r=n(4),i=n(2),o=n(5),c=n(0),a=n(1),s=n(7),u=n(12),d=n(10),l=[],f=!1,b=[];function p(t){var e=new Image;return e.src=t,b.push(e),e}!0===Object(o.c)("exposePixels")&&(window.apstagPixelQueue=l,window.apstagPixelsSent=b);var m,g={adServer:[],ampAdContext:[],appended:[],AaxSlotSizes:[],bidRender:[],bidRenderState:[],bidType:[],"blockedBidders-fetchBids":[],"blockedBidders-init":[],ccpa:[],cmpVar:[],creativeSize:[],deals:[],fetchBids:[],fifFlow:[],customFloor:[],gdpr:[],id:[],idRemap:[],iframe:[],renderFootprint:[],resizeIframe:[],schain:[],simplerGpt:[],slots:[],slotType:[],targeting:[],tcfVar:[],unusedDeal:[],useSafeFrames:[]},h=[],y=!1;function O(){y&&(clearTimeout(m),y=!1),Object(c.c)(h,5).forEach((function(t){_({_type:"featureUsage",p:t,u:Object(s.g)(window)})})),h=[]}function j(){y||(y=!0,m=setTimeout(O,2e3))}function v(t,e){try{return!!i.a.getState().experiments.shouldSampleFeatures&&(void 0!==g[t]&&!Object(c.j)(g[t],e)&&(g[t].push(e),h.push({cat:t,feat:e}),f&&j(),!0))}catch(t){return Object(a.b)(t,"sendFeaturePixel"),!1}}function S(){try{var t=i.a.getState().libraryLoadCallLatency,e=Object(u.c)(window,new RegExp("aax2/apstag.js"));if(null!==e||0!==t){var n=Object(u.e)(window,"navigationStart"),r={_type:"libLatency",pid:d.b,ns:n};if(null!==e){r.fs=Object(u.a)(e,"fetchStart"),r.re=Object(u.a)(e,"responseEnd");var o=Object(u.f)(e);null!==o&&(r.c=o?1:0)}0!==t&&(r.tcc=t),_(r)}}catch(t){Object(a.b)(t,"sendInitLatencyPixel")}}function w(t){try{if(f){var e=function(){try{var t=i.a.getState(),e=t.cfg.PIXEL_PATH,n=t.hosts.DEFAULT_AAX_PIXEL_HOST,c=Object(o.c)("pixelHost",n);return"".concat(r.s).concat(c).concat(e)}catch(t){return Object(a.b)(t,"buildPixelBaseUrl"),""}}();return void 0===t.bidId?e+="p/PH/":e+="".concat(t.bidId,"/"),p(e+=function(t){try{t._tl="aps-tag";var e=i.a.getState(),n=null,o="";Object(c.m)(e,"config")&&Object(c.m)(e.config,"pubID")&&""!==e.config.pubID&&(n=e.config.isSelfServePub,o=e.config.pubID),null!==n&&(n?(t.src=r.t,t.pubid=o):t.src=o),t.lv=r.l;var s=JSON.stringify(t);return s=function(t){try{return t.replace(/\\.{1}/g,"")}catch(t){return Object(a.b)(t,"escapeJsonForAax"),""}}(s),s=encodeURIComponent(s)}catch(t){return Object(a.b)(t,"objectToUrlPath"),""}}(t.payload))}return l.push(t),!1}catch(t){return Object(a.b)(t,"sendPixel"),!1}}function _(t){return w({payload:t})}function E(t,e){return w({payload:e,bidId:t})}function D(){try{if(f)return;f=!0,l.forEach(w),0<h.length&&j()}catch(t){Object(a.b)(t,"sendPixels")}}!0===Object(o.c)("exposePixels")&&(window.apstagFeaturePixelQueue=h)},function(t,e,n){"use strict";n.d(e,"i",(function(){return o})),n.d(e,"x",(function(){return c})),n.d(e,"c",(function(){return r})),n.d(e,"h",(function(){return d})),n.d(e,"w",(function(){return l})),n.d(e,"f",(function(){return f})),n.d(e,"g",(function(){return b})),n.d(e,"d",(function(){return p})),n.d(e,"p",(function(){return m})),n.d(e,"n",(function(){return g})),n.d(e,"e",(function(){return h})),n.d(e,"o",(function(){return a})),n.d(e,"m",(function(){return u})),n.d(e,"v",(function(){return S})),n.d(e,"j",(function(){return y})),n.d(e,"u",(function(){return j})),n.d(e,"t",(function(){return w})),n.d(e,"l",(function(){return _})),n.d(e,"s",(function(){return E})),n.d(e,"b",(function(){return D})),n.d(e,"k",(function(){return I})),n.d(e,"a",(function(){return T})),n.d(e,"r",(function(){return A})),n.d(e,"q",(function(){return R})),n.d(e,"z",(function(){return C})),n.d(e,"y",(function(){return x}));var r,i,o=["amznbid","amzniid","amznsz","amznp"],c=["amznbid","amzniid","amznp","r_amznbid","r_amzniid","r_amznp"];(i=r=r||{}).new="NEW",i.exposed="EXPOSED",i.set="SET",i.rendered="RENDERED";var a,s,u,d="apstagDebug",l=["redux","fake_bids","verbose","console","console_v2","errors"],f="apstagDebugHeight",b="apstagDEBUG",p="apstagCfg",m=0,g=0,h="apstagCxMEnabled";(s=a=a||{}).amznbid="testBid",s.amzniid="testImpression",s.amznp="testP",s.crid="testCrid",(u||(u={})).video="v";var y,O,j,v,S=["amznbid","amznp"];(O=y=y||{}).__apsid="ck",O.__aps_id_p="ckp",O.aps_ext_917="st",(v=j=j||{}).noRequest="0",v.bidInFlight="1",v.noBid="2";var w="600",_="7.69.01",E="https://",D="".concat(E,"aax.amazon-adsystem.com/e/dtb/vast?"),I="function"==typeof XMLHttpRequest&&void 0!==(new XMLHttpRequest).withCredentials,T="apstagLOADED",A=13,R=1e4,C=/^1[NY\-]{3}$/,x='<!DOCTYPE html>\n <html>\n     <head>\n         <title>APS Video Ads</title>\n         <script src="https://dcqi4aodgg8tv.cloudfront.net/apsvideoplayersdk/latest/apsvid.js"><\/script>\n     </head>\n     <body>\n         <div id="amazon-ads-container" style="height: 100%; width: 100%; position: absolute;">\n         </div>\n         <script type="text/javascript">\n           const adsContainer = document.querySelector("#amazon-ads-container")\n           const amazonVideoAds = new window.AmazonVideoAds(adsContainer);\n           window.adsM;\n\n           function addListeners(adsM, amazonVideoAds) {\n            adsM.addListener(amazonVideoAds.eventNames.AdVideoPlayerEvents.COMPLETED, (e) => {\n              window.top.postMessage({"apsVideoPlayer": true, "event": "completed"}, window.top.location.origin);\n            })\n            adsM.addListener(amazonVideoAds.eventNames.AdVideoPlayerEvents.LOADED, (e) => {\n              window.top.postMessage({"apsVideoPlayer": true, "event": "loaded"}, window.top.location.origin);\n            })\n        }\n \n           window.requestAndPlay = () => {\n             amazonVideoAds.fetchAds("$$apstagVastTag$$")\n               .then(adsManager => {\n \n                 adsM = adsManager;\n \n                 adsM.init({\n                    fullscreen: true,\n                    muted: true,\n                    volume: .3,\n                    autoplay: false,\n                    controls: false,\n                    preaload: "auto",\n                 })\n\n                 addListeners(adsM, amazonVideoAds);\n                 adsM.startAds(2000, {shouldVideoRemainAfterPlay: true});\n                 \n               })\n               .catch(function(err) {\n                 console.log("apstag failed to get APS ads manager", err);\n               });\n           }\n \n          requestAndPlay();\n\n         <\/script>\n     </body>\n </html>'},function(t,e,n){"use strict";n.d(e,"a",(function(){return d})),n.d(e,"b",(function(){return g})),n.d(e,"d",(function(){return _})),n.d(e,"c",(function(){return D})),n.d(e,"e",(function(){return T}));var r=n(2),i=n(0),o=n(4),c=n(8),a=n(3),s=n(1),u=["getLog","getState"];function d(t,e,n){try{switch(Object(i.j)(u,t)&&(Object(s.b)(new Error("Debug call made: ".concat(t)),"debugPublicApi-call-".concat(t)),u=u.filter((function(e){return e!==t}))),t){case"getLog":return r.a.getState().eventLog;case"getState":return r.a.getState();case"enable":return E("fake_bids",!0),"DEBUG MODE ENABLED";case"disable":return E("fake_bids",!1),"DEBUG MODE DISABLED";case"enableConsole":return g(!1,"command"),"Debug console enabled";case"enableConsoleV2":return g(!0,"command"),"Debug console v2 enabled";case"disableConsole":return function(){try{E("console",!1),E("console_v2",!1),null!==l&&document.body.removeChild(l),m=!1,Object(i.i)()&&window.localStorage.removeItem(o.f)}catch(t){Object(s.b)(t,"disableDebugConsole",!0)}}(),"Debug console disabled";case"setDebug":return E(e,n)?"Set debug mode '".concat(e,"' to '").concat(n,"'"):"Failed to set debug mode '".concat(e,"' to '").concat(n,"'");default:return"unknown debug argument"}}catch(e){return Object(s.b)(e,"debugPublicApi",!0),"error"}}var l,f,b,p,m=!1;function g(){var t=0<arguments.length&&void 0!==arguments[0]&&arguments[0],e=1<arguments.length?arguments[1]:void 0;try{if(E(t?"console_v2":"console",!0),m)return;var n={url:t?r.a.getState().cfg.DEBUG_APP_HTML_V2:r.a.getState().cfg.DEBUG_APP_HTML,onload:h,onerror:function(){return Object(s.b)(new Error("Error Loading Debug Console"),"enableDebugConsole-".concat(t?"v2":"v1","-onerror"),!0)}};Object(c.d)(n),setTimeout((function(){try{var n={_type:"debugLoad",mode:t?2:1};Object(i.m)(r.a.getState().config,"pubID")&&(n.src=r.a.getState().config.pubID),null!==e&&(n.method=e),Object(a.b)(n)}catch(n){Object(s.b)(n,"enableDebugConsole-setTimeout",!0)}}),5e3)}catch(n){Object(s.b)(n,"enableDebugConsole",!0)}}function h(t){try{var e=t.responseText;l=document.createElement("div"),f=document.createElement("div"),b=document.createElement("iframe");var n=200;_("console_v2")&&(n=330),Object(i.i)()&&null!==window.localStorage.getItem(o.f)&&(n=parseInt(window.localStorage.getItem(o.f),10)),(isNaN(n)||n>window.innerHeight)&&(n=200),l.style.background="#eaeded",l.style.zIndex="2147483647",l.style.bottom="0",l.style.position="fixed !important",l.style.display="block !important",l.style.left="0",l.style.right="0",l.style.height="".concat(n,"px"),f.style.cursor="row-resize",f.style.height="2px",f.style.position="absolute",f.style.top="0",f.style.left="0",f.style.right="0",f.style.backgroundColor="RGBA(0,0,0,0)",l.appendChild(f),b.frameBorder="0",b.marginHeight="0",b.marginWidth="0",b.scrolling="no",b.id="apstag-debug-iframe",b.src="about:blank",b.style.display="block",b.style.width="100%",b.style.height="".concat(n,"px"),l.appendChild(b),document.body.appendChild(l),null!==b.contentDocument&&(b.contentDocument.open(),b.contentDocument.write(e),b.contentDocument.close()),f.addEventListener("mousedown",j)}catch(t){Object(s.b)(t,"renderDebugConsole",!0)}}function y(t){try{var e=window.innerHeight-t.clientY;return e<200&&(e=200),l.style.height="".concat(e,"px"),b.style.height="".concat(e,"px"),e}catch(t){return Object(s.b)(t,"resizeDebugConsole",!0),200}}function O(t){try{return t.stopPropagation&&t.stopPropagation(),t.preventDefault&&t.preventDefault(),t.cancelBubble=!0,t.returnValue=!1}catch(t){return Object(s.b)(t,"preventEvent",!0),!1}}function j(){try{void 0===p&&((p=document.createElement("div")).style.position="fixed",p.style.left="0",p.style.right="0",p.style.top="0",p.style.bottom="0",p.style.zIndex="9999999999"),l.appendChild(p),window.addEventListener("mouseup",S),window.addEventListener("mousemove",v)}catch(t){Object(s.b)(t,"resizeBarMouseDownListener",!0)}}function v(t){try{return y(t),O(t)}catch(t){return Object(s.b)(t,"resizeBarMouseMoveListener",!0),!1}}function S(t){try{null!==p&&l.removeChild(p),window.removeEventListener("mousemove",v),window.removeEventListener("mouseup",S);var e=y(t);return Object(i.i)()&&window.localStorage.setItem(o.f,"".concat(e)),O(t)}catch(t){return Object(s.b)(t,"resizeBarMouseUpListener",!0),!1}}function w(){try{if(!Object(i.i)())return[];var t=window.localStorage.getItem(o.h);null===t||"false"===t?t="[]":"true"===t&&(t='["fake_bids"]');var e=[];try{e=JSON.parse(t)}catch(t){}return Object(i.k)(e)||(e=[]),e.filter((function(t){return Object(i.j)(o.w,t)}))}catch(t){return Object(s.b)(t,"getCurrentDebugArray"),[]}}function _(t){try{return Object(i.j)(w(),t)}catch(t){return Object(s.b)(t,"isDebugEnabled"),!1}}function E(t,e){try{if(!Object(i.i)())return;if(-1===o.w.indexOf(t))return;var n=w();return e&&-1===n.indexOf(t)?n.push(t):e||(n=n.filter((function(e){return e!==t}))),0===n.length?window.localStorage.removeItem(o.h):window.localStorage.setItem(o.h,JSON.stringify(n)),T(),1}catch(e){return void Object(s.b)(e,"setDebugMode")}}function D(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;try{if(Object(i.m)(window,o.g)&&Object(i.m)(window[o.g],t))return window[o.g][t]}catch(t){Object(s.b)(t,"getDebugValue")}return e}var I=[];function T(){try{w().filter((function(t){return-1===I.indexOf(t)})).forEach((function(t){Object(s.b)(new Error("Debug method enabled: ".concat(t)),"debugPublicApi-enabled-".concat(t),!0),I.push(t)}))}catch(t){Object(s.b)(t,"pixelDebugModes")}}},function(t,e,n){"use strict";n.d(e,"a",(function(){return D})),n.d(e,"b",(function(){return I}));var r=n(0),i=n(13),o=n(1);function c(t){return(c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function a(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function s(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function u(t,e,n){return e&&s(t.prototype,e),n&&s(t,n),t}function d(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&function(t,e){(Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}(t,e)}function l(t){var e=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var n,r,i,o=b(t);if(e){var a=b(this).constructor;n=Reflect.construct(o,arguments,a)}else n=o.apply(this,arguments);return r=this,!(i=n)||"object"!==c(i)&&"function"!=typeof i?f(r):i}}function f(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function b(t){return(b=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function p(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var m=function(){d(e,i.c);var t=l(e);function e(n){var i;return a(this,e),p(f(i=t.call(this,n.targetId,Object(r.m)(n,"invCode")?n.invCode:Object(r.m)(n,"tagId")?n.tagId:n.targetId)),"rawSlot",void 0),p(f(i),"mediaType","display"),i.rawSlot=n,i}return u(e,[{key:"reportError",value:function(t,e,n){var r=2<arguments.length&&void 0!==n&&n;Object(o.b)(t,"ApnSlot-".concat(e),r)}},{key:"initKeywords",value:function(){try{Object(r.m)(this.rawSlot,"keywords")||(this.rawSlot.keywords={})}catch(t){this.reportError(t,"initKeywords")}}},{key:"setTargeting",value:function(t,e){try{this.initKeywords(),this.rawSlot.keywords[t]=e}catch(t){this.reportError(t,"setTargeting")}}},{key:"getTargeting",value:function(t){try{return this.initKeywords(),Object(r.m)(this.rawSlot.keywords,t)?[this.rawSlot.keywords[t]]:[]}catch(t){return this.reportError(t,"getTargeting"),[]}}},{key:"clearTargeting",value:function(t){try{this.initKeywords(),delete this.rawSlot.keywords[t]}catch(t){this.reportError(t,"clearTargeting")}}},{key:"sizes",get:function(){try{return this.rawSlot.sizes}catch(t){return this.reportError(t,"sizes"),[]}}}]),e}(),g=function(){d(e,i.b);var t=l(e);function e(){var n;a(this,e);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return p(f(n=t.call.apply(t,[this].concat(i))),"isSupported",!0),n}return u(e,[{key:"reportError",value:function(t,e){Object(o.b)(t,"AppNexusAdServer-".concat(e))}},{key:"cmdQueuePush",value:function(t){try{window.apntag.anq.push(t)}catch(t){this.reportError(t,"cmdQueuePush")}}},{key:"setTargeting",value:function(t,e){try{if(!Object(r.m)(window,"apntag")||!Object(r.m)(window.apntag,"requests"))return;Object(r.m)(window.apntag.requests,"keywords")||(window.apntag.requests.keywords={}),window.apntag.requests.keywords[t]=e}catch(t){this.reportError(t,"setTargeting")}}},{key:"getTargeting",value:function(t){try{if(!Object(r.m)(window,"apntag")||!Object(r.m)(window.apntag,"requests"))return[];Object(r.m)(window.apntag.requests,"keywords")||(window.apntag.requests.keywords={});var e=window.apntag.requests.keywords[t];return void 0===e?[]:[e]}catch(t){return this.reportError(t,"getTargeting"),[]}}},{key:"clearTargeting",value:function(t){try{Object(r.m)(window,"apntag")&&Object(r.m)(window.apntag,"requests")&&Object(r.m)(window.apntag.requests,"keywords")&&delete window.apntag.requests.keywords[t]}catch(t){this.reportError(t,"clearTargeting")}}},{key:"hasAdServerObjectLoaded",value:function(){try{return Object(r.m)(window,"apntag")&&Object(r.m)(window.apntag,"loaded")&&!0===window.apntag.loaded}catch(t){return this.reportError(t,"hasAdServerObjectLoaded"),!1}}},{key:"isCommandQueueDefined",value:function(){try{return Object(r.m)(window,"apntag")&&Object(r.m)(window.apntag,"anq")}catch(t){return this.reportError(t,"isCommandQueueDefined"),!1}}},{key:"getSlots",value:function(){try{var t=[];return Object(r.m)(window,"apntag")&&Object(r.m)(window.apntag,"requests")&&Object(r.m)(window.apntag.requests,"tags")&&Object(r.l)(window.apntag.requests.tags)&&Object.keys(window.apntag.requests.tags).forEach((function(e){var n=window.apntag.requests.tags[e];t.push(new m(n))})),t}catch(t){return this.reportError(t,"getSlots"),[]}}}]),e}(),h=n(17);function y(t){return(y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function O(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function j(t,e){return(j=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function v(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function S(t){return(S=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function w(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var _=function(){!function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&j(t,e)}(c,i.b);var t,e,n=function(t){var e=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var n,r,i,o=S(t);if(e){var c=S(this).constructor;n=Reflect.construct(o,arguments,c)}else n=o.apply(this,arguments);return r=this,!(i=n)||"object"!==y(i)&&"function"!=typeof i?v(r):i}}(c);function c(){var t;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,c);for(var e=arguments.length,r=new Array(e),i=0;i<e;i++)r[i]=arguments[i];return w(v(t=n.call.apply(n,[this].concat(r))),"isSupported",!0),w(v(t),"needNewBidObject",!0),t}return t=c,(e=[{key:"reportError",value:function(t,e){Object(o.b)(t,"SmartAdServer-".concat(e))}},{key:"cmdQueuePush",value:function(t){try{window.sas.cmd.push(t)}catch(t){this.reportError(t,"cmdQueuePush")}}},{key:"hasAdServerObjectLoaded",value:function(){try{return Object(r.m)(window,"sas")&&Object(r.m)(window.sas,"__smartLoaded")&&!0===window.sas.__smartLoaded}catch(t){return this.reportError(t,"hasAdServerObjectLoaded"),!1}}},{key:"isCommandQueueDefined",value:function(){try{return Object(r.m)(window,"sas")&&Object(r.m)(window.sas,"cmd")}catch(t){return this.reportError(t,"isCommandQueueDefined"),!1}}}])&&O(t.prototype,e),c}(),E=n(3),D=new i.b;function I(t){try{switch(t){case"appnexus":Object(E.c)("adServer",t),D=new g;break;case"googletag":Object(E.c)("adServer",t),D=new h.a;break;case"sas":Object(E.c)("adServer",t),D=new _;break;default:"string"==typeof t?Object(E.c)("adServer","invalid-".concat(t)):Object(E.c)("adServer","none"),D=new i.b}}catch(t){Object(o.b)(t,"setDisplayAdServer")}}},function(t,e,n){"use strict";n.d(e,"c",(function(){return d})),n.d(e,"j",(function(){return l})),n.d(e,"g",(function(){return f})),n.d(e,"h",(function(){return b})),n.d(e,"d",(function(){return p})),n.d(e,"e",(function(){return m})),n.d(e,"f",(function(){return g})),n.d(e,"i",(function(){return y})),n.d(e,"b",(function(){return O})),n.d(e,"a",(function(){return j})),n.d(e,"k",(function(){return v}));var r=n(5),i=n(0),o=n(1),c=n(4),a=n(2),s=n(3);function u(t){return(u="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function d(t){try{return t.split("_").pop()}catch(t){return Object(o.b)(t,"getAmpAmznBidValue"),""}}function l(t){try{return!Object(i.m)(t,"slots")}catch(t){return Object(o.b)(t,"isAAXPunt"),!0}}function f(t){try{var e,n=Object(r.c)("url");if(null!==n)return encodeURIComponent(n);try{v(t,!1)?(Object(s.c)("ampAdContext","getCurrentUrl"),e=null,t.context&&(e=t.context.canonicalUrl||t.context.sourceUrl)):e=t.top.location.href}catch(t){e=null}if(null===e||!e||void 0===e){e="";try{t.top!==t.self&&(e=t.document.referrer)}catch(t){}}return encodeURIComponent(e)}catch(t){return Object(o.b)(t,"getCurrentUrl"),""}}function b(t){try{var e,n="",i=Object(r.c)("url");if(null!==i)return encodeURIComponent(i);try{try{e=v(t,!1)?(Object(s.c)("ampAdContext","getReferrerUrl"),t.context?t.context.referrer:t.top.document.referrer):t.top.document.referrer}catch(n){e=t.document.referrer}n=encodeURIComponent(e)}catch(n){}return n}catch(n){return Object(o.b)(n,"getReferrerUrl"),""}}function p(){try{var t={cookiesParams:""};return Object(i.d)().forEach((function(e){if(e[0]in c.j)switch(e[0]){case"aps_ext_917":t.fb=e[1];break;default:t.cookiesParams+="&".concat(c.j[e[0]],"=").concat(e[1])}})),t.fb||a.a.getState().sync917||a.a.dispatch({type:"SET_SYNC_917",value:!0}),t}catch(t){return Object(o.b)(t,"getApsFirstPartyCookies"),{cookiesParams:""}}}function m(t){try{var e=a.a.getState().config.blockedBidders;Object(i.m)(t,"blockedBidders")&&Object(i.k)(t.blockedBidders)&&(e=t.blockedBidders);var n="";return Object(i.k)(e)&&(n=JSON.stringify(e)),n}catch(t){return Object(o.b)(t,"getBlockedBidders",!0),""}}function g(){try{if(!Object(i.i)())return c.p;var t=a.a.getState();return Object(i.m)(t,"cfg")&&Object(i.m)(t.cfg,"v")&&-1!==t.cfg.v?t.cfg.v:null}catch(t){return Object(o.b)(t,"getCfgVersion"),null}}function h(t){try{if(-1===["string","number"].indexOf(u(t)))return!1;var e=Math.floor(Number(t));if(e>c.n)return e}catch(t){Object(o.b)(t,"parseTimeout",!0)}return!1}function y(t,e){try{var n=h(t.timeout);return!1===n&&(n=h(e.config.bidTimeout)),!1===n&&(n=h(e.cfg.DEFAULT_TIMEOUT)),n}catch(t){return Object(o.b)(t,"getTimeout",!0),2e3}}function O(t,e){var n,r=!1;function i(e){if(!r)try{t(e)}catch(e){Object(o.b)(e,"executeFunctionOnceWithTimeout-wrappedFunction",!0)}clearTimeout(n),r=!0}try{return n=setTimeout(i,e,!0),i.bind(null,!1)}catch(e){return Object(o.b)(e,"executeFunctionOnceWithTimeout",!0),function(){}}}function j(t){var e=!1;return function(){if(!e)try{t()}catch(t){Object(o.b)(t,"executeFunctionOnceWithTimeout-wrappedFunction",!0)}e=!0}}function v(t,e){try{var n=e?t.AMP_CONTEXT_DATA:t.context;return Boolean(n&&Object(i.m)(n,"tagName")&&"AMP-AD"===n.tagName)}catch(t){return Object(o.b)(t,"isInAmpAd"),!1}}},function(t,e,n){"use strict";n.d(e,"d",(function(){return o})),n.d(e,"b",(function(){return c})),n.d(e,"a",(function(){return a})),n.d(e,"c",(function(){return s}));var r=n(1);function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function o(t){var e=t.url,n=t.onload,o=t.onerror,c=t.ontimeout,a=t.withCredentials,s=t.body,u=void 0===s?null:s,d=t.headers,l=void 0===d?null:d,f=new window.XMLHttpRequest;try{if(""===e)return void(void 0!==o&&o.call(f,"error"));f.onload=n.bind(null,f),void 0!==o&&(f.onerror=o),void 0!==c&&(f.ontimeout=c),void 0!==a&&(f.withCredentials=a);var b="GET";null!==u&&(b="POST"),f.open(b,e),null!==l&&"object"===i(l)&&Object.keys(l).forEach((function(t){f.setRequestHeader(t,l[t])})),f.send(u)}catch(t){void 0!==o&&o.call(f,"error"),Object(r.b)(t,"xhrRequest")}}function c(t,e,n,i){try{if(void 0===n&&(n=document),void 0===t)return"function"==typeof e&&e(!0),!1;var o=n.getElementsByTagName("script")[0]||n.body.firstChild,c=n.createElement("script");if(c.type="text/javascript",c.async=!0,c.src=t,e&&a(c,e),a(c,i||function(){Object(r.b)(new Error("Error Loading Script Tag"),"loadScriptTag-onerror")},[],"onerror"),null!==o.parentNode)return o.parentNode.insertBefore(c,o),!0}catch(t){Object(r.b)(t,"loadScriptTag",!0)}return!1}function a(t,e){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:[],i=3<arguments.length&&void 0!==arguments[3]?arguments[3]:"onload";try{return"function"==typeof e&&(t[i]=function(){e.apply(null,n)},!0)}catch(t){return Object(r.b)(t,"addCallbackFunction"),!1}}function s(t){try{return encodeURIComponent(JSON.stringify(t))}catch(t){return Object(r.b)(t,"objToUrlParam"),""}}},function(t,e,n){"use strict";n.d(e,"a",(function(){return c})),n.d(e,"b",(function(){return a}));var r=n(1),i=n(0);function o(t){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function c(t){try{return function(t){try{if(!a(t,["number","string"]))return!1;if(isNaN(t))return!1;if("number"==typeof t)return!0;var e=parseInt(t,10);return!isNaN(e)}catch(t){return Object(r.b)(t,"isNumber"),!0}}(t)||void 0===t}catch(t){return Object(r.b)(t,"isNumberOrUndefined"),!0}}function a(t,e){try{return Object(i.j)(e,o(t))}catch(t){return Object(r.b)(t,"isVarOfTypes"),!0}}},function(t,e,n){"use strict";n.d(e,"a",(function(){return v})),n.d(e,"b",(function(){return S})),n.d(e,"i",(function(){return w})),n.d(e,"d",(function(){return _})),n.d(e,"g",(function(){return E})),n.d(e,"c",(function(){return D})),n.d(e,"h",(function(){return I})),n.d(e,"f",(function(){return T})),n.d(e,"e",(function(){return A}));var r=n(2),i=n(5),o=n(4),c=n(0),a=n(8),s=n(1),u=n(7),d=n(11),l=n(3),f=n(9),b=n(15);function p(t){return function(t){if(Array.isArray(t))return y(t)}(t)||function(t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(t))return Array.from(t)}(t)||h(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function m(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function g(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?m(Object(n),!0).forEach((function(e){j(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):m(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function h(t,e){if(t){if("string"==typeof t)return y(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?y(t,e):void 0}}function y(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function O(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function j(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var v=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),j(this,"bidConfig",void 0),j(this,"bidState",o.c.new),j(this,"_targetingSetID",void 0),j(this,"timing",{setAtTimes:[]}),j(this,"pixelSent",!1),j(this,"useSafeFrames",!1),j(this,"bidReqID",""),j(this,"host",void 0),j(this,"ev",void 0),j(this,"cfe",void 0),j(this,"isAmp",!1),j(this,"doc",void 0),j(this,"inheritSize",void 0),this.bidConfig=e,this._targetingSetID=Object(c.e)(),r.a.getState().config.useSafeFrames&&(this.useSafeFrames=!0),this.useSafeFrames&&Object(c.m)(e,"targeting")&&e.targeting.push("amznhost"),Object(c.m)(e,"meta")?Object(c.k)(e.meta)||(this.reportError({name:"TypeError",message:"'meta' is not an 'array': ".concat(JSON.stringify(e.meta))},"constructor-meta"),e.meta=[]):e.meta=[];try{var n="d";"video"!==this.bidConfig.mediaType&&"v"!==this.bidConfig.mediaType||(n="v");var i=[];Object(c.m)(this.bidConfig,"amzndeals")&&(Object(l.c)("bidType","".concat(n,"-amzndeals")),i=this.bidConfig.amzndeals.map((function(t){return"".concat(t,"amzniid")}))),this.bidConfig.targeting.filter((function(t){return-1!==t.indexOf("amzniid")&&!Object(c.j)(i,t)})).forEach((function(t){return Object(l.c)("bidType","".concat(n,"-").concat(t))})),Object(c.m)(this.bidConfig,"fif")&&"1"===this.bidConfig.fif?Object(l.c)("bidRender","friendly"):Object(l.c)("bidRender","unfriendly")}catch(e){this.reportError(e,"pixeling")}}var e,n;return e=t,(n=[{key:"reportError",value:function(t,e,n){var r=2<arguments.length&&void 0!==n&&n;Object(s.b)(t,"Bid-".concat(e),r)}},{key:"matchesBidCacheId",value:function(t){var e=this;try{return this.bidConfig.targeting.reduce((function(n,r){return n||-1!==r.indexOf("amzniid")&&e.bidConfig[r]===t}),!1)}catch(t){return this.reportError(t,"matchesBidCacheId"),!1}}},{key:"mediaType",get:function(){var t="d";return"video"!==this.bidConfig.mediaType&&"v"!==this.bidConfig.mediaType&&"v"!==this.bidConfig.mediaType_sp||(t="video"),t}},{key:"targeting",get:function(){var t=this;try{return this.bidConfig.targeting.map((function(e){return"amznhost"===e?[e,encodeURIComponent(t.host)]:Object(c.m)(t.bidConfig,e)&&Object(c.k)(t.bidConfig[e])?[e,encodeURIComponent(t.bidConfig[e].join(","))]:Object(c.m)(t.bidConfig,e)?[e,encodeURIComponent(t.bidConfig[e])]:[e,""]})).map((function(t){var e=function(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(t)){var n=[],r=!0,i=!1,o=void 0;try{for(var c,a=t[Symbol.iterator]();!(r=(c=a.next()).done)&&(n.push(c.value),!e||n.length!==e);r=!0);}catch(t){i=!0,o=t}finally{try{r||null==a.return||a.return()}finally{if(i)throw o}}return n}}(t,e)||h(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t,2),n=e[0],r=e[1];return"&".concat(n,"=").concat(r)})).join("")}catch(t){return this.reportError(t,"targeting"),""}}},{key:"bidObject",get:function(){try{var t={slotID:this.bidConfig.slotID,amzniid:this.bidConfig.amzniid,amznbid:this.bidConfig.amznbid,amznp:this.bidConfig.amznp,amznsz:this.bidConfig.amznsz,size:this.bidConfig.amznsz};return"video"===this.mediaType&&(t.mediaType="video",t.qsParams=this.targeting,t.encodedQsParams=encodeURIComponent(this.targeting),t.r_amznbid=this.bidConfig.r_amznbid,t.r_amzniid=this.bidConfig.r_amzniid,t.r_amznp=this.bidConfig.r_amznp),this.useSafeFrames&&(t.amznhost=this.host),t}catch(t){return this.reportError(t,"bidObject",!0),{slotID:"",amzniid:"error",amznbid:"error",amznp:"error",amznsz:"error",size:"error"}}}},{key:"newBidObject",get:function(){var t=this;try{var e={slotID:this.bidConfig.slotID,size:this.bidConfig.amznsz,mediaType:this.mediaType,targeting:{},helpers:{targetingKeys:this.bidConfig.targeting,qsParams:function(){return t.targeting},encodedQsParams:function(){return encodeURIComponent(t.targeting)}}},n=["slotID","size","mediaType"];return this.bidConfig.meta.filter((function(t){return-1===n.indexOf(t)})).forEach((function(n){e[n]=t.bidConfig[n]})),this.bidConfig.targeting.forEach((function(n){e.targeting[n]="amznhost"===n?t.host:t.bidConfig[n]})),void 0!==this.slotID&&-1!==this.slotID.indexOf("_")&&(e.sasTargeting=e.helpers.targetingKeys.map((function(n){return"".concat(n,"_").concat(t.slotID.split("_")[1],"=").concat(e.targeting[n])})).join(";")),e}catch(t){return this.reportError(t,"newBidObject",!0),{slotID:"",size:"",mediaType:"d",targeting:{},helpers:{targetingKeys:[],qsParams:function(){return""},encodedQsParams:function(){return""}}}}}},{key:"slotID",get:function(){try{return this.bidConfig.slotID}catch(t){return this.reportError(t,"slotID"),""}}}])&&O(e.prototype,n),t}(),S=Object(c.f)(o.r);function w(t){var e="validateSupplyChainObject",n=!1;function r(t,r){return Object(s.b)({name:"TypeError",message:r},"".concat(e,"-").concat(t),!0),!(n=!0)}try{return Object(c.l)(t)?(Object(c.m)(t,"complete")?-1===[1,0].indexOf(t.complete)&&r("schain-complete-type","The `schain.complete` property must be a `1` or `0`"):r("schain-complete","The `schain.complete` property must be provided"),Object(c.m)(t,"ver")?Object(f.b)(t.ver,["string"])||r("schain-ver-type","The `schain.ver` property must be a string"):r("schain-ver","The `schain.ver` property must be provided"),Object(c.m)(t,"nodes")?Object(c.k)(t.nodes)?t.nodes.reduce((function(t,e){return Object(c.l)(e)?(Object(c.m)(e,"asi")?Object(f.b)(e.asi,["string"])||r("schain-node-asi-type","All `schain.nodes` items must have an `asi` property of type `string`"):r("schain-node-asi","All `schain.nodes` items must have an `asi` property"),Object(c.m)(e,"sid")?Object(f.b)(e.sid,["string"])||r("schain-node-sid-type","All `schain.nodes` items must have an `sid` property of type `string`"):r("schain-node-sid","All `schain.nodes` items must have an `sid` property"),Object(c.m)(e,"hp")?-1===[1,0].indexOf(e.hp)&&r("schain-node-hp-type","All `schain.nodes` items must have an `hp` property which is `1` or `0`"):r("schain-node-hp","All `schain.nodes` items must have an `hp` property"),Object(f.b)(e.rid,["string","undefined"])||r("schain-node-rid-type","If provided, the `rid` property on an `schain.nodes` item must be of type `string`"),Object(f.b)(e.name,["string","undefined"])||r("schain-node-name-type","If provided, the `name` property on an `schain.nodes` item must be of type `string`"),Object(f.b)(e.domain,["string","undefined"])||r("schain-node-domain-type","If provided, the `domain` property on an `schain.nodes` item must be of type `string`"),t&&!n):r("schain-node-type","All `schain.nodes` items must be objects")}),!n):r("schain-nodes-type","The `schain.nodes` property must be an `Array`"):r("schain-nodes","The `schain.nodes` property must be provided")):r("schain","The `schain` value must be an object")}catch(t){return Object(s.b)(t,e,!0),!1}}function _(t,e,n,d){try{var f=r.a.getState(),m={},h=Object(i.c)("host",f.hosts.DEFAULT_AAX_BID_HOST),y=f.cfg.DTB_PATH,O="bid";f.experiments.shouldUseTestBidEndpoint&&null!==f.cfg.TEST_BID_ENDPOINT&&(O=f.cfg.TEST_BID_ENDPOINT);var j={src:f.config.pubID,u:Object(u.g)(window),pr:Object(u.h)(window),pid:S,cb:t.bidReqID,ws:Object(c.h)(window),v:o.l,t:e,slots:function(t){try{return Object(a.c)(t.map((function(t){var e;if(Object(c.m)(t,"mediaType")&&"video"===t.mediaType)e=t.aaxSlot;else{if(!(Object(c.m)(t,"sizes")&&0<t.sizes.length&&Object(c.m)(t,"slotID")))return Object(s.b)({name:"SlotError",message:"There was an error with the configuration for this slot: ".concat(JSON.stringify(t.rawSlot))},"buildSlotsUrlParam-invalidSlot",!0),{id:"ERROR",mt:o.m.video,error:!0};var n=t.aaxSlot;Object(c.m)(t,"slotName")&&t.slotName!==t.slotID?(Object(l.c)("idRemap","y"),r.a.dispatch({type:"ADD_SLOT_ID",slotID:t.slotID}),n.sd="".concat(r.a.getState().slotIdMap.indexOf(t.slotID)),n.sn=t.slotName):Object(l.c)("idRemap","n"),e=n}return e})).filter((function(t){return!0!==t.error})))}catch(t){return Object(s.b)(t,"buildSlotsUrlParam",!0),""}}(t.validSlots),pj:function(t,e){try{var n=Object(c.l)(t.config.params)?t.config.params:{},r=Object(c.l)(e.params)?e.params:{},i=g(g({},n),r);return 0===Object.keys(i).length?"":Object(a.c)(i)}catch(t){return Object(s.b)(t,"getBidParams",!0),""}}(f,t),cfgv:Object(u.f)(),bb:Object(u.e)(t),schain:function(t){try{var e;return Object(c.m)(t.config,"schain")?(e=t.config.schain,encodeURIComponent(["".concat(e.ver,",").concat(e.complete)].concat(p(e.nodes.map((function(t){return["asi","sid","hp","rid","name","domain"].map((function(e){return Object(c.m)(t,e)?t[e]:""})).map((function(t){return encodeURIComponent(t)})).map((function(t){return t.replace(/\!/g,"%21")})).join(",")})))).join("!"))):""}catch(t){return Object(s.b)(t,"getSupplyChainObject",!0),""}}(f)};if("[]"===j.slots||""===j.slots)throw new Error("No slots available for bid request");if(r.a.dispatch({type:"RECORD_AAX_REQUEST",data:{bidConfig:t,bidReqID:t.bidReqID,timeout:e,ws:j.ws,url:j.u,rqTs:Date.now()}}),f.experiments.chunkRequests){var v=t.bidReqID.split("-");r.a.dispatch({type:"RECORD_NETWORK_EXCHANGE",fid:v[0],networkID:parseInt(v[1],10),timestamp:Date.now(),exchangeType:"request"})}f.config.isSelfServePub&&(j.pubid=j.src,j.src=600);var w=Object(u.d)();w.fb&&(m[917]=w.fb,j[o.j.aps_ext_917]=Object(a.c)(m));var _=Object(i.c)("bidParams");Object(c.l)(_)&&(j=g(g({},j),_)),Object(c.l)(n)&&(Object(c.m)(n,"enabled")&&(j.gdpre=encodeURIComponent(n.enabled)),Object(c.m)(n,"consent")&&(j.gdprc=encodeURIComponent(n.consent)),Object(c.m)(n,"log")&&(j.gdprl=Object(a.c)(n.log))),Object(c.m)(f.config,"useSafeFrames")&&f.config.useSafeFrames&&(j.sf="1");var E=Object(b.b)();E&&(Object(l.c)("id","bidReq-attachToken"),d.at=E),j.vm=d&&0!==Object.keys(d).length?Object(a.c)({ids:d}):"";var D=Object.keys(j).filter((function(t){return Object(c.m)(j,t)&&"undefined"!==j[t]&&""!==j[t]&&null!==j[t]})).map((function(t){return"".concat(t,"=").concat(j[t])})).join("&");w.cookiesParams&&(D+=w.cookiesParams);var I="".concat(o.s).concat(h).concat(y,"/").concat(O,"?").concat(D);return r.a.dispatch({type:"RECORD_AAX_REQ_PROP",bidReqID:t.bidReqID,key:"urlLength",value:I.length}),I}catch(t){return Object(s.b)(t,"buildBidUrl",!0),""}}function E(t,e){try{return Object(c.m)(t,"config")&&Object(c.m)(t.config,"deals")&&!0===t.config.deals||!0===e.needNewBidObject}catch(t){return Object(s.b)(t,"isNewBidObjectRequired"),!1}}function D(t,e,n){try{var r,i=t.map(d.c),a=e.slots.filter(d.d).map(d.c).filter((function(t){return!Object(c.j)(i,t)}));return r=n?o.u.bidInFlight:o.u.noBid,t.concat(a.map((function(t){return new v({size:"0x0",crid:"",slotID:t,mediaType:"d",meta:["slotID","mediaType","size"],amznbid:e=r,amzniid:"",amznp:e,amznsz:"0x0",targeting:["amzniid","amznbid","amznp","amznsz"]});var e})))}catch(e){return Object(s.b)(e,"addStateTrackingBidsToRealBids"),t}}function I(t){try{if(Object(c.m)(t,"slots")){var e=r.a.getState().slotIdMap;t.slots.forEach((function(t){null!==t.slotID.match(/^\d+$/)&&parseInt(t.slotID,10)<e.length&&(t.slotID=e[parseInt(t.slotID,10)])}))}}catch(t){Object(s.b)(t,"mapSlotIDValues")}}function T(t){try{if(Object(c.j)(r.a.getState().displayAdServer.noBidSlotIDs,t.slotID))return!1;var e=r.a.getState().AAXReqs.filter((function(e){return e.bidReqID===t.bidReqID}))[0];return!(Object(c.m)(e,"rqTs")&&Date.now()-e.rqTs>24e4)&&(!(Object(c.m)(e,"url")&&!Object(c.b)(e.url,Object(u.g)(window)))&&t.bidState!==o.c.rendered)}catch(e){return Object(s.b)(e,"isBidEligible"),!1}}function A(t){try{var e=t.map(d.c),n=r.a.getState();return Object.keys(n.slotBids).filter((function(t){return Object(c.j)(e,t)})).reduce((function(t,e){var i=n.slotBids[e].filter((function(t){return t.bidState===o.c.new})).filter(T);if(0<i.length){var c=i[i.length-1];r.a.dispatch({type:"BID_STATE_CHANGE",slotID:e,_targetingSetID:c._targetingSetID,bidState:o.c.exposed}),t[e]=c}return t}),{})}catch(t){return Object(s.b)(t,"getNewSlotBidsAndExposeForRequestedSlots"),{}}}},function(t,e,n){"use strict";n.d(e,"b",(function(){return o})),n.d(e,"a",(function(){return c})),n.d(e,"d",(function(){return a})),n.d(e,"c",(function(){return s}));var r=n(1),i=n(0);function o(t){var e=[];try{t.hasAdServerObjectLoaded()&&(e=t.getSlots())}catch(t){Object(r.b)(t,"getDisplayAdServerSlots")}return e}function c(t){try{return Object(i.m)(t,"sizes")&&Object(i.k)(t.sizes)&&0!==t.sizes.length}catch(t){return Object(r.b)(t,"doesSlotHaveSizes"),!1}}function a(t){try{return"video"!==t.mediaType}catch(t){return Object(r.b)(t,"isDisplaySlot"),!0}}function s(t){try{return t.slotID}catch(t){return Object(r.b)(t,"getSlotID"),""}}},function(t,e,n){"use strict";n.d(e,"a",(function(){return r})),n.d(e,"c",(function(){return i})),n.d(e,"b",(function(){return o})),n.d(e,"e",(function(){return c})),n.d(e,"f",(function(){return a})),n.d(e,"d",(function(){return s}));function r(t,e){try{return"number"!=typeof t[e]?0:Math.round(t[e])}catch(t){return 0}}function i(t,e){try{var n=o(t,e)[0];if(void 0!==n)return n}catch(t){}return null}function o(t,e){try{return t.performance.getEntriesByType("resource").filter((function(t){return e.test(t.name)}))}catch(t){return[]}}function c(t,e){try{var n=t.performance.timing[e];return void 0===n?0:n}catch(t){return 0}}function a(t){try{if(0===["redirectStart","redirectEnd","domainLookupStart","domainLookupEnd","connectStart","connectEnd","requestStart","responseStart","secureConnectionStart"].reduce((function(e,n){return e+r(t,n)}),0))return null;var e=r(t,"fetchStart");return["domainLookupStart","domainLookupEnd","connectStart","connectEnd"].reduce((function(n,i){return n&&r(t,i)===e}),!0)}catch(t){return null}}function s(){try{var t=window.performance.timeOrigin;return void 0===t&&(t=window.performance.timing.navigationStart),t}catch(t){return 0}}},function(t,e,n){"use strict";n.d(e,"b",(function(){return g})),n.d(e,"c",(function(){return h})),n.d(e,"a",(function(){return v}));var r=n(0),i=n(1),o=n(3);function c(t){return(c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function a(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function s(t,e,n){return(s="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(t,e,n){var r=function(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=l(t)););return t}(t,e);if(r){var i=Object.getOwnPropertyDescriptor(r,e);return i.get?i.get.call(n):i.value}})(t,e,n||t)}function u(t,e){return(u=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function d(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function l(t){return(l=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function f(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function b(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function p(t,e,n){return e&&b(t.prototype,e),n&&b(t,n),t}function m(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var g=function(){function t(){f(this,t),m(this,"isSupported",!1),m(this,"needNewBidObject",!1)}return p(t,[{key:"cmdQueuePush",value:function(){}},{key:"slotRenderEndedEvent",value:function(){}},{key:"setTargeting",value:function(){}},{key:"getTargeting",value:function(){return[]}},{key:"clearTargeting",value:function(){}},{key:"hasAdServerObjectLoaded",value:function(){return!1}},{key:"isCommandQueueDefined",value:function(){return!1}},{key:"getSlots",value:function(){return[]}}]),t}(),h=function(){function t(e,n,r){f(this,t),m(this,"mediaType","display"),m(this,"slotID",void 0),m(this,"slotName",void 0),m(this,"slotParams",void 0),m(this,"rawSlot",void 0),this.slotID=e,this.slotName=n,this.slotParams=r}return p(t,[{key:"reportError",value:function(t,e,n){var r=2<arguments.length&&void 0!==n&&n;Object(i.b)(t,"Slot-".concat(e),r)}},{key:"setTargeting",value:function(){}},{key:"getTargeting",value:function(){return[]}},{key:"clearTargeting",value:function(){}},{key:"isValid",value:function(){function t(t,e){return"There was an issue with the configuration for this slot: ".concat(JSON.stringify(e),"\n")+t.map((function(t){return"- ".concat(t)})).join("\n")}try{var e=[],n=[];if(void 0===this.slotID?e.push("'slotID' must be provided and a string"):"string"!=typeof this.slotID&&n.push("'slotID' must be a string"),"display"===this.mediaType&&0===this.sizes.length&&e.push("'sizes' must have at least 1 valid item"),Object(r.m)(this.rawSlot,"floor")&&Object(r.l)(this.rawSlot.floor)){var i=this.rawSlot.floor,o=i.currency,c=i.value;"USD"!==o&&n.push("'floor' currency only supports USD"),S(c)||n.push("'floor' value must be a positive integer")}return 0<e.length?(this.reportError({name:"SlotValidationError",message:t([].concat(e,n),this.rawSlot)},"validation-error",!0),!1):(0<n.length&&this.reportError({name:"SlotValidationError",message:t(n,this.rawSlot)},"validation-warn",!0),!0)}catch(t){return this.reportError(t,"isValid",!0),!0}}},{key:"sizes",get:function(){return[]}},{key:"floor",get:function(){}},{key:"slotConfig",get:function(){try{return{slotID:this.slotID,slotName:this.slotName,sizes:this.sizes}}catch(t){return this.reportError(t,"slotConfig"),{slotID:"",slotName:"",sizes:[]}}}},{key:"aaxSlotParams",get:function(){var t=this;try{return Object(r.m)(this,"slotParams")&&Object(r.l)(this.slotParams)?Object.keys(this.slotParams).filter((function(e){return function t(e){try{return Object(r.k)(e)?0<e.length&&e.reduce((function(e,n){return e&&t(n)}),!0):"string"==typeof e&&0<e.length}catch(e){return Object(i.b)(e,"validateSlotParamValue"),!1}}(t.slotParams[e])})).reduce((function(e,n){return e[n]=t.slotParams[n],e}),{}):void 0}catch(t){return this.reportError(t,"aaxSlotParams"),this.slotParams}}},{key:"aaxSlot",get:function(){try{Object(o.c)("slotType","display");var t={sd:this.slotID,s:this.sizes.filter(r.k).map((function(t){return t.join("x")})),kv:this.aaxSlotParams};return this.slotID!==this.slotName&&(t.sn=this.slotName),this.floor&&(t.fc=this.floor.currency,t.fp=this.floor.value),t}catch(t){return this.reportError(t,"aaxSlot"),{sd:"",s:[],kv:{}}}}}]),t}(),y=[],O=/^[0-9]+x[0-9]+$/,j=/^[0-9]+$/,v=function(){!function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&u(t,e)}(e,h);var t=function(t){var e=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var n,r,i,o=l(t);if(e){var a=l(this).constructor;n=Reflect.construct(o,arguments,a)}else n=o.apply(this,arguments);return r=this,!(i=n)||"object"!==c(i)&&"function"!=typeof i?d(r):i}}(e);function e(n){var i;f(this,e),m(d(i=t.call(this,n.slotID,n.slotName,n.slotParams)),"rawSlot",void 0),m(d(i),"hasReportedWorkingInvalidSizeError",!1),i.mediaType="video"===n.mediaType?"video":"display",i.rawSlot=function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?a(Object(n),!0).forEach((function(e){m(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}({},n);try{Object(r.m)(i.rawSlot,"sizes")&&Object(r.k)(i.rawSlot.sizes)&&(i.rawSlot.sizes=i.rawSlot.sizes.filter((function(t){return"fluid"!==t})))}catch(n){i.reportError(n,"sizeFilter")}return i}return p(e,[{key:"reportError",value:function(t,e,n){var r=2<arguments.length&&void 0!==n&&n;Object(i.b)(t,"AaxSlot-".concat(e),r)}},{key:"aaxSlot",get:function(){try{if("video"!==this.rawSlot.mediaType)return s(l(e.prototype),"aaxSlot",this);Object(o.c)("slotType","video");var t={id:this.slotID,mt:"v",kv:this.aaxSlotParams};return 0<this.sizes.length&&(t.s=this.sizes.filter(r.k).map((function(t){return t.join("x")}))),this.floor&&(t.fc=this.floor.currency,t.fp=this.floor.value),t}catch(t){return this.reportError(t,"aaxSlot"),{sd:"",s:[]}}}},{key:"sizes",get:function(){try{var t=[];if(Object(r.m)(this.rawSlot,"sizes")&&Object(r.k)(this.rawSlot.sizes)){var e="2d",n=this.rawSlot.sizes;!(0<n.length)||Object(r.k)(n[0])||"string"==typeof n[0]&&O.test(n[0])||(e="1d",n=[n]),t=n.filter((function(t){return function(t,e){function n(t){var n=JSON.stringify(t);-1===y.indexOf(n)&&(y.push(n),Object(i.b)({name:"AaxSlot-InvalidSize",message:"Invalid Slot Size: ".concat(JSON.stringify(e))},"isValidSize-invalid"))}try{return"string"==typeof e&&O.test(e)?(Object(o.c)("AaxSlotSizes","".concat(t,"-compiled")),!0):Object(r.k)(e)&&1!==e.length?(2<e.length&&n(e),e.slice(0,2).reduce((function(e,n){return e?!("number"!=typeof n&&"string"!=typeof n||"string"==typeof n&&!j.test(n)||("string"==typeof n?Object(o.c)("AaxSlotSizes","".concat(t,"-string")):Object(o.c)("AaxSlotSizes","".concat(t,"-number")),0)):e}),!0)):(n(e),!1)}catch(n){return Object(i.b)(n,"isValidSize"),!0}}(e,t)})).map((function(t){return Object(r.k)(t)?t:t.split("x").map((function(t){return parseInt(t,10)}))}))}return t}catch(t){return this.reportError(t,"sizes"),[]}}},{key:"floor",get:function(){var t;try{Object(r.m)(this.rawSlot,"floor")&&"USD"===this.rawSlot.floor.currency&&S(this.rawSlot.floor.value)?(t=this.rawSlot.floor,Object(o.c)("customFloor","y")):Object(o.c)("customFloor","n")}catch(t){this.reportError(t,"floor")}return t}}]),e}();function S(t){return"number"==typeof t&&0<t&&t%1==0}},function(t,e,n){"use strict";n.d(e,"a",(function(){return f})),n.d(e,"b",(function(){return h})),n.d(e,"c",(function(){return y}));var r=n(1),i=n(3),o=n(0);function c(t){return(c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function a(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function s(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?a(Object(n),!0).forEach((function(e){u(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function u(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}Number.isInteger=Number.isInteger||function(t){return"number"==typeof t&&isFinite(t)&&Math.floor(t)===t};var d="__cmp",l="__tcfapi";function f(t,e){var n=!1,a={log:{status:"no-status"}},u=50,f="global-func-error";function b(){n||(n=!0,e(s(s({},a),{},{log:s({},a.log)})))}e=Object(r.d)(e,"GdprCallback");var p="null";function m(t,e){try{if(!e||!Object(o.l)(t))return a.log.status="".concat(p,"-error"),void b();a.log.status="".concat(p,"-success"),Object(o.m)(t,"tcString")?a.consent=t.tcString:Object(o.m)(t,"consentData")&&(a.consent=t.consentData),a.enabled=t.gdprApplies?1:0,0===a.enabled&&delete a.consent,a.gdprApplies=t.gdprApplies,b()}catch(t){a.log.status="func-error",b(),Object(r.b)(t,"cmpCallback-".concat(p),!0)}}try{if(!1===(t=Object(o.l)(t)?s({},t):{}).enabled||0===t.enabled?(a.log.status="explicit-no-gdpr",a.enabled=0):!0===t.enabled||1===t.enabled?(a.log.status=Object(o.m)(t,"consent")?"explicit-consent-passed":"explicit-no-consent-passed",a.enabled=1,a.consent=t.consent):Object(o.m)(t,"enabled")&&(a.log.status=Object(o.m)(t,"consent")?"malformed-with-consent":"malformed-without-consent",a.consent=t.consent,Number.isInteger(t.enabled)?a.enabled=t.enabled:a.enabled=1),Object(o.m)(t,"enabled")&&(a.log.enabled=t.enabled),Object(o.m)(t,"cmpTimeout")&&Number.isInteger(t.cmpTimeout)&&(u=t.cmpTimeout,a.log.cmpTimeout=u),void 0!==a.enabled)return Object(i.c)("gdpr","pub-api"),Object(o.m)(a,"consent")&&"string"!=typeof a.consent&&(delete a.consent,Object(r.b)(new Error("Invalid consent: must be string, given ".concat(c(a.consent))),"getGdprConfig-pub-consent-invalid",!0)),void b()}catch(t){Object(r.b)(t,"getGdprConfig-parseConfig",!0)}try{if(Object(o.m)(window,l)&&"function"==typeof window[l])p="tcfv2";else{if(!Object(o.m)(window,d)||"function"!=typeof window[d])return Object(i.c)("gdpr","no-cmp"),a.log.status="no-cmp",void b();p="cmp"}Object(i.c)("gdpr",p),setTimeout((function(){a.log.status="".concat(p,"-timeout"),b()}),u),f="".concat(p,"-internal-error"),"cmp"===p?window[d]("getConsentData",null,m):window[l]("getTCData",2,m)}catch(t){a.log.status=f,b(),Object(r.b)(t,"getGdprConfig-".concat(f),!0)}}function b(t){for(var e=[],n=-1;0<=(n=t.indexOf("1",n+1));)e.push(n+1);return e}function p(t){for(var e=[],n=parseInt(g(t,12),2),r=0;r<n;r++){var i=parseInt(g(t,1),2),o=parseInt(g(t,16),2);if(e.push(o),i)for(var c=parseInt(g(t,16),2),a=o+1;a<=c;a++)e.push(a)}return e}function m(t){var e=parseInt(g(t,16),2);return parseInt(g(t,1),2)?p(t):b(g(t,e))}function g(t,e){var n=t.bits.substr(t.index,e);return t.index+=e,n}function h(t){try{if(!t)return!1;var e=function(t){try{for(var e=(t=(t=t.replace(/-/g,"+")).replace(/_/g,"/")).split(".")[0],n=window.atob(e),i="",o=0;o<n.length;o++)i+=("0000000"+n.charCodeAt(o).toString(2)).substr(-8);return i}catch(t){return Object(r.b)(t,"TCFToBinary",!0),""}}(t);if(e.length<230)return!1;var n={},i={bits:e,index:0};return n.version=parseInt(g(i,6),2),2===n.version&&(n.created=parseInt(g(i,36),2),n.lastUpdated=parseInt(g(i,36),2),n.cmpId=parseInt(g(i,12),2),n.cmpVersion=parseInt(g(i,12),2),n.consentScreen=parseInt(g(i,6),2),n.consentLanguage=String.fromCharCode(parseInt(g(i,6),2)+65)+String.fromCharCode(parseInt(g(i,6),2)+65),n.vendorListVersion=parseInt(g(i,12),2),n.tcfPolicyVersion=parseInt(g(i,6),2),n.isServiceSpecific="1"===g(i,1),n.useNonStandardStacks="1"===g(i,1),n.specialFeatureOptIns=b(g(i,12)),n.purposesConsent=b(g(i,24)),n.purposesLITransparency=b(g(i,24)),n.purposeOneTreatment="1"===g(i,1),n.publisherCC=String.fromCharCode(parseInt(g(i,6),2)+65)+String.fromCharCode(parseInt(g(i,6),2)+65),n.vendorConsents=m(i),n.vendorLegitimateInterests=m(i),n.publisherRestrictions=function(t){for(var e=parseInt(g(t,12),2),n=[],r=0;r<e;r++){var i=parseInt(g(t,6),2),o=parseInt(g(t,2),2);n.push({purposeId:i,restrictionType:o,vendorIds:p(t)})}return n}(i),n)}catch(t){return Object(r.b)(t,"parseTCFString",!0),!1}}function y(t,e){if(!t)return!!window.apstag&&!window.apstag.isGDPRRegion&&!0!==e;if(window.apstag&&!window.apstag.isGDPRRegion&&!1===e)return!0;if(2!==t.version)return!1;if(t.useNonStandardStacks)return!1;if(!t.isServiceSpecific)return!1;if(t.vendorListVersion<51)return!1;var n=t.publisherRestrictions.filter((function(t){return 1===t.purposeId&&t.vendorIds.includes(793)}));if(0===n.length)return O(t);switch(n[0].restrictionType){case 0:case 2:return!1;default:return O(t)}}function O(t){return!(!Object(o.m)(t,"vendorConsents")||!Object(o.m)(t,"purposesConsent"))&&t.vendorConsents.includes(793)&&t.purposesConsent.includes(1)}},function(t,e,n){"use strict";n.d(e,"b",(function(){return h})),n.d(e,"a",(function(){return y})),n.d(e,"d",(function(){return j})),n.d(e,"c",(function(){return v}));var r=n(1),i=n(14),o=n(8),c=n(3),a=n(2),s=n(7),u=n(0);function d(t){return(d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}var l=["email"],f=/@/,b=/^[0-9a-fA-F]{64}$/,p="noconsent";function m(t){return t===p?"AMZN-NoCookieConsent":"AMZN-Token"}function g(t,e,n){var i=0<arguments.length&&void 0!==t?t:"",o=1<arguments.length&&void 0!==e?e:0,c=2<arguments.length&&void 0!==n?n:"token";try{var a=new Date(o).toUTCString();document.cookie="".concat(m(c),"=").concat(i,"; expires=").concat(a,"; path=/;")}catch(t){Object(r.b)(t,"setAmznToken-".concat(c),!0)}}function h(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:"token";try{var e=Object(u.d)().filter((function(e){return e[0]===m(t)}));return 0===e.length?"":e[0][1]}catch(e){return Object(r.b)(e,"getAmznToken-".concat(t),!0),""}}function y(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"api";try{if(void 0!==t&&"function"!=typeof t)throw new Error("Callback function must be a function, ".concat(d(t)," provided"));"function"!=typeof t&&(t=function(){}),g(),g("",0,"noconsent"),Object(c.c)("id","d-".concat(e))}catch(t){Object(r.b)(t,"deleteIdentity",!0)}t()}function O(t,e,n){try{e=Object(s.a)(e);var i=a.a.getState().config;if(!Object(u.m)(i,"pubID"))throw new Error("apstag.init must be called before ID functions");var d={url:"https://tk.amazon-adsystem.com/envelope",onload:function(t){try{if(t.readyState===XMLHttpRequest.DONE&&200===t.status){var n=JSON.parse(t.responseText);if("string"!=typeof n.AIPToken||"number"!=typeof n.cookieExpiry)return e(),void Object(r.b)(new Error("Invalid AIPES response"),"callAipes-response");""===n.AIPToken?(Object(c.c)("id","endReqAipes-tokenEmpty"),g("1",n.cookieExpiry,p)):(Object(c.c)("id","endReqAipes-tokenAvailable"),g(n.AIPToken,n.cookieExpiry),Object(c.f)())}else t.readyState===XMLHttpRequest.DONE&&Object(r.b)(new Error("AIPES response code: ".concat(t.status)),"callAipes-onload",!0)}catch(t){Object(r.b)(t,"callAipes-onload",!0)}e()},onerror:function(){Object(r.b)(new Error("AIPES response code: ".concat(this.status)),"callAipes-onerror",!0),e()},ontimeout:function(){Object(r.b)(new Error("AIPES request timeout"),"callAipes-ontimeout",!0),e()},headers:{"Content-Type":"application/json"},body:function(t,e,n){try{var i={publisherId:e.pubID,hashedRecords:t.hashedRecords};return n.enabled?(i.gdpr=1,void 0!==n.consent&&(i.gdprConsent=n.consent)):0===n.enabled&&(i.gdpr=0),void 0!==t.ttl&&(i.ttl=t.ttl),JSON.stringify(i)}catch(t){return Object(r.b)(t,"buildAipesBody",!0),""}}(t,i,n)};Object(c.c)("id","startReqAipes"),Object(o.d)(d)}catch(t){Object(r.b)(t,"callAipes",!0),e()}}function j(t,e){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:"api";"function"!=typeof e&&(e=function(){});try{if(!Object(u.l)(t))throw new Error("'tokenConfig' must be an object, ".concat("object"===d(t)?"null":d(t)," provided"));if(t.optOut)return void y(e,"u-oo");if(y((function(){}),"u"),Object(c.c)("id","u-".concat(n)),!function(t){try{var e=[];return!Object(u.m)(t,"gdpr")||Object(u.l)(t.gdpr)&&!Object(u.k)(t.gdpr)?Object(u.m)(t,"gdpr")&&(Object(u.m)(t.gdpr,"enabled")&&-1===[!0,!1].indexOf(t.gdpr.enabled)&&e.push("`gdpr.enabled` must be a boolean"),Object(u.m)(t.gdpr,"consent")&&"string"!=typeof t.gdpr.consent&&e.push("'gdpr.consent' must be a valid IAB-formatted string")):e.push("`gdpr` must be an Object"),Object(u.m)(t,"optOut")&&-1===[!0,!1].indexOf(t.optOut)&&e.push("'optOut' must be a boolean"),Object(u.m)(t,"hashedRecords")&&Object(u.k)(t.hashedRecords)?1!==t.hashedRecords.length?e.push("'hashedRecords' must contain exactly one item"):t.hashedRecords.forEach((function(t){Object(u.m)(t,"type")&&-1!==l.indexOf(t.type)||e.push("'type' must be 'email' in item '".concat(JSON.stringify(t),"'")),Object(u.m)(t,"encrypted")&&"boolean"!=typeof t.encrypted&&e.push("'encrypted' must be a boolean in item '".concat(JSON.stringify(t),"'")),Object(u.m)(t,"record")&&"string"==typeof t.record?t.encrypted||b.test(t.record)?t.encrypted&&f.test(t.record)&&e.push("'record' must NOT be an un-hashed, un-encrypted email"):e.push("'record' must be a SHA256 hash in item '".concat(JSON.stringify(t),"'")):e.push("'record' must be a string in item '".concat(JSON.stringify(t),"'"))})):e.push("'hashedRecords' must be an array"),Object(u.m)(t,"ttl")&&("number"!=typeof t.ttl||isNaN(t.ttl)||t.ttl<=0||t.ttl%1!=0)&&e.push("'ttl' must be a positive integer"),0<e.length?void Object(r.b)({name:"TokenConfigValidationError",message:"There was an issue with the TokenConfig provided ".concat(JSON.stringify(t),":\n")+e.map((function(t){return"- ".concat(t)})).join("\n")},"validateTokenConfig-invalid",!0):1}catch(t){return void Object(r.b)(t,"validateTokenConfig",!0)}}(t))return void e();Object(i.a)(t.gdpr,O.bind(null,t,e))}catch(t){Object(r.b)(t,"updateIdentity",!0),e()}}function v(t,e){"function"!=typeof e&&(e=function(){});try{if(!Object(u.l)(t))throw new Error("'tokenConfig' must be an object, ".concat("object"===d(t)?"null":d(t)," provided"));if(t.optOut)return void y(e,"r-oo");if(""!==h("noconsent"))return void e();if(""!==h())return e(),void Object(c.c)("id","r-noop");j(t,e,"r")}catch(t){Object(r.b)(t,"renewIdentity",!0),e()}}},function(t,e,n){"use strict";n.d(e,"d",(function(){return o})),n.d(e,"c",(function(){return c})),n.d(e,"b",(function(){return a})),n.d(e,"g",(function(){return d})),n.d(e,"a",(function(){return p})),n.d(e,"e",(function(){return m})),n.d(e,"f",(function(){return g}));var r=n(1),i=n(0);function o(t,e){try{if(Object(i.m)(e,"slotID")){var n=e.slotID,o=t.getElementById(n);if(o instanceof HTMLDivElement)return o}}catch(t){Object(r.b)(t,"getVideoDivElement-outstream")}}function c(t,e){try{Object(i.m)(t,"bidID")&&(e+="b=".concat(t.bidID)),Object(i.m)(t,"pp")&&(e+="&pp=".concat(t.pp)),e+="&rnd=".concat(Object(i.e)())}catch(t){Object(r.b)(t,"constructVastTag")}return e}function a(t,e){try{return e.replace("$$apstagVastTag$$",t)}catch(t){return Object(r.b)(t,"constructVastTag"),""}}var s={started:!1,completed:!1,loaded:!1,isPaused:!1},u={root:null,rootMargin:"0px",threshold:.5};function d(t,e){try{if(window.addEventListener("message",l,!1),window.IntersectionObserver){var n=new window.IntersectionObserver((function(o){o.forEach((function(o){.5<o.intersectionRatio&&e.contentWindow&&(function(t,e){try{null!==t.contentDocument&&Object(i.j)(["complete","interactive"],t.contentDocument.readyState)?b(t,e):null!==t.contentDocument&&"uninitialized"!==t.contentDocument.readyState?t.contentDocument.addEventListener("DOMContentLoaded",(function(){b(t,e)})):t.addEventListener("load",(function(){b(t,e)})),setTimeout(b,1e3,!0)}catch(t){Object(r.b)(t,"loadVideoAd")}}(e,t),n.disconnect())}))}),u);n.observe(t)}else Object(r.b)({name:"IntersectionObserver",message:"IntersectionObserver not supported "},"startVideoAndHandlePlayback")}catch(t){Object(r.b)(t,"startVideoAndHandlePlayback")}}function l(t){if(t.origin===window.top.location.origin&&!0===t.data.apsVideoPlayer)switch(t.data.event){case"completed":s.completed=!0;break;case"loaded":s.loaded=!0}}function f(t,e){try{if(window.IntersectionObserver){var n=new window.IntersectionObserver((function(e){e.forEach((function(e){s.completed&&n.disconnect(),e.intersectionRatio<.5&&!s.isPaused?t.contentWindow&&t.contentWindow.adsM&&(t.contentWindow.adsM.pause(),s.isPaused=!0):s.isPaused&&t.contentWindow&&t.contentWindow.adsM&&(t.contentWindow.adsM.play(),s.isPaused=!1)}))}),{threshold:.5});n.observe(e)}}catch(e){Object(r.b)(e,"handleAutoPauseAndPlay")}}function b(t,e){t.contentWindow&&!s.started&&(s.started=!0,function(t,e,n){var r=Number(new Date)+(e||2e3);return n=n||100,new Promise((function e(i,o){var c=t();c?i(c):Number(new Date)<r?setTimeout(e,n,i,o):o(new Error("apsVideoPlayer timed out"))}))}((function(){return s.loaded}),5e3,150).then((function(){t.contentWindow&&t.contentWindow.adsM&&(t.contentWindow.adsM.play(),f(t,e))})).catch((function(){f(t,e),Object(r.b)({name:"VideoPlayerTimeout",message:"video player took more than 5 seconds to load"},"startAd")})))}function p(t,e){try{e&&e.appendChild(t)}catch(t){Object(r.b)(t,"_appendDivElement")}}function m(t,e){try{t.appendChild(e)}catch(t){Object(r.b)(t,"_insertVideoIframeInsideDiv")}}function g(t){var e=document.createElement("div");return e.style.width="".concat(t[0],"px"),e.style.height="".concat(t[1],"px"),e.style.margin="0 auto",e.id="apsVideoDiv-".concat(Object(i.e)()),e}},function(t,e,n){"use strict";n.d(e,"b",(function(){return m})),n.d(e,"a",(function(){return g}));var r=n(0),i=n(13),o=n(1);function c(t){return(c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function a(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function s(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function u(t,e,n){return e&&s(t.prototype,e),n&&s(t,n),t}function d(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&function(t,e){(Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}(t,e)}function l(t){var e=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var n,r,i,o=b(t);if(e){var a=b(this).constructor;n=Reflect.construct(o,arguments,a)}else n=o.apply(this,arguments);return r=this,!(i=n)||"object"!==c(i)&&"function"!=typeof i?f(r):i}}function f(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function b(t){return(b=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function p(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var m=function(){d(e,i.c);var t=l(e);function e(n){var r;return a(this,e),p(f(r=t.call(this,n.getSlotElementId(),n.getAdUnitPath())),"rawSlot",void 0),p(f(r),"mediaType","display"),r.rawSlot=n,r}return u(e,[{key:"reportError",value:function(t,e,n){var r=2<arguments.length&&void 0!==n&&n;Object(o.b)(t,"GptSlot-".concat(e),r)}},{key:"setTargeting",value:function(t,e){try{this.rawSlot.setTargeting(t,e)}catch(t){this.reportError(t,"setTargeting")}}},{key:"getTargeting",value:function(t){try{return this.rawSlot.getTargeting(t)}catch(t){return this.reportError(t,"getTargeting"),[]}}},{key:"clearTargeting",value:function(t){try{this.rawSlot.clearTargeting(t)}catch(t){this.reportError(t,"clearTargeting")}}},{key:"sizes",get:function(){try{var t=Object(r.h)(window).split("x").map((function(t){return Number(t)})),e=this.rawSlot.getSizes(t[0],t[1]);return null===e?[]:e.filter((function(t){return"fluid"!==t})).map((function(t){return[t.getWidth(),t.getHeight()]}))}catch(t){return this.reportError(t,"sizes"),[]}}}]),e}(),g=function(){d(e,i.b);var t=l(e);function e(){var n;a(this,e);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return p(f(n=t.call.apply(t,[this].concat(i))),"isSupported",!0),n}return u(e,[{key:"reportError",value:function(t,e){Object(o.b)(t,"GoogletagAdServer-".concat(e))}},{key:"cmdQueuePush",value:function(t){try{window.googletag.cmd.push(t)}catch(t){this.reportError(t,"cmdQueuePush")}}},{key:"slotRenderEndedEvent",value:function(t){try{window.googletag.pubads().addEventListener("slotRenderEnded",(function(e){var n=new m(e.slot);t(n)}))}catch(t){this.reportError(t,"slotRenderEndedEvent")}}},{key:"setTargeting",value:function(t,e){try{window.googletag.pubads().setTargeting(t,e)}catch(t){this.reportError(t,"setTargeting")}}},{key:"getTargeting",value:function(t){try{return window.googletag.pubads().getTargeting(t)||[]}catch(t){return this.reportError(t,"getTargeting"),[]}}},{key:"clearTargeting",value:function(t){try{window.googletag.pubads().clearTargeting(t)}catch(t){this.reportError(t,"clearTargeting")}}},{key:"hasAdServerObjectLoaded",value:function(){try{return Object(r.m)(window,"googletag")&&Object(r.m)(window.googletag,"apiReady")&&!0===window.googletag.apiReady}catch(t){return this.reportError(t,"hasAdServerObjectLoaded"),!1}}},{key:"isCommandQueueDefined",value:function(){try{return Object(r.m)(window,"googletag")&&Object(r.m)(window.googletag,"cmd")}catch(t){return this.reportError(t,"isCommandQueueDefined"),!1}}},{key:"getSlots",value:function(){try{return window.googletag.pubads().getSlots().map((function(t){return new m(t)}))}catch(t){return this.reportError(t,"getSlots"),[]}}}]),e}()},function(t,e,n){"use strict";n.d(e,"c",(function(){return o})),n.d(e,"a",(function(){return c})),n.d(e,"b",(function(){return a}));var r=n(1),i=n(0);function o(t){try{return!(!Object(i.m)(t,"$sf")||!Object(i.m)(t.$sf,"ext"))}catch(t){return Object(r.b)(t,"isSafeFrame"),!1}}function c(t,e){try{var n=e.innerWidth,i=e.innerHeight,o=parseInt(t[0],10),c=parseInt(t[1],10),a=o-n,s=c-i,u=e.sfAPI||e.$sf.ext;u&&(n===o&&i===c||(u.register(o,c),u.expand({r:a,b:s,push:!0})))}catch(t){Object(r.b)(t,"expandSf")}}function a(t){try{return 1===t.innerWidth&&1===t.innerHeight}catch(t){return Object(r.b)(t,"is1x1Creative"),!1}}},function(t,e,n){"use strict";n.d(e,"b",(function(){return r})),n.d(e,"d",(function(){return i})),n.d(e,"c",(function(){return u})),n.d(e,"a",(function(){return y}));var o=n(8),d=n(1),l=n(4),c=n(5),f=n(2),a=n(7),b=n(0),p=n(10),m=n(3),g=n(14);function r(){var r=f.a.getState().experiments.shouldSampleLatency,i=Date.now(),t={url:s(),withCredentials:!0,onload:function t(e){if(200===e.status)try{f.a.dispatch({type:"RECORD_LIBRARY_LOAD_CALL_LATENCY",latency:Date.now()-i}),r&&setTimeout(m.d,1e3);var n=JSON.parse(e.response);eval(n["3pvendor"]),Object(g.a)(f.a.getState().config.gdpr,(function(t){if(t){var e=Object(g.b)(t.consent);Object(b.i)()&&Object(g.c)(e,t.gdprApplies)&&window.localStorage.setItem(l.e,"1")}}))}catch(t){Object(d.b)(t,"load3PLibraryConfig-onload",!0)}},onerror:function(){}};try{Object(o.d)(t)}catch(t){Object(d.b)(t,"load3PLibraryConfig",!0)}r&&setTimeout(m.d,1e3)}function s(){try{var t,e=f.a.getState(),n=e.config,r=Object(c.c)("host",e.hosts.DEFAULT_AAX_BID_HOST),i=e.cfg.LIB_CONFIG_PATH;t={src:n.isSelfServePub?l.t:n.pubID,u:Object(a.g)(window)},n.isSelfServePub&&(t.pubid=n.pubID);var o=Object.keys(t).map((function(e){return"".concat(e,"=").concat(t[e])})).join("&");return"".concat(l.s).concat(r).concat(i,"?").concat(o)}catch(e){return Object(d.b)(e,"buildLibraryConfigUrl",!0),""}}function i(){return Object(b.m)(window,"creativeVendorLibraryLoaded")&&!0===window.creativeVendorLibraryLoaded||Object(b.m)(window,"confiant")}function u(){var t;t={renderTimes:{}},window.addEventListener("message",(function(e){if(Object(b.l)(e.data)){var n;if(Object(b.m)(e.data,"bidInfo"))if(Object(b.m)(e.data.bidInfo,"src")){var r=e.data.bidInfo.src;n=new URL(r).searchParams.get("b")}else if(Object(b.m)(e.data.bidInfo,"jsonp")){var i=e.data.bidInfo.jsonp;n=JSON.parse(i.substr(17,i.length-20)).amzniid}if(Object(b.m)(e.data,"renderData")){var o=e.data.renderData,c=o.id;if(Object(b.m)(o,"renderStart")||Object(b.m)(o,"renderEnd")){var a=o.renderStart,s=o.renderEnd;if(a)t.renderTimes[c]={timeStamp:a},n&&(t.renderTimes[c].bidId=n);else if(s&&Object(b.m)(t.renderTimes,c)&&0!==t.renderTimes[c].timeStamp){var u=s-t.renderTimes[c].timeStamp,d={_type:"iframeRender",c:"dtb",pid:p.b,crt:u};t.renderTimes[c].bidId&&(n=t.renderTimes[c].bidId),n?Object(m.a)(n,d):Object(m.b)(d)}}}if(Object(b.m)(e.data,"blockData")){var l=e.data.blockData.blockInfo,f={_type:"malwareBlock",c:"dtb",tpbr:1,pid:p.b,info:l};n?Object(m.a)(n,f):Object(m.b)(f)}}}),!0)}function h(t){if(t)try{return JSON.parse(window.atob(t)).envelope}catch(e){return decodeURIComponent(t)}return""}function y(t){try{if(t){var e=Object(g.b)(t.consent),n=Date.now(),r=Object(g.c)(e,t.gdprApplies);if(f.a.dispatch({type:"RECORD_TCF_PARSE_TIME",time:Date.now()-n}),r){if("1"!==window.localStorage.getItem(l.e))return{};var i={},o=window.localStorage.getItem("id5id");o&&(i.id5=JSON.parse(decodeURIComponent(o)).universal_uid);var c,a=window.localStorage.getItem("_pubcid");if(a&&(i.pubcommon=a),window.localStorage._lr_env)c=h(window.localStorage._lr_env);else if(window.document.cookie.includes("_lr_env=")){var s=window.document.cookie.match("(^|;)*\\s*_lr_env\\s*=\\s*([^;]+)");s&&(c=h(s.pop()))}else if(window.localStorage.idl_env)c=h(window.localStorage.idl_env);else if(window.document.cookie.includes("idl_env=")){var u=window.document.cookie.match("(^|;)*\\s*idl_env\\s*=\\s*([^;]+)");u&&(c=h(u.pop()))}return c&&""!==c&&(i.liveRamp=c),i}}}catch(t){Object(d.b)(t,"getIdentityConfig",!0)}return{}}},function(t,e,n){"use strict";function r(t){return void 0!==t.amzniid}function i(t){return void 0!==t.kvMap}n.d(e,"b",(function(){return r})),n.d(e,"a",(function(){return i}))},function(t,e,n){"use strict";n.d(e,"b",(function(){return c})),n.d(e,"a",(function(){return a}));var r=n(4),i=n(0),o=n(1);function c(t){try{return Object(i.m)(t,"debug")}catch(t){return Object(o.b)(t,"isApstagLibrary"),!1}}function a(t){try{return!!Object(i.m)(t,r.a)&&!0===t[r.a]}catch(t){return Object(o.b)(t,"hasApstagJsLoaded"),!1}}},function(t,e,n){t.exports=n(23)},function(t,e,n){"use strict";n.r(e);var kt=n(14),xt=n(2),Lt=n(7),Bt=n(0),Nt=n(11),qt=n(5),Ft=n(4),Mt=n(12),Ut=n(18),Vt=n(16),Ht=n(3),Qt=n(1),Xt=n(8),Gt=n(17),r=n(21),Jt=n(6),Kt=n(10),Wt=n(13),Yt=n(20),$t=n(9),Zt=n(19),te=n(15);function ee(t){return a(t)||c(t)||o(t)||i()}function i(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function o(t,e){if(t){if("string"==typeof t)return s(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(t,e):void 0}}function c(t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(t))return Array.from(t)}function a(t){if(Array.isArray(t))return s(t)}function s(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function u(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function ne(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?u(Object(n),!0).forEach((function(e){re(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):u(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function re(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function ie(t){return(ie="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}try{var d=Object(r.b)(window.apstag);d?Object(Qt.b)(new Error("apstag has already loaded - preventing duplicate load"),"apstag-duplicateLoad",!0):(Object(r.a)(window)&&Object(Qt.b)(new Error("apstag was loaded and then destroyed"),"apstag-destroyReload",!0),window.apstagLOADED=!0,function(){var b=Object(Mt.e)(window,"navigationStart"),t="ls",e=Object(qt.d)("console")||function(){try{return-1!==window.location.href.indexOf("amzn_debug_console=1")&&(t="url",!0)}catch(t){return!1}}(),n=Object(qt.d)("console_v2")||function(){try{return-1!==window.location.href.indexOf("amzn_debug_console=2")&&(t="url",!0)}catch(t){return!1}}();function r(t){try{t.ts=Date.now(),xt.a.dispatch({type:"LOG_EVENT",event:t})}catch(t){Object(Qt.b)(t,"_logEvent")}}function i(t){function e(t){try{if(!xt.a.getState().cmpFired){xt.a.dispatch({type:"CMP_FIRED"});var e=document.createElement("iframe");e.style.display="none",e.src=t,document.body.appendChild(e)}}catch(t){Object(Qt.b)(t,"_doCookieMatch-ready")}}try{"loading"===document.readyState?document.addEventListener&&document.addEventListener("DOMContentLoaded",(function(){e(t)}),!1):e(t)}catch(t){Object(Qt.b)(t,"_doCookieMatch")}}function o(t){try{var e=xt.a.getState().cfg.COOKIE_MATCH_DELAY;setTimeout((function(){try{Object(Bt.m)(t,"cmp")?i(t.cmp):Object(Bt.m)(t,"cmpjs")&&Object(Xt.b)(t.cmpjs)}catch(t){Object(Qt.b)(t,"_tryCookieMatch-setTimeout")}}),e)}catch(t){Object(Qt.b)(t,"_tryCookieMatch")}}function c(t){try{return!xt.a.getState().experiments.chunkRequests||0===xt.a.getState().bidReqs[t.split("-")[0]].networkReqs.filter((function(t){return t.inFlight})).length}catch(t){return Object(Qt.b)(t,"_isRequestComplete"),1}}function a(t,e){try{!xt.a.getState().bidReqs[t].hasCallbackExecuted&&c(t)&&(xt.a.dispatch({type:"RECORD_CALLBACK",fid:t}),e())}catch(t){Object(Qt.b)(t,"_checkAndCallCallback")}}function s(t){try{xt.a.getState().experiments.chunkRequests&&xt.a.dispatch({type:"RECORD_NETWORK_EXCHANGE",fid:t[0],timestamp:Date.now(),exchangeType:"response",networkID:parseInt(t[1],10)})}catch(t){Object(Qt.b)(t,"_recordResponse")}}function p(t,r,e){var i=e.split("-"),n={url:t,withCredentials:!0,onload:function t(e){try{s(i);var n=e.responseText;eval(n),a(i[0],r)}catch(t){Object(Qt.b)(t,"_xhrBid-onload",!0)}},onerror:function(){try{s(i),a(i[0],r)}catch(t){Object(Qt.b)(t,"_xhrBid-onerror",!0)}}};try{Object(Xt.d)(n)}catch(t){Object(Qt.b)(t,"_xhrBid",!0),s(i),a(i[0],r)}}function u(t){try{var e=new Date;return e.setTime(e.getTime()+1e3*t),e.toUTCString()}catch(t){return Object(Qt.b)(t,"_getCookieExpiry"),"Thu, 01 Jan 1970 00:00:00 GMT"}}function d(t){try{Object(Bt.m)(t,"cr")&&t.cr.forEach((function(t){document.cookie="".concat(t.k,"=").concat(t.v,";expires=").concat(-1!==t.exp?u(t.exp):Object(Bt.g)(365),";path=/;")}))}catch(t){Object(Qt.b)(t,"_setFirstPartyCookies")}}function l(t){try{if(Object(Bt.m)(t,"cb")){xt.a.dispatch({type:"RECORD_AAX_REQ_PROP",bidReqID:t.cb,key:"resTs",value:Date.now()});var e=new RegExp("e/dtb/bid.*cb=".concat(t.cb));xt.a.dispatch({type:"RECORD_AAX_REQ_PROP",bidReqID:t.cb,key:"perf",value:Object(Mt.c)(window,e)})}Object(Bt.m)(t,"cfg")&&xt.a.dispatch({type:"SET_CFG",cfg:t.cfg}),J(t)}catch(t){Object(Qt.b)(t,"_doOnAaxResponse",!0)}}function f(t){try{if(o(t),d(t),Object(Bt.m)(t,"cfg")&&localStorage.setItem(Ft.d,JSON.stringify(t.cfg)),Object(Bt.m)(t,"st")&&Object(Bt.j)(t.st,917)&&xt.a.getState().sync917){xt.a.dispatch({type:"SET_SYNC_917",value:!1});try{z()}catch(t){Object(Qt.b)(t,"__error-doFbSync__")}}m(t),Object(Lt.j)(t)||Object(Ht.f)()}catch(t){Object(Qt.b)(t,"_doAfterAaxResponse",!0)}}function m(t){try{if(Object(Bt.m)(t,"fp")){var e=t.fp;Object(Bt.m)(e,"length")&&e.forEach((function(t){var e=t.d?t.d:0;setTimeout((function(){Object(Ht.e)(t.s)}),e)}))}}catch(t){Object(Qt.b)(t,"fireAAXPixels")}}function g(){try{xt.a.getState().Q.forEach((function(t){var e="init";switch(t[0]){case"i":e="init";break;case"f":e="fetchBids";break;case"di":e="deleteId";break;case"ri":e="renewId";break;case"ui":e="updateId";break;default:return}window.apstag[e].apply(null,t[1])}))}catch(t){Object(Qt.b)(t,"_QHandler",!0)}}function h(t){try{Object(Bt.l)(t)||(Object(Qt.c)("init.config",ie(t),"object"),t={pubID:"err"}),Object($t.b)(t.pubID,["string","number"])?"number"==typeof t.pubID&&(t.pubID="".concat(t.pubID)):Object(Qt.c)("init.config.pubID",ie(t.pubID),"string"),Object($t.b)(t.adServer,["undefined","string"])||Object(Qt.c)("init.config.adServer",ie(t.adServer),"string"),Object($t.a)(t.bidTimeout)||("string"==typeof t.bidTimeout?Object(Qt.b)({name:"string-".concat(t.bidTimeout),message:"init.config.bidTimeout was a non-numeric string '".concat(t.bidTimeout,"'")},"TypeError-init.config.bidTimeout",!0):Object(Qt.c)("init.config.bidTimeout",ie(t.bidTimeout),"number")),Object($t.b)(t.gdpr,["undefined","object"])?"object"===ie(t.gdpr)&&(Object($t.a)(t.gdpr.cmpTimeout)||(Object($t.b)(t.gdpr.cmpTimeout,["string","undefined"])?Object(Qt.b)({name:"string-".concat(t.bidTimeout),message:"init.config.gdpr.cmpTimeout was a non-numeric string '".concat(t.gdpr.cmpTimeout,"'")},"TypeError-init.config.gdpr.cmpTimeout",!0):Object(Qt.c)("init.config.gdpr.cmpTimeout",ie(t.gdpr.cmpTimeout),"number"))):Object(Qt.c)("init.config.gdpr",ie(t.gdpr),"object"),Object(Bt.m)(t,"params")&&!Object(Bt.l)(t.params)?Object(Qt.c)("init.config.params",ie(t.params),"object"):Object(Bt.m)(t,"params")&&Object.keys(t.params).forEach((function(e){return!(!Object(Bt.m)(t,"params")||"string"!=typeof t.params[e]&&"number"!=typeof t.params[e]&&(Object(Bt.k)(t.params[e])?!t.params[e].reduce((function(t,e){return t&&("string"==typeof e||"number"==typeof e)}),!0)&&(Object(Qt.b)({name:"non-string array item",message:"'init.config.params.".concat(e," contains a non-string item")},"TypeError-init.config.params.".concat(e),!0),1):(Object(Qt.c)("init.config.params.".concat(e),ie(t.params[e]),"string' or 'array"),1)))})),Object(Bt.m)(t,"params")&&Object(Bt.m)(t.params,"us_privacy")&&"string"==typeof t.params.us_privacy&&Ft.z.test(t.params.us_privacy)?Object(Ht.c)("ccpa","y"):Object(Bt.m)(t,"params")&&Object(Bt.m)(t.params,"us_privacy")?Object(Ht.c)("ccpa","i"):Object(Ht.c)("ccpa","n"),Object(Bt.m)(t,"blockedBidders")&&!Object(Bt.k)(t.blockedBidders)?Object(Qt.c)("init.config.blockedBidders",ie(t.blockedBidders),"array"):Object(Bt.m)(t,"blockedBidders")&&Object(Bt.k)(t.blockedBidders)&&(t.blockedBidders.reduce((function(t,e){return t&&("string"==typeof e||"number"==typeof e)}),!0)||Object(Qt.b)({name:"non-string array item",message:"'init.config.blockedBidders contains a non-string item"},"TypeError-init.config.blockedBidders",!0)),Object(Bt.m)(t,"blockedBidders")?Object(Ht.c)("blockedBidders-init","y"):Object(Ht.c)("blockedBidders-init","n"),Object($t.b)(t.simplerGPT,["undefined","boolean"])||Object(Qt.c)("init.config.simplerGPT",ie(t.simplerGPT),"boolean"),t.simplerGPT?Object(Ht.c)("simplerGpt","y"):Object(Ht.c)("simplerGpt","n"),Object($t.b)(t.deals,["undefined","boolean"])||Object(Qt.c)("init.config.deals",ie(t.deals),"boolean"),t.deals?Object(Ht.c)("deals","y"):Object(Ht.c)("deals","n"),Object($t.b)(t.schain,["undefined","object"])&&null!==t.schain?Object(Bt.m)(t,"schain")&&!Object(Kt.i)(t.schain)&&delete t.schain:(Object(Qt.c)("init.config.schain",ie(t.schain),"object"),delete t.schain),Object(Bt.m)(t,"schain")?Object(Ht.c)("schain","y"):Object(Ht.c)("schain","n"),Object($t.b)(t.useSafeFrames,["undefined","boolean"])||(Object(Qt.c)("init.config.useSafeFrames",ie(t.useSafeFrames),"boolean"),delete t.useSafeFrames),t.useSafeFrames?Object(Ht.c)("useSafeFrames","y"):Object(Ht.c)("useSafeFrames","n")}catch(e){Object(Qt.b)(e,"_validateAndStoreConfig-validateConfig")}try{var e=xt.a.getState().config;Object(Bt.m)(e,"pubID")&&Object(Bt.m)(t,"pubID")&&e.pubID!==t.pubID&&Object(Qt.b)(new Error("`apstag.init` was called multiple times with different pubIDs (".concat(e.pubID," then ").concat(t.pubID,")")),"_validateAndStoreConfig-diffPubId",!0),xt.a.dispatch({type:"SET_CONFIG",config:t,defaultCmpTimeout:xt.a.getState().cfg.GDPR_CMP_TIMEOUT})}catch(e){Object(Qt.b)(e,"_validateAndStoreConfig",!0)}}function y(t){try{var e=t.slotID,n=!1;if(Object(Bt.m)(t.bidConfig,"amznbid")&&"o_"===t.bidConfig.amznbid.slice(0,2)&&(n=!0),Object(Bt.m)(t.bidConfig,"mediaType")&&"v"===t.bidConfig.mediaType&&!1===n)return;if(!window.IntersectionObserver&&n)return void Object(Qt.b)({name:"IntersectionObserver",message:"IntersectionObserver not supported "},"_safeApplySlotTargeting");if(!Jt.a.hasAdServerObjectLoaded())return void Object(Qt.a)("displayAdServer Object hasn't been defined",!0);if(!Jt.a.isCommandQueueDefined())return void Object(Qt.a)("displayAdServer Object's cmd queue hasn't been defined",!0);Jt.a.hasAdServerObjectLoaded()?null!==O(e)?A(t):Object(Qt.a)("".concat(e," isn't defined when trying to set amazon bid!")):Jt.a.cmdQueuePush((function(){y(t)}))}catch(t){Object(Qt.b)(t,"_safeApplySlotTargeting",!0)}}function O(t){var e=null;try{e=Object(Nt.b)(Jt.a).filter((function(e){return e.slotID===t}))[0]||null}catch(e){Object(Qt.b)(e,"_getAdServerSlot")}return e}function j(t){try{var e=xt.a.getState().targetingKeys[t.slotID];Jt.a.hasAdServerObjectLoaded()&&Object(Bt.k)(e)&&e.forEach((function(e){return 0<t.getTargeting(e).length&&t.clearTargeting(e)}))}catch(e){Object(Qt.b)(e,"_clearTargetingFromSlot",!0)}}function v(t){try{if(Object(Bt.m)(xt.a.getState().slotBids,t.slotID)){var e=xt.a.getState().slotBids[t.slotID].filter((function(t){return t.bidState===Ft.c.set}))[0];e&&e.bidState===Ft.c.set&&xt.a.dispatch({type:"BID_STATE_CHANGE",slotID:t.slotID,_targetingSetID:e._targetingSetID,bidState:Ft.c.exposed})}}catch(t){Object(Qt.b)(t,"_clearBidSetOnSlot",!0)}}function S(t,e){try{return t.map((function(t){return Object(Bt.j)(e,t)})).filter((function(t){return t})).length===t.length}catch(t){return void Object(Qt.b)(t,"_hasAllItemsInArray")}}function w(){var t={};try{Object.keys(xt.a.getState().slotBids).forEach((function(e){var n=xt.a.getState().slotBids[e].filter(Kt.f);0<n.length&&(t[e]=n.map((function(t){var e=xt.a.getState().AAXReqs.filter((function(e){return e.bidReqID===t.bidReqID})),n=0;if(0<e.length)n=e[0].rqTs;else{var r=xt.a.getState().AAXReqs.map((function(t){return t.bidReqID})).join(", ");Object(Qt.b)({name:"BidError",message:"Request not found: ".concat(t.bidReqID," not found in ").concat(r)},"_getCurrentSlotBids-noRequest")}return{rqTs:n,bid:t}})).reduce((function(t,e){return t.rqTs>e.rqTs?t:e})).bid)}))}catch(t){Object(Qt.b)(t,"_getCurrentSlotBids",!0)}return t}function _(t,e){try{return Object(Bt.k)(xt.a.getState().targetingKeys[t])?e?["amzniid_sp"]:xt.a.getState().targetingKeys[t].filter((function(t){return-1<t.indexOf("amzniid")&&t.indexOf("amzniid_sp")<0})):["amzniid"]}catch(t){return Object(Qt.b)(t,"_getAllBidIdKeys"),[]}}function E(t,e){var n,r;try{var i=xt.a.getState().slotBids;Object.keys(i).forEach((function(o){i[o].forEach((function(i){_(o,e).forEach((function(e){i.bidConfig[e]===t&&(n=i,"amzniid_sp"===e?r="sp":"amzniid"!==e&&(r=e.substr(0,e.indexOf("amzniid"))))}))}))}))}catch(t){Object(Qt.b)(t,"_findSlotBidByBidID",!0)}return{slotBid:n,dealId:r}}function D(t,e,n){var r="";try{e.bidConfig[n+"amzniid"]===t&&(r=n.split("_").pop().trim())}catch(t){Object(Qt.b)(t,"_getPMPBidSize")}return r}function I(t){try{if(void 0===t.slots)return[];var e={};return t.slots.forEach((function(t){"video"!==t.mediaType&&"v"!==t.mediaType&&"v"!==t.mediaType_sp?e[t.slotID]=new Kt.a(t):(0<=t.slotID.indexOf("rsv-")&&(t={slotID:t.slotID.substring(4),r_amznbid:t.amznbid,r_amzniid:t.amzniid,r_amznp:t.amznp,mediaType:"video",targeting:["r_amznbid","r_amzniid","r_amznp"],amznsz:t.amznsz,size:t.size,crid:t.crid,meta:t.meta}),Object(Bt.m)(e,t.slotID)?t.targeting.forEach((function(n){e[t.slotID].bidConfig[n]=t[n],-1===e[t.slotID].bidConfig.targeting.indexOf(n)&&e[t.slotID].bidConfig.targeting.push(n)})):e[t.slotID]=new Kt.a(t))})),Object.keys(e).map((function(t){return e[t]}))}catch(t){return Object(Qt.b)(t,"_mergeVideoBids"),[]}}function T(t){var e=I(t),n=[];try{n=e.map((function(e){return e.bidReqID=t.cb,e.host=t.host,e.ev=t.ev,e.cfe=t.cfe,e}))}catch(e){Object(Qt.b)(e,"_convertAaxResponse")}return n}function A(t){try{var e=t.slotID,n=t._targetingSetID;if(t.bidState===Ft.c.set)return;var r=O(e);if(null!==r){v(r);var i=t.newBidObject;Object.keys(i.targeting).forEach((function(t){return r.setTargeting(t,i.targeting[t])})),xt.a.dispatch({type:"BID_STATE_CHANGE",slotID:e,_targetingSetID:n,bidState:Ft.c.set,ts:Date.now()})}}catch(t){Object(Qt.b)(t,"_applyTargetingToAdServerSlot",!0)}}function R(t){try{var e=w();t.forEach((function(t){e[t]&&y(e[t])}))}catch(t){Object(Qt.b)(t,"_applySuppliedSlotBidsToAdServerObject",!0)}}function C(){try{var t=w();Object.keys(t).forEach((function(e){return y(t[e])}))}catch(t){Object(Qt.b)(t,"_applyAllCurrentSlotBidsTargetingToAdServerObject",!0)}}function P(t){try{t?(Object(Ht.c)("targeting","setDisplayBids-list"),R(t)):(Object(Ht.c)("targeting","setDisplayBids-all"),C()),xt.a.getState().displayAdServer.slotRenderEndedSet||(Jt.a.cmdQueuePush((function(){try{Jt.a.slotRenderEndedEvent((function(t){try{j(t),v(t)}catch(t){Object(Qt.b)(t,"_applySlotTargeting-cmdQueue-slotCb",!0)}}))}catch(t){Object(Qt.b)(t,"_applySlotTargeting-cmdQueue",!0)}})),xt.a.dispatch({type:"SLOT_RENDER_ENDED_SET"}))}catch(t){Object(Qt.b)(t,"_applySlotTargeting",!0)}}function z(){var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",e="1881141382166183";function n(t){try{var e=JSON.parse(t),n=e.fbToken,r=new Date(parseInt(e.expAfter,10)).toUTCString();document.cookie="aps_ext_917=".concat(n,"; expires=").concat(r)}catch(t){Object(Qt.b)(t,"_doFbSync-setFbCookie")}}function r(e){try{!function(t,e,n){try{!function(t,e){try{var n={url:t,withCredentials:!0,onload:function(t){return e(t.responseText)}};Object(Xt.d)(n)}catch(t){Object(Qt.b)(t,"_doFbSync-sendTokenRequest")}}(function(t,e){try{return"".concat("https://www.facebook.com/audiencenetwork/token/update","?partner=").concat(encodeURIComponent(t),"&vr_token=").concat(encodeURIComponent(e))}catch(t){return Object(Qt.b)(t,"_doFbSync-getUpdateUrl"),""}}(t,e),n)}catch(t){Object(Qt.b)(t,"_doFbSync-getV4Token")}}(e,function(){try{for(var e="VR_",n=0;n<197;++n)e+=t.charAt(Math.floor(Math.random()*t.length));return e}catch(e){return Object(Qt.b)(e,"_doFbSync-getVrToken"),""}}(),n)}catch(e){Object(Qt.b)(e,"_doFbSync-getTokenResponse")}}try{"complete"===document.readyState?r(e):window.addEventListener("load",(function(){r(e)}))}catch(e){Object(Qt.b)(e,"_doFbSync")}}function k(t,e){function n(){if(!i)if(20<=o++)Object(Qt.b)({name:"LoopError",message:"Too many attempts to append to document.body"},"_safeDocumentBodyAppendChild-callback-loops",!0);else{try{if(t&&t.body&&null!==t.body&&"function"==typeof t.body.appendChild)return t.body.appendChild(e),r(),void(i=!0)}catch(t){Object(Qt.b)(t,"_safeDocumentBodyAppendChild-callback")}setTimeout(n,100)}}var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:function(){},i=!1,o=0;try{"complete"===t.readyState||"interactive"===t.readyState?(Object(Ht.c)("appended","sync"),n()):(Object(Ht.c)("appended","async"),t.addEventListener("DOMContentLoaded",n))}catch(t){Object(Qt.b)(t,"_safeDocumentBodyAppendChild")}}function x(t){try{var e,n;return e="".concat(t.host).concat(xt.a.getState().cfg.DTB_PATH,"/imp"),n="".concat(t.host).concat(xt.a.getState().cfg.DTB_PATH,"/adm"),t.cfe||t.isAmp||t.isSf?n:e}catch(t){return Object(Qt.b)(t,"determineCreativeFetchEndpoint"),""}}function L(t){try{var e,n="?b=".concat(t.bidID,"&rnd=").concat(Object(Bt.e)());return Object(Bt.m)(t,"pp")&&(n+="&pp=".concat(t.pp)),Object(Bt.m)(t,"amznp")&&(n+="&p=".concat(t.amznp)),Object(Bt.m)(t,"crID")&&(n+="&crid=".concat(t.crID)),Object(Bt.m)(t,"isSharedPMP")&&!0===t.isSharedPMP&&(n+="&sp=true"),Object(Zt.d)()&&(n+="&ep=%7B%22ce%22%3A%221%22%7D"),e=x(t),t.fif?"".concat(e,"j").concat(n):"".concat(e,"i").concat(n)}catch(t){return Object(Qt.b)(t,"_creativeURL"),""}}function B(t){try{var e=t.doc.createElement("iframe");return e.frameBorder="0",e.marginHeight="0",e.marginWidth="0",e.style.marginTop="0",e.style.marginLeft="0",e.scrolling="no",t.inheritSize?(e.style.width="100%",e.style.height="100%"):(e.style.width="".concat(t.sizes[0],"px"),e.style.height="".concat(t.sizes[1],"px")),e}catch(t){return Object(Qt.b)(t,"_baseIframe"),window.document.createElement("iframe")}}function N(t){try{if(Object(Bt.m)(t,"bidType")){var e=t.kvMap;switch(t.bidType){case"sharedPMP":return{bidID:e.amzniid_sp[0],pp:e.amznbid_sp[0],sizes:e.amznsz_sp[0].split("x"),amznp:e.amznp_sp[0],inheritSize:t.inheritSize,isSharedPMP:t.isSharedPMP};case"preferredPMP":if(Object(Yt.a)(t)&&Object(Bt.m)(t,"amzndeal")){var n=t.amzndeal.split("_").pop().trim();return{bidID:e["".concat(t.amzndeal,"amzniid")][0],sizes:jt(n)}}break;case"openAuction":if(Object(Yt.a)(t))return{bidID:e.amzniid[0],pp:Object(Lt.c)(e.amznbid[0]),amznp:e.amznp[0],inheritSize:t.inheritSize,sizes:e.amznsz[0].split("x")};if(Object(Yt.b)(t))return{bidID:t.amzniid,pp:Object(Lt.c)(t.amznbid),amznp:t.amznp,sizes:t.amznsz.split("x")};break;default:Object(Qt.b)({name:"Invalid AMP Bid Type: ".concat(t.bidType),message:"No valid AMP bid type"},"getAmpAdData-invalidBidType")}}}catch(t){Object(Qt.b)(t,"getAmpAdData")}return{bidID:"ERROR",sizes:[]}}function q(t,e){try{var n=null;if(void 0!==e&&(Object(Bt.m)(e,"ampEnv")&&e.ampEnv||Object(Bt.m)(e,"sfEnv")&&e.sfEnv)&&(n=e,Object(Bt.m)(e,"bidType")&&"sharedPMP"===e.bidType?n.isSharedPMP=!0:n.isSharedPMP=!1,n.document=t,n.amznhost=n.kvMap.amznhost[0]),yt(t)&&((n=t).bidType="openAuction",n.ampEnv=!0),null===n)return void Object(Qt.b)(new Error("Invalid AMP parameters"),"_renderAmpImpression-invalidParams",!0);var r=N(n);if("ERROR"===r.bidID)return;if(r.doc=n.document,r.host=n.amznhost.replace("http://","https://"),r.adID="amznad".concat(Object(Bt.e)()),r.isAmp=n.ampEnv,r.isSf=Object(Ut.c)(window),xt.a.getState().aaxViewabilityEnabled)return void wt(r,r.doc);M(r)}catch(t){Object(Qt.b)(t,"_renderAmpImpression")}}function F(t){var e,n="unknown";function r(r){try{if(r&&(t.hasTimedOut=!0),r&&!t.hasRendered&&Object(Qt.b)({name:"RenderTimeout",message:"renderAd was called from timeout. fifFlowMethod: ".concat(n)},"__loadAdIntoFriendlyIframe-renderAd-timeout-isOutstream:".concat(t.isOutstream)),null===e.contentDocument)return void Object(Qt.b)({name:"NoDocument",message:"iframe.contentDocument was null inside renderAd. isFromTimeout: ".concat(r,". fifFlowMethod: ").concat(n)},"__loadAdIntoFriendlyIframe-renderAd-noDocument-isOutstream:".concat(t.isOutstream),!0);if(t.hasRendered&&!t.hasTimedOut)return void Object(Qt.b)({name:"DupeRender",message:"Render was called twice"},"__loadAdIntoFriendlyIframe-renderAd-rerender-isOutstream:".concat(t.isOutstream),!0);if(t.hasRendered)return;t.hasRendered=!0,e.contentDocument.open(),e.contentDocument.write(t.html),e.contentDocument.close()}catch(r){Object(Qt.b)(r,"__loadAdIntoFriendlyIframe-renderAd-isOutstream:".concat(t.isOutstream))}}function i(){var i=r.bind(null,!1);try{n=null!==e.contentDocument&&Object(Bt.j)(["complete","interactive"],e.contentDocument.readyState)?(i(),"doc-ready"):null!==e.contentDocument&&"uninitialized"!==e.contentDocument.readyState?(e.contentDocument.addEventListener("DOMContentLoaded",i),"dom-listener"):(e.addEventListener("load",i),"iframe-listener"),Object(Ht.c)("fifFlow",n),setTimeout(r,1e3,!0)}catch(i){Object(Qt.b)(i,"_loadAdIntoFriendlyIframe-setAttributes-isOutstream:".concat(t.isOutstream))}}try{if(Object(Ht.c)("iframe","friendly"),void 0===t.html)throw new Error("No HTML available for ad, most likely the creative has expired");if(t=ne({hasRendered:!1,hasTimedOut:!1},t),(e=B(t)).id="apstag-f-iframe-".concat(Object(Bt.e)()),t.isOutstream)try{var o=Object(Vt.d)(document,t);if(void 0===o)throw new Error("gpt video div element is undefined");o&&o.firstElementChild&&(o.firstElementChild.style.display="none");var c=Object(Vt.f)(t.sizes);return Object(Vt.a)(c,o),Object(Vt.e)(c,e),i(),void Object(Vt.g)(c,e)}catch(i){Object(Qt.b)(i,"_loadAdIntoFriendlyIframe-outstream",!0)}else k(t.doc,e,i)}catch(i){Object(Qt.b)(i,"_loadAdIntoFriendlyIframe",!0)}}function M(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{states:{csmLoaded:!1,iframeLoaded:!1,shouldRunViewability:!1}},n=2<arguments.length?arguments[2]:void 0;try{Object(Ht.c)("iframe","unfriendly");var r=B(t);if(r.id=t.adID,r.setAttribute("sandbox","allow-forms allow-pointer-lock allow-popups allow-popups-to-escape-sandbox allow-same-origin allow-scripts allow-top-navigation-by-user-activation"),Object(qt.d)("fake_bids")){var i='<body style="background-color: #FF9900;">'.concat(50<parseInt(t.sizes[1],10)?"<h3>apstag Test Creative</h3>":"","<h4>amzniid - ").concat(t.bidID," | amznbid: ").concat(t.pp," | size: ").concat(t.sizes.join("x"),"</h4></body>");r.src="javascript:'".concat(i,"'")}else r.src=L(t);!(t.isAmp&&t.isSf&&Object(Ut.b)(window))&&(!t.isSf||t.isAmp||t.inheritSize)||Object(Ut.a)(t.sizes,window),k(t.doc,r),(e.iframe=r).onload=function(){e.states.iframeLoaded=!0,n&&n()}}catch(t){Object(Qt.b)(t,"_loadAdIntoUnfriendlyIframe",!0)}}function U(t){var e=t.states,n=t.doc,r=t.bidID,i=t.iframe;try{if(Object(Bt.a)(e))return;var o;e.shouldRunViewability=!1,Object(Bt.m)(window,"amzncsm")?o=window.amzncsm:void 0!==n&&null!==n.defaultView&&Object(Bt.m)(n.defaultView,"amzncsm")&&(o=n.defaultView.amzncsm),void 0!==n&&void 0!==o&&Object(Bt.m)(o,"rmD")&&(o.host=Object(qt.c)("host",xt.a.getState().hosts.DEFAULT_AAX_PIXEL_HOST),o.rmD(i,r,n.defaultView,n,xt.a.getState().config.pubID))}catch(t){Object(Qt.b)(t,"_triggerViewability")}}function V(t,e){return function(n){try{var r=Object(Kt.e)(e.slots),i=Object.keys(r),o=[];n&&(xt.a.dispatch({type:"RECORD_AAX_REQ_PROP",bidReqID:e.bidReqID,key:"timedOutAt",value:Date.now()}),xt.a.getState().experiments.chunkRequests&&xt.a.dispatch({type:"RECORD_TIMEOUT",fid:e.bidReqID,timeOut:Date.now()})),i.forEach((function(t){if(Object(Bt.m)(r,t)){var e=r[t];Object(Kt.g)(xt.a.getState(),Jt.a)||Object(Bt.m)(e.bidConfig,"amznbid")?Object(Bt.m)(e.bidConfig,"amznp")||(e.bidConfig.amznp=""):(Object(Ht.c)("unusedDeal",e.mediaType),"video"!==e.mediaType&&(e.bidConfig.targeting.unshift("amznsz"),e.bidConfig.amznsz="0x0"),e.bidConfig.targeting.unshift("amzniid","amznbid","amznp"),e.bidConfig.amzniid="",e.bidConfig.amznbid=Ft.u.noBid,e.bidConfig.amznp=Ft.u.noBid),o.push(e)}})),Jt.a.isSupported&&(o=Object(Kt.c)(o,e,n));var c={fromTimeout:n},a=Object(Kt.g)(xt.a.getState(),Jt.a);try{t(o.map((function(t){return a?t.newBidObject:t.bidObject})),c)}catch(i){console.error(i)}}catch(i){Object(Qt.b)(i,"_bidCallbackHandler",!0);try{t([],{fromTimeout:n,fromError:!0})}catch(i){console.error(i)}}}}function H(t,e){try{var n,r;e.inheritSize?Object(Ht.c)("creativeSize","inherited"):(r=t.defaultView&&t.defaultView.frameElement?(n=t.defaultView.frameElement,"defaultView"):(n=window.frameElement,"frameElement"),Object(Ht.c)("resizeIframe",r),Object(Ht.c)("creativeSize","resized"),null!==n?(n.style.width="".concat(e.sizes[0],"px"),n.style.height="".concat(e.sizes[1],"px")):Object(Qt.b)({name:"FrameNotFound",message:"'win' is 'null'. Method used: ".concat(r)},"_resizeIframe-win"))}catch(t){Object(Qt.b)(t,"_resizeIframe")}}function Q(t){try{return"".concat(t[0],"x").concat(t[1])}catch(t){return Object(Qt.b)(t,"_sizeArrayToSring"),"x"}}function X(t){try{return 1===t.length?Q(t[0]):Q(t[Math.floor(t.length*Math.random())])}catch(t){return Object(Qt.b)(t,"_pickRandomSizeForMockBid",!0),""}}function G(t){try{var e,n=Object(qt.c)("host",xt.a.getState().hosts.DEFAULT_AAX_BID_HOST),r=Object(Lt.g)(window),i=t.bidReqID,o=Object(Bt.h)(window),c=Object(qt.c)("testBidTimeout",200);xt.a.dispatch({type:"RECORD_AAX_REQUEST",data:{bidConfig:t,timeout:c,bidReqID:i,ws:o,url:r,rqTs:Date.now()}}),e=t.slots.map((function(t){var e,n=X(t.sizes),r="testDeal".concat(Object(Bt.e)(),"_").concat(n),i="testDealIi-".concat(Object(Bt.e)()),o=X(t.sizes),c=(re(e={slotID:t.slotID,crid:"".concat(Ft.o.crid,"-").concat(Object(Bt.e)()),size:o,amzniid:"".concat(Ft.o.amzniid,"-").concat(Object(Bt.e)()),amznbid:Ft.o.amznbid,amznp:Ft.o.amznp,amznsz:o,amzniid_sp:"".concat(Ft.o.amzniid,"-").concat(Object(Bt.e)()),amznbid_sp:"".concat(Ft.o.amznbid,"SP"),amznp_sp:"".concat(Ft.o.amznp,"SP"),amznsz_sp:X(t.sizes),amzndeals:[r]},"".concat(r,"amzniid"),i),re(e,"mediaType","d"),re(e,"meta",["slotID","mediaType","size"]),re(e,"targeting",["amzniid","amznbid","amznp","amznsz","amzniid_sp","amznbid_sp","amznp_sp","amznsz_sp","amzndeal_sp","amzndeals","".concat(r,"amzniid")]),e);return"video"===t.mediaType&&(c.mediaType="video",c.amznbid="v_".concat(c.amznbid)),c})),setTimeout((function(){window.apstag.bids({slots:e,host:n,status:"ok",cb:i})}),c)}catch(t){Object(Qt.b)(t,"_doMockBid",!0)}}function J(t){try{var e=xt.a.getState().AAXReqs.filter((function(e){return e.bidReqID===t.cb}))[0];if(e&&e.bidConfig&&e.bidConfig.slots){var n=e.bidConfig.slots.filter(Nt.d).map((function(t){return t.slotID})),r=Object(Bt.m)(t,"slots")?t.slots.map((function(t){return t.slotID})):[],i=n.filter((function(t){return!Object(Bt.j)(r,t)}));xt.a.dispatch({type:"NO_BID_ON_ADSERVER_SLOTS",slotIDs:i}),Jt.a.hasAdServerObjectLoaded()?Y():Jt.a.isCommandQueueDefined()&&Jt.a.cmdQueuePush((function(){Y()}))}}catch(e){Object(Qt.b)(e,"_determineNoBidStateForAdServerObject")}}function K(t){return Object(Bt.j)(xt.a.getState().AAXReqs.filter((function(t){return!t.resTs})).map((function(t){return t.bidConfig.slots})).reduce((function(t,e){return t.concat(e)}),[]).map(Nt.c),t)}function W(t){try{var e=t.getTargeting("amznbid");return 0<e.length&&2<e[0].length}catch(t){return Object(Qt.b)(t,"_isRealAmznbidTargetingSetOnSlot"),1}}function Y(){try{Jt.a.hasAdServerObjectLoaded()&&"1"===Jt.a.getTargeting("amznbid")[0]&&Z(),Object(Nt.b)(Jt.a).forEach((function(t){!Object(Bt.j)(xt.a.getState().displayAdServer.noBidSlotIDs,t.slotID)||K(t.slotID)||W(t)||"2"===t.getTargeting("amznbid")[0]||$("noBid",t)}))}catch(t){Object(Qt.b)(t,"_applyNoBidFromAAXState")}}function $(t,e){Ft.v.forEach((function(n){return e.setTargeting(n,Ft.u[t])}))}function Z(){Ft.v.forEach((function(t){return Jt.a.clearTargeting(t)}))}function tt(t){try{var e={_type:"dupePixel",dd:Date.now()-t.timing.renderTime};Object(Ht.a)(t.bidConfig.amzniid,e)}catch(t){Object(Qt.b)(t,"_sendDupeBidPixel")}}!function(){if(Object(Bt.i)()){var t=localStorage.getItem(Ft.d);if(t){var e=JSON.parse(t);null!==e&&xt.a.dispatch({type:"SET_CFG",cfg:e})}}}(),Object(Zt.c)();var et=0,nt;function rt(){try{if(!Object(Bt.m)(window,"googletag")||!Object(Bt.m)(window.googletag,"cmd"))return void(++et<5&&setTimeout(rt,100));(new Gt.a).cmdQueuePush((function(){try{window.googletag.pubads().addEventListener("slotRequested",(function(t){try{var e=t.slot;xt.a.dispatch({type:"LOG_GAM_EVENT",event:ne(ne({},new Gt.b(e).slotConfig),{},{ts:Date.now(),targeting:e.getTargetingMap()})})}catch(t){Object(Qt.b)(t,"_initializeSlotRequestedEventListener-cmdQueue-listener")}}))}catch(t){Object(Qt.b)(t,"_initializeSlotRequestedEventListener-cmdQueue")}}))}catch(t){Object(Qt.b)(t,"_initializeSlotRequestedEventListener")}}function it(t){try{var e=t.AAXReqs.slice(t.gamSlotRenderPixel.aaxReqOffset).reduce((function(t,e){return t.concat(e.bidConfig.slots)}),[]).map((function(t){return ne(ne({},t),{},{type:"a"})})).filter((function(t){return"video"!==t.mediaType})),n=t.gamSlotFetchLog.slice(t.gamSlotRenderPixel.gamSlotFetchLogOffset).map((function(t){return ne(ne({},t),{},{type:"g"})})),r=[].concat(ee(e),ee(n)).reduce((function(t,e){return void 0===t[e.slotID]&&(t[e.slotID]={sd:e.slotID,a:{c:0},g:{c:0}}),t[e.slotID][e.type].c++,t[e.slotID][e.type].s=e.sizes,t[e.slotID][e.type].sn=e.slotName||"",t}),{});return Object.keys(r).map((function(t){return r[t]})).filter((function(t){return 0!==t.a.c||0!==t.g.c}))}catch(t){return Object(Qt.b)(t,"getSlotFetchCounts"),[]}}function ot(){try{var t=xt.a.getState(),e=it(t);0<Object.keys(e).length&&(Object(Bt.c)(e,5).forEach((function(e){var n={slots:e,pid:Kt.b,url:Object(Lt.g)(window).split("?")[0],ws:Object(Bt.h)(window),pubid:t.config.pubID,_type:"slotRenders"};Object(Ht.b)(n)})),xt.a.dispatch({type:"UPDATE_RENDER_OFFSETS",offsets:{aaxReqOffset:t.AAXReqs.length,gamSlotFetchLogOffset:t.gamSlotFetchLog.length}}))}catch(e){Object(Qt.b)(e,"sendDisplayAdServerRenderPixel")}}function ct(){setInterval((function(){ot()}),5e3)}function at(){try{setTimeout((function(){try{var t=lt().filter((function(t){return!Object(Bt.m)(xt.a.getState().bsPixels,t.iid)||t.state!==xt.a.getState().bsPixels[t.iid]}));t&&t.length&&0<t.length&&(t.forEach((function(t){return Object(Ht.a)(t.iid,ut(t))})),st(t));var e={fetchStart:"a",domainLookupStart:"b",domainLookupEnd:"c",connectStart:"d",secureConnectionStart:"e",connectEnd:"f",requestStart:"g",responseStart:"h",responseEnd:"i"};Object.keys(xt.a.getState().slotBids).forEach((function(t){xt.a.getState().slotBids[t].forEach((function(n){if(Object(Bt.m)(n.bidConfig,"amzniid")&&!n.pixelSent){var r=xt.a.getState().AAXReqs.filter((function(t){return t.bidReqID===n.bidReqID}))[0];if("object"===ie(r)&&null!==r){var i=r.rqTs-Object(Mt.d)(),o={pid:Kt.b,ns:r.bidConfig.validSlots.length,fid:n.bidReqID,fbrq:r.rqTs,_type:"latencyBd"};"object"===ie(r.perf)&&null!==r.perf&&Object.keys(e).forEach((function(t){Object(Bt.m)(r,"perf")&&0!==Object(Mt.a)(r.perf,t)&&(o[e[t]]=Object(Mt.a)(r.perf,t)-i)})),o.j=r.resTs-r.rqTs,Object(Ht.a)(n.bidConfig.amzniid,o),xt.a.dispatch({type:"UPDATE_BID_INFO_PROP",slotID:t,iid:n.bidConfig.amzniid,key:"pixelSent",value:!0})}}}))})),at()}catch(t){Object(Qt.b)(t,"_sendBidsSetOnDFPPixel-timeout")}}),5e3)}catch(t){Object(Qt.b)(t,"_sendBidsSetOnDFPPixel")}}function st(t){t.forEach((function(t){return xt.a.dispatch({type:"RECORD_BID_INFO_SENT",bidInfo:t})}))}function ut(t){try{var e=dt(t.fid),n={status:t.state,pubid:xt.a.getState().config.pubID,_type:"bidSetPixel",toa:Object(Bt.m)(e.req,"timedOutAt")?e.req.timedOutAt:0,fbrq:e.req.rqTs,pto:e.req.timeout,ns:e.req.bidConfig.validSlots.length,bla:e.req.resTs-e.req.rqTs,reqindex:e.index,fid:t.fid,tbs:0,c:"dtb"};xt.a.getState().cfg.CHUNK_BID_REQUESTS_PROPORTION&&(n.eid=xt.a.getState().experiments.chunkRequests?2:1,n.fbindex=e.fbIndex,n.fbns=xt.a.getState().bidConfigs[parseInt(t.fid.split("-")[0],10)].slots.length);var r=xt.a.getState().experiments;Object(Bt.m)(r,"shouldUseTestBidEndpoint")&&(n.tbs=r.shouldUseTestBidEndpoint?2:1),t.delta&&(n.delay=t.delta);var i=e.req.perf;return void 0!==i&&(n.ul=e.req.urlLength,n.es=Object(Mt.a)(i,"encodedBodySize")),0<Object.keys(xt.a.getState().identityState).length&&(n.ids=JSON.stringify(xt.a.getState().identityState)),0<xt.a.getState().tcfParseTime&&(n.tpt=xt.a.getState().tcfParseTime),n}catch(t){return Object(Qt.b)(t,"_mapBidInfoToPixel"),{_type:"bidSetPixel",status:-1,pubid:"",toa:0,fbrq:0,pto:0,ns:0,bla:0,reqindex:0,fid:"",tbs:0,c:"dtb"}}}function dt(t){var e=xt.a.getState().AAXReqs.filter((function(e){return e.bidReqID===t}))[0],n=xt.a.getState().AAXReqs.indexOf(e)+1,r={req:e,index:n,fbIndex:n};return r.index=xt.a.getState().AAXReqs.indexOf(r.req)+1,xt.a.getState().experiments.chunkRequests&&(r.fbIndex=xt.a.getState().AAXReqs.filter((function(t){return-1===t.bidReqID.indexOf("-")||"0"===t.bidReqID.split("-")[1]})).map((function(t){return t.bidReqID.split("-")[0]})).indexOf(t.split("-")[0])+1),r}function lt(){try{var t=mt(),e=[];return null===t||Object.keys(xt.a.getState().slotBids).forEach((function(n){"video"!==xt.a.getState().slotBids[n][0].bidConfig.mediaType&&xt.a.getState().slotBids[n].filter((function(t){return Object(Bt.m)(t.bidConfig,"amzniid")})).forEach((function(r){if(null!==t){var i={state:-1,slotID:n,iid:r.bidConfig.amzniid,fid:r.bidReqID},o=[],c=[];if(n in t&&(o=t[n].fetchedAt.filter((function(t){return t.AAXReqInfo&&t.AAXReqInfo.bidReqID===r.bidReqID})),c=t[n].targetedAt.filter((function(t){return t.targeting===r.bidConfig.amzniid}))),0<o.length?0<o.length&&c.length>=o.length&&o.slice(o.length-1)[0].ts>c.slice(o.length-1)[0].ts?1===t[n].fetchWithIID.filter((function(t){return t===r.bidConfig.amzniid})).length?i.state=1:i.state=4:Object(Bt.j)(t[n].fetchWithIID,r.bidConfig.amzniid)?i.state=3:i.state=2:i.state=0,1===i.state||2===i.state){var a=xt.a.getState().AAXReqs.filter((function(t){return t.bidReqID===r.bidReqID}))[0].resTs,s=ft(a,t[n].fetchedAt,2===i.state);s&&Object(Bt.m)(s,"ts")&&(i.delta=a-s.ts)}e.push(i)}}))})),e}catch(t){return Object(Qt.b)(t,"_getBidSetInfo"),[]}}function ft(t,e,n){var r=e.map((function(e){var r=t-e.ts;return!n&&r<=0?-r:n&&0<=r?r:null}));return e[bt(r)]}function bt(t){for(var e=-1,n=-1,r=0;r<t.length;r++)null!==t[r]&&(-1===n||t[r]<e)&&(e=t[n=r]);return n}function pt(t,e){return xt.a.getState().AAXReqs.filter((function(t){return Object(Bt.j)(t.bidConfig.slots.map((function(t){return t.slotID})),e)}))[t]}function mt(){try{if(!Jt.a.hasAdServerObjectLoaded())return null;var t=xt.a.getState().gamSlotFetchLog.reduce((function(t,e){Object(Bt.m)(t,e.slotID)||(t[e.slotID]={fetchedAt:[],targetedAt:[]});var n=t[e.slotID];return n.fetchedAt.push({ts:e.ts,AAXReqInfo:pt(n.fetchedAt.length,e.slotID)}),Object(Bt.m)(e.targeting,"amzniid")&&0<e.targeting.amzniid.length?n.targetedAt.push({ts:e.ts-1,targeting:e.targeting.amzniid[0]}):n.targetedAt.push({ts:e.ts-1,targeting:""}),t}),{});return Object.keys(t).forEach((function(e){if(Object(Bt.m)(t,e)){var n=t[e];n.fetchWithIID=n.fetchedAt.map((function(t){var e=ft(t.ts,n.targetedAt,!0);return e?e.targeting:0})),t[e]=n}})),t}catch(t){return Object(Qt.b)(t,"_getDFPSlotFetches"),null}}function gt(){try{Jt.a.hasAdServerObjectLoaded()?$("noRequest",Jt.a):Jt.a.isCommandQueueDefined()&&Jt.a.cmdQueuePush((function(){$("noRequest",Jt.a)}))}catch(t){Object(Qt.b)(t,"_applyNoRequestToAAXState")}}function ht(t){try{xt.a.dispatch({type:"REQUESTED_BID_FOR_ADSERVER_SLOTS",slotIDs:t}),Jt.a.isCommandQueueDefined()&&Jt.a.cmdQueuePush((function(){try{var e=Object(Nt.b)(Jt.a);"0"===Jt.a.getTargeting("amznbid")[0]&&Z(),S(t.filter((function(t){return void 0!==t})),e.map((function(t){return t.slotID})))?e.forEach((function(e){Object(Bt.j)(t,e.slotID)&&!W(e)&&$("bidInFlight",e)})):Jt.a.cmdQueuePush((function(){try{$("bidInFlight",Jt.a)}catch(t){Object(Qt.b)(t,"_setRequestToAAXInFlightState-cmdQueue-cmdQueue")}}))}catch(e){Object(Qt.b)(e,"_setRequestToAAXInFlightState-cmdQueue")}}))}catch(t){Object(Qt.b)(t,"_setRequestToAAXInFlightState")}}function yt(t){try{return Object(Bt.m)(t,"type")&&!(t instanceof Document)&&"amp"===t.type}catch(t){return Object(Qt.b)(t,"_isLegacyAmpCreative"),!1}}function Ot(t,e){try{return void 0!==e&&Object(Bt.m)(e,"ampEnv")&&e.ampEnv||yt(t)}catch(t){return void Object(Qt.b)(t,"_isAmpImpression")}}function jt(t){return t.split("x")}function vt(t,e,n){try{Object(Ht.f)()}catch(t){Object(Qt.b)(t,"_renderImp-pixels")}try{var r=void 0===n?"0.0.0":n.cv;if(Ot(t,n)&&Object(Lt.k)(window,!0))return yt(t)?Object(Ht.c)("renderFootprint","amp"):Object(Ht.c)("renderFootprint","multi-amp-".concat(r)),void q(t,n);if(Object(Ut.c)(window)&&void 0!==n&&Object(Bt.m)(n,"kvMap")&&Object(Bt.m)(n.kvMap,"amznhost"))return Object(Ht.c)("renderFootprint","multi-sf-".concat(r)),void q(t,n);var i=!1;"string"==typeof e&&0===e.indexOf("sp|")&&(e=e.substring(3),i=!0);var o,c=e||t.amzniid,a=E(c,i),s=a.slotBid,u=a.dealId,d=!1;if(void 0!==n&&Object(Bt.m)(n,"bidType")&&"outstream"===n.bidType&&(d=!0,s&&Object(Bt.m)(s,"bidConfig")&&(s.bidConfig.amznsz=s.bidConfig.amznsz?s.bidConfig.amznsz:"640x360")),s){if(o=u&&1<=u.length?jt("sp"===u?s.bidConfig.amznsz_sp:D(c,s,u)):jt(s.bidConfig.amznsz),1===arguments.length)return Object(Ht.c)("renderFootprint","JSONp"),void F({doc:s.doc,bidID:s.bidConfig.amzniid,sizes:o,html:t.html,inheritSize:s.inheritSize||!1});Object(Ht.c)("bidRenderState",s.bidState);var l=i?"sharedpmp":"open";void 0!==n?Object(Ht.c)("renderFootprint","multi-".concat(l,"-").concat(r)):Object(Ht.c)("renderFootprint","standard-".concat(l,"-").concat(r)),s.bidState===Ft.c.rendered&&tt(s),xt.a.dispatch({type:"BID_STATE_CHANGE",slotID:s.slotID,_targetingSetID:s._targetingSetID,bidState:Ft.c.rendered,ts:Date.now()});var f=s.host,b=s.bidConfig.slotID,p="amznad".concat(Math.round(1e6*Math.random())),m={bidID:c,doc:t,slotID:b,pp:St("amznbid",s,u),host:f,adID:p,sizes:o,amznp:St("amznp",s,u),crID:St("crid",s,u),fif:!1,dealId:u,isSharedPMP:i,cfe:s.cfe,isOutstream:d,inheritSize:Object(Bt.l)(n)&&Object(Bt.m)(n,"inheritSize")&&!0===n.inheritSize};if("1"===s.bidConfig.fif)m.fif=!0,xt.a.dispatch({type:"UPDATE_BID_INFO_PROP",slotID:s.slotID,iid:e,key:"doc",value:t}),xt.a.dispatch({type:"UPDATE_BID_INFO_PROP",slotID:s.slotID,iid:e,key:"inheritSize",value:m.inheritSize}),Object(Xt.b)(L(m),(function(){}),document,(function(){return Object(Qt.b)(new Error("Error Loading JSONP Render Callback"),"renderImp-fif-callback-load",!0)}));else if(d){var g=Object(Vt.c)(m,Ft.b),h=Object(Vt.b)(g,Ft.y);m.html=h,F(m)}else xt.a.getState().aaxViewabilityEnabled?wt(m,t):M(m);d||H(t,m)}else Object(Qt.b)(new Error("Invalid bid ID tried to render"),"_renderImp-invalidId",!0)}catch(t){Object(Qt.b)(t,"_renderImp",!0)}}function St(t,e,n){try{var r="";if(void 0!==n&&1<=n.length){var i="".concat(t,"_sp");"sp"===n&&Object(Bt.m)(e.bidConfig,i)&&(r=e.bidConfig[i])}else Object(Bt.m)(e.bidConfig,t)&&(r=e.bidConfig[t]);return r}catch(t){return Object(Qt.b)(t,"_getProperBidInfoValue"),""}}function wt(t,e){try{var n=e.createElement("script");n.type="text/javascript",n.async=!0;var r={doc:e,bidID:t.bidID,states:{csmLoaded:!1,iframeLoaded:!1,shouldRunViewability:!0}},i=U.bind(null,r);Object(Xt.a)(n,(function(){r.states.csmLoaded=!0,i()}));try{n.addEventListener("error",(function(t){return Object(Ht.b)({_type:"csm_fail",ts:Date.now(),msg:t.message})}))}catch(t){Object(Qt.b)(t,"_loadViewabilityAd-csm")}M(t,r,i),n.src=xt.a.getState().cfg.CSM_JS,k(e,n)}catch(t){Object(Qt.b)(t,"_loadViewabilityAd")}}function _t(t){try{Object(Kt.h)(t),l(t),Object(Bt.m)(t,"slots")&&(xt.a.dispatch({type:"UPDATE_SLOT_BIDS",bids:T(t)}),Object(Bt.m)(t,"ev")&&xt.a.dispatch({type:"SET_VIEWABILITY",viewability:t.ev}),Object(Bt.m)(t,"cfn")&&xt.a.dispatch({type:"SET_CFG",cfg:{CSM_JS:"//"===t.cfn.substring(0,2)?t.cfn:"//c.amazon-adsystem.com/".concat(t.cfn)}})),f(t)}catch(t){Object(Qt.b)(t,"_bids",!0)}}function Et(){return"number"==typeof xt.a.getState().cfg.MAX_SLOTS_PER_REQUEST&&0<xt.a.getState().cfg.MAX_SLOTS_PER_REQUEST}function Dt(t,e){try{Object(kt.a)(xt.a.getState().config.gdpr,(function(n){var r=Object(Zt.a)(n);It(t,e,n,r)}))}catch(t){Object(Qt.b)(t,"_getConfigsAndFetchBids",!0)}}function It(t,e,n,r){try{Object($t.b)(e,["function","undefined"])||Object(Qt.c)("fetchBids.callback",ie(e),"function"),"function"!=typeof e&&(e=function(){}),Object(Bt.l)(t)||(Object(Qt.c)("fetchBids.bidConfig",ie(t),"object"),t={}),Object($t.a)(t.timeout)||("string"==typeof t.timeout?Object(Qt.b)({name:"string-".concat(t.timeout),message:"fetchBids.bidConfig.timeout was a non-numeric string '".concat(t.timeout,"'")},"TypeError-fetchBids.bidConfig.timeout",!0):Object(Qt.c)("fetchBids.bidConfig.timeout",ie(t.timeout),"number")),Object(Bt.m)(t,"params")&&!Object(Bt.l)(t.params)?Object(Qt.c)("fetchBids.bidConfig.params",ie(t.params),"object"):Object(Bt.m)(t,"params")&&Object(Bt.l)(t.params)&&Object.keys(t.params).forEach((function(e){return!(void 0===t.params||"string"!=typeof t.params[e]&&"number"!=typeof t.params[e]&&(Object(Bt.k)(t.params[e])?!t.params[e].reduce((function(t,e){return t&&("string"==typeof e||"number"==typeof e)}),!0)&&(Object(Qt.b)({name:"non-string array item",message:"'fetchBids.bidConfig.params.".concat(e," contains a non-string item")},"TypeError-fetchBids.bidConfig.params.".concat(e),!0),1):(Object(Qt.c)("fetchBids.bidConfig.params.".concat(e),ie(t.params[e]),"string' or 'array"),1)))})),Object(Bt.m)(t,"blockedBidders")&&!Object(Bt.k)(t.blockedBidders)?Object(Qt.c)("fetchBids.bidConfig.blockedBidders",ie(t.blockedBidders),"array"):Object(Bt.m)(t,"blockedBidders")&&Object(Bt.k)(t.blockedBidders)&&(t.blockedBidders.reduce((function(t,e){return t&&("string"==typeof e||"number"==typeof e)}),!0)||Object(Qt.b)({name:"non-string array item",message:"'fetchBids.bidConfig.blockedBidders contains a non-string item"},"TypeError-fetchBids.bidConfig.blockedBidders",!0)),Object(Bt.m)(t,"blockedBidders")?Object(Ht.c)("blockedBidders-fetchBids","y"):Object(Ht.c)("blockedBidders-fetchBids","n"),Object(Bt.m)(t,"slots")&&!Object(Bt.k)(t.slots)&&Object(Qt.c)("fetchBids.bidConfig.slots",ie(t.slots),"array")}catch(i){Object(Qt.b)(i,"_fetchBids-validation",!0)}var i=xt.a.getState().config.simplerGPT,o=ne(ne({},t),{},{bidReqID:"".concat(xt.a.getState().AAXReqs.length),slots:[],validSlots:[],networkReqs:[]}),c=!1;try{!0===i&&(!Object(Bt.m)(t,"slots")||Object(Bt.m)(t,"slots")&&Object(Bt.k)(t.slots)&&0<t.slots.length&&Object(Bt.m)(t.slots[0],"getSlotElementId"))?0===Object(Nt.b)(Jt.a).length?(Object(Qt.b)(new Error("fetchBids was called in simplerGPT mode before any slots were defined in GPT"),"_fetchBids-simplerGpt-NoSlots",!0),c=!0,o.slots=[]):(t.slots?(Object(Ht.c)("slots","gpt-provided"),o.slots=t.slots.map((function(t){return new Gt.b(t)}))):(Object(Ht.c)("slots","gpt-fetch"),o.slots=Object(Nt.b)(Jt.a)),o.slots=o.slots.filter(Nt.a),0===o.slots.length&&(Object(Qt.b)(new Error("No GPT slots provided to apstag.fetchBids() had valid sizes"),"_fetchBids-simplerGpt-NoValidSizes",!0),c=!0)):Object(Bt.m)(t,"slots")&&Object(Bt.k)(t.slots)&&(i?Object(Ht.c)("slots","gpt-aps"):Object(Ht.c)("slots","aps"),o.slots=t.slots.map((function(t){return new Wt.a(t)}))),o.validSlots=o.slots.filter((function(t){return t.isValid()}))}catch(i){Object(Qt.b)(i,"_fetchBids-getSlots",!0)}var a=Object(Lt.i)(o,xt.a.getState());try{e=Object(Lt.b)(V(e,o),a)}catch(i){Object(Qt.b)(i,"_fetchBids-wrapCallback",!0)}try{if(0===o.validSlots.length)return!1===c&&Object(Qt.b)(new Error("No valid slots provided to apstag.fetchBids"),"_fetchBids-noSlots",!0),void setTimeout(e.bind(null,[]),10);try{var s=1===o.slots.length?"single":"multi",u=Date.now()-b<=Ft.q?"onload":"ondelay",d=xt.a.getState().AAXReqs.reduce((function(t,e){return e.bidConfig.slots.forEach((function(e){Object(Bt.j)(t,e.slotID)||t.push(e.slotID)})),t}),[]);o.slots.map((function(t){return t.slotID})).map((function(t){return Object(Bt.j)(d,t)})).map((function(t){return t?"refresh":"initial"})).filter((function(t,e,n){return n.indexOf(t)===e})).forEach((function(t){return Object(Ht.c)("fetchBids","".concat(s,"-").concat(u,"-").concat(t))}))}catch(i){Object(Qt.b)(i,"_fetchBids-feature")}var l;if(ht(o.slots.filter(Nt.d).map(Nt.c)),xt.a.dispatch({type:"NEW_FETCH_BID_REQUEST",fid:o.bidReqID,pto:a}),xt.a.dispatch({type:"RECORD_ORIGINAL_BID_CONFIG",bidConfig:o}),Object(qt.d)("fake_bids"))G(o);else if(Ft.k)if(xt.a.dispatch({type:"SHOULD_CHUNK_REQUESTS",value:Object(Bt.n)(xt.a.getState().cfg.CHUNK_BID_REQUESTS_PROPORTION)}),xt.a.getState().experiments.chunkRequests&&Et()){l=Tt(o);for(var f=0;f<l.length;f++)l[f].bidReqID="".concat(o.bidReqID,"-").concat(f);xt.a.dispatch({type:"ADD_CHUNKED_REQUESTS",fid:o.bidReqID,numChunks:l.length}),l.forEach((function(t){p(Object(Kt.d)(t,a,n,r),e,t.bidReqID)}))}else p(Object(Kt.d)(o,a,n,r),e,o.bidReqID);else Object(Xt.b)(Object(Kt.d)(o,a,n,r),e)}catch(i){Object(Qt.b)(i,"_fetchBids",!0)}}function Tt(t){try{for(var e=Math.ceil(t.validSlots.length/xt.a.getState().cfg.MAX_SLOTS_PER_REQUEST),n=new Array(e),r=0;r<e;r++){var i=r*xt.a.getState().cfg.MAX_SLOTS_PER_REQUEST;n[r]={slots:t.validSlots.slice(i,i+xt.a.getState().cfg.MAX_SLOTS_PER_REQUEST)}}return n.map((function(e){return ne(ne({},t),e)}))}catch(e){return Object(Qt.b)(e,"chunkConfig",!0),[]}}function At(t){try{Object(Bt.m)(xt.a.getState().config,"adServer")?Jt.a.isSupported?(P(t),Y()):Object(Qt.b)(new Error("apstag.setDisplayBids called with unsupported ad server: ".concat(xt.a.getState().config.adServer)),"_setDisplayBids-invalidAdServer",!0):Object(Qt.b)(new Error("apstag.setDisplayBids called without specifying ad server"),"_setDisplayBids-noAdServer",!0)}catch(t){Object(Qt.b)(t,"_setDisplayBids",!0)}}function Rt(t,e){try{h(t),Object(Jt.b)(t.adServer),gt(),Object(Zt.b)()}catch(t){Object(Qt.b)(t,"_init")}"function"==typeof e&&e()}function Ct(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:"display",e=xt.a.getState();try{switch(t){case"display":return Object(Ht.c)("targeting","targetingKeys-display"),e.config.useSafeFrames?[].concat(ee(Ft.i),["amznhost"]):Ft.i;case"video":return Object(Ht.c)("targeting","targetingKeys-video"),e.config.useSafeFrames?[].concat(ee(Ft.x),["amznhost"]):Ft.x;default:if(Object(Kt.g)(xt.a.getState(),Jt.a)){if(Object(Ht.c)("targeting","targetingKeys-newBid"),Object(Bt.k)(xt.a.getState().targetingKeys[t]))return xt.a.getState().targetingKeys[t]}else Object(Ht.c)("targeting","targetingKeys-invalid");return[]}}catch(t){return Object(Qt.b)(t,"_targetingKeys",!0),[]}}function Pt(){try{return xt.a.getState().AAXReqs.reduce((function(t,e){return e.bidConfig.slots.reduce((function(t,e){return t[e.slotID]=e.slotName,t}),t)}),{})}catch(t){return Object(Qt.b)(t,"_getSlotIdToNameMapping",!0),{}}}function zt(t,e){var n=e;return function(){return r({method:t,args:arguments}),n.apply(void 0,arguments)}}try{Object(Bt.m)(window,"apstag")&&Object(Bt.m)(window.apstag,"_Q")&&0<window.apstag._Q.length&&xt.a.dispatch({type:"SET_Q",Q:window.apstag._Q})}catch(t){Object(Qt.b)(t,"apstag-storeQ",!0)}window.apstag=(nt={punt:_t,init:Rt,debug:qt.a,_getSlotIdToNameMapping:Pt,targetingKeys:Ct,fetchBids:Dt,setDisplayBids:At,renderImp:vt,bids:_t,deleteId:te.a,updateId:te.d,renewId:te.c,dpa:te.a,upa:te.d,rpa:te.c,thirdPartyData:{},isGDPRRegion:!1},Object.keys(nt).forEach((function(t){"function"==typeof nt[t]&&(nt[t]=zt(t,nt[t]),nt[t]=Object(Qt.d)(nt[t],t))})),n?Object(qt.b)(!0,t):e&&Object(qt.b)(!1,t),!0===Object(qt.c)("exposeApi")&&(nt._api={_getBidSetInfo:lt,_applyTargetingToGPTSlot:A,dispatch:xt.a.dispatch,_clearTargetingFromGPTSlot:j,_clearBidSetOnSlot:v,_doFbSync:z,_getCurrentSlotBids:w,_creativeURL:L,getSlotFetchCounts:it,buildBidUrl:Kt.d}),nt),function(){try{if(xt.a.dispatch({type:"SHOULD_SAMPLE_FEATURES",value:Object(Bt.n)(xt.a.getState().cfg.FEATURE_SAMPLING_RATE)}),xt.a.dispatch({type:"SHOULD_CF_ROUTE",value:Object(Bt.n)(xt.a.getState().cfg.CF_ROUTING_RATE)}),xt.a.getState().experiments.shouldCFRoute&&xt.a.dispatch({type:"SET_HOST",hostName:"DEFAULT_AAX_BID_HOST",hostValue:"c.amazon-adsystem.com"}),xt.a.dispatch({type:"SHOULD_SAMPLE_LATENCY",value:Object(Bt.n)(xt.a.getState().cfg.LATENCY_SAMPLING_RATE)}),null!==xt.a.getState().cfg.TEST_BID_ENDPOINT){var t=Object(Bt.n)(xt.a.getState().cfg.TEST_PATH_FREQUENCY);xt.a.dispatch({type:"SHOULD_USE_TEST_BID_ENDPOINT",value:t}),t&&null!==xt.a.getState().cfg.TEST_PATH_LATENCY_SAMPLE_RATE&&xt.a.dispatch({type:"SHOULD_SAMPLE_LATENCY",value:Object(Bt.n)(xt.a.getState().cfg.TEST_PATH_LATENCY_SAMPLE_RATE)})}xt.a.dispatch({type:"SHOULD_SAMPLE_SLOT_RENDER",value:Object(Bt.n)(xt.a.getState().cfg.SLOT_RENDER_SAMPLING_RATE)});var e=xt.a.getState();(e.experiments.shouldSampleLatency||e.displayAdServer.shouldSampleRender)&&rt(),e.displayAdServer.shouldSampleRender&&ct(),e.experiments.shouldSampleLatency&&at()}catch(t){Object(Qt.b)(t,"apstag-sampleLatency")}try{g()}catch(t){Object(Qt.b)(t,"apstag-doLast")}if(!Object(Lt.k)(window,!0))try{var n=function(t){t&&"object"!==ie(t)||(t="Request Timeout or Error"),Object(Qt.b)({message:"csm-rtb-comm-js loading failed",name:t},"__csm-rtb-comm-js__")};Object(Xt.d)({url:xt.a.getState().cfg.CSM_RTB_COMMUNICATOR_JS,onload:function t(e){e.readyState===XMLHttpRequest.DONE&&200===e.status?eval(e.responseText):n(JSON.stringify({status:e.statusText,response:e.responseXML}))},onerror:n,ontimeout:n})}catch(t){Object(Qt.b)(t,"__load-csm-rtb-comm-js__")}Object(qt.e)()}()}())}catch(t){Object(Qt.b)(t,"apstag")}}]);
//# sourceMappingURL=apstag.js.map