Skip to content

YC (S26) | Open Computer History | Continuously record your company computer work, map your workflows, help you find work worth automating, and power your agents' context

fix(chat): keep running tool activity monochrome (#6571)

Louis Beaumont34aed040bd70
diff --git a/apps/screenpipe-app-tauri/components/chat/standalone/activity-icon.tsx b/apps/screenpipe-app-tauri/components/chat/standalone/activity-icon.tsx
index b5e338a33..4e5dc4fc9 100644
--- a/apps/screenpipe-app-tauri/components/chat/standalone/activity-icon.tsx
+++ b/apps/screenpipe-app-tauri/components/chat/standalone/activity-icon.tsx
@@ -71,7 +71,7 @@ export function ActivityIcon({
<span
className={cn(
"relative flex h-5 w-5 shrink-0 items-center justify-center border bg-background text-foreground/55",
- state === "running" && "border-phosphor bg-phosphor text-phosphor-ink",
+ state === "running" && "border-foreground bg-foreground text-background",
state === "completed" && "border-border/80 text-foreground/55",
state === "error" && "border-destructive bg-destructive text-destructive-foreground",
state === "waiting" && "border-signal bg-signal text-signal-foreground",
@@ -88,7 +88,7 @@ export function ActivityIcon({
</span>
{state === "running" && (
<span
- className="absolute -right-0.5 -top-0.5 h-1.5 w-1.5 animate-pulse border border-background bg-phosphor-ink motion-reduce:animate-none"
+ className="absolute -right-0.5 -top-0.5 h-1.5 w-1.5 animate-pulse border border-background bg-foreground motion-reduce:animate-none"
aria-hidden="true"
/>
)}
diff --git a/apps/screenpipe-app-tauri/components/chat/standalone/message-content.activity-icons.test.tsx b/apps/screenpipe-app-tauri/components/chat/standalone/message-content.activity-icons.test.tsx
index 927093ee9..b180e6213 100644
--- a/apps/screenpipe-app-tauri/components/chat/standalone/message-content.activity-icons.test.tsx
+++ b/apps/screenpipe-app-tauri/components/chat/standalone/message-content.activity-icons.test.tsx
@@ -83,11 +83,38 @@ describe("MessageContent — semantic activity widget", () => {
'[data-activity-kind="test"][data-activity-state="running"]',
);
expect(errorIcon).toHaveClass("bg-destructive");
- expect(runningIcon).toHaveClass("bg-phosphor");
+ expect(runningIcon).toHaveClass("bg-foreground", "text-background");
+ expect(runningIcon).not.toHaveClass("bg-phosphor");
expect(screen.getByText("Loaded PDF skill")).toBeTruthy();
expect(screen.getByText("failed")).toBeTruthy();
});
+ it("keeps a running git commit activity monochrome", () => {
+ render(
+ <MessageContent
+ message={messageWithTools([
+ tool("commit", "bash", {
+ args: { command: "git commit -m 'fix tool activity color'" },
+ isRunning: true,
+ }),
+ ])}
+ isGenerating
+ />,
+ );
+
+ const summaryIcon = screen.getByTestId("tool-activity-running-indicator");
+ expect(summaryIcon).toHaveAttribute("data-activity-kind", "edit");
+ expect(summaryIcon).toHaveClass("bg-foreground", "text-background");
+ expect(summaryIcon).not.toHaveClass("bg-phosphor");
+
+ fireEvent.click(screen.getByTestId("tool-activity-summary"));
+ const rowIcon = screen
+ .getByTestId("tool-activity-list")
+ .querySelector('[data-activity-kind="edit"][data-activity-state="running"]');
+ expect(rowIcon).toHaveClass("bg-foreground", "text-background");
+ expect(rowIcon).not.toHaveClass("bg-phosphor");
+ });
+
it("marks an unrecovered completed failure on both the widget and row", () => {
render(
<MessageContent
diff --git a/docs/pr-assets/tool-call-active-color/after-dark.png b/docs/pr-assets/tool-call-active-color/after-dark.png
new file mode 100644
index 000000000..40b658b85
Binary files /dev/null and b/docs/pr-assets/tool-call-active-color/after-dark.png differ
diff --git a/docs/pr-assets/tool-call-active-color/after-light.png b/docs/pr-assets/tool-call-active-color/after-light.png
new file mode 100644
index 000000000..30d7745bc
Binary files /dev/null and b/docs/pr-assets/tool-call-active-color/after-light.png differ
diff --git a/docs/pr-assets/tool-call-active-color/before-dark.png b/docs/pr-assets/tool-call-active-color/before-dark.png
new file mode 100644
index 000000000..47e9fbce7
Binary files /dev/null and b/docs/pr-assets/tool-call-active-color/before-dark.png differ
diff --git a/docs/pr-assets/tool-call-active-color/before-light.png b/docs/pr-assets/tool-call-active-color/before-light.png
new file mode 100644
index 000000000..a794e69c1
Binary files /dev/null and b/docs/pr-assets/tool-call-active-color/before-light.png differ