Editing and error correction (in progress)

This commit is contained in:
2026-09-30 12:43:19 +03:30
parent a3ed6187e9
commit 3c0ed3369e
5 changed files with 199 additions and 31 deletions
+7 -2
View File
@@ -170,13 +170,18 @@ const typingLabel = computed(() => {
const roomId = activeRoom.value?.externalRoomId;
if (!roomId) return '';
const list = (typingMap.value?.[roomId] || []).filter(
(t) => Date.now() - t.at < 3500,
(t) => Date.now() - t.at < 4000,
);
if (!list.length) return '';
const names = list
.map((t) => {
if (t.name) return t.name;
if (t.userId === '__someone__') return '';
return peers.value.find((p) => p.chatUserId === t.userId)?.fullName || '';
return (
peers.value.find((p) => p.chatUserId === t.userId)?.fullName ||
peers.value.find((p) => p.id === t.userId)?.fullName ||
''
);
})
.filter(Boolean);
if (!names.length) return 'در حال نوشتن…';