1"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[26318],{1998:e=>{var t="%[a-f0-9]{2}",r=RegExp("("+t+")|([^%]+?)","gi"),i=RegExp("("+t+")+","gi");e.exports=function(e){if("string"!=typeof e)throw TypeError("Expected `encodedURI` to be of type `string`, got `"+typeof e+"`");try{return e=e.replace(/\+/g," "),decodeURIComponent(e)}catch(t){return function(e){for(var t={"%FE%FF":"��","%FF%FE":"��"},s=i.exec(e);s;){try{t[s[0]]=decodeURIComponent(s[0])}catch(e){var n=function(e){try{return decodeURIComponent(e)}catch(s){for(var t=e.match(r)||[],i=1;i<t.length;i++)t=(e=(function e(t,r){try{return[decodeURIComponent(t.join(""))]}catch(e){}if(1===t.length)return t;r=r||1;var i=t.slice(0,r),s=t.slice(r);return Array.prototype.concat.call([],e(i),e(s))})(t,i).join("")).match(r)||[];return e}}(s[0]);n!==s[0]&&(t[s[0]]=n)}s=i.exec(e)}t["%C2"]="�";for(var a=Object.keys(t),o=0;o<a.length;o++){var l=a[o];e=e.replace(RegExp(l,"g"),t[l])}return e}(e)}}},1857:e=>{var t=function(e){var t;return!!e&&"object"==typeof e&&"[object RegExp]"!==(t=Object.prototype.toString.call(e))&&"[object Date]"!==t&&e.$$typeof!==r},r="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function i(e,t){return!1!==t.clone&&t.isMergeableObject(e)?o(Array.isArray(e)?[]:{},e,t):e}function s(e,t,r){return e.concat(t).map(function(e){return i(e,r)})}function n(e){return Object.keys(e).concat(Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[])}function a(e,t){try{return t in e}catch(e){return!1}}function o(e,r,l){(l=l||{}).arrayMerge=l.arrayMerge||s,l.isMergeableObject=l.isMergeableObject||t,l.cloneUnlessOtherwiseSpecified=i;var c,u,d=Array.isArray(r);return d!==Array.isArray(e)?i(r,l):d?l.arrayMerge(e,r,l):(u={},(c=l).isMergeableObject(e)&&n(e).forEach(function(t){u[t]=i(e[t],c)}),n(r).forEach(function(t){(!a(e,t)||Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))&&(a(e,t)&&c.isMergeableObject(r[t])?u[t]=(function(e,t){if(!t.customMerge)return o;var r=t.customMerge(e);return"function"==typeof r?r:o})(t,c)(e[t],r[t],c):u[t]=i(r[t],c))}),u)}o.all=function(e,t){if(!Array.isArray(e))throw Error("first argument should be an array");return e.reduce(function(e,r){return o(e,r,t)},{})},e.exports=o},7728:e=>{e.exports=function(e,t){for(var r={},i=Object.keys(e),s=Array.isArray(t),n=0;n<i.length;n++){var a=i[n],o=e[a];(s?-1!==t.indexOf(a):t(a,o,e))&&(r[a]=o)}return r}},9742:e=>{e.exports=e=>encodeURIComponent(e).replace(/[!'()*]/g,e=>`%${e.charCodeAt(0).toString(16).toUpperCase()}`)},6318:(e,t,r)=>{r.r(t),r.d(t,{default:()=>s});var i=r(1152);class s extends i.Z{init(){document.getElementById("categoryItemsCount").textContent=this.el.textContent,this.pageUrl=new URL(window.location.href);let e=this.pageUrl.searchParams.get("p"),t=document.getElementById("cogi-additional-listing-content");t&&(parseInt(e)>1?(t.style.display="none",t.style.visibility="hidden"):(t.style.display="flex",t.style.visibility="visible"))}}},2940:(e,t,r)=>{let i=r(9742),s=r(1998),n=r(1231),a=r(7728),o=e=>null==e,l=Symbol("encodeFragmentIdentifier");function c(e){if("string"!=typeof e||1!==e.length)throw TypeError("arrayFormatSeparator must be single character string")}function u(e,t){return t.encode?t.strict?i(e):encodeURIComponent(e):e}function d(e,t){return t.decode?s(e):e}function p(e){let t=e.indexOf("#");return -1!==t&&(e=e.slice(0,t)),e}function h(e){let t=(e=p(e)).indexOf("?");return -1===t?"":e.slice(t+1)}function g(e,t){return t.parseNumbers&&!Number.isNaN(Number(e))&&"string"==typeof e&&""!==e.trim()?e=Number(e):t.parseBooleans&&null!==e&&("true"===e.toLowerCase()||"false"===e.toLowerCase())&&(e="true"===e.toLowerCase()),e}function f(e,t){c((t=Object.assign({decode:!0,sort:!0,arrayFormat:"none",arrayFormatSeparator:",",parseNumbers:!1,parseBooleans:!1},t)).arrayFormatSeparator);let r=function(e){let t;switch(e.arrayFormat){case"index":return(e,r,i)=>{if(t=/\[(\d*)\]$/.exec(e),e=e.replace(/\[\d*\]$/,""),!t){i[e]=r;return}void 0===i[e]&&(i[e]={}),i[e][t[1]]=r};
1case"bracket":return(e,r,i)=>{if(t=/(\[\])$/.exec(e),e=e.replace(/\[\]$/,""),!t){i[e]=r;return}if(void 0===i[e]){i[e]=[r];return}i[e]=[].concat(i[e],r)};case"colon-list-separator":return(e,r,i)=>{if(t=/(:list)$/.exec(e),e=e.replace(/:list$/,""),!t){i[e]=r;return}if(void 0===i[e]){i[e]=[r];return}i[e]=[].concat(i[e],r)};case"comma":case"separator":return(t,r,i)=>{let s="string"==typeof r&&r.includes(e.arrayFormatSeparator),n="string"==typeof r&&!s&&d(r,e).includes(e.arrayFormatSeparator);r=n?d(r,e):r;let a=s||n?r.split(e.arrayFormatSeparator).map(t=>d(t,e)):null===r?r:d(r,e);i[t]=a};case"bracket-separator":return(t,r,i)=>{let s=/(\[\])$/.test(t);if(t=t.replace(/\[\]$/,""),!s){i[t]=r?d(r,e):r;return}let n=null===r?[]:r.split(e.arrayFormatSeparator).map(t=>d(t,e));if(void 0===i[t]){i[t]=n;return}i[t]=[].concat(i[t],n)};default:return(e,t,r)=>{if(void 0===r[e]){r[e]=t;return}r[e]=[].concat(r[e],t)}}}(t),i=Object.create(null);if("string"!=typeof e||!(e=e.trim().replace(/^[?#&]/,"")))return i;for(let s of e.split("&")){if(""===s)continue;let[e,a]=n(t.decode?s.replace(/\+/g," "):s,"=");a=void 0===a?null:["comma","separator","bracket-separator"].includes(t.arrayFormat)?a:d(a,t),r(d(e,t),a,i)}for(let e of Object.keys(i)){let r=i[e];if("object"==typeof r&&null!==r)for(let e of Object.keys(r))r[e]=g(r[e],t);else i[e]=g(r,t)}return!1===t.sort?i:(!0===t.sort?Object.keys(i).sort():Object.keys(i).sort(t.sort)).reduce((e,t)=>{let r=i[t];return r&&"object"==typeof r&&!Array.isArray(r)?e[t]=function e(t){return Array.isArray(t)?t.sort():"object"==typeof t?e(Object.keys(t)).sort((e,t)=>Number(e)-Number(t)).map(e=>t[e]):t}(r):e[t]=r,e},Object.create(null))}t.extract=h,t.parse=f,t.stringify=(e,t)=>{if(!e)return"";c((t=Object.assign({encode:!0,strict:!0,arrayFormat:"none",arrayFormatSeparator:","},t)).arrayFormatSeparator);let r=r=>t.skipNull&&o(e[r])||t.skipEmptyString&&""===e[r],i=function(e){switch(e.arrayFormat){case"index":return t=>(r,i)=>{let s=r.length;return void 0===i||e.skipNull&&null===i||e.skipEmptyString&&""===i?r:null===i?[...r,[u(t,e),"[",s,"]"].join("")]:[...r,[u(t,e),"[",u(s,e),"]=",u(i,e)].join("")]};case"bracket":return t=>(r,i)=>void 0===i||e.skipNull&&null===i||e.skipEmptyString&&""===i?r:null===i?[...r,[u(t,e),"[]"].join("")]:[...r,[u(t,e),"[]=",u(i,e)].join("")];case"colon-list-separator":return t=>(r,i)=>void 0===i||e.skipNull&&null===i||e.skipEmptyString&&""===i?r:null===i?[...r,[u(t,e),":list="].join("")]:[...r,[u(t,e),":list=",u(i,e)].join("")];case"comma":case"separator":case"bracket-separator":{let t="bracket-separator"===e.arrayFormat?"[]=":"=";return r=>(i,s)=>void 0===s||e.skipNull&&null===s||e.skipEmptyString&&""===s?i:(s=null===s?"":s,0===i.length)?[[u(r,e),t,u(s,e)].join("")]:[[i,u(s,e)].join(e.arrayFormatSeparator)]}default:return t=>(r,i)=>void 0===i||e.skipNull&&null===i||e.skipEmptyString&&""===i?r:null===i?[...r,u(t,e)]:[...r,[u(t,e),"=",u(i,e)].join("")]}}(t),s={};for(let t of Object.keys(e))r(t)||(s[t]=e[t]);let n=Object.keys(s);return!1!==t.sort&&n.sort(t.sort),n.map(r=>{let s=e[r];return void 0===s?"":null===s?u(r,t):Array.isArray(s)?0===s.length&&"bracket-separator"===t.arrayFormat?u(r,t)+"[]":s.reduce(i(r),[]).join("&"):u(r,t)+"="+u(s,t)}).filter(e=>e.length>0).join("&")},t.parseUrl=(e,t)=>
1{t=Object.assign({decode:!0},t);let[r,i]=n(e,"#");return Object.assign({url:r.split("?")[0]||"",query:f(h(e),t)},t&&t.parseFragmentIdentifier&&i?{fragmentIdentifier:d(i,t)}:{})},t.stringifyUrl=(e,r)=>{r=Object.assign({encode:!0,strict:!0,[l]:!0},r);let i=p(e.url).split("?")[0]||"",s=t.extract(e.url),n=Object.assign(t.parse(s,{sort:!1}),e.query),a=t.stringify(n,r);a&&(a="?".concat(a));let o=function(e){let t="",r=e.indexOf("#");return -1!==r&&(t=e.slice(r)),t}(e.url);return e.fragmentIdentifier&&(o="#".concat(r[l]?u(e.fragmentIdentifier,r):e.fragmentIdentifier)),"".concat(i).concat(a).concat(o)},t.pick=(e,r,i)=>{i=Object.assign({parseFragmentIdentifier:!0,[l]:!1},i);let{url:s,query:n,fragmentIdentifier:o}=t.parseUrl(e,i);return t.stringifyUrl({url:s,query:a(n,r),fragmentIdentifier:o},i)},t.exclude=(e,r,i)=>{let s=Array.isArray(r)?e=>!r.includes(e):(e,t)=>!r(e,t);return t.pick(e,s,i)}},1231:e=>{e.exports=(e,t)=>{if(!("string"==typeof e&&"string"==typeof t))throw TypeError("Expected the arguments to be of type `string`");if(""===t)return[e];let r=e.indexOf(t);return -1===r?[e]:[e.slice(0,r),e.slice(r+t.length)]}},9610:(e,t,r)=>{r.d(t,{Z:()=>i});class i{static debounce(e,t){let r,i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(){for(var s=arguments.length,n=Array(s),a=0;a<s;a++)n[a]=arguments[a];i&&!r&&setTimeout(e.bind(e,...n),0),clearTimeout(r),r=setTimeout(e.bind(e,...n),t)}}}},4049:(e,t,r)=>{r.d(t,{Z:()=>s});var i=r(5140);class s{static isNode(e){return"object"==typeof e&&null!==e&&(e===document||e===window||e instanceof Node)}static hasAttribute(e,t){if(!s.isNode(e))throw Error("The element must be a valid HTML Node!");return"function"==typeof e.hasAttribute&&e.hasAttribute(t)}static getAttribute(e,t){let r=!(arguments.length>2)||void 0===arguments[2]||arguments[2];if(r&&!1===s.hasAttribute(e,t))throw Error('The required property "'.concat(t,'" does not exist!'));if("function"!=typeof e.getAttribute){if(r)throw Error("This node doesn't support the getAttribute function!");return}return e.getAttribute(t)}static getDataAttribute(e,t){let r=!(arguments.length>2)||void 0===arguments[2]||arguments[2],n=t.replace(/^data(|-)/,""),a=i.Z.toLowerCamelCase(n,"-");if(!s.isNode(e)){if(r)throw Error("The passed node is not a valid HTML Node!");return}if(void 0===e.dataset){if(r)throw Error("This node doesn't support the dataset attribute!");return}let o=e.dataset[a];if(void 0===o){if(r)throw Error('The required data attribute "'.concat(t,'" does not exist on ').concat(e,"!"));return o}return i.Z.parsePrimitive(o)}static querySelector(e,t){let r=!(arguments.length>2)||void 0===arguments[2]||arguments[2];if(r&&!s.isNode(e))throw Error("The parent node is not a valid HTML Node!");let i=e.querySelector(t)||!1;if(r&&!1===i)throw Error('The required element "'.concat(t,'" does not exist in parent node!'));return i}static querySelectorAll(e,t){let r=!(arguments.length>2)||void 0===arguments[2]||arguments[2];if(r&&!s.isNode(e))throw Error("The parent node is not a valid HTML Node!");let i=e.querySelectorAll(t);if(0===i.length&&(i=!1),r&&!1===i)throw Error('At least one item of "'.concat(t,'" must exist in parent node!'));return i}static getFocusableElements(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.body;return e.querySelectorAll('\n input:not([tabindex^="-"]):not([disabled]):not([type="hidden"]),\n select:not([tabindex^="-"]):not([disabled]),\n textarea:not([tabindex^="-"]):not([disabled]),\n button:not([tabindex^="-"]):not([disabled]),\n a[href]:not([tabindex^="-"]):not([disabled]),\n [tabindex]:not([tabindex^="-"]):not([disabled])\n ')}static getFirstFocusableElement(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.body;return this.getFocusableElements(e)[0]}static getLastFocusableElement(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document,t=this.getFocusableElements(e);return t[t.length-1]}}},4830:(e,t,r)=>{r.d(t,{Z:()=>i});class i{publish(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2&&void 0!==arguments[2]&&arguments[2],i=new CustomEvent(e,{detail:t,cancelable:r});return this.el.dispatchEvent(i),i}subscribe(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=this,s=e.split("."),n=r.scope?t.bind(r.scope):t;if(r.once&&!0===r.once){let t=n;n=function(r){i.unsubscribe(e),t(r)}}return this.el.addEventListener(s[0],n),this.listeners.push({splitEventName:s,opts:r,cb:n}),!0}unsubscribe(e){let t=e.split(".");return this.listeners=this.listeners.reduce((e,r)=>([...r.splitEventName].sort().toString()===t.sort().toString()?this.el.removeEventListener(r.splitEventName[0],r.cb):e.push(r),e),[]),!0}
1reset(){return this.listeners.forEach(e=>{this.el.removeEventListener(e.splitEventName[0],e.cb)}),this.listeners=[],!0}get el(){return this._el}set el(e){this._el=e}get listeners(){return this._listeners}set listeners(e){this._listeners=e}constructor(e=document){this._el=e,e.$emitter=this,this._listeners=[]}}},3266:(e,t,r)=>{r.d(t,{Z:()=>i});class i{static iterate(e,t){if(e instanceof Map||Array.isArray(e))return e.forEach(t);if(e instanceof FormData){for(var r of e.entries())t(r[1],r[0]);return}if(e instanceof NodeList)return e.forEach(t);if(e instanceof HTMLCollection)return Array.from(e).forEach(t);if(e instanceof Object)return Object.keys(e).forEach(r=>{t(e[r],r)});throw Error("The element type ".concat(typeof e," is not iterable!"))}}},5140:(e,t,r)=>{r.d(t,{Z:()=>i});class i{static ucFirst(e){return e.charAt(0).toUpperCase()+e.slice(1)}static lcFirst(e){return e.charAt(0).toLowerCase()+e.slice(1)}static toDashCase(e){return e.replace(/([A-Z])/g,"-$1").replace(/^-/,"").toLowerCase()}static toLowerCamelCase(e,t){let r=i.toUpperCamelCase(e,t);return i.lcFirst(r)}static toUpperCamelCase(e,t){return t?e.split(t).map(e=>i.ucFirst(e.toLowerCase())).join(""):i.ucFirst(e.toLowerCase())}static parsePrimitive(e){try{return/^\d+(.|,)\d+$/.test(e)&&(e=e.replace(",",".")),JSON.parse(e)}catch(t){return e.toString()}}}},9568:(e,t,r)=>{r.d(t,{Z:()=>l});var i=r(1857),s=r.n(i),n=r(4049),a=r(5140),o=r(4830);class l{init(){throw Error('The "init" method for the plugin "'.concat(this._pluginName,'" is not defined.'))}update(){}_init(){this._initialized||(this.init(),this._initialized=!0)}_update(){this._initialized&&this.update()}_mergeOptions(e){let t=a.Z.toDashCase(this._pluginName),r=n.Z.getDataAttribute(this.el,"data-".concat(t,"-config"),!1),i=n.Z.getAttribute(this.el,"data-".concat(t,"-options"),!1),o=[this.constructor.options,this.options,e];r&&o.push(window.PluginConfigManager.get(this._pluginName,r));try{i&&o.push(JSON.parse(i))}catch(e){throw console.error(this.el),Error('The data attribute "data-'.concat(t,'-options" could not be parsed to json: ').concat(e.message))}return s().all(o.filter(e=>e instanceof Object&&!(e instanceof Array)).map(e=>e||{}))}_registerInstance(){window.PluginManager.getPluginInstancesFromElement(this.el).set(this._pluginName,this),window.PluginManager.getPlugin(this._pluginName,!1).get("instances").push(this)}_getPluginName(e){return e||(e=this.constructor.name),e}constructor(e,t={},r=!1){if(!n.Z.isNode(e))throw Error("There is no valid element given.");this.el=e,this.$emitter=new o.Z(this.el),this._pluginName=this._getPluginName(r),this.options=this._mergeOptions(t),this._initialized=!1,this._registerInstance(),this._init()}}},1152:(e,t,r)=>{r.d(t,{Z:()=>d});var i=r(9568),s=r(3107),n=r(3266),a=r(4049),o=r(2940);let l=Object.freeze(new class{replaceFromMarkup(e,t){let r=!(arguments.length>2)||void 0===arguments[2]||arguments[2],i=e;"string"==typeof i&&(i=this._createMarkupFromString(i)),"string"==typeof t&&(t=[t]),this._replaceSelectors(i,t,r)}replaceElement(e,t){let r=!(arguments.length>2)||void 0===arguments[2]||arguments[2];return("string"==typeof e&&(e=a.Z.querySelectorAll(document,e,r)),"string"==typeof t&&(t=a.Z.querySelectorAll(document,t,r)),e instanceof NodeList&&t instanceof NodeList&&t.length>e.length)?(n.Z.iterate(t,t=>{n.Z.iterate(e,e=>{e.innerHTML&&e.className===t.className&&(t.innerHTML=e.innerHTML)})}),!0):e instanceof NodeList?(n.Z.iterate(e,(e,r)=>{e.innerHTML&&(t[r].innerHTML=e.innerHTML)}),!0):t instanceof NodeList?(n.Z.iterate(t,t=>{e.innerHTML&&(t.innerHTML=e.innerHTML)}),!0):!!t&&!!e&&!!e.innerHTML&&(t.innerHTML=e.innerHTML,!0)}_replaceSelectors(e,t,r){n.Z.iterate(t,t=>{let i=a.Z.querySelectorAll(e,t,r),s=a.Z.querySelectorAll(document,t,r);this.replaceElement(i,s,r)})}_createMarkupFromString(e){return this._domParser.parseFromString(e,"text/html")}constructor(){this._domParser=new DOMParser}});class c{static replaceFromMarkup(e,t,r){l.replaceFromMarkup(e,t,r)}static replaceElement(e,t,r){return l.replaceElement(e,t,r)}}var u=r(9610);class d extends i.Z{init(){this._registry=[],this.httpClient=new s.Z,this._urlFilterParams=o.parse(window.location.search),this._filterPanel=a.Z.querySelector(document,this.options.filterPanelSelector,!1),this._filterPanelActive=!!this._filterPanel,this._filterPanelActive&&(this._showResetAll=!1,this.activeFilterContainer=a.Z.querySelector(document,this.options.activeFilterContainerSelector),this.ariaLiveContainer=a.Z.querySelector(document,this.options.ariaLiveSelector,!1)),this._cmsProductListingWrapper=a.Z.querySelector(document,this.options.cmsProductListingWrapperSelector,!1),this._cmsProductListingWrapperActive=!!this._cmsProductListingWrapper,this._allFiltersInitializedDebounce=u.Z.debounce(this.sendDisabledFiltersRequest.bind(this),100),this._registerEvents()}refreshRegistry(){let e=this._registry.filter(e=>document.body.contains(e.el));this.init(),this._registry=e,window.PluginManager.initializePlugins()}
1changeListing(){let e=!(arguments.length>0)||void 0===arguments[0]||arguments[0],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this._buildRequest(e,t),this._filterPanelActive&&this._buildLabels()}registerFilter(e){this._registry.push(e),this._setFilterState(e),this.options.disableEmptyFilter&&this._allFiltersInitializedDebounce()}_setFilterState(e){Object.keys(this._urlFilterParams).length>0&&"function"==typeof e.setValuesFromUrl&&e.setValuesFromUrl(this._urlFilterParams)&&this._filterPanelActive&&(this._showResetAll=!0,this._buildLabels())}deregisterFilter(e){this._registry=this._registry.filter(t=>t!==e)}_fetchValuesOfRegisteredFilters(){let e={};return this._registry.forEach(t=>{let r=t.getValues();Object.keys(r).forEach(t=>{Object.prototype.hasOwnProperty.call(e,t)?Object.values(r[t]).forEach(r=>{e[t].push(r)}):e[t]=r[t]})}),e}_mapFilters(e){let t={};return Object.keys(e).forEach(r=>{let i=e[r];Array.isArray(i)&&(i=i.join("|")),"".concat(i).length&&(t[r]=i)}),t}_buildRequest(){let e=!(arguments.length>0)||void 0===arguments[0]||arguments[0],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=this._fetchValuesOfRegisteredFilters(),i=this._mapFilters(r);this._filterPanelActive&&(this._showResetAll=!!Object.keys(i).length),this.options.params&&Object.keys(this.options.params).forEach(e=>{i[e]=this.options.params[e]}),Object.entries(t).forEach(e=>{let[t,r]=e;i[t]=r});let s=o.stringify(i);this.sendDataRequest(s),delete i.slots,delete i["no-aggregations"],delete i["reduce-aggregations"],delete i["only-aggregations"],s=o.stringify(i),e&&this._updateHistory(s),this.options.scrollTopListingWrapper&&this._scrollTopOfListing()}_scrollTopOfListing(){let e=this._cmsProductListingWrapper.getBoundingClientRect();if(e.top>=0)return;let t=e.top+window.scrollY-this.options.scrollOffset;window.scrollTo({top:t,behavior:"smooth"})}_getDisabledFiltersParamsFromParams(e){let t=Object.assign({},{"only-aggregations":1,"reduce-aggregations":1},e);return delete t.p,delete t.order,delete t["no-aggregations"],t}_updateHistory(e){window.history.pushState({},"","".concat(window.location.pathname,"?").concat(e))}_buildLabels(){let e="";this._registry.forEach(t=>{let r=t.getLabels();r.length&&r.forEach(t=>{e+=this.getLabelTemplate(t)})}),this.activeFilterContainer.innerHTML=e;let t=window.Feature.isActive("ACCESSIBILITY_TWEAKS")?a.Z.querySelectorAll(this.activeFilterContainer,this.options.activeFilterLabelSelector,!1):a.Z.querySelectorAll(this.activeFilterContainer,".".concat(this.options.activeFilterLabelRemoveClass),!1);e.length&&(this._registerLabelEvents(t),this.createResetAllButton())}_registerLabelEvents(e){n.Z.iterate(e,e=>{e.addEventListener("click",()=>this.resetFilter(e))})}createResetAllButton(){this.activeFilterContainer.insertAdjacentHTML("beforeend",this.getResetAllButtonTemplate());let e=a.Z.querySelector(this.activeFilterContainer,this.options.resetAllFilterButtonSelector);e.removeEventListener("click",this.resetAllFilter.bind(this)),e.addEventListener("click",this.resetAllFilter.bind(this)),this._showResetAll||e.remove()}resetFilter(e){this._registry.forEach(t=>{t.reset(e.dataset.id)}),this._buildRequest(),this._buildLabels()}resetAllFilter(){this._registry.forEach(e=>{e.resetAll()}),this._buildRequest(),this._buildLabels()}getLabelTemplate(e){return window.Feature.isActive("ACCESSIBILITY_TWEAKS")?'\n <button\n class="'.concat(this.options.activeFilterLabelClasses,'"\n data-id="').concat(e.id,'"\n title="').concat(this.options.snippets.removeFilterAriaLabel,": ").concat(e.label,'"\n aria-label="').concat(this.options.snippets.removeFilterAriaLabel,": ").concat(e.label,'">\n ').concat(this.getLabelPreviewTemplate(e),"\n ").concat(e.label,'\n <span aria-hidden="true" class="ms-1 fs-4">×</span>\n </button>\n '):'\n <span class="'.concat(this.options.activeFilterLabelClass,'">\n ').concat(this.getLabelPreviewTemplate(e),'\n <span aria-hidden="true">').concat(e.label,'</span>\n <button class="').concat(this.options.activeFilterLabelRemoveClass,'"\n data-id="').concat(e.id,'"\n title="').concat(this.options.snippets.removeFilterAriaLabel,": ").concat(e.label,'"\n aria-label="').concat(this.options.snippets.removeFilterAriaLabel,": ").concat(e.label,'">\n ×\n </button>\n </span>\n ')}getLabelPreviewTemplate(e){let t=this.options.activeFilterLabelPreviewClass;
1return e.previewHex?'\n <span class="'.concat(t,'" style="background-color: ').concat(e.previewHex,';"></span>\n '):e.previewImageUrl?'\n <span class="'.concat(t,'" style="background-image: url(\'').concat(e.previewImageUrl,"');\"></span>\n "):""}getResetAllButtonTemplate(){return'\n <button class="'.concat(this.options.resetAllFilterButtonClasses,'" aria-label="').concat(this.options.snippets.resetAllFiltersAriaLabel,'">\n ').concat(this.options.snippets.resetAllButtonText,"\n </button>\n ")}addLoadingIndicatorClass(){this._filterPanel.classList.add(this.options.loadingIndicatorClass)}removeLoadingIndicatorClass(){this._filterPanel.classList.remove(this.options.loadingIndicatorClass)}addLoadingElementLoaderClass(){this._cmsProductListingWrapper.classList.add(this.options.loadingElementLoaderClass)}removeLoadingElementLoaderClass(){this._cmsProductListingWrapper.classList.remove(this.options.loadingElementLoaderClass)}sendDataRequest(e){this._filterPanelActive&&this.addLoadingIndicatorClass(),this._cmsProductListingWrapperActive&&this.addLoadingElementLoaderClass(),this.options.disableEmptyFilter&&this.sendDisabledFiltersRequest(),this.httpClient.get("".concat(this.options.dataUrl,"?").concat(e),e=>{this.renderResponse(e),this._filterPanelActive&&(this.removeLoadingIndicatorClass(),this._updateAriaLive()),this._cmsProductListingWrapperActive&&this.removeLoadingElementLoaderClass()})}sendDisabledFiltersRequest(){let e=this._fetchValuesOfRegisteredFilters(),t=this._mapFilters(e);this.options.params&&Object.keys(this.options.params).forEach(e=>{t[e]=this.options.params[e]}),this._allFiltersInitializedDebounce=()=>{};let r=this._getDisabledFiltersParamsFromParams(t);this.httpClient.get("".concat(this.options.filterUrl,"?").concat(o.stringify(r)),e=>{let t=JSON.parse(e);this._registry.forEach(e=>{"function"==typeof e.refreshDisabledState&&e.refreshDisabledState(t,r)})})}renderResponse(e){c.replaceFromMarkup(e,this.options.cmsProductListingSelector,!1),this._registry.forEach(e=>{"function"==typeof e.afterContentChange&&e.afterContentChange()}),window.PluginManager.initializePlugins(),this.$emitter.publish("Listing/afterRenderResponse",{response:e})}_updateAriaLive(){if(!this.options.ariaLiveUpdates||!this.ariaLiveContainer)return;let e=this.el.querySelector(this.options.cmsProductListingResultsSelector);this.ariaLiveContainer.innerHTML=e.dataset.ariaLiveText}_registerEvents(){window.onpopstate=this._onWindowPopstate.bind(this)}_onWindowPopstate(){this.refreshRegistry(),this._registry.forEach(e=>{0===Object.keys(this._urlFilterParams).length&&(this._urlFilterParams.p=1),this._setFilterState(e)}),this.options.disableEmptyFilter&&this._allFiltersInitializedDebounce(),this.changeListing(!1)}}d.options={dataUrl:"",filterUrl:"",params:{},filterPanelSelector:".filter-panel",cmsProductListingSelector:".cms-element-product-listing",cmsProductListingWrapperSelector:".cms-element-product-listing-wrapper",cmsProductListingResultsSelector:".js-listing-wrapper",activeFilterContainerSelector:".filter-panel-active-container",activeFilterLabelClass:"filter-active",activeFilterLabelClasses:"filter-active btn",activeFilterLabelSelector:".filter-active",activeFilterLabelRemoveClass:"filter-active-remove",activeFilterLabelPreviewClass:"filter-active-preview",resetAllFilterButtonClasses:"filter-reset-all btn btn-outline-danger",resetAllFilterButtonSelector:".filter-reset-all",loadingIndicatorClass:"is-loading",loadingElementLoaderClass:"has-element-loader",ariaLiveSelector:".filter-panel-aria-live",ariaLiveUpdates:!0,disableEmptyFilter:!1,snippets:{resetAllButtonText:"Reset all",resetAllFiltersAriaLabel:"Reset all filters",removeFilterAriaLabel:"Remove filter"},scrollTopListingWrapper:!0,scrollOffset:15}},3107:(e,t,r)=>{r.d(t,{Z:()=>i});class i{get(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"application/json",i=this._createPreparedRequest("GET",e,r);return this._sendRequest(i,null,t)}post(e,t,r){let i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"application/json";i=this._getContentType(t,i);let s=this._createPreparedRequest("POST",e,i);return this._sendRequest(s,t,r)}delete(e,t,r){let i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"application/json";i=this._getContentType(t,i);let s=this._createPreparedRequest("DELETE",e,i);return this._sendRequest(s,t,r)}patch(e,t,r){let i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"application/json";i=this._getContentType(t,i);let s=this._createPreparedRequest("PATCH",e,i);return this._sendRequest(s,t,r)}
1abort(){if(this._request)return this._request.abort()}setErrorHandlingInternal(e){this._errorHandlingInternal=e}_registerOnLoaded(e,t){t&&(!0===this._errorHandlingInternal?(e.addEventListener("load",()=>{t(e.responseText,e)}),e.addEventListener("abort",()=>{console.warn("the request to ".concat(e.responseURL," was aborted"))}),e.addEventListener("error",()=>{console.warn("the request to ".concat(e.responseURL," failed with status ").concat(e.status))}),e.addEventListener("timeout",()=>{console.warn("the request to ".concat(e.responseURL," timed out"))})):e.addEventListener("loadend",()=>{t(e.responseText,e)}))}_sendRequest(e,t,r){return this._registerOnLoaded(e,r),e.send(t),e}_getContentType(e,t){return e instanceof FormData&&(t=!1),t}_createPreparedRequest(e,t,r){return this._request=new XMLHttpRequest,this._request.open(e,t),this._request.setRequestHeader("X-Requested-With","XMLHttpRequest"),r&&this._request.setRequestHeader("Content-type",r),this._request}constructor(){this._request=null,this._errorHandlingInternal=!1}}}}]);
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.