Skip to content

Fix chat composer lag in long threads - #119

Open
Yuqing (mydmdm) wants to merge 3 commits into
mainfrom
fix/issue-115
Open

Fix chat composer lag in long threads#119
Yuqing (mydmdm) wants to merge 3 commits into
mainfrom
fix/issue-115

Conversation

@mydmdm

Copy link
Copy Markdown
Contributor

Summary

  • isolate the thread-local draft subscription inside a dedicated composer boundary so typing does not rerender ChatPanel or message history
  • memoize the message list and unchanged user, assistant, and Milkdown message cards while preserving streaming updates
  • cache textarea resize style metrics and avoid redundant style writes
  • add direct-input and Chinese IME regression coverage plus a real-browser 0-vs-200-message input-to-paint benchmark
  • document the composer/history render boundary

Validation

  • pnpm format
  • pnpm lint:fix
  • pnpm typecheck
  • targeted Vitest suite: 7 passed
  • Playwright composer benchmark: direct and Chinese IME p95 ~16.8 ms for both 0 and 200 messages; history delta ~0 ms

Fixes #115

Yuqing (mydmdm) and others added 3 commits August 19, 2026 13:30
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Chat composer typing lags as thread history grows

1 participant