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

Implements: Campaign listing page navigation and tracking #18833

Merged
merged 11 commits into from
Jul 25, 2023

Conversation

AjeshRPai
Copy link
Contributor

@AjeshRPai AjeshRPai commented Jul 25, 2023

Part of
#18800
#18533
#18528

Description

This PR implements the following in the Campaign listing page

  1. The Floating action button
    1. Clicking will navigate to the blaze creation flow
    2. Tracking events on click
  2. Clicking on the Campaign item navigates to the campaign detail page
  3. Clicking on the Create button in no Campaigns view navigates to the campaign detail page 

  4. Adds test in CampaignListingViewModelTest

Testing instruction

Click on FAB

  1. Log in to an account having campaigns
  2. Click on the campaigns card
  3. Verify that the campaign listing page is shown
  4. Click on the + Fab button
  5. Verify that the blaze promote overlay is shown
  6. Verify tracking event 🔵 Tracked: blaze_overlay_displayed, Properties: {"source":"campaign_listing_page”}

Campaign item click

  1. Log in to an account having campaigns
  2. Click on the campaigns card
  3. Verify that the campaign listing page is shown
  4. Click on any campaign
  5. Verify that the campaign detail page is shown
  6. Verify the tracking event 🔵 Tracked: blaze_campaign_details_opened, Properties: {"source":"campaign_listing_page"}

No campaigns button click & FAB

  1. Log in to an account having no campaigns
  2. Click on menu → blaze
  3. Verify that no campaigns page is shown
  4. Verify that the FAB is not shown
  5. Click on Create button in no Campaigns view
  6. Verify that the blaze flow is triggered
  7. Verify tracking event is triggered 🔵 Tracked: blaze_overlay_displayed, Properties: {"source":"campaign_listing_page"}

Note: The FAB implemented in this Page is a Jetpack compose replica of the current XML FAB implemented in the app with the PR - #18599, This FAB color is different to the one provided in the design. The one provided in the design was given before the FAB shape and color was changed across the Android PR, so I am guessing the one I have done is right. I am cc ing @osullivanchris so that he can review this when he comes back from AFK. Once he gives a design review of the FAB, I will take up the change if necessary. Lets go with the merge so that we can progress with the rest of the implementation

Regression Notes

  1. Potential unintended areas of impact
    Nothing as this is a new screen

  2. What I did to test those areas of impact (or what existing automated tests I relied on)
    N/A

  3. What automated tests I added (or what prevented me from doing so)
    N/A

PR submission checklist:

  • I have completed the Regression Notes.
  • 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.

UI Changes testing checklist:

  • Portrait and landscape orientations.
  • Light and dark modes.
  • Fonts: Larger, smaller and bold text.
  • High contrast.
  • Talkback.
  • Languages with large words or with letters/accents not frequently used in English.
  • Right-to-left languages. (Even if translation isn’t complete, formatting should still respect the right-to-left layout)
  • Large and small screen sizes. (Tablet and smaller phones)
  • Multi-tasking: Split screen and Pop-up view. (Android 10 or higher)

+ Adds: CampaignListingNavigation to the view model
+ Adds: navigation live data
↑ Updates: the logic to add navigation events
+ Adds: create campaign click on campaign listing ui state
+ Adds: compose view for create campaign
+ Adds: logic for navigating to blaze flow on create campaign fab click
+ Adds: content description for FAB button
@wpmobilebot
Copy link
Contributor

wpmobilebot commented Jul 25, 2023

WordPress📲 You can test the changes from this Pull Request in WordPress by scanning the QR code below to install the corresponding build.
App NameWordPress WordPress
FlavorJalapeno
Build TypeDebug
Versionpr18833-3cc7d27
Commit3cc7d27
Direct Downloadwordpress-prototype-build-pr18833-3cc7d27.apk
Note: Google Login is not supported on these builds.

@wpmobilebot
Copy link
Contributor

wpmobilebot commented Jul 25, 2023

Jetpack📲 You can test the changes from this Pull Request in Jetpack by scanning the QR code below to install the corresponding build.
App NameJetpack Jetpack
FlavorJalapeno
Build TypeDebug
Versionpr18833-3cc7d27
Commit3cc7d27
Direct Downloadjetpack-prototype-build-pr18833-3cc7d27.apk
Note: Google Login is not supported on these builds.

+ Adds: missing tests for CampaignListingViewModel
@AjeshRPai AjeshRPai requested a review from zwarm July 25, 2023 13:03
@AjeshRPai AjeshRPai marked this pull request as ready for review July 25, 2023 13:33
Copy link
Contributor

@zwarm zwarm left a comment

Choose a reason for hiding this comment

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

@AjeshRPai - All is working as expected. The FAB looks like it belongs and matches.

I have one design concern fyi @osullivanchris - The tap area on the card title, which is what launches the campaigns list, is tiny. It may become larger once the more menu is added, but thought I'd mention it all the same.

@zwarm zwarm enabled auto-merge July 25, 2023 20:53
@zwarm zwarm merged commit 5ec84d1 into trunk Jul 25, 2023
@zwarm zwarm deleted the issue/implement_campaign_listing_page_clicks branch July 25, 2023 20:58
@osullivanchris
Copy link

Tapping a campaign brought me to an empty campaigns detail screen. Nothing ever loaded. Not sure if I am doing something wrong. I downloaded the APK above directly and used our shared test account. I didn't touch any feature flags.

Note: The FAB implemented in this Page is a Jetpack compose replica of the current XML FAB implemented in the app with the PR - #18599, This FAB color is different to the one provided in the design. The one provided in the design was given before the FAB shape and color was changed across the Android PR, so I am guessing the one I have done is right. I am cc ing @osullivanchris so that he can review this when he comes back from AFK. Once he gives a design review of the FAB, I will take up the change if necessary. Lets go with the merge so that we can progress with the rest of the implementation

Yep we should use the new FAB going forward everywhere. Looks and works as expected.

I have one design concern fyi @osullivanchris - The tap area on the card title, which is what launches the campaigns list, is tiny. It may become larger once the more menu is added, but thought I'd mention it all the same.

Yep seems fair. Let's assess once the more menu is in there. And the more menu should also have a link inside to all campaigns which gives us a fail safe.

@AjeshRPai
Copy link
Contributor Author

Hey @osullivanchris

Tapping a campaign brought me to an empty campaigns detail screen. Nothing ever loaded. Not sure if I am doing something wrong. I downloaded the APK above directly and used our shared test account. I didn't touch any feature flags.

At this time, the campaign detail page was not implemented hence it shows an empty page. If you want to test the updated app for campaigns feature, you can test using the build from this PR #18842 (review)

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