echarts Tooltip is not displaying when the labels are hidden and symbol is set to none[Bug]

oaxa6hgo  于 3个月前  发布在  Echarts
关注(0)|答案(3)|浏览(117)

Version

5.3.0

https://codepen.io/Harshitha19/pen/yLvGMEZ

Steps to Reproduce

  1. Plot a line or an area chart.
  2. Set tooltip trigger to "item" within the series.
  3. Hide series labels and set the series symbol to none.
  4. Observe that on hiding labels and setting series symbol to none, tooltips are not being displayed.

Current Behavior

Observe that on hiding labels and setting series symbol to none, tooltips are not being displayed.

Expected Behavior

Tooltips should be displayed even on hiding the series labels and setting symbol to none.

Environment

- OS:
- Browser:
- Framework:

Any additional comments?

No response

ehxuflar

ehxuflar1#

I think this is the expected behavior because the tooltip trigger is set to be item and there are no items if it's set to be 'none' .

5jvtdoz2

5jvtdoz22#

#15437
I thought there were plans to snap to the nearest point for a graph with symbols set to "None"? I have some very large graphs which require trigger set to item, but drawing the symbols slows performance to the point that it stops responding.
Here's a jsfiddle . Performance will gradually slow down to a halt. Setting symbol to "none" drastically improves performance, but then trigger type item breaks. Trigger type axis shows way too many values to be very helpful.

pieyvz9o

pieyvz9o3#

I think it would be very beneficial to show item tooltips even the symbol is set to 'none'. Actually I find it a little counter-intuitive that the tooltip depends on the visibility of a symbol - the data item obviously is still there even if I do not want a special visualisation to be drawn. Currently, my workaround is to "hide" the item via itemStyle (transparent colors...), but that is not very convenient.

相关问题