obsidian-front-matter-title
obsidian-front-matter-title copied to clipboard
Render title in links
The setting options of the plugin shows an 'File Note Link', which suggest (to me) the idea that links could render the title of the note, instead of its filename.
If that's the idea, I think it's not working. For me, links keeps rendering the filename Everything else is working or rendering as expected (Header title, Explorer title, Graph title, Quick switcher)
@carugnom Hi, thank you for the feedback. Could you give me some screenshots? This option has to replace aliases of links if enabled. Also by default it replaces links without aliases, but you can change this behavoiur.
https://user-images.githubusercontent.com/3987716/192144983-36cc3739-bcfe-4310-a8a7-de2f7265df45.mp4
@Snezhig thank you for the quick reponse
My intention is to do something like this
Just specify a 'title' key in the frontmatter, and have the link rendering that name
This examples is... I've created a note with 'testing-obsidian-front-matter' as the filename
In the front matter I've specified the title as 'XXX'
As show in the screenshot, the note title (upper left) was update correctly to 'XXX'
But when I create a link to itself, the rendered text is still 'testing-obsidian-front-matter' instead of 'XXX'
I hope the example is clear enough Cheers
@carugnom yes, I got the idea. I though about this feature and I will try to add it, but after 0.16.* release, because it will bring some breaking changes.
ok, but what was the 'File Note Link' option meant for ? 'File Note Link' really sounds to be that functionality, IMHO Additionally, what name would have that new option after the 0.16 release ? Thank you for the clarification... I (and many others) will be waiting for that behavior ;)
Thinking of it... would it handle notes with the same title ? That would be great to support ambiguations (ie: many notes titled 'data types' would exist across several contexts)
It just will be a feature of File Note Link manager. Like the approve modal. May be I just make the changing logic as a separate feature too to give you some way to use the Manager (one of or both):
- To replace aliases of links
- To change suggested titles
Now the plugin has 1 feature for the Explorer Manager and for the File Note Link manager.
About notes with the same titles. I think it will be like it works now if you have the same alias:
All that sounds good... thank you for the effort !!
Maybe this plugin could be used as inspiration https://github.com/basham/obsidian-alias-from-heading
It creates a new alias (in the file cache, not in the file content) and makes the file title searchable by title.
@gilmrjc I will check it. Thanks.
@carugnom
You can kind of workaround it when defining alias
instead of title
, and changing the template field in the plugin settings from title
to alias
.
I've noticed this plugin only displays the title, but if you try to link a note, or click on the note in the graph it creates a new note. It's most likely because the displayed title doesn't exist in the notes yet. If you define an alias, at least obisidian will understand the note already exists.