Making pizza-chart reusable for different charts