Auto-close bead on PR merge detection#53
Merged
Conversation
When usePRStatus polling detects a merged PR and the worktree still exists, automatically trigger cleanup (delete worktree + branch + close bead) instead of requiring a manual "Clean Up" click. Uses a useRef guard to prevent duplicate triggers. Shows a toast notification for auto-triggered cleanups. Manual button remains as fallback. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Add tooltip explaining why button is disabled when bead status is not "inreview". Uses Radix Tooltip with span wrapper for disabled button hover events. Only shows tooltip content when status prevents action. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes beads-kanban-ui-62n
When usePRStatus polling detects a PR with state='merged', automatically trigger the cleanup flow (delete worktree + delete branch + bd close) instead of requiring the user to manually click 'Clean Up'. The Rust backend delete_worktree endpoint already handles the full chain (worktree removal, branch deletion, bead close). The frontend just needs to auto-trigger it when merged state is detected. Files: src/components/bead-detail.tsx (merge detection + auto-cleanup trigger).