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

No indenting and side bar over populates #79

Closed eiger3970 closed 6 months ago

eiger3970 commented 6 months ago
  1. The TOC picks up the headers in the text, however headers are not indented. For example, H1 is left on margin, H2 is 2or4 spaces right of margin, H3 is 4or8 spaces right of margin and so on. Screenshot from 2024-03-22 20-42-02

  2. The TOC side bar on the right populates the TOC when open. However when I close the side bar and reopen it, the TOC is there plus an additional copy of the TOC. The side bar continues to add more and more dupliate TOCs when I close and open the side bar. Screenshot from 2024-03-22 20-43-58

  3. I would suggest some clear and easy instructions for a newly installed TOC plugin for users, as setup is unintuitive. For example:

    CLI:

    Linux Mint 21.3 Virginia Cinnamon 64-bit -> Logseq 0.10.7 -> new Page (doesn't work in Journal) -> create content with headers -> move cursor to left of top line -> enter / -> select up or down arrow -> move to Table of Contents -> select Enter -> {{renderer:tocgen2}} -> select Enter -> ToC appears above content -> headers show, but no indenting.

    GUI:

    Logseq 0.10.7 -> select Open TOC (icon, near top right) -> right side bar opens -> shows all pages and their ToCs. Buggy: if opening and closing each time, a new page with ToCs appears in side bar?

eiger3970 commented 6 months ago

The TOC Q1 seems solved. My noob misunderstanding on Tab and Shift Tab and how to connect these to appropriate headers seems to be figuring out how TOC works.

eiger3970 commented 5 months ago

Another error appears when in Desktop -> Logseq 0.10.8 -> Page -> selecting the ToC icon at the top -> right column opens -> ToC appears -> [Page/Block not found!]. What is this error? Screenshot from 2024-04-22 14-36-50

eiger3970 commented 5 months ago

Another error is, when closing the ToC right column and then selecting the ToC icon at the top, the ToC opens correctly on the right column, however duplicates the ToC. I usually delete this, otherwise, this duplication builds up with a 3rd, a 4th and so on each time the ToC is opened.