-
-
Notifications
You must be signed in to change notification settings - Fork 285
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: 3332 - crop page title now reflects image field #3366
feat: 3332 - crop page title now reflects image field #3366
Conversation
Impacted files: * `confirm_and_upload_picture.dart`: minor refactoring * `crop_helper.dart`: added a `pageTitle` parameter * `edit_ingredients_page.dart`: minor refactoring * `image_crop_page.dart`: added `imageField` parameters, so that we can compute the correct label on crop page * `image_upload_card.dart`: now we explicitly use `getProductImageButtonText` as label * `new_crop_page.dart`: added a page title parameter * `product_cards_helper.dart`: new label method `getImagePageTitle`; minor refactoring * `product_image_carousel.dart`: minor refactoring * `product_image_data.dart`: removed label fields - now we have more flexibility, computing labels from `imageField` with `product_cards_helper.dart` methods * `product_image_gallery_view.dart`: minor refactoring * `product_image_swipeable_view.dart`: now we explicitly use `getImagePageTitle` as label * `product_image_viewer.dart`: minor refactoring * `smooth_images_sliver_list.dart`: now we explicitly use `getProductImageTitle` as label * `smooth_product_image.dart`: minor refactoring
Codecov Report
@@ Coverage Diff @@
## develop #3366 +/- ##
========================================
Coverage 10.41% 10.41%
========================================
Files 258 258
Lines 12494 12492 -2
========================================
Hits 1301 1301
+ Misses 11193 11191 -2
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
@omkarChend1kar ping |
Hii @monsieurtanuki ,I didn't get you. |
I think it's time you review this PR!! |
@@ -65,11 +65,7 @@ class _ProductImageSwipeableViewState extends State<ProductImageSwipeableView> { | |||
context.watch<LocalDatabase>(); | |||
_product = _localDatabase.upToDate.getLocalUpToDate(_initialProduct); | |||
final List<ProductImageData> allProductImagesData = | |||
getProductMainImagesData( | |||
_product, | |||
appLocalizations, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Everything looks good!!
Though ,If instance of AppLocalizations
is not required anymore to get the list of ProductImagesData
, Then it's declaration can be removed, Since not required anywhere else on this page.
Thank you @omkarChend1kar for your review! @M123-dev @AshAman999 May you approve too? Not that I don't trust @omkarChend1kar, but for some reason I'm not able to merge even with one approval. Not enough seniority on this project maybe... |
Yeah, Right missed it completely. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The first option looks like a good improvement. Does it degrade gracefully if translated texts are longer ?
Were translations already handled, I don't see any additional translated strings.
You mean "edit before", right? |
Impacted files: * `new_crop_page.dart`: 2 lines for the title
Thank you @omkarChend1kar @teolemon @AshAman999 for your help! |
Impacted files:
confirm_and_upload_picture.dart
: minor refactoringcrop_helper.dart
: added apageTitle
parameteredit_ingredients_page.dart
: minor refactoringimage_crop_page.dart
: addedimageField
parameters, so that we can compute the correct label on crop pageimage_upload_card.dart
: now we explicitly usegetProductImageButtonText
as labelnew_crop_page.dart
: added a page title parameterproduct_cards_helper.dart
: new label methodgetImagePageTitle
; minor refactoringproduct_image_carousel.dart
: minor refactoringproduct_image_data.dart
: removed label fields - now we have more flexibility, computing labels fromimageField
withproduct_cards_helper.dart
methodsproduct_image_gallery_view.dart
: minor refactoringproduct_image_swipeable_view.dart
: now we explicitly usegetImagePageTitle
as labelproduct_image_viewer.dart
: minor refactoringsmooth_images_sliver_list.dart
: now we explicitly usegetProductImageTitle
as labelsmooth_product_image.dart
: minor refactoringWhat
ProductImageData
that were not really usefulScreenshot
Part of