Commit 026bc91
fix(messages): restore newest-first default ordering in message list
The default topic message view (non-continuous pagination, "Newest"
origin, last-50) rendered rows in raw backend/stream order rather than
newest-first, so messages were not sorted by timestamp descending as
users expect.
Client-side sort was only applied in the narrow
`continuousPaginationEnabled && startOffset === EndMinusResults` case,
introduced in #2229. The default paginated path fell through to the
unsorted list.
Apply a stable newest-first sort (timestamp desc, then offset desc as a
cross-partition tiebreak) to the full loaded set before client-side
pagination, so page 1 of a last-50 fetch shows the globally newest rows.
Header click still overrides via the sorted row model.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>1 parent 7ee42a0 commit 026bc91
1 file changed
Lines changed: 17 additions & 6 deletions
Lines changed: 17 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
572 | 572 | | |
573 | 573 | | |
574 | 574 | | |
575 | | - | |
576 | | - | |
577 | | - | |
578 | | - | |
579 | | - | |
580 | | - | |
| 575 | + | |
| 576 | + | |
| 577 | + | |
| 578 | + | |
| 579 | + | |
| 580 | + | |
| 581 | + | |
| 582 | + | |
| 583 | + | |
| 584 | + | |
| 585 | + | |
| 586 | + | |
| 587 | + | |
| 588 | + | |
| 589 | + | |
| 590 | + | |
| 591 | + | |
581 | 592 | | |
582 | 593 | | |
583 | 594 | | |
| |||
0 commit comments