fix(frontend): prevent user message bubble overflow with long unbreakable strings - #3488
Conversation
|
@SnapLap thanks for your contribution. Please fix the lint error and here are some review comments on the PR.
Suggestion: Consider scoping the overflow change to user messages only:
Suggestion: Apply w-full max-w-full conditionally: |
…able strings - Add max-w-full min-w-0 to user message wrapper div to constrain width - Change bubble width from w-fit to w-full max-w-full for consistent layout - Add break-words to user message content for long string wrapping - Add overflow-x-clip as defensive overflow protection
7311e91 to
8920a5e
Compare
|
@WillemJiang Thanks for the detailed review! All three points addressed in this update: 1. 2. 3. |
…able strings (bytedance#3488) - Add max-w-full min-w-0 to user message wrapper div to constrain width - Change bubble width from w-fit to w-full max-w-full for consistent layout - Add break-words to user message content for long string wrapping - Add overflow-x-clip as defensive overflow protection Co-authored-by: Willem Jiang <willem.jiang@gmail.com>
…able strings (bytedance#3488) - Add max-w-full min-w-0 to user message wrapper div to constrain width - Change bubble width from w-fit to w-full max-w-full for consistent layout - Add break-words to user message content for long string wrapping - Add overflow-x-clip as defensive overflow protection Co-authored-by: Willem Jiang <willem.jiang@gmail.com>
…able strings (bytedance#3488) - Add max-w-full min-w-0 to user message wrapper div to constrain width - Change bubble width from w-fit to w-full max-w-full for consistent layout - Add break-words to user message content for long string wrapping - Add overflow-x-clip as defensive overflow protection Co-authored-by: Willem Jiang <willem.jiang@gmail.com>
…able strings (bytedance#3488) - Add max-w-full min-w-0 to user message wrapper div to constrain width - Change bubble width from w-fit to w-full max-w-full for consistent layout - Add break-words to user message content for long string wrapping - Add overflow-x-clip as defensive overflow protection Co-authored-by: Willem Jiang <willem.jiang@gmail.com>
fix(frontend): prevent user message bubble overflow with long unbreakable strings
Fixes #3484
Why
用户输入包含长不可换行字符串(如
=====================================、长 URL、无空格连续字符)时,用户消息气泡会被内容无限撑宽,超出页面容器导致页面出现横向滚动条。触发场景:用户粘贴长代码注释分隔线、长 URL、连续符号等无换行机会的字符串。
What changed
Surface area
backend/applanggraph.json, or prompt changedocker/or sandboxed executionskills/backend/pyproject.tomlorfrontend/package.json(say what it buys us)Screenshots / Recording
改动后的代码块或Markdown文本可以正常展示


Bug fix verification
=号)复现Validation