🐛 fix: #139 Adjust url regex to exclude URLs with display text

Closes: #139
This commit is contained in:
Nathan Smith 2024-08-16 21:27:09 -04:00
parent 43728122a6
commit 0fb4e4dbd0

View file

@ -44,7 +44,7 @@ export function createInlineViewPlugin(_plugin: GithubLinkPlugin) {
public inlineTags: DecorationSet = Decoration.none;
private readonly matcher = new MatchDecorator({
regexp: /(https:\/\/)?github\.com\S+/g,
regexp: /(?<!\[.*?\]\()https:\/\/github\.com\/[^\s,.)]+/g,
decorate: (add, from, to, match, _view) => {
add(
from,