klhebs
Posts: 16
Joined: Thu Apr 01, 2021 8:24 am

chart behavior on mobile browser

Hi,
I am struggling to get the mobile version of highstock working the same way as the desktop version.

The first problem is happened when after setting the year data then panning to the left,
Capture1.PNG
Capture1.PNG (22.56 KiB) Viewed 1227 times
then i change the setData to some one minute data and it looks fine at start
Capture2.PNG
Capture2.PNG (18.4 KiB) Viewed 1227 times
but if i start to drag the chart to left or right the scale changed.
Capture3.PNG
Capture3.PNG (8.12 KiB) Viewed 1227 times
since i dont think i can control the drag behavior on the mobile highstock and the desktop version works perfectly, is there any thing i need to aware of on the mobile version or how can i make the mobile act like the desktop one.


also i am using vue-highchart and i am try to rebuild a repo but somehow the panning does not work in codepen
https://codesandbox.io/s/highcharts-vue ... /Chart.vue
i am sure if you can repo the problem with 2set of data ,load the first data pan the chart a bit then set to another set of data and pan( using the chrome and toggle to mobile device) every thing will work fine at desktop version
pawelys
Posts: 962
Joined: Wed Sep 02, 2020 10:37 am

Re: chart behavior on mobile browser

Hi! Thanks for contacting us with your question! There's a difference between the events of the mobile and desktop version of our apps. The biggest difference are the events, that are triggered by the browser, when touching the plotArea. The pinch event often resizes the Axes, that you are touching, and it is handled separately from the events of the desktop versions. So it is almost impossible to make the chart behave the same way on mobile and on desktop. Could you check, if the same thing happens on our official demos? I didn't quite get the reproduction steps, that you provided. In case of any further questions feel free to contact us again, and I am waiting for your reply.
Paweł Lysy
Highcharts Developer
klhebs
Posts: 16
Joined: Thu Apr 01, 2021 8:24 am

Re: chart behavior on mobile browser

pawelys wrote: Wed Jul 14, 2021 7:05 am Hi! Thanks for contacting us with your question! There's a difference between the events of the mobile and desktop version of our apps. The biggest difference are the events, that are triggered by the browser, when touching the plotArea. The pinch event often resizes the Axes, that you are touching, and it is handled separately from the events of the desktop versions. So it is almost impossible to make the chart behave the same way on mobile and on desktop. Could you check, if the same thing happens on our official demos? I didn't quite get the reproduction steps, that you provided. In case of any further questions feel free to contact us again, and I am waiting for your reply.
https://codesandbox.io/s/highcharts-vue ... /Chart.vue
please refer to the example above
1. use pop out the browser window and switch to device simulation mode
first.PNG
first.PNG (32.79 KiB) Viewed 1110 times
2. panning toward the start from the 1 year data
sec.PNG
sec.PNG (38.83 KiB) Viewed 1110 times
3. change to 1 min data and pan toward the start
final.PNG
final.PNG (14.97 KiB) Viewed 1110 times
also the chart cannot pan on desktop mode after setting ordinal to true in xaxis. please also let me know the reason. Much thanks
pawelys
Posts: 962
Joined: Wed Sep 02, 2020 10:37 am

Re: chart behavior on mobile browser

Hi! This seems to be a bug connected to the ordinal Axis. We will report it as an issue on our GitHub, and we will try to fix this as soon as possible: https://github.com/highcharts/highcharts/issues/16068
Thanks for bringing it to our attention!
Kind regards,
Paweł Lysy
Highcharts Developer

Return to “Highcharts Stock”