Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import SwiftUI
- struct ContentView: View {
- var body: some View {
- NavigationView {
- VStack {
- Spacer()
- Text("Witamy w X")
- .font(.largeTitle)
- .padding(.bottom, 10)
- .accessibilityLabel("Welcome to X")
- Text("Wybierz sposób logowania")
- .font(.subheadline)
- .padding(.bottom, 40)
- .accessibilityLabel("Choose a login method")
- VStack(spacing: 20) {
- NavigationLink(destination: PhotoGridView()) {
- Text("Jako gość")
- .font(.headline)
- .frame(minWidth: 0, maxWidth: .infinity)
- .padding()
- .background(Color.blue)
- .foregroundColor(.white)
- .cornerRadius(10)
- }
- .accessibilityLabel("Login as guest")
- Button(action: {
- // Akcja dla przycisku "Zaloguj się"
- }) {
- Text("Zaloguj się")
- .font(.headline)
- .frame(minWidth: 0, maxWidth: .infinity)
- .padding()
- .background(Color.green)
- .foregroundColor(.white)
- .cornerRadius(10)
- }
- .accessibilityLabel("Login")
- }
- .padding(.horizontal, 40)
- Spacer()
- }
- .navigationBarTitle("Ekran Logowania", displayMode: .inline)
- }
- }
- }
- struct PhotoGridView: View {
- var body: some View {
- Text("Photo Grid View")
- }
- }
- struct ContentView_Previews: PreviewProvider {
- static var previews: some View {
- ContentView()
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement