mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-04 19:11:45 +00:00
Fix various small warnings
This commit is contained in:
committed by
Stefan Ceriu
parent
2a33ee1f63
commit
b5be6639d1
@@ -615,8 +615,6 @@ class AppCoordinator: AppCoordinatorProtocol, AuthenticationCoordinatorDelegate,
|
|||||||
switch callback {
|
switch callback {
|
||||||
case .didReceiveAuthError(let isSoftLogout):
|
case .didReceiveAuthError(let isSoftLogout):
|
||||||
stateMachine.processEvent(.signOut(isSoft: isSoftLogout, disableAppLock: false))
|
stateMachine.processEvent(.signOut(isSoft: isSoftLogout, disableAppLock: false))
|
||||||
default:
|
|
||||||
break
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -157,12 +157,13 @@ struct FormattedBodyText: View {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private var blockquoteAttributes: AttributeContainer {
|
private var blockquoteAttributes: AttributeContainer {
|
||||||
var container = AttributeContainer()
|
// The paragraph style removes the block style paragraph that the parser adds by default
|
||||||
|
// Set directly in the constructor to avoid `Conformance to 'Sendable'` warnings
|
||||||
|
var container = AttributeContainer([.paragraphStyle: NSParagraphStyle.default])
|
||||||
// Sadly setting SwiftUI fonts do not work so we would need UIFont equivalents for compound, this one is bodyMD
|
// Sadly setting SwiftUI fonts do not work so we would need UIFont equivalents for compound, this one is bodyMD
|
||||||
container.font = UIFont.preferredFont(forTextStyle: .subheadline)
|
container.font = UIFont.preferredFont(forTextStyle: .subheadline)
|
||||||
container.foregroundColor = UIColor.compound.textSecondary
|
container.foregroundColor = UIColor.compound.textSecondary
|
||||||
// To remove the block style paragraph that the parser adds by default
|
|
||||||
container.paragraphStyle = .default
|
|
||||||
return container
|
return container
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -54,7 +54,7 @@ struct RoomTimelineItemFactory: RoomTimelineItemFactoryProtocol {
|
|||||||
return buildUnsupportedTimelineItem(eventItemProxy, eventType, error, isOutgoing)
|
return buildUnsupportedTimelineItem(eventItemProxy, eventType, error, isOutgoing)
|
||||||
case .message:
|
case .message:
|
||||||
return buildMessageTimelineItem(eventItemProxy, isOutgoing)
|
return buildMessageTimelineItem(eventItemProxy, isOutgoing)
|
||||||
case .state(let stateKey, let content):
|
case .state(_, let content):
|
||||||
return buildStateTimelineItem(for: eventItemProxy, state: content, isOutgoing: isOutgoing)
|
return buildStateTimelineItem(for: eventItemProxy, state: content, isOutgoing: isOutgoing)
|
||||||
case .roomMembership(userId: let userID, change: let change):
|
case .roomMembership(userId: let userID, change: let change):
|
||||||
return buildStateMembershipChangeTimelineItem(for: eventItemProxy, member: userID, membershipChange: change, isOutgoing: isOutgoing)
|
return buildStateMembershipChangeTimelineItem(for: eventItemProxy, member: userID, membershipChange: change, isOutgoing: isOutgoing)
|
||||||
|
|||||||
Reference in New Issue
Block a user