mirror of
https://github.com/NinjaCheetah/RIT-Dining.git
synced 2025-10-19 06:36:18 -04:00
It seems reasonable to ask for some money here or there, since my Apple Developer Program membership was quite expensive just for this app
47 lines
1.4 KiB
Swift
47 lines
1.4 KiB
Swift
//
|
|
// AboutView.swift
|
|
// RIT Dining
|
|
//
|
|
// Created by Campbell on 9/12/25.
|
|
//
|
|
|
|
import SwiftUI
|
|
|
|
struct AboutView: View {
|
|
@Environment(\.openURL) private var openURL
|
|
let appVersionString: String = Bundle.main.object(forInfoDictionaryKey: "CFBundleShortVersionString") as! String
|
|
let buildNumber: String = Bundle.main.object(forInfoDictionaryKey: "CFBundleVersion") as! String
|
|
|
|
var body: some View {
|
|
VStack {
|
|
Image("Icon")
|
|
.resizable()
|
|
.frame(width: 128, height: 128)
|
|
.clipShape(RoundedRectangle(cornerRadius: 20))
|
|
Text("RIT Dining App")
|
|
.font(.title)
|
|
Text("because the RIT dining website is slow!")
|
|
Text("Version \(appVersionString) (\(buildNumber))")
|
|
.foregroundStyle(.secondary)
|
|
Spacer()
|
|
Button(action: {
|
|
openURL(URL(string: "https://github.com/NinjaCheetah/RIT-Dining")!)
|
|
}) {
|
|
Label("GitHub Repository", systemImage: "globe")
|
|
}
|
|
Button(action: {
|
|
openURL(URL(string: "https://tigercenter.rit.edu/")!)
|
|
}) {
|
|
Label("TigerCenter API", systemImage: "globe")
|
|
}
|
|
}
|
|
.padding()
|
|
.navigationTitle("About")
|
|
.navigationBarTitleDisplayMode(.inline)
|
|
}
|
|
}
|
|
|
|
#Preview {
|
|
AboutView()
|
|
}
|