antvis/G2




The issue has been closed
5.1.15: theme 'dark' applies black background color #6164
sspilleman posted onGitHub
Problem Description: theme 'dark' applies black background color. I think a lot of projects offering a dark mode use a different background color (than black).
Maybe you want to consider using 'transparent' by default instead? If i'm not mistaken, I think the 'light' theme already uses transparent by default. Also see workaround below. I had to use 'none' to get rid of it... Using 'transparent' instead of 'none' feels more natural?
Workaround:
chart.options({
theme: {
type: 'dark',
view: {
viewFill: 'none' <------------
}
},
});