mirror of
https://github.com/microsoft/vscode.git
synced 2026-05-03 23:06:49 +01:00
Enable Markdown Scroll Syncronization for Untitled Files (#20072)
Fixes #20070 **Bug** Markdown scroll sync and other sync features do not work for untitled files. The root cause seems to be that the `main.js` markdown file is never loaded **Fix** Instead of a using a path without a scheme for `main.js`, use a `file://` path
This commit is contained in:
@@ -30,7 +30,7 @@ export class MDDocumentContentProvider implements vscode.TextDocumentContentProv
|
||||
}
|
||||
|
||||
private getMediaPath(mediaFile: string): string {
|
||||
return this.context.asAbsolutePath(path.join('media', mediaFile));
|
||||
return vscode.Uri.file(this.context.asAbsolutePath(path.join('media', mediaFile))).toString();
|
||||
}
|
||||
|
||||
private isAbsolute(p: string): boolean {
|
||||
|
||||
Reference in New Issue
Block a user