wip: optimizations

This commit is contained in:
2026-05-23 15:28:40 +02:00
parent 5bf506af03
commit 155fe20862
89 changed files with 7431 additions and 392 deletions
@@ -8,6 +8,7 @@ import {
} from '../../shared-kernel';
import type { ElectronApi } from '../../core/platform/electron/electron-api.models';
import { ElectronBridgeService } from '../../core/platform/electron/electron-bridge.service';
import type { RoomMessageStats } from './database.service';
/**
* Database service for the Electron (desktop) runtime.
@@ -63,6 +64,10 @@ export class ElectronDatabaseService {
return this.api.query<Message[]>({ type: 'get-messages-since', payload: { roomId, sinceTimestamp } });
}
getRoomMessageStats(roomId: string): Promise<RoomMessageStats> {
return this.api.query<RoomMessageStats>({ type: 'get-room-message-stats', payload: { roomId } });
}
/** Permanently delete a message by ID. */
deleteMessage(messageId: string): Promise<void> {
return this.api.command({ type: 'delete-message', payload: { messageId } });