Repository navigation
🤖 fix: one main landmark in immersive review and on pages without a workspace - #5999
Merged
Merged
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. |
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
#5967 gave the workspace page one
mainlandmark, inside the chat pane. Immersive review hides the chat pane, and the pages with no workspace have no chat pane at all, so those layouts had nomainlandmark. This PR makes the primary view of each of those layouts itsmain. Every one now has exactly one, and the pages look the same as before.Fixes #5969
Changes
Each production file changes only its root element from
<div>to<main>and adds one comment. Classes and props are unchanged.mainImmersiveReviewViewroot (portaled into#review-immersive-root)ImmersiveReviewView.tsx/)RootRouteShellApp.tsxProjectPagerootProjectPage.tsxScratchPagerootScratchPage.tsxinertandaria-hidden, so itsmainleaves the accessibility tree. The immersive view is then the page's onlymain.ImmersiveReviewView'scontainerRefwidens fromHTMLDivElementtoHTMLElement. It is only used forfocus()andquerySelector.WorkspaceShell.tsxis not touched.Validation
App.seededWorkspaceA11y.stories.tsxcover immersive review and the root, project and scratch pages, each at desktop width and at 390 px (fixed-width wrapper plusglobals.viewport, Pixel disabled). Each play asserts exactly onerole="main"that contains the layout's content, and contains neither navigation "Projects", nor complementary "Workspace insights", norcontentinfo. On main, all 8 fail with "Unable to find role="main"".main, and its other landmarks are unchanged.landmark-one-mainpasses), but its setup cannot reach the pages this PR fixes, so the stories above are the evidence for the fix.make check-react-compilerreports 23/24 (the 1 known skip isProjectSidebarInner).ImmersiveReviewViewstill compiles.App/MemoryIntuition(a story these files do not render). That story then passed 3 of 3 runs on its own on this branch and 3 of 3 with main's versions of the 4 files, and two full reruns passed.Notes
mainin desktop immersive review. Its<aside>(complementary) was a top-level landmark and now sits inside the immersive view'smain. ARIA allows a complementary landmark insidemain. axe's best-practice rulelandmark-complementary-is-top-levelflags it.App.tsx), and the "Loading workspace..." and "No Workspace Selected" placeholders (WorkspaceShell.tsx) still have nomainlandmark. 🤖 a11y: main landmark missing in loading and placeholder states #5998 tracks them, after the perf work that editsWorkspaceShell.tsxlands.Screenshots
These show this branch. They are pixel-identical to main.
Generated with
xum• Model:anthropic:claude-opus-5-5• Thinking:high• Cost:$75.86