layered projects working; with some bugs

This commit is contained in:
Lachlan Kermode
2020-03-26 16:58:01 +01:00
parent 678d63f78b
commit 85476ee6fb
6 changed files with 96 additions and 23 deletions

View File

@@ -0,0 +1,23 @@
import React from 'react'
import { sizes } from '../../../common/global'
export default ({
id,
offset,
start,
end,
getX,
dims,
colour
}) => {
const length = getX(end) - getX(start)
return <rect
onClick={() => alert('TODO: associate all events')}
className='project'
x={getX(start)}
y={dims.trackHeight - offset}
width={length}
style={{ fill: colour, fillOpacity: 0.1 }}
height={2 * sizes.eventDotR}
/>
}