From 5182b92b820974ba613d37f767af235e4fd84665 Mon Sep 17 00:00:00 2001 From: wildscotsmen Date: Sat, 27 Oct 2018 15:15:47 -0400 Subject: [PATCH] Fixed issue from merge conflict. --- src/components/SightingMap.js | 38 ++++++++++++----------------------- 1 file changed, 13 insertions(+), 25 deletions(-) diff --git a/src/components/SightingMap.js b/src/components/SightingMap.js index 98b609a..72790de 100644 --- a/src/components/SightingMap.js +++ b/src/components/SightingMap.js @@ -208,7 +208,10 @@ export class MapContainer extends Component { } } -<<<<<<< HEAD + /** + * Determines marker icon based on the + * sighting type. + */ sightingIcon = (type) => { let pinIcon @@ -230,10 +233,10 @@ export class MapContainer extends Component { } return pinIcon -======= + } + formatDate = date => { return (moment(date, "YYYY-MM").format("MMMM YYYY").toString()) ->>>>>>> 48273519cbb4fe2cd134adbfa4e7814237f3021a } // Set the state of the component to contain user coordinates and initial @@ -267,30 +270,11 @@ export class MapContainer extends Component { position={this.state.myLatLng} onClick={this.onMarkerClick} type={'You are here'} - /> - -<<<<<<< HEAD - { this.state.sightings.map((sighting) => { + /> + {this.state.sightings.map((sighting) => { let pinIcon = this.sightingIcon(sighting.type) - return ( - { return ( Date: {this.formatDate(sighting.date)}} time = {Time: {getTime(sighting.time)}} description = {Description: {sighting.desc}} ->>>>>>> 48273519cbb4fe2cd134adbfa4e7814237f3021a + icon={{ + url: pinIcon, + anchor: new google.maps.Point(32,32), + scaledSize: new google.maps.Size(32,32) + }} /> ) })}