score:12
Accepted answer
change background color
use css to set background color for canvas (chart) element :
canvas {
background-color: rgba(47, 152, 208, 0.1);
}
remove grid-lines
set display
property of gridLines to false
for both x and y axis :
scales: {
xAxes: [{
gridLines: {
display: false
}
}],
yAxes: [{
gridLines: {
display: false
}
}]
}
change text of tooltip's label (add $ symbol)
use a callback function for tooltips label, as such :
tooltips: {
callbacks: {
label: function(t, d) {
var xLabel = d.datasets[t.datasetIndex].label;
var yLabel = d.datasets[t.datasetIndex].data[t.index];
return xLabel + ': $' + yLabel;
}
}
}
see a working example.
Source: stackoverflow.com
Related Query
- how to change background in chartjs and remove background lines?
- Remove y and x axis lines and change axis font style in Chartjs
- How to change the color of legend in chartjs and be able to add one more legend?
- How to remove gridlines and grid labels in Chartjs Radar?
- ChartJS click on bar and change it's background color
- How to add background color between two lines in yAxis Chartjs
- How to remove background color and color example from tooltip in Chart.js?
- How to add background color between two specific lines in Chartjs 3.1
- How to change the fontFamily of the labels and remove the grid in chart.js
- How to add new data point and remove leftmost data point dynamically in Chartjs
- how can i remove the grid lines in chartJs
- How to remove all gridlines and ticks all lines in lines chart in javascript taken from cdn)
- How can I change background color of a specific area in my chart's grid using Chart.js and Annotation?
- How to remove old chart and append new chart to div using chartjs
- How can I move chartJs legend left side and change the width and Hight of the chart?
- How to remove Grid lines except for zero line and border Chartjs?
- ChartJs How to display horizontal and vertical lines through the datasets points with their values on axes?
- How can I change the color of certain lines in chartjs / vue-chartjs?
- How to add space Between Columns in Bar chartjs and remove the space in the end
- ChartJS Line Charts - remove color underneath lines
- How to remove square label from tooltip and make its information in one line?
- how to change size of point in ChartJS
- chartjs datalabels change font and color of text displaying inside pie chart
- How to save Chart JS charts as image without black background using blobs and filesaver?
- ChartJS : How to leave just points without lines
- Change point size and color on hover in chartjs
- ChartJS and jsPDF - why the background is black?
- How to change the cursor to a pointer when I hover over a bar in a ChartJS bar chart?
- How to feed hour and minute data into chartJS
- How to set a full length background color for each bar in chartjs bar
More Query from same tag
- Javascript chart.js data object/array
- Execute chartjs after an ajax call with PHP
- Why are more columns on one labels in Angular ChartJS?
- save my chart.js output to an image
- Displaying dataset labels in Chart.js line graph
- Line graph with linear timescale in Chart.js
- How to generate multi bar chart in Chart.js with php & sql
- Chart.Mvc colliding with System.Web.Helpers.Chart
- Chart.js page is zooming out everytime we change to a different graph while using a browser on with IOS El Capitan or latest iPad version
- How to specify ticks locations in chart.js?
- my anchor tags are not working in my website after i added chart.js in it
- ChartJS pie chart with simple parsing options doesn't render, only works when set as bar/line chart
- Multi label tool-tip in Chart.js
- Charting Commodity Data - Issue getting the dates and values in JSON
- How to set static labels for ng2-charts bar charts?
- Uncaught TypeError: Cannot read property 'format' of undefined
- Two Y-axis not aligning correctly
- Chartjs Timestamp to Datetime labels
- Chart.js not showing up on online site
- after div display set to block nothing shows
- How I connect chart.js to database in ASP.NET web form?
- add labels dynamically in Charts.js
- Chart.js Label Issue
- The chart list is not showing
- How to remove the line/rule of an axis in Chart.js?
- Using string list as Chart.js label
- Charts.js how to fix the height with more than 50 horizontal bars
- chartjs - Not taking the height in reponsive chart
- Stacked Bar chart fixed width bar chart issue - Chartjs
- ng2charts using borderColor with array value