Repository navigation
fix(mobile): show subagents in a compact panel like the web - #347
Merged
Merged
Conversation
nixuuu
added a commit
that referenced
this pull request
Nov 8, 2026
Closing the expanded mobile subagents panel could draw its rows through the composer. Keep the panel anchored and clipped until its animation reaches the closed state. Fixes: #347 ### Cause and change The conditional render removed the panel's flex slot before Reanimated finished the native `exiting` animation. The retained native view lost its bottom anchor and moved into the composer. A persistent outer clip now retains the slot; an inner surface follows one reversible opacity/4 dp upward translation using `fast`, `quick`, and `distance.micro`. At zero progress the slot is hidden. Reduced motion switches instantly, and closed content cannot receive touches or accessibility focus. The 240 dp bound, internal scrolling, saved expansion and fixed composer/feed reserve remain intact. Interrupted toggles retain progress and scroll state without teardown callbacks. The narrow portrait column also has an application-side cause: the sidebar kept reserving its width until an asynchronous close callback. Its render-phase context update additionally consumed the intended `instant` flag before commit. Remounting the sidebar at a layout-context boundary now selects its target state immediately; manual sidebar toggles still animate. This removes that code path, but device rotation verification remains incomplete, so this does not establish that every frame in the supplied iPhone recording came from our layout rather than an OS snapshot. ### Evidence and device verification - Reviewed the supplied iPhone close/rotation recording. Reproduced the close glitch on the Android phone baseline with Gboard visible: the closing list appears below the summary in the composer area. The corresponding fixed close frames remain above the summary, with stationary composer and feed. - Used T3 Device tools on a separate Android phone and Canopy Fold with an isolated gateway, scripted worker and Postgres: one running and nine finished children, including long labels. Recorded before/after clips and inspected extracted frames; final fixed recordings cover light/dark and keyboard shown/hidden on both devices. - Exercised rapid repeated toggles, closing a scrolled list, reopening with retained scroll position, saved expansion after app restart, and the Android reduced-motion setting. No UI test suites added. - Evidence is retained outside version control. Primary captures: `before-phone-keyboard-verified.mp4`, `after-phone-{light,dark}-verified.mp4`, `after-fold-{light,dark}-verified.mp4`; extracted close frames include `before-phone-close.png`, `after-phone-close-frames.png` and `after-fold-close-frames.png`. Earlier exploratory recordings are not all reliable keyboard evidence. - **Not verified:** native iOS behavior. Its installed client lacks `ExpoClipboard`; Mac free space was below the required 12 GB (latest check: 1.9 GiB), so no iOS build was attempted. Android rotation requests returned `unconfirmed` and did not change the visible viewport; Fold pose commands also did not produce a cover-width viewport. Rotation/breakpoint transitions remain unverified on devices. ### Checks Passed: `bun install`, `bun run gen:check`, `bun run typecheck` (including mobile), `bun run lint`, `bun run format:check`, web build, mobile `bunx expo lint`, Expo Doctor (20/20), Android CNG prebuild, both native Hermes bundle exports and a local Android ARM64 debug build with a private SDK/Gradle and bounded heap/workers. Final formatting and diff checks are clean. **Full gate not green:** `bun run check:tmp` reported 16 failures in unchanged gateway/worker areas (add-project, bot routines/wakeups, shell, relay, linked-project routes and mirrors), then ended with SIGTERM/143 near the final updates tests without the final temp audit. Focused reruns: add-project 7 pass/1 fail; bot harness regressions 7 pass/4 fail/4 errors; both focused temp audits clean. These failures were not repaired in this UI change, and not all have been established as baseline failures. Draft pending a green full gate and the missing native verification. Owned servers, tunnel, reverse mappings, database container/volume and device sessions were cleaned up. Existing AVDs were preserved; generated native output and private build caches were removed. No store/EAS build, submission or merge. Copy audit: no UI text changed.
This was referenced Nov 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replaces the overflowing mobile subagent chips with one compact summary row above the composer. Needs-input counts remain highlighted while typing. Expanding shows state, title, provider/model and the first plain-text line of the last message; finished subagents remain reachable in their disclosure group, and rows open their threads.
The list uses a bounded overlay accordion (up to 240 dp, with internal scrolling) instead of a sheet. It keeps the keyboard and composer focus available and needs no additional sheet header or dismissal step. A permanent 44 dp summary slot keeps the composer measurement and feed reserve unchanged when agents start, finish or expand. Mention suggestions retain their existing overlay slot and temporarily take precedence. Expansion is collapsed by default and saved per device.
Also restores start/end timestamps for provider/recovery-origin turns in the mobile snapshot reducer, including disk-cache replay. This fixes missing elapsed time in the work header; older data without timestamps says “Working” instead of “Working for” without a duration. Timers use tabular digits.
Fixes: #231
Related: #332
Verification
bun install,bun run gen:check,bun run typecheck,bun run lint,bun run format:check, web build, mobile typecheck andbunx expo lint. Expo Doctor: 20/20; iOS and Android bundle exports passed. Fullbun run check:tmp: 1,755 passed, 161 skipped, 0 failed; no test temp entries left. Test temporary data stayed inside the worktree, withGIT_CEILING_DIRECTORIESto prevent nested test folders inheriting the checkout's Git repository.Componentize and motion pass
Completed before commit using the
design,componentizeandtransitions-devskills. Composer and thread details shareSubagentLineage,SubagentLineageRowandSubagentGroup; web/mobile share grouping and status presentation in@canopy/domain/subagents. Native components acceptstyle, use existing type/color tokens, and keep spacing at the call site. Existingpop,Expandand chevron motion tokens are reused; panel/group expansion is immediate with reduced motion.Copy audit (§8)