obsidian-simple-mention
obsidian-simple-mention copied to clipboard
Feature Request: @[[Name]]
Hi, I don't know if this specific use case is something that only fits me, but I have notes related with a person, and sometimes I don't remember who is who, so I do a person note with their photo, information, etc.
So nowadays (without this extension) I usually mention people by [[Person]]... So I'm wondering if there would be a possibility to generate some @[[Person]] mentions instead that would be considered mentions, and be links to a file all the same.
Alternatively, keep the mentions as they are, but allowing to create a note related the @person mention. idk if this makes sense..
Regards,
I am looking for basically the exact same feature! (My Idea was, to have the @ sign as part of the note name so that typing @person would be turned into [[@person]].
For somebody who knows what they're doing, this would probably be a rather small change because as far as I understand, the current code wraps the mention in html tags (which remain invisible in Obsidian). For me, it would suffice to replace those tags with [[ and ]]. I believe this is the method that does the wrapping:
https://github.com/der-tobi/obsidian-simple-mention/blob/969641d4db149258bf4b8c4ccc82bc673915aef7/src/MentionPostProcessor.ts#L82-L91
ChatGPT suggests that this method simply needs to be replaced with something like this:
private surroundWithBracket(text: string): string {
return `[[${text}]]`;
}
But I'm not sure how exactly to accomplish that.