How can I change the background color of a list item while it is selected inside of a NavigationLink?
It is always highlighted in blue (see the attached screen). I tried to change the listRowBackgroundColor view modifier, but it didn't work.
NavigationView {
List (templateModel.model.items) { item in
NavigationLink(destination: DetailView(selectedCategory: item.name, dismiss: dismiss)
.environmentObject(OrientationInfo())) {
Text("Test")
.listRowBackground(Color.gray)
}
.background(Color.black)
.buttonStyle(PlainButtonStyle())
.listRowBackground(Color.gray)
}
.background(Color.black)
.listStyle(InsetListStyle())
}

