Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,12 @@
- The script discovers the server with `opencode service status`, injects its private local credential from `opencode service get password`, and uses the `dev` TUI storage channel so tabs and other client-local state match the installed client.
- Prefer `dev:live` over plain `bun run dev` for this workflow. An implicit managed-service connection may replace the live server when the worktree client version differs; explicit `--server` warns and continues without replacing it.

## Live Desktop Diagnostics

- When attaching Playwright to a running desktop app, use `chromium.connectOverCDP(endpoint, { noDefaults: true })`.
- Without `noDefaults`, Playwright applies light-mode media emulation during attachment. An app following the system theme then flashes light until the connection closes. The option also preserves the existing focus and other media preferences.
- Do not emulate a color scheme or reduced-motion preference on the user's live window unless explicitly requested; use an isolated test context for those scenarios.

## TUI Stories

- When a user asks for a TUI story, add a fixture-driven story under `packages/tui/src/feature-plugins/system/storybook` and register it in `index.tsx`.
Expand Down
3 changes: 2 additions & 1 deletion packages/app/e2e/performance/devex/desktop-startup.ts
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,8 @@ function startDesktop(profile: Awaited<ReturnType<typeof createColdProfile>>) {
}),
])

browser = await chromium.connectOverCDP(url, { timeout: 120_000 })
// Observe the native appearance and focus instead of applying Playwright's media defaults.
browser = await chromium.connectOverCDP(url, { timeout: 120_000, noDefaults: true })
const context = browser.contexts()[0]

if (!context) throw new Error("Electron did not expose a browser context")
Expand Down
Loading