Skip to content

Fix iOS chat toolbar glass separation - #7111

Closed
azooz2003-bit wants to merge 8 commits into
mainfrom
fix-ios-bottom-scroll-blur
Closed

azooz2003-bit wants to merge 8 commits into
mainfrom
fix-ios-bottom-scroll-blur

Conversation

@azooz2003-bit

@azooz2003-bit azooz2003-bit commented Jun 30, 2026 •

Copy link
Copy Markdown
Collaborator

Follow-up to #7051.

Fixes the iOS inline agent chat toolbar after simulator verification showed the earlier build still fused the back button and title glass.

Changes:

  • Keep the workspace title in the principal toolbar slot from current main.
  • Add an isolated compact glass helper for back toolbar controls.
  • Add a debug-only idle fixture override so simulator screenshots cover the no-agent shortcut row.

Verification:

  • ./ios/scripts/reload.sh --tag vf2 --simulator "cmux-blur-verify-211039" --no-launch
  • ./scripts/reload-cloud.sh --tag vf2 (fell back to local ./scripts/reload.sh --tag vf2)
  • swift test --package-path Packages/iOS/CmuxAgentChatUI
  • swift test --package-path Packages/iOS/CmuxMobileSupport
  • autoreview --mode branch --base origin/main
  • Simulator screenshots: /tmp/cmux-vf-evidence/vf2-finaltip-working.png and /tmp/cmux-vf-evidence/vf2-finaltip-idle.png

View with Codesmith Autofix with Codesmith
Need help on this PR? Tag /codesmith with what you need. Autofix is disabled.


Summary by cubic

Separated the iOS chat toolbar glass so the back button and title render independently. Fixed the composer shortcut row by isolating the scroll strip with a leading hard stop and a trailing blur, keeping chips fully visible.

  • Bug Fixes

    • Added mobileIsolatedGlassCompactToolbarControl(...) in CmuxMobileSupport and applied to back controls in CmuxMobileShellUI (WorkspaceChatPane, AgentChatDemoScreen) with 16pt horizontal padding; title stays in the principal slot so glass remains separated.
    • Reworked ChatAccessoryChipRow in CmuxAgentChatUI: split a fixed leading cluster from a scrollable strip, added a leading hard stop and trailing-only fade with clipping/padding to keep chips outside the fade and correct scrolling; removed the composer glass wrapper in ChatComposerView to avoid unintended blur.
  • New Features

    • Debug-only env toggle CMUX_UITEST_AGENT_CHAT_STATE=idle to force idle state for simulator screenshots.

Written for commit 8d523c7. Summary will update on new commits.

Review in cubic

Summary by CodeRabbit

  • New Features

    • Added an iOS 26+ “isolated” compact Liquid Glass toolbar control for mobile views, with configurable horizontal padding.
    • Demo chat sessions can now start in an idle state based on the app environment setting.
  • UI Improvements

    • Updated workspace chat back/toolbar controls to use the new isolated compact toolbar appearance with consistent horizontal padding.
    • Refreshed the accessory shortcut chip row fade to a trailing fade for smoother scrolling.
    • Adjusted the composer surface rendering on iOS 26+ for a simplified look.

…os-bottom-scroll-blur

# Conflicts:
#	Packages/iOS/CmuxMobileShellUI/Sources/CmuxMobileShellUI/AgentChatDemoScreen.swift
…-blur

# Conflicts:
#	Packages/iOS/CmuxMobileShellUI/Sources/CmuxMobileShellUI/AgentChatDemoScreen.swift
#	Packages/iOS/CmuxMobileShellUI/Sources/CmuxMobileShellUI/WorkspaceChatPane.swift
@vercel

vercel Bot commented Jun 30, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
cmux Ready Ready Preview, Comment Jul 1, 2026 1:36am
cmux-staging Ready Ready Preview, Comment Jul 1, 2026 1:36am

@coderabbitai

coderabbitai Bot commented Jun 30, 2026 •

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: e7116c3f-d990-47e8-b902-cdc9af4c2960

📥 Commits

Reviewing files that changed from the base of the PR and between eb3e4f8 and 8d523c7.

📒 Files selected for processing (2)
  • Packages/iOS/CmuxAgentChatUI/Sources/CmuxAgentChatUI/Composer/ChatAccessoryChipRow.swift
  • Packages/iOS/CmuxAgentChatUI/Sources/CmuxAgentChatUI/Composer/ChatComposerView.swift

