From: Tom Pullen Date: Wed, 8 Aug 2018 16:44:53 +0000 (+0100) Subject: Add color to financial time series sample (#5661) X-Git-Tag: v2.7.3~1^2~9 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=a9c4e377a7f529a82fc1dbcef32ab23d40c9b158;p=thirdparty%2FChart.js.git Add color to financial time series sample (#5661) --- diff --git a/samples/scales/time/financial.html b/samples/scales/time/financial.html index 792eef553..b261b8986 100644 --- a/samples/scales/time/financial.html +++ b/samples/scales/time/financial.html @@ -56,12 +56,16 @@ var ctx = document.getElementById('chart1').getContext('2d'); ctx.canvas.width = 1000; ctx.canvas.height = 300; + + var color = Chart.helpers.color; var cfg = { type: 'bar', data: { labels: labels, datasets: [{ label: 'CHRT - Chart.js Corporation', + backgroundColor: color(window.chartColors.red).alpha(0.5).rgbString(), + borderColor: window.chartColors.red, data: data, type: 'line', pointRadius: 0,