Fix zoom-out on an image [#131080] (#134706)

This commit is contained in:
Damian Cyntler
2021-10-15 23:38:38 +02:00
committed by GitHub
parent 38a711024d
commit a12e9cd91e
2 changed files with 1 additions and 11 deletions
+1 -1
View File
@@ -59,7 +59,7 @@
];
const settings = getSettings();
const isMac = settings.isMac;
const isMac = navigator.platform.toUpperCase().indexOf('MAC') >= 0;
const vscode = acquireVsCodeApi();
-10
View File
@@ -206,7 +206,6 @@ class Preview extends Disposable {
private async getWebviewContents(): Promise<string> {
const version = Date.now().toString();
const settings = {
isMac: isMac(),
src: await this.getResourcePath(this.webviewEditor, this.resource, version),
};
@@ -262,15 +261,6 @@ class Preview extends Disposable {
}
}
declare const process: undefined | { readonly platform: string };
function isMac(): boolean {
if (typeof process === 'undefined') {
return false;
}
return process.platform === 'darwin';
}
function escapeAttribute(value: string | vscode.Uri): string {
return value.toString().replace(/"/g, '&quot;');
}