Skip to content

Commit 9c81d49

Browse files
committed
add: hidden tg widget
1 parent ff7b35a commit 9c81d49

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

layouts/index.html

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,16 @@
33
<!-- Welcome contents -->
44
{{ .Content }}
55

6+
<!-- Telegram Widget -->
7+
<!-- <h2>Latest Reading</h2> -->
8+
<!-- <script id="telegram_post" async src="https://telegram.org/js/telegram-widget.js?22" data-telegram-post="wsine_channel/2" data-width="100%" data-userpic="false" data-dark="0"></script> -->
9+
<!-- <script> -->
10+
<!-- const prefersDarkMode = window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches; -->
11+
<!-- if (prefersDarkMode) { -->
12+
<!-- document.getElementById('telegram_post').setAttribute('data-dark', '1'); -->
13+
<!-- } -->
14+
<!-- </script> -->
15+
616
<!-- Blog contents -->
717
<h2>Latest Articles</h2>
818
<ul>

0 commit comments

Comments
 (0)