You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by GitBox <gi...@apache.org> on 2022/08/12 06:55:32 UTC

[GitHub] [echarts] plainheart commented on issue #17503: echart tree label support click event

plainheart commented on issue #17503:
URL: https://github.com/apache/echarts/issues/17503#issuecomment-1212789347

   ECharts 5 开始 label 是支持点击事件的,如果要判断点击的是否是 label,可以按照如下代码实现
   
   ```js
   myChart.on('click', e => {
     if (e.event.target.type === 'tspan') {
       console.log('clicked label')
     }
   })
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org