GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
GeezerVison is showing github.com — feat(site): list every PR in the top bar by DanielleMaywood · Pull Request #29545 · coder/coder Conversation
|
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Here are some automated review suggestions for this pull request.
Reviewed commit: 14252937a9
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| onSelect={() => { | ||
| if (status.url) { | ||
| window.open(status.url, "_blank", "noreferrer"); | ||
| } |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Use anchors for the PR menu entries
When a chat has multiple PRs, these rows are generic Radix menu items that call window.open instead of links. Users consequently lose standard link behaviors such as inspecting or copying the destination and using the browser's context menu or middle-click, while assistive technology cannot expose the destination as a link. Render each DropdownMenuItem with asChild around an <a href={status.url} target="_blank" rel="noreferrer">, matching existing dropdown links in the repository.
Useful? React with 👍 / 👎.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Fixed in 68e2a11. Each entry is now <DropdownMenuItem asChild> around <a href={status.url} target="_blank" rel="noreferrer"> holding the existing icon and label, matching the repo's other dropdown links. The onSelect/window.open path is gone, so middle-click, copy-link, and the context menu work and assistive tech gets the destination. The test now asserts each menuitem carries its PR's href.
Generated by Coder Agents
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| // The PR chip in the top bar. On mobile it shows the number, on | ||
| // desktop the title. |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Remove the comment that restates PrLink
This comment only repeats the component's name and narrates the two responsive spans immediately below it, without documenting a non-obvious constraint or tradeoff. Remove it to comply with FE4's prohibition on comments that restate identifiers or control flow.
AGENTS.md reference: site/AGENTS.md:L10-L10
Useful? React with 👍 / 👎.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Fixed in 68e2a11. The PrLink comment is removed. The larger JSX block comment above the PR-link section was also narration under the same rule, except for one line: it kept only the sidebar-panel hiding constraint (hidden on desktop while the panel is open), which is the non-obvious part behind the lg:hidden classes.
Generated by Coder Agents
Sorry, something went wrong.
There was an error while loading. Please reload this page.
1425293 to
50e8b0a
Compare
50e8b0a to
bc7742d
Compare
7c4e854 to
38d6d3a
Compare
38d6d3a to
c02bba6
Compare
c02bba6 to
e4b4e1e
Compare
d6aed39 to
06ad63d
Compare
|
@codex review |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Here are some automated review suggestions for this pull request.
Reviewed commit: 68e2a11c62
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| // destination is announced. | ||
| expect( | ||
| within(menu).getByRole("menuitem", { name: /PR #123/ }), | ||
| ).toHaveAttribute("href", "https://github.com/coder/coder/pull/123"); |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Replace href assertions with observable behavior coverage
This new test uses toHaveAttribute as its only outcome, so it verifies rendered DOM rather than an observable callback, request, or state change. FE1 requires userEvent-driven tests to assert the non-visual effect of the interaction; exercise the selected entry and assert its navigation effect instead of inspecting href.
AGENTS.md reference: site/AGENTS.md:L7-L7
Useful? React with 👍 / 👎.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Keeping the assertion. The href value is the entire behavioral contract of an external target="_blank" anchor: jsdom implements no navigation, so there is no callback, request, or state change to assert instead. The query is semantic (getByRole("menuitem", { name: /PR #123/ })) and the assertion is value-bearing, not DOM presence. This matches existing repo practice, such as the skip-link destination in DashboardLayout.test.tsx.
This reply was generated by Coder Agents.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| }; | ||
|
|
||
| const mockPRStatuses = [ | ||
| { |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Compose the story statuses from the shared fixture
This story re-declares complete ChatDiffStatus entities even though MockChatDiffStatus already exists in testHelpers/chatEntities; these copies can silently drift when the generated API shape or standard fixture changes. Import the shared fixture and create the two named variants by spreading it, as required by FE9.
AGENTS.md reference: site/AGENTS.md:L15-L15
Useful? React with 👍 / 👎.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Leaving these shapes as they are. The single-PR story rows are pre-stack data carried over unchanged: they mirror rows written before pr_number (migration 000437) and pull_request_state backfills existed, which is why the component recovers the number from the URL (prNumber falls back to parsePullRequestUrl). Spreading MockChatDiffStatus would inject pr_number, remote_origin, and state: "open", switching those stories onto the modern-row path and dropping the URL-fallback coverage. mockPRStatuses is a named local variant under FE9; both rows differ from the shared fixture.
This reply was generated by Coder Agents.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| {/* The number keeps every item distinguishable when | ||
| two PRs share a title. */} | ||
| <span className="truncate"> | ||
| {`PR #${prNumber(status)} ${status.pull_request_title}`} |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Include the repository in cross-origin PR labels
When a chat tracks repositories with the same PR number and title, both menu entries receive the identical visible and accessible label even though they open different URLs, so users cannot tell which repository they are selecting. Multiple origins are a supported state and GitPanel already detects it and prefixes originRepoLabel; apply the same distinction here.
Useful? React with 👍 / 👎.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Fixed in f1f3fa9. originRepoLabel moved to site/src/pages/AgentsPage/utils/ and is shared with the git panel. The top bar menu now prefixes each entry with the repository name when the tracked PRs span multiple origins, so two origins carrying the same PR number stay distinguishable by accessible name. Covered by a test with two origins sharing PR #123 and a WithCrossOriginPRs screenshot state.
This reply was generated by Coder Agents.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
bf514bf to
4469e78
Compare
Sorry, something went wrong.
There was an error while loading. Please reload this page.
f1f3fa9 to
96fbdeb
Compare
|
This pull request was merged after its branch was accidentally flattened, so the merged diff does not contain the changes. The same work now lives in #29831. Coder Agents generated this comment. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.