diff --git a/.codex/environments/environment.toml b/.codex/environments/environment.toml deleted file mode 100644 index 23e3d526d..000000000 --- a/.codex/environments/environment.toml +++ /dev/null @@ -1,21 +0,0 @@ -# THIS IS AUTOGENERATED. DO NOT EDIT MANUALLY -version = 1 -name = "CodexMonitor" - -[setup] -script = "npm install" - -[[actions]] -name = "Tests" -icon = "test" -command = ''' -npm run typecheck -npm run lint -npm run test -cd src-tauri && cargo check -''' - -[[actions]] -name = "Run" -icon = "run" -command = "npm run tauri dev" diff --git a/.eslintrc.cjs b/.eslintrc.cjs index c7234ffd0..e4206a6f1 100644 --- a/.eslintrc.cjs +++ b/.eslintrc.cjs @@ -40,169 +40,5 @@ module.exports = { { files: ['**/*.ts', '**/*.tsx'], }, - { - files: [ - 'src/features/workspaces/components/*Prompt.tsx', - 'src/features/git/components/BranchSwitcherPrompt.tsx', - 'src/features/threads/components/RenameThreadPrompt.tsx', - 'src/features/settings/components/SettingsView.tsx', - ], - rules: { - 'no-restricted-syntax': [ - 'error', - { - selector: - "JSXOpeningElement[name.name='div'] > JSXAttribute[name.name='role'][value.value='dialog']", - message: - 'Use `ModalShell` for modal dialog shell markup instead of `
`.', - }, - { - selector: - "JSXOpeningElement[name.name='div'] > JSXAttribute[name.name='aria-modal']", - message: - 'Use `ModalShell` for modal dialog shell markup instead of manually setting `aria-modal`.', - }, - { - selector: - "JSXOpeningElement[name.name='div'] > JSXAttribute[name.name='className'][value.value=/\\b[a-z0-9-]*modal-(overlay|backdrop|window|card)\\b/]", - message: - 'Modal shell chrome belongs in `ModalShell`; avoid legacy `*-modal-overlay/backdrop/window/card` wrappers.', - }, - { - selector: - "Literal[value=/#[0-9A-Fa-f]{3,8}|rgba?\\(|hsla?\\(/]", - message: - 'Avoid hardcoded color literals in DS-targeted components; use design-system CSS variables/tokens.', - }, - ], - }, - }, - { - files: [ - 'src/features/git/components/GitDiffPanel.tsx', - 'src/features/files/components/FileTreePanel.tsx', - 'src/features/prompts/components/PromptPanel.tsx', - ], - rules: { - 'no-restricted-syntax': [ - 'error', - { - selector: "JSXOpeningElement[name.name='aside']", - message: 'Use `PanelFrame` instead of raw `
@@ -225,7 +225,7 @@

From repo to review in three moves.

01

Connect your workspaces

-

Codex Monitor runs one shared Codex app-server and restores your threads across workspaces.

+

Codex Monitor spawns a Codex app-server per repo and restores your threads.

02 @@ -412,7 +412,7 @@

Ready to monitor every agent run?

Codex Monitor app icon Codex Monitor
-

Desktop Codex agent orchestration, built by and for individuals who ship fast.

+

macOS Codex agents orchestration, built by and for individuals who ship fast.

); } diff --git a/src/features/app/components/LaunchScriptButton.tsx b/src/features/app/components/LaunchScriptButton.tsx index 85284b48a..43897c29d 100644 --- a/src/features/app/components/LaunchScriptButton.tsx +++ b/src/features/app/components/LaunchScriptButton.tsx @@ -1,7 +1,6 @@ +import { useEffect, useRef } from "react"; import Play from "lucide-react/dist/esm/icons/play"; import type { LaunchScriptIconId } from "../../../types"; -import { PopoverSurface } from "../../design-system/components/popover/PopoverPrimitives"; -import { useMenuController } from "../hooks/useMenuController"; import { LaunchScriptIconPicker } from "./LaunchScriptIconPicker"; import { DEFAULT_LAUNCH_SCRIPT_ICON } from "../utils/launchScriptIcons"; @@ -54,15 +53,26 @@ export function LaunchScriptButton({ onNewDraftLabelChange, onCreateNew, }: LaunchScriptButtonProps) { - const editorMenu = useMenuController({ - open: editorOpen, - onDismiss: () => { + const popoverRef = useRef(null); + const hasLaunchScript = Boolean(launchScript?.trim()); + + useEffect(() => { + if (!editorOpen) { + return; + } + const handleClick = (event: MouseEvent) => { + const target = event.target as Node; + if (popoverRef.current?.contains(target)) { + return; + } onCloseEditor(); onCloseNew?.(); - }, - }); - const { containerRef: popoverRef } = editorMenu; - const hasLaunchScript = Boolean(launchScript?.trim()); + }; + window.addEventListener("mousedown", handleClick); + return () => { + window.removeEventListener("mousedown", handleClick); + }; + }, [editorOpen, onCloseEditor, onCloseNew]); return (
@@ -83,7 +93,7 @@ export function LaunchScriptButton({
{editorOpen && ( - +
Launch script
- - -
- {showSuggested && ( -
-
Suggested
-
- - + +
+ {showSuggested && ( +
+
Suggested
+
+ + + +
+ )} + {error &&
{error}
} +
+ +
- )} - {error &&
{error}
} -
- -
- +
); } diff --git a/src/features/workspaces/components/MobileRemoteWorkspacePrompt.tsx b/src/features/workspaces/components/MobileRemoteWorkspacePrompt.tsx deleted file mode 100644 index 472f53cfc..000000000 --- a/src/features/workspaces/components/MobileRemoteWorkspacePrompt.tsx +++ /dev/null @@ -1,65 +0,0 @@ -import { useEffect, useRef } from "react"; -import { ModalShell } from "../../design-system/components/modal/ModalShell"; - -type MobileRemoteWorkspacePromptProps = { - value: string; - error: string | null; - onChange: (value: string) => void; - onCancel: () => void; - onConfirm: () => void; -}; - -export function MobileRemoteWorkspacePrompt({ - value, - error, - onChange, - onCancel, - onConfirm, -}: MobileRemoteWorkspacePromptProps) { - const textareaRef = useRef(null); - - useEffect(() => { - textareaRef.current?.focus(); - }, []); - - return ( - -
-
Add project directories
-
- Enter directories on the connected server. -
- -