Mercurial > public > lazybear
comparison LazyBear/Views/Home/Helpers/CurrencyRow.swift @ 395:a0cf8fe47044
Fix minor bugs
author | Dennis Concepción Martín <66180929+denniscm190@users.noreply.github.com> |
---|---|
date | Fri, 07 May 2021 11:43:47 +0200 |
parents | a7e2c5a7b4f6 |
children | 6dd97877f575 |
comparison
equal
deleted
inserted
replaced
394:4c90e5b18632 | 395:a0cf8fe47044 |
---|---|
8 import SwiftUI | 8 import SwiftUI |
9 | 9 |
10 struct CurrencyRow: View { | 10 struct CurrencyRow: View { |
11 var latestCurrencies: [String: CurrencyModel] | 11 var latestCurrencies: [String: CurrencyModel] |
12 | 12 |
13 @Environment(\.managedObjectContext) private var moc | |
13 @State private var showExtensiveList = false | 14 @State private var showExtensiveList = false |
14 | 15 |
15 var body: some View { | 16 var body: some View { |
16 VStack(alignment: .leading) { | 17 VStack(alignment: .leading) { |
17 HStack(alignment: .bottom) { | 18 HStack(alignment: .bottom) { |
42 .padding() | 43 .padding() |
43 } | 44 } |
44 } | 45 } |
45 .sheet(isPresented: $showExtensiveList) { | 46 .sheet(isPresented: $showExtensiveList) { |
46 ExtensiveList(listName: "Currencies", latestCurrencies: latestCurrencies, addOnDelete: false) | 47 ExtensiveList(listName: "Currencies", latestCurrencies: latestCurrencies, addOnDelete: false) |
48 .environment(\.managedObjectContext, self.moc) | |
47 } | 49 } |
48 } | 50 } |
49 } | 51 } |
50 | 52 |
51 struct CurrencyRow_Previews: PreviewProvider { | 53 struct CurrencyRow_Previews: PreviewProvider { |