@adhdev/daemon-standalone 0.9.76-rc.7 → 0.9.76-rc.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -30177,8 +30177,9 @@ ${rules.join("\n")}`;
30177
30177
  const currentSnapshot = normalizeScreenSnapshot(screenText);
30178
30178
  const lastSnapshot = this.lastScreenSnapshot;
30179
30179
  if (!lastSnapshot || lastSnapshot === currentSnapshot) return screenText;
30180
- const staleSnapshotLooksActive = /\besc to (?:interrupt|stop)\b|Enter to interrupt, Ctrl\+C to cancel/i.test(lastSnapshot);
30181
- const currentScreenLooksIdle = /(?:^|\n|\r)\s*[❯›>]\s*(?:\n|\r|$)/.test(screenText) && !/\besc to (?:interrupt|stop)\b|Enter to interrupt, Ctrl\+C to cancel/i.test(screenText);
30180
+ const activeScreenPattern = /\besc to (?:interrupt|stop)\b|Enter to interrupt, Ctrl\+C to cancel|Enter to confirm\s*[·•-]\s*Esc to cancel|\b(?:MCP servers?|tool calls?)\b[^\n\r]{0,160}\brequire approval\b/i;
30181
+ const staleSnapshotLooksActive = activeScreenPattern.test(lastSnapshot);
30182
+ const currentScreenLooksIdle = /(?:^|\n|\r)\s*[❯›>]\s*(?:Try\s+["“][^\n\r"”]+["”])?\s*(?:\n|\r|$)/.test(screenText) && !activeScreenPattern.test(screenText);
30182
30183
  if (staleSnapshotLooksActive && currentScreenLooksIdle) return screenText;
30183
30184
  if (currentSnapshot.length >= lastSnapshot.length) return screenText;
30184
30185
  return `${screenText}
@@ -39510,6 +39511,14 @@ ${effect.notification.body || ""}`.trim();
39510
39511
  if (profile === "full") return {};
39511
39512
  return LIVE_STATUS_ACTIVE_CHAT_OPTIONS;
39512
39513
  }
39514
+ function resolveSessionStatus(activeChat, providerStatus) {
39515
+ const chatStatus = normalizeManagedStatus(activeChat?.status, { activeModal: activeChat?.activeModal || null });
39516
+ const topLevelStatus = normalizeManagedStatus(providerStatus, { activeModal: activeChat?.activeModal || null });
39517
+ if (chatStatus === "waiting_approval" || topLevelStatus === "waiting_approval") return "waiting_approval";
39518
+ if (chatStatus === "generating" || topLevelStatus === "generating") return "generating";
39519
+ if (topLevelStatus !== "idle") return topLevelStatus;
39520
+ return chatStatus;
39521
+ }
39513
39522
  function shouldIncludeSessionControls(profile) {
39514
39523
  return profile !== "live";
39515
39524
  }
@@ -39588,9 +39597,7 @@ ${effect.notification.body || ""}`.trim();
39588
39597
  providerName: state.name,
39589
39598
  kind: "workspace",
39590
39599
  transport: "cdp-page",
39591
- status: normalizeManagedStatus(activeChat?.status || state.status, {
39592
- activeModal: activeChat?.activeModal || null
39593
- }),
39600
+ status: resolveSessionStatus(activeChat, state.status),
39594
39601
  title,
39595
39602
  workspace,
39596
39603
  ...git && { git },
@@ -39625,9 +39632,7 @@ ${effect.notification.body || ""}`.trim();
39625
39632
  providerSessionId: ext.providerSessionId,
39626
39633
  kind: "agent",
39627
39634
  transport: "cdp-webview",
39628
- status: normalizeManagedStatus(activeChat?.status || ext.status, {
39629
- activeModal: activeChat?.activeModal || null
39630
- }),
39635
+ status: resolveSessionStatus(activeChat, ext.status),
39631
39636
  title: activeChat?.title || ext.name,
39632
39637
  workspace,
39633
39638
  ...git && { git },
@@ -39677,9 +39682,7 @@ ${effect.notification.body || ""}`.trim();
39677
39682
  providerSessionId: state.providerSessionId,
39678
39683
  kind: "agent",
39679
39684
  transport: "pty",
39680
- status: normalizeManagedStatus(activeChat?.status || state.status, {
39681
- activeModal: activeChat?.activeModal || null
39682
- }),
39685
+ status: resolveSessionStatus(activeChat, state.status),
39683
39686
  title: activeChat?.title || state.name,
39684
39687
  workspace,
39685
39688
  ...git && { git },
@@ -39727,9 +39730,7 @@ ${effect.notification.body || ""}`.trim();
39727
39730
  providerName: state.name,
39728
39731
  kind: "agent",
39729
39732
  transport: "acp",
39730
- status: normalizeManagedStatus(activeChat?.status || state.status, {
39731
- activeModal: activeChat?.activeModal || null
39732
- }),
39733
+ status: resolveSessionStatus(activeChat, state.status),
39733
39734
  title: activeChat?.title || state.name,
39734
39735
  workspace,
39735
39736
  ...git && { git },