diff --git a/ElementX/Sources/AppHooks/AppHooks.swift b/ElementX/Sources/AppHooks/AppHooks.swift index 1e33ae477..027dfbf2e 100644 --- a/ElementX/Sources/AppHooks/AppHooks.swift +++ b/ElementX/Sources/AppHooks/AppHooks.swift @@ -43,7 +43,7 @@ final nonisolated class AppHooks: AppHooksProtocol { @AppHook(default: DefaultUserProfileScreenHook()) var userProfileScreenHook: UserProfileScreenHookProtocol - + @AppHook(default: DefaultExtendedProfileSectionHook()) var extendedProfileSectionHook: ExtendedProfileSectionHookProtocol @@ -52,7 +52,7 @@ final nonisolated class AppHooks: AppHooksProtocol { @AppHook(default: DefaultUserDetailsEditScreenHook()) var userDetailsEditScreenHook: UserDetailsEditScreenHookProtocol - + @AppHook(default: DefaultDeveloperOptionsScreenHook()) var developerOptionsScreenHook: DeveloperOptionsScreenHookProtocol diff --git a/ElementX/Sources/AppHooks/HealthChat/HealthChatAppSettingsHook.swift b/ElementX/Sources/AppHooks/HealthChat/HealthChatAppSettingsHook.swift index 161ef8d97..81ef70f2d 100644 --- a/ElementX/Sources/AppHooks/HealthChat/HealthChatAppSettingsHook.swift +++ b/ElementX/Sources/AppHooks/HealthChat/HealthChatAppSettingsHook.swift @@ -20,6 +20,8 @@ struct HealthChatAppSettingsHook: AppSettingsHookProtocol { hideBrandChrome: false, pushGatewayBaseURL: "https://sygnal.healthchat.ch", oAuthRedirectURL: "ch.healthchat.element:/oauth/callback", + // nil keeps the registered client_uri at the bare website URL, as shipped before upstream's `apps/ios` default. + oAuthClientURIPath: nil, websiteURL: "https://healthchat.ch", logoURL: "https://app.healthchat.ch/themes/element/img/logos/element-logo.png", copyrightURL: appSettings.copyrightURL, diff --git a/ElementX/Sources/AppHooks/Hooks/ExtendedProfileSectionHook.swift b/ElementX/Sources/AppHooks/Hooks/ExtendedProfileSectionHook.swift index 0de1acb81..3d0936627 100644 --- a/ElementX/Sources/AppHooks/Hooks/ExtendedProfileSectionHook.swift +++ b/ElementX/Sources/AppHooks/Hooks/ExtendedProfileSectionHook.swift @@ -9,7 +9,7 @@ import SwiftUI nonisolated protocol ExtendedProfileSectionHookProtocol: Sendable { @MainActor func configure(with userSession: UserSessionProtocol?) async - + /// An extra Form section rendered below the header on the user profile /// and room member details screens. @MainActor func extendedProfileSection(userID: String) -> AnyView? @@ -17,7 +17,7 @@ nonisolated protocol ExtendedProfileSectionHookProtocol: Sendable { struct DefaultExtendedProfileSectionHook: ExtendedProfileSectionHookProtocol { func configure(with userSession: UserSessionProtocol?) async { } - + func extendedProfileSection(userID: String) -> AnyView? { nil } diff --git a/ElementX/Sources/AppHooks/Hooks/UserDetailsEditScreenHook.swift b/ElementX/Sources/AppHooks/Hooks/UserDetailsEditScreenHook.swift index 4910d3222..f0fd53025 100644 --- a/ElementX/Sources/AppHooks/Hooks/UserDetailsEditScreenHook.swift +++ b/ElementX/Sources/AppHooks/Hooks/UserDetailsEditScreenHook.swift @@ -9,7 +9,7 @@ import Combine import SwiftUI @MainActor protocol UserDetailsEditCoordinatorProtocol: CoordinatorProtocol { - var actions: AnyPublisher { get } + var actions: AnyPublisher { get } } nonisolated protocol UserDetailsEditScreenHookProtocol: Sendable { diff --git a/ElementX/Sources/FlowCoordinators/HealthChatMembersFlowCoordinator.swift b/ElementX/Sources/FlowCoordinators/HealthChatMembersFlowCoordinator.swift index 32917a5bb..14095c0c5 100644 --- a/ElementX/Sources/FlowCoordinators/HealthChatMembersFlowCoordinator.swift +++ b/ElementX/Sources/FlowCoordinators/HealthChatMembersFlowCoordinator.swift @@ -121,10 +121,9 @@ final class HealthChatMembersFlowCoordinator { let parameters = UserProfileScreenCoordinatorParameters(userID: userID, isPresentedModally: false, userSession: flowParameters.userSession, - userIndicatorController: flowParameters.userIndicatorController, + appHooks: flowParameters.appHooks, analytics: flowParameters.analytics, - appSettings: flowParameters.appSettings, - appHooks: flowParameters.appHooks) + userIndicatorController: flowParameters.userIndicatorController) let coordinator = UserProfileScreenCoordinator(parameters: parameters) coordinator.actionsPublisher.sink { [weak self] action in @@ -151,8 +150,7 @@ final class HealthChatMembersFlowCoordinator { userSession: flowParameters.userSession, mediaUploadingPreprocessor: MediaUploadingPreprocessor(appSettings: flowParameters.appSettings), navigationStackCoordinator: navigationStackCoordinator, - userIndicatorController: flowParameters.userIndicatorController, - appSettings: flowParameters.appSettings) + userIndicatorController: flowParameters.userIndicatorController) let coordinator = flowParameters.appHooks.userDetailsEditScreenHook.makeCoordinator(parameters: parameters) coordinator.actions.sink { [weak self] action in diff --git a/ElementX/Sources/Screens/HealthChatProfileEditScreen/HealthChatProfileEditScreenCoordinator.swift b/ElementX/Sources/Screens/HealthChatProfileEditScreen/HealthChatProfileEditScreenCoordinator.swift index cc1e54264..cbc449baa 100644 --- a/ElementX/Sources/Screens/HealthChatProfileEditScreen/HealthChatProfileEditScreenCoordinator.swift +++ b/ElementX/Sources/Screens/HealthChatProfileEditScreen/HealthChatProfileEditScreenCoordinator.swift @@ -22,8 +22,8 @@ final class HealthChatProfileEditScreenCoordinator: CoordinatorProtocol, UserDet private let viewModel: HealthChatProfileEditScreenViewModelProtocol private var cancellables = Set() - private let actionsSubject: PassthroughSubject = .init() - var actions: AnyPublisher { + private let actionsSubject: PassthroughSubject = .init() + var actions: AnyPublisher { actionsSubject.eraseToAnyPublisher() }