Compare commits

...

3 Commits

Author SHA1 Message Date
85ecfc4c5b 新增文件点击,优化流式输出 2026-07-28 16:52:15 +08:00
c90600c66e //修改优先把消息加入列表 2026-07-27 18:01:32 +08:00
9bafcaed5d 修改wyxd居中和去内边距 2026-07-27 16:42:42 +08:00
5 changed files with 160 additions and 133 deletions

View File

@@ -41,8 +41,7 @@
<view class="chat-sidebar" :class="{'sidebar-show' : isChatSidebar}">
<ChatSidebar :chatList="UserConversations" v-model:showNewChatModal="showNewChatModal"
v-model:currentSessionId="currentSessionId" v-model:chatType="ChatType"
@refresh-conversations="takeUserConversations"
@select-chat="isChatSidebar = false">
@refresh-conversations="takeUserConversations" @select-chat="isChatSidebar = false">
</ChatSidebar>
</view>
@@ -67,7 +66,7 @@
</view>
<view class="main-chat">
<scroll-view class="chat-messages" direction="vertical" scroll-y :scroll-into-view="scrollToView"
:upper-threshold="0" :scroll-with-animation="true" @scroll="onScroll">
:upper-threshold="0" :scroll-with-animation="!isThinking" @scroll="onScroll">
<!-- 消息加载中弹窗仅会话变化时显示 -->
<view v-if="isLoadingMessages" class="messages-loading-overlay">
<view class="messages-loading-card">
@@ -211,6 +210,10 @@
</view>
</view>
<!-- 底部锚点两个交替切换确保流式时每次都能触发滚动到底部 -->
<!-- <view>
<view id="chat-bottom-a" style="height: 0rpx;width: 1rpx;"></view>
<view id="chat-bottom-b" style="height: 0rpx;width: 1rpx;"></view>
</view> -->
<view id="chat-bottom-a" style="height: 1rpx;"></view>
<view id="chat-bottom-b" style="height: 1rpx;"></view>
</scroll-view>
@@ -587,6 +590,7 @@
})
return
}
closeNewChatModal();
takeUserConversations();
} catch (error) {
@@ -938,6 +942,17 @@
}
// 发送好友消息
const sendFriendMessage = async () => {
const newMessageData = {
"sender": UserId.value,
"receiver": receiverId,
"content": textMessage.value,
"taskId": null,
"avatar": null,
"createTime": "",
"messageType": "null",
"contentJson": hasFiles ? JSON.stringify(uploadedFiles.value) : 'null'
}
allmessages.value = [...allmessages.value, newMessageData]
if (!friendSocketStore.isConnecting) await handleFriendConnect();
const receiverId = getReceiverId()
const hasFiles = uploadedFiles.value.length > 0
@@ -959,17 +974,17 @@
"body": body
}
friendSocketStore.send(data)
const newMessageData = {
"sender": UserId.value,
"receiver": receiverId,
"content": textMessage.value,
"taskId": null,
"avatar": null,
"createTime": "",
"messageType": "null",
"contentJson": hasFiles ? JSON.stringify(uploadedFiles.value) : 'null'
}
allmessages.value = [...allmessages.value, newMessageData]
// const newMessageData = {
// "sender": UserId.value,
// "receiver": receiverId,
// "content": textMessage.value,
// "taskId": null,
// "avatar": null,
// "createTime": "",
// "messageType": "null",
// "contentJson": hasFiles ? JSON.stringify(uploadedFiles.value) : 'null'
// }
// allmessages.value = [...allmessages.value, newMessageData]
textMessage.value = ''
uploadedFiles.value = []
setTimeout(() => {
@@ -979,6 +994,16 @@
// 发送群聊消息
const sendGroupMessage = async () => {
const newMessageData = {
"id": allmessages.value.length + 1,
"message": textMessage.value,
"messageType": hasFiles ? 1 : 0,
"groupId": null,
"createTime": '',
"contentJson": hasFiles ? JSON.stringify(uploadedFiles.value) : '',
"sender": UserId.value
}
allmessages.value = [...allmessages.value, newMessageData]
if (!friendSocketStore.isConnecting) await handleFriendConnect();
const hasFiles = uploadedFiles.value.length > 0
const body = {
@@ -997,57 +1022,37 @@
"body": body
}
friendSocketStore.send(data)
const newMessageData = {
"id": allmessages.value.length + 1,
"message": textMessage.value,
"messageType": hasFiles ? 1 : 0,
"groupId": null,
"createTime": '',
"contentJson": hasFiles ? JSON.stringify(uploadedFiles.value) : '',
"sender": UserId.value
}
allmessages.value = [...allmessages.value, newMessageData]
// const newMessageData = {
// "id": allmessages.value.length + 1,
// "message": textMessage.value,
// "messageType": hasFiles ? 1 : 0,
// "groupId": null,
// "createTime": '',
// "contentJson": hasFiles ? JSON.stringify(uploadedFiles.value) : '',
// "sender": UserId.value
// }
// allmessages.value = [...allmessages.value, newMessageData]
textMessage.value = ''
uploadedFiles.value = []
setTimeout(() => {
takeGroupMessages()
}, 1000)
}
// // 发送AI消息
// const sendAIMessage = async () => {
// try {
// handleConnect();
// let messageContent = textMessage.value
// if (uploadedFiles.value.length) {
// const fileJson = JSON.stringify(uploadedFiles.value)
// messageContent = messageContent ?
// `${messageContent}\n[文件信息:${fileJson}]` :
// `[文件信息:${fileJson}]`
// }
// const message_id = await addMessageDict(userToken.value, 'user', currentSessionId.value,
// messageContent)
// if (message_id) {
// textMessage.value = ''
// uploadedFiles.value = []
// isThinking.value = true
// }
// await waitForAIResponse();
// } catch (error) {
// isThinking.value = false
// uni.showToast({
// title: `用户发送消息失败${error}`,
// icon: 'error'
// })
// }
// }
// AI 回复超时定时器
// let aiResponseTimer = null
//修改优先把消息加入列表
// 发送AI消息
const sendAIMessage = async () => {
try {
await handleConnect();
let messageContent = textMessage.value
// 立即添加用户消息到列表(使用完整的 messageContent包含文件信息
allmessages.value = [...allmessages.value, {
role: 'user',
content: messageContent
}]
await handleConnect();
if (uploadedFiles.value.length) {
const fileJson = JSON.stringify(uploadedFiles.value)
messageContent = messageContent ?
@@ -1062,11 +1067,11 @@
socketStore.send(data)
isThinking.value = true
isSelfSent.value = true
// 立即添加用户消息到列表(使用完整的 messageContent包含文件信息
allmessages.value = [...allmessages.value, {
role: 'user',
content: messageContent
}]
// // 立即添加用户消息到列表(使用完整的 messageContent包含文件信息
// allmessages.value = [...allmessages.value, {
// role: 'user',
// content: messageContent
// }]
// 添加流式消息气泡(加载中状态)
streamingMessageId.value = 'streaming-' + Date.now()
allmessages.value = [...allmessages.value, {

View File

@@ -244,7 +244,7 @@ onLoad((options) => {
.wyxd-slide-area {
flex: 1;
min-height: 0;
padding: 20rpx;
/* padding: 20rpx; */
}
.wyxd-slide-scroll {
@@ -254,10 +254,18 @@ onLoad((options) => {
box-shadow: 0 2rpx 12rpx rgba(0, 0, 0, 0.04);
}
.wyxd-slide-card {
/* .wyxd-slide-card {
padding: 32rpx;
min-height: 100%;
box-sizing: border-box;
} */
.wyxd-slide-card {
min-height: 100%;
box-sizing: border-box;
display: flex;
justify-content: center;
align-items: center;
flex-direction: column; /* 子元素垂直排列 */
}
/* ===== 底部翻页 ===== */

View File

@@ -605,7 +605,10 @@
// 处理文件夹点击(非选择模式下进入文件夹,仅目录可点击进入)
const handleFolderClick = (folder) => {
if (folder.type !== 'directory') return;
if (folder.type !== 'directory') {
handleLongPress(folder)
return
}
folderStack.value.push({
path: folder.path,
name: folder.name

View File

@@ -5639,7 +5639,7 @@ This will fail in production.`);
if (friendSocketStore.isConnected)
return;
if (!userToken.value || !UserId.value) {
formatAppLog("warn", "at pages/Chat/Chat.vue:346", "Token或UserId未准备好");
formatAppLog("warn", "at pages/Chat/Chat.vue:349", "Token或UserId未准备好");
return;
}
friendSocketStore.connect({
@@ -5725,7 +5725,7 @@ This will fail in production.`);
);
return html;
} catch (e2) {
formatAppLog("error", "at pages/Chat/Chat.vue:472", "解析失败", e2);
formatAppLog("error", "at pages/Chat/Chat.vue:475", "解析失败", e2);
return content;
}
};
@@ -5784,7 +5784,7 @@ This will fail in production.`);
files
};
} catch (e2) {
formatAppLog("error", "at pages/Chat/Chat.vue:549", "解析文件信息失败:", e2);
formatAppLog("error", "at pages/Chat/Chat.vue:552", "解析文件信息失败:", e2);
return {
textContent: content,
files: []
@@ -5819,9 +5819,10 @@ This will fail in production.`);
});
return;
}
closeNewChatModal();
takeUserConversations();
} catch (error) {
formatAppLog("error", "at pages/Chat/Chat.vue:594", "新建普通会话失败:", error);
formatAppLog("error", "at pages/Chat/Chat.vue:598", "新建普通会话失败:", error);
uni.showToast({
title: "创建会话失败,请重试",
icon: "none"
@@ -5859,7 +5860,7 @@ This will fail in production.`);
};
const previewFileArray = vue.ref([]);
const uploadPhoto = () => {
formatAppLog("log", "at pages/Chat/Chat.vue:643", "点击了拍照上传");
formatAppLog("log", "at pages/Chat/Chat.vue:647", "点击了拍照上传");
uni.chooseImage({
count: 1,
sourceType: ["camera", "album"],
@@ -5882,7 +5883,7 @@ This will fail in production.`);
});
},
fail: (err) => {
formatAppLog("error", "at pages/Chat/Chat.vue:661", "选择图片失败", err);
formatAppLog("error", "at pages/Chat/Chat.vue:665", "选择图片失败", err);
}
});
};
@@ -5891,12 +5892,12 @@ This will fail in production.`);
};
const fileList = vue.ref([]);
const uploadFile = () => {
formatAppLog("log", "at pages/Chat/Chat.vue:672", "点击了上传文件");
formatAppLog("log", "at pages/Chat/Chat.vue:676", "点击了上传文件");
chooseFile({
count: 5,
type: "all",
success: (res) => {
formatAppLog("log", "at pages/Chat/Chat.vue:677", "成功了");
formatAppLog("log", "at pages/Chat/Chat.vue:681", "成功了");
fileList.value = res.tempFiles;
previewFileArray.value.push(...res.tempFiles);
uni.showToast({
@@ -5905,7 +5906,7 @@ This will fail in production.`);
});
},
fail: (err) => {
formatAppLog("error", "at pages/Chat/Chat.vue:688", "选择失败:", err);
formatAppLog("error", "at pages/Chat/Chat.vue:692", "选择失败:", err);
uni.showToast({
title: "选择失败",
icon: "error"
@@ -6107,7 +6108,7 @@ This will fail in production.`);
previewFileArray.value = [];
} catch (err) {
uni.hideLoading();
formatAppLog("error", "at pages/Chat/Chat.vue:923", "文件上传失败:", err);
formatAppLog("error", "at pages/Chat/Chat.vue:927", "文件上传失败:", err);
uni.showToast({
title: "文件上传失败,请重试",
icon: "error"
@@ -6126,6 +6127,17 @@ This will fail in production.`);
sendGroupMessage();
};
const sendFriendMessage = async () => {
const newMessageData = {
"sender": UserId.value,
"receiver": receiverId,
"content": textMessage.value,
"taskId": null,
"avatar": null,
"createTime": "",
"messageType": "null",
"contentJson": hasFiles ? JSON.stringify(uploadedFiles.value) : "null"
};
allmessages.value = [...allmessages.value, newMessageData];
if (!friendSocketStore.isConnecting)
await handleFriendConnect();
const receiverId = getReceiverId();
@@ -6148,17 +6160,6 @@ This will fail in production.`);
"body": body
};
friendSocketStore.send(data);
const newMessageData = {
"sender": UserId.value,
"receiver": receiverId,
"content": textMessage.value,
"taskId": null,
"avatar": null,
"createTime": "",
"messageType": "null",
"contentJson": hasFiles ? JSON.stringify(uploadedFiles.value) : "null"
};
allmessages.value = [...allmessages.value, newMessageData];
textMessage.value = "";
uploadedFiles.value = [];
setTimeout(() => {
@@ -6166,6 +6167,16 @@ This will fail in production.`);
}, 1e3);
};
const sendGroupMessage = async () => {
const newMessageData = {
"id": allmessages.value.length + 1,
"message": textMessage.value,
"messageType": hasFiles ? 1 : 0,
"groupId": null,
"createTime": "",
"contentJson": hasFiles ? JSON.stringify(uploadedFiles.value) : "",
"sender": UserId.value
};
allmessages.value = [...allmessages.value, newMessageData];
if (!friendSocketStore.isConnecting)
await handleFriendConnect();
const hasFiles = uploadedFiles.value.length > 0;
@@ -6185,16 +6196,6 @@ This will fail in production.`);
"body": body
};
friendSocketStore.send(data);
const newMessageData = {
"id": allmessages.value.length + 1,
"message": textMessage.value,
"messageType": hasFiles ? 1 : 0,
"groupId": null,
"createTime": "",
"contentJson": hasFiles ? JSON.stringify(uploadedFiles.value) : "",
"sender": UserId.value
};
allmessages.value = [...allmessages.value, newMessageData];
textMessage.value = "";
uploadedFiles.value = [];
setTimeout(() => {
@@ -6203,8 +6204,12 @@ This will fail in production.`);
};
const sendAIMessage = async () => {
try {
await handleConnect();
let messageContent = textMessage.value;
allmessages.value = [...allmessages.value, {
role: "user",
content: messageContent
}];
await handleConnect();
if (uploadedFiles.value.length) {
const fileJson = JSON.stringify(uploadedFiles.value);
messageContent = messageContent ? `${messageContent}
@@ -6218,10 +6223,6 @@ This will fail in production.`);
socketStore.send(data);
isThinking.value = true;
isSelfSent.value = true;
allmessages.value = [...allmessages.value, {
role: "user",
content: messageContent
}];
streamingMessageId.value = "streaming-" + Date.now();
allmessages.value = [...allmessages.value, {
role: "assistant",
@@ -6241,15 +6242,15 @@ This will fail in production.`);
}
};
const stopConversation = async () => {
formatAppLog("log", "at pages/Chat/Chat.vue:1092", "中断对话 - 当前会话ID:", currentSessionId.value);
formatAppLog("log", "at pages/Chat/Chat.vue:1097", "中断对话 - 当前会话ID:", currentSessionId.value);
try {
await socketStore.send({
type: "stop",
conversation_id: currentSessionId.value
});
formatAppLog("log", "at pages/Chat/Chat.vue:1098", "中断指令已发送成功");
formatAppLog("log", "at pages/Chat/Chat.vue:1103", "中断指令已发送成功");
} catch (err) {
formatAppLog("error", "at pages/Chat/Chat.vue:1100", "中断指令发送失败:", err);
formatAppLog("error", "at pages/Chat/Chat.vue:1105", "中断指令发送失败:", err);
}
if (streamingMessageId.value) {
allmessages.value = allmessages.value.filter((m) => m._id !== streamingMessageId.value);
@@ -6267,9 +6268,9 @@ This will fail in production.`);
});
};
vue.watch(() => socketStore.isThinking, (newVal, oldVal) => {
formatAppLog("log", "at pages/Chat/Chat.vue:1124", "isThinking 变化:", oldVal, "→", newVal, "messageString:", socketStore.messageString);
formatAppLog("log", "at pages/Chat/Chat.vue:1129", "isThinking 变化:", oldVal, "→", newVal, "messageString:", socketStore.messageString);
if (!oldVal && newVal) {
formatAppLog("log", "at pages/Chat/Chat.vue:1127", "AI开始回复跨设备同步锁定输入框");
formatAppLog("log", "at pages/Chat/Chat.vue:1132", "AI开始回复跨设备同步锁定输入框");
isThinking.value = true;
if (!streamingMessageId.value) {
streamingMessageId.value = "streaming-" + Date.now();
@@ -6283,7 +6284,7 @@ This will fail in production.`);
return;
}
if (oldVal && !newVal) {
formatAppLog("log", "at pages/Chat/Chat.vue:1143", "AI回复结束正常/中断),解锁并刷新消息列表");
formatAppLog("log", "at pages/Chat/Chat.vue:1148", "AI回复结束正常/中断),解锁并刷新消息列表");
if (streamingMessageId.value) {
allmessages.value = allmessages.value.filter((m) => m._id !== streamingMessageId.value);
streamingMessageId.value = null;
@@ -6335,15 +6336,15 @@ This will fail in production.`);
UserData.value = await getUserInfo(userToken.value);
UserId.value = UserData.value._id;
UserAvatar.value = UserData.value.avatar || "";
formatAppLog("log", "at pages/Chat/Chat.vue:1207", "用户信息已加载:", UserId.value, UserAvatar.value);
formatAppLog("log", "at pages/Chat/Chat.vue:1212", "用户信息已加载:", UserId.value, UserAvatar.value);
} catch (error) {
formatAppLog("error", "at pages/Chat/Chat.vue:1209", "获取用户信息失败:", error);
formatAppLog("error", "at pages/Chat/Chat.vue:1214", "获取用户信息失败:", error);
}
};
const takeUserConversations = async () => {
try {
userToken.value = getToken();
formatAppLog("log", "at pages/Chat/Chat.vue:1217", "token:", userToken.value);
formatAppLog("log", "at pages/Chat/Chat.vue:1222", "token:", userToken.value);
UserConversations.value = await getUserConversations(userToken.value) || [];
const savedSessionId = getCurrentSessionId();
if (savedSessionId && UserConversations.value.some((c) => c._id === savedSessionId)) {
@@ -6353,7 +6354,7 @@ This will fail in production.`);
} else {
currentSessionId.value = "";
}
formatAppLog("log", "at pages/Chat/Chat.vue:1229", "保存会话id", currentSessionId.value);
formatAppLog("log", "at pages/Chat/Chat.vue:1234", "保存会话id", currentSessionId.value);
uni.setStorageSync("currentSessionId", currentSessionId.value);
} catch (error) {
uni.showToast({
@@ -6365,17 +6366,17 @@ This will fail in production.`);
const FriendInfoList = vue.ref([]);
const takeFriendList = async () => {
try {
formatAppLog("log", "at pages/Chat/Chat.vue:1244", "开始获取好友列表");
formatAppLog("log", "at pages/Chat/Chat.vue:1249", "开始获取好友列表");
const friendList = await getChatFriend(UserId.value);
formatAppLog("log", "at pages/Chat/Chat.vue:1247", "friendList:", friendList);
formatAppLog("log", "at pages/Chat/Chat.vue:1252", "friendList:", friendList);
if (friendList && friendList.length) {
FriendInfoList.value = await takeUserAvatar(friendList);
} else {
FriendInfoList.value = [];
formatAppLog("log", "at pages/Chat/Chat.vue:1252", "好友列表为空");
formatAppLog("log", "at pages/Chat/Chat.vue:1257", "好友列表为空");
}
} catch (error) {
formatAppLog("error", "at pages/Chat/Chat.vue:1255", "获取好友列表失败:", error);
formatAppLog("error", "at pages/Chat/Chat.vue:1260", "获取好友列表失败:", error);
FriendInfoList.value = [];
} finally {
UserConversations.value = FriendInfoList.value;
@@ -6402,17 +6403,17 @@ This will fail in production.`);
};
});
} catch (err) {
formatAppLog("error", "at pages/Chat/Chat.vue:1285", "获取好友头像失败", err);
formatAppLog("error", "at pages/Chat/Chat.vue:1290", "获取好友头像失败", err);
return friendList;
}
};
const GroupList = vue.ref([]);
const takeGroupList = async () => {
try {
formatAppLog("log", "at pages/Chat/Chat.vue:1295", "开始获取群聊列表");
formatAppLog("log", "at pages/Chat/Chat.vue:1300", "开始获取群聊列表");
GroupList.value = await getGroup(UserId.value);
} catch (error) {
formatAppLog("error", "at pages/Chat/Chat.vue:1300", "获取群聊列表失败:", error);
formatAppLog("error", "at pages/Chat/Chat.vue:1305", "获取群聊列表失败:", error);
GroupList.value = [];
} finally {
UserConversations.value = GroupList.value;
@@ -6424,22 +6425,22 @@ This will fail in production.`);
return [];
try {
const memberIds = memberList.map((item) => item.groupContactId);
formatAppLog("log", "at pages/Chat/Chat.vue:1314", "请求头像的ID列表:", memberIds);
formatAppLog("log", "at pages/Chat/Chat.vue:1319", "请求头像的ID列表:", memberIds);
const memberAvatarList = await getUserAvatar(userToken.value, memberIds);
formatAppLog("log", "at pages/Chat/Chat.vue:1316", "头像接口返回数据:", memberAvatarList);
formatAppLog("log", "at pages/Chat/Chat.vue:1321", "头像接口返回数据:", memberAvatarList);
const userMap = new Map(memberAvatarList.map((user) => [user.user_id, user]) || []);
formatAppLog("log", "at pages/Chat/Chat.vue:1319", "userMap的keys:", Array.from(userMap.keys()));
formatAppLog("log", "at pages/Chat/Chat.vue:1324", "userMap的keys:", Array.from(userMap.keys()));
return memberList.map((member) => {
const memberId = member.groupContactId;
const userInfo = userMap.get(memberId);
formatAppLog("log", "at pages/Chat/Chat.vue:1324", `查找 ${memberId} 的头像:`, userInfo);
formatAppLog("log", "at pages/Chat/Chat.vue:1329", `查找 ${memberId} 的头像:`, userInfo);
return {
...member,
avatar: (userInfo == null ? void 0 : userInfo.avatar) || null
};
});
} catch (err) {
formatAppLog("error", "at pages/Chat/Chat.vue:1331", "获取群成员头像失败", err);
formatAppLog("error", "at pages/Chat/Chat.vue:1336", "获取群成员头像失败", err);
return memberList;
}
};
@@ -6486,12 +6487,12 @@ This will fail in production.`);
const takeGroupMessages = async () => {
try {
allmessages.value = await getGroupMessages(currentSessionId.value) || [];
formatAppLog("log", "at pages/Chat/Chat.vue:1395", "群聊消息:", allmessages.value);
formatAppLog("log", "at pages/Chat/Chat.vue:1400", "群聊消息:", allmessages.value);
const memberList = await getGroupMemberList(currentSessionId.value);
formatAppLog("log", "at pages/Chat/Chat.vue:1398", "获取到的群成员列表:", memberList);
formatAppLog("log", "at pages/Chat/Chat.vue:1403", "获取到的群成员列表:", memberList);
if (memberList && memberList.length) {
groupMemberList.value = await takeGroupMemberAvatar(memberList);
formatAppLog("log", "at pages/Chat/Chat.vue:1401", "群成员列表(带头像):", groupMemberList.value);
formatAppLog("log", "at pages/Chat/Chat.vue:1406", "群成员列表(带头像):", groupMemberList.value);
} else {
groupMemberList.value = [];
}
@@ -6515,9 +6516,9 @@ This will fail in production.`);
}
};
vue.watch(() => friendSocketStore.MessageReceived, (newId) => {
formatAppLog("log", "at pages/Chat/Chat.vue:1448", "收到了好友消息");
formatAppLog("log", "at pages/Chat/Chat.vue:1453", "收到了好友消息");
if (newId) {
formatAppLog("log", "at pages/Chat/Chat.vue:1450", "ChatType:", ChatType.value);
formatAppLog("log", "at pages/Chat/Chat.vue:1455", "ChatType:", ChatType.value);
switch (ChatType.value) {
case 0:
takeConversationMessages();
@@ -6532,7 +6533,7 @@ This will fail in production.`);
friendSocketStore.MessageReceived = false;
break;
default:
formatAppLog("log", "at pages/Chat/Chat.vue:1466", "default 分支");
formatAppLog("log", "at pages/Chat/Chat.vue:1471", "default 分支");
friendSocketStore.MessageReceived = false;
break;
}
@@ -6796,7 +6797,7 @@ This will fail in production.`);
"scroll-y": "",
"scroll-into-view": $setup.scrollToView,
"upper-threshold": 0,
"scroll-with-animation": true,
"scroll-with-animation": !$setup.isThinking,
onScroll: $setup.onScroll
}, [
$setup.isLoadingMessages ? (vue.openBlock(), vue.createElementBlock("view", {
@@ -7112,7 +7113,7 @@ This will fail in production.`);
id: "chat-bottom-b",
style: { "height": "1rpx" }
})
], 40, ["scroll-into-view"]),
], 40, ["scroll-into-view", "scroll-with-animation"]),
vue.createElementVNode(
"view",
{
@@ -7738,8 +7739,10 @@ This will fail in production.`);
currentFolderList.value = getCurrentFolderList();
};
const handleFolderClick = (folder) => {
if (folder.type !== "directory")
if (folder.type !== "directory") {
handleLongPress(folder);
return;
}
folderStack.value.push({
path: folder.path,
name: folder.name
@@ -7778,7 +7781,7 @@ This will fail in production.`);
uni.navigateBack({
delta: 1,
fail() {
formatAppLog("log", "at pages/WorkSpace/WorkSpace.vue:658", "返回失败,进入兜底跳转");
formatAppLog("log", "at pages/WorkSpace/WorkSpace.vue:661", "返回失败,进入兜底跳转");
uni.reLaunch({
url: "/pages/Chat/Chat"
});

View File

@@ -378,7 +378,7 @@
.wyxd-slide-area[data-v-507487c4] {
flex: 1;
min-height: 0;
padding: 0.625rem;
/* padding: 20rpx; */
}
.wyxd-slide-scroll[data-v-507487c4] {
height: 100%;
@@ -386,10 +386,18 @@
border-radius: 0.375rem;
box-shadow: 0 0.0625rem 0.375rem rgba(0, 0, 0, 0.04);
}
.wyxd-slide-card[data-v-507487c4] {
padding: 1rem;
/* .wyxd-slide-card {
padding: 32rpx;
min-height: 100%;
box-sizing: border-box;
} */
.wyxd-slide-card[data-v-507487c4] {
min-height: 100%;
box-sizing: border-box;
display: flex;
justify-content: center;
align-items: center;
flex-direction: column; /* 子元素垂直排列 */
}
/* ===== 底部翻页 ===== */
.wyxd-pager[data-v-507487c4] {