📝 Walkthrough

Walkthrough

Adds an isolated glass toolbar control, applies it to workspace and demo back buttons, forces the demo descriptor into idle from an environment variable, removes an iOS-only composer glass wrapper, and switches accessory chip fading to the trailing side.

Changes

Isolated glass toolbar control and demo state override

Layer / File(s) Summary
New isolated glass toolbar control
Packages/iOS/CmuxMobileSupport/Sources/CmuxMobileSupport/View+MobileGlass.swift
Adds a public View extension that applies iOS 26+ isolated capsule glass styling with configurable horizontal padding, plain button style, small control size, and a fixed minimum height.
Apply isolated glass control to back buttons
Packages/iOS/CmuxMobileShellUI/Sources/CmuxMobileShellUI/WorkspaceChatPane.swift, Packages/iOS/CmuxMobileShellUI/Sources/CmuxMobileShellUI/AgentChatDemoScreen.swift
Applies mobileIsolatedGlassCompactToolbarControl(horizontalPadding: 16) to the workspace back toolbar button and the demo screen’s inline workspace toolbar cluster.
Force idle demo descriptor from environment
Packages/iOS/CmuxMobileShellUI/Sources/CmuxMobileShellUI/AgentChatDemoScreen.swift
Adds demoDescriptor(from:) to read CMUX_UITEST_AGENT_CHAT_STATE, trim it, and return the descriptor with state set to .idle when the value is "idle".
Remove composer glass container
Packages/iOS/CmuxAgentChatUI/Sources/CmuxAgentChatUI/Composer/ChatComposerView.swift
The iOS-only composer surface now returns composerStack directly instead of wrapping it in a version-conditional GlassEffectContainer.

Accessory chip trailing fade

Layer / File(s) Summary
Switch chip row fade to trailing side
Packages/iOS/CmuxAgentChatUI/Sources/CmuxAgentChatUI/Composer/ChatAccessoryChipRow.swift
Replaces the edge fade width, condition helper, mask builder, and gradient framing with trailing-only fade logic and sizing.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

  • manaflow-ai/cmux#7092: Touches the same WorkspaceChatPane.swift toolbar area and related back-button placement logic.

Poem

🐇 I hop where glassy buttons glow,
And idle demos softly show.
The chip row fades to the rear with grace,
While workspace bars keep their tidy place.


Important

Pre-merge checks failed

Please resolve all errors before merging. Addressing warnings is optional.

❌ Failed checks (1 error, 1 warning)

