With the release of Bases and a focus on document properties, it feels like Obsidian is inching closer to accommodating an object-based notetaking system like the kind that Capacities offers. I’ve found that I’m able to approximate a Capacities-like workflow with the following missing components:
-
Slash (‘/’) event handler that exposes a suggest menu populated with Core Template file names.
-
Menu onClick pops a modal with fillable property fields defined by the selected Template.
-
Modal onSubmit writes a new file based on the Template + provided modal field values.
-
At (‘@’) event handler that exposes a suggest menu populated with names of existing object-based notes (discernable via known property e.g. ObjectClass: Person).
-
Menu onClick inserts a link to selected object-note.
I managed to implement the above in a proof of concept plugin, but it’s not in any shape to publish at the moment. Some of the issues I’m running into:
- Handling the “/” and “@” events across all relevant fields (e.g. property fields, Editor, modal fields) is difficult to do elegantly. registerEditorSuggest() is nice, but it only applies to the Editor.
- Inserting links at the cursor position while handling filter strings (e.g. “/Pers” to create a new Person note, or “@Nam” to insert “[[Name]]” is tricky.
If not an entirely new plugin, there may be existing Community Plugins that fill the gaps here. Just figured I’d throw this idea out there for someone better at this than I am.