Skip to content

Commit

Permalink
Fix markdown reference links for links with spaces
Browse files Browse the repository at this point in the history
  • Loading branch information
mjbvz committed Sep 8, 2017
1 parent 1e5274d commit 5829262
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion extensions/markdown/src/documentLinkProvider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ function matchAll(pattern: RegExp, text: string): Array<RegExpMatchArray> {
export default class LinkProvider implements vscode.DocumentLinkProvider {
private linkPattern = /(\[[^\]]*\]\(\s*?)(((((?=.*\)\)+)|(?=.*\)\]+))[^\s\)]+?)|([^\s]+)))\)/g;
private referenceLinkPattern = /(\[([^\]]+)\]\[\s*?)(\w*)\]/g;
private definitionPattern = /^([\t ]*\[(\w+)\]:\s*)(\S+)/gm;
private definitionPattern = /^([\t ]*\[([^\]]+)\]:\s*)(\S+)/gm;

public provideDocumentLinks(
document: vscode.TextDocument,
Expand Down

0 comments on commit 5829262

Please sign in to comment.