fix: reserve Windows titlebar chrome space for Code actions
This commit is contained in:
@@ -0,0 +1,51 @@
|
||||
# Task: Fix Windows coding titlebar logo overlap
|
||||
|
||||
## Identity
|
||||
|
||||
- Task ID: 20260915-windows-logo-overlap-5106511f
|
||||
- Mode: Feature
|
||||
- Branch: codex/20260915-windows-logo-overlap-5106511f-windows-logo-overlap
|
||||
- Worktree: D:\Datas\OthersProjects\.codex-worktrees\makelore\20260915-windows-logo-overlap-5106511f
|
||||
- Base commit: a39fbc1619470ad8d47a1b9131b2cada5b940ec5
|
||||
- Owner: codex
|
||||
- Status: Ready for Integration
|
||||
|
||||
## Scope
|
||||
|
||||
- Reproduce and fix the Windows Code titlebar overlap between the Makelore wordmark and the developer-browser toggle. Cover the actual Renderer geometry with the shared Electron fixture.
|
||||
|
||||
## Intent And Constraints
|
||||
|
||||
- Concurrent Task Gate passed: bundled check/start/status succeeded and match this task's feature mode, branch, isolated worktree and base commit. Main is occupied by the platform-embedding integration task; all task operations remain in this linked worktree.
|
||||
- Planning Gate passed after reading the agent entry and memory index, own task record, positioning, integrated state, decision index, system overview, business rules, success criteria, evidence index and previous Windows titlebar integration record.
|
||||
- Read the Scope, Intent And Constraints and Promotion Candidates of the 200 registered peers. No concrete semantic conflict with this narrow layout correction was found. Several older peer records remain planning placeholders; their coordination scope is unknown. Do not modify them.
|
||||
- Project positioning contains placeholders and some shared history describes retired modules. Use current AGENTS.md and implementation for product boundaries. The old titlebar source record is absent; its readable integration record documents the existing 148 px Windows control reservation.
|
||||
- Keep the light visual system, Main-owned browser contract, platform chrome behavior and Code/Pi configuration boundaries. No subagents, package, deployment or unrelated cleanup.
|
||||
- Plan: reproduce browser/wordmark geometry overlap in Electron, isolate the responsible spacing, make a narrow correction, then run related unit tests, typecheck, lint, build and Electron layout/interaction checks.
|
||||
|
||||
## Outcome
|
||||
|
||||
- Reproduced the reported Windows Code overlap against the built Electron app twice: the browser button ended at x=1084 while the wordmark started at x=1036. The minimized layout regression failed in 1.7 seconds before the fix.
|
||||
- Root cause: CodingConversationHeader used the macOS-sized 160 px padding for both custom-titlebar platforms. Windows chrome needs 148 px for caption controls plus 96 px for the wordmark, so browser and run actions occupied the wordmark region.
|
||||
- Shared the existing wordmark/caption dimensions in `src/components/layout/titlebar-metrics.ts`. Windows now ends the portaled conversation header at the wordmark boundary and retains its ordinary 12 px inner padding. This reserves space for all actions and keeps their hit area outside caption controls. macOS keeps its existing 160 px padding, and Linux keeps its inline header.
|
||||
- Updated README's platform-specific titlebar description. No backend, runtime, persistence, application identity or canonical-memory change.
|
||||
- Added a Windows Electron regression for geometry, browser open/close, sidebar collapse, active/settled run states, minimum window width, 125% zoom and real maximize/restore interaction. The existing broad Code UI test also checks browser/wordmark separation.
|
||||
|
||||
## Verification
|
||||
|
||||
- Toolchain: exact pinned pnpm 10.33.4; `pnpm install --frozen-lockfile` passed without lockfile changes.
|
||||
- Red: `pnpm exec playwright test tests/e2e/pi-coding-first-chat.spec.ts --grep 'Windows Code titlebar' --reporter=list` failed on the actual overlapping button bounds before the fix. The earlier existing-UI assertion independently reproduced the same coordinates.
|
||||
- Green: the same focused Electron command passed in 4.3 seconds. It covers 1280 px, the application's actual minimum of 1024 px, and 1280 px at 125% content zoom; browser open/closed; sidebar collapsed; running/idle; caption-control hit testing and maximize/restore. The initial test attempt used unsupported 1000 px and was corrected after confirming Main's 1024 px minimum; this was a fixture expectation, not a product defect.
|
||||
- `pnpm exec playwright test tests/e2e/pi-coding-first-chat.spec.ts --grep 'PI feature UI isolates' --reporter=list`: passed on the fixed production build, including existing browser and Conversation interaction assertions.
|
||||
- Related unit tests: `title-bar.test.tsx`, `coding-chat-panel.test.tsx`, `agent-browser-panel.test.tsx`: 3 files / 42 tests passed.
|
||||
- `pnpm run typecheck`, scoped ESLint for all changed TypeScript files, `pnpm run build:vite` (Renderer/Main/Preload/utility), and `git diff --check`: passed.
|
||||
- Visually inspected the default-size Electron screenshot at `test-results/pi-coding-first-chat-Windo-0b8c4-he-logo-and-window-controls/windows-code-titlebar.png`: browser and stop controls, wordmark and caption controls occupy separate regions. Screenshot/build outputs remain ignored.
|
||||
- No full unit suite or packaged/installed-client verification was run; the focused tests cover the changed Renderer seam. No temporary product instrumentation was introduced.
|
||||
|
||||
## Follow-ups
|
||||
|
||||
- Integrate this source branch and rebuild the Windows client for the installed application to receive the correction. This task does not merge main, push or package.
|
||||
|
||||
## Promotion Candidates
|
||||
|
||||
- None. This restores the existing titlebar separation contract; the README already records the platform-specific behavior.
|
||||
Reference in New Issue
Block a user