-
Notifications
You must be signed in to change notification settings - Fork 0
/
Welcome view.swift
42 lines (36 loc) · 1 KB
/
Welcome view.swift
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
//
// Welcome view.swift
// TopWeather
//
// Created by MD FARID on 27/11/23.
//
import SwiftUI
import CoreLocationUI
struct WelcomeView: View {
@EnvironmentObject var locationManager:
LocationManager
var body:some View {
VStack {
VStack(spacing: 20) {
Text("Welcome to weather app")
.bold().font(.title)
Text("Please share your current location to get the weather in your area")
.padding()
}
.multilineTextAlignment(.center)
.padding()
LocationButton(.shareCurrentLocation) {
locationManager.requestLocation()
}
.cornerRadius(30)
.symbolVariant(.fill )
.foregroundColor(.white)
}
.frame(maxWidth: .infinity, maxHeight: .infinity)
}
}
struct WelcomeView_Previews: PreviewProvider {
static var previews: some View {
WelcomeView()
}
}