Reset unread message count for all servers when a new server is selected.

This commit is contained in:
akastijn 2026-07-19 17:58:31 +02:00
parent 3f974b2dff
commit aca9bd45ab

View File

@ -86,6 +86,7 @@ export class ChatService implements OnDestroy {
public selectServer(server: string) { public selectServer(server: string) {
this._selectedServer.set(server); this._selectedServer.set(server);
this._servers.update((old) => old.map((s) => ({...s, unreadMessages: 0})));
} }
// single, deliberate escape hatch from the broken DOM/polyfill type overlap — // single, deliberate escape hatch from the broken DOM/polyfill type overlap —