perf(busuanzi): 支持关闭或隐藏卜算子,#81

This commit is contained in:
nineya 2024-01-02 19:24:32 +08:00
parent 15aa09c862
commit 753f34e6c7
3 changed files with 5 additions and 2 deletions

View File

@ -1077,9 +1077,12 @@ spec:
name: enable_busuanzi
label: 开启 busuanzi 访客统计
value: true
help: '隐藏时不显示统计信息,但依旧会请求 busuanzi 统计访客信息。'
options:
- value: true
label: 开启
- value: hide
label: 隐藏
- value: false
label: 关闭
- $formkit: radio

View File

@ -18,7 +18,7 @@
th:text="${theme.config.basic_info.record_number}"></a><span class="footer-truncation">Powered by <a class="powered" href="https://halo.run/" target="_blank">Halo</a> & <a class="powered" href="https://github.com/nineya/halo-theme-dream2.0" target="_blank">Dream</a></span></p>
<p class="icon-spot" th:if="${!#strings.isEmpty(theme.config.basic_info.website_time) || theme.config.enhance.enable_busuanzi}">
<span th:if="${!#strings.isEmpty(theme.config.basic_info.website_time)}" id="websiteDate">建站<span class="stand">00</span><span class="stand">0</span><span class="stand">0</span><span class="stand">0</span></span>
<span th:if="${theme.config.enhance.enable_busuanzi}" class="icon-spot footer-truncation">
<span th:if="${theme.config.enhance.enable_busuanzi == true}" class="icon-spot footer-truncation">
<span id="busuanzi_container_site_uv" style="display: none">
<i class="ri-account-circle-line" aria-hidden="true"></i><span class="stand" id="busuanzi_value_site_uv">0</span>访客
</span>

View File

@ -27,7 +27,7 @@
<script th:if="${isPost == true || isPhotos == true}" data-pjax async th:src="@{/assets/lib/fancybox@5.3.7/jquery.fancybox.min.js}"></script>
<script async src="https://busuanzi.ibruce.info/busuanzi/2.3/busuanzi.pure.mini.js"></script>
<script th:if="${theme.config.enhance.enable_busuanzi != false}" async src="https://busuanzi.ibruce.info/busuanzi/2.3/busuanzi.pure.mini.js"></script>
[(${theme.config.custom.external_js_body})]
<script th:if="${!#strings.isEmpty(theme.config.custom.inline_js_body)}" type="text/javascript" th:utext="${theme.config.custom.inline_js_body}">