react-vis icon indicating copy to clipboard operation
react-vis copied to clipboard

Highlight not working properly

Open lippyDesign opened this issue 5 years ago • 2 comments

If I do the follwing:

<XYPlot width={width} height={height}>
<HorizontalGridLines />
<VerticalGridLines />
<XAxis />
<YAxis />
<Highlight onBrushEnd={this.handleZoom} />
<HexbinSeries
    animation
    sizeHexagonsWithCount
    className="hexbin-size-example"
    radius={15}
    data={data}
    onValueClick={(datapoint, event) => {
        console.log({ datapoint, event });
    }}
/>

the highlighting drops randomly and unexpectedly (as if i release mouse), but i am still highlighting, however if I move Highlight to the end:

<XYPlot width={width} height={height}>
<HorizontalGridLines />
<VerticalGridLines />
<XAxis />
<YAxis />
<HexbinSeries
    animation
    sizeHexagonsWithCount
    className="hexbin-size-example"
    radius={15}
    data={data}
    onValueClick={(datapoint, event) => {
        console.log({ datapoint, event });
    }}
/>
<Highlight onBrushEnd={this.handleZoom} />

the highlighting works as expected, but now the Hexbin onValueClick event does not work. This is very annoying and is preventing us from going to prod with this

lippyDesign avatar Apr 25 '20 02:04 lippyDesign

I'm working on cleaning up the Highlight component here https://github.com/uber/react-vis/pull/1354

My plan is to split it up so that the Zoom and Window parts of it are separate. But the main advancement is moving the mouse handling to the XYPlot, which avoids the issues that you are seeing.

Xiot avatar Jun 11 '20 14:06 Xiot

Any updates on this?

prateek-redefcorp avatar Mar 18 '21 04:03 prateek-redefcorp