Commit f951d4f
committed
fix(ui): prevent content vanishing on streaming completion
Three changes to fix scroll position loss when streaming ends:
1. Eliminate double completeStreamingMessage - ChatWidget now checks
if message is still streaming before calling completeStreamingMessage
again; if already completed by orchestrator, uses updateMessage to
add performance metrics without triggering full finalization
2. Streaming completion scroll uses scroll-bottom-anchor instead of
message ID with .bottom anchor, and delay increased from 50ms to
150ms to allow layout to settle after ProgressView removal and
metrics addition
3. Remove content trimming in completeStreamingMessage to prevent
cache invalidation cascade (content hash change -> getCachedClean
miss -> displayedContent update -> MarkdownContentView re-parse)1 parent 17fa7cb commit f951d4f
2 files changed
Lines changed: 30 additions & 17 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
260 | 260 | | |
261 | 261 | | |
262 | 262 | | |
263 | | - | |
| 263 | + | |
264 | 264 | | |
265 | 265 | | |
266 | 266 | | |
| |||
305 | 305 | | |
306 | 306 | | |
307 | 307 | | |
308 | | - | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
309 | 311 | | |
310 | 312 | | |
311 | 313 | | |
| |||
331 | 333 | | |
332 | 334 | | |
333 | 335 | | |
334 | | - | |
| 336 | + | |
335 | 337 | | |
336 | 338 | | |
337 | | - | |
| 339 | + | |
338 | 340 | | |
339 | 341 | | |
340 | 342 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1279 | 1279 | | |
1280 | 1280 | | |
1281 | 1281 | | |
1282 | | - | |
1283 | | - | |
1284 | | - | |
| 1282 | + | |
| 1283 | + | |
| 1284 | + | |
1285 | 1285 | | |
1286 | | - | |
| 1286 | + | |
1287 | 1287 | | |
1288 | | - | |
1289 | | - | |
| 1288 | + | |
| 1289 | + | |
| 1290 | + | |
1290 | 1291 | | |
1291 | 1292 | | |
1292 | 1293 | | |
| |||
4037 | 4038 | | |
4038 | 4039 | | |
4039 | 4040 | | |
4040 | | - | |
4041 | | - | |
4042 | | - | |
4043 | | - | |
4044 | | - | |
4045 | | - | |
4046 | | - | |
| 4041 | + | |
| 4042 | + | |
| 4043 | + | |
| 4044 | + | |
| 4045 | + | |
| 4046 | + | |
| 4047 | + | |
| 4048 | + | |
| 4049 | + | |
| 4050 | + | |
| 4051 | + | |
| 4052 | + | |
| 4053 | + | |
| 4054 | + | |
| 4055 | + | |
| 4056 | + | |
| 4057 | + | |
4047 | 4058 | | |
4048 | 4059 | | |
4049 | 4060 | | |
| |||
0 commit comments