import SwiftUI
struct AppSubmissionGuideView: View {
@State private var showAlert = false
let steps = [
"Archive your app in Xcode",
"Validate your archive",
"Upload to App Store Connect",
"Fill app metadata",
"Submit for review"
]
var body: some View {
VStack(alignment: .leading, spacing: 12) {
Text("App Submission Guide")
.font(.title)
.bold()
.padding(.bottom, 20)
ForEach(steps.indices, id: \.self) { index in
Text("\(index + 1). \(steps[index])")
.font(.body)
}
Spacer()
Button("Start Submission") {
showAlert = true
}
.font(.headline)
.frame(maxWidth: .infinity)
.padding()
.background(Color.accentColor)
.foregroundColor(.white)
.cornerRadius(8)
.alert("Submission Started", isPresented: $showAlert) {
Button("OK", role: .cancel) { }
} message: {
Text("You have started the app submission process.")
}
}
.padding()
}
}
struct AppSubmissionGuideView_Previews: PreviewProvider {
static var previews: some View {
Group {
AppSubmissionGuideView()
.preferredColorScheme(.light)
AppSubmissionGuideView()
.preferredColorScheme(.dark)
}
}
}This SwiftUI view shows a clear numbered list of the five steps needed to submit an app to App Store Connect. The steps are displayed using a ForEach loop for simplicity and scalability.
The "Start Submission" button triggers an alert confirming the start of the submission process. The button uses the app's accent color for good visibility and accessibility.
The layout uses padding and spacing for readability and supports both light and dark modes automatically by using system colors.