Mercurial > public > simoleon
comparison Simoleon/Helpers/Sidebar.swift @ 187:13d5a8deb6c2
add AboutView and FavoritesView
author | Dennis Concepcion Martin <dennisconcepcionmartin@gmail.com> |
---|---|
date | Thu, 23 Dec 2021 16:12:22 +0100 |
parents | 1ebd1c5dd302 |
children |
comparison
equal
deleted
inserted
replaced
186:1ebd1c5dd302 | 187:13d5a8deb6c2 |
---|---|
8 import SwiftUI | 8 import SwiftUI |
9 | 9 |
10 struct Sidebar: View { | 10 struct Sidebar: View { |
11 var body: some View { | 11 var body: some View { |
12 List { | 12 List { |
13 NavigationLink(destination: ConversionView()) { | 13 NavigationLink(destination: |
14 ConversionView( | |
15 baseCurrency: SupportedCurrencyResult(code: "EUR", name: "Euro", isCrypto: 0), | |
16 quoteCurrency: SupportedCurrencyResult(code: "USD", name: "U.S. Dollar", isCrypto: 0) | |
17 ) | |
18 ) { | |
14 Label("Convert", systemImage: "arrow.counterclockwise.circle") | 19 Label("Convert", systemImage: "arrow.counterclockwise.circle") |
15 } | 20 } |
16 | 21 |
17 NavigationLink(destination: Text("Favorites View")) { | 22 NavigationLink(destination: FavoritesView()) { |
18 Label("Favorites", systemImage: "star") | 23 Label("Favorites", systemImage: "star") |
19 } | 24 } |
20 | 25 |
21 NavigationLink(destination: Text("About")) { | 26 NavigationLink(destination: AboutView()) { |
22 Label("About", systemImage: "info.circle") | 27 Label("About", systemImage: "info.circle") |
23 } | 28 } |
24 } | 29 } |
25 .listStyle(SidebarListStyle()) | 30 .listStyle(SidebarListStyle()) |
26 .navigationTitle("Categories") | 31 .navigationTitle("Categories") |