Remove fleet lobby follow notifications

This commit is contained in:
2026-09-21 19:33:57 -04:00
parent e448457d58
commit f875260b7e
5 changed files with 10 additions and 123 deletions
-18
View File
@@ -87,21 +87,3 @@ export function matchesFleet(server: FleetServer, query: string, filter: FleetFi
...(server.roster ?? []).map(player => player.name)].join(' ').toLocaleLowerCase();
return query.trim().toLocaleLowerCase().split(/\s+/).every(term => text.includes(term));
}
export interface LobbyWatch {
id: string;
server: string;
kind: 'empty' | 'online' | 'operation';
operationKey?: string;
href: string;
}
export function watchSatisfied(watch: LobbyWatch, server: FleetServer | undefined,
operations: readonly FleetOperation[], now: number): boolean {
if (watch.kind === 'operation') {
// Disappearance, failure and replacement by another operation are not completion.
return operations.some(op => op.key === watch.operationKey && op.state === 'done');
}
if (!server || !freshServer(server, now)) return false;
return watch.kind === 'online' || server.last_players === 0;
}