diff --git a/resources/views/chat/partials/games/baccarat-panel.blade.php b/resources/views/chat/partials/games/baccarat-panel.blade.php
index e86c485..f710992 100644
--- a/resources/views/chat/partials/games/baccarat-panel.blade.php
+++ b/resources/views/chat/partials/games/baccarat-panel.blade.php
@@ -276,13 +276,16 @@
{{-- 底部关闭 --}}
+ style="background:#fff; border-top:1px solid #d0e4f5; padding:12px 16px; display:flex; flex-direction:column; align-items:center; gap:6px;">
+ {{-- 结算后显示自动关闭倒计时 --}}
+
@@ -427,6 +430,10 @@
// 历史记录
history: [],
+ // 结算后定时自动关闭
+ autoCloseTimer: null,
+ autoCloseCountdown: 0,
+
/**
* 开局:填充局次数据并开始倒计时
*/
@@ -545,6 +552,17 @@
this.updateFab(false);
this.loadHistory();
+
+ // 结算后 10 秒自动关闭
+ this.autoCloseCountdown = 10;
+ clearInterval(this.autoCloseTimer);
+ this.autoCloseTimer = setInterval(() => {
+ this.autoCloseCountdown--;
+ if (this.autoCloseCountdown <= 0) {
+ clearInterval(this.autoCloseTimer);
+ this.close();
+ }
+ }, 1000);
},
/**
@@ -570,6 +588,9 @@
* 关闭面板
*/
close() {
+ // 手动关闭时清除自动关闭定时器
+ clearInterval(this.autoCloseTimer);
+ this.autoCloseCountdown = 0;
this.show = false;
if (this.phase === 'betting') {
this.updateFab(true); // 还在下注阶段时保留悬浮按钮