-
Notifications
You must be signed in to change notification settings - Fork 53
PM-10639: Implement conditional logic for showing the intro carousel #804
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
Conversation
let isCarouselEnabled: Bool = await services.configService.getFeatureFlag(.nativeCarouselFlow) | ||
let introCarouselShown = await services.stateService.getIntroCarouselShown() | ||
if isCarouselEnabled, !introCarouselShown { | ||
await services.stateService.setIntroCarouselShown(true) |
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.
🤔 If I'm understanding this correctly, we will also only show the carousel the first time the app is launched. So even if someone doesn't log in or create an account, they won't see it a second time. Just want to make sure this is intended behavior, as I feel the ticket is a bit ambiguous on this; and the PR summary indicates that it's only keyed to having accounts on the device, implying that it should pop up each time until a user successfully logs in or creates an account.
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.
we will also only show the carousel the first time the app is launched. So even if someone doesn't log in or create an account, they won't see it a second time
The completeAuthRedirect()
method is only called once someone has successfully logged in or created an account right before the vault is shown. So if the app is launched and you see the carousel, but you don't log in or create an account, we wouldn't get here and then you would still see it on subsequent app launches until an account is added.
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.
Makes sense, was just making sure!
No New Or Fixed Issues Found |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #804 +/- ##
=======================================
Coverage 88.21% 88.22%
=======================================
Files 581 581
Lines 29373 29390 +17
=======================================
+ Hits 25911 25928 +17
Misses 3462 3462 ☔ View full report in Codecov by Sentry. |
I made one other change here to set the carousel shown flag on app startup if there's existing accounts, to prevent existing users from seeing the carousel. The logic in |
🎟️ Tracking
PM-10639
📔 Objective
Adds the logic to determine when to show the intro carousel. If the feature is enabled, and there's no accounts on the device, the intro carousel should be shown on app launch. Once the user successfully creates an account or logs in, the carousel won't be shown on future app launches.
⏰ Reminders before review
🦮 Reviewer guidelines
:+1:
) or similar for great changes:memo:
) or ℹ️ (:information_source:
) for notes or general info:question:
) for questions:thinking:
) or 💭 (:thought_balloon:
) for more open inquiry that's not quite a confirmed issue and could potentially benefit from discussion:art:
) for suggestions / improvements:x:
) or:warning:
) for more significant problems or concerns needing attention:seedling:
) or ♻️ (:recycle:
) for future improvements or indications of technical debt:pick:
) for minor or nitpick changes