Two contributing layout issues in the chat message bubble:
1. MessageRow's content VStack (icon + text HStack) had no
.frame(maxWidth: .infinity), so it sized to its content's ideal
width instead of the space actually available.
2. swift-markdown-ui renders paragraphs with mixed inline styling
(bold/italic runs next to plain text) as concatenated Text(+)
segments, which on macOS report their ideal unwrapped single-line
size for height purposes instead of wrapping — truncating with "…"
regardless of window width. Plain single-style paragraphs (a single
Text) weren't affected, which is why some lines wrapped fine and
others didn't.
Fixed by adding .frame(maxWidth: .infinity, alignment: .leading) to
the MessageRow content stack, and .fixedSize(horizontal: false,
vertical: true) to the markdown paragraph label so height is
recomputed for the width actually given instead of the ideal width.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>