fix last message

This commit is contained in:
Peter Maquiran
2024-09-01 14:27:32 +01:00
parent 41c63b6c56
commit d4776a5d7a
21 changed files with 132 additions and 115 deletions
@@ -1,27 +0,0 @@
import { z } from "zod";
import { MessageAttachmentFileType, MessageAttachmentSource } from "./messageOutputDTO";
import { base64Schema } from "src/app/utils/zod";
export const MessageInputDTOSchema = z.object({
roomId: z.string().uuid().optional(),
receiverId: z.number().optional(),
senderId: z.number(),
message: z.string().nullable().optional(),
messageType: z.number(),
canEdit: z.boolean(),
oneShot: z.boolean(),
requireUnlock: z.boolean(),
requestId: z.string(),
attachment: z.object({
fileType: z.nativeEnum(MessageAttachmentFileType),
source: z.nativeEnum(MessageAttachmentSource),
file: base64Schema.optional(),
fileName: z.string().optional(),
applicationId: z.number().optional(),
docId: z.number().optional(),
mimeType: z.string().optional()
}).optional()
});
export type MessageInputDTO = z.infer<typeof MessageInputDTOSchema>
@@ -1,19 +1,19 @@
import { HubConnection } from "@microsoft/signalr";
import { Result } from "neverthrow";
import { MessageInputDTO } from '../dto/messageInputDtO'
import { MessageCreateOutPutDataDTO } from "src/app/module/chat/domain/use-case/message/message-create-use-case.service";
import { MessageCreateOutPutDataDTO, MessageInputDTO } from "src/app/module/chat/domain/use-case/message/message-create-use-case.service";
import { MessageMarkAsReadInput } from "src/app/module/chat/domain/use-case/message/message-mark-as-read-use-case.service";
import { MessageDeleteInputDTO } from "src/app/module/chat/domain/use-case/message/message-delete-by-id-live-use-case.service";
import { MessageOutPutDataDTO } from "../dto/messageOutputDTO";
import { Observable } from "rxjs";
import { MessageReactionInput } from "src/app/module/chat/domain/use-case/message/message-reaction-by-id-use-case.service";
import { MessageUpdateInput } from "src/app/module/chat/domain/use-case/message/message-update-by-id-use-case.service";
import { SocketMessage } from "src/app/infra/socket/signalR/signalR";
export abstract class IMessageSocketRepository {
abstract connect(): Promise<Result<HubConnection, false>>
abstract sendGroupMessage(data: MessageInputDTO): Promise<Result<MessageCreateOutPutDataDTO, any>>
abstract sendDirectMessage(data: MessageInputDTO): Promise<Result<MessageCreateOutPutDataDTO, any>>
abstract sendGroupMessage(data: MessageInputDTO): Promise<Result<MessageCreateOutPutDataDTO, any>>
abstract sendDirectMessage(data: MessageInputDTO): Promise<Result<MessageCreateOutPutDataDTO, any>>
// abstract sendDeliverAt(): Promise<Result<any, any>>
abstract sendReadAt(data: MessageMarkAsReadInput): Promise<Result<any, any>>
@@ -23,7 +23,9 @@ export abstract class IMessageSocketRepository {
abstract listenToDeleteMessages(): Observable<MessageOutPutDataDTO>
abstract listenToUpdateMessages(): Observable<MessageOutPutDataDTO>
abstract listenToSendMessage(): Observable<SocketMessage<MessageInputDTO>>
abstract reactToMessageSocket(data: MessageReactionInput): void
abstract updateMessage(input: MessageUpdateInput): void
abstract sendMessageDelete(data: MessageDeleteInputDTO): Promise<Result<any, any>>
}
}
@@ -1,6 +1,5 @@
import { HubConnection } from "@microsoft/signalr";
import { Result } from "neverthrow";
import { MessageInputDTO } from '../dto/messageInputDtO'
import { Observable } from "rxjs";
import { ListenToDeleteRoomInput, RoomSocketOutPutDTO } from "src/app/module/chat/data/repository/room/room-socket-repository.service";
import { CreateRoomInputDTO } from "src/app/module/chat/domain/use-case/room/room-create-use-case.service";
@@ -14,4 +13,4 @@ export abstract class IRoomSocketRepository {
abstract listenToDeleteRoom(): Observable<ListenToDeleteRoomInput>
}
}
@@ -16,7 +16,7 @@ export const AttachmentTableSchema = z.object({
applicationId: z.number().optional(),
docId: z.string().optional(),
mimeType: z.string().optional(),
id: z.string().optional(),
id: z.string().uuid().optional(),
description: z.string().optional()
})
@@ -4,7 +4,7 @@ import { RoomType } from "src/app/core/chat/entity/group";
import { MessageEntity, MessageEntitySchema } from "src/app/core/chat/entity/message";
export const RoomTableSchema = z.object({
id: z.string(),
id: z.string().uuid(),
roomName: z.string(),
createdBy: z.object({
wxUserId: z.number(),
@@ -20,4 +20,4 @@ export const RoomTableSchema = z.object({
export type RoomTable = z.infer<typeof RoomTableSchema>
export type DexieRoomsTable = EntityTable<RoomTable, 'id'>;
export const RoomTableColumn = 'id, createdBy, roomName, roomType, expirationDate, lastMessage'
export const RoomTableColumn = 'id, createdBy, roomName, roomType, expirationDate, lastMessage'
@@ -73,6 +73,10 @@ export class DexieRepository<T, R> implements IDexieRepository<T, R> {
return err(new Error('Failed to update document: ' + error.message));
}
} else {
Logger.error(`dexie.js failed to update into ${this.table.name}, invalid data`, {
data: document,
zodError: dataValidation.error.issues
});
return err((dataValidation as unknown as ZodError<T>))
}
}
+1 -1
View File
@@ -134,7 +134,7 @@ export class SignalRConnection {
first()
).subscribe(value => {
resolve(ok(value.data as unknown as T))
console.log('Received valid value:', value);
// console.log('Received valid value:', value);
});
} catch(error) {
@@ -14,8 +14,8 @@ export function roomListDetermineChanges(serverRooms: RoomListItemOutPutDTO[], l
room.chatRoom.roomName !== localRoom.roomName && room.chatRoom.roomType == RoomType.Group ||
room.chatRoom.createdBy.wxUserId !== localRoom.createdBy.wxUserId ||
room.chatRoom.createdAt !== localRoom.createdAt ||
room.chatRoom.expirationDate !== localRoom.expirationDate ||
room.chatRoom.messages?.[0]?.id !== localRoom.messages?.[0]?.id
room.chatRoom.expirationDate !== localRoom.expirationDate // ||
// room.chatRoom.messages?.[0]?.id !== localRoom.messages?.[0]?.id
// room.chatRoom.roomType !== localRoom.roomType
);
});
@@ -7,11 +7,11 @@ import { SignalRService } from 'src/app/infra/socket/signalR/signal-r.service';
import { filter, map } from 'rxjs/operators';
import { SocketMessage } from 'src/app/infra/socket/signalR/signalR';
import { IMessageSocketRepository } from 'src/app/core/chat/repository/message/message-socket-repository';
import { MessageCreateOutPutDataDTO } from '../../../domain/use-case/message/message-create-use-case.service';
import { MessageInputDTO } from 'src/app/core/chat/repository/dto/messageInputDtO'
import { MessageCreateOutPutDataDTO, MessageInputDTO } from '../../../domain/use-case/message/message-create-use-case.service';
import { MessageMarkAsReadInput } from '../../../domain/use-case/message/message-mark-as-read-use-case.service';
import { MessageOutPutDataDTO } from 'src/app/core/chat/repository/dto/messageOutputDTO';
import { MessageDeleteInputDTO } from '../../../domain/use-case/message/message-delete-by-id-live-use-case.service';
import { BehaviorSubject, Observable } from 'rxjs';
interface sendDeliverAt {
memberId: number,
@@ -25,6 +25,8 @@ interface sendDeliverAt {
})
export class MessageSocketRepositoryService implements IMessageSocketRepository {
private sendDataSubject: BehaviorSubject<{method: string, data: any}> = new BehaviorSubject<{method: string, data: any}>(null);
constructor(
private socket: SignalRService
) {}
@@ -49,9 +51,10 @@ export class MessageSocketRepositoryService implements IMessageSocketRepository
data: data,
})
if(result.isOk()) {
console.log('recieve', result.value)
}
this.sendDataSubject.next({
method: 'sendMessage',
data: data,
})
return result;
}
@@ -66,6 +69,10 @@ export class MessageSocketRepositoryService implements IMessageSocketRepository
data: data as any,
})
this.sendDataSubject.next({
method: 'SendDirectMessage',
data: data,
})
return result;
}
@@ -121,6 +128,18 @@ export class MessageSocketRepositoryService implements IMessageSocketRepository
)
}
listenToSendMessage() {
return this.sendDataSubject.pipe(
filter((e) : e is SocketMessage<MessageInputDTO>=> {
console.log(e, e?.method == 'sendMessage' || e?.method == 'SendDirectMessage')
return e?.method == 'sendMessage' || e?.method == 'SendDirectMessage'
}
))
}
reactToMessageSocket(data: MessageReactionInput) {
this.socket.sendData({
@@ -40,6 +40,7 @@ import { MessageSocketRepositoryService } from 'src/app/module/chat/data/reposit
import { MessageMarkAsReadInput } from "src/app/module/chat/domain/use-case/message/message-mark-as-read-use-case.service";
import { BoldRemoveByRoomIdInput, BoldRemoveByRoomIdService } from 'src/app/module/chat/domain/use-case/bold/bold-remove-by-room-id.service';
import { MemberListHttpSyncUseCase } from 'src/app/module/chat/domain/use-case/member/member-list-http-sync-use-case.ts.service'
import { RoomSetLastMessageService } from 'src/app/module/chat/domain/use-case/room/room-set-last-message.service'
export const InstanceId = uuidv4();
@Injectable({
@@ -80,7 +81,8 @@ export class ChatServiceService {
private HttpListenToMessageLoadHistory: HttpListenToMessageLoadHistoryAdapter,
private MessageSocketRepositoryService: MessageSocketRepositoryService,
private BoldRemoveByRoomIdService: BoldRemoveByRoomIdService,
private MemberListHttpSyncUseCase: MemberListHttpSyncUseCase
private MemberListHttpSyncUseCase: MemberListHttpSyncUseCase,
private RoomSetLastMessageService: RoomSetLastMessageService
) {
this.MessageSocketRepositoryService.listenToDeleteMessages()
.pipe()
@@ -1,6 +1,6 @@
import { MessageInputDTO } from "src/app/core/chat/repository/dto/messageInputDtO";
import { MessageEntity } from "../../../../core/chat/entity/message";
import { MessageOutPutDataDTO } from "src/app/core/chat/repository/dto/messageOutputDTO";
import { MessageInputDTO } from "../use-case/message/message-create-use-case.service";
export class MessageMapper {
static toDomain(DTO: MessageOutPutDataDTO) : MessageEntity {
@@ -15,20 +15,20 @@ export class MemberListHttpSyncUseCase {
private memberLocalRepository: IMemberLocalRepository
) {
// this.http.listen().pipe(
// filter((response)=> {
// if(response?.isOk()) {
// return response.value.url.includes('/Room/') && typeof response.value?.data?.data?.roomName == 'string'
// }
this.http.listen().pipe(
filter((response)=> {
if(response?.isOk()) {
return response.value.url.includes('/Room/') && typeof response.value?.data?.data?.roomName == 'string'
}
// return false
// }),
// map((response: any) => response.value.data as RoomByIdOutputDTO)
// )
// .subscribe(async (data) => {
return false
}),
map((response: any) => response.value.data as RoomByIdOutputDTO)
)
.subscribe(async (data) => {
// this.syncMembers(data)
// })
this.syncMembers(data)
})
}
private async syncMembers(roomData: RoomByIdOutputDTO): Promise<void> {
@@ -19,12 +19,31 @@ import { IMessageLocalRepository } from 'src/app/core/chat/repository/message/me
import { IMessageSocketRepository } from 'src/app/core/chat/repository/message/message-socket-repository';
import { IMemberLocalRepository } from 'src/app/core/chat/repository/member/member-local-repository';
import { IAttachmentLocalRepository } from 'src/app/core/chat/repository/typing/typing-local-repository';
import { base64Schema } from 'src/app/utils/zod';
export enum MessageEnum {
Direct = 1,
group = 2
}
export const MessageInputDTOSchema = z.object({
roomId: z.string().uuid().optional(),
receiverId: z.number().optional(),
senderId: z.number(),
message: z.string().nullable().optional(),
messageType: z.number(),
canEdit: z.boolean(),
oneShot: z.boolean(),
requireUnlock: z.boolean(),
requestId: z.string(),
attachment: z.object({
fileType: z.nativeEnum(MessageAttachmentFileType),
source: z.nativeEnum(MessageAttachmentSource),
file: base64Schema.optional(),
fileName: z.string().optional(),
applicationId: z.number().optional(),
docId: z.number().optional(),
mimeType: z.string().optional()
}).optional()
});
export type MessageInputDTO = z.infer<typeof MessageInputDTOSchema>
export const MessageCreatePutDataDTOSchema = z.object({
@@ -6,7 +6,6 @@ import { z } from "zod";
import { IRoomRemoteRepository } from 'src/app/core/chat/repository/room/room-remote-repository';
import { IRoomLocalRepository } from 'src/app/core/chat/repository/room/room-local-repository';
import { MessageEntitySchema } from 'src/app/core/chat/entity/message';
import { RoomEntity, RoomType } from 'src/app/core/chat/entity/group';
import { GetRoomListMapper } from 'src/app/core/chat/mapper/getRoomListMapper';
@@ -52,7 +51,6 @@ export class GetRoomListUseCaseService {
constructor(
private roomRemoteDataSourceService: IRoomRemoteRepository,
// private roomMemoryDataSourceService: Store<RoomRemoteDataSourceState>,
private roomLocalDataSourceService: IRoomLocalRepository,
private CronJobService: CronJobService
) { }
@@ -65,7 +63,7 @@ export class GetRoomListUseCaseService {
if(localList.isOk()) {
if(result.isOk()) {
const { roomsToDelete, roomsToInsert, roomsToUpdate } = roomListDetermineChanges(result.value.data, localList.value)
if(roomsToInsert) {
@@ -73,12 +71,11 @@ export class GetRoomListUseCaseService {
for( const room of roomsToInsertEntity) {
this.roomLocalDataSourceService.insert(room)
if(room.expirationDate) {
console.log('room expiration date schedule')
this.CronJobService.createCronJob('remove expired room', new Date(room.expirationDate), this.execute)
}
}
}
const roomsToUpdateEntity = GetRoomListMapper.toDomain(roomsToUpdate)
this.roomLocalDataSourceService.updateMany(roomsToUpdateEntity)
@@ -1,16 +0,0 @@
import { TestBed } from '@angular/core/testing';
import { RoomSetLastMessageService } from './room-set-last-message.service';
describe('RoomSetLastMessageService', () => {
let service: RoomSetLastMessageService;
beforeEach(() => {
TestBed.configureTestingModule({});
service = TestBed.inject(RoomSetLastMessageService);
});
it('should be created', () => {
expect(service).toBeTruthy();
});
});
@@ -4,6 +4,7 @@ import { IRoomLocalRepository } from 'src/app/core/chat/repository/room/room-loc
import { filter, map } from 'rxjs/operators';
import { InstanceId } from '../../chat-service.service';
import { MessageEntity } from 'src/app/core/chat/entity/message';
import { SessionStore } from 'src/app/store/session.service';
@Injectable({
providedIn: 'root'
@@ -11,14 +12,15 @@ import { MessageEntity } from 'src/app/core/chat/entity/message';
export class RoomSetLastMessageService {
constructor(
private MessageSocketRepositoryService: IMessageSocketRepository,
private roomLocalRepository: IRoomLocalRepository
private roomLocalRepository: IRoomLocalRepository,
private messageSocketRepository: IMessageSocketRepository
) {
// this.listenToIncomingMessage()
this.listenToIncomingMessage()
this.listenToOnSendDataToSocket()
}
listenToIncomingMessage() {
return this.MessageSocketRepositoryService.listenToMessages().pipe(
return this.messageSocketRepository.listenToMessages().pipe(
filter((message) => !message?.requestId?.startsWith(InstanceId)),
map(message => Object.assign(new MessageEntity(), message))
).subscribe(async (message) => {
@@ -31,6 +33,23 @@ export class RoomSetLastMessageService {
}
listenToOnSendDataToSocket() {
this.messageSocketRepository.listenToSendMessage().subscribe(async (e) => {
e.data['sender'] = {
userPhoto: '',
wxeMail: SessionStore.user.Email,
wxFullName: SessionStore.user.FullName,
wxUserId: SessionStore.user.UserId
}
e.data['sentAt'] = new Date().toISOString()
const result = await this.roomLocalRepository.update(e.data.roomId, {
messages: [e.data]
})
if(result.isErr()) {
console.log(result.error)
}
})
}
}
@@ -8,7 +8,6 @@ import { ChatServiceService } from 'src/app/module/chat/domain/chat-service.serv
import { HttpErrorHandle } from 'src/app/services/http-error-handle.service';
import { ToastService } from 'src/app/services/toast.service';
import { SessionStore } from 'src/app/store/session.service';
import { MessageEnum } from 'src/app/module/chat/domain/use-case/message/message-create-use-case.service';
import { MessageEntity } from 'src/app/core/chat/entity/message';
// import { ChatSystemService } from 'src/app/services/chat/chat-system.service'
import { RoomType } from "src/app/core/chat/entity/group";
@@ -170,9 +169,11 @@ export class ContactsPage implements OnInit {
const result = await this.chatServiceService.sendMessage(message, RoomType.Direct)
console.log('result', result);
if(result.isOk()) {
await this.chatServiceService.getRoomById(result.value.id)
this.close(result.value.roomId)
} else {
console.log(result.error)
@@ -3,7 +3,7 @@
<div class="main-header">
<div class="header-top">
<div class="middle" >
<ion-label class="title" > {{ room.roomName }}</ion-label>
<ion-label class="title" *ngIf="roomData$ | async as roomData"> {{ roomData.roomName }}</ion-label>
<!-- <button (click)="ChatMessageDebuggingPage()">Dev</button> -->
<span *ngIf="roomStatus$ | async as roomStatus"><ion-icon *ngIf="roomStatus" class="online" name="ellipse"></ion-icon></span>
</div>
@@ -41,7 +41,7 @@ import { UserTypingRemoteRepositoryService } from 'src/app/module/chat/data/repo
import { MessageLocalDataSourceService } from 'src/app/module/chat/data/repository/message/message-local-data-source.service';
import { RoomType } from "src/app/core/chat/entity/group";
import { Logger } from 'src/app/services/logger/main/service';
import { map, tap } from 'rxjs/operators';
import { tap } from 'rxjs/operators';
import { AlertController } from '@ionic/angular';
import { ViewOncesImagePage, ViewOncesImagePageInput } from '../../modal/view-onces/view-onces.page';
import { MemberTable } from 'src/app/infra/database/dexie/instance/chat/schema/members';
@@ -50,8 +50,6 @@ import { RoomTable } from 'src/app/infra/database/dexie/instance/chat/schema/roo
import { TypingTable } from 'src/app/infra/database/dexie/instance/chat/schema/typing';
import { HttpClient } from '@angular/common/http';
import { v4 as uuidv4 } from 'uuid'
import { RoomViewModel } from '../../store/model/room';
@Component({
selector: 'app-messages',
templateUrl: './messages.page.html',
@@ -114,7 +112,7 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
@ViewChild('array') myInputRef!: ElementRef;
userName = "";
@Input() room!: RoomViewModel;
room: any = new Array();
roomName: any;
isAdmin = true;
roomCountDownDate: string;
@@ -137,7 +135,6 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
messages: MessageEntity[] = []
RoomDataSubject: Subscription
messageReceiveSubject: Subscription
messageDeleteSubject: Subscription
messageUpdateSubject: Subscription
@@ -182,7 +179,7 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
private UserTypingRemoteRepositoryService: UserTypingRemoteRepositoryService,
private messageLocalDataSourceService: MessageLocalDataSourceService,
private alertController: AlertController,
private http: HttpClient,
private http: HttpClient
) {
// update
this.checkAudioPermission()
@@ -229,6 +226,17 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
ngOnChanges(changes: SimpleChanges): void {
this.roomData$ = this.RoomLocalRepository.getRoomByIdLive(this.roomId)
this.roomData$.subscribe(e => {
// console.log(e)
if(e) {
this.roomType = e.roomType
}
})
this.getMessages();
this.listenToIncomingMessage();
this.listenToDeleteMessage();
@@ -249,7 +257,7 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
)
this.roomStatus$ = this.MemberListLocalRepository.allMemberOnline(this.roomId)
this.chatServiceService.getRoomById(this.roomId)
// this.chatServiceService.getRoomById(this.roomId)
this.messageTypingSubject?.unsubscribe()
this.messageTypingSubject = this.userTypingLocalRepository.getUserTypingLiveByRoomId(this.roomId).subscribe((e) => {
@@ -268,15 +276,6 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
this.chatServiceService.removeBoldFromRoom({roomId: this.roomId})
// this.RoomDataSubject?.unsubscribe()
// this.RoomDataSubject = this.RoomLocalRepository.getRoomByIdLive(this.roomId).pipe(
// map((roomData) => new RoomViewModel(roomData)),
// tap((room: RoomViewModel) => {
// this.room = room
// })
// ).subscribe()
}
messageStatus(message: MessageEntity) {
@@ -470,6 +469,7 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
this.messageSendSubject = this.chatServiceService.listenToSendMessage(this.roomId).subscribe((updateMessage) => {
const index = this.messages1[this.roomId].findIndex(e => e?.requestId === updateMessage.requestId); // Use triple equals for comparison
if (index !== -1) { // Check if the item was found
@@ -733,7 +733,7 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
safeFile: this.sanitiser.bypassSecurityTrustResourceUrl(this.audioRecordedDataUrl)
}]
this.chatServiceService.sendMessage(message, this.room.roomType)
this.chatServiceService.sendMessage(message, this.roomType)
this.messages1[this.roomId].push(message)
setTimeout(() => {
this.scrollToBottomClicked()
@@ -794,7 +794,7 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
setTimeout(() => {
this.scrollToBottomClicked()
}, 100)
const data = await this.chatServiceService.sendMessage(message, this.room.roomType)
const data = await this.chatServiceService.sendMessage(message, this.roomType)
}
@@ -898,7 +898,7 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
roomId: this.roomId,
members: [],
isAdmin: this.isAdmin,
roomType: this.room.roomType
roomType: this.roomType
}
});
await modal.present();
@@ -980,7 +980,7 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
setTimeout(() => {
this.scrollToBottomClicked()
}, 100)
this.chatServiceService.sendMessage(message, this.room.roomType)
this.chatServiceService.sendMessage(message, this.roomType)
}
@@ -1036,7 +1036,7 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
setTimeout(() => {
this.scrollToBottomClicked()
}, 100)
this.chatServiceService.sendMessage(message, this.room.roomType)
this.chatServiceService.sendMessage(message, this.roomType)
this.textField = ''
}
@@ -1126,7 +1126,7 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
setTimeout(() => {
this.scrollToBottomClicked()
}, 100)
this.chatServiceService.sendMessage(message, this.room.roomType)
this.chatServiceService.sendMessage(message, this.roomType)
}
}
@@ -1182,7 +1182,7 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
setTimeout(() => {
this.scrollToBottomClicked()
}, 100)
this.chatServiceService.sendMessage(message, this.room.roomType)
this.chatServiceService.sendMessage(message, this.roomType)
}
} else {
@@ -8,7 +8,6 @@ import { HttpErrorHandle } from 'src/app/services/http-error-handle.service';
import { ToastService } from 'src/app/services/toast.service';
import { ChatServiceService } from 'src/app/module/chat/domain/chat-service.service'
import { MessageEntity } from 'src/app/core/chat/entity/message';
import { MessageEnum } from 'src/app/module/chat/domain/use-case/message/message-create-use-case.service';
import { RoomType } from "src/app/core/chat/entity/group";
@Component({
@@ -43,7 +43,6 @@ import { MemberListLocalRepository } from 'src/app/module/chat/data/repository/m
import { UserTypingLocalRepository } from 'src/app/module/chat/data/repository/typing/user-typing-local-data-source.service';
import { UserTypingRemoteRepositoryService } from 'src/app/module/chat/data/repository/typing/user-typing-live-data-source.service';
import { MessageLocalDataSourceService } from 'src/app/module/chat/data/repository/message/message-local-data-source.service';
import { MessageEnum } from 'src/app/module/chat/domain/use-case/message/message-create-use-case.service';
import { RoomType } from "src/app/core/chat/entity/group";
import { RoomTable } from 'src/app/infra/database/dexie/instance/chat/schema/room';