mirror of
https://github.com/xinnan-tech/xiaozhi-esp32-server.git
synced 2026-11-24 04:19:48 +01:00
fix: 修复点击用户框无法关闭菜单问题
This commit is contained in:
parent
ea8001a9c8
commit
f68fc5c90d
1 changed files with 7 additions and 1 deletions
|
|
@ -210,6 +210,7 @@ export default {
|
|||
paramDropdownVisible: false,
|
||||
voiceCloneDropdownVisible: false,
|
||||
userMenuVisible: false, // 添加用户菜单可见状态
|
||||
menuVisibleTimer: null, // 菜单显示定时器,防止够快触发
|
||||
isSmallScreen: false,
|
||||
// 搜索历史相关
|
||||
searchHistory: [],
|
||||
|
|
@ -631,7 +632,12 @@ export default {
|
|||
|
||||
// 处理用户菜单可见性变化
|
||||
handleUserMenuVisibleChange(visible) {
|
||||
this.userMenuVisible = visible;
|
||||
if (this.menuVisibleTimer) return;
|
||||
this.menuVisibleTimer = setTimeout(() => {
|
||||
this.userMenuVisible = visible;
|
||||
clearTimeout(this.menuVisibleTimer);
|
||||
this.menuVisibleTimer = null;
|
||||
}, 100);
|
||||
|
||||
// 如果菜单关闭了,也要清空选择值
|
||||
if (!visible) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue