-
Notifications
You must be signed in to change notification settings - Fork 46
🤖 feat: add Coder as separate runtime button #2012
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
d4148fe to
c8d4eef
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d4148fe23e
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
- Add Coder runtime choice in UI (maps to SSH + coder config internally) - Remove 'Use Coder Workspace' checkbox from SSH flow - Coder button only renders when CLI is confirmed available (no flash) - Disable Coder button in non-git projects (same as worktree) - Add 'Default for project' checkbox to Coder tooltip (maps to SSH) - Split CoderControls into reusable components (availability message, form) - Add resolveCoderAvailability helper for consistent availability logic - Avoid persisting CODER_RUNTIME_PLACEHOLDER as last SSH host
- Make Coder a first-class UI choice while keeping it SSH under the hood - Fix default runtime checkbox to persist Coder config correctly - Add SshRuntimeConfig helper to consolidate coderEnabled/coderConfig fields - Simplify CreationControls runtime button state resolution - Remove verbose RUNTIME_AVAILABILITY_KEY map in favor of inline ternary
f632588 to
a3da646
Compare
|
@codex review |
|
Codex Review: Didn't find any major issues. Chef's kiss. ℹ️ About Codex in GitHubCodex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback". |
- Fix storybook tests to use new Coder button pattern (not SSH→checkbox) - Extract RuntimeConfigInput component for SSH host/Docker image inputs - Extract CredentialSharingCheckbox component for Docker/Devcontainer - Extract hasTemplateDuplicateName helper to consolidate 3 duplicate checks - Update story descriptions to match new UI behavior
Summary
Adds Coder as a dedicated runtime button in the UI (alongside Local, Worktree, SSH, Docker, Devcontainer), removing the old "Use Coder Workspace" checkbox from the SSH flow. No backend/IPC changes—Coder remains mapped internally to SSH mode with coder config.
Background
Users asked for Coder to be a first-class runtime choice rather than a hidden checkbox within SSH settings. This aligns Coder UX with devcontainer: the button only renders once CLI availability is confirmed (no flash), and is disabled in non-git projects.
Implementation
RuntimeChoicetype: Union ofRuntimeMode | "coder"for UI-only representationresolveCoderAvailabilityhelper: Centralizes CLI state logic (loading/outdated/unavailable/available); onlyavailableshows the buttonCoderControls: New exportsCoderAvailabilityMessage,CoderEnableToggle,CoderWorkspaceFormfor flexible renderingRuntimeMode.SSH)CODER_RUNTIME_PLACEHOLDERexcluded fromlastSshHost; Coder config persists separatelyFiles changed:
src/browser/utils/runtimeUi.ts— Coder UI metadatasrc/browser/components/ChatInput/CoderControls.tsx— Split components + availability helpersrc/browser/components/ChatInput/CreationControls.tsx— Coder button in RuntimeButtonGroupsrc/browser/components/ChatInput/index.tsx— Coder config change handlingsrc/browser/hooks/useDraftWorkspaceSettings.ts— Placeholder exclusiondocs/runtime/coder.mdx— Updated instructionsValidation
make typecheckandmake lintpassGenerated with
mux• Model:anthropic:claude-opus-4-5• Thinking:high• Cost:$20.36