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

[Modal Layout Picker] Retry view #13159

Merged
merged 45 commits into from
Oct 26, 2020
Merged

[Modal Layout Picker] Retry view #13159

merged 45 commits into from
Oct 26, 2020

Conversation

antonis
Copy link
Contributor

@antonis antonis commented Oct 16, 2020

Fixes: wordpress-mobile/gutenberg-mobile#2740

Description

Adds a retry view to handle the case where the loading of layouts fails and there are no cached data

To test:

Layout Picker should show when creating a new page from My Site or Site Pages the Modal Layout Picker appears.

  1. Fresh install the app or clear storage (Device Settings>Apps>WordPress Beta>Storage & cache>Clear storage)
  2. Login
  3. Disable the internet connection (e.g. flight mode)
  4. Open the Modal Layout Picker
  5. Verify that you see the error/retry screen (check screenshot below)
  6. Press the Retry button
  7. Verify that nothing happens
  8. Enable the internet connection
  9. Press the Retry button
  10. Verify that the layouts did load

Screenshot

PR submission checklist:

  • I have considered adding unit tests where possible.
  • I have considered adding accessibility improvements for my changes.
  • I have considered if this change warrants user-facing release notes and have added them to RELEASE-NOTES.txt if necessary.

Antonis Lilis added 30 commits October 7, 2020 19:49
# Conflicts:
#	WordPress/src/main/java/org/wordpress/android/ui/main/WPMainActivity.java
#	WordPress/src/main/java/org/wordpress/android/ui/pages/PagesFragment.kt
#	WordPress/src/main/java/org/wordpress/android/viewmodel/mlp/ModalLayoutPickerViewModel.kt
#	build.gradle
# Conflicts:
#	WordPress/src/test/java/org/wordpress/android/viewmodel/mlp/ModalLayoutPickerViewModelTest.kt
# Conflicts:
#	WordPress/src/main/java/org/wordpress/android/ui/mlp/ModalLayoutPickerFragment.kt
#	WordPress/src/main/java/org/wordpress/android/viewmodel/mlp/ModalLayoutPickerViewModel.kt
#	build.gradle
# Conflicts:
#	WordPress/src/main/java/org/wordpress/android/viewmodel/mlp/ModalLayoutPickerViewModel.kt
@peril-wordpress-mobile
Copy link

peril-wordpress-mobile bot commented Oct 16, 2020

You can trigger optional UI/connected tests for these changes by visiting CircleCI here.

@antonis antonis self-assigned this Oct 16, 2020
@peril-wordpress-mobile
Copy link

peril-wordpress-mobile bot commented Oct 16, 2020

You can test the changes on this Pull Request by downloading the APK here.

@antonis antonis added this to the 16.1 milestone Oct 16, 2020
Base automatically changed from issue/2456-Cache to develop October 16, 2020 14:58
@antonis antonis added the [Status] Needs Design Review A designer needs to sign off on the implemented design. label Oct 16, 2020
@antonis antonis marked this pull request as ready for review October 19, 2020 07:28
@antonis antonis requested a review from malinajirka October 19, 2020 07:37
@malinajirka malinajirka self-assigned this Oct 20, 2020
Copy link
Contributor

@malinajirka malinajirka left a comment

Choose a reason for hiding this comment

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

Thanks @antonis!

I've left two minor comments. I also encountered an issue on a small device. The "retry" button doesn't fit the screen and the layout is not scrollable.

@antonis
Copy link
Contributor Author

antonis commented Oct 20, 2020

Hey @malinajirka 👋
Thank you once again for the prompt feedback 🙇

I implemented your suggestions along the design feedback with 3239d4a

The "retry" button doesn't fit the screen and the layout is not scrollable.

The new design moves the retry button to the bottom toolbar where it should be accessible in smaller devices. It also removes the large headers in error state making it more suitable for small devices.

Copy link
Contributor

@malinajirka malinajirka left a comment

Choose a reason for hiding this comment

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

LGTM, thanks

@malinajirka malinajirka merged commit 0a82bc8 into develop Oct 26, 2020
@malinajirka malinajirka deleted the issue/MLP_RetryView branch October 26, 2020 08:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Status] Needs Design Review A designer needs to sign off on the implemented design. [Type] Enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants