[eric] apps: auto hard-reload the app card when a turn installed deps (soft reload can't see new packages)

This commit is contained in:
ciregenz
2026-07-07 01:31:35 -07:00
parent 08d5bd3cc6
commit 953fddc99e
5 changed files with 81 additions and 1 deletions
@@ -14,6 +14,7 @@ import {
setContextOverflow,
setRateLimited,
setContextRecovered,
setAppDepsChanged,
setMcpSuggestions,
addBranch,
setActiveBranch,
@@ -562,6 +563,13 @@ class WebSocketManager {
}
break;
case 'agent:app_deps_changed':
// A view-builder agent installed/changed deps this turn; the app card escalates its turn-finish reload from soft to a Vite restart so new deps actually load.
if (session_id) {
store.dispatch(setAppDepsChanged({ sessionId: session_id }));
}
break;
case 'agent:context_status':
// Auto-compaction collapsed older turns into a summary. Mirror compacted_through_msg_id locally so the renderer can drop a visible "N earlier turns summarized" chip into the transcript. Other reasons (cleared, etc.) flow through this same event but don't currently need a chip, ignore them for now.
if (session_id && data.reason === 'compacted') {