Repository navigation
bug(ui): long default system notes are clipped at both edges #5138
Description
What happened
Long system_note diagnostics in the Desktop transcript are rendered as a single centered, non-wrapping line. When the text is wider than the chat reading measure, both ends overflow and are clipped, so the user can read only the middle of the message.
The reported zh-CN screenshot contains two separate affected notes. Their complete source copy begins and ends as follows:
供应商在丢弃或改写上下文:... 让 Maka 先行压缩。
本次交换用了约 129127 tokens,... 若希望回复保持完整,可调大窗口。
In the rendered transcript, the first visible line starts around 改写上下文 and ends around 让 Ma; the second starts around 用了约 129127 and loses its ending. There is no horizontal scrollbar or other way to reveal the omitted text.
This is separate from #5137. That issue tracks the incorrect remediation inside context_provider_dropping; this issue tracks the shared rendering behavior that makes long default system notes unreadable regardless of their semantics.
Expected: diagnostic system notes remain fully readable at the normal Desktop reading measure and at narrower widths. Long notes should wrap within the available width without horizontal scrolling or clipped prefixes/suffixes. Short divider-style status notes should keep their existing presentation.
How to reproduce
- Open a Desktop conversation using the
zh-CNlocale. - Reach a turn that records
context_provider_droppingand/orcontext_window_overrun, or render either current localized string as a defaultChatSystemMessageinside the normal 800 px chat reading measure. - Inspect the transcript.
Observed: the note stays on one centered line and both ends are clipped.
The rendering chain on current main is deterministic:
packages/ui/src/materialize.tsmaterializes these records as ordinary visible system notes.packages/ui/src/chat-turn.tsxsends non-compaction notes toChatSystemMessagewithvariant="default".- Astryx
ChatSystemMessagecenters its contents and gives the default content spandisplay: inline-flex,flex-shrink: 0, andwhite-space: nowrap. - Astryx
ChatLayoutsetsoverflow-x: hiddenon the scrollable transcript root. - Maka constrains a turn to
--maka-reading-measure: 800px.
Together, these rules create an oversized unshrinkable line centered inside a narrower container, then hide the overflow on both sides. The short context_compacted divider visible in the same screenshot is unaffected because it uses the separate divider variant and fits within the measure.
Environment
- Maka commit:
a9b4f21afb17e0ef310d076382e69ddda3a441d7 - OS: Ubuntu Linux x86_64, kernel
7.0.0-30-generic - Surface: Desktop
- Locale:
zh-CN - Node.js:
v26.3.0
Logs, screenshots, or additional context
No overlapping open issue or PR was found using searches for system note clipped, system message overflow, and system note nowrap.
Suggested regression coverage:
- a long zh-CN default system note at the standard Desktop reading measure;
- a long English default system note and a narrower responsive width;
- assertions that the full prefix and suffix are reachable/readable and that no horizontal scroll is required;
- preservation of the current short default and divider presentations.
Activity
testikun commentedon Sep 10, 2026
take
HuYellow commentedon Sep 15, 2026
Hi @testikun — are you still working on this issue? I saw your
takecomment and wanted to check before pursuing overlapping work.We have a local CSS fix and focused Chromium verification, but have not submitted a PR. If you are still working on it, we will leave the issue with you and can share the findings if useful. If you have moved on, please let us know whether you would be comfortable with us taking it over. We will work on another issue in the meantime.
Posted with OpenAI Codex assistance on behalf of @HuYellow.