Add button to open PR link on mobile#7879
Conversation
Introduce an external link action in the header of the Mobile PR View Panel. This provides a persistent and easily accessible shortcut to open the current pull request's canonical URL in the system browser.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughMobilePrViewPanel now includes an "open pull request on the web" control in both its embedded and full-screen headers. It imports ExternalLink and ChevronLeft icons plus an openMobilePrUrl helper, derives the PR URL and number when the sidebar state is ready, and conditionally renders a Pressable that opens the PR URL via the helper. Additionally, explanatory comments in PRSidebarHeader were updated to clarify that the existing badge/#number external-link control opens the PR using pr.url in the phone browser. No exported or public API declarations were altered. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
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. Comment |
Summary
Adds an external link button (
ExternalLinkicon) in theMobilePrViewPanelheader, allowing users to open the current pull request's web URL in their mobile browser.Screenshots
Adds an
ExternalLinkbutton to the right of the 'Pull Request' title in the mobile PR view header.Testing
pnpm lintpnpm typecheckpnpm testpnpm buildAI Review Report
Reviewed the mobile-specific UI additions. The review verified layout behavior on mobile and confirmed proper React Native accessibility props (
accessibilityRole="link"and descriptiveaccessibilityLabelincorporating the PR number when available). Touch target enhancement is handled viahitSlopof 8. Desktop/Electron cross-platform compatibility checks are not applicable since this change is strictly within themobilepackage.Security Audit
Reviewed the use of
openMobilePrUrlfor opening external browser links. URL handling safely handles deep links to standard pull request hosts. No secrets, command execution, or sensitive IPC channels are touched.Notes
None.