Mercurial > public > simoleon
comparison Simoleon/ConversionView.swift @ 161:3913aff613e8
Fix bug that didn't request API on symbol change
author | Dennis Concepcion Martin <dennisconcepcionmartin@gmail.com> |
---|---|
date | Tue, 31 Aug 2021 10:57:34 +0100 |
parents | 0c589138a6f3 |
children | 35573bdd7d9b |
comparison
equal
deleted
inserted
replaced
160:0c589138a6f3 | 161:3913aff613e8 |
---|---|
8 import SwiftUI | 8 import SwiftUI |
9 import Purchases | 9 import Purchases |
10 | 10 |
11 struct ConversionView: View { | 11 struct ConversionView: View { |
12 var showNavigationView: Bool? | 12 var showNavigationView: Bool? |
13 @StateObject var currencyPair = CurrencyPair() | 13 @StateObject var currencyConversion = CurrencyConversion() |
14 | 14 |
15 var body: some View { | 15 var body: some View { |
16 ScrollView(showsIndicators: false) { | 16 ScrollView(showsIndicators: false) { |
17 VStack(alignment: .leading, spacing: 20) { | 17 VStack(alignment: .leading, spacing: 20) { |
18 HStack { | 18 HStack { |
19 CurrencySelector(currencyPair: currencyPair) | 19 CurrencySelector(currencyConversion: currencyConversion) |
20 FavoriteButton(currencyPair: currencyPair) | 20 FavoriteButton(currencyConversion: currencyConversion) |
21 } | 21 } |
22 | 22 |
23 ConversionBox(currencyPair: currencyPair) | 23 ConversionBox(currencyConversion: currencyConversion) |
24 .padding(.top) | 24 .padding(.top) |
25 } | 25 } |
26 .padding() | 26 .padding() |
27 } | 27 } |
28 .navigationTitle("Convert") | 28 .navigationTitle("Convert") |