feat: 聊天历史加载动画支持#578
Merged
Merged
Conversation
从聊天历史打开对话时添加加载过渡页: - 模拟进度条(渐近99%,永久不停止,不设超时) - 实时百分比显示 - 8秒后显示"仍在加载中…"提示 - 叉叉取消按钮(右上角) - API 完成后跳转100%,400ms后淡出进入对话 - getSession / loadSession 支持 AbortSignal - React Strict Mode 双挂载兼容 Co-Authored-By: Claude <[email protected]>
pancacake
added a commit
that referenced
this pull request
Jun 23, 2026
Rework of the #578 loading overlay: - Replace the simulated rAF percentage bar (which climbed to a fake 99% over ~24s, unrelated to real load progress) with an honest indeterminate spinner + 'Loading conversation…' message and an 8s 'Still loading…' hint. - Collapse the null/loading/complete state machine to a single boolean and drop the artificial 400ms completion delay, so the conversation appears the moment the fetch resolves. - Fix a stray ')' in the cancel button's className that voided its hover color, and remove the now-redundant width-transition/rAF conflict. - Drop the dead 'server is taking too long' locale key (no timeout path uses it). The AbortSignal plumbing (getSession/loadSession + cancel button) and the Strict-Mode-safe initial-load ref are kept as-is. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Collaborator
|
Merged into |
vaskoyudha
added a commit
to vaskoyudha/deeptutor-for-programmer-fork
that referenced
this pull request
Jul 25, 2026
feat: loading overlay for chat-history navigation Shows a clear loading indicator (with cancel) while a session is fetched from chat history, replacing the misleading welcome-screen flash. Threads an AbortSignal through getSession/loadSession so the load is cancelable. Followed by a rework that swaps the simulated progress bar for an honest indeterminate spinner and drops the artificial completion delay. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
vaskoyudha
added a commit
to vaskoyudha/deeptutor-for-programmer-fork
that referenced
this pull request
Jul 25, 2026
Rework of the HKUDS#578 loading overlay: - Replace the simulated rAF percentage bar (which climbed to a fake 99% over ~24s, unrelated to real load progress) with an honest indeterminate spinner + 'Loading conversation…' message and an 8s 'Still loading…' hint. - Collapse the null/loading/complete state machine to a single boolean and drop the artificial 400ms completion delay, so the conversation appears the moment the fetch resolves. - Fix a stray ')' in the cancel button's className that voided its hover color, and remove the now-redundant width-transition/rAF conflict. - Drop the dead 'server is taking too long' locale key (no timeout path uses it). The AbortSignal plumbing (getSession/loadSession + cancel button) and the Strict-Mode-safe initial-load ref are kept as-is. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
概述
从聊天历史点击对话时,添加加载过渡页,避免白屏等待。
改动
web/components/chat/home/SessionLoadingView.tsxweb/app/(workspace)/home/[[...sessionId]]/page.tsxweb/context/UnifiedChatContext.tsxloadSession增加 AbortSignal 参数web/lib/session-api.tsgetSession增加 AbortSignal 参数web/locales/en/app.jsonweb/locales/zh/app.json功能
Screenshots
🤖 Generated with Claude Code