toomuchdesign/react-minimal-pie-chart

Not possible to render content inside chart on 8.0

morgoth opened this issue · 1 comments

I'm upgrading package from 7.1.0 to 8.0.1 and rendering custom content inside chart stopped working.
Having something like:

<PieChart
 ...
>
  {someContentHere}
</PieChart>

it was possible to render something inside.
Now the children content is part of svg tag, thus rendering HTML chart inside is not possible.
Is there any way to make it work as it was before?

Specifications

  • Version: 8.0.1

Hi @morgoth,
version 7 rendered chart's svg element inside a div. Children were rendered below svg element inside the div.

From version 8, the svg element is returned with no wrappers, and is up to the user to wrap and render it along with any further element.