You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maka.apache.org by "Astro-Han (via GitHub)" <gi...@apache.org> on 2026/08/27 09:18:08 UTC

[PR] fix(desktop): let transcript prose reach the turn column edge [maka]

Astro-Han opened a new pull request, #3997:
URL: https://github.com/apache/maka/pull/3997

   ## Summary
   
   An assistant turn had two right edges. The turn column is `--maka-transcript-measure` (800px), and the tool cards, code blocks and the user bubble all reach it — but every paragraph stopped 120px short, leaving a band of whitespace down the right side of the transcript that is wider on a wider window.
   
   The cause is two reading-measure authorities. Maka's column owns one, and Astryx's `Markdown` quietly owns another: `contentWidth` defaults to 680px with `contentAlign: 'start'`, while code and tables are left to fill the container. #3617 raised the column from 680 to 800 so source evidence could be read, which made the second authority visible for the first time.
   
   `MarkdownBody` now passes `contentWidth: 100%`. That is not a width choice but a disclaimer: Markdown holds no measure, and the container it lands in is the only one. Every caller already clamps itself — the transcript at the transcript measure, Daily Review at its report column, Artifact Preview at the panel.
   
   The 680 is deliberately not mirrored into a Maka token. A token would make Astryx's default ours to keep in sync, which is the same two-authority defect wearing a token's name. `contentWidth` cannot read the transcript token either, since `MarkdownBody` is shared with surfaces that are not the transcript.
   
   Refs #3617
   
   ## Verification
   
   - New E2E `apps/desktop/e2e/transcript-measure.spec.ts`: sends a paragraph at a 1400px viewport and asserts the prose right edge meets the turn right edge. Passes; reverting `contentWidth` to `680` fails it at exactly `120`.
   - New unit contract `packages/ui/src/__tests__/markdown-measure-contract.test.tsx`: pins the resolved prose cap to `100%`, so a dropped prop or an upstream default change fails in milliseconds instead of only in the desktop E2E. Passes; fails on the same revert.
   - `npm --workspace @maka/ui run test` — 231 pass, 0 fail.
   - `npm run format:check` — clean.
   - Not run: the repository-wide suite, and Storybook visual smoke. CI covers both.
   
   ## Root cause
   
   The defect reproduces in Astryx alone, with no Maka code: `ChatLayout density="spacious"` gives an 800px message area, `ChatMessageBubble variant="ghost" width="100%"` (the documented pattern for rich content) fills it, and a default `Markdown` inside stops its prose at 680px while its code blocks fill the bubble.
   
   Astryx already solves exactly this in `Layout`, which publishes its `contentWidth` as the inheritable `--layout-content-width` and has `LayoutHeader` / `LayoutFooter` read it back as `var(--layout-content-width, none)`. Neither `Markdown` nor `ChatLayout` participates: both carry hardcoded values instead. An upstream bug report is being prepared. If Astryx adopts the inheritance, this prop can be deleted, and the unit contract above is what will notice.
   
   ## AI use
   
   Select exactly one:
   
   - [ ] No generative tool made a substantive contribution
   - [x] Generative tooling made a substantive contribution
   
   Tool(s) and scope: Claude Code — diagnosis, the fix, both tests, and this description. Reviewed and verified by the contributor before opening.
   
   ## Checklist
   
   - [x] Tests cover the change and fail without it
   - [x] Lint, format, typecheck and the affected suites pass locally
   
   Does this PR entail a change in behavior?
   
   - [x] Yes — described under Summary above
   - [ ] No
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org


Re: [PR] fix(desktop): give the chat surface one reading measure [maka]

Posted by "Astro-Han (via GitHub)" <gi...@apache.org>.
Astro-Han merged PR #3997:
URL: https://github.com/apache/maka/pull/3997


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org