Fixed issue from merge conflict.

This commit is contained in:
wildscotsmen 2018-10-27 15:15:47 -04:00
parent 229bc1fa51
commit 5182b92b82
1 changed files with 13 additions and 25 deletions

View File

@ -208,7 +208,10 @@ export class MapContainer extends Component {
} }
} }
<<<<<<< HEAD /**
* Determines marker icon based on the
* sighting type.
*/
sightingIcon = (type) => { sightingIcon = (type) => {
let pinIcon let pinIcon
@ -230,10 +233,10 @@ export class MapContainer extends Component {
} }
return pinIcon return pinIcon
======= }
formatDate = date => { formatDate = date => {
return (moment(date, "YYYY-MM").format("MMMM YYYY").toString()) return (moment(date, "YYYY-MM").format("MMMM YYYY").toString())
>>>>>>> 48273519cbb4fe2cd134adbfa4e7814237f3021a
} }
// Set the state of the component to contain user coordinates and initial // Set the state of the component to contain user coordinates and initial
@ -269,28 +272,9 @@ export class MapContainer extends Component {
type={'You are here'} type={'You are here'}
/> />
<<<<<<< HEAD {this.state.sightings.map((sighting) => {
{ this.state.sightings.map((sighting) => {
let pinIcon = this.sightingIcon(sighting.type) let pinIcon = this.sightingIcon(sighting.type)
return (
<Marker
key={ sighting.id }
position={{ lat: sighting.lat, lng:sighting.lng }}
onClick = { this.onMarkerClick }
type = { 'Type: ' + sighting.type }
confidence = { 'Confidence: ' + sighting.confidence }
date = { 'Date: ' + sighting.date }
time = { 'Time: ' + sighting.time }
description = { 'Description: ' + sighting.desc }
icon={{
url: pinIcon,
anchor: new google.maps.Point(32,32),
scaledSize: new google.maps.Size(32,32)
}}
=======
{this.state.sightings.map((sighting) => {
return ( return (
<Marker <Marker
key = {sighting.id} key = {sighting.id}
@ -301,7 +285,11 @@ export class MapContainer extends Component {
date = {<Fragment><b>Date:</b> {this.formatDate(sighting.date)}</Fragment>} date = {<Fragment><b>Date:</b> {this.formatDate(sighting.date)}</Fragment>}
time = {<Fragment><b>Time:</b> {getTime(sighting.time)}</Fragment>} time = {<Fragment><b>Time:</b> {getTime(sighting.time)}</Fragment>}
description = {<Fragment><b>Description:</b> {sighting.desc}</Fragment>} description = {<Fragment><b>Description:</b> {sighting.desc}</Fragment>}
>>>>>>> 48273519cbb4fe2cd134adbfa4e7814237f3021a icon={{
url: pinIcon,
anchor: new google.maps.Point(32,32),
scaledSize: new google.maps.Size(32,32)
}}
/> />
) )
})} })}