diff --git a/InjectGUI.xcodeproj/project.pbxproj b/InjectGUI.xcodeproj/project.pbxproj index 98cddea..aa61f10 100644 --- a/InjectGUI.xcodeproj/project.pbxproj +++ b/InjectGUI.xcodeproj/project.pbxproj @@ -19,6 +19,7 @@ 38877A3A2C4A730F009F5910 /* Constants.swift in Sources */ = {isa = PBXBuildFile; fileRef = 38877A392C4A730F009F5910 /* Constants.swift */; }; 38877A3D2C4A9EB7009F5910 /* SetupApplicationSupportDirectory.swift in Sources */ = {isa = PBXBuildFile; fileRef = 38877A3C2C4A9EB7009F5910 /* SetupApplicationSupportDirectory.swift */; }; 38BC1F532C4B587A00C3B60E /* SidebarView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 38BC1F522C4B587900C3B60E /* SidebarView.swift */; }; + 38BC1F552C4B622500C3B60E /* WelcomeView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 38BC1F542C4B622500C3B60E /* WelcomeView.swift */; }; /* End PBXBuildFile section */ /* Begin PBXFileReference section */ @@ -36,6 +37,7 @@ 38877A392C4A730F009F5910 /* Constants.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Constants.swift; sourceTree = ""; }; 38877A3C2C4A9EB7009F5910 /* SetupApplicationSupportDirectory.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SetupApplicationSupportDirectory.swift; sourceTree = ""; }; 38BC1F522C4B587900C3B60E /* SidebarView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SidebarView.swift; sourceTree = ""; }; + 38BC1F542C4B622500C3B60E /* WelcomeView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = WelcomeView.swift; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -103,6 +105,7 @@ children = ( 38877A1E2C4A6F83009F5910 /* ContentView.swift */, 38BC1F522C4B587900C3B60E /* SidebarView.swift */, + 38BC1F542C4B622500C3B60E /* WelcomeView.swift */, ); path = View; sourceTree = ""; @@ -209,6 +212,7 @@ 38877A372C4A7294009F5910 /* Configuration.swift in Sources */, 38877A302C4A70DB009F5910 /* SoftwareManager.swift in Sources */, 38877A332C4A7222009F5910 /* PublishedStorage.swift in Sources */, + 38BC1F552C4B622500C3B60E /* WelcomeView.swift in Sources */, 38877A2E2C4A6FFA009F5910 /* InjectConfiguration.swift in Sources */, 38BC1F532C4B587A00C3B60E /* SidebarView.swift in Sources */, 38877A352C4A7254009F5910 /* ViewKit.swift in Sources */, diff --git a/InjectGUI/View/ContentView.swift b/InjectGUI/View/ContentView.swift index ce44e46..8d83003 100644 --- a/InjectGUI/View/ContentView.swift +++ b/InjectGUI/View/ContentView.swift @@ -14,9 +14,9 @@ struct ContentView: View { Group { SidebarView() } - // .frame(maxWidth: .infinity, maxHeight: .infinity) - // .listStyle(.sidebar) .navigationTitle(Constants.appName) + + WelcomeView() } } } diff --git a/InjectGUI/View/WelcomeView.swift b/InjectGUI/View/WelcomeView.swift new file mode 100644 index 0000000..f4508d3 --- /dev/null +++ b/InjectGUI/View/WelcomeView.swift @@ -0,0 +1,44 @@ +// +// WelcomeView.swift +// InjectGUI +// +// Created by wibus on 2024/7/20. +// + +import SwiftUI + +struct WelcomeView: View { + + var version: String { + var ret = "Version: " + + (Constants.appVersion) + + " Build: " + + (Constants.appBuildVersion) + #if DEBUG + ret = "👾 \(ret) 👾" + #endif + return ret + } + + + var body: some View { + ZStack { + VStack(spacing: 4) { + Text("Welcome to InjectGUI") + .font(.system(.title, design: .rounded, weight: .black)) + Text("By wibus. Based on Qiuchenly/InjectLib") + .font(.system(.subheadline, design: .rounded)) + .foregroundColor(.secondary) + + Spacer().frame(height: 24) + } + VStack { + Spacer() + Text(version) + .font(.system(size: 12, weight: .semibold, design: .rounded)) + .opacity(0.5) + } + .padding() + } + } +}