Repository navigation
Replies: 1 comment
|
Adding what I found while narrowing this down, plus a mock of the current UI. The target already exists. The right-panel store's case 'file': return typeof n.relativePath === 'string'
&& (n.revealLine === null || Number.isSafeInteger(n.revealLine))
&& Number.isSafeInteger(n.revealRequestId) && ...So "open this file at this line" is a supported operation, and Where the wiring stops. The thread card ( let b = r.line === null ? r.path : `${r.path}:${r.line}`;
jsx('span', { className: 'min-w-0 truncate font-mono', children: b })and threads That is the whole gap: one prop carrying three meanings, and the file header getting none of them. The diagrams above are mocks of the current layout, not screenshots of a real repository: paths and comments are generic placeholders. |
Uh oh!
There was an error while loading. Please reload this page.
What is missing
In the Summary and Timeline tabs of a pull request, a review thread's file location is rendered as plain text. Clicking it does nothing, so there is no way to get from a comment to the code it is about.
Concretely: a thread on
peer-backend/cmd/peer-api/internal/larkhook/privatecard.go:203shows the headeras a
<span>with noonClick, nohref, and no keyboard affordance. The whole card toggles collapsed/expanded when clicked, and that is the only interaction it offers. The Code tab is fine — inline threads are already attached to their diff line, so nothing needs to jump.Why it matters
Reading a review is mostly "what did they say about this line, and what does that line actually do". Without a jump, every comment in Summary is a dead end: copy the path, find the file by hand, scroll to the line. On a large PR with a dozen threads that is the whole review workflow.
This affects every host, not just one provider. I hit it on a self-hosted GitLab-like host (a
glab-compatible provider), and the same<span>renders for gitlab.com, GitHub, and Bitbucket because the card component is provider-agnostic.What I would expect
Clicking the
path:lineheader opens that file at that line in the file viewer (the same destination as "Open in file viewer" on a workspace-file attachment), or, when the file is not in the current checkout, falls back to opening the comment on the host.Worth noting: the component already receives an
onOpenprop, but it is wired toshell.openExternal, i.e. external URLs only. For commits the same prop receives the SHA. So the plumbing for "open something from a timeline event" exists — it just has no local-file case.Steps to reproduce
path:lineheader of a thread.Expected: the file opens at that line. Actual: nothing happens.
Environment
T3 Code
0.1.9-nightly.20261110.4465, macOS, MR with 9 positioned review threads.All reactions