fix(desktop): correct Agent Graph collapse chevron direction - #3466
Conversation
Astro-Han
left a comment
There was a problem hiding this comment.
Thanks — this is the smallest correct fix at the existing disclosure-state seam. I reviewed exact head e3225248f02d675029971801a9385482fb15a002; aria-expanded, rendered content, and the collapsed data attribute stay under one state owner, and the current-head test check is green. I found no P0–P2 issues; one optional visual-regression hardening note is inline.
AI-assisted review disclosure: OpenAI Codex performed an independent exact-head review. I verified the state/CSS mapping, focused tests, live review state, mergeability, and current-head CI, and I independently made the approval decision.
e322524 to
78911a8
Compare
Astro-Han
left a comment
There was a problem hiding this comment.
Thanks for chasing this down — the chevron pointing the wrong way is one of those things that quietly makes a panel feel broken, and the actual fix is exactly right: the rotation belongs on the collapsed state, not the expanded one.
My comments are entirely about the 122 lines of test added around that one-line change, not about the change.
The short version is that CI is currently red on this PR, and what is failing is the new e2e itself — electron e2e/agent-graph-chevron-smoke.mjs exits non-zero in the Desktop e2e job. So as it stands the instrument added to protect a one-line CSS fix is the thing keeping the fix out of the tree. That is worth weighing directly rather than debugging around.
There is also a deeper problem with that smoke test that I would raise even if it were green, and it is the one I would most like you to look at: it loads agent-graph.css on its own into a bare data: URL with a hand-written <button>, so it verifies the rule in isolation. The regression it exists to catch — this rule losing to something else, or the markup drifting — happens in the real cascade with the app's full stylesheet and the real component. A test that cannot fail for the scenario it is guarding against is not paying for its cost, and this one costs a real Electron process per run.
getComputedStyle(...).transform === 'matrix(-1, 0, 0, -1, 0, 0)' also pins Chromium's matrix serialization rather than the intent. Rewriting the rule as rotate(-180deg) would be visually identical and would fail this assertion.
I am not asking you to add heavier coverage — the opposite. For a one-line CSS direction fix, I think the honest options are to keep the small jsdom assertion, or to accept that this class of bug is caught by looking at it. Both seem better than an Electron process that is red today and blind to the real failure mode.
No [P0]/[P1] — the product change is correct.
Review assisted by AI (Claude Opus 5). Findings were verified against the files and the failing CI run at this head; the reviewer is accountable for them.
78911a8 to
2e3f300
Compare
|
Rebased onto current Local validation: Desktop workspace dependencies and main process build passed, the existing Agent Graph panel suite passed 14/14 before the unrelated added case was removed, Desktop typecheck passed, and lint, format, ASF header, and diff checks are clean. New CI is now pending on head |
|
Update: the rebased head is mergeable and has no unresolved review threads. Its new CI run is currently |
Summary
Testing
The concurrent Desktop suite reached 1059/1061. The unrelated Git Review and MCP runtime failures both passed when rerun independently.
Closes #3407.