mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-04-25 02:52:45 +02:00
Remove iOS 13/14 checks from Template/Onboarding/Authentication.
This commit is contained in:
-1
@@ -42,7 +42,6 @@ final class TemplateUserProfileCoordinator: Coordinator, Presentable {
|
||||
|
||||
// MARK: - Setup
|
||||
|
||||
@available(iOS 14.0, *)
|
||||
init(parameters: TemplateUserProfileCoordinatorParameters) {
|
||||
self.parameters = parameters
|
||||
let viewModel = TemplateUserProfileViewModel.makeTemplateUserProfileViewModel(templateUserProfileService: TemplateUserProfileService(session: parameters.session))
|
||||
|
||||
-1
@@ -19,7 +19,6 @@ import SwiftUI
|
||||
|
||||
/// Using an enum for the screen allows you define the different state cases with
|
||||
/// the relevant associated data for each case.
|
||||
@available(iOS 14.0, *)
|
||||
enum MockTemplateUserProfileScreenState: MockScreenState, CaseIterable {
|
||||
// A case for each state you want to represent
|
||||
// with specific, minimal associated data that will allow you
|
||||
|
||||
-1
@@ -17,7 +17,6 @@
|
||||
import Foundation
|
||||
import Combine
|
||||
|
||||
@available(iOS 14.0, *)
|
||||
class TemplateUserProfileService: TemplateUserProfileServiceProtocol {
|
||||
|
||||
// MARK: - Properties
|
||||
|
||||
-1
@@ -17,7 +17,6 @@
|
||||
import Foundation
|
||||
import Combine
|
||||
|
||||
@available(iOS 14.0, *)
|
||||
class MockTemplateUserProfileService: TemplateUserProfileServiceProtocol {
|
||||
var presenceSubject: CurrentValueSubject<TemplateUserProfilePresence, Never>
|
||||
|
||||
|
||||
-2
@@ -17,7 +17,6 @@
|
||||
import Foundation
|
||||
import Combine
|
||||
|
||||
@available(iOS 14.0, *)
|
||||
protocol TemplateUserProfileServiceProtocol: Avatarable {
|
||||
var userId: String { get }
|
||||
var displayName: String? { get }
|
||||
@@ -27,7 +26,6 @@ protocol TemplateUserProfileServiceProtocol: Avatarable {
|
||||
|
||||
// MARK: Avatarable
|
||||
|
||||
@available(iOS 14.0, *)
|
||||
extension TemplateUserProfileServiceProtocol {
|
||||
var mxContentUri: String? {
|
||||
avatarUrl
|
||||
|
||||
+1
-2
@@ -17,11 +17,10 @@
|
||||
import SwiftUI
|
||||
import Combine
|
||||
|
||||
@available(iOS 14, *)
|
||||
typealias TemplateUserProfileViewModelType = StateStoreViewModel<TemplateUserProfileViewState,
|
||||
Never,
|
||||
TemplateUserProfileViewAction>
|
||||
@available(iOS 14, *)
|
||||
|
||||
class TemplateUserProfileViewModel: TemplateUserProfileViewModelType, TemplateUserProfileViewModelProtocol {
|
||||
|
||||
// MARK: - Properties
|
||||
|
||||
-2
@@ -19,8 +19,6 @@ import Foundation
|
||||
protocol TemplateUserProfileViewModelProtocol {
|
||||
|
||||
var completion: ((TemplateUserProfileViewModelResult) -> Void)? { get set }
|
||||
@available(iOS 14, *)
|
||||
static func makeTemplateUserProfileViewModel(templateUserProfileService: TemplateUserProfileServiceProtocol) -> TemplateUserProfileViewModelProtocol
|
||||
@available(iOS 14, *)
|
||||
var context: TemplateUserProfileViewModelType.Context { get }
|
||||
}
|
||||
|
||||
-1
@@ -17,7 +17,6 @@
|
||||
import XCTest
|
||||
import RiotSwiftUI
|
||||
|
||||
@available(iOS 14.0, *)
|
||||
class TemplateUserProfileUITests: MockScreenTest {
|
||||
|
||||
override class var screenType: MockScreenState.Type {
|
||||
|
||||
-1
@@ -19,7 +19,6 @@ import Combine
|
||||
|
||||
@testable import RiotSwiftUI
|
||||
|
||||
@available(iOS 14.0, *)
|
||||
class TemplateUserProfileViewModelTests: XCTestCase {
|
||||
private enum Constants {
|
||||
static let presenceInitialValue: TemplateUserProfilePresence = .offline
|
||||
|
||||
@@ -16,7 +16,6 @@
|
||||
|
||||
import SwiftUI
|
||||
|
||||
@available(iOS 14.0, *)
|
||||
struct TemplateUserProfile: View {
|
||||
|
||||
// MARK: - Properties
|
||||
@@ -70,7 +69,6 @@ struct TemplateUserProfile: View {
|
||||
|
||||
// MARK: - Previews
|
||||
|
||||
@available(iOS 14.0, *)
|
||||
struct TemplateUserProfile_Previews: PreviewProvider {
|
||||
static let stateRenderer = MockTemplateUserProfileScreenState.stateRenderer
|
||||
static var previews: some View {
|
||||
|
||||
-2
@@ -16,7 +16,6 @@
|
||||
|
||||
import SwiftUI
|
||||
|
||||
@available(iOS 14.0, *)
|
||||
struct TemplateUserProfileHeader: View {
|
||||
|
||||
// MARK: - Properties
|
||||
@@ -49,7 +48,6 @@ struct TemplateUserProfileHeader: View {
|
||||
|
||||
// MARK: - Previews
|
||||
|
||||
@available(iOS 14.0, *)
|
||||
struct TemplateUserProfileHeader_Previews: PreviewProvider {
|
||||
static var previews: some View {
|
||||
TemplateUserProfileHeader(avatar: MockAvatarInput.example, displayName: "Alice", presence: .online)
|
||||
|
||||
-2
@@ -16,7 +16,6 @@
|
||||
|
||||
import SwiftUI
|
||||
|
||||
@available(iOS 14.0, *)
|
||||
struct TemplateUserProfilePresenceView: View {
|
||||
|
||||
// MARK: - Properties
|
||||
@@ -53,7 +52,6 @@ struct TemplateUserProfilePresenceView: View {
|
||||
|
||||
// MARK: - Previews
|
||||
|
||||
@available(iOS 14.0, *)
|
||||
struct TemplateUserProfilePresenceView_Previews: PreviewProvider {
|
||||
static var previews: some View {
|
||||
VStack(alignment:.leading){
|
||||
|
||||
Reference in New Issue
Block a user