Skip to content

Commit

Permalink
Set backgroundColor: transparent for theme compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
billz committed Sep 10, 2023
1 parent 67df02f commit 434e8dc
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions app/js/linkquality.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,31 +3,23 @@
// Support for dark theme
theme = getCookie('theme');
if (theme == 'lightsout.css') {
var bgColor1 = '#141414';
var bgColor2 = '#141414';
var borderColor = 'rgba(37, 153, 63, 1)';
var labelColor = 'rgba(37, 153, 63, 1)';
} else if (theme == 'material-light.php') {
var bgColor1 = 'rgba(255, 255, 255, 0.5)';
var bgColor2 = 'rgba(0, 0, 0, 0.5)';
var borderColor = '#f2f2fb';
var labelColor = '#f2f2fb';
} else if (theme == 'material-dark.php') {
var bgColor1 = 'rgba(255, 255, 255, 0.5)';
var bgColor2 = 'rgba(0, 0, 0, 0.5)';
var borderColor = '#f2f2fb';
var labelColor = '#f2f2fb';
} else {
var bgColor1 = '#d4edda';
var bgColor2 = '#eaecf4';
var borderColor = 'rgba(147, 210, 162, 1)';
var labelColor = 'rgba(130, 130, 130, 1)';
}

let data1 = {
datasets: [{
data: [linkQ, 100-linkQ],
backgroundColor: [bgColor1, bgColor2],
backgroundColor: 'transparent',
borderColor: borderColor,
}],
};
Expand Down

0 comments on commit 434e8dc

Please sign in to comment.