* 🧵 feat(client): Make the Flat Thread Renderer the Default
The flat message-thread renderer becomes the default; the recursive
MultiMessage path stays reachable with VITE_FLAT_THREAD=false at build
time or LC_FLAT_THREAD=false in localStorage as an escape hatch.
* 🧪 test(e2e): Differential Check of the Two Thread Renderers
Builds one conversation through the real pipeline with the content shapes
the seeded benchmarks never produce (a regenerated branch, reasoning,
markdown with a table and code, a provider attachment) and one with
detached subagent activity, then renders each with the flat list and the
recursive tree in turn. Both must produce the same transcript, sibling
counters, attachments and activity groups, before and after cycling a
branch. Also adds a benchmark config that runs the tree lane against the
built client for production-minified numbers.
* 🧵 feat(client): Flat Message Thread Renderer Behind a Flag
Adds a keyed thread index and an O(depth) visible-path resolver so the
message list can render as a flat, memoized list instead of one React
level per message. The recursive MultiMessage path stays the default;
the flat path is enabled per page with the LC_FLAT_THREAD localStorage
key or VITE_FLAT_THREAD at build time.
Also adds a react-scan/CDP benchmark lane (e2e/benchmarks-tree) that
A/Bs both render paths on a seeded 240-row thread, plus a parity config
that runs the branch-sensitive mock specs with the flat path on.
* 🙈 chore: Ignore the Tree Benchmark Output Directory
* 🪢 refactor(client): Move Sibling Selection to Feature-Owned Jotai State
Codex round 1 on #15633. The message thread's sibling selection moves out
of the Recoil store into a Jotai atom family owned by the thread feature,
shared by the recursive and flat renderers, the share view, and the focus,
resume and clear writers. Consumers that watch several branch points read
them through one derived atom via useSyncExternalStore, so a token-only
cache write costs no render.
Also keeps the raw cache object as a thread row's reuse identity (file
hydration now happens on the row, keyed on the file map), sets the flat
flag before the parity config snapshots the server env, and gives the
seeded alternate branch consistent turn numbers.
* 🧹 style: Sort Imports in the Thread Renderer Files
* 📏 chore(e2e): Sample Renderer CPU and Post-GC Heap in the Tree Benchmark
Adds a CDP resource probe to each phase: renderer-process CPU time (all
threads), JS heap after a forced GC (retained memory rather than allocation
churn), DOM node and listener counts. Also lets TREE_PARITY_MATCH pick
which mock specs the parity config runs, and derives the deep-switch
phase label from the seeded thread size.