lean4monaco 1.1.10 → 1.1.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/leanmonaco.js +5 -1
- package/package.json +1 -1
package/dist/leanmonaco.js
CHANGED
|
@@ -152,7 +152,7 @@ export class LeanMonaco {
|
|
|
152
152
|
"editor.fontFamily": "'Noto Color Emoji', 'JuliaMono'",
|
|
153
153
|
"editor.wordWrap": "on",
|
|
154
154
|
"editor.wrappingStrategy": "advanced",
|
|
155
|
-
"workbench.colorTheme": "Visual Studio Light",
|
|
155
|
+
"workbench.colorTheme": isBrowserDefaultDark() ? "Visual Studio Dark" : "Visual Studio Light",
|
|
156
156
|
...options.vscode
|
|
157
157
|
});
|
|
158
158
|
if (this.disposed) {
|
|
@@ -253,3 +253,7 @@ export class LeanMonaco {
|
|
|
253
253
|
this.abbreviationFeature = undefined;
|
|
254
254
|
}
|
|
255
255
|
}
|
|
256
|
+
/** Returns true if the browser wants dark mode */
|
|
257
|
+
function isBrowserDefaultDark() {
|
|
258
|
+
return window.matchMedia('(prefers-color-scheme: dark)').matches;
|
|
259
|
+
}
|