File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -78,13 +78,13 @@ export class ArduinoContentProvider implements vscode.TextDocumentContentProvide
78
78
console.log('reloaded results window at time ${ timeNow } ms');
79
79
var doc = document.documentElement;
80
80
var styles = window.getComputedStyle(doc);
81
- var backgroundcolor = styles.getPropertyValue('--background-color');
82
- var color = styles.getPropertyValue('--color');
83
- var theme = document.body.className;
81
+ var backgroundcolor = styles.getPropertyValue('--background-color') || '#1e1e1e' ;
82
+ var color = styles.getPropertyValue('--color') || '#d4d4d4' ;
83
+ var theme = document.body.className || 'vscode-dark' ;
84
84
var url = "${ this . _webserver . getEndpointUri ( type ) } ?" +
85
- "theme=" + theme +
86
- "&backgroundcolor=" + backgroundcolor +
87
- "&color=" + color;
85
+ "theme=" + encodeURIComponent( theme.trim()) +
86
+ "&backgroundcolor=" + encodeURIComponent( backgroundcolor.trim()) +
87
+ "&color=" + encodeURIComponent( color.trim()) ;
88
88
document.getElementById('frame').src = url;
89
89
};
90
90
</script>
You can’t perform that action at this time.
0 commit comments