mirror of
https://github.com/bellingcat/ukraine-timemap.git
synced 2026-06-08 03:18:36 +03:00
Non-structure locations are marked as approximated
This commit is contained in:
@@ -61,6 +61,7 @@ class Card extends React.Component {
|
||||
<CardLocation
|
||||
language={this.props.language}
|
||||
location={this.props.event.location}
|
||||
isPrecise={(this.props.event.type === 'Structure')}
|
||||
/>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -3,13 +3,13 @@ import React from 'react'
|
||||
import copy from '../../../js/data/copy.json'
|
||||
import { isNotNullNorUndefined } from '../../../js/utilities'
|
||||
|
||||
const CardLocation = ({ language, location }) => {
|
||||
const CardLocation = ({ language, location, isPrecise }) => {
|
||||
if (isNotNullNorUndefined(location)) {
|
||||
return (
|
||||
<div className='card-cell location'>
|
||||
<p>
|
||||
<i className='material-icons left'>location_on</i>
|
||||
{location}
|
||||
{`${location}${(isPrecise) ? '' : ' (Approximated)'}`}
|
||||
</p>
|
||||
</div>
|
||||
)
|
||||
|
||||
@@ -28,7 +28,7 @@ function MapEvents ({ getCategoryColor, categories, projectPoint, styleLocation,
|
||||
let cumulativeAngleSweep = 0;
|
||||
|
||||
return (
|
||||
<g>
|
||||
<React.Fragment>
|
||||
{colorSlices.map((color, idx) => {
|
||||
const r = 10
|
||||
|
||||
@@ -48,7 +48,7 @@ function MapEvents ({ getCategoryColor, categories, projectPoint, styleLocation,
|
||||
`M ${startX} ${startY}`, // Move
|
||||
`A ${r} ${r} 0 ${largeArcFlag} 1 ${endX} ${endY}`, // Arc
|
||||
`L 0 0 `, // Line
|
||||
`L ${startX} ${startY} `, // Line
|
||||
`L ${startX} ${startY} Z`, // Line
|
||||
].join(' ');
|
||||
|
||||
const extraStyles = ({
|
||||
@@ -66,7 +66,7 @@ function MapEvents ({ getCategoryColor, categories, projectPoint, styleLocation,
|
||||
)
|
||||
})}
|
||||
|
||||
</g>
|
||||
</React.Fragment>
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
@@ -170,6 +170,7 @@
|
||||
}
|
||||
|
||||
.location-event-marker {
|
||||
pointer-events: all;
|
||||
fill: $event_default;
|
||||
stroke-width: 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user