From a71f20dd18153420fa5a72ac1554e1a8412a644b Mon Sep 17 00:00:00 2001 From: Brooklyn Nicholson Date: Sat, 1 Aug 2026 11:37:44 -0500 Subject: [PATCH] feat(desktop): copy the branch-bar worktree path on hover Tiny copy glyph next to the hover-revealed cwd. Same reveal as the path, copies the real absolute path via the existing file-actions helper. --- .../chat/composer/status-stack/coding-row.tsx | 36 ++++++++++++++----- 1 file changed, 27 insertions(+), 9 deletions(-) diff --git a/apps/desktop/src/app/chat/composer/status-stack/coding-row.tsx b/apps/desktop/src/app/chat/composer/status-stack/coding-row.tsx index 32b21952db..5682fb82b5 100644 --- a/apps/desktop/src/app/chat/composer/status-stack/coding-row.tsx +++ b/apps/desktop/src/app/chat/composer/status-stack/coding-row.tsx @@ -17,6 +17,7 @@ import type { HermesGitBranch } from '@/global' import { useI18n } from '@/i18n' import { displayPath } from '@/lib/display-path' import { registerRepoStatusCwd, repoStatusForCwd, repoWorktreesForCwd } from '@/store/coding-status' +import { copyFilePath } from '@/store/file-actions' import { notifyError } from '@/store/notifications' import { $newWorktreeRequest } from '@/store/projects' @@ -63,6 +64,7 @@ export const CodingStatusRow = memo(function CodingStatusRow({ const { t } = useI18n() const s = t.statusStack.coding const p = t.sidebar.projects + const fileMenu = t.fileMenu const resolvedRepoPath = repoPath?.trim() || undefined // This surface's OWN worktree, always — never the primary's. The row used to // fall back to the global `$repoStatus` for a blank repoPath, which painted @@ -238,16 +240,32 @@ export const CodingStatusRow = memo(function CodingStatusRow({ - {/* Worktree path — plain muted text, not a chip. Always in the flex - so hover doesn't reflow the row; opacity alone reveals it. - `displayPath` collapses home → ~ (shell / VS Code convention). */} + {/* Worktree path + copy — plain muted text, not a chip. Always in the + flex so hover doesn't reflow the row; opacity alone reveals the + pair. `displayPath` collapses home → ~; copy still takes the + real absolute path. */} {resolvedRepoPath && ( - - {displayPath(resolvedRepoPath)} - +
+ + {displayPath(resolvedRepoPath)} + + +
)} {/* Branch actions kebab — same pattern as the session/worktree rows.