Fix new offenses

This commit is contained in:
Arkadiusz Fal
2021-11-08 17:29:35 +01:00
parent 2701c1ccb5
commit db9f7e5f5d
29 changed files with 305 additions and 305 deletions

View File

@@ -29,12 +29,12 @@ struct AccountForm: View {
.frame(maxWidth: 1000)
}
#if os(iOS)
.padding(.vertical)
.padding(.vertical)
#elseif os(tvOS)
.frame(minWidth: 0, maxWidth: .infinity, minHeight: 0, maxHeight: .infinity)
.background(.thickMaterial)
.frame(minWidth: 0, maxWidth: .infinity, minHeight: 0, maxHeight: .infinity)
.background(.thickMaterial)
#else
.frame(width: 400, height: 145)
.frame(width: 400, height: 145)
#endif
}
@@ -49,7 +49,7 @@ struct AccountForm: View {
dismiss()
}
#if !os(tvOS)
.keyboardShortcut(.cancelAction)
.keyboardShortcut(.cancelAction)
#endif
}
.padding(.horizontal)
@@ -61,7 +61,7 @@ struct AccountForm: View {
Form {
formFields
#if os(macOS)
.padding(.horizontal)
.padding(.horizontal)
#endif
}
#else
@@ -97,7 +97,7 @@ struct AccountForm: View {
#if os(tvOS)
.padding(.top, 30)
#endif
.padding(.horizontal)
.padding(.horizontal)
}
private func initializeForm() {

View File

@@ -46,7 +46,7 @@ struct AccountsSettings: View {
}
}
#if os(tvOS)
.frame(maxWidth: 1000)
.frame(maxWidth: 1000)
#endif
.navigationTitle(instance.description)
@@ -78,7 +78,7 @@ struct AccountsSettings: View {
AccountForm(instance: instance)
}
#if !os(tvOS)
.listStyle(.insetGrouped)
.listStyle(.insetGrouped)
#endif
}

View File

@@ -52,7 +52,7 @@ struct InstanceForm: View {
dismiss()
}
#if !os(tvOS)
.keyboardShortcut(.cancelAction)
.keyboardShortcut(.cancelAction)
#endif
}
.padding(.horizontal)
@@ -63,7 +63,7 @@ struct InstanceForm: View {
Form {
formFields
#if os(macOS)
.padding(.horizontal)
.padding(.horizontal)
#endif
}
#else
@@ -105,7 +105,7 @@ struct InstanceForm: View {
#endif
}
#if os(tvOS)
.padding(.top, 30)
.padding(.top, 30)
#endif
.padding(.horizontal)
}

View File

@@ -22,21 +22,21 @@ struct InstancesSettings: View {
}
}
#if os(iOS)
.swipeActions(edge: .trailing, allowsFullSwipe: false) {
removeInstanceButton(instance)
}
.buttonStyle(.plain)
.swipeActions(edge: .trailing, allowsFullSwipe: false) {
removeInstanceButton(instance)
}
.buttonStyle(.plain)
#else
.contextMenu {
removeInstanceButton(instance)
}
.contextMenu {
removeInstanceButton(instance)
}
#endif
}
addInstanceButton
}
#if os(iOS)
.listStyle(.insetGrouped)
.listStyle(.insetGrouped)
#endif
}
.sheet(isPresented: $presentingInstanceForm) {

View File

@@ -87,7 +87,7 @@ struct ServicesSettings: View {
.contentShape(Rectangle())
}
#if !os(tvOS)
.buttonStyle(.plain)
.buttonStyle(.plain)
#endif
}
}

View File

@@ -84,7 +84,7 @@ struct SettingsView: View {
#endif
}
#if os(tvOS)
.background(.black)
.background(.black)
#endif
#endif
}