Check name Status Explanation Resolution
Cmux No Test Or Debug Seam In Production Source ❌ Error AgentChatDemoScreen.swift adds demoDescriptor(from:), a DEBUG-only UI-test env seam (CMUX_UITEST_AGENT_CHAT_STATE) in production Sources with no production caller. Move the idle-state override into the test target or a dedicated debug-support file/folder; keep AgentChatDemoScreen free of test-observability accessors and use @testable import if state must be observed.
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (23 passed)
Check name Status Explanation
Title check ✅ Passed The title matches the main change: separating the iOS chat toolbar glass.
Description check ✅ Passed It includes a clear summary, verification steps, review trigger, and checklist; only the demo video section is missing.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Cmux Swift Actor Isolation ✅ Passed PASS: The diff only touches SwiftUI view code and a UI helper; shared models are already Sendable and ChatConversationStore is already @MainActor, so no new isolation debt.
Cmux Swift Blocking Runtime ✅ Passed No new blocking primitives appear in the edited Swift files; they use callbacks/state/Task wrappers only, with no semaphores, sleeps, sync waits, or locks.
Cmux Browser Automation Off-Main ✅ Passed PASS: The PR only changes iOS chat UI/glass helpers; no browser.* socket commands, worker routing, or policy tests were added or modified.
Cmux Expensive Synchronous Load ✅ Passed PASS: Touched code is UI-only plus a debug env override; no new expensive history loads, JSON/JSONL parsing, SharedLiveAgentIndex.shared, or Task.detached on interactive paths.
Cmux Cache Substitution Correctness ✅ Passed Only a DEBUG-only demoDescriptor override for screenshots; no persistence/history/undo/snapshot path swaps a fresh authoritative read for a cache.
Cmux No Hacky Sleeps ✅ Passed Diff only touches Swift sources plus build metadata (.xcstrings/pbxproj/tsv); no TypeScript/JS/shell/runtime script changes or fixed waits introduced.
Cmux Algorithmic Complexity ✅ Passed No new nested scans or large-collection hot paths; the new loops are single-pass over tiny toolbar/shortcut arrays or fixture data.
Cmux Swift Concurrency ✅ Passed Touched Swift changes are synchronous UI/layout helpers; async usage is limited to SwiftUI/button-boundary Task bridges, with no new DispatchQueue/Combine/completion-handler patterns.
Cmux Swift @Concurrent ✅ Passed No diffed async/@Concurrent violations: the new .task path calls sync in-memory fixture building, and the other edits are sync UI/view changes.
Cmux Swift File And Package Boundaries ✅ Passed Touched files are small UI/package-scoped edits; no new oversized files, responsibility mixing, or app-target feature logic hidden outside a package boundary.
Cmux Swiftpm Lockfiles ✅ Passed No .gitignore/Package.resolved files changed, and the pbxproj edits only shuffle source file refs; the Xcode packageReferences section is unchanged.
Cmux Swift Logging ✅ Passed Touched Swift files only add UI helpers and a debug env override; no print/debugPrint/dump/NSLog/Logger changes were introduced.
Cmux User-Facing Error Privacy ✅ Passed No user-facing error/alert/copy changes were introduced; the only env var usage is DEBUG-only fixture code, and the rest is toolbar/UI styling.
Cmux Full Internationalization ✅ Passed PR only adds debug-only fixture/env handling and glass/layout helpers; no new user-facing text or locale assets changed, and touched localized keys already have en/ja translations.
Cmux Swiftui State Layout ✅ Passed No new ObservableObject/@published, GeometryReader, lazy-row store refs, or render-time state writes were introduced in the touched SwiftUI files.
Cmux Architecture Rethink ✅ Passed Small local SwiftUI correctness fixes with clear owners; no sleeps, polling, observers, locks, or duplicate lifecycle wiring introduced.
Cmux Swift Auxiliary Window Close Shortcuts ✅ Passed Touched files only adjust toolbar/composer views and a DEBUG fixture; no NSWindow/WindowGroup/NSPanel code or cmuxAuxiliaryWindowIdentifiers changes.
Cmux Source Artifacts ✅ Passed Changed paths are intentional Swift source/config/docs files; no tmp/artifacts/screenshots/logs/build-output paths appear in the diff.
Cmux No Ambient Global State ✅ Passed No new ambient global surface: the new glass helper is a View-extension method, and the idle override is a private instance method; no new globals or singletons.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix-ios-bottom-scroll-blur

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@greptile-apps

greptile-apps Bot commented Jun 30, 2026 •

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR fixes the iOS chat toolbar glass separation by keeping the workspace title in the principal slot, wrapping back-button controls in a new mobileIsolatedGlassCompactToolbarControl helper (which uses .glassEffect directly without a merging container), and removing the GlassEffectContainer from the composer surface so each glass element renders independently. The chip shortcut row is also reworked to use a trailing-only scroll fade with a separate leading hard-stop overlay and leading cluster.

  • New mobileIsolatedGlassCompactToolbarControl helper added to CmuxMobileSupport and applied with horizontalPadding: 16 in both WorkspaceChatPane and AgentChatDemoScreen, separating back-button glass from the title glass.
  • ChatAccessoryChipRow refactored into a fixed leading-shortcut cluster and a scrollable strip with a trailing-only fade and a leading hard-stop overlay; two correctness issues are present (see comments).
  • AgentChatDemoScreen adds a CMUX_UITEST_AGENT_CHAT_STATE=idle env override inside the existing file-level #if DEBUG guard, consistent with the file's other UITestConfig pattern.

Confidence Score: 4/5

The toolbar glass separation and demo screen changes are safe; the chip row refactor has two correctness issues that should be addressed before shipping.

The glass-separation fix in the toolbar (new helper, removed GlassEffectContainer, back-button callsites) is clean and well-verified. Two issues are present in the reworked ChatAccessoryChipRow: the trailing-fade threshold omits the always-present 14 pt leading padding, leaving a ~16 pt range where the row is scrollable but shows no visual indicator; and the hard-stop overlay uses hardcoded Color.black, which renders as a visible black rectangle on light-mode or non-dark glass backgrounds. Both are introduced by this PR in production code paths.

Packages/iOS/CmuxAgentChatUI/Sources/CmuxAgentChatUI/Composer/ChatAccessoryChipRow.swift — both issues are here

Important Files Changed

