Repository navigation
Commit c42975f
feat(web): fold settled turn work behind a Worked-for collapsible
Codex-style turn folding in the chat timeline, derived entirely from
existing client-side data (no backend changes):
- Settled turns collapse their commentary messages and tool work log
behind a 'Worked for Xs' row anchored where the turn's work begins;
the terminal assistant message stays visible below the fold. Clicking
the row toggles the hidden history.
- The active turn is never folded — live commentary and collapsed tool
groups render exactly as before, with the working timer still at the
bottom.
- An interrupted latest turn folds with 'You stopped after Xs' (state
comes from latestTurn, the only turn whose interruption survives in
client data). Pressing stop leaves that turn expanded so the user
keeps their place; the next turn or a reload folds it.
- The completion divider ('Worked for ...' between hairlines) is
replaced by the fold row; deriveCompletionDividerBeforeEntryId,
completionSummary plumbing, and hasToolActivityForTurn are removed.
- Work log entries now carry turnId (from the underlying activity) so
tool activity can be attributed to a turn's fold.
- Commentary (non-terminal assistant) rows lose the reserved metadata
spacing.
Folding concept ported from PR #2962 (stale, full-stack, Codex-specific
assistantPhase plumbing) reimplemented web-only per discussion.
Co-Authored-By: Claude Fable 5 <[email protected]>1 parent 4b1a774 commit c42975f
8 files changed
Lines changed: 483 additions & 256 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
53 | | - | |
54 | 53 | | |
55 | 54 | | |
56 | 55 | | |
| |||
61 | 60 | | |
62 | 61 | | |
63 | 62 | | |
64 | | - | |
65 | 63 | | |
66 | | - | |
67 | 64 | | |
68 | 65 | | |
69 | 66 | | |
| |||
1521 | 1518 | | |
1522 | 1519 | | |
1523 | 1520 | | |
1524 | | - | |
1525 | | - | |
1526 | | - | |
1527 | | - | |
1528 | 1521 | | |
1529 | 1522 | | |
1530 | 1523 | | |
| |||
1859 | 1852 | | |
1860 | 1853 | | |
1861 | 1854 | | |
1862 | | - | |
1863 | | - | |
1864 | | - | |
1865 | | - | |
1866 | | - | |
1867 | | - | |
1868 | | - | |
1869 | | - | |
1870 | | - | |
1871 | | - | |
1872 | | - | |
1873 | | - | |
1874 | | - | |
1875 | | - | |
1876 | | - | |
1877 | | - | |
1878 | | - | |
1879 | | - | |
1880 | | - | |
1881 | 1855 | | |
1882 | 1856 | | |
1883 | 1857 | | |
| |||
3889 | 3863 | | |
3890 | 3864 | | |
3891 | 3865 | | |
3892 | | - | |
3893 | | - | |
| 3866 | + | |
3894 | 3867 | | |
3895 | 3868 | | |
3896 | 3869 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
57 | 57 | | |
58 | 58 | | |
59 | 59 | | |
60 | | - | |
61 | | - | |
| 60 | + | |
62 | 61 | | |
63 | 62 | | |
64 | 63 | | |
| |||
415 | 414 | | |
416 | 415 | | |
417 | 416 | | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
| 435 | + | |
| 436 | + | |
| 437 | + | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
| 443 | + | |
| 444 | + | |
| 445 | + | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
| 473 | + | |
| 474 | + | |
| 475 | + | |
| 476 | + | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
| 481 | + | |
| 482 | + | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
| 490 | + | |
418 | 491 | | |
0 commit comments