Make it work with mobile too

This commit is contained in:
Nick Mowen 2023-06-21 16:23:55 -06:00
parent 9d9950c7d4
commit 0b2053d159

View File

@ -42,6 +42,8 @@ export default function TimelineEventOverlay({ event, eventOverlay, cameraConfig
className="absolute border-4 border-red-600" className="absolute border-4 border-red-600"
onMouseEnter={() => setIsHovering(true)} onMouseEnter={() => setIsHovering(true)}
onMouseLeave={() => setIsHovering(false)} onMouseLeave={() => setIsHovering(false)}
onTouchStart={() => setIsHovering(true)}
onTouchEnd={() => setIsHovering(false)}
style={{ style={{
left: `${boxLeftEdge}%`, left: `${boxLeftEdge}%`,
top: `${boxTopEdge}%`, top: `${boxTopEdge}%`,