fix(canvas/a11y+tests): aria-hidden backdrop, verifiedCPSession guard, useCanvasStore mock normalization - #1961
Merged
HongmingWang-Rabbit merged 5 commits intoApr 24, 2026
Conversation
molecule-ai
Bot
force-pushed
the
feat/canvas-activitytab-missingkeys-tests
branch
from
April 24, 2026 03:02
6d28ebd to
45bc8a9
Compare
…ck conflict Cherry-pick from #1744 left the backdrop div without aria-hidden="true" (the outer dialog div got it instead). Re-apply aria-hidden="true" to the backdrop div so screen readers skip the clickable overlay layer. Also revert test assertion from bg-black → bg-black/70 to match the exact class applied to the backdrop div.
Standardize the mock for useCanvasStore to always expose getState() (used by production ContextMenu to filter parent nodes). Applies the same Object.assign-wrapping pattern introduced in #1744 to: - ClaudeSettings.test.tsx - tabs.a11y.test.tsx - ContextMenu.keyboard.test.tsx (mockStore shape alignment)
… alias The PR #1855 branch contains a newer version of session_auth.go that renamed verifiedCPSession → VerifiedCPSession (exported) but also left the already-exported definition in place, causing a duplicate declaration compile error (line 174 and line 238 both declare VerifiedCPSession). Fix: restore the internal func as verifiedCPSession (unexported) and keep the public alias wrapper VerifiedCPSession at line 238 which delegates to it — preserving the exported API that discovery.go and wsauth_middleware.go depend on. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
The short-var declaration inside the if-initializer scoped `presented`
only to that if statement, making it undefined on the following
`if presented { ... }` block. Move it to a plain assignment so it
remains accessible in the enclosing function scope.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
molecule-ai
Bot
force-pushed
the
feat/canvas-activitytab-missingkeys-tests
branch
from
April 24, 2026 03:10
45bc8a9 to
8fb5ec0
Compare
AllKeysModal already handles focus via autoFocus={index === 0} on the
first input and a separate title-focus effect. The orphaned useEffect
referencing firstInputRef (declared only in ProviderPickerModal) caused
a TypeScript build error: "Cannot find name 'firstInputRef'".
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Contributor
Author
|
CI fix applied — Canvas (Next.js) build was failing with: Root cause: a stale Fix: removed the stale 5-line |
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
aria-hiddenon canvas backdrop div after cherry-pick conflict resolutionverifiedCPSession, keep backward-compatible public aliasuseCanvasStoremock pattern across canvas test files (fixes GH#1740 keyboard context menu test)presentedvar must live in function scope, not block scopeChanges
canvas/src/components/Canvas/useWindowEvents.ts— aria-hidden on backdropworkspace-server/handlers/middleware.go— verifiedCPSession rename + aliascanvas/src/__tests__/— useCanvasStore mock normalizationworkspace-server/handlers/— Go scoping fix forpresentedvariableTest plan
pnpm testin canvas (useCanvasStore mock normalization)go test ./handlers/...in workspace-server (verifiedCPSession)aria-hidden="true"<button type="button">🤖 Generated with Claude Code