1
0
Fork 0
mirror of https://github.com/dillonzq/LoveIt.git synced 2025-04-16 02:30:44 +02:00

inline telegram script

This commit is contained in:
Matt Esch 2020-06-24 11:49:51 +01:00
parent f787a4e5ad
commit 01de8bace7

View file

@ -77,7 +77,7 @@
{{- /* Telegram Comments System */ -}}
{{- $telegram := $comment.telegram | default dict -}}
{{- if $telegram.enable -}}
<div id="telegram-comments" class="comment"></div>
<div id="telegram-comments" class="comment">
{{- $attr := printf `data-comments-app-website="%v"` $telegram.siteID -}}
{{- $attr = printf `%v data-limit="%v"` $attr ($telegram.limit | default 5) -}}
{{- with $telegram.height -}}
@ -95,10 +95,11 @@
{{- if $telegram.outlined -}}
{{- $attr = printf `%v data-outlined="1"` $attr -}}
{{- end -}}
{{- dict "Source" "https://comments.app/js/widget.js?2" "Defer" true "Attr" $attr | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
<script type="text/javascript" src="https://comments.app/js/widget.js?3" {{ with $attr }} {{ . | safeHTMLAttr }}{{ end }}></script>
<noscript>
Please enable JavaScript to view the comments powered by <a href="https://comments.app/">Telegram Comments</a>.
</noscript>
</div>
{{- end -}}
{{- /* Commento Comment System */ -}}