This commit is contained in:
2025-12-01 00:53:29 +08:00
parent 3afa6a3153
commit fa660200fd
2 changed files with 17 additions and 3 deletions

View File

@@ -41,6 +41,9 @@
init()
}
// 手动触发入口,便于在需要时重新初始化
window.runTwikooComments = onLoad
if (document.readyState === 'complete') {
onLoad()
} else {

View File

@@ -1,6 +1,17 @@
<p class="text-xs uppercase text-muted-foreground">comment</p>
<h3 class="text-xl font-semibold mb-3">留言 / 评论</h3>
<div id="tcomment"></div>
<p class="text-xs uppercase text-muted-foreground">comment</p>
<h3 class="text-xl font-semibold mb-3">留言 / 评论</h3>
<div id="tcomment" class="space-y-2">
<p class="text-sm text-muted-foreground">
如果暂时没有看到评论,请点击下方按钮重新加载。
</p>
<button
type="button"
class="inline-flex items-center justify-center rounded-md border border-input bg-background px-3 py-1.5 text-sm font-medium shadow-sm transition-colors hover:bg-accent hover:text-accent-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2"
onclick="window.runTwikooComments && window.runTwikooComments()"
>
重新加载评论
</button>
</div>
<script src="/js/twikoo-loader.js" defer></script>