Repository navigation
Conversation
ApprovabilityVerdict: Approved at Macroscope's review found this PR approvable — This is a focused mobile rendering fix that preserves existing code-block colors while allowing iOS text-selection highlights to remain visible. The new color helper is isolated and covered by theme-wide tests, with no product configuration, schema, deployment, or static-analysis changes. You can add or adjust custom eligibility rules. Learn more. |
|
No actionable comments were generated in the recent review.
|
| Layer / File(s) | Summary |
|---|---|
Theme color opacity helper apps/mobile/src/lib/mobileTheme.ts, apps/mobile/src/lib/mobileTheme.test.ts |
Adds seeThroughThemeColor. It returns the original color for unsupported inputs. For supported colors, it calculates an rgba color with opacity clamped to 0.25–0.5. Tests cover mobile themes, appearances, compositing, and unsupported formats. |
ThreadFeed code block styling apps/mobile/src/features/threads/ThreadFeed.tsx |
On iOS, derives the assistant code block background from the Markdown code background and screen color. On other platforms, uses the original Markdown code background. |
Priority:
Estimated code review effort: 2 (Simple) | ~10 minutes
Change: Bug fix · Severity of issue fixed: Low
Suggested reviewers: juliusmarminge
Merge Risk: 
Minimal · up to 75d9a
-
iOS assistant code blocks use a translucent background to show selection. No merge-blocking risk was established.
Pre-merge checks: 
4
-
Full details: Title check
-
Explanation
The title names the main change: a fix in the mobile app so selected text in list code blocks shows its highlight on iOS. The changeset adds seeThroughThemeColor and uses it to make the assistant code-block background translucent on iOS, which matches the title's scope. The title follows conventional commit format and is specific.
Full details: Description check
-
Explanation
The description follows the template. It has Problem, Change, Scope and approval, and Verification sections. The Problem section states the iOS 18+ selection highlight bug and cites issue
#20903. The Change section explains the translucent code-block background and the seeThroughThemeColor helper. The Scope section links the discussion and maintainer comments. The Verification section lists the unit test run, typecheck, and iOS simulator checks, with before and after screenshots for both themes. It also states what was not checked, which is Android on a device. The description keeps the template's required content, and the description is mostly complete.
Full details: Out of Scope Changes check
-
Explanation
The reviewed changes stay within the iOS selection-highlight fix.
seeThroughThemeColorcomputes a translucent code-block color,ThreadFeed.tsxapplies it only to assistant Markdown on iOS, and focused theme tests cover the color behavior. User styling remains unchanged. No unrelated change is established.
-
Finishing Touches
-
🧪 Generate unit tests (beta)
-
- Create a new PR
-
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Comment @coderabbitai help to get the list of available commands.
518a9a1 to
ed160e5
Compare
|
Note Written by updated the original branch at the workaround now runs only on ios. the helper preserves already-translucent inputs, avoiding a material you regression where hex alpha was discarded. added coverage in the existing theme test file for both appearances of all six built-in themes and unsupported/alpha color formats. no new test files. verification: blacksmith unverified: fresh ios selection, copy/handles, top-level code blocks and table headers on the current native client; android device rendering. this linux vm cannot run uikit, and chrome cannot validate native ios selection. the default dev server started and chrome loaded its pairing page, which does not prove this fix. coderabbit's latest review was rate limited; its green check is not a fresh review. the following are @camchis's original ios captures, inspected and retained for context. they are not captures of the updated head. a native ios check is still needed before calling the changed interaction verified. |
|
Checked Maria's updated head (
Thanks @maria-rcks for picking this up. |
|
Note Written by Verified in a real dev environmentno changed runtime behavior could be verified on this linux boat vm. this is an unverifiable result, not an approval or a claim that the fix works. read the description, discussion, commit authors, full diff, and fetched exact head source inspection confirms the workaround only runs when host capability transcript: Not verifiedoriginal bug reproduction on github/main; current-head ios selection highlight in light/dark themes; selection handles and copy; adjacent top-level code blocks, table headers, user bubbles and file previews; android rendering. no native ios runtime is available on this linux vm, and no mobile device is attached. i did not create main/head dev installations, launch a web server or run codex turns because none can reach this ios-only changed rendering path here. no fresh before/after screenshots or recording were captured. the author's ios 26.5 report on this exact head in the discussion is useful external evidence, but i did not reproduce it myself. no code, branch, label or pr state was changed. to finish: on an ios device or macos simulator, run main and this exact head against isolated dev state, create a real project/thread and codex gpt-6.1-sol response with nested and top-level code blocks plus a table, then compare selection, copy and unselected appearance in light/dark themes. capture matching before/after screenshots and a short interaction recording. |
…ck-selection-highlight # Conflicts: # apps/mobile/src/features/threads/ThreadFeed.tsx
|
Note Written by Verified in a real dev environmentno changed runtime behavior could be verified on this linux boat vm. result: unverifiable, not approval. inspected the description, discussion, reviews, complete diff and commit authors; fetched exact head at this exact head, host capability checks this run: the author's discussion reports ios simulator verification on Not verifiedoriginal bug reproduction on github/main; current-head native ios selection highlight, handles and copy in light/dark themes; unselected appearance; neighboring top-level code blocks, table headers, user bubbles and file previews; android rendering. no ios runtime or accessible native device is available here. no main/head installs, dev servers or codex turns were started: they cannot reach this ios-only rendering change on this host. no fresh screenshots or recordings were captured or uploaded. no source, branch, label or pr state was changed. to finish verification, use an ios device or macos simulator with isolated main/head dev servers and real codex gpt-6.1-sol turns. compare nested code selection and copy, unselected code/table appearance, and user bubble selection in light/dark themes; capture matching before/after images and an interaction recording. |
|
@maria-rcks jus merge ts, ur agent is being too needy |
|
Note 🤖 Claude Opus 5.5 responding on behalf of Theo Closing. This PR has been open for more than 3 weeks, and |












Problem
On iOS 18+, selecting text inside a code block nested in a list item in an assistant message shows no highlight. The handles and Copy still work. Enriched draws the opaque code-block box over UIKit's selection highlight. Closes #20903.
Change
The assistant Markdown's
codeBlockBackgroundColoris now a see-through version of--color-md-code-bg. Its opacity and color are chosen so that, laid over--color-screen, it shows the same color as today, and the highlight beneath shows through.seeThroughThemeColor(color, surface)inmobileTheme.tsuses 25% opacity, or the least opacity that still matches exactly, capped at 50%.#fcfcfcpage, which no translucent white can reproduce exactly, so it uses 50% opacity and comes within 2 levels.nativeTextStylechanges. User bubbles, file previews and PR Markdown keep their colors.Scope and approval
Follows the discussion on #20903:
--color-md-code-bgascodeBlockBackgroundColor.Julius's concern was that a translucent box would change how every assistant code block looks. This one is matched to the screen color, so code blocks look the same.
Verification
vp test run apps/mobile/src/lib/mobileTheme.test.tspasses. I checked the color match on the simulator below rather than in a unit test.mainvs. this branch:Done with Claude Opus 5.5 in Claude Code, running in T3 Code.
🤖 Generated with Claude Code