Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Fix gridLayout pinning action bug #5406

Merged
merged 1 commit into from
Nov 4, 2016
Merged

Fix gridLayout pinning action bug #5406

merged 1 commit into from
Nov 4, 2016

Conversation

cezaraugusto
Copy link
Contributor

@cezaraugusto cezaraugusto commented Nov 4, 2016

  • Submitted a ticket for my issue if one did not already exist.
  • Used Github auto-closing keywords in the commit message.
  • Ran git rebase -i to squash commits (if needed).

Fix #5337

Auditors: @bsclifton @bbondy

/cc @luixxiul @srirambv

Our topSites grid have actions connected to each other (pinning/removing/reordering),
so we must ensure all of them are working properly while doing multiple actions.

Test Plan:

  • Access new tab page;
  • Access several websites (you can grab this JSON https://github.com/cezaraugusto/brave-json/blob/master/newtab-3-rows.json
    and copy/paste on session-store-1, it has 18 sites);
  • Reordering a tile should work on any position;
  • Pin a site. Pinning a site should add a Pin icon on top-right corner and be kept on its position (not jump);
  • Keep in mind the website position and reorder it to a new position;
  • Access another website and get back to new tab. Ensure that your last pinned website kept its position;
  • Remove that site (pinned or not);
  • A modal will open. "Undo" removing;
  • There should be no pinned icon;
  • Website should be back to its original position;
  • Pin several websites;
  • Reorder pinned websites;
  • Access a new website;
  • Go back to new tab page: pinned sites should remember their positions;
  • Remove a website on removal modal and hit "restore all";
  • All sites must be unpinned.

Fix #5337

Auditors: @bsclifton @bbondy

/cc @luixxiul @srirambv

Our topSites grid have actions connected to each other (pinning/removing/reordering),
so we must ensure all of them are working properly while doing multiple actions.

Test Plan:

* Access new tab page;
* Access several websites (you can grab this JSON https://github.com/cezaraugusto/brave-json/blob/master/newtab-3-rows.json
and copy/paste on session-store-1, it has 18 sites);
* Reordering a tile should work on any position;
* Pin a site. Pinning a site should add a Pin icon on top-right corner and be kept on its position (not jump);
* Keep in mind the website position and reorder it to a new position;
* Access another website and get back to new tab. Ensure that your last pinned website kept its position;
* Remove that site (pinned or not);
* A modal will open. "Undo" removing;
* There should be no pinned icon;
* Website should be back to its last position;
* Pin several websites;
* Reorder pinned websites;
* Access a new website;
* Go back to new tab page: pinned sites should remmember their positions;
* Remove a website on removal modal and hit "restore all";
* All sites must be unpinned.
if (updatedStamp === this.state.updatedStamp) {
return
}

// Ensure top sites only has unique values
Copy link
Member

Choose a reason for hiding this comment

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

Since this logic is removed (which is OK), maybe we can move what's left into ipc.on() line 😄 I originally had added this because my state got into a situation where I had many duplicates, which caused problems

Copy link
Member

Choose a reason for hiding this comment

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

(can be done as a follow up in a later commit)

@bsclifton
Copy link
Member

LGTM! Thanks for sticking this one out and taking the time to manually test each of those scenarios; this page is looking great 😄

@srirambv
Copy link
Collaborator

This is not working on Windows. The pinned tabs all moves to the top of the grid after opening a newtab. Will the fix for #5337 fix this as well?

@luixxiul luixxiul added the needs-info Another team member needs information from the PR/issue opener. label Nov 16, 2016
@cezaraugusto
Copy link
Contributor Author

@srirambv sorry, it was fixed by #5645, which landed on master today.

I have also added steps for manual testing, feel free to ping me if I missed something.

@luixxiul luixxiul removed the needs-info Another team member needs information from the PR/issue opener. label Nov 16, 2016
@cezaraugusto cezaraugusto deleted the feature/newtab/5337 branch July 25, 2017 07:30
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants