App: agent notifications on the web (system notification, toast, tab title count)
The app subscribes to the notification stream on every connection and delivers chat_notify notices: a toast when the page is focused (none if that chat is in view), a browser notification titled '<chat>: <title>' plus a '(n)' tab title count when it is not, and on insecure http pages a toast, the title count and a short chime. Low priority posts only when hidden. Replays within an hour show once; ids persist in the ledger. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -44,6 +44,7 @@ import 'perf/chat_search_fixture.dart';
|
||||
import 'perf/chat_shown_fixture.dart';
|
||||
import 'perf/chat_claude_accounts_fixture.dart';
|
||||
import 'perf/chat_question_fixture.dart';
|
||||
import 'perf/agent_notice_fixture.dart';
|
||||
import 'capture/window_probe.dart';
|
||||
import 'perf/chat_scroll_fixture.dart';
|
||||
import 'perf/perf_fixture.dart';
|
||||
@@ -814,7 +815,11 @@ class _FixtureChannel implements WebSocketChannel {
|
||||
}
|
||||
});
|
||||
}
|
||||
final reply = probeReply(decoded);
|
||||
final reply =
|
||||
agentNoticeReply(decoded, (frame) {
|
||||
if (!_incoming.isClosed) _incoming.add(jsonEncode(frame));
|
||||
}) ??
|
||||
probeReply(decoded);
|
||||
final followUps = perfChatFollowUps(decoded);
|
||||
final subscribe = decoded['chat_subscribe'];
|
||||
if (subscribe is Map) {
|
||||
@@ -927,6 +932,7 @@ Future<void> main() async {
|
||||
return;
|
||||
}
|
||||
configurePerfFixture(params);
|
||||
configureAgentNoticeFixture(params);
|
||||
installSpeechFixture(params);
|
||||
if (params['files'] == '1') {
|
||||
probeMissingRememberedFolder = params['filesMissing'] == '1';
|
||||
|
||||
Reference in New Issue
Block a user