-
Notifications
You must be signed in to change notification settings - Fork 12k
Broken render on Brave (Chrome) browser? #10539
Copy link
Copy link
Closed
Labels
Description
Expected behavior
I would expect to see the rendered chart in the same way it's rendered on Firefox or Safari
Safari example:
Firefox example:
Current behavior
Legend and Axes length/space is being ignored
Brave (Chrome) example:
Reproducible sample
( code sample below - data provided through AJAX/JSON call )
Optional extra steps/info to reproduce
Chart.js is being included through CDN
https://cdn.jsdelivr.net/npm/chart.js
And I use this code
$(function () {
const usersCountOverTimeChartJsonData = $.ajax('/admin/stats/users/count', {
'type': 'GET',
'dataType': 'json',
'success': function (data) {
const usersCountOverTimeChartLabels = [];
const usersCountOverTimeChartDataSetActivated = [];
const usersCountOverTimeChartDataSetPending = [];
$.each(data, function(month, values) {
usersCountOverTimeChartLabels.push(month);
usersCountOverTimeChartDataSetActivated.push(values.activated);
usersCountOverTimeChartDataSetPending.push(values.pending);
});
const usersCountOverTimeChartData = {
labels: usersCountOverTimeChartLabels,
datasets: [{
label: 'Activated',
backgroundColor: 'rgb(58, 110, 165)',
borderColor: 'rgb(58, 110, 165)',
data: usersCountOverTimeChartDataSetActivated,
},{
label: 'Activation Pending',
backgroundColor: 'rgb(224, 151, 0)',
borderColor: 'rgb(224, 151, 0)',
data: usersCountOverTimeChartDataSetPending,
}]
};
const usersCountOverTimeChartConfig = {
type: 'line',
data: usersCountOverTimeChartData,
options: { plugins: { legend: { position: 'bottom' } } }
};
const usersCountOverTimeChart = new Chart(
document.getElementById('usersCountOverTimeChart'),
usersCountOverTimeChartConfig
);
},
});
});Possible solution
No response
Context
No response
chart.js version
v3.8.2
Browser name and version
Brave - Version 1.41.100 Chromium: 103.0.5060.134 (Official Build) (arm64)
Link to your project
No response
Reactions are currently unavailable


