添加多说评论系统

feature/cover-image
nodejh 8 years ago
parent aa9e7bdd0e
commit 753648ed2d

1
.gitignore vendored

@ -1,2 +1 @@
.DS_Store
CHANGELOG.md

@ -6,7 +6,7 @@
<article class="post">
<header>
<h1>
{{ if .Site.Params.useDescriptionAsTitle }}
{{ if .Site.Params.useDescriptionAsTitle }}
{{ .Description }}
{{ else }}
{{ .Title }}
@ -40,6 +40,10 @@
{{ partial "disqus.html" . }}
{{ end }}
{{ if .Site.Params.enableDuoshuo }}
{{ partial "duoshuo.html" . }}
{{ end }}
{{ partial "footer.html" . }}
</section>

@ -0,0 +1,18 @@
<!-- 多说评论框 start -->
<div class="ds-thread" data-thread-key="{{ .Permalink }}" data-title="{{ .Title }}" data-url="{{ .Permalink }}"></div>
<!-- 多说评论框 end -->
<!-- 多说公共JS代码 start (一个网页只需插入一次) -->
<script type="text/javascript">
var short_name = '{{ .Site.Params.duoshuoShortname }}';
var duoshuoQuery = {short_name: short_name };
(function() {
var ds = document.createElement('script');
ds.type = 'text/javascript';ds.async = true;
ds.src = (document.location.protocol == 'https:' ? 'https:' : 'http:') + '//static.duoshuo.com/embed.js';
ds.charset = 'UTF-8';
(document.getElementsByTagName('head')[0]
|| document.getElementsByTagName('body')[0]).appendChild(ds);
})();
</script>
<!-- 多说公共JS代码 end -->

@ -721,7 +721,7 @@ h2.month {
font: 300 16px/1.6 "Helvetica Neue", helvetica, Arial, sans-serif;
}
#disqus_thread {
#disqus_thread, #ds-thread {
margin-top: 100px;
}

Loading…
Cancel
Save