Set full screen views background color based on color scheme on tvOS (fixes #30)

This commit is contained in:
Arkadiusz Fal
2021-12-05 18:09:25 +01:00
parent 5143c4f8ce
commit 941e6a909d
10 changed files with 31 additions and 13 deletions

View File

@@ -15,6 +15,7 @@ struct AccountForm: View {
@State private var validationError: String?
@State private var validationDebounce = Debounce()
@Environment(\.colorScheme) private var colorScheme
@Environment(\.presentationMode) private var presentationMode
var body: some View {
@@ -30,7 +31,7 @@ struct AccountForm: View {
.padding(.vertical)
#elseif os(tvOS)
.frame(minWidth: 0, maxWidth: .infinity, minHeight: 0, maxHeight: .infinity)
.background(Color.tertiaryBackground)
.background(Color.background(scheme: colorScheme))
#else
.frame(width: 400, height: 145)
#endif