From 8ac540c65be97263dcd4e85f936487af983a2504 Mon Sep 17 00:00:00 2001 From: lkddi Date: Fri, 27 Feb 2026 16:06:15 +0800 Subject: [PATCH] =?UTF-8?q?=E9=87=8D=E6=9E=84=EF=BC=9A=E5=95=86=E5=BA=97?= =?UTF-8?q?=E4=BB=8E=E5=8F=B3=E4=BE=A7=20Tab=20=E7=A7=BB=E8=87=B3=E5=B7=A5?= =?UTF-8?q?=E5=85=B7=E6=A0=8F=E6=8C=89=E9=92=AE=E5=BC=B9=E7=AA=97=EF=BC=8C?= =?UTF-8?q?=E6=96=B0=E5=A2=9E=202=20=E5=88=97=E7=BD=91=E6=A0=BC=E5=8D=A1?= =?UTF-8?q?=E7=89=87=E5=B8=83=E5=B1=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../views/chat/partials/right-panel.blade.php | 8 +- .../views/chat/partials/scripts.blade.php | 9 +- .../views/chat/partials/toolbar.blade.php | 537 +++++++++++++++++- 3 files changed, 537 insertions(+), 17 deletions(-) diff --git a/resources/views/chat/partials/right-panel.blade.php b/resources/views/chat/partials/right-panel.blade.php index efb6d5e..1333d50 100644 --- a/resources/views/chat/partials/right-panel.blade.php +++ b/resources/views/chat/partials/right-panel.blade.php @@ -5,15 +5,12 @@ 依赖变量:$room(当前房间模型) --}} -
+
{{-- Tab 标题栏 --}}
- -
{{-- 用户列表面板 --}} @@ -90,7 +87,4 @@
在线: 0
- - {{-- 商店面板(位于最后,默认隐藏) --}} - @include('chat.partials.shop-panel')
diff --git a/resources/views/chat/partials/scripts.blade.php b/resources/views/chat/partials/scripts.blade.php index c0bd9fc..b30bc8e 100644 --- a/resources/views/chat/partials/scripts.blade.php +++ b/resources/views/chat/partials/scripts.blade.php @@ -27,18 +27,11 @@ // ── Tab 切换 ────────────────────────────────────── function switchTab(tab) { - // 所有内容面板(名单/房间/贴图/酷库 用 block,商店用 flex absolute 覆盖) + // 切换名单/房间/贴图/酷库 面板 ['users', 'rooms', 'emoji', 'action'].forEach(t => { document.getElementById('panel-' + t).style.display = t === tab ? 'block' : 'none'; document.getElementById('tab-' + t).classList.toggle('active', t === tab); }); - // 商店面板:absolute 定位覆盖,display flex/none 切换 - const shopPanel = document.getElementById('shop-panel'); - const shopTab = document.getElementById('tab-shop'); - if (shopPanel && shopTab) { - shopPanel.style.display = tab === 'shop' ? 'flex' : 'none'; - shopTab.classList.toggle('active', tab === 'shop'); - } // 贴图 Tab 懒加载 if (tab === 'emoji') { document.querySelectorAll('#panel-emoji img[data-src]').forEach(img => { diff --git a/resources/views/chat/partials/toolbar.blade.php b/resources/views/chat/partials/toolbar.blade.php index 86b7158..86c2540 100644 --- a/resources/views/chat/partials/toolbar.blade.php +++ b/resources/views/chat/partials/toolbar.blade.php @@ -5,7 +5,8 @@ 1. 工具条按钮(管理、商店、存点、头像、设置等) 2. 头像选择弹窗 3. 个人设置弹窗(密码、资料、密保) - 4. 对应的 JS 操作函数 + 4. 商店弹窗(从工具栏点击打开的全屏模态) + 5. 对应的 JS 操作函数 依赖变量:$user, $superLevel, $room @author ChatRoom Laravel @@ -14,7 +15,7 @@ {{-- ═══════════ 竖向工具条按钮 ═══════════ --}}
-
商店
+
🛍商店
存点
娱乐
银行
@@ -313,3 +314,535 @@ } } + +{{-- ═══════════ 商店弹窗 ═══════════ --}} + + +
+
+ + {{-- 标题栏 --}} +
+
🛍 道具商店
+
🪙 -- 金币
+ + +
+ + {{-- Toast --}} +
+ + {{-- 商品网格 --}} +
+
加载中…
+
+ + {{-- 改名内嵌遮罩 --}} +
+
+

🎭 使用改名卡

+ +
+ + +
+
+
+
+
+
+ +