Files
pipelines/android/app
alan d7f650032d Render assistant text as markdown in the chat transcript
Add a dependency-free CommonMark-subset parser/renderer (ui/chat/Markdown.kt):
paragraphs, headings, fenced code, block quotes, bullet/ordered lists, tables,
thematic rules and inline code/bold/italic/links/autolinks. The renderer turns
blocks into themed, selectable Compose content: fenced code reuses the shared
CodeBlock (existing whole-block copy action), tables are a bordered grid with a
bold header, links use LinkAnnotation.Url, and inline code/headings use the
shared type roles.

ChatScreen.MessagePart now calls MarkdownText(part.text) for PART_TEXT instead
of a single plain Text; the assistant message stays one SelectionContainer, so
all of it remains selectable and long content stays inside the bubble. Geometry
reuses the chat tokens (CHAT_ITEM_GAP promoted private -> internal).

Add MarkdownTest with 10 unit tests covering fences/language, unterminated
fences, soft-wrap joining, headings/rules, lists, tables, inline spans, bare-URL
autolinks and snake_case non-emphasis. Document the change in android/README.md.
2026-10-16 13:01:39 +01:00
..