Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can not change chart.type when it is set in default Options #141

Closed
shelterless opened this issue Jun 20, 2017 · 8 comments
Closed

Can not change chart.type when it is set in default Options #141

shelterless opened this issue Jun 20, 2017 · 8 comments
Labels

Comments

@shelterless
Copy link

If ] does not set chart type in default options , it's work properly.

but when i set chart type in default options, i can't change it into another chart type.

can you help me ?

@cvasseng
Copy link
Contributor

I'm sorry but I don't quite understand what you mean. Which default options are you talking about?

@minervarm
Copy link

Hi @cvasseng I'm facing the same issue when initializing the editor with defaultChartOptions.

Editor version

Highcharts Editor v0.2.1

Current behavior

If I've initialized the editor with a non empty defaultChartOptions I cannot change to a different chart template later in the editor itself.

Expected behavior

I can initialize the editor with custom default options and then change the chart as desired.

Example code

var myOptions = {
    "chart": {
        "type": "pie"
    },
    "title": {
        "text": "My Chart"
    },
    "subtitle": {
        "text": "My Untitled Chart"
    },
    "data": {
        "csv": "\"slice\";\"val\"\n\"Not Pacman\";24\n\"Pacman\";76",
    }
};

var editor = highed.Editor(document.body, {
    defaultChartOptions: myOptions
});

I've detected that when you initialize the editor with defaultChartOptions then go to the tab Advanced > Chart those options are prefilled but they do not update when you change between templates or other settings for example from type = pie to type = column, this also happens if you initialize from a 3D chart and try to change to a 2D, you can see that in the Preview Options tab those properties are not being updated and you have to manually change the properties in the Advanced tab for this to take effect.

You can check that this is also happening in the live demos, for example https://cloud.highcharts.com/create?q=H1K1rtxZQ, trying to change that Basic Column Chart demo to a pie chart.

Steps to reproduce

  1. Go to https://cloud.highcharts.com/create?q=H1K1rtxZQ
  2. Go to Templates tab
  3. Click on Pie
  4. Select any Pie template

As a side note this doesn't happen when the templates are from the same "family", lest say you want to switch from Pie:basic to Pie:donut.

Thanks in advance.

@pawelfus
Copy link

Thank you for the details, you are right it's a bug.

@minervarm
Copy link

Hello, any updates on this one?

@roborto444
Copy link

Has this been fixed in recent releases?

@jigar-sheth
Copy link

Hi, any updates on this?

@cvasseng cvasseng assigned cvasseng and unassigned cvasseng Sep 18, 2018
@cvasseng
Copy link
Contributor

cvasseng commented Sep 18, 2018

Still no updates unfortunately.

@kai2468 could you take a look at this?

@lovelyelfpop
Copy link

Bug still exsits in 0.2.2-rc3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

7 participants