Prepare onboarding flow for personalisation screens.

Add a BuildSetting to control the display of the personalisation screens.
Add a property to delay the AuthenticationCoordinator from showing any screens.
Add Congratulations screen to onboarding flow.
This commit is contained in:
Doug
2022-02-24 17:24:04 +00:00
parent 7934501811
commit 9396338c19
23 changed files with 642 additions and 91 deletions
@@ -73,11 +73,6 @@
@property (nonatomic) BOOL reviewSessionAlertHasBeenDisplayed;
/**
A flag to indicate that the analytics prompt should be shown during `-addMatrixSession:`.
*/
@property(nonatomic) BOOL presentAnalyticsPromptOnAddSession;
@end
@implementation MasterTabBarController
@@ -204,20 +199,6 @@
if (!authIsShown)
{
// Check whether the user should be prompted to send analytics.
if (Analytics.shared.shouldShowAnalyticsPrompt)
{
MXSession *mxSession = self.mxSessions.firstObject;
if (mxSession)
{
[self promptUserBeforeUsingAnalyticsForSession:mxSession];
}
else
{
self.presentAnalyticsPromptOnAddSession = YES;
}
}
[self refreshTabBarBadges];
// Release properly pushed and/or presented view controller
@@ -422,12 +403,6 @@
return;
}
if (self.presentAnalyticsPromptOnAddSession)
{
self.presentAnalyticsPromptOnAddSession = NO;
[self promptUserBeforeUsingAnalyticsForSession:mxSession];
}
// Check whether the controller'€™s view is loaded into memory.
if (self.homeViewController)
{
@@ -965,18 +940,6 @@
return NSNotFound;
}
#pragma mark -
- (void)promptUserBeforeUsingAnalyticsForSession:(MXSession *)mxSession
{
// Analytics aren't collected on iOS 12 & 13.
if (@available(iOS 14.0, *))
{
MXLogDebug(@"[MasterTabBarController]: Invite the user to send analytics");
[self.masterTabBarDelegate masterTabBarController:self shouldPresentAnalyticsPromptForMatrixSession:mxSession];
}
}
#pragma mark - Review session
- (void)presentVerifyCurrentSessionAlertIfNeededWithSession:(MXSession*)session