comparison Simoleon/Favourites.swift @ 22:3596690dda73

Add Config files and implementing Settings
author Dennis Concepción Martín <dennisconcepcionmartin@gmail.com>
date Tue, 20 Jul 2021 09:02:51 +0100
parents c3dda63f50ed
children bda6a55d027a
comparison
equal deleted inserted replaced
21:c3dda63f50ed 22:3596690dda73
19 ForEach(favourite) { favourite in 19 ForEach(favourite) { favourite in
20 CurrencyRow(currencyPair: favourite.currencyPair) 20 CurrencyRow(currencyPair: favourite.currencyPair)
21 } 21 }
22 .onDelete(perform: removeFromFavourites) 22 .onDelete(perform: removeFromFavourites)
23 } 23 }
24 .navigationTitle("Favourites")
25 .toolbar {
26 #if os(iOS)
27 EditButton()
28 #endif
29 }
24 .if(UIDevice.current.userInterfaceIdiom == .phone) { content in 30 .if(UIDevice.current.userInterfaceIdiom == .phone) { content in
25 NavigationView { 31 NavigationView { content }
26 content
27 .navigationTitle("Favourites")
28 .toolbar {
29 #if os(iOS)
30 EditButton()
31 #endif
32 }
33 }
34 } 32 }
35 } 33 }
36 34
37 private func removeFromFavourites(offsets: IndexSet) { 35 private func removeFromFavourites(offsets: IndexSet) {
38 withAnimation { 36 withAnimation {