Skip to content

fix(tui): last table row missing in markdown rendering #13855

@mocksoul

Description

@mocksoul

Bug

The last row of markdown tables is always missing after message streaming completes.

Reproduction

  1. Enable OPENCODE_EXPERIMENTAL_MARKDOWN=true
  2. Ask the AI to output a markdown table with 3+ data rows
  3. After streaming completes, the last row is not visible

Root cause

Two issues work together:

  1. opencode: TextPart passes streaming={true} unconditionally to <markdown> and <code> elements — even for completed messages
  2. opentui: During streaming, the last table row is skipped (rows.slice(0, -1)) as potentially incomplete. When streaming changes to false, updateBlocks() skips the table because tokenRaw hasn't changed — the missing row is never added back

Fix

Metadata

Metadata

Assignees

Labels

opentuiThis relates to changes in v1.0, now that opencode uses opentui

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions