{"version":3,"sources":["webpack:///./Scripts/Muurikka/ResellerGoogleMapStyleLight.js","webpack:///./Scripts/Muurikka/ResellerGoogleMapForProduct.js","webpack:///./Scripts/Muurikka/ResellerGoogleMapForProduct.container.js"],"names":["resellerStyle","featureType","elementType","stylers","color","visibility","saturation","lightness","API_KEY","ResellerGoogleMapForProduct","_Component","props","_context","_context2","_context3","_context4","_context5","_context6","_context7","_context8","_context9","_context10","_context11","_context12","_this","_classCallCheck","_callSuper","countryLoaded","values","productResellers","state","resellersData","showingInfoWindow","defaultCenter","lat","lng","currentMarkerCenter","selectedMarker","selectedPlace","search","showMap","zoom","zoomToMarkers","filterByLocation","isZoomIn","isBusinessReseller","selectedCountry","locationShared","productId","document","getElementById","value","localStorage","setItem","handleClick","_bindInstanceProperty","call","handleCloseClick","onGeoLocClick","onShowList","onShowMap","updateSearch","getMyLocation","closeMap","zoomMap","onGetNearbyPlacesClick","FilterByType","handleCountryChange","_inherits","_createClass","key","marker","event","this","setState","_parseFloat","getElementsByClassName","classList","toggle","country","_context13","filteredLocations","_this2","latitude","productresellers","_filterInstanceProperty","reseller","p1","google","maps","LatLng","p2","longitude","geometry","spherical","computeDistanceBetween","countries","loadGeoCountryData","getSelectedCountry","console","warn","geoCountryCode","getCookie","allCountryCodes","_Object$keys","_includesInstanceProperty","_this3","navigator","geolocation","getCurrentPosition","pos","_context14","_context15","coords","fetch","_concatInstanceProperty","concat","then","response","json","jsonData","address","results","address_components","countryCode","_findInstanceProperty","x","_context16","types","short_name","toLowerCase","setCookie","_JSON$stringify","error","log","message","enableHighAccuracy","timeout","maximumAge","target","substr","filteredResellerByType","_context17","_context19","resellerData","_context18","_indexOfInstanceProperty","type","_context20","onlineReseller","mapElementClass","React","createElement","MapWithAMarker","markers","onClick","onCloseClick","zoomLevel","googleMapURL","isGlobalChannel","loadingElement","id","style","height","padding","containerElement","className","mapElement","display","nextProps","prevState","_objectSpread","Component","compose","withScriptjs","withGoogleMap","_context21","_context22","_context23","_context24","_context25","_context26","_context27","_context28","_context29","resellers","length","_context30","customerNumber","phone","zipCode","coordinates","city","name","translate","GoogleMapDropdown","_extends","onCountryChange","placeholder","autoComplete","onChange","title","_mapInstanceProperty","_context31","GoogleMap","ref","map","fitBounds","center","defaultOptions","styles","Marker","visible","position","InfoWindow","_context32","_context33","icon","zipcode","href","ResellerGoogleMapForProductContainer","lifecycle","componentDidMount","_this$props","loadForProduct","variantId","connect","data","resellerProduct","resellerCountries","dispatch"],"mappings":"gcA4GeA,EA5GO,CACpB,CACEC,YAAa,MACbC,YAAa,MACbC,QAAS,CACP,CACEC,MAAO,aAIb,CACEH,YAAa,MACbC,YAAa,WACbC,QAAS,CACP,CACEC,MAAO,aAIb,CACEH,YAAa,iBACbC,YAAa,mBACbC,QAAS,CACP,CACEC,MAAO,aAIb,CACEH,YAAa,8BACbC,YAAa,gBACbC,QAAS,CACP,CACEC,MAAO,aAIb,CACEH,YAAa,MACbC,YAAa,MACbC,QAAS,CACP,CACEE,WAAY,SAIlB,CACEJ,YAAa,OACbC,YAAa,MACbC,QAAS,CACP,CACEG,YAAa,KAEf,CACEC,UAAW,MAIjB,CACEN,YAAa,eACbC,YAAa,MACbC,QAAS,CACP,CACEE,WAAY,gBAIlB,CACEJ,YAAa,eACbC,YAAa,SACbC,QAAS,CACP,CACEE,WAAY,SAIlB,CACEJ,YAAa,gBACbC,YAAa,cACbC,QAAS,CACP,CACEE,WAAY,SAIlB,CACEJ,YAAa,UACbC,YAAa,MACbC,QAAS,CACP,CACEE,WAAY,SAIlB,CACEJ,YAAa,QACbC,YAAa,MACbC,QAAS,CACP,CACEC,MAAO,WAET,CACEC,WAAY,S,6PC7FpB,IAAMG,EAAU,0CAEKC,EAA2B,SAAAC,GAC5C,SAAAD,EAAYE,GAAO,IAAAC,EAAAC,EAAAC,EAAAC,EAAAC,EAAAC,EAAAC,EAAAC,EAAAC,EAAAC,EAAAC,EAAAC,EAAAC,EAAAC,IAAA,KAAAhB,IACfe,EAAAE,EAAA,KAA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,cAAA,KAAGmE,KAAM,OAASpJ,EAAOsH,OAAQtH,EAAOsH,OAExCtC,IAAAC,cAAA,KAAGG,QAAS3F,EAASsG,UAAU,iC,SCpgBvFsD,GAAuC,SAAUjN,GACjD,OAAO4I,IAAAC,cAAC/I,EAAgCE,IAG5CiN,GAAuCC,YAAU,CAC7CC,kBAAiB,WAAG,IAAAC,EACoBtJ,KAAK9D,OACzCqN,EADqBD,EAAdC,gBAAyBD,EAATE,aAFQJ,CAKpCD,IAgBYM,uBAdS,SAAApM,GACpB,MAAO,CACHqM,KAAMrM,EAAMsM,gBACZvM,iBAAkBC,EAAMsM,gBAAgBvM,iBACxCwM,kBAAmBvM,EAAMsM,gBAAgBC,sBAItB,SAAAC,GACvB,MAAO,CACHN,eAAgB,SAACC,GAAS,OAAKK,EAASN,YAAeC,QAIhDC,CAA6CN","file":"20.7c7f09c48c48ac6bbeef.js","sourcesContent":["const resellerStyle = [\r\n  {\r\n    featureType: 'all',\r\n    elementType: 'all',\r\n    stylers: [\r\n      {\r\n        color: '#f2f2f1'\r\n      }\r\n    ]\r\n  },\r\n  {\r\n    featureType: 'all',\r\n    elementType: 'geometry',\r\n    stylers: [\r\n      {\r\n        color: '#f2f2f1'\r\n      }\r\n    ]\r\n  },\r\n  {\r\n    featureType: 'administrative',\r\n    elementType: 'labels.text.fill',\r\n    stylers: [\r\n      {\r\n        color: '#8a8a8a'\r\n      }\r\n    ]\r\n  },\r\n  {\r\n    featureType: 'landscape.natural.landcover',\r\n    elementType: 'geometry.fill',\r\n    stylers: [\r\n      {\r\n        color: '#f2f2f1'\r\n      }\r\n    ]\r\n  },\r\n  {\r\n    featureType: 'poi',\r\n    elementType: 'all',\r\n    stylers: [\r\n      {\r\n        visibility: 'off'\r\n      }\r\n    ]\r\n  },\r\n  {\r\n    featureType: 'road',\r\n    elementType: 'all',\r\n    stylers: [\r\n      {\r\n        saturation: -100\r\n      },\r\n      {\r\n        lightness: 45\r\n      }\r\n    ]\r\n  },\r\n  {\r\n    featureType: 'road.highway',\r\n    elementType: 'all',\r\n    stylers: [\r\n      {\r\n        visibility: 'simplified'\r\n      }\r\n    ]\r\n  },\r\n  {\r\n    featureType: 'road.highway',\r\n    elementType: 'labels',\r\n    stylers: [\r\n      {\r\n        visibility: 'off'\r\n      }\r\n    ]\r\n  },\r\n  {\r\n    featureType: 'road.arterial',\r\n    elementType: 'labels.icon',\r\n    stylers: [\r\n      {\r\n        visibility: 'off'\r\n      }\r\n    ]\r\n  },\r\n  {\r\n    featureType: 'transit',\r\n    elementType: 'all',\r\n    stylers: [\r\n      {\r\n        visibility: 'off'\r\n      }\r\n    ]\r\n  },\r\n  {\r\n    featureType: 'water',\r\n    elementType: 'all',\r\n    stylers: [\r\n      {\r\n        color: '#cdd1d2'\r\n      },\r\n      {\r\n        visibility: 'on'\r\n      }\r\n    ]\r\n  }\r\n]\r\n\r\nexport default resellerStyle\r\n","import React, {Component} from 'react'\r\nimport {compose} from 'recompose'\r\nimport {translate} from '../Services/translation'\r\nimport resellerStyle from './ResellerGoogleMapStyleLight'\r\nimport {GoogleMap, InfoWindow, Marker, withGoogleMap, withScriptjs} from 'react-google-maps'\r\nimport GoogleMapDropdown from './ResellerGoogleMapDropdown'\r\nimport {getCookie, setCookie} from \"../Shared/Utils\";\r\nimport {fitBounds} from \"./ResellerGoogleMapUtilities\";\r\n\r\nconst API_KEY = 'AIzaSyA-0Y1bOYeSmElvvtMBbyeRSY0XiNdbR9k'\r\n\r\nexport default class ResellerGoogleMapForProduct extends Component {\r\n    constructor(props) {\r\n        super(props)\r\n\r\n        this.countryLoaded = false;\r\n\r\n        let values = this.props.productResellers;\r\n        this.state = {\r\n            resellersData: values,\r\n            showingInfoWindow: false,\r\n            defaultCenter: {lat: 60.128162, lng: 18.643501},\r\n            currentMarkerCenter: {lat: 60.128162, lng: 18.643501},\r\n            selectedMarker: {},\r\n            selectedPlace: {},\r\n            search: '',\r\n            showMap: false,\r\n            zoom: 5,\r\n            zoomToMarkers: null,\r\n            filterByLocation: false,\r\n            isZoomIn: false,\r\n            isBusinessReseller: false,\r\n            selectedCountry: '',\r\n            locationShared: false,\r\n        }\r\n        const productId = document.getElementById('hdnProductId').value;\r\n        localStorage.setItem('ResellerData', productId);\r\n\r\n        this.handleClick = this.handleClick.bind(this)\r\n        this.handleCloseClick = this.handleCloseClick.bind(this)\r\n        this.onGeoLocClick = this.onGeoLocClick.bind(this)\r\n        this.onShowList = this.onShowList.bind(this)\r\n        this.onShowMap = this.onShowMap.bind(this)\r\n        this.updateSearch = this.updateSearch.bind(this)\r\n        this.getMyLocation = this.getMyLocation.bind(this)\r\n        this.closeMap = this.closeMap.bind(this)\r\n        this.zoomMap = this.zoomMap.bind(this)\r\n        this.onGetNearbyPlacesClick = this.onGetNearbyPlacesClick.bind(this)\r\n        this.FilterByType = this.FilterByType.bind(this)\r\n        this.handleCountryChange = this.handleCountryChange.bind(this);\r\n    }\r\n\r\n    static getDerivedStateFromProps(nextProps, prevState) {\r\n        return {...prevState, ...{resellersData: nextProps.productResellers}}\r\n    }\r\n\r\n    handleClick(marker, event) {\r\n        this.setState({\r\n            showingInfoWindow: false,\r\n            selectedMarker: marker,\r\n            showMap: true,\r\n            zoom: 11,\r\n            currentMarkerCenter: {\r\n                lat: parseFloat(marker.lat),\r\n                lng: parseFloat(marker.lng)\r\n            }\r\n        })\r\n    }\r\n\r\n    closeMap(event) {\r\n        this.setState({\r\n            showMap: false,\r\n            zoom: 5\r\n        })\r\n        document.getElementsByClassName('reseller-product')[0].classList.toggle('hide');\r\n    }\r\n\r\n    zoomMap() {\r\n        if (this.state.isZoomIn == false) {\r\n            this.setState({\r\n                zoom: 8,\r\n                isZoomIn: true\r\n            })\r\n        } else {\r\n            this.setState({\r\n                zoom: 5,\r\n                isZoomIn: false\r\n            })\r\n        }\r\n    }\r\n\r\n    onGeoLocClick(marker, event) {\r\n        this.setState({\r\n            showingInfoWindow: true,\r\n            zoom: 8,\r\n            isZoomIn: true\r\n        })\r\n    }\r\n\r\n    handleCountryChange(country) {\r\n        this.setState(\r\n            {selectedCountry: country}\r\n        )\r\n    }\r\n\r\n    onGetNearbyPlacesClick(marker, event) {\r\n        if (this.state.latitude == null) {\r\n            this.getMyLocation();\r\n        }\r\n\r\n        if (!this.state.filterByLocation) {\r\n            let filteredLocations;\r\n            filteredLocations = this.state.resellersData.filter(reseller => {\r\n                let p1 = new google.maps.LatLng(reseller.lat, reseller.lng);\r\n                let p2 = new google.maps.LatLng(this.state.latitude, this.state.longitude);\r\n                let distance = google.maps.geometry.spherical.computeDistanceBetween(p1, p2)\r\n                if (distance < 170000) {\r\n                    return reseller\r\n                }\r\n            })\r\n\r\n            this.setState({\r\n                showingInfoWindow: true,\r\n                filterByLocation: true,\r\n                resellersData: filteredLocations,\r\n                locationShared: true\r\n            })\r\n        } else {\r\n            this.setState({\r\n                locationShared: true,\r\n                filterByLocation: false,\r\n                resellersData: this.props.productresellers\r\n            })\r\n        }\r\n    }\r\n\r\n    onShowList() {\r\n        this.setState({\r\n            showMap: false,\r\n            zoom: 5\r\n        })\r\n    }\r\n\r\n    onShowMap() {\r\n        this.setState({\r\n            showMap: true,\r\n            zoom: 5\r\n        })\r\n    }\r\n\r\n    componentDidMount() {\r\n        if (typeof this.props.countries === 'undefined' || this.countryLoaded) return;\r\n\r\n        this.getMyLocation();\r\n        this.loadGeoCountryData();\r\n    }\r\n\r\n    loadGeoCountryData() {\r\n        let selectedCountry = this.getSelectedCountry();\r\n\r\n        if (!selectedCountry || selectedCountry === '') {\r\n            console.warn(`Your country is not available`);\r\n        }\r\n\r\n        this.setState({\r\n            selectedMarker: {},\r\n            selectedCountry: selectedCountry,\r\n        });\r\n        this.countryLoaded = true;\r\n    }\r\n\r\n    getSelectedCountry() {\r\n        let geoCountryCode = getCookie('country');\r\n        let allCountryCodes = Object.keys(this.props.countries);\r\n\r\n        if (!geoCountryCode || geoCountryCode && !allCountryCodes.includes(geoCountryCode)) {\r\n            geoCountryCode = '';\r\n        }\r\n\r\n        return geoCountryCode;\r\n    }\r\n\r\n    getMyLocation() {\r\n        if (navigator && navigator.geolocation) {\r\n            navigator.geolocation.getCurrentPosition(\r\n                pos => {\r\n                    const coords = pos.coords\r\n                    this.setState({\r\n                        defaultCenter: {\r\n                            lat: coords.latitude,\r\n                            lng: coords.longitude\r\n                        },\r\n                        latitude: coords.latitude,\r\n                        longitude: coords.longitude,\r\n                        locationShared: true\r\n                    })\r\n\r\n                    if (!getCookie('country')) {\r\n                        fetch(`https://maps.googleapis.com/maps/api/geocode/json?latlng=${coords.latitude},${coords.longitude}&sensor=false&key=${API_KEY}`)\r\n                            .then((response) => {\r\n                                return response.json();\r\n                            }).then(jsonData => {\r\n                            const address = jsonData.results[0].address_components;\r\n                            const country = address.find(x => x.types.includes(\"country\"));\r\n                            const countryCode = country.short_name.toLowerCase();\r\n\r\n                            setCookie('country', countryCode, 7);\r\n                            setCookie('co', JSON.stringify({\r\n                                latitude: coords.latitude,\r\n                                longitude: coords.longitude\r\n                            }), 7, true);\r\n\r\n                            this.setState({\r\n                                selectedCountry: this.getSelectedCountry(),\r\n                            });\r\n                        })\r\n                            .catch(error => {\r\n                                console.log(error);\r\n                            })\r\n                    }\r\n                },\r\n                error => (document.getElementById('errorLabel').value = error.message),\r\n                {enableHighAccuracy: true, timeout: 20000, maximumAge: 1000}\r\n            )\r\n        }\r\n    }\r\n\r\n    updateSearch(event) {\r\n        this.setState({\r\n            search: event.target.value.substr(0, 20)\r\n        })\r\n    }\r\n\r\n    FilterByType(marker, event) {\r\n        var filteredResellerByType;\r\n        if (this.state.isBusinessReseller == false) {\r\n            filteredResellerByType = this.props.resellerData.filter(reseller => {\r\n                return (\r\n                    (\r\n                        reseller.type.toLowerCase().indexOf('p')\r\n                    ) !==\r\n                    -1\r\n                )\r\n            })\r\n            this.setState({\r\n                isBusinessReseller: true,\r\n                resellersData: filteredResellerByType,\r\n                zoom: 5\r\n            })\r\n        } else {\r\n            filteredResellerByType = this.props.resellerData.filter(reseller => {\r\n                return (\r\n                    (\r\n                        reseller.onlineReseller.toLowerCase().indexOf('false')\r\n                    ) !==\r\n                    -1\r\n                )\r\n            })\r\n            this.setState({\r\n                isBusinessReseller: false,\r\n                resellersData: this.props.resellerData,\r\n                zoom: 5\r\n            })\r\n        }\r\n    }\r\n\r\n    handleCloseClick(event) {\r\n        this.setState({\r\n            showingInfoWindow: false,\r\n            selectedMarker: {}\r\n        })\r\n    }\r\n\r\n    render() {\r\n        let mapElementClass = '';\r\n        if (this.state.showMap) mapElementClass += 'show';\r\n\r\n        return (\r\n            <MapWithAMarker\r\n                selectedMarker={this.state.selectedMarker}\r\n                showingInfoWindow={this.state.showingInfoWindow}\r\n                defaultCenter={this.state.defaultCenter}\r\n                currentMarkerCenter={this.state.currentMarkerCenter}\r\n                latitude={this.state.latitude}\r\n                longitude={this.state.longitude}\r\n                search={this.state.search}\r\n                markers={this.state.resellersData}\r\n                onClick={this.handleClick}\r\n                showMap={this.state.showMap}\r\n                onGeoLocClick={this.onGeoLocClick}\r\n                onGetNearbyPlacesClick={this.onGetNearbyPlacesClick}\r\n                onShowList={this.onShowList}\r\n                onShowMap={this.onShowMap}\r\n                closeMap={this.closeMap}\r\n                onCloseClick={this.handleCloseClick}\r\n                zoomMap={this.zoomMap}\r\n                zoomLevel={this.state.zoom}\r\n                zoomToMarkers={this.state.zoomToMarkers}\r\n                updateSearch={this.updateSearch}\r\n                FilterByType={this.FilterByType}\r\n                googleMapURL={`https://maps.googleapis.com/maps/api/js?key=${API_KEY}&v=3.exp&libraries=geometry,drawing,places`}\r\n                countries={this.props.countries}\r\n                handleCountryChange={this.handleCountryChange}\r\n                isGlobalChannel={this.props.isGlobalChannel}\r\n                selectedCountry={this.state.selectedCountry}\r\n                locationShared={this.state.locationShared}\r\n\r\n                loadingElement={\r\n                    <div\r\n                        id=\"LoadingElement\"\r\n                        style={{height: `100%`, padding: `61px 55px 55px 55px`}}\r\n                    />\r\n                }\r\n                containerElement={\r\n                    <div\r\n                        id=\"Container\"\r\n                        className=\"google-map__panel\"\r\n                    />\r\n                }\r\n                mapElement={\r\n                    <div\r\n                        id=\"MapElement\"\r\n                        className={mapElementClass}\r\n                        style={{\r\n                            height: `100%`,\r\n                            display: this.state.showMap == true ? 'block' : 'none'\r\n                        }}\r\n                    />\r\n                }\r\n            />\r\n        )\r\n    }\r\n}\r\nconst MapWithAMarker = compose(\r\n    withScriptjs,\r\n    withGoogleMap\r\n)(props => {\r\n    const onGeoLocClick = props.onGeoLocClick.bind(this)\r\n    const onShowList = props.onShowList.bind(this)\r\n    const onShowMap = props.onShowMap.bind(this)\r\n    const updateSearch = props.updateSearch.bind(this)\r\n    const closeMap = props.closeMap.bind(this)\r\n    const zoomMap = props.zoomMap.bind(this)\r\n    const onGetNearbyPlacesClick = props.onGetNearbyPlacesClick.bind(this)\r\n    const FilterByType = props.FilterByType.bind(this)\r\n    const resellers =\r\n        !props.markers || props.markers.length === 0 ? (\r\n            <div>{'No Resellers Available'} </div>\r\n        ) : (\r\n            props.markers.filter(reseller => {\r\n                if (props.selectedCountry !== '' && reseller.countryCode.toLowerCase() !== props.selectedCountry) {\r\n                    return false;\r\n                }\r\n                return (\r\n                    (reseller.customerNumber.search(props.search) &&\r\n                        reseller.phone.search(props.search) &&\r\n                        reseller.zipCode.search(props.search) &&\r\n                        reseller.coordinates.search(props.search) &&\r\n                        reseller.address.toLowerCase().search(props.search.toLowerCase()) &&\r\n                        reseller.city.toLowerCase().search(props.search.toLowerCase()) &&\r\n                        reseller.name.toLowerCase().indexOf(props.search.toLowerCase())) !==\r\n                    -1\r\n                )\r\n            })\r\n        )\r\n    return <div className={`google-map__wrapperProduct` + (!props.showMap ? ' force-top' : '')}>\r\n        <div id=\"ResellersGoogleMap\">\r\n            <div className=\"ResellersGoogleMapHeader\">\r\n                {translate('findresellertitle')}\r\n                <a onClick={closeMap} className=\"close\">\r\n                    &#10006;\r\n                </a>\r\n            </div>\r\n            <input type=\"label\" id=\"errorLabel\" style={{display: 'none'}}/>\r\n\r\n            {props.showMap == false ? (\r\n                <div>\r\n                    <div id=\"GoogleMapList\" className=\"google-map__list\">\r\n                        <div className=\"google-map__input-container\">\r\n                            {props.isGlobalChannel === \"True\" &&\r\n                                <GoogleMapDropdown\r\n                                    {...props}\r\n                                    onCountryChange={props.handleCountryChange}\r\n                                >\r\n                                </GoogleMapDropdown>\r\n                            }\r\n                            <div className=\"google-map__input-wrapper\">\r\n                                <div className=\"google-map__button-container google-map__button-container--search\">\r\n                                    <i className=\"quick-search__icon\"/>\r\n                                    <input\r\n                                        type=\"search\"\r\n                                        className=\"google-map__input\"\r\n                                        placeholder={translate('reseller.search')}\r\n                                        autoComplete=\"off\"\r\n                                        value={props.search}\r\n                                        onChange={updateSearch}\r\n                                    />\r\n                                </div>\r\n\r\n                                <div\r\n                                    className={'google-map__button-container google-map__button-container--location' + (!props.locationShared ? ' disabled' : '')}\r\n                                    title={(props.locationShared ? translate('reseller.nearme') : translate('reseller.nearme.requireslocation'))}>\r\n                                    <input\r\n                                        className=\"google-map__button\"\r\n                                        type=\"button\"\r\n                                        value={translate('reseller.nearme')}\r\n                                        onClick={onGetNearbyPlacesClick}\r\n                                    /></div>\r\n\r\n                                <div className=\"google-map__button-container google-map__button-container--map\"><input\r\n                                    className=\"google-map__button\"\r\n                                    type=\"button\"\r\n                                    value={translate('reseller.showmap')}\r\n                                    onClick={onShowMap}\r\n                                /></div>\r\n\r\n                                <input\r\n                                    type=\"label\"\r\n                                    id=\"errorLabel\"\r\n                                    style={{display: 'none'}}\r\n                                />\r\n                            </div>\r\n                            {!props.markers || props.markers.length === 0 ? (\r\n                                <div>{'No Nearby Resellers Available'}  </div>\r\n                            ) : (\r\n                                <div className=\"store-list\">\r\n                                    {resellers.map(marker => {\r\n                                        const onClick = props.onClick.bind(this, marker)\r\n                                        return (\r\n                                            <a key={marker.customerNumber} onClick={onClick}>\r\n                                                <h3>{marker.name}</h3>\r\n                                                <h6>{marker.city}</h6>\r\n                                            </a>\r\n                                        )\r\n                                    })}\r\n                                </div>)}\r\n                        </div>\r\n                    </div>\r\n                </div>\r\n            ) : (\r\n                <div id=\"GoogleMap\" className=\"google-map\">\r\n                    <div className=\"google-map__back\">\r\n                        <a style={{padding: '9px'}} onClick={onShowList} className=\"close\"></a>\r\n                        <div className=\"google-map__button-container google-map__button-container--location\">\r\n                            <input\r\n                                className=\"google-map__button google-map__button--back\"\r\n                                type=\"button\"\r\n                                value=\"Nära mig\"\r\n                                onClick={onGeoLocClick}\r\n                            />\r\n                        </div>\r\n                    </div>\r\n                    <GoogleMap\r\n                        ref={(map) => {\r\n                            fitBounds(props, map, resellers, false)\r\n                        }}\r\n                        zoom={props.zoomLevel}\r\n                        center={props.showingInfoWindow == true ? {\r\n                            lat: parseFloat(props.latitude),\r\n                            lng: parseFloat(props.longitude)\r\n                        } : props.currentMarkerCenter}\r\n                        //center={props.currentMarkerCenter}\r\n                        style={{}}\r\n                        defaultOptions={{\r\n                            styles: resellerStyle\r\n                        }}\r\n                    >\r\n                        {props.showingInfoWindow == true && (\r\n                            <Marker\r\n                                visible={props.showingInfoWindow}\r\n                                zoom={props.zoomLevel}\r\n                                center={props.defaultCenter}\r\n                                position={{lat: props.latitude, lng: props.longitude}}\r\n                            >\r\n                                <InfoWindow>\r\n                                    <div id=\"MyLocation\">\r\n                                        <br/>\r\n                                        <h1> {'You are here!'}</h1>\r\n                                        <br/>\r\n                                    </div>\r\n                                </InfoWindow>\r\n                            </Marker>\r\n                        )}\r\n\r\n                        {resellers.map(marker => {\r\n                            if (marker.lat != null) {\r\n                                const onClick = props.onClick.bind(this, marker)\r\n                                const onCloseClick = props.onCloseClick.bind(this)\r\n                                return (\r\n                                    <Marker\r\n                                        key={marker.customerNumber}\r\n                                        onClick={onClick}\r\n                                        zoom={props.zoomLevel}\r\n                                        center={{\r\n                                            lat: parseFloat(marker.lat),\r\n                                            lng: parseFloat(marker.lng)\r\n                                        }}\r\n                                        icon={\r\n                                            props.selectedMarker === marker ?\r\n                                                '/UI/images/markerselected-muurikka-v2.png' :\r\n                                                '/UI/images/marker-muurikka.png'\r\n                                        }\r\n                                        position={{\r\n                                            lat: parseFloat(marker.lat),\r\n                                            lng: parseFloat(marker.lng)\r\n                                        }}\r\n                                    >\r\n                                        {props.selectedMarker === marker &&\r\n                                            props.showingInfoWindow == false && (\r\n                                                <InfoWindow onCloseClick={onCloseClick}>\r\n                                                    <div id=\"ResellersInfo\">\r\n                                                        <h1> {marker.name}</h1>\r\n                                                        <div className=\"marker-info-div\">\r\n                                                            {marker.address}\r\n                                                            <br/>\r\n                                                            {marker.zipcode} {marker.city}\r\n                                                            <br/>\r\n                                                            {marker.phone\r\n                                                                ? translate('phonenumberlabel') + ':'\r\n                                                                : ''}{' '}\r\n                                                            <a href={\"tel:\" + marker.phone}>{marker.phone}</a>\r\n\r\n                                                            <a onClick={zoomMap} className=\"close zoom-in\"></a>\r\n                                                        </div>\r\n                                                    </div>\r\n                                                </InfoWindow>\r\n                                            )}\r\n                                    </Marker>\r\n                                )\r\n                            }\r\n                        })}\r\n                    </GoogleMap>\r\n                </div>\r\n            )}\r\n        </div>\r\n    </div>\r\n\r\n})\r\n","import React from 'react';\r\nimport {connect} from 'react-redux';\r\nimport ResellerGoogleMapForProduct from \"./ResellerGoogleMapForProduct\";\r\nimport {loadForProduct} from \"../Actions/ResellerGoogleMapProduct.action\";\r\nimport {lifecycle} from \"recompose\";\r\n\r\nlet ResellerGoogleMapForProductContainer = function (props) {\r\n    return <ResellerGoogleMapForProduct {...props} />;\r\n}\r\n\r\nResellerGoogleMapForProductContainer = lifecycle({\r\n    componentDidMount() {\r\n        const {loadForProduct, variantId} = this.props;\r\n        loadForProduct(variantId);\r\n    }\r\n})(ResellerGoogleMapForProductContainer);\r\n\r\nconst mapStateToProps = state => {\r\n    return {\r\n        data: state.resellerProduct,\r\n        productResellers: state.resellerProduct.productResellers,\r\n        resellerCountries: state.resellerProduct.resellerCountries,\r\n    }\r\n}\r\n\r\nconst mapDispatchToProps = dispatch => {\r\n    return {\r\n        loadForProduct: (variantId) => dispatch(loadForProduct(variantId)),\r\n    }\r\n}\r\n\r\nexport default connect(mapStateToProps, mapDispatchToProps)(ResellerGoogleMapForProductContainer);\r\n"],"sourceRoot":""}