This code worked in Xcode 12.0 B1 but no longer works in B2.
struct ContentView: View {
var body: some View {
NavigationView {
List {
ForEach (1..<10) {
row in
Text("\(row) - Test").foregroundColor(Color.white).fontWeight(.bold)
}
.listRowBackground(Color.burgundy)
}
.navigationTitle(Text("List Background Color Test"))
.navigationBarTitleDisplayMode(.inline)
.toolbar {
ToolbarItem(placement: .bottomBar) {
HStack {
Button(action: {}, label: {
Text("One").foregroundColor(Color.white)
})
Spacer()
Button(action: {}, label: {
Text("Two").foregroundColor(Color.white)
})
Spacer()
Button(action: {}, label: {
Text("Three").foregroundColor(Color.white)
}).foregroundColor(.blue)
}
}
}
}
}
}
struct ContentView: View {
var body: some View {
NavigationView {
List {
ForEach (1..<10) {
row in
Text("\(row) - Test").foregroundColor(Color.white).fontWeight(.bold)
}
.listRowBackground(Color.burgundy)
}
.navigationTitle(Text("List Background Color Test"))
.navigationBarTitleDisplayMode(.inline)
.toolbar {
ToolbarItem(placement: .bottomBar) {
HStack {
Button(action: {}, label: {
Text("One").foregroundColor(Color.white)
})
Spacer()
Button(action: {}, label: {
Text("Two").foregroundColor(Color.white)
})
Spacer()
Button(action: {}, label: {
Text("Three").foregroundColor(Color.white)
}).foregroundColor(.blue)
}
}
}
}
}
}