1"use strict";(self.webpackChunkMGDBaseTheme=self.webpackChunkMGDBaseTheme||[]).push([[53008],{1857:t=>{var e=function(t){var e;return!!t&&"object"==typeof t&&"[object RegExp]"!==(e=Object.prototype.toString.call(t))&&"[object Date]"!==e&&t.$$typeof!==i},i="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function r(t,e){return!1!==e.clone&&e.isMergeableObject(t)?o(Array.isArray(t)?[]:{},t,e):t}function s(t,e,i){return t.concat(e).map(function(t){return r(t,i)})}function n(t){return Object.keys(t).concat(Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(t).filter(function(e){return Object.propertyIsEnumerable.call(t,e)}):[])}function l(t,e){try{return e in t}catch(t){return!1}}function o(t,i,a){(a=a||{}).arrayMerge=a.arrayMerge||s,a.isMergeableObject=a.isMergeableObject||e,a.cloneUnlessOtherwiseSpecified=r;var c,h,u=Array.isArray(i);return u!==Array.isArray(t)?r(i,a):u?a.arrayMerge(t,i,a):(h={},(c=a).isMergeableObject(t)&&n(t).forEach(function(e){h[e]=r(t[e],c)}),n(i).forEach(function(e){(!l(t,e)||Object.hasOwnProperty.call(t,e)&&Object.propertyIsEnumerable.call(t,e))&&(l(t,e)&&c.isMergeableObject(i[e])?h[e]=(function(t,e){if(!e.customMerge)return o;var i=e.customMerge(t);return"function"==typeof i?i:o})(e,c)(t[e],i[e],c):h[e]=r(i[e],c))}),h)}o.all=function(t,e){if(!Array.isArray(t))throw Error("first argument should be an array");return t.reduce(function(t,i){return o(t,i,e)},{})},t.exports=o},9025:(t,e,i)=>{i.d(e,{Z:()=>n});var r=i(4049);let s=Object.freeze(new class{translate(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(e.hasOwnProperty("%count%")){let i=t.split("|");i.length>1&&(t=this._translateFindPart(i,e["%count%"]))}for(let i in e){let r=e[i];t=t.replaceAll(i,r)}return t}translateFromElement(t,e){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};try{let s=r.Z.getDataAttribute(t,"translations");if(s){let t=s[e];return this.translate(t,i)}}catch(t){console.log(t)}return!1}_translateFindPart(t,e){let i=new RegExp("{(".concat(e,")}")),r=t.find(t=>i.test(t));return r||(r=t[t.length-1]),r.replace(i,"").trim()}});class n{static translate(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return s.translate(t,e)}static translateFromElement(t,e){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return s.translateFromElement(t,e,i)}}},3008:(t,e,i)=>{i.r(e),i.d(e,{FilterMultiSelectPluginOverrideFunc:()=>a,default:()=>c});var r=i(1857),s=i.n(r),n=i(400),l=i(4049),o=i(9025);let a=t=>{class e extends t{init(){this._resetFilter(),super.init(),this.isDropdown()?this._onDropdown():this.isModal()&&this._onModal(),this._updateButtons(),this.$emitter.subscribe("afterApplyFilters",this._resetFilter.bind(this)),this.$emitter.subscribe("afterCancelFilters",this._resetFilter.bind(this))}_onDropdown(){this.el.addEventListener("hide.bs.dropdown",t=>{t.clickEvent&&this._onApplyFilters()})}_onModal(){this._getModalSaveButton().addEventListener("click",this._onModalSave.bind(this))}_onChangeFilter(t){let e=t.target.id;this._changedFilters.indexOf(e)>-1?this._changedFilters.splice(this._changedFilters.indexOf(e),1):this._changedFilters.push(e),this.listing.updateFilters(),this._updateButtons()}_onModalSave(){this._changedFilters.length?this._onApplyFilters():this._onCancelFilters()}_onApplyFilters(){let t=this._changedFilters.length;this.applyFilters(),t&&this._toggleOpen()}_onCancelFilters(){this.cancelFilters(),this._toggleOpen()}applyFilters(){this._changedFilters.length&&super._onChangeFilter(),this.$emitter.publish("afterApplyFilters")}cancelFilters(){this._changedFilters.length&&this.listing.cancelFilters(),this.$emitter.publish("afterCancelFilters")}_toggleOpen(){let t=this._getMainFilterButton();if(t){if(this.isDropdown())new bootstrap.Dropdown(t).toggle();else if(this.isModal()){let e=t.dataset.bsTarget;e&&document.querySelector(e).querySelector("[data-bs-dismiss]").click()}}}_updateButtons(){if(this.isModal()){let t=this._getModalSaveButton();if(t){let e=o.Z.translateFromElement(t,"empty");this._changedFilters.length&&(e=o.Z.translateFromElement(t,"choose",{"%count%":this.selection.length})),t.innerHTML=e}}}_resetFilter(){this._changedFilters=[],this._updateButtons()}disableFilter(){}enableFilter(){}_getDropdown(){return l.Z.querySelector(this.el,".filter-multi-select-dropdown",!1)}_getModal(){return l.Z.querySelector(this.el,".filter-multi-select-modal",!1)}_getMainFilterButton(){return l.Z.querySelector(this.el,this.options.mainFilterButtonSelector,!1)}_getModalSaveButton(){return l.Z.querySelector(this.el,this.options.modalFilterButtonSelector,!1)}isDropdown(){return this.openType||(this.openType=this._getDropdown()?"dropdown":null),"dropdown"===this.openType}isModal(){return this.openType||(this.openType=this._getModal()?"modal":null),"modal"===this.openType}_updateCount(){super._updateCount(),this._updateButtons()}}return e.options=s()(n.Z.options,{modalFilterButtonSelector:".filter-multi-select-modal-save",checkboxSelector:".filter-multi-select-checkbox",listItemSelector:".filter-multi-select-list-element",translations:{applyFilter:window.filters.apply,cancelFilter:window.filters.cancel}}),e};class c extends a(n.Z){_updateCount(){super._updateCount(),c.customUpdateCount(this.counter,this.selection.length?this.selection.length:"")}static customUpdateCount(t,e){t.innerHTML=e?'<span class="filter-multi-select-count-inner">'.concat(e,"</span>"):""}}},4049:(t,e,i)=>{i.d(e,{Z:()=>s});var r=i(5140);class s{static isNode(t){return"object"==typeof t&&null!==t&&(t===document||t===window||t instanceof Node)}static hasAttribute(t,e){if(!s.isNode(t))throw Error("The element must be a valid HTML Node!");return"function"==typeof t.hasAttribute&&t.hasAttribute(e)}static getAttribute(t,e){let i=!(arguments.length>2)||void 0===arguments[2]||arguments[2];if(i&&!1===s.hasAttribute(t,e))throw Error('The required property "'.concat(e,'" does not exist!'));if("function"!=typeof t.getAttribute){if(i)throw Error("This node doesn't support the getAttribute function!");return}return t.getAttribute(e)}static getDataAttribute(t,e){let i=!(arguments.length>2)||void 0===arguments[2]||arguments[2],n=e.replace(/^data(|-)/,""),l=r.Z.toLowerCamelCase(n,"-");if(!s.isNode(t)){if(i)throw Error("The passed node is not a valid HTML Node!");return}if(void 0===t.dataset){if(i)throw Error("This node doesn't support the dataset attribute!");return}let o=t.dataset[l];
1if(void 0===o){if(i)throw Error('The required data attribute "'.concat(e,'" does not exist on ').concat(t,"!"));return o}return r.Z.parsePrimitive(o)}static querySelector(t,e){let i=!(arguments.length>2)||void 0===arguments[2]||arguments[2];if(i&&!s.isNode(t))throw Error("The parent node is not a valid HTML Node!");let r=t.querySelector(e)||!1;if(i&&!1===r)throw Error('The required element "'.concat(e,'" does not exist in parent node!'));return r}static querySelectorAll(t,e){let i=!(arguments.length>2)||void 0===arguments[2]||arguments[2];if(i&&!s.isNode(t))throw Error("The parent node is not a valid HTML Node!");let r=t.querySelectorAll(e);if(0===r.length&&(r=!1),i&&!1===r)throw Error('At least one item of "'.concat(e,'" must exist in parent node!'));return r}static getFocusableElements(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.body;return t.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 t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.body;return this.getFocusableElements(t)[0]}static getLastFocusableElement(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document,e=this.getFocusableElements(t);return e[e.length-1]}}},4830:(t,e,i)=>{i.d(e,{Z:()=>r});class r{publish(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=new CustomEvent(t,{detail:e,cancelable:i});return this.el.dispatchEvent(r),r}subscribe(t,e){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=this,s=t.split("."),n=i.scope?e.bind(i.scope):e;if(i.once&&!0===i.once){let e=n;n=function(i){r.unsubscribe(t),e(i)}}return this.el.addEventListener(s[0],n),this.listeners.push({splitEventName:s,opts:i,cb:n}),!0}unsubscribe(t){let e=t.split(".");return this.listeners=this.listeners.reduce((t,i)=>([...i.splitEventName].sort().toString()===e.sort().toString()?this.el.removeEventListener(i.splitEventName[0],i.cb):t.push(i),t),[]),!0}reset(){return this.listeners.forEach(t=>{this.el.removeEventListener(t.splitEventName[0],t.cb)}),this.listeners=[],!0}get el(){return this._el}set el(t){this._el=t}get listeners(){return this._listeners}set listeners(t){this._listeners=t}constructor(t=document){this._el=t,t.$emitter=this,this._listeners=[]}}},3266:(t,e,i)=>{i.d(e,{Z:()=>r});class r{static iterate(t,e){if(t instanceof Map||Array.isArray(t))return t.forEach(e);if(t instanceof FormData){for(var i of t.entries())e(i[1],i[0]);return}if(t instanceof NodeList)return t.forEach(e);if(t instanceof HTMLCollection)return Array.from(t).forEach(e);if(t instanceof Object)return Object.keys(t).forEach(i=>{e(t[i],i)});throw Error("The element type ".concat(typeof t," is not iterable!"))}}},5140:(t,e,i)=>{i.d(e,{Z:()=>r});class r{static ucFirst(t){return t.charAt(0).toUpperCase()+t.slice(1)}static lcFirst(t){return t.charAt(0).toLowerCase()+t.slice(1)}static toDashCase(t){return t.replace(/([A-Z])/g,"-$1").replace(/^-/,"").toLowerCase()}static toLowerCamelCase(t,e){let i=r.toUpperCamelCase(t,e);return r.lcFirst(i)}static toUpperCamelCase(t,e){return e?t.split(e).map(t=>r.ucFirst(t.toLowerCase())).join(""):r.ucFirst(t.toLowerCase())}static parsePrimitive(t){try{return/^\d+(.|,)\d+$/.test(t)&&(t=t.replace(",",".")),JSON.parse(t)}catch(e){return t.toString()}}}},9568:(t,e,i)=>{i.d(e,{Z:()=>a});var r=i(1857),s=i.n(r),n=i(4049),l=i(5140),o=i(4830);class a{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(t){let e=l.Z.toDashCase(this._pluginName),i=n.Z.getDataAttribute(this.el,"data-".concat(e,"-config"),!1),r=n.Z.getAttribute(this.el,"data-".concat(e,"-options"),!1),o=[this.constructor.options,this.options,t];i&&o.push(window.PluginConfigManager.get(this._pluginName,i));try{r&&o.push(JSON.parse(r))}catch(t){throw console.error(this.el),Error('The data attribute "data-'.concat(e,'-options" could not be parsed to json: ').concat(t.message))}return s().all(o.filter(t=>t instanceof Object&&!(t instanceof Array)).map(t=>t||{}))}_registerInstance(){window.PluginManager.getPluginInstancesFromElement(this.el).set(this._pluginName,this),window.PluginManager.getPlugin(this._pluginName,!1).get("instances").push(this)}_getPluginName(t){return t||(t=this.constructor.name),t}constructor(t,e={},i=!1){if(!n.Z.isNode(t))throw Error("There is no valid element given.");this.el=t,this.$emitter=new o.Z(this.el),this._pluginName=this._getPluginName(i),this.options=this._mergeOptions(e),this._initialized=!1,this._registerInstance(),this._init()}}},9304:(t,e,i)=>{i.d(e,{Z:()=>n});var r=i(9568),s=i(4049);
1class n extends r.Z{_init(){super._init(),this._validateMethods();let t=s.Z.querySelector(document,this.options.parentFilterPanelSelector);this.listing=window.PluginManager.getPluginInstanceFromElement(t,"Listing"),this.listing.registerFilter(this),this._preventDropdownClose()}_preventDropdownClose(){let t=s.Z.querySelector(this.el,this.options.dropdownSelector,!1);t&&t.addEventListener("click",t=>{t.stopPropagation()})}_validateMethods(){if("function"!=typeof this.getValues)throw Error("[".concat(this._pluginName,'] Needs the method "getValues"\''));if("function"!=typeof this.getLabels)throw Error("[".concat(this._pluginName,'] Needs the method "getLabels"\''));if("function"!=typeof this.reset)throw Error("[".concat(this._pluginName,'] Needs the method "reset"\''));if("function"!=typeof this.resetAll)throw Error("[".concat(this._pluginName,'] Needs the method "resetAll"\''))}}n.options={parentFilterPanelSelector:".cms-element-product-listing-wrapper",dropdownSelector:".filter-panel-item-dropdown"}},400:(t,e,i)=>{i.d(e,{Z:()=>a});var r=i(4049),s=i(3266),n=i(9304),l=i(1857),o=i.n(l);class a extends n.Z{init(){this.selection=[],this.counter=r.Z.querySelector(this.el,this.options.countSelector),this.mainFilterButton=r.Z.querySelector(this.el,this.options.mainFilterButtonSelector,!1),this._registerEvents()}_registerEvents(){let t=r.Z.querySelectorAll(this.el,this.options.checkboxSelector);s.Z.iterate(t,t=>{t.addEventListener("change",this._onChangeFilter.bind(this))})}getValues(){let t=r.Z.querySelectorAll(this.el,"".concat(this.options.checkboxSelector,":checked"),!1),e=[];t?s.Z.iterate(t,t=>{e.push(t.id)}):e=[],this.selection=e,this._updateCount();let i={};return i[this.options.name]=e,i}getLabels(){let t=r.Z.querySelectorAll(this.el,"".concat(this.options.checkboxSelector,":checked"),!1),e=[];return t?s.Z.iterate(t,t=>{e.push({label:t.dataset.label,id:t.id})}):e=[],e}setValuesFromUrl(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=!1,i=t[this.options.name],s=i?i.split("|"):[],n=this.selection.filter(t=>!s.includes(t)),l=s.filter(t=>!this.selection.includes(t));return(n.length>0||l.length>0)&&(e=!0),l.forEach(t=>{let e=r.Z.querySelector(this.el,'[id="'.concat(t,'"]'),!1);e&&(e.checked=!0,this.selection.push(e.id))}),n.forEach(t=>{this.reset(t),this.selection=this.selection.filter(e=>e!==t)}),this._updateCount(),e}_onChangeFilter(){this.listing.changeListing(!0,{p:1})}reset(t){let e=r.Z.querySelector(this.el,'[id="'.concat(t,'"]'),!1);e&&(e.checked=!1)}resetAll(){this.selection.filter=[];let t=r.Z.querySelectorAll(this.el,"".concat(this.options.checkboxSelector,":checked"),!1);t&&s.Z.iterate(t,t=>{t.checked=!1})}refreshDisabledState(t){let e=t[this.options.name];if(!e.entities||e.entities.length<1){this.disableFilter();return}this.enableFilter(),this._disableInactiveFilterOptions(e.entities.map(t=>t.id))}_disableInactiveFilterOptions(t){let e=r.Z.querySelectorAll(this.el,this.options.checkboxSelector);s.Z.iterate(e,e=>{!0!==e.checked&&(t.includes(e.id)?this.enableOption(e):this.disableOption(e))})}disableOption(t){let e=t.closest(this.options.listItemSelector);e.classList.add("disabled"),e.setAttribute("title",this.options.snippets.disabledFilterText),t.disabled=!0}enableOption(t){let e=t.closest(this.options.listItemSelector);e.removeAttribute("title"),e.classList.remove("disabled"),t.disabled=!1}enableAllOptions(){let t=r.Z.querySelectorAll(this.el,this.options.checkboxSelector);s.Z.iterate(t,t=>{this.enableOption(t)})}disableFilter(){let t=r.Z.querySelector(this.el,this.options.mainFilterButtonSelector);t.classList.add("disabled"),t.setAttribute("disabled","disabled"),t.setAttribute("title",this.options.snippets.disabledFilterText)}enableFilter(){let t=r.Z.querySelector(this.el,this.options.mainFilterButtonSelector);t.classList.remove("disabled"),t.removeAttribute("disabled"),t.removeAttribute("title")}_updateCount(){this.counter.textContent=this.selection.length?"(".concat(this.selection.length,")"):"",this._updateAriaLabel()}_updateAriaLabel(){if(this.options.snippets.ariaLabel){if(0===this.selection.length){this.mainFilterButton.setAttribute("aria-label",this.options.snippets.ariaLabel);return}this.mainFilterButton.setAttribute("aria-label","".concat(this.options.snippets.ariaLabel," (").concat(this.options.snippets.ariaLabelCount.replace("%count%",this.selection.length.toString()),")"))}}}a.options=o()(n.Z.options,{checkboxSelector:".filter-multi-select-checkbox",countSelector:".filter-multi-select-count",listItemSelector:".filter-multi-select-list-item",snippets:{disabledFilterText:"Filter not active",ariaLabel:"",ariaLabelCount:""},mainFilterButtonSelector:".filter-panel-item-toggle"})}}]);
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.