PageSourceSearch

https://www.riverisland.com/Assets/RiverIsland/Core/ui/dist/navigation-header-8b14b7a9c6fc6ee5d760.js

js riverisland.com collected 2026-09-24 15:19:41 UTC 87,463 bytes, 3 lines download raw bytes

1/*! For license information please see navigation-header-8b14b7a9c6fc6ee5d760.js.LICENSE.txt */
2(globalThis.riCoreJsonpFunction=globalThis.riCoreJsonpFunction||[]).push([[177],{93295:(e,t,n)=>{"use strict";n.d(t,{A:()=>i});const i=function(){return-1!==document.cookie.indexOf("uprops")}},59422:(e,t,n)=>{"use strict";function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function r(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,o(i.key),i)}}function o(e){var t=function(e){if("object"!=i(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=i(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==i(t)?t:t+""}function a(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(a=function(){return!!e})()}
2function s(e){return s=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},s(e)}function c(e,t){return c=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},c(e,t)}n.d(t,{A:()=>l});var u=function(e){function t(e){var n,r,o,c,u=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(r=this,o=t,c=[e],o=s(o),n=function(e,t){if(t&&("object"===i(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(r,a()?Reflect.construct(o,c||[],s(r).constructor):o.apply(r,c))).element=e,n.settings=n.getSettings(t.defaults,u),n.isShown=!1,n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&c(e,t)}(t,e),n=t,o=[{key:"show",value:function(){this.isShown||(this.trigger(t.event.SHOW),this.isShown=!0,this.showOverlay())}},{key:"hide",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.isShown&&(this.trigger(t.event.HIDE),this.isShown=!1,this.hideOverlay(e))}},{key:"showOverlay",value:function(){var e=this;this.element.style.display="block",this.element.removeAttribute("aria-hidden"),this.element.scrollTop=0,this.element.focus();var n=this.element.classList.contains(t.className.FADE);n&&this.reflow(),this.element.classList.add(t.className.SHOW),n?this.one("transitionend",(function(){e.trigger(t.event.SHOWN)})):this.trigger(t.event.SHOWN)}},{key:"hideOverlay",value:function(e){var n=this;this.element.setAttribute("aria-hidden",!0);var i=this.element.classList.contains(t.className.FADE);!e&&i?this.one("transitionend",(function(){n.element.style.display="none"})):this.element.style.display="none",this.element.classList.remove(t.className.SHOW),!e&&i?this.one("transitionend",(function(){n.trigger(t.event.HIDDEN)})):this.trigger(t.event.HIDDEN)}},{key:"reflow",value:function(){this.element.offsetHeight}}],o&&r(n.prototype,o),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,o}(n(45363).A);u.event={SHOW:"show:overlay",SHOWN:"shown:overlay",HIDE:"hide:overlay",HIDDEN:"hidden:overlay"},u.className={FADE:"overlay--fade",SHOW:"show"},u.defaults={};const l=u},45363:(e,t,n)=>{"use strict";function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?r(Object(n),!0).forEach((function(t){var i,r,o;i=e,r=t,o=n[t],(r=s(r))in i?Object.defineProperty(i,r,{value:o,enumerable:!0,configurable:!0,writable:!0}):i[r]=o})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function a(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,s(i.key),i)}}function s(e){var t=function(e){if("object"!=i(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=i(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==i(t)?t:t+""}n.d(t,{A:()=>c});const c=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.element=t},(t=[{key:"getSettings",value:function(e,t){return o(o({},e),t)}},{key:"trigger",value:function(e){var t=new CustomEvent(e);this.element.dispatchEvent(t)}},{key:"one",value:function(e,t){var n=this;this.element.addEventListener(e,(function i(){n.element.removeEventListener(e,i),t()}))}}])&&a(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}()},3832:(e,t,n)=>{"use strict";n.d(t,{Bh:()=>a,DY:()=>b,H:()=>d,Kj:()=>f,M4:()=>E,MA:()=>s,MH:()=>y,Pu:()=>m,Ui:()=>h,Ze:()=>o,_T:()=>v,b0:()=>l,eM:()=>p,ef:()=>i,jm:()=>r,tL:()=>u,wd:()=>g,xm:()=>S,y7:()=>c,yJ:()=>w});var i=1165,r=768,o=1164,a=768,s=36e4,c=26298e5,u={closeWelcomeMessage:"close:welcomeMessage",openStoreStockChecker:"open:StoreStockChecker",openedStoreStockChecker:"opened:StoreStockChecker",checkAvailabilityStoreStockChecker:"checkAvailability:StoreStockChecker",getDirectionsStoreStockChecker:"getDirections:StoreStockChecker",addedToBasketStoreStockChecker:"addedToBasket:StoreStockChecker",closeStoreStockChecker:"close:StoreStockChecker",searchLocationStoreLocator:"searchLocation:StoreLocator",sizeChangedPDP:"sizeChange:PDP",initWishlist:"initWishlist:UGCOverlay",openBasket:"basket:openBasket"},l=4,h=4,m=861,f=27,d=13,v="StyleStudio",y="Minibag",p={name:"Unlimited Delivery",description:"Unlimited next day delivery for a 
2whole year.",price:"£12.00",removedHeader:"Unlimited Delivery removed",removedContent:"Changed your mind? You can add Unlimited Delivery again from\n    within the checkout"},g="Get the outfit",b={postprod:"https://api.postprod.digital.ri-tech.io/",production:"https://api-v2.riverisland.com/"},E={dev:"559ca194-401e-4f18-91ce-87593c6f4550",production:"4e75323e-7f51-4f0d-89d8-d6101970bcff"},w={AT:"de-AT",BE:"nl-BE",BG:"bg-BG",CY:"el-CY",CZ:"cs-CZ",DE:"de-DE",DK:"da-DK",EE:"et-EE",ES:"es-ES",FI:"fi-FI",FR:"fr-FR",GR:"el-GR",HR:"hr-HR",HU:"hu-HU",IE:"en-IE",IT:"it-IT",LT:"lt-LT",LU:"fr-LU",LV:"lv-LV",MC:"fr-MC",MT:"mt-MT",NL:"nl-NL",PL:"pl-PL",PT:"pt-PT",RO:"ro-RO",SE:"sv-SE",SI:"sl-SI",SK:"sk-SK",SM:"it-SM",VA:"it-VA"},S={AT:{currency:"EUR",minOrder:30},BE:{currency:"EUR",minOrder:30},BG:{currency:"EUR",minOrder:30},CY:{currency:"EUR",minOrder:30},CZ:{currency:"EUR",minOrder:30},DE:{currency:"EUR",minOrder:30},DK:{currency:"DKK",minOrder:225},EE:{currency:"EUR",minOrder:30},ES:{currency:"EUR",minOrder:30},FI:{currency:"EUR",minOrder:30},FR:{currency:"EUR",minOrder:30},GR:{currency:"EUR",minOrder:30},HR:{currency:"EUR",minOrder:30},HU:{currency:"EUR",minOrder:30},IE:{currency:"EUR",minOrder:30},IT:{currency:"EUR",minOrder:30},LT:{currency:"EUR",minOrder:30},LU:{currency:"EUR",minOrder:30},LV:{currency:"EUR",minOrder:30},MC:{currency:"EUR",minOrder:30},MT:{currency:"EUR",minOrder:30},NL:{currency:"EUR",minOrder:30},PL:{currency:"PLN",minOrder:127},PT:{currency:"EUR",minOrder:30},RO:{currency:"RON",minOrder:156},SE:{currency:"SEK",minOrder:330},SI:{currency:"EUR",minOrder:30},SK:{currency:"EUR",minOrder:30},SM:{currency:"EUR",minOrder:30},VA:{currency:"EUR",minOrder:30}}},23901:(e,t,n)=>{"use strict";n.d(t,{A:()=>i});const i=function(e){return window.tcpl&&window.tcpl.publicfeatures&&window.tcpl.publicfeatures.includes(e)}},87370:(e,t,n)=>{"use strict";n.d(t,{Ay:()=>s,Dp:()=>a,Ny:()=>o});var i="region-",r={get region(){var e=document.body.classList;for(var t in e){var n=e[t];if("string"==typeof n&&0===n.indexOf(i))return n.replace(i,"")}}},o=r.region,a=function(e){return r.region===e};const s=r},27514:(e,t,n)=>{"use strict";n.d(t,{Co:()=>a,kh:()=>r,ol:()=>o,q9:()=>s});var i=n(3832),r=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:i.MA,r={value:t,expiry:(new Date).getTime()+n};localStorage.setItem(e,JSON.stringify(r))},o=function(e){var t=localStorage.getItem(e);if(!t)return null;var n=JSON.parse(t);return(new Date).getTime()>n.expiry?(localStorage.removeItem(e),null):n.value},a=function(e,t){var n=[],a=e.trim();o("user_recent_search",i.y7)&&(n=o("user_recent_search",i.y7));var s=n.includes(a);s&&"delete"===t&&n.splice(n.indexOf(a),1),"add"===t&&(s?n.unshift(n.splice(n.indexOf(a),1)[0]):n=[a].concat(n).slice(0,8)),r("user_recent_search",n,i.y7)},s=function(e){return"undefined"!=typeof window&&localStorage.removeItem(e),null}},20681:(e,t,n)=>{"use strict";function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function r(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,s(i.key),i)}}function o(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function a(e,t,n){return(t=s(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function s(e){var t=function(e){if("object"!=i(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=i(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==i(t)?t:t+""}const c=o((function e(){var t=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),a(this,"bindMenuButton",(function(){var e=document.getElementById(t.idNames.howCanWeHelpButton);e&&e.addEventListener("click",(function(e){e.preventDefault(),document.getElementsByClassName(t.classNames.howCanWeHelpBtn)[0].click(),setTimeout((function(){document.getElementsByClassName(t.classNames.burgerIcon)[0].click()}),410)}))})),a(this,"bindFooterExpandAccordions",(function(){var e=document.getElementsByClassName(t.classNames.accordionToggle);if(e&&e.length)for(var n=0;n<e.length;n++)e[n].addEventListener("click",(function(e){e.preventDefault();var t=e.currentTarget,n=t.parentNode.nextElementSibling;t.classList.toggle("active"),n.style.maxHeight?n.style.maxHeight=null:n.style.maxHeight="".concat(n.scrollHeight,"px")}))}
2)),a(this,"bindBackToTopButton",(function(){var e=document.getElementById(t.idNames.backToTop);e&&e.addEventListener("click",(function(e){e.preventDefault(),window.RI.UI.scrollToTop(0)}))})),a(this,"init",(function(){t.bindMenuButton(),t.bindBackToTopButton(),t.bindFooterExpandAccordions()})),this.idNames={howCanWeHelpPanel:"how-can-we-help",howCanWeHelpButton:"how-can-we-help-button",backToTop:"back-to-top"},this.classNames={accordionToggle:"footer-links__info__accordion--toggle",burgerIcon:"header__button--burger-menu",howCanWeHelpBtn:"mega-menu-info__chevron"}}));var u=n(87370),l=n(68396),h=n.n(l),m=n(93295),f=n(3832);function d(e){return d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},d(e)}function v(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function y(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?v(Object(n),!0).forEach((function(t){var i,r,o,a;i=e,r=t,o=n[t],a=function(e){if("object"!=d(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=d(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(r),(r="symbol"==d(a)?a:a+"")in i?Object.defineProperty(i,r,{value:o,enumerable:!0,configurable:!0,writable:!0}):i[r]=o})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):v(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const p=function(e,t){var n,i=e.querySelector(".mega-menu__widget-copy--title"),r=i?i.textContent.trim():"",o=e.querySelector(".mega-menu__widget-image"),a=e.querySelector(".mega-menu__widget-link"),s=a?a.href:"",c=(null===(n=e.closest("ul"))||void 0===n?void 0:n.parentElement).classList.contains("desktop-widgets")?"Desktop":"Mobile",u=e.dataset.widgetHierarchy.split(": "),l=u.length,h=u.splice(0,l-1),m=l<=1?u:h,f="widget";return""!==r&&null===o&&(f="widget_text_only"),""===r&&null!==o&&(f="widget_image_only"),""!==r&&null!==o&&(f="widget_text_and_image"),{navigation:y(y({menuWidget:r},"click"===t&&{dimension72:f}),{},{type:c,tab:m[0]||"",category:m[1]||"",subcategory:m[2]||"",sub_subcategory:m[3]||"",dimension73:s}),menu:{format:"burger",type:"widget"}}};var g=n(17334),b=n.n(g),E=n(45363);function w(e){return w="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},w(e)}function S(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,T(i.key),i)}}function k(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(k=function(){return!!e})()}function O(e){return O=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},O(e)}function _(e,t){return _=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},_(e,t)}function L(e,t,n){return(t=T(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function T(e){var t=function(e){if("object"!=w(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=w(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==w(t)?t:t+""}var C=function(e){function t(e){var n,i,r,o,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),L((i=this,o=[e],r=O(r=t),n=function(e,t){if(t&&("object"===w(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(i,k()?Reflect.construct(r,o||[],O(i).constructor):r.apply(i,o))),"onClear",(function(){n.input.value="",n.toggleButton(),n.trigger(t.event.CLEAR)})),L(n,"onToggleButton",(function(){n.toggleButton(),n.trigger(t.event.CHANGE)})),n.element=e,n.settings=n.getSettings(t.defaults,a),n.input=n.element.getElementsByClassName(t.className.input)[0],n.button=n.element.getElementsByClassName(t.className.button)[0],n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&_(e,t)}(t,e),n=t,(i=[{key:"init",value:function(){this.bindEvents()}},{key:"bindEvents",value:function(){var e=this;["change","keyup","cut","input","paste"].map((function(t){return e.input.addEventListener(t,e.onToggleButton)})),this.button.addEventListener("click",this.onClear)}},{key:"toggleButton",value:function(){0===this.input.value.length?this.button.classList.remove("active"):this.button.classList.add("active")}},{key:"destroy",value:function(){var e=this;["change","keyup","cut"].map((function(t){return e.input.removeEventListener(t,e.onToggleButton)})),this.button.removeEventListener("click",this.onToggleButton)}}
2])&&S(n.prototype,i),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,i}(E.A);C.event={CHANGE:"change:clearinput",CLEAR:"clear:clearinput"},C.className={input:"js-clear-input",button:"js-clear-button"},C.defaults={};const M=C;var I=n(59422);function j(e){return j="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},j(e)}function A(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,N(i.key),i)}}function R(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(R=function(){return!!e})()}function D(e){return D=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},D(e)}function P(e,t){return P=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},P(e,t)}function N(e){var t=function(e){if("object"!=j(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=j(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==j(t)?t:t+""}var B=function(e){function t(e,n){var i,r,o,a,s,c,u;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),s=this,u=[e,n],c=D(c=t),r=i=function(e,t){if(t&&("object"===j(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(s,R()?Reflect.construct(c,u||[],D(s).constructor):c.apply(s,u)),a=function(){i.search()},(o=N(o="handleOnSearch"))in r?Object.defineProperty(r,o,{value:a,enumerable:!0,configurable:!0,writable:!0}):r[o]=a,i.settings=i.getSettings(t.default,n),i.element=e,i.disabled=!1,i}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&P(e,t)}(t,e),n=t,(i=[{key:"init",value:function(){this.settings.autoFocus&&this.element.focus(),this.bindEvents()}},{key:"bindEvents",value:function(){this.element.addEventListener("input",this.handleOnSearch)}},{key:"enable",value:function(){this.disabled&&(this.disabled=!1,this.trigger(t.event.ENABLED))}},{key:"disable",value:function(){this.disabled||(this.disabled=!0,this.trigger(t.event.DISABLED))}},{key:"search",value:function(){var e=this.element.value.trim();if(!this.disabled&&e.length>=this.settings.minLength&&(this.trigger(t.event.SEARCH),"function"==typeof this.settings.source)){var n=this.settings.source(e);"function"==typeof this.settings.response&&(this.settings.response(n),this.trigger(t.event.RESPONSE))}}},{key:"destroy",value:function(){this.element.removeEventListener("input",this.handleOnSearch),this.trigger(t.event.DESTROY)}}])&&A(n.prototype,i),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,i}(E.A);B.default={autoFocus:!1,minLength:2,source:null,response:null},B.event={ENABLED:"enabled:typeahead",DISABLED:"disabled:typeahead",SEARCH:"search:typeahead",RESPONSE:"response:typeahead",DESTROY:"destroy:typeahead"};const x=B;function W(e){return W="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},W(e)}function H(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,U(i.key),i)}}function q(e,t,n){return(t=U(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function U(e){var t=function(e){if("object"!=W(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=W(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==W(t)?t:t+""}const F=function(){return e=function e(t){var n=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),q(this,"keyCode",{TAB:9,SHIFT:16,UP_ARROW:38,DOWN_ARROW:40}),q(this,"handleOnKeydown",(function(e){if([n.keyCode.TAB,n.keyCode.DOWN_ARROW,n.
2keyCode.UP_ARROW].indexOf(e.keyCode)>=0&&e.preventDefault(),void 0===n.containerOfElements)return!1;if(e.shiftKey&&e.keyCode===n.keyCode.TAB||e.keyCode===n.keyCode.UP_ARROW){if(n.isFirst())return n.setCurrent(n.inputElement).focus(n.inputElement);if(n.currentElement===n.inputElement){var t=n.previous();return n.setCurrent(t).focus(t.children[0])}var i=n.previous();return n.setCurrent(i).focus(i.children[0])}if([n.keyCode.TAB,n.keyCode.DOWN_ARROW].indexOf(e.keyCode)>=0){if(n.isLast())return n.setCurrent(n.inputElement).focus(n.inputElement);if(n.currentElement===n.inputElement){var r=n.next();return n.setCurrent(r).focus(r.children[0])}var o=n.next();return n.setCurrent(o).focus(o.children[0])}})),this.inputElement=t.inputElement,this.containerOfElements=t.containerOfElements,this.focusClass=t.focusClass,this.currentElement=null,this.currentInputValue=""},(t=[{key:"init",value:function(){return this.bindEvents(),this.currentElement=this.inputElement,this.currentInputValue=this.inputElement.value,this}},{key:"next",value:function(){var e=null;return(e=this.currentElement!==this.inputElement&&this.currentElement?this.currentElement.nextElementSibling:this.containerOfElements.firstElementChild)&&e.classList.contains(this.focusClass)?e:(this.currentElement=e,this.next())}},{key:"previous",value:function(){var e=this.currentElement===this.inputElement?this.containerOfElements.lastElementChild:this.currentElement.previousElementSibling;return e.classList.contains(this.focusClass)?e:(this.currentElement=e,this.previous())}},{key:"bindEvents",value:function(){document.addEventListener("keydown",this.handleOnKeydown)}},{key:"isFirst",value:function(){var e=this.containerOfElements.firstElementChild;return!!e.classList.contains("selected")&&(e.classList.remove("selected"),!0)}},{key:"isLast",value:function(){var e=this.containerOfElements.lastElementChild;return!!e.classList.contains("selected")&&(e.classList.remove("selected"),!0)}},{key:"focus",value:function(e){if(e.scrollIntoView(),e===this.inputElement)this.next().scrollIntoView(),this.inputElement.value=this.currentInputValue;else{var t=function(e){if(e&&e.textContent)return e.textContent.split("\n").filter((function(e){return e&&!e.match(/^\s+$/)})).map((function(e){return e.trim()}))}(e).join(" ");this.inputElement.value=t}return this.inputElement.focus()}},{key:"setCurrent",value:function(e){return this.currentElement&&this.currentElement.classList.remove("selected"),this.currentElement=e,this.currentElement!==this.inputElement&&e.classList.add("selected"),this}},{key:"destroy",value:function(){document.removeEventListener("keydown",this.handleOnKeydown)}}])&&H(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();var Z=n(27514);function K(e){return K="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},K(e)}function V(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function G(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,$(i.key),i)}}function z(e,t){if(t&&("object"===K(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}function Y(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(Y=function(){return!!e})()}function X(e){return X=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},X(e)}function J(e,t){return J=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},J(e,t)}function Q(e,t,n){return(t=$(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function $(e){var t=function(e){if("object"!=K(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=K(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==K(t)?t:t+""}var ee=function(e){function t(){var e,n,i,r,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),o?(n=this,r=[o],i=X(i=t),Q(e=z(n,Y()?Reflect.construct(i,r||[],X(n).constructor):i.apply(n,r)),"setUserSearchStorage",(function(e){(0,Z.kh)("user_search",e,f.MA)})),Q(e,"setSearchTypeStorage",(function(){(0,Z.kh)("search_type","suggested_searches")})),Q(e,"handleTypeaheadClick",(function(t){var n=t.currentTarget.firstElementChild.innerText.replace(/\n/g," ").trim();e.searchInputElement&&(e.searchInputElement.value=n),e.setSearchTypeStorage(),e.setUserSearchStorage(n),(0,Z.Co)(n,"add")})),e.index=1,e.lastTabIndex=null,e.searchTerm=null,e.searchInputElement=null,e):z(e)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&J(e,t)}(t,e),n=t,i=[{key:"init",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return this.empty(),e&&e.length>0&&(this.searchInputElement=n,this.searchTerm=n?n.value:null,this.trigger(t.event.ON_PRE_RENDER),this.element.insertAdjacentHTML("beforeend",this.createHtmlString(e)),this.trigger(t.event.ON_RENDER),this.bindEvents()),this}},{key:"bindEvents",value:function(){for(var e=this.element.getElementsByClassName("typeahead-search__link"),t=0;t<e.length;t+=1)e[t].addEventListener("click",this.handleTypeaheadClick)}},{key:"empty",value:function(){this.element.innerHTML="",this.trigger(t.event.ON_EMPTY)}},{key:"createHtmlString",value:function(e){return"\n\t\t\t<ul class='typeahead__results'>\n\t\t\t\t".concat(this.createSuggestions(e),"\n\t\t\t</ul>\n\t\t")}},{key:"highlightMatchingSearchText",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(this.searchTerm&&e)try{var t=this.searchTerm.toLowerCase().split(" "),n="";t.forEach((function(e){n+="(".concat(e,")*")}));var i,r=new RegExp(n,"ig"),o=[],a=function(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];
2if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return V(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?V(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var i=0,r=function(){};return{s:r,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){s=!0,o=e},f:function(){try{a||null==n.return||n.return()}finally{if(s)throw o}}}}(e.matchAll(r));try{for(a.s();!(i=a.n()).done;){var s=i.value;s[0]&&s[0].length>0&&o.push({index:s.index,text:s[0],textLength:s[0].length})}}catch(e){a.e(e)}finally{a.f()}if(o.length>0){for(var c=e,u=o.length-1;u>=0;u--)c="".concat(c.substring(0,o[u].index),'<span class="typeahead__results__keyword--matching-text">').concat(o[u].text,"</span>").concat(c.substring(o[u].index+o[u].textLength));return"<span"!==c.substring(0,5)&&(c="<span>".concat(c.substring(0,1),"</span>").concat(c.substring(1))),"".concat(c)}return"<span>".concat(e,"</span>")}catch(t){return"<span>".concat(e,"</span>")}return"<span>".concat(e,"</span>")}},{key:"createSuggestions",value:function(e){var n=this;return e.map((function(e){return"\n\t\t\t<li class='".concat(t.className.LINK,"'>\n\t\t\t\t<a tabindex='").concat(n.index++,"' href='/search?keyword=").concat(e.replace(/\s/g,"%20"),'\'>\n                    <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="none">\n                        <path\n                        d="M7.642 15.3a7.583 7.583 0 0 0 5.416-2.242 7.658 7.658 0 0 0 0-10.833 7.64 7.64 0 0 0-10.833 0A7.658 7.658 0 0 0 7.642 15.3Zm0-14.467A6.792 6.792 0 0 1 12.5 2.808a6.834 6.834 0 0 1 0 9.692 6.815 6.815 0 0 1-9.65 0A6.833 6.833 0 0 1 7.642.833Z"\n                        fill="#000"\n                        />\n                        <path\n                        d="m13.062 12.458 6.965 6.965-.59.59-6.965-6.965.59-.59Z"\n                        fill="#000"\n                        />\n                    </svg>\n\t\t\t\t\t<span class=\'typeahead__results__keyword\'>\n\t\t\t\t\t\t').concat(n.highlightMatchingSearchText(e[0].toUpperCase()+e.slice(1)),"\n\t\t\t\t\t</span>\n\t\t\t\t</a>\n\t\t\t</li>\n\t\t")})).join("")}}],i&&G(n.prototype,i),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,i}(E.A);ee.className={LINK:"typeahead-search__link"},ee.event={ON_RENDER:"onRender:typeaheadresults",ON_PRE_RENDER:"onPreRender:typeaheadresults",ON_EMPTY:"onEmpty:typeaheadresults",ON_BLUR_LAST_ITEM:"onBlurLastItem:typeaheadresults",ON_BLUR_FIRST_ITEM:"onBlurFirstItem:typeaheadresults"};const te=ee;function ne(e){return ne="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ne(e)}function ie(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,ue(i.key),i)}}function re(e,t){if(t&&("object"===ne(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}function oe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(oe=function(){return!!e})()}function ae(e){return ae=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},ae(e)}function se(e,t){return se=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},se(e,t)}function ce(e,t,n){return(t=ue(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ue(e){var t=function(e){if("object"!=ne(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=ne(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==ne(t)?t:t+""}var le=function(e){function t(){var e,n,i,r,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),o?(n=this,r=[o],i=ae(i=t),ce(e=re(n,oe()?Reflect.construct(i,r||[],ae(n).constructor):i.apply(n,r)),"getRecentSearchTerms",(function(){return(0,Z.ol)("user_recent_search")||[]})),ce(e,"setUserSearchStorage",(function(e){(0,Z.kh)("user_search",e,f.MA)})),ce(e,"setSearchTypeStorage",(function(){(0,Z.kh)("search_type","recent_searches")})),ce(e,"handleRecentSearchClick",(function(t){var n=t.currentTarget.innerText;""!==n&&(e.setSearchTypeStorage(),e.setUserSearchStorage(n.trim()),(0,Z.Co)(n.trim(),"add"))})),ce(e,"handleRecentSearchDelete",(function(t){var n=t.currentTarget.previousElementSibling.innerText.trim(),i=(0,Z.ol)("user_search");""!==n&&((0,Z.Co)(n,"delete"),i&&i===n&&e.setUserSearchStorage(""),e.init(
2))})),e.index=1,e.lastTabIndex=null,e):re(e)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&se(e,t)}(t,e),n=t,(i=[{key:"init",value:function(){var e=this.getRecentSearchTerms();return this.empty(),e&&e.length>0&&(this.trigger(t.event.ON_PRE_RENDER),this.element.insertAdjacentHTML("beforeend",this.createHtmlString(e)),this.trigger(t.event.ON_RENDER),this.bindEvents()),this}},{key:"bindEvents",value:function(){for(var e=this.element.getElementsByClassName("recent-search__link"),t=0;t<e.length;t+=1)e[t].addEventListener("click",this.handleRecentSearchClick);for(var n=this.element.getElementsByClassName("recent-search__delete"),i=0;i<n.length;i+=1)n[i].addEventListener("click",this.handleRecentSearchDelete)}},{key:"createHtmlString",value:function(){return"\n      <h4 tabindex=\"-1\" class='recent-search__title'>Recent Searches</h4>\n\t\t\t<ul class='recent-search__container'>\n        ".concat(this.createRecentSearchItems(),"\n\t\t\t</ul>\n\t\t")}},{key:"createRecentSearchItems",value:function(){var e=this;return this.getRecentSearchTerms().map((function(t){return'\n        <li class="recent-search__item">\n          <a tabindex="'.concat(e.index++,'" href="/search?keyword=').concat(t.replace(/\s/g,"%20"),'" class="recent-search__link" aria-label="recent search term link">\n              <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="none" aria-hidden="true">\n                <path\n                  d="M7.642 15.3a7.583 7.583 0 0 0 5.416-2.242 7.658 7.658 0 0 0 0-10.833 7.64 7.64 0 0 0-10.833 0A7.658 7.658 0 0 0 7.642 15.3Zm0-14.467A6.792 6.792 0 0 1 12.5 2.808a6.834 6.834 0 0 1 0 9.692 6.815 6.815 0 0 1-9.65 0A6.833 6.833 0 0 1 7.642.833Z"\n                  fill="#000"\n                />\n                <path\n                  d="m13.062 12.458 6.965 6.965-.59.59-6.965-6.965.59-.59Z"\n                  fill="#000"\n                />\n            </svg>\n            <span class="recent-search__keyword">').concat(t,'</span>\n          </a>\n          <button class="recent-search__delete" aria-label="delete ').concat(t,'">\n            <svg width="17" height="20" fill="none" aria-hidden="true">\n              <path\n                d="M8.05 5.458h.833v12.075H8.05V5.458ZM12.075 17.533l.775-12.075h-.833l-.775 12.075h.833ZM4.85 17.533h.833L4.917 5.458h-.834l.767 12.075Z"\n                fill="#000"\n              />\n              <path\n                d="M2.583 20h11.425a1.334 1.334 0 0 0 1.317-1.217l1.008-13.316H15.5l-1.008 13.258a.492.492 0 0 1-.484.442H2.583a.5.5 0 0 1-.491-.45l-1.059-15a.492.492 0 0 1 .125-.367.483.483 0 0 1 .359-.15H5.45a.417.417 0 0 0 .417-.417V.833h5v1.975a.417.417 0 0 0 .416.417h5.209l.075-.833h-4.9V.433A.418.418 0 0 0 11.25 0H5.417A.417.417 0 0 0 5 .417v1.975H1.483A1.317 1.317 0 0 0 .167 3.8l1.066 15a1.325 1.325 0 0 0 1.35 1.2Z"\n                fill="#000"\n              />\n            </svg>\n          </button>\n        </li>\n    ')})).join("")}},{key:"empty",value:function(){this.element.innerHTML="",this.trigger(t.event.ON_EMPTY)}}])&&ie(n.prototype,i),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,i}(E.A);le.event={ON_RENDER:"onRender:recentsearchlist",ON_PRE_RENDER:"onPreRender:recentsearchlist",ON_EMPTY:"onEmpty:recentsearchlist"};const he=le;function me(e){return me="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},me(e)}function fe(){fe=function(){return t};var e,t={},n=Object.prototype,i=n.hasOwnProperty,r=Object.defineProperty||function(e,t,n){e[t]=n.value},o="function"==typeof Symbol?Symbol:{},a=o.iterator||"@@iterator",s=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function u(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{u({},"")}catch(e){u=function(e,t,n){return e[t]=n}}function l(e,t,n,i){var o=t&&t.prototype instanceof p?t:p,a=Object.create(o.prototype),s=new I(i||[]);return r(a,"_invoke",{value:L(e,n,s)}),a}function h(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}t.wrap=l;var m="suspendedStart",f="suspendedYield",d="executing",v="completed",y={};function p(){}function g(){}function b(){}var E={};u(E,a,(function(){return this}));var w=Object.getPrototypeOf,S=w&&w(w(j([])));S&&S!==n&&i.call(S,a)&&(E=S);var k=b.prototype=p.prototype=Object.create(E);function O(e){["next","throw","return"].forEach((function(t){u(e,t,(function(e){return this._invoke(t,e)}))}
vendor: 4,565 bytes, line 2
2))}function _(e,t){function n(r,o,a,s){var c=h(e[r],e,o);if("throw"!==c.type){var u=c.arg,l=u.value;return l&&"object"==me(l)&&i.call(l,"__await")?t.resolve(l.__await).then((function(e){n("next",e,a,s)}),(function(e){n("throw",e,a,s)})):t.resolve(l).then((function(e){u.value=e,a(u)}),(function(e){return n("throw",e,a,s)}))}s(c.arg)}var o;r(this,"_invoke",{value:function(e,i){function r(){return new t((function(t,r){n(e,i,t,r)}))}return o=o?o.then(r,r):r()}})}function L(t,n,i){var r=m;return function(o,a){if(r===d)throw Error("Generator is already running");if(r===v){if("throw"===o)throw a;return{value:e,done:!0}}for(i.method=o,i.arg=a;;){var s=i.delegate;if(s){var c=T(s,i);if(c){if(c===y)continue;return c}}if("next"===i.method)i.sent=i._sent=i.arg;else if("throw"===i.method){if(r===m)throw r=v,i.arg;i.dispatchException(i.arg)}else"return"===i.method&&i.abrupt("return",i.arg);r=d;var u=h(t,n,i);if("normal"===u.type){if(r=i.done?v:f,u.arg===y)continue;return{value:u.arg,done:i.done}}"throw"===u.type&&(r=v,i.method="throw",i.arg=u.arg)}}}function T(t,n){var i=n.method,r=t.iterator[i];if(r===e)return n.delegate=null,"throw"===i&&t.iterator.return&&(n.method="return",n.arg=e,T(t,n),"throw"===n.method)||"return"!==i&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+i+"' method")),y;var o=h(r,t.iterator,n.arg);if("throw"===o.type)return n.method="throw",n.arg=o.arg,n.delegate=null,y;var a=o.arg;return a?a.done?(n[t.resultName]=a.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,y):a:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,y)}function C(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function M(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function I(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(C,this),this.reset(!0)}function j(t){if(t||""===t){var n=t[a];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var r=-1,o=function n(){for(;++r<t.length;)if(i.call(t,r))return n.value=t[r],n.done=!1,n;return n.value=e,n.done=!0,n};return o.next=o}}throw new TypeError(me(t)+" is not iterable")}return g.prototype=b,r(k,"constructor",{value:b,configurable:!0}),r(b,"constructor",{value:g,configurable:!0}),g.displayName=u(b,c,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===g||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,b):(e.__proto__=b,u(e,c,"GeneratorFunction")),e.prototype=Object.create(k),e},t.awrap=function(e){return{__await:e}},O(_.prototype),u(_.prototype,s,(function(){return this})),t.AsyncIterator=_,t.async=function(e,n,i,r,o){void 0===o&&(o=Promise);var a=new _(l(e,n,i,r),o);return t.isGeneratorFunction(n)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},O(k),u(k,c,"Generator"),u(k,a,(function(){return this})),u(k,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),n=[];for(var i in t)n.push(i);return n.reverse(),function e(){for(;n.length;){var i=n.pop();if(i in t)return e.value=i,e.done=!1,e}return e.done=!0,e}},t.values=j,I.prototype={constructor:I,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(M),!t)for(var n in this)"t"===n.charAt(0)&&i.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var n=this;function r(i,r){return s.type="throw",s.arg=t,n.next=i,r&&(n.method="next",n.arg=e),!!r}for(var o=this.tryEntries.length-1;o>=0;--o){var a=this.tryEntries[o],s=a.completion;if("root"===a.tryLoc)return r("end");if(a.tryLoc<=this.prev){var c=i.call(a,"catchLoc"),u=i.call(a,"finallyLoc");if(c&&u){if(this.prev<a.catchLoc)return r(a.catchLoc,!0);if(this.prev<a.finallyLoc)return r(a.finallyLoc)}else if(c){if(this.prev<a.catchLoc)return r(a.catchLoc,!0)}else{if(!u)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return r(a.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&i.call(r,"finallyLoc")&&this.prev<r.finallyLoc){var o=r;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);
2var a=o?o.completion:{};return a.type=e,a.arg=t,o?(this.method="next",this.next=o.finallyLoc,y):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),y},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),M(n),y}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var i=n.completion;if("throw"===i.type){var r=i.arg;M(n)}return r}}throw Error("illegal catch attempt")},delegateYield:function(t,n,i){return this.delegate={iterator:j(t),resultName:n,nextLoc:i},"next"===this.method&&(this.arg=e),y}},t}function de(e,t,n,i,r,o,a){try{var s=e[o](a),c=s.value}catch(e){return void n(e)}s.done?t(c):Promise.resolve(c).then(i,r)}function ve(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,pe(i.key),i)}}function ye(e,t,n){return(t=pe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pe(e){var t=function(e){if("object"!=me(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=me(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==me(t)?t:t+""}const ge=function(){return e=function e(t,n){var i=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),ye(this,"trackSearchStatus",(function(e){window.riDigitalData&&window.riDigitalData.add(e?"searchOpen":"searchClose",{search:{view:i.settings.isMobile?"sidebar":"overlay"}})})),ye(this,"handleOnSearch",function(){var e,t=(e=fe().mark((function e(t){var n,r,o,a,s,c,u,l,h;return fe().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n="/system/solrtypeahead?keyword=".concat(t.toLowerCase()),r=!1,window.tcpl&&window.tcpl.publicfeatures&&window.tcpl.publicfeatures.includes("UseFredhopperWeb")&&(a=window?window.location.host.includes(".riverisland.")?f.DY.production:f.DY.postprod:f.DY.production,n="".concat(a,"typeahead?search=").concat(t.toLowerCase()),r=!0),e.prev=3,e.next=6,fetch(n);case 6:if(s=e.sent,i.destroySearchAccessibility(),s.ok){e.next=10;break}throw new Error(s.statusText);case 10:return e.next=12,s.json();case 12:(c=e.sent)&&""!==i.inputElement.value?(r?(u=c.suggestionGroups||[],l=u.find((function(e){return"1keywords"===e.indexName})),h=l.suggestions||[],o=h.map((function(e){return e.searchterm}))):o=c.acterms,i.components.searchTypeaheadResults.init(o,i.inputElement),i.initSearchAccessibility("typeahead__results","typeahead-search__link")):""===i.inputElement.value&&i.initSearchAccessibilityForRecentSearches(),e.next=19;break;case 16:return e.prev=16,e.t0=e.catch(3),e.abrupt("return",!1);case 19:case"end":return e.stop()}}),e,null,[[3,16]])})),function(){var t=this,n=arguments;return new Promise((function(i,r){var o=e.apply(t,n);function a(e){de(o,i,r,a,s,"next",e)}function s(e){de(o,i,r,a,s,"throw",e)}a(void 0)}))});return function(e){return t.apply(this,arguments)}}()),ye(this,"handleHasHadInteraction",(function(){var e=new CustomEvent("search:interaction");i.formElement.dispatchEvent(e)})),ye(this,"handleInputChange",(function(){if(i.hasHadInteraction||i.handleHasHadInteraction(),i.validateInput())return i.enableSubmit(),void i.emptyRecentSearchList();i.inputInitialState()})),ye(this,"handleShowSearch",(function(){var e=i.inputElement.value;i.destroySearchAccessibility(),(0,Z.q9)("search_type"),e&&""!==e&&i.initSearchAccessibility("typeahead__results","typeahead-search__link"),i.open()})),ye(this,"handleCloseSearch",(function(e){var t=!1,n=e.target;void 0!==n.classList&&n.classList.contains("search-custom-hide")||("closed:mobileMenu"===e.type&&(i.overlayElement.getElementsByClassName("js-clear-button")[0].classList.remove("active"),t=!0),i.destroySearchAccessibility(),i.close(t))})),ye(this,"handleSearchResultsScroll",(function(e){e.target.scrollTop>10&&!i.fixedElementWrapper.classList.contains("scrolling")?i.fixedElementWrapper.classList.add("scrolling"):e.target.scrollTop<10&&i.fixedElementWrapper.classList.remove("scrolling")})),ye(this,"hasPersonalInfo",(function(){return!!i.inputElement.value.match(/\S+@\S+\.\S+/)&&(window.location="/c/women",!0)})),ye(this,"handleSubmit",(function(e){if(e.preventDefault(),!i.hasPersonalInfo()&&i.validateInput()){if(i.inputElement){var t=i.inputElement.value;i.setUserSearchStorage(t),(0,Z.Co)(t,"add")}else{var n=document.getElementById("typeahead-search-query").value;i.setUserSearchStorage(document.getElementById("typeahead-search-query").value),(0,Z.Co)(n,"add")}i.formElement.submit()}})),ye(this,"handleClearInput",(function(){i.inputInitialState(),i.inputElement.focus()})),ye(this,"setUserSearchStorage",(function(e){(0,Z.kh)("user_search",e,f.MA)})),ye(this,"handleOnKeydown",(function(e){e.keyCode===f.H&&i.handleSubmit(e)})),ye(this,"handleOnKeyup",(function(e){e.keyCode===f.Kj&&i.close(!1)})),ye(this,"handleResize",(function(){var e=Math.abs(i.windowWidth-window.innerWidth)<30;window.innerWidth>f.jm&&i.settings.isMobile||!i.isOpen||e||(i.windowWidth=window.innerWidth,i.close(!0))})),this.components={},this.settings=n,this.hasHadInteraction=!1,this.isOpen=!1,this.windowWidth=window.innerWidth,this.overlayElement=document.getElementById(t.overlayElement),this.overlayElement&&(this.showSearchElement=document.getElementById(t.showSearchElement),this.hideSearchElements=t.hideSearchElements.map((function(e){return document.querySelector("#".concat(e))})),this.searchResultsElement=document.getElementById(t.searchResultsElement),this.recentSearchElement=document.getElementById(t.recentSearchElement),this.inputElement=document.getElementById(t.inputElement),this.fixedElementWrapper=this.overlayElement.getElementsByClassName(t.fixedWrapperElement)[0],this.formElement=document.getElementById(t.formElement),t.submitElement&&(this.submitElement=document.getElementById(t.submitElement)),t.selectRegionElement&&(this.selectRegionElement=document.getElementById(t.selectRegionElement)),t.myAccountElement&&(this.myAccountElement=document.getElementById(t.myAccountElement)))},(t=[{key:"init",value:function(){if(this.overlayElement){this.components.overlay=new I.A(this.overlayElement),this.components.searchAccessibility=null;var e=(0,Z.ol)("user_search");e&&""!==e&&(this.inputElement.value=e,document.getElementsByClassName("js-clear-button")[0].classList.add("active")),this.disableSubmit(),this.initTypeahead(),this.settings.clearInput&&this.initClearInput(),this.bindEvents()}return this}},{key:"bindEvents",value:function(){var e=this;this.showSearchElement&&this.showSearchElement.addEventListener("click",this.handleShowSearch),this.inputElement.addEventListener("input",this.handleInputChange),this.searchResultsElement.addEventListener("scroll",this.handleSearchResultsScroll),this.formElement.addEventListener("submit",this.handleSubmit),this.hideSearchElements.forEac
2h((function(t){t&&t.addEventListener("click",e.handleCloseSearch)})),window.addEventListener("resize",this.handleResize),this.settings.isMobile&&document.addEventListener("closed:mobileMenu",this.handleCloseSearch),this.selectRegionElement&&this.selectRegionElement.addEventListener("click",this.handleCloseSearch),this.myAccountElement&&this.myAccountElement.addEventListener("click",this.handleCloseSearch),this.settings.keyboardEscape&&this.overlayElement.addEventListener("keyup",this.handleOnKeyup),this.overlayElement.addEventListener("keydown",this.handleOnKeydown),this.recentSearchElement&&(this.recentSearchElement.addEventListener("onPreRender:recentsearchlist",(function(t){e.components.overlay&&e.components.overlay.element&&e.setOverlayElementHasResults(!0)})),this.recentSearchElement.addEventListener("onEmpty:recentsearchlist",(function(t){e.components.overlay&&e.components.overlay.element&&e.setOverlayElementHasResults(!1)}))),this.searchResultsElement&&this.searchResultsElement.addEventListener("onPreRender:typeaheadresults",(function(t){e.components.overlay&&e.components.overlay.element&&e.setOverlayElementHasResults(!0)}))}},{key:"initTypeahead",value:function(){window.tcpl&&window.tcpl.publicfeatures&&window.tcpl.publicfeatures.includes("EnableLocalizeJs")&&(0,u.Dp)("DE")||(this.components.searchTypeaheadResults=new te(this.searchResultsElement),this.components.typeahead=new x(this.inputElement,{autoFocus:this.settings.autoFocus,source:b()(this.handleOnSearch,200)}),this.components.typeahead.init())}},{key:"initRecentSearchList",value:function(){this.destroySearchAccessibility(),this.components.recentSearchList=new he(this.recentSearchElement),this.components.recentSearchList.init()}},{key:"emptyRecentSearchList",value:function(){this.components.recentSearchList&&this.components.recentSearchList.empty()}},{key:"initClearInput",value:function(){var e=document.getElementsByClassName("clear-input-container")[0],t=new M(e);e.addEventListener("clear:clearinput",this.handleClearInput),t.init()}},{key:"initSearchAccessibility",value:function(e,t){if(null===this.components.searchAccessibility){var n={inputElement:document.getElementById("typeahead-search-query"),containerOfElements:document.getElementsByClassName(e)[0],focusClass:t};this.components.searchAccessibility=new F(n),this.components.searchAccessibility.init()}}},{key:"destroySearchAccessibility",value:function(){this.components.searchAccessibility&&(this.components.searchAccessibility.destroy(),this.components.searchAccessibility=null)}},{key:"initSearchAccessibilityForRecentSearches",value:function(){this.destroySearchAccessibility(),this.initSearchAccessibility("recent-search__container","recent-search__item")}},{key:"disableSubmit",value:function(){this.submitElement&&(""===this.inputElement.value.trim()||""===(0,Z.ol)("user_search")&&!(0,Z.ol)("user_search"))&&(this.submitElement.classList.add("disabled"),this.submitElement.setAttribute("disabled","disabled"))}},{key:"enableSubmit",value:function(){this.submitElement&&(this.submitElement.classList.remove("disabled"),this.submitElement.removeAttribute("disabled"))}},{key:"inputInitialState",value:function(){this.disableSubmit(),this.components.searchTypeaheadResults&&this.components.searchTypeaheadResults.empty(),this.initRecentSearchList(),this.initSearchAccessibilityForRecentSearches()}},{key:"open",value:function(){if(!this.isOpen){this.isOpen=!0,this.components.overlay.show();var e=new CustomEvent("search:show");this.formElement.dispatchEvent(e);var t=(0,Z.ol)("user_search");t&&""!==t?(this.inputElement.value=t,document.getElementsByClassName("js-clear-button")[0].classList.add("active"),this.emptyRecentSearchList()):(this.inputElement.value="",this.components.recentSearchList?(this.components.recentSearchList.init(),this.initSearchAccessibilityForRecentSearches()):(this.initRecentSearchList(),this.initSearchAccessibilityForRecentSearches())),this.settings.autoFocus&&(this.inputElement.focus(),this.inputElement.blur(),this.inputElement.focus()),document.getElementsByTagName("html")[0].classList.add("search-open"),this.trackSearchStatus(!0),this.components.typeahead.search()}}},{key:"close",value:function(e){if(this.isOpen){this.isOpen=!1,this.components.overlay.hide(e);var t=new CustomEvent("search:hide");this.formElement.dispatchEvent(t),document.getElementsByTagName("html")[0].classList.remove("search-open"),this.disableSubmit(),this.components.searchTypeaheadResults&&this.components.searchTypeaheadResults.empty(),this.emptyRecentSearchList(),this.trackSearchStatus(),this.setOverlayElementHasResults(!1)}}},{key:"setOverlayElementHasResults",value:function(e){e?this.components.overlay.element.classList.add("has-results"):this.components.overlay.element.classList.remove("has-results")}},{key:"validateInput",value:function(){return""!==this.inputElement.value.trim()}}])&&ve(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();var be=n(23901);function Ee(e){return Ee="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ee(e)}function we(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,ke(i.key),i)}}function Se(e,t,n){return(t=ke(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ke(e){var t=function(e){if("object"!=Ee(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Ee(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Ee(t)?t:t+""}const Oe=function(){return e=function e(t,n){var i=this;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),Se(this,"init",(function(){i._isInitialised||(i._isInitialised=!0,i.bindEventListeners(),i.setLoggedInStatus(),i.initSearch(),i.setAnalyticsValues())})),Se(this,"bindEventListeners",(function(){if(i.hamburgerBtn&&i.hamburgerBtn.addEventListener("click",i.openMainMenu),i.megaMenuOverlay&&i.megaMenuOverlay.addEventListener("click",i.closeMainMenu),i.loopBindEventListeners(i.mainNavigationBackMulitLayer,i.closeSubMenu),i.loopBindEventListeners(i.megaMenuSearchCloseText,i.closeMainMenu),i.searchBtnMultiLayer&&i.searchBtnMultiLayer.addEventListener("click",i.openSearch),i.loopBindEventListeners(i.mainNavigationSubMenuBack,i.closeSubMenu),i.loopBindEventListeners(i.navigationWidgets,i.trackNavigationWidgetClick),i.loopBindEventListeners(i.backButtons,i.trackNavigationBackButtonClick),i.megaMenuSearchClose&&i.megaMenuSearchClose.addEventListener("click",i.closeSearch),i.externalSearchBtn&&i.externalSearchBtn.addEventListener("click",i.openExternalSearch),i.loopBindEventListeners(i.mainNavigationItems,i.openSubMenu),i.loopBindEventListeners(i.firstLevelOfItems,i.openMultiLayerSubMenu),i.megaMenu){var e=i.megaMenu.querySelectorAll(".mega-menu__multi-layer-sub-level");i.loopBindEventListeners(e,i.openMultiLayerSubMenu)}i.logOut&&i.logOut.addEventListener("click",i.setSDKSyncCookie),i.loopBindEventListeners(i.megaMenuTabGroupInspirations,i.handleTabGroupClick)})),Se(this,"setSDKSyncCookie",(function(){document.cookie="shouldSDKSync=true;domain=".concat(function(){if(window.location.host.includes("localhost"))return"localhost";var e=window.location.host.split(".");return".".concat(e[e.length-2],".").concat(e[e.length-1])}(),";path=/")}
2)),Se(this,"trackNavigationWidgetClick",(function(e){var t=e.target.closest?e.target.closest("li"):null;if(t){var n=p(t,"click");window.riDigitalData&&window.riDigitalData.add&&window.riDigitalData.add("navigationClick",n)}})),Se(this,"getMenuHierarchy",(function(e){var t=[];return e&&e.firstElementChild&&e.firstElementChild.classList.contains("js-mega-menu__heading")&&(t=e.firstElementChild.dataset.menuHierarchy.split(":").map((function(e){return e.trim()}))),t})),Se(this,"trackNavigationBackButtonClick",(function(e){var t=e.target.closest?e.target.closest("li"):null,n=i.getMenuHierarchy(t).slice(0,-1);window.riDigitalData&&window.riDigitalData.add&&window.riDigitalData.add("navigationClick",{navigation:{type:"Mobile",tab:n[0]||"",category:n[1]||"",subcategory:n[2]||"",sub_subcategory:n[3]||""},menu:{format:"arrow",type:"back-button"}})})),Se(this,"handleTabGroupClick",(function(e){if(i.megaMenu&&e&&e.target){i.megaMenu.querySelectorAll(".js-mega-menu__tab-group--inspiration").forEach((function(e){e.classList.remove("mega-menu__tab-group-ins
2piration--active")})),e.target.classList.add("mega-menu__tab-group-inspiration--active");var t=e.target.getAttribute("data-tab-id"),n=document.getElementById("mega-menu__tab-group-item-".concat(t));if(n&&n.parentNode){for(var r=n.parentNode.getElementsByClassName("mega-menu__tab-group-item"),o=0;o<r.length;o+=1)r[o].style.display="none";n.style.display="block"}}})),Se(this,"trackBurgerMenuClick",(function(){window.riDigitalData&&window.riDigitalData.add&&window.riDigitalData.add("navigationClick",{navigation:{category:"",sub_subcategory:"",subcategory:"",tab:"",type:"Mobile",url:""},menu:{format:"burger",type:"burger-button"}})})),Se(this,"trackNavigationWidgetImpression",(function(e){if(i.mainNavigation&&i.mainNavigation.classList.contains("main-navigation--sub-menu-open")){var t;t=e?(0,be.A)("MegaMenuV4")?i.mainNavigation.querySelectorAll(".mega-menu__sub-menu--open.mega-menu__sub-menu--active > ul > li.js-widget-mobile"):i.mainNavigation.querySelectorAll(".mega-menu__sub-menu--open.mega-menu__sub-menu--active > div > ul > li.widget"):i.mainNavigation.querySelectorAll(".mega-menu__multi-layer-sub-level--open.mega-menu__multi-layer-sub-level--active > ul > li.js-widget-mobile");for(var n=0;n<t.length;n+=1){var r=p(t[n],"impression");window.riDigitalData&&window.riDigitalData.add&&window.riDigitalData.add("menuWidgetImpression",r)}}})),Se(this,"setLoggedInStatus",(function(){if(i.logIn&&i.logOut)return(0,m.A)()?(i.logIn.classList.add("mega-menu-info__log-in--hide"),void i.logOut.classList.remove("mega-menu-info__log-out--hide")):void i.logOut.classList.add("mega-menu-info__log-out--hide")})),Se(this,"openMainMenu",(function(){!i.isTransitioning&&!i.isClosing&&i.mainNavigation&&i.outerContainer&&i.megaMenuOverlay&&(i.isTransitioning=!0,i.mainNavigation.style.display="block",i.mainNavigation.scrollTop=0,h().on(),i.outerContainer.classList.add("outer-container--menu-open"),i.megaMenuOverlay.classList.add("mega-menu__overlay--menu-open"),i.screenWidth=window.innerWidth,window.addEventListener("resize",i.resetMenuForDesktop),i.trackNavigationWidgetImpression(),i.trackBurgerMenuClick(),setTimeout((function(){i.isTransitioning=!1}),410))})),Se(this,"closeMainMenu",(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.skipSearchClose,n=void 0!==t&&t,r=e.calledFromSearch,o=void 0!==r&&r;i.isClosing||i.isTransitioning||i.outerContainer&&i.megaMenuOverlay&&(i.isClosing=!0,i.isTransitioning=!0,h().off(),i.outerContainer.classList.remove("outer-container--menu-open"),i.megaMenuOverlay.classList.remove("mega-menu__overlay--menu-open"),setTimeout((function(){if(!i.mainNavigation)return i.isClosing=!1,void(i.isTransitioning=!1);i.closeSubMenuMain(),i.resetMultiLayerLevels(),n||o||i.closeSearch(),i.mainNavigation.style.display=null,i.isClosing=!1,i.isTransitioning=!1}),410))})),Se(this,"openSubMenu",(function(e){if(!(window.innerWidth>f.Ze)&&e&&e.target){e.preventDefault();var t=i.findTargetSubMenu(e);if(t){t.style.display="block",t.scrollTop=0;for(var n=t.querySelectorAll(".mega-menu__multi-layer-sub-level"),r=0;r<n.length;r+=1)"1"!==n[r].getAttribute("data-level")&&(n[r].style.display="none");var o=i.mainNavigation?i.mainNavigation.scrollTop:0;i.mainNavigation&&i.mainNavigation.classList.add("main-navigation--sub-menu-open"),t.classList.add("mega-menu__sub-menu--open"),t.classList.add("mega-menu__sub-menu--active"),t.style.top="".concat(o,"px"),i.openSubMenus.push(t),i.megaMenuSearch&&i.megaMenuSearch.classList.add("mega-menu-search--sub-menu"),i.trackNavigationWidgetImpression(!0)}}})),Se(this,"findTargetSubMenu",(function(e){for(var t,n=e.target,i=0;!t&&i<4&&n;){var r=n.querySelector&&n.querySelector(".mega-menu__sub-menu");r?t=r:(i+=1,n=n.parentElement)}return t})),Se(this,"openMultiLayerSubMenu",(function(e){if(e&&(e.stopPropagation(),!(window.innerWidth>f.Ze))){var t=e.target,n="IMG"===t.tagName?t.parentElement.nextElementSibling:t.nextElementSibling;if(n&&n.hasAttribute("data-level")){e.preventDefault();var r=t.closest?t.closest(".mega-menu__multi-layer-sub-level"):null;if(n.style.display="block",n.scrollTop=0,n.classList.add("mega-menu__multi-layer-sub-level--open","mega-menu__multi-layer-sub-level--active"),"2"===n.getAttribute("data-level")){var o=t.closest?t.closest(".mega-menu__sub-menu"):null;
2o&&o.classList.remove("mega-menu__sub-menu--active")}if(r){var a=r.scrollTop;n.style.top="".concat(a,"px"),r.classList.remove("mega-menu__multi-layer-sub-level--active")}i.trackNavigationWidgetImpression()}}})),Se(this,"closeSubMenu",(function(e){if(e&&e.target){var t=e.target,n=t.closest?t.closest(".mega-menu__multi-layer-sub-level"):null;n?i.closeMultiLayerLevels(n):i.closeSubMenuMain()}})),Se(this,"closeMultiLayerLevels",(function(e){if(e){e.classList.remove("mega-menu__multi-layer-sub-level--open");var t=e.parentElement?e.parentElement.closest(".mega-menu__multi-layer-sub-level"):null,n=e.parentElement?e.parentElement.closest(".mega-menu__sub-menu"):null;n&&n.classList.add("mega-menu__sub-menu--active"),t&&t.classList.add("mega-menu__multi-layer-sub-level--active"),i.resetDisplayValue(e)}})),Se(this,"resetMultiLayerLevels",(function(){if(i.megaMenu)for(var e=i.megaMenu.querySelectorAll('[class*="mega-menu__multi-layer-sub-level"]'),t=0;t<e.length;t+=1){var n=e[t].getAttribute("data-level");e[t].classList.remove("mega-menu__multi-layer-sub-level--open"),i.resetDisplayValue(e[t]),window.innerWidth>f.Ze&&"2"===n&&(e[t].style.display="block")}})),Se(this,"closeSubMenuMain",(function(){if(i.mainNavigation&&i.mainNavigation.classList.remove("main-navigation--sub-menu-open"),i.openSubMenus.length>0){for(var e=0;e<i.openSubMenus.length;e+=1){var t=i.openSubMenus[e];t&&(t.classList.remove("mega-menu__sub-menu--open"),i.removeSubMenuTop(t),i.resetDisplayValue(t))}i.openSubMenus=[]}i.megaMenuSearch&&i.megaMenuSearch.classList.remove("mega-menu-search--sub-menu")})),Se(this,"openSearch",(function(){i.mainNavigation&&i.megaMenuSearch&&i.searchQuery&&(i.mainNavigation.classList.add("main-navigation--search-open"),i.megaMenuSearch.classList.add("mega-menu-search--active"),i.searchInstance&&i.searchInstance.handleShowSearch&&i.searchInstance.handleShowSearch(),i.searchQuery.focus())})),Se(this,"closeSearch",(function(){var e=0;i.isExternalSearch&&(i.isExternalSearch=!1,i.closeMainMenu({skipSearchClose:!0,calledFromSearch:!0}),e=410),setTimeout((function(){i.mainNavigation&&i.megaMenuSearch&&(i.mainNavigation.classList.remove("main-navigation--search-open"),i.megaMenuSearch.classList.remove("mega-menu-search--active"),document.dispatchEvent(new CustomEvent("closed:mobileMenu")))}),e)})),Se(this,"openExternalSearch",(function(){i.isExternalSearch=!0,i.openMainMenu(),i.openSearch()})),Se(this,"loopBindEventListeners",(function(e,t){if(e&&e.length)for(var n=0;n<e.length;n+=1){var i=e[n];i.__mmMobileBound||(i.addEventListener("click",t),i.__mmMobileBound=!0)}})),Se(this,"resetMenuForDesktop",(function(){(Math.abs(i.screenWidth-window.innerWidth)>50||window.innerWidth>f.Ze)&&(window.removeEventListener("resize",i.resetMenuForDesktop),i.closeMainMenu({skipSearchClose:!0}))})),Se(this,"setAnalyticsValues",(function(){window.innerWidth>f.Ze||!i.megaMenu||(i.megaMenu.dataset.menuType="mobile")})),Se(this,"resetDisplayValue",(function(e){setTimeout((function(){e&&e.style&&(e.style.display=null)}),410)})),Se(this,"removeSubMenuTop",(function(e){setTimeout((function(){e&&e.classList&&e.style&&(e.classList.contains("mega-menu__sub-menu--info")||(e.style.top=null))}),410)})),this._isInitialised=!1,this.screenWidth=null,this.hamburgerBtn=t,this.mainNavigation=n,this.openSubMenus=[],this.searchInstance=null,this.isExternalSearch=!1,this.isClosing=!1,this.isTransitioning=!1,this.outerContainer=document.getElementById("outer-container"),this.navBarContainer=document.querySelector(".nav-bar-container"),this.megaMenuOverlay=document.querySelector(".mega-menu__overlay"),this.megaMenuMobile=this.navBarContainer?this.navBarContainer.querySelector(".mega-menu--desktop"):null,this.megaMenu=this.megaMenuMobile,!this.megaMenu)return this.megaMenuTabGroupInspirations=[],this.mainNavigationItems=[],this.mainNavigationSubMenuBack=[],this.mainNavigationBackMulitLayer=[],this.searchBtnMultiLayer=null,this.navigationWidgets=[],this.megaMenuSearch=this.navBarContainer?this.navBarContainer.querySelector(".mega-menu-search"):null,this.megaMenuSearchClose=this.navBarContainer?this.navBarContainer.querySelector(".mega-menu-search__close"):null,this.megaMenuSearchCloseText=[],this.searchQuery=document.getElementById("mm-typeahead-search-query"),this.externalSearchBtn=document.querySelector(".icon__search-button--mobile"),this.logIn=null,this.logOut=null,this.firstLevelOfItems=[],void(this.backButtons=[]);this.megaMenuTabGroupInspirations=this.megaMenu.querySelectorAll(".js-mega-menu__tab-group--inspiration"),this.mainNavigationItems=this.megaMenu.querySelectorAll(".main-navigation__item"),this.mainNavigationSubMenuBack=this.megaMenu.querySelectorAll(".mega-menu__sub-menu .main-navigation__back"),this.mainNavigationBackMulitLayer=this.megaMenu.querySelectorAll(".mega-menu--multi-layer .main-navigation__back"),this.searchBtnMultiLayer=this.navBarContainer?this.navBarContainer.querySelector(".main-navigation__search-inner.multi-layer .main-navigation__search-text"):null,this.navigationWidgets=this.megaMenu.querySelectorAll(".mega-menu__column-item.widget"),this.megaMenuSearch=this.navBarContainer?this.navBarContainer.querySelector(".mega-menu-search"):null,this.megaMenuSearchClose=this.navBarContainer?this.navBarContainer.querySelector(".mega-menu-search__close"):null,this.megaMenuSearchCloseText=this.navBarContainer?this.navBarContainer.querySelectorAll(".btn--hide-search.multi-layer"):[],this.searchQuery=document.getElementById("mm-typeahead-search-query"),this.externalSearchBtn=document.querySelector(".icon__search-button--mobile"),this.logIn=this.megaMenu.querySelector(".mega-menu-info__log-in"),this.logOut=this.megaMenu.querySelector(".mega-menu-info__log-out"),this.firstLevelOfItems=this.megaMenu.querySelectorAll(".mega-menu__multi-layer-level"),this.backButtons=this.megaMenu.querySelectorAll(".js-main-navigation__back")},(t=[{key:"initSearch",value:function(){this.searchInstance=new ge({overlayElement:"mm-search-overlay",showSearchElement:"mm-show-search",hideSearchElements:["mm-hide-search"],searchResultsElement:"mm-typeahead-results",inputElement:"mm-typeahead-search-query",fixedWrapperElement:"fixed-wrapper",formElement:"mm-typeahead-input",recentSearchElement:"mm-recent-search-list"},{clearInput:!0,autoFocus:!0,isMobile:!0,isRegionUK:(0,u.Dp)("UK"),keyboardEscape:!1}).init()}}])&&we(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function _e(e){return _e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_e(e)}function Le(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,Ce(i.key),i)}}function Te(e,t,n){return(t=Ce(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ce(e){var t=function(e){if("object"!=_e(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=_e(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==_e(t)?t:t+""}const Me=function(){return e=function e(){var t=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),Te(this,"loopBindEventListeners",(function(e,t){for(var n=0;n<e.length;n+=1)e[n].addEventListener("click",t)})),Te(this,"trackNavigationWidgetClick",(function(e){var t=e.currentTarget;if(t){var n=p(t,"click");window.riDigitalData&&window.riDigitalData.add&&window.riDigitalData.add("navigationClick",n)}})),Te(this,"setActiveNavigationItem",(function(e){var n=!0,i=e.currentTarget||e.target;if(t.currentActiveItem===i)return!1;t.currentActiveItem&&(t.unsetActiveNavigationItem(),n=!1),t.currentActiveItem=i,t.currentActiveDropdown=t.currentActiveItem.querySelector(t.querySelectors.dropdown),t.currentActiveDropdownContent=t.currentActiveDropdown.querySelector(t.querySelectors.dropdownContent),t.currentActiveDropdown.classList.add("mega-menu__sub-menu
2--active"),t.currentActiveItem.classList.add("active"),n&&(t.reflow(),t.megaMenu.classList.remove("transition"),document.querySelector(".nav-bar-container").classList.add("active")),t.currentActiveDropdown.classList.add("active"),t.currentActiveDropdownContent.classList.add("active")})),Te(this,"resetMegaMenu",(function(){t.backgroundVisible&&t.toggleBackground(),t.currentActiveItem&&t.unsetActiveNavigationItem(),t.currentActiveItem=null,t.currentActiveDropdown=null,t.megaMenu.classList.add("transition"),document.querySelector(".nav-bar-container").classList.remove("active"),t.animateBackground=!0})),Te(this,"resetMenuOnContentExit",(function(e){t.currentActiveDropdownContent.removeEventListener("mouseleave",t.resetMenuOnContentExit),t.currentActiveDropdownContent.addEventListener("mouseenter",t.resetMenuOnContentEnter),t.contentExitTimeout||(t.contentExitTimeout=setTimeout((function(){e.toElement===t.currentActiveDropdown&&t.resetMegaMenu()}),t.settings.dropdownCloseDelay))})),Te(this,"resetMenuOnContentEnter",(function(){clearTimeout(t.contentExitTimeout),clearTimeout(t.navigationItemTimeout),t.contentExitTimeout=null,t.navigationItemTimeout=null,t.currentActiveDropdownContent.removeEventListener("mouseenter",t.resetMenuOnContentEnter),t.currentActiveDropdownContent.addEventListener("mouseleave",t.resetMenuOnContentExit)})),Te(this,"onNavigationItemTouchStart",(function(e){return!(window.innerWidth<f.jm)&&(!(!t.currentActiveItem||t.currentActiveItem!==e.currentTarget)||(e.preventDefault(),t.setActiveNavigationItem(e),void(t.backgroundVisible||t.toggleBackgroun
2d())))})),Te(this,"onNavigationItemMouseEnter",(function(e){t.navigationItemTimeout?(clearTimeout(t.navigationItemTimeout),t.navigationItemTimeout=null,t.onNavigationItemMouseEnter(e)):t.openDropdownWithTimeout(e),null!==t.currentActiveItem&&(t.backgroundVisible||t.toggleBackground())})),Te(this,"onNavigationItemKeyDown",(function(e){13===e.keyCode&&t.onNavigationItemTouchStart(e)})),Te(this,"onNavigationItemMouseLeave",(function(){null!==t.navigationItemTimeout&&(clearTimeout(t.navigationItemTimeout),t.navigationItemTimeout=null)})),Te(this,"onOrientationChange",(function(){0===window.orientation&&t.resetMegaMenu()})),Te(this,"onSiteMaskTouch",(function(e){e.preventDefault(),t.resetMegaMenu()})),this.querySelectors={navigationID:"main-menu",megaMenu:".mega-menu--mobile",navigationItem:".mega-menu--mobile .mega-menu__item",dropdown:".mega-menu__sub-menu",dropdownContent:".mega-menu__content",siteMask:".site-container__mask",desktopWidgets:".mega-menu--mobile .mega-menu__column-item.widget"},this.settings={dropdownCloseDelay:500,itemHoverDelay:300},this.navigation=document.getElementById(this.querySelectors.navigationID),this.navigation&&(this.navigationItems=this.navigation.querySelectorAll(this.querySelectors.navigationItem),this.navigationColumnItems=this.navigation.querySelectorAll(this.querySelectors.navigationColumnItem),this.megaMenu=this.navigation.querySelector(this.querySelectors.megaMenu),this.siteMask=document.querySelector(this.querySelectors.siteMask),this.navigationWidgets=this.navigation.querySelectorAll(this.querySelectors.desktopWidgets),this.backgroundVisible=!1,this.currentActiveItem=null,this.currentActiveDropdown=null,this.animateBackground=!0,this.contentExitTimeout=null,this.navigationItemTimeout=null)},(t=[{key:"init",value:function(){return this.navigation&&(this.bindEvents(),this.megaMenu.classList.add("mega-menu--fade","transition")),this}},{key:"bindEvents",value:function(){for(var e=0;e<this.navigationItems.length;e+=1)this.navigationItems[e].addEventListener("touchstart",this.onNavigationItemTouchStart),this.navigationItems[e].addEventListener("mouseenter",this.onNavigationItemMouseEnter),this.navigationItems[e].addEventListener("mouseleave",this.onNavigationItemMouseLeave),this.navigationItems[e].addEventListener("keydown",this.onNavigationItemKeyDown);this.navigation&&this.navigation.addEventListener("mouseleave",b()(this.resetMegaMenu,10)),this.siteMask&&this.siteMask.addEventListener("touchstart",this.onSiteMaskTouch),this.loopBindEventListeners(this.navigationWidgets,this.trackNavigationWidgetClick),window.addEventListener("orientationchange",this.onOrientationChange)}},{key:"unsetActiveNavigationItem",value:function(){this.currentActiveItem.classList.remove("active"),this.currentActiveDropdownContent.classList.remove("active"),this.currentActiveDropdown.classList.remove("mega-menu__sub-menu--active","active")}}
2,{key:"toggleBackground",value:function(){this.backgroundVisible=!this.backgroundVisible,this.siteMask.style.display="block"===this.siteMask.style.display?"none":"block",this.siteMask.classList.toggle("mega-menu__background"),this.animateBackground&&(this.animateBackground=!1,this.reflow()),this.siteMask.classList.toggle("active")}},{key:"reflow",value:function(){this.navigation.offsetHeight}},{key:"openDropdown",value:function(e){this.setActiveNavigationItem(e),this.navigationItemTimeout=null,this.currentActiveDropdownContent.addEventListener("mouseenter",this.resetMenuOnContentEnter)}},{key:"openDropdownWithTimeout",value:function(e){var t=this;this.navigationItemTimeout=setTimeout((function(){t.openDropdown(e),t.backgroundVisible||t.toggleBackground()}),this.settings.itemHoverDelay)}}])&&Le(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function Ie(e){return Ie="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ie(e)}function je(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,Re(i.key),i)}}function Ae(e,t,n){return(t=Re(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Re(e){var t=function(e){if("object"!=Ie(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Ie(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Ie(t)?t:t+""}const De=function(){return e=function e(){var t=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),Ae(this,"onTrackedNavigationItemClick",(function(e){var n=e.currentTarget,i=n.closest("[data-menu-type]"),r="";i&&(r=i.dataset.menuType);var o="mobile"===r.toLowerCase(),a=n.classList.contains("main-navigation__item"),s="text";n.children&&n.children.length>0&&n.querySelector("img")&&(s="image"),!o&&a&&(s="text");var c=n.dataset.menuHierarchy,u=n.href;if((!n.classList.contains("mega-menu__heading-multi-layer")||"desktop"!==r)&&c){var l=c.split(": ");t.sendTracking(r,l[0],l[1],l[2],l[3],u,s,o)}})),Ae(this,"sendTracking",(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"desktop",t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"",r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"",o=arguments.length>5?arguments[5]:void 0,a=arguments.length>6&&void 0!==arguments[6]?arguments[6]:"text",s=arguments.length>7?arguments[7]:void 0;window.riDigitalData&&window.riDigitalData.add("navigationClick",{navigation:{type:e.charAt(0).toUpperCase()+e.slice(1),tab:t,category:n,subcategory:i,sub_subcategory:r,url:o},menu:{format:s?"burger":"regular",type:a}})})),this.trackedNavigationLinks=document.querySelectorAll("[data-menu-hierarchy]")},(t=[{key:"init",value:function(){this.bindEvents()}},{key:"bindEvents",value:function(){for(var e=0;e<this.trackedNavigationLinks.length;e+=1)this.trackedNavigationLinks[e].addEventListener("click",this.onTrackedNavigationItemClick)}}])&&je(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function Pe(e){return Pe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Pe(e)}function Ne(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,xe(i.key),i)}}function Be(e,t,n){return(t=xe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function xe(e){var t=function(e){if("object"!=Pe(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Pe(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Pe(t)?t:t+""}const We=function(){return e=function e(){var t=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),Be(this,"swipeLeft",(function(){t.currentZone<t.zoneTotal?(t.currentZone++,t.selectNewZone()):2==t.currentZone?(t.currentZone=1,t.carousel.classList.add("view-2msg-post"),t.carousel.classList.remove("view-2"),setTimeout(t.smoothOff,t.timeTilSmoothOff)):(t.currentZone=1,t.carousel.classList.add("view-3msg-post"),t.carousel.classList.remove("view-3"),setTimeout(t.smoothOff,t.timeTilSmoothOff))})),Be(this,"swipeRight",(function(){t.currentZone>1?(t.currentZone--,t.selectNewZone()):(t.currentZone=t.zoneTotal,t.carousel.classList.add("view-pre"),t.carousel.classList.remove("view-1"),setTimeout(t.smoothOff,t.timeTilSmoothOff))})),Be(this,"selectNewZone",(function(){var e="view-".concat(t.currentZone);
2t.selectionClasses.forEach((function(e){t.carousel.classList.remove(e)})),t.carousel.classList.add(e)})),Be(this,"smoothOff",(function(){t.carousel.classList.remove("transition"),t.fakeLeftOrRight()})),Be(this,"smoothOn",(function(){t.carousel.classList.add("transition"),t.selectNewZone()})),this.touchstartX=0,this.touchendX=0,this.leftThreshold=25,this.rightThreshold=-25,this.currentZone=1,this.zoneTotal=0,this.selectionClasses=["view-1","view-2","view-3","view-pre","view-2msg-post","view-3msg-post"],this.carousel=document.getElementById("mobile-info-strip-carousel"),this.gestureZone=document.querySelectorAll(".gesture-zone"),this.slideInterval=!1,this.autoScrollTime=4250,this.timeTilSmoothOff=550,this.timeTilSmoothOn=25},(t=[{key:"init",value:function(){this.bindEvents()}},{key:"bindEvents",value:function(){var e=this;this.zoneTotal=this.gestureZone.length,this.zoneTotal>1&&(this.gestureZone.forEach((function(t){t.addEventListener("touchstart",(function(t){e.touchstartX=t.changedTouches[0].screenX,e.restartAutoScroll(e.slideInterval)}),{passive:!0}),t.addEventListener("touchend",(function(n){e.touchendX=n.changedTouches[0].screenX,e.currentZone=t.dataset.zone,e.handleGesture()}),{passive:!0})})),this.startAutoScroll())}},{key:"startAutoScroll",value:function(){this.slideInterval=setInterval(this.swipeLeft,this.autoScrollTime)}},{key:"restartAutoScroll",value:function(){clearInterval(this.slideInterval),this.startAutoScroll()}},{key:"handleGesture",value:function(){if(this.touchendX<=this.touchstartX){if(this.touchstartX-this.touchendX<this.leftThreshold)return;this.swipeLeft()}if(this.touchendX>=this.touchstartX){if(this.touchstartX-this.touchendX>this.rightThreshold)return;this.swipeRight()}}},{key:"fakeLeftOrRight",value:function(){1===this.currentZone?(this.carousel.classList.remove("view-2msg-post","view-3msg-post"),this.carousel.classList.add("view-pre"),setTimeout(this.smoothOn,this.timeTilSmoothOn)):2===this.currentZone?(this.carousel.classList.remove("view-pre"),this.carousel.classList.add("view-2msg-post"),setTimeout(this.smoothOn,this.timeTilSmoothOn)):(this.carousel.classList.remove("view-pre"),this.carousel.classList.add("view-3msg-post"),setTimeout(this.smoothOn,this.timeTilSmoothOn))}}])&&Ne(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function He(e){return He="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},He(e)}function qe(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,Ze(i.key),i)}}function Ue(e,t,n){return t&&qe(e.prototype,t),n&&qe(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Fe(e,t,n){return(t=Ze(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ze(e){var t=function(e){if("object"!=He(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=He(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==He(t)?t:t+""}var Ke=new(Ue((function e(){var t=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),Fe(this,"init",(function(){window.addEventListener("resize",t.handleResize)})),Fe(this,"hydrateDesktop",(function(e){t.isMobile?t.desktopFuncs.push(e):e()})),Fe(this,"hydrateMobile",(function(e){t.isMobile?e():t.mobileFuncs.push(e)})),Fe(this,"handleResize",(function(){t.updateIsMobile()&&(t.isMobile?t.runAllFunctions(t.mobileFuncs):t.runAllFunctions(t.desktopFuncs),window.removeEventListener("resize",t.handleResize))})),Fe(this,"runAllFunctions",(function(e){if(e&&!(e.length<=0))for(var t=0;t<e.length;t+=1)e[t]()})),Fe(this,"updateIsMobile",(function(){return!(t.isMobile&&window.innerWidth<=f.ef||!t.isMobile&&window.innerWidth>f.ef||(t.isMobile=window.innerWidth<=f.ef,0))})),this.isMobile=window.innerWidth<=f.ef,this.mobileFuncs=[],this.desktopFuncs=[]})));Ke.init(),Ke.hydrateMobile((function(){var e=document.getElementById("hamburger"),t=document.querySelector(".main-navigation");e&&t&&(new Oe(e,t).init(),document.getElementById("main-menu").style.display="block")})),Ke.hydrateDesktop((function(){(new Me).init(),document.getElementById("main-menu").style.display="block"})),(new De).init(),(new c).init(),new ge({overlayElement:"search-overlay",showSearchElement:"show-search",hideSearchElements:["hide-search","hide-search-overlay-bg"],searchResultsElement:"typeahead-results",inputElement:"typeahead-search-query",submitElement:"search-submit",fixedWrapperElement:"fixed-wrapper",formElement:"typeahead-input",selectRegionElement:"region-currency-flag",myAccountElement:"header-my-account",recentSearchElement:"recent-search-list"},{clearInput:!1,autoFocus:!0,isMobile:!1,isRegionUK:(0,u.Dp)("UK"),keyboardEscape:!0}).init(),(new We).init()},17334:e=>{function t(e,t,n){var i,r,o,a,s;function c(){var u=Date.now()-a;u<t&&u>=0?i=setTimeout(c,t-u):(i=null,n||(s=e.apply(o,r),o=r=null))}null==t&&(t=100);var u=function(){o=this,r=arguments,a=Date.now();var u=n&&!i;
2return i||(i=setTimeout(c,t)),u&&(s=e.apply(o,r),o=r=null),s};return u.clear=function(){i&&(clearTimeout(i),i=null)},u.flush=function(){i&&(s=e.apply(o,r),o=r=null,clearTimeout(i),i=null)},u}t.debounce=t,e.exports=t},68396:function(e){!function(t){var n,i,r=!1;function o(e){if("undefined"!=typeof document&&!r){var t=document.documentElement;i=window.pageYOffset,document.documentElement.scrollHeight>window.innerHeight?t.style.width="calc(100% - "+function(){if(void 0!==n)return n;var e=document.documentElement,t=document.createElement("div");return t.setAttribute("style","width:99px;height:99px;position:absolute;top:-9999px;overflow:scroll;"),e.appendChild(t),n=t.offsetWidth-t.clientWidth,e.removeChild(t),n}()+"px)":t.style.width="100%",t.style.position="fixed",t.style.top=-i+"px",t.style.overflow="hidden",r=!0}}function a(){if("undefined"!=typeof document&&r){var e=document.documentElement;e.style.width="",e.style.position="",e.style.top="",e.style.overflow="",window.scroll(0,i),r=!1}}var s={on:o,off:a,toggle:function(){r?a():o()}};void 0!==e.exports?e.exports=s:t.noScroll=s}(this)}}]);
3//# sourceMappingURL=navigation-header-8b14b7a9c6fc6ee5d760.js.map

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.