commit
c43c5746ac
@ -51,9 +51,7 @@
|
||||
{{- end }}
|
||||
</footer>
|
||||
|
||||
{{- if (.Param "comments") }}
|
||||
{{- partial "comments.html" . }}
|
||||
{{- end }}
|
||||
</article>
|
||||
|
||||
{{- end }}{{/* end main */}}
|
||||
|
@ -1,3 +1,17 @@
|
||||
{{- /* Comments area start */ -}}
|
||||
{{- /* to add comments read => https://gohugo.io/content-management/comments/ */ -}}
|
||||
<div id="gitalk-container"></div>
|
||||
<script>
|
||||
const gitalk = new Gitalk({
|
||||
clientID: '402f41759b3537b6c752',
|
||||
clientSecret: 'd9558424431bfc3ee18d4b6c6ce7594ef682a701',
|
||||
repo: 'liuchang0812.github.io', // The repository of store comments,
|
||||
owner: 'liuchang0812',
|
||||
admin: ['liuchang0812'],
|
||||
id: location.pathname, // Ensure uniqueness and length less than 50
|
||||
distractionFreeMode: false // Facebook-like distraction free mode
|
||||
})
|
||||
|
||||
gitalk.render('gitalk-container')
|
||||
</script>
|
||||
{{- /* Comments area end */ -}}
|
||||
|
@ -115,6 +115,9 @@
|
||||
<link rel="alternate" hreflang="{{ .Lang }}" href="{{ .Permalink }}" />
|
||||
{{ end -}}
|
||||
|
||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/gitalk@1/dist/gitalk.css">
|
||||
<script src="https://cdn.jsdelivr.net/npm/gitalk@1/dist/gitalk.min.js"></script>
|
||||
|
||||
<noscript>
|
||||
<style>
|
||||
#theme-toggle,
|
||||
|
Loading…
x
Reference in New Issue
Block a user