Unable to scroll amcharts chart on mobile devices

Thus, I have a chart that is 100% distributed when on a mobile phone, but when I try to scroll the screen by touching the graph and scrolling, it just fires an event instead of scrolling. For example, if I try to scroll a pie chart, it will cause a piece of cake bubble.

Is there an event that I could turn off to alleviate this problem?

+5
source share
2 answers

Fixed setting options in the chart

"panEventsEnabled": false

+6
source

For line graphs, I had to use a combination of the two below:

 "panEventsEnabled": false 

From http://docs.amcharts.com/javascriptstockchart/PanelsSettings#panEventsEnabled

and

 "pan":true 

From http://docs.amcharts.com/3/javascriptcharts/ChartCursor#pan

Hope this helps!

+1
source

Source: https://habr.com/ru/post/1206912/


All Articles