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

feat: 3772 - access to nutrion photo from nutrition page #3851

Merged
merged 2 commits into from
Apr 6, 2023

Conversation

monsieurtanuki
Copy link
Contributor

New file:

  • product_image_unswipeable_view.dart: Display of the photo of a product image field.

Impacted files:

  • nutrition_page_loaded.dart: added a "go to picture" button
  • product_image_swipeable_view.dart: minor refactoring

What

  • A read/write access to the nutrition photo is now provided from the nutrition page, via a button.

Screenshot

nutrition page with new button new unswipeable nutrition page
Screenshot_2023-04-06-09-07-29 Screenshot_2023-04-06-09-07-37

Fixes bug(s)

New file:
* `product_image_unswipeable_view.dart`: Display of the photo of a product image field.

Impacted files:
* `nutrition_page_loaded.dart`: added a "go to picture" button
* `product_image_swipeable_view.dart`: minor refactoring
Impacted file:
* `product_image_unswipeable_view.dart`: now as a stateless widget.
Copy link
Member

@teolemon teolemon left a comment

Choose a reason for hiding this comment

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

  • The unswipeable behavior is okay-ish with me.
  • However, I usually like to swipe to see if other pictures are correctly cropped and available

@codecov-commenter
Copy link

Codecov Report

Merging #3851 (3139469) into develop (54560ff) will decrease coverage by 0.02%.
The diff coverage is 0.00%.

@@             Coverage Diff             @@
##           develop    #3851      +/-   ##
===========================================
- Coverage    10.77%   10.75%   -0.02%     
===========================================
  Files          269      270       +1     
  Lines        13420    13441      +21     
===========================================
  Hits          1446     1446              
- Misses       11974    11995      +21     
Impacted Files Coverage Δ
...h_app/lib/pages/product/nutrition_page_loaded.dart 0.00% <0.00%> (ø)
...ib/pages/product/product_image_swipeable_view.dart 0.00% <0.00%> (ø)
.../pages/product/product_image_unswipeable_view.dart 0.00% <0.00%> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@monsieurtanuki monsieurtanuki merged commit d5a4d27 into openfoodfacts:develop Apr 6, 2023
@monsieurtanuki
Copy link
Contributor Author

Thank you @teolemon for your review!

I assumed it was less confusing to go to only the nutrition picture on a "go to nutrition picture" button.
But for advanced users, we probably need to do some UX refactoring around the access to pictures.

Don't hesitate to create a new issue if you really prefer to go to swipeable pictures.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add the ability to take/see/edit the nutrition photo in the ingredients input
3 participants