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

Sort bookmarks in bookmarks panel #3001

Conversation

jotaemepereira
Copy link
Collaborator

@jotaemepereira jotaemepereira commented Jul 19, 2024

Task/Issue URL: https://app.asana.com/0/1204006570077678/1207680520620398/f
Tech Design URL:
CC:

Description

Acceptance criteria

AC1
Given a user that opens the bookmarks panel
When the user taps on the sort icon without any saved sort option
Then a menu with the following options appears Manual (selected), Name (unselected), Ascending (disabled) and Descending (disabled)
And sort icon is the ascending one

AC2
Given a user that taps the sort button
When the user taps on the name option
Then the tree view is ordered by title ascending
And the Ascending (selected by default) and Descending options are available.

AC3
Given a user that taps the sort button
When the user taps on the Descending option
Then the tree view is ordered by title descending
And the sort icon changes to descending

AC4
Given a user that taps the sort button
When the user taps on the Manual option
Then the tree view is ordered by proximity to the root

AC5
Given a user in the bookmarks panel
When the user starts a search
Then the list of results should respect the selected sorting order

AC6
Given a user that restarted the browser
When the user goes to the bookmarks panel
Then the last selected sorting option should be remembered
And the tree view should be sorted by the last remembered

Demo

sort-demo.mov

Steps to test this PR

  1. Open the browser
  2. Go to the bookmarks panel
  3. See the sort icon is being shown
  4. Check the acceptance criteria is met

Definition of Done:

Internal references:

Pull Request Review Checklist
Software Engineering Expectations
Technical Design Template
Pull Request Documentation

Copy link

github-actions bot commented Jul 19, 2024

Warnings
⚠️ PR has more than 500 lines of code changing. Consider splitting into smaller PRs if possible.

Generated by 🚫 dangerJS against fc01a2f

Copy link
Collaborator

@ayoy ayoy left a comment

Choose a reason for hiding this comment

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

Great job @jotaemepereira! Sorting works great and the code is nice and clean. Just please update string comparison to use localized case insensitive compare and it's good to go. Thanks!

@ayoy ayoy assigned jotaemepereira and unassigned ayoy and samsymons Jul 23, 2024
@jotaemepereira jotaemepereira force-pushed the feature/search-and-sort-bookmarks-panel branch from a4b209c to 832d72d Compare July 23, 2024 22:23
Copy link
Collaborator

@samsymons samsymons left a comment

Choose a reason for hiding this comment

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

Nothing more to add from Dominik's review; changes look clean, thanks for this!

@jotaemepereira jotaemepereira force-pushed the feature/search-and-sort-bookmarks-panel branch from 832d72d to b79737f Compare July 24, 2024 11:54
@jotaemepereira jotaemepereira merged commit c82227f into feature/search-and-sort-bookmarks-panel Jul 24, 2024
20 checks passed
@jotaemepereira jotaemepereira deleted the juan/sort-bookmarks-in-panel branch July 24, 2024 12:25
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.

3 participants