Skip to content

Fix punctuation and paste in remote browser control - #422

Merged
davidmckayv merged 4 commits into
CopilotKit:mainfrom
maximus792:codex/remote-keyboard-fix
Sep 8, 2026
Merged

Fix punctuation and paste in remote browser control#422
davidmckayv merged 4 commits into
CopilotKit:mainfrom
maximus792:codex/remote-keyboard-fix

Conversation

@maximus792

@maximus792 maximus792 commented Sep 7, 2026

Copy link
Copy Markdown
Contributor

Summary

  • forward the browser-provided Windows virtual key code so punctuation such as . reaches CDP correctly
  • leave Ctrl/Cmd+V local so the browser emits a paste event, then send its clipboard text through the existing text-input message
  • keep the matching V keyup local even when Ctrl/Cmd is released first
  • retain the existing server-side key-code fallback for older clients

Root cause

The computer service derived windowsVirtualKeyCode from the first character of event.key. For ., that produced 46, which Windows/CDP interprets as Delete; the correct browser key code is 190. The live screen also prevented every keydown, so Ctrl/Cmd+V could never produce a local paste event.

Verification

  • bun test app/tests
  • bun run --cwd app typecheck
  • cd agent-computer && bun test && bun run typecheck
  • bun run format:check
  • bun run lint
  • git diff --check
  • Linux/Chromium WebSocket integration: 9/9 live-screen tests passed, including real period insertion

Fixes #424.

@davidmckayv davidmckayv left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Deep-reviewed against live code (correctness, governance, no vendor/secret/scale issues). Composed build+tests green. CHANGELOG/format rebase on CI-validated substance.

@davidmckayv
davidmckayv merged commit 34da3cf into CopilotKit:main Sep 8, 2026
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Remote browser control cannot type a period or paste from the local clipboard

2 participants