diff --git a/resources/views/chat/frame.blade.php b/resources/views/chat/frame.blade.php index 3efa48b..749d2df 100644 --- a/resources/views/chat/frame.blade.php +++ b/resources/views/chat/frame.blade.php @@ -91,282 +91,6 @@ @include('chat.partials.right-panel') - {{-- ═══════════ 用户名片弹窗 (Alpine.js) ═══════════ --}} -
- -
- {{-- ═══════════ 聊天室交互脚本(独立文件维护) ═══════════ --}} @include('chat.partials.user-actions') @include('chat.partials.scripts') @@ -392,8 +116,7 @@ 当前选中: - {{ $user->usersf ?: '未设置' }} + {{ $user->usersf ?: '未设置' }} diff --git a/resources/views/chat/partials/user-actions.blade.php b/resources/views/chat/partials/user-actions.blade.php index 9d20dc2..9e344b5 100644 --- a/resources/views/chat/partials/user-actions.blade.php +++ b/resources/views/chat/partials/user-actions.blade.php @@ -1,12 +1,18 @@ {{-- - 文件功能:用户交互全局函数(单击选择目标、双击打开名片弹窗) + 文件功能:用户交互全局函数 + 名片弹窗组件 - 聊天消息区和右侧用户列表统一调用此文件中的函数。 - 从 scripts.blade.php 中抽取,保持代码职责清晰。 + 包含: + 1. switchTarget() — 单击用户名切换聊天目标 + 2. openUserCard() — 双击用户名打开名片弹窗 + 3. 用户名片弹窗 Alpine.js 组件(资料查看 + 管理操作) + + 从 scripts.blade.php 和 frame.blade.php 中抽取,保持代码职责清晰。 @author ChatRoom Laravel @version 1.0.0 --}} + +{{-- ═══════════ 全局交互函数 ═══════════ --}} + +{{-- ═══════════ 用户名片弹窗 (Alpine.js) ═══════════ --}} +
+ +