fix(chat): preserve pasted user message newlines - #353
Open
AlphaCatMeow wants to merge 3 commits into
Open
Conversation
AlphaCatMeow
marked this pull request as ready for review
August 1, 2026 02:13
Contributor
|
PR governance checks passed. Awaiting human review. |
AlphaCatMeow
marked this pull request as draft
August 1, 2026 02:14
Normalize logical line endings once across paste, draft, send, history, and user bubble rendering. Add mirrored GUI/WebUI pipeline coverage for DOM serialization, replay, cross-client parity, and visual blank-line spacing.
AlphaCatMeow
force-pushed
the
codex/fix-paste-newline-serialization
branch
from
August 5, 2026 17:08
bcbd4a5 to
8d74b7c
Compare
AlphaCatMeow
marked this pull request as ready for review
August 5, 2026 17:10
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.
Linked issue
Closes #352
Depends-On: none
Stack-Root: #353
Summary
DIV/P/placeholderBRnodes without double-counting blank lines.Change scope
agent-guiReact UI, Gateway WebUI, mirror verification, frontend testscrates/agent-gui/src/components/chat/MentionComposer.tsxcrates/agent-gui/src/lib/chat/composerText.tscrates/agent-gui/src/lib/chat/messages/userMessageContent.tsxcrates/agent-gateway/web/src/components/chat/MentionComposer.tsxcrates/agent-gateway/web/src/lib/chat/composerText.tscrates/agent-gateway/web/src/lib/chat/userMessageContent.tsxNo Rust, Go, protocol, database, dependency, lockfile, or generated-code changes.
Rebase and diff audit
upstream/main@00a2c6fcon 2026-08-06.upstream/main...HEAD= 0 behind / 3 ahead).GatewayApp.tsx,useSendChatTurn.ts, andscripts/mirror-manifest.jsonwere explicitly audited to preserve current-main behavior while adding only newline fidelity support.bb060885and final PR head differ only indocs/worklog/paste-newline-serialization.md.Screenshots / preview
Production-module runtime preview for
alpha\n\nbeta:white-spacepre-wrappre-wrapThe attached PNG below uses the actual production composer and
UserMessageContentmodules and shows the five-stage escaped text/counts, sent bubble, and history/reconnect replay without user session data.Verification
upstream/main@00a2c6fc:node scripts/check-mirror.mjs: 116 files passedgit diff --check upstream/main..HEAD: passedOpen PR overlap
MentionComposer.tsxfiles.Pre-submit checklist