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

Create a plan and designs for a user-friendly lists system #1073

Closed
5 of 20 tasks
Tracked by #523
teolemon opened this issue Feb 6, 2022 · 8 comments · Fixed by #1649
Closed
5 of 20 tasks
Tracked by #523

Create a plan and designs for a user-friendly lists system #1073

teolemon opened this issue Feb 6, 2022 · 8 comments · Fixed by #1649
Assignees
Labels
lists 🎨 Mockups available Some mockups are available for this issue. Please check everything is ok before starting coding. needs agreement P2 🎨 UI / UX
Milestone

Comments

@teolemon
Copy link
Member

teolemon commented Feb 6, 2022

What

  • Create a plan and designs for a user-friendly lists system
    • Examine if/what we can reuse from the previous system
    • Agree on the data structure (potentially including a non-used quantity field to make it future proof)
    • Create a product page widget to list which lists the product belongs to
      • Lists - Product page insert
    • Create a "Add/Remove from list" widget and use it in a modal that can be invoked from the product page
      • Lists - Lists modal
    • Create a "Create List" widget and use it in a modal that can be invoked from the "Add/Remove from list" modal and from the main Lists view
      • Lists - Create a new list modal
    • Create a "list of existing lists" view
      • List of lists
    • Create a layout to handle lists
      • Actions on lists
      • Export selected lists
    • Create a layout to handle empty lists
      • Empty list
    • Create a layout to list (and act on) products present in a list
      • Unsorted list with action toolbar checkbox
      • Unsorted list with action toolbar open
      • Unsorted list with action toolbar

Part of

Early mockups for discussion

image

Mockups on Figma

@teolemon teolemon closed this as completed Feb 6, 2022
@teolemon teolemon reopened this Feb 6, 2022
@teolemon teolemon added the lists label Feb 6, 2022
@teolemon teolemon added 🎨 Mockups available Some mockups are available for this issue. Please check everything is ok before starting coding. 🎨 UI / UX labels Mar 9, 2022
@teolemon teolemon added the P2 label Mar 31, 2022
@teolemon teolemon added this to the V 1 milestone Mar 31, 2022
@teolemon teolemon moved this from Todo (ready 2 dev) to To discuss and validate in 🤳🥫 The Open Food Facts mobile app (Android & iOS) Apr 4, 2022
@teolemon
Copy link
Member Author

@monsieurtanuki @stephanegigandet @g123k @M123-dev after several UX iterations, here's the plan for lists.

@monsieurtanuki
Copy link
Contributor

@teolemon My main concern is that one: where do you go to the "All the Lists" page from?

Other more minor comments:

  1. Side-effect - I suggest an "Add to a list" button when the product does not belong to any user list
  2. When you say "Shopping lists" or "Kitchen", we're talking about lists that the user created and named that way, right? Those are not list subtypes, right?
  3. Your list buttons have different colors in your mock-ups - where do those colors come from?
  4. There are 3 list types: "app history" (history and scan history), "search" ("keyword search", "category search") and to-be-created "user" (unlimited number of user-defined lists), right?
  5. Your "import" and "export" icons are both wrong - besides, I would add a "clear" button, and I would put those actions at the "list" level, not at the "listS" level (actually in the "list" page I can already see those actions)
  6. Agreed that from a database point of view, a list of products is an ordered list of barcodes, and in option data attached to some barcodes (for the moment no data, but perhaps one day quantity, perhaps one day best before date)

@monsieurtanuki monsieurtanuki self-assigned this Apr 16, 2022
@M123-dev
Copy link
Member

Just out of curiosity and not to start a big discussion about if, if so probably better in a own dedicated issue but what db are we going for, back to a SQLLite solution or are we sticking with hive for the lists?
@monsieurtanuki @teolemon

@monsieurtanuki
Copy link
Contributor

@M123-dev There's no obvious reason to go back to SQFlite because of lists. Lists only contain barcodes. Products are bigger: if we had to move back to SQFlite it would probably be because of products. Unless users get very fond of lists. The reward for success! Let's stick to hive for the moment.

@g123k
Copy link
Collaborator

g123k commented Apr 16, 2022

@M123-dev There's no obvious reason to go back to SQFlite because of lists. Lists only contain barcodes. Products are bigger: if we had to move back to SQFlite it would probably be because of products. Unless users get very fond of lists. The reward for success! Let's stick to hive for the moment.

+1
Also if Hive is too limited, the creator of the library has created a new one with extended query features: https://github.com/isar/isar

