Skip to content

RGBA notation doesn't work for colouring pie chart #476

@tiagosiebler

Description

@tiagosiebler

Overview

Describe the issue. What is the issue and what did you expect?
Because of issue #373 I moved to the latest versions of Chart.js and Angular-chart.js:

  • Angular-chart.js: 1.0.2
  • Chart.js: 2.2.1

Both downloaded via npm. Before moving, the rgba notation worked for customizing the colours of pie charts. After moving to the newer version of both dependencies, rgba colours are only working for line and bar charts (haven't tested others), pie and doughnut charts aren't taking values I provide here.

Step to reproduce

Reproduced in jsfiddle:
http://jsfiddle.net/TSTS123/zcLvjLnL/

I've included a few prewritten attempts to predefine the colour-set used by the pie chart. Only hex notation seems to work (see "$scope.colors").

$scope.oldColors is what worked before upgrading.

All the others are variations of my attempts to get this working in the latest version. Is anybody able to get this working? I like the transparency effect of charts using the alpha value in rgba.

Thanks!
Tiago

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions