Skip to content

feat(mobile): one next-step bar under both Source Control tabs - #37104

Merged
AmoabaKelvin merged 3 commits into
mainfrom
sc-hub-next-step-bar
Nov 1, 2026
Merged

AmoabaKelvin merged 3 commits into
mainfrom
sc-hub-next-step-bar

Conversation

@AmoabaKelvin

@AmoabaKelvin AmoabaKelvin commented Nov 1, 2026 •

Copy link
Copy Markdown
Collaborator
Files Added Deleted Net
Test 5 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​206 $\color{#cf222e}{\Huge{\mathbf{−}}}$​21 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​185
Prod 32 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​1614 $\color{#cf222e}{\Huge{\mathbf{−}}}$​542 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​1072

ELI5

Source Control on the phone had three tabs, and you had to hunt around for what to do next: commit was on one tab, merge on another, and Create PR showed up in five places. Now there are two tabs, Changes and Pull request, and one button bar at the bottom of both. It always offers the single next thing for this branch: commit, push, create the pull request, ask the agent to fix a failing check, turn on "merge when ready", or merge. When nothing can be done, it says why.

What Changed

  • Two segments. Changes and Pull request. Commits is no longer a tab. It opens as a pushed page over the hub through the in-panel pager from feat(mobile): Commits lists only this branch, and each commit opens its own page #37050, using that PR's MobileCommitsScreen. Old ?tab=history links and the native history/ redirect open Commits over Changes. Android and web Back close it.
  • One next-step bar under both tabs (MobileSourceControlNextStepBar). It shows one state at a time:
    • the commit box, only when there's something to commit. It reads "Commit 2 files" or "Stage all".
    • Push 3 commits, Pull 2 commits, Sync, Publish branch.
    • Create pull request, or Push & create pull request when the commits are still local. GitLab reads "merge request".
    • Complete merge once a local merge's last conflict is resolved.
    • Resolve with <agent> for local or PR conflicts.
    • Fix with <agent> with "Can't merge yet: 1 check failing".
    • Merge when ready (GitHub auto-merge) with "2 checks still running" or "Waiting on review from brennanb".
    • Will merge when ready + Cancel.
    • Squash and merge in desktop's merge green, using the repo's default method.
    • A disabled Merge with GitHub's reason.
    • Merged into main.
  • The agent's name. "Fix with Claude" names the agent the launch will actually use: desktop's Source Control AI recipe, then the default agent, then the first detected one, resolved by the existing resolveMobileSourceControlLaunchAgent. Until that's known, or when there's no agent, the button says "AI". If the host can't launch agents from a phone, the button is disabled and the existing launch notice says why. That notice also offers Copy prompt when the prompt didn't reach the agent.
  • Gone from the Changes tab: the disabled "A pull request already exists" banner and the Create PR entry above the file list. The bar's Create PR replaces them. Complete merge moved from the branch card to the bar.
  • The PR tab body hides its own Merge button and auto-merge toggle only while the bar is offering them. On local steps (commit, push) and agent steps (fix, resolve), the body keeps them, so a stray untracked file never makes Merge or Cancel auto-merge unreachable. The bar and the PR body share one agent launcher, so Fix can't start two agents.
  • Failures from push, commit, complete merge, merge and auto-merge show in red above the bar on whichever tab you're on. A refused merge (no permission) disables the merge buttons.
  • The bar and the keyboard. The bar rides the keyboard only for its own commit box. For any other field, such as a PR comment, it steps aside.

Why

The rule lives in one place, src/shared/source-control-next-step-decision.ts. It is layered on desktop's existing commit-area decision (resolveSourceControlCommitAreaPrimaryActionDecision) and its PR merge rules (resolveGitHubPRMergeState and the stack merge decision), so the phone can't drift from desktop. Desktop's behaviour is unchanged. The mobile side only names the steps and draws them.

  • Agent name: I name the launch agent rather than whichever agent last ran in a terminal. That's the agent that will actually do the fix, so the label is never wrong.
  • Pushed pages: they go through the shared in-panel pager, not new expo-router routes, so shipped phone shells don't need an app release.
  • Merge: the bar keeps today's confirm before merging. The Merge, Create PR and Reviewers sheets from feat(mobile): rebuild the pull request tab around what blocks the merge #36999 replace that confirm and today's create flow when it lands.

Linked Issue

No issue. This is the approved Source Control redesign (hub, segments and next-step bar). The redesigned Changes rows, sections, swipe-to-discard, conflict block and ⋯ menu follow as a stacked PR.

Visual Proof

Before (main): three tabs, commit on Changes only, merge on PR only, and the disabled "already exists" banner.

After: one bar under both tabs, one state per screenshot (dirty tree, push, create PR, fix with agent, waiting on review, checks running, auto-merge on, ready, blocked, merged, local conflicts), plus the pushed Commits page.



Captured from the built page bundle in headless WebKit at iPhone size, with scripted host replies for each state.

Testing

  • I manually tested these changes locally

  • Automated tests added/updated, or explained why not below

  • Rendered every bar state above from the real page bundle (build:mobile-web, 183 assets), with a scripted host for each branch and PR state.

  • src/shared/source-control-next-step-decision.test.ts pins the ranking: local conflicts, then complete merge, then the commit box, then push or pull, then create, then PR conflicts, failing checks, auto-merge, merge, merge when ready and blocked. It also checks that a fetch on a clean branch doesn't flash an empty commit box.

  • A bar test checks that the bar rides the keyboard only for its own commit box. I watched it fail without the fix.

  • Ran the focused mobile tests (src/source-control, src/components/pr-sidebar, src/host-screen), the RPC recording goldens, mobile localization verify and coverage, changed-file code quality and React Doctor. All pass.

  • Not tested on a physical phone yet.

AI Disclosure

Review

Two reviewers (Codex and Claude) ran four rounds. Fixed:

  • errors from Git steps were invisible on the PR tab;
  • refused merges gave no feedback;
  • a dock tab switch left Commits covering the PR tab;
  • the prompt-copy recovery was dropped;
  • PR conflicts behind review-required showed a dead Merge button;
  • Merge and Cancel auto-merge were unreachable on local and agent steps;
  • the commit box and the keyboard (redesigned into one focus rule);
  • a fetch flashed the commit box;
  • Fix counted checks the prompt leaves out;
  • two separate agent launch guards;
  • the PR data wasn't reread after a push;
  • stale errors replaced the step's reason.

Handed to the Commits PR: a refresh control on the pushed Commits page.

Agent skill upstream boundary

  • Not applicable, or this change copies or mechanically translates no upstream skill-installer source, tests, fixtures, registry entries, path tables, comments, or documentation.

Notes

  • Mobile: this is the mobile PR. Every string goes through the mobile i18n catalogs.
  • Remote and mixed versions: no new RPC methods or fields. It uses existing github.mergePR, github.setPRAutoMerge, agent.launchReplay, settings.get and preflight.detectAgents. Hosts too old to launch agents get a disabled AI button with the update notice.
  • Folder workspaces: no git status means no bar.
  • Non-GitHub hosts: the bar stops at Create (provider-named) because the PR body is GitHub-only.
  • Desktop: unchanged.
  • Page bundle: 183 assets, 9,447,887 bytes, under the 9.5 MiB fence.

Checklist

  • This PR is small and focused
  • I explained what changed and why (ELI5, the user-facing before/after, the mechanism, and why over the alternatives)
  • Before/after screenshots or videos attached for UI changes, or N/A with reason
  • Self-reviewed for correctness, security, and performance
  • Cross-platform, SSH/remote, and path/shortcut impact considered (or N/A)
  • pnpm lint, pnpm typecheck, pnpm test, and pnpm build pass (or CI will cover; local preferred)

@coderabbitai

coderabbitai Bot commented Nov 1, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • Resume reviews
  • Trigger review

No actionable comments were generated in the recent review.

Recent review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 80a56111-5adb-4e77-b427-955b908811fd
Commits

Reviewing files that changed from the base of the PR and between 5174b4d and d39dacd.

Files selected for processing: 1
  • config/scripts/mobile-web-app/mobile-web-app-source-control-render.test.mjs

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 4 remain after this review.

Walkthrough

The changes add a shared resolver for source-control next steps and a mobile bar that displays commit, remote, review, check, and merge actions. The source-control panel connects this bar to pull-request state and triage, and routes commits through hub navigation. The pull-request sidebar accepts shared state and can hide its merge controls. The changes also update primary-action labels, locale entries, and related tests.

Merge Risk: Low · previous review d39da

The change is broadly usable, but these bounded history, feedback, localization, and accessibility regressions should receive follow-up.

Pre-merge checks: Passed 4 · Failed 1

Failed Failed checks: 1 warning

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 30.30% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documenta… Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed Passed checks: 4 passed
Check name Status Explanation
Title check Passed The title clearly describes the primary change: adding one next-step bar under both mobile Source Control tabs.
Description check Passed The description is comprehensive and covers the required sections, user-facing behavior, rationale, visual proof, testing, compatibility notes, and checklist. It explicitly states that no linked issue…
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.
Full details: Description check

Explanation

The description is comprehensive and covers the required sections, user-facing behavior, rationale, visual proof, testing, compatibility notes, and checklist. It explicitly states that no linked issue exists, which is acceptable only under the template's maintainer exception.

Full details: Docstring Coverage

Explanation

Docstring coverage is 30.30% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 33 functions across 22 files.

Resolution

Write docstrings for the functions missing them to satisfy the coverage threshold.

Finishing Touches
Generate docstrings
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

@coderabbitai coderabbitai Bot left a comment

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.

Actionable comments posted: 3


Review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 7f43b60c-4912-4a80-bc72-05202f2c1b0a
Commits

Reviewing files that changed from the base of the PR and between 225db8c and f113e72.

Files selected for processing: 71
  • config/flaky-test-pattern-baseline.txt
  • mobile/rpc-foundation/goldens/matrix-git.history-branch-commits-git.history-1.json
  • mobile/rpc-foundation/goldens/matrix-git.history-branch-commits-repo.list-1.json
  • mobile/rpc-foundation/goldens/matrix-git.history-branch-commits-worktree.show-1.json
  • mobile/rpc-foundation/goldens/matrix-git.history-commit-files-git.commitcompare-1.json
  • mobile/rpc-foundation/goldens/sc-history-branch-commits.json
  • mobile/rpc-foundation/pilot-scenarios.json
  • mobile/src/components/BottomDrawer.tsx
  • mobile/src/components/MobilePRSidebar.tsx
  • mobile/src/components/bottom-drawer-close-lifecycle.test.ts
  • mobile/src/components/mobile-diff-review-send-sheet-stacking.test.ts
  • mobile/src/components/pr-sidebar/MobilePrViewPanel.tsx
  • mobile/src/components/pr-sidebar/PRActionsSection.tsx
  • mobile/src/components/use-bottom-drawer-follow-up.test.tsx
  • mobile/src/host-screen/workspace-options-pager.tsx
  • mobile/src/host-screen/workspace-options-sheet.test.tsx
  • mobile/src/host-screen/workspace-options-sheet.tsx
  • mobile/src/i18n/en-runtime-required.json
  • mobile/src/i18n/locales/de.json
  • mobile/src/i18n/locales/en.json
  • mobile/src/i18n/locales/es.json
  • mobile/src/i18n/locales/fr.json
  • mobile/src/i18n/locales/ja.json
  • mobile/src/i18n/locales/ko.json
  • mobile/src/i18n/locales/pt.json
  • mobile/src/i18n/locales/ru.json
  • mobile/src/i18n/locales/tr.json
  • mobile/src/i18n/locales/zh-Hant.json
  • mobile/src/i18n/locales/zh.json
  • mobile/src/session/mobile-closed-tab-dictation-lifetime.test.tsx
  • mobile/src/session/mobile-queued-edit-composer.test.tsx
  • mobile/src/session/mobile-queued-edit-presentation.test.tsx
  • mobile/src/session/native-chat/composer/MobileNativeChatComposer.structured.test.ts
  • mobile/src/session/native-chat/composer/MobileNativeChatComposer.test.ts
  • mobile/src/session/native-chat/transcript/MobileNativeChatMessageActionsSheet.test.tsx
  • mobile/src/session/pr-ai-triage-prompt.ts
  • mobile/src/source-control/MobileCommitDetailPage.tsx
  • mobile/src/source-control/MobileCommitListRows.tsx
  • mobile/src/source-control/MobileCommitsScreen.test.tsx
  • mobile/src/source-control/MobileCommitsScreen.tsx
  • mobile/src/source-control/MobileGitHistoryList.test.tsx
  • mobile/src/source-control/MobileGitHistoryList.tsx
  • mobile/src/source-control/MobileSourceControlBranchCard.tsx
  • mobile/src/source-control/MobileSourceControlContent.test.tsx
  • mobile/src/source-control/MobileSourceControlContent.tsx
  • mobile/src/source-control/MobileSourceControlCreatePrEntry.tsx
  • mobile/src/source-control/MobileSourceControlHubCommitsPage.tsx
  • mobile/src/source-control/MobileSourceControlNextStepBar.tsx
  • mobile/src/source-control/MobileSourceControlPanel.tsx
  • mobile/src/source-control/git-history-reply-schema.ts
  • mobile/src/source-control/mobile-create-pr-action.ts
  • mobile/src/source-control/mobile-git-history.test.ts
  • mobile/src/source-control/mobile-git-history.ts
  • mobile/src/source-control/mobile-git-read-operations.ts
  • mobile/src/source-control/mobile-history-screen-state.ts
  • mobile/src/source-control/mobile-source-control-hub-tab.ts
  • mobile/src/source-control/mobile-source-control-next-step.ts
  • mobile/src/source-control/mobile-source-control-primary-action-label.ts
  • mobile/src/source-control/mobile-source-control-primary-action.test.ts
  • mobile/src/source-control/mobile-source-control-primary-action.ts
  • mobile/src/source-control/mobile-source-control-styles.ts
  • mobile/src/source-control/source-control-status-retry.test.tsx
  • mobile/src/source-control/use-mobile-source-control-agent-name.ts
  • mobile/src/source-control/use-mobile-source-control-next-step.ts
  • mobile/src/source-control/use-source-control-hub-navigation.ts
  • mobile/src/test-support/bridged-parity/divergence-classes.test.ts
  • mobile/src/test-support/bridged-parity/divergence-classes.ts
  • mobile/src/test-support/reanimated-pager-stub.ts
  • mobile/src/test-support/rpc-recording/adapters/source-control-screen-read-mount-adapters.ts
  • src/shared/source-control-next-step-decision.test.ts
  • src/shared/source-control-next-step-decision.ts
Files with no reviewable changes: 7
  • mobile/rpc-foundation/goldens/matrix-git.history-commit-files-git.commitcompare-1.json
  • mobile/src/source-control/MobileGitHistoryList.test.tsx
  • mobile/src/source-control/MobileSourceControlCreatePrEntry.tsx
  • config/flaky-test-pattern-baseline.txt
  • mobile/src/host-screen/workspace-options-pager.tsx
  • mobile/src/source-control/mobile-source-control-styles.ts
  • mobile/src/source-control/MobileSourceControlBranchCard.tsx

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 2 remain after this review.

"changes": "Änderungen",
"commits": "Commits",
"pullRequest": "Pull Request"
"changes": "Änderungen"

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.

Minor · Functional Correctness · Quick win

Supported by static analysis

Script executed:

#!/bin/bash
# Check which locales still define the keys that source code requests.
rg -n "sourceControl.hubTab.pullRequest|sourceControl.primaryAction.stageAll" mobile/src --type=ts
for f in mobile/src/i18n/locales/*.json; do
  echo "== $f"
  rg -n '"pullRequest"|"stageAll"' "$f" | head -5
done

Repository: stablyai/orca

Length of output: 2841


Script executed:

#!/bin/bash
set -e
printf '%s\n' '--- relevant diff ---'
git diff --unified=8 e5b87cb8e610735b61dcfa5e066eb7b2ad91a623 f113e7294cc973dd0da6e430ff56947b67b2eaef -- mobile/src/i18n/locales mobile/src/source-control/mobile-source-control-hub-tab.ts mobile/src/source-control/mobile-source-control-primary-action-label.ts

printf '%s\n' '--- exact sourceControl locale objects and key presence ---'
python3 - <<'PY'
import json
from pathlib import Path
for path in sorted(Path('mobile/src/i18n/locales').glob('*.json')):
    data = json.loads(path.read_text())
    sc = data.get('sourceControl', {})
    print(f'== {path}')
    print('sourceControl.hubTab =', json.dumps(sc.get('hubTab'), ensure_ascii=False, sort_keys=True))
    print('sourceControl.primaryAction =', json.dumps(sc.get('primaryAction'), ensure_ascii=False, sort_keys=True))
PY

printf '%s\n' '--- translation implementation and imports ---'
rg -n -F --glob '*.{ts,tsx}' -e "function translate" -e "const translate" -e "export.*translate" -e "from './i18n" -e "from '../i18n" -e "from '@/i18n" mobile/src | head -100
sed -n '1,100p' mobile/src/source-control/mobile-source-control-hub-tab.ts
sed -n '1,100p' mobile/src/source-control/mobile-source-control-primary-action-label.ts

Repository: stablyai/orca

Length of output: 41769


Script executed:

sed -n '1,100p' mobile/src/i18n/mobile-i18n.ts

Repository: stablyai/orca

Length of output: 3612


Restore the missing Source Control translations.

The mobile Source Control code still requests sourceControl.hubTab.pullRequest and sourceControl.primaryAction.stageAll. The non-English locale files no longer define those keys, so those labels fall back to English. Restore the existing translations in all affected locale files.

🐛 Suggested fix for German
     "hubTab": {
-      "changes": "Änderungen"
+      "changes": "Änderungen",
+      "pullRequest": "Pull Request"
     },
...
     "primaryAction": {
       "commit": "Committen",
       "forcePush": "Push erzwingen",
       "forcePushFromDesktop": "Push für den Branch dieses Pull Requests vom Desktop aus erzwingen",
       "publishBranch": "Branch veröffentlichen",
       "pull": "Pullen",
       "push": "Pushen",
+      "stageAll": "Alle vormerken",
       "sync": "Synchronisieren"
     },

Comment on lines +124 to +125
if (generation.current === current) {
reloadingFirstPage.current = false

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.

Minor · Stability & Availability · Quick win

Use the fallback message when the transport error has an empty message.

A transport rejection can carry an empty message, for example new Error('') with isRpcDeliveryUnknown: true. The fetchMobileGitHistory function rethrows that error unchanged. The catch block at Lines 126-130 then calls setError('').

resolveMobileHistoryScreenView tests if (error). An empty string is falsy. rows is still null and connected is true, so the view resolves to loading. The screen then shows "Loading commits…" with no Retry control. The screen stays in this state until the connection state, refreshKey, or refreshNonce changes.

The new golden matrix-git.history-branch-commits-git.history-1.json records this outcome. Its checkpoint transport-rejection-no-message:settled has the state 5ad8bfe89483, which is the loading state.

MobileCommitDetailPage already treats an empty message as a failure. Apply the same rule here, then re-record the golden.

🐛 Proposed fix
           setError(
-            err instanceof Error
-              ? err.message
-              : translate('sourceControl.gitHistoryList.loadFailed', 'Failed to load history')
+            (err instanceof Error && err.message) ||
+              translate('sourceControl.gitHistoryList.loadFailed', 'Failed to load history')
           )

Comment on lines +264 to +267
const agentNotice =
triageKey && !showWorkflowErrors
? { ...triage.noticeFor(triageKey), availability: triage.availability }
: null

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.

Minor · Functional Correctness · Quick win

Supported by static analysis

Script executed:

set -o pipefail
printf '%s\n' '--- hook references and changed block ---'
rg -n -F --glob '*.ts' --glob '*.tsx' \
  -e 'showWorkflowErrors' \
  -e 'agentNotice' \
  -e 'resolve_conflicts' \
  -e 'PRConflictingFilesSection' \
  mobile/src/source-control mobile/src | head -240
printf '%s\n' '--- target file outline ---'
ast-grep outline mobile/src/source-control/use-mobile-source-control-next-step.ts --view expanded
printf '%s\n' '--- target file lines 210-300 ---'
nl -ba mobile/src/source-control/use-mobile-source-control-next-step.ts | sed -n '210,300p'
printf '%s\n' '--- relevant PR-body definitions and usages ---'
rg -n -F --glob '*.ts' --glob '*.tsx' \
  -e 'PRConflictingFilesSection' \
  -e 'conflictSummary' \
  -e 'triageNotice' \
  -e 'agentNotice' \
  mobile/src | head -240

Repository: stablyai/orca

Length of output: 11445


Script executed:

set -o pipefail
printf '%s\n' '--- target hook ---'
nl -ba mobile/src/source-control/use-mobile-source-control-next-step.ts | sed -n '220,285p'
printf '%s\n' '--- exact bindings ---'
rg -n -F --glob '*.ts' --glob '*.tsx' \
  -e 'showWorkflowErrors' \
  -e 'agentNotice' \
  -e 'PRConflictingFilesSection' \
  -e 'resolve_conflicts' \
  -e 'conflictSummary' \
  mobile/src | head -300

Repository: stablyai/orca

Length of output: 6989


Script executed:

set -o pipefail
nl -ba mobile/src/source-control/use-mobile-source-control-next-step.ts | sed -n '220,285p'
rg -n -F --glob '*.ts' --glob '*.tsx' \
  -e 'showWorkflowErrors' \
  -e 'agentNotice' \
  -e 'PRConflictingFilesSection' \
  -e 'resolve_conflicts' \
  -e 'conflictSummary' \
  mobile/src | head -300

Repository: stablyai/orca

Length of output: 6946


Script executed:

set -o pipefail
printf '%s\n' '--- source-control panel around hook and bar ---'
nl -ba mobile/src/source-control/MobileSourceControlPanel.tsx | sed -n '190,245p;345,390p'
printf '%s\n' '--- mobile PR sidebar around triage and conflict section ---'
nl -ba mobile/src/components/MobilePRSidebar.tsx | sed -n '250,345p'
printf '%s\n' '--- conflict section implementation ---'
nl -ba mobile/src/components/pr-sidebar/PRConflictingFilesSection.tsx | sed -n '1,220p'
printf '%s\n' '--- next-step types and triage scope references ---'
nl -ba mobile/src/source-control/mobile-source-control-next-step.ts | sed -n '1,140p'
rg -n -F --glob '*.ts' --glob '*.tsx' \
  -e 'usePrAiTriage' \
  -e 'scope: ' \
  -e 'resolve-conflicts' \
  -e 'conflictsTriage' \
  mobile/src/components mobile/src/source-control mobile/src | head -300

Repository: stablyai/orca

Length of output: 41688


Script executed:

set -o pipefail
nl -ba mobile/src/source-control/MobileSourceControlPanel.tsx | sed -n '190,245p;345,390p'
nl -ba mobile/src/components/MobilePRSidebar.tsx | sed -n '250,345p'
nl -ba mobile/src/components/pr-sidebar/PRConflictingFilesSection.tsx | sed -n '1,220p'
nl -ba mobile/src/source-control/mobile-source-control-next-step.ts | sed -n '1,140p'
rg -n -F --glob '*.ts' --glob '*.tsx' \
  -e 'usePrAiTriage' \
  -e 'resolve-conflicts' \
  -e 'conflictsTriage' \
  mobile/src/components mobile/src/source-control

Repository: stablyai/orca

Length of output: 25105


Script executed:

set -o pipefail
printf '%s\n' '--- next-step decision definitions and resolve-conflicts producers ---'
rg -n -F --glob '*.ts' --glob '*.tsx' \
  -e 'type SourceControlNextStep' \
  -e 'resolve_conflicts' \
  -e 'scope:.*local' \
  -e 'scope:.*review' \
  src/shared mobile/src/source-control | head -220
nl -ba src/shared/source-control-next-step-decision.ts | sed -n '1,240p'
printf '%s\n' '--- conflict display predicate ---'
nl -ba mobile/src/components/pr-sidebar/pr-conflict-presentation.ts | sed -n '1,130p'
printf '%s\n' '--- hook conflict handler and triage state ---'
nl -ba mobile/src/source-control/use-mobile-source-control-next-step.ts | sed -n '140,215p'
nl -ba mobile/src/session/use-mobile-pr-ai-triage.ts | sed -n '1,180p'

Repository: stablyai/orca

Length of output: 18933


Script executed:

set -o pipefail
nl -ba mobile/src/components/MobilePRSidebar.tsx | sed -n '338,380p'
rg -n -F --glob '*.tsx' --glob '*.ts' \
  -e 'checksTriage' \
  -e 'AgentLaunchNotice' \
  mobile/src/components/pr-sidebar mobile/src/components | head -160

Repository: stablyai/orca

Length of output: 2178


Keep launch feedback visible when the PR body cannot render it.

On the Pull request tab, agentNotice is suppressed for every resolve_conflicts step. The PR conflict section can render its notice only when pr.mergeable === 'CONFLICTING'. A local working-tree conflict can therefore hide launch failures, “Waiting for desktop…”, or undelivered-prompt feedback.

Hide the bar notice only when the corresponding PR-body section can render it:

Suggested fix
--- "a/mobile/src/source-control/use-mobile-source-control-next-step.ts"
+++ "b/mobile/src/source-control/use-mobile-source-control-next-step.ts"
@@ -261,10 +261,14 @@
         ? 'resolve-conflicts'
         : null
   // On the PR tab the body's own AI button already shows this launcher's notice.
-  const agentNotice =
-    triageKey && !showWorkflowErrors
+  const bodyShowsTriageNotice =
+    showWorkflowErrors &&
+    (step.kind === 'fix_checks' ||
+      (step.kind === 'resolve_conflicts' && pr?.mergeable === 'CONFLICTING'))
+  const agentNotice =
+    triageKey && !bodyShowsTriageNotice
       ? { ...triage.noticeFor(triageKey), availability: triage.availability }
       : null
   const workflowError = showWorkflowErrors
     ? (state.actionError ?? state.commitFailureRecovery?.error ?? null)
     : null
Committable suggestion

IMPORTANT
Review the replacement and indentation, then test before committing.

Suggested change
const agentNotice =
triageKey && !showWorkflowErrors
? { ...triage.noticeFor(triageKey), availability: triage.availability }
: null
const bodyShowsTriageNotice =
showWorkflowErrors &&
(step.kind === 'fix_checks' ||
(step.kind === 'resolve_conflicts' && pr?.mergeable === 'CONFLICTING'))
const agentNotice =
triageKey && !bodyShowsTriageNotice
? { ...triage.noticeFor(triageKey), availability: triage.availability }
: null

@AmoabaKelvin
AmoabaKelvin force-pushed the sc-hub-next-step-bar branch 2 times, most recently from 74edb83 to 319e5a9 Compare November 1, 2026 18:38

@coderabbitai coderabbitai Bot left a comment

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.

Actionable comments posted: 1


Review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 106d60bf-8c06-44ec-a4c9-8826699cba36
Commits

Reviewing files that changed from the base of the PR and between f113e72 and 74edb83.

Files selected for processing: 27
  • config/flaky-test-pattern-baseline.txt
  • mobile/rpc-foundation/pilot-scenarios.json
  • mobile/src/i18n/en-runtime-required.json
  • mobile/src/i18n/locales/de.json
  • mobile/src/i18n/locales/en.json
  • mobile/src/i18n/locales/es.json
  • mobile/src/i18n/locales/fr.json
  • mobile/src/i18n/locales/ja.json
  • mobile/src/i18n/locales/ko.json
  • mobile/src/i18n/locales/pt.json
  • mobile/src/i18n/locales/ru.json
  • mobile/src/i18n/locales/tr.json
  • mobile/src/i18n/locales/zh-Hant.json
  • mobile/src/i18n/locales/zh.json
  • mobile/src/source-control/MobileCommitDetailPage.tsx
  • mobile/src/source-control/MobileCommitsScreen.test.tsx
  • mobile/src/source-control/MobileGitHistoryList.tsx
  • mobile/src/source-control/MobileSourceControlContent.test.tsx
  • mobile/src/source-control/MobileSourceControlContent.tsx
  • mobile/src/source-control/MobileSourceControlNextStepBar.tsx
  • mobile/src/source-control/MobileSourceControlPanel.tsx
  • mobile/src/source-control/mobile-git-read-operations.ts
  • mobile/src/source-control/mobile-source-control-primary-action.test.ts
  • mobile/src/source-control/mobile-source-control-primary-action.ts
  • mobile/src/test-support/bridged-parity/divergence-classes.test.ts
  • mobile/src/test-support/bridged-parity/divergence-classes.ts
  • mobile/src/test-support/rpc-recording/adapters/source-control-screen-read-mount-adapters.ts
Files with no reviewable changes: 1
  • config/flaky-test-pattern-baseline.txt
Files skipped from review as they are similar to previous changes: 11
  • mobile/src/i18n/locales/ko.json
  • mobile/src/i18n/locales/ja.json
  • mobile/src/i18n/locales/de.json
  • mobile/src/i18n/locales/pt.json
  • mobile/src/i18n/locales/zh.json
  • mobile/src/i18n/locales/es.json
  • mobile/src/i18n/locales/ru.json
  • mobile/src/i18n/locales/fr.json
  • mobile/src/i18n/locales/zh-Hant.json
  • mobile/src/i18n/locales/tr.json
  • mobile/src/i18n/locales/en.json

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 1 remain after this review.

}
leading={
shouldShowGenerateButton ? (
<Pressable

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.

Minor · Functional Correctness · Quick win

Give both composer controls a button role.

The AI-generation and commit Pressable controls have accessible names but no accessibilityRole. React Native for Web does not assign a button role to Pressable by default. Add accessibilityRole="button" to both controls so screen readers identify their purpose. (raw.githubusercontent.com)

Based on learnings: interactive elements should expose appropriate roles to screen readers.

Also applies to: 308-308

Source: Learnings

Changes and Pull request are the only segments. A bar at the foot of both
shows the branch's one next action: the commit box, push or pull, create
the review, resolve or fix with the workspace's agent, merge when ready,
merge, or why it can't. Commits opens as a pushed screen.
@AmoabaKelvin
AmoabaKelvin merged commit 78484aa into main Nov 1, 2026
51 checks passed
Nenzyz pushed a commit to Nenzyz/orca that referenced this pull request Nov 2, 2026
…yai#37104)

* feat(mobile): one next-step bar under both Source Control tabs

Changes and Pull request are the only segments. A bar at the foot of both
shows the branch's one next action: the commit box, push or pull, create
the review, resolve or fix with the workspace's agent, merge when ready,
merge, or why it can't. Commits opens as a pushed screen.

* fix(mobile): keep Merge reachable and show bar failures on both tabs

* test(mobile): expect the two Source Control segments in the page render test
Nenzyz pushed a commit to Nenzyz/orca that referenced this pull request Nov 2, 2026
…yai#37104)

* feat(mobile): one next-step bar under both Source Control tabs

Changes and Pull request are the only segments. A bar at the foot of both
shows the branch's one next action: the commit box, push or pull, create
the review, resolve or fix with the workspace's agent, merge when ready,
merge, or why it can't. Commits opens as a pushed screen.

* fix(mobile): keep Merge reachable and show bar failures on both tabs

* test(mobile): expect the two Source Control segments in the page render test
Nenzyz pushed a commit to Nenzyz/orca that referenced this pull request Nov 2, 2026
…yai#37104)

* feat(mobile): one next-step bar under both Source Control tabs

Changes and Pull request are the only segments. A bar at the foot of both
shows the branch's one next action: the commit box, push or pull, create
the review, resolve or fix with the workspace's agent, merge when ready,
merge, or why it can't. Commits opens as a pushed screen.

* fix(mobile): keep Merge reachable and show bar failures on both tabs

* test(mobile): expect the two Source Control segments in the page render test
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