sethyuan / logseq-plugin-tocgen

Generate a TOC of any page anywhere to quickly access the page's content.
MIT License
144 stars 10 forks source link

Not being scrolled to headings - instead redirected to page root #78

Open Victor239 opened 7 months ago

Victor239 commented 7 months ago

See this video:

https://github.com/sethyuan/logseq-plugin-tocgen/assets/12621257/a671bd23-91d5-46ea-8133-9f41e8fa34d7

Same video also available here: https://streamable.com/vz3ggc

sethyuan commented 6 months ago

Are you using Logseq v0.10.7+? I think they changed the behavior of the related plugin API in the new versions. Unfortunately I'm been busy recently and I have no time to look into it.

Victor239 commented 6 months ago

I'm currently using v0.10.4.

sethyuan commented 6 months ago

Oh I see what's happening here. The "arrow go to" goes to the page the block is on and tries to locate the block, but the block in page "PC" is collapsed, hence not loaded by Logseq and there is no automatic loading behavior in the current Logseq API.

You may add a propose for this feature to the Logseq team. I believe it was mentioned several times before.

Victor239 commented 6 months ago

Sure I can do, but I'm not sure how to describe what the exact issue is as I don't know how this plugin works.

Is "add an API to scroll down a page to a referenced block" appropriate?

eiger3970 commented 6 months ago

Me too, Logseq 0.10.7, selecting the TOC opens the block and doesn't scroll down to the header.

queeup commented 2 months ago

Are you going to look at this? I am also having trouble with this. Logseq 0.10.9