What problem does this feature solve?
Ability to add multiple markers/selectors in the chart by the end user at a specific point similar to brush functionality , and moving them by dragging. current brush functionality allows us to select only a range of points.
Example scenario of it .
https://stackoverflow.com/questions/75064009/customizing-echart-horizontal-select-brush-functionality-to-select-single-point
What does the proposed API look like?
Similar to brush functionality (Horizontal & Vertical selection )
- A button in the toolbox to enable the selector.
- after adding selectors/annotations to the chart, an event to capture selectors :
1条答案
按热度按时间xv8emn3q1#
Look at this example .
By clicking twice on the chart, you will get two points pointInGridA and pointInGridB. Then you could add a MarkArea between their X-coordinates.
It will look exactly like the yellow area in your example :