Summary This commit addresses two critical issues affecting the real-time chat experience in the Playground: 1. Optimized re-rendering of reasoning content • Added `reasoningContent` to the comparison function of `OptimizedMessageContent` (`web/src/components/playground/OptimizedComponents.js`). • Ensures the component re-renders while reasoning text streams, resolving the bug where only the first characters (“好,”) were shown until the stream finished. 2. Defensive checks for SSE message updates • Added early-return guards in `streamMessageUpdate` (`web/src/hooks/useApiRequest.js`). • Skips updates when `lastMessage` is undefined or the last message isn’t from the assistant, preventing `TypeError: Cannot read properties of undefined (reading 'status')` during rapid SSE responses. Impact • Real-time reasoning content now appears progressively, enhancing user feedback. • Eliminates runtime crashes caused by undefined message references, improving overall stability.
| Name |
Last commit
|
Last Update |
|---|---|---|
| .. | ||
| ChatArea.js | Loading commit data... | |
| CodeViewer.js | Loading commit data... | |
| ConfigManager.js | Loading commit data... | |
| CustomInputRender.js | Loading commit data... | |
| CustomRequestEditor.js | Loading commit data... | |
| DebugPanel.js | Loading commit data... | |
| FloatingButtons.js | Loading commit data... | |
| ImageUrlInput.js | Loading commit data... | |
| MessageActions.js | Loading commit data... | |
| MessageContent.js | Loading commit data... | |
| OptimizedComponents.js | Loading commit data... | |
| ParameterControl.js | Loading commit data... | |
| SettingsPanel.js | Loading commit data... | |
| ThinkingContent.js | Loading commit data... | |
| configStorage.js | Loading commit data... | |
| index.js | Loading commit data... |