Filename Overview
Packages/iOS/CmuxAgentChatUI/Sources/CmuxAgentChatUI/Composer/ChatAccessoryChipRow.swift Refactored chip row into leading cluster + scrollable strip; introduces two bugs: trailing fade threshold ignores the always-present 14 pt leading padding, and the leading hard-stop overlay uses hardcoded Color.black which breaks light mode.
Packages/iOS/CmuxAgentChatUI/Sources/CmuxAgentChatUI/Composer/ChatComposerView.swift Removes the GlassEffectContainer wrapper from composerSurface on iOS 26, making each glass element inside render in isolation — intentional and correct for the glass-separation fix.
Packages/iOS/CmuxMobileShellUI/Sources/CmuxMobileShellUI/WorkspaceChatPane.swift Swaps mobileGlassCompactToolbarControl() for mobileIsolatedGlassCompactToolbarControl(horizontalPadding: 16) on the back button — straightforward callsite update, looks correct.
Packages/iOS/CmuxMobileShellUI/Sources/CmuxMobileShellUI/AgentChatDemoScreen.swift Adds demoDescriptor(from:) inside the file-level #if DEBUG guard to read CMUX_UITEST_AGENT_CHAT_STATE for idle-state simulator fixtures; consistent with the file's existing UITestConfig pattern.
Packages/iOS/CmuxMobileSupport/Sources/CmuxMobileSupport/View+MobileGlass.swift Adds mobileIsolatedGlassCompactToolbarControl(horizontalPadding:) that uses .buttonStyle(.plain) + .glassEffect(.regular.interactive()) to produce an isolated (non-merging) capsule glass control; clean addition alongside existing helpers.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[ChatAccessoryChipRow body] --> B{displayedLeadingShortcuts not empty?}
    B -- yes --> C[leadingShortcutCluster layoutPriority 2 zIndex 1]
    B -- no --> D{displayedScrollableShortcuts not empty?}
    C --> D
    D -- yes --> E[scrollableShortcutStrip]
    D -- no --> Z[Empty height 32]
    E --> F[ScrollView .horizontal]
    F --> G[chips HStack onGeometryChange scrollContentWidth]
    G --> H[.padding leading 14pt always .padding trailing 34 if fade else 2]
    H --> I[.compositingGroup .clipShape rect .mask scrollTrailingFadeMask]
    I --> J[.overlay leading scrollLeadingHardStop Color.black 14pt]
    I --> K{scrollNeedsTrailingFade? scrollContentWidth > scrollViewportWidth + 1}
    K -- true --> L[trailing fade gradient + 34pt trailing padding]
    K -- false --> M[full opaque mask + 2pt trailing padding]
    L --> N[Fade shown]
    M --> O{actual content scrollContentWidth + 14 + 2 > scrollViewportWidth?}
    O -- yes 16pt dead zone --> P[Scrollable but NO fade shown]
    O -- no --> Q[No scroll needed]
Loading
%%{init: {'theme': 'base', 'themeVariables': {"darkMode": true, "background": "#0d1117", "primaryColor": "#21262d", "primaryTextColor": "#e6edf3", "primaryBorderColor": "#8b949e", "lineColor": "#8b949e", "textColor": "#e6edf3", "edgeLabelBackground": "#161b22", "actorBkg": "#21262d", "actorBorder": "#8b949e", "actorTextColor": "#e6edf3", "actorLineColor": "#8b949e", "signalColor": "#8b949e", "signalTextColor": "#e6edf3", "noteBkgColor": "#373320", "noteBorderColor": "#d4a72c", "noteTextColor": "#f0e6c0", "labelBoxBkgColor": "#21262d", "labelBoxBorderColor": "#8b949e", "labelTextColor": "#e6edf3", "loopTextColor": "#e6edf3", "activationBkgColor": "#30363d", "activationBorderColor": "#8b949e"}}}%%
flowchart TD
    A[ChatAccessoryChipRow body] --> B{displayedLeadingShortcuts not empty?}
    B -- yes --> C[leadingShortcutCluster layoutPriority 2 zIndex 1]
    B -- no --> D{displayedScrollableShortcuts not empty?}
    C --> D
    D -- yes --> E[scrollableShortcutStrip]
    D -- no --> Z[Empty height 32]
    E --> F[ScrollView .horizontal]
    F --> G[chips HStack onGeometryChange scrollContentWidth]
    G --> H[.padding leading 14pt always .padding trailing 34 if fade else 2]
    H --> I[.compositingGroup .clipShape rect .mask scrollTrailingFadeMask]
    I --> J[.overlay leading scrollLeadingHardStop Color.black 14pt]
    I --> K{scrollNeedsTrailingFade? scrollContentWidth > scrollViewportWidth + 1}
    K -- true --> L[trailing fade gradient + 34pt trailing padding]
    K -- false --> M[full opaque mask + 2pt trailing padding]
    L --> N[Fade shown]
    M --> O{actual content scrollContentWidth + 14 + 2 > scrollViewportWidth?}
    O -- yes 16pt dead zone --> P[Scrollable but NO fade shown]
    O -- no --> Q[No scroll needed]
