diff --git a/Services/Sources/Services/Location/LocationService.swift b/Services/Sources/Services/Location/LocationService.swift index 2fc78c40..2a18b55f 100644 --- a/Services/Sources/Services/Location/LocationService.swift +++ b/Services/Sources/Services/Location/LocationService.swift @@ -80,8 +80,10 @@ extension LocationService: ApplicationDelegateService { _ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [AnyHashable: Any]? ) -> Bool { - locationManager.requestAuthorization(mode: .onlyInUse) {[weak self] status in - self?.logger.info("[LocationService] Current authorization status: \(status)") + DispatchQueue.global(qos: .userInitiated).async { [weak self] in + self?.locationManager.requestAuthorization(mode: .onlyInUse) {[weak self] status in + self?.logger.info("[LocationService] Current authorization status: \(status)") + } } return true } diff --git a/UIComponents/Sources/UIComponents/Components/Custom/Onboarding/OnboardingView.swift b/UIComponents/Sources/UIComponents/Components/Custom/Onboarding/OnboardingView.swift index b980745a..cce4ef28 100644 --- a/UIComponents/Sources/UIComponents/Components/Custom/Onboarding/OnboardingView.swift +++ b/UIComponents/Sources/UIComponents/Components/Custom/Onboarding/OnboardingView.swift @@ -79,6 +79,7 @@ public final class OnboardingView: UIView { numberOfSteps: model.steps.count ) ) + stepperView.isHidden = true } // MARK: - Setup diff --git a/animeal.xcodeproj/project.pbxproj b/animeal.xcodeproj/project.pbxproj index 782db9c5..5d6d4993 100644 --- a/animeal.xcodeproj/project.pbxproj +++ b/animeal.xcodeproj/project.pbxproj @@ -3084,7 +3084,7 @@ ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; CODE_SIGN_IDENTITY = "Apple Development: Pran Kishore (CM95PV92ZY)"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 20240505; + CURRENT_PROJECT_VERSION = 20240704; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEVELOPMENT_TEAM = 2JSLPH439W; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = 2JSLPH439W; @@ -3127,7 +3127,7 @@ CODE_SIGN_IDENTITY = "Apple Distribution: Animals Project, NCLE (2JSLPH439W)"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "Apple Distribution: Animals Project, NCLE (2JSLPH439W)"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 20240505; + CURRENT_PROJECT_VERSION = 20240704; DEVELOPMENT_TEAM = 2JSLPH439W; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = 2JSLPH439W; GENERATE_INFOPLIST_FILE = YES; diff --git a/animeal/AppDelegate.swift b/animeal/AppDelegate.swift index 56e6a27f..20904dfa 100644 --- a/animeal/AppDelegate.swift +++ b/animeal/AppDelegate.swift @@ -95,7 +95,7 @@ private extension AppDelegate { try Amplify.add(plugin: AWSAPIPlugin(sessionFactory: AppDelegate.makeDefault())) try Amplify.configure() try Amplify.API.add(interceptor: UrlQueryPlusFixInterceptor(), for: "AdminQueries") - Amplify.Logging.logLevel = .verbose + Amplify.Logging.logLevel = .error logInfo("[APP] Amplify configured") } catch { logError("[APP] Failed to initialize Amplify with \(error)") diff --git a/animeal/src/Flows/Auth/Modules/CustomAuth/CustomAuthViewController.swift b/animeal/src/Flows/Auth/Modules/CustomAuth/CustomAuthViewController.swift index 65ccdf63..2ce02314 100644 --- a/animeal/src/Flows/Auth/Modules/CustomAuth/CustomAuthViewController.swift +++ b/animeal/src/Flows/Auth/Modules/CustomAuth/CustomAuthViewController.swift @@ -132,12 +132,14 @@ private extension CustomAuthViewController { case .phone: let inputView = PhoneInputView() inputView.configure(item.phoneModel) + #if DEBUG inputView.codeWasTapped = { [weak self] _ in self?.view.endEditing(true) self?.viewModel.handleActionEvent( CustomAuthViewActionEvent.itemWasTapped(item.identifier) ) } + #endif inputView.didBeginEditing = { [weak self] textInput in guard let self = self else { return } let text = textInput.text diff --git a/animeal/src/Flows/Auth/Modules/Login/LoginViewController.swift b/animeal/src/Flows/Auth/Modules/Login/LoginViewController.swift index d54fe491..3b277cb2 100644 --- a/animeal/src/Flows/Auth/Modules/Login/LoginViewController.swift +++ b/animeal/src/Flows/Auth/Modules/Login/LoginViewController.swift @@ -10,6 +10,7 @@ import UIKit // SDK import UIComponents +import Services final class LoginViewController: UIViewController, LoginViewable { // MARK: - UI properties @@ -53,6 +54,16 @@ final class LoginViewController: UIViewController, LoginViewable { viewModel.load() } + override func viewDidAppear(_ animated: Bool) { + super.viewDidAppear(animated) + AppDelegate.shared.context.analyticsService.logEvent( + ScreenViewEvent( + screenName: AnalyticsScreen.screenForViewController(self).description, + trackablePolicy: .multipleTracking, + targets: [AnalyticsTargetType.firebase] + ) + ) + } // MARK: - State func applyOnboarding(_ onboardingSteps: [LoginViewOnboardingStep]) { onboardingView.configure( @@ -79,6 +90,7 @@ final class LoginViewController: UIViewController, LoginViewable { ).isActive = true onboardingView.leadingAnchor.constraint(equalTo: view.leadingAnchor).isActive = true onboardingView.trailingAnchor.constraint(equalTo: view.trailingAnchor).isActive = true + onboardingView.isUserInteractionEnabled = false view.addSubview(buttonsView) buttonsView.topAnchor.constraint(equalTo: onboardingView.bottomAnchor).isActive = true diff --git a/animeal/src/Flows/Auth/Modules/Verification/VerificationViewController.swift b/animeal/src/Flows/Auth/Modules/Verification/VerificationViewController.swift index 3afcbfc7..8730cde9 100644 --- a/animeal/src/Flows/Auth/Modules/Verification/VerificationViewController.swift +++ b/animeal/src/Flows/Auth/Modules/Verification/VerificationViewController.swift @@ -3,6 +3,7 @@ import UIKit // SDK import UIComponents +import Services final class VerificationViewController: BaseViewController, VerificationViewModelOutput { // MARK: - UI properties @@ -30,6 +31,17 @@ final class VerificationViewController: BaseViewController, VerificationViewMode bind() viewModel.load() } + + override func viewDidAppear(_ animated: Bool) { + super.viewDidAppear(animated) + AppDelegate.shared.context.analyticsService.logEvent( + ScreenViewEvent( + screenName: AnalyticsScreen.screenForViewController(self).description, + trackablePolicy: .multipleTracking, + targets: [AnalyticsTargetType.firebase] + ) + ) + } override func handleKeyboardNotification(keyboardData: KeyboardData) { super.handleKeyboardNotification(keyboardData: keyboardData) diff --git a/animeal/src/Flows/Main/Modules/Home/Main/View/HomeViewController.swift b/animeal/src/Flows/Main/Modules/Home/Main/View/HomeViewController.swift index 434a7cb7..c382cb8e 100644 --- a/animeal/src/Flows/Main/Modules/Home/Main/View/HomeViewController.swift +++ b/animeal/src/Flows/Main/Modules/Home/Main/View/HomeViewController.swift @@ -3,6 +3,7 @@ import AVFoundation import Style import UIComponents import Common +import Services @_spi(Experimental) import MapboxMaps class HomeViewController: UIViewController { @@ -69,6 +70,17 @@ class HomeViewController: UIViewController { viewModel.updateSelectionIfNeeded(for: itemIdentifier) } } + + override func viewDidAppear(_ animated: Bool) { + super.viewDidAppear(animated) + AppDelegate.shared.context.analyticsService.logEvent( + ScreenViewEvent( + screenName: AnalyticsScreen.screenForViewController(self).description, + trackablePolicy: .multipleTracking, + targets: [AnalyticsTargetType.firebase] + ) + ) + } } extension HomeViewController: HomeViewModelOutput { diff --git a/animeal/src/Flows/Profile/ProfileViewController.swift b/animeal/src/Flows/Profile/ProfileViewController.swift index 01074977..eb567553 100644 --- a/animeal/src/Flows/Profile/ProfileViewController.swift +++ b/animeal/src/Flows/Profile/ProfileViewController.swift @@ -161,11 +161,13 @@ private extension ProfileViewController { guard let model = (item as? ProfileTextFieldViewItem)?.phoneModel else { return } let inputView = PhoneInputView() inputView.configure(model) + #if DEBUG inputView.codeWasTapped = { [weak self] _ in self?.viewModel.handleActionEvent( ProfileViewActionEvent.itemWasTapped(item.identifier) ) } + #endif inputView.didBeginEditing = { [weak self] textInput in guard let self = self else { return } let text = textInput.text