Trying to get the x and y values at mouse over position.
<XYPlot
xType="time"
getX={ d => d[0] }
getY={ d => d[1] }
width={300}
height={300}>
<LineSeries
color="orange"
data={graphData}
onSeriesMouseOver={(event)=> {
console.log('val', event)
}}
/>
<XAxis />
<YAxis />
</XYPlot>
When i log the event i get {event: Class}. The docs are not clear on how to get the value
I have tried event.target.value and event.currentTarget but they are undefined. Has anyone come across this issue before and have a solution or work around?
When i expand the event object i get the following
event: Class
altKey: (...)
bubbles: (...)
button: (...)
buttons: (...)
cancelable: (...)
clientX: (...)
clientY: (...)
ctrlKey: (...)
currentTarget: (...)
defaultPrevented: (...)
detail: (...)
dispatchConfig: null
eventPhase: (...)
getModifierState: (...)
isDefaultPrevented: (...)
isPropagationStopped: (...)
isTrusted: (...)
metaKey: (...)
movementX: (...)
movementY: (...)
nativeEvent: (...)
pageX: (...)
pageY: (...)
relatedTarget: (...)
screenX: (...)
screenY: (...)
shiftKey: (...)
target: (...)
timeStamp: (...)
type: (...)
view: (...)
_dispatchInstances: null
_dispatchListeners: null
_targetInst: null
preventDefault: (...)
stopPropagation: (...)