mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 03:06:37 +00:00
Run SwiftFormat.
This commit is contained in:
+4
-4
@@ -35,11 +35,11 @@ struct DeveloperOptionsScreenViewState: BindableState {
|
||||
@dynamicMemberLookup
|
||||
struct DeveloperOptionsScreenViewStateBindings {
|
||||
private let developerOptions: DeveloperOptionsProtocol
|
||||
|
||||
|
||||
init(developerOptions: DeveloperOptionsProtocol) {
|
||||
self.developerOptions = developerOptions
|
||||
}
|
||||
|
||||
|
||||
subscript<Setting>(dynamicMember keyPath: ReferenceWritableKeyPath<DeveloperOptionsProtocol, Setting>) -> Setting {
|
||||
get { developerOptions[keyPath: keyPath] }
|
||||
set { developerOptions[keyPath: keyPath] = newValue }
|
||||
@@ -68,11 +68,11 @@ protocol DeveloperOptionsProtocol: AnyObject {
|
||||
var knockingEnabled: Bool { get set }
|
||||
|
||||
var linkPreviewsEnabled: Bool { get set }
|
||||
|
||||
|
||||
var jumpToReadMarkerEnabled: Bool { get set }
|
||||
|
||||
var linkNewDeviceEnabled: Bool { get set }
|
||||
|
||||
|
||||
var roomThreadListEnabled: Bool { get set }
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -48,7 +48,7 @@ class DeveloperOptionsScreenViewModel: DeveloperOptionsScreenViewModelType, Deve
|
||||
if let logsSize = try? FileManager.default.sizeForDirectory(at: .appGroupLogsDirectory) {
|
||||
components.append(.init(name: "Log Files", size: formatter.format(Int64(logsSize))))
|
||||
}
|
||||
|
||||
|
||||
state.storeSizes = components
|
||||
}
|
||||
}
|
||||
|
||||
+5
-5
@@ -87,12 +87,12 @@ struct DeveloperOptionsScreen: View {
|
||||
Text("Can leak the device IP address when loading link metadata.")
|
||||
.foregroundStyle(.compound.textCriticalPrimary)
|
||||
}
|
||||
|
||||
|
||||
Toggle(isOn: $context.jumpToReadMarkerEnabled) {
|
||||
Text("Jump to unread")
|
||||
Text("Adds a button to jump to the read marker, plus a presence dot on the scroll-to-bottom button when new messages arrive while scrolled away.")
|
||||
}
|
||||
|
||||
|
||||
Toggle(isOn: $context.knockingEnabled) {
|
||||
Text("Knocking")
|
||||
Text("Ask to join rooms")
|
||||
@@ -109,7 +109,7 @@ struct DeveloperOptionsScreen: View {
|
||||
} footer: {
|
||||
Text("This setting controls how end-to-end encryption (E2EE) keys are exchanged. Enabling it will prevent the inclusion of devices that have not been explicitly verified by their owners.")
|
||||
}
|
||||
|
||||
|
||||
Section("Element Call remote URL override") {
|
||||
TextField("Leave empty to use EC locally", text: $elementCallURLOverrideString)
|
||||
.autocorrectionDisabled(true)
|
||||
@@ -182,7 +182,7 @@ struct DeveloperOptionsScreen: View {
|
||||
.navigationBarTitleDisplayMode(.inline)
|
||||
.toolbar { toolbar }
|
||||
}
|
||||
|
||||
|
||||
@ViewBuilder
|
||||
private var effectsView: some View {
|
||||
if showConfetti {
|
||||
@@ -192,7 +192,7 @@ struct DeveloperOptionsScreen: View {
|
||||
.task { await removeConfettiAfterDelay() }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private func removeConfettiAfterDelay() async {
|
||||
try? await Task.sleep(for: .seconds(4))
|
||||
showConfetti = false
|
||||
|
||||
Reference in New Issue
Block a user