Repository navigation
fix(mobile): preserve Android Usage across layout changes - #25231
maria-rcks wants to merge 3 commits into
Conversation
Co-authored-by: Alex <5401039+PixPMusic@users.noreply.github.com>
|
No actionable comments were generated in the recent review.
|
| Layer / File(s) | Summary |
|---|---|
Shared workspace rendering apps/mobile/src/features/workspace/WorkspaceRootScreen.android.tsx |
Split view uses workspace bottom clearance and preserves the safe-area bottom inset. Empty-state, pull-request content, headers, and Android navigation render according to the active layout. |
Layout-switch persistence test apps/mobile/src/features/workspace/workspace-tabs-state.test.ts, apps/mobile/vite.config.ts |
A mounted-render test alternates layouts and checks that the Usage label and button instance persist. The React test project includes the test. |
Priority:
Estimated code review effort: 2 (Simple) | ~12 minutes
Change: Bug fix
Suggested labels: bugfix, 📱 Native Change, takeover
Suggested reviewers: juliusmarminge
Merge Risk: 
Minimal · up to 1a76f
-
No actionable merge-blocking risk remains in the reviewed changes.
Pre-merge checks: 
4
-
Full details: Title check
-
Explanation
The title "fix(mobile): preserve Android Usage across layout changes" matches the main change. The changeset keeps one workspace tab tree mounted across split and compact layouts in WorkspaceRootScreen.android.tsx, so the Usage page keeps its state. It uses a conventional commit prefix and plain language, and it names the platform, area, and symptom. The title is specific and accurate, so it passes.
Full details: Description check
-
Explanation
The description includes the required Problem, Change, Scope and approval, and Verification sections. It explains the regression, implementation, test results, scope, and unverified native Android checks. It does not include before/after Android screenshots, but it clearly states why those captures were unavailable. The description is otherwise complete and focused.
-
Finishing Touches
-
📝 Generate docstrings
-
- Commit to this branch
- Create a new PR
🧪 Generate unit tests (beta)
-
- Commit to this branch
- 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.
ApprovabilityVerdict: Approved at Macroscope's review found this PR approvable — This is a focused Android bug fix that preserves the existing Usage screen instance across split-view and compact-layout transitions. The production change is localized, behavior is covered by a targeted regression test, and no sensitive, schema, deployment, or default-setting changes are introduced. No code changes detected at You can add or adjust custom eligibility rules. Learn more. |
|
Note Written by Merged main into the existing head with merge commit Blacksmith Native Android resizing/folding and captures remain unverified: adb lists no attached devices. Browser evidence cannot exercise the Android workspace root. |
# Conflicts: # apps/mobile/vite.config.ts
|
Note Written by Pushed merge commit All 30 reported checks are green, with no conflicts. Blacksmith Native Android resizing/folding, scroll behavior, and captures remain unverified because adb lists no attached devices. This remains a verification gap before calling the UI ready. No dev servers were started; the task testbox is stopped. |
Problem
Crossing Android's compact/split workspace boundary remounts Usage, resetting its selected page, filters, and scroll container.
Change
Keep one workspace tab tree mounted across both layouts, retaining the original implementation's layout-specific safe-area insets, bottom clearance, navigation, and pull request content. Reuse the existing workspace test file instead of adding a new one.
Verification
LimitsreplacingUsage.vp run check:changedpassed formatting, lint, both knip passes, affected mobile/scripts typechecks, and all 18 workspace tests. The regression drives the actual Android root with a stateful leaf and checks its state and DOM identity through repeated transitions.github/main(32bf48f42820) with merge commit1a76f93797, preserving both mobile test registrations. Blacksmithvp run check:changedpassed on this head; All 30 reported checks are green and GitHub reports no conflicts.1a76f93797without findings. CodeRabbit reported no actionable findings on this head and its description check now passes.Scope and approval
This is a focused fix for the Android layout transition resetting Usage state. It keeps the existing screen mounted and adds regression coverage in the existing test file. Maria requested this takeover of https://git.cafe/pingdotgg/t3code/pulls/24903.
Takeover
Replaces https://git.cafe/pingdotgg/t3code/pulls/24903, with thanks to @PixPMusic for the original implementation.
Built with GPT-6.1-Sol in the Codex harness on T3 Code.