@teolemon
Copy link
Member Author

@M123-dev related to the Delete Button on History
https://user-images.githubusercontent.com/1689815/163598606-0c465dc6-e322-42f2-974c-34418b98c78c.png

@teolemon teolemon moved this from To discuss and validate to In Progress in 🤳🥫 The Open Food Facts mobile app (Android & iOS) Apr 25, 2022
monsieurtanuki added a commit to monsieurtanuki/smooth-app that referenced this issue Apr 25, 2022
New file:
* `product_list_user_dialog_helper.dart`: Dialog helper class for user product list.

Impacted files:
* `constant_icons.dart`: added method `getForwardIcon`
* `dao_product_list.dart`: added methods related to user list management
* `new_product_page.dart`: action bar with "add to list" button instead of just "edit product" button; added "lists" widget
* `product_list.dart`: added `ProductListType.USER` as "End-user product list"
* `product_list_page.dart`: added "clear" and "rename" popup options
* `product_query_page_helper.dart`: impact of new `ProductListType.USER`
monsieurtanuki added a commit to monsieurtanuki/smooth-app that referenced this issue Apr 25, 2022
Impacted file:
* `new_product_page.dart`
@teolemon teolemon linked a pull request Apr 26, 2022 that will close this issue
@teolemon teolemon moved this from In Progress to Pull Requests in 🤳🥫 The Open Food Facts mobile app (Android & iOS) Apr 26, 2022
monsieurtanuki added a commit to monsieurtanuki/smooth-app that referenced this issue Apr 26, 2022
Impacted files:
* `app_en.arb`: localizations in English
* `app_fr.arb`: localizations in French
* `edit_product_page.dart`: unrelated refactoring
* `new_product_page.dart`: localizations
* `product_list_page.dart`: localizations
* `product_list_user_dialog_helper.dart`: localizations
* `product_title_card.dart`: unrelated refactoring
* `smooth_product_card_found.dart`: unrelated refactoring
monsieurtanuki added a commit to monsieurtanuki/smooth-app that referenced this issue Apr 26, 2022
teolemon added a commit that referenced this issue Apr 26, 2022
* feat: #1073 - user-defined product lists

New file:
* `product_list_user_dialog_helper.dart`: Dialog helper class for user product list.

Impacted files:
* `constant_icons.dart`: added method `getForwardIcon`
* `dao_product_list.dart`: added methods related to user list management
* `new_product_page.dart`: action bar with "add to list" button instead of just "edit product" button; added "lists" widget
* `product_list.dart`: added `ProductListType.USER` as "End-user product list"
* `product_list_page.dart`: added "clear" and "rename" popup options
* `product_query_page_helper.dart`: impact of new `ProductListType.USER`

* feat: #1073 - lint check fix

Impacted file:
* `new_product_page.dart`

* feat: #1073 - localizations and refactoring

Impacted files:
* `app_en.arb`: localizations in English
* `app_fr.arb`: localizations in French
* `edit_product_page.dart`: unrelated refactoring
* `new_product_page.dart`: localizations
* `product_list_page.dart`: localizations
* `product_list_user_dialog_helper.dart`: localizations
* `product_title_card.dart`: unrelated refactoring
* `smooth_product_card_found.dart`: unrelated refactoring

* Update packages/smooth_app/lib/l10n/app_en.arb

* Update packages/smooth_app/lib/l10n/app_en.arb

Co-authored-by: Pierre Slamich <pierre.slamich@gmail.com>
Repository owner moved this from Pull Requests to Done in 🤳🥫 The Open Food Facts mobile app (Android & iOS) Apr 26, 2022
monsieurtanuki added a commit to monsieurtanuki/smooth-app that referenced this issue Apr 26, 2022
Impacted file:
* `new_product_page.dart`: same title style as KP; no more confusing icon
monsieurtanuki added a commit that referenced this issue Apr 26, 2022
Impacted file:
* `new_product_page.dart`: same title style as KP; no more confusing icon
@monsieurtanuki
Copy link
Contributor

@teolemon Still this question: from where should we get to the "list of existing lists" page?
In the meanwhile, working on the "export/import" feature.

@teolemon
Copy link
Member Author

Fixed 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lists 🎨 Mockups available Some mockups are available for this issue. Please check everything is ok before starting coding. needs agreement P2 🎨 UI / UX
Development

Successfully merging a pull request may close this issue.

4 participants