💄 Support more of analytics engine such as baidu, google, busuanzi and so on, then add new web information widget. close #19

This commit is contained in:
凡梦星尘
2022-09-11 18:33:41 +08:00
parent c38a439171
commit 2a7fd9f8fb
21 changed files with 197 additions and 86 deletions

View File

@@ -1,12 +1,12 @@
{{- $pageViewCls := "" }}
{{- $pageViewId := "" }}
{{- if .Site.Params.leancloudVisitors.enable }}
{{- $pageViewCls = "leancloud-visitors-count" }}
{{- $pageViewId = "leancloud-visitors-count" }}
{{- end }}
{{- if .Site.Params.waline.pageView }}
{{- $pageViewCls = "waline-pageview-count" }}
{{- $pageViewId = "waline-pageview-count" }}
{{- end }}
{{- if .Site.Params.busuanzi.postViews }}
{{- $pageViewCls = "busuanzi_value_page_pv" }}
{{- if .Site.Params.analytics.busuanzi.postViews }}
{{- $pageViewId = "busuanzi_value_page_pv" }}
{{- end }}
<span class="post-meta-item" title="{{ T "PostViews" }}">
<span class="post-meta-item-icon">
@@ -15,5 +15,5 @@
<span class="post-meta-item-text">
{{ print (T "PostViews") (T "SymbolColon") }}
</span>
<span class="{{ $pageViewCls }}" data-path="{{ .RelPermalink | relLangURL }}"><i class="fa fa-sync fa-spin"></i></span>
<span id="{{ $pageViewId }}" data-path="{{ .RelPermalink | relLangURL }}"><i class="fa fa-sync fa-spin"></i></span>
</span>