feat: enable Computer Use on Windows and Linux (#145)

Remove macOS-only guards so Computer Use works cross-platform:
- main.tsx: allow CHICAGO_MCP on any known platform (not just macos)
- swiftLoader.ts: remove darwin-only throw, let the backend handle it
- computer-use-input: dispatch to darwin/win32/linux backends
- computer-use-swift: rename loadDarwin→loadBackend, dispatch all platforms

Co-authored-by: yi7503 <yi7503@gmail.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
yi7503
2026-04-06 09:57:55 +08:00
committed by GitHub
parent 0da5ec09e8
commit 522a1a366d
4 changed files with 22 additions and 13 deletions

View File

@@ -7,9 +7,6 @@ let cached: ComputerUseAPI | undefined
* Non-darwin platforms should use src/utils/computerUse/platforms/ instead.
*/
export function requireComputerUseSwift(): ComputerUseAPI {
if (process.platform !== 'darwin') {
throw new Error('@ant/computer-use-swift is macOS-only. Use platforms/ for cross-platform.')
}
if (cached) return cached
// eslint-disable-next-line @typescript-eslint/no-require-imports
const mod = require('@ant/computer-use-swift')