Mercurial > public > lazybear
comparison LazyBear/Views/Home/TradingDates.swift @ 349:5ccceb527178
Implementing new internal API
author | Dennis Concepción Martín <66180929+denniscm190@users.noreply.github.com> |
---|---|
date | Wed, 14 Apr 2021 23:08:26 +0200 |
parents | 80bfa88c6b0f |
children | 4c90e5b18632 |
comparison
equal
deleted
inserted
replaced
348:0abb8d5c12ec | 349:5ccceb527178 |
---|---|
8 import SwiftUI | 8 import SwiftUI |
9 | 9 |
10 | 10 |
11 struct TradingDates: View { | 11 struct TradingDates: View { |
12 var dates: [TradingDatesModel] | 12 var dates: [TradingDatesModel] |
13 @Environment(\.presentationMode) var tradingDatesPresent | |
13 | 14 |
14 var body: some View { | 15 var body: some View { |
15 NavigationView { | 16 NavigationView { |
16 ScrollView { | 17 ScrollView { |
17 VStack(spacing: 20) { | 18 VStack(spacing: 20) { |
21 } | 22 } |
22 .padding() | 23 .padding() |
23 } | 24 } |
24 .navigationTitle("Holiday dates") | 25 .navigationTitle("Holiday dates") |
25 .navigationBarTitleDisplayMode(.inline) | 26 .navigationBarTitleDisplayMode(.inline) |
27 .toolbar { | |
28 ToolbarItem(placement: .navigationBarTrailing) { | |
29 Button(action: { tradingDatesPresent.wrappedValue.dismiss() }) { | |
30 Image(systemName: "multiply") | |
31 .imageScale(.large) | |
32 } | |
33 } | |
34 } | |
26 } | 35 } |
27 } | 36 } |
28 | 37 |
29 private func getArrayOfDates() -> [Date] { | 38 private func getArrayOfDates() -> [Date] { |
30 // Get array of the string dates | 39 // Get array of the string dates |