mirror of
https://github.com/Dimillian/IceCubesApp.git
synced 2024-11-29 11:41:01 +00:00
Prevent a tab item from being set twice (#2166)
This commit is contained in:
parent
199749b809
commit
1b7720c9c4
1 changed files with 15 additions and 5 deletions
|
@ -15,30 +15,40 @@ struct TabbarEntriesSettingsView: View {
|
|||
Section {
|
||||
Picker("settings.tabs.first-tab", selection: $tabs.firstTab) {
|
||||
ForEach(Tab.allCases) { tab in
|
||||
if tab == tabs.firstTab || !tabs.tabs.contains(tab) {
|
||||
tab.label.tag(tab)
|
||||
}
|
||||
}
|
||||
}
|
||||
Picker("settings.tabs.second-tab", selection: $tabs.secondTab) {
|
||||
ForEach(Tab.allCases) { tab in
|
||||
if tab == tabs.secondTab || !tabs.tabs.contains(tab) {
|
||||
tab.label.tag(tab)
|
||||
}
|
||||
}
|
||||
}
|
||||
Picker("settings.tabs.third-tab", selection: $tabs.thirdTab) {
|
||||
ForEach(Tab.allCases) { tab in
|
||||
if tab == tabs.thirdTab || !tabs.tabs.contains(tab) {
|
||||
tab.label.tag(tab)
|
||||
}
|
||||
}
|
||||
}
|
||||
Picker("settings.tabs.fourth-tab", selection: $tabs.fourthTab) {
|
||||
ForEach(Tab.allCases) { tab in
|
||||
if tab == tabs.fourthTab || !tabs.tabs.contains(tab) {
|
||||
tab.label.tag(tab)
|
||||
}
|
||||
}
|
||||
}
|
||||
Picker("settings.tabs.fifth-tab", selection: $tabs.fifthTab) {
|
||||
ForEach(Tab.allCases) { tab in
|
||||
if tab == tabs.fifthTab || !tabs.tabs.contains(tab) {
|
||||
tab.label.tag(tab)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
#if !os(visionOS)
|
||||
.listRowBackground(theme.primaryBackgroundColor)
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue