mirror of
https://github.com/bellingcat/ukraine-timemap.git
synced 2026-06-12 05:18:34 +03:00
WIP: gritty rewrite of timestamp handling
This commit is contained in:
@@ -2,21 +2,23 @@ import React from 'react'
|
||||
import { sizes } from '../../../common/global'
|
||||
|
||||
export default ({
|
||||
id,
|
||||
offset,
|
||||
id,
|
||||
start,
|
||||
end,
|
||||
getX,
|
||||
y,
|
||||
dims,
|
||||
colour,
|
||||
onClick
|
||||
}) => {
|
||||
const length = getX(end) - getX(start)
|
||||
if (offset === undefined) return null
|
||||
return <rect
|
||||
onClick={onClick}
|
||||
className='project'
|
||||
x={getX(start)}
|
||||
y={dims.trackHeight - (offset + sizes.eventDotR)}
|
||||
y={dims.marginTop + 100}
|
||||
width={length}
|
||||
style={{ fill: colour, fillOpacity: 0.2 }}
|
||||
height={2 * sizes.eventDotR}
|
||||
|
||||
Reference in New Issue
Block a user