fix(dock): auto-close after unpinning ended process - #105
Merged
Conversation
WHY: The /ps overview unpin path forced the dock open and rendered directly, bypassing the existing auto-close rule when every managed process had ended. HOW: Route COMMAND_PIN with a null id through hardRefresh after clearing focus, and cover both the no-live-process and remaining-live-process paths with colocated regression tests. WHAT: Unpinning the last finished process now clears the stale dock while unpinning with another live process keeps aggregate logs visible; unit, E2E, type, lint, changeset, schema, lockfile, and diff checks pass.
Owner
|
Thanks for this! |
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.
Summary
Fix the process dock remaining visible after an ended process is unpinned from the
/psoverview.Context
The overview sends
COMMAND_PINwithid: nullwhen toggling off the pinned process. That handler cleared the focus and forced the dock toexpanded, but rendered directly instead of applying the existing auto-close rule.Closes #104.
Changes
hardRefresh()after overview unpin.Testing
pnpm vitest run extensions/processes-dock/widget/setup.test.ts— 4 passed.pnpm test— 642 passed.pnpm test:e2e— 10 passed.pnpm typecheckpnpm lintpnpm check:changesetspnpm check:schemapnpm check:lockfilegit diff --checkUser impact / Release notes
Unpinning the last finished process from
/psnow removes the stale dock frame. If another process is still running, the dock remains visible and returns to aggregate logs.Notes for reviewers
The behavioral change is in the
COMMAND_PINnull branch insetupDockWidgets; the two regression cases are inwidget/setup.test.ts.