{"version":3,"sources":["webpack:///./assets/javascripts/modules/utils/FocusableElementUtils.js","webpack:///./node_modules/bootstrap/js/dist lazy ^\\.\\/.*\\.js$ namespace object","webpack:///./node_modules/flatpickr/dist/l10n lazy ^\\.\\/.*\\.js$ namespace object","webpack:///./assets/javascripts/modules/components/StoreLocatorComponent.js","webpack:///./assets/javascripts/modules/storelocator-subs/sl_filters.js","webpack:///./assets/javascripts/modules/storelocator-subs/sl_map.js","webpack:///./assets/javascripts/modules/storelocator-subs/sl_results.js","webpack:///./assets/javascripts/modules/storelocator-subs/sl_results_counter.js","webpack:///./assets/javascripts/modules/storelocator-subs/sl_search.js","webpack:///./assets/javascripts/modules/storelocator-subs/sl_storelocator.js","webpack:///./assets/javascripts/modules/storelocator-subs/sl_panel.js","webpack:///./assets/javascripts/modules/utils/DependencyInjector.js","webpack:///./assets/javascripts/modules/abstracts/Component.js"],"names":["$","__webpack_require__","d","__webpack_exports__","getFirstFocusable","toggleTabIndex","FOCUSABLE_ELEMENTS","parent","querySelector","join","makeTabbable","el","hasAttribute","setAttribute","getAttribute","removeAttribute","makeUntabbable","classList","contains","add","focusable","els","Array","prototype","slice","call","find","getFocusableElements","forEach","map","./alert.js","./button.js","./carousel.js","./collapse.js","./dropdown.js","./index.js","./modal.js","./popover.js","./scrollspy.js","./tab.js","./toast.js","./tooltip.js","./util.js","webpackAsyncContext","req","ids","Promise","all","e","then","id","t","resolve","Error","code","keys","Object","module","exports","./ar.js","./at.js","./be.js","./bg.js","./bn.js","./cat.js","./cs.js","./cy.js","./da.js","./de.js","./default.js","./eo.js","./es.js","./et.js","./fa.js","./fi.js","./fr.js","./gr.js","./he.js","./hi.js","./hr.js","./hu.js","./id.js","./it.js","./ja.js","./km.js","./ko.js","./kz.js","./lt.js","./lv.js","./mk.js","./mn.js","./ms.js","./my.js","./nl.js","./no.js","./pa.js","./pl.js","./pt.js","./ro.js","./ru.js","./si.js","./sk.js","./sl.js","./sq.js","./sr.js","./sv.js","./th.js","./tr.js","./uk.js","./vn.js","./zh.js","StoreLocatorComponent","Component","_get","__proto__","getPrototypeOf","this","window","InitGoogle","apiUrl","val","moduleLoader","loadExternalScript","Zero","Components","create","ZStoreLocator","ZMap","ZSearch","ZResults","ZFilters","ZResultsCounter","ZPanel","GEO_JSON","start","on","value","attr","document","trigger","Logger","element","_classCallCheck","_this","_possibleConstructorReturn","FiltersCounter","Selectors","ApplyFiltersBtn","ClearFiltersBtn","FilterInput","preventDefault","applyFilters","addClass","removeClass","resetFilters","hide","onFilterSelection","calculateFilters","onLabelCreation","filtersShortcut","clearAll","FiltersLabelsContainer","$state","StoreLocator","Filters","tot","serializeArray","length","text","self","show","delegate","ref","dataset","activeFilter","remove","prop","filters","querySelectorAll","empty","append","c","features","constructor","String","label","next","html","_iteratorNormalCompletion","_didIteratorError","_iteratorError","undefined","_step","_iterator","Symbol","iterator","done","item","err","return","filterArr","resultArr","_iteratorNormalCompletion2","_didIteratorError2","_iteratorError2","_step2","_iterator2","object","name","isArray","push","CAST","onFiltersLabelsCreation","Log","ZoomIn","zoom","ZoomOut","MapEl","Map","data","marker","StoreLocator:Init","onStoreLocatorInit","StoreLocator:GeoJson:Loaded","onGeoJsonLoaded","StoreLocator:Pin:Clicked","onClickedLightPin","StoreLocator:Pin:Unclicked","onUnclickedLightPin","StoreLocator:Pin:Hover","onHoverLightPin","StoreLocator:Pin:Unhover","onUnhoverLightPin","StoreLocator:List:Clicked","StoreLocator:List:Unclicked","StoreLocator:List:Hover","StoreLocator:List:Unhover","_this2","onLocationChange","location","Location","bounds","Bounds","navigateLocation","i","msg","_this3","info","styles","elementType","stylers","color","visibility","featureType","disableDefaultUI","scaleControl","fullscreenControl","gestureHandling","PromiseMap","GoogleMap","gmap","addMapEngine","GMap","bindStoreLocator","error","arguments","_this4","inCart","body","geojson","showPoint","usecluster","markers","hasOwnProperty","bindMarker","storeHidden","_this5","title","storeData","displayName","markerCode","getKey","PinHasBeenClicked","PrevMarkerCode","prev_marker","getMarker","setImageToMarker","_this6","Center","center","cluster","clusterIcon_","div_","index_","hover","brand","docroot","feature","image","Url","Size","w","h","ResultsEl","ResultsContainer","ToggleMoreResults","ResultPanelTrigger","TemplateCompile","ParsedTemplate","onLoadStores","bindEventOnResults","equalUtil","ifEquals","loadedStores","chunkedLoadedStores","Template","StoreListElement","ShowDetailsButton","HideDetailsButton","HighlightedClass","SelectedClass","DetailToggle","$el","currentTarget","innerHTML","off","Utils","JsonDa","Name","toLowerCase","store","key","parentLi","closest","store_id","storeElement","scrollCard","__msg__","Handlebars","registerHelper","lvalue","rvalue","options","inverse","fn","a","b","stores","Stores","size","properties","width","templateEl","compile","elContainer","elContainerOffset","offset","top","myElOffset","scrollTop","animate","position","left","scrollLeft","updateResultsCounter","resultsNumber","GeoLocationBtn","SearchBtn","InputSearch","cartClickAndCollectOpt","BlankSearchButton","disabled","navigate","InitialSearch","obj","onPlaceChanged","results","getUserLocation","checkInputSearchValue","Cart:Change:DeliveryMethod","onCartDeliveryMethodChanged","GeolocationButton","SearchButton","SearchInput","inputSearchLenght","navigator","geolocation","method","startsWith","clicked","currentLocation","timeout","geocoder","google","maps","Geocoder","coordinates","lat","lng","geocode","result","types","formatted_address","GoogleSearch","gsearch","addSearchEngine","GSearch","autoGeolocation","country","website","autocomplete","setComponentRestrictions","addListener","getPlace","searchedCountry","address_text","isCity","resType","address_components","place_id","geometry","JSON","parse","stringify","viewport","_type","GeocoderLocationType","RANGE_INTERPOLATED","ROOFTOP","indexOf","AddressType","PointOnMap","Generic","isCountry","short_name","Address","place","address","sl","storeLocatorState","StoreLocatorState","addState","onChangeLocation","onChangeBoundingBox","onChangeFilters","setResultsHeight","UseLocation","CurrentCountry","currentCountry","GRAB","geoloc","StoreLocator:Detail:Clicked","onShowDetailStore","InitialCountry","Pins","storeName","locationCenter","prefilter","assign","refreshGeoJsonViaAjax","g_bounds","getBounds","point","extend","LatLng","filterResults","sortResults","type","pins","LatLngBounds","south","west","north","east","Feats","Feat","g_point","_labelindex","_labelcolor","reject","listJson","withoutRadius","forceCountry","toUpperCase","_pin_req","abort","Ajax","get","traditional","content","fail","clearTimeout","TimerSearch","setTimeout","updateGeoJson","bind","Opened","target","timing","animateTime","togglePanel","closeSerivesPanel","panel","stop","height","min-height","elem","time","curHeight","autoHeight","css","attachbodyclass","closePanel","openPanel","autoAnimate","Storelocator:Filters:Applied","loadedDependency","existingDependency","saveDependency","lib","DependencyInjector","logStr","myName","console","debug","componentName","thenPromise","catchPromise","log","catch","res","locale","widgetName","url","script","createElement","src","addEventListener","appendChild","stack","Component_classCallCheck","$customEvents","CustomEvents","$matchMedia","match","$on","$emit","emit","$off","$one","one","$getFirstFocusable","warn"],"mappings":"6FAAA,SAAAA,GAAAC,EAAAC,EAAAC,EAAA,sBAAAC,IAAAH,EAAAC,EAAAC,EAAA,sBAAAE,IAAA,IAAMC,GAAsB,UAAW,6CAA8C,yBAA0B,2BAA4B,yBAA0B,mCAExJF,EAAoB,SAACG,GAChC,OAAOA,EAAOC,cAAcF,EAAmBG,KAAK,OAShDC,EAAe,SAACC,GAChBA,EAAGC,aAAa,iBAClBD,EAAGE,aAAa,WAAYF,EAAGG,aAAa,kBAE5CH,EAAGI,gBAAgB,aAIjBC,EAAiB,SAACL,GAClBA,EAAGC,aAAa,cAAgBD,EAAGM,UAAUC,SAAS,aACxDP,EAAGE,aAAa,gBAAiBF,EAAGG,aAAa,aAEnDH,EAAGM,UAAUE,IAAI,YACjBR,EAAGE,aAAa,YAAa,IAGlBR,EAAiB,SAACE,EAAQa,GACrC,IAAIC,EAvB8B,SAACV,GACnC,OAAOW,MAAMC,UAAUC,MAAMC,KAC3BzB,EAAEW,GAAIe,KAAKpB,EAAmBG,KAAK,OAqB3BkB,CAAqBpB,GAE/Ba,EACIC,EAAIO,QAAQlB,GACZW,EAAIO,QAAQZ,4CCjClB,IAAAa,GACAC,cACA,IACA,KAEAC,eACA,IACA,KAEAC,iBACA,IACA,KAEAC,iBACA,IACA,KAEAC,iBACA,IACA,EACA,KAEAC,cACA,IACA,KAEAC,cACA,IACA,KAEAC,gBACA,IACA,EACA,IACA,KAEAC,kBACA,IACA,KAEAC,YACA,IACA,KAEAC,cACA,IACA,KAEAC,gBACA,IACA,EACA,KAEAC,aACA,IACA,MAGA,SAAAC,EAAAC,GACA,IAAAC,EAAAhB,EAAAe,GACA,OAAAC,EAOAC,QAAAC,IAAAF,EAAArB,MAAA,GAAAK,IAAA5B,EAAA+C,IAAAC,KAAA,WACA,IAAAC,EAAAL,EAAA,GACA,OAAA5C,EAAAkD,EAAAD,EAAA,KARAJ,QAAAM,UAAAH,KAAA,WACA,IAAAD,EAAA,IAAAK,MAAA,uBAAAT,EAAA,KAEA,MADAI,EAAAM,KAAA,mBACAN,IAQAL,EAAAY,KAAA,WACA,OAAAC,OAAAD,KAAA1B,IAEAc,EAAAO,GAAA,IACAO,EAAAC,QAAAf,uBC5EA,IAAAd,GACA8B,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,YACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,gBACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEA9C,cACA,IACA,KAEA+C,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEAC,WACA,IACA,KAEA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AAQ6B,KAAR,IAAiB9B,EAAjB,KAA4BD,qCAQ9B,IAAIC,EAAStZ,KAAKmE,YAAYyB,KAC9B2T,QAAQK,IAAR,IAAgBN,EAAhB,0BAxCiB1Z","file":"components-StoreLocatorComponent.chunks.js","sourcesContent":["const FOCUSABLE_ELEMENTS = ['a[href]', 'input:not([disabled]):not([type=\"hidden\"])', 'select:not([disabled])', 'textarea:not([disabled])', 'button:not([disabled])', '[tabindex]:not([tabindex^=\"-\"])'];\n\nexport const getFirstFocusable = (parent) => {\n  return parent.querySelector(FOCUSABLE_ELEMENTS.join(','));\n};\n\nexport const getFocusableElements = (el) => {\n  return Array.prototype.slice.call(\n    $(el).find(FOCUSABLE_ELEMENTS.join(','))\n  )\n};\n\nconst makeTabbable = (el) => {\n  if (el.hasAttribute('data-tabindex')) {\n    el.setAttribute('tabindex', el.getAttribute('data-tabindex'));\n  } else {\n    el.removeAttribute('tabindex');\n  }\n};\n\nconst makeUntabbable = (el) => {\n  if (el.hasAttribute('tabindex') && !el.classList.contains('untabbed')) {\n    el.setAttribute('data-tabindex', el.getAttribute('tabindex'));\n  }\n  el.classList.add('untabbed');\n  el.setAttribute('tabindex', -1);\n};\n\nexport const toggleTabIndex = (parent, focusable) => {\n  var els = getFocusableElements(parent)\n  \n  focusable\n    ? els.forEach(makeTabbable)\n    : els.forEach(makeUntabbable)\n};","var map = {\n\t\"./alert.js\": [\n\t\t322,\n\t\t186\n\t],\n\t\"./button.js\": [\n\t\t323,\n\t\t187\n\t],\n\t\"./carousel.js\": [\n\t\t324,\n\t\t188\n\t],\n\t\"./collapse.js\": [\n\t\t325,\n\t\t189\n\t],\n\t\"./dropdown.js\": [\n\t\t326,\n\t\t2,\n\t\t190\n\t],\n\t\"./index.js\": [\n\t\t327,\n\t\t191\n\t],\n\t\"./modal.js\": [\n\t\t328,\n\t\t192\n\t],\n\t\"./popover.js\": [\n\t\t329,\n\t\t2,\n\t\t171,\n\t\t193\n\t],\n\t\"./scrollspy.js\": [\n\t\t330,\n\t\t194\n\t],\n\t\"./tab.js\": [\n\t\t331,\n\t\t195\n\t],\n\t\"./toast.js\": [\n\t\t332,\n\t\t196\n\t],\n\t\"./tooltip.js\": [\n\t\t321,\n\t\t2,\n\t\t171\n\t],\n\t\"./util.js\": [\n\t\t320,\n\t\t197\n\t]\n};\nfunction webpackAsyncContext(req) {\n\tvar ids = map[req];\n\tif(!ids) {\n\t\treturn Promise.resolve().then(function() {\n\t\t\tvar e = new Error(\"Cannot find module '\" + req + \"'\");\n\t\t\te.code = 'MODULE_NOT_FOUND';\n\t\t\tthrow e;\n\t\t});\n\t}\n\treturn Promise.all(ids.slice(1).map(__webpack_require__.e)).then(function() {\n\t\tvar id = ids[0];\n\t\treturn __webpack_require__.t(id, 7);\n\t});\n}\nwebpackAsyncContext.keys = function webpackAsyncContextKeys() {\n\treturn Object.keys(map);\n};\nwebpackAsyncContext.id = 291;\nmodule.exports = webpackAsyncContext;","var map = {\n\t\"./ar.js\": [\n\t\t333,\n\t\t198\n\t],\n\t\"./at.js\": [\n\t\t334,\n\t\t199\n\t],\n\t\"./be.js\": [\n\t\t335,\n\t\t200\n\t],\n\t\"./bg.js\": [\n\t\t336,\n\t\t201\n\t],\n\t\"./bn.js\": [\n\t\t337,\n\t\t202\n\t],\n\t\"./cat.js\": [\n\t\t338,\n\t\t203\n\t],\n\t\"./cs.js\": [\n\t\t339,\n\t\t204\n\t],\n\t\"./cy.js\": [\n\t\t340,\n\t\t205\n\t],\n\t\"./da.js\": [\n\t\t341,\n\t\t206\n\t],\n\t\"./de.js\": [\n\t\t342,\n\t\t207\n\t],\n\t\"./default.js\": [\n\t\t343,\n\t\t208\n\t],\n\t\"./eo.js\": [\n\t\t344,\n\t\t209\n\t],\n\t\"./es.js\": [\n\t\t345,\n\t\t210\n\t],\n\t\"./et.js\": [\n\t\t346,\n\t\t211\n\t],\n\t\"./fa.js\": [\n\t\t347,\n\t\t212\n\t],\n\t\"./fi.js\": [\n\t\t348,\n\t\t213\n\t],\n\t\"./fr.js\": [\n\t\t349,\n\t\t214\n\t],\n\t\"./gr.js\": [\n\t\t350,\n\t\t215\n\t],\n\t\"./he.js\": [\n\t\t351,\n\t\t216\n\t],\n\t\"./hi.js\": [\n\t\t352,\n\t\t217\n\t],\n\t\"./hr.js\": [\n\t\t353,\n\t\t218\n\t],\n\t\"./hu.js\": [\n\t\t354,\n\t\t219\n\t],\n\t\"./id.js\": [\n\t\t355,\n\t\t220\n\t],\n\t\"./index.js\": [\n\t\t356,\n\t\t257\n\t],\n\t\"./it.js\": [\n\t\t357,\n\t\t221\n\t],\n\t\"./ja.js\": [\n\t\t358,\n\t\t222\n\t],\n\t\"./km.js\": [\n\t\t359,\n\t\t223\n\t],\n\t\"./ko.js\": [\n\t\t360,\n\t\t224\n\t],\n\t\"./kz.js\": [\n\t\t361,\n\t\t225\n\t],\n\t\"./lt.js\": [\n\t\t362,\n\t\t226\n\t],\n\t\"./lv.js\": [\n\t\t363,\n\t\t227\n\t],\n\t\"./mk.js\": [\n\t\t364,\n\t\t228\n\t],\n\t\"./mn.js\": [\n\t\t365,\n\t\t229\n\t],\n\t\"./ms.js\": [\n\t\t366,\n\t\t230\n\t],\n\t\"./my.js\": [\n\t\t367,\n\t\t231\n\t],\n\t\"./nl.js\": [\n\t\t368,\n\t\t232\n\t],\n\t\"./no.js\": [\n\t\t369,\n\t\t233\n\t],\n\t\"./pa.js\": [\n\t\t370,\n\t\t234\n\t],\n\t\"./pl.js\": [\n\t\t371,\n\t\t235\n\t],\n\t\"./pt.js\": [\n\t\t372,\n\t\t236\n\t],\n\t\"./ro.js\": [\n\t\t373,\n\t\t237\n\t],\n\t\"./ru.js\": [\n\t\t374,\n\t\t238\n\t],\n\t\"./si.js\": [\n\t\t375,\n\t\t239\n\t],\n\t\"./sk.js\": [\n\t\t376,\n\t\t240\n\t],\n\t\"./sl.js\": [\n\t\t377,\n\t\t241\n\t],\n\t\"./sq.js\": [\n\t\t378,\n\t\t242\n\t],\n\t\"./sr.js\": [\n\t\t379,\n\t\t243\n\t],\n\t\"./sv.js\": [\n\t\t380,\n\t\t244\n\t],\n\t\"./th.js\": [\n\t\t381,\n\t\t245\n\t],\n\t\"./tr.js\": [\n\t\t382,\n\t\t246\n\t],\n\t\"./uk.js\": [\n\t\t383,\n\t\t247\n\t],\n\t\"./vn.js\": [\n\t\t384,\n\t\t248\n\t],\n\t\"./zh.js\": [\n\t\t385,\n\t\t249\n\t]\n};\nfunction webpackAsyncContext(req) {\n\tvar ids = map[req];\n\tif(!ids) {\n\t\treturn Promise.resolve().then(function() {\n\t\t\tvar e = new Error(\"Cannot find module '\" + req + \"'\");\n\t\t\te.code = 'MODULE_NOT_FOUND';\n\t\t\tthrow e;\n\t\t});\n\t}\n\treturn __webpack_require__.e(ids[1]).then(function() {\n\t\tvar id = ids[0];\n\t\treturn __webpack_require__.t(id, 7);\n\t});\n}\nwebpackAsyncContext.keys = function webpackAsyncContextKeys() {\n\treturn Object.keys(map);\n};\nwebpackAsyncContext.id = 292;\nmodule.exports = webpackAsyncContext;","import Component from '../abstracts/Component';\nimport {Zero, Components} from 'Zero';\nimport {ZFilters} from \"StoreLocatorSubcomponents/sl_filters.js\";\nimport {ZMap} from \"StoreLocatorSubcomponents/sl_map.js\";\nimport {ZResults} from \"StoreLocatorSubcomponents/sl_results.js\";\nimport {ZResultsCounter} from \"StoreLocatorSubcomponents/sl_results_counter.js\";\nimport {ZSearch} from \"StoreLocatorSubcomponents/sl_search.js\";\nimport {ZStoreLocator} from \"StoreLocatorSubcomponents/sl_storelocator.js\";\nimport {ZPanel} from \"StoreLocatorSubcomponents/sl_panel.js\";\n\nexport default class StoreLocatorComponent extends Component {\n\n  render() {\n    super.render();\n    let _this = this;\n\n    window.InitGoogle = function () {};\n    const googleApiKey = $(\"#googleApiKey\").val();\n    const googleLanguage = $(\"#googleLanguage\").val();\n\n    const apiUrl = `https://maps.googleapis.com/maps/api/js?v=3.36&key=${googleApiKey}&libraries=places,geometry&callback=InitGoogle&language=${googleLanguage}`;\n\n    this.moduleLoader.loadExternalScript(apiUrl).then(() => {\n      window.Zero = Zero;\n\n      Components.create('ZStoreLocator', ZStoreLocator);\n      Components.create('ZMap', ZMap);\n      Components.create('ZSearch', ZSearch);\n      Components.create('ZResults', ZResults);\n      Components.create('ZFilters', ZFilters);\n      Components.create('ZResultsCounter', ZResultsCounter);\n      Components.create('ZPanel', ZPanel);\n\n      window.GEO_JSON = {};\n\n      Zero.start( {} );\n    });\n\n\n    $('.js-collection-filter').on('click', function () {\n      let value = $(this).val();\n      let id = $(this).attr('id');\n      let collectionfilter = document.querySelector('.js-collection-prefilter');\n      collectionfilter.value = value;\n      $('.apply-filter-btn').trigger('click');\n    });\n  }\n}\n","import { Zero, Logger, Components } from 'Zero';\nimport $ from 'Vendor/jquery';\nconst Log = new Logger('Zero/StoreLocator/ZFilters');\n\nexport default class ZFilters extends Components {\n  get Selectors() {\n    return {\n      FiltersCounter: '.filters-counter',\n      ApplyFiltersBtn: '.apply-filter-btn',\n      ClearFiltersBtn: '.clear-filter-btn',\n      // ResetFiltersBtn: '.js-filters-reset',\n      FilterInput: 'input[name=\"features\"]',\n      FiltersLabelsContainer: '.js-mr_sl-filters-labels',\n    };\n  }\n\n  get react() {\n    return {\n      calculateFilters: function() {\n        var filters = Zero.$state.StoreLocator.Filters;\n        let tot = this.element.serializeArray().length;\n        this.FiltersCounter.text(tot);\n      },\n    };\n  }\n\n  constructor(element) {\n    super(element);\n\n    this.FiltersCounter = this.element.find(this.Selectors.FiltersCounter);\n    this.ApplyFiltersBtn = this.element.find(this.Selectors.ApplyFiltersBtn);\n    this.ClearFiltersBtn = this.element.find(this.Selectors.ClearFiltersBtn);\n    this.FilterInput = this.element.find(this.Selectors.FilterInput);\n    // this.ResetFiltersBtn = this.element.find(this.Selectors.ResetFiltersBtn);\n\n    this.ApplyFiltersBtn.on('click.filters', e => {\n      e.preventDefault();\n      let f = this.applyFilters();\n      this.element.addClass('is-filtered');\n      // this.CAST(\"Storelocator:Filter:Applied\", f);\n    });\n\n    this.ClearFiltersBtn.on('click.filters', () => {\n      this.element.removeClass('is-filtered');\n      this.resetFilters();\n      // this.CAST(\"Storelocator:Filter:Clear\", {});\n      // this.calculateFilters();\n      $('.clear-all-filter-btn').hide();\n    });\n\n\n    this.onFilterSelection();\n    this.calculateFilters();\n    this.onLabelCreation();\n    this.filtersShortcut();\n    this.clearAll();\n  }\n\n  onFilterSelection() {\n    var self = this;\n\n    $('.clear-all-filters-btn').hide();\n\n    self.FilterInput.on('change', function() {\n      self.onLabelCreation();\n\n      let n = $('input:checked').length;\n\n      if (n > 0) {\n        $('.clear-all-filters-btn').show();\n      } else {\n        $('.clear-all-filters-btn').hide();\n      }\n    });\n  }\n\n\n  clearAll() {\n    const self = this;\n\n    $('.js-filters-reset').on('click', function() {\n      self.resetFilters();\n      $(this).hide();\n    });\n  }\n\n  resetFilters() {\n    Zero.$state.StoreLocator.Filters = [];\n  }\n\n  // fake filters facets\n  filtersShortcut() {\n    const self = this;\n    $('body').delegate('.active-filter', 'click', function() {\n      const ref = this.dataset.activeFilter;\n      this.remove();\n      $(`#${ref}`).prop('checked', false);\n      self.applyFilters();\n      self.onLabelCreation();\n    });\n  }\n\n  onLabelCreation() {\n    let filters = document.querySelectorAll('.mm_sl-filter-input:checked');\n\n    if (filters.length > 0) {\n\n      $('#filter-counter').empty();\n      $('#filter-counter').append(`<span>(${filters.length})</span>`);\n    } else {\n\n      $('#filter-counter').empty();\n      $('#filter-counter').append(`<span>(0)</span>`);\n    }\n  }\n\n  onFiltersLabelsCreation() {\n    const c = this.Selectors.FiltersLabelsContainer;\n    let filters = Zero.$state.StoreLocator.Filters;\n    $(c).empty();\n    // change type depending on the number of filters selected..\n\n    const notEmptyFilters = Object.keys(filters).length !== 0;\n\n    if (notEmptyFilters && filters.features) {\n      switch (filters.features.constructor) {\n        case String:\n          if (\n            filters.features != '' &&\n            filters.features != 'PERSONA' &&\n            filters.features != 'MARINA_RINALDI'\n          ) {\n            const label = $(`#${filters.features}`)\n              .next()\n              .html();\n\n            $(c).append(\n              `<button class=\"active-filter\" data-active-filter=${\n                filters.features\n              }>\n                <span class=\"\">${label}</span>\n                <i class=\"icon-close\"></i>\n               </button>`\n            );\n          }\n          break;\n        case Array:\n          for (let item of filters.features) {\n            if (item != '' && item != 'PERSONA' && item != 'MARINA_RINALDI') {\n              const label = $(`#${item}`)\n                .next()\n                .html();\n\n              $(c).append(\n                `<button class=\"active-filter\" data-active-filter=${item}>\n                  <span class=\"\">${label}</span>\n                  <i class=\"icon-close\"></i>\n                </button>`\n              );\n            }\n          }\n          break;\n      }\n    }\n  }\n\n  applyFilters() {\n    const filterArr = this.element.serializeArray();\n    let resultArr = {};\n\n    for (let object of filterArr) {\n      let name = object.name;\n      let value = object.value;\n\n      if (value != '') {\n        if (resultArr[name]) {\n          if (!$.isArray(resultArr[name])) {\n            resultArr[name] = [resultArr[name]];\n          }\n          resultArr[name].push(value);\n        } else {\n          resultArr[name] = value;\n        }\n      }\n    }\n    this.CAST('Storelocator:Filters:Applied', {});\n\n    Zero.$state.StoreLocator.Filters = resultArr;\n\n    this.onFiltersLabelsCreation();\n    return resultArr;\n  }\n}\n\nexport { ZFilters };\n","import $ from 'Vendor/jquery';\nimport { Zero, Broadcast, Logger, Components } from 'Zero';\nimport { GoogleMap } from 'Vendor/@openmind/storelocator/dist/googlemap.umd.js';\n\nconst Log = new Logger('MC3_ZMap');\n\nexport default class ZMap extends Components {\n  get Messages() {\n    return {\n      'StoreLocator:Init': this.onStoreLocatorInit,\n      'StoreLocator:GeoJson:Loaded': this.onGeoJsonLoaded,\n      'StoreLocator:Pin:Clicked': this.onClickedLightPin,\n      'StoreLocator:Pin:Unclicked': this.onUnclickedLightPin,\n      'StoreLocator:Pin:Hover': this.onHoverLightPin,\n      'StoreLocator:Pin:Unhover': this.onUnhoverLightPin,\n      'StoreLocator:List:Clicked': this.onClickedLightPin,\n      'StoreLocator:List:Unclicked': this.onUnclickedLightPin,\n      'StoreLocator:List:Hover': this.onHoverLightPin,\n      'StoreLocator:List:Unhover': this.onUnhoverLightPin,\n    };\n  }\n\n  get Selectors() {\n    return {\n      Map: '#map-container',\n      ZoomIn: '#controls_zoom_in',\n      ZoomOut: '#controls_zoom_out',\n    };\n  }\n\n  get react() {\n    return {\n      onLocationChange: () => {\n        var location = Zero.$state.StoreLocator.Location;\n        var bounds = location && location.Bounds;\n        if (location && bounds) {\n          this.StoreLocator.navigateLocation(bounds).then(() => {\n            Log.i('Map has navigated');\n            this.CAST('StoreLocator:Map:Navigated', { bounds });\n          });\n        }\n      },\n    };\n  }\n\n  constructor(element) {\n    super(element);\n\n    this.element.find(this.Selectors.ZoomIn).on('click.zmap', () => {\n      this.StoreLocator.zoom = 1;\n    });\n\n    this.element.find(this.Selectors.ZoomOut).on('click.zmap', () => {\n      this.StoreLocator.zoom = -1;\n    });\n\n    this.MapEl = this.element.find(this.Selectors.Map);\n\n    this.data.marker = this.data.marker || {};\n  }\n\n  onStoreLocatorInit(msg) {\n    this.StoreLocator = msg.StoreLocator;\n\n    Log.info('Got storelocator for', this.element);\n\n    const _styles = [\n      { elementType: 'geometry', stylers: [{ color: '#f5f5f5' }] },\n      { elementType: 'labels.icon', stylers: [{ visibility: 'off' }] },\n      { elementType: 'labels.text.fill', stylers: [{ color: '#616161' }] },\n      { elementType: 'labels.text.stroke', stylers: [{ color: '#f5f5f5' }] },\n      {\n        featureType: 'administrative.land_parcel',\n        elementType: 'labels.text.fill',\n        stylers: [{ color: '#bdbdbd' }],\n      },\n      {\n        featureType: 'poi',\n        elementType: 'geometry',\n        stylers: [{ color: '#eeeeee' }],\n      },\n      {\n        featureType: 'poi',\n        elementType: 'labels.text.fill',\n        stylers: [{ color: '#757575' }],\n      },\n      {\n        featureType: 'poi.park',\n        elementType: 'geometry',\n        stylers: [{ color: '#e5e5e5' }],\n      },\n      {\n        featureType: 'poi.park',\n        elementType: 'labels.text.fill',\n        stylers: [{ color: '#9e9e9e' }],\n      },\n      {\n        featureType: 'road',\n        elementType: 'geometry',\n        stylers: [{ color: '#ffffff' }],\n      },\n      {\n        featureType: 'road.arterial',\n        elementType: 'labels.text.fill',\n        stylers: [{ color: '#757575' }],\n      },\n      {\n        featureType: 'road.highway',\n        elementType: 'geometry',\n        stylers: [{ color: '#dadada' }],\n      },\n      {\n        featureType: 'road.highway',\n        elementType: 'labels.text.fill',\n        stylers: [{ color: '#616161' }],\n      },\n      {\n        featureType: 'road.local',\n        elementType: 'labels.text.fill',\n        stylers: [{ color: '#9e9e9e' }],\n      },\n      {\n        featureType: 'transit.line',\n        elementType: 'geometry',\n        stylers: [{ color: '#e5e5e5' }],\n      },\n      {\n        featureType: 'transit.station',\n        elementType: 'geometry',\n        stylers: [{ color: '#eeeeee' }],\n      },\n      {\n        featureType: 'water',\n        elementType: 'geometry',\n        stylers: [{ color: '#c9c9c9' }],\n      },\n      {\n        featureType: 'water',\n        elementType: 'geometry.fill',\n        stylers: [{ color: '#fcf6e7' }],\n      },\n      {\n        featureType: 'water',\n        elementType: 'labels.text.fill',\n        stylers: [{ color: '#9e9e9e' }],\n      },\n    ];\n\n    this.data.map = this.data.map || {};\n    this.data.map.styles = _styles;\n    this.data.map.disableDefaultUI = true;\n    this.data.map.scaleControl = true;\n    this.data.map.fullscreenControl = false;\n    this.data.map.gestureHandling = 'cooperative';\n\n    this.PromiseMap = new GoogleMap(\n      this.StoreLocator,\n      this.MapEl,\n      this.data.map\n    );\n\n    this.PromiseMap.then(\n      gmap => {\n        this.StoreLocator.addMapEngine('GoogleMap', (this.GMap = gmap));\n\n        this.bindStoreLocator();\n\n        this.onLocationChange();\n\n        this.CAST('StoreLocator:Map:Ready', { map: gmap });\n      },\n      function() {\n        Log.error('Cannot bind GMap engine', arguments);\n        throw 'Cannot bind GMap engine';\n      }\n    );\n  }\n\n  onGeoJsonLoaded(msg) {\n    const inCart = document.body.classList.contains('t-cart');\n    let geojson = msg.geojson;\n\n    this.PromiseMap.then(() => {\n      this.StoreLocator.showPoint(geojson, !!this.data.usecluster).then(\n        markers => {\n          for (let marker of markers) {\n            if (inCart) {\n              if (marker.data.features.hasOwnProperty('CLICK_AND_COLLECT')) {\n                this.bindMarker(marker);\n              }\n            } else {\n              if (!marker.data.storeHidden) {\n                this.bindMarker(marker);\n              }\n            }\n          }\n        }\n      );\n    });\n  }\n\n  bindMarker(marker) {\n\n    marker.title = marker.storeData.displayName;\n\n    marker.on('mouseover', () => {\n      this.CAST('StoreLocator:Pin:Hover', { marker: marker });\n    });\n\n    marker.on('mouseout', () => {\n      let markerCode = marker.getKey();\n      if (this.PinHasBeenClicked) {\n        if (markerCode !== this.PrevMarkerCode) {\n          this.CAST('StoreLocator:Pin:Unhover', { marker: marker });\n        }\n      } else {\n        this.CAST('StoreLocator:Pin:Unhover', { marker: marker });\n      }\n    });\n\n\n    marker.on('click', () => {\n      let markerCode = marker.getKey();\n\n      if (this.PrevMarkerCode) {\n        let prev_marker = this.StoreLocator.getMarker(this.PrevMarkerCode);\n        if (prev_marker) {\n          this.CAST('StoreLocator:Pin:Unclicked', { marker: prev_marker });\n        }\n      }\n\n      if ((this.PinHasBeenClicked = markerCode !== this.PrevMarkerCode)) {\n        this.CAST('StoreLocator:Pin:Clicked', { marker: marker });\n      }\n    });\n\n    this.setImageToMarker(marker, false);\n  }\n\n  bindStoreLocator() {\n    this.StoreLocator.on('moveinmap.zmap navigateTo.zmap', (e, map) => {\n      Log.i('Map has been moved');\n      Zero.$state.StoreLocator.Map.Center = map.center;\n      Zero.$state.StoreLocator.Map.Bounds = map.bounds;\n    });\n\n    this.StoreLocator.on('mapzoom.zmap mappan.zmap', (e, map) => {\n      this.CAST('StoreLocator:Map:Moved', {\n        center: map ? map.center : null,\n        bounds: map ? map.bounds : null,\n      });\n    });\n  }\n\n  onClickedLightPin(msg) {\n    let marker = msg.marker;\n\n    this.PrevMarkerCode = marker.getKey();\n\n    this.setImageToMarker(marker, true);\n  }\n\n  onUnclickedLightPin(msg) {\n    let marker = msg.marker;\n\n    this.setImageToMarker(marker, false);\n\n    this.PrevMarkerCode = '';\n  }\n\n  onHoverLightPin(msg) {\n    let marker = msg.marker;\n\n    this.setImageToMarker(marker, true);\n\n    if (\n      marker.cluster &&\n      marker.cluster.clusterIcon_ &&\n      marker.cluster.clusterIcon_.div_\n    ) {\n      $(marker.cluster.clusterIcon_.div_).addClass(\n        `cluster${marker.cluster.clusterIcon_.index_ - 1}-hov`\n      );\n    }\n  }\n\n  onUnhoverLightPin(msg) {\n    let marker = msg.marker;\n\n    this.setImageToMarker(marker, false);\n\n    if (\n      marker.cluster &&\n      marker.cluster.clusterIcon_ &&\n      marker.cluster.clusterIcon_.div_\n    ) {\n      $(marker.cluster.clusterIcon_.div_).removeClass(\n        `cluster${marker.cluster.clusterIcon_.index_ - 1}-hov`\n      );\n    }\n  }\n\n  setImageToMarker(marker, hover) {\n    var brand = '';\n    var docroot = $('html').data('publicPath');\n    if (marker != null && marker.data != null) {\n      var store = marker.data;\n      var features = store.features;\n\n      for (var feature in features) {\n        if (feature == 'MARINA_RINALDI' || feature == 'PERSONA') {\n          brand = feature;\n        }\n      }\n\n      var image = '';\n      if (brand == 'PERSONA') {\n        if(hover){\n          image = docroot + '/markers/persona-pin-hov.svg';\n        }else {\n          image = docroot + '/markers/persona-pin.svg';\n        }\n      } else {\n        if(hover){\n          image = docroot + '/markers/marinarinaldi-pin-hov.svg';\n        }else {\n          image = docroot + '/markers/marinarinaldi-pin.svg';\n        }\n      }\n\n      marker.image = {\n        Url: image,\n        Size: {\n          w: 44,\n          h: 44\n        }\n      }\n\n    }\n\n  }\n\n}\n\nexport { ZMap };\n","import { Zero, Logger, Components, Utils } from 'Zero';\nimport Handlebars from 'Vendor/handlebars/dist/handlebars.js';\n\nconst Log = new Logger('Zero/StoreLocator/ZResults');\n\nexport default class ZResults extends Components {\n  get Messages() {\n    return {\n      'StoreLocator:Init': this.onStoreLocatorInit,\n      'StoreLocator:Pin:Clicked': this.onClickedLightPin,\n      'StoreLocator:Pin:Unclicked': this.onUnclickedLightPin,\n      'StoreLocator:Pin:Hover': this.onHoverLightPin,\n      'StoreLocator:Pin:Unhover': this.onUnhoverLightPin,\n      'StoreLocator:List:Clicked': this.onClickedLightPin,\n      'StoreLocator:List:Unclicked': this.onUnclickedLightPin,\n      'StoreLocator:List:Hover': this.onHoverLightPin,\n      'StoreLocator:List:Unhover': this.onUnhoverLightPin,\n    };\n  }\n\n  get Selectors() {\n    return {\n      Template: '#template-store',\n      ResultsContainer: '#results-list-container',\n      StoreListElement: 'li.js-store-item',\n      ShowDetailsButton: '.js-show-detail',\n      HideDetailsButton: '.js-hide-detail',\n      HighlightedClass: 'highlighted',\n      SelectedClass: 'selected',\n      DetailToggle: '.js-detail-toggle',\n      ToggleMoreResults: '.js-more-C-and-C-results'\n    };\n  }\n\n  constructor(element) {\n    super(element);\n\n    this.ResultsEl = this.element.find(this.Selectors.ResultsContainer);\n    this.ToggleMoreResults = this.element.find(this.Selectors.ToggleMoreResults)\n    this.ResultPanelTrigger = this.element.find(\n      this.Selectors.ResultPanelTrigger\n    );\n    this.TemplateCompile = this.ParsedTemplate;\n\n    this.onLoadStores();\n    this.bindEventOnResults();\n    this.equalUtil();\n    this.ifEquals();\n\n    this.loadedStores = [];\n    this.chunkedLoadedStores = [];\n  }\n\n\n  get react() {\n    return {\n      onLoadStores: function () {\n        const inCart = document.body.classList.contains('t-cart');\n        var stores = Zero.$state.StoreLocator.Stores;\n        this.ResultsEl[0].innerHTML = ''; // faster than jquery\n        this.loadedStores = [];\n        this.chunkedLoadedStores = [];\n\n        let size = 0;\n        if (inCart) {\n          if (stores && stores.features) {\n            let html = [];\n            const maxSize = 3;\n\n            for (var i = 0, store; (store = stores.features[i++]);) {\n              if (store.properties.features.hasOwnProperty('CLICK_AND_COLLECT')) {\n                this.loadedStores.push(this.TemplateCompile(store.properties));\n                size++;\n              }\n            }\n\n            if ($(window).width() < 768 && this.loadedStores.length < maxSize) {\n              this.ToggleMoreResults[0].classList.remove('d-flex');\n              this.ToggleMoreResults[0].classList.add('d-none');\n            }\n\n            if ($(window).width() < 768 && this.loadedStores.length > maxSize) {\n              this.ToggleMoreResults[0].classList.add('d-flex');\n              this.ToggleMoreResults[0].classList.remove('d-none');\n              this.chunkedLoadedStores = this.loadedStores.slice(0, 3)\n              this.ResultsEl[0].innerHTML = this.chunkedLoadedStores.join('');\n            } else {\n              this.ResultsEl[0].innerHTML = this.loadedStores.join('');\n            }\n          }\n        } else {\n          if (stores && stores.features) {\n            for (var i = 0, store; (store = stores.features[i++]);) {\n              if (!store.properties.storeHidden) {\n                this.loadedStores.push(this.TemplateCompile(store.properties));\n                size++;\n              }\n            }\n            this.ResultsEl[0].innerHTML = this.loadedStores.join('');\n          }\n        }\n\n        size > 0 ? this.element.removeClass('is-empty') : this.element.addClass('is-empty');\n      },\n    };\n  }\n\n  get ParsedTemplate() {\n    let templateEl = this.element.find(this.Selectors.Template);\n    return Handlebars.compile(templateEl[0].innerHTML);\n  }\n\n  onStoreLocatorInit(msg) {\n    this.StoreLocator = msg.StoreLocator;\n  }\n\n\n  bindEventOnResults() {\n\n    this.ToggleMoreResults.on('click', e => {\n      e.preventDefault();\n    const $el = $(e.currentTarget);\n    this.ResultsEl[0].innerHTML = this.loadedStores.join('');\n    $el.removeClass('d-flex');\n    $el.addClass('d-none');\n  }\n  );\n\n    this.ResultsEl.off('mouseenter mouseleave').on(\n      'mouseenter',\n      this.Selectors.StoreListElement,\n      e => {\n      if (this.PinHasBeenClicked) {\n      return;\n    }\n    let data = Utils.JsonDa.data(e.currentTarget, this.Name.toLowerCase());\n    let marker = this.StoreLocator.getMarker(data.store.key);\n    if (marker) {\n      this.CAST('StoreLocator:List:Hover', { marker: marker });\n    }\n  }\n  );\n\n    this.ResultsEl.on('mouseleave', this.Selectors.StoreListElement, e => {\n      if (this.PinHasBeenClicked) {\n      return;\n    }\n    let data = Utils.JsonDa.data(e.currentTarget, this.Name.toLowerCase());\n    let marker = this.StoreLocator.getMarker(data.store.key);\n    if (marker) {\n      this.CAST('StoreLocator:List:Unhover', { marker: marker });\n    }\n  });\n\n    //show\n    this.ResultsEl.on(\n      'click',\n      `${this.Selectors.StoreListElement} ${this.Selectors.ShowDetailsButton}`, e => {\n      e.preventDefault();\n    let $this = this.element.find(e.currentTarget);\n    let parentLi = $this.closest(this.Selectors.StoreListElement);\n    let data = Utils.JsonDa.data(parentLi, this.Name.toLowerCase());\n    let prev_marker_code = this.PrevMarkerCode;\n    this.CAST('StoreLocator:Detail:Clicked', { store_id: data.store.id });\n    this.CAST('StoreLocator:Detail:onCloseResults');\n  }\n  );\n\n    // hide\n    this.ResultsEl.on(\n      'click',\n      `${this.Selectors.StoreListElement} ${this.Selectors.HideDetailsButton}`, e => {\n      e.preventDefault();\n    var $this = this.element.find(e.currentTarget);\n    var parentLi = $this.closest(this.Selectors.StoreListElement);\n    let data = Utils.JsonDa.data(parentLi, this.Name.toLowerCase());\n    let marker = this.StoreLocator.getMarker(data.store.key);\n\n    if (marker) {\n      this.CAST('StoreLocator:List:Unclicked', { marker: marker });\n    }\n\n    this.PrevMarkerCode = '';\n  }\n  );\n  }\n\n  onClickedLightPin(msg) {\n    let marker = msg.marker;\n    let code = marker.getKey();\n    let storeElement = this.ResultsEl.find(\n      `${this.Selectors.StoreListElement}[data-${\n        this.Name\n        }-store-key='${code}']`\n    );\n\n    storeElement.addClass(this.Selectors.SelectedClass);\n\n    ZResults.scrollCard(this, storeElement);\n\n    this.PinHasBeenClicked = true;\n    this.PrevMarkerCode = code;\n  }\n\n  onUnclickedLightPin(msg) {\n    let marker = msg.marker;\n    let code = marker.getKey();\n    let storeElement = this.ResultsEl.find(\n      `${this.Selectors.StoreListElement}[data-${\n        this.Name\n        }-store-key='${code}']`\n    );\n\n    storeElement.removeClass(\n      `${this.Selectors.SelectedClass} ${this.Selectors.HighlightedClass}`\n    );\n    this.PinHasBeenClicked = false;\n    this.PrevMarkerCode = null;\n  }\n\n  onHoverLightPin(msg) {\n    let marker = msg.marker;\n    let code = marker.getKey();\n    let storeElement = this.ResultsEl.find(\n      `${this.Selectors.StoreListElement}[data-${\n        this.Name\n        }-store-key='${code}']`\n    );\n\n    storeElement.addClass(this.Selectors.HighlightedClass);\n\n    if (msg.__msg__ === 'StoreLocator:Pin:Hover') {\n      ZResults.scrollCard(this, storeElement);\n    }\n  }\n\n  static scrollCard(element, storeElement) {\n    let elContainer = element.element;\n    if($( window ).width() >= 1280) {\n      let elContainerOffset = elContainer.offset().top;\n      let actScrollTop = elContainer.scrollTop();\n      let myElOffset = actScrollTop + storeElement.offset().top - elContainerOffset;\n      elContainer.animate({ scrollTop: myElOffset }, 400);\n    } else {\n      let elContainerOffset = elContainer.position().left;\n      let actScrollTop = elContainer.scrollLeft();\n      let myElOffset = actScrollTop + storeElement.offset().left - elContainerOffset;\n      elContainer.animate({'scrollLeft': myElOffset}, 500);\n    }\n\n\n  }\n\n  onUnhoverLightPin(msg) {\n    let marker = msg.marker;\n    let code = marker.getKey();\n    let storeElement = this.ResultsEl.find(\n      `${this.Selectors.StoreListElement}[data-${\n        this.Name\n        }-store-key='${code}']`\n    );\n\n    storeElement.removeClass(this.Selectors.HighlightedClass);\n  }\n\n  equalUtil() {\n    Handlebars.registerHelper('equal', function(lvalue, rvalue, options) {\n      if (arguments.length < 3)\n        throw new Error('Handlebars Helper equal needs 2 parameters');\n      if (lvalue != rvalue) {\n        return options.inverse(this);\n      } else {\n        return options.fn(this);\n      }\n    });\n  }\n\n  ifEquals() {\n    Handlebars.registerHelper('ifEquals', function(a, b, options) {\n      if (a === b) {\n        return options.fn(this);\n      }\n\n      return options.inverse(this);\n    });\n  }\n}\n\nexport { ZResults };\n","import {Zero, Logger, Components, Utils} from 'Zero';\n\nconst Log = new Logger(\"Zero/StoreLocator/ZResultsCounter\");\n\nexport default class ZResultsCounter extends Components {\n\n  get Messages() {\n    return {\n      \"StoreLocator:GeoJson:Loaded\": this.updateResultsCounter\n    };\n  }\n\n  constructor(element) {\n    super(element);\n  }\n\n  updateResultsCounter(msg) {\n    const inCart = document.body.classList.contains('t-cart');\n\n    if (msg.geojson && msg.geojson.features) {\n      var resultsNumber = 0;\n      for (var i = 0, store; (store = msg.geojson.features[i++]);) {\n        if (inCart) {\n          if (store.properties.features.hasOwnProperty('CLICK_AND_COLLECT')) {\n            resultsNumber++;\n          }\n        } else {\n          if (!store.properties.storeHidden) {\n            resultsNumber++;\n          }\n        }\n      }\n\n      this.element.text( resultsNumber );\n    } else {\n      this.element.text('0');\n    }\n  }\n}\n\nexport {\n  ZResultsCounter\n}\n","import { Zero, Components, Logger, Utils } from 'Zero';\nimport GoogleSearch from 'Vendor/@openmind/storelocator/dist/googlesearch.umd.js';\n\nconst Log = new Logger('MM3_ZSearch');\n\nexport default class ZSearch extends Components {\n  get Messages() {\n    return {\n      'StoreLocator:Init': this.onStoreLocatorInit,\n      'Cart:Change:DeliveryMethod': this.onCartDeliveryMethodChanged,\n    };\n  }\n\n  get Selectors() {\n    return {\n      GeolocationButton: 'button.geo-location',\n      SearchButton: 'button.search',\n      SearchInput: 'input[name=search]',\n      cartClickAndCollectOpt: '.js-click_and_collect-opt',\n    };\n  }\n\n  get InitialSearch() {\n    return Zero.$state.StoreLocator.InitialSearch;\n  }\n\n  constructor(element) {\n    super(element);\n\n    this.GeoLocationBtn = $('#mm_my-geo');\n    this.SearchBtn = $('.mm_sl-search-btn');\n    this.InputSearch = $('#mm_sl-search-input');\n    this.cartClickAndCollectOpt = $('.js-click_and_collect-opt');\n    this.BlankSearchButton = $('.mm_sl-search-blank-btn');\n    this.inCart = document.body.classList.contains('t-cart');\n\n    this.InputSearch.on('click.iSearch', e => {\n      e.currentTarget.value = '';\n\n      if (!this.inCart) {\n        this.SearchBtn[0].classList.remove('d-none');\n        this.SearchBtn[0].classList.add('d-flex');\n\n        this.SearchBtn[0].disabled = true;\n        this.BlankSearchButton[0].classList.remove('d-flex');\n        this.BlankSearchButton[0].classList.add('d-none');\n      }\n    });\n\n    this.InputSearch.on('input.iSearch', e => {\n      if (!this.inCart) {\n        this.SearchBtn[0].disabled = false;\n        const inputSearchValue = e.currentTarget.value;\n\n        if (inputSearchValue.length) {\n          this.SearchBtn[0].disabled = false;\n        } else {\n          this.SearchBtn[0].disabled = true;\n        }\n      }\n    });\n\n    this.BlankSearchButton.on('click.iSearch', e => {\n      if(!this.inCart) {\n        this.InputSearch[0].value = '';\n        e.currentTarget.classList.remove('d-flex');\n        e.currentTarget.classList.add('d-none');\n        this.SearchBtn[0].classList.add('d-flex');\n        this.SearchBtn[0].disabled = true;\n      }\n    });\n\n    this.SearchBtn.on('click.searchBtn', e => {\n      e.preventDefault();\n      let value = this.InputSearch.val();\n      let p = null;\n\n      if(!this.inCart) {\n        this.BlankSearchButton[0].classList.add('d-flex');\n        this.SearchBtn[0].classList.remove('d-flex');\n        this.SearchBtn[0].classList.add('d-none');\n      }\n\n      if (value.length > 0) {\n        p = this.StoreLocator.navigate(value);\n      } else {\n        p = this.StoreLocator.navigate(this.InitialSearch);\n      }\n\n      p.then(obj => {\n        this.onPlaceChanged(obj.results ? obj.results[0] : { name: value });\n      });\n    });\n\n    this.GeoLocationBtn.on('click.search', e => {\n      e.preventDefault();\n      this.getUserLocation(true);\n    });\n\n    this.checkInputSearchValue();\n  }\n\n  checkInputSearchValue() {\n    const $el = this.InputSearch[0];\n    const inputSearchLenght = $el.value;\n\n    if(!this.inCart) {\n      if (inputSearchLenght) {\n        $el.classList.add('on-search');\n        this.BlankSearchButton[0].classList.remove('d-none');\n        this.SearchBtn[0].classList.add('d-none');\n      } else {\n        $el.classList.remove('on-search');\n        this.BlankSearchButton[0].classList.add('d-none');\n        this.SearchBtn[0].classList.remove('d-none');\n      }\n    }\n  }\n\n  autoGeolocation() {\n    const inCart = document.body.classList.contains('t-cart');\n\n    if (navigator.geolocation && !inCart) {\n      this.getUserLocation();\n    } else {\n      this.cartClickAndCollectOpt.on('click.clickcollect', e => {\n        this.getUserLocation();\n      });\n\n      Log.info(\n        'geolocation should be disable or browser cannot be able to retrive position'\n      );\n    }\n  }\n\n  onCartDeliveryMethodChanged(msg) {\n    if (msg.method.startsWith('Click-and-Collect')) {\n      this.getUserLocation(true);\n    }\n  }\n\n  getUserLocation(clicked) {\n    // MM30-894 force search by boundaries on get user location clicked = true\n    clicked = true;\n\n    this.StoreLocator.currentLocation({ timeout: 30000 }).then(\n      location => {\n        Log.i('Browser geolocation:', location);\n\n        let self = this;\n\n        let geocoder = new google.maps.Geocoder();\n\n        let coordinates = {\n          lat: location.lat,\n          lng: location.lng,\n        };\n\n        let latLng = coordinates.lat + ',' + coordinates.lng;\n\n        geocoder.geocode({ location: coordinates }, function(results) {\n          let formattedAddress = '';\n\n          for (let result of results) {\n            if (result.types[0] === 'postal_code') {\n              self.InputSearch.val(result.formatted_address);\n              return;\n            }\n          }\n        });\n\n        this.StoreLocator.navigate(null, location).then(obj => {\n          this.onPlaceChanged(obj.results[0], clicked);\n        });\n      },\n      function() {\n        Log.e('No current location enabled');\n      }\n    );\n  }\n\n  onStoreLocatorInit(msg) {\n    this.StoreLocator = msg.StoreLocator;\n\n    Log.info('Got storelocator for ', this.element);\n\n    var options = {\n      types: ['(regions)'],\n    };\n\n    let promise = new GoogleSearch(\n      this.StoreLocator,\n      this.InputSearch,\n      options\n    );\n\n    promise.then(\n      gsearch => {\n        this.StoreLocator.addSearchEngine(\n          'GoogleSearch',\n          (this.GSearch = gsearch),\n          options\n        );\n        this.bindStoreLocator();\n        this.autoGeolocation();\n\n        this.StoreLocator.navigate(this.InitialSearch).then(obj => {\n          this.onPlaceChanged(obj.results[0]);\n        });\n      },\n      function() {\n        Log.error('Cannot bind GSearch engine');\n        throw 'Cannot bind GSearch engine';\n      }\n    );\n  }\n\n  bindStoreLocator() {\n    // pick up in store autocomplete query restriction\n    const inCart = document.body.classList.contains('t-cart');\n\n    if (inCart) {\n      const country = document.body.dataset.website;\n      this.GSearch.autocomplete.setComponentRestrictions({\n        'country': [country]\n      });\n    }\n\n    this.GSearch.autocomplete.addListener('place_changed', () => {\n      const result = this.GSearch.autocomplete.getPlace();\n      this.onPlaceChanged(result);\n    });\n  }\n\n  onPlaceChanged(result, clicked) {\n    let searchedCountry = '';\n    const address_text = result.formatted_address || result.name;\n    let geolocation = null;\n    let isCity = null;\n\n    //check if location is administrative_area_level_3\n    let resType = result.address_components;\n\n    if(resType) {\n      for (let item of resType) {\n        if (\n          item.types[0] === 'administrative_area_level_3' ||\n          item.types[0] === 'administrative_area_level_2' ||\n          item.types[0] === 'administrative_area_level_1'\n        ) {\n          isCity = true;\n        }\n      }\n    }\n\n\n    if (result.place_id) {\n      geolocation = {\n        lat: result.geometry.location.lat(),\n        lng: result.geometry.location.lng(),\n        bounds: JSON.parse(JSON.stringify(result.geometry.viewport)),\n        _type:\n          [\n            // google.maps.GeocoderLocationType.APPROXIMATE,\n            google.maps.GeocoderLocationType.RANGE_INTERPOLATED,\n            google.maps.GeocoderLocationType.ROOFTOP,\n          ].indexOf(result.types[0]) > -1\n            ? this.StoreLocator.AddressType.PointOnMap\n            : this.StoreLocator.AddressType.Generic,\n      };\n\n      Zero.$state.StoreLocator.Location.Bounds = geolocation.bounds;\n\n      if (clicked) {\n        Zero.$state.StoreLocator.Location.Center = {\n          lat: geolocation.lat,\n          lng: geolocation.lng,\n        };\n\n        geolocation._type = '_fixed_';\n      } else {\n        Zero.$state.StoreLocator.Location.Center = null;\n      }\n\n      const isCountry = result.types.indexOf('country') > -1;\n\n      if (isCity) {\n        geolocation._type = '_fixed_';\n      }\n\n      if (isCountry) {\n        searchedCountry = result.address_components['0'].short_name;\n      }\n    } else {\n      Log.w('No address found for', address_text);\n      Zero.$state.StoreLocator.Location.Address = address_text;\n    }\n\n    this.CAST('StoreLocator:Search:Place', {\n      place: geolocation,\n      address: address_text,\n      searchedCountry: searchedCountry,\n    });\n  }\n}\n\nexport { ZSearch };\n","import {Zero, Components, Logger, Utils} from 'Zero';\nimport StoreLocator from 'Vendor/@openmind/storelocator/dist/storelocator.umd.js';\nimport $ from 'jquery';\n\nconst Log = new Logger(\"MM3_ZStoreLocator\");\n\nexport default class ZStoreLocator extends Components {\n\n\n  get Messages() {\n    return {\n      \"StoreLocator:Detail:Clicked\": this.onShowDetailStore\n    };\n  }\n\n\n  get StoreLocatorState() {\n    return {\n      InitialSearch : this.data.InitialCountry,\n      InitialCountry: this.data.currentCountry,\n      Location: {\n        Address: \"\",\n        Bounds: null,\n        Center: null\n      },\n      Pins: null,\n      Stores: null,\n\n      Map: {\n        Bounds: null,\n        Center: null\n      },\n\n      Filters: null\n    }\n  }\n\n\n  constructor(element) {\n    super(element);\n    this.StoreLocator = new StoreLocator( this.data.sl );\n    let storeLocatorState = this.StoreLocatorState;\n    Zero.addState( {StoreLocator: storeLocatorState} );\n    this.CAST( \"StoreLocator:Init\", {StoreLocator: this.StoreLocator} );\n    this.onChangeLocation();\n    this.onChangeBoundingBox();\n    this.onChangeFilters();\n    this.setResultsHeight();\n    this.UseLocation = null;\n    this.CurrentCountry = this.data.currentCountry;\n\n    this.GRAB(\"StoreLocator:Search:Place\", (msg) => {\n      let geoloc = msg.place;\n\n      if ( geoloc && geoloc._type === \"_fixed_\" ) {\n        this.UseLocation = {\n          lat: geoloc.lat,\n          lng: geoloc.lng\n        };\n      }\n      this.CurrentCountry = msg.searchedCountry;\n    });\n\n    this.GRAB(\"StoreLocator:Map:Moved\", (msg) => {\n      this.CurrentCountry = null;\n    })\n  }\n\n\n  setResultsHeight() {\n    return\n    let xs = $(window).width() < 768;\n    let filterPanel = (xs == true) ? 0 : $('.mm_sl-filters-panel').outerHeight(true);\n    let search = $('.mm_sl-search').outerHeight(true);\n    let uRow = $('.mm_sl-utility-row').outerHeight(true);\n    let resultOffset = search + filterPanel + uRow;\n    $('.mm_sl-stores-list').css({'top': resultOffset });\n  }\n\n\n  get react() {\n    return {\n\n      onChangeLocation: function() {\n        Zero.$state.StoreLocator.Location.Address;\n        clearTimeout(this.TimerSearch);\n        this.TimerSearch = setTimeout(this.updateGeoJson.bind(this), 500);\n      },\n\n      onChangeBoundingBox: function() {\n        Zero.$state.StoreLocator.Map.Bounds;\n        clearTimeout(this.TimerSearch);\n        this.TimerSearch = setTimeout(this.updateGeoJson.bind(this), 500);\n      },\n\n      onChangeFilters: function() {\n        Zero.$state.StoreLocator.Filters;\n        clearTimeout(this.TimerSearch);\n        this.TimerSearch = setTimeout(this.updateGeoJson.bind(this), 0);\n      }\n    };\n  }\n\n\n  updateGeoJson() {\n    let bounds = Zero.$state.StoreLocator.Map.Bounds;\n    let storeName = Zero.$state.StoreLocator.Location.Address;\n    let center = Zero.$state.StoreLocator.Map.Center;\n    let filters = Zero.$state.StoreLocator.Filters;\n    let locationCenter = Zero.$state.StoreLocator.Location.Center;\n\n\n    if ( !bounds &&  !center ) {\n      // map is not initialized\n      return;\n    }\n\n    // pre-filter\n    let prefilter = $(\".js-prefilter\").attr(\"data-prefilter\");\n    if (prefilter) {\n      if (filters == null) {\n        filters = {}\n      }\n      filters[\"features\"] = prefilter;\n      $(\".js-prefilter\").data(\"prefilter\", \"\");\n    }\n\n\n    let data = null;\n\n    if(locationCenter) {\n      data = Object.assign({}, {name: storeName, filters: filters } );\n    } else {\n      data = Object.assign({}, bounds, center, {name: storeName, filters: filters } );\n    }\n\n\n    this.refreshGeoJsonViaAjax(data).then( (geojson) => {\n\n      if( locationCenter ) {\n\n        Zero.$state.StoreLocator.Location.Center = null;\n        const g_bounds = this.StoreLocator.Map.Map.getBounds();\n\n        for(let item of geojson.features) {\n          const point = item.geometry.coordinates;\n          g_bounds.extend(new google.maps.LatLng({lat: point[1], lng:point[0]}) );\n        }\n\n        Zero.$state.StoreLocator.Location.Bounds = JSON.parse(JSON.stringify(g_bounds) );\n        return;\n      }\n\n      geojson = this.filterResults(geojson, {bounds, center, name: storeName, filters});\n      this.sortResults(geojson, {bounds, center, name: storeName, filters});\n      Zero.$state.StoreLocator.Pins = geojson;\n      Zero.$state.StoreLocator.Stores = geojson;\n\n      this.CAST(\"StoreLocator:GeoJson:Loaded\", {geojson: geojson});\n\n    }, () => {\n\n    });\n  }\n\n\n  calculateNearestStore() {\n    return true;\n  }\n\n\n  filterResults(stores, data) {\n    if ( ! stores ) {\n      stores = {type: 'FeatureCollection', features: []};\n    }\n    let pins = [];\n    let bounds = data.bounds;\n    if ( bounds ) {\n      let g_bounds = new google.maps.LatLngBounds({/*sw*/ lat: bounds.south, lng: bounds.west}, {/*ne*/ lat: bounds.north, lng: bounds.east});\n      let Feats = stores.features || [];\n      for( let Feat of Feats ) {\n        let g_point = new google.maps.LatLng({lat: Feat.geometry.coordinates[1], lng: Feat.geometry.coordinates[0]});\n        if ( g_bounds.contains( g_point ) ) {\n          pins.push( Feat );\n        }\n      }\n    }\n    stores.features = pins;\n    return stores;\n  }\n\n\n  sortResults(stores, data) {\n    if ( stores && stores.features ) {\n      for( let i = 0, store; store = stores.features[i]; i++) {\n        store.properties._labelindex = `${i + 1}`;\n        store.properties._labelcolor = \"#FFF\";\n      }\n    }\n\n    return stores\n  }\n\n\n  refreshGeoJsonViaAjax(data) {\n    return new Promise( (resolve, reject) => {\n      data.listJson = true;\n      data.withoutRadius = false; // new required param\n\n      data = Object.assign({}, data, data.filters || {});\n      delete data.filters;\n\n      if ( ! this.UseLocation ) {\n        delete data.lat;\n        delete data.lng;\n      } else {\n        data.lat = this.UseLocation.lat;\n        data.lng = this.UseLocation.lng;\n      }\n\n\n      if ( this.data.forceCountry ){\n\n        data.country = this.data.currentCountry.toUpperCase();\n\n      } else if ( this.CurrentCountry ) {\n        data.country = this.CurrentCountry.toUpperCase();\n      }\n\n      this._pin_req && this._pin_req.abort();\n\n      this._pin_req = Utils.Ajax.get('/store-locator', data, { traditional: true }).then( (geojson) => {\n        this._pin_req = null;\n        resolve(geojson)\n\n      }, () => {\n        this._pin_req = null;\n        reject()\n      })\n    });\n  }\n\n\n  onShowDetailStore(msg) {\n    const store_id = msg.store_id;\n    let askDetailPage = $.get( `store/${store_id}?ajax=true`, (html) => {\n\n    })\n      .done( (html) => {\n        let content = $(html);\n        this.element.find('#store-details-container').empty().append( content );\n      })\n      .fail( (html) => {\n        Log.info( `AskDetailPage: cannot retrive remote data from store/${store_id}` );\n      })\n  }\n\n}\n\nexport {\n  ZStoreLocator\n}\n","import { Logger, Zero, Components, Utils } from 'Zero';\nimport { detect } from 'detect-browser';\nconst Log = new Logger('Panel');\n\nexport default class ZPanel extends Components {\n  constructor(element) {\n    super(element);\n    this.Opened = false;\n    this.trigger = this.element.find('.js-sl_panel-trigger');\n    this.target = this.element.find('.js-sl_panel-target');\n    let timing = this.element.data('animate-time');\n    if (timing) {\n      this.animateTime = this.element.data('animate-time');\n    } else {\n      this.animateTime = 370;\n    }\n    this.trigger.on('click.panel', () => {\n      this.togglePanel();\n    });\n\n    $(document).on('click', (e) => {\n      this.closeSerivesPanel(e);\n    });\n  }\n\n  get Messages() {\n    return {\n      'Storelocator:Filters:Applied': this.closeSerivesPanel,\n    };\n  }\n\n  closeSerivesPanel(e) {\n    const panel = $('.is-open').find('.mr_sl-panel-target');\n\n    if ($(e.target).closest(\".is-open\").length === 0) {\n      $('.services-panel').removeClass('is-open');\n      this.Opened = false;\n      panel.stop().animate({ height: '0', 'min-height': '0' }, 350);\n      $('body').removeClass('panel-is-opened');\n    }\n  }\n\n  autoAnimate(elem, time) {\n    let curHeight = elem.height();\n    let autoHeight = elem.css('height', 'auto').height();\n    elem.height(curHeight);\n    elem.stop().animate({ height: autoHeight }, time, function() {\n      elem.css({ height: 'auto', 'min-height': 'auto' });\n    });\n  }\n\n  togglePanel() {\n    if (this.Opened) {\n      if (this.element[0].dataset.attachbodyclass) {\n        $('body').removeClass('panel-is-opened');\n      }\n      this.closePanel();\n    } else {\n      if (this.element[0].dataset.attachbodyclass) {\n        $('body').addClass('panel-is-opened');\n      }\n      this.openPanel();\n    }\n  }\n  openPanel() {\n    let animateTime = this.animateTime;\n    this.element.addClass('is-open');\n    this.autoAnimate(this.target, animateTime);\n    this.Opened = true;\n  }\n  closePanel() {\n    $('body').removeClass('panel-is-opened');\n    let animateTime = this.animateTime;\n    this.element.removeClass('is-open');\n    this.Opened = false;\n    this.target.stop().animate({ height: '0', 'min-height': '0' }, animateTime);\n  }\n}\n\nexport { ZPanel };\n","const loadedDependency = {};\n\nconst existingDependency = (name) => {\n  return (name in loadedDependency) ? loadedDependency[name] : false;\n};\n\nconst saveDependency = (name, lib) => {\n  return new Promise((resolve, reject) => {\n    try {\n      if (!existingDependency(name)) {\n        loadedDependency[name] = lib;\n        resolve(false);\n      } else {\n        resolve(true);\n      }\n    } catch (e) {\n      reject(e);\n    }\n  });\n};\n\n\n\n/**\n * This utility class is injected in all components that extends Component\n * and is used to lazy load third-part libraries\n */\nexport default class DependencyInjector {\n  static get CUSTOM_STYLES() {\n    return '../../../stylesheets';\n  }\n\n  static defaultCatchPromise(error) {\n    console.error(\"Failed to inject dependency\", error.stack);\n  }\n\n  /**\n   * Log utility\n   * @param logStr\n   */\n  log(logStr = \"\") {\n    if (logStr != \"\") {\n      let myName = this.constructor.name;\n      console.debug(`[${myName}] ${logStr}`);\n    }\n  }\n\n\n  /**\n   * Load a single bootstrap component from library\n   * The SCSS file shoul be created due to the impossibility to import from bootstrap package\n   * @param thenPromise\n   * @param catchPromise\n   */\n  loadBootstrapJsComponentAndExecute(componentName, thenPromise, catchPromise) {\n    this.log(`Loading Bootstrap ${componentName}`);\n\n    import(/* webpackChunkName: `boostrap-js` */ `bootstrap/js/dist/${componentName}.js`).then(thenPromise).catch(catchPromise);\n  }\n\n\n  loadAos(thenPromise, catchPromise) {\n    this.log('Loading aos');\n\n    import(/* webpackChunkName: `aos` */  'aos/dist/aos.css').then(\n      () => {\n        import(/* webpackChunkName: `aos` */ 'aos').then(thenPromise).catch(catchPromise);\n      }).catch(catchPromise);\n  }\n\n\n  loadModalAndExecute(thenPromise, catchPromise) {\n    this.log('Loading Modal');\n\n    import(/* webpackChunkName: `vex` */ 'vex-js/dist/js/vex.js').then(thenPromise).catch(catchPromise);\n  }\n\n  loadCarouselAndExecute(thenPromise, catchPromise) {\n    this.log('Loading Slick Carousel');\n    if (existingDependency('carousel')) return thenPromise(existingDependency('carousel'));\n\n    import(/* webpackChunkName: `slick` */  'slick-carousel/slick/slick.scss').then( () => {\n        import(/* webpackChunkName: `slick` */ \"slick-carousel/slick/slick-theme.scss\").then(() => {\n          import(/* webpackChunkName: `slick` */ 'slick-carousel/slick/slick.js').then((res) => {\n            saveDependency('carousel', res);\n            thenPromise(res);\n          }).catch(catchPromise);\n        }).catch(err => {\n          console.error('Failed slick css import')\n        }); // js library\n      }).catch(err => {\n      console.error('Failed slick css theme')\n    });\n\n  }\n\n  loadStickyAndExecute(thenPromise, catchPromise) {\n    this.log('Loading stickybits');\n    import(/* webpackChunkName: `stickybits` */ 'stickybits').then(thenPromise).catch(catchPromise);\n  }\n\n  loadSelect2(thenPromise, catchPromise) {\n    this.log('Loading Select2');\n    if (existingDependency('select2')) return thenPromise(existingDependency('carousel'));\n\n    import(/* webpackChunkName: `flatpickr` */  'select2/src/scss/core.scss').then(\n      () => {\n        import(/* webpackChunkName: `selectize` */ 'select2/dist/js/select2.js').then((res) => {\n          saveDependency('select2', res);\n          thenPromise(res);\n        }).catch(catchPromise);\n      }).catch(catchPromise);\n  }\n\n  loadFlatpickrLocale(locale, thenPromise, catchPromise) {\n    import(/* webpackChunkName: `flatpickr-locale` */ `flatpickr/dist/l10n/${locale}.js`).then(thenPromise).catch(catchPromise)\n  }\n\n  loadFlatpickr(thenPromise, catchPromise) {\n    this.log('Loading Flatpickr');\n\n      import(/* webpackChunkName: `flatpickr` */  'flatpickr/src/style/flatpickr.styl').then(\n          () => {\n            import(/* webpackChunkName: `flatpickr` */  'flatpickr/src/style/themes/airbnb.styl');\n            import(/* webpackChunkName: `flatpickr` */ 'flatpickr/dist/flatpickr.js').then(thenPromise).catch(catchPromise); // js library\n        }).catch(catchPromise);\n  }\n\n\n  loadMasonry(thenPromise, catchPromise) {\n    this.log('Loading Masonry');\n\n    import(/* webpackChunkName: `masonry-layout` */ 'masonry-layout').then(thenPromise).catch(catchPromise);\n  }\n\n  /**\n   * This method load the query-string library and execute the given promises\n   * when loaded\n   * @param thenPromise the code that must be executed when jscroll is ready\n   * @param catchPromise the code that must be executed when jscrol fails to load\n   */\n  loadQueryStringAndExecute(thenPromise, catchPromise) {\n    this.log(\"Loading query-string\");\n    import(/* webpackChunkName: `query-string` */ \"query-string\").then(thenPromise).catch(catchPromise);\n  }\n\n  /**\n   * This method load the jscroll library and execute the given promises\n   * when loaded\n   * @param thenPromise the code that must be executed when jscroll is ready\n   * @param catchPromise the code that must be executed when jscroll fails to load\n   */\n  // loadJscrollAndExecute(thenPromise, catchPromise) {\n  //   this.log(\"Loading jscroll\");\n  //   import(/* webpackChunkName: `jscroll` */ \"jscroll\").then(thenPromise).catch(catchPromise);\n  // }\n\n  /**\n   * This method load the blueimp-file-upload library and execute the given promises\n   * when loaded\n   * @param thenPromise the code that must be executed when blueimp-file-upload is ready\n   * @param catchPromise the code that must be executed when blueimp-file-upload fails to load\n   */\n  loadBlueimpFileUploadAndExecute(thenPromise, catchPromise) {\n    this.log(\"Loading BlueimpFileUpload\");\n    import(/* webpackChunkName: `blueimp-file-upload` */ \"blueimp-file-upload\").then(\n        () => {\n          import(/* webpackChunkName: `blueimp-file-upload` */ 'blueimp-file-upload/css/jquery.fileupload.css').then(thenPromise).catch(catchPromise); // js library\n      }).catch(catchPromise);\n  }\n\n  /**\n   * Load all jquery ui js (1.5kb gzipped)\n   * @param widgetName the name of jquery wigget\n   * @param thenPromise the code that must be executed when the widget is ready\n   * @param catchPromise the code that must be executed when the widget fails to load\n   */\n  loadJqueryUIWidgetAndExecute(widgetName, thenPromise, catchPromise) {\n    this.log(`Loading jQuery UI dist for ${widgetName}`);\n\n    import(\n      /* webpackChunkName: `jquery-ui` */\n      'jquery-ui-dist/jquery-ui').then(thenPromise).catch(catchPromise);\n  }\n\n  loadExternalScript(url) {\n    return new Promise((resolve, reject) => {\n      let script = document.createElement('script');\n      script.type = 'text/javascript';\n      script.src = url;\n      script.addEventListener('load', () => resolve(script), false);\n      script.addEventListener('error', () => reject(script), false);\n      document.body.appendChild(script);\n    });\n  }\n}\n","import DependencyInjector from '../utils/DependencyInjector';\nimport { CustomEvents } from '../utils/CustomEvents';\nimport { match } from '../utils/ResolutionHandler';\nimport { getFirstFocusable } from \"../utils/FocusableElementUtils\";\nimport {on, emit, off, one} from '../utils/EventsBus';\n\n\n\n/**\n * Generic web component that expose a render method\n */\nexport default class Component {\n\n  constructor() {\n    this.moduleLoader = new DependencyInjector(); // Use this class to lazy load modules!!\n    this.$customEvents = CustomEvents;\n    this.$matchMedia = match;\n    this.$on = on;\n    this.$emit = emit;\n    this.$off = off;\n    this.$one = one;\n    this.$getFirstFocusable = getFirstFocusable;\n  }\n\n  /**\n   * Log utility\n   * @param logStr\n   */\n  log(logStr = \"\") {\n    if (logStr != \"\") {\n      let myName = this.constructor.name;\n      console.log(`%c[${myName}] %c${logStr}`, 'color: #f56c42', 'color: inherit');\n    }\n  }\n\n  /**\n   * Log utility\n   * @param logStr\n   */\n  warn(logStr = \"\") {\n    if (logStr != \"\") {\n      let myName = this.constructor.name;\n      console.warn(`[${myName}] ${logStr}`);\n    }\n  }\n\n  /*\n    Main method that execute the render logic of the component\n   */\n  render() {\n    let myName = this.constructor.name;\n    console.log(`[${myName}] Rendering..`);\n  }\n}\n"],"sourceRoot":""}