Skip to content

Commit

Permalink
Fix link detection for markdown linsk without space between them
Browse files Browse the repository at this point in the history
Fixes #37018
  • Loading branch information
mjbvz committed Nov 11, 2017
1 parent 98d11f1 commit 25efef4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion extensions/markdown/src/documentLinkProvider.ts
Expand Up @@ -41,7 +41,7 @@ function matchAll(pattern: RegExp, text: string): Array<RegExpMatchArray> {
}

export default class LinkProvider implements vscode.DocumentLinkProvider {
private readonly linkPattern = /(\[[^\]]*\]\(\s*?)(((((?=.*\)\)+)|(?=.*\)\]+))[^\s\)]+?)|([^\s]+)))\)/g;
private readonly linkPattern = /(\[[^\]]*\]\(\s*?)(((((?=.*\)\)+)|(?=.*\)\]+))[^\s\)]+?)|([^\s]+?)))\)/g;
private readonly referenceLinkPattern = /(\[([^\]]+)\]\[\s*?)([^\s\]]*?)\]/g;
private readonly definitionPattern = /^([\t ]*\[([^\]]+)\]:\s*)(\S+)/gm;

Expand Down

0 comments on commit 25efef4

Please sign in to comment.