This commit is contained in:
George 2024-12-19 11:52:26 -03:00 committed by GitHub
parent c5101beae4
commit cc0cb3c426
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1,20 +1,18 @@
{% if site.wechat_qr %} <!-- WeChat Modal -->
<!-- WeChat Modal -->
<script> <script>
var wechatModal = document.getElementById('WeChatMod'); var wechatModal = document.getElementById('WeChatMod');
var wechatBtn = document.querySelectorAll('[id="WeChatBtn"]'); var wechatBtn = document.querySelectorAll('[id="WeChatBtn"]');
for (var i = 0; i < wechatBtn.length; i++) { for (var i = 0; i < wechatBtn.length; i++) {
wechatBtn[i].onclick = function () { wechatBtn[i].onclick = function () {
wechatModal.style.display = 'block'; wechatModal.style.display = 'block';
};
}
window.onclick = function (event) {
if (event.target == wechatModal) {
wechatModal.style.display = 'none';
}
}; };
</script> }
{% endif %}
window.onclick = function (event) {
if (event.target == wechatModal) {
wechatModal.style.display = 'none';
}
};
</script>