迁移聊天室前端工具并优化消息渲染

This commit is contained in:
2026-04-25 03:34:31 +08:00
parent e3cba255f9
commit f1d8d20180
12 changed files with 786 additions and 154 deletions
@@ -1420,8 +1420,8 @@
}
// ── 页面刷新后恢复婚礼红包领取按钮 ─────────────────────────
// 延迟 2 秒以确保聊天框和 Alpine 均已完成初始化
setTimeout(async () => {
// 空闲时再查待领取红包,避免和聊天室首屏消息/名单初始化抢网络。
window.deferChatGameBootstrap(async () => {
try {
const res = await fetch('/wedding/pending-envelopes', {
headers: {
@@ -1467,6 +1467,6 @@
} catch (e) {
console.warn('[婚礼红包] 恢复待领取按钮失败', e);
}
}, 2000);
}, 3000);
});
</script>