esm7 / obsidian-map-view

Interactive map view for Obsidian.md
MIT License
546 stars 25 forks source link

[Feature request] Support nested tags #226

Closed Satanniel closed 4 months ago

Satanniel commented 4 months ago

Obsidian has the nested tags feature and it would be great to support it, instead of having to type immediately for every subtag, and also for basic consistency.

Threre are two spots where this is relevant (at least I've noticed).

Icons

I initially assumed it works, but here is the case where I've noticed it doesn't. image (ignore the mess on unrelated entries) I've started adding pilgrimage (visits to real locations used in anime, etc.) spots for BokuYaba and I had a default icon for #pilgrimage which I've assumed will be used before I add more precise one. Alas, it just used a default one. This would be also relevant for cases where I don't have many spots so there is no point in defining its own icon.

Search filters

Continuing with the previous case. When searching for tag:pilgrimage in Obsidian's search I would've also get results for notes with the subtags, this is not the case for the Map View, which makes filtering much less convenient.

esm7 commented 4 months ago

It might not work exactly as you may expect, but you can achieve this using wildcards. The * sign will match against any set of characters, so you can use #pilgrimage/* to match all nested tags or #pilgrimage* if you also want to match the "base" tag itself.