| Merge upstream/main into pr_25: resolve conflict, adopt atomgit-bot review fixes Conflict resolution: - apps/web/package.json: keep cytoscape deps (per maintainer) AND add the PR's d3-force/d3-drag/d3-zoom/d3-selection/d3-transition deps; adopt upstream's @science-agent -> @sciencediscovery scope rename for the schema workspace dep. No files left with @science-agent imports after the merge carried upstream's rename through. Adopt atomgit-bot P2 review suggestions (both blocked CI): - P2#1 (EDGE_COLORS keys): MemoryGraphCanvas.tsx still used the pre-rename edge keys extracted_from/cites/states while the schema (and every other consumer) had already renamed them to extracts/supports/stated_in. Record<MemoryGraphEdgeType,string> with extra+missing keys failed typecheck (root cause of CI UT FAILED). Restore extracts/supports/stated_in. - P2#2 (fitAll viewport): fitAll used build-time closure width/height instead of ResizeObserver-updated ref.width/ref.height, so resize and zero-size-first-paint fit on stale dimensions. Switch to ref.width/height. P3 cleanups: - Remove dead chain.viewRelatedSubTasks/collapseSubTasks/collapsedCount/ expand i18n keys (en+zh) and .memory-paper-chain-row CSS (no consumers). - Add missing .memory-canvas-node.search-hit CSS rule the canvas applies at line 807 so search hits actually highlight. Tests: - New apps/web/tests/MemoryGraphCanvas.test.tsx locks the contract that EDGE_COLORS/NODE_COLORS keys exactly match the schema unions (the P2#1 regression), plus graphNodeName truncation/basename/priority-order and graphNodeDisplayNames #n suffixing. Verified: typecheck 0 errors, web test 379/379 pass, build green. | 1 个月前 |