-
Notifications
You must be signed in to change notification settings - Fork 652
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
right-side navbar Unable to locate in Chinese mode #170
Comments
When you click on the Chinese Catalogue on the right,Unable to locate intermediate specific fragments。It jumps to the top of the page。 @choldgraf |
Ah interesting - I see what you mean. I'm not sure why that happens, unfortunately :-( I've never worked with Chinese characters before. I'd guess maybe it is a UTF-8 encoding problem? Would love some help figuring out a fix for this one if somebody has an idea. |
At the same time,I am also looking for this problem。Thank you for your attention。 |
I found this fragment in the \jupyter_book\book_template_includes\onthispage.html {% assign toc_items = my_toc | split: '#' %} {{ page.toc_label | default: site.data.ui-text[site.locale].toc_label }}{{ my_toc | markdownify | strip }} {% endif %}I guess this line |
I'm happy to review PRs that give a shot at fixing this, I'd love for Jupyter Book to support chinese characters |
tks for your help. and another multi-language support problem when a md or ipynb file include chinese charset was built or create. |
@choldgraf I have done a lot of experiments and found that the anchor itself is not a problem, but there is a little hit, but I do not know where to capture this incident, can you help me look at it? Thank you |
Hmmm - could you describe what the issue seems to be? I don't have a ton of time to devote to this particular issue right now, but if you post information then hopefully folks in the community could help out (and I can help as I have the cycles) |
I found that the root of the problem is that this anchor. JS conflicts with its own anchor, but the library has only one |
So I had this same issue with Cyrrilic TOC and anchors in my book. I dig a bit and found that there are, basically, 3 different problems:
forEach.call(tocLis, function (tocLi) {
tocLi.className = tocLi.className.split(SPACE_CHAR + options.activeListItemClass).join('')
}) (See here in the In case of an empty I set
The best solution is to add
I'll make a PR soon. |
Thanks for the analysis, and looking forward to a PR @GasperPaul ! |
@choldgraf Here's a PR. Hope this helps. If things work out and I have time I'll be glad to work on a few other issues too. |
https://fdango.github.io/bookT/intro.html#linux%E7%9A%84%E8%B5%B7%E6%BA%90,
I made a demo.
The text was updated successfully, but these errors were encountered: