Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import SwiftUI
- struct NavBar : View {
- var body: some View {
- VStack {
- Image("navigation_border")
- .resizable()
- .aspectRatio(contentMode: .fill)
- HStack {
- Spacer()
- // Compass button
- Button(action: {
- // Code here
- }) {
- Image("ic_compass")
- .resizable()
- .aspectRatio(contentMode: .fit)
- .frame(width: CGFloat(35), height: CGFloat(35), alignment: .center)
- Text("Boussole")
- .foregroundColor(Color("TextLight"))
- .font(.system(size: 14))
- .fixedSize()
- }
- .frame(height: CGFloat(50), alignment: .bottomLeading)
- Spacer()
- // Travel button
- Button(action: {
- // Code here
- }) {
- Image("ic_travel")
- .resizable()
- .aspectRatio(contentMode: .fit)
- .frame(width: CGFloat(35), height: CGFloat(35), alignment: .center)
- Text("Parcours")
- .foregroundColor(Color("TextLight"))
- .font(.system(size: 14))
- .fixedSize()
- }
- .frame(height: CGFloat(50), alignment: .bottomLeading)
- Spacer()
- // Settings button
- PresentationLink(destination: Settings()) {
- Image("ic_settings")
- .resizable()
- .aspectRatio(contentMode: .fit)
- .frame(width: 32, height: 32, alignment: .center)
- Text("Paramètres")
- .foregroundColor(Color("TextLight"))
- .font(.system(size: 14))
- .fixedSize()
- }
- .frame(height: 50, alignment: .bottomLeading)
- Spacer()
- }
- .frame(minWidth: 0, maxWidth: .infinity, minHeight: 70, maxHeight: 70, alignment: .center)
- }
- .frame(minWidth: 0, maxWidth: .infinity, minHeight: 90, maxHeight: 90, alignment: .center)
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement