Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hide original tab search button when pref is off #18814

Merged
merged 1 commit into from
Jun 9, 2023
Merged

Conversation

sangwoo108
Copy link
Contributor

@sangwoo108 sangwoo108 commented Jun 8, 2023

When the preference is turned off, we shouldn't show the button

Resolves brave/brave-browser#30829

Submitter Checklist:

  • I confirm that no security/privacy review is needed, or that I have requested one
  • There is a ticket for my issue
  • Used Github auto-closing keywords in the PR description above
  • Wrote a good PR/commit description
  • Squashed any review feedback or "fixup" commits before merge, so that history is a record of what happened in the repo, not your PR
  • Added appropriate labels (QA/Yes or QA/No; release-notes/include or release-notes/exclude; OS/...) to the associated issue
  • Checked the PR locally:
    • npm run test -- brave_browser_tests, npm run test -- brave_unit_tests wiki
    • npm run lint, npm run presubmit wiki, npm run gn_check, npm run tslint
  • Ran git rebase master (if needed)

Reviewer Checklist:

  • A security review is not needed, or a link to one is included in the PR description
  • New files have MPL-2.0 license header
  • Adequate test coverage exists to prevent regressions
  • Major classes, functions and non-trivial code blocks are well-commented
  • Changes in component dependencies are properly reflected in gn
  • Code follows the style guide
  • Test plan is specified in PR before merging

After-merge Checklist:

Test Plan:

This applies to only non-win10 platform.

Manual

  • Turn off tab search button from brave://settings/appearance
  • open up a new window - tab search button shouldn't be on the new window
  • Toggle vertical tab strip on and off - tab search button shouldn't reappear

Automated

VerticalTabStripBrowserTest.OriginalTabSearchButton

When the preference is turned off, we shouldn't show the button
@sangwoo108 sangwoo108 marked this pull request as ready for review June 8, 2023 07:36
Copy link
Contributor

@fallaciousreasoning fallaciousreasoning left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@kjozwiak
Copy link
Member

kjozwiak commented Jun 12, 2023

Verification PASSED on macOS 13.4 Ventura x64 using the following build(s):

Brave | 1.54.54 Chromium: 114.0.5735.110 (Official Build) nightly (x86_64)
--- | ---
Revision | 1c828682b85bbc70230a48f5e345489ec447373e-refs/branch-heads/5735_90@{#13}
OS | macOS Version 13.4 (Build 22F66)

Reproduced the original issue using the STR/Cases outlined via brave/brave-browser#30829 (comment) running 1.54.47 Chromium: 114.0.5735.110 as per the following:

  • Disabled Show tab search button and the button was still appearing when opening new windows

Screenshot 2023-06-12 at 5 08 27 PM

Using the STR/Cases outlined via brave/brave-browser#30829 (comment), verified that the search button was being removed correctly as per the following:

  • ensured that toggling Show tab search button via brave://settings/appearance correctly removes the search button
    • ensured it's being removed from the current active window
    • ensured it's being removed from all other currently opened windows
    • ensured it's not being added when opening new windows
  • ensured that the Show tab search button state is persistent (not being enabled/disabled when it shouldn't)
    • ensured that the Show tab search button state is persistent across several restarts

As discussed with @rebron via https://bravesoftware.slack.com/archives/CHGKGMHDJ/p1686290856620189, the Search button does not get removed from vertical tabs when enabled. Essentially toggling Show tab search button doesn't do anything on macOS when vertical tabs are enabled.

kjozwiak pushed a commit that referenced this pull request Jun 12, 2023
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.

"Show tab search button" setting resets when a new window is open
3 participants