Skip to content

[Bug]: Fenced code blocks corrupt Android user-message bubble layout #5048

Description

@D-Gaspa

Before submitting

  • I searched existing issues and did not find a duplicate.
  • I included a minimal deterministic reproduction and control cases.

Area

apps/mobile on Android.

The current issue form does not list apps/mobile, so this report would otherwise use "Not sure."

Steps to reproduce

  1. Open the official T3 Code Android app with the default appearance settings.
  2. Create a fresh thread.
  3. Send this user message:
Reply only with OK.

```
alpha
beta
```
  1. Observe the rendered user-message bubble.

The problem also reproduces when the fence is labeled text or bash.

A single-message reproduction that makes the role difference visible is:

Reply with exactly one fenced code block containing two lines: alpha and beta. Do not put a language label after the opening fence.
Just like this:
```
alpha
beta
```
Output nothing else.

In that case, the fence embedded in the user message renders incorrectly, while the assistant's fenced response directly below it renders correctly.

Expected behavior

A fenced code block in a user message should size itself to its content, remain contained within the user-message bubble, and not overlap surrounding prose or message metadata.

User and assistant fenced blocks may use different colors, but both should have stable readable layout.

Actual behavior

Any fenced code block tested inside an Android user message corrupts the bubble layout:

  • The code surface becomes much taller than its content.
  • Prose overlaps the code-block header and content.
  • Text following the fence can render outside the bubble.
  • The timestamp and subsequent timeline content can be displaced or overlapped.

Assistant fenced code blocks render normally in the same app and thread.

Reproduction matrix

Message role No language label text bash
User Fails Fails Fails
Assistant Passes Passes Passes

Each case was tested in a fresh thread.

This isolates the problem to fenced blocks in user-message rendering rather than Bash syntax, a particular fence language, or fenced content generally.

Impact

Major degradation or frequent failure.

Prompts containing fenced examples can make the user message and surrounding thread content unreadable. This is common when asking an agent to transform, explain, or reproduce Markdown/code.

Version or commit

Android app 0.1.0, OTA 019fb32.

Environment

  • Official Android mobile app
  • Default appearance settings
  • Exact device model and Android OS version not yet recorded

Logs or stack traces

No relevant logs observed. This appears to be a client-side layout/rendering issue.

Workaround

Avoid literal fenced blocks in user prompts. Describe the desired fenced output in prose instead. Assistant responses containing fenced blocks render correctly.

Related issue

#4582 tracks Android monospace font fallback in code surfaces. It does not describe oversized user-message code blocks, overlapping content, or role-specific layout corruption, so this appears distinct.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions