highcharts / highcharts-vue

Other
686 stars 150 forks source link

Double axes visible in Export with Exporting module #19

Closed sjoris closed 5 years ago

sjoris commented 6 years ago

Hi,

When I use the Exporting module and the default export server from HighCharts, I get two Y-axis in the exports, even when I added just one Y-axis.

You can see a working example here: codesandbox.io/s/8zm10144l2 Just Click on button (1), (2) and then create an PNG export.

It seems that the SVG in the webpage and the SVG that is POSTed to the Export server are not the same. Probably another effect because of Vue. Or am I doing something wrong?

Kind regards

sebastianbochan commented 6 years ago

Hi @sjoris, Thank you for reporting. The issue is related with known bug in Highcharts. Its reported here: https://github.com/highcharts/highcharts/issues/5888 and its not related with highcharts-vue wrapper.

sjoris commented 6 years ago

Hi @sebastianbochan, Thank you for your answer. I see it might be related to the callback functionality of HighCharts, but is the workaround of Pawel (https://github.com/highcharts/highcharts/issues/5888#issuecomment-256586592) also possible with highcharts-vue?

I can't find a way to get it to work. Doesn't it have to do with the fact that the yAxis-array in the Vue chartOptions object is always twice the size of the number of actual yAxis', after you dynamically add a yAxis. This is not the case with yAxis' that are already present in the chartOptions object from the start.

pawelfus commented 6 years ago

I'm not convinced if this is a duplicate of https://github.com/highcharts/highcharts/issues/5888

Simple checking for number of axes added via addYaxis(): https://codesandbox.io/s/jj6zm8z56w results in adding two axis on each click. Every object is followed by another, observer object.

@Denyllon - could you check this?

Denyllon commented 5 years ago

Looks like the problem is resolved since v1.3.2 of the wrapper.