diff --git a/layout/includes/comments/disqus.pug b/layout/includes/comments/disqus.pug index 9795671..a1bd151 100644 --- a/layout/includes/comments/disqus.pug +++ b/layout/includes/comments/disqus.pug @@ -10,6 +10,4 @@ if theme.disqus.enable var d = document, s = d.createElement('script'); s.src = "https://" + '!{theme.disqus.shortname}' +".disqus.com/embed.js"; s.setAttribute('data-timestamp', '' + +new Date()); - (d.head || d.body).appendChild(s); - if theme.disqus.count - script#dsq-count-scr(src="https://" + theme.disqus.shortname + ".disqus.com/count.js" async) \ No newline at end of file + (d.head || d.body).appendChild(s); \ No newline at end of file diff --git a/layout/includes/comments/gitalk.pug b/layout/includes/comments/gitalk.pug index 4315187..e222491 100644 --- a/layout/includes/comments/gitalk.pug +++ b/layout/includes/comments/gitalk.pug @@ -1,13 +1,13 @@ -if theme.gitment && theme.gitment.enable - #gitment-container +if theme.gitalk && theme.gitalk.enable + #gitalk-container script. - var gitment = new Gitment({ + var gitalk = new Gitalk({ + clientID: '!{theme.gitalk.client_id}', + clientSecret: '!{theme.gitalk.client_secret}', + repo: '!{theme.gitalk.repo}', + owner: '!{theme.gitalk.owner}', + admin: '!{theme.gitalk.admin}', id: md5(decodeURI(location.pathname)), - owner: '!{theme.gitment.owner}', - repo: '!{theme.gitment.repo}', - oauth: { - client_id: '!{theme.gitment.client_id}', - client_secret: '!{theme.gitment.client_secret}' - } + language: '!{lang}' }) - gitment.render('gitment-container') \ No newline at end of file + gitalk.render('gitalk-container') \ No newline at end of file diff --git a/layout/includes/comments/gitment.pug b/layout/includes/comments/gitment.pug index d3ee3d0..4315187 100644 --- a/layout/includes/comments/gitment.pug +++ b/layout/includes/comments/gitment.pug @@ -2,6 +2,7 @@ if theme.gitment && theme.gitment.enable #gitment-container script. var gitment = new Gitment({ + id: md5(decodeURI(location.pathname)), owner: '!{theme.gitment.owner}', repo: '!{theme.gitment.repo}', oauth: { diff --git a/layout/includes/comments/valine.pug b/layout/includes/comments/valine.pug index a4c2329..ec432d9 100644 --- a/layout/includes/comments/valine.pug +++ b/layout/includes/comments/valine.pug @@ -1,7 +1,6 @@ if theme.valine && theme.valine.enable #vcomment.vcomment - script(src='https://cdn.jsdelivr.net/npm/leancloud-storage/dist/av-min.js') - script(src='https://cdn.jsdelivr.net/npm/valine@v1.3.6/dist/Valine.min.js') + script(src='https://cdn.jsdelivr.net/npm/valine/dist/Valine.min.js') script. var notify = '#{ theme.valine.notify }' == true ? true : false; var verify = '#{ theme.valine.verify }' == true ? true : false; diff --git a/source/css/_global/index.styl b/source/css/_global/index.styl index 0a95e5e..164171c 100644 --- a/source/css/_global/index.styl +++ b/source/css/_global/index.styl @@ -148,7 +148,9 @@ table // valine -#vcomment +#vcomment + font-size: inherit + input font-size: 0.65rem @@ -165,9 +167,6 @@ table .info display: none - - .vcomment - margin-top: 20px .vimg border: 0