Skip to content

Disable open new tab with long press in NTP#9113

Open
nalcalag wants to merge 1 commit into
developfrom
feature/noelia/disable_long_press_new_tab
Open

Disable open new tab with long press in NTP#9113
nalcalag wants to merge 1 commit into
developfrom
feature/noelia/disable_long_press_new_tab

Conversation

@nalcalag

@nalcalag nalcalag commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

Task/Issue URL: https://app.asana.com/1/137249556945/project/1204912272578138/task/1215861941732705?focus=true
Tech Design URL (if applicable):

Description

Disable opening a new tab with long press if already in a new tab

Steps to test this PR

New Tab Page

  • Install from branch
  • Open a new tab
  • Long press in the new tab menu item
  • Verify it is disable and nothing happens

Browser showing

  • Navigate to any website or perform a search
  • Long press in the new tab menu item
  • Verify it opens a new tab

No UI changes


Note

Low Risk
Small guard in tab menu handling with no auth, data, or API changes; behavior is covered by new unit tests.

Overview
Long-pressing the tabs/new-tab control no longer opens another tab when the user is already on the new tab page (browserShowing is false). The early return applies only to long-press; normal new-tab menu actions are unchanged.

When the browser is showing a site or SERP, long-press still opens a new tab and fires TAB_MANAGER_NEW_TAB_LONG_PRESSED. Unit tests were split to assert both behaviors.

Reviewed by Cursor Bugbot for commit 6f2a622. Bugbot is set up for automated code reviews on this repo. Configure here.

nalcalag commented Jul 6, 2026

Copy link
Copy Markdown
Contributor Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

@nalcalag nalcalag marked this pull request as ready for review July 6, 2026 09:46

@anikiki anikiki 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.

Looks good and works as expected! 🎉

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.

2 participants