remove refresh button from toolbar

This commit is contained in:
Satindar Dhillon 2022-03-10 20:51:42 -08:00
parent 779eb9ac1f
commit 54f4883e75

View file

@ -131,19 +131,13 @@ import Views
.toolbar {
ToolbarItem {
if #available(iOS 15.0, *) {
Button(
action: {
viewModel.loadItems(dataService: dataService, searchQuery: searchQuery, isRefresh: true)
},
label: { Label("Refresh Feed", systemImage: "arrow.clockwise") }
)
.disabled(viewModel.isLoading)
.opacity(viewModel.isLoading ? 0 : 1)
.overlay {
if viewModel.isLoading {
ProgressView()
Button("", action: {})
.disabled(true)
.overlay {
if viewModel.isLoading {
ProgressView()
}
}
}
} else {
Button(
action: {