Should be simple. I believe this is due to the int -> enum change, and these tag() modifiers looking for ints (1, 2, 3 for the pages, which I used before). The fix should be to change the .tag() cases to that of the SelectedPage enum type.
private var topNavBar: some View {
Picker(selection: $viewModel.selected, label: Text("Picker"), content: {
Text("Feed").tag(SelectedPage.feed)
Text("Saved").tag(SelectedPage.saved)
Text("Recent").tag(SelectedPage.recent)
})
.pickerStyle(SegmentedPickerStyle())
}
Should be simple. I believe this is due to the int -> enum change, and these
tag()
modifiers looking for ints (1, 2, 3 for the pages, which I used before). The fix should be to change the.tag()
cases to that of theSelectedPage
enum type.