Skip to content

Commit b44efcf

Browse files
author
Dou Du
committed
change NLG background according to the theme
1 parent 3aeee23 commit b44efcf

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/widget.tsx

+5-1
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,11 @@ export class CounterWidget extends ReactWidget {
8282
visualizer() {
8383
this.updateDatasource();
8484

85-
this.stage = new NGL.Stage(this.uuid, { backgroundColor: 'white' });
85+
if (this.theme === 'light') {
86+
this.stage = new NGL.Stage(this.uuid, { backgroundColor: 'white' });
87+
} else {
88+
this.stage = new NGL.Stage(this.uuid, { backgroundColor: 'black' });
89+
}
8690

8791
window.addEventListener(
8892
'resize',

0 commit comments

Comments
 (0)