score:0
Accepted answer
after some more tinkering, i have found the solution to the problem.
as it happens, chartjs sets a default max-width for the legend (although it doesn't specify this in the documentation). by setting legend max width to a high value, the legend can assume the whole canvas e.g.
legend: {
position: 'left',
align: 'start',
fullsize: false,
labels: {
font: {
size: 12
},
padding: 10
},
maxwidth: 9999
}
Source: stackoverflow.com
Related Query
- Resize Chart Independently From Legend in ChartJS for Canvas Download
- Chartjs random colors for each part of pie chart with data dynamically from database
- (Vue, ChartJS) Create gradient background for chart from child component canvas context
- I cant get Legend to work for my chartjs donut chart
- ChartJS custom legend doughnut separate legend from chart area
- getting additional value fields from data source for dx.chartjs doughnut chart
- Chartjs Custom Legend for Doughnut Chart Having Labelled Lines Sticking Out of Each Section
- How to clear a chart from a canvas so that hover events cannot be triggered?
- Resize chart.js canvas for printing
- Chartjs Bar Chart Legend
- show label in tooltip but not in x axis for chartjs line chart
- How to add label for ChartJs Legend
- ChartJS bar chart with legend which corresponds to each bar
- Border radius for the bar chart in ChartJS
- Chartjs - data format for bar chart with multi-level x-axes
- How to use 'time' (data from database, data type: timestamp ) for plotting graph in Chart JS
- Grouping the object by key for Chartjs bar chart
- How can I force my ChartJS canvas legend to stay in a single column?
- Side effects from Chartjs for only *some* clients
- Using Chart.js - Creating Legend for Doughnut Chart
- Removing ChartJS 2 border and shadow from point style legend
- ChartJS bar chart fixed width for dynamic data sets
- ChartJS (React) Line Chart - How to show single tooltip with data and labels from 3 (multiple) dataset?
- Stacked bar chart starting from 0 - ChartJS React
- Is it possible to change pointStyle for elements of a ChartJS bubble chart per dataset?
- How to create chartjs chart with data from database C#
- Multiple bubble chart datasets for chartjs
- canvas fill text vanishes when hovering over chartjs pie chart
- Chartjs - Donut Chart label for small values not visible
- How do I add time sourced from an external source as an X axis to a ChartJS graph?
More Query from same tag
- Loop through array of objects in Node
- Dynamically created Chart.js chart overpopulating time based x-axis?
- Chart js. How to change font styles for "labels" array?
- Parsing error: Unexpected token, expected ";" line 54 in .map function
- ChartJS doesnt display labels provided by Jinja variable
- Getting (X,Y) point on mouse click on chart
- How to disable a tooltip for a specific dataset in ChartJS
- Vue.js component for Chart.js - strange issue on AJAX reload
- Change Chartjs financial chart yaxis from left to right
- How to include chart js annotations in ember?
- How do I add padding on the right of tooltip, but not the left in Chart.js?
- Resize bars' chart in ReactChartJS
- Chart.js - Avoid line to goes to zero and remove dot for this situation
- How to use 'time' (data from database, data type: timestamp ) for plotting graph in Chart JS
- ChartJs in endless loop
- Chart.js - How to Add Text in the Middle of the Chart?
- Chart.js Customize tool tip to show more data
- How to display multiple y axis titles on seperate lines and rotated 90 degrees clockwise in chart.js
- Render Chartjs on hidden DIV
- How do I selecting a date range (like onClick but drag/select)
- Chart.js making this chart more readable / scrollable
- Custom gridLines and Axes Chartjs
- Provide Chart.js with data via AJAX JSON not working?
- Multiple usage of Javascript function
- Chart.js glitches and reverts to previous dataset on hover
- chartjs time cartesian axis adapter and date library setup
- ChartJS - Donut charts with multiple rings
- How to hide the legend in chart.js in a react project?
- Can we have number value on the top of charts bars.?
- Trying to update data in chart.js chart