SHARE
TWEET

Untitled

a guest Aug 21st, 2019 65 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import SwiftUI
  2.  
  3. struct NavBar : View {
  4.   var body: some View {
  5.     VStack {
  6.       Image("navigation_border")
  7.         .resizable()
  8.         .aspectRatio(contentMode: .fill)
  9.       HStack {
  10.         Spacer()
  11.  
  12.         // Compass button
  13.         Button(action: {
  14.           // Code here
  15.         }) {
  16.           Image("ic_compass")
  17.             .resizable()
  18.             .aspectRatio(contentMode: .fit)
  19.             .frame(width: CGFloat(35), height: CGFloat(35), alignment: .center)
  20.           Text("Boussole")
  21.             .foregroundColor(Color("TextLight"))
  22.             .font(.system(size: 14))
  23.             .fixedSize()
  24.         }
  25.         .frame(height: CGFloat(50), alignment: .bottomLeading)
  26.  
  27.         Spacer()
  28.  
  29.         // Travel button
  30.         Button(action: {
  31.           // Code here
  32.         }) {
  33.           Image("ic_travel")
  34.             .resizable()
  35.             .aspectRatio(contentMode: .fit)
  36.             .frame(width: CGFloat(35), height: CGFloat(35), alignment: .center)
  37.           Text("Parcours")
  38.             .foregroundColor(Color("TextLight"))
  39.             .font(.system(size: 14))
  40.             .fixedSize()
  41.         }
  42.         .frame(height: CGFloat(50), alignment: .bottomLeading)
  43.  
  44.         Spacer()
  45.  
  46.         // Settings button
  47.         PresentationLink(destination: Settings()) {
  48.           Image("ic_settings")
  49.             .resizable()
  50.             .aspectRatio(contentMode: .fit)
  51.             .frame(width: 32, height: 32, alignment: .center)
  52.           Text("Param├Ętres")
  53.             .foregroundColor(Color("TextLight"))
  54.             .font(.system(size: 14))
  55.             .fixedSize()
  56.         }
  57.         .frame(height: 50, alignment: .bottomLeading)
  58.  
  59.         Spacer()
  60.  
  61.       }
  62.       .frame(minWidth: 0, maxWidth: .infinity, minHeight: 70, maxHeight: 70, alignment: .center)
  63.     }
  64.     .frame(minWidth: 0, maxWidth: .infinity, minHeight: 90, maxHeight: 90, alignment: .center)
  65.   }
  66. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top