/*! For license information please see desktop.bundle.js.LICENSE.txt */ !function(){try{var t="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},e=(new Error).stack;e&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[e]="c563fce2-9c1a-4055-886b-e1b8aabf1c0a",t._sentryDebugIdIdentifier="sentry-dbid-c563fce2-9c1a-4055-886b-e1b8aabf1c0a")}catch(t){}}();var _global="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};_global.SENTRY_RELEASE={id:"193cb90"},function(){var t={341:function(t,e,n){"use strict";function r(){return"undefined"!=typeof __SENTRY_BROWSER_BUNDLE__&&!!__SENTRY_BROWSER_BUNDLE__}function i(){return"npm"}n.d(e,{Z:function(){return r},e:function(){return i}})},284:function(t,e,n){"use strict";n.d(e,{fj:function(){return o},wD:function(){return i}});var r=n(341);function i(){return!(0,r.Z)()&&"[object process]"===Object.prototype.toString.call("undefined"!=typeof process?process:0)}function o(t,e){return t.require(e)}t=n.hmd(t)},297:function(t,e,n){"use strict";n.d(e,{lu:function(){return l},zf:function(){return u}});var r=n(284),i=n(722);t=n.hmd(t);const o=(0,i.VZ)(),s={nowSeconds:()=>Date.now()/1e3};const a=(0,r.wD)()?function(){try{return(0,r.fj)(t,"perf_hooks").performance}catch(t){return}}():function(){const{performance:t}=o;if(!t||!t.now)return;return{now:()=>t.now(),timeOrigin:Date.now()-t.now()}}(),c=void 0===a?s:{nowSeconds:()=>(a.timeOrigin+a.now())/1e3},l=s.nowSeconds.bind(s),u=c.nowSeconds.bind(c);let p;(()=>{const{performance:t}=o;if(!t||!t.now)return void(p="none");const e=36e5,n=t.now(),r=Date.now(),i=t.timeOrigin?Math.abs(t.timeOrigin+n-r):e,s=i(()=>{var t=Object.defineProperty,e=Object.getOwnPropertyDescriptor,n=Object.getOwnPropertyNames,r=Object.prototype.hasOwnProperty,i={};((e,n)=>{for(var r in n)t(e,r,{get:n[r],enumerable:!0})})(i,{Iti:()=>b,default:()=>_});var o=[["af","93"],["al","355"],["dz","213"],["as","1",5,["684"]],["ad","376"],["ao","244"],["ai","1",6,["264"]],["ag","1",7,["268"]],["ar","54"],["am","374"],["aw","297"],["ac","247"],["au","61",0],["at","43"],["az","994"],["bs","1",8,["242"]],["bh","973"],["bd","880"],["bb","1",9,["246"]],["by","375"],["be","32"],["bz","501"],["bj","229"],["bm","1",10,["441"]],["bt","975"],["bo","591"],["ba","387"],["bw","267"],["br","55"],["io","246"],["vg","1",11,["284"]],["bn","673"],["bg","359"],["bf","226"],["bi","257"],["kh","855"],["cm","237"],["ca","1",1,["204","226","236","249","250","263","289","306","343","354","365","367","368","382","387","403","416","418","428","431","437","438","450","584","468","474","506","514","519","548","579","581","584","587","604","613","639","647","672","683","705","709","742","753","778","780","782","807","819","825","867","873","879","902","905"]],["cv","238"],["bq","599",1,["3","4","7"]],["ky","1",12,["345"]],["cf","236"],["td","235"],["cl","56"],["cn","86"],["cx","61",2,["89164"]],["cc","61",1,["89162"]],["co","57"],["km","269"],["cg","242"],["cd","243"],["ck","682"],["cr","506"],["ci","225"],["hr","385"],["cu","53"],["cw","599",0],["cy","357"],["cz","420"],["dk","45"],["dj","253"],["dm","1",13,["767"]],["do","1",2,["809","829","849"]],["ec","593"],["eg","20"],["sv","503"],["gq","240"],["er","291"],["ee","372"],["sz","268"],["et","251"],["fk","500"],["fo","298"],["fj","679"],["fi","358",0],["fr","33"],["gf","594"],["pf","689"],["ga","241"],["gm","220"],["ge","995"],["de","49"],["gh","233"],["gi","350"],["gr","30"],["gl","299"],["gd","1",14,["473"]],["gp","590",0],["gu","1",15,["671"]],["gt","502"],["gg","44",1,["1481","7781","7839","7911"]],["gn","224"],["gw","245"],["gy","592"],["ht","509"],["hn","504"],["hk","852"],["hu","36"],["is","354"],["in","91"],["id","62"],["ir","98"],["iq","964"],["ie","353"],["im","44",2,["1624","74576","7524","7924","7624"]],["il","972"],["it","39",0],["jm","1",4,["876","658"]],["jp","81"],["je","44",3,["1534","7509","7700","7797","7829","7937"]],["jo","962"],["kz","7",1,["33","7"]],["ke","254"],["ki","686"],["xk","383"],["kw","965"],["kg","996"],["la","856"],["lv","371"],["lb","961"],["ls","266"],["lr","231"],["ly","218"],["li","423"],["lt","370"],["lu","352"],["mo","853"],["mg","261"],["mw","265"],["my","60"],["mv","960"],["ml","223"],["mt","356"],["mh","692"],["mq","596"],["mr","222"],["mu","230"],["yt","262",1,["269","639"]],["mx","52"],["fm","691"],["md","373"],["mc","377"],["mn","976"],["me","382"],["ms","1",16,["664"]],["ma","212",0],["mz","258"],["mm","95"],["na","264"],["nr","674"],["np","977"],["nl","31"],["nc","687"],["nz","64"],["ni","505"],["ne","227"],["ng","234"],["nu","683"],["nf","672"],["kp","850"],["mk","389"],["mp","1",17,["670"]],["no","47",0],["om","968"],["pk","92"],["pw","680"],["ps","970"],["pa","507"],["pg","675"],["py","595"],["pe","51"],["ph","63"],["pl","48"],["pt","351"],["pr","1",3,["787","939"]],["qa","974"],["re","262",0],["ro","40"],["ru","7",0],["rw","250"],["ws","685"],["sm","378"],["st","239"],["sa","966"],["sn","221"],["rs","381"],["sc","248"],["sl","232"],["sg","65"],["sx","1",21,["721"]],["sk","421"],["si","386"],["sb","677"],["so","252"],["za","27"],["kr","82"],["ss","211"],["es","34"],["lk","94"],["bl","590",1],["sh","290"],["kn","1",18,["869"]],["lc","1",19,["758"]],["mf","590",2],["pm","508"],["vc","1",20,["784"]],["sd","249"],["sr","597"],["sj","47",1,["79"]],["se","46"],["ch","41"],["sy","963"],["tw","886"],["tj","992"],["tz","255"],["th","66"],["tl","670"],["tg","228"],["tk","690"],["to","676"],["tt","1",22,["868"]],["tn","216"],["tr","90"],["tm","993"],["tc","1",23,["649"]],["tv","688"],["ug","256"],["ua","380"],["ae","971"],["gb","44",0],["us","1",0],["uy","598"],["vi","1",24,["340"]],["uz","998"],["vu","678"],["va","39",1,["06698"]],["ve","58"],["vn","84"],["wf","681"],["eh","212",1,["5288","5289"]],["ye","967"],["zm","260"],["zw","263"],["ax","358",1,["18"]]],s=[];for(let t=0;tt.replace(/\D/g,""),h=(t="")=>t.normalize("NFD").replace(/[\u0300-\u036f]/g,"").toLowerCase(),f=t=>{const e=d(t);if("1"===e.charAt(0)){const t=e.substr(1,3);return-1!==p.indexOf(t)}return!1},m=(t,e)=>t.namee.name?1:0,g=(t,e,n)=>{const r=document.createElement(t);return e&&Object.entries(e).forEach((([t,e])=>r.setAttribute(t,e))),n&&n.appendChild(r),r},v=t=>{const{instances:e}=window.intlTelInputGlobals;Object.values(e).forEach((e=>e[t]()))},b=class{id;promise;telInput;activeItem;highlightedItem;options;hadInitialPlaceholder;isRTL;selectedCountryData;countries;dialCodeMaxLen;dialCodeToIso2Map;dialCodes;preferredCountries;countryContainer;selectedCountry;selectedCountryInner;selectedCountryA11yText;selectedDialCode;dropdownArrow;dropdownContent;searchInput;searchResultsA11yText;countryList;dropdown;hiddenInput;hiddenInputCountry;maxCoreNumberLength;defaultCountry;_handleHiddenInputSubmit;_handleLabelClick;_handleClickSelectedCountry;_handleCountryContainerKeydown;_handleInputEvent;_handleKeydownEvent;_handleWindowScroll;_handleMouseoverCountryList;_handleClickCountryList;_handleClickOffToClose;_handleKeydownOnDropdown;_handleSearchChange;resolveAutoCountryPromise;rejectAutoCountryPromise;resolveUtilsScriptPromise;rejectUtilsScriptPromise;constructor(t,e={}){this.id=l++,this.telInput=t,this.activeItem=null,this.highlightedItem=null,this.options=Object.assign({},u,e),this.hadInitialPlaceholder=Boolean(t.getAttribute("placeholder"))}_init(){this.options.useFullscreenPopup&&(this.options.fixDropdownWidth=!1),this.options.countrySearch&&!this.options.useFullscreenPopup&&(this.options.fixDropdownWidth=!0);const t=this.options.allowDropdown&&!this.options.showSelectedDialCode;!this.options.showFlags&&t&&(this.options.showFlags=!0),this.options.useFullscreenPopup&&!this.options.dropdownContainer&&(this.options.dropdownContainer=document.body),this.isRTL=!!this.telInput.closest("[dir=rtl]"),this.options.i18n={...c,...this.options.i18n};const e=new Promise(((t,e)=>{this.resolveAutoCountryPromise=t,this.rejectAutoCountryPromise=e})),n=new Promise(((t,e)=>{this.resolveUtilsScriptPromise=t,this.rejectUtilsScriptPromise=e}));this.promise=Promise.all([e,n]),this.selectedCountryData={},this._processCountryData(),this._generateMarkup(),this._setInitialState(),this._initListeners(),this._initRequests()}_processCountryData(){this._processAllCountries(),this._processDialCodes(),this._processPreferredCountries(),this._translateCountryNames(),(this.options.onlyCountries.length||this.options.i18n)&&this.countries.sort(m)}_addToDialCodeMap(t,e,n){e.length>this.dialCodeMaxLen&&(this.dialCodeMaxLen=e.length),this.dialCodeToIso2Map.hasOwnProperty(e)||(this.dialCodeToIso2Map[e]=[]);for(let n=0;nt.toLowerCase()));this.countries=a.filter((t=>e.indexOf(t.iso2)>-1))}else if(e.length){const t=e.map((t=>t.toLowerCase()));this.countries=a.filter((e=>-1===t.indexOf(e.iso2)))}else this.countries=a}_translateCountryNames(){for(let t=0;t
`),a+=`${i.name}`,a+=`+${i.dialCode}`,s.insertAdjacentHTML("beforeend",a)}}_setInitialState(t=!1){const e=this.telInput.getAttribute("value"),n=this.telInput.value,r=!e||"+"!==e.charAt(0)||n&&"+"===n.charAt(0)?n:e,i=this._getDialCode(r),o=f(r),{initialCountry:s}=this.options;if(i&&!o)this._updateCountryFromNumber(r);else if("auto"!==s||t){const t=s?s.toLowerCase():"";t&&this._getCountryData(t,!0)?this._setCountry(t):i&&o?this._setCountry("us"):this._setCountry()}r&&this._updateValFromNumber(r)}_initListeners(){this._initTelInputListeners(),this.options.allowDropdown&&this._initDropdownListeners(),(this.hiddenInput||this.hiddenInputCountry)&&this.telInput.form&&this._initHiddenInputListener()}_initHiddenInputListener(){this._handleHiddenInputSubmit=()=>{this.hiddenInput&&(this.hiddenInput.value=this.getNumber()),this.hiddenInputCountry&&(this.hiddenInputCountry.value=this.getSelectedCountryData().iso2||"")},this.telInput.form?.addEventListener("submit",this._handleHiddenInputSubmit)}_initDropdownListeners(){this._handleLabelClick=t=>{this.dropdownContent.classList.contains("iti__hide")?this.telInput.focus():t.preventDefault()};const t=this.telInput.closest("label");t&&t.addEventListener("click",this._handleLabelClick),this._handleClickSelectedCountry=()=>{!this.dropdownContent.classList.contains("iti__hide")||this.telInput.disabled||this.telInput.readOnly||this._openDropdown()},this.selectedCountry.addEventListener("click",this._handleClickSelectedCountry),this._handleCountryContainerKeydown=t=>{this.dropdownContent.classList.contains("iti__hide")&&["ArrowUp","ArrowDown"," ","Enter"].includes(t.key)&&(t.preventDefault(),t.stopPropagation(),this._openDropdown()),"Tab"===t.key&&this._closeDropdown()},this.countryContainer.addEventListener("keydown",this._handleCountryContainerKeydown)}_initRequests(){this.options.utilsScript&&!window.intlTelInputUtils?window.intlTelInputGlobals.documentReady()?window.intlTelInputGlobals.loadUtils(this.options.utilsScript):window.addEventListener("load",(()=>{window.intlTelInputGlobals.loadUtils(this.options.utilsScript)})):this.resolveUtilsScriptPromise(),"auto"!==this.options.initialCountry||this.selectedCountryData.iso2?this.resolveAutoCountryPromise():this._loadAutoCountry()}_loadAutoCountry(){window.intlTelInputGlobals.autoCountry?this.handleAutoCountry():window.intlTelInputGlobals.startedLoadingAutoCountry||(window.intlTelInputGlobals.startedLoadingAutoCountry=!0,"function"==typeof this.options.geoIpLookup&&this.options.geoIpLookup(((t="")=>{const e=t.toLowerCase();e&&this._getCountryData(e,!0)?(window.intlTelInputGlobals.autoCountry=e,setTimeout((()=>v("handleAutoCountry")))):(this._setInitialState(!0),v("rejectAutoCountryPromise"))}),(()=>{this._setInitialState(!0),v("rejectAutoCountryPromise")})))}_initTelInputListeners(){const{strictMode:t,formatAsYouType:e}=this.options;let n=!1;this._handleInputEvent=r=>{this._updateCountryFromNumber(this.telInput.value)&&this._triggerCountryChange();const i=r&&r.data&&/[^+0-9]/.test(r.data),o=r&&"insertFromPaste"===r.inputType&&this.telInput.value;if(i||o&&!t?n=!0:/[^+0-9]/.test(this.telInput.value)||(n=!1),e&&!n){const t=this.telInput.selectionStart||0,e=this.telInput.value.substring(0,t).replace(/[^+0-9]/g,"").length,n=r&&"deleteContentForward"===r.inputType,i=this._formatNumberAsYouType(),o=((t,e,n,r)=>{if(0===n&&!r)return 0;let i=0;for(let n=0;n{if(t.key&&1===t.key.length&&!t.altKey&&!t.ctrlKey&&!t.metaKey){const e=0===this.telInput.selectionStart&&"+"===t.key,n=/^[0-9]$/.test(t.key),r=e||n,i=this._getFullNumber(),o=window.intlTelInputUtils.getCoreNumber(i,this.selectedCountryData.iso2),s=this.maxCoreNumberLength&&o.length>=this.maxCoreNumberLength;r&&!s||t.preventDefault()}},this.telInput.addEventListener("keydown",this._handleKeydownEvent))}_cap(t){const e=parseInt(this.telInput.getAttribute("maxlength")||"",10);return e&&t.length>e?t.substr(0,e):t}_trigger(t){const e=new Event(t,{bubbles:!0,cancelable:!0});this.telInput.dispatchEvent(e)}_openDropdown(){const{fixDropdownWidth:t,countrySearch:e}=this.options;if(t&&(this.dropdownContent.style.width=`${this.telInput.offsetWidth}px`),this.dropdownContent.classList.remove("iti__hide"),this.selectedCountry.setAttribute("aria-expanded","true"),this._setDropdownPosition(),this.activeItem&&!e)this._highlightListItem(this.activeItem,!1),this._scrollTo(this.activeItem,!0);else{const t=this.countryList.firstElementChild;t&&(this._highlightListItem(t,!1),this.countryList.scrollTop=0),e&&this.searchInput.focus()}this._bindDropdownListeners(),this.dropdownArrow.classList.add("iti__arrow--up"),this._trigger("open:countrydropdown")}_setDropdownPosition(){if(this.options.dropdownContainer&&this.options.dropdownContainer.appendChild(this.dropdown),!this.options.useFullscreenPopup){const r=this.telInput.getBoundingClientRect(),i=document.documentElement.scrollTop,o=r.top+i,s=this.telInput.offsetHeight,a=this.dropdownContent.offsetHeight,c=o+s+ai,u=!this.options.countrySearch&&!c&&l;if(t=this.dropdownContent,e="iti__dropdown-content--dropup",(n=u)&&!t.classList.contains(e)?t.classList.add(e):!n&&t.classList.contains(e)&&t.classList.remove(e),this.options.dropdownContainer){const t=u?0:s;this.dropdown.style.top=`${r.top+t}px`,this.dropdown.style.left=`${r.left}px`,this._handleWindowScroll=()=>this._closeDropdown(),window.addEventListener("scroll",this._handleWindowScroll)}}var t,e,n}_bindDropdownListeners(){this._handleMouseoverCountryList=t=>{const e=t.target?.closest(".iti__country");e&&this._highlightListItem(e,!1)},this.countryList.addEventListener("mouseover",this._handleMouseoverCountryList),this._handleClickCountryList=t=>{const e=t.target?.closest(".iti__country");e&&this._selectListItem(e)},this.countryList.addEventListener("click",this._handleClickCountryList);let t=!0;this._handleClickOffToClose=()=>{t||this._closeDropdown(),t=!1},document.documentElement.addEventListener("click",this._handleClickOffToClose);let e="",n=null;if(this._handleKeydownOnDropdown=t=>{["ArrowUp","ArrowDown","Enter","Escape"].includes(t.key)&&(t.preventDefault(),t.stopPropagation(),"ArrowUp"===t.key||"ArrowDown"===t.key?this._handleUpDownKey(t.key):"Enter"===t.key?this._handleEnterKey():"Escape"===t.key&&this._closeDropdown()),!this.options.countrySearch&&/^[a-zA-ZÀ-ÿа-яА-Я ]$/.test(t.key)&&(t.stopPropagation(),n&&clearTimeout(n),e+=t.key.toLowerCase(),this._searchForCountry(e),n=setTimeout((()=>{e=""}),1e3))},document.addEventListener("keydown",this._handleKeydownOnDropdown),this.options.countrySearch){const t=()=>{const t=this.searchInput.value.trim();t?this._filterCountries(t):this._filterCountries("",!0)};let e=null;this._handleSearchChange=()=>{e&&clearTimeout(e),e=setTimeout((()=>{t(),e=null}),100)},this.searchInput.addEventListener("input",this._handleSearchChange),this.searchInput.addEventListener("click",(t=>t.stopPropagation()))}}_filterCountries(t,e=!1){let n=!0;this.countryList.innerHTML="";const r=h(t);for(let t=0;t1&&(e="ArrowUp"===t?this.countryList.lastElementChild:this.countryList.firstElementChild),e){this._scrollTo(e,!1);const t=!this.options.countrySearch;this._highlightListItem(e,t)}}_handleEnterKey(){this.highlightedItem&&this._selectListItem(this.highlightedItem)}_searchForCountry(t){for(let e=0;es){e&&(u+=p);const t=i-a;n.scrollTop=u-t}}_updateDialCode(t){const e=this.telInput.value,n=`+${t}`;let r;if("+"===e.charAt(0)){const t=this._getDialCode(e);r=t?e.replace(t,n):n,this.telInput.value=r}}_getDialCode(t,e){let n="";if("+"===t.charAt(0)){let r="";for(let i=0;i"complete"===document.readyState,getCountryData:()=>a,getInstance:e=>{const n=e.getAttribute("data-intl-tel-input-id");return n?t.instances[n]:null},instances:{},loadUtils:t=>window.intlTelInputUtils||window.intlTelInputGlobals.startedLoadingUtilsScript?null:(window.intlTelInputGlobals.startedLoadingUtilsScript=!0,new Promise(((e,n)=>((t,e,n)=>{const r=document.createElement("script");r.onload=()=>{v("handleUtils"),e&&e()},r.onerror=()=>{v("rejectUtilsScriptPromise"),n&&n()},r.className="iti-load-utils",r.async=!0,r.src=t,document.body.appendChild(r)})(t,e,n)))),version:"21.2.8"};window.intlTelInputGlobals=t}var y,_=(t,e)=>{const n=new b(t,e);return n._init(),t.setAttribute("data-intl-tel-input-id",n.id.toString()),window.intlTelInputGlobals.instances[n.id]=n,n};return y=i,((i,o,s,a)=>{if(o&&"object"==typeof o||"function"==typeof o)for(let c of n(o))r.call(i,c)||c===s||t(i,c,{get:()=>o[c],enumerable:!(a=e(o,c))||a.enumerable});return i})(t({},"__esModule",{value:!0}),y)})().default,t.exports?t.exports=e():window.intlTelInput=e()},490:function(t,e,n){var r;!function(){function i(t,e,n){return t.call.apply(t.bind,arguments)}function o(t,e,n){if(!t)throw Error();if(2=e.f?i():t.fonts.load(function(t){return E(t)+" "+t.f+"00 300px "+x(t.c)}(e.a),e.h).then((function(t){1<=t.length?r():setTimeout(o,25)}),(function(){i()}))}()})),i=null,o=new Promise((function(t,n){i=setTimeout(n,e.f)}));Promise.race([o,r]).then((function(){i&&(clearTimeout(i),i=null),e.g(e.a)}),(function(){e.j(e.a)}))};var N={D:"serif",C:"sans-serif"},j=null;function B(){if(null===j){var t=/AppleWebKit\/([0-9]+)(?:\.([0-9]+))/.exec(window.navigator.userAgent);j=!!t&&(536>parseInt(t[1],10)||536===parseInt(t[1],10)&&11>=parseInt(t[2],10))}return j}function M(t,e,n){for(var r in N)if(N.hasOwnProperty(r)&&e===t.f[N[r]]&&n===t.f[N[r]])return!0;return!1}function U(t){var e,n=t.g.a.offsetWidth,r=t.h.a.offsetWidth;(e=n===t.f.serif&&r===t.f["sans-serif"])||(e=B()&&M(t,n,r)),e?a()-t.A>=t.w?B()&&M(t,n,r)&&(null===t.u||t.u.hasOwnProperty(t.a.c))?z(t,t.v):z(t,t.B):function(t){setTimeout(s((function(){U(this)}),t),50)}(t):z(t,t.v)}function z(t,e){setTimeout(s((function(){d(this.g.a),d(this.h.a),d(this.j.a),d(this.m.a),e(this.a)}),t),0)}function F(t,e,n){this.c=t,this.a=e,this.f=0,this.m=this.j=!1,this.s=n}L.prototype.start=function(){this.f.serif=this.j.a.offsetWidth,this.f["sans-serif"]=this.m.a.offsetWidth,this.A=a(),U(this)};var G=null;function H(t){0==--t.f&&t.j&&(t.m?((t=t.a).g&&h(t.f,[t.a.c("wf","active")],[t.a.c("wf","loading"),t.a.c("wf","inactive")]),I(t,"active")):O(t.a))}function V(t){this.j=t,this.a=new A,this.h=0,this.f=this.g=!0}function W(t,e,n,r,i){var o=0==--t.h;(t.f||t.g)&&setTimeout((function(){var t=i||null,a=r||{};if(0===n.length&&o)O(e.a);else{e.f+=n.length,o&&(e.j=o);var c,l=[];for(c=0;c=0;--i){var o=this.tryEntries[i],a=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var c=s.call(o,"catchLoc"),l=s.call(o,"finallyLoc");if(c&&l){if(this.prev=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&s.call(r,"finallyLoc")&&this.prev=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),D(n),y}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var i=r.arg;D(n)}return i}}throw Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:$(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),y}},n}t.exports=i,t.exports.__esModule=!0,t.exports.default=t.exports},319:function(t){function e(n){return t.exports=e="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.exports.__esModule=!0,t.exports.default=t.exports,e(n)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},799:function(t,e,n){var r=n(48)();t.exports=r;try{regeneratorRuntime=r}catch(t){"object"==typeof globalThis?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}}},e={};function n(r){var i=e[r];if(void 0!==i)return i.exports;var o=e[r]={id:r,loaded:!1,exports:{}};return t[r](o,o.exports,n),o.loaded=!0,o.exports}n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,{a:e}),e},n.d=function(t,e){for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),n.hmd=function(t){return(t=Object.create(t)).children||(t.children=[]),Object.defineProperty(t,"exports",{enumerable:!0,set:function(){throw new Error("ES Modules may not assign module.exports or exports.*, Use ESM export syntax, instead: "+t.id)}}),t},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},function(){"use strict";function t(t,e,n,r,i,o,s){try{var a=t[o](s),c=a.value}catch(t){return void n(t)}a.done?e(c):Promise.resolve(c).then(r,i)}function e(e){return function(){var n=this,r=arguments;return new Promise((function(i,o){var s=e.apply(n,r);function a(e){t(s,i,o,a,c,"next",e)}function c(e){t(s,i,o,a,c,"throw",e)}a(void 0)}))}}var r=n(799),i=n.n(r);const o=window,s=o.ShadowRoot&&(void 0===o.ShadyCSS||o.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,a=Symbol(),c=new WeakMap;class l{constructor(t,e,n){if(this._$cssResult$=!0,n!==a)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const e=this.t;if(s&&void 0===t){const n=void 0!==e&&1===e.length;n&&(t=c.get(e)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),n&&c.set(e,t))}return t}toString(){return this.cssText}}const u=t=>new l("string"==typeof t?t:t+"",void 0,a),p=(t,...e)=>{const n=1===t.length?t[0]:e.reduce(((e,n,r)=>e+(t=>{if(!0===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(n)+t[r+1]),t[0]);return new l(n,t,a)},d=s?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const n of t.cssRules)e+=n.cssText;return u(e)})(t):t;var h;const f=window,m=f.trustedTypes,g=m?m.emptyScript:"",v=f.reactiveElementPolyfillSupport,b={toAttribute(t,e){switch(e){case Boolean:t=t?g:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,e){let n=t;switch(e){case Boolean:n=null!==t;break;case Number:n=null===t?null:Number(t);break;case Object:case Array:try{n=JSON.parse(t)}catch(t){n=null}}return n}},y=(t,e)=>e!==t&&(e==e||t==t),_={attribute:!0,type:String,converter:b,reflect:!1,hasChanged:y},w="finalized";class k extends HTMLElement{constructor(){super(),this._$Ei=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$El=null,this._$Eu()}static addInitializer(t){var e;this.finalize(),(null!==(e=this.h)&&void 0!==e?e:this.h=[]).push(t)}static get observedAttributes(){this.finalize();const t=[];return this.elementProperties.forEach(((e,n)=>{const r=this._$Ep(n,e);void 0!==r&&(this._$Ev.set(r,n),t.push(r))})),t}static createProperty(t,e=_){if(e.state&&(e.attribute=!1),this.finalize(),this.elementProperties.set(t,e),!e.noAccessor&&!this.prototype.hasOwnProperty(t)){const n="symbol"==typeof t?Symbol():"__"+t,r=this.getPropertyDescriptor(t,n,e);void 0!==r&&Object.defineProperty(this.prototype,t,r)}}static getPropertyDescriptor(t,e,n){return{get(){return this[e]},set(r){const i=this[t];this[e]=r,this.requestUpdate(t,i,n)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)||_}static finalize(){if(this.hasOwnProperty(w))return!1;this[w]=!0;const t=Object.getPrototypeOf(this);if(t.finalize(),void 0!==t.h&&(this.h=[...t.h]),this.elementProperties=new Map(t.elementProperties),this._$Ev=new Map,this.hasOwnProperty("properties")){const t=this.properties,e=[...Object.getOwnPropertyNames(t),...Object.getOwnPropertySymbols(t)];for(const n of e)this.createProperty(n,t[n])}return this.elementStyles=this.finalizeStyles(this.styles),!0}static finalizeStyles(t){const e=[];if(Array.isArray(t)){const n=new Set(t.flat(1/0).reverse());for(const t of n)e.unshift(d(t))}else void 0!==t&&e.push(d(t));return e}static _$Ep(t,e){const n=e.attribute;return!1===n?void 0:"string"==typeof n?n:"string"==typeof t?t.toLowerCase():void 0}_$Eu(){var t;this._$E_=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$Eg(),this.requestUpdate(),null===(t=this.constructor.h)||void 0===t||t.forEach((t=>t(this)))}addController(t){var e,n;(null!==(e=this._$ES)&&void 0!==e?e:this._$ES=[]).push(t),void 0!==this.renderRoot&&this.isConnected&&(null===(n=t.hostConnected)||void 0===n||n.call(t))}removeController(t){var e;null===(e=this._$ES)||void 0===e||e.splice(this._$ES.indexOf(t)>>>0,1)}_$Eg(){this.constructor.elementProperties.forEach(((t,e)=>{this.hasOwnProperty(e)&&(this._$Ei.set(e,this[e]),delete this[e])}))}createRenderRoot(){var t;const e=null!==(t=this.shadowRoot)&&void 0!==t?t:this.attachShadow(this.constructor.shadowRootOptions);return((t,e)=>{s?t.adoptedStyleSheets=e.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet)):e.forEach((e=>{const n=document.createElement("style"),r=o.litNonce;void 0!==r&&n.setAttribute("nonce",r),n.textContent=e.cssText,t.appendChild(n)}))})(e,this.constructor.elementStyles),e}connectedCallback(){var t;void 0===this.renderRoot&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null===(t=this._$ES)||void 0===t||t.forEach((t=>{var e;return null===(e=t.hostConnected)||void 0===e?void 0:e.call(t)}))}enableUpdating(t){}disconnectedCallback(){var t;null===(t=this._$ES)||void 0===t||t.forEach((t=>{var e;return null===(e=t.hostDisconnected)||void 0===e?void 0:e.call(t)}))}attributeChangedCallback(t,e,n){this._$AK(t,n)}_$EO(t,e,n=_){var r;const i=this.constructor._$Ep(t,n);if(void 0!==i&&!0===n.reflect){const o=(void 0!==(null===(r=n.converter)||void 0===r?void 0:r.toAttribute)?n.converter:b).toAttribute(e,n.type);this._$El=t,null==o?this.removeAttribute(i):this.setAttribute(i,o),this._$El=null}}_$AK(t,e){var n;const r=this.constructor,i=r._$Ev.get(t);if(void 0!==i&&this._$El!==i){const t=r.getPropertyOptions(i),o="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==(null===(n=t.converter)||void 0===n?void 0:n.fromAttribute)?t.converter:b;this._$El=i,this[i]=o.fromAttribute(e,t.type),this._$El=null}}requestUpdate(t,e,n){let r=!0;void 0!==t&&(((n=n||this.constructor.getPropertyOptions(t)).hasChanged||y)(this[t],e)?(this._$AL.has(t)||this._$AL.set(t,e),!0===n.reflect&&this._$El!==t&&(void 0===this._$EC&&(this._$EC=new Map),this._$EC.set(t,n))):r=!1),!this.isUpdatePending&&r&&(this._$E_=this._$Ej())}async _$Ej(){this.isUpdatePending=!0;try{await this._$E_}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var t;if(!this.isUpdatePending)return;this.hasUpdated,this._$Ei&&(this._$Ei.forEach(((t,e)=>this[e]=t)),this._$Ei=void 0);let e=!1;const n=this._$AL;try{e=this.shouldUpdate(n),e?(this.willUpdate(n),null===(t=this._$ES)||void 0===t||t.forEach((t=>{var e;return null===(e=t.hostUpdate)||void 0===e?void 0:e.call(t)})),this.update(n)):this._$Ek()}catch(t){throw e=!1,this._$Ek(),t}e&&this._$AE(n)}willUpdate(t){}_$AE(t){var e;null===(e=this._$ES)||void 0===e||e.forEach((t=>{var e;return null===(e=t.hostUpdated)||void 0===e?void 0:e.call(t)})),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$Ek(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$E_}shouldUpdate(t){return!0}update(t){void 0!==this._$EC&&(this._$EC.forEach(((t,e)=>this._$EO(e,this[e],t))),this._$EC=void 0),this._$Ek()}updated(t){}firstUpdated(t){}}var x;k[w]=!0,k.elementProperties=new Map,k.elementStyles=[],k.shadowRootOptions={mode:"open"},null==v||v({ReactiveElement:k}),(null!==(h=f.reactiveElementVersions)&&void 0!==h?h:f.reactiveElementVersions=[]).push("1.6.3");const S=window,E=S.trustedTypes,T=E?E.createPolicy("lit-html",{createHTML:t=>t}):void 0,C="$lit$",O=`lit$${(Math.random()+"").slice(9)}$`,I="?"+O,A=`<${I}>`,R=document,D=()=>R.createComment(""),P=t=>null===t||"object"!=typeof t&&"function"!=typeof t,$=Array.isArray,L=t=>$(t)||"function"==typeof(null==t?void 0:t[Symbol.iterator]),N="[ \t\n\f\r]",j=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,B=/-->/g,M=/>/g,U=RegExp(`>|${N}(?:([^\\s"'>=/]+)(${N}*=${N}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),z=/'/g,F=/"/g,G=/^(?:script|style|textarea|title)$/i,H=t=>(e,...n)=>({_$litType$:t,strings:e,values:n}),V=H(1),W=H(2),Y=Symbol.for("lit-noChange"),q=Symbol.for("lit-nothing"),Z=new WeakMap,X=R.createTreeWalker(R,129,null,!1);function K(t,e){if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==T?T.createHTML(e):e}const J=(t,e)=>{const n=t.length-1,r=[];let i,o=2===e?"":"",s=j;for(let e=0;e"===c[0]?(s=null!=i?i:j,l=-1):void 0===c[1]?l=-2:(l=s.lastIndex-c[2].length,a=c[1],s=void 0===c[3]?U:'"'===c[3]?F:z):s===F||s===z?s=U:s===B||s===M?s=j:(s=U,i=void 0);const p=s===U&&t[e+1].startsWith("/>")?" ":"";o+=s===j?n+A:l>=0?(r.push(a),n.slice(0,l)+C+n.slice(l)+O+p):n+O+(-2===l?(r.push(void 0),e):p)}return[K(t,o+(t[n]||"")+(2===e?"":"")),r]};class Q{constructor({strings:t,_$litType$:e},n){let r;this.parts=[];let i=0,o=0;const s=t.length-1,a=this.parts,[c,l]=J(t,e);if(this.el=Q.createElement(c,n),X.currentNode=this.el.content,2===e){const t=this.el.content,e=t.firstChild;e.remove(),t.append(...e.childNodes)}for(;null!==(r=X.nextNode())&&a.length0){r.textContent=E?E.emptyScript:"";for(let n=0;n2||""!==n[0]||""!==n[1]?(this._$AH=Array(n.length-1).fill(new String),this.strings=n):this._$AH=q}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,e=this,n,r){const i=this.strings;let o=!1;if(void 0===i)t=tt(this,t,e,0),o=!P(t)||t!==this._$AH&&t!==Y,o&&(this._$AH=t);else{const r=t;let s,a;for(t=i[0],s=0;s{var r,i;const o=null!==(r=null==n?void 0:n.renderBefore)&&void 0!==r?r:e;let s=o._$litPart$;if(void 0===s){const t=null!==(i=null==n?void 0:n.renderBefore)&&void 0!==i?i:null;o._$litPart$=s=new nt(e.insertBefore(D(),t),t,void 0,null!=n?n:{})}return s._$AI(t),s};var dt,ht;class ft extends k{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var t,e;const n=super.createRenderRoot();return null!==(t=(e=this.renderOptions).renderBefore)&&void 0!==t||(e.renderBefore=n.firstChild),n}update(t){const e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=pt(e,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),null===(t=this._$Do)||void 0===t||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),null===(t=this._$Do)||void 0===t||t.setConnected(!1)}render(){return Y}}ft.finalized=!0,ft._$litElement$=!0,null===(dt=globalThis.litElementHydrateSupport)||void 0===dt||dt.call(globalThis,{LitElement:ft});const mt=globalThis.litElementPolyfillSupport;null==mt||mt({LitElement:ft});(null!==(ht=globalThis.litElementVersions)&&void 0!==ht?ht:globalThis.litElementVersions=[]).push("3.3.3");const gt=1,vt=2,bt=t=>(...e)=>({_$litDirective$:t,values:e});class yt{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,n){this._$Ct=t,this._$AM=e,this._$Ci=n}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}}const _t=bt(class extends yt{constructor(t){var e;if(super(t),t.type!==gt||"class"!==t.name||(null===(e=t.strings)||void 0===e?void 0:e.length)>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(t){return" "+Object.keys(t).filter((e=>t[e])).join(" ")+" "}update(t,[e]){var n,r;if(void 0===this.it){this.it=new Set,void 0!==t.strings&&(this.nt=new Set(t.strings.join(" ").split(/\s/).filter((t=>""!==t))));for(const t in e)e[t]&&!(null===(n=this.nt)||void 0===n?void 0:n.has(t))&&this.it.add(t);return this.render(e)}const i=t.element.classList;this.it.forEach((t=>{t in e||(i.remove(t),this.it.delete(t))}));for(const t in e){const n=!!e[t];n===this.it.has(t)||(null===(r=this.nt)||void 0===r?void 0:r.has(t))||(n?(i.add(t),this.it.add(t)):(i.remove(t),this.it.delete(t)))}return Y}}),wt=t=>null!=t?t:q,kt="BUTTON",xt="CLOSE_BUTTON",St="CONTAINER",Et="EMAIL_INPUT",Tt="HEADING",Ct="IMAGE",Ot="OTP_INPUT",It="PHONE_INPUT",At="ROOT",Rt="ROOT_TEMP",Dt="SPIN_TO_WIN",Pt="TEASER",$t="TEASER_ROOT",Lt="TEXT",Nt="mobile",jt="desktop",Bt=[Nt,jt],Mt={BUTTON:"button"},Ut={HEADING:"heading"},zt={LABEL:"label"},Ft={PARAGRAPH:"paragraph"},Gt=Object.assign(Object.assign(Object.assign(Object.assign({},Mt),Ut),zt),Ft),Ht={BLOCK:"block"},Vt={MAIN_POPUP_CONTAINER:"mainPopupContainer"},Wt={BUTTON:"button"},Yt={HEADING:"heading"},qt={IMAGE:"image"},Zt={INPUT:"input"},Xt={LABEL:"label"},Kt={LINK:"link"},Jt={PATH:"path"},Qt={ROOT_BACKGROUND_IMAGE_DIV:"rootBackgroundImageDiv"},te={SMALL:"small"},ee={SPIN_TO_WIN_CENTER:"spinToWinCenter"},ne={SPIN_TO_WIN_MAIN_WHEEL:"spinToWinMainWheel"},re={SPIN_TO_WIN_SECTION_BORDER:"spinToWinSectionBorder"},ie={SVG:"svg"},oe={TEXT:"text"},se=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},Ht),Wt),Yt),qt),Zt),Xt),Kt),Vt),Jt),Qt),te),ee),ne),re),ie),oe),ae="alignItems",ce="alignSelf",le="backgroundColor",ue="backgroundImage",pe="backgroundPosition",de="backgroundRepeat",he="backgroundSize",fe="blockSize",me="borderColor",ge="borderRadius",ve="borderStyle",be="borderWidth",ye="borderTopColor",_e="borderTopStyle",we="borderTopWidth",ke="color",xe="display",Se="fill",Ee="flex",Te="flexGrow",Ce="fontFamily",Oe="fontSize",Ie="fontStyle",Ae="fontWeight",Re="gridArea",De="gridColumn",Pe="gridTemplateColumns",$e="height",Le="inset",Ne="justify-content",je="layoutDirection",Be="layoutSpacing",Me="letterSpacing",Ue="lineHeight",ze="margin",Fe="maxHeight",Ge="maxWidth",He="minHeight",Ve="minWidth",We="objectFit",Ye="overflow",qe="opacity",Ze="padding",Xe="position",Ke="rootLayout",Je="spinToWinDuration",Qe="stroke",tn="strokeWidth",en="teaserIframeInset",nn="textAlign",rn="textDecoration",on="textTransform",sn="textWrap",an="transform",cn="transformOrigin",ln="width",un="zIndex",pn="auto auto 16px 16px",dn={BORDER:"#000000",INPUT_BG:"#ECECEC",SPIN_TO_WIN_CENTER_BG:"#000000",POPUP_BG:"#FFFFFF",PRIMARY_BUTTON_BG:"#656565",PRIMARY_BUTTON_TEXT:"#FFFFFF",SECONDARY_BUTTON_BG:"transparent",SECONDARY_BUTTON_TEXT:"#656565",STOPPER:"#8D69F8",TEASER_CLOSE_BUTTON_BG:"rgba(255,255,255, 0.8)",TEXT:"#000000"},hn={ARIAL:"'Arial', sans-serif",CENTURY_GOTHIC:"'Century Gothic', sans-serif",COURIER:"'Courier', monospace",GEORGIA:"'Georgia', serif",HELVETICA:"'Helvetica', sans-serif",VERDANA:"'Verdana', sans-serif"},fn={[ae]:"align-items",[ce]:"align-self",[le]:"background-color",[pe]:"background-position",[de]:"background-repeat",[he]:"background-size",[fe]:"block-size",[me]:"border-color",[ge]:"border-radius",[ve]:"border-style",[be]:"border-width",[ye]:"border-top-color",[_e]:"border-top-style",[we]:"border-top-width",[ke]:"color",[xe]:"display",[Se]:"fill",[Ee]:"flex",[Te]:"flex-grow",[Ce]:"font-family",[Oe]:"font-size",[Ie]:"font-style",[Ae]:"font-weight",[Re]:"grid-area",[De]:"grid-column",[Pe]:"grid-template-columns",[$e]:"height",[Le]:"inset",[Ne]:"justify-content",[Me]:"letter-spacing",[Ue]:"line-height",[ze]:"margin",[Fe]:"max-height",[Ge]:"max-width",[He]:"min-height",[Ve]:"min-width",[We]:"object-fit",[qe]:"opacity",[Ye]:"overflow",[Ze]:"padding",[Xe]:"position",[Qe]:"stroke",[tn]:"stroke-width",[nn]:"text-align",[rn]:"text-decoration",[on]:"text-transform",[sn]:"text-wrap",[an]:"transform",[cn]:"transform-origin",[ln]:"width",[un]:"z-index"},mn="email",gn="phone",vn="otp",bn="HARD_CLOSE",yn="changeLocation",_n="close",wn="routeToStep",kn="submitAndRouteToStep",xn="next",Sn="previous",En="INCLUDED",Tn="{terms_of_service}",Cn="{privacy_policy}",On="DECORATIVE",In="MAIN_POPUP_CONTAINER",An="BOTTOM_DECORATIVE",Rn="LEFT_DECORATIVE",Dn="NONE",Pn="RIGHT_DECORATIVE",$n="TOP_DECORATIVE",Ln=50,Nn=2*Math.PI*25,jn="12.5%",Bn={BOTTOM:"BOTTOM",LEFT:"LEFT",RIGHT:"RIGHT",TOP:"TOP"},Mn="--spin-to-win-duration",Un="--spin-to-win-rotation";var zn=(t,e,n)=>{const{duplicateBlock:r,deleteBlock:i}=n;return e.isDevelopment?V`
${r||i?V`
${r?(s=r,V`
`):q} ${i?(o=i,V`
`):q}
`:q}
`:q;var o,s};const Fn=Object.assign({},Mt),Gn=Object.assign(Object.assign({},Wt),Ht);const Hn={addBlockActions:({block:t,blockActions:e,popupActions:n})=>{e.onClick=()=>{var e,r,i;(null===(e=t.config)||void 0===e?void 0:e.dataName)&&(null===(r=t.config)||void 0===r?void 0:r.dataValue)&&n.updateStepData(t.id,null===(i=t.config)||void 0===i?void 0:i.dataValue),n.handleButtonClick(t)}},defaultStyles:{[Gn.BLOCK]:{mobile:{[ce]:"center",[ze]:"0px 0px 0px 0px",[qe]:"1",[ln]:"100%",[Xe]:"relative"}},[Gn.BUTTON]:{mobile:{[le]:dn.PRIMARY_BUTTON_BG,[me]:dn.BORDER,[ge]:"0px 0px 0px 0px",[ve]:"none",[be]:"1px",[ke]:dn.PRIMARY_BUTTON_TEXT,[Ce]:hn.ARIAL,[Oe]:"16px",[Ie]:"normal",[Ae]:"bold",[Ze]:"8px 8px 8px 8px",[nn]:"center",[rn]:"none",[ln]:"100%"}}},render:function(t){var e,n,r;const{block:i,blockActions:{handleReorderDragEnd:o,handleReorderDragStart:s,handleReorderDrop:a,onClick:c,selectBlock:l},classes:{block:u,button:p,editorNode:d},content:h,environment:{isDevelopment:f}}=t,{action:m}=null!==(n=null===(e=i.config)||void 0===e?void 0:e.onClick)&&void 0!==n?n:{},g=null!==(r=h[Fn.BUTTON])&&void 0!==r?r:"Button",v=m===kn,b=m===_n,y=m===yn;return V`
${zn(d,t.environment,t.blockActions)}
`},styleElements:Gn,textElements:Fn};var Vn=Hn;const Wn=Object.assign(Object.assign(Object.assign({},Wt),Ht),ie);const Yn={addBlockActions:({block:t,blockActions:e,popupActions:n})=>{e.onClick=()=>n.handleButtonClick(t)},defaultStyles:{[Wn.BLOCK]:{mobile:{[qe]:"1",[Le]:"10px 10px auto auto",[Xe]:"absolute",[un]:"10"}},[Wn.BUTTON]:{mobile:{[le]:"transparent",[me]:dn.BORDER,[ge]:"0px 0px 0px 0px",[ve]:"none",[be]:"1px",[ke]:dn.TEXT,[Ze]:"3px 3px 3px 3px",[xe]:"flex",[Ne]:"center"}},[Wn.SVG]:{mobile:{[ke]:"currentColor",[$e]:"18px",[ln]:"18px"}}},render:function(t){const{block:{type:e},blockActions:n,classes:r,environment:i}=t,{block:o,button:s,editorNode:a,svg:c}=r;return V`
${zn(a,i,n)}
`},styleElements:Wn};var qn=Yn;const Zn=Object.assign({},Ht);var Xn={defaultStyles:{[Zn.BLOCK]:{mobile:{[le]:"transparent",[ge]:"0px 0px 0px 0px",[je]:"column",[Be]:"flex-start",[ze]:"0px 0px 0px 0px",[Ge]:"100%",[Ze]:"12px 12px 12px 12px",[xe]:"flex",[Ee]:"1",[Xe]:"relative"}}},isEmpty:function({children:t=[]}){return 0===t.length},render:function(t){const{children:e,blockActions:n,classes:r,environment:i}=t,{block:o,editorNode:s}=r;return V`
${zn(s,i,n)} ${e}
`},styleElements:Zn};const Kn=(t,e)=>{const{error:n}=null!=t?t:{};return n?V``:q},Jn=Object.assign({},zt),Qn=Object.assign(Object.assign(Object.assign({},Xt),Zt),Ht);const tr={addBlockActions:({block:t,blockActions:e,popupActions:n,stepBlocks:r})=>{e.updateStepData=e=>{const{value:r}=e.target;n.updateStepData(t.id,r)},e.deleteBlock&&(e.deleteBlock=()=>{var i,o;1===(null!=r?r:[]).filter((t=>t.type===Et)).length&&(null===(i=e.setEmailIntegration)||void 0===i||i.call(e,Object.assign({},{enabled:!1,integrationId:0,integrationType:"",lists:[]}))),null===(o=n.deleteBlock)||void 0===o||o.call(n,t.id)})},defaultStyles:{[Qn.BLOCK]:{mobile:{[le]:"transparent",[ge]:"0px 0px 0px 0px",[ze]:"0px 0px 0px 0px",[qe]:"1",[Ze]:"0px 0px 0px 0px",[xe]:"flex",[$e]:"fit-content",[je]:"column",[Be]:"flex-start",[Xe]:"relative"}},[Qn.INPUT]:{mobile:{[le]:dn.INPUT_BG,[me]:dn.BORDER,[ge]:"0px 0px 0px 0px",[ve]:"none",[be]:"1px",[ke]:dn.TEXT,[Ce]:hn.ARIAL,[Oe]:"16px",[Ie]:"normal",[Ae]:"normal",[ze]:"0px 0px 0px 0px",[Ze]:"8px 8px 8px 8px",[nn]:"left",[rn]:"none"}},[Qn.LABEL]:{mobile:{[ke]:dn.TEXT,[Ce]:hn.ARIAL,[Oe]:"14px",[Ie]:"normal",[Ae]:"normal",[ze]:"0px 0px 4px 0px",[nn]:"left",[rn]:"none",[Ue]:"1.2"}}},render:function(t){var e,n;const{blockActions:r,block:i,classes:o,content:s,environment:a,state:c}=t,{block:l,editorNode:u,input:p,label:d}=o,h=null!==(e=s[Jn.LABEL])&&void 0!==e?e:"Email",f=`input-${i.id}`;return V`
${zn(u,a,r)} ${Kn(c,f)}
`},styleElements:Qn,textElements:Jn,validateBlockData:(t,e="")=>{var n;return e||(null===(n=t.config)||void 0===n?void 0:n.required)?((t,e="Enter a valid email address")=>/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+$/.test(t)?null:e)(e):null}};var er=tr;const nr=Object.assign({},Ut),rr=Object.assign(Object.assign({},Yt),Ht);var ir={defaultStyles:{[rr.BLOCK]:{mobile:{[le]:"transparent",[ge]:"0px 0px 0px 0px",[ze]:"0px 0px 0px 0px",[qe]:"1",[Ze]:"0px 0px 0px 0px",[Xe]:"relative"}},[rr.HEADING]:{mobile:{[ke]:dn.TEXT,[Ce]:hn.ARIAL,[Oe]:"30px",[Ie]:"normal",[Ae]:"bold",[nn]:"center",[rn]:"none",[Ue]:"1.1",[ze]:"0px 0px 0px 0px"}}},render:function(t){var e;const{blockActions:n,classes:r,content:i,environment:o}=t,{block:s,editorNode:a,heading:c}=r,l=null!==(e=i[nr.HEADING])&&void 0!==e?e:"";return V`
${zn(a,o,n)}

${l}

`},styleElements:rr,textElements:nr};const or="–".repeat(4),sr=Object.assign(Object.assign({},Ft),Mt),ar=Object.assign(Object.assign(Object.assign(Object.assign({},Ht),Wt),Zt),oe);const cr={addBlockActions:({block:t,blockActions:e,popupActions:n})=>{e.updateStepData=e=>{n.updateStepData(t.id,e)},e.getNode=n.getNode,e.resendOtp=()=>{var e;return null===(e=n.resendOtp)||void 0===e?void 0:e.call(n,t)}},defaultStyles:{[ar.BLOCK]:{mobile:{[le]:"transparent",[ge]:"0px 0px 0px 0px",[ze]:"0px 0px 8px 0px",[qe]:"1",[Ze]:"0px 0px 0px 0px",[Xe]:"relative"}},[ar.BUTTON]:{mobile:{[le]:"transparent",[me]:dn.BORDER,[ge]:"0px 0px 0px 0px",[ve]:"none",[be]:"1px",[ke]:dn.TEXT,[Ce]:hn.ARIAL,[Oe]:"16px",[Ie]:"normal",[Ae]:"normal",[ze]:"8px 0px 8px 0px",[Ze]:"8px 8px 8px 8px",[rn]:"underline",[Ue]:"1.2",[nn]:"center"}},[ar.INPUT]:{mobile:{[le]:dn.INPUT_BG,[me]:dn.BORDER,[ge]:"0px 0px 0px 0px",[ve]:"none",[be]:"1px",[ke]:dn.TEXT,[Ce]:hn.ARIAL,[Oe]:"16px",[Ie]:"normal",[Ae]:"normal",[ze]:"0px 0px 0px 0px",[Ze]:"0px 0px 0px 0px",[nn]:"center",[rn]:"none",[Me]:"0.45em",[ln]:"100%"}},[ar.TEXT]:{mobile:{[ke]:dn.TEXT,[Ce]:hn.ARIAL,[Oe]:"16px",[Ie]:"normal",[Ae]:"normal",[nn]:"center",[rn]:"none",[Ue]:"1.2",[ze]:"0px 0px 0px 0px"}}},render:function(t){var e,n,r;const{block:i,blockActions:o,classes:s,content:a,environment:c,state:l}=t,u=`input-${i.id}`,{block:p,button:d,editorNode:h,input:f,text:m}=s,g=null!==(e=a[sr.PARAGRAPH])&&void 0!==e?e:"",v=null!==(n=a[sr.BUTTON])&&void 0!==n?n:"";return V`
${zn(h,c,o)}

${g} ${((t,e)=>{const{isResendOtpSuccessVisible:n}=null!=t?t:{};return n?V`Code sent!`:q})(l,u)}

{var e,n;if(t.preventDefault(),!t.target)return;const r=t.target,i=r.value.replace(/\D/g,"").slice(0,4),s=4===i.length;o.updateStepData(i),r.value=i,s&&(null===(n=null===(e=r.closest("form"))||void 0===e?void 0:e.querySelector('[type="submit"]'))||void 0===n||n.click())}} required=${wt(!!(null===(r=i.config)||void 0===r?void 0:r.required)||void 0)} /> ${Kn(l,u)}
`},styleElements:ar,textElements:sr,validateBlockData:(t,e="")=>{const n=((t,e,n=`This field must be ${e} characters long`)=>t.length===e?null:n)((t=>t.replace(/\D/g,""))(e),4,"Please enter the complete code");return null!=n?n:null}};var lr=cr,ur=n(679),pr=n.n(ur);class dr extends ft{constructor(){super(...arguments),this.phoneInputBindingTimeout=null,this.setPhoneInputInstance=()=>{var t;this.phoneInputBindingTimeout&&(this.input&&this.input.offsetWidth>0?(this.phoneInputInstance=pr()(this.input,{autoPlaceholder:"off",countrySearch:!1,dropdownContainer:document.body,fixDropdownWidth:!1,formatAsYouType:!1,initialCountry:null!==(t=this.countryCode)&&void 0!==t?t:"US",preferredCountries:["us","ca"],showSelectedDialCode:!0,useFullscreenPopup:this.viewport===Nt,utilsScript:"https://cdnjs.cloudflare.com/ajax/libs/intl-tel-input/21.2.8/js/utils.js"}),this.phoneInputBindingTimeout=null):requestAnimationFrame(this.setPhoneInputInstance))}}static get properties(){return{inputId:{type:String},countryCode:{type:String},phoneInputInstance:{type:Object,state:!0},finalInputStyleRules:{type:Object},viewport:{type:String}}}createRenderRoot(){return this}getFormattedInputValue(){var t;return null===(t=this.phoneInputInstance)||void 0===t?void 0:t.getNumber()}startPhoneInputBindingTimeout(){this.phoneInputBindingTimeout=window.setTimeout((()=>{this.phoneInputBindingTimeout=null}),5e3)}updatePhoneInput(){requestAnimationFrame(this.setPhoneInputInstance)}getValidationError(){var t,e,n,r,i,o;if(null===(t=this.phoneInputInstance)||void 0===t?void 0:t.isValidNumber())return null;switch(null===(e=this.phoneInputInstance)||void 0===e?void 0:e.getValidationError()){case null===(r=null===(n=window.intlTelInputUtils)||void 0===n?void 0:n.validationError)||void 0===r?void 0:r.TOO_SHORT:return"Phone number is too short";case null===(o=null===(i=window.intlTelInputUtils)||void 0===i?void 0:i.validationError)||void 0===o?void 0:o.TOO_LONG:return"Phone number is too long";default:return"Invalid phone number"}}firstUpdated(t){super.firstUpdated(t),this.updatePhoneInput()}static closeDropdownOnScroll(){window.dispatchEvent(new Event("scroll",{cancelable:!0,bubbles:!0}))}copyInputBlockFinalStyleRules(){const t=this.renderRoot,{margin:e}=this.finalInputStyleRules;t.style.margin=e}copyInputComputedStyle(){if(!this.input)return null;this.renderRoot.style.margin=getComputedStyle(this.input).margin}updated(t){super.updated(t),this.copyInputBlockFinalStyleRules()}connectedCallback(){var t;super.connectedCallback(),this.startPhoneInputBindingTimeout(),this.input=this.renderRoot.querySelector(`.${this.inputId}`),this.copyInputComputedStyle(),null===(t=document.querySelector("form"))||void 0===t||t.addEventListener("scroll",dr.closeDropdownOnScroll)}disconnectedCallback(){var t,e;super.disconnectedCallback(),null===(t=this.phoneInputInstance)||void 0===t||t.destroy(),null===(e=document.querySelector("form"))||void 0===e||e.removeEventListener("scroll",dr.closeDropdownOnScroll),this.phoneInputBindingTimeout&&clearTimeout(this.phoneInputBindingTimeout)}}customElements.get("ps-phone-input-block-iti-wrapper")||customElements.define("ps-phone-input-block-iti-wrapper",dr);const hr=Object.assign({},zt),fr=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},Ht),Zt),Xt),Kt),te),mr={[fr.BLOCK]:{mobile:{[le]:"transparent",[ge]:"0px 0px 0px 0px",[ze]:"0px 0px 8px 0px",[qe]:"1",[Ze]:"0px 0px 0px 0px",[Xe]:"relative"}},[fr.LABEL]:{mobile:{[ke]:dn.TEXT,[Ce]:hn.ARIAL,[Oe]:"14px",[Ie]:"normal",[Ae]:"normal",[ze]:"0px 0px 4px 0px",[nn]:"left",[rn]:"none",[xe]:"block",[Ue]:"1.2"}},[fr.INPUT]:{mobile:{[le]:dn.INPUT_BG,[me]:dn.BORDER,[ge]:"0px 0px 0px 0px",[ve]:"none",[be]:"1px",[ke]:dn.TEXT,[Ce]:hn.ARIAL,[Oe]:"16px",[Ie]:"normal",[Ae]:"normal",[ze]:"0px 0px 0px 0px",[Ze]:"0px 0px 0px 0px",[nn]:"left",[rn]:"none",[ln]:"100%"}},[fr.SMALL]:{mobile:{[le]:"transparent",[ke]:dn.TEXT,[Ce]:hn.ARIAL,[Oe]:"10px",[Ie]:"normal",[Ae]:"normal",[ze]:"8px 0px 0px 0px",[Ze]:"0px 0px 0px 0px",[nn]:"center",[xe]:"block",[Ue]:"1.2"}},[fr.LINK]:{mobile:{[ke]:dn.TEXT,[rn]:"underline",[on]:"uppercase"}}},gr={color:"",fontFamily:"",fontSize:"",margin:""};const vr={addBlockActions:({block:t,blockActions:e,popupActions:n})=>{e.updateStepData=e=>{var r,i;const{value:o}=e.target,s=null===(i=null===(r=e.target)||void 0===r?void 0:r.closest("ps-phone-input-block-iti-wrapper"))||void 0===i?void 0:i.getFormattedInputValue();n.updateStepData(t.id,null!=s?s:o)}},defaultStyles:mr,render:function(t){var e,n,r;const{block:i,blockActions:o,classes:s,content:a,disclaimer:c,environment:l,finalStyleRules:u,state:p}=t,{block:d,editorNode:h,input:f,label:m,link:g,small:v}=s,b=null!==(e=a[hr.LABEL])&&void 0!==e?e:"Phone",{disclaimerText:y,disclaimerUrls:_}=(t=>{const{privacy_policy:e,terms_of_service:n,text:r}=t;return{disclaimerText:{preTerms:r.split(Tn)[0],terms:n.text,betweenTermsAndPrivacy:r.split(Tn)[1].split(Cn)[0],privacy:e.text,postPrivacy:r.split(Cn)[1]},disclaimerUrls:{terms:n.url,privacy:e.url}}})(c),w=null!==(n=u[fr.INPUT])&&void 0!==n?n:gr,k=`input-${i.id}`;return V`
${zn(h,l,o)} ${Kn(p,k)} ${y.preTerms} ${y.terms} ${y.betweenTermsAndPrivacy} ${y.privacy}${y.postPrivacy}
`},styleElements:fr,textElements:hr,validateBlockData:(t,e)=>{var n;const r=((t,e,n="This field is required")=>{var r;return(null===(r=t.config)||void 0===r?void 0:r.required)&&!e?n:null})(t,e,"Please enter a valid phone number"),i=null===(n=document.querySelector("ps-phone-input-block-iti-wrapper"))||void 0===n?void 0:n.getValidationError();return null!=r?r:i}};var br=vr;const yr=Object.assign({},Ht);var _r={defaultStyles:{[yr.BLOCK]:{mobile:{[le]:dn.POPUP_BG,[ge]:"0px 0px 0px 0px",[je]:"column",[Be]:"center",[ze]:"0px 0px 0px 0px",[Ge]:"340px",[He]:"240px",[qe]:"1",[Ze]:"30px 30px 30px 30px",[xe]:"flex",[Xe]:"relative",[ln]:"100%"},desktop:{[Ge]:"450px"}}},isEmpty:function({children:t=[]}){return 0===t.length},render:function(t){const{blockActions:e,classes:n,environment:r}=t,{block:i,editorNode:o}=n;return V`
t.preventDefault()} > ${zn(o,r,e)} ${t.children}
`},styleElements:yr};const wr=Object.assign(Object.assign(Object.assign({},Qt),Ht),Vt);const kr={defaultStyles:{[wr.BLOCK]:{mobile:{[ge]:"0px 0px 0px 0px",[le]:dn.POPUP_BG,[xe]:"grid",[Pe]:"repeat(12, 1fr)",[Ye]:"hidden",[Xe]:"relative",[Ke]:Dn,[Ge]:"100%",[He]:"100%",[ln]:"100%"}},[wr.MAIN_POPUP_CONTAINER]:{mobile:{[je]:"column",[Be]:"center",[qe]:"1",[Ze]:"30px 30px 30px 30px",[xe]:"flex",[Re]:In,[ln]:"100%"}},[wr.ROOT_BACKGROUND_IMAGE_DIV]:{mobile:{[$e]:"200px",[pe]:"50% 50%",[he]:"cover",[xe]:"block",[Re]:On,[ln]:"100%"}}},isEmpty:function({children:t=[]}){return 0===t.length},render:function(t){var e;const{blockActions:n,classes:r,environment:i,finalStyleRules:o}=t,s=null===(e=o[se.BLOCK])||void 0===e?void 0:e[Ke],{block:a,rootBackgroundImageDiv:c,editorNode:l,mainPopupContainer:u}=r;return V`
${s!==Dn?V`
`:q}
t.preventDefault()} > ${zn(l,i,n)} ${t.children}
`},styleElements:wr};var xr=kr;const Sr=t=>t.replace(/\n\s+/g,""),Er=(t,e={})=>{var n;let r={};for(let i=0;i360/t.length,Cr=t=>Tr(t)/2,Or=(t,e)=>Tr(e)*t,Ir={[se.SPIN_TO_WIN_SECTION_BORDER]:{mobile:{[ye]:dn.BORDER,[_e]:"solid",[we]:"2px",[Le]:"50% auto auto 50%",[Xe]:"absolute",[cn]:"0 0",[ln]:"50%"}}};var Ar=(t,e)=>V` ${e.map(((n,r)=>V`
`))} `;var Rr=(t,e)=>{const n=`${Nn/t.length} ${Nn}`;return W` ${t.map((({styles:r},i)=>{var o;const{sectionColor:s="#FFFFFF"}=null!==(o=Er(e,r))&&void 0!==o?o:{};return W` `}))} `};const Dr={TEAR:"M35.5 0L54.9478 41.4677C61.6153 55.6846 51.2231 72 35.5 72C19.7769 72 9.38466 55.6846 16.0522 41.4678L35.5 0Z",TEAR_ROUNDED:"M30.674 3.602c1.867-4.803 8.785-4.803 10.652 0l15.206 39.102C62.03 56.839 51.404 72 36 72S9.97 56.839 15.468 42.704L30.674 3.602Z",TRIANGLE:"M35.5 0 64 72H7L35.5 0Z",TRIANGLE_ROUNDED:"M31.35 2.697c1.461-3.705 6.815-3.549 8.169.197 8.864 24.522 15.116 33.443 23.982 57.98C65.47 66.321 61.367 72 55.568 72H16.526C10.519 72 6.4 65.959 8.6 60.378l22.75-57.68Z"},Pr={[se.PATH]:{mobile:{[Se]:dn.STOPPER,[Qe]:dn.BORDER,[tn]:"2px"}},[se.SVG]:{mobile:{[xe]:"block",[Xe]:"absolute",[an]:"translate(-50%, 0) rotate(180deg)"}}};var $r=({finalStyleRules:t,position:e,psCssClasses:n,stopperRotationOffset:r,type:i})=>{var o,s;const a=`calc(${null!==(s=null===(o=t[se.PATH])||void 0===o?void 0:o.strokeWidth)&&void 0!==s?s:"0"} * 2)`,c=(t=>t===Bn.LEFT||t===Bn.RIGHT?(parseFloat(jn)/100+1)*parseFloat(jn)+"%":jn)(e),l=`calc(${c} / -2) auto auto 50%`;return V`
${W` `}
`};const Lr={[se.TEXT]:{mobile:{[Ce]:hn.ARIAL,[Ie]:"normal",[Ae]:"normal",[rn]:"none",[Le]:"50% auto auto 50%",[ze]:"unset",[Xe]:"absolute",[nn]:"center",[cn]:"left center",[ln]:"50%"}}};var Nr=({finalStyleRules:t,psCssClasses:e,sections:n,viewport:r})=>{var i,o,s,a,c;const l=`calc(${null===(i=t[se.SPIN_TO_WIN_CENTER])||void 0===i?void 0:i.width} / 2)`,u="none"!==(null!==(s=null===(o=t[se.SPIN_TO_WIN_MAIN_WHEEL])||void 0===o?void 0:o.borderStyle)&&void 0!==s?s:"none")&&null!==(c=null===(a=t[se.SPIN_TO_WIN_MAIN_WHEEL])||void 0===a?void 0:a.borderWidth)&&void 0!==c?c:"0px";return V` ${n.map((({styles:t,text:i},o)=>{var s;const{color:a=dn.TEXT,fontSize:c="16px"}=null!==(s=Er(r,t))&&void 0!==s?s:{};return V`

Tr(e)*t+Cr(e))(o,n)}deg);\n `)} > ${i}

`}))} `};const jr={[Bn.TOP]:0,[Bn.RIGHT]:90,[Bn.BOTTOM]:180,[Bn.LEFT]:270},Br=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},Ht),Jt),ee),ne),re),ie),oe);const Mr={defaultStyles:Object.assign(Object.assign(Object.assign({[Br.BLOCK]:{mobile:{[ce]:"center",[ze]:"0px 0px 0px 0px",[Je]:"8000ms",[ln]:"100%",[Xe]:"relative"}},[Br.SPIN_TO_WIN_CENTER]:{mobile:{[le]:dn.SPIN_TO_WIN_CENTER_BG,[me]:dn.BORDER,[ve]:"none",[be]:"1px",[$e]:"20px",[ln]:"20px",[ge]:"50%",[Le]:"50% auto auto 50%",[Xe]:"absolute",[an]:"translate(-50%, -50%)"}},[Br.SPIN_TO_WIN_MAIN_WHEEL]:{mobile:{[me]:dn.BORDER,[ve]:"solid",[be]:"2px",[ge]:"50%",[Le]:"0px 0px 0px 0px",[Xe]:"absolute"}}},Ir),Pr),Lr),render:function({block:t,blockActions:e,classes:n,environment:r,finalStyleRules:i,state:o}){var s,a,c,l;if(!(null===(s=t.config)||void 0===s?void 0:s.spinToWin))return q;const{isDevelopment:u,viewport:p}=r,{handleReorderDragEnd:d,handleReorderDragStart:h,handleReorderDrop:f,selectBlock:m}=e,{animation:g,sections:v,stopper:b,startingSection:y}=t.config.spinToWin,{isSpinning:_=!1}=null!=o?o:{},{block:w,editorNode:k,path:x,spinToWinSectionBorder:S,spinToWinCenter:E,spinToWinMainWheel:T,svg:C,text:O}=n,I=null!==(a=[...v].sort(((t,e)=>t.order-e.order)))&&void 0!==a?a:v,A=[...I.slice(y),...I.slice(0,y)],{stopperPosition:R=Bn.BOTTOM}=null!==(c=Er(p,b.position))&&void 0!==c?c:{},D=jr[R],P=D-Cr(A)-90-Cr(A)/3,$=(({rotations:t,sections:e,startingSection:n})=>360*t+(Tr(e)*n-Cr(e)/3))({rotations:null!==(l=null==g?void 0:g.rotations)&&void 0!==l?l:7,startingSection:y,sections:A});return V`
${zn(k,r,e)}
${Rr(A,p)} ${Ar(_t(S),A)}
${Nr({finalStyleRules:i,psCssClasses:O,sections:A,viewport:p})}
${$r({finalStyleRules:i,position:R,psCssClasses:{stopperPathClasses:x,stopperSvgClasses:C},stopperRotationOffset:D,type:b.type})}
`},styleElements:Br};var Ur=Mr;const zr=Object.assign({},Mt),Fr=Object.assign({},Wt);const Gr={addBlockActions:({block:t,blockActions:e,environment:n,popupActions:r})=>{e.onClick=()=>{var e;(null==n?void 0:n.isDevelopment)?null===(e=r.selectBlock)||void 0===e||e.call(r,t.id):r.handleTeaserClick()}},defaultStyles:{[Fr.BUTTON]:{mobile:{[le]:dn.PRIMARY_BUTTON_BG,[me]:dn.BORDER,[ge]:"0px 0px 0px 0px",[ve]:"none",[be]:"1px",[ke]:dn.PRIMARY_BUTTON_TEXT,[Ce]:hn.ARIAL,[Oe]:"16px",[Ie]:"normal",[Ae]:"400",[Ze]:"8px 8px 8px 8px",[rn]:"none",[ln]:"100%"}}},render:function(t){var e;const{block:{id:n,type:r},blockActions:i,classes:o,content:s,environment:a}=t,c=`teaser-${n}`,{button:l,editorNode:u}=o,p=null!==(e=s[zr.BUTTON])&&void 0!==e?e:"Button";return V`
${zn(u,a,i)}
`},styleElements:Fr,textElements:zr};var Hr=Gr;const Vr=Object.assign(Object.assign(Object.assign({},Ht),Wt),ie),Wr={[Vr.BLOCK]:{mobile:{[Xe]:"relative",[en]:pn}},[Vr.BUTTON]:{mobile:{[ae]:"center",[le]:dn.TEASER_CLOSE_BUTTON_BG,[me]:"unset",[ge]:"99em",[ve]:"unset",[be]:"unset",[ke]:dn.TEXT,[xe]:"flex",[$e]:"24px",[Le]:"-12px auto auto -12px",[Ne]:"center",[Be]:"center",[Ze]:"0px 0px 0px 0px",[Xe]:"absolute",[ln]:"24px"}},[Vr.SVG]:{mobile:{[$e]:"16px",[ln]:"16px"}}};const Yr={addBlockActions:({blockActions:t,popupActions:e})=>{t.onClick=()=>e.hardClose()},defaultStyles:Wr,render:function(t){const{blockActions:e,classes:n,block:r,environment:i,finalStyleRules:o}=t,{block:s,button:a}=n,c=`teaser-${r.id}`;return V`
${t.children}
`},styleElements:Vr};var qr=Yr;class Zr extends yt{constructor(t){if(super(t),this.et=q,t.type!==vt)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===q||null==t)return this.ft=void 0,this.et=t;if(t===Y)return t;if("string"!=typeof t)throw Error(this.constructor.directiveName+"() called with a non-string value");if(t===this.et)return this.ft;this.et=t;const e=[t];return e.raw=e,this.ft={_$litType$:this.constructor.resultType,strings:e,values:[]}}}Zr.directiveName="unsafeHTML",Zr.resultType=1;const Xr=bt(Zr);function Kr(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}let Jr={async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null};function Qr(t){Jr=t}const ti={exec:()=>null};function ei(t,e=""){let n="string"==typeof t?t:t.source;const r={replace:(t,e)=>{let i="string"==typeof e?e:e.source;return i=i.replace(ni.caret,"$1"),n=n.replace(t,i),r},getRegex:()=>new RegExp(n,e)};return r}const ni={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:t=>new RegExp(`^( {0,3}${t})((?:[\t ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ \t][^\\n]*)?(?:\\n|$))`),hrRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}#`),htmlBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}<(?:[a-z].*>|!--)`,"i")},ri=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,ii=/(?:[*+-]|\d{1,9}[.)])/,oi=ei(/^(?!bull |blockCode|fences|blockquote|heading|html)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html))+?)\n {0,3}(=+|-+) *(?:\n+|$)/).replace(/bull/g,ii).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).getRegex(),si=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,ai=/(?!\s*\])(?:\\.|[^\[\]\\])+/,ci=ei(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",ai).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),li=ei(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,ii).getRegex(),ui="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",pi=/|$))/,di=ei("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|)[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$))","i").replace("comment",pi).replace("tag",ui).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),hi=ei(si).replace("hr",ri).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",ui).getRegex(),fi={blockquote:ei(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",hi).getRegex(),code:/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,def:ci,fences:/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,hr:ri,html:di,lheading:oi,list:li,newline:/^(?:[ \t]*(?:\n|$))+/,paragraph:hi,table:ti,text:/^[^\n]+/},mi=ei("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",ri).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3}\t)[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",ui).getRegex(),gi={...fi,table:mi,paragraph:ei(si).replace("hr",ri).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",mi).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",ui).getRegex()},vi={...fi,html:ei("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment",pi).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:ti,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:ei(si).replace("hr",ri).replace("heading"," *#{1,6} *[^\n]").replace("lheading",oi).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},bi=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,yi=/^( {2,}|\\)\n(?!\s*$)/,_i=/[\p{P}\p{S}]/u,wi=/[\s\p{P}\p{S}]/u,ki=/[^\s\p{P}\p{S}]/u,xi=ei(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,wi).getRegex(),Si=ei(/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,"u").replace(/punct/g,_i).getRegex(),Ei=ei("^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)","gu").replace(/notPunctSpace/g,ki).replace(/punctSpace/g,wi).replace(/punct/g,_i).getRegex(),Ti=ei("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,ki).replace(/punctSpace/g,wi).replace(/punct/g,_i).getRegex(),Ci=ei(/\\(punct)/,"gu").replace(/punct/g,_i).getRegex(),Oi=ei(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),Ii=ei(pi).replace("(?:--\x3e|$)","--\x3e").getRegex(),Ai=ei("^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^").replace("comment",Ii).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),Ri=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,Di=ei(/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/).replace("label",Ri).replace("href",/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),Pi=ei(/^!?\[(label)\]\[(ref)\]/).replace("label",Ri).replace("ref",ai).getRegex(),$i=ei(/^!?\[(ref)\](?:\[\])?/).replace("ref",ai).getRegex(),Li={_backpedal:ti,anyPunctuation:Ci,autolink:Oi,blockSkip:/\[[^[\]]*?\]\((?:\\.|[^\\\(\)]|\((?:\\.|[^\\\(\)])*\))*\)|`[^`]*?`|<[^<>]*?>/g,br:yi,code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,del:ti,emStrongLDelim:Si,emStrongRDelimAst:Ei,emStrongRDelimUnd:Ti,escape:bi,link:Di,nolink:$i,punctuation:xi,reflink:Pi,reflinkSearch:ei("reflink|nolink(?!\\()","g").replace("reflink",Pi).replace("nolink",$i).getRegex(),tag:Ai,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\":">",'"':""","'":"'"},Fi=t=>zi[t];function Gi(t,e){if(e){if(ni.escapeTest.test(t))return t.replace(ni.escapeReplace,Fi)}else if(ni.escapeTestNoEncode.test(t))return t.replace(ni.escapeReplaceNoEncode,Fi);return t}function Hi(t){try{t=encodeURI(t).replace(ni.percentDecode,"%")}catch{return null}return t}function Vi(t,e){const n=t.replace(ni.findPipe,((t,e,n)=>{let r=!1,i=e;for(;--i>=0&&"\\"===n[i];)r=!r;return r?"|":" |"})).split(ni.splitPipe);let r=0;if(n[0].trim()||n.shift(),n.length>0&&!n.at(-1)?.trim()&&n.pop(),e)if(n.length>e)n.splice(e);else for(;n.length0)return{type:"space",raw:e[0]}}code(t){const e=this.rules.block.code.exec(t);if(e){const t=e[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:e[0],codeBlockStyle:"indented",text:this.options.pedantic?t:Wi(t,"\n")}}}fences(t){const e=this.rules.block.fences.exec(t);if(e){const t=e[0],n=function(t,e,n){const r=t.match(n.other.indentCodeCompensation);if(null===r)return e;const i=r[1];return e.split("\n").map((t=>{const e=t.match(n.other.beginningSpace);if(null===e)return t;const[r]=e;return r.length>=i.length?t.slice(i.length):t})).join("\n")}(t,e[3]||"",this.rules);return{type:"code",raw:t,lang:e[2]?e[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):e[2],text:n}}}heading(t){const e=this.rules.block.heading.exec(t);if(e){let t=e[2].trim();if(this.rules.other.endingHash.test(t)){const e=Wi(t,"#");this.options.pedantic?t=e.trim():e&&!this.rules.other.endingSpaceChar.test(e)||(t=e.trim())}return{type:"heading",raw:e[0],depth:e[1].length,text:t,tokens:this.lexer.inline(t)}}}hr(t){const e=this.rules.block.hr.exec(t);if(e)return{type:"hr",raw:Wi(e[0],"\n")}}blockquote(t){const e=this.rules.block.blockquote.exec(t);if(e){let t=Wi(e[0],"\n").split("\n"),n="",r="";const i=[];for(;t.length>0;){let e=!1;const o=[];let s;for(s=0;s1,i={type:"list",raw:"",ordered:r,start:r?+n.slice(0,-1):"",loose:!1,items:[]};n=r?`\\d{1,9}\\${n.slice(-1)}`:`\\${n}`,this.options.pedantic&&(n=r?n:"[*+-]");const o=this.rules.other.listItemRegex(n);let s=!1;for(;t;){let n=!1,r="",a="";if(!(e=o.exec(t)))break;if(this.rules.block.hr.test(t))break;r=e[0],t=t.substring(r.length);let c=e[2].split("\n",1)[0].replace(this.rules.other.listReplaceTabs,(t=>" ".repeat(3*t.length))),l=t.split("\n",1)[0],u=!c.trim(),p=0;if(this.options.pedantic?(p=2,a=c.trimStart()):u?p=e[1].length+1:(p=e[2].search(this.rules.other.nonSpaceChar),p=p>4?1:p,a=c.slice(p),p+=e[1].length),u&&this.rules.other.blankLine.test(l)&&(r+=l+"\n",t=t.substring(l.length+1),n=!0),!n){const e=this.rules.other.nextBulletRegex(p),n=this.rules.other.hrRegex(p),i=this.rules.other.fencesBeginRegex(p),o=this.rules.other.headingBeginRegex(p),s=this.rules.other.htmlBeginRegex(p);for(;t;){const d=t.split("\n",1)[0];let h;if(l=d,this.options.pedantic?(l=l.replace(this.rules.other.listReplaceNesting," "),h=l):h=l.replace(this.rules.other.tabCharGlobal," "),i.test(l))break;if(o.test(l))break;if(s.test(l))break;if(e.test(l))break;if(n.test(l))break;if(h.search(this.rules.other.nonSpaceChar)>=p||!l.trim())a+="\n"+h.slice(p);else{if(u)break;if(c.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4)break;if(i.test(c))break;if(o.test(c))break;if(n.test(c))break;a+="\n"+l}u||l.trim()||(u=!0),r+=d+"\n",t=t.substring(d.length+1),c=h.slice(p)}}i.loose||(s?i.loose=!0:this.rules.other.doubleBlankLine.test(r)&&(s=!0));let d,h=null;this.options.gfm&&(h=this.rules.other.listIsTask.exec(a),h&&(d="[ ] "!==h[0],a=a.replace(this.rules.other.listReplaceTask,""))),i.items.push({type:"list_item",raw:r,task:!!h,checked:d,loose:!1,text:a,tokens:[]}),i.raw+=r}const a=i.items.at(-1);a&&(a.raw=a.raw.trimEnd(),a.text=a.text.trimEnd()),i.raw=i.raw.trimEnd();for(let t=0;t"space"===t.type)),n=e.length>0&&e.some((t=>this.rules.other.anyLine.test(t.raw)));i.loose=n}if(i.loose)for(let t=0;t({text:t,tokens:this.lexer.inline(t),header:!1,align:o.align[e]}))));return o}}lheading(t){const e=this.rules.block.lheading.exec(t);if(e)return{type:"heading",raw:e[0],depth:"="===e[2].charAt(0)?1:2,text:e[1],tokens:this.lexer.inline(e[1])}}paragraph(t){const e=this.rules.block.paragraph.exec(t);if(e){const t="\n"===e[1].charAt(e[1].length-1)?e[1].slice(0,-1):e[1];return{type:"paragraph",raw:e[0],text:t,tokens:this.lexer.inline(t)}}}text(t){const e=this.rules.block.text.exec(t);if(e)return{type:"text",raw:e[0],text:e[0],tokens:this.lexer.inline(e[0])}}escape(t){const e=this.rules.inline.escape.exec(t);if(e)return{type:"escape",raw:e[0],text:e[1]}}tag(t){const e=this.rules.inline.tag.exec(t);if(e)return!this.lexer.state.inLink&&this.rules.other.startATag.test(e[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(e[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(e[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(e[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:e[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:e[0]}}link(t){const e=this.rules.inline.link.exec(t);if(e){const t=e[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(t)){if(!this.rules.other.endAngleBracket.test(t))return;const e=Wi(t.slice(0,-1),"\\");if((t.length-e.length)%2==0)return}else{const t=function(t,e){if(-1===t.indexOf(e[1]))return-1;let n=0;for(let r=0;r-1){const n=(0===e[0].indexOf("!")?5:4)+e[1].length+t;e[2]=e[2].substring(0,t),e[0]=e[0].substring(0,n).trim(),e[3]=""}}let n=e[2],r="";if(this.options.pedantic){const t=this.rules.other.pedanticHrefTitle.exec(n);t&&(n=t[1],r=t[3])}else r=e[3]?e[3].slice(1,-1):"";return n=n.trim(),this.rules.other.startAngleBracket.test(n)&&(n=this.options.pedantic&&!this.rules.other.endAngleBracket.test(t)?n.slice(1):n.slice(1,-1)),Yi(e,{href:n?n.replace(this.rules.inline.anyPunctuation,"$1"):n,title:r?r.replace(this.rules.inline.anyPunctuation,"$1"):r},e[0],this.lexer,this.rules)}}reflink(t,e){let n;if((n=this.rules.inline.reflink.exec(t))||(n=this.rules.inline.nolink.exec(t))){const t=e[(n[2]||n[1]).replace(this.rules.other.multipleSpaceGlobal," ").toLowerCase()];if(!t){const t=n[0].charAt(0);return{type:"text",raw:t,text:t}}return Yi(n,t,n[0],this.lexer,this.rules)}}emStrong(t,e,n=""){let r=this.rules.inline.emStrongLDelim.exec(t);if(!r)return;if(r[3]&&n.match(this.rules.other.unicodeAlphaNumeric))return;if(!(r[1]||r[2]||"")||!n||this.rules.inline.punctuation.exec(n)){const n=[...r[0]].length-1;let i,o,s=n,a=0;const c="*"===r[0][0]?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(c.lastIndex=0,e=e.slice(-1*t.length+n);null!=(r=c.exec(e));){if(i=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!i)continue;if(o=[...i].length,r[3]||r[4]){s+=o;continue}if((r[5]||r[6])&&n%3&&!((n+o)%3)){a+=o;continue}if(s-=o,s>0)continue;o=Math.min(o,o+s+a);const e=[...r[0]][0].length,c=t.slice(0,n+r.index+e+o);if(Math.min(n,o)%2){const t=c.slice(1,-1);return{type:"em",raw:c,text:t,tokens:this.lexer.inlineTokens(t)}}const l=c.slice(2,-2);return{type:"strong",raw:c,text:l,tokens:this.lexer.inlineTokens(l)}}}}codespan(t){const e=this.rules.inline.code.exec(t);if(e){let t=e[2].replace(this.rules.other.newLineCharGlobal," ");const n=this.rules.other.nonSpaceChar.test(t),r=this.rules.other.startingSpaceChar.test(t)&&this.rules.other.endingSpaceChar.test(t);return n&&r&&(t=t.substring(1,t.length-1)),{type:"codespan",raw:e[0],text:t}}}br(t){const e=this.rules.inline.br.exec(t);if(e)return{type:"br",raw:e[0]}}del(t){const e=this.rules.inline.del.exec(t);if(e)return{type:"del",raw:e[0],text:e[2],tokens:this.lexer.inlineTokens(e[2])}}autolink(t){const e=this.rules.inline.autolink.exec(t);if(e){let t,n;return"@"===e[2]?(t=e[1],n="mailto:"+t):(t=e[1],n=t),{type:"link",raw:e[0],text:t,href:n,tokens:[{type:"text",raw:t,text:t}]}}}url(t){let e;if(e=this.rules.inline.url.exec(t)){let t,n;if("@"===e[2])t=e[0],n="mailto:"+t;else{let r;do{r=e[0],e[0]=this.rules.inline._backpedal.exec(e[0])?.[0]??""}while(r!==e[0]);t=e[0],n="www."===e[1]?"http://"+e[0]:e[0]}return{type:"link",raw:e[0],text:t,href:n,tokens:[{type:"text",raw:t,text:t}]}}}inlineText(t){const e=this.rules.inline.text.exec(t);if(e){const t=this.lexer.state.inRawBlock;return{type:"text",raw:e[0],text:e[0],escaped:t}}}}class Zi{tokens;options;state;tokenizer;inlineQueue;constructor(t){this.tokens=[],this.tokens.links=Object.create(null),this.options=t||Jr,this.options.tokenizer=this.options.tokenizer||new qi,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};const e={other:ni,block:Mi.normal,inline:Ui.normal};this.options.pedantic?(e.block=Mi.pedantic,e.inline=Ui.pedantic):this.options.gfm&&(e.block=Mi.gfm,this.options.breaks?e.inline=Ui.breaks:e.inline=Ui.gfm),this.tokenizer.rules=e}static get rules(){return{block:Mi,inline:Ui}}static lex(t,e){return new Zi(e).lex(t)}static lexInline(t,e){return new Zi(e).inlineTokens(t)}lex(t){t=t.replace(ni.carriageReturn,"\n"),this.blockTokens(t,this.tokens);for(let t=0;t!!(r=n.call({lexer:this},t,e))&&(t=t.substring(r.raw.length),e.push(r),!0))))continue;if(r=this.tokenizer.space(t)){t=t.substring(r.raw.length);const n=e.at(-1);1===r.raw.length&&void 0!==n?n.raw+="\n":e.push(r);continue}if(r=this.tokenizer.code(t)){t=t.substring(r.raw.length);const n=e.at(-1);"paragraph"===n?.type||"text"===n?.type?(n.raw+="\n"+r.raw,n.text+="\n"+r.text,this.inlineQueue.at(-1).src=n.text):e.push(r);continue}if(r=this.tokenizer.fences(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.heading(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.hr(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.blockquote(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.list(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.html(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.def(t)){t=t.substring(r.raw.length);const n=e.at(-1);"paragraph"===n?.type||"text"===n?.type?(n.raw+="\n"+r.raw,n.text+="\n"+r.raw,this.inlineQueue.at(-1).src=n.text):this.tokens.links[r.tag]||(this.tokens.links[r.tag]={href:r.href,title:r.title});continue}if(r=this.tokenizer.table(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.lheading(t)){t=t.substring(r.raw.length),e.push(r);continue}let i=t;if(this.options.extensions?.startBlock){let e=1/0;const n=t.slice(1);let r;this.options.extensions.startBlock.forEach((t=>{r=t.call({lexer:this},n),"number"==typeof r&&r>=0&&(e=Math.min(e,r))})),e<1/0&&e>=0&&(i=t.substring(0,e+1))}if(this.state.top&&(r=this.tokenizer.paragraph(i))){const o=e.at(-1);n&&"paragraph"===o?.type?(o.raw+="\n"+r.raw,o.text+="\n"+r.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=o.text):e.push(r),n=i.length!==t.length,t=t.substring(r.raw.length)}else if(r=this.tokenizer.text(t)){t=t.substring(r.raw.length);const n=e.at(-1);"text"===n?.type?(n.raw+="\n"+r.raw,n.text+="\n"+r.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=n.text):e.push(r)}else if(t){const e="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(e);break}throw new Error(e)}}return this.state.top=!0,e}inline(t,e=[]){return this.inlineQueue.push({src:t,tokens:e}),e}inlineTokens(t,e=[]){let n=t,r=null;if(this.tokens.links){const t=Object.keys(this.tokens.links);if(t.length>0)for(;null!=(r=this.tokenizer.rules.inline.reflinkSearch.exec(n));)t.includes(r[0].slice(r[0].lastIndexOf("[")+1,-1))&&(n=n.slice(0,r.index)+"["+"a".repeat(r[0].length-2)+"]"+n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;null!=(r=this.tokenizer.rules.inline.blockSkip.exec(n));)n=n.slice(0,r.index)+"["+"a".repeat(r[0].length-2)+"]"+n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;null!=(r=this.tokenizer.rules.inline.anyPunctuation.exec(n));)n=n.slice(0,r.index)+"++"+n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);let i=!1,o="";for(;t;){let r;if(i||(o=""),i=!1,this.options.extensions?.inline?.some((n=>!!(r=n.call({lexer:this},t,e))&&(t=t.substring(r.raw.length),e.push(r),!0))))continue;if(r=this.tokenizer.escape(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.tag(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.link(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.reflink(t,this.tokens.links)){t=t.substring(r.raw.length);const n=e.at(-1);"text"===r.type&&"text"===n?.type?(n.raw+=r.raw,n.text+=r.text):e.push(r);continue}if(r=this.tokenizer.emStrong(t,n,o)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.codespan(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.br(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.del(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.autolink(t)){t=t.substring(r.raw.length),e.push(r);continue}if(!this.state.inLink&&(r=this.tokenizer.url(t))){t=t.substring(r.raw.length),e.push(r);continue}let s=t;if(this.options.extensions?.startInline){let e=1/0;const n=t.slice(1);let r;this.options.extensions.startInline.forEach((t=>{r=t.call({lexer:this},n),"number"==typeof r&&r>=0&&(e=Math.min(e,r))})),e<1/0&&e>=0&&(s=t.substring(0,e+1))}if(r=this.tokenizer.inlineText(s)){t=t.substring(r.raw.length),"_"!==r.raw.slice(-1)&&(o=r.raw.slice(-1)),i=!0;const n=e.at(-1);"text"===n?.type?(n.raw+=r.raw,n.text+=r.text):e.push(r)}else if(t){const e="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(e);break}throw new Error(e)}}return e}}class Xi{options;parser;constructor(t){this.options=t||Jr}space(t){return""}code({text:t,lang:e,escaped:n}){const r=(e||"").match(ni.notSpaceStart)?.[0],i=t.replace(ni.endingNewline,"")+"\n";return r?'
'+(n?i:Gi(i,!0))+"
\n":"
"+(n?i:Gi(i,!0))+"
\n"}blockquote({tokens:t}){return`
\n${this.parser.parse(t)}
\n`}html({text:t}){return t}heading({tokens:t,depth:e}){return`${this.parser.parseInline(t)}\n`}hr(t){return"
\n"}list(t){const e=t.ordered,n=t.start;let r="";for(let e=0;e\n"+r+"\n"}listitem(t){let e="";if(t.task){const n=this.checkbox({checked:!!t.checked});t.loose?"paragraph"===t.tokens[0]?.type?(t.tokens[0].text=n+" "+t.tokens[0].text,t.tokens[0].tokens&&t.tokens[0].tokens.length>0&&"text"===t.tokens[0].tokens[0].type&&(t.tokens[0].tokens[0].text=n+" "+Gi(t.tokens[0].tokens[0].text),t.tokens[0].tokens[0].escaped=!0)):t.tokens.unshift({type:"text",raw:n+" ",text:n+" ",escaped:!0}):e+=n+" "}return e+=this.parser.parse(t.tokens,!!t.loose),`
  • ${e}
  • \n`}checkbox({checked:t}){return"'}paragraph({tokens:t}){return`

    ${this.parser.parseInline(t)}

    \n`}table(t){let e="",n="";for(let e=0;e${r}`),"\n\n"+e+"\n"+r+"
    \n"}tablerow({text:t}){return`\n${t}\n`}tablecell(t){const e=this.parser.parseInline(t.tokens),n=t.header?"th":"td";return(t.align?`<${n} align="${t.align}">`:`<${n}>`)+e+`\n`}strong({tokens:t}){return`${this.parser.parseInline(t)}`}em({tokens:t}){return`${this.parser.parseInline(t)}`}codespan({text:t}){return`${Gi(t,!0)}`}br(t){return"
    "}del({tokens:t}){return`${this.parser.parseInline(t)}`}link({href:t,title:e,tokens:n}){const r=this.parser.parseInline(n),i=Hi(t);if(null===i)return r;let o='
    ",o}image({href:t,title:e,text:n}){const r=Hi(t);if(null===r)return Gi(n);let i=`${n}{const i=t[r].flat(1/0);n=n.concat(this.walkTokens(i,e))})):t.tokens&&(n=n.concat(this.walkTokens(t.tokens,e)))}}return n}use(...t){const e=this.defaults.extensions||{renderers:{},childTokens:{}};return t.forEach((t=>{const n={...t};if(n.async=this.defaults.async||n.async||!1,t.extensions&&(t.extensions.forEach((t=>{if(!t.name)throw new Error("extension name required");if("renderer"in t){const n=e.renderers[t.name];e.renderers[t.name]=n?function(...e){let r=t.renderer.apply(this,e);return!1===r&&(r=n.apply(this,e)),r}:t.renderer}if("tokenizer"in t){if(!t.level||"block"!==t.level&&"inline"!==t.level)throw new Error("extension level must be 'block' or 'inline'");const n=e[t.level];n?n.unshift(t.tokenizer):e[t.level]=[t.tokenizer],t.start&&("block"===t.level?e.startBlock?e.startBlock.push(t.start):e.startBlock=[t.start]:"inline"===t.level&&(e.startInline?e.startInline.push(t.start):e.startInline=[t.start]))}"childTokens"in t&&t.childTokens&&(e.childTokens[t.name]=t.childTokens)})),n.extensions=e),t.renderer){const e=this.defaults.renderer||new Xi(this.defaults);for(const n in t.renderer){if(!(n in e))throw new Error(`renderer '${n}' does not exist`);if(["options","parser"].includes(n))continue;const r=n,i=t.renderer[r],o=e[r];e[r]=(...t)=>{let n=i.apply(e,t);return!1===n&&(n=o.apply(e,t)),n||""}}n.renderer=e}if(t.tokenizer){const e=this.defaults.tokenizer||new qi(this.defaults);for(const n in t.tokenizer){if(!(n in e))throw new Error(`tokenizer '${n}' does not exist`);if(["options","rules","lexer"].includes(n))continue;const r=n,i=t.tokenizer[r],o=e[r];e[r]=(...t)=>{let n=i.apply(e,t);return!1===n&&(n=o.apply(e,t)),n}}n.tokenizer=e}if(t.hooks){const e=this.defaults.hooks||new Qi;for(const n in t.hooks){if(!(n in e))throw new Error(`hook '${n}' does not exist`);if(["options","block"].includes(n))continue;const r=n,i=t.hooks[r],o=e[r];Qi.passThroughHooks.has(n)?e[r]=t=>{if(this.defaults.async)return Promise.resolve(i.call(e,t)).then((t=>o.call(e,t)));const n=i.call(e,t);return o.call(e,n)}:e[r]=(...t)=>{let n=i.apply(e,t);return!1===n&&(n=o.apply(e,t)),n}}n.hooks=e}if(t.walkTokens){const e=this.defaults.walkTokens,r=t.walkTokens;n.walkTokens=function(t){let n=[];return n.push(r.call(this,t)),e&&(n=n.concat(e.call(this,t))),n}}this.defaults={...this.defaults,...n}})),this}setOptions(t){return this.defaults={...this.defaults,...t},this}lexer(t,e){return Zi.lex(t,e??this.defaults)}parser(t,e){return Ji.parse(t,e??this.defaults)}parseMarkdown(t){return(e,n)=>{const r={...n},i={...this.defaults,...r},o=this.onError(!!i.silent,!!i.async);if(!0===this.defaults.async&&!1===r.async)return o(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(null==e)return o(new Error("marked(): input parameter is undefined or null"));if("string"!=typeof e)return o(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(e)+", string expected"));i.hooks&&(i.hooks.options=i,i.hooks.block=t);const s=i.hooks?i.hooks.provideLexer():t?Zi.lex:Zi.lexInline,a=i.hooks?i.hooks.provideParser():t?Ji.parse:Ji.parseInline;if(i.async)return Promise.resolve(i.hooks?i.hooks.preprocess(e):e).then((t=>s(t,i))).then((t=>i.hooks?i.hooks.processAllTokens(t):t)).then((t=>i.walkTokens?Promise.all(this.walkTokens(t,i.walkTokens)).then((()=>t)):t)).then((t=>a(t,i))).then((t=>i.hooks?i.hooks.postprocess(t):t)).catch(o);try{i.hooks&&(e=i.hooks.preprocess(e));let t=s(e,i);i.hooks&&(t=i.hooks.processAllTokens(t)),i.walkTokens&&this.walkTokens(t,i.walkTokens);let n=a(t,i);return i.hooks&&(n=i.hooks.postprocess(n)),n}catch(t){return o(t)}}}onError(t,e){return n=>{if(n.message+="\nPlease report this to https://github.com/markedjs/marked.",t){const t="

    An error occurred:

    "+Gi(n.message+"",!0)+"
    ";return e?Promise.resolve(t):t}if(e)return Promise.reject(n);throw n}}};function eo(t,e){return to.parse(t,e)}eo.options=eo.setOptions=function(t){return to.setOptions(t),eo.defaults=to.defaults,Qr(eo.defaults),eo},eo.getDefaults=Kr,eo.defaults=Jr,eo.use=function(...t){return to.use(...t),eo.defaults=to.defaults,Qr(eo.defaults),eo},eo.walkTokens=function(t,e){return to.walkTokens(t,e)},eo.parseInline=to.parseInline,eo.Parser=Ji,eo.parser=Ji.parse,eo.Renderer=Xi,eo.TextRenderer=Ki,eo.Lexer=Zi,eo.lexer=Zi.lex,eo.Tokenizer=qi,eo.Hooks=Qi,eo.parse=eo;eo.options,eo.setOptions,eo.use,eo.walkTokens,eo.parseInline,Ji.parse,Zi.lex;const{entries:no,setPrototypeOf:ro,isFrozen:io,getPrototypeOf:oo,getOwnPropertyDescriptor:so}=Object;let{freeze:ao,seal:co,create:lo}=Object,{apply:uo,construct:po}="undefined"!=typeof Reflect&&Reflect;ao||(ao=function(t){return t}),co||(co=function(t){return t}),uo||(uo=function(t,e,n){return t.apply(e,n)}),po||(po=function(t,e){return new t(...e)});const ho=To(Array.prototype.forEach),fo=To(Array.prototype.pop),mo=To(Array.prototype.push),go=To(String.prototype.toLowerCase),vo=To(String.prototype.toString),bo=To(String.prototype.match),yo=To(String.prototype.replace),_o=To(String.prototype.indexOf),wo=To(String.prototype.trim),ko=To(Object.prototype.hasOwnProperty),xo=To(RegExp.prototype.test),So=(Eo=TypeError,function(){for(var t=arguments.length,e=new Array(t),n=0;n1?n-1:0),i=1;i2&&void 0!==arguments[2]?arguments[2]:go;ro&&ro(t,null);let r=e.length;for(;r--;){let i=e[r];if("string"==typeof i){const t=n(i);t!==i&&(io(e)||(e[r]=t),i=t)}t[i]=!0}return t}function Oo(t){for(let e=0;e/gm),Ho=co(/\${[\w\W]*}/gm),Vo=co(/^data-[\-\w.\u00B7-\uFFFF]/),Wo=co(/^aria-[\-\w]+$/),Yo=co(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),qo=co(/^(?:\w+script|data):/i),Zo=co(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),Xo=co(/^html$/i),Ko=co(/^[a-z][.\w]*(-[.\w]+)+$/i);var Jo=Object.freeze({__proto__:null,ARIA_ATTR:Wo,ATTR_WHITESPACE:Zo,CUSTOM_ELEMENT:Ko,DATA_ATTR:Vo,DOCTYPE_NAME:Xo,ERB_EXPR:Go,IS_ALLOWED_URI:Yo,IS_SCRIPT_OR_DATA:qo,MUSTACHE_EXPR:Fo,TMPLIT_EXPR:Ho});const Qo=1,ts=3,es=7,ns=8,rs=9,is=function(){return"undefined"==typeof window?null:window};var os=function t(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:is();const n=e=>t(e);if(n.version="3.2.2",n.removed=[],!e||!e.document||e.document.nodeType!==rs)return n.isSupported=!1,n;let{document:r}=e;const i=r,o=i.currentScript,{DocumentFragment:s,HTMLTemplateElement:a,Node:c,Element:l,NodeFilter:u,NamedNodeMap:p=e.NamedNodeMap||e.MozNamedAttrMap,HTMLFormElement:d,DOMParser:h,trustedTypes:f}=e,m=l.prototype,g=Ao(m,"cloneNode"),v=Ao(m,"remove"),b=Ao(m,"nextSibling"),y=Ao(m,"childNodes"),_=Ao(m,"parentNode");if("function"==typeof a){const t=r.createElement("template");t.content&&t.content.ownerDocument&&(r=t.content.ownerDocument)}let w,k="";const{implementation:x,createNodeIterator:S,createDocumentFragment:E,getElementsByTagName:T}=r,{importNode:C}=i;let O={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]};n.isSupported="function"==typeof no&&"function"==typeof _&&x&&void 0!==x.createHTMLDocument;const{MUSTACHE_EXPR:I,ERB_EXPR:A,TMPLIT_EXPR:R,DATA_ATTR:D,ARIA_ATTR:P,IS_SCRIPT_OR_DATA:$,ATTR_WHITESPACE:L,CUSTOM_ELEMENT:N}=Jo;let{IS_ALLOWED_URI:j}=Jo,B=null;const M=Co({},[...Ro,...Do,...Po,...Lo,...jo]);let U=null;const z=Co({},[...Bo,...Mo,...Uo,...zo]);let F=Object.seal(lo(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),G=null,H=null,V=!0,W=!0,Y=!1,q=!0,Z=!1,X=!0,K=!1,J=!1,Q=!1,tt=!1,et=!1,nt=!1,rt=!0,it=!1,ot=!0,st=!1,at={},ct=null;const lt=Co({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let ut=null;const pt=Co({},["audio","video","img","source","image","track"]);let dt=null;const ht=Co({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),ft="http://www.w3.org/1998/Math/MathML",mt="http://www.w3.org/2000/svg",gt="http://www.w3.org/1999/xhtml";let vt=gt,bt=!1,yt=null;const _t=Co({},[ft,mt,gt],vo);let wt=Co({},["mi","mo","mn","ms","mtext"]),kt=Co({},["annotation-xml"]);const xt=Co({},["title","style","font","a","script"]);let St=null;const Et=["application/xhtml+xml","text/html"];let Tt=null,Ct=null;const Ot=r.createElement("form"),It=function(t){return t instanceof RegExp||t instanceof Function},At=function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(!Ct||Ct!==t){if(t&&"object"==typeof t||(t={}),t=Io(t),St=-1===Et.indexOf(t.PARSER_MEDIA_TYPE)?"text/html":t.PARSER_MEDIA_TYPE,Tt="application/xhtml+xml"===St?vo:go,B=ko(t,"ALLOWED_TAGS")?Co({},t.ALLOWED_TAGS,Tt):M,U=ko(t,"ALLOWED_ATTR")?Co({},t.ALLOWED_ATTR,Tt):z,yt=ko(t,"ALLOWED_NAMESPACES")?Co({},t.ALLOWED_NAMESPACES,vo):_t,dt=ko(t,"ADD_URI_SAFE_ATTR")?Co(Io(ht),t.ADD_URI_SAFE_ATTR,Tt):ht,ut=ko(t,"ADD_DATA_URI_TAGS")?Co(Io(pt),t.ADD_DATA_URI_TAGS,Tt):pt,ct=ko(t,"FORBID_CONTENTS")?Co({},t.FORBID_CONTENTS,Tt):lt,G=ko(t,"FORBID_TAGS")?Co({},t.FORBID_TAGS,Tt):{},H=ko(t,"FORBID_ATTR")?Co({},t.FORBID_ATTR,Tt):{},at=!!ko(t,"USE_PROFILES")&&t.USE_PROFILES,V=!1!==t.ALLOW_ARIA_ATTR,W=!1!==t.ALLOW_DATA_ATTR,Y=t.ALLOW_UNKNOWN_PROTOCOLS||!1,q=!1!==t.ALLOW_SELF_CLOSE_IN_ATTR,Z=t.SAFE_FOR_TEMPLATES||!1,X=!1!==t.SAFE_FOR_XML,K=t.WHOLE_DOCUMENT||!1,tt=t.RETURN_DOM||!1,et=t.RETURN_DOM_FRAGMENT||!1,nt=t.RETURN_TRUSTED_TYPE||!1,Q=t.FORCE_BODY||!1,rt=!1!==t.SANITIZE_DOM,it=t.SANITIZE_NAMED_PROPS||!1,ot=!1!==t.KEEP_CONTENT,st=t.IN_PLACE||!1,j=t.ALLOWED_URI_REGEXP||Yo,vt=t.NAMESPACE||gt,wt=t.MATHML_TEXT_INTEGRATION_POINTS||wt,kt=t.HTML_INTEGRATION_POINTS||kt,F=t.CUSTOM_ELEMENT_HANDLING||{},t.CUSTOM_ELEMENT_HANDLING&&It(t.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(F.tagNameCheck=t.CUSTOM_ELEMENT_HANDLING.tagNameCheck),t.CUSTOM_ELEMENT_HANDLING&&It(t.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(F.attributeNameCheck=t.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),t.CUSTOM_ELEMENT_HANDLING&&"boolean"==typeof t.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements&&(F.allowCustomizedBuiltInElements=t.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),Z&&(W=!1),et&&(tt=!0),at&&(B=Co({},jo),U=[],!0===at.html&&(Co(B,Ro),Co(U,Bo)),!0===at.svg&&(Co(B,Do),Co(U,Mo),Co(U,zo)),!0===at.svgFilters&&(Co(B,Po),Co(U,Mo),Co(U,zo)),!0===at.mathMl&&(Co(B,Lo),Co(U,Uo),Co(U,zo))),t.ADD_TAGS&&(B===M&&(B=Io(B)),Co(B,t.ADD_TAGS,Tt)),t.ADD_ATTR&&(U===z&&(U=Io(U)),Co(U,t.ADD_ATTR,Tt)),t.ADD_URI_SAFE_ATTR&&Co(dt,t.ADD_URI_SAFE_ATTR,Tt),t.FORBID_CONTENTS&&(ct===lt&&(ct=Io(ct)),Co(ct,t.FORBID_CONTENTS,Tt)),ot&&(B["#text"]=!0),K&&Co(B,["html","head","body"]),B.table&&(Co(B,["tbody"]),delete G.tbody),t.TRUSTED_TYPES_POLICY){if("function"!=typeof t.TRUSTED_TYPES_POLICY.createHTML)throw So('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if("function"!=typeof t.TRUSTED_TYPES_POLICY.createScriptURL)throw So('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');w=t.TRUSTED_TYPES_POLICY,k=w.createHTML("")}else void 0===w&&(w=function(t,e){if("object"!=typeof t||"function"!=typeof t.createPolicy)return null;let n=null;const r="data-tt-policy-suffix";e&&e.hasAttribute(r)&&(n=e.getAttribute(r));const i="dompurify"+(n?"#"+n:"");try{return t.createPolicy(i,{createHTML(t){return t},createScriptURL(t){return t}})}catch(t){return console.warn("TrustedTypes policy "+i+" could not be created."),null}}(f,o)),null!==w&&"string"==typeof k&&(k=w.createHTML(""));ao&&ao(t),Ct=t}},Rt=Co({},[...Do,...Po,...$o]),Dt=Co({},[...Lo,...No]),Pt=function(t){mo(n.removed,{element:t});try{_(t).removeChild(t)}catch(e){v(t)}},$t=function(t,e){try{mo(n.removed,{attribute:e.getAttributeNode(t),from:e})}catch(t){mo(n.removed,{attribute:null,from:e})}if(e.removeAttribute(t),"is"===t)if(tt||et)try{Pt(e)}catch(t){}else try{e.setAttribute(t,"")}catch(t){}},Lt=function(t){let e=null,n=null;if(Q)t=""+t;else{const e=bo(t,/^[\r\n\t ]+/);n=e&&e[0]}"application/xhtml+xml"===St&&vt===gt&&(t=''+t+"");const i=w?w.createHTML(t):t;if(vt===gt)try{e=(new h).parseFromString(i,St)}catch(t){}if(!e||!e.documentElement){e=x.createDocument(vt,"template",null);try{e.documentElement.innerHTML=bt?k:i}catch(t){}}const o=e.body||e.documentElement;return t&&n&&o.insertBefore(r.createTextNode(n),o.childNodes[0]||null),vt===gt?T.call(e,K?"html":"body")[0]:K?e.documentElement:o},Nt=function(t){return S.call(t.ownerDocument||t,t,u.SHOW_ELEMENT|u.SHOW_COMMENT|u.SHOW_TEXT|u.SHOW_PROCESSING_INSTRUCTION|u.SHOW_CDATA_SECTION,null)},jt=function(t){return t instanceof d&&("string"!=typeof t.nodeName||"string"!=typeof t.textContent||"function"!=typeof t.removeChild||!(t.attributes instanceof p)||"function"!=typeof t.removeAttribute||"function"!=typeof t.setAttribute||"string"!=typeof t.namespaceURI||"function"!=typeof t.insertBefore||"function"!=typeof t.hasChildNodes)},Bt=function(t){return"function"==typeof c&&t instanceof c};function Mt(t,e,r){ho(t,(t=>{t.call(n,e,r,Ct)}))}const Ut=function(t){let e=null;if(Mt(O.beforeSanitizeElements,t,null),jt(t))return Pt(t),!0;const r=Tt(t.nodeName);if(Mt(O.uponSanitizeElement,t,{tagName:r,allowedTags:B}),t.hasChildNodes()&&!Bt(t.firstElementChild)&&xo(/<[/\w]/g,t.innerHTML)&&xo(/<[/\w]/g,t.textContent))return Pt(t),!0;if(t.nodeType===es)return Pt(t),!0;if(X&&t.nodeType===ns&&xo(/<[/\w]/g,t.data))return Pt(t),!0;if(!B[r]||G[r]){if(!G[r]&&Ft(r)){if(F.tagNameCheck instanceof RegExp&&xo(F.tagNameCheck,r))return!1;if(F.tagNameCheck instanceof Function&&F.tagNameCheck(r))return!1}if(ot&&!ct[r]){const e=_(t)||t.parentNode,n=y(t)||t.childNodes;if(n&&e){for(let r=n.length-1;r>=0;--r){const i=g(n[r],!0);i.__removalCount=(t.__removalCount||0)+1,e.insertBefore(i,b(t))}}}return Pt(t),!0}return t instanceof l&&!function(t){let e=_(t);e&&e.tagName||(e={namespaceURI:vt,tagName:"template"});const n=go(t.tagName),r=go(e.tagName);return!!yt[t.namespaceURI]&&(t.namespaceURI===mt?e.namespaceURI===gt?"svg"===n:e.namespaceURI===ft?"svg"===n&&("annotation-xml"===r||wt[r]):Boolean(Rt[n]):t.namespaceURI===ft?e.namespaceURI===gt?"math"===n:e.namespaceURI===mt?"math"===n&&kt[r]:Boolean(Dt[n]):t.namespaceURI===gt?!(e.namespaceURI===mt&&!kt[r])&&!(e.namespaceURI===ft&&!wt[r])&&!Dt[n]&&(xt[n]||!Rt[n]):!("application/xhtml+xml"!==St||!yt[t.namespaceURI]))}(t)?(Pt(t),!0):"noscript"!==r&&"noembed"!==r&&"noframes"!==r||!xo(/<\/no(script|embed|frames)/i,t.innerHTML)?(Z&&t.nodeType===ts&&(e=t.textContent,ho([I,A,R],(t=>{e=yo(e,t," ")})),t.textContent!==e&&(mo(n.removed,{element:t.cloneNode()}),t.textContent=e)),Mt(O.afterSanitizeElements,t,null),!1):(Pt(t),!0)},zt=function(t,e,n){if(rt&&("id"===e||"name"===e)&&(n in r||n in Ot))return!1;if(W&&!H[e]&&xo(D,e));else if(V&&xo(P,e));else if(!U[e]||H[e]){if(!(Ft(t)&&(F.tagNameCheck instanceof RegExp&&xo(F.tagNameCheck,t)||F.tagNameCheck instanceof Function&&F.tagNameCheck(t))&&(F.attributeNameCheck instanceof RegExp&&xo(F.attributeNameCheck,e)||F.attributeNameCheck instanceof Function&&F.attributeNameCheck(e))||"is"===e&&F.allowCustomizedBuiltInElements&&(F.tagNameCheck instanceof RegExp&&xo(F.tagNameCheck,n)||F.tagNameCheck instanceof Function&&F.tagNameCheck(n))))return!1}else if(dt[e]);else if(xo(j,yo(n,L,"")));else if("src"!==e&&"xlink:href"!==e&&"href"!==e||"script"===t||0!==_o(n,"data:")||!ut[t]){if(Y&&!xo($,yo(n,L,"")));else if(n)return!1}else;return!0},Ft=function(t){return"annotation-xml"!==t&&bo(t,N)},Gt=function(t){Mt(O.beforeSanitizeAttributes,t,null);const{attributes:e}=t;if(!e)return;const r={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:U,forceKeepAttr:void 0};let i=e.length;for(;i--;){const o=e[i],{name:s,namespaceURI:a,value:c}=o,l=Tt(s);let u="value"===s?c:wo(c);if(r.attrName=l,r.attrValue=u,r.keepAttr=!0,r.forceKeepAttr=void 0,Mt(O.uponSanitizeAttribute,t,r),u=r.attrValue,!it||"id"!==l&&"name"!==l||($t(s,t),u="user-content-"+u),X&&xo(/((--!?|])>)|<\/(style|title)/i,u)){$t(s,t);continue}if(r.forceKeepAttr)continue;if($t(s,t),!r.keepAttr)continue;if(!q&&xo(/\/>/i,u)){$t(s,t);continue}Z&&ho([I,A,R],(t=>{u=yo(u,t," ")}));const p=Tt(t.nodeName);if(zt(p,l,u)){if(w&&"object"==typeof f&&"function"==typeof f.getAttributeType)if(a);else switch(f.getAttributeType(p,l)){case"TrustedHTML":u=w.createHTML(u);break;case"TrustedScriptURL":u=w.createScriptURL(u)}try{a?t.setAttributeNS(a,s,u):t.setAttribute(s,u),jt(t)?Pt(t):fo(n.removed)}catch(t){}}}Mt(O.afterSanitizeAttributes,t,null)},Ht=function t(e){let n=null;const r=Nt(e);for(Mt(O.beforeSanitizeShadowDOM,e,null);n=r.nextNode();)Mt(O.uponSanitizeShadowNode,n,null),Ut(n)||(n.content instanceof s&&t(n.content),Gt(n));Mt(O.afterSanitizeShadowDOM,e,null)};return n.sanitize=function(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=null,o=null,a=null,l=null;if(bt=!t,bt&&(t="\x3c!--\x3e"),"string"!=typeof t&&!Bt(t)){if("function"!=typeof t.toString)throw So("toString is not a function");if("string"!=typeof(t=t.toString()))throw So("dirty is not a string, aborting")}if(!n.isSupported)return t;if(J||At(e),n.removed=[],"string"==typeof t&&(st=!1),st){if(t.nodeName){const e=Tt(t.nodeName);if(!B[e]||G[e])throw So("root node is forbidden and cannot be sanitized in-place")}}else if(t instanceof c)r=Lt("\x3c!----\x3e"),o=r.ownerDocument.importNode(t,!0),o.nodeType===Qo&&"BODY"===o.nodeName||"HTML"===o.nodeName?r=o:r.appendChild(o);else{if(!tt&&!Z&&!K&&-1===t.indexOf("<"))return w&&nt?w.createHTML(t):t;if(r=Lt(t),!r)return tt?null:nt?k:""}r&&Q&&Pt(r.firstChild);const u=Nt(st?t:r);for(;a=u.nextNode();)Ut(a)||(a.content instanceof s&&Ht(a.content),Gt(a));if(st)return t;if(tt){if(et)for(l=E.call(r.ownerDocument);r.firstChild;)l.appendChild(r.firstChild);else l=r;return(U.shadowroot||U.shadowrootmode)&&(l=C.call(i,l,!0)),l}let p=K?r.outerHTML:r.innerHTML;return K&&B["!doctype"]&&r.ownerDocument&&r.ownerDocument.doctype&&r.ownerDocument.doctype.name&&xo(Xo,r.ownerDocument.doctype.name)&&(p="\n"+p),Z&&ho([I,A,R],(t=>{p=yo(p,t," ")})),w&&nt?w.createHTML(p):p},n.setConfig=function(){At(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}),J=!0},n.clearConfig=function(){Ct=null,J=!1},n.isValidAttribute=function(t,e,n){Ct||At({});const r=Tt(t),i=Tt(e);return zt(r,i,n)},n.addHook=function(t,e){"function"==typeof e&&mo(O[t],e)},n.removeHook=function(t){return fo(O[t])},n.removeHooks=function(t){O[t]=[]},n.removeAllHooks=function(){O={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},n}();const ss=Object.assign({},Ft),as=Object.assign(Object.assign(Object.assign({},oe),Ht),Kt);const cs={addBlockActions:({block:t,blockActions:e,popupActions:n})=>{e.onClick=()=>n.handleButtonClick(t)},defaultStyles:{[as.BLOCK]:{mobile:{[le]:"transparent",[ge]:"0px 0px 0px 0px",[ze]:"0px 0px 0px 0px",[qe]:"1",[Ze]:"0px 0px 0px 0px",[Xe]:"relative"}},[as.TEXT]:{mobile:{[ke]:dn.TEXT,[Ce]:hn.ARIAL,[Oe]:"16px",[Ie]:"normal",[Ae]:"normal",[nn]:"center",[rn]:"none",[Ue]:"1.2",[ze]:"0px 0px 0px 0px"}},[as.LINK]:{mobile:{[ke]:"inherit"}}},render:function(t){var e,n,r;const{block:i,blockActions:o,content:s,classes:a,environment:c}=t,l=null!==(n=null===(e=c.enabledFeatureFlags)||void 0===e?void 0:e.includes("popup_rich_text_content"))&&void 0!==n&&n,{block:u,editorNode:p,text:d}=a,h=null!==(r=s[Gt.PARAGRAPH])&&void 0!==r?r:"";return V`
    ${zn(p,c,o)}

    ${l?Xr(((t,e)=>{const n=new eo.Renderer;n.link=({href:t,text:n})=>`${n}`;const r=eo.parseInline(t,{async:!1,breaks:!0,renderer:n});return os.sanitize(r,{ALLOWED_TAGS:["a","br","code","del","em","span","strong"],ADD_ATTR:["target"]})})(h,i.id)):h}

    `},styleElements:as,textElements:ss};var ls=cs;const us=Object.assign(Object.assign({},Ht),qt);var ps={defaultStyles:{[us.BLOCK]:{mobile:{[ce]:"center",[ze]:"0px 0px 0px 0px",[qe]:"1",[Ze]:"0px 0px 0px 0px",[ln]:"100px",[Xe]:"relative"}},[us.IMAGE]:{mobile:{[me]:dn.BORDER,[ge]:"0px 0px 0px 0px",[ve]:"none",[be]:"1px",[$e]:"auto",[Ge]:"100%",[xe]:"block",[ln]:"100%"}}},render:function(t){var e,n,r;const{blockActions:i,classes:o,environment:s}=t,{block:a,image:c,editorNode:l}=o;return V`
    ${zn(l,s,i)} ${null!==(r=null===(n=t.block.config)||void
    `},styleElements:us};const ds={[kt]:Vn,[xt]:qn,[St]:Xn,[Et]:er,[Tt]:ir,[Ct]:ps,[Ot]:lr,[It]:br,[At]:_r,[Rt]:xr,[Pt]:Hr,[$t]:qr,[Lt]:ls,[Dt]:Ur},hs={render(t){return ds[t.block.type].render(t)},getTextElements(t){var e;return null!==(e=ds[t].textElements)&&void 0!==e?e:{}},getStyleElements(t){var e;return null!==(e=ds[t].styleElements)&&void 0!==e?e:{}},getDefaultStyles(t){return ds[t].defaultStyles},isEmpty(t){var e;const{type:n}=t,r=ds[n];return!!(null===(e=r.isEmpty)||void 0===e?void 0:e.call(r,t))},addBlockActions({block:t,blockActions:e,environment:n,popupActions:r,stepBlocks:i}){var o;const{type:s}=t,a=ds[s];null===(o=a.addBlockActions)||void 0===o||o.call(a,{block:t,blockActions:e,environment:n,popupActions:r,stepBlocks:i})},validateBlockData(t,e){var n;const{type:r}=t,i=ds[r];return(null===(n=i.validateBlockData)||void 0===n?void 0:n.call(i,t,e))||null}};var fs=hs;const ms=t=>t===On?`"${`${On} `.repeat(12)}"`:`"${`${In} `.repeat(12)}"`,gs=t=>t===Rn?`"${`${On} `.repeat(6)} ${`${In} `.repeat(6)}"`.trim():`"${`${In} `.repeat(6)} ${`${On} `.repeat(6)}"`.trim(),vs={backgroundImage:t=>`\n background-image: url(${(t=>{var e;if(!t)return;const n=t.match(/url\((.*?)\)/);return null!==(e=null==n?void 0:n[1])&&void 0!==e?e:t})(t)});\n`,layoutDirection:t=>`flex-direction: ${t};`,layoutSpacing:t=>`justify-content: ${t};`,rootLayout:t=>t===Dn?`\n grid-template-areas: ${ms(In)};\n grid-template-rows: auto;\n `.trim():t===$n?`\n grid-template-areas: ${ms(On)} ${ms(In)};\n grid-template-rows: auto 1fr;\n `.trim():t===An?`\n grid-template-areas: ${ms(In)} ${ms(On)};\n grid-template-rows: 1fr auto;\n `.trim():t===Rn?`\n grid-template-areas: ${gs(Rn)};\n grid-template-rows: auto;\n `.trim():`\n grid-template-areas: ${gs(Pn)};\n grid-template-rows: auto;\n `.trim(),spinToWinDuration:t=>`${Mn}: ${t};`},bs=(t,e)=>`${e}-${t.id}`,ys=t=>Object.entries(t).reduce(((t,[e,n])=>{const r=((t,e)=>{const n=fn[t];return n?`${n}: ${e};`:vs[t]?vs[t](e):void 0})(e,n);return r?`${t}${r}`:t}),""),_s=(t,e=[])=>{let n=null;const r={};return Object.entries(t).forEach((([t,i])=>{"variant"===t?n=e.find((t=>t.id===i))||null:t.startsWith("hover")||t.startsWith("focus")||(r[t]=i)})),{variant:n,hover:{},focus:{},initial:r}},ws=(t,e,n)=>{const r=Object.values(fs.getStyleElements(t.type)),i=((t,e,n)=>{const r={},i=fs.getStyleElements(t.type),o=fs.getDefaultStyles(t.type),s=t.styles;return Object.values(i).forEach((t=>{var i,a;const c=o[t],l=null==s?void 0:s[t],u=n[t],p=null!==(i=Er(e,c))&&void 0!==i?i:{},d=null!==(a=Er(e,l))&&void 0!==a?a:{},{initial:h}=_s(p,u),{initial:f,variant:m}=_s(d,u);r[t]={default:h,variant:m,instance:f}})),r})(t,n,e),o={};return r.forEach((t=>{const e=i[t];if(e){const n=(t=>{var e;return Object.assign(Object.assign(Object.assign({},t.default),(null===(e=t.variant)||void 0===e?void 0:e.styles)||{}),t.instance)})(e);o[t]=n}})),o},ks=({stepBlocks:t,teaserBlocks:e,theme:n,viewport:r})=>{const i=!r||r===Nt,o=!r||r===jt;return{[Nt]:i?[...t,...e].map((t=>ws(t,n,Nt))):void 0,[jt]:o?[...t,...e].map((t=>ws(t,n,jt))):void 0}},xs=(t,e,n)=>t.reduce(((t,r)=>{const i=((t,e,n)=>{let r="";const i=ws(t,n,e);return Object.entries(i).forEach((([e,n])=>{const i=`.${bs(t,e)}`,o=ys(n);r+=`${i} { ${o} }\n`})),r})(r,e,n);return i?`${t} ${i}`:t}),""),Ss=({stepBlocks:t,teaserBlocks:e,theme:n,viewport:r})=>{const i=(({stepBlocks:t,styleRuleName:e,teaserBlocks:n,theme:r,viewport:i})=>{const{mobile:o=[],desktop:s=[]}=ks({stepBlocks:t,teaserBlocks:n,theme:r,viewport:i}),a=new Set;return[...o,...s].forEach((t=>{Object.values(t).forEach((t=>{const n=t[e];n&&a.add(n)}))})),[...a]})({stepBlocks:t,teaserBlocks:e,styleRuleName:Ce,theme:n,viewport:r});return i.map((t=>(t=>{const e=t.match(/'([^']*)'/);return e?e[1]:""})(t)))};var Es=function(t,e,n,r){return new(n||(n=Promise))((function(i,o){function s(t){try{c(r.next(t))}catch(t){o(t)}}function a(t){try{c(r.throw(t))}catch(t){o(t)}}function c(t){var e;t.done?i(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(s,a)}c((r=r.apply(t,e||[])).next())}))};var Ts=n(490),Cs=n.n(Ts);const Os={ROBOTO:"Roboto",OPEN_SANS:"Open Sans",LATO:"Lato",MONTSERRAT:"Montserrat",OSWALD:"Oswald",POPPINS:"Poppins",RUBIK:"Rubik",QUICKSAND:"Quicksand",PLAYFAIR_DISPLAY:"Playfair Display",FRAUNCES:"Fraunces"},Is=t=>Object.values(Os).includes(t);var As=function(t,e,n,r){return new(n||(n=Promise))((function(i,o){function s(t){try{c(r.next(t))}catch(t){o(t)}}function a(t){try{c(r.throw(t))}catch(t){o(t)}}function c(t){var e;t.done?i(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(s,a)}c((r=r.apply(t,e||[])).next())}))};const Rs=({stepBlocks:t,teaserBlocks:e,theme:n},r,i)=>As(void 0,void 0,void 0,(function*(){const o=Ss({stepBlocks:t,teaserBlocks:e,theme:n,viewport:r});yield((t,e)=>Es(void 0,void 0,void 0,(function*(){const n=e.filter((e=>t.includes(e.name))),r=n.map((t=>`\n @font-face {\n font-family: '${t.name}';\n src: url('${t.src}');\n }\n `)),i=document.createElement("style");i.innerText=r.join("\n"),document.head.appendChild(i)})))(o,i),(t=>{const e=t.filter(Is);e.length&&Cs().load({classes:!1,events:!1,google:{families:e}})})(o)})),Ds="dragging-over";var Ps=(t,e,n)=>{const{popupActions:{handleAddDrop:r,handleReorderDrop:i},environment:{isDraggingAddBlock:o,isDraggingReorderBlock:s}}=t;return V`
    t.preventDefault()} @dragenter=${t=>{t.currentTarget.classList.add(Ds)}} @dragleave=${t=>{t.currentTarget.classList.remove(Ds)}} @drop=${t=>{t.currentTarget.classList.remove(Ds),o&&(null==r||r(e,n)),s&&(null==i||i(e,n))}} class=${_t({dragging:!(!o&&!s),"drop-zone":!0})} >
    `};function $s(t,e){var n,r;const{blockState:i,environment:{isDevelopment:o}}=e,s=fs.getStyleElements(t.type),a=t.type===St,c=t.type===At||t.type===Rt,l=t.type===$t,u=fs.isEmpty(t),p=((t,{environment:{viewport:e},theme:n})=>{var r;return null===(r=ws(t,n,e)[t.type===Rt?se.MAIN_POPUP_CONTAINER:se.BLOCK])||void 0===r?void 0:r.layoutDirection})(t,e),d="row"===p,h="column"===p,f=t.type===Rt,m={[se.BLOCK]:Object.assign({"root-block":c,"teaser-root-block":l,container:a},f?{}:{"empty-layout":u,"horizontal-layout":d,"vertical-layout":h}),[se.MAIN_POPUP_CONTAINER]:Object.assign({"main-popup-container":f},f?{"empty-layout":u,"horizontal-layout":d,"vertical-layout":h}:{})},g={editorNode:{"editor-node":!0,error:!!(null===(n=i[t.id])||void 0===n?void 0:n.error),selected:!!(null===(r=i[t.id])||void 0===r?void 0:r.selected)}};return Object.values(s).reduce(((e,n)=>{const r=n===se.BLOCK||n===se.MAIN_POPUP_CONTAINER,i=bs(t,n);return Object.assign(Object.assign({},e),{[n]:Object.assign(Object.assign({},o&&r?m[n]:{}),{[i]:!0})})}),g)}function Ls(t,e){if(!t.children)return null;const{blocks:n,reorderingIds:r}=e,i=t.children.map((t=>{const r=n.find((e=>e.id===t));if(!r)throw new Error(`Block with id ${t} not found`);return Ns(r,e)}),[]);return(null==r?void 0:r.includes(t.id))?i:((t,e,n)=>{const{environment:{isDevelopment:r}}=n,i=t.type===At||t.type===Rt,o=t.type===St;return r&&(o||i)?e.reduce(((e,r,i)=>{const o=Ps(n,t.id,i+1);return e.push(r,o),e}),i?[]:[Ps(n,t.id,0)]):e})(t,i,e)}function Ns(t,e){const n=$s(t,e),r=(t=>{const e=fs.getTextElements(t.type);return t.content&&e?Object.values(e).reduce(((e,n)=>{var r,i;return e[n]=(null===(i=null===(r=t.content)||void 0===r?void 0:r[n])||void 0===i?void 0:i.default)||"",e}),{}):{}})(t),i=Ls(t,e),o=function(t,e){const{popupActions:n,environment:r}=e,i=r.isDevelopment?((t,e)=>{var n,r,i,o;const{selectBlock:s,handleReorderDragStart:a,handleReorderDragEnd:c,setEmailIntegration:l,deleteBlock:u,duplicateBlock:p}=e.popupActions,d={};return s&&(d.selectBlock=e=>{e.stopPropagation(),s(t.id)}),a&&(d.handleReorderDragStart=e=>{a(e,t.id)}),c&&(d.handleReorderDragEnd=c),l&&(d.setEmailIntegration=l),u&&!(null===(r=null===(n=e.editorRestrictions)||void 0===n?void 0:n.delete)||void 0===r?void 0:r.includes(t.id))&&(d.deleteBlock=()=>u(t.id)),p&&!(null===(o=null===(i=e.editorRestrictions)||void 0===i?void 0:i.duplicate)||void 0===o?void 0:o.includes(t.id))&&(d.duplicateBlock=()=>p(t.id)),d})(t,e):{};return fs.addBlockActions({block:t,blockActions:i,environment:r,popupActions:n,stepBlocks:e.stepBlocks}),i}(t,e),s=e.blockState[t.id],{disclaimer:a,environment:c,theme:l}=e,u={blockActions:o,block:t,children:i,classes:n,content:r,disclaimer:a,environment:c,finalStyleRules:ws(t,l,c.viewport),state:s};return fs.render(u)}const js=t=>{const e=t.blocks.find((t=>t.type===At||t.type===$t||t.type===Rt));if(!e)throw new Error("No root block found");const n=xs(t.blocks,t.environment.viewport,t.theme);return V` ${Ns(e,t)} `},Bs=Object.prototype.toString;function Ms(t){switch(Bs.call(t)){case"[object Error]":case"[object Exception]":case"[object DOMException]":return!0;default:return qs(t,Error)}}function Us(t,e){return Bs.call(t)===`[object ${e}]`}function zs(t){return Us(t,"ErrorEvent")}function Fs(t){return Us(t,"DOMError")}function Gs(t){return Us(t,"String")}function Hs(t){return null===t||"object"!=typeof t&&"function"!=typeof t}function Vs(t){return Us(t,"Object")}function Ws(t){return"undefined"!=typeof Event&&qs(t,Event)}function Ys(t){return Boolean(t&&t.then&&"function"==typeof t.then)}function qs(t,e){try{return t instanceof e}catch(t){return!1}}var Zs=n(722);const Xs=(0,Zs.VZ)();function Ks(t,e={}){try{let n=t;const r=5,i=[];let o=0,s=0;const a=" > ",c=a.length;let l;const u=Array.isArray(e)?e:e.keyAttrs,p=!Array.isArray(e)&&e.maxStringLength||80;for(;n&&o++1&&s+i.length*c+l.length>=p));)i.push(l),s+=l.length,n=n.parentNode;return i.reverse().join(a)}catch(t){return""}}function Js(t,e){const n=t,r=[];let i,o,s,a,c;if(!n||!n.tagName)return"";r.push(n.tagName.toLowerCase());const l=e&&e.length?e.filter((t=>n.getAttribute(t))).map((t=>[t,n.getAttribute(t)])):null;if(l&&l.length)l.forEach((t=>{r.push(`[${t[0]}="${t[1]}"]`)}));else if(n.id&&r.push(`#${n.id}`),i=n.className,i&&Gs(i))for(o=i.split(/\s+/),c=0;cea(t,e,n)))}function ra(t,e,n){if(!(e in t))return;const r=t[e],i=n(r);if("function"==typeof i)try{oa(i,r)}catch(t){}t[e]=i}function ia(t,e,n){Object.defineProperty(t,e,{value:n,writable:!0,configurable:!0})}function oa(t,e){const n=e.prototype||{};t.prototype=e.prototype=n,ia(t,"__sentry_original__",e)}function sa(t){return t.__sentry_original__}function aa(t){if(Ms(t))return{message:t.message,name:t.name,stack:t.stack,...la(t)};if(Ws(t)){const e={type:t.type,target:ca(t.target),currentTarget:ca(t.currentTarget),...la(t)};return"undefined"!=typeof CustomEvent&&qs(t,CustomEvent)&&(e.detail=t.detail),e}return t}function ca(t){try{return e=t,"undefined"!=typeof Element&&qs(e,Element)?Ks(t):Object.prototype.toString.call(t)}catch(t){return""}var e}function la(t){if("object"==typeof t&&null!==t){const e={};for(const n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}return{}}function ua(t){return pa(t,new Map)}function pa(t,e){if(Vs(t)){const n=e.get(t);if(void 0!==n)return n;const r={};e.set(t,r);for(const n of Object.keys(t))void 0!==t[n]&&(r[n]=pa(t[n],e));return r}if(Array.isArray(t)){const n=e.get(t);if(void 0!==n)return n;const r=[];return e.set(t,r),t.forEach((t=>{r.push(pa(t,e))})),r}return t}function da(){const t=Zs.OW,e=t.crypto||t.msCrypto;if(e&&e.randomUUID)return e.randomUUID().replace(/-/g,"");const n=e&&e.getRandomValues?()=>e.getRandomValues(new Uint8Array(1))[0]:()=>16*Math.random();return([1e7]+1e3+4e3+8e3+1e11).replace(/[018]/g,(t=>(t^(15&n())>>t/4).toString(16)))}function ha(t){return t.exception&&t.exception.values?t.exception.values[0]:void 0}function fa(t){const{message:e,event_id:n}=t;if(e)return e;const r=ha(t);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||n||"":n||""}function ma(t,e,n){const r=t.exception=t.exception||{},i=r.values=r.values||[],o=i[0]=i[0]||{};o.value||(o.value=e||""),o.type||(o.type=n||"Error")}function ga(t,e){const n=ha(t);if(!n)return;const r=n.mechanism;if(n.mechanism={type:"generic",handled:!0,...r,...e},e&&"data"in e){const t={...r&&r.data,...e.data};n.mechanism.data=t}}function va(t){if(t&&t.__sentry_captured__)return!0;try{ia(t,"__sentry_captured__",!0)}catch(t){}return!1}function ba(t){return Array.isArray(t)?t:[t]}var ya=n(297);const _a=["debug","info","warn","error","log","assert","trace"];function wa(t){if(!("console"in Zs.OW))return t();const e=Zs.OW.console,n={};_a.forEach((t=>{const r=e[t]&&e[t].__sentry_original__;t in e&&r&&(n[t]=e[t],e[t]=r)}));try{return t()}finally{Object.keys(n).forEach((t=>{e[t]=n[t]}))}}function ka(){let t=!1;const e={enable:()=>{t=!0},disable:()=>{t=!1}};return"undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__?_a.forEach((n=>{e[n]=(...e)=>{t&&wa((()=>{Zs.OW.console[n](`Sentry Logger [${n}]:`,...e)}))}})):_a.forEach((t=>{e[t]=()=>{}})),e}let xa;xa="undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__?(0,Zs.BY)("logger",ka):ka();const Sa="production";var Ea;function Ta(t){return new Oa((e=>{e(t)}))}function Ca(t){return new Oa(((e,n)=>{n(t)}))}!function(t){t[t.PENDING=0]="PENDING";t[t.RESOLVED=1]="RESOLVED";t[t.REJECTED=2]="REJECTED"}(Ea||(Ea={}));class Oa{__init(){this._state=Ea.PENDING}__init2(){this._handlers=[]}constructor(t){Oa.prototype.__init.call(this),Oa.prototype.__init2.call(this),Oa.prototype.__init3.call(this),Oa.prototype.__init4.call(this),Oa.prototype.__init5.call(this),Oa.prototype.__init6.call(this);try{t(this._resolve,this._reject)}catch(t){this._reject(t)}}then(t,e){return new Oa(((n,r)=>{this._handlers.push([!1,e=>{if(t)try{n(t(e))}catch(t){r(t)}else n(e)},t=>{if(e)try{n(e(t))}catch(t){r(t)}else r(t)}]),this._executeHandlers()}))}catch(t){return this.then((t=>t),t)}finally(t){return new Oa(((e,n)=>{let r,i;return this.then((e=>{i=!1,r=e,t&&t()}),(e=>{i=!0,r=e,t&&t()})).then((()=>{i?n(r):e(r)}))}))}__init3(){this._resolve=t=>{this._setResult(Ea.RESOLVED,t)}}__init4(){this._reject=t=>{this._setResult(Ea.REJECTED,t)}}__init5(){this._setResult=(t,e)=>{this._state===Ea.PENDING&&(Ys(e)?e.then(this._resolve,this._reject):(this._state=t,this._value=e,this._executeHandlers()))}}__init6(){this._executeHandlers=()=>{if(this._state===Ea.PENDING)return;const t=this._handlers.slice();this._handlers=[],t.forEach((t=>{t[0]||(this._state===Ea.RESOLVED&&t[1](this._value),this._state===Ea.REJECTED&&t[2](this._value),t[0]=!0)}))}}}function Ia(t){const e=(0,ya.zf)(),n={sid:da(),init:!0,timestamp:e,started:e,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>function(t){return ua({sid:`${t.sid}`,init:t.init,started:new Date(1e3*t.started).toISOString(),timestamp:new Date(1e3*t.timestamp).toISOString(),status:t.status,errors:t.errors,did:"number"==typeof t.did||"string"==typeof t.did?`${t.did}`:void 0,duration:t.duration,attrs:{release:t.release,environment:t.environment,ip_address:t.ipAddress,user_agent:t.userAgent}})}(n)};return t&&Aa(n,t),n}function Aa(t,e={}){if(e.user&&(!t.ipAddress&&e.user.ip_address&&(t.ipAddress=e.user.ip_address),t.did||e.did||(t.did=e.user.id||e.user.email||e.user.username)),t.timestamp=e.timestamp||(0,ya.zf)(),e.ignoreDuration&&(t.ignoreDuration=e.ignoreDuration),e.sid&&(t.sid=32===e.sid.length?e.sid:da()),void 0!==e.init&&(t.init=e.init),!t.did&&e.did&&(t.did=`${e.did}`),"number"==typeof e.started&&(t.started=e.started),t.ignoreDuration)t.duration=void 0;else if("number"==typeof e.duration)t.duration=e.duration;else{const e=t.timestamp-t.started;t.duration=e>=0?e:0}e.release&&(t.release=e.release),e.environment&&(t.environment=e.environment),!t.ipAddress&&e.ipAddress&&(t.ipAddress=e.ipAddress),!t.userAgent&&e.userAgent&&(t.userAgent=e.userAgent),"number"==typeof e.errors&&(t.errors=e.errors),e.status&&(t.status=e.status)}class Ra{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext=$a()}static clone(t){const e=new Ra;return t&&(e._breadcrumbs=[...t._breadcrumbs],e._tags={...t._tags},e._extra={...t._extra},e._contexts={...t._contexts},e._user=t._user,e._level=t._level,e._span=t._span,e._session=t._session,e._transactionName=t._transactionName,e._fingerprint=t._fingerprint,e._eventProcessors=[...t._eventProcessors],e._requestSession=t._requestSession,e._attachments=[...t._attachments],e._sdkProcessingMetadata={...t._sdkProcessingMetadata},e._propagationContext={...t._propagationContext}),e}addScopeListener(t){this._scopeListeners.push(t)}addEventProcessor(t){return this._eventProcessors.push(t),this}setUser(t){return this._user=t||{},this._session&&Aa(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(t){return this._requestSession=t,this}setTags(t){return this._tags={...this._tags,...t},this._notifyScopeListeners(),this}setTag(t,e){return this._tags={...this._tags,[t]:e},this._notifyScopeListeners(),this}setExtras(t){return this._extra={...this._extra,...t},this._notifyScopeListeners(),this}setExtra(t,e){return this._extra={...this._extra,[t]:e},this._notifyScopeListeners(),this}setFingerprint(t){return this._fingerprint=t,this._notifyScopeListeners(),this}setLevel(t){return this._level=t,this._notifyScopeListeners(),this}setTransactionName(t){return this._transactionName=t,this._notifyScopeListeners(),this}setContext(t,e){return null===e?delete this._contexts[t]:this._contexts[t]=e,this._notifyScopeListeners(),this}setSpan(t){return this._span=t,this._notifyScopeListeners(),this}getSpan(){return this._span}getTransaction(){const t=this.getSpan();return t&&t.transaction}setSession(t){return t?this._session=t:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;if("function"==typeof t){const e=t(this);return e instanceof Ra?e:this}return t instanceof Ra?(this._tags={...this._tags,...t._tags},this._extra={...this._extra,...t._extra},this._contexts={...this._contexts,...t._contexts},t._user&&Object.keys(t._user).length&&(this._user=t._user),t._level&&(this._level=t._level),t._fingerprint&&(this._fingerprint=t._fingerprint),t._requestSession&&(this._requestSession=t._requestSession),t._propagationContext&&(this._propagationContext=t._propagationContext)):Vs(t)&&(this._tags={...this._tags,...t.tags},this._extra={...this._extra,...t.extra},this._contexts={...this._contexts,...t.contexts},t.user&&(this._user=t.user),t.level&&(this._level=t.level),t.fingerprint&&(this._fingerprint=t.fingerprint),t.requestSession&&(this._requestSession=t.requestSession),t.propagationContext&&(this._propagationContext=t.propagationContext)),this}clear(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._requestSession=void 0,this._span=void 0,this._session=void 0,this._notifyScopeListeners(),this._attachments=[],this._propagationContext=$a(),this}addBreadcrumb(t,e){const n="number"==typeof e?e:100;if(n<=0)return this;const r={timestamp:(0,ya.lu)(),...t};return this._breadcrumbs=[...this._breadcrumbs,r].slice(-n),this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(t){return this._attachments.push(t),this}getAttachments(){return this._attachments}clearAttachments(){return this._attachments=[],this}applyToEvent(t,e={}){if(this._extra&&Object.keys(this._extra).length&&(t.extra={...this._extra,...t.extra}),this._tags&&Object.keys(this._tags).length&&(t.tags={...this._tags,...t.tags}),this._user&&Object.keys(this._user).length&&(t.user={...this._user,...t.user}),this._contexts&&Object.keys(this._contexts).length&&(t.contexts={...this._contexts,...t.contexts}),this._level&&(t.level=this._level),this._transactionName&&(t.transaction=this._transactionName),this._span){t.contexts={trace:this._span.getTraceContext(),...t.contexts};const e=this._span.transaction;if(e){t.sdkProcessingMetadata={dynamicSamplingContext:e.getDynamicSamplingContext(),...t.sdkProcessingMetadata};const n=e.name;n&&(t.tags={transaction:n,...t.tags})}}return this._applyFingerprint(t),t.breadcrumbs=[...t.breadcrumbs||[],...this._breadcrumbs],t.breadcrumbs=t.breadcrumbs.length>0?t.breadcrumbs:void 0,t.sdkProcessingMetadata={...t.sdkProcessingMetadata,...this._sdkProcessingMetadata,propagationContext:this._propagationContext},this._notifyEventProcessors([...Da(),...this._eventProcessors],t,e)}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata={...this._sdkProcessingMetadata,...t},this}setPropagationContext(t){return this._propagationContext=t,this}getPropagationContext(){return this._propagationContext}_notifyEventProcessors(t,e,n,r=0){return new Oa(((i,o)=>{const s=t[r];if(null===e||"function"!=typeof s)i(e);else{const a=s({...e},n);("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&s.id&&null===a&&xa.log(`Event processor "${s.id}" dropped event`),Ys(a)?a.then((e=>this._notifyEventProcessors(t,e,n,r+1).then(i))).then(null,o):this._notifyEventProcessors(t,a,n,r+1).then(i).then(null,o)}}))}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach((t=>{t(this)})),this._notifyingListeners=!1)}_applyFingerprint(t){t.fingerprint=t.fingerprint?ba(t.fingerprint):[],this._fingerprint&&(t.fingerprint=t.fingerprint.concat(this._fingerprint)),t.fingerprint&&!t.fingerprint.length&&delete t.fingerprint}}function Da(){return(0,Zs.BY)("globalEventProcessors",(()=>[]))}function Pa(t){Da().push(t)}function $a(){return{traceId:da(),spanId:da().substring(16),sampled:!1}}const La=100;class Na{constructor(t,e=new Ra,n=4){this._version=n,this._stack=[{scope:e}],t&&this.bindClient(t)}isOlderThan(t){return this._version{i.captureException(t,{originalException:t,syntheticException:r,...e,event_id:n},o)})),n}captureMessage(t,e,n){const r=this._lastEventId=n&&n.event_id?n.event_id:da(),i=new Error(t);return this._withClient(((o,s)=>{o.captureMessage(t,e,{originalException:t,syntheticException:i,...n,event_id:r},s)})),r}captureEvent(t,e){const n=e&&e.event_id?e.event_id:da();return t.type||(this._lastEventId=n),this._withClient(((r,i)=>{r.captureEvent(t,{...e,event_id:n},i)})),n}lastEventId(){return this._lastEventId}addBreadcrumb(t,e){const{scope:n,client:r}=this.getStackTop();if(!r)return;const{beforeBreadcrumb:i=null,maxBreadcrumbs:o=La}=r.getOptions&&r.getOptions()||{};if(o<=0)return;const s={timestamp:(0,ya.lu)(),...t},a=i?wa((()=>i(s,e))):s;null!==a&&(r.emit&&r.emit("beforeAddBreadcrumb",a,e),n.addBreadcrumb(a,o))}setUser(t){this.getScope().setUser(t)}setTags(t){this.getScope().setTags(t)}setExtras(t){this.getScope().setExtras(t)}setTag(t,e){this.getScope().setTag(t,e)}setExtra(t,e){this.getScope().setExtra(t,e)}setContext(t,e){this.getScope().setContext(t,e)}configureScope(t){const{scope:e,client:n}=this.getStackTop();n&&t(e)}run(t){const e=Ba(this);try{t(this)}finally{Ba(e)}}getIntegration(t){const e=this.getClient();if(!e)return null;try{return e.getIntegration(t)}catch(e){return("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn(`Cannot retrieve integration ${t.id} from the current Hub`),null}}startTransaction(t,e){const n=this._callExtensionMethod("startTransaction",t,e);return"undefined"!=typeof __SENTRY_DEBUG__&&!__SENTRY_DEBUG__||n||console.warn("Tracing extension 'startTransaction' has not been added. Call 'addTracingExtensions' before calling 'init':\nSentry.addTracingExtensions();\nSentry.init({...});\n"),n}traceHeaders(){return this._callExtensionMethod("traceHeaders")}captureSession(t=!1){if(t)return this.endSession();this._sendSessionUpdate()}endSession(){const t=this.getStackTop().scope,e=t.getSession();e&&function(t,e){let n={};e?n={status:e}:"ok"===t.status&&(n={status:"exited"}),Aa(t,n)}(e),this._sendSessionUpdate(),t.setSession()}startSession(t){const{scope:e,client:n}=this.getStackTop(),{release:r,environment:i=Sa}=n&&n.getOptions()||{},{userAgent:o}=Zs.OW.navigator||{},s=Ia({release:r,environment:i,user:e.getUser(),...o&&{userAgent:o},...t}),a=e.getSession&&e.getSession();return a&&"ok"===a.status&&Aa(a,{status:"exited"}),this.endSession(),e.setSession(s),s}shouldSendDefaultPii(){const t=this.getClient(),e=t&&t.getOptions();return Boolean(e&&e.sendDefaultPii)}_sendSessionUpdate(){const{scope:t,client:e}=this.getStackTop(),n=t.getSession();n&&e&&e.captureSession&&e.captureSession(n)}_withClient(t){const{scope:e,client:n}=this.getStackTop();n&&t(n,e)}_callExtensionMethod(t,...e){const n=ja().__SENTRY__;if(n&&n.extensions&&"function"==typeof n.extensions[t])return n.extensions[t].apply(this,e);("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn(`Extension method ${t} couldn't be found, doing nothing.`)}}function ja(){return Zs.OW.__SENTRY__=Zs.OW.__SENTRY__||{extensions:{},hub:void 0},Zs.OW}function Ba(t){const e=ja(),n=Fa(e);return Ga(e,t),n}function Ma(){const t=ja();if(t.__SENTRY__&&t.__SENTRY__.acs){const e=t.__SENTRY__.acs.getCurrentHub();if(e)return e}return Ua(t)}function Ua(t=ja()){return za(t)&&!Fa(t).isOlderThan(4)||Ga(t,new Na),Fa(t)}function za(t){return!!(t&&t.__SENTRY__&&t.__SENTRY__.hub)}function Fa(t){return(0,Zs.BY)("hub",(()=>new Na),t)}function Ga(t,e){if(!t)return!1;return(t.__SENTRY__=t.__SENTRY__||{}).hub=e,!0}function Ha(t,e){return Ma().captureException(t,{captureContext:e})}function Va(t,e){Ma().setTag(t,e)}function Wa(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n\n ',"\n \n ',"\n \n ","\n \n '," ","\n \n "])),o[0],"".concat(e," (view in new window)"),r,e,o[1],"".concat(n," (view in new window)"),i,n,o[2])}():function(t){var e,n=hc.getState(),r="https://".concat(t,"/policies/terms-of-service.html"),i="https://".concat(t,"/policies/privacy-policy.html");return n.shopShop&&null!==(e=n.flags)&&void 0!==e&&e.split(",").includes("dynamic_terms")&&(r="https://terms.pscr.pt/legal/shop/".concat(n.shopShop,"/terms_of_service"),i="https://terms.pscr.pt/legal/shop/".concat(n.shopShop,"/privacy_policy")),V(sc||(sc=Qa(['*I agree to receive recurring automated marketing text messages\n (e.g. cart reminders) at the phone number provided. Consent is not a\n condition to purchase. Msg & data rates may apply. Msg frequency varies.\n Reply HELP for help and STOP to cancel. View our\n \n Terms of Service\n \n and\n \n Privacy Policy.\n '])),r,i)}(t)},Ic="engagement",Ac="impression",Rc="submit_email",Dc="MOBILE",Pc="Delay",$c="Exit",Lc="Arial",Nc="Times New Roman",jc="sms:",Bc="&body=",Mc="NEW_SMS_USERS",Uc="EXISTING_SMS_SUBSCRIBERS",zc="Desktop Popup",Fc="DESKTOP_BLOCK_POPUP",Gc="MOBILE_BLOCK_POPUP",Hc={ALL:"All",ALL_OUTSIDE_US:"All outside US",US:"US",CANADA:"Canada",US_AND_CANADA:"US & Canada",ALL_OUTSIDE_US_AND_CANADA:"All outside US and Canada",AUSTRALIA_AND_NEW_ZEALAND:"Australia and New Zealand"},Vc=function(t,e){return function(t){return[Hc.ALL,null,void 0].includes(t)}(e)||function(t,e){return e===Hc.US_AND_CANADA&&[Hc.US,"CA"].includes(t)}(t,e)||function(t,e){return e===t}(t,e)||function(t,e){return e===Hc.CANADA&&"CA"===t}(t,e)||function(t,e){return e===Hc.ALL_OUTSIDE_US&&t!==Hc.US}(t,e)||function(t,e){return e===Hc.ALL_OUTSIDE_US_AND_CANADA&&!["US","CA"].includes(t)}(t,e)||function(t,e){return e===Hc.AUSTRALIA_AND_NEW_ZEALAND&&["AU","NZ"].includes(t)}(t,e)},Wc="DOUBLE_OPT_IN",Yc="LINK_CLICK",qc="TWO_TOUCH",Zc="EMAIL",Xc="PHONE",Kc="RADIO",Jc="MONTH_AND_DAY",Qc="TEXT",tl="psValidateForm",el="ps-one-time-passcode-hidden-text",nl="ps-one-time-passcode-input",rl="You're already subscribed! Thanks for being part of the community.",il="You are now subscribed to text messages!",ol="ps-widget-custom-form__",sl=function(t,e,n){customElements.get(t)||customElements.define(t,e,n)},al=function(t){var e=t.key,n=t.value,r=t.questions;return(void 0===r?[]:r).find((function(t){return e in t&&t[e]===n}))},cl=function(t){var e,n,r=t.twoTouchEnabled&&t.popupType===Dc?qc:Wc,i=null==t||null===(e=t.pages)||void 0===e?void 0:e.flatMap((function(t){return null==t?void 0:t.questions})),o=al({questions:i,key:"type",value:Xc});return null!==(n=null==o?void 0:o.optInMethod)&&void 0!==n?n:r},ll=function(t){var e=cl(t);return e===qc||e===Yc},ul="Open Sans Condensed",pl={collection_attributes:["phone"],font:{desktop:"Roboto",mobile:"".concat(ul,":300")},background_style:"Color",button_radius:10,two_touch_enabled:!0};function dl(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 hl(t){for(var e=1;e0&&(r=!1,r=i.split(",").some((function(e){return t.includes(e)})));o&&o.length>0&&(r=!o.split(",").some((function(e){return t.includes(e)}))&&r);return r},Cl=function(t){var e=t.offsetWidth,n=getComputedStyle(t);return e+=parseInt(n.marginLeft,10)+parseInt(n.marginRight,10)},Ol=function(t){var e=t.offsetHeight,n=getComputedStyle(t);return e+=parseInt(n.marginTop,10)+parseInt(n.marginBottom,10)},Il=function(t){var e=document.getElementById(t);return e?{height:Ol(e),width:Cl(e)}:{}},Al=function(t,e,n){var r,i,o,s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,a=arguments.length>4&&void 0!==arguments[4]&&arguments[4],c="".concat(t,"=").concat(e);if(n||s){var l=new Date;l.setTime(l.getTime()+24*n*60*60*1e3+60*s*60*1e3),c+="; expires=".concat(l.toUTCString())}a&&(c+="; domain=".concat((r=window.location.hostname,i=r.split("."),o=r,i.length>2&&(o=["com","co","org","net"].includes(i[i.length-2])?i.slice(i.length-3).join("."):i.slice(i.length-2).join(".")),o))),c+="; path=/",document.cookie=c},Rl=function(t){for(var e="".concat(t,"="),n=window.parent.document.cookie.split(";"),r=0;r1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1e4,r=new AbortController,i=r.signal,o=setTimeout((function(){r.abort()}),n);return fetch(t,hl(hl({},e),{},{signal:i})).then((function(t){return clearTimeout(o),t}))},Pl=function(t,e,n,r){window.parent.postMessage({FrameHeight:t,FrameWidth:e,FramePosition:n,shouldStopScroll:r},"*")},$l={top:"auto",left:"".concat(10,"px"),bottom:"".concat(10,"px"),right:"auto"},Ll=function(t,e,n){var r,i=Il(t),o=i.width,s=void 0===o?160:o,a=i.height,c=void 0===a?60:a,l=Il(e),u=l.width,p=void 0===u?0:u,d=l.height,h=c||60,f=s||160,m=10+p/2+10;Pl("".concat(h+(10+(void 0===d?0:d)/2+10),"px"),"".concat(f+m,"px"),null!==(r=null==n?void 0:n(h,f))&&void 0!==r?r:$l)},Nl=function(t){Pl("100%","100%",{top:0,left:0,bottom:"auto",right:"auto"},t)},jl=function(){window.parent.postMessage({FrameDisplay:"block"},"*")},Bl=function(){window.parent.postMessage({FrameOpacity:"1"},"*")},Ml=function(){window.parent.postMessage({FrameDisplay:"none",FrameOpacity:0},"*")},Ul=function(t){var e;if(!hc.getState().isPreview)if("BODY"===(null===(e=document.activeElement)||void 0===e?void 0:e.tagName)){window.addEventListener("message",(function e(n){var r;"FocusedElementStored"===n.data&&(t(null),null===(r=n.target)||void 0===r||r.removeEventListener("message",e))})),window.parent.postMessage("GetFocusedElement","*")}else{var n,r;t(null!==(n=null===(r=document.activeElement)||void 0===r?void 0:r.id)&&void 0!==n?n:null)}},zl=function(t){var e=document.getElementById(t);e?e.focus():window.parent.postMessage("RestoreFocusedElement","*")},Fl=function(){var t;null===(t=document.getElementById(mc))||void 0===t||t.setAttribute("aria-hidden","true"),window.parent.postMessage("UnhideElementsBehindPopupFromScreenReader","*")},Gl=function(t,e,n,r,i){window.parent.postMessage({SetCookie:{name:t,status:e,expirationDays:n,expirationHours:r,allowSubdomains:i}},"*")},Hl=function(t,e,n){window.parent.postMessage({type:"POPUP_CLOSE",popupId:t,popupName:e,hard:n},"*")};function Vl(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 Wl(t){for(var e=1;e1&&void 0!==arguments[1]?arguments[1]:{};return t.map((function(t){var n=document.createElement("link");return Object.entries(Wl(Wl({},e),{},{href:t})).forEach((function(t){var e=Ja(t,2),r=e[0],i=e[1];n[r]=i})),n}))}((arguments.length>0&&void 0!==arguments[0]?arguments[0]:[]).filter((function(t){return!!t})),{as:"image",rel:"preload"});t.forEach((function(t){!document.head.querySelector('link[href="'.concat(null==t?void 0:t.href,'"]'))&&t&&document.head.appendChild(t)}))};function Kl(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 Jl(t){for(var e=1;e0}))||n[0]||null};var lu=function(){var t=e(i().mark((function t(e,n){var r,o,s,a;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=Ql(e,n),t.prev=1,t.next=4,fetch(r.toString());case 4:if((s=t.sent).ok){t.next=7;break}throw new Error("Fetch failed with status code ".concat(s.status));case 7:return t.next=9,s.json();case 9:return a=t.sent,o=a.popups,t.abrupt("return",ru(o,n));case 14:return t.prev=14,t.t0=t.catch(1),Ha(new TypeError("Failed to load popups",{cause:t.t0})),t.abrupt("return",[]);case 18:case"end":return t.stop()}}),t,null,[[1,14]])})));return function(e,n){return t.apply(this,arguments)}}(),uu="fade-in",pu="fade-out",du="a[href], area[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), button:not([disabled]), iframe, object, embed, *[tabindex], *[contenteditable]",hu=function(t){"Enter"!==t.key&&" "!==t.key||(t.preventDefault(),t.target.click())},fu=function(t){for(var e=0;e{const n=e();if(n){const e=n.getIntegration(Ru);if(e){const r=n.getClient(),i=r?r.getOptions():{},o=function(t={},e={}){return{allowUrls:[...t.allowUrls||[],...e.allowUrls||[]],denyUrls:[...t.denyUrls||[],...e.denyUrls||[]],ignoreErrors:[...t.ignoreErrors||[],...e.ignoreErrors||[],...t.disableErrorDefaults?[]:Iu],ignoreTransactions:[...t.ignoreTransactions||[],...e.ignoreTransactions||[],...t.disableTransactionDefaults?[]:Au],ignoreInternal:void 0===t.ignoreInternal||t.ignoreInternal}}(e._options,i);return function(t,e){if(e.ignoreInternal&&function(t){try{return"SentryError"===t.exception.values[0].type}catch(t){}return!1}(t))return("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn(`Event dropped due to being internal Sentry Error.\nEvent: ${fa(t)}`),!0;if(function(t,e){if(t.type||!e||!e.length)return!1;return function(t){if(t.message)return[t.message];if(t.exception){const{values:e}=t.exception;try{const{type:t="",value:n=""}=e&&e[e.length-1]||{};return[`${n}`,`${t}: ${n}`]}catch(e){return("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.error(`Cannot extract message for event ${fa(t)}`),[]}}return[]}(t).some((t=>na(t,e)))}(t,e.ignoreErrors))return("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn(`Event dropped due to being matched by \`ignoreErrors\` option.\nEvent: ${fa(t)}`),!0;if(function(t,e){if("transaction"!==t.type||!e||!e.length)return!1;const n=t.transaction;return!!n&&na(n,e)}(t,e.ignoreTransactions))return("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn(`Event dropped due to being matched by \`ignoreTransactions\` option.\nEvent: ${fa(t)}`),!0;if(function(t,e){if(!e||!e.length)return!1;const n=Du(t);return!!n&&na(n,e)}(t,e.denyUrls))return("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn(`Event dropped due to being matched by \`denyUrls\` option.\nEvent: ${fa(t)}.\nUrl: ${Du(t)}`),!0;if(!function(t,e){if(!e||!e.length)return!0;const n=Du(t);return!n||na(n,e)}(t,e.allowUrls))return("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn(`Event dropped due to not being matched by \`allowUrls\` option.\nEvent: ${fa(t)}.\nUrl: ${Du(t)}`),!0;return!1}(t,o)?null:t}}return t};n.id=this.name,t(n)}}function Du(t){try{let e;try{e=t.exception.values[0].stacktrace.frames}catch(t){}return e?function(t=[]){for(let e=t.length-1;e>=0;e--){const n=t[e];if(n&&""!==n.filename&&"[native code]"!==n.filename)return n.filename||null}return null}(e):null}catch(e){return("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.error(`Cannot extract url for event ${fa(t)}`),null}}let Pu;Ru.__initStatic();class $u{constructor(){$u.prototype.__init.call(this)}static __initStatic(){this.id="FunctionToString"}__init(){this.name=$u.id}setupOnce(){Pu=Function.prototype.toString;try{Function.prototype.toString=function(...t){const e=sa(this)||this;return Pu.apply(e,t)}}catch(t){}}}$u.__initStatic();const Lu=[];function Nu(t){const e=t.defaultIntegrations||[],n=t.integrations;let r;e.forEach((t=>{t.isDefaultInstance=!0})),r=Array.isArray(n)?[...e,...n]:"function"==typeof n?ba(n(e)):e;const i=function(t){const e={};return t.forEach((t=>{const{name:n}=t,r=e[n];r&&!r.isDefaultInstance&&t.isDefaultInstance||(e[n]=t)})),Object.keys(e).map((t=>e[t]))}(r),o=function(t,e){for(let n=0;n"Debug"===t.name));if(-1!==o){const[t]=i.splice(o,1);i.push(t)}return i}function ju(t,e){e[t.name]=t,-1===Lu.indexOf(t.name)&&(t.setupOnce(Pa,Ma),Lu.push(t.name),("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.log(`Integration installed: ${t.name}`))}const Bu=/\(error: (.*)\)/;function Mu(...t){const e=t.sort(((t,e)=>t[0]-e[0])).map((t=>t[1]));return(t,n=0)=>{const r=[],i=t.split("\n");for(let t=n;t1024)continue;const o=Bu.test(n)?n.replace(Bu,"$1"):n;if(!o.match(/\S*Error: /)){for(const t of e){const e=t(o);if(e){r.push(e);break}}if(r.length>=50)break}}return function(t){if(!t.length)return[];const e=t.slice(0,50),n=e[e.length-1].function;n&&/sentryWrapped/.test(n)&&e.pop();e.reverse();const r=e[e.length-1].function;r&&/captureMessage|captureException/.test(r)&&e.pop();return e.map((t=>({...t,filename:t.filename||e[e.length-1].filename,function:t.function||"?"})))}(r)}}const Uu="";function zu(t){try{return t&&"function"==typeof t&&t.name||Uu}catch(t){return Uu}}const Fu=(0,Zs.VZ)();function Gu(){if(!("fetch"in Fu))return!1;try{return new Headers,new Request("http://www.example.com"),new Response,!0}catch(t){return!1}}function Hu(t){return t&&/^function fetch\(\)\s+\{\s+\[native code\]\s+\}$/.test(t.toString())}function Vu(){if(!Gu())return!1;if(Hu(Fu.fetch))return!0;let t=!1;const e=Fu.document;if(e&&"function"==typeof e.createElement)try{const n=e.createElement("iframe");n.hidden=!0,e.head.appendChild(n),n.contentWindow&&n.contentWindow.fetch&&(t=Hu(n.contentWindow.fetch)),e.head.removeChild(n)}catch(t){("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",t)}return t}const Wu=(0,Zs.VZ)();const Yu=(0,Zs.VZ)(),qu="__sentry_xhr_v2__",Zu={},Xu={};function Ku(t){if(!Xu[t])switch(Xu[t]=!0,t){case"console":!function(){if(!("console"in Yu))return;_a.forEach((function(t){t in Yu.console&&ra(Yu.console,t,(function(e){return function(...n){Qu("console",{args:n,level:t}),e&&e.apply(Yu.console,n)}}))}))}();break;case"dom":!function(){if(!("document"in Yu))return;const t=Qu.bind(null,"dom"),e=sp(t,!0);Yu.document.addEventListener("click",e,!1),Yu.document.addEventListener("keypress",e,!1),["EventTarget","Node"].forEach((e=>{const n=Yu[e]&&Yu[e].prototype;n&&n.hasOwnProperty&&n.hasOwnProperty("addEventListener")&&(ra(n,"addEventListener",(function(e){return function(n,r,i){if("click"===n||"keypress"==n)try{const r=this,o=r.__sentry_instrumentation_handlers__=r.__sentry_instrumentation_handlers__||{},s=o[n]=o[n]||{refCount:0};if(!s.handler){const r=sp(t);s.handler=r,e.call(this,n,r,i)}s.refCount++}catch(t){}return e.call(this,n,r,i)}})),ra(n,"removeEventListener",(function(t){return function(e,n,r){if("click"===e||"keypress"==e)try{const n=this,i=n.__sentry_instrumentation_handlers__||{},o=i[e];o&&(o.refCount--,o.refCount<=0&&(t.call(this,e,o.handler,r),o.handler=void 0,delete i[e]),0===Object.keys(i).length&&delete n.__sentry_instrumentation_handlers__)}catch(t){}return t.call(this,e,n,r)}})))}))}();break;case"xhr":!function(){if(!("XMLHttpRequest"in Yu))return;const t=XMLHttpRequest.prototype;ra(t,"open",(function(t){return function(...e){const n=e[1],r=this[qu]={method:Gs(e[0])?e[0].toUpperCase():e[0],url:e[1],request_headers:{}};Gs(n)&&"POST"===r.method&&n.match(/sentry_key/)&&(this.__sentry_own_request__=!0);const i=()=>{const t=this[qu];if(t&&4===this.readyState){try{t.status_code=this.status}catch(t){}Qu("xhr",{args:e,endTimestamp:Date.now(),startTimestamp:Date.now(),xhr:this})}};return"onreadystatechange"in this&&"function"==typeof this.onreadystatechange?ra(this,"onreadystatechange",(function(t){return function(...e){return i(),t.apply(this,e)}})):this.addEventListener("readystatechange",i),ra(this,"setRequestHeader",(function(t){return function(...e){const[n,r]=e,i=this[qu];return i&&(i.request_headers[n.toLowerCase()]=r),t.apply(this,e)}})),t.apply(this,e)}})),ra(t,"send",(function(t){return function(...e){const n=this[qu];return n&&void 0!==e[0]&&(n.body=e[0]),Qu("xhr",{args:e,startTimestamp:Date.now(),xhr:this}),t.apply(this,e)}}))}();break;case"fetch":!function(){if(!Vu())return;ra(Yu,"fetch",(function(t){return function(...e){const{method:n,url:r}=function(t){if(0===t.length)return{method:"GET",url:""};if(2===t.length){const[e,n]=t;return{url:ep(e),method:tp(n,"method")?String(n.method).toUpperCase():"GET"}}const e=t[0];return{url:ep(e),method:tp(e,"method")?String(e.method).toUpperCase():"GET"}}(e),i={args:e,fetchData:{method:n,url:r},startTimestamp:Date.now()};return Qu("fetch",{...i}),t.apply(Yu,e).then((t=>(Qu("fetch",{...i,endTimestamp:Date.now(),response:t}),t)),(t=>{throw Qu("fetch",{...i,endTimestamp:Date.now(),error:t}),t}))}}))}();break;case"history":!function(){if(!function(){const t=Wu.chrome,e=t&&t.app&&t.app.runtime,n="history"in Wu&&!!Wu.history.pushState&&!!Wu.history.replaceState;return!e&&n}())return;const t=Yu.onpopstate;function e(t){return function(...e){const n=e.length>2?e[2]:void 0;if(n){const t=np,e=String(n);np=e,Qu("history",{from:t,to:e})}return t.apply(this,e)}}Yu.onpopstate=function(...e){const n=Yu.location.href,r=np;if(np=n,Qu("history",{from:r,to:n}),t)try{return t.apply(this,e)}catch(t){}},ra(Yu.history,"pushState",e),ra(Yu.history,"replaceState",e)}();break;case"error":ap=Yu.onerror,Yu.onerror=function(t,e,n,r,i){return Qu("error",{column:r,error:i,line:n,msg:t,url:e}),!(!ap||ap.__SENTRY_LOADER__)&&ap.apply(this,arguments)},Yu.onerror.__SENTRY_INSTRUMENTED__=!0;break;case"unhandledrejection":cp=Yu.onunhandledrejection,Yu.onunhandledrejection=function(t){return Qu("unhandledrejection",t),!(cp&&!cp.__SENTRY_LOADER__)||cp.apply(this,arguments)},Yu.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0;break;default:return void(("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn("unknown instrumentation type:",t))}}function Ju(t,e){Zu[t]=Zu[t]||[],Zu[t].push(e),Ku(t)}function Qu(t,e){if(t&&Zu[t])for(const n of Zu[t]||[])try{n(e)}catch(e){("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.error(`Error while triggering instrumentation handler.\nType: ${t}\nName: ${zu(n)}\nError:`,e)}}function tp(t,e){return!!t&&"object"==typeof t&&!!t[e]}function ep(t){return"string"==typeof t?t:t?tp(t,"url")?t.url:t.toString?t.toString():"":""}let np;const rp=1e3;let ip,op;function sp(t,e=!1){return n=>{if(!n||op===n)return;if(function(t){if("keypress"!==t.type)return!1;try{const e=t.target;if(!e||!e.tagName)return!0;if("INPUT"===e.tagName||"TEXTAREA"===e.tagName||e.isContentEditable)return!1}catch(t){}return!0}(n))return;const r="keypress"===n.type?"input":n.type;(void 0===ip||function(t,e){if(!t)return!0;if(t.type!==e.type)return!0;try{if(t.target!==e.target)return!0}catch(t){}return!1}(op,n))&&(t({event:n,name:r,global:e}),op=n),clearTimeout(ip),ip=Yu.setTimeout((()=>{ip=void 0}),rp)}}let ap=null;let cp=null;const lp=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;function up(t,e=!1){const{host:n,path:r,pass:i,port:o,projectId:s,protocol:a,publicKey:c}=t;return`${a}://${c}${e&&i?`:${i}`:""}@${n}${o?`:${o}`:""}/${r?`${r}/`:r}${s}`}function pp(t){return{protocol:t.protocol,publicKey:t.publicKey||"",pass:t.pass||"",host:t.host,port:t.port||"",path:t.path||"",projectId:t.projectId}}function dp(t){const e="string"==typeof t?function(t){const e=lp.exec(t);if(!e)return void console.error(`Invalid Sentry Dsn: ${t}`);const[n,r,i="",o,s="",a]=e.slice(1);let c="",l=a;const u=l.split("/");if(u.length>1&&(c=u.slice(0,-1).join("/"),l=u.pop()),l){const t=l.match(/^\d+/);t&&(l=t[0])}return pp({host:o,pass:i,path:c,projectId:l,port:s,protocol:n,publicKey:r})}(t):pp(t);if(e&&function(t){if("undefined"!=typeof __SENTRY_DEBUG__&&!__SENTRY_DEBUG__)return!0;const{port:e,projectId:n,protocol:r}=t;return!(["protocol","publicKey","host","projectId"].find((e=>!t[e]&&(xa.error(`Invalid Sentry Dsn: ${e} missing`),!0)))||(n.match(/^\d+$/)?function(t){return"http"===t||"https"===t}(r)?e&&isNaN(parseInt(e,10))&&(xa.error(`Invalid Sentry Dsn: Invalid port ${e}`),1):(xa.error(`Invalid Sentry Dsn: Invalid protocol ${r}`),1):(xa.error(`Invalid Sentry Dsn: Invalid projectId ${n}`),1)))}(e))return e}function hp(t,e=100,n=1/0){try{return mp("",t,e,n)}catch(t){return{ERROR:`**non-serializable** (${t})`}}}function fp(t,e=3,n=102400){const r=hp(t,e);return i=r,function(t){return~-encodeURI(t).split(/%..|./).length}(JSON.stringify(i))>n?fp(t,e-1,n):r;var i}function mp(t,e,r=1/0,i=1/0,o=function(){const t="function"==typeof WeakSet,e=t?new WeakSet:[];return[function(n){if(t)return!!e.has(n)||(e.add(n),!1);for(let t=0;t=i){d[t]="[MaxProperties ~]";break}const e=f[t];d[t]=mp(t,e,u-1,i,o),h++}return a(e),d}function gp(t,e=[]){return[t,e]}function vp(t,e){const[n,r]=t;return[n,[...r,e]]}function bp(t,e){const n=t[1];for(const t of n){if(e(t,t[0].type))return!0}return!1}function yp(t,e){return(e||new TextEncoder).encode(t)}function _p(t,e){const[n,r]=t;let i=JSON.stringify(n);function o(t){"string"==typeof i?i="string"==typeof t?i+t:[yp(i,e),t]:i.push("string"==typeof t?yp(t,e):t)}for(const t of r){const[e,n]=t;if(o(`\n${JSON.stringify(e)}\n`),"string"==typeof n||n instanceof Uint8Array)o(n);else{let t;try{t=JSON.stringify(n)}catch(e){t=JSON.stringify(hp(n))}o(t)}}return"string"==typeof i?i:function(t){const e=t.reduce(((t,e)=>t+e.length),0),n=new Uint8Array(e);let r=0;for(const e of t)n.set(e,r),r+=e.length;return n}(i)}function wp(t,e){const n="string"==typeof t.data?yp(t.data,e):t.data;return[ua({type:"attachment",length:n.length,filename:t.filename,content_type:t.contentType,attachment_type:t.attachmentType}),n]}const kp={session:"session",sessions:"session",attachment:"attachment",transaction:"transaction",event:"error",client_report:"internal",user_report:"default",profile:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor"};function xp(t){return kp[t]}function Sp(t){if(!t||!t.sdk)return;const{name:e,version:n}=t.sdk;return{name:e,version:n}}class Ep extends Error{constructor(t,e="warn"){super(t),this.message=t,this.name=new.target.prototype.constructor.name,Object.setPrototypeOf(this,new.target.prototype),this.logLevel=e}}function Tp(t){const e=t.protocol?`${t.protocol}:`:"",n=t.port?`:${t.port}`:"";return`${e}//${t.host}${n}${t.path?`/${t.path}`:""}/api/`}function Cp(t,e){return n={sentry_key:t.publicKey,sentry_version:"7",...e&&{sentry_client:`${e.name}/${e.version}`}},Object.keys(n).map((t=>`${encodeURIComponent(t)}=${encodeURIComponent(n[t])}`)).join("&");var n}function Op(t,e={}){const n="string"==typeof e?e:e.tunnel,r="string"!=typeof e&&e._metadata?e._metadata.sdk:void 0;return n||`${function(t){return`${Tp(t)}${t.projectId}/envelope/`}(t)}?${Cp(t,r)}`}function Ip(t,e,n,r){const i=Sp(n),o=t.type&&"replay_event"!==t.type?t.type:"event";!function(t,e){e&&(t.sdk=t.sdk||{},t.sdk.name=t.sdk.name||e.name,t.sdk.version=t.sdk.version||e.version,t.sdk.integrations=[...t.sdk.integrations||[],...e.integrations||[]],t.sdk.packages=[...t.sdk.packages||[],...e.packages||[]])}(t,n&&n.sdk);const s=function(t,e,n,r){const i=t.sdkProcessingMetadata&&t.sdkProcessingMetadata.dynamicSamplingContext;return{event_id:t.event_id,sent_at:(new Date).toISOString(),...e&&{sdk:e},...!!n&&{dsn:up(r)},...i&&{trace:ua({...i})}}}(t,i,r,e);delete t.sdkProcessingMetadata;return gp(s,[[{type:o},t]])}function Ap(t,e,n,r){const{normalizeDepth:i=3,normalizeMaxBreadth:o=1e3}=t,s={...e,event_id:e.event_id||n.event_id||da(),timestamp:e.timestamp||(0,ya.lu)()},a=n.integrations||t.integrations.map((t=>t.name));!function(t,e){const{environment:n,release:r,dist:i,maxValueLength:o=250}=e;"environment"in t||(t.environment="environment"in e?n:Sa);void 0===t.release&&void 0!==r&&(t.release=r);void 0===t.dist&&void 0!==i&&(t.dist=i);t.message&&(t.message=Qs(t.message,o));const s=t.exception&&t.exception.values&&t.exception.values[0];s&&s.value&&(s.value=Qs(s.value,o));const a=t.request;a&&a.url&&(a.url=Qs(a.url,o))}(s,t),function(t,e){e.length>0&&(t.sdk=t.sdk||{},t.sdk.integrations=[...t.sdk.integrations||[],...e])}(s,a),void 0===e.type&&function(t,e){const n=Zs.OW._sentryDebugIds;if(!n)return;let r;const i=Rp.get(e);i?r=i:(r=new Map,Rp.set(e,r));const o=Object.keys(n).reduce(((t,i)=>{let o;const s=r.get(i);s?o=s:(o=e(i),r.set(i,o));for(let e=o.length-1;e>=0;e--){const r=o[e];if(r.filename){t[r.filename]=n[i];break}}return t}),{});try{t.exception.values.forEach((t=>{t.stacktrace.frames.forEach((t=>{t.filename&&(t.debug_id=o[t.filename])}))}))}catch(t){}}(s,t.stackParser);let c=r;n.captureContext&&(c=Ra.clone(c).update(n.captureContext));let l=Ta(s);if(c){if(c.getAttachments){const t=[...n.attachments||[],...c.getAttachments()];t.length&&(n.attachments=t)}l=c.applyToEvent(s,n)}return l.then((t=>(t&&function(t){const e={};try{t.exception.values.forEach((t=>{t.stacktrace.frames.forEach((t=>{t.debug_id&&(t.abs_path?e[t.abs_path]=t.debug_id:t.filename&&(e[t.filename]=t.debug_id),delete t.debug_id)}))}))}catch(t){}if(0===Object.keys(e).length)return;t.debug_meta=t.debug_meta||{},t.debug_meta.images=t.debug_meta.images||[];const n=t.debug_meta.images;Object.keys(e).forEach((t=>{n.push({type:"sourcemap",code_file:t,debug_id:e[t]})}))}(t),"number"==typeof i&&i>0?function(t,e,n){if(!t)return null;const r={...t,...t.breadcrumbs&&{breadcrumbs:t.breadcrumbs.map((t=>({...t,...t.data&&{data:hp(t.data,e,n)}})))},...t.user&&{user:hp(t.user,e,n)},...t.contexts&&{contexts:hp(t.contexts,e,n)},...t.extra&&{extra:hp(t.extra,e,n)}};t.contexts&&t.contexts.trace&&r.contexts&&(r.contexts.trace=t.contexts.trace,t.contexts.trace.data&&(r.contexts.trace.data=hp(t.contexts.trace.data,e,n)));t.spans&&(r.spans=t.spans.map((t=>(t.data&&(t.data=hp(t.data,e,n)),t))));return r}(t,i,o):t)))}const Rp=new WeakMap;const Dp="Not capturing exception because it's already been captured.";class Pp{__init(){this._integrations={}}__init2(){this._integrationsInitialized=!1}__init3(){this._numProcessing=0}__init4(){this._outcomes={}}__init5(){this._hooks={}}constructor(t){if(Pp.prototype.__init.call(this),Pp.prototype.__init2.call(this),Pp.prototype.__init3.call(this),Pp.prototype.__init4.call(this),Pp.prototype.__init5.call(this),this._options=t,t.dsn?this._dsn=dp(t.dsn):("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn("No DSN provided, client will not do anything."),this._dsn){const e=Op(this._dsn,t);this._transport=t.transport({recordDroppedEvent:this.recordDroppedEvent.bind(this),...t.transportOptions,url:e})}}captureException(t,e,n){if(va(t))return void(("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.log(Dp));let r=e&&e.event_id;return this._process(this.eventFromException(t,e).then((t=>this._captureEvent(t,e,n))).then((t=>{r=t}))),r}captureMessage(t,e,n,r){let i=n&&n.event_id;const o=Hs(t)?this.eventFromMessage(String(t),e,n):this.eventFromException(t,n);return this._process(o.then((t=>this._captureEvent(t,n,r))).then((t=>{i=t}))),i}captureEvent(t,e,n){if(e&&e.originalException&&va(e.originalException))return void(("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.log(Dp));let r=e&&e.event_id;return this._process(this._captureEvent(t,e,n).then((t=>{r=t}))),r}captureSession(t){this._isEnabled()?"string"!=typeof t.release?("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn("Discarded session because of missing or non-string release"):(this.sendSession(t),Aa(t,{init:!1})):("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn("SDK not enabled, will not capture session.")}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}flush(t){const e=this._transport;return e?this._isClientDoneProcessing(t).then((n=>e.flush(t).then((t=>n&&t)))):Ta(!0)}close(t){return this.flush(t).then((t=>(this.getOptions().enabled=!1,t)))}setupIntegrations(){this._isEnabled()&&!this._integrationsInitialized&&(this._integrations=function(t){const e={};return t.forEach((t=>{t&&ju(t,e)})),e}(this._options.integrations),this._integrationsInitialized=!0)}getIntegrationById(t){return this._integrations[t]}getIntegration(t){try{return this._integrations[t.id]||null}catch(e){return("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn(`Cannot retrieve integration ${t.id} from the current Client`),null}}addIntegration(t){ju(t,this._integrations)}sendEvent(t,e={}){if(this._dsn){let n=Ip(t,this._dsn,this._options._metadata,this._options.tunnel);for(const t of e.attachments||[])n=vp(n,wp(t,this._options.transportOptions&&this._options.transportOptions.textEncoder));const r=this._sendEnvelope(n);r&&r.then((e=>this.emit("afterSendEvent",t,e)),null)}}sendSession(t){if(this._dsn){const e=function(t,e,n,r){const i=Sp(n);return gp({sent_at:(new Date).toISOString(),...i&&{sdk:i},...!!r&&{dsn:up(e)}},["aggregates"in t?[{type:"sessions"},t]:[{type:"session"},t.toJSON()]])}(t,this._dsn,this._options._metadata,this._options.tunnel);this._sendEnvelope(e)}}recordDroppedEvent(t,e,n){if(this._options.sendClientReports){const n=`${t}:${e}`;("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.log(`Adding outcome: "${n}"`),this._outcomes[n]=this._outcomes[n]+1||1}}on(t,e){this._hooks[t]||(this._hooks[t]=[]),this._hooks[t].push(e)}emit(t,...e){this._hooks[t]&&this._hooks[t].forEach((t=>t(...e)))}_updateSessionFromEvent(t,e){let n=!1,r=!1;const i=e.exception&&e.exception.values;if(i){r=!0;for(const t of i){const e=t.mechanism;if(e&&!1===e.handled){n=!0;break}}}const o="ok"===t.status;(o&&0===t.errors||o&&n)&&(Aa(t,{...n&&{status:"crashed"},errors:t.errors||Number(r||n)}),this.captureSession(t))}_isClientDoneProcessing(t){return new Oa((e=>{let n=0;const r=setInterval((()=>{0==this._numProcessing?(clearInterval(r),e(!0)):(n+=1,t&&n>=t&&(clearInterval(r),e(!1)))}),1)}))}_isEnabled(){return!1!==this.getOptions().enabled&&void 0!==this._dsn}_prepareEvent(t,e,n){const r=this.getOptions(),i=Object.keys(this._integrations);return!e.integrations&&i.length>0&&(e.integrations=i),Ap(r,t,e,n).then((t=>{if(null===t)return t;const{propagationContext:e}=t.sdkProcessingMetadata||{};if(!(t.contexts&&t.contexts.trace)&&e){const{traceId:r,spanId:i,parentSpanId:o,dsc:s}=e;t.contexts={trace:{trace_id:r,span_id:i,parent_span_id:o},...t.contexts};const a=s||function(t,e,n){const r=e.getOptions(),{publicKey:i}=e.getDsn()||{},{segment:o}=n&&n.getUser()||{},s=ua({environment:r.environment||Sa,release:r.release,user_segment:o,public_key:i,trace_id:t});return e.emit&&e.emit("createDsc",s),s}(r,this,n);t.sdkProcessingMetadata={dynamicSamplingContext:a,...t.sdkProcessingMetadata}}return t}))}_captureEvent(t,e={},n){return this._processEvent(t,e,n).then((t=>t.event_id),(t=>{if("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__){const e=t;"log"===e.logLevel?xa.log(e.message):xa.warn(e)}}))}_processEvent(t,e,n){const r=this.getOptions(),{sampleRate:i}=r;if(!this._isEnabled())return Ca(new Ep("SDK not enabled, will not capture event.","log"));const o=Lp(t),s=$p(t),a=t.type||"error",c=`before send for type \`${a}\``;if(s&&"number"==typeof i&&Math.random()>i)return this.recordDroppedEvent("sample_rate","error",t),Ca(new Ep(`Discarding event because it's not included in the random sample (sampling rate = ${i})`,"log"));const l="replay_event"===a?"replay":a;return this._prepareEvent(t,e,n).then((n=>{if(null===n)throw this.recordDroppedEvent("event_processor",l,t),new Ep("An event processor returned `null`, will not send event.","log");if(e.data&&!0===e.data.__sentry__)return n;const i=function(t,e,n){const{beforeSend:r,beforeSendTransaction:i}=t;if($p(e)&&r)return r(e,n);if(Lp(e)&&i)return i(e,n);return e}(r,n,e);return function(t,e){const n=`${e} must return \`null\` or a valid event.`;if(Ys(t))return t.then((t=>{if(!Vs(t)&&null!==t)throw new Ep(n);return t}),(t=>{throw new Ep(`${e} rejected with ${t}`)}));if(!Vs(t)&&null!==t)throw new Ep(n);return t}(i,c)})).then((r=>{if(null===r)throw this.recordDroppedEvent("before_send",l,t),new Ep(`${c} returned \`null\`, will not send event.`,"log");const i=n&&n.getSession();!o&&i&&this._updateSessionFromEvent(i,r);const s=r.transaction_info;if(o&&s&&r.transaction!==t.transaction){const t="custom";r.transaction_info={...s,source:t}}return this.sendEvent(r,e),r})).then(null,(t=>{if(t instanceof Ep)throw t;throw this.captureException(t,{data:{__sentry__:!0},originalException:t}),new Ep(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.\nReason: ${t}`)}))}_process(t){this._numProcessing++,t.then((t=>(this._numProcessing--,t)),(t=>(this._numProcessing--,t)))}_sendEnvelope(t){if(this._transport&&this._dsn)return this.emit("beforeEnvelope",t),this._transport.send(t).then(null,(t=>{("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.error("Error while sending event:",t)}));("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.error("Transport disabled")}_clearOutcomes(){const t=this._outcomes;return this._outcomes={},Object.keys(t).map((e=>{const[n,r]=e.split(":");return{reason:n,category:r,quantity:t[e]}}))}}function $p(t){return void 0===t.type}function Lp(t){return"transaction"===t.type}const Np="7.59.2";var jp=n(341);function Bp(t,e){const n=Up(t,e),r={type:e&&e.name,value:Fp(e)};return n.length&&(r.stacktrace={frames:n}),void 0===r.type&&""===r.value&&(r.value="Unrecoverable error caught"),r}function Mp(t,e){return{exception:{values:[Bp(t,e)]}}}function Up(t,e){const n=e.stacktrace||e.stack||"",r=function(t){if(t){if("number"==typeof t.framesToPop)return t.framesToPop;if(zp.test(t.message))return 1}return 0}(e);try{return t(n,r)}catch(t){}return[]}const zp=/Minified React error #\d+;/i;function Fp(t){const e=t&&t.message;return e?e.error&&"string"==typeof e.error.message?e.error.message:e:"No error message"}function Gp(t,e,n,r,i){let o;if(zs(e)&&e.error){return Mp(t,e.error)}if(Fs(e)||Us(e,"DOMException")){const i=e;if("stack"in e)o=Mp(t,e);else{const e=i.name||(Fs(i)?"DOMError":"DOMException"),s=i.message?`${e}: ${i.message}`:e;o=Hp(t,s,n,r),ma(o,s)}return"code"in i&&(o.tags={...o.tags,"DOMException.code":`${i.code}`}),o}if(Ms(e))return Mp(t,e);if(Vs(e)||Ws(e)){return o=function(t,e,n,r){const i=Ma().getClient(),o=i&&i.getOptions().normalizeDepth,s={exception:{values:[{type:Ws(e)?e.constructor.name:r?"UnhandledRejection":"Error",value:Vp(e,{isUnhandledRejection:r})}]},extra:{__serialized__:fp(e,o)}};if(n){const e=Up(t,n);e.length&&(s.exception.values[0].stacktrace={frames:e})}return s}(t,e,n,i),ga(o,{synthetic:!0}),o}return o=Hp(t,e,n,r),ma(o,`${e}`,void 0),ga(o,{synthetic:!0}),o}function Hp(t,e,n,r){const i={message:e};if(r&&n){const r=Up(t,n);r.length&&(i.exception={values:[{value:e,stacktrace:{frames:r}}]})}return i}function Vp(t,{isUnhandledRejection:e}){const n=function(t,e=40){const n=Object.keys(aa(t));if(n.sort(),!n.length)return"[object has no keys]";if(n[0].length>=e)return Qs(n[0],e);for(let t=n.length;t>0;t--){const r=n.slice(0,t).join(", ");if(!(r.length>e))return t===n.length?r:Qs(r,e)}return""}(t),r=e?"promise rejection":"exception";if(zs(t))return`Event \`ErrorEvent\` captured as ${r} with message \`${t.message}\``;if(Ws(t)){return`Event \`${function(t){try{const e=Object.getPrototypeOf(t);return e?e.constructor.name:void 0}catch(t){}}(t)}\` (type=${t.type}) captured as ${r}`}return`Object captured as ${r} with keys: ${n}`}const Wp=Zs.OW;let Yp=0;function qp(){return Yp>0}function Zp(t,e={},n){if("function"!=typeof t)return t;try{const e=t.__sentry_wrapped__;if(e)return e;if(sa(t))return t}catch(e){return t}const r=function(){const r=Array.prototype.slice.call(arguments);try{n&&"function"==typeof n&&n.apply(this,arguments);const i=r.map((t=>Zp(t,e)));return t.apply(this,i)}catch(t){throw Yp++,setTimeout((()=>{Yp--})),i=n=>{n.addEventProcessor((t=>(e.mechanism&&(ma(t,void 0,void 0),ga(t,e.mechanism)),t.extra={...t.extra,arguments:r},t))),Ha(t)},Ma().withScope(i),t}var i};try{for(const e in t)Object.prototype.hasOwnProperty.call(t,e)&&(r[e]=t[e])}catch(t){}oa(r,t),ia(t,"__sentry_wrapped__",r);try{Object.getOwnPropertyDescriptor(r,"name").configurable&&Object.defineProperty(r,"name",{get(){return t.name}})}catch(t){}return r}const Xp=["fatal","error","warning","log","info","debug"];function Kp(t){return"warn"===t?"warning":Xp.includes(t)?t:"log"}function Jp(t){if(!t)return{};const e=t.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!e)return{};const n=e[6]||"",r=e[8]||"";return{host:e[4],path:e[5],protocol:e[2],search:n,hash:r,relative:e[5]+n+r}}const Qp=1024,td="Breadcrumbs";class ed{static __initStatic(){this.id=td}__init(){this.name=ed.id}constructor(t){ed.prototype.__init.call(this),this.options={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...t}}setupOnce(){this.options.console&&Ju("console",nd),this.options.dom&&Ju("dom",function(t){function e(e){let n,r="object"==typeof t?t.serializeAttribute:void 0,i="object"==typeof t&&"number"==typeof t.maxStringLength?t.maxStringLength:void 0;i&&i>Qp&&(("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn(`\`dom.maxStringLength\` cannot exceed 1024, but a value of ${i} was configured. Sentry will use 1024 instead.`),i=Qp),"string"==typeof r&&(r=[r]);try{const t=e.event;n=function(t){return!!t&&!!t.target}(t)?Ks(t.target,{keyAttrs:r,maxStringLength:i}):Ks(t,{keyAttrs:r,maxStringLength:i})}catch(t){n=""}0!==n.length&&Ma().addBreadcrumb({category:`ui.${e.name}`,message:n},{event:e.event,name:e.name,global:e.global})}return e}(this.options.dom)),this.options.xhr&&Ju("xhr",rd),this.options.fetch&&Ju("fetch",id),this.options.history&&Ju("history",od)}addSentryBreadcrumb(t){this.options.sentry&&Ma().addBreadcrumb({category:"sentry."+("transaction"===t.type?"transaction":"event"),event_id:t.event_id,level:t.level,message:fa(t)},{event:t})}}function nd(t){for(let e=0;e{"hidden"===Wp.document.visibilityState&&this._flushOutcomes()}))}eventFromException(t,e){return function(t,e,n,r){const i=Gp(t,e,n&&n.syntheticException||void 0,r);return ga(i),i.level="error",n&&n.event_id&&(i.event_id=n.event_id),Ta(i)}(this._options.stackParser,t,e,this._options.attachStacktrace)}eventFromMessage(t,e="info",n){return function(t,e,n="info",r,i){const o=Hp(t,e,r&&r.syntheticException||void 0,i);return o.level=n,r&&r.event_id&&(o.event_id=r.event_id),Ta(o)}(this._options.stackParser,t,e,n,this._options.attachStacktrace)}sendEvent(t,e){const n=this.getIntegrationById(td);n&&n.addSentryBreadcrumb&&n.addSentryBreadcrumb(t),super.sendEvent(t,e)}captureUserFeedback(t){if(!this._isEnabled())return void(("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn("SDK not enabled, will not capture user feedback."));const e=function(t,{metadata:e,tunnel:n,dsn:r}){const i={event_id:t.event_id,sent_at:(new Date).toISOString(),...e&&e.sdk&&{sdk:{name:e.sdk.name,version:e.sdk.version}},...!!n&&!!r&&{dsn:up(r)}},o=function(t){return[{type:"user_report"},t]}(t);return gp(i,[o])}(t,{metadata:this.getSdkMetadata(),dsn:this.getDsn(),tunnel:this.getOptions().tunnel});this._sendEnvelope(e)}_prepareEvent(t,e,n){return t.platform=t.platform||"javascript",super._prepareEvent(t,e,n)}_flushOutcomes(){const t=this._clearOutcomes();if(0===t.length)return void(("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.log("No outcomes to send"));if(!this._dsn)return void(("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.log("No dsn provided, will not send outcomes"));("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.log("Sending outcomes:",t);const e=(n=t,gp((r=this._options.tunnel&&up(this._dsn))?{dsn:r}:{},[[{type:"client_report"},{timestamp:i||(0,ya.lu)(),discarded_events:n}]]));var n,r,i;this._sendEnvelope(e)}}class ad{static __initStatic(){this.id="GlobalHandlers"}__init(){this.name=ad.id}__init2(){this._installFunc={onerror:cd,onunhandledrejection:ld}}constructor(t){ad.prototype.__init.call(this),ad.prototype.__init2.call(this),this._options={onerror:!0,onunhandledrejection:!0,...t}}setupOnce(){Error.stackTraceLimit=50;const t=this._options;for(const n in t){const r=this._installFunc[n];r&&t[n]&&(e=n,("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.log(`Global Handler attached: ${e}`),r(),this._installFunc[n]=void 0)}var e}}function cd(){Ju("error",(t=>{const[e,n,r]=dd();if(!e.getIntegration(ad))return;const{msg:i,url:o,line:s,column:a,error:c}=t;if(qp()||c&&c.__sentry_own_request__)return;const l=void 0===c&&Gs(i)?function(t,e,n,r){const i=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i;let o=zs(t)?t.message:t,s="Error";const a=o.match(i);a&&(s=a[1],o=a[2]);const c={exception:{values:[{type:s,value:o}]}};return ud(c,e,n,r)}(i,o,s,a):ud(Gp(n,c||i,void 0,r,!1),o,s,a);l.level="error",pd(e,c,l,"onerror")}))}function ld(){Ju("unhandledrejection",(t=>{const[e,n,r]=dd();if(!e.getIntegration(ad))return;let i=t;try{"reason"in t?i=t.reason:"detail"in t&&"reason"in t.detail&&(i=t.detail.reason)}catch(t){}if(qp()||i&&i.__sentry_own_request__)return!0;const o=Hs(i)?{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(i)}`}]}}:Gp(n,i,void 0,r,!0);o.level="error",pd(e,i,o,"onunhandledrejection")}))}function ud(t,e,n,r){const i=t.exception=t.exception||{},o=i.values=i.values||[],s=o[0]=o[0]||{},a=s.stacktrace=s.stacktrace||{},c=a.frames=a.frames||[],l=isNaN(parseInt(r,10))?void 0:r,u=isNaN(parseInt(n,10))?void 0:n,p=Gs(e)&&e.length>0?e:function(){try{return Xs.document.location.href}catch(t){return""}}();return 0===c.length&&c.push({colno:l,filename:p,function:"?",in_app:!0,lineno:u}),t}function pd(t,e,n,r){ga(n,{handled:!1,type:r}),t.captureEvent(n,{originalException:e})}function dd(){const t=Ma(),e=t.getClient(),n=e&&e.getOptions()||{stackParser:()=>[],attachStacktrace:!1};return[t,n.stackParser,n.attachStacktrace]}ad.__initStatic();const hd=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"];class fd{static __initStatic(){this.id="TryCatch"}__init(){this.name=fd.id}constructor(t){fd.prototype.__init.call(this),this._options={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...t}}setupOnce(){this._options.setTimeout&&ra(Wp,"setTimeout",md),this._options.setInterval&&ra(Wp,"setInterval",md),this._options.requestAnimationFrame&&ra(Wp,"requestAnimationFrame",gd),this._options.XMLHttpRequest&&"XMLHttpRequest"in Wp&&ra(XMLHttpRequest.prototype,"send",vd);const t=this._options.eventTarget;if(t){(Array.isArray(t)?t:hd).forEach(bd)}}}function md(t){return function(...e){const n=e[0];return e[0]=Zp(n,{mechanism:{data:{function:zu(t)},handled:!0,type:"instrument"}}),t.apply(this,e)}}function gd(t){return function(e){return t.apply(this,[Zp(e,{mechanism:{data:{function:"requestAnimationFrame",handler:zu(t)},handled:!0,type:"instrument"}})])}}function vd(t){return function(...e){const n=this;return["onload","onerror","onprogress","onreadystatechange"].forEach((t=>{t in n&&"function"==typeof n[t]&&ra(n,t,(function(e){const n={mechanism:{data:{function:t,handler:zu(e)},handled:!0,type:"instrument"}},r=sa(e);return r&&(n.mechanism.data.handler=zu(r)),Zp(e,n)}))})),t.apply(this,e)}}function bd(t){const e=Wp,n=e[t]&&e[t].prototype;n&&n.hasOwnProperty&&n.hasOwnProperty("addEventListener")&&(ra(n,"addEventListener",(function(e){return function(n,r,i){try{"function"==typeof r.handleEvent&&(r.handleEvent=Zp(r.handleEvent,{mechanism:{data:{function:"handleEvent",handler:zu(r),target:t},handled:!0,type:"instrument"}}))}catch(t){}return e.apply(this,[n,Zp(r,{mechanism:{data:{function:"addEventListener",handler:zu(r),target:t},handled:!0,type:"instrument"}}),i])}})),ra(n,"removeEventListener",(function(t){return function(e,n,r){const i=n;try{const n=i&&i.__sentry_wrapped__;n&&t.call(this,e,n,r)}catch(t){}return t.call(this,e,i,r)}})))}function yd(t,e,n,r,i,o){if(!(i.exception&&i.exception.values&&o&&qs(o.originalException,Error)))return;const s=i.exception.values.length>0?i.exception.values[i.exception.values.length-1]:void 0;s&&(i.exception.values=_d(t,e,r,o.originalException,n,i.exception.values,s,0))}function _d(t,e,n,r,i,o,s,a){if(o.length>=n+1)return o;let c=[...o];if(qs(r[i],Error)){wd(s,a);const o=t(e,r[i]),l=c.length;kd(o,i,l,a),c=_d(t,e,n,r[i],i,[o,...c],o,l)}return Array.isArray(r.errors)&&r.errors.forEach(((r,o)=>{if(qs(r,Error)){wd(s,a);const l=t(e,r),u=c.length;kd(l,`errors[${o}]`,u,a),c=_d(t,e,n,r,i,[l,...c],l,u)}})),c}function wd(t,e){t.mechanism=t.mechanism||{type:"generic",handled:!0},t.mechanism={...t.mechanism,is_exception_group:!0,exception_id:e}}function kd(t,e,n,r){t.mechanism=t.mechanism||{type:"generic",handled:!0},t.mechanism={...t.mechanism,type:"chained",source:e,exception_id:n,parent_id:r}}fd.__initStatic();class xd{static __initStatic(){this.id="LinkedErrors"}__init(){this.name=xd.id}constructor(t={}){xd.prototype.__init.call(this),this._key=t.key||"cause",this._limit=t.limit||5}setupOnce(t,e){t(((t,n)=>{const r=e(),i=r.getClient(),o=r.getIntegration(xd);return i&&o?(yd(Bp,i.getOptions().stackParser,o._key,o._limit,t,n),t):t}))}}xd.__initStatic();class Sd{constructor(){Sd.prototype.__init.call(this)}static __initStatic(){this.id="HttpContext"}__init(){this.name=Sd.id}setupOnce(){Pa((t=>{if(Ma().getIntegration(Sd)){if(!Wp.navigator&&!Wp.location&&!Wp.document)return t;const e=t.request&&t.request.url||Wp.location&&Wp.location.href,{referrer:n}=Wp.document||{},{userAgent:r}=Wp.navigator||{},i={...t.request&&t.request.headers,...n&&{Referer:n},...r&&{"User-Agent":r}},o={...t.request,...e&&{url:e},headers:i};return{...t,request:o}}return t}))}}Sd.__initStatic();class Ed{constructor(){Ed.prototype.__init.call(this)}static __initStatic(){this.id="Dedupe"}__init(){this.name=Ed.id}setupOnce(t,e){const n=t=>{if(t.type)return t;const n=e().getIntegration(Ed);if(n){try{if(function(t,e){if(!e)return!1;if(function(t,e){const n=t.message,r=e.message;if(!n&&!r)return!1;if(n&&!r||!n&&r)return!1;if(n!==r)return!1;if(!Cd(t,e))return!1;if(!Td(t,e))return!1;return!0}(t,e))return!0;if(function(t,e){const n=Od(e),r=Od(t);if(!n||!r)return!1;if(n.type!==r.type||n.value!==r.value)return!1;if(!Cd(t,e))return!1;if(!Td(t,e))return!1;return!0}(t,e))return!0;return!1}(t,n._previousEvent))return("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn("Event dropped due to being a duplicate of previously captured event."),null}catch(e){return n._previousEvent=t}return n._previousEvent=t}return t};n.id=this.name,t(n)}}function Td(t,e){let n=Id(t),r=Id(e);if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;if(r.length!==n.length)return!1;for(let t=0;t|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,Pd=/\((\S*)(?::(\d+))(?::(\d+))\)/,$d=[30,t=>{const e=Dd.exec(t);if(e){if(e[2]&&0===e[2].indexOf("eval")){const t=Pd.exec(e[2]);t&&(e[2]=t[1],e[3]=t[2],e[4]=t[3])}const[t,n]=Ud(e[1]||Ad,e[2]);return Rd(n,t,e[3]?+e[3]:void 0,e[4]?+e[4]:void 0)}}],Ld=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,Nd=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,jd=[50,t=>{const e=Ld.exec(t);if(e){if(e[3]&&e[3].indexOf(" > eval")>-1){const t=Nd.exec(e[3]);t&&(e[1]=e[1]||"eval",e[3]=t[1],e[4]=t[2],e[5]="")}let t=e[3],n=e[1]||Ad;return[n,t]=Ud(n,t),Rd(t,n,e[4]?+e[4]:void 0,e[5]?+e[5]:void 0)}}],Bd=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:[-a-z]+):.*?):(\d+)(?::(\d+))?\)?\s*$/i,Md=Mu(...[$d,jd,[40,t=>{const e=Bd.exec(t);return e?Rd(e[2],e[1]||Ad,+e[3],e[4]?+e[4]:void 0):void 0}]]),Ud=(t,e)=>{const n=-1!==t.indexOf("safari-extension"),r=-1!==t.indexOf("safari-web-extension");return n||r?[-1!==t.indexOf("@")?t.split("@")[0]:Ad,n?`safari-extension:${e}`:`safari-web-extension:${e}`]:[t,e]};function zd(t){const e=[];function n(t){return e.splice(e.indexOf(t),1)[0]}return{$:e,add:function(r){if(!(void 0===t||e.lengthn(i))).then(null,(()=>n(i).then(null,(()=>{})))),i},drain:function(t){return new Oa(((n,r)=>{let i=e.length;if(!i)return n(!0);const o=setTimeout((()=>{t&&t>0&&n(!1)}),t);e.forEach((t=>{Ta(t).then((()=>{--i||(clearTimeout(o),n(!0))}),r)}))}))}}}function Fd(t,{statusCode:e,headers:n},r=Date.now()){const i={...t},o=n&&n["x-sentry-rate-limits"],s=n&&n["retry-after"];if(o)for(const t of o.trim().split(",")){const[e,n]=t.split(":",2),o=parseInt(e,10),s=1e3*(isNaN(o)?60:o);if(n)for(const t of n.split(";"))i[t]=r+s;else i.all=r+s}else s?i.all=r+function(t,e=Date.now()){const n=parseInt(`${t}`,10);if(!isNaN(n))return 1e3*n;const r=Date.parse(`${t}`);return isNaN(r)?6e4:r-e}(s,r):429===e&&(i.all=r+6e4);return i}function Gd(t,e,n=zd(t.bufferSize||30)){let r={};function i(i){const o=[];if(bp(i,((e,n)=>{const i=xp(n);if(function(t,e,n=Date.now()){return function(t,e){return t[e]||t.all||0}(t,e)>n}(r,i)){const r=Hd(e,n);t.recordDroppedEvent("ratelimit_backoff",i,r)}else o.push(e)})),0===o.length)return Ta();const s=gp(i[0],o),a=e=>{bp(s,((n,r)=>{const i=Hd(n,r);t.recordDroppedEvent(e,xp(r),i)}))};return n.add((()=>e({body:_p(s,t.textEncoder)}).then((t=>(void 0!==t.statusCode&&(t.statusCode<200||t.statusCode>=300)&&("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn(`Sentry responded with status code ${t.statusCode} to sent event.`),r=Fd(r,t),t)),(t=>{throw a("network_error"),t})))).then((t=>t),(t=>{if(t instanceof Ep)return("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.error("Skipped sending event because buffer is full."),a("queue_overflow"),Ta();throw t}))}return i.__sentry__baseTransport__=!0,{send:i,flush:t=>n.drain(t)}}function Hd(t,e){if("event"===e||"transaction"===e)return Array.isArray(t)?t[1]:void 0}let Vd;function Wd(t,e=function(){if(Vd)return Vd;if(Hu(Wp.fetch))return Vd=Wp.fetch.bind(Wp);const t=Wp.document;let e=Wp.fetch;if(t&&"function"==typeof t.createElement)try{const n=t.createElement("iframe");n.hidden=!0,t.head.appendChild(n);const r=n.contentWindow;r&&r.fetch&&(e=r.fetch),t.head.removeChild(n)}catch(t){("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",t)}return Vd=e.bind(Wp)}()){let n=0,r=0;return Gd(t,(function(i){const o=i.body.length;n+=o,r++;const s={body:i.body,method:"POST",referrerPolicy:"origin",headers:t.headers,keepalive:n<=6e4&&r<15,...t.fetchOptions};try{return e(t.url,s).then((t=>(n-=o,r--,{statusCode:t.status,headers:{"x-sentry-rate-limits":t.headers.get("X-Sentry-Rate-Limits"),"retry-after":t.headers.get("Retry-After")}})))}catch(t){return Vd=void 0,n-=o,r--,Ca(t)}}))}function Yd(t){return Gd(t,(function(e){return new Oa(((n,r)=>{const i=new XMLHttpRequest;i.onerror=r,i.onreadystatechange=()=>{4===i.readyState&&n({statusCode:i.status,headers:{"x-sentry-rate-limits":i.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":i.getResponseHeader("Retry-After")}})},i.open("POST",t.url);for(const e in t.headers)Object.prototype.hasOwnProperty.call(t.headers,e)&&i.setRequestHeader(e,t.headers[e]);i.send(e.body)}))}))}const qd=[new Ru,new $u,new fd,new ed,new ad,new xd,new Ed,new Sd];function Zd(t={}){void 0===t.defaultIntegrations&&(t.defaultIntegrations=qd),void 0===t.release&&("string"==typeof __SENTRY_RELEASE__&&(t.release=__SENTRY_RELEASE__),Wp.SENTRY_RELEASE&&Wp.SENTRY_RELEASE.id&&(t.release=Wp.SENTRY_RELEASE.id)),void 0===t.autoSessionTracking&&(t.autoSessionTracking=!0),void 0===t.sendClientReports&&(t.sendClientReports=!0);const e={...t,stackParser:(n=t.stackParser||Md,Array.isArray(n)?Mu(...n):n),integrations:Nu(t),transport:t.transport||(Gu()?Wd:Yd)};var n;!function(t,e){!0===e.debug&&("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__?xa.enable():console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle."));const n=Ma();n.getScope().update(e.initialScope);const r=new t(e);n.bindClient(r)}(sd,e),t.autoSessionTracking&&function(){if(void 0===Wp.document)return void(("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn("Session tracking in non-browser environment with @sentry/browser is not supported."));const t=Ma();if(!t.captureSession)return;Xd(t),Ju("history",(({from:t,to:e})=>{void 0!==t&&t!==e&&Xd(Ma())}))}()}function Xd(t){t.startSession({ignoreDuration:!0}),t.captureSession()}class Kd{static __initStatic(){this.id="HttpClient"}__init(){this.name=Kd.id}constructor(t){Kd.prototype.__init.call(this),this._options={failedRequestStatusCodes:[[500,599]],failedRequestTargets:[/.*/],...t}}setupOnce(t,e){this._getCurrentHub=e,this._wrapFetch(),this._wrapXHR()}_fetchResponseHandler(t,e,n){if(this._getCurrentHub&&this._shouldCaptureResponse(e.status,e.url)){const r=function(t,e){if(!e&&t instanceof Request)return t;if(t instanceof Request&&t.bodyUsed)return t;return new Request(t,e)}(t,n),i=this._getCurrentHub();let o,s,a,c;i.shouldSendDefaultPii()&&([{headers:o,cookies:a},{headers:s,cookies:c}]=[{cookieHeader:"Cookie",obj:r},{cookieHeader:"Set-Cookie",obj:e}].map((({cookieHeader:t,obj:e})=>{const n=this._extractFetchHeaders(e.headers);let r;try{const e=n[t]||n[t.toLowerCase()]||void 0;e&&(r=this._parseCookieString(e))}catch(e){("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.log(`Could not extract cookies from header ${t}`)}return{headers:n,cookies:r}})));const l=this._createEvent({url:r.url,method:r.method,status:e.status,requestHeaders:o,responseHeaders:s,requestCookies:a,responseCookies:c});i.captureEvent(l)}}_xhrResponseHandler(t,e,n){if(this._getCurrentHub&&this._shouldCaptureResponse(t.status,t.responseURL)){let r,i,o;const s=this._getCurrentHub();if(s.shouldSendDefaultPii()){try{const e=t.getResponseHeader("Set-Cookie")||t.getResponseHeader("set-cookie")||void 0;e&&(i=this._parseCookieString(e))}catch(t){("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.log("Could not extract cookies from response headers")}try{o=this._getXHRResponseHeaders(t)}catch(t){("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.log("Could not extract headers from response")}r=n}const a=this._createEvent({url:t.responseURL,method:e,status:t.status,requestHeaders:r,responseHeaders:o,responseCookies:i});s.captureEvent(a)}}_getResponseSizeFromHeaders(t){if(t){const e=t["Content-Length"]||t["content-length"];if(e)return parseInt(e,10)}}_parseCookieString(t){return t.split("; ").reduce(((t,e)=>{const[n,r]=e.split("=");return t[n]=r,t}),{})}_extractFetchHeaders(t){const e={};return t.forEach(((t,n)=>{e[n]=t})),e}_getXHRResponseHeaders(t){const e=t.getAllResponseHeaders();return e?e.split("\r\n").reduce(((t,e)=>{const[n,r]=e.split(": ");return t[n]=r,t}),{}):{}}_isInGivenRequestTargets(t){return!!this._options.failedRequestTargets&&this._options.failedRequestTargets.some((e=>"string"==typeof e?t.includes(e):e.test(t)))}_isInGivenStatusRanges(t){return!!this._options.failedRequestStatusCodes&&this._options.failedRequestStatusCodes.some((e=>"number"==typeof e?e===t:t>=e[0]&&t<=e[1]))}_wrapFetch(){Vu()&&Ju("fetch",(t=>{const{response:e,args:n}=t,[r,i]=n;e&&this._fetchResponseHandler(r,e,i)}))}_wrapXHR(){"XMLHttpRequest"in Zs.OW&&Ju("xhr",(t=>{const{xhr:e}=t,n=e[qu];if(!n)return;const{method:r,request_headers:i}=n;if(r)try{this._xhrResponseHandler(e,r,i)}catch(t){("undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__)&&xa.warn("Error while extracting response event form XHR response",t)}}))}_isSentryRequest(t){const e=this._getCurrentHub&&this._getCurrentHub().getClient();if(!e)return!1;const n=e.getDsn();return!!n&&t.includes(n.host)}_shouldCaptureResponse(t,e){return this._isInGivenStatusRanges(t)&&this._isInGivenRequestTargets(e)&&!this._isSentryRequest(e)}_createEvent(t){const e=`HTTP Client Error with status code: ${t.status}`,n={message:e,exception:{values:[{type:"Error",value:e}]},request:{url:t.url,method:t.method,headers:t.requestHeaders,cookies:t.requestCookies},contexts:{response:{status_code:t.status,headers:t.responseHeaders,cookies:t.responseCookies,body_size:this._getResponseSizeFromHeaders(t.responseHeaders)}}};return ga(n,{type:"http.client"}),n}}Kd.__initStatic();var Jd=function(t){var e=["Load failed","Failed to fetch","cancelled","annulé","已取消","Abgebrochen","キャンセルしました","cancelado","avbruten","geannuleerd"];Zd({dsn:"https://1f67009d53b34b6e9118ddf500f45208@o142330.ingest.sentry.io/4504340660355072",integrations:[new Kd({failedRequestStatusCodes:[[400,599]]})],environment:"production",release:"193cb90",sampleRate:t?1:.1,beforeSend:function(t){var n,r;return(null===(n=t.exception)||void 0===n||null===(r=n.values)||void 0===r?void 0:r.some((function(t){return"TypeError"===t.type&&t.value&&e.includes(t.value)})))?null:t}})},Qd=function(){var t=e(i().mark((function t(e){var n,r,o;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,Yl(e);case 2:return o=t.sent,t.abrupt("return",null!==(n=null==o||null===(r=o.data)||void 0===r?void 0:r.disclaimer)&&void 0!==n?n:null);case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),th=function(){var t=e(i().mark((function t(){var e,n,r,o,s,a,c,l,u,p,d,h,f,m;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(e="?".concat(Cu().src.split("?").slice(1).join("")),n=Ou(e,"shopId"),r=Ou(e,"shopShop"),o=Ou(e,"status")||null,s=Ou(e,"splitTests")||null,a=Ou(e,"sessionId")||null,c=Ou(e,"subscriberId"),l=Ou(e,"origin"),u=Ou(e,"flags"),p=Ou(e,"config"),!(d=Ou(e,"disclaimer"))){t.next=15;break}t.t0=JSON.parse(d),t.next=18;break;case 15:return t.next=17,Qd(n);case 17:t.t0=t.sent;case 18:if(h=t.t0){t.next=21;break}throw new Error("Disclaimer data could not be loaded from config");case 21:if(t.t1=Ou(e,"country"),t.t1){t.next=26;break}return t.next=25,kl(n);case 25:t.t1=t.sent;case 26:return f=t.t1,p&&(m=JSON.parse(p)),t.abrupt("return",{shopId:null!=n?n:"",status:o,origin:l,sessionId:a,previewData:m,flags:u,shopShop:r,splitTestCookies:s,disclaimer:h,currentCountry:f,subscriberId:c});case 29:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}(),eh=function(){var t=e(i().mark((function t(){var e,n,r,o,s,a,c,l;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return e="?".concat(Cu().src.split("?").slice(1).join("")),Jd(!!Ou(e,"config")),t.next=4,th();case 4:return n=t.sent,r=n.flags,o=n.shopId,s=n.previewData,a=n.shopShop,c=n.origin,l=n.disclaimer,Va("shop_id",o),Va("editor_preview",!!s),hc.updateState({flags:null!=r?r:void 0,shopId:Number(o),shopShop:null!=a?a:void 0,disclaimer:null!=l?l:void 0,isPreview:Boolean(s)}),window.parentHostname=((i=c).indexOf("//")>-1?i.split("/")[2]:i.split("/")[0]).split(":")[0].split("?")[0],t.abrupt("return",n);case 11:case"end":return t.stop()}var i}),t)})));return function(){return t.apply(this,arguments)}}();function nh(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}var rh=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"#ps-desktop-widget__phone-input",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=document.querySelector(e);return r?pr()(r,function(t){for(var e=1;e0&&i[i.length-1])||6!==a[0]&&2!==a[0])){s=0;continue}if(3===a[0]&&(!i||a[1]>i[0]&&a[1]=i+n?(i=s,[4,lh(0)]):[3,3]):[3,4];case 2:a.sent(),a.label=3;case 3:return++o,[3,1];case 4:return[2,r]}}))}))}function hh(t){t.then(void 0,(function(){}))}function fh(t,e){t=[t[0]>>>16,65535&t[0],t[1]>>>16,65535&t[1]],e=[e[0]>>>16,65535&e[0],e[1]>>>16,65535&e[1]];var n=[0,0,0,0];return n[3]+=t[3]+e[3],n[2]+=n[3]>>>16,n[3]&=65535,n[2]+=t[2]+e[2],n[1]+=n[2]>>>16,n[2]&=65535,n[1]+=t[1]+e[1],n[0]+=n[1]>>>16,n[1]&=65535,n[0]+=t[0]+e[0],n[0]&=65535,[n[0]<<16|n[1],n[2]<<16|n[3]]}function mh(t,e){t=[t[0]>>>16,65535&t[0],t[1]>>>16,65535&t[1]],e=[e[0]>>>16,65535&e[0],e[1]>>>16,65535&e[1]];var n=[0,0,0,0];return n[3]+=t[3]*e[3],n[2]+=n[3]>>>16,n[3]&=65535,n[2]+=t[2]*e[3],n[1]+=n[2]>>>16,n[2]&=65535,n[2]+=t[3]*e[2],n[1]+=n[2]>>>16,n[2]&=65535,n[1]+=t[1]*e[3],n[0]+=n[1]>>>16,n[1]&=65535,n[1]+=t[2]*e[2],n[0]+=n[1]>>>16,n[1]&=65535,n[1]+=t[3]*e[1],n[0]+=n[1]>>>16,n[1]&=65535,n[0]+=t[0]*e[3]+t[1]*e[2]+t[2]*e[1]+t[3]*e[0],n[0]&=65535,[n[0]<<16|n[1],n[2]<<16|n[3]]}function gh(t,e){return 32===(e%=64)?[t[1],t[0]]:e<32?[t[0]<>>32-e,t[1]<>>32-e]:(e-=32,[t[1]<>>32-e,t[0]<>>32-e])}function vh(t,e){return 0===(e%=64)?t:e<32?[t[0]<>>32-e,t[1]<>>1]),t=bh(t=mh(t,[4283543511,3981806797]),[0,t[0]>>>1]),t=bh(t=mh(t,[3301882366,444984403]),[0,t[0]>>>1])}function _h(t,e){e=e||0;var n,r=(t=t||"").length%16,i=t.length-r,o=[0,e],s=[0,e],a=[0,0],c=[0,0],l=[2277735313,289559509],u=[1291169091,658871167];for(n=0;n>>0).toString(16)).slice(-8)+("00000000"+(o[1]>>>0).toString(16)).slice(-8)+("00000000"+(s[0]>>>0).toString(16)).slice(-8)+("00000000"+(s[1]>>>0).toString(16)).slice(-8)}function wh(t){return parseInt(t)}function kh(t){return parseFloat(t)}function xh(t,e){return"number"==typeof t&&isNaN(t)?e:t}function Sh(t){return t.reduce((function(t,e){return t+(e?1:0)}),0)}function Eh(t,e){if(void 0===e&&(e=1),Math.abs(e)>=1)return Math.round(t/e)*e;var n=1/e;return Math.round(t*n)/n}function Th(t){return t&&"object"==typeof t&&"message"in t?t:{message:t}}function Ch(t){return"function"!=typeof t}function Oh(t,e,n){var r=Object.keys(t).filter((function(t){return!function(t,e){for(var n=0,r=t.length;n=4}function Ah(){var t=window,e=navigator;return Sh(["webkitPersistentStorage"in e,"webkitTemporaryStorage"in e,0===e.vendor.indexOf("Google"),"webkitResolveLocalFileSystemURL"in t,"BatteryManager"in t,"webkitMediaStream"in t,"webkitSpeechGrammar"in t])>=5}function Rh(){var t=window,e=navigator;return Sh(["ApplePayError"in t,"CSSPrimitiveValue"in t,"Counter"in t,0===e.vendor.indexOf("Apple"),"getStorageUpdates"in e,"WebKitMediaKeys"in t])>=4}function Dh(){var t=window;return Sh(["safari"in t,!("DeviceMotionEvent"in t),!("ongestureend"in t),!("standalone"in navigator)])>=3}function Ph(){var t=document;return(t.exitFullscreen||t.msExitFullscreen||t.mozCancelFullScreen||t.webkitExitFullscreen).call(t)}function $h(){var t=Ah(),e=function(){var t,e,n=window;return Sh(["buildID"in navigator,"MozAppearance"in(null!==(e=null===(t=document.documentElement)||void 0===t?void 0:t.style)&&void 0!==e?e:{}),"onmozfullscreenchange"in n,"mozInnerScreenX"in n,"CSSMozDocumentRule"in n,"CanvasCaptureMediaStream"in n])>=4}();if(!t&&!e)return!1;var n=window;return Sh(["onorientationchange"in n,"orientation"in n,t&&!("SharedWorker"in n),e&&/android/i.test(navigator.appVersion)])>=2}function Lh(t){var e=new Error(t);return e.name=t,e}function Nh(t,e,n){var r,i,o;return void 0===n&&(n=50),oh(this,void 0,void 0,(function(){var s,a;return sh(this,(function(c){switch(c.label){case 0:s=document,c.label=1;case 1:return s.body?[3,3]:[4,lh(n)];case 2:return c.sent(),[3,1];case 3:a=s.createElement("iframe"),c.label=4;case 4:return c.trys.push([4,,10,11]),[4,new Promise((function(t,n){var r=!1,i=function(){r=!0,t()};a.onload=i,a.onerror=function(t){r=!0,n(t)};var o=a.style;o.setProperty("display","block","important"),o.position="absolute",o.top="0",o.left="0",o.visibility="hidden",e&&"srcdoc"in a?a.srcdoc=e:a.src="about:blank",s.body.appendChild(a);var c=function(){var t,e;r||("complete"===(null===(e=null===(t=a.contentWindow)||void 0===t?void 0:t.document)||void 0===e?void 0:e.readyState)?i():setTimeout(c,10))};c()}))];case 5:c.sent(),c.label=6;case 6:return(null===(i=null===(r=a.contentWindow)||void 0===r?void 0:r.document)||void 0===i?void 0:i.body)?[3,8]:[4,lh(n)];case 7:return c.sent(),[3,6];case 8:return[4,t(a,a.contentWindow)];case 9:return[2,c.sent()];case 10:return null===(o=a.parentNode)||void 0===o||o.removeChild(a),[7];case 11:return[2]}}))}))}function jh(t){for(var e=function(t){for(var e,n,r="Unexpected syntax '".concat(t,"'"),i=/^\s*([a-z-]*)(.*)$/i.exec(t),o=i[1]||void 0,s={},a=/([.:#][\w-]+|\[.+?\])/gi,c=function(t,e){s[t]=s[t]||[],s[t].push(e)};;){var l=a.exec(i[2]);if(!l)break;var u=l[0];switch(u[0]){case".":c("class",u.slice(1));break;case"#":c("id",u.slice(1));break;case"[":var p=/^\[([\w-]+)([~|^$*]?=("(.*?)"|([\w-]+)))?(\s+[is])?\]$/.exec(u);if(!p)throw new Error(r);c(p[1],null!==(n=null!==(e=p[4])&&void 0!==e?e:p[5])&&void 0!==n?n:"");break;default:throw new Error(r)}}return[o,s]}(t),n=e[0],r=e[1],i=document.createElement(null!=n?n:"div"),o=0,s=Object.keys(r);o.6*n.length}))).sort(),[2,i]}var a}))}))},fontPreferences:function(){return function(t,e){void 0===e&&(e=4e3);return Nh((function(n,r){var i=r.document,o=i.body,s=o.style;s.width="".concat(e,"px"),s.webkitTextSizeAdjust=s.textSizeAdjust="none",Ah()?o.style.zoom="".concat(1/r.devicePixelRatio):Rh()&&(o.style.zoom="reset");var a=i.createElement("div");return a.textContent=ah([],Array(e/20|0),!0).map((function(){return"word"})).join(" "),o.appendChild(a),t(i,o)}),'')}((function(t,e){for(var n={},r={},i=0,o=Object.keys(nf);i=3}())return-1;var n=new e(1,5e3,44100),r=n.createOscillator();r.type="triangle",r.frequency.value=1e4;var i=n.createDynamicsCompressor();i.threshold.value=-50,i.knee.value=40,i.ratio.value=12,i.attack.value=0,i.release.value=.25,r.connect(i),i.connect(n.destination),r.start(0);var o=function(t){var e=3,n=500,r=500,i=5e3,o=function(){},s=new Promise((function(s,a){var c=!1,l=0,u=0;t.oncomplete=function(t){return s(t.renderedBuffer)};var p=function(){setTimeout((function(){return a(Lh("timeout"))}),Math.min(r,u+i-Date.now()))},d=function(){try{var r=t.startRendering();switch(uh(r)&&hh(r),t.state){case"running":u=Date.now(),c&&p();break;case"suspended":document.hidden||l++,c&&l>=e?a(Lh("suspended")):setTimeout(d,n)}}catch(t){a(t)}};d(),o=function(){c||(c=!0,u>0&&p())}}));return[s,o]}(n),s=o[0],a=o[1],c=s.then((function(t){return function(t){for(var e=0,n=0;n=3}()||e.push(t.languages);else if("string"==typeof t.languages){var r=t.languages;r&&e.push(r.split(","))}return e},colorDepth:function(){return window.screen.colorDepth},deviceMemory:function(){return xh(kh(navigator.deviceMemory),void 0)},screenResolution:function(){var t=screen,e=function(t){return xh(wh(t),null)},n=[e(t.width),e(t.height)];return n.sort().reverse(),n},hardwareConcurrency:function(){return xh(wh(navigator.hardwareConcurrency),void 0)},timezone:function(){var t,e=null===(t=window.Intl)||void 0===t?void 0:t.DateTimeFormat;if(e){var n=(new e).resolvedOptions().timeZone;if(n)return n}var r,i=(r=(new Date).getFullYear(),-Math.max(kh(new Date(r,0,1).getTimezoneOffset()),kh(new Date(r,6,1).getTimezoneOffset())));return"UTC".concat(i>=0?"+":"").concat(Math.abs(i))},sessionStorage:function(){try{return!!window.sessionStorage}catch(t){return!0}},localStorage:function(){try{return!!window.localStorage}catch(t){return!0}},indexedDB:function(){if(!Ih()&&!function(){var t=window,e=navigator;return Sh(["msWriteProfilerMark"in t,"MSStream"in t,"msLaunchUri"in e,"msSaveBlob"in e])>=3&&!Ih()}())try{return!!window.indexedDB}catch(t){return!0}},openDatabase:function(){return!!window.openDatabase},cpuClass:function(){return navigator.cpuClass},platform:function(){var t=navigator.platform;return"MacIntel"===t&&Rh()&&!Dh()?function(){if("iPad"===navigator.platform)return!0;var t=screen,e=t.width/t.height;return Sh(["MediaSource"in window,!!Element.prototype.webkitRequestFullscreen,e>.65&&e<1.53])>=2}()?"iPad":"iPhone":t},plugins:function(){var t=navigator.plugins;if(t){for(var e=[],n=0;n=.001))try{var t=new XMLHttpRequest;t.open("get","https://m1.openfpcdn.io/fingerprintjs/v".concat(ch,"/npm-monitoring"),!0),t.send()}catch(t){console.error(t)}}(),[4,cf(n)];case 1:return e.sent(),t=function(t){return Oh(rf,t,[])}({debug:r}),[2,lf(t,r)]}}))}))},hashComponents:af,componentsToDebugString:sf},pf=function(){var t=e(i().mark((function t(){var e,n;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,uf.load();case 2:return e=t.sent,t.next=5,e.get();case 5:return n=t.sent,t.abrupt("return",n.visitorId);case 7:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}(),df=function(t,e,n){var r=t?n:Rl(gc);if(r&&!(!t&&Rl(vc))){var i="".concat(vl,"/v2/opt_in/fingerprint");pf().then((function(t){var n={shop_id:e,subscriber_id:r,fingerprint:[{version:2,data:t}]};return fetch(i,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(n)})})).then((function(){t?Gl(vc,"true",0,4):Al(vc,"true",0,4)})).catch((function(){return null}))}},hf=function(){var t=e(i().mark((function t(e){var n,r,o,s,a,c,l,u,p,d,h,f;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.country,r=e.phoneNumber,o=e.popupId,s=e.sessionId,a=e.shopId,c=e.source,l=e.sourceKey,t.prev=1,t.next=4,fetch("".concat(gl,"/v2/public/block_popups/opt_in"),{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({country:n,popup_id:o,shop_id:a,phone_number:r,source:c,session_id:s,source_key:l})});case 4:if((u=t.sent).ok){t.next=7;break}throw new Error;case 7:return t.next=9,u.json();case 9:return p=t.sent,d=p.subscriber_id,h=p.success,f=p.token,yf({subscriberId:d,token:f}),t.abrupt("return",{subscriberId:d,success:h,token:f});case 17:return t.prev=17,t.t0=t.catch(1),t.abrupt("return",{success:!1});case 20:case"end":return t.stop()}}),t,null,[[1,17]])})));return function(e){return t.apply(this,arguments)}}(),ff=function(){var t=e(i().mark((function t(e){var n,r,o,s,a,c,l,u,p,d,h,f,m;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.countryCode,r=e.id,o=e.phoneNumber,s=e.sessionId,a=e.shopId,c=e.source,l=e.optInMethod,t.next=3,pf();case 3:return u=t.sent,t.prev=4,t.next=7,fetch("".concat(gl,"/api/subscriber/opt_in"),{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({popup_id:r,shop_id:a,phone_number:o,country_code:n,source:c,session_id:s,email:window.ps__email,opt_in_method:l,fingerprint:[{version:2,data:u}]})});case 7:if((p=t.sent).ok){t.next=10;break}throw new Error;case 10:return t.next=12,p.json();case 12:return d=t.sent,h=d.subscriber_id,f=d.success,m=d.token,yf({subscriberId:h,token:m}),t.abrupt("return",{subscriberId:h,success:f,token:m});case 20:return t.prev=20,t.t0=t.catch(4),t.abrupt("return",{success:!1});case 23:case"end":return t.stop()}}),t,null,[[4,20]])})));return function(e){return t.apply(this,arguments)}}(),mf=function(){var t=e(i().mark((function t(e,n,r,o){var s;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,fetch("".concat(gl,"/v2/opt_in/one_time_passcode/verify"),{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({shop_id:e,phone_number:n,code:r,source_key:o})});case 3:return s=t.sent,t.t0=s.status,t.next=7,s.json();case 7:return t.t1=t.sent,t.abrupt("return",{status:t.t0,data:t.t1});case 11:return t.prev=11,t.t2=t.catch(0),t.t2 instanceof Error?console.error("Error validating code: ".concat(t.t2.message)):"string"==typeof t.t2?console.error("Error validating code: ".concat(t.t2)):console.error("Error validating code"),t.abrupt("return",null);case 15:case"end":return t.stop()}}),t,null,[[0,11]])})));return function(e,n,r,i){return t.apply(this,arguments)}}(),gf=function(){var t=e(i().mark((function t(e,n){var r,o,s,a;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,fetch("".concat(gl,"/v2/opt_in/one_time_passcode/resend"),{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({shop_id:e,phone_number:n})});case 3:return r=t.sent,t.next=6,r.json();case 6:return o=t.sent,s=o.success,a=o.subscriber_id,t.abrupt("return",{success:s,error:null,subscriber_id:a});case 12:return t.prev=12,t.t0=t.catch(0),t.abrupt("return",{success:!1,error:t.t0,subscriber_id:null});case 15:case"end":return t.stop()}}),t,null,[[0,12]])})));return function(e,n){return t.apply(this,arguments)}}();window.setParentLocation=function(t){var e;null===(e=window.top)||void 0===e||e.postMessage({NavigateToUri:{name:"NavigateToUri",href:t}},"*")};var vf=function(t,e){dc.updateState({status:uc(t)}),Gl("".concat(bc,"_").concat(e),t,3650)},bf=function(t){window.parent.postMessage({CollectedEmailEvent:{name:"CollectedEmailEvent",email:t}},"*")},yf=function(t){var e,n=t.isIframe,r=void 0===n||n,i=t.subscriberId,o=t.token;if(!r)return Al(xc,o,3650),void(i&&Al(gc,i,3650));o&&(e=o,window.ps__token=e,Gl(xc,e)),i&&function(t){window.ps__subscriber_id=t,Gl(gc,t,3650)}(i)},_f=function(t){return fetch("".concat(vl,"/api/subscriber/attributes"),{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify(t)})},wf=function(t,e,n,r){if(hc.getState().isPreview)return Promise.resolve({});var i="".concat(bl,"/v1/subscribers"),o={country:null==r?void 0:r.toUpperCase(),event:t,popup_id:n,event_type:"popup",shop_id:e};try{return fetch(i,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify(o)})}catch(e){Ha(new TypeError("Failed to track ".concat(t," event"),{cause:e}))}},kf=function(t,e,n,r){var i=arguments.length>4&&void 0!==arguments[4]&&arguments[4];wf(Ac,t,n,e),i&&wf(Ic,t,n,e),function(t,e,n){window.parent.postMessage({type:"POPUP_IMPRESSION",popupId:t,popupName:e,isReopen:n},"*")}(n,r,i)},xf=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"sid";if(!e)return t;var r=/(ref:\s\S+)(\s?)/,i=r.exec(t);if(!i||3!==i.length)return"".concat(t," ").concat(n,": ").concat(e);var o=Ja(i,2)[1];return t.replace(r,"".concat(o," ").concat(n,": ").concat(e," "))},Sf=function(t,e,n){var r=navigator.userAgent.toLowerCase(),i=t;return"US"!==n&&"CA"!==n||11===(i=String(i).replace(/^\+/,"")).length&&"1"===i.charAt(0)&&(i=i.slice(1)),r.includes("pixel")?"".concat(jc,"//").concat(i,"/?").concat(Bc).concat(encodeURIComponent(e)):r.includes("chrome")||r.includes("android")?"".concat(jc).concat(i,"?").concat(Bc).concat(encodeURIComponent(e)):"".concat(jc).concat(i).concat(Bc).concat(encodeURIComponent(e))},Ef=function(){var t=e(i().mark((function t(e,n,r,o,s,a){return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return window.ps__email=n,wf(Rc,e,s,o),t.abrupt("return",_f({shop_id:e,source:a,session_id:r,email:n,subscriber_id:window.ps__subscriber_id,token:window.ps__token,server_id:window.ps__server_id,popup_id:s}));case 3:case"end":return t.stop()}}),t)})));return function(e,n,r,i,o,s){return t.apply(this,arguments)}}(),Tf=function(){var t=e(i().mark((function t(e,n,r){return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return window.setParentLocation(Sf(n,r,e)),t.next=3,yl(500);case 3:case"end":return t.stop()}}),t)})));return function(e,n,r){return t.apply(this,arguments)}}(),Cf=function(){var t=e(i().mark((function t(e,n){var r,o;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,r={popup_id:e,session_id:n},t.next=4,Dl("".concat(vl,"/sdk/session/server_id"),{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify(r)},2e3);case 4:return o=t.sent,t.abrupt("return",o.ok?o.text():null);case 8:return t.prev=8,t.t0=t.catch(0),t.abrupt("return",null);case 11:case"end":return t.stop()}}),t,null,[[0,8]])})));return function(e,n){return t.apply(this,arguments)}}(),Of=function(t){return document.getElementById(t)},If=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return t?"".concat(t,"vw"):e},Af=function(t){var e,n=t.backgroundColor,r=t.buttonBackgroundColor,i=t.buttonRadius,o=t.buttonTextColor,s=t.headlineFontSize,a=t.font,c=t.postHeadlineFontSize,l=t.textColor;return{"--ps-popup-background-color":null!=n?n:"","--ps-popup-button-border-radius":(e=null!=i?i:"",0===e||"0"===e?"0rem":"number"!=typeof e||Number.isNaN(e)||e===Number.POSITIVE_INFINITY||e===Number.NEGATIVE_INFINITY?"string"==typeof e&&e.length>0?"".concat(parseFloat(e.replace("[^0-9.]",""))/16,"rem"):"":"".concat(e/16,"rem")),"--ps-popup-button-text-color":null!=o?o:"","--ps-popup-headline-font-size":If(s,"3rem"),"--ps-popup-postheadline-font-size":If(c,"1.5rem"),"--ps-popup-font":"".concat(null==a?void 0:a.split(":")[0],", sans-serif"),"--ps-popup-primary-color":null!=r?r:"","--ps-popup-text-color":null!=l?l:""}},Rf={"--ps-popup-close-button-text-color":"var(--ps-popup-primary-color)","--ps-popup-container-height":"100%","--ps-popup-container-margin-top":"0rem","--ps-popup-container-margin-right":"0rem","--ps-popup-container-margin-bottom":"0rem","--ps-popup-container-margin-left":"0rem","--ps-popup-container-width":"calc(100vw - var(--ps-popup-container-margin-left) - var(--ps-popup-container-margin-right))","--ps-popup-container-padding-top":"0rem","--ps-popup-container-padding-right":"10%","--ps-popup-container-padding-bottom":"15vh","--ps-popup-container-padding-left":"10%","--ps-popup-form-max-height":"100%"},Df={"--ps-popup-close-button-text-color":"var(--ps-popup-primary-color)","--ps-popup-container-height":"auto","--ps-popup-container-margin-top":"0rem","--ps-popup-container-margin-right":"1.25rem","--ps-popup-container-margin-bottom":"0rem","--ps-popup-container-margin-left":"1.25rem","--ps-popup-container-width":"calc(27.5625rem - var(--ps-popup-container-margin-left) - var(--ps-popup-container-margin-right))","--ps-popup-container-padding-top":"2.625rem","--ps-popup-container-padding-right":"3.375rem","--ps-popup-container-padding-bottom":"3.375rem","--ps-popup-container-padding-left":"3.375rem","--ps-popup-form-max-height":"calc(100vh - var(--ps-popup-container-padding-top) - var(--ps-popup-container-padding-bottom))"},Pf={"--ps-popup-close-button-text-color":"var(--ps-popup-text-color)","--ps-popup-container-height":"100vh","--ps-popup-container-margin-top":"0rem","--ps-popup-container-margin-right":"0rem","--ps-popup-container-margin-bottom":"0rem","--ps-popup-container-margin-left":"0rem","--ps-popup-container-width":"100%","--ps-popup-container-padding-top":"3rem","--ps-popup-container-padding-right":"2.25rem","--ps-popup-container-padding-bottom":"3rem","--ps-popup-container-padding-left":"2.25rem","--ps-popup-form-max-height":"calc(100vh - var(--ps-popup-container-padding-top) - var(--ps-popup-container-padding-bottom))"},$f={"--ps-popup-close-button-text-color":"var(--ps-popup-text-color)","--ps-popup-container-height":"100vh","--ps-popup-container-margin-top":"0rem","--ps-popup-container-margin-right":"1rem","--ps-popup-container-margin-bottom":"1rem","--ps-popup-container-margin-left":"1rem","--ps-popup-container-width":"calc(100% - var(--ps-popup-container-margin-left) - var(--ps-popup-container-margin-right))","--ps-popup-container-padding-top":"3rem","--ps-popup-container-padding-right":"2.25rem","--ps-popup-container-padding-bottom":"3rem","--ps-popup-container-padding-left":"2.25rem","--ps-popup-form-max-height":"calc(100vh - var(--ps-popup-container-padding-top) - var(--ps-popup-container-padding-bottom) - var(--ps-popup-container-margin-top) - var(--ps-popup-container-margin-bottom))"};function Lf(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}var Nf=function(t){var e=hc.getState().flags;return function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:1)<=2?{"--ps-popup-container-height":"600px"}:{})};function Uf(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 zf(t){for(var e=1;e svg {\n fill: ").concat(s,";\n }\n\n #ps-desktop-widget__phone-input-wrapper,\n #ps-desktop-widget__email-input-wrapper,\n #ps-desktop-widget__phone-input-wrapper input,\n #ps-desktop-widget__email-input-wrapper input {\n border-radius: ").concat(c,"px;\n }\n\n #ps-desktop-widget__submit {\n border-radius: ").concat(c,"px;\n }\n\n #ps-desktop-widget__side-img {\n display: ").concat(l?"none":"block",";\n width: ").concat(u?"400px":"0",";\n border-radius: ").concat(function(t){var e=t.sideImgUrl,n=t.borderRadius;return e?"".concat(n,"px 0 0 ").concat(n,"px"):"0"}({sideImgUrl:u,borderRadius:a}),";\n background-image: ").concat(u?"url('".concat(u,"')"):"none",";\n background-size: cover;\n }\n\n ").concat(f?"\n #ps-desktop-widget__disclaimer-text {\n text-align: center;\n line-height: 1;\n }\n ":"","\n\n ").concat(1===(null!=d?d:1)?function(t){var e=t.fullscreen,n=t.sideImgUrl;return"\n p {\n font-size: 1.2rem;\n }\n\n h4 {\n margin: 10px 0;\n font-size: 3.7rem;\n }\n\n #ps-desktop-widget__body {\n padding: ".concat(e?"0 10% 15vh 10%;":"30px 5% 50px;","\n ").concat(e||n?"":"width: 600px;","\n }\n")}({fullscreen:l,sideImgUrl:u}):"","\n\n ").concat(Zf(t),"\n\n ").concat(n||"","\n").trim();return V(Ff||(Ff=Qa(["\n \n "])),m)},Kf=function(){return V(Hf||(Hf=Qa(['\n
    \n

    \n Check YOUR 📱 AND\n

    \n

    \n REPLY "Y"\n

    \n

    \n TO FINISH SIGNING UP\n

    \n
    \n'])))},Jf=function(t){var e=t.screen,n=void 0===e?"phone":e,r=t.preHeadline,i=t.headline,o=t.postHeadline,s=t.emailPreHeadline,a=t.emailPostHeadline,c=t.emailHeadline,l=t.backInStock,u=void 0!==l&&l;return V(Vf||(Vf=Qa(['\n
    \n

    \n ',"\n

    \n ",'\n

    \n ',"","\n

    \n
    \n"])),"phone"===n?r:s,V(u?Wf||(Wf=Qa(['\n ',"\n

    "])):Yf||(Yf=Qa(['

    \n ',"\n

    "])),"phone"===n?i:c),"phone"===n?o:a,"phone"===n&&(o||a)?"*":"")};function Qf(t,e){if(null==t)return{};var n,r,i=function(t,e){if(null==t)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.includes(r))continue;n[r]=t[r]}return n}(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(r=0;rdocument.createComment(""),cm=(t,e,n)=>{var r;const i=t._$AA.parentNode,o=void 0===e?t._$AB:e._$AA;if(void 0===n){const e=i.insertBefore(am(),o),r=i.insertBefore(am(),o);n=new sm(e,r,t,t.options)}else{const e=n._$AB.nextSibling,s=n._$AM,a=s!==t;if(a){let e;null===(r=n._$AQ)||void 0===r||r.call(n,t),n._$AM=t,void 0!==n._$AP&&(e=t._$AU)!==s._$AU&&n._$AP(e)}if(e!==o||a){let t=n._$AA;for(;t!==e;){const e=t.nextSibling;i.insertBefore(t,o),t=e}}}return n},lm=(t,e,n=t)=>(t._$AI(e,n),t),um={},pm=t=>{var e;null===(e=t._$AP)||void 0===e||e.call(t,!1,!0);let n=t._$AA;const r=t._$AB.nextSibling;for(;n!==r;){const t=n.nextSibling;n.remove(),n=t}},dm=(t,e,n)=>{const r=new Map;for(let i=e;i<=n;i++)r.set(t[i],i);return r},hm=bt(class extends yt{constructor(t){if(super(t),t.type!==vt)throw Error("repeat() can only be used in text expressions")}ct(t,e,n){let r;void 0===n?n=e:void 0!==e&&(r=e);const i=[],o=[];let s=0;for(const e of t)i[s]=r?r(e,s):s,o[s]=n(e,s),s++;return{values:o,keys:i}}render(t,e,n){return this.ct(t,e,n).values}update(t,[e,n,r]){var i;const o=(t=>t._$AH)(t),{values:s,keys:a}=this.ct(e,n,r);if(!Array.isArray(o))return this.ut=a,s;const c=null!==(i=this.ut)&&void 0!==i?i:this.ut=[],l=[];let u,p,d=0,h=o.length-1,f=0,m=s.length-1;for(;d<=h&&f<=m;)if(null===o[d])d++;else if(null===o[h])h--;else if(c[d]===a[f])l[f]=lm(o[d],s[f]),d++,f++;else if(c[h]===a[m])l[m]=lm(o[h],s[m]),h--,m--;else if(c[d]===a[m])l[m]=lm(o[d],s[m]),cm(t,l[m+1],o[d]),d++,m--;else if(c[h]===a[f])l[f]=lm(o[h],s[f]),cm(t,o[d],o[h]),h--,f++;else if(void 0===u&&(u=dm(a,f,m),p=dm(c,d,h)),u.has(c[d]))if(u.has(c[h])){const e=p.get(a[f]),n=void 0!==e?o[e]:null;if(null===n){const e=cm(t,o[d]);lm(e,s[f]),l[f]=e}else l[f]=lm(n,s[f]),cm(t,o[d],n),o[e]=null;f++}else pm(o[h]),h--;else pm(o[d]),d++;for(;f<=m;){const e=cm(t,l[m+1]);lm(e,s[f]),l[f++]=e}for(;d<=h;){const t=o[d++];null!==t&&pm(t)}return this.ut=a,((t,e=um)=>{t._$AH=e})(t,l),Y}});var fm=function(){var t=e(i().mark((function t(e){return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.abrupt("return",new Promise((function(t){var n,r=function(e){"CASHBACK_CODE_APPLIED"===e.data&&(clearTimeout(n),t())};n=setTimeout((function(){Ha("Did not receive auto apply success event from Fondue within 2000ms."),window.removeEventListener("message",r),t()}),2e3),window.addEventListener("message",r,{once:!0}),window.parent.postMessage({type:"CASHBACK_CODE",code:e},"*")})));case 1:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),mm=function(t){var e,n=null===t||200!==t.status,r=!(null!=t&&null!==(e=t.data)&&void 0!==e&&e.success);return n?{general:n}:r?{verification:r}:{}};function gm(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}var vm,bm=function(t){var e=t.formData,n=t.hostComponent,r={};e.forEach((function(t,e){"phone"!==e&&e!==nl&&(r[e]=t)})),0!==Object.keys(r).length&&_f(function(t){for(var e=1;e\n \n ','\n \n
    \n \n \n \n
    \n \n '])),ol,this.question.text,ol,this.question,this.question.attributeKey,Om,this.handleMonthChange,!!this.day,this.question,this.question.attributeKey,(t=this.month)?qa(Array(Im[t]).keys()).map((function(t){return{label:(t+1).toString(),value:(t+1).toString().padStart(2,"0")}})):[],this.handleDayChange,!!this.month,!this.month,this.question.attributeKey,this.month&&this.day?"".concat(this.month,"-").concat(this.day):"");var t}}],[{key:"properties",get:function(){return{question:{type:Object},month:{state:!0},day:{state:!0}}}}]),n}(ft);function Rm(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(Rm=function(){return!!t})()}sl("ps-month-and-day-input",Am);var Dm,Pm,$m="".concat(ol,"phone-field-input"),Lm=function(t){rm(n,t);var e=function(t){var e=Rm();return function(){var n,r=tm(t);if(e){var i=tm(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return om(this,n)}}(n);function n(){var t;return tc(this,n),(t=e.call(this)).hasValue=!1,t.isDropdownOpen=!1,t.onFirstUpdate=t.onFirstUpdate.bind(im(t)),t}return nc(n,[{key:"createRenderRoot",value:function(){return this}},{key:"getFormattedInputValue",value:function(){var t,e,n,r=(null!==(t=null===(e=this.phoneInputInstance)||void 0===e?void 0:e.getSelectedCountryData())&&void 0!==t?t:{}).iso2;return{phone:null===(n=this.phoneInputInstance)||void 0===n?void 0:n.getNumber(),country:r}}},{key:"onFirstUpdate",value:function(){var t=this,e="#".concat($m," input");this.phoneInputInstance=rh(this.countryCode,e,{dropdownContainer:document.body,useFullscreenPopup:this.popupType===Dc});var n=document.querySelector(e);null==n||n.addEventListener("blur",(function(e){var n,r=null===(n=e.target)||void 0===n?void 0:n.value;t.hasValue=!(null==r||!r.trim())})),null==n||n.addEventListener("open:countrydropdown",(function(){t.isDropdownOpen=!0})),null==n||n.addEventListener("close:countrydropdown",(function(){t.isDropdownOpen=!1}))}},{key:"connectedCallback",value:function(){var t;em(tm(n.prototype),"connectedCallback",this).call(this),null===(t=document.querySelector("ps-popup-form"))||void 0===t||t.addEventListener("scroll",n.closeDropdownOnScroll)}},{key:"disconnectedCallback",value:function(){var t,e;em(tm(n.prototype),"disconnectedCallback",this).call(this),null===(t=this.phoneInputInstance)||void 0===t||t.destroy(),null===(e=document.querySelector("ps-popup-form"))||void 0===e||e.removeEventListener("scroll",n.closeDropdownOnScroll)}},{key:"render",value:function(){var t;return V(Cm||(Cm=Qa(['\n \n '])),this.question,$m,this.onFirstUpdate,null!==(t=this.ariaDescribedBy)&&void 0!==t?t:q,this.hasValue||this.isDropdownOpen)}}],[{key:"properties",get:function(){return{ariaDescribedBy:{type:String},question:{type:Object},countryCode:{type:String},phoneInputInstance:{state:!0},hasValue:{state:!0},isDropdownOpen:{state:!0},popupType:{type:String}}}},{key:"closeDropdownOnScroll",value:function(){window.dispatchEvent(new Event("scroll",{cancelable:!0,bubbles:!0}))}}]),n}(ft);function Nm(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(Nm=function(){return!!t})()}sl("ps-phone-input",Lm);var jm=function(t){rm(n,t);var e=function(t){var e=Nm();return function(){var n,r=tm(t);if(e){var i=tm(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return om(this,n)}}(n);function n(){return tc(this,n),e.apply(this,arguments)}return nc(n,[{key:"createRenderRoot",value:function(){return this}},{key:"render",value:function(){var t,e=this,n=null!==(t=this.question.options)&&void 0!==t?t:[];return V(Dm||(Dm=Qa(['\n
    \n \n ',"\n \n ","\n
    \n "])),ol,this.question.text,n.map((function(t){return V(Pm||(Pm=Qa(['\n \n "])),ol,ol,t,e.question.attributeKey,t)})))}}],[{key:"properties",get:function(){return{question:{type:Object}}}}]),n}(ft);sl("ps-radio-group",jm);var Bm,Mm,Um,zm="Something went wrong. Please try again later.",Fm="The code was not valid. Make sure the code is correct and try again.";function Gm(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(Gm=function(){return!!t})()}var Hm=function(t){rm(n,t);var e=function(t){var e=Gm();return function(){var n,r=tm(t);if(e){var i=tm(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return om(this,n)}}(n);function n(){return tc(this,n),e.apply(this,arguments)}return nc(n,[{key:"connectedCallback",value:function(){em(tm(n.prototype),"connectedCallback",this).call(this),this.classList.add("".concat(ol,"onsite-error-wrapper"))}},{key:"createRenderRoot",value:function(){return this}},{key:"render",value:function(){return V(Bm||(Bm=Qa(["\n ","\n ","\n "])),this.hasValidationError?V(Mm||(Mm=Qa(['

    ',"

    "])),Fm):q,this.hasGeneralError?V(Um||(Um=Qa(['

    ',"

    "])),zm):q)}}],[{key:"properties",get:function(){return{hasValidationError:{type:Boolean},hasGeneralError:{type:Boolean}}}}]),n}(ft);function Vm(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}sl("ps-one-time-passcode-input-error",Hm);var Wm,Ym,qm,Zm,Xm={bubbles:!0,cancelable:!0,composed:!0},Km=function(t){t.dispatchEvent(new CustomEvent(tl,function(t){for(var e=1;e=0?t:0}},{key:"svgDashes",get:function(){for(var t=[],e=0;e"])),this.characterWidth*e+this.dashGap*e,this.characterWidth*(e+1)+this.dashGap*e,this.svgHeight/2,this.svgHeight/2,this.visibleDashes[e]?"var(--ps-popup-field-text-color)":"transparent");t.push(n)}return t}},{key:"hasInputErrorStyle",get:function(){return this.hasValidationError&&!this.value||this.hasGeneralError}},{key:"handleInput",value:function(t){var e,n,r=null!==(e=null===(n=t.target)||void 0===n?void 0:n.value.replace(/\D/g,"").slice(0,this.requiredCharacterCount))&&void 0!==e?e:"";this.hasRequiredCharacterCount&&r.length>=this.requiredCharacterCount?this.input.value=this.value:(this.input.value=r,this.value=r,this.setDashVisibility(),Km(this),this._customFormSubmitButton&&this.hasRequiredCharacterCount&&this._customFormSubmitButton.focus())}},{key:"setDashVisibility",value:function(){var t=this;this.visibleDashes=Array.from({length:this.requiredCharacterCount},(function(e,n){return n>=t.valueLength}))}},{key:"createRenderRoot",value:function(){return this}},{key:"connectedCallback",value:function(){em(tm(a.prototype),"connectedCallback",this).call(this),this.id="".concat(ol,"onsite-wrapper"),this.style.setProperty("--_gap-width","".concat(this.dashGap,"px")),this.style.setProperty("--_padding-left","".concat(this.paddingLeft,"px")),this.style.setProperty("--_padding-right","".concat(this.paddingRight,"px")),this.style.setProperty("--_input-width","".concat(this.dynamicInputWidth,"px"))}},{key:"firstUpdated",value:(o=e(i().mark((function t(){var e,n=this;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.updateComplete;case 2:null===(e=Of(nl))||void 0===e||e.focus(),setTimeout((function(){var t;Km(n),null!==(t=n.hiddenText)&&void 0!==t&&t.getBoundingClientRect().width&&(n.characterWidth=n.hiddenText.getBoundingClientRect().width,n.svgViewBox="0 0 ".concat(n.dynamicSvgWidth," ").concat(n.svgHeight),n.style.setProperty("--_input-width","".concat(n.dynamicInputWidth,"px")))}),250);case 4:case"end":return t.stop()}}),t,this)}))),function(){return o.apply(this,arguments)})},{key:"updated",value:(r=e(i().mark((function t(e){return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!e.has("hasValidationError")||!this.hasValidationError){t.next=7;break}return this.input.value="",this.value="",this.setDashVisibility(),t.next=6,this.updateComplete;case 6:Km(this);case 7:case"end":return t.stop()}}),t,this)}))),function(t){return r.apply(this,arguments)})},{key:"handleClick",value:(n=e(i().mark((function t(){return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,gf(this.shopId,this.phoneNumber);case 2:t.sent.success&&(this.isResendCodeSuccessVisible=!0);case 5:case"end":return t.stop()}}),t,this)}))),function(){return n.apply(this,arguments)})},{key:"disconnectedCallback",value:function(){em(tm(a.prototype),"disconnectedCallback",this).call(this),this._customForm&&(this._customForm.hasInvalidField=!1)}},{key:"render",value:function(){return V(Ym||(Ym=Qa(["\n

    \n ",'\n

    \n \n Didn\'t get a code?\n \n Resend code\n \n ','\n \n \n \n ","\n "])),this.isLoading,this.isEngagement?"true":q,this.isDisabled,this.onClick,"".concat(ol,"button"),this.id,null!==(t=this.type)&&void 0!==t?t:"button",this.primaryText,this.secondaryText?V(ag||(ag=Qa(["",""])),this.secondaryText):q,this.isLoading?V(cg||(cg=Qa([""])),"submit"===this.type?"var(--ps-popup-button-text-color)":"var(--ps-popup-close-button-text-color)"):q)}}],[{key:"properties",get:function(){return{id:{type:String},isDisabled:{type:Boolean},isEngagement:{type:Boolean},isLoading:{type:Boolean},onClick:{type:Function},primaryText:{type:String},secondaryText:{type:String},type:{type:String}}}}]),n}(ft);function hg(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(hg=function(){return!!t})()}sl("ps-button",dg);var fg,mg=function(t){rm(n,t);var e=function(t){var e=hg();return function(){var n,r=tm(t);if(e){var i=tm(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return om(this,n)}}(n);function n(){return tc(this,n),e.apply(this,arguments)}return nc(n,[{key:"createRenderRoot",value:function(){return this}},{key:"firstUpdated",value:function(t){var e;em(tm(n.prototype),"firstUpdated",this).call(this,t),null===(e=this.onFirstUpdate)||void 0===e||e.call(this)}},{key:"render",value:function(){var t;return V(pg||(pg=Qa(['\n
    \n \n ',"\n
    \n "])),ol,this.type,this.question.attributeKey,this.question.attributeKey,null!==(t=this.ariaDescribedBy)&&void 0!==t?t:q," ","tel"===this.type?"tel-national":"email"===this.type?"email":"on",ol,this.question.attributeKey,this.question.text)}}],[{key:"properties",get:function(){return{ariaDescribedBy:{type:String},question:{type:Object},type:{type:String},onFirstUpdate:{type:Function}}}}]),n}(ft);function gg(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(gg=function(){return!!t})()}sl("ps-input",mg);var vg=function(t){rm(n,t);var e=function(t){var e=gg();return function(){var n,r=tm(t);if(e){var i=tm(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return om(this,n)}}(n);function n(){var t;tc(this,n);for(var r=arguments.length,i=new Array(r),o=0;o',"

    "])),this.message)}}],[{key:"properties",get:function(){return{message:{type:String},nextScreen:{type:Function},timeoutDuration:{type:Number}}}}]),n}(ft);function bg(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 yg(t){for(var e=1;e0&&function(t,e,n){window.parent.postMessage({type:"POPUP_FORM_SUBMIT",popupId:t,popupName:e,values:yg({},n)},"*")}(n,r,i)}catch(t){Ha(t)}};function Lg(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(Lg=function(){return!!t})()}var Ng,jg=function(t){rm(o,t);var n,r=function(t){var e=Lg();return function(){var n,r=tm(t);if(e){var i=tm(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return om(this,n)}}(o);function o(){var t;return tc(this,o),(t=r.call(this)).hasInvalidField=!1,t}return nc(o,[{key:"createRenderRoot",value:function(){return this}},{key:"fields",get:function(){return this.renderRoot.querySelectorAll("[name]")}},{key:"isSubmittable",get:function(){return!this.hasInvalidField&&!this.customFormSubmitController.isSubmitting}},{key:"submitButtonPrimaryText",get:function(){return this.customFormSubmitController.isOneTimePasscodeVisible?"Submit code":this.page.submitButtonText}},{key:"submitButtonSecondaryText",get:function(){return this.customFormSubmitController.isOneTimePasscodeVisible?void 0:this.page.secondarySubmitButtonText}},{key:"closeButtonPrimaryText",get:function(){return this.customFormSubmitController.isOneTimePasscodeVisible?"Exit":this.page.closeButtonText}},{key:"getComponentForQuestionType",value:function(t){switch(t.type){case Zc:return V(_g||(_g=Qa([''])),ol,t);case Xc:return ll(this.popupTemplateProps)?q:V(wg||(wg=Qa([''])),ol,t,this.popupTemplateProps.currentCountry,ol,this.popupTemplateProps.popupType);case Kc:return V(kg||(kg=Qa([''])),ol,t);case Jc:return V(xg||(xg=Qa([''])),ol,t);case Qc:return V(Sg||(Sg=Qa([''])),ol,t)}}},{key:"getSortedQuestions",value:function(){return this.page.questions.sort((function(t,e){return t.type===Xc?1:e.type===Xc?-1:0}))}},{key:"handleValidateFormEvent",value:(n=e(i().mark((function t(e){var n;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e.stopPropagation(),n=Array.from(this.fields).some((function(t){return!t.checkValidity()})),this.hasInvalidField=n;case 3:case"end":return t.stop()}}),t,this)}))),function(t){return n.apply(this,arguments)})},{key:"handleSubmit",value:function(t){$g(t,this.page.questions,this.popupTemplateProps.id,this.popupTemplateProps.name),this.customFormSubmitController.handleSubmit(t,this)}},{key:"connectedCallback",value:function(){em(tm(o.prototype),"connectedCallback",this).call(this),this.id="".concat(ol,"form-wrapper"),this.customFormSubmitController=new Em(this,{page:this.page,popupTemplateProps:this.popupTemplateProps}),this.addEventListener(tl,this.handleValidateFormEvent)}},{key:"updated",value:function(t){var e;(t.has("page")||t.has("popupTemplateProps"))&&(this.customFormSubmitController=new Em(this,{page:this.page,popupTemplateProps:this.popupTemplateProps}),this.requestUpdate()),this.showDisclaimerText=(null===(e=this.page)||void 0===e?void 0:e.questions.some((function(t){return t.type===Xc})))&&!this.customFormSubmitController.isOneTimePasscodeVisible}},{key:"render",value:function(){var t,e=this;return V(Eg||(Eg=Qa(['\n
    \n ',"\n ","\n ","\n ","\n
    \n\n \n '])),ol,this.popupTemplateProps.logoUrl),this.page.preHeadline&&V(Cg||(Cg=Qa(['

    \n ',"\n

    "])),ol,this.page.preHeadline),this.page.headline&&V(Og||(Og=Qa(['

    \n ',"\n

    "])),ol,this.page.headline),this.page.postHeadline&&V(Ig||(Ig=Qa(['

    \n ',"\n

    "])),ol,this.page.postHeadline),"".concat(ol,"form"),!!this.customFormSubmitController.staticPageMessage,this.handleSubmit,"".concat(ol,"form-questions-wrapper"),this.customFormSubmitController.isSubmitting,this.customFormSubmitController.isOneTimePasscodeVisible?V(Ag||(Ag=Qa([""])),this.customFormSubmitController.hasValidationError,this.customFormSubmitController.hasGeneralError,this.popupTemplateProps.shopId,this.customFormSubmitController.phoneNumber,this.customFormSubmitController.isResendCodeSuccessVisible):hm(this.getSortedQuestions(),(function(t){return t.attributeKey}),(function(t){return e.getComponentForQuestionType(t)})),this.showDisclaimerText?V(Rg||(Rg=Qa(['',""])),ol,null!==(t=this.popupTemplateProps.terms)&&void 0!==t?t:Oc(window.parentHostname)):q,"".concat(ol,"form-ctas-wrapper"),"".concat(ol,"submit-button"),!this.isSubmittable,this.customFormSubmitController.isSubmitting,this.submitButtonPrimaryText,this.submitButtonSecondaryText,"submit",this.page.closeButtonText?V(Dg||(Dg=Qa([""])),"".concat(ol,"close-button"),this.customFormSubmitController.isSubmitting,!1,this.closeButtonPrimaryText,this.onExit):q,this.customFormSubmitController.staticPageMessage?V(Pg||(Pg=Qa([""])),this.customFormSubmitController.staticPageMessage,this.popupTemplateProps.nextScreen,this.popupTemplateProps.autoApplyOfferEnabled?3500:2500):q)}}],[{key:"properties",get:function(){return{hasInvalidField:{type:Boolean},onExit:{type:Object},page:{type:Object},popupTemplateProps:{type:Object},showDisclaimerText:{state:!0},source:{type:String}}}}]),o}(ft);sl("ps-popup-form",jg);var Bg,Mg,Ug,zg,Fg,Gg,Hg,Vg=function(t){var e=t.content,n=t.currentCountry,r=t.formId,i=t.id,o=t.nextScreen,s=t.sessionId,a=t.shopId,c=t.source;return V(Ng||(Ng=Qa(["\n
    ',"
    \n "])),(function(t){t.preventDefault();var e=new FormData(t.target).get("email");Ef(a,e,s,n,i,c),bf(e),o()}),r,e)},Wg=function(t){var e=t.text,n=t.onClick;return V(Bg||(Bg=Qa(["\n \n ',"\n \n"])),n,e)},Yg=function(){return V(Mg||(Mg=Qa(['\n
    \n \n
    \n'])))},qg=function(t){var e=t.onClick;return V(Ug||(Ug=Qa(['\n \n \n \n \n \n'])),e,hu)},Zg=function(t){var e=t.logoUrl;return e?V(zg||(zg=Qa(['\n
    \n \n
    \n '])),e):null},Xg=function(t){var e=t.text,n=t.isVisible,r=void 0===n||n;return V(Fg||(Fg=Qa(['\n \n ',"\n \n"])),e,r?"visible":"hidden",e)},Kg=["headlineComponent","onExit","logoUrl","emailSubscribeText","emailCloseText"];function Jg(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}var Qg,tv,ev,nv,rv,iv,ov,sv,av,cv,lv,uv,pv,dv=function(t){var e=t.headlineComponent,n=t.onExit,r=t.logoUrl,i=t.emailSubscribeText,o=t.emailCloseText,s=Qf(t,Kg);return V(Gg||(Gg=Qa(["\n
    \n "," ","\n ","\n ","\n
    \n"])),qg({onClick:n}),Zg({logoUrl:r}),e,Vg(function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:{},e=t.terms,n=void 0===e?Oc(window.parentHostname):e,r=t.isVisible,i=void 0===r||r,o=t.backInStock,s=void 0!==o&&o;return V(Qg||(Qg=Qa(['\n \n
    ',"
    \n \n"])),s?i?null:"display: none;":i?"visibility: visible;":"visibility: hidden;",n)},fv=function(t){var e=t.isVisible,n=void 0===e||e,r=t.inputId,i=void 0===r?"ps-desktop-widget__phone-input":r,o=t.backInStock,s=void 0!==o&&o;return V(tv||(tv=Qa(['\n \n \n \n'])),s?n?null:"display: none;":n?"visibility: visible;":"visibility: hidden;",i)},mv=function(t){var e=t.headlineComponent,n=t.onExit,r=t.logoUrl,i=t.onSubmit,o=t.showSuccess,s=t.buttonText,a=t.closeText,c=t.popupSize,l=t.collectionAttributes,u=t.terms;return V(ev||(ev=Qa(['\n \n '," ","\n ","\n
    \n ","\n ","\n ","\n ","\n
    \n \n"])),uu,"Partial"===c&&l.includes("email")&&"animate-height-in",qg({onClick:n}),Zg({logoUrl:r}),e,i,fv({isVisible:!o}),hv({isVisible:!o,terms:u}),Xg({text:s,isVisible:!o}),Wg({text:o?"Got It!":a,onClick:o?function(){return n(!0)}:n}))},gv=["screen"],vv={success:mv,phone:mv,email:dv},bv=function(t){var e,n=t.screen,r=void 0===n?"phone":n,i=Qf(t,gv),o=i.onExit,s=i.popupSize,a=null===(e=i.pages)||void 0===e?void 0:e.find((function(t){return r==="page_".concat(t.id)})),c=a?function(t){return V(iv||(iv=Qa(['
    \n ',"\n \n
    '])),ol,qg({onClick:t.onExit}),t.onExit,a,t,zc)}:vv[r||"phone"];return"Banner"===s?V(ov||(ov=Qa(['\n \n \n \n ',"\n \n \n \n "])),uu,vu(o),c(i)):function(t,e){return V(rv||(rv=Qa(['\n \n
    \n
    \n
    ',"
    \n
    \n \n"])),uu,vu(e),e,t)}(V(sv||(sv=Qa(["\n ",'\n
    \n ',"\n
    \n "])),V(nv||(nv=Qa(['\n
    \n']))),c(i)),o)},yv=function t(e,n){return!!e.dataset.popupEngagement||!(e===n||!e.parentNode||e.parentNode.tagName===n.tagName)&&t(e.parentNode,n)},_v=function(t){var e,n=null,r=!1,i=function(t){if(r){for(var e,n=arguments.length,i=new Array(n>1?n-1:0),o=1;o\n
    \n
    \n \n \n \n \n \n
    \n
    \n \n \n'])),uu,n,hu,e,r,hu)}({text:g,onOpen:function(){var t=kv(kv({},e),{},{isOpen:!0});kf(i,o,k,x,!0),uv&&Ul(Ev),A(t),gu((function(){return mu(Of(Ec))}))},onExit:function(){return P(!0)}}));var L=I?Kf():Jf(kv({},e));return V(cv||(cv=Qa(["\n ","\n ","\n "])),$,bv(kv({headlineComponent:L,nextScreen:D,onExit:P,onSubmit:function(t){t.preventDefault();var e=pv.selectedCountryData.iso2,n=pv.getNumber();!function(t,e,n,r,i){ff({countryCode:e,id:r,phoneNumber:n,sessionId:i,shopId:t,source:zc})}(i,e,n,k,y),D()},showSuccess:I},e)))},Av=function(){var t=e(i().mark((function t(e,n,r,o,s,a){var c,l,u,p,d,h,f,m,g,v,b;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(xu(),c=!0,Va("popup_id",e.id),l=e.font,u=e.collectionAttributes,p=e.excludedHosts,d=void 0===p?fc:p,h=e.id,f=e.name,!d.includes(window.location.host)){t.next=6;break}return t.abrupt("return");case 6:m=ql(yc,h,r),u&&"closed"===u[0]&&(c=!1),Sl(l),s||m!==wc||(c=!1),g=_v((function(){return wf(Ic,n,h,a)})),v=kv(kv({},e),{},{screen:u[0]||"phone",screensList:El(e),shopId:n,isOpen:c,currentCountry:a,sessionId:o,engagementTracker:g,terms:e.terms?V(lv||(lv=Qa(["",""])),Xr(e.terms)):void 0}),pt(Iv(v),document.body),Nl(),c?(jl(),Bl(),b=document.querySelector("main"),g.startSession(b),kf(n,a,h,f),Ul(Ev),gu((function(){return mu(Of(Ec))})),pv=rh(a,void 0,{useFullscreenPopup:!1})):(jl(),setTimeout((function(){Ll(Tv,Cv),Bl()}),s?0:500)),dc.updateState({id:e.id,status:uc(m),engagementTracker:g});case 16:case"end":return t.stop()}}),t)})));return function(e,n,r,i,o,s){return t.apply(this,arguments)}}(),Rv="ps-block-popup__container",Dv="ENGAGEMENT",Pv="IMPRESSION",$v="SUBMIT_EMAIL",Lv="CLOSE_POPUP_STEP",Nv=function(t,e){return V(xv||(xv=Qa(['\n \n
    \n
    \n
    ',"
    \n
    \n \n"])),uu,Rv,vu(e),e,t)},jv=function(t){return V(Sv||(Sv=Qa(['\n
    \n ',"\n
    \n"])),Rv,uu,t)},Bv="closed",Mv="visible",Uv="teaser",zv=function(t,e){var n={subscriberProperties:{}},r={};return t.forEach((function(t){var i=function(t,e){var n,r=(null!==(n=t.config)&&void 0!==n?n:{}).dataName,i={},o=e[t.id];r&&o&&(i[r]=o);var s=fs.validateBlockData(t,o);return{blockData:!s&&Object.keys(i).length?i:null,blockError:s}}(t,e),o=i.blockData,s=i.blockError;if(s&&(r[t.id]=s),o){var a=Object.keys(o)[0];a!==gn&&a!==vn?n.subscriberProperties[a]=o[a]:n[a]=o[a]}})),{data:n,errors:r}},Fv=function(){var t=e(i().mark((function t(e){var n,r,o,s,a,c,l,u,p,d,h;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.defaultNextStep,r=e.optInFn,o=e.persistAttributesFn,s=e.validatedStepData,a=void 0===s?{subscriberProperties:{}}:s,c=e.verifyOtpFn,l=a.phone,u=a.otp,p=a.subscriberProperties,d={hasError:!1,nextStep:n},h=[],Object.keys(p).length&&h.push(o(p)),u&&h.push(c(u)),l&&h.push(r(l)),t.next=9,Promise.allSettled(h);case 9:return t.sent.forEach((function(t){"fulfilled"===t.status&&t.value&&(d=t.value)})),t.abrupt("return",d);case 12:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),Gv=function(t){var e=Mv;return t===kc&&(e=Bv),t===wc?Uv:e},Hv={id:Lv,name:"Close Popup",order:9999999,role:"DEFAULT"},Vv=function(t){var e,n,r,i,o=t.block,s=t.currentStepId,a=t.isExistingSubscriber,c=t.steps,l=null!==(e=null===(n=o.config)||void 0===n?void 0:n.onClick)&&void 0!==e?e:{},u=l.existingSubscriberRouteTo,p=l.routeTo;if(!u&&!p)return Hv;var d=p===xn,h=p===Sn;if(a)return null!==(r=c.find((function(t){return t.id===u})))&&void 0!==r?r:Hv;if(d||h){var f,m=c.find((function(t){return t.id===s}));return m&&(null!==(f=c.find((function(t){return t.order===m.order+(d?1:-1)})))&&void 0!==f)?f:Hv}return null!==(i=c.find((function(t){return t.id===p})))&&void 0!==i?i:Hv},Wv=function(t){var e=t.currentStepId,n=t.stepBlocks,r=t.steps,i=n.filter((function(t){return t.stepId===e&&t.type===kt}));return!!i.length&&i.some((function(t){var n=Vv({block:t,currentStepId:e,isExistingSubscriber:!1,steps:r}),i=Vv({block:t,currentStepId:e,isExistingSubscriber:!0,steps:r});return n.id!==Lv||i.id!==Lv}))},Yv=function(t){return t===jt?Fc:Gc};function qv(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 Zv(t){for(var e=1;e0)){t.next=36;break}return r.setBlockErrors(S),r.setIsLoading(!1),t.abrupt("return");case 36:return T=r.animateSpinToWin(),C=function(){var t=e(i().mark((function t(e){var o,s,a,c,l,u,p,d;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(a=null!==(o=r.blocksToRender.find((function(t){return t.type===It})))&&void 0!==o?o:{},c=a.id){t.next=3;break}throw new Error;case 3:return t.next=5,hf({country:r.currentCountry,phoneNumber:e,popupId:r.popup.id,sessionId:r.sessionId,shopId:r.shopId,source:Yv(r.viewport),sourceKey:r.popup.sourceKey});case 5:return l=t.sent,u=l.subscriberId,p=l.success,(d=!1===p)?r.setBlockErrors(Ka({},c,zm)):r.setBlockState(c,{error:null,isResendOtpSuccessVisible:!1}),t.abrupt("return",{hasError:d,nextStep:null!==(s=Vv({block:n,currentStepId:r.state.currentStepId,isExistingSubscriber:!!u,steps:r.popup.steps}))&&void 0!==s?s:null});case 11:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),O=function(){var t=e(i().mark((function t(e){var o,s,a,c,l,u,p,d,h,f,m,g,v,b,y,_;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(a=r.state.popupData[gn],c=null!==(o=r.blocksToRender.find((function(t){return t.type===Ot})))&&void 0!==o?o:{},l=c.id){t.next=4;break}throw new Error;case 4:return t.next=6,mf(r.shopId,a,e,r.popup.sourceKey);case 6:if(u=t.sent,p=mm(u),d=p.general,h=p.verification,!(f=!!d||!!h)&&null!=u&&u.data){t.next=14;break}d&&r.setBlockErrors(Ka({},l,zm)),!d&&h&&r.setBlockErrors(Ka({},l,Fm)),t.next=23;break;case 14:if(g=u.data,v=g.cashback_utm_code,b=g.coupon_code,y=g.subscriber_id,_=r.popup.autoApplyOfferEnabled,r.setBlockErrors(Ka({},l,null)),yf({subscriberId:+y}),df(!0,null===(m=r.shopId)||void 0===m?void 0:m.toString(),y.toString()),!_||!v){t.next=22;break}return t.next=22,fm(v);case 22:_&&b&&Gl(Cc,b);case 23:return t.abrupt("return",{hasError:f,nextStep:null!==(s=Vv({block:n,currentStepId:r.state.currentStepId,steps:r.popup.steps}))&&void 0!==s?s:null});case 24:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),I=null!==(k=Vv({block:n,currentStepId:r.state.currentStepId,steps:r.popup.steps}))&&void 0!==k?k:null,t.next=42,Fv({defaultNextStep:I,optInFn:C,persistAttributesFn:h,validatedStepData:E,verifyOtpFn:O});case 42:return A=t.sent,R=A.hasError,D=A.nextStep,t.next=47,T;case 47:r.setIsLoading(!1),!R&&D&&r.routeToStep(D,E);case 49:r.setIsLoading(!1);case 50:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()),this.currentCountry=o,this.disclaimer=s,this.enabledFeatureFlags=a,this.engagementTracker=_v((function(){return r.trackAnalyticsEvent(Dv)})),this.origin=c,this.popup=l,this.previousState=null,this.sessionId=u,this.state=function(t,e){var n,r=function(t){var e={};return t.teaserBlocks.forEach((function(t){e[t.id]={error:null,isResendOtpSuccessVisible:!1,selected:!1}})),e}(t);return{currentStepId:(null!==(n=t.steps.find((function(t){return 0===t.order})))&&void 0!==n?n:t.steps[0]).id,status:Gv(e),blockState:r,popupData:{subscriberProperties:{}},stepData:{}}}(l,d),this.shopId=p,this.subscriberId=h,this.viewport=f,this.preloadSrcAndBgImgs(),this.prepareTrigger()}return nc(t,[{key:"setState",value:function(t){this.previousState=eb({},this.state),this.state=eb(eb({},this.state),t),this.render()}},{key:"setBlockState",value:function(t,e){var n=eb({},this.state.blockState);n[t]=eb(eb({},n[t]),e),this.setState({blockState:n})}},{key:"setBlockErrors",value:function(t){var e=eb({},this.state.blockState);Object.entries(t).forEach((function(t){var n=Ja(t,2),r=n[0],i=n[1];e[r]={error:i,isResendOtpSuccessVisible:!1,selected:!1}})),this.setState({blockState:e})}},{key:"preloadSrcAndBgImgs",value:function(){var t=this,e=this.popup.steps.find((function(e){return e.id===t.state.currentStepId})),n=0===(null==e?void 0:e.order)?this.popup.stepBlocks.filter((function(e){return e.stepId===t.state.currentStepId})):qa(this.popup.stepBlocks),r=ks({stepBlocks:n,teaserBlocks:[],theme:this.popup.theme,viewport:this.viewport}),i=n.filter((function(t){return t.type===Ct})),o=function(t,e){for(var n=new Set,r=[t];r.length;){var i=r.pop();if("object"===Za(i)&&null!==i)for(var o=Object.entries(i),s=0;s0&&void 0!==arguments[0]&&arguments[0],e=!!t||!Wv({currentStepId:this.state.currentStepId,stepBlocks:this.popup.stepBlocks,steps:this.popup.steps});t||e||this.popup.closeBehavior===bn?this.setStatusToClosed():this.setStatusToTeaser()}},{key:"changeLocation",value:function(t){var e,n,r=(null!==(e=null===(n=t.config)||void 0===n?void 0:n.onClick)&&void 0!==e?e:{}).href;!Wv({currentStepId:this.state.currentStepId,stepBlocks:this.popup.stepBlocks,steps:this.popup.steps})&&this.closePopup(!0),r&&window.setParentLocation(r)}},{key:"routeToStep",value:function(t,e){var n;t.id===Lv&&this.closePopup(!0);var r,i,o,s,a=(r=this.popup,i=this.state.popupData,o=t.id,s=r.stepBlocks.filter((function(t){return t.stepId===o})),s.reduce((function(t,e){var n,r=(null!==(n=e.config)&&void 0!==n?n:{}).dataName;if(!r)return t;var o=r===gn||r===vn?i[r]:i.subscriberProperties[r];return o&&(t[e.id]=o),t}),{}));this.setState({currentStepId:t.id,stepData:a,popupData:eb(eb(eb({},this.state.popupData),null!=e?e:{}),{},{subscriberProperties:eb(eb({},this.state.popupData.subscriberProperties),null!==(n=null==e?void 0:e.subscriberProperties)&&void 0!==n?n:{})})})}},{key:"animateSpinToWin",value:function(){var t,e,n,r=this,i=this.blocksToRender.find((function(t){return t.type===Dt}));if(!i)return Promise.resolve();var o=parseInt(null!==(t=null===(e=ws(i,this.popup.theme,this.viewport))||void 0===e||null===(n=e[se.BLOCK])||void 0===n?void 0:n[Je])&&void 0!==t?t:"1000ms",10);return this.setBlockState(i.id,{isSpinning:!0}),function(t,e){return new Promise((function(n){setTimeout((function(){e(),n()}),t)}))}(o,(function(){r.setBlockState(i.id,{isSpinning:!1})}))}},{key:"trackAnalyticsEvent",value:function(t){var e,n=this.viewport===jt?"DESKTOP":"MOBILE";!function(t,e,n,r,i,o){var s="".concat("https://bicp-analytics.postscript.io","/api/v1/events"),a={country:null==r?void 0:r.toUpperCase(),event:t,platform:i,popup_id:n,shop_id:e};void 0!==o&&(a.split_test_id=o),navigator.sendBeacon(s,JSON.stringify(a))}(t,+this.shopId,this.popup.id,this.currentCountry,n,null===(e=this.popup.splitTest)||void 0===e?void 0:e.id)}},{key:"setPopupContainerInstance",value:function(t){this.popupContainer=null===t?null:document.querySelector("#".concat(Rv))}},{key:"focusFirstElement",value:function(){var t,e;null===(t=this.popupContainer)||void 0===t||null===(e=t.querySelector(":is(".concat(du,"):not([data-block-type=").concat(xt,"], .iti__selected-country)")))||void 0===e||e.focus({preventScroll:!0})}},{key:"renderHardClosed",value:function(){pt(null,document.body)}},{key:"renderTeaser",value:function(){var t=js(this.renderContext),e=jv(t);pt(e,document.body)}},{key:"renderPopup",value:function(){var t=this,e=js(this.renderContext),n=Nv(e,(function(){t.closePopup()}));pt(n,document.body)}},{key:"prerender",value:function(){var t,e,n,r=this,i=(null===(t=this.previousState)||void 0===t?void 0:t.status)===Uv,o=(null===(e=this.previousState)||void 0===e?void 0:e.status)===Mv,s=i||o,a=this.state.status===Mv,c=this.state.status===Uv,l=this.state.status===Bv,u=(null===(n=this.previousState)||void 0===n?void 0:n.status)===Mv&&this.state.status===Mv;s||!a&&!c||jl(),u&&this.preloadSrcAndBgImgs(),!this.previousState&&c&&Ll("","",(function(t,e){return Qv(r.popup,r.viewport,e)})),!o&&a&&(Ul((function(t){r.lastFocusedIframeElementId=t})),Nl()),l&&Ml()}},{key:"postrender",value:function(){var t,e,n,r,i=this,o=(null===(t=this.previousState)||void 0===t?void 0:t.status)!==Mv&&this.state.status===Mv,s=(null===(e=this.previousState)||void 0===e?void 0:e.status)!==Uv&&this.state.status===Uv,a=(null===(n=this.previousState)||void 0===n?void 0:n.status)===Uv,c=!this.previousState;if(o){var l;if(this.setPopupContainerInstance(),this.trackAnalyticsEvent(Pv),hc.getState().isPreview||(null===(r=document.getElementById(mc))||void 0===r||r.removeAttribute("aria-hidden"),window.parent.postMessage("HideElementsBehindPopupFromScreenReader","*")),c||a)null===(l=this.popupContainer)||void 0===l||l.addEventListener("animationend",(function(){i.focusFirstElement()}),{once:!0});a?this.trackAnalyticsEvent(Dv):this.startEngagementTracker()}if((o||s)&&Bl(),s){var u,p,d=null===(u=this.popup.teaserBlocks.find((function(t){return t.type===$t})))||void 0===u?void 0:u.id,h=null===(p=this.popup.teaserBlocks.find((function(t){return t.type===Pt})))||void 0===p?void 0:p.id;setTimeout((function(){Ll("teaser-".concat(h),"teaser-".concat(d),(function(t,e){return Qv(i.popup,i.viewport,e)}))}),0)}}},{key:"render",value:function(){this.prerender(),this.state.status===Bv?this.renderHardClosed():this.state.status===Uv?this.renderTeaser():this.renderPopup(),this.postrender()}}]),t}(),ib=function(){var t=e(i().mark((function t(e,n,r,o,s,a,c,l){var u,p,d,h,f,m,g,v,b;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(u=hc.getState(),p=u.disclaimer,d=u.flags,p){t.next=3;break}return t.abrupt("return",!1);case 3:return t.prev=3,t.next=6,Kv(a);case 6:if(f=t.sent,m=iu(f,l),g=au({blockPopups:m,currentCountry:n,origin:r,statuses:e,subscriberId:s}),v=cu(g,Pc)){t.next=12;break}return t.abrupt("return",!1);case 12:return t.t0=Rs,t.t1=v,t.t2=c,t.next=17,Jv(a);case 17:return t.t3=t.sent,(0,t.t0)(t.t1,t.t2,t.t3),b=ql(yc,v.id,e),new rb({currentCountry:n,disclaimer:p,enabledFeatureFlags:null!==(h=null==d?void 0:d.split(","))&&void 0!==h?h:[],origin:r,popup:v,sessionId:o,shopId:a,status:null!=b?b:null,subscriberId:s,theme:v.theme,viewport:c}),t.abrupt("return",!0);case 24:return t.prev=24,t.t4=t.catch(3),console.error("Error initializing block popups: ".concat(t.t4)),Ha(t.t4),t.abrupt("return",!1);case 29:case"end":return t.stop()}}),t,null,[[3,24]])})));return function(e,n,r,i,o,s,a,c){return t.apply(this,arguments)}}(),ob=ib;(nb=e(i().mark((function t(){var e,n,r,o,s,a,c,l,u,p,d,h;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,eh();case 2:if(e=t.sent,n=e.shopId,r=e.status,o=e.origin,s=e.sessionId,a=e.previewData,c=e.splitTestCookies,l=e.currentCountry,u=e.subscriberId,!a){t.next=14;break}return Ov(a,n,r,s),t.abrupt("return");case 14:return t.next=16,ob(r,l,o,s,u,n,jt,c);case 16:if(!t.sent){t.next=18;break}return t.abrupt("return");case 18:return t.next=20,lu(n,"desktop");case 20:if(0!==(p=t.sent).length){t.next=23;break}return t.abrupt("return");case 23:d=iu(p,c),Eu(d,r,o,l,u,h=function(t){return Av(t,n,r,s,a,l)}),Tu(d,r,o,l,u,h),Su({popups:p,shopId:n,statuses:r,origin:o,sessionId:s,previewData:a,initializePopup:Av});case 28:case"end":return t.stop()}}),t)}))),function(){return nb.apply(this,arguments)})()}()}(); //# sourceMappingURL=desktop.bundle.js.map