capitalconnect

main

(function(w){ const define = undefined; const require = undefined; !function(e){“object”==typeof exports&&”undefined”!=typeof module?module.exports=e():”function”==typeof define&&define.amd?define([],e):(“undefined”!=typeof window?window:”undefined”!=typeof global?global:”undefined”!=typeof self?self:this).__DTCHE=e()}(function(){return function o(n,r,a){function s(t,e){if(!r[t]){if(!n[t]){var i=”function”==typeof require&&require;if(!e&&i)return i(t,!0);if(l)return l(t,!0);throw(e=new Error(“Cannot find module ‘”+t+”‘”)).code=”MODULE_NOT_FOUND”,e}i=r[t]={exports:{}},n[t][0].call(i.exports,function(e){return s(n[t][1][e]||e)},i,i.exports,o,n,r,a)}return r[t].exports}for(var l=”function”==typeof require&&require,e=0;e{var t=(0,r.detectGoogleTagManagerInst)(this.window);t&&t[e.event](e.payload)}),this.window.addEventListener(“beforeunload”,()=>{this.destroy()}),this.handleIframeLoad=()=>{var e=this.window.document.getElementById(this.getSpinnerWrapperId());e&&e.classList.remove(“loading”)}}injectStyles(){var e=this.window.document.createElement(“style”);e.type=”text/css”,e.id=”dutchie–embed__styles”;let t=””;this.disableCustomStyles||(t=(t+=this.options.iframeCss||””)+(this.options.pageCss||””)),e.innerHTML=t,this.window.document.head.appendChild(e)}preventExtraDOMNodes(){var e=new MutationObserver(e=>{e.forEach(e=>{“childList”===e.type&&(e=this.window.document.getElementById(this.getEmbedContainerId()))&&Array.from(e.childNodes).filter(e=>e!==this.iframe&&e.id!==this.getSpinnerWrapperId()).forEach(e=>{(0,r.dutchieLogger)(“Removing unauthorized DOM node from “+this.getEmbedContainerId()),e.remove()})})}),t=this.window.document.getElementById(this.getEmbedContainerId());t&&e.observe(t,{childList:!0,subtree:!1}),this.containerObserver=e}updateFullScreenCheckout(e,t){this.featureFlags.forceFullWidthCheckoutEnabled&&this.options.enableFullScreenEmbeddedCheckout&&this.updateContainerPosition(e,t)}updateContainerPosition(e,t){var i,o=this.window.document.getElementById(this.getEmbedContainerId()),n=this.window.document.getElementById(this.getIframeId()),r=null==o?void 0:o.querySelector(“#”+this.getSpinnerWrapperId());o&&n&&(i=e&&!this.originalContainerPosition||!e&&this.originalContainerPosition,r&&i&&r.classList.add(“loading”),t&&i?n.src=this.constructIframeUrl(t):r&&i&&r.classList.remove(“loading”),e?this.moveContainerToBody(o):this.restoreContainerPosition(o))}moveContainerToBody(e){this.originalContainerPosition||(this.originalContainerPosition={previousSibling:e.previousElementSibling,nextSibling:e.nextElementSibling,parent:e.parentElement},this.window.document.body.insertBefore(e,this.window.document.body.firstChild))}restoreContainerPosition(e){var t,i,o;this.originalContainerPosition&&({previousSibling:t,nextSibling:i,parent:o}=this.originalContainerPosition,i?o.insertBefore(e,i):t?t.after(e):o.appendChild(e),this.originalContainerPosition=null)}injectIframe(){var e,t=this.window.document.createElement(“iframe”),i=(t.className=this.options.iframeClass,t.id=this.getIframeId(),t.frameBorder=”0″,t.title=this.getIframeTitle(),this.window.document.createElement(“div”)),o=(i.id=this.getEmbedContainerId(),i.style=”width: 100%; box-sizing: border-box;”,this.featureFlags.forceFullWidthCheckoutEnabled&&this.options.enableFullScreenEmbeddedCheckout&&((e=this.window.document.createElement(“div”)).id=this.getSpinnerWrapperId(),e.className=””,(o=this.window.document.createElement(“div”)).id=this.getSpinnerId(),o.setAttribute(“role”,”status”),o.setAttribute(“aria-label”,”Loading”),e.appendChild(o),i.appendChild(e)),i.appendChild(t),this.embedScriptTag.insertAdjacentElement(“afterend”,i),t.addEventListener(“load”,this.handleIframeLoad),t.src=this.initialFrameURL(),t.allow=”camera;microphone;geolocation;gyroscope;web-share”,”width: 100%; min-width: 100%; border: none;”);try{t.style=o}catch(e){t.style.cssText=o}this.iframe=t,this.featureFlags.forceFullWidthCheckoutEnabled&&this.preventExtraDOMNodes()}iFrameSEOSetup(){var e;this.isSearchEngineBot&&(this.window.document.title=””,null!=(e=this.window.document.querySelector(‘link[rel=”canonical”]’))&&e.remove(),this.embedScriptTag.setAttribute(“data-ua”,null==(e=navigator)?void 0:e.userAgent))}enableIframeSEO(){this.isSearchEngineBot&&(this.setTimingInterval(),this.setFakeRequestInterval())}cleanupIframeSEO(){clearInterval(this.timingInterval),clearInterval(this.fakeRequestInterval)}cleanupContainerObserver(){this.containerObserver&&(this.containerObserver.disconnect(),this.containerObserver=null)}setFeatureFlags(e){this.featureFlags=e||{},this.featureFlagsReady=!0}sendParentUrl(e){e=e?””+this.window.location.origin+e:this.window.location.href;this.sendPayload({event:”embed:setParentUrl”,url:””+this.window.location.origin+this.window.location.pathname,href:e})}setTimingInterval(){let e=0;this.timingInterval=setInterval(()=>{e+=1,this.embedScriptTag.setAttribute(“data-t”,e),20===e&&clearInterval(this.timingInterval)},1e3)}setFakeRequestInterval(){let e=0;this.fakeRequestInterval=setInterval(()=>{e+=1;try{fetch(“https://seo-utils.dutchie.com/sleep?ms=250”).then(e=>{e.ok||(0,r.dutchieLogger)(e.statusText)})}catch(e){(0,r.dutchieLogger)(e)}80===e&&clearInterval(this.fakeRequestInterval)},250)}setSeoPayloadDebugging(e,t){this.embedScriptTag.setAttribute(“data-existing-title”,t.document.title),this.embedScriptTag.setAttribute(“data-new-title”,e.title),this.embedScriptTag.setAttribute(“data-url”,t.location.href)}handleMessage(e){if(“analytics:ga_event”===e.event)return a.broadcast(e.payload),!0;if(“analytics:ga_dimensions”===e.event)return s.broadcast(e.payload),!0;if(“analytics:dataLayer”===e.event)return l.broadcast(e.payload),!0;if(“route:changing”===e.event){var t=(null==e?void 0:e.payload).url;if(t)return this.window.location.href=t,!0}return”seobot:elevate”===e.event?(this.setSeoPayloadDebugging(e.payload,this.window),(0,r.injectIframePayload)(e.payload,this.window,this.iframe),this.cleanupIframeSEO(),!0):”embeddedCarousel:setHeight”===e.event&&({carouselId:t,height:e}=e.payload,t===(null==(t=this.options)?void 0:t.carouselId)&&(this.iframe.style.height=e+”px”),!0)}enableEventListener(){this.window.addEventListener(“message”,t=>{var i=t.message?”message”:”data”;let e;if(t[i]&&”string”==typeof t[i]){try{e=JSON.parse(t[i])}catch(e){return(0,r.dutchieLogger)(“Could not parse event payload”,t[i]),void(0,r.dutchieLogger)(e)}this.handleMessage(e)}},!1)}ensureFeatureFlagsReady(t=5e3){var e,i;return this.featureFlagsReady||0===Object.keys(this.featureFlags).length?Promise.resolve():(e=new Promise(e=>{let t=()=>{this.featureFlagsReady?e():setTimeout(t,50)};t()}),i=new Promise(e=>{setTimeout(()=>{(0,r.dutchieLogger)(“DUTCHIE WARN: Feature flags did not become ready within the timeout period. Using default configuration.”);let t={forceFullWidthCheckoutEnabled:!1};Object.keys(t).forEach(e=>{void 0===this.featureFlags[e]&&(this.featureFlags[e]=t[e])}),this.featureFlagsReady=!0,e()},t)}),Promise.race([e,i]))}sendPayload(e){this.iframe&&this.iframe.contentWindow&&this.iframe.contentWindow.postMessage(JSON.stringify(e),”*”)}async boot(){this.embedScriptTag?(this.enableEventListener(),this.injectStyles(),await this.ensureFeatureFlagsReady(),this.injectIframe()):(0,r.dutchieLogger)(`DUTCHIE ERROR: Could not locate ${this.getScriptId()} tag.`)}destroy(){this.cleanupContainerObserver(),this.iframe&&this.iframe.removeEventListener(“load”,this.handleIframeLoad)}constructIframeUrl(e){return e?this.initialFrameURL().split(“?”)[0]+((e=e.includes(“?”)?e.split(“?”)[1]:””)?”?”+e:””):this.initialFrameURL()}}},{“../embedded-utils”:5,”@babel/runtime/helpers/defineProperty”:1,”@babel/runtime/helpers/interopRequireDefault”:2,”geval/event”:14}],5:[function(e,t,i){function n(e){let t=0,i=0;for(;e&&!isNaN(e.offsetLeft)&&!isNaN(e.offsetTop);)t+=e.offsetLeft,i+=e.offsetTop,e=e.offsetParent;return{top:i,left:t}}function o(t){var e;if(“function”==typeof URLSearchParams)return(e=new URLSearchParams(window.location.search)).has(t)?e.get(t):null;var i=window.location.search.substring(1).split(“&”);for(let e=0;e“function”==typeof t[e]);return t[e]},i.detectGoogleTagManagerInst=function(t){var e=[“dataLayer”].find(e=>void 0!==t[e]&&”function”==typeof t[e].push);return t[e]},i.dutchieLogger=function(e){(window.__DUTCHIE_DEBUG||o(“dtche[debug]”))&&console.log(“%c “+e,’background: url(“https://dutchie.com/favicon.ico”) no-repeat; color: #000; padding: 3px 0 3px 10px;’)},i.getBackToTopOffset=function(e){let o=n(e).top,t=Array.from(document.querySelectorAll(“*”)).filter(e=>{var t,i;return!(null!=(t=(i=e.id).startsWith)&&t.call(i,”dutchie–“)||”fixed”!==(i=(t=getComputedStyle(e)).getPropertyValue(“position”))&&”sticky”!==i||”none”===t.getPropertyValue(“display”)||”hidden”===t.getPropertyValue(“visibility”)||”0″===t.getPropertyValue(“opacity”))}).reduce((e,t)=>{var{height:t,top:i}=t.getBoundingClientRect(),t=t+i;return i<=0&&t<=o?Math.max(t,e):e},0);return Math.max(0,o-t)},i.getOffset=n,i.getQueryMap=function(e){let i=new RegExp(`^${e}\\[(.*)\\]$`),o={};if("function"==typeof URLSearchParams)new URLSearchParams(window.location.search).forEach((e,t)=>{t=i.exec(t);t&&(o[t[1]]=e)});else{var t=window.location.search.substring(1).split(“&”);for(let e=0;e{var t=o.createElement(e.tag);t.type=e.type,t.innerHTML=e.content,o.head.appendChild(t)}),e.body&&i.insertAdjacentHTML(“afterend”,`
${e.body}
`);var n=o.querySelector(‘link[rel=”canonical”]’),e=e.canonicalUrl??t.location.href;n?n.setAttribute(“href”,e):((t=o.createElement(“link”)).setAttribute(“rel”,”canonical”),t.setAttribute(“href”,e),o.head.appendChild(t));i.remove()},i.isSearchEngineBot=i.isGooglebot=i.isDuckduckgobot=i.isBingbot=void 0;let r=()=>”undefined”!=typeof navigator&&/googlebot/i.test(navigator.userAgent),a=(i.isGooglebot=r,()=>”undefined”!=typeof navigator&&/bingbot/i.test(navigator.userAgent)),s=(i.isBingbot=a,()=>”undefined”!=typeof navigator&&/duckduckbot/i.test(navigator.userAgent));i.isDuckduckgobot=s;i.isSearchEngineBot=()=>r()||a()||s()},{}],6:[function(e,t,i){var o=e(“@babel/runtime/helpers/interopRequireDefault”),a=(Object.defineProperty(i,”__esModule”,{value:!0}),i.createBackToTopButton=function(e){let{options:{primaryColor:t},iframe:i}=e,o=document.createElement(“button”),n=(0,a.getOffset)(i).top,r=l(e=>{o.className=e?”visible”:””},n);return d(),o.ariaLabel=”Scroll to top”,o.id=”dutchie–back-to-top”,o.innerHTML=` `,o.style.backgroundColor=t,s.default.onScroll(r),o.addEventListener(“click”,()=>{s.default.scrollTo({left:0,top:(0,a.getBackToTopOffset)(i),behavior:”smooth”}),o.className=””}),o},i.createScrollHandler=void 0,i.injectStyles=d,e(“../embedded-utils”)),n=e(“./styles”),s=o(e(“./window-context”));let l=(i,o=0)=>{let n=s.default.pageYOffset,r=s.default.pageYOffset,a=!1;return()=>{var e=s.default.pageYOffset;let t=o+20{try{t()}catch(e){console.warning(“Failed to run compatibility fix:”,t.name),console.warning(e)}})}Object.defineProperty(i,”__esModule”,{value:!0}),i.default=function(){r(n)},i.removeNiceScroll=n,i.runAllCompatibilityFixes=r,o(e(“smoothscroll-polyfill”)).default.polyfill()},{“@babel/runtime/helpers/interopRequireDefault”:2,”smoothscroll-polyfill”:3}],8:[function(e,t,i){Object.defineProperty(i,”__esModule”,{value:!0}),i.createFullScreenCheckoutStyles=function(){null!=(e=document.getElementById(n))&&e.remove();var e=document.createElement(“style”);return e.id=n,e.innerHTML=o.FullScreenCheckoutStyles,e};var o=e(“./styles”);let n=”dutchie–fullscreen_checkout_styles”},{“./styles”:12}],9:[function(e,t,i){var o=e(“@babel/runtime/helpers/interopRequireDefault”),n=(Object.defineProperty(i,”__esModule”,{value:!0}),i.DutchieEmbedder=void 0,o(e(“@babel/runtime/helpers/defineProperty”))),s=e(“../embedded-utils”),r=e(“./back-to-top”),a=e(“./fullscreen-checkout”),l=e(“./skip-to-menu”),d=e(“./loading-spinner”),c=o(e(“./compatibility-fixes”)),u=o(e(“./window-context”)),o=o(e(“../embed-class”));class h extends o.default{getFullscreenEnabledClass(){return”dutchie–is-fullscreen-enabled”}getIsFullscreenClass(){return”dutchie–is-fullscreen”}constructor(e,t={}){super(e,t),(0,n.default)(this,”onClickHandlerLoginClick”,null),(0,n.default)(this,”setUserDetails”,e=>{this.sendPayload({event:”embed:setUserDetails”,userDetails:e})}),this.options.shouldAutoScroll=!!this.options.autoScroll,this.options.hasAutoScrollOffset=!!parseInt(this.options.autoScrollOffset,10),this.options.shouldUseRouting=!this.options.disableRouting,this.initialState={documentTitle:e.document.title,documentMetaDescription:null==(t=this.getMetaDescription())?void 0:t.content},this.handleIframeLoad=()=>{var t=this.window.document.getElementById(this.getSpinnerWrapperId());if(t&&t.classList.remove(“loading”),this.iframe){let e=Math.max(270,u.default.innerHeight);this.isInIframe&&(this.originalWindowHeight?e=this.originalWindowHeight:this.originalWindowHeight=e);t=(0,s.getOffset)(this.iframe).top,t={width:window.innerWidth,height:e,offsetTop:t,offset:Math.max(0,t-window.pageYOffset),parentOffset:window.pageYOffset-t};this.sendPayload({event:”embed:events:viewport”,viewport:t})}}}registerClickHandlerLogin(e){this.sendPayload({event:”embed:registerClickHandler:login”}),this.onClickHandlerLoginClick=()=>e(this.setUserDetails)}getMetaDescription(){let e=this.window.document.querySelector(“meta[name=’description’]”);return e||((e=this.window.document.createElement(“meta”)).name=”description”,e.content=””,this.window.document.head.appendChild(e)),e}setIframeHeight(e=”100vh”,t=!1){t=`width: 100%; min-width: 100%; height: ${e=Number(e).toString()===e.toString()?t?e:Math.max(u.default.innerHeight,e):e}px !important; border: none;`;try{this.iframe.style=t}catch(e){this.iframe.style.cssText=t}this.onSetHeight&&this.onSetHeight(e)}injectBackToTop(){var e=(0,r.createBackToTopButton)(this);this.iframe.insertAdjacentElement(“afterend”,e)}injectSkipToMenu(){var e=(0,l.createSkipToMenuButton)(this);this.window.document.body.prepend(e)}injectCheckoutStyles(){var e=(0,a.createFullScreenCheckoutStyles)();this.window.document.head.appendChild(e)}injectLoadingSpinnerStyles(){var e=(0,d.createLoadingSpinnerStyles)();this.window.document.head.appendChild(e)}initialFrameURL(){var{cName:e,chainLocations:t,urlBase:i,hideTitle:o}=this.options;let n=i+`/embedded-menu/${e}/`+(t?”locations”:””),r={},a=((0,s.getQueryVariable)(“dtche”)?n=this.options.urlBase+”/”+decodeURIComponent((0,s.getQueryVariable)(“dtche”)):(i=(0,s.getQueryMap)(“dtche”),t&&(i.location?(n=n.replace(this.options.cName+”/locations”,i.location),delete i.location):0{(0,s.getQueryVariable)(e)&&a.append(e,(0,s.getQueryVariable)(e))}),this.parentGATracker&&((t=null==(e=this.parentGATracker)?void 0:e.get(“linkerParam”))?a.append(“_ga”,t.replace(“_ga=”,””)):(e=null==(i=this.parentGATracker)?void 0:i.get(“clientId”),a.append(“__ga_clientId”,e))),o&&a.append(“hideTitle”,o),n+”?”+a.toString()}enableScrollListener(){this.window.addEventListener(“scroll”,()=>{this.iframe&&(this.scrollTimerId&&clearTimeout(this.scrollTimerId),this.scrollTimerId=setTimeout(()=>{this.isScrolling=!1,this.sendPayload({event:”embed:events:scroll-end”})},110),this.isScrolling||(this.isScrolling=!0,this.sendPayload({event:”embed:events:scroll-start”})))})}onChildRouteChanged({fullPath:e,embeddedPath:t,query:i,cName:o}){var n=this.window.location.pathname;let r=new URLSearchParams(window.location.search);[…r.keys()].forEach(e=>{e.startsWith(“dtche”)&&r.delete(e)}),e?r.append(“dtche”,e):t&&”/”!==t&&r.append(“dtche[path]”,t),i&&Object.keys(i).filter(e=>”menuType”!==e).forEach(e=>{r.append(`dtche[${e}]`,i[e])}),this.options.chainLocations&&o&&(t&&”locations”===t.split(“/”)[0]||r.append(“dtche[location]”,o)),this.isV3Preview&&r.append(“v3-preview”,!0),this.disableCustomStyles&&null===(0,s.getQueryVariable)(“disable-custom-styles”)&&r.append(“disable-custom-styles”,!0);e=Array.from(r).length?n+”?”+r.toString():n,t=””+n+this.window.location.search;this.sendParentUrl(e),e!==this.lastDutchiePathChange&&e!==t&&(this.lastDutchiePathChange=e,this.window.history.replaceState({},””,e)),e.includes(“checkout”)||e.includes(“pay%2Fsignup”)&&this.featureFlags.forceFullWidthCheckoutEnabled?(this.window.document.body.classList.add(this.getIsFullscreenClass()),this.options.enableFullScreenEmbeddedCheckout&&this.updateFullScreenCheckout(!0,e)):(this.window.document.body.classList.remove(this.getIsFullscreenClass()),this.options.enableFullScreenEmbeddedCheckout&&this.updateFullScreenCheckout(!1,e))}handleMessage(e){var t;return!(!super.handleMessage(e)&&(“route:changed”===e.event&&this.options.shouldUseRouting?(this.onChildRouteChanged(e.payload),0):”product:viewed”===e.event?(this.window.document.title=e.payload.dispensaryName+” – “+e.payload.productName,this.getMetaDescription().content=””+e.payload.productName,0):”current-product:description:loaded”===e.event?(this.getMetaDescription().content=””+e.payload.Description,0):”product:closed”===e.event?(this.lastDutchiePathChange=null,this.window.document.title=this.initialState.documentTitle,this.getMetaDescription().content=this.initialState.documentMetaDescription,0):”iframe:resize”===e.event||”iframe:resize:override”===e.event?(t=”iframe:resize:override”===e.event,this.setIframeHeight(e.payload.height,t),0):”iframe:scrollToTop”===e.event?(this.options.disablePageLoadsAtTop&&!e.payload.force||(t=(0,s.getBackToTopOffset)(this.iframe),u.default.scrollY<=t&&!e.payload.force)||u.default.scrollTo({left:0,top:t,behavior:"auto"}),0):"iframe:goBack"===e.event?(e.payload.skipScroll||u.default.scrollTo({left:0,top:(null==(t=e.payload)?void 0:t.y)??0,behavior:"auto"}),0):"iframe:ready"===e.event?(this.onReady(e.payload),0):"embed:clickHandler:login"!==e.event||(this.onClickHandlerLoginClick(),0)))}enableHistoryListener(){this.window.onpopstate=()=>{let e;var t;(e=(0,s.getQueryVariable)(“dtche”)?decodeURIComponent((0,s.getQueryVariable)(“dtche”)):this.options.iframeURL)&&e!==this.lastDutchiePathChange&&(t={event:”embed:events:route”,path:this.lastDutchiePathChange=e},this.sendPayload(t))}}updateViewport(e){let t=!1;this.previousWidth!==e.width&&(this.previousWidth=e.width,t=!0),this.previousHeight!==e.height&&(this.previousHeight=e.height,t=!0),this.previousOffset!==e.offset&&(this.previousOffset=e.offset,t=!0),this.previousParentOffset!==e.parentOffset&&(this.previousParentOffset=e.parentOffset,t=!0),this.previousOffsetTop!==e.offsetTop&&(this.previousOffsetTop=e.offsetTop,t=!0),t&&this.sendPayload({event:”embed:events:viewport”,viewport:e})}enableViewportListener(){let t=Math.max(270,u.default.innerHeight);this.isInIframe&&(this.originalWindowHeight?t=this.originalWindowHeight:this.originalWindowHeight=t);var e=()=>{var e=(0,s.getOffset)(this.iframe).top,e={width:window.innerWidth,height:t,offsetTop:e,offset:Math.max(0,e-window.pageYOffset),parentOffset:window.pageYOffset-e};this.updateViewport(e)};window.addEventListener(“scroll”,e),window.addEventListener(“resize”,e),e()}onReady(e){!this.isReady&&(this.options={…this.options,…e},this.isReady=!0,this.enableViewportListener(),this.enableScrollListener(),this.sendParentUrl(),this.sendPayload({event:”embed:previewMode”,previewMode:this.options.previewMode}),this.sendPayload({event:”embed:ready”}),this.injectSkipToMenu(this),this.options.disablePageLoadsAtTop||this.injectBackToTop(),this.injectCheckoutStyles(),this.options.enableFullScreenEmbeddedCheckout&&this.featureFlags.forceFullWidthCheckoutEnabled&&this.window.document.body.classList.add(this.getFullscreenEnabledClass()),this.onClickHandlerLoginClick&&this.sendPayload({event:”embed:registerClickHandler:login”}),e=this.window.document.getElementById(this.getSpinnerWrapperId()))&&e.classList.remove(“loading”)}async boot(e={}){if(this.embedScriptTag){null===(0,s.getQueryVariable)(“disable-custom-styles”)&&!this.options.previewMode||(this.disableCustomStyles=!0),null!==(0,s.getQueryVariable)(“v3-preview”)&&(this.isV3Preview=!0),e.onSetHeight&&(this.onSetHeight=e.onSetHeight),e.featureFlags&&this.setFeatureFlags(e.featureFlags),u.default.setup(e);let o=async()=>{this.didBoot||(this.didBoot=!0,(0,c.default)(),this.injectLoadingSpinnerStyles(),this.injectStyles(),await this.ensureFeatureFlagsReady(),this.injectIframe(),this.enableIframeSEO(),this.enableEventListener(),this.enableHistoryListener())},n=(0,s.detectGoogleAnalyticsInst)(this.window);if(n){let i=window.setTimeout(()=>o(),2500);n(e=>{if(e)this.parentGATracker=e;else try{var t;this.parentGATracker=null==(t=n.getAll())?void 0:t[0]}catch(e){(0,s.dutchieLogger)(“Could not load any trackers for parent frame.”)}clearTimeout(i),o()})}else(0,s.dutchieLogger)(“Could not locate a Google Analytics instance.”),o()}else(0,s.dutchieLogger)(`DUTCHIE ERROR: Could not locate ${this.getScriptId()} tag.`)}}i.DutchieEmbedder=h},{“../embed-class”:4,”../embedded-utils”:5,”./back-to-top”:6,”./compatibility-fixes”:7,”./fullscreen-checkout”:8,”./loading-spinner”:10,”./skip-to-menu”:11,”./window-context”:13,”@babel/runtime/helpers/defineProperty”:1,”@babel/runtime/helpers/interopRequireDefault”:2}],10:[function(e,t,i){Object.defineProperty(i,”__esModule”,{value:!0}),i.createLoadingSpinnerStyles=function(){null!=(e=document.getElementById(n))&&e.remove();var e=document.createElement(“style”);return e.type=”text/css”,e.id=n,e.innerHTML=o.IframeLoadingSpinnerStyles,e};var o=e(“./styles”);let n=”dutchie–loading_spinner_styles”},{“./styles”:12}],11:[function(e,t,i){Object.defineProperty(i,”__esModule”,{value:!0}),i.createSkipToMenuButton=function(){var e=document.createElement(“button”);return e.id=s,e.textContent=l,e.ariaLabel=l,e.onclick=d,(()=>{null!=(e=document.getElementById(a))&&e.remove();var e=document.createElement(“style”);e.type=”text/css”,e.id=a,e.innerHTML=o.SkipToMenuStyles,document.head.appendChild(e)})(),e};var o=e(“./styles”);let n=”#main-content”,r=”#dutchie–embed__iframe”,a=”dutchie–skip_to_menu_styles”,s=”dutchie–skip-to-menu”,l=”Skip to menu”;function d(){var e=null==(e=document.querySelector(r))?void 0:e.contentWindow;null!=e&&e.document.querySelector(n)&&(e.focus(),e.location.hash=n)}},{“./styles”:12}],12:[function(e,t,i){Object.defineProperty(i,”__esModule”,{value:!0}),i.SkipToMenuStyles=i.IframeLoadingSpinnerStyles=i.FullScreenCheckoutStyles=i.BackToTopStyles=void 0;i.BackToTopStyles=` #dutchie–back-to-top.visible { opacity: 1; pointer-events: initial; cursor: pointer; } #dutchie–back-to-top:focus-visible { opacity: 1; pointer-events: initial; cursor: pointer; } #dutchie–back-to-top { appearance: none; animation : none; animation-delay : 0; animation-direction : normal; animation-duration : 0; animation-fill-mode : none; animation-iteration-count : 1; animation-name : none; animation-play-state : running; animation-timing-function : ease; backface-visibility : visible; background-attachment : scroll; background-clip : border-box; background-color : transparent; background-image : none; background-origin : padding-box; background-position : 0 0; background-position-x : 0; background-position-y : 0; background-repeat : repeat; background-size : auto auto; border : 0; border-style : none; border-width : medium; border-color : inherit; border-bottom : 0; border-bottom-color : inherit; border-bottom-style : none; border-bottom-width : medium; border-collapse : separate; border-image : none; border-left : 0; border-left-color : inherit; border-left-style : none; border-left-width : medium; border-right : 0; border-right-color : inherit; border-right-style : none; border-right-width : medium; border-spacing : 0; border-top : 0; border-top-color : inherit; border-top-style : none; border-top-width : medium; box-shadow : none; box-sizing : content-box; caption-side : top; clear : none; clip : auto; color : inherit; columns : auto; column-count : auto; column-fill : balance; column-gap : normal; column-rule : medium none currentColor; column-rule-color : currentColor; column-rule-style : none; column-rule-width : none; column-span : 1; column-width : auto; content : normal; counter-increment : none; counter-reset : none; cursor : auto; direction : ltr; display : inline; empty-cells : show; float : none; font : normal; font-family : inherit; font-size : medium; font-style : normal; font-variant : normal; font-weight : normal; hyphens : none; letter-spacing : normal; line-height : normal; list-style : none; list-style-image : none; list-style-position : outside; list-style-type : disc; margin : 0; margin-bottom : 0; margin-left : 0; margin-right : 0; margin-top : 0; max-height : none; max-width : none; min-height : 0; min-width : 0; opacity : 1; orphans : 0; outline : 0; outline-color : invert; outline-style : none; outline-width : medium; overflow : visible; overflow-x : visible; overflow-y : visible; padding-bottom : 0; padding-left : 0; padding-right : 0; padding-top : 0; page-break-after : auto; page-break-before : auto; page-break-inside : auto; perspective : none; perspective-origin : 50% 50%; right : auto; tab-size : 8; table-layout : auto; text-align : inherit; text-align-last : auto; text-decoration : none; text-decoration-color : inherit; text-decoration-line : none; text-decoration-style : solid; text-indent : 0; text-shadow : none; text-transform : none; transform : none; transform-style : flat; transition : none; transition-delay : 0s; transition-duration : 0s; transition-property : none; transition-timing-function : ease; unicode-bidi : normal; vertical-align : baseline; visibility : visible; white-space : normal; widows : 0; word-spacing : normal; z-index : auto; /* basic modern patch */ all: initial; all: unset; /* styles */ width: 40px; height: 40px; border-radius: 7px; position: fixed; bottom: 19px; left: calc(50% – 20px); text-align: center; opacity: 0; pointer-events: none; transition: opacity 0.2s; display: flex; align-items: center; justify-content: center; } #dutchie–back-to-top svg { position: relative; height: 8.5px; width: 14px; fill: white; transform: rotate(-180deg); margin-bottom: 1px; } `,i.SkipToMenuStyles=` #dutchie–skip-to-menu { position: absolute; margin: 0; width: 1px; height: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); } #dutchie–skip-to-menu:focus-visible { z-index: 9999999999; width: auto; height: auto; clip: auto; padding: 15px; background-color: #153F66; color: #FFF; font-weight: bold; outline: 2px solid #FF3E51; left: 2px; top: 2px; } `,i.FullScreenCheckoutStyles=` .dutchie–is-fullscreen.dutchie–is-fullscreen-enabled { overflow-y: hidden; } .dutchie–is-fullscreen.dutchie–is-fullscreen-enabled #dutchie–embed__container { position: fixed !important; top: 0 !important; left: 0 !important; margin: 0 !important; padding: 0 !important; width: 100vw !important; height: 100vh !important; z-index: 9999999999 !important; overflow-y: scroll !important; } `,i.IframeLoadingSpinnerStyles=` @keyframes spin-pulse { 0% { transform: rotate(0deg) scale(1); } 50% { transform: rotate(180deg) scale(0.8); } 100% { transform: rotate(360deg) scale(1); } } #dutchie–embed__spinner-wrapper { position: absolute; top: 0; left: 0; width: 100%; height: 100%; display: none; align-items: center; justify-content: center; z-index: 9999999999; } #dutchie–embed__container { position: relative; } .dutchie–is-checkout.dutchie–is-fullscreen #dutchie–embed__spinner-wrapper { position: fixed; height: 100vh; } #dutchie–embed__spinner-wrapper.loading { display: flex; } #dutchie–embed__spinner { width: 55px; height: 55px; border-radius: 100%; border-width: 2px; border-style: solid; border-color: rgb(75, 75, 75) rgb(75, 75, 75) transparent; border-image: initial; display: inline-block; animation: spin-pulse 0.75s linear 0s infinite normal both running; transform-origin: center; } `},{}],13:[function(e,t,i){var o=e(“@babel/runtime/helpers/interopRequireDefault”),n=(Object.defineProperty(i,”__esModule”,{value:!0}),i.default=void 0,o(e(“geval”)));let r={scrollEvent(e){window.addEventListener(“scroll”,e)}};function a(t){try{return t.parent&&t.parent!==t?0
Scroll to Top