diff --git a/_config.yml b/_config.yml index 431be4a..d4dcfea 100644 --- a/_config.yml +++ b/_config.yml @@ -85,3 +85,10 @@ toc: expand_all: false # Maximum heading depth of generated toc. max_depth: 6 + +# magic theme style +magic: + enable: true + sidebar: + enable: false + position: right diff --git a/layout/_partial/comments/valine.ejs b/layout/_partial/comments/valine.ejs index b1271d4..6400c6d 100755 --- a/layout/_partial/comments/valine.ejs +++ b/layout/_partial/comments/valine.ejs @@ -11,7 +11,6 @@ el: '#vcomments', appId: '<%= theme.comments.valine.appid %>', appKey: '<%= theme.comments.valine.appkey %>', - meta: '<%= theme.comments.valine.meta %>', avatar: 'wavatar', enableQQ: true, placeholder: '<%= theme.comments.valine.placeholder %>', diff --git a/layout/_partial/scripts.ejs b/layout/_partial/scripts.ejs index c0ef198..e453e88 100644 --- a/layout/_partial/scripts.ejs +++ b/layout/_partial/scripts.ejs @@ -11,7 +11,7 @@ <%- js('js/code-copy.js') %> <% } %> - <% if (theme.toc.enable) { %> + <% if (theme.toc.enable && theme.magic.enable && theme.magic.sidebar.enable) { %> <%- js(['lib/anime.min.js', 'js/toc.js']) %> <% } %> diff --git a/layout/_partial/sidebar-category.ejs b/layout/_partial/sidebar-category.ejs new file mode 100644 index 0000000..8c55477 --- /dev/null +++ b/layout/_partial/sidebar-category.ejs @@ -0,0 +1,25 @@ +