Loading

Reviews (3): Last reviewed commit: "Isolate iOS composer shortcut scroll" | Re-trigger Greptile

Comment on lines +127 to +134
private func demoDescriptor(from descriptor: ChatSessionDescriptor) -> ChatSessionDescriptor {
let demoState = ProcessInfo.processInfo.environment["CMUX_UITEST_AGENT_CHAT_STATE"]?
.trimmingCharacters(in: .whitespacesAndNewlines)
guard demoState == "idle" else {
return descriptor
}
return descriptor.withState(.idle)
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 UI-test env-var hook in production Sources/

demoDescriptor(from:) reads the CMUX_UITEST_AGENT_CHAT_STATE environment variable — a named UI-test integration point — and lives under Packages/iOS/CmuxMobileShellUI/Sources/, a production Sources/ path. The no-test-debug-seam-in-production-source rule flags debug-only seams in **/Sources/** regardless of a surrounding #if DEBUG guard, and the pass condition for #if DEBUG blocks is "real product behavior" — screenshots and simulator fixture overrides are test behavior, not product behavior. The conventional fix is to place this configuration in a dedicated debug module, a UI-test support target, or a test-only launch-argument resolver that is never compiled into the shipping product directory.

Rule Used: Flag Swift files under a production Sources path (... (source)

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

/// Compact toolbar glass that must remain visually separate from adjacent
/// glass controls.
@ViewBuilder
func mobileIsolatedGlassCompactToolbarControl(horizontalPadding: CGFloat = 14) -> some View {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 The default horizontalPadding value of 14 is never exercised in practice — both call sites in WorkspaceChatPane and AgentChatDemoScreen explicitly pass 16. An unused default creates ambiguity about which value is correct for the back-button context and makes the API misleading for future callers. If 16 is the intended standard for toolbar back controls, the default should match; if the default is reserved for a different, narrower use case, a comment explaining that distinction would prevent accidental misuse.

Suggested change
func mobileIsolatedGlassCompactToolbarControl(horizontalPadding: CGFloat = 14) -> some View {
func mobileIsolatedGlassCompactToolbarControl(horizontalPadding: CGFloat = 16) -> some View {

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@Packages/iOS/CmuxMobileShellUI/Sources/CmuxMobileShellUI/AgentChatDemoScreen.swift`:
- Around line 127-134: The demo-state override in demoDescriptor(from:) is
reading the environment directly instead of using the shared
UITestConfig.value(for:env:) helper, which is inconsistent with
inlineWorkspaceTitle and inlineWorkspaceSubtitle. Update demoDescriptor(from:)
to fetch CMUX_UITEST_AGENT_CHAT_STATE through UITestConfig.value(for:env:), then
keep the existing trim and idle-state check so the demo-state behavior matches
the rest of AgentChatDemoScreen.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: ff5e635f-23b5-49a3-b1d1-fd209023e46e

📥 Commits

Reviewing files that changed from the base of the PR and between a56181c and eb3e4f8.

📒 Files selected for processing (4)
  • Packages/iOS/CmuxAgentChatUI/Sources/CmuxAgentChatUI/Composer/ChatAccessoryChipRow.swift
  • Packages/iOS/CmuxMobileShellUI/Sources/CmuxMobileShellUI/AgentChatDemoScreen.swift
  • Packages/iOS/CmuxMobileShellUI/Sources/CmuxMobileShellUI/WorkspaceChatPane.swift
  • Packages/iOS/CmuxMobileSupport/Sources/CmuxMobileSupport/View+MobileGlass.swift

Comment on lines +127 to +134
private func demoDescriptor(from descriptor: ChatSessionDescriptor) -> ChatSessionDescriptor {
let demoState = ProcessInfo.processInfo.environment["CMUX_UITEST_AGENT_CHAT_STATE"]?
.trimmingCharacters(in: .whitespacesAndNewlines)
guard demoState == "idle" else {
return descriptor
}
return descriptor.withState(.idle)
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Confirm UITestConfig.value's trimming/matching semantics before reuse.
rg -n -A 15 'struct UITestConfig|enum UITestConfig' --type=swift
rg -n -A 15 'func value\(' --type=swift -g '*UITestConfig*'

Repository: manaflow-ai/cmux

Length of output: 154


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo '--- AgentChatDemoScreen.swift slice ---'
sed -n '1,220p' Packages/iOS/CmuxMobileShellUI/Sources/CmuxMobileShellUI/AgentChatDemoScreen.swift

echo
echo '--- Search for UITestConfig and value(for:) ---'
rg -n 'UITestConfig|value\(for:|CMUX_UITEST_AGENT_CHAT_STATE|inlineWorkspaceTitle|inlineWorkspaceSubtitle' Packages -g '*.swift'

Repository: manaflow-ai/cmux

Length of output: 34268


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo '--- UITestConfig.swift ---'
sed -n '1,260p' Packages/iOS/CmuxMobileSupport/Sources/CmuxMobileSupport/UITestConfig.swift

echo
echo '--- UITestConfigTests.swift ---'
sed -n '1,220p' Packages/iOS/CmuxMobileSupport/Tests/CmuxMobileSupportTests/UITestConfigTests.swift

Repository: manaflow-ai/cmux

Length of output: 13404


🏁 Script executed:

#!/bin/bash
set -euo pipefail
sed -n '1,260p' Packages/iOS/CmuxMobileSupport/Sources/CmuxMobileSupport/UITestConfig.swift

Repository: manaflow-ai/cmux

Length of output: 7795


Use UITestConfig.value(for:env:) here too.
inlineWorkspaceTitle and inlineWorkspaceSubtitle already route UI-test overrides through the shared helper, which handles the trim + mock-data gating consistently. This keeps the demo-state override aligned with the rest of the file.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@Packages/iOS/CmuxMobileShellUI/Sources/CmuxMobileShellUI/AgentChatDemoScreen.swift`
around lines 127 - 134, The demo-state override in demoDescriptor(from:) is
reading the environment directly instead of using the shared
UITestConfig.value(for:env:) helper, which is inconsistent with
inlineWorkspaceTitle and inlineWorkspaceSubtitle. Update demoDescriptor(from:)
to fetch CMUX_UITEST_AGENT_CHAT_STATE through UITestConfig.value(for:env:), then
keep the existing trim and idle-state check so the demo-state behavior matches
the rest of AgentChatDemoScreen.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 issue found across 5 files

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="Packages/iOS/CmuxAgentChatUI/Sources/CmuxAgentChatUI/Composer/ChatAccessoryChipRow.swift">

<violation number="1" location="Packages/iOS/CmuxAgentChatUI/Sources/CmuxAgentChatUI/Composer/ChatAccessoryChipRow.swift:197">
P2: The leading hard-stop overlay is painted black, not used as a mask, so it can render a visible black bar in the chip row. Use a background-matching style/material or remove the visible fill instead of hard-coding black.</violation>
</file>

Reply with feedback, questions, or to request a fix.

Re-trigger cubic


private var scrollLeadingHardStop: some View {
Rectangle()
.fill(Color.black)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: The leading hard-stop overlay is painted black, not used as a mask, so it can render a visible black bar in the chip row. Use a background-matching style/material or remove the visible fill instead of hard-coding black.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At Packages/iOS/CmuxAgentChatUI/Sources/CmuxAgentChatUI/Composer/ChatAccessoryChipRow.swift, line 197:

<comment>The leading hard-stop overlay is painted black, not used as a mask, so it can render a visible black bar in the chip row. Use a background-matching style/material or remove the visible fill instead of hard-coding black.</comment>

<file context>
@@ -170,17 +192,22 @@ public struct ChatAccessoryChipRow: View {
 
+    private var scrollLeadingHardStop: some View {
+        Rectangle()
+            .fill(Color.black)
+            .frame(width: Self.scrollLeadingHardStopWidth)
+            .overlay(alignment: .trailing) {
</file context>

@azooz2003-bit

Copy link
Copy Markdown
Collaborator Author

Superseded by #7116 so the iOS toolbar fixes can be tested and reviewed in one PR.

This branch was successfully deployed

1 active deployment
Preview – cmux — 8d523c78 Deployed Jul 1, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant