-
Notifications
You must be signed in to change notification settings - Fork 102
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
How to encrypt TOC under NexT theme #58
Comments
10/18/2018 10/19/2018 |
Cool~ |
更新一下 这个文件: 这一行 {%- set toc = toc(page.content, {class: 'nav', list_number: page.toc.number, max_depth: page.toc.max_depth}) %} 修改为 {%- if page.encrypt == true %}
{%- set toc = toc(page.origin, {class: 'nav', list_number: page.toc.number, max_depth: page.toc.max_depth}) %}
{% else %}
{%- set toc = toc(page.content, {class: 'nav', list_number: page.toc.number, max_depth: page.toc.max_depth}) %}
{%- endif %} 其实原理就是: 如果加密了,生成目录 |
Closed
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It is said that TOC can be encrypted in
themes/next/layout/_macro/sidebar.swig
.However, after I used another one's code hexo博文加密 , there is some bug in the TOC of encrypted article.
I want the presentation like this Hexo Blog Encrypt . How can I make it?
The text was updated successfully, but these errors were encountered: