Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Headings with numbers makes the TOC on the right panel fail to expand. #774

Closed
3 tasks done
sirlis opened this issue Nov 30, 2022 · 4 comments
Closed
3 tasks done

Comments

@sirlis
Copy link

sirlis commented Nov 30, 2022

Checklist

  • I have read the tutorials and know the correct effect of the functional design.
  • There are no similar reports on existing issues (including closed ones).
  • I found the bug on the latest code of the master branch.

Describe the bug

Adding numbers to each level of headings makes the TOC on the right fail to expand.

To Reproduce

Steps to reproduce the behavior:

  1. new a markdown file 111.md and write contents with headings like:
    ## 1. A
    
    contents ....
    
    ## 2. B
    
    contents ....
    
    ### 2.1. BB
    
    contents ....
    
    ### 2.2. BBB
    
    contents ....
    
    ## 3. C
    
  2. See error

The automatically generated TOC on the right panel won't expand to the 2nd level correctly.

Expected behavior

The TOC expanded as expected.

Screenshots

examples link: http://sirlis.cn/posts/reinforcement-learning-Monte-Carlo/

In fact, almost all posts of the blog cannot experience a auto-expanded TOC.

Environment

Command Version
chrispy latest

Desktop

  • OS: windows 11
  • Browser: Edge latest version

Smartphone

Additional context

@github-actions
Copy link

👋 Hi @sirlis,

This issue is being automatically closed because it does not follow the issue template. Please DO NOT open another similar issue, try to edit the current issue according to the template, then it will be reopened automatically.

@NichtsHsu
Copy link
Contributor

See #572 and afeld/bootstrap-toc#64

@sirlis
Copy link
Author

sirlis commented Nov 30, 2022

See #572 and afeld/bootstrap-toc#64

Thank you.

@sirlis sirlis closed this as completed Nov 30, 2022
@sirlis
Copy link
Author

sirlis commented Nov 30, 2022

Since bootstrap-toc is no longer maintained, I wonder if it is possible for the developer to update Chrispy by using Tocbot.

@sirlis sirlis reopened this Nov 30, 2022
cotes2020 added a commit that referenced this issue Mar 15, 2023
nabin-nath added a commit to nabin-nath/nabin-nath.github.io that referenced this issue Mar 29, 2023
* chore(deps): upgrade NPM packages

* chore: update code style config

* refactor(build): modularize JS code

- replace gulp with rollup
- remove JS output from repo

* chore(ci,tools): adapt to changes in JS builds

* chore: update configure-pages action (cotes2020#931)

* feat: change TOC plugin to `tocbot` (cotes2020#774)

* style: improve code style of SCSS & YAML

* fix: notch status bar doesn't match theme color (cotes2020#918)

Resolves cotes2020#918

* refactor: remove version number from self host config

* fix: some console snippets will be incompletely copied

Sample:

```console
echo $PATH
```

* style: fix scss lint issue

type: declaration-block-no-redundant-longhand-properties

* feat(ux): turn home page posts into clickable cards (cotes2020#895)

Resolves cotes2020#895

* chore: recover accidentally deleted LQIP style

* chore(tools): resume git checkout in initialization

* chore(tools): add JS dist to gem release

* docs: migrate upgrade details to the wiki

* chore(release): 5.6.0

* wip

* fix: mode-toggle leads to Disqus loading failure (cotes2020#945)

* search fix

* wip

---------

Co-authored-by: Cotes Chung <11371340+cotes2020@users.noreply.github.com>
Co-authored-by: Josh Johanning <joshjohanning@github.com>
Co-authored-by: Song-Zi Vong <v4vong@gmail.com>
gudtldn pushed a commit to gudtldn/gudtldn.github.io that referenced this issue Jul 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants