You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat(browser): add a setting to open links as a tab instead of a split - #41252
Clicking a link in a terminal that fills the whole workspace opens Orca's browser in a new pane beside it. Some people want the link as a new tab in the same pane instead. This adds a switch for that.
What Changed
New setting under Browser > Link Routing: Open links in a split. On by default, so nothing changes unless you turn it off.
Off: when a link would have created a split (no browser visible, the source pane is the only one), it opens as a new tab in the pane you clicked.
A visible browser pane or a neighbor pane still receives the link, same as today.
With the setting off, the terminal link popover hides "Open in new tab" when the link would otherwise have split, since a plain open now does the same thing. With a neighbor pane, the action stays, because a plain open goes to the neighbor.
Combined with Open links in the background, the link joins the clicked pane as an unselected tab and focus stays in the terminal.
Mechanism: resolveLinkOpenSidePlacement takes an allowSplit flag and returns the source group instead of a split target. The local and runtime link paths (selectBrowserLinkDestination, resolveHttpLinkBrowserPlacement) and the popover availability check pass the setting through. File links are unchanged.
Why
#31844 made split-beside the only behavior for HTTP links. That is a good default, but there is no way back to tab-in-place for users with a single pane who do not want their layout changed by every link. Adding the flag at the one function that decides "split" keeps the change small and leaves visible-browser and neighbor-pane routing alone.
Same flow both times: a fresh folder workspace with one terminal pane, echo https://example.com, then Cmd+click the link.
Before: "Open links in a split" on (default)
After: off
New toggle under Settings > Browser > Link routing:
Testing
I manually tested these changes locally
Automated tests added/updated, or explained why not below
Every added test fails without this change and avoids the test anti-patterns
Manual: ran the PR build with pnpm dev:fresh on macOS and Cmd+clicked a terminal link with the toggle on and off (screenshots above).
Added one case to browser-link-destination.test.ts: a single occupied pane with the setting off resolves to that pane, not a split. It fails when allowSplit is ignored. On macOS, pnpm tc and oxlint/oxfmt on the changed files pass. pnpm check:changed passes except for 48 src/main/agent-hooks unit tests, which fail the same way on the base commit locally.
Risk
Low. Default is on, and a missing key reads as on, so existing users see no change. The riskiest part is a link landing in the wrong pane with the setting off; the fallback target is the pane the user clicked. Plain revert backs it out; a saved openLinksInAppInSplit: false is ignored after revert.
Level: Low
AI Disclosure
Claude Code (Claude Opus 5.5) wrote the code, the test, and this description.
Review
Cross-platform: no platform-specific code; setting copy has no shortcut labels.
SSH/remote: runtime path uses the same placement (prepareRuntimeBrowserLink passes the group through); no new IPC or contract.
Agents/integrations: not affected.
Performance: one boolean read per link open.
UI: reuses SettingsSwitchRow and the indented layout of the background toggle; English-only copy per the i18n source rules.
Security: none.
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
Ensure no issues in: Security, Cross-platform support (Linux, Windows, Mac), Remote SSH, Mobile, general backwards compatibility, performance
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)
I stated the risk: what could break, for whom, and how to back it out
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)
No actionable comments were generated in the recent review.
Walkthrough
Adds the openLinksInAppInSplit setting, enabled by default. When disabled, link placement in the single-pane fallback uses the source pane instead of creating a split. The preference is applied to browser and HTTP link routing. A searchable switch is added to Browser settings, with English title, description, and search terms. A test covers disabled splitting for a single-pane workspace.
Severity of issue fixed: Medium
Merge Risk: Minimal · up to 64f6d
Adds an optional Open links in a split setting that is on by default, so existing users see no change. No outstanding defects remain in the reviewed changes, and the risk is minimal.
Pre-merge checks: 4
Check name
Status
Explanation
Title check
The title "feat(browser): add a setting to open links as a tab instead of a split" names the main change: a new browser setting that makes links open as a tab rather than a split. The changeset adds t…
Description check
The description follows the repository template. It includes ELI5, What Changed, Why, a linked issue (Fixes #41251), Visual Proof with before/after images and a settings screenshot, Testing with the m…
Linked Issues check
Directly linked issue #41251 requires: (1) an on-by-default toggle under Settings > Browser > Link Routing, next to "Open links in the background"; (2) when off, a link that would create a split opens…
Out of Scope Changes check
Every changed file serves the requested setting. The changes cover the setting type and default (browser-link-opening-settings.ts, default-global-settings.ts), the settings UI row and search entries (…
Full details: Title check
Explanation
The title "feat(browser): add a setting to open links as a tab instead of a split" names the main change: a new browser setting that makes links open as a tab rather than a split. The changeset adds the "Open links in a split" toggle (BrowserLinkRoutingSplitSetting), wires an allowSplit flag through link placement, and passes it to the HTTP link paths. The title is specific and matches the linked issue and objectives.
Full details: Description check
Explanation
The description follows the repository template. It includes ELI5, What Changed, Why, a linked issue (Fixes #41251), Visual Proof with before/after images and a settings screenshot, Testing with the manual test and the added unit test, Risk with level Low and a revert note, AI Disclosure, Review, the upstream boundary checkbox, Notes, and Checklist. Its gaps are small: the pnpm lint, typecheck, test, and build checklist item is unchecked, and the description does not state which platforms were tested beyond macOS.
Full details: Linked Issues check
Explanation
Directly linked issue #41251 requires: (1) an on-by-default toggle under Settings > Browser > Link Routing, next to "Open links in the background"; (2) when off, a link that would create a split opens as a new tab in the clicked pane; (3) a visible browser pane or neighbor pane still receives the link. Evidence: BrowserLinkRoutingSplitSetting is rendered in the routing group (BrowserPane.tsx) and has a search entry (browser-search.ts, browser-link-routing-copy.ts). The control treats the setting as on unless it is explicitly false, and the default is true (default-global-settings.ts). The reviewed head diff of adjacent-link-open-group.ts confirms that resolveLinkOpenSidePlacement takes allowSplit (default true). The split branch is unchanged when allowed. When splitting is disallowed, it returns { groupId: sourceGroupId }. This fallback sits after the existing visible-browser and neighbor-pane checks, so those paths are unchanged. selectBrowserLinkDestination and resolveHttpLinkBrowserPlacement pass the setting through, and canHttpLinkOpenInSourceGroup uses the same check for popover availability. Coding requirements are covered. Non-coding items in the PR (manual testing, screenshots) are not required. Minor note, not blocking: the raw summary lists the added test in browser-link-open.test.ts, while the PR description names browser-link-destination.test.ts. Test placement does not change the requirement result.
Full details: Out of Scope Changes check
Explanation
Every changed file serves the requested setting. The changes cover the setting type and default (browser-link-opening-settings.ts, default-global-settings.ts), the settings UI row and search entries (BrowserPane.tsx, browser-search.ts, BrowserLinkRoutingSplitSetting.tsx, browser-link-routing-copy.ts, en.json), the placement flag in the shared placement helpers (adjacent-link-open-group.ts, link-open-intent.ts), the local and runtime HTTP link paths (browser-link-destination.ts, http-link-browser-placement.ts, http-link-routing.ts), a telemetry whitelist entry for the new key (telemetry-property-schemas.ts), and a focused test. The summary reports no file-link changes, which matches the PR statement that file links are unchanged. No unrelated product behavior appears in the summary or the verified diff.
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.
Files skipped from review as they are similar to previous changes: 1
src/renderer/src/i18n/locales/en.json
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.
@AmoabaKelvin Had Opus whip this quick setting change. There was old tab opening behavior that was removed recently that was actually my preference. I want to be able to cmd + click a link and have it open as a new tab as a default behavior, opening multiple links is now frustrating.
@brennanb2025 would appreciate a look here. This is just adding an option to reintroduce old browser behavior before recent updates. Thanks!
This branch has not been deployed
No deployments
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
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.
ELI5
Clicking a link in a terminal that fills the whole workspace opens Orca's browser in a new pane beside it. Some people want the link as a new tab in the same pane instead. This adds a switch for that.
What Changed
resolveLinkOpenSidePlacementtakes anallowSplitflag and returns the source group instead of a split target. The local and runtime link paths (selectBrowserLinkDestination,resolveHttpLinkBrowserPlacement) and the popover availability check pass the setting through. File links are unchanged.Why
#31844 made split-beside the only behavior for HTTP links. That is a good default, but there is no way back to tab-in-place for users with a single pane who do not want their layout changed by every link. Adding the flag at the one function that decides "split" keeps the change small and leaves visible-browser and neighbor-pane routing alone.
Linked Issue
Fixes #41251
Visual Proof
Same flow both times: a fresh folder workspace with one terminal pane,
echo https://example.com, then Cmd+click the link.New toggle under Settings > Browser > Link routing:
Testing
Manual: ran the PR build with
pnpm dev:freshon macOS and Cmd+clicked a terminal link with the toggle on and off (screenshots above).Added one case to
browser-link-destination.test.ts: a single occupied pane with the setting off resolves to that pane, not a split. It fails whenallowSplitis ignored. On macOS,pnpm tcand oxlint/oxfmt on the changed files pass.pnpm check:changedpasses except for 48src/main/agent-hooksunit tests, which fail the same way on the base commit locally.Risk
Low. Default is on, and a missing key reads as on, so existing users see no change. The riskiest part is a link landing in the wrong pane with the setting off; the fallback target is the pane the user clicked. Plain revert backs it out; a saved
openLinksInAppInSplit: falseis ignored after revert.Level: Low
AI Disclosure
Claude Code (Claude Opus 5.5) wrote the code, the test, and this description.
Review
prepareRuntimeBrowserLinkpasses the group through); no new IPC or contract.SettingsSwitchRowand the indented layout of the background toggle; English-only copy per the i18n source rules.Agent skill upstream boundary
Notes
Ensure no issues in: Security, Cross-platform support (Linux, Windows, Mac), Remote SSH, Mobile, general backwards compatibility, performance
Checklist
N/Awith reasonpnpm lint,pnpm typecheck,pnpm test, andpnpm buildpass (or CI will cover; local preferred)