Skip to content

fix(sidebar): show PR state on cloud task icons, stop constant pulse#2346

Open
richardsolomou wants to merge 1 commit into
mainfrom
posthog-code/cloud-icon-precedence
Open

fix(sidebar): show PR state on cloud task icons, stop constant pulse#2346
richardsolomou wants to merge 1 commit into
mainfrom
posthog-code/cloud-icon-precedence

Conversation

@richardsolomou
Copy link
Copy Markdown
Member

@richardsolomou richardsolomou commented May 25, 2026

Problem

The ph-pulse animation ran for the whole in_progress window, so every active cloud task looked permanently busy. And the isCloudTask short-circuit in TaskIcon hid PR, diff, suspended, unread, and pinned state on non-terminal cloud tasks, so a cloud task with an open PR did not get the green PR icon a local task would.

Changes

  • Pulse only on queued. in_progress renders as a steady filled accent icon.
  • Drop the early isCloudTask return so PR/diff/suspended/unread/pinned state takes precedence over the cloud icon.
  • Cloud tasks with a cloudPrUrl now show the same green/purple GitPullRequest/GitMerge icon as local tasks (hasDiff amber branch still requires a local worktree).

How did you test this?

pnpm --filter code typecheck and pnpm lint pass. I did not run the desktop app, so the new icons are not visually verified.

Publish to changelog?

no

`in_progress` covers the entire time a cloud run is alive on the backend, including when the agent is idle waiting for the next user message. The `ph-pulse` animation on that state made every active cloud task look like it was constantly doing something, and the local "agent is generating right now" signal (`isPromptPending` → `DotsCircleSpinner`) was already handling the real "active" affordance.

Two changes:

- Pulse only on `queued` (genuinely transient, usually a few seconds). `in_progress` renders as a steady filled accent cloud/Slack icon.
- Drop the cloud short-circuit in `TaskIcon` so cloud tasks share the same precedence as local: needsPermission → terminalCloud → isGenerating → isSuspended → isUnread → PR/diff → isPinned → `CloudStatusIcon` (non-terminal) → originProductMeta → `ChatCircle`. Cloud tasks with an open PR now show the PR icon, with a diff show the branch icon, suspended show the pause icon, etc. — same as local tasks.

Generated-By: PostHog Code
Task-Id: b95e757c-ba51-444c-978c-27c02e740d85
@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented May 25, 2026

Reviews (1): Last reviewed commit: "fix(sidebar): stop pulsing cloud icon fo..." | Re-trigger Greptile

@richardsolomou richardsolomou requested a review from a team May 25, 2026 05:06
@richardsolomou richardsolomou changed the title fix(sidebar): stop pulsing cloud icon for the whole in_progress window fix(sidebar): only pulse cloud task icons when queued May 25, 2026
@richardsolomou richardsolomou changed the title fix(sidebar): only pulse cloud task icons when queued fix(sidebar): show PR state on cloud task icons, stop constant pulse May 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant