unipept/unipept-visualizations

Changing the ColorPalette does not always seem to work

pverscha opened this issue · 2 comments

A custom ColorPalette can be set as one of the options to the Sunburst visualization. However, changing this setting does not seem to have effect

This issue is caused by "reusing" data over multiple Sunburst-visualizations. The sunburst internally adds or changes properties of the given data elements, causing weird bugs when these objects are shared among multiple visualizations. We should update the docs and inform the user that he needs to pass a deep copy of the original data to the constructor of the sunburst (and the other visualizations as well) if he wants to reuse this data.

I've added a warning to the page describing the input data format: https://github.com/unipept/unipept-visualizations/wiki/DataNode