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: Photo gallery with tabs #5872

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

g123k
Copy link
Collaborator

@g123k g123k commented Nov 17, 2024

Hi everyone!

Here's the final touch for the photo gallery.
🎥 Video: https://github.com/user-attachments/assets/8308da52-1577-492d-afe6-4d1e35f48e20

There are now tabs for languages on top of the screen:
IMG_1375

And the action button is not a FAB anymore, but a footer button:
IMG_1375

@github-actions github-actions bot added 🥫 Product page ✏️ Editing Many products are incomplete and don't have Nutri-Score, Eco-Score…so editing is important for users 🖼️ Photos - Cropping labels Nov 17, 2024
@codecov-commenter
Copy link

Codecov Report

Attention: Patch coverage is 0.89286% with 444 lines in your changes missing coverage. Please review.

Project coverage is 6.78%. Comparing base (4d9c7fc) to head (154910c).
Report is 481 commits behind head on develop.

Files with missing lines Patch % Lines
...oduct/gallery_view/product_image_gallery_view.dart 0.93% 106 Missing ⚠️
...oduct/gallery_view/product_image_gallery_tabs.dart 1.86% 105 Missing ⚠️
packages/smooth_app/lib/widgets/smooth_tabbar.dart 0.00% 87 Missing ⚠️
.../gallery_view/product_image_gallery_photo_row.dart 0.00% 69 Missing ⚠️
packages/smooth_app/lib/pages/image_crop_page.dart 0.00% 37 Missing ⚠️
.../lib/cards/product_cards/smooth_product_image.dart 0.00% 13 Missing ⚠️
packages/smooth_app/lib/helpers/ui_helpers.dart 0.00% 13 Missing ⚠️
...s/smooth_app/lib/helpers/border_radius_helper.dart 0.00% 8 Missing ⚠️
...app/lib/generic_lib/widgets/language_selector.dart 0.00% 4 Missing ⚠️
...pp/lib/cards/product_cards/product_title_card.dart 0.00% 1 Missing ⚠️
... and 1 more
Additional details and impacted files
@@            Coverage Diff             @@
##           develop   #5872      +/-   ##
==========================================
- Coverage     9.54%   6.78%   -2.77%     
==========================================
  Files          325     432     +107     
  Lines        16411   23843    +7432     
==========================================
+ Hits          1567    1617      +50     
- Misses       14844   22226    +7382     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

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.

  • This is a very nice usability improvement for contributors
  • I'd be tempted to have a secret gesture (Long press on the outdated image) or button to directly jump to the camera to refresh the current photo
  • We will probably have to tweak this widget to have an inline equivalent to the tab system (drop-down, little list of available languages, accordion of available languages) when we insert it into the photos tab. By then anyway, the language shown in the photos tab will be probably good for 99% of viewers.

@g123k
Copy link
Collaborator Author

g123k commented Nov 18, 2024

  • I'd be tempted to have a secret gesture (Long press on the outdated image) or button to directly jump to the camera to refresh the current photo

For this one, I first need to change the product addition flow.
Blocked by #5857

  • We will probably have to tweak this widget to have an inline equivalent to the tab system (drop-down, little list of available languages, accordion of available languages) when we insert it into the photos tab. By then anyway, the language shown in the photos tab will be probably good for 99% of viewers.

An alternative would be to show a different layout on the product page, with only the "best pictures".
However, if photos are missing, a message will be displayed.
The idea would be to keep the advanced view in editing and a simplified view on the product page.

@g123k
Copy link
Collaborator Author

g123k commented Nov 18, 2024

@teolemon I have a doubt about my implementation.
It will always open the default language (the current issue with missing photos will disappear).

Is it what we want? Or should I open the tab containing the user language?

@teolemon
Copy link
Member

If and only if it has photos already. Otherwise, it's just a tap away to add photos.
Let's avoid wrong incentives.

@g123k
Copy link
Collaborator Author

g123k commented Nov 18, 2024

Ok, so I let this PR as is

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
✏️ Editing Many products are incomplete and don't have Nutri-Score, Eco-Score…so editing is important for users 🖼️ Photos - Cropping 🥫 Product page
Development

Successfully merging this pull request may close these issues.

3 participants