mirror of
https://github.com/bitwarden/ios.git
synced 2025-12-11 13:54:06 -06:00
34 lines
1.1 KiB
Swift
34 lines
1.1 KiB
Swift
import BitwardenKit
|
|
|
|
// MARK: - FileSelectionModule
|
|
|
|
/// An object that builds coordinators for the file selection flow.
|
|
///
|
|
@MainActor
|
|
protocol FileSelectionModule {
|
|
/// Initializes a coordinator for navigating between `FileSelectionRoutes`s.
|
|
///
|
|
/// - Parameters
|
|
/// - delegate: The delegate for this coordinator.
|
|
/// - stackNavigator: The stack navigator that will be used to navigate between routes.
|
|
/// - Returns: A coordinator that can navigate to `FileSelectionRoutes`s.
|
|
///
|
|
func makeFileSelectionCoordinator(
|
|
delegate: FileSelectionDelegate,
|
|
stackNavigator: StackNavigator,
|
|
) -> AnyCoordinator<FileSelectionRoute, FileSelectionEvent>
|
|
}
|
|
|
|
extension DefaultAppModule: FileSelectionModule {
|
|
func makeFileSelectionCoordinator(
|
|
delegate: FileSelectionDelegate,
|
|
stackNavigator: StackNavigator,
|
|
) -> AnyCoordinator<FileSelectionRoute, FileSelectionEvent> {
|
|
FileSelectionCoordinator(
|
|
delegate: delegate,
|
|
services: services,
|
|
stackNavigator: stackNavigator,
|
|
).asAnyCoordinator()
|
|
}
|
|
}
|