tth05 / obsidian-completr

Auto-completion plugin for the obsidian editor.
MIT License
303 stars 18 forks source link

YAML tags complete support? #2

Closed zeltak closed 2 years ago

zeltak commented 2 years ago

Hi and thx for this cool new plugin!

any chance that it can complete tags in YAML front matter?

currently obsidian is really missing that and could be super useful!

best

Z

tth05 commented 2 years ago

Could you explain a bit more how you would like this to work? Only completions I could think of are the following.

To start front-matter completes to:

---
<cursor>
---

Inside of the front matter:

Is this what you expect, or did you mean something else?

zeltak commented 2 years ago

thx @tth05 !i meant rather complete available tags from the internal tag list so if i have a tag named "asia" when i enter asa it completes to asia

does that make sense?

thx!

Z

tth05 commented 2 years ago

thx @tth05 !i meant rather complete available tags from the internal tag list so if i have a tag named "asia" when i enter asa it completes to asia

I see. I thought you meant the actual YAML tags and not the obsidian tags :D

Would you still like the other features I mentioned or just the tag completion?

zeltak commented 2 years ago

Hi!

well tag completion is the top priority (for me at least :)) but other features are also cool :D

thx for all your hard work!

Z

tth05 commented 2 years ago

@zeltak I'll do https://github.com/tth05/obsidian-completr/issues/2#issuecomment-1005258885 and tag completion then :)

tth05 commented 2 years ago

@zeltak I've implemented it! You can look at the README for a preview. e6418e2bdb64a3fc6e29f6b4e6aece33b568bf38

zeltak commented 2 years ago

thx so much !

i tried installing via

Browse the community plugins list and search for Completr.

but didn't see it in the list?

also installed manually but didn't get an plugin options nor did the YAML tags work 🗡️

Very happy to help debug this (unless i missed something glaring :D )

thx so much1!!

Z

tth05 commented 2 years ago

but didn't see it in the list?

The plugin hasn't been accepted yet.

also installed manually but didn't get an plugin options nor did the YAML tags work 🗡️

  • Did you put all three files in the correct folder?
  • Does it show up in the Community plugins tab in your settings?
  • Did you enable the plugin? This has to be done manually when you manually install it.
zeltak commented 2 years ago

Hi again

ok finally got it installed (used BRAT which is sweet :))

in any case in front matter lists ie:

---
tags: 
- india
- 

it doesn't seem to complete here unless i start with the # sign and then it uses the obsidian tag completion \

since i use lists for tags in YAML i want to keep the list formatting so that the tags complete without the #.. is that what i need to expect or does the current implementation use the # sign

thx so much for your awesome plugin!

Z

tth05 commented 2 years ago

ok finally got it installed (used BRAT which is sweet :))

The plugin just got accepted into the official community plugins, so you can install it from within obsidian now :)

since i use lists for tags in YAML i want to keep the list formatting so that the tags complete without the #.. is that what i need to expect or does the current implementation use the # sign

The current implementation was only made to work with the single line list style (e.g. tags: [one,two,three]). I'll change so it works with your use-case as well.

tth05 commented 2 years ago

@zeltak Should now work with the newest version!

zeltak commented 2 years ago

sweeeeettttt!

this just made my week! thx so much for this is much appreciated!

best

Z

zeltak commented 2 years ago

sorry last question, will this work on the mobile (iOS) @tth05 ?

seems to work perfect on my mac but not ios or iPadOS?

thx allot!

Z

tth05 commented 2 years ago

Haven't tested it on mobile and the plugin is also marked as desktop only. It would probably work but I'm just not really a fan of supporting mobile.